chore: account link

pull/21/head
Anthony Fu 2022-11-21 18:16:04 +08:00
rodzic 2267ca6122
commit 89845517e3
2 zmienionych plików z 6 dodań i 5 usunięć

Wyświetl plik

@ -1,19 +1,20 @@
<script setup lang="ts">
import type { Account } from 'masto'
defineProps<{
const { link = true } = defineProps<{
account: Account
link?: boolean
}>()
</script>
<template>
<div flex gap-2>
<div p1>
<NuxtLink :to="`/@${account.acct}`">
<NuxtLink :to="link ? `/@${account.acct}` : null">
<img :src="account.avatar" rounded w-10 h-10 bg-gray:10>
</NuxtLink>
</div>
<NuxtLink flex flex-col :to="`/@${account.acct}`">
<NuxtLink flex flex-col :to="link ? `/@${account.acct}` : null">
<CommonRichContent font-bold :content="account.displayName" />
<p op35 text-sm>
@{{ account.acct }}

Wyświetl plik

@ -7,8 +7,8 @@ defineProps<{
</script>
<template>
<a :href="`/@${account.acct}`" flex gap-2 font-bold items-center>
<NuxtLink :href="`/@${account.acct}`" flex gap-2 font-bold items-center>
<img :src="account.avatar" class="w-5 h-5 rounded">
<CommonRichContent :content="account.displayName" />
</a>
</NuxtLink>
</template>