@riverty/web-components 6.3.0 → 6.3.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 (397) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/dist/cjs/app-globals-V2Kpy_OQ.js +5 -0
  3. package/dist/cjs/focusable-Oll_rmtP.js +28 -0
  4. package/dist/cjs/formData-B2DZyLxP.js +44 -0
  5. package/dist/cjs/index-BnETQtSf.js +1834 -0
  6. package/dist/cjs/index.cjs.js +37 -0
  7. package/dist/cjs/loader.cjs.js +13 -0
  8. package/dist/cjs/r-accordion-panel.cjs.entry.js +24 -0
  9. package/dist/cjs/r-accordion-section.cjs.entry.js +125 -0
  10. package/dist/cjs/r-accordion-trigger.cjs.entry.js +93 -0
  11. package/dist/cjs/r-accordion.cjs.entry.js +20 -0
  12. package/dist/cjs/r-alert.cjs.entry.js +146 -0
  13. package/dist/cjs/r-badge.cjs.entry.js +41 -0
  14. package/dist/cjs/r-button.cjs.entry.js +149 -0
  15. package/dist/cjs/r-checkbox-group.cjs.entry.js +237 -0
  16. package/dist/cjs/r-checkbox.cjs.entry.js +274 -0
  17. package/dist/cjs/r-design-system-devtools.cjs.entry.js +31 -0
  18. package/dist/cjs/r-dialog.cjs.entry.js +107 -0
  19. package/dist/cjs/r-hint_2.cjs.entry.js +50 -0
  20. package/dist/cjs/r-icon-button_2.cjs.entry.js +492 -0
  21. package/dist/cjs/r-icon.cjs.entry.js +284 -0
  22. package/dist/cjs/r-illustration.cjs.entry.js +396 -0
  23. package/dist/cjs/r-input-code.cjs.entry.js +437 -0
  24. package/dist/cjs/r-input-date.cjs.entry.js +524 -0
  25. package/dist/cjs/r-input-password.cjs.entry.js +270 -0
  26. package/dist/cjs/r-input-phone-number.cjs.entry.js +2525 -0
  27. package/dist/cjs/r-input.cjs.entry.js +618 -0
  28. package/dist/cjs/r-list-item.cjs.entry.js +109 -0
  29. package/dist/cjs/r-pagination.cjs.entry.js +320 -0
  30. package/dist/cjs/r-panel.cjs.entry.js +184 -0
  31. package/dist/cjs/r-popover-action.cjs.entry.js +80 -0
  32. package/dist/cjs/r-popover-content.cjs.entry.js +62 -0
  33. package/dist/cjs/r-popover-headline.cjs.entry.js +28 -0
  34. package/dist/cjs/r-popover-trigger.cjs.entry.js +70 -0
  35. package/dist/cjs/r-popover.cjs.entry.js +347 -0
  36. package/dist/cjs/r-progress-bar.cjs.entry.js +25 -0
  37. package/dist/cjs/r-radio-button-description.cjs.entry.js +18 -0
  38. package/dist/cjs/r-radio-button-leading.cjs.entry.js +18 -0
  39. package/dist/cjs/r-radio-button-title.cjs.entry.js +18 -0
  40. package/dist/cjs/r-radio-button-trailing.cjs.entry.js +18 -0
  41. package/dist/cjs/r-radio-button.cjs.entry.js +139 -0
  42. package/dist/cjs/r-radio-group.cjs.entry.js +428 -0
  43. package/dist/cjs/r-select-option.cjs.entry.js +130 -0
  44. package/dist/cjs/r-select.cjs.entry.js +1107 -0
  45. package/dist/cjs/r-skip-link.cjs.entry.js +19 -0
  46. package/dist/cjs/r-stepper-item.cjs.entry.js +42 -0
  47. package/dist/cjs/r-stepper.cjs.entry.js +99 -0
  48. package/dist/cjs/r-tab-panel.cjs.entry.js +26 -0
  49. package/dist/cjs/r-tab.cjs.entry.js +62 -0
  50. package/dist/cjs/r-tabs-list.cjs.entry.js +175 -0
  51. package/dist/cjs/r-tabs.cjs.entry.js +277 -0
  52. package/dist/cjs/r-textarea.cjs.entry.js +270 -0
  53. package/dist/cjs/r-toast-group.cjs.entry.js +46 -0
  54. package/dist/cjs/r-toast.cjs.entry.js +314 -0
  55. package/dist/cjs/style-observer-D9zSP9wP.js +1118 -0
  56. package/dist/cjs/theming-NqxjhVJS.js +109 -0
  57. package/dist/cjs/web-components.cjs.js +25 -0
  58. package/dist/collection/collection-manifest.json +60 -0
  59. package/dist/collection/components/accordion/accordion.css +24 -0
  60. package/dist/collection/components/accordion/accordion.js +90 -0
  61. package/dist/collection/components/accordion/exports.js +1 -0
  62. package/dist/collection/components/accordion-panel/accordion-panel.css +50 -0
  63. package/dist/collection/components/accordion-panel/accordion-panel.js +86 -0
  64. package/dist/collection/components/accordion-section/accordion-section.css +27 -0
  65. package/dist/collection/components/accordion-section/accordion-section.js +235 -0
  66. package/dist/collection/components/accordion-trigger/accordion-trigger.css +93 -0
  67. package/dist/collection/components/accordion-trigger/accordion-trigger.js +220 -0
  68. package/dist/collection/components/alert/alert.css +120 -0
  69. package/dist/collection/components/alert/alert.js +526 -0
  70. package/dist/collection/components/alert/exports.js +2 -0
  71. package/dist/collection/components/badge/badge.css +62 -0
  72. package/dist/collection/components/badge/badge.js +124 -0
  73. package/dist/collection/components/badge/exports.js +1 -0
  74. package/dist/collection/components/button/button.css +180 -0
  75. package/dist/collection/components/button/button.js +510 -0
  76. package/dist/collection/components/button/exports.js +5 -0
  77. package/dist/collection/components/checkbox/checkbox.css +116 -0
  78. package/dist/collection/components/checkbox/checkbox.js +803 -0
  79. package/dist/collection/components/checkbox-group/checkbox-group.css +48 -0
  80. package/dist/collection/components/checkbox-group/checkbox-group.js +744 -0
  81. package/dist/collection/components/design-system-devtools/design-system-devtools.js +59 -0
  82. package/dist/collection/components/dialog/dialog.css +125 -0
  83. package/dist/collection/components/dialog/dialog.js +345 -0
  84. package/dist/collection/components/dialog/exports.js +9 -0
  85. package/dist/collection/components/hint/exports.js +1 -0
  86. package/dist/collection/components/hint/hint.css +63 -0
  87. package/dist/collection/components/hint/hint.js +114 -0
  88. package/dist/collection/components/icon/all-kit.js +2 -0
  89. package/dist/collection/components/icon/data.js +90 -0
  90. package/dist/collection/components/icon/exports.js +7 -0
  91. package/dist/collection/components/icon/icon.css +105 -0
  92. package/dist/collection/components/icon/icon.js +379 -0
  93. package/dist/collection/components/icon/riverty-kit.js +2 -0
  94. package/dist/collection/components/icon-button/icon-button.css +105 -0
  95. package/dist/collection/components/icon-button/icon-button.js +343 -0
  96. package/dist/collection/components/illustration/data.js +112 -0
  97. package/dist/collection/components/illustration/exports.js +3 -0
  98. package/dist/collection/components/illustration/illustration.css +52 -0
  99. package/dist/collection/components/illustration/illustration.js +540 -0
  100. package/dist/collection/components/illustration/illustrations-ui-kit.js +2 -0
  101. package/dist/collection/components/input/exports.js +62 -0
  102. package/dist/collection/components/input/input.css +186 -0
  103. package/dist/collection/components/input/input.js +1861 -0
  104. package/dist/collection/components/input-code/exports.js +2 -0
  105. package/dist/collection/components/input-code/input-code.css +127 -0
  106. package/dist/collection/components/input-code/input-code.js +1165 -0
  107. package/dist/collection/components/input-date/exports.js +1 -0
  108. package/dist/collection/components/input-date/input-date.css +148 -0
  109. package/dist/collection/components/input-date/input-date.js +1254 -0
  110. package/dist/collection/components/input-password/exports.js +1 -0
  111. package/dist/collection/components/input-password/input-password.css +25 -0
  112. package/dist/collection/components/input-password/input-password.js +1077 -0
  113. package/dist/collection/components/input-phone-number/input-phone-number.css +61 -0
  114. package/dist/collection/components/input-phone-number/input-phone-number.js +893 -0
  115. package/dist/collection/components/label/label.css +38 -0
  116. package/dist/collection/components/label/label.js +47 -0
  117. package/dist/collection/components/list-item/list-item/exports.js +2 -0
  118. package/dist/collection/components/list-item/list-item/list-item.css +199 -0
  119. package/dist/collection/components/list-item/list-item/list-item.js +467 -0
  120. package/dist/collection/components/pagination/exports.js +3 -0
  121. package/dist/collection/components/pagination/pagination.css +118 -0
  122. package/dist/collection/components/pagination/pagination.js +814 -0
  123. package/dist/collection/components/panel/exports.js +1 -0
  124. package/dist/collection/components/panel/panel.css +192 -0
  125. package/dist/collection/components/panel/panel.js +473 -0
  126. package/dist/collection/components/popover/exports.js +3 -0
  127. package/dist/collection/components/popover/popover.css +251 -0
  128. package/dist/collection/components/popover/popover.js +741 -0
  129. package/dist/collection/components/popover-action/popover-action.css +21 -0
  130. package/dist/collection/components/popover-action/popover-action.js +150 -0
  131. package/dist/collection/components/popover-content/popover-content.css +9 -0
  132. package/dist/collection/components/popover-content/popover-content.js +130 -0
  133. package/dist/collection/components/popover-headline/popover-headline.css +7 -0
  134. package/dist/collection/components/popover-headline/popover-headline.js +28 -0
  135. package/dist/collection/components/popover-trigger/exports.js +1 -0
  136. package/dist/collection/components/popover-trigger/popover-trigger.css +4 -0
  137. package/dist/collection/components/popover-trigger/popover-trigger.js +163 -0
  138. package/dist/collection/components/progress-bar/progress-bar.css +41 -0
  139. package/dist/collection/components/progress-bar/progress-bar.js +71 -0
  140. package/dist/collection/components/radio-button/radio-button.css +126 -0
  141. package/dist/collection/components/radio-button/radio-button.js +559 -0
  142. package/dist/collection/components/radio-button-description/radio-button-description.css +5 -0
  143. package/dist/collection/components/radio-button-description/radio-button-description.js +22 -0
  144. package/dist/collection/components/radio-button-leading/radio-button-leading.css +3 -0
  145. package/dist/collection/components/radio-button-leading/radio-button-leading.js +22 -0
  146. package/dist/collection/components/radio-button-title/radio-button-title.css +8 -0
  147. package/dist/collection/components/radio-button-title/radio-button-title.js +22 -0
  148. package/dist/collection/components/radio-button-trailing/radio-button-trailing.css +6 -0
  149. package/dist/collection/components/radio-button-trailing/radio-button-trailing.js +22 -0
  150. package/dist/collection/components/radio-group/exports.js +1 -0
  151. package/dist/collection/components/radio-group/radio-group.css +65 -0
  152. package/dist/collection/components/radio-group/radio-group.js +1023 -0
  153. package/dist/collection/components/select/exports.js +1 -0
  154. package/dist/collection/components/select/select.css +247 -0
  155. package/dist/collection/components/select/select.js +2038 -0
  156. package/dist/collection/components/select-option/select-option.css +93 -0
  157. package/dist/collection/components/select-option/select-option.js +459 -0
  158. package/dist/collection/components/skip-link/exports.js +1 -0
  159. package/dist/collection/components/skip-link/skip-link.css +37 -0
  160. package/dist/collection/components/skip-link/skip-link.js +52 -0
  161. package/dist/collection/components/stepper/stepper.css +25 -0
  162. package/dist/collection/components/stepper/stepper.js +216 -0
  163. package/dist/collection/components/stepper-item/stepper-item.css +62 -0
  164. package/dist/collection/components/stepper-item/stepper-item.js +171 -0
  165. package/dist/collection/components/tab/tab.css +81 -0
  166. package/dist/collection/components/tab/tab.js +169 -0
  167. package/dist/collection/components/tab-panel/tab-panel.css +19 -0
  168. package/dist/collection/components/tab-panel/tab-panel.js +72 -0
  169. package/dist/collection/components/tabs/tabs.css +4 -0
  170. package/dist/collection/components/tabs/tabs.js +345 -0
  171. package/dist/collection/components/tabs-list/exports.js +2 -0
  172. package/dist/collection/components/tabs-list/tabs-list.css +58 -0
  173. package/dist/collection/components/tabs-list/tabs-list.js +294 -0
  174. package/dist/collection/components/textarea/exports.js +8 -0
  175. package/dist/collection/components/textarea/textarea.css +148 -0
  176. package/dist/collection/components/textarea/textarea.js +1055 -0
  177. package/dist/collection/components/toast/exports.js +3 -0
  178. package/dist/collection/components/toast/toast.css +179 -0
  179. package/dist/collection/components/toast/toast.js +820 -0
  180. package/dist/collection/components/toast-group/exports.js +1 -0
  181. package/dist/collection/components/toast-group/toast-group.css +37 -0
  182. package/dist/collection/components/toast-group/toast-group.js +49 -0
  183. package/dist/collection/components/tooltip/exports.js +3 -0
  184. package/dist/collection/components/tooltip/tooltip.css +77 -0
  185. package/dist/collection/components/tooltip/tooltip.js +525 -0
  186. package/dist/collection/index.js +2 -0
  187. package/dist/collection/utils/focusable.js +24 -0
  188. package/dist/collection/utils/formData.js +40 -0
  189. package/dist/collection/utils/theming.js +103 -0
  190. package/dist/collection/utils/version-checker.js +33 -0
  191. package/dist/esm/app-globals-DQuL1Twl.js +3 -0
  192. package/dist/esm/focusable-ky1yonnS.js +26 -0
  193. package/dist/esm/formData-DvLT8-y3.js +42 -0
  194. package/dist/esm/index-CTxpqopm.js +1806 -0
  195. package/dist/esm/index.js +35 -0
  196. package/dist/esm/loader.js +11 -0
  197. package/dist/esm/r-accordion-panel.entry.js +22 -0
  198. package/dist/esm/r-accordion-section.entry.js +123 -0
  199. package/dist/esm/r-accordion-trigger.entry.js +91 -0
  200. package/dist/esm/r-accordion.entry.js +18 -0
  201. package/dist/esm/r-alert.entry.js +144 -0
  202. package/dist/esm/r-badge.entry.js +39 -0
  203. package/dist/esm/r-button.entry.js +147 -0
  204. package/dist/esm/r-checkbox-group.entry.js +235 -0
  205. package/dist/esm/r-checkbox.entry.js +272 -0
  206. package/dist/esm/r-design-system-devtools.entry.js +29 -0
  207. package/dist/esm/r-dialog.entry.js +105 -0
  208. package/dist/esm/r-hint_2.entry.js +47 -0
  209. package/dist/esm/r-icon-button_2.entry.js +489 -0
  210. package/dist/esm/r-icon.entry.js +282 -0
  211. package/dist/esm/r-illustration.entry.js +394 -0
  212. package/dist/esm/r-input-code.entry.js +435 -0
  213. package/dist/esm/r-input-date.entry.js +522 -0
  214. package/dist/esm/r-input-password.entry.js +268 -0
  215. package/dist/esm/r-input-phone-number.entry.js +2523 -0
  216. package/dist/esm/r-input.entry.js +616 -0
  217. package/dist/esm/r-list-item.entry.js +107 -0
  218. package/dist/esm/r-pagination.entry.js +318 -0
  219. package/dist/esm/r-panel.entry.js +182 -0
  220. package/dist/esm/r-popover-action.entry.js +78 -0
  221. package/dist/esm/r-popover-content.entry.js +60 -0
  222. package/dist/esm/r-popover-headline.entry.js +26 -0
  223. package/dist/esm/r-popover-trigger.entry.js +68 -0
  224. package/dist/esm/r-popover.entry.js +345 -0
  225. package/dist/esm/r-progress-bar.entry.js +23 -0
  226. package/dist/esm/r-radio-button-description.entry.js +16 -0
  227. package/dist/esm/r-radio-button-leading.entry.js +16 -0
  228. package/dist/esm/r-radio-button-title.entry.js +16 -0
  229. package/dist/esm/r-radio-button-trailing.entry.js +16 -0
  230. package/dist/esm/r-radio-button.entry.js +137 -0
  231. package/dist/esm/r-radio-group.entry.js +426 -0
  232. package/dist/esm/r-select-option.entry.js +128 -0
  233. package/dist/esm/r-select.entry.js +1105 -0
  234. package/dist/esm/r-skip-link.entry.js +17 -0
  235. package/dist/esm/r-stepper-item.entry.js +40 -0
  236. package/dist/esm/r-stepper.entry.js +97 -0
  237. package/dist/esm/r-tab-panel.entry.js +24 -0
  238. package/dist/esm/r-tab.entry.js +60 -0
  239. package/dist/esm/r-tabs-list.entry.js +173 -0
  240. package/dist/esm/r-tabs.entry.js +275 -0
  241. package/dist/esm/r-textarea.entry.js +268 -0
  242. package/dist/esm/r-toast-group.entry.js +44 -0
  243. package/dist/esm/r-toast.entry.js +312 -0
  244. package/dist/esm/style-observer-4Uv3PpKT.js +1116 -0
  245. package/dist/esm/theming-DD2IrjpG.js +106 -0
  246. package/dist/esm/web-components.js +21 -0
  247. package/dist/index.cjs.js +1 -0
  248. package/dist/index.js +1 -0
  249. package/dist/types/components/accordion/accordion.d.ts +27 -0
  250. package/dist/types/components/accordion/exports.d.ts +2 -0
  251. package/dist/types/components/accordion-panel/accordion-panel.d.ts +10 -0
  252. package/dist/types/components/accordion-section/accordion-section.d.ts +36 -0
  253. package/dist/types/components/accordion-trigger/accordion-trigger.d.ts +33 -0
  254. package/dist/types/components/alert/alert.d.ts +67 -0
  255. package/dist/types/components/alert/exports.d.ts +4 -0
  256. package/dist/types/components/badge/badge.d.ts +26 -0
  257. package/dist/types/components/badge/exports.d.ts +2 -0
  258. package/dist/types/components/button/button.d.ts +89 -0
  259. package/dist/types/components/button/exports.d.ts +10 -0
  260. package/dist/types/components/checkbox/checkbox.d.ts +138 -0
  261. package/dist/types/components/checkbox-group/checkbox-group.d.ts +124 -0
  262. package/dist/types/components/design-system-devtools/design-system-devtools.d.ts +15 -0
  263. package/dist/types/components/dialog/dialog.d.ts +69 -0
  264. package/dist/types/components/dialog/exports.d.ts +10 -0
  265. package/dist/types/components/hint/exports.d.ts +2 -0
  266. package/dist/types/components/hint/hint.d.ts +20 -0
  267. package/dist/types/components/icon/all-kit.d.ts +2890 -0
  268. package/dist/types/components/icon/data.d.ts +145 -0
  269. package/dist/types/components/icon/exports.d.ts +152 -0
  270. package/dist/types/components/icon/icon.d.ts +37 -0
  271. package/dist/types/components/icon/riverty-kit.d.ts +139 -0
  272. package/dist/types/components/icon-button/icon-button.d.ts +69 -0
  273. package/dist/types/components/illustration/data.d.ts +52 -0
  274. package/dist/types/components/illustration/exports.d.ts +23 -0
  275. package/dist/types/components/illustration/illustration.d.ts +51 -0
  276. package/dist/types/components/illustration/illustrations-ui-kit.d.ts +21 -0
  277. package/dist/types/components/input/exports.d.ts +55 -0
  278. package/dist/types/components/input/input.d.ts +365 -0
  279. package/dist/types/components/input-code/exports.d.ts +4 -0
  280. package/dist/types/components/input-code/input-code.d.ts +177 -0
  281. package/dist/types/components/input-date/exports.d.ts +5 -0
  282. package/dist/types/components/input-date/input-date.d.ts +174 -0
  283. package/dist/types/components/input-password/exports.d.ts +1 -0
  284. package/dist/types/components/input-password/input-password.d.ts +186 -0
  285. package/dist/types/components/input-phone-number/input-phone-number.d.ts +130 -0
  286. package/dist/types/components/label/label.d.ts +9 -0
  287. package/dist/types/components/list-item/list-item/exports.d.ts +4 -0
  288. package/dist/types/components/list-item/list-item/list-item.d.ts +61 -0
  289. package/dist/types/components/pagination/exports.d.ts +6 -0
  290. package/dist/types/components/pagination/pagination.d.ts +140 -0
  291. package/dist/types/components/panel/exports.d.ts +2 -0
  292. package/dist/types/components/panel/panel.d.ts +56 -0
  293. package/dist/types/components/popover/exports.d.ts +6 -0
  294. package/dist/types/components/popover/popover.d.ts +131 -0
  295. package/dist/types/components/popover-action/popover-action.d.ts +24 -0
  296. package/dist/types/components/popover-content/popover-content.d.ts +22 -0
  297. package/dist/types/components/popover-headline/popover-headline.d.ts +6 -0
  298. package/dist/types/components/popover-trigger/exports.d.ts +2 -0
  299. package/dist/types/components/popover-trigger/popover-trigger.d.ts +31 -0
  300. package/dist/types/components/progress-bar/progress-bar.d.ts +10 -0
  301. package/dist/types/components/radio-button/radio-button.d.ts +92 -0
  302. package/dist/types/components/radio-button-description/radio-button-description.d.ts +8 -0
  303. package/dist/types/components/radio-button-leading/radio-button-leading.d.ts +8 -0
  304. package/dist/types/components/radio-button-title/radio-button-title.d.ts +8 -0
  305. package/dist/types/components/radio-button-trailing/radio-button-trailing.d.ts +8 -0
  306. package/dist/types/components/radio-group/exports.d.ts +2 -0
  307. package/dist/types/components/radio-group/radio-group.d.ts +179 -0
  308. package/dist/types/components/select/exports.d.ts +2 -0
  309. package/dist/types/components/select/select.d.ts +319 -0
  310. package/dist/types/components/select-option/select-option.d.ts +113 -0
  311. package/dist/types/components/skip-link/exports.d.ts +2 -0
  312. package/dist/types/components/skip-link/skip-link.d.ts +6 -0
  313. package/dist/types/components/stepper/stepper.d.ts +22 -0
  314. package/dist/types/components/stepper-item/stepper-item.d.ts +23 -0
  315. package/dist/types/components/tab/tab.d.ts +23 -0
  316. package/dist/types/components/tab-panel/tab-panel.d.ts +7 -0
  317. package/dist/types/components/tabs/tabs.d.ts +49 -0
  318. package/dist/types/components/tabs-list/exports.d.ts +4 -0
  319. package/dist/types/components/tabs-list/tabs-list.d.ts +41 -0
  320. package/dist/types/components/textarea/exports.d.ts +2 -0
  321. package/dist/types/components/textarea/textarea.d.ts +158 -0
  322. package/dist/types/components/toast/exports.d.ts +6 -0
  323. package/dist/types/components/toast/toast.d.ts +146 -0
  324. package/dist/types/components/toast-group/exports.d.ts +2 -0
  325. package/dist/types/components/toast-group/toast-group.d.ts +9 -0
  326. package/dist/types/components/tooltip/exports.d.ts +6 -0
  327. package/dist/types/components/tooltip/tooltip.d.ts +132 -0
  328. package/dist/types/components.d.ts +6347 -0
  329. package/dist/types/index.d.ts +1 -0
  330. package/dist/types/stencil-public-runtime.d.ts +1732 -0
  331. package/dist/types/types/jsx-shim.d.ts +13 -0
  332. package/dist/types/types/style-observer.d.ts +20 -0
  333. package/dist/types/utils/focusable.d.ts +1 -0
  334. package/dist/types/utils/formData.d.ts +1 -0
  335. package/dist/types/utils/theming.d.ts +15 -0
  336. package/dist/types/utils/version-checker.d.ts +1 -0
  337. package/dist/web-components/index.esm.js +1 -0
  338. package/dist/web-components/p-01aefcf0.entry.js +1 -0
  339. package/dist/web-components/p-05cb55db.entry.js +1 -0
  340. package/dist/web-components/p-0a34d33b.entry.js +1 -0
  341. package/dist/web-components/p-11b22309.entry.js +1 -0
  342. package/dist/web-components/p-2d878934.entry.js +1 -0
  343. package/dist/web-components/p-325dbedf.entry.js +1 -0
  344. package/dist/web-components/p-34b9457b.entry.js +1 -0
  345. package/dist/web-components/p-36abd05a.entry.js +1 -0
  346. package/dist/web-components/p-386d1ef9.entry.js +1 -0
  347. package/dist/web-components/p-3d67b77b.entry.js +1 -0
  348. package/dist/web-components/p-4Uv3PpKT.js +1 -0
  349. package/dist/web-components/p-4b12fbc0.entry.js +1 -0
  350. package/dist/web-components/p-52f7b505.entry.js +1 -0
  351. package/dist/web-components/p-55600d47.entry.js +1 -0
  352. package/dist/web-components/p-57ebc474.entry.js +1 -0
  353. package/dist/web-components/p-57edf7f4.entry.js +1 -0
  354. package/dist/web-components/p-69a24fe2.entry.js +1 -0
  355. package/dist/web-components/p-6d92648c.entry.js +1 -0
  356. package/dist/web-components/p-75052597.entry.js +1 -0
  357. package/dist/web-components/p-7b2c5b63.entry.js +1 -0
  358. package/dist/web-components/p-7bf463ff.entry.js +1 -0
  359. package/dist/web-components/p-838e43d4.entry.js +1 -0
  360. package/dist/web-components/p-8c16d038.entry.js +1 -0
  361. package/dist/web-components/p-8f8313de.entry.js +1 -0
  362. package/dist/web-components/p-9026d5a2.entry.js +1 -0
  363. package/dist/web-components/p-95396b5c.entry.js +1 -0
  364. package/dist/web-components/p-9c31c7c4.entry.js +1 -0
  365. package/dist/web-components/p-9c415b9c.entry.js +1 -0
  366. package/dist/web-components/p-9f583ed1.entry.js +1 -0
  367. package/dist/web-components/p-B9rsR6cQ.js +1 -0
  368. package/dist/web-components/p-CTxpqopm.js +2 -0
  369. package/dist/web-components/p-DQuL1Twl.js +1 -0
  370. package/dist/web-components/p-DvLT8-y3.js +1 -0
  371. package/dist/web-components/p-b303b2cc.entry.js +1 -0
  372. package/dist/web-components/p-b8df041d.entry.js +1 -0
  373. package/dist/web-components/p-bc30844f.entry.js +1 -0
  374. package/dist/web-components/p-c4a77a65.entry.js +1 -0
  375. package/dist/web-components/p-c549addf.entry.js +1 -0
  376. package/dist/web-components/p-c65df19f.entry.js +1 -0
  377. package/dist/web-components/p-c80a5541.entry.js +1 -0
  378. package/dist/web-components/p-c96ee61a.entry.js +1 -0
  379. package/dist/web-components/p-cf3f044d.entry.js +1 -0
  380. package/dist/web-components/p-d1412932.entry.js +1 -0
  381. package/dist/web-components/p-d9778cfa.entry.js +1 -0
  382. package/dist/web-components/p-dbe4ccb8.entry.js +1 -0
  383. package/dist/web-components/p-ded50850.entry.js +1 -0
  384. package/dist/web-components/p-e5be895b.entry.js +1 -0
  385. package/dist/web-components/p-e6b34c1e.entry.js +1 -0
  386. package/dist/web-components/p-ec3c4800.entry.js +1 -0
  387. package/dist/web-components/p-f670fd87.entry.js +1 -0
  388. package/dist/web-components/p-f867e4c3.entry.js +1 -0
  389. package/dist/web-components/p-ff6b1b8f.entry.js +1 -0
  390. package/dist/web-components/p-ky1yonnS.js +1 -0
  391. package/dist/web-components/web-components.esm.js +1 -0
  392. package/loader/cdn.js +1 -0
  393. package/loader/index.cjs.js +1 -0
  394. package/loader/index.d.ts +24 -0
  395. package/loader/index.es2017.js +1 -0
  396. package/loader/index.js +2 -0
  397. package/package.json +1 -1
