Commit 19b6c005b3492ee8299d1e5500e85459fc719e19
Committed by
GitHub
Merge pull request #3925 from losadaem/select-with-disable-clearable
select: don't allow to clear the selected option when disabled (fix #3924)
Showing
1 changed file
with
1 additions
and
1 deletions
Show diff stats
src/components/select/select.vue
... | ... | @@ -328,7 +328,7 @@ |
328 | 328 | }, |
329 | 329 | canBeCleared(){ |
330 | 330 | const uiStateMatch = this.hasMouseHoverHead || this.active; |
331 | - const qualifiesForClear = !this.multiple && this.clearable; | |
331 | + const qualifiesForClear = !this.multiple && !this.disabled && this.clearable; | |
332 | 332 | return uiStateMatch && qualifiesForClear && this.reset; // we return a function |
333 | 333 | }, |
334 | 334 | selectOptions() { | ... | ... |