@lifecorner/angular-ui-kit 3.13.1 → 3.14.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -18,6 +18,10 @@ export type SidenavVariant = 'default' | 'transparent';
18
18
  * - Responsive mobile mode — docked automatically switches to drawer below a configurable breakpoint
19
19
  * - Collapsed icon-rail mode (narrow 56px sidebar with icons only and hover tooltips)
20
20
  * - Integrated logo area with collapse-toggle (sidebar-first layouts)
21
+ * - Text brand (`brandName`, `brandIcon`): an icon tile and the product name,
22
+ * one link to home (`brandHref`, else `routerLink="/"`), as high as the
23
+ * `lc-header` next to it; the rail shows only the tile. It never toggles:
24
+ * `showCollapseToggle` adds a collapse button at the bottom of the rail
21
25
  * - Hierarchical navigation with collapsible groups (up to 3 levels)
22
26
  * - Section headlines for item grouping with optional action buttons
23
27
  * - Action buttons on any item (hover-reveal)
@@ -29,7 +33,15 @@ export type SidenavVariant = 'default' | 'transparent';
29
33
  * - Keyboard navigation support (Escape closes drawer)
30
34
  * - Configurable width and position (left/right)
31
35
  * - Optional backdrop overlay
32
- * - Theme variants: auto, light, dark (with teal accent for dark mode)
36
+ * - Theme variants: auto, light, dark (with teal accent for dark mode). The
37
+ * theming hooks (`--lc-sidenav-bg`, `-fg`, `-fg-active`, `-border`,
38
+ * `-hover-bg`, `-section-fg`, `-active-bg`, `-active-fg`, `-active-icon`)
39
+ * set on `lc-sidenav` win over `theme` (3.14); `--lc-sidenav-active-indicator`
40
+ * (the current item's 2 px bar, default `--color-primary-500`; on a
41
+ * `theme="light"` rail #208497 on any page, like its focus rings),
42
+ * `--lc-sidenav-brand-tile-bg` (default `--color-primary-fill`) and
43
+ * `--lc-sidenav-brand-tile-fg` (default `--color-on-primary`) can be set on
44
+ * any ancestor
33
45
  * - `variant="transparent"`: no rail background or border, items as 48 px
34
46
  * pills with 16 px labels, the current one on `--color-surface-selected`
35
47
  * - Items are at least 44 px high in every density; the current item's ink is
@@ -77,8 +89,51 @@ export declare class SidenavComponent implements OnDestroy {
77
89
  readonly logoDarkEmblemSrc: import("@angular/core").InputSignal<string>;
78
90
  /** Alt text for the brand logo. */
79
91
  readonly logoAlt: import("@angular/core").InputSignal<string>;
80
- /** Size of the brand logo (forwarded to inner `<lc-logo>`). Defaults to `md` for a prominent brand block aligned with `<lc-header size="md">` (both 64px). */
92
+ /** Size of the brand logo (forwarded to inner `<lc-logo>`). Defaults to `md` for a prominent brand block aligned with `<lc-header size="md">` (both 64px). Also sets the height of the text brand (`brandName`). */
81
93
  readonly logoSize: import("@angular/core").InputSignal<"xs" | "sm" | "md" | "lg" | "xl">;
94
+ /**
95
+ * Product name shown as a text brand at the top: an icon tile and the name,
96
+ * one link to home. Replaces the image logo (`showLogo`). The block is as
97
+ * high as the image logo (`logoSize`: 64 px for `md`, matching
98
+ * `lc-header size="md"`); the name wraps to two lines at most, and the full
99
+ * name stays the link's accessible name. Collapsed, only the tile shows.
100
+ * The brand never toggles the rail (see `showCollapseToggle`). Under
101
+ * `@defer`, give the `lc-sidenav-placeholder` `[showLogo]="true"` and the
102
+ * same `logoSize` to reserve the block. Empty: no text brand.
103
+ * @default ''
104
+ */
105
+ readonly brandName: import("@angular/core").InputSignal<string>;
106
+ /**
107
+ * `lc-icon` name in the brand tile (decorative). Empty: the tile shows the
108
+ * name's first letter. Renders nothing without `brandName`.
109
+ * @default ''
110
+ */
111
+ readonly brandIcon: import("@angular/core").InputSignal<string>;
112
+ /**
113
+ * Plain URL of the brand link (a native `<a href>`, works without the
114
+ * router). Empty: `routerLink="/"`, as `lc-header`'s `homeHref`.
115
+ * @default ''
116
+ */
117
+ readonly brandHref: import("@angular/core").InputSignal<string>;
118
+ /**
119
+ * Accessible name of the brand link. Empty: the brand name. Start it with
120
+ * the visible name, e.g. `'Finance Intelligence – home'`.
121
+ * @default ''
122
+ */
123
+ readonly brandAriaLabel: import("@angular/core").InputSignal<string>;
124
+ /**
125
+ * Docked mode: a button at the bottom of the rail collapses and expands it
126
+ * (`collapsed`). Independent of the brand. With `showLogo` the image logo
127
+ * toggles already, so use one of the two.
128
+ * @default false
129
+ */
130
+ readonly showCollapseToggle: import("@angular/core").InputSignal<boolean>;
131
+ /**
132
+ * Accessible name of the collapse button (`showCollapseToggle`) while the
133
+ * rail is collapsed. Expanded, it uses `collapseAriaLabel`.
134
+ * @default 'Expand navigation'
135
+ */
136
+ readonly expandAriaLabel: import("@angular/core").InputSignal<string>;
82
137
  /** Whether the sidenav is open */
83
138
  readonly isOpen: import("@angular/core").InputSignal<boolean>;
84
139
  /** Display mode: 'drawer' (overlay) or 'docked' (persistent sidebar) */
@@ -203,10 +258,20 @@ export declare class SidenavComponent implements OnDestroy {
203
258
  sidenavStyles: import("@angular/core").Signal<{
204
259
  width: string;
205
260
  }>;
261
+ /** The brand tile's letter when there is no `brandIcon`: the name's first character, upper-cased. */
262
+ protected readonly brandInitial: import("@angular/core").Signal<string>;
263
+ /** Whether the rail shows only icons (as `lc-sidenav--collapsed`). */
264
+ protected readonly isRail: import("@angular/core").Signal<boolean>;
265
+ /** The collapse button's accessible name: what a press does. */
266
+ protected readonly collapseToggleLabel: import("@angular/core").Signal<string>;
267
+ /** The collapse button's chevron points where the rail moves: ⟨ to collapse a left rail, ⟩ to expand it (mirrored on the right). */
268
+ protected readonly collapseToggleIcon: import("@angular/core").Signal<"chevron-left" | "chevron-right">;
206
269
  /**
207
270
  * Toggle collapsed state
208
271
  */
209
272
  toggleCollapsed(): void;
273
+ /** The brand link closes the drawer on a phone, as the items do. */
274
+ handleBrandClick(): void;
210
275
  /**
211
276
  * Handle close action
212
277
  */
@@ -285,6 +350,36 @@ export declare class SidenavComponent implements OnDestroy {
285
350
  "required": false;
286
351
  "isSignal": true;
287
352
  };
353
+ "brandName": {
354
+ "alias": "brandName";
355
+ "required": false;
356
+ "isSignal": true;
357
+ };
358
+ "brandIcon": {
359
+ "alias": "brandIcon";
360
+ "required": false;
361
+ "isSignal": true;
362
+ };
363
+ "brandHref": {
364
+ "alias": "brandHref";
365
+ "required": false;
366
+ "isSignal": true;
367
+ };
368
+ "brandAriaLabel": {
369
+ "alias": "brandAriaLabel";
370
+ "required": false;
371
+ "isSignal": true;
372
+ };
373
+ "showCollapseToggle": {
374
+ "alias": "showCollapseToggle";
375
+ "required": false;
376
+ "isSignal": true;
377
+ };
378
+ "expandAriaLabel": {
379
+ "alias": "expandAriaLabel";
380
+ "required": false;
381
+ "isSignal": true;
382
+ };
288
383
  "isOpen": {
289
384
  "alias": "isOpen";
290
385
  "required": false;
@@ -1,6 +1,26 @@
1
1
  import { SparklineColor } from "@lifecorner/angular-ui-kit/sparkline";
2
2
  import * as i0 from "@angular/core";
3
3
  export type StatTrendDirection = 'up' | 'down' | 'neutral';
4
+ /** Whether a change is good or bad for the reader, independent of its direction. */
5
+ export type StatTrendSentiment = 'positive' | 'negative' | 'neutral';
6
+ /**
7
+ * Words of the screen-reader text that `lc-stat-trend` adds to the change when
8
+ * `sentiment` is set (", up, unfavourable"). Override single keys via `labels`.
9
+ */
10
+ export interface StatTrendLabels {
11
+ /** Direction up. EN "up", DE "gestiegen". */
12
+ up: string;
13
+ /** Direction down. EN "down", DE "gesunken". */
14
+ down: string;
15
+ /** Direction neutral. EN "unchanged", DE "unverändert". */
16
+ unchanged: string;
17
+ /** Sentiment positive. EN "favourable", DE "günstig". */
18
+ positive: string;
19
+ /** Sentiment negative. EN "unfavourable", DE "ungünstig". */
20
+ negative: string;
21
+ /** Sentiment neutral. EN "neutral", DE "neutral". */
22
+ neutral: string;
23
+ }
4
24
  export declare class StatTrendComponent {
5
25
  /** Main KPI label. */
6
26
  label: import("@angular/core").InputSignal<string>;
@@ -10,6 +30,20 @@ export declare class StatTrendComponent {
10
30
  change: import("@angular/core").InputSignal<string>;
11
31
  /** Trend direction for color coding. Auto-detected from change if not set. */
12
32
  direction: import("@angular/core").InputSignal<StatTrendDirection | undefined>;
33
+ /**
34
+ * Whether the change is good or bad, independent of its direction (a rise in
35
+ * costs is negative). Colours the change and the default sparkline; the arrow
36
+ * keeps the direction. Unset: derived from the direction.
37
+ * @default undefined
38
+ */
39
+ sentiment: import("@angular/core").InputSignal<StatTrendSentiment | undefined>;
40
+ /**
41
+ * Words of the screen-reader text added to the change when `sentiment` is set.
42
+ * Missing keys fall back to the English defaults (up, down, unchanged,
43
+ * favourable, unfavourable, neutral).
44
+ * @default {}
45
+ */
46
+ labels: import("@angular/core").InputSignal<Partial<StatTrendLabels>>;
13
47
  /** Sparkline data points. If empty, no sparkline is shown. */
14
48
  sparklineData: import("@angular/core").InputSignal<number[]>;
15
49
  /** Color of the sparkline. Auto-matched to trend direction if not set. */
@@ -20,6 +54,8 @@ export declare class StatTrendComponent {
20
54
  protected readonly trendColorClass: import("@angular/core").Signal<string>;
21
55
  protected readonly resolvedSparklineColor: import("@angular/core").Signal<SparklineColor>;
22
56
  protected readonly trendIcon: import("@angular/core").Signal<string>;
57
+ /** ", up, unfavourable": rendered only when `sentiment` is set. */
58
+ protected readonly srText: import("@angular/core").Signal<string>;
23
59
  protected readonly hasSparkline: import("@angular/core").Signal<boolean>;
24
60
  static ɵfac: i0.ɵɵFactoryDeclaration<StatTrendComponent, never>;
25
61
  static ɵcmp: i0.ɵɵComponentDeclaration<StatTrendComponent, "lc-stat-trend", never, {
@@ -43,6 +79,16 @@ export declare class StatTrendComponent {
43
79
  "required": false;
44
80
  "isSignal": true;
45
81
  };
82
+ "sentiment": {
83
+ "alias": "sentiment";
84
+ "required": false;
85
+ "isSignal": true;
86
+ };
87
+ "labels": {
88
+ "alias": "labels";
89
+ "required": false;
90
+ "isSignal": true;
91
+ };
46
92
  "sparklineData": {
47
93
  "alias": "sparklineData";
48
94
  "required": false;