From a8083eb52bc268829caa2d5453dec5d9a3c5185f Mon Sep 17 00:00:00 2001 From: syuilo Date: Sun, 29 Apr 2018 17:54:50 +0900 Subject: [PATCH] =?UTF-8?q?=E3=83=90=E3=82=B0=E4=BF=AE=E6=AD=A3=E3=81=AA?= =?UTF-8?q?=E3=81=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/client/app/common/mios.ts | 8 +++----- src/client/app/desktop/views/components/settings.vue | 2 +- src/client/app/desktop/views/pages/welcome.vue | 12 ++++-------- src/client/app/mobile/views/pages/welcome.vue | 12 ++++-------- src/client/app/store.ts | 10 ++++++---- src/server/api/stream/home.ts | 5 +++-- 6 files changed, 21 insertions(+), 28 deletions(-) diff --git a/src/client/app/common/mios.ts b/src/client/app/common/mios.ts index 7dcae47946..3973e4ae8c 100644 --- a/src/client/app/common/mios.ts +++ b/src/client/app/common/mios.ts @@ -332,7 +332,7 @@ export default class MiOS extends EventEmitter { const cachedSettings = JSON.parse(localStorage.getItem('settings')); if (cachedSettings) { - this.store.commit('settings/init', cachedSettings); + this.store.dispatch('settings/merge', cachedSettings); } //#endregion @@ -350,7 +350,7 @@ export default class MiOS extends EventEmitter { fetchme(cachedMe.token, freshData => { merge(cachedMe, freshData); - this.store.commit('settings/init', freshData.clientSettings); + this.store.dispatch('settings/merge', freshData.clientSettings); }); } else { // Get token from cookie @@ -358,9 +358,7 @@ export default class MiOS extends EventEmitter { fetchme(i, me => { if (me) { - Object.entries(me.clientSettings).forEach(([key, value]) => { - this.store.commit('settings/set', { key, value }); - }); + this.store.dispatch('settings/merge', me.clientSettings); fetched(me); } else { diff --git a/src/client/app/desktop/views/components/settings.vue b/src/client/app/desktop/views/components/settings.vue index af6ab12669..77606d4254 100644 --- a/src/client/app/desktop/views/components/settings.vue +++ b/src/client/app/desktop/views/components/settings.vue @@ -41,7 +41,7 @@
- +
diff --git a/src/client/app/desktop/views/pages/welcome.vue b/src/client/app/desktop/views/pages/welcome.vue index 3d6765c97e..898b6b2179 100644 --- a/src/client/app/desktop/views/pages/welcome.vue +++ b/src/client/app/desktop/views/pages/welcome.vue @@ -8,7 +8,7 @@

ようこそ! MisskeyはTwitter風ミニブログSNSです。思ったことや皆と共有したいことを投稿しましょう。タイムラインを見れば、皆の関心事をすぐにチェックすることもできます。詳しく...

- +
@@ -215,13 +215,9 @@ export default Vue.extend({ > * display inline-block margin 4px - - > * - display inline-block - width 38px - height 38px - vertical-align top - border-radius 6px + width 38px + height 38px + border-radius 6px > div:last-child diff --git a/src/client/app/mobile/views/pages/welcome.vue b/src/client/app/mobile/views/pages/welcome.vue index 4d236d7aa5..64cfa5a46c 100644 --- a/src/client/app/mobile/views/pages/welcome.vue +++ b/src/client/app/mobile/views/pages/welcome.vue @@ -22,7 +22,7 @@
- +