Skip to content

Commit

Permalink
Fixes toggle list when used without newValue
Browse files Browse the repository at this point in the history
  • Loading branch information
klovaaxel committed Feb 11, 2024
1 parent c98927b commit 5af4015
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/combobox-framework.ts
Original file line number Diff line number Diff line change
Expand Up @@ -323,7 +323,7 @@ export default class ComboboxFramework extends HTMLElement {
* @returns {void}
*/
public toggleList(
newValue: boolean = this._input!.getAttribute("aria-expanded") === "true",
newValue: boolean = this._input!.getAttribute("aria-expanded") !== true.toString(),
): void {
this._input!.setAttribute("aria-expanded", `${newValue}`);
if (!newValue) this.unfocusAllItems();
Expand Down

0 comments on commit 5af4015

Please sign in to comment.