mirror of
https://github.com/primefaces/primevue.git
synced 2025-05-09 00:42:36 +00:00
Refactor #5435
This commit is contained in:
parent
413efbb2f4
commit
71db0aea00
1 changed files with 1 additions and 1 deletions
|
@ -777,7 +777,7 @@ export default {
|
|||
isSelected(option) {
|
||||
const optionValue = this.getOptionValue(option);
|
||||
|
||||
return (this.modelValue || []).some((value) => this.isEquals(value, optionValue));
|
||||
return this.multiple ? (this.modelValue || []).some((value) => this.isEquals(value, optionValue)) : this.isEquals(this.modelValue, this.getOptionValue(option));
|
||||
},
|
||||
findFirstOptionIndex() {
|
||||
return this.visibleOptions.findIndex((option) => this.isValidOption(option));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue