@visma-swno/vsn-navigation 1.4.0-beta.8 → 1.4.0

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.
@@ -147,6 +147,8 @@ export declare class VSNNavigation extends LitElement {
147
147
  helpUrl?: string;
148
148
  /** Configuration for the feedback component */
149
149
  feedback: FeedbackConfig | null;
150
+ /** Keep the module switcher permanently open (non-closable). Default false. */
151
+ moduleSwitcherAlwaysOpen: boolean;
150
152
  /** Show notification icon in the top bar */
151
153
  showNotification: boolean;
152
154
  /** Notification icon shows active state */
@@ -177,7 +179,8 @@ export declare class VSNNavigation extends LitElement {
177
179
  updated(changed: Map<string, unknown>): void;
178
180
  connectedCallback(): void;
179
181
  disconnectedCallback(): void;
180
- /** CTRL+O (Cmd+O on Mac) opens the side-bar and focuses the search field (if enabled). */
182
+ /** Toggles the side-bar: opens and focuses search when closed, closes when open.
183
+ * Shortcut: Cmd+O on Mac (Ctrl+O also accepted as a Safari fallback); Ctrl+O on all other platforms. */
181
184
  private _onShortcut;
182
185
  private _onEscape;
183
186
  private _onTopBarClick;
@@ -206,6 +209,8 @@ export declare type VsnNavigation = {
206
209
  auth?: VsnAuth;
207
210
  /** Configuration for the feedback component */
208
211
  feedback?: FeedbackConfig | null;
212
+ /** Keep the module switcher permanently open (non-closable). Default false. */
213
+ moduleSwitcherAlwaysOpen?: boolean;
209
214
  };
210
215
 
211
216
  export declare class VSNSkipToMain extends LitElement {
@@ -129,7 +129,7 @@ var w = 0, we = (e) => (se(((e, t) => _e(Ce, e, t))), x = xe = e.sourceLocale, S
129
129
  if (typeof navigator > "u") return !1;
130
130
  let e = navigator.userAgentData?.platform ?? navigator.platform ?? "";
131
131
  return /mac/i.test(e);
132
- }, Oe = (e) => !e.shiftKey && !e.altKey && (De() ? e.metaKey && !e.ctrlKey : e.ctrlKey && !e.metaKey), T = (e) => e.shiftKey || e.altKey || e.ctrlKey || e.metaKey, E = (e) => !T(e), ke = () => v("Choose a service"), Ae = () => v("Search"), je = () => De() ? "Cmd+O" : "CTRL+O", Me = (e) => v(_`Type at least ${e} characters to search`), Ne = () => v("Menu items"), Pe = () => v("Load more"), Fe = () => v("Services"), Ie = () => v("Services"), D = "menu", Le = "survicate-sdk", Re = "ui-components-feedback", ze = (e) => `https://survey.survicate.com/workspaces/${e}/web_surveys.js`;
132
+ }, Oe = (e) => !e.shiftKey && !e.altKey && (De() ? e.ctrlKey !== e.metaKey : e.ctrlKey && !e.metaKey), T = (e) => e.shiftKey || e.altKey || e.ctrlKey || e.metaKey, E = (e) => !T(e), ke = () => v("Choose a service"), Ae = () => v("Search"), je = () => De() ? "Cmd+O / Ctrl+O" : "Ctrl+O", Me = (e) => v(_`Type at least ${e} characters to search`), Ne = () => v("Menu items"), Pe = () => v("Load more"), Fe = () => v("Services"), Ie = () => v("Services"), D = "menu", Le = "survicate-sdk", Re = "ui-components-feedback", ze = (e) => `https://survey.survicate.com/workspaces/${e}/web_surveys.js`;
133
133
  //#endregion
134
134
  //#region src/shared/icons.ts
135
135
  function O(e, t = 24, r) {
@@ -1156,7 +1156,7 @@ var B = class extends e {
1156
1156
  return this;
1157
1157
  }
1158
1158
  constructor() {
1159
- super(), this.modules = [], this.modulesLoading = !1, this.hasMenu = !1, this.moduleSwitcherMaxHeight = 0, this.searchValue = "", this.searchLoading = !1, this.expanded = !1, this._keyboard = new St(this), new _t(this, [".ga-side-navigation__switcher-dropdown", ".ga-side-navigation__switcher"], () => {
1159
+ super(), this.modules = [], this.modulesLoading = !1, this.moduleSwitcherAlwaysOpen = !1, this.moduleSwitcherMaxHeight = 0, this.searchValue = "", this.searchLoading = !1, this.expanded = !1, this._keyboard = new St(this), new _t(this, [".ga-side-navigation__switcher-dropdown", ".ga-side-navigation__switcher"], () => {
1160
1160
  this.canClose && (this.expanded = !1);
1161
1161
  }), new I(this, () => this.canClose && this.expanded, ".vsn-switcher-anchor");
1162
1162
  }
@@ -1170,7 +1170,7 @@ var B = class extends e {
1170
1170
  <div class="ga-side-navigation__header">
1171
1171
  <div class="vsn-switcher-anchor"
1172
1172
  @keydown=${this._keyboard.onSwitcherKeydown}>
1173
- ${this.canClose ? n`
1173
+ ${this.canToggle ? n`
1174
1174
  <button type="button"
1175
1175
  class="ga-side-navigation__switcher ${this.expanded ? "ga-side-navigation__switcher--active" : ""}"
1176
1176
  aria-label=${v(_`Service menu, ${e.title}`)}
@@ -1183,9 +1183,9 @@ var B = class extends e {
1183
1183
  </span>
1184
1184
  </button>
1185
1185
  ` : n`
1186
- <div class="ga-side-navigation__switcher ga-side-navigation__switcher--active"
1187
- aria-expanded="true"
1188
- aria-haspopup="menu"
1186
+ <div class="ga-side-navigation__switcher ${this._isOpen ? "ga-side-navigation__switcher--active" : ""}"
1187
+ aria-expanded="${this._isOpen}"
1188
+ aria-haspopup="${this._isOpen ? "menu" : "false"}"
1189
1189
  title="">
1190
1190
  <span class="ga-side-navigation__switcher-title">${e.title}</span>
1191
1191
  <span class="ga-side-navigation__switcher-action">
@@ -1194,10 +1194,10 @@ var B = class extends e {
1194
1194
  </div>
1195
1195
  `}
1196
1196
 
1197
- ${f(this.expanded, () => n`
1197
+ ${f(this._isOpen, () => n`
1198
1198
  <vsn-switcher-menu
1199
- .items=${e.kind === "loading" ? [] : e.available}
1200
- .loading=${e.kind === "loading"}
1199
+ .items=${e.kind === "module-loading" ? [] : e.available}
1200
+ .loading=${e.kind === "module-loading"}
1201
1201
  .maxHeight=${this.moduleSwitcherMaxHeight}
1202
1202
  @item-select=${this._onItemSelect}>
1203
1203
  </vsn-switcher-menu>`)}
@@ -1214,38 +1214,33 @@ var B = class extends e {
1214
1214
  }
1215
1215
  get _state() {
1216
1216
  if (this.modulesLoading) return {
1217
- kind: "loading",
1217
+ kind: "module-loading",
1218
1218
  title: this.activeModuleLabel || Fe()
1219
1219
  };
1220
1220
  let e = this.modules.find((e) => e.id === this.activeModuleId);
1221
1221
  return e ? {
1222
- kind: "active",
1222
+ kind: "module-selected",
1223
1223
  title: e.label,
1224
1224
  available: this.modules.filter((t) => t.id !== e.id)
1225
- } : this.activeModuleId && this.activeModuleLabel ? {
1226
- kind: "active",
1227
- title: this.activeModuleLabel,
1228
- available: this.modules
1229
1225
  } : {
1230
- kind: "no-active",
1231
- title: Fe(),
1226
+ kind: "module-unmatched",
1227
+ title: this.activeModuleId && this.activeModuleLabel ? this.activeModuleLabel : Fe(),
1232
1228
  available: this.modules
1233
1229
  };
1234
1230
  }
1235
1231
  get canClose() {
1236
- return this.hasMenu ? !0 : this._state.kind !== "no-active";
1232
+ return !this.moduleSwitcherAlwaysOpen;
1237
1233
  }
1238
1234
  get hasAvailableItems() {
1239
1235
  let e = this._state;
1240
- return e.kind !== "loading" && e.available.length > 0;
1236
+ return e.kind !== "module-loading" && e.available.length > 0;
1237
+ }
1238
+ get _isOpen() {
1239
+ return this.moduleSwitcherAlwaysOpen || this.expanded;
1241
1240
  }
1242
1241
  get canToggle() {
1243
1242
  return this.canClose && (this.hasAvailableItems || this.modulesLoading || this.expanded);
1244
1243
  }
1245
- willUpdate() {
1246
- let e = this._state;
1247
- e.kind !== "loading" && (this.hasMenu || e.kind !== "no-active" || e.available.length === 0 || (this.expanded = !0));
1248
- }
1249
1244
  reset() {
1250
1245
  this.expanded = !1;
1251
1246
  }
@@ -1269,7 +1264,7 @@ var B = class extends e {
1269
1264
  }), !0);
1270
1265
  }
1271
1266
  };
1272
- j([s({ attribute: !1 })], B.prototype, "modules", void 0), j([s()], B.prototype, "activeModuleId", void 0), j([s()], B.prototype, "activeModuleLabel", void 0), j([s({ type: Boolean })], B.prototype, "modulesLoading", void 0), j([s({ type: Boolean })], B.prototype, "hasMenu", void 0), j([s({ attribute: !1 })], B.prototype, "moduleSwitcherMaxHeight", void 0), j([s({ attribute: !1 })], B.prototype, "search", void 0), j([s()], B.prototype, "searchValue", void 0), j([s({ type: Boolean })], B.prototype, "searchLoading", void 0), j([s({
1267
+ j([s({ attribute: !1 })], B.prototype, "modules", void 0), j([s()], B.prototype, "activeModuleId", void 0), j([s()], B.prototype, "activeModuleLabel", void 0), j([s({ type: Boolean })], B.prototype, "modulesLoading", void 0), j([s({ type: Boolean })], B.prototype, "moduleSwitcherAlwaysOpen", void 0), j([s({ attribute: !1 })], B.prototype, "moduleSwitcherMaxHeight", void 0), j([s({ attribute: !1 })], B.prototype, "search", void 0), j([s()], B.prototype, "searchValue", void 0), j([s({ type: Boolean })], B.prototype, "searchLoading", void 0), j([s({
1273
1268
  type: Boolean,
1274
1269
  reflect: !0
1275
1270
  })], B.prototype, "expanded", void 0), B = j([y(), o("vsn-header")], B);
@@ -1519,6 +1514,7 @@ var kt = "en", At = [
1519
1514
  s352719d86112de9a: "Hjælp",
1520
1515
  s387a4a41718122cb: _`${0} resultater`,
1521
1516
  s3fb7db4771812f0c: "Hvis problemet fortsætter, genindlæs siden eller kontakt support.",
1517
+ s442010a1a0adb81d: "Vis skjulte brødkrummer",
1522
1518
  s457d59d649765619: "Gå til hovedindhold",
1523
1519
  s4b0c6b66b4efd7d8: "Vælg en tjeneste",
1524
1520
  s58a1dace5a9acc5b: _`Tjenestemenu, ${0}`,
@@ -1556,6 +1552,7 @@ var kt = "en", At = [
1556
1552
  s352719d86112de9a: "Ohje",
1557
1553
  s387a4a41718122cb: _`${0} tulosta`,
1558
1554
  s3fb7db4771812f0c: "Jos ongelma jatkuu, lataa sivu uudelleen tai ota yhteyttä tukeen.",
1555
+ s442010a1a0adb81d: "Näytä piilotetut murupolun kohteet",
1559
1556
  s457d59d649765619: "Siirry pääsisältöön",
1560
1557
  s4b0c6b66b4efd7d8: "Valitse palvelu",
1561
1558
  s58a1dace5a9acc5b: _`Palveluvalikko, ${0}`,
@@ -1593,6 +1590,7 @@ var kt = "en", At = [
1593
1590
  s352719d86112de9a: "Hulp",
1594
1591
  s387a4a41718122cb: _`${0} resultaten`,
1595
1592
  s3fb7db4771812f0c: "Als het probleem aanhoudt, laad de pagina opnieuw of neem contact op met ondersteuning.",
1593
+ s442010a1a0adb81d: "Toon verborgen broodkruimels",
1596
1594
  s457d59d649765619: "Ga naar hoofdinhoud",
1597
1595
  s4b0c6b66b4efd7d8: "Kies een service",
1598
1596
  s58a1dace5a9acc5b: _`Servicemenu, ${0}`,
@@ -1630,6 +1628,7 @@ var kt = "en", At = [
1630
1628
  s352719d86112de9a: "Hjelp",
1631
1629
  s387a4a41718122cb: _`${0} resultater`,
1632
1630
  s3fb7db4771812f0c: "Hvis problemet vedvarer, last inn siden på nytt eller kontakt støtte.",
1631
+ s442010a1a0adb81d: "Vis skjulte brødsmuleelementer",
1633
1632
  s457d59d649765619: "Hopp til hovedinnhold",
1634
1633
  s4b0c6b66b4efd7d8: "Velg en tjeneste",
1635
1634
  s58a1dace5a9acc5b: _`Tjenestemeny, ${0}`,
@@ -1667,6 +1666,7 @@ var kt = "en", At = [
1667
1666
  s352719d86112de9a: "Hjälp",
1668
1667
  s387a4a41718122cb: _`${0} resultat`,
1669
1668
  s3fb7db4771812f0c: "Om problemet kvarstår, ladda om sidan eller kontakta support.",
1669
+ s442010a1a0adb81d: "Visa dolda brödsmulor",
1670
1670
  s457d59d649765619: "Hoppa till huvudinnehåll",
1671
1671
  s4b0c6b66b4efd7d8: "Välj en tjänst",
1672
1672
  s58a1dace5a9acc5b: _`Tjänstemeny, ${0}`,
@@ -2076,7 +2076,7 @@ var kt = "en", At = [
2076
2076
  };
2077
2077
  }
2078
2078
  constructor() {
2079
- super(), this.modules = [], this.modulesLoading = !1, this.lang = "en", this.error = !1, this.open = !1, this._searchQuery = "", this._searchLoading = !1, this._activeScopeId = D, this._searchLoadingMore = !1, this._moduleSwitcherMaxHeight = 0, this._hasPageTitle = !1, this._navFooterKeyboard = new $t(this), this._customWidthPerLanguage = { fi: "30em" }, this._onNavigate = (e) => {
2079
+ super(), this.modules = [], this.modulesLoading = !1, this.moduleSwitcherAlwaysOpen = !1, this.lang = "en", this.error = !1, this.open = !1, this._searchQuery = "", this._searchLoading = !1, this._activeScopeId = D, this._searchLoadingMore = !1, this._moduleSwitcherMaxHeight = 0, this._hasPageTitle = !1, this._navFooterKeyboard = new $t(this), this._customWidthPerLanguage = { fi: "30em" }, this._onNavigate = (e) => {
2080
2080
  this._searchQuery = "", this._searchResults = void 0, this.dispatchEvent(new CustomEvent("vsn-side-bar-close", {
2081
2081
  bubbles: !0,
2082
2082
  composed: !0
@@ -2262,7 +2262,7 @@ var kt = "en", At = [
2262
2262
  .activeModuleId=${this.activeModuleId}
2263
2263
  .activeModuleLabel=${this.activeModuleLabel}
2264
2264
  .modulesLoading=${this.modulesLoading}
2265
- .hasMenu=${(this.menu?.items.length ?? 0) > 0}
2265
+ .moduleSwitcherAlwaysOpen=${this.moduleSwitcherAlwaysOpen}
2266
2266
  .search=${e}
2267
2267
  .searchValue=${this._searchQuery}
2268
2268
  .searchLoading=${this._searchLoading}
@@ -2304,7 +2304,7 @@ var kt = "en", At = [
2304
2304
  `;
2305
2305
  }
2306
2306
  };
2307
- j([s({ attribute: !1 })], K.prototype, "modules", void 0), j([s()], K.prototype, "activeModuleId", void 0), j([s()], K.prototype, "activeModuleLabel", void 0), j([s({ type: Boolean })], K.prototype, "modulesLoading", void 0), j([s()], K.prototype, "lang", void 0), j([s({ attribute: !1 })], K.prototype, "auth", void 0), j([s({ type: Boolean })], K.prototype, "error", void 0), j([s({
2307
+ j([s({ attribute: !1 })], K.prototype, "modules", void 0), j([s()], K.prototype, "activeModuleId", void 0), j([s()], K.prototype, "activeModuleLabel", void 0), j([s({ type: Boolean })], K.prototype, "modulesLoading", void 0), j([s({ type: Boolean })], K.prototype, "moduleSwitcherAlwaysOpen", void 0), j([s()], K.prototype, "lang", void 0), j([s({ attribute: !1 })], K.prototype, "auth", void 0), j([s({ type: Boolean })], K.prototype, "error", void 0), j([s({
2308
2308
  type: Boolean,
2309
2309
  reflect: !0
2310
2310
  })], K.prototype, "open", void 0), j([s({ attribute: !1 })], K.prototype, "menu", void 0), j([l()], K.prototype, "_searchQuery", void 0), j([l()], K.prototype, "_searchResults", void 0), j([l()], K.prototype, "_searchLoading", void 0), j([l()], K.prototype, "_activeScopeId", void 0), j([l()], K.prototype, "_searchError", void 0), j([l()], K.prototype, "_searchNextCursor", void 0), j([l()], K.prototype, "_searchLoadingMore", void 0), j([l()], K.prototype, "_moduleSwitcherMaxHeight", void 0), j([l()], K.prototype, "_hasPageTitle", void 0), K = j([o("vsn-side-bar")], K);
@@ -2531,6 +2531,11 @@ var J = class extends e {
2531
2531
  padding-inline: calc(0.25rem * var(--ga-base-scaling-factor, 1));
2532
2532
  }
2533
2533
 
2534
+ a.ga-breadcrumb-item__trigger {
2535
+ color: inherit;
2536
+ text-decoration: none;
2537
+ }
2538
+
2534
2539
  /* Focus indicator for keyboard navigation inside breadcrumb dropdowns */
2535
2540
  .ga-breadcrumb-item__menu .ga-side-navigation__item:focus-visible {
2536
2541
  outline: var(--_focus-ring-offset) solid var(--ga-color-border-focus);
@@ -2566,7 +2571,7 @@ var J = class extends e {
2566
2571
  if (this._displayMode !== "overflow") return;
2567
2572
  let e = this.shadowRoot?.querySelector(".ga-breadcrumb");
2568
2573
  if (!e) return;
2569
- let t = Math.max(0, this._breadcrumbPath.length - 1);
2574
+ let t = this.tree?.pageTitle ? this._breadcrumbPath.length : Math.max(0, this._breadcrumbPath.length - 1);
2570
2575
  for (; e.scrollWidth > e.clientWidth + 1 && this._overflowCount < t;) this._overflowCount++, await this.updateComplete;
2571
2576
  }
2572
2577
  async _tryExpandOverflow() {
@@ -2603,12 +2608,12 @@ var J = class extends e {
2603
2608
  _popoverItemTriggerId(e) {
2604
2609
  return `vsn-bc-item-${e}-trigger`;
2605
2610
  }
2606
- _onLeafAsAncestorClick(e) {
2607
- this.dispatchEvent(new CustomEvent("vsn-menu-item-changed", {
2608
- detail: e,
2611
+ _onLeafAsAncestorClick(e, t) {
2612
+ e.button !== 0 || T(e) || (e.preventDefault(), this.dispatchEvent(new CustomEvent("vsn-menu-item-changed", {
2613
+ detail: t,
2609
2614
  bubbles: !0,
2610
2615
  composed: !0
2611
- }));
2616
+ })));
2612
2617
  }
2613
2618
  _handlePopoverBeforeToggle(e, t) {
2614
2619
  if (t.newState !== "open") return;
@@ -2717,14 +2722,17 @@ var J = class extends e {
2717
2722
  }));
2718
2723
  }
2719
2724
  _renderLeafAsAncestor(e) {
2725
+ let t = k(e) ? n`<a class="ga-breadcrumb-item__trigger" href=${e.url} @click=${(t) => this._onLeafAsAncestorClick(t, e)}>
2726
+ <span class="ga-breadcrumb-item__label">${e.label ?? ""}</span>
2727
+ </a>` : n`<span class="ga-breadcrumb-item__trigger">
2728
+ <span class="ga-breadcrumb-item__label">${e.label ?? ""}</span>
2729
+ </span>`;
2720
2730
  return n`
2721
2731
  <div class="ga-breadcrumb-item ga-breadcrumb-item--link"
2722
2732
  aria-describedby=${this._tooltip ? "vsn-breadcrumb-tooltip" : r}
2723
2733
  data-tooltip-label="${e.label ?? ""}" @mouseenter=${this._onBreadcrumbMouseEnter}
2724
- @mouseleave=${this._onBreadcrumbMouseLeave} @click="${() => this._onLeafAsAncestorClick(e)}">
2725
- <span class="ga-breadcrumb-item__trigger">
2726
- <span class="ga-breadcrumb-item__label">${e.label ?? ""}</span>
2727
- </span>
2734
+ @mouseleave=${this._onBreadcrumbMouseLeave}>
2735
+ ${t}
2728
2736
  <span class="ga-breadcrumb-item__separator" aria-hidden="true">/</span>
2729
2737
  </div>`;
2730
2738
  }
@@ -2788,44 +2796,46 @@ var J = class extends e {
2788
2796
  let e = this._breadcrumbPath, t = this.tree?.pageTitle;
2789
2797
  return n`${this._renderModules()}${e.map((n, r) => r === e.length - 1 ? this._renderLastItem(n, r, t) : this._renderBreadcrumbItem(n, r))}`;
2790
2798
  }
2799
+ _renderOverflowDropdown(e) {
2800
+ return n`
2801
+ <div class="ga-breadcrumb-item ga-breadcrumb-item--overflow">
2802
+ <button
2803
+ id="vsn-bc-overflow-trigger"
2804
+ class="ga-breadcrumb-item__trigger"
2805
+ type="button"
2806
+ aria-label=${v("Show hidden breadcrumb items")}
2807
+ aria-expanded=${this._openPopoverId === "vsn-bc-overflow-popover"}
2808
+ aria-haspopup="menu"
2809
+ popovertarget="vsn-bc-overflow-popover"
2810
+ >
2811
+ <span class="ga-breadcrumb-item__label" aria-hidden="true">...</span>
2812
+ </button>
2813
+ <div
2814
+ id="vsn-bc-overflow-popover"
2815
+ class="ga-breadcrumb-item__menu"
2816
+ popover="auto"
2817
+ @beforetoggle=${(e) => this._handlePopoverBeforeToggle("vsn-bc-overflow-trigger", e)}
2818
+ @toggle=${(e) => this._handlePopoverToggle("vsn-bc-overflow-popover", e)}
2819
+ @vsn-breadcrumb-menu-close=${() => this._handleMenuClose("vsn-bc-overflow-trigger", "vsn-bc-overflow-popover")}
2820
+ >
2821
+ <vsn-breadcrumb-menu
2822
+ .treeList=${e}
2823
+ @vsn-breadcrumb-menu-leaf-select=${(e) => this._handleLeafSelect(e, "vsn-bc-overflow-popover")}
2824
+ ></vsn-breadcrumb-menu>
2825
+ </div>
2826
+ <span class="ga-breadcrumb-item__separator" aria-hidden="true">/</span>
2827
+ </div>`;
2828
+ }
2791
2829
  _renderOverflowBreadcrumbs() {
2792
2830
  let e = this._breadcrumbPath, t = this.tree?.pageTitle;
2793
2831
  if (e.length === 0) return n`${this._renderModules()}`;
2794
2832
  let r = e[e.length - 1];
2795
- if (e.length === 1) return n`${this._renderModules()}${this._renderLastItem(r, 0, t)}`;
2796
- let i = [e[0]], a = e.slice(this._overflowCount, e.length - 1);
2833
+ if (e.length === 1) return t && this._overflowCount >= e.length ? n`${this._renderOverflowDropdown([r])}${this._renderPageTitle(t)}` : n`${this._renderModules()}${this._renderLastItem(r, 0, t)}`;
2834
+ let i = [e[0]], a = e.slice(this._overflowCount, e.length - 1), o = !!t && this._overflowCount >= e.length;
2797
2835
  return n`
2798
- ${this._overflowCount === 0 ? this._renderModules() : ""}
2799
- ${this._overflowCount > 0 ? n`
2800
- <div class="ga-breadcrumb-item ga-breadcrumb-item--overflow">
2801
- <button
2802
- id="vsn-bc-overflow-trigger"
2803
- class="ga-breadcrumb-item__trigger"
2804
- type="button"
2805
- aria-expanded=${this._openPopoverId === "vsn-bc-overflow-popover"}
2806
- aria-haspopup="menu"
2807
- popovertarget="vsn-bc-overflow-popover"
2808
- >
2809
- <span class="ga-breadcrumb-item__label">...</span>
2810
- </button>
2811
- <div
2812
- id="vsn-bc-overflow-popover"
2813
- class="ga-breadcrumb-item__menu"
2814
- popover="auto"
2815
- @beforetoggle=${(e) => this._handlePopoverBeforeToggle("vsn-bc-overflow-trigger", e)}
2816
- @toggle=${(e) => this._handlePopoverToggle("vsn-bc-overflow-popover", e)}
2817
- @vsn-breadcrumb-menu-close=${() => this._handleMenuClose("vsn-bc-overflow-trigger", "vsn-bc-overflow-popover")}
2818
- >
2819
- <vsn-breadcrumb-menu
2820
- .treeList=${i}
2821
- @vsn-breadcrumb-menu-leaf-select=${(e) => this._handleLeafSelect(e, "vsn-bc-overflow-popover")}
2822
- ></vsn-breadcrumb-menu>
2823
- </div>
2824
- <span class="ga-breadcrumb-item__separator" aria-hidden="true">/</span>
2825
- </div>
2826
- ` : ""}
2836
+ ${this._overflowCount === 0 ? this._renderModules() : this._renderOverflowDropdown(i)}
2827
2837
  ${a.map((e, t) => this._renderBreadcrumbItem(e, this._overflowCount + t))}
2828
- ${this._renderLastItem(r, e.length - 1, t)}`;
2838
+ ${o ? this._renderPageTitle(t) : this._renderLastItem(r, e.length - 1, t)}`;
2829
2839
  }
2830
2840
  _renderMobileBreadcrumbs() {
2831
2841
  let e = this._breadcrumbPath;
@@ -3342,7 +3352,7 @@ j([s()], Q.prototype, "href", void 0), Q = j([y(), o("vsn-skip-to-main")], Q);
3342
3352
  //#region src/components/vsn-navigation.ts
3343
3353
  var $ = class extends e {
3344
3354
  constructor(...e) {
3345
- super(...e), this.lang = "en", this.showHelp = !1, this.feedback = null, this.showNotification = !1, this.notificationActive = !1, this.open = !1, this._resolvedModules = [], this._modulesLoading = !1, this._modulesLoadToken = 0, this._restoreFocusToToggle = !1, this._onTopBarMenuItemChanged = (e) => {
3355
+ super(...e), this.lang = "en", this.showHelp = !1, this.feedback = null, this.moduleSwitcherAlwaysOpen = !1, this.showNotification = !1, this.notificationActive = !1, this.open = !1, this._resolvedModules = [], this._modulesLoading = !1, this._modulesLoadToken = 0, this._restoreFocusToToggle = !1, this._onTopBarMenuItemChanged = (e) => {
3346
3356
  e.stopPropagation(), this.dispatchEvent(new CustomEvent("vsn-menu-item-changed", {
3347
3357
  bubbles: !0,
3348
3358
  composed: !0,
@@ -3360,11 +3370,15 @@ var $ = class extends e {
3360
3370
  detail: t
3361
3371
  }));
3362
3372
  }, this._onShortcut = (e) => {
3363
- e.defaultPrevented || !Oe(e) || e.key.toLowerCase() !== "o" || (e.preventDefault(), this.dispatchEvent(new CustomEvent("vsn-open", {
3364
- cancelable: !0,
3365
- bubbles: !0,
3366
- composed: !0
3367
- })) && this._openAndFocusSearch());
3373
+ if (!e.defaultPrevented && !e.repeat && !(!Oe(e) || e.key.toLowerCase() !== "o")) if (e.preventDefault(), this.open) this._closeSideBar();
3374
+ else {
3375
+ if (!this.dispatchEvent(new CustomEvent("vsn-open", {
3376
+ cancelable: !0,
3377
+ bubbles: !0,
3378
+ composed: !0
3379
+ }))) return;
3380
+ this._openAndFocusSearch();
3381
+ }
3368
3382
  }, this._onEscape = (e) => {
3369
3383
  e.defaultPrevented || this.open && E(e) && e.key === "Escape" && (e.preventDefault(), this.open = !1);
3370
3384
  };
@@ -3491,6 +3505,7 @@ var $ = class extends e {
3491
3505
  .activeModuleId=${this.modules?.activeModuleId}
3492
3506
  .activeModuleLabel=${this.modules?.activeModuleLabel}
3493
3507
  .modulesLoading=${this._modulesLoading}
3508
+ .moduleSwitcherAlwaysOpen=${this.moduleSwitcherAlwaysOpen}
3494
3509
  .auth=${this.auth}
3495
3510
  ?open=${this.open}
3496
3511
  @vsn-side-bar-close=${this._closeSideBar}
@@ -3509,6 +3524,9 @@ j([s()], $.prototype, "lang", void 0), j([s({ attribute: !1 })], $.prototype, "t
3509
3524
  type: Boolean,
3510
3525
  attribute: "show-help"
3511
3526
  })], $.prototype, "showHelp", void 0), j([s({ attribute: "help-url" })], $.prototype, "helpUrl", void 0), j([s({ attribute: !1 })], $.prototype, "feedback", void 0), j([s({
3527
+ type: Boolean,
3528
+ attribute: "module-switcher-always-open"
3529
+ })], $.prototype, "moduleSwitcherAlwaysOpen", void 0), j([s({
3512
3530
  type: Boolean,
3513
3531
  attribute: "show-notification"
3514
3532
  })], $.prototype, "showNotification", void 0), j([s({