@riverty/web-components 6.2.0 → 6.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (397) hide show
  1. package/CHANGELOG.md +30 -0
  2. package/README.md +78 -0
  3. package/custom-elements.json +4 -0
  4. package/package.json +3 -2
  5. package/dist/cjs/app-globals-V2Kpy_OQ.js +0 -5
  6. package/dist/cjs/focusable-Oll_rmtP.js +0 -28
  7. package/dist/cjs/formData-B2DZyLxP.js +0 -44
  8. package/dist/cjs/index-BnETQtSf.js +0 -1834
  9. package/dist/cjs/index.cjs.js +0 -2
  10. package/dist/cjs/loader.cjs.js +0 -13
  11. package/dist/cjs/r-accordion-panel.cjs.entry.js +0 -24
  12. package/dist/cjs/r-accordion-section.cjs.entry.js +0 -125
  13. package/dist/cjs/r-accordion-trigger.cjs.entry.js +0 -93
  14. package/dist/cjs/r-accordion.cjs.entry.js +0 -20
  15. package/dist/cjs/r-alert.cjs.entry.js +0 -146
  16. package/dist/cjs/r-badge.cjs.entry.js +0 -40
  17. package/dist/cjs/r-button.cjs.entry.js +0 -149
  18. package/dist/cjs/r-checkbox-group.cjs.entry.js +0 -232
  19. package/dist/cjs/r-checkbox.cjs.entry.js +0 -269
  20. package/dist/cjs/r-design-system-devtools.cjs.entry.js +0 -31
  21. package/dist/cjs/r-dialog.cjs.entry.js +0 -107
  22. package/dist/cjs/r-hint_2.cjs.entry.js +0 -50
  23. package/dist/cjs/r-icon-button_2.cjs.entry.js +0 -467
  24. package/dist/cjs/r-icon.cjs.entry.js +0 -284
  25. package/dist/cjs/r-illustration.cjs.entry.js +0 -396
  26. package/dist/cjs/r-input-code.cjs.entry.js +0 -432
  27. package/dist/cjs/r-input-date.cjs.entry.js +0 -519
  28. package/dist/cjs/r-input-password.cjs.entry.js +0 -265
  29. package/dist/cjs/r-input-phone-number.cjs.entry.js +0 -2525
  30. package/dist/cjs/r-input.cjs.entry.js +0 -402
  31. package/dist/cjs/r-list-item.cjs.entry.js +0 -109
  32. package/dist/cjs/r-pagination.cjs.entry.js +0 -314
  33. package/dist/cjs/r-panel.cjs.entry.js +0 -184
  34. package/dist/cjs/r-popover-action.cjs.entry.js +0 -80
  35. package/dist/cjs/r-popover-content.cjs.entry.js +0 -62
  36. package/dist/cjs/r-popover-headline.cjs.entry.js +0 -28
  37. package/dist/cjs/r-popover-trigger.cjs.entry.js +0 -70
  38. package/dist/cjs/r-popover.cjs.entry.js +0 -347
  39. package/dist/cjs/r-progress-bar.cjs.entry.js +0 -25
  40. package/dist/cjs/r-radio-button-description.cjs.entry.js +0 -18
  41. package/dist/cjs/r-radio-button-leading.cjs.entry.js +0 -18
  42. package/dist/cjs/r-radio-button-title.cjs.entry.js +0 -18
  43. package/dist/cjs/r-radio-button-trailing.cjs.entry.js +0 -18
  44. package/dist/cjs/r-radio-button.cjs.entry.js +0 -139
  45. package/dist/cjs/r-radio-group.cjs.entry.js +0 -425
  46. package/dist/cjs/r-select-option.cjs.entry.js +0 -130
  47. package/dist/cjs/r-select.cjs.entry.js +0 -1101
  48. package/dist/cjs/r-skip-link.cjs.entry.js +0 -19
  49. package/dist/cjs/r-stepper-item.cjs.entry.js +0 -42
  50. package/dist/cjs/r-stepper.cjs.entry.js +0 -99
  51. package/dist/cjs/r-tab-panel.cjs.entry.js +0 -26
  52. package/dist/cjs/r-tab.cjs.entry.js +0 -62
  53. package/dist/cjs/r-tabs-list.cjs.entry.js +0 -175
  54. package/dist/cjs/r-tabs.cjs.entry.js +0 -277
  55. package/dist/cjs/r-textarea.cjs.entry.js +0 -270
  56. package/dist/cjs/r-toast-group.cjs.entry.js +0 -46
  57. package/dist/cjs/r-toast.cjs.entry.js +0 -306
  58. package/dist/cjs/style-observer-D9zSP9wP.js +0 -1118
  59. package/dist/cjs/theming-NqxjhVJS.js +0 -109
  60. package/dist/cjs/web-components.cjs.js +0 -25
  61. package/dist/collection/collection-manifest.json +0 -60
  62. package/dist/collection/components/accordion/accordion.css +0 -24
  63. package/dist/collection/components/accordion/accordion.js +0 -90
  64. package/dist/collection/components/accordion/exports.js +0 -1
  65. package/dist/collection/components/accordion-panel/accordion-panel.css +0 -50
  66. package/dist/collection/components/accordion-panel/accordion-panel.js +0 -86
  67. package/dist/collection/components/accordion-section/accordion-section.css +0 -27
  68. package/dist/collection/components/accordion-section/accordion-section.js +0 -235
  69. package/dist/collection/components/accordion-trigger/accordion-trigger.css +0 -93
  70. package/dist/collection/components/accordion-trigger/accordion-trigger.js +0 -220
  71. package/dist/collection/components/alert/alert.css +0 -119
  72. package/dist/collection/components/alert/alert.js +0 -526
  73. package/dist/collection/components/alert/exports.js +0 -2
  74. package/dist/collection/components/badge/badge.css +0 -52
  75. package/dist/collection/components/badge/badge.js +0 -120
  76. package/dist/collection/components/badge/exports.js +0 -1
  77. package/dist/collection/components/button/button.css +0 -180
  78. package/dist/collection/components/button/button.js +0 -510
  79. package/dist/collection/components/button/exports.js +0 -5
  80. package/dist/collection/components/checkbox/checkbox.css +0 -116
  81. package/dist/collection/components/checkbox/checkbox.js +0 -777
  82. package/dist/collection/components/checkbox-group/checkbox-group.css +0 -48
  83. package/dist/collection/components/checkbox-group/checkbox-group.js +0 -718
  84. package/dist/collection/components/design-system-devtools/design-system-devtools.js +0 -59
  85. package/dist/collection/components/dialog/dialog.css +0 -125
  86. package/dist/collection/components/dialog/dialog.js +0 -345
  87. package/dist/collection/components/dialog/exports.js +0 -9
  88. package/dist/collection/components/hint/exports.js +0 -1
  89. package/dist/collection/components/hint/hint.css +0 -63
  90. package/dist/collection/components/hint/hint.js +0 -114
  91. package/dist/collection/components/icon/all-kit.js +0 -2
  92. package/dist/collection/components/icon/data.js +0 -90
  93. package/dist/collection/components/icon/exports.js +0 -7
  94. package/dist/collection/components/icon/icon.css +0 -105
  95. package/dist/collection/components/icon/icon.js +0 -379
  96. package/dist/collection/components/icon/riverty-kit.js +0 -2
  97. package/dist/collection/components/icon-button/icon-button.css +0 -105
  98. package/dist/collection/components/icon-button/icon-button.js +0 -343
  99. package/dist/collection/components/illustration/data.js +0 -112
  100. package/dist/collection/components/illustration/exports.js +0 -3
  101. package/dist/collection/components/illustration/illustration.js +0 -540
  102. package/dist/collection/components/illustration/illustration.scss +0 -56
  103. package/dist/collection/components/illustration/illustrations-ui-kit.js +0 -2
  104. package/dist/collection/components/input/exports.js +0 -16
  105. package/dist/collection/components/input/input.css +0 -180
  106. package/dist/collection/components/input/input.js +0 -1572
  107. package/dist/collection/components/input-code/exports.js +0 -2
  108. package/dist/collection/components/input-code/input-code.css +0 -127
  109. package/dist/collection/components/input-code/input-code.js +0 -1139
  110. package/dist/collection/components/input-date/exports.js +0 -1
  111. package/dist/collection/components/input-date/input-date.css +0 -148
  112. package/dist/collection/components/input-date/input-date.js +0 -1228
  113. package/dist/collection/components/input-password/exports.js +0 -1
  114. package/dist/collection/components/input-password/input-password.css +0 -25
  115. package/dist/collection/components/input-password/input-password.js +0 -1051
  116. package/dist/collection/components/input-phone-number/input-phone-number.css +0 -61
  117. package/dist/collection/components/input-phone-number/input-phone-number.js +0 -874
  118. package/dist/collection/components/label/label.css +0 -38
  119. package/dist/collection/components/label/label.js +0 -47
  120. package/dist/collection/components/list-item/list-item/exports.js +0 -2
  121. package/dist/collection/components/list-item/list-item/list-item.css +0 -199
  122. package/dist/collection/components/list-item/list-item/list-item.js +0 -467
  123. package/dist/collection/components/pagination/exports.js +0 -3
  124. package/dist/collection/components/pagination/pagination.css +0 -118
  125. package/dist/collection/components/pagination/pagination.js +0 -799
  126. package/dist/collection/components/panel/exports.js +0 -1
  127. package/dist/collection/components/panel/panel.css +0 -192
  128. package/dist/collection/components/panel/panel.js +0 -473
  129. package/dist/collection/components/popover/exports.js +0 -3
  130. package/dist/collection/components/popover/popover.css +0 -251
  131. package/dist/collection/components/popover/popover.js +0 -741
  132. package/dist/collection/components/popover-action/popover-action.css +0 -21
  133. package/dist/collection/components/popover-action/popover-action.js +0 -150
  134. package/dist/collection/components/popover-content/popover-content.css +0 -9
  135. package/dist/collection/components/popover-content/popover-content.js +0 -130
  136. package/dist/collection/components/popover-headline/popover-headline.css +0 -7
  137. package/dist/collection/components/popover-headline/popover-headline.js +0 -28
  138. package/dist/collection/components/popover-trigger/exports.js +0 -1
  139. package/dist/collection/components/popover-trigger/popover-trigger.css +0 -4
  140. package/dist/collection/components/popover-trigger/popover-trigger.js +0 -163
  141. package/dist/collection/components/progress-bar/progress-bar.css +0 -41
  142. package/dist/collection/components/progress-bar/progress-bar.js +0 -71
  143. package/dist/collection/components/radio-button/radio-button.css +0 -126
  144. package/dist/collection/components/radio-button/radio-button.js +0 -559
  145. package/dist/collection/components/radio-button-description/radio-button-description.css +0 -5
  146. package/dist/collection/components/radio-button-description/radio-button-description.js +0 -22
  147. package/dist/collection/components/radio-button-leading/radio-button-leading.css +0 -3
  148. package/dist/collection/components/radio-button-leading/radio-button-leading.js +0 -22
  149. package/dist/collection/components/radio-button-title/radio-button-title.css +0 -8
  150. package/dist/collection/components/radio-button-title/radio-button-title.js +0 -22
  151. package/dist/collection/components/radio-button-trailing/radio-button-trailing.css +0 -6
  152. package/dist/collection/components/radio-button-trailing/radio-button-trailing.js +0 -22
  153. package/dist/collection/components/radio-group/exports.js +0 -1
  154. package/dist/collection/components/radio-group/radio-group.css +0 -65
  155. package/dist/collection/components/radio-group/radio-group.js +0 -1020
  156. package/dist/collection/components/select/exports.js +0 -1
  157. package/dist/collection/components/select/select.css +0 -247
  158. package/dist/collection/components/select/select.js +0 -2011
  159. package/dist/collection/components/select-option/select-option.css +0 -93
  160. package/dist/collection/components/select-option/select-option.js +0 -459
  161. package/dist/collection/components/skip-link/exports.js +0 -1
  162. package/dist/collection/components/skip-link/skip-link.css +0 -37
  163. package/dist/collection/components/skip-link/skip-link.js +0 -52
  164. package/dist/collection/components/stepper/stepper.css +0 -25
  165. package/dist/collection/components/stepper/stepper.js +0 -216
  166. package/dist/collection/components/stepper-item/stepper-item.css +0 -62
  167. package/dist/collection/components/stepper-item/stepper-item.js +0 -171
  168. package/dist/collection/components/tab/tab.css +0 -81
  169. package/dist/collection/components/tab/tab.js +0 -169
  170. package/dist/collection/components/tab-panel/tab-panel.css +0 -19
  171. package/dist/collection/components/tab-panel/tab-panel.js +0 -72
  172. package/dist/collection/components/tabs/tabs.css +0 -4
  173. package/dist/collection/components/tabs/tabs.js +0 -345
  174. package/dist/collection/components/tabs-list/exports.js +0 -2
  175. package/dist/collection/components/tabs-list/tabs-list.css +0 -58
  176. package/dist/collection/components/tabs-list/tabs-list.js +0 -294
  177. package/dist/collection/components/textarea/exports.js +0 -8
  178. package/dist/collection/components/textarea/textarea.css +0 -148
  179. package/dist/collection/components/textarea/textarea.js +0 -1055
  180. package/dist/collection/components/toast/exports.js +0 -3
  181. package/dist/collection/components/toast/toast.css +0 -179
  182. package/dist/collection/components/toast/toast.js +0 -812
  183. package/dist/collection/components/toast-group/exports.js +0 -1
  184. package/dist/collection/components/toast-group/toast-group.css +0 -37
  185. package/dist/collection/components/toast-group/toast-group.js +0 -49
  186. package/dist/collection/components/tooltip/exports.js +0 -3
  187. package/dist/collection/components/tooltip/tooltip.css +0 -106
  188. package/dist/collection/components/tooltip/tooltip.js +0 -500
  189. package/dist/collection/index.js +0 -1
  190. package/dist/collection/utils/focusable.js +0 -24
  191. package/dist/collection/utils/formData.js +0 -40
  192. package/dist/collection/utils/theming.js +0 -103
  193. package/dist/esm/app-globals-DQuL1Twl.js +0 -3
  194. package/dist/esm/focusable-ky1yonnS.js +0 -26
  195. package/dist/esm/formData-DvLT8-y3.js +0 -42
  196. package/dist/esm/index-CTxpqopm.js +0 -1806
  197. package/dist/esm/index.js +0 -1
  198. package/dist/esm/loader.js +0 -11
  199. package/dist/esm/r-accordion-panel.entry.js +0 -22
  200. package/dist/esm/r-accordion-section.entry.js +0 -123
  201. package/dist/esm/r-accordion-trigger.entry.js +0 -91
  202. package/dist/esm/r-accordion.entry.js +0 -18
  203. package/dist/esm/r-alert.entry.js +0 -144
  204. package/dist/esm/r-badge.entry.js +0 -38
  205. package/dist/esm/r-button.entry.js +0 -147
  206. package/dist/esm/r-checkbox-group.entry.js +0 -230
  207. package/dist/esm/r-checkbox.entry.js +0 -267
  208. package/dist/esm/r-design-system-devtools.entry.js +0 -29
  209. package/dist/esm/r-dialog.entry.js +0 -105
  210. package/dist/esm/r-hint_2.entry.js +0 -47
  211. package/dist/esm/r-icon-button_2.entry.js +0 -464
  212. package/dist/esm/r-icon.entry.js +0 -282
  213. package/dist/esm/r-illustration.entry.js +0 -394
  214. package/dist/esm/r-input-code.entry.js +0 -430
  215. package/dist/esm/r-input-date.entry.js +0 -517
  216. package/dist/esm/r-input-password.entry.js +0 -263
  217. package/dist/esm/r-input-phone-number.entry.js +0 -2523
  218. package/dist/esm/r-input.entry.js +0 -400
  219. package/dist/esm/r-list-item.entry.js +0 -107
  220. package/dist/esm/r-pagination.entry.js +0 -312
  221. package/dist/esm/r-panel.entry.js +0 -182
  222. package/dist/esm/r-popover-action.entry.js +0 -78
  223. package/dist/esm/r-popover-content.entry.js +0 -60
  224. package/dist/esm/r-popover-headline.entry.js +0 -26
  225. package/dist/esm/r-popover-trigger.entry.js +0 -68
  226. package/dist/esm/r-popover.entry.js +0 -345
  227. package/dist/esm/r-progress-bar.entry.js +0 -23
  228. package/dist/esm/r-radio-button-description.entry.js +0 -16
  229. package/dist/esm/r-radio-button-leading.entry.js +0 -16
  230. package/dist/esm/r-radio-button-title.entry.js +0 -16
  231. package/dist/esm/r-radio-button-trailing.entry.js +0 -16
  232. package/dist/esm/r-radio-button.entry.js +0 -137
  233. package/dist/esm/r-radio-group.entry.js +0 -423
  234. package/dist/esm/r-select-option.entry.js +0 -128
  235. package/dist/esm/r-select.entry.js +0 -1099
  236. package/dist/esm/r-skip-link.entry.js +0 -17
  237. package/dist/esm/r-stepper-item.entry.js +0 -40
  238. package/dist/esm/r-stepper.entry.js +0 -97
  239. package/dist/esm/r-tab-panel.entry.js +0 -24
  240. package/dist/esm/r-tab.entry.js +0 -60
  241. package/dist/esm/r-tabs-list.entry.js +0 -173
  242. package/dist/esm/r-tabs.entry.js +0 -275
  243. package/dist/esm/r-textarea.entry.js +0 -268
  244. package/dist/esm/r-toast-group.entry.js +0 -44
  245. package/dist/esm/r-toast.entry.js +0 -304
  246. package/dist/esm/style-observer-4Uv3PpKT.js +0 -1116
  247. package/dist/esm/theming-DD2IrjpG.js +0 -106
  248. package/dist/esm/web-components.js +0 -21
  249. package/dist/index.cjs.js +0 -1
  250. package/dist/index.js +0 -1
  251. package/dist/types/components/accordion/accordion.d.ts +0 -27
  252. package/dist/types/components/accordion/exports.d.ts +0 -2
  253. package/dist/types/components/accordion-panel/accordion-panel.d.ts +0 -10
  254. package/dist/types/components/accordion-section/accordion-section.d.ts +0 -36
  255. package/dist/types/components/accordion-trigger/accordion-trigger.d.ts +0 -33
  256. package/dist/types/components/alert/alert.d.ts +0 -67
  257. package/dist/types/components/alert/exports.d.ts +0 -4
  258. package/dist/types/components/badge/badge.d.ts +0 -23
  259. package/dist/types/components/badge/exports.d.ts +0 -2
  260. package/dist/types/components/button/button.d.ts +0 -89
  261. package/dist/types/components/button/exports.d.ts +0 -10
  262. package/dist/types/components/checkbox/checkbox.d.ts +0 -136
  263. package/dist/types/components/checkbox-group/checkbox-group.d.ts +0 -122
  264. package/dist/types/components/design-system-devtools/design-system-devtools.d.ts +0 -15
  265. package/dist/types/components/dialog/dialog.d.ts +0 -69
  266. package/dist/types/components/dialog/exports.d.ts +0 -10
  267. package/dist/types/components/hint/exports.d.ts +0 -2
  268. package/dist/types/components/hint/hint.d.ts +0 -20
  269. package/dist/types/components/icon/all-kit.d.ts +0 -2890
  270. package/dist/types/components/icon/data.d.ts +0 -145
  271. package/dist/types/components/icon/exports.d.ts +0 -152
  272. package/dist/types/components/icon/icon.d.ts +0 -37
  273. package/dist/types/components/icon/riverty-kit.d.ts +0 -139
  274. package/dist/types/components/icon-button/icon-button.d.ts +0 -69
  275. package/dist/types/components/illustration/data.d.ts +0 -52
  276. package/dist/types/components/illustration/exports.d.ts +0 -23
  277. package/dist/types/components/illustration/illustration.d.ts +0 -51
  278. package/dist/types/components/illustration/illustrations-ui-kit.d.ts +0 -21
  279. package/dist/types/components/input/exports.d.ts +0 -10
  280. package/dist/types/components/input/input.d.ts +0 -300
  281. package/dist/types/components/input-code/exports.d.ts +0 -4
  282. package/dist/types/components/input-code/input-code.d.ts +0 -175
  283. package/dist/types/components/input-date/exports.d.ts +0 -5
  284. package/dist/types/components/input-date/input-date.d.ts +0 -172
  285. package/dist/types/components/input-password/exports.d.ts +0 -1
  286. package/dist/types/components/input-password/input-password.d.ts +0 -184
  287. package/dist/types/components/input-phone-number/input-phone-number.d.ts +0 -128
  288. package/dist/types/components/label/label.d.ts +0 -9
  289. package/dist/types/components/list-item/list-item/exports.d.ts +0 -4
  290. package/dist/types/components/list-item/list-item/list-item.d.ts +0 -61
  291. package/dist/types/components/pagination/exports.d.ts +0 -6
  292. package/dist/types/components/pagination/pagination.d.ts +0 -140
  293. package/dist/types/components/panel/exports.d.ts +0 -2
  294. package/dist/types/components/panel/panel.d.ts +0 -56
  295. package/dist/types/components/popover/exports.d.ts +0 -6
  296. package/dist/types/components/popover/popover.d.ts +0 -131
  297. package/dist/types/components/popover-action/popover-action.d.ts +0 -24
  298. package/dist/types/components/popover-content/popover-content.d.ts +0 -22
  299. package/dist/types/components/popover-headline/popover-headline.d.ts +0 -6
  300. package/dist/types/components/popover-trigger/exports.d.ts +0 -2
  301. package/dist/types/components/popover-trigger/popover-trigger.d.ts +0 -31
  302. package/dist/types/components/progress-bar/progress-bar.d.ts +0 -10
  303. package/dist/types/components/radio-button/radio-button.d.ts +0 -92
  304. package/dist/types/components/radio-button-description/radio-button-description.d.ts +0 -8
  305. package/dist/types/components/radio-button-leading/radio-button-leading.d.ts +0 -8
  306. package/dist/types/components/radio-button-title/radio-button-title.d.ts +0 -8
  307. package/dist/types/components/radio-button-trailing/radio-button-trailing.d.ts +0 -8
  308. package/dist/types/components/radio-group/exports.d.ts +0 -2
  309. package/dist/types/components/radio-group/radio-group.d.ts +0 -178
  310. package/dist/types/components/select/exports.d.ts +0 -2
  311. package/dist/types/components/select/select.d.ts +0 -317
  312. package/dist/types/components/select-option/select-option.d.ts +0 -113
  313. package/dist/types/components/skip-link/exports.d.ts +0 -2
  314. package/dist/types/components/skip-link/skip-link.d.ts +0 -6
  315. package/dist/types/components/stepper/stepper.d.ts +0 -22
  316. package/dist/types/components/stepper-item/stepper-item.d.ts +0 -23
  317. package/dist/types/components/tab/tab.d.ts +0 -23
  318. package/dist/types/components/tab-panel/tab-panel.d.ts +0 -7
  319. package/dist/types/components/tabs/tabs.d.ts +0 -49
  320. package/dist/types/components/tabs-list/exports.d.ts +0 -4
  321. package/dist/types/components/tabs-list/tabs-list.d.ts +0 -41
  322. package/dist/types/components/textarea/exports.d.ts +0 -2
  323. package/dist/types/components/textarea/textarea.d.ts +0 -158
  324. package/dist/types/components/toast/exports.d.ts +0 -6
  325. package/dist/types/components/toast/toast.d.ts +0 -146
  326. package/dist/types/components/toast-group/exports.d.ts +0 -2
  327. package/dist/types/components/toast-group/toast-group.d.ts +0 -9
  328. package/dist/types/components/tooltip/exports.d.ts +0 -6
  329. package/dist/types/components/tooltip/tooltip.d.ts +0 -131
  330. package/dist/types/components.d.ts +0 -6286
  331. package/dist/types/index.d.ts +0 -1
  332. package/dist/types/stencil-public-runtime.d.ts +0 -1732
  333. package/dist/types/types/jsx-shim.d.ts +0 -13
  334. package/dist/types/types/style-observer.d.ts +0 -20
  335. package/dist/types/utils/focusable.d.ts +0 -1
  336. package/dist/types/utils/formData.d.ts +0 -1
  337. package/dist/types/utils/theming.d.ts +0 -15
  338. package/dist/web-components/index.esm.js +0 -0
  339. package/dist/web-components/p-02b22f8e.entry.js +0 -1
  340. package/dist/web-components/p-075a8dc8.entry.js +0 -1
  341. package/dist/web-components/p-0a34d33b.entry.js +0 -1
  342. package/dist/web-components/p-10cc9983.entry.js +0 -1
  343. package/dist/web-components/p-253068b9.entry.js +0 -1
  344. package/dist/web-components/p-3b8c8951.entry.js +0 -1
  345. package/dist/web-components/p-3beacdab.entry.js +0 -1
  346. package/dist/web-components/p-4214867d.entry.js +0 -1
  347. package/dist/web-components/p-42c857e9.entry.js +0 -1
  348. package/dist/web-components/p-44f87e16.entry.js +0 -1
  349. package/dist/web-components/p-477614c5.entry.js +0 -1
  350. package/dist/web-components/p-495ba3d2.entry.js +0 -1
  351. package/dist/web-components/p-4Uv3PpKT.js +0 -1
  352. package/dist/web-components/p-4de76291.entry.js +0 -1
  353. package/dist/web-components/p-55600d47.entry.js +0 -1
  354. package/dist/web-components/p-562051aa.entry.js +0 -1
  355. package/dist/web-components/p-5b850e0f.entry.js +0 -1
  356. package/dist/web-components/p-6013dfc8.entry.js +0 -1
  357. package/dist/web-components/p-62e7ae04.entry.js +0 -1
  358. package/dist/web-components/p-71519d37.entry.js +0 -1
  359. package/dist/web-components/p-88f7b47f.entry.js +0 -1
  360. package/dist/web-components/p-8975a6a3.entry.js +0 -1
  361. package/dist/web-components/p-8e125826.entry.js +0 -1
  362. package/dist/web-components/p-91cc0bde.entry.js +0 -1
  363. package/dist/web-components/p-93435fcd.entry.js +0 -1
  364. package/dist/web-components/p-947969d7.entry.js +0 -1
  365. package/dist/web-components/p-95396b5c.entry.js +0 -1
  366. package/dist/web-components/p-9de3a1a5.entry.js +0 -1
  367. package/dist/web-components/p-9f583ed1.entry.js +0 -1
  368. package/dist/web-components/p-B9rsR6cQ.js +0 -1
  369. package/dist/web-components/p-CTxpqopm.js +0 -2
  370. package/dist/web-components/p-DQuL1Twl.js +0 -1
  371. package/dist/web-components/p-DvLT8-y3.js +0 -1
  372. package/dist/web-components/p-a1086abe.entry.js +0 -1
  373. package/dist/web-components/p-bbba6d79.entry.js +0 -1
  374. package/dist/web-components/p-bde44ec4.entry.js +0 -1
  375. package/dist/web-components/p-bfc7e6c0.entry.js +0 -1
  376. package/dist/web-components/p-c1030394.entry.js +0 -1
  377. package/dist/web-components/p-c1f59ed1.entry.js +0 -1
  378. package/dist/web-components/p-c80a5541.entry.js +0 -1
  379. package/dist/web-components/p-c96ee61a.entry.js +0 -1
  380. package/dist/web-components/p-caf8f067.entry.js +0 -1
  381. package/dist/web-components/p-cc363c3d.entry.js +0 -1
  382. package/dist/web-components/p-cf4ff357.entry.js +0 -1
  383. package/dist/web-components/p-d0310ed4.entry.js +0 -1
  384. package/dist/web-components/p-d1412932.entry.js +0 -1
  385. package/dist/web-components/p-d2447e30.entry.js +0 -1
  386. package/dist/web-components/p-dc9cca06.entry.js +0 -1
  387. package/dist/web-components/p-e5b943a2.entry.js +0 -1
  388. package/dist/web-components/p-e67b13df.entry.js +0 -1
  389. package/dist/web-components/p-efec231a.entry.js +0 -1
  390. package/dist/web-components/p-f867e4c3.entry.js +0 -1
  391. package/dist/web-components/p-ky1yonnS.js +0 -1
  392. package/dist/web-components/web-components.esm.js +0 -1
  393. package/loader/cdn.js +0 -1
  394. package/loader/index.cjs.js +0 -1
  395. package/loader/index.d.ts +0 -24
  396. package/loader/index.es2017.js +0 -1
  397. package/loader/index.js +0 -2
