mirror of
https://github.com/purrgrammer/grimoire.git
synced 2026-04-16 18:37:14 +02:00
* feat: add NIP-61 nutzap support to NIP-29 groups Fetch and render nutzap events (kind 9321) in NIP-29 relay groups using the same visual styling as lightning zaps. Nutzaps are P2PK locked Cashu token transfers defined in NIP-61. - Add nutzap filter subscription in loadMessages - Combine chat and nutzap observables with RxJS combineLatest - Add nutzapToMessage helper to parse NIP-61 event structure - Extract amount by summing proof amounts from proof tag JSON - Add nutzapUnit metadata field for future multi-currency support * fix: improve zap/nutzap rendering in chat - Add mb-1 margin bottom to zap messages for spacing - Show inline reply preview for zaps that target specific messages - Fix nutzap amount extraction to handle multiple proof tags - Extract replyTo from e-tag for nutzaps - Pass nutzap event to RichText for custom emoji rendering * fix: pass event only to RichText for proper emoji rendering * refactor: consolidate NIP-29 chat and nutzap into single REQ - Use single filter with kinds [9, 9000, 9001, 9321] instead of separate subscriptions with combineLatest - Enables proper pagination for "load older" with single page fetches - Add rounded corners to zap gradient border for consistent rendering * refactor: consolidate NIP-53 chat and zap into single REQ - Use single filter with kinds [1311, 9735] instead of separate subscriptions with combineLatest - Enables proper pagination for "load older" with single page fetches - Filter invalid zaps inline during event mapping * feat: add load older messages support to chat adapters - Implement loadMoreMessages in NIP-29 adapter using pool.request - Implement loadMoreMessages in NIP-53 adapter using pool.request - Add "Load older messages" button to ChatViewer header - Use firstValueFrom + toArray to convert Observable to Promise - Track loading state and hasMore for pagination UI --------- Co-authored-by: Claude <noreply@anthropic.com>