@simplybusiness/mobius 5.31.4 → 5.31.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # Changelog
2
2
 
3
+ ## 5.31.6
4
+
5
+ ### Patch Changes
6
+
7
+ - 0311105: Fix Combobox; in async mode, only show options list when there are options to display"
8
+
9
+ ## 5.31.5
10
+
11
+ ### Patch Changes
12
+
13
+ - Updated dependencies [412ee41]
14
+ - @simplybusiness/icons@4.31.1
15
+
3
16
  ## 5.31.4
4
17
 
5
18
  ### Patch Changes
package/dist/cjs/index.js CHANGED
@@ -1581,7 +1581,6 @@ var ComboboxInner = (0, import_react25.forwardRef)(
1581
1581
  const handleInputChange = (e) => {
1582
1582
  const newValue = e.target.value;
1583
1583
  setInputValue(newValue);
1584
- setIsOpen(true);
1585
1584
  clearHighlight();
1586
1585
  onChange?.(e);
1587
1586
  };
@@ -1679,6 +1678,11 @@ var ComboboxInner = (0, import_react25.forwardRef)(
1679
1678
  setInputValue(value);
1680
1679
  }
1681
1680
  }, [value]);
1681
+ (0, import_react25.useEffect)(() => {
1682
+ if (asyncOptions) {
1683
+ setIsOpen(!!filteredOptions && filteredOptions.length > 0);
1684
+ }
1685
+ }, [filteredOptions, asyncOptions]);
1682
1686
  const classes = (0, import_dedupe10.default)(
1683
1687
  "mobius mobius-combobox",
1684
1688
  {