@@ -1,139 +0,0 @@
1
- 'use strict';
2
-
3
- var index = require('./index-BnETQtSf.js');
4
-
5
- const radioButtonCss = ":host{display:inline-flex;outline:none;position:relative;pointer-events:auto;border:0.0625rem solid transparent;cursor:pointer;min-width:17.5rem}:host slot{display:contents}:host(:hover:not([disabled]:not([disabled=false])):not([checked]:not([checked=false]))){--r-radio-button--cursor:pointer;--r-radio-button--box--background-color:var(--r-background-interactive-hovered, rgba(40, 40, 40, 0.04))}:host(:active:not([disabled]:not([disabled=false])):not([checked]:not([checked=false]))){--r-radio-button--box--border-color:var(--r-border-regular, #282828);--r-radio-button--box--background-color:var(--r-background-interactive-pressed, rgba(40, 40, 40, 0.12))}:host(:focus-within),:host(.focused){--r-radio-button--box--box-shadow:0 0 0 4px var(--r-border-focused-outlined, #fff);--r-radio-button--box--outline:2px solid var(--r-border-focused, #0071e3);--r-radio-button--box--outline-offset:1px}:host([checked]:not([checked=false])),:host([checked]:not([checked=false]):hover){cursor:default;--r-radio-button--box--border-color:var(--r-border-regular, #282828);--r-radio-button--box--background-color:var(--r-background-interactive-softest, #fff);--r-radio-button--marker--transform:scale(1)}:host([invalid]:not([invalid=false])),:host([invalid]:not([invalid=false])[checked]:not([checked=false])){--r-radio-button--box--border-color:var(--r-status-error-regular, #b00c15);--r-radio-button--box--background-color:var(--r-status-error-soft, #fef6f6)}:host([disabled]:not([disabled=false])){--r-radio-button--box--opacity:0.4;cursor:not-allowed}.r-radio-button{display:var(--r-radio-button--display, flex);flex:var(--r-radio-button--flex, 1);gap:var(--r-radio-button--gap, var(--r-spacing-075, 0.75rem));position:var(--r-radio-button--position, relative);min-height:var(--r-radio-button--min-height, 24px);user-select:var(--r-radio-button--user-select, none);box-sizing:var(--r-radio-button--box-sizing, border-box);font-family:var(--r-radio-button--font-family, var(--r-font-family-text, system-ui));font-size:var(--r-radio-button--font-size, var(--r-font-size-400, 1rem));line-height:var(--r-radio-button--line-height, var(--r-line-height-m, 1.5rem));text-align:var(--r-radio-button--text-align, left);color:var(--r-radio-button--color, var(--r-text-regular, #282828));opacity:var(--r-radio-button--opacity, 1);box-shadow:var(--r-radio-button--box-shadow, none);outline:var(--r-radio-button--outline, none);cursor:var(--r-radio-button--cursor, inherit);padding:var(--r-radio-button--padding, var(--r-spacing-100, 1rem));margin:var(--r-radio-button--margin, 0);background-color:var(--r-radio-button--background-color, transparent);border-color:var(--r-radio-button--border-color, transparent);border-width:var(--r-radio-button--border-width, 0);border-style:var(--r-radio-button--border-style, solid)}.r-radio-button--input{position:var(--r-radio-button--input--position, absolute);z-index:var(--r-radio-button--input--z-index, -1);opacity:var(--r-radio-button--input--opacity, 0)}.r-radio-button--box{position:var(--r-radio-button--box--position, relative);display:var(--r-radio-button--box--display, block);top:var(--r-radio-button--box--top, 0);left:var(--r-radio-button--box--left, 0);width:var(--r-radio-button--box--width, 1.5rem);height:var(--r-radio-button--box--height, 1.5rem);background-color:var(--r-radio-button--box--background-color, var(--r-background-interactive-softest, #fff));border-width:var(--r-radio-button--box--border-width, 0.0625rem);border-style:var(--r-radio-button--box--border-style, solid);border-color:var(--r-radio-button--box--border-color, var(--r-border-soft, #686868));border-radius:var(--r-radio-button--box--border-radius, 50%);box-sizing:var(--r-radio-button--box--box-sizing, border-box);box-shadow:var(--r-radio-button--box--box-shadow, none);outline:var(--r-radio-button--box--outline, none);outline-offset:var(--r-radio-button--box--outline-offset, 0);cursor:var(--r-radio-button--box--cursor, inherit);opacity:var(--r-radio-button--box--opacity, 1)}.r-radio-button--box::before{content:var(--r-radio-button--marker--content, \"\");display:var(--r-radio-button--marker--display, block);width:var(--r-radio-button--marker--width, 0.75rem);height:var(--r-radio-button--marker--height, 0.75rem);position:var(--r-radio-button--marker--position, absolute);top:var(--r-radio-button--marker--top, calc(50% - 0.375rem));left:var(--r-radio-button--marker--left, calc(50% - 0.375rem));border-radius:var(--r-radio-button--marker--border-radius, 50%);background-color:var(--r-radio-button--marker--background-color, var(--r-background-interactive-regular, #282828));transition:var(--r-radio-button--marker--transition, 0.1s all);transform:var(--r-radio-button--marker--transform, scale(0));transform-origin:var(--r-radio-button--marker--transform-origin, center)}.r-radio-button--text{flex:var(--r-radio-button--text--flex, 1);display:var(--r-radio-button--text--display, flex);flex-direction:var(--r-radio-button--text--flex-direction, column);gap:var(--r-radio-button--text--gap, var(--r-spacing-025, 0.25rem));font-weight:var(--r-radio-button--text--font-weight, var(--r-font-weight-semibold, 600))}.r-radio-button--leading{min-height:var(--r-radio-button--leading--min-height, var(--r-spacing-150, 1.5rem));min-width:var(--r-radio-button--leading--min-width, calc(var(--r-spacing-150, 1.5rem) + 2 * var(--r-spacing-075, 0.75rem)));color:var(--r-radio-button--leading--color, var(--r-icon-soft, #686868));display:var(--r-radio-button--leading--display, flex);justify-content:var(--r-radio-button--leading--justify-content, center);align-items:var(--r-radio-button--leading--align-items, start)}";
6
-
7
- const RadioButton = class {
8
- constructor(hostRef) {
9
- index.registerInstance(this, hostRef);
10
- this.rChange = index.createEvent(this, "rChange");
11
- this.rReset = index.createEvent(this, "rReset");
12
- this.radioButtonClick = index.createEvent(this, "radioButtonClick");
13
- this.radioButtonKeydown = index.createEvent(this, "radioButtonKeydown");
14
- this.radioButtonDeselect = index.createEvent(this, "radioButtonDeselect");
15
- /** Value of element data within a form */
16
- this.value = this.slotTextValue;
17
- /** Automatically focus the radio button when the component is mounted. Note: Only one element per page should have autofocus set to true, following browser standard behavior. */
18
- this.autofocus = false;
19
- /** Unique id */
20
- this.uniqueId = `r-radio-button-${Date.now().toString(32)}${Math.random().toString(32)}`.replace(/\./g, '');
21
- this.onClick = (event) => {
22
- if (this.disabled)
23
- return;
24
- event.stopPropagation();
25
- event.preventDefault();
26
- this.radioButtonClick.emit(event);
27
- };
28
- this.onKeydown = (event) => {
29
- if (this.disabled)
30
- return;
31
- this.radioButtonKeydown.emit(event);
32
- };
33
- this.onFocus = () => {
34
- this.host.classList.add('focused');
35
- };
36
- this.onBlur = () => {
37
- this.host.classList.remove('focused');
38
- };
39
- this.applyAutofocus = () => {
40
- queueMicrotask(() => {
41
- this.setFocus();
42
- });
43
- };
44
- }
45
- /** Sets focus on the radio button element */
46
- async setFocus() {
47
- var _a;
48
- (_a = this.nativeEl) === null || _a === void 0 ? void 0 : _a.focus();
49
- }
50
- /** Blurs the radio button element */
51
- async setBlur() {
52
- var _a;
53
- (_a = this.nativeEl) === null || _a === void 0 ? void 0 : _a.blur();
54
- }
55
- /** Selects the radio button element */
56
- async select() {
57
- var _a, _b, _c;
58
- if (this.checked)
59
- return;
60
- if (this.disabled)
61
- return;
62
- (_a = this.radioElements) === null || _a === void 0 ? void 0 : _a.forEach(radio => {
63
- radio.checked = false;
64
- radio.shadowRoot.querySelector('.r-radio-button--input').setAttribute('tabindex', '-1');
65
- });
66
- this.checked = true;
67
- (_b = this.nativeEl) === null || _b === void 0 ? void 0 : _b.setAttribute('tabindex', '0');
68
- (_c = this.nativeEl) === null || _c === void 0 ? void 0 : _c.focus();
69
- const { host, value, checked } = this;
70
- this.rChange.emit({ element: host, value, checked });
71
- }
72
- /** Reference to the radio button elements */
73
- get radioElements() {
74
- if (this.groupEl) {
75
- // Use :scope > to only select direct children, excluding nested radio-group buttons
76
- return this.groupEl.querySelectorAll(`:scope > r-radio-button`);
77
- }
78
- if (this.parentFormEl) {
79
- return this.parentFormEl.querySelectorAll(`r-radio-button[name=${this.name}]`);
80
- }
81
- return document.querySelectorAll(`r-radio-button[name=${this.name}]`);
82
- }
83
- /** Get the text content of the slot */
84
- get slotTextValue() {
85
- return this.host.textContent || null;
86
- }
87
- /** Identify wrapping radio group element */
88
- get groupEl() {
89
- return this.host.closest('r-radio-group') || null;
90
- }
91
- /** Identify wrapping form element */
92
- get parentFormEl() {
93
- return this.host.closest('form') || null;
94
- }
95
- /** Check if the radio button is leading */
96
- get isLeading() {
97
- return this.icon !== undefined || this.host.querySelector('[slot="leading"]') !== null || this.host.querySelector('r-radio-button-leading') !== null;
98
- }
99
- /** Check if the radio button is trailing */
100
- get isTrailing() {
101
- return this.host.querySelector('[slot="trailing"]') !== null || this.host.querySelector('r-radio-button-trailing') !== null;
102
- }
103
- get shouldAutofocus() {
104
- return this.autofocus && (!this.groupEl || !this.groupEl.autofocus);
105
- }
106
- componentWillLoad() {
107
- if (!this.initialState)
108
- this.initialState = this.checked;
109
- if (this.groupEl && !this.name) {
110
- this.name = this.groupEl.name;
111
- }
112
- }
113
- componentDidLoad() {
114
- if (this.shouldAutofocus)
115
- this.applyAutofocus();
116
- }
117
- render() {
118
- const { name, value, checked, disabled, hint, uniqueId, required, invalid, error, autofocus } = this;
119
- const inputAttrs = {
120
- type: 'radio',
121
- tabindex: '-1',
122
- name,
123
- value,
124
- disabled,
125
- checked,
126
- required,
127
- autofocus
128
- };
129
- return (index.h(index.Host, { key: 'cf6b1b5db202773a2c6eea4df6a9303275054a73' }, index.h("label", { key: '4e203583a2b779e239c2893eadccc3514f84b0c4', class: "r-radio-button", onClick: this.onClick, onKeyDown: this.onKeydown }, index.h("input", Object.assign({ key: '14e89b050928abd51b66e8637c39bbd8da8e9856' }, inputAttrs, { id: `${uniqueId}-input`, class: "r-radio-button--input", ref: el => this.nativeEl = el, onFocus: this.onFocus, onBlur: this.onBlur })), index.h("span", { key: 'ee55afd60c5dbb947e9c12fffc401f7acfcefada', class: "r-radio-button--box" }), this.isLeading &&
130
- index.h("div", { key: 'eabd27b399dee0bc2cef0fb7a92adad55095708b', class: "r-radio-button--leading" }, index.h("slot", { key: '5ec99653141268456cf9c8b2398f70c7b1afd36d', name: "leading" }, this.icon && index.h("r-icon", { key: '47662e84ad1aac02e867ddd040b5b7e1890ba986', name: this.icon, size: "m" }))), index.h("div", { key: 'bcaaf67c6cdf95a0bfa0dd5784d69c237e551a0e', class: "r-radio-button--text" }, index.h("slot", { key: 'a54f1823afe368d85f9bd4743ac0aa1df7298049', name: "title" }, index.h("div", { key: 'b531b659b920d7f064f10e622b83099d14270935', style: { display: 'contents' } }, index.h("slot", { key: 'b51f3e83234681804c49cb1043d90de70e4929db' }))), index.h("slot", { key: 'd217abfd3675898afd5b41a543200f7104019aed', name: "description" }, this.description)), this.isTrailing &&
131
- index.h("div", { key: '664ddcc19dba3029343532caa13b05a6e3834977', class: "r-radio-button--trailing" }, index.h("slot", { key: 'b4ec626236a01c9c74b20ae09194ea414bc7699c', name: "trailing" }))), invalid && error &&
132
- index.h("r-hint", { key: 'bd60d4337984662f410613b470b6e3be695343f5', role: "alert", variant: "error", id: `${uniqueId}-hint` }, this.error), hint &&
133
- index.h("r-hint", { key: '31c5712fe6f2164219e28484a40ce5452a836743', role: "note", variant: "information", id: `${uniqueId}-hint` }, hint)));
134
- }
135
- get host() { return index.getElement(this); }
136
- };
137
- RadioButton.style = radioButtonCss;
138
-
139
- exports.r_radio_button = RadioButton;
@@ -1,425 +0,0 @@
1
- 'use strict';
2
-
3
- var index = require('./index-BnETQtSf.js');
4
- var formData = require('./formData-B2DZyLxP.js');
5
-
6
- const radioGroupCss = ":host{display:flex;flex-direction:column;box-sizing:border-box;margin-bottom:var(--r-spacing-100)}:host ::slotted(r-radio-button){display:var(--r-radio-group--slotted-radio-button--display, flex)}:host ::slotted(.focused){--r-radio-button--box-shadow:0 0 0 3px var(--r-border-focused-outlined, #fff), inset 0 0 0 1px var(--r-border-focused-outlined, #fff);--r-radio-button--outline:2px solid var(--r-border-focused, #0071e3);--r-radio-button--outline-offset:2px}:host slot{display:contents}:host([variant=contained]) ::slotted(r-radio-button){padding:0;--r-radio-button--padding:var(--r-spacing-100, 1rem);--r-radio-button--border-color:var(--r-border-soft, #686868);--r-radio-button--border-width:1px}:host([invalid]:not([invalid=false])) ::slotted(r-radio-button){--r-radio-button--box--border-color:var(--r-status-error-regular, #b00c15);--r-radio-button--box--background-color:var(--r-status-error-soft, #fef6f6);--r-radio-button--marker--background-color:var(--r-status-error-regular, #b00c15)}:host .r-radio-group{display:var(--r-radio-group--display, flex);flex-direction:var(--r-radio-group--flex-direction, column);padding:var(--r-radio-group--padding, 0);margin:var(--r-radio-group--margin, 0);border:var(--r-radio-group--border, none)}:host .r-radio-group--label-container{display:var(--r-radio-group--label-container--display, flex);gap:var(--r-radio-group--label-container--gap, var(--r-spacing-100, 1rem));align-items:var(--r-radio-group--label-container--align-items, center);justify-content:var(--r-radio-group--label-container--justify-content, space-between)}:host .r-radio-group--label-container ::slotted([slot=popover]){display:var(--r-radio-group--popover--display, inline-flex);height:var(--r-radio-group--popover--height, var(--r-spacing-150, 1.5));align-items:var(--r-radio-group--popover--align-items, center);justify-content:var(--r-radio-group--popover--justify-content, center);margin-right:var(--r-radio-group--popover--margin-right, -0.25rem);--r-popover--trigger--min-width:var(--r-radio-group--popover-trigger--min-width, var(--r-spacing-150, 1.5));--r-popover--trigger--min-height:var(--r-radio-group--popover--trigger--min-height, var(--r-spacing-150, 1.5))}:host .r-radio-group--hint{margin-bottom:var(--r-radio-group--hint--margin-bottom, var(--r-spacing-100, 1rem))}:host .r-radio-group--content{display:var(--r-radio-group--content--display, flex);flex-direction:var(--r-radio-group--content--flex-direction, column);flex-wrap:var(--r-radio-group--content--flex-wrap, nowrap);gap:var(--r-radio-group--content--gap, var(--r-spacing-050, 0.5rem))}:host .r-radio-group+.r-radio-group--message r-hint{margin-top:var(--r-radio-group--hint--margin-top, var(--r-spacing-050, 0.5rem))}";
7
-
8
- const RadioGroup = class {
9
- constructor(hostRef) {
10
- index.registerInstance(this, hostRef);
11
- this.rValidate = index.createEvent(this, "rValidate");
12
- this.rChange = index.createEvent(this, "rChange");
13
- this.rReset = index.createEvent(this, "rReset");
14
- /** Controls the style variation of the radio buttons. */
15
- this.variant = 'standard';
16
- /**
17
- * When set to `true`, automatically focuses the first enabled radio button in the group on mount.
18
- * This will focus the selected radio button if one exists, or the first enabled radio button otherwise.
19
- */
20
- this.autofocus = false;
21
- this.validityState = '';
22
- this.validityMessage = '';
23
- /**
24
- * Initial attributes state
25
- * */
26
- this.initial = {};
27
- /** Unique id */
28
- this.uniqueId = `r-radio-group-${Date.now().toString(32)}${Math.random().toString(32)}`.replace(/\./g, '');
29
- this.getValidityStateData = element => {
30
- let validityState = '';
31
- let validityMessage = '';
32
- if (element === null)
33
- return { validityState, validityMessage };
34
- for (const state in element.validity) {
35
- if (element.validity[state]) {
36
- validityState = state;
37
- if (this[state + 'Message']) {
38
- validityMessage = this[state + 'Message'];
39
- return { validityState, validityMessage };
40
- }
41
- validityMessage = element.validationMessage;
42
- }
43
- }
44
- return { validityState, validityMessage };
45
- };
46
- this.validateFormElement = (element = null) => {
47
- if (element === null)
48
- return;
49
- if (this.isNoValidate)
50
- return;
51
- if (this.error)
52
- return;
53
- const { validityState, validityMessage } = this.getValidityStateData(element);
54
- this.validityState = validityState;
55
- this.validityMessage = validityMessage;
56
- const isValid = this.validityState === 'valid';
57
- this.valid = isValid;
58
- this.invalid = !isValid;
59
- this.rValidate.emit({
60
- state: this.validityState,
61
- message: this.validityMessage
62
- });
63
- };
64
- this.onSubmitForm = (event) => {
65
- if (this.isNoValidate)
66
- return;
67
- this.validateFormElement(this.nativeSelectedEl || this.nativeFirstEl);
68
- if (!this.hasSelected || this.invalid) {
69
- event.preventDefault();
70
- event.stopPropagation();
71
- }
72
- };
73
- this.onResetForm = () => {
74
- this.reset();
75
- };
76
- this.onLabelClick = () => {
77
- const radioButtonEl = this.radioButtonElements[0].shadowRoot.querySelector('[type="radio"]');
78
- radioButtonEl === null || radioButtonEl === void 0 ? void 0 : radioButtonEl.focus();
79
- };
80
- this.contributeToFormData = (event) => {
81
- formData.appendControlToFormData(this.host, event.formData);
82
- };
83
- /**
84
- * Handles parent radio group value changes for nested groups.
85
- * If this is a nested group with a parentValue specified, it will reset when
86
- * the parent group's value changes to something other than the parentValue.
87
- */
88
- this.onParentGroupChange = (event) => {
89
- // Only proceed if this group has a parentValue specified (indicating it's nested)
90
- if (!this.parentValue)
91
- return;
92
- const parentNewValue = event.detail.value;
93
- // If parent changed to a different value than our parentValue, reset this nested group
94
- if (parentNewValue !== this.parentValue) {
95
- this.clearValue();
96
- // Emit rReset event to notify that the nested group was automatically reset
97
- this.rReset.emit({
98
- element: this.host,
99
- value: null
100
- });
101
- }
102
- };
103
- }
104
- rChangeAction(event) {
105
- // Only handle events from direct children, not from nested radio-groups
106
- const targetElement = event.target;
107
- const isDirectChild = targetElement.parentElement === this.host;
108
- if (!isDirectChild) {
109
- return; // Ignore events from nested radio-groups
110
- }
111
- // Stop event from bubbling to parent radio-groups
112
- event.stopPropagation();
113
- this.resetValidity();
114
- this.setValue(event.detail.value);
115
- }
116
- /**
117
- * Resets the radio group to its initial state.
118
- * This method clears the validity state and message, and sets the value and validity
119
- * to their initial values.
120
- */
121
- radioButtonClickAction(event) {
122
- // Only handle events from direct children, not from nested radio-groups
123
- const targetElement = event.target;
124
- const isDirectChild = targetElement.parentElement === this.host;
125
- if (!isDirectChild) {
126
- return; // Ignore events from nested radio-groups
127
- }
128
- // Stop event from bubbling to parent radio-groups
129
- event.stopPropagation();
130
- !event.target.disabled && event.target.select();
131
- }
132
- get selectedIndex() {
133
- return Array.from(this.radioButtonElements).findIndex(el => el.hasAttribute('checked'));
134
- }
135
- get prevIndex() {
136
- const isNoSelected = this.selectedIndex === -1;
137
- const isnativeFirstElement = this.selectedIndex === 0;
138
- return isnativeFirstElement || isNoSelected ? this.radioButtonElements.length - 1 : this.selectedIndex - 1;
139
- }
140
- get focusedRadioButtonEl() {
141
- // Query all descendants to find focused element, but it will only be used for direct children
142
- return this.host.querySelector('r-radio-button.focused');
143
- }
144
- get focusedRadioButtonElIndex() {
145
- return Array.from(this.radioButtonElements).indexOf(this.focusedRadioButtonEl);
146
- }
147
- get nextIndex() {
148
- const isNoSelected = this.selectedIndex === -1;
149
- if (isNoSelected) {
150
- return this.focusedRadioButtonElIndex === -1 ? 0 : this.focusedRadioButtonElIndex + 1;
151
- }
152
- const isLastElement = this.selectedIndex === this.radioButtonElements.length - 1;
153
- return isLastElement ? 0 : this.selectedIndex + 1;
154
- }
155
- radioButtonKeydownAction(event) {
156
- var _a;
157
- // Only handle events from direct children, not from nested radio-groups
158
- const targetElement = event.target;
159
- const isDirectChild = targetElement.parentElement === this.host;
160
- if (!isDirectChild) {
161
- return; // Ignore events from nested radio-groups
162
- }
163
- // Stop event from bubbling to parent radio-groups
164
- event.stopPropagation();
165
- switch (event.detail.code) {
166
- case 'ArrowUp':
167
- case 'ArrowLeft':
168
- // Select previous radio button
169
- this.radioButtonElements[this.prevIndex].select();
170
- break;
171
- case 'ArrowDown':
172
- case 'ArrowRight':
173
- // Select next radio button
174
- this.radioButtonElements[this.nextIndex].select();
175
- break;
176
- case 'Enter': {
177
- const submitEl = this.host.querySelector('[type="submit"]') ||
178
- ((_a = this.parentFormEl) === null || _a === void 0 ? void 0 : _a.querySelector('[type="submit"]'));
179
- if (submitEl && 'triggerClick' in submitEl) {
180
- submitEl === null || submitEl === void 0 ? void 0 : submitEl.triggerClick();
181
- }
182
- else {
183
- this.parentFormEl.requestSubmit();
184
- }
185
- break;
186
- }
187
- }
188
- }
189
- /**
190
- * Resets the validity state and message of the radio group.
191
- * This method clears the validity message and state, and sets the invalid
192
- * property to its initial value.
193
- */
194
- async resetValidity() {
195
- this.validityMessage = null;
196
- this.validityState = null;
197
- this.invalid = this.initial['invalid'];
198
- this.valid = !this.invalid;
199
- }
200
- /**
201
- * Resets the radio group to its initial state.
202
- *
203
- * This method:
204
- * - clears the validity state and message,
205
- * - sets the value and validity to initial values,
206
- * - if no initial value the radio group will be deselected,
207
- * - restores the tabindex on the first element.
208
- */
209
- async reset() {
210
- this.resetValidity();
211
- if (this.initial['value']) {
212
- this.setValue(this.initial['value']);
213
- return;
214
- }
215
- // Set default value to null
216
- this.clearValue();
217
- }
218
- /**
219
- * Sets the value of the radio group to the specified value.
220
- * If a radio button with the specified value exists, it will be selected.
221
- *
222
- * @param value - The value to set for the radio group.
223
- */
224
- async setValue(value) {
225
- const element = Array.from(this.radioButtonElements).find(el => el.value === value);
226
- if (element === undefined) {
227
- this.clearValue();
228
- return;
229
- }
230
- this.value = value;
231
- element === null || element === void 0 ? void 0 : element.select();
232
- }
233
- /**
234
- * Gets the current value of the radio group.
235
- *
236
- * @returns The current value of the radio group.
237
- */
238
- async getValue() {
239
- return this.value || null;
240
- }
241
- /**
242
- * Clears the value of the radio group and deselects all radio buttons.
243
- * This method sets the value to null and deselects all radio buttons in the group.
244
- */
245
- async clearValue() {
246
- var _a, _b, _c, _d, _e, _f;
247
- const isSelectedEqualsFirst = ((_a = this.nativeSelectedEl) === null || _a === void 0 ? void 0 : _a.value) === ((_b = this.nativeFirstEl) === null || _b === void 0 ? void 0 : _b.value);
248
- if (!isSelectedEqualsFirst) {
249
- (_c = this.nativeSelectedEl) === null || _c === void 0 ? void 0 : _c.setAttribute('tabindex', '-1');
250
- }
251
- (_d = this.nativeSelectedEl) === null || _d === void 0 ? void 0 : _d.setAttribute('tabindex', '-1');
252
- (_e = this.nativeFirstEl) === null || _e === void 0 ? void 0 : _e.setAttribute('tabindex', '0');
253
- (_f = this.selectedRadioButtonElement) === null || _f === void 0 ? void 0 : _f.removeAttribute('checked');
254
- this.value = null;
255
- }
256
- /**
257
- * Validates the radio group without triggering UI and returns a boolean indicating its validity.
258
- * @returns A boolean indicating whether the radio group is valid.
259
- */
260
- async checkValidity() {
261
- const element = this.nativeSelectedEl || this.nativeFirstEl || null;
262
- const { validityState } = this.getValidityStateData(element);
263
- return validityState === 'valid';
264
- }
265
- /**
266
- * Validates the radio group and displays the validity state.
267
- */
268
- async reportValidity() {
269
- const element = this.nativeSelectedEl || this.nativeFirstEl || null;
270
- this.validateFormElement(element);
271
- return this.validityState === 'valid';
272
- }
273
- /**
274
- * Sets a custom validity message for the radio group.
275
- * If the message is not empty, the radio group will be considered invalid.
276
- *
277
- * @param message - The custom validity message to set.
278
- */
279
- async setCustomValidity(message) {
280
- const element = this.nativeSelectedEl || this.nativeFirstEl || null;
281
- this.customErrorMessage = message;
282
- this.validateFormElement(element);
283
- }
284
- /**
285
- * Sets focus on the radio button element.
286
- * */
287
- async setFocus() {
288
- const element = this.selectedRadioButtonElement || this.radioButtonElements[0] || null;
289
- element === null || element === void 0 ? void 0 : element.setFocus();
290
- }
291
- /**
292
- * Blurs the radio button element.
293
- * */
294
- async setBlur() {
295
- var _a;
296
- (_a = this.focusedRadioButtonEl) === null || _a === void 0 ? void 0 : _a.setBlur();
297
- }
298
- /** Determine whether this element should be ignored during Constraint Validation API validation. */
299
- get isNoValidate() {
300
- var _a;
301
- return (((_a = this.parentFormEl) === null || _a === void 0 ? void 0 : _a.hasAttribute('novalidate')) ||
302
- this.novalidate ||
303
- !this.required ||
304
- false);
305
- }
306
- /** Identify wrapping form element */
307
- get parentFormEl() {
308
- return this.host.closest('form') || document.querySelector(`#${this.form}`) || null;
309
- }
310
- get radioButtonElements() {
311
- // Use :scope > to only select direct children, excluding nested radio-group buttons
312
- return this.host.querySelectorAll(':scope > r-radio-button:not([disabled]:not([disabled="false"]))');
313
- }
314
- get selectedRadioButtonElement() {
315
- return Array.from(this.radioButtonElements).find(el => el.checked || el.hasAttribute('checked')) || null;
316
- }
317
- get hasSelected() {
318
- return Array.from(this.radioButtonElements).some(el => el.checked || el.hasAttribute('checked'));
319
- }
320
- get nativeSelectedEl() {
321
- var _a, _b;
322
- if (this.selectedRadioButtonElement === null)
323
- return null;
324
- return ((_b = (_a = this.selectedRadioButtonElement) === null || _a === void 0 ? void 0 : _a.shadowRoot) === null || _b === void 0 ? void 0 : _b.querySelector('.r-radio-button--input')) || null;
325
- }
326
- get nativeFirstEl() {
327
- var _a, _b;
328
- return ((_b = (_a = this.radioButtonElements[0]) === null || _a === void 0 ? void 0 : _a.shadowRoot) === null || _b === void 0 ? void 0 : _b.querySelector('.r-radio-button--input')) || null;
329
- }
330
- passPropsToGroupItems(props = {}) {
331
- Object.entries(props).forEach(([key, value]) => {
332
- this.radioButtonElements.forEach(el => {
333
- if (typeof value === 'string')
334
- el.setAttribute(key, value);
335
- if (typeof value === 'boolean' && value)
336
- el.setAttribute(key, '');
337
- });
338
- });
339
- }
340
- selectGroupItemByValue() {
341
- if (this.hasSelected && !this.value) {
342
- this.value = this.selectedRadioButtonElement.value;
343
- }
344
- this.setValue(this.value);
345
- }
346
- setTabindex() {
347
- const el = this.nativeSelectedEl || this.nativeFirstEl;
348
- el === null || el === void 0 ? void 0 : el.setAttribute('tabindex', '0');
349
- }
350
- get parentRadioGroup() {
351
- var _a;
352
- // Find the parent radio group element
353
- return ((_a = this.host.parentElement) === null || _a === void 0 ? void 0 : _a.closest('r-radio-group')) || null;
354
- }
355
- connectFormEventListeners() {
356
- var _a, _b, _c;
357
- (_a = this.parentFormEl) === null || _a === void 0 ? void 0 : _a.addEventListener('formdata', this.contributeToFormData);
358
- (_b = this.parentFormEl) === null || _b === void 0 ? void 0 : _b.addEventListener('reset', this.onResetForm);
359
- (_c = this.parentFormEl) === null || _c === void 0 ? void 0 : _c.addEventListener('submit', this.onSubmitForm, { capture: true });
360
- }
361
- disconnectFormEventListeners() {
362
- var _a, _b, _c;
363
- (_a = this.parentFormEl) === null || _a === void 0 ? void 0 : _a.removeEventListener('formdata', this.contributeToFormData);
364
- (_b = this.parentFormEl) === null || _b === void 0 ? void 0 : _b.removeEventListener('reset', this.onResetForm);
365
- (_c = this.parentFormEl) === null || _c === void 0 ? void 0 : _c.removeEventListener('submit', this.onSubmitForm);
366
- }
367
- connectParentGroupListener() {
368
- // Only connect if this is a nested group (has parentValue specified)
369
- if (this.parentValue && this.parentRadioGroup) {
370
- this.parentRadioGroup.addEventListener('rChange', this.onParentGroupChange);
371
- }
372
- }
373
- disconnectParentGroupListener() {
374
- if (this.parentValue && this.parentRadioGroup) {
375
- this.parentRadioGroup.removeEventListener('rChange', this.onParentGroupChange);
376
- }
377
- }
378
- get ariaDescribedBy() {
379
- const messageId = `${this.uniqueId}-message`;
380
- return this.hint ? `${this.uniqueId}-hint ${messageId}` : messageId;
381
- }
382
- connectedCallback() {
383
- this.connectFormEventListeners();
384
- this.connectParentGroupListener();
385
- }
386
- disconnectedCallback() {
387
- this.disconnectFormEventListeners();
388
- this.disconnectParentGroupListener();
389
- }
390
- componentWillLoad() {
391
- const { required, name } = this;
392
- this.passPropsToGroupItems({ required, name });
393
- // If `value` is provided: item within group with such value shall be selected
394
- this.selectGroupItemByValue();
395
- this.initial['value'] = this.value;
396
- this.initial['invalid'] = this.invalid;
397
- }
398
- componentDidLoad() {
399
- const { name, required } = this;
400
- this.passPropsToGroupItems({ name, required });
401
- this.setTabindex();
402
- if (this.autofocus) {
403
- // Use setTimeout to ensure setValue has completed and checked state is synced
404
- setTimeout(() => {
405
- this.setFocus();
406
- }, 0);
407
- }
408
- }
409
- render() {
410
- const { label, hint, fieldIndicator, error, uniqueId, invalid } = this;
411
- const fieldsetAttrs = {
412
- 'aria-invalid': `${invalid || false}`,
413
- 'aria-describedby': this.ariaDescribedBy
414
- };
415
- return (index.h(index.Host, { key: 'bd1b1d42f3efab78cf0a2cce7b1a1e2568f21765' }, index.h("fieldset", Object.assign({ key: 'c449667b014cf8aeea4176b0d94c82573b661182', class: "r-radio-group" }, fieldsetAttrs, { onClick: this.onLabelClick }), label &&
416
- index.h("legend", { key: '212e27fd8d20b31cf6d84078870ec59796bb59c6', class: "r-radio-group--label-container" }, index.h("r-label", { key: '69907b0e2bdb49bcdea00d1849bc0c5c4d3404ae', id: `${uniqueId}-label`, class: "r-radio-group--label", "field-indicator": fieldIndicator }, label), index.h("slot", { key: 'd208c147248154ba26ecc5b412233d2cf479bb68', name: "popover" })), hint &&
417
- index.h("r-hint", { key: 'b409e053226d88ac3619524b2d63864b49972985', id: `${uniqueId}-hint`, class: "r-radio-group--hint", role: "note" }, hint), index.h("div", { key: 'c8e98214e9b14f6fdcf97677b392abd14d653a56', class: "r-radio-group--content" }, index.h("slot", { key: '5e4aa07801e8f1bd7ec3262511d28f553d8740a7' })), index.h("div", { key: 'a576e8c91d33877eb677d5551ac18d10924586fd', id: `${uniqueId}-message`, "aria-live": "polite", role: "alert", class: "r-radio-group--message" }, invalid && error &&
418
- index.h("r-hint", { key: '98f7fa6855c0803ae5d31a3a248c146679204af9', variant: "error" }, error), this.validityState !== 'valid' && this.validityMessage &&
419
- index.h("r-hint", { key: 'de1997af842a7e5fdb887a830fd0fe701e4fa5ce', variant: "error" }, this.customErrorMessage || this.validityMessage)))));
420
- }
421
- get host() { return index.getElement(this); }
422
- };
423
- RadioGroup.style = radioGroupCss;
424
-
425
- exports.r_radio_group = RadioGroup;