This commit is contained in:
Henry Jameson 2022-02-28 18:23:32 +02:00
parent 39909c8a85
commit 77bb0b5530
10 changed files with 168 additions and 74 deletions

View file

@ -81,56 +81,56 @@
<button <button
v-if="type === 'flash' && flashLoaded" v-if="type === 'flash' && flashLoaded"
class="button-unstyled attachment-button" class="button-unstyled attachment-button"
@click.prevent="stopFlash"
:title="$t('status.attachment_stop_flash')" :title="$t('status.attachment_stop_flash')"
@click.prevent="stopFlash"
> >
<FAIcon icon="stop" /> <FAIcon icon="stop" />
</button> </button>
<button <button
v-if="attachment.description && size !== 'small' && !edit && type !== 'unknown'" v-if="attachment.description && size !== 'small' && !edit && type !== 'unknown'"
class="button-unstyled attachment-button" class="button-unstyled attachment-button"
@click.prevent="toggleDescription"
:title="$t('status.show_attachment_description')" :title="$t('status.show_attachment_description')"
@click.prevent="toggleDescription"
> >
<FAIcon icon="align-right" /> <FAIcon icon="align-right" />
</button> </button>
<button <button
v-if="!useModal && type !== 'unknown'" v-if="!useModal && type !== 'unknown'"
class="button-unstyled attachment-button" class="button-unstyled attachment-button"
@click.prevent="openModalForce"
:title="$t('status.show_attachment_in_modal')" :title="$t('status.show_attachment_in_modal')"
@click.prevent="openModalForce"
> >
<FAIcon icon="search-plus" /> <FAIcon icon="search-plus" />
</button> </button>
<button <button
v-if="nsfw && hideNsfwLocal" v-if="nsfw && hideNsfwLocal"
class="button-unstyled attachment-button" class="button-unstyled attachment-button"
@click.prevent="toggleHidden"
:title="$t('status.hide_attachment')" :title="$t('status.hide_attachment')"
@click.prevent="toggleHidden"
> >
<FAIcon icon="times" /> <FAIcon icon="times" />
</button> </button>
<button <button
v-if="shiftUp" v-if="shiftUp"
class="button-unstyled attachment-button" class="button-unstyled attachment-button"
@click.prevent="onShiftUp"
:title="$t('status.move_up')" :title="$t('status.move_up')"
@click.prevent="onShiftUp"
> >
<FAIcon icon="chevron-left" /> <FAIcon icon="chevron-left" />
</button> </button>
<button <button
v-if="shiftDn" v-if="shiftDn"
class="button-unstyled attachment-button" class="button-unstyled attachment-button"
@click.prevent="onShiftDn"
:title="$t('status.move_down')" :title="$t('status.move_down')"
@click.prevent="onShiftDn"
> >
<FAIcon icon="chevron-right" /> <FAIcon icon="chevron-right" />
</button> </button>
<button <button
v-if="remove" v-if="remove"
class="button-unstyled attachment-button" class="button-unstyled attachment-button"
@click.prevent="onRemove"
:title="$t('status.remove_attachment')" :title="$t('status.remove_attachment')"
@click.prevent="onRemove"
> >
<FAIcon icon="trash-alt" /> <FAIcon icon="trash-alt" />
</button> </button>
@ -160,7 +160,10 @@
:href="attachment.url" :href="attachment.url"
target="_blank" target="_blank"
> >
<FAIcon size="5x" :icon="placeholderIconClass" /> <FAIcon
size="5x"
:icon="placeholderIconClass"
/>
<p> <p>
{{ localDescription }} {{ localDescription }}
</p> </p>

View file

@ -26,8 +26,8 @@
:size="size" :size="size"
:editable="editable" :editable="editable"
:remove="removeAttachment" :remove="removeAttachment"
:shiftUp="!(attachmentIndex === 0 && rowIndex === 0) && shiftUpAttachment" :shift-up="!(attachmentIndex === 0 && rowIndex === 0) && shiftUpAttachment"
:shiftDn="!(attachmentIndex === row.items.length - 1 && rowIndex === rows.length - 1) && shiftDnAttachment" :shift-dn="!(attachmentIndex === row.items.length - 1 && rowIndex === rows.length - 1) && shiftDnAttachment"
:edit="editAttachment" :edit="editAttachment"
:description="descriptions && descriptions[attachment.id]" :description="descriptions && descriptions[attachment.id]"
:hide-description="size === 'small' || tooManyAttachments && hidingLong" :hide-description="size === 'small' || tooManyAttachments && hidingLong"

