@public-ui/components 1.6.0-rc.12 → 1.6.0-rc.14

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 (509) hide show
  1. package/custom-elements.json +5 -5
  2. package/dist/cjs/{a11y.tipps-b7561cd9.js → a11y.tipps-dbfe482e.js} +1 -1
  3. package/dist/cjs/{a11y.tipps-b7561cd9.js.map → a11y.tipps-dbfe482e.js.map} +1 -1
  4. package/dist/cjs/{app-globals-76ba24c3.js → app-globals-3c457229.js} +1 -1
  5. package/dist/cjs/{app-globals-76ba24c3.js.map → app-globals-3c457229.js.map} +1 -1
  6. package/dist/cjs/{aria-selected-0ad16d16.js → aria-selected-b31756b3.js} +1 -1
  7. package/dist/cjs/{aria-selected-0ad16d16.js.map → aria-selected-b31756b3.js.map} +1 -1
  8. package/dist/cjs/{button-link-1df10d7c.js → button-link-58e21d08.js} +1 -1
  9. package/dist/cjs/{button-link-1df10d7c.js.map → button-link-58e21d08.js.map} +1 -1
  10. package/dist/cjs/{color-b81183e4.js → color-3b22adaf.js} +1 -1
  11. package/dist/cjs/{color-b81183e4.js.map → color-3b22adaf.js.map} +1 -1
  12. package/dist/cjs/{controller-6aabbf41.js → controller-0cd28689.js} +1 -1
  13. package/dist/cjs/{controller-6aabbf41.js.map → controller-0cd28689.js.map} +1 -1
  14. package/dist/cjs/{controller-d513b916.js → controller-43fe103f.js} +1 -1
  15. package/dist/cjs/{controller-d513b916.js.map → controller-43fe103f.js.map} +1 -1
  16. package/dist/cjs/controller-48d4248f.js +4 -0
  17. package/dist/cjs/controller-48d4248f.js.map +1 -0
  18. package/dist/cjs/{controller-7c4cd449.js → controller-bc933b12.js} +1 -1
  19. package/dist/cjs/{controller-7c4cd449.js.map → controller-bc933b12.js.map} +1 -1
  20. package/dist/cjs/controller-c3021b2f.js +4 -0
  21. package/dist/cjs/controller-c3021b2f.js.map +1 -0
  22. package/dist/cjs/{controller-9a10b30b.js → controller-ceae9412.js} +1 -1
  23. package/dist/cjs/{controller-9a10b30b.js.map → controller-ceae9412.js.map} +1 -1
  24. package/dist/cjs/{controller-icon-d2ec9da9.js → controller-icon-ceafc344.js} +1 -1
  25. package/dist/cjs/{controller-icon-d2ec9da9.js.map → controller-icon-ceafc344.js.map} +1 -1
  26. package/dist/cjs/dev.utils-78d00548.js +4 -0
  27. package/dist/cjs/{dev.utils-b2b6f024.js.map → dev.utils-78d00548.js.map} +1 -1
  28. package/dist/cjs/{devtools-60ad513c.js → devtools-7f99e00b.js} +1 -1
  29. package/dist/cjs/devtools-7f99e00b.js.map +1 -0
  30. package/dist/cjs/{disabled-98957f7e.js → disabled-959951da.js} +1 -1
  31. package/dist/cjs/{disabled-98957f7e.js.map → disabled-959951da.js.map} +1 -1
  32. package/dist/cjs/floating-ui.dom.esm-09852e47.js +4 -0
  33. package/dist/cjs/floating-ui.dom.esm-09852e47.js.map +1 -0
  34. package/dist/cjs/has-closer-01ac076a.js +4 -0
  35. package/dist/cjs/{has-closer-7d377e88.js.map → has-closer-01ac076a.js.map} +1 -1
  36. package/dist/cjs/hide-label-4d99f1d9.js +4 -0
  37. package/dist/cjs/{hide-label-9bf6abe6.js.map → hide-label-4d99f1d9.js.map} +1 -1
  38. package/dist/cjs/{i18n-43926d90.js → i18n-8d483c7b.js} +1 -1
  39. package/dist/cjs/{i18n-43926d90.js.map → i18n-8d483c7b.js.map} +1 -1
  40. package/dist/cjs/{icon-deabb5a9.js → icon-4b915891.js} +1 -1
  41. package/dist/cjs/{icon-deabb5a9.js.map → icon-4b915891.js.map} +1 -1
  42. package/dist/cjs/index.cjs.js +1 -1
  43. package/dist/cjs/kol-abbr.cjs.entry.js +1 -1
  44. package/dist/cjs/kol-accordion.cjs.entry.js +1 -1
  45. package/dist/cjs/kol-alert-wc_2.cjs.entry.js +1 -1
  46. package/dist/cjs/kol-badge.cjs.entry.js +1 -1
  47. package/dist/cjs/kol-breadcrumb.cjs.entry.js +1 -1
  48. package/dist/cjs/kol-breadcrumb.cjs.entry.js.map +1 -1
  49. package/dist/cjs/kol-button-wc_2.cjs.entry.js +1 -1
  50. package/dist/cjs/kol-button-wc_2.cjs.entry.js.map +1 -1
  51. package/dist/cjs/kol-card.cjs.entry.js +1 -1
  52. package/dist/cjs/kol-details.cjs.entry.js +1 -1
  53. package/dist/cjs/kol-form.cjs.entry.js +1 -1
  54. package/dist/cjs/kol-icon-font-awesome.cjs.entry.js +1 -1
  55. package/dist/cjs/kol-icon-font-awesome.cjs.entry.js.map +1 -1
  56. package/dist/cjs/kol-icon-icofont.cjs.entry.js +1 -1
  57. package/dist/cjs/kol-icon-icofont.cjs.entry.js.map +1 -1
  58. package/dist/cjs/kol-icon.cjs.entry.js +1 -1
  59. package/dist/cjs/kol-icon.cjs.entry.js.map +1 -1
  60. package/dist/cjs/kol-image.cjs.entry.js +1 -1
  61. package/dist/cjs/kol-input-adapter-leanup.cjs.entry.js +1 -1
  62. package/dist/cjs/kol-input-adapter-leanup.cjs.entry.js.map +1 -1
  63. package/dist/cjs/kol-input-checkbox.cjs.entry.js +1 -1
  64. package/dist/cjs/kol-input-checkbox.cjs.entry.js.map +1 -1
  65. package/dist/cjs/kol-input-color.cjs.entry.js +1 -1
  66. package/dist/cjs/kol-input-color.cjs.entry.js.map +1 -1
  67. package/dist/cjs/kol-input-date.cjs.entry.js +1 -1
  68. package/dist/cjs/kol-input-date.cjs.entry.js.map +1 -1
  69. package/dist/cjs/kol-input-email.cjs.entry.js +1 -1
  70. package/dist/cjs/kol-input-email.cjs.entry.js.map +1 -1
  71. package/dist/cjs/kol-input-file.cjs.entry.js +1 -1
  72. package/dist/cjs/kol-input-file.cjs.entry.js.map +1 -1
  73. package/dist/cjs/kol-input-number.cjs.entry.js +1 -1
  74. package/dist/cjs/kol-input-number.cjs.entry.js.map +1 -1
  75. package/dist/cjs/kol-input-password.cjs.entry.js +1 -1
  76. package/dist/cjs/kol-input-password.cjs.entry.js.map +1 -1
  77. package/dist/cjs/kol-input-radio-group.cjs.entry.js +1 -1
  78. package/dist/cjs/kol-input-radio.cjs.entry.js +1 -1
  79. package/dist/cjs/kol-input-radio.cjs.entry.js.map +1 -1
  80. package/dist/cjs/kol-input-range.cjs.entry.js +1 -1
  81. package/dist/cjs/kol-input-range.cjs.entry.js.map +1 -1
  82. package/dist/cjs/kol-input-text.cjs.entry.js +1 -1
  83. package/dist/cjs/kol-input-text.cjs.entry.js.map +1 -1
  84. package/dist/cjs/kol-kolibri.cjs.entry.js +1 -1
  85. package/dist/cjs/kol-link-button.cjs.entry.js +1 -1
  86. package/dist/cjs/kol-link-group.cjs.entry.js +1 -1
  87. package/dist/cjs/kol-link-wc.cjs.entry.js +1 -1
  88. package/dist/cjs/kol-logo.cjs.entry.js +1 -1
  89. package/dist/cjs/kol-modal.cjs.entry.js +1 -1
  90. package/dist/cjs/kol-nav.cjs.entry.js +1 -1
  91. package/dist/cjs/kol-pagination.cjs.entry.js +1 -1
  92. package/dist/cjs/kol-pagination.cjs.entry.js.map +1 -1
  93. package/dist/cjs/kol-popover.cjs.entry.js +1 -1
  94. package/dist/cjs/kol-progress.cjs.entry.js +1 -1
  95. package/dist/cjs/kol-quote.cjs.entry.js +1 -1
  96. package/dist/cjs/kol-select.cjs.entry.js +1 -1
  97. package/dist/cjs/kol-select.cjs.entry.js.map +1 -1
  98. package/dist/cjs/kol-skip-nav.cjs.entry.js +1 -1
  99. package/dist/cjs/kol-span-wc.cjs.entry.js +1 -1
  100. package/dist/cjs/kol-spin.cjs.entry.js +1 -1
  101. package/dist/cjs/kol-split-button.cjs.entry.js +1 -1
  102. package/dist/cjs/kol-symbol.cjs.entry.js +1 -1
  103. package/dist/cjs/kol-table.cjs.entry.js +1 -1
  104. package/dist/cjs/kol-tabs.cjs.entry.js +1 -1
  105. package/dist/cjs/kol-tabs.cjs.entry.js.map +1 -1
  106. package/dist/cjs/kol-textarea.cjs.entry.js +1 -1
  107. package/dist/cjs/kol-textarea.cjs.entry.js.map +1 -1
  108. package/dist/cjs/kol-toast.cjs.entry.js +1 -1
  109. package/dist/cjs/kol-tooltip.cjs.entry.js +1 -1
  110. package/dist/cjs/kol-version.cjs.entry.js +1 -1
  111. package/dist/cjs/kolibri.cjs.js +1 -1
  112. package/dist/cjs/{label-5738ac71.js → label-f31696ce.js} +1 -1
  113. package/dist/cjs/{label-5738ac71.js.map → label-f31696ce.js.map} +1 -1
  114. package/dist/cjs/loader.cjs.js +1 -1
  115. package/dist/cjs/prop.validators-7219caea.js +4 -0
  116. package/dist/cjs/prop.validators-7219caea.js.map +1 -0
  117. package/dist/cjs/show-a8907ed7.js +4 -0
  118. package/dist/cjs/{show-942951b7.js.map → show-a8907ed7.js.map} +1 -1
  119. package/dist/cjs/{tab-index-31c874b2.js → tab-index-fd4498b0.js} +1 -1
  120. package/dist/cjs/{tab-index-31c874b2.js.map → tab-index-fd4498b0.js.map} +1 -1
  121. package/dist/cjs/validation-6faf86e0.js +4 -0
  122. package/dist/cjs/{validation-6c112462.js.map → validation-6faf86e0.js.map} +1 -1
  123. package/dist/cjs/{validation-1f68fe35.js → validation-8cba92a6.js} +1 -1
  124. package/dist/cjs/{validation-1f68fe35.js.map → validation-8cba92a6.js.map} +1 -1
  125. package/dist/components/component13.js +1 -1
  126. package/dist/components/component13.js.map +1 -1
  127. package/dist/components/component14.js +1 -1
  128. package/dist/components/component14.js.map +1 -1
  129. package/dist/components/component15.js +1 -1
  130. package/dist/components/component15.js.map +1 -1
  131. package/dist/components/component2.js +1 -1
  132. package/dist/components/component2.js.map +1 -1
  133. package/dist/components/component5.js +1 -1
  134. package/dist/components/component5.js.map +1 -1
  135. package/dist/components/controller.js +1 -1
  136. package/dist/components/controller.js.map +1 -1
  137. package/dist/components/devtools.js +1 -1
  138. package/dist/components/devtools.js.map +1 -1
  139. package/dist/components/floating-ui.dom.esm.js +1 -1
  140. package/dist/components/floating-ui.dom.esm.js.map +1 -1
  141. package/dist/components/kol-breadcrumb.js.map +1 -1
  142. package/dist/components/kol-icon-font-awesome.js +1 -1
  143. package/dist/components/kol-icon-font-awesome.js.map +1 -1
  144. package/dist/components/kol-icon-icofont.js +1 -1
  145. package/dist/components/kol-icon-icofont.js.map +1 -1
  146. package/dist/components/kol-input-adapter-leanup.js +1 -1
  147. package/dist/components/kol-input-adapter-leanup.js.map +1 -1
  148. package/dist/components/kol-input-checkbox.js +1 -1
  149. package/dist/components/kol-input-checkbox.js.map +1 -1
  150. package/dist/components/kol-input-color.js +1 -1
  151. package/dist/components/kol-input-color.js.map +1 -1
  152. package/dist/components/kol-input-date.js +1 -1
  153. package/dist/components/kol-input-date.js.map +1 -1
  154. package/dist/components/kol-input-email.js +1 -1
  155. package/dist/components/kol-input-email.js.map +1 -1
  156. package/dist/components/kol-input-file.js +1 -1
  157. package/dist/components/kol-input-file.js.map +1 -1
  158. package/dist/components/kol-input-number.js +1 -1
  159. package/dist/components/kol-input-number.js.map +1 -1
  160. package/dist/components/kol-input-password.js +1 -1
  161. package/dist/components/kol-input-password.js.map +1 -1
  162. package/dist/components/kol-input-range.js +1 -1
  163. package/dist/components/kol-input-range.js.map +1 -1
  164. package/dist/components/kol-input-text.js +1 -1
  165. package/dist/components/kol-input-text.js.map +1 -1
  166. package/dist/components/kol-tabs.js +1 -1
  167. package/dist/components/kol-tabs.js.map +1 -1
  168. package/dist/components/kol-textarea.js +1 -1
  169. package/dist/components/kol-textarea.js.map +1 -1
  170. package/dist/components/prop.validators.js +1 -1
  171. package/dist/components/prop.validators.js.map +1 -1
  172. package/dist/esm/{a11y.tipps-e607b8b3.js → a11y.tipps-9f948961.js} +1 -1
  173. package/dist/esm/{a11y.tipps-e607b8b3.js.map → a11y.tipps-9f948961.js.map} +1 -1
  174. package/dist/esm/app-globals-bf9eb17a.js +4 -0
  175. package/dist/esm/{app-globals-1811b38e.js.map → app-globals-bf9eb17a.js.map} +1 -1
  176. package/dist/esm/{aria-selected-d90aa300.js → aria-selected-b9d7d1e4.js} +1 -1
  177. package/dist/esm/{aria-selected-d90aa300.js.map → aria-selected-b9d7d1e4.js.map} +1 -1
  178. package/dist/esm/{button-link-2ad7f3cf.js → button-link-99acae48.js} +1 -1
  179. package/dist/esm/{button-link-2ad7f3cf.js.map → button-link-99acae48.js.map} +1 -1
  180. package/dist/esm/{color-9d0ce5e3.js → color-408da8e8.js} +1 -1
  181. package/dist/esm/{color-9d0ce5e3.js.map → color-408da8e8.js.map} +1 -1
  182. package/dist/esm/{controller-ff99125c.js → controller-31db8bf4.js} +1 -1
  183. package/dist/esm/{controller-ff99125c.js.map → controller-31db8bf4.js.map} +1 -1
  184. package/dist/esm/{controller-0a60db6b.js → controller-3391cc2d.js} +1 -1
  185. package/dist/esm/{controller-0a60db6b.js.map → controller-3391cc2d.js.map} +1 -1
  186. package/dist/esm/{controller-d064cead.js → controller-6ed90cd7.js} +1 -1
  187. package/dist/esm/{controller-d064cead.js.map → controller-6ed90cd7.js.map} +1 -1
  188. package/dist/esm/controller-b036f128.js +4 -0
  189. package/dist/esm/controller-b036f128.js.map +1 -0
  190. package/dist/esm/controller-b26721c9.js +4 -0
  191. package/dist/esm/controller-b26721c9.js.map +1 -0
  192. package/dist/esm/{controller-3b1a37ac.js → controller-f8056e1a.js} +1 -1
  193. package/dist/esm/{controller-3b1a37ac.js.map → controller-f8056e1a.js.map} +1 -1
  194. package/dist/esm/{controller-icon-ba3c5351.js → controller-icon-7b8f547d.js} +1 -1
  195. package/dist/esm/{controller-icon-ba3c5351.js.map → controller-icon-7b8f547d.js.map} +1 -1
  196. package/dist/esm/{dev.utils-8aef00f6.js → dev.utils-4290338e.js} +1 -1
  197. package/dist/esm/{dev.utils-8aef00f6.js.map → dev.utils-4290338e.js.map} +1 -1
  198. package/dist/esm/devtools-57a6a46f.js +4 -0
  199. package/dist/esm/devtools-57a6a46f.js.map +1 -0
  200. package/dist/esm/{disabled-cac31f02.js → disabled-559fd371.js} +1 -1
  201. package/dist/esm/{disabled-cac31f02.js.map → disabled-559fd371.js.map} +1 -1
  202. package/dist/esm/floating-ui.dom.esm-26e61da8.js +4 -0
  203. package/dist/esm/floating-ui.dom.esm-26e61da8.js.map +1 -0
  204. package/dist/esm/{has-closer-268d165e.js → has-closer-62a48dbd.js} +1 -1
  205. package/dist/esm/{has-closer-268d165e.js.map → has-closer-62a48dbd.js.map} +1 -1
  206. package/dist/esm/{hide-label-e9f288ac.js → hide-label-9248468d.js} +1 -1
  207. package/dist/esm/{hide-label-e9f288ac.js.map → hide-label-9248468d.js.map} +1 -1
  208. package/dist/esm/{i18n-64b07ed9.js → i18n-23b83118.js} +1 -1
  209. package/dist/esm/{i18n-64b07ed9.js.map → i18n-23b83118.js.map} +1 -1
  210. package/dist/esm/{icon-278d567d.js → icon-e03e73f6.js} +1 -1
  211. package/dist/esm/{icon-278d567d.js.map → icon-e03e73f6.js.map} +1 -1
  212. package/dist/esm/index.js +1 -1
  213. package/dist/esm/kol-abbr.entry.js +1 -1
  214. package/dist/esm/kol-accordion.entry.js +1 -1
  215. package/dist/esm/kol-alert-wc_2.entry.js +1 -1
  216. package/dist/esm/kol-badge.entry.js +1 -1
  217. package/dist/esm/kol-breadcrumb.entry.js +1 -1
  218. package/dist/esm/kol-breadcrumb.entry.js.map +1 -1
  219. package/dist/esm/kol-button-wc_2.entry.js +1 -1
  220. package/dist/esm/kol-button-wc_2.entry.js.map +1 -1
  221. package/dist/esm/kol-card.entry.js +1 -1
  222. package/dist/esm/kol-details.entry.js +1 -1
  223. package/dist/esm/kol-form.entry.js +1 -1
  224. package/dist/esm/kol-icon-font-awesome.entry.js +1 -1
  225. package/dist/esm/kol-icon-font-awesome.entry.js.map +1 -1
  226. package/dist/esm/kol-icon-icofont.entry.js +1 -1
  227. package/dist/esm/kol-icon-icofont.entry.js.map +1 -1
  228. package/dist/esm/kol-icon.entry.js +1 -1
  229. package/dist/esm/kol-icon.entry.js.map +1 -1
  230. package/dist/esm/kol-image.entry.js +1 -1
  231. package/dist/esm/kol-input-adapter-leanup.entry.js +1 -1
  232. package/dist/esm/kol-input-adapter-leanup.entry.js.map +1 -1
  233. package/dist/esm/kol-input-checkbox.entry.js +1 -1
  234. package/dist/esm/kol-input-checkbox.entry.js.map +1 -1
  235. package/dist/esm/kol-input-color.entry.js +1 -1
  236. package/dist/esm/kol-input-color.entry.js.map +1 -1
  237. package/dist/esm/kol-input-date.entry.js +1 -1
  238. package/dist/esm/kol-input-date.entry.js.map +1 -1
  239. package/dist/esm/kol-input-email.entry.js +1 -1
  240. package/dist/esm/kol-input-email.entry.js.map +1 -1
  241. package/dist/esm/kol-input-file.entry.js +1 -1
  242. package/dist/esm/kol-input-file.entry.js.map +1 -1
  243. package/dist/esm/kol-input-number.entry.js +1 -1
  244. package/dist/esm/kol-input-number.entry.js.map +1 -1
  245. package/dist/esm/kol-input-password.entry.js +1 -1
  246. package/dist/esm/kol-input-password.entry.js.map +1 -1
  247. package/dist/esm/kol-input-radio-group.entry.js +1 -1
  248. package/dist/esm/kol-input-radio.entry.js +1 -1
  249. package/dist/esm/kol-input-radio.entry.js.map +1 -1
  250. package/dist/esm/kol-input-range.entry.js +1 -1
  251. package/dist/esm/kol-input-range.entry.js.map +1 -1
  252. package/dist/esm/kol-input-text.entry.js +1 -1
  253. package/dist/esm/kol-input-text.entry.js.map +1 -1
  254. package/dist/esm/kol-kolibri.entry.js +1 -1
  255. package/dist/esm/kol-link-button.entry.js +1 -1
  256. package/dist/esm/kol-link-group.entry.js +1 -1
  257. package/dist/esm/kol-link-wc.entry.js +1 -1
  258. package/dist/esm/kol-logo.entry.js +1 -1
  259. package/dist/esm/kol-modal.entry.js +1 -1
  260. package/dist/esm/kol-nav.entry.js +1 -1
  261. package/dist/esm/kol-pagination.entry.js +1 -1
  262. package/dist/esm/kol-pagination.entry.js.map +1 -1
  263. package/dist/esm/kol-popover.entry.js +1 -1
  264. package/dist/esm/kol-progress.entry.js +1 -1
  265. package/dist/esm/kol-quote.entry.js +1 -1
  266. package/dist/esm/kol-select.entry.js +1 -1
  267. package/dist/esm/kol-select.entry.js.map +1 -1
  268. package/dist/esm/kol-skip-nav.entry.js +1 -1
  269. package/dist/esm/kol-span-wc.entry.js +1 -1
  270. package/dist/esm/kol-spin.entry.js +1 -1
  271. package/dist/esm/kol-split-button.entry.js +1 -1
  272. package/dist/esm/kol-symbol.entry.js +1 -1
  273. package/dist/esm/kol-table.entry.js +1 -1
  274. package/dist/esm/kol-tabs.entry.js +1 -1
  275. package/dist/esm/kol-tabs.entry.js.map +1 -1
  276. package/dist/esm/kol-textarea.entry.js +1 -1
  277. package/dist/esm/kol-textarea.entry.js.map +1 -1
  278. package/dist/esm/kol-toast.entry.js +1 -1
  279. package/dist/esm/kol-tooltip.entry.js +1 -1
  280. package/dist/esm/kol-version.entry.js +1 -1
  281. package/dist/esm/kolibri.js +1 -1
  282. package/dist/esm/{label-bd9566f6.js → label-223fef8f.js} +1 -1
  283. package/dist/esm/{label-bd9566f6.js.map → label-223fef8f.js.map} +1 -1
  284. package/dist/esm/loader.js +1 -1
  285. package/dist/esm/prop.validators-601f1068.js +4 -0
  286. package/dist/esm/{prop.validators-683bb1d0.js.map → prop.validators-601f1068.js.map} +1 -1
  287. package/dist/esm/{show-2b9058c9.js → show-6d33a33f.js} +1 -1
  288. package/dist/esm/{show-2b9058c9.js.map → show-6d33a33f.js.map} +1 -1
  289. package/dist/esm/{tab-index-6d37f269.js → tab-index-fc60df7a.js} +1 -1
  290. package/dist/esm/{tab-index-6d37f269.js.map → tab-index-fc60df7a.js.map} +1 -1
  291. package/dist/esm/validation-4acc18ad.js +4 -0
  292. package/dist/esm/{validation-1f01325c.js.map → validation-4acc18ad.js.map} +1 -1
  293. package/dist/esm/{validation-0efb75d3.js → validation-5300d0a1.js} +1 -1
  294. package/dist/esm/{validation-0efb75d3.js.map → validation-5300d0a1.js.map} +1 -1
  295. package/dist/kolibri/{a11y.tipps-e607b8b3.js → a11y.tipps-9f948961.js} +1 -1
  296. package/dist/kolibri/app-globals-bf9eb17a.js +4 -0
  297. package/dist/kolibri/{app-globals-1811b38e.js.map → app-globals-bf9eb17a.js.map} +1 -1
  298. package/dist/kolibri/{aria-selected-d90aa300.js → aria-selected-b9d7d1e4.js} +1 -1
  299. package/dist/kolibri/assets/simulations/form-simulation.js +1 -1
  300. package/dist/kolibri/{button-link-2ad7f3cf.js → button-link-99acae48.js} +1 -1
  301. package/dist/kolibri/{color-9d0ce5e3.js → color-408da8e8.js} +1 -1
  302. package/dist/kolibri/{controller-ff99125c.js → controller-31db8bf4.js} +1 -1
  303. package/dist/kolibri/{controller-0a60db6b.js → controller-3391cc2d.js} +1 -1
  304. package/dist/kolibri/{controller-d064cead.js → controller-6ed90cd7.js} +1 -1
  305. package/dist/kolibri/{controller-ca0fe64f.js → controller-b036f128.js} +1 -1
  306. package/dist/kolibri/controller-b036f128.js.map +1 -0
  307. package/dist/kolibri/controller-b26721c9.js +4 -0
  308. package/dist/kolibri/controller-b26721c9.js.map +1 -0
  309. package/dist/kolibri/{controller-3b1a37ac.js → controller-f8056e1a.js} +1 -1
  310. package/dist/kolibri/controller-icon-7b8f547d.js +4 -0
  311. package/dist/kolibri/dev.utils-4290338e.js.map +1 -0
  312. package/dist/kolibri/{devtools-eaaafe9d.js → devtools-57a6a46f.js} +1 -1
  313. package/dist/kolibri/devtools-57a6a46f.js.map +1 -0
  314. package/dist/kolibri/{disabled-cac31f02.js → disabled-559fd371.js} +1 -1
  315. package/dist/kolibri/floating-ui.dom.esm-26e61da8.js +4 -0
  316. package/dist/kolibri/floating-ui.dom.esm-26e61da8.js.map +1 -0
  317. package/dist/kolibri/has-closer-62a48dbd.js +4 -0
  318. package/dist/kolibri/hide-label-9248468d.js +4 -0
  319. package/dist/kolibri/{i18n-64b07ed9.js → i18n-23b83118.js} +1 -1
  320. package/dist/kolibri/{icon-278d567d.js → icon-e03e73f6.js} +1 -1
  321. package/dist/kolibri/index.esm.js +1 -1
  322. package/dist/kolibri/kol-abbr.entry.js +1 -1
  323. package/dist/kolibri/kol-accordion.entry.js +1 -1
  324. package/dist/kolibri/kol-alert-wc_2.entry.js +1 -1
  325. package/dist/kolibri/kol-badge.entry.js +1 -1
  326. package/dist/kolibri/kol-breadcrumb.entry.js +1 -1
  327. package/dist/kolibri/kol-breadcrumb.entry.js.map +1 -1
  328. package/dist/kolibri/kol-button-wc_2.entry.js +1 -1
  329. package/dist/kolibri/kol-button-wc_2.entry.js.map +1 -1
  330. package/dist/kolibri/kol-card.entry.js +1 -1
  331. package/dist/kolibri/kol-details.entry.js +1 -1
  332. package/dist/kolibri/kol-form.entry.js +1 -1
  333. package/dist/kolibri/kol-icon-font-awesome.entry.js +1 -1
  334. package/dist/kolibri/kol-icon-font-awesome.entry.js.map +1 -1
  335. package/dist/kolibri/kol-icon-icofont.entry.js +1 -1
  336. package/dist/kolibri/kol-icon-icofont.entry.js.map +1 -1
  337. package/dist/kolibri/kol-icon.entry.js +1 -1
  338. package/dist/kolibri/kol-icon.entry.js.map +1 -1
  339. package/dist/kolibri/kol-image.entry.js +1 -1
  340. package/dist/kolibri/kol-input-adapter-leanup.entry.js +1 -1
  341. package/dist/kolibri/kol-input-adapter-leanup.entry.js.map +1 -1
  342. package/dist/kolibri/kol-input-checkbox.entry.js +1 -1
  343. package/dist/kolibri/kol-input-checkbox.entry.js.map +1 -1
  344. package/dist/kolibri/kol-input-color.entry.js +1 -1
  345. package/dist/kolibri/kol-input-color.entry.js.map +1 -1
  346. package/dist/kolibri/kol-input-date.entry.js +1 -1
  347. package/dist/kolibri/kol-input-date.entry.js.map +1 -1
  348. package/dist/kolibri/kol-input-email.entry.js +1 -1
  349. package/dist/kolibri/kol-input-email.entry.js.map +1 -1
  350. package/dist/kolibri/kol-input-file.entry.js +1 -1
  351. package/dist/kolibri/kol-input-file.entry.js.map +1 -1
  352. package/dist/kolibri/kol-input-number.entry.js +1 -1
  353. package/dist/kolibri/kol-input-number.entry.js.map +1 -1
  354. package/dist/kolibri/kol-input-password.entry.js +1 -1
  355. package/dist/kolibri/kol-input-password.entry.js.map +1 -1
  356. package/dist/kolibri/kol-input-radio-group.entry.js +1 -1
  357. package/dist/kolibri/kol-input-radio.entry.js +1 -1
  358. package/dist/kolibri/kol-input-radio.entry.js.map +1 -1
  359. package/dist/kolibri/kol-input-range.entry.js +1 -1
  360. package/dist/kolibri/kol-input-range.entry.js.map +1 -1
  361. package/dist/kolibri/kol-input-text.entry.js +1 -1
  362. package/dist/kolibri/kol-input-text.entry.js.map +1 -1
  363. package/dist/kolibri/kol-kolibri.entry.js +1 -1
  364. package/dist/kolibri/kol-link-button.entry.js +1 -1
  365. package/dist/kolibri/kol-link-group.entry.js +1 -1
  366. package/dist/kolibri/kol-link-wc.entry.js +1 -1
  367. package/dist/kolibri/kol-link-wc.entry.js.map +1 -1
  368. package/dist/kolibri/kol-logo.entry.js +1 -1
  369. package/dist/kolibri/kol-modal.entry.js +1 -1
  370. package/dist/kolibri/kol-nav.entry.js +1 -1
  371. package/dist/kolibri/kol-pagination.entry.js +1 -1
  372. package/dist/kolibri/kol-pagination.entry.js.map +1 -1
  373. package/dist/kolibri/kol-popover.entry.js +1 -1
  374. package/dist/kolibri/kol-progress.entry.js +1 -1
  375. package/dist/kolibri/kol-quote.entry.js +1 -1
  376. package/dist/kolibri/kol-select.entry.js +1 -1
  377. package/dist/kolibri/kol-select.entry.js.map +1 -1
  378. package/dist/kolibri/kol-skip-nav.entry.js +1 -1
  379. package/dist/kolibri/kol-span-wc.entry.js +1 -1
  380. package/dist/kolibri/kol-spin.entry.js +1 -1
  381. package/dist/kolibri/kol-split-button.entry.js +1 -1
  382. package/dist/kolibri/kol-symbol.entry.js +1 -1
  383. package/dist/kolibri/kol-symbol.entry.js.map +1 -1
  384. package/dist/kolibri/kol-table.entry.js +1 -1
  385. package/dist/kolibri/kol-tabs.entry.js +1 -1
  386. package/dist/kolibri/kol-tabs.entry.js.map +1 -1
  387. package/dist/kolibri/kol-textarea.entry.js +1 -1
  388. package/dist/kolibri/kol-textarea.entry.js.map +1 -1
  389. package/dist/kolibri/kol-toast.entry.js +1 -1
  390. package/dist/kolibri/kol-tooltip.entry.js +1 -1
  391. package/dist/kolibri/kol-version.entry.js +1 -1
  392. package/dist/kolibri/kolibri.esm.js +1 -1
  393. package/dist/kolibri/label-223fef8f.js +4 -0
  394. package/dist/kolibri/{label-bd9566f6.js.map → label-223fef8f.js.map} +1 -1
  395. package/dist/kolibri/{prop.validators-683bb1d0.js → prop.validators-601f1068.js} +1 -1
  396. package/dist/kolibri/prop.validators-601f1068.js.map +1 -0
  397. package/dist/kolibri/show-6d33a33f.js +4 -0
  398. package/dist/kolibri/{tab-index-6d37f269.js → tab-index-fc60df7a.js} +1 -1
  399. package/dist/kolibri/validation-4acc18ad.js +4 -0
  400. package/dist/kolibri/{validation-0efb75d3.js → validation-5300d0a1.js} +1 -1
  401. package/dist/types/components/breadcrumb/types.d.ts +2 -2
  402. package/dist/types/components/icon/component.d.ts +1 -1
  403. package/dist/types/components/input-adapter-leanup/controller.d.ts +7 -4
  404. package/dist/types/components/input-checkbox/component.d.ts +3 -2
  405. package/dist/types/components/input-checkbox/controller.d.ts +3 -1
  406. package/dist/types/components/input-checkbox/types.d.ts +5 -3
  407. package/dist/types/components.d.ts +4 -2
  408. package/dist/types/types/unknown.d.ts +1 -0
  409. package/dist/types/utils/dev.utils.d.ts +1 -1
  410. package/doc/abbr.md +1 -1
  411. package/doc/accordion.md +1 -1
  412. package/doc/alert.md +1 -1
  413. package/doc/badge.md +1 -3
  414. package/doc/breadcrumb.md +3 -3
  415. package/doc/button-group.md +2 -2
  416. package/doc/button.md +2 -2
  417. package/doc/details.md +1 -1
  418. package/doc/heading.md +0 -4
  419. package/doc/icon.md +6 -6
  420. package/doc/image.md +4 -4
  421. package/doc/input-checkbox.md +3 -3
  422. package/doc/input-color.md +1 -1
  423. package/doc/input-date.md +4 -4
  424. package/doc/input-email.md +2 -2
  425. package/doc/input-file.md +2 -2
  426. package/doc/input-number.md +1 -1
  427. package/doc/input-password.md +1 -1
  428. package/doc/input-radio.md +5 -5
  429. package/doc/input-range.md +1 -1
  430. package/doc/input-text.md +2 -2
  431. package/doc/link-group.md +0 -2
  432. package/doc/link.md +2 -4
  433. package/doc/logo.md +0 -8
  434. package/doc/modal.md +4 -4
  435. package/doc/nav.md +0 -2
  436. package/doc/pagination.md +0 -4
  437. package/doc/progress.md +2 -2
  438. package/doc/quote.md +5 -5
  439. package/doc/skip-nav.md +1 -1
  440. package/doc/spin.md +2 -6
  441. package/doc/split-button.md +1 -1
  442. package/doc/table.md +13 -13
  443. package/doc/tabs.md +4 -4
  444. package/doc/textarea.md +1 -1
  445. package/doc/toast.md +0 -2
  446. package/doc/tooltip.md +1 -1
  447. package/doc/version.md +0 -8
  448. package/jest-test-results.json +1 -1
  449. package/package.json +1 -1
  450. package/vscode-custom-data.json +2 -2
  451. package/dist/cjs/controller-20c47dac.js +0 -4
  452. package/dist/cjs/controller-20c47dac.js.map +0 -1
  453. package/dist/cjs/controller-beb0e753.js +0 -4
  454. package/dist/cjs/controller-beb0e753.js.map +0 -1
  455. package/dist/cjs/dev.utils-b2b6f024.js +0 -4
  456. package/dist/cjs/devtools-60ad513c.js.map +0 -1
  457. package/dist/cjs/floating-ui.dom.esm-c11b0ec1.js +0 -4
  458. package/dist/cjs/floating-ui.dom.esm-c11b0ec1.js.map +0 -1
  459. package/dist/cjs/has-closer-7d377e88.js +0 -4
  460. package/dist/cjs/hide-label-9bf6abe6.js +0 -4
  461. package/dist/cjs/prop.validators-8a027482.js +0 -4
  462. package/dist/cjs/prop.validators-8a027482.js.map +0 -1
  463. package/dist/cjs/show-942951b7.js +0 -4
  464. package/dist/cjs/validation-6c112462.js +0 -4
  465. package/dist/esm/app-globals-1811b38e.js +0 -4
  466. package/dist/esm/controller-ca0fe64f.js +0 -4
  467. package/dist/esm/controller-ca0fe64f.js.map +0 -1
  468. package/dist/esm/controller-d9fb3dc1.js +0 -4
  469. package/dist/esm/controller-d9fb3dc1.js.map +0 -1
  470. package/dist/esm/devtools-eaaafe9d.js +0 -4
  471. package/dist/esm/devtools-eaaafe9d.js.map +0 -1
  472. package/dist/esm/floating-ui.dom.esm-805abd08.js +0 -4
  473. package/dist/esm/floating-ui.dom.esm-805abd08.js.map +0 -1
  474. package/dist/esm/prop.validators-683bb1d0.js +0 -4
  475. package/dist/esm/validation-1f01325c.js +0 -4
  476. package/dist/kolibri/app-globals-1811b38e.js +0 -4
  477. package/dist/kolibri/controller-ca0fe64f.js.map +0 -1
  478. package/dist/kolibri/controller-d9fb3dc1.js +0 -4
  479. package/dist/kolibri/controller-d9fb3dc1.js.map +0 -1
  480. package/dist/kolibri/controller-icon-ba3c5351.js +0 -4
  481. package/dist/kolibri/dev.utils-8aef00f6.js.map +0 -1
  482. package/dist/kolibri/devtools-eaaafe9d.js.map +0 -1
  483. package/dist/kolibri/floating-ui.dom.esm-805abd08.js +0 -4
  484. package/dist/kolibri/floating-ui.dom.esm-805abd08.js.map +0 -1
  485. package/dist/kolibri/has-closer-268d165e.js +0 -4
  486. package/dist/kolibri/hide-label-e9f288ac.js +0 -4
  487. package/dist/kolibri/label-bd9566f6.js +0 -4
  488. package/dist/kolibri/prop.validators-683bb1d0.js.map +0 -1
  489. package/dist/kolibri/show-2b9058c9.js +0 -4
  490. package/dist/kolibri/validation-1f01325c.js +0 -4
  491. /package/dist/kolibri/{a11y.tipps-e607b8b3.js.map → a11y.tipps-9f948961.js.map} +0 -0
  492. /package/dist/kolibri/{aria-selected-d90aa300.js.map → aria-selected-b9d7d1e4.js.map} +0 -0
  493. /package/dist/kolibri/{button-link-2ad7f3cf.js.map → button-link-99acae48.js.map} +0 -0
  494. /package/dist/kolibri/{color-9d0ce5e3.js.map → color-408da8e8.js.map} +0 -0
  495. /package/dist/kolibri/{controller-ff99125c.js.map → controller-31db8bf4.js.map} +0 -0
  496. /package/dist/kolibri/{controller-0a60db6b.js.map → controller-3391cc2d.js.map} +0 -0
  497. /package/dist/kolibri/{controller-d064cead.js.map → controller-6ed90cd7.js.map} +0 -0
  498. /package/dist/kolibri/{controller-3b1a37ac.js.map → controller-f8056e1a.js.map} +0 -0
  499. /package/dist/kolibri/{controller-icon-ba3c5351.js.map → controller-icon-7b8f547d.js.map} +0 -0
  500. /package/dist/kolibri/{dev.utils-8aef00f6.js → dev.utils-4290338e.js} +0 -0
  501. /package/dist/kolibri/{disabled-cac31f02.js.map → disabled-559fd371.js.map} +0 -0
  502. /package/dist/kolibri/{has-closer-268d165e.js.map → has-closer-62a48dbd.js.map} +0 -0
  503. /package/dist/kolibri/{hide-label-e9f288ac.js.map → hide-label-9248468d.js.map} +0 -0
  504. /package/dist/kolibri/{i18n-64b07ed9.js.map → i18n-23b83118.js.map} +0 -0
  505. /package/dist/kolibri/{icon-278d567d.js.map → icon-e03e73f6.js.map} +0 -0
  506. /package/dist/kolibri/{show-2b9058c9.js.map → show-6d33a33f.js.map} +0 -0
  507. /package/dist/kolibri/{tab-index-6d37f269.js.map → tab-index-fc60df7a.js.map} +0 -0
  508. /package/dist/kolibri/{validation-1f01325c.js.map → validation-4acc18ad.js.map} +0 -0
  509. /package/dist/kolibri/{validation-0efb75d3.js.map → validation-5300d0a1.js.map} +0 -0
