mirror of
https://github.com/elk-zone/elk
synced 2024-12-28 13:37:59 +09:00
28 lines
628 B
Vue
28 lines
628 B
Vue
<script setup lang="ts">
|
|
import type { Status } from 'masto'
|
|
|
|
const { status, withAction = true } = defineProps<{
|
|
status: Status
|
|
withAction?: boolean
|
|
}>()
|
|
const { translation } = useTranslation(status)
|
|
const content = $computed(() => translation.visible ? translation.text : status.content)
|
|
</script>
|
|
|
|
<template>
|
|
<div class="status-body" whitespace-pre-wrap break-words :class="{ 'with-action': withAction }">
|
|
<ContentRich
|
|
v-if="content"
|
|
:content="content"
|
|
:emojis="status.emojis"
|
|
/>
|
|
<div v-else h-3 />
|
|
</div>
|
|
</template>
|
|
|
|
<style>
|
|
.status-body.with-action p {
|
|
cursor: pointer;
|
|
}
|
|
</style>
|