2022-11-23 03:00:52 +03:00
|
|
|
<script setup lang="ts">
|
2023-01-08 09:21:09 +03:00
|
|
|
import type { mastodon } from 'masto'
|
2022-11-23 03:00:52 +03:00
|
|
|
|
2023-01-08 11:27:21 +03:00
|
|
|
const {
|
|
|
|
status,
|
|
|
|
isSelfReply = false,
|
|
|
|
} = defineProps<{
|
2023-01-08 09:21:09 +03:00
|
|
|
status: mastodon.v1.Status
|
2023-01-08 11:27:21 +03:00
|
|
|
isSelfReply: boolean
|
2022-11-23 03:00:52 +03:00
|
|
|
}>()
|
|
|
|
|
2024-02-21 18:20:08 +03:00
|
|
|
const isSelf = computed(() => status.inReplyToAccountId === status.account.id)
|
2024-02-29 23:55:46 +03:00
|
|
|
const account = isSelf.value ? computed(() => status.account) : useAccountById(status.inReplyToAccountId)
|
2022-11-23 03:00:52 +03:00
|
|
|
</script>
|
|
|
|
|
|
|
|
<template>
|
2023-01-08 11:27:21 +03:00
|
|
|
<NuxtLink
|
|
|
|
v-if="status.inReplyToId"
|
|
|
|
flex="~ gap2" items-center h-auto text-sm text-secondary
|
|
|
|
:to="getStatusInReplyToRoute(status)"
|
2023-01-08 12:03:23 +03:00
|
|
|
:title="$t('status.replying_to', [account ? getDisplayName(account) : $t('status.someone')])"
|
|
|
|
text-blue saturate-50 hover:saturate-100
|
2023-01-08 11:27:21 +03:00
|
|
|
>
|
|
|
|
<template v-if="isSelfReply">
|
2023-01-08 12:03:23 +03:00
|
|
|
<div i-ri-discuss-line text-blue />
|
|
|
|
<span>{{ $t('status.show_full_thread') }}</span>
|
2023-01-08 11:27:21 +03:00
|
|
|
</template>
|
|
|
|
<template v-else>
|
2023-01-08 12:03:23 +03:00
|
|
|
<div i-ri-chat-1-line text-blue />
|
2023-02-15 22:21:08 +03:00
|
|
|
<div ws-nowrap flex>
|
|
|
|
<i18n-t keypath="status.replying_to">
|
|
|
|
<template v-if="account">
|
2023-03-20 01:36:09 +03:00
|
|
|
<AccountInlineInfo :account="account" :link="false" m-inline-2 />
|
2023-02-15 22:21:08 +03:00
|
|
|
</template>
|
|
|
|
<template v-else>
|
|
|
|
{{ $t('status.someone') }}
|
|
|
|
</template>
|
|
|
|
</i18n-t>
|
2023-02-07 11:12:30 +03:00
|
|
|
</div>
|
2023-01-08 11:27:21 +03:00
|
|
|
</template>
|
|
|
|
</NuxtLink>
|
2022-11-23 03:00:52 +03:00
|
|
|
</template>
|