mirror of
https://github.com/aljazceru/rabbit.git
synced 2025-12-19 06:54:23 +01:00
update
This commit is contained in:
@@ -19,17 +19,25 @@ const DeprecatedRepost: Component<DeprecatedRepostProps> = (props) => {
|
||||
const eventId = () => props.event.tags.find(([tagName]) => tagName === 'e')?.[1];
|
||||
|
||||
const { profile } = useProfile(() => ({ relayUrls: config().relayUrls, pubkey: pubkey() }));
|
||||
const { event } = useEvent(() => ({ relayUrls: config().relayUrls, eventId: eventId() }));
|
||||
const { event, query: eventQuery } = useEvent(() => ({
|
||||
relayUrls: config().relayUrls,
|
||||
eventId: eventId(),
|
||||
}));
|
||||
|
||||
return (
|
||||
<div>
|
||||
<div class="flex content-center px-1 text-xs">
|
||||
<div class="h-5 w-5 pr-1 text-green-500" aria-hidden="true">
|
||||
<div class="flex content-center px-1 text-xs">
|
||||
<div class="h-5 w-5 shrink-0 pr-1 text-green-500" aria-hidden="true">
|
||||
<ArrowPathRoundedSquare />
|
||||
</div>
|
||||
<div>{profile()?.display_name} Reposted</div>
|
||||
<div class="truncate">
|
||||
<Show when={(profile()?.display_name?.length ?? 0) > 0} fallback={props.event.pubkey}>
|
||||
{profile()?.display_name}
|
||||
</Show>
|
||||
{' Reposted'}
|
||||
</div>
|
||||
</div>
|
||||
<Show when={event() != null} fallback={'loading'}>
|
||||
<Show when={event() != null} fallback={<Show when={eventQuery.isLoading}>loading</Show>}>
|
||||
<TextNote event={event()} />
|
||||
</Show>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user