@oiz/stzh-components 2.10.0-beta → 2.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (428) hide show
  1. package/dist/cjs/{app-globals-1c49bef9.js → app-globals-4b0a6e5e.js} +2 -2
  2. package/dist/cjs/{app-globals-1c49bef9.js.map → app-globals-4b0a6e5e.js.map} +1 -1
  3. package/dist/cjs/index.cjs.js.map +1 -1
  4. package/dist/cjs/loader.cjs.js +2 -2
  5. package/dist/cjs/stzh-accordion-item.cjs.entry.js +1 -1
  6. package/dist/cjs/stzh-accordion-item.cjs.entry.js.map +1 -1
  7. package/dist/cjs/stzh-badge_3.cjs.entry.js.map +1 -1
  8. package/dist/cjs/stzh-carousel.cjs.entry.js +35 -11
  9. package/dist/cjs/stzh-carousel.cjs.entry.js.map +1 -1
  10. package/dist/cjs/stzh-cell.cjs.entry.js +2 -2
  11. package/dist/cjs/stzh-cell.cjs.entry.js.map +1 -1
  12. package/dist/cjs/stzh-components.cjs.js +2 -2
  13. package/dist/cjs/stzh-container.cjs.entry.js +9 -2
  14. package/dist/cjs/stzh-container.cjs.entry.js.map +1 -1
  15. package/dist/cjs/stzh-cspace.cjs.entry.js +1 -1
  16. package/dist/cjs/stzh-cspace.cjs.entry.js.map +1 -1
  17. package/dist/cjs/stzh-details.cjs.entry.js +1 -1
  18. package/dist/cjs/stzh-details.cjs.entry.js.map +1 -1
  19. package/dist/cjs/stzh-dropdown.cjs.entry.js +1 -1
  20. package/dist/cjs/stzh-dropdown.cjs.entry.js.map +1 -1
  21. package/dist/cjs/stzh-figure.cjs.entry.js +10 -3
  22. package/dist/cjs/stzh-figure.cjs.entry.js.map +1 -1
  23. package/dist/cjs/stzh-footer.cjs.entry.js +1 -1
  24. package/dist/cjs/stzh-footer.cjs.entry.js.map +1 -1
  25. package/dist/cjs/stzh-header.cjs.entry.js +1 -1
  26. package/dist/cjs/stzh-header.cjs.entry.js.map +1 -1
  27. package/dist/cjs/stzh-panorama.cjs.entry.js.map +1 -1
  28. package/dist/cjs/stzh-print.cjs.entry.js +52 -0
  29. package/dist/cjs/stzh-print.cjs.entry.js.map +1 -0
  30. package/dist/cjs/stzh-ratio.cjs.entry.js +5 -1
  31. package/dist/cjs/stzh-ratio.cjs.entry.js.map +1 -1
  32. package/dist/cjs/stzh-scrollup.cjs.entry.js +52 -0
  33. package/dist/cjs/stzh-scrollup.cjs.entry.js.map +1 -0
  34. package/dist/cjs/stzh-skin-portal-mitwirken.cjs.entry.js +1 -1
  35. package/dist/cjs/stzh-skin-portal-mitwirken.cjs.entry.js.map +1 -1
  36. package/dist/cjs/stzh-skiplink.cjs.entry.js +38 -1
  37. package/dist/cjs/stzh-skiplink.cjs.entry.js.map +1 -1
  38. package/dist/cjs/stzh-vbz-carousel.cjs.entry.js +51 -0
  39. package/dist/cjs/stzh-vbz-carousel.cjs.entry.js.map +1 -0
  40. package/dist/collection/collection-manifest.json +3 -0
  41. package/dist/collection/components/stzh-accordion/stzh-accordion.css +3 -0
  42. package/dist/collection/components/stzh-accordion-item/stzh-accordion-item.css +10 -0
  43. package/dist/collection/components/stzh-actions/stzh-actions.css +3 -0
  44. package/dist/collection/components/stzh-actionset/stzh-actionset.css +3 -0
  45. package/dist/collection/components/stzh-amount/stzh-amount.css +3 -0
  46. package/dist/collection/components/stzh-anchornav/stzh-anchornav.css +3 -0
  47. package/dist/collection/components/stzh-appnav/stzh-appnav.css +3 -0
  48. package/dist/collection/components/stzh-appointments/stzh-appointments.css +3 -0
  49. package/dist/collection/components/stzh-audio/stzh-audio.css +3 -0
  50. package/dist/collection/components/stzh-badge/stzh-badge.css +3 -0
  51. package/dist/collection/components/stzh-button/stzh-button.css +3 -0
  52. package/dist/collection/components/stzh-button/stzh-button.js +1 -1
  53. package/dist/collection/components/stzh-button/stzh-button.js.map +1 -1
  54. package/dist/collection/components/stzh-buttongroup/stzh-buttongroup.css +3 -0
  55. package/dist/collection/components/stzh-calendar/stzh-calendar.css +3 -0
  56. package/dist/collection/components/stzh-card/stzh-card.css +3 -0
  57. package/dist/collection/components/stzh-card-list/stzh-card-list.css +3 -0
  58. package/dist/collection/components/stzh-carousel/stzh-carousel.css +37 -24
  59. package/dist/collection/components/stzh-carousel/stzh-carousel.js +148 -12
  60. package/dist/collection/components/stzh-carousel/stzh-carousel.js.map +1 -1
  61. package/dist/collection/components/stzh-carousel/stzh-carousel.stories.js +50 -50
  62. package/dist/collection/components/stzh-cell/stzh-cell.css +11 -19
  63. package/dist/collection/components/stzh-cell/stzh-cell.js +8 -14
  64. package/dist/collection/components/stzh-cell/stzh-cell.js.map +1 -1
  65. package/dist/collection/components/stzh-chart/stzh-chart.css +3 -0
  66. package/dist/collection/components/stzh-checkbox/stzh-checkbox.css +3 -0
  67. package/dist/collection/components/stzh-checkboxgroup/stzh-checkboxgroup.css +3 -0
  68. package/dist/collection/components/stzh-chip/stzh-chip.css +3 -0
  69. package/dist/collection/components/stzh-chip-select/stzh-chip-select.css +3 -0
  70. package/dist/collection/components/stzh-clamp/stzh-clamp.css +3 -0
  71. package/dist/collection/components/stzh-contact/stzh-contact.css +3 -0
  72. package/dist/collection/components/stzh-container/stzh-container.css +22 -5
  73. package/dist/collection/components/stzh-container/stzh-container.js +51 -2
  74. package/dist/collection/components/stzh-container/stzh-container.js.map +1 -1
  75. package/dist/collection/components/stzh-cspace/stzh-cspace.css +1271 -9
  76. package/dist/collection/components/stzh-datalist/stzh-datalist.css +3 -0
  77. package/dist/collection/components/stzh-datalist-item/stzh-datalist-item.css +3 -0
  78. package/dist/collection/components/stzh-datamessagelist/stzh-datamessagelist.css +3 -0
  79. package/dist/collection/components/stzh-datamessagelist-item/stzh-datamessagelist-item.css +3 -0
  80. package/dist/collection/components/stzh-datatable/stzh-datatable.css +3 -0
  81. package/dist/collection/components/stzh-datepicker/stzh-datepicker.css +3 -0
  82. package/dist/collection/components/stzh-details/stzh-details.css +10 -0
  83. package/dist/collection/components/stzh-dialog/stzh-dialog.css +3 -0
  84. package/dist/collection/components/stzh-dropdown/stzh-dropdown.css +6 -0
  85. package/dist/collection/components/stzh-fieldset/stzh-fieldset.css +3 -0
  86. package/dist/collection/components/stzh-figure/stzh-figure.css +18 -6
  87. package/dist/collection/components/stzh-figure/stzh-figure.js +47 -2
  88. package/dist/collection/components/stzh-figure/stzh-figure.js.map +1 -1
  89. package/dist/collection/components/stzh-figure/stzh-figure.stories.js +10 -0
  90. package/dist/collection/components/stzh-flyingfocus/stzh-flyingfocus.css +3 -0
  91. package/dist/collection/components/stzh-footer/stzh-footer.css +13 -5
  92. package/dist/collection/components/stzh-ghettobox/stzh-ghettobox.css +3 -0
  93. package/dist/collection/components/stzh-header/stzh-header.css +33 -15
  94. package/dist/collection/components/stzh-header/stzh-header.stories.js +7 -7
  95. package/dist/collection/components/stzh-heading/stzh-heading.css +3 -0
  96. package/dist/collection/components/stzh-hr/stzh-hr.css +3 -0
  97. package/dist/collection/components/stzh-hspace/stzh-hspace.css +3 -0
  98. package/dist/collection/components/stzh-icon/stzh-icon.css +3 -0
  99. package/dist/collection/components/stzh-icon-sprite/stzh-icon-sprite.css +3 -0
  100. package/dist/collection/components/stzh-iframe/stzh-iframe.css +3 -0
  101. package/dist/collection/components/stzh-input/stzh-input.css +3 -0
  102. package/dist/collection/components/stzh-invert/stzh-invert.css +3 -0
  103. package/dist/collection/components/stzh-langnav/stzh-langnav.css +3 -0
  104. package/dist/collection/components/stzh-link/stzh-link.css +3 -0
  105. package/dist/collection/components/stzh-list/stzh-list.css +3 -0
  106. package/dist/collection/components/stzh-list-item/stzh-list-item.css +3 -0
  107. package/dist/collection/components/stzh-loader/stzh-loader.css +3 -0
  108. package/dist/collection/components/stzh-loadingbar/stzh-loadingbar.css +3 -0
  109. package/dist/collection/components/stzh-menu/stzh-menu.css +3 -0
  110. package/dist/collection/components/stzh-menu-item/stzh-menu-item.css +3 -0
  111. package/dist/collection/components/stzh-message/stzh-message.css +3 -0
  112. package/dist/collection/components/stzh-metanav/stzh-metanav.css +3 -0
  113. package/dist/collection/components/stzh-microsite-teaserlist/stzh-microsite-teaserlist.css +3 -0
  114. package/dist/collection/components/stzh-monthyearpicker/stzh-monthyearpicker.css +3 -0
  115. package/dist/collection/components/stzh-olmap/stzh-olmap.css +3 -0
  116. package/dist/collection/components/stzh-overlay/stzh-overlay.css +3 -0
  117. package/dist/collection/components/stzh-page-skiplinks/stzh-page-skiplinks.css +3 -0
  118. package/dist/collection/components/stzh-page-skiplinks/stzh-page-skiplinks.stories.js +2 -2
  119. package/dist/collection/components/stzh-pagebottom/stzh-pagebottom.css +3 -0
  120. package/dist/collection/components/stzh-pagetitle/stzh-pagetitle.css +3 -0
  121. package/dist/collection/components/stzh-pagetitle-hero/stzh-pagetitle-hero.css +3 -0
  122. package/dist/collection/components/stzh-pagination/stzh-pagination.css +3 -0
  123. package/dist/collection/components/stzh-panorama/stzh-panorama.css +3 -0
  124. package/dist/collection/components/stzh-popover/stzh-popover.css +3 -0
  125. package/dist/collection/components/stzh-print/stzh-print.css +127 -0
  126. package/dist/collection/components/stzh-print/stzh-print.js +53 -0
  127. package/dist/collection/components/stzh-print/stzh-print.js.map +1 -0
  128. package/dist/collection/components/stzh-print/stzh-print.stories.js +43 -0
  129. package/dist/collection/components/stzh-progressbar/stzh-progressbar.css +3 -0
  130. package/dist/collection/components/stzh-progressbar-item/stzh-progressbar-item.css +3 -0
  131. package/dist/collection/components/stzh-radio/stzh-radio.css +3 -0
  132. package/dist/collection/components/stzh-radiogroup/stzh-radiogroup.css +3 -0
  133. package/dist/collection/components/stzh-ratio/stzh-ratio.css +457 -21
  134. package/dist/collection/components/stzh-ratio/stzh-ratio.js +110 -4
  135. package/dist/collection/components/stzh-ratio/stzh-ratio.js.map +1 -1
  136. package/dist/collection/components/stzh-readspeaker/stzh-readspeaker.css +3 -0
  137. package/dist/collection/components/stzh-richtext/stzh-richtext.css +3 -0
  138. package/dist/collection/components/stzh-row/stzh-row.css +3 -0
  139. package/dist/collection/components/stzh-saptcha/stzh-saptcha.css +3 -0
  140. package/dist/collection/components/stzh-scrollup/stzh-scrollup.css +127 -0
  141. package/dist/collection/components/stzh-scrollup/stzh-scrollup.js +53 -0
  142. package/dist/collection/components/stzh-scrollup/stzh-scrollup.js.map +1 -0
  143. package/dist/collection/components/stzh-scrollup/stzh-scrollup.stories.js +99 -0
  144. package/dist/collection/components/stzh-section/stzh-section.css +3 -0
  145. package/dist/collection/components/stzh-share/stzh-share.css +3 -0
  146. package/dist/collection/components/stzh-show/stzh-show.css +3 -0
  147. package/dist/collection/components/stzh-sitemap/stzh-sitemap.css +3 -0
  148. package/dist/collection/components/stzh-skin-portal-mitwirken/stzh-skin-portal-mitwirken.css +25 -0
  149. package/dist/collection/components/stzh-skin-storybook-preview/stzh-skin-storybook-preview.css +3 -0
  150. package/dist/collection/components/stzh-skiplink/stzh-skiplink.css +3 -0
  151. package/dist/collection/components/stzh-skiplink/stzh-skiplink.js +81 -1
  152. package/dist/collection/components/stzh-skiplink/stzh-skiplink.js.map +1 -1
  153. package/dist/collection/components/stzh-skiplink/stzh-skiplink.stories.js +1 -1
  154. package/dist/collection/components/stzh-sortable/stzh-sortable.css +3 -0
  155. package/dist/collection/components/stzh-space/stzh-space.css +3 -0
  156. package/dist/collection/components/stzh-status/stzh-status.css +3 -0
  157. package/dist/collection/components/stzh-sticky/stzh-sticky.css +3 -0
  158. package/dist/collection/components/stzh-table/stzh-table.css +3 -0
  159. package/dist/collection/components/stzh-text/stzh-text.css +3 -0
  160. package/dist/collection/components/stzh-textandimage/stzh-textandimage.css +3 -0
  161. package/dist/collection/components/stzh-timeline/stzh-timeline.css +3 -0
  162. package/dist/collection/components/stzh-timeline-item/stzh-timeline-item.css +3 -0
  163. package/dist/collection/components/stzh-timepicker/stzh-timepicker.css +3 -0
  164. package/dist/collection/components/stzh-toast/stzh-toast.css +3 -0
  165. package/dist/collection/components/stzh-toastbar/stzh-toastbar.css +3 -0
  166. package/dist/collection/components/stzh-toggle/stzh-toggle.css +3 -0
  167. package/dist/collection/components/stzh-tooltip/stzh-tooltip.css +3 -0
  168. package/dist/collection/components/stzh-upload/stzh-upload.css +3 -0
  169. package/dist/collection/components/stzh-vbz-carousel/stzh-vbz-carousel.css +142 -0
  170. package/dist/collection/components/stzh-vbz-carousel/stzh-vbz-carousel.js +76 -0
  171. package/dist/collection/components/stzh-vbz-carousel/stzh-vbz-carousel.js.map +1 -0
  172. package/dist/collection/components/stzh-vbz-carousel/stzh-vbz-carousel.stories.js +52 -0
  173. package/dist/collection/components/stzh-vbz-linechip/stzh-vbz-linechip.css +3 -0
  174. package/dist/collection/components/stzh-vbz-majorticker/stzh-vbz-majorticker.css +3 -0
  175. package/dist/collection/components/stzh-vbz-ticker/stzh-vbz-ticker.css +3 -0
  176. package/dist/collection/components/stzh-visuallyhidden/stzh-visuallyhidden.css +3 -0
  177. package/dist/collection/components/stzh-vspace/stzh-vspace.css +3 -0
  178. package/dist/collection/components/stzh-youtube/stzh-youtube.css +3 -0
  179. package/dist/collection/index.js.map +1 -1
  180. package/dist/components/index.js +1 -1
  181. package/dist/components/index2.js.map +1 -1
  182. package/dist/components/stzh-accordion-item.js +1 -1
  183. package/dist/components/stzh-accordion-item.js.map +1 -1
  184. package/dist/components/stzh-button2.js.map +1 -1
  185. package/dist/components/stzh-carousel.js +1 -579
  186. package/dist/components/stzh-carousel.js.map +1 -1
  187. package/dist/components/stzh-carousel2.js +615 -0
  188. package/dist/components/stzh-carousel2.js.map +1 -0
  189. package/dist/components/stzh-cell.js +3 -3
  190. package/dist/components/stzh-cell.js.map +1 -1
  191. package/dist/components/stzh-container.js +13 -3
  192. package/dist/components/stzh-container.js.map +1 -1
  193. package/dist/components/stzh-cspace.js +1 -1
  194. package/dist/components/stzh-cspace.js.map +1 -1
  195. package/dist/components/stzh-details.js +1 -1
  196. package/dist/components/stzh-details.js.map +1 -1
  197. package/dist/components/stzh-dropdown2.js +1 -1
  198. package/dist/components/stzh-dropdown2.js.map +1 -1
  199. package/dist/components/stzh-figure2.js +12 -3
  200. package/dist/components/stzh-figure2.js.map +1 -1
  201. package/dist/components/stzh-footer.js +1 -1
  202. package/dist/components/stzh-footer.js.map +1 -1
  203. package/dist/components/stzh-header.js +1 -1
  204. package/dist/components/stzh-header.js.map +1 -1
  205. package/dist/components/stzh-panorama.js.map +1 -1
  206. package/dist/components/stzh-print.d.ts +11 -0
  207. package/dist/components/stzh-print.js +64 -0
  208. package/dist/components/stzh-print.js.map +1 -0
  209. package/dist/components/stzh-ratio2.js +10 -2
  210. package/dist/components/stzh-ratio2.js.map +1 -1
  211. package/dist/components/stzh-scrollup.d.ts +11 -0
  212. package/dist/components/stzh-scrollup.js +64 -0
  213. package/dist/components/stzh-scrollup.js.map +1 -0
  214. package/dist/components/stzh-skin-portal-mitwirken.js +1 -1
  215. package/dist/components/stzh-skin-portal-mitwirken.js.map +1 -1
  216. package/dist/components/stzh-skiplink.js +39 -2
  217. package/dist/components/stzh-skiplink.js.map +1 -1
  218. package/dist/components/stzh-vbz-carousel.d.ts +11 -0
  219. package/dist/components/stzh-vbz-carousel.js +72 -0
  220. package/dist/components/stzh-vbz-carousel.js.map +1 -0
  221. package/dist/esm/{app-globals-503e5649.js → app-globals-fecef0e2.js} +2 -2
  222. package/dist/esm/{app-globals-503e5649.js.map → app-globals-fecef0e2.js.map} +1 -1
  223. package/dist/esm/index.js.map +1 -1
  224. package/dist/esm/loader.js +2 -2
  225. package/dist/esm/stzh-accordion-item.entry.js +1 -1
  226. package/dist/esm/stzh-accordion-item.entry.js.map +1 -1
  227. package/dist/esm/stzh-badge_3.entry.js.map +1 -1
  228. package/dist/esm/stzh-carousel.entry.js +35 -11
  229. package/dist/esm/stzh-carousel.entry.js.map +1 -1
  230. package/dist/esm/stzh-cell.entry.js +2 -2
  231. package/dist/esm/stzh-cell.entry.js.map +1 -1
  232. package/dist/esm/stzh-components.js +2 -2
  233. package/dist/esm/stzh-container.entry.js +9 -2
  234. package/dist/esm/stzh-container.entry.js.map +1 -1
  235. package/dist/esm/stzh-cspace.entry.js +1 -1
  236. package/dist/esm/stzh-cspace.entry.js.map +1 -1
  237. package/dist/esm/stzh-details.entry.js +1 -1
  238. package/dist/esm/stzh-details.entry.js.map +1 -1
  239. package/dist/esm/stzh-dropdown.entry.js +1 -1
  240. package/dist/esm/stzh-dropdown.entry.js.map +1 -1
  241. package/dist/esm/stzh-figure.entry.js +10 -3
  242. package/dist/esm/stzh-figure.entry.js.map +1 -1
  243. package/dist/esm/stzh-footer.entry.js +1 -1
  244. package/dist/esm/stzh-footer.entry.js.map +1 -1
  245. package/dist/esm/stzh-header.entry.js +1 -1
  246. package/dist/esm/stzh-header.entry.js.map +1 -1
  247. package/dist/esm/stzh-panorama.entry.js.map +1 -1
  248. package/dist/esm/stzh-print.entry.js +48 -0
  249. package/dist/esm/stzh-print.entry.js.map +1 -0
  250. package/dist/esm/stzh-ratio.entry.js +5 -1
  251. package/dist/esm/stzh-ratio.entry.js.map +1 -1
  252. package/dist/esm/stzh-scrollup.entry.js +48 -0
  253. package/dist/esm/stzh-scrollup.entry.js.map +1 -0
  254. package/dist/esm/stzh-skin-portal-mitwirken.entry.js +1 -1
  255. package/dist/esm/stzh-skin-portal-mitwirken.entry.js.map +1 -1
  256. package/dist/esm/stzh-skiplink.entry.js +39 -2
  257. package/dist/esm/stzh-skiplink.entry.js.map +1 -1
  258. package/dist/esm/stzh-vbz-carousel.entry.js +47 -0
  259. package/dist/esm/stzh-vbz-carousel.entry.js.map +1 -0
  260. package/dist/esm-es5/{app-globals-503e5649.js → app-globals-fecef0e2.js} +2 -2
  261. package/dist/esm-es5/{app-globals-503e5649.js.map → app-globals-fecef0e2.js.map} +1 -1
  262. package/dist/esm-es5/index.js.map +1 -1
  263. package/dist/esm-es5/loader.js +1 -1
  264. package/dist/esm-es5/loader.js.map +1 -1
  265. package/dist/esm-es5/stzh-accordion-item.entry.js +1 -1
  266. package/dist/esm-es5/stzh-accordion-item.entry.js.map +1 -1
  267. package/dist/esm-es5/stzh-badge_3.entry.js.map +1 -1
  268. package/dist/esm-es5/stzh-carousel.entry.js +1 -1
  269. package/dist/esm-es5/stzh-carousel.entry.js.map +1 -1
  270. package/dist/esm-es5/stzh-cell.entry.js +1 -1
  271. package/dist/esm-es5/stzh-cell.entry.js.map +1 -1
  272. package/dist/esm-es5/stzh-components.js +1 -1
  273. package/dist/esm-es5/stzh-components.js.map +1 -1
  274. package/dist/esm-es5/stzh-container.entry.js +1 -1
  275. package/dist/esm-es5/stzh-container.entry.js.map +1 -1
  276. package/dist/esm-es5/stzh-cspace.entry.js +1 -1
  277. package/dist/esm-es5/stzh-cspace.entry.js.map +1 -1
  278. package/dist/esm-es5/stzh-details.entry.js +1 -1
  279. package/dist/esm-es5/stzh-details.entry.js.map +1 -1
  280. package/dist/esm-es5/stzh-dropdown.entry.js +1 -1
  281. package/dist/esm-es5/stzh-dropdown.entry.js.map +1 -1
  282. package/dist/esm-es5/stzh-figure.entry.js +1 -1
  283. package/dist/esm-es5/stzh-figure.entry.js.map +1 -1
  284. package/dist/esm-es5/stzh-footer.entry.js +1 -1
  285. package/dist/esm-es5/stzh-footer.entry.js.map +1 -1
  286. package/dist/esm-es5/stzh-header.entry.js +1 -1
  287. package/dist/esm-es5/stzh-header.entry.js.map +1 -1
  288. package/dist/esm-es5/stzh-panorama.entry.js.map +1 -1
  289. package/dist/esm-es5/stzh-print.entry.js +2 -0
  290. package/dist/esm-es5/stzh-print.entry.js.map +1 -0
  291. package/dist/esm-es5/stzh-ratio.entry.js +1 -1
  292. package/dist/esm-es5/stzh-ratio.entry.js.map +1 -1
  293. package/dist/esm-es5/stzh-scrollup.entry.js +2 -0
  294. package/dist/esm-es5/stzh-scrollup.entry.js.map +1 -0
  295. package/dist/esm-es5/stzh-skin-portal-mitwirken.entry.js +1 -1
  296. package/dist/esm-es5/stzh-skin-portal-mitwirken.entry.js.map +1 -1
  297. package/dist/esm-es5/stzh-skiplink.entry.js +1 -1
  298. package/dist/esm-es5/stzh-skiplink.entry.js.map +1 -1
  299. package/dist/esm-es5/stzh-vbz-carousel.entry.js +2 -0
  300. package/dist/esm-es5/stzh-vbz-carousel.entry.js.map +1 -0
  301. package/dist/stzh-components/index.esm.js.map +1 -1
  302. package/dist/stzh-components/p-0bb08043.system.js.map +1 -1
  303. package/dist/stzh-components/{p-42d27a5d.system.entry.js → p-0d654519.system.entry.js} +2 -2
  304. package/dist/stzh-components/{p-42d27a5d.system.entry.js.map → p-0d654519.system.entry.js.map} +1 -1
  305. package/dist/stzh-components/p-0dcbb483.system.entry.js.map +1 -1
  306. package/dist/stzh-components/p-0f3f22c8.entry.js +2 -0
  307. package/dist/stzh-components/p-0f3f22c8.entry.js.map +1 -0
  308. package/dist/stzh-components/p-25bfad8b.entry.js +2 -0
  309. package/dist/stzh-components/p-25bfad8b.entry.js.map +1 -0
  310. package/dist/stzh-components/p-28ae4569.entry.js +2 -0
  311. package/dist/stzh-components/p-28ae4569.entry.js.map +1 -0
  312. package/dist/stzh-components/p-35de63a8.entry.js +2 -0
  313. package/dist/stzh-components/p-35de63a8.entry.js.map +1 -0
  314. package/dist/stzh-components/p-37fc4785.system.entry.js +2 -0
  315. package/dist/stzh-components/p-37fc4785.system.entry.js.map +1 -0
  316. package/dist/stzh-components/{p-6b86b394.entry.js → p-390c4a4b.entry.js} +4 -4
  317. package/dist/stzh-components/{p-6b86b394.entry.js.map → p-390c4a4b.entry.js.map} +1 -1
  318. package/dist/stzh-components/p-491ae21b.entry.js.map +1 -1
  319. package/dist/stzh-components/p-4b7f4e66.entry.js +2 -0
  320. package/dist/stzh-components/p-4b7f4e66.entry.js.map +1 -0
  321. package/dist/stzh-components/p-4d975c00.entry.js +2 -0
  322. package/dist/stzh-components/{p-18402a84.entry.js.map → p-4d975c00.entry.js.map} +1 -1
  323. package/dist/stzh-components/p-531fd43a.entry.js +2 -0
  324. package/dist/stzh-components/p-531fd43a.entry.js.map +1 -0
  325. package/dist/stzh-components/p-5f1338aa.system.entry.js.map +1 -1
  326. package/dist/stzh-components/p-64217de4.system.entry.js +2 -0
  327. package/dist/stzh-components/p-64217de4.system.entry.js.map +1 -0
  328. package/dist/stzh-components/p-6858fb1c.entry.js +2 -0
  329. package/dist/stzh-components/p-6858fb1c.entry.js.map +1 -0
  330. package/dist/stzh-components/p-6c9e992d.entry.js +2 -0
  331. package/dist/stzh-components/p-6c9e992d.entry.js.map +1 -0
  332. package/dist/stzh-components/p-70680746.entry.js +2 -0
  333. package/dist/stzh-components/p-70680746.entry.js.map +1 -0
  334. package/dist/stzh-components/p-81aee661.system.entry.js +2 -0
  335. package/dist/stzh-components/{p-1d8dbb06.system.entry.js.map → p-81aee661.system.entry.js.map} +1 -1
  336. package/dist/stzh-components/p-83e30e85.system.entry.js +2 -0
  337. package/dist/stzh-components/p-83e30e85.system.entry.js.map +1 -0
  338. package/dist/stzh-components/p-844a2406.system.entry.js +2 -0
  339. package/dist/stzh-components/p-844a2406.system.entry.js.map +1 -0
  340. package/dist/stzh-components/p-8c26e8c9.entry.js +2 -0
  341. package/dist/stzh-components/{p-a8f684d4.entry.js.map → p-8c26e8c9.entry.js.map} +1 -1
  342. package/dist/stzh-components/p-8f9dc890.system.entry.js +2 -0
  343. package/dist/stzh-components/p-8f9dc890.system.entry.js.map +1 -0
  344. package/dist/stzh-components/p-9790b917.entry.js +2 -0
  345. package/dist/stzh-components/p-9790b917.entry.js.map +1 -0
  346. package/dist/stzh-components/p-a2a68a9d.system.entry.js +2 -0
  347. package/dist/stzh-components/p-a2a68a9d.system.entry.js.map +1 -0
  348. package/dist/stzh-components/p-b1d5d2df.system.entry.js +2 -0
  349. package/dist/stzh-components/p-b1d5d2df.system.entry.js.map +1 -0
  350. package/dist/stzh-components/p-be975e7b.system.js +2 -0
  351. package/dist/stzh-components/{p-5fce4cad.system.js.map → p-be975e7b.system.js.map} +1 -1
  352. package/dist/stzh-components/{p-a12b9320.entry.js → p-bf106d8e.entry.js} +2 -2
  353. package/dist/stzh-components/p-bf106d8e.entry.js.map +1 -0
  354. package/dist/stzh-components/p-c6e46a21.entry.js.map +1 -1
  355. package/dist/stzh-components/{p-902b3880.system.js → p-cce9517f.system.js} +2 -2
  356. package/dist/stzh-components/{p-902b3880.system.js.map → p-cce9517f.system.js.map} +1 -1
  357. package/dist/stzh-components/p-ce501c33.system.entry.js +2 -0
  358. package/dist/stzh-components/p-ce501c33.system.entry.js.map +1 -0
  359. package/dist/stzh-components/{p-8a9c656a.system.entry.js → p-d58e8330.system.entry.js} +2 -2
  360. package/dist/stzh-components/p-d58e8330.system.entry.js.map +1 -0
  361. package/dist/stzh-components/p-dfda6333.system.entry.js +2 -0
  362. package/dist/stzh-components/p-dfda6333.system.entry.js.map +1 -0
  363. package/dist/stzh-components/p-e03a82e6.system.entry.js +2 -0
  364. package/dist/stzh-components/{p-ff1cfbee.system.entry.js.map → p-e03a82e6.system.entry.js.map} +1 -1
  365. package/dist/stzh-components/p-e922df8b.system.entry.js +2 -0
  366. package/dist/stzh-components/{p-4b5bc7a0.system.entry.js.map → p-e922df8b.system.entry.js.map} +1 -1
  367. package/dist/stzh-components/p-ec8651cb.entry.js +2 -0
  368. package/dist/stzh-components/{p-346b8599.entry.js.map → p-ec8651cb.entry.js.map} +1 -1
  369. package/dist/stzh-components/{p-e11c28a1.js → p-ed41f495.js} +2 -2
  370. package/dist/stzh-components/{p-e11c28a1.js.map → p-ed41f495.js.map} +1 -1
  371. package/dist/stzh-components/p-ee8c7dc4.system.entry.js +2 -0
  372. package/dist/stzh-components/p-ee8c7dc4.system.entry.js.map +1 -0
  373. package/dist/stzh-components/p-f3ab9795.system.entry.js +2 -0
  374. package/dist/stzh-components/p-f3ab9795.system.entry.js.map +1 -0
  375. package/dist/stzh-components/p-fe31269f.entry.js +2 -0
  376. package/dist/stzh-components/p-fe31269f.entry.js.map +1 -0
  377. package/dist/stzh-components/stzh-components.css +22 -0
  378. package/dist/stzh-components/stzh-components.esm.js +1 -1
  379. package/dist/stzh-components/stzh-components.esm.js.map +1 -1
  380. package/dist/stzh-components/stzh-components.js +1 -1
  381. package/dist/types/components/stzh-cell/stzh-cell.d.ts +2 -2
  382. package/dist/types/components/stzh-container/stzh-container.d.ts +4 -0
  383. package/dist/types/components.d.ts +186 -15
  384. package/dist/types/index.d.ts +10 -1
  385. package/dist/vscode-data.json +213 -24
  386. package/package.json +1 -1
  387. package/dist/stzh-components/p-061ede8b.entry.js +0 -2
  388. package/dist/stzh-components/p-061ede8b.entry.js.map +0 -1
  389. package/dist/stzh-components/p-086e9523.system.entry.js +0 -2
  390. package/dist/stzh-components/p-086e9523.system.entry.js.map +0 -1
  391. package/dist/stzh-components/p-18402a84.entry.js +0 -2
  392. package/dist/stzh-components/p-1ae561a5.system.entry.js +0 -2
  393. package/dist/stzh-components/p-1ae561a5.system.entry.js.map +0 -1
  394. package/dist/stzh-components/p-1c930dc5.entry.js +0 -2
  395. package/dist/stzh-components/p-1c930dc5.entry.js.map +0 -1
  396. package/dist/stzh-components/p-1d8dbb06.system.entry.js +0 -2
  397. package/dist/stzh-components/p-1edbef4a.system.entry.js +0 -2
  398. package/dist/stzh-components/p-1edbef4a.system.entry.js.map +0 -1
  399. package/dist/stzh-components/p-2eb74ed1.entry.js +0 -2
  400. package/dist/stzh-components/p-2eb74ed1.entry.js.map +0 -1
  401. package/dist/stzh-components/p-2f205fad.entry.js +0 -2
  402. package/dist/stzh-components/p-2f205fad.entry.js.map +0 -1
  403. package/dist/stzh-components/p-32773a2c.system.entry.js +0 -2
  404. package/dist/stzh-components/p-32773a2c.system.entry.js.map +0 -1
  405. package/dist/stzh-components/p-346b8599.entry.js +0 -2
  406. package/dist/stzh-components/p-3d3d09c3.entry.js +0 -2
  407. package/dist/stzh-components/p-3d3d09c3.entry.js.map +0 -1
  408. package/dist/stzh-components/p-4b5bc7a0.system.entry.js +0 -2
  409. package/dist/stzh-components/p-5fce4cad.system.js +0 -2
  410. package/dist/stzh-components/p-6966188f.system.entry.js +0 -2
  411. package/dist/stzh-components/p-6966188f.system.entry.js.map +0 -1
  412. package/dist/stzh-components/p-8a9c656a.system.entry.js.map +0 -1
  413. package/dist/stzh-components/p-95a50796.entry.js +0 -2
  414. package/dist/stzh-components/p-95a50796.entry.js.map +0 -1
  415. package/dist/stzh-components/p-a12b9320.entry.js.map +0 -1
  416. package/dist/stzh-components/p-a8f684d4.entry.js +0 -2
  417. package/dist/stzh-components/p-b98bc5c1.entry.js +0 -2
  418. package/dist/stzh-components/p-b98bc5c1.entry.js.map +0 -1
  419. package/dist/stzh-components/p-bb5b861d.system.entry.js +0 -2
  420. package/dist/stzh-components/p-bb5b861d.system.entry.js.map +0 -1
  421. package/dist/stzh-components/p-c4c8b232.system.entry.js +0 -2
  422. package/dist/stzh-components/p-c4c8b232.system.entry.js.map +0 -1
  423. package/dist/stzh-components/p-d3f4ad11.system.entry.js +0 -2
  424. package/dist/stzh-components/p-d3f4ad11.system.entry.js.map +0 -1
  425. package/dist/stzh-components/p-e0e7105e.entry.js +0 -2
  426. package/dist/stzh-components/p-e0e7105e.entry.js.map +0 -1
  427. package/dist/stzh-components/p-ff1cfbee.system.entry.js +0 -2
  428. package/dist/types/components/stzh-skiplink/stzh-skiplink.d.ts +0 -27
