Skip to content

Commit

Permalink
fix(VItem): support disabled effect
Browse files Browse the repository at this point in the history
  • Loading branch information
yuwu9145 committed Apr 8, 2022
1 parent 0b34506 commit 62dc78c
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
2 changes: 2 additions & 0 deletions packages/vuetify/src/components/VItemGroup/VItem.sass
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
.v-item--disabled
pointer-events: none
9 changes: 8 additions & 1 deletion packages/vuetify/src/components/VItemGroup/VItem.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// Styles
import './VItem.sass'

// Mixins
import { factory as GroupableFactory } from '../../mixins/groupable'

Expand All @@ -16,6 +19,7 @@ export const BaseItem = Vue.extend({
value: {
required: false,
},
disabled: Boolean,
},

data: () => ({
Expand Down Expand Up @@ -56,7 +60,10 @@ export const BaseItem = Vue.extend({
}

element.data = this._b(element.data || {}, element.tag!, {
class: { [this.activeClass]: this.isActive },
class: {
[this.activeClass]: this.isActive,
'v-item--disabled': this.disabled,
},
})

return element
Expand Down

0 comments on commit 62dc78c

Please sign in to comment.