@molecule/app-ui-angular 1.2.1 → 1.3.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.
Files changed (212) hide show
  1. package/README.md +2744 -912
  2. package/dist/components/accordion.component.d.ts +17 -2
  3. package/dist/components/accordion.component.d.ts.map +1 -1
  4. package/dist/components/accordion.component.js +31 -7
  5. package/dist/components/accordion.component.js.map +1 -1
  6. package/dist/components/alert.component.d.ts +15 -2
  7. package/dist/components/alert.component.d.ts.map +1 -1
  8. package/dist/components/alert.component.js +25 -4
  9. package/dist/components/alert.component.js.map +1 -1
  10. package/dist/components/auth-guard.component.d.ts +41 -9
  11. package/dist/components/auth-guard.component.d.ts.map +1 -1
  12. package/dist/components/auth-guard.component.js +58 -23
  13. package/dist/components/auth-guard.component.js.map +1 -1
  14. package/dist/components/avatar.component.d.ts +15 -2
  15. package/dist/components/avatar.component.d.ts.map +1 -1
  16. package/dist/components/avatar.component.js +35 -5
  17. package/dist/components/avatar.component.js.map +1 -1
  18. package/dist/components/badge.component.d.ts +15 -2
  19. package/dist/components/badge.component.d.ts.map +1 -1
  20. package/dist/components/badge.component.js +35 -6
  21. package/dist/components/badge.component.js.map +1 -1
  22. package/dist/components/button.component.d.ts +20 -2
  23. package/dist/components/button.component.d.ts.map +1 -1
  24. package/dist/components/button.component.js +30 -4
  25. package/dist/components/button.component.js.map +1 -1
  26. package/dist/components/card.component.d.ts +67 -9
  27. package/dist/components/card.component.d.ts.map +1 -1
  28. package/dist/components/card.component.js +99 -17
  29. package/dist/components/card.component.js.map +1 -1
  30. package/dist/components/checkbox.component.d.ts +35 -5
  31. package/dist/components/checkbox.component.d.ts.map +1 -1
  32. package/dist/components/checkbox.component.js +59 -9
  33. package/dist/components/checkbox.component.js.map +1 -1
  34. package/dist/components/confirm-button.component.d.ts +85 -17
  35. package/dist/components/confirm-button.component.d.ts.map +1 -1
  36. package/dist/components/confirm-button.component.js +112 -25
  37. package/dist/components/confirm-button.component.js.map +1 -1
  38. package/dist/components/confirm-dialog.component.d.ts +50 -13
  39. package/dist/components/confirm-dialog.component.d.ts.map +1 -1
  40. package/dist/components/confirm-dialog.component.js +118 -31
  41. package/dist/components/confirm-dialog.component.js.map +1 -1
  42. package/dist/components/dropdown.component.d.ts +30 -4
  43. package/dist/components/dropdown.component.d.ts.map +1 -1
  44. package/dist/components/dropdown.component.js +80 -13
  45. package/dist/components/dropdown.component.js.map +1 -1
  46. package/dist/components/empty-state.component.d.ts +5 -1
  47. package/dist/components/empty-state.component.d.ts.map +1 -1
  48. package/dist/components/empty-state.component.js +5 -1
  49. package/dist/components/empty-state.component.js.map +1 -1
  50. package/dist/components/floating-input.component.d.ts +18 -4
  51. package/dist/components/floating-input.component.d.ts.map +1 -1
  52. package/dist/components/floating-input.component.js +38 -8
  53. package/dist/components/floating-input.component.js.map +1 -1
  54. package/dist/components/form-field.component.d.ts +14 -2
  55. package/dist/components/form-field.component.d.ts.map +1 -1
  56. package/dist/components/form-field.component.js +34 -5
  57. package/dist/components/form-field.component.js.map +1 -1
  58. package/dist/components/form.component.d.ts +61 -15
  59. package/dist/components/form.component.d.ts.map +1 -1
  60. package/dist/components/form.component.js +65 -14
  61. package/dist/components/form.component.js.map +1 -1
  62. package/dist/components/icon.component.d.ts +22 -4
  63. package/dist/components/icon.component.d.ts.map +1 -1
  64. package/dist/components/icon.component.js +1 -1
  65. package/dist/components/icon.component.js.map +1 -1
  66. package/dist/components/input.component.d.ts +34 -4
  67. package/dist/components/input.component.d.ts.map +1 -1
  68. package/dist/components/input.component.js +66 -11
  69. package/dist/components/input.component.js.map +1 -1
  70. package/dist/components/label.component.d.ts +5 -1
  71. package/dist/components/label.component.d.ts.map +1 -1
  72. package/dist/components/label.component.js +6 -2
  73. package/dist/components/label.component.js.map +1 -1
  74. package/dist/components/language-picker.component.d.ts +44 -8
  75. package/dist/components/language-picker.component.d.ts.map +1 -1
  76. package/dist/components/language-picker.component.js +29 -17
  77. package/dist/components/language-picker.component.js.map +1 -1
  78. package/dist/components/layout.component.d.ts +57 -8
  79. package/dist/components/layout.component.d.ts.map +1 -1
  80. package/dist/components/layout.component.js +134 -21
  81. package/dist/components/layout.component.js.map +1 -1
  82. package/dist/components/load-error-banner.component.d.ts +39 -7
  83. package/dist/components/load-error-banner.component.d.ts.map +1 -1
  84. package/dist/components/load-error-banner.component.js +68 -21
  85. package/dist/components/load-error-banner.component.js.map +1 -1
  86. package/dist/components/modal.component.d.ts +20 -3
  87. package/dist/components/modal.component.d.ts.map +1 -1
  88. package/dist/components/modal.component.js +40 -6
  89. package/dist/components/modal.component.js.map +1 -1
  90. package/dist/components/optimistic-toggle-button.component.d.ts +80 -19
  91. package/dist/components/optimistic-toggle-button.component.d.ts.map +1 -1
  92. package/dist/components/optimistic-toggle-button.component.js +86 -25
  93. package/dist/components/optimistic-toggle-button.component.js.map +1 -1
  94. package/dist/components/page-header.component.d.ts +5 -1
  95. package/dist/components/page-header.component.d.ts.map +1 -1
  96. package/dist/components/page-header.component.js +5 -1
  97. package/dist/components/page-header.component.js.map +1 -1
  98. package/dist/components/page-shell.component.d.ts +5 -1
  99. package/dist/components/page-shell.component.d.ts.map +1 -1
  100. package/dist/components/page-shell.component.js +5 -1
  101. package/dist/components/page-shell.component.js.map +1 -1
  102. package/dist/components/pagination.component.d.ts +15 -2
  103. package/dist/components/pagination.component.d.ts.map +1 -1
  104. package/dist/components/pagination.component.js +26 -5
  105. package/dist/components/pagination.component.js.map +1 -1
  106. package/dist/components/panel-close.component.d.ts +10 -1
  107. package/dist/components/panel-close.component.d.ts.map +1 -1
  108. package/dist/components/panel-close.component.js +1 -1
  109. package/dist/components/panel-close.component.js.map +1 -1
  110. package/dist/components/progress.component.d.ts +51 -8
  111. package/dist/components/progress.component.d.ts.map +1 -1
  112. package/dist/components/progress.component.js +26 -5
  113. package/dist/components/progress.component.js.map +1 -1
  114. package/dist/components/prompt-dialog.component.d.ts +59 -16
  115. package/dist/components/prompt-dialog.component.d.ts.map +1 -1
  116. package/dist/components/prompt-dialog.component.js +129 -41
  117. package/dist/components/prompt-dialog.component.js.map +1 -1
  118. package/dist/components/radio-group.component.d.ts +16 -2
  119. package/dist/components/radio-group.component.d.ts.map +1 -1
  120. package/dist/components/radio-group.component.js +28 -5
  121. package/dist/components/radio-group.component.js.map +1 -1
  122. package/dist/components/responsive-app-shell.component.d.ts +155 -31
  123. package/dist/components/responsive-app-shell.component.d.ts.map +1 -1
  124. package/dist/components/responsive-app-shell.component.js +163 -54
  125. package/dist/components/responsive-app-shell.component.js.map +1 -1
  126. package/dist/components/select.component.d.ts +29 -4
  127. package/dist/components/select.component.d.ts.map +1 -1
  128. package/dist/components/select.component.js +55 -9
  129. package/dist/components/select.component.js.map +1 -1
  130. package/dist/components/separator.component.d.ts +37 -7
  131. package/dist/components/separator.component.d.ts.map +1 -1
  132. package/dist/components/separator.component.js +33 -6
  133. package/dist/components/separator.component.js.map +1 -1
  134. package/dist/components/sidebar-user-card.component.d.ts +28 -7
  135. package/dist/components/sidebar-user-card.component.d.ts.map +1 -1
  136. package/dist/components/sidebar-user-card.component.js +1 -1
  137. package/dist/components/sidebar-user-card.component.js.map +1 -1
  138. package/dist/components/skeleton.component.d.ts +23 -4
  139. package/dist/components/skeleton.component.d.ts.map +1 -1
  140. package/dist/components/skeleton.component.js +34 -7
  141. package/dist/components/skeleton.component.js.map +1 -1
  142. package/dist/components/spinner.component.d.ts +15 -2
  143. package/dist/components/spinner.component.d.ts.map +1 -1
  144. package/dist/components/spinner.component.js +34 -6
  145. package/dist/components/spinner.component.js.map +1 -1
  146. package/dist/components/switch.component.d.ts +30 -7
  147. package/dist/components/switch.component.d.ts.map +1 -1
  148. package/dist/components/switch.component.js +56 -11
  149. package/dist/components/switch.component.js.map +1 -1
  150. package/dist/components/table.component.d.ts +29 -3
  151. package/dist/components/table.component.d.ts.map +1 -1
  152. package/dist/components/table.component.js +63 -8
  153. package/dist/components/table.component.js.map +1 -1
  154. package/dist/components/tabs.component.d.ts +18 -3
  155. package/dist/components/tabs.component.d.ts.map +1 -1
  156. package/dist/components/tabs.component.js +74 -39
  157. package/dist/components/tabs.component.js.map +1 -1
  158. package/dist/components/textarea.component.d.ts +29 -4
  159. package/dist/components/textarea.component.d.ts.map +1 -1
  160. package/dist/components/textarea.component.js +55 -9
  161. package/dist/components/textarea.component.js.map +1 -1
  162. package/dist/components/theme-toggle.component.d.ts +25 -6
  163. package/dist/components/theme-toggle.component.d.ts.map +1 -1
  164. package/dist/components/theme-toggle.component.js +1 -1
  165. package/dist/components/theme-toggle.component.js.map +1 -1
  166. package/dist/components/toast.component.d.ts +27 -6
  167. package/dist/components/toast.component.d.ts.map +1 -1
  168. package/dist/components/toast.component.js +48 -14
  169. package/dist/components/toast.component.js.map +1 -1
  170. package/dist/components/tooltip.component.d.ts +57 -5
  171. package/dist/components/tooltip.component.d.ts.map +1 -1
  172. package/dist/components/tooltip.component.js +103 -11
  173. package/dist/components/tooltip.component.js.map +1 -1
  174. package/dist/components/user-menu-popover.component.d.ts +68 -14
  175. package/dist/components/user-menu-popover.component.d.ts.map +1 -1
  176. package/dist/components/user-menu-popover.component.js +4 -4
  177. package/dist/components/user-menu-popover.component.js.map +1 -1
  178. package/dist/components/user-menu.component.d.ts +33 -9
  179. package/dist/components/user-menu.component.d.ts.map +1 -1
  180. package/dist/components/user-menu.component.js +1 -1
  181. package/dist/components/user-menu.component.js.map +1 -1
  182. package/dist/index.d.ts +4 -0
  183. package/dist/index.d.ts.map +1 -1
  184. package/dist/index.js +4 -0
  185. package/dist/index.js.map +1 -1
  186. package/dist/types.d.ts +1 -1
  187. package/dist/types.d.ts.map +1 -1
  188. package/dist/utilities/element-props.d.ts +78 -0
  189. package/dist/utilities/element-props.d.ts.map +1 -0
  190. package/dist/utilities/element-props.js +166 -0
  191. package/dist/utilities/element-props.js.map +1 -0
  192. package/dist/utilities/element.d.ts +34 -0
  193. package/dist/utilities/element.d.ts.map +1 -0
  194. package/dist/utilities/element.js +24 -0
  195. package/dist/utilities/element.js.map +1 -0
  196. package/dist/utilities/index.d.ts +2 -0
  197. package/dist/utilities/index.d.ts.map +1 -1
  198. package/dist/utilities/index.js +2 -0
  199. package/dist/utilities/index.js.map +1 -1
  200. package/dist/utilities/node-value.d.ts +1 -1
  201. package/dist/utilities/node-value.d.ts.map +1 -1
  202. package/dist/utilities/node-value.js +6 -2
  203. package/dist/utilities/node-value.js.map +1 -1
  204. package/dist/utilities/render-icon.d.ts +3 -2
  205. package/dist/utilities/render-icon.d.ts.map +1 -1
  206. package/dist/utilities/render-icon.js +6 -3
  207. package/dist/utilities/render-icon.js.map +1 -1
  208. package/dist/utilities/rest-attrs.d.ts +26 -2
  209. package/dist/utilities/rest-attrs.d.ts.map +1 -1
  210. package/dist/utilities/rest-attrs.js +37 -0
  211. package/dist/utilities/rest-attrs.js.map +1 -1
  212. package/package.json +4 -3
