avero-ui 0.0.0-stage → 0.0.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 (237) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +1043 -2
  3. package/fesm2022/avero-ui-accordion.mjs +515 -0
  4. package/fesm2022/avero-ui-accordion.mjs.map +1 -0
  5. package/fesm2022/avero-ui-animate-on-scroll.mjs +223 -0
  6. package/fesm2022/avero-ui-animate-on-scroll.mjs.map +1 -0
  7. package/fesm2022/avero-ui-auto-complete.mjs +638 -0
  8. package/fesm2022/avero-ui-auto-complete.mjs.map +1 -0
  9. package/fesm2022/avero-ui-auto-focus.mjs +88 -0
  10. package/fesm2022/avero-ui-auto-focus.mjs.map +1 -0
  11. package/fesm2022/avero-ui-avatar.mjs +274 -0
  12. package/fesm2022/avero-ui-avatar.mjs.map +1 -0
  13. package/fesm2022/avero-ui-badge.mjs +278 -0
  14. package/fesm2022/avero-ui-badge.mjs.map +1 -0
  15. package/fesm2022/avero-ui-bind.mjs +103 -0
  16. package/fesm2022/avero-ui-bind.mjs.map +1 -0
  17. package/fesm2022/avero-ui-block-ui.mjs +175 -0
  18. package/fesm2022/avero-ui-block-ui.mjs.map +1 -0
  19. package/fesm2022/avero-ui-breadcrumb.mjs +187 -0
  20. package/fesm2022/avero-ui-breadcrumb.mjs.map +1 -0
  21. package/fesm2022/avero-ui-button.mjs +118 -0
  22. package/fesm2022/avero-ui-button.mjs.map +1 -0
  23. package/fesm2022/avero-ui-calendar.mjs +412 -0
  24. package/fesm2022/avero-ui-calendar.mjs.map +1 -0
  25. package/fesm2022/avero-ui-card.mjs +305 -0
  26. package/fesm2022/avero-ui-card.mjs.map +1 -0
  27. package/fesm2022/avero-ui-carousel.mjs +390 -0
  28. package/fesm2022/avero-ui-carousel.mjs.map +1 -0
  29. package/fesm2022/avero-ui-cascade-select.mjs +771 -0
  30. package/fesm2022/avero-ui-cascade-select.mjs.map +1 -0
  31. package/fesm2022/avero-ui-chart.mjs +361 -0
  32. package/fesm2022/avero-ui-chart.mjs.map +1 -0
  33. package/fesm2022/avero-ui-checkbox.mjs +279 -0
  34. package/fesm2022/avero-ui-checkbox.mjs.map +1 -0
  35. package/fesm2022/avero-ui-chip.mjs +256 -0
  36. package/fesm2022/avero-ui-chip.mjs.map +1 -0
  37. package/fesm2022/avero-ui-class-names.mjs +80 -0
  38. package/fesm2022/avero-ui-class-names.mjs.map +1 -0
  39. package/fesm2022/avero-ui-color-picker.mjs +665 -0
  40. package/fesm2022/avero-ui-color-picker.mjs.map +1 -0
  41. package/fesm2022/avero-ui-confirm-dialog.mjs +561 -0
  42. package/fesm2022/avero-ui-confirm-dialog.mjs.map +1 -0
  43. package/fesm2022/avero-ui-confirm-popup.mjs +406 -0
  44. package/fesm2022/avero-ui-confirm-popup.mjs.map +1 -0
  45. package/fesm2022/avero-ui-context-menu.mjs +409 -0
  46. package/fesm2022/avero-ui-context-menu.mjs.map +1 -0
  47. package/fesm2022/avero-ui-core.mjs +38 -0
  48. package/fesm2022/avero-ui-core.mjs.map +1 -0
  49. package/fesm2022/avero-ui-data-view.mjs +312 -0
  50. package/fesm2022/avero-ui-data-view.mjs.map +1 -0
  51. package/fesm2022/avero-ui-dialog.mjs +595 -0
  52. package/fesm2022/avero-ui-dialog.mjs.map +1 -0
  53. package/fesm2022/avero-ui-divider.mjs +119 -0
  54. package/fesm2022/avero-ui-divider.mjs.map +1 -0
  55. package/fesm2022/avero-ui-dock.mjs +243 -0
  56. package/fesm2022/avero-ui-dock.mjs.map +1 -0
  57. package/fesm2022/avero-ui-drawer.mjs +577 -0
  58. package/fesm2022/avero-ui-drawer.mjs.map +1 -0
  59. package/fesm2022/avero-ui-dropdown.mjs +510 -0
  60. package/fesm2022/avero-ui-dropdown.mjs.map +1 -0
  61. package/fesm2022/avero-ui-dynamic-dialog.mjs +268 -0
  62. package/fesm2022/avero-ui-dynamic-dialog.mjs.map +1 -0
  63. package/fesm2022/avero-ui-fieldset.mjs +354 -0
  64. package/fesm2022/avero-ui-fieldset.mjs.map +1 -0
  65. package/fesm2022/avero-ui-file-upload.mjs +658 -0
  66. package/fesm2022/avero-ui-file-upload.mjs.map +1 -0
  67. package/fesm2022/avero-ui-fluid.mjs +147 -0
  68. package/fesm2022/avero-ui-fluid.mjs.map +1 -0
  69. package/fesm2022/avero-ui-focus-trap.mjs +120 -0
  70. package/fesm2022/avero-ui-focus-trap.mjs.map +1 -0
  71. package/fesm2022/avero-ui-galleria.mjs +523 -0
  72. package/fesm2022/avero-ui-galleria.mjs.map +1 -0
  73. package/fesm2022/avero-ui-icon-field.mjs +99 -0
  74. package/fesm2022/avero-ui-icon-field.mjs.map +1 -0
  75. package/fesm2022/avero-ui-image-compare.mjs +274 -0
  76. package/fesm2022/avero-ui-image-compare.mjs.map +1 -0
  77. package/fesm2022/avero-ui-image.mjs +397 -0
  78. package/fesm2022/avero-ui-image.mjs.map +1 -0
  79. package/fesm2022/avero-ui-input-group.mjs +79 -0
  80. package/fesm2022/avero-ui-input-group.mjs.map +1 -0
  81. package/fesm2022/avero-ui-input-mask.mjs +678 -0
  82. package/fesm2022/avero-ui-input-mask.mjs.map +1 -0
  83. package/fesm2022/avero-ui-input-number.mjs +390 -0
  84. package/fesm2022/avero-ui-input-number.mjs.map +1 -0
  85. package/fesm2022/avero-ui-input-otp.mjs +541 -0
  86. package/fesm2022/avero-ui-input-otp.mjs.map +1 -0
  87. package/fesm2022/avero-ui-input.mjs +140 -0
  88. package/fesm2022/avero-ui-input.mjs.map +1 -0
  89. package/fesm2022/avero-ui-knob.mjs +436 -0
  90. package/fesm2022/avero-ui-knob.mjs.map +1 -0
  91. package/fesm2022/avero-ui-mega-menu.mjs +431 -0
  92. package/fesm2022/avero-ui-mega-menu.mjs.map +1 -0
  93. package/fesm2022/avero-ui-menu.mjs +398 -0
  94. package/fesm2022/avero-ui-menu.mjs.map +1 -0
  95. package/fesm2022/avero-ui-menubar.mjs +387 -0
  96. package/fesm2022/avero-ui-menubar.mjs.map +1 -0
  97. package/fesm2022/avero-ui-message.mjs +221 -0
  98. package/fesm2022/avero-ui-message.mjs.map +1 -0
  99. package/fesm2022/avero-ui-order-list.mjs +302 -0
  100. package/fesm2022/avero-ui-order-list.mjs.map +1 -0
  101. package/fesm2022/avero-ui-organization-chart.mjs +505 -0
  102. package/fesm2022/avero-ui-organization-chart.mjs.map +1 -0
  103. package/fesm2022/avero-ui-paginator.mjs +319 -0
  104. package/fesm2022/avero-ui-paginator.mjs.map +1 -0
  105. package/fesm2022/avero-ui-panel-menu.mjs +339 -0
  106. package/fesm2022/avero-ui-panel-menu.mjs.map +1 -0
  107. package/fesm2022/avero-ui-password.mjs +483 -0
  108. package/fesm2022/avero-ui-password.mjs.map +1 -0
  109. package/fesm2022/avero-ui-popover.mjs +469 -0
  110. package/fesm2022/avero-ui-popover.mjs.map +1 -0
  111. package/fesm2022/avero-ui-progress-bar.mjs +194 -0
  112. package/fesm2022/avero-ui-progress-bar.mjs.map +1 -0
  113. package/fesm2022/avero-ui-progress-spinner.mjs +150 -0
  114. package/fesm2022/avero-ui-progress-spinner.mjs.map +1 -0
  115. package/fesm2022/avero-ui-radio.mjs +67 -0
  116. package/fesm2022/avero-ui-radio.mjs.map +1 -0
  117. package/fesm2022/avero-ui-rating.mjs +271 -0
  118. package/fesm2022/avero-ui-rating.mjs.map +1 -0
  119. package/fesm2022/avero-ui-scroll-panel.mjs +415 -0
  120. package/fesm2022/avero-ui-scroll-panel.mjs.map +1 -0
  121. package/fesm2022/avero-ui-slider.mjs +274 -0
  122. package/fesm2022/avero-ui-slider.mjs.map +1 -0
  123. package/fesm2022/avero-ui-splitter.mjs +438 -0
  124. package/fesm2022/avero-ui-splitter.mjs.map +1 -0
  125. package/fesm2022/avero-ui-stepper.mjs +626 -0
  126. package/fesm2022/avero-ui-stepper.mjs.map +1 -0
  127. package/fesm2022/avero-ui-switch.mjs +252 -0
  128. package/fesm2022/avero-ui-switch.mjs.map +1 -0
  129. package/fesm2022/avero-ui-table.mjs +448 -0
  130. package/fesm2022/avero-ui-table.mjs.map +1 -0
  131. package/fesm2022/avero-ui-tabs.mjs +693 -0
  132. package/fesm2022/avero-ui-tabs.mjs.map +1 -0
  133. package/fesm2022/avero-ui-textarea.mjs +180 -0
  134. package/fesm2022/avero-ui-textarea.mjs.map +1 -0
  135. package/fesm2022/avero-ui-tiered-menu.mjs +444 -0
  136. package/fesm2022/avero-ui-tiered-menu.mjs.map +1 -0
  137. package/fesm2022/avero-ui-timeline.mjs +348 -0
  138. package/fesm2022/avero-ui-timeline.mjs.map +1 -0
  139. package/fesm2022/avero-ui-toast.mjs +291 -0
  140. package/fesm2022/avero-ui-toast.mjs.map +1 -0
  141. package/fesm2022/avero-ui-toggle-button.mjs +317 -0
  142. package/fesm2022/avero-ui-toggle-button.mjs.map +1 -0
  143. package/fesm2022/avero-ui-toolbar.mjs +284 -0
  144. package/fesm2022/avero-ui-toolbar.mjs.map +1 -0
  145. package/fesm2022/avero-ui-tooltip.mjs +442 -0
  146. package/fesm2022/avero-ui-tooltip.mjs.map +1 -0
  147. package/fesm2022/avero-ui-tree.mjs +426 -0
  148. package/fesm2022/avero-ui-tree.mjs.map +1 -0
  149. package/fesm2022/avero-ui-virtual-scroller.mjs +503 -0
  150. package/fesm2022/avero-ui-virtual-scroller.mjs.map +1 -0
  151. package/fesm2022/avero-ui.mjs +114 -0
  152. package/fesm2022/avero-ui.mjs.map +1 -0
  153. package/package.json +342 -3
  154. package/scripts/install-agent-skills.mjs +31 -0
  155. package/skills/avero-ui-build/SKILL.md +40 -0
  156. package/skills/avero-ui-build/agents/openai.yaml +4 -0
  157. package/skills/avero-ui-build/assets/workspace-page.scss +94 -0
  158. package/skills/avero-ui-build/assets/workspace-page.ts +222 -0
  159. package/skills/avero-ui-build/references/components.md +47 -0
  160. package/skills/avero-ui-build/references/integration.md +65 -0
  161. package/skills/avero-ui-build/references/recipes.md +88 -0
  162. package/styles/theme.scss +92 -0
  163. package/types/avero-ui-accordion.d.ts +101 -0
  164. package/types/avero-ui-animate-on-scroll.d.ts +56 -0
  165. package/types/avero-ui-auto-complete.d.ts +188 -0
  166. package/types/avero-ui-auto-focus.d.ts +24 -0
  167. package/types/avero-ui-avatar.d.ts +73 -0
  168. package/types/avero-ui-badge.d.ts +71 -0
  169. package/types/avero-ui-bind.d.ts +26 -0
  170. package/types/avero-ui-block-ui.d.ts +31 -0
  171. package/types/avero-ui-breadcrumb.d.ts +65 -0
  172. package/types/avero-ui-button.d.ts +37 -0
  173. package/types/avero-ui-calendar.d.ts +105 -0
  174. package/types/avero-ui-card.d.ts +53 -0
  175. package/types/avero-ui-carousel.d.ts +128 -0
  176. package/types/avero-ui-cascade-select.d.ts +212 -0
  177. package/types/avero-ui-chart.d.ts +106 -0
  178. package/types/avero-ui-checkbox.d.ts +90 -0
  179. package/types/avero-ui-chip.d.ts +63 -0
  180. package/types/avero-ui-class-names.d.ts +24 -0
  181. package/types/avero-ui-color-picker.d.ts +173 -0
  182. package/types/avero-ui-confirm-dialog.d.ts +113 -0
  183. package/types/avero-ui-confirm-popup.d.ts +68 -0
  184. package/types/avero-ui-context-menu.d.ts +95 -0
  185. package/types/avero-ui-core.d.ts +11 -0
  186. package/types/avero-ui-data-view.d.ts +102 -0
  187. package/types/avero-ui-dialog.d.ts +118 -0
  188. package/types/avero-ui-divider.d.ts +31 -0
  189. package/types/avero-ui-dock.d.ts +80 -0
  190. package/types/avero-ui-drawer.d.ts +109 -0
  191. package/types/avero-ui-dropdown.d.ts +146 -0
  192. package/types/avero-ui-dynamic-dialog.d.ts +51 -0
  193. package/types/avero-ui-fieldset.d.ts +73 -0
  194. package/types/avero-ui-file-upload.d.ts +195 -0
  195. package/types/avero-ui-fluid.d.ts +32 -0
  196. package/types/avero-ui-focus-trap.d.ts +25 -0
  197. package/types/avero-ui-galleria.d.ts +156 -0
  198. package/types/avero-ui-icon-field.d.ts +22 -0
  199. package/types/avero-ui-image-compare.d.ts +77 -0
  200. package/types/avero-ui-image.d.ts +111 -0
  201. package/types/avero-ui-input-group.d.ts +14 -0
  202. package/types/avero-ui-input-mask.d.ts +178 -0
  203. package/types/avero-ui-input-number.d.ts +131 -0
  204. package/types/avero-ui-input-otp.d.ts +140 -0
  205. package/types/avero-ui-input.d.ts +36 -0
  206. package/types/avero-ui-knob.d.ts +139 -0
  207. package/types/avero-ui-mega-menu.d.ts +115 -0
  208. package/types/avero-ui-menu.d.ts +100 -0
  209. package/types/avero-ui-menubar.d.ts +91 -0
  210. package/types/avero-ui-message.d.ts +54 -0
  211. package/types/avero-ui-order-list.d.ts +85 -0
  212. package/types/avero-ui-organization-chart.d.ts +145 -0
  213. package/types/avero-ui-paginator.d.ts +104 -0
  214. package/types/avero-ui-panel-menu.d.ts +99 -0
  215. package/types/avero-ui-password.d.ts +163 -0
  216. package/types/avero-ui-popover.d.ts +91 -0
  217. package/types/avero-ui-progress-bar.d.ts +45 -0
  218. package/types/avero-ui-progress-spinner.d.ts +41 -0
  219. package/types/avero-ui-radio.d.ts +16 -0
  220. package/types/avero-ui-rating.d.ts +75 -0
  221. package/types/avero-ui-scroll-panel.d.ts +78 -0
  222. package/types/avero-ui-slider.d.ts +92 -0
  223. package/types/avero-ui-splitter.d.ts +90 -0
  224. package/types/avero-ui-stepper.d.ts +134 -0
  225. package/types/avero-ui-switch.d.ts +83 -0
  226. package/types/avero-ui-table.d.ts +150 -0
  227. package/types/avero-ui-tabs.d.ts +135 -0
  228. package/types/avero-ui-textarea.d.ts +43 -0
  229. package/types/avero-ui-tiered-menu.d.ts +105 -0
  230. package/types/avero-ui-timeline.d.ts +97 -0
  231. package/types/avero-ui-toast.d.ts +99 -0
  232. package/types/avero-ui-toggle-button.d.ts +115 -0
  233. package/types/avero-ui-toolbar.d.ts +33 -0
  234. package/types/avero-ui-tooltip.d.ts +93 -0
  235. package/types/avero-ui-tree.d.ts +128 -0
  236. package/types/avero-ui-virtual-scroller.d.ts +149 -0
  237. package/types/avero-ui.d.ts +82 -0
