mirror of
https://github.com/elk-zone/elk.git
synced 2024-11-05 00:19:59 +00:00
style: spoiler and filter UI improvements (#378)
This commit is contained in:
parent
462e85dad0
commit
deea8c0aab
3 changed files with 8 additions and 8 deletions
|
@ -125,7 +125,9 @@ const avatarOnAvatar = $(computedEager(() => useFeatureFlags().experimentalAvata
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div v-else-if="isFiltered" gap-2 px-4>
|
||||
<p>{{ filterPhrase && `${$t('status.filter_removed_phrase')}: ${filterPhrase}` }}</p>
|
||||
<div v-else-if="isFiltered" gap-2 p-4>
|
||||
<p text-center text-secondary text-sm>
|
||||
{{ filterPhrase && `${$t('status.filter_removed_phrase')}: ${filterPhrase}` }}
|
||||
</p>
|
||||
</div>
|
||||
</template>
|
||||
|
|
|
@ -40,9 +40,9 @@ const visibility = $computed(() => STATUS_VISIBILITIES.find(v => v.value === sta
|
|||
v-if="status.mediaAttachments?.length"
|
||||
:status="status"
|
||||
/>
|
||||
<StatusPreviewCard v-if="status.card" :card="status.card" />
|
||||
</StatusSpoiler>
|
||||
</div>
|
||||
<StatusPreviewCard v-if="status.card" :card="status.card" />
|
||||
<div flex="~ gap-1" items-center text-secondary text-sm>
|
||||
<div flex>
|
||||
<div>{{ createdAt }}</div>
|
||||
|
|
|
@ -11,17 +11,15 @@ watchEffect(() => {
|
|||
|
||||
<template>
|
||||
<div v-if="enabled" flex flex-col items-start>
|
||||
<div class="content-rich">
|
||||
<div class="content-rich" px-4 pb-2 text-center text-secondary text-sm w-full border="~ base" border-0 border-b-dotted border-b-3 mt-2>
|
||||
<slot name="spoiler" />
|
||||
</div>
|
||||
<div flex="~ gap-1 center" w-full>
|
||||
<div border="t base" w-5 h-1px />
|
||||
<button btn-text px-2 py-1 text-3 flex="~ center gap-2" :class="showContent ? '' : 'filter-saturate-0 hover:filter-saturate-100'" @click="toggleContent()">
|
||||
<div flex="~ gap-1 center" w-full mt="-3.5">
|
||||
<button btn-text px-2 py-1 text-3 bg-base flex="~ center gap-2" :class="showContent ? '' : 'filter-saturate-0 hover:filter-saturate-100'" @click="toggleContent()">
|
||||
<div v-if="showContent" i-ri:eye-line />
|
||||
<div v-else i-ri:eye-close-line />
|
||||
{{ showContent ? $t('status.spoiler_show_less') : $t(filter ? 'status.filter_show_anyway' : 'status.spoiler_show_more') }}
|
||||
</button>
|
||||
<div border="t base" flex-auto h-1px />
|
||||
</div>
|
||||
</div>
|
||||
<slot v-if="!enabled || showContent" />
|
||||
|
|
Loading…
Reference in a new issue