@aeris-ui/core 22.0.0-alpha.1 → 22.0.0-alpha.10

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 (288) hide show
  1. package/README.md +200 -191
  2. package/fesm2022/aeris-ui-core-accordion.mjs +646 -255
  3. package/fesm2022/aeris-ui-core-accordion.mjs.map +1 -1
  4. package/fesm2022/aeris-ui-core-animate-on-scroll.mjs +284 -103
  5. package/fesm2022/aeris-ui-core-animate-on-scroll.mjs.map +1 -1
  6. package/fesm2022/aeris-ui-core-auto-complete.mjs +1228 -446
  7. package/fesm2022/aeris-ui-core-auto-complete.mjs.map +1 -1
  8. package/fesm2022/aeris-ui-core-auto-focus.mjs +111 -61
  9. package/fesm2022/aeris-ui-core-auto-focus.mjs.map +1 -1
  10. package/fesm2022/aeris-ui-core-avatar.mjs +383 -101
  11. package/fesm2022/aeris-ui-core-avatar.mjs.map +1 -1
  12. package/fesm2022/aeris-ui-core-badge.mjs +562 -115
  13. package/fesm2022/aeris-ui-core-badge.mjs.map +1 -1
  14. package/fesm2022/aeris-ui-core-block-ui.mjs +209 -101
  15. package/fesm2022/aeris-ui-core-block-ui.mjs.map +1 -1
  16. package/fesm2022/aeris-ui-core-breadcrumb.mjs +581 -189
  17. package/fesm2022/aeris-ui-core-breadcrumb.mjs.map +1 -1
  18. package/fesm2022/aeris-ui-core-button-group.mjs +153 -38
  19. package/fesm2022/aeris-ui-core-button-group.mjs.map +1 -1
  20. package/fesm2022/aeris-ui-core-button.mjs +741 -139
  21. package/fesm2022/aeris-ui-core-button.mjs.map +1 -1
  22. package/fesm2022/aeris-ui-core-card.mjs +371 -101
  23. package/fesm2022/aeris-ui-core-card.mjs.map +1 -1
  24. package/fesm2022/aeris-ui-core-carousel.mjs +773 -369
  25. package/fesm2022/aeris-ui-core-carousel.mjs.map +1 -1
  26. package/fesm2022/aeris-ui-core-cascade-select.mjs +1171 -521
  27. package/fesm2022/aeris-ui-core-cascade-select.mjs.map +1 -1
  28. package/fesm2022/aeris-ui-core-chart.mjs +455 -258
  29. package/fesm2022/aeris-ui-core-chart.mjs.map +1 -1
  30. package/fesm2022/aeris-ui-core-checkbox.mjs +440 -140
  31. package/fesm2022/aeris-ui-core-checkbox.mjs.map +1 -1
  32. package/fesm2022/aeris-ui-core-chip.mjs +430 -117
  33. package/fesm2022/aeris-ui-core-chip.mjs.map +1 -1
  34. package/fesm2022/aeris-ui-core-class-names.mjs +87 -65
  35. package/fesm2022/aeris-ui-core-class-names.mjs.map +1 -1
  36. package/fesm2022/aeris-ui-core-code-block.mjs +637 -0
  37. package/fesm2022/aeris-ui-core-code-block.mjs.map +1 -0
  38. package/fesm2022/aeris-ui-core-color-picker.mjs +1340 -700
  39. package/fesm2022/aeris-ui-core-color-picker.mjs.map +1 -1
  40. package/fesm2022/aeris-ui-core-compare.mjs +823 -318
  41. package/fesm2022/aeris-ui-core-compare.mjs.map +1 -1
  42. package/fesm2022/aeris-ui-core-confirm-dialog.mjs +1404 -555
  43. package/fesm2022/aeris-ui-core-confirm-dialog.mjs.map +1 -1
  44. package/fesm2022/aeris-ui-core-confirm-popup.mjs +1471 -740
  45. package/fesm2022/aeris-ui-core-confirm-popup.mjs.map +1 -1
  46. package/fesm2022/aeris-ui-core-context-menu.mjs +918 -443
  47. package/fesm2022/aeris-ui-core-context-menu.mjs.map +1 -1
  48. package/fesm2022/aeris-ui-core-date-picker.mjs +1942 -1123
  49. package/fesm2022/aeris-ui-core-date-picker.mjs.map +1 -1
  50. package/fesm2022/aeris-ui-core-dialog.mjs +1079 -346
  51. package/fesm2022/aeris-ui-core-dialog.mjs.map +1 -1
  52. package/fesm2022/aeris-ui-core-divider.mjs +204 -43
  53. package/fesm2022/aeris-ui-core-divider.mjs.map +1 -1
  54. package/fesm2022/aeris-ui-core-drawer.mjs +1015 -322
  55. package/fesm2022/aeris-ui-core-drawer.mjs.map +1 -1
  56. package/fesm2022/aeris-ui-core-dynamic-dialog.mjs +410 -254
  57. package/fesm2022/aeris-ui-core-dynamic-dialog.mjs.map +1 -1
  58. package/fesm2022/aeris-ui-core-editor.mjs +967 -587
  59. package/fesm2022/aeris-ui-core-editor.mjs.map +1 -1
  60. package/fesm2022/aeris-ui-core-file-upload.mjs +1379 -522
  61. package/fesm2022/aeris-ui-core-file-upload.mjs.map +1 -1
  62. package/fesm2022/aeris-ui-core-filter-service.mjs +258 -301
  63. package/fesm2022/aeris-ui-core-filter-service.mjs.map +1 -1
  64. package/fesm2022/aeris-ui-core-fluid.mjs +68 -21
  65. package/fesm2022/aeris-ui-core-fluid.mjs.map +1 -1
  66. package/fesm2022/aeris-ui-core-focus-trap.mjs +206 -182
  67. package/fesm2022/aeris-ui-core-focus-trap.mjs.map +1 -1
  68. package/fesm2022/aeris-ui-core-form-field.mjs +688 -0
  69. package/fesm2022/aeris-ui-core-form-field.mjs.map +1 -0
  70. package/fesm2022/aeris-ui-core-galleria.mjs +2446 -1117
  71. package/fesm2022/aeris-ui-core-galleria.mjs.map +1 -1
  72. package/fesm2022/aeris-ui-core-glass.mjs +110 -33
  73. package/fesm2022/aeris-ui-core-glass.mjs.map +1 -1
  74. package/fesm2022/aeris-ui-core-icon-field.mjs +426 -98
  75. package/fesm2022/aeris-ui-core-icon-field.mjs.map +1 -1
  76. package/fesm2022/aeris-ui-core-inplace.mjs +452 -130
  77. package/fesm2022/aeris-ui-core-inplace.mjs.map +1 -1
  78. package/fesm2022/aeris-ui-core-input-group.mjs +413 -107
  79. package/fesm2022/aeris-ui-core-input-group.mjs.map +1 -1
  80. package/fesm2022/aeris-ui-core-input-mask.mjs +658 -255
  81. package/fesm2022/aeris-ui-core-input-mask.mjs.map +1 -1
  82. package/fesm2022/aeris-ui-core-input-number.mjs +926 -291
  83. package/fesm2022/aeris-ui-core-input-number.mjs.map +1 -1
  84. package/fesm2022/aeris-ui-core-input-otp.mjs +678 -264
  85. package/fesm2022/aeris-ui-core-input-otp.mjs.map +1 -1
  86. package/fesm2022/aeris-ui-core-input-text.mjs +625 -158
  87. package/fesm2022/aeris-ui-core-input-text.mjs.map +1 -1
  88. package/fesm2022/aeris-ui-core-key-filter.mjs +263 -201
  89. package/fesm2022/aeris-ui-core-key-filter.mjs.map +1 -1
  90. package/fesm2022/aeris-ui-core-mega-menu.mjs +613 -382
  91. package/fesm2022/aeris-ui-core-mega-menu.mjs.map +1 -1
  92. package/fesm2022/aeris-ui-core-menu.mjs +1062 -472
  93. package/fesm2022/aeris-ui-core-menu.mjs.map +1 -1
  94. package/fesm2022/aeris-ui-core-menubar.mjs +994 -393
  95. package/fesm2022/aeris-ui-core-menubar.mjs.map +1 -1
  96. package/fesm2022/aeris-ui-core-message.mjs +477 -145
  97. package/fesm2022/aeris-ui-core-message.mjs.map +1 -1
  98. package/fesm2022/aeris-ui-core-meter-group.mjs +623 -230
  99. package/fesm2022/aeris-ui-core-meter-group.mjs.map +1 -1
  100. package/fesm2022/aeris-ui-core-multi-select.mjs +1598 -561
  101. package/fesm2022/aeris-ui-core-multi-select.mjs.map +1 -1
  102. package/fesm2022/aeris-ui-core-order-list.mjs +592 -220
  103. package/fesm2022/aeris-ui-core-order-list.mjs.map +1 -1
  104. package/fesm2022/aeris-ui-core-organization-chart.mjs +485 -199
  105. package/fesm2022/aeris-ui-core-organization-chart.mjs.map +1 -1
  106. package/fesm2022/aeris-ui-core-paginator.mjs +428 -123
  107. package/fesm2022/aeris-ui-core-paginator.mjs.map +1 -1
  108. package/fesm2022/aeris-ui-core-panel.mjs +596 -196
  109. package/fesm2022/aeris-ui-core-panel.mjs.map +1 -1
  110. package/fesm2022/aeris-ui-core-password.mjs +925 -249
  111. package/fesm2022/aeris-ui-core-password.mjs.map +1 -1
  112. package/fesm2022/aeris-ui-core-pick-list.mjs +1280 -659
  113. package/fesm2022/aeris-ui-core-pick-list.mjs.map +1 -1
  114. package/fesm2022/aeris-ui-core-popover.mjs +912 -375
  115. package/fesm2022/aeris-ui-core-popover.mjs.map +1 -1
  116. package/fesm2022/aeris-ui-core-progress-bar.mjs +549 -176
  117. package/fesm2022/aeris-ui-core-progress-bar.mjs.map +1 -1
  118. package/fesm2022/aeris-ui-core-progress-spinner.mjs +410 -133
  119. package/fesm2022/aeris-ui-core-progress-spinner.mjs.map +1 -1
  120. package/fesm2022/aeris-ui-core-radio-button.mjs +394 -124
  121. package/fesm2022/aeris-ui-core-radio-button.mjs.map +1 -1
  122. package/fesm2022/aeris-ui-core-rating.mjs +506 -231
  123. package/fesm2022/aeris-ui-core-rating.mjs.map +1 -1
  124. package/fesm2022/aeris-ui-core-scroll-panel.mjs +457 -154
  125. package/fesm2022/aeris-ui-core-scroll-panel.mjs.map +1 -1
  126. package/fesm2022/aeris-ui-core-scroll-top.mjs +226 -63
  127. package/fesm2022/aeris-ui-core-scroll-top.mjs.map +1 -1
  128. package/fesm2022/aeris-ui-core-select.mjs +1845 -648
  129. package/fesm2022/aeris-ui-core-select.mjs.map +1 -1
  130. package/fesm2022/aeris-ui-core-skeleton.mjs +149 -45
  131. package/fesm2022/aeris-ui-core-skeleton.mjs.map +1 -1
  132. package/fesm2022/aeris-ui-core-slider.mjs +884 -430
  133. package/fesm2022/aeris-ui-core-slider.mjs.map +1 -1
  134. package/fesm2022/aeris-ui-core-speed-dial.mjs +861 -337
  135. package/fesm2022/aeris-ui-core-speed-dial.mjs.map +1 -1
  136. package/fesm2022/aeris-ui-core-split-button.mjs +955 -266
  137. package/fesm2022/aeris-ui-core-split-button.mjs.map +1 -1
  138. package/fesm2022/aeris-ui-core-splitter.mjs +812 -352
  139. package/fesm2022/aeris-ui-core-splitter.mjs.map +1 -1
  140. package/fesm2022/aeris-ui-core-stepper.mjs +697 -254
  141. package/fesm2022/aeris-ui-core-stepper.mjs.map +1 -1
  142. package/fesm2022/aeris-ui-core-style-class.mjs +587 -342
  143. package/fesm2022/aeris-ui-core-style-class.mjs.map +1 -1
  144. package/fesm2022/aeris-ui-core-table.mjs +2034 -869
  145. package/fesm2022/aeris-ui-core-table.mjs.map +1 -1
  146. package/fesm2022/aeris-ui-core-tabs.mjs +789 -279
  147. package/fesm2022/aeris-ui-core-tabs.mjs.map +1 -1
  148. package/fesm2022/aeris-ui-core-textarea.mjs +856 -219
  149. package/fesm2022/aeris-ui-core-textarea.mjs.map +1 -1
  150. package/fesm2022/aeris-ui-core-theme-builder.mjs +1284 -1399
  151. package/fesm2022/aeris-ui-core-theme-builder.mjs.map +1 -1
  152. package/fesm2022/aeris-ui-core-theming.mjs +132 -144
  153. package/fesm2022/aeris-ui-core-theming.mjs.map +1 -1
  154. package/fesm2022/aeris-ui-core-tiered-menu.mjs +909 -441
  155. package/fesm2022/aeris-ui-core-tiered-menu.mjs.map +1 -1
  156. package/fesm2022/aeris-ui-core-timeline.mjs +407 -131
  157. package/fesm2022/aeris-ui-core-timeline.mjs.map +1 -1
  158. package/fesm2022/aeris-ui-core-toast.mjs +1076 -384
  159. package/fesm2022/aeris-ui-core-toast.mjs.map +1 -1
  160. package/fesm2022/aeris-ui-core-toggle-switch.mjs +398 -132
  161. package/fesm2022/aeris-ui-core-toggle-switch.mjs.map +1 -1
  162. package/fesm2022/aeris-ui-core-toolbar.mjs +458 -121
  163. package/fesm2022/aeris-ui-core-toolbar.mjs.map +1 -1
  164. package/fesm2022/aeris-ui-core-tooltip.mjs +625 -330
  165. package/fesm2022/aeris-ui-core-tooltip.mjs.map +1 -1
  166. package/fesm2022/aeris-ui-core-tree-select.mjs +1453 -621
  167. package/fesm2022/aeris-ui-core-tree-select.mjs.map +1 -1
  168. package/fesm2022/aeris-ui-core-tree-table.mjs +2019 -940
  169. package/fesm2022/aeris-ui-core-tree-table.mjs.map +1 -1
  170. package/fesm2022/aeris-ui-core-tree.mjs +1107 -658
  171. package/fesm2022/aeris-ui-core-tree.mjs.map +1 -1
  172. package/fesm2022/aeris-ui-core.mjs +985 -316
  173. package/fesm2022/aeris-ui-core.mjs.map +1 -1
  174. package/package.json +20 -8
  175. package/schematics/ng-add/schema.json +1 -1
  176. package/schematics/runtime/schematics/ng-add/options.js +4 -4
  177. package/schematics/runtime/schematics/ng-add/options.js.map +1 -1
  178. package/schematics/runtime/schematics/ng-add/workspace.js +1 -1
  179. package/schematics/runtime/schematics/ng-add/workspace.js.map +1 -1
  180. package/schematics/runtime/theme-builder/aeris-contrast.js +6 -17
  181. package/schematics/runtime/theme-builder/aeris-contrast.js.map +1 -1
  182. package/schematics/runtime/theme-builder/aeris-foundation.js +10 -4
  183. package/schematics/runtime/theme-builder/aeris-foundation.js.map +1 -1
  184. package/schematics/runtime/theme-builder/aeris-semantic-tones.js +28 -5
  185. package/schematics/runtime/theme-builder/aeris-semantic-tones.js.map +1 -1
  186. package/schematics/runtime/theme-builder/aeris-theme-generator.js +2 -2
  187. package/schematics/runtime/theme-builder/aeris-theme-generator.js.map +1 -1
  188. package/schematics/runtime/theme-builder/aeris-theme-resolver.js +22 -8
  189. package/schematics/runtime/theme-builder/aeris-theme-resolver.js.map +1 -1
  190. package/schematics/runtime/theme-builder/aeris-theme-tokens.js +12 -4
  191. package/schematics/runtime/theme-builder/aeris-theme-tokens.js.map +1 -1
  192. package/schematics/runtime/theme-builder/aeris-theme-validation.js +7 -1
  193. package/schematics/runtime/theme-builder/aeris-theme-validation.js.map +1 -1
  194. package/schematics/runtime/theme-builder/aeris-theme.js +49 -33
  195. package/schematics/runtime/theme-builder/aeris-theme.js.map +1 -1
  196. package/styles/_fallback-colors.scss +10 -0
  197. package/styles/_mobile.scss +16 -0
  198. package/styles/_tokens.scss +5 -5
  199. package/styles/aeris.css +412 -125
  200. package/styles/controls.css +61 -29
  201. package/tools/aeris-theme.mjs +2 -2
  202. package/tools/aeris-theme.schema.json +5 -2
  203. package/types/aeris-ui-core-accordion.d.ts +167 -93
  204. package/types/aeris-ui-core-animate-on-scroll.d.ts +72 -31
  205. package/types/aeris-ui-core-auto-complete.d.ts +327 -140
  206. package/types/aeris-ui-core-auto-focus.d.ts +24 -16
  207. package/types/aeris-ui-core-avatar.d.ts +112 -42
  208. package/types/aeris-ui-core-badge.d.ts +160 -46
  209. package/types/aeris-ui-core-block-ui.d.ts +47 -27
  210. package/types/aeris-ui-core-breadcrumb.d.ts +163 -92
  211. package/types/aeris-ui-core-button-group.d.ts +37 -16
  212. package/types/aeris-ui-core-button.d.ts +226 -67
  213. package/types/aeris-ui-core-card.d.ts +74 -37
  214. package/types/aeris-ui-core-carousel.d.ts +201 -117
  215. package/types/aeris-ui-core-cascade-select.d.ts +257 -123
  216. package/types/aeris-ui-core-chart.d.ts +134 -84
  217. package/types/aeris-ui-core-checkbox.d.ts +139 -54
  218. package/types/aeris-ui-core-chip.d.ts +116 -51
  219. package/types/aeris-ui-core-class-names.d.ts +22 -20
  220. package/types/aeris-ui-core-code-block.d.ts +188 -0
  221. package/types/aeris-ui-core-color-picker.d.ts +348 -143
  222. package/types/aeris-ui-core-compare.d.ts +224 -102
  223. package/types/aeris-ui-core-confirm-dialog.d.ts +442 -245
  224. package/types/aeris-ui-core-confirm-popup.d.ts +442 -263
  225. package/types/aeris-ui-core-context-menu.d.ts +264 -146
  226. package/types/aeris-ui-core-date-picker.d.ts +489 -217
  227. package/types/aeris-ui-core-dialog.d.ts +288 -117
  228. package/types/aeris-ui-core-divider.d.ts +58 -20
  229. package/types/aeris-ui-core-drawer.d.ts +273 -112
  230. package/types/aeris-ui-core-dynamic-dialog.d.ts +158 -137
  231. package/types/aeris-ui-core-editor.d.ts +250 -123
  232. package/types/aeris-ui-core-file-upload.d.ts +367 -197
  233. package/types/aeris-ui-core-filter-service.d.ts +48 -52
  234. package/types/aeris-ui-core-fluid.d.ts +12 -9
  235. package/types/aeris-ui-core-focus-trap.d.ts +39 -31
  236. package/types/aeris-ui-core-form-field.d.ts +163 -0
  237. package/types/aeris-ui-core-galleria.d.ts +588 -256
  238. package/types/aeris-ui-core-glass.d.ts +24 -11
  239. package/types/aeris-ui-core-icon-field.d.ts +94 -32
  240. package/types/aeris-ui-core-inplace.d.ts +123 -62
  241. package/types/aeris-ui-core-input-group.d.ts +84 -33
  242. package/types/aeris-ui-core-input-mask.d.ts +194 -69
  243. package/types/aeris-ui-core-input-number.d.ts +272 -87
  244. package/types/aeris-ui-core-input-otp.d.ts +191 -81
  245. package/types/aeris-ui-core-input-text.d.ts +185 -60
  246. package/types/aeris-ui-core-key-filter.d.ts +53 -39
  247. package/types/aeris-ui-core-mega-menu.d.ts +175 -121
  248. package/types/aeris-ui-core-menu.d.ts +277 -168
  249. package/types/aeris-ui-core-menubar.d.ts +273 -135
  250. package/types/aeris-ui-core-message.d.ts +132 -60
  251. package/types/aeris-ui-core-meter-group.d.ts +163 -90
  252. package/types/aeris-ui-core-multi-select.d.ts +439 -180
  253. package/types/aeris-ui-core-order-list.d.ts +144 -66
  254. package/types/aeris-ui-core-organization-chart.d.ts +133 -77
  255. package/types/aeris-ui-core-paginator.d.ts +93 -38
  256. package/types/aeris-ui-core-panel.d.ts +149 -78
  257. package/types/aeris-ui-core-password.d.ts +258 -102
  258. package/types/aeris-ui-core-pick-list.d.ts +374 -179
  259. package/types/aeris-ui-core-popover.d.ts +219 -105
  260. package/types/aeris-ui-core-progress-bar.d.ts +157 -73
  261. package/types/aeris-ui-core-progress-spinner.d.ts +110 -48
  262. package/types/aeris-ui-core-radio-button.d.ts +124 -50
  263. package/types/aeris-ui-core-rating.d.ts +149 -76
  264. package/types/aeris-ui-core-scroll-panel.d.ts +142 -64
  265. package/types/aeris-ui-core-scroll-top.d.ts +66 -29
  266. package/types/aeris-ui-core-select.d.ts +475 -217
  267. package/types/aeris-ui-core-skeleton.d.ts +39 -17
  268. package/types/aeris-ui-core-slider.d.ts +270 -115
  269. package/types/aeris-ui-core-speed-dial.d.ts +241 -111
  270. package/types/aeris-ui-core-split-button.d.ts +267 -113
  271. package/types/aeris-ui-core-splitter.d.ts +225 -106
  272. package/types/aeris-ui-core-stepper.d.ts +184 -91
  273. package/types/aeris-ui-core-style-class.d.ts +141 -71
  274. package/types/aeris-ui-core-table.d.ts +596 -304
  275. package/types/aeris-ui-core-tabs.d.ts +181 -76
  276. package/types/aeris-ui-core-textarea.d.ts +261 -78
  277. package/types/aeris-ui-core-theme-builder.d.ts +472 -450
  278. package/types/aeris-ui-core-theming.d.ts +42 -45
  279. package/types/aeris-ui-core-tiered-menu.d.ts +251 -142
  280. package/types/aeris-ui-core-timeline.d.ts +109 -71
  281. package/types/aeris-ui-core-toast.d.ts +225 -115
  282. package/types/aeris-ui-core-toggle-switch.d.ts +125 -51
  283. package/types/aeris-ui-core-toolbar.d.ts +98 -41
  284. package/types/aeris-ui-core-tooltip.d.ts +157 -88
  285. package/types/aeris-ui-core-tree-select.d.ts +364 -171
  286. package/types/aeris-ui-core-tree-table.d.ts +566 -286
  287. package/types/aeris-ui-core-tree.d.ts +270 -165
  288. package/types/aeris-ui-core.d.ts +197 -72
