You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jan 8, 2020. It is now read-only.
In .storybook/addon-vuetify/decorator.js I added a knob to toggle the theme like so:
// inside of the `wrapper()` functionreturnVue.extend({
vuetify,components: { WrappedComponent },props: {dark: {default: boolean('Dark Theme',false),// or options.theme.dark see #2 },},watch: {dark(val){this.$vuetify.theme.dark=val},},template: ` <v-app> <v-container fluid> <wrapped-component /> </v-container> </v-app> `})
Now in all of my stories, there's a knob that allows me to toggle Vuetify's dark theme on and off to see what components look like in those scenarios. Here are some screenshots:
Dunno if this kinda thing should be baked into the addon or not, but I thought it was a neat trick that I'd share.
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
In
.storybook/addon-vuetify/decorator.js
I added a knob to toggle the theme like so:Now in all of my stories, there's a knob that allows me to toggle Vuetify's dark theme on and off to see what components look like in those scenarios. Here are some screenshots:
Dunno if this kinda thing should be baked into the addon or not, but I thought it was a neat trick that I'd share.
The text was updated successfully, but these errors were encountered: