Skip to content

Commit 173f0bf

Browse files
authored
Merge pull request sagalbot#470 from dbezborodovrp/feature/clear-button-flag
Clear button flag.
2 parents 546b27d + 50c4ede commit 173f0bf

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

src/components/Select.vue

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -423,6 +423,15 @@
423423
default: false
424424
},
425425
426+
/**
427+
* Can the user clear the selected property?
428+
* @type {Boolean}
429+
*/
430+
clearable: {
431+
type: Boolean,
432+
default: true
433+
},
434+
426435
/**
427436
* Sets the max-height property on the dropdown list.
428437
* @deprecated
@@ -1053,7 +1062,7 @@
10531062
* @return {Boolean}
10541063
*/
10551064
showClearButton() {
1056-
return !this.multiple && !this.open && this.mutableValue != null
1065+
return !this.multiple && this.clearable && !this.open && this.mutableValue != null
10571066
}
10581067
},
10591068

0 commit comments

Comments
 (0)