mirror of
https://github.com/elk-zone/elk.git
synced 2024-11-09 10:29:57 +00:00
1d9bd6a9d4
relate PR #557
33 lines
806 B
Vue
33 lines
806 B
Vue
<script setup lang="ts">
|
|
import type { Status } from 'masto'
|
|
|
|
const { status, withAction = true } = defineProps<{
|
|
status: Status
|
|
withAction?: boolean
|
|
}>()
|
|
const { translation } = useTranslation(status)
|
|
</script>
|
|
|
|
<template>
|
|
<div class="status-body" whitespace-pre-wrap break-words :class="{ 'with-action': withAction }">
|
|
<ContentRich
|
|
v-if="status.content"
|
|
class="line-compact"
|
|
:content="status.content"
|
|
:emojis="status.emojis"
|
|
:lang="status.language"
|
|
/>
|
|
<div v-else />
|
|
<template v-if="translation.visible">
|
|
<div my2 h-px border="b base" bg-base />
|
|
<ContentRich class="line-compact" :content="translation.text" :emojis="status.emojis" />
|
|
</template>
|
|
</div>
|
|
</template>
|
|
|
|
<style>
|
|
.status-body.with-action p {
|
|
cursor: pointer;
|
|
}
|
|
</style>
|