feat/add_user_theme_view_controls: yarn add cookie-universal-nuxt , to allow users to choose the lightness of the theme and the compactness of the view on events
This commit is contained in:
@@ -32,7 +32,12 @@ export default {
|
||||
components: { Appbar, Snackbar, Footer, Confirm },
|
||||
computed: mapState(['settings']),
|
||||
created () {
|
||||
this.$vuetify.theme.dark = this.settings['theme.is_dark']
|
||||
const theme_is_dark = this.$cookies.get('theme.is_dark')
|
||||
if ( theme_is_dark != null ) {
|
||||
this.$vuetify.theme.dark = theme_is_dark
|
||||
} else {
|
||||
this.$vuetify.theme.dark = this.settings['theme.is_dark']
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user