fix: spacing of status card without content

zio/stable
patak 2022-11-26 20:06:07 +01:00
parent 03785846eb
commit 2d16c4868e
1 changed files with 4 additions and 2 deletions

View File

@ -6,14 +6,16 @@ const { status, withAction = true } = defineProps<{
withAction?: boolean withAction?: boolean
}>() }>()
const { translation } = useTranslation(status) const { translation } = useTranslation(status)
const content = $computed(() => translation.visible ? translation.text : status.content)
</script> </script>
<template> <template>
<div class="status-body" whitespace-pre-wrap break-words :class="{ 'with-action': withAction }"> <div class="status-body" whitespace-pre-wrap break-words :class="{ 'with-action': withAction }">
<ContentRich <ContentRich v-if="content"
:content="translation.visible ? translation.text : status.content" :content="content"
:emojis="status.emojis" :emojis="status.emojis"
/> />
<div v-else h-3 />
</div> </div>
</template> </template>