@public-ui/components 3.0.6-rc.0 → 3.0.6-rc.2

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 (827) hide show
  1. package/custom-elements.json +55 -61
  2. package/dist/cjs/{Alert-DcMlrzdD.js → Alert-Do6ehPPd.js} +1 -1
  3. package/dist/cjs/{Alert-DcMlrzdD.js.map → Alert-Do6ehPPd.js.map} +1 -1
  4. package/dist/cjs/{Collapsible-B6jbiscX.js → Collapsible-DLJ9ngpN.js} +1 -1
  5. package/dist/cjs/{Collapsible-B6jbiscX.js.map → Collapsible-DLJ9ngpN.js.map} +1 -1
  6. package/dist/cjs/{CustomSuggestionsToggle-c_U9sjXZ.js → CustomSuggestionsToggle-CQNbxrFu.js} +1 -1
  7. package/dist/cjs/{CustomSuggestionsToggle-c_U9sjXZ.js.map → CustomSuggestionsToggle-CQNbxrFu.js.map} +1 -1
  8. package/dist/cjs/FieldControlStateWrapper-BTPMHsM1.js +4 -0
  9. package/dist/cjs/FieldControlStateWrapper-BTPMHsM1.js.map +1 -0
  10. package/dist/cjs/FormFieldStateWrapper-C8Ds5tPB.js +4 -0
  11. package/dist/cjs/FormFieldStateWrapper-C8Ds5tPB.js.map +1 -0
  12. package/dist/cjs/{Heading-CAbB1kIb.js → Heading-DGnr9w8b.js} +1 -1
  13. package/dist/cjs/{Heading-CAbB1kIb.js.map → Heading-DGnr9w8b.js.map} +1 -1
  14. package/dist/cjs/{Icon-DSj-XpeC.js → Icon-CrlBnVcz.js} +1 -1
  15. package/dist/cjs/{Icon-DSj-XpeC.js.map → Icon-CrlBnVcz.js.map} +1 -1
  16. package/dist/cjs/Input-DMeMmmBn.js +4 -0
  17. package/dist/cjs/Input-DMeMmmBn.js.map +1 -0
  18. package/dist/cjs/InputStateWrapper-0zKOwPtz.js +4 -0
  19. package/dist/cjs/InputStateWrapper-0zKOwPtz.js.map +1 -0
  20. package/dist/cjs/{InternalUnderlinedBadgeText-BkQ9DFaD.js → InternalUnderlinedBadgeText-DPW4yX2Z.js} +1 -1
  21. package/dist/cjs/{InternalUnderlinedBadgeText-BkQ9DFaD.js.map → InternalUnderlinedBadgeText-DPW4yX2Z.js.map} +1 -1
  22. package/dist/cjs/{Span-DPo-84T2.js → Span-BBoWRjZC.js} +1 -1
  23. package/dist/cjs/{Span-DPo-84T2.js.map → Span-BBoWRjZC.js.map} +1 -1
  24. package/dist/cjs/access-and-short-key-BExF929g.js.map +1 -1
  25. package/dist/cjs/align-floating-elements-Bxx5nIn-.js.map +1 -1
  26. package/dist/cjs/{app-globals-4QvupzFj.js → app-globals-9cT_8sCJ.js} +1 -1
  27. package/dist/cjs/{app-globals-4QvupzFj.js.map → app-globals-9cT_8sCJ.js.map} +1 -1
  28. package/dist/cjs/associated.controller-Dpp0zVIP.js.map +1 -1
  29. package/dist/cjs/bootstrap-B3uKTmEF.js.map +1 -1
  30. package/dist/cjs/color-D7OxzTlF.js.map +1 -1
  31. package/dist/cjs/common-Cd2qH809.js.map +1 -1
  32. package/dist/cjs/controller-BF3IbQCZ.js.map +1 -1
  33. package/dist/cjs/{controller-ZfXZFg-x.js → controller-C2cxr6Rw.js} +1 -1
  34. package/dist/cjs/{controller-ZfXZFg-x.js.map → controller-C2cxr6Rw.js.map} +1 -1
  35. package/dist/cjs/{controller-B1n3An30.js → controller-Ccj6Gm2M.js} +1 -1
  36. package/dist/cjs/{controller-B1n3An30.js.map → controller-Ccj6Gm2M.js.map} +1 -1
  37. package/dist/cjs/{controller-BszsfOUC.js → controller-DvExtwnx.js} +1 -1
  38. package/dist/cjs/{controller-BszsfOUC.js.map → controller-DvExtwnx.js.map} +1 -1
  39. package/dist/cjs/controller-icon-QLNq0HO6.js +4 -0
  40. package/dist/cjs/controller-icon-QLNq0HO6.js.map +1 -0
  41. package/dist/cjs/{dev.utils-C863Y3KX.js → dev.utils-UE8Qk4FC.js} +1 -1
  42. package/dist/cjs/{dev.utils-C863Y3KX.js.map → dev.utils-UE8Qk4FC.js.map} +1 -1
  43. package/dist/cjs/{devtools-D2vBkrTT.js → devtools-DaWRMPjB.js} +1 -1
  44. package/dist/cjs/{devtools-D2vBkrTT.js.map → devtools-DaWRMPjB.js.map} +1 -1
  45. package/dist/cjs/i18n-Drgbs46L.js.map +1 -1
  46. package/dist/cjs/icons-CvKgcv20.js.map +1 -1
  47. package/dist/cjs/index-CMEXkCjL.js +4 -0
  48. package/dist/cjs/index-CMEXkCjL.js.map +1 -0
  49. package/dist/cjs/index.cjs.js.map +1 -1
  50. package/dist/cjs/kol-abbr.cjs.entry.js +1 -1
  51. package/dist/cjs/kol-abbr.entry.cjs.js.map +1 -1
  52. package/dist/cjs/kol-accordion.cjs.entry.js +1 -1
  53. package/dist/cjs/kol-alert-wc.cjs.entry.js +1 -1
  54. package/dist/cjs/kol-alert.cjs.entry.js +1 -1
  55. package/dist/cjs/kol-alert.entry.cjs.js.map +1 -1
  56. package/dist/cjs/kol-avatar-wc.cjs.entry.js +1 -1
  57. package/dist/cjs/kol-avatar.cjs.entry.js +1 -1
  58. package/dist/cjs/kol-badge.cjs.entry.js +1 -1
  59. package/dist/cjs/kol-badge.entry.cjs.js.map +1 -1
  60. package/dist/cjs/kol-breadcrumb.cjs.entry.js +1 -1
  61. package/dist/cjs/kol-breadcrumb.entry.cjs.js.map +1 -1
  62. package/dist/cjs/kol-button-link.cjs.entry.js +1 -1
  63. package/dist/cjs/kol-button-link.entry.cjs.js.map +1 -1
  64. package/dist/cjs/kol-button-wc.cjs.entry.js +1 -1
  65. package/dist/cjs/kol-button-wc.entry.cjs.js.map +1 -1
  66. package/dist/cjs/kol-button.cjs.entry.js +1 -1
  67. package/dist/cjs/kol-button.entry.cjs.js.map +1 -1
  68. package/dist/cjs/kol-card-wc.cjs.entry.js +1 -1
  69. package/dist/cjs/kol-card.cjs.entry.js +1 -1
  70. package/dist/cjs/kol-card.entry.cjs.js.map +1 -1
  71. package/dist/cjs/kol-combobox.cjs.entry.js +1 -1
  72. package/dist/cjs/kol-combobox.entry.cjs.js.map +1 -1
  73. package/dist/cjs/kol-details.cjs.entry.js +1 -1
  74. package/dist/cjs/kol-drawer.cjs.entry.js +1 -1
  75. package/dist/cjs/kol-drawer.entry.cjs.js.map +1 -1
  76. package/dist/cjs/kol-form.cjs.entry.js +1 -1
  77. package/dist/cjs/kol-form.entry.cjs.js.map +1 -1
  78. package/dist/cjs/kol-heading.cjs.entry.js +1 -1
  79. package/dist/cjs/kol-icon.cjs.entry.js +1 -1
  80. package/dist/cjs/kol-image.cjs.entry.js +1 -1
  81. package/dist/cjs/kol-input-checkbox.cjs.entry.js +1 -1
  82. package/dist/cjs/kol-input-checkbox.entry.cjs.js.map +1 -1
  83. package/dist/cjs/kol-input-color.cjs.entry.js +1 -1
  84. package/dist/cjs/kol-input-color.entry.cjs.js.map +1 -1
  85. package/dist/cjs/kol-input-date.cjs.entry.js +1 -1
  86. package/dist/cjs/kol-input-date.entry.cjs.js.map +1 -1
  87. package/dist/cjs/kol-input-email.cjs.entry.js +1 -1
  88. package/dist/cjs/kol-input-email.entry.cjs.js.map +1 -1
  89. package/dist/cjs/kol-input-file.cjs.entry.js +1 -1
  90. package/dist/cjs/kol-input-file.entry.cjs.js.map +1 -1
  91. package/dist/cjs/kol-input-number.cjs.entry.js +1 -1
  92. package/dist/cjs/kol-input-number.entry.cjs.js.map +1 -1
  93. package/dist/cjs/kol-input-password.cjs.entry.js +1 -1
  94. package/dist/cjs/kol-input-password.entry.cjs.js.map +1 -1
  95. package/dist/cjs/kol-input-radio.cjs.entry.js +1 -1
  96. package/dist/cjs/kol-input-radio.entry.cjs.js.map +1 -1
  97. package/dist/cjs/kol-input-range.cjs.entry.js +1 -1
  98. package/dist/cjs/kol-input-range.entry.cjs.js.map +1 -1
  99. package/dist/cjs/kol-input-text.cjs.entry.js +1 -1
  100. package/dist/cjs/kol-input-text.entry.cjs.js.map +1 -1
  101. package/dist/cjs/kol-kolibri.cjs.entry.js +1 -1
  102. package/dist/cjs/kol-link-button.cjs.entry.js +1 -1
  103. package/dist/cjs/kol-link-button.entry.cjs.js.map +1 -1
  104. package/dist/cjs/kol-link-wc.cjs.entry.js +1 -1
  105. package/dist/cjs/kol-link-wc.entry.cjs.js.map +1 -1
  106. package/dist/cjs/kol-link.cjs.entry.js +1 -1
  107. package/dist/cjs/kol-link.entry.cjs.js.map +1 -1
  108. package/dist/cjs/kol-modal.cjs.entry.js +1 -1
  109. package/dist/cjs/kol-modal.entry.cjs.js.map +1 -1
  110. package/dist/cjs/kol-nav.cjs.entry.js +1 -1
  111. package/dist/cjs/kol-nav.entry.cjs.js.map +1 -1
  112. package/dist/cjs/kol-pagination-wc.cjs.entry.js +1 -1
  113. package/dist/cjs/kol-pagination.cjs.entry.js +1 -1
  114. package/dist/cjs/kol-pagination.entry.cjs.js.map +1 -1
  115. package/dist/cjs/kol-popover-button-wc.cjs.entry.js +1 -1
  116. package/dist/cjs/kol-popover-button-wc.entry.cjs.js.map +1 -1
  117. package/dist/cjs/kol-popover-button.cjs.entry.js +1 -1
  118. package/dist/cjs/kol-popover-button.entry.cjs.js.map +1 -1
  119. package/dist/cjs/kol-popover-wc.cjs.entry.js +1 -1
  120. package/dist/cjs/kol-progress.cjs.entry.js +1 -1
  121. package/dist/cjs/kol-quote.cjs.entry.js +1 -1
  122. package/dist/cjs/kol-select.cjs.entry.js +1 -1
  123. package/dist/cjs/kol-select.entry.cjs.js.map +1 -1
  124. package/dist/cjs/kol-single-select.cjs.entry.js +1 -1
  125. package/dist/cjs/kol-single-select.entry.cjs.js.map +1 -1
  126. package/dist/cjs/kol-skip-nav.cjs.entry.js +1 -1
  127. package/dist/cjs/kol-spin.cjs.entry.js +1 -1
  128. package/dist/cjs/kol-split-button.cjs.entry.js +1 -1
  129. package/dist/cjs/kol-split-button.entry.cjs.js.map +1 -1
  130. package/dist/cjs/kol-table-settings-wc.cjs.entry.js +1 -1
  131. package/dist/cjs/kol-table-stateful.cjs.entry.js +1 -1
  132. package/dist/cjs/kol-table-stateful.entry.cjs.js.map +1 -1
  133. package/dist/cjs/kol-table-stateless-wc.cjs.entry.js +1 -1
  134. package/dist/cjs/kol-table-stateless.cjs.entry.js +1 -1
  135. package/dist/cjs/kol-table-stateless.entry.cjs.js.map +1 -1
  136. package/dist/cjs/kol-tabs.cjs.entry.js +1 -1
  137. package/dist/cjs/kol-tabs.entry.cjs.js.map +1 -1
  138. package/dist/cjs/kol-textarea.cjs.entry.js +1 -1
  139. package/dist/cjs/kol-textarea.entry.cjs.js.map +1 -1
  140. package/dist/cjs/kol-toast-container.cjs.entry.js +1 -1
  141. package/dist/cjs/kol-toast-container.entry.cjs.js.map +1 -1
  142. package/dist/cjs/kol-toolbar.cjs.entry.js +1 -1
  143. package/dist/cjs/kol-toolbar.entry.cjs.js.map +1 -1
  144. package/dist/cjs/kol-tooltip-wc.cjs.entry.js +1 -1
  145. package/dist/cjs/kol-tooltip-wc.entry.cjs.js.map +1 -1
  146. package/dist/cjs/kol-tree-item-wc.cjs.entry.js +1 -1
  147. package/dist/cjs/kol-tree-item.cjs.entry.js +1 -1
  148. package/dist/cjs/kol-tree-wc.cjs.entry.js +1 -1
  149. package/dist/cjs/kol-tree.cjs.entry.js +1 -1
  150. package/dist/cjs/kol-version.cjs.entry.js +1 -1
  151. package/dist/cjs/kolibri.cjs.js +1 -1
  152. package/dist/cjs/kolibri.cjs.js.map +1 -1
  153. package/dist/cjs/label-Nicf9N_T.js.map +1 -1
  154. package/dist/cjs/loader.cjs.js +1 -1
  155. package/dist/cjs/max-length-behavior-Bvbwhaxv.js.map +1 -1
  156. package/dist/cjs/test-component.cjs.entry.js +1 -1
  157. package/dist/components/Alert.js.map +1 -1
  158. package/dist/components/Collapsible.js.map +1 -1
  159. package/dist/components/CustomSuggestionsToggle.js.map +1 -1
  160. package/dist/components/FieldControlStateWrapper.js +1 -1
  161. package/dist/components/FieldControlStateWrapper.js.map +1 -1
  162. package/dist/components/Heading.js.map +1 -1
  163. package/dist/components/Input.js +1 -1
  164. package/dist/components/Input.js.map +1 -1
  165. package/dist/components/InputStateWrapper.js +1 -1
  166. package/dist/components/InputStateWrapper.js.map +1 -1
  167. package/dist/components/InternalUnderlinedBadgeText.js.map +1 -1
  168. package/dist/components/Span.js.map +1 -1
  169. package/dist/components/access-and-short-key.js.map +1 -1
  170. package/dist/components/align-floating-elements.js.map +1 -1
  171. package/dist/components/associated.controller.js.map +1 -1
  172. package/dist/components/bootstrap.js.map +1 -1
  173. package/dist/components/color.js.map +1 -1
  174. package/dist/components/common.js.map +1 -1
  175. package/dist/components/controller-icon.js +1 -1
  176. package/dist/components/controller-icon.js.map +1 -1
  177. package/dist/components/controller.js.map +1 -1
  178. package/dist/components/controller2.js +1 -1
  179. package/dist/components/controller2.js.map +1 -1
  180. package/dist/components/controller3.js.map +1 -1
  181. package/dist/components/controller4.js.map +1 -1
  182. package/dist/components/controller5.js.map +1 -1
  183. package/dist/components/i18n2.js.map +1 -1
  184. package/dist/components/icons.js.map +1 -1
  185. package/dist/components/index.js.map +1 -1
  186. package/dist/components/keyboard.js.map +1 -1
  187. package/dist/components/kol-abbr.js +1 -1
  188. package/dist/components/kol-abbr.js.map +1 -1
  189. package/dist/components/kol-accordion.js +1 -1
  190. package/dist/components/kol-accordion.js.map +1 -1
  191. package/dist/components/kol-alert-wc.js +1 -1
  192. package/dist/components/kol-alert-wc.js.map +1 -1
  193. package/dist/components/kol-alert.js +1 -1
  194. package/dist/components/kol-alert.js.map +1 -1
  195. package/dist/components/kol-avatar-wc.js +1 -1
  196. package/dist/components/kol-avatar-wc.js.map +1 -1
  197. package/dist/components/kol-avatar.js +1 -1
  198. package/dist/components/kol-avatar.js.map +1 -1
  199. package/dist/components/kol-badge.js +1 -1
  200. package/dist/components/kol-badge.js.map +1 -1
  201. package/dist/components/kol-breadcrumb.js +1 -1
  202. package/dist/components/kol-breadcrumb.js.map +1 -1
  203. package/dist/components/kol-button-link.js +1 -1
  204. package/dist/components/kol-button-link.js.map +1 -1
  205. package/dist/components/kol-button-wc.js +1 -1
  206. package/dist/components/kol-button-wc.js.map +1 -1
  207. package/dist/components/kol-button.js +1 -1
  208. package/dist/components/kol-button.js.map +1 -1
  209. package/dist/components/kol-card-wc.js +1 -1
  210. package/dist/components/kol-card-wc.js.map +1 -1
  211. package/dist/components/kol-card.js +1 -1
  212. package/dist/components/kol-card.js.map +1 -1
  213. package/dist/components/kol-combobox.js +1 -1
  214. package/dist/components/kol-combobox.js.map +1 -1
  215. package/dist/components/kol-details.js +1 -1
  216. package/dist/components/kol-details.js.map +1 -1
  217. package/dist/components/kol-drawer.js +1 -1
  218. package/dist/components/kol-drawer.js.map +1 -1
  219. package/dist/components/kol-form.js +1 -1
  220. package/dist/components/kol-form.js.map +1 -1
  221. package/dist/components/kol-heading.js +1 -1
  222. package/dist/components/kol-heading.js.map +1 -1
  223. package/dist/components/kol-icon.js +1 -1
  224. package/dist/components/kol-icon.js.map +1 -1
  225. package/dist/components/kol-image.js +1 -1
  226. package/dist/components/kol-image.js.map +1 -1
  227. package/dist/components/kol-input-checkbox.js +1 -1
  228. package/dist/components/kol-input-checkbox.js.map +1 -1
  229. package/dist/components/kol-input-color.js +1 -1
  230. package/dist/components/kol-input-color.js.map +1 -1
  231. package/dist/components/kol-input-date.js +1 -1
  232. package/dist/components/kol-input-date.js.map +1 -1
  233. package/dist/components/kol-input-email.js +1 -1
  234. package/dist/components/kol-input-email.js.map +1 -1
  235. package/dist/components/kol-input-file.js +1 -1
  236. package/dist/components/kol-input-file.js.map +1 -1
  237. package/dist/components/kol-input-number.js +1 -1
  238. package/dist/components/kol-input-number.js.map +1 -1
  239. package/dist/components/kol-input-password.js +1 -1
  240. package/dist/components/kol-input-password.js.map +1 -1
  241. package/dist/components/kol-input-radio.js +1 -1
  242. package/dist/components/kol-input-radio.js.map +1 -1
  243. package/dist/components/kol-input-range.js +1 -1
  244. package/dist/components/kol-input-range.js.map +1 -1
  245. package/dist/components/kol-input-text.js +1 -1
  246. package/dist/components/kol-input-text.js.map +1 -1
  247. package/dist/components/kol-kolibri.js +1 -1
  248. package/dist/components/kol-kolibri.js.map +1 -1
  249. package/dist/components/kol-link-button.js +1 -1
  250. package/dist/components/kol-link-button.js.map +1 -1
  251. package/dist/components/kol-link-wc.js +1 -1
  252. package/dist/components/kol-link-wc.js.map +1 -1
  253. package/dist/components/kol-link.js +1 -1
  254. package/dist/components/kol-link.js.map +1 -1
  255. package/dist/components/kol-modal.js +1 -1
  256. package/dist/components/kol-modal.js.map +1 -1
  257. package/dist/components/kol-nav.js +1 -1
  258. package/dist/components/kol-nav.js.map +1 -1
  259. package/dist/components/kol-pagination-wc.js +1 -1
  260. package/dist/components/kol-pagination-wc.js.map +1 -1
  261. package/dist/components/kol-pagination.js +1 -1
  262. package/dist/components/kol-pagination.js.map +1 -1
  263. package/dist/components/kol-popover-button-wc.js +1 -1
  264. package/dist/components/kol-popover-button-wc.js.map +1 -1
  265. package/dist/components/kol-popover-button.js +1 -1
  266. package/dist/components/kol-popover-button.js.map +1 -1
  267. package/dist/components/kol-popover-wc.js +1 -1
  268. package/dist/components/kol-popover-wc.js.map +1 -1
  269. package/dist/components/kol-progress.js +1 -1
  270. package/dist/components/kol-progress.js.map +1 -1
  271. package/dist/components/kol-quote.js +1 -1
  272. package/dist/components/kol-quote.js.map +1 -1
  273. package/dist/components/kol-select.js +1 -1
  274. package/dist/components/kol-select.js.map +1 -1
  275. package/dist/components/kol-single-select.js +1 -1
  276. package/dist/components/kol-single-select.js.map +1 -1
  277. package/dist/components/kol-skip-nav.js +1 -1
  278. package/dist/components/kol-skip-nav.js.map +1 -1
  279. package/dist/components/kol-spin.js +1 -1
  280. package/dist/components/kol-spin.js.map +1 -1
  281. package/dist/components/kol-split-button.js +1 -1
  282. package/dist/components/kol-split-button.js.map +1 -1
  283. package/dist/components/kol-table-settings-wc.js +1 -1
  284. package/dist/components/kol-table-settings-wc.js.map +1 -1
  285. package/dist/components/kol-table-stateful.js +1 -1
  286. package/dist/components/kol-table-stateful.js.map +1 -1
  287. package/dist/components/kol-table-stateless-wc.js +1 -1
  288. package/dist/components/kol-table-stateless-wc.js.map +1 -1
  289. package/dist/components/kol-table-stateless.js +1 -1
  290. package/dist/components/kol-table-stateless.js.map +1 -1
  291. package/dist/components/kol-tabs.js +1 -1
  292. package/dist/components/kol-tabs.js.map +1 -1
  293. package/dist/components/kol-textarea.js +1 -1
  294. package/dist/components/kol-textarea.js.map +1 -1
  295. package/dist/components/kol-toast-container.js +1 -1
  296. package/dist/components/kol-toast-container.js.map +1 -1
  297. package/dist/components/kol-toolbar.js +1 -1
  298. package/dist/components/kol-toolbar.js.map +1 -1
  299. package/dist/components/kol-tooltip-wc.js +1 -1
  300. package/dist/components/kol-tooltip-wc.js.map +1 -1
  301. package/dist/components/kol-tree-item-wc.js +1 -1
  302. package/dist/components/kol-tree-item-wc.js.map +1 -1
  303. package/dist/components/kol-tree-item.js +1 -1
  304. package/dist/components/kol-tree-item.js.map +1 -1
  305. package/dist/components/kol-tree-wc.js +1 -1
  306. package/dist/components/kol-tree-wc.js.map +1 -1
  307. package/dist/components/kol-tree.js +1 -1
  308. package/dist/components/kol-tree.js.map +1 -1
  309. package/dist/components/kol-version.js +1 -1
  310. package/dist/components/kol-version.js.map +1 -1
  311. package/dist/components/label.js.map +1 -1
  312. package/dist/components/max-length-behavior.js.map +1 -1
  313. package/dist/esm/{Alert-DSfF5oYO.js → Alert-qbdf_fcL.js} +1 -1
  314. package/dist/esm/{Alert-DSfF5oYO.js.map → Alert-qbdf_fcL.js.map} +1 -1
  315. package/dist/esm/{Collapsible-8yntsjFt.js → Collapsible-CIrvKN_B.js} +1 -1
  316. package/dist/esm/{Collapsible-8yntsjFt.js.map → Collapsible-CIrvKN_B.js.map} +1 -1
  317. package/dist/esm/{CustomSuggestionsToggle-C8IuvN89.js → CustomSuggestionsToggle-DElswCqH.js} +1 -1
  318. package/dist/{kolibri/CustomSuggestionsToggle-C8IuvN89.js.map → esm/CustomSuggestionsToggle-DElswCqH.js.map} +1 -1
  319. package/dist/esm/FieldControlStateWrapper-CHywsLUV.js +4 -0
  320. package/dist/esm/FieldControlStateWrapper-CHywsLUV.js.map +1 -0
  321. package/dist/esm/FormFieldStateWrapper-CmxXneQY.js +4 -0
  322. package/dist/esm/FormFieldStateWrapper-CmxXneQY.js.map +1 -0
  323. package/dist/esm/{Heading-CfdCVyC3.js → Heading-CKpEiZDI.js} +1 -1
  324. package/dist/{kolibri/Heading-CfdCVyC3.js.map → esm/Heading-CKpEiZDI.js.map} +1 -1
  325. package/dist/esm/Icon-CPnthaTn.js +4 -0
  326. package/dist/esm/{Icon-Bsf76uHm.js.map → Icon-CPnthaTn.js.map} +1 -1
  327. package/dist/esm/Input-BHMhOXxm.js +4 -0
  328. package/dist/esm/Input-BHMhOXxm.js.map +1 -0
  329. package/dist/esm/InputStateWrapper-CqJvkzZt.js +4 -0
  330. package/dist/esm/InputStateWrapper-CqJvkzZt.js.map +1 -0
  331. package/dist/esm/InternalUnderlinedBadgeText-DOCFbPLy.js +4 -0
  332. package/dist/esm/{InternalUnderlinedBadgeText-EK327PqL.js.map → InternalUnderlinedBadgeText-DOCFbPLy.js.map} +1 -1
  333. package/dist/esm/{Span-CabLpAXO.js → Span-BZB_bkKp.js} +1 -1
  334. package/dist/{kolibri/Span-CabLpAXO.js.map → esm/Span-BZB_bkKp.js.map} +1 -1
  335. package/dist/esm/access-and-short-key-bcID78Ha.js.map +1 -1
  336. package/dist/esm/align-floating-elements-Bx4ukVlr.js.map +1 -1
  337. package/dist/esm/{app-globals-CtV70nwT.js → app-globals-Bd-b6ifP.js} +1 -1
  338. package/dist/esm/{app-globals-CtV70nwT.js.map → app-globals-Bd-b6ifP.js.map} +1 -1
  339. package/dist/esm/associated.controller-BKIODHIT.js.map +1 -1
  340. package/dist/esm/bootstrap-BiRnv4fV.js.map +1 -1
  341. package/dist/esm/color-C3pYZKV3.js.map +1 -1
  342. package/dist/esm/common-8fBdMvJM.js.map +1 -1
  343. package/dist/esm/{controller-CjDina_l.js → controller-BORRr_3T.js} +1 -1
  344. package/dist/esm/{controller-CjDina_l.js.map → controller-BORRr_3T.js.map} +1 -1
  345. package/dist/esm/{controller-BOrHVaYB.js → controller-CBTEbm6r.js} +1 -1
  346. package/dist/esm/{controller-BOrHVaYB.js.map → controller-CBTEbm6r.js.map} +1 -1
  347. package/dist/esm/controller-CV2y9Ae_.js.map +1 -1
  348. package/dist/esm/{controller-qa9_sr4y.js → controller-Cb9l3YaE.js} +1 -1
  349. package/dist/{kolibri/controller-qa9_sr4y.js.map → esm/controller-Cb9l3YaE.js.map} +1 -1
  350. package/dist/esm/controller-icon-CvKGJIGZ.js +4 -0
  351. package/dist/esm/controller-icon-CvKGJIGZ.js.map +1 -0
  352. package/dist/esm/{dev.utils-DbZWp4Qf.js → dev.utils-D4rfC2RQ.js} +1 -1
  353. package/dist/{kolibri/dev.utils-DbZWp4Qf.js.map → esm/dev.utils-D4rfC2RQ.js.map} +1 -1
  354. package/dist/esm/{devtools-BsF06iJC.js → devtools-DosNZdSl.js} +1 -1
  355. package/dist/esm/{devtools-BsF06iJC.js.map → devtools-DosNZdSl.js.map} +1 -1
  356. package/dist/esm/i18n-ZF6JbdVP.js.map +1 -1
  357. package/dist/esm/icons-72ER78AW.js.map +1 -1
  358. package/dist/esm/index-D7gsjUuJ.js +4 -0
  359. package/dist/esm/index-D7gsjUuJ.js.map +1 -0
  360. package/dist/esm/index.js.map +1 -1
  361. package/dist/esm/keyboard-D6PoWr38.js.map +1 -1
  362. package/dist/esm/kol-abbr.entry.js +1 -1
  363. package/dist/esm/kol-abbr.entry.js.map +1 -1
  364. package/dist/esm/kol-accordion.entry.js +1 -1
  365. package/dist/esm/kol-alert-wc.entry.js +1 -1
  366. package/dist/esm/kol-alert.entry.js +1 -1
  367. package/dist/esm/kol-alert.entry.js.map +1 -1
  368. package/dist/esm/kol-avatar-wc.entry.js +1 -1
  369. package/dist/esm/kol-avatar.entry.js +1 -1
  370. package/dist/esm/kol-badge.entry.js +1 -1
  371. package/dist/esm/kol-badge.entry.js.map +1 -1
  372. package/dist/esm/kol-breadcrumb.entry.js +1 -1
  373. package/dist/esm/kol-breadcrumb.entry.js.map +1 -1
  374. package/dist/esm/kol-button-link.entry.js +1 -1
  375. package/dist/esm/kol-button-link.entry.js.map +1 -1
  376. package/dist/esm/kol-button-wc.entry.js +1 -1
  377. package/dist/esm/kol-button-wc.entry.js.map +1 -1
  378. package/dist/esm/kol-button.entry.js +1 -1
  379. package/dist/esm/kol-button.entry.js.map +1 -1
  380. package/dist/esm/kol-card-wc.entry.js +1 -1
  381. package/dist/esm/kol-card.entry.js +1 -1
  382. package/dist/esm/kol-card.entry.js.map +1 -1
  383. package/dist/esm/kol-combobox.entry.js +1 -1
  384. package/dist/esm/kol-combobox.entry.js.map +1 -1
  385. package/dist/esm/kol-details.entry.js +1 -1
  386. package/dist/esm/kol-drawer.entry.js +1 -1
  387. package/dist/esm/kol-drawer.entry.js.map +1 -1
  388. package/dist/esm/kol-form.entry.js +1 -1
  389. package/dist/esm/kol-form.entry.js.map +1 -1
  390. package/dist/esm/kol-heading.entry.js +1 -1
  391. package/dist/esm/kol-icon.entry.js +1 -1
  392. package/dist/esm/kol-image.entry.js +1 -1
  393. package/dist/esm/kol-input-checkbox.entry.js +1 -1
  394. package/dist/esm/kol-input-checkbox.entry.js.map +1 -1
  395. package/dist/esm/kol-input-color.entry.js +1 -1
  396. package/dist/esm/kol-input-color.entry.js.map +1 -1
  397. package/dist/esm/kol-input-date.entry.js +1 -1
  398. package/dist/esm/kol-input-date.entry.js.map +1 -1
  399. package/dist/esm/kol-input-email.entry.js +1 -1
  400. package/dist/esm/kol-input-email.entry.js.map +1 -1
  401. package/dist/esm/kol-input-file.entry.js +1 -1
  402. package/dist/esm/kol-input-file.entry.js.map +1 -1
  403. package/dist/esm/kol-input-number.entry.js +1 -1
  404. package/dist/esm/kol-input-number.entry.js.map +1 -1
  405. package/dist/esm/kol-input-password.entry.js +1 -1
  406. package/dist/esm/kol-input-password.entry.js.map +1 -1
  407. package/dist/esm/kol-input-radio.entry.js +1 -1
  408. package/dist/esm/kol-input-radio.entry.js.map +1 -1
  409. package/dist/esm/kol-input-range.entry.js +1 -1
  410. package/dist/esm/kol-input-range.entry.js.map +1 -1
  411. package/dist/esm/kol-input-text.entry.js +1 -1
  412. package/dist/esm/kol-input-text.entry.js.map +1 -1
  413. package/dist/esm/kol-kolibri.entry.js +1 -1
  414. package/dist/esm/kol-link-button.entry.js +1 -1
  415. package/dist/esm/kol-link-button.entry.js.map +1 -1
  416. package/dist/esm/kol-link-wc.entry.js +1 -1
  417. package/dist/esm/kol-link-wc.entry.js.map +1 -1
  418. package/dist/esm/kol-link.entry.js +1 -1
  419. package/dist/esm/kol-link.entry.js.map +1 -1
  420. package/dist/esm/kol-modal.entry.js +1 -1
  421. package/dist/esm/kol-modal.entry.js.map +1 -1
  422. package/dist/esm/kol-nav.entry.js +1 -1
  423. package/dist/esm/kol-nav.entry.js.map +1 -1
  424. package/dist/esm/kol-pagination-wc.entry.js +1 -1
  425. package/dist/esm/kol-pagination.entry.js +1 -1
  426. package/dist/esm/kol-pagination.entry.js.map +1 -1
  427. package/dist/esm/kol-popover-button-wc.entry.js +1 -1
  428. package/dist/esm/kol-popover-button-wc.entry.js.map +1 -1
  429. package/dist/esm/kol-popover-button.entry.js +1 -1
  430. package/dist/esm/kol-popover-button.entry.js.map +1 -1
  431. package/dist/esm/kol-popover-wc.entry.js +1 -1
  432. package/dist/esm/kol-progress.entry.js +1 -1
  433. package/dist/esm/kol-quote.entry.js +1 -1
  434. package/dist/esm/kol-select.entry.js +1 -1
  435. package/dist/esm/kol-select.entry.js.map +1 -1
  436. package/dist/esm/kol-single-select.entry.js +1 -1
  437. package/dist/esm/kol-single-select.entry.js.map +1 -1
  438. package/dist/esm/kol-skip-nav.entry.js +1 -1
  439. package/dist/esm/kol-spin.entry.js +1 -1
  440. package/dist/esm/kol-split-button.entry.js +1 -1
  441. package/dist/esm/kol-split-button.entry.js.map +1 -1
  442. package/dist/esm/kol-table-settings-wc.entry.js +1 -1
  443. package/dist/esm/kol-table-stateful.entry.js +1 -1
  444. package/dist/esm/kol-table-stateful.entry.js.map +1 -1
  445. package/dist/esm/kol-table-stateless-wc.entry.js +1 -1
  446. package/dist/esm/kol-table-stateless.entry.js +1 -1
  447. package/dist/esm/kol-table-stateless.entry.js.map +1 -1
  448. package/dist/esm/kol-tabs.entry.js +1 -1
  449. package/dist/esm/kol-tabs.entry.js.map +1 -1
  450. package/dist/esm/kol-textarea.entry.js +1 -1
  451. package/dist/esm/kol-textarea.entry.js.map +1 -1
  452. package/dist/esm/kol-toast-container.entry.js +1 -1
  453. package/dist/esm/kol-toast-container.entry.js.map +1 -1
  454. package/dist/esm/kol-toolbar.entry.js +1 -1
  455. package/dist/esm/kol-toolbar.entry.js.map +1 -1
  456. package/dist/esm/kol-tooltip-wc.entry.js +1 -1
  457. package/dist/esm/kol-tooltip-wc.entry.js.map +1 -1
  458. package/dist/esm/kol-tree-item-wc.entry.js +1 -1
  459. package/dist/esm/kol-tree-item.entry.js +1 -1
  460. package/dist/esm/kol-tree-wc.entry.js +1 -1
  461. package/dist/esm/kol-tree.entry.js +1 -1
  462. package/dist/esm/kol-version.entry.js +1 -1
  463. package/dist/esm/kolibri.js +1 -1
  464. package/dist/esm/kolibri.js.map +1 -1
  465. package/dist/esm/label-CdtNxOKu.js.map +1 -1
  466. package/dist/esm/loader.js +1 -1
  467. package/dist/esm/max-length-behavior-BmNWss6T.js.map +1 -1
  468. package/dist/esm/test-component.entry.js +1 -1
  469. package/dist/kolibri/Alert-qbdf_fcL.js +4 -0
  470. package/dist/kolibri/{Alert-DSfF5oYO.js.map → Alert-qbdf_fcL.js.map} +1 -1
  471. package/dist/kolibri/Collapsible-CIrvKN_B.js +4 -0
  472. package/dist/kolibri/{Collapsible-8yntsjFt.js.map → Collapsible-CIrvKN_B.js.map} +1 -1
  473. package/dist/kolibri/{CustomSuggestionsToggle-C8IuvN89.js → CustomSuggestionsToggle-DElswCqH.js} +1 -1
  474. package/dist/{esm/CustomSuggestionsToggle-C8IuvN89.js.map → kolibri/CustomSuggestionsToggle-DElswCqH.js.map} +1 -1
  475. package/dist/kolibri/FieldControlStateWrapper-CHywsLUV.js +4 -0
  476. package/dist/kolibri/FieldControlStateWrapper-CHywsLUV.js.map +1 -0
  477. package/dist/kolibri/FormFieldStateWrapper-CmxXneQY.js +4 -0
  478. package/dist/kolibri/FormFieldStateWrapper-CmxXneQY.js.map +1 -0
  479. package/dist/kolibri/{Heading-CfdCVyC3.js → Heading-CKpEiZDI.js} +1 -1
  480. package/dist/{esm/Heading-CfdCVyC3.js.map → kolibri/Heading-CKpEiZDI.js.map} +1 -1
  481. package/dist/kolibri/{Icon-Bsf76uHm.js → Icon-CPnthaTn.js} +1 -1
  482. package/dist/kolibri/{Icon-Bsf76uHm.js.map → Icon-CPnthaTn.js.map} +1 -1
  483. package/dist/kolibri/Input-BHMhOXxm.js +4 -0
  484. package/dist/kolibri/Input-BHMhOXxm.js.map +1 -0
  485. package/dist/kolibri/InputStateWrapper-CqJvkzZt.js +4 -0
  486. package/dist/kolibri/InputStateWrapper-CqJvkzZt.js.map +1 -0
  487. package/dist/kolibri/InternalUnderlinedBadgeText-DOCFbPLy.js +4 -0
  488. package/dist/kolibri/{InternalUnderlinedBadgeText-EK327PqL.js.map → InternalUnderlinedBadgeText-DOCFbPLy.js.map} +1 -1
  489. package/dist/kolibri/Span-BZB_bkKp.js +4 -0
  490. package/dist/{esm/Span-CabLpAXO.js.map → kolibri/Span-BZB_bkKp.js.map} +1 -1
  491. package/dist/kolibri/access-and-short-key-bcID78Ha.js.map +1 -1
  492. package/dist/kolibri/align-floating-elements-Bx4ukVlr.js.map +1 -1
  493. package/dist/kolibri/{app-globals-CtV70nwT.js → app-globals-Bd-b6ifP.js} +1 -1
  494. package/dist/kolibri/{app-globals-CtV70nwT.js.map → app-globals-Bd-b6ifP.js.map} +1 -1
  495. package/dist/kolibri/associated.controller-BKIODHIT.js.map +1 -1
  496. package/dist/kolibri/bootstrap-BiRnv4fV.js.map +1 -1
  497. package/dist/kolibri/color-C3pYZKV3.js.map +1 -1
  498. package/dist/kolibri/common-8fBdMvJM.js.map +1 -1
  499. package/dist/kolibri/controller-BORRr_3T.js +4 -0
  500. package/dist/kolibri/{controller-CjDina_l.js.map → controller-BORRr_3T.js.map} +1 -1
  501. package/dist/kolibri/{controller-BOrHVaYB.js → controller-CBTEbm6r.js} +1 -1
  502. package/dist/kolibri/{controller-BOrHVaYB.js.map → controller-CBTEbm6r.js.map} +1 -1
  503. package/dist/kolibri/controller-CV2y9Ae_.js.map +1 -1
  504. package/dist/kolibri/{controller-qa9_sr4y.js → controller-Cb9l3YaE.js} +1 -1
  505. package/dist/{esm/controller-qa9_sr4y.js.map → kolibri/controller-Cb9l3YaE.js.map} +1 -1
  506. package/dist/kolibri/controller-icon-CvKGJIGZ.js +4 -0
  507. package/dist/kolibri/controller-icon-CvKGJIGZ.js.map +1 -0
  508. package/dist/kolibri/{dev.utils-DbZWp4Qf.js → dev.utils-D4rfC2RQ.js} +1 -1
  509. package/dist/{esm/dev.utils-DbZWp4Qf.js.map → kolibri/dev.utils-D4rfC2RQ.js.map} +1 -1
  510. package/dist/kolibri/{devtools-BsF06iJC.js → devtools-DosNZdSl.js} +1 -1
  511. package/dist/kolibri/{devtools-BsF06iJC.js.map → devtools-DosNZdSl.js.map} +1 -1
  512. package/dist/kolibri/i18n-ZF6JbdVP.js.map +1 -1
  513. package/dist/kolibri/icons-72ER78AW.js.map +1 -1
  514. package/dist/kolibri/{index-DwzuLp_u.js → index-D7gsjUuJ.js} +2 -2
  515. package/dist/kolibri/index-D7gsjUuJ.js.map +1 -0
  516. package/dist/kolibri/index.esm.js.map +1 -1
  517. package/dist/kolibri/keyboard-D6PoWr38.js.map +1 -1
  518. package/dist/kolibri/kol-abbr.entry.esm.js.map +1 -1
  519. package/dist/kolibri/kol-abbr.entry.js +1 -1
  520. package/dist/kolibri/kol-abbr.entry.js.map +1 -1
  521. package/dist/kolibri/kol-accordion.entry.js +1 -1
  522. package/dist/kolibri/kol-accordion.entry.js.map +1 -1
  523. package/dist/kolibri/kol-alert-wc.entry.js +1 -1
  524. package/dist/kolibri/kol-alert-wc.entry.js.map +1 -1
  525. package/dist/kolibri/kol-alert.entry.esm.js.map +1 -1
  526. package/dist/kolibri/kol-alert.entry.js +1 -1
  527. package/dist/kolibri/kol-alert.entry.js.map +1 -1
  528. package/dist/kolibri/kol-avatar-wc.entry.js +1 -1
  529. package/dist/kolibri/kol-avatar-wc.entry.js.map +1 -1
  530. package/dist/kolibri/kol-avatar.entry.js +1 -1
  531. package/dist/kolibri/kol-avatar.entry.js.map +1 -1
  532. package/dist/kolibri/kol-badge.entry.esm.js.map +1 -1
  533. package/dist/kolibri/kol-badge.entry.js +1 -1
  534. package/dist/kolibri/kol-badge.entry.js.map +1 -1
  535. package/dist/kolibri/kol-breadcrumb.entry.esm.js.map +1 -1
  536. package/dist/kolibri/kol-breadcrumb.entry.js +1 -1
  537. package/dist/kolibri/kol-breadcrumb.entry.js.map +1 -1
  538. package/dist/kolibri/kol-button-link.entry.esm.js.map +1 -1
  539. package/dist/kolibri/kol-button-link.entry.js +1 -1
  540. package/dist/kolibri/kol-button-link.entry.js.map +1 -1
  541. package/dist/kolibri/kol-button-wc.entry.esm.js.map +1 -1
  542. package/dist/kolibri/kol-button-wc.entry.js +1 -1
  543. package/dist/kolibri/kol-button-wc.entry.js.map +1 -1
  544. package/dist/kolibri/kol-button.entry.esm.js.map +1 -1
  545. package/dist/kolibri/kol-button.entry.js +1 -1
  546. package/dist/kolibri/kol-button.entry.js.map +1 -1
  547. package/dist/kolibri/kol-card-wc.entry.js +1 -1
  548. package/dist/kolibri/kol-card-wc.entry.js.map +1 -1
  549. package/dist/kolibri/kol-card.entry.esm.js.map +1 -1
  550. package/dist/kolibri/kol-card.entry.js +1 -1
  551. package/dist/kolibri/kol-card.entry.js.map +1 -1
  552. package/dist/kolibri/kol-combobox.entry.esm.js.map +1 -1
  553. package/dist/kolibri/kol-combobox.entry.js +1 -1
  554. package/dist/kolibri/kol-combobox.entry.js.map +1 -1
  555. package/dist/kolibri/kol-details.entry.js +1 -1
  556. package/dist/kolibri/kol-details.entry.js.map +1 -1
  557. package/dist/kolibri/kol-drawer.entry.esm.js.map +1 -1
  558. package/dist/kolibri/kol-drawer.entry.js +1 -1
  559. package/dist/kolibri/kol-drawer.entry.js.map +1 -1
  560. package/dist/kolibri/kol-form.entry.esm.js.map +1 -1
  561. package/dist/kolibri/kol-form.entry.js +1 -1
  562. package/dist/kolibri/kol-form.entry.js.map +1 -1
  563. package/dist/kolibri/kol-heading.entry.js +1 -1
  564. package/dist/kolibri/kol-heading.entry.js.map +1 -1
  565. package/dist/kolibri/kol-icon.entry.js +1 -1
  566. package/dist/kolibri/kol-icon.entry.js.map +1 -1
  567. package/dist/kolibri/kol-image.entry.js +1 -1
  568. package/dist/kolibri/kol-image.entry.js.map +1 -1
  569. package/dist/kolibri/kol-input-checkbox.entry.esm.js.map +1 -1
  570. package/dist/kolibri/kol-input-checkbox.entry.js +1 -1
  571. package/dist/kolibri/kol-input-checkbox.entry.js.map +1 -1
  572. package/dist/kolibri/kol-input-color.entry.esm.js.map +1 -1
  573. package/dist/kolibri/kol-input-color.entry.js +1 -1
  574. package/dist/kolibri/kol-input-color.entry.js.map +1 -1
  575. package/dist/kolibri/kol-input-date.entry.esm.js.map +1 -1
  576. package/dist/kolibri/kol-input-date.entry.js +1 -1
  577. package/dist/kolibri/kol-input-date.entry.js.map +1 -1
  578. package/dist/kolibri/kol-input-email.entry.esm.js.map +1 -1
  579. package/dist/kolibri/kol-input-email.entry.js +1 -1
  580. package/dist/kolibri/kol-input-email.entry.js.map +1 -1
  581. package/dist/kolibri/kol-input-file.entry.esm.js.map +1 -1
  582. package/dist/kolibri/kol-input-file.entry.js +1 -1
  583. package/dist/kolibri/kol-input-file.entry.js.map +1 -1
  584. package/dist/kolibri/kol-input-number.entry.esm.js.map +1 -1
  585. package/dist/kolibri/kol-input-number.entry.js +1 -1
  586. package/dist/kolibri/kol-input-number.entry.js.map +1 -1
  587. package/dist/kolibri/kol-input-password.entry.esm.js.map +1 -1
  588. package/dist/kolibri/kol-input-password.entry.js +1 -1
  589. package/dist/kolibri/kol-input-password.entry.js.map +1 -1
  590. package/dist/kolibri/kol-input-radio.entry.esm.js.map +1 -1
  591. package/dist/kolibri/kol-input-radio.entry.js +1 -1
  592. package/dist/kolibri/kol-input-radio.entry.js.map +1 -1
  593. package/dist/kolibri/kol-input-range.entry.esm.js.map +1 -1
  594. package/dist/kolibri/kol-input-range.entry.js +1 -1
  595. package/dist/kolibri/kol-input-range.entry.js.map +1 -1
  596. package/dist/kolibri/kol-input-text.entry.esm.js.map +1 -1
  597. package/dist/kolibri/kol-input-text.entry.js +1 -1
  598. package/dist/kolibri/kol-input-text.entry.js.map +1 -1
  599. package/dist/kolibri/kol-kolibri.entry.js +1 -1
  600. package/dist/kolibri/kol-kolibri.entry.js.map +1 -1
  601. package/dist/kolibri/kol-link-button.entry.esm.js.map +1 -1
  602. package/dist/kolibri/kol-link-button.entry.js +1 -1
  603. package/dist/kolibri/kol-link-button.entry.js.map +1 -1
  604. package/dist/kolibri/kol-link-wc.entry.esm.js.map +1 -1
  605. package/dist/kolibri/kol-link-wc.entry.js +1 -1
  606. package/dist/kolibri/kol-link-wc.entry.js.map +1 -1
  607. package/dist/kolibri/kol-link.entry.esm.js.map +1 -1
  608. package/dist/kolibri/kol-link.entry.js +1 -1
  609. package/dist/kolibri/kol-link.entry.js.map +1 -1
  610. package/dist/kolibri/kol-modal.entry.esm.js.map +1 -1
  611. package/dist/kolibri/kol-modal.entry.js +1 -1
  612. package/dist/kolibri/kol-modal.entry.js.map +1 -1
  613. package/dist/kolibri/kol-nav.entry.esm.js.map +1 -1
  614. package/dist/kolibri/kol-nav.entry.js +1 -1
  615. package/dist/kolibri/kol-nav.entry.js.map +1 -1
  616. package/dist/kolibri/kol-pagination-wc.entry.js +1 -1
  617. package/dist/kolibri/kol-pagination-wc.entry.js.map +1 -1
  618. package/dist/kolibri/kol-pagination.entry.esm.js.map +1 -1
  619. package/dist/kolibri/kol-pagination.entry.js +1 -1
  620. package/dist/kolibri/kol-pagination.entry.js.map +1 -1
  621. package/dist/kolibri/kol-popover-button-wc.entry.esm.js.map +1 -1
  622. package/dist/kolibri/kol-popover-button-wc.entry.js +1 -1
  623. package/dist/kolibri/kol-popover-button-wc.entry.js.map +1 -1
  624. package/dist/kolibri/kol-popover-button.entry.esm.js.map +1 -1
  625. package/dist/kolibri/kol-popover-button.entry.js +1 -1
  626. package/dist/kolibri/kol-popover-button.entry.js.map +1 -1
  627. package/dist/kolibri/kol-popover-wc.entry.js +1 -1
  628. package/dist/kolibri/kol-popover-wc.entry.js.map +1 -1
  629. package/dist/kolibri/kol-progress.entry.js +1 -1
  630. package/dist/kolibri/kol-progress.entry.js.map +1 -1
  631. package/dist/kolibri/kol-quote.entry.js +1 -1
  632. package/dist/kolibri/kol-quote.entry.js.map +1 -1
  633. package/dist/kolibri/kol-select.entry.esm.js.map +1 -1
  634. package/dist/kolibri/kol-select.entry.js +1 -1
  635. package/dist/kolibri/kol-select.entry.js.map +1 -1
  636. package/dist/kolibri/kol-single-select.entry.esm.js.map +1 -1
  637. package/dist/kolibri/kol-single-select.entry.js +1 -1
  638. package/dist/kolibri/kol-single-select.entry.js.map +1 -1
  639. package/dist/kolibri/kol-skip-nav.entry.js +1 -1
  640. package/dist/kolibri/kol-skip-nav.entry.js.map +1 -1
  641. package/dist/kolibri/kol-spin.entry.js +1 -1
  642. package/dist/kolibri/kol-spin.entry.js.map +1 -1
  643. package/dist/kolibri/kol-split-button.entry.esm.js.map +1 -1
  644. package/dist/kolibri/kol-split-button.entry.js +1 -1
  645. package/dist/kolibri/kol-split-button.entry.js.map +1 -1
  646. package/dist/kolibri/kol-table-settings-wc.entry.js +1 -1
  647. package/dist/kolibri/kol-table-settings-wc.entry.js.map +1 -1
  648. package/dist/kolibri/kol-table-stateful.entry.esm.js.map +1 -1
  649. package/dist/kolibri/kol-table-stateful.entry.js +1 -1
  650. package/dist/kolibri/kol-table-stateful.entry.js.map +1 -1
  651. package/dist/kolibri/kol-table-stateless-wc.entry.js +1 -1
  652. package/dist/kolibri/kol-table-stateless-wc.entry.js.map +1 -1
  653. package/dist/kolibri/kol-table-stateless.entry.esm.js.map +1 -1
  654. package/dist/kolibri/kol-table-stateless.entry.js +1 -1
  655. package/dist/kolibri/kol-table-stateless.entry.js.map +1 -1
  656. package/dist/kolibri/kol-tabs.entry.esm.js.map +1 -1
  657. package/dist/kolibri/kol-tabs.entry.js +1 -1
  658. package/dist/kolibri/kol-tabs.entry.js.map +1 -1
  659. package/dist/kolibri/kol-textarea.entry.esm.js.map +1 -1
  660. package/dist/kolibri/kol-textarea.entry.js +1 -1
  661. package/dist/kolibri/kol-textarea.entry.js.map +1 -1
  662. package/dist/kolibri/kol-toast-container.entry.esm.js.map +1 -1
  663. package/dist/kolibri/kol-toast-container.entry.js +1 -1
  664. package/dist/kolibri/kol-toast-container.entry.js.map +1 -1
  665. package/dist/kolibri/kol-toolbar.entry.esm.js.map +1 -1
  666. package/dist/kolibri/kol-toolbar.entry.js +1 -1
  667. package/dist/kolibri/kol-toolbar.entry.js.map +1 -1
  668. package/dist/kolibri/kol-tooltip-wc.entry.esm.js.map +1 -1
  669. package/dist/kolibri/kol-tooltip-wc.entry.js +1 -1
  670. package/dist/kolibri/kol-tooltip-wc.entry.js.map +1 -1
  671. package/dist/kolibri/kol-tree-item-wc.entry.js +1 -1
  672. package/dist/kolibri/kol-tree-item-wc.entry.js.map +1 -1
  673. package/dist/kolibri/kol-tree-item.entry.js +1 -1
  674. package/dist/kolibri/kol-tree-item.entry.js.map +1 -1
  675. package/dist/kolibri/kol-tree-wc.entry.js +1 -1
  676. package/dist/kolibri/kol-tree-wc.entry.js.map +1 -1
  677. package/dist/kolibri/kol-tree.entry.js +1 -1
  678. package/dist/kolibri/kol-tree.entry.js.map +1 -1
  679. package/dist/kolibri/kol-version.entry.js +1 -1
  680. package/dist/kolibri/kol-version.entry.js.map +1 -1
  681. package/dist/kolibri/kolibri.esm.js +1 -1
  682. package/dist/kolibri/kolibri.esm.js.map +1 -1
  683. package/dist/kolibri/label-CdtNxOKu.js.map +1 -1
  684. package/dist/kolibri/max-length-behavior-BmNWss6T.js.map +1 -1
  685. package/dist/kolibri/test-component.entry.js +1 -1
  686. package/dist/kolibri/test-component.entry.js.map +1 -1
  687. package/dist/types/components.d.ts +124 -100
  688. package/dist/types/e2e/input-msg.d.ts +2 -2
  689. package/dist/types/functional-component-wrappers/_helpers/getRenderStates.d.ts +3 -2
  690. package/dist/types/functional-components/FieldControl/FieldControl.d.ts +2 -2
  691. package/dist/types/functional-components/FormField/FormField.d.ts +2 -2
  692. package/dist/types/functional-components/FormFieldMsg/FormFieldMsg.d.ts +3 -4
  693. package/dist/types/functional-components/InputContainer/InputContainer.d.ts +2 -2
  694. package/dist/types/functional-components/inputs/Input/Input.d.ts +2 -2
  695. package/dist/types/functional-components/inputs/NativeSelect/NativeSelect.d.ts +5 -2
  696. package/dist/types/functional-components/inputs/TextArea/TextArea.d.ts +5 -2
  697. package/dist/types/schema/props/msg.d.ts +6 -9
  698. package/dist/types/stencil-public-runtime.d.ts +21 -0
  699. package/doc/button-link.md +4 -4
  700. package/doc/button.md +4 -4
  701. package/doc/combobox.md +20 -20
  702. package/doc/input-checkbox.md +22 -22
  703. package/doc/input-color.md +20 -20
  704. package/doc/input-date.md +26 -26
  705. package/doc/input-email.md +28 -28
  706. package/doc/input-file.md +20 -20
  707. package/doc/input-number.md +26 -26
  708. package/doc/input-password.md +27 -27
  709. package/doc/input-radio.md +17 -17
  710. package/doc/input-range.md +22 -22
  711. package/doc/input-text.md +29 -29
  712. package/doc/link-button.md +2 -2
  713. package/doc/link.md +2 -2
  714. package/doc/popover-button.md +2 -3
  715. package/doc/select.md +22 -22
  716. package/doc/single-select.md +22 -22
  717. package/doc/split-button.md +4 -4
  718. package/doc/textarea.md +27 -27
  719. package/package.json +2 -2
  720. package/vscode-custom-data.json +54 -296
  721. package/dist/cjs/FieldControlStateWrapper-B1qQ3hQ7.js +0 -4
  722. package/dist/cjs/FieldControlStateWrapper-B1qQ3hQ7.js.map +0 -1
  723. package/dist/cjs/FormFieldStateWrapper-CPVnaqrG.js +0 -4
  724. package/dist/cjs/FormFieldStateWrapper-CPVnaqrG.js.map +0 -1
  725. package/dist/cjs/Input-D1MCZPt4.js +0 -4
  726. package/dist/cjs/Input-D1MCZPt4.js.map +0 -1
  727. package/dist/cjs/InputStateWrapper-L2XHGzYI.js +0 -4
  728. package/dist/cjs/InputStateWrapper-L2XHGzYI.js.map +0 -1
  729. package/dist/cjs/controller-icon-D5rg_BkW.js +0 -4
  730. package/dist/cjs/controller-icon-D5rg_BkW.js.map +0 -1
  731. package/dist/cjs/index-BAxGQsCx.js +0 -4
  732. package/dist/cjs/index-BAxGQsCx.js.map +0 -1
  733. package/dist/cjs/kol-abbr.cjs.entry.js.map +0 -1
  734. package/dist/cjs/kol-accordion.cjs.entry.js.map +0 -1
  735. package/dist/cjs/kol-alert-wc.cjs.entry.js.map +0 -1
  736. package/dist/cjs/kol-alert.cjs.entry.js.map +0 -1
  737. package/dist/cjs/kol-avatar-wc.cjs.entry.js.map +0 -1
  738. package/dist/cjs/kol-avatar.cjs.entry.js.map +0 -1
  739. package/dist/cjs/kol-badge.cjs.entry.js.map +0 -1
  740. package/dist/cjs/kol-breadcrumb.cjs.entry.js.map +0 -1
  741. package/dist/cjs/kol-button-link.cjs.entry.js.map +0 -1
  742. package/dist/cjs/kol-button-wc.cjs.entry.js.map +0 -1
  743. package/dist/cjs/kol-button.cjs.entry.js.map +0 -1
  744. package/dist/cjs/kol-card-wc.cjs.entry.js.map +0 -1
  745. package/dist/cjs/kol-card.cjs.entry.js.map +0 -1
  746. package/dist/cjs/kol-combobox.cjs.entry.js.map +0 -1
  747. package/dist/cjs/kol-details.cjs.entry.js.map +0 -1
  748. package/dist/cjs/kol-drawer.cjs.entry.js.map +0 -1
  749. package/dist/cjs/kol-form.cjs.entry.js.map +0 -1
  750. package/dist/cjs/kol-heading.cjs.entry.js.map +0 -1
  751. package/dist/cjs/kol-icon.cjs.entry.js.map +0 -1
  752. package/dist/cjs/kol-image.cjs.entry.js.map +0 -1
  753. package/dist/cjs/kol-input-checkbox.cjs.entry.js.map +0 -1
  754. package/dist/cjs/kol-input-color.cjs.entry.js.map +0 -1
  755. package/dist/cjs/kol-input-date.cjs.entry.js.map +0 -1
  756. package/dist/cjs/kol-input-email.cjs.entry.js.map +0 -1
  757. package/dist/cjs/kol-input-file.cjs.entry.js.map +0 -1
  758. package/dist/cjs/kol-input-number.cjs.entry.js.map +0 -1
  759. package/dist/cjs/kol-input-password.cjs.entry.js.map +0 -1
  760. package/dist/cjs/kol-input-radio.cjs.entry.js.map +0 -1
  761. package/dist/cjs/kol-input-range.cjs.entry.js.map +0 -1
  762. package/dist/cjs/kol-input-text.cjs.entry.js.map +0 -1
  763. package/dist/cjs/kol-kolibri.cjs.entry.js.map +0 -1
  764. package/dist/cjs/kol-link-button.cjs.entry.js.map +0 -1
  765. package/dist/cjs/kol-link-wc.cjs.entry.js.map +0 -1
  766. package/dist/cjs/kol-link.cjs.entry.js.map +0 -1
  767. package/dist/cjs/kol-modal.cjs.entry.js.map +0 -1
  768. package/dist/cjs/kol-nav.cjs.entry.js.map +0 -1
  769. package/dist/cjs/kol-pagination-wc.cjs.entry.js.map +0 -1
  770. package/dist/cjs/kol-pagination.cjs.entry.js.map +0 -1
  771. package/dist/cjs/kol-popover-button-wc.cjs.entry.js.map +0 -1
  772. package/dist/cjs/kol-popover-button.cjs.entry.js.map +0 -1
  773. package/dist/cjs/kol-popover-wc.cjs.entry.js.map +0 -1
  774. package/dist/cjs/kol-progress.cjs.entry.js.map +0 -1
  775. package/dist/cjs/kol-quote.cjs.entry.js.map +0 -1
  776. package/dist/cjs/kol-select.cjs.entry.js.map +0 -1
  777. package/dist/cjs/kol-single-select.cjs.entry.js.map +0 -1
  778. package/dist/cjs/kol-skip-nav.cjs.entry.js.map +0 -1
  779. package/dist/cjs/kol-spin.cjs.entry.js.map +0 -1
  780. package/dist/cjs/kol-split-button.cjs.entry.js.map +0 -1
  781. package/dist/cjs/kol-table-settings-wc.cjs.entry.js.map +0 -1
  782. package/dist/cjs/kol-table-stateful.cjs.entry.js.map +0 -1
  783. package/dist/cjs/kol-table-stateless-wc.cjs.entry.js.map +0 -1
  784. package/dist/cjs/kol-table-stateless.cjs.entry.js.map +0 -1
  785. package/dist/cjs/kol-tabs.cjs.entry.js.map +0 -1
  786. package/dist/cjs/kol-textarea.cjs.entry.js.map +0 -1
  787. package/dist/cjs/kol-toast-container.cjs.entry.js.map +0 -1
  788. package/dist/cjs/kol-toolbar.cjs.entry.js.map +0 -1
  789. package/dist/cjs/kol-tooltip-wc.cjs.entry.js.map +0 -1
  790. package/dist/cjs/kol-tree-item-wc.cjs.entry.js.map +0 -1
  791. package/dist/cjs/kol-tree-item.cjs.entry.js.map +0 -1
  792. package/dist/cjs/kol-tree-wc.cjs.entry.js.map +0 -1
  793. package/dist/cjs/kol-tree.cjs.entry.js.map +0 -1
  794. package/dist/cjs/kol-version.cjs.entry.js.map +0 -1
  795. package/dist/cjs/test-component.cjs.entry.js.map +0 -1
  796. package/dist/esm/FieldControlStateWrapper-ChUQFvRm.js +0 -4
  797. package/dist/esm/FieldControlStateWrapper-ChUQFvRm.js.map +0 -1
  798. package/dist/esm/FormFieldStateWrapper-BDa3sFBn.js +0 -4
  799. package/dist/esm/FormFieldStateWrapper-BDa3sFBn.js.map +0 -1
  800. package/dist/esm/Icon-Bsf76uHm.js +0 -4
  801. package/dist/esm/Input-BQVzI0c9.js +0 -4
  802. package/dist/esm/Input-BQVzI0c9.js.map +0 -1
  803. package/dist/esm/InputStateWrapper-BVBg8J1R.js +0 -4
  804. package/dist/esm/InputStateWrapper-BVBg8J1R.js.map +0 -1
  805. package/dist/esm/InternalUnderlinedBadgeText-EK327PqL.js +0 -4
  806. package/dist/esm/controller-icon-NuudIQ5E.js +0 -4
  807. package/dist/esm/controller-icon-NuudIQ5E.js.map +0 -1
  808. package/dist/esm/index-DwzuLp_u.js +0 -4
  809. package/dist/esm/index-DwzuLp_u.js.map +0 -1
  810. package/dist/kolibri/Alert-DSfF5oYO.js +0 -4
  811. package/dist/kolibri/Collapsible-8yntsjFt.js +0 -4
  812. package/dist/kolibri/FieldControlStateWrapper-ChUQFvRm.js +0 -4
  813. package/dist/kolibri/FieldControlStateWrapper-ChUQFvRm.js.map +0 -1
  814. package/dist/kolibri/FormFieldStateWrapper-BDa3sFBn.js +0 -4
  815. package/dist/kolibri/FormFieldStateWrapper-BDa3sFBn.js.map +0 -1
  816. package/dist/kolibri/Input-BQVzI0c9.js +0 -4
  817. package/dist/kolibri/Input-BQVzI0c9.js.map +0 -1
  818. package/dist/kolibri/InputStateWrapper-BVBg8J1R.js +0 -4
  819. package/dist/kolibri/InputStateWrapper-BVBg8J1R.js.map +0 -1
  820. package/dist/kolibri/InternalUnderlinedBadgeText-EK327PqL.js +0 -4
  821. package/dist/kolibri/Span-CabLpAXO.js +0 -4
  822. package/dist/kolibri/controller-CjDina_l.js +0 -4
  823. package/dist/kolibri/controller-icon-NuudIQ5E.js +0 -4
  824. package/dist/kolibri/controller-icon-NuudIQ5E.js.map +0 -1
  825. package/dist/kolibri/index-DwzuLp_u.js.map +0 -1
  826. package/dist/types/utils/transformObjectProperties.d.ts +0 -5
  827. package/dist/types/utils/transformObjectProperties.test.d.ts +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"controller-BF3IbQCZ.js","sources":["src/components/form/controller.ts"],"sourcesContent":["import type { FormProps } from '../../schema';\nimport { Log } from '../../schema';\nimport { devHint, getExperimentalMode, KoliBriDevHelper, setEventTarget } from '../../schema';\nimport { KolFormTag } from '../../core/component-names';\n\nconst searchFormElement = (el?: HTMLElement | ParentNode | null): HTMLElement | ParentNode | null | undefined => {\n\tif (getExperimentalMode()) {\n\t\tdevHint(`↓ Search form element start.`);\n\t\tLog.debug(el);\n\t}\n\twhile (el instanceof HTMLElement && el.tagName !== 'FORM' && el.tagName !== KolFormTag.toUpperCase()) {\n\t\ttry {\n\t\t\tif (el.parentElement instanceof HTMLElement) {\n\t\t\t\tel = el.parentElement;\n\t\t\t} else if (el.parentNode instanceof ShadowRoot) {\n\t\t\t\tel = el.parentNode.host;\n\t\t\t} else {\n\t\t\t\tel = null;\n\t\t\t}\n\t\t} catch (error) {\n\t\t\t/**\n\t\t\t * Try is needed for SSR.\n\t\t\t * - no HTMLElement is available\n\t\t\t * - no ShadowRoot is available\n\t\t\t */\n\t\t}\n\t\tif (getExperimentalMode()) {\n\t\t\tLog.debug(el);\n\t\t\tdevHint(`↑ Search form element finished.`);\n\t\t}\n\t}\n\treturn el;\n};\n\nexport const propagateResetEventToForm = (\n\toptions: {\n\t\tform?: HTMLElement | ParentNode | null;\n\t\tref?: HTMLElement;\n\t} = {},\n): void => {\n\tconst form = searchFormElement(options.form);\n\tif (form instanceof HTMLElement) {\n\t\tconst event = new Event('reset', {\n\t\t\tbubbles: true,\n\t\t\tcancelable: true,\n\t\t});\n\t\tif (form.tagName === 'FORM') {\n\t\t\tsetEventTarget(event, form);\n\t\t\tform.dispatchEvent(event);\n\t\t} else if (form.tagName === KolFormTag.toUpperCase()) {\n\t\t\tsetEventTarget(event, KoliBriDevHelper.querySelector('form', form) as HTMLFormElement);\n\t\t\tconst kolForm = form as FormProps;\n\t\t\tif (typeof kolForm._on?.onReset === 'function') {\n\t\t\t\ttypeof kolForm._on?.onReset(event);\n\t\t\t}\n\t\t}\n\t}\n};\n\nexport const propagateSubmitEventToForm = (\n\toptions: {\n\t\tform?: HTMLElement | ParentNode | null;\n\t\tref?: HTMLElement;\n\t} = {},\n): void => {\n\tconst form = searchFormElement(options.form);\n\tif (form instanceof HTMLElement) {\n\t\tconst event = new SubmitEvent('submit', {\n\t\t\tbubbles: true,\n\t\t\tcancelable: true,\n\t\t\tsubmitter: form,\n\t\t});\n\t\t/**\n\t\t * TODO: Wenn Formular-Action (nicht Ajax oder JS) verwendet wird,\n\t\t * dann müssen wir das Event an das HTMLFormElement innerhalb\n\t\t * der HTMLKolFormElements propagieren, wenn kein onSubmit\n\t\t * gesetzt wurde.\n\t\t *\n\t\t * TODO: Form-associated custom elements:\n\t\t * - https://web.dev/more-capable-form-controls/\n\t\t * - https://github.com/public-ui/kolibri/issues/946\n\t\t */\n\t\tif (form.tagName === 'FORM') {\n\t\t\tif (getExperimentalMode() && (form as HTMLFormElement).noValidate === false) {\n\t\t\t\tdevHint(`If you have not focusable or hidden form fields in your form, you should enable noValidate for your form.`, {\n\t\t\t\t\tforce: true,\n\t\t\t\t});\n\t\t\t\t// (form as HTMLFormElement).noValidate = true; do not make this implicit\n\t\t\t}\n\t\t\t// Use setTimeout to ensure onChange has been called first\n\t\t\tsetTimeout(() => {\n\t\t\t\t// See https://developer.mozilla.org/en-US/docs/Web/API/HTMLFormElement/requestSubmit\n\t\t\t\tif (typeof (form as HTMLFormElement).requestSubmit === 'function') {\n\t\t\t\t\t(form as HTMLFormElement).requestSubmit();\n\t\t\t\t} else {\n\t\t\t\t\tsetEventTarget(event, form);\n\t\t\t\t\tform.dispatchEvent(event);\n\t\t\t\t}\n\t\t\t});\n\t\t} else if (form.tagName === KolFormTag.toUpperCase()) {\n\t\t\tsetEventTarget(event, KoliBriDevHelper.querySelector('form', form) as HTMLFormElement);\n\t\t\tconst kolForm = form as FormProps;\n\t\t\t// Use setTimeout to ensure onChange has been called first\n\t\t\tsetTimeout(() => {\n\t\t\t\tif (typeof kolForm._on?.onSubmit === 'function') {\n\t\t\t\t\tkolForm._on?.onSubmit(event);\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t}\n};\n"],"names":["getExperimentalMode","devHint","Log","KolFormTag","setEventTarget","KoliBriDevHelper"],"mappings":";;;;;;;;AAKA,MAAM,iBAAiB,GAAG,CAAC,EAAoC,KAAiD;IAC/G,IAAIA,0BA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CAAC,OAAO,KAAKD,yBAAU,CAAC,WAAW,EAAE,EAAE;AACrD,YAAAC,qBAAc,CAAC,KAAK,EAAEC,uBAAgB,CAAC,aAAa,CAAC,MAAM,EAAE,IAAI,CAAoB,CAAC;YACtF,MAAM,OAAO,GAAG,IAAiB;YAEjC,UAAU,CAAC,MAAK;;AACf,gBAAA,IAAI,QAAO,CAAA,EAAA,GAAA,OAAO,CAAC,GAAG,MAAE,IAAA,IAAA,EAAA,KAAA,MAAA,GAAA,MAAA,GAAA,EAAA,CAAA,QAAQ,CAAA,KAAK,UAAU,EAAE;oBAChD,CAAA,EAAA,GAAA,OAAO,CAAC,GAAG,MAAA,IAAA,IAAA,EAAA,KAAA,MAAA,GAAA,MAAA,GAAA,EAAA,CAAE,QAAQ,CAAC,KAAK,CAAC;;AAE9B,aAAC,CAAC;;;AAGL;;;;;"}
