@public-ui/components 2.0.0-rc.6 → 2.0.0-rc.8

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 (451) hide show
  1. package/custom-elements.json +1 -1
  2. package/dist/cjs/{a11y.tipps-91e6a303.js → a11y.tipps-c9682dc9.js} +1 -1
  3. package/dist/cjs/{a11y.tipps-91e6a303.js.map → a11y.tipps-c9682dc9.js.map} +1 -1
  4. package/dist/cjs/access-key-9c2d35b1.js +4 -0
  5. package/dist/cjs/{access-key-5fe7eedb.js.map → access-key-9c2d35b1.js.map} +1 -1
  6. package/dist/cjs/{alignment-86e87aca.js → alignment-a8499755.js} +1 -1
  7. package/dist/cjs/{alignment-86e87aca.js.map → alignment-a8499755.js.map} +1 -1
  8. package/dist/cjs/alternative-button-link-role-c28b468f.js +4 -0
  9. package/dist/cjs/{alternative-button-link-role-d99da0f8.js.map → alternative-button-link-role-c28b468f.js.map} +1 -1
  10. package/dist/cjs/{app-globals-ac58ae8f.js → app-globals-52d99c30.js} +1 -1
  11. package/dist/cjs/{app-globals-ac58ae8f.js.map → app-globals-52d99c30.js.map} +1 -1
  12. package/dist/cjs/{associated.controller-2d107864.js → associated.controller-e37fdad4.js} +1 -1
  13. package/dist/cjs/{associated.controller-2d107864.js.map → associated.controller-e37fdad4.js.map} +1 -1
  14. package/dist/cjs/{color-03e36edf.js → color-cf957ff4.js} +1 -1
  15. package/dist/cjs/{color-03e36edf.js.map → color-cf957ff4.js.map} +1 -1
  16. package/dist/cjs/{controller-19b94b08.js → controller-5a6a89c4.js} +1 -1
  17. package/dist/cjs/{controller-19b94b08.js.map → controller-5a6a89c4.js.map} +1 -1
  18. package/dist/cjs/{controller-120e1333.js → controller-5e82e39c.js} +1 -1
  19. package/dist/cjs/{controller-120e1333.js.map → controller-5e82e39c.js.map} +1 -1
  20. package/dist/cjs/{controller-ee271465.js → controller-5f33446f.js} +1 -1
  21. package/dist/cjs/{controller-ee271465.js.map → controller-5f33446f.js.map} +1 -1
  22. package/dist/cjs/{controller-c15b473b.js → controller-62e7f4d4.js} +1 -1
  23. package/dist/cjs/{controller-c15b473b.js.map → controller-62e7f4d4.js.map} +1 -1
  24. package/dist/cjs/{controller-56885ef0.js → controller-cd27f197.js} +1 -1
  25. package/dist/cjs/{controller-56885ef0.js.map → controller-cd27f197.js.map} +1 -1
  26. package/dist/cjs/{controller-icon-f7b60716.js → controller-icon-8b602e6a.js} +1 -1
  27. package/dist/cjs/{controller-icon-f7b60716.js.map → controller-icon-8b602e6a.js.map} +1 -1
  28. package/dist/cjs/custom-class-82b756d7.js +4 -0
  29. package/dist/cjs/{custom-class-ed101b87.js.map → custom-class-82b756d7.js.map} +1 -1
  30. package/dist/cjs/{dev.utils-5f0c3b7d.js → dev.utils-80099077.js} +1 -1
  31. package/dist/cjs/{dev.utils-5f0c3b7d.js.map → dev.utils-80099077.js.map} +1 -1
  32. package/dist/cjs/{devtools-26e86ead.js → devtools-a49b8ec9.js} +1 -1
  33. package/dist/cjs/{devtools-26e86ead.js.map → devtools-a49b8ec9.js.map} +1 -1
  34. package/dist/cjs/has-closer-21f24bf0.js +4 -0
  35. package/dist/cjs/{has-closer-0140b049.js.map → has-closer-21f24bf0.js.map} +1 -1
  36. package/dist/cjs/hide-label-63295094.js +4 -0
  37. package/dist/cjs/{hide-label-72171d2b.js.map → hide-label-63295094.js.map} +1 -1
  38. package/dist/cjs/{i18n-42767646.js → i18n-b0531c4a.js} +1 -1
  39. package/dist/cjs/{i18n-42767646.js.map → i18n-b0531c4a.js.map} +1 -1
  40. package/dist/cjs/{icons-6be116f2.js → icons-26b30637.js} +1 -1
  41. package/dist/cjs/{icons-6be116f2.js.map → icons-26b30637.js.map} +1 -1
  42. package/dist/cjs/image-source-fe99810d.js +4 -0
  43. package/dist/cjs/{image-source-f283f0ea.js.map → image-source-fe99810d.js.map} +1 -1
  44. package/dist/cjs/{index-d12ab3a8.js → index-01cee031.js} +1 -1
  45. package/dist/cjs/{index-d12ab3a8.js.map → index-01cee031.js.map} +1 -1
  46. package/dist/cjs/index.cjs.js +1 -1
  47. package/dist/cjs/kol-abbr.cjs.entry.js +1 -1
  48. package/dist/cjs/kol-accordion.cjs.entry.js +1 -1
  49. package/dist/cjs/kol-accordion.cjs.entry.js.map +1 -1
  50. package/dist/cjs/kol-alert-wc_2.cjs.entry.js +1 -1
  51. package/dist/cjs/kol-avatar-wc.cjs.entry.js +1 -1
  52. package/dist/cjs/kol-badge.cjs.entry.js +1 -1
  53. package/dist/cjs/kol-breadcrumb.cjs.entry.js +1 -1
  54. package/dist/cjs/kol-button-link.cjs.entry.js +1 -1
  55. package/dist/cjs/kol-button-link.cjs.entry.js.map +1 -1
  56. package/dist/cjs/kol-button-wc_2.cjs.entry.js +1 -1
  57. package/dist/cjs/kol-button.cjs.entry.js +1 -1
  58. package/dist/cjs/kol-button.cjs.entry.js.map +1 -1
  59. package/dist/cjs/kol-card.cjs.entry.js +1 -1
  60. package/dist/cjs/kol-details.cjs.entry.js +1 -1
  61. package/dist/cjs/kol-details.cjs.entry.js.map +1 -1
  62. package/dist/cjs/kol-form.cjs.entry.js +1 -1
  63. package/dist/cjs/kol-icon.cjs.entry.js +1 -1
  64. package/dist/cjs/kol-image.cjs.entry.js +1 -1
  65. package/dist/cjs/kol-image.cjs.entry.js.map +1 -1
  66. package/dist/cjs/kol-input-checkbox.cjs.entry.js +1 -1
  67. package/dist/cjs/kol-input-checkbox.cjs.entry.js.map +1 -1
  68. package/dist/cjs/kol-input-color.cjs.entry.js +1 -1
  69. package/dist/cjs/kol-input-date.cjs.entry.js +1 -1
  70. package/dist/cjs/kol-input-email.cjs.entry.js +1 -1
  71. package/dist/cjs/kol-input-file.cjs.entry.js +1 -1
  72. package/dist/cjs/kol-input-number.cjs.entry.js +1 -1
  73. package/dist/cjs/kol-input-password.cjs.entry.js +1 -1
  74. package/dist/cjs/kol-input-radio.cjs.entry.js +1 -1
  75. package/dist/cjs/kol-input-radio.cjs.entry.js.map +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-input.cjs.entry.js +1 -1
  79. package/dist/cjs/kol-kolibri.cjs.entry.js +1 -1
  80. package/dist/cjs/kol-link-button.cjs.entry.js +1 -1
  81. package/dist/cjs/kol-link-button.cjs.entry.js.map +1 -1
  82. package/dist/cjs/kol-link-group.cjs.entry.js +1 -1
  83. package/dist/cjs/kol-link-wc.cjs.entry.js +1 -1
  84. package/dist/cjs/kol-link.cjs.entry.js +1 -1
  85. package/dist/cjs/kol-link.cjs.entry.js.map +1 -1
  86. package/dist/cjs/kol-logo.cjs.entry.js +1 -1
  87. package/dist/cjs/kol-modal.cjs.entry.js +1 -1
  88. package/dist/cjs/kol-nav.cjs.entry.js +1 -1
  89. package/dist/cjs/kol-pagination.cjs.entry.js +1 -1
  90. package/dist/cjs/kol-popover.cjs.entry.js +1 -1
  91. package/dist/cjs/kol-progress.cjs.entry.js +1 -1
  92. package/dist/cjs/kol-quote.cjs.entry.js +1 -1
  93. package/dist/cjs/kol-select.cjs.entry.js +1 -1
  94. package/dist/cjs/kol-skip-nav.cjs.entry.js +1 -1
  95. package/dist/cjs/kol-span-wc.cjs.entry.js +1 -1
  96. package/dist/cjs/kol-spin.cjs.entry.js +1 -1
  97. package/dist/cjs/kol-symbol.cjs.entry.js +1 -1
  98. package/dist/cjs/kol-table.cjs.entry.js +1 -1
  99. package/dist/cjs/kol-tabs.cjs.entry.js +1 -1
  100. package/dist/cjs/kol-textarea.cjs.entry.js +1 -1
  101. package/dist/cjs/kol-toast-container.cjs.entry.js +1 -1
  102. package/dist/cjs/kol-version.cjs.entry.js +1 -1
  103. package/dist/cjs/kolibri.cjs.js +1 -1
  104. package/dist/cjs/{label-f1bb026a.js → label-a9e9ea83.js} +1 -1
  105. package/dist/cjs/{label-f1bb026a.js.map → label-a9e9ea83.js.map} +1 -1
  106. package/dist/cjs/loader.cjs.js +1 -1
  107. package/dist/cjs/open-d4905ad3.js +4 -0
  108. package/dist/cjs/{open-b82318b2.js.map → open-d4905ad3.js.map} +1 -1
  109. package/dist/cjs/{prop.validators-d0c36c3f.js → prop.validators-4653485a.js} +1 -1
  110. package/dist/cjs/{prop.validators-d0c36c3f.js.map → prop.validators-4653485a.js.map} +1 -1
  111. package/dist/cjs/rows-78a948f1.js +4 -0
  112. package/dist/cjs/{rows-3afa56f3.js.map → rows-78a948f1.js.map} +1 -1
  113. package/dist/cjs/show-eda88962.js +4 -0
  114. package/dist/cjs/{show-9104c9b1.js.map → show-eda88962.js.map} +1 -1
  115. package/dist/cjs/{suggestions-f2df9189.js → suggestions-d7efef3e.js} +1 -1
  116. package/dist/cjs/{suggestions-f2df9189.js.map → suggestions-d7efef3e.js.map} +1 -1
  117. package/dist/cjs/{tab-index-bcdca21e.js → tab-index-c327027d.js} +1 -1
  118. package/dist/cjs/{tab-index-bcdca21e.js.map → tab-index-c327027d.js.map} +1 -1
  119. package/dist/cjs/{tooltip-align-0e5ab85b.js → tooltip-align-b2dc9c08.js} +1 -1
  120. package/dist/cjs/{tooltip-align-0e5ab85b.js.map → tooltip-align-b2dc9c08.js.map} +1 -1
  121. package/dist/cjs/{validation-c699f0e1.js → validation-c73ef686.js} +1 -1
  122. package/dist/cjs/{validation-c699f0e1.js.map → validation-c73ef686.js.map} +1 -1
  123. package/dist/cjs/{validation-5e914a29.js → validation-d2ef4d42.js} +1 -1
  124. package/dist/cjs/{validation-5e914a29.js.map → validation-d2ef4d42.js.map} +1 -1
  125. package/dist/components/component15.js +1 -1
  126. package/dist/components/component5.js +1 -1
  127. package/dist/components/component6.js +1 -1
  128. package/dist/components/component8.js +1 -1
  129. package/dist/components/component9.js +1 -1
  130. package/dist/components/controller.js +1 -1
  131. package/dist/components/controller2.js +1 -1
  132. package/dist/components/devtools.js +1 -1
  133. package/dist/components/kol-accordion.js +1 -1
  134. package/dist/components/kol-accordion.js.map +1 -1
  135. package/dist/components/kol-button-link.js +1 -1
  136. package/dist/components/kol-button-link.js.map +1 -1
  137. package/dist/components/kol-card.js +1 -1
  138. package/dist/components/kol-details.js +1 -1
  139. package/dist/components/kol-details.js.map +1 -1
  140. package/dist/components/kol-image.js +1 -1
  141. package/dist/components/kol-image.js.map +1 -1
  142. package/dist/components/kol-input-checkbox.js +1 -1
  143. package/dist/components/kol-input-checkbox.js.map +1 -1
  144. package/dist/components/kol-input-color.js +1 -1
  145. package/dist/components/kol-input-date.js +1 -1
  146. package/dist/components/kol-input-email.js +1 -1
  147. package/dist/components/kol-input-file.js +1 -1
  148. package/dist/components/kol-input-number.js +1 -1
  149. package/dist/components/kol-input-password.js +1 -1
  150. package/dist/components/kol-input-radio.js +1 -1
  151. package/dist/components/kol-input-radio.js.map +1 -1
  152. package/dist/components/kol-input-range.js +1 -1
  153. package/dist/components/kol-input-text.js +1 -1
  154. package/dist/components/kol-link-button.js +1 -1
  155. package/dist/components/kol-link-button.js.map +1 -1
  156. package/dist/components/kol-logo.js +1 -1
  157. package/dist/components/kol-modal.js +1 -1
  158. package/dist/components/kol-nav.js +1 -1
  159. package/dist/components/kol-table.js +1 -1
  160. package/dist/components/kol-tabs.js +1 -1
  161. package/dist/components/kol-textarea.js +1 -1
  162. package/dist/components/prop.validators.js +1 -1
  163. package/dist/components/prop.validators.js.map +1 -1
  164. package/dist/components/shadow2.js +1 -1
  165. package/dist/components/shadow2.js.map +1 -1
  166. package/dist/components/shadow3.js +1 -1
  167. package/dist/components/shadow3.js.map +1 -1
  168. package/dist/esm/{a11y.tipps-06cd7c77.js → a11y.tipps-ce35f0ba.js} +1 -1
  169. package/dist/esm/{a11y.tipps-06cd7c77.js.map → a11y.tipps-ce35f0ba.js.map} +1 -1
  170. package/dist/esm/{access-key-d58c03d6.js → access-key-8240737c.js} +1 -1
  171. package/dist/esm/{access-key-d58c03d6.js.map → access-key-8240737c.js.map} +1 -1
  172. package/dist/esm/{alignment-de1c6559.js → alignment-e4b01638.js} +1 -1
  173. package/dist/esm/{alignment-de1c6559.js.map → alignment-e4b01638.js.map} +1 -1
  174. package/dist/esm/alternative-button-link-role-6e40ea00.js +4 -0
  175. package/dist/esm/{alternative-button-link-role-8db83e93.js.map → alternative-button-link-role-6e40ea00.js.map} +1 -1
  176. package/dist/esm/{app-globals-77b2422c.js → app-globals-c9725f59.js} +1 -1
  177. package/dist/esm/{app-globals-77b2422c.js.map → app-globals-c9725f59.js.map} +1 -1
  178. package/dist/esm/{associated.controller-1124284d.js → associated.controller-6fc585ca.js} +1 -1
  179. package/dist/esm/{associated.controller-1124284d.js.map → associated.controller-6fc585ca.js.map} +1 -1
  180. package/dist/esm/{color-84b42735.js → color-d643b48d.js} +1 -1
  181. package/dist/esm/{color-84b42735.js.map → color-d643b48d.js.map} +1 -1
  182. package/dist/esm/{controller-6a175634.js → controller-2924ea0a.js} +1 -1
  183. package/dist/esm/{controller-6a175634.js.map → controller-2924ea0a.js.map} +1 -1
  184. package/dist/esm/{controller-7e5c82c1.js → controller-5fe68410.js} +1 -1
  185. package/dist/esm/{controller-7e5c82c1.js.map → controller-5fe68410.js.map} +1 -1
  186. package/dist/esm/{controller-98501396.js → controller-b4e5201d.js} +1 -1
  187. package/dist/esm/{controller-98501396.js.map → controller-b4e5201d.js.map} +1 -1
  188. package/dist/esm/{controller-f38fc4fc.js → controller-be4224bb.js} +1 -1
  189. package/dist/esm/{controller-f38fc4fc.js.map → controller-be4224bb.js.map} +1 -1
  190. package/dist/esm/{controller-5a0cb886.js → controller-ca2640db.js} +1 -1
  191. package/dist/esm/{controller-5a0cb886.js.map → controller-ca2640db.js.map} +1 -1
  192. package/dist/esm/{controller-icon-ffe0af69.js → controller-icon-d242ea16.js} +1 -1
  193. package/dist/esm/{controller-icon-ffe0af69.js.map → controller-icon-d242ea16.js.map} +1 -1
  194. package/dist/esm/custom-class-4f50e79f.js +4 -0
  195. package/dist/esm/{custom-class-6ba43df0.js.map → custom-class-4f50e79f.js.map} +1 -1
  196. package/dist/esm/{dev.utils-075f4e7b.js → dev.utils-34544843.js} +1 -1
  197. package/dist/esm/{dev.utils-075f4e7b.js.map → dev.utils-34544843.js.map} +1 -1
  198. package/dist/esm/{devtools-d3472315.js → devtools-5924cad9.js} +1 -1
  199. package/dist/esm/{devtools-d3472315.js.map → devtools-5924cad9.js.map} +1 -1
  200. package/dist/esm/{has-closer-d28fec0f.js → has-closer-1b322deb.js} +1 -1
  201. package/dist/esm/{has-closer-d28fec0f.js.map → has-closer-1b322deb.js.map} +1 -1
  202. package/dist/esm/{hide-label-3381f0cc.js → hide-label-29f1b0eb.js} +1 -1
  203. package/dist/esm/{hide-label-3381f0cc.js.map → hide-label-29f1b0eb.js.map} +1 -1
  204. package/dist/esm/{i18n-8ec5b30e.js → i18n-bb569ab8.js} +1 -1
  205. package/dist/esm/{i18n-8ec5b30e.js.map → i18n-bb569ab8.js.map} +1 -1
  206. package/dist/esm/{icons-062ba29d.js → icons-7806a223.js} +1 -1
  207. package/dist/esm/{icons-062ba29d.js.map → icons-7806a223.js.map} +1 -1
  208. package/dist/esm/{image-source-ceb96521.js → image-source-bdd50deb.js} +1 -1
  209. package/dist/esm/{image-source-ceb96521.js.map → image-source-bdd50deb.js.map} +1 -1
  210. package/dist/esm/{index-b79e4012.js → index-7a38e9a3.js} +1 -1
  211. package/dist/esm/{index-b79e4012.js.map → index-7a38e9a3.js.map} +1 -1
  212. package/dist/esm/index.js +1 -1
  213. package/dist/esm/kol-abbr.entry.js +1 -1
  214. package/dist/esm/kol-accordion.entry.js +1 -1
  215. package/dist/esm/kol-accordion.entry.js.map +1 -1
  216. package/dist/esm/kol-alert-wc_2.entry.js +1 -1
  217. package/dist/esm/kol-avatar-wc.entry.js +1 -1
  218. package/dist/esm/kol-badge.entry.js +1 -1
  219. package/dist/esm/kol-breadcrumb.entry.js +1 -1
  220. package/dist/esm/kol-button-link.entry.js +1 -1
  221. package/dist/esm/kol-button-link.entry.js.map +1 -1
  222. package/dist/esm/kol-button-wc_2.entry.js +1 -1
  223. package/dist/esm/kol-button.entry.js +1 -1
  224. package/dist/esm/kol-button.entry.js.map +1 -1
  225. package/dist/esm/kol-card.entry.js +1 -1
  226. package/dist/esm/kol-details.entry.js +1 -1
  227. package/dist/esm/kol-details.entry.js.map +1 -1
  228. package/dist/esm/kol-form.entry.js +1 -1
  229. package/dist/esm/kol-icon.entry.js +1 -1
  230. package/dist/esm/kol-image.entry.js +1 -1
  231. package/dist/esm/kol-image.entry.js.map +1 -1
  232. package/dist/esm/kol-input-checkbox.entry.js +1 -1
  233. package/dist/esm/kol-input-checkbox.entry.js.map +1 -1
  234. package/dist/esm/kol-input-color.entry.js +1 -1
  235. package/dist/esm/kol-input-date.entry.js +1 -1
  236. package/dist/esm/kol-input-email.entry.js +1 -1
  237. package/dist/esm/kol-input-file.entry.js +1 -1
  238. package/dist/esm/kol-input-number.entry.js +1 -1
  239. package/dist/esm/kol-input-password.entry.js +1 -1
  240. package/dist/esm/kol-input-radio.entry.js +1 -1
  241. package/dist/esm/kol-input-radio.entry.js.map +1 -1
  242. package/dist/esm/kol-input-range.entry.js +1 -1
  243. package/dist/esm/kol-input-text.entry.js +1 -1
  244. package/dist/esm/kol-input.entry.js +1 -1
  245. package/dist/esm/kol-kolibri.entry.js +1 -1
  246. package/dist/esm/kol-link-button.entry.js +1 -1
  247. package/dist/esm/kol-link-button.entry.js.map +1 -1
  248. package/dist/esm/kol-link-group.entry.js +1 -1
  249. package/dist/esm/kol-link-wc.entry.js +1 -1
  250. package/dist/esm/kol-link.entry.js +1 -1
  251. package/dist/esm/kol-link.entry.js.map +1 -1
  252. package/dist/esm/kol-logo.entry.js +1 -1
  253. package/dist/esm/kol-modal.entry.js +1 -1
  254. package/dist/esm/kol-nav.entry.js +1 -1
  255. package/dist/esm/kol-pagination.entry.js +1 -1
  256. package/dist/esm/kol-popover.entry.js +1 -1
  257. package/dist/esm/kol-progress.entry.js +1 -1
  258. package/dist/esm/kol-quote.entry.js +1 -1
  259. package/dist/esm/kol-select.entry.js +1 -1
  260. package/dist/esm/kol-skip-nav.entry.js +1 -1
  261. package/dist/esm/kol-span-wc.entry.js +1 -1
  262. package/dist/esm/kol-spin.entry.js +1 -1
  263. package/dist/esm/kol-symbol.entry.js +1 -1
  264. package/dist/esm/kol-table.entry.js +1 -1
  265. package/dist/esm/kol-tabs.entry.js +1 -1
  266. package/dist/esm/kol-textarea.entry.js +1 -1
  267. package/dist/esm/kol-toast-container.entry.js +1 -1
  268. package/dist/esm/kol-version.entry.js +1 -1
  269. package/dist/esm/kolibri.js +1 -1
  270. package/dist/esm/{label-5c173d60.js → label-2cb169c2.js} +1 -1
  271. package/dist/esm/{label-5c173d60.js.map → label-2cb169c2.js.map} +1 -1
  272. package/dist/esm/loader.js +1 -1
  273. package/dist/esm/{open-47384c18.js → open-590f675d.js} +1 -1
  274. package/dist/esm/{open-47384c18.js.map → open-590f675d.js.map} +1 -1
  275. package/dist/esm/{prop.validators-3d53ddab.js → prop.validators-b0d023a4.js} +1 -1
  276. package/dist/esm/{prop.validators-3d53ddab.js.map → prop.validators-b0d023a4.js.map} +1 -1
  277. package/dist/esm/{rows-1eebe49e.js → rows-16012802.js} +1 -1
  278. package/dist/esm/{rows-1eebe49e.js.map → rows-16012802.js.map} +1 -1
  279. package/dist/esm/{show-3e682c46.js → show-caf52695.js} +1 -1
  280. package/dist/esm/{show-3e682c46.js.map → show-caf52695.js.map} +1 -1
  281. package/dist/esm/{suggestions-04f64716.js → suggestions-ef03081f.js} +1 -1
  282. package/dist/esm/{suggestions-04f64716.js.map → suggestions-ef03081f.js.map} +1 -1
  283. package/dist/esm/{tab-index-d2d0d9db.js → tab-index-9201352c.js} +1 -1
  284. package/dist/esm/{tab-index-d2d0d9db.js.map → tab-index-9201352c.js.map} +1 -1
  285. package/dist/esm/{tooltip-align-c09e55cd.js → tooltip-align-f2f68cbf.js} +1 -1
  286. package/dist/esm/{tooltip-align-c09e55cd.js.map → tooltip-align-f2f68cbf.js.map} +1 -1
  287. package/dist/esm/validation-6962a682.js +4 -0
  288. package/dist/esm/{validation-68e14b6f.js.map → validation-6962a682.js.map} +1 -1
  289. package/dist/esm/{validation-c57e7be5.js → validation-b1ee30aa.js} +1 -1
  290. package/dist/esm/{validation-c57e7be5.js.map → validation-b1ee30aa.js.map} +1 -1
  291. package/dist/kolibri/{a11y.tipps-06cd7c77.js → a11y.tipps-ce35f0ba.js} +1 -1
  292. package/dist/kolibri/access-key-8240737c.js +4 -0
  293. package/dist/kolibri/{alignment-de1c6559.js → alignment-e4b01638.js} +1 -1
  294. package/dist/kolibri/alternative-button-link-role-6e40ea00.js +4 -0
  295. package/dist/kolibri/app-globals-c9725f59.js +4 -0
  296. package/dist/kolibri/{associated.controller-1124284d.js → associated.controller-6fc585ca.js} +1 -1
  297. package/dist/kolibri/{color-84b42735.js → color-d643b48d.js} +1 -1
  298. package/dist/kolibri/{controller-6a175634.js → controller-2924ea0a.js} +1 -1
  299. package/dist/kolibri/{controller-7e5c82c1.js → controller-5fe68410.js} +1 -1
  300. package/dist/kolibri/{controller-98501396.js → controller-b4e5201d.js} +1 -1
  301. package/dist/kolibri/{controller-f38fc4fc.js → controller-be4224bb.js} +1 -1
  302. package/dist/kolibri/{controller-5a0cb886.js → controller-ca2640db.js} +1 -1
  303. package/dist/kolibri/controller-icon-d242ea16.js +4 -0
  304. package/dist/kolibri/custom-class-4f50e79f.js +4 -0
  305. package/dist/kolibri/{dev.utils-075f4e7b.js → dev.utils-34544843.js} +1 -1
  306. package/dist/kolibri/{dev.utils-075f4e7b.js.map → dev.utils-34544843.js.map} +1 -1
  307. package/dist/kolibri/{devtools-d3472315.js → devtools-5924cad9.js} +1 -1
  308. package/dist/kolibri/has-closer-1b322deb.js +4 -0
  309. package/dist/kolibri/hide-label-29f1b0eb.js +4 -0
  310. package/dist/kolibri/{i18n-8ec5b30e.js → i18n-bb569ab8.js} +1 -1
  311. package/dist/kolibri/{icons-062ba29d.js → icons-7806a223.js} +1 -1
  312. package/dist/kolibri/image-source-bdd50deb.js +4 -0
  313. package/dist/kolibri/{index-b79e4012.js → index-7a38e9a3.js} +1 -1
  314. package/dist/kolibri/index.esm.js +1 -1
  315. package/dist/kolibri/kol-abbr.entry.js +1 -1
  316. package/dist/kolibri/kol-accordion.entry.js +1 -1
  317. package/dist/kolibri/kol-accordion.entry.js.map +1 -1
  318. package/dist/kolibri/kol-alert-wc_2.entry.js +1 -1
  319. package/dist/kolibri/kol-alert-wc_2.entry.js.map +1 -1
  320. package/dist/kolibri/kol-avatar-wc.entry.js +1 -1
  321. package/dist/kolibri/kol-badge.entry.js +1 -1
  322. package/dist/kolibri/kol-breadcrumb.entry.js +1 -1
  323. package/dist/kolibri/kol-button-link.entry.js +1 -1
  324. package/dist/kolibri/kol-button-link.entry.js.map +1 -1
  325. package/dist/kolibri/kol-button-wc_2.entry.js +1 -1
  326. package/dist/kolibri/kol-button.entry.js +1 -1
  327. package/dist/kolibri/kol-button.entry.js.map +1 -1
  328. package/dist/kolibri/kol-card.entry.js +1 -1
  329. package/dist/kolibri/kol-details.entry.js +1 -1
  330. package/dist/kolibri/kol-details.entry.js.map +1 -1
  331. package/dist/kolibri/kol-form.entry.js +1 -1
  332. package/dist/kolibri/kol-icon.entry.js +1 -1
  333. package/dist/kolibri/kol-image.entry.js +1 -1
  334. package/dist/kolibri/kol-image.entry.js.map +1 -1
  335. package/dist/kolibri/kol-input-checkbox.entry.js +1 -1
  336. package/dist/kolibri/kol-input-checkbox.entry.js.map +1 -1
  337. package/dist/kolibri/kol-input-color.entry.js +1 -1
  338. package/dist/kolibri/kol-input-date.entry.js +1 -1
  339. package/dist/kolibri/kol-input-email.entry.js +1 -1
  340. package/dist/kolibri/kol-input-file.entry.js +1 -1
  341. package/dist/kolibri/kol-input-number.entry.js +1 -1
  342. package/dist/kolibri/kol-input-password.entry.js +1 -1
  343. package/dist/kolibri/kol-input-radio.entry.js +1 -1
  344. package/dist/kolibri/kol-input-radio.entry.js.map +1 -1
  345. package/dist/kolibri/kol-input-range.entry.js +1 -1
  346. package/dist/kolibri/kol-input-text.entry.js +1 -1
  347. package/dist/kolibri/kol-input.entry.js +1 -1
  348. package/dist/kolibri/kol-kolibri.entry.js +1 -1
  349. package/dist/kolibri/kol-link-button.entry.js +1 -1
  350. package/dist/kolibri/kol-link-button.entry.js.map +1 -1
  351. package/dist/kolibri/kol-link-group.entry.js +1 -1
  352. package/dist/kolibri/kol-link-wc.entry.js +1 -1
  353. package/dist/kolibri/kol-link.entry.js +1 -1
  354. package/dist/kolibri/kol-link.entry.js.map +1 -1
  355. package/dist/kolibri/kol-logo.entry.js +1 -1
  356. package/dist/kolibri/kol-logo.entry.js.map +1 -1
  357. package/dist/kolibri/kol-modal.entry.js +1 -1
  358. package/dist/kolibri/kol-nav.entry.js +1 -1
  359. package/dist/kolibri/kol-pagination.entry.js +1 -1
  360. package/dist/kolibri/kol-pagination.entry.js.map +1 -1
  361. package/dist/kolibri/kol-popover.entry.js +1 -1
  362. package/dist/kolibri/kol-progress.entry.js +1 -1
  363. package/dist/kolibri/kol-quote.entry.js +1 -1
  364. package/dist/kolibri/kol-select.entry.js +1 -1
  365. package/dist/kolibri/kol-skip-nav.entry.js +1 -1
  366. package/dist/kolibri/kol-skip-nav.entry.js.map +1 -1
  367. package/dist/kolibri/kol-span-wc.entry.js +1 -1
  368. package/dist/kolibri/kol-spin.entry.js +1 -1
  369. package/dist/kolibri/kol-symbol.entry.js +1 -1
  370. package/dist/kolibri/kol-table.entry.js +1 -1
  371. package/dist/kolibri/kol-tabs.entry.js +1 -1
  372. package/dist/kolibri/kol-textarea.entry.js +1 -1
  373. package/dist/kolibri/kol-toast-container.entry.js +1 -1
  374. package/dist/kolibri/kol-version.entry.js +1 -1
  375. package/dist/kolibri/kolibri.esm.js +1 -1
  376. package/dist/kolibri/{label-5c173d60.js → label-2cb169c2.js} +1 -1
  377. package/dist/kolibri/open-590f675d.js +4 -0
  378. package/dist/kolibri/{prop.validators-3d53ddab.js → prop.validators-b0d023a4.js} +1 -1
  379. package/dist/kolibri/rows-16012802.js +4 -0
  380. package/dist/kolibri/show-caf52695.js +4 -0
  381. package/dist/kolibri/{suggestions-04f64716.js → suggestions-ef03081f.js} +1 -1
  382. package/dist/kolibri/tab-index-9201352c.js +4 -0
  383. package/dist/kolibri/{tab-index-d2d0d9db.js.map → tab-index-9201352c.js.map} +1 -1
  384. package/dist/kolibri/tooltip-align-f2f68cbf.js +4 -0
  385. package/dist/kolibri/validation-6962a682.js +4 -0
  386. package/dist/kolibri/{validation-c57e7be5.js → validation-b1ee30aa.js} +1 -1
  387. package/dist/types/components/accordion/component.d.ts +2 -0
  388. package/dist/types/components/button/shadow.d.ts +0 -1
  389. package/dist/types/components/button-link/component.d.ts +0 -1
  390. package/dist/types/components/details/component.d.ts +1 -0
  391. package/dist/types/components/input-checkbox/component.d.ts +0 -1
  392. package/dist/types/components/input-radio/component.d.ts +0 -1
  393. package/dist/types/components/link/shadow.d.ts +0 -1
  394. package/dist/types/components/link-button/component.d.ts +0 -1
  395. package/package.json +1 -1
  396. package/dist/cjs/access-key-5fe7eedb.js +0 -4
  397. package/dist/cjs/alternative-button-link-role-d99da0f8.js +0 -4
  398. package/dist/cjs/custom-class-ed101b87.js +0 -4
  399. package/dist/cjs/has-closer-0140b049.js +0 -4
  400. package/dist/cjs/hide-label-72171d2b.js +0 -4
  401. package/dist/cjs/image-source-f283f0ea.js +0 -4
  402. package/dist/cjs/open-b82318b2.js +0 -4
  403. package/dist/cjs/rows-3afa56f3.js +0 -4
  404. package/dist/cjs/show-9104c9b1.js +0 -4
  405. package/dist/esm/alternative-button-link-role-8db83e93.js +0 -4
  406. package/dist/esm/custom-class-6ba43df0.js +0 -4
  407. package/dist/esm/validation-68e14b6f.js +0 -4
  408. package/dist/kolibri/access-key-d58c03d6.js +0 -4
  409. package/dist/kolibri/alternative-button-link-role-8db83e93.js +0 -4
  410. package/dist/kolibri/app-globals-77b2422c.js +0 -4
  411. package/dist/kolibri/controller-icon-ffe0af69.js +0 -4
  412. package/dist/kolibri/custom-class-6ba43df0.js +0 -4
  413. package/dist/kolibri/has-closer-d28fec0f.js +0 -4
  414. package/dist/kolibri/hide-label-3381f0cc.js +0 -4
  415. package/dist/kolibri/image-source-ceb96521.js +0 -4
  416. package/dist/kolibri/open-47384c18.js +0 -4
  417. package/dist/kolibri/rows-1eebe49e.js +0 -4
  418. package/dist/kolibri/show-3e682c46.js +0 -4
  419. package/dist/kolibri/tab-index-d2d0d9db.js +0 -4
  420. package/dist/kolibri/tooltip-align-c09e55cd.js +0 -4
  421. package/dist/kolibri/validation-68e14b6f.js +0 -4
  422. /package/dist/kolibri/{a11y.tipps-06cd7c77.js.map → a11y.tipps-ce35f0ba.js.map} +0 -0
  423. /package/dist/kolibri/{access-key-d58c03d6.js.map → access-key-8240737c.js.map} +0 -0
  424. /package/dist/kolibri/{alignment-de1c6559.js.map → alignment-e4b01638.js.map} +0 -0
  425. /package/dist/kolibri/{alternative-button-link-role-8db83e93.js.map → alternative-button-link-role-6e40ea00.js.map} +0 -0
  426. /package/dist/kolibri/{app-globals-77b2422c.js.map → app-globals-c9725f59.js.map} +0 -0
  427. /package/dist/kolibri/{associated.controller-1124284d.js.map → associated.controller-6fc585ca.js.map} +0 -0
  428. /package/dist/kolibri/{color-84b42735.js.map → color-d643b48d.js.map} +0 -0
  429. /package/dist/kolibri/{controller-6a175634.js.map → controller-2924ea0a.js.map} +0 -0
  430. /package/dist/kolibri/{controller-7e5c82c1.js.map → controller-5fe68410.js.map} +0 -0
  431. /package/dist/kolibri/{controller-98501396.js.map → controller-b4e5201d.js.map} +0 -0
  432. /package/dist/kolibri/{controller-f38fc4fc.js.map → controller-be4224bb.js.map} +0 -0
  433. /package/dist/kolibri/{controller-5a0cb886.js.map → controller-ca2640db.js.map} +0 -0
  434. /package/dist/kolibri/{controller-icon-ffe0af69.js.map → controller-icon-d242ea16.js.map} +0 -0
  435. /package/dist/kolibri/{custom-class-6ba43df0.js.map → custom-class-4f50e79f.js.map} +0 -0
  436. /package/dist/kolibri/{devtools-d3472315.js.map → devtools-5924cad9.js.map} +0 -0
  437. /package/dist/kolibri/{has-closer-d28fec0f.js.map → has-closer-1b322deb.js.map} +0 -0
  438. /package/dist/kolibri/{hide-label-3381f0cc.js.map → hide-label-29f1b0eb.js.map} +0 -0
  439. /package/dist/kolibri/{i18n-8ec5b30e.js.map → i18n-bb569ab8.js.map} +0 -0
  440. /package/dist/kolibri/{icons-062ba29d.js.map → icons-7806a223.js.map} +0 -0
  441. /package/dist/kolibri/{image-source-ceb96521.js.map → image-source-bdd50deb.js.map} +0 -0
  442. /package/dist/kolibri/{index-b79e4012.js.map → index-7a38e9a3.js.map} +0 -0
  443. /package/dist/kolibri/{label-5c173d60.js.map → label-2cb169c2.js.map} +0 -0
  444. /package/dist/kolibri/{open-47384c18.js.map → open-590f675d.js.map} +0 -0
  445. /package/dist/kolibri/{prop.validators-3d53ddab.js.map → prop.validators-b0d023a4.js.map} +0 -0
  446. /package/dist/kolibri/{rows-1eebe49e.js.map → rows-16012802.js.map} +0 -0
  447. /package/dist/kolibri/{show-3e682c46.js.map → show-caf52695.js.map} +0 -0
  448. /package/dist/kolibri/{suggestions-04f64716.js.map → suggestions-ef03081f.js.map} +0 -0
  449. /package/dist/kolibri/{tooltip-align-c09e55cd.js.map → tooltip-align-f2f68cbf.js.map} +0 -0
  450. /package/dist/kolibri/{validation-68e14b6f.js.map → validation-6962a682.js.map} +0 -0
  451. /package/dist/kolibri/{validation-c57e7be5.js.map → validation-b1ee30aa.js.map} +0 -0