@@ -0,0 +1,1165 @@
1
+ import { h, Host } from "@stencil/core";
2
+ import { appendControlToFormData } from "../../utils/formData";
3
+ export class InputCode {
4
+ constructor() {
5
+ /** Specifies a name for an input for submission within formData object. */
6
+ this.name = 'input-code';
7
+ /** Number of digits (typically 4–6).
8
+ * @default: 4
9
+ */
10
+ this.length = 4;
11
+ /** Label for accessibility.
12
+ * @default: 'Verification code'
13
+ */
14
+ this.label = 'Verification code';
15
+ /** Defines initial value */
16
+ this.value = '';
17
+ /** Specifies the input mode for the virtual keyboard on mobile devices. Default is 'numeric' for OTP codes.
18
+ * @default: 'numeric'
19
+ */
20
+ this.inputmode = 'numeric';
21
+ /** Specifies the enter key hint for the virtual keyboard. Default is 'done' for OTP completion.
22
+ * @default: 'done'
23
+ */
24
+ this.enterkeyhint = 'done';
25
+ /** Specifies the autocomplete behavior. Default is 'one-time-code' for SMS OTP autofill.
26
+ * @default: 'one-time-code'
27
+ */
28
+ this.autocomplete = 'one-time-code';
29
+ /** Holds the current values of each input box */
30
+ this.values = [];
31
+ /** Tracks whether the component was previously in a complete state */
32
+ this.wasComplete = false;
33
+ /** Tracks the last completed value to detect changes */
34
+ this.lastCompletedValue = '';
35
+ /** Validity state passed from validateFormElement function after validation */
36
+ this.validityState = '';
37
+ /** Validity message passed from validateFormElement function after validation */
38
+ this.validityMessage = '';
39
+ this.inputs = [];
40
+ /**
41
+ * Checks if all segments are filled and emits rComplete event when:
42
+ * 1. Transitioning from incomplete to complete
43
+ * 2. Complete and value has changed from previous completed value
44
+ */
45
+ this.checkAndEmitCompletion = () => {
46
+ const isFullLength = this.value.length === this.length;
47
+ const isNoEmptySegments = this.values.every(val => val !== '');
48
+ const isComplete = isFullLength && isNoEmptySegments;
49
+ // Emit when transitioning to complete OR when complete with a different value
50
+ if (isComplete && (!this.wasComplete || this.value !== this.lastCompletedValue)) {
51
+ this.wasComplete = true;
52
+ this.lastCompletedValue = this.value;
53
+ this.rComplete.emit({ value: this.value, isComplete: true });
54
+ }
55
+ else if (!isComplete && this.wasComplete) {
56
+ // Reset the flag when becoming incomplete
57
+ this.wasComplete = false;
58
+ }
59
+ };
60
+ this.handleInput = (index, event) => {
61
+ var _a;
62
+ if (this.readonly)
63
+ return;
64
+ const input = event.target;
65
+ const value = input.value.slice(-1);
66
+ this.values[index] = value;
67
+ this.values = [...this.values];
68
+ if (value && index < this.length - 1) {
69
+ (_a = this.inputs[index + 1]) === null || _a === void 0 ? void 0 : _a.focus();
70
+ }
71
+ this.rChange.emit({ value: this.values.join('') });
72
+ };
73
+ this.handleKeyDown = (index, event) => {
74
+ var _a, _b, _c;
75
+ if (this.readonly)
76
+ return;
77
+ const key = event.key;
78
+ if (key === 'Backspace') {
79
+ if (!this.values[index] && index > 0) {
80
+ this.values[index - 1] = '';
81
+ this.values = [...this.values];
82
+ (_a = this.inputs[index - 1]) === null || _a === void 0 ? void 0 : _a.focus();
83
+ }
84
+ }
85
+ if (key === 'ArrowLeft') {
86
+ if (index > 0) {
87
+ (_b = this.inputs[index - 1]) === null || _b === void 0 ? void 0 : _b.focus();
88
+ if (this.values[index - 1]) {
89
+ setTimeout(() => {
90
+ var _a;
91
+ (_a = this.inputs[index - 1]) === null || _a === void 0 ? void 0 : _a.setSelectionRange(0, 1);
92
+ }, 0);
93
+ }
94
+ }
95
+ }
96
+ if (key === 'ArrowRight') {
97
+ if (index < this.length - 1) {
98
+ (_c = this.inputs[index + 1]) === null || _c === void 0 ? void 0 : _c.focus();
99
+ if (this.values[index + 1]) {
100
+ setTimeout(() => {
101
+ var _a;
102
+ (_a = this.inputs[index + 1]) === null || _a === void 0 ? void 0 : _a.setSelectionRange(0, 1);
103
+ }, 0);
104
+ }
105
+ }
106
+ }
107
+ };
108
+ this.createInputHandler = (index) => {
109
+ return (e) => this.handleInput(index, e);
110
+ };
111
+ this.createKeyDownHandler = (index) => {
112
+ return (e) => this.handleKeyDown(index, e);
113
+ };
114
+ this.handlePaste = async (event) => {
115
+ var _a;
116
+ if (this.readonly)
117
+ return;
118
+ event.preventDefault();
119
+ const pasted = event.clipboardData.getData('text').slice(0, this.length);
120
+ this.values = pasted.split('').concat(new Array(this.length).fill('')).slice(0, this.length);
121
+ this.values = [...this.values];
122
+ this.rChange.emit({ value: this.values.join('') });
123
+ const nextEmpty = this.values.findIndex(v => !v);
124
+ const nextIndex = nextEmpty === -1 ? this.length - 1 : nextEmpty;
125
+ (_a = this.inputs[nextIndex]) === null || _a === void 0 ? void 0 : _a.focus();
126
+ };
127
+ this.onHostClick = () => {
128
+ const input = this.firstEmptyInput || this.inputs[this.inputs.length - 1];
129
+ input === null || input === void 0 ? void 0 : input.focus();
130
+ if (this.firstEmptyInput === null) {
131
+ setTimeout(() => {
132
+ input === null || input === void 0 ? void 0 : input.setSelectionRange(0, 1);
133
+ }, 0);
134
+ }
135
+ };
136
+ this.uniqueId = `r-input-code-${Date.now().toString(32)}${Math.random().toString(32)}`.replace(/\./g, '');
137
+ this.nativeElement = null;
138
+ this.getValidityStateData = (element) => {
139
+ let validityState = '';
140
+ let validityMessage = '';
141
+ if (!element) {
142
+ validityState = 'valid';
143
+ return { validityState, validityMessage };
144
+ }
145
+ if (this.required && element.value.length === 0) {
146
+ validityState = 'valueMissing';
147
+ validityMessage = this.valueMissingMessage;
148
+ return { validityState, validityMessage };
149
+ }
150
+ if (element.value.length > 0 && element.value.length < this.length) {
151
+ validityState = 'tooShort';
152
+ validityMessage = this.tooShortMessage || `All ${this.length} characters must be filled.`;
153
+ return { validityState, validityMessage };
154
+ }
155
+ validityState = 'valid';
156
+ return { validityState, validityMessage };
157
+ };
158
+ this.validateFormElement = (element) => {
159
+ if (element === null)
160
+ return;
161
+ if (this.isNoValidate)
162
+ return;
163
+ const { validityState, validityMessage } = this.getValidityStateData(element);
164
+ this.validityState = validityState;
165
+ this.validityMessage = validityMessage;
166
+ const isValid = this.validityState === 'valid';
167
+ this.valid = isValid;
168
+ this.invalid = !isValid;
169
+ this.rValidate.emit({
170
+ state: this.validityState,
171
+ message: this.validityMessage
172
+ });
173
+ };
174
+ this.onResetForm = async () => {
175
+ if (this.readonly)
176
+ return;
177
+ await this.reset();
178
+ this.validityState = null;
179
+ this.validityMessage = null;
180
+ this.invalid = null;
181
+ this.valid = null;
182
+ const { host } = this;
183
+ this.rReset.emit({ element: host, value: this.values.join('') });
184
+ };
185
+ this.onSubmitForm = (event) => {
186
+ if (this.isNoValidate)
187
+ return;
188
+ if (this.disabled)
189
+ return;
190
+ this.validateFormElement(this.nativeElement);
191
+ if (this.invalid) {
192
+ event.preventDefault();
193
+ event.stopPropagation();
194
+ }
195
+ };
196
+ this.contributeToFormData = (event) => {
197
+ appendControlToFormData(this.nativeElement || this.host, event.formData);
198
+ };
199
+ }
200
+ /**
201
+ * Validates segment index and throws descriptive errors if invalid.
202
+ * @param index - The index to validate
203
+ * @throws Error if index is not an integer or out of bounds
204
+ */
205
+ validateSegmentIndex(index) {
206
+ if (typeof index !== 'number' || !Number.isInteger(index)) {
207
+ throw new Error('Index must be an integer');
208
+ }
209
+ if (index < 0 || index >= this.length) {
210
+ throw new Error(`Index out of bounds: must be between 0 and ${this.length - 1}`);
211
+ }
212
+ }
213
+ /**
214
+ * Gets the current complete code value by joining all individual digit values.
215
+ * @returns Promise that resolves to the complete code string
216
+ */
217
+ async getValue() {
218
+ return this.values.join('');
219
+ }
220
+ /**
221
+ * Resets the component by clearing all input values and focusing the first input.
222
+ * @returns Promise that resolves when reset is complete
223
+ */
224
+ async reset() {
225
+ var _a;
226
+ if (this.readonly)
227
+ return;
228
+ this.values = new Array(this.length).fill('');
229
+ (_a = this.inputs[0]) === null || _a === void 0 ? void 0 : _a.focus();
230
+ }
231
+ /**
232
+ * Sets provided value.
233
+ * */
234
+ async setValue(value) {
235
+ if (!value) {
236
+ this.values = new Array(this.length).fill('');
237
+ return;
238
+ }
239
+ const valueArray = Array.from(value).slice(0, this.length).map(char => String(char));
240
+ // Pad with empty strings if value is shorter than length
241
+ while (valueArray.length < this.length) {
242
+ valueArray.push('');
243
+ }
244
+ this.values = valueArray;
245
+ this.rChange.emit({ value: this.values.join('') });
246
+ }
247
+ /** Validates an element, displays provided message in case value is invalid. */
248
+ async setCustomValidity(message) {
249
+ this.customErrorMessage = message;
250
+ this.validateFormElement(this.nativeElement);
251
+ }
252
+ /**
253
+ * Validates the input code without triggering UI and returns a boolean indicating its validity.
254
+ * @returns A boolean indicating whether the input code is valid.
255
+ */
256
+ async checkValidity() {
257
+ const { validityState } = this.getValidityStateData(this.nativeElement);
258
+ return validityState === 'valid';
259
+ }
260
+ /**
261
+ * Focuses a specific segment (input) by index.
262
+ * @param index - The zero-based index of the segment to focus (0 to length-1)
263
+ * @returns Promise that resolves when focus is set, or rejects if index is invalid
264
+ */
265
+ async focusSegment(index) {
266
+ this.validateSegmentIndex(index);
267
+ const input = this.inputs[index];
268
+ if (input) {
269
+ input.focus();
270
+ // Select the content if it exists
271
+ if (this.values[index]) {
272
+ setTimeout(() => {
273
+ // Check if setSelectionRange exists (not available in some test environments)
274
+ if (typeof input.setSelectionRange === 'function') {
275
+ input.setSelectionRange(0, 1);
276
+ }
277
+ }, 0);
278
+ }
279
+ }
280
+ }
281
+ /**
282
+ * Gets the value of a specific segment by index.
283
+ * @param index - The zero-based index of the segment (0 to length-1)
284
+ * @returns Promise that resolves to the segment value (single character string or empty string)
285
+ */
286
+ async getSegmentValue(index) {
287
+ this.validateSegmentIndex(index);
288
+ return this.values[index] || '';
289
+ }
290
+ /**
291
+ * Sets the value of a specific segment by index.
292
+ * @param index - The zero-based index of the segment (0 to length-1)
293
+ * @param value - The value to set (will be truncated to first character if longer)
294
+ */
295
+ async setSegmentValue(index, value) {
296
+ this.validateSegmentIndex(index);
297
+ // Take only the first character, or empty string if value is empty
298
+ const newValue = value ? value.charAt(0) : '';
299
+ this.values[index] = newValue;
300
+ this.values = [...this.values];
301
+ // Update the input element's value to reflect the change
302
+ const input = this.inputs[index];
303
+ if (input) {
304
+ input.value = newValue;
305
+ }
306
+ }
307
+ handleValuesChange() {
308
+ this.value = this.values.join('');
309
+ this.checkAndEmitCompletion();
310
+ }
311
+ handleLengthChange(newLength) {
312
+ // Adjust values array when length changes
313
+ if (this.values.length !== newLength) {
314
+ const newValues = new Array(newLength).fill('');
315
+ // Copy existing values up to the new length
316
+ for (let i = 0; i < Math.min(this.values.length, newLength); i++) {
317
+ newValues[i] = this.values[i];
318
+ }
319
+ this.values = newValues;
320
+ this.inputs = [];
321
+ }
322
+ }
323
+ get firstEmptyInput() {
324
+ return this.inputs.find(input => !input.value) || null;
325
+ }
326
+ get message() {
327
+ if (this.invalid && this.error) {
328
+ return this.error;
329
+ }
330
+ const isValid = this.valid || this.validityState === 'valid';
331
+ if (isValid) {
332
+ return null;
333
+ }
334
+ return (this.validityState && this.validityState !== 'valid' ?
335
+ (this.customErrorMessage || this.validityMessage || `All ${this.length} characters must be filled.`)
336
+ : null);
337
+ }
338
+ get ariaDescribedBy() {
339
+ const messageId = this.message ? `${this.uniqueId}-message` : null;
340
+ return this.hint ? `${this.uniqueId}-hint ${messageId}` : messageId;
341
+ }
342
+ /** Identify wrapping form element */
343
+ get parentFormEl() {
344
+ return this.host.closest('form') || document.querySelector(`#${this.form}`) || null;
345
+ }
346
+ /**
347
+ * Determine whether this element should be ignored
348
+ * during Constraint Validation API validation.
349
+ * */
350
+ get isNoValidate() {
351
+ var _a, _b;
352
+ return (((_a = this.parentFormEl) === null || _a === void 0 ? void 0 : _a.hasAttribute('novalidate')) ||
353
+ this.novalidate ||
354
+ this.disabled ||
355
+ ((_b = this.error) === null || _b === void 0 ? void 0 : _b.length) > 0 ||
356
+ false);
357
+ }
358
+ connectFormEventListeners() {
359
+ var _a, _b, _c;
360
+ (_a = this.parentFormEl) === null || _a === void 0 ? void 0 : _a.addEventListener('formdata', this.contributeToFormData);
361
+ (_b = this.parentFormEl) === null || _b === void 0 ? void 0 : _b.addEventListener('submit', this.onSubmitForm, { capture: true });
362
+ (_c = this.parentFormEl) === null || _c === void 0 ? void 0 : _c.addEventListener('reset', this.onResetForm);
363
+ }
364
+ disconnectFormEventListeners() {
365
+ var _a, _b, _c;
366
+ (_a = this.parentFormEl) === null || _a === void 0 ? void 0 : _a.removeEventListener('formdata', this.contributeToFormData);
367
+ (_b = this.parentFormEl) === null || _b === void 0 ? void 0 : _b.removeEventListener('submit', this.onSubmitForm);
368
+ (_c = this.parentFormEl) === null || _c === void 0 ? void 0 : _c.removeEventListener('reset', this.onResetForm);
369
+ }
370
+ connectedCallback() {
371
+ this.connectFormEventListeners();
372
+ }
373
+ disconnectedCallback() {
374
+ this.disconnectFormEventListeners();
375
+ }
376
+ get hasMessage() {
377
+ return !!this.message;
378
+ }
379
+ get groupDescribedby() {
380
+ const { uniqueId, hint, hasMessage } = this;
381
+ if (hasMessage && hint)
382
+ return `${uniqueId}-message ${uniqueId}-hint`;
383
+ if (hasMessage)
384
+ return `${uniqueId}-message`;
385
+ if (hint)
386
+ return `${uniqueId}-hint`;
387
+ return null;
388
+ }
389
+ componentWillLoad() {
390
+ this.setValue(this.value);
391
+ }
392
+ render() {
393
+ const { form, name, novalidate, required, disabled, label, fieldIndicator, hint, uniqueId, valid, readonly } = this;
394
+ const inputAttrs = {
395
+ id: uniqueId,
396
+ readonly,
397
+ form,
398
+ name,
399
+ novalidate,
400
+ required,
401
+ disabled,
402
+ 'aria-describedby': this.ariaDescribedBy,
403
+ minlength: this.length,
404
+ maxlength: this.length
405
+ };
406
+ const labelAttr = label ? {
407
+ id: `${uniqueId}-label`,
408
+ fieldIndicator
409
+ } : {};
410
+ return (h(Host, { key: '800791debf1f1c64b666d8933dddfc9d308ef70e', value: this.value, onClick: this.onHostClick }, h("div", { key: 'b081be06e5e46fbce4764d59ee3de65091c39464', class: "r-input-code--label-container" }, h("label", { key: '4b98d9f9ea5e318943da440c1851887a9c540d50', htmlFor: uniqueId }, label ?
411
+ h("r-label", Object.assign({}, labelAttr), label)
412
+ :
413
+ h("slot", { name: "label" })), h("slot", { key: 'd7949be3b99b6774529948b22a4dc9544da2057d', name: "popover" })), hint &&
414
+ h("r-hint", { key: 'cd46c69b0f7ca4468219bc5d5698f95a8639864b', id: `${uniqueId}-hint`, role: "note" }, hint), h("div", { key: '3249a7836c7354a8ec8b9457d6dc0e81140710c9', class: "r-form-field" }, h("slot", { key: '9e1e2574802b9b650ba99bb971a5c0a165b0b197', name: "prefix" }), h("div", { key: '6ccba704319cc140d68a37b9bea922f62e4513b6', class: "r-input-code--container", role: "group", "aria-labelledby": `${uniqueId}-label`, "aria-describedby": this.groupDescribedby }, h("slot", { key: '06d57c63d11f5818f4cf2ccacca60aa64bd16a49', name: "leading" }), Array.from({ length: this.length }).map((_, i) => (h("input", { class: "r-input-code--input", key: i, id: `${uniqueId}-input-section-${i}`, "aria-label": `${this.ariaCharacterLabel || 'Character'}: ${i + 1}`, "aria-invalid": `${this.invalid || false}`, value: this.values[i], ref: el => this.inputs[i] = el, maxlength: 1, disabled: this.disabled, required: this.required, readonly: readonly, inputmode: this.inputmode, enterkeyhint: this.enterkeyhint, autocomplete: this.autocomplete, onInput: this.createInputHandler(i), onKeyDown: this.createKeyDownHandler(i), onPaste: this.handlePaste }))), h("input", Object.assign({ key: '56e629b9f9c4a7cbf83e0ba10d3338cccb27579f', type: "hidden" }, inputAttrs, { value: this.values.join(''), ref: el => this.nativeElement = el })), h("div", { key: '1388dab339130521becb1a0c2d0005ba8e1b8fde', class: "r-input-code--trailing" }, this.readonly &&
415
+ h("r-icon", { key: 'ea1cbf74635a3480ec03ea16f41d8133a156219d', class: "r-input-code--readonly-icon", name: "pen-disabled", size: "s" }), h("slot", { key: '90801524b96b72fdb21b49f6c15d00d4809faba6', name: "trailing" }, valid &&
416
+ h("r-icon", { key: '709294d96d12dfff3c902bbac8656d59d0e6064b', name: "circled-check", size: "s", color: "var(--r-status-success-regular)" })))), h("slot", { key: '67195193bd3d6a8c3e7aaa3ae0b5f35274971add', name: "suffix" })), h("slot", { key: '735676c16afee87dc1b121ec4eed689645e40f84', name: "message" }, this.hasMessage &&
417
+ h("r-hint", { key: 'f7733e7bdaa5037fa6244fb351551c9a6d7faf95', "aria-live": "polite", id: `${uniqueId}-message`, variant: "error" }, this.message))));
418
+ }
419
+ static get is() { return "r-input-code"; }
420
+ static get encapsulation() { return "shadow"; }
421
+ static get originalStyleUrls() {
422
+ return {
423
+ "$": ["input-code.css"]
424
+ };
425
+ }
426
+ static get styleUrls() {
427
+ return {
428
+ "$": ["input-code.css"]
429
+ };
430
+ }
431
+ static get properties() {
432
+ return {
433
+ "form": {
434
+ "type": "string",
435
+ "attribute": "form",
436
+ "mutable": false,
437
+ "complexType": {
438
+ "original": "string",
439
+ "resolved": "string",
440
+ "references": {}
441
+ },
442
+ "required": false,
443
+ "optional": true,
444
+ "docs": {
445
+ "tags": [],
446
+ "text": "Specifies the `id` of the `<form>` to which the element belongs."
447
+ },
448
+ "getter": false,
449
+ "setter": false,
450
+ "reflect": false
451
+ },
452
+ "name": {
453
+ "type": "string",
454
+ "attribute": "name",
455
+ "mutable": false,
456
+ "complexType": {
457
+ "original": "string",
458
+ "resolved": "string",
459
+ "references": {}
460
+ },
461
+ "required": false,
462
+ "optional": false,
463
+ "docs": {
464
+ "tags": [],
465
+ "text": "Specifies a name for an input for submission within formData object."
466
+ },
467
+ "getter": false,
468
+ "setter": false,
469
+ "reflect": false,
470
+ "defaultValue": "'input-code'"
471
+ },
472
+ "length": {
473
+ "type": "number",
474
+ "attribute": "length",
475
+ "mutable": false,
476
+ "complexType": {
477
+ "original": "number",
478
+ "resolved": "number",
479
+ "references": {}
480
+ },
481
+ "required": false,
482
+ "optional": false,
483
+ "docs": {
484
+ "tags": [{
485
+ "name": "default",
486
+ "text": ": 4"
487
+ }],
488
+ "text": "Number of digits (typically 4\u20136)."
489
+ },
490
+ "getter": false,
491
+ "setter": false,
492
+ "reflect": false,
493
+ "defaultValue": "4"
494
+ },
495
+ "disabled": {
496
+ "type": "boolean",
497
+ "attribute": "disabled",
498
+ "mutable": false,
499
+ "complexType": {
500
+ "original": "boolean",
501
+ "resolved": "boolean",
502
+ "references": {}
503
+ },
504
+ "required": false,
505
+ "optional": true,
506
+ "docs": {
507
+ "tags": [],
508
+ "text": "Whether the input is disabled"
509
+ },
510
+ "getter": false,
511
+ "setter": false,
512
+ "reflect": true
513
+ },
514
+ "novalidate": {
515
+ "type": "boolean",
516
+ "attribute": "novalidate",
517
+ "mutable": false,
518
+ "complexType": {
519
+ "original": "boolean",
520
+ "resolved": "boolean",
521
+ "references": {}
522
+ },
523
+ "required": false,
524
+ "optional": true,
525
+ "docs": {
526
+ "tags": [],
527
+ "text": "Specifies if element must be ignored during validation of the form elements."
528
+ },
529
+ "getter": false,
530
+ "setter": false,
531
+ "reflect": false
532
+ },
533
+ "required": {
534
+ "type": "boolean",
535
+ "attribute": "required",
536
+ "mutable": false,
537
+ "complexType": {
538
+ "original": "boolean",
539
+ "resolved": "boolean",
540
+ "references": {}
541
+ },
542
+ "required": false,
543
+ "optional": true,
544
+ "docs": {
545
+ "tags": [],
546
+ "text": "Whether the input is required"
547
+ },
548
+ "getter": false,
549
+ "setter": false,
550
+ "reflect": false
551
+ },
552
+ "readonly": {
553
+ "type": "boolean",
554
+ "attribute": "readonly",
555
+ "mutable": false,
556
+ "complexType": {
557
+ "original": "boolean",
558
+ "resolved": "boolean",
559
+ "references": {}
560
+ },
561
+ "required": false,
562
+ "optional": true,
563
+ "docs": {
564
+ "tags": [],
565
+ "text": "Read-only mode (mirrors native `readonly`): value cannot be changed by the user,\nbut the field can still receive focus, be selected, and be submitted with a form."
566
+ },
567
+ "getter": false,
568
+ "setter": false,
569
+ "reflect": true
570
+ },
571
+ "label": {
572
+ "type": "string",
573
+ "attribute": "label",
574
+ "mutable": false,
575
+ "complexType": {
576
+ "original": "string",
577
+ "resolved": "string",
578
+ "references": {}
579
+ },
580
+ "required": false,
581
+ "optional": false,
582
+ "docs": {
583
+ "tags": [{
584
+ "name": "default",
585
+ "text": ": 'Verification code'"
586
+ }],
587
+ "text": "Label for accessibility."
588
+ },
589
+ "getter": false,
590
+ "setter": false,
591
+ "reflect": false,
592
+ "defaultValue": "'Verification code'"
593
+ },
594
+ "fieldIndicator": {
595
+ "type": "string",
596
+ "attribute": "field-indicator",
597
+ "mutable": false,
598
+ "complexType": {
599
+ "original": "string",
600
+ "resolved": "string",
601
+ "references": {}
602
+ },
603
+ "required": false,
604
+ "optional": true,
605
+ "docs": {
606
+ "tags": [],
607
+ "text": "Text of an additional marker in the label"
608
+ },
609
+ "getter": false,
610
+ "setter": false,
611
+ "reflect": false
612
+ },
613
+ "hint": {
614
+ "type": "string",
615
+ "attribute": "hint",
616
+ "mutable": false,
617
+ "complexType": {
618
+ "original": "string",
619
+ "resolved": "string",
620
+ "references": {}
621
+ },
622
+ "required": false,
623
+ "optional": true,
624
+ "docs": {
625
+ "tags": [],
626
+ "text": "Description for accessibility"
627
+ },
628
+ "getter": false,
629
+ "setter": false,
630
+ "reflect": false
631
+ },
632
+ "invalid": {
633
+ "type": "boolean",
634
+ "attribute": "invalid",
635
+ "mutable": true,
636
+ "complexType": {
637
+ "original": "boolean",
638
+ "resolved": "boolean",
639
+ "references": {}
640
+ },
641
+ "required": false,
642
+ "optional": true,
643
+ "docs": {
644
+ "tags": [],
645
+ "text": "Validity indicator, serving to change UI of the component"
646
+ },
647
+ "getter": false,
648
+ "setter": false,
649
+ "reflect": true
650
+ },
651
+ "error": {
652
+ "type": "string",
653
+ "attribute": "error",
654
+ "mutable": false,
655
+ "complexType": {
656
+ "original": "string",
657
+ "resolved": "string",
658
+ "references": {}
659
+ },
660
+ "required": false,
661
+ "optional": true,
662
+ "docs": {
663
+ "tags": [],
664
+ "text": "The way to provide error message separately from Constraint Validation API."
665
+ },
666
+ "getter": false,
667
+ "setter": false,
668
+ "reflect": false
669
+ },
670
+ "valid": {
671
+ "type": "boolean",
672
+ "attribute": "valid",
673
+ "mutable": true,
674
+ "complexType": {
675
+ "original": "boolean",
676
+ "resolved": "boolean",
677
+ "references": {}
678
+ },
679
+ "required": false,
680
+ "optional": true,
681
+ "docs": {
682
+ "tags": [],
683
+ "text": "Visual indication of valid state"
684
+ },
685
+ "getter": false,
686
+ "setter": false,
687
+ "reflect": true
688
+ },
689
+ "tooShortMessage": {
690
+ "type": "string",
691
+ "attribute": "too-short-message",
692
+ "mutable": false,
693
+ "complexType": {
694
+ "original": "string",
695
+ "resolved": "string",
696
+ "references": {}
697
+ },
698
+ "required": false,
699
+ "optional": true,
700
+ "docs": {
701
+ "tags": [],
702
+ "text": "Set custom message for `tooShort` property of a ValidityState object (set by `minlength`) within Constrain Validation API"
703
+ },
704
+ "getter": false,
705
+ "setter": false,
706
+ "reflect": false
707
+ },
708
+ "customErrorMessage": {
709
+ "type": "string",
710
+ "attribute": "custom-error-message",
711
+ "mutable": false,
712
+ "complexType": {
713
+ "original": "string",
714
+ "resolved": "string",
715
+ "references": {}
716
+ },
717
+ "required": false,
718
+ "optional": true,
719
+ "docs": {
720
+ "tags": [],
721
+ "text": "Set custom message for `customError` property of a ValidityState object indicating whether the element's custom validity message has been set to a non-empty string by calling the element's setCustomValidity() method."
722
+ },
723
+ "getter": false,
724
+ "setter": false,
725
+ "reflect": false
726
+ },
727
+ "valueMissingMessage": {
728
+ "type": "string",
729
+ "attribute": "value-missing-message",
730
+ "mutable": false,
731
+ "complexType": {
732
+ "original": "string",
733
+ "resolved": "string",
734
+ "references": {}
735
+ },
736
+ "required": false,
737
+ "optional": true,
738
+ "docs": {
739
+ "tags": [],
740
+ "text": "Set custom message for `valueMissing` property of a ValidityState object (set by `required`) within Constrain Validation API"
741
+ },
742
+ "getter": false,
743
+ "setter": false,
744
+ "reflect": false
745
+ },
746
+ "fullWidth": {
747
+ "type": "boolean",
748
+ "attribute": "full-width",
749
+ "mutable": false,
750
+ "complexType": {
751
+ "original": "boolean",
752
+ "resolved": "boolean",
753
+ "references": {}
754
+ },
755
+ "required": false,
756
+ "optional": true,
757
+ "docs": {
758
+ "tags": [],
759
+ "text": "Defines if the component suppose to occupy 100% width"
760
+ },
761
+ "getter": false,
762
+ "setter": false,
763
+ "reflect": true
764
+ },
765
+ "ariaCharacterLabel": {
766
+ "type": "string",
767
+ "attribute": "aria-character-label",
768
+ "mutable": false,
769
+ "complexType": {
770
+ "original": "string",
771
+ "resolved": "string",
772
+ "references": {}
773
+ },
774
+ "required": false,
775
+ "optional": true,
776
+ "docs": {
777
+ "tags": [],
778
+ "text": "Defines label for each character's input.\nDefault \"Character: ${character number}\""
779
+ },
780
+ "getter": false,
781
+ "setter": false,
782
+ "reflect": false
783
+ },
784
+ "value": {
785
+ "type": "string",
786
+ "attribute": "value",
787
+ "mutable": true,
788
+ "complexType": {
789
+ "original": "string | null",
790
+ "resolved": "string",
791
+ "references": {}
792
+ },
793
+ "required": false,
794
+ "optional": true,
795
+ "docs": {
796
+ "tags": [],
797
+ "text": "Defines initial value"
798
+ },
799
+ "getter": false,
800
+ "setter": false,
801
+ "reflect": true,
802
+ "defaultValue": "''"
803
+ },
804
+ "inputmode": {
805
+ "type": "string",
806
+ "attribute": "inputmode",
807
+ "mutable": false,
808
+ "complexType": {
809
+ "original": "InputCodeInputMode",
810
+ "resolved": "\"decimal\" | \"email\" | \"none\" | \"numeric\" | \"search\" | \"tel\" | \"text\" | \"url\"",
811
+ "references": {
812
+ "InputCodeInputMode": {
813
+ "location": "import",
814
+ "path": "./exports",
815
+ "id": "src/components/input-code/exports.ts::InputCodeInputMode"
816
+ }
817
+ }
818
+ },
819
+ "required": false,
820
+ "optional": true,
821
+ "docs": {
822
+ "tags": [{
823
+ "name": "default",
824
+ "text": ": 'numeric'"
825
+ }],
826
+ "text": "Specifies the input mode for the virtual keyboard on mobile devices. Default is 'numeric' for OTP codes."
827
+ },
828
+ "getter": false,
829
+ "setter": false,
830
+ "reflect": false,
831
+ "defaultValue": "'numeric'"
832
+ },
833
+ "enterkeyhint": {
834
+ "type": "string",
835
+ "attribute": "enterkeyhint",
836
+ "mutable": false,
837
+ "complexType": {
838
+ "original": "InputCodeEnterKeyHint",
839
+ "resolved": "\"done\" | \"enter\" | \"go\" | \"next\" | \"previous\" | \"search\" | \"send\"",
840
+ "references": {
841
+ "InputCodeEnterKeyHint": {
842
+ "location": "import",
843
+ "path": "./exports",
844
+ "id": "src/components/input-code/exports.ts::InputCodeEnterKeyHint"
845
+ }
846
+ }
847
+ },
848
+ "required": false,
849
+ "optional": true,
850
+ "docs": {
851
+ "tags": [{
852
+ "name": "default",
853
+ "text": ": 'done'"
854
+ }],
855
+ "text": "Specifies the enter key hint for the virtual keyboard. Default is 'done' for OTP completion."
856
+ },
857
+ "getter": false,
858
+ "setter": false,
859
+ "reflect": false,
860
+ "defaultValue": "'done'"
861
+ },
862
+ "autocomplete": {
863
+ "type": "string",
864
+ "attribute": "autocomplete",
865
+ "mutable": false,
866
+ "complexType": {
867
+ "original": "string",
868
+ "resolved": "string",
869
+ "references": {}
870
+ },
871
+ "required": false,
872
+ "optional": true,
873
+ "docs": {
874
+ "tags": [{
875
+ "name": "default",
876
+ "text": ": 'one-time-code'"
877
+ }],
878
+ "text": "Specifies the autocomplete behavior. Default is 'one-time-code' for SMS OTP autofill."
879
+ },
880
+ "getter": false,
881
+ "setter": false,
882
+ "reflect": false,
883
+ "defaultValue": "'one-time-code'"
884
+ }
885
+ };
886
+ }
887
+ static get states() {
888
+ return {
889
+ "values": {},
890
+ "wasComplete": {},
891
+ "lastCompletedValue": {},
892
+ "validityState": {},
893
+ "validityMessage": {}
894
+ };
895
+ }
896
+ static get events() {
897
+ return [{
898
+ "method": "rChange",
899
+ "name": "rChange",
900
+ "bubbles": true,
901
+ "cancelable": true,
902
+ "composed": true,
903
+ "docs": {
904
+ "tags": [],
905
+ "text": "Emits the current code value as it changes"
906
+ },
907
+ "complexType": {
908
+ "original": "{ value: string }",
909
+ "resolved": "{ value: string; }",
910
+ "references": {}
911
+ }
912
+ }, {
913
+ "method": "rValidate",
914
+ "name": "rValidate",
915
+ "bubbles": true,
916
+ "cancelable": true,
917
+ "composed": true,
918
+ "docs": {
919
+ "tags": [],
920
+ "text": "Emits event after each validation"
921
+ },
922
+ "complexType": {
923
+ "original": "{\n state: string,\n message: string\n }",
924
+ "resolved": "{ state: string; message: string; }",
925
+ "references": {}
926
+ }
927
+ }, {
928
+ "method": "rReset",
929
+ "name": "rReset",
930
+ "bubbles": true,
931
+ "cancelable": true,
932
+ "composed": true,
933
+ "docs": {
934
+ "tags": [],
935
+ "text": "Emits 'rReset' event when form containing the component was reset"
936
+ },
937
+ "complexType": {
938
+ "original": "{\n element: HTMLRInputCodeElement,\n value: any\n }",
939
+ "resolved": "{ element: HTMLRInputCodeElement; value: any; }",
940
+ "references": {
941
+ "HTMLRInputCodeElement": {
942
+ "location": "global",
943
+ "id": "global::HTMLRInputCodeElement"
944
+ }
945
+ }
946
+ }
947
+ }, {
948
+ "method": "rComplete",
949
+ "name": "rComplete",
950
+ "bubbles": true,
951
+ "cancelable": true,
952
+ "composed": true,
953
+ "docs": {
954
+ "tags": [],
955
+ "text": "Emits when all segments are filled with values"
956
+ },
957
+ "complexType": {
958
+ "original": "{ value: string, isComplete: boolean }",
959
+ "resolved": "{ value: string; isComplete: boolean; }",
960
+ "references": {}
961
+ }
962
+ }];
963
+ }
964
+ static get methods() {
965
+ return {
966
+ "getValue": {
967
+ "complexType": {
968
+ "signature": "() => Promise<string>",
969
+ "parameters": [],
970
+ "references": {
971
+ "Promise": {
972
+ "location": "global",
973
+ "id": "global::Promise"
974
+ }
975
+ },
976
+ "return": "Promise<string>"
977
+ },
978
+ "docs": {
979
+ "text": "Gets the current complete code value by joining all individual digit values.",
980
+ "tags": [{
981
+ "name": "returns",
982
+ "text": "Promise that resolves to the complete code string"
983
+ }]
984
+ }
985
+ },
986
+ "reset": {
987
+ "complexType": {
988
+ "signature": "() => Promise<void>",
989
+ "parameters": [],
990
+ "references": {
991
+ "Promise": {
992
+ "location": "global",
993
+ "id": "global::Promise"
994
+ }
995
+ },
996
+ "return": "Promise<void>"
997
+ },
998
+ "docs": {
999
+ "text": "Resets the component by clearing all input values and focusing the first input.",
1000
+ "tags": [{
1001
+ "name": "returns",
1002
+ "text": "Promise that resolves when reset is complete"
1003
+ }]
1004
+ }
1005
+ },
1006
+ "setValue": {
1007
+ "complexType": {
1008
+ "signature": "(value: string | null) => Promise<void>",
1009
+ "parameters": [{
1010
+ "name": "value",
1011
+ "type": "string",
1012
+ "docs": ""
1013
+ }],
1014
+ "references": {
1015
+ "Promise": {
1016
+ "location": "global",
1017
+ "id": "global::Promise"
1018
+ }
1019
+ },
1020
+ "return": "Promise<void>"
1021
+ },
1022
+ "docs": {
1023
+ "text": "Sets provided value.",
1024
+ "tags": []
1025
+ }
1026
+ },
1027
+ "setCustomValidity": {
1028
+ "complexType": {
1029
+ "signature": "(message: string) => Promise<void>",
1030
+ "parameters": [{
1031
+ "name": "message",
1032
+ "type": "string",
1033
+ "docs": ""
1034
+ }],
1035
+ "references": {
1036
+ "Promise": {
1037
+ "location": "global",
1038
+ "id": "global::Promise"
1039
+ }
1040
+ },
1041
+ "return": "Promise<void>"
1042
+ },
1043
+ "docs": {
1044
+ "text": "Validates an element, displays provided message in case value is invalid.",
1045
+ "tags": []
1046
+ }
1047
+ },
1048
+ "checkValidity": {
1049
+ "complexType": {
1050
+ "signature": "() => Promise<boolean>",
1051
+ "parameters": [],
1052
+ "references": {
1053
+ "Promise": {
1054
+ "location": "global",
1055
+ "id": "global::Promise"
1056
+ }
1057
+ },
1058
+ "return": "Promise<boolean>"
1059
+ },
1060
+ "docs": {
1061
+ "text": "Validates the input code without triggering UI and returns a boolean indicating its validity.",
1062
+ "tags": [{
1063
+ "name": "returns",
1064
+ "text": "A boolean indicating whether the input code is valid."
1065
+ }]
1066
+ }
1067
+ },
1068
+ "focusSegment": {
1069
+ "complexType": {
1070
+ "signature": "(index: number) => Promise<void>",
1071
+ "parameters": [{
1072
+ "name": "index",
1073
+ "type": "number",
1074
+ "docs": "- The zero-based index of the segment to focus (0 to length-1)"
1075
+ }],
1076
+ "references": {
1077
+ "Promise": {
1078
+ "location": "global",
1079
+ "id": "global::Promise"
1080
+ }
1081
+ },
1082
+ "return": "Promise<void>"
1083
+ },
1084
+ "docs": {
1085
+ "text": "Focuses a specific segment (input) by index.",
1086
+ "tags": [{
1087
+ "name": "param",
1088
+ "text": "index - The zero-based index of the segment to focus (0 to length-1)"
1089
+ }, {
1090
+ "name": "returns",
1091
+ "text": "Promise that resolves when focus is set, or rejects if index is invalid"
1092
+ }]
1093
+ }
1094
+ },
1095
+ "getSegmentValue": {
1096
+ "complexType": {
1097
+ "signature": "(index: number) => Promise<string>",
1098
+ "parameters": [{
1099
+ "name": "index",
1100
+ "type": "number",
1101
+ "docs": "- The zero-based index of the segment (0 to length-1)"
1102
+ }],
1103
+ "references": {
1104
+ "Promise": {
1105
+ "location": "global",
1106
+ "id": "global::Promise"
1107
+ }
1108
+ },
1109
+ "return": "Promise<string>"
1110
+ },
1111
+ "docs": {
1112
+ "text": "Gets the value of a specific segment by index.",
1113
+ "tags": [{
1114
+ "name": "param",
1115
+ "text": "index - The zero-based index of the segment (0 to length-1)"
1116
+ }, {
1117
+ "name": "returns",
1118
+ "text": "Promise that resolves to the segment value (single character string or empty string)"
1119
+ }]
1120
+ }
1121
+ },
1122
+ "setSegmentValue": {
1123
+ "complexType": {
1124
+ "signature": "(index: number, value: string) => Promise<void>",
1125
+ "parameters": [{
1126
+ "name": "index",
1127
+ "type": "number",
1128
+ "docs": "- The zero-based index of the segment (0 to length-1)"
1129
+ }, {
1130
+ "name": "value",
1131
+ "type": "string",
1132
+ "docs": "- The value to set (will be truncated to first character if longer)"
1133
+ }],
1134
+ "references": {
1135
+ "Promise": {
1136
+ "location": "global",
1137
+ "id": "global::Promise"
1138
+ }
1139
+ },
1140
+ "return": "Promise<void>"
1141
+ },
1142
+ "docs": {
1143
+ "text": "Sets the value of a specific segment by index.",
1144
+ "tags": [{
1145
+ "name": "param",
1146
+ "text": "index - The zero-based index of the segment (0 to length-1)"
1147
+ }, {
1148
+ "name": "param",
1149
+ "text": "value - The value to set (will be truncated to first character if longer)"
1150
+ }]
1151
+ }
1152
+ }
1153
+ };
1154
+ }
1155
+ static get elementRef() { return "host"; }
1156
+ static get watchers() {
1157
+ return [{
1158
+ "propName": "values",
1159
+ "methodName": "handleValuesChange"
1160
+ }, {
1161
+ "propName": "length",
1162
+ "methodName": "handleLengthChange"
1163
+ }];
1164
+ }
1165
+ }