diff --git a/src/App.js b/src/App.js index a65b5e52a..c6f2b21b3 100644 --- a/src/App.js +++ b/src/App.js @@ -150,13 +150,6 @@ export default { shout() { return useShoutStore().joined }, - showInstanceSpecificPanel() { - return ( - this.showInstanceSpecificPanel && - !this.$store.getters.mergedConfig.hideISP && - this.instanceSpecificPanelContent - ) - }, isChats() { return this.$route.name === 'chat' || this.$route.name === 'chats' }, @@ -197,6 +190,12 @@ export default { scrollParent() { return window /* this.$refs.appContentRef */ }, + showInstanceSpecificPanel() { + return ( + this.instanceSpecificPanelPresent && + !this.$store.getters.mergedConfig.hideISP + ) + }, ...mapGetters(['mergedConfig']), ...mapState(useInterfaceStore, [ 'themeApplied', @@ -211,9 +210,8 @@ export default { ...mapState(useInstanceStore, { background: (store) => store.instanceIdentity.background, showFeaturesPanel: (store) => store.instanceIdentity.showFeaturesPanel, - showInstanceSpecificPanel: (store) => - store.instanceIdentity.showInstanceSpecificPanel, - instanceSpecificPanelContent: (store) => + instanceSpecificPanelPresent: (store) => + store.instanceIdentity.showInstanceSpecificPanel && store.instanceIdentity.instanceSpecificPanelContent, }), }, diff --git a/src/components/settings_modal/tabs/clutter_tab.js b/src/components/settings_modal/tabs/clutter_tab.js index 7aef996c8..23e069d21 100644 --- a/src/components/settings_modal/tabs/clutter_tab.js +++ b/src/components/settings_modal/tabs/clutter_tab.js @@ -10,6 +10,7 @@ import IntegerSetting from '../helpers/integer_setting.vue' import SharedComputedObject from '../helpers/shared_computed_object.js' import UnitSetting from '../helpers/unit_setting.vue' +import { useInstanceStore } from 'src/stores/instance.js' import { useInstanceCapabilitiesStore } from 'src/stores/instance_capabilities.js' import { useServerSideStorageStore } from 'src/stores/serverSideStorage' @@ -26,6 +27,12 @@ const ClutterTab = { computed: { ...SharedComputedObject(), ...mapState(useInstanceCapabilitiesStore, ['shoutAvailable']), + ...mapState(useInstanceStore, { + showFeaturesPanel: (store) => store.instanceIdentity.showFeaturesPanel, + instanceSpecificPanelPresent: (store) => + store.instanceIdentity.showInstanceSpecificPanel && + store.instanceIdentity.instanceSpecificPanelContent, + }), ...mapState(useServerSideStorageStore, { muteFilters: (store) => Object.entries(store.prefsStorage.simple.muteFilters), diff --git a/src/components/settings_modal/tabs/clutter_tab.vue b/src/components/settings_modal/tabs/clutter_tab.vue index 5cd66dccd..d14d94818 100644 --- a/src/components/settings_modal/tabs/clutter_tab.vue +++ b/src/components/settings_modal/tabs/clutter_tab.vue @@ -45,6 +45,11 @@ {{ $t('settings.hide_scrobbles_after') }} +
  • + + {{ $t('settings.hide_isp') }} + +
  • diff --git a/src/components/settings_modal/tabs/layout_tab.js b/src/components/settings_modal/tabs/layout_tab.js index 58eb60a45..8259820fc 100644 --- a/src/components/settings_modal/tabs/layout_tab.js +++ b/src/components/settings_modal/tabs/layout_tab.js @@ -28,7 +28,6 @@ const GeneralTab = { }, computed: { ...mapState(useInstanceCapabilitiesStore, [ - 'instanceSpecificPanelPresent', 'postFormats', 'suggestionsEnabled', ]), diff --git a/src/components/settings_modal/tabs/layout_tab.vue b/src/components/settings_modal/tabs/layout_tab.vue index 2290b0630..b52c106b9 100644 --- a/src/components/settings_modal/tabs/layout_tab.vue +++ b/src/components/settings_modal/tabs/layout_tab.vue @@ -69,11 +69,6 @@ {{ $t('settings.show_scrollbars') }} -
  • - - {{ $t('settings.hide_isp') }} - -
  • ({ statuses: [], @@ -115,7 +115,8 @@ const sortTimeline = (timeline) => { } const getLatestScrobble = (state, user) => { - const scrobblesSupport = useInstanceCapabilitiesStore().pleromaScrobblesAvailable + const scrobblesSupport = + useInstanceCapabilitiesStore().pleromaScrobblesAvailable if (!scrobblesSupport || !user.name || user.id === 'undefined') { return