Commit Graph

3 Commits

Author SHA1 Message Date
Claude
9332dcc35a fix: Improve NIP-17 chat UI and fix decrypt handling
- Fix garbled messages by creating synthetic events from rumors
- Add rumor events to EventStore so ReplyPreview can find them
- Fix decrypt toast showing success even on failure
- Show profile names in chat title using DmTitle component
- Support $me alias for saved messages (chat $me)
- Make inbox conversations more compact, remove icon
- Show "Saved Messages" for self-conversation in inbox
- Wire up inbox conversation click to open chat window
- Show per-participant inbox relays in RelaysDropdown
- Add participantInboxRelays metadata type for NIP-17
2026-01-16 10:19:29 +00:00
Claude
35e1f9fe1a fix: Improve inbox gift wrap handling and UI
Fixes several issues with the inbox feature:

1. Load persisted decrypted content on init:
   - Load stored encrypted content IDs from Dexie on service init
   - Subscribe to eventStore.update$ to detect cache restoration
   - Automatically update conversations when restored content is available

2. Mark already-decrypted gift wraps correctly:
   - Check both in-memory unlock state AND persisted IDs
   - Prevents showing decrypted messages as "pending" after reload

3. Hide manual decrypt UI when auto-decrypt is enabled:
   - Only show "Decrypt All" button when auto-decrypt is off
   - Show "Auto-decrypting..." status when auto-decrypt is on

4. Show pending count in user menu:
   - Add pendingCount$ observable to gift wrap service
   - Display badge on "Private Messages" menu item when there are
     undecrypted messages and auto-decrypt is disabled

5. Expose full rumor for future kind support:
   - Add decryptedRumors$ observable with all decrypted rumors
   - Full rumor event (id, pubkey, kind, tags, content) is preserved
   - Enables future support for any kind sent via gift wrap
2026-01-16 09:34:47 +00:00
Claude
325ffa5aa8 feat: Add inbox for NIP-17 private direct messages
Implements private message inbox with gift wrap (NIP-59) support:

- Add GiftWrapService for managing encrypted messages (NIP-17/NIP-59)
  - Track decrypt states (pending/decrypting/success/error)
  - Load inbox relays from kind 10050 (DM relay list)
  - Auto-decrypt option with settings persistence
  - Group messages into conversations

- Add InboxViewer component with:
  - Enable/disable private messages toggle
  - Auto-decrypt toggle
  - Inbox relay display
  - Decrypt status badges (pending/success/error)
  - Conversation list with last message preview
  - Click to decrypt individual messages

- Add encrypted content persistence using Dexie (version 16)
- Add "inbox" command to man pages
- Add "Private Messages" menu item to user menu
2026-01-16 09:19:56 +00:00