feat: zapstr previews

This commit is contained in:
2023-05-15 12:35:47 +01:00
parent 6344a4356a
commit ed6461fbc8
4 changed files with 38 additions and 5 deletions

View File

@ -0,0 +1,11 @@
import useEventFeed from "Feed/EventFeed";
import Spinner from "Icons/Spinner";
import { NostrLink } from "Util";
import Text from "./Text";
export default function ZapstrEmbed({ link }: { link: NostrLink }) {
const ev = useEventFeed(link);
if (!ev.data) return <Spinner />;
return <Text content={ev.data.content ?? ""} tags={[]} creator={ev.data.pubkey} />;
}