@daffodil/design 0.91.0 → 0.92.3-rc.1

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 (142) hide show
  1. package/accordion/README.md +26 -38
  2. package/accordion/index.d.ts +2 -2
  3. package/article/README.md +66 -46
  4. package/article/index.d.ts +22 -1
  5. package/article/src/article-theme.scss +12 -0
  6. package/breadcrumb/README.md +6 -1
  7. package/breadcrumb/index.d.ts +65 -11
  8. package/breadcrumb/src/breadcrumb-theme.scss +1 -1
  9. package/button/README.md +36 -33
  10. package/button/index.d.ts +26 -5
  11. package/button/src/button/basic/button-theme.scss +4 -2
  12. package/button/src/button/button-base.scss +26 -3
  13. package/button/src/button/icon/icon-theme.scss +10 -6
  14. package/button/src/button/raised/raised-theme.scss +4 -2
  15. package/callout/README.md +15 -27
  16. package/card/README.md +36 -61
  17. package/container/README.md +18 -23
  18. package/fesm2022/daffodil-design-accordion.mjs +13 -13
  19. package/fesm2022/daffodil-design-accordion.mjs.map +1 -1
  20. package/fesm2022/daffodil-design-article.mjs +168 -26
  21. package/fesm2022/daffodil-design-article.mjs.map +1 -1
  22. package/fesm2022/daffodil-design-breadcrumb.mjs +180 -28
  23. package/fesm2022/daffodil-design-breadcrumb.mjs.map +1 -1
  24. package/fesm2022/daffodil-design-button.mjs +83 -42
  25. package/fesm2022/daffodil-design-button.mjs.map +1 -1
  26. package/fesm2022/daffodil-design-callout.mjs +23 -23
  27. package/fesm2022/daffodil-design-callout.mjs.map +1 -1
  28. package/fesm2022/daffodil-design-card.mjs +33 -33
  29. package/fesm2022/daffodil-design-card.mjs.map +1 -1
  30. package/fesm2022/daffodil-design-checkbox.mjs +13 -13
  31. package/fesm2022/daffodil-design-checkbox.mjs.map +1 -1
  32. package/fesm2022/daffodil-design-container.mjs +8 -8
  33. package/fesm2022/daffodil-design-container.mjs.map +1 -1
  34. package/fesm2022/daffodil-design-form-field.mjs +26 -26
  35. package/fesm2022/daffodil-design-form-field.mjs.map +1 -1
  36. package/fesm2022/daffodil-design-form.mjs +9 -9
  37. package/fesm2022/daffodil-design-form.mjs.map +1 -1
  38. package/fesm2022/daffodil-design-hero.mjs +23 -23
  39. package/fesm2022/daffodil-design-hero.mjs.map +1 -1
  40. package/fesm2022/daffodil-design-image.mjs +8 -8
  41. package/fesm2022/daffodil-design-image.mjs.map +1 -1
  42. package/fesm2022/daffodil-design-input.mjs +18 -14
  43. package/fesm2022/daffodil-design-input.mjs.map +1 -1
  44. package/fesm2022/daffodil-design-link-set.mjs +25 -17
  45. package/fesm2022/daffodil-design-link-set.mjs.map +1 -1
  46. package/fesm2022/daffodil-design-list.mjs +16 -16
  47. package/fesm2022/daffodil-design-list.mjs.map +1 -1
  48. package/fesm2022/daffodil-design-loading-icon.mjs +8 -8
  49. package/fesm2022/daffodil-design-loading-icon.mjs.map +1 -1
  50. package/fesm2022/daffodil-design-media-gallery.mjs +13 -13
  51. package/fesm2022/daffodil-design-media-gallery.mjs.map +1 -1
  52. package/fesm2022/daffodil-design-menu.mjs +223 -60
  53. package/fesm2022/daffodil-design-menu.mjs.map +1 -1
  54. package/fesm2022/daffodil-design-modal.mjs +33 -29
  55. package/fesm2022/daffodil-design-modal.mjs.map +1 -1
  56. package/fesm2022/daffodil-design-native-select.mjs +47 -41
  57. package/fesm2022/daffodil-design-native-select.mjs.map +1 -1
  58. package/fesm2022/daffodil-design-navbar.mjs +25 -21
  59. package/fesm2022/daffodil-design-navbar.mjs.map +1 -1
  60. package/fesm2022/daffodil-design-notification.mjs +16 -16
  61. package/fesm2022/daffodil-design-notification.mjs.map +1 -1
  62. package/fesm2022/daffodil-design-paginator.mjs +7 -7
  63. package/fesm2022/daffodil-design-paginator.mjs.map +1 -1
  64. package/fesm2022/daffodil-design-progress-bar.mjs +10 -10
  65. package/fesm2022/daffodil-design-progress-bar.mjs.map +1 -1
  66. package/fesm2022/daffodil-design-quantity-field.mjs +17 -14
  67. package/fesm2022/daffodil-design-quantity-field.mjs.map +1 -1
  68. package/fesm2022/daffodil-design-radio.mjs +16 -16
  69. package/fesm2022/daffodil-design-radio.mjs.map +1 -1
  70. package/fesm2022/daffodil-design-select.mjs +6 -6
  71. package/fesm2022/daffodil-design-select.mjs.map +1 -1
  72. package/fesm2022/daffodil-design-sidebar.mjs +25 -25
  73. package/fesm2022/daffodil-design-sidebar.mjs.map +1 -1
  74. package/fesm2022/daffodil-design-spinner.mjs +99 -0
  75. package/fesm2022/daffodil-design-spinner.mjs.map +1 -0
  76. package/fesm2022/daffodil-design-switch.mjs +3 -3
  77. package/fesm2022/daffodil-design-switch.mjs.map +1 -1
  78. package/fesm2022/daffodil-design-tabs.mjs +15 -15
  79. package/fesm2022/daffodil-design-tabs.mjs.map +1 -1
  80. package/fesm2022/daffodil-design-tag.mjs +7 -7
  81. package/fesm2022/daffodil-design-tag.mjs.map +1 -1
  82. package/fesm2022/daffodil-design-text-snippet.mjs +6 -8
  83. package/fesm2022/daffodil-design-text-snippet.mjs.map +1 -1
  84. package/fesm2022/daffodil-design-textarea.mjs +6 -3
  85. package/fesm2022/daffodil-design-textarea.mjs.map +1 -1
  86. package/fesm2022/daffodil-design-toast.mjs +23 -25
  87. package/fesm2022/daffodil-design-toast.mjs.map +1 -1
  88. package/fesm2022/daffodil-design-tree.mjs +152 -103
  89. package/fesm2022/daffodil-design-tree.mjs.map +1 -1
  90. package/fesm2022/daffodil-design-youtube-player.mjs +6 -6
  91. package/fesm2022/daffodil-design-youtube-player.mjs.map +1 -1
  92. package/fesm2022/daffodil-design.mjs +385 -326
  93. package/fesm2022/daffodil-design.mjs.map +1 -1
  94. package/form-field/README.md +50 -85
  95. package/form-field/index.d.ts +11 -9
  96. package/hero/README.md +5 -5
  97. package/image/README.md +2 -2
  98. package/index.d.ts +184 -270
  99. package/input/README.md +4 -4
  100. package/input/index.d.ts +4 -3
  101. package/link-set/index.d.ts +9 -1
  102. package/list/README.md +2 -2
  103. package/loading-icon/README.md +1 -1
  104. package/loading-icon/index.d.ts +1 -1
  105. package/media-gallery/README.md +3 -3
  106. package/menu/README.md +107 -10
  107. package/menu/index.d.ts +143 -11
  108. package/modal/README.md +1 -1
  109. package/modal/index.d.ts +23 -15
  110. package/native-select/README.md +4 -4
  111. package/native-select/index.d.ts +8 -7
  112. package/navbar/README.md +23 -17
  113. package/navbar/index.d.ts +12 -2
  114. package/navbar/src/navbar-theme.scss +4 -46
  115. package/notification/README.md +4 -4
  116. package/package.json +1 -1
  117. package/paginator/README.md +42 -6
  118. package/paginator/index.d.ts +4 -2
  119. package/progress-bar/README.md +3 -3
  120. package/quantity-field/README.md +4 -4
  121. package/quantity-field/index.d.ts +4 -1
  122. package/radio/README.md +1 -1
  123. package/scss/theme.scss +7 -1
  124. package/scss/theming/_color-palettes.scss +0 -6
  125. package/select/README.md +4 -4
  126. package/sidebar/README.md +6 -6
  127. package/spinner/README.md +57 -0
  128. package/spinner/index.d.ts +53 -0
  129. package/spinner/src/spinner-theme.scss +62 -0
  130. package/switch/README.md +4 -4
  131. package/switch/index.d.ts +2 -2
  132. package/tabs/README.md +1 -1
  133. package/tabs/index.d.ts +2 -2
  134. package/tag/README.md +24 -30
  135. package/tag/index.d.ts +1 -1
  136. package/text-snippet/README.md +1 -1
  137. package/text-snippet/src/text-snippet-theme.scss +12 -0
  138. package/textarea/README.md +4 -4
  139. package/textarea/index.d.ts +4 -4
  140. package/toast/README.md +4 -4
  141. package/tree/README.md +39 -22
  142. package/tree/index.d.ts +57 -90
