fix: move the ALT text button for video attahcments to the top (#2479)

pull/2444/head^2
Alex 2023-11-24 02:19:53 -06:00 zatwierdzone przez GitHub
rodzic 7595162a0e
commit 1f752e65ed
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
1 zmienionych plików z 7 dodań i 1 usunięć

Wyświetl plik

@ -67,6 +67,7 @@ const type = $computed(() => {
const video = ref<HTMLVideoElement | undefined>()
const prefersReducedMotion = usePreferredReducedMotion()
const isAudio = $computed(() => attachment.type === 'audio')
const isVideo = $computed(() => attachment.type === 'video')
const enableAutoplay = usePreferences('enableAutoplay')
@ -246,7 +247,12 @@ watch(shouldLoadAttachment, () => {
/>
</button>
</template>
<div v-if="attachment.description && !getPreferences(userSettings, 'hideAltIndicatorOnPosts')" :class="isAudio ? '' : 'absolute left-2 bottom-2'">
<div
v-if="attachment.description && !getPreferences(userSettings, 'hideAltIndicatorOnPosts')" :class="isAudio ? [] : [
'absolute left-2',
isVideo ? 'top-2' : 'bottom-2',
]"
>
<VDropdown :distance="6" placement="bottom-start">
<button
font-bold text-sm