@@ -5,6 +5,7 @@
5
5
  */
6
6
  import { type AfterViewInit, ElementRef, type OnDestroy } from '@angular/core';
7
7
  import type { UIClassMap } from '@molecule/app-ui';
8
+ import { type HasElement } from '../utilities/element.js';
8
9
  import * as i0 from "@angular/core";
9
10
  /**
10
11
  * FormField component.
@@ -15,7 +16,7 @@ import * as i0 from "@angular/core";
15
16
  * registered on the host as a {@link FormFieldContext} that the field
16
17
  * components (`Input`, `Select`, `Textarea`, `Checkbox`) read.
17
18
  */
18
- export declare class FormField implements AfterViewInit, OnDestroy {
19
+ export declare class FormField implements AfterViewInit, OnDestroy, HasElement<HTMLDivElement> {
19
20
  /** Field label. */
20
21
  label?: string;
21
22
  /** Field name (drives the ids). */
@@ -32,6 +33,10 @@ export declare class FormField implements AfterViewInit, OnDestroy {
32
33
  style?: Record<string, unknown>;
33
34
  /** `data-testid`. */
34
35
  testId?: string;
36
+ /** `data-mol-id` automation id (React's `automationId`). */
37
+ automationId?: string;
38
+ /** A `data-mol-id` given as a plain rest attribute (React's `rootProps` precedence). */
39
+ dataMolId?: string;
35
40
  /** The projected-children capture point. */
36
41
  capture?: ElementRef<HTMLSpanElement>;
37
42
  /** The label's `for` target (the single child's control id, read after view init). */
@@ -39,6 +44,8 @@ export declare class FormField implements AfterViewInit, OnDestroy {
39
44
  /** A generated id used when `name` is absent (the normalizer renumbers it). */
40
45
  private readonly generatedId;
41
46
  private readonly host;
47
+ /** The element a caller's ref receives: the host `<div>`. */
48
+ readonly element: import("@angular/core").Signal<HTMLDivElement | null>;
42
49
  private readonly renderer;
43
50
  private readonly sync;
44
51
  /** Cached single-child determination (the capture empties at view init). */
@@ -80,6 +87,11 @@ export declare class FormField implements AfterViewInit, OnDestroy {
80
87
  * @returns The style attribute text.
81
88
  */
82
89
  hostStyle(): string | null;
90
+ /**
91
+ * The `data-mol-id` value (`automationId` wins over a rest `data-mol-id`).
92
+ * @returns The attribute value.
93
+ */
94
+ molId(): string | undefined;
83
95
  /**
84
96
  * The capture span (a view query before view init, a DOM lookup after —
85
97
  * the span lives directly under the host and is removed at view init).
@@ -106,6 +118,6 @@ export declare class FormField implements AfterViewInit, OnDestroy {
106
118
  /** Removes the context registration (unmount). */
107
119
  ngOnDestroy(): void;
108
120
  static ɵfac: i0.ɵɵFactoryDeclaration<FormField, never>;
109
- static ɵcmp: i0.ɵɵComponentDeclaration<FormField, "div[mol-form-field]", never, { "label": { "alias": "label"; "required": false; }; "name": { "alias": "name"; "required": false; }; "error": { "alias": "error"; "required": false; }; "hint": { "alias": "hint"; "required": false; }; "required": { "alias": "required"; "required": false; }; "className": { "alias": "className"; "required": false; }; "style": { "alias": "style"; "required": false; }; "testId": { "alias": "testId"; "required": false; }; }, {}, never, ["*"], true, never>;
121
+ static ɵcmp: i0.ɵɵComponentDeclaration<FormField, "div[mol-form-field]", never, { "label": { "alias": "label"; "required": false; }; "name": { "alias": "name"; "required": false; }; "error": { "alias": "error"; "required": false; }; "hint": { "alias": "hint"; "required": false; }; "required": { "alias": "required"; "required": false; }; "className": { "alias": "className"; "required": false; }; "style": { "alias": "style"; "required": false; }; "testId": { "alias": "testId"; "required": false; }; "automationId": { "alias": "automationId"; "required": false; }; "dataMolId": { "alias": "data-mol-id"; "required": false; }; }, {}, never, ["*"], true, never>;
110
122
  }
111
123
  //# sourceMappingURL=form-field.component.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"form-field.component.d.ts","sourceRoot":"","sources":["../../src/components/form-field.component.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EACL,KAAK,aAAa,EAElB,UAAU,EAEV,KAAK,SAAS,EAIf,MAAM,eAAe,CAAA;AAEtB,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;;AAYlD;;;;;;;;GAQG;AACH,qBAwBa,SAAU,YAAW,aAAa,EAAE,SAAS;IACxD,mBAAmB;IACnB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,mCAAmC;IACnC,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,mEAAmE;IACnE,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,0CAA0C;IAC1C,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,gDAAgD;IAChD,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,qCAAqC;IACrC,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,6CAA6C;IAC7C,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IAC/B,qBAAqB;IACrB,MAAM,CAAC,EAAE,MAAM,CAAA;IAEf,4CAA4C;IACtB,OAAO,CAAC,EAAE,UAAU,CAAC,eAAe,CAAC,CAAA;IAE3D,sFAAsF;IACtF,QAAQ,CAAC,QAAQ,iDAAa;IAE9B,+EAA+E;IAC/E,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAmB;IAC/C,OAAO,CAAC,QAAQ,CAAC,IAAI,CAA8C;IACnE,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAoB;IAC7C,OAAO,CAAC,QAAQ,CAAC,IAAI,CAA4C;IACjE,4EAA4E;IAC5E,OAAO,CAAC,WAAW,CAAuB;IAE1C,0EAA0E;;IAK1E;;;OAGG;IACH,EAAE,IAAI,UAAU;IAIhB;;;OAGG;IACH,OAAO,IAAI,MAAM;IAIjB;;;OAGG;IACH,IAAI,OAAO,IAAI,MAAM,CAEpB;IAED;;;OAGG;IACH,IAAI,MAAM,IAAI,MAAM,CAEnB;IAED;;;OAGG;IACH,iBAAiB,IAAI,MAAM,GAAG,SAAS;IAMvC;;;OAGG;IACH,OAAO,IAAI,MAAM;IAIjB;;;OAGG;IACH,SAAS,IAAI,MAAM,GAAG,IAAI;IAI1B;;;;OAIG;IACH,OAAO,CAAC,SAAS;IAOjB;;;;OAIG;IACH,WAAW,IAAI,OAAO;IAWtB;;;;OAIG;IACH,eAAe,IAAI,IAAI;IAqBvB;;;OAGG;IACH,OAAO,CAAC,kBAAkB;IAU1B,kDAAkD;IAClD,WAAW,IAAI,IAAI;yCApKR,SAAS;2CAAT,SAAS;CAuKrB"}
1
+ {"version":3,"file":"form-field.component.d.ts","sourceRoot":"","sources":["../../src/components/form-field.component.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EACL,KAAK,aAAa,EAElB,UAAU,EAEV,KAAK,SAAS,EAIf,MAAM,eAAe,CAAA;AAEtB,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAIlD,OAAO,EAAE,KAAK,UAAU,EAAe,MAAM,yBAAyB,CAAA;;AAStE;;;;;;;;GAQG;AACH,qBAoCa,SAAU,YAAW,aAAa,EAAE,SAAS,EAAE,UAAU,CAAC,cAAc,CAAC;IACpF,mBAAmB;IACnB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,mCAAmC;IACnC,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,mEAAmE;IACnE,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,0CAA0C;IAC1C,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,gDAAgD;IAChD,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,qCAA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;IAU1B,kDAAkD;IAClD,WAAW,IAAI,IAAI;yCAvLR,SAAS;2CAAT,SAAS;CA0LrB"}
@@ -6,6 +6,7 @@
6
6
  import { Component, ElementRef, inject, Renderer2, signal, ViewChild, } from '@angular/core';
7
7
  import { getClassMap } from '@molecule/app-ui';
8
8
  import { provideDomContext, removeDomContext } from '../utilities/dom-context.js';
9
+ import { hostElement } from '../utilities/element.js';
9
10
  import { nextInstanceId } from '../utilities/ids.js';
10
11
  import { styleText } from '../utilities/style.js';
11
12
  import { SlotWrapper } from './button.component.js';
@@ -74,6 +75,10 @@ export class FormField {
74
75
  style;
75
76
  /** `data-testid`. */
76
77
  testId;
78
+ /** `data-mol-id` automation id (React's `automationId`). */
79
+ automationId;
80
+ /** A `data-mol-id` given as a plain rest attribute (React's `rootProps` precedence). */
81
+ dataMolId;
77
82
  /** The projected-children capture point. */
78
83
  capture;
79
84
  /** The label's `for` target (the single child's control id, read after view init). */
@@ -82,6 +87,8 @@ export class FormField {
82
87
  /** A generated id used when `name` is absent (the normalizer renumbers it). */
83
88
  generatedId = nextInstanceId();
84
89
  host = inject(ElementRef);
90
+ /** The element a caller's ref receives: the host `<div>`. */
91
+ element = hostElement(this.host);
85
92
  renderer = inject(Renderer2);
86
93
  sync = new SlotWrapper(this.host, this.renderer);
87
94
  /** Cached single-child determination (the capture empties at view init). */
@@ -143,6 +150,16 @@ export class FormField {
143
150
  hostStyle() {
144
151
  return styleText(this.style);
145
152
  }
153
+ /**
154
+ * The `data-mol-id` value (`automationId` wins over a rest `data-mol-id`).
155
+ * @returns The attribute value.
156
+ */
157
+ molId() {
158
+ return (this.automationId ??
159
+ this.dataMolId ??
160
+ this.host.nativeElement.getAttribute('data-mol-id') ??
161
+ undefined);
162
+ }
146
163
  /**
147
164
  * The capture span (a view query before view init, a DOM lookup after —
148
165
  * the span lives directly under the host and is removed at view init).
@@ -222,11 +239,11 @@ export class FormField {
222
239
  } if (rf & 2) {
223
240
  let _t;
224
241
  i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.capture = _t.first);
225
- } }, hostVars: 5, hostBindings: function FormField_HostBindings(rf, ctx) { if (rf & 2) {
226
- i0.ɵɵattribute("data-testid", ctx.testId);
242
+ } }, hostVars: 6, hostBindings: function FormField_HostBindings(rf, ctx) { if (rf & 2) {
243
+ i0.ɵɵattribute("data-testid", ctx.testId)("data-mol-id", ctx.molId());
227
244
  i0.ɵɵstyleMap(ctx.hostStyle());
228
245
  i0.ɵɵclassMap(ctx.classes());
229
- } }, inputs: { label: "label", name: "name", error: "error", hint: "hint", required: "required", className: "className", style: "style", testId: "testId" }, ngContentSelectors: _c1, decls: 6, vars: 3, consts: [["capture", ""], [3, "class"], ["data-mol-field-capture", ""]], template: function FormField_Template(rf, ctx) { if (rf & 1) {
246
+ } }, inputs: { label: "label", name: "name", error: "error", hint: "hint", required: "required", className: "className", style: "style", testId: "testId", automationId: "automationId", dataMolId: [0, "data-mol-id", "dataMolId"] }, ngContentSelectors: _c1, decls: 6, vars: 3, consts: [["capture", ""], [3, "class"], ["data-mol-field-capture", ""]], template: function FormField_Template(rf, ctx) { if (rf & 1) {
230
247
  i0.ɵɵprojectionDef();
231
248
  i0.ɵɵconditionalCreate(0, FormField_Conditional_0_Template, 2, 6, "label", 1);
232
249
  i0.ɵɵdomElementStart(1, "span", 2, 0);
@@ -247,11 +264,23 @@ export class FormField {
247
264
  args: [{
248
265
  selector: 'div[mol-form-field]',
249
266
  standalone: true,
250
- inputs: ['label', 'name', 'error', 'hint', 'required', 'className', 'style', 'testId'],
267
+ inputs: [
268
+ 'label',
269
+ 'name',
270
+ 'error',
271
+ 'hint',
272
+ 'required',
273
+ 'className',
274
+ 'style',
275
+ 'testId',
276
+ 'automationId',
277
+ 'dataMolId: data-mol-id',
278
+ ],
251
279
  host: {
252
280
  '[class]': 'classes()',
253
281
  '[style]': 'hostStyle()',
254
282
  '[attr.data-testid]': 'testId',
283
+ '[attr.data-mol-id]': 'molId()',
255
284
  },
256
285
  template: `@if (label) {
257
286
  <label
@@ -272,7 +301,7 @@ export class FormField {
272
301
  type: ViewChild,
273
302
  args: ['capture']
274
303
  }] }); })();
275
- (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(FormField, { className: "FormField", filePath: "components/form-field.component.ts", lineNumber: 63 }); })();
304
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(FormField, { className: "FormField", filePath: "components/form-field.component.ts", lineNumber: 76 }); })();
276
305
  /** The field context a `FormField` registers (React's cloned child props). */
277
306
  class FormFieldContextValue {
278
307
  field;
@@ -1 +1 @@
1
- {"version":3,"file":"form-field.component.js","sourceRoot":"","sources":["../../src/components/form-field.component.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAEL,SAAS,EACT,UAAU,EACV,MAAM,EAEN,SAAS,EACT,MAAM,EACN,SAAS,GACV,MAAM,eAAe,CAAA;AAGtB,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAE9C,OAAO,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAA;AAEjF,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAA;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAA;AACjD,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAA;;;;;;IAwB7C,gCAGG;IAAA,YAAW;IAAA,oBACb;;;IAFC,uHAAwE;;IACvE,cAAW;IAAX,kCAAW;;;IAKd,4BAAgD;IAAA,YAAW;IAAA,oBAAI;;;IAAxC,oCAAwB;;IAAC,cAAW;IAAX,kCAAW;;;IAG3D,4BAA8C;IAAA,YAAU;IAAA,oBAAI;;;IAAtC,mCAAuB;;IAAC,cAAU;IAAV,iCAAU;;AAjC9D,2DAA2D;AAC3D,MAAM,cAAc,GAAG,yBAAyB,CAAA;AAEhD;;;;;;;;GAQG;AAyBH,MAAM,OAAO,SAAS;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B;gBACD,QAAQ,EAAE;;;;;;;;;;;;;MAaN;aACL;;kBAoBE,SAAS;mBAAC,SAAS;;kFAnBT,SAAS;AAyKtB,8EAA8E;AAC9E,MAAM,qBAAqB;IAMI;IAL7B;;;;OAIG;IACH,YAA6B,KAAgB;QAAhB,UAAK,GAAL,KAAK,CAAW;IAAG,CAAC;IAEjD,qDAAqD;IACrD,IAAI,EAAE;QACJ,OAAO,IAAI,CAAC,KAAK,CAAC,WAAW,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,SAAS,CAAA;IACpE,CAAC;IAED,8DAA8D;IAC9D,IAAI,WAAW;QACb,OAAO,IAAI,CAAC,KAAK,CAAC,WAAW,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,iBAAiB,EAAE,CAAC,CAAC,CAAC,SAAS,CAAA;IAC9E,CAAC;IAED,qEAAqE;IACrE,IAAI,OAAO;QACT,OAAO,IAAI,CAAC,KAAK,CAAC,WAAW,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,SAAS,CAAA;IAClE,CAAC;CACF"}
1
+ {"version":3,"file":"form-field.component.js","sourceRoot":"","sources":["../../src/components/form-field.component.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAEL,SAAS,EACT,UAAU,EACV,MAAM,EAEN,SAAS,EACT,MAAM,EACN,SAAS,GACV,MAAM,eAAe,CAAA;AAGtB,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAE9C,OAAO,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAA;AACjF,OAAO,EAAmB,WAAW,EAAE,MAAM,yBAAyB,CAAA;AAEtE,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAA;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAA;AACjD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AO,IAAI,CAAC,KAAK,CAAC,WAAW,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,iBAAiB,EAAE,CAAC,CAAC,CAAC,SAAS,CAAA;IAC9E,CAAC;IAED,qEAAqE;IACrE,IAAI,OAAO;QACT,OAAO,IAAI,CAAC,KAAK,CAAC,WAAW,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,SAAS,CAAA;IAClE,CAAC;CACF"}
@@ -1,5 +1,18 @@
1
- import type { UIClassMap } from '@molecule/app-ui';
1
+ import type { FormProps, UIClassMap } from '@molecule/app-ui';
2
+ import { type HasElement } from '../utilities/element.js';
2
3
  import * as i0 from "@angular/core";
4
+ /**
5
+ * Props for {@link Form} (React's `ReactFormProps`, in Angular's form).
6
+ *
7
+ * React's form adds one prop to the core `FormProps`: a failure managed by an
8
+ * external form controller (`useForm().formState.submitError`). Binding the
9
+ * `submitError` input is the Angular equivalent — the form then renders the
10
+ * same accessible server-error list instead of the failure it captured.
11
+ */
12
+ export interface ReactFormProps extends FormProps {
13
+ /** A rejected submission, for example useForm().formState.submitError. */
14
+ submitError?: unknown;
15
+ }
3
16
  /**
4
17
  * Form component.
5
18
  *
@@ -8,35 +21,63 @@ import * as i0 from "@angular/core";
8
21
  * default; a new submit clears the previous failure. Native action/method
9
22
  * forms keep native submission.
10
23
  */
11
- export declare class Form {
24
+ export declare class Form implements HasElement<HTMLFormElement> {
12
25
  /** Collects the form's data on submit (React's `onFormSubmit`). */
13
- onFormSubmit?: (data: Record<string, unknown>) => void | Promise<void>;
26
+ onFormSubmit?: ReactFormProps['onFormSubmit'];
14
27
  /** Receives the submit event (React's `onSubmit`). */
15
- onSubmit?: (event: Event) => void | Promise<void>;
28
+ onSubmit?: ReactFormProps['onSubmit'];
16
29
  /** Receives the reset event (React's `onReset`). */
17
- onReset?: (event: Event) => void;
30
+ onReset?: ReactFormProps['onReset'];
18
31
  /** Whether the form is submitting (disables the fieldset). */
19
- submitting?: boolean;
20
- /** A failure managed by an external form controller. */
21
- submitError?: unknown;
32
+ submitting?: ReactFormProps['submitting'];
22
33
  /** Native form action. */
23
- action?: string;
34
+ action?: ReactFormProps['action'];
24
35
  /** Native form method. */
25
- method?: string;
36
+ method?: ReactFormProps['method'];
26
37
  /** Whether native validation is disabled. */
27
- noValidate?: boolean;
38
+ noValidate?: ReactFormProps['noValidate'];
28
39
  /** Extra classes for the form. */
29
- className?: string;
40
+ className?: ReactFormProps['className'];
30
41
  /** Inline style object (React camelCase). */
31
- style?: Record<string, unknown>;
42
+ style?: ReactFormProps['style'];
32
43
  /** `data-testid`. */
33
- testId?: string;
44
+ testId?: ReactFormProps['testId'];
45
+ /** `data-mol-id` automation id (React's `automationId`). */
46
+ automationId?: ReactFormProps['automationId'];
47
+ /** A `data-mol-id` given as a plain rest attribute (React's `rootProps` precedence). */
48
+ dataMolId?: string;
34
49
  /** Whether a submit is in flight. */
35
50
  readonly pending: import("@angular/core").WritableSignal<boolean>;
36
51
  /** The failure the last submit produced. */
37
52
  private readonly failure;
38
53
  /** A submit counter: a later submit supersedes an earlier settling one. */
39
54
  private attempt;
55
+ /** The controlled failure's current value. */
56
+ private controlledError;
57
+ /** Whether the caller has written `submitError` (React's `Object.hasOwn`). */
58
+ private controlled;
59
+ private readonly host;
60
+ /** The element a caller's ref receives: the host `<form>`. */
61
+ readonly element: import("@angular/core").Signal<HTMLFormElement | null>;
62
+ /**
63
+ * A failure managed by an external form controller (React's `submitError`
64
+ * prop).
65
+ *
66
+ * An accessor, not a field: Angular writes an input by assigning the
67
+ * property, so the write itself is the "this prop was passed" signal React
68
+ * reads with `Object.hasOwn(props, 'submitError')`. A caller that binds
69
+ * `[submitError]` therefore owns the error UI — an explicit `undefined`
70
+ * clears a failure the form captured itself.
71
+ *
72
+ * @returns The controlled failure, as the caller last wrote it.
73
+ */
74
+ get submitError(): ReactFormProps['submitError'];
75
+ /**
76
+ * Records the caller's controlled failure (and that the caller passed one).
77
+ *
78
+ * @param value - The caller's failure, or `undefined` to clear the error UI.
79
+ */
80
+ set submitError(value: ReactFormProps['submitError']);
40
81
  /**
41
82
  * Reactive translation, read in the injection context. Its `t` reads the
42
83
  * locale, so the view re-renders the text on a locale switch (the static `t`
@@ -53,6 +94,11 @@ export declare class Form {
53
94
  * @returns The style attribute text.
54
95
  */
55
96
  hostStyle(): string | null;
97
+ /**
98
+ * The `data-mol-id` value (`automationId` wins over a rest `data-mol-id`).
99
+ * @returns The attribute value.
100
+ */
101
+ molId(): string | undefined;
56
102
  /**
57
103
  * The error messages to announce (React's `submitError`/`failure` branch).
58
104
  * @returns The messages.
@@ -72,6 +118,6 @@ export declare class Form {
72
118
  */
73
119
  handleReset(event: Event): void;
74
120
  static ɵfac: i0.ɵɵFactoryDeclaration<Form, never>;
75
- static ɵcmp: i0.ɵɵComponentDeclaration<Form, "form[mol-form]", never, { "onFormSubmit": { "alias": "onFormSubmit"; "required": false; }; "onSubmit": { "alias": "onSubmit"; "required": false; }; "onReset": { "alias": "onReset"; "required": false; }; "submitting": { "alias": "submitting"; "required": false; }; "submitError": { "alias": "submitError"; "required": false; }; "action": { "alias": "action"; "required": false; }; "method": { "alias": "method"; "required": false; }; "noValidate": { "alias": "noValidate"; "required": false; }; "className": { "alias": "className"; "required": false; }; "style": { "alias": "style"; "required": false; }; "testId": { "alias": "testId"; "required": false; }; }, {}, never, ["*"], true, never>;
121
+ static ɵcmp: i0.ɵɵComponentDeclaration<Form, "form[mol-form]", never, { "onFormSubmit": { "alias": "onFormSubmit"; "required": false; }; "onSubmit": { "alias": "onSubmit"; "required": false; }; "onReset": { "alias": "onReset"; "required": false; }; "submitting": { "alias": "submitting"; "required": false; }; "submitError": { "alias": "submitError"; "required": false; }; "action": { "alias": "action"; "required": false; }; "method": { "alias": "method"; "required": false; }; "noValidate": { "alias": "noValidate"; "required": false; }; "className": { "alias": "className"; "required": false; }; "style": { "alias": "style"; "required": false; }; "testId": { "alias": "testId"; "required": false; }; "automationId": { "alias": "automationId"; "required": false; }; "dataMolId": { "alias": "data-mol-id"; "required": false; }; }, {}, never, ["*"], true, never>;
76
122
  }
77
123
  //# sourceMappingURL=form.component.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"form.component.d.ts","sourceRoot":"","sources":["../../src/components/form.component.ts"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;;AAMlD;;;;;;;GAOG;AACH,qBAwCa,IAAI;IACf,mEAAmE;IACnE,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAA;IACtE,sDAAsD;IACtD,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAA;IACjD,oDAAoD;IACpD,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,CAAA;IAChC,8DAA8D;IAC9D,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,wDAAwD;IACxD,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,0BAA0B;IAC1B,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,0BAA0B;IAC1B,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,6CAA6C;IAC7C,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,kCAAkC;IAClC,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,6CAA6C;IAC7C,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IAC/B,qBAAqB;IACrB,MAAM,CAAC,EAAE,MAAM,CAAA;IAEf,qCAAqC;IACrC,QAAQ,CAAC,OAAO,kDAAgB;IAChC,4CAA4C;IAC5C,OAAO,CAAC,QAAQ,CAAC,OAAO,CAA0C;IAClE,2EAA2E;IAC3E,OAAO,CAAC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K,EAAE,KAAK,GAAG,IAAI;yCAxKpB,IAAI;2CAAJ,IAAI;CA2KhB"}
@@ -3,9 +3,10 @@
3
3
  *
4
4
  * @module
5
5
  */
6
- import { Component, signal } from '@angular/core';
6
+ import { Component, ElementRef, inject, signal } from '@angular/core';
7
7
  import { useTranslation } from '@molecule/app-angular';
8
8
  import { getClassMap } from '@molecule/app-ui';
9
+ import { hostElement } from '../utilities/element.js';
9
10
  import { formSubmitErrorMessages } from '../utilities/form-submit-error.js';
10
11
  import { styleText } from '../utilities/style.js';
11
12
  import * as i0 from "@angular/core";
@@ -46,8 +47,6 @@ export class Form {
46
47
  onReset;
47
48
  /** Whether the form is submitting (disables the fieldset). */
48
49
  submitting;
49
- /** A failure managed by an external form controller. */
50
- submitError;
51
50
  /** Native form action. */
52
51
  action;
53
52
  /** Native form method. */
@@ -60,6 +59,10 @@ export class Form {
60
59
  style;
61
60
  /** `data-testid`. */
62
61
  testId;
62
+ /** `data-mol-id` automation id (React's `automationId`). */
63
+ automationId;
64
+ /** A `data-mol-id` given as a plain rest attribute (React's `rootProps` precedence). */
65
+ dataMolId;
63
66
  /** Whether a submit is in flight. */
64
67
  pending = signal(false, /* @ts-ignore */
65
68
  ...(ngDevMode ? [{ debugName: "pending" }] : /* istanbul ignore next */ []));
@@ -68,6 +71,37 @@ export class Form {
68
71
  ...(ngDevMode ? [{ debugName: "failure" }] : /* istanbul ignore next */ []));
69
72
  /** A submit counter: a later submit supersedes an earlier settling one. */
70
73
  attempt = 0;
74
+ /** The controlled failure's current value. */
75
+ controlledError;
76
+ /** Whether the caller has written `submitError` (React's `Object.hasOwn`). */
77
+ controlled = false;
78
+ host = inject(ElementRef);
79
+ /** The element a caller's ref receives: the host `<form>`. */
80
+ element = hostElement(this.host);
81
+ /**
82
+ * A failure managed by an external form controller (React's `submitError`
83
+ * prop).
84
+ *
85
+ * An accessor, not a field: Angular writes an input by assigning the
86
+ * property, so the write itself is the "this prop was passed" signal React
87
+ * reads with `Object.hasOwn(props, 'submitError')`. A caller that binds
88
+ * `[submitError]` therefore owns the error UI — an explicit `undefined`
89
+ * clears a failure the form captured itself.
90
+ *
91
+ * @returns The controlled failure, as the caller last wrote it.
92
+ */
93
+ get submitError() {
94
+ return this.controlledError;
95
+ }
96
+ /**
97
+ * Records the caller's controlled failure (and that the caller passed one).
98
+ *
99
+ * @param value - The caller's failure, or `undefined` to clear the error UI.
100
+ */
101
+ set submitError(value) {
102
+ this.controlled = true;
103
+ this.controlledError = value;
104
+ }
71
105
  /**
72
106
  * Reactive translation, read in the injection context. Its `t` reads the
73
107
  * locale, so the view re-renders the text on a locale switch (the static `t`
@@ -88,18 +122,32 @@ export class Form {
88
122
  hostStyle() {
89
123
  return styleText(this.style);
90
124
  }
125
+ /**
126
+ * The `data-mol-id` value (`automationId` wins over a rest `data-mol-id`).
127
+ * @returns The attribute value.
128
+ */
129
+ molId() {
130
+ return (this.automationId ??
131
+ this.dataMolId ??
132
+ this.host.nativeElement.getAttribute('data-mol-id') ??
133
+ undefined);
134
+ }
91
135
  /**
92
136
  * The error messages to announce (React's `submitError`/`failure` branch).
93
137
  * @returns The messages.
94
138
  */
95
139
  messages() {
96
- // Angular has no "prop was passed" signal; an explicitly-present
97
- // `submitError` is the external-controller form, absent means the
98
- // component owns the failure (React's `Object.hasOwn(props, …)`).
99
- const error = this.submitError !== undefined ? { error: this.submitError } : this.failure();
100
- if (!error)
140
+ // React's `Object.hasOwn(props, 'submitError')` branch: once the caller
141
+ // binds the input, it owns the error UI — an explicitly-undefined value
142
+ // clears the list instead of falling back to a captured failure.
143
+ const failure = this.controlled
144
+ ? this.controlledError === undefined
145
+ ? null
146
+ : { error: this.controlledError }
147
+ : this.failure();
148
+ if (!failure)
101
149
  return [];
102
- return formSubmitErrorMessages(error.error, this.i18n.t('ui.form.submitError', undefined, {
150
+ return formSubmitErrorMessages(failure.error, this.i18n.t('ui.form.submitError', undefined, {
103
151
  defaultValue: 'Unable to submit. Please try again.',
104
152
  }));
105
153
  }
@@ -125,7 +173,7 @@ export class Form {
125
173
  submissions.push(Promise.reject(error));
126
174
  }
127
175
  };
128
- const form = event.currentTarget;
176
+ const form = event.currentTarget instanceof HTMLFormElement ? event.currentTarget : null;
129
177
  if (this.onFormSubmit) {
130
178
  event.preventDefault();
131
179
  const formData = new FormData(form ?? undefined);
@@ -156,13 +204,13 @@ export class Form {
156
204
  this.onReset?.(event);
157
205
  }
158
206
  static ɵfac = function Form_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || Form)(); };
159
- static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: Form, selectors: [["form", "mol-form", ""]], hostVars: 8, hostBindings: function Form_HostBindings(rf, ctx) { if (rf & 1) {
207
+ static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: Form, selectors: [["form", "mol-form", ""]], hostVars: 9, hostBindings: function Form_HostBindings(rf, ctx) { if (rf & 1) {
160
208
  i0.ɵɵlistener("submit", function Form_submit_HostBindingHandler($event) { return ctx.handleSubmit($event); })("reset", function Form_reset_HostBindingHandler($event) { return ctx.handleReset($event); });
161
209
  } if (rf & 2) {
162
- i0.ɵɵattribute("data-testid", ctx.testId)("action", ctx.action ?? null, i0.ɵɵsanitizeUrlOrResourceUrl)("method", ctx.method ?? null)("novalidate", ctx.noValidate ? "" : null);
210
+ i0.ɵɵattribute("data-testid", ctx.testId)("data-mol-id", ctx.molId())("action", ctx.action ?? null, i0.ɵɵsanitizeUrlOrResourceUrl)("method", ctx.method ?? null)("novalidate", ctx.noValidate ? "" : null);
163
211
  i0.ɵɵstyleMap(ctx.hostStyle());
164
212
  i0.ɵɵclassMap(ctx.className);
165
- } }, inputs: { onFormSubmit: "onFormSubmit", onSubmit: "onSubmit", onReset: "onReset", submitting: "submitting", submitError: "submitError", action: "action", method: "method", noValidate: "noValidate", className: "className", style: "style", testId: "testId" }, ngContentSelectors: _c0, decls: 3, vars: 4, consts: [["role", "alert", 3, "class"], ["role", "alert"]], template: function Form_Template(rf, ctx) { if (rf & 1) {
213
+ } }, inputs: { onFormSubmit: "onFormSubmit", onSubmit: "onSubmit", onReset: "onReset", submitting: "submitting", submitError: "submitError", action: "action", method: "method", noValidate: "noValidate", className: "className", style: "style", testId: "testId", automationId: "automationId", dataMolId: [0, "data-mol-id", "dataMolId"] }, ngContentSelectors: _c0, decls: 3, vars: 4, consts: [["role", "alert", 3, "class"], ["role", "alert"]], template: function Form_Template(rf, ctx) { if (rf & 1) {
166
214
  i0.ɵɵprojectionDef();
167
215
  i0.ɵɵconditionalCreate(0, Form_Conditional_0_Template, 3, 2, "ul", 0);
168
216
  i0.ɵɵdomElementStart(1, "fieldset");
@@ -192,11 +240,14 @@ export class Form {
192
240
  'className',
193
241
  'style',
194
242
  'testId',
243
+ 'automationId',
244
+ 'dataMolId: data-mol-id',
195
245
  ],
196
246
  host: {
197
247
  '[class]': 'className',
198
248
  '[style]': 'hostStyle()',
199
249
  '[attr.data-testid]': 'testId',
250
+ '[attr.data-mol-id]': 'molId()',
200
251
  '[attr.action]': 'action ?? null',
201
252
  '[attr.method]': 'method ?? null',
202
253
  '[attr.novalidate]': 'noValidate ? "" : null',
@@ -218,5 +269,5 @@ export class Form {
218
269
  </fieldset>`,
219
270
  }]
220
271
  }], null, null); })();
221
- (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(Form, { className: "Form", filePath: "components/form.component.ts", lineNumber: 64 }); })();
272
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(Form, { className: "Form", filePath: "components/form.component.ts", lineNumber: 81 }); })();
222
273
  //# sourceMappingURL=form.component.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"form.component.js","sourceRoot":"","sources":["../../src/components/form.component.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AAEjD,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAA;AAE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tB,cAAA,eAAW,CAAP;YAAJ,4BAAI;;;YAdJ,qEAA6B;YAOtC,mCAGC;YACC,kBAAyB;YAC3B,oBAAW;;YAZF,oDAMR;YAEC,cAAmC;YAAnC,4CAAmC;;;;iFAM5B,IAAI;cA3ChB,SAAS;eAAC;gBACT,QAAQ,EAAE,gBAAgB;gBAC1B,UAAU,EAAE,IAAI;gBAChB,MAAM,EAAE;oBACN,cAAc;oBACd,UAAU;oBACV,SAAS;oBACT,YAAY;oBACZ,aAAa;oBACb,QAAQ;oBACR,QAAQ;oBACR,YAAY;oBACZ,WAAW;oBACX,OAAO;oBACP,QAAQ;oBACR,cAAc;oBACd,wBAAwB;iBACzB;gBACD,IAAI,EAAE;oBACJ,SAAS,EAAE,WAAW;oBACtB,SAAS,EAAE,aAAa;oBACxB,oBAAoB,EAAE,QAAQ;oBAC9B,oBAAoB,EAAE,SAAS;oBAC/B,eAAe,EAAE,gBAAgB;oBACjC,eAAe,EAAE,gBAAgB;oBACjC,mBAAmB,EAAE,wBAAwB;oBAC7C,UAAU,EAAE,sBAAsB;oBAClC,SAAS,EAAE,qBAAqB;iBACjC;gBACD,QAAQ,EAAE;;;;;;;;;;;;gBAYI;aACf;;kFACY,IAAI"}
@@ -6,6 +6,24 @@
6
6
  import { ElementRef, type OnChanges } from '@angular/core';
7
7
  import { type IconData, type IconName } from '@molecule/app-icons';
8
8
  import * as i0 from "@angular/core";
9
+ /**
10
+ * Props for {@link Icon} (React's `IconProps`, in Angular's form).
11
+ *
12
+ * React extends `SVGProps<SVGSVGElement>` so any SVG attribute reaches the
13
+ * `<svg>`; the host IS the `<svg>`, so extra `data-*`, `aria-*`, `role` and
14
+ * event attributes spread onto it exactly as React spreads them. The named
15
+ * props are typed here.
16
+ */
17
+ export interface IconProps {
18
+ /** The glyph name from the bonded icon set. */
19
+ name: IconName;
20
+ /** Width and height in pixels (default 20). */
21
+ size?: number;
22
+ /** Class name forwarded to the `<svg>`. */
23
+ className?: string;
24
+ /** Explicit `aria-hidden` (React keeps `false` as the string `"false"`). */
25
+ 'aria-hidden'?: boolean | string;
26
+ }
9
27
  /**
10
28
  * Icon component.
11
29
  *
@@ -16,16 +34,16 @@ import * as i0 from "@angular/core";
16
34
  */
17
35
  export declare class Icon implements OnChanges {
18
36
  /** The glyph name from the bonded icon set. */
19
- name: IconName;
37
+ name: IconProps['name'];
20
38
  /** Width and height in pixels (default 20). */
21
- size: number;
39
+ size?: IconProps['size'];
22
40
  /** Class name forwarded to the `<svg>`. */
23
- className?: string;
41
+ className?: IconProps['className'];
24
42
  /**
25
43
  * Explicit `aria-hidden` (React stringifies `false` to `"false"` rather
26
44
  * than dropping the attribute).
27
45
  */
28
- ariaHidden?: boolean | string;
46
+ ariaHidden?: IconProps['aria-hidden'];
29
47
  /** Whether the name is missing from the bonded set (placeholder renders). */
30
48
  failed: boolean;
31
49
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"icon.component.d.ts","sourceRoot":"","sources":["../../src/components/icon.component.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAa,UAAU,EAAU,KAAK,SAAS,EAAE,MAAM,eAAe,CAAA;AAE7E,OAAO,EAAW,KAAK,QAAQ,EAAE,KAAK,QAAQ,EAAE,MAAM,qBAAqB,CAAA;;AAE3E;;;;;;;GAOG;AACH,qBA+Ba,IAAK,YAAW,SAAS;IACpC,+CAA+C;IAC/C,IAAI,EAAG,QAAQ,CAAA;IACf,+CAA+C;IAC/C,IAAI,SAAK;IACT,2CAA2C;IAC3C,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB;;;OAGG;IACH,UAAU,CAAC,EAAE,OAAO,GAAG,MAAM,CAAA;IAE7B,6EAA6E;IAC7E,MAAM,UAAQ;IAEd;;;;OAIG;IACH,QAAQ,IAAI,MAAM;IAIlB;;OAEG;IACH,WAAW,IAAI,IAAI;IAgBnB,OAAO,CAAC,QAAQ,CAAC,CAAU;IAE3B;;;OAGG;IACH,IAAI,IAAI,QAAQ;IAIhB;;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AS,CAAC,WAAW,CAAC,CAAA;IAClC;;;OAGG;IACH,UAAU,CAAC,EAAE,SAAS,CAAC,aAAa,CAAC,CAAA;IAErC,6EAA6E;IAC7E,MAAM,UAAQ;IAEd;;;;OAIG;IACH,QAAQ,IAAI,MAAM;IAIlB;;OAEG;IACH,WAAW,IAAI,IAAI;IAgBnB,OAAO,CAAC,QAAQ,CAAC,CAAU;IAE3B;;;OAGG;IACH,IAAI,IAAI,QAAQ;IAIhB;;;;OAIG;IACH,IAAI,IAAI,MAAM;IAMd;;;OAGG;IACH,WAAW,IAAI;QACb,MAAM,EAAE,MAAM,GAAG,IAAI,CAAA;QACrB,WAAW,EAAE,MAAM,GAAG,IAAI,CAAA;QAC1B,aAAa,EAAE,MAAM,GAAG,IAAI,CAAA;QAC5B,cAAc,EAAE,MAAM,GAAG,IAAI,CAAA;KAC9B;IAaD;;;OAGG;IACH,KAAK,IAAI,QAAQ,CAAC,OAAO,CAAC;IAI1B;;;;OAIG;IACH,UAAU,IAAI,OAAO;IASrB;;;;OAIG;IACH,cAAc,IAAI,MAAM,GAAG,IAAI;IAU/B,4BAA4B;IAC5B,QAAQ,CAAC,IAAI,EAAE,UAAU,CAAC,aAAa,CAAC,CAAqB;yCA7HlD,IAAI;2CAAJ,IAAI;CA8HhB"}
@@ -183,5 +183,5 @@ export class Icon {
183
183
  }`,
184
184
  }]
185
185
  }], null, null); })();
186
- (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(Icon, { className: "Icon", filePath: "components/icon.component.ts", lineNumber: 50 }); })();
186
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(Icon, { className: "Icon", filePath: "components/icon.component.ts", lineNumber: 69 }); })();
187
187
  //# sourceMappingURL=icon.component.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"icon.component.js","sourceRoot":"","sources":["../../src/components/icon.component.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE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