@@ -1 +1 @@
1
- {"version":3,"names":["alertTypeOptions","alertVariantOptions","Icon","props","h","class","_label","label","length","ariaLabel","_icons","icon","AlertIcon","type","translate","KolAlertWc","this","close","_a","_on","onClose","undefined","Event","on","onClick","validateOnValue","value","_level","render","state","_alert","Log","debug","navigator","vibrate","e","setTimeout","validateAlert","Host","_type","_variant","hasCloser","_hasCloser","role","_hideLabel","left","_tooltipAlign","watchBoolean","validateHasCloser","validateLabel","validateLevel","watchHeadingLevel","validateOn","setState","validateType","watchValidator","includes","Set","join","validateVariant","componentWillLoad","KolHeadingWc","renderHeadline","headline","level","renderSecondaryHeadline","validateLabelWithExpertSlot","validateSecondaryHeadline","watchString","_secondaryHeadline"],"sources":["src/components/alert/types.ts","src/components/alert/component.tsx","src/components/heading/component.tsx"],"sourcesContent":["import { Generic } from '@a11y-ui/core';\n\nimport { EventCallback } from '../../types/callbacks';\nimport { HeadingLevel } from '../../types/heading-level';\nimport { PropAlert } from '../../types/props/alert';\nimport { PropHasCloser } from '../../types/props/has-closer';\nimport { PropLabel } from '../../types/props/label';\n\nexport const alertTypeOptions = ['default', 'info', 'success', 'warning', 'error'] as const;\nexport type AlertType = (typeof alertTypeOptions)[number];\n\nexport const alertVariantOptions = ['card', 'msg'] as const;\nexport type AlertVariant = (typeof alertVariantOptions)[number];\n\nexport type KoliBriAlertEventCallbacks = {\n\tonClose?: EventCallback<Event>;\n};\n\ntype RequiredAlertProps = NonNullable<unknown>;\ntype OptionalAlertProps = {\n\tlevel: HeadingLevel;\n\ton: KoliBriAlertEventCallbacks;\n\ttype: AlertType;\n\tvariant: AlertVariant;\n} & PropLabel &\n\tPropAlert &\n\tPropHasCloser;\n\ntype RequiredAlertStates = RequiredAlertProps;\ntype OptionalAlertStates = OptionalAlertProps;\n\nexport type Props = Generic.Element.Members<RequiredAlertProps, OptionalAlertProps>;\nexport type States = Generic.Element.Members<RequiredAlertStates, OptionalAlertStates>;\nexport type API = Generic.Element.ComponentApi<RequiredAlertProps, OptionalAlertProps, RequiredAlertStates, OptionalAlertStates>;\n","import { Component, h, Host, JSX, Prop, State, Watch } from '@stencil/core';\n\nimport { translate } from '../../i18n';\nimport { HeadingLevel } from '../../types/heading-level';\nimport { HasCloserPropType, validateHasCloser } from '../../types/props/has-closer';\nimport { LabelPropType, validateLabel } from '../../types/props/label';\nimport { Log } from '../../utils/dev.utils';\nimport { setState, watchBoolean, watchValidator } from '../../utils/prop.validators';\nimport { watchHeadingLevel } from '../heading/validation';\nimport { AlertType, alertTypeOptions, AlertVariant, alertVariantOptions, API, KoliBriAlertEventCallbacks, States } from './types';\n\nconst Icon = (props: { ariaLabel: string; icon: string; label?: string }) => {\n\treturn <kol-icon class=\"heading-icon\" _label={typeof props.label === 'string' && props.label.length > 0 ? '' : props.ariaLabel} _icons={props.icon} />;\n};\n\nconst AlertIcon = (props: { label?: string; type?: AlertType }) => {\n\tswitch (props.type) {\n\t\tcase 'error':\n\t\t\treturn <Icon ariaLabel={translate('kol-error')} icon=\"codicon codicon-error\" label={props.label} />;\n\t\tcase 'info':\n\t\t\treturn <Icon ariaLabel={translate('kol-info')} icon=\"codicon codicon-info\" label={props.label} />;\n\t\tcase 'warning':\n\t\t\treturn <Icon ariaLabel={translate('kol-warning')} icon=\"codicon codicon-warning\" label={props.label} />;\n\t\tcase 'success':\n\t\t\treturn <Icon ariaLabel={translate('kol-success')} icon=\"codicon codicon-pass\" label={props.label} />;\n\t\tdefault:\n\t\t\treturn <Icon ariaLabel={translate('kol-message')} icon=\"codicon codicon-comment\" label={props.label} />;\n\t}\n};\n\n/**\n * @slot - Der Inhalt der Meldung.\n */\n@Component({\n\ttag: 'kol-alert-wc',\n\tshadow: false,\n})\nexport class KolAlertWc implements API {\n\tprivate readonly close = () => {\n\t\tif (this._on?.onClose !== undefined) {\n\t\t\tthis._on.onClose(new Event('Close'));\n\t\t}\n\t};\n\n\tprivate readonly on = {\n\t\tonClick: this.close,\n\t};\n\n\tpublic render(): JSX.Element {\n\t\tif (this.state._alert) {\n\t\t\t/**\n\t\t\t * - https://developer.mozilla.org/de/docs/Web/API/Navigator/vibrate\n\t\t\t * - https://googlechrome.github.io/samples/vibration/\n\t\t\t */\n\t\t\ttry {\n\t\t\t\tLog.debug(['Navigator should vibrate ...', navigator.vibrate([100, 75, 100, 75, 100])]);\n\t\t\t} catch (e) {\n\t\t\t\tLog.debug('Navigator does not support vibration.');\n\t\t\t}\n\n\t\t\tsetTimeout(() => {\n\t\t\t\tthis.validateAlert(false);\n\t\t\t}, 10000);\n\t\t}\n\n\t\treturn (\n\t\t\t<Host\n\t\t\t\tclass={{\n\t\t\t\t\t[this.state._type as string]: true,\n\t\t\t\t\t[this.state._variant as string]: true,\n\t\t\t\t\thasCloser: !!this.state._hasCloser,\n\t\t\t\t}}\n\t\t\t\trole={this.state._alert ? 'alert' : undefined}\n\t\t\t>\n\t\t\t\t<div class=\"heading\">\n\t\t\t\t\t<AlertIcon label={this.state._label} type={this.state._type} />\n\t\t\t\t\t<div>\n\t\t\t\t\t\t{typeof this.state._label === 'string' && this.state._label?.length > 0 && (\n\t\t\t\t\t\t\t<kol-heading-wc _label={this.state._label} _level={this.state._level}></kol-heading-wc>\n\t\t\t\t\t\t)}\n\t\t\t\t\t\t{this._variant === 'msg' && (\n\t\t\t\t\t\t\t<div class=\"content\">\n\t\t\t\t\t\t\t\t<slot />\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t)}\n\t\t\t\t\t</div>\n\t\t\t\t\t{this.state._hasCloser && (\n\t\t\t\t\t\t<kol-button-wc\n\t\t\t\t\t\t\tclass=\"close\"\n\t\t\t\t\t\t\t_hideLabel\n\t\t\t\t\t\t\t_icons={{\n\t\t\t\t\t\t\t\tleft: {\n\t\t\t\t\t\t\t\t\ticon: 'codicon codicon-close',\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t_label={translate('kol-close')}\n\t\t\t\t\t\t\t_on={this.on}\n\t\t\t\t\t\t\t_tooltipAlign=\"left\"\n\t\t\t\t\t\t></kol-button-wc>\n\t\t\t\t\t)}\n\t\t\t\t</div>\n\t\t\t\t{this._variant === 'card' && (\n\t\t\t\t\t<div class=\"content\">\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</div>\n\t\t\t\t)}\n\t\t\t</Host>\n\t\t);\n\t}\n\n\t/**\n\t * Defines whether the screen-readers should read out the notification.\n\t */\n\t@Prop() public _alert?: boolean = false;\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 * Defines which H-level from 1-6 the heading has. 0 specifies no heading and is shown as bold text.\n\t */\n\t@Prop() public _level?: HeadingLevel = 1;\n\n\t/**\n\t * Gibt die EventCallback-Function für das Schließen des Alerts an.\n\t */\n\t@Prop() public _on?: KoliBriAlertEventCallbacks;\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?: AlertType = 'default';\n\n\t/**\n\t * Defines which variant should be used for presentation.\n\t */\n\t@Prop() public _variant?: AlertVariant = 'msg';\n\n\t@State() public state: States = {\n\t\t_level: 1,\n\t};\n\n\t@Watch('_alert')\n\tpublic validateAlert(value?: boolean): void {\n\t\twatchBoolean(this, '_alert', 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('_label')\n\tpublic validateLabel(value?: LabelPropType): void {\n\t\tvalidateLabel(this, value);\n\t}\n\n\t@Watch('_level')\n\tpublic validateLevel(value?: HeadingLevel): void {\n\t\twatchHeadingLevel(this, value);\n\t}\n\n\tprivate validateOnValue = (value: unknown): boolean =>\n\t\ttypeof value === 'object' && value !== null && typeof (value as KoliBriAlertEventCallbacks).onClose === 'function';\n\n\t@Watch('_on')\n\tpublic validateOn(value?: KoliBriAlertEventCallbacks): void {\n\t\tif (this.validateOnValue(value)) {\n\t\t\tsetState<KoliBriAlertEventCallbacks>(\n\t\t\t\tthis,\n\t\t\t\t'_on',\n\t\t\t\t{\n\t\t\t\t\tonClose: (value as KoliBriAlertEventCallbacks).onClose,\n\t\t\t\t}\n\t\t\t\t// {\n\t\t\t\t// \tafterPatch: (value: unknown) => {\n\t\t\t\t// \t\tthis._hasCloser = this.validateOnValue(value);\n\t\t\t\t// \t},\n\t\t\t\t// }\n\t\t\t);\n\t\t\t// } else {\n\t\t\t// \tsetState<KoliBriAlertEventCallbacks>(this, '_on', null, {\n\t\t\t// \t\tafterPatch: (value: unknown) => {\n\t\t\t// \t\t\tthis._hasCloser = this.validateOnValue(value);\n\t\t\t// \t\t},\n\t\t\t// \t});\n\t\t}\n\t}\n\n\t@Watch('_type')\n\tpublic validateType(value?: AlertType): void {\n\t\twatchValidator(\n\t\t\tthis,\n\t\t\t'_type',\n\t\t\t(value?) => typeof value === 'string' && alertTypeOptions.includes(value),\n\t\t\tnew Set(`String {${alertTypeOptions.join(', ')}`),\n\t\t\tvalue\n\t\t);\n\t}\n\n\t@Watch('_variant')\n\tpublic validateVariant(value?: AlertVariant): void {\n\t\twatchValidator(\n\t\t\tthis,\n\t\t\t'_variant',\n\t\t\t(value?) => typeof value === 'string' && alertVariantOptions.includes(value),\n\t\t\tnew Set(`AlertVariant {${alertVariantOptions.join(', ')}`),\n\t\t\tvalue\n\t\t);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tthis.validateAlert(this._alert);\n\t\tthis.validateHasCloser(this._hasCloser);\n\t\tthis.validateLabel(this._label);\n\t\tthis.validateLevel(this._level);\n\t\tthis.validateOn(this._on);\n\t\tthis.validateType(this._type);\n\t\tthis.validateVariant(this._variant);\n\t}\n}\n","import { Component, h, Host, JSX, Prop, State, Watch } from '@stencil/core';\n\nimport { HeadingLevel } from '../../types/heading-level';\nimport { LabelWithExpertSlotPropType, validateLabelWithExpertSlot } from '../../types/props/label';\nimport { watchString } from '../../utils/prop.validators';\nimport { API, States } from './types';\nimport { watchHeadingLevel } from './validation';\n\n/**\n * @slot - Inhalt der Überschrift.\n */\n@Component({\n\ttag: 'kol-heading-wc',\n\tshadow: false,\n})\nexport class KolHeadingWc implements API {\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 H-level from 1-6 the heading has. 0 specifies no heading and is shown as bold text.\n\t */\n\t@Prop() public _level?: HeadingLevel = 1;\n\n\t/**\n\t * Setzt den Text einer weiteren Überschrift, einen Level kleiner, unter der Ersten.\n\t */\n\t@Prop() public _secondaryHeadline?: string;\n\n\t@State() public state: States = {\n\t\t_label: '', // ⚠ required\n\t\t_level: 1,\n\t};\n\n\t@Watch('_label')\n\tpublic validateLabel(value?: LabelWithExpertSlotPropType): void {\n\t\tvalidateLabelWithExpertSlot(this, value);\n\t}\n\n\t@Watch('_level')\n\tpublic validateLevel(value?: HeadingLevel): void {\n\t\twatchHeadingLevel(this, value);\n\t}\n\n\t@Watch('_secondaryHeadline')\n\tpublic validateSecondaryHeadline(value?: string): void {\n\t\twatchString(this, '_secondaryHeadline', value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tthis.validateLabel(this._label);\n\t\tthis.validateLevel(this._level);\n\t\tthis.validateSecondaryHeadline(this._secondaryHeadline);\n\t}\n\n\tprivate readonly renderHeadline = (headline: LabelWithExpertSlotPropType, level?: number): JSX.Element => {\n\t\tswitch (level) {\n\t\t\tcase 1:\n\t\t\t\treturn (\n\t\t\t\t\t<h1 class=\"headline\">\n\t\t\t\t\t\t{headline}\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</h1>\n\t\t\t\t);\n\t\t\tcase 2:\n\t\t\t\treturn (\n\t\t\t\t\t<h2 class=\"headline\">\n\t\t\t\t\t\t{headline}\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</h2>\n\t\t\t\t);\n\t\t\tcase 3:\n\t\t\t\treturn (\n\t\t\t\t\t<h3 class=\"headline\">\n\t\t\t\t\t\t{headline}\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</h3>\n\t\t\t\t);\n\t\t\tcase 4:\n\t\t\t\treturn (\n\t\t\t\t\t<h4 class=\"headline\">\n\t\t\t\t\t\t{headline}\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</h4>\n\t\t\t\t);\n\t\t\tcase 5:\n\t\t\t\treturn (\n\t\t\t\t\t<h5 class=\"headline\">\n\t\t\t\t\t\t{headline}\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</h5>\n\t\t\t\t);\n\t\t\tcase 6:\n\t\t\t\treturn (\n\t\t\t\t\t<h6 class=\"headline\">\n\t\t\t\t\t\t{headline}\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</h6>\n\t\t\t\t);\n\t\t\tdefault:\n\t\t\t\treturn (\n\t\t\t\t\t<strong class=\"headline\">\n\t\t\t\t\t\t{headline}\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</strong>\n\t\t\t\t);\n\t\t}\n\t};\n\n\tprivate readonly renderSecondaryHeadline = (headline: string, level?: number): JSX.Element => {\n\t\tswitch (level) {\n\t\t\tcase 1: // if the headline is only strong\n\t\t\t\treturn <span class=\"secondary-headline\">{headline}</span>;\n\t\t\tcase 2: // if the headline is h1\n\t\t\t\treturn <h2 class=\"secondary-headline\">{headline}</h2>;\n\t\t\tcase 3: // if the headline is h2\n\t\t\t\treturn <h3 class=\"secondary-headline\">{headline}</h3>;\n\t\t\tcase 4: // if the headline is h3\n\t\t\t\treturn <h4 class=\"secondary-headline\">{headline}</h4>;\n\t\t\tcase 5: // if the headline is h4\n\t\t\t\treturn <h5 class=\"secondary-headline\">{headline}</h5>;\n\t\t\tcase 6: // if the headline is h5\n\t\t\t\treturn <h6 class=\"secondary-headline\">{headline}</h6>;\n\t\t\tdefault: // if the headline is h6\n\t\t\t\treturn <strong class=\"secondary-headline\">{headline}</strong>;\n\t\t}\n\t};\n\n\tpublic render(): JSX.Element {\n\t\treturn (\n\t\t\t<Host>\n\t\t\t\t{typeof this.state._secondaryHeadline === 'string' && this.state._secondaryHeadline.length > 0 ? (\n\t\t\t\t\t<hgroup>\n\t\t\t\t\t\t{this.renderHeadline(this.state._label, this.state._level)}\n\t\t\t\t\t\t{this.state._secondaryHeadline && this.renderSecondaryHeadline(this.state._secondaryHeadline, this.state._level + 1)}\n\t\t\t\t\t</hgroup>\n\t\t\t\t) : (\n\t\t\t\t\tthis.renderHeadline(this.state._label, this.state._level)\n\t\t\t\t)}\n\t\t\t</Host>\n\t\t);\n\t}\n}\n"],"mappings":"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"}
1
+ {"version":3,"names":["alertTypeOptions","alertVariantOptions","Icon","props","h","class","_label","label","length","ariaLabel","_icons","icon","AlertIcon","type","translate","KolAlertWc","this","close","_a","_on","onClose","undefined","Event","on","onClick","validateOnValue","value","_level","render","state","_alert","Log","debug","navigator","vibrate","e","setTimeout","validateAlert","Host","_type","_variant","hasCloser","_hasCloser","role","_hideLabel","left","_tooltipAlign","watchBoolean","validateHasCloser","validateLabel","validateLevel","watchHeadingLevel","validateOn","setState","validateType","watchValidator","includes","Set","join","validateVariant","componentWillLoad","KolHeadingWc","renderHeadline","headline","level","renderSecondaryHeadline","validateLabelWithExpertSlot","validateSecondaryHeadline","watchString","_secondaryHeadline"],"sources":["src/components/alert/types.ts","src/components/alert/component.tsx","src/components/heading/component.tsx"],"sourcesContent":["import { Generic } from '@a11y-ui/core';\n\nimport { EventCallback } from '../../types/callbacks';\nimport { HeadingLevel } from '../../types/heading-level';\nimport { PropAlert } from '../../types/props/alert';\nimport { PropHasCloser } from '../../types/props/has-closer';\nimport { PropLabel } from '../../types/props/label';\n\nexport const alertTypeOptions = ['default', 'info', 'success', 'warning', 'error'] as const;\nexport type AlertType = (typeof alertTypeOptions)[number];\n\nexport const alertVariantOptions = ['card', 'msg'] as const;\nexport type AlertVariant = (typeof alertVariantOptions)[number];\n\nexport type KoliBriAlertEventCallbacks = {\n\tonClose?: EventCallback<Event>;\n};\n\ntype RequiredAlertProps = NonNullable<unknown>;\ntype OptionalAlertProps = {\n\tlevel: HeadingLevel;\n\ton: KoliBriAlertEventCallbacks;\n\ttype: AlertType;\n\tvariant: AlertVariant;\n} & PropLabel &\n\tPropAlert &\n\tPropHasCloser;\n\ntype RequiredAlertStates = RequiredAlertProps;\ntype OptionalAlertStates = OptionalAlertProps;\n\nexport type Props = Generic.Element.Members<RequiredAlertProps, OptionalAlertProps>;\nexport type States = Generic.Element.Members<RequiredAlertStates, OptionalAlertStates>;\nexport type API = Generic.Element.ComponentApi<RequiredAlertProps, OptionalAlertProps, RequiredAlertStates, OptionalAlertStates>;\n","import { Component, h, Host, JSX, Prop, State, Watch } from '@stencil/core';\n\nimport { translate } from '../../i18n';\nimport { HeadingLevel } from '../../types/heading-level';\nimport { HasCloserPropType, validateHasCloser } from '../../types/props/has-closer';\nimport { LabelPropType, validateLabel } from '../../types/props/label';\nimport { Log } from '../../utils/dev.utils';\nimport { setState, watchBoolean, watchValidator } from '../../utils/prop.validators';\nimport { watchHeadingLevel } from '../heading/validation';\nimport { AlertType, alertTypeOptions, AlertVariant, alertVariantOptions, API, KoliBriAlertEventCallbacks, States } from './types';\n\nconst Icon = (props: { ariaLabel: string; icon: string; label?: string }) => {\n\treturn <kol-icon class=\"heading-icon\" _label={typeof props.label === 'string' && props.label.length > 0 ? '' : props.ariaLabel} _icons={props.icon} />;\n};\n\nconst AlertIcon = (props: { label?: string; type?: AlertType }) => {\n\tswitch (props.type) {\n\t\tcase 'error':\n\t\t\treturn <Icon ariaLabel={translate('kol-error')} icon=\"codicon codicon-error\" label={props.label} />;\n\t\tcase 'info':\n\t\t\treturn <Icon ariaLabel={translate('kol-info')} icon=\"codicon codicon-info\" label={props.label} />;\n\t\tcase 'warning':\n\t\t\treturn <Icon ariaLabel={translate('kol-warning')} icon=\"codicon codicon-warning\" label={props.label} />;\n\t\tcase 'success':\n\t\t\treturn <Icon ariaLabel={translate('kol-success')} icon=\"codicon codicon-pass\" label={props.label} />;\n\t\tdefault:\n\t\t\treturn <Icon ariaLabel={translate('kol-message')} icon=\"codicon codicon-comment\" label={props.label} />;\n\t}\n};\n\n/**\n * @slot - Der Inhalt der Meldung.\n */\n@Component({\n\ttag: 'kol-alert-wc',\n\tshadow: false,\n})\nexport class KolAlertWc implements API {\n\tprivate readonly close = () => {\n\t\tif (this._on?.onClose !== undefined) {\n\t\t\tthis._on.onClose(new Event('Close'));\n\t\t}\n\t};\n\n\tprivate readonly on = {\n\t\tonClick: this.close,\n\t};\n\n\tpublic render(): JSX.Element {\n\t\tif (this.state._alert) {\n\t\t\t/**\n\t\t\t * - https://developer.mozilla.org/de/docs/Web/API/Navigator/vibrate\n\t\t\t * - https://googlechrome.github.io/samples/vibration/\n\t\t\t */\n\t\t\ttry {\n\t\t\t\tLog.debug(['Navigator should vibrate ...', navigator.vibrate([100, 75, 100, 75, 100])]);\n\t\t\t} catch (e) {\n\t\t\t\tLog.debug('Navigator does not support vibration.');\n\t\t\t}\n\n\t\t\tsetTimeout(() => {\n\t\t\t\tthis.validateAlert(false);\n\t\t\t}, 10000);\n\t\t}\n\n\t\treturn (\n\t\t\t<Host\n\t\t\t\tclass={{\n\t\t\t\t\t[this.state._type as string]: true,\n\t\t\t\t\t[this.state._variant as string]: true,\n\t\t\t\t\thasCloser: !!this.state._hasCloser,\n\t\t\t\t}}\n\t\t\t\trole={this.state._alert ? 'alert' : undefined}\n\t\t\t>\n\t\t\t\t<div class=\"heading\">\n\t\t\t\t\t<AlertIcon label={this.state._label} type={this.state._type} />\n\t\t\t\t\t<div>\n\t\t\t\t\t\t{typeof this.state._label === 'string' && this.state._label?.length > 0 && (\n\t\t\t\t\t\t\t<kol-heading-wc _label={this.state._label} _level={this.state._level}></kol-heading-wc>\n\t\t\t\t\t\t)}\n\t\t\t\t\t\t{this._variant === 'msg' && (\n\t\t\t\t\t\t\t<div class=\"content\">\n\t\t\t\t\t\t\t\t<slot />\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t)}\n\t\t\t\t\t</div>\n\t\t\t\t\t{this.state._hasCloser && (\n\t\t\t\t\t\t<kol-button-wc\n\t\t\t\t\t\t\tclass=\"close\"\n\t\t\t\t\t\t\t_hideLabel\n\t\t\t\t\t\t\t_icons={{\n\t\t\t\t\t\t\t\tleft: {\n\t\t\t\t\t\t\t\t\ticon: 'codicon codicon-close',\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t_label={translate('kol-close')}\n\t\t\t\t\t\t\t_on={this.on}\n\t\t\t\t\t\t\t_tooltipAlign=\"left\"\n\t\t\t\t\t\t></kol-button-wc>\n\t\t\t\t\t)}\n\t\t\t\t</div>\n\t\t\t\t{this._variant === 'card' && (\n\t\t\t\t\t<div class=\"content\">\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</div>\n\t\t\t\t)}\n\t\t\t</Host>\n\t\t);\n\t}\n\n\t/**\n\t * Defines whether the screen-readers should read out the notification.\n\t */\n\t@Prop() public _alert?: boolean = false;\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 * Defines which H-level from 1-6 the heading has. 0 specifies no heading and is shown as bold text.\n\t */\n\t@Prop() public _level?: HeadingLevel = 1;\n\n\t/**\n\t * Gibt die EventCallback-Function für das Schließen des Alerts an.\n\t */\n\t@Prop() public _on?: KoliBriAlertEventCallbacks;\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?: AlertType = 'default';\n\n\t/**\n\t * Defines which variant should be used for presentation.\n\t */\n\t@Prop() public _variant?: AlertVariant = 'msg';\n\n\t@State() public state: States = {\n\t\t_level: 1,\n\t};\n\n\t@Watch('_alert')\n\tpublic validateAlert(value?: boolean): void {\n\t\twatchBoolean(this, '_alert', 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('_label')\n\tpublic validateLabel(value?: LabelPropType): void {\n\t\tvalidateLabel(this, value);\n\t}\n\n\t@Watch('_level')\n\tpublic validateLevel(value?: HeadingLevel): void {\n\t\twatchHeadingLevel(this, value);\n\t}\n\n\tprivate validateOnValue = (value: unknown): boolean =>\n\t\ttypeof value === 'object' && value !== null && typeof (value as KoliBriAlertEventCallbacks).onClose === 'function';\n\n\t@Watch('_on')\n\tpublic validateOn(value?: KoliBriAlertEventCallbacks): void {\n\t\tif (this.validateOnValue(value)) {\n\t\t\tsetState<KoliBriAlertEventCallbacks>(\n\t\t\t\tthis,\n\t\t\t\t'_on',\n\t\t\t\t{\n\t\t\t\t\tonClose: (value as KoliBriAlertEventCallbacks).onClose,\n\t\t\t\t}\n\t\t\t\t// {\n\t\t\t\t// \tafterPatch: (value: unknown) => {\n\t\t\t\t// \t\tthis._hasCloser = this.validateOnValue(value);\n\t\t\t\t// \t},\n\t\t\t\t// }\n\t\t\t);\n\t\t\t// } else {\n\t\t\t// \tsetState<KoliBriAlertEventCallbacks>(this, '_on', null, {\n\t\t\t// \t\tafterPatch: (value: unknown) => {\n\t\t\t// \t\t\tthis._hasCloser = this.validateOnValue(value);\n\t\t\t// \t\t},\n\t\t\t// \t});\n\t\t}\n\t}\n\n\t@Watch('_type')\n\tpublic validateType(value?: AlertType): void {\n\t\twatchValidator(\n\t\t\tthis,\n\t\t\t'_type',\n\t\t\t(value?) => typeof value === 'string' && alertTypeOptions.includes(value),\n\t\t\tnew Set(`String {${alertTypeOptions.join(', ')}`),\n\t\t\tvalue\n\t\t);\n\t}\n\n\t@Watch('_variant')\n\tpublic validateVariant(value?: AlertVariant): void {\n\t\twatchValidator(\n\t\t\tthis,\n\t\t\t'_variant',\n\t\t\t(value?) => typeof value === 'string' && alertVariantOptions.includes(value),\n\t\t\tnew Set(`AlertVariant {${alertVariantOptions.join(', ')}`),\n\t\t\tvalue\n\t\t);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tthis.validateAlert(this._alert);\n\t\tthis.validateHasCloser(this._hasCloser);\n\t\tthis.validateLabel(this._label);\n\t\tthis.validateLevel(this._level);\n\t\tthis.validateOn(this._on);\n\t\tthis.validateType(this._type);\n\t\tthis.validateVariant(this._variant);\n\t}\n}\n","import { Component, h, Host, JSX, Prop, State, Watch } from '@stencil/core';\n\nimport { HeadingLevel } from '../../types/heading-level';\nimport { LabelWithExpertSlotPropType, validateLabelWithExpertSlot } from '../../types/props/label';\nimport { watchString } from '../../utils/prop.validators';\nimport { API, States } from './types';\nimport { watchHeadingLevel } from './validation';\n\n/**\n * @slot - Inhalt der Überschrift.\n */\n@Component({\n\ttag: 'kol-heading-wc',\n\tshadow: false,\n})\nexport class KolHeadingWc implements API {\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 H-level from 1-6 the heading has. 0 specifies no heading and is shown as bold text.\n\t */\n\t@Prop() public _level?: HeadingLevel = 1;\n\n\t/**\n\t * Setzt den Text einer weiteren Überschrift, einen Level kleiner, unter der Ersten.\n\t */\n\t@Prop() public _secondaryHeadline?: string;\n\n\t@State() public state: States = {\n\t\t_label: '', // ⚠ required\n\t\t_level: 1,\n\t};\n\n\t@Watch('_label')\n\tpublic validateLabel(value?: LabelWithExpertSlotPropType): void {\n\t\tvalidateLabelWithExpertSlot(this, value);\n\t}\n\n\t@Watch('_level')\n\tpublic validateLevel(value?: HeadingLevel): void {\n\t\twatchHeadingLevel(this, value);\n\t}\n\n\t@Watch('_secondaryHeadline')\n\tpublic validateSecondaryHeadline(value?: string): void {\n\t\twatchString(this, '_secondaryHeadline', value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tthis.validateLabel(this._label);\n\t\tthis.validateLevel(this._level);\n\t\tthis.validateSecondaryHeadline(this._secondaryHeadline);\n\t}\n\n\tprivate readonly renderHeadline = (headline: LabelWithExpertSlotPropType, level?: number): JSX.Element => {\n\t\tswitch (level) {\n\t\t\tcase 1:\n\t\t\t\treturn (\n\t\t\t\t\t<h1 class=\"headline\">\n\t\t\t\t\t\t{headline}\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</h1>\n\t\t\t\t);\n\t\t\tcase 2:\n\t\t\t\treturn (\n\t\t\t\t\t<h2 class=\"headline\">\n\t\t\t\t\t\t{headline}\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</h2>\n\t\t\t\t);\n\t\t\tcase 3:\n\t\t\t\treturn (\n\t\t\t\t\t<h3 class=\"headline\">\n\t\t\t\t\t\t{headline}\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</h3>\n\t\t\t\t);\n\t\t\tcase 4:\n\t\t\t\treturn (\n\t\t\t\t\t<h4 class=\"headline\">\n\t\t\t\t\t\t{headline}\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</h4>\n\t\t\t\t);\n\t\t\tcase 5:\n\t\t\t\treturn (\n\t\t\t\t\t<h5 class=\"headline\">\n\t\t\t\t\t\t{headline}\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</h5>\n\t\t\t\t);\n\t\t\tcase 6:\n\t\t\t\treturn (\n\t\t\t\t\t<h6 class=\"headline\">\n\t\t\t\t\t\t{headline}\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</h6>\n\t\t\t\t);\n\t\t\tdefault:\n\t\t\t\treturn (\n\t\t\t\t\t<strong class=\"headline\">\n\t\t\t\t\t\t{headline}\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</strong>\n\t\t\t\t);\n\t\t}\n\t};\n\n\tprivate readonly renderSecondaryHeadline = (headline: string, level?: number): JSX.Element => {\n\t\tswitch (level) {\n\t\t\tcase 1: // if the headline is only strong\n\t\t\t\treturn <span class=\"secondary-headline\">{headline}</span>;\n\t\t\tcase 2: // if the headline is h1\n\t\t\t\treturn <h2 class=\"secondary-headline\">{headline}</h2>;\n\t\t\tcase 3: // if the headline is h2\n\t\t\t\treturn <h3 class=\"secondary-headline\">{headline}</h3>;\n\t\t\tcase 4: // if the headline is h3\n\t\t\t\treturn <h4 class=\"secondary-headline\">{headline}</h4>;\n\t\t\tcase 5: // if the headline is h4\n\t\t\t\treturn <h5 class=\"secondary-headline\">{headline}</h5>;\n\t\t\tcase 6: // if the headline is h5\n\t\t\t\treturn <h6 class=\"secondary-headline\">{headline}</h6>;\n\t\t\tdefault: // if the headline is h6\n\t\t\t\treturn <strong class=\"secondary-headline\">{headline}</strong>;\n\t\t}\n\t};\n\n\tpublic render(): JSX.Element {\n\t\treturn (\n\t\t\t<Host>\n\t\t\t\t{typeof this.state._secondaryHeadline === 'string' && this.state._secondaryHeadline.length > 0 ? (\n\t\t\t\t\t<hgroup>\n\t\t\t\t\t\t{this.renderHeadline(this.state._label, this.state._level)}\n\t\t\t\t\t\t{this.state._secondaryHeadline && this.renderSecondaryHeadline(this.state._secondaryHeadline, this.state._level + 1)}\n\t\t\t\t\t</hgroup>\n\t\t\t\t) : (\n\t\t\t\t\tthis.renderHeadline(this.state._label, this.state._level)\n\t\t\t\t)}\n\t\t\t</Host>\n\t\t);\n\t}\n}\n"],"mappings":"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"}
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{r as s,h as t,H as a}from"./index-9c30809b.js";import{a as i}from"./i18n-8ec5b30e.js";import{v as r}from"./image-source-ceb96521.js";import{v as e}from"./label-5c173d60.js";import"./index-b79e4012.js";import"./dev.utils-075f4e7b.js";import"./reuse-b3566e4c.js";import"./a11y.tipps-06cd7c77.js";import"./prop.validators-3d53ddab.js";const o=t=>0===t.length?"":t[0].toUpperCase(),l=t=>{const a=t.split(/\s+/),s=a.at(0),e=a.at(-1);return a.length>=2&&s&&e?`${o(s)}${o(e)}`:o(t)},c=class{constructor(t){s(this,t),this._src=void 0,this._label=void 0,this.state={_src:"",_label:""}}render(){return t(a,null,t("div",{"aria-label":i("kol-avatar-alt",{placeholders:{name:this.state._label}}),class:"container",role:"img"},this.state._src?t("img",{alt:"","aria-hidden":"true",class:"image",src:this.state._src}):t("span",{"aria-hidden":"true",class:"initials"},l(this.state._label))))}validateSrc(t){r(this,t)}validateLabel(t){e(this,t)}componentWillLoad(){this.validateSrc(this._src),this.validateLabel(this._label)}static get watchers(){return{_src:["validateSrc"],_label:["validateLabel"]}}};export{c as kol_avatar_wc};
4
+ import{r as s,h as t,H as a}from"./index-9c30809b.js";import{a as i}from"./i18n-bb569ab8.js";import{v as r}from"./image-source-bdd50deb.js";import{v as e}from"./label-2cb169c2.js";import"./index-7a38e9a3.js";import"./dev.utils-34544843.js";import"./reuse-b3566e4c.js";import"./a11y.tipps-ce35f0ba.js";import"./prop.validators-b0d023a4.js";const o=a=>0===a.length?"":a[0].toUpperCase(),l=a=>{const t=a.split(/\s+/),s=t.at(0),e=t.at(-1);return t.length>=2&&s&&e?`${o(s)}${o(e)}`:o(a)},n=class{constructor(a){s(this,a),this._src=void 0,this._label=void 0,this.state={_src:"",_label:""}}render(){return t(a,null,t("div",{"aria-label":i("kol-avatar-alt",{placeholders:{name:this.state._label}}),class:"container",role:"img"},this.state._src?t("img",{alt:"","aria-hidden":"true",class:"image",src:this.state._src}):t("span",{"aria-hidden":"true",class:"initials"},l(this.state._label))))}validateSrc(a){r(this,a)}validateLabel(a){e(this,a)}componentWillLoad(){this.validateSrc(this._src),this.validateLabel(this._label)}static get watchers(){return{_src:["validateSrc"],_label:["validateLabel"]}}};export{n as kol_avatar_wc};
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{r as t,h as n,H as e}from"./index-9c30809b.js";import{h as i,v as o}from"./color-84b42735.js";import{f as s}from"./a11y.tipps-06cd7c77.js";import{n as a}from"./dev.utils-075f4e7b.js";import{o as r,p as l,s as h}from"./prop.validators-3d53ddab.js";import"./reuse-b3566e4c.js";const d="@layer kol-global {\n\t/*\n\t * This file contains all rules for accessibility.\n\t */\n\t:host {\n\t\t/*\n\t\t * Minimum size of interactive elements.\n\t\t */\n\t\t--a11y-min-size: 44px;\n\t\tfont-size: inherit;\n\t}\n\n\t* {\n\t\t/*\n\t\t * Verdana is an accessible font that can be used without requiring additional loading time.\n\t\t */\n\t\tfont-family: Verdana;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\thyphens: auto;\n\t\t/*\n\t\t * Letter spacing is required for all texts.\n\t\t */\n\t\tletter-spacing: inherit;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\tword-break: break-word;\n\t\t/*\n\t\t * Word spacing is required for all texts.\n\t\t */\n\t\tword-spacing: inherit;\n\t}\n\n\t/*\n\t * All interactive elements should have a minimum size of 44px.\n\t */\n\t/* input:not([type='checkbox'], [type='radio'], [type='range']), */\n\t/* option, */\n\t/* select, */\n\t/* textarea, */\n\t[role='button'],\n\tbutton:not([role='link']),\n\tkol-input .input {\n\t\tmin-height: var(--a11y-min-size);\n\t\tmin-width: var(--a11y-min-size);\n\t}\n\n\t/*\n\t * Some interactive elements should not inherit the font-family and font-size.\n\t */\n\ta,\n\tbutton,\n\th1,\n\th2,\n\th3,\n\th4,\n\th5,\n\th6,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\t/*\n\t\t * All elements should inherit the font family from his parent element.\n\t\t */\n\t\tfont-family: inherit;\n\t\t/*\n\t\t * All elements should inherit the font size from his parent element.\n\t\t */\n\t\tfont-size: inherit;\n\t}\n}\n\n@layer kol-global {\n\t/*\n\t * Dieses CSS stellt sicher, dass der Standard-Style\n\t * von A und Button resettet werden.\n\t */\n\t:is(a, button) {\n\t\tbackground-color: transparent;\n\t\tborder: none;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\twidth: 100%; /* 100% needed for custom width from outside */\n\t}\n}\n\n@layer kol-global {\n\t:host {\n\t\t/*\n\t\t * The max-width is needed to prevent the table from overflowing the\n\t\t * parent node, if the table is wider than the parent node.\n\t\t */\n\t\tmax-width: 100%;\n\t}\n\n\t* {\n\t\t/*\n\t\t * We prefer to box-sizing: border-box for all elements.\n\t\t */\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n\tkol-span-wc {\n\t\tdisplay: grid;\n\t\tplace-items: center;\n\t}\n\n\t/* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n\tkol-span-wc > span {\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\ta,\n\tbutton {\n\t\tcursor: pointer;\n\t}\n\n\t/* font-family is NOT inherited all HTML elements. */\n\tbutton,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\tfont-family: inherit;\n\t}\n\n\t/* This is the text label. */\n\t.icon-only > kol-span-wc > span > span {\n\t\tdisplay: none;\n\t}\n}\n\n@layer kol-component {\n\t:host > span {\n\t\tdisplay: inline-flex;\n\t\tplace-items: center;\n\t}\n\n\t:host > span > kol-button-wc button {\n\t\tcolor: inherit;\n\t}\n}\n";s("[KolBadge] Optimierung des _color-Properties (rgba, rgb, hex usw.).");const c=class{constructor(n){t(this,n),this.bgColorStr="#000",this.colorStr="#fff",this.id=a(),this.handleColorChange=t=>{const n=i(t);this.bgColorStr=n.backgroundColor,this.colorStr=n.foregroundColor},this._color="#000",this._icons=void 0,this._label=void 0,this._smartButton=void 0,this.state={_color:{backgroundColor:"#000",foregroundColor:"#fff"}}}renderSmartButton(t){return n("kol-button-wc",{_ariaControls:this.id,_customClass:t._customClass,_disabled:t._disabled,_hideLabel:!0,_icons:t._icons,_id:t._id,_label:t._label,_on:t._on,_tooltipAlign:t._tooltipAlign,_variant:t._variant})}render(){const t="object"==typeof this.state._smartButton&&null!==this.state._smartButton;return n(e,null,n("span",{class:{"smart-button":"object"==typeof this.state._smartButton&&null!==this.state._smartButton},style:{backgroundColor:this.bgColorStr,color:this.colorStr}},n("kol-span-wc",{id:t?this.id:void 0,_allowMarkdown:!0,_icons:this._icons,_label:this._label}),t&&this.renderSmartButton(this.state._smartButton)))}validateColor(t){o(this,t,{defaultValue:"#000",hooks:{beforePatch:this.handleColorChange}})}validateSmartButton(t){r(t,(()=>{try{t=l(t)}catch(t){}h(this,"_smartButton",t)}))}componentWillLoad(){this.validateColor(this._color),this.validateSmartButton(this._smartButton)}static get watchers(){return{_color:["validateColor"],_smartButton:["validateSmartButton"]}}};c.style={default:d};export{c as kol_badge};
4
+ import{r as t,h as n,H as e}from"./index-9c30809b.js";import{h as i,v as o}from"./color-d643b48d.js";import{f as s}from"./a11y.tipps-ce35f0ba.js";import{n as a}from"./dev.utils-34544843.js";import{o as r,p as l,s as h}from"./prop.validators-b0d023a4.js";import"./reuse-b3566e4c.js";const d="@layer kol-global {\n\t/*\n\t * This file contains all rules for accessibility.\n\t */\n\t:host {\n\t\t/*\n\t\t * Minimum size of interactive elements.\n\t\t */\n\t\t--a11y-min-size: 44px;\n\t\tfont-size: inherit;\n\t}\n\n\t* {\n\t\t/*\n\t\t * Verdana is an accessible font that can be used without requiring additional loading time.\n\t\t */\n\t\tfont-family: Verdana;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\thyphens: auto;\n\t\t/*\n\t\t * Letter spacing is required for all texts.\n\t\t */\n\t\tletter-spacing: inherit;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\tword-break: break-word;\n\t\t/*\n\t\t * Word spacing is required for all texts.\n\t\t */\n\t\tword-spacing: inherit;\n\t}\n\n\t/*\n\t * All interactive elements should have a minimum size of 44px.\n\t */\n\t/* input:not([type='checkbox'], [type='radio'], [type='range']), */\n\t/* option, */\n\t/* select, */\n\t/* textarea, */\n\t[role='button'],\n\tbutton:not([role='link']),\n\tkol-input .input {\n\t\tmin-height: var(--a11y-min-size);\n\t\tmin-width: var(--a11y-min-size);\n\t}\n\n\t/*\n\t * Some interactive elements should not inherit the font-family and font-size.\n\t */\n\ta,\n\tbutton,\n\th1,\n\th2,\n\th3,\n\th4,\n\th5,\n\th6,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\t/*\n\t\t * All elements should inherit the font family from his parent element.\n\t\t */\n\t\tfont-family: inherit;\n\t\t/*\n\t\t * All elements should inherit the font size from his parent element.\n\t\t */\n\t\tfont-size: inherit;\n\t}\n}\n\n@layer kol-global {\n\t/*\n\t * Dieses CSS stellt sicher, dass der Standard-Style\n\t * von A und Button resettet werden.\n\t */\n\t:is(a, button) {\n\t\tbackground-color: transparent;\n\t\tborder: none;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\twidth: 100%; /* 100% needed for custom width from outside */\n\t}\n}\n\n@layer kol-global {\n\t:host {\n\t\t/*\n\t\t * The max-width is needed to prevent the table from overflowing the\n\t\t * parent node, if the table is wider than the parent node.\n\t\t */\n\t\tmax-width: 100%;\n\t}\n\n\t* {\n\t\t/*\n\t\t * We prefer to box-sizing: border-box for all elements.\n\t\t */\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n\tkol-span-wc {\n\t\tdisplay: grid;\n\t\tplace-items: center;\n\t}\n\n\t/* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n\tkol-span-wc > span {\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\ta,\n\tbutton {\n\t\tcursor: pointer;\n\t}\n\n\t/* font-family is NOT inherited all HTML elements. */\n\tbutton,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\tfont-family: inherit;\n\t}\n\n\t/* This is the text label. */\n\t.icon-only > kol-span-wc > span > span {\n\t\tdisplay: none;\n\t}\n}\n\n@layer kol-component {\n\t:host > span {\n\t\tdisplay: inline-flex;\n\t\tplace-items: center;\n\t}\n\n\t:host > span > kol-button-wc button {\n\t\tcolor: inherit;\n\t}\n}\n";s("[KolBadge] Optimierung des _color-Properties (rgba, rgb, hex usw.).");const c=class{constructor(n){t(this,n),this.bgColorStr="#000",this.colorStr="#fff",this.id=a(),this.handleColorChange=t=>{const n=i(t);this.bgColorStr=n.backgroundColor,this.colorStr=n.foregroundColor},this._color="#000",this._icons=void 0,this._label=void 0,this._smartButton=void 0,this.state={_color:{backgroundColor:"#000",foregroundColor:"#fff"}}}renderSmartButton(t){return n("kol-button-wc",{_ariaControls:this.id,_customClass:t._customClass,_disabled:t._disabled,_hideLabel:!0,_icons:t._icons,_id:t._id,_label:t._label,_on:t._on,_tooltipAlign:t._tooltipAlign,_variant:t._variant})}render(){const t="object"==typeof this.state._smartButton&&null!==this.state._smartButton;return n(e,null,n("span",{class:{"smart-button":"object"==typeof this.state._smartButton&&null!==this.state._smartButton},style:{backgroundColor:this.bgColorStr,color:this.colorStr}},n("kol-span-wc",{id:t?this.id:void 0,_allowMarkdown:!0,_icons:this._icons,_label:this._label}),t&&this.renderSmartButton(this.state._smartButton)))}validateColor(t){o(this,t,{defaultValue:"#000",hooks:{beforePatch:this.handleColorChange}})}validateSmartButton(t){r(t,(()=>{try{t=l(t)}catch(t){}h(this,"_smartButton",t)}))}componentWillLoad(){this.validateColor(this._color),this.validateSmartButton(this._smartButton)}static get watchers(){return{_color:["validateColor"],_smartButton:["validateSmartButton"]}}};c.style={default:d};export{c as kol_badge};
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{r as t,h as n,F as e,H as i}from"./index-9c30809b.js";import{v as o}from"./label-5c173d60.js";import{b as a}from"./a11y.tipps-06cd7c77.js";import{r as l,a as s}from"./unique-nav-labels-c6750f60.js";import{w as r}from"./validation-68e14b6f.js";import"./prop.validators-3d53ddab.js";import"./dev.utils-075f4e7b.js";import"./reuse-b3566e4c.js";const d="@layer kol-global {\n\t/*\n\t * This file contains all rules for accessibility.\n\t */\n\t:host {\n\t\t/*\n\t\t * Minimum size of interactive elements.\n\t\t */\n\t\t--a11y-min-size: 44px;\n\t\tfont-size: inherit;\n\t}\n\n\t* {\n\t\t/*\n\t\t * Verdana is an accessible font that can be used without requiring additional loading time.\n\t\t */\n\t\tfont-family: Verdana;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\thyphens: auto;\n\t\t/*\n\t\t * Letter spacing is required for all texts.\n\t\t */\n\t\tletter-spacing: inherit;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\tword-break: break-word;\n\t\t/*\n\t\t * Word spacing is required for all texts.\n\t\t */\n\t\tword-spacing: inherit;\n\t}\n\n\t/*\n\t * All interactive elements should have a minimum size of 44px.\n\t */\n\t/* input:not([type='checkbox'], [type='radio'], [type='range']), */\n\t/* option, */\n\t/* select, */\n\t/* textarea, */\n\t[role='button'],\n\tbutton:not([role='link']),\n\tkol-input .input {\n\t\tmin-height: var(--a11y-min-size);\n\t\tmin-width: var(--a11y-min-size);\n\t}\n\n\t/*\n\t * Some interactive elements should not inherit the font-family and font-size.\n\t */\n\ta,\n\tbutton,\n\th1,\n\th2,\n\th3,\n\th4,\n\th5,\n\th6,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\t/*\n\t\t * All elements should inherit the font family from his parent element.\n\t\t */\n\t\tfont-family: inherit;\n\t\t/*\n\t\t * All elements should inherit the font size from his parent element.\n\t\t */\n\t\tfont-size: inherit;\n\t}\n}\n\n@layer kol-global {\n\t/*\n\t * Dieses CSS stellt sicher, dass der Standard-Style\n\t * von A und Button resettet werden.\n\t */\n\t:is(a, button) {\n\t\tbackground-color: transparent;\n\t\tborder: none;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\twidth: 100%; /* 100% needed for custom width from outside */\n\t}\n}\n\n@layer kol-global {\n\t:host {\n\t\t/*\n\t\t * The max-width is needed to prevent the table from overflowing the\n\t\t * parent node, if the table is wider than the parent node.\n\t\t */\n\t\tmax-width: 100%;\n\t}\n\n\t* {\n\t\t/*\n\t\t * We prefer to box-sizing: border-box for all elements.\n\t\t */\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n\tkol-span-wc {\n\t\tdisplay: grid;\n\t\tplace-items: center;\n\t}\n\n\t/* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n\tkol-span-wc > span {\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\ta,\n\tbutton {\n\t\tcursor: pointer;\n\t}\n\n\t/* font-family is NOT inherited all HTML elements. */\n\tbutton,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\tfont-family: inherit;\n\t}\n\n\t/* This is the text label. */\n\t.icon-only > kol-span-wc > span > span {\n\t\tdisplay: none;\n\t}\n}\n\n@layer kol-component {\n\tli,\n\tul {\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\tlist-style: none;\n\t\tdisplay: flex;\n\t\tgap: 0.5em;\n\t\tflex-wrap: wrap;\n\t\tplace-items: center;\n\t}\n\n\tkol-icon::part(separator) {\n\t\tfont-weight: 900;\n\t\tfont-size: 0.7em;\n\t}\n\n\tkol-icon::part(separator):before {\n\t\tcontent: '\\f054';\n\t\tfont-family: 'Font Awesome 6 Free';\n\t}\n}\n",h=class{constructor(i){t(this,i),this.renderLink=(t,i)=>{const l=this.state._links.length-1;return n("li",{key:i},0!==i&&n("kol-icon",{_label:"",_icons:"codicon codicon-chevron-right"}),i===l?n("span",null,t._hideLabel?n("kol-icon",{_label:t._label,_icons:"string"==typeof t._icons?t._icons:"codicon codicon-symbol-event"}):n(e,null,t._label)):n("kol-link",Object.assign({},t)))},this._label=void 0,this._links=void 0,this.state={_label:"…",_links:[]}}render(){return n(i,null,n("nav",{"aria-label":this.state._label},n("ul",null,0===this.state._links.length&&n("li",null,n("kol-icon",{_label:"",_icons:"codicon codicon-home"}),"…"),this.state._links.map(this.renderLink))))}validateLabel(t,n,e=!1){e||l(this.state._label),o(this,t),a(t),s(this.state._label)}validateLinks(t){r("KolBreadcrumb",this,t)}componentWillLoad(){this.validateLabel(this._label,void 0,!0),this.validateLinks(this._links)}disconnectedCallback(){l(this.state._label)}static get watchers(){return{_label:["validateLabel"],_links:["validateLinks"]}}};h.style={default:d};export{h as kol_breadcrumb};
4
+ import{r as t,h as n,F as e,H as i}from"./index-9c30809b.js";import{v as o}from"./label-2cb169c2.js";import{b as a}from"./a11y.tipps-ce35f0ba.js";import{r as l,a as s}from"./unique-nav-labels-c6750f60.js";import{w as r}from"./validation-6962a682.js";import"./prop.validators-b0d023a4.js";import"./dev.utils-34544843.js";import"./reuse-b3566e4c.js";const d="@layer kol-global {\n\t/*\n\t * This file contains all rules for accessibility.\n\t */\n\t:host {\n\t\t/*\n\t\t * Minimum size of interactive elements.\n\t\t */\n\t\t--a11y-min-size: 44px;\n\t\tfont-size: inherit;\n\t}\n\n\t* {\n\t\t/*\n\t\t * Verdana is an accessible font that can be used without requiring additional loading time.\n\t\t */\n\t\tfont-family: Verdana;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\thyphens: auto;\n\t\t/*\n\t\t * Letter spacing is required for all texts.\n\t\t */\n\t\tletter-spacing: inherit;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\tword-break: break-word;\n\t\t/*\n\t\t * Word spacing is required for all texts.\n\t\t */\n\t\tword-spacing: inherit;\n\t}\n\n\t/*\n\t * All interactive elements should have a minimum size of 44px.\n\t */\n\t/* input:not([type='checkbox'], [type='radio'], [type='range']), */\n\t/* option, */\n\t/* select, */\n\t/* textarea, */\n\t[role='button'],\n\tbutton:not([role='link']),\n\tkol-input .input {\n\t\tmin-height: var(--a11y-min-size);\n\t\tmin-width: var(--a11y-min-size);\n\t}\n\n\t/*\n\t * Some interactive elements should not inherit the font-family and font-size.\n\t */\n\ta,\n\tbutton,\n\th1,\n\th2,\n\th3,\n\th4,\n\th5,\n\th6,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\t/*\n\t\t * All elements should inherit the font family from his parent element.\n\t\t */\n\t\tfont-family: inherit;\n\t\t/*\n\t\t * All elements should inherit the font size from his parent element.\n\t\t */\n\t\tfont-size: inherit;\n\t}\n}\n\n@layer kol-global {\n\t/*\n\t * Dieses CSS stellt sicher, dass der Standard-Style\n\t * von A und Button resettet werden.\n\t */\n\t:is(a, button) {\n\t\tbackground-color: transparent;\n\t\tborder: none;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\twidth: 100%; /* 100% needed for custom width from outside */\n\t}\n}\n\n@layer kol-global {\n\t:host {\n\t\t/*\n\t\t * The max-width is needed to prevent the table from overflowing the\n\t\t * parent node, if the table is wider than the parent node.\n\t\t */\n\t\tmax-width: 100%;\n\t}\n\n\t* {\n\t\t/*\n\t\t * We prefer to box-sizing: border-box for all elements.\n\t\t */\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n\tkol-span-wc {\n\t\tdisplay: grid;\n\t\tplace-items: center;\n\t}\n\n\t/* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n\tkol-span-wc > span {\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\ta,\n\tbutton {\n\t\tcursor: pointer;\n\t}\n\n\t/* font-family is NOT inherited all HTML elements. */\n\tbutton,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\tfont-family: inherit;\n\t}\n\n\t/* This is the text label. */\n\t.icon-only > kol-span-wc > span > span {\n\t\tdisplay: none;\n\t}\n}\n\n@layer kol-component {\n\tli,\n\tul {\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\tlist-style: none;\n\t\tdisplay: flex;\n\t\tgap: 0.5em;\n\t\tflex-wrap: wrap;\n\t\tplace-items: center;\n\t}\n\n\tkol-icon::part(separator) {\n\t\tfont-weight: 900;\n\t\tfont-size: 0.7em;\n\t}\n\n\tkol-icon::part(separator):before {\n\t\tcontent: '\\f054';\n\t\tfont-family: 'Font Awesome 6 Free';\n\t}\n}\n",h=class{constructor(i){t(this,i),this.renderLink=(t,i)=>{const l=this.state._links.length-1;return n("li",{key:i},0!==i&&n("kol-icon",{_label:"",_icons:"codicon codicon-chevron-right"}),i===l?n("span",null,t._hideLabel?n("kol-icon",{_label:t._label,_icons:"string"==typeof t._icons?t._icons:"codicon codicon-symbol-event"}):n(e,null,t._label)):n("kol-link",Object.assign({},t)))},this._label=void 0,this._links=void 0,this.state={_label:"…",_links:[]}}render(){return n(i,null,n("nav",{"aria-label":this.state._label},n("ul",null,0===this.state._links.length&&n("li",null,n("kol-icon",{_label:"",_icons:"codicon codicon-home"}),"…"),this.state._links.map(this.renderLink))))}validateLabel(t,n,e=!1){e||l(this.state._label),o(this,t),a(t),s(this.state._label)}validateLinks(t){r("KolBreadcrumb",this,t)}componentWillLoad(){this.validateLabel(this._label,void 0,!0),this.validateLinks(this._links)}disconnectedCallback(){l(this.state._label)}static get watchers(){return{_label:["validateLabel"],_links:["validateLinks"]}}};h.style={default:d};export{h as kol_breadcrumb};
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{r as t,h as n,H as e,g as i}from"./index-9c30809b.js";import{a as s}from"./reuse-b3566e4c.js";const o="@layer kol-global {\n\t/*\n\t * This file contains all rules for accessibility.\n\t */\n\t:host {\n\t\t/*\n\t\t * Minimum size of interactive elements.\n\t\t */\n\t\t--a11y-min-size: 44px;\n\t\tfont-size: inherit;\n\t}\n\n\t* {\n\t\t/*\n\t\t * Verdana is an accessible font that can be used without requiring additional loading time.\n\t\t */\n\t\tfont-family: Verdana;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\thyphens: auto;\n\t\t/*\n\t\t * Letter spacing is required for all texts.\n\t\t */\n\t\tletter-spacing: inherit;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\tword-break: break-word;\n\t\t/*\n\t\t * Word spacing is required for all texts.\n\t\t */\n\t\tword-spacing: inherit;\n\t}\n\n\t/*\n\t * All interactive elements should have a minimum size of 44px.\n\t */\n\t/* input:not([type='checkbox'], [type='radio'], [type='range']), */\n\t/* option, */\n\t/* select, */\n\t/* textarea, */\n\t[role='button'],\n\tbutton:not([role='link']),\n\tkol-input .input {\n\t\tmin-height: var(--a11y-min-size);\n\t\tmin-width: var(--a11y-min-size);\n\t}\n\n\t/*\n\t * Some interactive elements should not inherit the font-family and font-size.\n\t */\n\ta,\n\tbutton,\n\th1,\n\th2,\n\th3,\n\th4,\n\th5,\n\th6,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\t/*\n\t\t * All elements should inherit the font family from his parent element.\n\t\t */\n\t\tfont-family: inherit;\n\t\t/*\n\t\t * All elements should inherit the font size from his parent element.\n\t\t */\n\t\tfont-size: inherit;\n\t}\n}\n\n@layer kol-global {\n\t/*\n\t * Dieses CSS stellt sicher, dass der Standard-Style\n\t * von A und Button resettet werden.\n\t */\n\t:is(a, button) {\n\t\tbackground-color: transparent;\n\t\tborder: none;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\twidth: 100%; /* 100% needed for custom width from outside */\n\t}\n}\n\n@layer kol-global {\n\t:host {\n\t\t/*\n\t\t * The max-width is needed to prevent the table from overflowing the\n\t\t * parent node, if the table is wider than the parent node.\n\t\t */\n\t\tmax-width: 100%;\n\t}\n\n\t* {\n\t\t/*\n\t\t * We prefer to box-sizing: border-box for all elements.\n\t\t */\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n\tkol-span-wc {\n\t\tdisplay: grid;\n\t\tplace-items: center;\n\t}\n\n\t/* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n\tkol-span-wc > span {\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\ta,\n\tbutton {\n\t\tcursor: pointer;\n\t}\n\n\t/* font-family is NOT inherited all HTML elements. */\n\tbutton,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\tfont-family: inherit;\n\t}\n\n\t/* This is the text label. */\n\t.icon-only > kol-span-wc > span > span {\n\t\tdisplay: none;\n\t}\n}\n\n@layer kol-component {\n\t:host {\n\t\tdisplay: inline-block;\n\t}\n\n\t:is(a, button) {\n\t\talign-items: baseline;\n\t\tdisplay: inline-flex;\n\t\tplace-items: center;\n\t\ttext-align: left;\n\t\ttext-decoration-line: underline;\n\t}\n\n\t:is(a, button):is(:focus, :hover) {\n\t\ttext-decoration-thickness: 0.2em;\n\t}\n\n\t.hidden {\n\t\tdisplay: none;\n\t\tvisibility: hidden;\n\t}\n\n\t.skip {\n\t\tleft: -99999px;\n\t\toverflow: hidden;\n\t\tposition: absolute;\n\t\tz-index: 9999999;\n\t\tline-height: 1em;\n\t}\n\n\t.skip:focus {\n\t\tbackground-color: #fff;\n\t\tleft: unset;\n\t\tpadding: 1em;\n\t\tposition: unset;\n\t}\n\n\tkol-icon.external-link-icon {\n\t\tdisplay: inline-flex;\n\t}\n}\n\n",l=class{constructor(n){t(this,n),this.catchRef=t=>{this.ref=t,s(this.host,this.ref)},this._accessKey=void 0,this._ariaControls=void 0,this._ariaExpanded=void 0,this._ariaSelected=void 0,this._disabled=!1,this._hideLabel=!1,this._icons=void 0,this._id=void 0,this._label=void 0,this._name=void 0,this._on=void 0,this._role=void 0,this._syncValueBySelector=void 0,this._tabIndex=void 0,this._tooltipAlign="top",this._type="button",this._value=void 0}render(){return n(e,null,n("kol-button-wc",{ref:this.catchRef,_accessKey:this._accessKey,_ariaControls:this._ariaControls,_ariaExpanded:this._ariaExpanded,_ariaSelected:this._ariaSelected,_disabled:this._disabled,_icons:this._icons,_hideLabel:this._hideLabel,_id:this._id,_label:this._label,_name:this._name,_on:this._on,_role:"link",_syncValueBySelector:this._syncValueBySelector,_tabIndex:this._tabIndex,_tooltipAlign:this._tooltipAlign,_type:this._type,_value:this._value},n("slot",{name:"expert",slot:"expert"})))}get host(){return i(this)}};l.style={default:o};export{l as kol_button_link};
4
+ import{r as t,h as n,H as e,g as i}from"./index-9c30809b.js";import{a as s}from"./reuse-b3566e4c.js";const o="@layer kol-global {\n\t/*\n\t * This file contains all rules for accessibility.\n\t */\n\t:host {\n\t\t/*\n\t\t * Minimum size of interactive elements.\n\t\t */\n\t\t--a11y-min-size: 44px;\n\t\tfont-size: inherit;\n\t}\n\n\t* {\n\t\t/*\n\t\t * Verdana is an accessible font that can be used without requiring additional loading time.\n\t\t */\n\t\tfont-family: Verdana;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\thyphens: auto;\n\t\t/*\n\t\t * Letter spacing is required for all texts.\n\t\t */\n\t\tletter-spacing: inherit;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\tword-break: break-word;\n\t\t/*\n\t\t * Word spacing is required for all texts.\n\t\t */\n\t\tword-spacing: inherit;\n\t}\n\n\t/*\n\t * All interactive elements should have a minimum size of 44px.\n\t */\n\t/* input:not([type='checkbox'], [type='radio'], [type='range']), */\n\t/* option, */\n\t/* select, */\n\t/* textarea, */\n\t[role='button'],\n\tbutton:not([role='link']),\n\tkol-input .input {\n\t\tmin-height: var(--a11y-min-size);\n\t\tmin-width: var(--a11y-min-size);\n\t}\n\n\t/*\n\t * Some interactive elements should not inherit the font-family and font-size.\n\t */\n\ta,\n\tbutton,\n\th1,\n\th2,\n\th3,\n\th4,\n\th5,\n\th6,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\t/*\n\t\t * All elements should inherit the font family from his parent element.\n\t\t */\n\t\tfont-family: inherit;\n\t\t/*\n\t\t * All elements should inherit the font size from his parent element.\n\t\t */\n\t\tfont-size: inherit;\n\t}\n}\n\n@layer kol-global {\n\t/*\n\t * Dieses CSS stellt sicher, dass der Standard-Style\n\t * von A und Button resettet werden.\n\t */\n\t:is(a, button) {\n\t\tbackground-color: transparent;\n\t\tborder: none;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\twidth: 100%; /* 100% needed for custom width from outside */\n\t}\n}\n\n@layer kol-global {\n\t:host {\n\t\t/*\n\t\t * The max-width is needed to prevent the table from overflowing the\n\t\t * parent node, if the table is wider than the parent node.\n\t\t */\n\t\tmax-width: 100%;\n\t}\n\n\t* {\n\t\t/*\n\t\t * We prefer to box-sizing: border-box for all elements.\n\t\t */\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n\tkol-span-wc {\n\t\tdisplay: grid;\n\t\tplace-items: center;\n\t}\n\n\t/* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n\tkol-span-wc > span {\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\ta,\n\tbutton {\n\t\tcursor: pointer;\n\t}\n\n\t/* font-family is NOT inherited all HTML elements. */\n\tbutton,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\tfont-family: inherit;\n\t}\n\n\t/* This is the text label. */\n\t.icon-only > kol-span-wc > span > span {\n\t\tdisplay: none;\n\t}\n}\n\n@layer kol-component {\n\t:host {\n\t\tdisplay: inline-block;\n\t}\n\n\t:is(a, button) {\n\t\talign-items: baseline;\n\t\tdisplay: inline-flex;\n\t\tplace-items: center;\n\t\ttext-align: left;\n\t\ttext-decoration-line: underline;\n\t}\n\n\t:is(a, button):is(:focus, :hover) {\n\t\ttext-decoration-thickness: 0.2em;\n\t}\n\n\t.hidden {\n\t\tdisplay: none;\n\t\tvisibility: hidden;\n\t}\n\n\t.skip {\n\t\tleft: -99999px;\n\t\toverflow: hidden;\n\t\tposition: absolute;\n\t\tz-index: 9999999;\n\t\tline-height: 1em;\n\t}\n\n\t.skip:focus {\n\t\tbackground-color: #fff;\n\t\tleft: unset;\n\t\tpadding: 1em;\n\t\tposition: unset;\n\t}\n\n\tkol-icon.external-link-icon {\n\t\tdisplay: inline-flex;\n\t}\n}\n\n",l=class{constructor(n){t(this,n),this.catchRef=t=>{s(this.host,t)},this._accessKey=void 0,this._ariaControls=void 0,this._ariaExpanded=void 0,this._ariaSelected=void 0,this._disabled=!1,this._hideLabel=!1,this._icons=void 0,this._id=void 0,this._label=void 0,this._name=void 0,this._on=void 0,this._role=void 0,this._syncValueBySelector=void 0,this._tabIndex=void 0,this._tooltipAlign="top",this._type="button",this._value=void 0}render(){return n(e,null,n("kol-button-wc",{ref:this.catchRef,_accessKey:this._accessKey,_ariaControls:this._ariaControls,_ariaExpanded:this._ariaExpanded,_ariaSelected:this._ariaSelected,_disabled:this._disabled,_icons:this._icons,_hideLabel:this._hideLabel,_id:this._id,_label:this._label,_name:this._name,_on:this._on,_role:"link",_syncValueBySelector:this._syncValueBySelector,_tabIndex:this._tabIndex,_tooltipAlign:this._tooltipAlign,_type:this._type,_value:this._value},n("slot",{name:"expert",slot:"expert"})))}get host(){return i(this)}};l.style={default:o};export{l as kol_button_link};
@@ -1 +1 @@
1
- {"version":3,"names":["defaultStyleCss","KolButtonLink","this","catchRef","ref","propagateFocus","host","render","h","Host","_accessKey","_ariaControls","_ariaExpanded","_ariaSelected","_disabled","_icons","_hideLabel","_id","_label","_name","_on","_role","_syncValueBySelector","_tabIndex","_tooltipAlign","_type","_value","name","slot"],"sources":["src/components/button-link/style.css?tag=kol-button-link&mode=default&encapsulation=shadow","src/components/button-link/component.tsx"],"sourcesContent":["@import url(../link.css);\n","import { Component, Element, h, Host, JSX, Prop } from '@stencil/core';\n\nimport { Stringified } from '../../types/common';\nimport { AlternativeButtonLinkRolePropType } from '../../types/props/alternative-button-link-role';\nimport { ButtonCallbacksPropType } from '../../types/props/button-callbacks';\nimport { ButtonTypePropType } from '../../types/props/button-type';\nimport { IconsPropType } from '../../types/props/icons';\nimport { IdPropType } from '../../types/props/id';\nimport { LabelWithExpertSlotPropType } from '../../types/props/label';\nimport { NamePropType } from '../../types/props/name';\nimport { SyncValueBySelectorPropType } from '../../types/props/sync-value-by-selector';\nimport { TooltipAlignPropType } from '../../types/props/tooltip-align';\nimport { StencilUnknown } from '../../types/unknown';\nimport { propagateFocus } from '../../utils/reuse';\nimport { Props } from './types';\nimport { AccessKeyPropType } from '../../types/props/access-key';\n\n@Component({\n\ttag: 'kol-button-link',\n\tstyleUrls: {\n\t\tdefault: './style.css',\n\t},\n\tshadow: true,\n})\nexport class KolButtonLink implements Props {\n\t@Element() private readonly host?: HTMLKolButtonLinkElement;\n\tprivate ref?: HTMLKolButtonWcElement;\n\n\tprivate readonly catchRef = (ref?: HTMLKolButtonWcElement) => {\n\t\tthis.ref = ref;\n\t\tpropagateFocus(this.host, this.ref);\n\t};\n\n\tpublic render(): JSX.Element {\n\t\treturn (\n\t\t\t<Host>\n\t\t\t\t<kol-button-wc\n\t\t\t\t\tref={this.catchRef}\n\t\t\t\t\t_accessKey={this._accessKey}\n\t\t\t\t\t_ariaControls={this._ariaControls}\n\t\t\t\t\t_ariaExpanded={this._ariaExpanded}\n\t\t\t\t\t_ariaSelected={this._ariaSelected}\n\t\t\t\t\t_disabled={this._disabled}\n\t\t\t\t\t_icons={this._icons}\n\t\t\t\t\t_hideLabel={this._hideLabel}\n\t\t\t\t\t_id={this._id}\n\t\t\t\t\t_label={this._label}\n\t\t\t\t\t_name={this._name}\n\t\t\t\t\t_on={this._on}\n\t\t\t\t\t_role=\"link\"\n\t\t\t\t\t_syncValueBySelector={this._syncValueBySelector}\n\t\t\t\t\t_tabIndex={this._tabIndex}\n\t\t\t\t\t_tooltipAlign={this._tooltipAlign}\n\t\t\t\t\t_type={this._type}\n\t\t\t\t\t_value={this._value}\n\t\t\t\t>\n\t\t\t\t\t<slot name=\"expert\" slot=\"expert\"></slot>\n\t\t\t\t</kol-button-wc>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\t/**\n\t * Defines the elements access key.\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 whether the interactive element of the component expanded something. (https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-expanded)\n\t * @TODO: Change type back to `AriaExpandedPropType` after Stencil#4663 has been resolved.\n\t */\n\t@Prop() public _ariaExpanded?: boolean;\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 * @TODO: Change type back to `AriaSelectedPropType` after Stencil#4663 has been resolved.\n\t */\n\t@Prop() public _ariaSelected?: boolean;\n\n\t/**\n\t * Makes the element not focusable and ignore all events.\n\t * @TODO: Change type back to `DisabledPropType` after Stencil#4663 has been resolved.\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 */\n\t@Prop() public _id?: IdPropType;\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 the technical name of an input field.\n\t */\n\t@Prop() public _name?: NamePropType;\n\n\t/**\n\t * Gibt die EventCallback-Funktionen für die Button-Events an.\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 * 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?: Stringified<StencilUnknown>;\n}\n"],"mappings":";;;qGAAA,MAAMA,EAAkB,imH,MCwBXC,EAAa,M,yBAIRC,KAAAC,SAAYC,IAC5BF,KAAKE,IAAMA,EACXC,EAAeH,KAAKI,KAAMJ,KAAKE,IAAI,E,gIA0DC,M,gBAOC,M,4MA8CgB,M,WAKV,S,sBAjHrC,MAAAG,GACN,OACCC,EAACC,EAAI,KACJD,EAAA,iBACCJ,IAAKF,KAAKC,SACVO,WAAYR,KAAKQ,WACjBC,cAAeT,KAAKS,cACpBC,cAAeV,KAAKU,cACpBC,cAAeX,KAAKW,cACpBC,UAAWZ,KAAKY,UAChBC,OAAQb,KAAKa,OACbC,WAAYd,KAAKc,WACjBC,IAAKf,KAAKe,IACVC,OAAQhB,KAAKgB,OACbC,MAAOjB,KAAKiB,MACZC,IAAKlB,KAAKkB,IACVC,MAAM,OACNC,qBAAsBpB,KAAKoB,qBAC3BC,UAAWrB,KAAKqB,UAChBC,cAAetB,KAAKsB,cACpBC,MAAOvB,KAAKuB,MACZC,OAAQxB,KAAKwB,QAEblB,EAAA,QAAMmB,KAAK,SAASC,KAAK,Y"}
1
+ {"version":3,"names":["defaultStyleCss","KolButtonLink","this","catchRef","ref","propagateFocus","host","render","h","Host","_accessKey","_ariaControls","_ariaExpanded","_ariaSelected","_disabled","_icons","_hideLabel","_id","_label","_name","_on","_role","_syncValueBySelector","_tabIndex","_tooltipAlign","_type","_value","name","slot"],"sources":["src/components/button-link/style.css?tag=kol-button-link&mode=default&encapsulation=shadow","src/components/button-link/component.tsx"],"sourcesContent":["@import url(../link.css);\n","import { Component, Element, h, Host, JSX, Prop } from '@stencil/core';\n\nimport { Stringified } from '../../types/common';\nimport { AlternativeButtonLinkRolePropType } from '../../types/props/alternative-button-link-role';\nimport { ButtonCallbacksPropType } from '../../types/props/button-callbacks';\nimport { ButtonTypePropType } from '../../types/props/button-type';\nimport { IconsPropType } from '../../types/props/icons';\nimport { IdPropType } from '../../types/props/id';\nimport { LabelWithExpertSlotPropType } from '../../types/props/label';\nimport { NamePropType } from '../../types/props/name';\nimport { SyncValueBySelectorPropType } from '../../types/props/sync-value-by-selector';\nimport { TooltipAlignPropType } from '../../types/props/tooltip-align';\nimport { StencilUnknown } from '../../types/unknown';\nimport { propagateFocus } from '../../utils/reuse';\nimport { Props } from './types';\nimport { AccessKeyPropType } from '../../types/props/access-key';\n\n@Component({\n\ttag: 'kol-button-link',\n\tstyleUrls: {\n\t\tdefault: './style.css',\n\t},\n\tshadow: true,\n})\nexport class KolButtonLink implements Props {\n\t@Element() private readonly host?: HTMLKolButtonLinkElement;\n\n\tprivate readonly catchRef = (ref?: HTMLKolButtonWcElement) => {\n\t\tpropagateFocus(this.host, ref);\n\t};\n\n\tpublic render(): JSX.Element {\n\t\treturn (\n\t\t\t<Host>\n\t\t\t\t<kol-button-wc\n\t\t\t\t\tref={this.catchRef}\n\t\t\t\t\t_accessKey={this._accessKey}\n\t\t\t\t\t_ariaControls={this._ariaControls}\n\t\t\t\t\t_ariaExpanded={this._ariaExpanded}\n\t\t\t\t\t_ariaSelected={this._ariaSelected}\n\t\t\t\t\t_disabled={this._disabled}\n\t\t\t\t\t_icons={this._icons}\n\t\t\t\t\t_hideLabel={this._hideLabel}\n\t\t\t\t\t_id={this._id}\n\t\t\t\t\t_label={this._label}\n\t\t\t\t\t_name={this._name}\n\t\t\t\t\t_on={this._on}\n\t\t\t\t\t_role=\"link\"\n\t\t\t\t\t_syncValueBySelector={this._syncValueBySelector}\n\t\t\t\t\t_tabIndex={this._tabIndex}\n\t\t\t\t\t_tooltipAlign={this._tooltipAlign}\n\t\t\t\t\t_type={this._type}\n\t\t\t\t\t_value={this._value}\n\t\t\t\t>\n\t\t\t\t\t<slot name=\"expert\" slot=\"expert\"></slot>\n\t\t\t\t</kol-button-wc>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\t/**\n\t * Defines the elements access key.\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 whether the interactive element of the component expanded something. (https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-expanded)\n\t * @TODO: Change type back to `AriaExpandedPropType` after Stencil#4663 has been resolved.\n\t */\n\t@Prop() public _ariaExpanded?: boolean;\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 * @TODO: Change type back to `AriaSelectedPropType` after Stencil#4663 has been resolved.\n\t */\n\t@Prop() public _ariaSelected?: boolean;\n\n\t/**\n\t * Makes the element not focusable and ignore all events.\n\t * @TODO: Change type back to `DisabledPropType` after Stencil#4663 has been resolved.\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 */\n\t@Prop() public _id?: IdPropType;\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 the technical name of an input field.\n\t */\n\t@Prop() public _name?: NamePropType;\n\n\t/**\n\t * Gibt die EventCallback-Funktionen für die Button-Events an.\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 * 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?: Stringified<StencilUnknown>;\n}\n"],"mappings":";;;qGAAA,MAAMA,EAAkB,imH,MCwBXC,EAAa,M,yBAGRC,KAAAC,SAAYC,IAC5BC,EAAeH,KAAKI,KAAMF,EAAI,E,gIA0DM,M,gBAOC,M,4MA8CgB,M,WAKV,S,sBAjHrC,MAAAG,GACN,OACCC,EAACC,EAAI,KACJD,EAAA,iBACCJ,IAAKF,KAAKC,SACVO,WAAYR,KAAKQ,WACjBC,cAAeT,KAAKS,cACpBC,cAAeV,KAAKU,cACpBC,cAAeX,KAAKW,cACpBC,UAAWZ,KAAKY,UAChBC,OAAQb,KAAKa,OACbC,WAAYd,KAAKc,WACjBC,IAAKf,KAAKe,IACVC,OAAQhB,KAAKgB,OACbC,MAAOjB,KAAKiB,MACZC,IAAKlB,KAAKkB,IACVC,MAAM,OACNC,qBAAsBpB,KAAKoB,qBAC3BC,UAAWrB,KAAKqB,UAChBC,cAAetB,KAAKsB,cACpBC,MAAOvB,KAAKuB,MACZC,OAAQxB,KAAKwB,QAEblB,EAAA,QAAMmB,KAAK,SAASC,KAAK,Y"}
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{h as t,H as i,r as e,g as n}from"./index-9c30809b.js";import{v as s}from"./alternative-button-link-role-8db83e93.js";import{d as a,a as o,w as l,i as h,j as d,f as r,s as c}from"./prop.validators-3d53ddab.js";import{v as p}from"./custom-class-6ba43df0.js";import{v as f}from"./hide-label-3381f0cc.js";import{v as u}from"./icons-062ba29d.js";import{a as m,v}from"./label-5c173d60.js";import{v as b}from"./tooltip-align-c09e55cd.js";import{e as y}from"./a11y.tipps-06cd7c77.js";import{s as g,t as x}from"./events-2bb1065b.js";import{a as _,s as w,p as k}from"./reuse-b3566e4c.js";import{v as j}from"./tab-index-d2d0d9db.js";import{p as A,a as S}from"./controller-7e5c82c1.js";import{A as T}from"./associated.controller-1124284d.js";import{v as z}from"./access-key-d58c03d6.js";import{c as C,b as K,o as L,f as I,s as V,a as $}from"./floating-ui.dom.esm-e435ab9f.js";import{a as B}from"./alignment-de1c6559.js";import{b as O,n as E}from"./dev.utils-075f4e7b.js";const D=(t,e)=>{a(t,"_ariaControls",e)},H=(t,e)=>{o(t,"_ariaExpanded",e)},W=(t,e)=>{l(t,"_on",(t=>"object"==typeof t&&null!==t),new Set(["ButtonCallbacksPropType {Events.onClick, Events.onMouseDown}"]),e)},q=["button","reset","submit"],M=(t,e)=>{l(t,"_type",(t=>"string"==typeof t&&q.includes(t)),new Set([`KoliBriButtonType {${q.join(", ")}`]),e)},N=["primary","secondary","normal","tertiary","danger","ghost","custom"],R=(t,e)=>{l(t,"_variant",(t=>"string"==typeof t&&N.includes(t)),new Set([`KoliBriButtonVariant {${N.join(", ")}`]),e,{defaultValue:"normal"})},P=(t,e)=>{o(t,"_disabled",e)},F=(t,e)=>{o(t,"_ariaSelected",e)},G=class{render(){const e=w(this.state._label);return t(i,null,t("button",Object.assign({ref:this.catchRef,accessKey:this.state._accessKey||void 0,"aria-controls":this.state._ariaControls,"aria-expanded":h(this.state._ariaExpanded),"aria-label":this.state._hideLabel&&"string"==typeof this.state._label?this.state._label:void 0,"aria-selected":d(this.state._ariaSelected),class:{button:!0,[this.state._variant]:"custom"!==this.state._variant,[this.state._customClass]:"custom"===this.state._variant&&"string"==typeof this.state._customClass&&this.state._customClass.length>0,"icon-only":!0===this.state._hideLabel,"hide-label":!0===this.state._hideLabel},disabled:this.state._disabled,id:this.state._id,name:this.state._name},this.state._on,{onClick:this.onClick,role:this.state._role,tabIndex:this.state._tabIndex,type:this.state._type}),t("kol-span-wc",{class:"button-inner",_accessKey:this.state._accessKey,_icons:this.state._icons,_hideLabel:this.state._hideLabel,_label:e?"":this.state._label},t("slot",{name:"expert",slot:"expert"}))),t("kol-tooltip-wc",{"aria-hidden":"true",hidden:e||!this.state._hideLabel,_accessKey:this._accessKey,_align:this.state._tooltipAlign,_label:"string"==typeof this.state._label?this.state._label:""}))}constructor(t){e(this,t),this.catchRef=t=>{this.ref=t,_(this.host,this.ref)},this.onClick=t=>{var e,i;"submit"===this.state._type?A({form:this.host,ref:this.ref}):"reset"===this.state._type?S({form:this.host,ref:this.ref}):(g(t),x("click",this.host,this.state._value),this.controller.setFormAssociatedValue(this.state._value),"function"==typeof(null===(e=this.state._on)||void 0===e?void 0:e.onClick)&&(r(t,this.ref),null===(i=this.state._on)||void 0===i||i.onClick(t,this.state._value)))},this._accessKey=void 0,this._ariaControls=void 0,this._ariaExpanded=void 0,this._ariaSelected=void 0,this._customClass=void 0,this._disabled=!1,this._hideLabel=!1,this._icons=void 0,this._id=void 0,this._label=void 0,this._name=void 0,this._on=void 0,this._role=void 0,this._syncValueBySelector=void 0,this._tabIndex=void 0,this._tooltipAlign="top",this._type="button",this._value=void 0,this._variant="normal",this.state={_icons:{},_label:"",_on:{},_type:"button",_variant:"normal"},this.controller=new T(this,"button",this.host)}validateAccessKey(t){z(this,t)}validateAriaControls(t){D(this,t)}validateAriaExpanded(t){H(this,t)}validateAriaSelected(t){F(this,t)}validateCustomClass(t){p(this,t)}validateDisabled(t){P(this,t),!0===t&&y()}validateHideLabel(t){f(this,t)}validateIcons(t){u(this,t)}validateId(t){a(this,"_id",t)}validateLabel(t){m(this,t)}validateName(t){this.controller.validateName(t)}validateOn(t){W(this,t)}validateRole(t){s(this,t)}validateSyncValueBySelector(t){this.controller.validateSyncValueBySelector(t)}validateTabIndex(t){j(this,t)}validateTooltipAlign(t){b(this,t)}validateType(t){M(this,t)}validateValue(t){c(this,"_value",t),this.controller.setFormAssociatedValue(this.state._value)}validateVariant(t){R(this,t)}componentWillLoad(){this.validateAccessKey(this._accessKey),this.validateAriaControls(this._ariaControls),this.validateAriaExpanded(this._ariaExpanded),this.validateAriaSelected(this._ariaSelected),this.validateCustomClass(this._customClass),this.validateDisabled(this._disabled),this.validateHideLabel(this._hideLabel),this.validateIcons(this._icons),this.validateId(this._id),this.validateLabel(this._label),this.validateName(this._name),this.validateOn(this._on),this.validateRole(this._role),this.validateSyncValueBySelector(this._syncValueBySelector),this.validateTabIndex(this._tabIndex),this.validateTooltipAlign(this._tooltipAlign),this.validateType(this._type),this.validateValue(this._value),this.validateVariant(this._variant)}get host(){return n(this)}static get watchers(){return{_accessKey:["validateAccessKey"],_ariaControls:["validateAriaControls"],_ariaExpanded:["validateAriaExpanded"],_ariaSelected:["validateAriaSelected"],_customClass:["validateCustomClass"],_disabled:["validateDisabled"],_hideLabel:["validateHideLabel"],_icons:["validateIcons"],_id:["validateId"],_label:["validateLabel"],_name:["validateName"],_on:["validateOn"],_role:["validateRole"],_syncValueBySelector:["validateSyncValueBySelector"],_tabIndex:["validateTabIndex"],_tooltipAlign:["validateTooltipAlign"],_type:["validateType"],_value:["validateValue"],_variant:["validateVariant"]}}},J=(t,e)=>{a(t,"_id",e)},Q=new Set;function U(t){Q.forEach((t=>{t.style.setProperty("z-index","999")})),Q.add(t),t.style.setProperty("z-index","1000")}function X(t){if(Q.delete(t),Q.size>0){const t=Array.from(Q).pop();t&&t.style.setProperty("z-index","1000")}}const Y="@layer kol-global {\n\t/*\n\t * This file contains all rules for accessibility.\n\t */\n\t:host {\n\t\t/*\n\t\t * Minimum size of interactive elements.\n\t\t */\n\t\t--a11y-min-size: 44px;\n\t\tfont-size: inherit;\n\t}\n\n\t* {\n\t\t/*\n\t\t * Verdana is an accessible font that can be used without requiring additional loading time.\n\t\t */\n\t\tfont-family: Verdana;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\thyphens: auto;\n\t\t/*\n\t\t * Letter spacing is required for all texts.\n\t\t */\n\t\tletter-spacing: inherit;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\tword-break: break-word;\n\t\t/*\n\t\t * Word spacing is required for all texts.\n\t\t */\n\t\tword-spacing: inherit;\n\t}\n\n\t/*\n\t * All interactive elements should have a minimum size of 44px.\n\t */\n\t/* input:not([type='checkbox'], [type='radio'], [type='range']), */\n\t/* option, */\n\t/* select, */\n\t/* textarea, */\n\t[role='button'],\n\tbutton:not([role='link']),\n\tkol-input .input {\n\t\tmin-height: var(--a11y-min-size);\n\t\tmin-width: var(--a11y-min-size);\n\t}\n\n\t/*\n\t * Some interactive elements should not inherit the font-family and font-size.\n\t */\n\ta,\n\tbutton,\n\th1,\n\th2,\n\th3,\n\th4,\n\th5,\n\th6,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\t/*\n\t\t * All elements should inherit the font family from his parent element.\n\t\t */\n\t\tfont-family: inherit;\n\t\t/*\n\t\t * All elements should inherit the font size from his parent element.\n\t\t */\n\t\tfont-size: inherit;\n\t}\n}\n\n@layer kol-global {\n\t/*\n\t * Dieses CSS stellt sicher, dass der Standard-Style\n\t * von A und Button resettet werden.\n\t */\n\t:is(a, button) {\n\t\tbackground-color: transparent;\n\t\tborder: none;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\twidth: 100%; /* 100% needed for custom width from outside */\n\t}\n}\n\n@layer kol-global {\n\t:host {\n\t\t/*\n\t\t * The max-width is needed to prevent the table from overflowing the\n\t\t * parent node, if the table is wider than the parent node.\n\t\t */\n\t\tmax-width: 100%;\n\t}\n\n\t* {\n\t\t/*\n\t\t * We prefer to box-sizing: border-box for all elements.\n\t\t */\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n\tkol-span-wc {\n\t\tdisplay: grid;\n\t\tplace-items: center;\n\t}\n\n\t/* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n\tkol-span-wc > span {\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\ta,\n\tbutton {\n\t\tcursor: pointer;\n\t}\n\n\t/* font-family is NOT inherited all HTML elements. */\n\tbutton,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\tfont-family: inherit;\n\t}\n\n\t/* This is the text label. */\n\t.icon-only > kol-span-wc > span > span {\n\t\tdisplay: none;\n\t}\n}\n\n@layer kol-component {\n\tkol-tooltip-wc .tooltip-floating {\n\t\tanimation-duration: 0.5s;\n\t\tanimation-iteration-count: 1;\n\t\tanimation-name: fadeInOpacity;\n\t\tanimation-timing-function: ease-in;\n\t\tbox-sizing: border-box;\n\t\tdisplay: none;\n\t\tposition: absolute;\n\t\tvisibility: hidden;\n\t\t/* Avoid layout interference - see https://floating-ui.com/docs/computePosition */\n\t\ttop: 0;\n\t\tleft: 0;\n\t\tmax-width: 90vw;\n\t\tmax-height: 90vh;\n\t}\n\n\t/* Shared between content and arrow */\n\tkol-tooltip-wc .tooltip-area {\n\t\tbackground-color: #fff;\n\t\tcolor: #000;\n\t}\n\n\tkol-tooltip-wc .tooltip-arrow {\n\t\theight: 10px;\n\t\tposition: absolute;\n\t\ttransform: rotate(45deg);\n\t\twidth: 10px;\n\t\tz-index: 999;\n\t}\n\n\tkol-tooltip-wc .tooltip-content {\n\t\tposition: relative;\n\t\tz-index: 1000;\n\t}\n\n\t@keyframes fadeInOpacity {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n}\n",Z=class{constructor(t){e(this,t),this.alignTooltip=()=>{var t;if("test"!==k&&this.previousSibling&&this.tooltipElement){const e=this.previousSibling,i=this.tooltipElement,s=this.arrowElement,n=[L(null!==(t=null==s?void 0:s.offsetHeight)&&void 0!==t?t:10),I(),V()];s&&n.push($({element:s})),C(e,i,{placement:this.state._align,middleware:n}).then((({x:t,y:e,middlewareData:n,placement:a})=>{var o,l;Object.assign(i.style,{left:`${t}px`,top:`${e}px`,visibility:"visible"}),s&&((null===(o=n.arrow)||void 0===o?void 0:o.x)?Object.assign(s.style,{left:`${n.arrow.x}px`,top:"bottom"===a?-s.offsetHeight/2+"px":"",bottom:"top"===a?-s.offsetHeight/2+"px":""}):(null===(l=n.arrow)||void 0===l?void 0:l.y)&&Object.assign(s.style,{left:"right"===a?-s.offsetWidth/2+"px":"",right:"left"===a?-s.offsetWidth/2+"px":"",top:`${n.arrow.y}px`}))}))}},this.showTooltip=()=>{if(this.previousSibling&&this.tooltipElement){U(this.tooltipElement),this.tooltipElement.style.setProperty("display","block"),O().body.addEventListener("keyup",this.hideTooltipByEscape);const t=this.previousSibling,e=this.tooltipElement;this.cleanupAutoPositioning=K(t,e,this.alignTooltip)}},this.hideTooltip=()=>{this.tooltipElement&&(X(this.tooltipElement),this.tooltipElement.style.setProperty("display","none"),this.tooltipElement.style.setProperty("visibility","hidden"),this.cleanupAutoPositioning&&(this.cleanupAutoPositioning(),this.cleanupAutoPositioning=void 0))},this.hideTooltipByEscape=t=>{"Escape"===t.key&&(O().body.removeEventListener("keyup",this.hideTooltipByEscape),this.hideTooltip())},this.addListeners=t=>{t.addEventListener("mouseover",this.incrementOverFocusCount),t.addEventListener("focus",this.incrementOverFocusCount),t.addEventListener("focusin",this.incrementOverFocusCount),t.addEventListener("mouseout",this.decrementOverFocusCount),t.addEventListener("blur",this.decrementOverFocusCount),t.addEventListener("focusout",this.decrementOverFocusCount)},this.removeListeners=t=>{t.removeEventListener("mouseover",this.incrementOverFocusCount),t.removeEventListener("focus",this.incrementOverFocusCount),t.removeEventListener("focusin",this.incrementOverFocusCount),t.removeEventListener("mouseout",this.decrementOverFocusCount),t.removeEventListener("blur",this.decrementOverFocusCount),t.addEventListener("focusout",this.decrementOverFocusCount)},this.resyncListeners=(t,e,i=!1)=>{t&&this.removeListeners(t),e&&(i&&(this.previousSibling=e),this.addListeners(e))},this.catchTooltipElement=t=>{this.tooltipElement=t},this.catchArrowElement=t=>{this.arrowElement=t},this.overFocusCount=0,this.incrementOverFocusCount=()=>{this.overFocusCount++,this.showOrHideTooltip()},this.decrementOverFocusCount=()=>{this.overFocusCount--,this.showOrHideTooltip()},this.showOrHideTooltip=()=>{clearTimeout(this.overFocusTimeout),this.overFocusTimeout=setTimeout((()=>{clearTimeout(this.overFocusTimeout),this.overFocusCount>0?this.showTooltip():this.hideTooltip()}),250)},this._accessKey=void 0,this._align="top",this._id=void 0,this._label=void 0,this.state={_align:"top",_id:E(),_label:"…"}}render(){return t(i,null,""!==this.state._label&&t("div",{class:"tooltip-floating",ref:this.catchTooltipElement},t("div",{class:"tooltip-area tooltip-arrow",ref:this.catchArrowElement}),t("kol-span-wc",{class:"tooltip-area tooltip-content",id:this.state._id,_accessKey:this._accessKey,_label:this.state._label})))}validateAccessKey(t){z(this,t)}validateAlign(t){B(this,t)}validateId(t){J(this,t)}validateLabel(t){v(this,t)}componentWillLoad(){this.validateAccessKey(this._accessKey),this.validateAlign(this._align),this.validateId(this._id),this.validateLabel(this._label)}handleEventListeners(){var t;this.resyncListeners(this.previousSibling,null===(t=this.host)||void 0===t?void 0:t.previousElementSibling,!0),this.resyncListeners(this.tooltipElement,this.tooltipElement)}connectedCallback(){var t;this.previousSibling=null===(t=this.host)||void 0===t?void 0:t.previousElementSibling,this.handleEventListeners()}componentDidRender(){this.handleEventListeners()}disconnectedCallback(){this.previousSibling&&(this.removeListeners(this.previousSibling),this.previousSibling=void 0),this.tooltipElement&&this.removeListeners(this.tooltipElement),this.cleanupAutoPositioning&&this.cleanupAutoPositioning()}get host(){return n(this)}static get watchers(){return{_accessKey:["validateAccessKey"],_align:["validateAlign"],_id:["validateId"],_label:["validateLabel"]}}};Z.style=Y;export{G as kol_button_wc,Z as kol_tooltip_wc};
4
+ import{h as t,H as i,r as e,g as n}from"./index-9c30809b.js";import{v as s}from"./alternative-button-link-role-6e40ea00.js";import{d as a,a as o,w as l,i as h,j as r,f as d,s as c}from"./prop.validators-b0d023a4.js";import{v as f}from"./custom-class-4f50e79f.js";import{v as p}from"./hide-label-29f1b0eb.js";import{v as u}from"./icons-7806a223.js";import{a as m,v}from"./label-2cb169c2.js";import{v as b}from"./tooltip-align-f2f68cbf.js";import{e as y}from"./a11y.tipps-ce35f0ba.js";import{s as g,t as x}from"./events-2bb1065b.js";import{a as _,s as w,p as k}from"./reuse-b3566e4c.js";import{v as j}from"./tab-index-9201352c.js";import{p as A,a as S}from"./controller-5fe68410.js";import{A as T}from"./associated.controller-6fc585ca.js";import{v as z}from"./access-key-8240737c.js";import{c as C,b as K,o as L,f as I,s as V,a as $}from"./floating-ui.dom.esm-e435ab9f.js";import{a as B}from"./alignment-e4b01638.js";import{b as O,n as E}from"./dev.utils-34544843.js";const D=(t,e)=>{a(t,"_ariaControls",e)},H=(t,e)=>{o(t,"_ariaExpanded",e)},W=(t,e)=>{l(t,"_on",(t=>"object"==typeof t&&null!==t),new Set(["ButtonCallbacksPropType {Events.onClick, Events.onMouseDown}"]),e)},q=["button","reset","submit"],M=(t,e)=>{l(t,"_type",(t=>"string"==typeof t&&q.includes(t)),new Set([`KoliBriButtonType {${q.join(", ")}`]),e)},N=["primary","secondary","normal","tertiary","danger","ghost","custom"],R=(t,e)=>{l(t,"_variant",(t=>"string"==typeof t&&N.includes(t)),new Set([`KoliBriButtonVariant {${N.join(", ")}`]),e,{defaultValue:"normal"})},P=(t,e)=>{o(t,"_disabled",e)},F=(t,e)=>{o(t,"_ariaSelected",e)},G=class{render(){const e=w(this.state._label);return t(i,null,t("button",Object.assign({ref:this.catchRef,accessKey:this.state._accessKey||void 0,"aria-controls":this.state._ariaControls,"aria-expanded":h(this.state._ariaExpanded),"aria-label":this.state._hideLabel&&"string"==typeof this.state._label?this.state._label:void 0,"aria-selected":r(this.state._ariaSelected),class:{button:!0,[this.state._variant]:"custom"!==this.state._variant,[this.state._customClass]:"custom"===this.state._variant&&"string"==typeof this.state._customClass&&this.state._customClass.length>0,"icon-only":!0===this.state._hideLabel,"hide-label":!0===this.state._hideLabel},disabled:this.state._disabled,id:this.state._id,name:this.state._name},this.state._on,{onClick:this.onClick,role:this.state._role,tabIndex:this.state._tabIndex,type:this.state._type}),t("kol-span-wc",{class:"button-inner",_accessKey:this.state._accessKey,_icons:this.state._icons,_hideLabel:this.state._hideLabel,_label:e?"":this.state._label},t("slot",{name:"expert",slot:"expert"}))),t("kol-tooltip-wc",{"aria-hidden":"true",hidden:e||!this.state._hideLabel,_accessKey:this._accessKey,_align:this.state._tooltipAlign,_label:"string"==typeof this.state._label?this.state._label:""}))}constructor(t){e(this,t),this.catchRef=t=>{this.ref=t,_(this.host,this.ref)},this.onClick=t=>{var e,i;"submit"===this.state._type?A({form:this.host,ref:this.ref}):"reset"===this.state._type?S({form:this.host,ref:this.ref}):(g(t),x("click",this.host,this.state._value),this.controller.setFormAssociatedValue(this.state._value),"function"==typeof(null===(e=this.state._on)||void 0===e?void 0:e.onClick)&&(d(t,this.ref),null===(i=this.state._on)||void 0===i||i.onClick(t,this.state._value)))},this._accessKey=void 0,this._ariaControls=void 0,this._ariaExpanded=void 0,this._ariaSelected=void 0,this._customClass=void 0,this._disabled=!1,this._hideLabel=!1,this._icons=void 0,this._id=void 0,this._label=void 0,this._name=void 0,this._on=void 0,this._role=void 0,this._syncValueBySelector=void 0,this._tabIndex=void 0,this._tooltipAlign="top",this._type="button",this._value=void 0,this._variant="normal",this.state={_icons:{},_label:"",_on:{},_type:"button",_variant:"normal"},this.controller=new T(this,"button",this.host)}validateAccessKey(t){z(this,t)}validateAriaControls(t){D(this,t)}validateAriaExpanded(t){H(this,t)}validateAriaSelected(t){F(this,t)}validateCustomClass(t){f(this,t)}validateDisabled(t){P(this,t),!0===t&&y()}validateHideLabel(t){p(this,t)}validateIcons(t){u(this,t)}validateId(t){a(this,"_id",t)}validateLabel(t){m(this,t)}validateName(t){this.controller.validateName(t)}validateOn(t){W(this,t)}validateRole(t){s(this,t)}validateSyncValueBySelector(t){this.controller.validateSyncValueBySelector(t)}validateTabIndex(t){j(this,t)}validateTooltipAlign(t){b(this,t)}validateType(t){M(this,t)}validateValue(t){c(this,"_value",t),this.controller.setFormAssociatedValue(this.state._value)}validateVariant(t){R(this,t)}componentWillLoad(){this.validateAccessKey(this._accessKey),this.validateAriaControls(this._ariaControls),this.validateAriaExpanded(this._ariaExpanded),this.validateAriaSelected(this._ariaSelected),this.validateCustomClass(this._customClass),this.validateDisabled(this._disabled),this.validateHideLabel(this._hideLabel),this.validateIcons(this._icons),this.validateId(this._id),this.validateLabel(this._label),this.validateName(this._name),this.validateOn(this._on),this.validateRole(this._role),this.validateSyncValueBySelector(this._syncValueBySelector),this.validateTabIndex(this._tabIndex),this.validateTooltipAlign(this._tooltipAlign),this.validateType(this._type),this.validateValue(this._value),this.validateVariant(this._variant)}get host(){return n(this)}static get watchers(){return{_accessKey:["validateAccessKey"],_ariaControls:["validateAriaControls"],_ariaExpanded:["validateAriaExpanded"],_ariaSelected:["validateAriaSelected"],_customClass:["validateCustomClass"],_disabled:["validateDisabled"],_hideLabel:["validateHideLabel"],_icons:["validateIcons"],_id:["validateId"],_label:["validateLabel"],_name:["validateName"],_on:["validateOn"],_role:["validateRole"],_syncValueBySelector:["validateSyncValueBySelector"],_tabIndex:["validateTabIndex"],_tooltipAlign:["validateTooltipAlign"],_type:["validateType"],_value:["validateValue"],_variant:["validateVariant"]}}},J=(t,e)=>{a(t,"_id",e)},Q=new Set;function U(t){Q.forEach((t=>{t.style.setProperty("z-index","999")})),Q.add(t),t.style.setProperty("z-index","1000")}function X(t){if(Q.delete(t),Q.size>0){const t=Array.from(Q).pop();t&&t.style.setProperty("z-index","1000")}}const Y="@layer kol-global {\n\t/*\n\t * This file contains all rules for accessibility.\n\t */\n\t:host {\n\t\t/*\n\t\t * Minimum size of interactive elements.\n\t\t */\n\t\t--a11y-min-size: 44px;\n\t\tfont-size: inherit;\n\t}\n\n\t* {\n\t\t/*\n\t\t * Verdana is an accessible font that can be used without requiring additional loading time.\n\t\t */\n\t\tfont-family: Verdana;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\thyphens: auto;\n\t\t/*\n\t\t * Letter spacing is required for all texts.\n\t\t */\n\t\tletter-spacing: inherit;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\tword-break: break-word;\n\t\t/*\n\t\t * Word spacing is required for all texts.\n\t\t */\n\t\tword-spacing: inherit;\n\t}\n\n\t/*\n\t * All interactive elements should have a minimum size of 44px.\n\t */\n\t/* input:not([type='checkbox'], [type='radio'], [type='range']), */\n\t/* option, */\n\t/* select, */\n\t/* textarea, */\n\t[role='button'],\n\tbutton:not([role='link']),\n\tkol-input .input {\n\t\tmin-height: var(--a11y-min-size);\n\t\tmin-width: var(--a11y-min-size);\n\t}\n\n\t/*\n\t * Some interactive elements should not inherit the font-family and font-size.\n\t */\n\ta,\n\tbutton,\n\th1,\n\th2,\n\th3,\n\th4,\n\th5,\n\th6,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\t/*\n\t\t * All elements should inherit the font family from his parent element.\n\t\t */\n\t\tfont-family: inherit;\n\t\t/*\n\t\t * All elements should inherit the font size from his parent element.\n\t\t */\n\t\tfont-size: inherit;\n\t}\n}\n\n@layer kol-global {\n\t/*\n\t * Dieses CSS stellt sicher, dass der Standard-Style\n\t * von A und Button resettet werden.\n\t */\n\t:is(a, button) {\n\t\tbackground-color: transparent;\n\t\tborder: none;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\twidth: 100%; /* 100% needed for custom width from outside */\n\t}\n}\n\n@layer kol-global {\n\t:host {\n\t\t/*\n\t\t * The max-width is needed to prevent the table from overflowing the\n\t\t * parent node, if the table is wider than the parent node.\n\t\t */\n\t\tmax-width: 100%;\n\t}\n\n\t* {\n\t\t/*\n\t\t * We prefer to box-sizing: border-box for all elements.\n\t\t */\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n\tkol-span-wc {\n\t\tdisplay: grid;\n\t\tplace-items: center;\n\t}\n\n\t/* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n\tkol-span-wc > span {\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\ta,\n\tbutton {\n\t\tcursor: pointer;\n\t}\n\n\t/* font-family is NOT inherited all HTML elements. */\n\tbutton,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\tfont-family: inherit;\n\t}\n\n\t/* This is the text label. */\n\t.icon-only > kol-span-wc > span > span {\n\t\tdisplay: none;\n\t}\n}\n\n@layer kol-component {\n\tkol-tooltip-wc .tooltip-floating {\n\t\tanimation-duration: 0.5s;\n\t\tanimation-iteration-count: 1;\n\t\tanimation-name: fadeInOpacity;\n\t\tanimation-timing-function: ease-in;\n\t\tbox-sizing: border-box;\n\t\tdisplay: none;\n\t\tposition: absolute;\n\t\tvisibility: hidden;\n\t\t/* Avoid layout interference - see https://floating-ui.com/docs/computePosition */\n\t\ttop: 0;\n\t\tleft: 0;\n\t\tmax-width: 90vw;\n\t\tmax-height: 90vh;\n\t}\n\n\t/* Shared between content and arrow */\n\tkol-tooltip-wc .tooltip-area {\n\t\tbackground-color: #fff;\n\t\tcolor: #000;\n\t}\n\n\tkol-tooltip-wc .tooltip-arrow {\n\t\theight: 10px;\n\t\tposition: absolute;\n\t\ttransform: rotate(45deg);\n\t\twidth: 10px;\n\t\tz-index: 999;\n\t}\n\n\tkol-tooltip-wc .tooltip-content {\n\t\tposition: relative;\n\t\tz-index: 1000;\n\t}\n\n\t@keyframes fadeInOpacity {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n}\n",Z=class{constructor(t){e(this,t),this.alignTooltip=()=>{var t;if("test"!==k&&this.previousSibling&&this.tooltipElement){const e=this.previousSibling,i=this.tooltipElement,s=this.arrowElement,n=[L(null!==(t=null==s?void 0:s.offsetHeight)&&void 0!==t?t:10),I(),V()];s&&n.push($({element:s})),C(e,i,{placement:this.state._align,middleware:n}).then((({x:t,y:e,middlewareData:n,placement:a})=>{var o,l;Object.assign(i.style,{left:`${t}px`,top:`${e}px`,visibility:"visible"}),s&&((null===(o=n.arrow)||void 0===o?void 0:o.x)?Object.assign(s.style,{left:`${n.arrow.x}px`,top:"bottom"===a?-s.offsetHeight/2+"px":"",bottom:"top"===a?-s.offsetHeight/2+"px":""}):(null===(l=n.arrow)||void 0===l?void 0:l.y)&&Object.assign(s.style,{left:"right"===a?-s.offsetWidth/2+"px":"",right:"left"===a?-s.offsetWidth/2+"px":"",top:`${n.arrow.y}px`}))}))}},this.showTooltip=()=>{if(this.previousSibling&&this.tooltipElement){U(this.tooltipElement),this.tooltipElement.style.setProperty("display","block"),O().body.addEventListener("keyup",this.hideTooltipByEscape);const t=this.previousSibling,e=this.tooltipElement;this.cleanupAutoPositioning=K(t,e,this.alignTooltip)}},this.hideTooltip=()=>{this.tooltipElement&&(X(this.tooltipElement),this.tooltipElement.style.setProperty("display","none"),this.tooltipElement.style.setProperty("visibility","hidden"),this.cleanupAutoPositioning&&(this.cleanupAutoPositioning(),this.cleanupAutoPositioning=void 0))},this.hideTooltipByEscape=t=>{"Escape"===t.key&&(O().body.removeEventListener("keyup",this.hideTooltipByEscape),this.hideTooltip())},this.addListeners=t=>{t.addEventListener("mouseover",this.incrementOverFocusCount),t.addEventListener("focus",this.incrementOverFocusCount),t.addEventListener("focusin",this.incrementOverFocusCount),t.addEventListener("mouseout",this.decrementOverFocusCount),t.addEventListener("blur",this.decrementOverFocusCount),t.addEventListener("focusout",this.decrementOverFocusCount)},this.removeListeners=t=>{t.removeEventListener("mouseover",this.incrementOverFocusCount),t.removeEventListener("focus",this.incrementOverFocusCount),t.removeEventListener("focusin",this.incrementOverFocusCount),t.removeEventListener("mouseout",this.decrementOverFocusCount),t.removeEventListener("blur",this.decrementOverFocusCount),t.addEventListener("focusout",this.decrementOverFocusCount)},this.resyncListeners=(t,e,i=!1)=>{t&&this.removeListeners(t),e&&(i&&(this.previousSibling=e),this.addListeners(e))},this.catchTooltipElement=t=>{this.tooltipElement=t},this.catchArrowElement=t=>{this.arrowElement=t},this.overFocusCount=0,this.incrementOverFocusCount=()=>{this.overFocusCount++,this.showOrHideTooltip()},this.decrementOverFocusCount=()=>{this.overFocusCount--,this.showOrHideTooltip()},this.showOrHideTooltip=()=>{clearTimeout(this.overFocusTimeout),this.overFocusTimeout=setTimeout((()=>{clearTimeout(this.overFocusTimeout),this.overFocusCount>0?this.showTooltip():this.hideTooltip()}),250)},this._accessKey=void 0,this._align="top",this._id=void 0,this._label=void 0,this.state={_align:"top",_id:E(),_label:"…"}}render(){return t(i,null,""!==this.state._label&&t("div",{class:"tooltip-floating",ref:this.catchTooltipElement},t("div",{class:"tooltip-area tooltip-arrow",ref:this.catchArrowElement}),t("kol-span-wc",{class:"tooltip-area tooltip-content",id:this.state._id,_accessKey:this._accessKey,_label:this.state._label})))}validateAccessKey(t){z(this,t)}validateAlign(t){B(this,t)}validateId(t){J(this,t)}validateLabel(t){v(this,t)}componentWillLoad(){this.validateAccessKey(this._accessKey),this.validateAlign(this._align),this.validateId(this._id),this.validateLabel(this._label)}handleEventListeners(){var t;this.resyncListeners(this.previousSibling,null===(t=this.host)||void 0===t?void 0:t.previousElementSibling,!0),this.resyncListeners(this.tooltipElement,this.tooltipElement)}connectedCallback(){var t;this.previousSibling=null===(t=this.host)||void 0===t?void 0:t.previousElementSibling,this.handleEventListeners()}componentDidRender(){this.handleEventListeners()}disconnectedCallback(){this.previousSibling&&(this.removeListeners(this.previousSibling),this.previousSibling=void 0),this.tooltipElement&&this.removeListeners(this.tooltipElement),this.cleanupAutoPositioning&&this.cleanupAutoPositioning()}get host(){return n(this)}static get watchers(){return{_accessKey:["validateAccessKey"],_align:["validateAlign"],_id:["validateId"],_label:["validateLabel"]}}};Z.style=Y;export{G as kol_button_wc,Z as kol_tooltip_wc};
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{r as t,h as n,H as e,g as i}from"./index-9c30809b.js";import{a as s}from"./reuse-b3566e4c.js";const o="@layer kol-global {\n\t/*\n\t * This file contains all rules for accessibility.\n\t */\n\t:host {\n\t\t/*\n\t\t * Minimum size of interactive elements.\n\t\t */\n\t\t--a11y-min-size: 44px;\n\t\tfont-size: inherit;\n\t}\n\n\t* {\n\t\t/*\n\t\t * Verdana is an accessible font that can be used without requiring additional loading time.\n\t\t */\n\t\tfont-family: Verdana;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\thyphens: auto;\n\t\t/*\n\t\t * Letter spacing is required for all texts.\n\t\t */\n\t\tletter-spacing: inherit;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\tword-break: break-word;\n\t\t/*\n\t\t * Word spacing is required for all texts.\n\t\t */\n\t\tword-spacing: inherit;\n\t}\n\n\t/*\n\t * All interactive elements should have a minimum size of 44px.\n\t */\n\t/* input:not([type='checkbox'], [type='radio'], [type='range']), */\n\t/* option, */\n\t/* select, */\n\t/* textarea, */\n\t[role='button'],\n\tbutton:not([role='link']),\n\tkol-input .input {\n\t\tmin-height: var(--a11y-min-size);\n\t\tmin-width: var(--a11y-min-size);\n\t}\n\n\t/*\n\t * Some interactive elements should not inherit the font-family and font-size.\n\t */\n\ta,\n\tbutton,\n\th1,\n\th2,\n\th3,\n\th4,\n\th5,\n\th6,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\t/*\n\t\t * All elements should inherit the font family from his parent element.\n\t\t */\n\t\tfont-family: inherit;\n\t\t/*\n\t\t * All elements should inherit the font size from his parent element.\n\t\t */\n\t\tfont-size: inherit;\n\t}\n}\n\n@layer kol-global {\n\t/*\n\t * Dieses CSS stellt sicher, dass der Standard-Style\n\t * von A und Button resettet werden.\n\t */\n\t:is(a, button) {\n\t\tbackground-color: transparent;\n\t\tborder: none;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\twidth: 100%; /* 100% needed for custom width from outside */\n\t}\n}\n\n@layer kol-global {\n\t:host {\n\t\t/*\n\t\t * The max-width is needed to prevent the table from overflowing the\n\t\t * parent node, if the table is wider than the parent node.\n\t\t */\n\t\tmax-width: 100%;\n\t}\n\n\t* {\n\t\t/*\n\t\t * We prefer to box-sizing: border-box for all elements.\n\t\t */\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n\tkol-span-wc {\n\t\tdisplay: grid;\n\t\tplace-items: center;\n\t}\n\n\t/* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n\tkol-span-wc > span {\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\ta,\n\tbutton {\n\t\tcursor: pointer;\n\t}\n\n\t/* font-family is NOT inherited all HTML elements. */\n\tbutton,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\tfont-family: inherit;\n\t}\n\n\t/* This is the text label. */\n\t.icon-only > kol-span-wc > span > span {\n\t\tdisplay: none;\n\t}\n}\n\n@layer kol-component {\n\t:host {\n\t\tdisplay: inline-block;\n\t}\n\t:is(a, button) {\n\t\tdisplay: inline-flex;\n\t\tplace-items: center;\n\t\ttext-align: center;\n\t\ttext-decoration-line: none;\n\n\t\t&::before {\n\t\t\t/* Render zero-width character as first element to set the baseline correctly. */\n\t\t\tcontent: '\\200B';\n\t\t}\n\t}\n\t/* TODO: Why we need this? */\n\t:is(a, button) > kol-span-wc {\n\t\tmargin: auto;\n\t\twidth: 100%;\n\t}\n\t:is(button):disabled {\n\t\tcursor: not-allowed;\n\t\topacity: 0.5;\n\t}\n}\n\n",a=class{constructor(n){t(this,n),this.catchRef=t=>{this.ref=t,s(this.host,this.ref)},this._accessKey=void 0,this._ariaControls=void 0,this._ariaExpanded=void 0,this._ariaSelected=void 0,this._customClass=void 0,this._disabled=!1,this._hideLabel=!1,this._icons=void 0,this._id=void 0,this._label=void 0,this._name=void 0,this._on=void 0,this._role=void 0,this._syncValueBySelector=void 0,this._tabIndex=void 0,this._tooltipAlign="top",this._type="button",this._value=void 0,this._variant="normal"}render(){return n(e,null,n("kol-button-wc",{ref:this.catchRef,class:{button:!0,[this._variant]:"custom"!==this._variant,[this._customClass]:"custom"===this._variant&&"string"==typeof this._customClass&&this._customClass.length>0},_accessKey:this._accessKey,_ariaControls:this._ariaControls,_ariaExpanded:this._ariaExpanded,_ariaSelected:this._ariaSelected,_customClass:this._customClass,_disabled:this._disabled,_hideLabel:this._hideLabel,_icons:this._icons,_id:this._id,_label:this._label,_name:this._name,_on:this._on,_role:this._role,_syncValueBySelector:this._syncValueBySelector,_tabIndex:this._tabIndex,_tooltipAlign:this._tooltipAlign,_type:this._type,_value:this._value,_variant:this._variant},n("slot",{name:"expert",slot:"expert"})))}get host(){return i(this)}};a.style={default:o};export{a as kol_button};
4
+ import{r as t,h as n,H as e,g as i}from"./index-9c30809b.js";import{a as s}from"./reuse-b3566e4c.js";const o="@layer kol-global {\n\t/*\n\t * This file contains all rules for accessibility.\n\t */\n\t:host {\n\t\t/*\n\t\t * Minimum size of interactive elements.\n\t\t */\n\t\t--a11y-min-size: 44px;\n\t\tfont-size: inherit;\n\t}\n\n\t* {\n\t\t/*\n\t\t * Verdana is an accessible font that can be used without requiring additional loading time.\n\t\t */\n\t\tfont-family: Verdana;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\thyphens: auto;\n\t\t/*\n\t\t * Letter spacing is required for all texts.\n\t\t */\n\t\tletter-spacing: inherit;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\tword-break: break-word;\n\t\t/*\n\t\t * Word spacing is required for all texts.\n\t\t */\n\t\tword-spacing: inherit;\n\t}\n\n\t/*\n\t * All interactive elements should have a minimum size of 44px.\n\t */\n\t/* input:not([type='checkbox'], [type='radio'], [type='range']), */\n\t/* option, */\n\t/* select, */\n\t/* textarea, */\n\t[role='button'],\n\tbutton:not([role='link']),\n\tkol-input .input {\n\t\tmin-height: var(--a11y-min-size);\n\t\tmin-width: var(--a11y-min-size);\n\t}\n\n\t/*\n\t * Some interactive elements should not inherit the font-family and font-size.\n\t */\n\ta,\n\tbutton,\n\th1,\n\th2,\n\th3,\n\th4,\n\th5,\n\th6,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\t/*\n\t\t * All elements should inherit the font family from his parent element.\n\t\t */\n\t\tfont-family: inherit;\n\t\t/*\n\t\t * All elements should inherit the font size from his parent element.\n\t\t */\n\t\tfont-size: inherit;\n\t}\n}\n\n@layer kol-global {\n\t/*\n\t * Dieses CSS stellt sicher, dass der Standard-Style\n\t * von A und Button resettet werden.\n\t */\n\t:is(a, button) {\n\t\tbackground-color: transparent;\n\t\tborder: none;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\twidth: 100%; /* 100% needed for custom width from outside */\n\t}\n}\n\n@layer kol-global {\n\t:host {\n\t\t/*\n\t\t * The max-width is needed to prevent the table from overflowing the\n\t\t * parent node, if the table is wider than the parent node.\n\t\t */\n\t\tmax-width: 100%;\n\t}\n\n\t* {\n\t\t/*\n\t\t * We prefer to box-sizing: border-box for all elements.\n\t\t */\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n\tkol-span-wc {\n\t\tdisplay: grid;\n\t\tplace-items: center;\n\t}\n\n\t/* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n\tkol-span-wc > span {\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\ta,\n\tbutton {\n\t\tcursor: pointer;\n\t}\n\n\t/* font-family is NOT inherited all HTML elements. */\n\tbutton,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\tfont-family: inherit;\n\t}\n\n\t/* This is the text label. */\n\t.icon-only > kol-span-wc > span > span {\n\t\tdisplay: none;\n\t}\n}\n\n@layer kol-component {\n\t:host {\n\t\tdisplay: inline-block;\n\t}\n\t:is(a, button) {\n\t\tdisplay: inline-flex;\n\t\tplace-items: center;\n\t\ttext-align: center;\n\t\ttext-decoration-line: none;\n\n\t\t&::before {\n\t\t\t/* Render zero-width character as first element to set the baseline correctly. */\n\t\t\tcontent: '\\200B';\n\t\t}\n\t}\n\t/* TODO: Why we need this? */\n\t:is(a, button) > kol-span-wc {\n\t\tmargin: auto;\n\t\twidth: 100%;\n\t}\n\t:is(button):disabled {\n\t\tcursor: not-allowed;\n\t\topacity: 0.5;\n\t}\n}\n\n",a=class{constructor(n){t(this,n),this.catchRef=t=>{s(this.host,t)},this._accessKey=void 0,this._ariaControls=void 0,this._ariaExpanded=void 0,this._ariaSelected=void 0,this._customClass=void 0,this._disabled=!1,this._hideLabel=!1,this._icons=void 0,this._id=void 0,this._label=void 0,this._name=void 0,this._on=void 0,this._role=void 0,this._syncValueBySelector=void 0,this._tabIndex=void 0,this._tooltipAlign="top",this._type="button",this._value=void 0,this._variant="normal"}render(){return n(e,null,n("kol-button-wc",{ref:this.catchRef,class:{button:!0,[this._variant]:"custom"!==this._variant,[this._customClass]:"custom"===this._variant&&"string"==typeof this._customClass&&this._customClass.length>0},_accessKey:this._accessKey,_ariaControls:this._ariaControls,_ariaExpanded:this._ariaExpanded,_ariaSelected:this._ariaSelected,_customClass:this._customClass,_disabled:this._disabled,_hideLabel:this._hideLabel,_icons:this._icons,_id:this._id,_label:this._label,_name:this._name,_on:this._on,_role:this._role,_syncValueBySelector:this._syncValueBySelector,_tabIndex:this._tabIndex,_tooltipAlign:this._tooltipAlign,_type:this._type,_value:this._value,_variant:this._variant},n("slot",{name:"expert",slot:"expert"})))}get host(){return i(this)}};a.style={default:o};export{a as kol_button};
@@ -1 +1 @@
1
- {"version":3,"names":["defaultStyleCss","KolButton","this","catchRef","ref","propagateFocus","host","render","h","Host","class","button","_variant","_customClass","length","_accessKey","_ariaControls","_ariaExpanded","_ariaSelected","_disabled","_hideLabel","_icons","_id","_label","_name","_on","_role","_syncValueBySelector","_tabIndex","_tooltipAlign","_type","_value","name","slot"],"sources":["src/components/button/style.css?tag=kol-button&mode=default&encapsulation=shadow","src/components/button/shadow.tsx"],"sourcesContent":["@import url(../button.css);\n","import { Component, Element, h, Host, JSX, Prop } from '@stencil/core';\n\nimport { Stringified } from '../../types/common';\nimport { AlternativeButtonLinkRolePropType } from '../../types/props/alternative-button-link-role';\nimport { ButtonCallbacksPropType } from '../../types/props/button-callbacks';\nimport { ButtonTypePropType } from '../../types/props/button-type';\nimport { ButtonVariantPropType } from '../../types/props/button-variant';\nimport { CustomClassPropType } from '../../types/props/custom-class';\nimport { IconsPropType } from '../../types/props/icons';\nimport { LabelWithExpertSlotPropType } from '../../types/props/label';\nimport { SyncValueBySelectorPropType } from '../../types/props/sync-value-by-selector';\nimport { TooltipAlignPropType } from '../../types/props/tooltip-align';\nimport { StencilUnknown } from '../../types/unknown';\nimport { propagateFocus } from '../../utils/reuse';\nimport { Props } from './types';\nimport { AccessKeyPropType } from '../../types/props/access-key';\n\n@Component({\n\ttag: 'kol-button',\n\tstyleUrls: {\n\t\tdefault: './style.css',\n\t},\n\tshadow: true,\n})\nexport class KolButton implements Props {\n\t@Element() private readonly host?: HTMLKolButtonElement;\n\tprivate ref?: HTMLKolButtonWcElement;\n\n\tprivate readonly catchRef = (ref?: HTMLKolButtonWcElement) => {\n\t\tthis.ref = ref;\n\t\tpropagateFocus(this.host, this.ref);\n\t};\n\n\tpublic render(): JSX.Element {\n\t\treturn (\n\t\t\t<Host>\n\t\t\t\t<kol-button-wc\n\t\t\t\t\tref={this.catchRef}\n\t\t\t\t\tclass={{\n\t\t\t\t\t\tbutton: true,\n\t\t\t\t\t\t[this._variant as string]: this._variant !== 'custom',\n\t\t\t\t\t\t[this._customClass as string]: this._variant === 'custom' && typeof this._customClass === 'string' && this._customClass.length > 0,\n\t\t\t\t\t}}\n\t\t\t\t\t_accessKey={this._accessKey}\n\t\t\t\t\t_ariaControls={this._ariaControls}\n\t\t\t\t\t_ariaExpanded={this._ariaExpanded}\n\t\t\t\t\t_ariaSelected={this._ariaSelected}\n\t\t\t\t\t_customClass={this._customClass}\n\t\t\t\t\t_disabled={this._disabled}\n\t\t\t\t\t_hideLabel={this._hideLabel}\n\t\t\t\t\t_icons={this._icons}\n\t\t\t\t\t_id={this._id}\n\t\t\t\t\t_label={this._label}\n\t\t\t\t\t_name={this._name}\n\t\t\t\t\t_on={this._on}\n\t\t\t\t\t_role={this._role}\n\t\t\t\t\t_syncValueBySelector={this._syncValueBySelector}\n\t\t\t\t\t_tabIndex={this._tabIndex}\n\t\t\t\t\t_tooltipAlign={this._tooltipAlign}\n\t\t\t\t\t_type={this._type}\n\t\t\t\t\t_value={this._value}\n\t\t\t\t\t_variant={this._variant}\n\t\t\t\t>\n\t\t\t\t\t<slot name=\"expert\" slot=\"expert\"></slot>\n\t\t\t\t</kol-button-wc>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\t/**\n\t * Defines the elements access key.\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 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 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 _variant=\"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 */\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 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 * 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?: Stringified<StencilUnknown>;\n\n\t/**\n\t * Defines which variant should be used for presentation.\n\t */\n\t@Prop() public _variant?: ButtonVariantPropType = 'normal';\n}\n"],"mappings":";;;qGAAA,MAAMA,EAAkB,w7G,MCwBXC,EAAS,M,yBAIJC,KAAAC,SAAYC,IAC5BF,KAAKE,IAAMA,EACXC,EAAeH,KAAKI,KAAMJ,KAAKE,IAAI,E,4JAmEC,M,gBAOC,M,4MA8CgB,M,WAKV,S,oCAUM,Q,CApI3C,MAAAG,GACN,OACCC,EAACC,EAAI,KACJD,EAAA,iBACCJ,IAAKF,KAAKC,SACVO,MAAO,CACNC,OAAQ,KACR,CAACT,KAAKU,UAAqBV,KAAKU,WAAa,SAC7C,CAACV,KAAKW,cAAyBX,KAAKU,WAAa,iBAAmBV,KAAKW,eAAiB,UAAYX,KAAKW,aAAaC,OAAS,GAElIC,WAAYb,KAAKa,WACjBC,cAAed,KAAKc,cACpBC,cAAef,KAAKe,cACpBC,cAAehB,KAAKgB,cACpBL,aAAcX,KAAKW,aACnBM,UAAWjB,KAAKiB,UAChBC,WAAYlB,KAAKkB,WACjBC,OAAQnB,KAAKmB,OACbC,IAAKpB,KAAKoB,IACVC,OAAQrB,KAAKqB,OACbC,MAAOtB,KAAKsB,MACZC,IAAKvB,KAAKuB,IACVC,MAAOxB,KAAKwB,MACZC,qBAAsBzB,KAAKyB,qBAC3BC,UAAW1B,KAAK0B,UAChBC,cAAe3B,KAAK2B,cACpBC,MAAO5B,KAAK4B,MACZC,OAAQ7B,KAAK6B,OACbnB,SAAUV,KAAKU,UAEfJ,EAAA,QAAMwB,KAAK,SAASC,KAAK,Y"}
1
+ {"version":3,"names":["defaultStyleCss","KolButton","this","catchRef","ref","propagateFocus","host","render","h","Host","class","button","_variant","_customClass","length","_accessKey","_ariaControls","_ariaExpanded","_ariaSelected","_disabled","_hideLabel","_icons","_id","_label","_name","_on","_role","_syncValueBySelector","_tabIndex","_tooltipAlign","_type","_value","name","slot"],"sources":["src/components/button/style.css?tag=kol-button&mode=default&encapsulation=shadow","src/components/button/shadow.tsx"],"sourcesContent":["@import url(../button.css);\n","import { Component, Element, h, Host, JSX, Prop } from '@stencil/core';\n\nimport { Stringified } from '../../types/common';\nimport { AlternativeButtonLinkRolePropType } from '../../types/props/alternative-button-link-role';\nimport { ButtonCallbacksPropType } from '../../types/props/button-callbacks';\nimport { ButtonTypePropType } from '../../types/props/button-type';\nimport { ButtonVariantPropType } from '../../types/props/button-variant';\nimport { CustomClassPropType } from '../../types/props/custom-class';\nimport { IconsPropType } from '../../types/props/icons';\nimport { LabelWithExpertSlotPropType } from '../../types/props/label';\nimport { SyncValueBySelectorPropType } from '../../types/props/sync-value-by-selector';\nimport { TooltipAlignPropType } from '../../types/props/tooltip-align';\nimport { StencilUnknown } from '../../types/unknown';\nimport { propagateFocus } from '../../utils/reuse';\nimport { Props } from './types';\nimport { AccessKeyPropType } from '../../types/props/access-key';\n\n@Component({\n\ttag: 'kol-button',\n\tstyleUrls: {\n\t\tdefault: './style.css',\n\t},\n\tshadow: true,\n})\nexport class KolButton implements Props {\n\t@Element() private readonly host?: HTMLKolButtonElement;\n\n\tprivate readonly catchRef = (ref?: HTMLKolButtonWcElement) => {\n\t\tpropagateFocus(this.host, ref);\n\t};\n\n\tpublic render(): JSX.Element {\n\t\treturn (\n\t\t\t<Host>\n\t\t\t\t<kol-button-wc\n\t\t\t\t\tref={this.catchRef}\n\t\t\t\t\tclass={{\n\t\t\t\t\t\tbutton: true,\n\t\t\t\t\t\t[this._variant as string]: this._variant !== 'custom',\n\t\t\t\t\t\t[this._customClass as string]: this._variant === 'custom' && typeof this._customClass === 'string' && this._customClass.length > 0,\n\t\t\t\t\t}}\n\t\t\t\t\t_accessKey={this._accessKey}\n\t\t\t\t\t_ariaControls={this._ariaControls}\n\t\t\t\t\t_ariaExpanded={this._ariaExpanded}\n\t\t\t\t\t_ariaSelected={this._ariaSelected}\n\t\t\t\t\t_customClass={this._customClass}\n\t\t\t\t\t_disabled={this._disabled}\n\t\t\t\t\t_hideLabel={this._hideLabel}\n\t\t\t\t\t_icons={this._icons}\n\t\t\t\t\t_id={this._id}\n\t\t\t\t\t_label={this._label}\n\t\t\t\t\t_name={this._name}\n\t\t\t\t\t_on={this._on}\n\t\t\t\t\t_role={this._role}\n\t\t\t\t\t_syncValueBySelector={this._syncValueBySelector}\n\t\t\t\t\t_tabIndex={this._tabIndex}\n\t\t\t\t\t_tooltipAlign={this._tooltipAlign}\n\t\t\t\t\t_type={this._type}\n\t\t\t\t\t_value={this._value}\n\t\t\t\t\t_variant={this._variant}\n\t\t\t\t>\n\t\t\t\t\t<slot name=\"expert\" slot=\"expert\"></slot>\n\t\t\t\t</kol-button-wc>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\t/**\n\t * Defines the elements access key.\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 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 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 _variant=\"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 */\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 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 * 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?: Stringified<StencilUnknown>;\n\n\t/**\n\t * Defines which variant should be used for presentation.\n\t */\n\t@Prop() public _variant?: ButtonVariantPropType = 'normal';\n}\n"],"mappings":";;;qGAAA,MAAMA,EAAkB,w7G,MCwBXC,EAAS,M,yBAGJC,KAAAC,SAAYC,IAC5BC,EAAeH,KAAKI,KAAMF,EAAI,E,4JAmEM,M,gBAOC,M,4MA8CgB,M,WAKV,S,oCAUM,Q,CApI3C,MAAAG,GACN,OACCC,EAACC,EAAI,KACJD,EAAA,iBACCJ,IAAKF,KAAKC,SACVO,MAAO,CACNC,OAAQ,KACR,CAACT,KAAKU,UAAqBV,KAAKU,WAAa,SAC7C,CAACV,KAAKW,cAAyBX,KAAKU,WAAa,iBAAmBV,KAAKW,eAAiB,UAAYX,KAAKW,aAAaC,OAAS,GAElIC,WAAYb,KAAKa,WACjBC,cAAed,KAAKc,cACpBC,cAAef,KAAKe,cACpBC,cAAehB,KAAKgB,cACpBL,aAAcX,KAAKW,aACnBM,UAAWjB,KAAKiB,UAChBC,WAAYlB,KAAKkB,WACjBC,OAAQnB,KAAKmB,OACbC,IAAKpB,KAAKoB,IACVC,OAAQrB,KAAKqB,OACbC,MAAOtB,KAAKsB,MACZC,IAAKvB,KAAKuB,IACVC,MAAOxB,KAAKwB,MACZC,qBAAsBzB,KAAKyB,qBAC3BC,UAAW1B,KAAK0B,UAChBC,cAAe3B,KAAK2B,cACpBC,MAAO5B,KAAK4B,MACZC,OAAQ7B,KAAK6B,OACbnB,SAAUV,KAAKU,UAEfJ,EAAA,QAAMwB,KAAK,SAASC,KAAK,Y"}
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{r as t,h as n,H as e}from"./index-9c30809b.js";import{a as i}from"./i18n-8ec5b30e.js";import{v as o}from"./has-closer-d28fec0f.js";import{v as s}from"./label-5c173d60.js";import{s as l}from"./prop.validators-3d53ddab.js";import{w as a}from"./validation-c57e7be5.js";import"./index-b79e4012.js";import"./dev.utils-075f4e7b.js";import"./reuse-b3566e4c.js";import"./a11y.tipps-06cd7c77.js";const r="@layer kol-global {\n\t/*\n\t * This file contains all rules for accessibility.\n\t */\n\t:host {\n\t\t/*\n\t\t * Minimum size of interactive elements.\n\t\t */\n\t\t--a11y-min-size: 44px;\n\t\tfont-size: inherit;\n\t}\n\n\t* {\n\t\t/*\n\t\t * Verdana is an accessible font that can be used without requiring additional loading time.\n\t\t */\n\t\tfont-family: Verdana;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\thyphens: auto;\n\t\t/*\n\t\t * Letter spacing is required for all texts.\n\t\t */\n\t\tletter-spacing: inherit;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\tword-break: break-word;\n\t\t/*\n\t\t * Word spacing is required for all texts.\n\t\t */\n\t\tword-spacing: inherit;\n\t}\n\n\t/*\n\t * All interactive elements should have a minimum size of 44px.\n\t */\n\t/* input:not([type='checkbox'], [type='radio'], [type='range']), */\n\t/* option, */\n\t/* select, */\n\t/* textarea, */\n\t[role='button'],\n\tbutton:not([role='link']),\n\tkol-input .input {\n\t\tmin-height: var(--a11y-min-size);\n\t\tmin-width: var(--a11y-min-size);\n\t}\n\n\t/*\n\t * Some interactive elements should not inherit the font-family and font-size.\n\t */\n\ta,\n\tbutton,\n\th1,\n\th2,\n\th3,\n\th4,\n\th5,\n\th6,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\t/*\n\t\t * All elements should inherit the font family from his parent element.\n\t\t */\n\t\tfont-family: inherit;\n\t\t/*\n\t\t * All elements should inherit the font size from his parent element.\n\t\t */\n\t\tfont-size: inherit;\n\t}\n}\n\n@layer kol-global {\n\t/*\n\t * Dieses CSS stellt sicher, dass der Standard-Style\n\t * von A und Button resettet werden.\n\t */\n\t:is(a, button) {\n\t\tbackground-color: transparent;\n\t\tborder: none;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\twidth: 100%; /* 100% needed for custom width from outside */\n\t}\n}\n\n@layer kol-global {\n\t:host {\n\t\t/*\n\t\t * The max-width is needed to prevent the table from overflowing the\n\t\t * parent node, if the table is wider than the parent node.\n\t\t */\n\t\tmax-width: 100%;\n\t}\n\n\t* {\n\t\t/*\n\t\t * We prefer to box-sizing: border-box for all elements.\n\t\t */\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n\tkol-span-wc {\n\t\tdisplay: grid;\n\t\tplace-items: center;\n\t}\n\n\t/* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n\tkol-span-wc > span {\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\ta,\n\tbutton {\n\t\tcursor: pointer;\n\t}\n\n\t/* font-family is NOT inherited all HTML elements. */\n\tbutton,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\tfont-family: inherit;\n\t}\n\n\t/* This is the text label. */\n\t.icon-only > kol-span-wc > span > span {\n\t\tdisplay: none;\n\t}\n}\n\n@layer kol-component {\n\t:host > div.card {\n\t\theight: 100%;\n\t\tposition: relative;\n\t}\n\n\t.close {\n\t\tposition: absolute;\n\t\ttop: 0;\n\t\tright: 0;\n\t}\n}\n",h=class{constructor(n){t(this,n),this.close=()=>{var t;void 0!==(null===(t=this._on)||void 0===t?void 0:t.onClose)&&this._on.onClose(new Event("Close"))},this.on={onClick:this.close},this.validateOnValue=t=>"object"==typeof t&&null!==t&&"function"==typeof t.onClose,this._on=void 0,this._hasCloser=!1,this._label=void 0,this._level=1,this.state={_label:"…"}}render(){return n(e,null,n("div",{class:"card"},n("div",{class:"header"},n("kol-heading-wc",{_label:this.state._label,_level:this.state._level})),n("div",{class:"content"},n("slot",null)),this.state._hasCloser&&n("kol-button-wc",{class:"close",_hideLabel:!0,_icons:{left:{icon:"codicon codicon-close"}},_label:i("kol-close"),_on:this.on,_tooltipAlign:"left"})))}validateOn(t){this.validateOnValue(t)&&l(this,"_on",{onClose:t.onClose})}validateHasCloser(t){o(this,t)}validateLabel(t){s(this,t)}validateLevel(t){a(this,t)}componentWillLoad(){this.validateHasCloser(this._hasCloser),this.validateLabel(this._label),this.validateLevel(this._level),this.validateOn(this._on)}static get watchers(){return{_on:["validateOn"],_hasCloser:["validateHasCloser"],_label:["validateLabel"],_level:["validateLevel"]}}};h.style={default:r};export{h as kol_card};
4
+ import{r as t,h as n,H as e}from"./index-9c30809b.js";import{a as i}from"./i18n-bb569ab8.js";import{v as o}from"./has-closer-1b322deb.js";import{v as s}from"./label-2cb169c2.js";import{s as a}from"./prop.validators-b0d023a4.js";import{w as l}from"./validation-b1ee30aa.js";import"./index-7a38e9a3.js";import"./dev.utils-34544843.js";import"./reuse-b3566e4c.js";import"./a11y.tipps-ce35f0ba.js";const r="@layer kol-global {\n\t/*\n\t * This file contains all rules for accessibility.\n\t */\n\t:host {\n\t\t/*\n\t\t * Minimum size of interactive elements.\n\t\t */\n\t\t--a11y-min-size: 44px;\n\t\tfont-size: inherit;\n\t}\n\n\t* {\n\t\t/*\n\t\t * Verdana is an accessible font that can be used without requiring additional loading time.\n\t\t */\n\t\tfont-family: Verdana;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\thyphens: auto;\n\t\t/*\n\t\t * Letter spacing is required for all texts.\n\t\t */\n\t\tletter-spacing: inherit;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\tword-break: break-word;\n\t\t/*\n\t\t * Word spacing is required for all texts.\n\t\t */\n\t\tword-spacing: inherit;\n\t}\n\n\t/*\n\t * All interactive elements should have a minimum size of 44px.\n\t */\n\t/* input:not([type='checkbox'], [type='radio'], [type='range']), */\n\t/* option, */\n\t/* select, */\n\t/* textarea, */\n\t[role='button'],\n\tbutton:not([role='link']),\n\tkol-input .input {\n\t\tmin-height: var(--a11y-min-size);\n\t\tmin-width: var(--a11y-min-size);\n\t}\n\n\t/*\n\t * Some interactive elements should not inherit the font-family and font-size.\n\t */\n\ta,\n\tbutton,\n\th1,\n\th2,\n\th3,\n\th4,\n\th5,\n\th6,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\t/*\n\t\t * All elements should inherit the font family from his parent element.\n\t\t */\n\t\tfont-family: inherit;\n\t\t/*\n\t\t * All elements should inherit the font size from his parent element.\n\t\t */\n\t\tfont-size: inherit;\n\t}\n}\n\n@layer kol-global {\n\t/*\n\t * Dieses CSS stellt sicher, dass der Standard-Style\n\t * von A und Button resettet werden.\n\t */\n\t:is(a, button) {\n\t\tbackground-color: transparent;\n\t\tborder: none;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\twidth: 100%; /* 100% needed for custom width from outside */\n\t}\n}\n\n@layer kol-global {\n\t:host {\n\t\t/*\n\t\t * The max-width is needed to prevent the table from overflowing the\n\t\t * parent node, if the table is wider than the parent node.\n\t\t */\n\t\tmax-width: 100%;\n\t}\n\n\t* {\n\t\t/*\n\t\t * We prefer to box-sizing: border-box for all elements.\n\t\t */\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n\tkol-span-wc {\n\t\tdisplay: grid;\n\t\tplace-items: center;\n\t}\n\n\t/* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n\tkol-span-wc > span {\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\ta,\n\tbutton {\n\t\tcursor: pointer;\n\t}\n\n\t/* font-family is NOT inherited all HTML elements. */\n\tbutton,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\tfont-family: inherit;\n\t}\n\n\t/* This is the text label. */\n\t.icon-only > kol-span-wc > span > span {\n\t\tdisplay: none;\n\t}\n}\n\n@layer kol-component {\n\t:host > div.card {\n\t\theight: 100%;\n\t\tposition: relative;\n\t}\n\n\t.close {\n\t\tposition: absolute;\n\t\ttop: 0;\n\t\tright: 0;\n\t}\n}\n",h=class{constructor(n){t(this,n),this.close=()=>{var t;void 0!==(null===(t=this._on)||void 0===t?void 0:t.onClose)&&this._on.onClose(new Event("Close"))},this.on={onClick:this.close},this.validateOnValue=t=>"object"==typeof t&&null!==t&&"function"==typeof t.onClose,this._on=void 0,this._hasCloser=!1,this._label=void 0,this._level=1,this.state={_label:"…"}}render(){return n(e,null,n("div",{class:"card"},n("div",{class:"header"},n("kol-heading-wc",{_label:this.state._label,_level:this.state._level})),n("div",{class:"content"},n("slot",null)),this.state._hasCloser&&n("kol-button-wc",{class:"close",_hideLabel:!0,_icons:{left:{icon:"codicon codicon-close"}},_label:i("kol-close"),_on:this.on,_tooltipAlign:"left"})))}validateOn(t){this.validateOnValue(t)&&a(this,"_on",{onClose:t.onClose})}validateHasCloser(t){o(this,t)}validateLabel(t){s(this,t)}validateLevel(t){l(this,t)}componentWillLoad(){this.validateHasCloser(this._hasCloser),this.validateLabel(this._label),this.validateLevel(this._level),this.validateOn(this._on)}static get watchers(){return{_on:["validateOn"],_hasCloser:["validateHasCloser"],_label:["validateLabel"],_level:["validateLevel"]}}};h.style={default:r};export{h as kol_card};
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{r as t,h as n,H as e,g as i}from"./index-9c30809b.js";import{v as s}from"./label-5c173d60.js";import{v as o}from"./open-47384c18.js";import{t as a}from"./events-2bb1065b.js";import{s as l}from"./prop.validators-3d53ddab.js";import"./a11y.tipps-06cd7c77.js";import"./dev.utils-075f4e7b.js";import"./reuse-b3566e4c.js";class r{constructor(t,n,e){this.detailsElement=t,this.summaryElement=n,this.contentElement=e,this.isClosing=!1,this.isExpanding=!1,this.summaryElement.addEventListener("click",this.handleSummaryClick.bind(this))}handleSummaryClick(t){t.preventDefault(),this.detailsElement.style.overflow="hidden",this.isClosing||!this.detailsElement.open?this.open():(this.isExpanding||this.detailsElement.open)&&this.collapse()}open(){var t;this.detailsElement.style.height=`${null!==(t=this.detailsElement.offsetHeight)&&void 0!==t?t:0}px`,this.detailsElement.open=!0,window.requestAnimationFrame(this.expand.bind(this))}expand(){this.isExpanding=!0,this.animateDetailsHeight(this.summaryElement.offsetHeight+this.contentElement.offsetHeight,"expand")}collapse(){this.isClosing=!0,this.animateDetailsHeight(this.summaryElement.offsetHeight,"collapse")}animateDetailsHeight(t,n){const e=this.detailsElement.offsetHeight;this.animation&&this.animation.cancel(),this.animation=this.detailsElement.animate({height:[`${e}px`,`${t}px`]},{duration:matchMedia("(prefers-reduced-motion)").matches?0:250,easing:"ease-out"}),this.animation.addEventListener("finish",(()=>{this.onAnimationFinish()}),{once:!0}),this.animation.addEventListener("cancel",(()=>{"expand"===n?this.isExpanding=!1:this.isClosing=!1}),{once:!0})}onAnimationFinish(){this.detailsElement.open=this.isExpanding,this.animation=void 0,this.isClosing=!1,this.isExpanding=!1,this.detailsElement.style.removeProperty("height"),this.detailsElement.style.removeProperty("overview")}}const h="@layer kol-global {\n\t/*\n\t * This file contains all rules for accessibility.\n\t */\n\t:host {\n\t\t/*\n\t\t * Minimum size of interactive elements.\n\t\t */\n\t\t--a11y-min-size: 44px;\n\t\tfont-size: inherit;\n\t}\n\n\t* {\n\t\t/*\n\t\t * Verdana is an accessible font that can be used without requiring additional loading time.\n\t\t */\n\t\tfont-family: Verdana;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\thyphens: auto;\n\t\t/*\n\t\t * Letter spacing is required for all texts.\n\t\t */\n\t\tletter-spacing: inherit;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\tword-break: break-word;\n\t\t/*\n\t\t * Word spacing is required for all texts.\n\t\t */\n\t\tword-spacing: inherit;\n\t}\n\n\t/*\n\t * All interactive elements should have a minimum size of 44px.\n\t */\n\t/* input:not([type='checkbox'], [type='radio'], [type='range']), */\n\t/* option, */\n\t/* select, */\n\t/* textarea, */\n\t[role='button'],\n\tbutton:not([role='link']),\n\tkol-input .input {\n\t\tmin-height: var(--a11y-min-size);\n\t\tmin-width: var(--a11y-min-size);\n\t}\n\n\t/*\n\t * Some interactive elements should not inherit the font-family and font-size.\n\t */\n\ta,\n\tbutton,\n\th1,\n\th2,\n\th3,\n\th4,\n\th5,\n\th6,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\t/*\n\t\t * All elements should inherit the font family from his parent element.\n\t\t */\n\t\tfont-family: inherit;\n\t\t/*\n\t\t * All elements should inherit the font size from his parent element.\n\t\t */\n\t\tfont-size: inherit;\n\t}\n}\n\n@layer kol-global {\n\t/*\n\t * Dieses CSS stellt sicher, dass der Standard-Style\n\t * von A und Button resettet werden.\n\t */\n\t:is(a, button) {\n\t\tbackground-color: transparent;\n\t\tborder: none;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\twidth: 100%; /* 100% needed for custom width from outside */\n\t}\n}\n\n@layer kol-global {\n\t:host {\n\t\t/*\n\t\t * The max-width is needed to prevent the table from overflowing the\n\t\t * parent node, if the table is wider than the parent node.\n\t\t */\n\t\tmax-width: 100%;\n\t}\n\n\t* {\n\t\t/*\n\t\t * We prefer to box-sizing: border-box for all elements.\n\t\t */\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n\tkol-span-wc {\n\t\tdisplay: grid;\n\t\tplace-items: center;\n\t}\n\n\t/* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n\tkol-span-wc > span {\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\ta,\n\tbutton {\n\t\tcursor: pointer;\n\t}\n\n\t/* font-family is NOT inherited all HTML elements. */\n\tbutton,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\tfont-family: inherit;\n\t}\n\n\t/* This is the text label. */\n\t.icon-only > kol-span-wc > span > span {\n\t\tdisplay: none;\n\t}\n}\n\n@layer kol-component {\n\t:host {\n\t\tdisplay: block;\n\t}\n}\n\n@layer kol-component {\n\tdetails {\n\t\tdisplay: grid;\n\t}\n\n\tdetails > summary {\n\t\tcursor: pointer;\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\tdetails > summary > span {\n\t\tborder-bottom-color: grey;\n\t\tborder-bottom-style: solid;\n\t}\n\n\tdetails > summary:focus > span,\n\tdetails > summary:hover > span,\n\tdetails[open] > summary > span {\n\t\tborder-bottom-color: #000;\n\t}\n\n\tdetails > kol-indented-text {\n\t\tmargin: 0.25em 0 0 0.5em;\n\t}\n}\n.icon.is-open::part(icon) {\n\ttransform: rotate(90deg);\n}\n",d=class{constructor(n){t(this,n),this.handleToggle=t=>{clearTimeout(this.toggleTimeout),this.toggleTimeout=setTimeout((()=>{var n,e,i,s;Boolean(null===(n=this.detailsElement)||void 0===n?void 0:n.open)!==this.state._open&&(this._open=Boolean(null===(e=this.detailsElement)||void 0===e?void 0:e.open),a("toggle",this.host,this._open),"function"==typeof(null===(i=this.state._on)||void 0===i?void 0:i.onToggle)&&(null===(s=this.state._on)||void 0===s||s.onToggle(t,this._open)))}),25)},this._label=void 0,this._on=void 0,this._open=!1,this.state={_label:"…",_on:{}}}render(){return n(e,null,n("details",{ref:t=>{this.detailsElement=t},onToggle:this.handleToggle},n("summary",{ref:t=>this.summaryElement=t},n("kol-icon",{_label:"",_icons:"codicon codicon-chevron-right",class:"icon "+(this.state._open?"is-open":"")}),n("span",null,this.state._label)),n("div",{class:"content",ref:t=>this.contentElement=t},n("kol-indented-text",null,n("slot",null)))))}validateLabel(t){s(this,t)}validateOn(t){"object"==typeof t&&null!==t&&"function"==typeof t.onToggle&&l(this,"_on",t)}validateOpen(t){o(this,t)}componentWillLoad(){this.validateLabel(this._label),this.validateOn(this._on),this.validateOpen(this._open)}componentDidLoad(){if(this.detailsElement&&this.summaryElement&&this.contentElement){const t=new r(this.detailsElement,this.summaryElement,this.contentElement);this.state._open&&t.open()}}get host(){return i(this)}static get watchers(){return{_label:["validateLabel"],_on:["validateOn"],_open:["validateOpen"]}}};d.style={default:h};export{d as kol_details};
4
+ import{r as t,h as n,H as e,g as i}from"./index-9c30809b.js";import{v as s}from"./label-2cb169c2.js";import{v as o}from"./open-590f675d.js";import{t as a}from"./events-2bb1065b.js";import{s as l}from"./prop.validators-b0d023a4.js";import{a as r}from"./reuse-b3566e4c.js";import"./a11y.tipps-ce35f0ba.js";import"./dev.utils-34544843.js";class h{constructor(t,n,e){this.detailsElement=t,this.summaryElement=n,this.contentElement=e,this.isClosing=!1,this.isExpanding=!1,this.summaryElement.addEventListener("click",this.handleSummaryClick.bind(this))}handleSummaryClick(t){t.preventDefault(),this.detailsElement.style.overflow="hidden",this.isClosing||!this.detailsElement.open?this.open():(this.isExpanding||this.detailsElement.open)&&this.collapse()}open(){var t;this.detailsElement.style.height=`${null!==(t=this.detailsElement.offsetHeight)&&void 0!==t?t:0}px`,this.detailsElement.open=!0,window.requestAnimationFrame(this.expand.bind(this))}expand(){this.isExpanding=!0,this.animateDetailsHeight(this.summaryElement.offsetHeight+this.contentElement.offsetHeight,"expand")}collapse(){this.isClosing=!0,this.animateDetailsHeight(this.summaryElement.offsetHeight,"collapse")}animateDetailsHeight(t,n){const e=this.detailsElement.offsetHeight;this.animation&&this.animation.cancel(),this.animation=this.detailsElement.animate({height:[`${e}px`,`${t}px`]},{duration:matchMedia("(prefers-reduced-motion)").matches?0:250,easing:"ease-out"}),this.animation.addEventListener("finish",(()=>{this.onAnimationFinish()}),{once:!0}),this.animation.addEventListener("cancel",(()=>{"expand"===n?this.isExpanding=!1:this.isClosing=!1}),{once:!0})}onAnimationFinish(){this.detailsElement.open=this.isExpanding,this.animation=void 0,this.isClosing=!1,this.isExpanding=!1,this.detailsElement.style.removeProperty("height"),this.detailsElement.style.removeProperty("overview")}}const d="@layer kol-global {\n\t/*\n\t * This file contains all rules for accessibility.\n\t */\n\t:host {\n\t\t/*\n\t\t * Minimum size of interactive elements.\n\t\t */\n\t\t--a11y-min-size: 44px;\n\t\tfont-size: inherit;\n\t}\n\n\t* {\n\t\t/*\n\t\t * Verdana is an accessible font that can be used without requiring additional loading time.\n\t\t */\n\t\tfont-family: Verdana;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\thyphens: auto;\n\t\t/*\n\t\t * Letter spacing is required for all texts.\n\t\t */\n\t\tletter-spacing: inherit;\n\t\t/*\n\t\t * This rule enables the word dividing for all texts. That is important for high zoom levels.\n\t\t */\n\t\tword-break: break-word;\n\t\t/*\n\t\t * Word spacing is required for all texts.\n\t\t */\n\t\tword-spacing: inherit;\n\t}\n\n\t/*\n\t * All interactive elements should have a minimum size of 44px.\n\t */\n\t/* input:not([type='checkbox'], [type='radio'], [type='range']), */\n\t/* option, */\n\t/* select, */\n\t/* textarea, */\n\t[role='button'],\n\tbutton:not([role='link']),\n\tkol-input .input {\n\t\tmin-height: var(--a11y-min-size);\n\t\tmin-width: var(--a11y-min-size);\n\t}\n\n\t/*\n\t * Some interactive elements should not inherit the font-family and font-size.\n\t */\n\ta,\n\tbutton,\n\th1,\n\th2,\n\th3,\n\th4,\n\th5,\n\th6,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\t/*\n\t\t * All elements should inherit the font family from his parent element.\n\t\t */\n\t\tfont-family: inherit;\n\t\t/*\n\t\t * All elements should inherit the font size from his parent element.\n\t\t */\n\t\tfont-size: inherit;\n\t}\n}\n\n@layer kol-global {\n\t/*\n\t * Dieses CSS stellt sicher, dass der Standard-Style\n\t * von A und Button resettet werden.\n\t */\n\t:is(a, button) {\n\t\tbackground-color: transparent;\n\t\tborder: none;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t\twidth: 100%; /* 100% needed for custom width from outside */\n\t}\n}\n\n@layer kol-global {\n\t:host {\n\t\t/*\n\t\t * The max-width is needed to prevent the table from overflowing the\n\t\t * parent node, if the table is wider than the parent node.\n\t\t */\n\t\tmax-width: 100%;\n\t}\n\n\t* {\n\t\t/*\n\t\t * We prefer to box-sizing: border-box for all elements.\n\t\t */\n\t\tbox-sizing: border-box;\n\t}\n\n\t/* KolSpan is a layout component with icons in all directions and a label text in the middle. */\n\tkol-span-wc {\n\t\tdisplay: grid;\n\t\tplace-items: center;\n\t}\n\n\t/* The sub span in KolSpan is the horizontal span with icon left and right and the label text in the middle. */\n\tkol-span-wc > span {\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\ta,\n\tbutton {\n\t\tcursor: pointer;\n\t}\n\n\t/* font-family is NOT inherited all HTML elements. */\n\tbutton,\n\tinput,\n\toption,\n\tselect,\n\ttextarea {\n\t\tfont-family: inherit;\n\t}\n\n\t/* This is the text label. */\n\t.icon-only > kol-span-wc > span > span {\n\t\tdisplay: none;\n\t}\n}\n\n@layer kol-component {\n\t:host {\n\t\tdisplay: block;\n\t}\n}\n\n@layer kol-component {\n\tdetails {\n\t\tdisplay: grid;\n\t}\n\n\tdetails > summary {\n\t\tcursor: pointer;\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\tdetails > summary > span {\n\t\tborder-bottom-color: grey;\n\t\tborder-bottom-style: solid;\n\t}\n\n\tdetails > summary:focus > span,\n\tdetails > summary:hover > span,\n\tdetails[open] > summary > span {\n\t\tborder-bottom-color: #000;\n\t}\n\n\tdetails > kol-indented-text {\n\t\tmargin: 0.25em 0 0 0.5em;\n\t}\n}\n.icon.is-open::part(icon) {\n\ttransform: rotate(90deg);\n}\n",p=class{constructor(n){t(this,n),this.catchRef=t=>{this.summaryElement=t,r(this.host,this.summaryElement)},this.handleToggle=t=>{clearTimeout(this.toggleTimeout),this.toggleTimeout=setTimeout((()=>{var n,e,i,s;Boolean(null===(n=this.detailsElement)||void 0===n?void 0:n.open)!==this.state._open&&(this._open=Boolean(null===(e=this.detailsElement)||void 0===e?void 0:e.open),a("toggle",this.host,this._open),"function"==typeof(null===(i=this.state._on)||void 0===i?void 0:i.onToggle)&&(null===(s=this.state._on)||void 0===s||s.onToggle(t,this._open)))}),25)},this._label=void 0,this._on=void 0,this._open=!1,this.state={_label:"…",_on:{}}}render(){return n(e,null,n("details",{ref:t=>{this.detailsElement=t},onToggle:this.handleToggle},n("summary",{ref:this.catchRef},n("kol-icon",{_label:"",_icons:"codicon codicon-chevron-right",class:"icon "+(this.state._open?"is-open":"")}),n("span",null,this.state._label)),n("div",{"aria-hidden":!1===this.state._open?"true":void 0,class:"content",ref:t=>this.contentElement=t},n("kol-indented-text",null,n("slot",null)))))}validateLabel(t){s(this,t)}validateOn(t){"object"==typeof t&&null!==t&&"function"==typeof t.onToggle&&l(this,"_on",t)}validateOpen(t){o(this,t)}componentWillLoad(){this.validateLabel(this._label),this.validateOn(this._on),this.validateOpen(this._open)}componentDidLoad(){if(this.detailsElement&&this.summaryElement&&this.contentElement){const t=new h(this.detailsElement,this.summaryElement,this.contentElement);this.state._open&&t.open()}}get host(){return i(this)}static get watchers(){return{_label:["validateLabel"],_on:["validateOn"],_open:["validateOpen"]}}};p.style={default:d};export{p as kol_details};
@@ -1 +1 @@
1
- {"version":3,"names":["DetailsAnimationController","constructor","detailsElement","summaryElement","contentElement","this","isClosing","isExpanding","addEventListener","handleSummaryClick","bind","event","preventDefault","style","overflow","open","collapse","height","_a","offsetHeight","window","requestAnimationFrame","expand","animateDetailsHeight","endHeight","direction","startHeight","animation","cancel","animate","duration","matchMedia","matches","easing","onAnimationFinish","once","undefined","removeProperty","defaultStyleCss","KolDetails","handleToggle","clearTimeout","toggleTimeout","setTimeout","Boolean","state","_open","_b","tryToDispatchKoliBriEvent","host","_c","_on","onToggle","_d","_label","render","h","Host","ref","el","element","_icons","class","validateLabel","value","validateOn","on","setState","validateOpen","componentWillLoad","componentDidLoad","animationController"],"sources":["src/components/details/DetailsAnimationController.ts","src/components/details/style.css?tag=kol-details&mode=default&encapsulation=shadow","src/components/details/component.tsx"],"sourcesContent":["/* Heavily inspired by: https://codepen.io/Mamboleoo/pen/QWEpLqm */\n\nexport default class DetailsAnimationController {\n\tprivate animation?: Animation;\n\tprivate isClosing = false;\n\tprivate isExpanding = false;\n\n\tconstructor(private detailsElement: HTMLDetailsElement, private summaryElement: HTMLElement, private contentElement: HTMLElement) {\n\t\tthis.summaryElement.addEventListener('click', this.handleSummaryClick.bind(this));\n\t}\n\n\tprivate handleSummaryClick(event: MouseEvent) {\n\t\tevent.preventDefault();\n\n\t\tthis.detailsElement.style.overflow = 'hidden';\n\t\tif (this.isClosing || !this.detailsElement.open) {\n\t\t\tthis.open();\n\t\t} else if (this.isExpanding || this.detailsElement.open) {\n\t\t\tthis.collapse();\n\t\t}\n\t}\n\n\tpublic open() {\n\t\t/**\n\t\t * The Jest test framework does not support the `offsetHeight` property on the `details` element.\n\t\t * This is a workaround to make the tests pass (?? 0).\n\t\t */\n\t\tthis.detailsElement.style.height = `${this.detailsElement.offsetHeight ?? 0}px`;\n\t\tthis.detailsElement.open = true;\n\t\twindow.requestAnimationFrame(this.expand.bind(this));\n\t}\n\n\tprivate expand() {\n\t\tthis.isExpanding = true;\n\t\tthis.animateDetailsHeight(this.summaryElement.offsetHeight + this.contentElement.offsetHeight, 'expand');\n\t}\n\n\tprivate collapse() {\n\t\tthis.isClosing = true;\n\t\tthis.animateDetailsHeight(this.summaryElement.offsetHeight, 'collapse');\n\t}\n\n\tprivate animateDetailsHeight(endHeight: number, direction: 'expand' | 'collapse') {\n\t\tconst startHeight = this.detailsElement.offsetHeight;\n\n\t\tif (this.animation) {\n\t\t\tthis.animation.cancel();\n\t\t}\n\n\t\tthis.animation = this.detailsElement.animate(\n\t\t\t{\n\t\t\t\theight: [`${startHeight}px`, `${endHeight}px`],\n\t\t\t},\n\t\t\t{\n\t\t\t\tduration: matchMedia('(prefers-reduced-motion)').matches ? 0 : 250,\n\t\t\t\teasing: 'ease-out',\n\t\t\t}\n\t\t);\n\n\t\tthis.animation.addEventListener(\n\t\t\t'finish',\n\t\t\t() => {\n\t\t\t\tthis.onAnimationFinish();\n\t\t\t},\n\t\t\t{ once: true }\n\t\t);\n\t\tthis.animation.addEventListener(\n\t\t\t'cancel',\n\t\t\t() => {\n\t\t\t\tif (direction === 'expand') {\n\t\t\t\t\tthis.isExpanding = false;\n\t\t\t\t} else {\n\t\t\t\t\tthis.isClosing = false;\n\t\t\t\t}\n\t\t\t},\n\t\t\t{ once: true }\n\t\t);\n\t}\n\n\tprivate onAnimationFinish() {\n\t\tthis.detailsElement.open = this.isExpanding;\n\t\tthis.animation = undefined;\n\t\tthis.isClosing = false;\n\t\tthis.isExpanding = false;\n\t\tthis.detailsElement.style.removeProperty('height');\n\t\tthis.detailsElement.style.removeProperty('overview');\n\t}\n}\n","@import url(../style.css);\n@import url(../host-display-block.css);\n@layer kol-component {\n\tdetails {\n\t\tdisplay: grid;\n\t}\n\n\tdetails > summary {\n\t\tcursor: pointer;\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\tdetails > summary > span {\n\t\tborder-bottom-color: grey;\n\t\tborder-bottom-style: solid;\n\t}\n\n\tdetails > summary:focus > span,\n\tdetails > summary:hover > span,\n\tdetails[open] > summary > span {\n\t\tborder-bottom-color: #000;\n\t}\n\n\tdetails > kol-indented-text {\n\t\tmargin: 0.25em 0 0 0.5em;\n\t}\n}\n.icon.is-open::part(icon) {\n\ttransform: rotate(90deg);\n}\n","import { Component, Element, h, Host, JSX, Prop, State, Watch } from '@stencil/core';\n\nimport { LabelPropType, validateLabel } from '../../types/props/label';\nimport { validateOpen } from '../../types/props/open';\nimport { tryToDispatchKoliBriEvent } from '../../utils/events';\nimport { setState } from '../../utils/prop.validators';\nimport DetailsAnimationController from './DetailsAnimationController';\nimport { API, EventCallbacks, States } from './types';\n\n/**\n * @slot - Der Inhalt, der in der Detailbeschreibung angezeigt wird.\n */\n@Component({\n\ttag: 'kol-details',\n\tstyleUrls: {\n\t\tdefault: './style.css',\n\t},\n\tshadow: true,\n})\nexport class KolDetails implements API {\n\t@Element() private readonly host?: HTMLKolDetailsElement;\n\tprivate detailsElement?: HTMLDetailsElement;\n\tprivate summaryElement?: HTMLElement;\n\tprivate contentElement?: HTMLElement;\n\n\tpublic render(): JSX.Element {\n\t\treturn (\n\t\t\t<Host>\n\t\t\t\t<details\n\t\t\t\t\tref={(el) => {\n\t\t\t\t\t\tthis.detailsElement = el as HTMLDetailsElement;\n\t\t\t\t\t}}\n\t\t\t\t\tonToggle={this.handleToggle}\n\t\t\t\t>\n\t\t\t\t\t<summary ref={(element) => (this.summaryElement = element)}>\n\t\t\t\t\t\t<kol-icon _label=\"\" _icons=\"codicon codicon-chevron-right\" class={`icon ${this.state._open ? 'is-open' : ''}`} />\n\t\t\t\t\t\t<span>{this.state._label}</span>\n\t\t\t\t\t</summary>\n\t\t\t\t\t<div class=\"content\" ref={(element) => (this.contentElement = element)}>\n\t\t\t\t\t\t<kol-indented-text>\n\t\t\t\t\t\t\t<slot />\n\t\t\t\t\t\t</kol-indented-text>\n\t\t\t\t\t</div>\n\t\t\t\t</details>\n\t\t\t</Host>\n\t\t);\n\t}\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 * Defines the callback functions for details.\n\t */\n\t@Prop() public _on?: EventCallbacks;\n\n\t/**\n\t * If set (to true) opens/expands the element, closes if not set (or set to false).\n\t * @TODO: Change type back to `OpenPropType` after Stencil#4663 has been resolved.\n\t */\n\t@Prop({ mutable: true, reflect: true }) public _open?: boolean = false;\n\n\t@State() public state: States = {\n\t\t_label: '…', // '⚠'\n\t\t_on: {},\n\t};\n\n\t@Watch('_label')\n\tpublic validateLabel(value?: LabelPropType): void {\n\t\tvalidateLabel(this, value);\n\t}\n\n\t@Watch('_on')\n\tpublic validateOn(on?: EventCallbacks) {\n\t\tif (typeof on === 'object' && on !== null && typeof on.onToggle === 'function') {\n\t\t\tsetState<EventCallbacks>(this, '_on', on);\n\t\t}\n\t}\n\n\t@Watch('_open')\n\tpublic validateOpen(value?: boolean): void {\n\t\tvalidateOpen(this, value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tthis.validateLabel(this._label);\n\t\tthis.validateOn(this._on);\n\t\tthis.validateOpen(this._open);\n\t}\n\n\tpublic componentDidLoad() {\n\t\tif (this.detailsElement && this.summaryElement && this.contentElement) {\n\t\t\tconst animationController = new DetailsAnimationController(this.detailsElement, this.summaryElement, this.contentElement);\n\t\t\tif (this.state._open) {\n\t\t\t\tanimationController.open();\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate toggleTimeout?: ReturnType<typeof setTimeout>;\n\n\tprivate handleToggle = (event: Event) => {\n\t\tclearTimeout(this.toggleTimeout);\n\t\tthis.toggleTimeout = setTimeout(() => {\n\t\t\tconst open = Boolean(this.detailsElement?.open);\n\t\t\tif (open !== this.state._open) {\n\t\t\t\t// Update state\n\t\t\t\tthis._open = Boolean(this.detailsElement?.open);\n\n\t\t\t\t// Event handling\n\t\t\t\ttryToDispatchKoliBriEvent('toggle', this.host, this._open);\n\n\t\t\t\t// Callback\n\t\t\t\tif (typeof this.state._on?.onToggle === 'function') {\n\t\t\t\t\tthis.state._on?.onToggle(event, this._open);\n\t\t\t\t}\n\t\t\t}\n\t\t}, 25);\n\t};\n}\n"],"mappings":"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"}
1
+ {"version":3,"names":["DetailsAnimationController","constructor","detailsElement","summaryElement","contentElement","this","isClosing","isExpanding","addEventListener","handleSummaryClick","bind","event","preventDefault","style","overflow","open","collapse","height","_a","offsetHeight","window","requestAnimationFrame","expand","animateDetailsHeight","endHeight","direction","startHeight","animation","cancel","animate","duration","matchMedia","matches","easing","onAnimationFinish","once","undefined","removeProperty","defaultStyleCss","KolDetails","catchRef","ref","propagateFocus","host","handleToggle","clearTimeout","toggleTimeout","setTimeout","Boolean","state","_open","_b","tryToDispatchKoliBriEvent","_c","_on","onToggle","_d","_label","render","h","Host","el","_icons","class","element","validateLabel","value","validateOn","on","setState","validateOpen","componentWillLoad","componentDidLoad","animationController"],"sources":["src/components/details/DetailsAnimationController.ts","src/components/details/style.css?tag=kol-details&mode=default&encapsulation=shadow","src/components/details/component.tsx"],"sourcesContent":["/* Heavily inspired by: https://codepen.io/Mamboleoo/pen/QWEpLqm */\n\nexport default class DetailsAnimationController {\n\tprivate animation?: Animation;\n\tprivate isClosing = false;\n\tprivate isExpanding = false;\n\n\tconstructor(private detailsElement: HTMLDetailsElement, private summaryElement: HTMLElement, private contentElement: HTMLElement) {\n\t\tthis.summaryElement.addEventListener('click', this.handleSummaryClick.bind(this));\n\t}\n\n\tprivate handleSummaryClick(event: MouseEvent) {\n\t\tevent.preventDefault();\n\n\t\tthis.detailsElement.style.overflow = 'hidden';\n\t\tif (this.isClosing || !this.detailsElement.open) {\n\t\t\tthis.open();\n\t\t} else if (this.isExpanding || this.detailsElement.open) {\n\t\t\tthis.collapse();\n\t\t}\n\t}\n\n\tpublic open() {\n\t\t/**\n\t\t * The Jest test framework does not support the `offsetHeight` property on the `details` element.\n\t\t * This is a workaround to make the tests pass (?? 0).\n\t\t */\n\t\tthis.detailsElement.style.height = `${this.detailsElement.offsetHeight ?? 0}px`;\n\t\tthis.detailsElement.open = true;\n\t\twindow.requestAnimationFrame(this.expand.bind(this));\n\t}\n\n\tprivate expand() {\n\t\tthis.isExpanding = true;\n\t\tthis.animateDetailsHeight(this.summaryElement.offsetHeight + this.contentElement.offsetHeight, 'expand');\n\t}\n\n\tprivate collapse() {\n\t\tthis.isClosing = true;\n\t\tthis.animateDetailsHeight(this.summaryElement.offsetHeight, 'collapse');\n\t}\n\n\tprivate animateDetailsHeight(endHeight: number, direction: 'expand' | 'collapse') {\n\t\tconst startHeight = this.detailsElement.offsetHeight;\n\n\t\tif (this.animation) {\n\t\t\tthis.animation.cancel();\n\t\t}\n\n\t\tthis.animation = this.detailsElement.animate(\n\t\t\t{\n\t\t\t\theight: [`${startHeight}px`, `${endHeight}px`],\n\t\t\t},\n\t\t\t{\n\t\t\t\tduration: matchMedia('(prefers-reduced-motion)').matches ? 0 : 250,\n\t\t\t\teasing: 'ease-out',\n\t\t\t}\n\t\t);\n\n\t\tthis.animation.addEventListener(\n\t\t\t'finish',\n\t\t\t() => {\n\t\t\t\tthis.onAnimationFinish();\n\t\t\t},\n\t\t\t{ once: true }\n\t\t);\n\t\tthis.animation.addEventListener(\n\t\t\t'cancel',\n\t\t\t() => {\n\t\t\t\tif (direction === 'expand') {\n\t\t\t\t\tthis.isExpanding = false;\n\t\t\t\t} else {\n\t\t\t\t\tthis.isClosing = false;\n\t\t\t\t}\n\t\t\t},\n\t\t\t{ once: true }\n\t\t);\n\t}\n\n\tprivate onAnimationFinish() {\n\t\tthis.detailsElement.open = this.isExpanding;\n\t\tthis.animation = undefined;\n\t\tthis.isClosing = false;\n\t\tthis.isExpanding = false;\n\t\tthis.detailsElement.style.removeProperty('height');\n\t\tthis.detailsElement.style.removeProperty('overview');\n\t}\n}\n","@import url(../style.css);\n@import url(../host-display-block.css);\n@layer kol-component {\n\tdetails {\n\t\tdisplay: grid;\n\t}\n\n\tdetails > summary {\n\t\tcursor: pointer;\n\t\tdisplay: flex;\n\t\tplace-items: center;\n\t}\n\n\tdetails > summary > span {\n\t\tborder-bottom-color: grey;\n\t\tborder-bottom-style: solid;\n\t}\n\n\tdetails > summary:focus > span,\n\tdetails > summary:hover > span,\n\tdetails[open] > summary > span {\n\t\tborder-bottom-color: #000;\n\t}\n\n\tdetails > kol-indented-text {\n\t\tmargin: 0.25em 0 0 0.5em;\n\t}\n}\n.icon.is-open::part(icon) {\n\ttransform: rotate(90deg);\n}\n","import { Component, Element, h, Host, JSX, Prop, State, Watch } from '@stencil/core';\n\nimport { LabelPropType, validateLabel } from '../../types/props/label';\nimport { validateOpen } from '../../types/props/open';\nimport { tryToDispatchKoliBriEvent } from '../../utils/events';\nimport { setState } from '../../utils/prop.validators';\nimport DetailsAnimationController from './DetailsAnimationController';\nimport { API, EventCallbacks, States } from './types';\nimport { propagateFocus } from '../../utils/reuse';\n\n/**\n * @slot - Der Inhalt, der in der Detailbeschreibung angezeigt wird.\n */\n@Component({\n\ttag: 'kol-details',\n\tstyleUrls: {\n\t\tdefault: './style.css',\n\t},\n\tshadow: true,\n})\nexport class KolDetails implements API {\n\t@Element() private readonly host?: HTMLKolDetailsElement;\n\tprivate detailsElement?: HTMLDetailsElement;\n\tprivate summaryElement?: HTMLElement;\n\tprivate contentElement?: HTMLElement;\n\n\tprivate readonly catchRef = (ref?: HTMLElement) => {\n\t\tthis.summaryElement = ref;\n\t\tpropagateFocus(this.host, this.summaryElement);\n\t};\n\n\tpublic render(): JSX.Element {\n\t\treturn (\n\t\t\t<Host>\n\t\t\t\t<details\n\t\t\t\t\tref={(el) => {\n\t\t\t\t\t\tthis.detailsElement = el as HTMLDetailsElement;\n\t\t\t\t\t}}\n\t\t\t\t\tonToggle={this.handleToggle}\n\t\t\t\t>\n\t\t\t\t\t<summary ref={this.catchRef}>\n\t\t\t\t\t\t<kol-icon _label=\"\" _icons=\"codicon codicon-chevron-right\" class={`icon ${this.state._open ? 'is-open' : ''}`} />\n\t\t\t\t\t\t<span>{this.state._label}</span>\n\t\t\t\t\t</summary>\n\t\t\t\t\t<div aria-hidden={this.state._open === false ? 'true' : undefined} class=\"content\" ref={(element) => (this.contentElement = element)}>\n\t\t\t\t\t\t<kol-indented-text>\n\t\t\t\t\t\t\t<slot />\n\t\t\t\t\t\t</kol-indented-text>\n\t\t\t\t\t</div>\n\t\t\t\t</details>\n\t\t\t</Host>\n\t\t);\n\t}\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 * Defines the callback functions for details.\n\t */\n\t@Prop() public _on?: EventCallbacks;\n\n\t/**\n\t * If set (to true) opens/expands the element, closes if not set (or set to false).\n\t * @TODO: Change type back to `OpenPropType` after Stencil#4663 has been resolved.\n\t */\n\t@Prop({ mutable: true, reflect: true }) public _open?: boolean = false;\n\n\t@State() public state: States = {\n\t\t_label: '…', // '⚠'\n\t\t_on: {},\n\t};\n\n\t@Watch('_label')\n\tpublic validateLabel(value?: LabelPropType): void {\n\t\tvalidateLabel(this, value);\n\t}\n\n\t@Watch('_on')\n\tpublic validateOn(on?: EventCallbacks) {\n\t\tif (typeof on === 'object' && on !== null && typeof on.onToggle === 'function') {\n\t\t\tsetState<EventCallbacks>(this, '_on', on);\n\t\t}\n\t}\n\n\t@Watch('_open')\n\tpublic validateOpen(value?: boolean): void {\n\t\tvalidateOpen(this, value);\n\t}\n\n\tpublic componentWillLoad(): void {\n\t\tthis.validateLabel(this._label);\n\t\tthis.validateOn(this._on);\n\t\tthis.validateOpen(this._open);\n\t}\n\n\tpublic componentDidLoad() {\n\t\tif (this.detailsElement && this.summaryElement && this.contentElement) {\n\t\t\tconst animationController = new DetailsAnimationController(this.detailsElement, this.summaryElement, this.contentElement);\n\t\t\tif (this.state._open) {\n\t\t\t\tanimationController.open();\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate toggleTimeout?: ReturnType<typeof setTimeout>;\n\n\tprivate handleToggle = (event: Event) => {\n\t\tclearTimeout(this.toggleTimeout);\n\t\tthis.toggleTimeout = setTimeout(() => {\n\t\t\tconst open = Boolean(this.detailsElement?.open);\n\t\t\tif (open !== this.state._open) {\n\t\t\t\t// Update state\n\t\t\t\tthis._open = Boolean(this.detailsElement?.open);\n\n\t\t\t\t// Event handling\n\t\t\t\ttryToDispatchKoliBriEvent('toggle', this.host, this._open);\n\n\t\t\t\t// Callback\n\t\t\t\tif (typeof this.state._on?.onToggle === 'function') {\n\t\t\t\t\tthis.state._on?.onToggle(event, this._open);\n\t\t\t\t}\n\t\t\t}\n\t\t}, 25);\n\t};\n}\n"],"mappings":"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"}
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * KoliBri - The accessible HTML-Standard
3
3
  */
