The real problem: nostr.relay() and nostr.group() each open brand new
WebSocket connections outside the pool. Every hook that called these
was creating duplicate connections to relays the pool already had open.
Fixed by routing all queries and subscriptions through the pool (nostr)
directly, which reuses its internal connections:
- useStreamPosts: nostr.relay('wss://relay.ditto.pub') → nostr
- useStreamKind: nostr.relay('wss://relay.ditto.pub') → nostr
- useSearchProfiles: nostr.relay('wss://relay.ditto.pub') → nostr
- useFollowActions: nostr.group([...]) → nostr
- FollowPackDetailContent: nostr.group([...]) → nostr
Also reverted the hacky relay cleanup code in NostrProvider since
it was trying to solve the wrong problem.
Co-authored-by: shakespeare.diy <assistant@shakespeare.diy>
- Split Treasures into two sub-kinds: Geocaches (kind 37516) and Found Logs (kind 7516)
- Add `showTreasureGeocaches`, `showTreasureFoundLogs`, `feedIncludeTreasureGeocaches`, `feedIncludeTreasureFoundLogs` to FeedSettings
- Extend ExtraKindDef with optional `subKinds` array for nested settings
- Update FeedSettingsForm to render nested sub-kind toggles under parent entries
- Update useStreamKind to accept single kind or array of kinds
- Create TreasuresPage that filters kinds based on sub-kind settings
- Add getPageKinds() utility for resolving sub-kind-aware page kinds
Co-authored-by: shakespeare.diy <assistant@shakespeare.diy>
- PollContent (kind 1068 / NIP-88): Shows question, options with
selectable vote UI, tallied results with percentage bars, poll type
badge (single/multi), expiry status. Fetches kind 1018 vote events,
deduplicates per pubkey, and allows voting when logged in.
- GeocacheContent (kind 37516 / NIP-GC): Shows cache name, type badge,
size badge, D/T difficulty pips (1-5), description, image, and
ROT13-decoded hint toggle. Supports verified cache indicator.
- ColorMomentContent (kind 3367 / Espy NIP): Renders color palettes
with all 6 layout modes (horizontal, vertical, grid, star,
checkerboard, diagonalStripes). Emoji overlay with adaptive
light/dark text based on palette luminance. Click-to-copy hex
swatches. Name display above palette.
- NoteCard now dispatches to the correct content component based on
event.kind (1, 1068, 3367, 34236, 37516).
- Replaced VinesPage/useStreamVines with generic KindFeedPage/useStreamKind.
All kind-specific routes (/vines, /polls, /treasures, /colors) use
the same generic streaming page parameterized by kind number.
- Centralized extra-kind definitions in lib/extraKinds.ts. All feeds
(home, search, profile, hashtag) respect feed settings for which
extra kinds to include.
Co-authored-by: shakespeare.diy <assistant@shakespeare.diy>