@cngx/common 0.1.0-rc.7 → 0.1.0-rc.8

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 (63) hide show
  1. package/card/README.md +2 -1
  2. package/data/README.md +10 -1
  3. package/dialog/README.md +23 -1
  4. package/fesm2022/cngx-common-a11y.mjs +125 -111
  5. package/fesm2022/cngx-common-a11y.mjs.map +1 -1
  6. package/fesm2022/cngx-common-audio.mjs +47 -5
  7. package/fesm2022/cngx-common-audio.mjs.map +1 -1
  8. package/fesm2022/cngx-common-card.mjs +300 -46
  9. package/fesm2022/cngx-common-card.mjs.map +1 -1
  10. package/fesm2022/cngx-common-chart.mjs +1176 -453
  11. package/fesm2022/cngx-common-chart.mjs.map +1 -1
  12. package/fesm2022/cngx-common-command.mjs +37 -10
  13. package/fesm2022/cngx-common-command.mjs.map +1 -1
  14. package/fesm2022/cngx-common-data.mjs +1318 -469
  15. package/fesm2022/cngx-common-data.mjs.map +1 -1
  16. package/fesm2022/cngx-common-dialog.mjs +151 -14
  17. package/fesm2022/cngx-common-dialog.mjs.map +1 -1
  18. package/fesm2022/cngx-common-display.mjs +340 -73
  19. package/fesm2022/cngx-common-display.mjs.map +1 -1
  20. package/fesm2022/cngx-common-interactive.mjs +1744 -952
  21. package/fesm2022/cngx-common-interactive.mjs.map +1 -1
  22. package/fesm2022/cngx-common-layout.mjs +841 -114
  23. package/fesm2022/cngx-common-layout.mjs.map +1 -1
  24. package/fesm2022/cngx-common-popover.mjs +350 -60
  25. package/fesm2022/cngx-common-popover.mjs.map +1 -1
  26. package/fesm2022/cngx-common-stepper.mjs +727 -317
  27. package/fesm2022/cngx-common-stepper.mjs.map +1 -1
  28. package/fesm2022/cngx-common-tabs.mjs +1601 -1243
  29. package/fesm2022/cngx-common-tabs.mjs.map +1 -1
  30. package/fesm2022/cngx-common-timeline.mjs +137 -53
  31. package/fesm2022/cngx-common-timeline.mjs.map +1 -1
  32. package/fesm2022/cngx-common.mjs +1 -1
  33. package/interactive/README.md +15 -4
  34. package/layout/README.md +21 -1
  35. package/package.json +3 -3
  36. package/popover/README.md +18 -2
  37. package/stepper/README.md +6 -4
  38. package/theming/components/cngx-accordion.css +1 -1
  39. package/theming/components/cngx-backdrop.css +12 -0
  40. package/theming/components/cngx-button-toggle.css +29 -3
  41. package/theming/components/cngx-data-grid.css +168 -1
  42. package/theming/components/cngx-dialog.css +13 -0
  43. package/theming/components/cngx-listbox.css +21 -12
  44. package/theming/components/cngx-menu.css +56 -16
  45. package/theming/components/cngx-popover.css +24 -0
  46. package/theming/components/cngx-recycler-placeholder.css +196 -0
  47. package/theming/components/cngx-ripple.css +1 -1
  48. package/theming/components/cngx-slider.css +32 -1
  49. package/theming/components/cngx-tooltip.css +12 -0
  50. package/timeline/README.md +155 -0
  51. package/types/cngx-common-a11y.d.ts +42 -18
  52. package/types/cngx-common-card.d.ts +201 -17
  53. package/types/cngx-common-chart.d.ts +343 -47
  54. package/types/cngx-common-command.d.ts +31 -8
  55. package/types/cngx-common-data.d.ts +581 -68
  56. package/types/cngx-common-dialog.d.ts +158 -3
  57. package/types/cngx-common-display.d.ts +356 -142
  58. package/types/cngx-common-interactive.d.ts +859 -210
  59. package/types/cngx-common-layout.d.ts +567 -28
  60. package/types/cngx-common-popover.d.ts +262 -39
  61. package/types/cngx-common-stepper.d.ts +366 -116
  62. package/types/cngx-common-tabs.d.ts +214 -50
  63. package/types/cngx-common-timeline.d.ts +82 -16
@@ -4,6 +4,7 @@ import { CngxAsyncState, StatusTransition } from '@cngx/core/utils';
4
4
  import { Observable } from 'rxjs';
5
5
  import * as i1 from '@cngx/common/interactive';
6
6
  import { CngxErrorAggregatorContract, SwipeDirection } from '@cngx/common/interactive';
7
+ import { CngxMessage } from '@cngx/core/i18n';
7
8
  import { CngxDirection } from '@cngx/core';
8
9
  import { CngxCommitController } from '@cngx/common/data';
9
10
 
@@ -155,6 +156,17 @@ interface CngxStepperHost {
155
156
  readonly previousStepLabel: Signal<string | undefined>;
156
157
  readonly linear: Signal<boolean>;
157
158
  readonly orientation: Signal<'horizontal' | 'vertical'>;
159
+ /**
160
+ * Resolved commit mode (`input ?? config ?? default`, with the DI
161
+ * fallback's pinned mode winning while a routed action is active).
162
+ * On the contract so Level-2 builders can gate mode-dependent
163
+ * behaviour - e.g. the pending-to-success announcement only applies
164
+ * in pessimistic mode, where the accept is what moves the step.
165
+ * Optional so pre-existing custom host implementations stay
166
+ * assignable; readers treat absence as `'pessimistic'` (the stepper
167
+ * default).
168
+ */
169
+ readonly commitMode?: Signal<'optimistic' | 'pessimistic'>;
158
170
  readonly commitState: CngxAsyncState<number | undefined>;
159
171
  readonly intendedStepIndex: Signal<number | undefined>;
160
172
  /**
@@ -199,7 +211,13 @@ interface CngxStepperHost {
199
211
  */
200
212
  clearLastFailed(): void;
201
213
  register(handle: CngxStepRegistration, parentId?: string | null): void;
202
- unregister(id: string): void;
214
+ /**
215
+ * Remove a registration. Pass the registering `handle` so a destroyed
216
+ * instance can only evict itself: under an id collision the presenter's
217
+ * idempotent re-register replaces the stored handle, and the OLD
218
+ * instance's late destroy must not tear down the NEW instance's entry.
219
+ */
220
+ unregister(id: string, handle?: CngxStepRegistration): void;
203
221
  }
204
222
  /**
205
223
  * DI token carrying the presenter's contract to atoms + organism shells.
@@ -272,6 +290,7 @@ declare class CngxStepperPresenter implements CngxStepperHost {
272
290
  */
273
291
  readonly commitTransition: StatusTransition;
274
292
  private readonly lastFailedIndexState;
293
+ private lastCommittedIndex;
275
294
  private readonly originIndexDuringCommitState;
276
295
  /** {@inheritDoc CngxStepperHost.lastFailedIndex} */
277
296
  readonly lastFailedIndex: Signal<number | undefined>;
