@ardimedia/angular-portal-azure 0.3.17 → 0.3.25

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.
@@ -1,5 +1,5 @@
1
1
  import * as i0 from '@angular/core';
2
- import { WritableSignal, EnvironmentProviders } from '@angular/core';
2
+ import { WritableSignal, Type, EnvironmentProviders } from '@angular/core';
3
3
  import * as _ardimedia_angular_portal_azure from '@ardimedia/angular-portal-azure';
4
4
 
5
5
  /**
@@ -19,8 +19,8 @@ interface BladeCommand {
19
19
  enabled: boolean;
20
20
  /** SVG icon identifier or CSS class for the command icon */
21
21
  icon?: string;
22
- /** Callback executed when the command is clicked */
23
- action: () => void;
22
+ /** Callback executed when the command is clicked (supports async) */
23
+ action: () => void | Promise<void>;
24
24
  }
25
25
  /**
26
26
  * Standard command keys matching the 18 commands from v0.2.346:
@@ -29,7 +29,7 @@ interface BladeCommand {
29
29
  */
30
30
  type StandardCommandKey = 'browse' | 'cancel' | 'copy' | 'delete' | 'document' | 'document2' | 'document3' | 'document4' | 'document5' | 'new' | 'order' | 'restart' | 'save' | 'search' | 'start' | 'stop' | 'swap' | 'excel';
31
31
  /** Creates a command with sensible defaults (visible, enabled, no-op action) */
32
- declare function createCommand(key: string, label: string, action: () => void, icon?: string): BladeCommand;
32
+ declare function createCommand(key: string, label: string, action: () => void | Promise<void>, icon?: string): BladeCommand;
33
33
 
34
34
  /**
35
35
  * Status bar display state for a blade.
@@ -47,6 +47,8 @@ declare function statusBarInfo(text: string): StatusBarState;
47
47
  declare function statusBarError(text: string): StatusBarState;
48
48
  declare function statusBarSuccess(text: string): StatusBarState;
49
49
 
50
+ /** @internal */
51
+ declare function nextBladeUid(): number;
50
52
  /**
51
53
  * Base blade definition used by BladeService to manage the blade stack.
52
54
  * Ported from Blade class in v0.2.346 — flattened from the UserControlBase → Blade hierarchy.
@@ -55,6 +57,8 @@ declare function statusBarSuccess(text: string): StatusBarState;
55
57
  * In v0.3.0 commands are a BladeCommand[] array and blade state is managed by the service.
56
58
  */