@@ -1 +1 @@
1
- {"version":3,"names":["stzhBadgeCss","StzhBadge","prototype","render","classes","_a","concat","this","type","h","Host","class","label","stzhButtonCss","StzhButton","focusedByInput","onInput","event","_this","checked","input","stzhChange","emit","component","originalEvent","value","onRootFocus","setFocus","onFocus","focusEvent","FocusEvent","view","window","bubbles","cancelable","element","dispatchEvent","stzhFocus","onBlur","blurEvent","stzhBlur","onClick","disabled","stopPropagation","preventDefault","class_1","button","focus","renderIcon","iconUsed","icon","name","badge","badgeEmpty","badgePosition","badgeType","renderContent","rel","includes","localization","$globals","externalLinkLabel","download","downloadLinkLabel","ref","el","text","renderInner","Fragment","iconPosition","componentWillLoad","stzhComponents","utils","fetchTranslations","_b","sent","componentDidRender","requestAnimationFrame","setAttribute","analyticsId","innerText","hasSlot","iconOnly","floating","rounded","fullwidth","a11yDisabled","active","effect","textAlign","size","variant","tabindex","href","target","a11yLabel","a11yDescribedby","a11yExpanded","a11yControls","accessKey","linkAccesskey","a11yTabindex","stzhIconCss","iconCounter","StzhIcon","iconId","role","a11yTitle","focusable","id"],"sources":["src/components/stzh-badge/stzh-badge.scss?tag=stzh-badge&encapsulation=scoped","src/components/stzh-badge/stzh-badge.tsx","src/components/stzh-button/stzh-button.scss?tag=stzh-button&encapsulation=scoped","src/components/stzh-button/stzh-button.tsx","src/components/stzh-icon/stzh-icon.scss?tag=stzh-icon&encapsulation=scoped","src/components/stzh-icon/stzh-icon.tsx"],"sourcesContent":[":host {\n --color: #{$colorWhite};\n --background-color: #{$baseColor};\n display: inline-flex;\n\n &[type=\"success\"] {\n --background-color: #{$colorTruegreen};\n }\n\n &[type=\"warning\"] {\n --color: #{$colorGrey87};\n --background-color: #{$colorWarning};\n }\n\n &[type=\"error\"] {\n --background-color: #{$colorError};\n }\n\n &[type=\"info\"] {\n --background-color: #{$colorZueriblue};\n }\n}\n\n.stzh-badge {\n @include badge;\n}\n","import {\n Component,\n Host,\n h,\n Prop,\n} from \"@stencil/core\";\n\n/**\n * @slot - Slot badge content\n */\n@Component({\n tag: \"stzh-badge\",\n styleUrl: \"stzh-badge.scss\",\n scoped: true\n})\nexport class StzhBadge {\n /** Text content of the badge */\n @Prop() label: string = \"\";\n\n /** Type */\n @Prop({ reflect: true }) type: \"default\" | \"success\" | \"warning\" | \"error\" | \"info\" = \"default\";\n\n render() {\n const classes = {\n \"stzh-badge\": true,\n [`stzh-badge--type-${this.type}`]: !!this.type\n };\n\n return (\n <Host>\n <div class={classes}>\n {this.label}\n </div>\n </Host>\n );\n }\n}\n","/**\n * @prop --height: Height of button\n * @prop --padding: Padding of button\n * @prop --border-radius: Border radius of button\n * @prop --color: Color of button\n * @prop --background-color: Background color of button\n * @prop --border-color: Border color of button\n * @prop --icon-size: Size of icon next to button\n * @prop --hover-color: Hover color of button\n * @prop --hover-background-color: Hover background color of button\n * @prop --hover-border-color: Hover border color of button\n * @prop --white-space: White space behaviour of button\n *\n * @prop --floating-position: Position when floating variant is used\n * @prop --floating-float: Floating direction when floating variant is used\n * @prop --floating-top: Space to the top when floating variant is used\n * @prop --floating-bottom: Space to the bottom when floating variant is used\n * @prop --floating-left: Space to the left when floating variant is used\n * @prop --floating-right: Space to the right when floating variant is used\n *\n * @prop --stzh-form-input-height: **Global**: Height of fields & buttons\n * @prop --stzh-form-input-small-height: **Global**: Height of fields & buttons when small variant is used\n * @prop --stzh-form-input-tiny-height: **Global**: Height of fields & buttons when tiny variant is used\n */\n\n:host {\n --color: #{$colorWhite};\n --background-color: #{$colorPrimary};\n --border-width: 1px;\n --border-color: #{$colorPrimary};\n --border-radius: #{$buttonBorderRadius};\n --height: #{$formInputHeight};\n --icon-size: #{iconSize('small')};\n --icon-text-margin: #{space('small')};\n --badge-icon-text-margin: calc(var(--icon-text-margin) + #{space('xxsmall')});\n --padding: calc(#{space('xsmall')} - 1px) #{space('xlarge')};\n --white-space: normal;\n --box-shadow: none;\n --cursor: pointer;\n\n --hover-color: #{$colorWhite};\n --hover-background-color: #{$colorPrimaryHover};\n --hover-border-color: #{$colorPrimaryHover};\n\n --floating-position: sticky;\n --floating-float: right;\n --floating-top: auto;\n --floating-bottom: #{space('medium')};\n --floating-left: auto;\n --floating-right: #{space('medium')};\n\n display: inline-block;\n\n @include mq($from: small) {\n --floating-bottom: #{space('xlarge')};\n --floating-right: #{space('xlarge')};\n }\n\n &[fullwidth]:not([fullwidth=\"false\"]) {\n width: 100%;\n display: block;\n }\n\n &[rounded]:not([rounded=\"false\"]) {\n --border-radius: var(--height);\n }\n\n &[floating]:not([floating=\"false\"]) {\n --box-shadow: #{$boxShadowOverlay};\n\n position: var(--floating-position);\n top: var(--floating-top);\n bottom: var(--floating-bottom);\n left: var(--floating-left);\n right: var(--floating-right);\n float: var(--floating-float);\n }\n\n &[size=\"small\"] {\n --height: #{$formInputHeightSmall};\n }\n\n &[size=\"tiny\"] {\n --height: #{$formInputHeightTiny};\n --icon-text-margin: #{space('xsmall')};\n --padding: calc(#{space('xxsmall')} - 1px) #{space('medium')};\n }\n\n &[variant=\"secondary\"] {\n --color: #{$colorPrimary};\n --background-color: #{$colorWhite};\n --border-color: #{$colorPrimary60op};\n }\n\n &[variant=\"input\"] {\n --color: #{$formColor};\n --background-color: transparent;\n --border-color: #{$formBorderColor};\n\n --hover-color: #{$colorPrimaryHover};\n --hover-background-color: transparent;\n --hover-border-color: #{$colorPrimaryHover};\n }\n\n &[variant=\"tertiary\"] {\n --color: #{$colorPrimary};\n --background-color: transparent;\n --border-color: transparent;\n\n --hover-color: #{$colorPrimaryHover};\n --hover-background-color: #{$buttonTextHoverBackground};\n --hover-border-color: transparent;\n }\n\n &[active]:not([active=\"false\"]) {\n --color: #{$colorWhite};\n --background-color: #{$colorPrimaryHover};\n --border-color: #{$colorPrimaryHover};\n\n --hover-color: #{$colorWhite};\n --hover-background-color: #{$colorPrimaryHover};\n --hover-border-color: #{$colorPrimaryHover};\n }\n\n &[disabled]:not([disabled=\"false\"]),\n &[a11y-disabled]:not([a11y-disabled=\"false\"]) {\n --border-color: #{$colorGrey13};\n --background-color: #{$colorGrey13};\n\n --hover-border-color: #{$colorGrey13};\n --hover-background-color: #{$colorGrey13};\n }\n\n &[disabled]:not([disabled=\"false\"])[variant=\"secondary\"],\n &[disabled]:not([disabled=\"false\"])[variant=\"input\"],\n &[disabled]:not([disabled=\"false\"])[variant=\"tertiary\"],\n &[a11y-disabled]:not([a11y-disabled=\"false\"])[variant=\"secondary\"],\n &[a11y-disabled]:not([a11y-disabled=\"false\"])[variant=\"input\"],\n &[a11y-disabled]:not([a11y-disabled=\"false\"])[variant=\"tertiary\"] {\n --color: #{$colorGrey25};\n --border-color: #{$colorGrey13};\n --background-color: transparent;\n\n --hover-color: #{$colorGrey25};\n --hover-border-color: #{$colorGrey13};\n --hover-background-color: transparent;\n }\n}\n\n@keyframes stzh-button-effect-cta {\n\t0%,\n\t20%,\n\t50%,\n\t80%,\n\t100% {\n\t\ttransform: translateX(0);\n\t}\n\n\t40% {\n\t\ttransform: translateX(-8px);\n\t}\n\n\t60% {\n\t\ttransform: translateX(-4px);\n\t}\n}\n\n:host ::slotted(stzh-icon),\n.stzh-button__icon {\n --size: var(--icon-size);\n}\n\n.stzh-button {\n @include fontSize('milli');\n line-height: 1.25;\n font-family: inherit;\n position: relative;\n z-index: 0;\n overflow: visible;\n display: flex;\n align-items: center;\n justify-content: stretch;\n appearance: none;\n color: var(--color);\n padding: var(--padding);\n background-color: var(--background-color);\n transition-duration: $baseTransitionAnimationSpeed;\n transition-property: color, background-color, border-color;\n border-style: solid;\n border-width: var(--border-width);\n border-color: var(--border-color);\n cursor: var(--cursor);\n text-decoration-line: none;\n width: 100%;\n min-width: var(--height);\n min-height: var(--height);\n border-radius: var(--border-radius);\n text-align: left;\n box-shadow: var(--box-shadow);\n\n &:hover {\n border-color: var(--hover-border-color);\n background-color: var(--hover-background-color);\n color: var(--hover-color);\n }\n\n &__vhidden {\n @include visuallyhidden;\n }\n\n &__inner {\n display: flex;\n align-items: center;\n justify-content: center;\n flex-grow: 1;\n }\n\n &__icon-wrapper {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n width: auto;\n height: 1em;\n }\n\n &__text {\n @include wordWrap;\n white-space: var(--white-space);\n text-align: center;\n }\n\n &__icon-wrapper:not(:empty) + &__text:not(:empty),\n &__text:not(:empty) + &__icon-wrapper:not(:empty) {\n margin-left: var(--icon-text-margin);\n }\n\n &__badge {\n position: absolute;\n z-index: 1;\n top: 0;\n right: 0;\n }\n\n &__input {\n @include visuallyhiddenInput;\n }\n\n &__mark {\n @include radio__mark();\n width: 20px;\n height: 20px;\n margin-right: space('xsmall');\n border-color: currentColor;\n }\n\n &__check {\n @include radio__check();\n }\n\n /* Hover / Focus / Checked / Disabled of Radio Type */\n\n &__input:checked:hover ~ &__inner &__mark &__check,\n &__input:checked:focus ~ &__inner &__mark &__check {\n color: $colorPrimaryHover;\n }\n\n &:hover &__mark,\n &__input:focus:hover ~ &__inner &__mark,\n &__input:checked:hover ~ &__inner &__mark,\n &__input:checked:focus ~ &__inner &__mark {\n border-color: $colorPrimaryHover;\n }\n\n &__input:focus ~ &__inner &__mark,\n &__input:checked ~ &__inner &__mark {\n border-color: $colorPrimary;\n }\n\n &__input:checked ~ &__inner &__mark &__check {\n opacity: 1;\n }\n\n &--is-disabled &__input ~ &__inner &__mark &__check {\n color: $formDisabledColor;\n }\n\n &--is-disabled &__input ~ &__inner &__mark {\n border-color: $formDisabledBorderColor;\n }\n\n &--is-disabled &__mark {\n background-color: $formDisabledBackgroundColor;\n }\n\n /* Size variants */\n\n &--size-small,\n &--size-tiny {\n @include fontSize('micro');\n }\n\n /* Badge positioning variants */\n\n &--badge-position-button &__icon-wrapper {\n position: static;\n }\n\n &__badge,\n &--badge-position-button &__badge {\n top: calc(#{space('xsmall')} * -1);\n right: calc(#{space('xsmall')} * -1);\n }\n\n &--badge-position-icon#{&}--has-icon &__icon-wrapper {\n position: relative;\n }\n\n &--badge-position-icon#{&}--has-icon &__badge {\n top: calc(#{space('xsmall')} * -1);\n right: calc(#{space('small')} * -1);\n }\n\n &--badge-position-icon#{&}--has-icon#{&}--has-badge &__icon-wrapper:not(:empty) + &__text:not(:empty),\n &--badge-position-icon#{&}--has-icon#{&}--has-badge &__text:not(:empty) + &__icon-wrapper:not(:empty) {\n margin-left: var(--badge-icon-text-margin);\n }\n\n /* Variant if button only has icon */\n\n &--has-icon-only {\n width: var(--height);\n height: var(--height);\n padding: 0;\n }\n\n &--has-icon-only &__text {\n @include visuallyhidden;\n }\n\n /* Effect */\n\n &--effect-cta:hover &__icon-wrapper {\n\t\tanimation: stzh-button-effect-cta 1s;\n }\n\n /* Alignment variants */\n\n &--align-left &__inner {\n justify-content: flex-start;\n }\n\n &--align-right &__inner {\n justify-content: flex-end;\n }\n\n &--align-center &__inner {\n justify-content: center;\n }\n\n &--align-space-between &__inner {\n justify-content: space-between;\n }\n\n /* Disabled variant */\n\n &--is-disabled {\n cursor: not-allowed;\n }\n\n /* Focus */\n\n &.has-focus {\n outline-offset: 3px;\n }\n\n /* Default */\n\n &--default.has-focus {\n outline: var(--stzh-flyingfocus-color) solid 3px;\n }\n}\n","import {\n Component,\n Host,\n Method,\n Fragment,\n Element,\n h,\n Prop,\n Event,\n EventEmitter\n} from \"@stencil/core\";\n\nimport {\n StzhButtonFocusEvent,\n StzhButtonBlurEvent,\n StzhButtonChangeEvent\n} from \"../../index\";\n\nimport { hasSlot } from \"../../utils/utils\";\nimport { StzhLocaleComponent } from \"../../utils/translation-utils\";\n\n/**\n * @slot - Slot for label/text content\n * @slot icon - Slot for icon element\n */\n@Component({\n tag: \"stzh-button\",\n styleUrl: \"stzh-button.scss\",\n scoped: true\n})\nexport class StzhButton {\n /** Translation strings */\n @Prop() localization: StzhLocaleComponent;\n\n /** Display a badge aligned to button or icons */\n @Prop() badge: string = \"\";\n\n /** Badge type */\n @Prop({ reflect: true }) badgeType: \"default\" | \"success\" | \"warning\" | \"error\" | \"info\" = \"default\";\n\n /** Badge position */\n @Prop({ reflect: true }) badgePosition: \"icon\" | \"button\" = \"button\";\n\n /** Whether badge should be displayed empty */\n @Prop({ reflect: true }) badgeEmpty: boolean = false;\n\n /** Whether the button is full width */\n @Prop({ reflect: true }) fullwidth: boolean = false;\n\n /** Whether the button is rounded */\n @Prop({ reflect: true }) rounded: boolean = false;\n\n /** Whether the button is floating */\n @Prop({ reflect: true }) floating: boolean = false;\n\n /** Size variant */\n @Prop({ reflect: true }) size: \"default\" | \"small\" | \"tiny\" = \"default\";\n\n /** Text alignment */\n @Prop({ reflect: true }) textAlign: \"left\" | \"center\" | \"right\" | \"space-between\" | \"default\" = \"default\";\n\n /** Variant style */\n @Prop({ reflect: true }) variant: \"default\" | \"secondary\" | \"input\" | \"tertiary\" = \"default\";\n\n /** Icon (use instead of icon slot) */\n @Prop() icon: string = \"\";\n\n /** Icon Position */\n @Prop({ reflect: true }) iconPosition: \"left\" | \"right\" = \"left\";\n\n /** Checked status (if type is radio) */\n @Prop({ mutable: true, reflect: true }) checked: boolean = false;\n\n /** The name of the input element (if type is radio) */\n @Prop({ reflect: true }) name: string = \"\";\n\n /** The value of the input element (if type is radio) */\n @Prop({ mutable: true }) value: string = \"\";\n\n /** `href` if the button should be used as link */\n @Prop() href: string = \"\";\n\n /** Rel (if href is used) */\n @Prop() rel: string;\n\n /** Target if the button is used as link (if `href` used) */\n @Prop() target: string = \"\";\n\n /** Download attribute of link (if `href` used) */\n @Prop() download: string;\n\n /** Type of the button */\n @Prop() type: \"button\" | \"submit\" | \"reset\" | \"radio\" = \"button\";\n\n /** Whether the button is disabled */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /** Whether the button is active */\n @Prop({ reflect: true }) active: boolean = false;\n\n /** Label */\n @Prop() label: string = \"\";\n\n /** Effect/Animation used */\n @Prop() effect: \"default\" | \"cta\" = \"default\";\n\n /** Whether only an icon is used inside the button */\n @Prop({ reflect: true }) iconOnly: boolean = false;\n\n /** Access key of link (usually a number e.g. 1) */\n @Prop() linkAccesskey: string;\n\n /** Accessible label for screen readers to replace visible text */\n @Prop({ attribute: \"a11y-label\" }) a11yLabel: string;\n\n /** Id for element which describes the button (this will be overwritten if description prop or slot is used, used by stzh-radiogroup) */\n @Prop({ attribute: \"a11y-describedby\" }) a11yDescribedby: string = \"\";\n\n /** Aria expanded of link/button */\n @Prop({ reflect: true, attribute: \"a11y-expanded\" }) a11yExpanded: boolean;\n\n /** Aria disabled of link/button */\n @Prop({ reflect: true, attribute: \"a11y-disabled\" }) a11yDisabled: boolean;\n\n /** Aria controls of link/button */\n @Prop({ attribute: \"a11y-controls\" }) a11yControls: string;\n\n /** Tabindex of link/button */\n @Prop({ attribute: \"a11y-tabindex\" }) a11yTabindex: string;\n\n /**\n * For Adobe Analytics.\n * Will be rendered as value of `s-object-id` attribute to the link/button element.\n * Default value will be taken from `label` prop or default slot.\n */\n @Prop() analyticsId: string;\n\n @Element() element: HTMLStzhButtonElement;\n\n /** Focus button */\n @Method()\n async setFocus() {\n this.button.focus();\n }\n\n /** Focus event */\n @Event() stzhFocus: EventEmitter<StzhButtonFocusEvent>;\n\n /** Input blur event */\n @Event() stzhBlur: EventEmitter<StzhButtonBlurEvent>;\n\n /** Change event (only called if type is radio) */\n @Event() stzhChange: EventEmitter<StzhButtonChangeEvent>;\n\n private button: HTMLButtonElement | HTMLAnchorElement | HTMLLabelElement;\n private input: HTMLInputElement;\n private text: HTMLDivElement;\n private focusedByInput: boolean = false;\n\n private onInput = (event: InputEvent) => {\n this.checked = this.input.checked;\n this.stzhChange.emit({\n component: \"stzh-button\",\n originalEvent: event,\n value: this.value,\n checked: this.checked\n });\n }\n\n private onRootFocus = () => {\n if (!this.focusedByInput) {\n this.setFocus();\n }\n\n this.focusedByInput = false;\n }\n\n private onFocus = (event: FocusEvent) => {\n this.focusedByInput = true;\n\n const focusEvent = new FocusEvent(\"focus\", {\n view: window,\n bubbles: false,\n cancelable: false\n });\n\n this.element.dispatchEvent(focusEvent);\n this.stzhFocus.emit({\n component: \"stzh-button\",\n originalEvent: event\n });\n }\n\n private onBlur = (event: FocusEvent) => {\n const blurEvent = new FocusEvent(\"blur\", {\n view: window,\n bubbles: false,\n cancelable: false\n });\n\n this.element.dispatchEvent(blurEvent);\n this.stzhBlur.emit({\n component: \"stzh-button\",\n originalEvent: event\n });\n }\n\n private onClick = (event: MouseEvent) => {\n if (this.disabled) {\n event.stopPropagation();\n event.preventDefault();\n }\n }\n\n private renderIcon(iconUsed: boolean): HTMLInputElement {\n return (\n <div class=\"stzh-button__icon-wrapper\">\n {this.icon ?\n <stzh-icon class=\"stzh-button__icon\" name={this.icon}></stzh-icon>\n :\n <slot name=\"icon\"></slot>\n }\n {(this.badge || this.badgeEmpty) && this.badgePosition === \"icon\" && iconUsed &&\n <stzh-badge class=\"stzh-button__badge\" label={this.badge} type={this.badgeType}></stzh-badge>\n }\n </div>\n );\n }\n\n private renderContent(): HTMLDivElement {\n return (\n <div class=\"stzh-button__text\">\n {this.rel && this.rel.includes('external') && <div class=\"stzh-button__vhidden\">{this.localization.$globals.externalLinkLabel}</div>}\n {this.download && <div class=\"stzh-button__vhidden\">{this.localization.$globals.downloadLinkLabel}</div>}\n <div ref={(el) => (this.text = el as HTMLDivElement)}>{this.label ? this.label : <slot></slot>}</div>\n </div>\n );\n }\n\n private renderInner(iconUsed: boolean): DocumentFragment {\n return (\n <Fragment>\n <div\n class=\"stzh-button__inner\"\n onClick={this.onClick}\n >\n {this.type === \"radio\" &&\n <div class=\"stzh-button__mark\">\n <div class=\"stzh-button__check\"></div>\n </div>\n }\n {this.iconPosition === \"left\" && this.renderIcon(iconUsed)}\n {this.renderContent()}\n {this.iconPosition === \"right\" && this.renderIcon(iconUsed)}\n </div>\n {(this.badge || this.badgeEmpty) && (this.badgePosition === \"button\" || !iconUsed) &&\n <stzh-badge\n class=\"stzh-button__badge\"\n label={this.badge}\n type={this.badgeType}\n onClick={this.onClick}\n ></stzh-badge>\n }\n </Fragment>\n );\n }\n\n async componentWillLoad() {\n if (!this.localization) {\n this.localization = await window.stzhComponents.utils.fetchTranslations(this.element, \"button\");\n }\n }\n\n componentDidRender() {\n requestAnimationFrame(() => {\n this.button.setAttribute(\"s-object-id\", this.analyticsId || this.text.innerText);\n });\n }\n\n render() {\n const iconUsed: boolean = hasSlot(this.element, \"icon\") || !!this.icon;\n const classes = {\n \"stzh-button\": true,\n \"stzh-button--has-icon\": iconUsed,\n \"stzh-button--has-icon-only\": this.iconOnly,\n \"stzh-button--has-badge\": !!this.badge,\n \"stzh-button--is-floating\": this.floating,\n \"stzh-button--is-rounded\": this.rounded,\n \"stzh-button--is-fullwidth\": this.fullwidth,\n \"stzh-button--is-disabled\": this.disabled || this.a11yDisabled,\n \"stzh-button--is-active\": this.active,\n [`stzh-button--effect-${this.effect}`]: !!this.effect,\n [`stzh-button--badge-position-${this.badgePosition}`]: !!this.badgePosition,\n [`stzh-button--align-${this.textAlign}`]: !!this.textAlign,\n [`stzh-button--size-${this.size}`]: !!this.size,\n [`stzh-button--type-${this.type}`]: !!this.type,\n [`stzh-button--${this.variant}`]: !!this.variant\n };\n\n return (\n <Host tabindex={this.disabled ? null : \"-1\"} onFocus={this.onRootFocus}>\n {this.href ?\n <a\n ref={(el) => (this.button = el as HTMLAnchorElement)}\n href={this.disabled ? null : this.href}\n rel={this.rel}\n download={this.download}\n target={this.target}\n class={classes}\n aria-label={this.a11yLabel || null}\n aria-describedby={this.a11yDescribedby || null}\n aria-disabled={typeof this.a11yDisabled !== \"undefined\"\n ? (this.a11yDisabled ? \"true\" : \"false\") : null}\n aria-expanded={typeof this.a11yExpanded !== \"undefined\"\n ? (this.a11yExpanded ? \"true\" : \"false\") : null}\n aria-controls={this.a11yControls || null}\n accessKey={this.linkAccesskey}\n tabindex={this.a11yTabindex}\n onFocus={this.onFocus}\n onBlur={this.onBlur}\n onClick={this.onClick}\n >\n {this.renderInner(iconUsed)}\n </a>\n :\n this.type === \"radio\" ?\n <label\n ref={(el) => (this.button = el as HTMLLabelElement)}\n class={classes}\n onClick={this.onClick}\n >\n <input\n ref={(el) => (this.input = el as HTMLInputElement)}\n type=\"radio\"\n class=\"stzh-button__input\"\n name={this.name}\n value={this.value}\n checked={this.checked}\n disabled={this.disabled}\n aria-label={this.a11yLabel || null}\n aria-describedby={this.a11yDescribedby || null}\n aria-disabled={typeof this.a11yDisabled !== \"undefined\"\n ? (this.a11yDisabled ? \"true\" : \"false\") : null}\n aria-expanded={typeof this.a11yExpanded !== \"undefined\"\n ? (this.a11yExpanded ? \"true\" : \"false\") : null}\n aria-controls={this.a11yControls || null}\n accessKey={this.linkAccesskey}\n tabindex={this.a11yTabindex}\n onFocus={this.onFocus}\n onBlur={this.onBlur}\n onClick={this.onClick}\n onInput={this.onInput}\n />\n {this.renderInner(iconUsed)}\n </label>\n :\n <button\n ref={(el) => (this.button = el as HTMLButtonElement)}\n class={classes}\n type={this.type}\n disabled={this.disabled}\n aria-label={this.a11yLabel || null}\n aria-describedby={this.a11yDescribedby || null}\n aria-disabled={typeof this.a11yDisabled !== \"undefined\"\n ? (this.a11yDisabled ? \"true\" : \"false\") : null}\n aria-expanded={typeof this.a11yExpanded !== \"undefined\"\n ? (this.a11yExpanded ? \"true\" : \"false\") : null}\n aria-controls={this.a11yControls || null}\n accessKey={this.linkAccesskey}\n tabindex={this.a11yTabindex}\n onFocus={this.onFocus}\n onBlur={this.onBlur}\n onClick={this.onClick}\n >\n {this.renderInner(iconUsed)}\n </button>\n }\n </Host>\n );\n }\n}\n","/**\n * @prop --size: Border color\n *\n * @prop --stzh-icon-size-default: **Global**: Default icon size (default `var(--stzh-icon-size-small)`). [See available icon sizes here](/docs/tokens-icons--docs#sizes).\n */\n\n:host {\n --size: #{iconSize()};\n\n display: inline-flex;\n justify-content: center;\n align-items: center;\n color: currentColor;\n vertical-align: text-top;\n}\n\n.stzh-icon {\n width: var(--size);\n height: var(--size);\n}\n","import {\n Component,\n Host,\n h,\n Prop\n} from \"@stencil/core\";\n\nlet iconCounter = 0;\n\n@Component({\n tag: \"stzh-icon\",\n styleUrl: \"stzh-icon.scss\",\n scoped: true\n})\nexport class StzhIcon {\n /**\n * Icon which should be displayed\n * See the [icon overview](stzh-components/assets/svgsprites/symbol/sprite.symbol.html) for a list of all available icons.\n */\n @Prop() name: string = \"\";\n\n /**\n * Hidden icon title for screenreader\n * (usually not needed when e.g. inside links or buttons that have text)\n */\n @Prop({ attribute: 'a11y-title' }) a11yTitle: string = \"\";\n\n private iconId: string;\n\n componentWillLoad() {\n this.iconId = `stzh-icon-${iconCounter++}`;\n }\n\n render() {\n return (\n <Host>\n {this.name &&\n <svg\n class=\"stzh-icon\"\n role={this.a11yTitle ? 'img' : 'presentation'}\n aria-hidden={this.a11yTitle ? null : 'true'}\n focusable={this.a11yTitle ? 'true' : 'false'}\n aria-labelledby={this.a11yTitle ? `${this.iconId}-title` : null}\n >\n {this.a11yTitle &&\n <title id={`${this.iconId}-title`}>\n {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ss","StzhBadge","prototype","render","classes","_a","concat","this","type","h","Host","class","label","stzhButtonCss","StzhButton","focusedByInput","onInput","event","_this","checked","input","stzhChange","emit","component","originalEvent","value","onRootFocus","setFocus","onFocus","focusEvent","FocusEvent","view","window","bubbles","cancelable","element","dispatchEvent","stzhFocus","onBlur","blurEvent","stzhBlur","onClick","disabled","stopPropagation","preventDefault","class_1","button","focus","renderIcon","iconUsed","icon","name","badge","badgeEmpty","badgePosition","badgeType","renderContent","rel","includes","localization","$globals","externalLinkLabel","download","downloadLinkLabel","ref","el","text","renderInner","Fragment","iconPosition","componentWillLoad","stzhComponents","utils","fetchTranslations","_b","sent","componentDidRender","requestAnimationFrame","setAttribute","analyticsId","innerText","hasSlot","iconOnly","floating","rounded","fullwidth","a11yDisabled","active","effect","textAlign","size","variant","tabindex","href","target","a11yLabel","a11yDescribedby","a11yExpanded","a11yControls","accessKey","linkAccesskey","a11yTabindex","stzhIconCss","iconCounter","StzhIcon","iconId","role","a11yTitle","focusable","id"],"sources":["src/components/stzh-badge/stzh-badge.scss?tag=stzh-badge&encapsulation=scoped","src/components/stzh-badge/stzh-badge.tsx","src/components/stzh-button/stzh-button.scss?tag=stzh-button&encapsulation=scoped","src/components/stzh-button/stzh-button.tsx","src/components/stzh-icon/stzh-icon.scss?tag=stzh-icon&encapsulation=scoped","src/components/stzh-icon/stzh-icon.tsx"],"sourcesContent":[":host {\n --color: #{$colorWhite};\n --background-color: #{$baseColor};\n display: inline-flex;\n\n &[type=\"success\"] {\n --background-color: #{$colorTruegreen};\n }\n\n &[type=\"warning\"] {\n --color: #{$colorGrey87};\n --background-color: #{$colorWarning};\n }\n\n &[type=\"error\"] {\n --background-color: #{$colorError};\n }\n\n &[type=\"info\"] {\n --background-color: #{$colorZueriblue};\n }\n}\n\n.stzh-badge {\n @include badge;\n}\n","import {\n Component,\n Host,\n h,\n Prop,\n} from \"@stencil/core\";\n\n/**\n * @slot - Slot badge content\n */\n@Component({\n tag: \"stzh-badge\",\n styleUrl: \"stzh-badge.scss\",\n scoped: true\n})\nexport class StzhBadge {\n /** Text content of the badge */\n @Prop() label: string = \"\";\n\n /** Type */\n @Prop({ reflect: true }) type: \"default\" | \"success\" | \"warning\" | \"error\" | \"info\" = \"default\";\n\n render() {\n const classes = {\n \"stzh-badge\": true,\n [`stzh-badge--type-${this.type}`]: !!this.type\n };\n\n return (\n <Host>\n <div class={classes}>\n {this.label}\n </div>\n </Host>\n );\n }\n}\n","/**\n * @prop --height: Height of button\n * @prop --padding: Padding of button\n * @prop --border-radius: Border radius of button\n * @prop --color: Color of button\n * @prop --background-color: Background color of button\n * @prop --border-color: Border color of button\n * @prop --icon-size: Size of icon next to button\n * @prop --hover-color: Hover color of button\n * @prop --hover-background-color: Hover background color of button\n * @prop --hover-border-color: Hover border color of button\n * @prop --white-space: White space behaviour of button\n *\n * @prop --floating-position: Position when floating variant is used\n * @prop --floating-float: Floating direction when floating variant is used\n * @prop --floating-top: Space to the top when floating variant is used\n * @prop --floating-bottom: Space to the bottom when floating variant is used\n * @prop --floating-left: Space to the left when floating variant is used\n * @prop --floating-right: Space to the right when floating variant is used\n *\n * @prop --stzh-form-input-height: **Global**: Height of fields & buttons\n * @prop --stzh-form-input-small-height: **Global**: Height of fields & buttons when small variant is used\n * @prop --stzh-form-input-tiny-height: **Global**: Height of fields & buttons when tiny variant is used\n */\n\n:host {\n --color: #{$colorWhite};\n --background-color: #{$colorPrimary};\n --border-width: 1px;\n --border-color: #{$colorPrimary};\n --border-radius: #{$buttonBorderRadius};\n --height: #{$formInputHeight};\n --icon-size: #{iconSize('small')};\n --icon-text-margin: #{space('small')};\n --badge-icon-text-margin: calc(var(--icon-text-margin) + #{space('xxsmall')});\n --padding: calc(#{space('xsmall')} - 1px) #{space('xlarge')};\n --white-space: normal;\n --box-shadow: none;\n --cursor: pointer;\n\n --hover-color: #{$colorWhite};\n --hover-background-color: #{$colorPrimaryHover};\n --hover-border-color: #{$colorPrimaryHover};\n\n --floating-position: sticky;\n --floating-float: right;\n --floating-top: auto;\n --floating-bottom: #{space('medium')};\n --floating-left: auto;\n --floating-right: #{space('medium')};\n\n display: inline-block;\n\n @include mq($from: small) {\n --floating-bottom: #{space('xlarge')};\n --floating-right: #{space('xlarge')};\n }\n\n &[fullwidth]:not([fullwidth=\"false\"]) {\n width: 100%;\n display: block;\n }\n\n &[rounded]:not([rounded=\"false\"]) {\n --border-radius: var(--height);\n }\n\n &[floating]:not([floating=\"false\"]) {\n --box-shadow: #{$boxShadowOverlay};\n\n position: var(--floating-position);\n top: var(--floating-top);\n bottom: var(--floating-bottom);\n left: var(--floating-left);\n right: var(--floating-right);\n float: var(--floating-float);\n }\n\n &[size=\"small\"] {\n --height: #{$formInputHeightSmall};\n }\n\n &[size=\"tiny\"] {\n --height: #{$formInputHeightTiny};\n --icon-text-margin: #{space('xsmall')};\n --padding: calc(#{space('xxsmall')} - 1px) #{space('medium')};\n }\n\n &[variant=\"secondary\"] {\n --color: #{$colorPrimary};\n --background-color: #{$colorWhite};\n --border-color: #{$colorPrimary60op};\n }\n\n &[variant=\"input\"] {\n --color: #{$formColor};\n --background-color: transparent;\n --border-color: #{$formBorderColor};\n\n --hover-color: #{$colorPrimaryHover};\n --hover-background-color: transparent;\n --hover-border-color: #{$colorPrimaryHover};\n }\n\n &[variant=\"tertiary\"] {\n --color: #{$colorPrimary};\n --background-color: transparent;\n --border-color: transparent;\n\n --hover-color: #{$colorPrimaryHover};\n --hover-background-color: #{$buttonTextHoverBackground};\n --hover-border-color: transparent;\n }\n\n &[active]:not([active=\"false\"]) {\n --color: #{$colorWhite};\n --background-color: #{$colorPrimaryHover};\n --border-color: #{$colorPrimaryHover};\n\n --hover-color: #{$colorWhite};\n --hover-background-color: #{$colorPrimaryHover};\n --hover-border-color: #{$colorPrimaryHover};\n }\n\n &[disabled]:not([disabled=\"false\"]),\n &[a11y-disabled]:not([a11y-disabled=\"false\"]) {\n --border-color: #{$colorGrey13};\n --background-color: #{$colorGrey13};\n\n --hover-border-color: #{$colorGrey13};\n --hover-background-color: #{$colorGrey13};\n }\n\n &[disabled]:not([disabled=\"false\"])[variant=\"secondary\"],\n &[disabled]:not([disabled=\"false\"])[variant=\"input\"],\n &[disabled]:not([disabled=\"false\"])[variant=\"tertiary\"],\n &[a11y-disabled]:not([a11y-disabled=\"false\"])[variant=\"secondary\"],\n &[a11y-disabled]:not([a11y-disabled=\"false\"])[variant=\"input\"],\n &[a11y-disabled]:not([a11y-disabled=\"false\"])[variant=\"tertiary\"] {\n --color: #{$colorGrey25};\n --border-color: #{$colorGrey13};\n --background-color: transparent;\n\n --hover-color: #{$colorGrey25};\n --hover-border-color: #{$colorGrey13};\n --hover-background-color: transparent;\n }\n}\n\n@keyframes stzh-button-effect-cta {\n\t0%,\n\t20%,\n\t50%,\n\t80%,\n\t100% {\n\t\ttransform: translateX(0);\n\t}\n\n\t40% {\n\t\ttransform: translateX(-8px);\n\t}\n\n\t60% {\n\t\ttransform: translateX(-4px);\n\t}\n}\n\n:host ::slotted(stzh-icon),\n.stzh-button__icon {\n --size: var(--icon-size);\n}\n\n.stzh-button {\n @include fontSize('milli');\n line-height: 1.25;\n font-family: inherit;\n position: relative;\n z-index: 0;\n overflow: visible;\n display: flex;\n align-items: center;\n justify-content: stretch;\n appearance: none;\n color: var(--color);\n padding: var(--padding);\n background-color: var(--background-color);\n transition-duration: $baseTransitionAnimationSpeed;\n transition-property: color, background-color, border-color;\n border-style: solid;\n border-width: var(--border-width);\n border-color: var(--border-color);\n cursor: var(--cursor);\n text-decoration-line: none;\n width: 100%;\n min-width: var(--height);\n min-height: var(--height);\n border-radius: var(--border-radius);\n text-align: left;\n box-shadow: var(--box-shadow);\n\n &:hover {\n border-color: var(--hover-border-color);\n background-color: var(--hover-background-color);\n color: var(--hover-color);\n }\n\n &__vhidden {\n @include visuallyhidden;\n }\n\n &__inner {\n display: flex;\n align-items: center;\n justify-content: center;\n flex-grow: 1;\n }\n\n &__icon-wrapper {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n width: auto;\n height: 1em;\n }\n\n &__text {\n @include wordWrap;\n white-space: var(--white-space);\n text-align: center;\n }\n\n &__icon-wrapper:not(:empty) + &__text:not(:empty),\n &__text:not(:empty) + &__icon-wrapper:not(:empty) {\n margin-left: var(--icon-text-margin);\n }\n\n &__badge {\n position: absolute;\n z-index: 1;\n top: 0;\n right: 0;\n }\n\n &__input {\n @include visuallyhiddenInput;\n }\n\n &__mark {\n @include radio__mark();\n width: 20px;\n height: 20px;\n margin-right: space('xsmall');\n border-color: currentColor;\n }\n\n &__check {\n @include radio__check();\n }\n\n /* Hover / Focus / Checked / Disabled of Radio Type */\n\n &__input:checked:hover ~ &__inner &__mark &__check,\n &__input:checked:focus ~ &__inner &__mark &__check {\n color: $colorPrimaryHover;\n }\n\n &:hover &__mark,\n &__input:focus:hover ~ &__inner &__mark,\n &__input:checked:hover ~ &__inner &__mark,\n &__input:checked:focus ~ &__inner &__mark {\n border-color: $colorPrimaryHover;\n }\n\n &__input:focus ~ &__inner &__mark,\n &__input:checked ~ &__inner &__mark {\n border-color: $colorPrimary;\n }\n\n &__input:checked ~ &__inner &__mark &__check {\n opacity: 1;\n }\n\n &--is-disabled &__input ~ &__inner &__mark &__check {\n color: $formDisabledColor;\n }\n\n &--is-disabled &__input ~ &__inner &__mark {\n border-color: $formDisabledBorderColor;\n }\n\n &--is-disabled &__mark {\n background-color: $formDisabledBackgroundColor;\n }\n\n /* Size variants */\n\n &--size-small,\n &--size-tiny {\n @include fontSize('micro');\n }\n\n /* Badge positioning variants */\n\n &--badge-position-button &__icon-wrapper {\n position: static;\n }\n\n &__badge,\n &--badge-position-button &__badge {\n top: calc(#{space('xsmall')} * -1);\n right: calc(#{space('xsmall')} * -1);\n }\n\n &--badge-position-icon#{&}--has-icon &__icon-wrapper {\n position: relative;\n }\n\n &--badge-position-icon#{&}--has-icon &__badge {\n top: calc(#{space('xsmall')} * -1);\n right: calc(#{space('small')} * -1);\n }\n\n &--badge-position-icon#{&}--has-icon#{&}--has-badge &__icon-wrapper:not(:empty) + &__text:not(:empty),\n &--badge-position-icon#{&}--has-icon#{&}--has-badge &__text:not(:empty) + &__icon-wrapper:not(:empty) {\n margin-left: var(--badge-icon-text-margin);\n }\n\n /* Variant if button only has icon */\n\n &--has-icon-only {\n width: var(--height);\n height: var(--height);\n padding: 0;\n }\n\n &--has-icon-only &__text {\n @include visuallyhidden;\n }\n\n /* Effect */\n\n &--effect-cta:hover &__icon-wrapper {\n\t\tanimation: stzh-button-effect-cta 1s;\n }\n\n /* Alignment variants */\n\n &--align-left &__inner {\n justify-content: flex-start;\n }\n\n &--align-right &__inner {\n justify-content: flex-end;\n }\n\n &--align-center &__inner {\n justify-content: center;\n }\n\n &--align-space-between &__inner {\n justify-content: space-between;\n }\n\n /* Disabled variant */\n\n &--is-disabled {\n cursor: not-allowed;\n }\n\n /* Focus */\n\n &.has-focus {\n outline-offset: 3px;\n }\n\n /* Default */\n\n &--default.has-focus {\n outline: var(--stzh-flyingfocus-color) solid 3px;\n }\n}\n","import {\n Component,\n Host,\n Method,\n Fragment,\n Element,\n h,\n Prop,\n Event,\n EventEmitter\n} from \"@stencil/core\";\n\nimport {\n StzhButtonFocusEvent,\n StzhButtonBlurEvent,\n StzhButtonChangeEvent\n} from \"../../index\";\n\nimport { hasSlot } from \"../../utils/utils\";\nimport { StzhLocaleComponent } from \"../../utils/translation-utils\";\n\n/**\n * @slot - Slot for label/text content\n * @slot icon - Slot for icon element\n */\n@Component({\n tag: \"stzh-button\",\n styleUrl: \"stzh-button.scss\",\n scoped: true\n})\nexport class StzhButton {\n /** Translation strings */\n @Prop() localization: StzhLocaleComponent;\n\n /** Display a badge aligned to button or icons */\n @Prop() badge: string = \"\";\n\n /** Badge type */\n @Prop({ reflect: true }) badgeType: \"default\" | \"success\" | \"warning\" | \"error\" | \"info\" = \"default\";\n\n /** Badge position */\n @Prop({ reflect: true }) badgePosition: \"icon\" | \"button\" = \"button\";\n\n /** Whether badge should be displayed empty */\n @Prop({ reflect: true }) badgeEmpty: boolean = false;\n\n /** Whether the button is full width */\n @Prop({ reflect: true }) fullwidth: boolean = false;\n\n /** Whether the button is rounded */\n @Prop({ reflect: true }) rounded: boolean = false;\n\n /** Whether the button is floating */\n @Prop({ reflect: true }) floating: boolean = false;\n\n /** Size variant */\n @Prop({ reflect: true }) size: \"default\" | \"small\" | \"tiny\" = \"default\";\n\n /** Text alignment */\n @Prop({ reflect: true }) textAlign: \"left\" | \"center\" | \"right\" | \"space-between\" | \"default\" = \"default\";\n\n /** Variant style */\n @Prop({ reflect: true }) variant: \"default\" | \"secondary\" | \"input\" | \"tertiary\" = \"default\";\n\n /** Icon (use instead of icon slot) */\n @Prop() icon: string = \"\";\n\n /** Icon Position */\n @Prop({ reflect: true }) iconPosition: \"left\" | \"right\" = \"left\";\n\n /** Checked status (if type is radio) */\n @Prop({ mutable: true, reflect: true }) checked: boolean = false;\n\n /** The name of the input element (if type is radio) */\n @Prop({ reflect: true }) name: string = \"\";\n\n /** The value of the input element (if type is radio) */\n @Prop({ mutable: true }) value: string = \"\";\n\n /** `href` if the button should be used as link */\n @Prop() href: string = \"\";\n\n /** Rel (if href is used) */\n @Prop() rel: string;\n\n /** Target if the button is used as link (if `href` used) */\n @Prop() target: string = \"\";\n\n /** Download attribute of link (if `href` used) */\n @Prop() download: string;\n\n /** Type of the button */\n @Prop() type: \"button\" | \"submit\" | \"reset\" | \"radio\" = \"button\";\n\n /** Whether the button is disabled */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /** Whether the button is active */\n @Prop({ reflect: true }) active: boolean = false;\n\n /** Label */\n @Prop() label: string = \"\";\n\n /** Effect/Animation used */\n @Prop() effect: \"default\" | \"cta\" = \"default\";\n\n /** Whether only an icon is used inside the button */\n @Prop({ reflect: true }) iconOnly: boolean = false;\n\n /** Access key of link (usually a number e.g. 1) */\n @Prop() linkAccesskey: string;\n\n /** Accessible label for screen readers to replace visible text */\n @Prop({ attribute: \"a11y-label\" }) a11yLabel: string;\n\n /** Id for element which describes the button (this will be overwritten if description prop or slot is used, used by stzh-radiogroup) */\n @Prop({ attribute: \"a11y-describedby\" }) a11yDescribedby: string = \"\";\n\n /** Aria expanded of link/button */\n @Prop({ reflect: true, attribute: \"a11y-expanded\" }) a11yExpanded: boolean;\n\n /** Aria disabled of link/button */\n @Prop({ reflect: true, attribute: \"a11y-disabled\" }) a11yDisabled: boolean;\n\n /** Aria controls of link/button */\n @Prop({ attribute: \"a11y-controls\" }) a11yControls: string;\n\n /** Tabindex of link/button */\n @Prop({ attribute: \"a11y-tabindex\" }) a11yTabindex: string;\n\n /**\n * For Adobe Analytics.\n * Will be rendered as value of `s-object-id` attribute to the link/button element.\n * Default value will be taken from `label` prop or default slot.\n */\n @Prop() analyticsId: string;\n\n @Element() element: HTMLStzhButtonElement;\n\n /** Focus button */\n @Method()\n async setFocus() {\n this.button.focus();\n }\n\n /** Input focus event */\n @Event() stzhFocus: EventEmitter<StzhButtonFocusEvent>;\n\n /** Input blur event */\n @Event() stzhBlur: EventEmitter<StzhButtonBlurEvent>;\n\n /** Change event (only called if type is radio) */\n @Event() stzhChange: EventEmitter<StzhButtonChangeEvent>;\n\n private button: HTMLButtonElement | HTMLAnchorElement | HTMLLabelElement;\n private input: HTMLInputElement;\n private text: HTMLDivElement;\n private focusedByInput: boolean = false;\n\n private onInput = (event: InputEvent) => {\n this.checked = this.input.checked;\n this.stzhChange.emit({\n component: \"stzh-button\",\n originalEvent: event,\n value: this.value,\n checked: this.checked\n });\n }\n\n private onRootFocus = () => {\n if (!this.focusedByInput) {\n this.setFocus();\n }\n\n this.focusedByInput = false;\n }\n\n private onFocus = (event: FocusEvent) => {\n this.focusedByInput = true;\n\n const focusEvent = new FocusEvent(\"focus\", {\n view: window,\n bubbles: false,\n cancelable: false\n });\n\n this.element.dispatchEvent(focusEvent);\n this.stzhFocus.emit({\n component: \"stzh-button\",\n originalEvent: event\n });\n }\n\n private onBlur = (event: FocusEvent) => {\n const blurEvent = new FocusEvent(\"blur\", {\n view: window,\n bubbles: false,\n cancelable: false\n });\n\n this.element.dispatchEvent(blurEvent);\n this.stzhBlur.emit({\n component: \"stzh-button\",\n originalEvent: event\n });\n }\n\n private onClick = (event: MouseEvent) => {\n if (this.disabled) {\n event.stopPropagation();\n event.preventDefault();\n }\n }\n\n private renderIcon(iconUsed: boolean): HTMLInputElement {\n return (\n <div class=\"stzh-button__icon-wrapper\">\n {this.icon ?\n <stzh-icon class=\"stzh-button__icon\" name={this.icon}></stzh-icon>\n :\n <slot name=\"icon\"></slot>\n }\n {(this.badge || this.badgeEmpty) && this.badgePosition === \"icon\" && iconUsed &&\n <stzh-badge class=\"stzh-button__badge\" label={this.badge} type={this.badgeType}></stzh-badge>\n }\n </div>\n );\n }\n\n private renderContent(): HTMLDivElement {\n return (\n <div class=\"stzh-button__text\">\n {this.rel && this.rel.includes('external') && <div class=\"stzh-button__vhidden\">{this.localization.$globals.externalLinkLabel}</div>}\n {this.download && <div class=\"stzh-button__vhidden\">{this.localization.$globals.downloadLinkLabel}</div>}\n <div ref={(el) => (this.text = el as HTMLDivElement)}>{this.label ? this.label : <slot></slot>}</div>\n </div>\n );\n }\n\n private renderInner(iconUsed: boolean): DocumentFragment {\n return (\n <Fragment>\n <div\n class=\"stzh-button__inner\"\n onClick={this.onClick}\n >\n {this.type === \"radio\" &&\n <div class=\"stzh-button__mark\">\n <div class=\"stzh-button__check\"></div>\n </div>\n }\n {this.iconPosition === \"left\" && this.renderIcon(iconUsed)}\n {this.renderContent()}\n {this.iconPosition === \"right\" && this.renderIcon(iconUsed)}\n </div>\n {(this.badge || this.badgeEmpty) && (this.badgePosition === \"button\" || !iconUsed) &&\n <stzh-badge\n class=\"stzh-button__badge\"\n label={this.badge}\n type={this.badgeType}\n onClick={this.onClick}\n ></stzh-badge>\n }\n </Fragment>\n );\n }\n\n async componentWillLoad() {\n if (!this.localization) {\n this.localization = await window.stzhComponents.utils.fetchTranslations(this.element, \"button\");\n }\n }\n\n componentDidRender() {\n requestAnimationFrame(() => {\n this.button.setAttribute(\"s-object-id\", this.analyticsId || this.text.innerText);\n });\n }\n\n render() {\n const iconUsed: boolean = hasSlot(this.element, \"icon\") || !!this.icon;\n const classes = {\n \"stzh-button\": true,\n \"stzh-button--has-icon\": iconUsed,\n \"stzh-button--has-icon-only\": this.iconOnly,\n \"stzh-button--has-badge\": !!this.badge,\n \"stzh-button--is-floating\": this.floating,\n \"stzh-button--is-rounded\": this.rounded,\n \"stzh-button--is-fullwidth\": this.fullwidth,\n \"stzh-button--is-disabled\": this.disabled || this.a11yDisabled,\n \"stzh-button--is-active\": this.active,\n [`stzh-button--effect-${this.effect}`]: !!this.effect,\n [`stzh-button--badge-position-${this.badgePosition}`]: !!this.badgePosition,\n [`stzh-button--align-${this.textAlign}`]: !!this.textAlign,\n [`stzh-button--size-${this.size}`]: !!this.size,\n [`stzh-button--type-${this.type}`]: !!this.type,\n [`stzh-button--${this.variant}`]: !!this.variant\n };\n\n return (\n <Host tabindex={this.disabled ? null : \"-1\"} onFocus={this.onRootFocus}>\n {this.href ?\n <a\n ref={(el) => (this.button = el as HTMLAnchorElement)}\n href={this.disabled ? null : this.href}\n rel={this.rel}\n download={this.download}\n target={this.target}\n class={classes}\n aria-label={this.a11yLabel || null}\n aria-describedby={this.a11yDescribedby || null}\n aria-disabled={typeof this.a11yDisabled !== \"undefined\"\n ? (this.a11yDisabled ? \"true\" : \"false\") : null}\n aria-expanded={typeof this.a11yExpanded !== \"undefined\"\n ? (this.a11yExpanded ? \"true\" : \"false\") : null}\n aria-controls={this.a11yControls || null}\n accessKey={this.linkAccesskey}\n tabindex={this.a11yTabindex}\n onFocus={this.onFocus}\n onBlur={this.onBlur}\n onClick={this.onClick}\n >\n {this.renderInner(iconUsed)}\n </a>\n :\n this.type === \"radio\" ?\n <label\n ref={(el) => (this.button = el as HTMLLabelElement)}\n class={classes}\n onClick={this.onClick}\n >\n <input\n ref={(el) => (this.input = el as HTMLInputElement)}\n type=\"radio\"\n class=\"stzh-button__input\"\n name={this.name}\n value={this.value}\n checked={this.checked}\n disabled={this.disabled}\n aria-label={this.a11yLabel || null}\n aria-describedby={this.a11yDescribedby || null}\n aria-disabled={typeof this.a11yDisabled !== \"undefined\"\n ? (this.a11yDisabled ? \"true\" : \"false\") : null}\n aria-expanded={typeof this.a11yExpanded !== \"undefined\"\n ? (this.a11yExpanded ? \"true\" : \"false\") : null}\n aria-controls={this.a11yControls || null}\n accessKey={this.linkAccesskey}\n tabindex={this.a11yTabindex}\n onFocus={this.onFocus}\n onBlur={this.onBlur}\n onClick={this.onClick}\n onInput={this.onInput}\n />\n {this.renderInner(iconUsed)}\n </label>\n :\n <button\n ref={(el) => (this.button = el as HTMLButtonElement)}\n class={classes}\n type={this.type}\n disabled={this.disabled}\n aria-label={this.a11yLabel || null}\n aria-describedby={this.a11yDescribedby || null}\n aria-disabled={typeof this.a11yDisabled !== \"undefined\"\n ? (this.a11yDisabled ? \"true\" : \"false\") : null}\n aria-expanded={typeof this.a11yExpanded !== \"undefined\"\n ? (this.a11yExpanded ? \"true\" : \"false\") : null}\n aria-controls={this.a11yControls || null}\n accessKey={this.linkAccesskey}\n tabindex={this.a11yTabindex}\n onFocus={this.onFocus}\n onBlur={this.onBlur}\n onClick={this.onClick}\n >\n {this.renderInner(iconUsed)}\n </button>\n }\n </Host>\n );\n }\n}\n","/**\n * @prop --size: Border color\n *\n * @prop --stzh-icon-size-default: **Global**: Default icon size (default `var(--stzh-icon-size-small)`). [See available icon sizes here](/docs/tokens-icons--docs#sizes).\n */\n\n:host {\n --size: #{iconSize()};\n\n display: inline-flex;\n justify-content: center;\n align-items: center;\n color: currentColor;\n vertical-align: text-top;\n}\n\n.stzh-icon {\n width: var(--size);\n height: var(--size);\n}\n","import {\n Component,\n Host,\n h,\n Prop\n} from \"@stencil/core\";\n\nlet iconCounter = 0;\n\n@Component({\n tag: \"stzh-icon\",\n styleUrl: \"stzh-icon.scss\",\n scoped: true\n})\nexport class StzhIcon {\n /**\n * Icon which should be displayed\n * See the [icon overview](stzh-components/assets/svgsprites/symbol/sprite.symbol.html) for a list of all available icons.\n */\n @Prop() name: string = \"\";\n\n /**\n * Hidden icon title for screenreader\n * (usually not needed when e.g. inside links or buttons that have text)\n */\n @Prop({ attribute: 'a11y-title' }) a11yTitle: string = \"\";\n\n private iconId: string;\n\n componentWillLoad() {\n this.iconId = `stzh-icon-${iconCounter++}`;\n }\n\n render() {\n return (\n <Host>\n {this.name &&\n <svg\n class=\"stzh-icon\"\n role={this.a11yTitle ? 'img' : 'presentation'}\n aria-hidden={this.a11yTitle ? null : 'true'}\n focusable={this.a11yTitle ? 'true' : 'false'}\n aria-labelledby={this.a11yTitle ? `${this.iconId}-title` : null}\n >\n {this.a11yTitle &&\n <title id={`${this.iconId}-title`}>\n {this.a11yTitle}\n </title>\n }\n <use href={`#stzh-icon-${this.name}`}></use>\n </svg>\n }\n </Host>\n );\n }\n}\n"],"mappings":"ipDAAA,IAAMA,aAAe,27D,ICeRC,UAAS,W,kDAEI,G,UAG8D,S,CAEtFA,EAAAC,UAAAC,OAAA,W,MACE,IAAMC,GAAOC,EAAA,CACX,aAAc,MACdA,EAAC,oBAAAC,OAAoBC,KAAKC,SAAWD,KAAKC,K,GAG5C,OACEC,EAACC,KAAI,KACHD,EAAA,OAAKE,MAAOP,GACTG,KAAKK,O,WAhBM,G,6BCftB,IAAMC,cAAgB,yna,IC8BTC,WAAU,W,+LA+HbP,KAAAQ,eAA0B,MAE1BR,KAAAS,QAAU,SAACC,GACjBC,EAAKC,QAAUD,EAAKE,MAAMD,QAC1BD,EAAKG,WAAWC,KAAK,CACnBC,UAAW,cACXC,cAAeP,EACfQ,MAAOP,EAAKO,MACZN,QAASD,EAAKC,S,EAIVZ,KAAAmB,YAAc,WACpB,IAAKR,EAAKH,eAAgB,CACxBG,EAAKS,U,CAGPT,EAAKH,eAAiB,K,EAGhBR,KAAAqB,QAAU,SAACX,GACjBC,EAAKH,eAAiB,KAEtB,IAAMc,EAAa,IAA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AKkG,OAAS,aAAAnG,OAAaiG,c,EAG7BC,EAAAtG,UAAAC,OAAA,WACE,OACEM,EAACC,KAAI,KACFH,KAAK4C,MACJ1C,EAAA,OACEE,MAAM,YACN+F,KAAMnG,KAAKoG,UAAY,MAAQ,eAAc,cAChCpG,KAAKoG,UAAY,KAAO,OACrCC,UAAWrG,KAAKoG,UAAY,OAAS,QAAO,kBAC3BpG,KAAKoG,UAAY,GAAArG,OAAGC,KAAKkG,OAAM,UAAW,MAE1DlG,KAAKoG,WACJlG,EAAA,SAAOoG,GAAI,GAAAvG,OAAGC,KAAKkG,OAAM,WACtBlG,KAAKoG,WAGVlG,EAAA,OAAKoF,KAAM,cAAAvF,OAAcC,KAAK4C,S,WAnCrB,G"}
@@ -1,2 +1,2 @@
1
- var __awaiter=this&&this.__awaiter||function(e,t,s,i){function r(e){return e instanceof s?e:new s((function(t){t(e)}))}return new(s||(s=Promise))((function(s,o){function a(e){try{n(i.next(e))}catch(e){o(e)}}function l(e){try{n(i["throw"](e))}catch(e){o(e)}}function n(e){e.done?s(e.value):r(e.value).then(a,l)}n((i=i.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var s={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},i,r,o,a;return a={next:l(0),throw:l(1),return:l(2)},typeof Symbol==="function"&&(a[Symbol.iterator]=function(){return this}),a;function l(e){return function(t){return n([e,t])}}function n(l){if(i)throw new TypeError("Generator is already executing.");while(a&&(a=0,l[0]&&(s=0)),s)try{if(i=1,r&&(o=l[0]&2?r["return"]:l[0]?r["throw"]||((o=r["return"])&&o.call(r),0):r.next)&&!(o=o.call(r,l[1])).done)return o;if(r=0,o)l=[l[0]&2,o.value];switch(l[0]){case 0:case 1:o=l;break;case 4:s.label++;return{value:l[1],done:false};case 5:s.label++;r=l[1];l=[0];continue;case 7:l=s.ops.pop();s.trys.pop();continue;default:if(!(o=s.trys,o=o.length>0&&o[o.length-1])&&(l[0]===6||l[0]===2)){s=0;continue}if(l[0]===3&&(!o||l[1]>o[0]&&l[1]<o[3])){s.label=l[1];break}if(l[0]===6&&s.label<o[1]){s.label=o[1];o=l;break}if(o&&s.label<o[2]){s.label=o[2];s.ops.push(l);break}if(o[2])s.ops.pop();s.trys.pop();continue}l=t.call(e,s)}catch(e){l=[6,e];r=0}finally{i=o=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:true}}};import{r as registerInstance,c as createEvent,h,a as Host,g as getElement}from"./index-bfb5b569.js";import{i as isStzhElement}from"./utils-107fad0f.js";import{a as addMediaChangeListener,r as removeMediaChangeListener,m as media}from"./media-utils-ee5a59fa.js";import"./string-utils-e252977e.js";var stzhCarouselCss=".sc-stzh-carousel-h{font-family:var(--stzh-font-family-regular);font-weight:var(--stzh-font-weight-regular);font-style:normal;color:var(--stzh-base-color);-webkit-box-sizing:border-box;box-sizing:border-box;display:block}[hidden].sc-stzh-carousel-h{display:none}.sc-stzh-carousel-h *.sc-stzh-carousel,.sc-stzh-carousel-h *.sc-stzh-carousel::before,.sc-stzh-carousel-h *.sc-stzh-carousel::after{-webkit-box-sizing:border-box;box-sizing:border-box;text-underline-offset:var(--stzh-link-text-underline-offset);text-decoration-thickness:var(--stzh-link-text-decoration-thickness)}.sc-stzh-carousel-h .has-focus.sc-stzh-carousel{outline:var(--stzh-flyingfocus-color) solid 0.125rem;outline-offset:0.3125rem}.sc-stzh-carousel-h .stzh-fylingfocus-focused.sc-stzh-carousel{outline-style:none !important}.sc-stzh-carousel-h .stzh-fylingfocus-focused.sc-stzh-carousel::-moz-focus-inner{border:0 !important}.sc-stzh-carousel-h{--peek:calc(var(--peek-in, 0px) + var(--peek-out, 0px));--peek-out:1.25rem;--padding-top:0px;--padding-bottom:0px;--gutter:var(--stzh-space-xxxsmall);--snap-stop:always;--slides:1;--slide-size:calc((100% - (var(--slides) - 1) * var(--gutter)) / var(--slides))}@media screen and (min-width: 600px){.sc-stzh-carousel-h{--peek-out:2rem}}@media screen and (min-width: 1024px){.sc-stzh-carousel-h{--peek-out:0px}}[variant=cards].sc-stzh-carousel-h{--padding-top:0.25rem;--padding-bottom:0.25rem;--gutter:var(--stzh-space-xsmall)}@media screen and (min-width: 1024px){[variant=cards].sc-stzh-carousel-h{--peek-out:2.5rem;--gutter:var(--stzh-space-small)}}@media screen and (min-width: 1260px){[variant=cards].sc-stzh-carousel-h{--peek-out:5.5rem;--gutter:var(--stzh-space-medium)}}@media screen and (min-width: 1440px){[variant=cards].sc-stzh-carousel-h{--peek-out:calc((100vw - 78.75rem - var(--stzh-scrollbar-width, 0px)) / 2)}}.sc-stzh-carousel-h .sc-stzh-carousel-s>*{width:100%;height:100%;-ms-flex-negative:0;flex-shrink:0;scroll-snap-align:start;scroll-snap-stop:var(--snap-stop)}.sc-stzh-carousel-h .sc-stzh-carousel-s img{-webkit-user-drag:none;user-drag:none;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}.sc-stzh-carousel-h .sc-stzh-carousel-s>[slot=actions]{position:absolute;top:0;left:0;z-index:1;pointer-events:none;padding:0 var(--peek)}.sc-stzh-carousel-h .sc-stzh-carousel-s>[slot=actions] stzh-text{width:auto}.sc-stzh-carousel-h .sc-stzh-carousel-s>[slot=actions] stzh-button{pointer-events:all}.sc-stzh-carousel-h .sc-stzh-carousel-s>stzh-ratio[slot=actions] stzh-space,.sc-stzh-carousel-h .sc-stzh-carousel-s>stzh-ratio[slot=actions] stzh-hspace,.sc-stzh-carousel-h .sc-stzh-carousel-s>stzh-ratio[slot=actions] stzh-vspace{padding:var(--stzh-space-xsmall)}.sc-stzh-carousel-h .sc-stzh-carousel-s>stzh-ratio[slot=actions]{--background-color:transparent}.sc-stzh-carousel-h[variant=cards] .sc-stzh-carousel-s>[slot=actions]{position:relative;-ms-flex-order:1;order:1;margin-top:calc(var(--stzh-space-medium) - var(--padding-bottom))}.stzh-carousel.sc-stzh-carousel{position:relative;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;width:calc(100% + var(--peek-out) * 2);margin-left:calc(var(--peek-out) / -1);margin-right:calc(var(--peek-out) / -1)}.stzh-carousel__vhidden.sc-stzh-carousel{border:0;clip:rect(0 0 0 0);-webkit-clip-path:inset(100%);clip-path:inset(100%);width:0.0625rem;height:0.0625rem;overflow:hidden;padding:0;position:absolute}.stzh-carousel__scroll.sc-stzh-carousel{position:relative;grid-area:slides;display:grid;width:100%;height:100%;place-items:center;overflow-x:auto;overflow-y:visible;grid-auto-flow:column;grid-auto-columns:var(--slide-size);grid-auto-rows:100%;-moz-column-gap:var(--gutter);-webkit-column-gap:var(--gutter);column-gap:var(--gutter);-webkit-overflow-scrolling:touch;scrollbar-width:none;-ms-overflow-style:none;scroll-behavior:smooth;overscroll-behavior-x:contain;-webkit-scroll-snap-type:x mandatory;-ms-scroll-snap-type:x mandatory;scroll-snap-type:x mandatory;scroll-padding:0 var(--peek);padding:var(--padding-top) var(--peek) var(--padding-bottom)}@media (prefers-reduced-motion: reduce){.stzh-carousel__scroll.sc-stzh-carousel{scroll-behavior:auto}}.stzh-carousel__scroll.sc-stzh-carousel::-webkit-scrollbar{display:none}.stzh-carousel--is-draggable.sc-stzh-carousel .stzh-carousel__scroll.sc-stzh-carousel{cursor:-webkit-grab;cursor:grab}.stzh-carousel--is-dragging.sc-stzh-carousel .stzh-carousel__scroll.sc-stzh-carousel{cursor:-webkit-grabbing;cursor:grabbing}.stzh-carousel--is-disabled.sc-stzh-carousel .stzh-carousel__scroll.sc-stzh-carousel{cursor:not-allowed;overflow:hidden}";var reducedMotionMedia=window.matchMedia("(prefers-reduced-motion: reduce)");var carouselCounter=0;var StzhCarousel=function(){function e(e){var t=this;registerInstance(this,e);this.stzhSlideStart=createEvent(this,"stzhSlideStart",7);this.stzhSlidePassed=createEvent(this,"stzhSlidePassed",7);this.stzhSlideEnd=createEvent(this,"stzhSlideEnd",7);this.slideScrollLeft=0;this.scrolledByAutoplay=false;this.scrollTimeoutId=null;this.lastX=null;this.startX=null;this.startScrollLeft=null;this.disableTimeoutId=null;this.stoppedDragging=false;this.onReducedMotionMediaChange=function(){t.autoplayDisabledByMotionMedia=reducedMotionMedia.matches};this.onMouseenter=function(){t.autoplayDisabledByMouse=true};this.onMouseleave=function(){t.autoplayDisabledByMouse=false};this.onFocusin=function(){t.autoplayDisabledByFocus=true};this.onFocusout=function(){t.autoplayDisabledByFocus=false};this.onPreviousClick=function(){t.scrollToPreviousSnapPoint()};this.onNextClick=function(){t.scrollToNextSnapPoint()};this.onSlideResize=function(){if(t.scrollElement){t.itemSize=t.sizingMethod()}};this.onMutation=function(){if(!t.scrollElement){return}t.slideElements=Array.from(t.scrollElement.children);t.slideElements.forEach((function(e,s){e.setAttribute("role","group");e.setAttribute("aria-roledescription","slide");e.setAttribute("aria-label",t.localization.slideLabel.replace(/\{current\}/gi,(s+1).toString()).replace(/\{total\}/gi,t.slideElements.length.toString()))}));t.previousElements=Array.from(t.element.querySelectorAll("[data-stzh-carousel-previous]"));t.nextElements=Array.from(t.element.querySelectorAll("[data-stzh-carousel-next]"));t.navigationTextElements=Array.from(t.element.querySelectorAll("[data-stzh-carousel-navigation-text]"))};this.onScroll=function(){if(t.scrollTimeoutId===null){var e=t.scrollElement.scrollLeft>t.slideScrollLeft?1:-1;t.scrolling=true;if(!t.scrolledByAutoplay){t.autoplay=false}t.stzhSlideStart.emit({component:"stzh-carousel",index:t.slide+e})}if(t.slide!==t.calculateSlide()){t.update();t.stzhSlidePassed.emit({component:"stzh-carousel",index:t.slide})}t.scrollTimeoutId&&window.clearTimeout(t.scrollTimeoutId);t.scrollTimeoutId=window.setTimeout(t.onScrollEnd,t.scrollTimeout)};this.onScrollEnd=function(){t.scrollTimeoutId=null;t.update();t.scrolling=false;t.scrolledByAutoplay=false;if(t.stoppedDragging){t.stoppedDragging=false;t.scrollElement.style.removeProperty("scroll-behavior");t.scrollElement.style.removeProperty("scroll-snap-type")}if(t.tabThrough||t.variant==="cards"){t.ariaLive=""}else{t.ariaLive=(t.currentSlides>1?t.localization.slidesLabel:t.localization.slideLabel).replace(/\{(current|from)\}/gi,(t.slide+1).toString()).replace(/\{to\}/gi,(t.slide+t.currentSlides).toString()).replace(/\{total\}/gi,t.slideElements.length.toString())}t.stzhSlideEnd.emit({component:"stzh-carousel",index:t.slide})};this.onMediaChange=function(){var e=media("ultra").matches;var s=media("large").matches;var i=media("medium").matches;var r=media("small").matches;if(e&&t.slidesUltra!==0){t.currentSlides=t.slidesUltra}else if(s&&t.slidesLarge!==0){t.currentSlides=t.slidesLarge}else if(i&&t.slidesMedium!==0){t.currentSlides=t.slidesMedium}else if(r&&t.slidesSmall!==0){t.currentSlides=t.slidesSmall}else{t.currentSlides=t.slides}t.currentSwipeSlides=t.currentSlides};this.mouseMove=function(e){var s=t.lastX-e.clientX;t.lastX=e.clientX;t.scrollElement.scrollLeft+=s};this.startDragging=function(e){e.preventDefault();t.disableTimeoutId&&window.clearTimeout(t.disableTimeoutId);t.disableTimeoutId=null;t.startX=t.lastX=e.clientX;t.startScrollLeft=t.scrollElement.scrollLeft;t.scrollElement.style.setProperty("scroll-behavior","auto");t.scrollElement.style.setProperty("scroll-snap-type","unset");t.dragging=true;t.autoplay=false;window.addEventListener("mousemove",t.mouseMove);window.addEventListener("mouseup",t.stopDragging,{capture:true});window.addEventListener("click",t.checkClick,{capture:true})};this.stopDragging=function(e){e.preventDefault();var s=Math.abs(t.startX-t.lastX);var i=s>t.distanceQuickSwipe;var r=t.lastX>t.startX?1:-1;t.dragging=false;var o=t.scrollElement.scrollLeft;t.scrollElement.style.removeProperty("scroll-snap-type");var a=t.scrollElement.scrollLeft;t.scrollElement.style.setProperty("scroll-snap-type","unset");t.scrollElement.scrollTo({left:o,behavior:"auto"});if(a!==t.startScrollLeft||!i){t.scrollElement.scrollTo({left:a,behavior:reducedMotionMedia.matches?"auto":"smooth"})}else if(r===1){t.slideToPrevious()}else{t.slideToNext()}window.removeEventListener("mousemove",t.mouseMove);window.removeEventListener("mouseup",t.stopDragging,{capture:true});t.stoppedDragging=true};this.checkClick=function(e){var s=Math.abs(t.startX-t.lastX);var i=s>t.distancePreventClick;if(i){e.preventDefault()}t.lastX=null;window.removeEventListener("click",t.checkClick,{capture:true})};this.autoplayInterval=function(){t.scrolledByAutoplay=true;if(t.hasReachedLastSlide()){t.slideTo(0)}else{t.slideToNext()}};this.localization=undefined;this.variant="default";this.disabled=false;this.slides=1;this.slidesSmall=0;this.slidesMedium=0;this.slidesLarge=0;this.slidesUltra=0;this.slide=0;this.autoplay=false;this.tabThrough=false;this.preventMouseDrag=false;this.scrollTimeout=100;this.autoplayTimeout=3e3;this.distanceQuickSwipe=40;this.distancePreventClick=6;this.autoplayRunning=false;this.autoplayDisabledByMotionMedia=false;this.autoplayDisabledByMouse=false;this.autoplayDisabledByFocus=false;this.dragging=false;this.scrolling=false;this.ariaLive="";this.currentSlides=1;this.currentSwipeSlides=1;this.slideElements=[];this.previousElements=[];this.nextElements=[];this.navigationTextElements=[]}e.prototype.slideTo=function(e,t){if(t===void 0){t="smooth"}return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(s){this.scrollToSlide(e,t);return[2]}))}))};e.prototype.slideToPrevious=function(e){if(e===void 0){e="smooth"}return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.scrollToPreviousSnapPoint(e);return[2]}))}))};e.prototype.slideToNext=function(e){if(e===void 0){e="smooth"}return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.scrollToNextSnapPoint(e);return[2]}))}))};e.prototype.disabledWatcher=function(){if(this.disabled){this.scrollElement&&this.scrollElement.removeEventListener("scroll",this.onScroll);this.scrollTimeoutId&&window.clearTimeout(this.scrollTimeoutId);this.scrollTimeoutId=null;this.element.removeEventListener("mouseenter",this.onMouseenter);this.element.removeEventListener("mouseleave",this.onMouseleave);this.element.removeEventListener("focusin",this.onFocusin);this.element.removeEventListener("focusout",this.onFocusout);this.onReducedMotionMediaChange();reducedMotionMedia&&reducedMotionMedia.removeEventListener("change",this.onReducedMotionMediaChange)}else{this.scrollElement&&this.scrollElement.addEventListener("scroll",this.onScroll,{passive:true});this.element.addEventListener("mouseenter",this.onMouseenter);this.element.addEventListener("mouseleave",this.onMouseleave);this.element.addEventListener("focusin",this.onFocusin);this.element.addEventListener("focusout",this.onFocusout);reducedMotionMedia&&reducedMotionMedia.addEventListener("change",this.onReducedMotionMediaChange)}};e.prototype.preventMouseDragWatcher=function(){if(this.preventMouseDrag||this.disabled){this.disableTimeoutId&&window.clearTimeout(this.disableTimeoutId);this.disableTimeoutId=null;this.scrollElement&&this.scrollElement.removeEventListener("mousedown",this.startDragging);this.lastX=null}else{this.scrollElement&&this.scrollElement.addEventListener("mousedown",this.startDragging)}};e.prototype.autoplayRunningWatcher=function(){if(!this.autoplay||this.disabled||this.autoplayDisabledByMotionMedia||this.autoplayDisabledByMouse||this.autoplayDisabledByFocus){this.autoplayIntervalId&&window.clearInterval(this.autoplayIntervalId);this.autoplayIntervalId=null;this.autoplayRunning=false}else{this.autoplayIntervalId&&window.clearInterval(this.autoplayIntervalId);this.autoplayIntervalId=window.setInterval(this.autoplayInterval,this.autoplayTimeout);this.autoplayRunning=true}};e.prototype.snapAlignWatcher=function(){var e=this;this.slideElements.forEach((function(t,s){var i=(s-e.currentSwipeSlides)%e.currentSwipeSlides===0;if(i){t.style.removeProperty("scroll-snap-align")}else{t.style.setProperty("scroll-snap-align","none")}}))};e.prototype.inertWatcher=function(){var e=this;this.slideElements.forEach((function(t,s){var i=e.tabThrough||e.variant==="cards"||s>=e.slide&&s<e.slide+e.currentSlides;t.inert=!i;if(i){t.removeAttribute("aria-hidden")}else{t.setAttribute("aria-hidden",i?"false":"true")}}))};e.prototype.prevNextNavigationWatcher=function(){var e=this.tabThrough||this.variant==="cards";var t=function(t){var s=isStzhElement(t);if(e){t.setAttribute("aria-hidden","true");t.setAttribute(s?"a11y-tabindex":"tabindex","-1")}else{t.removeAttribute("aria-hidden");t.removeAttribute(s?"a11y-tabindex":"tabindex")}};this.nextElements.forEach(t);this.previousElements.forEach(t)};e.prototype.prevNextHiddenWatcher=function(){var e=this.slideElements.length<=this.currentSlides;var t=function(t){if(e){t.setAttribute("hidden","")}else{t.removeAttribute("hidden")}};this.navigationTextElements.forEach(t);this.nextElements.forEach(t);this.previousElements.forEach(t)};e.prototype.nextPrevDisabledWatcher=function(){if(!this.scrollElement){return}var e=this.slide===0;var t=this.hasReachedLastSlide();this.nextElements.forEach((function(e){var s=isStzhElement(e);e.setAttribute(s?"a11y-disabled":"aria-disabled",t?"true":"false")}));this.previousElements.forEach((function(t){var s=isStzhElement(t);t.setAttribute(s?"a11y-disabled":"aria-disabled",e?"true":"false")}))};e.prototype.nextElementsWatcher=function(){var e=this;this.nextElements.forEach((function(t){var s=isStzhElement(t);t.addEventListener("click",e.onNextClick);t.setAttribute(s?"a11y-controls":"aria-controls","".concat(e.carouselId,"-scroll"))}))};e.prototype.previousElementsWatcher=function(){var e=this;this.previousElements.forEach((function(t){var s=isStzhElement(t);t.addEventListener("click",e.onPreviousClick);t.setAttribute(s?"a11y-controls":"aria-controls","".concat(e.carouselId,"-scroll"))}))};e.prototype.scrollToSlide=function(e,t){if(t===void 0){t="smooth"}if(this.disabled){return}this.scrollElement.scrollTo({left:e*this.itemSize,behavior:reducedMotionMedia.matches?"auto":t})};e.prototype.sizingMethod=function(){var e=window.getComputedStyle(this.scrollElement);return(this.scrollElement.firstElementChild||this.scrollElement).offsetWidth+parseInt(e.getPropertyValue("column-gap"),10)};e.prototype.calculateSlide=function(){return Math.floor(this.scrollElement.scrollLeft/this.itemSize)};e.prototype.scrollToPreviousSnapPoint=function(e){if(e===void 0){e="smooth"}if(this.disabled){return}var t=this.slide;var s=false;while(!s&&t>0){t=t-1;s=(t-this.currentSwipeSlides)%this.currentSwipeSlides===0}this.slideTo(t,e)};e.prototype.scrollToNextSnapPoint=function(e){if(e===void 0){e="smooth"}if(this.disabled){return}this.slideTo(this.slide+this.currentSwipeSlides,e)};e.prototype.update=function(){this.slide=this.calculateSlide();this.slideScrollLeft=this.slide*this.itemSize;this.onMutation()};e.prototype.hasReachedLastSlide=function(){var e=this.scrollElement,t=e.scrollLeft,s=e.offsetWidth,i=e.scrollWidth;return Math.ceil(t+s)>=i};e.prototype.componentWillLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e;return __generator(this,(function(t){switch(t.label){case 0:this.carouselId="stzh-carousel-".concat(carouselCounter++);this.onMediaChange();if(!!this.localization)return[3,2];e=this;return[4,window.stzhComponents.utils.fetchTranslations(this.element,"carousel")];case 1:e.localization=t.sent();t.label=2;case 2:return[2]}}))}))};e.prototype.componentDidLoad=function(){this.itemSize=this.sizingMethod();this.update();this.disabledWatcher();this.preventMouseDragWatcher();this.autoplayRunningWatcher()};e.prototype.connectedCallback=function(){addMediaChangeListener(this.onMediaChange);this.resizeObserver=new ResizeObserver(this.onSlideResize);this.resizeObserver.observe(this.element);this.mutationObserver=new MutationObserver(this.onMutation);this.mutationObserver.observe(this.element,{childList:true,subtree:true})};e.prototype.disconnectedCallback=function(){this.scrollTimeoutId&&window.clearTimeout(this.scrollTimeoutId);this.scrollTimeoutId=null;this.disabled=true;removeMediaChangeListener(this.onMediaChange);if(this.resizeObserver){this.resizeObserver.disconnect()}if(this.mutationObserver){this.mutationObserver.disconnect()}};e.prototype.render=function(){var e=this;var t={"stzh-carousel":true,"stzh-carousel--is-disabled":this.disabled,"stzh-carousel--is-draggable":!this.preventMouseDrag,"stzh-carousel--is-dragging":this.dragging,"stzh-carousel--is-scrolling":this.scrolling,"stzh-carousel--has-autoplay":this.autoplay,"stzh-carousel--is-autoplay-running":this.autoplayRunning,"stzh-carousel--is-autoplay-disabled-by-motion-media":this.autoplayDisabledByMotionMedia,"stzh-carousel--is-autoplay-disabled-by-mouse":this.autoplayDisabledByMouse,"stzh-carousel--is-autoplay-disabled-by-focus":this.autoplayDisabledByFocus};return h(Host,{"aria-roledescription":"carousel",style:{"--slides":this.currentSlides.toString()}},h("div",{class:t},h("slot",{name:"actions"}),h("div",{class:"stzh-carousel__vhidden","aria-live":this.autoplayDisabledByFocus||this.autoplayDisabledByMouse?"polite":"off"},this.ariaLive),h("div",{ref:function(t){return e.scrollElement=t},id:"".concat(this.carouselId,"-scroll"),class:"stzh-carousel__scroll"},h("slot",null))))};Object.defineProperty(e.prototype,"element",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{disabled:["disabledWatcher","preventMouseDragWatcher","autoplayRunningWatcher"],preventMouseDrag:["preventMouseDragWatcher"],autoplay:["autoplayRunningWatcher"],autoplayDisabledByMotionMedia:["autoplayRunningWatcher"],autoplayDisabledByMouse:["autoplayRunningWatcher"],autoplayDisabledByFocus:["autoplayRunningWatcher"],autoplayTimeout:["autoplayRunningWatcher"],slideElements:["snapAlignWatcher","inertWatcher","prevNextHiddenWatcher","nextPrevDisabledWatcher"],currentSwipeSlides:["snapAlignWatcher"],slide:["inertWatcher","nextPrevDisabledWatcher"],variant:["inertWatcher","prevNextNavigationWatcher"],currentSlides:["inertWatcher","prevNextHiddenWatcher","nextPrevDisabledWatcher"],tabThrough:["inertWatcher","prevNextNavigationWatcher"],nextElements:["prevNextNavigationWatcher","prevNextHiddenWatcher","nextPrevDisabledWatcher","nextElementsWatcher"],previousElements:["prevNextNavigationWatcher","prevNextHiddenWatcher","nextPrevDisabledWatcher","previousElementsWatcher"],navigationTextElements:["prevNextHiddenWatcher"]}},enumerable:false,configurable:true});return e}();StzhCarousel.style=stzhCarouselCss;export{StzhCarousel as stzh_carousel};
1
+ var __awaiter=this&&this.__awaiter||function(e,t,s,i){function r(e){return e instanceof s?e:new s((function(t){t(e)}))}return new(s||(s=Promise))((function(s,o){function a(e){try{n(i.next(e))}catch(e){o(e)}}function l(e){try{n(i["throw"](e))}catch(e){o(e)}}function n(e){e.done?s(e.value):r(e.value).then(a,l)}n((i=i.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var s={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},i,r,o,a;return a={next:l(0),throw:l(1),return:l(2)},typeof Symbol==="function"&&(a[Symbol.iterator]=function(){return this}),a;function l(e){return function(t){return n([e,t])}}function n(l){if(i)throw new TypeError("Generator is already executing.");while(a&&(a=0,l[0]&&(s=0)),s)try{if(i=1,r&&(o=l[0]&2?r["return"]:l[0]?r["throw"]||((o=r["return"])&&o.call(r),0):r.next)&&!(o=o.call(r,l[1])).done)return o;if(r=0,o)l=[l[0]&2,o.value];switch(l[0]){case 0:case 1:o=l;break;case 4:s.label++;return{value:l[1],done:false};case 5:s.label++;r=l[1];l=[0];continue;case 7:l=s.ops.pop();s.trys.pop();continue;default:if(!(o=s.trys,o=o.length>0&&o[o.length-1])&&(l[0]===6||l[0]===2)){s=0;continue}if(l[0]===3&&(!o||l[1]>o[0]&&l[1]<o[3])){s.label=l[1];break}if(l[0]===6&&s.label<o[1]){s.label=o[1];o=l;break}if(o&&s.label<o[2]){s.label=o[2];s.ops.push(l);break}if(o[2])s.ops.pop();s.trys.pop();continue}l=t.call(e,s)}catch(e){l=[6,e];r=0}finally{i=o=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:true}}};import{r as registerInstance,c as createEvent,h,a as Host,g as getElement}from"./index-bfb5b569.js";import{i as isStzhElement}from"./utils-107fad0f.js";import{a as addMediaChangeListener,r as removeMediaChangeListener,m as media}from"./media-utils-ee5a59fa.js";import"./string-utils-e252977e.js";var stzhCarouselCss=".sc-stzh-carousel-h{font-family:var(--stzh-font-family-regular);font-weight:var(--stzh-font-weight-regular);font-style:normal;color:var(--stzh-base-color);-webkit-box-sizing:border-box;box-sizing:border-box;display:block}[hidden].sc-stzh-carousel-h{display:none}.sc-stzh-carousel-h *.sc-stzh-carousel,.sc-stzh-carousel-h *.sc-stzh-carousel::before,.sc-stzh-carousel-h *.sc-stzh-carousel::after{-webkit-box-sizing:border-box;box-sizing:border-box;text-underline-offset:var(--stzh-link-text-underline-offset);text-decoration-thickness:var(--stzh-link-text-decoration-thickness)}.sc-stzh-carousel-h .has-focus.sc-stzh-carousel{outline:var(--stzh-flyingfocus-color) solid 0.125rem;outline-offset:0.3125rem}.sc-stzh-carousel-h .stzh-fylingfocus-focused.sc-stzh-carousel{outline-style:none !important}.sc-stzh-carousel-h .stzh-fylingfocus-focused.sc-stzh-carousel::-moz-focus-inner{border:0 !important}.sc-stzh-carousel-h{--peek:calc(var(--peek-in, 0px) + var(--peek-out, 0px));--peek-out:1.25rem;--padding-top:0px;--padding-bottom:0px;--gutter:var(--stzh-space-xxxsmall);--snap-stop:always;--slides:1;--slide-size:calc((100% - (var(--slides) - 1) * var(--gutter)) / var(--slides))}@media screen and (min-width: 600px){.sc-stzh-carousel-h{--peek-out:2rem}}@media screen and (min-width: 1024px){.sc-stzh-carousel-h{--peek-out:0px}}.sc-stzh-carousel-h .sc-stzh-carousel-s>*{width:100%;height:100%;-ms-flex-negative:0;flex-shrink:0;scroll-snap-align:start;scroll-snap-stop:var(--snap-stop)}.sc-stzh-carousel-h .sc-stzh-carousel-s img{-webkit-user-drag:none;user-drag:none;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}.sc-stzh-carousel-h .sc-stzh-carousel-s>[slot=actions]{position:absolute;top:0;left:0;z-index:1;pointer-events:none;padding:0 var(--peek)}.sc-stzh-carousel-h .sc-stzh-carousel-s>[slot=actions] stzh-text{width:auto}.sc-stzh-carousel-h .sc-stzh-carousel-s>[slot=actions] stzh-button{pointer-events:all}.sc-stzh-carousel-h .sc-stzh-carousel-s>stzh-ratio[slot=actions] stzh-space,.sc-stzh-carousel-h .sc-stzh-carousel-s>stzh-ratio[slot=actions] stzh-hspace,.sc-stzh-carousel-h .sc-stzh-carousel-s>stzh-ratio[slot=actions] stzh-vspace{padding:var(--stzh-space-xsmall)}.sc-stzh-carousel-h .sc-stzh-carousel-s>stzh-ratio[slot=actions]{--background-color:transparent}[variant=cards].sc-stzh-carousel-h{--padding-top:0.25rem;--padding-bottom:0.25rem;--gutter:var(--stzh-space-xsmall)}@media screen and (min-width: 1024px){[variant=cards].sc-stzh-carousel-h{--peek-out:2.5rem;--gutter:var(--stzh-space-small)}}@media screen and (min-width: 1260px){[variant=cards].sc-stzh-carousel-h{--peek-out:5.5rem;--gutter:var(--stzh-space-medium)}}@media screen and (min-width: 1440px){[variant=cards].sc-stzh-carousel-h{--peek-out:calc((100vw - 78.75rem - var(--stzh-scrollbar-width, 0px)) / 2)}}.sc-stzh-carousel-h[variant=cards] .sc-stzh-carousel-s>[slot=actions]{position:relative;-ms-flex-order:1;order:1;margin-top:calc(var(--stzh-space-medium) - var(--padding-bottom))}[no-peek].sc-stzh-carousel-h:not([no-peek=false]){--peek-out:0px;--peek-in:0px}.stzh-carousel.sc-stzh-carousel{position:relative;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;width:calc(100% + var(--peek-out) * 2);margin-left:calc(var(--peek-out) / -1);margin-right:calc(var(--peek-out) / -1)}.stzh-carousel__vhidden.sc-stzh-carousel{border:0;clip:rect(0 0 0 0);-webkit-clip-path:inset(100%);clip-path:inset(100%);width:0.0625rem;height:0.0625rem;overflow:hidden;padding:0;position:absolute}.stzh-carousel__scroll.sc-stzh-carousel{position:relative;grid-area:slides;display:grid;width:100%;height:100%;place-items:center;overflow-x:auto;overflow-y:visible;grid-auto-flow:column;grid-auto-columns:var(--slide-size);grid-auto-rows:100%;-moz-column-gap:var(--gutter);-webkit-column-gap:var(--gutter);column-gap:var(--gutter);-webkit-overflow-scrolling:touch;scrollbar-width:none;-ms-overflow-style:none;scroll-behavior:smooth;overscroll-behavior-x:contain;-webkit-scroll-snap-type:x mandatory;-ms-scroll-snap-type:x mandatory;scroll-snap-type:x mandatory;scroll-padding:0 var(--peek);padding:var(--padding-top) var(--peek) var(--padding-bottom)}@media (prefers-reduced-motion: reduce){.stzh-carousel__scroll.sc-stzh-carousel{scroll-behavior:auto}}.stzh-carousel__scroll.sc-stzh-carousel::-webkit-scrollbar{display:none}.stzh-carousel--is-draggable.sc-stzh-carousel .stzh-carousel__scroll.sc-stzh-carousel{cursor:-webkit-grab;cursor:grab}.stzh-carousel--is-dragging.sc-stzh-carousel .stzh-carousel__scroll.sc-stzh-carousel{cursor:-webkit-grabbing;cursor:grabbing}.stzh-carousel--is-disabled.sc-stzh-carousel .stzh-carousel__scroll.sc-stzh-carousel{cursor:not-allowed;overflow:hidden}.stzh-carousel--is-non-interactive.sc-stzh-carousel{pointer-events:none;-ms-touch-action:none;touch-action:none}";var reducedMotionMedia=window.matchMedia("(prefers-reduced-motion: reduce)");var carouselCounter=0;var StzhCarousel=function(){function e(e){var t=this;registerInstance(this,e);this.stzhSlideStart=createEvent(this,"stzhSlideStart",7);this.stzhSlidePassed=createEvent(this,"stzhSlidePassed",7);this.stzhSlideEnd=createEvent(this,"stzhSlideEnd",7);this.slideScrollLeft=0;this.scrolledByAutoplay=false;this.scrollTimeoutId=null;this.lastX=null;this.startX=null;this.startScrollLeft=null;this.disableTimeoutId=null;this.stoppedDragging=false;this.onReducedMotionMediaChange=function(){t.autoplayDisabledByMotionMedia=reducedMotionMedia.matches};this.onMouseenter=function(){if(!t.preventAutoplayPause){t.autoplayDisabledByMouse=true}};this.onMouseleave=function(){t.autoplayDisabledByMouse=false};this.onFocusin=function(){if(!t.preventAutoplayPause){t.autoplayDisabledByFocus=true}};this.onFocusout=function(){t.autoplayDisabledByFocus=false};this.onPreviousClick=function(){t.scrollToPreviousSnapPoint()};this.onNextClick=function(){t.scrollToNextSnapPoint()};this.onSlideResize=function(){if(t.scrollElement){t.itemSize=t.sizingMethod()}};this.onMutation=function(){if(!t.scrollElement){return}t.slideElements=Array.from(t.scrollElement.children);t.slideElements.forEach((function(e,s){e.setAttribute("role","group");e.setAttribute("aria-roledescription","slide");e.setAttribute("aria-label",t.localization.slideLabel.replace(/\{current\}/gi,(s+1).toString()).replace(/\{total\}/gi,t.slideElements.length.toString()))}));t.previousElements=Array.from(t.element.querySelectorAll("[data-stzh-carousel-previous]"));t.nextElements=Array.from(t.element.querySelectorAll("[data-stzh-carousel-next]"));t.navigationTextElements=Array.from(t.element.querySelectorAll("[data-stzh-carousel-navigation-text]"))};this.onScroll=function(){if(t.scrollTimeoutId===null){var e=t.scrollElement.scrollLeft>t.slideScrollLeft?1:-1;t.scrolling=true;if(!t.scrolledByAutoplay){if(t.preventAutoplayStop){t.autoplayDisabledByScroll=true}else{t.autoplay=false}}t.stzhSlideStart.emit({component:"stzh-carousel",index:t.slide+e})}if(t.slide!==t.calculateSlide()){t.update();t.stzhSlidePassed.emit({component:"stzh-carousel",index:t.slide})}t.scrollTimeoutId&&window.clearTimeout(t.scrollTimeoutId);t.scrollTimeoutId=window.setTimeout(t.onScrollEnd,t.scrollTimeout)};this.onScrollEnd=function(){t.scrollTimeoutId=null;t.update();t.scrolling=false;t.scrolledByAutoplay=false;t.autoplayDisabledByScroll=false;if(t.stoppedDragging){t.stoppedDragging=false;t.scrollElement.style.removeProperty("scroll-behavior");t.scrollElement.style.removeProperty("scroll-snap-type")}if(t.tabThrough||t.variant==="cards"){t.ariaLive=""}else{t.ariaLive=(t.currentSlides>1?t.localization.slidesLabel:t.localization.slideLabel).replace(/\{(current|from)\}/gi,(t.slide+1).toString()).replace(/\{to\}/gi,(t.slide+t.currentSlides).toString()).replace(/\{total\}/gi,t.slideElements.length.toString())}t.stzhSlideEnd.emit({component:"stzh-carousel",index:t.slide})};this.onMediaChange=function(){var e=media("ultra").matches;var s=media("large").matches;var i=media("medium").matches;var r=media("small").matches;if(e&&t.slidesUltra!==0){t.currentSlides=t.slidesUltra}else if(s&&t.slidesLarge!==0){t.currentSlides=t.slidesLarge}else if(i&&t.slidesMedium!==0){t.currentSlides=t.slidesMedium}else if(r&&t.slidesSmall!==0){t.currentSlides=t.slidesSmall}else{t.currentSlides=t.slides}t.currentSwipeSlides=t.currentSlides};this.mouseMove=function(e){var s=t.lastX-e.clientX;t.lastX=e.clientX;t.scrollElement.scrollLeft+=s};this.startDragging=function(e){e.preventDefault();t.disableTimeoutId&&window.clearTimeout(t.disableTimeoutId);t.disableTimeoutId=null;t.startX=t.lastX=e.clientX;t.startScrollLeft=t.scrollElement.scrollLeft;t.scrollElement.style.setProperty("scroll-behavior","auto");t.scrollElement.style.setProperty("scroll-snap-type","unset");t.dragging=true;if(t.preventAutoplayStop){t.autoplayDisabledByDrag=true}else{t.autoplay=false}window.addEventListener("mousemove",t.mouseMove);window.addEventListener("mouseup",t.stopDragging,{capture:true});window.addEventListener("click",t.checkClick,{capture:true})};this.stopDragging=function(e){e.preventDefault();var s=Math.abs(t.startX-t.lastX);var i=s>t.distanceQuickSwipe;var r=t.lastX>t.startX?1:-1;t.dragging=false;t.autoplayDisabledByDrag=false;var o=t.scrollElement.scrollLeft;t.scrollElement.style.removeProperty("scroll-snap-type");var a=t.scrollElement.scrollLeft;t.scrollElement.style.setProperty("scroll-snap-type","unset");t.scrollElement.scrollTo({left:o,behavior:"auto"});if(a!==t.startScrollLeft||!i){t.scrollElement.scrollTo({left:a,behavior:reducedMotionMedia.matches?"auto":"smooth"})}else if(r===1){t.slideToPrevious()}else{t.slideToNext()}window.removeEventListener("mousemove",t.mouseMove);window.removeEventListener("mouseup",t.stopDragging,{capture:true});t.stoppedDragging=true};this.checkClick=function(e){var s=Math.abs(t.startX-t.lastX);var i=s>t.distancePreventClick;if(i){e.preventDefault()}t.lastX=null;window.removeEventListener("click",t.checkClick,{capture:true})};this.autoplayInterval=function(){t.scrolledByAutoplay=true;if(t.hasReachedLastSlide()){t.slideTo(0)}else{t.slideToNext()}};this.localization=undefined;this.variant="default";this.disabled=false;this.noPeek=false;this.slides=1;this.slidesSmall=0;this.slidesMedium=0;this.slidesLarge=0;this.slidesUltra=0;this.slide=0;this.autoplay=false;this.autoplayTimeout=3e3;this.nonInteractive=false;this.preventMouseDrag=false;this.preventAutoplayPause=false;this.preventAutoplayStop=false;this.tabThrough=false;this.scrollTimeout=100;this.distanceQuickSwipe=40;this.distancePreventClick=6;this.autoplayRunning=false;this.autoplayDisabledByMotionMedia=false;this.autoplayDisabledByMouse=false;this.autoplayDisabledByFocus=false;this.autoplayDisabledByScroll=false;this.autoplayDisabledByDrag=false;this.dragging=false;this.scrolling=false;this.ariaLive="";this.currentSlides=1;this.currentSwipeSlides=1;this.slideElements=[];this.previousElements=[];this.nextElements=[];this.navigationTextElements=[]}e.prototype.slideTo=function(e,t){if(t===void 0){t="smooth"}return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(s){this.scrollToSlide(e,t);return[2]}))}))};e.prototype.slideToPrevious=function(e){if(e===void 0){e="smooth"}return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.scrollToPreviousSnapPoint(e);return[2]}))}))};e.prototype.slideToNext=function(e){if(e===void 0){e="smooth"}return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.scrollToNextSnapPoint(e);return[2]}))}))};e.prototype.disabledWatcher=function(){if(this.disabled){this.scrollElement&&this.scrollElement.removeEventListener("scroll",this.onScroll);this.scrollTimeoutId&&window.clearTimeout(this.scrollTimeoutId);this.scrollTimeoutId=null;this.element.removeEventListener("mouseenter",this.onMouseenter);this.element.removeEventListener("mouseleave",this.onMouseleave);this.element.removeEventListener("focusin",this.onFocusin);this.element.removeEventListener("focusout",this.onFocusout);this.onReducedMotionMediaChange();reducedMotionMedia&&reducedMotionMedia.removeEventListener("change",this.onReducedMotionMediaChange)}else{this.scrollElement&&this.scrollElement.addEventListener("scroll",this.onScroll,{passive:true});this.element.addEventListener("mouseenter",this.onMouseenter);this.element.addEventListener("mouseleave",this.onMouseleave);this.element.addEventListener("focusin",this.onFocusin);this.element.addEventListener("focusout",this.onFocusout);reducedMotionMedia&&reducedMotionMedia.addEventListener("change",this.onReducedMotionMediaChange)}};e.prototype.preventMouseDragWatcher=function(){if(this.preventMouseDrag||this.disabled){this.disableTimeoutId&&window.clearTimeout(this.disableTimeoutId);this.disableTimeoutId=null;this.scrollElement&&this.scrollElement.removeEventListener("mousedown",this.startDragging);this.lastX=null}else{this.scrollElement&&this.scrollElement.addEventListener("mousedown",this.startDragging)}};e.prototype.autoplayRunningWatcher=function(){if(!this.autoplay||this.disabled||this.autoplayDisabledByMotionMedia||this.autoplayDisabledByMouse||this.autoplayDisabledByFocus||this.autoplayDisabledByScroll||this.autoplayDisabledByDrag){this.autoplayIntervalId&&window.clearInterval(this.autoplayIntervalId);this.autoplayIntervalId=null;this.autoplayRunning=false}else{this.autoplayIntervalId&&window.clearInterval(this.autoplayIntervalId);this.autoplayIntervalId=window.setInterval(this.autoplayInterval,this.autoplayTimeout);this.autoplayRunning=true}};e.prototype.snapAlignWatcher=function(){var e=this;this.slideElements.forEach((function(t,s){var i=(s-e.currentSwipeSlides)%e.currentSwipeSlides===0;if(i){t.style.removeProperty("scroll-snap-align")}else{t.style.setProperty("scroll-snap-align","none")}}))};e.prototype.inertWatcher=function(){var e=this;this.slideElements.forEach((function(t,s){var i=e.tabThrough||e.variant==="cards"||s>=e.slide&&s<e.slide+e.currentSlides;t.inert=!i;if(i){t.removeAttribute("aria-hidden")}else{t.setAttribute("aria-hidden",i?"false":"true")}}))};e.prototype.prevNextNavigationWatcher=function(){var e=this.tabThrough||this.variant==="cards";var t=function(t){var s=isStzhElement(t);if(e){t.setAttribute("aria-hidden","true");t.setAttribute(s?"a11y-tabindex":"tabindex","-1")}else{t.removeAttribute("aria-hidden");t.removeAttribute(s?"a11y-tabindex":"tabindex")}};this.nextElements.forEach(t);this.previousElements.forEach(t)};e.prototype.prevNextHiddenWatcher=function(){var e=this.slideElements.length<=this.currentSlides;var t=function(t){if(e){t.setAttribute("hidden","")}else{t.removeAttribute("hidden")}};this.navigationTextElements.forEach(t);this.nextElements.forEach(t);this.previousElements.forEach(t)};e.prototype.nextPrevDisabledWatcher=function(){if(!this.scrollElement){return}var e=this.slide===0;var t=this.hasReachedLastSlide();this.nextElements.forEach((function(e){var s=isStzhElement(e);e.setAttribute(s?"a11y-disabled":"aria-disabled",t?"true":"false")}));this.previousElements.forEach((function(t){var s=isStzhElement(t);t.setAttribute(s?"a11y-disabled":"aria-disabled",e?"true":"false")}))};e.prototype.nextElementsWatcher=function(){var e=this;this.nextElements.forEach((function(t){var s=isStzhElement(t);t.addEventListener("click",e.onNextClick);t.setAttribute(s?"a11y-controls":"aria-controls","".concat(e.carouselId,"-scroll"))}))};e.prototype.previousElementsWatcher=function(){var e=this;this.previousElements.forEach((function(t){var s=isStzhElement(t);t.addEventListener("click",e.onPreviousClick);t.setAttribute(s?"a11y-controls":"aria-controls","".concat(e.carouselId,"-scroll"))}))};e.prototype.scrollToSlide=function(e,t){if(t===void 0){t="smooth"}if(this.disabled){return}this.scrollElement.scrollTo({left:e*this.itemSize,behavior:reducedMotionMedia.matches?"auto":t})};e.prototype.sizingMethod=function(){var e=window.getComputedStyle(this.scrollElement);return(this.scrollElement.firstElementChild||this.scrollElement).offsetWidth+parseInt(e.getPropertyValue("column-gap"),10)};e.prototype.calculateSlide=function(){return Math.floor(this.scrollElement.scrollLeft/this.itemSize)};e.prototype.scrollToPreviousSnapPoint=function(e){if(e===void 0){e="smooth"}if(this.disabled){return}var t=this.slide;var s=false;while(!s&&t>0){t=t-1;s=(t-this.currentSwipeSlides)%this.currentSwipeSlides===0}this.slideTo(t,e)};e.prototype.scrollToNextSnapPoint=function(e){if(e===void 0){e="smooth"}if(this.disabled){return}this.slideTo(this.slide+this.currentSwipeSlides,e)};e.prototype.update=function(){this.slide=this.calculateSlide();this.slideScrollLeft=this.slide*this.itemSize;this.onMutation()};e.prototype.hasReachedLastSlide=function(){var e=this.scrollElement,t=e.scrollLeft,s=e.offsetWidth,i=e.scrollWidth;return Math.ceil(t+s)>=i};e.prototype.componentWillLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e;return __generator(this,(function(t){switch(t.label){case 0:this.carouselId="stzh-carousel-".concat(carouselCounter++);this.onMediaChange();if(!!this.localization)return[3,2];e=this;return[4,window.stzhComponents.utils.fetchTranslations(this.element,"carousel")];case 1:e.localization=t.sent();t.label=2;case 2:return[2]}}))}))};e.prototype.componentDidLoad=function(){this.itemSize=this.sizingMethod();this.update();this.disabledWatcher();this.preventMouseDragWatcher();this.autoplayRunningWatcher()};e.prototype.connectedCallback=function(){addMediaChangeListener(this.onMediaChange);this.resizeObserver=new ResizeObserver(this.onSlideResize);this.resizeObserver.observe(this.element);this.mutationObserver=new MutationObserver(this.onMutation);this.mutationObserver.observe(this.element,{childList:true,subtree:true})};e.prototype.disconnectedCallback=function(){this.scrollTimeoutId&&window.clearTimeout(this.scrollTimeoutId);this.scrollTimeoutId=null;this.disabled=true;removeMediaChangeListener(this.onMediaChange);if(this.resizeObserver){this.resizeObserver.disconnect()}if(this.mutationObserver){this.mutationObserver.disconnect()}};e.prototype.render=function(){var e=this;var t={"stzh-carousel":true,"stzh-carousel--is-disabled":this.disabled,"stzh-carousel--is-draggable":!this.preventMouseDrag,"stzh-carousel--is-non-interactive":this.nonInteractive,"stzh-carousel--is-dragging":this.dragging,"stzh-carousel--is-scrolling":this.scrolling,"stzh-carousel--has-autoplay":this.autoplay,"stzh-carousel--is-autoplay-running":this.autoplayRunning};return h(Host,{"aria-roledescription":"carousel",style:{"--slides":this.currentSlides.toString()}},h("div",{class:t},h("slot",{name:"actions"}),h("div",{class:"stzh-carousel__vhidden","aria-live":this.autoplayDisabledByFocus||this.autoplayDisabledByMouse?"polite":"off"},this.ariaLive),h("div",{ref:function(t){return e.scrollElement=t},id:"".concat(this.carouselId,"-scroll"),class:"stzh-carousel__scroll"},h("slot",null))))};Object.defineProperty(e.prototype,"element",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{disabled:["disabledWatcher","preventMouseDragWatcher","autoplayRunningWatcher"],preventMouseDrag:["preventMouseDragWatcher"],autoplay:["autoplayRunningWatcher"],autoplayDisabledByMotionMedia:["autoplayRunningWatcher"],autoplayDisabledByMouse:["autoplayRunningWatcher"],autoplayDisabledByFocus:["autoplayRunningWatcher"],autoplayDisabledByScroll:["autoplayRunningWatcher"],autoplayDisabledByDrag:["autoplayRunningWatcher"],autoplayTimeout:["autoplayRunningWatcher"],slideElements:["snapAlignWatcher","inertWatcher","prevNextHiddenWatcher","nextPrevDisabledWatcher"],currentSwipeSlides:["snapAlignWatcher"],slide:["inertWatcher","nextPrevDisabledWatcher"],variant:["inertWatcher","prevNextNavigationWatcher"],currentSlides:["inertWatcher","prevNextHiddenWatcher","nextPrevDisabledWatcher"],tabThrough:["inertWatcher","prevNextNavigationWatcher"],nextElements:["prevNextNavigationWatcher","prevNextHiddenWatcher","nextPrevDisabledWatcher","nextElementsWatcher"],previousElements:["prevNextNavigationWatcher","prevNextHiddenWatcher","nextPrevDisabledWatcher","previousElementsWatcher"],navigationTextElements:["prevNextHiddenWatcher"]}},enumerable:false,configurable:true});return e}();StzhCarousel.style=stzhCarouselCss;export{StzhCarousel as stzh_carousel};
2
2
  //# sourceMappingURL=stzh-carousel.entry.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["stzhCarouselCss","reducedMotionMedia","window","matchMedia","carouselCounter","StzhCarousel","this","slideScrollLeft","scrolledByAutoplay","scrollTimeoutId","lastX","startX","startScrollLeft","disableTimeoutId","stoppedDragging","onReducedMotionMediaChange","_this","autoplayDisabledByMotionMedia","matches","onMouseenter","autoplayDisabledByMouse","onMouseleave","onFocusin","autoplayDisabledByFocus","onFocusout","onPreviousClick","scrollToPreviousSnapPoint","onNextClick","scrollToNextSnapPoint","onSlideResize","scrollElement","itemSize","sizingMethod","onMutation","slideElements","Array","from","children","forEach","slide","index","setAttribute","localization","slideLabel","replace","toString","length","previousElements","element","querySelectorAll","nextElements","navigationTextElements","onScroll","direction","scrollLeft","scrolling","autoplay","stzhSlideStart","emit","component","calculateSlide","update","stzhSlidePassed","clearTimeout","setTimeout","onScrollEnd","scrollTimeout","style","removeProperty","tabThrough","variant","ariaLive","currentSlides","slidesLabel","stzhSlideEnd","onMediaChange","ultra","media","large","medium","small","slidesUltra","slidesLarge","slidesMedium","slidesSmall","slides","currentSwipeSlides","mouseMove","event","distance","clientX","startDragging","preventDefault","setProperty","dragging","addEventListener","stopDragging","capture","checkClick","Math","abs","minimumReached","distanceQuickSwipe","endDraddingLeft","finalLeft","scrollTo","left","behavior","slideToPrevious","slideToNext","removeEventListener","distancePreventClick","autoplayInterval","hasReachedLastSlide","slideTo","class_1","prototype","behaviour","scrollToSlide","disabledWatcher","disabled","passive","preventMouseDragWatcher","preventMouseDrag","autoplayRunningWatcher","autoplayIntervalId","clearInterval","autoplayRunning","setInterval","autoplayTimeout","snapAlignWatcher","shouldSnap","inertWatcher","isActive","inert","removeAttribute","prevNextNavigationWatcher","setAriaAttributes","isStzh","isStzhElement","prevNextHiddenWatcher","hideElements","setHiddenAttribute","nextPrevDisabledWatcher","reachedFirstSlide","reachedLastSlide","nextElementsWatcher","nextElement","concat","carouselId","previousElementsWatcher","previousElement","css","getComputedStyle","firstElementChild","offsetWidth","parseInt","getPropertyValue","floor","previousIndex","canSnap","_a","scrollWidth","ceil","componentWillLoad","stzhComponents","utils","fetchTranslations","_b","sent","componentDidLoad","connectedCallback","addMediaChangeListener","resizeObserver","ResizeObserver","observe","mutationObserver","MutationObserver","childList","subtree","disconnectedCallback","removeMediaChangeListener","disconnect","render","classes","h","Host","class","name","ref","el","id"],"sources":["src/components/stzh-carousel/stzh-carousel.scss?tag=stzh-carousel&encapsulation=scoped","src/components/stzh-carousel/stzh-carousel.tsx"],"sourcesContent":["/**\n * @prop --padding-top: Padding Top of scroll container\n * @prop --padding-bottom: Padding Bottom of scroll container\n * @prop --peek: Peek size showing the slides\n * @prop --peek-out: Negative peek size (breakout of container) showing the slides\n * @prop --gutter: Space between the slides\n * @prop --snap-stop: Snap stop of scroll container\n */\n\n:host {\n --peek: calc(var(--peek-in, 0px) + var(--peek-out, 0px));\n --peek-out: #{$containerMargin};\n --padding-top: 0px;\n --padding-bottom: 0px;\n --gutter: #{space('xxxsmall')};\n --snap-stop: always;\n --slides: 1;\n --slide-size: calc((100% - (var(--slides) - 1) * var(--gutter)) / var(--slides));\n\n @include mq($from: small) {\n --peek-out: #{$containerMarginSmall};\n }\n\n @include mq($from: medium) {\n --peek-out: 0px;\n }\n\n &[variant=\"cards\"] {\n --padding-top: 4px;\n --padding-bottom: 4px;\n\n --gutter: #{spaceCurveValue('tiny')};\n\n @include mq($from: medium) {\n --peek-out: #{$containerMarginMedium};\n --gutter: #{spaceCurveValue('tiny', 'medium')};\n }\n\n @include mq($from: large) {\n --peek-out: #{$containerMarginLarge};\n --gutter: #{spaceCurveValue('tiny', 'large')};\n }\n\n @include mq($from: ultra) {\n --peek-out: calc((100vw - #{$containerMaxWidth} - var(--stzh-scrollbar-width, 0px)) / 2);\n }\n }\n\n ::slotted(*) {\n width: 100%;\n height: 100%;\n flex-shrink: 0;\n scroll-snap-align: start;\n scroll-snap-stop: var(--snap-stop);\n\n img {\n -webkit-user-drag: none;\n user-drag: none;\n -ms-user-select: none;\n -moz-user-select: none;\n -webkit-user-select: none;\n user-select: none;\n }\n }\n\n ::slotted([slot=\"actions\"]) {\n position: absolute;\n top: 0;\n left: 0;\n z-index: 1;\n pointer-events: none;\n padding: 0 var(--peek);\n\n stzh-text {\n width: auto;\n }\n\n stzh-button {\n pointer-events: all;\n }\n }\n\n ::slotted(stzh-ratio[slot=\"actions\"]) {\n stzh-space,\n stzh-hspace,\n stzh-vspace {\n padding: space('xsmall');\n }\n }\n\n ::slotted(stzh-ratio[slot=\"actions\"]) {\n --background-color: transparent;\n }\n\n &[variant=\"cards\"] ::slotted([slot=\"actions\"]) {\n position: relative;\n order: 1;\n margin-top: calc(#{space('medium')} - var(--padding-bottom));\n }\n}\n\n.stzh-carousel {\n position: relative;\n display: flex;\n flex-direction: column;\n width: calc(100% + var(--peek-out) * 2);\n margin-left: calc(var(--peek-out) / -1);\n margin-right: calc(var(--peek-out) / -1);\n\n &__vhidden {\n @include visuallyhidden;\n }\n\n &__scroll {\n position: relative;\n grid-area: slides;\n display: grid;\n width: 100%;\n height: 100%;\n place-items: center;\n overflow-x: auto;\n overflow-y: visible;\n grid-auto-flow: column;\n grid-auto-columns: var(--slide-size);\n grid-auto-rows: 100%;\n column-gap: var(--gutter);\n -webkit-overflow-scrolling: touch;\n scrollbar-width: none;\n -ms-overflow-style: none;\n scroll-behavior: smooth;\n overscroll-behavior-x: contain;\n scroll-snap-type: x mandatory;\n scroll-padding: 0 var(--peek);\n padding: var(--padding-top) var(--peek) var(--padding-bottom);\n\n @media (prefers-reduced-motion: reduce) {\n scroll-behavior: auto;\n }\n\n &::-webkit-scrollbar {\n display: none;\n }\n }\n\n &--is-draggable &__scroll {\n cursor: grab;\n }\n\n &--is-dragging &__scroll {\n cursor: grabbing;\n }\n\n &--is-disabled &__scroll {\n cursor: not-allowed;\n overflow: hidden;\n }\n}\n","import {\n Component,\n Host,\n h,\n Element,\n Prop,\n Method,\n Event,\n EventEmitter,\n Watch,\n State\n} from \"@stencil/core\";\n\nimport {\n StzhCarouselSlideStartEvent,\n StzhCarouselSlidePassedEvent,\n StzhCarouselSlideEndEvent\n} from \"../../index\";\n\nimport { isStzhElement } from \"../../utils/utils\";\nimport { StzhCarouselLocalizedText } from \"./stzh-carousel.localization\"\n\nimport {\n media,\n addMediaChangeListener,\n removeMediaChangeListener\n} from '../../utils/media-utils';\n\nconst reducedMotionMedia = window.matchMedia(\"(prefers-reduced-motion: reduce)\");\n\nlet carouselCounter = 0;\n\n/*\n* Inspired by:\n*\n* - https://github.com/barthy-koeln/scroll-snap-slider\n* - https://tannerhodges.github.io/snap-slider/\n* - https://www.w3.org/WAI/ARIA/apg/patterns/carousel/examples/carousel-1-prev-next/\n* - https://dev.to/jasonwebb/how-to-build-a-more-accessible-carousel-or-slider-35lp\n* - http://web-accessibility.carnegiemuseums.org/code/carousels/\n*/\n\n/**\n * @slot - Slot any element\n * @slot actions - Slot for `stzh-actions` element\n */\n@Component({\n tag: \"stzh-carousel\",\n styleUrl: \"stzh-carousel.scss\",\n scoped: true\n})\nexport class StzhCarousel {\n /** Translation strings */\n @Prop() localization: StzhCarouselLocalizedText;\n\n /** Carousel variant */\n @Prop({ reflect: true }) variant: \"default\" | \"cards\" = \"default\";\n\n /** Whether carousel is disabled */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /** Slides number */\n @Prop() slides: number = 1;\n /** Slides number above small breakpoint */\n @Prop() slidesSmall: number = 0;\n /** Slides number above medium breakpoint */\n @Prop() slidesMedium: number = 0;\n /** Slides number above large breakpoint */\n @Prop() slidesLarge: number = 0;\n /** Slides number above ultra breakpoint */\n @Prop() slidesUltra: number = 0;\n\n // /** How many slides per swipe */\n // @Prop() swipeSlides: number = 1;\n // /** How many slides per swipe above small breakpoint */\n // @Prop() swipeSlidesSmall: number = 0;\n // /** How many slides per swipe above medium breakpoint */\n // @Prop() swipeSlidesMedium: number = 0;\n // /** How many slides per swipe above large breakpoint */\n // @Prop() swipeSlidesLarge: number = 0;\n // /** How many slides per swipe above ultra breakpoint */\n // @Prop() swipeSlidesUltra: number = 0;\n\n /** Active slide (readonly) */\n @Prop() slide: number = 0;\n\n /**\n * Whether autoplay is enabled.\n * Gets paused, when user has focus inside carousel element or hovers over it.\n * Also when reduced motion media query is active or carousel is set disabled.\n * Gets disabled permanently, when user interacts with carousel manually (clicks prev/next, scrolls or drags)\n */\n @Prop({ mutable: true }) autoplay: boolean = false;\n\n /**\n * Enable all slides to be tabbable (will disable prev/next arrows from being tabbable).\n * By default only the visible slides will be tabbable and the prev/next can be used to change slides\n * (enabled when `variant` is set to `cards`).\n */\n @Prop() tabThrough: boolean = false;\n\n /** Whether drag with mouse should be disabled */\n @State() preventMouseDrag = false;\n\n /** Timeout delay in milliseconds used to catch the end of scroll events */\n @State() scrollTimeout: number = 100;\n\n /** Timeout delay in milliseconds used for autoplay */\n @State() autoplayTimeout: number = 3000;\n\n /** Minimum drag distance that needs to be reached to swipe to next/previous slide(s). */\n @State() distanceQuickSwipe: number = 40;\n\n /** Minimum drag distance that neeeds to be reached to prevent click on slide elements. */\n @State() distancePreventClick: number = 6;\n\n @Element() element: HTMLStzhCarouselElement;\n\n /** Slide start event */\n @Event() stzhSlideStart: EventEmitter<StzhCarouselSlideStartEvent>;\n\n /** Slide passed event */\n @Event() stzhSlidePassed: EventEmitter<StzhCarouselSlidePassedEvent>;\n\n /** Slide end event */\n @Event() stzhSlideEnd: EventEmitter<StzhCarouselSlideEndEvent>;\n\n /** Scroll to a slide by index */\n @Method()\n async slideTo(index, behaviour: \"auto\" | \"smooth\" = \"smooth\") {\n this.scrollToSlide(index, behaviour);\n }\n\n /** Scroll to previous snap point */\n @Method()\n async slideToPrevious(behaviour: \"auto\" | \"smooth\" = \"smooth\") {\n this.scrollToPreviousSnapPoint(behaviour);\n }\n\n /** Scroll to next snap point */\n @Method()\n async slideToNext(behaviour: \"auto\" | \"smooth\" = \"smooth\") {\n this.scrollToNextSnapPoint(behaviour);\n }\n\n @Watch(\"disabled\")\n disabledWatcher() {\n if (this.disabled) {\n this.scrollElement && this.scrollElement.removeEventListener(\"scroll\", this.onScroll);\n this.scrollTimeoutId && window.clearTimeout(this.scrollTimeoutId);\n this.scrollTimeoutId = null;\n this.element.removeEventListener(\"mouseenter\", this.onMouseenter);\n this.element.removeEventListener(\"mouseleave\", this.onMouseleave);\n this.element.removeEventListener(\"focusin\", this.onFocusin);\n this.element.removeEventListener(\"focusout\", this.onFocusout);\n this.onReducedMotionMediaChange();\n reducedMotionMedia && reducedMotionMedia.removeEventListener(\"change\", this.onReducedMotionMediaChange);\n } else {\n this.scrollElement && this.scrollElement.addEventListener(\"scroll\", this.onScroll, { passive: true });\n this.element.addEventListener(\"mouseenter\", this.onMouseenter);\n this.element.addEventListener(\"mouseleave\", this.onMouseleave);\n this.element.addEventListener(\"focusin\", this.onFocusin);\n this.element.addEventListener(\"focusout\", this.onFocusout);\n reducedMotionMedia && reducedMotionMedia.addEventListener(\"change\", this.onReducedMotionMediaChange);\n }\n }\n\n @Watch(\"disabled\")\n @Watch(\"preventMouseDrag\")\n preventMouseDragWatcher() {\n if (this.preventMouseDrag || this.disabled) {\n this.disableTimeoutId && window.clearTimeout(this.disableTimeoutId);\n this.disableTimeoutId = null;\n this.scrollElement && this.scrollElement.removeEventListener(\"mousedown\", this.startDragging);\n this.lastX = null;\n } else {\n this.scrollElement && this.scrollElement.addEventListener(\"mousedown\", this.startDragging);\n }\n }\n\n @Watch(\"autoplay\")\n @Watch(\"autoplayDisabledByMotionMedia\")\n @Watch(\"autoplayDisabledByMouse\")\n @Watch(\"autoplayDisabledByFocus\")\n @Watch(\"autoplayTimeout\")\n @Watch(\"disabled\")\n autoplayRunningWatcher() {\n if (\n !this.autoplay\n || this.disabled\n || this.autoplayDisabledByMotionMedia\n || this.autoplayDisabledByMouse\n || this.autoplayDisabledByFocus\n ) {\n this.autoplayIntervalId && window.clearInterval(this.autoplayIntervalId);\n this.autoplayIntervalId = null;\n this.autoplayRunning = false;\n } else {\n this.autoplayIntervalId && window.clearInterval(this.autoplayIntervalId);\n this.autoplayIntervalId = window.setInterval(this.autoplayInterval, this.autoplayTimeout);\n this.autoplayRunning = true;\n }\n }\n\n @Watch(\"slideElements\")\n @Watch(\"currentSwipeSlides\")\n snapAlignWatcher() {\n this.slideElements.forEach((slide, index) => {\n const shouldSnap = (index - this.currentSwipeSlides) % this.currentSwipeSlides === 0;\n\n if (shouldSnap) {\n slide.style.removeProperty(\"scroll-snap-align\");\n } else {\n slide.style.setProperty(\"scroll-snap-align\", \"none\");\n }\n });\n }\n\n @Watch(\"slide\")\n @Watch(\"variant\")\n @Watch(\"slideElements\")\n @Watch(\"currentSlides\")\n @Watch(\"tabThrough\")\n inertWatcher() {\n this.slideElements.forEach((slide, index) => {\n const isActive = this.tabThrough\n || this.variant === \"cards\"\n || index >= this.slide && index < this.slide + this.currentSlides;\n\n slide.inert = !isActive;\n\n if (isActive) {\n slide.removeAttribute(\"aria-hidden\");\n } else {\n slide.setAttribute(\"aria-hidden\", isActive ? \"false\" : \"true\");\n }\n });\n }\n\n @Watch(\"variant\")\n @Watch(\"tabThrough\")\n @Watch(\"nextElements\")\n @Watch(\"previousElements\")\n prevNextNavigationWatcher() {\n const tabThrough = this.tabThrough || this.variant === \"cards\";\n\n const setAriaAttributes = (element) => {\n const isStzh = isStzhElement(element);\n\n if (tabThrough) {\n element.setAttribute(\"aria-hidden\", \"true\");\n element.setAttribute(isStzh ? \"a11y-tabindex\" : \"tabindex\", \"-1\");\n } else {\n element.removeAttribute(\"aria-hidden\");\n element.removeAttribute(isStzh ? \"a11y-tabindex\" : \"tabindex\");\n }\n }\n\n this.nextElements.forEach(setAriaAttributes);\n this.previousElements.forEach(setAriaAttributes);\n }\n\n @Watch(\"currentSlides\")\n @Watch(\"slideElements\")\n @Watch(\"nextElements\")\n @Watch(\"previousElements\")\n @Watch(\"navigationTextElements\")\n prevNextHiddenWatcher() {\n const hideElements = this.slideElements.length <= this.currentSlides;\n\n const setHiddenAttribute = (element) => {\n if (hideElements) {\n element.setAttribute(\"hidden\", \"\");\n } else {\n element.removeAttribute(\"hidden\");\n }\n };\n\n this.navigationTextElements.forEach(setHiddenAttribute);\n this.nextElements.forEach(setHiddenAttribute);\n this.previousElements.forEach(setHiddenAttribute);\n }\n\n @Watch(\"slide\")\n @Watch(\"currentSlides\")\n @Watch(\"slideElements\")\n @Watch(\"nextElements\")\n @Watch(\"previousElements\")\n nextPrevDisabledWatcher() {\n if (!this.scrollElement) {\n return;\n }\n\n const reachedFirstSlide = this.slide === 0;\n const reachedLastSlide = this.hasReachedLastSlide();\n\n this.nextElements.forEach((element) => {\n const isStzh = isStzhElement(element);\n element.setAttribute(isStzh ? \"a11y-disabled\" : \"aria-disabled\", reachedLastSlide ? \"true\" : \"false\");\n });\n\n this.previousElements.forEach((element) => {\n const isStzh = isStzhElement(element);\n element.setAttribute(isStzh ? \"a11y-disabled\" : \"aria-disabled\", reachedFirstSlide ? \"true\" : \"false\");\n });\n }\n\n @Watch(\"nextElements\")\n nextElementsWatcher() {\n this.nextElements.forEach((nextElement) => {\n const isStzh = isStzhElement(nextElement);\n\n nextElement.addEventListener(\"click\", this.onNextClick);\n nextElement.setAttribute(isStzh ? \"a11y-controls\" : \"aria-controls\", `${this.carouselId}-scroll`);\n });\n }\n\n @Watch(\"previousElements\")\n previousElementsWatcher() {\n this.previousElements.forEach((previousElement) => {\n const isStzh = isStzhElement(previousElement);\n\n previousElement.addEventListener(\"click\", this.onPreviousClick);\n previousElement.setAttribute(isStzh ? \"a11y-controls\" : \"aria-controls\", `${this.carouselId}-scroll`);\n });\n }\n\n /** Whether autoplay is currently running */\n @State() autoplayRunning: boolean = false;\n\n /** Whether autoplay is currently disabled by reduced motion media */\n @State() autoplayDisabledByMotionMedia: boolean = false;\n\n /** Whether autoplay is currently disabled by mouse */\n @State() autoplayDisabledByMouse: boolean = false;\n\n /** Whether autoplay is currently disabled by focus */\n @State() autoplayDisabledByFocus: boolean = false;\n\n /** Whether user is currently dragging with mouse */\n @State() dragging: boolean = false;\n\n /** Whether user is currently scrolling */\n @State() scrolling: boolean = false;\n\n /** Aria live text */\n @State() ariaLive: string = \"\";\n\n /** Currently shown slides */\n @State() currentSlides: number = 1;\n\n /** How many slides should be moved currently */\n @State() currentSwipeSlides: number = 1;\n\n /** Slide elements */\n @State() slideElements: HTMLElement[] = [];\n\n /** Previous elements */\n @State() previousElements: HTMLElement[] = [];\n\n /** Next elements */\n @State() nextElements: HTMLElement[] = [];\n\n /** Navigation text elements */\n @State() navigationTextElements: HTMLElement[] = [];\n\n private scrollElement: HTMLElement;\n\n /** Unique generated id */\n private carouselId: string;\n\n /** Current scroll position */\n private slideScrollLeft: number = 0;\n\n /** Flag whether scrolling was done by user or not */\n private scrolledByAutoplay: boolean = false;\n\n /** Timeout ID used to catch the end of scroll events */\n private scrollTimeoutId: number = null;\n\n /** Interval ID for autoplay */\n private autoplayIntervalId: number;\n\n /** Last drag event position */\n private lastX: number = null;\n\n /** Where the dragging started */\n private startX: number = null;\n\n /** Where the dragging started scroll position */\n private startScrollLeft: number = null;\n\n /** Timeout ID for a smooth drag release */\n private disableTimeoutId: number = null;\n\n /** Calculated size of a single item */\n private itemSize: number;\n\n /** Resize observer used to update item size */\n private resizeObserver: ResizeObserver;\n\n /** Mutation observer used to keep track of slides */\n private mutationObserver: MutationObserver;\n\n /** Whether user has just stopped dragging */\n private stoppedDragging: boolean = false;\n\n private scrollToSlide(index, behaviour: \"auto\" | \"smooth\" = \"smooth\") {\n if (this.disabled) {\n return;\n }\n\n this.scrollElement.scrollTo({\n left: index * this.itemSize,\n behavior: reducedMotionMedia.matches ? \"auto\" : behaviour\n });\n }\n\n /** Width of a slide */\n private sizingMethod() {\n const css = window.getComputedStyle(this.scrollElement);\n\n return ((this.scrollElement.firstElementChild as HTMLElement) || this.scrollElement).offsetWidth\n + parseInt(css.getPropertyValue(\"column-gap\"), 10);\n }\n\n /**\n * Calculates the active slide.\n * The scroll-snap-type property makes sure that the container snaps perfectly to integer multiples.\n */\n private calculateSlide() {\n // Math.round: Dispatch 'stzhSlidePassed' events around the center of each slide\n // Math.ceil: Dispatch 'stzhSlidePassed' events as soon as the next one is visible\n // Math.floor: Dispatch 'stzhSlidePassed' events only when the next one is fully visible\n return Math.floor(this.scrollElement.scrollLeft / this.itemSize);\n }\n\n private scrollToPreviousSnapPoint(behaviour: \"auto\" | \"smooth\" = \"smooth\") {\n if (this.disabled) {\n return;\n }\n\n let previousIndex = this.slide;\n let canSnap = false;\n\n while (!canSnap && previousIndex > 0) {\n previousIndex = previousIndex - 1;\n canSnap = (previousIndex - this.currentSwipeSlides) % this.currentSwipeSlides === 0;\n }\n\n this.slideTo(previousIndex, behaviour);\n }\n\n private scrollToNextSnapPoint(behaviour: \"auto\" | \"smooth\" = \"smooth\") {\n if (this.disabled) {\n return;\n }\n\n this.slideTo(this.slide + this.currentSwipeSlides, behaviour);\n }\n\n private update() {\n this.slide = this.calculateSlide();\n this.slideScrollLeft = this.slide * this.itemSize;\n\n this.onMutation();\n }\n\n private hasReachedLastSlide() {\n const { scrollLeft, offsetWidth, scrollWidth } = this.scrollElement;\n return Math.ceil(scrollLeft + offsetWidth) >= scrollWidth;\n }\n\n private onReducedMotionMediaChange = () => {\n this.autoplayDisabledByMotionMedia = reducedMotionMedia.matches;\n }\n\n private onMouseenter = () => {\n this.autoplayDisabledByMouse = true;\n }\n\n private onMouseleave = () => {\n this.autoplayDisabledByMouse = false;\n }\n\n private onFocusin = () => {\n this.autoplayDisabledByFocus = true;\n }\n\n private onFocusout = () => {\n this.autoplayDisabledByFocus = false;\n }\n\n private onPreviousClick = () => {\n this.scrollToPreviousSnapPoint();\n }\n\n private onNextClick = () => {\n this.scrollToNextSnapPoint();\n }\n\n private onSlideResize = () => {\n if (this.scrollElement) {\n this.itemSize = this.sizingMethod();\n }\n }\n\n private onMutation = () => {\n if (!this.scrollElement) {\n return;\n }\n\n this.slideElements = Array.from(this.scrollElement.children) as HTMLElement[];\n\n this.slideElements.forEach((slide, index) => {\n slide.setAttribute(\"role\", \"group\");\n slide.setAttribute(\"aria-roledescription\", \"slide\");\n slide.setAttribute(\"aria-label\", this.localization.slideLabel\n .replace(/\\{current\\}/gi, (index + 1).toString())\n .replace(/\\{total\\}/gi, this.slideElements.length.toString())\n );\n });\n\n this.previousElements = Array.from(this.element.querySelectorAll(\"[data-stzh-carousel-previous]\"));\n this.nextElements = Array.from(this.element.querySelectorAll(\"[data-stzh-carousel-next]\"));\n this.navigationTextElements = Array.from(this.element.querySelectorAll(\"[data-stzh-carousel-navigation-text]\"));\n }\n\n private onScroll = () => {\n if (this.scrollTimeoutId === null) {\n const direction = (this.scrollElement.scrollLeft > this.slideScrollLeft) ? 1 : -1;\n\n this.scrolling = true;\n\n if (!this.scrolledByAutoplay) {\n this.autoplay = false;\n }\n\n this.stzhSlideStart.emit({\n component: \"stzh-carousel\",\n index: this.slide + direction\n });\n }\n\n if (this.slide !== this.calculateSlide()) {\n this.update();\n this.stzhSlidePassed.emit({\n component: \"stzh-carousel\",\n index: this.slide\n });\n }\n\n this.scrollTimeoutId && window.clearTimeout(this.scrollTimeoutId);\n this.scrollTimeoutId = window.setTimeout(this.onScrollEnd, this.scrollTimeout);\n }\n\n private onScrollEnd = () => {\n this.scrollTimeoutId = null;\n this.update();\n\n this.scrolling = false;\n this.scrolledByAutoplay = false;\n\n if (this.stoppedDragging) {\n this.stoppedDragging = false;\n this.scrollElement.style.removeProperty(\"scroll-behavior\");\n this.scrollElement.style.removeProperty(\"scroll-snap-type\");\n }\n\n if (this.tabThrough || this.variant === \"cards\") {\n this.ariaLive = \"\";\n } else {\n this.ariaLive = (this.currentSlides > 1 ? this.localization.slidesLabel : this.localization.slideLabel)\n .replace(/\\{(current|from)\\}/gi, (this.slide + 1).toString())\n .replace(/\\{to\\}/gi, (this.slide + this.currentSlides).toString())\n .replace(/\\{total\\}/gi, this.slideElements.length.toString());\n }\n\n this.stzhSlideEnd.emit({\n component: \"stzh-carousel\",\n index: this.slide\n });\n }\n\n private onMediaChange = () => {\n const ultra = media(\"ultra\").matches;\n const large = media(\"large\").matches;\n const medium = media(\"medium\").matches;\n const small = media(\"small\").matches;\n\n if (ultra && this.slidesUltra !== 0) {\n this.currentSlides = this.slidesUltra;\n } else if (large && this.slidesLarge !== 0) {\n this.currentSlides = this.slidesLarge;\n } else if (medium && this.slidesMedium !== 0) {\n this.currentSlides = this.slidesMedium;\n } else if (small && this.slidesSmall !== 0) {\n this.currentSlides = this.slidesSmall;\n } else {\n this.currentSlides = this.slides;\n }\n\n // if (ultra && this.swipeSlidesUltra !== 0) {\n // this.currentSwipeSlides = this.swipeSlidesUltra;\n // } else if (large && this.swipeSlidesLarge !== 0) {\n // this.currentSwipeSlides = this.swipeSlidesLarge;\n // } else if (medium && this.swipeSlidesMedium !== 0) {\n // this.currentSwipeSlides = this.swipeSlidesMedium;\n // } else if (small && this.swipeSlidesSmall !== 0) {\n // this.currentSwipeSlides = this.swipeSlidesSmall;\n // } else {\n // this.currentSwipeSlides = this.swipeSlides;\n // }\n\n this.currentSwipeSlides = this.currentSlides;\n }\n\n /** Scroll the slider the appropriate amount of pixels and update the last event position */\n private mouseMove = (event: MouseEvent) => {\n const distance = this.lastX - event.clientX;\n this.lastX = event.clientX;\n\n this.scrollElement.scrollLeft += distance;\n }\n\n /** Clear disable timeout, set up variables and styles and attach the listener. */\n private startDragging = (event: MouseEvent) => {\n event.preventDefault()\n this.disableTimeoutId && window.clearTimeout(this.disableTimeoutId);\n this.disableTimeoutId = null;\n\n this.startX = this.lastX = event.clientX;\n this.startScrollLeft = this.scrollElement.scrollLeft;\n this.scrollElement.style.setProperty(\"scroll-behavior\", \"auto\");\n this.scrollElement.style.setProperty(\"scroll-snap-type\", \"unset\");\n\n this.dragging = true;\n this.autoplay = false;\n\n window.addEventListener(\"mousemove\", this.mouseMove);\n window.addEventListener(\"mouseup\", this.stopDragging, { capture: true });\n window.addEventListener(\"click\", this.checkClick, { capture: true });\n }\n\n /** User stopped dragging */\n private stopDragging = (event: MouseEvent) => {\n event.preventDefault();\n\n const distance = Math.abs(this.startX - this.lastX);\n const minimumReached = distance > this.distanceQuickSwipe;\n const direction = (this.lastX > this.startX) ? 1 : -1;\n\n this.dragging = false;\n\n const endDraddingLeft = this.scrollElement.scrollLeft;\n\n this.scrollElement.style.removeProperty(\"scroll-snap-type\");\n const finalLeft = this.scrollElement.scrollLeft;\n\n this.scrollElement.style.setProperty(\"scroll-snap-type\", \"unset\");\n this.scrollElement.scrollTo({ left: endDraddingLeft, behavior: \"auto\" });\n\n if (finalLeft !== this.startScrollLeft || !minimumReached) {\n this.scrollElement.scrollTo({ left: finalLeft, behavior: reducedMotionMedia.matches ? \"auto\" : \"smooth\" });\n } else if (direction === 1) {\n this.slideToPrevious();\n } else {\n this.slideToNext();\n }\n\n window.removeEventListener(\"mousemove\", this.mouseMove);\n window.removeEventListener(\"mouseup\", this.stopDragging, { capture: true });\n\n this.stoppedDragging = true;\n }\n\n private checkClick = (event: MouseEvent) => {\n const distance = Math.abs(this.startX - this.lastX);\n const minimumReached = distance > this.distancePreventClick;\n\n if (minimumReached) {\n event.preventDefault();\n }\n\n this.lastX = null;\n\n window.removeEventListener(\"click\", this.checkClick, { capture: true });\n }\n\n private autoplayInterval = () => {\n this.scrolledByAutoplay = true;\n\n if (this.hasReachedLastSlide()) {\n this.slideTo(0);\n } else {\n this.slideToNext();\n }\n }\n\n async componentWillLoad() {\n this.carouselId = `stzh-carousel-${carouselCounter++}`;\n this.onMediaChange();\n\n if (!this.localization) {\n this.localization = await window.stzhComponents.utils.fetchTranslations(this.element, \"carousel\");\n }\n }\n\n componentDidLoad() {\n this.itemSize = this.sizingMethod();\n this.update();\n\n this.disabledWatcher();\n this.preventMouseDragWatcher();\n this.autoplayRunningWatcher();\n }\n\n connectedCallback() {\n addMediaChangeListener(this.onMediaChange);\n\n this.resizeObserver = new ResizeObserver(this.onSlideResize)\n this.resizeObserver.observe(this.element)\n\n this.mutationObserver = new MutationObserver(this.onMutation);\n this.mutationObserver.observe(this.element, {\n childList: true,\n subtree: true\n });\n }\n\n disconnectedCallback() {\n this.scrollTimeoutId && window.clearTimeout(this.scrollTimeoutId);\n this.scrollTimeoutId = null;\n this.disabled = true;\n\n removeMediaChangeListener(this.onMediaChange);\n\n if (this.resizeObserver) {\n this.resizeObserver.disconnect();\n }\n\n if (this.mutationObserver) {\n this.mutationObserver.disconnect();\n }\n }\n\n render() {\n const classes = {\n \"stzh-carousel\": true,\n \"stzh-carousel--is-disabled\": this.disabled,\n \"stzh-carousel--is-draggable\": !this.preventMouseDrag,\n \"stzh-carousel--is-dragging\": this.dragging,\n \"stzh-carousel--is-scrolling\": this.scrolling,\n \"stzh-carousel--has-autoplay\": this.autoplay,\n \"stzh-carousel--is-autoplay-running\": this.autoplayRunning,\n \"stzh-carousel--is-autoplay-disabled-by-motion-media\": this.autoplayDisabledByMotionMedia,\n \"stzh-carousel--is-autoplay-disabled-by-mouse\": this.autoplayDisabledByMouse,\n \"stzh-carousel--is-autoplay-disabled-by-focus\": this.autoplayDisabledByFocus\n };\n\n return (\n <Host\n aria-roledescription=\"carousel\"\n style={{\n '--slides': this.currentSlides.toString()\n }}\n >\n <div class={classes}>\n <slot name=\"actions\"></slot>\n <div\n class=\"stzh-carousel__vhidden\"\n aria-live={this.autoplayDisabledByFocus || this.autoplayDisabledByMouse ? \"polite\" : \"off\"}\n >\n {this.ariaLive}\n </div>\n <div\n ref={(el) => (this.scrollElement = el as HTMLDivElement)}\n id={`${this.carouselId}-scroll`}\n class=\"stzh-carousel__scroll\"\n >\n <slot></slot>\n </div>\n </div>\n </Host>\n );\n }\n}\n"],"mappings":"svDAAA,IAAMA,gBAAkB,giJC4BxB,IAAMC,mBAAqBC,OAAOC,WAAW,oCAE7C,IAAIC,gBAAkB,E,IAqBTC,aAAY,W,2NAiUfC,KAAAC,gBAA0B,EAG1BD,KAAAE,mBAA8B,MAG9BF,KAAAG,gBAA0B,KAM1BH,KAAAI,MAAgB,KAGhBJ,KAAAK,OAAiB,KAGjBL,KAAAM,gBAA0B,KAG1BN,KAAAO,iBAA2B,KAY3BP,KAAAQ,gBAA2B,MAoE3BR,KAAAS,2BAA6B,WACnCC,EAAKC,8BAAgChB,mBAAmBiB,O,EAGlDZ,KAAAa,aAAe,WACrBH,EAAKI,wBAA0B,I,EAGzBd,KAAAe,aAAe,WACrBL,EAAKI,wBAA0B,K,EAGzBd,KAAAgB,UAAY,WAClBN,EAAKO,wBAA0B,I,EAGzBjB,KAAAkB,WAAa,WACnBR,EAAKO,wBAA0B,K,EAGzBjB,KAAAmB,gBAAkB,WACxBT,EAAKU,2B,EAGCpB,KAAAqB,YAAc,WACpBX,EAAKY,uB,EAGCtB,KAAAuB,cAAgB,WACtB,GAAIb,EAAKc,cAAe,CACtBd,EAAKe,SAAWf,EAAKgB,c,GAIjB1B,KAAA2B,WAAa,WACnB,IAAKjB,EAAKc,cAAe,CACvB,M,CAGFd,EAAKkB,cAAgBC,MAAMC,KAAKpB,EAAKc,cAAcO,UAEnDrB,EAAKkB,cAAcI,SAAQ,SAACC,EAAOC,GACjCD,EAAME,aAAa,OAAQ,SAC3BF,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A,OACEI,IAAK,SAACC,GAAE,OAAM9K,EAAKc,cAAgBgK,CAA3B,EACRC,GAAI,GAAA3C,OAAG9I,KAAK+I,WAAU,WACtBsC,MAAM,yBAENF,EAAA,e,2uCAztBa,G"}
