@triptease/tt-navbar 0.0.85 → 0.0.86

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,12 @@
1
1
  # @triptease/tt-navbar
2
2
 
3
+ ## 0.0.86
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [9497296]
8
+ - @triptease/tt-combobox@5.6.2
9
+
3
10
  ## 0.0.85
4
11
 
5
12
  ### Patch Changes
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @triptease/tt-navbar v0.0.85
2
+ * @triptease/tt-navbar v0.0.86
3
3
  */
4
4
 
5
5
  // src/Config.ts
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @triptease/tt-navbar v0.0.85
2
+ * @triptease/tt-navbar v0.0.86
3
3
  */
4
4
 
5
5
  // src/Routes.ts
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @triptease/tt-navbar v0.0.85
2
+ * @triptease/tt-navbar v0.0.86
3
3
  */
4
4
  var __defProp = Object.defineProperty;
5
5
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
@@ -1367,7 +1367,7 @@ var TtCombobox = class extends i4 {
1367
1367
  return this.internals.validity.valid && !this.invalid;
1368
1368
  }
1369
1369
  _renderCombobox() {
1370
- const placeHolderValue = i6([this.placeholder, this.disabled, this.value, this.activeOptions.length, this.selectAllPlaceholder], () => {
1370
+ const placeHolderValue = i6([this.placeholder, this.disabled, this.value, this.activeOptions.length, this.selectAllPlaceholder, this._filter], () => {
1371
1371
  if (this.placeholder) {
1372
1372
  return this.placeholder;
1373
1373
  }
@@ -1380,10 +1380,13 @@ var TtCombobox = class extends i4 {
1380
1380
  if (this.value.length === 1) {
1381
1381
  return Array.from(this._selectableVisibleOptions).find((option) => option.value === this.value[0])?.textContent?.trim();
1382
1382
  }
1383
- if (this._isAllSelected) {
1383
+ const permanentlyHiddenValues = Array.from(this.options).filter((option) => option.hidden).map((option) => option.value);
1384
+ const selectedCount = this.value.filter((val) => !permanentlyHiddenValues.includes(val)).length;
1385
+ const totalSelectableCount = this.options.length - permanentlyHiddenValues.length;
1386
+ if (this._filter === "" && selectedCount === totalSelectableCount && totalSelectableCount > 0) {
1384
1387
  return this.selectAllPlaceholder || "All options selected";
1385
1388
  }
1386
- return `${this._selectedVisibleOptions.length} options selected`;
1389
+ return `${selectedCount} options selected`;
1387
1390
  });
1388
1391
  return x` <input
1389
1392
  type="text"