package/index.d.ts CHANGED
@@ -3,7 +3,8 @@ import { OnChanges, OnInit, SimpleChanges, InjectionToken, Type, EventEmitter, C
3
3
  import { BreakpointObserver, BreakpointState } from '@angular/cdk/layout';
4
4
  import { Observable } from 'rxjs';
5
5
  import { DaffPersistenceService } from '@daffodil/core';
6
- import { UntypedFormControl } from '@angular/forms';
6
+ import * as i1 from '@angular/cdk/a11y';
7
+ import { CdkTrapFocus } from '@angular/cdk/a11y';
7
8
 
8
9
  /**
9
10
  * @deprecated in favor of the {@link DaffFormFieldLabelDirective}. Deprecated in version 0.86.0. Will be removed in version 1.0.0.
@@ -64,93 +65,34 @@ declare class DaffPrefixSuffixModule {
64
65
 
65
66
  declare const DAFF_PREFIX_SUFFIX_DIRECTIVES: readonly [typeof DaffPrefixDirective, typeof DaffSuffixDirective];
66
67
 
68
+ /**
69
+ * @deprecated Deprecated in version 0.92.0. Will be removed in version 1.0.0.
70
+ */
67
71
  interface DaffColorable {
68
- color: DaffPalette;
72
+ color: DaffColor;
69
73
  }
70
74
  /**
71
- * These are the valid options that can be passed to a DaffColorable component.
75
+ * The available color options.
76
+ */
77
+ type DaffColor = 'primary' | 'secondary' | 'tertiary' | 'light' | 'dark' | 'theme' | 'theme-contrast' | 'black' | 'white' | undefined;
78
+ /**
79
+ * @deprecated Deprecated in version 0.92.0. Will be removed in version 1.0.0.
72
80
  */
73
- type DaffPalette = 'primary' | 'secondary' | 'tertiary' | 'light' | 'dark' | 'theme' | 'theme-contrast' | 'black' | 'white' | undefined;
81
+ type DaffPalette = DaffColor;
74
82
 
75
83
  /**
76
- * `DaffColorableDirective` allows a component to conditionally apply color-specific
77
- * styles by setting CSS classes based on the specified color. This directive is useful
78
- * for applying different color palettes to a component in an Angular application.
79
- *
80
- * Supported colors: `primary | secondary | tertiary | light | dark | theme | theme-contrast`
81
- *
82
- * | Color | Class |
83
- * | -------- | ----- |
84
- * | `primary` | `.daff-primary`|
85
- * | `secondary` | `.daff-secondary`|
86
- * | `tertiary` | `.daff-tertiary`|
87
- * | `light` | `daff-light` |
88
- * | `dark` | `daff-dark` |
89
- * | `theme` | `daff-theme`|
90
- * | `theme-contrast` | `.daff-theme-contrast`|
91
- *
92
- * `white` and `black` have been deprecated in favor of `light` and `dark`.
93
- *
94
- * @example Implementing it as an attribute directive
95
- *
96
- * ```html
97
- * <div daffColorable [color]="primary">Colored content</div>
98
- * ```
99
- *
100
- * ```scss
101
- * .div {
102
- * &.daff-primary {
103
- * color: daff-color($primary);
104
- * }
105
- * }
106
- * ```
107
- *
108
- * In this example, the `daff-primary` class is applied to the `div` element, allowing you to
109
- * use the color class to style the `div`.
110
- *
111
- * @example Implementing it as an Angular host directive
112
- *
113
- * ```ts
114
- * @Component({
115
- * selector: 'custom-component',
116
- * template: 'custom-component.html',
117
- * hostDirectives: [
118
- * {
119
- * directive: DaffColorableDirective,
120
- * inputs: ['color'],
121
- * },
122
- * ],
123
- * })
124
- * export class CustomComponent {
125
- * @HostBinding('class.custom-component') class = true;
126
- * }
127
- * ```
128
- *
129
- * ```scss
130
- * .custom-component {
131
- * &.daff-primary {
132
- * background: daff-color($primary, 10);
133
- * color: daff-color($primary, 90);
134
- * }
135
- * }
136
- * ```
84
+ * Enforces consistent use of {@link DaffColor} on a component by applying
85
+ * color-specific CSS classes and validating the color in dev mode.
137
86
  */
138
- declare class DaffColorableDirective implements DaffColorable, OnChanges, OnInit {
87
+ declare class DaffColorableDirective implements OnChanges, OnInit {
139
88
  /**
140
- * Sets the color on a component.
89
+ * The color of the component.
141
90
  */
142
- color: DaffPalette;
91
+ color: DaffColor;
143
92
  /**
144
- * Sets a default color.
145
- *
146
- * @example
147
- * ```ts
148
- * constructor(private colorableDirective: DaffColorableDirective) {
149
- * this.colorableDirective.defaultColor = 'theme';
150
- * }
151
- * ```
93
+ * The default color used when no color is set.
152
94
  */
153
- defaultColor: DaffPalette;
95
+ defaultColor: DaffColor;
154
96
  /**
155
97
  * @docs-private
156
98
  */
@@ -163,12 +105,21 @@ declare class DaffColorableDirective implements DaffColorable, OnChanges, OnInit
163
105
  static ɵdir: i0.ɵɵDirectiveDeclaration<DaffColorableDirective, "[daffColorable]", never, { "color": { "alias": "color"; "required": false; }; }, {}, never, never, true, never>;
164
106
  }
165
107
 
108
+ /**
109
+ * Sensible breakpoints for layouts and interfaces used across `@daffodil/design` components.
110
+ */
166
111
  declare enum DaffBreakpoints {
112
+ /** `min-width: 1920px` */
167
113
  DESKTOP = "(min-width: 1920px)",
114
+ /** `min-width: 1440px` */
168
115
  LAPTOP = "(min-width: 1440px)",
116
+ /** `min-width: 1200px` */
169
117
  SMALL_LAPTOP = "(min-width: 1200px)",
118
+ /** `min-width: 1024px` */
170
119
  BIG_TABLET = "(min-width: 1024px)",
120
+ /** `min-width: 768px` */
171
121
  TABLET = "(min-width: 768px)",
122
+ /** `min-width: 480px` */
172
123
  MOBILE = "(min-width: 480px)"
173
124
  }
174
125
 
@@ -178,11 +129,22 @@ declare enum DaffBreakpoints {
178
129
  declare const SERVER_SAFE_BREAKPOINT_OBSERVER: InjectionToken<Omit<BreakpointObserver, never>>;
179
130
 
180
131
  /**
181
- * A stubbed out breakpoint observer service.
132
+ * A no-op implementation of Angular CDK's `BreakpointObserver` that always reports
133
+ * no breakpoints as matched. Useful for server-side rendering or testing contexts
134
+ * where browser layout APIs are unavailable.
182
135
  */
183
136
  declare class NoopBreakpointObserver implements Omit<BreakpointObserver, never> {
137
+ /**
138
+ * @docs-private
139
+ */
184
140
  ngOnDestroy(): void;
141
+ /**
142
+ * Always returns `false`, indicating that none of the given media queries are active.
143
+ */
185
144
  isMatched(value: string | readonly string[]): boolean;
145
+ /**
146
+ * Returns an observable that never emits a `BreakpointState`, making breakpoint-dependent logic inert.
147
+ */
186
148
  observe(value: string | readonly string[]): Observable<BreakpointState>;
187
149
  static ɵfac: i0.ɵɵFactoryDeclaration<NoopBreakpointObserver, never>;
188
150
  static ɵprov: i0.ɵɵInjectableDeclaration<NoopBreakpointObserver>;
@@ -344,23 +306,18 @@ declare class DaffSkeletonableDirective {
344
306
  }
345
307
 
346
308
  /**
347
- * An interface for giving a component the ability to display a mutating UI.
348
- * In order to be mutable, our class must implement this property.
349
- */
350
- interface DaffMutable {
351
- mutating: boolean;
352
- }
353
-
354
- /**
355
- * Interface for giving a component the ability to customize text alignment for component-specific UI.
309
+ * @deprecated Deprecated in version 0.92.1. Will be removed in version 1.0.0.
356
310
  */
357
311
  interface DaffTextAlignable {
358
312
  textAlignment: DaffTextAlignment;
359
313
  }
360
314
  /**
361
- * The possible types that can be passed to a DaffTextAlignable component
315
+ * * The available text alignment options.
362
316
  */
363
317
  type DaffTextAlignment = 'left' | 'center' | 'right';
318
+ /**
319
+ * This enum will be removed from the public api in v1.0.0.
320
+ */
364
321
  declare enum DaffTextAlignmentEnum {
365
322
  Left = "left",
366
323
  Center = "center",
@@ -368,49 +325,7 @@ declare enum DaffTextAlignmentEnum {
368
325
  }
369
326
 
370
327
  /**
371
- * `DaffTextAlignableDirective` allows for dynamic text alignment of a component by
372
- * setting CSS classes based on the specified text alignment. This directive is
373
- * useful when text alignment needs to be managed dynamically in an Angular component.
374
- *
375
- * ## Why not just use CSS?
376
- *
377
- * While the native CSS `text-align` property can be used for static text alignment,
378
- * the `DaffTextAlignableDirective` provides a structured and consistent way to handle
379
- * dynamic text alignment within Angular components in more complex use cases where the
380
- * application of `text-align: center;` would cause unexpected side effects.
381
- *
382
- * @example Implementing it as an attribute directive
383
- *
384
- * ```html
385
- * <div daffTextAlignable textAlignment="center">Aligned text</div>
386
- * ```
387
- *
388
- * In this example, the `daff-center` class is added to the `div` element, allowing
389
- * you to style the `div` as you wish using the class.
390
- *
391
- * @example Implementing it as an Angular host directive
392
- *
393
- * ```ts
394
- * @Component({
395
- * selector: 'custom-component',
396
- * template: 'custom-component.html',
397
- * hostDirectives: [
398
- * {
399
- * directive: DaffTextAlignableDirective,
400
- * inputs: ['textAlignment'],
401
- * },
402
- * ],
403
- * })
404
- * export class CustomComponent { }
405
- * ```
406
- *
407
- * ```scss
408
- * .custom-component {
409
- * &.daff-left {
410
- * text-align: left;
411
- * }
412
- * }
413
- * ```
328
+ * `DaffTextAlignableDirective` enforces consistent use of text alignment across components.
414
329
  */
415
330
  declare class DaffTextAlignableDirective implements DaffTextAlignable, OnChanges, OnInit {
416
331
  /**
@@ -418,14 +333,7 @@ declare class DaffTextAlignableDirective implements DaffTextAlignable, OnChanges
418
333
  */
419
334
  textAlignment: DaffTextAlignment;
420
335
  /**
421
- * Sets a default alignment.
422
- *
423
- * @example
424
- * ```ts
425
- * constructor(private textAligmentDirective: DaffTextAlignableDirective) {
426
- * this.textAligmentDirective.defaultAlignent = 'left';
427
- * }
428
- * ```
336
+ * The default used when no text alignment is set.
429
337
  */
430
338
  defaultAlignment: DaffTextAlignment;
431
339
  /**
@@ -441,59 +349,18 @@ declare class DaffTextAlignableDirective implements DaffTextAlignable, OnChanges
441
349
  }
442
350
 
443
351
  /**
444
- * An interface for giving a component the ability to display a compact UI.
445
- * In order to be compactable, the class must implement this property.
352
+ * @deprecated Deprecated in version 0.92.0. Will be removed in version 1.0.0.
446
353
  */
447
354
  interface DaffCompactable {
448
355
  compact: boolean;
449
356
  }
450
357
 
451
358
  /**
452
- * `DaffCompactableDirective` allows a component to conditionally apply a compact
453
- * style by toggling a CSS class. This is useful for creating components that can
454
- * switch between regular and compact styles based on the `compact` property.
455
- *
456
- * @example Implementing it as an attribute directive
457
- *
458
- * ```html
459
- * <div daffCompactable [compact]="isCompact">Content goes here</div>
460
- * ```
461
- *
462
- * In this example, the `daff-compact` class is applied to the `div` element when
463
- * `isCompact` is `true`, making the `div` display its compact state.
464
- *
465
- * @example Implementing it as an Angular host directive
466
- *
467
- * ```ts
468
- * @Component({
469
- * selector: 'custom-component',
470
- * template: 'custom-component.html',
471
- * hostDirectives: [
472
- * {
473
- * directive: DaffCompactableDirective,
474
- * inputs: ['compact'],
475
- * },
476
- * ],
477
- * })
478
- * export class CustomComponent { }
479
- * ```
480
- *
481
- * The directive applies the `daff-compact` class to the component and
482
- * should be defined in your styles to display the compact state as desired.
483
- *
484
- * ```scss
485
- * :host {
486
- * padding: 8px 16px;
487
- *
488
- * &.daff-compact {
489
- * padding: 4px 8px;
490
- * }
491
- * }
492
- * ```
359
+ * Enforces consistent use of the compact property.
493
360
  */
494
361
  declare class DaffCompactableDirective {
495
362
  /**
496
- * Controls whether the component is compact.
363
+ * Whether the component is compact.
497
364
  */
498
365
  compact: boolean;
499
366
  static ɵfac: i0.ɵɵFactoryDeclaration<DaffCompactableDirective, never>;
@@ -563,27 +430,7 @@ declare class DaffManageContainerLayoutDirective {
563
430
  }
564
431
 
565
432
  /**
566
- * `DaffArticleEncapsulatedDirective` is used to encapsulate custom components within an article,
567
- * preventing {@link DaffArticleComponent } styles from bleeding into the component.
568
- *
569
- * @example Implementing it as an attribute directive
570
- *
571
- * ```html
572
- * <my-custom-component daffArticleEncapsulated></my-custom-component>
573
- * ```
574
- *
575
- * @example Implementing it as an Angular host directive
576
- *
577
- * ```ts
578
- * @Component({
579
- * selector: 'custom-component',
580
- * template: 'custom-component.html',
581
- * hostDirectives: [{ directive: DaffArticleEncapsulatedDirective }],
582
- * })
583
- * export class CustomComponent { }
584
- * ```
585
- *
586
- * This directive will apply the `daff-ae` class to the component, ensuring that it is encapsulated from the article's styles.
433
+ * The `DaffArticleEncapsulatedDirective` prevents {@link DaffArticleComponent } styles from bleeding into custom components nested within an article.
587
434
  */
588
435
  declare class DaffArticleEncapsulatedDirective {
589
436
  static ɵfac: i0.ɵɵFactoryDeclaration<DaffArticleEncapsulatedDirective, never>;
@@ -918,6 +765,8 @@ declare class DaffOpenableDirective implements DaffOpenable, OnChanges {
918
765
  }
919
766
 
920
767
  /**
768
+ * @deprecated Deprecated in version 0.92.1. Will be removed in version 1.0.0.
769
+ *
921
770
  * Interface for giving a component the ability to customize text alignment for component-specific UI.
922
771
  */
923
772
  interface DaffOrientable {
@@ -927,66 +776,24 @@ interface DaffOrientable {
927
776
  * The possible types that can be passed to a DaffOrientable component
928
777
  */
929
778
  type DaffOrientation = 'horizontal' | 'vertical';
779
+ /**
780
+ * This enum will be removed from the public api in v1.0.0.
781
+ */
930
782
  declare enum DaffOrientationEnum {
931
783
  Horizontal = "horizontal",
932
784
  Vertical = "vertical"
933
785
  }
934
786
 
935
787
  /**
936
- * `DaffOrientableDirective` allows for dynamic orientation of a component by
937
- * setting CSS classes based on the specified orientation. This directive is
938
- * useful when orientation needs to be managed dynamically in an Angular component.
939
- *
940
- * @example Implementing it as an attribute directive
941
- *
942
- * ```html
943
- * <div daffOrientable [orientation]="horizontal"></div>
944
- * ```
945
- *
946
- * In this example, the `daff-horizontal` class is added to the `div` element, allowing
947
- * you to style the `div` as you wish using the class.
948
- *
949
- * @example Implementing it as an Angular host directive
950
- *
951
- * ```ts
952
- * @Component({
953
- * selector: 'custom-component',
954
- * template: 'custom-component.html',
955
- * hostDirectives: [
956
- * {
957
- * directive: DaffOrientableDirective,
958
- * inputs: ['orientation'],
959
- * },
960
- * ],
961
- * })
962
- * export class CustomComponent { }
963
- * ```
964
- *
965
- * ```scss
966
- * .custom-component {
967
- * &.daff-vertical {
968
- * display: flex;
969
- * flex-direction: column;
970
- * }
971
- * }
972
- * ```
788
+ * `DaffOrientableDirective`enforces consistent use of orientation across components.
973
789
  */
974
790
  declare class DaffOrientableDirective implements DaffOrientable, OnChanges, OnInit {
975
791
  /**
976
792
  * The orientation of the component.
977
- *
978
- * Options are: `horizontal` and `vertical`.
979
793
  */
980
794
  orientation: DaffOrientation;
981
795
  /**
982
- * Sets a default orientation.
983
- *
984
- * @example
985
- * ```ts
986
- * constructor(private orientableDirective: DaffOrientableDirective) {
987
- * this.orientableDirective.defaultOrientation = 'horizontal';
988
- * }
989
- * ```
796
+ * The default used when no orientation is set.
990
797
  */
991
798
  defaultOrientation: DaffOrientation;
992
799
  /**
@@ -1055,17 +862,36 @@ declare class DaffStickyTrackerDirective implements OnDestroy {
1055
862
  }
1056
863
 
1057
864
  /**
1058
- * `DaffDisableableDirective` allows a component to display a disabled UI
865
+ * Enforces consistent use of the disabled property.
866
+ */
867
+ declare class DaffDisableableDirective {
868
+ /**
869
+ * Whether the component is disabled.
870
+ */
871
+ disabled: boolean;
872
+ static ɵfac: i0.ɵɵFactoryDeclaration<DaffDisableableDirective, never>;
873
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DaffDisableableDirective, "[daffDisableable]", never, { "disabled": { "alias": "disabled"; "required": false; }; }, {}, never, never, true, never>;
874
+ }
875
+
876
+ /**
877
+ * An interface for any component or directive that can be disabled.
878
+ */
879
+ interface DaffDisableable {
880
+ disabled: boolean;
881
+ }
882
+
883
+ /**
884
+ * `DaffLoadableDirective` allows a component to display a loading UI
1059
885
  * by conditionally applying a CSS class. This is useful for indicating to
1060
- * users that content is loading or being processed. This directive can be used to
1061
- * apply a disabled UI to any component by toggling the `disabled`
1062
- * input property. When `disabled` is `true`, the `daff-disabled` CSS class
886
+ * users that a user action is being processed. This directive can be used to
887
+ * apply a loading UI to any component by toggling the `loading`
888
+ * input property. When `loading` is `true`, the `daff-loading` CSS class
1063
889
  * is applied, which should style the component to look like it's not interactable.
1064
890
  *
1065
891
  * @example Implementing it as an attribute directive
1066
892
  *
1067
893
  * ```html
1068
- * <div daffDisableable [disabled]="isDisabled">Content</div>
894
+ * <div daffLoadable [loading]="isLoading">Content</div>
1069
895
  * ```
1070
896
  *
1071
897
  * @example Implementing it as an Angular host directive
@@ -1076,8 +902,8 @@ declare class DaffStickyTrackerDirective implements OnDestroy {
1076
902
  * template: 'custom-component.html',
1077
903
  * hostDirectives: [
1078
904
  * {
1079
- * directive: DaffDisableableDirective,
1080
- * inputs: ['disabled'],
905
+ * directive: DaffLoadableDirective,
906
+ * inputs: ['loading'],
1081
907
  * },
1082
908
  * ],
1083
909
  * })
@@ -1086,25 +912,113 @@ declare class DaffStickyTrackerDirective implements OnDestroy {
1086
912
  *
1087
913
  * ```scss
1088
914
  * :host {
1089
- * .daff-disabled {
1090
- * cursor: not-allowed;
1091
- * opacity: 0.5;
915
+ * .spinner {
916
+ * opacity: 0;
917
+ * }
918
+ * .daff-loading {
919
+ * .spinner {
920
+ * opacity: 1;
921
+ * }
1092
922
  * }
1093
923
  * }
1094
924
  * ```
1095
925
  *
1096
- * The directive applies the `daff-disabled` class to the component. The class should be
926
+ * The directive applies the `daff-loading` class to the component. The class should be
1097
927
  * defined in your styles to display the loading state as desired.
1098
928
  */
1099
- declare class DaffDisableableDirective {
1100
- disabled: boolean;
1101
- static ɵfac: i0.ɵɵFactoryDeclaration<DaffDisableableDirective, never>;
1102
- static ɵdir: i0.ɵɵDirectiveDeclaration<DaffDisableableDirective, "[daffDisableable]", never, { "disabled": { "alias": "disabled"; "required": false; }; }, {}, never, never, true, never>;
929
+ declare class DaffLoadableDirective {
930
+ loading: boolean;
931
+ static ɵfac: i0.ɵɵFactoryDeclaration<DaffLoadableDirective, never>;
932
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DaffLoadableDirective, "[daffLoadable]", never, { "loading": { "alias": "loading"; "required": false; }; }, {}, never, never, true, never>;
933
+ }
934
+
935
+ declare class DaffRovingTabIndexService {
936
+ private document;
937
+ private readonly _hierarchy;
938
+ private readonly _group;
939
+ readonly group: i0.Signal<string>;
940
+ constructor(document: Document);
941
+ enter(group: string): void;
942
+ leave(): void;
943
+ next(): void;
944
+ previous(): void;
945
+ private _changeFocus;
946
+ onKeydown(evt: Event): void;
947
+ static ɵfac: i0.ɵɵFactoryDeclaration<DaffRovingTabIndexService, never>;
948
+ static ɵprov: i0.ɵɵInjectableDeclaration<DaffRovingTabIndexService>;
949
+ }
950
+
951
+ /**
952
+ * Defines the boundary of an RTI group.
953
+ */
954
+ declare class DaffRovingTabIndexBoundaryDirective {
955
+ private groupService;
956
+ private focusTrap;
957
+ /**
958
+ * Don't touch this directly. Use `_uniqueId`.
959
+ */
960
+ private static _uniqueIdCounter;
961
+ /**
962
+ * Don't touch this directly. Use `_uniqueId`.
963
+ */
964
+ private _cachedUniqueId;
965
+ private get _uniqueId();
966
+ /**
967
+ * The name of the group for which that this element will act as boundary.
968
+ * Optional, will be autogenerated to a unique name if omitted.
969
+ */
970
+ readonly rtiBoundary: i0.InputSignal<string>;
971
+ /**
972
+ * The name of the group defined by this boundary.
973
+ */
974
+ readonly effectiveBoundary: i0.Signal<string>;
975
+ constructor(groupService: DaffRovingTabIndexService, focusTrap: CdkTrapFocus);
976
+ /**
977
+ * @docs-private
978
+ */
979
+ enterGroup(evt: Event): void;
980
+ static ɵfac: i0.ɵɵFactoryDeclaration<DaffRovingTabIndexBoundaryDirective, never>;
981
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DaffRovingTabIndexBoundaryDirective, "[rtiBoundary]", never, { "rtiBoundary": { "alias": "rtiBoundary"; "required": false; "isSignal": true; }; }, {}, never, never, true, [{ directive: typeof i1.CdkTrapFocus; inputs: {}; outputs: {}; }, { directive: typeof DaffRovingTabIndexDirective; inputs: {}; outputs: {}; }]>;
1103
982
  }
1104
983
 
1105
- declare class DaffErrorStateMatcher {
1106
- isErrorState(control: UntypedFormControl, formSubmitted: boolean): boolean;
984
+ /**
985
+ * Declares that an element is an RTI target.
986
+ * Automatically applied to `<a>` and `<button>` elements.
987
+ */
988
+ declare class DaffRovingTabIndexDirective {
989
+ private service;
990
+ private parent;
991
+ /**
992
+ * Allows the RTI group to be overriden.
993
+ * By default it will be the nearest ancestor or the default root group if no boundary ancestor exists.
994
+ * @see {@link DaffRovingTabIndexBoundaryDirective}.
995
+ */
996
+ readonly rti: i0.InputSignal<string>;
997
+ /**
998
+ * The group in which this RTI target resides.
999
+ * See {@link DaffRovingTabIndexBoundaryDirective} to make an element act as the boundary of an RTI group.
1000
+ */
1001
+ readonly group: i0.Signal<string>;
1002
+ /**
1003
+ * @docs-private
1004
+ */
1005
+ readonly tabindex: i0.Signal<0 | -1>;
1006
+ constructor(service: DaffRovingTabIndexService, parent: DaffRovingTabIndexBoundaryDirective);
1007
+ /**
1008
+ * @docs-private
1009
+ */
1010
+ leaveGroup(evt: Event): void;
1011
+ /**
1012
+ * @docs-private
1013
+ */
1014
+ next(evt: Event): void;
1015
+ /**
1016
+ * @docs-private
1017
+ */
1018
+ previous(evt: Event): void;
1019
+ static ɵfac: i0.ɵɵFactoryDeclaration<DaffRovingTabIndexDirective, [null, { optional: true; skipSelf: true; }]>;
1020
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DaffRovingTabIndexDirective, "[rti],a,button", never, { "rti": { "alias": "rti"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
1107
1021
  }
1108
1022
 
1109
- export { DAFF_PREFIX_SUFFIX_DIRECTIVES, DAFF_THEME_INITIALIZER, DaffArticleEncapsulatedDirective, DaffBreakpoints, DaffColorableDirective, DaffCompactableDirective, DaffDisableableDirective, DaffErrorStateMatcher, DaffFocusStackService, DaffFormLabelDirective, DaffFormLabelModule, DaffManageContainerLayoutDirective, DaffOpenableDirective, DaffOrientableDirective, DaffOrientationEnum, DaffPrefixDirective, DaffPrefixSuffixModule, DaffSelectableDirective, DaffSizableDirective, DaffSizableEnum, DaffSkeletonableDirective, DaffStatusEnum, DaffStatusableDirective, DaffStickyTrackerDirective, DaffSuffixDirective, DaffTextAlignableDirective, DaffTextAlignmentEnum, DaffTheme, DaffThemingService, NoopBreakpointObserver, SERVER_SAFE_BREAKPOINT_OBSERVER, daffFocusableElementsSelector };
1110
- export type { AnimationStateWithParams, Constructor, DaffColorable, DaffCompactable, DaffLazyComponent, DaffMutable, DaffOpenable, DaffOrientable, DaffOrientation, DaffPalette, DaffSelectable, DaffSizable, DaffSizeAllType, DaffSizeLargeType, DaffSizeMediumType, DaffSizeSmallType, DaffSizeXLargeType, DaffSizeXSmallType, DaffStatus, DaffStatusable, DaffTextAlignable, DaffTextAlignment };
1023
+ export { DAFF_PREFIX_SUFFIX_DIRECTIVES, DAFF_THEME_INITIALIZER, DaffArticleEncapsulatedDirective, DaffBreakpoints, DaffColorableDirective, DaffCompactableDirective, DaffDisableableDirective, DaffFocusStackService, DaffFormLabelDirective, DaffFormLabelModule, DaffLoadableDirective, DaffManageContainerLayoutDirective, DaffOpenableDirective, DaffOrientableDirective, DaffOrientationEnum, DaffPrefixDirective, DaffPrefixSuffixModule, DaffRovingTabIndexBoundaryDirective, DaffRovingTabIndexDirective, DaffSelectableDirective, DaffSizableDirective, DaffSizableEnum, DaffSkeletonableDirective, DaffStatusEnum, DaffStatusableDirective, DaffStickyTrackerDirective, DaffSuffixDirective, DaffTextAlignableDirective, DaffTextAlignmentEnum, DaffTheme, DaffThemingService, NoopBreakpointObserver, SERVER_SAFE_BREAKPOINT_OBSERVER, daffFocusableElementsSelector };
1024
+ export type { AnimationStateWithParams, Constructor, DaffColor, DaffColorable, DaffCompactable, DaffDisableable, DaffLazyComponent, DaffOpenable, DaffOrientable, DaffOrientation, DaffPalette, DaffSelectable, DaffSizable, DaffSizeAllType, DaffSizeLargeType, DaffSizeMediumType, DaffSizeSmallType, DaffSizeXLargeType, DaffSizeXSmallType, DaffStatus, DaffStatusable, DaffTextAlignable, DaffTextAlignment };
package/input/README.md CHANGED
@@ -4,7 +4,7 @@ Input works alongside the native HTML input element, with additional custom styl
4
4
  ## Overview
5
5
  Input has the same functionality as a native HTML input element, with additional custom styling and functionality. It **cannot** be used by itself and must be contained within a [form field](/libs/design/form-field/README.md).
6
6
 
7
- <design-land-example-viewer-container example="input-with-form-field"></design-land-example-viewer-container>
7
+ <daff-docs-example-viewer example="input-with-form-field"></daff-docs-example-viewer>
8
8
 
9
9
  ## Usage
10
10
 
@@ -66,19 +66,19 @@ Input must be used inside `<daff-form-field>` to enable proper state management
66
66
  ### Disabled
67
67
  Input can be disabled in two ways: using Angular's reactive forms with `FormControl` or with the native HTML `disabled` attribute.
68
68
 
69
- <design-land-example-viewer-container example="input-disabled"></design-land-example-viewer-container>
69
+ <daff-docs-example-viewer example="input-disabled"></daff-docs-example-viewer>
70
70
 
71
71
  ### Error
72
72
  Input supports validation and error messages through Angular's form validation system. Use `<daff-error-message>` within the form field to display context-specific error messages. Error messages automatically appear when the input is invalid and has been touched or submitted.
73
73
 
74
- <design-land-example-viewer-container example="input-error"></design-land-example-viewer-container>
74
+ <daff-docs-example-viewer example="input-error"></daff-docs-example-viewer>
75
75
 
76
76
  Multiple error messages can be displayed conditionally based on the type of validation error. The form field component handles the styling and positioning of error messages.
77
77
 
78
78
  ## Hints
79
79
  Hints provide additional context or instructions to help users complete the input field correctly. Use `<daff-hint>` within the form field to display helpful information below the input. Unlike error messages, hints are always visible and provide guidance rather than validation feedback.
80
80
 
81
- <design-land-example-viewer-container example="input-hint"></design-land-example-viewer-container>
81
+ <daff-docs-example-viewer example="input-hint"></daff-docs-example-viewer>
82
82
 
83
83
  ## Accessibility
84
84
  When `<daff-form-label>` is used within `<daff-form-field>`, the label automatically associates with the input using the `for` and `id` attributes.
package/input/index.d.ts CHANGED
@@ -29,7 +29,7 @@ declare class DaffInputComponent extends DaffFormFieldControl<string> implements
29
29
  /**
30
30
  * @docs-private
31
31
  */
32
- get disabledAttribute(): true;
32
+ get disabledAttribute(): boolean;
33
33
  private _required;
34
34
  /**
35
35
  * @docs-private
@@ -46,10 +46,11 @@ declare class DaffInputComponent extends DaffFormFieldControl<string> implements
46
46
  * @docs-private
47
47
  */
48
48
  get ariaDescribedBy(): string;
49
- /** @docs-private */
50
49
  focus(): void;
51
50
  /** @docs-private */
52
- blur(): void;
51
+ _handleFocus(): void;
52
+ /** @docs-private */
53
+ _handleBlur(): void;
53
54
  constructor(
54
55
  /** @docs-private */
55
56
  ngControl: NgControl, _elementRef: ElementRef<HTMLInputElement>, formField: DaffFormFieldComponent);