This commit is contained in:
syuilo
2025-03-03 10:26:49 +09:00
parent 6084f23d83
commit bb812ed07a
2 changed files with 72 additions and 132 deletions

View File

@@ -13,98 +13,73 @@ SPDX-License-Identifier: AGPL-3.0-only
</MkSwitch> </MkSwitch>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['follow', 'auto', 'accept']">
:label="i18n.ts.autoAcceptFollowed" <MkSwitch v-if="isLocked" v-model="autoAcceptFollowed" @update:modelValue="save()">
:keywords="['follow', 'auto', 'accept']" <template #label><SearchLabel>{{ i18n.ts.autoAcceptFollowed }}</SearchLabel></template>
> </MkSwitch>
<MkSwitch v-if="isLocked" v-model="autoAcceptFollowed" @update:modelValue="save()">{{ i18n.ts.autoAcceptFollowed }}</MkSwitch>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['reaction', 'public']">
:label="i18n.ts.makeReactionsPublic"
:keywords="['reaction', 'public', i18n.ts.makeReactionsPublicDescription]"
>
<MkSwitch v-model="publicReactions" @update:modelValue="save()"> <MkSwitch v-model="publicReactions" @update:modelValue="save()">
{{ i18n.ts.makeReactionsPublic }} <template #label><SearchLabel>{{ i18n.ts.makeReactionsPublic }}</SearchLabel></template>
<template #caption>{{ i18n.ts.makeReactionsPublicDescription }}</template> <template #caption><SearchKeyword>{{ i18n.ts.makeReactionsPublicDescription }}</SearchKeyword></template>
</MkSwitch> </MkSwitch>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['following', 'visibility']">
:label="i18n.ts.followingVisibility"
:keywords="['following', 'visibility']"
>
<MkSelect v-model="followingVisibility" @update:modelValue="save()"> <MkSelect v-model="followingVisibility" @update:modelValue="save()">
<template #label>{{ i18n.ts.followingVisibility }}</template> <template #label><SearchLabel>{{ i18n.ts.followingVisibility }}</SearchLabel></template>
<option value="public">{{ i18n.ts._ffVisibility.public }}</option> <option value="public">{{ i18n.ts._ffVisibility.public }}</option>
<option value="followers">{{ i18n.ts._ffVisibility.followers }}</option> <option value="followers">{{ i18n.ts._ffVisibility.followers }}</option>
<option value="private">{{ i18n.ts._ffVisibility.private }}</option> <option value="private">{{ i18n.ts._ffVisibility.private }}</option>
</MkSelect> </MkSelect>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['follower', 'visibility']">
:label="i18n.ts.followersVisibility"
:keywords="['follower', 'visibility']"
>
<MkSelect v-model="followersVisibility" @update:modelValue="save()"> <MkSelect v-model="followersVisibility" @update:modelValue="save()">
<template #label>{{ i18n.ts.followersVisibility }}</template> <template #label><SearchLabel>{{ i18n.ts.followersVisibility }}</SearchLabel></template>
<option value="public">{{ i18n.ts._ffVisibility.public }}</option> <option value="public">{{ i18n.ts._ffVisibility.public }}</option>
<option value="followers">{{ i18n.ts._ffVisibility.followers }}</option> <option value="followers">{{ i18n.ts._ffVisibility.followers }}</option>
<option value="private">{{ i18n.ts._ffVisibility.private }}</option> <option value="private">{{ i18n.ts._ffVisibility.private }}</option>
</MkSelect> </MkSelect>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['online', 'status']">
:label="i18n.ts.hideOnlineStatus"
:keywords="['online', 'status', i18n.ts.hideOnlineStatusDescription]"
>
<MkSwitch v-model="hideOnlineStatus" @update:modelValue="save()"> <MkSwitch v-model="hideOnlineStatus" @update:modelValue="save()">
{{ i18n.ts.hideOnlineStatus }} <template #label><SearchLabel>{{ i18n.ts.hideOnlineStatus }}</SearchLabel></template>
<template #caption>{{ i18n.ts.hideOnlineStatusDescription }}</template> <template #caption><SearchKeyword>{{ i18n.ts.hideOnlineStatusDescription }}</SearchKeyword></template>
</MkSwitch> </MkSwitch>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['crawle', 'index', 'search']">
:label="i18n.ts.noCrawle"
:keywords="['crawle', 'index', 'search', i18n.ts.noCrawleDescription]"
>
<MkSwitch v-model="noCrawle" @update:modelValue="save()"> <MkSwitch v-model="noCrawle" @update:modelValue="save()">
{{ i18n.ts.noCrawle }} <template #label><SearchLabel>{{ i18n.ts.noCrawle }}</SearchLabel></template>
<template #caption>{{ i18n.ts.noCrawleDescription }}</template> <template #caption><SearchKeyword>{{ i18n.ts.noCrawleDescription }}</SearchKeyword></template>
</MkSwitch> </MkSwitch>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['crawle', 'ai']">
:label="i18n.ts.preventAiLearning"
:keywords="['crawle', 'ai', i18n.ts.preventAiLearningDescription]"
>
<MkSwitch v-model="preventAiLearning" @update:modelValue="save()"> <MkSwitch v-model="preventAiLearning" @update:modelValue="save()">
{{ i18n.ts.preventAiLearning }} <template #label><SearchLabel>{{ i18n.ts.preventAiLearning }}</SearchLabel></template>
<template #caption>{{ i18n.ts.preventAiLearningDescription }}</template> <template #caption><SearchKeyword>{{ i18n.ts.preventAiLearningDescription }}</SearchKeyword></template>
</MkSwitch> </MkSwitch>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['explore']">
:label="i18n.ts.makeExplorable"
:keywords="['explore', i18n.ts.makeExplorableDescription]"
>
<MkSwitch v-model="isExplorable" @update:modelValue="save()"> <MkSwitch v-model="isExplorable" @update:modelValue="save()">
{{ i18n.ts.makeExplorable }} <template #label><SearchLabel>{{ i18n.ts.makeExplorable }}</SearchLabel></template>
<template #caption>{{ i18n.ts.makeExplorableDescription }}</template> <template #caption><SearchKeyword>{{ i18n.ts.makeExplorableDescription }}</SearchKeyword></template>
</MkSwitch> </MkSwitch>
</SearchMarker> </SearchMarker>
<SearchMarker :label="i18n.ts.lockdown" :keywords="['lockdown']"> <SearchMarker :keywords="['lockdown']">
<FormSection> <FormSection>
<template #label>{{ i18n.ts.lockdown }}<span class="_beta">{{ i18n.ts.beta }}</span></template> <template #label><SearchLabel>{{ i18n.ts.lockdown }}</SearchLabel><span class="_beta">{{ i18n.ts.beta }}</span></template>
<div class="_gaps_m"> <div class="_gaps_m">
<SearchMarker <SearchMarker :keywords="['login', 'signin']">
:label="i18n.ts._accountSettings.requireSigninToViewContents"
:keywords="['login', 'signin', i18n.ts._accountSettings.requireSigninToViewContentsDescription1, i18n.ts._accountSettings.requireSigninToViewContentsDescription2, i18n.ts._accountSettings.requireSigninToViewContentsDescription3]"
>
<MkSwitch :modelValue="requireSigninToViewContents" @update:modelValue="update_requireSigninToViewContents"> <MkSwitch :modelValue="requireSigninToViewContents" @update:modelValue="update_requireSigninToViewContents">
{{ i18n.ts._accountSettings.requireSigninToViewContents }} <template #label><SearchLabel>{{ i18n.ts.requireSigninToViewContents }}</SearchLabel></template>
<template #caption> <template #caption>
<div>{{ i18n.ts._accountSettings.requireSigninToViewContentsDescription1 }}</div> <div>{{ i18n.ts._accountSettings.requireSigninToViewContentsDescription1 }}</div>
<div><i class="ti ti-alert-triangle" style="color: var(--MI_THEME-warn);"></i> {{ i18n.ts._accountSettings.requireSigninToViewContentsDescription2 }}</div> <div><i class="ti ti-alert-triangle" style="color: var(--MI_THEME-warn);"></i> {{ i18n.ts._accountSettings.requireSigninToViewContentsDescription2 }}</div>
@@ -113,12 +88,9 @@ SPDX-License-Identifier: AGPL-3.0-only
</MkSwitch> </MkSwitch>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['follower']">
:label="i18n.ts._accountSettings.makeNotesFollowersOnlyBefore"
:keywords="['follower', i18n.ts._accountSettings.makeNotesFollowersOnlyBeforeDescription]"
>
<FormSlot> <FormSlot>
<template #label>{{ i18n.ts._accountSettings.makeNotesFollowersOnlyBefore }}</template> <template #label><SearchLabel>{{ i18n.ts._accountSettings.makeNotesFollowersOnlyBefore }}</SearchLabel></template>
<div class="_gaps_s"> <div class="_gaps_s">
<MkSelect :modelValue="makeNotesFollowersOnlyBefore_type" @update:modelValue="makeNotesFollowersOnlyBefore = $event === 'relative' ? -604800 : $event === 'absolute' ? Math.floor(Date.now() / 1000) : null"> <MkSelect :modelValue="makeNotesFollowersOnlyBefore_type" @update:modelValue="makeNotesFollowersOnlyBefore = $event === 'relative' ? -604800 : $event === 'absolute' ? Math.floor(Date.now() / 1000) : null">
@@ -148,18 +120,15 @@ SPDX-License-Identifier: AGPL-3.0-only
</div> </div>
<template #caption> <template #caption>
<div>{{ i18n.ts._accountSettings.makeNotesFollowersOnlyBeforeDescription }}</div> <div><SearchKeyword>{{ i18n.ts._accountSettings.makeNotesFollowersOnlyBeforeDescription }}</SearchKeyword></div>
<div v-if="instance.federation !== 'none'"><i class="ti ti-alert-triangle" style="color: var(--MI_THEME-warn);"></i> {{ i18n.ts._accountSettings.mayNotEffectForFederatedNotes }}</div> <div v-if="instance.federation !== 'none'"><i class="ti ti-alert-triangle" style="color: var(--MI_THEME-warn);"></i> {{ i18n.ts._accountSettings.mayNotEffectForFederatedNotes }}</div>
</template> </template>
</FormSlot> </FormSlot>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['hidden']">
:label="i18n.ts._accountSettings.makeNotesHiddenBefore"
:keywords="['hidden', i18n.ts._accountSettings.makeNotesHiddenBeforeDescription]"
>
<FormSlot> <FormSlot>
<template #label>{{ i18n.ts._accountSettings.makeNotesHiddenBefore }}</template> <template #label><SearchLabel>{{ i18n.ts._accountSettings.makeNotesHiddenBefore }}</SearchLabel></template>
<div class="_gaps_s"> <div class="_gaps_s">
<MkSelect :modelValue="makeNotesHiddenBefore_type" @update:modelValue="makeNotesHiddenBefore = $event === 'relative' ? -604800 : $event === 'absolute' ? Math.floor(Date.now() / 1000) : null"> <MkSelect :modelValue="makeNotesHiddenBefore_type" @update:modelValue="makeNotesHiddenBefore = $event === 'relative' ? -604800 : $event === 'absolute' ? Math.floor(Date.now() / 1000) : null">
@@ -189,7 +158,7 @@ SPDX-License-Identifier: AGPL-3.0-only
</div> </div>
<template #caption> <template #caption>
<div>{{ i18n.ts._accountSettings.makeNotesHiddenBeforeDescription }}</div> <div><SearchKeyword>{{ i18n.ts._accountSettings.makeNotesHiddenBeforeDescription }}</SearchKeyword></div>
<div v-if="instance.federation !== 'none'"><i class="ti ti-alert-triangle" style="color: var(--MI_THEME-warn);"></i> {{ i18n.ts._accountSettings.mayNotEffectForFederatedNotes }}</div> <div v-if="instance.federation !== 'none'"><i class="ti ti-alert-triangle" style="color: var(--MI_THEME-warn);"></i> {{ i18n.ts._accountSettings.mayNotEffectForFederatedNotes }}</div>
</template> </template>
</FormSlot> </FormSlot>
@@ -200,19 +169,15 @@ SPDX-License-Identifier: AGPL-3.0-only
<FormSection> <FormSection>
<div class="_gaps_m"> <div class="_gaps_m">
<SearchMarker <SearchMarker :keywords="['remember', 'keep', 'note', 'visibility']">
:label="i18n.ts.rememberNoteVisibility" <MkSwitch v-model="rememberNoteVisibility" @update:modelValue="save()">
:keywords="['remember', 'keep', 'note', 'visibility']" <template #label><SearchLabel>{{ i18n.ts.rememberNoteVisibility }}</SearchLabel></template>
> </MkSwitch>
<MkSwitch v-model="rememberNoteVisibility" @update:modelValue="save()">{{ i18n.ts.rememberNoteVisibility }}</MkSwitch>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['default', 'note', 'visibility']">
:label="i18n.ts.defaultNoteVisibility"
:keywords="['default', 'note', 'visibility']"
>
<MkFolder v-if="!rememberNoteVisibility"> <MkFolder v-if="!rememberNoteVisibility">
<template #label>{{ i18n.ts.defaultNoteVisibility }}</template> <template #label><SearchLabel>{{ i18n.ts.defaultNoteVisibility }}</SearchLabel></template>
<template v-if="defaultNoteVisibility === 'public'" #suffix>{{ i18n.ts._visibility.public }}</template> <template v-if="defaultNoteVisibility === 'public'" #suffix>{{ i18n.ts._visibility.public }}</template>
<template v-else-if="defaultNoteVisibility === 'home'" #suffix>{{ i18n.ts._visibility.home }}</template> <template v-else-if="defaultNoteVisibility === 'home'" #suffix>{{ i18n.ts._visibility.home }}</template>
<template v-else-if="defaultNoteVisibility === 'followers'" #suffix>{{ i18n.ts._visibility.followers }}</template> <template v-else-if="defaultNoteVisibility === 'followers'" #suffix>{{ i18n.ts._visibility.followers }}</template>
@@ -232,11 +197,10 @@ SPDX-License-Identifier: AGPL-3.0-only
</div> </div>
</FormSection> </FormSection>
<SearchMarker <SearchMarker :keywords="['remember', 'keep', 'note', 'cw']">
:label="i18n.ts.keepCw" <MkSwitch v-model="keepCw" @update:modelValue="save()">
:keywords="['remember', 'keep', 'note', 'cw']" <template #label><SearchLabel>{{ i18n.ts.keepCw }}</SearchLabel></template>
> </MkSwitch>
<MkSwitch v-model="keepCw" @update:modelValue="save()">{{ i18n.ts.keepCw }}</MkSwitch>
</SearchMarker> </SearchMarker>
</div> </div>
</SearchMarker> </SearchMarker>