1
+ {"version":3,"names":["stzhCarouselCss","reducedMotionMedia","window","matchMedia","carouselCounter","StzhCarousel","this","slideScrollLeft","scrolledByAutoplay","scrollTimeoutId","lastX","startX","startScrollLeft","disableTimeoutId","stoppedDragging","onReducedMotionMediaChange","_this","autoplayDisabledByMotionMedia","matches","onMouseenter","preventAutoplayPause","autoplayDisabledByMouse","onMouseleave","onFocusin","autoplayDisabledByFocus","onFocusout","onPreviousClick","scrollToPreviousSnapPoint","onNextClick","scrollToNextSnapPoint","onSlideResize","scrollElement","itemSize","sizingMethod","onMutation","slideElements","Array","from","children","forEach","slide","index","setAttribute","localization","slideLabel","replace","toString","length","previousElements","element","querySelectorAll","nextElements","navigationTextElements","onScroll","direction","scrollLeft","scrolling","preventAutoplayStop","autoplayDisabledByScroll","autoplay","stzhSlideStart","emit","component","calculateSlide","update","stzhSlidePassed","clearTimeout","setTimeout","onScrollEnd","scrollTimeout","style","removeProperty","tabThrough","variant","ariaLive","currentSlides","slidesLabel","stzhSlideEnd","onMediaChange","ultra","media","large","medium","small","slidesUltra","slidesLarge","slidesMedium","slidesSmall","slides","currentSwipeSlides","mouseMove","event","distance","clientX","startDragging","preventDefault","setProperty","dragging","autoplayDisabledByDrag","addEventListener","stopDragging","capture","checkClick","Math","abs","minimumReached","distanceQuickSwipe","endDraddingLeft","finalLeft","scrollTo","left","behavior","slideToPrevious","slideToNext","removeEventListener","distancePreventClick","autoplayInterval","hasReachedLastSlide","slideTo","class_1","prototype","behaviour","scrollToSlide","disabledWatcher","disabled","passive","preventMouseDragWatcher","preventMouseDrag","autoplayRunningWatcher","autoplayIntervalId","clearInterval","autoplayRunning","setInterval","autoplayTimeout","snapAlignWatcher","shouldSnap","inertWatcher","isActive","inert","removeAttribute","prevNextNavigationWatcher","setAriaAttributes","isStzh","isStzhElement","prevNextHiddenWatcher","hideElements","setHiddenAttribute","nextPrevDisabledWatcher","reachedFirstSlide","reachedLastSlide","nextElementsWatcher","nextElement","concat","carouselId","previousElementsWatcher","previousElement","css","getComputedStyle","firstElementChild","offsetWidth","parseInt","getPropertyValue","floor","previousIndex","canSnap","_a","scrollWidth","ceil","componentWillLoad","stzhComponents","utils","fetchTranslations","_b","sent","componentDidLoad","connectedCallback","addMediaChangeListener","resizeObserver","ResizeObserver","observe","mutationObserver","MutationObserver","childList","subtree","disconnectedCallback","removeMediaChangeListener","disconnect","render","classes","nonInteractive","h","Host","class","name","ref","el","id"],"sources":["src/components/stzh-carousel/stzh-carousel.scss?tag=stzh-carousel&encapsulation=scoped","src/components/stzh-carousel/stzh-carousel.tsx"],"sourcesContent":["/**\n * @prop --padding-top: Padding Top of scroll container\n * @prop --padding-bottom: Padding Bottom of scroll container\n * @prop --peek-in: Peek size (inside container) showing the next/previous slides\n * @prop --peek-out: Negative peek size (breakout of container) showing the next/previous slides\n * @prop --gutter: Space between the slides\n * @prop --snap-stop: Snap stop of scroll container\n */\n\n:host {\n --peek: calc(var(--peek-in, 0px) + var(--peek-out, 0px));\n --peek-out: #{$containerMargin};\n --padding-top: 0px;\n --padding-bottom: 0px;\n --gutter: #{space('xxxsmall')};\n --snap-stop: always;\n --slides: 1;\n --slide-size: calc((100% - (var(--slides) - 1) * var(--gutter)) / var(--slides));\n\n @include mq($from: small) {\n --peek-out: #{$containerMarginSmall};\n }\n\n @include mq($from: medium) {\n --peek-out: 0px;\n }\n\n ::slotted(*) {\n width: 100%;\n height: 100%;\n flex-shrink: 0;\n scroll-snap-align: start;\n scroll-snap-stop: var(--snap-stop);\n\n img {\n -webkit-user-drag: none;\n user-drag: none;\n -ms-user-select: none;\n -moz-user-select: none;\n -webkit-user-select: none;\n user-select: none;\n }\n }\n\n ::slotted([slot=\"actions\"]) {\n position: absolute;\n top: 0;\n left: 0;\n z-index: 1;\n pointer-events: none;\n padding: 0 var(--peek);\n\n stzh-text {\n width: auto;\n }\n\n stzh-button {\n pointer-events: all;\n }\n }\n\n ::slotted(stzh-ratio[slot=\"actions\"]) {\n stzh-space,\n stzh-hspace,\n stzh-vspace {\n padding: space('xsmall');\n }\n }\n\n ::slotted(stzh-ratio[slot=\"actions\"]) {\n --background-color: transparent;\n }\n\n /* Card */\n\n &[variant=\"cards\"] {\n --padding-top: 4px;\n --padding-bottom: 4px;\n\n --gutter: #{spaceCurveValue('tiny')};\n\n @include mq($from: medium) {\n --peek-out: #{$containerMarginMedium};\n --gutter: #{spaceCurveValue('tiny', 'medium')};\n }\n\n @include mq($from: large) {\n --peek-out: #{$containerMarginLarge};\n --gutter: #{spaceCurveValue('tiny', 'large')};\n }\n\n @include mq($from: ultra) {\n --peek-out: calc((100vw - #{$containerMaxWidth} - var(--stzh-scrollbar-width, 0px)) / 2);\n }\n }\n\n &[variant=\"cards\"] ::slotted([slot=\"actions\"]) {\n position: relative;\n order: 1;\n margin-top: calc(#{space('medium')} - var(--padding-bottom));\n }\n\n /* No peek */\n\n &[no-peek]:not([no-peek=\"false\"]) {\n --peek-out: 0px;\n --peek-in: 0px;\n }\n}\n\n.stzh-carousel {\n position: relative;\n display: flex;\n flex-direction: column;\n width: calc(100% + var(--peek-out) * 2);\n margin-left: calc(var(--peek-out) / -1);\n margin-right: calc(var(--peek-out) / -1);\n\n &__vhidden {\n @include visuallyhidden;\n }\n\n &__scroll {\n position: relative;\n grid-area: slides;\n display: grid;\n width: 100%;\n height: 100%;\n place-items: center;\n overflow-x: auto;\n overflow-y: visible;\n grid-auto-flow: column;\n grid-auto-columns: var(--slide-size);\n grid-auto-rows: 100%;\n column-gap: var(--gutter);\n -webkit-overflow-scrolling: touch;\n scrollbar-width: none;\n -ms-overflow-style: none;\n scroll-behavior: smooth;\n overscroll-behavior-x: contain;\n scroll-snap-type: x mandatory;\n scroll-padding: 0 var(--peek);\n padding: var(--padding-top) var(--peek) var(--padding-bottom);\n\n @media (prefers-reduced-motion: reduce) {\n scroll-behavior: auto;\n }\n\n &::-webkit-scrollbar {\n display: none;\n }\n }\n\n &--is-draggable &__scroll {\n cursor: grab;\n }\n\n &--is-dragging &__scroll {\n cursor: grabbing;\n }\n\n &--is-disabled &__scroll {\n cursor: not-allowed;\n overflow: hidden;\n }\n\n &--is-non-interactive {\n pointer-events: none;\n touch-action: none;\n }\n}\n","import {\n Component,\n Host,\n h,\n Element,\n Prop,\n Method,\n Event,\n EventEmitter,\n Watch,\n State\n} from \"@stencil/core\";\n\nimport {\n StzhCarouselSlideStartEvent,\n StzhCarouselSlidePassedEvent,\n StzhCarouselSlideEndEvent\n} from \"../../index\";\n\nimport { isStzhElement } from \"../../utils/utils\";\nimport { StzhCarouselLocalizedText } from \"./stzh-carousel.localization\"\n\nimport {\n media,\n addMediaChangeListener,\n removeMediaChangeListener\n} from '../../utils/media-utils';\n\nconst reducedMotionMedia = window.matchMedia(\"(prefers-reduced-motion: reduce)\");\n\nlet carouselCounter = 0;\n\n/*\n* Inspired by:\n*\n* - https://github.com/barthy-koeln/scroll-snap-slider\n* - https://tannerhodges.github.io/snap-slider/\n* - https://www.w3.org/WAI/ARIA/apg/patterns/carousel/examples/carousel-1-prev-next/\n* - https://dev.to/jasonwebb/how-to-build-a-more-accessible-carousel-or-slider-35lp\n* - http://web-accessibility.carnegiemuseums.org/code/carousels/\n*/\n\n/**\n * @slot - Slot any element\n * @slot actions - Slot for `stzh-actions` element\n */\n@Component({\n tag: \"stzh-carousel\",\n styleUrl: \"stzh-carousel.scss\",\n scoped: true\n})\nexport class StzhCarousel {\n /** Translation strings */\n @Prop() localization: StzhCarouselLocalizedText;\n\n /** Carousel variant */\n @Prop({ reflect: true }) variant: \"default\" | \"cards\" = \"default\";\n\n /** Whether carousel is disabled */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /** Whether to remove inside/outside peek. */\n @Prop({ reflect: true }) noPeek: boolean = false;\n\n /** Slides number */\n @Prop() slides: number = 1;\n /** Slides number above small breakpoint */\n @Prop() slidesSmall: number = 0;\n /** Slides number above medium breakpoint */\n @Prop() slidesMedium: number = 0;\n /** Slides number above large breakpoint */\n @Prop() slidesLarge: number = 0;\n /** Slides number above ultra breakpoint */\n @Prop() slidesUltra: number = 0;\n\n // /** How many slides per swipe */\n // @Prop() swipeSlides: number = 1;\n // /** How many slides per swipe above small breakpoint */\n // @Prop() swipeSlidesSmall: number = 0;\n // /** How many slides per swipe above medium breakpoint */\n // @Prop() swipeSlidesMedium: number = 0;\n // /** How many slides per swipe above large breakpoint */\n // @Prop() swipeSlidesLarge: number = 0;\n // /** How many slides per swipe above ultra breakpoint */\n // @Prop() swipeSlidesUltra: number = 0;\n\n /** Active slide (readonly) */\n @Prop() slide: number = 0;\n\n /**\n * Whether autoplay is enabled.\n * Gets paused, when user has focus inside carousel element or hovers over it.\n * Also when reduced motion media query is active or carousel is set disabled.\n * Gets disabled permanently, when user interacts with carousel manually (clicks prev/next, scrolls or drags)\n */\n @Prop({ mutable: true }) autoplay: boolean = false;\n\n /** Timeout delay in milliseconds used for autoplay */\n @Prop() autoplayTimeout: number = 3000;\n\n /** Whether scrolling & dragging should be disabled */\n @Prop() nonInteractive: boolean = false;\n\n /** Whether drag with mouse should be disabled (still will be able to scroll with wheeling or arrow keys) */\n @Prop() preventMouseDrag: boolean = false;\n\n /** Whether autoplay pause should be prevented when user hovers/focuses carousel */\n @Prop() preventAutoplayPause: boolean = false;\n\n /** Whether autoplay stop should be prevented when user scroll or drags carousel */\n @Prop() preventAutoplayStop: boolean = false;\n\n /**\n * Enable all slides to be tabbable (will disable prev/next arrows from being tabbable).\n * By default only the visible slides will be tabbable and the prev/next can be used to change slides\n * (enabled when `variant` is set to `cards`).\n */\n @Prop() tabThrough: boolean = false;\n\n\n /** Timeout delay in milliseconds used to catch the end of scroll events */\n @State() scrollTimeout: number = 100;\n\n /** Minimum drag distance that needs to be reached to swipe to next/previous slide(s). */\n @State() distanceQuickSwipe: number = 40;\n\n /** Minimum drag distance that neeeds to be reached to prevent click on slide elements. */\n @State() distancePreventClick: number = 6;\n\n @Element() element: HTMLStzhCarouselElement;\n\n /** Slide start event */\n @Event() stzhSlideStart: EventEmitter<StzhCarouselSlideStartEvent>;\n\n /** Slide passed event */\n @Event() stzhSlidePassed: EventEmitter<StzhCarouselSlidePassedEvent>;\n\n /** Slide end event */\n @Event() stzhSlideEnd: EventEmitter<StzhCarouselSlideEndEvent>;\n\n /** Scroll to a slide by index */\n @Method()\n async slideTo(index, behaviour: \"auto\" | \"smooth\" = \"smooth\") {\n this.scrollToSlide(index, behaviour);\n }\n\n /** Scroll to previous snap point */\n @Method()\n async slideToPrevious(behaviour: \"auto\" | \"smooth\" = \"smooth\") {\n this.scrollToPreviousSnapPoint(behaviour);\n }\n\n /** Scroll to next snap point */\n @Method()\n async slideToNext(behaviour: \"auto\" | \"smooth\" = \"smooth\") {\n this.scrollToNextSnapPoint(behaviour);\n }\n\n @Watch(\"disabled\")\n disabledWatcher() {\n if (this.disabled) {\n this.scrollElement && this.scrollElement.removeEventListener(\"scroll\", this.onScroll);\n this.scrollTimeoutId && window.clearTimeout(this.scrollTimeoutId);\n this.scrollTimeoutId = null;\n this.element.removeEventListener(\"mouseenter\", this.onMouseenter);\n this.element.removeEventListener(\"mouseleave\", this.onMouseleave);\n this.element.removeEventListener(\"focusin\", this.onFocusin);\n this.element.removeEventListener(\"focusout\", this.onFocusout);\n this.onReducedMotionMediaChange();\n reducedMotionMedia && reducedMotionMedia.removeEventListener(\"change\", this.onReducedMotionMediaChange);\n } else {\n this.scrollElement && this.scrollElement.addEventListener(\"scroll\", this.onScroll, { passive: true });\n this.element.addEventListener(\"mouseenter\", this.onMouseenter);\n this.element.addEventListener(\"mouseleave\", this.onMouseleave);\n this.element.addEventListener(\"focusin\", this.onFocusin);\n this.element.addEventListener(\"focusout\", this.onFocusout);\n reducedMotionMedia && reducedMotionMedia.addEventListener(\"change\", this.onReducedMotionMediaChange);\n }\n }\n\n @Watch(\"disabled\")\n @Watch(\"preventMouseDrag\")\n preventMouseDragWatcher() {\n if (this.preventMouseDrag || this.disabled) {\n this.disableTimeoutId && window.clearTimeout(this.disableTimeoutId);\n this.disableTimeoutId = null;\n this.scrollElement && this.scrollElement.removeEventListener(\"mousedown\", this.startDragging);\n this.lastX = null;\n } else {\n this.scrollElement && this.scrollElement.addEventListener(\"mousedown\", this.startDragging);\n }\n }\n\n @Watch(\"autoplay\")\n @Watch(\"autoplayDisabledByMotionMedia\")\n @Watch(\"autoplayDisabledByMouse\")\n @Watch(\"autoplayDisabledByFocus\")\n @Watch(\"autoplayDisabledByScroll\")\n @Watch(\"autoplayDisabledByDrag\")\n @Watch(\"autoplayTimeout\")\n @Watch(\"disabled\")\n autoplayRunningWatcher() {\n if (\n !this.autoplay\n || this.disabled\n || this.autoplayDisabledByMotionMedia\n || this.autoplayDisabledByMouse\n || this.autoplayDisabledByFocus\n || this.autoplayDisabledByScroll\n || this.autoplayDisabledByDrag\n ) {\n this.autoplayIntervalId && window.clearInterval(this.autoplayIntervalId);\n this.autoplayIntervalId = null;\n this.autoplayRunning = false;\n } else {\n this.autoplayIntervalId && window.clearInterval(this.autoplayIntervalId);\n this.autoplayIntervalId = window.setInterval(this.autoplayInterval, this.autoplayTimeout);\n this.autoplayRunning = true;\n }\n }\n\n @Watch(\"slideElements\")\n @Watch(\"currentSwipeSlides\")\n snapAlignWatcher() {\n this.slideElements.forEach((slide, index) => {\n const shouldSnap = (index - this.currentSwipeSlides) % this.currentSwipeSlides === 0;\n\n if (shouldSnap) {\n slide.style.removeProperty(\"scroll-snap-align\");\n } else {\n slide.style.setProperty(\"scroll-snap-align\", \"none\");\n }\n });\n }\n\n @Watch(\"slide\")\n @Watch(\"variant\")\n @Watch(\"slideElements\")\n @Watch(\"currentSlides\")\n @Watch(\"tabThrough\")\n inertWatcher() {\n this.slideElements.forEach((slide, index) => {\n const isActive = this.tabThrough\n || this.variant === \"cards\"\n || index >= this.slide && index < this.slide + this.currentSlides;\n\n slide.inert = !isActive;\n\n if (isActive) {\n slide.removeAttribute(\"aria-hidden\");\n } else {\n slide.setAttribute(\"aria-hidden\", isActive ? \"false\" : \"true\");\n }\n });\n }\n\n @Watch(\"variant\")\n @Watch(\"tabThrough\")\n @Watch(\"nextElements\")\n @Watch(\"previousElements\")\n prevNextNavigationWatcher() {\n const tabThrough = this.tabThrough || this.variant === \"cards\";\n\n const setAriaAttributes = (element) => {\n const isStzh = isStzhElement(element);\n\n if (tabThrough) {\n element.setAttribute(\"aria-hidden\", \"true\");\n element.setAttribute(isStzh ? \"a11y-tabindex\" : \"tabindex\", \"-1\");\n } else {\n element.removeAttribute(\"aria-hidden\");\n element.removeAttribute(isStzh ? \"a11y-tabindex\" : \"tabindex\");\n }\n }\n\n this.nextElements.forEach(setAriaAttributes);\n this.previousElements.forEach(setAriaAttributes);\n }\n\n @Watch(\"currentSlides\")\n @Watch(\"slideElements\")\n @Watch(\"nextElements\")\n @Watch(\"previousElements\")\n @Watch(\"navigationTextElements\")\n prevNextHiddenWatcher() {\n const hideElements = this.slideElements.length <= this.currentSlides;\n\n const setHiddenAttribute = (element) => {\n if (hideElements) {\n element.setAttribute(\"hidden\", \"\");\n } else {\n element.removeAttribute(\"hidden\");\n }\n };\n\n this.navigationTextElements.forEach(setHiddenAttribute);\n this.nextElements.forEach(setHiddenAttribute);\n this.previousElements.forEach(setHiddenAttribute);\n }\n\n @Watch(\"slide\")\n @Watch(\"currentSlides\")\n @Watch(\"slideElements\")\n @Watch(\"nextElements\")\n @Watch(\"previousElements\")\n nextPrevDisabledWatcher() {\n if (!this.scrollElement) {\n return;\n }\n\n const reachedFirstSlide = this.slide === 0;\n const reachedLastSlide = this.hasReachedLastSlide();\n\n this.nextElements.forEach((element) => {\n const isStzh = isStzhElement(element);\n element.setAttribute(isStzh ? \"a11y-disabled\" : \"aria-disabled\", reachedLastSlide ? \"true\" : \"false\");\n });\n\n this.previousElements.forEach((element) => {\n const isStzh = isStzhElement(element);\n element.setAttribute(isStzh ? \"a11y-disabled\" : \"aria-disabled\", reachedFirstSlide ? \"true\" : \"false\");\n });\n }\n\n @Watch(\"nextElements\")\n nextElementsWatcher() {\n this.nextElements.forEach((nextElement) => {\n const isStzh = isStzhElement(nextElement);\n\n nextElement.addEventListener(\"click\", this.onNextClick);\n nextElement.setAttribute(isStzh ? \"a11y-controls\" : \"aria-controls\", `${this.carouselId}-scroll`);\n });\n }\n\n @Watch(\"previousElements\")\n previousElementsWatcher() {\n this.previousElements.forEach((previousElement) => {\n const isStzh = isStzhElement(previousElement);\n\n previousElement.addEventListener(\"click\", this.onPreviousClick);\n previousElement.setAttribute(isStzh ? \"a11y-controls\" : \"aria-controls\", `${this.carouselId}-scroll`);\n });\n }\n\n /** Whether autoplay is currently running */\n @State() autoplayRunning: boolean = false;\n\n /** Whether autoplay is currently disabled by reduced motion media */\n @State() autoplayDisabledByMotionMedia: boolean = false;\n\n /** Whether autoplay is currently disabled by mouse */\n @State() autoplayDisabledByMouse: boolean = false;\n\n /** Whether autoplay is currently disabled by focus */\n @State() autoplayDisabledByFocus: boolean = false;\n\n /** Whether autoplay is currently disabled by scroll */\n @State() autoplayDisabledByScroll: boolean = false;\n\n /** Whether autoplay is currently disabled by drag */\n @State() autoplayDisabledByDrag: boolean = false;\n\n /** Whether user is currently dragging with mouse */\n @State() dragging: boolean = false;\n\n /** Whether user is currently scrolling */\n @State() scrolling: boolean = false;\n\n /** Aria live text */\n @State() ariaLive: string = \"\";\n\n /** Currently shown slides */\n @State() currentSlides: number = 1;\n\n /** How many slides should be moved currently */\n @State() currentSwipeSlides: number = 1;\n\n /** Slide elements */\n @State() slideElements: HTMLElement[] = [];\n\n /** Previous elements */\n @State() previousElements: HTMLElement[] = [];\n\n /** Next elements */\n @State() nextElements: HTMLElement[] = [];\n\n /** Navigation text elements */\n @State() navigationTextElements: HTMLElement[] = [];\n\n private scrollElement: HTMLElement;\n\n /** Unique generated id */\n private carouselId: string;\n\n /** Current scroll position */\n private slideScrollLeft: number = 0;\n\n /** Flag whether scrolling was done by user or not */\n private scrolledByAutoplay: boolean = false;\n\n /** Timeout ID used to catch the end of scroll events */\n private scrollTimeoutId: number = null;\n\n /** Interval ID for autoplay */\n private autoplayIntervalId: number;\n\n /** Last drag event position */\n private lastX: number = null;\n\n /** Where the dragging started */\n private startX: number = null;\n\n /** Where the dragging started scroll position */\n private startScrollLeft: number = null;\n\n /** Timeout ID for a smooth drag release */\n private disableTimeoutId: number = null;\n\n /** Calculated size of a single item */\n private itemSize: number;\n\n /** Resize observer used to update item size */\n private resizeObserver: ResizeObserver;\n\n /** Mutation observer used to keep track of slides */\n private mutationObserver: MutationObserver;\n\n /** Whether user has just stopped dragging */\n private stoppedDragging: boolean = false;\n\n private scrollToSlide(index, behaviour: \"auto\" | \"smooth\" = \"smooth\") {\n if (this.disabled) {\n return;\n }\n\n this.scrollElement.scrollTo({\n left: index * this.itemSize,\n behavior: reducedMotionMedia.matches ? \"auto\" : behaviour\n });\n }\n\n /** Width of a slide */\n private sizingMethod() {\n const css = window.getComputedStyle(this.scrollElement);\n\n return ((this.scrollElement.firstElementChild as HTMLElement) || this.scrollElement).offsetWidth\n + parseInt(css.getPropertyValue(\"column-gap\"), 10);\n }\n\n /**\n * Calculates the active slide.\n * The scroll-snap-type property makes sure that the container snaps perfectly to integer multiples.\n */\n private calculateSlide() {\n // Math.round: Dispatch 'stzhSlidePassed' events around the center of each slide\n // Math.ceil: Dispatch 'stzhSlidePassed' events as soon as the next one is visible\n // Math.floor: Dispatch 'stzhSlidePassed' events only when the next one is fully visible\n return Math.floor(this.scrollElement.scrollLeft / this.itemSize);\n }\n\n private scrollToPreviousSnapPoint(behaviour: \"auto\" | \"smooth\" = \"smooth\") {\n if (this.disabled) {\n return;\n }\n\n let previousIndex = this.slide;\n let canSnap = false;\n\n while (!canSnap && previousIndex > 0) {\n previousIndex = previousIndex - 1;\n canSnap = (previousIndex - this.currentSwipeSlides) % this.currentSwipeSlides === 0;\n }\n\n this.slideTo(previousIndex, behaviour);\n }\n\n private scrollToNextSnapPoint(behaviour: \"auto\" | \"smooth\" = \"smooth\") {\n if (this.disabled) {\n return;\n }\n\n this.slideTo(this.slide + this.currentSwipeSlides, behaviour);\n }\n\n private update() {\n this.slide = this.calculateSlide();\n this.slideScrollLeft = this.slide * this.itemSize;\n\n this.onMutation();\n }\n\n private hasReachedLastSlide() {\n const { scrollLeft, offsetWidth, scrollWidth } = this.scrollElement;\n return Math.ceil(scrollLeft + offsetWidth) >= scrollWidth;\n }\n\n private onReducedMotionMediaChange = () => {\n this.autoplayDisabledByMotionMedia = reducedMotionMedia.matches;\n }\n\n private onMouseenter = () => {\n if (!this.preventAutoplayPause) {\n this.autoplayDisabledByMouse = true;\n }\n }\n\n private onMouseleave = () => {\n this.autoplayDisabledByMouse = false;\n }\n\n private onFocusin = () => {\n if (!this.preventAutoplayPause) {\n this.autoplayDisabledByFocus = true;\n }\n }\n\n private onFocusout = () => {\n this.autoplayDisabledByFocus = false;\n }\n\n private onPreviousClick = () => {\n this.scrollToPreviousSnapPoint();\n }\n\n private onNextClick = () => {\n this.scrollToNextSnapPoint();\n }\n\n private onSlideResize = () => {\n if (this.scrollElement) {\n this.itemSize = this.sizingMethod();\n }\n }\n\n private onMutation = () => {\n if (!this.scrollElement) {\n return;\n }\n\n this.slideElements = Array.from(this.scrollElement.children) as HTMLElement[];\n\n this.slideElements.forEach((slide, index) => {\n slide.setAttribute(\"role\", \"group\");\n slide.setAttribute(\"aria-roledescription\", \"slide\");\n slide.setAttribute(\"aria-label\", this.localization.slideLabel\n .replace(/\\{current\\}/gi, (index + 1).toString())\n .replace(/\\{total\\}/gi, this.slideElements.length.toString())\n );\n });\n\n this.previousElements = Array.from(this.element.querySelectorAll(\"[data-stzh-carousel-previous]\"));\n this.nextElements = Array.from(this.element.querySelectorAll(\"[data-stzh-carousel-next]\"));\n this.navigationTextElements = Array.from(this.element.querySelectorAll(\"[data-stzh-carousel-navigation-text]\"));\n }\n\n private onScroll = () => {\n if (this.scrollTimeoutId === null) {\n const direction = (this.scrollElement.scrollLeft > this.slideScrollLeft) ? 1 : -1;\n\n this.scrolling = true;\n\n if (!this.scrolledByAutoplay) {\n if (this.preventAutoplayStop) {\n this.autoplayDisabledByScroll = true;\n } else {\n this.autoplay = false;\n }\n }\n\n this.stzhSlideStart.emit({\n component: \"stzh-carousel\",\n index: this.slide + direction\n });\n }\n\n if (this.slide !== this.calculateSlide()) {\n this.update();\n this.stzhSlidePassed.emit({\n component: \"stzh-carousel\",\n index: this.slide\n });\n }\n\n this.scrollTimeoutId && window.clearTimeout(this.scrollTimeoutId);\n this.scrollTimeoutId = window.setTimeout(this.onScrollEnd, this.scrollTimeout);\n }\n\n private onScrollEnd = () => {\n this.scrollTimeoutId = null;\n this.update();\n\n this.scrolling = false;\n this.scrolledByAutoplay = false;\n this.autoplayDisabledByScroll = false;\n\n if (this.stoppedDragging) {\n this.stoppedDragging = false;\n this.scrollElement.style.removeProperty(\"scroll-behavior\");\n this.scrollElement.style.removeProperty(\"scroll-snap-type\");\n }\n\n if (this.tabThrough || this.variant === \"cards\") {\n this.ariaLive = \"\";\n } else {\n this.ariaLive = (this.currentSlides > 1 ? this.localization.slidesLabel : this.localization.slideLabel)\n .replace(/\\{(current|from)\\}/gi, (this.slide + 1).toString())\n .replace(/\\{to\\}/gi, (this.slide + this.currentSlides).toString())\n .replace(/\\{total\\}/gi, this.slideElements.length.toString());\n }\n\n this.stzhSlideEnd.emit({\n component: \"stzh-carousel\",\n index: this.slide\n });\n }\n\n private onMediaChange = () => {\n const ultra = media(\"ultra\").matches;\n const large = media(\"large\").matches;\n const medium = media(\"medium\").matches;\n const small = media(\"small\").matches;\n\n if (ultra && this.slidesUltra !== 0) {\n this.currentSlides = this.slidesUltra;\n } else if (large && this.slidesLarge !== 0) {\n this.currentSlides = this.slidesLarge;\n } else if (medium && this.slidesMedium !== 0) {\n this.currentSlides = this.slidesMedium;\n } else if (small && this.slidesSmall !== 0) {\n this.currentSlides = this.slidesSmall;\n } else {\n this.currentSlides = this.slides;\n }\n\n // if (ultra && this.swipeSlidesUltra !== 0) {\n // this.currentSwipeSlides = this.swipeSlidesUltra;\n // } else if (large && this.swipeSlidesLarge !== 0) {\n // this.currentSwipeSlides = this.swipeSlidesLarge;\n // } else if (medium && this.swipeSlidesMedium !== 0) {\n // this.currentSwipeSlides = this.swipeSlidesMedium;\n // } else if (small && this.swipeSlidesSmall !== 0) {\n // this.currentSwipeSlides = this.swipeSlidesSmall;\n // } else {\n // this.currentSwipeSlides = this.swipeSlides;\n // }\n\n this.currentSwipeSlides = this.currentSlides;\n }\n\n /** Scroll the slider the appropriate amount of pixels and update the last event position */\n private mouseMove = (event: MouseEvent) => {\n const distance = this.lastX - event.clientX;\n this.lastX = event.clientX;\n\n this.scrollElement.scrollLeft += distance;\n }\n\n /** Clear disable timeout, set up variables and styles and attach the listener. */\n private startDragging = (event: MouseEvent) => {\n event.preventDefault();\n\n this.disableTimeoutId && window.clearTimeout(this.disableTimeoutId);\n this.disableTimeoutId = null;\n\n this.startX = this.lastX = event.clientX;\n this.startScrollLeft = this.scrollElement.scrollLeft;\n this.scrollElement.style.setProperty(\"scroll-behavior\", \"auto\");\n this.scrollElement.style.setProperty(\"scroll-snap-type\", \"unset\");\n\n this.dragging = true;\n\n if (this.preventAutoplayStop) {\n this.autoplayDisabledByDrag = true;\n } else {\n this.autoplay = false;\n }\n\n window.addEventListener(\"mousemove\", this.mouseMove);\n window.addEventListener(\"mouseup\", this.stopDragging, { capture: true });\n window.addEventListener(\"click\", this.checkClick, { capture: true });\n }\n\n /** User stopped dragging */\n private stopDragging = (event: MouseEvent) => {\n event.preventDefault();\n\n const distance = Math.abs(this.startX - this.lastX);\n const minimumReached = distance > this.distanceQuickSwipe;\n const direction = (this.lastX > this.startX) ? 1 : -1;\n\n this.dragging = false;\n this.autoplayDisabledByDrag = false;\n\n const endDraddingLeft = this.scrollElement.scrollLeft;\n\n this.scrollElement.style.removeProperty(\"scroll-snap-type\");\n const finalLeft = this.scrollElement.scrollLeft;\n\n this.scrollElement.style.setProperty(\"scroll-snap-type\", \"unset\");\n this.scrollElement.scrollTo({ left: endDraddingLeft, behavior: \"auto\" });\n\n if (finalLeft !== this.startScrollLeft || !minimumReached) {\n this.scrollElement.scrollTo({ left: finalLeft, behavior: reducedMotionMedia.matches ? \"auto\" : \"smooth\" });\n } else if (direction === 1) {\n this.slideToPrevious();\n } else {\n this.slideToNext();\n }\n\n window.removeEventListener(\"mousemove\", this.mouseMove);\n window.removeEventListener(\"mouseup\", this.stopDragging, { capture: true });\n\n this.stoppedDragging = true;\n }\n\n private checkClick = (event: MouseEvent) => {\n const distance = Math.abs(this.startX - this.lastX);\n const minimumReached = distance > this.distancePreventClick;\n\n if (minimumReached) {\n event.preventDefault();\n }\n\n this.lastX = null;\n\n window.removeEventListener(\"click\", this.checkClick, { capture: true });\n }\n\n private autoplayInterval = () => {\n this.scrolledByAutoplay = true;\n\n if (this.hasReachedLastSlide()) {\n this.slideTo(0);\n } else {\n this.slideToNext();\n }\n }\n\n async componentWillLoad() {\n this.carouselId = `stzh-carousel-${carouselCounter++}`;\n this.onMediaChange();\n\n if (!this.localization) {\n this.localization = await window.stzhComponents.utils.fetchTranslations(this.element, \"carousel\");\n }\n }\n\n componentDidLoad() {\n this.itemSize = this.sizingMethod();\n this.update();\n\n this.disabledWatcher();\n this.preventMouseDragWatcher();\n this.autoplayRunningWatcher();\n }\n\n connectedCallback() {\n addMediaChangeListener(this.onMediaChange);\n\n this.resizeObserver = new ResizeObserver(this.onSlideResize)\n this.resizeObserver.observe(this.element)\n\n this.mutationObserver = new MutationObserver(this.onMutation);\n this.mutationObserver.observe(this.element, {\n childList: true,\n subtree: true\n });\n }\n\n disconnectedCallback() {\n this.scrollTimeoutId && window.clearTimeout(this.scrollTimeoutId);\n this.scrollTimeoutId = null;\n this.disabled = true;\n\n removeMediaChangeListener(this.onMediaChange);\n\n if (this.resizeObserver) {\n this.resizeObserver.disconnect();\n }\n\n if (this.mutationObserver) {\n this.mutationObserver.disconnect();\n }\n }\n\n render() {\n const classes = {\n \"stzh-carousel\": true,\n \"stzh-carousel--is-disabled\": this.disabled,\n \"stzh-carousel--is-draggable\": !this.preventMouseDrag,\n \"stzh-carousel--is-non-interactive\": this.nonInteractive,\n \"stzh-carousel--is-dragging\": this.dragging,\n \"stzh-carousel--is-scrolling\": this.scrolling,\n \"stzh-carousel--has-autoplay\": this.autoplay,\n \"stzh-carousel--is-autoplay-running\": this.autoplayRunning,\n };\n\n return (\n <Host\n aria-roledescription=\"carousel\"\n style={{\n '--slides': this.currentSlides.toString()\n }}\n >\n <div class={classes}>\n <slot name=\"actions\"></slot>\n <div\n class=\"stzh-carousel__vhidden\"\n aria-live={this.autoplayDisabledByFocus || this.autoplayDisabledByMouse ? \"polite\" : \"off\"}\n >\n {this.ariaLive}\n </div>\n <div\n ref={(el) => (this.scrollElement = el as HTMLDivElement)}\n id={`${this.carouselId}-scroll`}\n class=\"stzh-carousel__scroll\"\n >\n <slot></slot>\n </div>\n </div>\n </Host>\n );\n }\n}\n"],"mappings":"svDAAA,IAAMA,gBAAkB,+tJC4BxB,IAAMC,mBAAqBC,OAAOC,WAAW,oCAE7C,IAAIC,gBAAkB,E,IAqBTC,aAAY,W,2NAwVfC,KAAAC,gBAA0B,EAG1BD,KAAAE,mBAA8B,MAG9BF,KAAAG,gBAA0B,KAM1BH,KAAAI,MAAgB,KAGhBJ,KAAAK,OAAiB,KAGjBL,KAAAM,gBAA0B,KAG1BN,KAAAO,iBAA2B,KAY3BP,KAAAQ,gBAA2B,MAoE3BR,KAAAS,2BAA6B,WACnCC,EAAKC,8BAAgChB,mBAAmBiB,O,EAGlDZ,KAAAa,aAAe,WACrB,IAAKH,EAAKI,qBAAsB,CAC9BJ,EAAKK,wBAA0B,I,GAI3Bf,KAAAgB,aAAe,WACrBN,EAAKK,wBAA0B,K,EAGzBf,KAAAiB,UAAY,WAClB,IAAKP,EAAKI,qBAAsB,CAC9BJ,EAAKQ,w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AA0BnL,KAAKwE,eAE/B,GAAIxE,KAAK2K,eAAgB,CACvB3K,KAAK2K,eAAeS,Y,CAGtB,GAAIpL,KAAK8K,iBAAkB,CACzB9K,KAAK8K,iBAAiBM,Y,GAI1BnE,EAAAC,UAAAmE,OAAA,eAAA3K,EAAAV,KACE,IAAMsL,EAAU,CACd,gBAAiB,KACjB,6BAA8BtL,KAAKsH,SACnC,+BAAgCtH,KAAKyH,iBACrC,oCAAqCzH,KAAKuL,eAC1C,6BAA8BvL,KAAK2F,SACnC,8BAA+B3F,KAAKkD,UACpC,8BAA+BlD,KAAKqD,SACpC,qCAAsCrD,KAAK6H,iBAG7C,OACE2D,EAACC,KAAI,wBACkB,WACrBzH,MAAO,CACL,WAAYhE,KAAKqE,cAAc7B,aAGjCgJ,EAAA,OAAKE,MAAOJ,GACVE,EAAA,QAAMG,KAAK,YACXH,EAAA,OACEE,MAAM,yBAAwB,YACnB1L,KAAKkB,yBAA2BlB,KAAKe,wBAA0B,SAAW,OAEpFf,KAAKoE,UAERoH,EAAA,OACEI,IAAK,SAACC,GAAE,OAAMnL,EAAKe,cAAgBoK,CAA3B,EACRC,GAAI,GAAA5C,OAAGlJ,KAAKmJ,WAAU,WACtBuC,MAAM,yBAENF,EAAA,e,i1CA9vBa,G"}
@@ -1,2 +1,2 @@
1
- import{r as registerInstance,h,a as Host}from"./index-bfb5b569.js";var stzhCellCss=':host{font-family:var(--stzh-font-family-regular);font-weight:var(--stzh-font-weight-regular);font-style:normal;color:var(--stzh-base-color);-webkit-box-sizing:border-box;box-sizing:border-box;display:block;}:host[hidden]{display:none}:host *,:host *::before,:host *::after{-webkit-box-sizing:border-box;box-sizing:border-box;text-underline-offset:var(--stzh-link-text-underline-offset);text-decoration-thickness:var(--stzh-link-text-decoration-thickness)}:host .has-focus{outline:var(--stzh-flyingfocus-color) solid 0.125rem;outline-offset:0.3125rem}:host .stzh-fylingfocus-focused{outline-style:none !important}:host .stzh-fylingfocus-focused::-moz-focus-inner{border:0 !important}:host{--cell-width:100%;max-width:100%;width:var(--cell-width);-ms-flex-preferred-size:var(--cell-width);flex-basis:var(--cell-width);-ms-flex-negative:0;flex-shrink:0}:host([justify-self=start]){justify-self:flex-start}:host([justify-self=end]){justify-self:flex-end}:host([justify-self=center]){justify-self:center}:host([justify-self=between]){justify-self:space-between}:host([justify-self=around]){justify-self:space-around}:host([justify-self=evenly]){justify-self:space-evenly}:host([align-self=start]){-ms-flex-item-align:start;align-self:flex-start}:host([align-self=end]){-ms-flex-item-align:end;align-self:flex-end}:host([align-self=center]){-ms-flex-item-align:center;align-self:center}:host([align-self=baseline]){-ms-flex-item-align:baseline;align-self:baseline}:host([align-self=stretch]){-ms-flex-item-align:stretch;align-self:stretch}:host([span="1"]){--cell-width:8.3333333333%}:host([span="2"]){--cell-width:16.6666666667%}:host([span="3"]){--cell-width:25%}:host([span="4"]){--cell-width:33.3333333333%}:host([span="5"]){--cell-width:41.6666666667%}:host([span="6"]){--cell-width:50%}:host([span="7"]){--cell-width:58.3333333333%}:host([span="8"]){--cell-width:66.6666666667%}:host([span="9"]){--cell-width:75%}:host([span="10"]){--cell-width:83.3333333333%}:host([span="11"]){--cell-width:91.6666666667%}:host([span="12"]){--cell-width:100%}@media screen and (min-width: 600px){:host([span-small="1"]){--cell-width:8.3333333333%}}@media screen and (min-width: 600px){:host([span-small="2"]){--cell-width:16.6666666667%}}@media screen and (min-width: 600px){:host([span-small="3"]){--cell-width:25%}}@media screen and (min-width: 600px){:host([span-small="4"]){--cell-width:33.3333333333%}}@media screen and (min-width: 600px){:host([span-small="5"]){--cell-width:41.6666666667%}}@media screen and (min-width: 600px){:host([span-small="6"]){--cell-width:50%}}@media screen and (min-width: 600px){:host([span-small="7"]){--cell-width:58.3333333333%}}@media screen and (min-width: 600px){:host([span-small="8"]){--cell-width:66.6666666667%}}@media screen and (min-width: 600px){:host([span-small="9"]){--cell-width:75%}}@media screen and (min-width: 600px){:host([span-small="10"]){--cell-width:83.3333333333%}}@media screen and (min-width: 600px){:host([span-small="11"]){--cell-width:91.6666666667%}}@media screen and (min-width: 600px){:host([span-small="12"]){--cell-width:100%}}@media screen and (min-width: 800px){:host([span-smallheader="1"]){--cell-width:8.3333333333%}}@media screen and (min-width: 800px){:host([span-smallheader="2"]){--cell-width:16.6666666667%}}@media screen and (min-width: 800px){:host([span-smallheader="3"]){--cell-width:25%}}@media screen and (min-width: 800px){:host([span-smallheader="4"]){--cell-width:33.3333333333%}}@media screen and (min-width: 800px){:host([span-smallheader="5"]){--cell-width:41.6666666667%}}@media screen and (min-width: 800px){:host([span-smallheader="6"]){--cell-width:50%}}@media screen and (min-width: 800px){:host([span-smallheader="7"]){--cell-width:58.3333333333%}}@media screen and (min-width: 800px){:host([span-smallheader="8"]){--cell-width:66.6666666667%}}@media screen and (min-width: 800px){:host([span-smallheader="9"]){--cell-width:75%}}@media screen and (min-width: 800px){:host([span-smallheader="10"]){--cell-width:83.3333333333%}}@media screen and (min-width: 800px){:host([span-smallheader="11"]){--cell-width:91.6666666667%}}@media screen and (min-width: 800px){:host([span-smallheader="12"]){--cell-width:100%}}@media screen and (min-width: 1024px){:host([span-medium="1"]){--cell-width:8.3333333333%}}@media screen and (min-width: 1024px){:host([span-medium="2"]){--cell-width:16.6666666667%}}@media screen and (min-width: 1024px){:host([span-medium="3"]){--cell-width:25%}}@media screen and (min-width: 1024px){:host([span-medium="4"]){--cell-width:33.3333333333%}}@media screen and (min-width: 1024px){:host([span-medium="5"]){--cell-width:41.6666666667%}}@media screen and (min-width: 1024px){:host([span-medium="6"]){--cell-width:50%}}@media screen and (min-width: 1024px){:host([span-medium="7"]){--cell-width:58.3333333333%}}@media screen and (min-width: 1024px){:host([span-medium="8"]){--cell-width:66.6666666667%}}@media screen and (min-width: 1024px){:host([span-medium="9"]){--cell-width:75%}}@media screen and (min-width: 1024px){:host([span-medium="10"]){--cell-width:83.3333333333%}}@media screen and (min-width: 1024px){:host([span-medium="11"]){--cell-width:91.6666666667%}}@media screen and (min-width: 1024px){:host([span-medium="12"]){--cell-width:100%}}@media screen and (min-width: 1260px){:host([span-large="1"]){--cell-width:8.3333333333%}}@media screen and (min-width: 1260px){:host([span-large="2"]){--cell-width:16.6666666667%}}@media screen and (min-width: 1260px){:host([span-large="3"]){--cell-width:25%}}@media screen and (min-width: 1260px){:host([span-large="4"]){--cell-width:33.3333333333%}}@media screen and (min-width: 1260px){:host([span-large="5"]){--cell-width:41.6666666667%}}@media screen and (min-width: 1260px){:host([span-large="6"]){--cell-width:50%}}@media screen and (min-width: 1260px){:host([span-large="7"]){--cell-width:58.3333333333%}}@media screen and (min-width: 1260px){:host([span-large="8"]){--cell-width:66.6666666667%}}@media screen and (min-width: 1260px){:host([span-large="9"]){--cell-width:75%}}@media screen and (min-width: 1260px){:host([span-large="10"]){--cell-width:83.3333333333%}}@media screen and (min-width: 1260px){:host([span-large="11"]){--cell-width:91.6666666667%}}@media screen and (min-width: 1260px){:host([span-large="12"]){--cell-width:100%}}@media screen and (min-width: 1440px){:host([span-ultra="1"]){--cell-width:8.3333333333%}}@media screen and (min-width: 1440px){:host([span-ultra="2"]){--cell-width:16.6666666667%}}@media screen and (min-width: 1440px){:host([span-ultra="3"]){--cell-width:25%}}@media screen and (min-width: 1440px){:host([span-ultra="4"]){--cell-width:33.3333333333%}}@media screen and (min-width: 1440px){:host([span-ultra="5"]){--cell-width:41.6666666667%}}@media screen and (min-width: 1440px){:host([span-ultra="6"]){--cell-width:50%}}@media screen and (min-width: 1440px){:host([span-ultra="7"]){--cell-width:58.3333333333%}}@media screen and (min-width: 1440px){:host([span-ultra="8"]){--cell-width:66.6666666667%}}@media screen and (min-width: 1440px){:host([span-ultra="9"]){--cell-width:75%}}@media screen and (min-width: 1440px){:host([span-ultra="10"]){--cell-width:83.3333333333%}}@media screen and (min-width: 1440px){:host([span-ultra="11"]){--cell-width:91.6666666667%}}@media screen and (min-width: 1440px){:host([span-ultra="12"]){--cell-width:100%}}.stzh-cell{height:100%;padding-left:calc(var(--stzh-grid-gutter) / 2);padding-right:calc(var(--stzh-grid-gutter) / 2)}@media screen and (min-width: 600px){.stzh-cell{padding-left:calc(var(--stzh-grid-gutter-small) / 2);padding-right:calc(var(--stzh-grid-gutter-small) / 2)}}@media screen and (min-width: 1024px){.stzh-cell{padding-left:calc(var(--stzh-grid-gutter-medium) / 2);padding-right:calc(var(--stzh-grid-gutter-medium) / 2)}}';var StzhCell=function(){function e(e){registerInstance(this,e);this.span=12;this.spanSmall=0;this.spanMedium=0;this.spanLarge=0;this.spanUltra=0;this.justifySelf="auto";this.alignSelf="auto"}e.prototype.render=function(){return h(Host,null,h("div",{class:{"stzh-cell":true}},h("slot",null)))};return e}();StzhCell.style=stzhCellCss;export{StzhCell as stzh_cell};
1
+ import{r as registerInstance,h,a as Host}from"./index-bfb5b569.js";var stzhCellCss=':host{font-family:var(--stzh-font-family-regular);font-weight:var(--stzh-font-weight-regular);font-style:normal;color:var(--stzh-base-color);-webkit-box-sizing:border-box;box-sizing:border-box;display:block;}:host[hidden]{display:none}:host *,:host *::before,:host *::after{-webkit-box-sizing:border-box;box-sizing:border-box;text-underline-offset:var(--stzh-link-text-underline-offset);text-decoration-thickness:var(--stzh-link-text-decoration-thickness)}:host .has-focus{outline:var(--stzh-flyingfocus-color) solid 0.125rem;outline-offset:0.3125rem}:host .stzh-fylingfocus-focused{outline-style:none !important}:host .stzh-fylingfocus-focused::-moz-focus-inner{border:0 !important}:host{--cell-width:100%;max-width:100%;width:var(--cell-width);-ms-flex-preferred-size:var(--cell-width);flex-basis:var(--cell-width);-ms-flex-negative:0;flex-shrink:0}:host([align=left]){margin-right:auto}:host([align=right]){margin-left:auto}:host([align=middle]){margin-left:auto;margin-right:auto}:host([align-self=start]){-ms-flex-item-align:start;align-self:flex-start}:host([align-self=end]){-ms-flex-item-align:end;align-self:flex-end}:host([align-self=center]){-ms-flex-item-align:center;align-self:center}:host([align-self=baseline]){-ms-flex-item-align:baseline;align-self:baseline}:host([align-self=stretch]){-ms-flex-item-align:stretch;align-self:stretch}:host([span="1"]){--cell-width:8.3333333333%}:host([span="2"]){--cell-width:16.6666666667%}:host([span="3"]){--cell-width:25%}:host([span="4"]){--cell-width:33.3333333333%}:host([span="5"]){--cell-width:41.6666666667%}:host([span="6"]){--cell-width:50%}:host([span="7"]){--cell-width:58.3333333333%}:host([span="8"]){--cell-width:66.6666666667%}:host([span="9"]){--cell-width:75%}:host([span="10"]){--cell-width:83.3333333333%}:host([span="11"]){--cell-width:91.6666666667%}:host([span="12"]){--cell-width:100%}@media screen and (min-width: 600px){:host([span-small="1"]){--cell-width:8.3333333333%}}@media screen and (min-width: 600px){:host([span-small="2"]){--cell-width:16.6666666667%}}@media screen and (min-width: 600px){:host([span-small="3"]){--cell-width:25%}}@media screen and (min-width: 600px){:host([span-small="4"]){--cell-width:33.3333333333%}}@media screen and (min-width: 600px){:host([span-small="5"]){--cell-width:41.6666666667%}}@media screen and (min-width: 600px){:host([span-small="6"]){--cell-width:50%}}@media screen and (min-width: 600px){:host([span-small="7"]){--cell-width:58.3333333333%}}@media screen and (min-width: 600px){:host([span-small="8"]){--cell-width:66.6666666667%}}@media screen and (min-width: 600px){:host([span-small="9"]){--cell-width:75%}}@media screen and (min-width: 600px){:host([span-small="10"]){--cell-width:83.3333333333%}}@media screen and (min-width: 600px){:host([span-small="11"]){--cell-width:91.6666666667%}}@media screen and (min-width: 600px){:host([span-small="12"]){--cell-width:100%}}@media screen and (min-width: 800px){:host([span-smallheader="1"]){--cell-width:8.3333333333%}}@media screen and (min-width: 800px){:host([span-smallheader="2"]){--cell-width:16.6666666667%}}@media screen and (min-width: 800px){:host([span-smallheader="3"]){--cell-width:25%}}@media screen and (min-width: 800px){:host([span-smallheader="4"]){--cell-width:33.3333333333%}}@media screen and (min-width: 800px){:host([span-smallheader="5"]){--cell-width:41.6666666667%}}@media screen and (min-width: 800px){:host([span-smallheader="6"]){--cell-width:50%}}@media screen and (min-width: 800px){:host([span-smallheader="7"]){--cell-width:58.3333333333%}}@media screen and (min-width: 800px){:host([span-smallheader="8"]){--cell-width:66.6666666667%}}@media screen and (min-width: 800px){:host([span-smallheader="9"]){--cell-width:75%}}@media screen and (min-width: 800px){:host([span-smallheader="10"]){--cell-width:83.3333333333%}}@media screen and (min-width: 800px){:host([span-smallheader="11"]){--cell-width:91.6666666667%}}@media screen and (min-width: 800px){:host([span-smallheader="12"]){--cell-width:100%}}@media screen and (min-width: 1024px){:host([span-medium="1"]){--cell-width:8.3333333333%}}@media screen and (min-width: 1024px){:host([span-medium="2"]){--cell-width:16.6666666667%}}@media screen and (min-width: 1024px){:host([span-medium="3"]){--cell-width:25%}}@media screen and (min-width: 1024px){:host([span-medium="4"]){--cell-width:33.3333333333%}}@media screen and (min-width: 1024px){:host([span-medium="5"]){--cell-width:41.6666666667%}}@media screen and (min-width: 1024px){:host([span-medium="6"]){--cell-width:50%}}@media screen and (min-width: 1024px){:host([span-medium="7"]){--cell-width:58.3333333333%}}@media screen and (min-width: 1024px){:host([span-medium="8"]){--cell-width:66.6666666667%}}@media screen and (min-width: 1024px){:host([span-medium="9"]){--cell-width:75%}}@media screen and (min-width: 1024px){:host([span-medium="10"]){--cell-width:83.3333333333%}}@media screen and (min-width: 1024px){:host([span-medium="11"]){--cell-width:91.6666666667%}}@media screen and (min-width: 1024px){:host([span-medium="12"]){--cell-width:100%}}@media screen and (min-width: 1260px){:host([span-large="1"]){--cell-width:8.3333333333%}}@media screen and (min-width: 1260px){:host([span-large="2"]){--cell-width:16.6666666667%}}@media screen and (min-width: 1260px){:host([span-large="3"]){--cell-width:25%}}@media screen and (min-width: 1260px){:host([span-large="4"]){--cell-width:33.3333333333%}}@media screen and (min-width: 1260px){:host([span-large="5"]){--cell-width:41.6666666667%}}@media screen and (min-width: 1260px){:host([span-large="6"]){--cell-width:50%}}@media screen and (min-width: 1260px){:host([span-large="7"]){--cell-width:58.3333333333%}}@media screen and (min-width: 1260px){:host([span-large="8"]){--cell-width:66.6666666667%}}@media screen and (min-width: 1260px){:host([span-large="9"]){--cell-width:75%}}@media screen and (min-width: 1260px){:host([span-large="10"]){--cell-width:83.3333333333%}}@media screen and (min-width: 1260px){:host([span-large="11"]){--cell-width:91.6666666667%}}@media screen and (min-width: 1260px){:host([span-large="12"]){--cell-width:100%}}@media screen and (min-width: 1440px){:host([span-ultra="1"]){--cell-width:8.3333333333%}}@media screen and (min-width: 1440px){:host([span-ultra="2"]){--cell-width:16.6666666667%}}@media screen and (min-width: 1440px){:host([span-ultra="3"]){--cell-width:25%}}@media screen and (min-width: 1440px){:host([span-ultra="4"]){--cell-width:33.3333333333%}}@media screen and (min-width: 1440px){:host([span-ultra="5"]){--cell-width:41.6666666667%}}@media screen and (min-width: 1440px){:host([span-ultra="6"]){--cell-width:50%}}@media screen and (min-width: 1440px){:host([span-ultra="7"]){--cell-width:58.3333333333%}}@media screen and (min-width: 1440px){:host([span-ultra="8"]){--cell-width:66.6666666667%}}@media screen and (min-width: 1440px){:host([span-ultra="9"]){--cell-width:75%}}@media screen and (min-width: 1440px){:host([span-ultra="10"]){--cell-width:83.3333333333%}}@media screen and (min-width: 1440px){:host([span-ultra="11"]){--cell-width:91.6666666667%}}@media screen and (min-width: 1440px){:host([span-ultra="12"]){--cell-width:100%}}.stzh-cell{height:100%;padding-left:calc(var(--stzh-grid-gutter) / 2);padding-right:calc(var(--stzh-grid-gutter) / 2)}@media screen and (min-width: 600px){.stzh-cell{padding-left:calc(var(--stzh-grid-gutter-small) / 2);padding-right:calc(var(--stzh-grid-gutter-small) / 2)}}@media screen and (min-width: 1024px){.stzh-cell{padding-left:calc(var(--stzh-grid-gutter-medium) / 2);padding-right:calc(var(--stzh-grid-gutter-medium) / 2)}}';var StzhCell=function(){function e(e){registerInstance(this,e);this.span=12;this.spanSmall=0;this.spanMedium=0;this.spanLarge=0;this.spanUltra=0;this.align="none";this.alignSelf="auto"}e.prototype.render=function(){return h(Host,null,h("div",{class:{"stzh-cell":true}},h("slot",null)))};return e}();StzhCell.style=stzhCellCss;export{StzhCell as stzh_cell};
2
2
  //# sourceMappingURL=stzh-cell.entry.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["stzhCellCss","StzhCell","prototype","render","h","Host","class"],"sources":["src/components/stzh-cell/stzh-cell.scss?tag=stzh-cell&encapsulation=shadow","src/components/stzh-cell/stzh-cell.tsx"],"sourcesContent":[":host {\n // couldn't use cell-span and calcuate the with with css calc\n // since IE was calculating the width wrongly with certain viewport widths\n // so calculating it with sass and using the width directly\n --cell-width: 100%;\n\n max-width: 100%;\n width: var(--cell-width);\n flex-basis: var(--cell-width);\n flex-shrink: 0;\n}\n\n/* Justify self variants */\n\n:host([justify-self=\"start\"]) {\n justify-self: flex-start;\n}\n\n:host([justify-self=\"end\"]) {\n justify-self: flex-end;\n}\n\n:host([justify-self=\"center\"]) {\n justify-self: center;\n}\n\n:host([justify-self=\"between\"]) {\n justify-self: space-between;\n}\n\n:host([justify-self=\"around\"]) {\n justify-self: space-around;\n}\n\n:host([justify-self=\"evenly\"]) {\n justify-self: space-evenly;\n}\n\n/* Align self variants */\n\n:host([align-self=\"start\"]) {\n align-self: flex-start;\n}\n\n:host([align-self=\"end\"]) {\n align-self: flex-end;\n}\n\n:host([align-self=\"center\"]) {\n align-self: center;\n}\n\n:host([align-self=\"baseline\"]) {\n align-self: baseline;\n}\n\n:host([align-self=\"stretch\"]) {\n align-self: stretch;\n}\n\n@mixin cellProps($breakpoint: null) {\n @for $i from 1 through $gridCells {\n @if $breakpoint {\n :host([span-#{$breakpoint}=\"#{$i}\"]) {\n @include mq($from: $breakpoint) {\n --cell-width: #{100% / ($gridCells / $i)};\n }\n }\n } @else {\n :host([span=\"#{$i}\"]) {\n --cell-width: #{100% / ($gridCells / $i)};\n }\n }\n }\n}\n\n@include cellProps();\n\n@each $breakpoint, $size in $breakpoints {\n @include cellProps($breakpoint);\n}\n\n.stzh-cell {\n height: 100%;\n padding-left: calc(#{$gridGutter} / 2);\n padding-right: calc(#{$gridGutter} / 2);\n\n @include mq($from: small) {\n padding-left: calc(#{$gridGutterSmall} / 2);\n padding-right: calc(#{$gridGutterSmall} / 2);\n }\n\n @include mq($from: medium) {\n padding-left: calc(#{$gridGutterMedium} / 2);\n padding-right: calc(#{$gridGutterMedium} / 2);\n }\n}\n","import {\n Component,\n Host,\n h,\n Prop,\n} from \"@stencil/core\";\n\nimport { Layout } from \"../../index\";\n\n/**\n * @slot - Slot for any content\n */\n@Component({\n tag: \"stzh-cell\",\n styleUrl: \"stzh-cell.scss\",\n shadow: true\n})\nexport class StzhCell {\n /** Default span of each cell */\n @Prop() span: number = 12;\n /** Default span of each cell above small breakpoint */\n @Prop() spanSmall: number = 0;\n /** Default span of each cell above medium breakpoint */\n @Prop() spanMedium: number = 0;\n /** Default span of each cell above large breakpoint */\n @Prop() spanLarge: number = 0;\n /** Default span of each cell above ultra breakpoint */\n @Prop() spanUltra: number = 0;\n\n /** Controlling how cells are positioned along a container's main axis */\n @Prop({ reflect: true }) justifySelf: Layout.JustifySelf = \"auto\";\n\n /** Control how cells items are positioned along a container's cross axis */\n @Prop({ reflect: true }) alignSelf: Layout.AlignSelf = \"auto\";\n\n render() {\n return (\n <Host>\n <div\n class={{\n \"stzh-cell\": true\n }}\n >\n <slot></slot>\n </div>\n </Host>\n );\n }\n}\n"],"mappings":"mEAAA,IAAMA,YAAc,onP,ICiBPC,SAAQ,W,iDAEI,G,eAEK,E,gBAEC,E,eAED,E,eAEA,E,iBAG+B,O,eAGJ,M,CAEvDA,EAAAC,UAAAC,OAAA,WACE,OACEC,EAACC,KAAI,KACHD,EAAA,OACEE,MAAO,CACL,YAAa,OAGfF,EAAA,c,WA1BW,G"}
