Skip to content

Commit

Permalink
Revert bad test for if a select-element should be disabled. setChoice…
Browse files Browse the repository at this point in the history
…s means even if no choices exist they can be added
  • Loading branch information
Xon committed Aug 9, 2024
1 parent 18ec5ed commit a3ed41f
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions src/scripts/choices.ts
Original file line number Diff line number Diff line change
Expand Up @@ -368,9 +368,6 @@ class Choices implements ChoicesInterface {

const shouldDisable =
(this._isTextElement && !this.config.addItems) ||
(this._isSelectElement &&
!this.config.addChoices &&
this._store.choices.length === 0) ||
this.passedElement.element.hasAttribute('disabled') ||
!!this.passedElement.element.closest('fieldset:disabled');

Expand Down

0 comments on commit a3ed41f

Please sign in to comment.