4
- import{r as t,h as i}from"./index-9c30809b.js";import{a as e}from"./i18n-8ec5b30e.js";import{a as o,d as s}from"./prop.validators-3d53ddab.js";import"./index-b79e4012.js";import"./dev.utils-075f4e7b.js";import"./reuse-b3566e4c.js";import"./a11y.tipps-06cd7c77.js";const r=class{constructor(e){t(this,e),this.onSubmit=t=>{var e,i;t.preventDefault(),t.stopPropagation(),"function"==typeof(null===(e=this.state._on)||void 0===e?void 0:e.onSubmit)&&(null===(i=this.state._on)||void 0===i||i.onSubmit(t))},this.onReset=t=>{var e,i;t.preventDefault(),t.stopPropagation(),"function"==typeof(null===(e=this.state._on)||void 0===e?void 0:e.onReset)&&(null===(i=this.state._on)||void 0===i||i.onReset(t))},this._on=void 0,this._requiredText=!0,this.state={}}render(){return i("form",{method:"post",onSubmit:this.onSubmit,onReset:this.onReset,autoComplete:"off",noValidate:!0},!0===this.state._requiredText?i("p",null,i("kol-indented-text",null,e("kol-form-description"))):"string"==typeof this.state._requiredText&&this.state._requiredText.length>0?i("p",null,i("kol-indented-text",null,this.state._requiredText)):null,i("slot",null))}validateOn(t){"object"==typeof t&&null!==t&&(this.state=Object.assign(Object.assign({},this.state),{_on:t}))}validateRequiredText(t){"boolean"==typeof t?o(this,"_requiredText",t):s(this,"_requiredText",t)}componentWillLoad(){this.validateOn(this._on),this.validateRequiredText(this._requiredText)}static get watchers(){return{_on:["validateOn"],_requiredText:["validateRequiredText"]}}};export{r as kol_form};
4
+ import{r as t,h as i}from"./index-9c30809b.js";import{a as e}from"./i18n-bb569ab8.js";import{a as o,d as s}from"./prop.validators-b0d023a4.js";import"./index-7a38e9a3.js";import"./dev.utils-34544843.js";import"./reuse-b3566e4c.js";import"./a11y.tipps-ce35f0ba.js";const r=class{constructor(e){t(this,e),this.onSubmit=t=>{var e,i;t.preventDefault(),t.stopPropagation(),"function"==typeof(null===(e=this.state._on)||void 0===e?void 0:e.onSubmit)&&(null===(i=this.state._on)||void 0===i||i.onSubmit(t))},this.onReset=t=>{var e,i;t.preventDefault(),t.stopPropagation(),"function"==typeof(null===(e=this.state._on)||void 0===e?void 0:e.onReset)&&(null===(i=this.state._on)||void 0===i||i.onReset(t))},this._on=void 0,this._requiredText=!0,this.state={}}render(){return i("form",{method:"post",onSubmit:this.onSubmit,onReset:this.onReset,autoComplete:"off",noValidate:!0},!0===this.state._requiredText?i("p",null,i("kol-indented-text",null,e("kol-form-description"))):"string"==typeof this.state._requiredText&&this.state._requiredText.length>0?i("p",null,i("kol-indented-text",null,this.state._requiredText)):null,i("slot",null))}validateOn(t){"object"==typeof t&&null!==t&&(this.state=Object.assign(Object.assign({},this.state),{_on:t}))}validateRequiredText(t){"boolean"==typeof t?o(this,"_requiredText",t):s(this,"_requiredText",t)}componentWillLoad(){this.validateOn(this._on),this.validateRequiredText(this._requiredText)}static get watchers(){return{_on:["validateOn"],_requiredText:["validateRequiredText"]}}};export{r as kol_form};