@@ -1,247 +1,448 @@
1
- import { NgTemplateOutlet } from '@angular/common';
2
- import * as i0 from '@angular/core';
3
- import { inject, TemplateRef, Directive, numberAttribute, ElementRef, viewChildren, signal, model, input, booleanAttribute, output, contentChild, computed, afterNextRender, forwardRef, Component } from '@angular/core';
4
- import { NG_VALUE_ACCESSOR } from '@angular/forms';
5
-
6
- class AerisInputOtpSeparatorTemplate {
7
- template = inject(TemplateRef);
8
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: AerisInputOtpSeparatorTemplate, deps: [], target: i0.ɵɵFactoryTarget.Directive });
9
- static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.0.6", type: AerisInputOtpSeparatorTemplate, isStandalone: true, selector: "ng-template[aerisInputOtpSeparator]", ngImport: i0 });
10
- }
11
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: AerisInputOtpSeparatorTemplate, decorators: [{
12
- type: Directive,
13
- args: [{ selector: 'ng-template[aerisInputOtpSeparator]' }]
14
- }] });
1
+ import { NgTemplateOutlet } from "@angular/common";
2
+ import * as i0 from "@angular/core";
3
+ import { Component, Directive, ElementRef, TemplateRef, afterNextRender, booleanAttribute, computed, contentChild, forwardRef, inject, input, model, numberAttribute, output, signal, viewChildren } from "@angular/core";
4
+ import { NG_VALUE_ACCESSOR } from "@angular/forms";
5
+ import { ɵaerisDisplayInvalid } from "@aeris-ui/core";
6
+ var AerisInputOtpSeparatorTemplate = class AerisInputOtpSeparatorTemplate {
7
+ template = inject(TemplateRef);
8
+ static ɵfac = i0.ɵɵngDeclareFactory({
9
+ minVersion: "12.0.0",
10
+ version: "22.2.2",
11
+ ngImport: i0,
12
+ type: AerisInputOtpSeparatorTemplate,
13
+ deps: [],
14
+ target: i0.ɵɵFactoryTarget.Directive
15
+ });
16
+ static ɵdir = i0.ɵɵngDeclareDirective({
17
+ minVersion: "14.0.0",
18
+ version: "22.2.2",
19
+ type: AerisInputOtpSeparatorTemplate,
20
+ isStandalone: true,
21
+ selector: "ng-template[aerisInputOtpSeparator]",
22
+ ngImport: i0
23
+ });
24
+ };
25
+ i0.ɵɵngDeclareClassMetadata({
26
+ minVersion: "12.0.0",
27
+ version: "22.2.2",
28
+ ngImport: i0,
29
+ type: AerisInputOtpSeparatorTemplate,
30
+ decorators: [{
31
+ type: Directive,
32
+ args: [{ selector: "ng-template[aerisInputOtpSeparator]" }]
33
+ }]
34
+ });
15
35
  const normalizeLength = (value) => Math.max(1, Math.floor(numberAttribute(value, 4)));