57
59
  interface BladeDefinition {
60
+ /** Auto-incrementing unique ID for @for track identity */
61
+ readonly uid: number;
58
62
  /** Unique path identifying this blade (lowercased) */
59
63
  path: string;
60
64
  /** Blade header title */
@@ -69,10 +73,12 @@ interface BladeDefinition {
69
73
  commands: BladeCommand[];
70
74
  /** Status bar state */
71
75
  statusBar: StatusBarState;
76
+ /** URL-persisted parameters for this blade (e.g., { id: '1' }) */
77
+ params: Record<string, string>;
72
78
  }
73
79
  /** Creates a blade definition with sensible defaults.
74
- * statusBar uses a getter/setter backed by a signal for zoneless change detection. */
75
- declare function createBlade(path: string, title: string, width?: number): BladeDefinition;
80
+ * statusBar and title use getter/setter pairs backed by signals for zoneless change detection. */
81
+ declare function createBlade(path: string, title: string, width?: number, params?: Record<string, string>, uid?: number): BladeDefinition;
76
82
  /**
77
83
  * Event args for blade navigation.
78
84
  * Ported from IAddBladeEventArgs in v0.2.346.
@@ -82,6 +88,61 @@ interface AddBladeEventArgs {
82
88
  pathSender: string;
83
89
  }
84
90
 
91
+ /**
92
+ * Localization labels for the angular-portal-azure library.
93
+ * All labels default to German (de-CH). Override via PortalConfig.labels.
94
+ */
95
+ interface PortalLabels {
96
+ loading: string;
97
+ saving: string;
98
+ saved: string;
99
+ deleting: string;
100
+ deleted: string;
101
+ loadError: string;
102
+ saveError: string;
103
+ deleteError: string;
104
+ cmdNew: string;
105
+ cmdSave: string;
106
+ cmdDelete: string;
107
+ cmdCancel: string;
108
+ search: string;
109
+ close: string;
110
+ noAppsTitle: string;
111
+ noAppsMessage: string;
112
+ closePanel: string;
113
+ lightMode: string;
114
+ darkMode: string;
115
+ switchToLight: string;
116
+ switchToDark: string;
117
+ settings: string;
118
+ language: string;
119
+ appearance: string;
120
+ }
121
+ /** Language preset definition for the built-in language registry. */
122
+ interface LanguagePreset {
123
+ code: string;
124
+ displayName: string;
125
+ labels: PortalLabels;
126
+ }
127
+ /** German (Switzerland / Liechtenstein) — default */
128
+ declare const LABELS_DE_CH: PortalLabels;
129
+ /** German (Germany) — Swiss spelling rules apply (no ß) */
130
+ declare const LABELS_DE_DE: PortalLabels;
131
+ /** English */
132
+ declare const LABELS_EN: PortalLabels;
133
+ /** French */
134
+ declare const LABELS_FR: PortalLabels;
135
+ /** Spanish */
136
+ declare const LABELS_ES: PortalLabels;
137
+ /** Italian */
138
+ declare const LABELS_IT: PortalLabels;
139
+ /** Keep DEFAULT_LABELS as alias for backward compatibility */
140
+ declare const DEFAULT_LABELS: PortalLabels;
141
+ /** Built-in language presets. Consumers can add custom presets via registerLanguagePreset(). */
142
+ declare const LANGUAGE_PRESETS: Map<string, LanguagePreset>;
143
+ /** Register a custom language preset. */
144
+ declare function registerLanguagePreset(preset: LanguagePreset): void;
145
+
85
146
  /**
86
147
  * Exception model for API error responses.
87
148
  * Ported from Exception / ExceptionDotNet in v0.2.346.
@@ -141,27 +202,27 @@ interface BladeDataDefinition<T> extends BladeDefinition {
141
202
  lifecycle: BladeDataLifecycle<T>;
142
203
  }
143
204
  /** Creates a data blade definition with sensible defaults.
144
- * statusBar, item, items use getter/setter pairs backed by signals for zoneless change detection.
205
+ * statusBar, title, item, items use getter/setter pairs backed by signals for zoneless change detection.
145
206
  * Note: cannot use ...createBlade() spread here — spread copies getter values, not getter/setter pairs. */
146
- declare function createDataBlade<T>(path: string, title: string, width?: number): BladeDataDefinition<T>;
207
+ declare function createDataBlade<T>(path: string, title: string, width?: number, params?: Record<string, string>, uid?: number): BladeDataDefinition<T>;
147
208
  /**
148
209
  * Execute a load-item operation with lifecycle hooks and status bar updates.
149
210
  * Replaces the BladeData.loadItem() template method from v0.2.346.
150
211
  */
151
- declare function executeLoadItem<T>(blade: BladeDataDefinition<T>, loadFn: () => Promise<T>): Promise<T | void>;
212
+ declare function executeLoadItem<T>(blade: BladeDataDefinition<T>, loadFn: () => Promise<T>, labels?: PortalLabels): Promise<T | void>;
152
213
  /**
153
214
  * Execute a load-items operation with lifecycle hooks and status bar updates.
154
215
  */
155
- declare function executeLoadItems<T>(blade: BladeDataDefinition<T>, loadFn: () => Promise<T[]>): Promise<T[] | void>;
216
+ declare function executeLoadItems<T>(blade: BladeDataDefinition<T>, loadFn: () => Promise<T[]>, labels?: PortalLabels): Promise<T[] | void>;
156
217
  /**
157
218
  * Execute a save-item operation with lifecycle hooks and status bar updates.
158
219
  */
159
- declare function executeSaveItem<T>(blade: BladeDataDefinition<T>, saveFn: () => Promise<T>): Promise<T | void>;
220
+ declare function executeSaveItem<T>(blade: BladeDataDefinition<T>, saveFn: () => Promise<T>, labels?: PortalLabels): Promise<T | void>;
160
221
  /**
161
222
  * Execute a delete-item operation with lifecycle hooks and status bar updates.
162
223
  * Returns true if the blade should be closed after deletion.
163
224
  */
164
- declare function executeDeleteItem<T>(blade: BladeDataDefinition<T>, deleteFn: () => Promise<void>): Promise<boolean>;
225
+ declare function executeDeleteItem<T>(blade: BladeDataDefinition<T>, deleteFn: () => Promise<void>, labels?: PortalLabels): Promise<boolean>;
165
226
 
166
227
  /**
167
228
  * Navigation item displayed in a BladeNav component.
@@ -182,6 +243,8 @@ interface BladeNavItem {
182
243
  isVisible: boolean;
183
244
  /** Optional callback executed on click (in addition to navigation) */
184
245
  callback?: () => void;
246
+ /** Optional badge text (e.g. notification count) */
247
+ badge?: string;
185
248
  }