package/README.md CHANGED
@@ -1,3 +1,1044 @@
1
- # Temporary Holding Version
1
+ # AveroUi
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ ## Color themes
4
+
5
+ Import the shared theme once in your global stylesheet:
6
+
7
+ ```scss
8
+ @use 'avero-ui/styles/theme';
9
+ ```
10
+
11
+ Light is the default. Set `data-theme="dark"` on the `<html>` element for the
12
+ graphite dark palette, and remove it or use `data-theme="light"` to return to light.
13
+ Shared semantic tokens such as `--av-surface`, `--av-text`, `--av-border` and
14
+ `--av-primary` theme components consistently. Existing component-specific tokens
15
+ (for example `--av-card-background`) take precedence. Apply the attribute on
16
+ `<html>` so tooltips and dynamically created dialogs receive the same theme.
17
+
18
+ ## InputOtp
19
+
20
+ Import `AvInputOtp` with `FormsModule` or `ReactiveFormsModule`.
21
+
22
+ ```html
23
+ <av-input-otp
24
+ inputId="code"
25
+ label="Verification code"
26
+ [length]="6"
27
+ integerOnly
28
+ [(ngModel)]="code"
29
+ [separatorAfter]="3"
30
+ />
31
+ ```
32
+
33
+ `inputId` and `label` are required. `length` defaults to 4 and is clamped to 1–32.
34
+ The value is a string (preserves leading zeros), or null when empty. Nonempty
35
+ incomplete/malformed codes return an `otp` validation error; add
36
+ `Validators.required` for mandatory codes. `integerOnly` accepts ASCII digits;
37
+ otherwise non-whitespace printable characters are accepted. `mask` hides values.
38
+
39
+ Supports `disabled`, `readonly`, `required`, `invalid`, `describedBy`, `avSize`
40
+ (`sm`, `md`, `lg`), `variant` (`outlined`, `filled`) and `characterLabel` for
41
+ localized field labels. `separatorAfter` inserts a visual separator after that
42
+ position; `ng-template #separator` replaces its content. Standard input CSS tokens
43
+ apply, plus `--av-input-otp-width`, `--av-input-otp-gap`,
44
+ `--av-input-otp-separator-color`, `--av-input-otp-filled-background`.
45
+
46
+ Typing overwrites and advances; arrows and Home/End navigate. Backspace clears
47
+ and moves back; Delete clears in place. Native Tab order remains available.
48
+ Full-code paste/autofill replaces all cells; partial paste starts at the focused
49
+ cell. Composition text is handled on completion. The code row is always LTR.
50
+ The first input uses `autocomplete="one-time-code"`; browser support varies.
51
+
52
+ `onChange` and `onComplete` emit `AvInputOtpChangeEvent` with `value` and
53
+ `originalEvent`. Completion fires when a user edit leaves all cells filled,
54
+ without submitting. Form writes/reset are silent. Changing `length` or
55
+ `integerOnly` reformats the display without rewriting the model. Reset the value
56
+ when changing its meaning. See `/input-otp` for working examples.
57
+
58
+ ## InputMask
59
+
60
+ Import `AvInputMask` with `FormsModule` or `ReactiveFormsModule`.
61
+
62
+ ```html
63
+ <av-input-mask
64
+ inputId="phone"
65
+ label="Phone"
66
+ mask="(999) 999-9999"
67
+ [(ngModel)]="phone"
68
+ showClear
69
+ inputmode="tel"
70
+ />
71
+ ```
72
+
73
+ `9` accepts digits, `a` ASCII letters, `*` either; other characters are literals.
74
+ Escape tokens with a backslash. All positions after `?` are optional.
75
+ `slotChar` defaults to `_` or accepts a positional guide like `dd/mm/yyyy`.
76
+ `unmask` emits only entered characters; otherwise values contain formatting.
77
+ Empty values emit null. `autoClear` (true by default) clears incomplete input on
78
+ blur. Incomplete nonempty values have an Angular `mask` validation error; use
79
+ `Validators.required` for mandatory fields. Date masks only check structure.
80
+
81
+ Typing overwrites slots; Backspace/Delete leave other positions in place.
82
+ Selection replacement, raw/formatted paste and composition input are supported.
83
+ `onInput` and `onComplete` emit `AvInputMaskEvent` with `value`, `unmaskedValue`
84
+ and `originalEvent`. Completion means the required portion became complete.
85
+ `onClear` emits its original event. Programmatic writes emit no user events.
86
+
87
+ Required inputs: `inputId`, `label`, `mask`. Also supports `placeholder`,
88
+ `disabled`, `readonly`, `required`, `invalid`, `describedBy`, `autocomplete`,
89
+ `inputmode`, `name`, `showClear`, `clearLabel`, `avSize` (`sm`, `md`, `lg`),
90
+ `fluid`, `variant` (`outlined`, `filled`). Changing a mask reformats the display
91
+ without rewriting the form value; reset the model when changing its meaning.
92
+ Input theme tokens apply, plus `--av-input-mask-filled-background`.
93
+ See `/input-mask` for working examples.
94
+
95
+ ## InputGroup
96
+
97
+ Import `AvInputGroup` and `AvInputGroupAddon` with the controls you use.
98
+
99
+ ```html
100
+ <label for="price">Price</label>
101
+ <av-input-group>
102
+ <av-input-group-addon id="currency">USD</av-input-group-addon>
103
+ <input avInput id="price" type="number" aria-describedby="currency" [formControl]="price" />
104
+ <button avButton type="button" (click)="save()">Save</button>
105
+ </av-input-group>
106
+ ```
107
+
108
+ Layout components with no inputs/outputs or form accessor. Supported segments:
109
+ direct native `avInput` fields, `avButton` buttons/links, `AvIconField`,
110
+ `AvFloatLabel` and `AvInputGroupAddon`. Addons accept text, SVGs, buttons and
111
+ independently labeled checkbox/radio controls. Dropdown/InputNumber composite
112
+ controls are not styled by this implementation. Use consistent `avSize` on
113
+ inputs and buttons; addons follow the input height. Logical corners support RTL.
114
+
115
+ Label each input and interactive addon. Connect meaningful units/prefixes with
116
+ `aria-describedby`; set `aria-hidden` only on decorative content. Focus, form
117
+ binding, validation and disabled state remain on each control. The group adds
118
+ no focus stops or ARIA roles. Groups remain on one line, so keep addons concise.
119
+
120
+ Tokens: `--av-input-group-radius`, `--av-input-group-border`,
121
+ `--av-input-group-addon-background`, `--av-input-group-addon-color`,
122
+ `--av-input-group-addon-padding`. See `/input-group` for working examples.
123
+
124
+ ## IconField
125
+
126
+ Import `AvIconField`, `AvInputIcon` and `AvInput`.
127
+
128
+ ```html
129
+ <label for="search">Search</label>
130
+ <av-icon-field>
131
+ <av-input-icon>⌕</av-input-icon>
132
+ <input avInput id="search" [(ngModel)]="query" />
133
+ </av-icon-field>
134
+ ```
135
+
136
+ Use one native `avInput` and one or two direct-child `av-input-icon` elements.
137
+ Default `iconPosition="auto"` follows element order: an icon before the input is
138
+ leading, after it is trailing. For one icon, `left` or `right` overrides its side;
139
+ positions use logical start/end in RTL. SVGs and icon-font classes are supported.
140
+ Size and padding follow the input's `avSize` (`sm`, `md`, `lg`). Native values,
141
+ events, validation and disabled state remain on the input.
142
+
143
+ Icons are decorative (`aria-hidden`) and do not intercept pointer events. Do not
144
+ put interactive controls inside them. Label the input and expose meaningful
145
+ status in separate accessible text. `AvFloatLabel` can wrap `av-icon-field`;
146
+ keep `placeholder=" "` on the input to enable native empty-state detection.
147
+
148
+ Customize `--av-icon-field-color`, `--av-icon-field-size`, `--av-icon-field-inset`
149
+ and `--av-icon-field-gap` on the wrapper. See `/icon-field` for examples.
150
+
151
+ ## ColorPicker
152
+
153
+ Import `AvColorPicker` with `FormsModule` or `ReactiveFormsModule`.
154
+
155
+ ```html
156
+ <av-color-picker inputId="brand" label="Brand color" [(ngModel)]="color" />
157
+ <av-color-picker inputId="accent" label="Accent color" [formControl]="accent" inline />
158
+ ```
159
+
160
+ `format` accepts `hex` (default, six digits without #), `rgb` (`{ r, g, b }`,
161
+ 0–255), or `hsb` (`{ h, s, b }`, hue 0–360 and percentages 0–100). Exported types:
162
+ `AvColorPickerFormat`, `AvColorPickerValue`, `AvColorPickerRGB`, `AvColorPickerHSB`
163
+ and `AvColorPickerChangeEvent`. Writes accept HEX with/without #, shorthand HEX,
164
+ RGB or HSB objects. Finite channels are clamped; malformed values behave as empty.
165
+ Null/reset leaves the form empty; `defaultColor` (default `ff0000`) only supplies
166
+ the initial palette until a user edits it or confirms with Done/Enter.
167
+
168
+ Provide unique `inputId` and `label`. Supports `inline`, `disabled`, `readonly`,
169
+ `required`, `invalid`, `describedBy` and `avSize` (`sm`, `md`, `lg`). Required
170
+ validation belongs to Angular forms. `onChange` emits `{ value, originalEvent }`
171
+ for user edits; form writes emit nothing. `onShow` and `onHide` report popup state.
172
+ Changing `format` affects subsequent user emissions, not the existing form value.
173
+
174
+ The pointer palette has equivalent labeled hue, saturation and brightness native
175
+ sliders and an editable HEX field. Invalid HEX edits restore the previous color.
176
+ Popup opening focuses Hue; arrows and Home/End adjust sliders, Enter/Done confirms,
177
+ Escape closes and restores focus, and Tab follows normal focus order. Edits apply
178
+ immediately; Escape does not revert them. Localize using `hueLabel`,
179
+ `saturationLabel`, `brightnessLabel`, `hexLabel` and `closeLabel`.
180
+
181
+ The local popup opens above when appropriate; allow visible overflow on ancestors.
182
+ Input theme tokens apply, plus `--av-color-picker-background`,
183
+ `--av-color-picker-accent`, `--av-color-picker-button-color`, and
184
+ `--av-color-picker-invalid`. See `/color-picker` for examples.
185
+
186
+ ## CascadeSelect
187
+
188
+ Import `AvCascadeSelect` with `FormsModule` or `ReactiveFormsModule`.
189
+
190
+ ```html
191
+ <av-cascade-select
192
+ inputId="city"
193
+ label="City"
194
+ [options]="countries"
195
+ optionLabel="cname"
196
+ optionGroupLabel="name"
197
+ [optionGroupChildren]="['states', 'cities']"
198
+ [(ngModel)]="city"
199
+ showClear
200
+ />
201
+ ```
202
+
203
+ Options can use arbitrary nested objects; list child property names in hierarchy
204
+ order. Only leaves are selectable, including when a group has an empty array.
205
+ The value is the leaf object by default; `optionValue="code"` stores its property
206
+ instead. `dataKey` compares object values by a unique property. Null/undefined are
207
+ reserved for no selection. Property names support dot paths. `optionDisabled`
208
+ defaults to `disabled`; disabled groups also disable their descendants.
209
+
210
+ Provide a unique `inputId` and `label`. Inputs include `placeholder`, `showClear`,
211
+ `clearLabel`, `disabled`, `loading`, `required`, `invalid`, `describedBy`, `fluid`,
212
+ `avSize` (`sm`, `md`, `lg`), `variant` (`outlined`, `filled`) and `emptyMessage`.
213
+ Use Angular validators for required fields. Programmatic writes and asynchronous
214
+ option changes do not emit selection events. `onChange` emits `{ value,
215
+ originalEvent }`, `onSelectedElement` emits the original leaf (null on clear), and
216
+ `onClear` emits the clear event.
217
+
218
+ Templates: `#option` and `#value` receive the original option as `$implicit`;
219
+ `#header`, `#footer`, `#dropdownicon`, `#loadingicon`, `#optiongroupicon` customize
220
+ the panel and icons. Keep option/value templates presentational. Up/Down and
221
+ Home/End navigate siblings, Right enters a group, Left returns (reversed in RTL),
222
+ Enter/Space selects, Escape closes, and Tab leaves. Typing an initial finds a sibling.
223
+ The combobox uses an accessible tree popup with level, position and active item.
224
+
225
+ The locally positioned panel opens above if needed and scrolls on narrow screens.
226
+ Ancestors must allow visible overflow. Input theme tokens apply, plus
227
+ `--av-cascade-select-option-hover`, `--av-cascade-select-option-selected`,
228
+ `--av-cascade-select-accent`, `--av-cascade-select-filled-background` and
229
+ `--av-cascade-select-invalid`. See `/cascade-select` for working examples.
230
+
231
+ ## ScrollPanel
232
+
233
+ Import `AvScrollPanel` from `avero-ui`.
234
+
235
+ ```html
236
+ <av-scroll-panel inputId="notes" ariaLabel="Project notes" style="height: 280px">
237
+ <p>Your scrollable content goes here.</p>
238
+ </av-scroll-panel>
239
+ ```
240
+
241
+ Set a height (and optionally width) on the host. Provide a unique `inputId` and
242
+ `ariaLabel` or `ariaLabelledBy`. Custom scrollbars appear only when their axis
243
+ overflows. Space for both tracks is always reserved to avoid layout shifts.
244
+ Wheel, touch and native viewport keyboard scrolling remain available.
245
+
246
+ Focusable scrollbars support arrows, PageUp/PageDown, Home/End, pointer dragging
247
+ and paging by clicking the track. `step` is the arrow increment in pixels (40 by
248
+ default). `horizontalLabel` and `verticalLabel` customize their accessible names.
249
+ Each scrollbar exposes its pixel range and references the controlled viewport.
250
+
251
+ `scrollTo(options)` accepts native `ScrollToOptions` and respects reduced motion.
252
+ `onScroll` emits `AvScrollPanelEvent` with `originalEvent`, `scrollTop` and
253
+ `scrollLeft` (negative horizontal coordinates in RTL). Resize/content observers
254
+ update geometry automatically; `refresh()` handles unobserved external changes
255
+ such as inherited direction changes. Observers are disconnected on destruction.
256
+
257
+ Theme tokens: `--av-scroll-panel-bar-size`, `--av-scroll-panel-bar-radius`,
258
+ `--av-scroll-panel-track-background`, `--av-scroll-panel-bar-background`,
259
+ `--av-scroll-panel-bar-hover`, `--av-scroll-panel-focus`. See `/scroll-panel`.
260
+
261
+ ## Fieldset
262
+
263
+ Import `AvFieldset` from `avero-ui`.
264
+
265
+ ```html
266
+ <av-fieldset inputId="details" legend="Project details" toggleable [(collapsed)]="collapsed">
267
+ <label for="project-name">Project name</label>
268
+ <input avInput id="project-name" />
269
+ </av-fieldset>
270
+ ```
271
+
272
+ Provide a unique `inputId` and a legend or a direct child header template.
273
+ `ng-template avFieldsetHeader` (import `AvFieldsetHeader`) or `ng-template #header`
274
+ replaces the legend text; the directive takes precedence. Keep toggleable header
275
+ content presentational because it is rendered inside a native button.
276
+
277
+ `toggleable` defaults to false; non-toggleable content stays visible even when
278
+ `collapsed` is true. `[(collapsed)]` supports controlled state. `disabled` only
279
+ locks the legend toggle; it does not disable projected fields or external updates.
280
+ Content is eagerly created and preserved when hidden.
281
+
282
+ `onBeforeToggle` and `onAfterToggle` emit `AvFieldsetToggleEvent` containing
283
+ `originalEvent` and the next `collapsed` state, immediately before and after a user
284
+ toggle. External updates do not emit these events. The native button handles
285
+ Enter/Space and exposes `aria-expanded` and `aria-controls`. Optional
286
+ `toggleAriaLabel` and `toggleAriaLabelledBy` customize its accessible name.
287
+
288
+ Theme tokens: `--av-fieldset-background`, `--av-fieldset-border`,
289
+ `--av-fieldset-radius`, `--av-fieldset-color`, `--av-fieldset-legend-color`,
290
+ `--av-fieldset-hover`, `--av-fieldset-accent`. See `/fieldset` for working examples.
291
+
292
+ ## Splitter
293
+
294
+ Import `AvSplitter` and `AvSplitterPanel` from `avero-ui`.
295
+
296
+ ```html
297
+ <av-splitter
298
+ inputId="workspace"
299
+ style="height: 300px"
300
+ [(panelSizes)]="sizes"
301
+ [minSizes]="[15, 25]"
302
+ [separatorLabels]="['Resize navigation']"
303
+ >
304
+ <ng-template avSplitterPanel>Navigation</ng-template>
305
+ <ng-template avSplitterPanel>Workspace</ng-template>
306
+ </av-splitter>
307
+ ```
308
+
309
+ Supply direct child `avSplitterPanel` templates, or `ng-template #panel` references
310
+ without importing the directive. Do not mix the two styles in one splitter.
311
+ Use a unique `inputId` and an explicit height. Nest independent splitters inside
312
+ panel templates. `layout` accepts `horizontal` (default) or `vertical`.
313
+
314
+ `panelSizes` contains relative weights (equal by default); `[(panelSizes)]` reports
315
+ percentages during resizing. `minSizes` specifies percentage minimums, excluding
316
+ gutters; totals above 100 are proportionally reduced. Invalid or negative sizes
317
+ are normalized. `gutterSize` defaults to 10px (minimum 4), `step` to one percentage
318
+ point. `disabled` blocks user resizing while external updates remain supported.
319
+
320
+ Drag using mouse, touch or pen, or focus the separator and use the corresponding
321
+ arrow keys. Home/End select its minimum/maximum. Horizontal resizing respects RTL.
322
+ `separatorLabels` supplies accessible names; each separator exposes its value,
323
+ limits, orientation and controlled panel. `onResizeStart` and `onResizeEnd` emit
324
+ `AvSplitterResizeEvent` with `sizes` and `originalEvent`. Cancellation ends at the
325
+ current sizes. Content changes do not emit resize events.
326
+
327
+ Theme tokens: `--av-splitter-background`, `--av-splitter-color`,
328
+ `--av-splitter-border`, `--av-splitter-radius`, `--av-splitter-gutter-background`,
329
+ `--av-splitter-handle-color`, `--av-splitter-accent`. See `/splitter` for examples.
330
+
331
+ ## Toolbar
332
+
333
+ Import `AvToolbar`, `AvToolbarStart`, `AvToolbarCenter` and `AvToolbarEnd` from `avero-ui`.
334
+
335
+ ```html
336
+ <av-toolbar aria-label="Project actions">
337
+ <ng-template avToolbarStart><button avButton>New</button></ng-template>
338
+ <ng-template avToolbarCenter><input avInput aria-label="Search projects" /></ng-template>
339
+ <ng-template avToolbarEnd><button avButton>Save</button></ng-template>
340
+ </av-toolbar>
341
+ ```
342
+
343
+ Direct child `ng-template #start`, `#center` and `#end` references are also supported
344
+ without the slot directive imports. A slot directive takes precedence over its
345
+ named reference. Plain projected content works without templates.
346
+
347
+ The root uses `role="toolbar"`; provide `aria-label` or `aria-labelledby`.
348
+ Controls keep their native keyboard behavior and normal Tab order. Sections wrap
349
+ when space is limited. Customize with `--av-toolbar-background`, `--av-toolbar-color`,
350
+ `--av-toolbar-border`, `--av-toolbar-radius`, `--av-toolbar-padding` and
351
+ `--av-toolbar-gap`. Working examples are available at `/toolbar`.
352
+
353
+ ## Tabs
354
+
355
+ Import `AvTabs`, `AvTabList`, `AvTab`, `AvTabPanels` and `AvTabPanel` from `avero-ui`.
356
+
357
+ ```html
358
+ <av-tabs inputId="project" [(value)]="active">
359
+ <av-tab-list ariaLabel="Project">
360
+ <av-tab value="overview">Overview</av-tab>
361
+ <av-tab value="draft">Draft</av-tab>
362
+ </av-tab-list>
363
+ <av-tab-panels>
364
+ <av-tab-panel value="overview">Project overview</av-tab-panel>
365
+ <av-tab-panel value="draft" lazy>
366
+ <ng-template #content><input aria-label="Draft" /></ng-template>
367
+ </av-tab-panel>
368
+ </av-tab-panels>
369
+ </av-tabs>
370
+ ```
371
+
372
+ Provide a unique `inputId`, an initial `value`, and matching unique string or number
373
+ values for tabs and panels. `[(value)]` supports controlled selection;
374
+ `activate(value)` selects an existing enabled tab. `disabled` on a tab or container
375
+ blocks user interaction, while external value changes remain supported.
376
+
377
+ `scrollable` adds horizontal scrolling and navigation buttons. `AvTabList` accepts
378
+ `ariaLabel`, `previousLabel` and `nextLabel` for accessible, localizable labels.
379
+ Left/Right, Home and End move focus, skipping disabled tabs. Enter/Space select;
380
+ `selectOnFocus` also selects on focus. Custom headers should be presentational.
381
+
382
+ `lazy` on the container or panel delays `ng-template #content` until first
383
+ activation and preserves its state when hidden. Plain projected content is eager.
384
+ No initial value (or a removed selected tab) leaves all panels hidden and the
385
+ first enabled tab keyboard reachable; selection remains application controlled.
386
+
387
+ Theme tokens: `--av-tabs-accent`, `--av-tabs-color`, `--av-tabs-muted`,
388
+ `--av-tabs-border`, `--av-tabs-background`, `--av-tabs-hover`,
389
+ `--av-tabs-panel-padding`. See `/tabs` in the playground.
390
+
391
+ ## Stepper
392
+
393
+ Import `AvStepper`, `AvStepList`, `AvStep`, `AvStepPanels`, `AvStepPanel` from
394
+ `avero-ui`. Use `AvStepItem` for vertical layouts.
395
+
396
+ ```html
397
+ <av-stepper inputId="setup" [(value)]="active">
398
+ <av-step-list ariaLabel="Account setup">
399
+ <av-step [value]="1">Details</av-step>
400
+ <av-step [value]="2">Review</av-step>
401
+ </av-step-list>
402
+ <av-step-panels>
403
+ <av-step-panel [value]="1">
404
+ <ng-template #content let-next="activateCallback">
405
+ <p>Enter your details here.</p>
406
+ <button (click)="next(2)">Next</button>
407
+ </ng-template>
408
+ </av-step-panel>
409
+ <av-step-panel [value]="2">
410
+ <ng-template #content let-next="activateCallback">
411
+ <p>Review your details.</p>
412
+ <button (click)="next(1)">Back</button>
413
+ </ng-template>
414
+ </av-step-panel>
415
+ </av-step-panels>
416
+ </av-stepper>
417
+ ```
418
+
419
+ Initialize `active` to `1`. `inputId` is required and must be unique on the page.
420
+ Step values are unique strings or numbers; numeric `0` and string `'0'` are distinct.
421
+ Match each horizontal step with one panel. For vertical layout, replace the list
422
+ and panels containers with an `av-step-item [value]="..."` per step, containing
423
+ an `av-step` and `av-step-panel`; both inherit the item's value.
424
+
425
+ `linear` locks inactive headers; call the panel context's `activateCallback(value)`
426
+ or the stepper's `activate(value)` after application validation. These methods
427
+ reject missing or disabled destinations. `disabled` on stepper, step or step item
428
+ blocks user navigation; direct model writes still work. Inner form controls manage
429
+ their own disabled state. `valueChange` supports two-way binding.
430
+
431
+ Optional `ng-template #content` is created on first activation and retained while
432
+ hidden. Its context provides `activateCallback`, `value`, and `active`. Ordinary
433
+ projected content is created immediately. Removing a step preserves the current
434
+ model value; the application should select a remaining step if needed.
435
+
436
+ Horizontal headers use tabs with Left/Right, vertical headers use expandable
437
+ buttons with Up/Down. Home/End focus the first/last enabled header; Enter/Space
438
+ activate. Callback navigation from focused panel content moves focus to the new
439
+ header. Custom header content must not contain interactive controls.
440
+ Theme tokens: `--av-stepper-accent`, `--av-stepper-active-color`,
441
+ `--av-stepper-color`, `--av-stepper-border`, `--av-stepper-background`,
442
+ `--av-stepper-hover`. See the playground `/stepper` for working examples.
443
+
444
+ ## Switch
445
+
446
+ Import `AvSwitch` with `FormsModule` or `ReactiveFormsModule`.
447
+
448
+ ```html
449
+ <av-switch label="Notifications" [(ngModel)]="enabled" (onChange)="changed($event)" />
450
+ <av-switch label="Updates" [formControl]="updates" />
451
+ ```
452
+
453
+ The value is boolean. `label` is required and is associated with the native
454
+ checkbox using `role="switch"`. Supports `inputId`, `name`, `avSize` (`sm`, `md`,
455
+ `lg`), `disabled`, `readonly`, `required`, `invalid`, and `describedBy`.
456
+ Use `Validators.requiredTrue` when the form requires an enabled setting.
457
+ Tab focuses and Space toggles. Read-only switches remain focusable but cannot
458
+ be changed by the user. Animation respects reduced-motion preferences.
459
+
460
+ `onChange` emits `AvSwitchChangeEvent` with `{ checked: boolean, originalEvent: Event }`
461
+ only for user changes. Form writes and resets do not emit it. Customize
462
+ `--av-switch-accent`, `--av-switch-background`, `--av-switch-thumb`,
463
+ `--av-switch-border`, `--av-switch-focus`, and `--av-switch-disabled-opacity`.
464
+
465
+ ## Dropdown
466
+
467
+ ### Selection event
468
+
469
+ ```html
470
+ <av-dropdown
471
+ inputId="city"
472
+ label="City"
473
+ [options]="cities"
474
+ [(ngModel)]="city"
475
+ showClear
476
+ (onSelectedElement)="onCitySelected($event)"
477
+ />
478
+ ```
479
+
480
+ `onSelectedElement` emits `AvDropdownOption | null`: the full option on user
481
+ selection (mouse or keyboard, including selecting the current option again), or
482
+ `null` when the user clears the field. Disabled options, navigation, filtering,
483
+ `setValue` and `reset` do not emit this event. Use a form control's `valueChanges`
484
+ when you need to observe programmatic value changes as well.
485
+
486
+ Import `AvDropdown` with `FormsModule` or `ReactiveFormsModule`.
487
+
488
+ ```ts
489
+ const cities: AvDropdownOption<string>[] = [
490
+ { label: 'Warsaw', value: 'waw' },
491
+ { label: 'London', value: 'lon' },
492
+ { label: 'Unavailable', value: 'off', disabled: true },
493
+ ];
494
+ ```
495
+
496
+ ```html
497
+ <av-dropdown inputId="city" label="City" [options]="cities" [(ngModel)]="city" filter showClear />
498
+ ```
499
+
500
+ `inputId` must be unique and `label` is required. `options` is a flat array of
501
+ `AvDropdownOption<T>` objects. Values use `Object.is`; use primitive IDs or stable
502
+ object references. Reserve `null` and `undefined` for no selection. Clearing emits
503
+ `null`. Options can arrive asynchronously without changing the form value.
504
+
505
+ Supports `avSize` (`sm`, `md`, `lg`), `disabled`, `required` (ARIA only; use Angular
506
+ validators), `invalid`, `describedBy`, `placeholder`, `filter`, `showClear`,
507
+ `filterPlaceholder`, `emptyMessage`, and `clearLabel`. Filtering matches labels
508
+ without case sensitivity. Arrows navigate enabled options, Enter/Space selects,
509
+ Escape cancels, and Tab leaves. Home/End navigate the list (inside the search box
510
+ they retain normal text editing behavior). Typing on the trigger jumps by initial.
511
+
512
+ The panel is positioned within the component and opens above when space below is
513
+ limited. Ancestors must allow visible overflow; body portals, option groups,
514
+ editable values and virtual scrolling are not included. Input CSS tokens apply,
515
+ plus `--av-dropdown-option-hover`, `--av-dropdown-option-selected`, and
516
+ `--av-dropdown-accent`.
517
+
518
+ ## Checkbox
519
+
520
+ Import `AvCheckbox` and `FormsModule` or `ReactiveFormsModule`.
521
+
522
+ ```html
523
+ <av-checkbox label="Remember me" [(ngModel)]="remember" />
524
+ <av-checkbox label="Accept terms" [formControl]="accepted" />
525
+ <av-checkbox label="Email" [binary]="false" value="email" [(ngModel)]="channels" />
526
+ ```
527
+
528
+ Boolean mode is the default. Set `[binary]="false"` for an array of selected
529
+ values. Values use `Object.is` comparison; use stable primitive IDs or the same
530
+ object references. Group updates create a new array. Use `Validators.requiredTrue`
531
+ for a mandatory boolean control.
532
+
533
+ `label` is required and is associated through native label nesting. Optional inputs:
534
+ `inputId`, `name`, `avSize` (`sm`, `md`, `lg`), `disabled`, `required`, `invalid`,
535
+ and `describedBy`. `[(indeterminate)]` supports a mixed state and clears on user
536
+ activation; compute it from child selections for a select-all checkbox.
537
+ Tab and Space retain native keyboard behavior. Customize `--av-checkbox-accent`,
538
+ `--av-checkbox-check`, `--av-checkbox-border`, `--av-checkbox-background`,
539
+ `--av-checkbox-radius`, `--av-checkbox-focus`, and `--av-checkbox-disabled-opacity`.
540
+
541
+ ## Password
542
+
543
+ Import `AvPassword` plus `FormsModule` or `ReactiveFormsModule` in your application.
544
+
545
+ ```html
546
+ <av-password inputId="account-password" label="Password" [formControl]="password" />
547
+ <av-password
548
+ inputId="login-password"
549
+ label="Password"
550
+ autocomplete="current-password"
551
+ [(ngModel)]="loginPassword"
552
+ [feedback]="false"
553
+ floatingLabel
554
+ />
555
+ ```
556
+
557
+ Use a unique `inputId` for each instance. Supports `avSize` (`sm`, `md`, `lg`),
558
+ `disabled`, `readonly`, `required`, `name`, `placeholder`, `autocomplete`,
559
+ `invalid`, and `describedBy` (IDs of external hints or errors).
560
+ `toggleMask` and `feedback` default to true; `floatingLabel` defaults to false.
561
+ The eye button works with the keyboard. Leaving the component, resetting its
562
+ value, disabling it, or pressing Escape hides the password again. Escape also
563
+ dismisses feedback until the next edit or focus entry.
564
+
565
+ Feedback is displayed below the field while it contains focus. The local heuristic
566
+ uses length and character variety; it is not a breach check or form validator.
567
+ Use Angular validators for application rules. Labels can be customized with
568
+ `promptLabel`, `weakLabel`, `mediumLabel`, `strongLabel`, `showLabel`, and `hideLabel`.
569
+ Input CSS variables apply; additional variables include `--av-password-weak`,
570
+ `--av-password-medium`, `--av-password-strong`, and `--av-password-invalid`.
571
+
572
+ ## Button
573
+
574
+ Import `AvButton` from `avero-ui` and add it to your component's `imports`.
575
+
576
+ ```html
577
+ <button avButton>Save</button>
578
+ <button avButton variant="secondary" avSize="sm">Cancel</button>
579
+ <button avButton variant="ghost" avSize="lg">More options</button>
580
+ <button avButton variant="danger" disabled>Delete</button>
581
+ <button avButton type="submit">Submit form</button>
582
+ ```
583
+
584
+ `variant`: `primary` (default), `secondary`, `ghost`, `danger`.
585
+ `avSize`: `sm` (32px), `md` (40px, default), `lg` (48px).
586
+ The default `type` is `button`; set `submit` or `reset` for native form actions.
587
+ Native `disabled`, `[disabled]`, disabled fieldsets and `(click)` retain their behavior.
588
+ Styles are included automatically. Customize `--av-button-radius`,
589
+ `--av-button-focus`, `--av-button-disabled-opacity`, or variant tokens such as
590
+ `--av-button-primary-background`, `--av-button-primary-color`,
591
+ `--av-button-primary-border`, `--av-button-primary-hover` and
592
+ `--av-button-primary-active`. The same suffixes exist for every variant.
593
+
594
+ ## Input
595
+
596
+ ### Floating label
597
+
598
+ Add `AvFloatLabel` and `AvInput` to your component's `imports`:
599
+
600
+ ```html
601
+ <av-float-label label="Email address">
602
+ <input avInput type="email" placeholder=" " autocomplete="email" />
603
+ </av-float-label>
604
+ ```
605
+
606
+ Wrap exactly one text-like input. Keep `placeholder=" "`: the native
607
+ `:placeholder-shown` state detects empty values, including programmatic form
608
+ updates and resets. The label floats on focus or when the field contains a value,
609
+ and returns inside when the empty field loses focus. Do not supply a visible
610
+ placeholder alongside the floating label. Input types without placeholder support
611
+ (such as date, time, and color) are not supported by this wrapper.
612
+ The label is associated with the input through native label nesting.
613
+ Animation respects `prefers-reduced-motion`. Existing `--av-input-*` colors apply.
614
+
615
+ Import `AvInput` from `avero-ui` and add it to your component's `imports`.
616
+
617
+ ```html
618
+ <label for="name">Name</label>
619
+ <input avInput id="name" avSize="md" placeholder="Your name" />
620
+ <input avInput aria-label="Disabled example" disabled />
621
+ ```
622
+
623
+ `avSize` accepts `sm` (32px), `md` (40px, default), and `lg` (48px).
624
+ Styles are included automatically. Native `size`, `disabled`, `[disabled]`,
625
+ and disabled fieldsets retain their browser behavior. Use this component on
626
+ text-like inputs (text, email, password, search, tel, url, number).
627
+ Colors and radius can be customized with the `--av-input-*` CSS variables
628
+ defined in `src/lib/input/input.scss`.
629
+
630
+ This project was generated using [Angular CLI](https://github.com/angular/angular-cli) version 22.1.0.
631
+
632
+ ## Code scaffolding
633
+
634
+ Angular CLI includes powerful code scaffolding tools. To generate a new component, run:
635
+
636
+ ```bash
637
+ ng generate component component-name
638
+ ```
639
+
640
+ For a complete list of available schematics (such as `components`, `directives`, or `pipes`), run:
641
+
642
+ ```bash
643
+ ng generate --help
644
+ ```
645
+
646
+ ## Building
647
+
648
+ To build the library, run:
649
+
650
+ ```bash
651
+ ng build avero-ui
652
+ ```
653
+
654
+ This command will compile your project, and the build artifacts will be placed in the `dist/` directory.
655
+
656
+ ### Publishing the Library
657
+
658
+ Once the project is built, you can publish your library by following these steps:
659
+
660
+ 1. Navigate to the `dist` directory:
661
+
662
+ ```bash
663
+ cd dist/avero-ui
664
+ ```
665
+
666
+ 2. Run the `npm publish` command to publish your library to the npm registry:
667
+ ```bash
668
+ npm publish
669
+ ```
670
+
671
+ ## Running unit tests
672
+
673
+ To execute unit tests with the [Vitest](https://vitest.dev/) test runner, use the following command:
674
+
675
+ ```bash
676
+ ng test
677
+ ```
678
+
679
+ ## Running end-to-end tests
680
+
681
+ For end-to-end (e2e) testing, run:
682
+
683
+ ```bash
684
+ ng e2e
685
+ ```
686
+
687
+ Angular CLI does not come with an end-to-end testing framework by default. You can choose one that suits your needs.
688
+
689
+ ## Drawer
690
+
691
+ Import `AvDrawer` from `avero-ui` and add it to your standalone component imports.
692
+ Bind `visible` to a writable signal:
693
+
694
+ ```html
695
+ <button (click)="visible.set(true)" aria-controls="details" [attr.aria-expanded]="visible()">
696
+ Open details
697
+ </button>
698
+ <av-drawer inputId="details" header="Details" [(visible)]="visible" position="right">
699
+ <p>Your content.</p>
700
+ <ng-template #footer let-close="close">
701
+ <button (click)="close()">Done</button>
702
+ </ng-template>
703
+ </av-drawer>
704
+ ```
705
+
706
+ `position`: `left` (default), `right`, `top`, `bottom`, or `full`.
707
+ `width` and `height` default to `320px`; side drawers fill the viewport height,
708
+ top/bottom drawers fill its width. `breakpoints` maps maximum viewport widths in px
709
+ to drawer widths, for example `{ '640px': '100vw' }`.
710
+
711
+ `modal`, `closable`, `closeOnEscape`, and `dismissableMask` default to `true`.
712
+ Use `header` or `ariaLabel` to name the drawer. Native modal focus management
713
+ contains keyboard focus; closing restores focus to the trigger. Set
714
+ `data-default-focus` on the desired initial control.
715
+
716
+ Templates: `#header`, `#content`, `#footer`, and `#headless`. Content, footer, and
717
+ headless templates receive `let-close="close"`. Events: `onShow`, `onHide`;
718
+ method: `close()`. Styles: `--av-drawer-background`, `--av-drawer-color`,
719
+ `--av-drawer-border`, `--av-drawer-padding`, and `--av-drawer-mask`.
720
+ See the playground at `/drawer` for interactive examples.
721
+
722
+ ## DynamicDialog
723
+
724
+ Use `AvDialogService` to load a standalone Angular component in a dialog without
725
+ adding an outlet to the page. Provide the service locally to dispose all its open
726
+ dialogs when the page is destroyed.
727
+
728
+ ```typescript
729
+ import { inject } from '@angular/core';
730
+ import { AvDialogService, AvDynamicDialogConfig, AvDynamicDialogRef } from 'avero-ui';
731
+
732
+ // In the caller (with providers: [AvDialogService]):
733
+ private readonly dialogs = inject(AvDialogService);
734
+
735
+ show() {
736
+ const ref = this.dialogs.open(ProductPicker, {
737
+ header: 'Choose a product',
738
+ width: '640px',
739
+ breakpoints: { '768px': '92vw' },
740
+ data: { category: 'Workspace' },
741
+ inputValues: { quantity: 2 },
742
+ });
743
+ ref.onClose.subscribe(result => console.log(result));
744
+ }
745
+
746
+ // In ProductPicker (which declares a quantity input):
747
+ readonly config = inject(AvDynamicDialogConfig<{ category: string }>);
748
+ readonly ref = inject(AvDynamicDialogRef<string>);
749
+ // this.ref.close('Selected product');
750
+ ```
751
+
752
+ `open<Component, Data, Result>()` returns `AvDynamicDialogRef<Result>`.
753
+ `inputValues` uses public Angular input names, including aliases, and sets inputs
754
+ before initialization. Loaded components can inject the caller's scoped services.
755
+
756
+ Configuration supports `header`, `ariaLabel`, `inputId`, `width`, `breakpoints`,
757
+ `position`, `modal`, `closable`, `closeOnEscape`, `dismissableMask`, and
758
+ `maximizable`. Defaults match `AvDialog`, except that `modal` defaults to `true`.
759
+
760
+ `close(result?)` emits `onClose` once. Dismissal emits `undefined`; `destroy()`
761
+ disposes without emitting a result. Both paths emit `onDestroy` and complete the
762
+ observable streams. Views, child components and injectors are removed on disposal.
763
+ During SSR, `open()` returns an inert reference and creates no DOM; open dialogs
764
+ from browser interactions after hydration. Examples are available at `/dynamic-dialog`.
765
+
766
+ ## Popover
767
+
768
+ Import `AvPopover` and add it to your component imports. Open it from an event:
769
+
770
+ ```html
771
+ <button (click)="panel.toggle($event)">Project details</button>
772
+ <av-popover #panel ariaLabel="Project details" width="360px">
773
+ <h3>Design workspace</h3>
774
+ <p>Keep useful context close to its trigger.</p>
775
+ <button (click)="panel.hide()">Done</button>
776
+ </av-popover>
777
+ ```
778
+
779
+ Methods: `show(event, target?)`, `toggle(event, target?)`, `hide()`.
780
+ The optional `HTMLElement` target overrides `event.currentTarget`. `visible()` is
781
+ read-only; `onShow` and `onHide` report visibility changes. A `#content` template
782
+ can replace projected content and receives a `let-close="close"` callback.
783
+
784
+ Inputs: `inputId`, `ariaLabel` (Popover), `ariaLabelledBy`, `width` (320px),
785
+ `dismissable` (true), `closeOnEscape` (true), `focusOnShow` (true),
786
+ `showCloseIcon` (false), and `closeAriaLabel` (Close popover).
787
+
788
+ This is a non-modal dialog: the page remains interactive and Tab is not trapped.
789
+ Trigger ARIA attributes are set while open and restored on close. Use
790
+ `data-default-focus` to choose initial focus. Escape and panel actions restore
791
+ focus when it was inside the panel; outside dismissal does not steal focus.
792
+
793
+ The panel follows scrolling and resizing, flips above the trigger when needed,
794
+ and clamps to the viewport. Supported browsers use the native Popover top layer;
795
+ older browsers fall back to a fixed panel within the component's DOM ancestry.
796
+ Removing the trigger closes the panel. Destruction removes all tracking listeners.
797
+ Keep one popover outside repeated table rows and reuse it with different triggers.
798
+
799
+ Theme variables: `--av-popover-background`, `--av-popover-color`,
800
+ `--av-popover-border`, `--av-popover-radius`, `--av-popover-padding`.
801
+ Interactive examples are available at `/popover`.
802
+
803
+ ## Tooltip
804
+
805
+ Import `AvTooltip` in your standalone component and attach it to a focusable element:
806
+
807
+ ```html
808
+ <button avTooltip="Save your changes" tooltipPosition="top">Save</button>
809
+ <input aria-label="Email" avTooltip="Use your work email" tooltipEvent="focus" />
810
+ <button [avTooltip]="hint" [autoHide]="false">Status</button>
811
+ <ng-template #hint><strong>All changes saved</strong></ng-template>
812
+ ```
813
+
814
+ `avTooltip` accepts text, a `TemplateRef`, or null. Text is escaped; empty content
815
+ hides the overlay. `tooltipPosition` accepts `top`, `bottom`, `left`, and `right`
816
+ (default). `tooltipEvent` is `hover` (default, also accessible through focus) or
817
+ `focus`. `showDelay` and `hideDelay` default to 0 milliseconds. `autoHide` defaults
818
+ to true; false allows the pointer to move onto the tooltip. `tooltipDisabled`
819
+ disables the hint without changing the element's disabled state. `tooltipOptions`
820
+ accepts these settings and overrides individual inputs for supplied keys.
821
+
822
+ Export as `avTooltip` to call `show()` or `hide()`. Escape dismisses a visible or
823
+ pending hint without moving focus. Existing `aria-describedby` IDs are preserved.
824
+ Templates should contain descriptive text only; use Popover for interactive
825
+ content. Tooltips supplement visible labels rather than replacing them.
826
+
827
+ The overlay follows scrolling and resizing, flips near viewport edges, and is
828
+ removed on destruction. It uses the native Popover top layer when available,
829
+ falling back to a fixed overlay. Set `--av-tooltip-background`, `--av-tooltip-color`,
830
+ `--av-tooltip-padding`, `--av-tooltip-radius`, and `--av-font-family` globally;
831
+ the panel is appended to the document body. Examples are available at `/tooltip`.
832
+
833
+ ## FileUpload
834
+
835
+ Import `AvFileUpload` in your standalone component:
836
+
837
+ ```html
838
+ <av-file-upload
839
+ url="/api/upload"
840
+ name="documents[]"
841
+ [multiple]="true"
842
+ accept="image/*,.pdf"
843
+ [maxFileSize]="5000000"
844
+ [fileLimit]="5"
845
+ (onUpload)="uploaded($event)"
846
+ />
847
+ ```
848
+
849
+ `mode` is `advanced` (default, includes drag and drop) or `basic`. `auto` starts
850
+ uploading after selection. Configure `disabled`, `headers`, `withCredentials`,
851
+ `timeout` (ms), `chooseLabel`, `uploadLabel`, and `cancelLabel`. HTTP upload uses
852
+ multipart POST; do not manually set its Content-Type boundary. Supply your own
853
+ backend, including server-side validation and authorization.
854
+
855
+ `accept` supports comma-separated extensions, MIME types and MIME wildcards.
856
+ `maxFileSize` is in bytes; `fileLimit` limits pending files. Single-file mode holds
857
+ one pending file until removed or uploaded. Duplicate files are rejected by name,
858
+ size and last-modified time. Invalid files produce messages; valid files remain.
859
+
860
+ For custom transport, set `customUpload` and handle `uploadHandler`. Its
861
+ `AvFileUploadRequest` contains `files`, an abort `signal`, `progress(percent)`,
862
+ `complete(response?)`, and `error(message)` callbacks. Honor cancellation and call
863
+ complete or error to settle the request. Late callbacks after cancellation are ignored.
864
+
865
+ Methods: `choose()`, `upload()`, `remove(file)`, `clear()`, `formatSize(bytes)`.
866
+ `clear()` aborts an active request and clears pending/completed files. Read-only
867
+ signals: `files`, `uploadedFiles`, `uploading`, `progress`. Events: `onSelect`
868
+ (accepted files and currentFiles), `onRemove`, `onClear`, `onProgress`, `onUpload`
869
+ (files and response), and `onError` (files, message and optional HTTP status).
870
+ Failed uploads retain their queue for retry. Destruction cancels requests and
871
+ releases image preview URLs.
872
+
873
+ Templates: `#header`, `#content`, `#file`, `#empty`. Header/content context exposes
874
+ pending files implicitly, uploadedFiles, uploading, progress, chooseCallback,
875
+ uploadCallback, clearCallback and removeFileCallback(file). File templates receive
876
+ the file implicitly and removeCallback(file). The Choose button is the keyboard
877
+ alternative to dropping files; errors and progress have accessible announcements.
878
+
879
+ Theme with `--av-upload-background`, `--av-upload-color`, `--av-upload-border`,
880
+ `--av-upload-radius`, and `--av-upload-accent`. Playground examples at
881
+ `/file-upload` simulate upload locally and do not send files to any server.
882
+
883
+ ## Additional Resources
884
+
885
+ For more information on using the Angular CLI, including detailed command references, visit the [Angular CLI Overview and Command Reference](https://angular.dev/tools/cli) page.
886
+
887
+ ## Breadcrumb
888
+
889
+ Import `AvBreadcrumb` and `AvBreadcrumbItem` from `avero-ui`. Requires `@angular/router`.
890
+
891
+ ```html
892
+ <av-breadcrumb [home]="home" [model]="items" ariaLabel="Page hierarchy" />
893
+ ```
894
+
895
+ Items accept label, icon (application CSS class), ariaLabel, routerLink, queryParams,
896
+ fragment, url, target, disabled, visible and command. The last visible item is the
897
+ current page. Home is optional. Commands receive { originalEvent, item }, also
898
+ emitted through onItemClick. Disabled items are not interactive.
899
+
900
+ Use #item with the implicit item plus index and last to customize content inside
901
+ the built-in link/button; do not nest interactive elements. #separator replaces
902
+ the decorative separator. ariaLabelledBy can reference an existing heading.
903
+ The layout wraps on narrow screens. Theme with --av-breadcrumb-background,
904
+ --av-breadcrumb-border, --av-breadcrumb-radius, --av-breadcrumb-color and
905
+ --av-breadcrumb-current-color.
906
+
907
+ ## ContextMenu
908
+
909
+ Import AvContextMenu and AvContextMenuItem from avero-ui.
910
+
911
+ ```html
912
+ <div #target tabindex="0" aria-haspopup="menu">Right-click here</div>
913
+ <av-context-menu [target]="target" [model]="items" />
914
+ ```
915
+
916
+ Inputs: model, target (HTMLElement), global, disabled, ariaLabel, inputId.
917
+ Use a stable unique inputId when rendering multiple menus with SSR.
918
+ Call show(MouseEvent | KeyboardEvent) for manual contextual selection and hide(true)
919
+ to dismiss with focus restoration. visible() is a readonly signal. Outputs:
920
+ onShow, onHide, onItemClick ({ originalEvent, item }).
921
+
922
+ Items support label, icon (CSS class), shortcut (display only), badge, items,
923
+ separator, disabled, visible, command, routerLink, url and target.
924
+ The #item template receives the implicit item and supplies non-interactive
925
+ content inside the built-in menuitem.
926
+
927
+ Targets automatically support right-click, Shift+F10 and the Context Menu key.
928
+ Provide a focusable target and aria-haspopup="menu". Arrow keys, Home/End,
929
+ Enter/Space, Escape, Tab and label-prefix search are supported.
930
+ Submenus open on hover or activation. Native popover top-layer rendering avoids
931
+ ancestor clipping where available; fixed positioning is the fallback.
932
+ Outside pointer/focus, page scrolling and resizing dismiss the menu.
933
+ Global mode is opt-in. Scope it carefully so ordinary browser context menus
934
+ remain available where appropriate.
935
+
936
+ Theme with --av-context-menu-background, --av-context-menu-color,
937
+ --av-context-menu-border, --av-context-menu-radius and --av-context-menu-hover.
938
+
939
+ ## Dock
940
+
941
+ Import `AvDock`, `AvDockItem` and `AvDockPosition` from `avero-ui`.
942
+
943
+ ```html
944
+ <av-dock [model]="items" position="bottom" ariaLabel="Applications">
945
+ <ng-template #item let-item let-index="index">
946
+ <span aria-hidden="true" [class]="item.icon"></span>
947
+ </ng-template>
948
+ </av-dock>
949
+ ```
950
+
951
+ Items require `label` and optionally accept `icon` (CSS class), `command`,
952
+ `disabled`, `visible`, `routerLink`, `queryParams`, `fragment`, `url` and `target`.
953
+ `onItemClick` emits `{ originalEvent, item }`. Positions: bottom (default), top,
954
+ left and right. The dock aligns inside its own layout box, without a fixed overlay.
955
+ Set its height in an application container to position it along an edge.
956
+ `magnification` defaults to true and can be disabled.
957
+
958
+ Accessibility: name the menu with `ariaLabel` or `ariaLabelledBy`. Visible labels
959
+ remain alongside custom icons. Templates must contain only non-interactive content.
960
+ One roving Tab stop, orientation-aware arrow keys, Home/End and Enter/Space support
961
+ keyboard operation; Tab leaves normally. Disabled items are skipped and cannot
962
+ activate, hidden items are omitted, and focus recovers if the active item is removed.
963
+ Targets are at least 64px. Reduced-motion and forced-colors preferences are supported.
964
+ Verify contrast and accessible names when customizing the theme or templates.
965
+
966
+ Theme variables: `--av-dock-background`, `--av-dock-border`, `--av-dock-radius`,
967
+ `--av-dock-color`, `--av-dock-hover`, `--av-dock-focus`.
968
+
969
+ ## Menu
970
+
971
+ Import `AvMenu` and `AvMenuItem` from `avero-ui`. Use `[model]="items"` for a
972
+ static menu or `[popup]="true"` with `menu.toggle(event)` / `menu.show(event)`
973
+ for an anchored popup. `hide(restoreFocus?)` closes it; `visible()` reports its
974
+ state. Outputs: `onShow`, `onHide`, `onItemClick` (`{ originalEvent, item }`).
975
+
976
+ Items support label, icon (CSS class), badge, shortcut (display only), separator,
977
+ disabled, visible, command, routerLink, queryParams, fragment, url and target.
978
+ Use `items` for one level of labeled groups. Name the menu with `ariaLabel` or
979
+ `ariaLabelledBy`; `inputId` identifies the menu for trigger relationships.
980
+ Templates `#item` and `#submenuheader` receive the item. `#start` and `#end`
981
+ provide content outside the menu. Keep item/group templates non-interactive.
982
+
983
+ Up/Down, Home/End, typeahead and Enter/Space provide keyboard navigation.
984
+ Disabled actions are skipped. Popup Escape/selection returns focus; Tab closes
985
+ and continues from the trigger. Outside click/focus dismisses without restoring
986
+ focus. Trigger ARIA attributes are managed while open and restored on close;
987
+ set aria-haspopup="menu" and bind aria-expanded/aria-controls in your template
988
+ so the relationship is exposed before first use. Menu targets are at least 44px.
989
+
990
+ Theme variables: `--av-menu-background`, `--av-menu-color`, `--av-menu-border`,
991
+ `--av-menu-radius`, `--av-menu-hover`, `--av-menu-focus`. Preserve contrast when
992
+ customizing colors, and provide meaningful labels for actions and groups.
993
+
994
+ ## Message
995
+
996
+ Import AvMessage from avero-ui to display inline feedback.
997
+
998
+ ```html
999
+ <av-message severity="success">Success: changes saved.</av-message>
1000
+ <av-message severity="error" variant="simple" avSize="sm">
1001
+ Error: username is required.
1002
+ </av-message>
1003
+ ```
1004
+
1005
+ Inputs: severity (success, info, warn, error, secondary, contrast), variant
1006
+ (filled, outlined, simple), avSize (sm, md, lg), text, icon (CSS class) and
1007
+ messageRole (alert, status, none). Defaults are info, filled and md.
1008
+ Projected content and text are both rendered; #icon replaces the decorative icon.
1009
+
1010
+ Errors default to alert and other severities to status. Use messageRole="none"
1011
+ for static content or within an existing live region. Put meaning in the message
1012
+ text, and use aria-describedby on inputs to associate validation feedback.
1013
+ Theme with --av-message-color, --av-message-background, --av-message-border and
1014
+ --av-message-radius.
1015
+
1016
+ ## Toast
1017
+
1018
+ Mount AvToast in your application shell and inject AvToastService into callers.
1019
+
1020
+ ```html
1021
+ <av-toast position="top-right" />
1022
+ ```
1023
+
1024
+ ```typescript
1025
+ toast.add({ severity: 'success', summary: 'Saved', detail: 'Changes saved.', life: 5000 });
1026
+ toast.addAll([{ summary: 'One' }, { summary: 'Two', sticky: true }]);
1027
+ toast.clear();
1028
+ ```
1029
+
1030
+ Use one mounted outlet per key and the same service instance for callers and
1031
+ outlets. Messages sent before mounting are not queued. Inputs: key, position,
1032
+ life, closeAriaLabel. Position supports top-left/center/right, bottom-left/center/right
1033
+ and center. Message fields: key, severity, summary, detail, life, sticky,
1034
+ closable and data. clear(key) clears one channel; clear() clears all.
1035
+ onClose emits { message, reason } with close, timeout or clear.
1036
+
1037
+ #message and #headless templates receive the message and closeFn callback.
1038
+ Headless templates supply their own accessible close action. Hover and focus
1039
+ independently pause the remaining lifetime. Use sticky for important content.
1040
+ Errors use alert; other severities use status. Opening does not steal focus.
1041
+ Timers and subscriptions are removed on destruction; notifications run only
1042
+ in the browser. The native popover top layer avoids clipping where supported,
1043
+ with a fixed-position fallback. Reduced motion is respected.
1044
+ Theme using --av-toast-width, --av-toast-z-index (fallback), and Message variables.