@ojiepermana/angular 22.2.4 → 22.2.5

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.
Files changed (18) hide show
  1. package/fesm2022/{ojiepermana-angular-navigation-navigation-badge-count.component-4RIokl1C.mjs → ojiepermana-angular-navigation-navigation-badge-count.component-BYN_Vxm3.mjs} +36 -5
  2. package/fesm2022/{ojiepermana-angular-navigation-navigation-dockbar-menu.component-DC8rfxS5.mjs → ojiepermana-angular-navigation-navigation-dockbar-menu.component-Dlyt6eZr.mjs} +17 -32
  3. package/fesm2022/{ojiepermana-angular-navigation-navigation-entry-grid.component-meQb_EWZ.mjs → ojiepermana-angular-navigation-navigation-entry-grid.component-DeF_s1vE.mjs} +35 -20
  4. package/fesm2022/{ojiepermana-angular-navigation-navigation-flyout-menu.component-DRdw2G-c.mjs → ojiepermana-angular-navigation-navigation-flyout-menu.component-BOGL8MY0.mjs} +23 -4
  5. package/fesm2022/{ojiepermana-angular-navigation-navigation-horizontal.component-Bx1NcrWO.mjs → ojiepermana-angular-navigation-navigation-horizontal.component-Cb4bHM58.mjs} +29 -4
  6. package/fesm2022/{ojiepermana-angular-navigation-navigation-item.component-ERZNpmTZ.mjs → ojiepermana-angular-navigation-navigation-item.component-DLgcJQOC.mjs} +351 -108
  7. package/fesm2022/{ojiepermana-angular-navigation-navigation-list.component-D-oOKwHg.mjs → ojiepermana-angular-navigation-navigation-list.component-BYc3WCt8.mjs} +20 -1
  8. package/fesm2022/ojiepermana-angular-navigation.mjs +66 -15
  9. package/fesm2022/ojiepermana-angular-theme-layout-wrapper.mjs +48 -2
  10. package/fesm2022/ojiepermana-angular-theme-page-root.mjs +1 -0
  11. package/fesm2022/ojiepermana-angular-theme-shell.mjs +1 -0
  12. package/navigation/README.md +92 -3
  13. package/package.json +2 -2
  14. package/theme/styles/css/base/components.css +20 -0
  15. package/theme/styles/css/base/tokens.css +6 -0
  16. package/types/ojiepermana-angular-navigation-types.d.ts +3 -3
  17. package/types/ojiepermana-angular-navigation.d.ts +16 -0
  18. package/types/ojiepermana-angular-theme-layout-wrapper.d.ts +17 -3
@@ -3,7 +3,32 @@ import { Component, computed, input, isSignal } from "@angular/core";
3
3
  import { cn } from "@ojiepermana/angular/component/utils/core";
4
4
  import { formatNavigationBadgeCount } from "@ojiepermana/angular/navigation/types";
5
5
  import { toObservable, toSignal } from "@angular/core/rxjs-interop";
6
- import { catchError, isObservable, of, switchMap } from "rxjs";
6
+ import { catchError, isObservable, map, of, switchMap } from "rxjs";
7
+ var __defProp = Object.defineProperty;
8
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
9
+ var __getOwnPropNames = Object.getOwnPropertyNames;
10
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
11
+ var __exportAll = (all, no_symbols) => {
12
+ let target = {};
13
+ for (var name in all) __defProp(target, name, {
14
+ get: all[name],
15
+ enumerable: true
16
+ });
17
+ if (!no_symbols) __defProp(target, Symbol.toStringTag, { value: "Module" });
18
+ return target;
19
+ };
20
+ var __copyProps = (to, from, except, desc) => {
21
+ if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
22
+ key = keys[i];
23
+ if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
24
+ get: ((k) => from[k]).bind(null, key),
25
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
26
+ });
27
+ }
28
+ return to;
29
+ };
30
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
31
+ var navigation_badge_count_component_exports = /* @__PURE__ */ __exportAll({ NavigationBadgeCountComponent: () => NavigationBadgeCountComponent });
7
32
  var NavigationBadgeCountComponent = class NavigationBadgeCountComponent {
8
33
  badge = input(null, ...ngDevMode ? [{ debugName: "badge" }] : /* istanbul ignore next */ []);
9
34
  class = input("", ...ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []);
@@ -11,10 +36,16 @@ var NavigationBadgeCountComponent = class NavigationBadgeCountComponent {
11
36
  const value = this.badge()?.value;
12
37
  return isObservable(value) ? value : of(null);
13
38
  }, ...ngDevMode ? [{ debugName: "observableSource" }] : /* istanbul ignore next */ []);
14
- observableValue = toSignal(toObservable(this.observableSource).pipe(switchMap((source) => source.pipe(catchError(() => of(null))))), { initialValue: null });
39
+ observableValue = toSignal(toObservable(this.observableSource).pipe(switchMap((source) => source.pipe(catchError(() => of(null)), map((value) => ({
40
+ source,
41
+ value
42
+ }))))), { initialValue: null });
15
43
  rawValue() {
16
44
  const value = this.badge()?.value;
17
- if (isObservable(value)) return this.observableValue();
45
+ if (isObservable(value)) {
46
+ const snapshot = this.observableValue();
47
+ return snapshot?.source === value ? snapshot.value : null;
48
+ }
18
49
  if (isSignal(value)) return value();
19
50
  if (typeof value === "function") return value();
20
51
  return value;
@@ -31,7 +62,7 @@ var NavigationBadgeCountComponent = class NavigationBadgeCountComponent {
31
62
  accessibleLabel: (typeof label === "function" ? label(count) : label)?.trim() || `${count} items`
32
63
  };
33
64
  }
34
- badgeClasses = computed(() => cn("nav-badge inline-flex h-5 min-w-5 items-center justify-center rounded-full bg-destructive px-1 text-xs font-semibold text-destructive-foreground", this.badge()?.classes, this.class()), ...ngDevMode ? [{ debugName: "badgeClasses" }] : /* istanbul ignore next */ []);
65
+ badgeClasses = computed(() => cn("nav-count pointer-events-none ml-auto inline-flex shrink-0 items-center justify-center self-center rounded-full bg-destructive text-destructive-foreground", this.badge()?.classes, this.class()), ...ngDevMode ? [{ debugName: "badgeClasses" }] : /* istanbul ignore next */ []);
35
66
  static ɵfac = i0.ɵɵngDeclareFactory({
36
67
  minVersion: "12.0.0",
37
68
  version: "22.2.3",
@@ -126,4 +157,4 @@ i0.ɵɵngDeclareClassMetadata({
126
157
  }]
127
158
  }
128
159
  });
129
- export { NavigationBadgeCountComponent };
160
+ export { __reExport as i, navigation_badge_count_component_exports as n, __exportAll as r, NavigationBadgeCountComponent as t };
@@ -1,6 +1,5 @@
1
- import { n as NAVIGATION_SHELL, t as NavigationListComponent } from "./ojiepermana-angular-navigation-navigation-list.component-D-oOKwHg.mjs";
2
- import { r as NavigationItemContentComponent, t as NavigationItemComponent } from "./ojiepermana-angular-navigation-navigation-item.component-ERZNpmTZ.mjs";
3
- import { NavigationBadgeCountComponent } from "./ojiepermana-angular-navigation-navigation-badge-count.component-4RIokl1C.mjs";
1
+ import { n as NAVIGATION_SHELL, t as NavigationListComponent } from "./ojiepermana-angular-navigation-navigation-list.component-BYc3WCt8.mjs";
2
+ import { r as NavigationItemContentComponent, t as NavigationItemComponent } from "./ojiepermana-angular-navigation-navigation-item.component-DLgcJQOC.mjs";
4
3
  import * as i0 from "@angular/core";