@@ -1 +1 @@
1
- {"version":3,"names":["AVAILABLE_HORIZONTAL_ALIGNMENT_VALUES","Set","AVAILABLE_VERTICAL_ALIGNMENT_VALUES","AVAILABLE_ALIGNMENT_VALUES","validateAlignment","component","propName","value","watchValidator","defaultStyleCss","KolTabs","this","onCreateLabel","translate","showCreateTab","nextPossibleTabIndex","tabs","offset","step","length","_disabled","onKeyDown","event","timeout","setTimeout","clearTimeout","selectedIndex","key","state","_tabs","_selected","onSelect","onClickSelect","index","onMouseDown","stopPropagation","callbacks","onClick","catchTabPanelHost","el","tabPanelHost","selectNextNotDisabledTab","selected","upOrDown","initialSelected","Array","isArray","devHint","syncSelectedAndTabs","nextValue","nextState","_component","set","handleTabPanels","HTMLDivElement","i","children","div","document","createElement","setAttribute","slot","appendChild","_a","host","HTMLCollection","_b","_c","onCreate","_on","_label","_tabsAlign","renderButtonGroup","h","role","map","button","_icon","_hideLabel","_iconOnly","_tabIndex","_tooltipAlign","_variant","undefined","_customClass","_ariaControls","_ariaSelected","_id","_role","_value","class","render","Host","ref","tabPanelsElement","validateAriaLabel","validateLabel","validateOn","featureHint","label","Log","debug","callback","setState","validateSelected","watchNumber","hooks","beforePatch","validateTabs","watchJsonArrayString","item","uiUxHintMillerscheZahl","validateTabsAlign","componentWillLoad","_ariaLabel","componentDidRender","removeAttribute","focus","selectedTimeout","koliBriQuerySelector"],"sources":["src/utils/validators/alignment.ts","src/components/tabs/style.css?tag=kol-tabs&mode=default&encapsulation=shadow","src/components/tabs/component.tsx"],"sourcesContent":["import { Generic } from '@a11y-ui/core';\n\nimport { Align } from '../../types/props/align';\nimport { watchValidator } from '../prop.validators';\n\nconst AVAILABLE_HORIZONTAL_ALIGNMENT_VALUES = new Set(['\"left\", \"right\"']);\n// export const validateHorizontalAlignment = (component: Generic.Element.Component, propName: string, value?: HorizontalAlignment): void => {\n// \twatchValidator(component, propName, (value) => value === 'left' || value === 'right', AVAILABLE_HORIZONTAL_ALIGNMENT_VALUES, value);\n// };\n\nconst AVAILABLE_VERTICAL_ALIGNMENT_VALUES = new Set(['\"bottom\", \"top\"']);\n// export const validateVertivalAlignment = (component: Generic.Element.Component, propName: string, value?: VerticalAlignment): void => {\n// \twatchValidator(component, propName, (value) => value === 'top' || value === 'bottom', AVAILABLE_VERTICAL_ALIGNMENT_VALUES, value);\n// };\n\nconst AVAILABLE_ALIGNMENT_VALUES = new Set([...AVAILABLE_HORIZONTAL_ALIGNMENT_VALUES, ...AVAILABLE_VERTICAL_ALIGNMENT_VALUES]);\nexport const validateAlignment = (component: Generic.Element.Component, propName: string, value?: Align): void => {\n\twatchValidator(\n\t\tcomponent,\n\t\tpropName,\n\t\t(value) => value === 'bottom' || value === 'left' || value === 'right' || value === 'top',\n\t\tAVAILABLE_ALIGNMENT_VALUES,\n\t\tvalue\n\t);\n};\n","@import url(../style.css);\n@import url(../host-display-block.css);\nkol-button-group-wc {\n\tdisplay: inline-flex;\n\tflex-wrap: wrap;\n}\nkol-button-group-wc button {\n\tborder-bottom-color: transparent;\n\tborder-bottom-style: solid;\n\tdisplay: block;\n}\ndiv.grid,\ndiv[role='tabpanel'] {\n\theight: 100%;\n}\n:host > .tabs-align-right {\n\tdisplay: grid;\n\tgrid-template-columns: 1fr auto;\n}\n:host > .tabs-align-right kol-button-group-wc {\n\tdisplay: grid;\n\torder: 2;\n}\n:host > .tabs-align-left {\n\tdisplay: grid;\n\tgrid-template-columns: auto 1fr;\n}\n:host > .tabs-align-left kol-button-group-wc {\n\tdisplay: grid;\n\torder: 0;\n}\n:host > .tabs-align-bottom {\n\tdisplay: grid;\n\tgrid-template-rows: 1fr auto;\n}\n:host > .tabs-align-bottom kol-button-group-wc {\n\torder: 2;\n}\n:host > .tabs-align-bottom kol-button-group-wc > div {\n\tdisplay: flex;\n}\n:host > .tabs-align-bottom > kol-button-group-wc > div > div:first-child {\n\tmargin: 0 1em 0 0;\n}\n:host > .tabs-align-bottom > kol-button-group-wc > div > div {\n\tmargin: 0 1em;\n}\n:host > .tabs-align-top {\n\tdisplay: grid;\n\tgrid-template-rows: auto 1fr;\n}\n:host > .tabs-align-top kol-button-group-wc {\n\torder: 0;\n}\n:host > .tabs-align-top kol-button-group-wc > div {\n\tdisplay: flex;\n}\n:host > .tabs-align-top > kol-button-group-wc > div > div:first-child {\n\tmargin: 0 1em 0 0;\n}\n:host > .tabs-align-top > kol-button-group-wc > div > div {\n\tmargin: 0 1em;\n}\n:host > div {\n\tdisplay: grid;\n}\n:host > .tabs-align-left kol-button-group-wc,\n:host > .tabs-align-top kol-button-group-wc {\n\torder: 0;\n}\n:host > .tabs-align-bottom kol-button-group-wc,\n:host > .tabs-align-right kol-button-group-wc {\n\torder: 1;\n}\n:host > div.tabs-align-left kol-button-group-wc > div,\n:host > div.tabs-align-left kol-button-group-wc > div > div,\n:host > div.tabs-align-right kol-button-group-wc > div,\n:host > div.tabs-align-right kol-button-group-wc > div > div {\n\tdisplay: grid;\n}\n:host > div.tabs-align-left kol-button-group-wc > div > div kol-button-wc,\n:host > div.tabs-align-right kol-button-group-wc > div > div kol-button-wc {\n\twidth: 100%;\n}\n:host > div.tabs-align-bottom kol-button-group-wc div,\n:host > div.tabs-align-top kol-button-group-wc div {\n\tdisplay: flex;\n\tflex-wrap: wrap;\n}\n","import { Generic } from '@a11y-ui/core';\nimport { Component, Element, h, Host, JSX, Prop, State, Watch } from '@stencil/core';\n\nimport { translate } from '../../i18n';\nimport { KoliBriButtonCallbacks } from '../../types/button-link';\nimport { Stringified } from '../../types/common';\nimport { Align } from '../../types/props/align';\nimport { LabelPropType, validateLabel } from '../../types/props/label';\nimport { devHint, featureHint, uiUxHintMillerscheZahl } from '../../utils/a11y.tipps';\nimport { Log } from '../../utils/dev.utils';\nimport { koliBriQuerySelector, setState, watchJsonArrayString, watchNumber } from '../../utils/prop.validators';\nimport { validateAlignment } from '../../utils/validators/alignment';\nimport { KoliBriTabsAPI, KoliBriTabsCallbacks, KoliBriTabsStates, TabButtonProps } from './types';\n\n// https://www.w3.org/TR/wai-aria-practices-1.1/examples/tabs/tabs-2/tabs.html\n\n@Component({\n\ttag: 'kol-tabs',\n\tstyleUrls: {\n\t\tdefault: './style.css',\n\t},\n\tshadow: true,\n})\nexport class KolTabs implements KoliBriTabsAPI {\n\t@Element() private readonly host?: HTMLKolTabsElement;\n\tprivate tabPanelsElement?: HTMLElement;\n\tprivate onCreateLabel = `${translate('kol-new')} …`;\n\tprivate showCreateTab = false;\n\tprivate selectedTimeout?: ReturnType<typeof setTimeout>;\n\n\tprivate nextPossibleTabIndex = (tabs: TabButtonProps[], offset: number, step: number): number => {\n\t\tif (step > 0) {\n\t\t\tif (offset + step < tabs.length) {\n\t\t\t\tif (tabs[offset + step]._disabled) {\n\t\t\t\t\treturn this.nextPossibleTabIndex(tabs, offset, step + 1);\n\t\t\t\t}\n\t\t\t\treturn offset + step;\n\t\t\t}\n\t\t} else if (step < 0) {\n\t\t\tif (offset + step >= 0) {\n\t\t\t\tif (tabs[offset + step]._disabled) {\n\t\t\t\t\treturn this.nextPossibleTabIndex(tabs, offset, step - 1);\n\t\t\t\t}\n\t\t\t\treturn offset + step;\n\t\t\t}\n\t\t}\n\t\treturn offset;\n\t};\n\n\tprivate onKeyDown = (event: KeyboardEvent) => {\n\t\tconst timeout = setTimeout(() => {\n\t\t\tclearTimeout(timeout);\n\t\t\tlet selectedIndex: number | null = null;\n\t\t\tswitch (event.key) {\n\t\t\t\tcase 'ArrowRight':\n\t\t\t\t\tselectedIndex = this.nextPossibleTabIndex(this.state._tabs, this.state._selected, 1);\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'ArrowLeft':\n\t\t\t\t\tselectedIndex = this.nextPossibleTabIndex(this.state._tabs, this.state._selected, -1);\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t\tif (selectedIndex !== null) {\n\t\t\t\tthis.onSelect(event, selectedIndex, true);\n\t\t\t}\n\t\t}, 250);\n\t};\n\n\tprivate readonly onClickSelect = (event: MouseEvent, index: number): void => {\n\t\tthis.onSelect(event, index, true);\n\t};\n\n\t// private readonly onClickClose = (event: Event, button: TabButtonProps, index: number) => {\n\t// \tevent.stopPropagation();\n\t// \tthis.onClose(button, event, index);\n\t// };\n\n\tprivate readonly onMouseDown = (event: Event): void => {\n\t\tevent.stopPropagation();\n\t};\n\n\tprivate readonly callbacks: KoliBriButtonCallbacks<number> = {\n\t\tonClick: this.onClickSelect,\n\t\tonMouseDown: this.onMouseDown,\n\t};\n\n\tprivate renderButtonGroup() {\n\t\treturn (\n\t\t\t<kol-button-group-wc role=\"tablist\" aria-label={this.state._label} onKeyDown={this.onKeyDown}>\n\t\t\t\t{this.state._tabs.map((button: TabButtonProps, index: number) => (\n\t\t\t\t\t<kol-button-wc\n\t\t\t\t\t\t_disabled={button._disabled}\n\t\t\t\t\t\t_icon={button._icon}\n\t\t\t\t\t\t_hideLabel={button._hideLabel || button._iconOnly}\n\t\t\t\t\t\t_label={button._label} // TODO: ariaLabel-Konzept prüfen\n\t\t\t\t\t\t_on={this.callbacks as KoliBriButtonCallbacks<unknown>}\n\t\t\t\t\t\t_tabIndex={this.state._selected === index ? 0 : -1}\n\t\t\t\t\t\t_tooltipAlign={button._tooltipAlign}\n\t\t\t\t\t\t_variant={this.state._selected === index ? 'custom' : undefined}\n\t\t\t\t\t\t_customClass={this.state._selected === index ? 'selected' : undefined}\n\t\t\t\t\t\t_ariaControls={`tabpanel-${index}`}\n\t\t\t\t\t\t_ariaSelected={this.state._selected === index}\n\t\t\t\t\t\t_id={`tab-${index}`}\n\t\t\t\t\t\t_role=\"tab\"\n\t\t\t\t\t\t_value={index}\n\t\t\t\t\t></kol-button-wc>\n\t\t\t\t))}\n\t\t\t\t{this.showCreateTab && (\n\t\t\t\t\t<kol-button-wc\n\t\t\t\t\t\tclass=\"create-button\"\n\t\t\t\t\t\t_label={this.onCreateLabel}\n\t\t\t\t\t\t_on={{\n\t\t\t\t\t\t\tonClick: this.onCreate,\n\t\t\t\t\t\t}}\n\t\t\t\t\t></kol-button-wc>\n\t\t\t\t)}\n\t\t\t</kol-button-group-wc>\n\t\t);\n\t}\n\n\tprivate tabPanelHost?: HTMLDivElement;\n\n\tprivate readonly catchTabPanelHost = (el?: HTMLDivElement) => {\n\t\tthis.tabPanelHost = el;\n\t};\n\n\tpublic render(): JSX.Element {\n\t\treturn (\n\t\t\t<Host>\n\t\t\t\t<div\n\t\t\t\t\tref={(el) => {\n\t\t\t\t\t\tthis.tabPanelsElement = el as HTMLElement;\n\t\t\t\t\t}}\n\t\t\t\t\tclass={{\n\t\t\t\t\t\t[`tabs-align-${this.state._tabsAlign}`]: true,\n\t\t\t\t\t}}\n\t\t\t\t>\n\t\t\t\t\t{this.renderButtonGroup()}\n\t\t\t\t\t<div ref={this.catchTabPanelHost}>{/* <slot /> */}</div>\n\t\t\t\t</div>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\t/**\n\t * Setzt die sichtbare oder semantische Beschriftung der Komponente (z.B. Aria-Label, Label, Headline, Caption, Summary usw.).\n\t *\n\t * @deprecated use _label instead\n\t */\n\t@Prop() public _ariaLabel?: string;\n\n\t/**\n\t * Setzt die sichtbare oder semantische Beschriftung der Komponente (z.B. Aria-Label, Label, Headline, Caption, Summary usw.).\n\t */\n\t@Prop() public _label?: LabelPropType; // TODO: required in v2\n\n\t/**\n\t * Gibt die Liste der Callback-Funktionen an, die auf Events aufgerufen werden sollen.\n\t */\n\t@Prop() public _on?: KoliBriTabsCallbacks;\n\n\t/**\n\t * Gibt an, welches Tab selektiert sein soll.\n\t */\n\t@Prop({ mutable: true, reflect: true }) public _selected?: number = 0;\n\n\t/**\n\t * Setzt die Daten für die Registrierkarten.\n\t */\n\t@Prop() public _tabs!: Stringified<TabButtonProps[]>;\n\n\t/**\n\t * Setzt die Position der Registrierkarten.\n\t */\n\t@Prop() public _tabsAlign?: Align = 'top';\n\n\t@State() public state: KoliBriTabsStates = {\n\t\t_label: '…', // ⚠ required\n\t\t_selected: 0,\n\t\t_tabs: [],\n\t\t_tabsAlign: 'top',\n\t};\n\n\tprivate selectNextNotDisabledTab = (selected: number, tabs: TabButtonProps[], upOrDown = true, initialSelected?: number): number => {\n\t\tif (selected > tabs.length - 1) {\n\t\t\tselected = tabs.length - 1;\n\t\t}\n\t\tif (selected < 0) {\n\t\t\tselected = 0;\n\t\t}\n\t\tif (Array.isArray(tabs) && tabs[selected]) {\n\t\t\tif (tabs[selected]._disabled) {\n\t\t\t\tif (upOrDown === true) {\n\t\t\t\t\tif (selected < tabs.length - 1) {\n\t\t\t\t\t\treturn this.selectNextNotDisabledTab(selected + 1, tabs, true, initialSelected || selected);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tselected = initialSelected || selected;\n\t\t\t\t\t\tupOrDown = false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (upOrDown === false) {\n\t\t\t\t\tif (selected > 0) {\n\t\t\t\t\t\treturn this.selectNextNotDisabledTab(selected - 1, tabs, false, initialSelected || selected);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tdevHint(`[KolTabs] Alle Tabs sind deaktiviert und somit kann kein Tab angezeigt werden.`);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn selected;\n\t};\n\n\tprivate syncSelectedAndTabs = (nextValue: unknown, nextState: Map<string, unknown>, _component: Generic.Element.Component, key: string) => {\n\t\tlet selected: number;\n\t\tif (key === '_selected') {\n\t\t\tselected = nextValue as number;\n\t\t} else {\n\t\t\tselected = this.state._selected;\n\t\t}\n\t\tlet tabs: TabButtonProps[];\n\t\tif (key === '_tabs') {\n\t\t\ttabs = nextValue as TabButtonProps[];\n\t\t} else {\n\t\t\ttabs = this.state._tabs;\n\t\t}\n\t\tif (tabs.length > 0) {\n\t\t\tnextState.set('_selected', this.selectNextNotDisabledTab(selected, tabs));\n\t\t}\n\t};\n\n\t/**\n\t * @deprecated\n\t */\n\t@Watch('_ariaLabel')\n\tpublic validateAriaLabel(value?: string): void {\n\t\tthis.validateLabel(value);\n\t}\n\n\t@Watch('_label')\n\tpublic validateLabel(value?: LabelPropType): void {\n\t\tvalidateLabel(this, value);\n\t}\n\n\t@Watch('_on')\n\tpublic validateOn(value?: KoliBriTabsCallbacks): void {\n\t\tif (typeof value === 'object' && value !== null) {\n\t\t\tfeatureHint('[KolTabs] Prüfen, wie man auch einen EventCallback einzeln ändern kann.');\n\t\t\tconst callbacks: KoliBriTabsCallbacks = {};\n\t\t\tif (typeof value.onCreate === 'function' || typeof value.onCreate === 'object') {\n\t\t\t\tif (typeof value.onCreate === 'object') {\n\t\t\t\t\tif (typeof value.onCreate.label === 'string' && value.onCreate.label.length > 0) {\n\t\t\t\t\t\tthis.onCreateLabel = value.onCreate.label;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tLog.debug(\n\t\t\t\t\t\t\t`[KolTabs] Der Label-Text für Neu in {\n onCreate: {\n label: string (!),\n callback: Function\n }\n} ist nicht korrekt gesetzt.`\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t\tif (typeof value.onCreate.callback === 'function') {\n\t\t\t\t\t\tcallbacks.onCreate = value.onCreate.callback;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tLog.debug(\n\t\t\t\t\t\t\t`[KolTabs] Die onCreate-Callback-Funktion für Neu in {\n onCreate: {\n label: string,\n callback: Function (!)\n }\n} ist nicht korrekt gesetzt.`\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tcallbacks.onCreate = value.onCreate;\n\t\t\t\t}\n\t\t\t\tthis.showCreateTab = typeof callbacks.onCreate === 'function';\n\t\t\t}\n\t\t\tif (typeof value.onSelect === 'function') {\n\t\t\t\tcallbacks.onSelect = value.onSelect;\n\t\t\t}\n\t\t\tsetState<KoliBriTabsCallbacks>(this, '_on', callbacks);\n\t\t}\n\t}\n\n\t@Watch('_selected')\n\tpublic validateSelected(value?: number): void {\n\t\twatchNumber(this, '_selected', value, {\n\t\t\thooks: {\n\t\t\t\tbeforePatch: this.syncSelectedAndTabs,\n\t\t\t},\n\t\t});\n\t}\n\n\t@Watch('_tabs')\n\tpublic validateTabs(value?: Stringified<TabButtonProps[]>): void {\n\t\twatchJsonArrayString(\n\t\t\tthis,\n\t\t\t'_tabs',\n\t\t\t(item: TabButtonProps) => typeof item === 'object' && item !== null && typeof item._label === 'string' && item._label.length > 0,\n\t\t\tvalue,\n\t\t\tundefined,\n\t\t\t{\n\t\t\t\thooks: {\n\t\t\t\t\tbeforePatch: this.syncSelectedAndTabs,\n\t\t\t\t},\n\t\t\t}\n\t\t);\n\t\tuiUxHintMillerscheZahl('KolTabs', this.state._tabs.length);\n\t}\n\n\t@Watch('_tabsAlign')\n\tpublic validateTabsAlign(value?: Align): void {\n\t\tvalidateAlignment(this, '_tabsAlign', value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tthis.validateLabel(this._label || this._ariaLabel);\n\t\tthis.validateOn(this._on);\n\t\tthis.validateSelected(this._selected);\n\t\tthis.validateTabs(this._tabs);\n\t\tthis.validateTabsAlign(this._tabsAlign);\n\t}\n\n\tprivate readonly handleTabPanels = () => {\n\t\tif (this.tabPanelHost instanceof HTMLDivElement) {\n\t\t\tfor (let i = this.tabPanelHost.children.length; i < this.state._tabs.length; i++) {\n\t\t\t\tconst div = document.createElement('div');\n\t\t\t\tdiv.setAttribute('aria-labelledby', `tab-${i}`);\n\t\t\t\tdiv.setAttribute('id', `tabpanel-${i}`);\n\t\t\t\tdiv.setAttribute('role', 'tabpanel');\n\t\t\t\tdiv.setAttribute('hidden', '');\n\t\t\t\tconst slot = document.createElement('slot');\n\t\t\t\tslot.setAttribute('name', `tabpanel-slot-${i}`);\n\t\t\t\tdiv.appendChild(slot);\n\t\t\t\tthis.tabPanelHost.appendChild(div);\n\t\t\t\tif (this.host?.children instanceof HTMLCollection && this.host?.children[i] /* SSR instanceof HTMLElement */) {\n\t\t\t\t\t// div.appendChild(this.host?.children[0]);\n\t\t\t\t\tthis.host?.children[i].setAttribute('slot', `tabpanel-slot-${i}`);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t};\n\n\tpublic componentDidRender(): void {\n\t\tthis.handleTabPanels();\n\t\tif (this.tabPanelHost instanceof HTMLDivElement) {\n\t\t\tfor (let i = 0; i < this.tabPanelHost.children.length; i++) {\n\t\t\t\tif (i !== this.state._selected) {\n\t\t\t\t\tthis.tabPanelHost.children[i].setAttribute('hidden', '');\n\t\t\t\t} else {\n\t\t\t\t\tthis.tabPanelHost.children[i].removeAttribute('hidden');\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate onSelect(event: CustomEvent | KeyboardEvent | MouseEvent | PointerEvent, index: number, focus = false): void {\n\t\tthis._selected = index;\n\t\tif (typeof this._on?.onSelect === 'function') {\n\t\t\tthis._on?.onSelect(event, index);\n\t\t}\n\t\tif (focus === true) {\n\t\t\t// TODO: prüfen, ob hier noch was offen ist\n\t\t\t// devHint('[KolTabs] Tab-Fokus-verschieben geht im Moment nicht.');\n\t\t\tthis.selectedTimeout = setTimeout(() => {\n\t\t\t\tclearTimeout(this.selectedTimeout);\n\t\t\t\tif (this.tabPanelsElement /* SSR instanceof HTMLElement */) {\n\t\t\t\t\tconst button: HTMLElement | null = koliBriQuerySelector(`button#tab-${index}`, this.tabPanelsElement);\n\t\t\t\t\tbutton?.focus();\n\t\t\t\t}\n\t\t\t}, 250);\n\t\t}\n\t}\n\n\tprivate onCreate = (event: Event) => {\n\t\tevent.stopPropagation();\n\t\tif (typeof this.state._on?.onCreate === 'function') {\n\t\t\tthis.state._on?.onCreate(event);\n\t\t}\n\t};\n}\n"],"mappings":";;;qZAKA,MAAMA,EAAwC,IAAIC,IAAI,CAAC,oBAKvD,MAAMC,EAAsC,IAAID,IAAI,CAAC,oBAKrD,MAAME,EAA6B,IAAIF,IAAI,IAAID,KAA0CE,IAClF,MAAME,EAAoB,CAACC,EAAsCC,EAAkBC,KACzFC,EACCH,EACAC,GACCC,GAAUA,IAAU,UAAYA,IAAU,QAAUA,IAAU,SAAWA,IAAU,OACpFJ,EACAI,EACA,ECvBF,MAAME,EAAkB,m+E,MCuBXC,EAAO,M,yBAGXC,KAAAC,cAAgB,GAAGC,EAAU,eAC7BF,KAAAG,cAAgB,MAGhBH,KAAAI,qBAAuB,CAACC,EAAwBC,EAAgBC,KACvE,GAAIA,EAAO,EAAG,CACb,GAAID,EAASC,EAAOF,EAAKG,OAAQ,CAChC,GAAIH,EAAKC,EAASC,GAAME,UAAW,CAClC,OAAOT,KAAKI,qBAAqBC,EAAMC,EAAQC,EAAO,E,CAEvD,OAAOD,EAASC,C,OAEX,GAAIA,EAAO,EAAG,CACpB,GAAID,EAASC,GAAQ,EAAG,CACvB,GAAIF,EAAKC,EAASC,GAAME,UAAW,CAClC,OAAOT,KAAKI,qBAAqBC,EAAMC,EAAQC,EAAO,E,CAEvD,OAAOD,EAASC,C,EAGlB,OAAOD,CAAM,EAGNN,KAAAU,UAAaC,IACpB,MAAMC,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3D,GAAIA,IAAM5C,KAAKiB,MAAME,UAAW,CAC/BnB,KAAK6B,aAAagB,SAASD,GAAGK,aAAa,SAAU,G,KAC/C,CACNjD,KAAK6B,aAAagB,SAASD,GAAG6D,gBAAgB,S,IAM1CrF,SAAST,EAAgEW,EAAeoF,EAAQ,O,QACvG1G,KAAKmB,UAAYG,EACjB,WAAW8B,EAAApD,KAAK0D,OAAG,MAAAN,SAAA,SAAAA,EAAEhC,YAAa,WAAY,EAC7CmC,EAAAvD,KAAK0D,OAAG,MAAAH,SAAA,SAAAA,EAAEnC,SAAST,EAAOW,E,CAE3B,GAAIoF,IAAU,KAAM,CAGnB1G,KAAK2G,gBAAkB9F,YAAW,KACjCC,aAAad,KAAK2G,iBAClB,GAAI3G,KAAKmF,iBAAmD,CAC3D,MAAMlB,EAA6B2C,EAAqB,cAActF,IAAStB,KAAKmF,kBACpFlB,IAAM,MAANA,SAAM,SAANA,EAAQyC,O,IAEP,I"}
1
+ {"version":3,"names":["AVAILABLE_HORIZONTAL_ALIGNMENT_VALUES","Set","AVAILABLE_VERTICAL_ALIGNMENT_VALUES","AVAILABLE_ALIGNMENT_VALUES","validateAlignment","component","propName","value","watchValidator","defaultStyleCss","KolTabs","this","onCreateLabel","translate","showCreateTab","nextPossibleTabIndex","tabs","offset","step","length","_disabled","onKeyDown","event","timeout","setTimeout","clearTimeout","selectedIndex","key","state","_tabs","_selected","onSelect","onClickSelect","index","onMouseDown","stopPropagation","callbacks","onClick","catchTabPanelHost","el","tabPanelHost","selectNextNotDisabledTab","selected","upOrDown","initialSelected","Array","isArray","devHint","syncSelectedAndTabs","nextValue","nextState","_component","set","handleTabPanels","HTMLDivElement","i","children","div","document","createElement","setAttribute","_label","replace","slot","appendChild","_a","host","HTMLCollection","_b","_c","onCreate","_on","_tabsAlign","renderButtonGroup","h","role","map","button","_icon","_hideLabel","_iconOnly","_tabIndex","_tooltipAlign","_variant","undefined","_customClass","_ariaControls","_ariaSelected","_id","_role","_value","class","render","Host","ref","tabPanelsElement","validateAriaLabel","validateLabel","validateOn","featureHint","label","Log","debug","callback","setState","validateSelected","watchNumber","hooks","beforePatch","validateTabs","watchJsonArrayString","item","uiUxHintMillerscheZahl","validateTabsAlign","componentWillLoad","_ariaLabel","componentDidRender","removeAttribute","focus","selectedTimeout","koliBriQuerySelector"],"sources":["src/utils/validators/alignment.ts","src/components/tabs/style.css?tag=kol-tabs&mode=default&encapsulation=shadow","src/components/tabs/component.tsx"],"sourcesContent":["import { Generic } from '@a11y-ui/core';\n\nimport { Align } from '../../types/props/align';\nimport { watchValidator } from '../prop.validators';\n\nconst AVAILABLE_HORIZONTAL_ALIGNMENT_VALUES = new Set(['\"left\", \"right\"']);\n// export const validateHorizontalAlignment = (component: Generic.Element.Component, propName: string, value?: HorizontalAlignment): void => {\n// \twatchValidator(component, propName, (value) => value === 'left' || value === 'right', AVAILABLE_HORIZONTAL_ALIGNMENT_VALUES, value);\n// };\n\nconst AVAILABLE_VERTICAL_ALIGNMENT_VALUES = new Set(['\"bottom\", \"top\"']);\n// export const validateVertivalAlignment = (component: Generic.Element.Component, propName: string, value?: VerticalAlignment): void => {\n// \twatchValidator(component, propName, (value) => value === 'top' || value === 'bottom', AVAILABLE_VERTICAL_ALIGNMENT_VALUES, value);\n// };\n\nconst AVAILABLE_ALIGNMENT_VALUES = new Set([...AVAILABLE_HORIZONTAL_ALIGNMENT_VALUES, ...AVAILABLE_VERTICAL_ALIGNMENT_VALUES]);\nexport const validateAlignment = (component: Generic.Element.Component, propName: string, value?: Align): void => {\n\twatchValidator(\n\t\tcomponent,\n\t\tpropName,\n\t\t(value) => value === 'bottom' || value === 'left' || value === 'right' || value === 'top',\n\t\tAVAILABLE_ALIGNMENT_VALUES,\n\t\tvalue\n\t);\n};\n","@import url(../style.css);\n@import url(../host-display-block.css);\nkol-button-group-wc {\n\tdisplay: inline-flex;\n\tflex-wrap: wrap;\n}\nkol-button-group-wc button {\n\tborder-bottom-color: transparent;\n\tborder-bottom-style: solid;\n\tdisplay: block;\n}\ndiv.grid,\ndiv[role='tabpanel'] {\n\theight: 100%;\n}\n:host > .tabs-align-right {\n\tdisplay: grid;\n\tgrid-template-columns: 1fr auto;\n}\n:host > .tabs-align-right kol-button-group-wc {\n\tdisplay: grid;\n\torder: 2;\n}\n:host > .tabs-align-left {\n\tdisplay: grid;\n\tgrid-template-columns: auto 1fr;\n}\n:host > .tabs-align-left kol-button-group-wc {\n\tdisplay: grid;\n\torder: 0;\n}\n:host > .tabs-align-bottom {\n\tdisplay: grid;\n\tgrid-template-rows: 1fr auto;\n}\n:host > .tabs-align-bottom kol-button-group-wc {\n\torder: 2;\n}\n:host > .tabs-align-bottom kol-button-group-wc > div {\n\tdisplay: flex;\n}\n:host > .tabs-align-bottom > kol-button-group-wc > div > div:first-child {\n\tmargin: 0 1em 0 0;\n}\n:host > .tabs-align-bottom > kol-button-group-wc > div > div {\n\tmargin: 0 1em;\n}\n:host > .tabs-align-top {\n\tdisplay: grid;\n\tgrid-template-rows: auto 1fr;\n}\n:host > .tabs-align-top kol-button-group-wc {\n\torder: 0;\n}\n:host > .tabs-align-top kol-button-group-wc > div {\n\tdisplay: flex;\n}\n:host > .tabs-align-top > kol-button-group-wc > div > div:first-child {\n\tmargin: 0 1em 0 0;\n}\n:host > .tabs-align-top > kol-button-group-wc > div > div {\n\tmargin: 0 1em;\n}\n:host > div {\n\tdisplay: grid;\n}\n:host > .tabs-align-left kol-button-group-wc,\n:host > .tabs-align-top kol-button-group-wc {\n\torder: 0;\n}\n:host > .tabs-align-bottom kol-button-group-wc,\n:host > .tabs-align-right kol-button-group-wc {\n\torder: 1;\n}\n:host > div.tabs-align-left kol-button-group-wc > div,\n:host > div.tabs-align-left kol-button-group-wc > div > div,\n:host > div.tabs-align-right kol-button-group-wc > div,\n:host > div.tabs-align-right kol-button-group-wc > div > div {\n\tdisplay: grid;\n}\n:host > div.tabs-align-left kol-button-group-wc > div > div kol-button-wc,\n:host > div.tabs-align-right kol-button-group-wc > div > div kol-button-wc {\n\twidth: 100%;\n}\n:host > div.tabs-align-bottom kol-button-group-wc div,\n:host > div.tabs-align-top kol-button-group-wc div {\n\tdisplay: flex;\n\tflex-wrap: wrap;\n}\n","import { Generic } from '@a11y-ui/core';\nimport { Component, Element, h, Host, JSX, Prop, State, Watch } from '@stencil/core';\n\nimport { translate } from '../../i18n';\nimport { KoliBriButtonCallbacks } from '../../types/button-link';\nimport { Stringified } from '../../types/common';\nimport { Align } from '../../types/props/align';\nimport { LabelPropType, validateLabel } from '../../types/props/label';\nimport { devHint, featureHint, uiUxHintMillerscheZahl } from '../../utils/a11y.tipps';\nimport { Log } from '../../utils/dev.utils';\nimport { koliBriQuerySelector, setState, watchJsonArrayString, watchNumber } from '../../utils/prop.validators';\nimport { validateAlignment } from '../../utils/validators/alignment';\nimport { KoliBriTabsAPI, KoliBriTabsCallbacks, KoliBriTabsStates, TabButtonProps } from './types';\n\n// https://www.w3.org/TR/wai-aria-practices-1.1/examples/tabs/tabs-2/tabs.html\n\n@Component({\n\ttag: 'kol-tabs',\n\tstyleUrls: {\n\t\tdefault: './style.css',\n\t},\n\tshadow: true,\n})\nexport class KolTabs implements KoliBriTabsAPI {\n\t@Element() private readonly host?: HTMLKolTabsElement;\n\tprivate tabPanelsElement?: HTMLElement;\n\tprivate onCreateLabel = `${translate('kol-new')} …`;\n\tprivate showCreateTab = false;\n\tprivate selectedTimeout?: ReturnType<typeof setTimeout>;\n\n\tprivate nextPossibleTabIndex = (tabs: TabButtonProps[], offset: number, step: number): number => {\n\t\tif (step > 0) {\n\t\t\tif (offset + step < tabs.length) {\n\t\t\t\tif (tabs[offset + step]._disabled) {\n\t\t\t\t\treturn this.nextPossibleTabIndex(tabs, offset, step + 1);\n\t\t\t\t}\n\t\t\t\treturn offset + step;\n\t\t\t}\n\t\t} else if (step < 0) {\n\t\t\tif (offset + step >= 0) {\n\t\t\t\tif (tabs[offset + step]._disabled) {\n\t\t\t\t\treturn this.nextPossibleTabIndex(tabs, offset, step - 1);\n\t\t\t\t}\n\t\t\t\treturn offset + step;\n\t\t\t}\n\t\t}\n\t\treturn offset;\n\t};\n\n\tprivate onKeyDown = (event: KeyboardEvent) => {\n\t\tconst timeout = setTimeout(() => {\n\t\t\tclearTimeout(timeout);\n\t\t\tlet selectedIndex: number | null = null;\n\t\t\tswitch (event.key) {\n\t\t\t\tcase 'ArrowRight':\n\t\t\t\t\tselectedIndex = this.nextPossibleTabIndex(this.state._tabs, this.state._selected, 1);\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'ArrowLeft':\n\t\t\t\t\tselectedIndex = this.nextPossibleTabIndex(this.state._tabs, this.state._selected, -1);\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t\tif (selectedIndex !== null) {\n\t\t\t\tthis.onSelect(event, selectedIndex, true);\n\t\t\t}\n\t\t}, 250);\n\t};\n\n\tprivate readonly onClickSelect = (event: MouseEvent, index: number): void => {\n\t\tthis.onSelect(event, index, true);\n\t};\n\n\t// private readonly onClickClose = (event: Event, button: TabButtonProps, index: number) => {\n\t// \tevent.stopPropagation();\n\t// \tthis.onClose(button, event, index);\n\t// };\n\n\tprivate readonly onMouseDown = (event: Event): void => {\n\t\tevent.stopPropagation();\n\t};\n\n\tprivate readonly callbacks: KoliBriButtonCallbacks<number> = {\n\t\tonClick: this.onClickSelect,\n\t\tonMouseDown: this.onMouseDown,\n\t};\n\n\tprivate renderButtonGroup() {\n\t\treturn (\n\t\t\t<kol-button-group-wc role=\"tablist\" aria-label={this.state._label} onKeyDown={this.onKeyDown}>\n\t\t\t\t{this.state._tabs.map((button: TabButtonProps, index: number) => (\n\t\t\t\t\t<kol-button-wc\n\t\t\t\t\t\t_disabled={button._disabled}\n\t\t\t\t\t\t_icon={button._icon}\n\t\t\t\t\t\t_hideLabel={button._hideLabel || button._iconOnly}\n\t\t\t\t\t\t_label={button._label} // TODO: ariaLabel-Konzept prüfen\n\t\t\t\t\t\t_on={this.callbacks as KoliBriButtonCallbacks<unknown>}\n\t\t\t\t\t\t_tabIndex={this.state._selected === index ? 0 : -1}\n\t\t\t\t\t\t_tooltipAlign={button._tooltipAlign}\n\t\t\t\t\t\t_variant={this.state._selected === index ? 'custom' : undefined}\n\t\t\t\t\t\t_customClass={this.state._selected === index ? 'selected' : undefined}\n\t\t\t\t\t\t_ariaControls={`tabpanel-${index}`}\n\t\t\t\t\t\t_ariaSelected={this.state._selected === index}\n\t\t\t\t\t\t_id={`${this.state._label.replace(/\\s/g, '-')}-tab-${index}`}\n\t\t\t\t\t\t_role=\"tab\"\n\t\t\t\t\t\t_value={index}\n\t\t\t\t\t></kol-button-wc>\n\t\t\t\t))}\n\t\t\t\t{this.showCreateTab && (\n\t\t\t\t\t<kol-button-wc\n\t\t\t\t\t\tclass=\"create-button\"\n\t\t\t\t\t\t_label={this.onCreateLabel}\n\t\t\t\t\t\t_on={{\n\t\t\t\t\t\t\tonClick: this.onCreate,\n\t\t\t\t\t\t}}\n\t\t\t\t\t></kol-button-wc>\n\t\t\t\t)}\n\t\t\t</kol-button-group-wc>\n\t\t);\n\t}\n\n\tprivate tabPanelHost?: HTMLDivElement;\n\n\tprivate readonly catchTabPanelHost = (el?: HTMLDivElement) => {\n\t\tthis.tabPanelHost = el;\n\t};\n\n\tpublic render(): JSX.Element {\n\t\treturn (\n\t\t\t<Host>\n\t\t\t\t<div\n\t\t\t\t\tref={(el) => {\n\t\t\t\t\t\tthis.tabPanelsElement = el as HTMLElement;\n\t\t\t\t\t}}\n\t\t\t\t\tclass={{\n\t\t\t\t\t\t[`tabs-align-${this.state._tabsAlign}`]: true,\n\t\t\t\t\t}}\n\t\t\t\t>\n\t\t\t\t\t{this.renderButtonGroup()}\n\t\t\t\t\t<div ref={this.catchTabPanelHost}>{/* <slot /> */}</div>\n\t\t\t\t</div>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\t/**\n\t * Setzt die sichtbare oder semantische Beschriftung der Komponente (z.B. Aria-Label, Label, Headline, Caption, Summary usw.).\n\t *\n\t * @deprecated use _label instead\n\t */\n\t@Prop() public _ariaLabel?: string;\n\n\t/**\n\t * Setzt die sichtbare oder semantische Beschriftung der Komponente (z.B. Aria-Label, Label, Headline, Caption, Summary usw.).\n\t */\n\t@Prop() public _label?: LabelPropType; // TODO: required in v2\n\n\t/**\n\t * Gibt die Liste der Callback-Funktionen an, die auf Events aufgerufen werden sollen.\n\t */\n\t@Prop() public _on?: KoliBriTabsCallbacks;\n\n\t/**\n\t * Gibt an, welches Tab selektiert sein soll.\n\t */\n\t@Prop({ mutable: true, reflect: true }) public _selected?: number = 0;\n\n\t/**\n\t * Setzt die Daten für die Registrierkarten.\n\t */\n\t@Prop() public _tabs!: Stringified<TabButtonProps[]>;\n\n\t/**\n\t * Setzt die Position der Registrierkarten.\n\t */\n\t@Prop() public _tabsAlign?: Align = 'top';\n\n\t@State() public state: KoliBriTabsStates = {\n\t\t_label: '…', // ⚠ required\n\t\t_selected: 0,\n\t\t_tabs: [],\n\t\t_tabsAlign: 'top',\n\t};\n\n\tprivate selectNextNotDisabledTab = (selected: number, tabs: TabButtonProps[], upOrDown = true, initialSelected?: number): number => {\n\t\tif (selected > tabs.length - 1) {\n\t\t\tselected = tabs.length - 1;\n\t\t}\n\t\tif (selected < 0) {\n\t\t\tselected = 0;\n\t\t}\n\t\tif (Array.isArray(tabs) && tabs[selected]) {\n\t\t\tif (tabs[selected]._disabled) {\n\t\t\t\tif (upOrDown === true) {\n\t\t\t\t\tif (selected < tabs.length - 1) {\n\t\t\t\t\t\treturn this.selectNextNotDisabledTab(selected + 1, tabs, true, initialSelected || selected);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tselected = initialSelected || selected;\n\t\t\t\t\t\tupOrDown = false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (upOrDown === false) {\n\t\t\t\t\tif (selected > 0) {\n\t\t\t\t\t\treturn this.selectNextNotDisabledTab(selected - 1, tabs, false, initialSelected || selected);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tdevHint(`[KolTabs] Alle Tabs sind deaktiviert und somit kann kein Tab angezeigt werden.`);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn selected;\n\t};\n\n\tprivate syncSelectedAndTabs = (nextValue: unknown, nextState: Map<string, unknown>, _component: Generic.Element.Component, key: string) => {\n\t\tlet selected: number;\n\t\tif (key === '_selected') {\n\t\t\tselected = nextValue as number;\n\t\t} else {\n\t\t\tselected = this.state._selected;\n\t\t}\n\t\tlet tabs: TabButtonProps[];\n\t\tif (key === '_tabs') {\n\t\t\ttabs = nextValue as TabButtonProps[];\n\t\t} else {\n\t\t\ttabs = this.state._tabs;\n\t\t}\n\t\tif (tabs.length > 0) {\n\t\t\tnextState.set('_selected', this.selectNextNotDisabledTab(selected, tabs));\n\t\t}\n\t};\n\n\t/**\n\t * @deprecated\n\t */\n\t@Watch('_ariaLabel')\n\tpublic validateAriaLabel(value?: string): void {\n\t\tthis.validateLabel(value);\n\t}\n\n\t@Watch('_label')\n\tpublic validateLabel(value?: LabelPropType): void {\n\t\tvalidateLabel(this, value);\n\t}\n\n\t@Watch('_on')\n\tpublic validateOn(value?: KoliBriTabsCallbacks): void {\n\t\tif (typeof value === 'object' && value !== null) {\n\t\t\tfeatureHint('[KolTabs] Prüfen, wie man auch einen EventCallback einzeln ändern kann.');\n\t\t\tconst callbacks: KoliBriTabsCallbacks = {};\n\t\t\tif (typeof value.onCreate === 'function' || typeof value.onCreate === 'object') {\n\t\t\t\tif (typeof value.onCreate === 'object') {\n\t\t\t\t\tif (typeof value.onCreate.label === 'string' && value.onCreate.label.length > 0) {\n\t\t\t\t\t\tthis.onCreateLabel = value.onCreate.label;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tLog.debug(\n\t\t\t\t\t\t\t`[KolTabs] Der Label-Text für Neu in {\n onCreate: {\n label: string (!),\n callback: Function\n }\n} ist nicht korrekt gesetzt.`\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t\tif (typeof value.onCreate.callback === 'function') {\n\t\t\t\t\t\tcallbacks.onCreate = value.onCreate.callback;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tLog.debug(\n\t\t\t\t\t\t\t`[KolTabs] Die onCreate-Callback-Funktion für Neu in {\n onCreate: {\n label: string,\n callback: Function (!)\n }\n} ist nicht korrekt gesetzt.`\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tcallbacks.onCreate = value.onCreate;\n\t\t\t\t}\n\t\t\t\tthis.showCreateTab = typeof callbacks.onCreate === 'function';\n\t\t\t}\n\t\t\tif (typeof value.onSelect === 'function') {\n\t\t\t\tcallbacks.onSelect = value.onSelect;\n\t\t\t}\n\t\t\tsetState<KoliBriTabsCallbacks>(this, '_on', callbacks);\n\t\t}\n\t}\n\n\t@Watch('_selected')\n\tpublic validateSelected(value?: number): void {\n\t\twatchNumber(this, '_selected', value, {\n\t\t\thooks: {\n\t\t\t\tbeforePatch: this.syncSelectedAndTabs,\n\t\t\t},\n\t\t});\n\t}\n\n\t@Watch('_tabs')\n\tpublic validateTabs(value?: Stringified<TabButtonProps[]>): void {\n\t\twatchJsonArrayString(\n\t\t\tthis,\n\t\t\t'_tabs',\n\t\t\t(item: TabButtonProps) => typeof item === 'object' && item !== null && typeof item._label === 'string' && item._label.length > 0,\n\t\t\tvalue,\n\t\t\tundefined,\n\t\t\t{\n\t\t\t\thooks: {\n\t\t\t\t\tbeforePatch: this.syncSelectedAndTabs,\n\t\t\t\t},\n\t\t\t}\n\t\t);\n\t\tuiUxHintMillerscheZahl('KolTabs', this.state._tabs.length);\n\t}\n\n\t@Watch('_tabsAlign')\n\tpublic validateTabsAlign(value?: Align): void {\n\t\tvalidateAlignment(this, '_tabsAlign', value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tthis.validateLabel(this._label || this._ariaLabel);\n\t\tthis.validateOn(this._on);\n\t\tthis.validateSelected(this._selected);\n\t\tthis.validateTabs(this._tabs);\n\t\tthis.validateTabsAlign(this._tabsAlign);\n\t}\n\n\tprivate readonly handleTabPanels = () => {\n\t\tif (this.tabPanelHost instanceof HTMLDivElement) {\n\t\t\tfor (let i = this.tabPanelHost.children.length; i < this.state._tabs.length; i++) {\n\t\t\t\tconst div = document.createElement('div');\n\t\t\t\tdiv.setAttribute('aria-labelledby', `${this.state._label.replace(/\\s/g, '-')}-tab-${i}`);\n\t\t\t\tdiv.setAttribute('id', `tabpanel-${i}`);\n\t\t\t\tdiv.setAttribute('role', 'tabpanel');\n\t\t\t\tdiv.setAttribute('hidden', '');\n\t\t\t\tconst slot = document.createElement('slot');\n\t\t\t\tslot.setAttribute('name', `tabpanel-slot-${i}`);\n\t\t\t\tdiv.appendChild(slot);\n\t\t\t\tthis.tabPanelHost.appendChild(div);\n\t\t\t\tif (this.host?.children instanceof HTMLCollection && this.host?.children[i] /* SSR instanceof HTMLElement */) {\n\t\t\t\t\t// div.appendChild(this.host?.children[0]);\n\t\t\t\t\tthis.host?.children[i].setAttribute('slot', `tabpanel-slot-${i}`);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t};\n\n\tpublic componentDidRender(): void {\n\t\tthis.handleTabPanels();\n\t\tif (this.tabPanelHost instanceof HTMLDivElement) {\n\t\t\tfor (let i = 0; i < this.tabPanelHost.children.length; i++) {\n\t\t\t\tif (i !== this.state._selected) {\n\t\t\t\t\tthis.tabPanelHost.children[i].setAttribute('hidden', '');\n\t\t\t\t} else {\n\t\t\t\t\tthis.tabPanelHost.children[i].removeAttribute('hidden');\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate onSelect(event: CustomEvent | KeyboardEvent | MouseEvent | PointerEvent, index: number, focus = false): void {\n\t\tthis._selected = index;\n\t\tif (typeof this._on?.onSelect === 'function') {\n\t\t\tthis._on?.onSelect(event, index);\n\t\t}\n\t\tif (focus === true) {\n\t\t\t// TODO: prüfen, ob hier noch was offen ist\n\t\t\t// devHint('[KolTabs] Tab-Fokus-verschieben geht im Moment nicht.');\n\t\t\tthis.selectedTimeout = setTimeout(() => {\n\t\t\t\tclearTimeout(this.selectedTimeout);\n\t\t\t\tif (this.tabPanelsElement /* SSR instanceof HTMLElement */) {\n\t\t\t\t\tconst button: HTMLElement | null = koliBriQuerySelector(`button#${this.state._label.replace(/\\s/g, '-')}-tab-${index}`, this.tabPanelsElement);\n\t\t\t\t\tbutton?.focus();\n\t\t\t\t}\n\t\t\t}, 250);\n\t\t}\n\t}\n\n\tprivate onCreate = (event: Event) => {\n\t\tevent.stopPropagation();\n\t\tif (typeof this.state._on?.onCreate === 'function') {\n\t\t\tthis.state._on?.onCreate(event);\n\t\t}\n\t};\n}\n"],"mappings":";;;qZAKA,MAAMA,EAAwC,IAAIC,IAAI,CAAC,oBAKvD,MAAMC,EAAsC,IAAID,IAAI,CAAC,oBAKrD,MAAME,EAA6B,IAAIF,IAAI,IAAID,KAA0CE,IAClF,MAAME,EAAoB,CAACC,EAAsCC,EAAkBC,KACzFC,EACCH,EACAC,GACCC,GAAUA,IAAU,UAAYA,IAAU,QAAUA,IAAU,SAAWA,IAAU,OACpFJ,EACAI,EACA,ECvBF,MAAME,EAAkB,m+E,MCuBXC,EAAO,M,yBAGXC,KAAAC,cAAgB,GAAGC,EAAU,eAC7BF,KAAAG,cAAgB,MAGhBH,KAAAI,qBAAuB,CAACC,EAAwBC,EAAgBC,KACvE,GAAIA,EAAO,EAAG,CACb,GAAID,EAASC,EAAOF,EAAKG,OAAQ,CAChC,GAAIH,EAAKC,EAASC,GAAME,UAAW,CAClC,OAAOT,KAAKI,qBAAqBC,EAAMC,EAAQC,EAAO,E,CAEvD,OAAOD,EAASC,C,OAEX,GAAIA,EAAO,EAAG,CACpB,GAAID,EAASC,GAAQ,EAAG,CACvB,GAAIF,EAAKC,EAASC,GAAME,UAAW,CAClC,OAAOT,KAAKI,qBAAqBC,EAAMC,EAAQC,EAAO,E,CAEvD,OAAOD,EAASC,C,EAGlB,OAAOD,CAAM,EAGNN,KAAAU,UAAaC,IACpB,MAA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K6B,wBAAwBc,eAAgB,CAChD,IAAK,IAAIC,EAAI,EAAGA,EAAI5C,KAAK6B,aAAagB,SAASrC,OAAQoC,IAAK,CAC3D,GAAIA,IAAM5C,KAAKiB,MAAME,UAAW,CAC/BnB,KAAK6B,aAAagB,SAASD,GAAGK,aAAa,SAAU,G,KAC/C,CACNjD,KAAK6B,aAAagB,SAASD,GAAG8D,gBAAgB,S,IAM1CtF,SAAST,EAAgEW,EAAeqF,EAAQ,O,QACvG3G,KAAKmB,UAAYG,EACjB,WAAWgC,EAAAtD,KAAK4D,OAAG,MAAAN,SAAA,SAAAA,EAAElC,YAAa,WAAY,EAC7CqC,EAAAzD,KAAK4D,OAAG,MAAAH,SAAA,SAAAA,EAAErC,SAAST,EAAOW,E,CAE3B,GAAIqF,IAAU,KAAM,CAGnB3G,KAAK4G,gBAAkB/F,YAAW,KACjCC,aAAad,KAAK4G,iBAClB,GAAI5G,KAAKoF,iBAAmD,CAC3D,MAAMlB,EAA6B2C,EAAqB,UAAU7G,KAAKiB,MAAMiC,OAAOC,QAAQ,MAAO,YAAY7B,IAAStB,KAAKoF,kBAC7HlB,IAAM,MAANA,SAAM,SAANA,EAAQyC,O,IAEP,I"}
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{h as t,H as e,r as i,g as a}from"./index-2c046ff1.js";import{n as s}from"./dev.utils-8aef00f6.js";import{b as n,e as l,w as h,a as d,s as r}from"./prop.validators-683bb1d0.js";import{a as o}from"./reuse-c2156413.js";import{I as u,g as p}from"./controller-d9fb3dc1.js";import"./a11y.tipps-e607b8b3.js";import"./index-37b5cbcf.js";import"./label-bd9566f6.js";import"./tab-index-6d37f269.js";class c extends u{constructor(t,e,a){super(t,e,a),this.afterSyncCharCounter=()=>{"string"==typeof this.component._value&&this.component._value.length>0&&(this.component.state._currentLength=this.component._value.length)},this.component=t}validateHasCounter(t){n(this.component,"_hasCounter",t,{hooks:{afterPatch:this.afterSyncCharCounter}})}validateMaxLength(t){l(this.component,"_maxLength",t,{hooks:{afterPatch:this.afterSyncCharCounter},min:0})}validatePlaceholder(t){h(this.component,"_placeholder",t)}validateReadOnly(t){n(this.component,"_readOnly",t)}validateResize(t){d(this.component,"_resize",(t=>"string"==typeof t&&("both"===t||"horizontal"===t||"none"===t||"vertical"===t)),new Set("String {both, horizontal, vertical, none}"),t)}validateRequired(t){n(this.component,"_required",t)}validateRows(t){l(this.component,"_rows",t)}validateValue(t){h(this.component,"_value",t,{hooks:{afterPatch:this.afterSyncCharCounter}}),this.setFormAssociatedValue(this.component._value)}componentWillLoad(){super.componentWillLoad(),this.validateHasCounter(this.component._hasCounter),this.validateMaxLength(this.component._maxLength),this.validatePlaceholder(this.component._placeholder),this.validateReadOnly(this.component._readOnly),this.validateResize(this.component._resize),this.validateRequired(this.component._required),this.validateRows(this.component._rows),this.validateValue(this.component._value)}}const f=":host{--a11y-min-size:44px;font-size:inherit}*{hyphens:auto;letter-spacing:inherit;word-break:break-word;word-spacing:inherit}[role='button'],button:not([role='link']),kol-input .input{min-height:var(--a11y-min-size);min-width:var(--a11y-min-size)}a,button,h1,h2,h3,h4,h5,h6,input,option,select,textarea{font-family:inherit;font-size:inherit}:is(a,button){background-color:transparent;border:none;margin:0;padding:0;width:100%;}:host{max-width:100%}*{box-sizing:border-box}kol-span-wc{display:grid;place-items:center}kol-span-wc>span{display:flex;place-items:center}a,button{cursor:pointer}button,input,option,select,textarea{font-family:inherit}.icon-only>kol-span-wc>span>span{display:none}.required label>span::after,.required legend>span::after{content:'*'}:host{display:block}input,textarea{cursor:text}input[type='checkbox'],input[type='color'],input[type='file'],input[type='radio'],input[type='range'],label,option,select{cursor:pointer}input[type='color'],input[type='date'],input[type='datetime-local'],input[type='email'],input[type='file'],input[type='month'],input[type='number'],input[type='password'],input[type='search'],input[type='tel'],input[type='text'],input[type='time'],input[type='url'],input[type='week'],select:not([multiple]),select[multiple] option,textarea{font-size:1rem;width:100%}input[type='file']{padding:calc((var(--a11y-min-size) - 1rem) / 10) 0.5em}select[multiple] option{padding:calc((var(--a11y-min-size) - 1rem) / 2) 0.5em}kol-input.disabled :is(button,input,label,option,select,textarea){cursor:not-allowed;opacity:0.5}kol-input{display:grid}kol-input [slot='input']{flex-grow:1}input:not([type='checkbox'],[type='radio']),select:not([multiple]){height:2.75em}input:focus,option:focus,select:focus,textarea:focus{outline:0}.input{display:flex;align-items:center}.input>kol-icon{display:grid;height:var(--a11y-min-size);place-items:center}",v=t=>{t.style.overflow="hidden";const e=t.rows,a=t.clientHeight/e;t.rows=1;const i=Math.round(t.scrollHeight/a);return t.rows=e,i},y=class{render(){const{ariaDescribedBy:a}=p(this.state),i=!1===this.state._label;return t(e,{class:{"has-value":this.state._hasValue}},t("kol-input",{class:{textarea:!0,"hide-label":!!this.state._hideLabel,"has-counter":!!this.state._hasCounter},_alert:this.state._alert,_currentLength:this.state._currentLength,_disabled:this.state._disabled,_error:this.state._error,_hasCounter:this.state._hasCounter,_hideLabel:this.state._hideLabel,_hint:this.state._hint,_id:this.state._id,_maxLength:this.state._maxLength,_readOnly:this.state._readOnly,_required:this.state._required,_touched:this.state._touched,onClick:()=>{var t;return null===(t=this.ref)||void 0===t?void 0:t.focus()}},t("span",{slot:"label"},i?t("slot",null):this.state._label),t("div",{slot:"input"},t("textarea",Object.assign({ref:this.catchRef,title:"",accessKey:this.state._accessKey,"aria-describedby":a.length>0?a.join(" "):void 0,"aria-labelledby":`${this.state._id}-label`,autoCapitalize:"off",autoCorrect:"off",disabled:this.state._disabled,id:this.state._id,maxlength:this.state._maxLength,name:this.state._name,readOnly:this.state._readOnly,required:this.state._required,rows:this.state._rows,placeholder:this.state._placeholder,spellcheck:"false"},this.controller.onFacade,{onKeyUp:this.onChange,style:{resize:this.state._resize},value:this.state._value})),t("kol-tooltip",{"aria-hidden":"true",hidden:i||!this.state._hideLabel,_align:this._tooltipAlign,_id:`${this.state._id}-tooltip`,_label:"string"==typeof this.state._label?this.state._label:""}))))}constructor(t){i(this,t),this.catchRef=t=>{this.ref=t,o(this.host,this.ref)},this.onChange=t=>{this.ref instanceof HTMLTextAreaElement&&(r(this,"_currentLength",this.ref.value.length),this.state._adjustHeight&&(this._rows=v(this.ref))),"function"==typeof this.controller.onFacade.onChange&&this.controller.onFacade.onChange(t)},this._accessKey=void 0,this._adjustHeight=!1,this._alert=!0,this._disabled=void 0,this._error=void 0,this._hasCounter=void 0,this._hideLabel=void 0,this._hint="",this._id=void 0,this._label=void 0,this._maxLength=void 0,this._name=void 0,this._on=void 0,this._placeholder=void 0,this._readOnly=void 0,this._resize="vertical",this._required=void 0,this._rows=void 0,this._syncValueBySelector=void 0,this._tabIndex=void 0,this._tooltipAlign="top",this._touched=!1,this._value=void 0,this.state={_adjustHeight:!1,_currentLength:0,_hasValue:!1,_id:s(),_label:!1,_resize:"vertical"},this.controller=new c(this,"textarea",this.host)}validateAccessKey(t){this.controller.validateAccessKey(t)}validateAdjustHeight(t){this.controller.validateAdjustHeight(t)}validateAlert(t){this.controller.validateAlert(t)}validateDisabled(t){this.controller.validateDisabled(t)}validateError(t){this.controller.validateError(t)}validateHasCounter(t){this.controller.validateHasCounter(t)}validateHideLabel(t){this.controller.validateHideLabel(t)}validateHint(t){this.controller.validateHint(t)}validateId(t){this.controller.validateId(t)}validateLabel(t){this.controller.validateLabel(t)}validateMaxLength(t){this.controller.validateMaxLength(t)}validateName(t){this.controller.validateName(t)}validateOn(t){this.controller.validateOn(t)}validatePlaceholder(t){this.controller.validatePlaceholder(t)}validateReadOnly(t){this.controller.validateReadOnly(t)}validateResize(t){this.controller.validateResize(t)}validateRequired(t){this.controller.validateRequired(t)}validateRows(t){this.controller.validateRows(t)}validateSyncValueBySelector(t){this.controller.validateSyncValueBySelector(t)}validateTabIndex(t){this.controller.validateTabIndex(t)}validateTouched(t){this.controller.validateTouched(t)}validateValue(t){this.controller.validateValue(t)}componentWillLoad(){this._alert=!0===this._alert,this._touched=!0===this._touched,this.controller.componentWillLoad(),this.state._hasValue=!!this.state._value,this.controller.addValueChangeListener((t=>this.state._hasValue=!!t))}get host(){return a(this)}static get watchers(){return{_accessKey:["validateAccessKey"],_adjustHeight:["validateAdjustHeight"],_alert:["validateAlert"],_disabled:["validateDisabled"],_error:["validateError"],_hasCounter:["validateHasCounter"],_hideLabel:["validateHideLabel"],_hint:["validateHint"],_id:["validateId"],_label:["validateLabel"],_maxLength:["validateMaxLength"],_name:["validateName"],_on:["validateOn"],_placeholder:["validatePlaceholder"],_readOnly:["validateReadOnly"],_resize:["validateResize"],_required:["validateRequired"],_rows:["validateRows"],_syncValueBySelector:["validateSyncValueBySelector"],_tabIndex:["validateTabIndex"],_touched:["validateTouched"],_value:["validateValue"]}}};y.style={default:f};export{y as kol_textarea};
4
+ import{h as t,H as e,r as i,g as a}from"./index-2c046ff1.js";import{n as s}from"./dev.utils-4290338e.js";import{b as n,e as l,w as h,a as r,s as d}from"./prop.validators-601f1068.js";import{a as o}from"./reuse-c2156413.js";import{I as u,g as p}from"./controller-b26721c9.js";import"./a11y.tipps-9f948961.js";import"./index-37b5cbcf.js";import"./label-223fef8f.js";import"./tab-index-fc60df7a.js";class c extends u{constructor(t,e,a){super(t,e,a),this.afterSyncCharCounter=()=>{"string"==typeof this.component._value&&this.component._value.length>0&&(this.component.state._currentLength=this.component._value.length)},this.component=t}validateHasCounter(t){n(this.component,"_hasCounter",t,{hooks:{afterPatch:this.afterSyncCharCounter}})}validateMaxLength(t){l(this.component,"_maxLength",t,{hooks:{afterPatch:this.afterSyncCharCounter},min:0})}validatePlaceholder(t){h(this.component,"_placeholder",t)}validateReadOnly(t){n(this.component,"_readOnly",t)}validateResize(t){r(this.component,"_resize",(t=>"string"==typeof t&&("both"===t||"horizontal"===t||"none"===t||"vertical"===t)),new Set("String {both, horizontal, vertical, none}"),t)}validateRequired(t){n(this.component,"_required",t)}validateRows(t){l(this.component,"_rows",t)}validateValue(t){h(this.component,"_value",t,{hooks:{afterPatch:this.afterSyncCharCounter}}),this.setFormAssociatedValue(this.component._value)}componentWillLoad(){super.componentWillLoad(),this.validateHasCounter(this.component._hasCounter),this.validateMaxLength(this.component._maxLength),this.validatePlaceholder(this.component._placeholder),this.validateReadOnly(this.component._readOnly),this.validateResize(this.component._resize),this.validateRequired(this.component._required),this.validateRows(this.component._rows),this.validateValue(this.component._value)}}const f=":host{--a11y-min-size:44px;font-size:inherit}*{hyphens:auto;letter-spacing:inherit;word-break:break-word;word-spacing:inherit}[role='button'],button:not([role='link']),kol-input .input{min-height:var(--a11y-min-size);min-width:var(--a11y-min-size)}a,button,h1,h2,h3,h4,h5,h6,input,option,select,textarea{font-family:inherit;font-size:inherit}:is(a,button){background-color:transparent;border:none;margin:0;padding:0;width:100%;}:host{max-width:100%}*{box-sizing:border-box}kol-span-wc{display:grid;place-items:center}kol-span-wc>span{display:flex;place-items:center}a,button{cursor:pointer}button,input,option,select,textarea{font-family:inherit}.icon-only>kol-span-wc>span>span{display:none}.required label>span::after,.required legend>span::after{content:'*'}:host{display:block}input,textarea{cursor:text}input[type='checkbox'],input[type='color'],input[type='file'],input[type='radio'],input[type='range'],label,option,select{cursor:pointer}input[type='color'],input[type='date'],input[type='datetime-local'],input[type='email'],input[type='file'],input[type='month'],input[type='number'],input[type='password'],input[type='search'],input[type='tel'],input[type='text'],input[type='time'],input[type='url'],input[type='week'],select:not([multiple]),select[multiple] option,textarea{font-size:1rem;width:100%}input[type='file']{padding:calc((var(--a11y-min-size) - 1rem) / 10) 0.5em}select[multiple] option{padding:calc((var(--a11y-min-size) - 1rem) / 2) 0.5em}kol-input.disabled :is(button,input,label,option,select,textarea){cursor:not-allowed;opacity:0.5}kol-input{display:grid}kol-input [slot='input']{flex-grow:1}input:not([type='checkbox'],[type='radio']),select:not([multiple]){height:2.75em}input:focus,option:focus,select:focus,textarea:focus{outline:0}.input{display:flex;align-items:center}.input>kol-icon{display:grid;height:var(--a11y-min-size);place-items:center}",v=t=>{t.style.overflow="hidden";const e=t.rows,a=t.clientHeight/e;t.rows=1;const i=Math.round(t.scrollHeight/a);return t.rows=e,i},y=class{render(){const{ariaDescribedBy:a}=p(this.state),i=!1===this.state._label;return t(e,{class:{"has-value":this.state._hasValue}},t("kol-input",{class:{textarea:!0,"hide-label":!!this.state._hideLabel,"has-counter":!!this.state._hasCounter},_alert:this.state._alert,_currentLength:this.state._currentLength,_disabled:this.state._disabled,_error:this.state._error,_hasCounter:this.state._hasCounter,_hideLabel:this.state._hideLabel,_hint:this.state._hint,_id:this.state._id,_maxLength:this.state._maxLength,_readOnly:this.state._readOnly,_required:this.state._required,_touched:this.state._touched,onClick:()=>{var t;return null===(t=this.ref)||void 0===t?void 0:t.focus()}},t("span",{slot:"label"},i?t("slot",null):this.state._label),t("div",{slot:"input"},t("textarea",Object.assign({ref:this.catchRef,title:"",accessKey:this.state._accessKey,"aria-describedby":a.length>0?a.join(" "):void 0,"aria-labelledby":`${this.state._id}-label`,autoCapitalize:"off",autoCorrect:"off",disabled:this.state._disabled,id:this.state._id,maxlength:this.state._maxLength,name:this.state._name,readOnly:this.state._readOnly,required:this.state._required,rows:this.state._rows,placeholder:this.state._placeholder,spellcheck:"false"},this.controller.onFacade,{onKeyUp:this.onChange,style:{resize:this.state._resize},value:this.state._value})),t("kol-tooltip",{"aria-hidden":"true",hidden:i||!this.state._hideLabel,_align:this._tooltipAlign,_id:`${this.state._id}-tooltip`,_label:"string"==typeof this.state._label?this.state._label:""}))))}constructor(t){i(this,t),this.catchRef=t=>{this.ref=t,o(this.host,this.ref)},this.onChange=t=>{this.ref instanceof HTMLTextAreaElement&&(d(this,"_currentLength",this.ref.value.length),this.state._adjustHeight&&(this._rows=v(this.ref))),"function"==typeof this.controller.onFacade.onChange&&this.controller.onFacade.onChange(t)},this._accessKey=void 0,this._adjustHeight=!1,this._alert=!0,this._disabled=void 0,this._error=void 0,this._hasCounter=void 0,this._hideLabel=void 0,this._hint="",this._id=void 0,this._label=void 0,this._maxLength=void 0,this._name=void 0,this._on=void 0,this._placeholder=void 0,this._readOnly=void 0,this._resize="vertical",this._required=void 0,this._rows=void 0,this._syncValueBySelector=void 0,this._tabIndex=void 0,this._tooltipAlign="top",this._touched=!1,this._value=void 0,this.state={_adjustHeight:!1,_currentLength:0,_hasValue:!1,_id:`id-${s()}`,_label:!1,_resize:"vertical"},this.controller=new c(this,"textarea",this.host)}validateAccessKey(t){this.controller.validateAccessKey(t)}validateAdjustHeight(t){this.controller.validateAdjustHeight(t)}validateAlert(t){this.controller.validateAlert(t)}validateDisabled(t){this.controller.validateDisabled(t)}validateError(t){this.controller.validateError(t)}validateHasCounter(t){this.controller.validateHasCounter(t)}validateHideLabel(t){this.controller.validateHideLabel(t)}validateHint(t){this.controller.validateHint(t)}validateId(t){this.controller.validateId(t)}validateLabel(t){this.controller.validateLabel(t)}validateMaxLength(t){this.controller.validateMaxLength(t)}validateName(t){this.controller.validateName(t)}validateOn(t){this.controller.validateOn(t)}validatePlaceholder(t){this.controller.validatePlaceholder(t)}validateReadOnly(t){this.controller.validateReadOnly(t)}validateResize(t){this.controller.validateResize(t)}validateRequired(t){this.controller.validateRequired(t)}validateRows(t){this.controller.validateRows(t)}validateSyncValueBySelector(t){this.controller.validateSyncValueBySelector(t)}validateTabIndex(t){this.controller.validateTabIndex(t)}validateTouched(t){this.controller.validateTouched(t)}validateValue(t){this.controller.validateValue(t)}componentWillLoad(){this._alert=!0===this._alert,this._touched=!0===this._touched,this.controller.componentWillLoad(),this.state._hasValue=!!this.state._value,this.controller.addValueChangeListener((t=>this.state._hasValue=!!t))}get host(){return a(this)}static get watchers(){return{_accessKey:["validateAccessKey"],_adjustHeight:["validateAdjustHeight"],_alert:["validateAlert"],_disabled:["validateDisabled"],_error:["validateError"],_hasCounter:["validateHasCounter"],_hideLabel:["validateHideLabel"],_hint:["validateHint"],_id:["validateId"],_label:["validateLabel"],_maxLength:["validateMaxLength"],_name:["validateName"],_on:["validateOn"],_placeholder:["validatePlaceholder"],_readOnly:["validateReadOnly"],_resize:["validateResize"],_required:["validateRequired"],_rows:["validateRows"],_syncValueBySelector:["validateSyncValueBySelector"],_tabIndex:["validateTabIndex"],_touched:["validateTouched"],_value:["validateValue"]}}};y.style={default:f};export{y as kol_textarea};
@@ -1 +1 @@
1
- {"version":3,"names":["TextareaController","InputController","constructor","component","name","host","super","this","afterSyncCharCounter","_value","length","state","_currentLength","validateHasCounter","value","watchBoolean","hooks","afterPatch","validateMaxLength","watchNumber","min","validatePlaceholder","watchString","validateReadOnly","validateResize","watchValidator","Set","validateRequired","validateRows","validateValue","setFormAssociatedValue","componentWillLoad","_hasCounter","_maxLength","_placeholder","_readOnly","_resize","_required","_rows","defaultStyleCss","increaseTextareaHeight","el","style","overflow","currentRows","rows","rowHeight","clientHeight","nextRows","Math","round","scrollHeight","KolTextarea","render","ariaDescribedBy","getRenderStates","hasExpertSlot","_label","h","Host","class","_hasValue","textarea","_hideLabel","_alert","_disabled","_error","_hint","_id","_touched","onClick","_a","ref","focus","slot","Object","assign","catchRef","title","accessKey","_accessKey","join","undefined","autoCapitalize","autoCorrect","disabled","id","maxlength","_name","readOnly","required","placeholder","spellcheck","controller","onFacade","onKeyUp","onChange","resize","hidden","_align","_tooltipAlign","hostRef","propagateFocus","event","HTMLTextAreaElement","setState","_adjustHeight","nonce","validateAccessKey","validateAdjustHeight","validateAlert","validateDisabled","validateError","validateHideLabel","validateHint","validateId","validateLabel","validateName","validateOn","validateSyncValueBySelector","validateTabIndex","validateTouched","addValueChangeListener","v"],"sources":["src/components/textarea/controller.ts","src/components/textarea/style.css?tag=kol-textarea&mode=default&encapsulation=shadow","src/components/textarea/component.tsx"],"sourcesContent":["import { Generic } from '@a11y-ui/core';\n\nimport { watchBoolean, watchNumber, watchString, watchValidator } from '../../utils/prop.validators';\nimport { InputController } from '../@deprecated/input/controller';\nimport { CSSResize, Props, Watches } from './types';\n\nexport class TextareaController extends InputController implements Watches {\n\tprotected readonly component: Generic.Element.Component & Props;\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\tprivate afterSyncCharCounter = () => {\n\t\tif (typeof this.component._value === 'string' && this.component._value.length > 0) {\n\t\t\tthis.component.state._currentLength = this.component._value.length;\n\t\t}\n\t};\n\n\tpublic validateHasCounter(value?: boolean): void {\n\t\twatchBoolean(this.component, '_hasCounter', value, {\n\t\t\thooks: {\n\t\t\t\tafterPatch: this.afterSyncCharCounter,\n\t\t\t},\n\t\t});\n\t}\n\n\tpublic validateMaxLength(value?: number): void {\n\t\twatchNumber(this.component, '_maxLength', value, {\n\t\t\thooks: {\n\t\t\t\tafterPatch: this.afterSyncCharCounter,\n\t\t\t},\n\t\t\tmin: 0,\n\t\t});\n\t}\n\n\tpublic validatePlaceholder(value?: string): void {\n\t\twatchString(this.component, '_placeholder', value);\n\t}\n\n\tpublic validateReadOnly(value?: boolean): void {\n\t\twatchBoolean(this.component, '_readOnly', value);\n\t}\n\n\tpublic validateResize(value?: CSSResize): void {\n\t\twatchValidator(\n\t\t\tthis.component,\n\t\t\t'_resize',\n\t\t\t(value) => typeof value === 'string' && (value === 'both' || value === 'horizontal' || value === 'none' || value === 'vertical'),\n\t\t\tnew Set('String {both, horizontal, vertical, none}'),\n\t\t\tvalue\n\t\t);\n\t}\n\n\tpublic validateRequired(value?: boolean): void {\n\t\twatchBoolean(this.component, '_required', value);\n\t}\n\n\tpublic validateRows(value?: number): void {\n\t\twatchNumber(this.component, '_rows', 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\t\tthis.setFormAssociatedValue(this.component._value as string);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tsuper.componentWillLoad();\n\t\tthis.validateHasCounter(this.component._hasCounter);\n\t\tthis.validateMaxLength(this.component._maxLength);\n\t\tthis.validatePlaceholder(this.component._placeholder);\n\t\tthis.validateReadOnly(this.component._readOnly);\n\t\tthis.validateResize(this.component._resize);\n\t\tthis.validateRequired(this.component._required);\n\t\tthis.validateRows(this.component._rows);\n\t\tthis.validateValue(this.component._value);\n\t}\n}\n","@import url(../input-line.css);\n","import { Component, Element, h, Host, JSX, Prop, State, Watch } from '@stencil/core';\n\nimport { InputTypeOnDefault } from '../../types/input/types';\nimport { Align } from '../../types/props/align';\nimport { LabelWithExpertSlotPropType } from '../../types/props/label';\nimport { nonce } from '../../utils/dev.utils';\nimport { setState } from '../../utils/prop.validators';\nimport { propagateFocus } from '../../utils/reuse';\nimport { getRenderStates } from '../input/controller';\nimport { TextareaController } from './controller';\nimport { ComponentApi, CSSResize, States } from './types';\n\n/**\n * https://stackoverflow.com/questions/17772260/textarea-auto-height\n */\nconst increaseTextareaHeight = (el: HTMLTextAreaElement): number => {\n\tel.style.overflow = 'hidden'; // verhindert, dass ein Scrollbalken kurz angezeigt wird\n\tconst currentRows = el.rows;\n\tconst rowHeight = el.clientHeight / currentRows;\n\tel.rows = 1;\n\tconst nextRows = Math.round(el.scrollHeight / rowHeight);\n\tel.rows = currentRows;\n\treturn nextRows;\n};\n\n/**\n * @slot - Die Beschriftung des Eingabefeldes.\n */\n@Component({\n\ttag: 'kol-textarea',\n\tstyleUrls: {\n\t\tdefault: './style.css',\n\t},\n\tshadow: true,\n})\nexport class KolTextarea implements ComponentApi {\n\t@Element() private readonly host?: HTMLKolTextareaElement;\n\tprivate ref?: HTMLTextAreaElement;\n\n\tprivate readonly catchRef = (ref?: HTMLTextAreaElement) => {\n\t\tthis.ref = ref;\n\t\tpropagateFocus(this.host, this.ref);\n\t};\n\n\tpublic render(): JSX.Element {\n\t\tconst { ariaDescribedBy } = getRenderStates(this.state);\n\t\tconst hasExpertSlot = this.state._label === false; // _label=\"\" or _label\n\n\t\treturn (\n\t\t\t<Host class={{ 'has-value': this.state._hasValue }}>\n\t\t\t\t<kol-input\n\t\t\t\t\tclass={{ textarea: true, 'hide-label': !!this.state._hideLabel, 'has-counter': !!this.state._hasCounter }}\n\t\t\t\t\t_alert={this.state._alert}\n\t\t\t\t\t_currentLength={this.state._currentLength}\n\t\t\t\t\t_disabled={this.state._disabled}\n\t\t\t\t\t_error={this.state._error}\n\t\t\t\t\t_hasCounter={this.state._hasCounter}\n\t\t\t\t\t_hideLabel={this.state._hideLabel}\n\t\t\t\t\t_hint={this.state._hint}\n\t\t\t\t\t_id={this.state._id}\n\t\t\t\t\t_maxLength={this.state._maxLength}\n\t\t\t\t\t_readOnly={this.state._readOnly}\n\t\t\t\t\t_required={this.state._required}\n\t\t\t\t\t_touched={this.state._touched}\n\t\t\t\t\tonClick={() => this.ref?.focus()}\n\t\t\t\t>\n\t\t\t\t\t{/* TODO: der folgende Slot ohne Name muss später entfernt werden */}\n\t\t\t\t\t<span slot=\"label\">{hasExpertSlot ? <slot></slot> : this.state._label}</span>\n\t\t\t\t\t<div slot=\"input\">\n\t\t\t\t\t\t<textarea\n\t\t\t\t\t\t\tref={this.catchRef}\n\t\t\t\t\t\t\ttitle=\"\"\n\t\t\t\t\t\t\taccessKey={this.state._accessKey}\n\t\t\t\t\t\t\taria-describedby={ariaDescribedBy.length > 0 ? ariaDescribedBy.join(' ') : undefined}\n\t\t\t\t\t\t\taria-labelledby={`${this.state._id}-label`}\n\t\t\t\t\t\t\tautoCapitalize=\"off\"\n\t\t\t\t\t\t\tautoCorrect=\"off\"\n\t\t\t\t\t\t\tdisabled={this.state._disabled}\n\t\t\t\t\t\t\tid={this.state._id}\n\t\t\t\t\t\t\tmaxlength={this.state._maxLength}\n\t\t\t\t\t\t\tname={this.state._name}\n\t\t\t\t\t\t\treadOnly={this.state._readOnly}\n\t\t\t\t\t\t\trequired={this.state._required}\n\t\t\t\t\t\t\trows={this.state._rows}\n\t\t\t\t\t\t\tplaceholder={this.state._placeholder}\n\t\t\t\t\t\t\tspellcheck=\"false\"\n\t\t\t\t\t\t\t{...this.controller.onFacade}\n\t\t\t\t\t\t\tonKeyUp={this.onChange}\n\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\tresize: this.state._resize,\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\tvalue={this.state._value}\n\t\t\t\t\t\t/>\n\t\t\t\t\t\t<kol-tooltip\n\t\t\t\t\t\t\t/**\n\t\t\t\t\t\t\t * Dieses Aria-Hidden verhindert das doppelte Vorlesen des Labels,\n\t\t\t\t\t\t\t * verhindert aber nicht das Aria-Labelledby vorgelesen wird.\n\t\t\t\t\t\t\t */\n\t\t\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\t\t\thidden={hasExpertSlot || !this.state._hideLabel}\n\t\t\t\t\t\t\t_align={this._tooltipAlign}\n\t\t\t\t\t\t\t_id={`${this.state._id}-tooltip`}\n\t\t\t\t\t\t\t_label={typeof this.state._label === 'string' ? this.state._label : ''}\n\t\t\t\t\t\t></kol-tooltip>\n\t\t\t\t\t</div>\n\t\t\t\t</kol-input>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\tprivate readonly controller: TextareaController;\n\n\t/**\n\t * Gibt an, mit welcher Tastenkombination man das interaktive Element der Komponente auslösen oder fokussieren kann.\n\t */\n\t@Prop() public _accessKey?: string;\n\n\t/**\n\t * Passt die Höhe des Eingabefeldes automatisch an den Füllstand an.\n\t */\n\t@Prop() public _adjustHeight?: boolean = false;\n\n\t/**\n\t * Gibt an, ob der Screenreader die Meldung aktiv vorlesen soll.\n\t */\n\t@Prop({ mutable: true, reflect: true }) public _alert?: boolean = true;\n\n\t/**\n\t * Deaktiviert das interaktive Element in der Komponente und erlaubt keine Interaktion mehr damit.\n\t */\n\t@Prop() public _disabled?: boolean;\n\n\t/**\n\t * Gibt den Text für eine Fehlermeldung an.\n\t */\n\t@Prop() public _error?: string;\n\n\t/**\n\t * Aktiviert den Zeichenanzahlzähler am unteren Rand des Eingabefeldes.\n\t */\n\t@Prop() public _hasCounter?: boolean;\n\n\t/**\n\t * Blendet die Beschriftung (Label) aus und zeigt sie stattdessen mittels eines Tooltips an.\n\t */\n\t@Prop() public _hideLabel?: boolean;\n\n\t/**\n\t * Gibt den Hinweistext an.\n\t */\n\t@Prop() public _hint?: string = '';\n\n\t/**\n\t * Gibt die interne ID des primären Elements in der Komponente an.\n\t */\n\t@Prop() public _id?: string;\n\n\t/**\n\t * Setzt die sichtbare oder semantische Beschriftung der Komponente (z.B. Aria-Label, Label, Headline, Caption, Summary usw.).\n\t */\n\t@Prop() public _label!: LabelWithExpertSlotPropType;\n\n\t/**\n\t * Gibt an, wie viele Zeichen maximal eingegeben werden können.\n\t */\n\t@Prop() public _maxLength?: number;\n\n\t/**\n\t * Gibt den technischen Namen des Eingabefeldes an.\n\t */\n\t@Prop() public _name?: string;\n\n\t/**\n\t * Gibt die EventCallback-Funktionen für das Input-Event an.\n\t */\n\t@Prop() public _on?: InputTypeOnDefault;\n\n\t/**\n\t * Gibt den Platzhalter des Eingabefeldes an, wenn es leer ist.\n\t */\n\t@Prop() public _placeholder?: string;\n\n\t/**\n\t * Setzt das Eingabefeld in den schreibgeschützten Modus.\n\t */\n\t@Prop() public _readOnly?: boolean;\n\n\t/**\n\t * Gibt an, ob die Größe des Eingabefeldes von Nutzer:innen geändert werden kann. (https://developer.mozilla.org/de/docs/Web/CSS/resize)\n\t */\n\t@Prop() public _resize?: CSSResize = 'vertical';\n\n\t/**\n\t * Macht das Eingabeelement zu einem Pflichtfeld.\n\t */\n\t@Prop() public _required?: boolean;\n\n\t/**\n\t * Gibt die Anzahl der anzuzeigenden Zeilen des Eingabefeldes an.\n\t */\n\t@Prop({ mutable: true, reflect: false }) public _rows?: number;\n\n\t/**\n\t * Selector for synchronizing the value with another input element.\n\t * @internal\n\t */\n\t@Prop() public _syncValueBySelector?: string;\n\n\t/**\n\t * Gibt an, welchen Tab-Index das primäre Element in der Komponente hat. (https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/tabindex)\n\t */\n\t@Prop() public _tabIndex?: number;\n\n\t/**\n\t * Gibt an, ob der Tooltip bevorzugt entweder oben, rechts, unten oder links angezeigt werden soll.\n\t */\n\t@Prop() public _tooltipAlign?: Align = 'top';\n\n\t/**\n\t * Gibt an, ob dieses Eingabefeld von Nutzer:innen einmal besucht/berührt wurde.\n\t */\n\t@Prop({ mutable: true, reflect: true }) public _touched?: boolean = false;\n\n\t/**\n\t * Gibt den Wert des Eingabefeldes an.\n\t */\n\t@Prop() public _value?: string;\n\n\t@State() public state: States = {\n\t\t_adjustHeight: false,\n\t\t_currentLength: 0,\n\t\t_hasValue: false,\n\t\t_id: nonce(), // ⚠ required\n\t\t_label: false, // ⚠ required\n\t\t_resize: 'vertical',\n\t};\n\n\tpublic constructor() {\n\t\tthis.controller = new TextareaController(this, 'textarea', this.host);\n\t}\n\n\t@Watch('_accessKey')\n\tpublic validateAccessKey(value?: string): void {\n\t\tthis.controller.validateAccessKey(value);\n\t}\n\n\t@Watch('_adjustHeight')\n\tpublic validateAdjustHeight(value?: boolean): void {\n\t\tthis.controller.validateAdjustHeight(value);\n\t}\n\n\t@Watch('_alert')\n\tpublic validateAlert(value?: boolean): void {\n\t\tthis.controller.validateAlert(value);\n\t}\n\n\t@Watch('_disabled')\n\tpublic validateDisabled(value?: boolean): void {\n\t\tthis.controller.validateDisabled(value);\n\t}\n\n\t@Watch('_error')\n\tpublic validateError(value?: string): void {\n\t\tthis.controller.validateError(value);\n\t}\n\n\t@Watch('_hasCounter')\n\tpublic validateHasCounter(value?: boolean): void {\n\t\tthis.controller.validateHasCounter(value);\n\t}\n\n\t@Watch('_hideLabel')\n\tpublic validateHideLabel(value?: boolean): void {\n\t\tthis.controller.validateHideLabel(value);\n\t}\n\n\t@Watch('_hint')\n\tpublic validateHint(value?: string): void {\n\t\tthis.controller.validateHint(value);\n\t}\n\n\t@Watch('_id')\n\tpublic validateId(value?: string): void {\n\t\tthis.controller.validateId(value);\n\t}\n\n\t@Watch('_label')\n\tpublic validateLabel(value?: LabelWithExpertSlotPropType): void {\n\t\tthis.controller.validateLabel(value);\n\t}\n\n\t@Watch('_maxLength')\n\tpublic validateMaxLength(value?: number): void {\n\t\tthis.controller.validateMaxLength(value);\n\t}\n\n\t@Watch('_name')\n\tpublic validateName(value?: string): void {\n\t\tthis.controller.validateName(value);\n\t}\n\n\t@Watch('_on')\n\tpublic validateOn(value?: InputTypeOnDefault): void {\n\t\tthis.controller.validateOn(value);\n\t}\n\n\t@Watch('_placeholder')\n\tpublic validatePlaceholder(value?: string): void {\n\t\tthis.controller.validatePlaceholder(value);\n\t}\n\n\t@Watch('_readOnly')\n\tpublic validateReadOnly(value?: boolean): void {\n\t\tthis.controller.validateReadOnly(value);\n\t}\n\n\t@Watch('_resize')\n\tpublic validateResize(value?: CSSResize): void {\n\t\tthis.controller.validateResize(value);\n\t}\n\n\t@Watch('_required')\n\tpublic validateRequired(value?: boolean): void {\n\t\tthis.controller.validateRequired(value);\n\t}\n\n\t@Watch('_rows')\n\tpublic validateRows(value?: number): void {\n\t\tthis.controller.validateRows(value);\n\t}\n\n\t@Watch('_syncValueBySelector')\n\tpublic validateSyncValueBySelector(value?: string): void {\n\t\tthis.controller.validateSyncValueBySelector(value);\n\t}\n\n\t@Watch('_tabIndex')\n\tpublic validateTabIndex(value?: number): void {\n\t\tthis.controller.validateTabIndex(value);\n\t}\n\n\t@Watch('_touched')\n\tpublic validateTouched(value?: boolean): void {\n\t\tthis.controller.validateTouched(value);\n\t}\n\n\t@Watch('_value')\n\tpublic validateValue(value?: string): void {\n\t\tthis.controller.validateValue(value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tthis._alert = this._alert === true;\n\t\tthis._touched = this._touched === true;\n\t\tthis.controller.componentWillLoad();\n\n\t\tthis.state._hasValue = !!this.state._value;\n\t\tthis.controller.addValueChangeListener((v) => (this.state._hasValue = !!v));\n\t}\n\n\tprivate readonly onChange = (event: Event) => {\n\t\tif (this.ref instanceof HTMLTextAreaElement) {\n\t\t\tsetState(this, '_currentLength', this.ref.value.length);\n\t\t\tif (this.state._adjustHeight) {\n\t\t\t\tthis._rows = increa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ACvBP,KAAKsF,WAAWlE,iBAAiBb,E,CAI3Bc,aAAad,GACnBP,KAAKsF,WAAWjE,aAAad,E,CAIvByG,4BAA4BzG,GAClCP,KAAKsF,WAAW0B,4BAA4BzG,E,CAItC0G,iBAAiB1G,GACvBP,KAAKsF,WAAW2B,iBAAiB1G,E,CAI3B2G,gBAAgB3G,GACtBP,KAAKsF,WAAW4B,gBAAgB3G,E,CAI1Be,cAAcf,GACpBP,KAAKsF,WAAWhE,cAAcf,E,CAGxBiB,oBACNxB,KAAKyD,OAASzD,KAAKyD,SAAW,KAC9BzD,KAAK8D,SAAW9D,KAAK8D,WAAa,KAClC9D,KAAKsF,WAAW9D,oBAEhBxB,KAAKI,MAAMkD,YAActD,KAAKI,MAAMF,OACpCF,KAAKsF,WAAW6B,wBAAwBC,GAAOpH,KAAKI,MAAMkD,YAAc8D,G"}
1
+ {"version":3,"names":["TextareaController","InputController","constructor","component","name","host","super","this","afterSyncCharCounter","_value","length","state","_currentLength","validateHasCounter","value","watchBoolean","hooks","afterPatch","validateMaxLength","watchNumber","min","validatePlaceholder","watchString","validateReadOnly","validateResize","watchValidator","Set","validateRequired","validateRows","validateValue","setFormAssociatedValue","componentWillLoad","_hasCounter","_maxLength","_placeholder","_readOnly","_resize","_required","_rows","defaultStyleCss","increaseTextareaHeight","el","style","overflow","currentRows","rows","rowHeight","clientHeight","nextRows","Math","round","scrollHeight","KolTextarea","render","ariaDescribedBy","getRenderStates","hasExpertSlot","_label","h","Host","class","_hasValue","textarea","_hideLabel","_alert","_disabled","_error","_hint","_id","_touched","onClick","_a","ref","focus","slot","Object","assign","catchRef","title","accessKey","_accessKey","join","undefined","autoCapitalize","autoCorrect","disabled","id","maxlength","_name","readOnly","required","placeholder","spellcheck","controller","onFacade","onKeyUp","onChange","resize","hidden","_align","_tooltipAlign","hostRef","propagateFocus","event","HTMLTextAreaElement","setState","_adjustHeight","nonce","validateAccessKey","validateAdjustHeight","validateAlert","validateDisabled","validateError","validateHideLabel","validateHint","validateId","validateLabel","validateName","validateOn","validateSyncValueBySelector","validateTabIndex","validateTouched","addValueChangeListener","v"],"sources":["src/components/textarea/controller.ts","src/components/textarea/style.css?tag=kol-textarea&mode=default&encapsulation=shadow","src/components/textarea/component.tsx"],"sourcesContent":["import { Generic } from '@a11y-ui/core';\n\nimport { watchBoolean, watchNumber, watchString, watchValidator } from '../../utils/prop.validators';\nimport { InputController } from '../@deprecated/input/controller';\nimport { CSSResize, Props, Watches } from './types';\n\nexport class TextareaController extends InputController implements Watches {\n\tprotected readonly component: Generic.Element.Component & Props;\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\tprivate afterSyncCharCounter = () => {\n\t\tif (typeof this.component._value === 'string' && this.component._value.length > 0) {\n\t\t\tthis.component.state._currentLength = this.component._value.length;\n\t\t}\n\t};\n\n\tpublic validateHasCounter(value?: boolean): void {\n\t\twatchBoolean(this.component, '_hasCounter', value, {\n\t\t\thooks: {\n\t\t\t\tafterPatch: this.afterSyncCharCounter,\n\t\t\t},\n\t\t});\n\t}\n\n\tpublic validateMaxLength(value?: number): void {\n\t\twatchNumber(this.component, '_maxLength', value, {\n\t\t\thooks: {\n\t\t\t\tafterPatch: this.afterSyncCharCounter,\n\t\t\t},\n\t\t\tmin: 0,\n\t\t});\n\t}\n\n\tpublic validatePlaceholder(value?: string): void {\n\t\twatchString(this.component, '_placeholder', value);\n\t}\n\n\tpublic validateReadOnly(value?: boolean): void {\n\t\twatchBoolean(this.component, '_readOnly', value);\n\t}\n\n\tpublic validateResize(value?: CSSResize): void {\n\t\twatchValidator(\n\t\t\tthis.component,\n\t\t\t'_resize',\n\t\t\t(value) => typeof value === 'string' && (value === 'both' || value === 'horizontal' || value === 'none' || value === 'vertical'),\n\t\t\tnew Set('String {both, horizontal, vertical, none}'),\n\t\t\tvalue\n\t\t);\n\t}\n\n\tpublic validateRequired(value?: boolean): void {\n\t\twatchBoolean(this.component, '_required', value);\n\t}\n\n\tpublic validateRows(value?: number): void {\n\t\twatchNumber(this.component, '_rows', 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\t\tthis.setFormAssociatedValue(this.component._value as string);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tsuper.componentWillLoad();\n\t\tthis.validateHasCounter(this.component._hasCounter);\n\t\tthis.validateMaxLength(this.component._maxLength);\n\t\tthis.validatePlaceholder(this.component._placeholder);\n\t\tthis.validateReadOnly(this.component._readOnly);\n\t\tthis.validateResize(this.component._resize);\n\t\tthis.validateRequired(this.component._required);\n\t\tthis.validateRows(this.component._rows);\n\t\tthis.validateValue(this.component._value);\n\t}\n}\n","@import url(../input-line.css);\n","import { Component, Element, h, Host, JSX, Prop, State, Watch } from '@stencil/core';\n\nimport { InputTypeOnDefault } from '../../types/input/types';\nimport { Align } from '../../types/props/align';\nimport { LabelWithExpertSlotPropType } from '../../types/props/label';\nimport { nonce } from '../../utils/dev.utils';\nimport { setState } from '../../utils/prop.validators';\nimport { propagateFocus } from '../../utils/reuse';\nimport { getRenderStates } from '../input/controller';\nimport { TextareaController } from './controller';\nimport { ComponentApi, CSSResize, States } from './types';\n\n/**\n * https://stackoverflow.com/questions/17772260/textarea-auto-height\n */\nconst increaseTextareaHeight = (el: HTMLTextAreaElement): number => {\n\tel.style.overflow = 'hidden'; // verhindert, dass ein Scrollbalken kurz angezeigt wird\n\tconst currentRows = el.rows;\n\tconst rowHeight = el.clientHeight / currentRows;\n\tel.rows = 1;\n\tconst nextRows = Math.round(el.scrollHeight / rowHeight);\n\tel.rows = currentRows;\n\treturn nextRows;\n};\n\n/**\n * @slot - Die Beschriftung des Eingabefeldes.\n */\n@Component({\n\ttag: 'kol-textarea',\n\tstyleUrls: {\n\t\tdefault: './style.css',\n\t},\n\tshadow: true,\n})\nexport class KolTextarea implements ComponentApi {\n\t@Element() private readonly host?: HTMLKolTextareaElement;\n\tprivate ref?: HTMLTextAreaElement;\n\n\tprivate readonly catchRef = (ref?: HTMLTextAreaElement) => {\n\t\tthis.ref = ref;\n\t\tpropagateFocus(this.host, this.ref);\n\t};\n\n\tpublic render(): JSX.Element {\n\t\tconst { ariaDescribedBy } = getRenderStates(this.state);\n\t\tconst hasExpertSlot = this.state._label === false; // _label=\"\" or _label\n\n\t\treturn (\n\t\t\t<Host class={{ 'has-value': this.state._hasValue }}>\n\t\t\t\t<kol-input\n\t\t\t\t\tclass={{ textarea: true, 'hide-label': !!this.state._hideLabel, 'has-counter': !!this.state._hasCounter }}\n\t\t\t\t\t_alert={this.state._alert}\n\t\t\t\t\t_currentLength={this.state._currentLength}\n\t\t\t\t\t_disabled={this.state._disabled}\n\t\t\t\t\t_error={this.state._error}\n\t\t\t\t\t_hasCounter={this.state._hasCounter}\n\t\t\t\t\t_hideLabel={this.state._hideLabel}\n\t\t\t\t\t_hint={this.state._hint}\n\t\t\t\t\t_id={this.state._id}\n\t\t\t\t\t_maxLength={this.state._maxLength}\n\t\t\t\t\t_readOnly={this.state._readOnly}\n\t\t\t\t\t_required={this.state._required}\n\t\t\t\t\t_touched={this.state._touched}\n\t\t\t\t\tonClick={() => this.ref?.focus()}\n\t\t\t\t>\n\t\t\t\t\t{/* TODO: der folgende Slot ohne Name muss später entfernt werden */}\n\t\t\t\t\t<span slot=\"label\">{hasExpertSlot ? <slot></slot> : this.state._label}</span>\n\t\t\t\t\t<div slot=\"input\">\n\t\t\t\t\t\t<textarea\n\t\t\t\t\t\t\tref={this.catchRef}\n\t\t\t\t\t\t\ttitle=\"\"\n\t\t\t\t\t\t\taccessKey={this.state._accessKey}\n\t\t\t\t\t\t\taria-describedby={ariaDescribedBy.length > 0 ? ariaDescribedBy.join(' ') : undefined}\n\t\t\t\t\t\t\taria-labelledby={`${this.state._id}-label`}\n\t\t\t\t\t\t\tautoCapitalize=\"off\"\n\t\t\t\t\t\t\tautoCorrect=\"off\"\n\t\t\t\t\t\t\tdisabled={this.state._disabled}\n\t\t\t\t\t\t\tid={this.state._id}\n\t\t\t\t\t\t\tmaxlength={this.state._maxLength}\n\t\t\t\t\t\t\tname={this.state._name}\n\t\t\t\t\t\t\treadOnly={this.state._readOnly}\n\t\t\t\t\t\t\trequired={this.state._required}\n\t\t\t\t\t\t\trows={this.state._rows}\n\t\t\t\t\t\t\tplaceholder={this.state._placeholder}\n\t\t\t\t\t\t\tspellcheck=\"false\"\n\t\t\t\t\t\t\t{...this.controller.onFacade}\n\t\t\t\t\t\t\tonKeyUp={this.onChange}\n\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\tresize: this.state._resize,\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\tvalue={this.state._value}\n\t\t\t\t\t\t/>\n\t\t\t\t\t\t<kol-tooltip\n\t\t\t\t\t\t\t/**\n\t\t\t\t\t\t\t * Dieses Aria-Hidden verhindert das doppelte Vorlesen des Labels,\n\t\t\t\t\t\t\t * verhindert aber nicht das Aria-Labelledby vorgelesen wird.\n\t\t\t\t\t\t\t */\n\t\t\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\t\t\thidden={hasExpertSlot || !this.state._hideLabel}\n\t\t\t\t\t\t\t_align={this._tooltipAlign}\n\t\t\t\t\t\t\t_id={`${this.state._id}-tooltip`}\n\t\t\t\t\t\t\t_label={typeof this.state._label === 'string' ? this.state._label : ''}\n\t\t\t\t\t\t></kol-tooltip>\n\t\t\t\t\t</div>\n\t\t\t\t</kol-input>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\tprivate readonly controller: TextareaController;\n\n\t/**\n\t * Gibt an, mit welcher Tastenkombination man das interaktive Element der Komponente auslösen oder fokussieren kann.\n\t */\n\t@Prop() public _accessKey?: string;\n\n\t/**\n\t * Passt die Höhe des Eingabefeldes automatisch an den Füllstand an.\n\t */\n\t@Prop() public _adjustHeight?: boolean = false;\n\n\t/**\n\t * Gibt an, ob der Screenreader die Meldung aktiv vorlesen soll.\n\t */\n\t@Prop({ mutable: true, reflect: true }) public _alert?: boolean = true;\n\n\t/**\n\t * Deaktiviert das interaktive Element in der Komponente und erlaubt keine Interaktion mehr damit.\n\t */\n\t@Prop() public _disabled?: boolean;\n\n\t/**\n\t * Gibt den Text für eine Fehlermeldung an.\n\t */\n\t@Prop() public _error?: string;\n\n\t/**\n\t * Aktiviert den Zeichenanzahlzähler am unteren Rand des Eingabefeldes.\n\t */\n\t@Prop() public _hasCounter?: boolean;\n\n\t/**\n\t * Blendet die Beschriftung (Label) aus und zeigt sie stattdessen mittels eines Tooltips an.\n\t */\n\t@Prop() public _hideLabel?: boolean;\n\n\t/**\n\t * Gibt den Hinweistext an.\n\t */\n\t@Prop() public _hint?: string = '';\n\n\t/**\n\t * Gibt die interne ID des primären Elements in der Komponente an.\n\t */\n\t@Prop() public _id?: string;\n\n\t/**\n\t * Setzt die sichtbare oder semantische Beschriftung der Komponente (z.B. Aria-Label, Label, Headline, Caption, Summary usw.).\n\t */\n\t@Prop() public _label!: LabelWithExpertSlotPropType;\n\n\t/**\n\t * Gibt an, wie viele Zeichen maximal eingegeben werden können.\n\t */\n\t@Prop() public _maxLength?: number;\n\n\t/**\n\t * Gibt den technischen Namen des Eingabefeldes an.\n\t */\n\t@Prop() public _name?: string;\n\n\t/**\n\t * Gibt die EventCallback-Funktionen für das Input-Event an.\n\t */\n\t@Prop() public _on?: InputTypeOnDefault;\n\n\t/**\n\t * Gibt den Platzhalter des Eingabefeldes an, wenn es leer ist.\n\t */\n\t@Prop() public _placeholder?: string;\n\n\t/**\n\t * Setzt das Eingabefeld in den schreibgeschützten Modus.\n\t */\n\t@Prop() public _readOnly?: boolean;\n\n\t/**\n\t * Gibt an, ob die Größe des Eingabefeldes von Nutzer:innen geändert werden kann. (https://developer.mozilla.org/de/docs/Web/CSS/resize)\n\t */\n\t@Prop() public _resize?: CSSResize = 'vertical';\n\n\t/**\n\t * Macht das Eingabeelement zu einem Pflichtfeld.\n\t */\n\t@Prop() public _required?: boolean;\n\n\t/**\n\t * Gibt die Anzahl der anzuzeigenden Zeilen des Eingabefeldes an.\n\t */\n\t@Prop({ mutable: true, reflect: false }) public _rows?: number;\n\n\t/**\n\t * Selector for synchronizing the value with another input element.\n\t * @internal\n\t */\n\t@Prop() public _syncValueBySelector?: string;\n\n\t/**\n\t * Gibt an, welchen Tab-Index das primäre Element in der Komponente hat. (https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/tabindex)\n\t */\n\t@Prop() public _tabIndex?: number;\n\n\t/**\n\t * Gibt an, ob der Tooltip bevorzugt entweder oben, rechts, unten oder links angezeigt werden soll.\n\t */\n\t@Prop() public _tooltipAlign?: Align = 'top';\n\n\t/**\n\t * Gibt an, ob dieses Eingabefeld von Nutzer:innen einmal besucht/berührt wurde.\n\t */\n\t@Prop({ mutable: true, reflect: true }) public _touched?: boolean = false;\n\n\t/**\n\t * Gibt den Wert des Eingabefeldes an.\n\t */\n\t@Prop() public _value?: string;\n\n\t@State() public state: States = {\n\t\t_adjustHeight: false,\n\t\t_currentLength: 0,\n\t\t_hasValue: false,\n\t\t_id: `id-${nonce()}`, // ⚠ required\n\t\t_label: false, // ⚠ required\n\t\t_resize: 'vertical',\n\t};\n\n\tpublic constructor() {\n\t\tthis.controller = new TextareaController(this, 'textarea', this.host);\n\t}\n\n\t@Watch('_accessKey')\n\tpublic validateAccessKey(value?: string): void {\n\t\tthis.controller.validateAccessKey(value);\n\t}\n\n\t@Watch('_adjustHeight')\n\tpublic validateAdjustHeight(value?: boolean): void {\n\t\tthis.controller.validateAdjustHeight(value);\n\t}\n\n\t@Watch('_alert')\n\tpublic validateAlert(value?: boolean): void {\n\t\tthis.controller.validateAlert(value);\n\t}\n\n\t@Watch('_disabled')\n\tpublic validateDisabled(value?: boolean): void {\n\t\tthis.controller.validateDisabled(value);\n\t}\n\n\t@Watch('_error')\n\tpublic validateError(value?: string): void {\n\t\tthis.controller.validateError(value);\n\t}\n\n\t@Watch('_hasCounter')\n\tpublic validateHasCounter(value?: boolean): void {\n\t\tthis.controller.validateHasCounter(value);\n\t}\n\n\t@Watch('_hideLabel')\n\tpublic validateHideLabel(value?: boolean): void {\n\t\tthis.controller.validateHideLabel(value);\n\t}\n\n\t@Watch('_hint')\n\tpublic validateHint(value?: string): void {\n\t\tthis.controller.validateHint(value);\n\t}\n\n\t@Watch('_id')\n\tpublic validateId(value?: string): void {\n\t\tthis.controller.validateId(value);\n\t}\n\n\t@Watch('_label')\n\tpublic validateLabel(value?: LabelWithExpertSlotPropType): void {\n\t\tthis.controller.validateLabel(value);\n\t}\n\n\t@Watch('_maxLength')\n\tpublic validateMaxLength(value?: number): void {\n\t\tthis.controller.validateMaxLength(value);\n\t}\n\n\t@Watch('_name')\n\tpublic validateName(value?: string): void {\n\t\tthis.controller.validateName(value);\n\t}\n\n\t@Watch('_on')\n\tpublic validateOn(value?: InputTypeOnDefault): void {\n\t\tthis.controller.validateOn(value);\n\t}\n\n\t@Watch('_placeholder')\n\tpublic validatePlaceholder(value?: string): void {\n\t\tthis.controller.validatePlaceholder(value);\n\t}\n\n\t@Watch('_readOnly')\n\tpublic validateReadOnly(value?: boolean): void {\n\t\tthis.controller.validateReadOnly(value);\n\t}\n\n\t@Watch('_resize')\n\tpublic validateResize(value?: CSSResize): void {\n\t\tthis.controller.validateResize(value);\n\t}\n\n\t@Watch('_required')\n\tpublic validateRequired(value?: boolean): void {\n\t\tthis.controller.validateRequired(value);\n\t}\n\n\t@Watch('_rows')\n\tpublic validateRows(value?: number): void {\n\t\tthis.controller.validateRows(value);\n\t}\n\n\t@Watch('_syncValueBySelector')\n\tpublic validateSyncValueBySelector(value?: string): void {\n\t\tthis.controller.validateSyncValueBySelector(value);\n\t}\n\n\t@Watch('_tabIndex')\n\tpublic validateTabIndex(value?: number): void {\n\t\tthis.controller.validateTabIndex(value);\n\t}\n\n\t@Watch('_touched')\n\tpublic validateTouched(value?: boolean): void {\n\t\tthis.controller.validateTouched(value);\n\t}\n\n\t@Watch('_value')\n\tpublic validateValue(value?: string): void {\n\t\tthis.controller.validateValue(value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tthis._alert = this._alert === true;\n\t\tthis._touched = this._touched === true;\n\t\tthis.controller.componentWillLoad();\n\n\t\tthis.state._hasValue = !!this.state._value;\n\t\tthis.controller.addValueChangeListener((v) => (this.state._hasValue = !!v));\n\t}\n\n\tprivate readonly onChange = (event: Event) => {\n\t\tif (this.ref instanceof HTMLTextAreaElement) {\n\t\t\tsetState(this, '_currentLength', this.ref.value.length);\n\t\t\tif (this.state._adjustHeight) {\n\t\t\t\tthis._rows = increaseTextareaHeight(this.ref);\n\t\t\t}\n\t\t}\n\t\tif (typeof this.controller.onFacade.onChange === 'function') {\n\t\t\tthis.controller.onFacade.onChange(event);\n\t\t}\n\t};\n}\n"],"mappings":";;;kZAMaA,UAA2BC,EAGvCC,YAAmBC,EAA8CC,EAAcC,GAC9EC,MAAMH,EAAWC,EAAMC,GAIhBE,KAAAC,qBAAuB,KAC9B,UAAWD,KAAKJ,UAAUM,SAAW,UAAYF,KAAKJ,UAAUM,OAAOC,OAAS,EAAG,CAClFH,KAAKJ,UAAUQ,MAAMC,eAAiBL,KAAKJ,UAAUM,OAAOC,M,GAL7DH,KAAKJ,UAAYA,C,CASXU,mBAAmBC,GACzBC,EAAaR,KAAKJ,UAAW,cAAeW,EAAO,CAClDE,MAAO,CACNC,WAAYV,KAAKC,uB,CAKbU,kBAAkBJ,GACxBK,EAAYZ,KAAKJ,UAAW,aAAcW,EAAO,CAChDE,MAAO,CACNC,WAAYV,KAAKC,sBAElBY,IAAK,G,CAIAC,oBAAoBP,GAC1BQ,EAAYf,KAAKJ,UAAW,eAAgBW,E,CAGtCS,iBAAiBT,GACvBC,EAAaR,KAAKJ,UAAW,YAAaW,E,CAGpCU,eAAeV,GACrBW,EACClB,KAAKJ,UACL,WACCW,UAAiBA,IAAU,WAAaA,IAAU,QAAUA,IAAU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ACjBP,KAAKsF,WAAWsB,WAAWrG,E,CAIrBsG,cAActG,GACpBP,KAAKsF,WAAWuB,cAActG,E,CAIxBI,kBAAkBJ,GACxBP,KAAKsF,WAAW3E,kBAAkBJ,E,CAI5BuG,aAAavG,GACnBP,KAAKsF,WAAWwB,aAAavG,E,CAIvBwG,WAAWxG,GACjBP,KAAKsF,WAAWyB,WAAWxG,E,CAIrBO,oBAAoBP,GAC1BP,KAAKsF,WAAWxE,oBAAoBP,E,CAI9BS,iBAAiBT,GACvBP,KAAKsF,WAAWtE,iBAAiBT,E,CAI3BU,eAAeV,GACrBP,KAAKsF,WAAWrE,eAAeV,E,CAIzBa,iBAAiBb,GACvBP,KAAKsF,WAAWlE,iBAAiBb,E,CAI3Bc,aAAad,GACnBP,KAAKsF,WAAWjE,aAAad,E,CAIvByG,4BAA4BzG,GAClCP,KAAKsF,WAAW0B,4BAA4BzG,E,CAItC0G,iBAAiB1G,GACvBP,KAAKsF,WAAW2B,iBAAiB1G,E,CAI3B2G,gBAAgB3G,GACtBP,KAAKsF,WAAW4B,gBAAgB3G,E,CAI1Be,cAAcf,GACpBP,KAAKsF,WAAWhE,cAAcf,E,CAGxBiB,oBACNxB,KAAKyD,OAASzD,KAAKyD,SAAW,KAC9BzD,KAAK8D,SAAW9D,KAAK8D,WAAa,KAClC9D,KAAKsF,WAAW9D,oBAEhBxB,KAAKI,MAAMkD,YAActD,KAAKI,MAAMF,OACpCF,KAAKsF,WAAW6B,wBAAwBC,GAAOpH,KAAKI,MAAMkD,YAAc8D,G"}
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{r as t,h as i,H as s}from"./index-2c046ff1.js";import{v as e}from"./has-closer-268d165e.js";import{v as a}from"./show-2b9058c9.js";import{b as o,w as n,s as h,e as r,a as l}from"./prop.validators-683bb1d0.js";import{w as d}from"./validation-0efb75d3.js";import"./a11y.tipps-e607b8b3.js";import"./dev.utils-8aef00f6.js";import"./reuse-c2156413.js";import"./index-37b5cbcf.js";const p=":host{--a11y-min-size:44px;font-size:inherit}*{hyphens:auto;letter-spacing:inherit;word-break:break-word;word-spacing:inherit}[role='button'],button:not([role='link']),kol-input .input{min-height:var(--a11y-min-size);min-width:var(--a11y-min-size)}a,button,h1,h2,h3,h4,h5,h6,input,option,select,textarea{font-family:inherit;font-size:inherit}:is(a,button){background-color:transparent;border:none;margin:0;padding:0;width:100%;}:host{max-width:100%}*{box-sizing:border-box}kol-span-wc{display:grid;place-items:center}kol-span-wc>span{display:flex;place-items:center}a,button{cursor:pointer}button,input,option,select,textarea{font-family:inherit}.icon-only>kol-span-wc>span>span{display:none}:host{display:block}:host>div{background-color:#fff;height:0;left:0;position:fixed;top:0;width:100%;z-index:200}:host>div>kol-alert{display:block;margin:auto;max-width:750px}:host>div>kol-button-wc{display:block;margin:auto;position:relative;top:0;width:1em}",u=class{constructor(i){t(this,i),this.handleShowAndDuration=()=>{!0===this.state._show&&"number"==typeof this.state._showDuration&&this.state._showDuration>=0&&(clearTimeout(this.durationTimeout),this.durationTimeout=setTimeout((()=>{this.close()}),this.state._showDuration))},this.close=()=>{var t;this._show=!1,this.state=Object.assign(Object.assign({},this.state),{_show:!1}),void 0!==(null===(t=this._on)||void 0===t?void 0:t.onClose)&&this._on.onClose(new Event("Close"))},this.on={onClose:this.close},this._alert=!0,this._hasCloser=!1,this._heading="",this._level=1,this._on=void 0,this._show=!0,this._showDuration=1e4,this._type="default",this.state={_alert:!0,_level:1,_show:!0}}validateAlert(t){o(this,"_alert",t)}validateHasCloser(t){e(this,t)}validateHeading(t){n(this,"_heading",t)}validateLevel(t){d(this,t)}validateOn(t){"object"!=typeof t||"function"!=typeof(null==t?void 0:t.onClose)&&!0!==t.onClose||h(this,"_on",{onClose:t.onClose})}validateShow(t){a(this,t,{hooks:{afterPatch:this.handleShowAndDuration}})}validateShowDuration(t){r(this,"_showDuration",t,{hooks:{afterPatch:this.handleShowAndDuration}})}validateType(t){l(this,"_type",(t=>"string"==typeof t&&("default"===t||"error"===t||"info"===t||"success"===t||"warning"===t)),new Set("String {success, info, warning, error}"),t)}componentWillLoad(){this.validateAlert(this._alert),this.validateHasCloser(this._hasCloser),this.validateHeading(this._heading),this.validateLevel(this._level),this.validateOn(this._on),this.validateShow(this._show),this.validateShowDuration(this._showDuration),this.validateType(this._type)}render(){return i(s,null,this.state._show&&i("div",null,i("kol-alert",{_alert:this.state._alert,_heading:this.state._heading,_level:this.state._level,_hasCloser:this.state._hasCloser,_type:this.state._type,_variant:"card",_on:this.on},i("slot",null))))}static get watchers(){return{_alert:["validateAlert"],_hasCloser:["validateHasCloser"],_heading:["validateHeading"],_level:["validateLevel"],_on:["validateOn"],_show:["validateShow"],_showDuration:["validateShowDuration"],_type:["validateType"]}}};u.style={default:p};export{u as kol_toast};
4
+ import{r as t,h as i,H as s}from"./index-2c046ff1.js";import{v as e}from"./has-closer-62a48dbd.js";import{v as a}from"./show-6d33a33f.js";import{b as o,w as n,s as h,e as r,a as l}from"./prop.validators-601f1068.js";import{w as d}from"./validation-5300d0a1.js";import"./a11y.tipps-9f948961.js";import"./dev.utils-4290338e.js";import"./reuse-c2156413.js";import"./index-37b5cbcf.js";const p=":host{--a11y-min-size:44px;font-size:inherit}*{hyphens:auto;letter-spacing:inherit;word-break:break-word;word-spacing:inherit}[role='button'],button:not([role='link']),kol-input .input{min-height:var(--a11y-min-size);min-width:var(--a11y-min-size)}a,button,h1,h2,h3,h4,h5,h6,input,option,select,textarea{font-family:inherit;font-size:inherit}:is(a,button){background-color:transparent;border:none;margin:0;padding:0;width:100%;}:host{max-width:100%}*{box-sizing:border-box}kol-span-wc{display:grid;place-items:center}kol-span-wc>span{display:flex;place-items:center}a,button{cursor:pointer}button,input,option,select,textarea{font-family:inherit}.icon-only>kol-span-wc>span>span{display:none}:host{display:block}:host>div{background-color:#fff;height:0;left:0;position:fixed;top:0;width:100%;z-index:200}:host>div>kol-alert{display:block;margin:auto;max-width:750px}:host>div>kol-button-wc{display:block;margin:auto;position:relative;top:0;width:1em}",u=class{constructor(i){t(this,i),this.handleShowAndDuration=()=>{!0===this.state._show&&"number"==typeof this.state._showDuration&&this.state._showDuration>=0&&(clearTimeout(this.durationTimeout),this.durationTimeout=setTimeout((()=>{this.close()}),this.state._showDuration))},this.close=()=>{var t;this._show=!1,this.state=Object.assign(Object.assign({},this.state),{_show:!1}),void 0!==(null===(t=this._on)||void 0===t?void 0:t.onClose)&&this._on.onClose(new Event("Close"))},this.on={onClose:this.close},this._alert=!0,this._hasCloser=!1,this._heading="",this._level=1,this._on=void 0,this._show=!0,this._showDuration=1e4,this._type="default",this.state={_alert:!0,_level:1,_show:!0}}validateAlert(t){o(this,"_alert",t)}validateHasCloser(t){e(this,t)}validateHeading(t){n(this,"_heading",t)}validateLevel(t){d(this,t)}validateOn(t){"object"!=typeof t||"function"!=typeof(null==t?void 0:t.onClose)&&!0!==t.onClose||h(this,"_on",{onClose:t.onClose})}validateShow(t){a(this,t,{hooks:{afterPatch:this.handleShowAndDuration}})}validateShowDuration(t){r(this,"_showDuration",t,{hooks:{afterPatch:this.handleShowAndDuration}})}validateType(t){l(this,"_type",(t=>"string"==typeof t&&("default"===t||"error"===t||"info"===t||"success"===t||"warning"===t)),new Set("String {success, info, warning, error}"),t)}componentWillLoad(){this.validateAlert(this._alert),this.validateHasCloser(this._hasCloser),this.validateHeading(this._heading),this.validateLevel(this._level),this.validateOn(this._on),this.validateShow(this._show),this.validateShowDuration(this._showDuration),this.validateType(this._type)}render(){return i(s,null,this.state._show&&i("div",null,i("kol-alert",{_alert:this.state._alert,_heading:this.state._heading,_level:this.state._level,_hasCloser:this.state._hasCloser,_type:this.state._type,_variant:"card",_on:this.on},i("slot",null))))}static get watchers(){return{_alert:["validateAlert"],_hasCloser:["validateHasCloser"],_heading:["validateHeading"],_level:["validateLevel"],_on:["validateOn"],_show:["validateShow"],_showDuration:["validateShowDuration"],_type:["validateType"]}}};u.style={default:p};export{u as kol_toast};
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{r as i,h as t,H as s}from"./index-2c046ff1.js";import{c as o,b as e,o as a,f as n,s as h,a as l}from"./floating-ui.dom.esm-805abd08.js";import{w as r}from"./button-link-2ad7f3cf.js";import{v as d}from"./label-bd9566f6.js";import{g as p,n as c}from"./dev.utils-8aef00f6.js";import{w as f}from"./prop.validators-683bb1d0.js";import{p as m}from"./reuse-c2156413.js";import"./a11y.tipps-e607b8b3.js";import"./index-37b5cbcf.js";const u=new Set;function b(t){u.forEach((t=>{t.style.setProperty("z-index","999")})),u.add(t),t.style.setProperty("z-index","1000")}function v(t){if(u.delete(t),u.size>0){const t=Array.from(u).pop();t&&t.style.setProperty("z-index","1000")}}const x=":host{--a11y-min-size:44px;font-size:inherit}*{hyphens:auto;letter-spacing:inherit;word-break:break-word;word-spacing:inherit}[role='button'],button:not([role='link']),kol-input .input{min-height:var(--a11y-min-size);min-width:var(--a11y-min-size)}a,button,h1,h2,h3,h4,h5,h6,input,option,select,textarea{font-family:inherit;font-size:inherit}:is(a,button){background-color:transparent;border:none;margin:0;padding:0;width:100%;}:host{max-width:100%}*{box-sizing:border-box}kol-span-wc{display:grid;place-items:center}kol-span-wc>span{display:flex;place-items:center}a,button{cursor:pointer}button,input,option,select,textarea{font-family:inherit}.icon-only>kol-span-wc>span>span{display:none}kol-tooltip #floating{animation-duration:0.5s;animation-iteration-count:1;animation-name:fadeInOpacity;animation-timing-function:ease-in;box-sizing:border-box;display:none;position:absolute;visibility:hidden;width:max-content;top:0;left:0}kol-tooltip #arrow{height:10px;position:absolute;transform:rotate(45deg);width:10px;z-index:999}kol-tooltip .area{background-color:#fff;color:#000}kol-tooltip kol-span-wc{position:relative;z-index:1000}@keyframes fadeInOpacity{0%{opacity:0}100%{opacity:1}}",y=class{constructor(t){i(this,t),this.alignTooltip=()=>{var t;if("test"!==m&&this.previousSibling&&this.tooltipElement){const i=this.previousSibling,e=this.tooltipElement,s=this.arrowElement,r=[a(null!==(t=null==s?void 0:s.offsetHeight)&&void 0!==t?t:10),n(),h()];s&&r.push(l({element:s})),o(i,e,{placement:this.state._align,middleware:r}).then((({x:t,y:i,middlewareData:o,placement:n})=>{var l,r;Object.assign(e.style,{left:`${t}px`,top:`${i}px`,visibility:"visible"}),s&&((null===(l=o.arrow)||void 0===l?void 0:l.x)?Object.assign(s.style,{left:`${o.arrow.x}px`,top:"bottom"===n?-s.offsetHeight/2+"px":"",bottom:"top"===n?-s.offsetHeight/2+"px":""}):(null===(r=o.arrow)||void 0===r?void 0:r.y)&&Object.assign(s.style,{left:"right"===n?-s.offsetWidth/2+"px":"",right:"left"===n?-s.offsetWidth/2+"px":"",top:`${o.arrow.y}px`}))}))}},this.showTooltip=()=>{if(this.previousSibling&&this.tooltipElement){b(this.tooltipElement),this.tooltipElement.style.setProperty("display","block"),p().body.addEventListener("keyup",this.hideTooltipByEscape);const t=this.previousSibling,i=this.tooltipElement;this.cleanupAutoPositioning=e(t,i,this.alignTooltip)}},this.hideTooltip=()=>{this.tooltipElement&&(v(this.tooltipElement),this.tooltipElement.style.setProperty("display","none"),this.tooltipElement.style.setProperty("visibility","hidden"),this.cleanupAutoPositioning&&(this.cleanupAutoPositioning(),this.cleanupAutoPositioning=void 0))},this.hideTooltipByEscape=t=>{"Escape"===t.key&&(p().body.removeEventListener("keyup",this.hideTooltipByEscape),this.hideTooltip())},this.addListeners=t=>{t.addEventListener("mouseover",this.incrementOverFocusCount),t.addEventListener("focus",this.incrementOverFocusCount),t.addEventListener("mouseout",this.decrementOverFocusCount),t.addEventListener("blur",this.decrementOverFocusCount)},this.removeListeners=t=>{t.removeEventListener("mouseover",this.incrementOverFocusCount),t.removeEventListener("focus",this.incrementOverFocusCount),t.removeEventListener("mouseout",this.decrementOverFocusCount),t.removeEventListener("blur",this.decrementOverFocusCount)},this.resyncListeners=t=>{this.removeListeners(t),this.addListeners(t)},this.catchHostElement=t=>{t&&(this.previousSibling=t.previousElementSibling,this.previousSibling&&this.resyncListeners(this.previousSibling))},this.catchTooltipElement=t=>{this.tooltipElement=t,this.tooltipElement&&this.resyncListeners(this.tooltipElement)},this.catchArrowElement=t=>{this.arrowElement=t},this.overFocusCount=0,this.incrementOverFocusCount=()=>{this.overFocusCount++,this.showOrHideTooltip()},this.decrementOverFocusCount=()=>{this.overFocusCount--,this.showOrHideTooltip()},this.showOrHideTooltip=()=>{clearTimeout(this.overFocusTimeout),this.overFocusTimeout=setTimeout((()=>{clearTimeout(this.overFocusTimeout),this.overFocusCount>0?this.showTooltip():this.hideTooltip()}),250)},this._align="top",this._id=void 0,this._label=void 0,this.state={_align:"top",_id:c(),_label:"…"}}render(){return t(s,{ref:this.catchHostElement},""!==this.state._label&&t("div",{id:"floating",ref:this.catchTooltipElement},t("div",{class:"area",id:"arrow",ref:this.catchArrowElement}),t("kol-span-wc",{class:"area",id:this.state._id,_label:this.state._label})))}validateAlign(t){r(this,"_align",t)}validateId(t){f(this,"_id",t)}validateLabel(t){d(this,t)}componentWillLoad(){this.validateAlign(this._align),this.validateId(this._id),this.validateLabel(this._label)}disconnectedCallback(){this.previousSibling&&this.removeListeners(this.previousSibling),this.tooltipElement&&this.removeListeners(this.tooltipElement),this.cleanupAutoPositioning&&this.cleanupAutoPositioning()}static get watchers(){return{_align:["validateAlign"],_id:["validateId"],_label:["validateLabel"]}}};y.style=x;export{y as kol_tooltip};
4
+ import{r as i,h as t,H as s}from"./index-2c046ff1.js";import{c as o,b as e,o as a,f as n,s as h,a as l}from"./floating-ui.dom.esm-26e61da8.js";import{w as r}from"./button-link-99acae48.js";import{v as d}from"./label-223fef8f.js";import{g as p,n as c}from"./dev.utils-4290338e.js";import{w as f}from"./prop.validators-601f1068.js";import{p as m}from"./reuse-c2156413.js";import"./a11y.tipps-9f948961.js";import"./index-37b5cbcf.js";const u=new Set;function b(t){u.forEach((t=>{t.style.setProperty("z-index","999")})),u.add(t),t.style.setProperty("z-index","1000")}function v(t){if(u.delete(t),u.size>0){const t=Array.from(u).pop();t&&t.style.setProperty("z-index","1000")}}const x=":host{--a11y-min-size:44px;font-size:inherit}*{hyphens:auto;letter-spacing:inherit;word-break:break-word;word-spacing:inherit}[role='button'],button:not([role='link']),kol-input .input{min-height:var(--a11y-min-size);min-width:var(--a11y-min-size)}a,button,h1,h2,h3,h4,h5,h6,input,option,select,textarea{font-family:inherit;font-size:inherit}:is(a,button){background-color:transparent;border:none;margin:0;padding:0;width:100%;}:host{max-width:100%}*{box-sizing:border-box}kol-span-wc{display:grid;place-items:center}kol-span-wc>span{display:flex;place-items:center}a,button{cursor:pointer}button,input,option,select,textarea{font-family:inherit}.icon-only>kol-span-wc>span>span{display:none}kol-tooltip #floating{animation-duration:0.5s;animation-iteration-count:1;animation-name:fadeInOpacity;animation-timing-function:ease-in;box-sizing:border-box;display:none;position:absolute;visibility:hidden;width:max-content;top:0;left:0}kol-tooltip #arrow{height:10px;position:absolute;transform:rotate(45deg);width:10px;z-index:999}kol-tooltip .area{background-color:#fff;color:#000}kol-tooltip kol-span-wc{position:relative;z-index:1000}@keyframes fadeInOpacity{0%{opacity:0}100%{opacity:1}}",y=class{constructor(t){i(this,t),this.alignTooltip=()=>{var t;if("test"!==m&&this.previousSibling&&this.tooltipElement){const i=this.previousSibling,e=this.tooltipElement,s=this.arrowElement,r=[a(null!==(t=null==s?void 0:s.offsetHeight)&&void 0!==t?t:10),n(),h()];s&&r.push(l({element:s})),o(i,e,{placement:this.state._align,middleware:r}).then((({x:t,y:i,middlewareData:o,placement:n})=>{var l,r;Object.assign(e.style,{left:`${t}px`,top:`${i}px`,visibility:"visible"}),s&&((null===(l=o.arrow)||void 0===l?void 0:l.x)?Object.assign(s.style,{left:`${o.arrow.x}px`,top:"bottom"===n?-s.offsetHeight/2+"px":"",bottom:"top"===n?-s.offsetHeight/2+"px":""}):(null===(r=o.arrow)||void 0===r?void 0:r.y)&&Object.assign(s.style,{left:"right"===n?-s.offsetWidth/2+"px":"",right:"left"===n?-s.offsetWidth/2+"px":"",top:`${o.arrow.y}px`}))}))}},this.showTooltip=()=>{if(this.previousSibling&&this.tooltipElement){b(this.tooltipElement),this.tooltipElement.style.setProperty("display","block"),p().body.addEventListener("keyup",this.hideTooltipByEscape);const t=this.previousSibling,i=this.tooltipElement;this.cleanupAutoPositioning=e(t,i,this.alignTooltip)}},this.hideTooltip=()=>{this.tooltipElement&&(v(this.tooltipElement),this.tooltipElement.style.setProperty("display","none"),this.tooltipElement.style.setProperty("visibility","hidden"),this.cleanupAutoPositioning&&(this.cleanupAutoPositioning(),this.cleanupAutoPositioning=void 0))},this.hideTooltipByEscape=t=>{"Escape"===t.key&&(p().body.removeEventListener("keyup",this.hideTooltipByEscape),this.hideTooltip())},this.addListeners=t=>{t.addEventListener("mouseover",this.incrementOverFocusCount),t.addEventListener("focus",this.incrementOverFocusCount),t.addEventListener("mouseout",this.decrementOverFocusCount),t.addEventListener("blur",this.decrementOverFocusCount)},this.removeListeners=t=>{t.removeEventListener("mouseover",this.incrementOverFocusCount),t.removeEventListener("focus",this.incrementOverFocusCount),t.removeEventListener("mouseout",this.decrementOverFocusCount),t.removeEventListener("blur",this.decrementOverFocusCount)},this.resyncListeners=t=>{this.removeListeners(t),this.addListeners(t)},this.catchHostElement=t=>{t&&(this.previousSibling=t.previousElementSibling,this.previousSibling&&this.resyncListeners(this.previousSibling))},this.catchTooltipElement=t=>{this.tooltipElement=t,this.tooltipElement&&this.resyncListeners(this.tooltipElement)},this.catchArrowElement=t=>{this.arrowElement=t},this.overFocusCount=0,this.incrementOverFocusCount=()=>{this.overFocusCount++,this.showOrHideTooltip()},this.decrementOverFocusCount=()=>{this.overFocusCount--,this.showOrHideTooltip()},this.showOrHideTooltip=()=>{clearTimeout(this.overFocusTimeout),this.overFocusTimeout=setTimeout((()=>{clearTimeout(this.overFocusTimeout),this.overFocusCount>0?this.showTooltip():this.hideTooltip()}),250)},this._align="top",this._id=void 0,this._label=void 0,this.state={_align:"top",_id:c(),_label:"…"}}render(){return t(s,{ref:this.catchHostElement},""!==this.state._label&&t("div",{id:"floating",ref:this.catchTooltipElement},t("div",{class:"area",id:"arrow",ref:this.catchArrowElement}),t("kol-span-wc",{class:"area",id:this.state._id,_label:this.state._label})))}validateAlign(t){r(this,"_align",t)}validateId(t){f(this,"_id",t)}validateLabel(t){d(this,t)}componentWillLoad(){this.validateAlign(this._align),this.validateId(this._id),this.validateLabel(this._label)}disconnectedCallback(){this.previousSibling&&this.removeListeners(this.previousSibling),this.tooltipElement&&this.removeListeners(this.tooltipElement),this.cleanupAutoPositioning&&this.cleanupAutoPositioning()}static get watchers(){return{_align:["validateAlign"],_id:["validateId"],_label:["validateLabel"]}}};y.style=x;export{y as kol_tooltip};
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{r as i,h as t}from"./index-2c046ff1.js";import{v as e}from"./label-bd9566f6.js";import"./a11y.tipps-e607b8b3.js";import"./dev.utils-8aef00f6.js";import"./reuse-c2156413.js";import"./prop.validators-683bb1d0.js";import"./index-37b5cbcf.js";var n;!function(e){e.Violett="#5f316e",e.Dunkelrot="#780f2d",e.Rot="#c0003c",e.Orange="#cd5038",e.Hellorange="#f7bb3d",e.Gelb="#f9e03a",e["Hellgrün"]="#c1ca31",e.Oliv="#597c39",e["Dunkelgrün"]="#005c45",e["Grün"]="#00854a",e["Türkis"]="#00818b",e.Hellblau="#80cdec",e.Blau="#0077b6",e.Petrol="#007194",e.Dunkelblau="#004b76",e.Dunkelgrau="#576164",e.Hellgrau="#bec5c9"}(n||(n={}));const o=":host{--a11y-min-size:44px;font-size:inherit}*{hyphens:auto;letter-spacing:inherit;word-break:break-word;word-spacing:inherit}[role='button'],button:not([role='link']),kol-input .input{min-height:var(--a11y-min-size);min-width:var(--a11y-min-size)}a,button,h1,h2,h3,h4,h5,h6,input,option,select,textarea{font-family:inherit;font-size:inherit}:is(a,button){background-color:transparent;border:none;margin:0;padding:0;width:100%;}:host{max-width:100%}*{box-sizing:border-box}kol-span-wc{display:grid;place-items:center}kol-span-wc>span{display:flex;place-items:center}a,button{cursor:pointer}button,input,option,select,textarea{font-family:inherit}.icon-only>kol-span-wc>span>span{display:none}",a=class{constructor(e){i(this,e),this._label=void 0,this._version=void 0,this.state={_label:"0.0.0-alpha.0"}}render(){return t("kol-badge",{_color:n.Hellgrau,_icon:"codicon codicon-versions",_label:`v${this.state._label}`})}validateLabel(t){e(this,t)}validateVersion(e){this.validateLabel(e)}componentWillLoad(){this.validateLabel(this._label||this._version)}static get watchers(){return{_label:["validateLabel"],_version:["validateVersion"]}}};a.style={default:o};export{a as kol_version};
4
+ import{r as i,h as t}from"./index-2c046ff1.js";import{v as e}from"./label-223fef8f.js";import"./a11y.tipps-9f948961.js";import"./dev.utils-4290338e.js";import"./reuse-c2156413.js";import"./prop.validators-601f1068.js";import"./index-37b5cbcf.js";var n;!function(e){e.Violett="#5f316e",e.Dunkelrot="#780f2d",e.Rot="#c0003c",e.Orange="#cd5038",e.Hellorange="#f7bb3d",e.Gelb="#f9e03a",e["Hellgrün"]="#c1ca31",e.Oliv="#597c39",e["Dunkelgrün"]="#005c45",e["Grün"]="#00854a",e["Türkis"]="#00818b",e.Hellblau="#80cdec",e.Blau="#0077b6",e.Petrol="#007194",e.Dunkelblau="#004b76",e.Dunkelgrau="#576164",e.Hellgrau="#bec5c9"}(n||(n={}));const o=":host{--a11y-min-size:44px;font-size:inherit}*{hyphens:auto;letter-spacing:inherit;word-break:break-word;word-spacing:inherit}[role='button'],button:not([role='link']),kol-input .input{min-height:var(--a11y-min-size);min-width:var(--a11y-min-size)}a,button,h1,h2,h3,h4,h5,h6,input,option,select,textarea{font-family:inherit;font-size:inherit}:is(a,button){background-color:transparent;border:none;margin:0;padding:0;width:100%;}:host{max-width:100%}*{box-sizing:border-box}kol-span-wc{display:grid;place-items:center}kol-span-wc>span{display:flex;place-items:center}a,button{cursor:pointer}button,input,option,select,textarea{font-family:inherit}.icon-only>kol-span-wc>span>span{display:none}",a=class{constructor(e){i(this,e),this._label=void 0,this._version=void 0,this.state={_label:"0.0.0-alpha.0"}}render(){return t("kol-badge",{_color:n.Hellgrau,_icon:"codicon codicon-versions",_label:`v${this.state._label}`})}validateLabel(t){e(this,t)}validateVersion(e){this.validateLabel(e)}componentWillLoad(){this.validateLabel(this._label||this._version)}static get watchers(){return{_label:["validateLabel"],_version:["validateVersion"]}}};a.style={default:o};export{a as kol_version};
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{p as e,b as a}from"./index-2c046ff1.js";export{s as setNonce}from"./index-2c046ff1.js";import{g as _}from"./app-globals-1811b38e.js";import"./index-d8ac1088.js";import"./index-37b5cbcf.js";import"./dev.utils-8aef00f6.js";import"./reuse-c2156413.js";const l=()=>{const a=import.meta.url,_={};return""!==a&&(_.resourcesUrl=new URL(".",a).href),e(_)};l().then((e=>(_(),a(JSON.parse('[["kol-table",[[33,"kol-table",{"_caption":[1],"_data":[1],"_dataFoot":[1,"_data-foot"],"_headers":[1],"_minWidth":[1,"_min-width"],"_pagination":[8],"state":[32]}]]],["kol-input-adapter-leanup",[[1,"kol-input-adapter-leanup"]]],["kol-input-radio-group",[[1,"kol-input-radio-group",{"_accessKey":[1,"_access-key"],"_alert":[4],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_id":[1],"_label":[8],"_list":[1],"_name":[1],"_on":[16],"_orientation":[1],"_required":[4],"_tabIndex":[2,"_tab-index"],"_touched":[4],"_value":[8]}]]],["kol-input-checkbox",[[33,"kol-input-checkbox",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_checked":[1540],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_indeterminate":[1540],"_label":[8],"_name":[1],"_on":[16],"_required":[4],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_type":[1],"_value":[1],"_variant":[1],"state":[32]}]]],["kol-input-color",[[33,"kol-input-color",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_list":[1],"_name":[1],"_on":[16],"_smartButton":[16],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-date",[[33,"kol-input-date",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_list":[1],"_max":[1],"_min":[1],"_name":[1],"_on":[16],"_readOnly":[4,"_read-only"],"_required":[4],"_smartButton":[16],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_step":[2],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_type":[1],"_value":[1025],"state":[32]}]]],["kol-input-email",[[33,"kol-input-email",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[4],"_error":[1],"_hasCounter":[4,"_has-counter"],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_list":[1],"_maxLength":[2,"_max-length"],"_multiple":[4],"_name":[1],"_on":[16],"_pattern":[1],"_placeholder":[1],"_readOnly":[4,"_read-only"],"_required":[4],"_size":[2],"_smartButton":[16],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-file",[[33,"kol-input-file",{"_accept":[1],"_accessKey":[1,"_access-key"],"_alert":[1540],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_multiple":[4],"_name":[1],"_on":[16],"_required":[4],"_smartButton":[16],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-number",[[33,"kol-input-number",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_list":[1],"_max":[8],"_min":[8],"_name":[1],"_on":[16],"_placeholder":[1],"_readOnly":[4,"_read-only"],"_required":[4],"_smartButton":[16],"_step":[2],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_type":[1],"_value":[1032],"state":[32]}]]],["kol-input-password",[[33,"kol-input-password",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[4],"_error":[1],"_hasCounter":[4,"_has-counter"],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_maxLength":[2,"_max-length"],"_name":[1],"_on":[16],"_pattern":[1],"_placeholder":[1],"_readOnly":[4,"_read-only"],"_required":[4],"_size":[2],"_smartButton":[16],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-range",[[33,"kol-input-range",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_list":[1],"_max":[2],"_min":[2],"_name":[1],"_on":[16],"_step":[2],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[2],"state":[32]}]]],["kol-input-text",[[33,"kol-input-text",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[4],"_error":[1],"_hasCounter":[4,"_has-counter"],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_list":[1],"_maxLength":[2,"_max-length"],"_name":[1],"_on":[16],"_pattern":[1],"_placeholder":[1],"_readOnly":[4,"_read-only"],"_required":[4],"_size":[2],"_smartButton":[16],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_type":[1],"_value":[1025],"state":[32]}]]],["kol-textarea",[[33,"kol-textarea",{"_accessKey":[1,"_access-key"],"_adjustHeight":[4,"_adjust-height"],"_alert":[1540],"_disabled":[4],"_error":[1],"_hasCounter":[4,"_has-counter"],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_id":[1],"_label":[8],"_maxLength":[2,"_max-length"],"_name":[1],"_on":[16],"_placeholder":[1],"_readOnly":[4,"_read-only"],"_resize":[1],"_required":[4],"_rows":[1026],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-nav",[[33,"kol-nav",{"_ariaCurrentValue":[8,"_aria-current-value"],"_ariaLabel":[1,"_aria-label"],"_collapsible":[4],"_compact":[4],"_hasCompactButton":[4,"_has-compact-button"],"_label":[1],"_links":[1],"_orientation":[1],"_variant":[1],"state":[32]}]]],["kol-toast",[[33,"kol-toast",{"_alert":[4],"_hasCloser":[4,"_has-closer"],"_heading":[1],"_level":[2],"_on":[16],"_show":[1540],"_showDuration":[2,"_show-duration"],"_type":[1],"state":[32]}]]],["kol-link-group",[[33,"kol-link-group",{"_ariaLabel":[1,"_aria-label"],"_listStyleType":[1,"_list-style-type"],"_heading":[1],"_label":[1],"_level":[2],"_links":[1],"_ordered":[4],"_orientation":[1],"state":[32]}]]],["kol-accordion",[[33,"kol-accordion",{"_heading":[1],"_level":[2],"_on":[16],"_open":[1540],"state":[32]}]]],["kol-breadcrumb",[[33,"kol-breadcrumb",{"_ariaLabel":[1,"_aria-label"],"_label":[1],"_links":[1],"state":[32]}]]],["kol-quote",[[33,"kol-quote",{"_caption":[1],"_href":[1],"_quote":[1],"_variant":[1],"state":[32]}]]],["kol-tabs",[[33,"kol-tabs",{"_ariaLabel":[1,"_aria-label"],"_label":[1],"_on":[16],"_selected":[1538],"_tabs":[1],"_tabsAlign":[1,"_tabs-align"],"state":[32]}]]],["kol-version",[[33,"kol-version",{"_label":[1],"_version":[1],"state":[32]}]]],["kol-button-link",[[33,"kol-button-link",{"_accessKey":[1,"_access-key"],"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[4,"_aria-expanded"],"_ariaLabel":[1025,"_aria-label"],"_ariaSelected":[4,"_aria-selected"],"_disabled":[4],"_hideLabel":[4,"_hide-label"],"_icon":[1],"_iconOnly":[4,"_icon-only"],"_id":[1],"_label":[8],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_type":[1],"_value":[16]}]]],["kol-link-button",[[33,"kol-link-button",{"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[4,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[4,"_aria-selected"],"_customClass":[1,"_custom-class"],"_disabled":[4],"_download":[8],"_hideLabel":[4,"_hide-label"],"_href":[1],"_icon":[1],"_iconOnly":[4,"_icon-only"],"_label":[8],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_target":[1],"_targetDescription":[1,"_target-description"],"_tooltipAlign":[1,"_tooltip-align"],"_variant":[1]}]]],["kol-skip-nav",[[33,"kol-skip-nav",{"_ariaLabel":[1,"_aria-label"],"_label":[1],"_links":[1],"state":[32]}]]],["kol-split-button",[[33,"kol-split-button",{"_accessKey":[1,"_access-key"],"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[4,"_aria-expanded"],"_ariaLabel":[1025,"_aria-label"],"_ariaSelected":[4,"_aria-selected"],"_customClass":[1,"_custom-class"],"_disabled":[4],"_hideLabel":[4,"_hide-label"],"_icon":[1],"_iconOnly":[4,"_icon-only"],"_label":[1],"_on":[16],"_role":[1],"_showDropdown":[1540,"_show-dropdown"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_type":[1],"_value":[16],"_variant":[1],"state":[32]}]]],["kol-abbr",[[33,"kol-abbr",{"_tooltipAlign":[1,"_tooltip-align"],"_title":[1],"state":[32]}]]],["kol-details",[[33,"kol-details",{"_open":[1540],"_summary":[1],"state":[32]}]]],["kol-span",[[33,"kol-span",{"_hideLabel":[4,"_hide-label"],"_icon":[1],"_iconOnly":[4,"_icon-only"],"_label":[8]}]]],["kol-button-group",[[33,"kol-button-group"]]],["kol-card",[[33,"kol-card",{"_hasFooter":[4,"_has-footer"],"_heading":[1],"_headline":[1],"_level":[2],"state":[32]}]]],["kol-form",[[1,"kol-form",{"_on":[16],"_requiredText":[8,"_required-text"],"state":[32]}]]],["kol-heading",[[33,"kol-heading",{"_label":[8],"_level":[2],"_secondaryHeadline":[1,"_secondary-headline"]}]]],["kol-icon-font-awesome",[[0,"kol-icon-font-awesome",{"_ariaLabel":[1,"_aria-label"],"_icon":[1],"_prefix":[1],"_part":[1]}]]],["kol-image",[[33,"kol-image",{"_alt":[1],"_loading":[1],"_sizes":[1],"_src":[1],"_srcset":[1],"state":[32]}]]],["kol-kolibri",[[33,"kol-kolibri",{"_animate":[4],"_color":[1],"_labeled":[4],"state":[32]}]]],["kol-logo",[[33,"kol-logo",{"_abbr":[1],"_org":[1],"state":[32]}]]],["kol-modal",[[33,"kol-modal",{"_activeElement":[1040],"_ariaLabel":[1,"_aria-label"],"_label":[1],"_on":[16],"_width":[1],"state":[32]}]]],["kol-popover",[[4,"kol-popover",{"_align":[1],"_show":[1540],"state":[32]}]]],["kol-progress",[[33,"kol-progress",{"_label":[1],"_max":[2],"_type":[1],"_unit":[1],"_value":[2],"_variant":[1],"state":[32]}]]],["kol-spin",[[33,"kol-spin",{"_show":[4],"_variant":[1],"state":[32]}]]],["kol-button-group-wc",[[4,"kol-button-group-wc",{"state":[32]}]]],["kol-icon",[[33,"kol-icon",{"_ariaLabel":[1,"_aria-label"],"_icon":[1],"_label":[1],"_part":[1],"state":[32]}]]],["kol-icon-icofont",[[0,"kol-icon-icofont",{"_ariaLabel":[1,"_aria-label"],"_icon":[1],"_part":[1]}]]],["kol-symbol",[[0,"kol-symbol",{"_ariaLabel":[1,"_aria-label"],"_label":[1],"_symbol":[1],"state":[32]}]]],["kol-span-wc",[[4,"kol-span-wc",{"_hideLabel":[4,"_hide-label"],"_icon":[1],"_iconOnly":[4,"_icon-only"],"_label":[8],"state":[32]}]]],["kol-tooltip",[[0,"kol-tooltip",{"_align":[1],"_id":[1],"_label":[1],"state":[32]}]]],["kol-button-wc_2",[[4,"kol-heading-wc",{"_label":[8],"_level":[2],"_secondaryHeadline":[1,"_secondary-headline"],"state":[32]}],[4,"kol-button-wc",{"_accessKey":[1,"_access-key"],"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[4,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[4,"_aria-selected"],"_customClass":[1,"_custom-class"],"_disabled":[4],"_hideLabel":[4,"_hide-label"],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[4,"_icon-only"],"_id":[1],"_label":[8],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_type":[1],"_value":[16],"_variant":[1],"state":[32]}]]],["kol-pagination",[[33,"kol-pagination",{"_boundaryCount":[2,"_boundary-count"],"_customClass":[1,"_custom-class"],"_hasButtons":[8,"_has-buttons"],"_page":[2],"_pageSize":[1026,"_page-size"],"_pageSizeOptions":[1,"_page-size-options"],"_on":[16],"_siblingCount":[2,"_sibling-count"],"_tooltipAlign":[1,"_tooltip-align"],"_total":[2],"_variant":[1],"state":[32]}]]],["kol-input-radio",[[33,"kol-input-radio",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_id":[1],"_label":[8],"_list":[1],"_name":[1],"_on":[16],"_orientation":[1],"_required":[4],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[8],"state":[32]}]]],["kol-button-link-text-switch",[[0,"kol-button-link-text-switch",{"_ariaCurrentValue":[8,"_aria-current-value"],"_hasChildren":[4,"_has-children"],"_link":[16],"_hideLabel":[4,"_hide-label"],"_selected":[4]}]]],["kol-badge",[[33,"kol-badge",{"_color":[1],"_hideLabel":[4,"_hide-label"],"_icon":[1],"_iconOnly":[4,"_icon-only"],"_label":[1],"_smartButton":[1,"_smart-button"],"state":[32]}]]],["kol-select",[[33,"kol-select",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_disabled":[4],"_error":[1],"_height":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_list":[1],"_multiple":[4],"_name":[1],"_on":[16],"_required":[4],"_size":[2],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[1025],"state":[32]}]]],["kol-indented-text",[[33,"kol-indented-text",{"state":[32]}]]],["kol-button",[[33,"kol-button",{"_accessKey":[1,"_access-key"],"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[4,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[4,"_aria-selected"],"_customClass":[1,"_custom-class"],"_disabled":[4],"_hideLabel":[4,"_hide-label"],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[4,"_icon-only"],"_id":[1],"_label":[8],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_type":[1],"_value":[16],"_variant":[1]}]]],["kol-link-wc",[[4,"kol-link-wc",{"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[4,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[4,"_aria-selected"],"_disabled":[4],"_download":[8],"_hideLabel":[4,"_hide-label"],"_href":[1],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[4,"_icon-only"],"_label":[8],"_on":[16],"_role":[1],"_selector":[1],"_stealth":[4],"_tabIndex":[2,"_tab-index"],"_target":[1],"_targetDescription":[1,"_target-description"],"_tooltipAlign":[1,"_tooltip-align"],"_useCase":[1,"_use-case"],"state":[32]}]]],["kol-link",[[33,"kol-link",{"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[4,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[4,"_aria-selected"],"_disabled":[4],"_download":[8],"_hideLabel":[4,"_hide-label"],"_href":[1],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[4,"_icon-only"],"_label":[8],"_on":[16],"_role":[1],"_selector":[1],"_stealth":[4],"_tabIndex":[2,"_tab-index"],"_target":[1],"_targetDescription":[1,"_target-description"],"_tooltipAlign":[1,"_tooltip-align"],"_useCase":[1,"_use-case"]}]]],["kol-alert",[[33,"kol-alert",{"_alert":[4],"_hasCloser":[4,"_has-closer"],"_heading":[1],"_level":[2],"_on":[16],"_type":[1],"_variant":[1],"state":[32]}]]],["kol-alert-wc_2",[[4,"kol-input",{"_alert":[4],"_currentLength":[2,"_current-length"],"_disabled":[4],"_error":[1],"_hasCounter":[4,"_has-counter"],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[16],"_id":[1],"_list":[1],"_maxLength":[2,"_max-length"],"_readOnly":[4,"_read-only"],"_renderNoLabel":[4,"_render-no-label"],"_required":[4],"_slotName":[1,"_slot-name"],"_smartButton":[16],"_touched":[4]}],[4,"kol-alert-wc",{"_alert":[4],"_hasCloser":[4,"_has-closer"],"_heading":[1],"_level":[2],"_on":[16],"_type":[1],"_variant":[1],"state":[32]}]]]]'),e))));
4
+ import{p as e,b as a}from"./index-2c046ff1.js";export{s as setNonce}from"./index-2c046ff1.js";import{g as _}from"./app-globals-bf9eb17a.js";import"./index-d8ac1088.js";import"./index-37b5cbcf.js";import"./dev.utils-4290338e.js";import"./reuse-c2156413.js";const l=()=>{const a=import.meta.url,_={};return""!==a&&(_.resourcesUrl=new URL(".",a).href),e(_)};l().then((e=>(_(),a(JSON.parse('[["kol-table",[[33,"kol-table",{"_caption":[1],"_data":[1],"_dataFoot":[1,"_data-foot"],"_headers":[1],"_minWidth":[1,"_min-width"],"_pagination":[8],"state":[32]}]]],["kol-input-adapter-leanup",[[1,"kol-input-adapter-leanup"]]],["kol-input-radio-group",[[1,"kol-input-radio-group",{"_accessKey":[1,"_access-key"],"_alert":[4],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_id":[1],"_label":[8],"_list":[1],"_name":[1],"_on":[16],"_orientation":[1],"_required":[4],"_tabIndex":[2,"_tab-index"],"_touched":[4],"_value":[8]}]]],["kol-input-checkbox",[[33,"kol-input-checkbox",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_checked":[1540],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_indeterminate":[1540],"_label":[8],"_name":[1],"_on":[16],"_required":[4],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_type":[1],"_value":[8],"_variant":[1],"state":[32]}]]],["kol-input-color",[[33,"kol-input-color",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_list":[1],"_name":[1],"_on":[16],"_smartButton":[16],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-date",[[33,"kol-input-date",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_list":[1],"_max":[1],"_min":[1],"_name":[1],"_on":[16],"_readOnly":[4,"_read-only"],"_required":[4],"_smartButton":[16],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_step":[2],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_type":[1],"_value":[1025],"state":[32]}]]],["kol-input-email",[[33,"kol-input-email",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[4],"_error":[1],"_hasCounter":[4,"_has-counter"],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_list":[1],"_maxLength":[2,"_max-length"],"_multiple":[4],"_name":[1],"_on":[16],"_pattern":[1],"_placeholder":[1],"_readOnly":[4,"_read-only"],"_required":[4],"_size":[2],"_smartButton":[16],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-file",[[33,"kol-input-file",{"_accept":[1],"_accessKey":[1,"_access-key"],"_alert":[1540],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_multiple":[4],"_name":[1],"_on":[16],"_required":[4],"_smartButton":[16],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-number",[[33,"kol-input-number",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_list":[1],"_max":[8],"_min":[8],"_name":[1],"_on":[16],"_placeholder":[1],"_readOnly":[4,"_read-only"],"_required":[4],"_smartButton":[16],"_step":[2],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_type":[1],"_value":[1032],"state":[32]}]]],["kol-input-password",[[33,"kol-input-password",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[4],"_error":[1],"_hasCounter":[4,"_has-counter"],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_maxLength":[2,"_max-length"],"_name":[1],"_on":[16],"_pattern":[1],"_placeholder":[1],"_readOnly":[4,"_read-only"],"_required":[4],"_size":[2],"_smartButton":[16],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-range",[[33,"kol-input-range",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_list":[1],"_max":[2],"_min":[2],"_name":[1],"_on":[16],"_step":[2],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[2],"state":[32]}]]],["kol-input-text",[[33,"kol-input-text",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[4],"_error":[1],"_hasCounter":[4,"_has-counter"],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_list":[1],"_maxLength":[2,"_max-length"],"_name":[1],"_on":[16],"_pattern":[1],"_placeholder":[1],"_readOnly":[4,"_read-only"],"_required":[4],"_size":[2],"_smartButton":[16],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_type":[1],"_value":[1025],"state":[32]}]]],["kol-textarea",[[33,"kol-textarea",{"_accessKey":[1,"_access-key"],"_adjustHeight":[4,"_adjust-height"],"_alert":[1540],"_disabled":[4],"_error":[1],"_hasCounter":[4,"_has-counter"],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_id":[1],"_label":[8],"_maxLength":[2,"_max-length"],"_name":[1],"_on":[16],"_placeholder":[1],"_readOnly":[4,"_read-only"],"_resize":[1],"_required":[4],"_rows":[1026],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-nav",[[33,"kol-nav",{"_ariaCurrentValue":[8,"_aria-current-value"],"_ariaLabel":[1,"_aria-label"],"_collapsible":[4],"_compact":[4],"_hasCompactButton":[4,"_has-compact-button"],"_label":[1],"_links":[1],"_orientation":[1],"_variant":[1],"state":[32]}]]],["kol-toast",[[33,"kol-toast",{"_alert":[4],"_hasCloser":[4,"_has-closer"],"_heading":[1],"_level":[2],"_on":[16],"_show":[1540],"_showDuration":[2,"_show-duration"],"_type":[1],"state":[32]}]]],["kol-link-group",[[33,"kol-link-group",{"_ariaLabel":[1,"_aria-label"],"_listStyleType":[1,"_list-style-type"],"_heading":[1],"_label":[1],"_level":[2],"_links":[1],"_ordered":[4],"_orientation":[1],"state":[32]}]]],["kol-accordion",[[33,"kol-accordion",{"_heading":[1],"_level":[2],"_on":[16],"_open":[1540],"state":[32]}]]],["kol-breadcrumb",[[33,"kol-breadcrumb",{"_ariaLabel":[1,"_aria-label"],"_label":[1],"_links":[1],"state":[32]}]]],["kol-quote",[[33,"kol-quote",{"_caption":[1],"_href":[1],"_quote":[1],"_variant":[1],"state":[32]}]]],["kol-tabs",[[33,"kol-tabs",{"_ariaLabel":[1,"_aria-label"],"_label":[1],"_on":[16],"_selected":[1538],"_tabs":[1],"_tabsAlign":[1,"_tabs-align"],"state":[32]}]]],["kol-version",[[33,"kol-version",{"_label":[1],"_version":[1],"state":[32]}]]],["kol-button-link",[[33,"kol-button-link",{"_accessKey":[1,"_access-key"],"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[4,"_aria-expanded"],"_ariaLabel":[1025,"_aria-label"],"_ariaSelected":[4,"_aria-selected"],"_disabled":[4],"_hideLabel":[4,"_hide-label"],"_icon":[1],"_iconOnly":[4,"_icon-only"],"_id":[1],"_label":[8],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_type":[1],"_value":[16]}]]],["kol-link-button",[[33,"kol-link-button",{"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[4,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[4,"_aria-selected"],"_customClass":[1,"_custom-class"],"_disabled":[4],"_download":[8],"_hideLabel":[4,"_hide-label"],"_href":[1],"_icon":[1],"_iconOnly":[4,"_icon-only"],"_label":[8],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_target":[1],"_targetDescription":[1,"_target-description"],"_tooltipAlign":[1,"_tooltip-align"],"_variant":[1]}]]],["kol-skip-nav",[[33,"kol-skip-nav",{"_ariaLabel":[1,"_aria-label"],"_label":[1],"_links":[1],"state":[32]}]]],["kol-split-button",[[33,"kol-split-button",{"_accessKey":[1,"_access-key"],"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[4,"_aria-expanded"],"_ariaLabel":[1025,"_aria-label"],"_ariaSelected":[4,"_aria-selected"],"_customClass":[1,"_custom-class"],"_disabled":[4],"_hideLabel":[4,"_hide-label"],"_icon":[1],"_iconOnly":[4,"_icon-only"],"_label":[1],"_on":[16],"_role":[1],"_showDropdown":[1540,"_show-dropdown"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_type":[1],"_value":[16],"_variant":[1],"state":[32]}]]],["kol-abbr",[[33,"kol-abbr",{"_tooltipAlign":[1,"_tooltip-align"],"_title":[1],"state":[32]}]]],["kol-details",[[33,"kol-details",{"_open":[1540],"_summary":[1],"state":[32]}]]],["kol-span",[[33,"kol-span",{"_hideLabel":[4,"_hide-label"],"_icon":[1],"_iconOnly":[4,"_icon-only"],"_label":[8]}]]],["kol-button-group",[[33,"kol-button-group"]]],["kol-card",[[33,"kol-card",{"_hasFooter":[4,"_has-footer"],"_heading":[1],"_headline":[1],"_level":[2],"state":[32]}]]],["kol-form",[[1,"kol-form",{"_on":[16],"_requiredText":[8,"_required-text"],"state":[32]}]]],["kol-heading",[[33,"kol-heading",{"_label":[8],"_level":[2],"_secondaryHeadline":[1,"_secondary-headline"]}]]],["kol-icon-font-awesome",[[0,"kol-icon-font-awesome",{"_ariaLabel":[1,"_aria-label"],"_icon":[1],"_prefix":[1],"_part":[1]}]]],["kol-image",[[33,"kol-image",{"_alt":[1],"_loading":[1],"_sizes":[1],"_src":[1],"_srcset":[1],"state":[32]}]]],["kol-kolibri",[[33,"kol-kolibri",{"_animate":[4],"_color":[1],"_labeled":[4],"state":[32]}]]],["kol-logo",[[33,"kol-logo",{"_abbr":[1],"_org":[1],"state":[32]}]]],["kol-modal",[[33,"kol-modal",{"_activeElement":[1040],"_ariaLabel":[1,"_aria-label"],"_label":[1],"_on":[16],"_width":[1],"state":[32]}]]],["kol-popover",[[4,"kol-popover",{"_align":[1],"_show":[1540],"state":[32]}]]],["kol-progress",[[33,"kol-progress",{"_label":[1],"_max":[2],"_type":[1],"_unit":[1],"_value":[2],"_variant":[1],"state":[32]}]]],["kol-spin",[[33,"kol-spin",{"_show":[4],"_variant":[1],"state":[32]}]]],["kol-button-group-wc",[[4,"kol-button-group-wc",{"state":[32]}]]],["kol-icon",[[33,"kol-icon",{"_ariaLabel":[1,"_aria-label"],"_icon":[1],"_label":[1],"_part":[1],"state":[32]}]]],["kol-icon-icofont",[[0,"kol-icon-icofont",{"_ariaLabel":[1,"_aria-label"],"_icon":[1],"_part":[1]}]]],["kol-symbol",[[0,"kol-symbol",{"_ariaLabel":[1,"_aria-label"],"_label":[1],"_symbol":[1],"state":[32]}]]],["kol-span-wc",[[4,"kol-span-wc",{"_hideLabel":[4,"_hide-label"],"_icon":[1],"_iconOnly":[4,"_icon-only"],"_label":[8],"state":[32]}]]],["kol-tooltip",[[0,"kol-tooltip",{"_align":[1],"_id":[1],"_label":[1],"state":[32]}]]],["kol-button-wc_2",[[4,"kol-heading-wc",{"_label":[8],"_level":[2],"_secondaryHeadline":[1,"_secondary-headline"],"state":[32]}],[4,"kol-button-wc",{"_accessKey":[1,"_access-key"],"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[4,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[4,"_aria-selected"],"_customClass":[1,"_custom-class"],"_disabled":[4],"_hideLabel":[4,"_hide-label"],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[4,"_icon-only"],"_id":[1],"_label":[8],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_type":[1],"_value":[16],"_variant":[1],"state":[32]}]]],["kol-pagination",[[33,"kol-pagination",{"_boundaryCount":[2,"_boundary-count"],"_customClass":[1,"_custom-class"],"_hasButtons":[8,"_has-buttons"],"_page":[2],"_pageSize":[1026,"_page-size"],"_pageSizeOptions":[1,"_page-size-options"],"_on":[16],"_siblingCount":[2,"_sibling-count"],"_tooltipAlign":[1,"_tooltip-align"],"_total":[2],"_variant":[1],"state":[32]}]]],["kol-input-radio",[[33,"kol-input-radio",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_disabled":[4],"_error":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_id":[1],"_label":[8],"_list":[1],"_name":[1],"_on":[16],"_orientation":[1],"_required":[4],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[8],"state":[32]}]]],["kol-button-link-text-switch",[[0,"kol-button-link-text-switch",{"_ariaCurrentValue":[8,"_aria-current-value"],"_hasChildren":[4,"_has-children"],"_link":[16],"_hideLabel":[4,"_hide-label"],"_selected":[4]}]]],["kol-badge",[[33,"kol-badge",{"_color":[1],"_hideLabel":[4,"_hide-label"],"_icon":[1],"_iconOnly":[4,"_icon-only"],"_label":[1],"_smartButton":[1,"_smart-button"],"state":[32]}]]],["kol-select",[[33,"kol-select",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_disabled":[4],"_error":[1],"_height":[1],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_label":[8],"_list":[1],"_multiple":[4],"_name":[1],"_on":[16],"_required":[4],"_size":[2],"_syncValueBySelector":[1,"_sync-value-by-selector"],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_touched":[1540],"_value":[1025],"state":[32]}]]],["kol-indented-text",[[33,"kol-indented-text",{"state":[32]}]]],["kol-button",[[33,"kol-button",{"_accessKey":[1,"_access-key"],"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[4,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[4,"_aria-selected"],"_customClass":[1,"_custom-class"],"_disabled":[4],"_hideLabel":[4,"_hide-label"],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[4,"_icon-only"],"_id":[1],"_label":[8],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_type":[1],"_value":[16],"_variant":[1]}]]],["kol-link-wc",[[4,"kol-link-wc",{"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[4,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[4,"_aria-selected"],"_disabled":[4],"_download":[8],"_hideLabel":[4,"_hide-label"],"_href":[1],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[4,"_icon-only"],"_label":[8],"_on":[16],"_role":[1],"_selector":[1],"_stealth":[4],"_tabIndex":[2,"_tab-index"],"_target":[1],"_targetDescription":[1,"_target-description"],"_tooltipAlign":[1,"_tooltip-align"],"_useCase":[1,"_use-case"],"state":[32]}]]],["kol-link",[[33,"kol-link",{"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[4,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[4,"_aria-selected"],"_disabled":[4],"_download":[8],"_hideLabel":[4,"_hide-label"],"_href":[1],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[4,"_icon-only"],"_label":[8],"_on":[16],"_role":[1],"_selector":[1],"_stealth":[4],"_tabIndex":[2,"_tab-index"],"_target":[1],"_targetDescription":[1,"_target-description"],"_tooltipAlign":[1,"_tooltip-align"],"_useCase":[1,"_use-case"]}]]],["kol-alert",[[33,"kol-alert",{"_alert":[4],"_hasCloser":[4,"_has-closer"],"_heading":[1],"_level":[2],"_on":[16],"_type":[1],"_variant":[1],"state":[32]}]]],["kol-alert-wc_2",[[4,"kol-input",{"_alert":[4],"_currentLength":[2,"_current-length"],"_disabled":[4],"_error":[1],"_hasCounter":[4,"_has-counter"],"_hideLabel":[4,"_hide-label"],"_hint":[1],"_icon":[16],"_id":[1],"_list":[1],"_maxLength":[2,"_max-length"],"_readOnly":[4,"_read-only"],"_renderNoLabel":[4,"_render-no-label"],"_required":[4],"_slotName":[1,"_slot-name"],"_smartButton":[16],"_touched":[4]}],[4,"kol-alert-wc",{"_alert":[4],"_hasCloser":[4,"_has-closer"],"_heading":[1],"_level":[2],"_on":[16],"_type":[1],"_variant":[1],"state":[32]}]]]]'),e))));
@@ -0,0 +1,4 @@
1
+ /*!
2
+ * KoliBri - The accessible HTML-Standard
3
+ */
4
+ import{a as t,u as o}from"./a11y.tipps-9f948961.js";import{a}from"./prop.validators-601f1068.js";const e=/[a-zA-Z0-9äöüÄÖÜß]/g,s=/^\d+$/;function n(t){var o;return"string"==typeof t&&(null===(o=t.match(e))||void 0===o?void 0:o.length)||0}function r(t,e=1){return n(t)>=e}function i(t){return s.test(t)}function l(e){var a;return{hooks:{afterPatch:(a,n,s,l)=>{var f,c;"function"==typeof(null===(f=e.hooks)||void 0===f?void 0:f.afterPatch)&&(null===(c=e.hooks)||void 0===c||c.afterPatch(a,n,s,l)),"string"==typeof a&&!1===r(a,3)&&!1===i(a)&&t(`The heading or label ("${a}") is not accessible. A label should consist of at least three readable characters.`),"string"==typeof a&&a.length>80&&o("A heading or label should not be longer than 80 characters.")},beforePatch:null===(a=e.hooks)||void 0===a?void 0:a.beforePatch}}}const f=new Set(["string"]),c=(t,e,o={})=>{a(t,"_label",(t=>"string"==typeof t),f,e,l(o))},u=new Set(["string","false"]),d=(t,e,o={})=>{""!==e&&"false"!==e||(e=!1),a(t,"_label",(t=>!1===t||"string"==typeof t),u,e,l(o))};export{d as a,i as c,r as h,c as v};
@@ -1 +1 @@
1
- {"version":3,"names":["READABLE_CHARS","ONLY_NUMBERS","countReadableChars","str","_a","match","length","hasEnoughReadableChars","min","containsOnlyNumbers","test","getValidationOptions","options","hooks","afterPatch","value","state","component","key","_b","a11yHint","uiUxHint","beforePatch","LABEL_VALUES","Set","validateLabel","watchValidator","LABEL_WITH_EXPERT_SLOT_VALUES","validateLabelWithExpertSlot"],"sources":["src/types/props/label.ts"],"sourcesContent":["import { Generic } from '@a11y-ui/core';\n\nimport { a11yHint, uiUxHint } from '../../utils/a11y.tipps';\nimport { WatchStringOptions, watchValidator } from '../../utils/prop.validators';\n\n/* types */\n\n/**\n * This is a regular expression that matches all readable characters.\n *\n * Interesting: https://stackoverflow.com/questions/150033/regular-expression-to-match-non-english-characters\n */\nconst READABLE_CHARS = /[a-zA-Z0-9äöüÄÖÜß]/g;\n\n/**\n * This is a regular expression that matches only numbers.\n */\nconst ONLY_NUMBERS = /^\\d+$/;\n\n/**\n * This function counts the number of readable characters in a string.\n * @param str The string to count.\n * @returns The number of readable characters in the string.\n */\nfunction countReadableChars(str: string): number {\n\treturn typeof str === 'string' ? str.match(READABLE_CHARS)?.length || 0 : 0;\n}\n\n/**\n * This function checks if a string has at least a certain number of readable characters.\n * @param str The string to check.\n * @param min The minimum number of readable characters.\n * @returns True if the string has at least the minimum number of readable characters, false otherwise.\n */\nexport function hasEnoughReadableChars(str: string, min = 1): boolean {\n\treturn countReadableChars(str) >= min;\n}\n\n/**\n * This function checks if a string contains only numbers.\n * @param str The string to check.\n * @returns True if the string contains only numbers, false otherwise.\n */\nexport function containsOnlyNumbers(str: string): boolean {\n\treturn ONLY_NUMBERS.test(str);\n}\n\n/**\n * Defines the type of the label property.\n */\nexport type LabelPropType = string;\n\n/**\n * Defines the type of the label with expert-slot toggle property.\n */\nexport type LabelWithExpertSlotPropType = LabelPropType | false;\n\n/**\n * The label property is used to label different elements:\n * - abbr -> title text\n * - button -> label text\n * - heading -> headline text\n * - input, select and textarea -> label text\n * - summary -> summary text\n * - quote, table -> caption text\n * - version -> version text\n * - etc.\n *\n * The label is often a mandatory attribute. If the value of the label is false,\n * the expert-slot will be used. Otherwise, the value of the label must be a string\n * and the expert-slot will be ignored.\n */\nexport type PropLabel = {\n\tlabel: LabelPropType;\n};\nexport type PropLabelWithExpertSlot = {\n\tlabel: LabelWithExpertSlotPropType;\n};\n\nexport type LabelProp = Generic.Element.Members<PropLabel, unknown>;\n// type LabelWithExpertSlotProp = Generic.Element.Members<PropLabelWithExpertSlot, unknown>;\n\nfunction getValidationOptions(options: WatchStringOptions): WatchStringOptions {\n\treturn {\n\t\thooks: {\n\t\t\tafterPatch: (value, state, component, key) => {\n\t\t\t\tif (typeof options.hooks?.afterPatch === 'function') {\n\t\t\t\t\toptions.hooks?.afterPatch(value, state, component, key);\n\t\t\t\t}\n\t\t\t\tif (typeof value === 'string' && hasEnoughReadableChars(value, 3) === false && containsOnlyNumbers(value) === false) {\n\t\t\t\t\ta11yHint(`The heading or label (\"${value}\") is not accessible. A label should consist of at least three readable characters.`);\n\t\t\t\t}\n\t\t\t\tif (typeof value === 'string' && value.length > 80) {\n\t\t\t\t\tuiUxHint(`A heading or label should not be longer than 80 characters.`);\n\t\t\t\t}\n\t\t\t},\n\t\t\tbeforePatch: options.hooks?.beforePatch,\n\t\t},\n\t};\n}\n\nconst LABEL_VALUES = new Set(['string']);\nexport const validateLabel = (component: Generic.Element.Component, value?: LabelPropType, options: WatchStringOptions = {}): void => {\n\twatchValidator(component, '_label', (value) => typeof value === 'string', LABEL_VALUES, value, getValidationOptions(options));\n};\n\nconst LABEL_WITH_EXPERT_SLOT_VALUES = new Set(['string', 'false']);\nexport const validateLabelWithExpertSlot = (\n\tcomponent: Generic.Element.Component,\n\tvalue?: LabelWithExpertSlotPropType,\n\toptions: WatchStringOptions = {}\n): void => {\n\tif (value === '' || value === 'false') {\n\t\tvalue = false; // TODO: remove this workaround in v2\n\t}\n\twatchValidator(\n\t\tcomponent,\n\t\t'_label',\n\t\t(value) => value === false || typeof value === 'string',\n\t\tLABEL_WITH_EXPERT_SLOT_VALUES,\n\t\tvalue,\n\t\tgetValidationOptions(options)\n\t);\n};\n\n// TODO: Validation for labelWithExpertSlot\n"],"mappings":";;;sGAYA,MAAMA,EAAiB,sBAKvB,MAAMC,EAAe,QAOrB,SAASC,EAAmBC,G,MAC3B,cAAcA,IAAQ,WAAWC,EAAAD,EAAIE,MAAML,MAAe,MAAAI,SAAA,SAAAA,EAAEE,SAAU,EAAI,CAC3E,C,SAQgBC,EAAuBJ,EAAaK,EAAM,GACzD,OAAON,EAAmBC,IAAQK,CACnC,C,SAOgBC,EAAoBN,GACnC,OAAOF,EAAaS,KAAKP,EAC1B,CAqCA,SAASQ,EAAqBC,G,MAC7B,MAAO,CACNC,MAAO,CACNC,WAAY,CAACC,EAAOC,EAAOC,EAAWC,K,QACrC,WAAWd,EAAAQ,EAAQC,SAAK,MAAAT,SAAA,SAAAA,EAAEU,cAAe,WAAY,EACpDK,EAAAP,EAAQC,SAAK,MAAAM,SAAA,SAAAA,EAAEL,WAAWC,EAAOC,EAAOC,EAAWC,E,CAEpD,UAAWH,IAAU,UAAYR,EAAuBQ,EAAO,KAAO,OAASN,EAAoBM,KAAW,MAAO,CACpHK,EAAS,0BAA0BL,uF,CAEpC,UAAWA,IAAU,UAAYA,EAAMT,OAAS,GAAI,CACnDe,EAAS,8D,GAGXC,aAAalB,EAAAQ,EAAQC,SAAK,MAAAT,SAAA,SAAAA,EAAEkB,aAG/B,CAEA,MAAMC,EAAe,IAAIC,IAAI,CAAC,W,MACjBC,EAAgB,CAACR,EAAsCF,EAAuBH,EAA8B,MACxHc,EAAeT,EAAW,UAAWF,UAAiBA,IAAU,UAAUQ,EAAcR,EAAOJ,EAAqBC,GAAS,EAG9H,MAAMe,EAAgC,IAAIH,IAAI,CAAC,SAAU,U,MAC5CI,EAA8B,CAC1CX,EACAF,EACAH,EAA8B,MAE9B,GAAIG,IAAU,IAAMA,IAAU,QAAS,CACtCA,EAAQ,K,CAETW,EACCT,EACA,UACCF,GAAUA,IAAU,cAAgBA,IAAU,UAC/CY,EACAZ,EACAJ,EAAqBC,GACrB,S"}
1
+ {"version":3,"names":["READABLE_CHARS","ONLY_NUMBERS","countReadableChars","str","_a","match","length","hasEnoughReadableChars","min","containsOnlyNumbers","test","getValidationOptions","options","hooks","afterPatch","value","state","component","key","_b","a11yHint","uiUxHint","beforePatch","LABEL_VALUES","Set","validateLabel","watchValidator","LABEL_WITH_EXPERT_SLOT_VALUES","validateLabelWithExpertSlot"],"sources":["src/types/props/label.ts"],"sourcesContent":["import { Generic } from '@a11y-ui/core';\n\nimport { a11yHint, uiUxHint } from '../../utils/a11y.tipps';\nimport { WatchStringOptions, watchValidator } from '../../utils/prop.validators';\n\n/* types */\n\n/**\n * This is a regular expression that matches all readable characters.\n *\n * Interesting: https://stackoverflow.com/questions/150033/regular-expression-to-match-non-english-characters\n */\nconst READABLE_CHARS = /[a-zA-Z0-9äöüÄÖÜß]/g;\n\n/**\n * This is a regular expression that matches only numbers.\n */\nconst ONLY_NUMBERS = /^\\d+$/;\n\n/**\n * This function counts the number of readable characters in a string.\n * @param str The string to count.\n * @returns The number of readable characters in the string.\n */\nfunction countReadableChars(str: string): number {\n\treturn typeof str === 'string' ? str.match(READABLE_CHARS)?.length || 0 : 0;\n}\n\n/**\n * This function checks if a string has at least a certain number of readable characters.\n * @param str The string to check.\n * @param min The minimum number of readable characters.\n * @returns True if the string has at least the minimum number of readable characters, false otherwise.\n */\nexport function hasEnoughReadableChars(str: string, min = 1): boolean {\n\treturn countReadableChars(str) >= min;\n}\n\n/**\n * This function checks if a string contains only numbers.\n * @param str The string to check.\n * @returns True if the string contains only numbers, false otherwise.\n */\nexport function containsOnlyNumbers(str: string): boolean {\n\treturn ONLY_NUMBERS.test(str);\n}\n\n/**\n * Defines the type of the label property.\n */\nexport type LabelPropType = string;\n\n/**\n * Defines the type of the label with expert-slot toggle property.\n */\nexport type LabelWithExpertSlotPropType = LabelPropType | false;\n\n/**\n * The label property is used to label different elements:\n * - abbr -> title text\n * - button -> label text\n * - heading -> headline text\n * - input, select and textarea -> label text\n * - summary -> summary text\n * - quote, table -> caption text\n * - version -> version text\n * - etc.\n *\n * The label is often a mandatory attribute. If the value of the label is false,\n * the expert-slot will be used. Otherwise, the value of the label must be a string\n * and the expert-slot will be ignored.\n */\nexport type PropLabel = {\n\tlabel: LabelPropType;\n};\nexport type PropLabelWithExpertSlot = {\n\tlabel: LabelWithExpertSlotPropType;\n};\n\nexport type LabelProp = Generic.Element.Members<PropLabel, unknown>;\n// type LabelWithExpertSlotProp = Generic.Element.Members<PropLabelWithExpertSlot, unknown>;\n\nfunction getValidationOptions(options: WatchStringOptions): WatchStringOptions {\n\treturn {\n\t\thooks: {\n\t\t\tafterPatch: (value, state, component, key) => {\n\t\t\t\tif (typeof options.hooks?.afterPatch === 'function') {\n\t\t\t\t\toptions.hooks?.afterPatch(value, state, component, key);\n\t\t\t\t}\n\t\t\t\tif (typeof value === 'string' && hasEnoughReadableChars(value, 3) === false && containsOnlyNumbers(value) === false) {\n\t\t\t\t\ta11yHint(`The heading or label (\"${value}\") is not accessible. A label should consist of at least three readable characters.`);\n\t\t\t\t}\n\t\t\t\tif (typeof value === 'string' && value.length > 80) {\n\t\t\t\t\tuiUxHint(`A heading or label should not be longer than 80 characters.`);\n\t\t\t\t}\n\t\t\t},\n\t\t\tbeforePatch: options.hooks?.beforePatch,\n\t\t},\n\t};\n}\n\nconst LABEL_VALUES = new Set(['string']);\nexport const validateLabel = (component: Generic.Element.Component, value?: LabelPropType, options: WatchStringOptions = {}): void => {\n\twatchValidator(component, '_label', (value) => typeof value === 'string', LABEL_VALUES, value, getValidationOptions(options));\n};\n\nconst LABEL_WITH_EXPERT_SLOT_VALUES = new Set(['string', 'false']);\nexport const validateLabelWithExpertSlot = (\n\tcomponent: Generic.Element.Component,\n\tvalue?: LabelWithExpertSlotPropType,\n\toptions: WatchStringOptions = {}\n): void => {\n\tif (value === '' || value === 'false') {\n\t\tvalue = false; // TODO: remove this workaround in v2\n\t}\n\twatchValidator(\n\t\tcomponent,\n\t\t'_label',\n\t\t(value) => value === false || typeof value === 'string',\n\t\tLABEL_WITH_EXPERT_SLOT_VALUES,\n\t\tvalue,\n\t\tgetValidationOptions(options)\n\t);\n};\n\n// TODO: Validation for labelWithExpertSlot\n"],"mappings":";;;iGAYA,MAAMA,EAAiB,sBAKvB,MAAMC,EAAe,QAOrB,SAASC,EAAmBC,G,MAC3B,cAAcA,IAAQ,WAAWC,EAAAD,EAAIE,MAAML,MAAe,MAAAI,SAAA,SAAAA,EAAEE,SAAU,EAAI,CAC3E,C,SAQgBC,EAAuBJ,EAAaK,EAAM,GACzD,OAAON,EAAmBC,IAAQK,CACnC,C,SAOgBC,EAAoBN,GACnC,OAAOF,EAAaS,KAAKP,EAC1B,CAqCA,SAASQ,EAAqBC,G,MAC7B,MAAO,CACNC,MAAO,CACNC,WAAY,CAACC,EAAOC,EAAOC,EAAWC,K,QACrC,WAAWd,EAAAQ,EAAQC,SAAK,MAAAT,SAAA,SAAAA,EAAEU,cAAe,WAAY,EACpDK,EAAAP,EAAQC,SAAK,MAAAM,SAAA,SAAAA,EAAEL,WAAWC,EAAOC,EAAOC,EAAWC,E,CAEpD,UAAWH,IAAU,UAAYR,EAAuBQ,EAAO,KAAO,OAASN,EAAoBM,KAAW,MAAO,CACpHK,EAAS,0BAA0BL,uF,CAEpC,UAAWA,IAAU,UAAYA,EAAMT,OAAS,GAAI,CACnDe,EAAS,8D,GAGXC,aAAalB,EAAAQ,EAAQC,SAAK,MAAAT,SAAA,SAAAA,EAAEkB,aAG/B,CAEA,MAAMC,EAAe,IAAIC,IAAI,CAAC,W,MACjBC,EAAgB,CAACR,EAAsCF,EAAuBH,EAA8B,MACxHc,EAAeT,EAAW,UAAWF,UAAiBA,IAAU,UAAUQ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