feat: toc sidebar position

This commit is contained in:
NGPixel
2022-12-10 17:03:40 -05:00
parent 9ac80c1a8f
commit f3133a72ec
9 changed files with 48 additions and 15 deletions

View File

@@ -55,20 +55,16 @@
v-card.mt-3.animated.fadeInUp.wait-p1s
v-toolbar(color='primary', dark, dense, flat)
v-toolbar-title.subtitle-1 {{$t(`admin:theme.options`)}}
v-spacer
v-chip(label, color='white', small).primary--text coming soon
v-card-text
v-select(
:items='[]'
:items='tocPositions'
outlined
prepend-icon='mdi-border-vertical'
v-model='config.iconset'
v-model='config.tocPosition'
label='Table of Contents Position'
persistent-hint
hint='Select whether the table of contents is shown on the left, right or not at all.'
disabled
)
v-flex(lg6 xs12)
//- v-card.animated.fadeInUp.wait-p2s
//- v-toolbar(color='teal', dark, dense, flat)
@@ -155,6 +151,7 @@ export default {
theme: 'default',
darkMode: false,
iconset: '',
tocPosition: 'left',
injectCSS: '',
injectHead: '',
injectBody: ''
@@ -184,6 +181,13 @@ export default {
width: 100
}
]
},
tocPositions () {
return [
{ text: 'Left (default)', value: 'left' },
{ text: 'Right', value: 'right' },
{ text: 'Hidden', value: 'off' }
]
}
},
watch: {
@@ -209,6 +213,7 @@ export default {
theme: this.config.theme,
iconset: this.config.iconset,
darkMode: this.darkMode,
tocPosition: this.config.tocPosition,
injectCSS: this.config.injectCSS,
injectHead: this.config.injectHead,
injectBody: this.config.injectBody