From e6bdf94bb9448f97947411ac9ce04c69cdf58d4f Mon Sep 17 00:00:00 2001 From: michael-n-cooper Date: Fri, 28 Feb 2020 21:59:25 +0000 Subject: [PATCH] Generated by TRAVIS-CI b543058379f8180be0c76fca7b52f7fc2ec41ad8 Combobox with list and both autocomplete: Fix issue with listbox not updating (pull #1335) * fixed #1332 by adding call to filterOptions after updating filter * added update filterOptions when ever backspace is pressed Co-authored-by: Matt King --- examples/combobox/js/combobox-autocomplete.js | 3 +++ index.html | 1 + 2 files changed, 4 insertions(+) diff --git a/examples/combobox/js/combobox-autocomplete.js b/examples/combobox/js/combobox-autocomplete.js index ebf61dd2f4..8bae873d66 100644 --- a/examples/combobox/js/combobox-autocomplete.js +++ b/examples/combobox/js/combobox-autocomplete.js @@ -391,6 +391,7 @@ ComboboxAutocomplete.prototype.handleComboboxKeyUp = function (event) { if (this.comboboxNode.value.length < this.filter.length) { this.filter = this.comboboxNode.value; this.option = null; + this.filterOptions() } if (event.key === "Escape" || event.key === "Esc") { @@ -402,7 +403,9 @@ ComboboxAutocomplete.prototype.handleComboboxKeyUp = function (event) { case "Backspace": this.setVisualFocusCombobox(); this.setCurrentOptionStyle(false); + this.filter = this.comboboxNode.value; this.option = null; + this.filterOptions() flag = true; break; diff --git a/index.html b/index.html index e61c77d9e7..99cc950b44 100644 --- a/index.html +++ b/index.html @@ -2610,6 +2610,7 @@

ExamplesScrollable Listbox Example: Single-select listbox that scrolls to reveal more options, similar to HTML select with size attribute greater than one.
  • Collapsible Dropdown Listbox Example: Single-select collapsible listbox that expands when activated, similar to HTML select with the attribute size="1".
  • Example Listboxes with Rearrangeable Options: Examples of both single-select and multi-select listboxes with accompanying toolbars where options can be added, moved, and removed.
  • +
  • Listbox Example with Grouped Options: Single-select listbox with grouped options, similar to an HTML select with optgroup children.