Vuetify Version: 2.0.3
Vue Version: 2.6.10
Browsers: Google Chrome
OS: Windows 10
v-content left padding is 120px when mini-variant is true and 320px when not.
v-content left padding is 320px when mini-variant is true and 120px when not.
It works if you use a number instead: width="320"
This happens due to a change made in order to allow the drawer to take non px value numbers such as 40vw. However, even when using 300px, the system checks to see if it is NaN and if so, simply returns the current width of the drawer.
The issue starts when you swap between mini and full width, the element is animating when the check for its width is called and therefor returns an incorrect value.
What I'll probably end up doing with this is informing users of the caveat as I'm not sure it is worth dedicating time to come up with a specific solution.
It works if you use a number instead:
width="320"
Only works for the first time then breaks (expand, collapse, expand, collapse << fails). And this doesn't support expand-on-hover being set.
This is on v2.2.11.
I only got it to works with this workaround inside my Drawer component:
onTransitionEnd () {
this.isMini = this.$refs.drawer.isMiniVariant;
}
@Watch("isMini")
onIsMiniChanged() {
this.width = this.miniWidth;
this.$nextTick(() => {
this.width = this.fullWidth;
});
}
onTransitionEnd is triggered by @transitionend
Most helpful comment
It works if you use a number instead:
width="320"