@uni-design-system/uni-angular 10.2.1 → 10.4.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@uni-design-system/uni-angular",
3
- "version": "10.2.1",
3
+ "version": "10.4.0",
4
4
  "license": "MIT",
5
5
  "repository": {
6
6
  "type": "git",
@@ -22,7 +22,7 @@
22
22
  "@angular/core": "^21.2.0",
23
23
  "@angular/forms": "^21.2.0",
24
24
  "@emotion/css": "^11.0.0",
25
- "@uni-design-system/uni-core": "^10.2.1"
25
+ "@uni-design-system/uni-core": "^10.4.0"
26
26
  },
27
27
  "module": "fesm2022/uni-design-system-uni-angular.mjs",
28
28
  "typings": "types/uni-design-system-uni-angular.d.ts",
@@ -875,6 +875,16 @@ var BaseMotion = {
875
875
  easing: "ease"
876
876
  }
877
877
  };
878
+ /**
879
+ * The one wash every modal surface lays over the page it covers. Dialog and
880
+ * drawer both point at `scrim` by name, so a theme redresses them together —
881
+ * before this they owned a `backdrop` blob each and had drifted apart, the
882
+ * dialog washing the page white and blurred while the drawer dimmed it dark.
883
+ */
884
+ var BaseBackdrops = { scrim: {
885
+ background: "rgba(255, 255, 255, 0.6)",
886
+ backdropFilter: "blur(2px)"
887
+ } };
878
888
  var BaseRadii = {
879
889
  none: "none",
880
890
  xxs: "4px",
@@ -967,9 +977,10 @@ var buildComponents = (c) => ({
967
977
  divider: "light",
968
978
  elevation: "menu",
969
979
  padding: "md",
970
- backdrop: { background: "rgba(0, 0, 0, 0.4)" },
980
+ backdrop: "scrim",
971
981
  scrim: true,
972
- background: "solid"
982
+ background: "solid",
983
+ motion: "panel"
973
984
  } },
974
985
  drawerHeader: { options: {
975
986
  color: void 0,
@@ -1084,17 +1095,18 @@ var buildComponents = (c) => ({
1084
1095
  color: "primary-surface",
1085
1096
  border: "quaternary",
1086
1097
  padding: "sm",
1098
+ bodyPadding: void 0,
1099
+ inset: "lg",
1087
1100
  elevation: "dialog",
1088
- backdrop: {
1089
- background: "rgba(255, 255, 255, 0.6)",
1090
- backdropFilter: "blur(2px)"
1091
- }
1101
+ backdrop: "scrim",
1102
+ motion: "panel"
1092
1103
  } },
1093
1104
  dialogButtons: { options: {
1094
1105
  gap: "md",
1095
1106
  padding: "md",
1096
1107
  paddingBottom: "lg",
1097
1108
  justifyContent: "center",
1109
+ divider: void 0,
1098
1110
  confirmButtonVariant: "primary",
1099
1111
  cancelButtonVariant: "warn",
1100
1112
  buttonSize: "lg",
@@ -1107,6 +1119,7 @@ var buildComponents = (c) => ({
1107
1119
  height: 48,
1108
1120
  textRole: "title-large",
1109
1121
  textAlign: "center",
1122
+ divider: void 0,
1110
1123
  closeButtonIcon: "close",
1111
1124
  closeButtonSize: "md"
1112
1125
  } },
@@ -1403,6 +1416,15 @@ var buildComponents = (c) => ({
1403
1416
  cursor: "pointer",
1404
1417
  transition: "all 0.28s ease"
1405
1418
  },
1419
+ variantOptions: {
1420
+ primary: { focusColor: "primary" },
1421
+ secondary: { focusColor: "secondary" },
1422
+ tertiary: { focusColor: "tertiary" },
1423
+ warn: { focusColor: "warn" },
1424
+ success: { focusColor: "success" },
1425
+ disabled: { focusColor: "disabled" },
1426
+ ghost: { focusColor: "primary" }
1427
+ },
1406
1428
  variants: {
1407
1429
  ghost: {
1408
1430
  backgroundColor: "transparent",
@@ -1474,30 +1496,45 @@ var buildComponents = (c) => ({
1474
1496
  },
1475
1497
  iconButton: {
1476
1498
  options: { borderRadius: "max" },
1499
+ variantOptions: {
1500
+ primary: { focusColor: "primary" },
1501
+ secondary: { focusColor: "secondary" },
1502
+ tertiary: { focusColor: "tertiary" },
1503
+ warn: { focusColor: "warn" },
1504
+ success: { focusColor: "success" },
1505
+ disabled: { focusColor: "disabled" },
1506
+ ghost: { focusColor: "primary" }
1507
+ },
1477
1508
  variants: {
1478
1509
  ghost: {
1479
1510
  backgroundColor: "transparent",
1480
- color: "currentcolor"
1511
+ color: "currentcolor",
1512
+ "&:hover": { backgroundColor: "rgba(0,0,0,0.1)" }
1481
1513
  },
1482
1514
  primary: {
1483
1515
  backgroundColor: c.primary,
1484
- color: c["on-primary"]
1516
+ color: c["on-primary"],
1517
+ "&:hover": { boxShadow: BaseShadows.raised }
1485
1518
  },
1486
1519
  secondary: {
1487
1520
  backgroundColor: c.secondary,
1488
- color: c["on-secondary"]
1521
+ color: c["on-secondary"],
1522
+ "&:hover": { boxShadow: BaseShadows.raised }
1489
1523
  },
1490
1524
  tertiary: {
1491
1525
  backgroundColor: c.tertiary,
1492
- color: c["on-tertiary"]
1526
+ color: c["on-tertiary"],
1527
+ "&:hover": { boxShadow: BaseShadows.raised }
1493
1528
  },
1494
1529
  warn: {
1495
1530
  backgroundColor: c.warn,
1496
- color: c["on-warn"]
1531
+ color: c["on-warn"],
1532
+ "&:hover": { boxShadow: BaseShadows.raised }
1497
1533
  },
1498
1534
  success: {
1499
1535
  backgroundColor: c.success,
1500
- color: c["on-success"]
1536
+ color: c["on-success"],
1537
+ "&:hover": { boxShadow: BaseShadows.raised }
1501
1538
  },
1502
1539
  disabled: {
1503
1540
  backgroundColor: "transparent !important",
@@ -1753,7 +1790,7 @@ var deepMerge = (base, override) => {
1753
1790
  for (const [key, value] of Object.entries(override)) out[key] = isRecord$1(value) && isRecord$1(out[key]) ? deepMerge(out[key], value) : value;
1754
1791
  return out;
1755
1792
  };
1756
- var createTheme = ({ id, name, colors, icons = {}, radii = BaseRadii, shadows = BaseShadows, motion, typography, borders, thicknesses, spacing, components }) => ({
1793
+ var createTheme = ({ id, name, colors, icons = {}, radii = BaseRadii, shadows = BaseShadows, motion, backdrops, typography, borders, thicknesses, spacing, components }) => ({
1757
1794
  id,
1758
1795
  name,
1759
1796
  colors,
@@ -1769,6 +1806,10 @@ var createTheme = ({ id, name, colors, icons = {}, radii = BaseRadii, shadows =
1769
1806
  ...BaseMotion,
1770
1807
  ...motion
1771
1808
  },
1809
+ backdrops: {
1810
+ ...BaseBackdrops,
1811
+ ...backdrops
1812
+ },
1772
1813
  thicknesses: {
1773
1814
  ...BaseThicknesses,
1774
1815
  ...thicknesses
@@ -2159,7 +2200,7 @@ var UniThemes = {
2159
2200
  Object.keys(UniThemes)[0];
2160
2201
  //#endregion
2161
2202
  //#region package.json
2162
- var version = "10.2.1";
2203
+ var version = "10.4.0";
2163
2204
  //#endregion
2164
2205
  //#region schematics-src/ng-add/transforms.ts
2165
2206
  var addDependencies = (packageJsonText, deps) => {
@@ -1,7 +1,7 @@
1
1
  import * as _angular_core from '@angular/core';
2
2
  import { Signal, WritableSignal, InjectionToken, ElementRef, TemplateRef, OnInit, OnDestroy, AfterViewInit } from '@angular/core';
3
3
  import * as _uni_design_system_uni_core from '@uni-design-system/uni-core';
4
- import { IconName, Variant, ContainerColorToken, PaletteConfig, GenerateColorsConfig, Radii, UniTheme, ComponentName, ComponentTheme, MotionToken, ThemeName, ThemeParseResult, TextRole, ContentColorToken, Size, NullableSize, Thickness, NullableStyleExpression, ColorKey, ColorToken, Typeface, Radius, Motion, OptionalSize, Border, Shadow, ZIndexableElements, OptionalAlignSelf, OptionalAlignItems, OptionalAlignContent, OptionalJustifyContent, OptionalDisplay, OptionalPosition, OptionalOverflow, OptionalFlexDirection, OptionalTextAlign, OptionalWrap, TextColor, TagTone, Elevation, RadiiSize, JustifyContent, StyleExpression, Orientation, CssLength, ColorScheme, ColorCategory, ThemeShape, ContrastCheck, Colors, GenerationInput } from '@uni-design-system/uni-core';
4
+ import { IconName, Variant, ContainerColorToken, PaletteConfig, GenerateColorsConfig, Radii, UniTheme, ComponentName, ComponentTheme, MotionToken, StyleExpression, ThemeName, ThemeParseResult, TextRole, ContentColorToken, Size, NullableSize, Thickness, NullableStyleExpression, ColorKey, ColorToken, Typeface, Radius, Motion, Backdrop, OptionalSize, Border, Shadow, ZIndexableElements, OptionalAlignSelf, OptionalAlignItems, OptionalAlignContent, OptionalJustifyContent, OptionalDisplay, OptionalPosition, OptionalOverflow, OptionalFlexDirection, OptionalTextAlign, OptionalWrap, TextColor, TagTone, Elevation, RadiiSize, JustifyContent, Orientation, CssLength, ColorScheme, ColorCategory, ThemeShape, ContrastCheck, Colors, GenerationInput } from '@uni-design-system/uni-core';
5
5
  import { FormCheckboxControl, FormValueControl } from '@angular/forms/signals';
6
6
  import * as _uni_design_system_uni_angular from '@uni-design-system/uni-angular';
7
7
  import { CSSObject } from '@emotion/css/create-instance';
@@ -1019,6 +1019,8 @@ declare class ThemeService {
1019
1019
  shadows: Signal<Partial<Record<string, string>>>;
1020
1020
  icons: Signal<_uni_design_system_uni_core.Icons>;
1021
1021
  motions: Signal<Partial<Record<string, MotionToken>>>;
1022
+ /** Same story as `motions`: a JSON theme may predate the backdrops scale. */
1023
+ backdrops: Signal<Partial<Record<string, StyleExpression>>>;
1022
1024
  constructor();
1023
1025
  /**
1024
1026
  * Activate a registered theme. Returns false — touching nothing, persisting
@@ -1066,7 +1068,7 @@ declare class ThemeService {
1066
1068
  selectedThemeKey: _angular_core.WritableSignal<string>;
1067
1069
  textClass: (textRole: TextRole, textColor?: ContentColorToken) => string;
1068
1070
  componentStyle: (componentName: ComponentName, variant: Variant, size: Size) => Signal<{
1069
- [x: string]: string | number | _uni_design_system_uni_core.StyleExpression;
1071
+ [x: string]: string | number | StyleExpression;
1070
1072
  }>;
1071
1073
  /**
1072
1074
  * The active variant's roles from a component's `variantOptions` map — the
@@ -1111,7 +1113,7 @@ declare class ThemeService {
1111
1113
  colorPair: (token?: ContainerColorToken, colorVariant?: boolean) => NullableStyleExpression;
1112
1114
  backgroundColor: (token?: ColorKey) => NullableStyleExpression;
1113
1115
  backgroundImage: (url?: string) => NullableStyleExpression;
1114
- getContainerColors: (color: Variant, useVariant?: boolean) => _uni_design_system_uni_core.StyleExpression;
1116
+ getContainerColors: (color: Variant, useVariant?: boolean) => StyleExpression;
1115
1117
  /**
1116
1118
  * The shared keyboard-focus indicator's styles (WCAG 2.4.7), without a
1117
1119
  * selector — for controls that key the ring off their own state selector
@@ -1154,6 +1156,16 @@ declare class ThemeService {
1154
1156
  * token that isn't there — still animates rather than snapping.
1155
1157
  */
1156
1158
  motion(token: Motion | undefined): MotionToken;
1159
+ private readonly warnedBackdrops;
1160
+ /**
1161
+ * Resolves a named backdrop primitive — the wash a modal surface lays over
1162
+ * the page — so every such surface dims it the same way.
1163
+ *
1164
+ * A raw style object passes straight through: that is the shape the dialog's
1165
+ * and drawer's `backdrop` options took before the scale existed, and a
1166
+ * consumer theme that still states one keeps working.
1167
+ */
1168
+ backdrop(token: Backdrop | StyleExpression | undefined): NullableStyleExpression;
1157
1169
  radius(size: Radius | undefined): NullableStyleExpression;
1158
1170
  getRadiusLeft(size: Radius | undefined): NullableStyleExpression;
1159
1171
  getRadiusRight(size: Radius | undefined): NullableStyleExpression;
@@ -3682,6 +3694,27 @@ declare class UniBreadcrumbComponent extends BaseComponent<UniBreadcrumbOptions>
3682
3694
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<UniBreadcrumbComponent, "uni-breadcrumb", never, { "items": { "alias": "items"; "required": true; "isSignal": true; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; "isSignal": true; }; }, { "itemClicked": "itemClicked"; }, never, never, true, never>;
3683
3695
  }
3684
3696
 
3697
+ /**
3698
+ * What a variant means for a button, as theme data the component reads.
3699
+ *
3700
+ * Only the keyboard-focus indicator lives here. Everything else a variant does
3701
+ * to a button is ordinary CSS and belongs in its `variants` style block; the
3702
+ * ring is different because it is drawn *outside* the element, so it cannot
3703
+ * take its colour from the fill and has to be named separately.
3704
+ */
3705
+ interface UniButtonVariant {
3706
+ /**
3707
+ * Keyboard-focus ring colour (WCAG 2.4.7).
3708
+ *
3709
+ * Falls back to the reserved `primary` accent. It must never resolve to
3710
+ * nothing: the ring used to take the variant *name* as a colour token, which
3711
+ * left `ghost` with a transparent outline and every unthemed or
3712
+ * consumer-registered intent with `2px solid undefined` — dropped by the CSS
3713
+ * parser, so the ring simply vanished while `outline-offset` survived and
3714
+ * kept the layout looking correct.
3715
+ */
3716
+ focusColor?: ColorKey;
3717
+ }
3685
3718
  /** Theme-level options for `uni-text-button`, resolved by token name. */
3686
3719
  interface UniButtonOptions {
3687
3720
  /**
@@ -3712,7 +3745,7 @@ declare class RippleDirective {
3712
3745
  static ɵdir: _angular_core.ɵɵDirectiveDeclaration<RippleDirective, "[uniRipple]", never, {}, {}, never, never, true, never>;
3713
3746
  }
3714
3747
 
3715
- declare class UniButtonComponent extends BaseComponent<UniButtonOptions> {
3748
+ declare class UniButtonComponent extends BaseComponent<UniButtonOptions, UniButtonVariant> {
3716
3749
  readonly disable: _angular_core.InputSignal<boolean>;
3717
3750
  readonly loading: _angular_core.InputSignal<boolean>;
3718
3751
  readonly fullWidth: _angular_core.InputSignal<boolean>;
@@ -3720,6 +3753,23 @@ declare class UniButtonComponent extends BaseComponent<UniButtonOptions> {
3720
3753
  readonly symbolRight: _angular_core.InputSignal<string>;
3721
3754
  spinnerBox: string;
3722
3755
  protected readonly className: _angular_core.Signal<string>;
3756
+ /**
3757
+ * The focus ring's colour, from the variant's theme entry.
3758
+ *
3759
+ * This used to be `colors[variant()]` — the variant *name* resolved as a
3760
+ * colour token. That held together only while every variant happened to also
3761
+ * be a colour, and it failed silently in both directions: `ghost` resolves to
3762
+ * `transparent`, and `light`/`onLight`/`dark`/`onDark` (and any name a
3763
+ * consumer registers) resolve to nothing, emitting `2px solid undefined`
3764
+ * which the parser drops. `outline-offset` survived either way, so the
3765
+ * element still shifted on focus and the missing ring went unnoticed.
3766
+ *
3767
+ * Falls back to the reserved `primary` accent rather than to `currentColor`:
3768
+ * the ring is drawn outside the element, so on a filled button
3769
+ * `currentColor` is the label colour and would sit near-invisibly against
3770
+ * the page rather than the button.
3771
+ */
3772
+ private readonly focusRingColor;
3723
3773
  symbolSize: _angular_core.Signal<number>;
3724
3774
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<UniButtonComponent, never>;
3725
3775
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<UniButtonComponent, "button[uni-text-button], button[text-button]", never, { "disable": { "alias": "disable"; "required": false; "isSignal": true; }; "loading": { "alias": "loading"; "required": false; "isSignal": true; }; "fullWidth": { "alias": "fullWidth"; "required": false; "isSignal": true; }; "symbolLeft": { "alias": "symbolLeft"; "required": false; "isSignal": true; }; "symbolRight": { "alias": "symbolRight"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, [{ directive: typeof RippleDirective; inputs: {}; outputs: {}; }]>;
@@ -4158,6 +4208,8 @@ interface UniDialogButtonsOptions {
4158
4208
  /** Bottom padding, as a spacing token. */
4159
4209
  paddingBottom?: NullableSize;
4160
4210
  justifyContent?: JustifyContent;
4211
+ /** Border drawn above the pinned row, separating it from the scrolling body. */
4212
+ divider?: Border;
4161
4213
  confirmButtonVariant?: Variant;
4162
4214
  cancelButtonVariant?: Variant;
4163
4215
  /** Size passed to both buttons. */
@@ -4190,6 +4242,8 @@ declare class UniDialogButtonsComponent extends BaseComponent<UniDialogButtonsOp
4190
4242
  protected justifyContentValue: _angular_core.Signal<JustifyContent>;
4191
4243
  protected gapValue: _angular_core.Signal<NullableSize>;
4192
4244
  protected buttonSize: _angular_core.Signal<Size>;
4245
+ /** A pinned row, sized by its content rather than by the body beside it. */
4246
+ protected readonly hostClass: _angular_core.Signal<string>;
4193
4247
  protected readonly className: _angular_core.Signal<string>;
4194
4248
  closeDialog(): void;
4195
4249
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<UniDialogButtonsComponent, never>;
@@ -4205,6 +4259,8 @@ interface UniDialogHeaderOptions {
4205
4259
  textRole: TextRole;
4206
4260
  textColor?: ContentColorToken;
4207
4261
  textAlign?: 'left' | 'center' | 'right';
4262
+ /** Border drawn under the pinned header, separating it from the scrolling body. */
4263
+ divider?: Border;
4208
4264
  closeButtonIcon?: IconName;
4209
4265
  closeButtonSymbol?: string;
4210
4266
  closeButtonSize?: Size;
@@ -4216,8 +4272,13 @@ declare class UniDialogHeaderComponent extends BaseComponent<UniDialogHeaderOpti
4216
4272
  protected readonly titleId: string;
4217
4273
  constructor();
4218
4274
  closeDialog(): void;
4275
+ /**
4276
+ * A pinned row: it is a flex child of the dialog and must not be sized by
4277
+ * the scrolling body beside it.
4278
+ */
4279
+ protected readonly className: _angular_core.Signal<string>;
4219
4280
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<UniDialogHeaderComponent, never>;
4220
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<UniDialogHeaderComponent, "[uni-dialog-header]", never, {}, {}, never, ["*"], true, never>;
4281
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<UniDialogHeaderComponent, "[uni-dialog-header], [dialog-header]", never, {}, {}, never, ["*"], true, never>;
4221
4282
  }
4222
4283
 
4223
4284
  interface UniDialogOptions {
@@ -4225,10 +4286,51 @@ interface UniDialogOptions {
4225
4286
  borderRadius: Radius;
4226
4287
  color: ContainerColorToken;
4227
4288
  elevation: Elevation;
4228
- backdrop: StyleExpression;
4289
+ /**
4290
+ * Name of a `backdrops` primitive — the wash laid over the page behind the
4291
+ * dialog. Shared with the drawer, so one token dresses both. A raw style
4292
+ * object is still accepted for themes that stated one before the scale.
4293
+ */
4294
+ backdrop: Backdrop | StyleExpression;
4295
+ /**
4296
+ * Insets the whole surface: the pinned header, the scrolling body and the
4297
+ * pinned buttons all sit inside it. Safe on a surface that never scrolls —
4298
+ * the dialog is `overflow: clip` and only its body row scrolls.
4299
+ */
4229
4300
  padding?: NullableSize;
4301
+ /**
4302
+ * Padding on the scrolling body row alone. Distinct from `padding`, which
4303
+ * insets all three rows.
4304
+ */
4305
+ bodyPadding?: NullableSize;
4306
+ /**
4307
+ * Timing for the open and close fade, panel and scrim together. The same
4308
+ * token the drawer points at, so the two surfaces arrive and leave alike.
4309
+ */
4310
+ motion?: Motion;
4311
+ /**
4312
+ * Minimum gap between the surface and the viewport edge. The dialog is
4313
+ * content-sized up to `calc(100dvh - 2 x inset)` and scrolls its body from
4314
+ * there.
4315
+ */
4316
+ inset?: NullableSize;
4230
4317
  }
4231
4318
 
4319
+ /**
4320
+ * Modal dialog on the native `<dialog>` element, laid out as three rows:
4321
+ * an optional `[dialog-header]`, the projected body, an optional
4322
+ * `[dialog-buttons]`.
4323
+ *
4324
+ * **The surface is never the scroll container.** It is a flex column that is
4325
+ * `overflow: clip` on both axes; the header and buttons pin while only the
4326
+ * body row scrolls. Unlike the drawer, which is deliberately viewport-tall,
4327
+ * the dialog stays content-sized: it has no `height`, and grows until it hits
4328
+ * `calc(100dvh - 2 x inset)` — the point at which the body starts to scroll.
4329
+ *
4330
+ * The theme's `padding` insets all three rows (which is what makes the default
4331
+ * header read as a pill floating inside the surface); `bodyPadding` pads the
4332
+ * scrolling row alone.
4333
+ */
4232
4334
  declare class UniDialogComponent extends BaseComponent<UniDialogOptions> {
4233
4335
  private elem;
4234
4336
  /** Two-way bindable open state: [(show)]. */
@@ -4249,9 +4351,22 @@ declare class UniDialogComponent extends BaseComponent<UniDialogOptions> {
4249
4351
  readonly hasTitle: _angular_core.WritableSignal<boolean>;
4250
4352
  /** Emits true once opened and false once the closing animation finishes. */
4251
4353
  showing: _angular_core.OutputEmitterRef<boolean>;
4354
+ protected readonly headerTemplate: _angular_core.Signal<TemplateRef<unknown>>;
4355
+ protected readonly bodyTemplate: _angular_core.Signal<TemplateRef<unknown>>;
4356
+ protected readonly footerTemplate: _angular_core.Signal<TemplateRef<unknown>>;
4252
4357
  constructor();
4253
4358
  private get _dialog();
4359
+ /**
4360
+ * One timing for the whole move, panel and scrim together — the same `panel`
4361
+ * token the drawer's slide reads, so the two surfaces no longer disagree
4362
+ * about how long arriving takes.
4363
+ */
4364
+ private readonly motion;
4365
+ /** The gap the surface keeps from the viewport edge before its body scrolls. */
4366
+ private readonly inset;
4254
4367
  protected readonly className: _angular_core.Signal<string>;
4368
+ /** The only scrolling row, and the only one `bodyPadding` touches. */
4369
+ protected readonly bodyClass: _angular_core.Signal<string>;
4255
4370
  protected backdropClick(event: Event): void;
4256
4371
  /**
4257
4372
  * Escape fires the native 'cancel' event, which would close the dialog
@@ -4260,13 +4375,19 @@ declare class UniDialogComponent extends BaseComponent<UniDialogOptions> {
4260
4375
  */
4261
4376
  protected escapeCancel(event: Event): void;
4262
4377
  protected closingAnimation(e: AnimationEvent): void;
4378
+ /**
4379
+ * Doubled selector (`.css-x.css-x`) so these win over the icon button's own
4380
+ * class, which sets `position: relative` and is emitted after this one.
4381
+ * Without it the close never leaves the flow — it used to sit inline at the
4382
+ * top of the surface, and under the flex column it would take a whole row.
4383
+ */
4263
4384
  closeButton: string;
4264
4385
  private dialogFadeIn;
4265
4386
  private dialogFadeOut;
4266
4387
  open(): void;
4267
4388
  close(): void;
4268
4389
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<UniDialogComponent, never>;
4269
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<UniDialogComponent, "dialog[uni-dialog]", never, { "show": { "alias": "show"; "required": false; "isSignal": true; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; "isSignal": true; }; "initialFocus": { "alias": "initialFocus"; "required": false; "isSignal": true; }; "defaultCloseButton": { "alias": "defaultCloseButton"; "required": false; "isSignal": true; }; }, { "show": "showChange"; "showing": "showing"; }, never, ["*"], true, never>;
4390
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<UniDialogComponent, "dialog[uni-dialog]", never, { "show": { "alias": "show"; "required": false; "isSignal": true; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; "isSignal": true; }; "initialFocus": { "alias": "initialFocus"; "required": false; "isSignal": true; }; "defaultCloseButton": { "alias": "defaultCloseButton"; "required": false; "isSignal": true; }; }, { "show": "showChange"; "showing": "showing"; }, never, ["[uni-dialog-header], [dialog-header]", "[uni-dialog-buttons], [dialog-buttons]", "*"], true, never>;
4270
4391
  }
4271
4392
 
4272
4393
  declare class UniDividerComponent {
@@ -4434,8 +4555,12 @@ interface UniDrawerOptions {
4434
4555
  * unpadded so that header and footer rows can pin flush to its edges.
4435
4556
  */
4436
4557
  padding?: OptionalSize;
4437
- /** Backdrop styling for the overlay mode. Ignored when `scrim` is false. */
4438
- backdrop?: StyleExpression;
4558
+ /**
4559
+ * Name of a `backdrops` primitive — the wash laid over the page behind the
4560
+ * overlay. The same token the dialog points at, so one theme entry dresses
4561
+ * both. A raw style object is still accepted. Ignored when `scrim` is false.
4562
+ */
4563
+ backdrop?: Backdrop | StyleExpression;
4439
4564
  /**
4440
4565
  * Whether the overlay mode dims the page behind it. False leaves
4441
4566
  * `::backdrop` transparent — the drawer still traps focus and is still
@@ -4444,6 +4569,12 @@ interface UniDrawerOptions {
4444
4569
  scrim?: boolean;
4445
4570
  /** Surface treatment of the panel. */
4446
4571
  background?: DrawerBackground;
4572
+ /**
4573
+ * Timing for everything the panel does: the overlay's slide, its scrim's
4574
+ * fade, and the side panel's width transition. One token for all three, so
4575
+ * the scrim can never drift out of step with the panel it dims.
4576
+ */
4577
+ motion?: Motion;
4447
4578
  }
4448
4579
 
4449
4580
  /**
@@ -4543,6 +4674,15 @@ declare class UniDrawerComponent extends BaseComponent<UniDrawerOptions> {
4543
4674
  private readonly edge;
4544
4675
  private readonly slideIn;
4545
4676
  private readonly slideOut;
4677
+ /** The scrim's own fade, so the dimming arrives and leaves with the panel. */
4678
+ private readonly scrimIn;
4679
+ private readonly scrimOut;
4680
+ /**
4681
+ * One timing for everything the panel does. The scrim used to snap in and
4682
+ * out around a panel that took 250ms to slide, because `::backdrop` had a
4683
+ * background and no animation at all.
4684
+ */
4685
+ private readonly motion;
4546
4686
  /** Input wins over the theme option; the literal is the last-resort default. */
4547
4687
  private readonly panelWidth;
4548
4688
  private readonly showScrim;
@@ -4922,11 +5062,20 @@ declare class UniIconComponent {
4922
5062
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<UniIconComponent, "uni-icon", never, { "color": { "alias": "color"; "required": false; "isSignal": true; }; "name": { "alias": "name"; "required": true; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
4923
5063
  }
4924
5064
 
5065
+ /**
5066
+ * What a variant means for an icon button, as theme data the component reads.
5067
+ * Mirrors `uni-button`'s: only the focus ring needs naming, because it is drawn
5068
+ * outside the element and so cannot take its colour from the fill.
5069
+ */
5070
+ interface UniIconButtonVariant {
5071
+ /** Keyboard-focus ring colour (WCAG 2.4.7). Falls back to `primary`. */
5072
+ focusColor?: ColorKey;
5073
+ }
4925
5074
  declare class UniIconButtonComponent {
4926
5075
  private theme;
4927
5076
  config: _angular_core.Signal<_uni_design_system_uni_core.ComponentTheme<{
4928
5077
  borderRadius?: RadiiSize;
4929
- }, object>>;
5078
+ }, UniIconButtonVariant>>;
4930
5079
  /**
4931
5080
  * Accessible name for the button. Alternative to projecting text content
4932
5081
  * (`<button icon-button>Close</button>`); one of the two is required for
@@ -4951,6 +5100,13 @@ declare class UniIconButtonComponent {
4951
5100
  */
4952
5101
  protected readonly glyphSize: _angular_core.Signal<string | number>;
4953
5102
  protected readonly className: _angular_core.Signal<string>;
5103
+ /**
5104
+ * The focus ring's colour, from the variant's theme entry — never from the
5105
+ * variant *name*, which is what left `uni-button`'s ring transparent on
5106
+ * `ghost` and absent on every unthemed intent. Falls back to the reserved
5107
+ * `primary` accent so a ring always renders.
5108
+ */
5109
+ private readonly focusRingColor;
4954
5110
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<UniIconButtonComponent, never>;
4955
5111
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<UniIconButtonComponent, "button[uni-icon-button], button[icon-button]", never, { "ariaLabel": { "alias": "ariaLabel"; "required": false; "isSignal": true; }; "iconName": { "alias": "iconName"; "required": false; "isSignal": true; }; "symbolName": { "alias": "symbolName"; "required": false; "isSignal": true; }; "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "disable": { "alias": "disable"; "required": false; "isSignal": true; }; "loading": { "alias": "loading"; "required": false; "isSignal": true; }; "opticalSize": { "alias": "opticalSize"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, [{ directive: typeof RippleDirective; inputs: {}; outputs: {}; }]>;
4956
5112
  }