From 019935928a6a95a62e4015fbca240eb6f88e4e5c Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 12 Jan 2026 16:42:27 +0000 Subject: [PATCH] feat: add kind names for NIP-29 group events and simplify renderer - Add kind 39000 (Group), 39001 (Group Admins), 39002 (Group Members) to EVENT_KINDS so kind badge displays proper names - Simplify GroupMetadataRenderer to show only title, description, and Open Chat CTA (remove group picture) --- .../nostr/kinds/GroupMetadataRenderer.tsx | 57 ++++++------------- src/constants/kinds.ts | 21 +++++++ 2 files changed, 37 insertions(+), 41 deletions(-) diff --git a/src/components/nostr/kinds/GroupMetadataRenderer.tsx b/src/components/nostr/kinds/GroupMetadataRenderer.tsx index d7b23f0..461d8f6 100644 --- a/src/components/nostr/kinds/GroupMetadataRenderer.tsx +++ b/src/components/nostr/kinds/GroupMetadataRenderer.tsx @@ -20,7 +20,6 @@ export function GroupMetadataRenderer({ event }: GroupMetadataRendererProps) { const groupId = getTagValue(event, "d") || ""; const name = getTagValue(event, "name") || groupId; const about = getTagValue(event, "about"); - const picture = getTagValue(event, "picture"); // Get relay URL from where we saw this event const seenRelaysSet = getSeenRelays(event); @@ -43,48 +42,24 @@ export function GroupMetadataRenderer({ event }: GroupMetadataRendererProps) { return ( -
- {/* Group Picture */} -
- {picture ? ( - {name} - ) : ( -
- -
- )} -
+
+ + {name} + - {/* Group Info */} -
- - {name} - + {about && ( +

{about}

+ )} - {about && ( -

- {about} -

- )} - - {/* Open Chat Link */} - {canOpenChat && ( - - )} -
+ {canOpenChat && ( + + )}
); diff --git a/src/constants/kinds.ts b/src/constants/kinds.ts index 9bc78e6..fd62988 100644 --- a/src/constants/kinds.ts +++ b/src/constants/kinds.ts @@ -1415,6 +1415,27 @@ export const EVENT_KINDS: Record = { nip: "51", icon: Play, }, + 39000: { + kind: 39000, + name: "Group", + description: "Group Metadata", + nip: "29", + icon: Users, + }, + 39001: { + kind: 39001, + name: "Group Admins", + description: "Group Admins List", + nip: "29", + icon: UserCheck, + }, + 39002: { + kind: 39002, + name: "Group Members", + description: "Group Members List", + nip: "29", + icon: Users, + }, 39701: { kind: 39701, name: "Web Bookmark",