feat: badges
- render badges in cards - render mentioned badges in chat - render host badge awards in chat - render accepted badges next to username
This commit is contained in:
@ -1,8 +1,9 @@
|
||||
import { type NostrLink } from "@snort/system";
|
||||
import { type NostrLink, EventKind } from "@snort/system";
|
||||
|
||||
import { useEvent } from "hooks/event";
|
||||
import { EMOJI_PACK } from "const";
|
||||
import { EmojiPack } from "element/emoji-pack";
|
||||
import { Badge } from "element/badge";
|
||||
|
||||
interface AddressProps {
|
||||
link: NostrLink;
|
||||
@ -15,5 +16,9 @@ export function Address({ link }: AddressProps) {
|
||||
return <EmojiPack ev={event} />;
|
||||
}
|
||||
|
||||
if (event?.kind === EventKind.Badge) {
|
||||
return <Badge ev={event} />;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
Reference in New Issue
Block a user