perf: don't destroy elements when zen mode

closes #834
This commit is contained in:
三咲智子 2023-01-07 22:03:20 +08:00
parent bbc1580010
commit 30e4ef57df
No known key found for this signature in database
GPG Key ID: 69992F2250DFD93E
1 changed files with 2 additions and 4 deletions

View File

@ -138,7 +138,7 @@ const isDM = $computed(() => status.visibility === 'direct')
<StatusReplyingTo :collapsed="true" :status="status" :class="faded ? 'text-secondary-light' : ''" />
</div>
<div flex-auto />
<div v-if="!userSettings.zenMode" text-sm text-secondary flex="~ row nowrap" hover:underline>
<div v-show="!userSettings.zenMode" text-sm text-secondary flex="~ row nowrap" hover:underline>
<AccountBotIndicator v-if="status.account.bot" me-2 />
<div flex>
<CommonTooltip :content="createdAt">
@ -154,9 +154,7 @@ const isDM = $computed(() => status.visibility === 'direct')
<StatusActionsMore v-if="actions !== false" :status="status" me--2 />
</div>
<StatusContent :status="status" :context="context" mb2 :class="{ 'mt-2 mb1': isDM }" />
<div>
<StatusActions v-if="(actions !== false && !userSettings.zenMode)" :status="status" />
</div>
<StatusActions v-if="actions !== false" v-show="!userSettings.zenMode" :status="status" />
</div>
</div>
</div>