@cscfi/csc-ui 2.1.4 → 2.1.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.
@@ -1919,6 +1919,12 @@ const CSelect = class {
1919
1919
  const isOpen = event.detail;
1920
1920
  this.dropdownVisible = isOpen;
1921
1921
  }
1922
+ onValueChanged() {
1923
+ var _a;
1924
+ if (!this.value && this.optionAsSelection) {
1925
+ (_a = this._selectionElement) === null || _a === void 0 ? void 0 : _a.replaceChildren();
1926
+ }
1927
+ }
1922
1928
  onSelectOption(event) {
1923
1929
  this._dropdownElement.close();
1924
1930
  const { name, value } = event.detail;
@@ -2021,6 +2027,9 @@ const CSelect = class {
2021
2027
  }
2022
2028
  static get formAssociated() { return true; }
2023
2029
  get el() { return index.getElement(this); }
2030
+ static get watchers() { return {
2031
+ "value": ["onValueChanged"]
2032
+ }; }
2024
2033
  };
2025
2034
  CSelect._uniqueId = 0;
2026
2035
  CSelect.style = cSelectCss;