16
36
  let inputOtpId = 0;
17
- class AerisInputOtpComponent {
18
- host = inject(ElementRef);
19
- inputElements = viewChildren('otpInput', /* @ts-ignore */
20
- ...(ngDevMode ? [{ debugName: "inputElements" }] : /* istanbul ignore next */ []));
21
- generatedId = `aeris-input-otp-${++inputOtpId}`;
22
- formDisabled = signal(false, /* @ts-ignore */
23
- ...(ngDevMode ? [{ debugName: "formDisabled" }] : /* istanbul ignore next */ []));
24
- onChange = () => undefined;
25
- onTouched = () => undefined;
26
- value = model('', /* @ts-ignore */
27
- ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
28
- length = input(4, { ...(ngDevMode ? { debugName: "length" } : /* istanbul ignore next */ {}), transform: normalizeLength });
29
- mode = input('numeric', /* @ts-ignore */
30
- ...(ngDevMode ? [{ debugName: "mode" }] : /* istanbul ignore next */ []));
31
- inputId = input('', /* @ts-ignore */
32
- ...(ngDevMode ? [{ debugName: "inputId" }] : /* istanbul ignore next */ []));
33
- name = input('', /* @ts-ignore */
34
- ...(ngDevMode ? [{ debugName: "name" }] : /* istanbul ignore next */ []));
35
- autocomplete = input('one-time-code', /* @ts-ignore */
36
- ...(ngDevMode ? [{ debugName: "autocomplete" }] : /* istanbul ignore next */ []));
37
- ariaLabel = input('', /* @ts-ignore */
38
- ...(ngDevMode ? [{ debugName: "ariaLabel" }] : /* istanbul ignore next */ []));
39
- ariaLabelledby = input('', /* @ts-ignore */
40
- ...(ngDevMode ? [{ debugName: "ariaLabelledby" }] : /* istanbul ignore next */ []));
41
- ariaDescribedby = input('', /* @ts-ignore */
42
- ...(ngDevMode ? [{ debugName: "ariaDescribedby" }] : /* istanbul ignore next */ []));
43
- slotAriaLabel = input('Character {0} of {1}', /* @ts-ignore */
44
- ...(ngDevMode ? [{ debugName: "slotAriaLabel" }] : /* istanbul ignore next */ []));
45
- size = input('md', /* @ts-ignore */
46
- ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
47
- appearance = input('outline', /* @ts-ignore */
48
- ...(ngDevMode ? [{ debugName: "appearance" }] : /* istanbul ignore next */ []));
49
- mask = input(false, { ...(ngDevMode ? { debugName: "mask" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
50
- autoFocus = input(false, { ...(ngDevMode ? { debugName: "autoFocus" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
51
- selectOnFocus = input(true, { ...(ngDevMode ? { debugName: "selectOnFocus" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
52
- disabled = input(false, { ...(ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
53
- readonly = input(false, { ...(ngDevMode ? { debugName: "readonly" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
54
- required = input(false, { ...(ngDevMode ? { debugName: "required" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
55
- invalid = input(false, { ...(ngDevMode ? { debugName: "invalid" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
56
- fluid = input(false, { ...(ngDevMode ? { debugName: "fluid" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
57
- valueInput = output();
58
- completed = output();
59
- focused = output();
60
- blurred = output();
61
- touch = output();
62
- separatorTemplate = contentChild(AerisInputOtpSeparatorTemplate, /* @ts-ignore */
63
- ...(ngDevMode ? [{ debugName: "separatorTemplate" }] : /* istanbul ignore next */ []));
64
- effectiveDisabled = computed(() => this.disabled() || this.formDisabled(), /* @ts-ignore */
65
- ...(ngDevMode ? [{ debugName: "effectiveDisabled" }] : /* istanbul ignore next */ []));
66
- effectiveInputMode = computed(() => this.mode() === 'numeric' ? 'numeric' : 'text', /* @ts-ignore */
67
- ...(ngDevMode ? [{ debugName: "effectiveInputMode" }] : /* istanbul ignore next */ []));
68
- slots = computed(() => {
69
- const value = this.normalizedValue();
70
- return Array.from({ length: this.length() }, (_, index) => ({
71
- index,
72
- position: index + 1,
73
- id: index === 0 && this.inputId() ? this.inputId() : `${this.generatedId}-${index + 1}`,
74
- value: value[index] ?? '',
75
- ariaLabel: this.slotAriaLabel()
76
- .replace('{0}', String(index + 1))
77
- .replace('{1}', String(this.length())),
78
- }));
79
- }, /* @ts-ignore */
80
- ...(ngDevMode ? [{ debugName: "slots" }] : /* istanbul ignore next */ []));
81
- normalizedValue = computed(() => this.filterCharacters(this.value()).slice(0, this.length()), /* @ts-ignore */
82
- ...(ngDevMode ? [{ debugName: "normalizedValue" }] : /* istanbul ignore next */ []));
83
- constructor() {
84
- afterNextRender(() => {
85
- if (this.autoFocus() && !this.effectiveDisabled())
86
- this.focus();
87
- });
88
- }
89
- writeValue(value) {
90
- const next = typeof value === 'string' || typeof value === 'number' ? String(value) : '';
91
- this.value.set(this.filterCharacters(next).slice(0, this.length()));
92
- }
93
- registerOnChange(callback) {
94
- this.onChange = callback;
95
- }
96
- registerOnTouched(callback) {
97
- this.onTouched = callback;
98
- }
99
- setDisabledState(disabled) {
100
- this.formDisabled.set(disabled);
101
- }
102
- focus(index = 0, options) {
103
- const targetIndex = Math.min(Math.max(index, 0), this.length() - 1);
104
- this.inputElements()[targetIndex]?.nativeElement.focus(options);
105
- }
106
- clear() {
107
- if (this.effectiveDisabled() || this.readonly())
108
- return;
109
- this.commit('', new Event('clear'));
110
- queueMicrotask(() => this.focus());
111
- }
112
- handleBeforeInput(event, index) {
113
- if (event.inputType.startsWith('delete') || !event.data)
114
- return;
115
- const accepted = this.filterCharacters(event.data);
116
- if (!accepted) {
117
- event.preventDefault();
118
- return;
119
- }
120
- if (accepted.length > 1) {
121
- event.preventDefault();
122
- this.insertCharacters(accepted, index, event);
123
- }
124
- }
125
- handleInput(event, index) {
126
- const inputElement = event.target;
127
- const accepted = this.filterCharacters(inputElement.value);
128
- if (!accepted) {
129
- inputElement.value = this.normalizedValue()[index] ?? '';
130
- return;
131
- }
132
- this.insertCharacters(accepted, index, event);
133
- }
134
- handleKeydown(event, index) {
135
- if (this.effectiveDisabled() || this.readonly())
136
- return;
137
- if (event.key === 'ArrowLeft') {
138
- event.preventDefault();
139
- this.focus(index - 1);
140
- return;
141
- }
142
- if (event.key === 'ArrowRight') {
143
- event.preventDefault();
144
- this.focus(index + 1);
145
- return;
146
- }
147
- if (event.key === 'Home') {
148
- event.preventDefault();
149
- this.focus(0);
150
- return;
151
- }
152
- if (event.key === 'End') {
153
- event.preventDefault();
154
- this.focus(this.length() - 1);
155
- return;
156
- }
157
- if (event.key === 'Backspace') {
158
- event.preventDefault();
159
- const currentValue = this.normalizedValue();
160
- const targetIndex = currentValue[index] ? index : Math.max(0, index - 1);
161
- this.removeAt(targetIndex, event);
162
- queueMicrotask(() => this.focus(targetIndex));
163
- return;
164
- }
165
- if (event.key === 'Delete') {
166
- event.preventDefault();
167
- this.removeAt(index, event);
168
- }
169
- }
170
- handlePaste(event, index) {
171
- const pasted = this.filterCharacters(event.clipboardData?.getData('text') ?? '');
172
- if (!pasted)
173
- return;
174
- event.preventDefault();
175
- this.insertCharacters(pasted, index, event);
176
- }
177
- handleFocus(event) {
178
- if (this.selectOnFocus()) {
179
- event.target.select();
180
- }
181
- this.focused.emit(event);
182
- }
183
- handleFocusOut(event) {
184
- const nextTarget = event.relatedTarget;
185
- if (nextTarget instanceof Node && this.host.nativeElement.contains(nextTarget))
186
- return;
187
- this.touch.emit();
188
- this.onTouched();
189
- }
190
- insertCharacters(characters, index, event) {
191
- const slots = Array.from({ length: this.length() }, (_, slotIndex) => this.normalizedValue()[slotIndex] ?? '');
192
- let nextIndex = index;
193
- for (const character of characters) {
194
- if (nextIndex >= slots.length)
195
- break;
196
- slots[nextIndex] = character;
197
- nextIndex += 1;
198
- }
199
- const nextValue = slots.join('');
200
- this.commit(nextValue, event);
201
- queueMicrotask(() => this.focus(Math.min(nextIndex, this.length() - 1)));
202
- }
203
- removeAt(index, event) {
204
- const slots = Array.from({ length: this.length() }, (_, slotIndex) => this.normalizedValue()[slotIndex] ?? '');
205
- slots[index] = '';
206
- this.commit(slots.join(''), event);
207
- }
208
- commit(value, event) {
209
- const nextValue = this.filterCharacters(value).slice(0, this.length());
210
- const wasComplete = this.normalizedValue().length === this.length();
211
- if (this.value() !== nextValue) {
212
- this.value.set(nextValue);
213
- this.valueInput.emit(nextValue);
214
- this.onChange(nextValue);
215
- }
216
- if (!wasComplete && nextValue.length === this.length()) {
217
- this.completed.emit({ originalEvent: event, value: nextValue });
218
- }
219
- }
220
- filterCharacters(value) {
221
- const pattern = this.mode() === 'numeric' ? /[0-9]/g : /[A-Za-z0-9]/g;
222
- return value.match(pattern)?.join('') ?? '';
223
- }
224
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: AerisInputOtpComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
225
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: AerisInputOtpComponent, isStandalone: true, selector: "aeris-input-otp", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, length: { classPropertyName: "length", publicName: "length", isSignal: true, isRequired: false, transformFunction: null }, mode: { classPropertyName: "mode", publicName: "mode", isSignal: true, isRequired: false, transformFunction: null }, inputId: { classPropertyName: "inputId", publicName: "inputId", isSignal: true, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, autocomplete: { classPropertyName: "autocomplete", publicName: "autocomplete", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelledby: { classPropertyName: "ariaLabelledby", publicName: "ariaLabelledby", isSignal: true, isRequired: false, transformFunction: null }, ariaDescribedby: { classPropertyName: "ariaDescribedby", publicName: "ariaDescribedby", isSignal: true, isRequired: false, transformFunction: null }, slotAriaLabel: { classPropertyName: "slotAriaLabel", publicName: "slotAriaLabel", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, appearance: { classPropertyName: "appearance", publicName: "appearance", isSignal: true, isRequired: false, transformFunction: null }, mask: { classPropertyName: "mask", publicName: "mask", isSignal: true, isRequired: false, transformFunction: null }, autoFocus: { classPropertyName: "autoFocus", publicName: "autoFocus", isSignal: true, isRequired: false, transformFunction: null }, selectOnFocus: { classPropertyName: "selectOnFocus", publicName: "selectOnFocus", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, invalid: { classPropertyName: "invalid", publicName: "invalid", isSignal: true, isRequired: false, transformFunction: null }, fluid: { classPropertyName: "fluid", publicName: "fluid", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange", valueInput: "valueInput", completed: "completed", focused: "focused", blurred: "blurred", touch: "touch" }, host: { properties: { "attr.data-fluid": "fluid() || null" } }, providers: [
226
- {
227
- provide: NG_VALUE_ACCESSOR,
228
- useExisting: forwardRef(() => AerisInputOtpComponent),
229
- multi: true,
230
- },
231
- ], queries: [{ propertyName: "separatorTemplate", first: true, predicate: AerisInputOtpSeparatorTemplate, descendants: true, isSignal: true }], viewQueries: [{ propertyName: "inputElements", predicate: ["otpInput"], descendants: true, isSignal: true }], ngImport: i0, template: `
37
+ var AerisInputOtpComponent = class AerisInputOtpComponent {
38
+ host = inject(ElementRef);
39
+ inputElements = viewChildren("otpInput", ...ngDevMode ? [{ debugName: "inputElements" }] : /* istanbul ignore next */ []);
40
+ generatedId = `aeris-input-otp-${++inputOtpId}`;
41
+ formDisabled = signal(false, ...ngDevMode ? [{ debugName: "formDisabled" }] : /* istanbul ignore next */ []);
42
+ onChange = () => void 0;
43
+ onTouched = () => void 0;
44
+ value = model("", ...ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []);
45
+ length = input(4, {
46
+ ...ngDevMode ? { debugName: "length" } : /* istanbul ignore next */ {},
47
+ transform: normalizeLength
48
+ });
49
+ mode = input("numeric", ...ngDevMode ? [{ debugName: "mode" }] : /* istanbul ignore next */ []);
50
+ inputId = input("", ...ngDevMode ? [{ debugName: "inputId" }] : /* istanbul ignore next */ []);
51
+ name = input("", ...ngDevMode ? [{ debugName: "name" }] : /* istanbul ignore next */ []);
52
+ autocomplete = input("one-time-code", ...ngDevMode ? [{ debugName: "autocomplete" }] : /* istanbul ignore next */ []);
53
+ ariaLabel = input("", ...ngDevMode ? [{ debugName: "ariaLabel" }] : /* istanbul ignore next */ []);
54
+ ariaLabelledBy = input("", ...ngDevMode ? [{ debugName: "ariaLabelledBy" }] : /* istanbul ignore next */ []);
55
+ ariaDescribedBy = input("", ...ngDevMode ? [{ debugName: "ariaDescribedBy" }] : /* istanbul ignore next */ []);
56
+ slotAriaLabel = input("Character {0} of {1}", ...ngDevMode ? [{ debugName: "slotAriaLabel" }] : /* istanbul ignore next */ []);
57
+ size = input("md", ...ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []);
58
+ appearance = input("outline", ...ngDevMode ? [{ debugName: "appearance" }] : /* istanbul ignore next */ []);
59
+ mask = input(false, {
60
+ ...ngDevMode ? { debugName: "mask" } : /* istanbul ignore next */ {},
61
+ transform: booleanAttribute
62
+ });
63
+ autoFocus = input(false, {
64
+ ...ngDevMode ? { debugName: "autoFocus" } : /* istanbul ignore next */ {},
65
+ transform: booleanAttribute
66
+ });
67
+ selectOnFocus = input(true, {
68
+ ...ngDevMode ? { debugName: "selectOnFocus" } : /* istanbul ignore next */ {},
69
+ transform: booleanAttribute
70
+ });
71
+ disabled = input(false, {
72
+ ...ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {},
73
+ transform: booleanAttribute
74
+ });
75
+ readonly = input(false, {
76
+ ...ngDevMode ? { debugName: "readonly" } : /* istanbul ignore next */ {},
77
+ transform: booleanAttribute
78
+ });
79
+ required = input(false, {
80
+ ...ngDevMode ? { debugName: "required" } : /* istanbul ignore next */ {},
81
+ transform: booleanAttribute
82
+ });
83
+ invalid = input(false, {
84
+ ...ngDevMode ? { debugName: "invalid" } : /* istanbul ignore next */ {},
85
+ transform: booleanAttribute
86
+ });
87
+ touched = input(null, ...ngDevMode ? [{ debugName: "touched" }] : /* istanbul ignore next */ []);
88
+ displayInvalid = computed(() => ɵaerisDisplayInvalid(this.invalid(), this.touched()), ...ngDevMode ? [{ debugName: "displayInvalid" }] : /* istanbul ignore next */ []);
89
+ fluid = input(false, {
90
+ ...ngDevMode ? { debugName: "fluid" } : /* istanbul ignore next */ {},
91
+ transform: booleanAttribute
92
+ });
93
+ completed = output();
94
+ focused = output();
95
+ blurred = output();
96
+ touch = output();
97
+ separatorTemplate = contentChild(AerisInputOtpSeparatorTemplate, ...ngDevMode ? [{ debugName: "separatorTemplate" }] : /* istanbul ignore next */ []);
98
+ effectiveDisabled = computed(() => this.disabled() || this.formDisabled(), ...ngDevMode ? [{ debugName: "effectiveDisabled" }] : /* istanbul ignore next */ []);
99
+ effectiveInputMode = computed(() => this.mode() === "numeric" ? "numeric" : "text", ...ngDevMode ? [{ debugName: "effectiveInputMode" }] : /* istanbul ignore next */ []);
100
+ slots = computed(() => {
101
+ const value = this.normalizedValue();
102
+ return Array.from({ length: this.length() }, (_, index) => ({
103
+ index,
104
+ position: index + 1,
105
+ id: index === 0 && this.inputId() ? this.inputId() : `${this.generatedId}-${index + 1}`,
106
+ value: value[index] ?? "",
107
+ ariaLabel: this.slotAriaLabel().replace("{0}", String(index + 1)).replace("{1}", String(this.length()))
108
+ }));
109
+ }, ...ngDevMode ? [{ debugName: "slots" }] : /* istanbul ignore next */ []);
110
+ normalizedValue = computed(() => this.filterCharacters(this.value()).slice(0, this.length()), ...ngDevMode ? [{ debugName: "normalizedValue" }] : /* istanbul ignore next */ []);
111
+ constructor() {
112
+ afterNextRender(() => {
113
+ if (this.autoFocus() && !this.effectiveDisabled()) this.focus();
114
+ });
115
+ }
116
+ writeValue(value) {
117
+ const next = typeof value === "string" || typeof value === "number" ? String(value) : "";
118
+ this.value.set(this.filterCharacters(next).slice(0, this.length()));
119
+ }
120
+ registerOnChange(callback) {
121
+ this.onChange = callback;
122
+ }
123
+ registerOnTouched(callback) {
124
+ this.onTouched = callback;
125
+ }
126
+ setDisabledState(disabled) {
127
+ this.formDisabled.set(disabled);
128
+ }
129
+ focus(index = 0, options) {
130
+ const targetIndex = Math.min(Math.max(index, 0), this.length() - 1);
131
+ this.inputElements()[targetIndex]?.nativeElement.focus(options);
132
+ }
133
+ clear() {
134
+ if (this.effectiveDisabled() || this.readonly()) return;
135
+ this.commit("", new Event("clear"));
136
+ queueMicrotask(() => this.focus());
137
+ }
138
+ handleBeforeInput(event, index) {
139
+ if (event.inputType.startsWith("delete") || !event.data) return;
140
+ const accepted = this.filterCharacters(event.data);
141
+ if (!accepted) {
142
+ event.preventDefault();
143
+ return;
144
+ }
145
+ if (accepted.length > 1) {
146
+ event.preventDefault();
147
+ this.insertCharacters(accepted, index, event);
148
+ }
149
+ }
150
+ handleInput(event, index) {
151
+ const inputElement = event.target;
152
+ const accepted = this.filterCharacters(inputElement.value);
153
+ if (!accepted) {
154
+ inputElement.value = this.normalizedValue()[index] ?? "";
155
+ return;
156
+ }
157
+ this.insertCharacters(accepted, index, event);
158
+ }
159
+ handleKeydown(event, index) {
160
+ if (this.effectiveDisabled() || this.readonly()) return;
161
+ if (event.key === "ArrowLeft") {
162
+ event.preventDefault();
163
+ this.focus(index - 1);
164
+ return;
165
+ }
166
+ if (event.key === "ArrowRight") {
167
+ event.preventDefault();
168
+ this.focus(index + 1);
169
+ return;
170
+ }
171
+ if (event.key === "Home") {
172
+ event.preventDefault();
173
+ this.focus(0);
174
+ return;
175
+ }
176
+ if (event.key === "End") {
177
+ event.preventDefault();
178
+ this.focus(this.length() - 1);
179
+ return;
180
+ }
181
+ if (event.key === "Backspace") {
182
+ event.preventDefault();
183
+ const targetIndex = this.normalizedValue()[index] ? index : Math.max(0, index - 1);
184
+ this.removeAt(targetIndex, event);
185
+ queueMicrotask(() => this.focus(targetIndex));
186
+ return;
187
+ }
188
+ if (event.key === "Delete") {
189
+ event.preventDefault();
190
+ this.removeAt(index, event);
191
+ }
192
+ }
193
+ handlePaste(event, index) {
194
+ const pasted = this.filterCharacters(event.clipboardData?.getData("text") ?? "");
195
+ if (!pasted) return;
196
+ event.preventDefault();
197
+ this.insertCharacters(pasted, index, event);
198
+ }
199
+ handleFocus(event) {
200
+ if (this.selectOnFocus()) event.target.select();
201
+ this.focused.emit(event);
202
+ }
203
+ handleFocusOut(event) {
204
+ const nextTarget = event.relatedTarget;
205
+ if (nextTarget instanceof Node && this.host.nativeElement.contains(nextTarget)) return;
206
+ this.touch.emit();
207
+ this.onTouched();
208
+ }
209
+ insertCharacters(characters, index, event) {
210
+ const slots = Array.from({ length: this.length() }, (_, slotIndex) => this.normalizedValue()[slotIndex] ?? "");
211
+ let nextIndex = index;
212
+ for (const character of characters) {
213
+ if (nextIndex >= slots.length) break;
214
+ slots[nextIndex] = character;
215
+ nextIndex += 1;
216
+ }
217
+ const nextValue = slots.join("");
218
+ this.commit(nextValue, event);
219
+ queueMicrotask(() => this.focus(Math.min(nextIndex, this.length() - 1)));
220
+ }
221
+ removeAt(index, event) {
222
+ const slots = Array.from({ length: this.length() }, (_, slotIndex) => this.normalizedValue()[slotIndex] ?? "");
223
+ slots[index] = "";
224
+ this.commit(slots.join(""), event);
225
+ }
226
+ commit(value, event) {
227
+ const nextValue = this.filterCharacters(value).slice(0, this.length());
228
+ const wasComplete = this.normalizedValue().length === this.length();
229
+ if (this.value() !== nextValue) {
230
+ this.value.set(nextValue);
231
+ this.onChange(nextValue);
232
+ }
233
+ if (!wasComplete && nextValue.length === this.length()) this.completed.emit({
234
+ originalEvent: event,
235
+ value: nextValue
236
+ });
237
+ }
238
+ filterCharacters(value) {
239
+ const pattern = this.mode() === "numeric" ? /[0-9]/g : /[A-Za-z0-9]/g;
240
+ return value.match(pattern)?.join("") ?? "";
241
+ }
242
+ static ɵfac = i0.ɵɵngDeclareFactory({
243
+ minVersion: "12.0.0",
244
+ version: "22.2.2",
245
+ ngImport: i0,
246
+ type: AerisInputOtpComponent,
247
+ deps: [],
248
+ target: i0.ɵɵFactoryTarget.Component
249
+ });
250
+ static ɵcmp = i0.ɵɵngDeclareComponent({
251
+ minVersion: "17.0.0",
252
+ version: "22.2.2",
253
+ type: AerisInputOtpComponent,
254
+ isStandalone: true,
255
+ selector: "aeris-input-otp",
256
+ inputs: {
257
+ value: {
258
+ classPropertyName: "value",
259
+ publicName: "value",
260
+ isSignal: true,
261
+ isRequired: false,
262
+ transformFunction: null
263
+ },
264
+ length: {
265
+ classPropertyName: "length",
266
+ publicName: "length",
267
+ isSignal: true,
268
+ isRequired: false,
269
+ transformFunction: null
270
+ },
271
+ mode: {
272
+ classPropertyName: "mode",
273
+ publicName: "mode",
274
+ isSignal: true,
275
+ isRequired: false,
276
+ transformFunction: null
277
+ },
278
+ inputId: {
279
+ classPropertyName: "inputId",
280
+ publicName: "inputId",
281
+ isSignal: true,
282
+ isRequired: false,
283
+ transformFunction: null
284
+ },
285
+ name: {
286
+ classPropertyName: "name",
287
+ publicName: "name",
288
+ isSignal: true,
289
+ isRequired: false,
290
+ transformFunction: null
291
+ },
292
+ autocomplete: {
293
+ classPropertyName: "autocomplete",
294
+ publicName: "autocomplete",
295
+ isSignal: true,
296
+ isRequired: false,
297
+ transformFunction: null
298
+ },
299
+ ariaLabel: {
300
+ classPropertyName: "ariaLabel",
301
+ publicName: "ariaLabel",
302
+ isSignal: true,
303
+ isRequired: false,
304
+ transformFunction: null
305
+ },
306
+ ariaLabelledBy: {
307
+ classPropertyName: "ariaLabelledBy",
308
+ publicName: "ariaLabelledBy",
309
+ isSignal: true,
310
+ isRequired: false,
311
+ transformFunction: null
312
+ },
313
+ ariaDescribedBy: {
314
+ classPropertyName: "ariaDescribedBy",
315
+ publicName: "ariaDescribedBy",
316
+ isSignal: true,
317
+ isRequired: false,
318
+ transformFunction: null
319
+ },
320
+ slotAriaLabel: {
321
+ classPropertyName: "slotAriaLabel",
322
+ publicName: "slotAriaLabel",
323
+ isSignal: true,
324
+ isRequired: false,
325
+ transformFunction: null
326
+ },
327
+ size: {
328
+ classPropertyName: "size",
329
+ publicName: "size",
330
+ isSignal: true,
331
+ isRequired: false,
332
+ transformFunction: null
333
+ },
334
+ appearance: {
335
+ classPropertyName: "appearance",
336
+ publicName: "appearance",
337
+ isSignal: true,
338
+ isRequired: false,
339
+ transformFunction: null
340
+ },
341
+ mask: {
342
+ classPropertyName: "mask",
343
+ publicName: "mask",
344
+ isSignal: true,
345
+ isRequired: false,
346
+ transformFunction: null
347
+ },
348
+ autoFocus: {
349
+ classPropertyName: "autoFocus",
350
+ publicName: "autoFocus",
351
+ isSignal: true,
352
+ isRequired: false,
353
+ transformFunction: null
354
+ },
355
+ selectOnFocus: {
356
+ classPropertyName: "selectOnFocus",
357
+ publicName: "selectOnFocus",
358
+ isSignal: true,
359
+ isRequired: false,
360
+ transformFunction: null
361
+ },
362
+ disabled: {
363
+ classPropertyName: "disabled",
364
+ publicName: "disabled",
365
+ isSignal: true,
366
+ isRequired: false,
367
+ transformFunction: null
368
+ },
369
+ readonly: {
370
+ classPropertyName: "readonly",
371
+ publicName: "readonly",
372
+ isSignal: true,
373
+ isRequired: false,
374
+ transformFunction: null
375
+ },
376
+ required: {
377
+ classPropertyName: "required",
378
+ publicName: "required",
379
+ isSignal: true,
380
+ isRequired: false,
381
+ transformFunction: null
382
+ },
383
+ invalid: {
384
+ classPropertyName: "invalid",
385
+ publicName: "invalid",
386
+ isSignal: true,
387
+ isRequired: false,
388
+ transformFunction: null
389
+ },
390
+ touched: {
391
+ classPropertyName: "touched",
392
+ publicName: "touched",
393
+ isSignal: true,
394
+ isRequired: false,
395
+ transformFunction: null
396
+ },
397
+ fluid: {
398
+ classPropertyName: "fluid",
399
+ publicName: "fluid",
400
+ isSignal: true,
401
+ isRequired: false,
402
+ transformFunction: null
403
+ }
404
+ },
405
+ outputs: {
406
+ value: "valueChange",
407
+ completed: "completed",
408
+ focused: "focused",
409
+ blurred: "blurred",
410
+ touch: "touch"
411
+ },
412
+ host: { properties: { "attr.data-fluid": "fluid() || null" } },
413
+ providers: [{
414
+ provide: NG_VALUE_ACCESSOR,
415
+ useExisting: forwardRef(() => AerisInputOtpComponent),
416
+ multi: true
417
+ }],
418
+ queries: [{
419
+ propertyName: "separatorTemplate",
420
+ first: true,
421
+ predicate: AerisInputOtpSeparatorTemplate,
422
+ descendants: true,
423
+ isSignal: true
424
+ }],
425
+ viewQueries: [{
426
+ propertyName: "inputElements",
427
+ predicate: ["otpInput"],
428
+ descendants: true,
429
+ isSignal: true
430
+ }],
431
+ ngImport: i0,
432
+ template: `
232
433
  <span
233
434
  class="aeris-input-otp"
234
435
  role="group"
235
436
  [attr.data-size]="size()"
236
437
  [attr.data-appearance]="appearance()"
237
- [attr.data-invalid]="invalid() || null"
438
+ [attr.data-invalid]="displayInvalid() || null"
238
439
  [attr.data-disabled]="effectiveDisabled() || null"
239
440
  [attr.data-readonly]="readonly() || null"
240
441
  [attr.data-fluid]="fluid() || null"
241
442
  [attr.aria-label]="ariaLabel() || null"
242
- [attr.aria-labelledby]="ariaLabelledby() || null"
243
- [attr.aria-describedby]="ariaDescribedby() || null"
244
- [attr.aria-invalid]="invalid() || null"
443
+ [attr.aria-labelledby]="ariaLabelledBy() || null"
444
+ [attr.aria-describedby]="ariaDescribedBy() || null"
445
+ [attr.aria-invalid]="displayInvalid() || null"
245
446
  [attr.aria-required]="required() || null"
246
447
  (focusout)="handleFocusOut($event)"
247
448
  >
@@ -262,7 +463,7 @@ class AerisInputOtpComponent {
262
463
  [disabled]="effectiveDisabled()"
263
464
  [readOnly]="readonly()"
264
465
  [attr.aria-label]="slot.ariaLabel"
265
- [attr.aria-invalid]="invalid() || null"
466
+ [attr.aria-invalid]="displayInvalid() || null"
266
467
  (beforeinput)="handleBeforeInput($event, slot.index)"
267
468
  (input)="handleInput($event, slot.index)"
268
469
  (keydown)="handleKeydown($event, slot.index)"
@@ -281,24 +482,45 @@ class AerisInputOtpComponent {
281
482
  }
282
483
  }
283
484
  </span>
284
- `, isInline: true, styles: [":host{display:inline-block;max-width:100%;vertical-align:middle}:host([data-fluid]){width:100%}.aeris-input-otp{--_slot-size: var(--aeris-control-height, 2.625rem);--_font-size: 1rem;display:flex;align-items:center;gap:.5rem;max-width:100%}.aeris-input-otp[data-fluid]{width:100%}.aeris-input-otp__slot{width:var(--_slot-size);height:var(--_slot-size);min-width:0;padding:0;border:1px solid var(--aeris-border-strong, #c7c9c0);border-radius:var(--aeris-radius-sm, .4375rem);outline:0;background:var(--aeris-surface, #fff);color:var(--aeris-text, #222222);font:650 var(--_font-size)/1 inherit;text-align:center;caret-color:var(--aeris-primary, #879566);transition:border-color .12s ease,box-shadow .12s ease,background-color .12s ease}.aeris-input-otp[data-fluid] .aeris-input-otp__slot{flex:1 1 0;width:auto;max-width:var(--_slot-size)}.aeris-input-otp__slot:hover:not(:disabled,:read-only){border-color:var(--aeris-primary, #879566)}.aeris-input-otp__slot:focus-visible{border-color:var(--aeris-focus, #536437);box-shadow:0 0 0 3px color-mix(in srgb,var(--aeris-focus, #536437) 18%,transparent)}.aeris-input-otp[data-appearance=filled] .aeris-input-otp__slot{border-color:transparent;background:var(--aeris-surface-2, #f2f0ec)}.aeris-input-otp[data-appearance=filled] .aeris-input-otp__slot:focus-visible{border-color:var(--aeris-focus, #536437);background:var(--aeris-surface, #fff)}.aeris-input-otp[data-invalid] .aeris-input-otp__slot{border-color:var(--aeris-danger, #c81e2a)}.aeris-input-otp[data-invalid] .aeris-input-otp__slot:focus-visible{box-shadow:0 0 0 3px color-mix(in srgb,var(--aeris-danger, #c81e2a) 18%,transparent)}.aeris-input-otp[data-disabled],.aeris-input-otp[data-readonly]{opacity:var(--aeris-disabled-opacity, .54)}.aeris-input-otp[data-disabled] .aeris-input-otp__slot,.aeris-input-otp[data-readonly] .aeris-input-otp__slot{background:var(--aeris-surface-2, #f2f0ec)}.aeris-input-otp[data-size=xs]{--_slot-size: 1.875rem;--_font-size: .75rem;gap:.375rem}.aeris-input-otp[data-size=sm]{--_slot-size: 2.25rem;--_font-size: .875rem;gap:.4375rem}.aeris-input-otp[data-size=lg]{--_slot-size: 3rem;--_font-size: 1.125rem;gap:.625rem}.aeris-input-otp__separator{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;color:var(--aeris-text-2, #555555)}.aeris-input-otp__separator:empty{display:none}@media(max-width:30rem){.aeris-input-otp{gap:.375rem}}@media(prefers-reduced-motion:reduce){.aeris-input-otp__slot{transition:none}}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] });
285
- }
286
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: AerisInputOtpComponent, decorators: [{
287
- type: Component,
288
- args: [{ selector: 'aeris-input-otp', imports: [NgTemplateOutlet], template: `
485
+ `,
486
+ isInline: true,
487
+ styles: [":host{display:inline-block;max-width:100%;vertical-align:middle}:host([data-fluid]){width:100%}.aeris-input-otp{--_slot-size: var(--aeris-control-height, 2.625rem);--_font-size: var(--aeris-font-size-2xl, 1rem);display:flex;align-items:center;gap:.5rem;max-width:100%}.aeris-input-otp[data-fluid]{width:100%}.aeris-input-otp__slot{width:var(--_slot-size);height:var(--_slot-size);min-width:0;padding:0;border:1px solid var(--aeris-border, #efefef);border-radius:var(--aeris-radius-control, var(--aeris-radius-sm, .4375rem));outline:0;background:var(--aeris-surface, #fff);color:var(--aeris-text, #111111);font:650 var(--_font-size)/1 inherit;text-align:center;caret-color:var(--aeris-primary, #111111);transition:border-color var(--aeris-motion-fast, .1s) var(--aeris-ease-standard, ease),box-shadow var(--aeris-motion-fast, .1s) var(--aeris-ease-standard, ease),background-color var(--aeris-motion-fast, .1s) var(--aeris-ease-standard, ease)}.aeris-input-otp[data-fluid] .aeris-input-otp__slot{flex:1 1 0;width:auto;max-width:var(--_slot-size)}@media(hover:hover){.aeris-input-otp__slot:hover:not(:disabled,:read-only){border-color:var(--aeris-control-hover-border, var(--aeris-primary, #111111))}}.aeris-input-otp__slot:focus-visible{border-color:var(--aeris-control-focus-border, var(--aeris-focus, #111111));box-shadow:0 0 0 var(--aeris-focus-ring-width, 3px) var(--aeris-control-focus-ring-color, var(--aeris-focus-ring-color, transparent))}.aeris-input-otp[data-appearance=filled] .aeris-input-otp__slot{border-color:transparent;background:var(--aeris-surface-2, #f3f3f3)}.aeris-input-otp[data-appearance=filled] .aeris-input-otp__slot:focus-visible{border-color:var(--aeris-control-focus-border, var(--aeris-focus, #111111));background:var(--aeris-surface, #fff)}.aeris-input-otp[data-invalid] .aeris-input-otp__slot{border-color:var(--aeris-control-invalid-border, var(--aeris-danger, #c81e2a))}.aeris-input-otp[data-invalid] .aeris-input-otp__slot:focus-visible{box-shadow:0 0 0 var(--aeris-focus-ring-width, 3px) var(--aeris-control-invalid-focus-ring-color, transparent)}.aeris-input-otp[data-disabled],.aeris-input-otp[data-readonly]{opacity:var(--aeris-disabled-opacity, .54)}.aeris-input-otp[data-disabled] .aeris-input-otp__slot,.aeris-input-otp[data-readonly] .aeris-input-otp__slot{background:var(--aeris-surface-2, #f3f3f3)}.aeris-input-otp[data-size=xs]{--_slot-size: 1.875rem;--_font-size: var(--aeris-font-size-sm, .75rem);gap:.375rem}.aeris-input-otp[data-size=sm]{--_slot-size: 2.25rem;--_font-size: var(--aeris-font-size-lg, .875rem);gap:.4375rem}.aeris-input-otp[data-size=lg]{--_slot-size: 3rem;--_font-size: var(--aeris-font-size-3xl, 1.125rem);gap:.625rem}.aeris-input-otp__separator{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;color:var(--aeris-text-2, #454545)}.aeris-input-otp__separator:empty{display:none}@media(max-width:30rem){.aeris-input-otp{gap:.375rem}}@media(prefers-reduced-motion:reduce){.aeris-input-otp__slot{transition:none}}@media(pointer:coarse){input{font-size:var(--aeris-mobile-input-font-size, 1rem)}}\n"],
488
+ dependencies: [{
489
+ kind: "directive",
490
+ type: NgTemplateOutlet,
491
+ selector: "[ngTemplateOutlet]",
492
+ inputs: [
493
+ "ngTemplateOutletContext",
494
+ "ngTemplateOutlet",
495
+ "ngTemplateOutletInjector"
496
+ ]
497
+ }]
498
+ });
499
+ };
500
+ i0.ɵɵngDeclareClassMetadata({
501
+ minVersion: "12.0.0",
502
+ version: "22.2.2",
503
+ ngImport: i0,
504
+ type: AerisInputOtpComponent,
505
+ decorators: [{
506
+ type: Component,
507
+ args: [{
508
+ selector: "aeris-input-otp",
509
+ imports: [NgTemplateOutlet],
510
+ template: `
289
511
  <span
290
512
  class="aeris-input-otp"
291
513
  role="group"
292
514
  [attr.data-size]="size()"
293
515
  [attr.data-appearance]="appearance()"
294
- [attr.data-invalid]="invalid() || null"
516
+ [attr.data-invalid]="displayInvalid() || null"
295
517
  [attr.data-disabled]="effectiveDisabled() || null"
296
518
  [attr.data-readonly]="readonly() || null"
297
519
  [attr.data-fluid]="fluid() || null"
298
520
  [attr.aria-label]="ariaLabel() || null"
299
- [attr.aria-labelledby]="ariaLabelledby() || null"
300
- [attr.aria-describedby]="ariaDescribedby() || null"
301
- [attr.aria-invalid]="invalid() || null"
521
+ [attr.aria-labelledby]="ariaLabelledBy() || null"
522
+ [attr.aria-describedby]="ariaDescribedBy() || null"
523
+ [attr.aria-invalid]="displayInvalid() || null"
302
524
  [attr.aria-required]="required() || null"
303
525
  (focusout)="handleFocusOut($event)"
304
526
  >
@@ -319,7 +541,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
319
541
  [disabled]="effectiveDisabled()"
320
542
  [readOnly]="readonly()"
321
543
  [attr.aria-label]="slot.ariaLabel"
322
- [attr.aria-invalid]="invalid() || null"
544
+ [attr.aria-invalid]="displayInvalid() || null"
323
545
  (beforeinput)="handleBeforeInput($event, slot.index)"
324
546
  (input)="handleInput($event, slot.index)"
325
547
  (keydown)="handleKeydown($event, slot.index)"
@@ -338,24 +560,216 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
338
560
  }
339
561
  }
340
562
  </span>
341
- `, providers: [
342
- {
343
- provide: NG_VALUE_ACCESSOR,
344
- useExisting: forwardRef(() => AerisInputOtpComponent),
345
- multi: true,
346
- },
347
- ], host: {
348
- '[attr.data-fluid]': 'fluid() || null',
349
- }, styles: [":host{display:inline-block;max-width:100%;vertical-align:middle}:host([data-fluid]){width:100%}.aeris-input-otp{--_slot-size: var(--aeris-control-height, 2.625rem);--_font-size: 1rem;display:flex;align-items:center;gap:.5rem;max-width:100%}.aeris-input-otp[data-fluid]{width:100%}.aeris-input-otp__slot{width:var(--_slot-size);height:var(--_slot-size);min-width:0;padding:0;border:1px solid var(--aeris-border-strong, #c7c9c0);border-radius:var(--aeris-radius-sm, .4375rem);outline:0;background:var(--aeris-surface, #fff);color:var(--aeris-text, #222222);font:650 var(--_font-size)/1 inherit;text-align:center;caret-color:var(--aeris-primary, #879566);transition:border-color .12s ease,box-shadow .12s ease,background-color .12s ease}.aeris-input-otp[data-fluid] .aeris-input-otp__slot{flex:1 1 0;width:auto;max-width:var(--_slot-size)}.aeris-input-otp__slot:hover:not(:disabled,:read-only){border-color:var(--aeris-primary, #879566)}.aeris-input-otp__slot:focus-visible{border-color:var(--aeris-focus, #536437);box-shadow:0 0 0 3px color-mix(in srgb,var(--aeris-focus, #536437) 18%,transparent)}.aeris-input-otp[data-appearance=filled] .aeris-input-otp__slot{border-color:transparent;background:var(--aeris-surface-2, #f2f0ec)}.aeris-input-otp[data-appearance=filled] .aeris-input-otp__slot:focus-visible{border-color:var(--aeris-focus, #536437);background:var(--aeris-surface, #fff)}.aeris-input-otp[data-invalid] .aeris-input-otp__slot{border-color:var(--aeris-danger, #c81e2a)}.aeris-input-otp[data-invalid] .aeris-input-otp__slot:focus-visible{box-shadow:0 0 0 3px color-mix(in srgb,var(--aeris-danger, #c81e2a) 18%,transparent)}.aeris-input-otp[data-disabled],.aeris-input-otp[data-readonly]{opacity:var(--aeris-disabled-opacity, .54)}.aeris-input-otp[data-disabled] .aeris-input-otp__slot,.aeris-input-otp[data-readonly] .aeris-input-otp__slot{background:var(--aeris-surface-2, #f2f0ec)}.aeris-input-otp[data-size=xs]{--_slot-size: 1.875rem;--_font-size: .75rem;gap:.375rem}.aeris-input-otp[data-size=sm]{--_slot-size: 2.25rem;--_font-size: .875rem;gap:.4375rem}.aeris-input-otp[data-size=lg]{--_slot-size: 3rem;--_font-size: 1.125rem;gap:.625rem}.aeris-input-otp__separator{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;color:var(--aeris-text-2, #555555)}.aeris-input-otp__separator:empty{display:none}@media(max-width:30rem){.aeris-input-otp{gap:.375rem}}@media(prefers-reduced-motion:reduce){.aeris-input-otp__slot{transition:none}}\n"] }]
350
- }], ctorParameters: () => [], propDecorators: { inputElements: [{ type: i0.ViewChildren, args: ['otpInput', { isSignal: true }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], length: [{ type: i0.Input, args: [{ isSignal: true, alias: "length", required: false }] }], mode: [{ type: i0.Input, args: [{ isSignal: true, alias: "mode", required: false }] }], inputId: [{ type: i0.Input, args: [{ isSignal: true, alias: "inputId", required: false }] }], name: [{ type: i0.Input, args: [{ isSignal: true, alias: "name", required: false }] }], autocomplete: [{ type: i0.Input, args: [{ isSignal: true, alias: "autocomplete", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], ariaLabelledby: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabelledby", required: false }] }], ariaDescribedby: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaDescribedby", required: false }] }], slotAriaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "slotAriaLabel", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], appearance: [{ type: i0.Input, args: [{ isSignal: true, alias: "appearance", required: false }] }], mask: [{ type: i0.Input, args: [{ isSignal: true, alias: "mask", required: false }] }], autoFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoFocus", required: false }] }], selectOnFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "selectOnFocus", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], readonly: [{ type: i0.Input, args: [{ isSignal: true, alias: "readonly", required: false }] }], required: [{ type: i0.Input, args: [{ isSignal: true, alias: "required", required: false }] }], invalid: [{ type: i0.Input, args: [{ isSignal: true, alias: "invalid", required: false }] }], fluid: [{ type: i0.Input, args: [{ isSignal: true, alias: "fluid", required: false }] }], valueInput: [{ type: i0.Output, args: ["valueInput"] }], completed: [{ type: i0.Output, args: ["completed"] }], focused: [{ type: i0.Output, args: ["focused"] }], blurred: [{ type: i0.Output, args: ["blurred"] }], touch: [{ type: i0.Output, args: ["touch"] }], separatorTemplate: [{ type: i0.ContentChild, args: [i0.forwardRef(() => AerisInputOtpSeparatorTemplate), { isSignal: true }] }] } });
351
- const AerisInputOtp = [
352
- AerisInputOtpComponent,
353
- AerisInputOtpSeparatorTemplate,
354
- ];
355
-
356
- /**
357
- * Generated bundle index. Do not edit.
358
- */
359
-
563
+ `,
564
+ providers: [{
565
+ provide: NG_VALUE_ACCESSOR,
566
+ useExisting: forwardRef(() => AerisInputOtpComponent),
567
+ multi: true
568
+ }],
569
+ host: { "[attr.data-fluid]": "fluid() || null" },
570
+ styles: [":host{display:inline-block;max-width:100%;vertical-align:middle}:host([data-fluid]){width:100%}.aeris-input-otp{--_slot-size: var(--aeris-control-height, 2.625rem);--_font-size: var(--aeris-font-size-2xl, 1rem);display:flex;align-items:center;gap:.5rem;max-width:100%}.aeris-input-otp[data-fluid]{width:100%}.aeris-input-otp__slot{width:var(--_slot-size);height:var(--_slot-size);min-width:0;padding:0;border:1px solid var(--aeris-border, #efefef);border-radius:var(--aeris-radius-control, var(--aeris-radius-sm, .4375rem));outline:0;background:var(--aeris-surface, #fff);color:var(--aeris-text, #111111);font:650 var(--_font-size)/1 inherit;text-align:center;caret-color:var(--aeris-primary, #111111);transition:border-color var(--aeris-motion-fast, .1s) var(--aeris-ease-standard, ease),box-shadow var(--aeris-motion-fast, .1s) var(--aeris-ease-standard, ease),background-color var(--aeris-motion-fast, .1s) var(--aeris-ease-standard, ease)}.aeris-input-otp[data-fluid] .aeris-input-otp__slot{flex:1 1 0;width:auto;max-width:var(--_slot-size)}@media(hover:hover){.aeris-input-otp__slot:hover:not(:disabled,:read-only){border-color:var(--aeris-control-hover-border, var(--aeris-primary, #111111))}}.aeris-input-otp__slot:focus-visible{border-color:var(--aeris-control-focus-border, var(--aeris-focus, #111111));box-shadow:0 0 0 var(--aeris-focus-ring-width, 3px) var(--aeris-control-focus-ring-color, var(--aeris-focus-ring-color, transparent))}.aeris-input-otp[data-appearance=filled] .aeris-input-otp__slot{border-color:transparent;background:var(--aeris-surface-2, #f3f3f3)}.aeris-input-otp[data-appearance=filled] .aeris-input-otp__slot:focus-visible{border-color:var(--aeris-control-focus-border, var(--aeris-focus, #111111));background:var(--aeris-surface, #fff)}.aeris-input-otp[data-invalid] .aeris-input-otp__slot{border-color:var(--aeris-control-invalid-border, var(--aeris-danger, #c81e2a))}.aeris-input-otp[data-invalid] .aeris-input-otp__slot:focus-visible{box-shadow:0 0 0 var(--aeris-focus-ring-width, 3px) var(--aeris-control-invalid-focus-ring-color, transparent)}.aeris-input-otp[data-disabled],.aeris-input-otp[data-readonly]{opacity:var(--aeris-disabled-opacity, .54)}.aeris-input-otp[data-disabled] .aeris-input-otp__slot,.aeris-input-otp[data-readonly] .aeris-input-otp__slot{background:var(--aeris-surface-2, #f3f3f3)}.aeris-input-otp[data-size=xs]{--_slot-size: 1.875rem;--_font-size: var(--aeris-font-size-sm, .75rem);gap:.375rem}.aeris-input-otp[data-size=sm]{--_slot-size: 2.25rem;--_font-size: var(--aeris-font-size-lg, .875rem);gap:.4375rem}.aeris-input-otp[data-size=lg]{--_slot-size: 3rem;--_font-size: var(--aeris-font-size-3xl, 1.125rem);gap:.625rem}.aeris-input-otp__separator{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;color:var(--aeris-text-2, #454545)}.aeris-input-otp__separator:empty{display:none}@media(max-width:30rem){.aeris-input-otp{gap:.375rem}}@media(prefers-reduced-motion:reduce){.aeris-input-otp__slot{transition:none}}@media(pointer:coarse){input{font-size:var(--aeris-mobile-input-font-size, 1rem)}}\n"]
571
+ }]
572
+ }],
573
+ ctorParameters: () => [],
574
+ propDecorators: {
575
+ inputElements: [{
576
+ type: i0.ViewChildren,
577
+ args: ["otpInput", { isSignal: true }]
578
+ }],
579
+ value: [{
580
+ type: i0.Input,
581
+ args: [{
582
+ isSignal: true,
583
+ alias: "value",
584
+ required: false
585
+ }]
586
+ }, {
587
+ type: i0.Output,
588
+ args: ["valueChange"]
589
+ }],
590
+ length: [{
591
+ type: i0.Input,
592
+ args: [{
593
+ isSignal: true,
594
+ alias: "length",
595
+ required: false
596
+ }]
597
+ }],
598
+ mode: [{
599
+ type: i0.Input,
600
+ args: [{
601
+ isSignal: true,
602
+ alias: "mode",
603
+ required: false
604
+ }]
605
+ }],
606
+ inputId: [{
607
+ type: i0.Input,
608
+ args: [{
609
+ isSignal: true,
610
+ alias: "inputId",
611
+ required: false
612
+ }]
613
+ }],
614
+ name: [{
615
+ type: i0.Input,
616
+ args: [{
617
+ isSignal: true,
618
+ alias: "name",
619
+ required: false
620
+ }]
621
+ }],
622
+ autocomplete: [{
623
+ type: i0.Input,
624
+ args: [{
625
+ isSignal: true,
626
+ alias: "autocomplete",
627
+ required: false
628
+ }]
629
+ }],
630
+ ariaLabel: [{
631
+ type: i0.Input,
632
+ args: [{
633
+ isSignal: true,
634
+ alias: "ariaLabel",
635
+ required: false
636
+ }]
637
+ }],
638
+ ariaLabelledBy: [{
639
+ type: i0.Input,
640
+ args: [{
641
+ isSignal: true,
642
+ alias: "ariaLabelledBy",
643
+ required: false
644
+ }]
645
+ }],
646
+ ariaDescribedBy: [{
647
+ type: i0.Input,
648
+ args: [{
649
+ isSignal: true,
650
+ alias: "ariaDescribedBy",
651
+ required: false
652
+ }]
653
+ }],
654
+ slotAriaLabel: [{
655
+ type: i0.Input,
656
+ args: [{
657
+ isSignal: true,
658
+ alias: "slotAriaLabel",
659
+ required: false
660
+ }]
661
+ }],
662
+ size: [{
663
+ type: i0.Input,
664
+ args: [{
665
+ isSignal: true,
666
+ alias: "size",
667
+ required: false
668
+ }]
669
+ }],
670
+ appearance: [{
671
+ type: i0.Input,
672
+ args: [{
673
+ isSignal: true,
674
+ alias: "appearance",
675
+ required: false
676
+ }]
677
+ }],
678
+ mask: [{
679
+ type: i0.Input,
680
+ args: [{
681
+ isSignal: true,
682
+ alias: "mask",
683
+ required: false
684
+ }]
685
+ }],
686
+ autoFocus: [{
687
+ type: i0.Input,
688
+ args: [{
689
+ isSignal: true,
690
+ alias: "autoFocus",
691
+ required: false
692
+ }]
693
+ }],
694
+ selectOnFocus: [{
695
+ type: i0.Input,
696
+ args: [{
697
+ isSignal: true,
698
+ alias: "selectOnFocus",
699
+ required: false
700
+ }]
701
+ }],
702
+ disabled: [{
703
+ type: i0.Input,
704
+ args: [{
705
+ isSignal: true,
706
+ alias: "disabled",
707
+ required: false
708
+ }]
709
+ }],
710
+ readonly: [{
711
+ type: i0.Input,
712
+ args: [{
713
+ isSignal: true,
714
+ alias: "readonly",
715
+ required: false
716
+ }]
717
+ }],
718
+ required: [{
719
+ type: i0.Input,
720
+ args: [{
721
+ isSignal: true,
722
+ alias: "required",
723
+ required: false
724
+ }]
725
+ }],
726
+ invalid: [{
727
+ type: i0.Input,
728
+ args: [{
729
+ isSignal: true,
730
+ alias: "invalid",
731
+ required: false
732
+ }]
733
+ }],
734
+ touched: [{
735
+ type: i0.Input,
736
+ args: [{
737
+ isSignal: true,
738
+ alias: "touched",
739
+ required: false
740
+ }]
741
+ }],
742
+ fluid: [{
743
+ type: i0.Input,
744
+ args: [{
745
+ isSignal: true,
746
+ alias: "fluid",
747
+ required: false
748
+ }]
749
+ }],
750
+ completed: [{
751
+ type: i0.Output,
752
+ args: ["completed"]
753
+ }],
754
+ focused: [{
755
+ type: i0.Output,
756
+ args: ["focused"]
757
+ }],
758
+ blurred: [{
759
+ type: i0.Output,
760
+ args: ["blurred"]
761
+ }],
762
+ touch: [{
763
+ type: i0.Output,
764
+ args: ["touch"]
765
+ }],
766
+ separatorTemplate: [{
767
+ type: i0.ContentChild,
768
+ args: [i0.forwardRef(() => AerisInputOtpSeparatorTemplate), { isSignal: true }]
769
+ }]
770
+ }
771
+ });
772
+ const AerisInputOtp = [AerisInputOtpComponent, AerisInputOtpSeparatorTemplate];
360
773
  export { AerisInputOtp, AerisInputOtpComponent, AerisInputOtpSeparatorTemplate };
361
- //# sourceMappingURL=aeris-ui-core-input-otp.mjs.map
774
+
775
+ //# sourceMappingURL=aeris-ui-core-input-otp.mjs.map