@@ -324,7 +343,9 @@ declare class CngxStepperPresenter implements CngxStepperHost {
324
343
  private readonly nextEnabledIndex;
325
344
  /**
326
345
  * Previous enabled step-only index before the active one, skipping
327
- * disabled steps. Returns `-1` when no enabled step precedes. Single
346
+ * disabled steps. Returns `-1` when no enabled step precedes - also for
347
+ * a stale out-of-range active index (consumer-writable model), which
348
+ * must resolve to "none" instead of wrapping or throwing. Single
328
349
  * source for `selectPrevious()` and the `canGoPrevious` bound.
329
350
  */
330
351
  private readonly previousEnabledIndex;
@@ -354,7 +375,7 @@ declare class CngxStepperPresenter implements CngxStepperHost {
354
375
  private readonly registry;
355
376
  private readonly insertionOrder;
356
377
  register(handle: CngxStepRegistration, parentId?: string | null): void;
357
- unregister(id: string): void;
378
+ unregister(id: string, handle?: CngxStepRegistration): void;
358
379
  private rebuildTree;
359
380
  /** {@inheritDoc CngxStepperHost.clearLastFailed} */
360
381
  clearLastFailed(): void;
@@ -378,9 +399,23 @@ declare class CngxStepperPresenter implements CngxStepperHost {
378
399
  canNavigateTo(index: number): boolean;
379
400
  select(index: number): void;
380
401
  selectNext(): void;
402
+ /**
403
+ * Ungated back-move. Supersedes an in-flight commit: the runner is
404
+ * canceled and the commit state settles to idle, so `busy` cannot
405
+ * latch and a late resolve cannot yank the user forward off the step
406
+ * they explicitly returned to.
407
+ */
381
408
  selectPrevious(): void;
382
409
  selectById(id: string): void;
383
410
  reset(): void;
411
+ /**
412
+ * Cancels the in-flight commit and settles the state to idle. The
413
+ * settle option is load-bearing here - a custom
414
+ * `CNGX_COMMIT_CONTROLLER_FACTORY` implementation that ignores it
415
+ * leaves `busy` latched, which is invisible until a user backs out
416
+ * mid-commit; the dev-mode probe surfaces that immediately.
417
+ */
418
+ private cancelAndSettleCommit;
384
419
  static ɵfac: i0.ɵɵFactoryDeclaration<CngxStepperPresenter, never>;
385
420
  static ɵdir: i0.ɵɵDirectiveDeclaration<CngxStepperPresenter, "[cngxStepper]", ["cngxStepper"], { "activeStepIndex": { "alias": "activeStepIndex"; "required": false; "isSignal": true; }; "linearInput": { "alias": "linear"; "required": false; "isSignal": true; }; "orientationInput": { "alias": "orientation"; "required": false; "isSignal": true; }; "commitAction": { "alias": "commitAction"; "required": false; "isSignal": true; }; "commitModeInput": { "alias": "commitMode"; "required": false; "isSignal": true; }; }, { "activeStepIndex": "activeStepIndexChange"; }, never, never, true, never>;
386
421
  }
@@ -397,7 +432,8 @@ declare class CngxStepperPresenter implements CngxStepperHost {
397
432
  */
398
433
  interface CngxStepGroupHost {
399
434
  register(handle: CngxStepRegistration): void;
400
- unregister(id: string): void;
435
+ /** Instance-guarded like `CngxStepperHost.unregister` - see there. */
436
+ unregister(id: string, handle?: CngxStepRegistration): void;
401
437
  }
402
438
  /**
403
439
  * DI token providing a `CngxStepGroup`'s contract to nested `CngxStep` atoms.
@@ -473,8 +509,7 @@ declare const CNGX_STEP_PANEL_HOST: InjectionToken<CngxStepPanelHost>;
473
509
  * a sibling is inserted) on top of the {@link stepTreeEqual} fields.
474
510
  *
475
511
  * Use only on projections where every step carries a real
476
- * DFS-assigned `flatIndex` and `depth` - for `-1` placeholders, use
477
- * {@link stepNodesEqual}.
512
+ * DFS-assigned `flatIndex` and `depth`.
478
513
  *
479
514
  * @internal Exported from `public-api.ts` so the cngx-stepper and
480
515
  * cngx-mat-stepper organisms share the comparator across the
@@ -539,7 +574,7 @@ declare class CngxStepLabel {
539
574
  * `CngxStepGroup` ({@link CNGX_STEP_GROUP_HOST}) or the root
540
575
  * `CngxStepperPresenter` ({@link CNGX_STEPPER_HOST}).
541
576
  *
542
- * `state` is a `linkedSignal` over `[disabled]`, `[completed]`, and
577
+ * `state` is a pure `computed` over `[disabled]`, `[completed]`, and
543
578
  * the optional `[errorAggregator]`'s `hasError()`.
544
579
  *
545
580
  * @category common/stepper
@@ -578,10 +613,7 @@ declare class CngxStep implements OnInit {
578
613
  protected readonly contentSlot: Signal<CngxStepContent | undefined>;
579
614
  readonly labelTemplate: Signal<CngxStepLabel | undefined>;
580
615
  readonly contentTemplate: Signal<CngxStepContent | undefined>;
581
- /**
582
- * Per-step status derived from inputs + aggregator. `linkedSignal`
583
- * with structural equal - never written via `effect`.
584
- */
616
+ /** Per-step status derived from inputs + aggregator - never written. */
585
617
  readonly state: Signal<CngxStepStatus>;
586
618
  private readonly groupHost;
587
619
  private readonly stepperHost;
@@ -619,6 +651,7 @@ declare class CngxStepGroup implements CngxStepGroupHost, OnInit {
619
651
  private readonly childRegistry;
620
652
  readonly aggregatedStatus: Signal<CngxStepStatus>;
621
653
  private readonly stepperHost;
654
+ private readonly parentGroupHost;
622
655
  private readonly destroyRef;
623
656
  /**
624
657
  * `true` when this group's children are collapsed to the header node:
@@ -637,7 +670,7 @@ declare class CngxStepGroup implements CngxStepGroupHost, OnInit {
637
670
  constructor();
638
671
  ngOnInit(): void;
639
672
  register(handle: CngxStepRegistration): void;
640
- unregister(id: string): void;
673
+ unregister(id: string, handle?: CngxStepRegistration): void;
641
674
  static ɵfac: i0.ɵɵFactoryDeclaration<CngxStepGroup, never>;
642
675
  static ɵdir: i0.ɵɵDirectiveDeclaration<CngxStepGroup, "[cngxStepGroup]", ["cngxStepGroup"], { "id": { "alias": "id"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
643
676
  }
@@ -1084,10 +1117,14 @@ interface CngxStepperTemplates {
1084
1117
  */
1085
1118
  type CngxStepperSkin = 'classic' | 'linear-minimal' | 'stripe-status-rich' | 'path-chevron' | 'pill-segment' | 'chips' | 'breadcrumb';
1086
1119
  /**
1087
- * Mobile auto-collapse target. Under a narrow viewport
1088
- * (`max-width: 480px`), `<cngx-stepper>` falls back to one of the
1089
- * compact variants instead of rendering the full strip. Set to
1090
- * `'off'` to retain the classic strip on every viewport.
1120
+ * Mobile auto-collapse target. Below `30rem` of the stepper's own
1121
+ * container width, `<cngx-stepper>` falls back to one of the compact
1122
+ * variants instead of rendering the full strip. Set to `'off'` to retain
1123
+ * the classic strip at every width.
1124
+ *
1125
+ * The width itself is not configurable - it is a `@container` rule in
1126
+ * `stepper-base.css`, overridable in consumer CSS. This setting picks
1127
+ * *what* the strip collapses into, not *where*.
1091
1128
  *
1092
1129
  * @category common/stepper
1093
1130
  */
@@ -1160,15 +1197,6 @@ interface CngxStepperDensityBreakpoints {
1160
1197
  * @category common/stepper
1161
1198
  */
1162
1199
  type CngxStepperMobileIndicatorPosition = 'top' | 'bottom';
1163
- /**
1164
- * Default media query the mobile auto-collapse policy reacts to. The
1165
- * literal lives on a single exported const so the runtime, the config
1166
- * default, and any JSDoc cross-references stay in lockstep. Consumers
1167
- * override the query via {@link withStepperMobileBreakpoint}.
1168
- *
1169
- * @category common/stepper
1170
- */
1171
- declare const STEPPER_DEFAULT_MOBILE_BREAKPOINT = "(max-width: 480px)";
1172
1200
  /**
1173
1201
  * Default per-step px thresholds for the `density: 'auto'` ladder. The
1174
1202
  * literal lives on a single exported const so the runtime resolver, the
@@ -1236,12 +1264,6 @@ interface CngxStepperConfig {
1236
1264
  */
1237
1265
  readonly connectors?: boolean;
1238
1266
  readonly mobileCollapse?: CngxStepperMobileCollapse;
1239
- /**
1240
- * Media query the mobile auto-collapse policy reacts to. Default
1241
- * {@link STEPPER_DEFAULT_MOBILE_BREAKPOINT}. Tablet consumers can
1242
- * re-aim the trigger via {@link withStepperMobileBreakpoint}.
1243
- */
1244
- readonly mobileBreakpoint?: string;
1245
1267
  /**
1246
1268
  * Where the mobile auto-collapse indicator sits relative to the
1247
1269
  * panel content. Default `'top'`. Override per-instance via the
@@ -1257,8 +1279,10 @@ interface CngxStepperConfig {
1257
1279
  * classic strip and on the Material twin (`<cngx-mat-stepper>`).
1258
1280
  */
1259
1281
  readonly mobileSwipe?: boolean;
1260
- readonly ariaLabels?: CngxStepperAriaLabels;
1261
- readonly fallbackLabels?: CngxStepperFallbackLabels;
1282
+ /** Landmark labels; a `Signal` switches the language at runtime. */
1283
+ readonly ariaLabels?: CngxStepperAriaLabels | Signal<CngxStepperAriaLabels>;
1284
+ /** Role descriptions; a `Signal` switches the language at runtime. */
1285
+ readonly fallbackLabels?: CngxStepperFallbackLabels | Signal<CngxStepperFallbackLabels>;
1262
1286
  readonly templates?: CngxStepperTemplates;
1263
1287
  }
1264
1288
  /**
@@ -1336,24 +1360,16 @@ declare function withStepperSkin(skin: CngxStepperSkin): CngxStepperConfigFeatur
1336
1360
  */
1337
1361
  declare function withStepperConnectors(on: boolean): CngxStepperConfigFeature;
1338
1362
  /**
1339
- * Configure the mobile auto-collapse target for `<cngx-stepper>`. Under
1340
- * a narrow viewport (`max-width: 480px`), the classic strip swaps to
1341
- * the chosen variant - `'text'` (default) renders `<cngx-text-stepper>`,
1342
- * `'dots'` renders `<cngx-dot-stepper>`, `'off'` keeps the classic
1343
- * strip. The Material twin `<cngx-mat-stepper>` ignores this setting.
1363
+ * Configure the mobile auto-collapse target for `<cngx-stepper>`. Below
1364
+ * `30rem` of the stepper's own container width, the classic strip swaps
1365
+ * to the chosen variant - `'text'` (default) renders
1366
+ * `<cngx-text-stepper>`, `'dots'` renders `<cngx-dot-stepper>`, `'off'`
1367
+ * keeps the classic strip. The Material twin `<cngx-mat-stepper>` ignores
1368
+ * this setting.
1344
1369
  *
1345
1370
  * @category common/stepper
1346
1371
  */
1347
1372
  declare function withStepperMobileCollapse(mode: CngxStepperMobileCollapse): CngxStepperConfigFeature;
1348
- /**
1349
- * Override the media query the mobile auto-collapse policy reacts to.
1350
- * Default `'(max-width: 480px)'`. Useful for tablet-tier consumers
1351
- * who want the collapse to engage at 768px or for design systems
1352
- * aligned with `--mat-sys-breakpoint-*` tokens.
1353
- *
1354
- * @category common/stepper
1355
- */
1356
- declare function withStepperMobileBreakpoint(query: string): CngxStepperConfigFeature;
1357
1373
  /**
1358
1374
  * Set the app-wide default position of the mobile auto-collapse
1359
1375
  * indicator relative to panel content. `'top'` keeps the indicator
@@ -1420,17 +1436,20 @@ declare function withStepperDensity(mode: CngxStepperDensity, breakpoints?: Cngx
1420
1436
  /**
1421
1437
  * Merge ARIA labels into the cascade. Keys not provided keep their
1422
1438
  * library defaults; per-instance overrides on the stepper still win.
1439
+ * Pass a `Signal` to switch the language at runtime.
1423
1440
  *
1424
1441
  * @category common/stepper
1425
1442
  */
1426
- declare function withStepperAriaLabels(labels: CngxStepperAriaLabels): CngxStepperConfigFeature;
1443
+ declare function withStepperAriaLabels(labels: CngxStepperAriaLabels | Signal<CngxStepperAriaLabels>): CngxStepperConfigFeature;
1427
1444
  /**
1428
- * Merge text fallback labels (button captions, error strings) into the
1429
- * cascade. Used when a slot directive is not present.
1445
+ * Merge fallback role descriptions (`groupRoleDescription` /
1446
+ * `stepRoleDescription`) into the cascade. These feed the strip's
1447
+ * `aria-roledescription` attributes when the consumer supplies none.
1448
+ * Pass a `Signal` to switch the language at runtime.
1430
1449
  *
1431
1450
  * @category common/stepper
1432
1451
  */
1433
- declare function withStepperFallbackLabels(labels: CngxStepperFallbackLabels): CngxStepperConfigFeature;
1452
+ declare function withStepperFallbackLabels(labels: CngxStepperFallbackLabels | Signal<CngxStepperFallbackLabels>): CngxStepperConfigFeature;
1434
1453
  /**
1435
1454
  * Override the default `*cngxStepIndicator` template app-wide.
1436
1455
  * Per-instance directive still wins; this only moves the cascade
@@ -1639,16 +1658,24 @@ declare class CngxStepperRouterSync implements AfterContentInit {
1639
1658
  constructor();
1640
1659
  /**
1641
1660
  * Seed from the URL before the stepper renders its panels. `CngxStep`
1642
- * registers in its constructor, so the registry is populated by the time
1643
- * this runs, and the host view has not rendered yet - which is what keeps
1644
- * a `panelMode="lazy"` default step from counting its first render as a
1645
- * first activation on a deep link that named another step.
1661
+ * registers in `ngOnInit` (so a bound `[id]` reaches the registry), which
1662
+ * runs before the host's `ngAfterContentInit` - the registry is populated
1663
+ * by the time this runs, and the host view has not rendered yet, which is
1664
+ * what keeps a `panelMode="lazy"` default step from counting its first
1665
+ * render as a first activation on a deep link that named another step.
1646
1666
  *
1647
1667
  * Own router guard: the constructor's early return does not stop
1648
1668
  * lifecycle hooks from running.
1649
1669
  */
1650
1670
  ngAfterContentInit(): void;
1651
1671
  private seedFromUrl;
1672
+ /**
1673
+ * Reflect `id` into the URL. Fragment mode re-serializes the existing
1674
+ * fragment params so foreign state (`#foo=1&step=x`) survives the
1675
+ * write; values are URI-encoded symmetric to {@link parseFragment}.
1676
+ */
1677
+ private writeUrl;
1678
+ private serializeFragment;
1652
1679
  private readUrlValue;
1653
1680
  private parseFragment;
1654
1681
  static ɵfac: i0.ɵɵFactoryDeclaration<CngxStepperRouterSync, never>;
@@ -1656,20 +1683,94 @@ declare class CngxStepperRouterSync implements AfterContentInit {
1656
1683
  }
1657
1684
 
1658
1685
  /**
1659
- * Status-pill labels used by the `stripe-status-rich` skin (and any
1660
- * future skin / variant that surfaces a per-step status pill). Sub-
1661
- * bundle of {@link CngxStepperI18n}; consumers override partial keys
1662
- * via {@link withStepperI18nLabels} - un-overridden keys keep their
1663
- * English defaults.
1686
+ * The status-pill words of the stepper section.
1664
1687
  *
1665
1688
  * @category common/stepper/i18n
1689
+ * @since 0.1.0
1666
1690
  */
1667
- interface CngxStepperStatusLabels {
1691
+ interface CngxStepperStatusLanguage {
1668
1692
  readonly done: string;
1669
1693
  readonly inProgress: string;
1670
1694
  readonly upNext: string;
1671
1695
  readonly errored: string;
1672
1696
  }
1697
+ /**
1698
+ * The stepper section of a {@link CngxLanguagePack}: the copy of
1699
+ * `@cngx/common/stepper` and of the steppers in `@cngx/ui/stepper` and
1700
+ * `@cngx/ui/mat-stepper`. It feeds `CNGX_STEPPER_I18N` and the copy keys of
1701
+ * `CNGX_STEPPER_CONFIG` (`ariaLabels`, `fallbackLabels`). Messages use
1702
+ * `{name}` placeholders; a plural message picks its form from `{count}`.
1703
+ *
1704
+ * @category common/stepper/i18n
1705
+ * @since 0.1.0
1706
+ * @relatedTo CNGX_STEPPER_I18N, CNGX_STEPPER_CONFIG
1707
+ */
1708
+ interface CngxStepperLanguageSection {
1709
+ /** Accessible name of the stepper landmark. */
1710
+ readonly stepperRegion: string;
1711
+ /** Last-tier landmark label and role description, used when the config keys are unset. */
1712
+ readonly stepperLabel: string;
1713
+ /** `aria-roledescription` of the stepper organism. */
1714
+ readonly stepRoleDescription: string;
1715
+ /** Role description of compact step indicators (dot stepper, mobile dots). */
1716
+ readonly stepIndicatorRoleDescription: string;
1717
+ /** Role description of a step group header. */
1718
+ readonly groupRoleDescription: string;
1719
+ /** `{label}`, `{position}`, `{count}`: the accessible name of a step. */
1720
+ readonly selectedStep: CngxMessage;
1721
+ /** `{step}`, `{detail}`: a step name followed by its status or its label. */
1722
+ readonly stepWithDetail: CngxMessage;
1723
+ /** Plural on `{count}`: the number of steps with errors. */
1724
+ readonly stepHasErrors: CngxMessage;
1725
+ readonly previousStep: string;
1726
+ readonly nextStep: string;
1727
+ readonly commitFailedRetry: string;
1728
+ /** Announced while a step commit is in flight. */
1729
+ readonly commitInFlight: string;
1730
+ /** `{origin}`: announced when a failed commit reverts to the origin step. */
1731
+ readonly commitRolledBackTo: CngxMessage;
1732
+ /** `{base}`: the description of a rolled-back step, `{base}` being its name. */
1733
+ readonly stepRolledBack: CngxMessage;
1734
+ readonly statusLabels: CngxStepperStatusLanguage;
1735
+ /** `{current}`, `{count}`: the short progress caption. */
1736
+ readonly textStepperFormat: CngxMessage;
1737
+ /** Plural on `{count}`: a collapsed group's step count for screen readers. */
1738
+ readonly groupSummaryCount: CngxMessage;
1739
+ /** `{completed}`, plural on `{count}`: a collapsed group's progress for screen readers. */
1740
+ readonly groupSummaryProgress: CngxMessage;
1741
+ /** `{count}`: a collapsed group's visible step count. */
1742
+ readonly groupSummaryCountShort: CngxMessage;
1743
+ /** `{completed}`, `{count}`: a collapsed group's visible progress. */
1744
+ readonly groupSummaryProgressShort: CngxMessage;
1745
+ /** `{id}`: the last-resort label of an unlabelled Material step. */
1746
+ readonly stepFallbackLabel: CngxMessage;
1747
+ }
1748
+ /**
1749
+ * The English stepper section: the single source of the stepper's English
1750
+ * copy. `CNGX_STEPPER_I18N` and the `CNGX_STEPPER_CONFIG` labels default to it.
1751
+ *
1752
+ * @category common/stepper/i18n
1753
+ * @since 0.1.0
1754
+ * @relatedTo CNGX_STEPPER_I18N
1755
+ */
1756
+ declare const CNGX_STEPPER_LANGUAGE_EN: CngxStepperLanguageSection;
1757
+ declare module '@cngx/core/i18n' {
1758
+ interface CngxLanguagePack {
1759
+ readonly stepper: CngxStepperLanguageSection;
1760
+ }
1761
+ }
1762
+
1763
+ /**
1764
+ * Status-pill labels used by the `stripe-status-rich` skin (and any
1765
+ * future skin / variant that surfaces a per-step status pill). Sub-
1766
+ * bundle of {@link CngxStepperI18n}; consumers override partial keys
1767
+ * via {@link withStepperI18nLabels} - un-overridden keys keep their
1768
+ * English defaults. The same shape as the section's status words, declared
1769
+ * once as {@link CngxStepperStatusLanguage}.
1770
+ *
1771
+ * @category common/stepper/i18n
1772
+ */
1773
+ type CngxStepperStatusLabels = CngxStepperStatusLanguage;
1673
1774
  /**
1674
1775
  * Stepper i18n surface. Library defaults are English; locales come from
1675
1776
  * consumer overrides via {@link provideStepperI18n}. Sibling of
@@ -1678,6 +1779,14 @@ interface CngxStepperStatusLabels {
1678
1779
  * @category common/stepper/i18n
1679
1780
  */
1680
1781
  interface CngxStepperI18n {
1782
+ /**
1783
+ * Last tier of the landmark `aria-label` and of the organism's
1784
+ * `aria-roledescription`. The label applies only while
1785
+ * `CNGX_STEPPER_CONFIG.ariaLabels.stepperRegion` (default `'Steps'`) is
1786
+ * unset, the role description only while `fallbackLabels.stepRoleDescription`
1787
+ * (default `'stepper'`) is unset. Localise both through
1788
+ * `withStepperAriaLabels(...)` and `withStepperFallbackLabels(...)`.
1789
+ */
1681
1790
  readonly stepperLabel: string;
1682
1791
  /**
1683
1792
  * Landmark `aria-roledescription` for compact step-indicator
@@ -1687,9 +1796,15 @@ interface CngxStepperI18n {
1687
1796
  * @category common/stepper/i18n
1688
1797
  */
1689
1798
  readonly stepIndicatorRoleDescription: string;
1799
+ /** `aria-roledescription` of a step group header. English `step group`. */
1800
+ readonly groupRoleDescription: string;
1690
1801
  readonly selectedStep: (label: string, position: number, count: number) => string;
1691
- readonly stepCompleted: string;
1692
- readonly stepErrored: string;
1802
+ /**
1803
+ * A step name followed by a detail - its status (`Step 2 of 3: Shipping:
1804
+ * Errored`) or its label (`Step 2 of 3: Shipping`). One message, so a
1805
+ * locale owns the joiner and the order.
1806
+ */
1807
+ readonly stepWithDetail: (step: string, detail: string) => string;
1693
1808
  readonly stepHasErrors: (count: number) => string;
1694
1809
  readonly previousStep: string;
1695
1810
  readonly nextStep: string;
@@ -1710,13 +1825,15 @@ interface CngxStepperI18n {
1710
1825
  */
1711
1826
  readonly commitRolledBackTo: (originLabel: string) => string;
1712
1827
  /**
1713
- * Persistent suffix on the per-step `aria-describedby` while
1714
- * `presenter.lastFailedIndex()` matches the step. Distinct from
1715
- * {@link commitRolledBackTo} (transient live-region phrase) - this
1716
- * suffix is reachable when AT users navigate back to the rejected
1717
- * step after the announcement has faded. Pillar 2.
1828
+ * Per-step `aria-describedby` text while `presenter.lastFailedIndex()`
1829
+ * matches the step. Receives the step's base description (e.g.
1830
+ * `Step 2 of 3: Shipping`) and owns the whole sentence, so a locale can
1831
+ * place the rolled-back note before, after or inside it. Distinct from
1832
+ * {@link commitRolledBackTo} (transient live-region phrase) - this text
1833
+ * is reachable when AT users navigate back to the rejected step after
1834
+ * the announcement has faded. Pillar 2.
1718
1835
  */
1719
- readonly stepRolledBackSuffix: string;
1836
+ readonly stepRolledBack: (base: string) => string;
1720
1837
  /**
1721
1838
  * Per-state pill labels surfaced by the `stripe-status-rich` skin
1722
1839
  * (and any future skin / variant that paints a state pill). English
@@ -1733,6 +1850,21 @@ interface CngxStepperI18n {
1733
1850
  * @category common/stepper/i18n
1734
1851
  */
1735
1852
  readonly textStepperFormat: (current: number, total: number) => string;
1853
+ /** Collapsed-group SR phrase for `groupCollapseSummary: 'count'`. */
1854
+ readonly groupSummaryCount: (total: number) => string;
1855
+ /** Collapsed-group SR phrase for `groupCollapseSummary: 'progress'`. */
1856
+ readonly groupSummaryProgress: (completed: number, total: number) => string;
1857
+ /** Visible collapsed-group badge for `groupCollapseSummary: 'count'`. */
1858
+ readonly groupSummaryCountShort: (total: number) => string;
1859
+ /** Visible collapsed-group badge for `groupCollapseSummary: 'progress'`. */
1860
+ readonly groupSummaryProgressShort: (completed: number, total: number) => string;
1861
+ /**
1862
+ * Last-resort label of a Material `<mat-step>` instrumented by
1863
+ * `[cngxMatStepper]` when it has no `label`, `ariaLabel` or static
1864
+ * `matStepLabel` text. Receives the cngx handle id. English default
1865
+ * `Step <id>`.
1866
+ */
1867
+ readonly stepFallbackLabel: (id: string) => string;
1736
1868
  }
1737
1869
  /**
1738
1870
  * Partial-override shape for {@link withStepperI18nLabels}. Behaves as
@@ -1746,15 +1878,19 @@ type CngxStepperI18nOverrides = Omit<Partial<CngxStepperI18n>, 'statusLabels'> &
1746
1878
  readonly statusLabels?: Partial<CngxStepperStatusLabels>;
1747
1879
  };
1748
1880
  /**
1749
- * DI token for the resolved stepper i18n bundle. `providedIn: 'root'`
1750
- * with English defaults.
1881
+ * DI token for the resolved stepper i18n bundle, as a `Signal` so a
1882
+ * runtime language switch re-renders every label it feeds.
1883
+ * `providedIn: 'root'`: the stepper section of the active language pack over
1884
+ * the English defaults, formatted for the app locale. Provide it through
1885
+ * {@link provideStepperI18n}; a `{ provide, useValue }` entry must supply a
1886
+ * `Signal<CngxStepperI18n>`.
1751
1887
  *
1752
1888
  * @category common/stepper/i18n
1753
1889
  * @wcag AA
1754
1890
  * @github https://github.com/cngxjs/cngx/blob/main/projects/common/stepper/i18n/stepper-i18n.ts
1755
1891
  * @since 0.1.0
1756
1892
  */
1757
- declare const CNGX_STEPPER_I18N: InjectionToken<CngxStepperI18n>;
1893
+ declare const CNGX_STEPPER_I18N: InjectionToken<Signal<CngxStepperI18n>>;
1758
1894
  /**
1759
1895
  * Feature shape consumed by {@link provideStepperI18n} and {@link provideCngxStepper}.
1760
1896
  * Hidden `_target: 'i18n'` discriminator routes through the family aggregator.
@@ -1762,22 +1898,23 @@ declare const CNGX_STEPPER_I18N: InjectionToken<CngxStepperI18n>;
1762
1898
  *
1763
1899
  * @category common/stepper/i18n
1764
1900
  */
1765
- type CngxStepperI18nFeature = ((bundle: CngxStepperI18n) => CngxStepperI18n) & {
1901
+ type CngxStepperI18nFeature = ((bundle: Signal<CngxStepperI18n>) => Signal<CngxStepperI18n>) & {
1766
1902
  readonly _target: 'i18n';
1767
1903
  };
1768
1904
  /**
1769
1905
  * Override stepper i18n labels. Partial override - unset keys keep
1770
- * the English default. {@link CngxStepperStatusLabels} is merged
1906
+ * the language pack's copy, or the English default. {@link CngxStepperStatusLabels} is merged
1771
1907
  * key-by-key so consumers can override one pill label without
1772
- * restating the rest. Sibling of `withStepperAriaLabels` /
1773
- * `withStepperFallbackLabels`.
1908
+ * restating the rest. Pass a `Signal` to switch the language at runtime.
1909
+ * Sibling of `withStepperAriaLabels` / `withStepperFallbackLabels`.
1774
1910
  *
1775
1911
  * @category common/stepper/i18n
1776
1912
  */
1777
- declare function withStepperI18nLabels(overrides: CngxStepperI18nOverrides): CngxStepperI18nFeature;
1913
+ declare function withStepperI18nLabels(overrides: CngxStepperI18nOverrides | Signal<CngxStepperI18nOverrides>): CngxStepperI18nFeature;
1778
1914
  /**
1779
1915
  * Provider for the stepper i18n bundle. Compose `withStepperI18nLabels(...)`
1780
- * (plus any future i18n `with*`) - unset keys fall back to English.
1916
+ * (plus any future i18n `with*`) - unset keys fall back to the language
1917
+ * pack, then English. The features apply on top of the active pack.
1781
1918
  *
1782
1919
  * ```ts
1783
1920
  * bootstrapApplication(AppComponent, {
@@ -1793,11 +1930,13 @@ declare function withStepperI18nLabels(overrides: CngxStepperI18nOverrides): Cng
1793
1930
  */
1794
1931
  declare function provideStepperI18n(...features: readonly CngxStepperI18nFeature[]): Provider;
1795
1932
  /**
1796
- * Inject the resolved stepper i18n bundle in an injection context.
1933
+ * Inject the resolved stepper i18n bundle in an injection context. Read it
1934
+ * inside a `computed()`, template or handler so a language switch reaches
1935
+ * the label.
1797
1936
  *
1798
1937
  * @category common/stepper/i18n
1799
1938
  */
1800
- declare function injectStepperI18n(): CngxStepperI18n;
1939
+ declare function injectStepperI18n(): Signal<CngxStepperI18n>;
1801
1940
 
1802
1941
  /**
1803
1942
  * Resolve the status-pill label for a step node against the resolved
@@ -1818,26 +1957,40 @@ declare function injectStepperI18n(): CngxStepperI18n;
1818
1957
  declare function resolveStepperStatusLabel(node: CngxStepNode, i18n: CngxStepperI18n, isActive: boolean): string;
1819
1958
 
1820
1959
  /**
1821
- * Returns a reactive `Signal<boolean>` that reflects whether the host
1822
- * window matches a CSS media query (e.g. `(max-width: 480px)`). Used by
1823
- * `<cngx-stepper>` to drive its mobile auto-collapse template branch.
1960
+ * Reads the stepper's collapse flag off its own container.
1961
+ *
1962
+ * The threshold is a `@container` rule in `stepper-base.css` writing
1963
+ * `--cngx-stepper-collapse` onto `.cngx-stepper::after`. It lands on the
1964
+ * pseudo-element because a container query cannot style its own container,
1965
+ * and the query container for a pseudo-element is selected from its
1966
+ * originating element's inclusive ancestors. Nothing here parses a width, so
1967
+ * a consumer re-aims the collapse with a plain CSS rule.
1824
1968
  *
1825
- * In SSR / non-DOM environments the signal stays `false` and the
1826
- * listener is never wired. Thin wrapper over `createMediaQuerySignal`
1827
- * from `@cngx/core/utils`, bound to `globalThis`.
1969
+ * Requires an injection context - it observes through `injectContainerSize`,
1970
+ * so the observer is scoped to the caller's `DestroyRef`. A field initialiser
1971
+ * on the stepper component is one; a bare call from a lifecycle hook is not.
1828
1972
  *
1973
+ * @param host The `<cngx-stepper>` host element, which is its own container.
1829
1974
  * @category common/stepper
1975
+ * @relatedTo createStepperDisplayMode, injectContainerSize
1830
1976
  */
1831
- declare function createMobileViewportSignal(mediaQuery: string, destroyRef: DestroyRef): Signal<boolean>;
1977
+ declare function injectStepperCollapse(host: Element): Signal<boolean>;
1832
1978
  /**
1833
- * Resolves the active stepper display mode by combining a viewport
1834
- * media-query with the configured `mobileCollapse` policy.
1835
- * `'classic'` keeps the full strip; `'text'` / `'dots'` swap to the
1836
- * matching compact variant.
1979
+ * Resolves the active stepper display mode by combining the collapse *signal*
1980
+ * - whether the stepper's own container is narrow - with the configured
1981
+ * `mobileCollapse` policy. `'classic'` keeps the full strip; `'text'` /
1982
+ * `'dots'` swap to the matching compact variant, `'off'` stays classic at any
1983
+ * width.
1984
+ *
1985
+ * The factory takes no DOM API and holds no threshold: *where* the collapse
1986
+ * happens is a `@container` rule in the stepper stylesheet, *what* it collapses
1987
+ * into is this policy. See `core-concepts/responsive-by-default.md`.
1837
1988
  *
1989
+ * @param collapsed `true` while the container sits below the collapse rung.
1990
+ * @param mobileCollapse The configured collapse policy, read lazily.
1838
1991
  * @category common/stepper
1839
1992
  */
1840
- declare function createStepperDisplayMode(mediaQuery: string, mobileCollapse: () => CngxStepperMobileCollapse | undefined, destroyRef: DestroyRef): Signal<'classic' | 'text' | 'dots'>;
1993
+ declare function createStepperDisplayMode(collapsed: Signal<boolean>, mobileCollapse: () => CngxStepperMobileCollapse | undefined): Signal<'classic' | 'text' | 'dots'>;
1841
1994
 
1842
1995
  /**
1843
1996
  * Resolved density rung for the classic `<cngx-stepper>` strip.
@@ -1878,9 +2031,9 @@ interface CngxStripDensityOptions {
1878
2031
  /**
1879
2032
  * Resolves the classic strip's density rung from its own container
1880
2033
  * width against the step count and two per-step px thresholds. Pure
1881
- * `create*` factory, sibling to `createStepperDisplayMode` - it owns a
1882
- * `ResizeObserver` the way the display-mode factory owns a
1883
- * `matchMedia` listener, and returns a single derived `Signal`.
2034
+ * `create*` factory, sibling to `createStepperDisplayMode` - both derive
2035
+ * a rung from the space the stepper was given and return a single
2036
+ * `Signal`; this one measures, the other reads what CSS resolved.
1884
2037
  *
1885
2038
  * `'comfortable'` density short-circuits to `'full'` (no measurement
1886
2039
  * dependency). Before the first measurement (`width === 0`) and for an
@@ -1919,13 +2072,15 @@ interface CngxStepperGroupSummaryOptions {
1919
2072
  readonly summaryMode: () => CngxStepperGroupSummary | undefined;
1920
2073
  /** Whether a given group node is currently collapsed. */
1921
2074
  readonly isCollapsed: (node: CngxStepNode) => boolean;
2075
+ /** Resolved i18n bundle Signal for the SR phrases. */
2076
+ readonly i18n: Signal<Pick<CngxStepperI18n, 'groupSummaryCount' | 'groupSummaryProgress' | 'groupSummaryCountShort' | 'groupSummaryProgressShort'>>;
1922
2077
  }
1923
2078
  /**
1924
2079
  * Builds the collapsed-group summary view. Level-2 helper so the
1925
2080
  * organism stays a thin renderer. `status` mode defers its SR phrasing
1926
2081
  * to the group's existing status-phrase span, so {@link srText} returns
1927
- * `null` there. English defaults (locale via the i18n cascade is a
1928
- * follow-up).
2082
+ * `null` there. SR phrases resolve through the `CngxStepperI18n` bundle
2083
+ * when passed; English defaults otherwise.
1929
2084
  *
1930
2085
  * @category common/stepper
1931
2086
  */
@@ -2032,6 +2187,29 @@ interface CngxStepperHostAttrs {
2032
2187
  * @internal
2033
2188
  */
2034
2189
  declare function createStepperHostAttrs(inputs: CngxStepperHostAttrsInputs): CngxStepperHostAttrs;
2190
+ /**
2191
+ * Input bundle for {@link createStepperAccname}: the two per-instance
2192
+ * accname inputs plus the resolved config and the i18n bundle Signal.
2193
+ *
2194
+ * @internal
2195
+ */
2196
+ interface CngxStepperAccnameInputs {
2197
+ readonly ariaLabel: Signal<string | undefined>;
2198
+ readonly ariaLabelledBy: Signal<string | undefined>;
2199
+ readonly config: CngxStepperConfig;
2200
+ readonly i18n: Signal<CngxStepperI18n>;
2201
+ }
2202
+ /**
2203
+ * Shared `aria-label` cascade for every stepper organism host
2204
+ * (`<cngx-stepper>` and the compact variants): a bound
2205
+ * `aria-labelledby` trumps and nulls the label out; otherwise the
2206
+ * per-instance input wins over `ariaLabels.stepperRegion` wins over
2207
+ * `i18n.stepperLabel`. One source so the variants cannot drift from
2208
+ * the parent's naming behaviour.
2209
+ *
2210
+ * @internal
2211
+ */
2212
+ declare function createStepperAccname(inputs: CngxStepperAccnameInputs): Signal<string | null>;
2035
2213
 
2036
2214
  /**
2037
2215
  * Options for {@link createStepperStripKeyboardNav}.
@@ -2048,8 +2226,6 @@ interface CngxStepperStripKeyboardNavOptions {
2048
2226
  * under `rtl` (APG); the vertical strip and Home/End stay invariant.
2049
2227
  */
2050
2228
  readonly direction: Signal<CngxDirection>;
2051
- /** Returns the current flat-step count so `End` lands on the last step. */
2052
- readonly flatStepCount: () => number;
2053
2229
  /**
2054
2230
  * Maps a CngxStepNode id to its DOM button id (e.g. `${id}-header`).
2055
2231
  * The strip selects by stable DOM id rather than waiting for the
@@ -2175,7 +2351,10 @@ declare function createStepperStateView(inputs: {
2175
2351
  * (the classic mobile-collapse summary) are a guaranteed no-op.
2176
2352
  *
2177
2353
  * Pure helper - reads signals at call time, intended to be wrapped in the
2178
- * caller's `computed()`.
2354
+ * caller's `computed()`. The phrase feeds live regions, so the step label
2355
+ * is read untracked: a label that follows a language switch must not
2356
+ * re-announce the line. Pass the i18n bundle as an untracked snapshot for
2357
+ * the same reason.
2179
2358
  *
2180
2359
  * @category common/stepper
2181
2360
  * @since 0.1.0
@@ -2192,8 +2371,14 @@ declare function resolveStepperErrorSummary(view: Pick<CngxStepperStateView, 'er
2192
2371
  interface CngxStepperSlotContextBuildersInputs {
2193
2372
  readonly presenter: CngxStepperHost;
2194
2373
  readonly stepsOnly: Signal<readonly CngxStepNode[]>;
2195
- /** i18n bundle - supplies the `errored` status label as the message fallback. */
2196
- readonly i18n: CngxStepperI18n;
2374
+ /**
2375
+ * Whether a group node is currently collapsed (focus-driven collapse
2376
+ * policy). Optional so header contexts of collapse-free steppers keep
2377
+ * reporting `expanded: true` without the caller wiring a predicate.
2378
+ */
2379
+ readonly isGroupCollapsed?: (node: CngxStepNode) => boolean;
2380
+ /** i18n bundle Signal - supplies the `errored` status label as the message fallback. */
2381
+ readonly i18n: Signal<CngxStepperI18n>;
2197
2382
  }
2198
2383
  /**
2199
2384
  * Per-step status / activity / rejection / labelling derivations shared by
@@ -2231,14 +2416,14 @@ declare function createStepperSlotContextBuilders(inputs: CngxStepperSlotContext
2231
2416
  /**
2232
2417
  * Input bundle for {@link createStepperAnnouncementBuilders}. The presenter
2233
2418
  * surface (commit transition + failed-index signals), the step-only flat
2234
- * projection, and the resolved i18n strings.
2419
+ * projection, and the resolved i18n bundle Signal.
2235
2420
  *
2236
2421
  * @internal
2237
2422
  */
2238
2423
  interface CngxStepperAnnouncementBuildersInputs {
2239
2424
  readonly presenter: CngxStepperHost;
2240
2425
  readonly stepsOnly: Signal<readonly CngxStepNode[]>;
2241
- readonly i18n: CngxStepperI18n;
2426
+ readonly i18n: Signal<CngxStepperI18n>;
2242
2427
  }
2243
2428
  /**
2244
2429
  * Reactive SR-announcement surface for the stepper organism: the
@@ -2260,16 +2445,23 @@ interface CngxStepperAnnouncementBuilders {
2260
2445
  readonly liveAnnouncement: Signal<string>;
2261
2446
  /**
2262
2447
  * SR descriptor phrase. Aggregator-announced or "Step N of M: <label>";
2263
- * appends `stepRolledBackSuffix` on the rejected row.
2448
+ * routes the rejected row through `stepRolledBack(base)`.
2264
2449
  */
2265
2450
  readonly statusPhrase: (node: CngxStepNode) => string;
2451
+ /**
2452
+ * Step-header descriptor: `statusPhrase` plus the done / errored status
2453
+ * the stepper skins draw as a CSS glyph, joined through `stepWithDetail`.
2454
+ * The glyphs carry `/ ''` alt text, so this text is where their meaning
2455
+ * reaches a screen reader.
2456
+ */
2457
+ readonly headerStatusPhrase: (node: CngxStepNode) => string;
2266
2458
  /** Group descriptor - rolls up children's aggregated status. */
2267
2459
  readonly groupStatusPhrase: (node: CngxStepNode) => string;
2268
2460
  /** Stable descriptor-span id for a node (`<node-id>-desc`). */
2269
2461
  readonly descriptorId: (node: CngxStepNode) => string;
2270
2462
  /**
2271
2463
  * `aria-describedby` value for a node: `descriptorId(node)` while the
2272
- * node's phrase (`statusPhrase` for steps, `groupStatusPhrase` for
2464
+ * node's phrase (`headerStatusPhrase` for steps, `groupStatusPhrase` for
2273
2465
  * groups) is non-empty, else `null`. The descriptor span stays in the
2274
2466
  * DOM; only the reference is gated - accname 1.2 §2A traverses a
2275
2467
  * directly-referenced node even when it is empty or hidden.
@@ -2284,6 +2476,45 @@ interface CngxStepperAnnouncementBuilders {
2284
2476
  * @internal
2285
2477
  */
2286
2478
  declare function createStepperAnnouncementBuilders(inputs: CngxStepperAnnouncementBuildersInputs): CngxStepperAnnouncementBuilders;
2479
+ /**
2480
+ * Input bundle for {@link createStepperPanelRefs}: the resolved display
2481
+ * mode, the strip projection that decides which headers exist, and the
2482
+ * organism's id/describedby schemes.
2483
+ *
2484
+ * @internal
2485
+ */
2486
+ interface CngxStepperPanelRefsInputs {
2487
+ readonly displayMode: Signal<'classic' | 'text' | 'dots'>;
2488
+ readonly visibleStripNodes: Signal<readonly CngxStepNode[]>;
2489
+ readonly headerIdFor: (node: CngxStepNode) => string;
2490
+ readonly describedByFor: (node: CngxStepNode) => string | null;
2491
+ }
2492
+ /**
2493
+ * Per-mode panel naming surface for `<cngx-stepper>`'s region panels.
2494
+ *
2495
+ * @internal
2496
+ */
2497
+ interface CngxStepperPanelRefs {
2498
+ /** Header id when a header element is rendered for the node, else `null`. */
2499
+ readonly labelledBy: (node: CngxStepNode) => string | null;
2500
+ /** Self-naming fallback whenever {@link labelledBy} emits no id. */
2501
+ readonly ariaLabel: (node: CngxStepNode) => string | null;
2502
+ /** Gated describedby - suppressed when the descriptor span is header-hosted and the header is not rendered. */
2503
+ readonly describedBy: (node: CngxStepNode) => string | null;
2504
+ }
2505
+ /**
2506
+ * Build the mode-aware panel ref surface. The dots branch always
2507
+ * renders one dot per step; the classic strip only renders headers the
2508
+ * group-collapse policy exposes; the text branch has no header element
2509
+ * at all. A panel must never reference an id that is not in the DOM -
2510
+ * a dangling IDREF names the region as empty - so header-less panels
2511
+ * self-name via `aria-label` and drop the describedby reference (the
2512
+ * classic descriptor spans live inside the strip headers; the
2513
+ * collapsed branches mount theirs inside the panel).
2514
+ *
2515
+ * @internal
2516
+ */
2517
+ declare function createStepperPanelRefs(inputs: CngxStepperPanelRefsInputs): CngxStepperPanelRefs;
2287
2518
 
2288
2519
  /**
2289
2520
  * Routes a `CngxSwipe` gesture into the stepper presenter so the
@@ -2296,10 +2527,10 @@ declare function createStepperAnnouncementBuilders(inputs: CngxStepperAnnounceme
2296
2527
  * `CNGX_STEPPER_CONFIG.mobileSwipe` -> library default `true`.
2297
2528
  *
2298
2529
  * Direction routing is asymmetric, matching the presenter's existing
2299
- * navigation surface: `left` -> `selectNext()` -> `select()` (linear
2300
- * gate + commit window apply identically to a click); `right` ->
2301
- * `selectPrevious()` (ungated direct back-move, same path as the
2302
- * existing strip back-nav).
2530
+ * navigation surface: the forward swipe (`left` under `ltr`, `right`
2531
+ * under `rtl`) -> `selectNext()` -> `select()` (linear gate + commit
2532
+ * window apply identically to a click); the back swipe ->
2533
+ * `selectPrevious()`, gated on `busy()` like the strip back-arrow.
2303
2534
  *
2304
2535
  * @category common/stepper
2305
2536
  * @docsKind primary
@@ -2315,12 +2546,16 @@ declare class CngxStepperSwipeNav {
2315
2546
  readonly mobileSwipe: i0.InputSignal<boolean | undefined>;
2316
2547
  private readonly host;
2317
2548
  private readonly config;
2549
+ private readonly direction;
2318
2550
  /** Resolved enabled flag (Input -> config -> default(true)). Boolean output, no `equal` fn required. */
2319
2551
  readonly swipeEnabled: i0.Signal<boolean>;
2320
2552
  /**
2321
- * Route a swipe direction into the presenter. `left` and `right`
2322
- * map onto `selectNext` and `selectPrevious`; vertical directions
2323
- * are ignored.
2553
+ * Route a swipe direction into the presenter. The inline mapping
2554
+ * resolves against the document direction like the keyboard path:
2555
+ * under `ltr` a left swipe advances; under `rtl` the roles flip.
2556
+ * Vertical directions are ignored. The back path waits while a
2557
+ * commit is in flight - a stray gesture must not supersede it (the
2558
+ * programmatic `selectPrevious()` cancels deliberately).
2324
2559
  */
2325
2560
  handleSwipe(direction: SwipeDirection): void;
2326
2561
  static ɵfac: i0.ɵɵFactoryDeclaration<CngxStepperSwipeNav, never>;
@@ -2374,7 +2609,11 @@ interface CngxStepperCountHost {
2374
2609
  * <example-url>http://localhost:4200/#/ui/stepper/stepper-count/multi-instance-format-overrides</example-url>
2375
2610
  */
2376
2611
  declare class CngxStepperCount {
2377
- /** When `true`, wraps the rendered string in an `aria-live="polite"` span. */
2612
+ /**
2613
+ * When `true`, wraps the rendered string in an `aria-live="polite"` span.
2614
+ * Set it once per instance: toggling it swaps the span, and the region
2615
+ * content present at that moment is not announced.
2616
+ */
2378
2617
  readonly live: i0.InputSignal<boolean>;
2379
2618
  /**
2380
2619
  * Per-instance format override. Receives `(current, total)` where
@@ -2397,8 +2636,15 @@ declare class CngxStepperCount {
2397
2636
  private readonly injectedHost;
2398
2637
  private readonly i18n;
2399
2638
  private readonly resolvedHost;
2639
+ /** 1-based active position and step total, or `null` while there is nothing to count. */
2640
+ private readonly position;
2400
2641
  /** Resolved caption - reactive on activeStepIndex / stepsOnly / format / i18n. */
2401
2642
  protected readonly label: Signal<string>;
2643
+ /**
2644
+ * {@link label} for the live span: the bundle and a consumer `format`
2645
+ * (which may itself be language-dependent) are read untracked.
2646
+ */
2647
+ protected readonly liveLabel: Signal<string>;
2402
2648
  static ɵfac: i0.ɵɵFactoryDeclaration<CngxStepperCount, never>;
2403
2649
  static ɵcmp: i0.ɵɵComponentDeclaration<CngxStepperCount, "cngx-stepper-count", never, { "live": { "alias": "live"; "required": false; "isSignal": true; }; "format": { "alias": "format"; "required": false; "isSignal": true; }; "host": { "alias": "host"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
2404
2650
  }
@@ -2441,6 +2687,8 @@ declare class CngxStepperPrevious {
2441
2687
  private readonly injectedHost;
2442
2688
  private readonly resolvedHost;
2443
2689
  private readonly coPlacedAsyncClick;
2690
+ private readonly elementRef;
2691
+ private readonly i18n;
2444
2692
  constructor();
2445
2693
  /** `true` when retreat is unavailable: no earlier step or commit busy. */
2446
2694
  protected readonly disabled: Signal<boolean>;
@@ -2492,6 +2740,8 @@ declare class CngxStepperNext {
2492
2740
  private readonly injectedHost;
2493
2741
  private readonly resolvedHost;
2494
2742
  private readonly coPlacedAsyncClick;
2743
+ private readonly elementRef;
2744
+ private readonly i18n;
2495
2745
  /** `true` when advancing is unavailable: no enabled next step or commit busy. */
2496
2746
  protected readonly disabled: Signal<boolean>;
2497
2747
  constructor();
@@ -2687,5 +2937,5 @@ declare function provideCngxStepper(...features: readonly CngxStepperFeature[]):
2687
2937
  */
2688
2938
  declare function provideCngxStepperAt(...features: readonly CngxStepperFeature[]): Provider[];
2689
2939
 
2690
- export { CNGX_STEPPER_COMMIT_HANDLER_FACTORY, CNGX_STEPPER_CONFIG, CNGX_STEPPER_GLYPHS, CNGX_STEPPER_HOST, CNGX_STEPPER_I18N, CNGX_STEP_GROUP_HOST, CNGX_STEP_PANEL_HOST, CngxDotStepperDot, CngxStep, CngxStepBadge, CngxStepBusySpinner, CngxStepContent, CngxStepError, CngxStepGroup, CngxStepGroupHeader, CngxStepIndicator, CngxStepLabel, CngxStepRejection, CngxStepperComplete, CngxStepperCount, CngxStepperEmpty, CngxStepperNext, CngxStepperPresenter, CngxStepperPrevious, CngxStepperRouterSync, CngxStepperSwipeNav, STEPPER_DEFAULT_DENSITY_BREAKPOINTS, STEPPER_DEFAULT_MOBILE_BREAKPOINT, createMobileViewportSignal, createStepperAnnouncementBuilders, createStepperCommitHandler, createStepperDisplayMode, createStepperGroupNavigation, createStepperGroupSummary, createStepperHostAttrs, createStepperHostProxy, createStepperSlotContextBuilders, createStepperStateView, createStepperStripKeyboardNav, createStepperTemplateBindings, createStripDensity, flatStepsEqual, injectStepperConfig, injectStepperI18n, provideCngxStepper, provideCngxStepperAt, provideStepperConfig, provideStepperConfigAt, provideStepperI18n, resolveStepperErrorSummary, resolveStepperStatusLabel, withDotStepperDotTemplate, withStepBadgeTemplate, withStepBusySpinnerTemplate, withStepErrorTemplate, withStepGroupHeaderTemplate, withStepIndicatorTemplate, withStepRejectionTemplate, withStepperAriaLabels, withStepperCommitMode, withStepperConnectors, withStepperDefaultOrientation, withStepperDensity, withStepperEmptyTemplate, withStepperFallbackLabels, withStepperGroupCollapse, withStepperGroupCollapseSummary, withStepperHeaderNavigation, withStepperI18nLabels, withStepperLinear, withStepperMobileBreakpoint, withStepperMobileCollapse, withStepperMobileIndicatorPosition, withStepperMobileSwipe, withStepperRouterSync, withStepperSkin };
2691
- export type { CngxDotStepperDotContext, CngxStepBadgeContext, CngxStepBusySpinnerContext, CngxStepContentContext, CngxStepErrorContext, CngxStepGroupHeaderContext, CngxStepGroupHost, CngxStepIndicatorContext, CngxStepLabelContext, CngxStepNode, CngxStepPanelHost, CngxStepRegistration, CngxStepRejectionContext, CngxStepStatus, CngxStepperAnnouncementBuilders, CngxStepperAnnouncementBuildersInputs, CngxStepperAriaLabels, CngxStepperCommitAction, CngxStepperCommitHandler, CngxStepperCommitHandlerFactory, CngxStepperCommitHandlerOptions, CngxStepperConfig, CngxStepperConfigFeature, CngxStepperCountHost, CngxStepperDensity, CngxStepperDensityBreakpoints, CngxStepperFallbackLabels, CngxStepperFeature, CngxStepperGroupCollapse, CngxStepperGroupNavigationOptions, CngxStepperGroupNavigationView, CngxStepperGroupSummary, CngxStepperGroupSummaryOptions, CngxStepperGroupSummaryView, CngxStepperHeaderNavigation, CngxStepperHost, CngxStepperHostAttrs, CngxStepperHostAttrsInputs, CngxStepperI18n, CngxStepperI18nFeature, CngxStepperI18nOverrides, CngxStepperMobileCollapse, CngxStepperMobileIndicatorPosition, CngxStepperSkin, CngxStepperSlotContextBuilders, CngxStepperSlotContextBuildersInputs, CngxStepperStateView, CngxStepperStatusLabels, CngxStepperStripKeyboardNavOptions, CngxStepperTemplateBindings, CngxStepperTemplateBindingsOptions, CngxStepperTemplates, CngxStripDensity, CngxStripDensityOptions };
2940
+ export { CNGX_STEPPER_COMMIT_HANDLER_FACTORY, CNGX_STEPPER_CONFIG, CNGX_STEPPER_GLYPHS, CNGX_STEPPER_HOST, CNGX_STEPPER_I18N, CNGX_STEPPER_LANGUAGE_EN, CNGX_STEP_GROUP_HOST, CNGX_STEP_PANEL_HOST, CngxDotStepperDot, CngxStep, CngxStepBadge, CngxStepBusySpinner, CngxStepContent, CngxStepError, CngxStepGroup, CngxStepGroupHeader, CngxStepIndicator, CngxStepLabel, CngxStepRejection, CngxStepperComplete, CngxStepperCount, CngxStepperEmpty, CngxStepperNext, CngxStepperPresenter, CngxStepperPrevious, CngxStepperRouterSync, CngxStepperSwipeNav, STEPPER_DEFAULT_DENSITY_BREAKPOINTS, createStepperAccname, createStepperAnnouncementBuilders, createStepperCommitHandler, createStepperDisplayMode, createStepperGroupNavigation, createStepperGroupSummary, createStepperHostAttrs, createStepperHostProxy, createStepperPanelRefs, createStepperSlotContextBuilders, createStepperStateView, createStepperStripKeyboardNav, createStepperTemplateBindings, createStripDensity, flatStepsEqual, injectStepperCollapse, injectStepperConfig, injectStepperI18n, provideCngxStepper, provideCngxStepperAt, provideStepperConfig, provideStepperConfigAt, provideStepperI18n, resolveStepperErrorSummary, resolveStepperStatusLabel, withDotStepperDotTemplate, withStepBadgeTemplate, withStepBusySpinnerTemplate, withStepErrorTemplate, withStepGroupHeaderTemplate, withStepIndicatorTemplate, withStepRejectionTemplate, withStepperAriaLabels, withStepperCommitMode, withStepperConnectors, withStepperDefaultOrientation, withStepperDensity, withStepperEmptyTemplate, withStepperFallbackLabels, withStepperGroupCollapse, withStepperGroupCollapseSummary, withStepperHeaderNavigation, withStepperI18nLabels, withStepperLinear, withStepperMobileCollapse, withStepperMobileIndicatorPosition, withStepperMobileSwipe, withStepperRouterSync, withStepperSkin };
2941
+ export type { CngxDotStepperDotContext, CngxStepBadgeContext, CngxStepBusySpinnerContext, CngxStepContentContext, CngxStepErrorContext, CngxStepGroupHeaderContext, CngxStepGroupHost, CngxStepIndicatorContext, CngxStepLabelContext, CngxStepNode, CngxStepPanelHost, CngxStepRegistration, CngxStepRejectionContext, CngxStepStatus, CngxStepperAccnameInputs, CngxStepperAnnouncementBuilders, CngxStepperAnnouncementBuildersInputs, CngxStepperAriaLabels, CngxStepperCommitAction, CngxStepperCommitHandler, CngxStepperCommitHandlerFactory, CngxStepperCommitHandlerOptions, CngxStepperConfig, CngxStepperConfigFeature, CngxStepperCountHost, CngxStepperDensity, CngxStepperDensityBreakpoints, CngxStepperFallbackLabels, CngxStepperFeature, CngxStepperGroupCollapse, CngxStepperGroupNavigationOptions, CngxStepperGroupNavigationView, CngxStepperGroupSummary, CngxStepperGroupSummaryOptions, CngxStepperGroupSummaryView, CngxStepperHeaderNavigation, CngxStepperHost, CngxStepperHostAttrs, CngxStepperHostAttrsInputs, CngxStepperI18n, CngxStepperI18nFeature, CngxStepperI18nOverrides, CngxStepperLanguageSection, CngxStepperMobileCollapse, CngxStepperMobileIndicatorPosition, CngxStepperPanelRefs, CngxStepperPanelRefsInputs, CngxStepperSkin, CngxStepperSlotContextBuilders, CngxStepperSlotContextBuildersInputs, CngxStepperStateView, CngxStepperStatusLabels, CngxStepperStatusLanguage, CngxStepperStripKeyboardNavOptions, CngxStepperTemplateBindings, CngxStepperTemplateBindingsOptions, CngxStepperTemplates, CngxStripDensity, CngxStripDensityOptions };