diff options
| author | Shpuld Shpludson <shp@cock.li> | 2020-08-06 09:53:24 +0000 |
|---|---|---|
| committer | Shpuld Shpludson <shp@cock.li> | 2020-08-06 09:53:24 +0000 |
| commit | 9a10ad38260cc4d1ef93a6988ef2cb0941080156 (patch) | |
| tree | 43abd13df222be80c67fa7e446a9b257da7d77c1 /src/components/tab_switcher/tab_switcher.js | |
| parent | 7bd684670384b082d9b87a3a1eacf04dbce0267d (diff) | |
| parent | 77d65d6cecfae1bdbf5e5b7d8c882d39846b91f1 (diff) | |
Merge branch 'mobile-setting-modal-fix' into 'develop'
Mobile setting modal behavior fixes
Closes #908
See merge request pleroma/pleroma-fe!1200
Diffstat (limited to 'src/components/tab_switcher/tab_switcher.js')
| -rw-r--r-- | src/components/tab_switcher/tab_switcher.js | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/components/tab_switcher/tab_switcher.js b/src/components/tab_switcher/tab_switcher.js index 7891cb78..40b5b3ca 100644 --- a/src/components/tab_switcher/tab_switcher.js +++ b/src/components/tab_switcher/tab_switcher.js @@ -1,4 +1,5 @@ import Vue from 'vue' +import { mapState } from 'vuex' import './tab_switcher.scss' @@ -44,7 +45,13 @@ export default Vue.component('tab-switcher', { } else { return this.active } - } + }, + settingsModalVisible () { + return this.settingsModalState === 'visible' + }, + ...mapState({ + settingsModalState: state => state.interface.settingsModalState + }) }, beforeUpdate () { const currentSlot = this.$slots.default[this.active] @@ -134,7 +141,7 @@ export default Vue.component('tab-switcher', { <div class="tabs"> {tabs} </div> - <div ref="contents" class={'contents' + (this.scrollableTabs ? ' scrollable-tabs' : '')}> + <div ref="contents" class={'contents' + (this.scrollableTabs ? ' scrollable-tabs' : '')} v-body-scroll-lock={this.settingsModalVisible}> {contents} </div> </div> |