1
+ {"version":3,"file":"controller-BF3IbQCZ.js","sources":["src/components/form/controller.ts"],"sourcesContent":["import type { FormProps } from '../../schema';\nimport { Log } from '../../schema';\nimport { devHint, getExperimentalMode, KoliBriDevHelper, setEventTarget } from '../../schema';\nimport { KolFormTag } from '../../core/component-names';\n\nconst searchFormElement = (el?: HTMLElement | ParentNode | null): HTMLElement | ParentNode | null | undefined => {\n\tif (getExperimentalMode()) {\n\t\tdevHint(`↓ Search form element start.`);\n\t\tLog.debug(el);\n\t}\n\twhile (el instanceof HTMLElement && el.tagName !== 'FORM' && el.tagName !== KolFormTag.toUpperCase()) {\n\t\ttry {\n\t\t\tif (el.parentElement instanceof HTMLElement) {\n\t\t\t\tel = el.parentElement;\n\t\t\t} else if (el.parentNode instanceof ShadowRoot) {\n\t\t\t\tel = el.parentNode.host;\n\t\t\t} else {\n\t\t\t\tel = null;\n\t\t\t}\n\t\t} catch (error) {\n\t\t\t/**\n\t\t\t * Try is needed for SSR.\n\t\t\t * - no HTMLElement is available\n\t\t\t * - no ShadowRoot is available\n\t\t\t */\n\t\t}\n\t\tif (getExperimentalMode()) {\n\t\t\tLog.debug(el);\n\t\t\tdevHint(`↑ Search form element finished.`);\n\t\t}\n\t}\n\treturn el;\n};\n\nexport const propagateResetEventToForm = (\n\toptions: {\n\t\tform?: HTMLElement | ParentNode | null;\n\t\tref?: HTMLElement;\n\t} = {},\n): void => {\n\tconst form = searchFormElement(options.form);\n\tif (form instanceof HTMLElement) {\n\t\tconst event = new Event('reset', {\n\t\t\tbubbles: true,\n\t\t\tcancelable: true,\n\t\t});\n\t\tif (form.tagName === 'FORM') {\n\t\t\tsetEventTarget(event, form);\n\t\t\tform.dispatchEvent(event);\n\t\t} else if (form.tagName === KolFormTag.toUpperCase()) {\n\t\t\tsetEventTarget(event, KoliBriDevHelper.querySelector('form', form) as HTMLFormElement);\n\t\t\tconst kolForm = form as FormProps;\n\t\t\tif (typeof kolForm._on?.onReset === 'function') {\n\t\t\t\ttypeof kolForm._on?.onReset(event);\n\t\t\t}\n\t\t}\n\t}\n};\n\nexport const propagateSubmitEventToForm = (\n\toptions: {\n\t\tform?: HTMLElement | ParentNode | null;\n\t\tref?: HTMLElement;\n\t} = {},\n): void => {\n\tconst form = searchFormElement(options.form);\n\tif (form instanceof HTMLElement) {\n\t\tconst event = new SubmitEvent('submit', {\n\t\t\tbubbles: true,\n\t\t\tcancelable: true,\n\t\t\tsubmitter: form,\n\t\t});\n\t\t/**\n\t\t * TODO: Wenn Formular-Action (nicht Ajax oder JS) verwendet wird,\n\t\t * dann müssen wir das Event an das HTMLFormElement innerhalb\n\t\t * der HTMLKolFormElements propagieren, wenn kein onSubmit\n\t\t * gesetzt wurde.\n\t\t *\n\t\t * TODO: Form-associated custom elements:\n\t\t * - https://web.dev/more-capable-form-controls/\n\t\t * - https://github.com/public-ui/kolibri/issues/946\n\t\t */\n\t\tif (form.tagName === 'FORM') {\n\t\t\tif (getExperimentalMode() && (form as HTMLFormElement).noValidate === false) {\n\t\t\t\tdevHint(`If you have not focusable or hidden form fields in your form, you should enable noValidate for your form.`, {\n\t\t\t\t\tforce: true,\n\t\t\t\t});\n\t\t\t\t// (form as HTMLFormElement).noValidate = true; do not make this implicit\n\t\t\t}\n\t\t\t// Use setTimeout to ensure onChange has been called first\n\t\t\tsetTimeout(() => {\n\t\t\t\t// See https://developer.mozilla.org/en-US/docs/Web/API/HTMLFormElement/requestSubmit\n\t\t\t\tif (typeof (form as HTMLFormElement).requestSubmit === 'function') {\n\t\t\t\t\t(form as HTMLFormElement).requestSubmit();\n\t\t\t\t} else {\n\t\t\t\t\tsetEventTarget(event, form);\n\t\t\t\t\tform.dispatchEvent(event);\n\t\t\t\t}\n\t\t\t});\n\t\t} else if (form.tagName === KolFormTag.toUpperCase()) {\n\t\t\tsetEventTarget(event, KoliBriDevHelper.querySelector('form', form) as HTMLFormElement);\n\t\t\tconst kolForm = form as FormProps;\n\t\t\t// Use setTimeout to ensure onChange has been called first\n\t\t\tsetTimeout(() => {\n\t\t\t\tif (typeof kolForm._on?.onSubmit === 'function') {\n\t\t\t\t\tkolForm._on?.onSubmit(event);\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t}\n};\n"],"names":["getExperimentalMode","devHint","Log","KolFormTag","setEventTarget","KoliBriDevHelper"],"mappings":";;;;;;;;AAKA,MAAM,iBAAiB,GAAG,CAAC,EAAoC,KAAiD;IAC/G,IAAIA,0BAAmB,EAAE,EAAE;QAC1BC,cAAO,CAAC,CAA8B,4BAAA,CAAA,CAAC;AACvC,QAAAC,UAAG,CAAC,KAAK,CAAC,EAAE,CAAC;;AAEd,IAAA,OAAO,EAAE,YAAY,WAAW,IAAI,EAAE,CAAC,OAAO,KAAK,MAAM,IAAI,EAAE,CAAC,OAAO,KAAKC,yBAAU,CAAC,WAAW,EAAE,EAAE;AACrG,QAAA,IAAI;AACH,YAAA,IAAI,EAAE,CAAC,aAAa,YAAY,WAAW,EAAE;AAC5C,gBAAA,EAAE,GAAG,EAAE,CAAC,aAAa;;AACf,iBAAA,IAAI,EAAE,CAAC,UAAU,YAAY,UAAU,EAAE;AAC/C,gBAAA,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A,KAAA,MAAA,GAAA,MAAA,GAAA,EAAA,CAAE,QAAQ,CAAC,KAAK,CAAC;;AAE9B,aAAC,CAAC;;;AAGL;;;;;"}
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- "use strict";var common=require("./common-Cd2qH809.js"),autoComplete=require("./auto-complete-DQ9TPAgi.js"),maxLengthBehavior=require("./max-length-behavior-Bvbwhaxv.js"),placeholder=require("./placeholder-BncK-3gZ.js"),readOnly=require("./read-only-dIvCm73W.js"),required=require("./required-CXU7vdyH.js"),controllerIcon=require("./controller-icon-D5rg_BkW.js");const validatePattern=(t,e,a={})=>{common.watchString(t,"_pattern",e,a)},PasswordVariantPropTypeOptions=["default","visibility-toggle"],validatePasswordVariant=(t,e)=>{common.watchValidator(t,"_variant",t=>"string"==typeof t&&PasswordVariantPropTypeOptions.includes(t),new Set(PasswordVariantPropTypeOptions),e)};class InputPasswordController extends controllerIcon.InputIconController{constructor(t,e,a){super(t,e,a),this.afterSyncCharCounter=()=>{"string"==typeof this.component._value&&(this.component.state._currentLength=this.component._value.length,this.updateCurrentLengthDebounced(this.component._value.length))},this.component=t}validateAutoComplete(t){autoComplete.validateAutoComplete(this.component,t)}validateHasCounter(t){maxLengthBehavior.validateHasCounter(this.component,t)}validateMaxLengthBehavior(t){maxLengthBehavior.validateMaxLengthBehavior(this.component,t)}validateVariant(t){validatePasswordVariant(this.component,t)}validateMaxLength(t){maxLengthBehavior.validateMaxLength(this.component,t,{hooks:{afterPatch:this.afterSyncCharCounter}})}validatePattern(t){validatePattern(this.component,t)}validatePlaceholder(t){placeholder.validatePlaceholder(this.component,t)}validateReadOnly(t){readOnly.validateReadOnly(this.component,t)}validateRequired(t){required.validateRequired(this.component,t)}validateValue(t){common.watchString(this.component,"_value",t,{hooks:{afterPatch:this.afterSyncCharCounter}}),this.setFormAssociatedValue(this.component.state._value)}componentWillLoad(){super.componentWillLoad(),this.validateAutoComplete(this.component._autoComplete),this.validateHasCounter(this.component._hasCounter),this.validateMaxLengthBehavior(this.component._maxLengthBehavior),this.validateMaxLength(this.component._maxLength),this.validatePattern(this.component._pattern),this.validatePlaceholder(this.component._placeholder),this.validateReadOnly(this.component._readOnly),this.validateRequired(this.component._required),this.validateValue(this.component._value),this.validateVariant(this.component._variant)}}exports.InputPasswordController=InputPasswordController;
4
+ "use strict";var common=require("./common-Cd2qH809.js"),autoComplete=require("./auto-complete-DQ9TPAgi.js"),maxLengthBehavior=require("./max-length-behavior-Bvbwhaxv.js"),placeholder=require("./placeholder-BncK-3gZ.js"),readOnly=require("./read-only-dIvCm73W.js"),required=require("./required-CXU7vdyH.js"),controllerIcon=require("./controller-icon-QLNq0HO6.js");const validatePattern=(t,e,a={})=>{common.watchString(t,"_pattern",e,a)},PasswordVariantPropTypeOptions=["default","visibility-toggle"],validatePasswordVariant=(t,e)=>{common.watchValidator(t,"_variant",t=>"string"==typeof t&&PasswordVariantPropTypeOptions.includes(t),new Set(PasswordVariantPropTypeOptions),e)};class InputPasswordController extends controllerIcon.InputIconController{constructor(t,e,a){super(t,e,a),this.afterSyncCharCounter=()=>{"string"==typeof this.component._value&&(this.component.state._currentLength=this.component._value.length,this.updateCurrentLengthDebounced(this.component._value.length))},this.component=t}validateAutoComplete(t){autoComplete.validateAutoComplete(this.component,t)}validateHasCounter(t){maxLengthBehavior.validateHasCounter(this.component,t)}validateMaxLengthBehavior(t){maxLengthBehavior.validateMaxLengthBehavior(this.component,t)}validateVariant(t){validatePasswordVariant(this.component,t)}validateMaxLength(t){maxLengthBehavior.validateMaxLength(this.component,t,{hooks:{afterPatch:this.afterSyncCharCounter}})}validatePattern(t){validatePattern(this.component,t)}validatePlaceholder(t){placeholder.validatePlaceholder(this.component,t)}validateReadOnly(t){readOnly.validateReadOnly(this.component,t)}validateRequired(t){required.validateRequired(this.component,t)}validateValue(t){common.watchString(this.component,"_value",t,{hooks:{afterPatch:this.afterSyncCharCounter}}),this.setFormAssociatedValue(this.component.state._value)}componentWillLoad(){super.componentWillLoad(),this.validateAutoComplete(this.component._autoComplete),this.validateHasCounter(this.component._hasCounter),this.validateMaxLengthBehavior(this.component._maxLengthBehavior),this.validateMaxLength(this.component._maxLength),this.validatePattern(this.component._pattern),this.validatePlaceholder(this.component._placeholder),this.validateReadOnly(this.component._readOnly),this.validateRequired(this.component._required),this.validateValue(this.component._value),this.validateVariant(this.component._variant)}}exports.InputPasswordController=InputPasswordController;
@@ -1 +1 @@
1
- {"version":3,"file":"controller-ZfXZFg-x.js","sources":["src/schema/props/pattern.ts","src/schema/props/variant/password-variant.ts","src/components/input-password/controller.ts"],"sourcesContent":["import type { Generic } from 'adopted-style-sheets';\nimport type { WatchStringOptions } from '../utils';\nimport { watchString } from '../utils';\n\nexport type PatternPropType = string;\n\n/**\n * Defines a validation pattern for the input field.\n */\nexport type PropPattern = {\n\tpattern: PatternPropType;\n};\n\nexport const validatePattern = (component: Generic.Element.Component, value?: PatternPropType, options: WatchStringOptions = {}): void => {\n\twatchString(component, '_pattern', value, options);\n};\n","import type { Generic } from 'adopted-style-sheets';\n\nimport { watchValidator } from '../../utils/prop.validators';\n\nconst PasswordVariantPropTypeOptions = ['default', 'visibility-toggle'] as const;\nexport type PasswordVariantPropType = (typeof PasswordVariantPropTypeOptions)[number];\n\n/**\n * Defines the different variants for displaying the password input.\n */\nexport type PropPasswordVariant = {\n\tvariant: PasswordVariantPropType;\n};\n\n/* validator */\nexport const validatePasswordVariant = (component: Generic.Element.Component, value?: PasswordVariantPropType): void => {\n\twatchValidator(\n\t\tcomponent,\n\t\t'_variant',\n\t\t(value) => typeof value === 'string' && PasswordVariantPropTypeOptions.includes(value),\n\t\tnew Set(PasswordVariantPropTypeOptions),\n\t\tvalue,\n\t);\n};\n","import type {\n\tAutoCompletePropType,\n\tHasCounterPropType,\n\tInputPasswordProps,\n\tInputPasswordWatches,\n\tMaxLengthBehaviorPropType,\n\tPlaceholderPropType,\n\tReadOnlyPropType,\n\tRequiredPropType,\n} from '../../schema';\nimport { validateHasCounter, validateMaxLength, validatePlaceholder, validateReadOnly, validateRequired, validatePattern, watchString } from '../../schema';\nimport { validateAutoComplete } from '../../schema/props/auto-complete';\nimport { validateMaxLengthBehavior } from '../../schema/props/max-length-behavior';\nimport type { PasswordVariantPropType } from '../../schema/props/variant/password-variant';\nimport { validatePasswordVariant } from '../../schema/props/variant/password-variant';\n\nimport { InputIconController } from '../@deprecated/input/controller-icon';\n\nimport type { Generic } from 'adopted-style-sheets';\n\nexport class InputPasswordController extends InputIconController implements InputPasswordWatches {\n\tprotected readonly component: Generic.Element.Component & InputPasswordProps;\n\n\tpublic constructor(component: Generic.Element.Component & InputPasswordProps, name: string, host?: HTMLElement) {\n\t\tsuper(component, name, host);\n\t\tthis.component = component;\n\t}\n\n\tprotected afterSyncCharCounter = () => {\n\t\tif (typeof this.component._value === 'string') {\n\t\t\tthis.component.state._currentLength = this.component._value.length;\n\t\t\tthis.updateCurrentLengthDebounced(this.component._value.length);\n\t\t}\n\t};\n\n\tpublic validateAutoComplete(value?: AutoCompletePropType): void {\n\t\tvalidateAutoComplete(this.component, value);\n\t}\n\n\tpublic validateHasCounter(value?: HasCounterPropType): void {\n\t\tvalidateHasCounter(this.component, value);\n\t}\n\n\tpublic validateMaxLengthBehavior(value?: MaxLengthBehaviorPropType): void {\n\t\tvalidateMaxLengthBehavior(this.component, value);\n\t}\n\n\tpublic validateVariant(value?: PasswordVariantPropType): void {\n\t\tvalidatePasswordVariant(this.component, value);\n\t}\n\n\tpublic validateMaxLength(value?: number): void {\n\t\tvalidateMaxLength(this.component, value, {\n\t\t\thooks: { afterPatch: this.afterSyncCharCounter },\n\t\t});\n\t}\n\n\tpublic validatePattern(value?: string): void {\n\t\tvalidatePattern(this.component, value);\n\t}\n\n\tpublic validatePlaceholder(value?: PlaceholderPropType): void {\n\t\tvalidatePlaceholder(this.component, value);\n\t}\n\n\tpublic validateReadOnly(value?: ReadOnlyPropType): void {\n\t\tvalidateReadOnly(this.component, value);\n\t}\n\n\tpublic validateRequired(value?: RequiredPropType): void {\n\t\tvalidateRequired(this.component, value);\n\t}\n\n\tpublic validateValue(value?: string): void {\n\t\twatchString(this.component, '_value', value, {\n\t\t\thooks: {\n\t\t\t\tafterPatch: this.afterSyncCharCounter,\n\t\t\t},\n\t\t});\n\n\t\tthis.setFormAssociatedValue(this.component.state._value as string);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tsuper.componentWillLoad();\n\t\tthis.validateAutoComplete(this.component._autoComplete);\n\t\tthis.validateHasCounter(this.component._hasCounter);\n\t\tthis.validateMaxLengthBehavior(this.component._maxLengthBehavior);\n\t\tthis.validateMaxLength(this.component._maxLength);\n\t\tthis.validatePattern(this.component._pattern);\n\t\tthis.validatePlaceholder(this.component._placeholder);\n\t\tthis.validateReadOnly(this.component._readOnly);\n\t\tthis.validateRequired(this.component._required);\n\t\tthis.validateValue(this.component._value);\n\t\tthis.validateVariant(this.component._variant);\n\t}\n}\n"],"names":["watchString","watchValidator","InputIconController","validateAutoComplete","validateHasCounter","validateMaxLengthBehavior","validateMaxLength","validatePlaceholder","validateReadOnly","validateRequired"],"mappings":";;;;;;;;;;;;;AAaO,MAAM,eAAe,GAAG,CAAC,SAAoC,EAAE,KAAuB,EAAE,OAAA,GAA8B,EAAE,KAAU;IACxIA,kBAAW,CAAC,SAAS,EAAE,UAAU,EAAE,KAAK,EAAE,OAAO,CAAC;AACnD,CAAC;;ACXD,MAAM,8BAA8B,GAAG,CAAC,SAAS,EAAE,mBAAmB,CAAU;AAWzE,MAAM,uBAAuB,GAAG,CAAC,SAAoC,EAAE,KAA+B,KAAU;AACtH,IAAAC,qBAAc,CACb,SAAS,EACT,UAAU,EACV,CAAC,KAAK,KAAK,OAAO,KAAK,KAAK,QAAQ,IAAI,8BAA8B,CAAC,QAAQ,CAAC,KAAK,CAAC,EACtF,IAAI,GAAG,CAAC,8BAA8B,CAAC,EACvC,KAAK,CACL;AACF,CAAC;;ACHK,MAAO,uBAAwB,SAAQC,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AAM,CAAC;QACzC,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC;;AAE9C;;;;"}
1
+ {"version":3,"file":"controller-C2cxr6Rw.js","sources":["src/schema/props/pattern.ts","src/schema/props/variant/password-variant.ts","src/components/input-password/controller.ts"],"sourcesContent":["import type { Generic } from 'adopted-style-sheets';\nimport type { WatchStringOptions } from '../utils';\nimport { watchString } from '../utils';\n\nexport type PatternPropType = string;\n\n/**\n * Defines a validation pattern for the input field.\n */\nexport type PropPattern = {\n\tpattern: PatternPropType;\n};\n\nexport const validatePattern = (component: Generic.Element.Component, value?: PatternPropType, options: WatchStringOptions = {}): void => {\n\twatchString(component, '_pattern', value, options);\n};\n","import type { Generic } from 'adopted-style-sheets';\n\nimport { watchValidator } from '../../utils/prop.validators';\n\nconst PasswordVariantPropTypeOptions = ['default', 'visibility-toggle'] as const;\nexport type PasswordVariantPropType = (typeof PasswordVariantPropTypeOptions)[number];\n\n/**\n * Defines the different variants for displaying the password input.\n */\nexport type PropPasswordVariant = {\n\tvariant: PasswordVariantPropType;\n};\n\n/* validator */\nexport const validatePasswordVariant = (component: Generic.Element.Component, value?: PasswordVariantPropType): void => {\n\twatchValidator(\n\t\tcomponent,\n\t\t'_variant',\n\t\t(value) => typeof value === 'string' && PasswordVariantPropTypeOptions.includes(value),\n\t\tnew Set(PasswordVariantPropTypeOptions),\n\t\tvalue,\n\t);\n};\n","import type {\n\tAutoCompletePropType,\n\tHasCounterPropType,\n\tInputPasswordProps,\n\tInputPasswordWatches,\n\tMaxLengthBehaviorPropType,\n\tPlaceholderPropType,\n\tReadOnlyPropType,\n\tRequiredPropType,\n} from '../../schema';\nimport { validateHasCounter, validateMaxLength, validatePlaceholder, validateReadOnly, validateRequired, validatePattern, watchString } from '../../schema';\nimport { validateAutoComplete } from '../../schema/props/auto-complete';\nimport { validateMaxLengthBehavior } from '../../schema/props/max-length-behavior';\nimport type { PasswordVariantPropType } from '../../schema/props/variant/password-variant';\nimport { validatePasswordVariant } from '../../schema/props/variant/password-variant';\n\nimport { InputIconController } from '../@deprecated/input/controller-icon';\n\nimport type { Generic } from 'adopted-style-sheets';\n\nexport class InputPasswordController extends InputIconController implements InputPasswordWatches {\n\tprotected readonly component: Generic.Element.Component & InputPasswordProps;\n\n\tpublic constructor(component: Generic.Element.Component & InputPasswordProps, name: string, host?: HTMLElement) {\n\t\tsuper(component, name, host);\n\t\tthis.component = component;\n\t}\n\n\tprotected afterSyncCharCounter = () => {\n\t\tif (typeof this.component._value === 'string') {\n\t\t\tthis.component.state._currentLength = this.component._value.length;\n\t\t\tthis.updateCurrentLengthDebounced(this.component._value.length);\n\t\t}\n\t};\n\n\tpublic validateAutoComplete(value?: AutoCompletePropType): void {\n\t\tvalidateAutoComplete(this.component, value);\n\t}\n\n\tpublic validateHasCounter(value?: HasCounterPropType): void {\n\t\tvalidateHasCounter(this.component, value);\n\t}\n\n\tpublic validateMaxLengthBehavior(value?: MaxLengthBehaviorPropType): void {\n\t\tvalidateMaxLengthBehavior(this.component, value);\n\t}\n\n\tpublic validateVariant(value?: PasswordVariantPropType): void {\n\t\tvalidatePasswordVariant(this.component, value);\n\t}\n\n\tpublic validateMaxLength(value?: number): void {\n\t\tvalidateMaxLength(this.component, value, {\n\t\t\thooks: { afterPatch: this.afterSyncCharCounter },\n\t\t});\n\t}\n\n\tpublic validatePattern(value?: string): void {\n\t\tvalidatePattern(this.component, value);\n\t}\n\n\tpublic validatePlaceholder(value?: PlaceholderPropType): void {\n\t\tvalidatePlaceholder(this.component, value);\n\t}\n\n\tpublic validateReadOnly(value?: ReadOnlyPropType): void {\n\t\tvalidateReadOnly(this.component, value);\n\t}\n\n\tpublic validateRequired(value?: RequiredPropType): void {\n\t\tvalidateRequired(this.component, value);\n\t}\n\n\tpublic validateValue(value?: string): void {\n\t\twatchString(this.component, '_value', value, {\n\t\t\thooks: {\n\t\t\t\tafterPatch: this.afterSyncCharCounter,\n\t\t\t},\n\t\t});\n\n\t\tthis.setFormAssociatedValue(this.component.state._value as string);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tsuper.componentWillLoad();\n\t\tthis.validateAutoComplete(this.component._autoComplete);\n\t\tthis.validateHasCounter(this.component._hasCounter);\n\t\tthis.validateMaxLengthBehavior(this.component._maxLengthBehavior);\n\t\tthis.validateMaxLength(this.component._maxLength);\n\t\tthis.validatePattern(this.component._pattern);\n\t\tthis.validatePlaceholder(this.component._placeholder);\n\t\tthis.validateReadOnly(this.component._readOnly);\n\t\tthis.validateRequired(this.component._required);\n\t\tthis.validateValue(this.component._value);\n\t\tthis.validateVariant(this.component._variant);\n\t}\n}\n"],"names":["watchString","watchValidator","InputIconController","validateAutoComplete","validateHasCounter","validateMaxLengthBehavior","validateMaxLength","validatePlaceholder","validateReadOnly","validateRequired"],"mappings":";;;;;;;;;;;;;AAaO,MAAM,eAAe,GAAG,CAAC,SAAoC,EAAE,KAAuB,EAAE,OAAA,GAA8B,EAAE,KAAU;IACxIA,kBAAW,CAAC,SAAS,EAAE,UAAU,EAAE,KAAK,EAAE,OAAO,CAAC;AACnD,CAAC;;ACXD,MAAM,8BAA8B,GAAG,CAAC,SAAS,EAAE,mBAAmB,CAAU;AAWzE,MAAM,uBAAuB,GAAG,CAAC,SAAoC,EAAE,KAA+B,KAAU;AACtH,IAAAC,qBAAc,CACb,SAAS,EACT,UAAU,EACV,CAAC,KAAK,KAAK,OAAO,KAAK,KAAK,QAAQ,IAAI,8BAA8B,CAAC,QAAQ,CAAC,KAAK,CAAC,EACtF,IAAI,GAAG,CAAC,8BAA8B,CAAC,EACvC,KAAK,CACL;AACF,CAAC;;ACHK,MAAO,uBAAwB,SAAQC,kCAAmB,CAAA;AAG/D,IAAA,WAAA,CAAmB,SAAyD,EAAE,IAAY,EAAE,IAAkB,EAAA;AAC7G,QAAA,KAAK,CAAC,SAAS,EAAE,IAAI,EAAE,IAAI,CAAC;AAInB,QAAA,IAAoB,CAAA,oBAAA,GAAG,MAAK;YACrC,IAAI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js"),spellCheck=require("./spell-check-Bkq4G9L7.js"),suggestions=require("./suggestions-BjiW0xio.js"),controller=require("./controller-ZfXZFg-x.js");const inputTextTypeOptions=["text","search","url","tel"],isInputTextTypePropType=e=>"string"==typeof e&&inputTextTypeOptions.includes(e),validateTypeInputText=(e,t)=>{common.watchValidator(e,"_type",isInputTextTypePropType,new Set(inputTextTypeOptions),t)};class InputTextEmailController extends controller.InputPasswordController{constructor(e,t,o){super(e,t,o),this.component=e}validateSuggestions(e){suggestions.validateSuggestions(this.component,e)}componentWillLoad(){super.componentWillLoad(),this.validateSuggestions(this.component._suggestions)}}class InputTextController extends InputTextEmailController{constructor(e,t,o){super(e,t,o),this.hasError=!1,this.component=e}validateSpellCheck(e){spellCheck.validateSpellCheck(this.component,e)}validateType(e){validateTypeInputText(this.component,e)}componentWillLoad(){super.componentWillLoad(),this.validateSpellCheck(this.component._spellCheck),this.validateType(this.component._type)}}exports.InputTextController=InputTextController,exports.InputTextEmailController=InputTextEmailController;
4
+ "use strict";var common=require("./common-Cd2qH809.js"),spellCheck=require("./spell-check-Bkq4G9L7.js"),suggestions=require("./suggestions-BjiW0xio.js"),controller=require("./controller-C2cxr6Rw.js");const inputTextTypeOptions=["text","search","url","tel"],isInputTextTypePropType=e=>"string"==typeof e&&inputTextTypeOptions.includes(e),validateTypeInputText=(e,t)=>{common.watchValidator(e,"_type",isInputTextTypePropType,new Set(inputTextTypeOptions),t)};class InputTextEmailController extends controller.InputPasswordController{constructor(e,t,o){super(e,t,o),this.component=e}validateSuggestions(e){suggestions.validateSuggestions(this.component,e)}componentWillLoad(){super.componentWillLoad(),this.validateSuggestions(this.component._suggestions)}}class InputTextController extends InputTextEmailController{constructor(e,t,o){super(e,t,o),this.hasError=!1,this.component=e}validateSpellCheck(e){spellCheck.validateSpellCheck(this.component,e)}validateType(e){validateTypeInputText(this.component,e)}componentWillLoad(){super.componentWillLoad(),this.validateSpellCheck(this.component._spellCheck),this.validateType(this.component._type)}}exports.InputTextController=InputTextController,exports.InputTextEmailController=InputTextEmailController;
@@ -1 +1 @@
1
- {"version":3,"file":"controller-B1n3An30.js","sources":["src/schema/props/type-input-text.ts","src/components/input-text/controller.ts"],"sourcesContent":["import type { Generic } from 'adopted-style-sheets';\n\nimport { watchValidator } from '../utils';\n\nexport const inputTextTypeOptions = ['text', 'search', 'url', 'tel'] as const;\nexport type InputTextTypePropType = (typeof inputTextTypeOptions)[number];\n\n/**\n * Defines the type of the input-text component.\n */\nexport type PropTypeInputText = {\n\ttype: InputTextTypePropType;\n};\n\nconst isInputTextTypePropType = (value: unknown): value is InputTextTypePropType => {\n\treturn typeof value === 'string' && inputTextTypeOptions.includes(value as InputTextTypePropType);\n};\n\nexport const validateTypeInputText = (component: Generic.Element.Component, value?: InputTextTypePropType): void => {\n\twatchValidator(component, '_type', isInputTextTypePropType, new Set(inputTextTypeOptions), value);\n};\n","import type {\n\tInputTextProps,\n\tInputTextTypePropType,\n\tInputTextWatches,\n\tPropLabelWithExpertSlot,\n\tPropSuggestions,\n\tSpellCheckPropType,\n\tSuggestionsPropType,\n} from '../../schema';\nimport { validateSpellCheck, validateSuggestions, validateTypeInputText } from '../../schema';\n\nimport { InputPasswordController } from '../input-password/controller';\n\nimport type { Generic } from 'adopted-style-sheets';\n\ntype RequiredProps = PropLabelWithExpertSlot;\ntype OptionalProps = {\n\tid: string;\n} & PropSuggestions;\ntype InputTextEmailProps = Generic.Element.Members<RequiredProps, OptionalProps>;\ntype InputTextEmailWatches = Generic.Element.Watchers<RequiredProps, OptionalProps>;\n\nexport class InputTextEmailController extends InputPasswordController implements InputTextEmailWatches {\n\tprotected readonly component: Generic.Element.Component & InputTextEmailProps;\n\n\tpublic constructor(component: Generic.Element.Component & InputTextEmailProps, name: string, host?: HTMLElement) {\n\t\tsuper(component, name, host);\n\t\tthis.component = component;\n\t}\n\n\tpublic validateSuggestions(value?: SuggestionsPropType): void {\n\t\tvalidateSuggestions(this.component, value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tsuper.componentWillLoad();\n\t\tthis.validateSuggestions(this.component._suggestions);\n\t}\n}\n\nexport class InputTextController extends InputTextEmailController implements InputTextWatches {\n\tprotected readonly component: Generic.Element.Component & InputTextProps;\n\n\tpublic hasError = false;\n\n\tpublic constructor(component: Generic.Element.Component & InputTextProps, name: string, host?: HTMLElement) {\n\t\tsuper(component, name, host);\n\t\tthis.component = component;\n\t}\n\n\tpublic validateSpellCheck(value?: SpellCheckPropType): void {\n\t\tvalidateSpellCheck(this.component, value);\n\t}\n\n\tpublic validateType(value?: InputTextTypePropType): void {\n\t\tvalidateTypeInputText(this.component, value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tsuper.componentWillLoad();\n\t\tthis.validateSpellCheck(this.component._spellCheck);\n\t\tthis.validateType(this.component._type);\n\t}\n}\n"],"names":["watchValidator","InputPasswordController","validateSuggestions","validateSpellCheck"],"mappings":";;;;;;;;;;AAIO,MAAM,oBAAoB,GAAG,CAAC,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,KAAK,CAAU;AAU7E,MAAM,uBAAuB,GAAG,CAAC,KAAc,KAAoC;IAClF,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,oBAAoB,CAAC,QAAQ,CAAC,KAA8B,CAAC;AAClG,CAAC;AAEM,MAAM,qBAAqB,GAAG,CAAC,SAAoC,EAAE,KAA6B,KAAU;AAClH,IAAAA,qBAAc,CAAC,SAAS,EAAE,OAAO,EAAE,uBAAuB,EAAE,IAAI,GAAG,CAAC,oBAAoB,CAAC,EAAE,KAAK,CAAC;AAClG,CAAC;;ACEK,MAAO,wBAAyB,SAAQC,kCAAuB,CAAA;AAGpE,IAAA,WAAA,CAAmB,SAA0D,EAAE,IAAY,EAAE,IAAkB,EAAA;AAC9G,QAAA,KAAK,CAAC,SAAS,EAAE,IAAI,EAAE,IAAI,CAAC;AAC5B,QAAA,IAAI,CAAC,SAAS,GAAG,SAAS;;AAGpB,IAAA,mBAAmB,CAAC,KAA2B,EAAA;AACrD,QAAAC,+BAAmB,CAAC,IAAI,CAAC,SAAS,EAAE,KAAK,CAAC;;IAGpC,iBAAiB,GAAA;QACvB,KAAK,CAAC,iBAAiB,EAAE;QACzB,IAAI,CAAC,mBAAmB,CAAC,IAAI,CAAC,SAAS,CAAC,YAAY,CAAC;;AAEtD;AAEK,MAAO,mBAAoB,SAAQ,wBAAwB,CAAA;AAKhE,IAAA,WAAA,CAAmB,SAAqD,EAAE,IAAY,EAAE,IAAkB,EAAA;AACzG,QAAA,KAAK,CAAC,SAAS,EAAE,IAAI,EAAE,IAAI,CAAC;QAHtB,IAAQ,CAAA,QAAA,GAAG,KAAK;AAItB,QAAA,IAAI,CAAC,SAAS,GAAG,SAAS;;AAGpB,IAAA,kBAAkB,CAAC,KAA0B,EAAA;AACnD,QAAAC,6BAAkB,CAAC,IAAI,CAAC,SAAS,EAAE,KAAK,CAAC;;AAGnC,IAAA,YAAY,CAAC,KAA6B,EAAA;AAChD,QAAA,qBAAqB,CAAC,IAAI,CAAC,SAAS,EAAE,KAAK,CAAC;;IAGtC,iBAAiB,GAAA;QACvB,KAAK,CAAC,iBAAiB,EAAE;QACzB,IAAI,CAAC,kBAAkB,CAAC,IAAI,CAAC,SAAS,CAAC,WAAW,CAAC;QACnD,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC;;AAExC;;;;;"}
1
+ {"version":3,"file":"controller-Ccj6Gm2M.js","sources":["src/schema/props/type-input-text.ts","src/components/input-text/controller.ts"],"sourcesContent":["import type { Generic } from 'adopted-style-sheets';\n\nimport { watchValidator } from '../utils';\n\nexport const inputTextTypeOptions = ['text', 'search', 'url', 'tel'] as const;\nexport type InputTextTypePropType = (typeof inputTextTypeOptions)[number];\n\n/**\n * Defines the type of the input-text component.\n */\nexport type PropTypeInputText = {\n\ttype: InputTextTypePropType;\n};\n\nconst isInputTextTypePropType = (value: unknown): value is InputTextTypePropType => {\n\treturn typeof value === 'string' && inputTextTypeOptions.includes(value as InputTextTypePropType);\n};\n\nexport const validateTypeInputText = (component: Generic.Element.Component, value?: InputTextTypePropType): void => {\n\twatchValidator(component, '_type', isInputTextTypePropType, new Set(inputTextTypeOptions), value);\n};\n","import type {\n\tInputTextProps,\n\tInputTextTypePropType,\n\tInputTextWatches,\n\tPropLabelWithExpertSlot,\n\tPropSuggestions,\n\tSpellCheckPropType,\n\tSuggestionsPropType,\n} from '../../schema';\nimport { validateSpellCheck, validateSuggestions, validateTypeInputText } from '../../schema';\n\nimport { InputPasswordController } from '../input-password/controller';\n\nimport type { Generic } from 'adopted-style-sheets';\n\ntype RequiredProps = PropLabelWithExpertSlot;\ntype OptionalProps = {\n\tid: string;\n} & PropSuggestions;\ntype InputTextEmailProps = Generic.Element.Members<RequiredProps, OptionalProps>;\ntype InputTextEmailWatches = Generic.Element.Watchers<RequiredProps, OptionalProps>;\n\nexport class InputTextEmailController extends InputPasswordController implements InputTextEmailWatches {\n\tprotected readonly component: Generic.Element.Component & InputTextEmailProps;\n\n\tpublic constructor(component: Generic.Element.Component & InputTextEmailProps, name: string, host?: HTMLElement) {\n\t\tsuper(component, name, host);\n\t\tthis.component = component;\n\t}\n\n\tpublic validateSuggestions(value?: SuggestionsPropType): void {\n\t\tvalidateSuggestions(this.component, value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tsuper.componentWillLoad();\n\t\tthis.validateSuggestions(this.component._suggestions);\n\t}\n}\n\nexport class InputTextController extends InputTextEmailController implements InputTextWatches {\n\tprotected readonly component: Generic.Element.Component & InputTextProps;\n\n\tpublic hasError = false;\n\n\tpublic constructor(component: Generic.Element.Component & InputTextProps, name: string, host?: HTMLElement) {\n\t\tsuper(component, name, host);\n\t\tthis.component = component;\n\t}\n\n\tpublic validateSpellCheck(value?: SpellCheckPropType): void {\n\t\tvalidateSpellCheck(this.component, value);\n\t}\n\n\tpublic validateType(value?: InputTextTypePropType): void {\n\t\tvalidateTypeInputText(this.component, value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tsuper.componentWillLoad();\n\t\tthis.validateSpellCheck(this.component._spellCheck);\n\t\tthis.validateType(this.component._type);\n\t}\n}\n"],"names":["watchValidator","InputPasswordController","validateSuggestions","validateSpellCheck"],"mappings":";;;;;;;;;;AAIO,MAAM,oBAAoB,GAAG,CAAC,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,KAAK,CAAU;AAU7E,MAAM,uBAAuB,GAAG,CAAC,KAAc,KAAoC;IAClF,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,oBAAoB,CAAC,QAAQ,CAAC,KAA8B,CAAC;AAClG,CAAC;AAEM,MAAM,qBAAqB,GAAG,CAAC,SAAoC,EAAE,KAA6B,KAAU;AAClH,IAAAA,qBAAc,CAAC,SAAS,EAAE,OAAO,EAAE,uBAAuB,EAAE,IAAI,GAAG,CAAC,oBAAoB,CAAC,EAAE,KAAK,CAAC;AAClG,CAAC;;ACEK,MAAO,wBAAyB,SAAQC,kCAAuB,CAAA;AAGpE,IAAA,WAAA,CAAmB,SAA0D,EAAE,IAAY,EAAE,IAAkB,EAAA;AAC9G,QAAA,KAAK,CAAC,SAAS,EAAE,IAAI,EAAE,IAAI,CAAC;AAC5B,QAAA,IAAI,CAAC,SAAS,GAAG,SAAS;;AAGpB,IAAA,mBAAmB,CAAC,KAA2B,EAAA;AACrD,QAAAC,+BAAmB,CAAC,IAAI,CAAC,SAAS,EAAE,KAAK,CAAC;;IAGpC,iBAAiB,GAAA;QACvB,KAAK,CAAC,iBAAiB,EAAE;QACzB,IAAI,CAAC,mBAAmB,CAAC,IAAI,CAAC,SAAS,CAAC,YAAY,CAAC;;AAEtD;AAEK,MAAO,mBAAoB,SAAQ,wBAAwB,CAAA;AAKhE,IAAA,WAAA,CAAmB,SAAqD,EAAE,IAAY,EAAE,IAAkB,EAAA;AACzG,QAAA,KAAK,CAAC,SAAS,EAAE,IAAI,EAAE,IAAI,CAAC;AAHtB,QAAA,IAAQ,CAAA,QAAA,GAAG,KAAK;AAItB,QAAA,IAAI,CAAC,SAAS,GAAG,SAAS;;AAGpB,IAAA,kBAAkB,CAAC,KAA0B,EAAA;AACnD,QAAAC,6BAAkB,CAAC,IAAI,CAAC,SAAS,EAAE,KAAK,CAAC;;AAGnC,IAAA,YAAY,CAAC,KAA6B,EAAA;AAChD,QAAA,qBAAqB,CAAC,IAAI,CAAC,SAAS,EAAE,KAAK,CAAC;;IAGtC,iBAAiB,GAAA;QACvB,KAAK,CAAC,iBAAiB,EAAE;QACzB,IAAI,CAAC,kBAAkB,CAAC,IAAI,CAAC,SAAS,CAAC,WAAW,CAAC;QACnD,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC;;AAExC;;;;;"}
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- "use strict";var common=require("./common-Cd2qH809.js"),label=require("./label-Nicf9N_T.js"),required=require("./required-CXU7vdyH.js"),FormFieldStateWrapper=require("./FormFieldStateWrapper-CPVnaqrG.js"),orientation=require("./orientation-BGODo_Ua.js");const validateInputSelectOptions=t=>{if("object"==typeof t&&null!==t){if("string"==typeof t.label&&t.label.length>0)return t.disabled=!0===t.disabled,t.label=`${t.label}`.trim(),!1===label.hasEnoughReadableChars(t.label,3)&&!1===label.containsOnlyNumbers(t.label)&&common.a11yHint(`A differing Aria-Label (${t.label}) is inaccessible. A differing Aria-Label should consist of at least three readable characters.`),!Array.isArray(t.options)||void 0===t.options.find(t=>!1===validateInputSelectOptions(t));if("number"==typeof t.label)return!0}return!1},validateOptions=(t,e,o={})=>{common.watchJsonArrayString(t,"_options",t=>"object"==typeof t&&null!==t&&"string"==typeof t.label&&t.label.length>0,e,void 0,o)},validateOptionsWithOptgroup=(t,e,o={})=>{common.watchJsonArrayString(t,"_options",validateInputSelectOptions,e,void 0,o)},fillKeyOptionMap=(t,e,o="")=>{e.forEach((e,i)=>{const a=`${o}-${i}`;"object"==typeof e&&null!==e&&"string"==typeof e.label&&e.label.length>0&&(Array.isArray(e.options)?fillKeyOptionMap(t,e.options,a):t.set(a,e))})};class InputCheckboxRadioController extends FormFieldStateWrapper.InputController{constructor(t,e,o){super(t,e,o),this.component=t}validateRequired(t){required.validateRequired(this.component,t)}componentWillLoad(){super.componentWillLoad(),this.validateRequired(this.component._required)}}class InputRadioController extends InputCheckboxRadioController{constructor(t,e,o){super(t,e,o),this.keyOptionMap=new Map,this.getOptionByKey=t=>this.keyOptionMap.get(t),this.afterPatchOptions=(t,e,o,i)=>{"_value"===i&&this.setFormAssociatedValue(t)},this.beforePatchOptions=(t,e)=>{const o=e.has("_options")?e.get("_options"):this.component.state._options;if(Array.isArray(o)&&o.length>0){this.keyOptionMap.clear();const t=o.map(t=>{var e;return"object"==typeof t&&null!==t&&"string"==typeof t.label?Object.assign(Object.assign({},t),{value:null!==(e=t.value)&&void 0!==e?e:t.label}):t});fillKeyOptionMap(this.keyOptionMap,t)}},this.component=t}validateOrientation(t){orientation.validateOrientation(this.component,t,"vertical")}validateOptions(t){validateOptions(this.component,t,{hooks:{afterPatch:this.afterPatchOptions,beforePatch:this.beforePatchOptions}})}validateValue(t){t=Array.isArray(t)?t[0]:t,common.setState(this.component,"_value",t,{afterPatch:this.afterPatchOptions,beforePatch:this.beforePatchOptions})}componentWillLoad(){super.componentWillLoad(),this.validateOrientation(this.component._orientation),this.validateOptions(this.component._options),this.validateValue(this.component._value)}}exports.InputCheckboxRadioController=InputCheckboxRadioController,exports.InputRadioController=InputRadioController,exports.fillKeyOptionMap=fillKeyOptionMap,exports.validateOptions=validateOptions,exports.validateOptionsWithOptgroup=validateOptionsWithOptgroup;
4
+ "use strict";var common=require("./common-Cd2qH809.js"),label=require("./label-Nicf9N_T.js"),required=require("./required-CXU7vdyH.js"),FormFieldStateWrapper=require("./FormFieldStateWrapper-C8Ds5tPB.js"),orientation=require("./orientation-BGODo_Ua.js");const validateInputSelectOptions=t=>{if("object"==typeof t&&null!==t){if("string"==typeof t.label&&t.label.length>0)return t.disabled=!0===t.disabled,t.label=`${t.label}`.trim(),!1===label.hasEnoughReadableChars(t.label,3)&&!1===label.containsOnlyNumbers(t.label)&&common.a11yHint(`A differing Aria-Label (${t.label}) is inaccessible. A differing Aria-Label should consist of at least three readable characters.`),!Array.isArray(t.options)||void 0===t.options.find(t=>!1===validateInputSelectOptions(t));if("number"==typeof t.label)return!0}return!1},validateOptions=(t,e,o={})=>{common.watchJsonArrayString(t,"_options",t=>"object"==typeof t&&null!==t&&"string"==typeof t.label&&t.label.length>0,e,void 0,o)},validateOptionsWithOptgroup=(t,e,o={})=>{common.watchJsonArrayString(t,"_options",validateInputSelectOptions,e,void 0,o)},fillKeyOptionMap=(t,e,o="")=>{e.forEach((e,i)=>{const a=`${o}-${i}`;"object"==typeof e&&null!==e&&"string"==typeof e.label&&e.label.length>0&&(Array.isArray(e.options)?fillKeyOptionMap(t,e.options,a):t.set(a,e))})};class InputCheckboxRadioController extends FormFieldStateWrapper.InputController{constructor(t,e,o){super(t,e,o),this.component=t}validateRequired(t){required.validateRequired(this.component,t)}componentWillLoad(){super.componentWillLoad(),this.validateRequired(this.component._required)}}class InputRadioController extends InputCheckboxRadioController{constructor(t,e,o){super(t,e,o),this.keyOptionMap=new Map,this.getOptionByKey=t=>this.keyOptionMap.get(t),this.afterPatchOptions=(t,e,o,i)=>{"_value"===i&&this.setFormAssociatedValue(t)},this.beforePatchOptions=(t,e)=>{const o=e.has("_options")?e.get("_options"):this.component.state._options;if(Array.isArray(o)&&o.length>0){this.keyOptionMap.clear();const t=o.map(t=>{var e;return"object"==typeof t&&null!==t&&"string"==typeof t.label?Object.assign(Object.assign({},t),{value:null!==(e=t.value)&&void 0!==e?e:t.label}):t});fillKeyOptionMap(this.keyOptionMap,t)}},this.component=t}validateOrientation(t){orientation.validateOrientation(this.component,t,"vertical")}validateOptions(t){validateOptions(this.component,t,{hooks:{afterPatch:this.afterPatchOptions,beforePatch:this.beforePatchOptions}})}validateValue(t){t=Array.isArray(t)?t[0]:t,common.setState(this.component,"_value",t,{afterPatch:this.afterPatchOptions,beforePatch:this.beforePatchOptions})}componentWillLoad(){super.componentWillLoad(),this.validateOrientation(this.component._orientation),this.validateOptions(this.component._options),this.validateValue(this.component._value)}}exports.InputCheckboxRadioController=InputCheckboxRadioController,exports.InputRadioController=InputRadioController,exports.fillKeyOptionMap=fillKeyOptionMap,exports.validateOptions=validateOptions,exports.validateOptionsWithOptgroup=validateOptionsWithOptgroup;
@@ -1 +1 @@
1
- {"version":3,"file":"controller-BszsfOUC.js","sources":["src/schema/validators/options.ts","src/schema/props/options.ts","src/components/input-radio/controller.ts"],"sourcesContent":["import { containsOnlyNumbers, hasEnoughReadableChars } from '../props';\nimport { a11yHint } from '../utils';\n\nimport type { Optgroup, SelectOption } from '../types';\nexport const validateInputSelectOptions = <T>(option: SelectOption<T>): boolean => {\n\tif (typeof option === 'object' && option !== null) {\n\t\tif (typeof option.label === 'string' && option.label.length > 0) {\n\t\t\toption.disabled = option.disabled === true;\n\t\t\toption.label = `${option.label}`.trim();\n\t\t\tif (hasEnoughReadableChars(option.label, 3) === false && containsOnlyNumbers(option.label) === false) {\n\t\t\t\ta11yHint(`A differing Aria-Label (${option.label}) is inaccessible. A differing Aria-Label should consist of at least three readable characters.`);\n\t\t\t}\n\t\t\tif (Array.isArray((option as Optgroup<T>).options)) {\n\t\t\t\treturn (\n\t\t\t\t\t(option as Optgroup<T>).options.find((item) => {\n\t\t\t\t\t\treturn validateInputSelectOptions(item) === false;\n\t\t\t\t\t}) === undefined\n\t\t\t\t);\n\t\t\t}\n\t\t\treturn true;\n\t\t} else if (typeof option.label === 'number') {\n\t\t\treturn true;\n\t\t}\n\t}\n\treturn false;\n};\n","import type { Generic } from 'adopted-style-sheets';\n\nimport type { RadioOption, Optgroup, Option, StencilUnknown } from '../types';\nimport type { Stringified } from '../types/common';\nimport type { WatchOptions } from '../utils';\nimport { watchJsonArrayString } from '../utils';\nimport { validateInputSelectOptions } from '../validators';\n\n/* types */\n\nexport type OptionsPropType = Stringified<Option<StencilUnknown>[]>;\nexport type OptionsWithOptgroupPropType = Stringified<(Option<StencilUnknown> | Optgroup<StencilUnknown>)[]>;\nexport type RadioOptionsPropType = Stringified<RadioOption<StencilUnknown>[]>;\n\n/**\n * Options the user can choose from.\n */\nexport type PropOptions = {\n\toptions: OptionsPropType;\n};\n\nexport type PropRadioOptions = {\n\toptions: RadioOptionsPropType;\n};\n\n/**\n * Options the user can choose from, also supporting Optgroup.\n */\nexport type PropOptionsWithOptgroup = {\n\toptions: OptionsWithOptgroupPropType;\n};\n\n/* validators */\n\nexport const validateOptions = (component: Generic.Element.Component, value: OptionsPropType | undefined, options: WatchOptions = {}): void => {\n\twatchJsonArrayString(\n\t\tcomponent,\n\t\t'_options',\n\t\t(item: Option<StencilUnknown>) => typeof item === 'object' && item !== null && typeof item.label === 'string' && item.label.length > 0,\n\t\tvalue,\n\t\tundefined,\n\t\toptions,\n\t);\n};\n\nexport const validateOptionsWithOptgroup = (\n\tcomponent: Generic.Element.Component,\n\tvalue: OptionsWithOptgroupPropType | undefined,\n\toptions: WatchOptions = {},\n) => {\n\twatchJsonArrayString(component, '_options', validateInputSelectOptions, value, undefined, options);\n};\n","import type { Generic } from 'adopted-style-sheets';\n\nimport type {\n\tInputRadioProps,\n\tInputRadioWatches,\n\tOptgroup,\n\tOptionsPropType,\n\tPropLabelWithExpertSlot,\n\tRadioOption,\n\tRequiredPropType,\n\tSelectOption,\n\tStencilUnknown,\n} from '../../schema';\nimport { setState, validateOptions, validateRequired } from '../../schema';\n\nimport { InputController } from '../@deprecated/input/controller';\nimport type { OrientationPropType } from '../../schema/props/orientation';\nimport { validateOrientation } from '../../schema/props/orientation';\n\nexport const fillKeyOptionMap = <T>(keyOptionMap: Map<string, RadioOption<T>>, options: SelectOption<T>[], preKey = ''): void => {\n\toptions.forEach((option, index) => {\n\t\tconst key = `${preKey}-${index}`;\n\t\tif (typeof option === 'object' && option !== null && typeof option.label === 'string' && option.label.length > 0) {\n\t\t\tif (Array.isArray((option as Optgroup<T>).options)) {\n\t\t\t\tfillKeyOptionMap(keyOptionMap, (option as Optgroup<T>).options, key);\n\t\t\t} else {\n\t\t\t\tkeyOptionMap.set(key, option as RadioOption<T>);\n\t\t\t}\n\t\t}\n\t});\n};\n\ntype RequiredProps = PropLabelWithExpertSlot;\ntype OptionalProps = {\n\trequired: boolean;\n};\ntype InputCheckboxRadioProps = Generic.Element.Members<RequiredProps, OptionalProps>;\ntype InputCheckboxRadioWatches = Generic.Element.Watchers<RequiredProps, OptionalProps>;\n\nexport class InputCheckboxRadioController extends InputController implements InputCheckboxRadioWatches {\n\tprotected readonly component: Generic.Element.Component & InputCheckboxRadioProps;\n\n\tpublic constructor(component: Generic.Element.Component & InputCheckboxRadioProps, name: string, host?: HTMLElement) {\n\t\tsuper(component, name, host);\n\t\tthis.component = component;\n\t}\n\n\tpublic validateRequired(value?: RequiredPropType): void {\n\t\tvalidateRequired(this.component, value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tsuper.componentWillLoad();\n\t\tthis.validateRequired(this.component._required);\n\t}\n}\n\nexport class InputRadioController extends InputCheckboxRadioController implements InputRadioWatches {\n\tprotected readonly component: Generic.Element.Component & InputRadioProps;\n\tprivate readonly keyOptionMap = new Map<string, RadioOption<StencilUnknown>>();\n\n\tpublic constructor(component: Generic.Element.Component & InputRadioProps, name: string, host?: HTMLElement) {\n\t\tsuper(component, name, host);\n\t\tthis.component = component;\n\t}\n\n\tpublic readonly getOptionByKey = (key: string): RadioOption<StencilUnknown> | undefined => this.keyOptionMap.get(key);\n\n\tprotected readonly afterPatchOptions = (value: unknown, _state: Record<string, unknown>, _component: Generic.Element.Component, key: string): void => {\n\t\tif (key === '_value') {\n\t\t\tthis.setFormAssociatedValue(value as string);\n\t\t}\n\t};\n\n\tpublic validateOrientation(value?: OrientationPropType): void {\n\t\tvalidateOrientation(this.component, value, 'vertical');\n\t}\n\n\tprotected readonly beforePatchOptions = (_value: unknown, nextState: Map<string, unknown>): void => {\n\t\tconst options = nextState.has('_options') ? nextState.get('_options') : this.component.state._options;\n\t\tif (Array.isArray(options) && options.length > 0) {\n\t\t\tthis.keyOptionMap.clear();\n\n\t\t\tconst normalizedOptions = options.map((option: RadioOption<StencilUnknown> | string) => {\n\t\t\t\tif (typeof option === 'object' && option !== null && typeof option.label === 'string') {\n\t\t\t\t\treturn {\n\t\t\t\t\t\t...option,\n\t\t\t\t\t\tvalue: option.value ?? option.label,\n\t\t\t\t\t};\n\t\t\t\t}\n\t\t\t\treturn option;\n\t\t\t});\n\n\t\t\tfillKeyOptionMap(this.keyOptionMap, normalizedOptions as SelectOption<StencilUnknown>[]);\n\t\t}\n\t};\n\n\tpublic validateOptions(value?: OptionsPropType): void {\n\t\tvalidateOptions(this.component, value, {\n\t\t\thooks: {\n\t\t\t\tafterPatch: this.afterPatchOptions,\n\t\t\t\tbeforePatch: this.beforePatchOptions,\n\t\t\t},\n\t\t});\n\t}\n\n\tpublic validateValue(value?: StencilUnknown): void {\n\t\tvalue = Array.isArray(value) ? (value[0] as StencilUnknown) : value;\n\t\tsetState(this.component, '_value', value, {\n\t\t\tafterPatch: this.afterPatchOptions,\n\t\t\tbeforePatch: this.beforePatchOptions,\n\t\t});\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tsuper.componentWillLoad();\n\t\tthis.validateOrientation(this.component._orientation);\n\t\tthis.validateOptions(this.component._options);\n\t\tthis.validateValue(this.component._value);\n\t}\n}\n"],"names":["hasEnoughReadableChars","containsOnlyNumbers","a11yHint","watchJsonArrayString","InputController","validateRequired","validateOrientation","setState"],"mappings":";;;;;;;;;;;AAIO,MAAM,0BAA0B,GAAG,CAAI,MAAuB,KAAa;IACjF,IAAI,OAAO,MAAM,KAAK,QAAQ,IAAI,MAAM,KAAK,IAAI,EAAE;AAClD,QAAA,IAAI,OAAO,MAAM,CAAC,KAAK,KAAK,QAAQ,IAAI,MAAM,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE;Y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,OAAO,MAAM;AACd,iBAAC,CAAC;AAEF,gBAAA,gBAAgB,CAAC,IAAI,CAAC,YAAY,EAAE,iBAAmD,CAAC;;AAE1F,SAAC;AAhCA,QAAA,IAAI,CAAC,SAAS,GAAG,SAAS;;AAWpB,IAAA,mBAAmB,CAAC,KAA2B,EAAA;QACrDC,+BAAmB,CAAC,IAAI,CAAC,SAAS,EAAE,KAAK,EAAE,UAAU,CAAC;;AAsBhD,IAAA,eAAe,CAAC,KAAuB,EAAA;AAC7C,QAAA,eAAe,CAAC,IAAI,CAAC,SAAS,EAAE,KAAK,EAAE;AACtC,YAAA,KAAK,EAAE;gBACN,UAAU,EAAE,IAAI,CAAC,iBAAiB;gBAClC,WAAW,EAAE,IAAI,CAAC,kBAAkB;AACpC,aAAA;AACD,SAAA,CAAC;;AAGI,IAAA,aAAa,CAAC,KAAsB,EAAA;AAC1C,QAAA,KAAK,GAAG,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,GAAI,KAAK,CAAC,CAAC,CAAoB,GAAG,KAAK;QACnEC,eAAQ,CAAC,IAAI,CAAC,SAAS,EAAE,QAAQ,EAAE,KAAK,EAAE;YACzC,UAAU,EAAE,IAAI,CAAC,iBAAiB;YAClC,WAAW,EAAE,IAAI,CAAC,kBAAkB;AACpC,SAAA,CAAC;;IAGI,iBAAiB,GAAA;QACvB,KAAK,CAAC,iBAAiB,EAAE;QACzB,IAAI,CAAC,mBAAmB,CAAC,IAAI,CAAC,SAAS,CAAC,YAAY,CAAC;QACrD,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC;QAC7C,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC;;AAE1C;;;;;;;;"}
1
+ {"version":3,"file":"controller-DvExtwnx.js","sources":["src/schema/validators/options.ts","src/schema/props/options.ts","src/components/input-radio/controller.ts"],"sourcesContent":["import { containsOnlyNumbers, hasEnoughReadableChars } from '../props';\nimport { a11yHint } from '../utils';\n\nimport type { Optgroup, SelectOption } from '../types';\nexport const validateInputSelectOptions = <T>(option: SelectOption<T>): boolean => {\n\tif (typeof option === 'object' && option !== null) {\n\t\tif (typeof option.label === 'string' && option.label.length > 0) {\n\t\t\toption.disabled = option.disabled === true;\n\t\t\toption.label = `${option.label}`.trim();\n\t\t\tif (hasEnoughReadableChars(option.label, 3) === false && containsOnlyNumbers(option.label) === false) {\n\t\t\t\ta11yHint(`A differing Aria-Label (${option.label}) is inaccessible. A differing Aria-Label should consist of at least three readable characters.`);\n\t\t\t}\n\t\t\tif (Array.isArray((option as Optgroup<T>).options)) {\n\t\t\t\treturn (\n\t\t\t\t\t(option as Optgroup<T>).options.find((item) => {\n\t\t\t\t\t\treturn validateInputSelectOptions(item) === false;\n\t\t\t\t\t}) === undefined\n\t\t\t\t);\n\t\t\t}\n\t\t\treturn true;\n\t\t} else if (typeof option.label === 'number') {\n\t\t\treturn true;\n\t\t}\n\t}\n\treturn false;\n};\n","import type { Generic } from 'adopted-style-sheets';\n\nimport type { RadioOption, Optgroup, Option, StencilUnknown } from '../types';\nimport type { Stringified } from '../types/common';\nimport type { WatchOptions } from '../utils';\nimport { watchJsonArrayString } from '../utils';\nimport { validateInputSelectOptions } from '../validators';\n\n/* types */\n\nexport type OptionsPropType = Stringified<Option<StencilUnknown>[]>;\nexport type OptionsWithOptgroupPropType = Stringified<(Option<StencilUnknown> | Optgroup<StencilUnknown>)[]>;\nexport type RadioOptionsPropType = Stringified<RadioOption<StencilUnknown>[]>;\n\n/**\n * Options the user can choose from.\n */\nexport type PropOptions = {\n\toptions: OptionsPropType;\n};\n\nexport type PropRadioOptions = {\n\toptions: RadioOptionsPropType;\n};\n\n/**\n * Options the user can choose from, also supporting Optgroup.\n */\nexport type PropOptionsWithOptgroup = {\n\toptions: OptionsWithOptgroupPropType;\n};\n\n/* validators */\n\nexport const validateOptions = (component: Generic.Element.Component, value: OptionsPropType | undefined, options: WatchOptions = {}): void => {\n\twatchJsonArrayString(\n\t\tcomponent,\n\t\t'_options',\n\t\t(item: Option<StencilUnknown>) => typeof item === 'object' && item !== null && typeof item.label === 'string' && item.label.length > 0,\n\t\tvalue,\n\t\tundefined,\n\t\toptions,\n\t);\n};\n\nexport const validateOptionsWithOptgroup = (\n\tcomponent: Generic.Element.Component,\n\tvalue: OptionsWithOptgroupPropType | undefined,\n\toptions: WatchOptions = {},\n) => {\n\twatchJsonArrayString(component, '_options', validateInputSelectOptions, value, undefined, options);\n};\n","import type { Generic } from 'adopted-style-sheets';\n\nimport type {\n\tInputRadioProps,\n\tInputRadioWatches,\n\tOptgroup,\n\tOptionsPropType,\n\tPropLabelWithExpertSlot,\n\tRadioOption,\n\tRequiredPropType,\n\tSelectOption,\n\tStencilUnknown,\n} from '../../schema';\nimport { setState, validateOptions, validateRequired } from '../../schema';\n\nimport { InputController } from '../@deprecated/input/controller';\nimport type { OrientationPropType } from '../../schema/props/orientation';\nimport { validateOrientation } from '../../schema/props/orientation';\n\nexport const fillKeyOptionMap = <T>(keyOptionMap: Map<string, RadioOption<T>>, options: SelectOption<T>[], preKey = ''): void => {\n\toptions.forEach((option, index) => {\n\t\tconst key = `${preKey}-${index}`;\n\t\tif (typeof option === 'object' && option !== null && typeof option.label === 'string' && option.label.length > 0) {\n\t\t\tif (Array.isArray((option as Optgroup<T>).options)) {\n\t\t\t\tfillKeyOptionMap(keyOptionMap, (option as Optgroup<T>).options, key);\n\t\t\t} else {\n\t\t\t\tkeyOptionMap.set(key, option as RadioOption<T>);\n\t\t\t}\n\t\t}\n\t});\n};\n\ntype RequiredProps = PropLabelWithExpertSlot;\ntype OptionalProps = {\n\trequired: boolean;\n};\ntype InputCheckboxRadioProps = Generic.Element.Members<RequiredProps, OptionalProps>;\ntype InputCheckboxRadioWatches = Generic.Element.Watchers<RequiredProps, OptionalProps>;\n\nexport class InputCheckboxRadioController extends InputController implements InputCheckboxRadioWatches {\n\tprotected readonly component: Generic.Element.Component & InputCheckboxRadioProps;\n\n\tpublic constructor(component: Generic.Element.Component & InputCheckboxRadioProps, name: string, host?: HTMLElement) {\n\t\tsuper(component, name, host);\n\t\tthis.component = component;\n\t}\n\n\tpublic validateRequired(value?: RequiredPropType): void {\n\t\tvalidateRequired(this.component, value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tsuper.componentWillLoad();\n\t\tthis.validateRequired(this.component._required);\n\t}\n}\n\nexport class InputRadioController extends InputCheckboxRadioController implements InputRadioWatches {\n\tprotected readonly component: Generic.Element.Component & InputRadioProps;\n\tprivate readonly keyOptionMap = new Map<string, RadioOption<StencilUnknown>>();\n\n\tpublic constructor(component: Generic.Element.Component & InputRadioProps, name: string, host?: HTMLElement) {\n\t\tsuper(component, name, host);\n\t\tthis.component = component;\n\t}\n\n\tpublic readonly getOptionByKey = (key: string): RadioOption<StencilUnknown> | undefined => this.keyOptionMap.get(key);\n\n\tprotected readonly afterPatchOptions = (value: unknown, _state: Record<string, unknown>, _component: Generic.Element.Component, key: string): void => {\n\t\tif (key === '_value') {\n\t\t\tthis.setFormAssociatedValue(value as string);\n\t\t}\n\t};\n\n\tpublic validateOrientation(value?: OrientationPropType): void {\n\t\tvalidateOrientation(this.component, value, 'vertical');\n\t}\n\n\tprotected readonly beforePatchOptions = (_value: unknown, nextState: Map<string, unknown>): void => {\n\t\tconst options = nextState.has('_options') ? nextState.get('_options') : this.component.state._options;\n\t\tif (Array.isArray(options) && options.length > 0) {\n\t\t\tthis.keyOptionMap.clear();\n\n\t\t\tconst normalizedOptions = options.map((option: RadioOption<StencilUnknown> | string) => {\n\t\t\t\tif (typeof option === 'object' && option !== null && typeof option.label === 'string') {\n\t\t\t\t\treturn {\n\t\t\t\t\t\t...option,\n\t\t\t\t\t\tvalue: option.value ?? option.label,\n\t\t\t\t\t};\n\t\t\t\t}\n\t\t\t\treturn option;\n\t\t\t});\n\n\t\t\tfillKeyOptionMap(this.keyOptionMap, normalizedOptions as SelectOption<StencilUnknown>[]);\n\t\t}\n\t};\n\n\tpublic validateOptions(value?: OptionsPropType): void {\n\t\tvalidateOptions(this.component, value, {\n\t\t\thooks: {\n\t\t\t\tafterPatch: this.afterPatchOptions,\n\t\t\t\tbeforePatch: this.beforePatchOptions,\n\t\t\t},\n\t\t});\n\t}\n\n\tpublic validateValue(value?: StencilUnknown): void {\n\t\tvalue = Array.isArray(value) ? (value[0] as StencilUnknown) : value;\n\t\tsetState(this.component, '_value', value, {\n\t\t\tafterPatch: this.afterPatchOptions,\n\t\t\tbeforePatch: this.beforePatchOptions,\n\t\t});\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tsuper.componentWillLoad();\n\t\tthis.validateOrientation(this.component._orientation);\n\t\tthis.validateOptions(this.component._options);\n\t\tthis.validateValue(this.component._value);\n\t}\n}\n"],"names":["hasEnoughReadableChars","containsOnlyNumbers","a11yHint","watchJsonArrayString","InputController","validateRequired","validateOrientation","setState"],"mappings":";;;;;;;;;;;AAIO,MAAM,0BAA0B,GAAG,CAAI,MAAuB,KAAa;IACjF,IAAI,OAAO,MAAM,KAAK,QAAQ,IAAI,MAAM,KAAK,IAAI,EAAE;AAClD,QAAA,IAAI,OAAO,MAAM,CAAC,KAAK,KAAK,QAAQ,IAAI,MAAM,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE;YAChE,MAAM,CAAC,QAAQ,GAAG,MAAM,CAAC,QAAQ,KAAK,IAAI;YAC1C,MAAM,CAAC,KAAK,GAAG,CAAG,EAAA,MAAM,CAAC,KAAK,CAAE,CAAA,CAAC,IAAI,EAAE;YACvC,IAAIA,4BAAsB,CAAC,MAAM,CAAC,KAAK,EAAE,CAAC,CAAC,KAAK,KAAK,IAAIC,yBAAmB,CAAC,MAAM,CAAC,KAAK,CAAC,KAAK,KAAK,EAAE;AACrG,gBAAAC,eAAQ,CAAC,CAA2B,wBAAA,EAAA,MAAM,CAAC,KAAK,CAAA,+FAAA,CAAiG,CAAC;;YAEnJ,IAAI,KAAK,CAAC,OAAO,CAAE,MAAsB,CAAC,OAAO,CA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AAE,IAAI,CAAC,kBAAkB;AACpC,aAAA;AACD,SAAA,CAAC;;AAGI,IAAA,aAAa,CAAC,KAAsB,EAAA;AAC1C,QAAA,KAAK,GAAG,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,GAAI,KAAK,CAAC,CAAC,CAAoB,GAAG,KAAK;QACnEC,eAAQ,CAAC,IAAI,CAAC,SAAS,EAAE,QAAQ,EAAE,KAAK,EAAE;YACzC,UAAU,EAAE,IAAI,CAAC,iBAAiB;YAClC,WAAW,EAAE,IAAI,CAAC,kBAAkB;AACpC,SAAA,CAAC;;IAGI,iBAAiB,GAAA;QACvB,KAAK,CAAC,iBAAiB,EAAE;QACzB,IAAI,CAAC,mBAAmB,CAAC,IAAI,CAAC,SAAS,CAAC,YAAY,CAAC;QACrD,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC;QAC7C,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC;;AAE1C;;;;;;;;"}
@@ -0,0 +1,4 @@
1
+ /*!
2
+ * KoliBri - The accessible HTML-Standard
3
+ */
4
+ "use strict";var index=require("./index-CMEXkCjL.js"),Heading=require("./Heading-DGnr9w8b.js"),clsx=require("./clsx-CkZlkaek.js"),common=require("./common-Cd2qH809.js"),FormFieldStateWrapper=require("./FormFieldStateWrapper-C8Ds5tPB.js"),componentNames=require("./component-names-D7MwtuB7.js"),Icon=require("./Icon-CrlBnVcz.js"),InternalUnderlinedBadgeText=require("./InternalUnderlinedBadgeText-DPW4yX2Z.js"),isObject=require("./isObject-DMA85Fq4.js"),icons=require("./icons-CvKgcv20.js");const InputAdornment=(n,e)=>{var{position:t="start",class:o}=n,s=Heading.__rest(n,["position","class"]);const i="kol-input-container__adornment",r=`${i}--${t}`;return index.h("div",Object.assign({class:clsx.clsx(i,r,o)},s),e)};function hasItems(n){return!!n&&(Array.isArray(n)?n.length>0:Boolean(n))}const Container=(n,e)=>{var{class:t}=n,o=Heading.__rest(n,["class"]);return index.h("div",Object.assign({class:clsx.clsx("kol-input-container__container",t)},o),e)},KolInputContainerFc=(n,e)=>{const{class:t,startAdornment:o,endAdornment:s,disabled:i,msg:r,touched:c,containerProps:a,startAdornmentProps:l,endAdornmentProps:d}=n,u=Heading.__rest(n,["class","startAdornment","endAdornment","disabled","msg","touched","containerProps","startAdornmentProps","endAdornmentProps"]),p=FormFieldStateWrapper.checkHasMsg(r,c),m="string"==typeof r?"error":null==r?void 0:r._type,b={"kol-input-container--disabled":i,[`kol-input-container--${m||"error"}`]:p},g=Object.assign({class:clsx.clsx("kol-input-container",b,t)},u);return hasItems(o)||hasItems(s)?index.h("div",Object.assign({},g),index.h(InputAdornment,Object.assign({},l,{position:"start"}),o),index.h(Container,Object.assign({},a),e),index.h(InputAdornment,Object.assign({},d,{position:"end"}),s)):index.h("div",Object.assign({},g),index.h(Container,Object.assign({},a),e))},KolButtonFc=n=>{const{label:e,icons:t,hideLabel:o,disabled:s,onClick:i}=n,r=Heading.__rest(n,["label","icons","hideLabel","disabled","onClick"]);return index.h(componentNames.KolButtonWcTag,Object.assign({_label:e,_disabled:s,_icons:t,_hideLabel:o,_on:{onClick:i}},r))},KolIconButtonFc=n=>{const{componentName:e="button",label:t,icon:o,onClick:s}=n,i=Heading.__rest(n,["componentName","label","icon","onClick"]),r="button"===e?KolButtonFc:Icon.KolIconFc;return index.h(r,Object.assign({label:t||"",hideLabel:!0,icons:`codicon codicon-${o}`,onClick:s},i))};function getInputContainerProps(n){let e,t;return"_icons"in n&&(e=n._icons),"_smartButton"in n&&(t=n._smartButton),{icons:e,smartButton:t,disabled:n._disabled,msg:n._msg,touched:n._touched}}const InputContainerStateWrapperFc=({state:n,endAdornment:e},t)=>{const{icons:o,smartButton:s,disabled:i,msg:r,touched:c}=getInputContainerProps(n);let a=null==o?void 0:o.left;InternalUnderlinedBadgeText.isString(a)&&(a={icon:a});let l=null==o?void 0:o.right;InternalUnderlinedBadgeText.isString(l)&&(l={icon:l});const d=[],u=[];return e&&(Array.isArray(e)?u.push(...e):u.push(e)),a&&d.push(index.h(KolIconButtonFc,Object.assign({componentName:"icon",class:"kol-input-container__icon"},isObject.isObject(a)?a:{}))),isObject.isObject(s)&&u.push(index.h(KolIconButtonFc,Object.assign({componentName:"button",class:"kol-input-container__smart-button"},s,{hideLabel:!0,disabled:i}))),l&&u.push(index.h(KolIconButtonFc,Object.assign({componentName:"icon",class:"kol-input-container__icon"},isObject.isObject(l)?l:{}))),index.h(KolInputContainerFc,{disabled:i,msg:r,touched:c,startAdornment:d,endAdornment:u},t)};class InputIconController extends FormFieldStateWrapper.InputController{constructor(n,e,t){super(n,e,t),this.numberStringRegex=/^\d+(\.\d+)?$/,this.parseToNumber=n=>"number"==typeof n?isNaN(n)?null:n:this.isNumberString(n)?parseFloat(n):null,this.validateNumber=(n,e)=>common.watchValidator(this.component,n,n=>null==n||"number"==typeof n||"string"==typeof n&&this.numberStringRegex.test(n),new Set(["number","NumberString"]),e,{hooks:{beforePatch:(e,t)=>{(null==t?void 0:t.has(n))&&(null==t||t.set(n,this.parseToNumber(e)))}}}),this.component=n}validateIcons(n){icons.validateIcons(this.component,n)}isNumberString(n){return"string"==typeof n&&this.numberStringRegex.test(n)}componentWillLoad(){super.componentWillLoad(),this.validateIcons(this.component._icons)}}exports.InputContainerStateWrapperFc=InputContainerStateWrapperFc,exports.InputIconController=InputIconController,exports.KolIconButtonFc=KolIconButtonFc;
@@ -0,0 +1 @@
1
+ {"version":3,"file":"controller-icon-QLNq0HO6.js","sources":["src/functional-components/InputAdornment/InputAdornment.tsx","src/functional-components/InputContainer/InputContainer.tsx","src/functional-components/Button/Button.tsx","src/functional-components/IconButton/IconButton.tsx","src/functional-component-wrappers/InputContainerStateWrapper/InputContainerStateWrapper.tsx","src/components/@deprecated/input/controller-icon.ts"],"sourcesContent":["import { h, type FunctionalComponent as FC } from '@stencil/core';\nimport type { JSXBase } from '@stencil/core/internal';\nimport clsx from 'clsx';\n\nexport type InputAdornmentProps = JSXBase.HTMLAttributes<HTMLDivElement> & {\n\tposition?: 'start' | 'end';\n};\n\nconst InputAdornment: FC<InputAdornmentProps> = ({ position = 'start', class: className, ...other }, children) => {\n\tconst rootClassName = `kol-input-container__adornment`;\n\tconst positionClassName = `${rootClassName}--${position}`;\n\n\treturn (\n\t\t<div class={clsx(rootClassName, positionClassName, className)} {...other}>\n\t\t\t{children}\n\t\t</div>\n\t);\n};\n\nexport default InputAdornment;\n","import { h, type FunctionalComponent as FC } from '@stencil/core';\nimport clsx from 'clsx';\nimport type { JSXBase, VNode } from '@stencil/core/internal';\nimport InputAdornment from '../InputAdornment';\nimport { checkHasMsg, type MsgPropType, type Stringified } from '../../schema';\n\ntype InputAdornmentType = VNode | VNode[] | null;\n\nexport type InputContainerProps = JSXBase.HTMLAttributes & {\n\tstartAdornment?: InputAdornmentType;\n\tendAdornment?: InputAdornmentType;\n\tdisabled?: boolean;\n\tmsg?: Stringified<MsgPropType>;\n\ttouched?: boolean;\n\n\tcontainerProps?: JSXBase.HTMLAttributes<HTMLDivElement>;\n\tstartAdornmentProps?: JSXBase.HTMLAttributes<HTMLDivElement>;\n\tendAdornmentProps?: JSXBase.HTMLAttributes<HTMLDivElement>;\n};\n\nfunction hasItems(items?: InputAdornmentType): boolean {\n\tif (!items) {\n\t\treturn false;\n\t}\n\n\treturn Array.isArray(items) ? items.length > 0 : Boolean(items);\n}\n\nconst Container: FC<JSXBase.HTMLAttributes<HTMLDivElement>> = ({ class: className, ...other }, children) => {\n\treturn (\n\t\t<div class={clsx('kol-input-container__container', className)} {...other}>\n\t\t\t{children}\n\t\t</div>\n\t);\n};\n\nconst KolInputContainerFc: FC<InputContainerProps> = (props, children) => {\n\tconst { class: classNames, startAdornment, endAdornment, disabled, msg, touched, containerProps, startAdornmentProps, endAdornmentProps, ...other } = props;\n\tconst showMsg = checkHasMsg(msg, touched);\n\tconst msgType = typeof msg === 'string' ? 'error' : msg?._type;\n\n\tconst stateCssClasses = {\n\t\t['kol-input-container--disabled']: disabled,\n\t\t[`kol-input-container--${msgType || 'error'}`]: showMsg,\n\t};\n\n\tconst baseProps: JSXBase.HTMLAttributes<HTMLDivElement> = {\n\t\tclass: clsx('kol-input-container', stateCssClasses, classNames),\n\t\t...other,\n\t};\n\n\tif (!hasItems(startAdornment) && !hasItems(endAdornment)) {\n\t\treturn (\n\t\t\t<div {...baseProps}>\n\t\t\t\t<Container {...containerProps}>{children}</Container>\n\t\t\t</div>\n\t\t);\n\t}\n\n\treturn (\n\t\t<div {...baseProps}>\n\t\t\t<InputAdornment {...startAdornmentProps} position=\"start\">\n\t\t\t\t{startAdornment}\n\t\t\t</InputAdornment>\n\t\t\t<Container {...containerProps}>{children}</Container>\n\t\t\t<InputAdornment {...endAdornmentProps} position=\"end\">\n\t\t\t\t{endAdornment}\n\t\t\t</InputAdornment>\n\t\t</div>\n\t);\n};\n\nexport default KolInputContainerFc;\n","import { h, type FunctionalComponent as FC } from '@stencil/core';\nimport { KolButtonWcTag } from '../../core/component-names';\nimport type { InternalButtonProps } from '../../schema';\n\nexport type ButtonProps = Partial<InternalButtonProps> & {\n\tlabel: string;\n\tclass?: string;\n\tonClick?: (event: MouseEvent) => void;\n};\n\nconst KolButtonFc: FC<ButtonProps> = (props) => {\n\tconst { label, icons, hideLabel, disabled, onClick, ...other } = props;\n\n\treturn <KolButtonWcTag _label={label} _disabled={disabled} _icons={icons} _hideLabel={hideLabel} _on={{ onClick }} {...other} />;\n};\n\nexport default KolButtonFc;\n","import { h, type FunctionalComponent as FC } from '@stencil/core';\nimport KolButtonFc, { type ButtonProps } from '../Button';\nimport KolIconFc, { type IconProps } from '../Icon';\nimport type { ButtonVariantPropType } from '../../schema';\n\ntype IconType = Partial<Omit<IconProps, 'icons'>> & {\n\tcomponentName: 'icon';\n\ticon?: string;\n\tclass?: string;\n\n\tonClick?: (event: MouseEvent) => void;\n};\n\ntype ButtonType = Partial<Omit<ButtonProps, 'icons'>> & {\n\tcomponentName: 'button';\n\ticon?: string;\n\tlabel?: string;\n\tclass?: string;\n\tbuttonVariant?: ButtonVariantPropType;\n\n\tonClick?: (event: MouseEvent) => void;\n};\n\nexport type IconButtonProps = IconType | ButtonType;\n\n/**\n * `KolIconButtonFc` is a functional component that renders either a Button or an Icon based on the provided props.\n *\n * Depending on the value of the `componentName` prop, either a Button (`KolButtonFc`) or an Icon (`KolIconFc`) is rendered.\n * Both components support optional `icon` props for displaying an icon and an optional `onClick` handler for user interactions.\n *\n * This component combines the flexibility of rendering either a button with an optional label or a simple icon, while ensuring that unnecessary props for the selected element are not passed.\n *\n * Supported props:\n * - `componentName`: Specifies whether a 'button' or 'icon' should be rendered. Default is 'button'.\n * - `label`: An optional label, which is only shown for Buttons.\n * - `icon`: The name of the icon (e.g., \"home\", \"edit\") or the Codicon class used for the icon display.\n * - `class`: Optional CSS class for additional styling customization.\n * - `buttonVariant`: Variant for the button component.\n * - `onClick`: Optional click handler for user interactions.\n *\n * Example usage:\n * ```tsx\n * <KolIconButtonFc componentName=\"button\" label=\"Submit\" icon=\"check\" onClick={handleClick} />\n * <KolIconButtonFc componentName=\"icon\" icon=\"alert\" onClick={handleClick} />\n * ```\n *\n * @param {IconButtonProps} props - The properties that customize the component, including the selection of the component type (Button or Icon) and other specific attributes.\n * @returns {JSX.Element} - The rendered JSX element (Button or Icon).\n */\nconst KolIconButtonFc: FC<IconButtonProps> = (props) => {\n\tconst { componentName = 'button', label, icon, onClick, ...other } = props;\n\tconst Component = componentName === 'button' ? KolButtonFc : KolIconFc;\n\n\treturn <Component label={label || ''} hideLabel icons={`codicon codicon-${icon}`} onClick={onClick} {...other} />;\n};\n\nexport default KolIconButtonFc;\n","import { h, type FunctionalComponent as FC } from '@stencil/core';\nimport {\n\ttype ButtonProps,\n\ttype IconOrIconClass,\n\ttype InputColorStates,\n\ttype InputEmailStates,\n\ttype InputFileStates,\n\ttype InputNumberStates,\n\ttype InputPasswordStates,\n\ttype InputRangeStates,\n\ttype InputTextStates,\n\ttype KoliBriHorizontalIcons,\n\ttype TextareaStates,\n\ttype SelectStates,\n\ttype MsgPropType,\n\ttype Stringified,\n} from '../../schema';\n\nimport KolInputContainerFc, { type InputContainerProps } from '../../functional-components/InputContainer';\nimport KolIconButtonFc from '../../functional-components/IconButton';\nimport { isObject, isString } from 'lodash-es';\n\ntype InputState =\n\t| TextareaStates\n\t| SelectStates\n\t| InputTextStates\n\t| InputEmailStates\n\t| InputPasswordStates\n\t| InputNumberStates\n\t| InputColorStates\n\t| InputFileStates\n\t| InputRangeStates;\n\nexport type InputContainerStateWrapperProps = Partial<InputContainerProps> & {\n\tstate: InputState;\n};\n\nfunction getInputContainerProps(state: InputState): {\n\ticons?: KoliBriHorizontalIcons;\n\tsmartButton?: ButtonProps;\n\tdisabled?: boolean;\n\tmsg?: Stringified<MsgPropType>;\n\ttouched?: boolean;\n} {\n\tlet icons: KoliBriHorizontalIcons | undefined = undefined;\n\tlet smartButton: ButtonProps | undefined;\n\n\tif ('_icons' in state) {\n\t\ticons = state._icons;\n\t}\n\n\tif ('_smartButton' in state) {\n\t\tsmartButton = state._smartButton;\n\t}\n\n\treturn {\n\t\ticons,\n\t\tsmartButton,\n\t\tdisabled: state._disabled,\n\t\tmsg: state._msg,\n\t\ttouched: state._touched,\n\t};\n}\n\nconst InputContainerStateWrapperFc: FC<InputContainerStateWrapperProps> = ({ state, endAdornment: defaultEndAdornment }, children) => {\n\tconst { icons, smartButton, disabled, msg, touched } = getInputContainerProps(state);\n\n\tlet leftIconProps: IconOrIconClass | undefined = icons?.left;\n\tif (isString(leftIconProps)) {\n\t\tleftIconProps = { icon: leftIconProps };\n\t}\n\n\tlet rightIconProps: IconOrIconClass | undefined = icons?.right;\n\tif (isString(rightIconProps)) {\n\t\trightIconProps = { icon: rightIconProps };\n\t}\n\n\tconst startAdornment = [];\n\tconst endAdornment = [];\n\n\tif (defaultEndAdornment) {\n\t\tif (Array.isArray(defaultEndAdornment)) {\n\t\t\tendAdornment.push(...defaultEndAdornment);\n\t\t} else {\n\t\t\tendAdornment.push(defaultEndAdornment);\n\t\t}\n\t}\n\n\tif (leftIconProps) {\n\t\tstartAdornment.push(<KolIconButtonFc componentName=\"icon\" class=\"kol-input-container__icon\" {...(isObject(leftIconProps) ? leftIconProps : {})} />);\n\t}\n\n\tif (isObject(smartButton)) {\n\t\tendAdornment.push(\n\t\t\t<KolIconButtonFc componentName=\"button\" class=\"kol-input-container__smart-button\" {...smartButton} hideLabel={true} disabled={disabled} />,\n\t\t);\n\t}\n\n\tif (rightIconProps) {\n\t\tendAdornment.push(<KolIconButtonFc componentName=\"icon\" class=\"kol-input-container__icon\" {...(isObject(rightIconProps) ? rightIconProps : {})} />);\n\t}\n\n\treturn (\n\t\t<KolInputContainerFc disabled={disabled} msg={msg} touched={touched} startAdornment={startAdornment} endAdornment={endAdornment}>\n\t\t\t{children}\n\t\t</KolInputContainerFc>\n\t);\n};\n\nexport default InputContainerStateWrapperFc;\n","import type { Generic } from 'adopted-style-sheets';\n\nimport type { IconsHorizontalPropType, NumberString } from '../../../schema';\nimport { watchValidator } from '../../../schema';\nimport { validateIcons } from '../../../schema';\n\nimport { InputController } from './controller';\n\nimport type { Props, Watches } from './types-icon';\n\nexport class InputIconController extends InputController implements Watches {\n\tprotected readonly component: Generic.Element.Component & Props;\n\tprivate readonly numberStringRegex = /^\\d+(\\.\\d+)?$/; // https://regex101.com/r/mET6Tx/1\n\n\tpublic constructor(component: Generic.Element.Component & Props, name: string, host?: HTMLElement) {\n\t\tsuper(component, name, host);\n\t\tthis.component = component;\n\t}\n\n\tpublic validateIcons(value?: IconsHorizontalPropType): void {\n\t\tvalidateIcons(this.component, value);\n\t}\n\n\tpublic isNumberString(value: unknown): value is NumberString {\n\t\treturn typeof value === 'string' && this.numberStringRegex.test(value);\n\t}\n\n\tprotected readonly parseToNumber = (value?: number | NumberString | null): number | null => {\n\t\tif (typeof value === 'number') {\n\t\t\treturn isNaN(value) ? null : value;\n\t\t}\n\t\tif (this.isNumberString(value)) {\n\t\t\treturn parseFloat(value);\n\t\t}\n\t\treturn null;\n\t};\n\n\tprotected readonly validateNumber = (propName: string, value?: number | NumberString | null) => {\n\t\treturn watchValidator(\n\t\t\tthis.component,\n\t\t\tpropName,\n\t\t\t(value): boolean =>\n\t\t\t\tvalue === undefined || value === null || typeof value === 'number' || (typeof value === 'string' && this.numberStringRegex.test(value)),\n\t\t\tnew Set(['number', 'NumberString']),\n\t\t\tvalue,\n\t\t\t{\n\t\t\t\thooks: {\n\t\t\t\t\tbeforePatch: (value: unknown, nextState) => {\n\t\t\t\t\t\tif (nextState?.has(propName)) {\n\t\t\t\t\t\t\tnextState?.set(propName, this.parseToNumber(value as number | NumberString | null));\n\t\t\t\t\t\t}\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t);\n\t};\n\n\tpublic componentWillLoad(): void {\n\t\tsuper.componentWillLoad();\n\t\tthis.validateIcons(this.component._icons);\n\t}\n}\n"],"names":["__rest","h","clsx","checkHasMsg","KolButtonWcTag","KolIconFc","isString","isObject","InputController","watchValidator","validateIcons"],"mappings":";;;;;;;;;;;;;;;;AAQA,MAAM,cAAc,GAA4B,CAAC,EAAkD,EAAE,QAAQ,KAAI;IAAhE,IAAA,EAAE,QAAQ,GAAG,OAAO,EAAE,KAAK,EAAE,SAAS,EAAA,GAAA,EAAY,EAAP,KAAK,GAAhDA,cAAA,CAAA,EAAA,EAAA,CAAA,UAAA,EAAA,OAAA,CAAkD,CAAF;IAChG,MAAM,aAAa,GAAG,CAAA,8BAAA,CAAgC;AACtD,IAAA,MAAM,iBAAiB,GAAG,CAAA,EAAG,aAAa,CAAK,EAAA,EAAA,QAAQ,EAAE;AAEzD,IAAA,QACCC,OAAK,CAAA,KAAA,EAAA,MAAA,CAAA,MAAA,CAAA,EAAA,KAAK,EAAEC,SAAI,CAAC,aAAa,EAAE,iBAAiB,EAAE,SAAS,CAAC,EAAM,EAAA,KAAK,GACtE,QAAQ,CACJ;AAER,CAAC;;ACGD,SAAS,QAAQ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AAI,CAAC,KAAK,CAAC,CAAC,EACxI,IAAI,GAAG,CAAC,CAAC,QAAQ,EAAE,cAAc,CAAC,CAAC,EACnC,KAAK,EACL;AACC,gBAAA,KAAK,EAAE;AACN,oBAAA,WAAW,EAAE,CAAC,KAAc,EAAE,SAAS,KAAI;wBAC1C,IAAI,SAAS,KAAT,IAAA,IAAA,SAAS,KAAT,MAAA,GAAA,MAAA,GAAA,SAAS,CAAE,GAAG,CAAC,QAAQ,CAAC,EAAE;AAC7B,4BAAA,SAAS,aAAT,SAAS,KAAA,MAAA,GAAA,MAAA,GAAT,SAAS,CAAE,GAAG,CAAC,QAAQ,EAAE,IAAI,CAAC,aAAa,CAAC,KAAqC,CAAC,CAAC;;qBAEpF;AACD,iBAAA;AACD,aAAA,CACD;AACF,SAAC;AAvCA,QAAA,IAAI,CAAC,SAAS,GAAG,SAAS;;AAGpB,IAAA,aAAa,CAAC,KAA+B,EAAA;AACnD,QAAAC,mBAAa,CAAC,IAAI,CAAC,SAAS,EAAE,KAAK,CAAC;;AAG9B,IAAA,cAAc,CAAC,KAAc,EAAA;AACnC,QAAA,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,IAAI,CAAC,iBAAiB,CAAC,IAAI,CAAC,KAAK,CAAC;;IAiChE,iBAAiB,GAAA;QACvB,KAAK,CAAC,iBAAiB,EAAE;QACzB,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC;;AAE1C;;;;;;"}
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- "use strict";var common=require("./common-Cd2qH809.js"),index=require("./index-BAxGQsCx.js");const initMeta=()=>{try{const e=common.getDocument();if(!e||"function"!=typeof e.querySelector)return;const o=e.querySelector('meta[name="kolibri"]');if(o&&o.hasAttribute("content")){const e=o.getAttribute("content");"string"==typeof e&&(common.setExperimentalMode(e.includes("experimental-mode=true")),common.setColorContrastAnalysis(e.includes("color-contrast-analysis=true")))}}catch(e){}},getKoliBri=()=>{let e=common.getWindow().KoliBri;return void 0===e&&(e={},Object.defineProperty(common.getWindow(),"KoliBri",{value:e,writable:!1})),e},initKoliBri=()=>{initMeta(),common.Log.debug(`\n,--. ,--. ,--. ,--. ,-----. ,--.\n| .' / ,---. | | \`--' | |) /_ ,--.--. \`--'\n| . ' | .-. | | | ,--. | .-. \\ | .--' ,--.\n| |\\ \\ | '-' | | | | | | '--' / | | | |\n\`--' \`--´ \`---´ \`--' \`--' \`------´ \`--' \`--'\n🚹 The accessible HTML-Standard | 👉 https://public-ui.github.io | ${index.Env.kolibriVersion}\n\t`,{forceLog:!0})},renderDevAdvice=()=>{!0!==getKoliBri().adviceShown&&(Object.defineProperty(getKoliBri(),"adviceShown",{get:function(){return!0}}),common.Log.debug("\nYou are using the KoliBri component library. If you have any suggestions for improvement or find a problem, please contact us:\n\nTicket: https://github.com/public-ui/kolibri/issues/new/choose (for privacy reasons, please use email)\nEmail: kolibri@itzbund.de\n"))};exports.nonce=()=>Math.floor(16777215*Math.random()).toString(16),common.isTestMode()&&(exports.nonce=()=>"nonce"),exports.initKoliBri=initKoliBri,exports.renderDevAdvice=renderDevAdvice;
4
+ "use strict";var common=require("./common-Cd2qH809.js"),index=require("./index-CMEXkCjL.js");const initMeta=()=>{try{const e=common.getDocument();if(!e||"function"!=typeof e.querySelector)return;const o=e.querySelector('meta[name="kolibri"]');if(o&&o.hasAttribute("content")){const e=o.getAttribute("content");"string"==typeof e&&(common.setExperimentalMode(e.includes("experimental-mode=true")),common.setColorContrastAnalysis(e.includes("color-contrast-analysis=true")))}}catch(e){}},getKoliBri=()=>{let e=common.getWindow().KoliBri;return void 0===e&&(e={},Object.defineProperty(common.getWindow(),"KoliBri",{value:e,writable:!1})),e},initKoliBri=()=>{initMeta(),common.Log.debug(`\n,--. ,--. ,--. ,--. ,-----. ,--.\n| .' / ,---. | | \`--' | |) /_ ,--.--. \`--'\n| . ' | .-. | | | ,--. | .-. \\ | .--' ,--.\n| |\\ \\ | '-' | | | | | | '--' / | | | |\n\`--' \`--´ \`---´ \`--' \`--' \`------´ \`--' \`--'\n🚹 The accessible HTML-Standard | 👉 https://public-ui.github.io | ${index.Env.kolibriVersion}\n\t`,{forceLog:!0})},renderDevAdvice=()=>{!0!==getKoliBri().adviceShown&&(Object.defineProperty(getKoliBri(),"adviceShown",{get:function(){return!0}}),common.Log.debug("\nYou are using the KoliBri component library. If you have any suggestions for improvement or find a problem, please contact us:\n\nTicket: https://github.com/public-ui/kolibri/issues/new/choose (for privacy reasons, please use email)\nEmail: kolibri@itzbund.de\n"))};exports.nonce=()=>Math.floor(16777215*Math.random()).toString(16),common.isTestMode()&&(exports.nonce=()=>"nonce"),exports.initKoliBri=initKoliBri,exports.renderDevAdvice=renderDevAdvice;
@@ -1 +1 @@
1
- {"version":3,"file":"dev.utils-C863Y3KX.js","sources":["src/utils/dev.utils.ts"],"sourcesContent":["import { Log, getDocument, isTestMode, setColorContrastAnalysis, setExperimentalMode } from '../schema';\n\nimport { getWindow } from '../schema';\nimport { Env } from '@stencil/core';\n\nconst initMeta = (): void => {\n\ttry {\n\t\tconst document = getDocument();\n\t\tif (!document || typeof document.querySelector !== 'function') {\n\t\t\treturn; // Skip meta initialization if document is not available\n\t\t}\n\n\t\tconst meta = document.querySelector('meta[name=\"kolibri\"]');\n\t\tif (meta && meta.hasAttribute('content')) {\n\t\t\tconst content = meta.getAttribute('content');\n\t\t\tif (typeof content === 'string') {\n\t\t\t\tsetExperimentalMode(content.includes('experimental-mode=true'));\n\t\t\t\tsetColorContrastAnalysis(content.includes('color-contrast-analysis=true'));\n\t\t\t}\n\t\t}\n\t} catch (error) {\n\t\t// Ignore meta initialization errors in test/SSR environments\n\t}\n};\n\nconst getKoliBri = (): Record<string, unknown> => {\n\tlet kolibri = getWindow().KoliBri;\n\tif (kolibri === undefined) {\n\t\tkolibri = {};\n\t\tObject.defineProperty(getWindow(), 'KoliBri', {\n\t\t\tvalue: kolibri,\n\t\t\twritable: false,\n\t\t});\n\t}\n\treturn kolibri;\n};\n\nexport { getKoliBri };\n\nexport const initKoliBri = (): void => {\n\tinitMeta();\n\tLog.debug(\n\t\t`\n,--. ,--. ,--. ,--. ,-----. ,--.\n| .' / ,---. | | \\`--' | |) /_ ,--.--. \\`--'\n| . ' | .-. | | | ,--. | .-. \\\\ | .--' ,--.\n| |\\\\ \\\\ | '-' | | | | | | '--' / | | | |\n\\`--' \\`--´ \\`---´ \\`--' \\`--' \\`------´ \\`--' \\`--'\n🚹 The accessible HTML-Standard | 👉 https://public-ui.github.io | ${Env.kolibriVersion}\n\t`,\n\t\t{\n\t\t\tforceLog: true,\n\t\t},\n\t);\n};\n\nexport const renderDevAdvice = (): void => {\n\tif (getKoliBri().adviceShown !== true) {\n\t\tObject.defineProperty(getKoliBri(), 'adviceShown', {\n\t\t\tget: function () {\n\t\t\t\treturn true;\n\t\t\t},\n\t\t});\n\t\tLog.debug(\n\t\t\t`\nYou are using the KoliBri component library. If you have any suggestions for improvement or find a problem, please contact us:\n\nTicket: https://github.com/public-ui/kolibri/issues/new/choose (for privacy reasons, please use email)\nEmail: kolibri@itzbund.de\n`,\n\t\t);\n\t}\n};\n\nlet nonce = (): string => Math.floor(Math.random() * 16777215).toString(16);\n\nif (isTestMode()) {\n\tnonce = (): string => 'nonce';\n}\n\nexport { nonce };\n"],"names":["getDocument","setExperimentalMode","setColorContrastAnalysis","getWindow","Log","Env","nonce","isTestMode"],"mappings":";;;;;;;;AAKA,MAAM,QAAQ,GAAG,MAAW;AAC3B,IAAA,IAAI;AACH,QAAA,MAAM,QAAQ,GAAGA,kBAAW,EAAE;QAC9B,IAAI,CAAC,QAAQ,IAAI,OAAO,QAAQ,CAAC,aAAa,KAAK,UAAU,EAAE;YAC9D;;QAGD,MAAM,IAAI,GAAG,QAAQ,CAAC,aAAa,CAAC,sBAAsB,CAAC;QAC3D,IAAI,IAAI,IAAI,IAAI,CAAC,YAAY,CAAC,SAAS,CAAC,EAAE;YACzC,M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IC,iBAAU,EAAE,EAAE;AACjB,IAAAD,aAAK,GAAG,MAAc,OAAO;AAC9B;;;;;"}
1
+ {"version":3,"file":"dev.utils-UE8Qk4FC.js","sources":["src/utils/dev.utils.ts"],"sourcesContent":["import { Log, getDocument, isTestMode, setColorContrastAnalysis, setExperimentalMode } from '../schema';\n\nimport { getWindow } from '../schema';\nimport { Env } from '@stencil/core';\n\nconst initMeta = (): void => {\n\ttry {\n\t\tconst document = getDocument();\n\t\tif (!document || typeof document.querySelector !== 'function') {\n\t\t\treturn; // Skip meta initialization if document is not available\n\t\t}\n\n\t\tconst meta = document.querySelector('meta[name=\"kolibri\"]');\n\t\tif (meta && meta.hasAttribute('content')) {\n\t\t\tconst content = meta.getAttribute('content');\n\t\t\tif (typeof content === 'string') {\n\t\t\t\tsetExperimentalMode(content.includes('experimental-mode=true'));\n\t\t\t\tsetColorContrastAnalysis(content.includes('color-contrast-analysis=true'));\n\t\t\t}\n\t\t}\n\t} catch (error) {\n\t\t// Ignore meta initialization errors in test/SSR environments\n\t}\n};\n\nconst getKoliBri = (): Record<string, unknown> => {\n\tlet kolibri = getWindow().KoliBri;\n\tif (kolibri === undefined) {\n\t\tkolibri = {};\n\t\tObject.defineProperty(getWindow(), 'KoliBri', {\n\t\t\tvalue: kolibri,\n\t\t\twritable: false,\n\t\t});\n\t}\n\treturn kolibri;\n};\n\nexport { getKoliBri };\n\nexport const initKoliBri = (): void => {\n\tinitMeta();\n\tLog.debug(\n\t\t`\n,--. ,--. ,--. ,--. ,-----. ,--.\n| .' / ,---. | | \\`--' | |) /_ ,--.--. \\`--'\n| . ' | .-. | | | ,--. | .-. \\\\ | .--' ,--.\n| |\\\\ \\\\ | '-' | | | | | | '--' / | | | |\n\\`--' \\`--´ \\`---´ \\`--' \\`--' \\`------´ \\`--' \\`--'\n🚹 The accessible HTML-Standard | 👉 https://public-ui.github.io | ${Env.kolibriVersion}\n\t`,\n\t\t{\n\t\t\tforceLog: true,\n\t\t},\n\t);\n};\n\nexport const renderDevAdvice = (): void => {\n\tif (getKoliBri().adviceShown !== true) {\n\t\tObject.defineProperty(getKoliBri(), 'adviceShown', {\n\t\t\tget: function () {\n\t\t\t\treturn true;\n\t\t\t},\n\t\t});\n\t\tLog.debug(\n\t\t\t`\nYou are using the KoliBri component library. If you have any suggestions for improvement or find a problem, please contact us:\n\nTicket: https://github.com/public-ui/kolibri/issues/new/choose (for privacy reasons, please use email)\nEmail: kolibri@itzbund.de\n`,\n\t\t);\n\t}\n};\n\nlet nonce = (): string => Math.floor(Math.random() * 16777215).toString(16);\n\nif (isTestMode()) {\n\tnonce = (): string => 'nonce';\n}\n\nexport { nonce };\n"],"names":["getDocument","setExperimentalMode","setColorContrastAnalysis","getWindow","Log","Env","nonce","isTestMode"],"mappings":";;;;;;;;AAKA,MAAM,QAAQ,GAAG,MAAW;AAC3B,IAAA,IAAI;AACH,QAAA,MAAM,QAAQ,GAAGA,kBAAW,EAAE;QAC9B,IAAI,CAAC,QAAQ,IAAI,OAAO,QAAQ,CAAC,aAAa,KAAK,UAAU,EAAE;YAC9D;;QAGD,MAAM,IAAI,GAAG,QAAQ,CAAC,aAAa,CAAC,sBAAsB,CAAC;QAC3D,IAAI,IAAI,IAAI,IAAI,CAAC,YAAY,CAAC,SAAS,CAAC,EAAE;YACzC,MAAM,OAAO,GAAG,IAAI,CAAC,YAAY,CAAC,SAAS,CAAC;AAC5C,YAAA,IAAI,OAAO,OAAO,KAAK,QAAQ,EAAE;gBAChCC,0BAAmB,CAAC,OAAO,CAAC,QAAQ,CAAC,wBAAwB,CAAC,CAAC;gBAC/DC,+BAAwB,CAAC,OAAO,CAAC,QAAQ,CAAC,8BAA8B,CAAC,CAAC;;;;IAG3E,OAAO,KAAK,EAAE;;AAGjB,CAAC;AAED,MAAM,UAAU,GAAG,MAA8B;AAChD,IAAA,IAAI,OAAO,GAAGC,gBAAS,EAAE,CAAC,OAAO;AACjC,IAAA,IAAI,OAAO,KAAK,SAAS,EAAE;QAC1B,OAAO,GAAG,EAAE;AACZ,QAAA,MAAM,CAAC,cAAc,CAACA,gBAAS,EAAE,EAAE,SAAS,EAAE;AAC7C,YAAA,KAAK,EAAE,OAAO;AACd,YAAA,QAAQ,EAAE,KAAK;AACf,SAAA,CAAC;;AAEH,IAAA,OAAO,OAAO;AACf,CAAC;AAIM,MAAM,WAAW,GAAG,MAAW;AACrC,IAAA,QAAQ,EAAE;IACVC,UAAG,CAAC,KAAK,CACR;;;;;;AAMmE,mEAAA,EAAAC,SAAG,CAAC,cAAc;EACrF,EACA;AACC,QAAA,QAAQ,EAAE,IAAI;AACd,KAAA,CACD;AACF;AAEO,MAAM,eAAe,GAAG,MAAW;AACzC,IAAA,IAAI,UAAU,EAAE,CAAC,WAAW,KAAK,IAAI,EAAE;AACtC,QAAA,MAAM,CAAC,cAAc,CAAC,UAAU,EAAE,EAAE,aAAa,EAAE;AAClD,YAAA,GAAG,EAAE,YAAA;AACJ,gBAAA,OAAO,IAAI;aACX;AACD,SAAA,CAAC;QACFD,UAAG,CAAC,KAAK,CACR;;;;;AAKF,CAAA,CACE;;AAEH;AAEIE,aAAK,GAAG,MAAc,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,EAAE,GAAG,QAAQ,CAAC,CAAC,QAAQ,CAAC,EAAE;AAE1E,IAAIC,iBAAU,EAAE,EAAE;AACjB,IAAAD,aAAK,GAAG,MAAc,OAAO;AAC9B;;;;;"}
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- "use strict";var common=require("./common-Cd2qH809.js"),dev_utils=require("./dev.utils-C863Y3KX.js");require("./index-BAxGQsCx.js");const getKoliBri=()=>{let o=common.getWindow().KoliBri;return void 0===o&&(o={},Object.defineProperty(common.getWindow(),"KoliBri",{value:o,writable:!1})),o};function prototypeKoliBri(o,t){try{Object.defineProperty(getKoliBri(),o,{get:function(){return t}})}catch(t){common.Log.debug(`KoliBri property ${o} is already bind.`)}}const metaModeLog=(o,t)=>common.Log.debug(`${o} ${t?"":"not "}activated`),initialize=()=>{if(dev_utils.initKoliBri(),common.isDevMode()&&(dev_utils.renderDevAdvice(),prototypeKoliBri("a11yColorContrast",common.koliBriA11yColorContrast),prototypeKoliBri("querySelector",common.koliBriQuerySelector),prototypeKoliBri("querySelectorAll",common.koliBriQuerySelectorAll),prototypeKoliBri("querySelectorColors",common.koliBriQuerySelectorColors),prototypeKoliBri("utils",function(){return common.KoliBriUtils}),prototypeKoliBri("parseJson",common.parseJson),prototypeKoliBri("stringifyJson",common.stringifyJson),metaModeLog("Development mode",common.isDevMode()),metaModeLog("Experimental mode",common.getExperimentalMode()),metaModeLog("Color contrast analysis",common.getColorContrastAnalysis()),setTimeout(()=>{try{const o=common.getDocument(),t=null==o?void 0:o.body;if(o&&t&&"function"==typeof o.createElement){const e=o.createElement("svg");e.setAttribute("aria-label","KoliBri-DevTools"),e.setAttribute("xmlns","http://www.w3.org/2000/svg"),e.setAttribute("role","toolbar"),e.setAttribute("style","position: fixed;color: black;font-size: 200%;bottom: 0.25rem;right: 0.25rem;"),e.innerHTML='<svg\n xmlns="http://www.w3.org/2000/svg"\n width="50"\n height="50"\n viewBox="0 0 600 600"\n>\n <path d="M353 322L213 304V434L353 322Z" fill="#047" />\n <path d="M209 564V304L149 434L209 564Z" fill="#047" />\n <path d="M357 316L417 250L361 210L275 244L357 316Z" fill="#047" />\n <path d="M353 318L35 36L213 300L353 318Z" fill="#047" />\n <path d="M329 218L237 92L250 222L272 241L329 218Z" fill="#047" />\n <path d="M391 286L565 272L421 252L391 286Z" fill="#047" />\n</svg>',t.appendChild(e)}}catch(o){common.Log.debug(["Could not initialize DevTools UI (likely in SSR/test environment):",o])}},100),common.getColorContrastAnalysis())){const o=setTimeout(()=>{clearTimeout(o);try{const o=common.getDocument(),t=null==o?void 0:o.body;o&&t&&"function"==typeof o.createElement&&setInterval(()=>{common.KoliBriUtils.queryHtmlElementColors(o.createElement("div"),common.koliBriA11yColorContrast(t),!1,!1)},1e4)}catch(o){common.Log.debug(["Could not initialize color contrast analysis:",o])}},2500)}};exports.initialize=initialize;
4
+ "use strict";var common=require("./common-Cd2qH809.js"),dev_utils=require("./dev.utils-UE8Qk4FC.js");require("./index-CMEXkCjL.js");const getKoliBri=()=>{let o=common.getWindow().KoliBri;return void 0===o&&(o={},Object.defineProperty(common.getWindow(),"KoliBri",{value:o,writable:!1})),o};function prototypeKoliBri(o,t){try{Object.defineProperty(getKoliBri(),o,{get:function(){return t}})}catch(t){common.Log.debug(`KoliBri property ${o} is already bind.`)}}const metaModeLog=(o,t)=>common.Log.debug(`${o} ${t?"":"not "}activated`),initialize=()=>{if(dev_utils.initKoliBri(),common.isDevMode()&&(dev_utils.renderDevAdvice(),prototypeKoliBri("a11yColorContrast",common.koliBriA11yColorContrast),prototypeKoliBri("querySelector",common.koliBriQuerySelector),prototypeKoliBri("querySelectorAll",common.koliBriQuerySelectorAll),prototypeKoliBri("querySelectorColors",common.koliBriQuerySelectorColors),prototypeKoliBri("utils",function(){return common.KoliBriUtils}),prototypeKoliBri("parseJson",common.parseJson),prototypeKoliBri("stringifyJson",common.stringifyJson),metaModeLog("Development mode",common.isDevMode()),metaModeLog("Experimental mode",common.getExperimentalMode()),metaModeLog("Color contrast analysis",common.getColorContrastAnalysis()),setTimeout(()=>{try{const o=common.getDocument(),t=null==o?void 0:o.body;if(o&&t&&"function"==typeof o.createElement){const e=o.createElement("svg");e.setAttribute("aria-label","KoliBri-DevTools"),e.setAttribute("xmlns","http://www.w3.org/2000/svg"),e.setAttribute("role","toolbar"),e.setAttribute("style","position: fixed;color: black;font-size: 200%;bottom: 0.25rem;right: 0.25rem;"),e.innerHTML='<svg\n xmlns="http://www.w3.org/2000/svg"\n width="50"\n height="50"\n viewBox="0 0 600 600"\n>\n <path d="M353 322L213 304V434L353 322Z" fill="#047" />\n <path d="M209 564V304L149 434L209 564Z" fill="#047" />\n <path d="M357 316L417 250L361 210L275 244L357 316Z" fill="#047" />\n <path d="M353 318L35 36L213 300L353 318Z" fill="#047" />\n <path d="M329 218L237 92L250 222L272 241L329 218Z" fill="#047" />\n <path d="M391 286L565 272L421 252L391 286Z" fill="#047" />\n</svg>',t.appendChild(e)}}catch(o){common.Log.debug(["Could not initialize DevTools UI (likely in SSR/test environment):",o])}},100),common.getColorContrastAnalysis())){const o=setTimeout(()=>{clearTimeout(o);try{const o=common.getDocument(),t=null==o?void 0:o.body;o&&t&&"function"==typeof o.createElement&&setInterval(()=>{common.KoliBriUtils.queryHtmlElementColors(o.createElement("div"),common.koliBriA11yColorContrast(t),!1,!1)},1e4)}catch(o){common.Log.debug(["Could not initialize color contrast analysis:",o])}},2500)}};exports.initialize=initialize;
@@ -1 +1 @@
1
- {"version":3,"file":"devtools-D2vBkrTT.js","sources":["src/global/devtools.ts"],"sourcesContent":["import {\n\tgetColorContrastAnalysis,\n\tisDevMode,\n\tgetDocument,\n\tgetExperimentalMode,\n\tgetWindow,\n\tkoliBriA11yColorContrast,\n\tkoliBriQuerySelector,\n\tkoliBriQuerySelectorAll,\n\tkoliBriQuerySelectorColors,\n\tKoliBriUtils,\n\tLog,\n\tparseJson,\n\tstringifyJson,\n} from '../schema';\nimport { initKoliBri, renderDevAdvice } from '../utils/dev.utils';\n\nconst getKoliBri = (): Record<string, unknown> => {\n\tlet kolibri = getWindow().KoliBri;\n\tif (kolibri === undefined) {\n\t\tkolibri = {};\n\t\tObject.defineProperty(getWindow(), 'KoliBri', {\n\t\t\tvalue: kolibri,\n\t\t\twritable: false,\n\t\t});\n\t}\n\treturn kolibri;\n};\n\nfunction prototypeKoliBri<T>(name: string, cb: T) {\n\ttry {\n\t\tObject.defineProperty(getKoliBri(), name, {\n\t\t\tget: function () {\n\t\t\t\treturn cb;\n\t\t\t},\n\t\t});\n\t} catch (e) {\n\t\tLog.debug(`KoliBri property ${name} is already bind.`);\n\t}\n}\n\nconst metaModeLog = (name: string, active: boolean) => Log.debug(`${name} ${active ? '' : 'not '}activated`);\n\nexport const initialize = (): void => {\n\tinitKoliBri();\n\tif (isDevMode()) {\n\t\trenderDevAdvice();\n\n\t\tprototypeKoliBri('a11yColorContrast', koliBriA11yColorContrast);\n\t\tprototypeKoliBri('querySelector', koliBriQuerySelector);\n\t\tprototypeKoliBri('querySelectorAll', koliBriQuerySelectorAll);\n\t\tprototypeKoliBri('querySelectorColors', koliBriQuerySelectorColors);\n\t\tprototypeKoliBri('utils', function () {\n\t\t\treturn KoliBriUtils;\n\t\t});\n\t\tprototypeKoliBri('parseJson', parseJson);\n\t\tprototypeKoliBri('stringifyJson', stringifyJson);\n\n\t\tmetaModeLog('Development mode', isDevMode());\n\t\tmetaModeLog('Experimental mode', getExperimentalMode());\n\t\tmetaModeLog('Color contrast analysis', getColorContrastAnalysis());\n\n\t\t// Delay DOM manipulation to ensure document is ready\n\t\tsetTimeout(() => {\n\t\t\ttry {\n\t\t\t\tconst document = getDocument();\n\t\t\t\tconst body = document?.body;\n\n\t\t\t\t// Only proceed if we have a valid document and body\n\t\t\t\tif (document && body && typeof document.createElement === 'function') {\n\t\t\t\t\tconst div = document.createElement('svg');\n\t\t\t\t\tdiv.setAttribute('aria-label', 'KoliBri-DevTools');\n\t\t\t\t\tdiv.setAttribute('xmlns', 'http://www.w3.org/2000/svg');\n\t\t\t\t\tdiv.setAttribute('role', 'toolbar');\n\t\t\t\t\tdiv.setAttribute('style', 'position: fixed;color: black;font-size: 200%;bottom: 0.25rem;right: 0.25rem;');\n\t\t\t\t\tdiv.innerHTML = `<svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"50\"\n height=\"50\"\n viewBox=\"0 0 600 600\"\n>\n <path d=\"M353 322L213 304V434L353 322Z\" fill=\"#047\" />\n <path d=\"M209 564V304L149 434L209 564Z\" fill=\"#047\" />\n <path d=\"M357 316L417 250L361 210L275 244L357 316Z\" fill=\"#047\" />\n <path d=\"M353 318L35 36L213 300L353 318Z\" fill=\"#047\" />\n <path d=\"M329 218L237 92L250 222L272 241L329 218Z\" fill=\"#047\" />\n <path d=\"M391 286L565 272L421 252L391 286Z\" fill=\"#047\" />\n</svg>`;\n\n\t\t\t\t\tbody.appendChild(div);\n\t\t\t\t}\n\t\t\t} catch (error) {\n\t\t\t\tLog.debug(['Could not initialize DevTools UI (likely in SSR/test environment):', error]);\n\t\t\t}\n\t\t}, 100);\n\n\t\tif (getColorContrastAnalysis()) {\n\t\t\tconst timeout = setTimeout(() => {\n\t\t\t\tclearTimeout(timeout);\n\t\t\t\ttry {\n\t\t\t\t\tconst document = getDocument();\n\t\t\t\t\tconst body = document?.body;\n\t\t\t\t\tif (document && body && typeof document.createElement === 'function') {\n\t\t\t\t\t\tsetInterval(() => {\n\t\t\t\t\t\t\tKoliBriUtils.queryHtmlElementColors(document.createElement('div'), koliBriA11yColorContrast(body), false, false);\n\t\t\t\t\t\t}, 10000);\n\t\t\t\t\t}\n\t\t\t\t} catch (error) {\n\t\t\t\t\tLog.debug(['Could not initialize color contrast analysis:', error]);\n\t\t\t\t}\n\t\t\t}, 2500);\n\t\t}\n\n\t\t// setTimeout(() => {\n\t\t// const kolButton = koliBriQuerySelector<HTMLButtonElement>(document, '[_label=\"Aktion ausführen\"]');\n\t\t// if (kolButton) {\n\t\t// const button = koliBriQuerySelector<HTMLButtonElement>(kolButton?.shadowRoot as ShadowRoot, 'button');\n\t\t// if (button) {\n\t\t// kolButton.style.backgroundColor = '#988';\n\t\t// button.style.backgroundColor = 'inherit';\n\t\t// button.style.color = '#988';\n\t\t// const kolButtonColors = koliBriQuerySelectorColors('[_label=\"Aktion ausführen\"]');\n\t\t// console.log(\n\t\t// koliBriQuerySelectorColors('button', {\n\t\t// ...kolButtonColors,\n\t\t// })\n\t\t// );\n\t\t// }\n\t\t// }\n\t\t// }, 2500);\n\t}\n};\n"],"names":["getWindow","Log","initKoliBri","isDevMode","renderDevAdvice","koliBriA11yColorContrast","koliBriQuerySelector","koliBriQuerySelectorAll","koliBriQuerySelectorColors","KoliBriUtils","parseJson","stringifyJson","getExperimentalMode","getColorContr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AC,MAAK;gBAC/B,YAAY,CAAC,OAAO,CAAC;AACrB,gBAAA,IAAI;AACH,oBAAA,MAAM,QAAQ,GAAGC,kBAAW,EAAE;oBAC9B,MAAM,IAAI,GAAG,QAAQ,KAAA,IAAA,IAAR,QAAQ,KAAR,MAAA,GAAA,MAAA,GAAA,QAAQ,CAAE,IAAI;oBAC3B,IAAI,QAAQ,IAAI,IAAI,IAAI,OAAO,QAAQ,CAAC,aAAa,KAAK,UAAU,EAAE;wBACrE,WAAW,CAAC,MAAK;AAChB,4BAAAL,mBAAY,CAAC,sBAAsB,CAAC,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,EAAEJ,+BAAwB,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,KAAK,CAAC;yBAChH,EAAE,KAAK,CAAC;;;gBAET,OAAO,KAAK,EAAE;oBACfJ,UAAG,CAAC,KAAK,CAAC,CAAC,+CAA+C,EAAE,KAAK,CAAC,CAAC;;aAEpE,EAAE,IAAI,CAAC;;;AAqBX;;;;"}
1
+ {"version":3,"file":"devtools-DaWRMPjB.js","sources":["src/global/devtools.ts"],"sourcesContent":["import {\n\tgetColorContrastAnalysis,\n\tisDevMode,\n\tgetDocument,\n\tgetExperimentalMode,\n\tgetWindow,\n\tkoliBriA11yColorContrast,\n\tkoliBriQuerySelector,\n\tkoliBriQuerySelectorAll,\n\tkoliBriQuerySelectorColors,\n\tKoliBriUtils,\n\tLog,\n\tparseJson,\n\tstringifyJson,\n} from '../schema';\nimport { initKoliBri, renderDevAdvice } from '../utils/dev.utils';\n\nconst getKoliBri = (): Record<string, unknown> => {\n\tlet kolibri = getWindow().KoliBri;\n\tif (kolibri === undefined) {\n\t\tkolibri = {};\n\t\tObject.defineProperty(getWindow(), 'KoliBri', {\n\t\t\tvalue: kolibri,\n\t\t\twritable: false,\n\t\t});\n\t}\n\treturn kolibri;\n};\n\nfunction prototypeKoliBri<T>(name: string, cb: T) {\n\ttry {\n\t\tObject.defineProperty(getKoliBri(), name, {\n\t\t\tget: function () {\n\t\t\t\treturn cb;\n\t\t\t},\n\t\t});\n\t} catch (e) {\n\t\tLog.debug(`KoliBri property ${name} is already bind.`);\n\t}\n}\n\nconst metaModeLog = (name: string, active: boolean) => Log.debug(`${name} ${active ? '' : 'not '}activated`);\n\nexport const initialize = (): void => {\n\tinitKoliBri();\n\tif (isDevMode()) {\n\t\trenderDevAdvice();\n\n\t\tprototypeKoliBri('a11yColorContrast', koliBriA11yColorContrast);\n\t\tprototypeKoliBri('querySelector', koliBriQuerySelector);\n\t\tprototypeKoliBri('querySelectorAll', koliBriQuerySelectorAll);\n\t\tprototypeKoliBri('querySelectorColors', koliBriQuerySelectorColors);\n\t\tprototypeKoliBri('utils', function () {\n\t\t\treturn KoliBriUtils;\n\t\t});\n\t\tprototypeKoliBri('parseJson', parseJson);\n\t\tprototypeKoliBri('stringifyJson', stringifyJson);\n\n\t\tmetaModeLog('Development mode', isDevMode());\n\t\tmetaModeLog('Experimental mode', getExperimentalMode());\n\t\tmetaModeLog('Color contrast analysis', getColorContrastAnalysis());\n\n\t\t// Delay DOM manipulation to ensure document is ready\n\t\tsetTimeout(() => {\n\t\t\ttry {\n\t\t\t\tconst document = getDocument();\n\t\t\t\tconst body = document?.body;\n\n\t\t\t\t// Only proceed if we have a valid document and body\n\t\t\t\tif (document && body && typeof document.createElement === 'function') {\n\t\t\t\t\tconst div = document.createElement('svg');\n\t\t\t\t\tdiv.setAttribute('aria-label', 'KoliBri-DevTools');\n\t\t\t\t\tdiv.setAttribute('xmlns', 'http://www.w3.org/2000/svg');\n\t\t\t\t\tdiv.setAttribute('role', 'toolbar');\n\t\t\t\t\tdiv.setAttribute('style', 'position: fixed;color: black;font-size: 200%;bottom: 0.25rem;right: 0.25rem;');\n\t\t\t\t\tdiv.innerHTML = `<svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"50\"\n height=\"50\"\n viewBox=\"0 0 600 600\"\n>\n <path d=\"M353 322L213 304V434L353 322Z\" fill=\"#047\" />\n <path d=\"M209 564V304L149 434L209 564Z\" fill=\"#047\" />\n <path d=\"M357 316L417 250L361 210L275 244L357 316Z\" fill=\"#047\" />\n <path d=\"M353 318L35 36L213 300L353 318Z\" fill=\"#047\" />\n <path d=\"M329 218L237 92L250 222L272 241L329 218Z\" fill=\"#047\" />\n <path d=\"M391 286L565 272L421 252L391 286Z\" fill=\"#047\" />\n</svg>`;\n\n\t\t\t\t\tbody.appendChild(div);\n\t\t\t\t}\n\t\t\t} catch (error) {\n\t\t\t\tLog.debug(['Could not initialize DevTools UI (likely in SSR/test environment):', error]);\n\t\t\t}\n\t\t}, 100);\n\n\t\tif (getColorContrastAnalysis()) {\n\t\t\tconst timeout = setTimeout(() => {\n\t\t\t\tclearTimeout(timeout);\n\t\t\t\ttry {\n\t\t\t\t\tconst document = getDocument();\n\t\t\t\t\tconst body = document?.body;\n\t\t\t\t\tif (document && body && typeof document.createElement === 'function') {\n\t\t\t\t\t\tsetInterval(() => {\n\t\t\t\t\t\t\tKoliBriUtils.queryHtmlElementColors(document.createElement('div'), koliBriA11yColorContrast(body), false, false);\n\t\t\t\t\t\t}, 10000);\n\t\t\t\t\t}\n\t\t\t\t} catch (error) {\n\t\t\t\t\tLog.debug(['Could not initialize color contrast analysis:', error]);\n\t\t\t\t}\n\t\t\t}, 2500);\n\t\t}\n\n\t\t// setTimeout(() => {\n\t\t// const kolButton = koliBriQuerySelector<HTMLButtonElement>(document, '[_label=\"Aktion ausführen\"]');\n\t\t// if (kolButton) {\n\t\t// const button = koliBriQuerySelector<HTMLButtonElement>(kolButton?.shadowRoot as ShadowRoot, 'button');\n\t\t// if (button) {\n\t\t// kolButton.style.backgroundColor = '#988';\n\t\t// button.style.backgroundColor = 'inherit';\n\t\t// button.style.color = '#988';\n\t\t// const kolButtonColors = koliBriQuerySelectorColors('[_label=\"Aktion ausführen\"]');\n\t\t// console.log(\n\t\t// koliBriQuerySelectorColors('button', {\n\t\t// ...kolButtonColors,\n\t\t// })\n\t\t// );\n\t\t// }\n\t\t// }\n\t\t// }, 2500);\n\t}\n};\n"],"names":["getWindow","Log","initKoliBri","isDevMode","renderDevAdvice","koliBriA11yColorContrast","koliBriQuerySelector","koliBriQuerySelectorAll","koliBriQuerySelectorColors","KoliBriUtils","parseJson","stringifyJson","getExperimentalMode","getColorContrastAnalysis","getDocument"],"mappings":";;;;;;;;;AAiBA,MAAM,UAAU,GAAG,MAA8B;AAChD,IAAA,IAAI,OAAO,GAAGA,gBAAS,EAAE,CAAC,OAAO;AACjC,IAAA,IAAI,OAAO,KAAK,SAAS,EAAE;QAC1B,OAAO,GAAG,EAAE;AACZ,QAAA,MAAM,CAAC,cAAc,CAACA,gBAAS,EAAE,EAAE,SAAS,EAAE;AAC7C,YAAA,KAAK,EAAE,OAAO;AACd,YAAA,QAAQ,EAAE,KAAK;AACf,SAAA,CAAC;;AAEH,IAAA,OAAO,OAAO;AACf,CAAC;AAED,SAAS,gBAAgB,CAAI,IAAY,EAAE,EAAK,EAAA;AAC/C,IAAA,IAAI;AACH,QAAA,MAAM,CAAC,cAAc,CAAC,UAAU,EAAE,EAAE,IAAI,EAAE;AACzC,YAAA,GAAG,EAAE,YAAA;AACJ,gBAAA,OAAO,EAAE;aACT;AACD,SAAA,CAAC;;IACD,OAAO,CAAC,EAAE;AACX,QAAAC,UAAG,CAAC,KAAK,CAAC,oBAAoB,IAAI,CAAA,iBAAA,CAAmB,CAAC;;AAExD;AAEA,MAAM,WAAW,GAAG,CAAC,IAAY,EAAE,MAAe,KAAKA,UAAG,CAAC,KAAK,CAAC,CAAG,EAAA,IAAI,CAAI,CAAA,EAAA,MAAM,GAAG,EAAE,GAAG,MAAM,CAAW,SAAA,CAAA,CAAC;AAErG,MAAM,UAAU,GAAG,MAAW;AACpC,IAAAC,qBAAW,EAAE;IACb,IAAIC,gBAAS,EAAE,EAAE;AAChB,QAAAC,yBAAe,EAAE;AAEjB,QAAA,gBAAgB,CAAC,mBAAmB,EAAEC,+BAAwB,CAAC;AAC/D,Q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AErB,OAAO,KAAK,EAAE;gBACfb,UAAG,CAAC,KAAK,CAAC,CAAC,oEAAoE,EAAE,KAAK,CAAC,CAAC;;SAEzF,EAAE,GAAG,CAAC;QAEP,IAAIY,+BAAwB,EAAE,EAAE;AAC/B,YAAA,MAAM,OAAO,GAAG,UAAU,CAAC,MAAK;gBAC/B,YAAY,CAAC,OAAO,CAAC;AACrB,gBAAA,IAAI;AACH,oBAAA,MAAM,QAAQ,GAAGC,kBAAW,EAAE;oBAC9B,MAAM,IAAI,GAAG,QAAQ,KAAA,IAAA,IAAR,QAAQ,KAAR,MAAA,GAAA,MAAA,GAAA,QAAQ,CAAE,IAAI;oBAC3B,IAAI,QAAQ,IAAI,IAAI,IAAI,OAAO,QAAQ,CAAC,aAAa,KAAK,UAAU,EAAE;wBACrE,WAAW,CAAC,MAAK;AAChB,4BAAAL,mBAAY,CAAC,sBAAsB,CAAC,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,EAAEJ,+BAAwB,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,KAAK,CAAC;yBAChH,EAAE,KAAK,CAAC;;;gBAET,OAAO,KAAK,EAAE;oBACfJ,UAAG,CAAC,KAAK,CAAC,CAAC,+CAA+C,EAAE,KAAK,CAAC,CAAC;;aAEpE,EAAE,IAAI,CAAC;;;AAqBX;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"i18n-Drgbs46L.js","sources":["src/locales/de.ts","src/locales/en.ts","src/core/i18n.ts"],"sourcesContent":["export default {\n\terror: 'Fehler',\n\twarning: 'Warnung',\n\tinfo: 'Hinweis',\n\tsuccess: 'Erfolg',\n\tmessage: 'Nachricht',\n\tclose: 'Schließen',\n\t'form-description': 'Formular-Felder, die mit einem Sternchen (*) gekennzeichnet sind, sind Pflichtangaben.',\n\tnew: 'Neu',\n\t'no-entries': 'Es sind keine Einträge vorhanden.',\n\t'change-order': 'Sortierung von {{colLabel}} ändern',\n\t'action-running': 'Aktion wird ausgeführt...',\n\t'action-done': 'Aktion abgeschlossen',\n\tpagination: 'Paginierung',\n\t'page-first': 'Direkt zur ersten Seite',\n\t'page-back': 'Eine Seite zurück',\n\t'page-next': 'Eine Seite weiter',\n\t'page-last': 'Direkt zur letzten Seite',\n\t'entries-per-site': 'Einträge pro Seite',\n\tpage: 'Seite',\n\t'page-current': 'Seite {{page}}',\n\t'page-selected': 'Seite {{page}} ist ausgewählt',\n\t'page-per-site': '{{entries}} Einträge pro Seite',\n\t'nav-maximize': 'Navigation maximieren',\n\t'nav-minimize': 'Navigation minimieren',\n\t'logo-description': 'Logo {{orgShort}}. Bundesadler mit Flaggenstab und Schriftzug {{orgLong}}',\n\t'open-link-in-tab': 'Öffnet in neuem Tab.',\n\t'kolibri-logo': 'Logo von KoliBri',\n\t'table-pagination-label': 'Paginierung für die Tabelle {{label}}',\n\t'avatar-alt': 'Avatar von {{name}}',\n\t'split-button-dropdown-label-open': 'Optionen anzeigen',\n\t'split-button-dropdown-label-close': 'Optionen schließen',\n\t'toast-close-all': 'Alle schließen',\n\t'error-list': 'Fehlerliste',\n\t'error-list-message': 'Bitte korrigieren Sie folgende Fehler:',\n\tversion: 'Versionsnummer',\n\t'table-visible-range': 'Einträge {{start}} bis {{end}} von {{total}}',\n\t'table-selection-all': 'Alle auswählen',\n\t'table-selection-none': 'Alle abwählen',\n\t'table-selection-indeterminate': 'Alle auswählen bei teilweiser Auswahl',\n\t'table-settings': 'Tabellenkonfiguration',\n\t'table-settings-cancel': 'Abbrechen',\n\t'table-settings-apply': 'Übernehmen',\n\t'table-settings-show-column': 'Spalte {{column}} anzeigen',\n\t'table-settings-column-width': 'Breite von {{column}}',\n\t'table-settings-move-up': 'Spalte {{column}} nach oben verschieben',\n\t'table-settings-move-down': 'Spalte {{column}} nach unten verschieben',\n\t'table-settings-error-all-invisible': 'Mindestens eine Spalte muss sichtbar sein.',\n\t'table-settings-column-not-hidable': 'nicht ausblendbar',\n\tdropdown: 'Auswahlliste',\n\t'nav-label-open': 'Untermenü zu {{label}} öffnen',\n\t'nav-label-close': 'Untermenü zu {{label}} schließen',\n\t'close-alert': 'Benachrichtigung schließen',\n\t'show-password': 'einblenden',\n\t'hide-password': 'ausblenden',\n\t'no-results-message': 'Keine Ergebnisse gefunden.',\n\t'delete-selection': 'Auswahl entfernen',\n\t'filename-text': 'Datei auswählen oder hier ablegen...',\n\t'data-browse-text': 'Datei auswählen',\n\tsort: 'sortieren',\n\t'pagination-position-top': 'oben',\n\t'pagination-position-bottom': 'unten',\n\t'character-limit-hint': 'Es können bis zu {{limit}} Zeichen eingegeben werden.',\n\t'character-limit-remaining': 'Es sind noch {{remaining}} Zeichen verfügbar.',\n\t'character-limit-exceeded': 'Es sind {{over}} Zeichen zu viel.',\n\t'character-counter-current': '{{current}} Zeichen',\n\t'character-counter-current-of-max': '{{current}}/{{max}} Zeichen',\n\t'character-counter-current-of-max-aria': '{{current}} von {{max}} Zeichen',\n};\n","export default {\n\terror: 'Error',\n\twarning: 'Warning',\n\tinfo: 'Note',\n\tsuccess: 'Success',\n\tmessage: 'Message',\n\tclose: 'Close',\n\t'form-description': 'Form fields marked with an asterisk (*) are mandatory.',\n\tnew: 'New',\n\t'no-entries': 'No entries available.',\n\t'change-order': 'Change order of {{colLabel}}',\n\t'action-running': 'Action is running...',\n\t'action-done': 'Action done',\n\tpagination: 'Pagination',\n\t'page-first': 'Directly to the first page',\n\t'page-back': 'One page back',\n\t'page-next': 'One page further',\n\t'page-last': 'Directly to the last page',\n\t'entries-per-site': 'Entries per page',\n\tpage: 'Page',\n\t'page-current': 'Page {{page}}',\n\t'page-selected': 'Page {{page}} is selected',\n\t'page-per-site': '{{entries}} entries per page',\n\t'nav-maximize': 'Maximize navigation',\n\t'nav-minimize': 'Minimize navigation',\n\t'logo-description': 'Logo {{orgShort}}. Federal eagle with flag staff and lettering {{orgLong}}',\n\t'open-link-in-tab': 'Opens in new tab.',\n\t'kolibri-logo': 'KoliBri logo',\n\t'table-pagination-label': 'Pagination for table {{label}}',\n\t'avatar-alt': 'Avatar of {{name}}',\n\t'split-button-dropdown-label-open': 'Show options',\n\t'split-button-dropdown-label-close': 'Hide options',\n\t'toast-close-all': 'Close all',\n\t'error-list': 'Error list',\n\t'error-list-message': 'Please correct the following errors',\n\tversion: 'Version number',\n\t'table-visible-range': 'Entries {{start}} to {{end}} of {{total}}',\n\t'table-selection-all': 'Select all',\n\t'table-selection-none': 'Deselect all',\n\t'table-selection-indeterminate': 'Select all with partial selection',\n\t'table-settings': 'Table configuration',\n\t'table-settings-cancel': 'Cancel',\n\t'table-settings-apply': 'Apply',\n\t'table-settings-show-column': 'Show column {{column}}',\n\t'table-settings-column-width': '{{column}} width',\n\t'table-settings-move-up': 'Move {{column}} column up',\n\t'table-settings-move-down': 'Move {{column}} column down',\n\t'table-settings-error-all-invisible': 'At least one column must be visible.',\n\t'table-settings-column-not-hidable': 'cannot be hidden',\n\tdropdown: 'Dropdown',\n\t'nav-label-open': 'Submenu for {{label}} open',\n\t'nav-label-close': 'Submenu for {{label}} close',\n\t'close-alert': 'Close notification',\n\t'show-password': 'Show',\n\t'hide-password': 'Hide',\n\t'no-results-message': 'No results found.',\n\t'delete-selection': 'Delete selection',\n\t'filename-text': 'Choose a file or drop it here...',\n\t'data-browse-text': 'Browse',\n\tsort: 'sort',\n\t'pagination-position-top': 'top',\n\t'pagination-position-bottom': 'bottom',\n\t'character-limit-hint': 'You can enter up to {{limit}} characters',\n\t'character-limit-remaining': 'You have {{remaining}} characters remaining.',\n\t'character-limit-exceeded': 'You have {{over}} characters too many.',\n\t'character-counter-current': '{{current}} characters',\n\t'character-counter-current-of-max': '{{current}}/{{max}} characters',\n\t'character-counter-current-of-max-aria': '{{current}} of {{max}} characters',\n};\n","import type { Generic } from 'adopted-style-sheets';\nimport locale_de from '../locales/de';\nimport locale_en from '../locales/en';\n\nexport type ResourcePrefix = 'Kol';\nexport type ComponentKeys = keyof typeof locale_de;\n\nconst mapLocaleKeys = (locale: { [K in ComponentKeys]: string }) =>\n\t(Object.keys(locale) as ComponentKeys[]).reduce((a, c) => ((a[`${'kol'}-${c}`] = locale[c]), a), {} as Generic.I18n.Map<ResourcePrefix, ComponentKeys>);\n\nconst TRANSLATIONS = new Set<Generic.I18n.RegisterPatch<Generic.I18n.Locale.ISO_639_1, ResourcePrefix, ComponentKeys>>([\n\t(t: (language: 'en', translationMap: Generic.I18n.Map<ResourcePrefix, ComponentKeys>) => Generic.I18n.Locale.ISO_639_1) => t('en', mapLocaleKeys(locale_en)),\n\t(t: (language: 'de', translationMap: Generic.I18n.Map<ResourcePrefix, ComponentKeys>) => Generic.I18n.Locale.ISO_639_1) => t('de', mapLocaleKeys(locale_de)),\n]);\n\ninterface ITranslationOptions {\n\t/**\n\t * Placeholders to insert into the text. Replacing {{key}} with the specified value if the \"key\".\n\t */\n\tplaceholders?: { [K: string]: string };\n}\n\n// String.replaceAll should be used but is only available with ECMAScript 2021.\nconst replaceAll = function (text: string, search: string, replacement: string) {\n\treturn text.split(search).join(replacement);\n};\n\ntype Resources = Map<string, string>;\n\nexport class I18nService {\n\tprivate resourceMap = new Map<Generic.I18n.Locale.ISO_639_1, Resources>();\n\tlanguage: Generic.I18n.Locale.ISO_639_1;\n\n\tpublic constructor(initialLanguage?: Generic.I18n.Locale.ISO_639_1) {\n\t\tthis.language = initialLanguage ?? 'de';\n\t}\n\n\t/**\n\t * Adds a resource bundle for the specified language.\n\t * @param lng the language the bundle is for\n\t * @param translationMap the translations of the given language\n\t */\n\tpublic addTranslations(\n\t\ttranslations?:\n\t\t\t| Generic.I18n.RegisterPatch<Generic.I18n.Locale.ISO_639_1, string, string>\n\t\t\t| Generic.I18n.RegisterPatch<Generic.I18n.Locale.ISO_639_1, string, string>[]\n\t\t\t| Set<Generic.I18n.RegisterPatch<Generic.I18n.Locale.ISO_639_1, string, string>>,\n\t) {\n\t\tif (Array.isArray(translations)) {\n\t\t\ttranslations = new Set(translations);\n\t\t} else if (typeof translations === 'function') {\n\t\t\ttranslations = new Set([translations]);\n\t\t}\n\n\t\tif (translations !== undefined) {\n\t\t\ttranslations.forEach((t) =>\n\t\t\t\tt((l, t) => {\n\t\t\t\t\tlet resources = this.resourceMap.get(l);\n\t\t\t\t\tif (!resources) {\n\t\t\t\t\t\tresources = new Map<string, string>();\n\t\t\t\t\t\tthis.resourceMap.set(l, resources);\n\t\t\t\t\t}\n\n\t\t\t\t\tObject.entries(t).forEach(([k, v]) => {\n\t\t\t\t\t\tif (v) {\n\t\t\t\t\t\t\tresources.set(k, v);\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t\treturn l;\n\t\t\t\t}),\n\t\t\t);\n\t\t}\n\t}\n\n\t/**\n\t * Set the current language.\n\t * @param lng the language the bundle is for\n\t */\n\tpublic setLanguage(lng: Generic.I18n.Locale.ISO_639_1) {\n\t\tthis.language = lng;\n\t}\n\n\t/**\n\t * Determines a human-readable translated text for the given resource key.\n\t * @param key the resource key\n\t * @param options optional translation parameters\n\t * @returns the translated text\n\t */\n\tpublic translate(key: string, options?: ITranslationOptions) {\n\t\tlet result = this.resourceMap.get(this.language)?.get(key);\n\t\tif (result) {\n\t\t\tif (options?.placeholders) {\n\t\t\t\tObject.entries(options.placeholders).forEach(([k, v]) => {\n\t\t\t\t\tresult = replaceAll(result!, `{{${k}}}`, v);\n\t\t\t\t});\n\t\t\t}\n\t\t} else {\n\t\t\tresult = key;\n\t\t}\n\t\treturn result;\n\t}\n}\n\nlet i18n: I18nService;\n\nexport const getI18nInstance = () => {\n\treturn i18n;\n};\n\nexport const initializeI18n = (\n\tlng: Generic.I18n.Locale.ISO_639_1,\n\ttranslations:\n\t\t| Generic.I18n.RegisterPatch<Generic.I18n.Locale.ISO_639_1, string, string>\n\t\t| Generic.I18n.RegisterPatch<Generic.I18n.Locale.ISO_639_1, string, string>[]\n\t\t| Set<Generic.I18n.RegisterPatch<Generic.I18n.Locale.ISO_639_1, string, string>> = TRANSLATIONS,\n) => {\n\ti18n = new I18nService(lng);\n\ti18n.addTranslations(translations);\n\treturn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.ts"],"sourcesContent":["export default {\n\terror: 'Fehler',\n\twarning: 'Warnung',\n\tinfo: 'Hinweis',\n\tsuccess: 'Erfolg',\n\tmessage: 'Nachricht',\n\tclose: 'Schließen',\n\t'form-description': 'Formular-Felder, die mit einem Sternchen (*) gekennzeichnet sind, sind Pflichtangaben.',\n\tnew: 'Neu',\n\t'no-entries': 'Es sind keine Einträge vorhanden.',\n\t'change-order': 'Sortierung von {{colLabel}} ändern',\n\t'action-running': 'Aktion wird ausgeführt...',\n\t'action-done': 'Aktion abgeschlossen',\n\tpagination: 'Paginierung',\n\t'page-first': 'Direkt zur ersten Seite',\n\t'page-back': 'Eine Seite zurück',\n\t'page-next': 'Eine Seite weiter',\n\t'page-last': 'Direkt zur letzten Seite',\n\t'entries-per-site': 'Einträge pro Seite',\n\tpage: 'Seite',\n\t'page-current': 'Seite {{page}}',\n\t'page-selected': 'Seite {{page}} ist ausgewählt',\n\t'page-per-site': '{{entries}} Einträge pro Seite',\n\t'nav-maximize': 'Navigation maximieren',\n\t'nav-minimize': 'Navigation minimieren',\n\t'logo-description': 'Logo {{orgShort}}. Bundesadler mit Flaggenstab und Schriftzug {{orgLong}}',\n\t'open-link-in-tab': 'Öffnet in neuem Tab.',\n\t'kolibri-logo': 'Logo von KoliBri',\n\t'table-pagination-label': 'Paginierung für die Tabelle {{label}}',\n\t'avatar-alt': 'Avatar von {{name}}',\n\t'split-button-dropdown-label-open': 'Optionen anzeigen',\n\t'split-button-dropdown-label-close': 'Optionen schließen',\n\t'toast-close-all': 'Alle schließen',\n\t'error-list': 'Fehlerliste',\n\t'error-list-message': 'Bitte korrigieren Sie folgende Fehler:',\n\tversion: 'Versionsnummer',\n\t'table-visible-range': 'Einträge {{start}} bis {{end}} von {{total}}',\n\t'table-selection-all': 'Alle auswählen',\n\t'table-selection-none': 'Alle abwählen',\n\t'table-selection-indeterminate': 'Alle auswählen bei teilweiser Auswahl',\n\t'table-settings': 'Tabellenkonfiguration',\n\t'table-settings-cancel': 'Abbrechen',\n\t'table-settings-apply': 'Übernehmen',\n\t'table-settings-show-column': 'Spalte {{column}} anzeigen',\n\t'table-settings-column-width': 'Breite von {{column}}',\n\t'table-settings-move-up': 'Spalte {{column}} nach oben verschieben',\n\t'table-settings-move-down': 'Spalte {{column}} nach unten verschieben',\n\t'table-settings-error-all-invisible': 'Mindestens eine Spalte muss sichtbar sein.',\n\t'table-settings-column-not-hidable': 'nicht ausblendbar',\n\tdropdown: 'Auswahlliste',\n\t'nav-label-open': 'Untermenü zu {{label}} öffnen',\n\t'nav-label-close': 'Untermenü zu {{label}} schließen',\n\t'close-alert': 'Benachrichtigung schließen',\n\t'show-password': 'einblenden',\n\t'hide-password': 'ausblenden',\n\t'no-results-message': 'Keine Ergebnisse gefunden.',\n\t'delete-selection': 'Auswahl entfernen',\n\t'filename-text': 'Datei auswählen oder hier ablegen...',\n\t'data-browse-text': 'Datei auswählen',\n\tsort: 'sortieren',\n\t'pagination-position-top': 'oben',\n\t'pagination-position-bottom': 'unten',\n\t'character-limit-hint': 'Es können bis zu {{limit}} Zeichen eingegeben werden.',\n\t'character-limit-remaining': 'Es sind noch {{remaining}} Zeichen verfügbar.',\n\t'character-limit-exceeded': 'Es sind {{over}} Zeichen zu viel.',\n\t'character-counter-current': '{{current}} Zeichen',\n\t'character-counter-current-of-max': '{{current}}/{{max}} Zeichen',\n\t'character-counter-current-of-max-aria': '{{current}} von {{max}} Zeichen',\n};\n","export default {\n\terror: 'Error',\n\twarning: 'Warning',\n\tinfo: 'Note',\n\tsuccess: 'Success',\n\tmessage: 'Message',\n\tclose: 'Close',\n\t'form-description': 'Form fields marked with an asterisk (*) are mandatory.',\n\tnew: 'New',\n\t'no-entries': 'No entries available.',\n\t'change-order': 'Change order of {{colLabel}}',\n\t'action-running': 'Action is running...',\n\t'action-done': 'Action done',\n\tpagination: 'Pagination',\n\t'page-first': 'Directly to the first page',\n\t'page-back': 'One page back',\n\t'page-next': 'One page further',\n\t'page-last': 'Directly to the last page',\n\t'entries-per-site': 'Entries per page',\n\tpage: 'Page',\n\t'page-current': 'Page {{page}}',\n\t'page-selected': 'Page {{page}} is selected',\n\t'page-per-site': '{{entries}} entries per page',\n\t'nav-maximize': 'Maximize navigation',\n\t'nav-minimize': 'Minimize navigation',\n\t'logo-description': 'Logo {{orgShort}}. Federal eagle with flag staff and lettering {{orgLong}}',\n\t'open-link-in-tab': 'Opens in new tab.',\n\t'kolibri-logo': 'KoliBri logo',\n\t'table-pagination-label': 'Pagination for table {{label}}',\n\t'avatar-alt': 'Avatar of {{name}}',\n\t'split-button-dropdown-label-open': 'Show options',\n\t'split-button-dropdown-label-close': 'Hide options',\n\t'toast-close-all': 'Close all',\n\t'error-list': 'Error list',\n\t'error-list-message': 'Please correct the following errors',\n\tversion: 'Version number',\n\t'table-visible-range': 'Entries {{start}} to {{end}} of {{total}}',\n\t'table-selection-all': 'Select all',\n\t'table-selection-none': 'Deselect all',\n\t'table-selection-indeterminate': 'Select all with partial selection',\n\t'table-settings': 'Table configuration',\n\t'table-settings-cancel': 'Cancel',\n\t'table-settings-apply': 'Apply',\n\t'table-settings-show-column': 'Show column {{column}}',\n\t'table-settings-column-width': '{{column}} width',\n\t'table-settings-move-up': 'Move {{column}} column up',\n\t'table-settings-move-down': 'Move {{column}} column down',\n\t'table-settings-error-all-invisible': 'At least one column must be visible.',\n\t'table-settings-column-not-hidable': 'cannot be hidden',\n\tdropdown: 'Dropdown',\n\t'nav-label-open': 'Submenu for {{label}} open',\n\t'nav-label-close': 'Submenu for {{label}} close',\n\t'close-alert': 'Close notification',\n\t'show-password': 'Show',\n\t'hide-password': 'Hide',\n\t'no-results-message': 'No results found.',\n\t'delete-selection': 'Delete selection',\n\t'filename-text': 'Choose a file or drop it here...',\n\t'data-browse-text': 'Browse',\n\tsort: 'sort',\n\t'pagination-position-top': 'top',\n\t'pagination-position-bottom': 'bottom',\n\t'character-limit-hint': 'You can enter up to {{limit}} characters',\n\t'character-limit-remaining': 'You have {{remaining}} characters remaining.',\n\t'character-limit-exceeded': 'You have {{over}} characters too many.',\n\t'character-counter-current': '{{current}} characters',\n\t'character-counter-current-of-max': '{{current}}/{{max}} characters',\n\t'character-counter-current-of-max-aria': '{{current}} of {{max}} characters',\n};\n","import type { Generic } from 'adopted-style-sheets';\nimport locale_de from '../locales/de';\nimport locale_en from '../locales/en';\n\nexport type ResourcePrefix = 'Kol';\nexport type ComponentKeys = keyof typeof locale_de;\n\nconst mapLocaleKeys = (locale: { [K in ComponentKeys]: string }) =>\n\t(Object.keys(locale) as ComponentKeys[]).reduce((a, c) => ((a[`${'kol'}-${c}`] = locale[c]), a), {} as Generic.I18n.Map<ResourcePrefix, ComponentKeys>);\n\nconst TRANSLATIONS = new Set<Generic.I18n.RegisterPatch<Generic.I18n.Locale.ISO_639_1, ResourcePrefix, ComponentKeys>>([\n\t(t: (language: 'en', translationMap: Generic.I18n.Map<ResourcePrefix, ComponentKeys>) => Generic.I18n.Locale.ISO_639_1) => t('en', mapLocaleKeys(locale_en)),\n\t(t: (language: 'de', translationMap: Generic.I18n.Map<ResourcePrefix, ComponentKeys>) => Generic.I18n.Locale.ISO_639_1) => t('de', mapLocaleKeys(locale_de)),\n]);\n\ninterface ITranslationOptions {\n\t/**\n\t * Placeholders to insert into the text. Replacing {{key}} with the specified value if the \"key\".\n\t */\n\tplaceholders?: { [K: string]: string };\n}\n\n// String.replaceAll should be used but is only available with ECMAScript 2021.\nconst replaceAll = function (text: string, search: string, replacement: string) {\n\treturn text.split(search).join(replacement);\n};\n\ntype Resources = Map<string, string>;\n\nexport class I18nService {\n\tprivate resourceMap = new Map<Generic.I18n.Locale.ISO_639_1, Resources>();\n\tlanguage: Generic.I18n.Locale.ISO_639_1;\n\n\tpublic constructor(initialLanguage?: Generic.I18n.Locale.ISO_639_1) {\n\t\tthis.language = initialLanguage ?? 'de';\n\t}\n\n\t/**\n\t * Adds a resource bundle for the specified language.\n\t * @param lng the language the bundle is for\n\t * @param translationMap the translations of the given language\n\t */\n\tpublic addTranslations(\n\t\ttranslations?:\n\t\t\t| Generic.I18n.RegisterPatch<Generic.I18n.Locale.ISO_639_1, string, string>\n\t\t\t| Generic.I18n.RegisterPatch<Generic.I18n.Locale.ISO_639_1, string, string>[]\n\t\t\t| Set<Generic.I18n.RegisterPatch<Generic.I18n.Locale.ISO_639_1, string, string>>,\n\t) {\n\t\tif (Array.isArray(translations)) {\n\t\t\ttranslations = new Set(translations);\n\t\t} else if (typeof translations === 'function') {\n\t\t\ttranslations = new Set([translations]);\n\t\t}\n\n\t\tif (translations !== undefined) {\n\t\t\ttranslations.forEach((t) =>\n\t\t\t\tt((l, t) => {\n\t\t\t\t\tlet resources = this.resourceMap.get(l);\n\t\t\t\t\tif (!resources) {\n\t\t\t\t\t\tresources = new Map<string, string>();\n\t\t\t\t\t\tthis.resourceMap.set(l, resources);\n\t\t\t\t\t}\n\n\t\t\t\t\tObject.entries(t).forEach(([k, v]) => {\n\t\t\t\t\t\tif (v) {\n\t\t\t\t\t\t\tresources.set(k, v);\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t\treturn l;\n\t\t\t\t}),\n\t\t\t);\n\t\t}\n\t}\n\n\t/**\n\t * Set the current language.\n\t * @param lng the language the bundle is for\n\t */\n\tpublic setLanguage(lng: Generic.I18n.Locale.ISO_639_1) {\n\t\tthis.language = lng;\n\t}\n\n\t/**\n\t * Determines a human-readable translated text for the given resource key.\n\t * @param key the resource key\n\t * @param options optional translation parameters\n\t * @returns the translated text\n\t */\n\tpublic translate(key: string, options?: ITranslationOptions) {\n\t\tlet result = this.resourceMap.get(this.language)?.get(key);\n\t\tif (result) {\n\t\t\tif (options?.placeholders) {\n\t\t\t\tObject.entries(options.placeholders).forEach(([k, v]) => {\n\t\t\t\t\tresult = replaceAll(result!, `{{${k}}}`, v);\n\t\t\t\t});\n\t\t\t}\n\t\t} else {\n\t\t\tresult = key;\n\t\t}\n\t\treturn result;\n\t}\n}\n\nlet i18n: I18nService;\n\nexport const getI18nInstance = () => {\n\treturn i18n;\n};\n\nexport const initializeI18n = (\n\tlng: Generic.I18n.Locale.ISO_639_1,\n\ttranslations:\n\t\t| Generic.I18n.RegisterPatch<Generic.I18n.Locale.ISO_639_1, string, string>\n\t\t| Generic.I18n.RegisterPatch<Generic.I18n.Locale.ISO_639_1, string, string>[]\n\t\t| Set<Generic.I18n.RegisterPatch<Generic.I18n.Locale.ISO_639_1, string, string>> = TRANSLATIONS,\n) => {\n\ti18n = new I18nService(lng);\n\ti18n.addTranslations(translations);\n\treturn i18n;\n};\n"],"names":[],"mappings":";;;;;AAAA,gBAAe;AACd,IAAA,KAAK,EAAE,QAAQ;AACf,IAAA,OAAO,EAAE,SAAS;AAClB,IAAA,IAAI,EAAE,SAAS;AACf,IAAA,OAAO,EAAE,QAAQ;AACjB,IAAA,OAAO,EAAE,WAAW;AACpB,IAAA,KAAK,EAAE,WAAW;AAClB,IAAA,kBAAkB,EAAE,wFAAwF;AAC5G,IAAA,GAAG,EAAE,KAAK;AACV,IAAA,YAAY,EAAE,mCAAmC;AACjD,IAAA,cAAc,EAAE,oCAAoC;AACpD,IAAA,gBAAgB,EAAE,2BAA2B;AAC7C,IAAA,aAAa,EAAE,sBAAsB;AACrC,IAAA,UAAU,EAAE,aAAa;AACzB,IAAA,YAAY,EAAE,yBAAyB;AACvC,IAAA,WAAW,EAAE,mBAAmB;AAChC,IAAA,WAAW,EAAE,mBAAmB;AAChC,IAAA,WAAW,EAAE,0BAA0B;AACvC,IAAA,kBAAkB,EAAE,oBAAoB;AACxC,IAAA,IAAI,EAAE,OAAO;AACb,IAAA,cAAc,EAAE,gBAAgB;AAChC,IAAA,eAAe,EAAE,+BAA+B;AAChD,IAAA,eAAe,EAAE,gCAAgC;AACjD,IAAA,cAAc,EAAE,uBAAuB;AACvC,IAAA,cAAc,EAAE,uBAAuB;AACvC,IAAA,kBAAkB,EAAE,2EAA2E;AAC/F,IAAA,kBAAkB,EAAE,sBAAsB;AAC1C,IAAA,cAAc,EAAE,kBAAk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e,GAAG,MAAK;AACnC,IAAA,OAAO,IAAI;AACZ;AAEa,MAAA,cAAc,GAAG,CAC7B,GAAkC,EAClC,YAAA,GAGoF,YAAY,KAC7F;AACH,IAAA,IAAI,GAAG,IAAI,WAAW,CAAC,GAAG,CAAC;AAC3B,IAAA,IAAI,CAAC,eAAe,CAAC,YAAY,CAAC;AAClC,IAAA,OAAO,IAAI;AACZ;;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"icons-CvKgcv20.js","sources":["src/schema/props/icons.ts"],"sourcesContent":["import type { Generic } from 'adopted-style-sheets';\n\nimport type { AnyIconFontClass, KoliBriCustomIcon, KoliBriHorizontalIconsProp, KoliBriIconsProp, KoliBriIconsState } from '../types';\nimport type { Stringified } from '../types/common';\nimport type { WatchOptions } from '../utils';\nimport { objectObjectHandler, parseJson, watchValidator } from '../utils';\nimport { isObject, isString, isStyle } from '../validators';\n\nimport type { AlignPropType } from './align';\n\n/* types */\nexport type IconsPropType = Stringified<KoliBriIconsProp>;\nexport type IconsHorizontalPropType = Stringified<KoliBriHorizontalIconsProp>;\n\n/**\n * Defines the icon classnames.\n */\nexport type PropIcons = {\n\ticons: IconsPropType;\n};\nexport type PropHorizontalIcons = {\n\ticons: IconsHorizontalPropType;\n};\n\n/* validator */\n\nconst mapCustomIcon = (state: KoliBriIconsState, alignment: AlignPropType, icon?: AnyIconFontClass | KoliBriCustomIcon) => {\n\tif (isObject(icon)) {\n\t\tstate[alignment] = icon as KoliBriCustomIcon;\n\t} else if (isString(icon, 1)) {\n\t\tstate[alignment] = {\n\t\t\ticon: icon as AnyIconFontClass,\n\t\t};\n\t}\n};\n\nexport const mapIconProp2State = (icon: KoliBriIconsProp): KoliBriIconsState => {\n\tlet state: KoliBriIconsState = {};\n\tif (isString(icon, 1)) {\n\t\tstate = {\n\t\t\tleft: {\n\t\t\t\ticon: icon as AnyIconFontClass,\n\t\t\t},\n\t\t};\n\t} else if (typeof icon === 'object' && icon !== null) {\n\t\tmapCustomIcon(state, 'top', icon.top);\n\t\tmapCustomIcon(state, 'right', icon.right);\n\t\tmapCustomIcon(state, 'bottom', icon.bottom);\n\t\tmapCustomIcon(state, 'left', icon.left);\n\t}\n\treturn state;\n};\n\nconst beforePatchIcon = (component: Generic.Element.Component): void => {\n\tif (component.nextState?.has('_icons')) {\n\t\tconst icons = component.nextState?.get('_icons') as KoliBriIconsProp;\n\t\tcomponent.nextState?.set('_icons', mapIconProp2State(icons));\n\t}\n};\n\nexport const isIcon = (value?: unknown): boolean =>\n\ttypeof value === 'object' &&\n\tvalue !== null &&\n\t(typeof (value as KoliBriCustomIcon).style === 'undefined' || isStyle((value as KoliBriCustomIcon).style)) &&\n\t(typeof (value as KoliBriCustomIcon).label === 'undefined' || isString((value as KoliBriCustomIcon).label)) &&\n\tisString((value as KoliBriCustomIcon).icon, 1);\n\nexport const validateIcons = (component: Generic.Element.Component, value?: IconsPropType, options: WatchOptions = {}): void => {\n\tobjectObjectHandler(value, () => {\n\t\ttry {\n\t\t\tvalue = parseJson<KoliBriIconsProp>(value as string);\n\t\t} catch (e) {\n\t\t\t// value behält den ursprünglichen Wert\n\t\t}\n\t\twatchValidator(\n\t\t\tcomponent,\n\t\t\t'_icons',\n\t\t\t(value): boolean => {\n\t\t\t\tconst valueIsEmptyObject = typeof value === 'object' && value !== null && Object.keys(value).length === 0;\n\t\t\t\treturn (\n\t\t\t\t\tvalue === null ||\n\t\t\t\t\tvalueIsEmptyObject ||\n\t\t\t\t\tisString(value, 1) ||\n\t\t\t\t\t(typeof value === 'object' &&\n\t\t\t\t\t\tvalue !== null &&\n\t\t\t\t\t\t(isString(value.left, 1) ||\n\t\t\t\t\t\t\tisIcon(value.left) ||\n\t\t\t\t\t\t\tisString(value.right, 1) ||\n\t\t\t\t\t\t\tisIcon(value.right) ||\n\t\t\t\t\t\t\tisString(value.top, 1) ||\n\t\t\t\t\t\t\tisIcon(value.top) ||\n\t\t\t\t\t\t\tisString(value.bottom, 1) ||\n\t\t\t\t\t\t\tisIcon(value.bottom)))\n\t\t\t\t);\n\t\t\t},\n\t\t\tnew Set(['KoliBriIcon']),\n\t\t\tvalue,\n\t\t\t{\n\t\t\t\t...options,\n\t\t\t\tdefaultValue: {},\n\t\t\t\thooks: {\n\t\t\t\t\tafterPatch: options.hooks?.afterPatch,\n\t\t\t\t\tbeforePatch: (nextValue, nextState, component, key) => {\n\t\t\t\t\t\tif (typeof options.hooks?.beforePatch === 'function') {\n\t\t\t\t\t\t\toptions.hooks?.beforePatch(nextValue, nextState, component, key);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbeforePatchIcon(component);\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t);\n\t});\n};\n"],"names":["isObject","isString","isStyle","objectObjectHandler","parseJson","watchValidator"],"mappings":";;;;;;;AA0BA,MAAM,aAAa,GAAG,CAAC,KAAwB,EAAE,SAAwB,EAAE,IAA2C,KAAI;AACzH,IAAA,IAAIA,eAAQ,CAAC,IAAI,CAAC,EAAE;AACnB,QAAA,KAAK,CAAC,SAAS,CAAC,GAAG,IAAyB;;AACtC,SAAA,IAAIC,eAAQ,CAAC,IAAI,EAAE,CAAC,CAAC,EAAE;QAC7B,KAAK,CAAC,SAAS,CAAC,GAAG;AAClB,YAAA,IAAI,EAAE,IAAwB;SAC9B;;AAEH,CAAC;AAEM,MAAM,iBAAiB,GAAG,CAAC,IAAsB,KAAuB;IAC9E,IAAI,KAAK,GAAsB,EAAE;AACjC,IAAA,IAAIA,eAAQ,CAAC,IAAI,EAAE,CAAC,CAAC,EAAE;AACtB,QAAA,KAAK,GAAG;AACP,YAAA,IAAI,EAAE;AACL,gBAAA,IAAI,EAAE,IAAwB;AAC9B,aAAA;SACD;;SACK,IAAI,OAAO,IAAI,KAAK,QAAQ,IAAI,IAAI,KAAK,IAAI,EAAE;QACrD,aAAa,CAAC,KAAK,EAAE,KAAK,EAAE,IAAI,CAAC,GAAG,CAAC;QACrC,aAAa,CAAC,KAAK,EAAE,OAAO,EAAE,I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AG,KAAI;;AACrD,oBAAA,IAAI,QAAO,CAAA,EAAA,GAAA,OAAO,CAAC,KAAK,MAAE,IAAA,IAAA,EAAA,KAAA,MAAA,GAAA,MAAA,GAAA,EAAA,CAAA,WAAW,CAAA,KAAK,UAAU,EAAE;AACrD,wBAAA,CAAA,EAAA,GAAA,OAAO,CAAC,KAAK,MAAA,IAAA,IAAA,EAAA,KAAA,MAAA,GAAA,MAAA,GAAA,EAAA,CAAE,WAAW,CAAC,SAAS,EAAE,SAAS,EAAE,SAAS,EAAE,GAAG,CAAC;;oBAEjE,eAAe,CAAC,SAAS,CAAC;iBAC1B;AACD,aAAA,EAAA,CAAA,CAEF;AACF,KAAC,CAAC;AACH;;;;"}
1
+ {"version":3,"file":"icons-CvKgcv20.js","sources":["src/schema/props/icons.ts"],"sourcesContent":["import type { Generic } from 'adopted-style-sheets';\n\nimport type { AnyIconFontClass, KoliBriCustomIcon, KoliBriHorizontalIconsProp, KoliBriIconsProp, KoliBriIconsState } from '../types';\nimport type { Stringified } from '../types/common';\nimport type { WatchOptions } from '../utils';\nimport { objectObjectHandler, parseJson, watchValidator } from '../utils';\nimport { isObject, isString, isStyle } from '../validators';\n\nimport type { AlignPropType } from './align';\n\n/* types */\nexport type IconsPropType = Stringified<KoliBriIconsProp>;\nexport type IconsHorizontalPropType = Stringified<KoliBriHorizontalIconsProp>;\n\n/**\n * Defines the icon classnames.\n */\nexport type PropIcons = {\n\ticons: IconsPropType;\n};\nexport type PropHorizontalIcons = {\n\ticons: IconsHorizontalPropType;\n};\n\n/* validator */\n\nconst mapCustomIcon = (state: KoliBriIconsState, alignment: AlignPropType, icon?: AnyIconFontClass | KoliBriCustomIcon) => {\n\tif (isObject(icon)) {\n\t\tstate[alignment] = icon as KoliBriCustomIcon;\n\t} else if (isString(icon, 1)) {\n\t\tstate[alignment] = {\n\t\t\ticon: icon as AnyIconFontClass,\n\t\t};\n\t}\n};\n\nexport const mapIconProp2State = (icon: KoliBriIconsProp): KoliBriIconsState => {\n\tlet state: KoliBriIconsState = {};\n\tif (isString(icon, 1)) {\n\t\tstate = {\n\t\t\tleft: {\n\t\t\t\ticon: icon as AnyIconFontClass,\n\t\t\t},\n\t\t};\n\t} else if (typeof icon === 'object' && icon !== null) {\n\t\tmapCustomIcon(state, 'top', icon.top);\n\t\tmapCustomIcon(state, 'right', icon.right);\n\t\tmapCustomIcon(state, 'bottom', icon.bottom);\n\t\tmapCustomIcon(state, 'left', icon.left);\n\t}\n\treturn state;\n};\n\nconst beforePatchIcon = (component: Generic.Element.Component): void => {\n\tif (component.nextState?.has('_icons')) {\n\t\tconst icons = component.nextState?.get('_icons') as KoliBriIconsProp;\n\t\tcomponent.nextState?.set('_icons', mapIconProp2State(icons));\n\t}\n};\n\nexport const isIcon = (value?: unknown): boolean =>\n\ttypeof value === 'object' &&\n\tvalue !== null &&\n\t(typeof (value as KoliBriCustomIcon).style === 'undefined' || isStyle((value as KoliBriCustomIcon).style)) &&\n\t(typeof (value as KoliBriCustomIcon).label === 'undefined' || isString((value as KoliBriCustomIcon).label)) &&\n\tisString((value as KoliBriCustomIcon).icon, 1);\n\nexport const validateIcons = (component: Generic.Element.Component, value?: IconsPropType, options: WatchOptions = {}): void => {\n\tobjectObjectHandler(value, () => {\n\t\ttry {\n\t\t\tvalue = parseJson<KoliBriIconsProp>(value as string);\n\t\t} catch (e) {\n\t\t\t// value behält den ursprünglichen Wert\n\t\t}\n\t\twatchValidator(\n\t\t\tcomponent,\n\t\t\t'_icons',\n\t\t\t(value): boolean => {\n\t\t\t\tconst valueIsEmptyObject = typeof value === 'object' && value !== null && Object.keys(value).length === 0;\n\t\t\t\treturn (\n\t\t\t\t\tvalue === null ||\n\t\t\t\t\tvalueIsEmptyObject ||\n\t\t\t\t\tisString(value, 1) ||\n\t\t\t\t\t(typeof value === 'object' &&\n\t\t\t\t\t\tvalue !== null &&\n\t\t\t\t\t\t(isString(value.left, 1) ||\n\t\t\t\t\t\t\tisIcon(value.left) ||\n\t\t\t\t\t\t\tisString(value.right, 1) ||\n\t\t\t\t\t\t\tisIcon(value.right) ||\n\t\t\t\t\t\t\tisString(value.top, 1) ||\n\t\t\t\t\t\t\tisIcon(value.top) ||\n\t\t\t\t\t\t\tisString(value.bottom, 1) ||\n\t\t\t\t\t\t\tisIcon(value.bottom)))\n\t\t\t\t);\n\t\t\t},\n\t\t\tnew Set(['KoliBriIcon']),\n\t\t\tvalue,\n\t\t\t{\n\t\t\t\t...options,\n\t\t\t\tdefaultValue: {},\n\t\t\t\thooks: {\n\t\t\t\t\tafterPatch: options.hooks?.afterPatch,\n\t\t\t\t\tbeforePatch: (nextValue, nextState, component, key) => {\n\t\t\t\t\t\tif (typeof options.hooks?.beforePatch === 'function') {\n\t\t\t\t\t\t\toptions.hooks?.beforePatch(nextValue, nextState, component, key);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbeforePatchIcon(component);\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t);\n\t});\n};\n"],"names":["isObject","isString","isStyle","objectObjectHandler","parseJson","watchValidator"],"mappings":";;;;;;;AA0BA,MAAM,aAAa,GAAG,CAAC,KAAwB,EAAE,SAAwB,EAAE,IAA2C,KAAI;AACzH,IAAA,IAAIA,eAAQ,CAAC,IAAI,CAAC,EAAE;AACnB,QAAA,KAAK,CAAC,SAAS,CAAC,GAAG,IAAyB;;AACtC,SAAA,IAAIC,eAAQ,CAAC,IAAI,EAAE,CAAC,CAAC,EAAE;QAC7B,KAAK,CAAC,SAAS,CAAC,GAAG;AAClB,YAAA,IAAI,EAAE,IAAwB;SAC9B;;AAEH,CAAC;AAEM,MAAM,iBAAiB,GAAG,CAAC,IAAsB,KAAuB;IAC9E,IAAI,KAAK,GAAsB,EAAE;AACjC,IAAA,IAAIA,eAAQ,CAAC,IAAI,EAAE,CAAC,CAAC,EAAE;AACtB,QAAA,KAAK,GAAG;AACP,YAAA,IAAI,EAAE;AACL,gBAAA,IAAI,EAAE,IAAwB;AAC9B,aAAA;SACD;;S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