2024-10-01 21:55:33 +00:00
|
|
|
<script lang="ts">
|
2025-11-11 21:39:32 +00:00
|
|
|
import {removeUndefined} from "@welshman/lib"
|
2025-10-06 18:23:19 +00:00
|
|
|
import ContentMinimal from "@app/components/ContentMinimal.svelte"
|
2026-07-28 16:16:26 +00:00
|
|
|
import {profiles} from "@app/core"
|
2024-10-01 21:55:33 +00:00
|
|
|
|
2025-04-15 18:03:27 +00:00
|
|
|
export type Props = {
|
|
|
|
|
pubkey: string
|
2026-06-22 20:36:57 +00:00
|
|
|
singleLine?: boolean
|
2025-04-15 18:03:27 +00:00
|
|
|
url?: string
|
|
|
|
|
}
|
2024-10-01 21:55:33 +00:00
|
|
|
|
2026-06-22 20:36:57 +00:00
|
|
|
const {pubkey, url, singleLine}: Props = $props()
|
2025-04-15 18:03:27 +00:00
|
|
|
|
2026-07-28 16:16:26 +00:00
|
|
|
const profile = $profiles.one(pubkey, removeUndefined([url]))
|
2024-10-01 21:55:33 +00:00
|
|
|
</script>
|
|
|
|
|
|
2025-04-15 22:45:48 +00:00
|
|
|
{#if $profile}
|
2026-07-28 16:16:26 +00:00
|
|
|
<ContentMinimal event={{content: $profile.about() || "", tags: []}} {singleLine} />
|
2024-10-01 21:55:33 +00:00
|
|
|
{/if}
|