Skip to content

Commit

Permalink
Fix regression of UnhighlightItem event not firing (#1173)
Browse files Browse the repository at this point in the history
  • Loading branch information
Xon committed Sep 4, 2024
1 parent bef1adf commit 5448b99
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
* Fix choice disable state wasn't considered when showing the "no choices to choose from" notice
* Fix regression "no choices to choose from" notice not triggering when no selectable choices exist for select-one. [#1185](https://github.com/Choices-js/Choices/issues/1185)
* Fix regression where webpack doesn't permit importing scss/css @tagliala (#1193)
* Fix regression of UnhighlightItem event not firing [#1173](https://github.com/Choices-js/Choices/issues/1173)

### Chore
* Add e2e tests for "no choices" behavior to match v10
Expand Down
2 changes: 1 addition & 1 deletion src/scripts/choices.ts
Original file line number Diff line number Diff line change
Expand Up @@ -434,7 +434,7 @@ class Choices {
this._store.dispatch(highlightItem(choice, false));

if (runEvent) {
this.passedElement.triggerEvent(EventType.highlightItem, this._getChoiceForOutput(choice));
this.passedElement.triggerEvent(EventType.unhighlightItem, this._getChoiceForOutput(choice));
}

return this;
Expand Down

0 comments on commit 5448b99

Please sign in to comment.