1
0
mirror of https://github.com/elk-zone/elk synced 2024-11-27 22:38:11 +09:00
elk/components/account/AccountHandle.vue

18 lines
557 B
Vue
Raw Normal View History

<script setup lang="ts">
2023-01-08 15:21:09 +09:00
import type { mastodon } from 'masto'
const { account } = defineProps<{
2023-01-08 15:21:09 +09:00
account: mastodon.v1.Account
}>()
const serverName = $computed(() => getServerName(account))
</script>
<template>
<p line-clamp-1 whitespace-pre-wrap break-all text-secondary-light leading-tight dir="ltr">
<!-- fix: #274 only line-clamp-1 can be used here, using text-ellipsis is not valid -->
<span text-secondary>{{ getShortHandle(account) }}</span>
<span v-if="serverName" text-secondary-light>@{{ serverName }}</span>
</p>
</template>