feat: option to hide alt indicator closes #1410
This commit is contained in:
parent
87496e01af
commit
4a74b16d24
|
@ -87,6 +87,8 @@ useIntersectionObserver(video, (entries) => {
|
|||
}
|
||||
})
|
||||
}, { threshold: 0.75 })
|
||||
|
||||
const userSettings = useUserSettings()
|
||||
</script>
|
||||
|
||||
<template>
|
||||
|
@ -167,7 +169,7 @@ useIntersectionObserver(video, (entries) => {
|
|||
/>
|
||||
</button>
|
||||
</template>
|
||||
<div v-if="attachment.description" :class="isAudio ? '' : 'absolute left-2 bottom-2'">
|
||||
<div v-if="attachment.description && !getPreferences(userSettings, 'hideAltIndicatorOnPosts')" :class="isAudio ? '' : 'absolute left-2 bottom-2'">
|
||||
<VDropdown :distance="6" placement="bottom-start">
|
||||
<button
|
||||
font-bold text-sm
|
||||
|
|
|
@ -8,6 +8,7 @@ export type OldFontSize = 'xs' | 'sm' | 'md' | 'lg' | 'xl'
|
|||
export type ColorMode = 'light' | 'dark' | 'system'
|
||||
|
||||
export interface PreferencesSettings {
|
||||
hideAltIndicatorOnPosts: boolean
|
||||
hideBoostCount: boolean
|
||||
hideReplyCount: boolean
|
||||
hideFavoriteCount: boolean
|
||||
|
@ -65,6 +66,7 @@ export function getDefaultUserSettings(locales: string[]): UserSettings {
|
|||
}
|
||||
|
||||
export const DEFAULT__PREFERENCES_SETTINGS: PreferencesSettings = {
|
||||
hideAltIndicatorOnPosts: false,
|
||||
hideBoostCount: false,
|
||||
hideReplyCount: false,
|
||||
hideFavoriteCount: false,
|
||||
|
|
|
@ -400,6 +400,7 @@
|
|||
"github_cards": "GitHub Cards",
|
||||
"grayscale_mode": "Grayscale mode",
|
||||
"hide_account_hover_card": "Hide account hover card",
|
||||
"hide_alt_indi_on_posts": "Hide alt indicator on posts",
|
||||
"hide_boost_count": "Hide boost count",
|
||||
"hide_favorite_count": "Hide favorite count",
|
||||
"hide_follower_count": "Hide follower count",
|
||||
|
|
|
@ -15,6 +15,12 @@ const userSettings = useUserSettings()
|
|||
{{ $t('settings.preferences.label') }}
|
||||
</h1>
|
||||
</template>
|
||||
<SettingsToggleItem
|
||||
:checked="getPreferences(userSettings, 'hideAltIndicatorOnPosts')"
|
||||
@click="togglePreferences('hideAltIndicatorOnPosts')"
|
||||
>
|
||||
{{ $t('settings.preferences.hide_alt_indi_on_posts') }}
|
||||
</SettingsToggleItem>
|
||||
<SettingsToggleItem
|
||||
:checked="getPreferences(userSettings, 'hideBoostCount')"
|
||||
@click="togglePreferences('hideBoostCount')"
|
||||
|
|
Loading…
Reference in a new issue