View file

@ -1,7 +1,7 @@
<template> <template>
<label <label
class="BooleanSetting"
v-if="matchesExpertLevel" v-if="matchesExpertLevel"
class="BooleanSetting"
> >
<Checkbox <Checkbox
:checked="state" :checked="state"
@ -14,7 +14,7 @@
> >
<slot /> <slot />
</span> </span>
<ModifiedIndicator :changed="isChanged" /><ServerSideIndicator :serverSide="isServerSide" /> </Checkbox> <ModifiedIndicator :changed="isChanged" /><ServerSideIndicator :server-side="isServerSide" /> </Checkbox>
</label> </label>
</template> </template>

View file

@ -1,7 +1,7 @@
<template> <template>
<label <label
class="ChoiceSetting"
v-if="matchesExpertLevel" v-if="matchesExpertLevel"
class="ChoiceSetting"
> >
<slot /> <slot />
<Select <Select
@ -19,7 +19,7 @@
</option> </option>
</Select> </Select>
<ModifiedIndicator :changed="isChanged" /> <ModifiedIndicator :changed="isChanged" />
<ServerSideIndicator :serverSide="isServerSide" /> <ServerSideIndicator :server-side="isServerSide" />
</label> </label>
</template> </template>

View file

@ -109,8 +109,8 @@
</template> </template>
</Popover> </Popover>
<Checkbox v-model="expertLevel" > <Checkbox v-model="expertLevel">
{{ $t("settings.expert_mode")}} {{ $t("settings.expert_mode") }}
</Checkbox> </Checkbox>
</div> </div>
</div> </div>

View file

