import { DEFAULT_AVATAR } from '@stores/constants'; import { useProfileMetadata } from '@utils/hooks/useProfileMetadata'; import { shortenKey } from '@utils/shortenKey'; import dayjs from 'dayjs'; import relativeTime from 'dayjs/plugin/relativeTime'; import { MoreHoriz } from 'iconoir-react'; dayjs.extend(relativeTime); export const UserLarge = ({ pubkey, time }: { pubkey: string; time: number }) => { const profile = useProfileMetadata(pubkey); return (
{pubkey}
{profile?.display_name || profile?.name || shortenKey(pubkey)} {profile?.username || shortenKey(pubkey)} ยท {dayjs().to(dayjs.unix(time))}
); };