5
4
  import { Component, ElementRef, Injector, afterNextRender, computed, inject, input, output, signal } from "@angular/core";
6
5
  import { cn } from "@ojiepermana/angular/component/utils/core";
@@ -125,14 +124,6 @@ var NavigationDockbarMenuComponent = class NavigationDockbarMenuComponent {
125
124
  this.focusFirstAsideItem();
126
125
  });
127
126
  }
128
- badgeFor(entry) {
129
- const sourceKey = entry.badge?.source;
130
- if (!sourceKey) return null;
131
- return this.badgeContext()[sourceKey] ?? null;
132
- }
133
- badgeClassesFor(entry) {
134
- return cn("absolute -right-1 -top-1", entry.badge?.classes);
135
- }
136
127
  closeAside() {
137
128
  const openKey = this.openGroup()?.key ?? null;
138
129
  this.nav.closePanel(this.navId());
@@ -320,7 +311,9 @@ var NavigationDockbarMenuComponent = class NavigationDockbarMenuComponent {
320
311
  [class]="triggerClasses(entry)"
321
312
  [attr.aria-expanded]="isGroupOpen(entry)"
322
313
  [attr.aria-controls]="asideId()"
323
- [attr.aria-label]="badgeFor(entry) ? null : (entry.tooltip ?? entry.title ?? null)"
314
+ [attr.aria-label]="
315
+ entry.badge?.source ? null : (entry.tooltip ?? entry.title ?? null)
316
+ "
324
317
  [attr.title]="isGroupOpen(entry) ? null : (entry.tooltip ?? entry.title ?? null)"
325
318
  [Tooltip]="entry.tooltip ?? entry.title ?? ''"
326
319
  [TooltipPosition]="tooltipPosition()"
@@ -329,20 +322,15 @@ var NavigationDockbarMenuComponent = class NavigationDockbarMenuComponent {
329
322
  [disabled]="entry.disabled || null"
330
323
  (click)="toggleGroup(entry)"
331
324
  >
332
- @if (badgeFor(entry)) {
333
- <span class="sr-only">{{ entry.tooltip ?? entry.title }}</span>
334
- }
335
325
  <NavigationItemContent
336
326
  [item]="entry"
337
327
  [active]="isGroupActive(entry)"
338
328
  [compact]="true"
339
329
  orientation="vertical"
340
330
  [level]="0"
331
+ [badgeContext]="badgeContext()"
341
332
  [iconTemplate]="iconTemplate()"
342
333
  />
343
- @if (badgeFor(entry); as badge) {
344
- <NavigationBadgeCount [badge]="badge" [class]="badgeClassesFor(entry)" />
345
- }
346
334
  </button>
347
335
  </li>
348
336
  } @else {
@@ -356,6 +344,7 @@ var NavigationDockbarMenuComponent = class NavigationDockbarMenuComponent {
356
344
  [itemClass]="itemClass()"
357
345
  [activeIds]="activeIds()"
358
346
  [activeUrl]="activeUrl()"
347
+ [badgeContext]="badgeContext()"
359
348
  [iconTemplate]="iconTemplate()"
360
349
  [tooltip-position]="tooltipPosition()"
361
350
  [collapseTree]="collapseTree()"
@@ -426,6 +415,7 @@ var NavigationDockbarMenuComponent = class NavigationDockbarMenuComponent {
426
415
  [itemClass]="itemClass()"
427
416
  [activeIds]="activeIds()"
428
417
  [activeUrl]="activeUrl()"
418
+ [badgeContext]="badgeContext()"
429
419
  [iconTemplate]="iconTemplate()"
430
420
  [collapseTree]="collapseTree()"
431
421
  [openedIds]="openedIds()"
@@ -462,17 +452,12 @@ var NavigationDockbarMenuComponent = class NavigationDockbarMenuComponent {
462
452
  "label"
463
453
  ]
464
454
  },
465
- {
466
- kind: "component",
467
- type: NavigationBadgeCountComponent,
468
- selector: "NavigationBadgeCount",
469
- inputs: ["badge", "class"]
470
- },
471
455
  {
472
456
  kind: "component",
473
457
  type: NavigationItemComponent,
474
458
  selector: "li[NavigationItem]",
475
459
  inputs: [
460
+ "badgeContext",
476
461
  "navId",
477
462
  "item",
478
463
  "level",
@@ -498,6 +483,7 @@ var NavigationDockbarMenuComponent = class NavigationDockbarMenuComponent {
498
483
  type: NavigationItemContentComponent,
499
484
  selector: "NavigationItemContent",
500
485
  inputs: [
486
+ "badgeContext",
501
487
  "item",
502
488
  "active",
503
489
  "compact",
@@ -511,6 +497,7 @@ var NavigationDockbarMenuComponent = class NavigationDockbarMenuComponent {
511
497
  type: NavigationListComponent,
512
498
  selector: "NavigationList",
513
499
  inputs: [
500
+ "badgeContext",
514
501
  "navId",
515
502
  "items",
516
503
  "collapsed",
@@ -563,7 +550,6 @@ i0.ɵɵngDeclareClassMetadata({
563
550
  selector: "NavigationDockbarMenu",
564
551
  imports: [
565
552
  IconComponent,
566
- NavigationBadgeCountComponent,
567
553
  NavigationItemComponent,
568
554
  NavigationItemContentComponent,
569
555
  NavigationListComponent,
@@ -591,7 +577,9 @@ i0.ɵɵngDeclareClassMetadata({
591
577
  [class]="triggerClasses(entry)"
592
578
  [attr.aria-expanded]="isGroupOpen(entry)"
593
579
  [attr.aria-controls]="asideId()"
594
- [attr.aria-label]="badgeFor(entry) ? null : (entry.tooltip ?? entry.title ?? null)"
580
+ [attr.aria-label]="
581
+ entry.badge?.source ? null : (entry.tooltip ?? entry.title ?? null)
582
+ "
595
583
  [attr.title]="isGroupOpen(entry) ? null : (entry.tooltip ?? entry.title ?? null)"
596
584
  [Tooltip]="entry.tooltip ?? entry.title ?? ''"
597
585
  [TooltipPosition]="tooltipPosition()"
@@ -600,20 +588,15 @@ i0.ɵɵngDeclareClassMetadata({
600
588
  [disabled]="entry.disabled || null"
601
589
  (click)="toggleGroup(entry)"
602
590
  >
603
- @if (badgeFor(entry)) {
604
- <span class="sr-only">{{ entry.tooltip ?? entry.title }}</span>
605
- }
606
591
  <NavigationItemContent
607
592
  [item]="entry"
608
593
  [active]="isGroupActive(entry)"
609
594
  [compact]="true"
610
595
  orientation="vertical"
611
596
  [level]="0"
597
+ [badgeContext]="badgeContext()"
612
598
  [iconTemplate]="iconTemplate()"
613
599
  />
614
- @if (badgeFor(entry); as badge) {
615
- <NavigationBadgeCount [badge]="badge" [class]="badgeClassesFor(entry)" />
616
- }
617
600
  </button>
618
601
  </li>
619
602
  } @else {
@@ -627,6 +610,7 @@ i0.ɵɵngDeclareClassMetadata({
627
610
  [itemClass]="itemClass()"
628
611
  [activeIds]="activeIds()"
629
612
  [activeUrl]="activeUrl()"
613
+ [badgeContext]="badgeContext()"
630
614
  [iconTemplate]="iconTemplate()"
631
615
  [tooltip-position]="tooltipPosition()"
632
616
  [collapseTree]="collapseTree()"
@@ -697,6 +681,7 @@ i0.ɵɵngDeclareClassMetadata({
697
681
  [itemClass]="itemClass()"
698
682
  [activeIds]="activeIds()"
699
683
  [activeUrl]="activeUrl()"
684
+ [badgeContext]="badgeContext()"
700
685
  [iconTemplate]="iconTemplate()"
701
686
  [collapseTree]="collapseTree()"
702
687
  [openedIds]="openedIds()"
@@ -1,4 +1,4 @@
1
- import { n as navigationPanelId, t as NavigationItemComponent } from "./ojiepermana-angular-navigation-navigation-item.component-ERZNpmTZ.mjs";
1
+ import { i as NavigationItemBadgeComponent, n as navigationPanelId, t as NavigationItemComponent } from "./ojiepermana-angular-navigation-navigation-item.component-DLgcJQOC.mjs";
2
2
  import * as i0 from "@angular/core";
3
3
  import { Component, computed, inject, input, output, signal } from "@angular/core";
4
4
  import { ActivatedRoute, Router, RouterLink } from "@angular/router";
@@ -12,6 +12,7 @@ var NavigationEntryGridComponent = class NavigationEntryGridComponent {
12
12
  routeContext = inject(NAVIGATION_ROUTE_CONTEXT_ADAPTER);
13
13
  router = inject(Router, { optional: true });
14
14
  activatedRoute = inject(ActivatedRoute, { optional: true });
15
+ badgeContext = input({}, ...ngDevMode ? [{ debugName: "badgeContext" }] : /* istanbul ignore next */ []);
15
16
  navId = input("default", ...ngDevMode ? [{ debugName: "navId" }] : /* istanbul ignore next */ []);
16
17
  branch = input.required(...ngDevMode ? [{ debugName: "branch" }] : /* istanbul ignore next */ []);
17
18
  typeStyle = input("flat", ...ngDevMode ? [{ debugName: "typeStyle" }] : /* istanbul ignore next */ []);
@@ -132,6 +133,13 @@ var NavigationEntryGridComponent = class NavigationEntryGridComponent {
132
133
  isStandalone: true,
133
134
  selector: "NavigationEntryGrid",
134
135
  inputs: {
136
+ badgeContext: {
137
+ classPropertyName: "badgeContext",
138
+ publicName: "badgeContext",
139
+ isSignal: true,
140
+ isRequired: false,
141
+ transformFunction: null
142
+ },
135
143
  navId: {
136
144
  classPropertyName: "navId",
137
145
  publicName: "navId",
@@ -261,6 +269,7 @@ var NavigationEntryGridComponent = class NavigationEntryGridComponent {
261
269
  [itemClass]="navItemClass()"
262
270
  [activeIds]="activeIds()"
263
271
  [activeUrl]="activeUrl()"
272
+ [badgeContext]="badgeContext()"
264
273
  [iconTemplate]="iconTemplate()"
265
274
  [collapseTree]="collapseTree()"
266
275
  [openedIds]="openedIds()"
@@ -402,15 +411,7 @@ var NavigationEntryGridComponent = class NavigationEntryGridComponent {
402
411
  }
403
412
  </span>
404
413
 
405
- @if (child.badge?.title; as badgeTitle) {
406
- <span
407
- [class]="
408
- child.badge?.classes ??
409
- 'nav-badge inline-flex h-5 shrink-0 items-center self-center rounded-full bg-muted px-2 text-muted-foreground'
410
- "
411
- >{{ badgeTitle }}</span
412
- >
413
- }
414
+ <NavigationItemBadge [itemBadge]="child.badge" [badgeContext]="badgeContext()" />
414
415
  </ng-template>
415
416
  `,
416
417
  isInline: true,
@@ -461,6 +462,7 @@ var NavigationEntryGridComponent = class NavigationEntryGridComponent {
461
462
  type: NavigationItemComponent,
462
463
  selector: "li[NavigationItem]",
463
464
  inputs: [
465
+ "badgeContext",
464
466
  "navId",
465
467
  "item",
466
468
  "level",
@@ -480,6 +482,17 @@ var NavigationEntryGridComponent = class NavigationEntryGridComponent {
480
482
  "openedIds"
481
483
  ],
482
484
  outputs: ["openedIdsChange", "itemSelected"]
485
+ },
486
+ {
487
+ kind: "component",
488
+ type: NavigationItemBadgeComponent,
489
+ selector: "NavigationItemBadge",
490
+ inputs: [
491
+ "staticClass",
492
+ "compact",
493
+ "itemBadge",
494
+ "badgeContext"
495
+ ]
483
496
  }
484
497
  ]
485
498
  });
@@ -497,7 +510,8 @@ i0.ɵɵngDeclareClassMetadata({
497
510
  NgTemplateOutlet,
498
511
  RouterLink,
499
512
  IconComponent,
500
- NavigationItemComponent
513
+ NavigationItemComponent,
514
+ NavigationItemBadgeComponent
501
515
  ],
502
516
  providers: [provideIcons(LucideChevronRight)],
503
517
  host: { class: "contents" },
@@ -559,6 +573,7 @@ i0.ɵɵngDeclareClassMetadata({
559
573
  [itemClass]="navItemClass()"
560
574
  [activeIds]="activeIds()"
561
575
  [activeUrl]="activeUrl()"
576
+ [badgeContext]="badgeContext()"
562
577
  [iconTemplate]="iconTemplate()"
563
578
  [collapseTree]="collapseTree()"
564
579
  [openedIds]="openedIds()"
@@ -700,20 +715,20 @@ i0.ɵɵngDeclareClassMetadata({
700
715
  }
701
716
  </span>
702
717
 
703
- @if (child.badge?.title; as badgeTitle) {
704
- <span
705
- [class]="
706
- child.badge?.classes ??
707
- 'nav-badge inline-flex h-5 shrink-0 items-center self-center rounded-full bg-muted px-2 text-muted-foreground'
708
- "
709
- >{{ badgeTitle }}</span
710
- >
711
- }
718
+ <NavigationItemBadge [itemBadge]="child.badge" [badgeContext]="badgeContext()" />
712
719
  </ng-template>
713
720
  `
714
721
  }]
715
722
  }],
716
723
  propDecorators: {
724
+ badgeContext: [{
725
+ type: i0.Input,
726
+ args: [{
727
+ isSignal: true,
728
+ alias: "badgeContext",
729
+ required: false
730
+ }]
731
+ }],
717
732
  navId: [{
718
733
  type: i0.Input,
719
734
  args: [{
@@ -1,5 +1,5 @@
1
- import { r as NavigationItemContentComponent, t as NavigationItemComponent } from "./ojiepermana-angular-navigation-navigation-item.component-ERZNpmTZ.mjs";
2
- import { t as NavigationEntryGridComponent } from "./ojiepermana-angular-navigation-navigation-entry-grid.component-meQb_EWZ.mjs";
1
+ import { r as NavigationItemContentComponent, t as NavigationItemComponent } from "./ojiepermana-angular-navigation-navigation-item.component-DLgcJQOC.mjs";
2
+ import { t as NavigationEntryGridComponent } from "./ojiepermana-angular-navigation-navigation-entry-grid.component-DeF_s1vE.mjs";
3
3
  import * as i0 from "@angular/core";
4
4
  import { Component, ElementRef, Injector, afterNextRender, computed, effect, inject, input, output, signal } from "@angular/core";
5
5
  import { cn } from "@ojiepermana/angular/component/utils/core";
@@ -12,6 +12,7 @@ var NavigationFlyoutMenuComponent = class NavigationFlyoutMenuComponent {
12
12
  host = inject(ElementRef);
13
13
  injector = inject(Injector);
14
14
  document = inject(DOCUMENT);
15
+ badgeContext = input({}, ...ngDevMode ? [{ debugName: "badgeContext" }] : /* istanbul ignore next */ []);
15
16
  navId = input("default", ...ngDevMode ? [{ debugName: "navId" }] : /* istanbul ignore next */ []);
16
17
  items = input([], ...ngDevMode ? [{ debugName: "items" }] : /* istanbul ignore next */ []);
17
18
  label = input("Menu", ...ngDevMode ? [{ debugName: "label" }] : /* istanbul ignore next */ []);
@@ -213,6 +214,13 @@ var NavigationFlyoutMenuComponent = class NavigationFlyoutMenuComponent {
213
214
  isStandalone: true,
214
215
  selector: "NavigationFlyoutMenu",
215
216
  inputs: {
217
+ badgeContext: {
218
+ classPropertyName: "badgeContext",
219
+ publicName: "badgeContext",
220
+ isSignal: true,
221
+ isRequired: false,
222
+ transformFunction: null
223
+ },
216
224
  navId: {
217
225
  classPropertyName: "navId",
218
226
  publicName: "navId",
@@ -371,7 +379,7 @@ var NavigationFlyoutMenuComponent = class NavigationFlyoutMenuComponent {
371
379
  },
372
380
  providers: [provideIcons(LucideChevronRight, LucideMenu)],
373
381
  ngImport: i0,
374
- template: "<button\n type=\"button\"\n data-navigation-flyout-trigger=\"true\"\n [class]=\"triggerClasses()\"\n aria-haspopup=\"menu\"\n [attr.aria-expanded]=\"isOpen()\"\n [attr.aria-controls]=\"isOpen() ? panelId() : null\"\n [attr.aria-label]=\"showIconOnly() ? label() : null\"\n [attr.title]=\"showIconOnly() ? label() : null\"\n (click)=\"toggleFlyout()\"\n>\n @if (showIconOnly()) {\n <Icon\n [name]=\"triggerIcon() ?? 'menu'\"\n size=\"inherit\"\n class=\"text-(length:--nav-icon-size) text-current\"\n />\n } @else {\n @if (iconPosition() === 'start' && triggerIcon(); as iconName) {\n <Icon\n [name]=\"iconName\"\n size=\"inherit\"\n class=\"shrink-0 text-(length:--nav-icon-size) text-current\"\n />\n }\n\n <span class=\"truncate\">{{ label() }}</span>\n\n @if (iconPosition() === 'end' && triggerIcon(); as iconName) {\n <Icon\n [name]=\"iconName\"\n size=\"inherit\"\n class=\"shrink-0 text-(length:--nav-icon-size) text-current\"\n />\n }\n }\n</button>\n\n@if (isOpen()) {\n <div\n [id]=\"panelId()\"\n data-navigation-flyout-panel=\"true\"\n [attr.data-navigation-flyout-floating]=\"floating() ? 'true' : null\"\n [class]=\"panelWrapperClasses()\"\n [style.left.px]=\"floating() ? null : panelPlacement()?.left\"\n [style.top.px]=\"floating() || isBottom() ? null : panelPlacement()?.top\"\n [style.bottom.px]=\"!floating() && isBottom() ? panelPlacement()?.bottom : null\"\n [style.width.px]=\"floating() ? null : panelPlacement()?.width\"\n >\n <div\n [attr.data-navigation-flyout-floating-card]=\"floating() ? 'true' : null\"\n [class]=\"panelCardClasses()\"\n >\n <div data-navigation-flyout-menu-layout=\"true\" [class]=\"menuClasses()\">\n <!-- ROW 1 = bar (sticky, menutup bar trigger), struktur seperti bar navbar:\n Header (kiri) | menu item (tengah) | Footer (kanan). Hanya ROW 2 (grid child)\n di bawah bar yang ikut scroll. -->\n <div data-navigation-flyout-bar=\"true\" [class]=\"barRowClasses()\">\n <ng-content select=\"NavigationHeader\" />\n\n <ul\n role=\"menu\"\n tabindex=\"-1\"\n data-navigation-flyout-row=\"true\"\n [class]=\"rowClasses()\"\n [attr.aria-label]=\"label()\"\n (keydown)=\"onRowKeydown($event)\"\n >\n @for (item of items(); track item.key) {\n @switch (item.type) {\n @case ('divider') {\n <li role=\"separator\" class=\"mx-1 h-5 w-px bg-border\"></li>\n }\n @case ('spacer') {\n <li role=\"none\" aria-hidden=\"true\" class=\"flex-1\"></li>\n }\n @default {\n @if (item.children.length > 0) {\n <li\n role=\"none\"\n [class]=\"groupContainerClasses(item)\"\n [attr.data-navigation-item-key]=\"item.key\"\n >\n <button\n type=\"button\"\n role=\"menuitem\"\n data-navigation-flyout-tab=\"true\"\n [class]=\"tabClasses(item)\"\n [attr.aria-expanded]=\"isBranchOpen(item)\"\n [attr.aria-controls]=\"isBranchOpen(item) ? panelContentId() : null\"\n [disabled]=\"item.disabled || null\"\n (click)=\"openBranch(item)\"\n >\n <NavigationItemContent\n [item]=\"item\"\n [active]=\"isItemActive(item)\"\n [compact]=\"false\"\n [orientation]=\"'horizontal'\"\n [level]=\"0\"\n [iconTemplate]=\"iconTemplate()\"\n />\n <Icon\n name=\"chevron-right\"\n size=\"inherit\"\n [class]=\"tabChevronClasses(item)\"\n />\n </button>\n </li>\n } @else {\n <li\n NavigationItem\n [navId]=\"navId()\"\n [item]=\"item\"\n [level]=\"0\"\n [orientation]=\"'horizontal'\"\n [compact]=\"false\"\n [itemClass]=\"navItemClass()\"\n [activeIds]=\"activeIds()\"\n [activeUrl]=\"activeUrl()\"\n [iconTemplate]=\"iconTemplate()\"\n [collapseTree]=\"collapseTree()\"\n [openedIds]=\"openedIds()\"\n (openedIdsChange)=\"openedIdsChange.emit($event)\"\n (itemSelected)=\"itemSelected.emit($event)\"\n ></li>\n }\n }\n }\n }\n </ul>\n\n <ng-content select=\"NavigationFooter\" />\n </div>\n\n <!-- ROW 2 = child dari menu item aktif; HANYA area ini yang men-scroll. -->\n <div\n [id]=\"panelContentId()\"\n data-navigation-flyout-scroll=\"true\"\n [attr.role]=\"activeBranch() ? 'menu' : null\"\n [attr.aria-label]=\"activeBranch()?.title || null\"\n [class]=\"scrollRegionClasses()\"\n >\n @if (activeBranch(); as branch) {\n <NavigationEntryGrid\n [navId]=\"navId()\"\n [branch]=\"branch\"\n [typeStyle]=\"typeStyle()\"\n [itemClass]=\"itemClass()\"\n [activeIds]=\"activeIds()\"\n [activeUrl]=\"activeUrl()\"\n [iconTemplate]=\"iconTemplate()\"\n [collapseTree]=\"collapseTree()\"\n [openedIds]=\"openedIds()\"\n (openedIdsChange)=\"openedIdsChange.emit($event)\"\n (itemSelected)=\"itemSelected.emit($event)\"\n />\n }\n </div>\n </div>\n </div>\n </div>\n}\n",
382
+ template: "<button\n type=\"button\"\n data-navigation-flyout-trigger=\"true\"\n [class]=\"triggerClasses()\"\n aria-haspopup=\"menu\"\n [attr.aria-expanded]=\"isOpen()\"\n [attr.aria-controls]=\"isOpen() ? panelId() : null\"\n [attr.aria-label]=\"showIconOnly() ? label() : null\"\n [attr.title]=\"showIconOnly() ? label() : null\"\n (click)=\"toggleFlyout()\"\n>\n @if (showIconOnly()) {\n <Icon\n [name]=\"triggerIcon() ?? 'menu'\"\n size=\"inherit\"\n class=\"text-(length:--nav-icon-size) text-current\"\n />\n } @else {\n @if (iconPosition() === 'start' && triggerIcon(); as iconName) {\n <Icon\n [name]=\"iconName\"\n size=\"inherit\"\n class=\"shrink-0 text-(length:--nav-icon-size) text-current\"\n />\n }\n\n <span class=\"truncate\">{{ label() }}</span>\n\n @if (iconPosition() === 'end' && triggerIcon(); as iconName) {\n <Icon\n [name]=\"iconName\"\n size=\"inherit\"\n class=\"shrink-0 text-(length:--nav-icon-size) text-current\"\n />\n }\n }\n</button>\n\n@if (isOpen()) {\n <div\n [id]=\"panelId()\"\n data-navigation-flyout-panel=\"true\"\n [attr.data-navigation-flyout-floating]=\"floating() ? 'true' : null\"\n [class]=\"panelWrapperClasses()\"\n [style.left.px]=\"floating() ? null : panelPlacement()?.left\"\n [style.top.px]=\"floating() || isBottom() ? null : panelPlacement()?.top\"\n [style.bottom.px]=\"!floating() && isBottom() ? panelPlacement()?.bottom : null\"\n [style.width.px]=\"floating() ? null : panelPlacement()?.width\"\n >\n <div\n [attr.data-navigation-flyout-floating-card]=\"floating() ? 'true' : null\"\n [class]=\"panelCardClasses()\"\n >\n <div data-navigation-flyout-menu-layout=\"true\" [class]=\"menuClasses()\">\n <!-- ROW 1 = bar (sticky, menutup bar trigger), struktur seperti bar navbar:\n Header (kiri) | menu item (tengah) | Footer (kanan). Hanya ROW 2 (grid child)\n di bawah bar yang ikut scroll. -->\n <div data-navigation-flyout-bar=\"true\" [class]=\"barRowClasses()\">\n <ng-content select=\"NavigationHeader\" />\n\n <ul\n role=\"menu\"\n tabindex=\"-1\"\n data-navigation-flyout-row=\"true\"\n [class]=\"rowClasses()\"\n [attr.aria-label]=\"label()\"\n (keydown)=\"onRowKeydown($event)\"\n >\n @for (item of items(); track item.key) {\n @switch (item.type) {\n @case ('divider') {\n <li role=\"separator\" class=\"mx-1 h-5 w-px bg-border\"></li>\n }\n @case ('spacer') {\n <li role=\"none\" aria-hidden=\"true\" class=\"flex-1\"></li>\n }\n @default {\n @if (item.children.length > 0) {\n <li\n role=\"none\"\n [class]=\"groupContainerClasses(item)\"\n [attr.data-navigation-item-key]=\"item.key\"\n >\n <button\n type=\"button\"\n role=\"menuitem\"\n data-navigation-flyout-tab=\"true\"\n [class]=\"tabClasses(item)\"\n [attr.aria-expanded]=\"isBranchOpen(item)\"\n [attr.aria-controls]=\"isBranchOpen(item) ? panelContentId() : null\"\n [disabled]=\"item.disabled || null\"\n (click)=\"openBranch(item)\"\n >\n <NavigationItemContent\n [item]=\"item\"\n [active]=\"isItemActive(item)\"\n [compact]=\"false\"\n [orientation]=\"'horizontal'\"\n [level]=\"0\"\n [badgeContext]=\"badgeContext()\"\n [iconTemplate]=\"iconTemplate()\"\n />\n <Icon\n name=\"chevron-right\"\n size=\"inherit\"\n [class]=\"tabChevronClasses(item)\"\n />\n </button>\n </li>\n } @else {\n <li\n NavigationItem\n [navId]=\"navId()\"\n [item]=\"item\"\n [level]=\"0\"\n [orientation]=\"'horizontal'\"\n [compact]=\"false\"\n [itemClass]=\"navItemClass()\"\n [activeIds]=\"activeIds()\"\n [activeUrl]=\"activeUrl()\"\n [badgeContext]=\"badgeContext()\"\n [iconTemplate]=\"iconTemplate()\"\n [collapseTree]=\"collapseTree()\"\n [openedIds]=\"openedIds()\"\n (openedIdsChange)=\"openedIdsChange.emit($event)\"\n (itemSelected)=\"itemSelected.emit($event)\"\n ></li>\n }\n }\n }\n }\n </ul>\n\n <ng-content select=\"NavigationFooter\" />\n </div>\n\n <!-- ROW 2 = child dari menu item aktif; HANYA area ini yang men-scroll. -->\n <div\n [id]=\"panelContentId()\"\n data-navigation-flyout-scroll=\"true\"\n [attr.role]=\"activeBranch() ? 'menu' : null\"\n [attr.aria-label]=\"activeBranch()?.title || null\"\n [class]=\"scrollRegionClasses()\"\n >\n @if (activeBranch(); as branch) {\n <NavigationEntryGrid\n [navId]=\"navId()\"\n [branch]=\"branch\"\n [typeStyle]=\"typeStyle()\"\n [itemClass]=\"itemClass()\"\n [activeIds]=\"activeIds()\"\n [activeUrl]=\"activeUrl()\"\n [badgeContext]=\"badgeContext()\"\n [iconTemplate]=\"iconTemplate()\"\n [collapseTree]=\"collapseTree()\"\n [openedIds]=\"openedIds()\"\n (openedIdsChange)=\"openedIdsChange.emit($event)\"\n (itemSelected)=\"itemSelected.emit($event)\"\n />\n }\n </div>\n </div>\n </div>\n </div>\n}\n",
375
383
  styles: ["[data-navigation-flyout-floating=true]{width:var(--nav-flyout-floating-width, min(22rem, 85vw));max-width:var(--nav-flyout-floating-max-width, 85vw)}[data-navigation-flyout-floating-card=true]{border-radius:var(--nav-flyout-floating-radius, var(--radius-xl))}[data-navigation-flyout-panel=true]{-webkit-app-region:no-drag;app-region:no-drag}\n"],
376
384
  dependencies: [
377
385
  {
@@ -391,6 +399,7 @@ var NavigationFlyoutMenuComponent = class NavigationFlyoutMenuComponent {
391
399
  type: NavigationEntryGridComponent,
392
400
  selector: "NavigationEntryGrid",
393
401
  inputs: [
402
+ "badgeContext",
394
403
  "navId",
395
404
  "branch",
396
405
  "typeStyle",
@@ -408,6 +417,7 @@ var NavigationFlyoutMenuComponent = class NavigationFlyoutMenuComponent {
408
417
  type: NavigationItemComponent,
409
418
  selector: "li[NavigationItem]",
410
419
  inputs: [
420
+ "badgeContext",
411
421
  "navId",
412
422
  "item",
413
423
  "level",
@@ -433,6 +443,7 @@ var NavigationFlyoutMenuComponent = class NavigationFlyoutMenuComponent {
433
443
  type: NavigationItemContentComponent,
434
444
  selector: "NavigationItemContent",
435
445
  inputs: [
446
+ "badgeContext",
436
447
  "item",
437
448
  "active",
438
449
  "compact",
@@ -464,12 +475,20 @@ i0.ɵɵngDeclareClassMetadata({
464
475
  "[class]": "hostClasses()",
465
476
  "(keydown.escape)": "onEscape($event)"
466
477
  },
467
- template: "<button\n type=\"button\"\n data-navigation-flyout-trigger=\"true\"\n [class]=\"triggerClasses()\"\n aria-haspopup=\"menu\"\n [attr.aria-expanded]=\"isOpen()\"\n [attr.aria-controls]=\"isOpen() ? panelId() : null\"\n [attr.aria-label]=\"showIconOnly() ? label() : null\"\n [attr.title]=\"showIconOnly() ? label() : null\"\n (click)=\"toggleFlyout()\"\n>\n @if (showIconOnly()) {\n <Icon\n [name]=\"triggerIcon() ?? 'menu'\"\n size=\"inherit\"\n class=\"text-(length:--nav-icon-size) text-current\"\n />\n } @else {\n @if (iconPosition() === 'start' && triggerIcon(); as iconName) {\n <Icon\n [name]=\"iconName\"\n size=\"inherit\"\n class=\"shrink-0 text-(length:--nav-icon-size) text-current\"\n />\n }\n\n <span class=\"truncate\">{{ label() }}</span>\n\n @if (iconPosition() === 'end' && triggerIcon(); as iconName) {\n <Icon\n [name]=\"iconName\"\n size=\"inherit\"\n class=\"shrink-0 text-(length:--nav-icon-size) text-current\"\n />\n }\n }\n</button>\n\n@if (isOpen()) {\n <div\n [id]=\"panelId()\"\n data-navigation-flyout-panel=\"true\"\n [attr.data-navigation-flyout-floating]=\"floating() ? 'true' : null\"\n [class]=\"panelWrapperClasses()\"\n [style.left.px]=\"floating() ? null : panelPlacement()?.left\"\n [style.top.px]=\"floating() || isBottom() ? null : panelPlacement()?.top\"\n [style.bottom.px]=\"!floating() && isBottom() ? panelPlacement()?.bottom : null\"\n [style.width.px]=\"floating() ? null : panelPlacement()?.width\"\n >\n <div\n [attr.data-navigation-flyout-floating-card]=\"floating() ? 'true' : null\"\n [class]=\"panelCardClasses()\"\n >\n <div data-navigation-flyout-menu-layout=\"true\" [class]=\"menuClasses()\">\n <!-- ROW 1 = bar (sticky, menutup bar trigger), struktur seperti bar navbar:\n Header (kiri) | menu item (tengah) | Footer (kanan). Hanya ROW 2 (grid child)\n di bawah bar yang ikut scroll. -->\n <div data-navigation-flyout-bar=\"true\" [class]=\"barRowClasses()\">\n <ng-content select=\"NavigationHeader\" />\n\n <ul\n role=\"menu\"\n tabindex=\"-1\"\n data-navigation-flyout-row=\"true\"\n [class]=\"rowClasses()\"\n [attr.aria-label]=\"label()\"\n (keydown)=\"onRowKeydown($event)\"\n >\n @for (item of items(); track item.key) {\n @switch (item.type) {\n @case ('divider') {\n <li role=\"separator\" class=\"mx-1 h-5 w-px bg-border\"></li>\n }\n @case ('spacer') {\n <li role=\"none\" aria-hidden=\"true\" class=\"flex-1\"></li>\n }\n @default {\n @if (item.children.length > 0) {\n <li\n role=\"none\"\n [class]=\"groupContainerClasses(item)\"\n [attr.data-navigation-item-key]=\"item.key\"\n >\n <button\n type=\"button\"\n role=\"menuitem\"\n data-navigation-flyout-tab=\"true\"\n [class]=\"tabClasses(item)\"\n [attr.aria-expanded]=\"isBranchOpen(item)\"\n [attr.aria-controls]=\"isBranchOpen(item) ? panelContentId() : null\"\n [disabled]=\"item.disabled || null\"\n (click)=\"openBranch(item)\"\n >\n <NavigationItemContent\n [item]=\"item\"\n [active]=\"isItemActive(item)\"\n [compact]=\"false\"\n [orientation]=\"'horizontal'\"\n [level]=\"0\"\n [iconTemplate]=\"iconTemplate()\"\n />\n <Icon\n name=\"chevron-right\"\n size=\"inherit\"\n [class]=\"tabChevronClasses(item)\"\n />\n </button>\n </li>\n } @else {\n <li\n NavigationItem\n [navId]=\"navId()\"\n [item]=\"item\"\n [level]=\"0\"\n [orientation]=\"'horizontal'\"\n [compact]=\"false\"\n [itemClass]=\"navItemClass()\"\n [activeIds]=\"activeIds()\"\n [activeUrl]=\"activeUrl()\"\n [iconTemplate]=\"iconTemplate()\"\n [collapseTree]=\"collapseTree()\"\n [openedIds]=\"openedIds()\"\n (openedIdsChange)=\"openedIdsChange.emit($event)\"\n (itemSelected)=\"itemSelected.emit($event)\"\n ></li>\n }\n }\n }\n }\n </ul>\n\n <ng-content select=\"NavigationFooter\" />\n </div>\n\n <!-- ROW 2 = child dari menu item aktif; HANYA area ini yang men-scroll. -->\n <div\n [id]=\"panelContentId()\"\n data-navigation-flyout-scroll=\"true\"\n [attr.role]=\"activeBranch() ? 'menu' : null\"\n [attr.aria-label]=\"activeBranch()?.title || null\"\n [class]=\"scrollRegionClasses()\"\n >\n @if (activeBranch(); as branch) {\n <NavigationEntryGrid\n [navId]=\"navId()\"\n [branch]=\"branch\"\n [typeStyle]=\"typeStyle()\"\n [itemClass]=\"itemClass()\"\n [activeIds]=\"activeIds()\"\n [activeUrl]=\"activeUrl()\"\n [iconTemplate]=\"iconTemplate()\"\n [collapseTree]=\"collapseTree()\"\n [openedIds]=\"openedIds()\"\n (openedIdsChange)=\"openedIdsChange.emit($event)\"\n (itemSelected)=\"itemSelected.emit($event)\"\n />\n }\n </div>\n </div>\n </div>\n </div>\n}\n",
478
+ template: "<button\n type=\"button\"\n data-navigation-flyout-trigger=\"true\"\n [class]=\"triggerClasses()\"\n aria-haspopup=\"menu\"\n [attr.aria-expanded]=\"isOpen()\"\n [attr.aria-controls]=\"isOpen() ? panelId() : null\"\n [attr.aria-label]=\"showIconOnly() ? label() : null\"\n [attr.title]=\"showIconOnly() ? label() : null\"\n (click)=\"toggleFlyout()\"\n>\n @if (showIconOnly()) {\n <Icon\n [name]=\"triggerIcon() ?? 'menu'\"\n size=\"inherit\"\n class=\"text-(length:--nav-icon-size) text-current\"\n />\n } @else {\n @if (iconPosition() === 'start' && triggerIcon(); as iconName) {\n <Icon\n [name]=\"iconName\"\n size=\"inherit\"\n class=\"shrink-0 text-(length:--nav-icon-size) text-current\"\n />\n }\n\n <span class=\"truncate\">{{ label() }}</span>\n\n @if (iconPosition() === 'end' && triggerIcon(); as iconName) {\n <Icon\n [name]=\"iconName\"\n size=\"inherit\"\n class=\"shrink-0 text-(length:--nav-icon-size) text-current\"\n />\n }\n }\n</button>\n\n@if (isOpen()) {\n <div\n [id]=\"panelId()\"\n data-navigation-flyout-panel=\"true\"\n [attr.data-navigation-flyout-floating]=\"floating() ? 'true' : null\"\n [class]=\"panelWrapperClasses()\"\n [style.left.px]=\"floating() ? null : panelPlacement()?.left\"\n [style.top.px]=\"floating() || isBottom() ? null : panelPlacement()?.top\"\n [style.bottom.px]=\"!floating() && isBottom() ? panelPlacement()?.bottom : null\"\n [style.width.px]=\"floating() ? null : panelPlacement()?.width\"\n >\n <div\n [attr.data-navigation-flyout-floating-card]=\"floating() ? 'true' : null\"\n [class]=\"panelCardClasses()\"\n >\n <div data-navigation-flyout-menu-layout=\"true\" [class]=\"menuClasses()\">\n <!-- ROW 1 = bar (sticky, menutup bar trigger), struktur seperti bar navbar:\n Header (kiri) | menu item (tengah) | Footer (kanan). Hanya ROW 2 (grid child)\n di bawah bar yang ikut scroll. -->\n <div data-navigation-flyout-bar=\"true\" [class]=\"barRowClasses()\">\n <ng-content select=\"NavigationHeader\" />\n\n <ul\n role=\"menu\"\n tabindex=\"-1\"\n data-navigation-flyout-row=\"true\"\n [class]=\"rowClasses()\"\n [attr.aria-label]=\"label()\"\n (keydown)=\"onRowKeydown($event)\"\n >\n @for (item of items(); track item.key) {\n @switch (item.type) {\n @case ('divider') {\n <li role=\"separator\" class=\"mx-1 h-5 w-px bg-border\"></li>\n }\n @case ('spacer') {\n <li role=\"none\" aria-hidden=\"true\" class=\"flex-1\"></li>\n }\n @default {\n @if (item.children.length > 0) {\n <li\n role=\"none\"\n [class]=\"groupContainerClasses(item)\"\n [attr.data-navigation-item-key]=\"item.key\"\n >\n <button\n type=\"button\"\n role=\"menuitem\"\n data-navigation-flyout-tab=\"true\"\n [class]=\"tabClasses(item)\"\n [attr.aria-expanded]=\"isBranchOpen(item)\"\n [attr.aria-controls]=\"isBranchOpen(item) ? panelContentId() : null\"\n [disabled]=\"item.disabled || null\"\n (click)=\"openBranch(item)\"\n >\n <NavigationItemContent\n [item]=\"item\"\n [active]=\"isItemActive(item)\"\n [compact]=\"false\"\n [orientation]=\"'horizontal'\"\n [level]=\"0\"\n [badgeContext]=\"badgeContext()\"\n [iconTemplate]=\"iconTemplate()\"\n />\n <Icon\n name=\"chevron-right\"\n size=\"inherit\"\n [class]=\"tabChevronClasses(item)\"\n />\n </button>\n </li>\n } @else {\n <li\n NavigationItem\n [navId]=\"navId()\"\n [item]=\"item\"\n [level]=\"0\"\n [orientation]=\"'horizontal'\"\n [compact]=\"false\"\n [itemClass]=\"navItemClass()\"\n [activeIds]=\"activeIds()\"\n [activeUrl]=\"activeUrl()\"\n [badgeContext]=\"badgeContext()\"\n [iconTemplate]=\"iconTemplate()\"\n [collapseTree]=\"collapseTree()\"\n [openedIds]=\"openedIds()\"\n (openedIdsChange)=\"openedIdsChange.emit($event)\"\n (itemSelected)=\"itemSelected.emit($event)\"\n ></li>\n }\n }\n }\n }\n </ul>\n\n <ng-content select=\"NavigationFooter\" />\n </div>\n\n <!-- ROW 2 = child dari menu item aktif; HANYA area ini yang men-scroll. -->\n <div\n [id]=\"panelContentId()\"\n data-navigation-flyout-scroll=\"true\"\n [attr.role]=\"activeBranch() ? 'menu' : null\"\n [attr.aria-label]=\"activeBranch()?.title || null\"\n [class]=\"scrollRegionClasses()\"\n >\n @if (activeBranch(); as branch) {\n <NavigationEntryGrid\n [navId]=\"navId()\"\n [branch]=\"branch\"\n [typeStyle]=\"typeStyle()\"\n [itemClass]=\"itemClass()\"\n [activeIds]=\"activeIds()\"\n [activeUrl]=\"activeUrl()\"\n [badgeContext]=\"badgeContext()\"\n [iconTemplate]=\"iconTemplate()\"\n [collapseTree]=\"collapseTree()\"\n [openedIds]=\"openedIds()\"\n (openedIdsChange)=\"openedIdsChange.emit($event)\"\n (itemSelected)=\"itemSelected.emit($event)\"\n />\n }\n </div>\n </div>\n </div>\n </div>\n}\n",
468
479
  styles: ["[data-navigation-flyout-floating=true]{width:var(--nav-flyout-floating-width, min(22rem, 85vw));max-width:var(--nav-flyout-floating-max-width, 85vw)}[data-navigation-flyout-floating-card=true]{border-radius:var(--nav-flyout-floating-radius, var(--radius-xl))}[data-navigation-flyout-panel=true]{-webkit-app-region:no-drag;app-region:no-drag}\n"]
469
480
  }]
470
481
  }],
471
482
  ctorParameters: () => [],
472
483
  propDecorators: {
484
+ badgeContext: [{
485
+ type: i0.Input,
486
+ args: [{
487
+ isSignal: true,
488
+ alias: "badgeContext",
489
+ required: false
490
+ }]
491
+ }],
473
492
  navId: [{
474
493
  type: i0.Input,
475
494
  args: [{
@@ -1,5 +1,5 @@
1
- import { n as navigationPanelId, r as NavigationItemContentComponent, t as NavigationItemComponent } from "./ojiepermana-angular-navigation-navigation-item.component-ERZNpmTZ.mjs";
2
- import { t as NavigationEntryGridComponent } from "./ojiepermana-angular-navigation-navigation-entry-grid.component-meQb_EWZ.mjs";
1
+ import { n as navigationPanelId, r as NavigationItemContentComponent, t as NavigationItemComponent } from "./ojiepermana-angular-navigation-navigation-item.component-DLgcJQOC.mjs";
2
+ import { t as NavigationEntryGridComponent } from "./ojiepermana-angular-navigation-navigation-entry-grid.component-DeF_s1vE.mjs";
3
3
  import * as i0 from "@angular/core";
4
4
  import { Component, ElementRef, Injector, afterNextRender, computed, effect, inject, input, output, signal } from "@angular/core";
5
5
  import { cn } from "@ojiepermana/angular/component/utils/core";
@@ -10,6 +10,7 @@ var NavigationHorizontalComponent = class NavigationHorizontalComponent {
10
10
  host = inject(ElementRef);
11
11
  injector = inject(Injector);
12
12
  document = inject(DOCUMENT);
13
+ badgeContext = input({}, ...ngDevMode ? [{ debugName: "badgeContext" }] : /* istanbul ignore next */ []);
13
14
  navId = input("default", ...ngDevMode ? [{ debugName: "navId" }] : /* istanbul ignore next */ []);
14
15
  items = input([], ...ngDevMode ? [{ debugName: "items" }] : /* istanbul ignore next */ []);
15
16
  position = input("top", ...ngDevMode ? [{ debugName: "position" }] : /* istanbul ignore next */ []);
@@ -168,6 +169,13 @@ var NavigationHorizontalComponent = class NavigationHorizontalComponent {
168
169
  isStandalone: true,
169
170
  selector: "NavigationHorizontal",
170
171
  inputs: {
172
+ badgeContext: {
173
+ classPropertyName: "badgeContext",
174
+ publicName: "badgeContext",
175
+ isSignal: true,
176
+ isRequired: false,
177
+ transformFunction: null
178
+ },
171
179
  navId: {
172
180
  classPropertyName: "navId",
173
181
  publicName: "navId",
@@ -292,6 +300,7 @@ var NavigationHorizontalComponent = class NavigationHorizontalComponent {
292
300
  [itemClass]="navItemClass()"
293
301
  [activeIds]="activeIds()"
294
302
  [activeUrl]="activeUrl()"
303
+ [badgeContext]="badgeContext()"
295
304
  [iconTemplate]="iconTemplate()"
296
305
  [collapseTree]="collapseTree()"
297
306
  [openedIds]="openedIds()"
@@ -317,7 +326,7 @@ var NavigationHorizontalComponent = class NavigationHorizontalComponent {
317
326
  [attr.aria-expanded]="isPanelOpen(item)"
318
327
  [attr.aria-controls]="isPanelOpen(item) ? panelIdFor(item) : null"
319
328
  [attr.aria-haspopup]="'menu'"
320
- [attr.aria-label]="compactLabel(item)"
329
+ [attr.aria-label]="item.badge?.source ? null : compactLabel(item)"
321
330
  [attr.title]="titleFor(item)"
322
331
  [disabled]="item.disabled || null"
323
332
  (click)="togglePanel(item)"
@@ -328,6 +337,7 @@ var NavigationHorizontalComponent = class NavigationHorizontalComponent {
328
337
  [compact]="compact()"
329
338
  [orientation]="'horizontal'"
330
339
  [level]="0"
340
+ [badgeContext]="badgeContext()"
331
341
  [iconTemplate]="iconTemplate()"
332
342
  />
333
343
  </button>
@@ -350,6 +360,7 @@ var NavigationHorizontalComponent = class NavigationHorizontalComponent {
350
360
  [itemClass]="itemClass()"
351
361
  [activeIds]="activeIds()"
352
362
  [activeUrl]="activeUrl()"
363
+ [badgeContext]="badgeContext()"
353
364
  [iconTemplate]="iconTemplate()"
354
365
  [collapseTree]="collapseTree()"
355
366
  [openedIds]="openedIds()"
@@ -378,6 +389,7 @@ var NavigationHorizontalComponent = class NavigationHorizontalComponent {
378
389
  type: NavigationEntryGridComponent,
379
390
  selector: "NavigationEntryGrid",
380
391
  inputs: [
392
+ "badgeContext",
381
393
  "navId",
382
394
  "branch",
383
395
  "typeStyle",
@@ -395,6 +407,7 @@ var NavigationHorizontalComponent = class NavigationHorizontalComponent {
395
407
  type: NavigationItemComponent,
396
408
  selector: "li[NavigationItem]",
397
409
  inputs: [
410
+ "badgeContext",
398
411
  "navId",
399
412
  "item",
400
413
  "level",
@@ -420,6 +433,7 @@ var NavigationHorizontalComponent = class NavigationHorizontalComponent {
420
433
  type: NavigationItemContentComponent,
421
434
  selector: "NavigationItemContent",
422
435
  inputs: [
436
+ "badgeContext",
423
437
  "item",
424
438
  "active",
425
439
  "compact",
@@ -480,6 +494,7 @@ i0.ɵɵngDeclareClassMetadata({
480
494
  [itemClass]="navItemClass()"
481
495
  [activeIds]="activeIds()"
482
496
  [activeUrl]="activeUrl()"
497
+ [badgeContext]="badgeContext()"
483
498
  [iconTemplate]="iconTemplate()"
484
499
  [collapseTree]="collapseTree()"
485
500
  [openedIds]="openedIds()"
@@ -505,7 +520,7 @@ i0.ɵɵngDeclareClassMetadata({
505
520
  [attr.aria-expanded]="isPanelOpen(item)"
506
521
  [attr.aria-controls]="isPanelOpen(item) ? panelIdFor(item) : null"
507
522
  [attr.aria-haspopup]="'menu'"
508
- [attr.aria-label]="compactLabel(item)"
523
+ [attr.aria-label]="item.badge?.source ? null : compactLabel(item)"
509
524
  [attr.title]="titleFor(item)"
510
525
  [disabled]="item.disabled || null"
511
526
  (click)="togglePanel(item)"
@@ -516,6 +531,7 @@ i0.ɵɵngDeclareClassMetadata({
516
531
  [compact]="compact()"
517
532
  [orientation]="'horizontal'"
518
533
  [level]="0"
534
+ [badgeContext]="badgeContext()"
519
535
  [iconTemplate]="iconTemplate()"
520
536
  />
521
537
  </button>
@@ -538,6 +554,7 @@ i0.ɵɵngDeclareClassMetadata({
538
554
  [itemClass]="itemClass()"
539
555
  [activeIds]="activeIds()"
540
556
  [activeUrl]="activeUrl()"
557
+ [badgeContext]="badgeContext()"
541
558
  [iconTemplate]="iconTemplate()"
542
559
  [collapseTree]="collapseTree()"
543
560
  [openedIds]="openedIds()"
@@ -553,6 +570,14 @@ i0.ɵɵngDeclareClassMetadata({
553
570
  }],
554
571
  ctorParameters: () => [],
555
572
  propDecorators: {
573
+ badgeContext: [{
574
+ type: i0.Input,
575
+ args: [{
576
+ isSignal: true,
577
+ alias: "badgeContext",
578
+ required: false
579
+ }]
580
+ }],
556
581
  navId: [{
557
582
  type: i0.Input,
558
583
  args: [{