@ -21,8 +21,8 @@
</li> </li>
<li> <li>
<BooleanSetting <BooleanSetting
:disabled="hideFilteredStatuses"
v-if="user" v-if="user"
:disabled="hideFilteredStatuses"
path="hideMutedThreads" path="hideMutedThreads"
> >
{{ $t('settings.hide_muted_threads') }} {{ $t('settings.hide_muted_threads') }}
@ -30,8 +30,8 @@
</li> </li>
<li> <li>
<BooleanSetting <BooleanSetting
:disabled="hideFilteredStatuses"
v-if="user" v-if="user"
:disabled="hideFilteredStatuses"
path="hideMutedPosts" path="hideMutedPosts"
> >
{{ $t('settings.hide_muted_posts') }} {{ $t('settings.hide_muted_posts') }}
@ -40,15 +40,18 @@
</ul> </ul>
</li> </li>
<li> <li>
<BooleanSetting path="hidePostStats" expert="1"> <BooleanSetting
path="hidePostStats"
expert="1"
>
{{ $t('settings.hide_post_stats') }} {{ $t('settings.hide_post_stats') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
<ChoiceSetting <ChoiceSetting
v-if="user"
id="replyVisibility" id="replyVisibility"
path="replyVisibility" path="replyVisibility"
:options="replyVisibilityOptions" :options="replyVisibilityOptions"
v-if="user"
> >
{{ $t('settings.replies_in_timeline') }} {{ $t('settings.replies_in_timeline') }}
</ChoiceSetting> </ChoiceSetting>
@ -87,7 +90,10 @@
</li> </li>
</ul> </ul>
</div> </div>
<div class="setting-item" v-if="expertLevel > 0"> <div
v-if="expertLevel > 0"
class="setting-item"
>
<h2>{{ $t('settings.user_profiles') }}</h2> <h2>{{ $t('settings.user_profiles') }}</h2>
<ul class="setting-list"> <ul class="setting-list">
<li> <li>

View file

@ -41,7 +41,7 @@ const GeneralTab = {
ChoiceSetting, ChoiceSetting,
InterfaceLanguageSwitcher, InterfaceLanguageSwitcher,
ScopeSelector, ScopeSelector,
ServerSideIndicator, ServerSideIndicator
}, },
computed: { computed: {
postFormats () { postFormats () {

View file

@ -27,7 +27,7 @@
</BooleanSetting> </BooleanSetting>
</li> </li>
<li> <li>
<BooleanSetting path="streaming" > <BooleanSetting path="streaming">
{{ $t('settings.streaming') }} {{ $t('settings.streaming') }}
</BooleanSetting> </BooleanSetting>
<ul <ul
@ -45,7 +45,10 @@
</ul> </ul>
</li> </li>
<li> <li>
<BooleanSetting path="useStreamingApi" expert="1"> <BooleanSetting
path="useStreamingApi"
expert="1"
>
{{ $t('settings.useStreamingApi') }} {{ $t('settings.useStreamingApi') }}
<br> <br>
<small> <small>
@ -54,22 +57,34 @@
</BooleanSetting> </BooleanSetting>
</li> </li>
<li> <li>
<BooleanSetting path="virtualScrolling" expert="1"> <BooleanSetting
path="virtualScrolling"
expert="1"
>
{{ $t('settings.virtual_scrolling') }} {{ $t('settings.virtual_scrolling') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
<li> <li>
<BooleanSetting path="alwaysShowNewPostButton" expert="1"> <BooleanSetting
path="alwaysShowNewPostButton"
expert="1"
>
{{ $t('settings.always_show_post_button') }} {{ $t('settings.always_show_post_button') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
<li> <li>
<BooleanSetting path="autohideFloatingPostButton" expert="1"> <BooleanSetting
path="autohideFloatingPostButton"
expert="1"
>
{{ $t('settings.autohide_floating_post_button') }} {{ $t('settings.autohide_floating_post_button') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
<li v-if="instanceShoutboxPresent"> <li v-if="instanceShoutboxPresent">
<BooleanSetting path="hideShoutbox" expert="1"> <BooleanSetting
path="hideShoutbox"
expert="1"
>
{{ $t('settings.hide_shoutbox') }} {{ $t('settings.hide_shoutbox') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
@ -84,18 +99,28 @@
</BooleanSetting> </BooleanSetting>
</li> </li>
<li> <li>
<BooleanSetting path="emojiReactionsOnTimeline" expert="1"> <BooleanSetting
path="emojiReactionsOnTimeline"
expert="1"
>
{{ $t('settings.emoji_reactions_on_timeline') }} {{ $t('settings.emoji_reactions_on_timeline') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
<li> <li>
<BooleanSetting path="serverSide_stripRichContent" expert="1" v-if="user"> <BooleanSetting
v-if="user"
path="serverSide_stripRichContent"
expert="1"
>
{{ $t('settings.no_rich_text_description') }} {{ $t('settings.no_rich_text_description') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
<h3>{{ $t('settings.attachments') }}</h3> <h3>{{ $t('settings.attachments') }}</h3>
<li> <li>
<BooleanSetting path="useContainFit" expert="1"> <BooleanSetting
path="useContainFit"
expert="1"
>
{{ $t('settings.use_contain_fit') }} {{ $t('settings.use_contain_fit') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
@ -107,7 +132,8 @@
<ul class="setting-list suboptions"> <ul class="setting-list suboptions">
<li> <li>
<BooleanSetting <BooleanSetting
path="preloadImage" expert="1" path="preloadImage"
expert="1"
:disabled="!hideNsfw" :disabled="!hideNsfw"
> >
{{ $t('settings.preload_images') }} {{ $t('settings.preload_images') }}
@ -115,7 +141,8 @@
</li> </li>
<li> <li>
<BooleanSetting <BooleanSetting
path="useOneClickNsfw" expert="1" path="useOneClickNsfw"
expert="1"
:disabled="!hideNsfw" :disabled="!hideNsfw"
> >
{{ $t('settings.use_one_click_nsfw') }} {{ $t('settings.use_one_click_nsfw') }}
@ -123,7 +150,10 @@
</li> </li>
</ul> </ul>
<li> <li>
<BooleanSetting path="loopVideo" expert="1"> <BooleanSetting
path="loopVideo"
expert="1"
>
{{ $t('settings.loop_video') }} {{ $t('settings.loop_video') }}
</BooleanSetting> </BooleanSetting>
<ul <ul
@ -132,7 +162,8 @@
> >
<li> <li>
<BooleanSetting <BooleanSetting
path="loopVideoSilentOnly" expert="1" path="loopVideoSilentOnly"
expert="1"
:disabled="!loopVideo || !loopSilentAvailable" :disabled="!loopVideo || !loopSilentAvailable"
> >
{{ $t('settings.loop_video_silent_only') }} {{ $t('settings.loop_video_silent_only') }}
@ -147,7 +178,10 @@
</ul> </ul>
</li> </li>
<li> <li>
<BooleanSetting path="playVideosInModal" expert="1"> <BooleanSetting
path="playVideosInModal"
expert="1"
>
{{ $t('settings.play_videos_in_modal') }} {{ $t('settings.play_videos_in_modal') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
@ -165,51 +199,74 @@
class="setting-list suboptions" class="setting-list suboptions"
> >
<li v-if="mentionLinkDisplay === 'short'"> <li v-if="mentionLinkDisplay === 'short'">
<BooleanSetting path="mentionLinkShowTooltip" expert="1"> <BooleanSetting
path="mentionLinkShowTooltip"
expert="1"
>
{{ $t('settings.mention_link_show_tooltip') }} {{ $t('settings.mention_link_show_tooltip') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
</ul> </ul>
<li>
<BooleanSetting path="useAtIcon" expert="1">
{{ $t('settings.use_at_icon') }}
</BooleanSetting>
</li>
<li>
<BooleanSetting path="mentionLinkShowAvatar">
{{ $t('settings.mention_link_show_avatar') }}
</BooleanSetting>
</li>
<li>
<BooleanSetting path="mentionLinkFadeDomain" expert="1">
{{ $t('settings.mention_link_fade_domain') }}
</BooleanSetting>
</li>
<li v-if="user">
<BooleanSetting path="mentionLinkBoldenYou" expert="1">
{{ $t('settings.mention_link_bolden_you') }}
</BooleanSetting>
</li>
<h3 v-if="expertLevel > 0">{{ $t('settings.fun') }}</h3>
<li> <li>
<BooleanSetting path="greentext" expert="1"> <BooleanSetting
path="useAtIcon"
expert="1"
>
{{ $t('settings.use_at_icon') }}
</BooleanSetting>
</li>
<li>
<BooleanSetting path="mentionLinkShowAvatar">
{{ $t('settings.mention_link_show_avatar') }}
</BooleanSetting>
</li>
<li>
<BooleanSetting
path="mentionLinkFadeDomain"
expert="1"
>
{{ $t('settings.mention_link_fade_domain') }}
</BooleanSetting>
</li>
<li v-if="user">
<BooleanSetting
path="mentionLinkBoldenYou"
expert="1"
>
{{ $t('settings.mention_link_bolden_you') }}
</BooleanSetting>
</li>
<h3 v-if="expertLevel > 0">
{{ $t('settings.fun') }}
</h3>
<li>
<BooleanSetting
path="greentext"
expert="1"
>
{{ $t('settings.greentext') }} {{ $t('settings.greentext') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
<li v-if="user"> <li v-if="user">
<BooleanSetting path="mentionLinkShowYous" expert="1"> <BooleanSetting
path="mentionLinkShowYous"
expert="1"
>
{{ $t('settings.show_yous') }} {{ $t('settings.show_yous') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
</ul> </ul>
</div> </div>
<div class="setting-item" v-if="user"> <div
v-if="user"
class="setting-item"
>
<h2>{{ $t('settings.composing') }}</h2> <h2>{{ $t('settings.composing') }}</h2>
<ul class="setting-list"> <ul class="setting-list">
<li> <li>
<label for="default-vis"> <label for="default-vis">
{{ $t('settings.default_vis') }} <ServerSideIndicator :serverSide="true"/> {{ $t('settings.default_vis') }} <ServerSideIndicator :server-side="true" />
<ScopeSelector <ScopeSelector
class="scope-selector" class="scope-selector"
:show-all="true" :show-all="true"
@ -226,12 +283,18 @@
</BooleanSetting> </BooleanSetting>
</li> </li>
<li> <li>
<BooleanSetting path="scopeCopy" expert="1"> <BooleanSetting
path="scopeCopy"
expert="1"
>
{{ $t('settings.scope_copy') }} {{ $t('settings.scope_copy') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
<li> <li>
<BooleanSetting path="alwaysShowSubjectInput" expert="1"> <BooleanSetting
path="alwaysShowSubjectInput"
expert="1"
>
{{ $t('settings.subject_input_always_show') }} {{ $t('settings.subject_input_always_show') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
@ -255,22 +318,34 @@
</ChoiceSetting> </ChoiceSetting>
</li> </li>
<li> <li>
<BooleanSetting path="minimalScopesMode" expert="1"> <BooleanSetting
path="minimalScopesMode"
expert="1"
>
{{ $t('settings.minimal_scopes_mode') }} {{ $t('settings.minimal_scopes_mode') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
<li> <li>
<BooleanSetting path="alwaysShowNewPostButton" expert="1"> <BooleanSetting
path="alwaysShowNewPostButton"
expert="1"
>
{{ $t('settings.always_show_post_button') }} {{ $t('settings.always_show_post_button') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
<li> <li>
<BooleanSetting path="autohideFloatingPostButton" expert="1"> <BooleanSetting
path="autohideFloatingPostButton"
expert="1"
>
{{ $t('settings.autohide_floating_post_button') }} {{ $t('settings.autohide_floating_post_button') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
<li> <li>
<BooleanSetting path="padEmoji" expert="1"> <BooleanSetting
path="padEmoji"
expert="1"
>
{{ $t('settings.pad_emoji') }} {{ $t('settings.pad_emoji') }}
</BooleanSetting> </BooleanSetting>
</li> </li>

View file

@ -46,16 +46,25 @@
</ul> </ul>
</div> </div>
<div class="setting-item" v-if="expertLevel > 0"> <div
v-if="expertLevel > 0"
class="setting-item"
>
<h2>{{ $t('settings.notification_setting_privacy') }}</h2> <h2>{{ $t('settings.notification_setting_privacy') }}</h2>
<ul class="setting-list"> <ul class="setting-list">
<li> <li>
<BooleanSetting path="webPushNotifications" expert="1"> <BooleanSetting
path="webPushNotifications"
expert="1"
>
{{ $t('settings.enable_web_push_notifications') }} {{ $t('settings.enable_web_push_notifications') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
<li> <li>
<BooleanSetting path="serverSide_webPushHideContents" expert="1"> <BooleanSetting
path="serverSide_webPushHideContents"
expert="1"
>
{{ $t('settings.notification_setting_hide_notification_contents') }} {{ $t('settings.notification_setting_hide_notification_contents') }}
</BooleanSetting> </BooleanSetting>
</li> </li>

View file

@ -101,7 +101,8 @@
<p class="visibility-notice"> <p class="visibility-notice">
{{ $t('settings.avatar_size_instruction') }} {{ $t('settings.avatar_size_instruction') }}
</p> </p>
<div class="current-avatar-container"> <img <div class="current-avatar-container">
<img
:src="user.profile_image_url_original" :src="user.profile_image_url_original"
class="current-avatar" class="current-avatar"
> >
@ -243,7 +244,7 @@
<BooleanSetting <BooleanSetting
path="serverSide_hideFollowersCount" path="serverSide_hideFollowersCount"
:disabled="!serverSide_hideFollowers" :disabled="!serverSide_hideFollowers"
> >
{{ $t('settings.hide_followers_count_description') }} {{ $t('settings.hide_followers_count_description') }}
</BooleanSetting> </BooleanSetting>
</li> </li>
@ -261,7 +262,7 @@
<BooleanSetting <BooleanSetting
path="serverSide_hideFollowsCount" path="serverSide_hideFollowsCount"
:disabled="!serverSide_hideFollows" :disabled="!serverSide_hideFollows"
> >
{{ $t('settings.hide_follows_count_description') }} {{ $t('settings.hide_follows_count_description') }}
</BooleanSetting> </BooleanSetting>
</li> </li>