From d202b94104972e17a3d158530b738603e8510779 Mon Sep 17 00:00:00 2001 From: Henry Jameson Date: Wed, 5 Aug 2026 19:13:07 +0300 Subject: [PATCH 1/4] fix third column setting change not affecting UI immideately --- src/App.js | 24 ++++++++++++------- src/components/notifications/notifications.js | 6 +++-- .../settings_modal/helpers/setting.js | 5 +++- .../settings_modal/tabs/layout_tab.js | 6 +++++ .../settings_modal/tabs/layout_tab.vue | 1 + 5 files changed, 30 insertions(+), 12 deletions(-) diff --git a/src/App.js b/src/App.js index 4ce6f1abc..c5b38d958 100644 --- a/src/App.js +++ b/src/App.js @@ -74,6 +74,8 @@ export default { }, data: () => ({ mobileActivePanel: 'timeline', + updateMobileState: null, + updateScrollState: null, }), provide() { return { @@ -211,22 +213,26 @@ export default { hideShoutbox() { return this.isChats || useMergedConfigStore().mergedConfig.hideShoutbox }, + thirdColumnMode() { + return this.mergedConfig.thirdColumnMode + }, + reverseSetting() { + return this.mergedConfig.sidebarRight + }, reverseLayout() { - const { thirdColumnMode, sidebarRight: reverseSetting } = - useMergedConfigStore().mergedConfig if (this.layoutType !== 'wide') { - return reverseSetting + return this.reverseSetting } else { - return thirdColumnMode === 'notifications' - ? reverseSetting - : !reverseSetting + return this.thirdColumnMode === 'notifications' + ? this.reverseSetting + : !this.reverseSetting } }, noSticky() { - return useMergedConfigStore().mergedConfig.disableStickyHeaders + return this.mergedConfig.disableStickyHeaders }, showScrollbars() { - return useMergedConfigStore().mergedConfig.showScrollbars + return this.mergedConfig.showScrollbars }, scrollParent() { return window /* this.$refs.appContentRef */ @@ -234,7 +240,7 @@ export default { showInstanceSpecificPanel() { return ( this.instanceSpecificPanelPresent && - !useMergedConfigStore().mergedConfig.hideISP + !this.mergedConfig.hideISP ) }, ...mapState(useMergedConfigStore, ['mergedConfig']), diff --git a/src/components/notifications/notifications.js b/src/components/notifications/notifications.js index 393aef639..5ae6014bc 100644 --- a/src/components/notifications/notifications.js +++ b/src/components/notifications/notifications.js @@ -134,12 +134,11 @@ const Notifications = { return this.minimalMode || layoutType === 'mobile' }, teleportTarget() { - const { layoutType } = useInterfaceStore() const map = { wide: '#notifs-column', mobile: '#mobile-notifications', } - return map[layoutType] || '#notifs-sidebar' + return map[this.layoutType] || '#notifs-sidebar' }, popoversZLayer() { const { layoutType } = useInterfaceStore() @@ -162,6 +161,9 @@ const Notifications = { }, ...mapState(useAnnouncementsStore, ['unreadAnnouncementCount']), ...mapState(useChatsStore, ['unreadChatsCount']), + ...mapState(useInterfaceStore, [ + 'layoutType', + ]), }, mounted() { this.scrollerRef = this.$refs.root.closest('.column.-scrollable') diff --git a/src/components/settings_modal/helpers/setting.js b/src/components/settings_modal/helpers/setting.js index 09d3ecc2d..4e0f43875 100644 --- a/src/components/settings_modal/helpers/setting.js +++ b/src/components/settings_modal/helpers/setting.js @@ -113,6 +113,7 @@ export default { localDraft: null, } }, + emits: ['update:modelValue'], created() { if ( this.realDraftMode && @@ -244,7 +245,7 @@ export default { }, configSink() { if (this.path == null) { - return (k, v) => this.$emit('update:modelValue', v) + return () => {} } switch (this.realSource) { @@ -385,11 +386,13 @@ export default { if (this.realDraftMode) { this.draft = this.getValue(e) } else { + this.$emit('update:modelValue', this.getValue(e)) this.configSink(this.path, this.getValue(e)) } }, commitDraft() { if (this.realDraftMode) { + this.$emit('update:modelValue', v) this.configSink(this.path, this.draft) } }, diff --git a/src/components/settings_modal/tabs/layout_tab.js b/src/components/settings_modal/tabs/layout_tab.js index fc56e1392..c1a3cd3b4 100644 --- a/src/components/settings_modal/tabs/layout_tab.js +++ b/src/components/settings_modal/tabs/layout_tab.js @@ -7,6 +7,7 @@ import UnitSetting from '../helpers/unit_setting.vue' import { useInstanceCapabilitiesStore } from 'src/stores/instance_capabilities.js' import { useMergedConfigStore } from 'src/stores/merged_config.js' +import { useInterfaceStore } from 'src/stores/interface.js' const GeneralTab = { data() { @@ -46,6 +47,11 @@ const GeneralTab = { }, ...SharedComputedObject(), }, + methods: { + updateLayout() { + useInterfaceStore().setLayoutWidth() + }, + }, } export default GeneralTab diff --git a/src/components/settings_modal/tabs/layout_tab.vue b/src/components/settings_modal/tabs/layout_tab.vue index 0035f3a11..b649572fb 100644 --- a/src/components/settings_modal/tabs/layout_tab.vue +++ b/src/components/settings_modal/tabs/layout_tab.vue @@ -105,6 +105,7 @@ id="thirdColumnMode" path="thirdColumnMode" :options="thirdColumnModeOptions" + @change="updateLayout" > {{ $t('settings.third_column_mode') }} From 8e19fbf23ed8785deed69c042033ce9d48350c10 Mon Sep 17 00:00:00 2001 From: Henry Jameson Date: Wed, 5 Aug 2026 19:13:58 +0300 Subject: [PATCH 2/4] changelog --- changelog.d/third_column.fix | 1 + 1 file changed, 1 insertion(+) create mode 100644 changelog.d/third_column.fix diff --git a/changelog.d/third_column.fix b/changelog.d/third_column.fix new file mode 100644 index 000000000..191e914d5 --- /dev/null +++ b/changelog.d/third_column.fix @@ -0,0 +1 @@ +Fixed layout selector (third column/reverse) not working immideately upon change From 92b8d1607f8da7b2df30ef209555255ffe130037 Mon Sep 17 00:00:00 2001 From: Henry Jameson Date: Wed, 5 Aug 2026 19:15:37 +0300 Subject: [PATCH 3/4] lint --- src/App.js | 5 +---- src/components/notifications/notifications.js | 4 +--- src/components/settings_modal/helpers/setting.js | 4 ++-- src/components/settings_modal/tabs/layout_tab.js | 2 +- 4 files changed, 5 insertions(+), 10 deletions(-) diff --git a/src/App.js b/src/App.js index c5b38d958..d7a63bd8a 100644 --- a/src/App.js +++ b/src/App.js @@ -238,10 +238,7 @@ export default { return window /* this.$refs.appContentRef */ }, showInstanceSpecificPanel() { - return ( - this.instanceSpecificPanelPresent && - !this.mergedConfig.hideISP - ) + return this.instanceSpecificPanelPresent && !this.mergedConfig.hideISP }, ...mapState(useMergedConfigStore, ['mergedConfig']), ...mapState(useInterfaceStore, [ diff --git a/src/components/notifications/notifications.js b/src/components/notifications/notifications.js index 5ae6014bc..feb59857e 100644 --- a/src/components/notifications/notifications.js +++ b/src/components/notifications/notifications.js @@ -161,9 +161,7 @@ const Notifications = { }, ...mapState(useAnnouncementsStore, ['unreadAnnouncementCount']), ...mapState(useChatsStore, ['unreadChatsCount']), - ...mapState(useInterfaceStore, [ - 'layoutType', - ]), + ...mapState(useInterfaceStore, ['layoutType']), }, mounted() { this.scrollerRef = this.$refs.root.closest('.column.-scrollable') diff --git a/src/components/settings_modal/helpers/setting.js b/src/components/settings_modal/helpers/setting.js index 4e0f43875..05e1027f3 100644 --- a/src/components/settings_modal/helpers/setting.js +++ b/src/components/settings_modal/helpers/setting.js @@ -245,7 +245,7 @@ export default { }, configSink() { if (this.path == null) { - return () => {} + return () => {/* no-op */} } switch (this.realSource) { @@ -392,7 +392,7 @@ export default { }, commitDraft() { if (this.realDraftMode) { - this.$emit('update:modelValue', v) + this.$emit('update:modelValue', this.draft) this.configSink(this.path, this.draft) } }, diff --git a/src/components/settings_modal/tabs/layout_tab.js b/src/components/settings_modal/tabs/layout_tab.js index c1a3cd3b4..50761fa43 100644 --- a/src/components/settings_modal/tabs/layout_tab.js +++ b/src/components/settings_modal/tabs/layout_tab.js @@ -6,8 +6,8 @@ import SharedComputedObject from '../helpers/shared_computed_object.js' import UnitSetting from '../helpers/unit_setting.vue' import { useInstanceCapabilitiesStore } from 'src/stores/instance_capabilities.js' -import { useMergedConfigStore } from 'src/stores/merged_config.js' import { useInterfaceStore } from 'src/stores/interface.js' +import { useMergedConfigStore } from 'src/stores/merged_config.js' const GeneralTab = { data() { From a3bc98589e65ab347d48edb812af160fe1287cb8 Mon Sep 17 00:00:00 2001 From: Henry Jameson Date: Wed, 5 Aug 2026 19:18:33 +0300 Subject: [PATCH 4/4] lint --- src/components/settings_modal/helpers/setting.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/components/settings_modal/helpers/setting.js b/src/components/settings_modal/helpers/setting.js index 05e1027f3..a1a946fca 100644 --- a/src/components/settings_modal/helpers/setting.js +++ b/src/components/settings_modal/helpers/setting.js @@ -245,7 +245,9 @@ export default { }, configSink() { if (this.path == null) { - return () => {/* no-op */} + return () => { + /* no-op */ + } } switch (this.realSource) {