Commit Graph

93 Commits

Author SHA1 Message Date
e4468d305e Improve Blossom UI responsiveness and layout (v0.37.2)
Some checks failed
Go / build-and-release (push) Has been cancelled
- Show full npub on screens > 720px, truncated on smaller screens
- Make admin users list extend to full width

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-25 13:20:49 +01:00
3f07e47ffb Fix Blossom view right edge overflow 2025-12-25 13:10:44 +01:00
aea8fd31e7 Improve Blossom UI with thumbnails and full-width layout (v0.37.0)
Some checks failed
Go / build-and-release (push) Has been cancelled
- Make Blossom view use full available width
- Add "Upload new files" label with Select Files button on right
- Show image/video thumbnails in file list (48x48px)
- Add emoji icons for audio (🎵) and documents (📄)
- Show full hash on screens > 720px, truncated on smaller

Files modified:
- app/web/src/BlossomView.svelte: UI layout and thumbnail changes
- app/web/dist/*: Rebuilt bundle

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-25 13:07:25 +01:00
042acd9ed2 Track all dist assets and remove debug logging 2025-12-25 12:38:54 +01:00
dddf1ac568 Add bundle.js to git tracking for embedded web UI 2025-12-25 12:34:48 +01:00
d6f2a0f7cf Add visible debug bar for role detection 2025-12-25 12:32:40 +01:00
7c60b63df6 Add debug logging for Blossom admin role detection (v0.36.22)
Some checks failed
Go / build-and-release (push) Has been cancelled
- Add console.log to trace currentEffectiveRole value in BlossomView
- Add HTML comment showing role and isAdmin values for debugging

Files modified:
- app/web/src/BlossomView.svelte: Add debug logging for role detection

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-25 12:30:15 +01:00
ab2ac1bf4c Add Blossom admin UI for viewing all users' storage (v0.36.21)
Some checks failed
Go / build-and-release (push) Has been cancelled
- Add ListAllUserStats() storage method to aggregate user blob stats
- Add handleAdminListUsers() handler for admin endpoint
- Add /blossom/admin/users route requiring admin ACL
- Add Admin button to Blossom UI for admin/owner roles
- Add admin view showing all users with file counts and sizes
- Add user detail view to browse individual user's files
- Fetch user profiles (avatar, name) for admin list display

Files modified:
- pkg/blossom/storage.go: Add UserBlobStats struct and ListAllUserStats()
- pkg/blossom/handlers.go: Add handleAdminListUsers() handler
- pkg/blossom/server.go: Add admin/users route
- app/web/src/BlossomView.svelte: Add admin view state, UI, and styles

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-25 12:04:35 +01:00
da6008a00e Improve version link visibility and styling in sidebar (v0.36.19)
Some checks failed
Go / build-and-release (push) Has been cancelled
- Change version link color from muted to readable text color
- Add background color hover effect matching tab styling
- Replace Gitea icon with mug-and-leaf icon
- Rename CSS class from gitea-icon to version-icon

Files modified:
- app/web/src/Sidebar.svelte: Updated version link styling and icon

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-25 11:19:52 +01:00
b6b31cb93f Add version display to web UI sidebar (v0.36.18)
Some checks failed
Go / build-and-release (push) Has been cancelled
- Add version footer to sidebar bottom-left with Gitea icon link
- Fetch relay version from NIP-11 relay info document
- Link opens https://next.orly.dev in new tab
- Responsive design hides version text on medium screens

Files modified:
- app/web/src/api.js: Add fetchRelayInfo() function
- app/web/src/Sidebar.svelte: Add version display with Gitea SVG icon
- app/web/src/App.svelte: Add relayVersion state and fetch on init
- pkg/version/version: Bump to v0.36.18

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-25 10:08:50 +01:00
c9a03db395 Fix Blossom CORS headers and add root-level upload routes (v0.36.12)
Some checks failed
Go / build-and-release (push) Has been cancelled
- Add proper CORS headers for Blossom endpoints including X-SHA-256,
  X-Content-Length, X-Content-Type headers required by blossom-client-sdk
- Add root-level Blossom routes (/upload, /media, /mirror, /report, /list/)
  for clients like Jumble that expect Blossom at root
- Export BaseURLKey from pkg/blossom for use by app handlers
- Make blossomRootHandler return URLs with /blossom prefix so blob
  downloads work via the registered /blossom/ route
- Remove Access-Control-Allow-Credentials header (not needed for * origin)
- Add Access-Control-Expose-Headers for X-Reason and other response headers

Files modified:
- app/blossom.go: Add blossomRootHandler, use exported BaseURLKey
- app/server.go: Add CORS handling for blossom paths, register root routes
- pkg/blossom/server.go: Fix CORS headers, export BaseURLKey
- pkg/blossom/utils.go: Minor formatting
- pkg/version/version: Bump to v0.36.12

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-24 11:32:52 +01:00
11d1b6bfd1 Fix fetch-kinds script for Node.js compatibility (v0.36.9)
Some checks failed
Go / build-and-release (push) Has been cancelled
- Replace import.meta.dirname with fileURLToPath/dirname for Node < 20.11
- Use static imports instead of dynamic imports for fs/path

Files modified:
- app/web/scripts/fetch-kinds.js: Node.js compatibility fix
- pkg/version/version: v0.36.8 -> v0.36.9

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-21 05:17:48 +01:00
7f1785a39a Add prebuild script to fetch event kinds from nostr library
- Add scripts/fetch-kinds.js to fetch kinds.json from central source
- Update package.json with prebuild hook to auto-fetch on build
- Regenerate eventKinds.js from https://git.mleku.dev/mleku/nostr/raw/branch/main/encoders/kind/kinds.json
- Now uses single source of truth for all 184 event kinds

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-21 05:07:34 +01:00
b4c0c4825c Add secure nsec key generation and encryption for web UI (v0.36.7)
Some checks failed
Go / build-and-release (push) Has been cancelled
- Add nsec-crypto.js library with Argon2id+AES-GCM encryption
- Generate new nsec keys using secure system entropy
- Encrypt nsec with password (~3 sec Argon2id derivation in Web Worker)
- Add unlock flow for returning users with encrypted keys
- Add deriving modal with live timer during key derivation
- Auto-create default profile for new users with ORLY logo avatar
- Fix NIP-42 auth race condition in websocket-auth.js
- Improve header user profile display (avatar fills height, no truncation)
- Add instant light/dark theme colors in HTML head
- Add background box around username/nip05 in settings drawer
- Update CLAUDE.md with nsec-crypto library documentation

Files modified:
- app/web/src/nsec-crypto.js: New encryption library
- app/web/src/LoginModal.svelte: Key gen, encryption, unlock UI
- app/web/src/nostr.js: Default profile creation
- app/web/src/App.svelte: Header and drawer styling
- app/web/public/index.html: Instant theme colors
- CLAUDE.md: Library documentation

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-18 08:40:16 +01:00
602d563a7c Fix WebSocket auth flow and improve header user profile display
- Fix NIP-42 auth race condition: wait for AUTH challenge before authenticating
- Header user profile: avatar fills vertical space, username vertically centered
- Remove username truncation to show full name/npub
- Standardize header height to 3em across all components

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-18 06:25:38 +01:00
358c8bc931 Replace manual theme toggle with automatic system preference detection (v0.36.4)
Some checks failed
Go / build-and-release (push) Has been cancelled
- Remove sun/moon theme toggle button from header
- Detect system theme preference using window.matchMedia prefers-color-scheme
- Add event listener to automatically switch theme when OS preference changes
- Remove localStorage-based theme persistence in favor of system preference
- Clean up unused theme-toggle-btn CSS styles

Files modified:
- app/web/src/Header.svelte: Remove toggle button, toggleTheme function, and CSS
- app/web/src/App.svelte: Replace localStorage theme init with matchMedia detection
- pkg/version/version: Bump to v0.36.4

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-17 14:11:15 +01:00
1bbbfb5570 Fix WebSocket protocol detection for HTTP deployments (v0.36.3)
Some checks failed
Go / build-and-release (push) Has been cancelled
- Fix minifier optimization bug that caused ws:// protocol detection to
  always return wss:// by using startsWith('https') instead of === 'https:'
- Update App.svelte to use protocol detection in all 5 WebSocket URL
  construction locations (compose, delete, repost, publish functions)
- Update constants.js DEFAULT_RELAYS to use the same minifier-safe pattern
- Enables web UI to work correctly on HTTP-only relay deployments

Files modified:
- app/web/src/App.svelte: Fix 5 hardcoded wss:// URLs with protocol detection
- app/web/src/constants.js: Fix DEFAULT_RELAYS protocol detection
- pkg/version/version: Bump to v0.36.3

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-17 13:52:28 +01:00
0a3e639fee Add event template generator with 140+ Nostr event kinds (v0.36.2)
Some checks failed
Go / build-and-release (push) Has been cancelled
- Add comprehensive eventKinds.js database with all NIPs event kinds
  including templates, descriptions, NIP references, and type flags
- Create EventTemplateSelector.svelte modal with search functionality
  and category filtering (Social, Messaging, Lists, Marketplace, etc.)
- Update ComposeView with "Generate Template" button and error banner
  for displaying permission-aware publish error messages
- Enhance publishEvent() in App.svelte with detailed error handling
  that explains policy restrictions, permission issues, and provides
  actionable guidance for users
- Add permission pre-check to prevent read-only users from attempting
  to publish events
- Update CLAUDE.md with Web UI event templates documentation
- Create docs/WEB_UI_EVENT_TEMPLATES.md with comprehensive user guide

Files modified:
- app/web/src/eventKinds.js (new)
- app/web/src/EventTemplateSelector.svelte (new)
- app/web/src/ComposeView.svelte
- app/web/src/App.svelte
- docs/WEB_UI_EVENT_TEMPLATES.md (new)
- CLAUDE.md
- pkg/version/version

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-16 10:39:02 +01:00
8bdf1fcd39 Replace search mode with an enhanced filter system
Some checks failed
Go / build-and-release (push) Has been cancelled
Removes the legacy search mode in favor of an improved event filter system. Introduces debounced filter application, JSON-based filter configuration, and a cleaner UI for filtering events, offering greater flexibility and clarity.
2025-12-05 21:16:19 +00:00
930e3eb1b1 Upgrade dependencies and improve UI handling.
Updated "applesauce-core" and "applesauce-signers" to newer versions in lockfile and package.json. Enhanced UI with better button styling and added logic to hide the "policy" tab if not enabled. Included "bun update" in approved commands.
2025-12-05 19:48:34 +00:00
8ef3114f5c Refactor project to modularize constants and utilities.
Moved reusable constants and helper functions to dedicated modules for improved maintainability and reusability. Improved build configuration to differentiate output directories for development and production. Enhanced server error handling and added safeguards for disabled web UI scenarios.
2025-12-05 19:25:13 +00:00
e9173a6894 Update event import process and improve user feedback
Some checks failed
Go / build-and-release (push) Has been cancelled
Simplified event import to run synchronously, ensuring proper resource handling and accurate feedback. Enhanced frontend with real-time import status messages and error handling. Adjusted migrations to handle events individually, improving reliability and granular progress tracking.
2025-12-05 14:42:22 +00:00
c1bd05fb04 Adjust ACL behavior for "none" mode and make query cache optional
Some checks failed
Go / build-and-release (push) Has been cancelled
This commit allows skipping authentication, permission checks, and certain filters (e.g., deletions, expirations) when the ACL mode is set to "none" (open relay mode). It also introduces a configuration option to disable query caching to reduce memory usage. These changes improve operational flexibility for open relay setups and resource-constrained environments.
2025-12-05 11:25:34 +00:00
7fedcd24d3 initial draft of hot reload policy 2025-11-27 06:31:34 +00:00
cc99fcfab5 bump to v0.27.5
Some checks failed
Go / build (push) Has been cancelled
Go / release (push) Has been cancelled
2025-11-11 14:38:05 +00:00
d0dbd2e2dc implemented and tested NIP-43 invite based ACL 2025-11-09 10:41:58 +00:00
b4760c49b6 implement messages and operations for FIND 2025-11-08 08:54:58 +00:00
29ab350eed Implement advanced filtering capabilities in the search interface
Some checks failed
Go / build (push) Has been cancelled
Go / release (push) Has been cancelled
- Added a FilterBuilder component to allow users to create complex search filters based on various criteria such as event kinds, authors, and tags.
- Introduced a FilterDisplay component to show active filters and provide an option to clear them.
- Updated the App.svelte to integrate the new filtering features, including handling filter application and clearing.
- Enhanced search functionality to utilize the new filter structure, improving the search results experience.
- Bumped version to v0.26.0 to reflect these changes.
2025-11-06 09:20:18 +00:00
f4358eeee0 Enhance Event Loading Logic and Update Permissions
Some checks failed
Go / build (push) Has been cancelled
Go / release (push) Has been cancelled
- Updated event loading logic in App.svelte to reset the attempt flag when toggling filters or switching tabs, preventing infinite load loops.
- Modified role-based permissions to include "read" access for viewing events, ensuring users with "read", "write", "admin", or "owner" roles can access the event list.
- Adjusted alert messages to reflect the updated permission structure.
- Incremented the version number to v0.19.5 to reflect these changes.
2025-10-27 13:25:18 +00:00
ebb11686d5 Update Role-Based Permissions and Increment Version
Some checks failed
Go / build (push) Has been cancelled
Go / release (push) Has been cancelled
- Modified role-based permissions in App.svelte and EventsView.svelte to include "read" access for viewing events, enhancing user access control.
- Updated conditional rendering logic to reflect the new permission structure, ensuring users with "read", "write", "admin", or "owner" roles can view events.
- Incremented the version number to v0.19.4 to reflect these changes.
2025-10-27 11:59:54 +00:00
d4f4f2a186 Implement New Views and Refactor App Structure
Some checks failed
Go / build (push) Has been cancelled
Go / release (push) Has been cancelled
- Added new components: Header, Sidebar, ExportView, ImportView, EventsView, ComposeView, RecoveryView, SprocketView, and SearchResultsView to enhance the application's functionality and user experience.
- Updated App.svelte to integrate the new views and improve the overall layout.
- Refactored existing components for better organization and maintainability.
- Adjusted CSS styles for improved visual consistency across the application.
- Incremented version number to v0.19.3 to reflect the latest changes and additions.
2025-10-25 23:03:34 +01:00
9abcb32030 Refactor Event Signing and Update Test Cases
Some checks failed
Go / build (push) Has been cancelled
Go / release (push) Has been cancelled
- Changed the event signing method in App.svelte from `sign` to `signEvent` for clarity and consistency.
- Updated the privileged events test to replace `PrivateDirectMessage` with `DirectMessage`, aligning with the latest event kind definitions.
- Adjusted the bundle.js and bundle.js.map files to reflect the latest build changes and optimizations.
2025-10-25 20:45:36 +01:00
fe0ed11ce4 Enhance App Functionality with Role-Based Permissions and UI Improvements
- Introduced a new permission menu and role view settings to manage user access more effectively.
- Updated tab filtering logic to accommodate role-based permissions, ensuring users see only relevant options based on their roles.
- Enhanced the App.svelte component with new CSS styles for the view-as section, improving user experience and visual consistency.
- Added debug logging for tab filtering to assist in development and troubleshooting.
- Incremented the version number to reflect the latest changes and improvements.
2025-10-25 20:37:18 +01:00
5452da6ecc Update IndexedDB Handling and Enhance App Functionality
Some checks failed
Go / build (push) Has been cancelled
Go / release (push) Has been cancelled
- Modified the NostrClient's publish method to allow for specific relay usage and added event storage in IndexedDB.
- Introduced a debug function for IndexedDB to inspect stored events and their counts by kind.
- Updated the App.svelte component to expose the debug function globally for easier access during development.
- Enhanced the CSS styles for better user feedback on export results and status messages.
- Incremented the IndexedDB version to accommodate new indexes and improve event storage management.
- Updated the version number to v0.19.1.
2025-10-25 19:26:31 +01:00
c5ff2c648c Refactor Nostr Client and Update Dependencies
- Replaced NDKPrivateKeySigner with PrivateKeySigner from applesauce-signers for improved signing functionality.
- Updated the Nostr client implementation to utilize nostr-tools for event management and connection pooling.
- Enhanced event fetching logic to support multiple versions of replaceable events based on limit parameters.
- Updated package dependencies in package.json and bun.lock, including the addition of applesauce-core and applesauce-signers.
- Refined event kind definitions and improved documentation for clarity and consistency with NIP specifications.
- Adjusted CSS styles in bundle.css for better visual consistency across components.
2025-10-25 17:27:25 +01:00
384b6113bc fixes memory problem with many pubkeys in query
Some checks failed
Go / build (push) Has been cancelled
Go / release (push) Has been cancelled
2025-10-20 22:20:21 +01:00
105e372712 Refactor and enhance UI components for improved styling and functionality
Some checks failed
Go / build (push) Has been cancelled
Go / release (push) Has been cancelled
- Updated CSS styles for modal and tab components to enhance visual consistency and responsiveness.
- Refactored JavaScript imports in App.svelte for better readability and organization.
- Improved layout and padding in ManagedACL.svelte for a more user-friendly interface.
- Adjusted event handling and state management in App.svelte to streamline user interactions.
- Updated bundle files to reflect the latest changes in the application structure and styling.
- bump to v0.17.1
2025-10-16 18:02:39 +01:00
bcd79aa967 implemented nip-86 relay management API and added to relay client
Some checks failed
Go / build (push) Has been cancelled
Go / release (push) Has been cancelled
2025-10-16 17:20:04 +01:00
1cfd4a6dbe Include app/web/dist in repository
- Remove app/web/dist/** from .gitignore
- Add built web assets to repository for deployment
- Includes bundle.css, bundle.js, index.html and other static assets
2025-10-16 11:41:57 +01:00
f19dc4e5c8 Implement compose tab for event creation and management
Some checks failed
Go / build (push) Has been cancelled
- Added a new compose tab for users to create, sign, and publish Nostr events.
- Introduced functions for JSON reformatting, event signing, and publishing with WebSocket authentication.
- Implemented clipboard functionality to copy event JSON directly from the UI.
- Enhanced UI with buttons for reformatting, signing, and publishing events, improving user experience.
- Created a new websocket-auth.js module for handling WebSocket authentication with Nostr relays.
- Bumped version to v0.14.5.
2025-10-11 10:30:38 +01:00
49619f74c7 fix user button and images
Some checks failed
Go / build (push) Has been cancelled
2025-10-11 09:23:01 +01:00
5952c7e657 Revert "Update project structure and enhance build process"
This reverts commit 4cf3d9cfb5.
2025-10-11 08:46:30 +01:00
4cf3d9cfb5 Update project structure and enhance build process
Some checks failed
Go / build (push) Has been cancelled
- Removed unnecessary entries from .gitignore related to the app/web/dist directory.
- Updated app/web/.gitignore to exclude the dist directory.
- Added rollup-plugin-copy to package.json and updated rollup.config.js to copy static assets during the build process.
- Introduced new CSS and JS files in the dist directory for improved styling and functionality.
- Updated index.html to reference new global CSS and JS files, enhancing the overall user interface.
- Added favicon and other image assets to the dist directory for branding consistency.
2025-10-11 08:05:50 +01:00
b0f919cd5a Enhance event display and UI in App.svelte
- Added a formatTimestamp function to display event creation timestamps.
- Refactored event rendering to include timestamps and improved content truncation.
- Updated the events view header and buttons for better layout and usability.
- Adjusted styles for event items and timestamps for improved readability.
- Implemented responsive design adjustments for smaller screens.
2025-10-11 07:52:48 +01:00
0cdf44c2c9 fully working deletes bump to v0.14.0
Some checks failed
Go / build (push) Has been cancelled
2025-10-10 21:52:32 +01:00
40f3cb6f6e Enhance delete event functionality and UI updates
- Improved logging in handle-delete.go for admin and owner checks during delete operations.
- Updated handle-event.go to ensure delete events are saved before processing, with enhanced error handling.
- Added fetchDeleteEventsByTarget function in nostr.js to retrieve delete events targeting specific event IDs.
- Modified App.svelte to include delete event verification and improved event sorting by creation timestamp.
- Enhanced UI to display delete event information and added loading indicators for event refresh actions.
2025-10-10 21:23:36 +01:00
67a74980f9 Enhance delete event handling and logging
- Improved logging for delete events in handle-delete.go, including detailed information about the event and its tags.
- Added checks for admin and owner deletions, with appropriate logging for each case.
- Updated HandleEvent to process delete events more robustly, including success and error logging.
- Introduced a new fetchEventById function in nostr.js to verify event deletion.
- Updated App.svelte to handle event deletion verification and state management.
- Changed favicon references in HTML files to use the new orly-favicon.png.
- Added orly-favicon.png to the public and docs directories for consistent branding.
2025-10-10 20:36:53 +01:00
dc184d7ff5 Revert ephemeral event handling changes that broke relaytester
- Remove ephemeral event handling in handle-event.go
- Remove ephemeral event rejection in save-event.go
- Remove formatTimestamp function and title attributes in App.svelte
- Remove TestEphemeralEventRejection test
- Fix slice bounds bug in get-serials-by-range.go
- Restore correct error message format for existing events
- Revert version from v0.13.2 to v0.12.3

This reverts commit 075838150d which introduced
a critical bug causing runtime panics in the relaytester.
2025-10-10 19:55:39 +01:00
075dc6b545 Integrate NDK for Nostr client functionality and update dependencies
This commit introduces the Nostr Development Kit (NDK) to enhance the Nostr client functionality. Key changes include:

- Added `NDKPrivateKeySigner` for improved authentication methods in `LoginModal.svelte` and `App.svelte`.
- Refactored the Nostr client to utilize NDK for connection and event fetching, streamlining the connection process and event handling.
- Updated `go.mod` and `package.json` to include `@nostr-dev-kit/ndk` as a dependency.
- Created a new `package-lock.json` to reflect the updated dependency tree.

These changes improve the overall architecture and maintainability of the Nostr client.
2025-10-10 17:37:43 +01:00
919747c910 Remove fallback external relays from DEFAULT_RELAYS in constants.js to streamline relay connection handling. 2025-10-10 17:11:21 +01:00