2025-02-12 00:00:14 +00:00
|
|
|
<script lang="ts">
|
|
|
|
|
import {fromPairs} from "@welshman/lib"
|
|
|
|
|
import type {TrustedEvent} from "@welshman/util"
|
|
|
|
|
import Icon from "@lib/components/Icon.svelte"
|
|
|
|
|
import ProfileLink from "@app/components/ProfileLink.svelte"
|
|
|
|
|
|
|
|
|
|
type Props = {
|
|
|
|
|
event: TrustedEvent
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const {event}: Props = $props()
|
|
|
|
|
const meta = $derived(fromPairs(event.tags) as Record<string, string>)
|
|
|
|
|
</script>
|
|
|
|
|
|
2025-03-17 16:53:14 +00:00
|
|
|
<div class="flex min-w-0 flex-col gap-1 text-sm opacity-75">
|
2025-02-12 00:00:14 +00:00
|
|
|
<span class="flex items-center gap-1">
|
2025-03-17 16:53:14 +00:00
|
|
|
<Icon icon="user-circle" size={4} />
|
|
|
|
|
Posted by <ProfileLink pubkey={event.pubkey} />
|
2025-02-12 00:00:14 +00:00
|
|
|
</span>
|
2025-03-17 16:53:14 +00:00
|
|
|
{#if meta.location}
|
|
|
|
|
<span class="ellipsize flex items-center gap-1 whitespace-nowrap">
|
|
|
|
|
<Icon icon="map-point" size={4} />
|
|
|
|
|
{meta.location}
|
|
|
|
|
</span>
|
|
|
|
|
{/if}
|
|
|
|
|
</div>
|