1
+ {"version":3,"names":["stzhCellCss","StzhCell","prototype","render","h","Host","class"],"sources":["src/components/stzh-cell/stzh-cell.scss?tag=stzh-cell&encapsulation=shadow","src/components/stzh-cell/stzh-cell.tsx"],"sourcesContent":[":host {\n // couldn't use cell-span and calcuate the with with css calc\n // since IE was calculating the width wrongly with certain viewport widths\n // so calculating it with sass and using the width directly\n --cell-width: 100%;\n\n max-width: 100%;\n width: var(--cell-width);\n flex-basis: var(--cell-width);\n flex-shrink: 0;\n}\n\n/* Align variants */\n\n:host([align=\"left\"]) {\n margin-right: auto;\n}\n\n:host([align=\"right\"]) {\n margin-left: auto;\n}\n\n:host([align=\"middle\"]) {\n margin-left: auto;\n margin-right: auto;\n}\n\n/* Align self variants */\n\n:host([align-self=\"start\"]) {\n align-self: flex-start;\n}\n\n:host([align-self=\"end\"]) {\n align-self: flex-end;\n}\n\n:host([align-self=\"center\"]) {\n align-self: center;\n}\n\n:host([align-self=\"baseline\"]) {\n align-self: baseline;\n}\n\n:host([align-self=\"stretch\"]) {\n align-self: stretch;\n}\n\n@mixin cellProps($breakpoint: null) {\n @for $i from 1 through $gridCells {\n @if $breakpoint {\n :host([span-#{$breakpoint}=\"#{$i}\"]) {\n @include mq($from: $breakpoint) {\n --cell-width: #{100% / ($gridCells / $i)};\n }\n }\n } @else {\n :host([span=\"#{$i}\"]) {\n --cell-width: #{100% / ($gridCells / $i)};\n }\n }\n }\n}\n\n@include cellProps();\n\n@each $breakpoint, $size in $breakpoints {\n @include cellProps($breakpoint);\n}\n\n.stzh-cell {\n height: 100%;\n padding-left: calc(#{$gridGutter} / 2);\n padding-right: calc(#{$gridGutter} / 2);\n\n @include mq($from: small) {\n padding-left: calc(#{$gridGutterSmall} / 2);\n padding-right: calc(#{$gridGutterSmall} / 2);\n }\n\n @include mq($from: medium) {\n padding-left: calc(#{$gridGutterMedium} / 2);\n padding-right: calc(#{$gridGutterMedium} / 2);\n }\n}\n","import {\n Component,\n Host,\n h,\n Prop,\n} from \"@stencil/core\";\n\nimport { Layout } from \"../../index\";\n\n/**\n * @slot - Slot for any content\n */\n@Component({\n tag: \"stzh-cell\",\n styleUrl: \"stzh-cell.scss\",\n shadow: true\n})\nexport class StzhCell {\n /** Default span of each cell */\n @Prop() span: number = 12;\n /** Default span of each cell above small breakpoint */\n @Prop() spanSmall: number = 0;\n /** Default span of each cell above medium breakpoint */\n @Prop() spanMedium: number = 0;\n /** Default span of each cell above large breakpoint */\n @Prop() spanLarge: number = 0;\n /** Default span of each cell above ultra breakpoint */\n @Prop() spanUltra: number = 0;\n\n /** Controlling how cell is aligned in main axis (sets margin: auto to left/right side) */\n @Prop({ reflect: true }) align: \"none\" | \"left\" | \"right\" | \"middle\" = \"none\";\n\n /** Control how cells items are positioned along a container's cross axis */\n @Prop({ reflect: true }) alignSelf: Layout.AlignSelf = \"auto\";\n\n render() {\n return (\n <Host>\n <div\n class={{\n \"stzh-cell\": true\n }}\n >\n <slot></slot>\n </div>\n </Host>\n );\n }\n}\n"],"mappings":"mEAAA,IAAMA,YAAc,67O,ICiBPC,SAAQ,W,iDAEI,G,eAEK,E,gBAEC,E,eAED,E,eAEA,E,WAG2C,O,eAGhB,M,CAEvDA,EAAAC,UAAAC,OAAA,WACE,OACEC,EAACC,KAAI,KACHD,EAAA,OACEE,MAAO,CACL,YAAa,OAGfF,EAAA,c,WA1BW,G"}