@ojiepermana/angular 22.2.3 → 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.
- package/fesm2022/{ojiepermana-angular-navigation-navigation-badge-count.component-4RIokl1C.mjs → ojiepermana-angular-navigation-navigation-badge-count.component-BYN_Vxm3.mjs} +36 -5
- package/fesm2022/{ojiepermana-angular-navigation-navigation-dockbar-menu.component-I-ln7fOq.mjs → ojiepermana-angular-navigation-navigation-dockbar-menu.component-Dlyt6eZr.mjs} +47 -34
- package/fesm2022/{ojiepermana-angular-navigation-navigation-entry-grid.component-meQb_EWZ.mjs → ojiepermana-angular-navigation-navigation-entry-grid.component-DeF_s1vE.mjs} +35 -20
- package/fesm2022/{ojiepermana-angular-navigation-navigation-flyout-menu.component-DRdw2G-c.mjs → ojiepermana-angular-navigation-navigation-flyout-menu.component-BOGL8MY0.mjs} +23 -4
- package/fesm2022/{ojiepermana-angular-navigation-navigation-horizontal.component-Bx1NcrWO.mjs → ojiepermana-angular-navigation-navigation-horizontal.component-Cb4bHM58.mjs} +29 -4
- package/fesm2022/{ojiepermana-angular-navigation-navigation-item.component-ERZNpmTZ.mjs → ojiepermana-angular-navigation-navigation-item.component-DLgcJQOC.mjs} +351 -108
- package/fesm2022/{ojiepermana-angular-navigation-navigation-list.component-DfG6_3eF.mjs → ojiepermana-angular-navigation-navigation-list.component-BYc3WCt8.mjs} +23 -3
- package/fesm2022/ojiepermana-angular-navigation.mjs +67 -17
- package/fesm2022/ojiepermana-angular-theme-component-settings.mjs +152 -109
- package/fesm2022/ojiepermana-angular-theme-layout-wrapper.mjs +216 -79
- package/fesm2022/ojiepermana-angular-theme-page-root.mjs +4 -0
- package/fesm2022/ojiepermana-angular-theme-shell.mjs +4 -0
- package/navigation/README.md +92 -3
- package/package.json +2 -2
- package/theme/component/settings/README.md +19 -0
- package/theme/layout/README.md +67 -0
- package/theme/styles/css/base/components.css +20 -0
- package/theme/styles/css/base/tokens.css +6 -0
- package/types/ojiepermana-angular-navigation-types.d.ts +3 -3
- package/types/ojiepermana-angular-navigation.d.ts +16 -0
- package/types/ojiepermana-angular-theme-component-settings.d.ts +18 -1
- package/types/ojiepermana-angular-theme-layout-wrapper.d.ts +125 -14
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
|
-
import { Component, Service, booleanAttribute, computed, effect, inject, input, model, output, signal, viewChild } from "@angular/core";
|
|
2
|
+
import { Component, InjectionToken, Service, booleanAttribute, computed, effect, inject, input, model, output, signal, viewChild } from "@angular/core";
|
|
3
3
|
import { NavigationAsideFooterDirective, NavigationContainerComponent, NavigationDockbarComponent, NavigationFlyoutComponent, NavigationFooterActionComponent, NavigationFooterComponent, NavigationFooterInitialComponent, NavigationFooterTitleComponent, NavigationHeaderComponent, NavigationHeaderInitialComponent, NavigationHeaderTitleComponent, NavigationMinidockComponent, NavigationNavbarComponent, NavigationSidebarComponent } from "@ojiepermana/angular/navigation";
|
|
4
|
-
import {
|
|
4
|
+
import { cn } from "@ojiepermana/angular/component/utils/core";
|
|
5
|
+
import { LucideDoorOpen, LucideGrip, LucideLogOut } from "@lucide/angular";
|
|
5
6
|
import { IconComponent, provideIcons } from "@ojiepermana/angular/component/icon";
|
|
6
7
|
import { ThemeSettingsComponent } from "@ojiepermana/angular/theme/component/settings";
|
|
7
8
|
import { DOCUMENT, NgTemplateOutlet } from "@angular/common";
|
|
8
|
-
import { cn } from "@ojiepermana/angular/component/utils/core";
|
|
9
9
|
import { LayoutComponent, LayoutContentComponent, LayoutEmptyComponent, LayoutFluidComponent, LayoutHorizontalComponent, LayoutNavigationComponent, LayoutVerticalComponent } from "@ojiepermana/angular/theme/layout";
|
|
10
10
|
import { LAYOUT_DEFAULT_APPEARANCE, LAYOUT_DEFAULT_SURFACE, LAYOUT_DEFAULT_TYPE, LAYOUT_DEFAULT_WIDTH } from "@ojiepermana/angular/theme/layout/types";
|
|
11
11
|
import { toMinidockItems } from "@ojiepermana/angular/navigation/types";
|
|
@@ -44,12 +44,21 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
44
44
|
type: LayoutIdentityService,
|
|
45
45
|
decorators: [{ type: Service }]
|
|
46
46
|
});
|
|
47
|
+
const LAYOUT_USER_OPTIONS = new InjectionToken("LAYOUT_USER_OPTIONS");
|
|
48
|
+
function provideLayoutUserOptions(options) {
|
|
49
|
+
return [{
|
|
50
|
+
provide: LAYOUT_USER_OPTIONS,
|
|
51
|
+
useValue: options
|
|
52
|
+
}];
|
|
53
|
+
}
|
|
47
54
|
var LayoutBrand = class LayoutBrand {
|
|
48
55
|
brand = input.required(...ngDevMode ? [{ debugName: "brand" }] : /* istanbul ignore next */ []);
|
|
49
56
|
compact = input(false, {
|
|
50
57
|
...ngDevMode ? { debugName: "compact" } : /* istanbul ignore next */ {},
|
|
51
58
|
transform: booleanAttribute
|
|
52
59
|
});
|
|
60
|
+
wordmarkClasses = computed(() => cn("block truncate font-semibold tracking-tight text-foreground", this.compact() ? "text-xs leading-none" : "nav-text in-data-[collapsed=true]:text-xs in-data-[collapsed=true]:leading-none"), ...ngDevMode ? [{ debugName: "wordmarkClasses" }] : /* istanbul ignore next */ []);
|
|
61
|
+
taglineClasses = computed(() => cn("block truncate text-muted-foreground", this.compact() ? "text-2xs leading-none" : "nav-subtitle in-data-[collapsed=true]:text-2xs in-data-[collapsed=true]:leading-none"), ...ngDevMode ? [{ debugName: "taglineClasses" }] : /* istanbul ignore next */ []);
|
|
53
62
|
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
54
63
|
minVersion: "12.0.0",
|
|
55
64
|
version: "22.2.3",
|
|
@@ -83,7 +92,22 @@ var LayoutBrand = class LayoutBrand {
|
|
|
83
92
|
host: { classAttribute: "contents" },
|
|
84
93
|
ngImport: i0,
|
|
85
94
|
template: `
|
|
86
|
-
|
|
95
|
+
@if (brand().wordmark; as wordmark) {
|
|
96
|
+
<span
|
|
97
|
+
data-layout-brand-mark
|
|
98
|
+
role="img"
|
|
99
|
+
[attr.aria-label]="brand().name"
|
|
100
|
+
[attr.data-compact]="compact()"
|
|
101
|
+
class="inline-flex min-w-0 max-w-full flex-col justify-center"
|
|
102
|
+
>
|
|
103
|
+
<span data-layout-brand-wordmark [class]="wordmarkClasses()">{{ wordmark }}</span>
|
|
104
|
+
@if (brand().tagline; as tagline) {
|
|
105
|
+
<span data-layout-brand-tagline [class]="taglineClasses()">{{ tagline }}</span>
|
|
106
|
+
}
|
|
107
|
+
</span>
|
|
108
|
+
} @else {
|
|
109
|
+
<NavigationHeaderInitial [name]="brand().name" [icon]="brand().icon" [compact]="compact()" />
|
|
110
|
+
}
|
|
87
111
|
@if (!compact()) {
|
|
88
112
|
<NavigationHeaderTitle [title]="brand().title" [subtitle]="brand().subtitle" />
|
|
89
113
|
}
|
|
@@ -125,7 +149,22 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
125
149
|
imports: [NavigationHeaderInitialComponent, NavigationHeaderTitleComponent],
|
|
126
150
|
host: { class: "contents" },
|
|
127
151
|
template: `
|
|
128
|
-
|
|
152
|
+
@if (brand().wordmark; as wordmark) {
|
|
153
|
+
<span
|
|
154
|
+
data-layout-brand-mark
|
|
155
|
+
role="img"
|
|
156
|
+
[attr.aria-label]="brand().name"
|
|
157
|
+
[attr.data-compact]="compact()"
|
|
158
|
+
class="inline-flex min-w-0 max-w-full flex-col justify-center"
|
|
159
|
+
>
|
|
160
|
+
<span data-layout-brand-wordmark [class]="wordmarkClasses()">{{ wordmark }}</span>
|
|
161
|
+
@if (brand().tagline; as tagline) {
|
|
162
|
+
<span data-layout-brand-tagline [class]="taglineClasses()">{{ tagline }}</span>
|
|
163
|
+
}
|
|
164
|
+
</span>
|
|
165
|
+
} @else {
|
|
166
|
+
<NavigationHeaderInitial [name]="brand().name" [icon]="brand().icon" [compact]="compact()" />
|
|
167
|
+
}
|
|
129
168
|
@if (!compact()) {
|
|
130
169
|
<NavigationHeaderTitle [title]="brand().title" [subtitle]="brand().subtitle" />
|
|
131
170
|
}
|
|
@@ -151,15 +190,39 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
151
190
|
}]
|
|
152
191
|
}
|
|
153
192
|
});
|
|
193
|
+
function optionalBooleanAttribute(value) {
|
|
194
|
+
return value === null || value === void 0 ? null : booleanAttribute(value);
|
|
195
|
+
}
|
|
154
196
|
var LayoutUser = class LayoutUser {
|
|
197
|
+
options = inject(LAYOUT_USER_OPTIONS, { optional: true });
|
|
155
198
|
user = input.required(...ngDevMode ? [{ debugName: "user" }] : /* istanbul ignore next */ []);
|
|
156
199
|
detailed = input(false, {
|
|
157
200
|
...ngDevMode ? { debugName: "detailed" } : /* istanbul ignore next */ {},
|
|
158
201
|
transform: booleanAttribute
|
|
159
202
|
});
|
|
160
|
-
|
|
161
|
-
|
|
203
|
+
showInitial = input(true, {
|
|
204
|
+
...ngDevMode ? { debugName: "showInitial" } : /* istanbul ignore next */ {},
|
|
205
|
+
alias: "show-initial",
|
|
206
|
+
transform: booleanAttribute
|
|
207
|
+
});
|
|
208
|
+
showEmail = input(null, {
|
|
209
|
+
...ngDevMode ? { debugName: "showEmail" } : /* istanbul ignore next */ {},
|
|
210
|
+
alias: "show-email",
|
|
211
|
+
transform: optionalBooleanAttribute
|
|
212
|
+
});
|
|
213
|
+
showThemeSettings = input(null, {
|
|
214
|
+
...ngDevMode ? { debugName: "showThemeSettings" } : /* istanbul ignore next */ {},
|
|
215
|
+
alias: "show-theme-settings",
|
|
216
|
+
transform: optionalBooleanAttribute
|
|
217
|
+
});
|
|
218
|
+
logoutLabel = input(null, ...ngDevMode ? [{ debugName: "logoutLabel" }] : /* istanbul ignore next */ []);
|
|
219
|
+
logoutIcon = input(null, ...ngDevMode ? [{ debugName: "logoutIcon" }] : /* istanbul ignore next */ []);
|
|
162
220
|
logout = output();
|
|
221
|
+
showsIdentity = computed(() => this.detailed() || this.options?.detailed === true, ...ngDevMode ? [{ debugName: "showsIdentity" }] : /* istanbul ignore next */ []);
|
|
222
|
+
showsEmail = computed(() => this.showEmail() ?? this.options?.showEmail ?? true, ...ngDevMode ? [{ debugName: "showsEmail" }] : /* istanbul ignore next */ []);
|
|
223
|
+
showsThemeSettings = computed(() => this.showThemeSettings() ?? this.options?.showThemeSettings ?? true, ...ngDevMode ? [{ debugName: "showsThemeSettings" }] : /* istanbul ignore next */ []);
|
|
224
|
+
resolvedLogoutLabel = computed(() => this.logoutLabel() ?? this.options?.logoutLabel ?? "Logout", ...ngDevMode ? [{ debugName: "resolvedLogoutLabel" }] : /* istanbul ignore next */ []);
|
|
225
|
+
resolvedLogoutIcon = computed(() => this.logoutIcon() ?? this.options?.logoutIcon ?? "log-out", ...ngDevMode ? [{ debugName: "resolvedLogoutIcon" }] : /* istanbul ignore next */ []);
|
|
163
226
|
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
164
227
|
minVersion: "12.0.0",
|
|
165
228
|
version: "22.2.3",
|
|
@@ -189,6 +252,27 @@ var LayoutUser = class LayoutUser {
|
|
|
189
252
|
isRequired: false,
|
|
190
253
|
transformFunction: null
|
|
191
254
|
},
|
|
255
|
+
showInitial: {
|
|
256
|
+
classPropertyName: "showInitial",
|
|
257
|
+
publicName: "show-initial",
|
|
258
|
+
isSignal: true,
|
|
259
|
+
isRequired: false,
|
|
260
|
+
transformFunction: null
|
|
261
|
+
},
|
|
262
|
+
showEmail: {
|
|
263
|
+
classPropertyName: "showEmail",
|
|
264
|
+
publicName: "show-email",
|
|
265
|
+
isSignal: true,
|
|
266
|
+
isRequired: false,
|
|
267
|
+
transformFunction: null
|
|
268
|
+
},
|
|
269
|
+
showThemeSettings: {
|
|
270
|
+
classPropertyName: "showThemeSettings",
|
|
271
|
+
publicName: "show-theme-settings",
|
|
272
|
+
isSignal: true,
|
|
273
|
+
isRequired: false,
|
|
274
|
+
transformFunction: null
|
|
275
|
+
},
|
|
192
276
|
logoutLabel: {
|
|
193
277
|
classPropertyName: "logoutLabel",
|
|
194
278
|
publicName: "logoutLabel",
|
|
@@ -206,25 +290,33 @@ var LayoutUser = class LayoutUser {
|
|
|
206
290
|
},
|
|
207
291
|
outputs: { logout: "logout" },
|
|
208
292
|
host: { classAttribute: "contents" },
|
|
209
|
-
providers: [provideIcons(LucideLogOut)],
|
|
293
|
+
providers: [provideIcons(LucideLogOut, LucideDoorOpen)],
|
|
210
294
|
ngImport: i0,
|
|
211
295
|
template: `
|
|
212
|
-
@if (
|
|
213
|
-
|
|
214
|
-
|
|
296
|
+
@if (showsIdentity()) {
|
|
297
|
+
@if (showInitial()) {
|
|
298
|
+
<NavigationFooterInitial [name]="user().name" />
|
|
299
|
+
}
|
|
300
|
+
<NavigationFooterTitle
|
|
301
|
+
class="min-w-0 max-w-64 flex-1"
|
|
302
|
+
[title]="user().name"
|
|
303
|
+
[subtitle]="showsEmail() ? user().email : null"
|
|
304
|
+
/>
|
|
215
305
|
}
|
|
216
306
|
|
|
217
307
|
<NavigationFooterAction class="ml-auto">
|
|
218
308
|
<button
|
|
219
309
|
type="button"
|
|
220
|
-
[attr.aria-label]="
|
|
221
|
-
[attr.title]="
|
|
222
|
-
class="inline-flex h-8 w-8 items-center justify-center rounded-md text-muted-foreground transition-colors hover:bg-accent hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
|
|
310
|
+
[attr.aria-label]="resolvedLogoutLabel()"
|
|
311
|
+
[attr.title]="resolvedLogoutLabel()"
|
|
312
|
+
class="inline-flex h-8 w-8 shrink-0 items-center justify-center rounded-md text-muted-foreground transition-colors hover:bg-accent hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
|
|
223
313
|
(click)="logout.emit()"
|
|
224
314
|
>
|
|
225
|
-
<Icon [name]="
|
|
315
|
+
<Icon [name]="resolvedLogoutIcon()" [size]="18" />
|
|
226
316
|
</button>
|
|
227
|
-
|
|
317
|
+
@if (showsThemeSettings()) {
|
|
318
|
+
<ThemeSettings [trigger-icon-only]="true" class="size-8! min-h-8!" />
|
|
319
|
+
}
|
|
228
320
|
</NavigationFooterAction>
|
|
229
321
|
`,
|
|
230
322
|
isInline: true,
|
|
@@ -247,6 +339,7 @@ var LayoutUser = class LayoutUser {
|
|
|
247
339
|
selector: "ThemeSettings",
|
|
248
340
|
inputs: [
|
|
249
341
|
"open",
|
|
342
|
+
"inline",
|
|
250
343
|
"trigger",
|
|
251
344
|
"triggerLabel",
|
|
252
345
|
"trigger-icon-only",
|
|
@@ -296,7 +389,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
296
389
|
type: Component,
|
|
297
390
|
args: [{
|
|
298
391
|
selector: "LayoutUser",
|
|
299
|
-
providers: [provideIcons(LucideLogOut)],
|
|
392
|
+
providers: [provideIcons(LucideLogOut, LucideDoorOpen)],
|
|
300
393
|
imports: [
|
|
301
394
|
IconComponent,
|
|
302
395
|
ThemeSettingsComponent,
|
|
@@ -306,22 +399,30 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
306
399
|
],
|
|
307
400
|
host: { class: "contents" },
|
|
308
401
|
template: `
|
|
309
|
-
@if (
|
|
310
|
-
|
|
311
|
-
|
|
402
|
+
@if (showsIdentity()) {
|
|
403
|
+
@if (showInitial()) {
|
|
404
|
+
<NavigationFooterInitial [name]="user().name" />
|
|
405
|
+
}
|
|
406
|
+
<NavigationFooterTitle
|
|
407
|
+
class="min-w-0 max-w-64 flex-1"
|
|
408
|
+
[title]="user().name"
|
|
409
|
+
[subtitle]="showsEmail() ? user().email : null"
|
|
410
|
+
/>
|
|
312
411
|
}
|
|
313
412
|
|
|
314
413
|
<NavigationFooterAction class="ml-auto">
|
|
315
414
|
<button
|
|
316
415
|
type="button"
|
|
317
|
-
[attr.aria-label]="
|
|
318
|
-
[attr.title]="
|
|
319
|
-
class="inline-flex h-8 w-8 items-center justify-center rounded-md text-muted-foreground transition-colors hover:bg-accent hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
|
|
416
|
+
[attr.aria-label]="resolvedLogoutLabel()"
|
|
417
|
+
[attr.title]="resolvedLogoutLabel()"
|
|
418
|
+
class="inline-flex h-8 w-8 shrink-0 items-center justify-center rounded-md text-muted-foreground transition-colors hover:bg-accent hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
|
|
320
419
|
(click)="logout.emit()"
|
|
321
420
|
>
|
|
322
|
-
<Icon [name]="
|
|
421
|
+
<Icon [name]="resolvedLogoutIcon()" [size]="18" />
|
|
323
422
|
</button>
|
|
324
|
-
|
|
423
|
+
@if (showsThemeSettings()) {
|
|
424
|
+
<ThemeSettings [trigger-icon-only]="true" class="size-8! min-h-8!" />
|
|
425
|
+
}
|
|
325
426
|
</NavigationFooterAction>
|
|
326
427
|
`
|
|
327
428
|
}]
|
|
@@ -343,6 +444,30 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
343
444
|
required: false
|
|
344
445
|
}]
|
|
345
446
|
}],
|
|
447
|
+
showInitial: [{
|
|
448
|
+
type: i0.Input,
|
|
449
|
+
args: [{
|
|
450
|
+
isSignal: true,
|
|
451
|
+
alias: "show-initial",
|
|
452
|
+
required: false
|
|
453
|
+
}]
|
|
454
|
+
}],
|
|
455
|
+
showEmail: [{
|
|
456
|
+
type: i0.Input,
|
|
457
|
+
args: [{
|
|
458
|
+
isSignal: true,
|
|
459
|
+
alias: "show-email",
|
|
460
|
+
required: false
|
|
461
|
+
}]
|
|
462
|
+
}],
|
|
463
|
+
showThemeSettings: [{
|
|
464
|
+
type: i0.Input,
|
|
465
|
+
args: [{
|
|
466
|
+
isSignal: true,
|
|
467
|
+
alias: "show-theme-settings",
|
|
468
|
+
required: false
|
|
469
|
+
}]
|
|
470
|
+
}],
|
|
346
471
|
logoutLabel: [{
|
|
347
472
|
type: i0.Input,
|
|
348
473
|
args: [{
|
|
@@ -473,6 +598,9 @@ var LayoutNavSidebar = class LayoutNavSidebar {
|
|
|
473
598
|
inputs: [
|
|
474
599
|
"user",
|
|
475
600
|
"detailed",
|
|
601
|
+
"show-initial",
|
|
602
|
+
"show-email",
|
|
603
|
+
"show-theme-settings",
|
|
476
604
|
"logoutLabel",
|
|
477
605
|
"logoutIcon"
|
|
478
606
|
],
|
|
@@ -562,6 +690,10 @@ var LayoutNavDockbar = class LayoutNavDockbar {
|
|
|
562
690
|
...ngDevMode ? { debugName: "dockbarRouteContext" } : /* istanbul ignore next */ {},
|
|
563
691
|
alias: "dockbar-route-context"
|
|
564
692
|
});
|
|
693
|
+
badgeContext = input(null, {
|
|
694
|
+
...ngDevMode ? { debugName: "badgeContext" } : /* istanbul ignore next */ {},
|
|
695
|
+
alias: "badge-context"
|
|
696
|
+
});
|
|
565
697
|
dockbarBadgeContext = input(EMPTY_NAVIGATION_BADGE_CONTEXT$1, {
|
|
566
698
|
...ngDevMode ? { debugName: "dockbarBadgeContext" } : /* istanbul ignore next */ {},
|
|
567
699
|
alias: "dockbar-badge"
|
|
@@ -624,6 +756,13 @@ var LayoutNavDockbar = class LayoutNavDockbar {
|
|
|
624
756
|
isRequired: false,
|
|
625
757
|
transformFunction: null
|
|
626
758
|
},
|
|
759
|
+
badgeContext: {
|
|
760
|
+
classPropertyName: "badgeContext",
|
|
761
|
+
publicName: "badge-context",
|
|
762
|
+
isSignal: true,
|
|
763
|
+
isRequired: false,
|
|
764
|
+
transformFunction: null
|
|
765
|
+
},
|
|
627
766
|
dockbarBadgeContext: {
|
|
628
767
|
classPropertyName: "dockbarBadgeContext",
|
|
629
768
|
publicName: "dockbar-badge",
|
|
@@ -634,13 +773,12 @@ var LayoutNavDockbar = class LayoutNavDockbar {
|
|
|
634
773
|
},
|
|
635
774
|
outputs: { logout: "logout" },
|
|
636
775
|
host: { classAttribute: "contents" },
|
|
637
|
-
providers: [provideIcons(LucideLogOut)],
|
|
638
776
|
ngImport: i0,
|
|
639
777
|
template: `
|
|
640
778
|
<NavigationDockbar
|
|
641
779
|
[mode]="dockbarMode()"
|
|
642
780
|
[dockbar-route-context]="dockbarRouteContext()"
|
|
643
|
-
[
|
|
781
|
+
[badge-context]="badgeContext() ?? dockbarBadgeContext()"
|
|
644
782
|
[class]="shellClass()"
|
|
645
783
|
>
|
|
646
784
|
@if (!routeContextEnabled()) {
|
|
@@ -653,41 +791,12 @@ var LayoutNavDockbar = class LayoutNavDockbar {
|
|
|
653
791
|
</NavigationFooter>
|
|
654
792
|
|
|
655
793
|
<ng-template NavigationAsideFooter>
|
|
656
|
-
<
|
|
657
|
-
<span class="block truncate text-sm font-semibold leading-tight text-foreground">{{
|
|
658
|
-
user().name
|
|
659
|
-
}}</span>
|
|
660
|
-
<span class="block truncate text-xs leading-tight text-muted-foreground">{{
|
|
661
|
-
user().email
|
|
662
|
-
}}</span>
|
|
663
|
-
</div>
|
|
664
|
-
|
|
665
|
-
<button
|
|
666
|
-
type="button"
|
|
667
|
-
aria-label="Logout"
|
|
668
|
-
title="Logout"
|
|
669
|
-
class="ml-auto inline-flex h-8 w-8 shrink-0 items-center justify-center rounded-md text-muted-foreground transition-colors hover:bg-accent hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
|
|
670
|
-
(click)="logout.emit()"
|
|
671
|
-
>
|
|
672
|
-
<Icon name="log-out" [size]="18" />
|
|
673
|
-
</button>
|
|
794
|
+
<LayoutUser [user]="user()" detailed [show-initial]="false" (logout)="logout.emit()" />
|
|
674
795
|
</ng-template>
|
|
675
796
|
</NavigationDockbar>
|
|
676
797
|
`,
|
|
677
798
|
isInline: true,
|
|
678
799
|
dependencies: [
|
|
679
|
-
{
|
|
680
|
-
kind: "component",
|
|
681
|
-
type: IconComponent,
|
|
682
|
-
selector: "Icon",
|
|
683
|
-
inputs: [
|
|
684
|
-
"name",
|
|
685
|
-
"class",
|
|
686
|
-
"size",
|
|
687
|
-
"strokeWidth",
|
|
688
|
-
"label"
|
|
689
|
-
]
|
|
690
|
-
},
|
|
691
800
|
{
|
|
692
801
|
kind: "directive",
|
|
693
802
|
type: NavigationAsideFooterDirective,
|
|
@@ -702,6 +811,7 @@ var LayoutNavDockbar = class LayoutNavDockbar {
|
|
|
702
811
|
"position",
|
|
703
812
|
"dockbar-route-context",
|
|
704
813
|
"dockbar-badge",
|
|
814
|
+
"badge-context",
|
|
705
815
|
"class"
|
|
706
816
|
]
|
|
707
817
|
},
|
|
@@ -730,6 +840,9 @@ var LayoutNavDockbar = class LayoutNavDockbar {
|
|
|
730
840
|
inputs: [
|
|
731
841
|
"user",
|
|
732
842
|
"detailed",
|
|
843
|
+
"show-initial",
|
|
844
|
+
"show-email",
|
|
845
|
+
"show-theme-settings",
|
|
733
846
|
"logoutLabel",
|
|
734
847
|
"logoutIcon"
|
|
735
848
|
],
|
|
@@ -747,9 +860,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
747
860
|
type: Component,
|
|
748
861
|
args: [{
|
|
749
862
|
selector: "LayoutNavDockbar",
|
|
750
|
-
providers: [provideIcons(LucideLogOut)],
|
|
751
863
|
imports: [
|
|
752
|
-
IconComponent,
|
|
753
864
|
NavigationAsideFooterDirective,
|
|
754
865
|
NavigationDockbarComponent,
|
|
755
866
|
NavigationHeaderComponent,
|
|
@@ -762,7 +873,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
762
873
|
<NavigationDockbar
|
|
763
874
|
[mode]="dockbarMode()"
|
|
764
875
|
[dockbar-route-context]="dockbarRouteContext()"
|
|
765
|
-
[
|
|
876
|
+
[badge-context]="badgeContext() ?? dockbarBadgeContext()"
|
|
766
877
|
[class]="shellClass()"
|
|
767
878
|
>
|
|
768
879
|
@if (!routeContextEnabled()) {
|
|
@@ -775,24 +886,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
775
886
|
</NavigationFooter>
|
|
776
887
|
|
|
777
888
|
<ng-template NavigationAsideFooter>
|
|
778
|
-
<
|
|
779
|
-
<span class="block truncate text-sm font-semibold leading-tight text-foreground">{{
|
|
780
|
-
user().name
|
|
781
|
-
}}</span>
|
|
782
|
-
<span class="block truncate text-xs leading-tight text-muted-foreground">{{
|
|
783
|
-
user().email
|
|
784
|
-
}}</span>
|
|
785
|
-
</div>
|
|
786
|
-
|
|
787
|
-
<button
|
|
788
|
-
type="button"
|
|
789
|
-
aria-label="Logout"
|
|
790
|
-
title="Logout"
|
|
791
|
-
class="ml-auto inline-flex h-8 w-8 shrink-0 items-center justify-center rounded-md text-muted-foreground transition-colors hover:bg-accent hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
|
|
792
|
-
(click)="logout.emit()"
|
|
793
|
-
>
|
|
794
|
-
<Icon name="log-out" [size]="18" />
|
|
795
|
-
</button>
|
|
889
|
+
<LayoutUser [user]="user()" detailed [show-initial]="false" (logout)="logout.emit()" />
|
|
796
890
|
</ng-template>
|
|
797
891
|
</NavigationDockbar>
|
|
798
892
|
`
|
|
@@ -839,6 +933,14 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
839
933
|
required: false
|
|
840
934
|
}]
|
|
841
935
|
}],
|
|
936
|
+
badgeContext: [{
|
|
937
|
+
type: i0.Input,
|
|
938
|
+
args: [{
|
|
939
|
+
isSignal: true,
|
|
940
|
+
alias: "badge-context",
|
|
941
|
+
required: false
|
|
942
|
+
}]
|
|
943
|
+
}],
|
|
842
944
|
dockbarBadgeContext: [{
|
|
843
945
|
type: i0.Input,
|
|
844
946
|
args: [{
|
|
@@ -943,6 +1045,9 @@ var LayoutNavMinidock = class LayoutNavMinidock {
|
|
|
943
1045
|
inputs: [
|
|
944
1046
|
"user",
|
|
945
1047
|
"detailed",
|
|
1048
|
+
"show-initial",
|
|
1049
|
+
"show-email",
|
|
1050
|
+
"show-theme-settings",
|
|
946
1051
|
"logoutLabel",
|
|
947
1052
|
"logoutIcon"
|
|
948
1053
|
],
|
|
@@ -1103,6 +1208,9 @@ var LayoutNavNavbar = class LayoutNavNavbar {
|
|
|
1103
1208
|
inputs: [
|
|
1104
1209
|
"user",
|
|
1105
1210
|
"detailed",
|
|
1211
|
+
"show-initial",
|
|
1212
|
+
"show-email",
|
|
1213
|
+
"show-theme-settings",
|
|
1106
1214
|
"logoutLabel",
|
|
1107
1215
|
"logoutIcon"
|
|
1108
1216
|
],
|
|
@@ -1278,6 +1386,9 @@ var LayoutNavFlyout = class LayoutNavFlyout {
|
|
|
1278
1386
|
inputs: [
|
|
1279
1387
|
"user",
|
|
1280
1388
|
"detailed",
|
|
1389
|
+
"show-initial",
|
|
1390
|
+
"show-email",
|
|
1391
|
+
"show-theme-settings",
|
|
1281
1392
|
"logoutLabel",
|
|
1282
1393
|
"logoutIcon"
|
|
1283
1394
|
],
|
|
@@ -1472,6 +1583,11 @@ var LayoutWrapperDefault = class LayoutWrapperDefault {
|
|
|
1472
1583
|
...ngDevMode ? { debugName: "dockbarRouteContext" } : /* istanbul ignore next */ {},
|
|
1473
1584
|
alias: "dockbar-route-context"
|
|
1474
1585
|
});
|
|
1586
|
+
badgeContext = input(null, {
|
|
1587
|
+
...ngDevMode ? { debugName: "badgeContext" } : /* istanbul ignore next */ {},
|
|
1588
|
+
alias: "badge-context"
|
|
1589
|
+
});
|
|
1590
|
+
resolvedBadgeContext = computed(() => this.badgeContext() ?? this.dockbarBadgeContext(), ...ngDevMode ? [{ debugName: "resolvedBadgeContext" }] : /* istanbul ignore next */ []);
|
|
1475
1591
|
dockbarBadgeContext = input(EMPTY_NAVIGATION_BADGE_CONTEXT, {
|
|
1476
1592
|
...ngDevMode ? { debugName: "dockbarBadgeContext" } : /* istanbul ignore next */ {},
|
|
1477
1593
|
alias: "dockbar-badge"
|
|
@@ -1628,6 +1744,13 @@ var LayoutWrapperDefault = class LayoutWrapperDefault {
|
|
|
1628
1744
|
isRequired: false,
|
|
1629
1745
|
transformFunction: null
|
|
1630
1746
|
},
|
|
1747
|
+
badgeContext: {
|
|
1748
|
+
classPropertyName: "badgeContext",
|
|
1749
|
+
publicName: "badge-context",
|
|
1750
|
+
isSignal: true,
|
|
1751
|
+
isRequired: false,
|
|
1752
|
+
transformFunction: null
|
|
1753
|
+
},
|
|
1631
1754
|
dockbarBadgeContext: {
|
|
1632
1755
|
classPropertyName: "dockbarBadgeContext",
|
|
1633
1756
|
publicName: "dockbar-badge",
|
|
@@ -1777,6 +1900,7 @@ var LayoutWrapperDefault = class LayoutWrapperDefault {
|
|
|
1777
1900
|
id="main-mobile"
|
|
1778
1901
|
data-id="main"
|
|
1779
1902
|
[data]="data()"
|
|
1903
|
+
[badge-context]="resolvedBadgeContext()"
|
|
1780
1904
|
ariaLabel="Primary navigation"
|
|
1781
1905
|
class="h-full w-full"
|
|
1782
1906
|
(itemSelected)="mobileNavOpen.set(false)"
|
|
@@ -1803,6 +1927,7 @@ var LayoutWrapperDefault = class LayoutWrapperDefault {
|
|
|
1803
1927
|
id="main"
|
|
1804
1928
|
[data-id]="desktopDataId()"
|
|
1805
1929
|
[data]="desktopData()"
|
|
1930
|
+
[badge-context]="resolvedBadgeContext()"
|
|
1806
1931
|
[class]="navClass()"
|
|
1807
1932
|
>
|
|
1808
1933
|
@switch (navKind()) {
|
|
@@ -1969,6 +2094,7 @@ var LayoutWrapperDefault = class LayoutWrapperDefault {
|
|
|
1969
2094
|
"id",
|
|
1970
2095
|
"data-id",
|
|
1971
2096
|
"data",
|
|
2097
|
+
"badge-context",
|
|
1972
2098
|
"ariaLabel",
|
|
1973
2099
|
"compact",
|
|
1974
2100
|
"collapse-tree",
|
|
@@ -2009,6 +2135,7 @@ var LayoutWrapperDefault = class LayoutWrapperDefault {
|
|
|
2009
2135
|
"appearance",
|
|
2010
2136
|
"nav-type-mode",
|
|
2011
2137
|
"dockbar-route-context",
|
|
2138
|
+
"badge-context",
|
|
2012
2139
|
"dockbar-badge"
|
|
2013
2140
|
],
|
|
2014
2141
|
outputs: ["logout"]
|
|
@@ -2151,6 +2278,7 @@ i0.ɵɵngDeclareClassMetadataAsync({
|
|
|
2151
2278
|
id="main-mobile"
|
|
2152
2279
|
data-id="main"
|
|
2153
2280
|
[data]="data()"
|
|
2281
|
+
[badge-context]="resolvedBadgeContext()"
|
|
2154
2282
|
ariaLabel="Primary navigation"
|
|
2155
2283
|
class="h-full w-full"
|
|
2156
2284
|
(itemSelected)="mobileNavOpen.set(false)"
|
|
@@ -2177,6 +2305,7 @@ i0.ɵɵngDeclareClassMetadataAsync({
|
|
|
2177
2305
|
id="main"
|
|
2178
2306
|
[data-id]="desktopDataId()"
|
|
2179
2307
|
[data]="desktopData()"
|
|
2308
|
+
[badge-context]="resolvedBadgeContext()"
|
|
2180
2309
|
[class]="navClass()"
|
|
2181
2310
|
>
|
|
2182
2311
|
@switch (navKind()) {
|
|
@@ -2326,6 +2455,14 @@ i0.ɵɵngDeclareClassMetadataAsync({
|
|
|
2326
2455
|
required: false
|
|
2327
2456
|
}]
|
|
2328
2457
|
}],
|
|
2458
|
+
badgeContext: [{
|
|
2459
|
+
type: i0.Input,
|
|
2460
|
+
args: [{
|
|
2461
|
+
isSignal: true,
|
|
2462
|
+
alias: "badge-context",
|
|
2463
|
+
required: false
|
|
2464
|
+
}]
|
|
2465
|
+
}],
|
|
2329
2466
|
dockbarBadgeContext: [{
|
|
2330
2467
|
type: i0.Input,
|
|
2331
2468
|
args: [{
|
|
@@ -2428,4 +2565,4 @@ i0.ɵɵngDeclareClassMetadataAsync({
|
|
|
2428
2565
|
}
|
|
2429
2566
|
})
|
|
2430
2567
|
});
|
|
2431
|
-
export { LAYOUT_DESKTOP_NAVIGATION_DATA_ID, LayoutBrand, LayoutIdentityService, LayoutNavDockbar, LayoutNavFlyout, LayoutNavMinidock, LayoutNavMinimal, LayoutNavNavbar, LayoutNavSidebar, LayoutUser, LayoutWrapperDefault };
|
|
2568
|
+
export { LAYOUT_DESKTOP_NAVIGATION_DATA_ID, LAYOUT_USER_OPTIONS, LayoutBrand, LayoutIdentityService, LayoutNavDockbar, LayoutNavFlyout, LayoutNavMinidock, LayoutNavMinimal, LayoutNavNavbar, LayoutNavSidebar, LayoutUser, LayoutWrapperDefault, provideLayoutUserOptions };
|
|
@@ -379,6 +379,7 @@ var PageComponent = class PageComponent {
|
|
|
379
379
|
"id",
|
|
380
380
|
"data-id",
|
|
381
381
|
"data",
|
|
382
|
+
"badge-context",
|
|
382
383
|
"ariaLabel",
|
|
383
384
|
"compact",
|
|
384
385
|
"collapse-tree",
|
|
@@ -435,6 +436,9 @@ var PageComponent = class PageComponent {
|
|
|
435
436
|
inputs: [
|
|
436
437
|
"user",
|
|
437
438
|
"detailed",
|
|
439
|
+
"show-initial",
|
|
440
|
+
"show-email",
|
|
441
|
+
"show-theme-settings",
|
|
438
442
|
"logoutLabel",
|
|
439
443
|
"logoutIcon"
|
|
440
444
|
],
|
|
@@ -111,6 +111,7 @@ var ShellNavigationFlyoutComponent = class ShellNavigationFlyoutComponent {
|
|
|
111
111
|
"id",
|
|
112
112
|
"data-id",
|
|
113
113
|
"data",
|
|
114
|
+
"badge-context",
|
|
114
115
|
"ariaLabel",
|
|
115
116
|
"compact",
|
|
116
117
|
"collapse-tree",
|
|
@@ -167,6 +168,9 @@ var ShellNavigationFlyoutComponent = class ShellNavigationFlyoutComponent {
|
|
|
167
168
|
inputs: [
|
|
168
169
|
"user",
|
|
169
170
|
"detailed",
|
|
171
|
+
"show-initial",
|
|
172
|
+
"show-email",
|
|
173
|
+
"show-theme-settings",
|
|
170
174
|
"logoutLabel",
|
|
171
175
|
"logoutIcon"
|
|
172
176
|
],
|