Skip to content

Commit

Permalink
fix(VPicker): fix width in landscape mode
Browse files Browse the repository at this point in the history
  • Loading branch information
dsseng committed Jun 18, 2019
1 parent 372c314 commit 5075e43
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packages/vuetify/src/components/VPicker/VPicker.sass
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,6 @@
height: 100%
z-index: 1

.v-picker__body,
.v-picker__actions
.v-picker__body:not(.v-picker__body--no-title),
.v-picker__actions:not(.v-picker__actions--no-title)
margin-left: $picker-landscape-title-width
9 changes: 8 additions & 1 deletion packages/vuetify/src/components/VPicker/VPicker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ export default mixins(Colorable, Themeable).extend({
props: {
fullWidth: Boolean,
landscape: Boolean,
noTitle: Boolean,
transition: {
type: String,
default: 'fade-transition',
Expand Down Expand Up @@ -55,7 +56,10 @@ export default mixins(Colorable, Themeable).extend({
genBody () {
return this.$createElement('div', {
staticClass: 'v-picker__body',
'class': this.themeClasses,
class: {
'v-picker__body--no-title': this.noTitle,
...this.themeClasses,
},
style: this.fullWidth ? undefined : {
width: convertToUnit(this.width),
},
Expand All @@ -66,6 +70,9 @@ export default mixins(Colorable, Themeable).extend({
genActions () {
return this.$createElement('div', {
staticClass: 'v-picker__actions v-card__actions',
class: {
'v-picker__actions--no-title': this.noTitle,
},
}, this.$slots.actions)
},
},
Expand Down
1 change: 1 addition & 0 deletions packages/vuetify/src/mixins/picker/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ export default mixins(
landscape: this.landscape,
light: this.light,
width: this.width,
noTitle: this.noTitle,
},
}, children)
},
Expand Down

0 comments on commit 5075e43

Please sign in to comment.