import { Image } from "@shared/image"; import { DEFAULT_AVATAR, IMGPROXY_URL } from "@stores/constants"; import { useProfile } from "@utils/hooks/useProfile"; import { shortenKey } from "@utils/shortenKey"; import { Popover, Transition } from "@headlessui/react"; import dayjs from "dayjs"; import relativeTime from "dayjs/plugin/relativeTime"; import { Fragment } from "react"; dayjs.extend(relativeTime); export function NoteRepostUser({ pubkey, time, }: { pubkey: string; time: number }) { const { user } = useProfile(pubkey); return ( {pubkey}
{user?.display_name || user?.name || (
)} {" "} reposted
ยท {dayjs().to(dayjs.unix(time), true)}
e.stopPropagation()} onKeyDown={(e) => e.stopPropagation()} className="w-full max-w-xs overflow-hidden rounded-lg border border-zinc-700 bg-zinc-900 shadow-input ring-1 ring-black ring-opacity-5" >
{pubkey}
{user?.display_name || user?.name || (
)}
{user?.nip05 || shortenKey(pubkey)}

{user?.about}

View full profile Message
); }