@public-ui/components 3.0.7-rc.0 → 4.0.0-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (494) hide show
  1. package/custom-elements.json +1 -1
  2. package/dist/cjs/{Alert-pYM9xL1B.js → Alert-DDA66DVu.js} +1 -1
  3. package/dist/cjs/Alert-DDA66DVu.js.map +1 -0
  4. package/dist/cjs/{Collapsible-CEcUGOI1.js → Collapsible-IhYdCplx.js} +1 -1
  5. package/dist/cjs/{Collapsible-CEcUGOI1.js.map → Collapsible-IhYdCplx.js.map} +1 -1
  6. package/dist/cjs/{CustomSuggestionsToggle-CPk5IOdw.js → CustomSuggestionsToggle-CeGKydyw.js} +1 -1
  7. package/dist/cjs/{CustomSuggestionsToggle-CPk5IOdw.js.map → CustomSuggestionsToggle-CeGKydyw.js.map} +1 -1
  8. package/dist/cjs/FieldControlStateWrapper-DPxapC_D.js +4 -0
  9. package/dist/cjs/FieldControlStateWrapper-DPxapC_D.js.map +1 -0
  10. package/dist/cjs/FormFieldStateWrapper-C2VTSu-i.js +4 -0
  11. package/dist/cjs/FormFieldStateWrapper-C2VTSu-i.js.map +1 -0
  12. package/dist/cjs/{Heading-CPcp0Wr1.js → Heading-DJ48CpuI.js} +1 -1
  13. package/dist/cjs/{Heading-CPcp0Wr1.js.map → Heading-DJ48CpuI.js.map} +1 -1
  14. package/dist/cjs/{Icon-B8rPDYT-.js → Icon-D6G0_09j.js} +1 -1
  15. package/dist/cjs/{Icon-B8rPDYT-.js.map → Icon-D6G0_09j.js.map} +1 -1
  16. package/dist/cjs/Input-BRmqCQyF.js +4 -0
  17. package/dist/cjs/{Input-CMtYrIiX.js.map → Input-BRmqCQyF.js.map} +1 -1
  18. package/dist/cjs/{InputStateWrapper-CyxEYc7X.js → InputStateWrapper-BBi90S8D.js} +1 -1
  19. package/dist/cjs/{InputStateWrapper-CyxEYc7X.js.map → InputStateWrapper-BBi90S8D.js.map} +1 -1
  20. package/dist/cjs/{InternalUnderlinedBadgeText-6WeC6ukm.js → InternalUnderlinedBadgeText-D0tClEJo.js} +1 -1
  21. package/dist/cjs/{InternalUnderlinedBadgeText-6WeC6ukm.js.map → InternalUnderlinedBadgeText-D0tClEJo.js.map} +1 -1
  22. package/dist/cjs/{Span-CSTnGgMo.js → Span-BZT0Xgoj.js} +1 -1
  23. package/dist/cjs/{Span-CSTnGgMo.js.map → Span-BZT0Xgoj.js.map} +1 -1
  24. package/dist/cjs/{app-globals-EBS1Rxmp.js → app-globals-CprMO-cF.js} +1 -1
  25. package/dist/cjs/{app-globals-EBS1Rxmp.js.map → app-globals-CprMO-cF.js.map} +1 -1
  26. package/dist/cjs/{controller-p8a-m8p9.js → controller-BY1lNpWb.js} +1 -1
  27. package/dist/cjs/{controller-p8a-m8p9.js.map → controller-BY1lNpWb.js.map} +1 -1
  28. package/dist/cjs/{controller-h186ZoKi.js → controller-C36y36pM.js} +1 -1
  29. package/dist/cjs/{controller-h186ZoKi.js.map → controller-C36y36pM.js.map} +1 -1
  30. package/dist/cjs/{controller-dziW0eTQ.js → controller-CygpdBUj.js} +1 -1
  31. package/dist/cjs/{controller-dziW0eTQ.js.map → controller-CygpdBUj.js.map} +1 -1
  32. package/dist/cjs/{controller-icon-flui-j3P.js → controller-icon-CdU193q2.js} +1 -1
  33. package/dist/cjs/{controller-icon-flui-j3P.js.map → controller-icon-CdU193q2.js.map} +1 -1
  34. package/dist/cjs/{dev.utils-NQv4Or1w.js → dev.utils-BMH6oSjV.js} +1 -1
  35. package/dist/cjs/{dev.utils-NQv4Or1w.js.map → dev.utils-BMH6oSjV.js.map} +1 -1
  36. package/dist/cjs/{devtools-DJ5Gsvbm.js → devtools-BI89G7wy.js} +1 -1
  37. package/dist/cjs/{devtools-DJ5Gsvbm.js.map → devtools-BI89G7wy.js.map} +1 -1
  38. package/dist/cjs/index-DBmXlvaP.js +4 -0
  39. package/dist/cjs/index-DBmXlvaP.js.map +1 -0
  40. package/dist/cjs/index.cjs.js +1 -1
  41. package/dist/cjs/index.cjs.js.map +1 -1
  42. package/dist/cjs/kol-abbr.cjs.entry.js +1 -1
  43. package/dist/cjs/kol-accordion.cjs.entry.js +1 -1
  44. package/dist/cjs/kol-alert-wc.cjs.entry.js +1 -1
  45. package/dist/cjs/kol-alert.cjs.entry.js +1 -1
  46. package/dist/cjs/kol-avatar-wc.cjs.entry.js +1 -1
  47. package/dist/cjs/kol-avatar.cjs.entry.js +1 -1
  48. package/dist/cjs/kol-badge.cjs.entry.js +1 -1
  49. package/dist/cjs/kol-breadcrumb.cjs.entry.js +1 -1
  50. package/dist/cjs/kol-breadcrumb.entry.cjs.js.map +1 -1
  51. package/dist/cjs/kol-button-link.cjs.entry.js +1 -1
  52. package/dist/cjs/kol-button-link.entry.cjs.js.map +1 -1
  53. package/dist/cjs/kol-button-wc.cjs.entry.js +1 -1
  54. package/dist/cjs/kol-button-wc.entry.cjs.js.map +1 -1
  55. package/dist/cjs/kol-button.cjs.entry.js +1 -1
  56. package/dist/cjs/kol-card-wc.cjs.entry.js +1 -1
  57. package/dist/cjs/kol-card.cjs.entry.js +1 -1
  58. package/dist/cjs/kol-combobox.cjs.entry.js +1 -1
  59. package/dist/cjs/kol-details.cjs.entry.js +1 -1
  60. package/dist/cjs/kol-drawer.cjs.entry.js +1 -1
  61. package/dist/cjs/kol-drawer.entry.cjs.js.map +1 -1
  62. package/dist/cjs/kol-form.cjs.entry.js +1 -1
  63. package/dist/cjs/kol-form.entry.cjs.js.map +1 -1
  64. package/dist/cjs/kol-heading.cjs.entry.js +1 -1
  65. package/dist/cjs/kol-icon.cjs.entry.js +1 -1
  66. package/dist/cjs/kol-icon.entry.cjs.js.map +1 -1
  67. package/dist/cjs/kol-image.cjs.entry.js +1 -1
  68. package/dist/cjs/kol-input-checkbox.cjs.entry.js +1 -1
  69. package/dist/cjs/kol-input-color.cjs.entry.js +1 -1
  70. package/dist/cjs/kol-input-date.cjs.entry.js +1 -1
  71. package/dist/cjs/kol-input-email.cjs.entry.js +1 -1
  72. package/dist/cjs/kol-input-file.cjs.entry.js +1 -1
  73. package/dist/cjs/kol-input-number.cjs.entry.js +1 -1
  74. package/dist/cjs/kol-input-password.cjs.entry.js +1 -1
  75. package/dist/cjs/kol-input-radio.cjs.entry.js +1 -1
  76. package/dist/cjs/kol-input-range.cjs.entry.js +1 -1
  77. package/dist/cjs/kol-input-text.cjs.entry.js +1 -1
  78. package/dist/cjs/kol-kolibri.cjs.entry.js +1 -1
  79. package/dist/cjs/kol-link-button.cjs.entry.js +1 -1
  80. package/dist/cjs/kol-link-wc.cjs.entry.js +1 -1
  81. package/dist/cjs/kol-link-wc.entry.cjs.js.map +1 -1
  82. package/dist/cjs/kol-link.cjs.entry.js +1 -1
  83. package/dist/cjs/kol-link.entry.cjs.js.map +1 -1
  84. package/dist/cjs/kol-modal.cjs.entry.js +1 -1
  85. package/dist/cjs/kol-modal.entry.cjs.js.map +1 -1
  86. package/dist/cjs/kol-nav.cjs.entry.js +1 -1
  87. package/dist/cjs/kol-nav.entry.cjs.js.map +1 -1
  88. package/dist/cjs/kol-pagination-wc.cjs.entry.js +1 -1
  89. package/dist/cjs/kol-pagination-wc.entry.cjs.js.map +1 -1
  90. package/dist/cjs/kol-pagination.cjs.entry.js +1 -1
  91. package/dist/cjs/kol-popover-button-wc.cjs.entry.js +1 -1
  92. package/dist/cjs/kol-popover-button.cjs.entry.js +1 -1
  93. package/dist/cjs/kol-popover-wc.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-single-select.cjs.entry.js +1 -1
  98. package/dist/cjs/kol-skip-nav.cjs.entry.js +1 -1
  99. package/dist/cjs/kol-spin.cjs.entry.js +1 -1
  100. package/dist/cjs/kol-split-button.cjs.entry.js +1 -1
  101. package/dist/cjs/kol-table-settings-wc.cjs.entry.js +1 -1
  102. package/dist/cjs/kol-table-stateful.cjs.entry.js +1 -1
  103. package/dist/cjs/kol-table-stateless-wc.cjs.entry.js +1 -1
  104. package/dist/cjs/kol-table-stateless.cjs.entry.js +1 -1
  105. package/dist/cjs/kol-tabs.cjs.entry.js +1 -1
  106. package/dist/cjs/kol-textarea.cjs.entry.js +1 -1
  107. package/dist/cjs/kol-toast-container.cjs.entry.js +1 -1
  108. package/dist/cjs/kol-toast-container.entry.cjs.js.map +1 -1
  109. package/dist/cjs/kol-toolbar.cjs.entry.js +1 -1
  110. package/dist/cjs/kol-tooltip-wc.cjs.entry.js +1 -1
  111. package/dist/cjs/kol-tooltip-wc.entry.cjs.js.map +1 -1
  112. package/dist/cjs/kol-tree-item-wc.cjs.entry.js +1 -1
  113. package/dist/cjs/kol-tree-item.cjs.entry.js +1 -1
  114. package/dist/cjs/kol-tree-wc.cjs.entry.js +1 -1
  115. package/dist/cjs/kol-tree.cjs.entry.js +1 -1
  116. package/dist/cjs/kol-version.cjs.entry.js +1 -1
  117. package/dist/cjs/kolibri.cjs.js +1 -1
  118. package/dist/cjs/loader.cjs.js +1 -1
  119. package/dist/cjs/test-component.cjs.entry.js +1 -1
  120. package/dist/cjs/tooltip-open-tracking-Ba0udJRU.js +4 -0
  121. package/dist/cjs/tooltip-open-tracking-Ba0udJRU.js.map +1 -0
  122. package/dist/components/Alert.js +1 -1
  123. package/dist/components/Alert.js.map +1 -1
  124. package/dist/components/FieldControlStateWrapper.js +1 -1
  125. package/dist/components/FieldControlStateWrapper.js.map +1 -1
  126. package/dist/components/controller2.js +1 -1
  127. package/dist/components/controller2.js.map +1 -1
  128. package/dist/components/index.js +1 -1
  129. package/dist/components/index.js.map +1 -1
  130. package/dist/components/kol-accordion.js +1 -1
  131. package/dist/components/kol-breadcrumb.js +1 -1
  132. package/dist/components/kol-breadcrumb.js.map +1 -1
  133. package/dist/components/kol-button-link.js +1 -1
  134. package/dist/components/kol-button-link.js.map +1 -1
  135. package/dist/components/kol-button-wc.js +1 -1
  136. package/dist/components/kol-button-wc.js.map +1 -1
  137. package/dist/components/kol-card-wc.js +1 -1
  138. package/dist/components/kol-card.js +1 -1
  139. package/dist/components/kol-combobox.js +1 -1
  140. package/dist/components/kol-details.js +1 -1
  141. package/dist/components/kol-drawer.js +1 -1
  142. package/dist/components/kol-drawer.js.map +1 -1
  143. package/dist/components/kol-form.js +1 -1
  144. package/dist/components/kol-form.js.map +1 -1
  145. package/dist/components/kol-heading.js +1 -1
  146. package/dist/components/kol-icon.js +1 -1
  147. package/dist/components/kol-icon.js.map +1 -1
  148. package/dist/components/kol-image.js +1 -1
  149. package/dist/components/kol-input-checkbox.js +1 -1
  150. package/dist/components/kol-input-color.js +1 -1
  151. package/dist/components/kol-input-date.js +1 -1
  152. package/dist/components/kol-input-email.js +1 -1
  153. package/dist/components/kol-input-file.js +1 -1
  154. package/dist/components/kol-input-number.js +1 -1
  155. package/dist/components/kol-input-password.js +1 -1
  156. package/dist/components/kol-input-radio.js +1 -1
  157. package/dist/components/kol-input-range.js +1 -1
  158. package/dist/components/kol-input-text.js +1 -1
  159. package/dist/components/kol-kolibri.js +1 -1
  160. package/dist/components/kol-link-button.js +1 -1
  161. package/dist/components/kol-link-wc.js +1 -1
  162. package/dist/components/kol-link-wc.js.map +1 -1
  163. package/dist/components/kol-link.js +1 -1
  164. package/dist/components/kol-link.js.map +1 -1
  165. package/dist/components/kol-modal.js +1 -1
  166. package/dist/components/kol-modal.js.map +1 -1
  167. package/dist/components/kol-nav.js +1 -1
  168. package/dist/components/kol-nav.js.map +1 -1
  169. package/dist/components/kol-pagination-wc.js +1 -1
  170. package/dist/components/kol-pagination-wc.js.map +1 -1
  171. package/dist/components/kol-pagination.js +1 -1
  172. package/dist/components/kol-popover-button-wc.js +1 -1
  173. package/dist/components/kol-popover-button.js +1 -1
  174. package/dist/components/kol-popover-wc.js +1 -1
  175. package/dist/components/kol-progress.js +1 -1
  176. package/dist/components/kol-quote.js +1 -1
  177. package/dist/components/kol-select.js +1 -1
  178. package/dist/components/kol-single-select.js +1 -1
  179. package/dist/components/kol-skip-nav.js +1 -1
  180. package/dist/components/kol-spin.js +1 -1
  181. package/dist/components/kol-split-button.js +1 -1
  182. package/dist/components/kol-table-settings-wc.js +1 -1
  183. package/dist/components/kol-table-stateful.js +1 -1
  184. package/dist/components/kol-table-stateless-wc.js +1 -1
  185. package/dist/components/kol-table-stateless.js +1 -1
  186. package/dist/components/kol-tabs.js +1 -1
  187. package/dist/components/kol-textarea.js +1 -1
  188. package/dist/components/kol-toast-container.js +1 -1
  189. package/dist/components/kol-toast-container.js.map +1 -1
  190. package/dist/components/kol-toolbar.js +1 -1
  191. package/dist/components/kol-tooltip-wc.js +1 -1
  192. package/dist/components/kol-tooltip-wc.js.map +1 -1
  193. package/dist/components/kol-tree-item-wc.js +1 -1
  194. package/dist/components/kol-tree-item.js +1 -1
  195. package/dist/components/kol-tree-wc.js +1 -1
  196. package/dist/components/kol-tree.js +1 -1
  197. package/dist/components/kol-version.js +1 -1
  198. package/dist/components/tooltip-open-tracking.js +4 -0
  199. package/dist/components/tooltip-open-tracking.js.map +1 -0
  200. package/dist/esm/{Alert-qJPuIv8b.js → Alert-yh8R3coC.js} +1 -1
  201. package/dist/esm/Alert-yh8R3coC.js.map +1 -0
  202. package/dist/esm/{Collapsible-VwOBRTg-.js → Collapsible-DMNJjdc3.js} +1 -1
  203. package/dist/esm/{Collapsible-VwOBRTg-.js.map → Collapsible-DMNJjdc3.js.map} +1 -1
  204. package/dist/esm/{CustomSuggestionsToggle-BtYSYCn5.js → CustomSuggestionsToggle-_i-9Z6oo.js} +1 -1
  205. package/dist/{kolibri/CustomSuggestionsToggle-BtYSYCn5.js.map → esm/CustomSuggestionsToggle-_i-9Z6oo.js.map} +1 -1
  206. package/dist/esm/FieldControlStateWrapper-DxTxYvO0.js +4 -0
  207. package/dist/esm/FieldControlStateWrapper-DxTxYvO0.js.map +1 -0
  208. package/dist/esm/FormFieldStateWrapper-DRcnPo2o.js +4 -0
  209. package/dist/esm/FormFieldStateWrapper-DRcnPo2o.js.map +1 -0
  210. package/dist/esm/{Heading-CMd-jtC1.js → Heading-KhwFHPZb.js} +1 -1
  211. package/dist/{kolibri/Heading-CMd-jtC1.js.map → esm/Heading-KhwFHPZb.js.map} +1 -1
  212. package/dist/esm/Icon-BsRmEtCa.js +4 -0
  213. package/dist/esm/{Icon-BQRZwXjg.js.map → Icon-BsRmEtCa.js.map} +1 -1
  214. package/dist/esm/Input-BxElrU0N.js +4 -0
  215. package/dist/esm/{Input-BQNyXbdV.js.map → Input-BxElrU0N.js.map} +1 -1
  216. package/dist/esm/{InputStateWrapper-5DGko7Ry.js → InputStateWrapper-GJbSTDc8.js} +1 -1
  217. package/dist/esm/{InputStateWrapper-5DGko7Ry.js.map → InputStateWrapper-GJbSTDc8.js.map} +1 -1
  218. package/dist/esm/InternalUnderlinedBadgeText-BnPUgbKl.js +4 -0
  219. package/dist/esm/{InternalUnderlinedBadgeText-DeV9AANw.js.map → InternalUnderlinedBadgeText-BnPUgbKl.js.map} +1 -1
  220. package/dist/esm/{Span-9Jbefwfo.js → Span-5ZR0JDnP.js} +1 -1
  221. package/dist/esm/{Span-9Jbefwfo.js.map → Span-5ZR0JDnP.js.map} +1 -1
  222. package/dist/esm/{app-globals-BV7c4MN_.js → app-globals-COkPg4hl.js} +1 -1
  223. package/dist/esm/{app-globals-BV7c4MN_.js.map → app-globals-COkPg4hl.js.map} +1 -1
  224. package/dist/esm/{controller-BMZRH6Si.js → controller-BiC2tpL8.js} +1 -1
  225. package/dist/esm/{controller-BMZRH6Si.js.map → controller-BiC2tpL8.js.map} +1 -1
  226. package/dist/esm/{controller-C7skty3T.js → controller-CeGWU1Au.js} +1 -1
  227. package/dist/{kolibri/controller-C7skty3T.js.map → esm/controller-CeGWU1Au.js.map} +1 -1
  228. package/dist/esm/{controller-B_Bwl5E9.js → controller-HR9pimff.js} +1 -1
  229. package/dist/esm/{controller-B_Bwl5E9.js.map → controller-HR9pimff.js.map} +1 -1
  230. package/dist/esm/{controller-icon-DcftMfhw.js → controller-icon-DN63N3Rm.js} +1 -1
  231. package/dist/esm/{controller-icon-DcftMfhw.js.map → controller-icon-DN63N3Rm.js.map} +1 -1
  232. package/dist/esm/{dev.utils-D2H-D7vZ.js → dev.utils-0SH3ep_K.js} +1 -1
  233. package/dist/esm/{dev.utils-D2H-D7vZ.js.map → dev.utils-0SH3ep_K.js.map} +1 -1
  234. package/dist/esm/{devtools-Bv4R5yuw.js → devtools-Cg1RmbyV.js} +1 -1
  235. package/dist/esm/{devtools-Bv4R5yuw.js.map → devtools-Cg1RmbyV.js.map} +1 -1
  236. package/dist/esm/index-Dina3aff.js +4 -0
  237. package/dist/esm/index-Dina3aff.js.map +1 -0
  238. package/dist/esm/index.js +1 -1
  239. package/dist/esm/index.js.map +1 -1
  240. package/dist/esm/kol-abbr.entry.js +1 -1
  241. package/dist/esm/kol-accordion.entry.js +1 -1
  242. package/dist/esm/kol-alert-wc.entry.js +1 -1
  243. package/dist/esm/kol-alert.entry.js +1 -1
  244. package/dist/esm/kol-avatar-wc.entry.js +1 -1
  245. package/dist/esm/kol-avatar.entry.js +1 -1
  246. package/dist/esm/kol-badge.entry.js +1 -1
  247. package/dist/esm/kol-breadcrumb.entry.js +1 -1
  248. package/dist/esm/kol-breadcrumb.entry.js.map +1 -1
  249. package/dist/esm/kol-button-link.entry.js +1 -1
  250. package/dist/esm/kol-button-link.entry.js.map +1 -1
  251. package/dist/esm/kol-button-wc.entry.js +1 -1
  252. package/dist/esm/kol-button-wc.entry.js.map +1 -1
  253. package/dist/esm/kol-button.entry.js +1 -1
  254. package/dist/esm/kol-card-wc.entry.js +1 -1
  255. package/dist/esm/kol-card.entry.js +1 -1
  256. package/dist/esm/kol-combobox.entry.js +1 -1
  257. package/dist/esm/kol-details.entry.js +1 -1
  258. package/dist/esm/kol-drawer.entry.js +1 -1
  259. package/dist/esm/kol-drawer.entry.js.map +1 -1
  260. package/dist/esm/kol-form.entry.js +1 -1
  261. package/dist/esm/kol-form.entry.js.map +1 -1
  262. package/dist/esm/kol-heading.entry.js +1 -1
  263. package/dist/esm/kol-icon.entry.js +1 -1
  264. package/dist/esm/kol-icon.entry.js.map +1 -1
  265. package/dist/esm/kol-image.entry.js +1 -1
  266. package/dist/esm/kol-input-checkbox.entry.js +1 -1
  267. package/dist/esm/kol-input-color.entry.js +1 -1
  268. package/dist/esm/kol-input-date.entry.js +1 -1
  269. package/dist/esm/kol-input-email.entry.js +1 -1
  270. package/dist/esm/kol-input-file.entry.js +1 -1
  271. package/dist/esm/kol-input-number.entry.js +1 -1
  272. package/dist/esm/kol-input-password.entry.js +1 -1
  273. package/dist/esm/kol-input-radio.entry.js +1 -1
  274. package/dist/esm/kol-input-range.entry.js +1 -1
  275. package/dist/esm/kol-input-text.entry.js +1 -1
  276. package/dist/esm/kol-kolibri.entry.js +1 -1
  277. package/dist/esm/kol-link-button.entry.js +1 -1
  278. package/dist/esm/kol-link-wc.entry.js +1 -1
  279. package/dist/esm/kol-link-wc.entry.js.map +1 -1
  280. package/dist/esm/kol-link.entry.js +1 -1
  281. package/dist/esm/kol-link.entry.js.map +1 -1
  282. package/dist/esm/kol-modal.entry.js +1 -1
  283. package/dist/esm/kol-modal.entry.js.map +1 -1
  284. package/dist/esm/kol-nav.entry.js +1 -1
  285. package/dist/esm/kol-nav.entry.js.map +1 -1
  286. package/dist/esm/kol-pagination-wc.entry.js +1 -1
  287. package/dist/esm/kol-pagination-wc.entry.js.map +1 -1
  288. package/dist/esm/kol-pagination.entry.js +1 -1
  289. package/dist/esm/kol-popover-button-wc.entry.js +1 -1
  290. package/dist/esm/kol-popover-button.entry.js +1 -1
  291. package/dist/esm/kol-popover-wc.entry.js +1 -1
  292. package/dist/esm/kol-progress.entry.js +1 -1
  293. package/dist/esm/kol-quote.entry.js +1 -1
  294. package/dist/esm/kol-select.entry.js +1 -1
  295. package/dist/esm/kol-single-select.entry.js +1 -1
  296. package/dist/esm/kol-skip-nav.entry.js +1 -1
  297. package/dist/esm/kol-spin.entry.js +1 -1
  298. package/dist/esm/kol-split-button.entry.js +1 -1
  299. package/dist/esm/kol-table-settings-wc.entry.js +1 -1
  300. package/dist/esm/kol-table-stateful.entry.js +1 -1
  301. package/dist/esm/kol-table-stateless-wc.entry.js +1 -1
  302. package/dist/esm/kol-table-stateless.entry.js +1 -1
  303. package/dist/esm/kol-tabs.entry.js +1 -1
  304. package/dist/esm/kol-textarea.entry.js +1 -1
  305. package/dist/esm/kol-toast-container.entry.js +1 -1
  306. package/dist/esm/kol-toast-container.entry.js.map +1 -1
  307. package/dist/esm/kol-toolbar.entry.js +1 -1
  308. package/dist/esm/kol-tooltip-wc.entry.js +1 -1
  309. package/dist/esm/kol-tooltip-wc.entry.js.map +1 -1
  310. package/dist/esm/kol-tree-item-wc.entry.js +1 -1
  311. package/dist/esm/kol-tree-item.entry.js +1 -1
  312. package/dist/esm/kol-tree-wc.entry.js +1 -1
  313. package/dist/esm/kol-tree.entry.js +1 -1
  314. package/dist/esm/kol-version.entry.js +1 -1
  315. package/dist/esm/kolibri.js +1 -1
  316. package/dist/esm/loader.js +1 -1
  317. package/dist/esm/test-component.entry.js +1 -1
  318. package/dist/esm/tooltip-open-tracking-rBbBgPWP.js +4 -0
  319. package/dist/esm/tooltip-open-tracking-rBbBgPWP.js.map +1 -0
  320. package/dist/kolibri/Alert-yh8R3coC.js +4 -0
  321. package/dist/kolibri/Alert-yh8R3coC.js.map +1 -0
  322. package/dist/kolibri/{Collapsible-VwOBRTg-.js → Collapsible-DMNJjdc3.js} +1 -1
  323. package/dist/kolibri/{Collapsible-VwOBRTg-.js.map → Collapsible-DMNJjdc3.js.map} +1 -1
  324. package/dist/kolibri/{CustomSuggestionsToggle-BtYSYCn5.js → CustomSuggestionsToggle-_i-9Z6oo.js} +1 -1
  325. package/dist/{esm/CustomSuggestionsToggle-BtYSYCn5.js.map → kolibri/CustomSuggestionsToggle-_i-9Z6oo.js.map} +1 -1
  326. package/dist/kolibri/FieldControlStateWrapper-DxTxYvO0.js +4 -0
  327. package/dist/kolibri/FieldControlStateWrapper-DxTxYvO0.js.map +1 -0
  328. package/dist/kolibri/FormFieldStateWrapper-DRcnPo2o.js +4 -0
  329. package/dist/kolibri/FormFieldStateWrapper-DRcnPo2o.js.map +1 -0
  330. package/dist/kolibri/Heading-KhwFHPZb.js +4 -0
  331. package/dist/{esm/Heading-CMd-jtC1.js.map → kolibri/Heading-KhwFHPZb.js.map} +1 -1
  332. package/dist/kolibri/Icon-BsRmEtCa.js +4 -0
  333. package/dist/kolibri/{Icon-BQRZwXjg.js.map → Icon-BsRmEtCa.js.map} +1 -1
  334. package/dist/kolibri/Input-BxElrU0N.js +4 -0
  335. package/dist/kolibri/{Input-BQNyXbdV.js.map → Input-BxElrU0N.js.map} +1 -1
  336. package/dist/kolibri/InputStateWrapper-GJbSTDc8.js +4 -0
  337. package/dist/kolibri/{InputStateWrapper-5DGko7Ry.js.map → InputStateWrapper-GJbSTDc8.js.map} +1 -1
  338. package/dist/kolibri/InternalUnderlinedBadgeText-BnPUgbKl.js +4 -0
  339. package/dist/kolibri/{InternalUnderlinedBadgeText-DeV9AANw.js.map → InternalUnderlinedBadgeText-BnPUgbKl.js.map} +1 -1
  340. package/dist/kolibri/Span-5ZR0JDnP.js +4 -0
  341. package/dist/kolibri/{Span-9Jbefwfo.js.map → Span-5ZR0JDnP.js.map} +1 -1
  342. package/dist/kolibri/app-globals-COkPg4hl.js +4 -0
  343. package/dist/kolibri/{app-globals-BV7c4MN_.js.map → app-globals-COkPg4hl.js.map} +1 -1
  344. package/dist/kolibri/{controller-BMZRH6Si.js → controller-BiC2tpL8.js} +1 -1
  345. package/dist/kolibri/{controller-BMZRH6Si.js.map → controller-BiC2tpL8.js.map} +1 -1
  346. package/dist/kolibri/{controller-C7skty3T.js → controller-CeGWU1Au.js} +1 -1
  347. package/dist/{esm/controller-C7skty3T.js.map → kolibri/controller-CeGWU1Au.js.map} +1 -1
  348. package/dist/kolibri/{controller-B_Bwl5E9.js → controller-HR9pimff.js} +1 -1
  349. package/dist/kolibri/{controller-B_Bwl5E9.js.map → controller-HR9pimff.js.map} +1 -1
  350. package/dist/kolibri/{controller-icon-DcftMfhw.js → controller-icon-DN63N3Rm.js} +1 -1
  351. package/dist/kolibri/{controller-icon-DcftMfhw.js.map → controller-icon-DN63N3Rm.js.map} +1 -1
  352. package/dist/kolibri/{dev.utils-D2H-D7vZ.js → dev.utils-0SH3ep_K.js} +1 -1
  353. package/dist/kolibri/{dev.utils-D2H-D7vZ.js.map → dev.utils-0SH3ep_K.js.map} +1 -1
  354. package/dist/kolibri/{devtools-Bv4R5yuw.js → devtools-Cg1RmbyV.js} +1 -1
  355. package/dist/kolibri/{devtools-Bv4R5yuw.js.map → devtools-Cg1RmbyV.js.map} +1 -1
  356. package/dist/kolibri/{index-DKFHNf-G.js → index-Dina3aff.js} +1 -1
  357. package/dist/kolibri/index-Dina3aff.js.map +1 -0
  358. package/dist/kolibri/index.esm.js +1 -1
  359. package/dist/kolibri/index.esm.js.map +1 -1
  360. package/dist/kolibri/kol-abbr.entry.js +1 -1
  361. package/dist/kolibri/kol-accordion.entry.js +1 -1
  362. package/dist/kolibri/kol-alert-wc.entry.js +1 -1
  363. package/dist/kolibri/kol-alert.entry.js +1 -1
  364. package/dist/kolibri/kol-avatar-wc.entry.js +1 -1
  365. package/dist/kolibri/kol-avatar.entry.js +1 -1
  366. package/dist/kolibri/kol-badge.entry.js +1 -1
  367. package/dist/kolibri/kol-breadcrumb.entry.esm.js.map +1 -1
  368. package/dist/kolibri/kol-breadcrumb.entry.js +1 -1
  369. package/dist/kolibri/kol-breadcrumb.entry.js.map +1 -1
  370. package/dist/kolibri/kol-button-link.entry.esm.js.map +1 -1
  371. package/dist/kolibri/kol-button-link.entry.js +1 -1
  372. package/dist/kolibri/kol-button-link.entry.js.map +1 -1
  373. package/dist/kolibri/kol-button-wc.entry.esm.js.map +1 -1
  374. package/dist/kolibri/kol-button-wc.entry.js +1 -1
  375. package/dist/kolibri/kol-button-wc.entry.js.map +1 -1
  376. package/dist/kolibri/kol-button.entry.js +1 -1
  377. package/dist/kolibri/kol-card-wc.entry.js +1 -1
  378. package/dist/kolibri/kol-card.entry.js +1 -1
  379. package/dist/kolibri/kol-combobox.entry.js +1 -1
  380. package/dist/kolibri/kol-details.entry.js +1 -1
  381. package/dist/kolibri/kol-drawer.entry.esm.js.map +1 -1
  382. package/dist/kolibri/kol-drawer.entry.js +1 -1
  383. package/dist/kolibri/kol-drawer.entry.js.map +1 -1
  384. package/dist/kolibri/kol-form.entry.esm.js.map +1 -1
  385. package/dist/kolibri/kol-form.entry.js +1 -1
  386. package/dist/kolibri/kol-form.entry.js.map +1 -1
  387. package/dist/kolibri/kol-heading.entry.js +1 -1
  388. package/dist/kolibri/kol-icon.entry.esm.js.map +1 -1
  389. package/dist/kolibri/kol-icon.entry.js +1 -1
  390. package/dist/kolibri/kol-icon.entry.js.map +1 -1
  391. package/dist/kolibri/kol-image.entry.js +1 -1
  392. package/dist/kolibri/kol-input-checkbox.entry.js +1 -1
  393. package/dist/kolibri/kol-input-color.entry.js +1 -1
  394. package/dist/kolibri/kol-input-date.entry.js +1 -1
  395. package/dist/kolibri/kol-input-date.entry.js.map +1 -1
  396. package/dist/kolibri/kol-input-email.entry.js +1 -1
  397. package/dist/kolibri/kol-input-file.entry.js +1 -1
  398. package/dist/kolibri/kol-input-number.entry.js +1 -1
  399. package/dist/kolibri/kol-input-password.entry.js +1 -1
  400. package/dist/kolibri/kol-input-radio.entry.js +1 -1
  401. package/dist/kolibri/kol-input-range.entry.js +1 -1
  402. package/dist/kolibri/kol-input-text.entry.js +1 -1
  403. package/dist/kolibri/kol-kolibri.entry.js +1 -1
  404. package/dist/kolibri/kol-link-button.entry.js +1 -1
  405. package/dist/kolibri/kol-link-wc.entry.esm.js.map +1 -1
  406. package/dist/kolibri/kol-link-wc.entry.js +1 -1
  407. package/dist/kolibri/kol-link-wc.entry.js.map +1 -1
  408. package/dist/kolibri/kol-link.entry.esm.js.map +1 -1
  409. package/dist/kolibri/kol-link.entry.js +1 -1
  410. package/dist/kolibri/kol-link.entry.js.map +1 -1
  411. package/dist/kolibri/kol-modal.entry.esm.js.map +1 -1
  412. package/dist/kolibri/kol-modal.entry.js +1 -1
  413. package/dist/kolibri/kol-modal.entry.js.map +1 -1
  414. package/dist/kolibri/kol-nav.entry.esm.js.map +1 -1
  415. package/dist/kolibri/kol-nav.entry.js +1 -1
  416. package/dist/kolibri/kol-nav.entry.js.map +1 -1
  417. package/dist/kolibri/kol-pagination-wc.entry.esm.js.map +1 -1
  418. package/dist/kolibri/kol-pagination-wc.entry.js +1 -1
  419. package/dist/kolibri/kol-pagination-wc.entry.js.map +1 -1
  420. package/dist/kolibri/kol-pagination.entry.js +1 -1
  421. package/dist/kolibri/kol-popover-button-wc.entry.js +1 -1
  422. package/dist/kolibri/kol-popover-button.entry.js +1 -1
  423. package/dist/kolibri/kol-popover-wc.entry.js +1 -1
  424. package/dist/kolibri/kol-progress.entry.js +1 -1
  425. package/dist/kolibri/kol-quote.entry.js +1 -1
  426. package/dist/kolibri/kol-select.entry.js +1 -1
  427. package/dist/kolibri/kol-single-select.entry.js +1 -1
  428. package/dist/kolibri/kol-skip-nav.entry.js +1 -1
  429. package/dist/kolibri/kol-spin.entry.js +1 -1
  430. package/dist/kolibri/kol-split-button.entry.js +1 -1
  431. package/dist/kolibri/kol-table-settings-wc.entry.js +1 -1
  432. package/dist/kolibri/kol-table-stateful.entry.js +1 -1
  433. package/dist/kolibri/kol-table-stateless-wc.entry.js +1 -1
  434. package/dist/kolibri/kol-table-stateless.entry.js +1 -1
  435. package/dist/kolibri/kol-tabs.entry.js +1 -1
  436. package/dist/kolibri/kol-textarea.entry.js +1 -1
  437. package/dist/kolibri/kol-toast-container.entry.esm.js.map +1 -1
  438. package/dist/kolibri/kol-toast-container.entry.js +1 -1
  439. package/dist/kolibri/kol-toast-container.entry.js.map +1 -1
  440. package/dist/kolibri/kol-toolbar.entry.js +1 -1
  441. package/dist/kolibri/kol-tooltip-wc.entry.esm.js.map +1 -1
  442. package/dist/kolibri/kol-tooltip-wc.entry.js +1 -1
  443. package/dist/kolibri/kol-tooltip-wc.entry.js.map +1 -1
  444. package/dist/kolibri/kol-tree-item-wc.entry.js +1 -1
  445. package/dist/kolibri/kol-tree-item.entry.js +1 -1
  446. package/dist/kolibri/kol-tree-wc.entry.js +1 -1
  447. package/dist/kolibri/kol-tree.entry.js +1 -1
  448. package/dist/kolibri/kol-version.entry.js +1 -1
  449. package/dist/kolibri/kolibri.esm.js +1 -1
  450. package/dist/kolibri/test-component.entry.js +1 -1
  451. package/dist/kolibri/tooltip-open-tracking-rBbBgPWP.js +4 -0
  452. package/dist/kolibri/tooltip-open-tracking-rBbBgPWP.js.map +1 -0
  453. package/dist/types/components/button/component.d.ts +0 -1
  454. package/dist/types/components/drawer/shadow.d.ts +1 -1
  455. package/dist/types/components/link/component.d.ts +0 -1
  456. package/dist/types/components/nav/shadow.d.ts +3 -1
  457. package/dist/types/functional-components/FormFieldTooltip/FormFieldTooltip.d.ts +0 -1
  458. package/dist/types/index.d.ts +1 -0
  459. package/dist/types/schema/components/toaster.d.ts +3 -3
  460. package/dist/types/utils/tooltip-open-tracking.d.ts +4 -0
  461. package/doc/toaster.md +3 -3
  462. package/package.json +1 -1
  463. package/dist/cjs/Alert-pYM9xL1B.js.map +0 -1
  464. package/dist/cjs/FieldControlStateWrapper-CxSfV7UW.js +0 -4
  465. package/dist/cjs/FieldControlStateWrapper-CxSfV7UW.js.map +0 -1
  466. package/dist/cjs/FormFieldStateWrapper-CujxRl8G.js +0 -4
  467. package/dist/cjs/FormFieldStateWrapper-CujxRl8G.js.map +0 -1
  468. package/dist/cjs/Input-CMtYrIiX.js +0 -4
  469. package/dist/cjs/index-DHm-aTX3.js +0 -4
  470. package/dist/cjs/index-DHm-aTX3.js.map +0 -1
  471. package/dist/esm/Alert-qJPuIv8b.js.map +0 -1
  472. package/dist/esm/FieldControlStateWrapper-CIWPKSbC.js +0 -4
  473. package/dist/esm/FieldControlStateWrapper-CIWPKSbC.js.map +0 -1
  474. package/dist/esm/FormFieldStateWrapper-CKwM-DIl.js +0 -4
  475. package/dist/esm/FormFieldStateWrapper-CKwM-DIl.js.map +0 -1
  476. package/dist/esm/Icon-BQRZwXjg.js +0 -4
  477. package/dist/esm/Input-BQNyXbdV.js +0 -4
  478. package/dist/esm/InternalUnderlinedBadgeText-DeV9AANw.js +0 -4
  479. package/dist/esm/index-DKFHNf-G.js +0 -4
  480. package/dist/esm/index-DKFHNf-G.js.map +0 -1
  481. package/dist/kolibri/Alert-qJPuIv8b.js +0 -4
  482. package/dist/kolibri/Alert-qJPuIv8b.js.map +0 -1
  483. package/dist/kolibri/FieldControlStateWrapper-CIWPKSbC.js +0 -4
  484. package/dist/kolibri/FieldControlStateWrapper-CIWPKSbC.js.map +0 -1
  485. package/dist/kolibri/FormFieldStateWrapper-CKwM-DIl.js +0 -4
  486. package/dist/kolibri/FormFieldStateWrapper-CKwM-DIl.js.map +0 -1
  487. package/dist/kolibri/Heading-CMd-jtC1.js +0 -4
  488. package/dist/kolibri/Icon-BQRZwXjg.js +0 -4
  489. package/dist/kolibri/Input-BQNyXbdV.js +0 -4
  490. package/dist/kolibri/InputStateWrapper-5DGko7Ry.js +0 -4
  491. package/dist/kolibri/InternalUnderlinedBadgeText-DeV9AANw.js +0 -4
  492. package/dist/kolibri/Span-9Jbefwfo.js +0 -4
  493. package/dist/kolibri/app-globals-BV7c4MN_.js +0 -4
  494. package/dist/kolibri/index-DKFHNf-G.js.map +0 -1
