summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/client/components/post-form.vue5
-rw-r--r--src/client/pages/settings/general.vue2
-rw-r--r--src/client/pages/settings/privacy.vue7
-rw-r--r--src/client/store.ts1
4 files changed, 11 insertions, 4 deletions
diff --git a/src/client/components/post-form.vue b/src/client/components/post-form.vue
index 3586223f7e..166b3c7c5f 100644
--- a/src/client/components/post-form.vue
+++ b/src/client/components/post-form.vue
@@ -217,7 +217,7 @@ export default Vue.extend({
// デフォルト公開範囲
this.applyVisibility(this.$store.state.settings.rememberNoteVisibility ? this.$store.state.device.visibility : this.$store.state.settings.defaultNoteVisibility);
- this.localOnly = this.$store.state.settings.rememberNoteVisibility ? this.$store.state.device.localOnly : false;
+ this.localOnly = this.$store.state.settings.rememberNoteVisibility ? this.$store.state.device.localOnly : this.$store.state.settings.defaultNoteLocalOnly;
// 公開以外へのリプライ時は元の公開範囲を引き継ぐ
if (this.reply && ['home', 'followers', 'specified'].includes(this.reply.visibility)) {
@@ -398,8 +398,7 @@ export default Vue.extend({
},
applyVisibility(v: string) {
- if (!['public', 'home', 'followers', 'specified'].includes(v)) v = 'public'; // v11互換性のため
- this.visibility = v;
+ this.visibility = ['public', 'home', 'followers', 'specified'].includes(v) ? v : 'public'; // v11互換性のため
},
addVisibleUser() {
diff --git a/src/client/pages/settings/general.vue b/src/client/pages/settings/general.vue
index 85a4ac2cfe..061838b44d 100644
--- a/src/client/pages/settings/general.vue
+++ b/src/client/pages/settings/general.vue
@@ -14,7 +14,7 @@
{{ $t('autoReloadWhenDisconnected') }}
</mk-switch>
<mk-switch v-model="$store.state.i.autoWatch" @change="onChangeAutoWatch">
- {{ $t('autoNoteWatch') }}<template #desc>{{ $t('auto-watch-desc') }}</template>
+ {{ $t('autoNoteWatch') }}<template #desc>{{ $t('autoNoteWatchDescription') }}</template>
</mk-switch>
</div>
<div class="_content">
diff --git a/src/client/pages/settings/privacy.vue b/src/client/pages/settings/privacy.vue
index d9c4f6ad3d..7ac9062d88 100644
--- a/src/client/pages/settings/privacy.vue
+++ b/src/client/pages/settings/privacy.vue
@@ -10,9 +10,11 @@
<mk-select v-model="defaultNoteVisibility" style="margin-bottom: 8px;" v-if="!rememberNoteVisibility">
<template #label>{{ $t('defaultNoteVisibility') }}</template>
<option value="public">{{ $t('_visibility.public') }}</option>
+ <option value="home">{{ $t('_visibility.home') }}</option>
<option value="followers">{{ $t('_visibility.followers') }}</option>
<option value="specified">{{ $t('_visibility.specified') }}</option>
</mk-select>
+ <mk-switch v-model="defaultNoteLocalOnly" v-if="!rememberNoteVisibility">{{ $t('_visibility.localOnly') }}</mk-switch>
</div>
</section>
</template>
@@ -46,6 +48,11 @@ export default Vue.extend({
set(value) { this.$store.dispatch('settings/set', { key: 'defaultNoteVisibility', value }); }
},
+ defaultNoteLocalOnly: {
+ get() { return this.$store.state.settings.defaultNoteLocalOnly; },
+ set(value) { this.$store.dispatch('settings/set', { key: 'defaultNoteLocalOnly', value }); }
+ },
+
rememberNoteVisibility: {
get() { return this.$store.state.settings.rememberNoteVisibility; },
set(value) { this.$store.dispatch('settings/set', { key: 'rememberNoteVisibility', value }); }
diff --git a/src/client/store.ts b/src/client/store.ts
index 71e19f4da8..04598525b7 100644
--- a/src/client/store.ts
+++ b/src/client/store.ts
@@ -9,6 +9,7 @@ const defaultSettings = {
showFullAcct: false,
rememberNoteVisibility: false,
defaultNoteVisibility: 'public',
+ defaultNoteLocalOnly: false,
uploadFolder: null,
pastedFileName: 'yyyy-MM-dd HH-mm-ss [{{number}}]',
wallpaper: null,