View File

@@ -19,63 +19,45 @@ SPDX-License-Identifier: AGPL-3.0-only
</div> </div>
</div> </div>
<SearchMarker <SearchMarker :keywords="['name']">
:label="i18n.ts._profile.name"
:keywords="['name']"
>
<MkInput v-model="profile.name" :max="30" manualSave :mfmAutocomplete="['emoji']"> <MkInput v-model="profile.name" :max="30" manualSave :mfmAutocomplete="['emoji']">
<template #label>{{ i18n.ts._profile.name }}</template> <template #label><SearchLabel>{{ i18n.ts._profile.name }}</SearchLabel></template>
</MkInput> </MkInput>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['description', 'bio']">
:label="i18n.ts._profile.description"
:keywords="['description', 'bio']"
>
<MkTextarea v-model="profile.description" :max="500" tall manualSave mfmAutocomplete :mfmPreview="true"> <MkTextarea v-model="profile.description" :max="500" tall manualSave mfmAutocomplete :mfmPreview="true">
<template #label>{{ i18n.ts._profile.description }}</template> <template #label><SearchLabel>{{ i18n.ts._profile.description }}</SearchLabel></template>
<template #caption>{{ i18n.ts._profile.youCanIncludeHashtags }}</template> <template #caption>{{ i18n.ts._profile.youCanIncludeHashtags }}</template>
</MkTextarea> </MkTextarea>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['location', 'locale']">
:label="i18n.ts.location"
:keywords="['location', 'locale']"
>
<MkInput v-model="profile.location" manualSave> <MkInput v-model="profile.location" manualSave>
<template #label>{{ i18n.ts.location }}</template> <template #label><SearchLabel>{{ i18n.ts.location }}</SearchLabel></template>
<template #prefix><i class="ti ti-map-pin"></i></template> <template #prefix><i class="ti ti-map-pin"></i></template>
</MkInput> </MkInput>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['birthday', 'birthdate', 'age']">
:label="i18n.ts.birthday"
:keywords="['birthday', 'birthdate', 'age']"
>
<MkInput v-model="profile.birthday" type="date" manualSave> <MkInput v-model="profile.birthday" type="date" manualSave>
<template #label>{{ i18n.ts.birthday }}</template> <template #label><SearchLabel>{{ i18n.ts.birthday }}</SearchLabel></template>
<template #prefix><i class="ti ti-cake"></i></template> <template #prefix><i class="ti ti-cake"></i></template>
</MkInput> </MkInput>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['language', 'locale']">
:label="i18n.ts.language"
:keywords="['language', 'locale']"
>
<MkSelect v-model="profile.lang"> <MkSelect v-model="profile.lang">
<template #label>{{ i18n.ts.language }}</template> <template #label><SearchLabel>{{ i18n.ts.language }}</SearchLabel></template>
<option v-for="x in Object.keys(langmap)" :key="x" :value="x">{{ langmap[x].nativeName }}</option> <option v-for="x in Object.keys(langmap)" :key="x" :value="x">{{ langmap[x].nativeName }}</option>
</MkSelect> </MkSelect>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['metadata']">
:label="i18n.ts._profile.metadataEdit"
:keywords="['metadata']"
>
<FormSlot> <FormSlot>
<MkFolder> <MkFolder>
<template #icon><i class="ti ti-list"></i></template> <template #icon><i class="ti ti-list"></i></template>
<template #label>{{ i18n.ts._profile.metadataEdit }}</template> <template #label><SearchLabel>{{ i18n.ts._profile.metadataEdit }}</SearchLabel></template>
<template #footer> <template #footer>
<div class="_buttons"> <div class="_buttons">
<MkButton primary @click="saveFields"><i class="ti ti-check"></i> {{ i18n.ts.save }}</MkButton> <MkButton primary @click="saveFields"><i class="ti ti-check"></i> {{ i18n.ts.save }}</MkButton>
@@ -118,25 +100,19 @@ SPDX-License-Identifier: AGPL-3.0-only
</FormSlot> </FormSlot>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['follow', 'message']">
:label="i18n.ts._profile.followedMessage"
:keywords="['follow', 'message', i18n.ts._profile.followedMessageDescription]"
>
<MkInput v-model="profile.followedMessage" :max="200" manualSave :mfmPreview="false"> <MkInput v-model="profile.followedMessage" :max="200" manualSave :mfmPreview="false">
<template #label>{{ i18n.ts._profile.followedMessage }}<span class="_beta">{{ i18n.ts.beta }}</span></template> <template #label><SearchLabel>{{ i18n.ts._profile.followedMessage }}</SearchLabel><span class="_beta">{{ i18n.ts.beta }}</span></template>
<template #caption> <template #caption>
<div>{{ i18n.ts._profile.followedMessageDescription }}</div> <div><SearchKeyword>{{ i18n.ts._profile.followedMessageDescription }}</SearchKeyword></div>
<div>{{ i18n.ts._profile.followedMessageDescriptionForLockedAccount }}</div> <div>{{ i18n.ts._profile.followedMessageDescriptionForLockedAccount }}</div>
</template> </template>
</MkInput> </MkInput>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['reaction']">
:label="i18n.ts.reactionAcceptance"
:keywords="['reaction']"
>
<MkSelect v-model="reactionAcceptance"> <MkSelect v-model="reactionAcceptance">
<template #label>{{ i18n.ts.reactionAcceptance }}</template> <template #label><SearchLabel>{{ i18n.ts.reactionAcceptance }}</SearchLabel></template>
<option :value="null">{{ i18n.ts.all }}</option> <option :value="null">{{ i18n.ts.all }}</option>
<option value="likeOnlyForRemote">{{ i18n.ts.likeOnlyForRemote }}</option> <option value="likeOnlyForRemote">{{ i18n.ts.likeOnlyForRemote }}</option>
<option value="nonSensitiveOnly">{{ i18n.ts.nonSensitiveOnly }}</option> <option value="nonSensitiveOnly">{{ i18n.ts.nonSensitiveOnly }}</option>
@@ -145,23 +121,23 @@ SPDX-License-Identifier: AGPL-3.0-only
</MkSelect> </MkSelect>
</SearchMarker> </SearchMarker>
<SearchMarker :label="i18n.ts.advancedSettings"> <SearchMarker>
<MkFolder> <MkFolder>
<template #label>{{ i18n.ts.advancedSettings }}</template> <template #label><SearchLabel>{{ i18n.ts.advancedSettings }}</SearchLabel></template>
<div class="_gaps_m"> <div class="_gaps_m">
<SearchMarker <SearchMarker :keywords="['cat']">
:label="i18n.ts.flagAsCat" <MkSwitch v-model="profile.isCat">
:keywords="['cat', i18n.ts.flagAsCatDescription]" <template #label><SearchLabel>{{ i18n.ts.flagAsCat }}</SearchLabel></template>
> <template #caption>{{ i18n.ts.flagAsCatDescription }}</template>
<MkSwitch v-model="profile.isCat">{{ i18n.ts.flagAsCat }}<template #caption>{{ i18n.ts.flagAsCatDescription }}</template></MkSwitch> </MkSwitch>
</SearchMarker> </SearchMarker>
<SearchMarker <SearchMarker :keywords="['bot']">
:label="i18n.ts.flagAsBot" <MkSwitch v-model="profile.isBot">
:keywords="['bot', i18n.ts.flagAsBotDescription]" <template #label><SearchLabel>{{ i18n.ts.flagAsBot }}</SearchLabel></template>
> <template #caption>{{ i18n.ts.flagAsBotDescription }}</template>
<MkSwitch v-model="profile.isBot">{{ i18n.ts.flagAsBot }}<template #caption>{{ i18n.ts.flagAsBotDescription }}</template></MkSwitch> </MkSwitch>
</SearchMarker> </SearchMarker>
</div> </div>
</MkFolder> </MkFolder>