@@ -1 +1 @@
1
- {"file":"kol-button-wc.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAgBO,MAAM,oBAAoB,GAAG,CAAC,SAAoC,EAAE,KAAe,KAAU;AACnG,IAAA,YAAY,CAAC,SAAS,EAAE,eAAe,EAAE,KAAK,CAAC;AAChD,CAAC;;ACEM,MAAM,uBAAuB,GAAG,CAAC,SAAoC,EAAE,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a,CAAC;AAC7C,QAAA,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,KAAK,CAAC;AAC7B,QAAA,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,MAAM,CAAC;AAC/B,QAAA,IAAI,CAAC,qBAAqB,CAAC,IAAI,CAAC,cAAc,CAAC;QAC/C,yBAAyB,CAAC,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,SAAS,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["KolButtonWc","__stencil_proxyCustomElement"],"sources":["src/schema/props/aria-selected.ts","src/schema/props/button-callbacks.ts","src/schema/props/button-type.ts","src/components/button/component.tsx"],"sourcesContent":["import type { Generic } from 'adopted-style-sheets';\n\nimport { watchBoolean } from '../utils';\n\n/* types */\nexport type AriaSelectedPropType = boolean;\n\n/**\n * Marks this element as selected.\n * (https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-selected)\n */\nexport type PropAriaSelected = {\n\tariaSelected: AriaSelectedPropType;\n};\n\n/* validator */\nexport const validateAriaSelected = (component: Generic.Element.Component, value?: boolean): void => {\n\twatchBoolean(component, '_ariaSelected', value);\n};\n","import type { Callback } from '../enums';\nimport type { EventCallback, EventValueOrEventCallback } from '../types/callbacks';\nimport type { StencilUnknown } from '../types/unknown';\nimport { watchValidator } from '../utils';\n\nimport type { Generic } from 'adopted-style-sheets';\n/* types */\nexport type ButtonCallbacksPropType<T> = {\n\t[Callback.onClick]?: EventValueOrEventCallback<MouseEvent, T>;\n\t[Callback.onMouseDown]?: EventCallback<MouseEvent>;\n};\n\n/**\n * Defines the callback functions for button events.\n */\nexport type PropButtonCallbacks<T> = {\n\ton: ButtonCallbacksPropType<T>;\n};\n\n/* validator */\nexport const validateButtonCallbacks = (component: Generic.Element.Component, value?: ButtonCallbacksPropType<StencilUnknown>): void => {\n\twatchValidator(\n\t\tcomponent,\n\t\t`_on`,\n\t\t(value) => typeof value === 'object' && value !== null,\n\t\tnew Set(['ButtonCallbacksPropType {Events.onClick, Events.onMouseDown}']),\n\t\tvalue,\n\t);\n};\n","/* types */\nimport type { Generic } from 'adopted-style-sheets';\nimport { watchValidator } from '../utils';\n\nconst buttonTypePropTypeOptions = ['button', 'reset', 'submit'] as const;\nexport type ButtonTypePropType = (typeof buttonTypePropTypeOptions)[number];\n\n/**\n * Defines either the type of the component or of the components interactive element.\n */\nexport type PropButtonType = {\n\ttype: ButtonTypePropType;\n};\n\n/* validator */\nexport const validateButtonType = (component: Generic.Element.Component, value?: ButtonTypePropType): void => {\n\twatchValidator(\n\t\tcomponent,\n\t\t`_type`,\n\t\t(value?) => typeof value === 'string' && buttonTypePropTypeOptions.includes(value),\n\t\tnew Set([`KoliBriButtonType {${buttonTypePropTypeOptions.join(', ')}`]),\n\t\tvalue,\n\t);\n};\n","import type {\n\tAccessKeyPropType,\n\tAlternativeButtonLinkRolePropType,\n\tAriaDescriptionPropType,\n\tAriaExpandedPropType,\n\tAriaSelectedPropType,\n\tButtonCallbacksPropType,\n\tButtonStates,\n\tButtonTypePropType,\n\tButtonVariantPropType,\n\tCustomClassPropType,\n\tDisabledPropType,\n\tHideLabelPropType,\n\tFocusableElement,\n\tIconsPropType,\n\tInternalButtonAPI,\n\tLabelWithExpertSlotPropType,\n\tLinkVariantPropType,\n\tShortKeyPropType,\n\tStencilUnknown,\n\tSyncValueBySelectorPropType,\n\tTooltipAlignPropType,\n} from '../../schema';\nimport { validateLinkVariant } from '../../schema';\nimport {\n\tmapBoolean2String,\n\tmapStringOrBoolean2String,\n\tsetEventTarget,\n\tsetState,\n\tshowExpertSlot,\n\tvalidateAccessKey,\n\tvalidateAlternativeButtonLinkRole,\n\tvalidateAriaControls,\n\tvalidateAriaDescription,\n\tvalidateAriaExpanded,\n\tvalidateAriaSelected,\n\tvalidateButtonCallbacks,\n\tvalidateButtonType,\n\tvalidateButtonVariant,\n\tvalidateCustomClass,\n\tvalidateDisabled,\n\tvalidateHideLabel,\n\tvalidateIcons,\n\tvalidateLabelWithExpertSlot,\n\tvalidateShortKey,\n\tvalidateTooltipAlign,\n\twatchString,\n} from '../../schema';\nimport { validateTabIndex } from '../../schema/props/tab-index';\nimport type { JSX } from '@stencil/core';\nimport { Component, Element, h, Host, Method, Prop, State, Watch } from '@stencil/core';\n\nimport { dispatchDomEvent, KolEvent } from '../../utils/events';\nimport { nonce } from '../../utils/dev.utils';\nimport { propagateResetEventToForm, propagateSubmitEventToForm } from '../form/controller';\nimport { AssociatedInputController } from '../input-adapter-leanup/associated.controller';\nimport { KolTooltipWcTag } from '../../core/component-names';\nimport { validateAccessAndShortKey } from '../../schema/validators/access-and-short-key';\nimport type { AriaHasPopupPropType } from '../../schema/props/aria-has-popup';\nimport { KolSpanFc } from '../../functional-components';\nimport clsx from 'clsx';\n\n/**\n * @internal\n */\n@Component({\n\ttag: 'kol-button-wc',\n\tshadow: false,\n})\nexport class KolButtonWc implements InternalButtonAPI, FocusableElement {\n\t@Element() private readonly host?: HTMLKolButtonWcElement;\n\tprivate buttonRef?: HTMLButtonElement;\n\tprivate tooltipRef?: HTMLKolTooltipWcElement;\n\n\tprivate readonly internalDescriptionById = nonce();\n\n\t/**\n\t * Sets focus on the internal element.\n\t */\n\t@Method()\n\t// eslint-disable-next-line @typescript-eslint/require-await\n\tpublic async kolFocus() {\n\t\tthis.buttonRef?.focus();\n\t}\n\n\t/**\n\t * Hides the tooltip.\n\t */\n\t@Method()\n\t// eslint-disable-next-line @typescript-eslint/require-await\n\tpublic async hideTooltip() {\n\t\tvoid this.tooltipRef?.hideTooltip();\n\t}\n\n\tprivate readonly onClick = (event: MouseEvent) => {\n\t\tif (this.state._type === 'submit') {\n\t\t\tpropagateSubmitEventToForm({\n\t\t\t\tform: this.host,\n\t\t\t\tref: this.buttonRef,\n\t\t\t});\n\t\t} else if (this.state._type === 'reset') {\n\t\t\tpropagateResetEventToForm({\n\t\t\t\tform: this.host,\n\t\t\t\tref: this.buttonRef,\n\t\t\t});\n\t\t} else {\n\t\t\t// TODO: Static form handling\n\t\t\tthis.controller.setFormAssociatedValue(this.state._value);\n\n\t\t\t// Callback\n\t\t\tif (typeof this.state._on?.onClick === 'function') {\n\t\t\t\tsetEventTarget(event, this.buttonRef);\n\t\t\t\tthis.state._on?.onClick(event, this.state._value);\n\t\t\t}\n\t\t}\n\n\t\tif (this.host) {\n\t\t\tdispatchDomEvent(this.host, KolEvent.click, this.state._value);\n\t\t}\n\t};\n\n\tprivate readonly onMouseDown = (event: MouseEvent) => {\n\t\tthis.state?._on?.onMouseDown?.(event);\n\t\tif (this.host) {\n\t\t\tdispatchDomEvent(this.host, KolEvent.mousedown);\n\t\t}\n\t};\n\n\tpublic render(): JSX.Element {\n\t\tconst hasExpertSlot = showExpertSlot(this.state._label);\n\t\tconst hasAriaDescription = Boolean(this.state._ariaDescription?.trim()?.length);\n\t\tconst badgeText = this.state._accessKey || this.state._shortKey;\n\t\tconst isDisabled = this.state._disabled === true;\n\t\tconst hideLabel = this.state._hideLabel === true;\n\n\t\treturn (\n\t\t\t<Host>\n\t\t\t\t<button\n\t\t\t\t\tref={(ref) => (this.buttonRef = ref)}\n\t\t\t\t\taccessKey={this.state._accessKey}\n\t\t\t\t\taria-controls={this.state._ariaControls}\n\t\t\t\t\taria-describedby={hasAriaDescription ? this.internalDescriptionById : undefined}\n\t\t\t\t\taria-expanded={mapBoolean2String(this.state._ariaExpanded)}\n\t\t\t\t\taria-haspopup={this._ariaHasPopup}\n\t\t\t\t\taria-keyshortcuts={this.state._shortKey}\n\t\t\t\t\taria-label={hideLabel && typeof this.state._label === 'string' ? this.state._label : undefined}\n\t\t\t\t\taria-selected={mapStringOrBoolean2String(this.state._ariaSelected)}\n\t\t\t\t\tclass={clsx('kol-button', {\n\t\t\t\t\t\t'kol-button--disabled': isDisabled,\n\t\t\t\t\t\t[`kol-button--${this.state._buttonVariant as string}`]: this.state._buttonVariant !== 'custom',\n\t\t\t\t\t\t[`kol-button--${this.state._linkVariant as string}`]: this.state._linkVariant,\n\t\t\t\t\t\t'kol-button--hide-label': hideLabel,\n\t\t\t\t\t\t[this.state._customClass as string]:\n\t\t\t\t\t\t\tthis.state._buttonVariant === 'custom' && typeof this.state._customClass === 'string' && this.state._customClass.length > 0,\n\t\t\t\t\t})}\n\t\t\t\t\tdisabled={isDisabled}\n\t\t\t\t\tid={this.state._id}\n\t\t\t\t\tname={this.state._name}\n\t\t\t\t\tonClick={this.onClick}\n\t\t\t\t\tonMouseDown={this.onMouseDown}\n\t\t\t\t\trole={this.state._role}\n\t\t\t\t\ttabIndex={this.state._tabIndex}\n\t\t\t\t\ttype={this.state._type}\n\t\t\t\t>\n\t\t\t\t\t<KolSpanFc\n\t\t\t\t\t\tclass=\"kol-button__text\"\n\t\t\t\t\t\tbadgeText={badgeText}\n\t\t\t\t\t\ticons={this.state._icons}\n\t\t\t\t\t\thideLabel={hideLabel}\n\t\t\t\t\t\tlabel={hasExpertSlot ? '' : this.state._label}\n\t\t\t\t\t>\n\t\t\t\t\t\t<slot name=\"expert\" slot=\"expert\"></slot>\n\t\t\t\t\t</KolSpanFc>\n\t\t\t\t</button>\n\t\t\t\t<KolTooltipWcTag\n\t\t\t\t\tref={(ref) => (this.tooltipRef = ref)}\n\t\t\t\t\t/**\n\t\t\t\t\t * Dieses Aria-Hidden verhindert das doppelte Vorlesen des Labels,\n\t\t\t\t\t * verhindert aber nicht das Aria-Labelledby vorgelesen wird.\n\t\t\t\t\t */\n\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\thidden={hasExpertSlot || !hideLabel}\n\t\t\t\t\tclass=\"kol-button__tooltip\"\n\t\t\t\t\t_badgeText={badgeText}\n\t\t\t\t\t_align={this.state._tooltipAlign}\n\t\t\t\t\t_label={typeof this.state._label === 'string' ? this.state._label : ''}\n\t\t\t\t></KolTooltipWcTag>\n\t\t\t\t{hasAriaDescription && (\n\t\t\t\t\t<span class=\"visually-hidden\" id={this.internalDescriptionById}>\n\t\t\t\t\t\t{this.state._ariaDescription}\n\t\t\t\t\t</span>\n\t\t\t\t)}\n\t\t\t</Host>\n\t\t);\n\t}\n\n\tprivate readonly controller: AssociatedInputController;\n\n\t/**\n\t * Defines the key combination that can be used to trigger or focus the component’s interactive element.\n\t */\n\t@Prop() public _accessKey?: AccessKeyPropType;\n\n\t/**\n\t * Defines which elements are controlled by this component. (https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-controls)\n\t */\n\t@Prop() public _ariaControls?: string;\n\n\t/**\n\t * Defines the value for the aria-description attribute.\n\t */\n\t@Prop() public _ariaDescription?: AriaDescriptionPropType;\n\n\t/**\n\t * Defines whether the interactive element of the component expanded something. (https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-expanded)\n\t */\n\t@Prop() public _ariaExpanded?: boolean;\n\n\t/**\n\t * Defines the aria-haspopup attribute. (https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Reference/Attributes/aria-haspopup)\n\t * @internal\n\t */\n\t@Prop() public _ariaHasPopup?: AriaHasPopupPropType;\n\n\t/**\n\t * Defines whether the interactive element of the component is selected (e.g. role=tab). (https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-selected)\n\t */\n\t@Prop() public _ariaSelected?: boolean;\n\n\t/**\n\t * Defines the custom class attribute if _buttonVariant=\"custom\" is set.\n\t */\n\t@Prop() public _customClass?: CustomClassPropType;\n\n\t/**\n\t * Makes the element not focusable and ignore all events.\n\t */\n\t@Prop() public _disabled?: boolean = false;\n\n\t/**\n\t * Hides the caption by default and displays the caption text with a tooltip when the\n\t * interactive element is focused or the mouse is over it.\n\t * @TODO: Change type back to `HideLabelPropType` after Stencil#4663 has been resolved.\n\t */\n\t@Prop() public _hideLabel?: boolean = false;\n\n\t/**\n\t * Defines the icon classnames (e.g. `_icons=\"fa-solid fa-user\"`).\n\t */\n\t@Prop() public _icons?: IconsPropType;\n\n\t/**\n\t * Defines the internal ID of the primary component element.\n\t * @internal\n\t */\n\t@Prop() public _id?: string;\n\n\t/**\n\t * Defines the visible or semantic label of the component (e.g. aria-label, label, headline, caption, summary, etc.). Set to `false` to enable the expert slot.\n\t */\n\t@Prop() public _label!: LabelWithExpertSlotPropType;\n\n\t/**\n\t * Defines which variant should be used for presentation.\n\t * @internal\n\t */\n\t@Prop() public _linkVariant?: LinkVariantPropType;\n\n\t/**\n\t * Defines the technical name of an input field.\n\t */\n\t@Prop() public _name?: string;\n\n\t/**\n\t * Defines the callback functions for button events.\n\t */\n\t@Prop() public _on?: ButtonCallbacksPropType<StencilUnknown>;\n\n\t/**\n\t * Defines the role of the components primary element.\n\t */\n\t@Prop() public _role?: AlternativeButtonLinkRolePropType;\n\n\t/**\n\t * Adds a visual shortcut hint after the label and instructs the screen reader to read the shortcut aloud.\n\t */\n\t@Prop() public _shortKey?: ShortKeyPropType;\n\n\t/**\n\t * Selector for synchronizing the value with another input element.\n\t * @internal\n\t */\n\t@Prop() public _syncValueBySelector?: SyncValueBySelectorPropType;\n\n\t/**\n\t * Defines which tab-index the primary element of the component has. (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 * Defines where to show the Tooltip preferably: top, right, bottom or left.\n\t */\n\t@Prop() public _tooltipAlign?: TooltipAlignPropType = 'top';\n\n\t/**\n\t * Defines either the type of the component or of the components interactive element.\n\t */\n\t@Prop() public _type?: ButtonTypePropType = 'button';\n\n\t/**\n\t * Defines the value that the button emits on click.\n\t */\n\t@Prop() public _value?: StencilUnknown;\n\n\t/**\n\t * Defines which variant should be used for presentation.\n\t * @internal\n\t */\n\t@Prop() public _buttonVariant?: ButtonVariantPropType = 'normal';\n\n\t@State() public state: ButtonStates = {\n\t\t_icons: {},\n\t\t_label: '', // ⚠ required\n\t\t_on: {},\n\t\t_type: 'button',\n\t\t_buttonVariant: 'normal',\n\t};\n\n\tpublic constructor() {\n\t\tthis.controller = new AssociatedInputController(this, 'button', this.host);\n\t}\n\n\t@Watch('_accessKey')\n\tpublic validateAccessKey(value?: AccessKeyPropType): void {\n\t\tvalidateAccessKey(this, value);\n\t\tvalidateAccessAndShortKey(value, this._shortKey);\n\t}\n\n\t@Watch('_ariaControls')\n\tpublic validateAriaControls(value?: string): void {\n\t\tvalidateAriaControls(this, value);\n\t}\n\n\t@Watch('_ariaDescription')\n\tpublic validateAriaDescription(value?: AriaDescriptionPropType): void {\n\t\tvalidateAriaDescription(this, value);\n\t}\n\n\t@Watch('_ariaExpanded')\n\tpublic validateAriaExpanded(value?: AriaExpandedPropType): void {\n\t\tvalidateAriaExpanded(this, value);\n\t}\n\n\t@Watch('_ariaSelected')\n\tpublic validateAriaSelected(value?: AriaSelectedPropType): void {\n\t\tvalidateAriaSelected(this, value);\n\t}\n\n\t@Watch('_customClass')\n\tpublic validateCustomClass(value?: CustomClassPropType): void {\n\t\tvalidateCustomClass(this, value);\n\t}\n\n\t@Watch('_disabled')\n\tpublic validateDisabled(value?: DisabledPropType): void {\n\t\tvalidateDisabled(this, value);\n\t}\n\n\t@Watch('_hideLabel')\n\tpublic validateHideLabel(value?: HideLabelPropType): void {\n\t\tvalidateHideLabel(this, value);\n\t}\n\n\t@Watch('_icons')\n\tpublic validateIcons(value?: IconsPropType): void {\n\t\tvalidateIcons(this, value);\n\t}\n\n\t@Watch('_id')\n\tpublic validateId(value?: string): void {\n\t\twatchString(this, '_id', value);\n\t}\n\n\t@Watch('_label')\n\tpublic validateLabel(value?: LabelWithExpertSlotPropType): void {\n\t\tvalidateLabelWithExpertSlot(this, value, {\n\t\t\trequired: true,\n\t\t});\n\t}\n\n\t@Watch('_linkVariant')\n\tpublic validateLinkVariant(value?: LinkVariantPropType): void {\n\t\tvalidateLinkVariant(this, 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?: ButtonCallbacksPropType<StencilUnknown>): void {\n\t\tvalidateButtonCallbacks(this, value);\n\t}\n\n\t@Watch('_role')\n\tpublic validateRole(value?: AlternativeButtonLinkRolePropType): void {\n\t\tvalidateAlternativeButtonLinkRole(this, value);\n\t}\n\n\t@Watch('_shortKey')\n\tpublic validateShortKey(value?: ShortKeyPropType): void {\n\t\tvalidateShortKey(this, value);\n\t\tvalidateAccessAndShortKey(this._accessKey, value);\n\t}\n\n\t@Watch('_syncValueBySelector')\n\tpublic validateSyncValueBySelector(value?: SyncValueBySelectorPropType): void {\n\t\tthis.controller.validateSyncValueBySelector(value);\n\t}\n\n\t@Watch('_tabIndex')\n\tpublic validateTabIndex(value?: number): void {\n\t\tvalidateTabIndex(this, value);\n\t}\n\n\t@Watch('_tooltipAlign')\n\tpublic validateTooltipAlign(value?: TooltipAlignPropType): void {\n\t\tvalidateTooltipAlign(this, value);\n\t}\n\n\t@Watch('_type')\n\tpublic validateType(value?: ButtonTypePropType): void {\n\t\tvalidateButtonType(this, value);\n\t}\n\n\t@Watch('_value')\n\tpublic validateValue(value?: StencilUnknown): void {\n\t\tsetState(this, '_value', value);\n\t\tthis.controller.setFormAssociatedValue(this.state._value);\n\t}\n\n\t@Watch('_buttonVariant')\n\tpublic validateButtonVariant(value?: ButtonVariantPropType): void {\n\t\tvalidateButtonVariant(this, value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tthis.validateAccessKey(this._accessKey);\n\t\tthis.validateAriaControls(this._ariaControls);\n\t\tthis.validateAriaDescription(this._ariaDescription);\n\t\tthis.validateAriaExpanded(this._ariaExpanded);\n\t\tthis.validateAriaSelected(this._ariaSelected);\n\t\tthis.validateCustomClass(this._customClass);\n\t\tthis.validateDisabled(this._disabled);\n\t\tthis.validateHideLabel(this._hideLabel);\n\t\tthis.validateIcons(this._icons);\n\t\tthis.validateId(this._id);\n\t\tthis.validateLabel(this._label);\n\t\tthis.validateLinkVariant(this._linkVariant);\n\t\tthis.validateName(this._name);\n\t\tthis.validateOn(this._on);\n\t\tthis.validateRole(this._role);\n\t\tthis.validateShortKey(this._shortKey);\n\t\tthis.validateSyncValueBySelector(this._syncValueBySelector);\n\t\tthis.validateTabIndex(this._tabIndex);\n\t\tthis.validateTooltipAlign(this._tooltipAlign);\n\t\tthis.validateType(this._type);\n\t\tthis.validateValue(this._value);\n\t\tthis.validateButtonVariant(this._buttonVariant);\n\t\tvalidateAccessAndShortKey(this._accessKey, this._shortKey);\n\t}\n}\n"],"version":3}
1
+ {"file":"kol-button-wc.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;AAgBO,MAAM,oBAAoB,GAAG,CAAC,SAAoC,EAAE,KAAe,KAAU;AACnG,IAAA,YAAY,CAAC,SAAS,EAAE,eAAe,EAAE,KAAK,CAAC;AAChD,CAAC;;ACEM,MAAM,uBAAuB,GAAG,CAAC,SAAoC,EAAE,KAA+C,KAAU;AACtI,IAAA,cAAc,CACb,SAAS,EACT,CAAA,GAAA,CAAK,EACL,CAAC,KAAK,KAAK,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,KAAK,IAAI,EACtD,IAAI,GAAG,CAAC,CAAC,8DAA8D,CAAC,CAAC,EACzE,KAAK,CACL;AACF,CAAC;;ACxBD,MAAM,yBAAyB,GAAG,CAAC,QAAQ,EAAE,OAAO,EAAE,QAAQ,CAAU;AAWjE,MAAM,kBAAkB,GAAG,CAAC,SAAoC,EAAE,KAA0B,KAAU;AAC5G,IAAA,cAAc,CACb,SAAS,EACT,CAAO,KAAA,CAAA,EACP,CAAC,KAAM,KAAK,OAAO,KAAK,KAAK,QAAQ,IAAI,yBAAyB,CAAC,QAAQ,CAAC,KAAK,CAAC,EAClF,IAAI,GAAG,CAAC,CAAC,CAAA,mBAAA,EAAsB,yBAAyB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAE,CAAA,CAAC,CAAC,EACvE,KAAK,CACL;AACF,CAAC;;MC6CYA,aAAW,GAAAC,kBAAA,CAAA,MAAA,WAA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B,CAAC;AAC3D,QAAA,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,SAAS,CAAC;AACrC,QAAA,IAAI,CAAC,oBAAoB,CAAC,IAAI,CAAC,aAAa,CAAC;AAC7C,QAAA,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,KAAK,CAAC;AAC7B,QAAA,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,MAAM,CAAC;AAC/B,QAAA,IAAI,CAAC,qBAAqB,CAAC,IAAI,CAAC,cAAc,CAAC;QAC/C,yBAAyB,CAAC,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,SAAS,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["KolButtonWc","__stencil_proxyCustomElement"],"sources":["src/schema/props/aria-selected.ts","src/schema/props/button-callbacks.ts","src/schema/props/button-type.ts","src/components/button/component.tsx"],"sourcesContent":["import type { Generic } from 'adopted-style-sheets';\n\nimport { watchBoolean } from '../utils';\n\n/* types */\nexport type AriaSelectedPropType = boolean;\n\n/**\n * Marks this element as selected.\n * (https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-selected)\n */\nexport type PropAriaSelected = {\n\tariaSelected: AriaSelectedPropType;\n};\n\n/* validator */\nexport const validateAriaSelected = (component: Generic.Element.Component, value?: boolean): void => {\n\twatchBoolean(component, '_ariaSelected', value);\n};\n","import type { Callback } from '../enums';\nimport type { EventCallback, EventValueOrEventCallback } from '../types/callbacks';\nimport type { StencilUnknown } from '../types/unknown';\nimport { watchValidator } from '../utils';\n\nimport type { Generic } from 'adopted-style-sheets';\n/* types */\nexport type ButtonCallbacksPropType<T> = {\n\t[Callback.onClick]?: EventValueOrEventCallback<MouseEvent, T>;\n\t[Callback.onMouseDown]?: EventCallback<MouseEvent>;\n};\n\n/**\n * Defines the callback functions for button events.\n */\nexport type PropButtonCallbacks<T> = {\n\ton: ButtonCallbacksPropType<T>;\n};\n\n/* validator */\nexport const validateButtonCallbacks = (component: Generic.Element.Component, value?: ButtonCallbacksPropType<StencilUnknown>): void => {\n\twatchValidator(\n\t\tcomponent,\n\t\t`_on`,\n\t\t(value) => typeof value === 'object' && value !== null,\n\t\tnew Set(['ButtonCallbacksPropType {Events.onClick, Events.onMouseDown}']),\n\t\tvalue,\n\t);\n};\n","/* types */\nimport type { Generic } from 'adopted-style-sheets';\nimport { watchValidator } from '../utils';\n\nconst buttonTypePropTypeOptions = ['button', 'reset', 'submit'] as const;\nexport type ButtonTypePropType = (typeof buttonTypePropTypeOptions)[number];\n\n/**\n * Defines either the type of the component or of the components interactive element.\n */\nexport type PropButtonType = {\n\ttype: ButtonTypePropType;\n};\n\n/* validator */\nexport const validateButtonType = (component: Generic.Element.Component, value?: ButtonTypePropType): void => {\n\twatchValidator(\n\t\tcomponent,\n\t\t`_type`,\n\t\t(value?) => typeof value === 'string' && buttonTypePropTypeOptions.includes(value),\n\t\tnew Set([`KoliBriButtonType {${buttonTypePropTypeOptions.join(', ')}`]),\n\t\tvalue,\n\t);\n};\n","import type {\n\tAccessKeyPropType,\n\tAlternativeButtonLinkRolePropType,\n\tAriaDescriptionPropType,\n\tAriaExpandedPropType,\n\tAriaSelectedPropType,\n\tButtonCallbacksPropType,\n\tButtonStates,\n\tButtonTypePropType,\n\tButtonVariantPropType,\n\tCustomClassPropType,\n\tDisabledPropType,\n\tHideLabelPropType,\n\tFocusableElement,\n\tIconsPropType,\n\tInternalButtonAPI,\n\tLabelWithExpertSlotPropType,\n\tLinkVariantPropType,\n\tShortKeyPropType,\n\tStencilUnknown,\n\tSyncValueBySelectorPropType,\n\tTooltipAlignPropType,\n} from '../../schema';\nimport { validateLinkVariant } from '../../schema';\nimport {\n\tmapBoolean2String,\n\tmapStringOrBoolean2String,\n\tsetEventTarget,\n\tsetState,\n\tshowExpertSlot,\n\tvalidateAccessKey,\n\tvalidateAlternativeButtonLinkRole,\n\tvalidateAriaControls,\n\tvalidateAriaDescription,\n\tvalidateAriaExpanded,\n\tvalidateAriaSelected,\n\tvalidateButtonCallbacks,\n\tvalidateButtonType,\n\tvalidateButtonVariant,\n\tvalidateCustomClass,\n\tvalidateDisabled,\n\tvalidateHideLabel,\n\tvalidateIcons,\n\tvalidateLabelWithExpertSlot,\n\tvalidateShortKey,\n\tvalidateTooltipAlign,\n\twatchString,\n} from '../../schema';\nimport { validateTabIndex } from '../../schema/props/tab-index';\nimport type { JSX } from '@stencil/core';\nimport { Component, Element, h, Host, Method, Prop, State, Watch } from '@stencil/core';\n\nimport { dispatchDomEvent, KolEvent } from '../../utils/events';\nimport { propagateResetEventToForm, propagateSubmitEventToForm } from '../form/controller';\nimport { AssociatedInputController } from '../input-adapter-leanup/associated.controller';\nimport { KolTooltipWcTag } from '../../core/component-names';\nimport { validateAccessAndShortKey } from '../../schema/validators/access-and-short-key';\nimport type { AriaHasPopupPropType } from '../../schema/props/aria-has-popup';\nimport { KolSpanFc } from '../../functional-components';\nimport clsx from 'clsx';\n\n/**\n * @internal\n */\n@Component({\n\ttag: 'kol-button-wc',\n\tshadow: false,\n})\nexport class KolButtonWc implements InternalButtonAPI, FocusableElement {\n\t@Element() private readonly host?: HTMLKolButtonWcElement;\n\tprivate buttonRef?: HTMLButtonElement;\n\tprivate tooltipRef?: HTMLKolTooltipWcElement;\n\n\t/**\n\t * Sets focus on the internal element.\n\t */\n\t@Method()\n\t// eslint-disable-next-line @typescript-eslint/require-await\n\tpublic async kolFocus() {\n\t\tthis.buttonRef?.focus();\n\t}\n\n\t/**\n\t * Hides the tooltip.\n\t */\n\t@Method()\n\t// eslint-disable-next-line @typescript-eslint/require-await\n\tpublic async hideTooltip() {\n\t\tvoid this.tooltipRef?.hideTooltip();\n\t}\n\n\tprivate readonly onClick = (event: MouseEvent) => {\n\t\tif (this.state._type === 'submit') {\n\t\t\tpropagateSubmitEventToForm({\n\t\t\t\tform: this.host,\n\t\t\t\tref: this.buttonRef,\n\t\t\t});\n\t\t} else if (this.state._type === 'reset') {\n\t\t\tpropagateResetEventToForm({\n\t\t\t\tform: this.host,\n\t\t\t\tref: this.buttonRef,\n\t\t\t});\n\t\t} else {\n\t\t\t// TODO: Static form handling\n\t\t\tthis.controller.setFormAssociatedValue(this.state._value);\n\n\t\t\t// Callback\n\t\t\tif (typeof this.state._on?.onClick === 'function') {\n\t\t\t\tsetEventTarget(event, this.buttonRef);\n\t\t\t\tthis.state._on?.onClick(event, this.state._value);\n\t\t\t}\n\t\t}\n\n\t\tif (this.host) {\n\t\t\tdispatchDomEvent(this.host, KolEvent.click, this.state._value);\n\t\t}\n\t};\n\n\tprivate readonly onMouseDown = (event: MouseEvent) => {\n\t\tthis.state?._on?.onMouseDown?.(event);\n\t\tif (this.host) {\n\t\t\tdispatchDomEvent(this.host, KolEvent.mousedown);\n\t\t}\n\t};\n\n\tpublic render(): JSX.Element {\n\t\tconst hasExpertSlot = showExpertSlot(this.state._label);\n\t\tconst ariaDescription = this.state._ariaDescription?.trim();\n\t\tconst badgeText = this.state._accessKey || this.state._shortKey;\n\t\tconst isDisabled = this.state._disabled === true;\n\t\tconst hideLabel = this.state._hideLabel === true;\n\n\t\treturn (\n\t\t\t<Host>\n\t\t\t\t<button\n\t\t\t\t\tref={(ref) => (this.buttonRef = ref)}\n\t\t\t\t\taccessKey={this.state._accessKey}\n\t\t\t\t\taria-controls={this.state._ariaControls}\n\t\t\t\t\taria-description={ariaDescription || undefined}\n\t\t\t\t\taria-expanded={mapBoolean2String(this.state._ariaExpanded)}\n\t\t\t\t\taria-haspopup={this._ariaHasPopup}\n\t\t\t\t\taria-keyshortcuts={this.state._shortKey}\n\t\t\t\t\taria-label={hideLabel && typeof this.state._label === 'string' ? this.state._label : undefined}\n\t\t\t\t\taria-selected={mapStringOrBoolean2String(this.state._ariaSelected)}\n\t\t\t\t\tclass={clsx('kol-button', {\n\t\t\t\t\t\t'kol-button--disabled': isDisabled,\n\t\t\t\t\t\t[`kol-button--${this.state._buttonVariant as string}`]: this.state._buttonVariant !== 'custom',\n\t\t\t\t\t\t[`kol-button--${this.state._linkVariant as string}`]: this.state._linkVariant,\n\t\t\t\t\t\t'kol-button--hide-label': hideLabel,\n\t\t\t\t\t\t[this.state._customClass as string]:\n\t\t\t\t\t\t\tthis.state._buttonVariant === 'custom' && typeof this.state._customClass === 'string' && this.state._customClass.length > 0,\n\t\t\t\t\t})}\n\t\t\t\t\tdisabled={isDisabled}\n\t\t\t\t\tid={this.state._id}\n\t\t\t\t\tname={this.state._name}\n\t\t\t\t\tonClick={this.onClick}\n\t\t\t\t\tonMouseDown={this.onMouseDown}\n\t\t\t\t\trole={this.state._role}\n\t\t\t\t\ttabIndex={this.state._tabIndex}\n\t\t\t\t\ttype={this.state._type}\n\t\t\t\t>\n\t\t\t\t\t<KolSpanFc\n\t\t\t\t\t\tclass=\"kol-button__text\"\n\t\t\t\t\t\tbadgeText={badgeText}\n\t\t\t\t\t\ticons={this.state._icons}\n\t\t\t\t\t\thideLabel={hideLabel}\n\t\t\t\t\t\tlabel={hasExpertSlot ? '' : this.state._label}\n\t\t\t\t\t>\n\t\t\t\t\t\t<slot name=\"expert\" slot=\"expert\"></slot>\n\t\t\t\t\t</KolSpanFc>\n\t\t\t\t</button>\n\t\t\t\t{hideLabel && (\n\t\t\t\t\t<KolTooltipWcTag\n\t\t\t\t\t\tref={(ref) => (this.tooltipRef = ref)}\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * Dieses Aria-Hidden verhindert das doppelte Vorlesen des Labels,\n\t\t\t\t\t\t * verhindert aber nicht das Aria-Labelledby vorgelesen wird.\n\t\t\t\t\t\t */\n\t\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\t\thidden={hasExpertSlot}\n\t\t\t\t\t\tclass=\"kol-button__tooltip\"\n\t\t\t\t\t\t_badgeText={badgeText}\n\t\t\t\t\t\t_align={this.state._tooltipAlign}\n\t\t\t\t\t\t_label={typeof this.state._label === 'string' ? this.state._label : ''}\n\t\t\t\t\t></KolTooltipWcTag>\n\t\t\t\t)}\n\t\t\t</Host>\n\t\t);\n\t}\n\n\tprivate readonly controller: AssociatedInputController;\n\n\t/**\n\t * Defines the key combination that can be used to trigger or focus the component’s interactive element.\n\t */\n\t@Prop() public _accessKey?: AccessKeyPropType;\n\n\t/**\n\t * Defines which elements are controlled by this component. (https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-controls)\n\t */\n\t@Prop() public _ariaControls?: string;\n\n\t/**\n\t * Defines the value for the aria-description attribute.\n\t */\n\t@Prop() public _ariaDescription?: AriaDescriptionPropType;\n\n\t/**\n\t * Defines whether the interactive element of the component expanded something. (https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-expanded)\n\t */\n\t@Prop() public _ariaExpanded?: boolean;\n\n\t/**\n\t * Defines the aria-haspopup attribute. (https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Reference/Attributes/aria-haspopup)\n\t * @internal\n\t */\n\t@Prop() public _ariaHasPopup?: AriaHasPopupPropType;\n\n\t/**\n\t * Defines whether the interactive element of the component is selected (e.g. role=tab). (https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-selected)\n\t */\n\t@Prop() public _ariaSelected?: boolean;\n\n\t/**\n\t * Defines the custom class attribute if _buttonVariant=\"custom\" is set.\n\t */\n\t@Prop() public _customClass?: CustomClassPropType;\n\n\t/**\n\t * Makes the element not focusable and ignore all events.\n\t */\n\t@Prop() public _disabled?: boolean = false;\n\n\t/**\n\t * Hides the caption by default and displays the caption text with a tooltip when the\n\t * interactive element is focused or the mouse is over it.\n\t * @TODO: Change type back to `HideLabelPropType` after Stencil#4663 has been resolved.\n\t */\n\t@Prop() public _hideLabel?: boolean = false;\n\n\t/**\n\t * Defines the icon classnames (e.g. `_icons=\"fa-solid fa-user\"`).\n\t */\n\t@Prop() public _icons?: IconsPropType;\n\n\t/**\n\t * Defines the internal ID of the primary component element.\n\t * @internal\n\t */\n\t@Prop() public _id?: string;\n\n\t/**\n\t * Defines the visible or semantic label of the component (e.g. aria-label, label, headline, caption, summary, etc.). Set to `false` to enable the expert slot.\n\t */\n\t@Prop() public _label!: LabelWithExpertSlotPropType;\n\n\t/**\n\t * Defines which variant should be used for presentation.\n\t * @internal\n\t */\n\t@Prop() public _linkVariant?: LinkVariantPropType;\n\n\t/**\n\t * Defines the technical name of an input field.\n\t */\n\t@Prop() public _name?: string;\n\n\t/**\n\t * Defines the callback functions for button events.\n\t */\n\t@Prop() public _on?: ButtonCallbacksPropType<StencilUnknown>;\n\n\t/**\n\t * Defines the role of the components primary element.\n\t */\n\t@Prop() public _role?: AlternativeButtonLinkRolePropType;\n\n\t/**\n\t * Adds a visual shortcut hint after the label and instructs the screen reader to read the shortcut aloud.\n\t */\n\t@Prop() public _shortKey?: ShortKeyPropType;\n\n\t/**\n\t * Selector for synchronizing the value with another input element.\n\t * @internal\n\t */\n\t@Prop() public _syncValueBySelector?: SyncValueBySelectorPropType;\n\n\t/**\n\t * Defines which tab-index the primary element of the component has. (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 * Defines where to show the Tooltip preferably: top, right, bottom or left.\n\t */\n\t@Prop() public _tooltipAlign?: TooltipAlignPropType = 'top';\n\n\t/**\n\t * Defines either the type of the component or of the components interactive element.\n\t */\n\t@Prop() public _type?: ButtonTypePropType = 'button';\n\n\t/**\n\t * Defines the value that the button emits on click.\n\t */\n\t@Prop() public _value?: StencilUnknown;\n\n\t/**\n\t * Defines which variant should be used for presentation.\n\t * @internal\n\t */\n\t@Prop() public _buttonVariant?: ButtonVariantPropType = 'normal';\n\n\t@State() public state: ButtonStates = {\n\t\t_icons: {},\n\t\t_label: '', // ⚠ required\n\t\t_on: {},\n\t\t_type: 'button',\n\t\t_buttonVariant: 'normal',\n\t};\n\n\tpublic constructor() {\n\t\tthis.controller = new AssociatedInputController(this, 'button', this.host);\n\t}\n\n\t@Watch('_accessKey')\n\tpublic validateAccessKey(value?: AccessKeyPropType): void {\n\t\tvalidateAccessKey(this, value);\n\t\tvalidateAccessAndShortKey(value, this._shortKey);\n\t}\n\n\t@Watch('_ariaControls')\n\tpublic validateAriaControls(value?: string): void {\n\t\tvalidateAriaControls(this, value);\n\t}\n\n\t@Watch('_ariaDescription')\n\tpublic validateAriaDescription(value?: AriaDescriptionPropType): void {\n\t\tvalidateAriaDescription(this, value);\n\t}\n\n\t@Watch('_ariaExpanded')\n\tpublic validateAriaExpanded(value?: AriaExpandedPropType): void {\n\t\tvalidateAriaExpanded(this, value);\n\t}\n\n\t@Watch('_ariaSelected')\n\tpublic validateAriaSelected(value?: AriaSelectedPropType): void {\n\t\tvalidateAriaSelected(this, value);\n\t}\n\n\t@Watch('_customClass')\n\tpublic validateCustomClass(value?: CustomClassPropType): void {\n\t\tvalidateCustomClass(this, value);\n\t}\n\n\t@Watch('_disabled')\n\tpublic validateDisabled(value?: DisabledPropType): void {\n\t\tvalidateDisabled(this, value);\n\t}\n\n\t@Watch('_hideLabel')\n\tpublic validateHideLabel(value?: HideLabelPropType): void {\n\t\tvalidateHideLabel(this, value);\n\t}\n\n\t@Watch('_icons')\n\tpublic validateIcons(value?: IconsPropType): void {\n\t\tvalidateIcons(this, value);\n\t}\n\n\t@Watch('_id')\n\tpublic validateId(value?: string): void {\n\t\twatchString(this, '_id', value);\n\t}\n\n\t@Watch('_label')\n\tpublic validateLabel(value?: LabelWithExpertSlotPropType): void {\n\t\tvalidateLabelWithExpertSlot(this, value, {\n\t\t\trequired: true,\n\t\t});\n\t}\n\n\t@Watch('_linkVariant')\n\tpublic validateLinkVariant(value?: LinkVariantPropType): void {\n\t\tvalidateLinkVariant(this, 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?: ButtonCallbacksPropType<StencilUnknown>): void {\n\t\tvalidateButtonCallbacks(this, value);\n\t}\n\n\t@Watch('_role')\n\tpublic validateRole(value?: AlternativeButtonLinkRolePropType): void {\n\t\tvalidateAlternativeButtonLinkRole(this, value);\n\t}\n\n\t@Watch('_shortKey')\n\tpublic validateShortKey(value?: ShortKeyPropType): void {\n\t\tvalidateShortKey(this, value);\n\t\tvalidateAccessAndShortKey(this._accessKey, value);\n\t}\n\n\t@Watch('_syncValueBySelector')\n\tpublic validateSyncValueBySelector(value?: SyncValueBySelectorPropType): void {\n\t\tthis.controller.validateSyncValueBySelector(value);\n\t}\n\n\t@Watch('_tabIndex')\n\tpublic validateTabIndex(value?: number): void {\n\t\tvalidateTabIndex(this, value);\n\t}\n\n\t@Watch('_tooltipAlign')\n\tpublic validateTooltipAlign(value?: TooltipAlignPropType): void {\n\t\tvalidateTooltipAlign(this, value);\n\t}\n\n\t@Watch('_type')\n\tpublic validateType(value?: ButtonTypePropType): void {\n\t\tvalidateButtonType(this, value);\n\t}\n\n\t@Watch('_value')\n\tpublic validateValue(value?: StencilUnknown): void {\n\t\tsetState(this, '_value', value);\n\t\tthis.controller.setFormAssociatedValue(this.state._value);\n\t}\n\n\t@Watch('_buttonVariant')\n\tpublic validateButtonVariant(value?: ButtonVariantPropType): void {\n\t\tvalidateButtonVariant(this, value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tthis.validateAccessKey(this._accessKey);\n\t\tthis.validateAriaControls(this._ariaControls);\n\t\tthis.validateAriaDescription(this._ariaDescription);\n\t\tthis.validateAriaExpanded(this._ariaExpanded);\n\t\tthis.validateAriaSelected(this._ariaSelected);\n\t\tthis.validateCustomClass(this._customClass);\n\t\tthis.validateDisabled(this._disabled);\n\t\tthis.validateHideLabel(this._hideLabel);\n\t\tthis.validateIcons(this._icons);\n\t\tthis.validateId(this._id);\n\t\tthis.validateLabel(this._label);\n\t\tthis.validateLinkVariant(this._linkVariant);\n\t\tthis.validateName(this._name);\n\t\tthis.validateOn(this._on);\n\t\tthis.validateRole(this._role);\n\t\tthis.validateShortKey(this._shortKey);\n\t\tthis.validateSyncValueBySelector(this._syncValueBySelector);\n\t\tthis.validateTabIndex(this._tabIndex);\n\t\tthis.validateTooltipAlign(this._tooltipAlign);\n\t\tthis.validateType(this._type);\n\t\tthis.validateValue(this._value);\n\t\tthis.validateButtonVariant(this._buttonVariant);\n\t\tvalidateAccessAndShortKey(this._accessKey, this._shortKey);\n\t}\n}\n"],"version":3}
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{proxyCustomElement,HTMLElement,h,Host}from"@stencil/core/internal/client";import{s as setState}from"./common.js";import{v as validateHasCloser}from"./has-closer.js";import{v as validateLabel}from"./label.js";import{t as translate}from"./i18n.js";import{w as watchHeadingLevel}from"./validation.js";import{d as KolButtonWcTag}from"./component-names.js";import"./Alert.js";import{K as KolHeadingFc}from"./Heading.js";import"./markdown.js";import{n as nonce}from"./dev.utils.js";import{d as dispatchDomEvent,K as KolEvent}from"./events.js";const KolCardWc$1=proxyCustomElement(class extends HTMLElement{constructor(e){super(),!1!==e&&this.__registerHost(),this.nonce=nonce(),this.translateClose=translate("kol-close"),this.close=()=>{var e;void 0!==(null===(e=this._on)||void 0===e?void 0:e.onClose)&&this._on.onClose(new Event("Close")),this.host&&dispatchDomEvent(this.host,KolEvent.close)},this.on={onClick:this.close},this._hasCloser=!1,this._level=0,this.state={_label:""},this.validateOnValue=e=>"object"==typeof e&&null!==e&&"function"==typeof e.onClose}render(){return h(Host,{key:"de517413c990072e7e7faca2916c0c5243ad9495"},h("div",{key:"01f98d52d173677f5e314e2dce9425cc19cdaadc","aria-labelledby":this.nonce,class:"kol-card",role:"group"},h(KolHeadingFc,{key:"d2ce693140449135323ff1601af712982aae9325",class:"kol-card__header",id:this.nonce,level:this.state._level},this.state._label),h("div",{key:"155c2d42406dbb9ba02f6a29ec92f10d93b8c38d",class:"kol-card__content"},h("slot",{key:"f3c23f1168273dbfbb515b1d83b7f087d9d019ca"})),this.state._hasCloser&&h(KolButtonWcTag,{key:"7c9ebe3b241019c157161bfb2f5562a0ce482c09",class:"kol-card__close-button","data-testid":"card-close-button",_hideLabel:!0,_icons:{left:{icon:"codicon codicon-close"}},_label:this.translateClose,_on:this.on,_tooltipAlign:"left"})))}validateOn(e){this.validateOnValue(e)&&setState(this,"_on",{onClose:e.onClose})}validateHasCloser(e){validateHasCloser(this,e)}validateLabel(e){validateLabel(this,e,{required:!0})}validateLevel(e){watchHeadingLevel(this,e)}componentWillLoad(){this.validateHasCloser(this._hasCloser),this.validateLabel(this._label),this.validateLevel(this._level),this.validateOn(this._on)}get host(){return this}static get watchers(){return{_on:["validateOn"],_hasCloser:["validateHasCloser"],_label:["validateLabel"],_level:["validateLevel"]}}},[260,"kol-card-wc",{_on:[16],_hasCloser:[4,"_has-closer"],_label:[1],_level:[2],state:[32]},void 0,{_on:["validateOn"],_hasCloser:["validateHasCloser"],_label:["validateLabel"],_level:["validateLevel"]}]);function defineCustomElement$1(){if("undefined"==typeof customElements)return;["kol-card-wc"].forEach(e=>{if("kol-card-wc"===e)customElements.get(e)||customElements.define(e,KolCardWc$1)})}const KolCardWc=KolCardWc$1,defineCustomElement=defineCustomElement$1;export{KolCardWc,defineCustomElement};
4
+ import{proxyCustomElement,HTMLElement,h,Host}from"@stencil/core/internal/client";import{s as setState}from"./common.js";import{v as validateHasCloser}from"./has-closer.js";import{v as validateLabel}from"./label.js";import{t as translate}from"./i18n.js";import{w as watchHeadingLevel}from"./validation.js";import{d as KolButtonWcTag}from"./component-names.js";import"./Alert.js";import{K as KolHeadingFc}from"./Heading.js";import"./markdown.js";import{n as nonce}from"./dev.utils.js";import{d as dispatchDomEvent,K as KolEvent}from"./events.js";const KolCardWc$1=proxyCustomElement(class extends HTMLElement{constructor(e){super(),!1!==e&&this.__registerHost(),this.nonce=nonce(),this.translateClose=translate("kol-close"),this.close=()=>{var e;void 0!==(null===(e=this._on)||void 0===e?void 0:e.onClose)&&this._on.onClose(new Event("Close")),this.host&&dispatchDomEvent(this.host,KolEvent.close)},this.on={onClick:this.close},this._hasCloser=!1,this._level=0,this.state={_label:""},this.validateOnValue=e=>"object"==typeof e&&null!==e&&"function"==typeof e.onClose}render(){return h(Host,{key:"e2e32f376bd12f7fc8beb4df8f76facb80f5e7a5"},h("div",{key:"0ef931bd24c643b575342f434506483f0b3ebca8","aria-labelledby":this.nonce,class:"kol-card",role:"group"},h(KolHeadingFc,{key:"ce924a0307338f9d6beaa3ea24051fbb3173d83e",class:"kol-card__header",id:this.nonce,level:this.state._level},this.state._label),h("div",{key:"2d004878aedb826c78acb8834d79144b05ae4d1b",class:"kol-card__content"},h("slot",{key:"c5075d61a16c46bdf3c8c5ffea3ca70cd02c4d8c"})),this.state._hasCloser&&h(KolButtonWcTag,{key:"89d83b4fb181fb2bd43b7b5a4dfedba1660395b4",class:"kol-card__close-button","data-testid":"card-close-button",_hideLabel:!0,_icons:{left:{icon:"codicon codicon-close"}},_label:this.translateClose,_on:this.on,_tooltipAlign:"left"})))}validateOn(e){this.validateOnValue(e)&&setState(this,"_on",{onClose:e.onClose})}validateHasCloser(e){validateHasCloser(this,e)}validateLabel(e){validateLabel(this,e,{required:!0})}validateLevel(e){watchHeadingLevel(this,e)}componentWillLoad(){this.validateHasCloser(this._hasCloser),this.validateLabel(this._label),this.validateLevel(this._level),this.validateOn(this._on)}get host(){return this}static get watchers(){return{_on:["validateOn"],_hasCloser:["validateHasCloser"],_label:["validateLabel"],_level:["validateLevel"]}}},[260,"kol-card-wc",{_on:[16],_hasCloser:[4,"_has-closer"],_label:[1],_level:[2],state:[32]},void 0,{_on:["validateOn"],_hasCloser:["validateHasCloser"],_label:["validateLabel"],_level:["validateLevel"]}]);function defineCustomElement$1(){if("undefined"==typeof customElements)return;["kol-card-wc"].forEach(e=>{if("kol-card-wc"===e)customElements.get(e)||customElements.define(e,KolCardWc$1)})}const KolCardWc=KolCardWc$1,defineCustomElement=defineCustomElement$1;export{KolCardWc,defineCustomElement};
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{proxyCustomElement,HTMLElement,h}from"@stencil/core/internal/client";import{g as KolCardWcTag}from"./component-names.js";const defaultStyleCss="/*\n* This file defines the layer order for all CSS layers used in KoliBri.\n* The order is important as it determines the cascade priority.\n*\n* Layer order (lowest to highest priority):\n* 1. kol-a11y - Accessibility defaults and requirements\n* 2. kol-global - Global component styles and resets\n* 3. kol-component - Component-specific styles\n* 4. kol-theme-global - Theme-specific global styles\n* 5. kol-theme-component - Theme-specific component styles\n*/\n@layer kol-a11y, kol-global, kol-component, kol-theme-global, kol-theme-component;\n/* forward the rem function */\n/*\n * This file contains all rules for accessibility.\n */\n@layer kol-a11y {\n :host {\n /*\n * Minimum size of interactive elements.\n */\n --a11y-min-size: calc(44 * 1rem / var(--kolibri-root-font-size, 16));\n /*\n * No element should be used without verifying the contrast ratio of its background and font colors.\n * By initially setting the background color to white and the font color to black,\n * the contrast ratio is ensured and explicit adjustment is forced.\n */\n color: black;\n background-color: white;\n /*\n * Verdana is an accessible font that can be used without requiring additional loading time.\n */\n font-family: Verdana;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n * {\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n hyphens: auto;\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n word-break: break-word;\n }\n /*\n * All interactive elements should have a minimum size of to-rem(44).\n */\n /* input:not([type='checkbox'], [type='radio'], [type='range']), */\n /* option, */\n /* select, */\n /* textarea, */\n button,\n .kol-input .input {\n min-width: var(--a11y-min-size);\n min-height: var(--a11y-min-size);\n }\n /*\n * Some interactive elements should not inherit the font-family and font-size.\n */\n a,\n button,\n h1,\n h2,\n h3,\n h4,\n h5,\n h6,\n input,\n option,\n select,\n textarea {\n /*\n * All elements should inherit the font family from his parent element.\n */\n font-family: inherit;\n /*\n * All elements should inherit the font size from his parent element.\n */\n font-size: inherit;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n /**\n * Sometimes we need the semantic element for accessibility reasons,\n * but we don't want to show it.\n *\n * - https://www.a11yproject.com/posts/how-to-hide-content/\n */\n .visually-hidden {\n position: fixed;\n top: 0;\n left: 0;\n width: 1px;\n height: 1px;\n overflow: hidden;\n white-space: nowrap;\n clip-path: inset(50%);\n }\n}\n@layer kol-global {\n /*\n * Dieses CSS stellt sicher, dass der Standard-Style\n * von A und Button resettet werden.\n */\n :is(a, button) {\n background-color: transparent;\n width: 100%;\n margin: 0;\n padding: 0;\n border: none;\n /* 100% needed for custom width from outside */\n }\n /*\n * Ensure elements with hidden attribute to be actually not visible\n * @see https://meowni.ca/hidden.is.a.lie.html\n */\n [hidden] {\n display: none !important;\n }\n .badge-text-hint {\n color: black;\n background-color: lightgray;\n }\n}\n@layer kol-global {\n :host {\n /*\n * The max-width is needed to prevent the table from overflowing the\n * parent node, if the table is wider than the parent node.\n */\n max-width: 100%;\n font-size: calc(16 * 1rem / var(--kolibri-root-font-size, 16));\n }\n * {\n /*\n * We prefer to box-sizing: border-box for all elements.\n */\n box-sizing: border-box;\n }\n .kol-span {\n /* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n display: grid;\n place-items: center;\n /* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n }\n .kol-span__container {\n display: flex;\n place-items: center;\n }\n a,\n button {\n cursor: pointer;\n }\n .kol-span .kol-span__label--hide-label .kol-span__label {\n display: none;\n }\n /* Reset browser agent style. */\n button:disabled {\n color: unset;\n }\n .disabled label,\n .disabled:focus-within label,\n [aria-disabled=true],\n [aria-disabled=true]:focus,\n [disabled],\n [disabled]:focus {\n opacity: 0.5;\n outline: none;\n cursor: not-allowed;\n }\n [aria-disabled=true]:focus .kol-span,\n [disabled]:focus .kol-span {\n outline: none !important;\n }\n}\n@layer kol-component {\n @keyframes fadeInOpacity {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n }\n .kol-tooltip {\n display: contents;\n }\n .kol-tooltip__floating {\n display: none;\n position: fixed;\n /* Avoid layout interference - see https://floating-ui.com/docs/computePosition */\n top: 0;\n left: 0;\n /* Can be used to specify the tooltip-width from the outside. Unset by default. */\n width: var(--kol-tooltip-width, max-content);\n min-width: calc(8 * 1rem / var(--kolibri-root-font-size, 16));\n max-width: 90vw;\n max-height: 90vh;\n visibility: hidden;\n animation-duration: 0.25s;\n animation-iteration-count: 1;\n animation-name: fadeInOpacity;\n animation-timing-function: ease-in;\n }\n .kol-tooltip__arrow {\n transform: rotate(45deg);\n color: #000;\n background-color: #fff;\n position: absolute;\n z-index: 999;\n width: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n height: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n }\n .kol-tooltip__content {\n color: #000;\n background-color: #fff;\n position: relative;\n z-index: 1000;\n }\n}\n@layer kol-component {\n .kol-card {\n /* Visible with forced colors */\n outline: transparent solid calc(1 * 1rem / var(--kolibri-root-font-size, 16));\n position: relative;\n height: 100%;\n }\n .kol-card__close-button {\n position: absolute;\n top: 0;\n right: 0;\n }\n}",KolCard$1=proxyCustomElement(class extends HTMLElement{constructor(n){super(),!1!==n&&this.__registerHost(),this.__attachShadow(),this._hasCloser=!1,this._level=0}render(){return h(KolCardWcTag,{key:"214de69b88f18259f7ea036d889fd6caab14a346",_on:this._on,_hasCloser:this._hasCloser,_label:this._label,_level:this._level},h("slot",{key:"671f44467a488eb8dedd4cdb36aaeeb33b6f8aea"}))}static get style(){return{default:defaultStyleCss}}},[289,"kol-card",{_on:[16],_hasCloser:[4,"_has-closer"],_label:[1],_level:[2]}]);function defineCustomElement$1(){if("undefined"==typeof customElements)return;["kol-card"].forEach(n=>{if("kol-card"===n)customElements.get(n)||customElements.define(n,KolCard$1)})}const KolCard=KolCard$1,defineCustomElement=defineCustomElement$1;export{KolCard,defineCustomElement};
4
+ import{proxyCustomElement,HTMLElement,h}from"@stencil/core/internal/client";import{g as KolCardWcTag}from"./component-names.js";const defaultStyleCss="/*\n* This file defines the layer order for all CSS layers used in KoliBri.\n* The order is important as it determines the cascade priority.\n*\n* Layer order (lowest to highest priority):\n* 1. kol-a11y - Accessibility defaults and requirements\n* 2. kol-global - Global component styles and resets\n* 3. kol-component - Component-specific styles\n* 4. kol-theme-global - Theme-specific global styles\n* 5. kol-theme-component - Theme-specific component styles\n*/\n@layer kol-a11y, kol-global, kol-component, kol-theme-global, kol-theme-component;\n/* forward the rem function */\n/*\n * This file contains all rules for accessibility.\n */\n@layer kol-a11y {\n :host {\n /*\n * Minimum size of interactive elements.\n */\n --a11y-min-size: calc(44 * 1rem / var(--kolibri-root-font-size, 16));\n /*\n * No element should be used without verifying the contrast ratio of its background and font colors.\n * By initially setting the background color to white and the font color to black,\n * the contrast ratio is ensured and explicit adjustment is forced.\n */\n color: black;\n background-color: white;\n /*\n * Verdana is an accessible font that can be used without requiring additional loading time.\n */\n font-family: Verdana;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n * {\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n hyphens: auto;\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n word-break: break-word;\n }\n /*\n * All interactive elements should have a minimum size of to-rem(44).\n */\n /* input:not([type='checkbox'], [type='radio'], [type='range']), */\n /* option, */\n /* select, */\n /* textarea, */\n button,\n .kol-input .input {\n min-width: var(--a11y-min-size);\n min-height: var(--a11y-min-size);\n }\n /*\n * Some interactive elements should not inherit the font-family and font-size.\n */\n a,\n button,\n h1,\n h2,\n h3,\n h4,\n h5,\n h6,\n input,\n option,\n select,\n textarea {\n /*\n * All elements should inherit the font family from his parent element.\n */\n font-family: inherit;\n /*\n * All elements should inherit the font size from his parent element.\n */\n font-size: inherit;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n /**\n * Sometimes we need the semantic element for accessibility reasons,\n * but we don't want to show it.\n *\n * - https://www.a11yproject.com/posts/how-to-hide-content/\n */\n .visually-hidden {\n position: fixed;\n top: 0;\n left: 0;\n width: 1px;\n height: 1px;\n overflow: hidden;\n white-space: nowrap;\n clip-path: inset(50%);\n }\n}\n@layer kol-global {\n /*\n * Dieses CSS stellt sicher, dass der Standard-Style\n * von A und Button resettet werden.\n */\n :is(a, button) {\n background-color: transparent;\n width: 100%;\n margin: 0;\n padding: 0;\n border: none;\n /* 100% needed for custom width from outside */\n }\n /*\n * Ensure elements with hidden attribute to be actually not visible\n * @see https://meowni.ca/hidden.is.a.lie.html\n */\n [hidden] {\n display: none !important;\n }\n .badge-text-hint {\n color: black;\n background-color: lightgray;\n }\n}\n@layer kol-global {\n :host {\n /*\n * The max-width is needed to prevent the table from overflowing the\n * parent node, if the table is wider than the parent node.\n */\n max-width: 100%;\n font-size: calc(16 * 1rem / var(--kolibri-root-font-size, 16));\n }\n * {\n /*\n * We prefer to box-sizing: border-box for all elements.\n */\n box-sizing: border-box;\n }\n .kol-span {\n /* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n display: grid;\n place-items: center;\n /* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n }\n .kol-span__container {\n display: flex;\n place-items: center;\n }\n a,\n button {\n cursor: pointer;\n }\n .kol-span .kol-span__label--hide-label .kol-span__label {\n display: none;\n }\n /* Reset browser agent style. */\n button:disabled {\n color: unset;\n }\n .disabled label,\n .disabled:focus-within label,\n [aria-disabled=true],\n [aria-disabled=true]:focus,\n [disabled],\n [disabled]:focus {\n opacity: 0.5;\n outline: none;\n cursor: not-allowed;\n }\n [aria-disabled=true]:focus .kol-span,\n [disabled]:focus .kol-span {\n outline: none !important;\n }\n}\n@layer kol-component {\n @keyframes fadeInOpacity {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n }\n .kol-tooltip {\n display: contents;\n }\n .kol-tooltip__floating {\n display: none;\n position: fixed;\n /* Avoid layout interference - see https://floating-ui.com/docs/computePosition */\n top: 0;\n left: 0;\n /* Can be used to specify the tooltip-width from the outside. Unset by default. */\n width: var(--kol-tooltip-width, max-content);\n min-width: calc(8 * 1rem / var(--kolibri-root-font-size, 16));\n max-width: 90vw;\n max-height: 90vh;\n visibility: hidden;\n animation-duration: 0.25s;\n animation-iteration-count: 1;\n animation-name: fadeInOpacity;\n animation-timing-function: ease-in;\n }\n .kol-tooltip__arrow {\n transform: rotate(45deg);\n color: #000;\n background-color: #fff;\n position: absolute;\n z-index: 999;\n width: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n height: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n }\n .kol-tooltip__content {\n color: #000;\n background-color: #fff;\n position: relative;\n z-index: 1000;\n }\n}\n@layer kol-component {\n .kol-card {\n /* Visible with forced colors */\n outline: transparent solid calc(1 * 1rem / var(--kolibri-root-font-size, 16));\n position: relative;\n height: 100%;\n }\n .kol-card__close-button {\n position: absolute;\n top: 0;\n right: 0;\n }\n}",KolCard$1=proxyCustomElement(class extends HTMLElement{constructor(n){super(),!1!==n&&this.__registerHost(),this.__attachShadow(),this._hasCloser=!1,this._level=0}render(){return h(KolCardWcTag,{key:"db950a543bc2f41a1e0786c9ac3d4cb0fce5cf97",_on:this._on,_hasCloser:this._hasCloser,_label:this._label,_level:this._level},h("slot",{key:"f7ad1dd60427b5e2ae00f0e2260309a025d1ed44"}))}static get style(){return{default:defaultStyleCss}}},[289,"kol-card",{_on:[16],_hasCloser:[4,"_has-closer"],_label:[1],_level:[2]}]);function defineCustomElement$1(){if("undefined"==typeof customElements)return;["kol-card"].forEach(n=>{if("kol-card"===n)customElements.get(n)||customElements.define(n,KolCard$1)})}const KolCard=KolCard$1,defineCustomElement=defineCustomElement$1;export{KolCard,defineCustomElement};
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{proxyCustomElement,HTMLElement,h}from"@stencil/core/internal/client";import{c as clsx}from"./clsx.js";import{g as getRenderStates,F as FormFieldStateWrapper}from"./controller2.js";import{I as InputIconController,a as InputContainerStateWrapperFc}from"./controller-icon.js";import{I as InputStateWrapper}from"./InputStateWrapper.js";import{C as CustomSuggestionsToggleFc,a as CustomSuggestionsOptionsGroupFc,b as CustomSuggestionsOptionFc}from"./CustomSuggestionsToggle.js";import{n as nonce}from"./dev.utils.js";import{h as watchString}from"./common.js";import{v as validatePlaceholder}from"./placeholder.js";import{v as validateRequired}from"./required.js";import{v as validateSuggestions}from"./suggestions.js";class ComboboxController extends InputIconController{constructor(e,t,n){super(e,t,n),this.component=e}validatePlaceholder(e){validatePlaceholder(this.component,e)}validateRequired(e){validateRequired(this.component,e)}validateSuggestions(e){validateSuggestions(this.component,e)}validateValue(e){watchString(this.component,"_value",e)}componentWillLoad(){super.componentWillLoad(),this.validatePlaceholder(this.component._placeholder),this.validateRequired(this.component._required),this.validateSuggestions(this.component._suggestions),this.validateValue(this.component._value)}}const defaultStyleCss="/*\n* This file defines the layer order for all CSS layers used in KoliBri.\n* The order is important as it determines the cascade priority.\n*\n* Layer order (lowest to highest priority):\n* 1. kol-a11y - Accessibility defaults and requirements\n* 2. kol-global - Global component styles and resets\n* 3. kol-component - Component-specific styles\n* 4. kol-theme-global - Theme-specific global styles\n* 5. kol-theme-component - Theme-specific component styles\n*/\n@layer kol-a11y, kol-global, kol-component, kol-theme-global, kol-theme-component;\n/* forward the rem function */\n/*\n * This file contains all rules for accessibility.\n */\n@layer kol-a11y {\n :host {\n /*\n * Minimum size of interactive elements.\n */\n --a11y-min-size: calc(44 * 1rem / var(--kolibri-root-font-size, 16));\n /*\n * No element should be used without verifying the contrast ratio of its background and font colors.\n * By initially setting the background color to white and the font color to black,\n * the contrast ratio is ensured and explicit adjustment is forced.\n */\n color: black;\n background-color: white;\n /*\n * Verdana is an accessible font that can be used without requiring additional loading time.\n */\n font-family: Verdana;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n * {\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n hyphens: auto;\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n word-break: break-word;\n }\n /*\n * All interactive elements should have a minimum size of to-rem(44).\n */\n /* input:not([type='checkbox'], [type='radio'], [type='range']), */\n /* option, */\n /* select, */\n /* textarea, */\n button,\n .kol-input .input {\n min-width: var(--a11y-min-size);\n min-height: var(--a11y-min-size);\n }\n /*\n * Some interactive elements should not inherit the font-family and font-size.\n */\n a,\n button,\n h1,\n h2,\n h3,\n h4,\n h5,\n h6,\n input,\n option,\n select,\n textarea {\n /*\n * All elements should inherit the font family from his parent element.\n */\n font-family: inherit;\n /*\n * All elements should inherit the font size from his parent element.\n */\n font-size: inherit;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n /**\n * Sometimes we need the semantic element for accessibility reasons,\n * but we don't want to show it.\n *\n * - https://www.a11yproject.com/posts/how-to-hide-content/\n */\n .visually-hidden {\n position: fixed;\n top: 0;\n left: 0;\n width: 1px;\n height: 1px;\n overflow: hidden;\n white-space: nowrap;\n clip-path: inset(50%);\n }\n}\n@layer kol-global {\n /*\n * Dieses CSS stellt sicher, dass der Standard-Style\n * von A und Button resettet werden.\n */\n :is(a, button) {\n background-color: transparent;\n width: 100%;\n margin: 0;\n padding: 0;\n border: none;\n /* 100% needed for custom width from outside */\n }\n /*\n * Ensure elements with hidden attribute to be actually not visible\n * @see https://meowni.ca/hidden.is.a.lie.html\n */\n [hidden] {\n display: none !important;\n }\n .badge-text-hint {\n color: black;\n background-color: lightgray;\n }\n}\n@layer kol-global {\n :host {\n /*\n * The max-width is needed to prevent the table from overflowing the\n * parent node, if the table is wider than the parent node.\n */\n max-width: 100%;\n font-size: calc(16 * 1rem / var(--kolibri-root-font-size, 16));\n }\n * {\n /*\n * We prefer to box-sizing: border-box for all elements.\n */\n box-sizing: border-box;\n }\n .kol-span {\n /* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n display: grid;\n place-items: center;\n /* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n }\n .kol-span__container {\n display: flex;\n place-items: center;\n }\n a,\n button {\n cursor: pointer;\n }\n .kol-span .kol-span__label--hide-label .kol-span__label {\n display: none;\n }\n /* Reset browser agent style. */\n button:disabled {\n color: unset;\n }\n .disabled label,\n .disabled:focus-within label,\n [aria-disabled=true],\n [aria-disabled=true]:focus,\n [disabled],\n [disabled]:focus {\n opacity: 0.5;\n outline: none;\n cursor: not-allowed;\n }\n [aria-disabled=true]:focus .kol-span,\n [disabled]:focus .kol-span {\n outline: none !important;\n }\n}\n@layer kol-component {\n :host {\n display: block;\n }\n}\n@layer kol-component {\n @keyframes fadeInOpacity {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n }\n .kol-tooltip {\n display: contents;\n }\n .kol-tooltip__floating {\n display: none;\n position: fixed;\n /* Avoid layout interference - see https://floating-ui.com/docs/computePosition */\n top: 0;\n left: 0;\n /* Can be used to specify the tooltip-width from the outside. Unset by default. */\n width: var(--kol-tooltip-width, max-content);\n min-width: calc(8 * 1rem / var(--kolibri-root-font-size, 16));\n max-width: 90vw;\n max-height: 90vh;\n visibility: hidden;\n animation-duration: 0.25s;\n animation-iteration-count: 1;\n animation-name: fadeInOpacity;\n animation-timing-function: ease-in;\n }\n .kol-tooltip__arrow {\n transform: rotate(45deg);\n color: #000;\n background-color: #fff;\n position: absolute;\n z-index: 999;\n width: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n height: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n }\n .kol-tooltip__content {\n color: #000;\n background-color: #fff;\n position: relative;\n z-index: 1000;\n }\n}\n@layer kol-component {\n .kol-alert {\n display: grid;\n }\n .kol-alert__container {\n display: flex;\n place-items: center;\n }\n .kol-alert__container-content {\n flex-grow: 1;\n }\n .kol-alert__closer {\n /* Visible with forced colors */\n outline: transparent solid calc(1 * 1rem / var(--kolibri-root-font-size, 16));\n }\n .kol-custom-suggestions-option {\n line-height: 1.5;\n white-space: normal;\n cursor: pointer;\n overflow-wrap: break-word;\n }\n .kol-custom-suggestions-options-group--cursor-hidden .kol-custom-suggestions-option {\n cursor: none !important;\n }\n .kol-custom-suggestions-options-group {\n background-color: white;\n display: block;\n position: absolute;\n z-index: 2;\n max-height: calc(250 * 1rem / var(--kolibri-root-font-size, 16));\n margin: 0;\n padding: 0;\n overflow-x: hidden;\n overflow-y: auto;\n list-style-type: none;\n }\n .kol-custom-suggestions-toggle {\n display: flex;\n width: var(--a11y-min-size);\n height: var(--a11y-min-size);\n align-items: center;\n }\n .kol-custom-suggestions-toggle:not(:disabled) {\n cursor: pointer;\n }\n .kol-form-field {\n display: grid;\n }\n .kol-form-field:not(.kol-form-field--disabled) .kol-form-field__label {\n cursor: pointer;\n }\n .kol-form-field--disabled .kol-form-field__label {\n opacity: 0.5;\n }\n .kol-form-field--required .kol-form-field__label-text::after {\n content: \"*\";\n }\n .kol-form-field--disabled .kol-form-field__hint {\n opacity: 0.5;\n }\n .kol-form-field--required .kol-form-field__tooltip .span-label::after {\n content: \"*\";\n }\n .kol-input-container {\n background-color: white;\n display: grid;\n width: 100%;\n min-width: var(--a11y-min-size);\n min-height: var(--a11y-min-size);\n align-items: center;\n grid-template-columns: 1fr;\n }\n .kol-input-container:has(> .kol-input-container__adornment--start) {\n grid-template-columns: auto 1fr;\n }\n .kol-input-container:has(> .kol-input-container__adornment--end) {\n grid-template-columns: 1fr auto;\n }\n .kol-input-container:has(> .kol-input-container__adornment--start):has(> .kol-input-container__adornment--end) {\n grid-template-columns: auto 1fr auto;\n }\n .kol-input-container__container {\n position: relative;\n }\n .kol-input-container__adornment {\n display: flex;\n align-items: center;\n }\n .kol-input-container__adornment .kol-icon {\n display: grid;\n height: var(--a11y-min-size);\n place-items: center;\n }\n .kol-input {\n width: 100%;\n min-width: var(--a11y-min-size);\n }\n .kol-input:focus {\n outline: none;\n }\n}",KolCombobox$1=proxyCustomElement(class extends HTMLElement{async getValue(){return this.state._value}async kolFocus(){var e;null===(e=this.refInput)||void 0===e||e.focus()}selectOption(e){var t;this.controller.onFacade.onInput(new CustomEvent("input",{bubbles:!0,detail:{name:this.state._name,value:e}}),!0,e),this.controller.onFacade.onChange(new CustomEvent("change",{bubbles:!0,detail:{name:this.state._name,value:e}}),e),this.controller.setFormAssociatedValue(e),this.state._value=e,null===(t=this.refInput)||void 0===t||t.focus()}onInput(e){const t=e.target;this.state._value=t.value,this._value=t.value,this.controller.onFacade.onInput(e),this.setFilteredSuggestionsByQuery(t.value),this._focusedOptionIndex=-1}handleKeyDownDropdown(e){1===e.key.length&&/[a-z0-9]/i.test(e.key)&&(this._isOpen=!0,this.focusSuggestionStartingWith(e.key))}setFilteredSuggestionsByQuery(e){""===e.trim()?this._filteredSuggestions=[...this._suggestions]:(this._filteredSuggestions=Array.isArray(this._suggestions)?this._suggestions.filter(t=>t.toLowerCase().includes(e.toLowerCase())):this._filteredSuggestions,this._isOpen=!!(this._filteredSuggestions&&this._filteredSuggestions.length>0))}moveFocus(e){if(!this._filteredSuggestions)return;let t=this._focusedOptionIndex+e;t>=this._filteredSuggestions.length&&(t=0),t<0&&(t=this._filteredSuggestions.length-1),this.focusOption(t)}focusOption(e){if(this._focusedOptionIndex=e,this.refSuggestions){const t=this.refSuggestions[e];null==t||t.focus()}}focusSuggestionStartingWith(e){const t=e.toLowerCase(),n=Array.isArray(this._filteredSuggestions)&&this._filteredSuggestions.length>0&&this._filteredSuggestions.findIndex(e=>e.toLowerCase().startsWith(t));"number"==typeof n&&this.focusOption(n)}getFormFieldProps(){return{state:this.state,class:clsx("kol-combobox",{"has-value":this.state._hasValue}),tooltipAlign:this._tooltipAlign,onClick:()=>{var e;return null===(e=this.refInput)||void 0===e?void 0:e.focus()},alert:this.showAsAlert()}}getInputProps(){const{ariaDescribedBy:e}=getRenderStates(this.state),t=!0===this.state._disabled;return Object.assign(Object.assign({ref:this.catchRef,state:this.state,class:"kol-combobox__input",type:"text",role:"combobox","aria-activedescendant":this._isOpen&&this._focusedOptionIndex>=0?`option-${this._focusedOptionIndex}`:void 0,"aria-autocomplete":"both","aria-controls":"listbox","aria-describedby":e.length>0?e.join(" "):void 0,"aria-expanded":this._isOpen?"true":"false","aria-label":this.state._hideLabel&&"string"==typeof this.state._label?this.state._label:void 0,"aria-labelledby":this.state._id,"aria-keyshortcuts":this.state._shortKey,value:this.state._value,accessKey:this.state._accessKey,autocapitalize:"off",autocorrect:"off",disabled:t,customSuggestions:!0,id:this.state._id,name:this.state._name,required:this.state._required},this.controller.onFacade),{onFocus:e=>{this.controller.onFacade.onFocus(e),this.inputHasFocus=!0},onBlur:e=>{this.controller.onFacade.onBlur(e),this.inputHasFocus=!1},onChange:this.onChange.bind(this),onInput:this.onInput.bind(this),placeholder:this.state._placeholder})}render(){const e=!0===this.state._disabled;return h(FormFieldStateWrapper,Object.assign({key:"eb15fe58d236a7f992976c4d35e004996c1fcd4e"},this.getFormFieldProps()),h(InputContainerStateWrapperFc,{key:"80c19ad381816ef88948ac29b48fb64dc407cf29",state:this.state},h("div",{key:"96a9ea7656090a0e10024d6cc0b44e182238b217",class:"kol-combobox__group"},h(InputStateWrapper,Object.assign({key:"1f79a7c35437e4357b296118ce7ab45166966cb5"},this.getInputProps())),h(CustomSuggestionsToggleFc,{key:"5741846ebde26e7eb4cb7d7d557084c028193a8c",onClick:this.toggleListbox.bind(this),disabled:e})),this._isOpen&&!e&&h(CustomSuggestionsOptionsGroupFc,{key:"2e8c160d9ada3feb752d4efcdb2e3b281a6d7269",blockSuggestionMouseOver:this.blockSuggestionMouseOver,onKeyDown:this.handleKeyDownDropdown.bind(this)},Array.isArray(this._filteredSuggestions)&&this._filteredSuggestions.length>0&&this._filteredSuggestions.map((e,t)=>h(CustomSuggestionsOptionFc,{index:t,option:e,searchTerm:this.state._value,ref:e=>{e&&(this.refSuggestions[t]=e)},selected:this.state._value===e,onClick:()=>{this.selectOption(e),this.toggleListbox(),this._isOpen=!1,this._hasOpened=!1},onMouseOver:()=>{this.blockSuggestionMouseOver||this.focusOption(t)},onFocus:()=>{this.focusOption(t)},onKeyDown:t=>{"Enter"!==t.key&&"NumpadEnter"!==t.key||(this.selectOption(e),this.toggleListbox(),t.preventDefault())}})))))}handleKeyDown(e){var t,n;const i=(t,n)=>{var i;e.preventDefault(),void 0!==t&&(this._isOpen=t,t||null===(i=this.refInput)||void 0===i||i.focus()),null==n||n()};switch(e.key){case"Down":case"ArrowDown":this.blockSuggestionMouseOver=!0,i(!0,()=>this.moveFocus(1));break;case"Up":case"ArrowUp":this.blockSuggestionMouseOver=!0,i(!0,()=>this.moveFocus(-1));break;case"Tab":this._isOpen&&(this._isOpen=!1,null===(t=this.refInput)||void 0===t||t.focus());break;case"Esc":case"Escape":this._hasOpened=!1,this._isOpen=!1,e.preventDefault(),null===(n=this.refInput)||void 0===n||n.focus();break;case"NumpadEnter":case"Enter":this._isOpen&&this._focusedOptionIndex>=0?(this._filteredSuggestions&&this.selectOption(this._filteredSuggestions[this._focusedOptionIndex]),this._isOpen=!1,this._hasOpened=!1):this.toggleListbox(),e.preventDefault();break;case"Home":this.blockSuggestionMouseOver=!0,i(void 0,()=>{this._isOpen&&this.focusOption(0)});break;case"End":this.blockSuggestionMouseOver=!0,i(void 0,()=>{this._isOpen&&this.focusOption(this._filteredSuggestions?this._filteredSuggestions.length-1:0)});break;case"PageUp":this.blockSuggestionMouseOver=!0,i(void 0,()=>this._isOpen&&this.moveFocus(-10));break;case"PageDown":this.blockSuggestionMouseOver=!0,i(void 0,()=>this._isOpen&&this.moveFocus(10))}}handleWindowClick(e){void 0===this.host||this.host.contains(e.target)||(this._isOpen=!1)}constructor(e){super(),!1!==e&&this.__registerHost(),this.__attachShadow(),this.refSuggestions=[],this._focusedOptionIndex=-1,this.toggleListbox=()=>{var e;if(!0===this.state._disabled)this._isOpen=!1;else if(null===(e=this.refInput)||void 0===e||e.focus(),!this._hasOpened&&Array.isArray(this._filteredSuggestions)&&this._filteredSuggestions.length>0){this._isOpen=!0,this._hasOpened=!0;const e=this._filteredSuggestions.findIndex(e=>e===this.state._value);this._focusedOptionIndex=e>=0?e:-1,this.focusOption(this._focusedOptionIndex)}},this.catchRef=e=>{this.refInput=e},this.blockSuggestionMouseOver=!1,this._isOpen=!1,this._hasOpened=!1,this._disabled=!1,this._hideMsg=!1,this._hideLabel=!1,this._hint="",this._required=!1,this._tooltipAlign="top",this._touched=!1,this.state={_hasValue:!1,_hideMsg:!1,_id:`id-${nonce()}`,_label:"",_suggestions:[],_value:""},this.inputHasFocus=!1,this.controller=new ComboboxController(this,"combobox",this.host),this.onInput=this.onInput.bind(this)}showAsAlert(){return Boolean(this.state._touched)&&!this.inputHasFocus}validatePlaceholder(e){this.controller.validatePlaceholder(e)}validateAccessKey(e){this.controller.validateAccessKey(e)}validateDisabled(e){this.controller.validateDisabled(e)}validateHideMsg(e){this.controller.validateHideMsg(e)}validateHideLabel(e){this.controller.validateHideLabel(e)}validateHint(e){this.controller.validateHint(e)}validateIcons(e){this.controller.validateIcons(e)}validateId(e){this.controller.validateId(e)}validateLabel(e){this.controller.validateLabel(e)}validateMsg(e){this.controller.validateMsg(e)}validateName(e){this.controller.validateName(e)}validateOn(e){this.controller.validateOn(e)}validateShortKey(e){this.controller.validateShortKey(e)}validateSuggestions(e){this.controller.validateSuggestions(e),this._filteredSuggestions=e}validateRequired(e){this.controller.validateRequired(e)}validateSyncValueBySelector(e){this.controller.validateSyncValueBySelector(e)}validateTouched(e){this.controller.validateTouched(e)}validateValue(e){this.controller.validateValue(e),this.controller.setFormAssociatedValue(e)}componentWillLoad(){this.refSuggestions=[],this._touched=!0===this._touched,this.controller.componentWillLoad(),this.state._hasValue=!!this.state._value,this.controller.addValueChangeListener(e=>this.state._hasValue=!!e),this._filteredSuggestions=this.state._suggestions}handleMouseEvent(){this.blockSuggestionMouseOver=!1}handleFocusOut(){setTimeout(()=>{var e;(null===(e=this.host)||void 0===e?void 0:e.contains(document.activeElement))||this.onBlur()},0)}handleWindowBlur(){this.onBlur()}onBlur(){var e;this._hasOpened=!1,this._isOpen&&(this._isOpen=!this._isOpen,null===(e=this.refInput)||void 0===e||e.focus())}onChange(e){this.controller.onFacade.onChange(e),this.controller.setFormAssociatedValue(this.state._value)}static get delegatesFocus(){return!0}get host(){return this}static get watchers(){return{_placeholder:["validatePlaceholder"],_accessKey:["validateAccessKey"],_disabled:["validateDisabled"],_hideMsg:["validateHideMsg"],_hideLabel:["validateHideLabel"],_hint:["validateHint"],_icons:["validateIcons"],_id:["validateId"],_label:["validateLabel"],_msg:["validateMsg"],_name:["validateName"],_on:["validateOn"],_shortKey:["validateShortKey"],_suggestions:["validateSuggestions"],_required:["validateRequired"],_syncValueBySelector:["validateSyncValueBySelector"],_touched:["validateTouched"],_value:["validateValue"]}}static get style(){return{default:defaultStyleCss}}},[305,"kol-combobox",{_accessKey:[1,"_access-key"],_placeholder:[1],_disabled:[4],_hideMsg:[4,"_hide-msg"],_hideLabel:[4,"_hide-label"],_hint:[1],_icons:[1],_id:[1],_label:[1],_msg:[1],_name:[1],_on:[16],_suggestions:[1],_required:[4],_shortKey:[1,"_short-key"],_syncValueBySelector:[1,"_sync-value-by-selector"],_tooltipAlign:[1,"_tooltip-align"],_touched:[1540],_value:[1537],blockSuggestionMouseOver:[32],_isOpen:[32],_filteredSuggestions:[32],_hasOpened:[32],state:[32],inputHasFocus:[32],getValue:[64],kolFocus:[64]},[[0,"keydown","handleKeyDown"],[8,"click","handleWindowClick"],[1,"mousemove","handleMouseEvent"],[8,"focusout","handleFocusOut"],[8,"blur","handleWindowBlur"]],{_placeholder:["validatePlaceholder"],_accessKey:["validateAccessKey"],_disabled:["validateDisabled"],_hideMsg:["validateHideMsg"],_hideLabel:["validateHideLabel"],_hint:["validateHint"],_icons:["validateIcons"],_id:["validateId"],_label:["validateLabel"],_msg:["validateMsg"],_name:["validateName"],_on:["validateOn"],_shortKey:["validateShortKey"],_suggestions:["validateSuggestions"],_required:["validateRequired"],_syncValueBySelector:["validateSyncValueBySelector"],_touched:["validateTouched"],_value:["validateValue"]}]);function defineCustomElement$1(){if("undefined"==typeof customElements)return;["kol-combobox"].forEach(e=>{if("kol-combobox"===e)customElements.get(e)||customElements.define(e,KolCombobox$1)})}const KolCombobox=KolCombobox$1,defineCustomElement=defineCustomElement$1;export{KolCombobox,defineCustomElement};
4
+ import{proxyCustomElement,HTMLElement,h}from"@stencil/core/internal/client";import{c as clsx}from"./clsx.js";import{g as getRenderStates,F as FormFieldStateWrapper}from"./controller2.js";import{I as InputIconController,a as InputContainerStateWrapperFc}from"./controller-icon.js";import{I as InputStateWrapper}from"./InputStateWrapper.js";import{C as CustomSuggestionsToggleFc,a as CustomSuggestionsOptionsGroupFc,b as CustomSuggestionsOptionFc}from"./CustomSuggestionsToggle.js";import{n as nonce}from"./dev.utils.js";import{h as watchString}from"./common.js";import{v as validatePlaceholder}from"./placeholder.js";import{v as validateRequired}from"./required.js";import{v as validateSuggestions}from"./suggestions.js";class ComboboxController extends InputIconController{constructor(e,t,n){super(e,t,n),this.component=e}validatePlaceholder(e){validatePlaceholder(this.component,e)}validateRequired(e){validateRequired(this.component,e)}validateSuggestions(e){validateSuggestions(this.component,e)}validateValue(e){watchString(this.component,"_value",e)}componentWillLoad(){super.componentWillLoad(),this.validatePlaceholder(this.component._placeholder),this.validateRequired(this.component._required),this.validateSuggestions(this.component._suggestions),this.validateValue(this.component._value)}}const defaultStyleCss="/*\n* This file defines the layer order for all CSS layers used in KoliBri.\n* The order is important as it determines the cascade priority.\n*\n* Layer order (lowest to highest priority):\n* 1. kol-a11y - Accessibility defaults and requirements\n* 2. kol-global - Global component styles and resets\n* 3. kol-component - Component-specific styles\n* 4. kol-theme-global - Theme-specific global styles\n* 5. kol-theme-component - Theme-specific component styles\n*/\n@layer kol-a11y, kol-global, kol-component, kol-theme-global, kol-theme-component;\n/* forward the rem function */\n/*\n * This file contains all rules for accessibility.\n */\n@layer kol-a11y {\n :host {\n /*\n * Minimum size of interactive elements.\n */\n --a11y-min-size: calc(44 * 1rem / var(--kolibri-root-font-size, 16));\n /*\n * No element should be used without verifying the contrast ratio of its background and font colors.\n * By initially setting the background color to white and the font color to black,\n * the contrast ratio is ensured and explicit adjustment is forced.\n */\n color: black;\n background-color: white;\n /*\n * Verdana is an accessible font that can be used without requiring additional loading time.\n */\n font-family: Verdana;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n * {\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n hyphens: auto;\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n word-break: break-word;\n }\n /*\n * All interactive elements should have a minimum size of to-rem(44).\n */\n /* input:not([type='checkbox'], [type='radio'], [type='range']), */\n /* option, */\n /* select, */\n /* textarea, */\n button,\n .kol-input .input {\n min-width: var(--a11y-min-size);\n min-height: var(--a11y-min-size);\n }\n /*\n * Some interactive elements should not inherit the font-family and font-size.\n */\n a,\n button,\n h1,\n h2,\n h3,\n h4,\n h5,\n h6,\n input,\n option,\n select,\n textarea {\n /*\n * All elements should inherit the font family from his parent element.\n */\n font-family: inherit;\n /*\n * All elements should inherit the font size from his parent element.\n */\n font-size: inherit;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n /**\n * Sometimes we need the semantic element for accessibility reasons,\n * but we don't want to show it.\n *\n * - https://www.a11yproject.com/posts/how-to-hide-content/\n */\n .visually-hidden {\n position: fixed;\n top: 0;\n left: 0;\n width: 1px;\n height: 1px;\n overflow: hidden;\n white-space: nowrap;\n clip-path: inset(50%);\n }\n}\n@layer kol-global {\n /*\n * Dieses CSS stellt sicher, dass der Standard-Style\n * von A und Button resettet werden.\n */\n :is(a, button) {\n background-color: transparent;\n width: 100%;\n margin: 0;\n padding: 0;\n border: none;\n /* 100% needed for custom width from outside */\n }\n /*\n * Ensure elements with hidden attribute to be actually not visible\n * @see https://meowni.ca/hidden.is.a.lie.html\n */\n [hidden] {\n display: none !important;\n }\n .badge-text-hint {\n color: black;\n background-color: lightgray;\n }\n}\n@layer kol-global {\n :host {\n /*\n * The max-width is needed to prevent the table from overflowing the\n * parent node, if the table is wider than the parent node.\n */\n max-width: 100%;\n font-size: calc(16 * 1rem / var(--kolibri-root-font-size, 16));\n }\n * {\n /*\n * We prefer to box-sizing: border-box for all elements.\n */\n box-sizing: border-box;\n }\n .kol-span {\n /* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n display: grid;\n place-items: center;\n /* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n }\n .kol-span__container {\n display: flex;\n place-items: center;\n }\n a,\n button {\n cursor: pointer;\n }\n .kol-span .kol-span__label--hide-label .kol-span__label {\n display: none;\n }\n /* Reset browser agent style. */\n button:disabled {\n color: unset;\n }\n .disabled label,\n .disabled:focus-within label,\n [aria-disabled=true],\n [aria-disabled=true]:focus,\n [disabled],\n [disabled]:focus {\n opacity: 0.5;\n outline: none;\n cursor: not-allowed;\n }\n [aria-disabled=true]:focus .kol-span,\n [disabled]:focus .kol-span {\n outline: none !important;\n }\n}\n@layer kol-component {\n :host {\n display: block;\n }\n}\n@layer kol-component {\n @keyframes fadeInOpacity {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n }\n .kol-tooltip {\n display: contents;\n }\n .kol-tooltip__floating {\n display: none;\n position: fixed;\n /* Avoid layout interference - see https://floating-ui.com/docs/computePosition */\n top: 0;\n left: 0;\n /* Can be used to specify the tooltip-width from the outside. Unset by default. */\n width: var(--kol-tooltip-width, max-content);\n min-width: calc(8 * 1rem / var(--kolibri-root-font-size, 16));\n max-width: 90vw;\n max-height: 90vh;\n visibility: hidden;\n animation-duration: 0.25s;\n animation-iteration-count: 1;\n animation-name: fadeInOpacity;\n animation-timing-function: ease-in;\n }\n .kol-tooltip__arrow {\n transform: rotate(45deg);\n color: #000;\n background-color: #fff;\n position: absolute;\n z-index: 999;\n width: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n height: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n }\n .kol-tooltip__content {\n color: #000;\n background-color: #fff;\n position: relative;\n z-index: 1000;\n }\n}\n@layer kol-component {\n .kol-alert {\n display: grid;\n }\n .kol-alert__container {\n display: flex;\n place-items: center;\n }\n .kol-alert__container-content {\n flex-grow: 1;\n }\n .kol-alert__closer {\n /* Visible with forced colors */\n outline: transparent solid calc(1 * 1rem / var(--kolibri-root-font-size, 16));\n }\n .kol-custom-suggestions-option {\n line-height: 1.5;\n white-space: normal;\n cursor: pointer;\n overflow-wrap: break-word;\n }\n .kol-custom-suggestions-options-group--cursor-hidden .kol-custom-suggestions-option {\n cursor: none !important;\n }\n .kol-custom-suggestions-options-group {\n background-color: white;\n display: block;\n position: absolute;\n z-index: 2;\n max-height: calc(250 * 1rem / var(--kolibri-root-font-size, 16));\n margin: 0;\n padding: 0;\n overflow-x: hidden;\n overflow-y: auto;\n list-style-type: none;\n }\n .kol-custom-suggestions-toggle {\n display: flex;\n width: var(--a11y-min-size);\n height: var(--a11y-min-size);\n align-items: center;\n }\n .kol-custom-suggestions-toggle:not(:disabled) {\n cursor: pointer;\n }\n .kol-form-field {\n display: grid;\n }\n .kol-form-field:not(.kol-form-field--disabled) .kol-form-field__label {\n cursor: pointer;\n }\n .kol-form-field--disabled .kol-form-field__label {\n opacity: 0.5;\n }\n .kol-form-field--required .kol-form-field__label-text::after {\n content: \"*\";\n }\n .kol-form-field--disabled .kol-form-field__hint {\n opacity: 0.5;\n }\n .kol-form-field--required .kol-form-field__tooltip .span-label::after {\n content: \"*\";\n }\n .kol-input-container {\n background-color: white;\n display: grid;\n width: 100%;\n min-width: var(--a11y-min-size);\n min-height: var(--a11y-min-size);\n align-items: center;\n grid-template-columns: 1fr;\n }\n .kol-input-container:has(> .kol-input-container__adornment--start) {\n grid-template-columns: auto 1fr;\n }\n .kol-input-container:has(> .kol-input-container__adornment--end) {\n grid-template-columns: 1fr auto;\n }\n .kol-input-container:has(> .kol-input-container__adornment--start):has(> .kol-input-container__adornment--end) {\n grid-template-columns: auto 1fr auto;\n }\n .kol-input-container__container {\n position: relative;\n }\n .kol-input-container__adornment {\n display: flex;\n align-items: center;\n }\n .kol-input-container__adornment .kol-icon {\n display: grid;\n height: var(--a11y-min-size);\n place-items: center;\n }\n .kol-input {\n width: 100%;\n min-width: var(--a11y-min-size);\n }\n .kol-input:focus {\n outline: none;\n }\n}",KolCombobox$1=proxyCustomElement(class extends HTMLElement{async getValue(){return this.state._value}async kolFocus(){var e;null===(e=this.refInput)||void 0===e||e.focus()}selectOption(e){var t;this.controller.onFacade.onInput(new CustomEvent("input",{bubbles:!0,detail:{name:this.state._name,value:e}}),!0,e),this.controller.onFacade.onChange(new CustomEvent("change",{bubbles:!0,detail:{name:this.state._name,value:e}}),e),this.controller.setFormAssociatedValue(e),this.state._value=e,null===(t=this.refInput)||void 0===t||t.focus()}onInput(e){const t=e.target;this.state._value=t.value,this._value=t.value,this.controller.onFacade.onInput(e),this.setFilteredSuggestionsByQuery(t.value),this._focusedOptionIndex=-1}handleKeyDownDropdown(e){1===e.key.length&&/[a-z0-9]/i.test(e.key)&&(this._isOpen=!0,this.focusSuggestionStartingWith(e.key))}setFilteredSuggestionsByQuery(e){""===e.trim()?this._filteredSuggestions=[...this._suggestions]:(this._filteredSuggestions=Array.isArray(this._suggestions)?this._suggestions.filter(t=>t.toLowerCase().includes(e.toLowerCase())):this._filteredSuggestions,this._isOpen=!!(this._filteredSuggestions&&this._filteredSuggestions.length>0))}moveFocus(e){if(!this._filteredSuggestions)return;let t=this._focusedOptionIndex+e;t>=this._filteredSuggestions.length&&(t=0),t<0&&(t=this._filteredSuggestions.length-1),this.focusOption(t)}focusOption(e){if(this._focusedOptionIndex=e,this.refSuggestions){const t=this.refSuggestions[e];null==t||t.focus()}}focusSuggestionStartingWith(e){const t=e.toLowerCase(),n=Array.isArray(this._filteredSuggestions)&&this._filteredSuggestions.length>0&&this._filteredSuggestions.findIndex(e=>e.toLowerCase().startsWith(t));"number"==typeof n&&this.focusOption(n)}getFormFieldProps(){return{state:this.state,class:clsx("kol-combobox",{"has-value":this.state._hasValue}),tooltipAlign:this._tooltipAlign,onClick:()=>{var e;return null===(e=this.refInput)||void 0===e?void 0:e.focus()},alert:this.showAsAlert()}}getInputProps(){const{ariaDescribedBy:e}=getRenderStates(this.state),t=!0===this.state._disabled;return Object.assign(Object.assign({ref:this.catchRef,state:this.state,class:"kol-combobox__input",type:"text",role:"combobox","aria-activedescendant":this._isOpen&&this._focusedOptionIndex>=0?`option-${this._focusedOptionIndex}`:void 0,"aria-autocomplete":"both","aria-controls":"listbox","aria-describedby":e.length>0?e.join(" "):void 0,"aria-expanded":this._isOpen?"true":"false","aria-label":this.state._hideLabel&&"string"==typeof this.state._label?this.state._label:void 0,"aria-labelledby":this.state._id,"aria-keyshortcuts":this.state._shortKey,value:this.state._value,accessKey:this.state._accessKey,autocapitalize:"off",autocorrect:"off",disabled:t,customSuggestions:!0,id:this.state._id,name:this.state._name,required:this.state._required},this.controller.onFacade),{onFocus:e=>{this.controller.onFacade.onFocus(e),this.inputHasFocus=!0},onBlur:e=>{this.controller.onFacade.onBlur(e),this.inputHasFocus=!1},onChange:this.onChange.bind(this),onInput:this.onInput.bind(this),placeholder:this.state._placeholder})}render(){const e=!0===this.state._disabled;return h(FormFieldStateWrapper,Object.assign({key:"b5a6f7b326f51416cc1c1c5791cef34552433327"},this.getFormFieldProps()),h(InputContainerStateWrapperFc,{key:"801cdf53218006019828f3328f0eccfccacc1132",state:this.state},h("div",{key:"354db1547eba447cddefb456802b512efc807d54",class:"kol-combobox__group"},h(InputStateWrapper,Object.assign({key:"d231adf62c4e893a50ab45f55dfa2b709c492e48"},this.getInputProps())),h(CustomSuggestionsToggleFc,{key:"d61b92fad3dd59b99a2342ba9fd5091ba813bde2",onClick:this.toggleListbox.bind(this),disabled:e})),this._isOpen&&!e&&h(CustomSuggestionsOptionsGroupFc,{key:"dec96f5306ae54cc5c9561b04bf8ef09f1e2baee",blockSuggestionMouseOver:this.blockSuggestionMouseOver,onKeyDown:this.handleKeyDownDropdown.bind(this)},Array.isArray(this._filteredSuggestions)&&this._filteredSuggestions.length>0&&this._filteredSuggestions.map((e,t)=>h(CustomSuggestionsOptionFc,{index:t,option:e,searchTerm:this.state._value,ref:e=>{e&&(this.refSuggestions[t]=e)},selected:this.state._value===e,onClick:()=>{this.selectOption(e),this.toggleListbox(),this._isOpen=!1,this._hasOpened=!1},onMouseOver:()=>{this.blockSuggestionMouseOver||this.focusOption(t)},onFocus:()=>{this.focusOption(t)},onKeyDown:t=>{"Enter"!==t.key&&"NumpadEnter"!==t.key||(this.selectOption(e),this.toggleListbox(),t.preventDefault())}})))))}handleKeyDown(e){var t,n;const i=(t,n)=>{var i;e.preventDefault(),void 0!==t&&(this._isOpen=t,t||null===(i=this.refInput)||void 0===i||i.focus()),null==n||n()};switch(e.key){case"Down":case"ArrowDown":this.blockSuggestionMouseOver=!0,i(!0,()=>this.moveFocus(1));break;case"Up":case"ArrowUp":this.blockSuggestionMouseOver=!0,i(!0,()=>this.moveFocus(-1));break;case"Tab":this._isOpen&&(this._isOpen=!1,null===(t=this.refInput)||void 0===t||t.focus());break;case"Esc":case"Escape":this._hasOpened=!1,this._isOpen=!1,e.preventDefault(),null===(n=this.refInput)||void 0===n||n.focus();break;case"NumpadEnter":case"Enter":this._isOpen&&this._focusedOptionIndex>=0?(this._filteredSuggestions&&this.selectOption(this._filteredSuggestions[this._focusedOptionIndex]),this._isOpen=!1,this._hasOpened=!1):this.toggleListbox(),e.preventDefault();break;case"Home":this.blockSuggestionMouseOver=!0,i(void 0,()=>{this._isOpen&&this.focusOption(0)});break;case"End":this.blockSuggestionMouseOver=!0,i(void 0,()=>{this._isOpen&&this.focusOption(this._filteredSuggestions?this._filteredSuggestions.length-1:0)});break;case"PageUp":this.blockSuggestionMouseOver=!0,i(void 0,()=>this._isOpen&&this.moveFocus(-10));break;case"PageDown":this.blockSuggestionMouseOver=!0,i(void 0,()=>this._isOpen&&this.moveFocus(10))}}handleWindowClick(e){void 0===this.host||this.host.contains(e.target)||(this._isOpen=!1)}constructor(e){super(),!1!==e&&this.__registerHost(),this.__attachShadow(),this.refSuggestions=[],this._focusedOptionIndex=-1,this.toggleListbox=()=>{var e;if(!0===this.state._disabled)this._isOpen=!1;else if(null===(e=this.refInput)||void 0===e||e.focus(),!this._hasOpened&&Array.isArray(this._filteredSuggestions)&&this._filteredSuggestions.length>0){this._isOpen=!0,this._hasOpened=!0;const e=this._filteredSuggestions.findIndex(e=>e===this.state._value);this._focusedOptionIndex=e>=0?e:-1,this.focusOption(this._focusedOptionIndex)}},this.catchRef=e=>{this.refInput=e},this.blockSuggestionMouseOver=!1,this._isOpen=!1,this._hasOpened=!1,this._disabled=!1,this._hideMsg=!1,this._hideLabel=!1,this._hint="",this._required=!1,this._tooltipAlign="top",this._touched=!1,this.state={_hasValue:!1,_hideMsg:!1,_id:`id-${nonce()}`,_label:"",_suggestions:[],_value:""},this.inputHasFocus=!1,this.controller=new ComboboxController(this,"combobox",this.host),this.onInput=this.onInput.bind(this)}showAsAlert(){return Boolean(this.state._touched)&&!this.inputHasFocus}validatePlaceholder(e){this.controller.validatePlaceholder(e)}validateAccessKey(e){this.controller.validateAccessKey(e)}validateDisabled(e){this.controller.validateDisabled(e)}validateHideMsg(e){this.controller.validateHideMsg(e)}validateHideLabel(e){this.controller.validateHideLabel(e)}validateHint(e){this.controller.validateHint(e)}validateIcons(e){this.controller.validateIcons(e)}validateId(e){this.controller.validateId(e)}validateLabel(e){this.controller.validateLabel(e)}validateMsg(e){this.controller.validateMsg(e)}validateName(e){this.controller.validateName(e)}validateOn(e){this.controller.validateOn(e)}validateShortKey(e){this.controller.validateShortKey(e)}validateSuggestions(e){this.controller.validateSuggestions(e),this._filteredSuggestions=e}validateRequired(e){this.controller.validateRequired(e)}validateSyncValueBySelector(e){this.controller.validateSyncValueBySelector(e)}validateTouched(e){this.controller.validateTouched(e)}validateValue(e){this.controller.validateValue(e),this.controller.setFormAssociatedValue(e)}componentWillLoad(){this.refSuggestions=[],this._touched=!0===this._touched,this.controller.componentWillLoad(),this.state._hasValue=!!this.state._value,this.controller.addValueChangeListener(e=>this.state._hasValue=!!e),this._filteredSuggestions=this.state._suggestions}handleMouseEvent(){this.blockSuggestionMouseOver=!1}handleFocusOut(){setTimeout(()=>{var e;(null===(e=this.host)||void 0===e?void 0:e.contains(document.activeElement))||this.onBlur()},0)}handleWindowBlur(){this.onBlur()}onBlur(){var e;this._hasOpened=!1,this._isOpen&&(this._isOpen=!this._isOpen,null===(e=this.refInput)||void 0===e||e.focus())}onChange(e){this.controller.onFacade.onChange(e),this.controller.setFormAssociatedValue(this.state._value)}static get delegatesFocus(){return!0}get host(){return this}static get watchers(){return{_placeholder:["validatePlaceholder"],_accessKey:["validateAccessKey"],_disabled:["validateDisabled"],_hideMsg:["validateHideMsg"],_hideLabel:["validateHideLabel"],_hint:["validateHint"],_icons:["validateIcons"],_id:["validateId"],_label:["validateLabel"],_msg:["validateMsg"],_name:["validateName"],_on:["validateOn"],_shortKey:["validateShortKey"],_suggestions:["validateSuggestions"],_required:["validateRequired"],_syncValueBySelector:["validateSyncValueBySelector"],_touched:["validateTouched"],_value:["validateValue"]}}static get style(){return{default:defaultStyleCss}}},[305,"kol-combobox",{_accessKey:[1,"_access-key"],_placeholder:[1],_disabled:[4],_hideMsg:[4,"_hide-msg"],_hideLabel:[4,"_hide-label"],_hint:[1],_icons:[1],_id:[1],_label:[1],_msg:[1],_name:[1],_on:[16],_suggestions:[1],_required:[4],_shortKey:[1,"_short-key"],_syncValueBySelector:[1,"_sync-value-by-selector"],_tooltipAlign:[1,"_tooltip-align"],_touched:[1540],_value:[1537],blockSuggestionMouseOver:[32],_isOpen:[32],_filteredSuggestions:[32],_hasOpened:[32],state:[32],inputHasFocus:[32],getValue:[64],kolFocus:[64]},[[0,"keydown","handleKeyDown"],[8,"click","handleWindowClick"],[1,"mousemove","handleMouseEvent"],[8,"focusout","handleFocusOut"],[8,"blur","handleWindowBlur"]],{_placeholder:["validatePlaceholder"],_accessKey:["validateAccessKey"],_disabled:["validateDisabled"],_hideMsg:["validateHideMsg"],_hideLabel:["validateHideLabel"],_hint:["validateHint"],_icons:["validateIcons"],_id:["validateId"],_label:["validateLabel"],_msg:["validateMsg"],_name:["validateName"],_on:["validateOn"],_shortKey:["validateShortKey"],_suggestions:["validateSuggestions"],_required:["validateRequired"],_syncValueBySelector:["validateSyncValueBySelector"],_touched:["validateTouched"],_value:["validateValue"]}]);function defineCustomElement$1(){if("undefined"==typeof customElements)return;["kol-combobox"].forEach(e=>{if("kol-combobox"===e)customElements.get(e)||customElements.define(e,KolCombobox$1)})}const KolCombobox=KolCombobox$1,defineCustomElement=defineCustomElement$1;export{KolCombobox,defineCustomElement};
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{proxyCustomElement,HTMLElement,h}from"@stencil/core/internal/client";import{w as watchValidator}from"./common.js";import{v as validateDisabled}from"./disabled.js";import{v as validateLabel}from"./label.js";import{v as validateOpen}from"./open.js";import{K as KolCollapsibleFc}from"./Collapsible.js";import{n as nonce}from"./dev.utils.js";import{w as watchHeadingLevel}from"./validation.js";import{d as dispatchDomEvent,K as KolEvent}from"./events.js";const validateDetailsCallbacks=(e,n)=>{watchValidator(e,"_on",e=>"object"==typeof e&&null!==e,new Set(["DetailsCallbacksPropType {Events.onToggle}"]),n)},defaultStyleCss="/* forward the rem function */\n/*\n* This file defines the layer order for all CSS layers used in KoliBri.\n* The order is important as it determines the cascade priority.\n*\n* Layer order (lowest to highest priority):\n* 1. kol-a11y - Accessibility defaults and requirements\n* 2. kol-global - Global component styles and resets\n* 3. kol-component - Component-specific styles\n* 4. kol-theme-global - Theme-specific global styles\n* 5. kol-theme-component - Theme-specific component styles\n*/\n@layer kol-a11y, kol-global, kol-component, kol-theme-global, kol-theme-component;\n/*\n * This file contains all rules for accessibility.\n */\n@layer kol-a11y {\n :host {\n /*\n * Minimum size of interactive elements.\n */\n --a11y-min-size: calc(44 * 1rem / var(--kolibri-root-font-size, 16));\n /*\n * No element should be used without verifying the contrast ratio of its background and font colors.\n * By initially setting the background color to white and the font color to black,\n * the contrast ratio is ensured and explicit adjustment is forced.\n */\n color: black;\n background-color: white;\n /*\n * Verdana is an accessible font that can be used without requiring additional loading time.\n */\n font-family: Verdana;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n * {\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n hyphens: auto;\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n word-break: break-word;\n }\n /*\n * All interactive elements should have a minimum size of to-rem(44).\n */\n /* input:not([type='checkbox'], [type='radio'], [type='range']), */\n /* option, */\n /* select, */\n /* textarea, */\n button,\n .kol-input .input {\n min-width: var(--a11y-min-size);\n min-height: var(--a11y-min-size);\n }\n /*\n * Some interactive elements should not inherit the font-family and font-size.\n */\n a,\n button,\n h1,\n h2,\n h3,\n h4,\n h5,\n h6,\n input,\n option,\n select,\n textarea {\n /*\n * All elements should inherit the font family from his parent element.\n */\n font-family: inherit;\n /*\n * All elements should inherit the font size from his parent element.\n */\n font-size: inherit;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n /**\n * Sometimes we need the semantic element for accessibility reasons,\n * but we don't want to show it.\n *\n * - https://www.a11yproject.com/posts/how-to-hide-content/\n */\n .visually-hidden {\n position: fixed;\n top: 0;\n left: 0;\n width: 1px;\n height: 1px;\n overflow: hidden;\n white-space: nowrap;\n clip-path: inset(50%);\n }\n}\n@layer kol-global {\n /*\n * Dieses CSS stellt sicher, dass der Standard-Style\n * von A und Button resettet werden.\n */\n :is(a, button) {\n background-color: transparent;\n width: 100%;\n margin: 0;\n padding: 0;\n border: none;\n /* 100% needed for custom width from outside */\n }\n /*\n * Ensure elements with hidden attribute to be actually not visible\n * @see https://meowni.ca/hidden.is.a.lie.html\n */\n [hidden] {\n display: none !important;\n }\n .badge-text-hint {\n color: black;\n background-color: lightgray;\n }\n}\n@layer kol-global {\n :host {\n /*\n * The max-width is needed to prevent the table from overflowing the\n * parent node, if the table is wider than the parent node.\n */\n max-width: 100%;\n font-size: calc(16 * 1rem / var(--kolibri-root-font-size, 16));\n }\n * {\n /*\n * We prefer to box-sizing: border-box for all elements.\n */\n box-sizing: border-box;\n }\n .kol-span {\n /* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n display: grid;\n place-items: center;\n /* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n }\n .kol-span__container {\n display: flex;\n place-items: center;\n }\n a,\n button {\n cursor: pointer;\n }\n .kol-span .kol-span__label--hide-label .kol-span__label {\n display: none;\n }\n /* Reset browser agent style. */\n button:disabled {\n color: unset;\n }\n .disabled label,\n .disabled:focus-within label,\n [aria-disabled=true],\n [aria-disabled=true]:focus,\n [disabled],\n [disabled]:focus {\n opacity: 0.5;\n outline: none;\n cursor: not-allowed;\n }\n [aria-disabled=true]:focus .kol-span,\n [disabled]:focus .kol-span {\n outline: none !important;\n }\n}\n@layer kol-component {\n :host {\n display: block;\n }\n}\n/* For animation technique see https://css-tricks.com/css-grid-can-do-auto-height-transitions/ */\n@layer kol-component {\n .collapsible {\n /* @see https://github.com/public-ui/kolibri/issues/5952 */\n /*\n * Inside a button, the caption text is always centered.\n * So we have to align the text to the left.\n */\n }\n @media (prefers-reduced-motion) {\n .collapsible__wrapper-animation, .collapsible__wrapper {\n transition-duration: 0s;\n }\n }\n @media print {\n :not(.collapsible--open) .collapsible__wrapper-animation {\n display: none;\n }\n }\n .collapsible__wrapper {\n /* Forces the element into its own GPU compositing layer (via 3D transform). Helps prevent rendering/layout bugs (e.g. #7511) and may improve animation performance. */\n transform: translateZ(0);\n display: grid;\n /**\n * The `overflow: hidden` ensures that the content is not visible during the animated\n * opening and closing. This should also cut off overlays containing content, but it\n *does not.\n */\n overflow: hidden;\n grid-template-rows: 0fr;\n transition: grid-template-rows 0.3s;\n }\n .collapsible__wrapper-animation {\n min-height: 0;\n /* This property is important to keep in sync with the visual transition (template-rows). Without it interactive elements within the accordion would stay focusable. */\n visibility: hidden;\n transition: visibility 0.3s;\n }\n .collapsible--open .collapsible__wrapper {\n grid-template-rows: 1fr;\n }\n .collapsible--open .collapsible__wrapper-animation {\n visibility: visible;\n }\n .collapsible__heading-button button .kol-span {\n justify-items: start;\n }\n}\n@layer kol-component {\n .kol-details__heading-button {\n display: flex;\n }\n .kol-details__heading-button .kol-button {\n min-height: auto;\n }\n .kol-details__heading-button .kol-button .kol-span__label {\n border-bottom-color: grey;\n border-bottom-style: solid;\n }\n .collapsible--open .kol-details__heading-button .kol-icon::part(icon) {\n transform: rotate(90deg);\n }\n}",KolDetails$1=proxyCustomElement(class extends HTMLElement{constructor(e){super(),!1!==e&&this.__registerHost(),this.__attachShadow(),this.nonce=nonce(),this.catchRef=e=>{this.buttonWcRef=e},this.handleOnClick=e=>{this._open=!this._open,clearTimeout(this.toggleTimeout),this.toggleTimeout=setTimeout(()=>{var n,t;this.host&&dispatchDomEvent(this.host,KolEvent.toggle,Boolean(this._open)),null===(t=null===(n=this.state._on)||void 0===n?void 0:n.onToggle)||void 0===t||t.call(n,e,Boolean(this._open))},25)},this._disabled=!1,this._level=0,this._open=!1,this.state={_label:"",_level:0,_on:{}}}async kolFocus(){var e;await(null===(e=this.buttonWcRef)||void 0===e?void 0:e.kolFocus())}render(){const{_open:e,_label:n,_disabled:t,_level:i}=this.state,o="kol-details",l={id:this.nonce,label:n,open:e,disabled:t,level:i,onClick:this.handleOnClick,class:o,HeadingProps:{class:`${o}__heading`},HeadingButtonProps:{ref:this.catchRef,class:`${o}__heading-button`,_icons:"codicon codicon-chevron-right"},ContentProps:{class:`${o}__content indented-text`,wrapperClass:`${o}__wrapper`,animationClass:`${o}__wrapper-animation`}};return h(KolCollapsibleFc,Object.assign({key:"e149779c3d5053267bcd2785b061c3862c1ab806"},l),h("slot",{key:"ba4278e16e1cd27c08ecc5aef1d47d8427d94575"}))}validateDisabled(e){validateDisabled(this,e)}validateLabel(e){validateLabel(this,e,{required:!0})}validateLevel(e){watchHeadingLevel(this,e)}validateOn(e){validateDetailsCallbacks(this,e)}validateOpen(e){validateOpen(this,e)}componentWillLoad(){this.validateDisabled(this._disabled),this.validateLabel(this._label),this.validateLevel(this._level),this.validateOn(this._on),this.validateOpen(this._open)}get host(){return this}static get watchers(){return{_disabled:["validateDisabled"],_label:["validateLabel"],_level:["validateLevel"],_on:["validateOn"],_open:["validateOpen"]}}static get style(){return{default:defaultStyleCss}}},[289,"kol-details",{_disabled:[4],_label:[1],_level:[2],_on:[16],_open:[1540],state:[32],kolFocus:[64]},void 0,{_disabled:["validateDisabled"],_label:["validateLabel"],_level:["validateLevel"],_on:["validateOn"],_open:["validateOpen"]}]);function defineCustomElement$1(){if("undefined"==typeof customElements)return;["kol-details"].forEach(e=>{if("kol-details"===e)customElements.get(e)||customElements.define(e,KolDetails$1)})}const KolDetails=KolDetails$1,defineCustomElement=defineCustomElement$1;export{KolDetails,defineCustomElement};
4
+ import{proxyCustomElement,HTMLElement,h}from"@stencil/core/internal/client";import{w as watchValidator}from"./common.js";import{v as validateDisabled}from"./disabled.js";import{v as validateLabel}from"./label.js";import{v as validateOpen}from"./open.js";import{K as KolCollapsibleFc}from"./Collapsible.js";import{n as nonce}from"./dev.utils.js";import{w as watchHeadingLevel}from"./validation.js";import{d as dispatchDomEvent,K as KolEvent}from"./events.js";const validateDetailsCallbacks=(e,n)=>{watchValidator(e,"_on",e=>"object"==typeof e&&null!==e,new Set(["DetailsCallbacksPropType {Events.onToggle}"]),n)},defaultStyleCss="/* forward the rem function */\n/*\n* This file defines the layer order for all CSS layers used in KoliBri.\n* The order is important as it determines the cascade priority.\n*\n* Layer order (lowest to highest priority):\n* 1. kol-a11y - Accessibility defaults and requirements\n* 2. kol-global - Global component styles and resets\n* 3. kol-component - Component-specific styles\n* 4. kol-theme-global - Theme-specific global styles\n* 5. kol-theme-component - Theme-specific component styles\n*/\n@layer kol-a11y, kol-global, kol-component, kol-theme-global, kol-theme-component;\n/*\n * This file contains all rules for accessibility.\n */\n@layer kol-a11y {\n :host {\n /*\n * Minimum size of interactive elements.\n */\n --a11y-min-size: calc(44 * 1rem / var(--kolibri-root-font-size, 16));\n /*\n * No element should be used without verifying the contrast ratio of its background and font colors.\n * By initially setting the background color to white and the font color to black,\n * the contrast ratio is ensured and explicit adjustment is forced.\n */\n color: black;\n background-color: white;\n /*\n * Verdana is an accessible font that can be used without requiring additional loading time.\n */\n font-family: Verdana;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n * {\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n hyphens: auto;\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n word-break: break-word;\n }\n /*\n * All interactive elements should have a minimum size of to-rem(44).\n */\n /* input:not([type='checkbox'], [type='radio'], [type='range']), */\n /* option, */\n /* select, */\n /* textarea, */\n button,\n .kol-input .input {\n min-width: var(--a11y-min-size);\n min-height: var(--a11y-min-size);\n }\n /*\n * Some interactive elements should not inherit the font-family and font-size.\n */\n a,\n button,\n h1,\n h2,\n h3,\n h4,\n h5,\n h6,\n input,\n option,\n select,\n textarea {\n /*\n * All elements should inherit the font family from his parent element.\n */\n font-family: inherit;\n /*\n * All elements should inherit the font size from his parent element.\n */\n font-size: inherit;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n /**\n * Sometimes we need the semantic element for accessibility reasons,\n * but we don't want to show it.\n *\n * - https://www.a11yproject.com/posts/how-to-hide-content/\n */\n .visually-hidden {\n position: fixed;\n top: 0;\n left: 0;\n width: 1px;\n height: 1px;\n overflow: hidden;\n white-space: nowrap;\n clip-path: inset(50%);\n }\n}\n@layer kol-global {\n /*\n * Dieses CSS stellt sicher, dass der Standard-Style\n * von A und Button resettet werden.\n */\n :is(a, button) {\n background-color: transparent;\n width: 100%;\n margin: 0;\n padding: 0;\n border: none;\n /* 100% needed for custom width from outside */\n }\n /*\n * Ensure elements with hidden attribute to be actually not visible\n * @see https://meowni.ca/hidden.is.a.lie.html\n */\n [hidden] {\n display: none !important;\n }\n .badge-text-hint {\n color: black;\n background-color: lightgray;\n }\n}\n@layer kol-global {\n :host {\n /*\n * The max-width is needed to prevent the table from overflowing the\n * parent node, if the table is wider than the parent node.\n */\n max-width: 100%;\n font-size: calc(16 * 1rem / var(--kolibri-root-font-size, 16));\n }\n * {\n /*\n * We prefer to box-sizing: border-box for all elements.\n */\n box-sizing: border-box;\n }\n .kol-span {\n /* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n display: grid;\n place-items: center;\n /* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n }\n .kol-span__container {\n display: flex;\n place-items: center;\n }\n a,\n button {\n cursor: pointer;\n }\n .kol-span .kol-span__label--hide-label .kol-span__label {\n display: none;\n }\n /* Reset browser agent style. */\n button:disabled {\n color: unset;\n }\n .disabled label,\n .disabled:focus-within label,\n [aria-disabled=true],\n [aria-disabled=true]:focus,\n [disabled],\n [disabled]:focus {\n opacity: 0.5;\n outline: none;\n cursor: not-allowed;\n }\n [aria-disabled=true]:focus .kol-span,\n [disabled]:focus .kol-span {\n outline: none !important;\n }\n}\n@layer kol-component {\n :host {\n display: block;\n }\n}\n/* For animation technique see https://css-tricks.com/css-grid-can-do-auto-height-transitions/ */\n@layer kol-component {\n .collapsible {\n /* @see https://github.com/public-ui/kolibri/issues/5952 */\n /*\n * Inside a button, the caption text is always centered.\n * So we have to align the text to the left.\n */\n }\n @media (prefers-reduced-motion) {\n .collapsible__wrapper-animation, .collapsible__wrapper {\n transition-duration: 0s;\n }\n }\n @media print {\n :not(.collapsible--open) .collapsible__wrapper-animation {\n display: none;\n }\n }\n .collapsible__wrapper {\n /* Forces the element into its own GPU compositing layer (via 3D transform). Helps prevent rendering/layout bugs (e.g. #7511) and may improve animation performance. */\n transform: translateZ(0);\n display: grid;\n grid-template-rows: 0fr;\n transition: grid-template-rows 0.3s;\n }\n .collapsible__wrapper-animation {\n min-height: 0;\n /**\n * The `overflow: hidden` ensures that the content is not visible during the animated\n * opening and closing. This should also cut off overlays containing content, but it\n *does not.\n */\n overflow: hidden;\n /* This property is important to keep in sync with the visual transition (template-rows). Without it interactive elements within the accordion would stay focusable. */\n visibility: hidden;\n transition: visibility 0.3s;\n }\n .collapsible--open .collapsible__wrapper {\n grid-template-rows: 1fr;\n }\n .collapsible--open .collapsible__wrapper-animation {\n visibility: visible;\n }\n .collapsible__heading-button button .kol-span {\n justify-items: start;\n }\n}\n@layer kol-component {\n .kol-details__heading-button {\n display: flex;\n }\n .kol-details__heading-button .kol-button {\n min-height: auto;\n }\n .kol-details__heading-button .kol-button .kol-span__label {\n border-bottom-color: grey;\n border-bottom-style: solid;\n }\n .collapsible--open .kol-details__heading-button .kol-icon::part(icon) {\n transform: rotate(90deg);\n }\n}",KolDetails$1=proxyCustomElement(class extends HTMLElement{constructor(e){super(),!1!==e&&this.__registerHost(),this.__attachShadow(),this.nonce=nonce(),this.catchRef=e=>{this.buttonWcRef=e},this.handleOnClick=e=>{this._open=!this._open,clearTimeout(this.toggleTimeout),this.toggleTimeout=setTimeout(()=>{var n,t;this.host&&dispatchDomEvent(this.host,KolEvent.toggle,Boolean(this._open)),null===(t=null===(n=this.state._on)||void 0===n?void 0:n.onToggle)||void 0===t||t.call(n,e,Boolean(this._open))},25)},this._disabled=!1,this._level=0,this._open=!1,this.state={_label:"",_level:0,_on:{}}}async kolFocus(){var e;await(null===(e=this.buttonWcRef)||void 0===e?void 0:e.kolFocus())}render(){const{_open:e,_label:n,_disabled:t,_level:i}=this.state,o="kol-details",l={id:this.nonce,label:n,open:e,disabled:t,level:i,onClick:this.handleOnClick,class:o,HeadingProps:{class:`${o}__heading`},HeadingButtonProps:{ref:this.catchRef,class:`${o}__heading-button`,_icons:"codicon codicon-chevron-right"},ContentProps:{class:`${o}__content indented-text`,wrapperClass:`${o}__wrapper`,animationClass:`${o}__wrapper-animation`}};return h(KolCollapsibleFc,Object.assign({key:"2723a76015e4561151328565c2eec42d99bf00a3"},l),h("slot",{key:"18e154f7788540a9e839ce25b70552a102aa7869"}))}validateDisabled(e){validateDisabled(this,e)}validateLabel(e){validateLabel(this,e,{required:!0})}validateLevel(e){watchHeadingLevel(this,e)}validateOn(e){validateDetailsCallbacks(this,e)}validateOpen(e){validateOpen(this,e)}componentWillLoad(){this.validateDisabled(this._disabled),this.validateLabel(this._label),this.validateLevel(this._level),this.validateOn(this._on),this.validateOpen(this._open)}get host(){return this}static get watchers(){return{_disabled:["validateDisabled"],_label:["validateLabel"],_level:["validateLevel"],_on:["validateOn"],_open:["validateOpen"]}}static get style(){return{default:defaultStyleCss}}},[289,"kol-details",{_disabled:[4],_label:[1],_level:[2],_on:[16],_open:[1540],state:[32],kolFocus:[64]},void 0,{_disabled:["validateDisabled"],_label:["validateLabel"],_level:["validateLevel"],_on:["validateOn"],_open:["validateOpen"]}]);function defineCustomElement$1(){if("undefined"==typeof customElements)return;["kol-details"].forEach(e=>{if("kol-details"===e)customElements.get(e)||customElements.define(e,KolDetails$1)})}const KolDetails=KolDetails$1,defineCustomElement=defineCustomElement$1;export{KolDetails,defineCustomElement};
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{proxyCustomElement,HTMLElement,h,Host}from"@stencil/core/internal/client";import{s as setState}from"./common.js";import{v as validateAlign}from"./align.js";import{v as validateHasCloser}from"./has-closer.js";import{v as validateLabel}from"./label.js";import{v as validateOpen}from"./open.js";import{d as dispatchDomEvent,K as KolEvent}from"./events.js";import{c as clsx}from"./clsx.js";import{g as KolCardWcTag}from"./component-names.js";const defaultStyleCss="/*\n* This file defines the layer order for all CSS layers used in KoliBri.\n* The order is important as it determines the cascade priority.\n*\n* Layer order (lowest to highest priority):\n* 1. kol-a11y - Accessibility defaults and requirements\n* 2. kol-global - Global component styles and resets\n* 3. kol-component - Component-specific styles\n* 4. kol-theme-global - Theme-specific global styles\n* 5. kol-theme-component - Theme-specific component styles\n*/\n@layer kol-a11y, kol-global, kol-component, kol-theme-global, kol-theme-component;\n/* forward the rem function */\n/*\n * This file contains all rules for accessibility.\n */\n@layer kol-a11y {\n :host {\n /*\n * Minimum size of interactive elements.\n */\n --a11y-min-size: calc(44 * 1rem / var(--kolibri-root-font-size, 16));\n /*\n * No element should be used without verifying the contrast ratio of its background and font colors.\n * By initially setting the background color to white and the font color to black,\n * the contrast ratio is ensured and explicit adjustment is forced.\n */\n color: black;\n background-color: white;\n /*\n * Verdana is an accessible font that can be used without requiring additional loading time.\n */\n font-family: Verdana;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n * {\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n hyphens: auto;\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n word-break: break-word;\n }\n /*\n * All interactive elements should have a minimum size of to-rem(44).\n */\n /* input:not([type='checkbox'], [type='radio'], [type='range']), */\n /* option, */\n /* select, */\n /* textarea, */\n button,\n .kol-input .input {\n min-width: var(--a11y-min-size);\n min-height: var(--a11y-min-size);\n }\n /*\n * Some interactive elements should not inherit the font-family and font-size.\n */\n a,\n button,\n h1,\n h2,\n h3,\n h4,\n h5,\n h6,\n input,\n option,\n select,\n textarea {\n /*\n * All elements should inherit the font family from his parent element.\n */\n font-family: inherit;\n /*\n * All elements should inherit the font size from his parent element.\n */\n font-size: inherit;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n /**\n * Sometimes we need the semantic element for accessibility reasons,\n * but we don't want to show it.\n *\n * - https://www.a11yproject.com/posts/how-to-hide-content/\n */\n .visually-hidden {\n position: fixed;\n top: 0;\n left: 0;\n width: 1px;\n height: 1px;\n overflow: hidden;\n white-space: nowrap;\n clip-path: inset(50%);\n }\n}\n@layer kol-global {\n /*\n * Dieses CSS stellt sicher, dass der Standard-Style\n * von A und Button resettet werden.\n */\n :is(a, button) {\n background-color: transparent;\n width: 100%;\n margin: 0;\n padding: 0;\n border: none;\n /* 100% needed for custom width from outside */\n }\n /*\n * Ensure elements with hidden attribute to be actually not visible\n * @see https://meowni.ca/hidden.is.a.lie.html\n */\n [hidden] {\n display: none !important;\n }\n .badge-text-hint {\n color: black;\n background-color: lightgray;\n }\n}\n@layer kol-global {\n :host {\n /*\n * The max-width is needed to prevent the table from overflowing the\n * parent node, if the table is wider than the parent node.\n */\n max-width: 100%;\n font-size: calc(16 * 1rem / var(--kolibri-root-font-size, 16));\n }\n * {\n /*\n * We prefer to box-sizing: border-box for all elements.\n */\n box-sizing: border-box;\n }\n .kol-span {\n /* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n display: grid;\n place-items: center;\n /* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n }\n .kol-span__container {\n display: flex;\n place-items: center;\n }\n a,\n button {\n cursor: pointer;\n }\n .kol-span .kol-span__label--hide-label .kol-span__label {\n display: none;\n }\n /* Reset browser agent style. */\n button:disabled {\n color: unset;\n }\n .disabled label,\n .disabled:focus-within label,\n [aria-disabled=true],\n [aria-disabled=true]:focus,\n [disabled],\n [disabled]:focus {\n opacity: 0.5;\n outline: none;\n cursor: not-allowed;\n }\n [aria-disabled=true]:focus .kol-span,\n [disabled]:focus .kol-span {\n outline: none !important;\n }\n}\n@layer kol-component {\n @keyframes fadeInOpacity {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n }\n .kol-tooltip {\n display: contents;\n }\n .kol-tooltip__floating {\n display: none;\n position: fixed;\n /* Avoid layout interference - see https://floating-ui.com/docs/computePosition */\n top: 0;\n left: 0;\n /* Can be used to specify the tooltip-width from the outside. Unset by default. */\n width: var(--kol-tooltip-width, max-content);\n min-width: calc(8 * 1rem / var(--kolibri-root-font-size, 16));\n max-width: 90vw;\n max-height: 90vh;\n visibility: hidden;\n animation-duration: 0.25s;\n animation-iteration-count: 1;\n animation-name: fadeInOpacity;\n animation-timing-function: ease-in;\n }\n .kol-tooltip__arrow {\n transform: rotate(45deg);\n color: #000;\n background-color: #fff;\n position: absolute;\n z-index: 999;\n width: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n height: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n }\n .kol-tooltip__content {\n color: #000;\n background-color: #fff;\n position: relative;\n z-index: 1000;\n }\n}\n@layer kol-component {\n .kol-card {\n /* Visible with forced colors */\n outline: transparent solid calc(1 * 1rem / var(--kolibri-root-font-size, 16));\n position: relative;\n height: 100%;\n }\n .kol-card__close-button {\n position: absolute;\n top: 0;\n right: 0;\n }\n .kol-drawer__dialog {\n padding: 0;\n border: none;\n }\n .kol-drawer__wrapper {\n position: fixed;\n overflow: auto;\n }\n .kol-drawer__wrapper--left, .kol-drawer__wrapper--right {\n top: 0;\n max-width: 100vw;\n height: 100vh;\n }\n .kol-drawer__wrapper--left .kol-drawer__content, .kol-drawer__wrapper--right .kol-drawer__content {\n height: 100%;\n }\n .kol-drawer__wrapper--left {\n left: 0;\n }\n .kol-drawer__wrapper--right {\n right: 0;\n }\n .kol-drawer__wrapper--bottom, .kol-drawer__wrapper--top {\n left: 0;\n width: 100vw;\n max-height: 100vh;\n }\n .kol-drawer__wrapper--bottom .kol-drawer__content, .kol-drawer__wrapper--top .kol-drawer__content {\n width: 100%;\n }\n .kol-drawer__wrapper--bottom {\n bottom: 0;\n }\n .kol-drawer__wrapper--top {\n top: 0;\n }\n .kol-drawer__content {\n position: relative;\n }\n}",KolDrawer$1=proxyCustomElement(class extends HTMLElement{constructor(e){super(),!1!==e&&this.__registerHost(),this.__attachShadow(),this.getWrapperRef=e=>this.dialogWrapperElement=e,this.getRef=e=>{this.dialogElement=e,setTimeout(()=>{this.openOrCloseBasedOnState()})},this._hasCloser=!1,this.state={_label:"",_open:!1,_align:"left"}}async open(){var e;this.state=Object.assign(Object.assign({},this.state),{_open:!0}),null===(e=this.dialogElement)||void 0===e||e.showModal()}async close(){this.state=Object.assign(Object.assign({},this.state),{_open:!1});const e=this.dialogWrapperElement;if(!e)return;"none"===window.getComputedStyle(e).animationName&&this.handleCloseDialog()}renderDialogContent(){const e=this.state._align;return h(KolCardWcTag,{ref:this.getWrapperRef,class:clsx("kol-drawer__wrapper",`kol-drawer__wrapper--${e}`,{"kol-drawer__wrapper--open":this.state._open,"kol-drawer__wrapper--is-closing":!1===this.state._open}),_label:this.state._label,_hasCloser:this.state._hasCloser,_on:{onClose:()=>{this.close()}}},h("div",{class:"kol-drawer__content"},h("slot",null)))}render(){return h(Host,{key:"789134f227ece64520110596720256d7f7a86961",class:"kol-drawer"},h("dialog",{key:"5b6e57975b4d92874647624ead38d9ff3a673626","aria-label":this.state._label,class:"kol-drawer__dialog",ref:this.getRef},this.renderDialogContent()))}validateLabel(e){validateLabel(this,e,{required:!0})}validateAlign(e){validateAlign(this,e)}validateHasCloser(e){validateHasCloser(this,e)}validateOpen(e){"boolean"==typeof e&&(validateOpen(this,e),this.dialogElement&&this.openOrCloseBasedOnState())}async openOrCloseBasedOnState(){this.state._open?await this.open():await this.close()}validateOn(e){if("object"==typeof e&&null!==e){const n={};"function"==typeof e.onClose&&(n.onClose=e.onClose),setState(this,"_on",n)}}handleCloseDialog(){var e,n,t;null===(e=this.dialogElement)||void 0===e||e.close(),null===(t=null===(n=this._on)||void 0===n?void 0:n.onClose)||void 0===t||t.call(n),this.host&&dispatchDomEvent(this.host,KolEvent.close)}handleClose(){(async()=>{await this.close(),this.handleCloseDialog()})()}handleAnimationEnd(e){e.animationName.includes("slideOut")&&this.handleCloseDialog()}componentDidLoad(){var e,n;null===(e=this.dialogElement)||void 0===e||e.addEventListener("animationend",this.handleAnimationEnd.bind(this)),null===(n=this.dialogElement)||void 0===n||n.addEventListener("close",this.handleClose.bind(this))}disconnectedCallback(){var e,n;null===(e=this.dialogElement)||void 0===e||e.removeEventListener("animationend",this.handleAnimationEnd.bind(this)),null===(n=this.dialogElement)||void 0===n||n.removeEventListener("close",this.handleClose.bind(this))}componentWillLoad(){this.validateLabel(this._label),this.validateOpen(this._open),this.validateAlign(this._align),this.validateHasCloser(this._hasCloser),this.validateOn(this._on)}get host(){return this}static get watchers(){return{_label:["validateLabel"],_align:["validateAlign"],_hasCloser:["validateHasCloser"],_open:["validateOpen"],_on:["validateOn"]}}static get style(){return{default:defaultStyleCss}}},[289,"kol-drawer",{_open:[4],_align:[1],_hasCloser:[4,"_has-closer"],_label:[1],_on:[16],state:[32],open:[64],close:[64]},void 0,{_label:["validateLabel"],_align:["validateAlign"],_hasCloser:["validateHasCloser"],_open:["validateOpen"],_on:["validateOn"]}]);function defineCustomElement$1(){if("undefined"==typeof customElements)return;["kol-drawer"].forEach(e=>{if("kol-drawer"===e)customElements.get(e)||customElements.define(e,KolDrawer$1)})}const KolDrawer=KolDrawer$1,defineCustomElement=defineCustomElement$1;export{KolDrawer,defineCustomElement};
4
+ import{proxyCustomElement,HTMLElement,h,Host}from"@stencil/core/internal/client";import{c as clsx}from"./clsx.js";import{g as KolCardWcTag}from"./component-names.js";import{s as setState}from"./common.js";import{v as validateAlign}from"./align.js";import{v as validateHasCloser}from"./has-closer.js";import{v as validateLabel}from"./label.js";import{v as validateOpen}from"./open.js";import{d as dispatchDomEvent,K as KolEvent}from"./events.js";import{h as handleCancelOverlay}from"./tooltip-open-tracking.js";const defaultStyleCss="/*\n* This file defines the layer order for all CSS layers used in KoliBri.\n* The order is important as it determines the cascade priority.\n*\n* Layer order (lowest to highest priority):\n* 1. kol-a11y - Accessibility defaults and requirements\n* 2. kol-global - Global component styles and resets\n* 3. kol-component - Component-specific styles\n* 4. kol-theme-global - Theme-specific global styles\n* 5. kol-theme-component - Theme-specific component styles\n*/\n@layer kol-a11y, kol-global, kol-component, kol-theme-global, kol-theme-component;\n/* forward the rem function */\n/*\n * This file contains all rules for accessibility.\n */\n@layer kol-a11y {\n :host {\n /*\n * Minimum size of interactive elements.\n */\n --a11y-min-size: calc(44 * 1rem / var(--kolibri-root-font-size, 16));\n /*\n * No element should be used without verifying the contrast ratio of its background and font colors.\n * By initially setting the background color to white and the font color to black,\n * the contrast ratio is ensured and explicit adjustment is forced.\n */\n color: black;\n background-color: white;\n /*\n * Verdana is an accessible font that can be used without requiring additional loading time.\n */\n font-family: Verdana;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n * {\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n hyphens: auto;\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n word-break: break-word;\n }\n /*\n * All interactive elements should have a minimum size of to-rem(44).\n */\n /* input:not([type='checkbox'], [type='radio'], [type='range']), */\n /* option, */\n /* select, */\n /* textarea, */\n button,\n .kol-input .input {\n min-width: var(--a11y-min-size);\n min-height: var(--a11y-min-size);\n }\n /*\n * Some interactive elements should not inherit the font-family and font-size.\n */\n a,\n button,\n h1,\n h2,\n h3,\n h4,\n h5,\n h6,\n input,\n option,\n select,\n textarea {\n /*\n * All elements should inherit the font family from his parent element.\n */\n font-family: inherit;\n /*\n * All elements should inherit the font size from his parent element.\n */\n font-size: inherit;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n /**\n * Sometimes we need the semantic element for accessibility reasons,\n * but we don't want to show it.\n *\n * - https://www.a11yproject.com/posts/how-to-hide-content/\n */\n .visually-hidden {\n position: fixed;\n top: 0;\n left: 0;\n width: 1px;\n height: 1px;\n overflow: hidden;\n white-space: nowrap;\n clip-path: inset(50%);\n }\n}\n@layer kol-global {\n /*\n * Dieses CSS stellt sicher, dass der Standard-Style\n * von A und Button resettet werden.\n */\n :is(a, button) {\n background-color: transparent;\n width: 100%;\n margin: 0;\n padding: 0;\n border: none;\n /* 100% needed for custom width from outside */\n }\n /*\n * Ensure elements with hidden attribute to be actually not visible\n * @see https://meowni.ca/hidden.is.a.lie.html\n */\n [hidden] {\n display: none !important;\n }\n .badge-text-hint {\n color: black;\n background-color: lightgray;\n }\n}\n@layer kol-global {\n :host {\n /*\n * The max-width is needed to prevent the table from overflowing the\n * parent node, if the table is wider than the parent node.\n */\n max-width: 100%;\n font-size: calc(16 * 1rem / var(--kolibri-root-font-size, 16));\n }\n * {\n /*\n * We prefer to box-sizing: border-box for all elements.\n */\n box-sizing: border-box;\n }\n .kol-span {\n /* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n display: grid;\n place-items: center;\n /* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n }\n .kol-span__container {\n display: flex;\n place-items: center;\n }\n a,\n button {\n cursor: pointer;\n }\n .kol-span .kol-span__label--hide-label .kol-span__label {\n display: none;\n }\n /* Reset browser agent style. */\n button:disabled {\n color: unset;\n }\n .disabled label,\n .disabled:focus-within label,\n [aria-disabled=true],\n [aria-disabled=true]:focus,\n [disabled],\n [disabled]:focus {\n opacity: 0.5;\n outline: none;\n cursor: not-allowed;\n }\n [aria-disabled=true]:focus .kol-span,\n [disabled]:focus .kol-span {\n outline: none !important;\n }\n}\n@layer kol-component {\n @keyframes fadeInOpacity {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n }\n .kol-tooltip {\n display: contents;\n }\n .kol-tooltip__floating {\n display: none;\n position: fixed;\n /* Avoid layout interference - see https://floating-ui.com/docs/computePosition */\n top: 0;\n left: 0;\n /* Can be used to specify the tooltip-width from the outside. Unset by default. */\n width: var(--kol-tooltip-width, max-content);\n min-width: calc(8 * 1rem / var(--kolibri-root-font-size, 16));\n max-width: 90vw;\n max-height: 90vh;\n visibility: hidden;\n animation-duration: 0.25s;\n animation-iteration-count: 1;\n animation-name: fadeInOpacity;\n animation-timing-function: ease-in;\n }\n .kol-tooltip__arrow {\n transform: rotate(45deg);\n color: #000;\n background-color: #fff;\n position: absolute;\n z-index: 999;\n width: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n height: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n }\n .kol-tooltip__content {\n color: #000;\n background-color: #fff;\n position: relative;\n z-index: 1000;\n }\n}\n@layer kol-component {\n .kol-card {\n /* Visible with forced colors */\n outline: transparent solid calc(1 * 1rem / var(--kolibri-root-font-size, 16));\n position: relative;\n height: 100%;\n }\n .kol-card__close-button {\n position: absolute;\n top: 0;\n right: 0;\n }\n .kol-drawer__dialog {\n padding: 0;\n border: none;\n }\n .kol-drawer__wrapper {\n position: fixed;\n overflow: auto;\n }\n .kol-drawer__wrapper--left, .kol-drawer__wrapper--right {\n top: 0;\n max-width: 100vw;\n height: 100vh;\n }\n .kol-drawer__wrapper--left .kol-drawer__content, .kol-drawer__wrapper--right .kol-drawer__content {\n height: 100%;\n }\n .kol-drawer__wrapper--left {\n left: 0;\n }\n .kol-drawer__wrapper--right {\n right: 0;\n }\n .kol-drawer__wrapper--bottom, .kol-drawer__wrapper--top {\n left: 0;\n width: 100vw;\n max-height: 100vh;\n }\n .kol-drawer__wrapper--bottom .kol-drawer__content, .kol-drawer__wrapper--top .kol-drawer__content {\n width: 100%;\n }\n .kol-drawer__wrapper--bottom {\n bottom: 0;\n }\n .kol-drawer__wrapper--top {\n top: 0;\n }\n .kol-drawer__content {\n position: relative;\n }\n}",KolDrawer$1=proxyCustomElement(class extends HTMLElement{constructor(e){super(),!1!==e&&this.__registerHost(),this.__attachShadow(),this.getWrapperRef=e=>this.dialogWrapperElement=e,this.getRef=e=>{this.dialogElement=e,setTimeout(()=>{this.openOrCloseBasedOnState()})},this._hasCloser=!1,this.state={_label:"",_open:!1,_align:"left"}}async open(){var e;this.state=Object.assign(Object.assign({},this.state),{_open:!0}),null===(e=this.dialogElement)||void 0===e||e.showModal()}async close(){this.state=Object.assign(Object.assign({},this.state),{_open:!1});const e=this.dialogWrapperElement;if(!e)return;"none"===window.getComputedStyle(e).animationName&&this.handleCloseDialog()}renderDialogContent(){const e=this.state._align;return h(KolCardWcTag,{ref:this.getWrapperRef,class:clsx("kol-drawer__wrapper",`kol-drawer__wrapper--${e}`,{"kol-drawer__wrapper--open":this.state._open,"kol-drawer__wrapper--is-closing":!1===this.state._open}),_label:this.state._label,_hasCloser:this.state._hasCloser,_on:{onClose:()=>{this.close()}}},h("div",{class:"kol-drawer__content"},h("slot",null)))}render(){return h(Host,{key:"d50e43c9e192ab4870c9981588af1d625597636e",class:"kol-drawer"},h("dialog",{key:"0323b4add4803bffa9d6df8d3dcfc84fb16311f8","aria-label":this.state._label,class:"kol-drawer__dialog",onCancel:handleCancelOverlay,ref:this.getRef},this.renderDialogContent()))}validateLabel(e){validateLabel(this,e,{required:!0})}validateAlign(e){validateAlign(this,e)}validateHasCloser(e){validateHasCloser(this,e)}validateOpen(e){"boolean"==typeof e&&(validateOpen(this,e),this.dialogElement&&this.openOrCloseBasedOnState())}async openOrCloseBasedOnState(){this.state._open?await this.open():await this.close()}validateOn(e){if("object"==typeof e&&null!==e){const n={};"function"==typeof e.onClose&&(n.onClose=e.onClose),setState(this,"_on",n)}}handleCloseDialog(){var e,n,t;null===(e=this.dialogElement)||void 0===e||e.close(),null===(t=null===(n=this._on)||void 0===n?void 0:n.onClose)||void 0===t||t.call(n),this.host&&dispatchDomEvent(this.host,KolEvent.close)}handleClose(){(async()=>{await this.close(),this.handleCloseDialog()})()}handleAnimationEnd(e){e.animationName.includes("slideOut")&&this.handleCloseDialog()}componentDidLoad(){var e,n;null===(e=this.dialogElement)||void 0===e||e.addEventListener("animationend",this.handleAnimationEnd.bind(this)),null===(n=this.dialogElement)||void 0===n||n.addEventListener("close",this.handleClose.bind(this))}disconnectedCallback(){var e,n;null===(e=this.dialogElement)||void 0===e||e.removeEventListener("animationend",this.handleAnimationEnd.bind(this)),null===(n=this.dialogElement)||void 0===n||n.removeEventListener("close",this.handleClose.bind(this))}componentWillLoad(){this.validateLabel(this._label),this.validateOpen(this._open),this.validateAlign(this._align),this.validateHasCloser(this._hasCloser),this.validateOn(this._on)}get host(){return this}static get watchers(){return{_label:["validateLabel"],_align:["validateAlign"],_hasCloser:["validateHasCloser"],_open:["validateOpen"],_on:["validateOn"]}}static get style(){return{default:defaultStyleCss}}},[289,"kol-drawer",{_open:[4],_align:[1],_hasCloser:[4,"_has-closer"],_label:[1],_on:[16],state:[32],open:[64],close:[64]},void 0,{_label:["validateLabel"],_align:["validateAlign"],_hasCloser:["validateHasCloser"],_open:["validateOpen"],_on:["validateOn"]}]);function defineCustomElement$1(){if("undefined"==typeof customElements)return;["kol-drawer"].forEach(e=>{if("kol-drawer"===e)customElements.get(e)||customElements.define(e,KolDrawer$1)})}const KolDrawer=KolDrawer$1,defineCustomElement=defineCustomElement$1;export{KolDrawer,defineCustomElement};
@@ -1 +1 @@
1
- {"file":"kol-drawer.js","mappings":";;;;;;;;;;;;;AAAA,MAAM,eAAe,GAAG,2uOAA2uO;;MCmBtvOA,WAAS,GAAAC,kBAAA,CAAA,MAAA,SAAA,SAAA,WAAA,CAAA;AAPtB,IAAA,WAAA,CAAA,YAAA,EAAA;;;;;;AA2CS,QAAA,IAAA,CAAA,aAAa,GAAG,CAAC,EAAoC,MAAM,IAAI,CAAC,oBAAoB,GAAG,EAA0B,CAAC;AAyBlH,QAAA,IAAA,CAAA,MAAM,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AC;AACvC,QAAA,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,GAAG,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["KolDrawer","__stencil_proxyCustomElement"],"sources":["src/components/drawer/style.scss?tag=kol-drawer&mode=default&encapsulation=shadow","src/components/drawer/shadow.tsx"],"sourcesContent":["@use '../../styles/global' as *;\n@use '../../styles/kol-card-mixin' as *;\n@use '../@shared/mixins' as *;\n@use '../tooltip/style.scss' as *;\n\n@layer kol-component {\n\t@include kol-card;\n\n\t.kol-drawer {\n\t\t$root: &;\n\n\t\t&__dialog {\n\t\t\tpadding: 0;\n\t\t\tborder: none;\n\t\t}\n\n\t\t&__wrapper {\n\t\t\tposition: fixed;\n\t\t\toverflow: auto;\n\n\t\t\t&--left,\n\t\t\t&--right {\n\t\t\t\ttop: 0;\n\t\t\t\tmax-width: 100vw;\n\t\t\t\theight: 100vh;\n\n\t\t\t\t#{$root}__content {\n\t\t\t\t\theight: 100%;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t&--left {\n\t\t\t\tleft: 0;\n\t\t\t}\n\n\t\t\t&--right {\n\t\t\t\tright: 0;\n\t\t\t}\n\n\t\t\t&--bottom,\n\t\t\t&--top {\n\t\t\t\tleft: 0;\n\t\t\t\twidth: 100vw;\n\t\t\t\tmax-height: 100vh;\n\n\t\t\t\t#{$root}__content {\n\t\t\t\t\twidth: 100%;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t&--bottom {\n\t\t\t\tbottom: 0;\n\t\t\t}\n\n\t\t\t&--top {\n\t\t\t\ttop: 0;\n\t\t\t}\n\t\t}\n\n\t\t&__content {\n\t\t\tposition: relative;\n\t\t}\n\t}\n}\n","/* eslint-disable jsx-a11y/no-noninteractive-element-interactions */\nimport type { AlignPropType, DrawerAPI, DrawerStates, HasCloserPropType, KoliBriModalEventCallbacks, LabelPropType, OpenPropType } from '../../schema';\nimport { setState, validateAlign, validateHasCloser, validateLabel, validateOpen } from '../../schema';\nimport type { JSX } from '@stencil/core';\nimport { Component, Element, h, Host, Method, Prop, State, Watch } from '@stencil/core';\nimport { dispatchDomEvent, KolEvent } from '../../utils/events';\nimport clsx from 'clsx';\nimport { KolCardWcTag } from '../../core/component-names';\n\n/**\n * @slot - The Content of drawer.\n */\n@Component({\n\ttag: 'kol-drawer',\n\tstyleUrls: {\n\t\tdefault: './style.scss',\n\t},\n\tshadow: true,\n})\nexport class KolDrawer implements DrawerAPI {\n\t@Element() private readonly host?: HTMLKolDetailsElement;\n\tprivate dialogElement?: HTMLDialogElement;\n\tprivate dialogWrapperElement?: HTMLKolCardWcElement;\n\n\t/**\n\t * Opens the drawer.\n\t */\n\t@Method()\n\t// eslint-disable-next-line @typescript-eslint/require-await\n\tasync open() {\n\t\tthis.state = {\n\t\t\t...this.state,\n\t\t\t_open: true,\n\t\t};\n\t\tthis.dialogElement?.showModal();\n\t}\n\n\t/**\n\t * Closes the drawer.\n\t */\n\t@Method()\n\t// eslint-disable-next-line @typescript-eslint/require-await\n\tasync close() {\n\t\tthis.state = {\n\t\t\t...this.state,\n\t\t\t_open: false,\n\t\t};\n\t\tconst wrapper = this.dialogWrapperElement;\n\t\tif (!wrapper) return;\n\t\tconst computedStyle = window.getComputedStyle(wrapper);\n\t\tif (computedStyle.animationName === 'none') {\n\t\t\tthis.handleCloseDialog();\n\t\t}\n\t}\n\n\tprivate getWrapperRef = (el: HTMLKolCardWcElement | undefined) => (this.dialogWrapperElement = el as HTMLKolCardWcElement);\n\tprivate renderDialogContent() {\n\t\tconst align = this.state._align as string;\n\t\treturn (\n\t\t\t<KolCardWcTag\n\t\t\t\tref={this.getWrapperRef}\n\t\t\t\tclass={clsx(`kol-drawer__wrapper`, `kol-drawer__wrapper--${align}`, {\n\t\t\t\t\t'kol-drawer__wrapper--open': this.state._open,\n\t\t\t\t\t'kol-drawer__wrapper--is-closing': this.state._open === false,\n\t\t\t\t})}\n\t\t\t\t_label={this.state._label}\n\t\t\t\t_hasCloser={this.state._hasCloser}\n\t\t\t\t_on={{\n\t\t\t\t\tonClose: () => {\n\t\t\t\t\t\tvoid this.close();\n\t\t\t\t\t},\n\t\t\t\t}}\n\t\t\t>\n\t\t\t\t<div class=\"kol-drawer__content\">\n\t\t\t\t\t<slot />\n\t\t\t\t</div>\n\t\t\t</KolCardWcTag>\n\t\t);\n\t}\n\n\tprivate getRef = (el: HTMLDialogElement | undefined) => {\n\t\tthis.dialogElement = el as HTMLDialogElement;\n\t\tsetTimeout(() => {\n\t\t\tvoid this.openOrCloseBasedOnState(); // handle initial state as soon as element is ready\n\t\t});\n\t};\n\tpublic render(): JSX.Element {\n\t\treturn (\n\t\t\t<Host class=\"kol-drawer\">\n\t\t\t\t<dialog aria-label={this.state._label} class=\"kol-drawer__dialog\" ref={this.getRef}>\n\t\t\t\t\t{this.renderDialogContent()}\n\t\t\t\t</dialog>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\t/**\n\t * Opens/expands the element when truthy, closes/collapses when falsy.\n\t */\n\t@Prop() public _open?: OpenPropType;\n\n\t/**\n\t * Defines the visual orientation of the component.\n\t */\n\t@Prop() public _align?: AlignPropType;\n\n\t/**\n\t * Defines whether the element can be closed.\n\t * @TODO: Change type back to `HasCloserPropType` after Stencil#4663 has been resolved.\n\t */\n\t@Prop() public _hasCloser?: boolean = false;\n\n\t/**\n\t * Defines the visible or semantic label of the component (e.g. aria-label, label, headline, caption, summary, etc.).\n\t */\n\t@Prop() public _label!: LabelPropType;\n\n\t/**\n\t * Specifies the EventCallback function to be called when the drawer is closing.\n\t */\n\t@Prop() public _on?: KoliBriModalEventCallbacks;\n\n\t@State() public state: DrawerStates = {\n\t\t_label: '', // ⚠ required\n\t\t_open: false,\n\t\t_align: 'left',\n\t};\n\n\t@Watch('_label')\n\tpublic validateLabel(value?: LabelPropType): void {\n\t\tvalidateLabel(this, value, {\n\t\t\trequired: true,\n\t\t});\n\t}\n\n\t@Watch('_align')\n\tpublic validateAlign(value?: AlignPropType): void {\n\t\tvalidateAlign(this, value);\n\t}\n\n\t@Watch('_hasCloser')\n\tpublic validateHasCloser(value?: HasCloserPropType): void {\n\t\tvalidateHasCloser(this, value);\n\t}\n\n\t@Watch('_open')\n\tpublic validateOpen(value?: OpenPropType) {\n\t\tif (typeof value === 'boolean') {\n\t\t\tvalidateOpen(this, value);\n\n\t\t\tif (this.dialogElement) {\n\t\t\t\t// handle property changes but not the initial validateOpen call\n\t\t\t\tvoid this.openOrCloseBasedOnState();\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate async openOrCloseBasedOnState() {\n\t\tif (this.state._open) {\n\t\t\tawait this.open();\n\t\t} else {\n\t\t\tawait this.close();\n\t\t}\n\t}\n\n\t@Watch('_on')\n\tpublic validateOn(value?: KoliBriModalEventCallbacks): void {\n\t\tif (typeof value === 'object' && value !== null) {\n\t\t\tconst callbacks: KoliBriModalEventCallbacks = {};\n\t\t\tif (typeof value.onClose === 'function') {\n\t\t\t\tcallbacks.onClose = value.onClose;\n\t\t\t}\n\t\t\tsetState<KoliBriModalEventCallbacks>(this, '_on', callbacks);\n\t\t}\n\t}\n\n\tprivate handleCloseDialog() {\n\t\tthis.dialogElement?.close();\n\t\tthis._on?.onClose?.();\n\t\tif (this.host) {\n\t\t\tdispatchDomEvent(this.host, KolEvent.close);\n\t\t}\n\t}\n\n\tprivate handleClose() {\n\t\tvoid (async () => {\n\t\t\tawait this.close();\n\t\t\tthis.handleCloseDialog();\n\t\t})();\n\t}\n\n\tprivate handleAnimationEnd(e: Event): void {\n\t\tconst animationEvent = e as AnimationEvent;\n\t\tif (animationEvent.animationName.includes('slideOut')) {\n\t\t\tthis.handleCloseDialog();\n\t\t}\n\t}\n\n\tpublic componentDidLoad(): void {\n\t\tthis.dialogElement?.addEventListener('animationend', this.handleAnimationEnd.bind(this));\n\t\tthis.dialogElement?.addEventListener('close', this.handleClose.bind(this));\n\t}\n\n\tpublic disconnectedCallback(): void {\n\t\tthis.dialogElement?.removeEventListener('animationend', this.handleAnimationEnd.bind(this));\n\t\tthis.dialogElement?.removeEventListener('close', this.handleClose.bind(this));\n\t}\n\n\tpublic componentWillLoad() {\n\t\tthis.validateLabel(this._label);\n\t\tthis.validateOpen(this._open);\n\t\tthis.validateAlign(this._align);\n\t\tthis.validateHasCloser(this._hasCloser);\n\t\tthis.validateOn(this._on);\n\t}\n}\n"],"version":3}
1
+ {"file":"kol-drawer.js","mappings":";;;;;;;;;;;;;;AAAA,MAAM,eAAe,GAAG,2uOAA2uO;;MCoBtvOA,WAAS,GAAAC,kBAAA,CAAA,MAAA,SAAA,SAAA,WAAA,CAAA;AAPtB,IAAA,WAAA,CAAA,YAAA,EAAA;;;;;;AA2CS,QAAA,IAAA,CAAA,aAAa,GAAG,CAAC,EAAoC,MAAM,IAAI,CAAC,oBAAoB,GAAG,EAA0B,CAAC;AAyBlH,QAAA,IAAA,CAAA,MAAM,GAAG,CAAC,EAAiC,KAAI;AACtD,YAAA,IAAI,CAAC,aAAa,GAAG,EAAuB;YAC5C,UAAU,CAAC,MAAK;AACf,gBAAA,KAAK,IAAI,CAAC,uBAAuB,EAAE;AACpC,aAAC,CAAC;AACH,SAAC;AAyBc,QAAA,IAAU,CAAA,UAAA,GAAa,KAAK;QAY3B,IAAA,CAAA,KAAK,GAAiB;AACrC,YAAA,MAAM,EAAE,EAAE;AACV,YAAA,KAAK,EAAE,KAAK;AACZ,YAAA,MAAM,EAAE,MAAM;SACd;AAyFD;AA1LA,IAAA,MAAM,IAAI,GAAA;;QACT,IAAI,CAAC,KAAK,GAAA,MAAA,CAAA,MAAA,CAAA,MAAA,CAAA,MAAA,CAAA,EAAA,EACN,IAAI,CAAC,KAAK,CAAA,EAAA,EACb,KAAK,EAAE,IAAI,EAAA,CACX;QACD,CAAA,EAAA,GAAA,IAAI,CAAC,aAAa,MAAE,IAAA,IAAA,EAAA,KAAA,MAAA,GAAA,MAAA,GAAA,EAAA,CAAA,SAAS,EAAE;;AAQhC,IAAA,MAAM,KAAK,GAAA;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MAAA,GAAA,MAAA,GAAA,EAAA,CAAA,mBAAmB,CAAC,cAAc,EAAE,IAAI,CAAC,kBAAkB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AAC3F,QAAA,CAAA,EAAA,GAAA,IAAI,CAAC,aAAa,MAAE,IAAA,IAAA,EAAA,KAAA,MAAA,GAAA,MAAA,GAAA,EAAA,CAAA,mBAAmB,CAAC,OAAO,EAAE,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;;IAGvE,iBAAiB,GAAA;AACvB,QAAA,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,MAAM,CAAC;AAC/B,QAAA,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,KAAK,CAAC;AAC7B,QAAA,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,MAAM,CAAC;AAC/B,QAAA,IAAI,CAAC,iBAAiB,CAAC,IAAI,CAAC,UAAU,CAAC;AACvC,QAAA,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,GAAG,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["KolDrawer","__stencil_proxyCustomElement"],"sources":["src/components/drawer/style.scss?tag=kol-drawer&mode=default&encapsulation=shadow","src/components/drawer/shadow.tsx"],"sourcesContent":["@use '../../styles/global' as *;\n@use '../../styles/kol-card-mixin' as *;\n@use '../@shared/mixins' as *;\n@use '../tooltip/style.scss' as *;\n\n@layer kol-component {\n\t@include kol-card;\n\n\t.kol-drawer {\n\t\t$root: &;\n\n\t\t&__dialog {\n\t\t\tpadding: 0;\n\t\t\tborder: none;\n\t\t}\n\n\t\t&__wrapper {\n\t\t\tposition: fixed;\n\t\t\toverflow: auto;\n\n\t\t\t&--left,\n\t\t\t&--right {\n\t\t\t\ttop: 0;\n\t\t\t\tmax-width: 100vw;\n\t\t\t\theight: 100vh;\n\n\t\t\t\t#{$root}__content {\n\t\t\t\t\theight: 100%;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t&--left {\n\t\t\t\tleft: 0;\n\t\t\t}\n\n\t\t\t&--right {\n\t\t\t\tright: 0;\n\t\t\t}\n\n\t\t\t&--bottom,\n\t\t\t&--top {\n\t\t\t\tleft: 0;\n\t\t\t\twidth: 100vw;\n\t\t\t\tmax-height: 100vh;\n\n\t\t\t\t#{$root}__content {\n\t\t\t\t\twidth: 100%;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t&--bottom {\n\t\t\t\tbottom: 0;\n\t\t\t}\n\n\t\t\t&--top {\n\t\t\t\ttop: 0;\n\t\t\t}\n\t\t}\n\n\t\t&__content {\n\t\t\tposition: relative;\n\t\t}\n\t}\n}\n","/* eslint-disable jsx-a11y/no-noninteractive-element-interactions */\nimport type { JSX } from '@stencil/core';\nimport { Component, Element, h, Host, Method, Prop, State, Watch } from '@stencil/core';\nimport clsx from 'clsx';\nimport { KolCardWcTag } from '../../core/component-names';\nimport type { AlignPropType, DrawerAPI, DrawerStates, HasCloserPropType, KoliBriModalEventCallbacks, LabelPropType, OpenPropType } from '../../schema';\nimport { setState, validateAlign, validateHasCloser, validateLabel, validateOpen } from '../../schema';\nimport { dispatchDomEvent, KolEvent } from '../../utils/events';\nimport { handleCancelOverlay } from '../../utils/tooltip-open-tracking';\n\n/**\n * @slot - The Content of drawer.\n */\n@Component({\n\ttag: 'kol-drawer',\n\tstyleUrls: {\n\t\tdefault: './style.scss',\n\t},\n\tshadow: true,\n})\nexport class KolDrawer implements DrawerAPI {\n\t@Element() private readonly host?: HTMLKolDetailsElement;\n\tprivate dialogElement?: HTMLDialogElement;\n\tprivate dialogWrapperElement?: HTMLKolCardWcElement;\n\n\t/**\n\t * Opens the drawer.\n\t */\n\t@Method()\n\t// eslint-disable-next-line @typescript-eslint/require-await\n\tasync open() {\n\t\tthis.state = {\n\t\t\t...this.state,\n\t\t\t_open: true,\n\t\t};\n\t\tthis.dialogElement?.showModal();\n\t}\n\n\t/**\n\t * Closes the drawer.\n\t */\n\t@Method()\n\t// eslint-disable-next-line @typescript-eslint/require-await\n\tasync close() {\n\t\tthis.state = {\n\t\t\t...this.state,\n\t\t\t_open: false,\n\t\t};\n\t\tconst wrapper = this.dialogWrapperElement;\n\t\tif (!wrapper) return;\n\t\tconst computedStyle = window.getComputedStyle(wrapper);\n\t\tif (computedStyle.animationName === 'none') {\n\t\t\tthis.handleCloseDialog();\n\t\t}\n\t}\n\n\tprivate getWrapperRef = (el: HTMLKolCardWcElement | undefined) => (this.dialogWrapperElement = el as HTMLKolCardWcElement);\n\tprivate renderDialogContent() {\n\t\tconst align = this.state._align as string;\n\t\treturn (\n\t\t\t<KolCardWcTag\n\t\t\t\tref={this.getWrapperRef}\n\t\t\t\tclass={clsx(`kol-drawer__wrapper`, `kol-drawer__wrapper--${align}`, {\n\t\t\t\t\t'kol-drawer__wrapper--open': this.state._open,\n\t\t\t\t\t'kol-drawer__wrapper--is-closing': this.state._open === false,\n\t\t\t\t})}\n\t\t\t\t_label={this.state._label}\n\t\t\t\t_hasCloser={this.state._hasCloser}\n\t\t\t\t_on={{\n\t\t\t\t\tonClose: () => {\n\t\t\t\t\t\tvoid this.close();\n\t\t\t\t\t},\n\t\t\t\t}}\n\t\t\t>\n\t\t\t\t<div class=\"kol-drawer__content\">\n\t\t\t\t\t<slot />\n\t\t\t\t</div>\n\t\t\t</KolCardWcTag>\n\t\t);\n\t}\n\n\tprivate getRef = (el: HTMLDialogElement | undefined) => {\n\t\tthis.dialogElement = el as HTMLDialogElement;\n\t\tsetTimeout(() => {\n\t\t\tvoid this.openOrCloseBasedOnState(); // handle initial state as soon as element is ready\n\t\t});\n\t};\n\tpublic render(): JSX.Element {\n\t\treturn (\n\t\t\t<Host class=\"kol-drawer\">\n\t\t\t\t<dialog aria-label={this.state._label} class=\"kol-drawer__dialog\" onCancel={handleCancelOverlay} ref={this.getRef}>\n\t\t\t\t\t{this.renderDialogContent()}\n\t\t\t\t</dialog>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\t/**\n\t * Opens/expands the element when truthy, closes/collapses when falsy.\n\t */\n\t@Prop() public _open?: OpenPropType;\n\n\t/**\n\t * Defines the visual orientation of the component.\n\t */\n\t@Prop() public _align?: AlignPropType;\n\n\t/**\n\t * Defines whether the element can be closed.\n\t * @TODO: Change type back to `HasCloserPropType` after Stencil#4663 has been resolved.\n\t */\n\t@Prop() public _hasCloser?: boolean = false;\n\n\t/**\n\t * Defines the visible or semantic label of the component (e.g. aria-label, label, headline, caption, summary, etc.).\n\t */\n\t@Prop() public _label!: LabelPropType;\n\n\t/**\n\t * Specifies the EventCallback function to be called when the drawer is closing.\n\t */\n\t@Prop() public _on?: KoliBriModalEventCallbacks;\n\n\t@State() public state: DrawerStates = {\n\t\t_label: '', // ⚠ required\n\t\t_open: false,\n\t\t_align: 'left',\n\t};\n\n\t@Watch('_label')\n\tpublic validateLabel(value?: LabelPropType): void {\n\t\tvalidateLabel(this, value, {\n\t\t\trequired: true,\n\t\t});\n\t}\n\n\t@Watch('_align')\n\tpublic validateAlign(value?: AlignPropType): void {\n\t\tvalidateAlign(this, value);\n\t}\n\n\t@Watch('_hasCloser')\n\tpublic validateHasCloser(value?: HasCloserPropType): void {\n\t\tvalidateHasCloser(this, value);\n\t}\n\n\t@Watch('_open')\n\tpublic validateOpen(value?: OpenPropType) {\n\t\tif (typeof value === 'boolean') {\n\t\t\tvalidateOpen(this, value);\n\n\t\t\tif (this.dialogElement) {\n\t\t\t\t// handle property changes but not the initial validateOpen call\n\t\t\t\tvoid this.openOrCloseBasedOnState();\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate async openOrCloseBasedOnState() {\n\t\tif (this.state._open) {\n\t\t\tawait this.open();\n\t\t} else {\n\t\t\tawait this.close();\n\t\t}\n\t}\n\n\t@Watch('_on')\n\tpublic validateOn(value?: KoliBriModalEventCallbacks): void {\n\t\tif (typeof value === 'object' && value !== null) {\n\t\t\tconst callbacks: KoliBriModalEventCallbacks = {};\n\t\t\tif (typeof value.onClose === 'function') {\n\t\t\t\tcallbacks.onClose = value.onClose;\n\t\t\t}\n\t\t\tsetState<KoliBriModalEventCallbacks>(this, '_on', callbacks);\n\t\t}\n\t}\n\n\tprivate handleCloseDialog() {\n\t\tthis.dialogElement?.close();\n\t\tthis._on?.onClose?.();\n\t\tif (this.host) {\n\t\t\tdispatchDomEvent(this.host, KolEvent.close);\n\t\t}\n\t}\n\n\tprivate handleClose() {\n\t\tvoid (async () => {\n\t\t\tawait this.close();\n\t\t\tthis.handleCloseDialog();\n\t\t})();\n\t}\n\n\tprivate handleAnimationEnd(e: Event): void {\n\t\tconst animationEvent = e as AnimationEvent;\n\t\tif (animationEvent.animationName.includes('slideOut')) {\n\t\t\tthis.handleCloseDialog();\n\t\t}\n\t}\n\n\tpublic componentDidLoad(): void {\n\t\tthis.dialogElement?.addEventListener('animationend', this.handleAnimationEnd.bind(this));\n\t\tthis.dialogElement?.addEventListener('close', this.handleClose.bind(this));\n\t}\n\n\tpublic disconnectedCallback(): void {\n\t\tthis.dialogElement?.removeEventListener('animationend', this.handleAnimationEnd.bind(this));\n\t\tthis.dialogElement?.removeEventListener('close', this.handleClose.bind(this));\n\t}\n\n\tpublic componentWillLoad() {\n\t\tthis.validateLabel(this._label);\n\t\tthis.validateOpen(this._open);\n\t\tthis.validateAlign(this._align);\n\t\tthis.validateHasCloser(this._hasCloser);\n\t\tthis.validateOn(this._on);\n\t}\n}\n"],"version":3}
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{proxyCustomElement,HTMLElement,h,Host}from"@stencil/core/internal/client";import{w as watchValidator,c as watchBoolean,h as watchString}from"./common.js";import{t as translate}from"./i18n.js";import{f as KolLinkWcTag}from"./component-names.js";import{K as KolAlertFc}from"./Alert.js";import{d as dispatchDomEvent,K as KolEvent}from"./events.js";const validateErrorList=(n,e)=>{watchValidator(n,"errorList",n=>Array.isArray(n)&&void 0===n.find(n=>!("string"==typeof n||"function"==typeof n)),new Set(["string","function"]),e)},defaultStyleCss="/* forward the rem function */\n/*\n* This file defines the layer order for all CSS layers used in KoliBri.\n* The order is important as it determines the cascade priority.\n*\n* Layer order (lowest to highest priority):\n* 1. kol-a11y - Accessibility defaults and requirements\n* 2. kol-global - Global component styles and resets\n* 3. kol-component - Component-specific styles\n* 4. kol-theme-global - Theme-specific global styles\n* 5. kol-theme-component - Theme-specific component styles\n*/\n@layer kol-a11y, kol-global, kol-component, kol-theme-global, kol-theme-component;\n/*\n * This file contains all rules for accessibility.\n */\n@layer kol-a11y {\n :host {\n /*\n * Minimum size of interactive elements.\n */\n --a11y-min-size: calc(44 * 1rem / var(--kolibri-root-font-size, 16));\n /*\n * No element should be used without verifying the contrast ratio of its background and font colors.\n * By initially setting the background color to white and the font color to black,\n * the contrast ratio is ensured and explicit adjustment is forced.\n */\n color: black;\n background-color: white;\n /*\n * Verdana is an accessible font that can be used without requiring additional loading time.\n */\n font-family: Verdana;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n * {\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n hyphens: auto;\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n word-break: break-word;\n }\n /*\n * All interactive elements should have a minimum size of to-rem(44).\n */\n /* input:not([type='checkbox'], [type='radio'], [type='range']), */\n /* option, */\n /* select, */\n /* textarea, */\n button,\n .kol-input .input {\n min-width: var(--a11y-min-size);\n min-height: var(--a11y-min-size);\n }\n /*\n * Some interactive elements should not inherit the font-family and font-size.\n */\n a,\n button,\n h1,\n h2,\n h3,\n h4,\n h5,\n h6,\n input,\n option,\n select,\n textarea {\n /*\n * All elements should inherit the font family from his parent element.\n */\n font-family: inherit;\n /*\n * All elements should inherit the font size from his parent element.\n */\n font-size: inherit;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n /**\n * Sometimes we need the semantic element for accessibility reasons,\n * but we don't want to show it.\n *\n * - https://www.a11yproject.com/posts/how-to-hide-content/\n */\n .visually-hidden {\n position: fixed;\n top: 0;\n left: 0;\n width: 1px;\n height: 1px;\n overflow: hidden;\n white-space: nowrap;\n clip-path: inset(50%);\n }\n}\n@layer kol-global {\n /*\n * Dieses CSS stellt sicher, dass der Standard-Style\n * von A und Button resettet werden.\n */\n :is(a, button) {\n background-color: transparent;\n width: 100%;\n margin: 0;\n padding: 0;\n border: none;\n /* 100% needed for custom width from outside */\n }\n /*\n * Ensure elements with hidden attribute to be actually not visible\n * @see https://meowni.ca/hidden.is.a.lie.html\n */\n [hidden] {\n display: none !important;\n }\n .badge-text-hint {\n color: black;\n background-color: lightgray;\n }\n}\n@layer kol-global {\n :host {\n /*\n * The max-width is needed to prevent the table from overflowing the\n * parent node, if the table is wider than the parent node.\n */\n max-width: 100%;\n font-size: calc(16 * 1rem / var(--kolibri-root-font-size, 16));\n }\n * {\n /*\n * We prefer to box-sizing: border-box for all elements.\n */\n box-sizing: border-box;\n }\n .kol-span {\n /* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n display: grid;\n place-items: center;\n /* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n }\n .kol-span__container {\n display: flex;\n place-items: center;\n }\n a,\n button {\n cursor: pointer;\n }\n .kol-span .kol-span__label--hide-label .kol-span__label {\n display: none;\n }\n /* Reset browser agent style. */\n button:disabled {\n color: unset;\n }\n .disabled label,\n .disabled:focus-within label,\n [aria-disabled=true],\n [aria-disabled=true]:focus,\n [disabled],\n [disabled]:focus {\n opacity: 0.5;\n outline: none;\n cursor: not-allowed;\n }\n [aria-disabled=true]:focus .kol-span,\n [disabled]:focus .kol-span {\n outline: none !important;\n }\n}\n@layer kol-component {\n :host {\n display: block;\n }\n}\n@layer kol-component {\n @keyframes fadeInOpacity {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n }\n .kol-tooltip {\n display: contents;\n }\n .kol-tooltip__floating {\n display: none;\n position: fixed;\n /* Avoid layout interference - see https://floating-ui.com/docs/computePosition */\n top: 0;\n left: 0;\n /* Can be used to specify the tooltip-width from the outside. Unset by default. */\n width: var(--kol-tooltip-width, max-content);\n min-width: calc(8 * 1rem / var(--kolibri-root-font-size, 16));\n max-width: 90vw;\n max-height: 90vh;\n visibility: hidden;\n animation-duration: 0.25s;\n animation-iteration-count: 1;\n animation-name: fadeInOpacity;\n animation-timing-function: ease-in;\n }\n .kol-tooltip__arrow {\n transform: rotate(45deg);\n color: #000;\n background-color: #fff;\n position: absolute;\n z-index: 999;\n width: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n height: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n }\n .kol-tooltip__content {\n color: #000;\n background-color: #fff;\n position: relative;\n z-index: 1000;\n }\n}\n@layer kol-component {\n :host {\n display: inline-block;\n }\n .kol-link {\n display: inline-flex;\n align-items: baseline;\n place-items: center;\n text-align: left;\n text-decoration-line: none;\n }\n .kol-link--standalone {\n min-width: var(--a11y-min-size);\n min-height: var(--a11y-min-size);\n }\n .kol-link__text .kol-span__label {\n text-decoration-line: underline;\n }\n .kol-link:is(:focus, :hover):not([aria-disabled], [disabled]) .kol-link__text .kol-span__label {\n text-decoration-thickness: 0.2em;\n }\n .kol-link__icon {\n display: inline-flex;\n margin-left: calc(8 * 1rem / var(--kolibri-root-font-size, 16));\n }\n .kol-alert {\n display: grid;\n }\n .kol-alert__container {\n display: flex;\n place-items: center;\n }\n .kol-alert__container-content {\n flex-grow: 1;\n }\n .kol-alert__closer {\n /* Visible with forced colors */\n outline: transparent solid calc(1 * 1rem / var(--kolibri-root-font-size, 16));\n }\n}",KolForm$1=proxyCustomElement(class extends HTMLElement{constructor(n){super(),!1!==n&&this.__registerHost(),this.__attachShadow(),this.translateErrorListMessage=translate("kol-error-list-message"),this.translateErrorList=translate("kol-error-list"),this.translateFormDescription=translate("kol-form-description"),this.onSubmit=n=>{var e,t;n.preventDefault(),"function"==typeof(null===(e=this.state._on)||void 0===e?void 0:e.onSubmit)&&(null===(t=this.state._on)||void 0===t||t.onSubmit(n)),this.host&&dispatchDomEvent(this.host,KolEvent.submit)},this.onReset=n=>{var e,t;n.preventDefault(),"function"==typeof(null===(e=this.state._on)||void 0===e?void 0:e.onReset)&&(null===(t=this.state._on)||void 0===t||t.onReset(n)),this.host&&dispatchDomEvent(this.host,KolEvent.reset)},this.handleLinkClick=n=>{const e=document.querySelector(n);e&&"function"==typeof e.focus&&(e.scrollIntoView({behavior:"smooth"}),e.focus())},this.setBlockElement=n=>this.errorListBlock=n,this.setFirstLinkElement=n=>this.errorListFirstLink=n,this._requiredText=!0,this.state={}}renderErrorList(n){return h(KolAlertFc,{class:"kol-form__alert",ref:this.setBlockElement,type:"error",variant:"card",label:this.translateErrorListMessage},h("nav",{"aria-label":this.translateErrorList},h("ul",null,null==n?void 0:n.map((n,e)=>h("li",{key:e},h(KolLinkWcTag,{class:"kol-form__link",_href:"",_label:n.message,_on:{onClick:"string"==typeof n.selector?()=>this.handleLinkClick(String(n.selector)):n.selector},ref:0===e?this.setFirstLinkElement:void 0}))))))}renderFormElement(){return h("form",{class:"kol-form",method:"post",onSubmit:this.onSubmit,onReset:this.onReset,noValidate:!0},!0===this.state._requiredText?h("p",null,h("div",{class:"kol-form__mandatory-fields-hint"},this.translateFormDescription)):"string"==typeof this.state._requiredText&&this.state._requiredText.length>0?h("p",null,h("div",{class:"kol-form__mandatory-fields-hint"},this.state._requiredText)):null,h("slot",null))}render(){const n=Array.isArray(this._errorList)&&this._errorList.length>0;return h(Host,{key:"129655c9f0160c5c3eb6801253953b52c9649031"},n&&this.renderErrorList(this._errorList),this.renderFormElement())}scrollToErrorList(){var n;null===(n=this.errorListBlock)||void 0===n||n.scrollIntoView({behavior:"smooth",block:"start"}),setTimeout(()=>{var n,e;null===(e=null===(n=this.errorListFirstLink)||void 0===n?void 0:n.querySelector("a"))||void 0===e||e.focus()},250)}async focusErrorList(){return this.scrollToErrorList(),Promise.resolve()}validateOn(n){"object"==typeof n&&null!==n&&(this.state=Object.assign(Object.assign({},this.state),{_on:n}))}validateRequiredText(n){"boolean"==typeof n?watchBoolean(this,"_requiredText",n):watchString(this,"_requiredText",n)}validateErrorList(n){validateErrorList(this,n)}componentWillLoad(){this.validateOn(this._on),this.validateRequiredText(this._requiredText),this.validateErrorList(this._errorList)}get host(){return this}static get watchers(){return{_on:["validateOn"],_requiredText:["validateRequiredText"],_errorList:["validateErrorList"]}}static get style(){return{default:defaultStyleCss}}},[289,"kol-form",{_on:[16],_requiredText:[8,"_required-text"],_errorList:[16,"_error-list"],state:[32],focusErrorList:[64]},void 0,{_on:["validateOn"],_requiredText:["validateRequiredText"],_errorList:["validateErrorList"]}]);function defineCustomElement$1(){if("undefined"==typeof customElements)return;["kol-form"].forEach(n=>{if("kol-form"===n)customElements.get(n)||customElements.define(n,KolForm$1)})}const KolForm=KolForm$1,defineCustomElement=defineCustomElement$1;export{KolForm,defineCustomElement};
4
+ import{proxyCustomElement,HTMLElement,h,Host}from"@stencil/core/internal/client";import{w as watchValidator,c as watchBoolean,h as watchString}from"./common.js";import{t as translate}from"./i18n.js";import{f as KolLinkWcTag}from"./component-names.js";import{K as KolAlertFc}from"./Alert.js";import{d as dispatchDomEvent,K as KolEvent}from"./events.js";const validateErrorList=(n,e)=>{watchValidator(n,"errorList",n=>Array.isArray(n)&&void 0===n.find(n=>!("string"==typeof n||"function"==typeof n)),new Set(["string","function"]),e)},defaultStyleCss="/* forward the rem function */\n/*\n* This file defines the layer order for all CSS layers used in KoliBri.\n* The order is important as it determines the cascade priority.\n*\n* Layer order (lowest to highest priority):\n* 1. kol-a11y - Accessibility defaults and requirements\n* 2. kol-global - Global component styles and resets\n* 3. kol-component - Component-specific styles\n* 4. kol-theme-global - Theme-specific global styles\n* 5. kol-theme-component - Theme-specific component styles\n*/\n@layer kol-a11y, kol-global, kol-component, kol-theme-global, kol-theme-component;\n/*\n * This file contains all rules for accessibility.\n */\n@layer kol-a11y {\n :host {\n /*\n * Minimum size of interactive elements.\n */\n --a11y-min-size: calc(44 * 1rem / var(--kolibri-root-font-size, 16));\n /*\n * No element should be used without verifying the contrast ratio of its background and font colors.\n * By initially setting the background color to white and the font color to black,\n * the contrast ratio is ensured and explicit adjustment is forced.\n */\n color: black;\n background-color: white;\n /*\n * Verdana is an accessible font that can be used without requiring additional loading time.\n */\n font-family: Verdana;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n * {\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n hyphens: auto;\n /*\n * This rule enables the word dividing for all texts. That is important for high zoom levels.\n */\n word-break: break-word;\n }\n /*\n * All interactive elements should have a minimum size of to-rem(44).\n */\n /* input:not([type='checkbox'], [type='radio'], [type='range']), */\n /* option, */\n /* select, */\n /* textarea, */\n button,\n .kol-input .input {\n min-width: var(--a11y-min-size);\n min-height: var(--a11y-min-size);\n }\n /*\n * Some interactive elements should not inherit the font-family and font-size.\n */\n a,\n button,\n h1,\n h2,\n h3,\n h4,\n h5,\n h6,\n input,\n option,\n select,\n textarea {\n /*\n * All elements should inherit the font family from his parent element.\n */\n font-family: inherit;\n /*\n * All elements should inherit the font size from his parent element.\n */\n font-size: inherit;\n /*\n * Letter spacing is required for all texts.\n */\n letter-spacing: inherit;\n /*\n * Word spacing is required for all texts.\n */\n word-spacing: inherit;\n }\n /**\n * Sometimes we need the semantic element for accessibility reasons,\n * but we don't want to show it.\n *\n * - https://www.a11yproject.com/posts/how-to-hide-content/\n */\n .visually-hidden {\n position: fixed;\n top: 0;\n left: 0;\n width: 1px;\n height: 1px;\n overflow: hidden;\n white-space: nowrap;\n clip-path: inset(50%);\n }\n}\n@layer kol-global {\n /*\n * Dieses CSS stellt sicher, dass der Standard-Style\n * von A und Button resettet werden.\n */\n :is(a, button) {\n background-color: transparent;\n width: 100%;\n margin: 0;\n padding: 0;\n border: none;\n /* 100% needed for custom width from outside */\n }\n /*\n * Ensure elements with hidden attribute to be actually not visible\n * @see https://meowni.ca/hidden.is.a.lie.html\n */\n [hidden] {\n display: none !important;\n }\n .badge-text-hint {\n color: black;\n background-color: lightgray;\n }\n}\n@layer kol-global {\n :host {\n /*\n * The max-width is needed to prevent the table from overflowing the\n * parent node, if the table is wider than the parent node.\n */\n max-width: 100%;\n font-size: calc(16 * 1rem / var(--kolibri-root-font-size, 16));\n }\n * {\n /*\n * We prefer to box-sizing: border-box for all elements.\n */\n box-sizing: border-box;\n }\n .kol-span {\n /* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n display: grid;\n place-items: center;\n /* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n }\n .kol-span__container {\n display: flex;\n place-items: center;\n }\n a,\n button {\n cursor: pointer;\n }\n .kol-span .kol-span__label--hide-label .kol-span__label {\n display: none;\n }\n /* Reset browser agent style. */\n button:disabled {\n color: unset;\n }\n .disabled label,\n .disabled:focus-within label,\n [aria-disabled=true],\n [aria-disabled=true]:focus,\n [disabled],\n [disabled]:focus {\n opacity: 0.5;\n outline: none;\n cursor: not-allowed;\n }\n [aria-disabled=true]:focus .kol-span,\n [disabled]:focus .kol-span {\n outline: none !important;\n }\n}\n@layer kol-component {\n :host {\n display: block;\n }\n}\n@layer kol-component {\n @keyframes fadeInOpacity {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n }\n .kol-tooltip {\n display: contents;\n }\n .kol-tooltip__floating {\n display: none;\n position: fixed;\n /* Avoid layout interference - see https://floating-ui.com/docs/computePosition */\n top: 0;\n left: 0;\n /* Can be used to specify the tooltip-width from the outside. Unset by default. */\n width: var(--kol-tooltip-width, max-content);\n min-width: calc(8 * 1rem / var(--kolibri-root-font-size, 16));\n max-width: 90vw;\n max-height: 90vh;\n visibility: hidden;\n animation-duration: 0.25s;\n animation-iteration-count: 1;\n animation-name: fadeInOpacity;\n animation-timing-function: ease-in;\n }\n .kol-tooltip__arrow {\n transform: rotate(45deg);\n color: #000;\n background-color: #fff;\n position: absolute;\n z-index: 999;\n width: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n height: calc(10 * 1rem / var(--kolibri-root-font-size, 16));\n }\n .kol-tooltip__content {\n color: #000;\n background-color: #fff;\n position: relative;\n z-index: 1000;\n }\n}\n@layer kol-component {\n :host {\n display: inline-block;\n }\n .kol-link {\n display: inline-flex;\n max-width: fit-content;\n align-items: baseline;\n place-items: center;\n text-align: left;\n text-decoration-line: none;\n }\n .kol-link--standalone {\n min-width: var(--a11y-min-size);\n min-height: var(--a11y-min-size);\n }\n .kol-link__text .kol-span__label {\n text-decoration-line: underline;\n }\n .kol-link:is(:focus, :hover):not([aria-disabled], [disabled]) .kol-link__text .kol-span__label {\n text-decoration-thickness: 0.2em;\n }\n .kol-link__icon {\n display: inline-flex;\n margin-left: calc(8 * 1rem / var(--kolibri-root-font-size, 16));\n }\n .kol-alert {\n display: grid;\n }\n .kol-alert__container {\n display: flex;\n place-items: center;\n }\n .kol-alert__container-content {\n flex-grow: 1;\n }\n .kol-alert__closer {\n /* Visible with forced colors */\n outline: transparent solid calc(1 * 1rem / var(--kolibri-root-font-size, 16));\n }\n}",KolForm$1=proxyCustomElement(class extends HTMLElement{constructor(n){super(),!1!==n&&this.__registerHost(),this.__attachShadow(),this.translateErrorListMessage=translate("kol-error-list-message"),this.translateErrorList=translate("kol-error-list"),this.translateFormDescription=translate("kol-form-description"),this.onSubmit=n=>{var e,t;n.preventDefault(),"function"==typeof(null===(e=this.state._on)||void 0===e?void 0:e.onSubmit)&&(null===(t=this.state._on)||void 0===t||t.onSubmit(n)),this.host&&dispatchDomEvent(this.host,KolEvent.submit)},this.onReset=n=>{var e,t;n.preventDefault(),"function"==typeof(null===(e=this.state._on)||void 0===e?void 0:e.onReset)&&(null===(t=this.state._on)||void 0===t||t.onReset(n)),this.host&&dispatchDomEvent(this.host,KolEvent.reset)},this.handleLinkClick=n=>{const e=document.querySelector(n);e&&"function"==typeof e.focus&&(e.scrollIntoView({behavior:"smooth"}),e.focus())},this.setBlockElement=n=>this.errorListBlock=n,this.setFirstLinkElement=n=>this.errorListFirstLink=n,this._requiredText=!0,this.state={}}renderErrorList(n){return h(KolAlertFc,{class:"kol-form__alert",ref:this.setBlockElement,type:"error",variant:"card",label:this.translateErrorListMessage},h("nav",{"aria-label":this.translateErrorList},h("ul",null,null==n?void 0:n.map((n,e)=>h("li",{key:e},h(KolLinkWcTag,{class:"kol-form__link",_href:"",_label:n.message,_on:{onClick:"string"==typeof n.selector?()=>this.handleLinkClick(String(n.selector)):n.selector},ref:0===e?this.setFirstLinkElement:void 0}))))))}renderFormElement(){return h("form",{class:"kol-form",method:"post",onSubmit:this.onSubmit,onReset:this.onReset,noValidate:!0},!0===this.state._requiredText?h("p",null,h("div",{class:"kol-form__mandatory-fields-hint"},this.translateFormDescription)):"string"==typeof this.state._requiredText&&this.state._requiredText.length>0?h("p",null,h("div",{class:"kol-form__mandatory-fields-hint"},this.state._requiredText)):null,h("slot",null))}render(){const n=Array.isArray(this._errorList)&&this._errorList.length>0;return h(Host,{key:"9664175b745ee7a365e58e902f626bde0e07a99b"},n&&this.renderErrorList(this._errorList),this.renderFormElement())}scrollToErrorList(){var n;null===(n=this.errorListBlock)||void 0===n||n.scrollIntoView({behavior:"smooth",block:"start"}),setTimeout(()=>{var n,e;null===(e=null===(n=this.errorListFirstLink)||void 0===n?void 0:n.querySelector("a"))||void 0===e||e.focus()},250)}async focusErrorList(){return this.scrollToErrorList(),Promise.resolve()}validateOn(n){"object"==typeof n&&null!==n&&(this.state=Object.assign(Object.assign({},this.state),{_on:n}))}validateRequiredText(n){"boolean"==typeof n?watchBoolean(this,"_requiredText",n):watchString(this,"_requiredText",n)}validateErrorList(n){validateErrorList(this,n)}componentWillLoad(){this.validateOn(this._on),this.validateRequiredText(this._requiredText),this.validateErrorList(this._errorList)}get host(){return this}static get watchers(){return{_on:["validateOn"],_requiredText:["validateRequiredText"],_errorList:["validateErrorList"]}}static get style(){return{default:defaultStyleCss}}},[289,"kol-form",{_on:[16],_requiredText:[8,"_required-text"],_errorList:[16,"_error-list"],state:[32],focusErrorList:[64]},void 0,{_on:["validateOn"],_requiredText:["validateRequiredText"],_errorList:["validateErrorList"]}]);function defineCustomElement$1(){if("undefined"==typeof customElements)return;["kol-form"].forEach(n=>{if("kol-form"===n)customElements.get(n)||customElements.define(n,KolForm$1)})}const KolForm=KolForm$1,defineCustomElement=defineCustomElement$1;export{KolForm,defineCustomElement};