186
249
  declare function createNavItem(title: string, bladePath: string, cssClass?: string): BladeNavItem;
187
250
 
@@ -225,6 +288,8 @@ interface TileDefinition {
225
288
  size: TileSize;
226
289
  /** Optional CSS class for tile icon/content */
227
290
  cssClass?: string;
291
+ /** Whether the tile is disabled (grayed out, not clickable) */
292
+ disabled?: boolean;
228
293
  }
229
294
  declare function createTile(title: string, bladePath: string, size?: TileSize): TileDefinition;
230
295
 
@@ -245,6 +310,15 @@ declare function getUserDisplayName(account: UserAccount): string;
245
310
  * Notification panel definition.
246
311
  * Ported from AreaNotification in v0.2.346.
247
312
  */
313
+ /** Lifecycle hooks for the notification panel */
314
+ interface NotificationLifecycle {
315
+ /** Called before hide; return false to prevent hiding */
316
+ onHide?: () => boolean;
317
+ /** Called before showing */
318
+ onShow?: () => void;
319
+ /** Called after the panel is shown */
320
+ onShowed?: () => void;
321
+ }
248
322
  interface NotificationDefinition {
249
323
  /** Path/identifier for the content shown in the notification area */
250
324
  path: string;
@@ -254,15 +328,8 @@ interface NotificationDefinition {
254
328
  isVisible: boolean;
255
329
  /** Background color (default '#32383f') */
256
330
  backgroundColor: string;
257
- }
258
- /** Lifecycle hooks for the notification panel */
259
- interface NotificationLifecycle {
260
- /** Called before hide; return false to prevent hiding */
261
- onHide?: () => boolean;
262
- /** Called before showing */
263
- onShow?: () => void;
264
- /** Called after the panel is shown */
265
- onShowed?: () => void;
331
+ /** Optional lifecycle hooks invoked during show/hide transitions */
332
+ lifecycle?: NotificationLifecycle;
266
333
  }
267
334
  declare function createNotificationPanel(): NotificationDefinition;
268
335
 
@@ -342,6 +409,10 @@ interface PortalConfig {
342
409
  userAccount?: UserAccount;
343
410
  /** Theme identifier (default: 'azure-blue') */
344
411
  theme?: string;
412
+ /** Override default labels for localization (defaults to German/de-CH) */
413
+ labels?: Partial<PortalLabels>;
414
+ /** Language code (e.g. 'en', 'fr'). Default: auto-detect from browser, fallback 'de-CH' */
415
+ language?: string;
345
416
  }
346
417
 
347
418
  /**
@@ -360,6 +431,13 @@ declare function filterItems<T>(items: T[], searchText: string): T[];
360
431
  * All state is managed via Angular signals for reactive updates.
361
432
  */
362
433
  declare class PortalService {
434
+ private static readonly LANG_STORAGE_KEY;
435
+ /** Localization labels (defaults to German/de-CH, override via PortalConfig.labels) */
436
+ readonly labels: WritableSignal<PortalLabels>;
437
+ /** Current language code */
438
+ readonly currentLanguage: WritableSignal<string>;
439
+ /** Whether the settings dropdown is open */
440
+ readonly isSettingsOpen: WritableSignal<boolean>;
363
441
  /** The blade stack — ordered left-to-right */
364
442
  readonly blades: WritableSignal<BladeDefinition[]>;
365
443
  /** Panorama (startboard/dashboard) state */
@@ -378,15 +456,27 @@ declare class PortalService {
378
456
  readonly bladeCount: i0.Signal<number>;
379
457
  /** Positioned tiles with layout coordinates */
380
458
  readonly positionedTiles: i0.Signal<PositionedTile[]>;
459
+ /** Consumer label overrides from PortalConfig — re-applied on every language switch */
460
+ private _configLabelOverrides;
381
461
  /**
382
462
  * Initialize the portal with configuration.
383
463
  * Called by providePortalAzure() during app bootstrap.
384
464
  */
385
465
  configure(config: PortalConfig): void;
466
+ /** Switch the active language. Persists to localStorage. */
467
+ setLanguage(code: string): void;
468
+ /** Detect language from browser, match to closest preset. */
469
+ private detectBrowserLanguage;
470
+ /** Toggle settings dropdown. Closes avatar menu if opening. */
471
+ toggleSettings(): void;
472
+ /** Close settings dropdown */
473
+ closeSettings(): void;
386
474
  /** Update the portal title */
387
475
  setTitle(title: string): void;
388
476
  /** Update the user account */
389
477
  setUserAccount(userAccount: UserAccount): void;
478
+ /** Clear all blades and return to panorama */
479
+ clearBlades(): void;
390
480
  /** Set tiles on the startboard */
391
481
  setTiles(tiles: TileDefinition[]): void;
392
482
  /** Set blade parameter for inter-blade communication */
@@ -394,10 +484,10 @@ declare class PortalService {
394
484
  /** Clear the blade parameter back to defaults */
395
485
  clearParameter(): void;
396
486
  /** Show the notification panel */
397
- showNotification(path: string, width?: number): void;
398
- /** Hide the notification panel */
487
+ showNotification(path: string, width?: number, lifecycle?: NotificationLifecycle): void;
488
+ /** Hide the notification panel. Aborted if onHide() returns false. */
399
489
  hideNotification(): void;
400
- /** Toggle avatar menu open/close */
490
+ /** Toggle avatar menu open/close. Closes settings if opening. */
401
491
  toggleAvatarMenu(): void;
402
492
  /** Close avatar menu */
403
493
  closeAvatarMenu(): void;
@@ -413,9 +503,13 @@ declare class PortalService {
413
503
  *
414
504
  * Manages the blade stack: adding, removing, cascade-closing,
415
505
  * and panorama visibility toggling.
506
+ *
507
+ * When a BladeRegistry is available, metadata (title, width) from the
508
+ * registry is used as defaults — explicit arguments take precedence.
416
509
  */
417
510
  declare class BladeService {
418
511
  private readonly portal;
512
+ private readonly registry;
419
513
  /**
420
514
  * Set the first blade (e.g., when opening a top-level item from a tile).
421
515
  * Clears all existing blades, hides panorama, and adds the new blade.
@@ -429,7 +523,7 @@ declare class BladeService {
429
523
  *
430
524
  * Ported from AreaBlades.addBlade() in v0.2.346.
431
525
  */
432
- addBlade(path: string, senderPath?: string, title?: string, width?: number): BladeDefinition | undefined;
526
+ addBlade(path: string, senderPath?: string, title?: string, width?: number, params?: Record<string, string>): BladeDefinition | undefined;
433
527
  /**
434
528
  * Open a blade from a navigation event (e.g., tile click, nav item click).
435
529
  * Wraps addBlade with AddBladeEventArgs for compatibility.
@@ -476,11 +570,128 @@ declare class BladeService {
476
570
  /**
477
571
  * Check if a blade with the given path is currently open.
478
572
  */
479
- isBladOpen(path: string): boolean;
573
+ isBladeOpen(path: string): boolean;
574
+ /**
575
+ * Get URL-persisted parameters for a blade by path.
576
+ * Returns empty object if blade not found or has no params.
577
+ */
578
+ getBladeParams(path: string): Record<string, string>;
480
579
  static ɵfac: i0.ɵɵFactoryDeclaration<BladeService, never>;
481
580
  static ɵprov: i0.ɵɵInjectableDeclaration<BladeService>;
482
581
  }
483
582
 
583
+ /** Entry in the blade registry: component + optional metadata for URL restoration */
584
+ interface BladeRegistryEntry {
585
+ component: Type<unknown>;
586
+ title?: string;
587
+ width?: number;
588
+ /** Parameter names this blade expects from the URL (e.g., ['id']) */
589
+ params?: string[];
590
+ }
591
+ /**
592
+ * Registry for mapping blade paths to Angular components.
593
+ *
594
+ * Allows consumer apps to register components for blade paths,
595
+ * enabling dynamic rendering in BladeHostComponent without
596
+ * manual @switch blocks.
597
+ *
598
+ * Usage in app bootstrap:
599
+ * ```typescript
600
+ * const registry = inject(BladeRegistry);
601
+ * registry.register('customers', CustomerNavComponent);
602
+ * registry.register('customers/list', CustomerListComponent, { title: 'All Customers', width: 585 });
603
+ * ```
604
+ *
605
+ * Or register multiple at once:
606
+ * ```typescript
607
+ * registry.registerAll({
608
+ * 'customers': CustomerNavComponent,
609
+ * 'customers/list': CustomerListComponent,
610
+ * });
611
+ * ```
612
+ */
613
+ declare class BladeRegistry {
614
+ private readonly registry;
615
+ /** Register a component for a blade path with optional metadata (title, width, params) */
616
+ register(path: string, component: Type<unknown>, metadata?: {
617
+ title?: string;
618
+ width?: number;
619
+ params?: string[];
620
+ }): void;
621
+ /** Register multiple blade path → component mappings */
622
+ registerAll(mappings: Record<string, Type<unknown>>): void;
623
+ /** Get the component registered for a path, if any */
624
+ get(path: string): Type<unknown> | undefined;
625
+ /** Get the full registry entry (component + metadata) for a path */
626
+ getEntry(path: string): BladeRegistryEntry | undefined;
627
+ /** Check if a component is registered for a path */
628
+ has(path: string): boolean;
629
+ static ɵfac: i0.ɵɵFactoryDeclaration<BladeRegistry, never>;
630
+ static ɵprov: i0.ɵɵInjectableDeclaration<BladeRegistry>;
631
+ }
632
+
633
+ /**
634
+ * Optional service that syncs the blade stack with the browser URL.
635
+ *
636
+ * When enabled, blade paths are stored as URL path segments with matrix params:
637
+ * `/crm/customers/list/detail;id=1`
638
+ *
639
+ * This makes blade states bookmarkable, shareable, and back-button navigable.
640
+ *
641
+ * Opt-in: add `provideBladeRouter()` to your app providers alongside `provideRouter()`.
642
+ * Without it, blade navigation remains purely in-memory (no URL changes).
643
+ */
644
+ declare class BladeRouterService {
645
+ private readonly router;
646
+ private readonly portal;
647
+ private readonly registry;
648
+ private readonly destroyRef;
649
+ private _syncingFromUrl;
650
+ private _initialRestoreDone;
651
+ constructor();
652
+ /**
653
+ * Encode the blade stack into URL path segments.
654
+ * Each blade contributes its "short name" (suffix after parent prefix).
655
+ * Blades with params get Angular matrix params appended.
656
+ *
657
+ * Example: [customers, customers/list, customers/detail{id:1}]
658
+ * → "customers/list/detail;id=1"
659
+ */
660
+ private encodeBladesToPath;
661
+ /**
662
+ * Decode URL path segments into blade definitions.
663
+ * Resolves short segment names to full blade paths using the registry.
664
+ *
665
+ * Example: "customers/list/detail;id=1" with route prefix "crm"
666
+ * → [customers, customers/list, customers/detail] with detail.params={id:'1'}
667
+ */
668
+ private decodeBladesFromPath;
669
+ /**
670
+ * Parse a URL segment into its name and matrix parameters.
671
+ * "detail;id=1;mode=edit" → { name: "detail", params: { id: "1", mode: "edit" } }
672
+ */
673
+ private parseSegment;
674
+ /**
675
+ * Resolve a short segment name to a full blade path using the registry.
676
+ * Tries parent/segment first, then walks up ancestors.
677
+ */
678
+ private resolveSegment;
679
+ /** Restore blade stack from a path-based URL */
680
+ private restoreFromPath;
681
+ /** Check if params match between two blade arrays */
682
+ private paramsMatch;
683
+ /** Get the route prefix from the current URL (e.g., 'crm' from '/crm/...') */
684
+ private getRoutePrefix;
685
+ /** Normalize URL for comparison (strip trailing slashes) */
686
+ private normalizeUrl;
687
+ /** Extract legacy `blades` query parameter from URL */
688
+ private extractLegacyBladesParam;
689
+ /** Handle legacy ?blades= URL by redirecting to new path format */
690
+ private handleLegacyUrl;
691
+ static ɵfac: i0.ɵɵFactoryDeclaration<BladeRouterService, never>;
692
+ static ɵprov: i0.ɵɵInjectableDeclaration<BladeRouterService>;
693
+ }
694
+
484
695
  /**
485
696
  * Provide the angular-portal-azure library configuration.
486
697
  *
@@ -501,6 +712,27 @@ declare class BladeService {
501
712
  */
502
713
  declare function providePortalAzure(config: PortalConfig): EnvironmentProviders;
503
714
 
715
+ /**
716
+ * Enables opt-in URL synchronization for the blade stack.
717
+ *
718
+ * Add alongside `provideRouter()` and `providePortalAzure()`:
719
+ * ```typescript
720
+ * export const appConfig: ApplicationConfig = {
721
+ * providers: [
722
+ * provideRouter(routes),
723
+ * providePortalAzure({ title: 'My Portal', ... }),
724
+ * provideBladeRouter(),
725
+ * ],
726
+ * };
727
+ * ```
728
+ *
729
+ * When enabled, blade paths sync to the URL as a query parameter:
730
+ * `?blades=customers,customers/list,customers/1`
731
+ *
732
+ * Without this provider, blade navigation remains purely in-memory.
733
+ */
734
+ declare function provideBladeRouter(): EnvironmentProviders;
735
+
504
736
  /**
505
737
  * Individual dashboard tile.
506
738
  * Ported from the tile section in home.html (v0.2.346).
@@ -525,25 +757,34 @@ declare class TileComponent {
525
757
  * Displays tiles on the startboard. When a tile is clicked, it opens
526
758
  * the first blade via BladeService.setFirstBlade().
527
759
  *
760
+ * When `autoNavigate` is true (default), clicking a tile automatically
761
+ * opens the first blade. Set it to false to handle tile clicks manually
762
+ * via the `(tileClick)` output.
763
+ *
528
764
  * Usage:
529
765
  * ```html
530
766
  * <apa-panorama />
767
+ * <apa-panorama [autoNavigate]="false" (tileClick)="onTileClick($event)" />
531
768
  * ```
532
769
  */
533
770
  declare class PanoramaComponent {
534
771
  protected readonly portal: PortalService;
535
772
  private readonly bladeService;
773
+ /** When false, tile clicks only emit tileClick without opening a blade. */
774
+ readonly autoNavigate: i0.InputSignal<boolean>;
775
+ /** Emitted when a tile is clicked (always, regardless of autoNavigate). */
776
+ readonly tileClick: i0.OutputEmitterRef<PositionedTile>;
536
777
  protected panorama: i0.WritableSignal<_ardimedia_angular_portal_azure.PanoramaDefinition>;
537
778
  onTileClick(tile: PositionedTile): void;
538
779
  static ɵfac: i0.ɵɵFactoryDeclaration<PanoramaComponent, never>;
539
- static ɵcmp: i0.ɵɵComponentDeclaration<PanoramaComponent, "apa-panorama", never, {}, {}, never, never, true, never>;
780
+ static ɵcmp: i0.ɵɵComponentDeclaration<PanoramaComponent, "apa-panorama", never, { "autoNavigate": { "alias": "autoNavigate"; "required": false; "isSignal": true; }; }, { "tileClick": "tileClick"; }, never, never, true, never>;
540
781
  }
541
782
 
542
783
  /**
543
784
  * Root portal shell component.
544
785
  * Ported from the fxs-portal structure in home.html (v0.2.346).
545
786
  *
546
- * Provides the top bar (with portal title and avatar menu),
787
+ * Provides the top bar (with portal title, settings gear, and avatar menu),
547
788
  * and the main content area. Child components (panorama, blade-host,
548
789
  * notification-panel) are projected via content projection.
549
790
  *
@@ -561,9 +802,16 @@ declare class PortalLayoutComponent {
561
802
  private readonly document;
562
803
  private readonly elementRef;
563
804
  private readonly injector;
805
+ private readonly destroyRef;
564
806
  protected readonly isDark: i0.WritableSignal<boolean>;
807
+ /** Available languages from the preset registry */
808
+ protected readonly availableLanguages: {
809
+ code: string;
810
+ displayName: string;
811
+ }[];
565
812
  constructor();
566
813
  protected toggleDarkMode(): void;
814
+ protected switchLanguage(code: string): void;
567
815
  private applyTheme;
568
816
  protected displayName(): string;
569
817
  protected initials(): string;
@@ -610,6 +858,7 @@ declare class CommandBarComponent {
610
858
  declare class BladeComponent {
611
859
  readonly blade: i0.InputSignal<BladeDefinition>;
612
860
  readonly bladeClose: i0.OutputEmitterRef<BladeDefinition>;
861
+ protected readonly portal: PortalService;
613
862
  private readonly bladeService;
614
863
  onClose(): void;
615
864
  static ɵfac: i0.ɵɵFactoryDeclaration<BladeComponent, never>;
@@ -623,8 +872,9 @@ declare class BladeComponent {
623
872
  * Each blade in the stack is rendered horizontally. When a new blade
624
873
  * is added, the portal layout scrolls to show it.
625
874
  *
626
- * Consumer apps provide blade content via the [bladeTemplate] input
627
- * or by routing. For now, blades are rendered with their path as content.
875
+ * If a component is registered via BladeRegistry for a blade path,
876
+ * it is rendered dynamically via ngComponentOutlet. Otherwise,
877
+ * the blade path is shown as fallback text.
628
878
  *
629
879
  * Usage:
630
880
  * ```html
@@ -633,6 +883,8 @@ declare class BladeComponent {
633
883
  */
634
884
  declare class BladeHostComponent {
635
885
  protected readonly portal: PortalService;
886
+ private readonly registry;
887
+ getComponent(path: string): i0.Type<unknown> | null;
636
888
  static ɵfac: i0.ɵɵFactoryDeclaration<BladeHostComponent, never>;
637
889
  static ɵcmp: i0.ɵɵComponentDeclaration<BladeHostComponent, "apa-blade-host", never, {}, {}, never, never, true, never>;
638
890
  }
@@ -685,16 +937,19 @@ declare class BladeGridComponent {
685
937
  readonly senderPath: i0.InputSignal<string>;
686
938
  readonly displayField: i0.InputSignal<string>;
687
939
  readonly bladePathField: i0.InputSignal<string>;
940
+ readonly idField: i0.InputSignal<string>;
941
+ readonly iconClass: i0.InputSignal<string>;
688
942
  readonly searchable: i0.InputSignal<boolean>;
689
943
  readonly itemClick: i0.OutputEmitterRef<any>;
690
944
  searchText: string;
691
945
  private readonly bladeService;
946
+ protected readonly portal: PortalService;
692
947
  filteredItems(): any[];
693
948
  getDisplayValue(item: any): string;
694
949
  onSearchInput(event: Event): void;
695
950
  onRowClick(item: any): void;
696
951
  static ɵfac: i0.ɵɵFactoryDeclaration<BladeGridComponent, never>;
697
- static ɵcmp: i0.ɵɵComponentDeclaration<BladeGridComponent, "apa-blade-grid", never, { "items": { "alias": "items"; "required": false; "isSignal": true; }; "senderPath": { "alias": "senderPath"; "required": false; "isSignal": true; }; "displayField": { "alias": "displayField"; "required": false; "isSignal": true; }; "bladePathField": { "alias": "bladePathField"; "required": false; "isSignal": true; }; "searchable": { "alias": "searchable"; "required": false; "isSignal": true; }; }, { "itemClick": "itemClick"; }, never, never, true, never>;
952
+ static ɵcmp: i0.ɵɵComponentDeclaration<BladeGridComponent, "apa-blade-grid", never, { "items": { "alias": "items"; "required": false; "isSignal": true; }; "senderPath": { "alias": "senderPath"; "required": false; "isSignal": true; }; "displayField": { "alias": "displayField"; "required": false; "isSignal": true; }; "bladePathField": { "alias": "bladePathField"; "required": false; "isSignal": true; }; "idField": { "alias": "idField"; "required": false; "isSignal": true; }; "iconClass": { "alias": "iconClass"; "required": false; "isSignal": true; }; "searchable": { "alias": "searchable"; "required": false; "isSignal": true; }; }, { "itemClick": "itemClick"; }, never, never, true, never>;
698
953
  }
699
954
 
700
955
  /**
@@ -733,7 +988,7 @@ declare function createDetailCommands(handlers: {
733
988
  onSave?: () => void;
734
989
  onDelete?: () => void;
735
990
  onCancel?: () => void;
736
- }): BladeCommand[];
991
+ }, labels?: PortalLabels): BladeCommand[];
737
992
 
738
993
  /**
739
994
  * Notification panel — right-side overlay panel.
@@ -748,6 +1003,8 @@ declare function createDetailCommands(handlers: {
748
1003
  */
749
1004
  declare class NotificationPanelComponent {
750
1005
  protected readonly portal: PortalService;
1006
+ private wasVisible;
1007
+ constructor();
751
1008
  onClose(): void;
752
1009
  static ɵfac: i0.ɵɵFactoryDeclaration<NotificationPanelComponent, never>;
753
1010
  static ɵcmp: i0.ɵɵComponentDeclaration<NotificationPanelComponent, "apa-notification-panel", never, {}, {}, never, ["*"], true, never>;
@@ -785,17 +1042,20 @@ declare class AvatarMenuComponent {
785
1042
  * Usage:
786
1043
  * ```html
787
1044
  * <apa-sidebar [items]="sidebarItems" [collapsed]="false" />
1045
+ * <apa-sidebar [items]="sidebarItems" [width]="240" [collapsedWidth]="60" />
788
1046
  * ```
789
1047
  */
790
1048
  declare class SidebarComponent {
791
1049
  readonly items: i0.InputSignal<BladeNavItem[]>;
792
1050
  readonly collapsed: i0.InputSignal<boolean>;
1051
+ readonly width: i0.InputSignal<number>;
1052
+ readonly collapsedWidth: i0.InputSignal<number>;
793
1053
  private readonly bladeService;
794
1054
  visibleItems(): BladeNavItem[];
795
1055
  onItemClick(item: BladeNavItem): void;
796
1056
  static ɵfac: i0.ɵɵFactoryDeclaration<SidebarComponent, never>;
797
- static ɵcmp: i0.ɵɵComponentDeclaration<SidebarComponent, "apa-sidebar", never, { "items": { "alias": "items"; "required": false; "isSignal": true; }; "collapsed": { "alias": "collapsed"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
1057
+ static ɵcmp: i0.ɵɵComponentDeclaration<SidebarComponent, "apa-sidebar", never, { "items": { "alias": "items"; "required": false; "isSignal": true; }; "collapsed": { "alias": "collapsed"; "required": false; "isSignal": true; }; "width": { "alias": "width"; "required": false; "isSignal": true; }; "collapsedWidth": { "alias": "collapsedWidth"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
798
1058
  }
799
1059
 
800
- export { AvatarMenuComponent, BladeComponent, BladeDetailComponent, BladeGridComponent, BladeHostComponent, BladeNavComponent, BladeService, CommandBarComponent, NotificationPanelComponent, PanoramaComponent, PortalLayoutComponent, PortalService, SidebarComponent, TILE_DIMENSIONS, TileComponent, TileSize, clearStatusBar, createAvatarMenu, createBlade, createCommand, createDataBlade, createDetailCommands, createNavItem, createNotificationPanel, createPanorama, createTile, executeDeleteItem, executeLoadItem, executeLoadItems, executeSaveItem, filterItems, getUserDisplayName, layoutTiles, providePortalAzure, statusBarError, statusBarInfo, statusBarSuccess };
801
- export type { AddBladeEventArgs, ApiException, AvatarMenuDefinition, AvatarMenuItem, BladeCommand, BladeDataDefinition, BladeDataLifecycle, BladeDefinition, BladeNavItem, BladeParameter, NotificationDefinition, NotificationLifecycle, PanoramaDefinition, PortalConfig, PositionedTile, StandardCommandKey, StatusBarState, StatusBarStyle, TileDefinition, UserAccount };
1060
+ export { AvatarMenuComponent, BladeComponent, BladeDetailComponent, BladeGridComponent, BladeHostComponent, BladeNavComponent, BladeRegistry, BladeRouterService, BladeService, CommandBarComponent, DEFAULT_LABELS, LABELS_DE_CH, LABELS_DE_DE, LABELS_EN, LABELS_ES, LABELS_FR, LABELS_IT, LANGUAGE_PRESETS, NotificationPanelComponent, PanoramaComponent, PortalLayoutComponent, PortalService, SidebarComponent, TILE_DIMENSIONS, TileComponent, TileSize, clearStatusBar, createAvatarMenu, createBlade, createCommand, createDataBlade, createDetailCommands, createNavItem, createNotificationPanel, createPanorama, createTile, executeDeleteItem, executeLoadItem, executeLoadItems, executeSaveItem, filterItems, getUserDisplayName, layoutTiles, nextBladeUid, provideBladeRouter, providePortalAzure, registerLanguagePreset, statusBarError, statusBarInfo, statusBarSuccess };
1061
+ export type { AddBladeEventArgs, ApiException, AvatarMenuDefinition, AvatarMenuItem, BladeCommand, BladeDataDefinition, BladeDataLifecycle, BladeDefinition, BladeNavItem, BladeParameter, BladeRegistryEntry, LanguagePreset, NotificationDefinition, NotificationLifecycle, PanoramaDefinition, PortalConfig, PortalLabels, PositionedTile, StandardCommandKey, StatusBarState, StatusBarStyle, TileDefinition, UserAccount };