@oiz/stzh-components 3.0.0-beta4 → 3.0.0-beta5

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 (590) hide show
  1. package/dist/cjs/{app-globals-5897b76e.js → app-globals-82cc9313.js} +2 -2
  2. package/dist/cjs/{app-globals-5897b76e.js.map → app-globals-82cc9313.js.map} +1 -1
  3. package/dist/cjs/index-92254d32.js +20 -16
  4. package/dist/cjs/index.cjs.js.map +1 -1
  5. package/dist/cjs/loader.cjs.js +2 -2
  6. package/dist/cjs/stzh-actions.cjs.entry.js.map +1 -1
  7. package/dist/cjs/stzh-badge_3.cjs.entry.js +8 -0
  8. package/dist/cjs/stzh-badge_3.cjs.entry.js.map +1 -1
  9. package/dist/cjs/stzh-breadcrumb_2.cjs.entry.js +12 -3
  10. package/dist/cjs/stzh-breadcrumb_2.cjs.entry.js.map +1 -1
  11. package/dist/cjs/stzh-calendar.cjs.entry.js +1 -1
  12. package/dist/cjs/stzh-calendar.cjs.entry.js.map +1 -1
  13. package/dist/cjs/stzh-card-navigation.cjs.entry.js +2 -1
  14. package/dist/cjs/stzh-card-navigation.cjs.entry.js.map +1 -1
  15. package/dist/cjs/stzh-card-searchresult.cjs.entry.js +21 -32
  16. package/dist/cjs/stzh-card-searchresult.cjs.entry.js.map +1 -1
  17. package/dist/cjs/stzh-card-superteaser.cjs.entry.js +146 -0
  18. package/dist/cjs/stzh-card-superteaser.cjs.entry.js.map +1 -0
  19. package/dist/cjs/stzh-card_3.cjs.entry.js +72 -29
  20. package/dist/cjs/stzh-card_3.cjs.entry.js.map +1 -1
  21. package/dist/cjs/stzh-checkbox.cjs.entry.js +1 -1
  22. package/dist/cjs/stzh-checkbox.cjs.entry.js.map +1 -1
  23. package/dist/cjs/stzh-chip.cjs.entry.js +7 -2
  24. package/dist/cjs/stzh-chip.cjs.entry.js.map +1 -1
  25. package/dist/cjs/stzh-components.cjs.js +2 -2
  26. package/dist/cjs/stzh-contact.cjs.entry.js +7 -2
  27. package/dist/cjs/stzh-contact.cjs.entry.js.map +1 -1
  28. package/dist/cjs/stzh-cspace.cjs.entry.js +1 -1
  29. package/dist/cjs/stzh-cspace.cjs.entry.js.map +1 -1
  30. package/dist/cjs/stzh-cta.cjs.entry.js +10 -2
  31. package/dist/cjs/stzh-cta.cjs.entry.js.map +1 -1
  32. package/dist/cjs/stzh-datalist_2.cjs.entry.js +26 -16
  33. package/dist/cjs/stzh-datalist_2.cjs.entry.js.map +1 -1
  34. package/dist/cjs/stzh-datamessagelist-item.cjs.entry.js +2 -1
  35. package/dist/cjs/stzh-datamessagelist-item.cjs.entry.js.map +1 -1
  36. package/dist/cjs/stzh-datatable.cjs.entry.js +1 -1
  37. package/dist/cjs/stzh-datatable.cjs.entry.js.map +1 -1
  38. package/dist/cjs/stzh-datepicker_3.cjs.entry.js +1 -1
  39. package/dist/cjs/stzh-datepicker_3.cjs.entry.js.map +1 -1
  40. package/dist/cjs/stzh-daterange.cjs.entry.js +107 -0
  41. package/dist/cjs/stzh-daterange.cjs.entry.js.map +1 -0
  42. package/dist/cjs/{stzh-message.cjs.entry.js → stzh-details_2.cjs.entry.js} +155 -1
  43. package/dist/cjs/stzh-details_2.cjs.entry.js.map +1 -0
  44. package/dist/cjs/stzh-dropdown.cjs.entry.js +6 -3
  45. package/dist/cjs/stzh-dropdown.cjs.entry.js.map +1 -1
  46. package/dist/cjs/stzh-fieldset.cjs.entry.js +1 -1
  47. package/dist/cjs/stzh-fieldset.cjs.entry.js.map +1 -1
  48. package/dist/cjs/stzh-ghettobox_3.cjs.entry.js +2 -3
  49. package/dist/cjs/stzh-ghettobox_3.cjs.entry.js.map +1 -1
  50. package/dist/cjs/stzh-header.cjs.entry.js +49 -29
  51. package/dist/cjs/stzh-header.cjs.entry.js.map +1 -1
  52. package/dist/cjs/stzh-heading.cjs.entry.js +1 -1
  53. package/dist/cjs/stzh-heading.cjs.entry.js.map +1 -1
  54. package/dist/cjs/stzh-input.cjs.entry.js.map +1 -1
  55. package/dist/cjs/stzh-link.cjs.entry.js +10 -2
  56. package/dist/cjs/stzh-link.cjs.entry.js.map +1 -1
  57. package/dist/cjs/stzh-menu_2.cjs.entry.js +10 -2
  58. package/dist/cjs/stzh-menu_2.cjs.entry.js.map +1 -1
  59. package/dist/cjs/stzh-microsite-teaserlist.cjs.entry.js +2 -2
  60. package/dist/cjs/stzh-microsite-teaserlist.cjs.entry.js.map +1 -1
  61. package/dist/cjs/stzh-pagebottom.cjs.entry.js +1 -1
  62. package/dist/cjs/stzh-pagebottom.cjs.entry.js.map +1 -1
  63. package/dist/cjs/stzh-popover_2.cjs.entry.js +1 -1
  64. package/dist/cjs/stzh-popover_2.cjs.entry.js.map +1 -1
  65. package/dist/cjs/stzh-search.cjs.entry.js +83 -67
  66. package/dist/cjs/stzh-search.cjs.entry.js.map +1 -1
  67. package/dist/cjs/stzh-skin-portal-mitwirken.cjs.entry.js +1 -1
  68. package/dist/cjs/stzh-skin-portal-mitwirken.cjs.entry.js.map +1 -1
  69. package/dist/cjs/stzh-skin-storybook-preview.cjs.entry.js +1 -1
  70. package/dist/cjs/stzh-skin-storybook-preview.cjs.entry.js.map +1 -1
  71. package/dist/cjs/stzh-table.cjs.entry.js +1 -1
  72. package/dist/cjs/stzh-table.cjs.entry.js.map +1 -1
  73. package/dist/cjs/stzh-vbz-carousel.cjs.entry.js +1 -1
  74. package/dist/cjs/stzh-vbz-carousel.cjs.entry.js.map +1 -1
  75. package/dist/collection/assets/fonts/HelveticaNeueLTW05_66MediumIt.woff2 +0 -0
  76. package/dist/collection/assets/fonts.css +7 -0
  77. package/dist/collection/assets/i18n/de.json +10 -3
  78. package/dist/collection/assets/i18n/en.json +10 -3
  79. package/dist/collection/collection-manifest.json +2 -0
  80. package/dist/collection/components/stzh-accordion/stzh-accordion.css +4 -1
  81. package/dist/collection/components/stzh-accordion-item/stzh-accordion-item.css +4 -1
  82. package/dist/collection/components/stzh-actions/stzh-actions.css +4 -1
  83. package/dist/collection/components/stzh-actions/stzh-actions.js +2 -2
  84. package/dist/collection/components/stzh-actions/stzh-actions.js.map +1 -1
  85. package/dist/collection/components/stzh-actionset/stzh-actionset.css +4 -1
  86. package/dist/collection/components/stzh-amount/stzh-amount.css +4 -1
  87. package/dist/collection/components/stzh-anchornav/stzh-anchornav.css +4 -1
  88. package/dist/collection/components/stzh-appointments/stzh-appointments.css +4 -1
  89. package/dist/collection/components/stzh-archivelist/stzh-archivelist.css +4 -1
  90. package/dist/collection/components/stzh-audio/stzh-audio.css +4 -1
  91. package/dist/collection/components/stzh-badge/stzh-badge.css +4 -1
  92. package/dist/collection/components/stzh-banner/stzh-banner.css +4 -1
  93. package/dist/collection/components/stzh-breadcrumb/stzh-breadcrumb.css +5 -1
  94. package/dist/collection/components/stzh-breadcrumb/stzh-breadcrumb.js +32 -1
  95. package/dist/collection/components/stzh-breadcrumb/stzh-breadcrumb.js.map +1 -1
  96. package/dist/collection/components/stzh-breadcrumb/stzh-breadcrumb.stories.js +3 -0
  97. package/dist/collection/components/stzh-button/stzh-button.css +4 -1
  98. package/dist/collection/components/stzh-button/stzh-button.js +34 -6
  99. package/dist/collection/components/stzh-button/stzh-button.js.map +1 -1
  100. package/dist/collection/components/stzh-button/stzh-button.stories.js +1 -1
  101. package/dist/collection/components/stzh-buttongroup/stzh-buttongroup.css +4 -1
  102. package/dist/collection/components/stzh-calendar/stzh-calendar.css +5 -1
  103. package/dist/collection/components/stzh-card/stzh-card.css +4 -1
  104. package/dist/collection/components/stzh-card/stzh-card.js +3 -2
  105. package/dist/collection/components/stzh-card/stzh-card.js.map +1 -1
  106. package/dist/collection/components/stzh-card-navigation/stzh-card-navigation.css +4 -1
  107. package/dist/collection/components/stzh-card-navigation/stzh-card-navigation.js +3 -2
  108. package/dist/collection/components/stzh-card-navigation/stzh-card-navigation.js.map +1 -1
  109. package/dist/collection/components/stzh-card-searchresult/stzh-card-searchresult.css +53 -36
  110. package/dist/collection/components/stzh-card-searchresult/stzh-card-searchresult.js +72 -44
  111. package/dist/collection/components/stzh-card-searchresult/stzh-card-searchresult.js.map +1 -1
  112. package/dist/collection/components/stzh-card-searchresult/stzh-card-searchresult.stories.js +38 -22
  113. package/dist/collection/components/stzh-card-superteaser/stzh-card-superteaser.css +437 -0
  114. package/dist/collection/components/stzh-card-superteaser/stzh-card-superteaser.e2e.js +31 -0
  115. package/dist/collection/components/stzh-card-superteaser/stzh-card-superteaser.e2e.js.map +1 -0
  116. package/dist/collection/components/stzh-card-superteaser/stzh-card-superteaser.js +591 -0
  117. package/dist/collection/components/stzh-card-superteaser/stzh-card-superteaser.js.map +1 -0
  118. package/dist/collection/components/stzh-card-superteaser/stzh-card-superteaser.localization.js +2 -0
  119. package/dist/collection/components/stzh-card-superteaser/stzh-card-superteaser.localization.js.map +1 -0
  120. package/dist/collection/components/stzh-card-superteaser/stzh-card-superteaser.stories.js +222 -0
  121. package/dist/collection/components/stzh-cardlist/stzh-cardlist.css +12 -4
  122. package/dist/collection/components/stzh-carousel/stzh-carousel.css +4 -1
  123. package/dist/collection/components/stzh-cell/stzh-cell.css +4 -1
  124. package/dist/collection/components/stzh-chart/stzh-chart.css +4 -1
  125. package/dist/collection/components/stzh-checkbox/stzh-checkbox.css +5 -1
  126. package/dist/collection/components/stzh-checkboxgroup/stzh-checkboxgroup.css +4 -1
  127. package/dist/collection/components/stzh-chip/stzh-chip.css +184 -25
  128. package/dist/collection/components/stzh-chip/stzh-chip.js +99 -2
  129. package/dist/collection/components/stzh-chip/stzh-chip.js.map +1 -1
  130. package/dist/collection/components/stzh-chipgroup/stzh-chipgroup.css +4 -1
  131. package/dist/collection/components/stzh-chipselect/stzh-chipselect.css +50 -20
  132. package/dist/collection/components/stzh-chipselect/stzh-chipselect.js +111 -31
  133. package/dist/collection/components/stzh-chipselect/stzh-chipselect.js.map +1 -1
  134. package/dist/collection/components/stzh-clamp/stzh-clamp.css +4 -1
  135. package/dist/collection/components/stzh-contact/stzh-contact.css +11 -6
  136. package/dist/collection/components/stzh-contact/stzh-contact.js +24 -1
  137. package/dist/collection/components/stzh-contact/stzh-contact.js.map +1 -1
  138. package/dist/collection/components/stzh-container/stzh-container.css +4 -1
  139. package/dist/collection/components/stzh-content/stzh-content.css +4 -1
  140. package/dist/collection/components/stzh-cspace/stzh-cspace.css +13 -7
  141. package/dist/collection/components/stzh-cta/stzh-cta.css +6 -3
  142. package/dist/collection/components/stzh-cta/stzh-cta.js +31 -3
  143. package/dist/collection/components/stzh-cta/stzh-cta.js.map +1 -1
  144. package/dist/collection/components/stzh-cta/stzh-cta.stories.js +4 -1
  145. package/dist/collection/components/stzh-datalist/stzh-datalist.css +6 -1
  146. package/dist/collection/components/stzh-datalist/stzh-datalist.stories.js +27 -8
  147. package/dist/collection/components/stzh-datalist-item/stzh-datalist-item.css +7 -2
  148. package/dist/collection/components/stzh-datalist-item/stzh-datalist-item.js +62 -14
  149. package/dist/collection/components/stzh-datalist-item/stzh-datalist-item.js.map +1 -1
  150. package/dist/collection/components/stzh-datalist-item/stzh-datalist-item.stories.js +1 -1
  151. package/dist/collection/components/stzh-datamessagelist/stzh-datamessagelist.css +4 -1
  152. package/dist/collection/components/stzh-datamessagelist-item/stzh-datamessagelist-item.css +4 -1
  153. package/dist/collection/components/stzh-datamessagelist-item/stzh-datamessagelist-item.js +3 -2
  154. package/dist/collection/components/stzh-datamessagelist-item/stzh-datamessagelist-item.js.map +1 -1
  155. package/dist/collection/components/stzh-datatable/stzh-datatable.css +7 -4
  156. package/dist/collection/components/stzh-datepicker/stzh-datepicker.css +4 -1
  157. package/dist/collection/components/stzh-daterange/stzh-daterange.css +256 -0
  158. package/dist/collection/components/stzh-daterange/stzh-daterange.e2e.js +18 -0
  159. package/dist/collection/components/stzh-daterange/stzh-daterange.e2e.js.map +1 -0
  160. package/dist/collection/components/stzh-daterange/stzh-daterange.js +178 -0
  161. package/dist/collection/components/stzh-daterange/stzh-daterange.js.map +1 -0
  162. package/dist/collection/components/stzh-daterange/stzh-daterange.localization.js +2 -0
  163. package/dist/collection/components/stzh-daterange/stzh-daterange.localization.js.map +1 -0
  164. package/dist/collection/components/stzh-daterange/stzh-daterange.stories.js +51 -0
  165. package/dist/collection/components/stzh-details/stzh-details.css +4 -1
  166. package/dist/collection/components/stzh-dialog/stzh-dialog.css +4 -1
  167. package/dist/collection/components/stzh-disturber/stzh-disturber.css +4 -1
  168. package/dist/collection/components/stzh-dropdown/stzh-dropdown.css +453 -62
  169. package/dist/collection/components/stzh-dropdown/stzh-dropdown.e2e.js +1 -0
  170. package/dist/collection/components/stzh-dropdown/stzh-dropdown.e2e.js.map +1 -1
  171. package/dist/collection/components/stzh-dropdown/stzh-dropdown.js +16 -13
  172. package/dist/collection/components/stzh-dropdown/stzh-dropdown.js.map +1 -1
  173. package/dist/collection/components/stzh-dropdown/stzh-dropdown.stories.js +17 -0
  174. package/dist/collection/components/stzh-editor/stzh-editor.css +4 -1
  175. package/dist/collection/components/stzh-eventinfo/stzh-eventinfo.css +4 -1
  176. package/dist/collection/components/stzh-fieldset/stzh-fieldset.css +75 -6
  177. package/dist/collection/components/stzh-figure/stzh-figure.css +4 -1
  178. package/dist/collection/components/stzh-flyingfocus/stzh-flyingfocus.css +4 -1
  179. package/dist/collection/components/stzh-footer/stzh-footer.css +4 -1
  180. package/dist/collection/components/stzh-gallery/stzh-gallery.css +4 -1
  181. package/dist/collection/components/stzh-ghettobox/stzh-ghettobox.css +7 -9
  182. package/dist/collection/components/stzh-header/stzh-header.css +9 -6
  183. package/dist/collection/components/stzh-header/stzh-header.js +72 -30
  184. package/dist/collection/components/stzh-header/stzh-header.js.map +1 -1
  185. package/dist/collection/components/stzh-header/stzh-header.stories.js +1 -0
  186. package/dist/collection/components/stzh-heading/stzh-heading.css +26 -1
  187. package/dist/collection/components/stzh-hr/stzh-hr.css +4 -1
  188. package/dist/collection/components/stzh-hspace/stzh-hspace.css +4 -1
  189. package/dist/collection/components/stzh-icon/stzh-icon.css +4 -1
  190. package/dist/collection/components/stzh-iframe/stzh-iframe.css +4 -1
  191. package/dist/collection/components/stzh-imagecomparison/stzh-imagecomparison.css +4 -1
  192. package/dist/collection/components/stzh-input/stzh-input.css +4 -1
  193. package/dist/collection/components/stzh-invert/stzh-invert.css +4 -1
  194. package/dist/collection/components/stzh-link/stzh-link.css +4 -1
  195. package/dist/collection/components/stzh-link/stzh-link.js +34 -6
  196. package/dist/collection/components/stzh-link/stzh-link.js.map +1 -1
  197. package/dist/collection/components/stzh-link/stzh-link.stories.js +1 -1
  198. package/dist/collection/components/stzh-list/stzh-list.css +4 -1
  199. package/dist/collection/components/stzh-list-item/stzh-list-item.css +4 -1
  200. package/dist/collection/components/stzh-loader/stzh-loader.css +4 -1
  201. package/dist/collection/components/stzh-loadingbar/stzh-loadingbar.css +4 -1
  202. package/dist/collection/components/stzh-menu/stzh-menu.css +4 -1
  203. package/dist/collection/components/stzh-menu-item/stzh-menu-item.css +4 -1
  204. package/dist/collection/components/stzh-menu-item/stzh-menu-item.js +31 -3
  205. package/dist/collection/components/stzh-menu-item/stzh-menu-item.js.map +1 -1
  206. package/dist/collection/components/stzh-menu-item/stzh-menu-item.stories.js +1 -1
  207. package/dist/collection/components/stzh-message/stzh-message.css +4 -1
  208. package/dist/collection/components/stzh-microsite-teaserlist/stzh-microsite-teaserlist.css +4 -1
  209. package/dist/collection/components/stzh-microsite-teaserlist/stzh-microsite-teaserlist.js +2 -2
  210. package/dist/collection/components/stzh-microsite-teaserlist/stzh-microsite-teaserlist.js.map +1 -1
  211. package/dist/collection/components/stzh-monthyearpicker/stzh-monthyearpicker.css +4 -1
  212. package/dist/collection/components/stzh-olmap/stzh-olmap.css +4 -1
  213. package/dist/collection/components/stzh-overlay/stzh-overlay.css +4 -1
  214. package/dist/collection/components/stzh-page-skiplinks/stzh-page-skiplinks.css +4 -1
  215. package/dist/collection/components/stzh-pagebottom/stzh-pagebottom.css +5 -2
  216. package/dist/collection/components/stzh-pagecontent/stzh-pagecontent.css +4 -1
  217. package/dist/collection/components/stzh-pagetitle/stzh-pagetitle.css +4 -1
  218. package/dist/collection/components/stzh-pagetitle-hero/stzh-pagetitle-hero.css +4 -1
  219. package/dist/collection/components/stzh-pagination/stzh-pagination.css +4 -1
  220. package/dist/collection/components/stzh-panorama/stzh-panorama.css +4 -1
  221. package/dist/collection/components/stzh-popover/stzh-popover.css +4 -1
  222. package/dist/collection/components/stzh-print/stzh-print.css +4 -1
  223. package/dist/collection/components/stzh-progressbar/stzh-progressbar.css +4 -1
  224. package/dist/collection/components/stzh-progressbar-item/stzh-progressbar-item.css +4 -1
  225. package/dist/collection/components/stzh-radio/stzh-radio.css +5 -1
  226. package/dist/collection/components/stzh-radiogroup/stzh-radiogroup.css +4 -1
  227. package/dist/collection/components/stzh-ratio/stzh-ratio.css +4 -1
  228. package/dist/collection/components/stzh-readspeaker/stzh-readspeaker.css +4 -1
  229. package/dist/collection/components/stzh-richtext/stzh-richtext.css +10 -7
  230. package/dist/collection/components/stzh-row/stzh-row.css +4 -1
  231. package/dist/collection/components/stzh-saptcha/stzh-saptcha.css +4 -1
  232. package/dist/collection/components/stzh-scrollup/stzh-scrollup.css +4 -1
  233. package/dist/collection/components/stzh-search/stzh-search.css +25 -22
  234. package/dist/collection/components/stzh-search/stzh-search.js +120 -67
  235. package/dist/collection/components/stzh-search/stzh-search.js.map +1 -1
  236. package/dist/collection/components/stzh-search/stzh-search.localization.js.map +1 -1
  237. package/dist/collection/components/stzh-search/stzh-search.stories.js +108 -39
  238. package/dist/collection/components/stzh-section/stzh-section.css +4 -1
  239. package/dist/collection/components/stzh-share/stzh-share.css +4 -1
  240. package/dist/collection/components/stzh-show/stzh-show.css +4 -1
  241. package/dist/collection/components/stzh-show/stzh-show.js +0 -1
  242. package/dist/collection/components/stzh-show/stzh-show.js.map +1 -1
  243. package/dist/collection/components/stzh-sitemap/stzh-sitemap.css +4 -1
  244. package/dist/collection/components/stzh-skin-portal-mitwirken/stzh-skin-portal-mitwirken.css +26 -17
  245. package/dist/collection/components/stzh-skin-storybook-preview/stzh-skin-storybook-preview.css +13 -10
  246. package/dist/collection/components/stzh-skiplink/stzh-skiplink.css +4 -1
  247. package/dist/collection/components/stzh-sortable/stzh-sortable.css +4 -1
  248. package/dist/collection/components/stzh-space/stzh-space.css +4 -1
  249. package/dist/collection/components/stzh-status/stzh-status.css +4 -1
  250. package/dist/collection/components/stzh-sticky/stzh-sticky.css +4 -1
  251. package/dist/collection/components/stzh-sticky-actions/stzh-sticky-actions.css +4 -1
  252. package/dist/collection/components/stzh-table/stzh-table.css +7 -4
  253. package/dist/collection/components/stzh-tag/stzh-tag.css +4 -1
  254. package/dist/collection/components/stzh-tag/stzh-tag.js +3 -2
  255. package/dist/collection/components/stzh-tag/stzh-tag.js.map +1 -1
  256. package/dist/collection/components/stzh-text/stzh-text.css +9 -1
  257. package/dist/collection/components/stzh-textandimage/stzh-textandimage.css +4 -1
  258. package/dist/collection/components/stzh-timeline/stzh-timeline.css +4 -1
  259. package/dist/collection/components/stzh-timeline-item/stzh-timeline-item.css +4 -1
  260. package/dist/collection/components/stzh-timepicker/stzh-timepicker.css +4 -1
  261. package/dist/collection/components/stzh-toast/stzh-toast.css +4 -1
  262. package/dist/collection/components/stzh-toastbar/stzh-toastbar.css +4 -1
  263. package/dist/collection/components/stzh-toggle/stzh-toggle.css +4 -1
  264. package/dist/collection/components/stzh-tooltip/stzh-tooltip.css +4 -1
  265. package/dist/collection/components/stzh-twocolumns/stzh-twocolumns.css +4 -1
  266. package/dist/collection/components/stzh-upload/stzh-upload.css +4 -1
  267. package/dist/collection/components/stzh-vbz-carousel/stzh-vbz-carousel.css +8 -5
  268. package/dist/collection/components/stzh-vbz-carousel/stzh-vbz-carousel.js.map +1 -1
  269. package/dist/collection/components/stzh-vbz-linechip/stzh-vbz-linechip.css +4 -1
  270. package/dist/collection/components/stzh-vbz-majorticker/stzh-vbz-majorticker.css +4 -1
  271. package/dist/collection/components/stzh-vbz-ticker/stzh-vbz-ticker.css +4 -1
  272. package/dist/collection/components/stzh-visuallyhidden/stzh-visuallyhidden.css +4 -1
  273. package/dist/collection/components/stzh-vspace/stzh-vspace.css +4 -1
  274. package/dist/collection/components/stzh-youtube/stzh-youtube.css +4 -1
  275. package/dist/collection/index.js.map +1 -1
  276. package/dist/components/index.js +1 -1
  277. package/dist/components/index2.js.map +1 -1
  278. package/dist/components/stzh-actions.js.map +1 -1
  279. package/dist/components/stzh-breadcrumb2.js +11 -3
  280. package/dist/components/stzh-breadcrumb2.js.map +1 -1
  281. package/dist/components/stzh-button2.js +8 -0
  282. package/dist/components/stzh-button2.js.map +1 -1
  283. package/dist/components/stzh-calendar2.js +1 -1
  284. package/dist/components/stzh-calendar2.js.map +1 -1
  285. package/dist/components/stzh-card-navigation.js +2 -1
  286. package/dist/components/stzh-card-navigation.js.map +1 -1
  287. package/dist/components/stzh-card-searchresult.js +73 -47
  288. package/dist/components/stzh-card-searchresult.js.map +1 -1
  289. package/dist/components/stzh-card-superteaser.d.ts +11 -0
  290. package/dist/components/stzh-card-superteaser.js +256 -0
  291. package/dist/components/stzh-card-superteaser.js.map +1 -0
  292. package/dist/components/stzh-card2.js +2 -1
  293. package/dist/components/stzh-card2.js.map +1 -1
  294. package/dist/components/stzh-cardlist2.js +1 -1
  295. package/dist/components/stzh-cardlist2.js.map +1 -1
  296. package/dist/components/stzh-checkbox.js +1 -1
  297. package/dist/components/stzh-checkbox.js.map +1 -1
  298. package/dist/components/stzh-chip2.js +11 -2
  299. package/dist/components/stzh-chip2.js.map +1 -1
  300. package/dist/components/stzh-chipselect2.js +78 -39
  301. package/dist/components/stzh-chipselect2.js.map +1 -1
  302. package/dist/components/stzh-contact.js +8 -2
  303. package/dist/components/stzh-contact.js.map +1 -1
  304. package/dist/components/stzh-cspace.js +1 -1
  305. package/dist/components/stzh-cspace.js.map +1 -1
  306. package/dist/components/stzh-cta.js +10 -2
  307. package/dist/components/stzh-cta.js.map +1 -1
  308. package/dist/components/stzh-datalist-item2.js +26 -15
  309. package/dist/components/stzh-datalist-item2.js.map +1 -1
  310. package/dist/components/stzh-datalist2.js +1 -1
  311. package/dist/components/stzh-datalist2.js.map +1 -1
  312. package/dist/components/stzh-datamessagelist-item.js +2 -1
  313. package/dist/components/stzh-datamessagelist-item.js.map +1 -1
  314. package/dist/components/stzh-datatable.js +1 -1
  315. package/dist/components/stzh-datatable.js.map +1 -1
  316. package/dist/components/stzh-daterange.d.ts +11 -0
  317. package/dist/components/stzh-daterange.js +143 -0
  318. package/dist/components/stzh-daterange.js.map +1 -0
  319. package/dist/components/stzh-dropdown2.js +6 -3
  320. package/dist/components/stzh-dropdown2.js.map +1 -1
  321. package/dist/components/stzh-fieldset.js +1 -1
  322. package/dist/components/stzh-fieldset.js.map +1 -1
  323. package/dist/components/stzh-ghettobox2.js +1 -1
  324. package/dist/components/stzh-ghettobox2.js.map +1 -1
  325. package/dist/components/stzh-header.js +49 -29
  326. package/dist/components/stzh-header.js.map +1 -1
  327. package/dist/components/stzh-heading2.js +1 -1
  328. package/dist/components/stzh-heading2.js.map +1 -1
  329. package/dist/components/stzh-input2.js.map +1 -1
  330. package/dist/components/stzh-link2.js +10 -2
  331. package/dist/components/stzh-link2.js.map +1 -1
  332. package/dist/components/stzh-menu-item2.js +10 -2
  333. package/dist/components/stzh-menu-item2.js.map +1 -1
  334. package/dist/components/stzh-message.js +1 -92
  335. package/dist/components/stzh-message.js.map +1 -1
  336. package/dist/{esm/stzh-message.entry.js → components/stzh-message2.js} +50 -9
  337. package/dist/components/stzh-message2.js.map +1 -0
  338. package/dist/components/stzh-microsite-teaserlist.js +18 -24
  339. package/dist/components/stzh-microsite-teaserlist.js.map +1 -1
  340. package/dist/components/stzh-pagebottom.js +1 -1
  341. package/dist/components/stzh-pagebottom.js.map +1 -1
  342. package/dist/components/stzh-radio2.js +1 -1
  343. package/dist/components/stzh-radio2.js.map +1 -1
  344. package/dist/components/stzh-richtext2.js +1 -1
  345. package/dist/components/stzh-richtext2.js.map +1 -1
  346. package/dist/components/stzh-search.js +106 -81
  347. package/dist/components/stzh-search.js.map +1 -1
  348. package/dist/components/stzh-show2.js +0 -1
  349. package/dist/components/stzh-show2.js.map +1 -1
  350. package/dist/components/stzh-skin-portal-mitwirken.js +1 -1
  351. package/dist/components/stzh-skin-portal-mitwirken.js.map +1 -1
  352. package/dist/components/stzh-skin-storybook-preview.js +1 -1
  353. package/dist/components/stzh-skin-storybook-preview.js.map +1 -1
  354. package/dist/components/stzh-table.js +1 -1
  355. package/dist/components/stzh-table.js.map +1 -1
  356. package/dist/components/stzh-tag2.js +2 -1
  357. package/dist/components/stzh-tag2.js.map +1 -1
  358. package/dist/components/stzh-text2.js +1 -1
  359. package/dist/components/stzh-text2.js.map +1 -1
  360. package/dist/components/stzh-vbz-carousel.js +1 -1
  361. package/dist/components/stzh-vbz-carousel.js.map +1 -1
  362. package/dist/esm/{app-globals-6a7ed0f4.js → app-globals-d7eff0a5.js} +2 -2
  363. package/dist/esm/{app-globals-6a7ed0f4.js.map → app-globals-d7eff0a5.js.map} +1 -1
  364. package/dist/esm/index-e3050b18.js +20 -16
  365. package/dist/esm/index.js.map +1 -1
  366. package/dist/esm/loader.js +2 -2
  367. package/dist/esm/stzh-actions.entry.js.map +1 -1
  368. package/dist/esm/stzh-badge_3.entry.js +8 -0
  369. package/dist/esm/stzh-badge_3.entry.js.map +1 -1
  370. package/dist/esm/stzh-breadcrumb_2.entry.js +13 -4
  371. package/dist/esm/stzh-breadcrumb_2.entry.js.map +1 -1
  372. package/dist/esm/stzh-calendar.entry.js +1 -1
  373. package/dist/esm/stzh-calendar.entry.js.map +1 -1
  374. package/dist/esm/stzh-card-navigation.entry.js +2 -1
  375. package/dist/esm/stzh-card-navigation.entry.js.map +1 -1
  376. package/dist/esm/stzh-card-searchresult.entry.js +21 -32
  377. package/dist/esm/stzh-card-searchresult.entry.js.map +1 -1
  378. package/dist/esm/stzh-card-superteaser.entry.js +142 -0
  379. package/dist/esm/stzh-card-superteaser.entry.js.map +1 -0
  380. package/dist/esm/stzh-card_3.entry.js +72 -29
  381. package/dist/esm/stzh-card_3.entry.js.map +1 -1
  382. package/dist/esm/stzh-checkbox.entry.js +1 -1
  383. package/dist/esm/stzh-checkbox.entry.js.map +1 -1
  384. package/dist/esm/stzh-chip.entry.js +7 -2
  385. package/dist/esm/stzh-chip.entry.js.map +1 -1
  386. package/dist/esm/stzh-components.js +2 -2
  387. package/dist/esm/stzh-contact.entry.js +7 -2
  388. package/dist/esm/stzh-contact.entry.js.map +1 -1
  389. package/dist/esm/stzh-cspace.entry.js +1 -1
  390. package/dist/esm/stzh-cspace.entry.js.map +1 -1
  391. package/dist/esm/stzh-cta.entry.js +10 -2
  392. package/dist/esm/stzh-cta.entry.js.map +1 -1
  393. package/dist/esm/stzh-datalist_2.entry.js +26 -16
  394. package/dist/esm/stzh-datalist_2.entry.js.map +1 -1
  395. package/dist/esm/stzh-datamessagelist-item.entry.js +2 -1
  396. package/dist/esm/stzh-datamessagelist-item.entry.js.map +1 -1
  397. package/dist/esm/stzh-datatable.entry.js +1 -1
  398. package/dist/esm/stzh-datatable.entry.js.map +1 -1
  399. package/dist/esm/stzh-datepicker_3.entry.js +1 -1
  400. package/dist/esm/stzh-datepicker_3.entry.js.map +1 -1
  401. package/dist/esm/stzh-daterange.entry.js +103 -0
  402. package/dist/esm/stzh-daterange.entry.js.map +1 -0
  403. package/dist/esm/stzh-details_2.entry.js +208 -0
  404. package/dist/esm/stzh-details_2.entry.js.map +1 -0
  405. package/dist/esm/stzh-dropdown.entry.js +6 -3
  406. package/dist/esm/stzh-dropdown.entry.js.map +1 -1
  407. package/dist/esm/stzh-fieldset.entry.js +1 -1
  408. package/dist/esm/stzh-fieldset.entry.js.map +1 -1
  409. package/dist/esm/stzh-ghettobox_3.entry.js +2 -3
  410. package/dist/esm/stzh-ghettobox_3.entry.js.map +1 -1
  411. package/dist/esm/stzh-header.entry.js +49 -29
  412. package/dist/esm/stzh-header.entry.js.map +1 -1
  413. package/dist/esm/stzh-heading.entry.js +1 -1
  414. package/dist/esm/stzh-heading.entry.js.map +1 -1
  415. package/dist/esm/stzh-input.entry.js.map +1 -1
  416. package/dist/esm/stzh-link.entry.js +10 -2
  417. package/dist/esm/stzh-link.entry.js.map +1 -1
  418. package/dist/esm/stzh-menu_2.entry.js +10 -2
  419. package/dist/esm/stzh-menu_2.entry.js.map +1 -1
  420. package/dist/esm/stzh-microsite-teaserlist.entry.js +2 -2
  421. package/dist/esm/stzh-microsite-teaserlist.entry.js.map +1 -1
  422. package/dist/esm/stzh-pagebottom.entry.js +1 -1
  423. package/dist/esm/stzh-pagebottom.entry.js.map +1 -1
  424. package/dist/esm/stzh-popover_2.entry.js +1 -1
  425. package/dist/esm/stzh-popover_2.entry.js.map +1 -1
  426. package/dist/esm/stzh-search.entry.js +83 -67
  427. package/dist/esm/stzh-search.entry.js.map +1 -1
  428. package/dist/esm/stzh-skin-portal-mitwirken.entry.js +1 -1
  429. package/dist/esm/stzh-skin-portal-mitwirken.entry.js.map +1 -1
  430. package/dist/esm/stzh-skin-storybook-preview.entry.js +1 -1
  431. package/dist/esm/stzh-skin-storybook-preview.entry.js.map +1 -1
  432. package/dist/esm/stzh-table.entry.js +1 -1
  433. package/dist/esm/stzh-table.entry.js.map +1 -1
  434. package/dist/esm/stzh-vbz-carousel.entry.js +1 -1
  435. package/dist/esm/stzh-vbz-carousel.entry.js.map +1 -1
  436. package/dist/stzh-components/assets/fonts/HelveticaNeueLTW05_66MediumIt.woff2 +0 -0
  437. package/dist/stzh-components/assets/fonts.css +7 -0
  438. package/dist/stzh-components/assets/i18n/de.json +10 -3
  439. package/dist/stzh-components/assets/i18n/en.json +10 -3
  440. package/dist/stzh-components/index.esm.js.map +1 -1
  441. package/dist/stzh-components/{p-78eaea8d.js → p-05e8c18d.js} +2 -2
  442. package/dist/stzh-components/p-0aabd857.entry.js +2 -0
  443. package/dist/stzh-components/p-0aabd857.entry.js.map +1 -0
  444. package/dist/stzh-components/p-0bf70420.entry.js +2 -0
  445. package/dist/stzh-components/p-0bf70420.entry.js.map +1 -0
  446. package/dist/stzh-components/p-100d4052.entry.js +2 -0
  447. package/dist/stzh-components/p-100d4052.entry.js.map +1 -0
  448. package/dist/stzh-components/p-1be90089.entry.js +2 -0
  449. package/dist/stzh-components/p-1be90089.entry.js.map +1 -0
  450. package/dist/stzh-components/p-206ec94f.entry.js +2 -0
  451. package/dist/stzh-components/p-206ec94f.entry.js.map +1 -0
  452. package/dist/stzh-components/p-2773b08f.entry.js +2 -0
  453. package/dist/stzh-components/p-2773b08f.entry.js.map +1 -0
  454. package/dist/stzh-components/{p-53828193.entry.js → p-2ca82cdb.entry.js} +2 -2
  455. package/dist/stzh-components/{p-53828193.entry.js.map → p-2ca82cdb.entry.js.map} +1 -1
  456. package/dist/stzh-components/p-3c2d9cff.entry.js +2 -0
  457. package/dist/stzh-components/p-3c2d9cff.entry.js.map +1 -0
  458. package/dist/stzh-components/p-3ce84a88.entry.js +2 -0
  459. package/dist/stzh-components/p-3ce84a88.entry.js.map +1 -0
  460. package/dist/stzh-components/{p-5b9b2425.entry.js → p-3fa1c5a4.entry.js} +2 -2
  461. package/dist/stzh-components/p-3fa1c5a4.entry.js.map +1 -0
  462. package/dist/stzh-components/p-400f2932.entry.js +2 -0
  463. package/dist/stzh-components/p-400f2932.entry.js.map +1 -0
  464. package/dist/stzh-components/p-4db427d5.entry.js +2 -0
  465. package/dist/stzh-components/p-4db427d5.entry.js.map +1 -0
  466. package/dist/stzh-components/p-5d4a2df0.entry.js +2 -0
  467. package/dist/stzh-components/{p-10fb3950.entry.js.map → p-5d4a2df0.entry.js.map} +1 -1
  468. package/dist/stzh-components/{p-75fec3cd.entry.js → p-68d33cd3.entry.js} +2 -2
  469. package/dist/stzh-components/p-68d33cd3.entry.js.map +1 -0
  470. package/dist/stzh-components/p-6fdc4c74.entry.js +2 -0
  471. package/dist/stzh-components/p-6fdc4c74.entry.js.map +1 -0
  472. package/dist/stzh-components/p-722b9e40.entry.js +2 -0
  473. package/dist/stzh-components/p-722b9e40.entry.js.map +1 -0
  474. package/dist/stzh-components/p-72c375c7.entry.js +2 -0
  475. package/dist/stzh-components/p-72c375c7.entry.js.map +1 -0
  476. package/dist/stzh-components/p-836c4cdf.entry.js +2 -0
  477. package/dist/stzh-components/p-836c4cdf.entry.js.map +1 -0
  478. package/dist/stzh-components/{p-cde04c36.entry.js → p-8f1dbd3b.entry.js} +2 -2
  479. package/dist/stzh-components/{p-cde04c36.entry.js.map → p-8f1dbd3b.entry.js.map} +1 -1
  480. package/dist/stzh-components/{p-8cc09e67.entry.js → p-94947ab0.entry.js} +2 -2
  481. package/dist/stzh-components/p-94947ab0.entry.js.map +1 -0
  482. package/dist/stzh-components/{p-e7ac738e.entry.js → p-9b43127f.entry.js} +2 -2
  483. package/dist/stzh-components/{p-e7ac738e.entry.js.map → p-9b43127f.entry.js.map} +1 -1
  484. package/dist/stzh-components/{p-295c8995.entry.js → p-9f9d53a0.entry.js} +2 -2
  485. package/dist/stzh-components/p-9f9d53a0.entry.js.map +1 -0
  486. package/dist/stzh-components/p-accbac61.entry.js +2 -0
  487. package/dist/stzh-components/p-accbac61.entry.js.map +1 -0
  488. package/dist/stzh-components/p-b22876e5.entry.js +2 -0
  489. package/dist/stzh-components/p-b22876e5.entry.js.map +1 -0
  490. package/dist/stzh-components/{p-1b78f602.entry.js → p-ba32d7ef.entry.js} +2 -2
  491. package/dist/stzh-components/{p-1b78f602.entry.js.map → p-ba32d7ef.entry.js.map} +1 -1
  492. package/dist/stzh-components/p-bd2a2c30.entry.js +2 -0
  493. package/dist/stzh-components/p-bd2a2c30.entry.js.map +1 -0
  494. package/dist/stzh-components/p-beec9a0a.entry.js.map +1 -1
  495. package/dist/stzh-components/p-c31b1590.entry.js +9 -0
  496. package/dist/stzh-components/{p-2bbbc217.entry.js.map → p-c31b1590.entry.js.map} +1 -1
  497. package/dist/stzh-components/{p-56b6eab9.entry.js → p-cff05968.entry.js} +2 -2
  498. package/dist/stzh-components/p-cff05968.entry.js.map +1 -0
  499. package/dist/stzh-components/p-d028e43d.entry.js +2 -0
  500. package/dist/stzh-components/{p-2d57953a.entry.js.map → p-d028e43d.entry.js.map} +1 -1
  501. package/dist/stzh-components/p-dff1ce7c.entry.js +2 -0
  502. package/dist/stzh-components/p-dff1ce7c.entry.js.map +1 -0
  503. package/dist/stzh-components/{p-17de3017.entry.js → p-e5cfdb8a.entry.js} +2 -2
  504. package/dist/stzh-components/{p-17de3017.entry.js.map → p-e5cfdb8a.entry.js.map} +1 -1
  505. package/dist/stzh-components/p-f3d2dc46.entry.js +2 -0
  506. package/dist/stzh-components/{p-3e1ae32f.entry.js.map → p-f3d2dc46.entry.js.map} +1 -1
  507. package/dist/stzh-components/p-f5809e5f.entry.js.map +1 -1
  508. package/dist/stzh-components/p-f5821678.entry.js +2 -0
  509. package/dist/stzh-components/p-f5821678.entry.js.map +1 -0
  510. package/dist/stzh-components/stzh-components.css +1 -1
  511. package/dist/stzh-components/stzh-components.esm.js +1 -1
  512. package/dist/stzh-components/stzh-components.esm.js.map +1 -1
  513. package/dist/types/components/stzh-actions/stzh-actions.d.ts +1 -1
  514. package/dist/types/components/stzh-breadcrumb/stzh-breadcrumb.d.ts +5 -1
  515. package/dist/types/components/stzh-button/stzh-button.d.ts +9 -7
  516. package/dist/types/components/stzh-card-searchresult/stzh-card-searchresult.d.ts +11 -9
  517. package/dist/types/components/stzh-card-superteaser/stzh-card-superteaser.d.ts +75 -0
  518. package/dist/types/components/stzh-card-superteaser/stzh-card-superteaser.localization.d.ts +2 -0
  519. package/dist/types/components/stzh-chip/stzh-chip.d.ts +8 -0
  520. package/dist/types/components/stzh-chipselect/stzh-chipselect.d.ts +8 -4
  521. package/dist/types/components/stzh-contact/stzh-contact.d.ts +2 -0
  522. package/dist/types/components/stzh-cta/stzh-cta.d.ts +6 -3
  523. package/dist/types/components/stzh-datalist-item/stzh-datalist-item.d.ts +7 -2
  524. package/dist/types/components/stzh-daterange/stzh-daterange.d.ts +26 -0
  525. package/dist/types/components/stzh-daterange/stzh-daterange.localization.d.ts +9 -0
  526. package/dist/types/components/stzh-dropdown/stzh-dropdown.d.ts +5 -5
  527. package/dist/types/components/stzh-header/stzh-header.d.ts +8 -3
  528. package/dist/types/components/stzh-link/stzh-link.d.ts +8 -5
  529. package/dist/types/components/stzh-menu-item/stzh-menu-item.d.ts +5 -2
  530. package/dist/types/components/stzh-search/stzh-search.d.ts +5 -0
  531. package/dist/types/components/stzh-search/stzh-search.localization.d.ts +1 -1
  532. package/dist/types/components.d.ts +417 -53
  533. package/dist/types/index.d.ts +54 -6
  534. package/dist/vscode-data.json +282 -19
  535. package/package.json +1 -1
  536. package/dist/cjs/stzh-details.cjs.entry.js +0 -162
  537. package/dist/cjs/stzh-details.cjs.entry.js.map +0 -1
  538. package/dist/cjs/stzh-message.cjs.entry.js.map +0 -1
  539. package/dist/collection/components/stzh-card-searchresult/stzh-card-searchresult.localization.js +0 -2
  540. package/dist/collection/components/stzh-card-searchresult/stzh-card-searchresult.localization.js.map +0 -1
  541. package/dist/esm/stzh-details.entry.js +0 -158
  542. package/dist/esm/stzh-details.entry.js.map +0 -1
  543. package/dist/esm/stzh-message.entry.js.map +0 -1
  544. package/dist/stzh-components/p-10fb3950.entry.js +0 -2
  545. package/dist/stzh-components/p-161ae3d1.entry.js +0 -2
  546. package/dist/stzh-components/p-161ae3d1.entry.js.map +0 -1
  547. package/dist/stzh-components/p-295c8995.entry.js.map +0 -1
  548. package/dist/stzh-components/p-2bbbc217.entry.js +0 -9
  549. package/dist/stzh-components/p-2d57953a.entry.js +0 -2
  550. package/dist/stzh-components/p-2eb8f323.entry.js +0 -2
  551. package/dist/stzh-components/p-2eb8f323.entry.js.map +0 -1
  552. package/dist/stzh-components/p-3e1ae32f.entry.js +0 -2
  553. package/dist/stzh-components/p-43cc5c4d.entry.js +0 -2
  554. package/dist/stzh-components/p-43cc5c4d.entry.js.map +0 -1
  555. package/dist/stzh-components/p-45392fe0.entry.js +0 -2
  556. package/dist/stzh-components/p-45392fe0.entry.js.map +0 -1
  557. package/dist/stzh-components/p-56b6eab9.entry.js.map +0 -1
  558. package/dist/stzh-components/p-5b9b2425.entry.js.map +0 -1
  559. package/dist/stzh-components/p-75fec3cd.entry.js.map +0 -1
  560. package/dist/stzh-components/p-7658bb41.entry.js +0 -2
  561. package/dist/stzh-components/p-7658bb41.entry.js.map +0 -1
  562. package/dist/stzh-components/p-79a6b95b.entry.js +0 -2
  563. package/dist/stzh-components/p-79a6b95b.entry.js.map +0 -1
  564. package/dist/stzh-components/p-8ab62796.entry.js +0 -2
  565. package/dist/stzh-components/p-8ab62796.entry.js.map +0 -1
  566. package/dist/stzh-components/p-8cc09e67.entry.js.map +0 -1
  567. package/dist/stzh-components/p-b0626969.entry.js +0 -2
  568. package/dist/stzh-components/p-b0626969.entry.js.map +0 -1
  569. package/dist/stzh-components/p-b34a4e7c.entry.js +0 -2
  570. package/dist/stzh-components/p-b34a4e7c.entry.js.map +0 -1
  571. package/dist/stzh-components/p-b5224e53.entry.js +0 -2
  572. package/dist/stzh-components/p-b5224e53.entry.js.map +0 -1
  573. package/dist/stzh-components/p-ba37488e.entry.js +0 -2
  574. package/dist/stzh-components/p-ba37488e.entry.js.map +0 -1
  575. package/dist/stzh-components/p-cf96dafb.entry.js +0 -2
  576. package/dist/stzh-components/p-cf96dafb.entry.js.map +0 -1
  577. package/dist/stzh-components/p-d1e6afe2.entry.js +0 -2
  578. package/dist/stzh-components/p-d1e6afe2.entry.js.map +0 -1
  579. package/dist/stzh-components/p-d2ce78d1.entry.js +0 -2
  580. package/dist/stzh-components/p-d2ce78d1.entry.js.map +0 -1
  581. package/dist/stzh-components/p-ddbf653e.entry.js +0 -2
  582. package/dist/stzh-components/p-ddbf653e.entry.js.map +0 -1
  583. package/dist/stzh-components/p-e4f62382.entry.js +0 -2
  584. package/dist/stzh-components/p-e4f62382.entry.js.map +0 -1
  585. package/dist/stzh-components/p-ef849bb1.entry.js +0 -2
  586. package/dist/stzh-components/p-ef849bb1.entry.js.map +0 -1
  587. package/dist/stzh-components/p-f8ec1488.entry.js +0 -2
  588. package/dist/stzh-components/p-f8ec1488.entry.js.map +0 -1
  589. package/dist/types/components/stzh-card-searchresult/stzh-card-searchresult.localization.d.ts +0 -2
  590. /package/dist/stzh-components/{p-78eaea8d.js.map → p-05e8c18d.js.map} +0 -0
@@ -1 +1 @@
1
- {"version":3,"file":"stzh-chipselect.js","sourceRoot":"","sources":["../../../../src/components/stzh-chipselect/stzh-chipselect.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,IAAI,EACJ,CAAC,EACD,OAAO,EACP,IAAI,EACJ,KAAK,EACL,KAAK,EAEL,KAAK,EACL,QAAQ,EACR,MAAM,GACP,MAAM,eAAe,CAAC;AAQvB,OAAO,EAAE,oBAAoB,EAAE,MAAM,sCAAsC,CAAC;AAK5E,IAAI,iBAAiB,GAAG,CAAC,CAAC;AAE1B;;;;;;GAMG;AAMH,MAAM,OAAO,cAAc;;IAMjB,UAAK,GAAyB,EAAE,CAAC;IACjC,kBAAa,GAAU,EAAE,CAAC;IAsG1B,gBAAW,GAAG,KAAK,IAAI,EAAE;MAC/B,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,YAAY,CAAC;MAE/B,yBAAyB;MACzB,kCAAkC;MAClC,sBAAsB;MACtB,MAAM;IACR,CAAC,CAAA;IAEO,oBAAe,GAAG,KAAK,EAAE,IAAwB,EAAE,KAAa,EAAE,EAAE;MAC1E,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;MACxB,IAAI,CAAC,sBAAsB,GAAG,KAAK,CAAC;MAEpC,MAAM,IAAI,CAAC,iBAAiB,EAAE,CAAC;MAE/B,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC;QACnB,SAAS,EAAE,iBAAiB;QAC5B,KAAK,EAAE,IAAI,CAAC,KAAK;OAClB,CAAC,CAAA;IACJ,CAAC,CAAA;IAEO,yBAAoB,GAAG,KAAK,EAAE,KAA2C,EAAE,EAAE;MACnF,IAAI,CAAC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QAAQ,EACvB,OAAO,EAAE,IAAI,CAAC,OAAO,EACrB,KAAK,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,EACnB,KAAK,EAAE,IAAI,CAAC,KAAK,EACjB,OAAO,EAAE,IAAI,CAAC,aAAa,EAC3B,YAAY,EAAE,IAAI,CAAC,YAAY,EAC/B,YAAY,EAAE,IAAI,CAAC,oBAAoB,GACxB,CACR,CAET,CACD,CACR,CAAC;EACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import {\n Component,\n Host,\n h,\n Element,\n Prop,\n Watch,\n Event,\n EventEmitter,\n State,\n Fragment,\n Listen,\n} from \"@stencil/core\";\n\nimport {\n StzhChipselectItem,\n StzhChipselectChangeEvent,\n StzhDropdownChangeEvent\n} from \"../../index\";\n\nimport { StzhInputDescription } from \"../stzh-input/stzh-input-description\";\n\n// import { hasSlot } from \"../../utils/utils\";\nimport { StzhLocaleComponent } from \"../../utils/translation-utils\";\n\nlet chipselectCounter = 0;\n\n/**\n * @slot - Slot for `stzh-checkbox` elements\n * @slot description - Slot for description\n * @slot description-long - Slot for long description (in popover)\n * @slot description-long-title - Slot for long description title (in popover) / instead of descriptionLongTitle or description property\n * @slot error - Slot for error\n */\n@Component({\n tag: \"stzh-chipselect\",\n styleUrl: \"stzh-chipselect.scss\",\n scoped: true\n})\nexport class StzhChipselect {\n /** Translation strings */\n @Prop() localization: StzhLocaleComponent;\n\n /** The list of chips */\n @Prop() data: string | StzhChipselectItem[] = [];\n private _data: StzhChipselectItem[] = [];\n private _dataDropdown: any[] = [];\n\n /** The name of the input element */\n @Prop({ reflect: true }) name: string;\n\n /** Label */\n @Prop() label: string = \"\";\n\n /** Value */\n @Prop({ mutable: true }) value: string = \"\";\n\n /** Default value (used by reset) */\n @Prop({ mutable: true }) defaultValue: string = \"\";\n\n /** Description message (use description slot as alternative) */\n @Prop() description: string;\n\n /** Long description message appearing in a popover (use description-long slot as alternative) */\n @Prop() descriptionLong: string;\n\n /** Long description title appearing in a popover (use description-long-title slot as or description property alternative) */\n @Prop() descriptionLongTitle: string;\n\n /** One or multiple error message (use error slot as alternative) */\n @Prop() error: string | string[];\n private _error: string[];\n\n /** Invalid status */\n @Prop({ reflect: true }) invalid: boolean = false;\n\n /** Required status */\n @Prop({ reflect: true }) required: boolean = false;\n\n /** Whether all chips are disabled or not */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /** Hide `(optional)` label (or use `required` inside form ot hide it) */\n @Prop({ reflect: true }) hideOptional: boolean = false;\n\n /** Id for element which describes the input (this will be overwritten if description prop or slot is used, used by stzh-radiogroup) */\n @Prop({ attribute: \"a11y-describedby\" }) a11yDescribedby: string = \"\";\n\n @State() activeFocusOptionIndex: number = 0;\n\n @Element() element: HTMLStzhChipselectElement;\n\n /** Change event */\n @Event() stzhChange: EventEmitter<StzhChipselectChangeEvent>;\n\n @Listen(\"reset\", { target: \"document\" })\n resetListener(event: Event) {\n if ((event.target as HTMLElement).contains(this.element)) {\n requestAnimationFrame(() => {\n this.handleReset();\n });\n }\n }\n\n @Watch(\"data\")\n dataWatcher(newValue: StzhChipselectItem[] | string) {\n if (typeof newValue === \"string\") {\n this._data = JSON.parse(newValue);\n } else {\n this._data = newValue;\n }\n\n this._dataDropdown = this._data.map((data) => {\n return {\n text: data.counter\n ? `${data.label} (${data.counter})`\n : data.label,\n value: data.value\n }\n });\n }\n\n @Watch(\"error\")\n errorWatcher(newValue: string | string[]) {\n if (typeof newValue === \"string\") {\n try {\n this._error = JSON.parse(newValue);\n } catch (e) {\n if (newValue) {\n this._error = [newValue];\n } else {\n this._error = [];\n }\n }\n } else if (newValue) {\n this._error = newValue;\n } else {\n this._error = [];\n }\n }\n\n private id: string;\n private renderPromiseResolve: (value?: unknown) => void;\n\n private waitForNextRender() {\n return new Promise(resolve => this.renderPromiseResolve = resolve);\n }\n\n private handleReset = async () => {\n this.value = this.defaultValue;\n\n // this.stzhChange.emit({\n // component: \"stzh-chipselect\",\n // value: this.value\n // });\n }\n\n private handleChipClick = async (data: StzhChipselectItem, index: number) => {\n this.value = data.value;\n this.activeFocusOptionIndex = index;\n\n await this.waitForNextRender();\n\n this.stzhChange.emit({\n component: \"stzh-chipselect\",\n value: this.value\n })\n }\n\n private handleDropdownChange = async (event: CustomEvent<StzhDropdownChangeEvent>) => {\n this.value = Array.isArray(event.detail.value) ? event.detail.value[0] : event.detail.value;\n\n this.activeFocusOptionIndex = this._data.findIndex(data => {\n return data.value === this.value;\n });\n\n await this.waitForNextRender();\n\n this.stzhChange.emit({\n component: \"stzh-chipselect\",\n value: this.value\n })\n }\n\n private handleKeydown = (event: KeyboardEvent) => {\n let newActiveIndex: number = null;\n const activeOptionIndex = this.activeFocusOptionIndex;\n\n if (event.key === \"ArrowUp\" || event.key === \"ArrowLeft\") {\n event.preventDefault();\n\n if (activeOptionIndex > 0) {\n newActiveIndex = activeOptionIndex - 1;\n }\n } else if (event.key === \"ArrowDown\" || event.key === \"ArrowRight\") {\n event.preventDefault();\n\n if (activeOptionIndex < this._data.length - 1) {\n newActiveIndex = activeOptionIndex + 1;\n }\n } else if (event.key === \" \" || event.key === \"Enter\") {\n event.preventDefault();\n this.value = this._data[activeOptionIndex].value;\n\n this.stzhChange.emit({\n component: \"stzh-chipselect\",\n value: this.value\n });\n }\n\n if (newActiveIndex !== null) {\n this.activeFocusOptionIndex = newActiveIndex;\n }\n }\n\n componentDidRender() {\n if (this.renderPromiseResolve) {\n this.renderPromiseResolve();\n }\n }\n\n async componentWillLoad() {\n this.id = `stzh-chipselect-${chipselectCounter++}`;\n\n this.dataWatcher(this.data);\n this.errorWatcher(this.error);\n\n this.defaultValue = this.defaultValue || this.value;\n\n if (!this.localization) {\n this.localization = await window.stzhComponents.utils.fetchTranslations(this.element, \"chipselect\");\n }\n }\n\n render() {\n const descriptionUsed = !!this.description;\n const descriptionLongUsed = !!this.descriptionLong;\n const errorUsed = !!this.error;\n\n const classes = {\n \"stzh-chipselect\": true,\n \"stzh-chipselect--has-description\": descriptionUsed,\n \"stzh-chipselect--has-description-long\": descriptionLongUsed,\n \"stzh-chipselect--has-error\": errorUsed,\n \"stzh-chipselect--is-invalid\": this.invalid || errorUsed,\n \"stzh-chipselect--is-disabled\": this.disabled,\n \"stzh-chipselect--is-required\": this.required\n };\n\n return (\n <Host is-invalid={this.invalid || errorUsed}>\n <div class={classes}>\n <input\n type=\"hidden\"\n name={this.name}\n value={this.value}\n defaultValue={this.defaultValue}\n />\n\n {this._data.length > 0 &&\n <Fragment>\n <div\n class=\"stzh-chipselect__chips\"\n role=\"listbox\"\n tabindex=\"0\"\n aria-multiselectable=\"false\"\n aria-activedescendant={`${this.id}-option-${this.activeFocusOptionIndex}`}\n aria-describedby={`${this.id}-description ${this.a11yDescribedby}`}\n onKeyDown={this.handleKeydown}\n >\n {this._data.map((data, index) => (\n <stzh-chip\n role=\"option\"\n class={{\n \"stzh-chipselect__chip\": true,\n \"is-focused\": this.activeFocusOptionIndex === index\n }}\n label={data.label}\n counter={data.counter}\n icon={data.icon}\n type={data.type}\n inverted={data.inverted}\n variant={data.variant}\n size={data.size}\n disabled={this.disabled || data.disabled}\n active={this.value === data.value}\n aria-selected={this.value === data.value ? \"true\" : \"false\"}\n id={`${this.id}-option-${index}`}\n a11yTabindex=\"-1\"\n onClick={() => this.handleChipClick(data, index)}\n ></stzh-chip>\n ))}\n </div>\n\n <StzhInputDescription\n classPrefix=\"stzh-chipselect\"\n id={`${this.id}-description`}\n error={this._error}\n description={this.description}\n descriptionLong={this.descriptionLong}\n descriptionLongTitle={this.descriptionLongTitle}\n descriptionLongUsed={descriptionLongUsed}\n moreInfoButtonLabel={this.localization.$globals.moreInfoButtonLabel}\n />\n\n <stzh-dropdown\n class=\"stzh-chipselect__dropdown\"\n disabled={this.disabled}\n error={this._error}\n description={this.description}\n descriptionLong={this.descriptionLong}\n required={this.required}\n invalid={this.invalid}\n items={[this.value]}\n label={this.label}\n options={this._dataDropdown}\n hideOptional={this.hideOptional}\n onStzhChange={this.handleDropdownChange}\n ></stzh-dropdown>\n </Fragment>\n }\n </div>\n </Host>\n );\n }\n}\n"]}
1
+ {"version":3,"file":"stzh-chipselect.js","sourceRoot":"","sources":["../../../../src/components/stzh-chipselect/stzh-chipselect.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,IAAI,EACJ,CAAC,EACD,OAAO,EACP,IAAI,EACJ,KAAK,EACL,KAAK,EAEL,KAAK,EACL,QAAQ,EACR,MAAM,GACP,MAAM,eAAe,CAAC;AAQvB,OAAO,EAAE,oBAAoB,EAAE,MAAM,sCAAsC,CAAC;AAK5E,IAAI,iBAAiB,GAAG,CAAC,CAAC;AAE1B;;;;;;GAMG;AAMH,MAAM,OAAO,cAAc;;IAMjB,UAAK,GAAyB,EAAE,CAAC;IAiBjC,WAAM,GAAa,EAAE,CAAC;IA0GtB,gBAAW,GAAG,KAAK,IAAI,EAAE;MAC/B,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,YAAY,CAAC;MAE/B,yBAAyB;MACzB,kCAAkC;MAClC,sBAAsB;MACtB,MAAM;IACR,CAAC,CAAA;IAEO,oBAAe,GAAG,KAAK,EAAE,IAAwB,EAAE,KAAa,EAAE,EAAE;MAC1E,IAAI,IAAI,CAAC,QAAQ,EAAE;QACjB,IAAI,IAAI,CAAC,KAAK,KAAK,EAAE,IAAI,IAAI,CAAC,MAAM,CAAC,MAAM,GAAG,CAAC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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import {\n Component,\n Host,\n h,\n Element,\n Prop,\n Watch,\n Event,\n EventEmitter,\n State,\n Fragment,\n Listen,\n} from \"@stencil/core\";\n\nimport {\n StzhChipselectItem,\n StzhChipselectChangeEvent,\n // StzhDropdownChangeEvent\n} from \"../../index\";\n\nimport { StzhInputDescription } from \"../stzh-input/stzh-input-description\";\n\n// import { hasSlot } from \"../../utils/utils\";\nimport { StzhLocaleComponent } from \"../../utils/translation-utils\";\n\nlet chipselectCounter = 0;\n\n/**\n * @slot - Slot for `stzh-checkbox` elements\n * @slot description - Slot for description\n * @slot description-long - Slot for long description (in popover)\n * @slot description-long-title - Slot for long description title (in popover) / instead of descriptionLongTitle or description property\n * @slot error - Slot for error\n */\n@Component({\n tag: \"stzh-chipselect\",\n styleUrl: \"stzh-chipselect.scss\",\n scoped: true\n})\nexport class StzhChipselect {\n /** Translation strings */\n @Prop() localization: StzhLocaleComponent;\n\n /** The list of chips */\n @Prop() data: string | StzhChipselectItem[] = [];\n private _data: StzhChipselectItem[] = [];\n // private _dataDropdown: any[] = [];\n\n /** The name of the input element */\n @Prop({ reflect: true }) name: string;\n\n /** Label */\n @Prop() label: string = \"\";\n\n /** Whether label is hidden. */\n @Prop() labelHidden: boolean = false;\n\n /** Multiple */\n @Prop({ mutable: true }) multiple: boolean = false;\n\n /** Value */\n @Prop({ mutable: true }) value: string | string[] = \"\";\n private _value: string[] = [];\n\n /** Default value (used by reset) */\n @Prop({ mutable: true }) defaultValue: string | string[] = \"\";\n\n /** Description message (use description slot as alternative) */\n @Prop() description: string;\n\n /** Long description message appearing in a popover (use description-long slot as alternative) */\n @Prop() descriptionLong: string;\n\n /** Long description title appearing in a popover (use description-long-title slot as or description property alternative) */\n @Prop() descriptionLongTitle: string;\n\n /** One or multiple error message (use error slot as alternative) */\n @Prop() error: string | string[];\n private _error: string[];\n\n /** Invalid status */\n @Prop({ reflect: true }) invalid: boolean = false;\n\n /** Required status */\n @Prop({ reflect: true }) required: boolean = false;\n\n /** Whether all chips are disabled or not */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /** Hide `(optional)` label (or use `required` inside form ot hide it) */\n @Prop({ reflect: true }) hideOptional: boolean = false;\n\n /** Id for element which describes the input (this will be overwritten if description prop or slot is used, used by stzh-radiogroup) */\n @Prop({ attribute: \"a11y-describedby\" }) a11yDescribedby: string = \"\";\n\n @State() activeFocusOptionIndex: number = 0;\n\n @Element() element: HTMLStzhChipselectElement;\n\n /** Change event */\n @Event() stzhChange: EventEmitter<StzhChipselectChangeEvent>;\n\n @Listen(\"reset\", { target: \"document\" })\n resetListener(event: Event) {\n if ((event.target as HTMLElement).contains(this.element)) {\n requestAnimationFrame(() => {\n this.handleReset();\n });\n }\n }\n\n @Watch(\"value\")\n valueWatcher(newValue: string[] | string) {\n if (typeof newValue === \"string\") {\n try {\n this._value = JSON.parse(newValue);\n } catch(ex) {\n this._value = newValue ? [newValue] : [];\n }\n } else {\n this._value = newValue ? newValue : [];\n }\n }\n\n @Watch(\"data\")\n dataWatcher(newValue: StzhChipselectItem[] | string) {\n if (typeof newValue === \"string\") {\n this._data = JSON.parse(newValue);\n } else {\n this._data = newValue;\n }\n\n // this._dataDropdown = this._data.map((data) => {\n // return {\n // text: data.counter\n // ? `${data.label} (${data.counter})`\n // : data.label,\n // value: data.value\n // }\n // });\n }\n\n @Watch(\"error\")\n errorWatcher(newValue: string | string[]) {\n if (typeof newValue === \"string\") {\n try {\n this._error = JSON.parse(newValue);\n } catch (e) {\n if (newValue) {\n this._error = [newValue];\n } else {\n this._error = [];\n }\n }\n } else if (newValue) {\n this._error = newValue;\n } else {\n this._error = [];\n }\n }\n\n private id: string;\n private renderPromiseResolve: (value?: unknown) => void;\n\n private waitForNextRender() {\n return new Promise(resolve => this.renderPromiseResolve = resolve);\n }\n\n private handleReset = async () => {\n this.value = this.defaultValue;\n\n // this.stzhChange.emit({\n // component: \"stzh-chipselect\",\n // value: this.value\n // });\n }\n\n private handleChipClick = async (data: StzhChipselectItem, index: number) => {\n if (this.multiple) {\n if (data.value === \"\" && this._value.length > 0 && !(this._value.length === 1 && this._value[0] === \"\")) {\n this.value = [];\n } else if (data.value !== \"\") {\n this.value = this._value.includes(data.value)\n ? this._value.filter(value => value !== data.value)\n : [...this._value, data.value];\n }\n } else {\n this.value = [data.value]\n }\n\n this.activeFocusOptionIndex = index;\n\n await this.waitForNextRender();\n\n this.stzhChange.emit({\n component: \"stzh-chipselect\",\n value: this.multiple ? this._value[0] : this._value\n })\n }\n\n // private handleDropdownChange = async (event: CustomEvent<StzhDropdownChangeEvent>) => {\n // this.value = Array.isArray(event.detail.value) ? event.detail.value[0] : event.detail.value;\n\n // this.activeFocusOptionIndex = this._data.findIndex(data => {\n // return data.value === this.value;\n // });\n\n // await this.waitForNextRender();\n\n // this.stzhChange.emit({\n // component: \"stzh-chipselect\",\n // value: this.value\n // })\n // }\n\n private handleKeydown = (event: KeyboardEvent) => {\n let newActiveIndex: number = null;\n const activeOptionIndex = this.activeFocusOptionIndex;\n\n if (event.key === \"ArrowUp\" || event.key === \"ArrowLeft\") {\n event.preventDefault();\n\n if (activeOptionIndex > 0) {\n newActiveIndex = activeOptionIndex - 1;\n }\n } else if (event.key === \"ArrowDown\" || event.key === \"ArrowRight\") {\n event.preventDefault();\n\n if (activeOptionIndex < this._data.length - 1) {\n newActiveIndex = activeOptionIndex + 1;\n }\n } else if (event.key === \" \" || event.key === \"Enter\") {\n event.preventDefault();\n this.value = this._data[activeOptionIndex].value;\n\n this.stzhChange.emit({\n component: \"stzh-chipselect\",\n value: this.value\n });\n }\n\n if (newActiveIndex !== null) {\n this.activeFocusOptionIndex = newActiveIndex;\n }\n }\n\n componentDidRender() {\n if (this.renderPromiseResolve) {\n this.renderPromiseResolve();\n }\n }\n\n async componentWillLoad() {\n this.id = `stzh-chipselect-${chipselectCounter++}`;\n\n this.dataWatcher(this.data);\n this.errorWatcher(this.error);\n this.valueWatcher(this.value);\n\n this.defaultValue = this.defaultValue || this.value;\n\n if (!this.localization) {\n this.localization = await window.stzhComponents.utils.fetchTranslations(this.element, \"chipselect\");\n }\n }\n\n render() {\n const descriptionUsed = !!this.description;\n const descriptionLongUsed = !!this.descriptionLong;\n const errorUsed = !!this.error;\n\n const classes = {\n \"stzh-chipselect\": true,\n \"stzh-chipselect--has-description\": descriptionUsed,\n \"stzh-chipselect--has-description-long\": descriptionLongUsed,\n \"stzh-chipselect--has-error\": errorUsed,\n \"stzh-chipselect--is-invalid\": this.invalid || errorUsed,\n \"stzh-chipselect--is-disabled\": this.disabled,\n \"stzh-chipselect--is-required\": this.required,\n \"stzh-chipselect--has-label-hidden\": this.labelHidden,\n };\n\n return (\n <Host is-invalid={this.invalid || errorUsed}>\n <div class={classes}>\n {this.multiple\n ?\n <Fragment>\n {this._value.map((value) =>\n <input type=\"hidden\" name={this.name} value={value} />\n )}\n </Fragment>\n :\n <input\n type=\"hidden\"\n name={this.name}\n value={this.value}\n />\n }\n\n <label class=\"stzh-chipselect__label\" htmlFor={this.id}>\n {this.label ? this.label : <slot></slot>}\n {!this.hideOptional &&\n <span class=\"stzh-chipselect__marker\">\n <span class=\"stzh-chipselect__marker-symbol\" aria-hidden=\"true\">\n {this.required\n ? this.localization.$globals.requiredFieldMarker\n : this.localization.$globals.optionalFieldMarker\n }\n </span>\n <span class=\"stzh-chipselect__marker-text\">\n {this.required\n ? this.localization.$globals.requiredFieldText\n : this.localization.$globals.optionalFieldText\n }\n </span>\n </span>\n }\n </label>\n\n {this._data.length > 0 &&\n <Fragment>\n <div\n id={this.id}\n class=\"stzh-chipselect__chips\"\n role=\"listbox\"\n tabindex=\"0\"\n aria-multiselectable={this.multiple ? \"true\" : \"false\"}\n aria-activedescendant={`${this.id}-option-${this.activeFocusOptionIndex}`}\n aria-describedby={`${this.id}-description ${this.a11yDescribedby}`}\n onKeyDown={this.handleKeydown}\n >\n {this._data.map((data, index) => (\n <stzh-chip\n role=\"option\"\n class={{\n \"stzh-chipselect__chip\": true,\n \"is-focused\": this.activeFocusOptionIndex === index\n }}\n label={data.label}\n counter={data.counter}\n icon={data.icon}\n type={data.type}\n inverted={data.inverted}\n variant={data.variant}\n size={data.size || \"small\"}\n disabled={this.disabled || data.disabled}\n active={\n this._value.includes(data.value)\n || (!data.value && this.multiple && (this._value.length === 0 || (this._value.length === 1 && this._value[0] === \"\")))\n }\n aria-selected={\n this._value.includes(data.value)\n || (!data.value && this.multiple && (this._value.length === 0 || (this._value.length === 1 && this._value[0] === \"\")))\n ? \"true\" : \"false\"\n }\n id={`${this.id}-option-${index}`}\n a11yTabindex=\"-1\"\n onClick={() => this.handleChipClick(data, index)}\n ></stzh-chip>\n ))}\n </div>\n\n <StzhInputDescription\n classPrefix=\"stzh-chipselect\"\n id={`${this.id}-description`}\n error={this._error}\n description={this.description}\n descriptionLong={this.descriptionLong}\n descriptionLongTitle={this.descriptionLongTitle}\n descriptionLongUsed={descriptionLongUsed}\n moreInfoButtonLabel={this.localization.$globals.moreInfoButtonLabel}\n />\n\n {/* <stzh-dropdown\n class=\"stzh-chipselect__dropdown\"\n multiple={this.multiple}\n disabled={this.disabled}\n error={this._error}\n description={this.description}\n descriptionLong={this.descriptionLong}\n required={this.required}\n invalid={this.invalid}\n items={[this.value]}\n label={this.label}\n labelHidden={this.labelHidden}\n options={this._dataDropdown}\n hideOptional={this.hideOptional}\n onStzhChange={this.handleDropdownChange}\n ></stzh-dropdown> */}\n </Fragment>\n }\n </div>\n </Host>\n );\n }\n}\n"]}
@@ -2,7 +2,7 @@
2
2
  * Colors
3
3
  */
4
4
  /* Signal colors */
5
- /* Old colors (TODO: cleanup if not needed) */
5
+ /* Old colors (TODO: cleanup when not needed anymore) */
6
6
  /**
7
7
  * Base
8
8
  */
@@ -27,6 +27,9 @@
27
27
  /**
28
28
  * Header
29
29
  */
30
+ /**
31
+ * Fieldset
32
+ */
30
33
  /**
31
34
  * Progressbar
32
35
  */
@@ -2,7 +2,7 @@
2
2
  * Colors
3
3
  */
4
4
  /* Signal colors */
5
- /* Old colors (TODO: cleanup if not needed) */
5
+ /* Old colors (TODO: cleanup when not needed anymore) */
6
6
  /**
7
7
  * Base
8
8
  */
@@ -27,6 +27,9 @@
27
27
  /**
28
28
  * Header
29
29
  */
30
+ /**
31
+ * Fieldset
32
+ */
30
33
  /**
31
34
  * Progressbar
32
35
  */
@@ -276,22 +279,24 @@
276
279
  display: flex;
277
280
  align-items: center;
278
281
  }
279
- .stzh-contact__heading, .stzh-contact__availability-title {
280
- font-family: var(--stzh-font-family-heavy);
281
- font-weight: var(--stzh-font-weight-heavy);
282
- font-style: var(--stzh-font-style-heavy);
282
+ .stzh-contact__heading, .stzh-contact__name, .stzh-contact__availability-title {
283
283
  font-size: var(--stzh-font-curve-p1-default-font-size, var(--stzh-font-milli-font-size));
284
284
  line-height: var(--stzh-font-curve-p1-default-text-line-height, var(--stzh-font-milli-text-line-height));
285
285
  letter-spacing: var(--stzh-font-curve-p1-default-text-letter-spacing);
286
286
  margin: 0px;
287
287
  }
288
288
  @media screen and (min-width: 900px) {
289
- .stzh-contact__heading, .stzh-contact__availability-title {
289
+ .stzh-contact__heading, .stzh-contact__name, .stzh-contact__availability-title {
290
290
  font-size: var(--stzh-font-curve-p1-medium-font-size, var(--stzh-font-centi-font-size));
291
291
  line-height: var(--stzh-font-curve-p1-medium-text-line-height, var(--stzh-font-centi-text-line-height));
292
292
  letter-spacing: var(--stzh-font-curve-p1-medium-text-letter-spacing);
293
293
  }
294
294
  }
295
+ .stzh-contact__heading, .stzh-contact__name.is-heading, .stzh-contact__availability-title {
296
+ font-family: var(--stzh-font-family-heavy);
297
+ font-weight: var(--stzh-font-weight-heavy);
298
+ font-style: var(--stzh-font-style-heavy);
299
+ }
295
300
  .stzh-contact__availability {
296
301
  grid-area: availability;
297
302
  margin-top: var(--stzh-space-xlarge);
@@ -21,6 +21,7 @@ export class StzhContact {
21
21
  this.heading = undefined;
22
22
  this.headingLevel = "3";
23
23
  this.name = undefined;
24
+ this.nameHeadingLevel = "";
24
25
  this.address = undefined;
25
26
  this.street = undefined;
26
27
  this.streetInfo = undefined;
@@ -86,13 +87,17 @@ export class StzhContact {
86
87
  "stzh-contact--has-links": hasLinks
87
88
  };
88
89
  const HeadingLevel = `h${this.headingLevel}`;
90
+ const NameHeadingLevel = this.nameHeadingLevel ? `h${this.nameHeadingLevel}` : 'div';
89
91
  const AvailabilityTitleElement = `h${this.availabilityTitleLevel}`;
90
92
  return (h(Host, null, h("div", { class: classes, itemscope: true, itemtype: `http://schema.org/${this.type}` }, h("div", { class: "stzh-contact__main-heading", itemprop: (this.type === "Organization" && !this.heading
91
93
  || this.type === "Person" && !this.name) ? "name" : null }, this.mainHeading
92
94
  ? h("stzh-heading", { level: this.mainHeadingLevel }, this.mainHeading)
93
95
  : h("slot", { name: "main-heading" })), h("div", { class: "stzh-contact__image-wrapper" }, h("div", { class: "stzh-contact__image" }, h("slot", { name: "image" }))), h("div", { class: "stzh-contact__info" }, this.heading &&
94
96
  h(HeadingLevel, { class: "stzh-contact__heading", itemprop: this.type === "Organization" || !this.name ? "name" : null, innerHTML: this.heading }), this.name &&
95
- h("div", { class: "stzh-contact__name", itemprop: this.type === "Person" ? "name" : null }, this.name), h("div", { class: "stzh-contact__address", itemprop: "address", itemscope: true, itemtype: "http://schema.org/PostalAddress", innerHTML: this.address }, !this.address &&
97
+ h(NameHeadingLevel, { class: {
98
+ "stzh-contact__name": true,
99
+ "is-heading": this.nameHeadingLevel !== "",
100
+ }, itemprop: this.type === "Person" ? "name" : null }, this.name), h("div", { class: "stzh-contact__address", itemprop: "address", itemscope: true, itemtype: "http://schema.org/PostalAddress", innerHTML: this.address }, !this.address &&
96
101
  h(Fragment, null, this.street &&
97
102
  h("div", { class: "stzh-contact__street", itemprop: "streetAddress" }, this.street, this.streetInfo &&
98
103
  h(Fragment, null, h("br", null), " ", this.streetInfo)), this.postalCode &&
@@ -237,6 +242,24 @@ export class StzhContact {
237
242
  "attribute": "name",
238
243
  "reflect": false
239
244
  },
245
+ "nameHeadingLevel": {
246
+ "type": "string",
247
+ "mutable": false,
248
+ "complexType": {
249
+ "original": "\"\" | \"1\" | \"2\" | \"3\" | \"4\"",
250
+ "resolved": "\"\" | \"1\" | \"2\" | \"3\" | \"4\"",
251
+ "references": {}
252
+ },
253
+ "required": false,
254
+ "optional": false,
255
+ "docs": {
256
+ "tags": [],
257
+ "text": "Name heading level"
258
+ },
259
+ "attribute": "name-heading-level",
260
+ "reflect": false,
261
+ "defaultValue": "\"\""
262
+ },
240
263
  "address": {
241
264
  "type": "string",
242
265
  "mutable": false,
@@ -1 +1 @@
1
- {"version":3,"file":"stzh-contact.js","sourceRoot":"","sources":["../../../../src/components/stzh-contact/stzh-contact.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,IAAI,EACJ,CAAC,EACD,OAAO,EACP,IAAI,EACJ,QAAQ,EACR,KAAK,EACN,MAAM,eAAe,CAAC;AAQvB,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAE5C,SAAS,SAAS,CAAC,GAAW;EAC5B,OAAO,GAAG,CAAC,OAAO,CAAC,KAAK,EAAC,EAAE,CAAC,CAAC;AAC/B,CAAC;AAED;;;;;;GAMG;AAMH,MAAM,OAAO,WAAW;;IAyCd,aAAQ,GAAoB,EAAE,CAAC;IAS/B,YAAO,GAAmB,EAAE,CAAC;IAyB7B,kBAAa,GAAkC,EAAE,CAAC;gBAzEhB,cAAc;;4BAMN,GAAG;;wBAMP,GAAG;;;;;;;mBA0BL,EAAE;kBASJ,EAAE;;;;;;;kCAsBY,GAAG;;;EAK3D,gEAAgE;EAGhE,mBAAmB,CAAC,QAAgD;IAClE,IAAI,OAAO,QAAQ,KAAK,QAAQ,EAAE;MAChC,IAAI,CAAC,aAAa,GAAG,IAAI,CAAC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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import {\n Component,\n Host,\n h,\n Element,\n Prop,\n Fragment,\n Watch\n} from \"@stencil/core\";\n\nimport {\n ContactNumber,\n ContactEmail,\n StzhContactAvailabilityItem\n} from \"../../index\";\n\nimport { hasSlot } from \"../../utils/utils\";\n\nfunction formatTel(tel: string) {\n return tel.replace(/\\s/g,'');\n}\n\n/**\n * @slot main-heading - slot for main heading\n * @slot image - slot for image\n * @slot address - slot for address (alternative for `address` property or separate properties `street`, `streetInfo`, `postalCode` & `location`)\n * @slot pobox - slot for pobox (alternative for `pobox` property or separate properties `poboxHeading`, `poboxTitle`, `poboxPostalCode` & `poboxLocation`)\n * @slot slot for additional (e.g. accordion with contact form, map or datalist)\n */\n@Component({\n tag: \"stzh-contact\",\n styleUrl: \"stzh-contact.scss\",\n scoped: true\n})\nexport class StzhContact {\n /** Type */\n @Prop() type: \"Organization\" | \"Person\" = \"Organization\";\n\n /** Main heading */\n @Prop() mainHeading: string;\n\n /** Main heading level */\n @Prop() mainHeadingLevel: \"1\" | \"2\" | \"3\" | \"4\" = \"2\";\n\n /** Heading */\n @Prop() heading: string;\n\n /** Heading level */\n @Prop() headingLevel: \"1\" | \"2\" | \"3\" | \"4\" = \"3\";\n\n /** Name */\n @Prop() name: string;\n\n /** Address (alternative for address slot or separate properties `street`, `streetInfo`, `postalCode` & `location`) */\n @Prop() address: string;\n\n /** Street */\n @Prop() street: string;\n\n /** Additional street info */\n @Prop() streetInfo: string;\n\n /** Postal code */\n @Prop() postalCode: string;\n\n /** Location / city */\n @Prop() location: string;\n\n /**\n * Numbers\n * Array of objects that can include the attributes `type` = `tel`|`fax`, `label`, `number`\n * and optionally `analyticsId` for setting `s-object-id` to the link element\n * (for Adobe Analytics, default value is `label` and `number`).\n */\n @Prop() numbers: ContactNumber[] | string = [];\n private _numbers: ContactNumber[] = [];\n\n /**\n * Numbers\n * Array of objects that can include the attributes `label`, `number`, `text`, `href`\n * and optionally `analyticsId` for setting `s-object-id` to the link element\n * (for Adobe Analytics, default value is `label` and `text`).\n */\n @Prop() emails: ContactEmail[] | string = [];\n private _emails: ContactEmail[] = [];\n\n /** Pobox (alternative for pobox slot or separate properties `poboxHeading`, `poboxTitle`, `poboxPostalCode` & `poboxLocation`) */\n @Prop() pobox: string;\n\n /** Post office box heading */\n @Prop() poboxHeading: string;\n\n /** Post office box title */\n @Prop() poboxTitle: string;\n\n /** Post office box postal code */\n @Prop() poboxPostalCode: string;\n\n /** Post office box location / city */\n @Prop() poboxLocation: string;\n\n /** Availability title */\n @Prop() availabilityTitle: string;\n\n /** Availability title level */\n @Prop() availabilityTitleLevel: \"1\" | \"2\" | \"3\" | \"4\" = \"3\";\n\n /** Availability times */\n @Prop() availability: string | StzhContactAvailabilityItem[];\n private _availability: StzhContactAvailabilityItem[] = [];\n // private _availabilityDataItems: StzhDatalistItemEntry[] = [];\n\n @Watch(\"availability\")\n availabilityWatcher(newValue: string | StzhContactAvailabilityItem[]) {\n if (typeof newValue === \"string\") {\n this._availability = JSON.parse(newValue);\n } else {\n this._availability = newValue;\n }\n\n // if (this._availability) {\n // this._availabilityDataItems = this._availability.map((item) => ({\n // value: item.hours.join(' | '),\n // label: item.weekday\n // }));\n // }\n }\n\n @Watch(\"numbers\")\n numbersWatcher(newValue: ContactNumber[] | string) {\n if (typeof newValue === \"string\") {\n this._numbers = JSON.parse(newValue);\n } else {\n this._numbers = newValue;\n }\n }\n\n @Watch(\"emails\")\n emailsWatcher(newValue: ContactEmail[] | string) {\n if (typeof newValue === \"string\") {\n this._emails = JSON.parse(newValue);\n } else {\n this._emails = newValue;\n }\n }\n\n @Element() element: HTMLStzhFigureElement;\n\n async componentWillLoad() {\n this.numbersWatcher(this.numbers);\n this.emailsWatcher(this.emails);\n this.availabilityWatcher(this.availability);\n }\n\n render() {\n const hasImage = hasSlot(this.element, \"image\");\n const hasAddress = !!this.address || hasSlot(this.element, \"address\");\n const hasAddons = hasSlot(this.element, \"addons\");\n const hasLinks = hasSlot(this.element, \"links\");\n\n const classes = {\n \"stzh-contact\": true,\n \"stzh-contact--has-image\": hasImage,\n \"stzh-contact--has-address\": hasAddress,\n \"stzh-contact--has-addons\": hasAddons,\n \"stzh-contact--has-links\": hasLinks\n };\n\n const HeadingLevel = `h${this.headingLevel}`;\n const AvailabilityTitleElement = `h${this.availabilityTitleLevel}`;\n\n return (\n <Host>\n <div class={classes} itemscope itemtype={`http://schema.org/${this.type}`}>\n <div\n class=\"stzh-contact__main-heading\"\n itemprop={(this.type === \"Organization\" && !this.heading\n || this.type === \"Person\" && !this.name) ? \"name\" : null}\n >\n {this.mainHeading\n ? <stzh-heading level={this.mainHeadingLevel}>{this.mainHeading}</stzh-heading>\n : <slot name=\"main-heading\"></slot>\n }\n </div>\n\n <div class=\"stzh-contact__image-wrapper\">\n <div class=\"stzh-contact__image\">\n <slot name=\"image\"></slot>\n </div>\n </div>\n\n <div class=\"stzh-contact__info\">\n {this.heading &&\n <HeadingLevel\n class=\"stzh-contact__heading\"\n itemprop={this.type === \"Organization\" || !this.name ? \"name\" : null}\n innerHTML={this.heading}\n ></HeadingLevel>\n }\n\n {this.name &&\n <div\n class=\"stzh-contact__name\"\n itemprop={this.type === \"Person\" ? \"name\" : null}\n >\n {this.name}\n </div>\n }\n\n <div\n class=\"stzh-contact__address\"\n itemprop=\"address\"\n itemscope\n itemtype=\"http://schema.org/PostalAddress\"\n innerHTML={this.address}\n >\n {!this.address &&\n <Fragment>\n {this.street &&\n <div class=\"stzh-contact__street\" itemprop=\"streetAddress\">\n {this.street}\n {this.streetInfo &&\n <Fragment>\n <br /> {this.streetInfo}\n </Fragment>\n }\n </div>\n }\n\n {this.postalCode &&\n <span class=\"stzh-contact__postal-code\" itemprop=\"postalCode\">\n {this.postalCode}&nbsp;\n </span>\n }\n\n {this.location &&\n <span class=\"stzh-contact__locality\" itemprop=\"addressLocality\">\n {this.location}\n </span>\n }\n\n <slot name=\"address\"></slot>\n </Fragment>\n }\n </div>\n\n {this._numbers.length > 0 &&\n <div class=\"stzh-contact__numbers\">\n {this._numbers.map((number) =>\n <div class=\"stzh-contact__number\">\n <span>{number.label}&nbsp;</span>\n <stzh-link\n size=\"inherit\"\n height=\"auto\"\n class=\"stzh-contact__number-link\"\n href={`${number.type}:${formatTel(number.number)}`}\n analyticsId={number.analyticsId || (`${number.label} ${number.number}`)}\n itemprop={number.type === \"fax\" ? \"faxNumber\" : \"telephone\"}\n >\n {number.number}\n </stzh-link>\n </div>\n )}\n </div>\n }\n\n {this._emails.length > 0 &&\n <div class=\"stzh-contact__emails\">\n {this._emails.map((email) =>\n <div class=\"stzh-contact__email\">\n <span>{email.label}&nbsp;</span>\n {email.href\n ?\n <stzh-link\n size=\"inherit\"\n height=\"auto\"\n class=\"stzh-container__email-link\"\n href={`mailto:${email.href}`}\n analyticsId={email.analyticsId || (`${email.label} ${email.text}`)}\n itemprop=\"email\"\n >\n {email.text}\n </stzh-link>\n :\n <span\n class=\"stzh-container__email-link\"\n itemprop=\"email\"\n >\n {email.text}\n </span>\n }\n </div>\n )}\n </div>\n }\n\n <div\n class=\"stzh-contact__pobox\"\n innerHTML={this.pobox}\n >\n {!this.pobox &&\n <Fragment>\n {this.poboxHeading &&\n <div class=\"stzh-contact__pobox-heading\">{this.poboxHeading}</div>\n }\n {this.poboxTitle &&\n <div class=\"stzh-contact__pobox-title\">{this.poboxTitle}</div>\n }\n {this.poboxPostalCode &&\n <span class=\"stzh-contact__pobox-postal-code\">{this.poboxPostalCode}&nbsp;</span>\n }\n {this.poboxLocation &&\n <span class=\"stzh-contact__pobox-locality\">{this.poboxLocation}</span>\n }\n <slot name=\"pobox\"></slot>\n </Fragment>\n }\n </div>\n </div>\n\n {this.availability &&\n <div class=\"stzh-contact__availability\">\n {this.availabilityTitle &&\n <AvailabilityTitleElement\n class=\"stzh-contact__availability-title\"\n >\n {this.availabilityTitle}\n </AvailabilityTitleElement>\n }\n\n {this._availability.length > 0 &&\n <ul class=\"stzh-contact__availability-list\">\n {this._availability.map((item) =>\n <li class=\"stzh-contact__availability-list-item\">\n <div class=\"stzh-contact__availability-weekday\">{item.weekday}</div>\n {item.hours.length > 0\n ?\n <div class=\"stzh-contact__availability-hours\">\n {item.hours.map((hour, index) =>\n <Fragment>\n <div class=\"stzh-contact__availability-hour\">{hour}</div>\n {index < item.hours.length - 1 &&\n <div class=\"stzh-contact__availability-hours-separator\"></div>\n }\n </Fragment>\n )}\n </div>\n :\n <div class=\"stzh-contact__availability-hours\">\n -\n </div>\n }\n </li>\n )}\n </ul>\n }\n </div>\n }\n\n <div class=\"stzh-contact__additional\">\n <slot></slot>\n </div>\n </div>\n </Host>\n );\n }\n}\n"]}
1
+ {"version":3,"file":"stzh-contact.js","sourceRoot":"","sources":["../../../../src/components/stzh-contact/stzh-contact.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,IAAI,EACJ,CAAC,EACD,OAAO,EACP,IAAI,EACJ,QAAQ,EACR,KAAK,EACN,MAAM,eAAe,CAAC;AAQvB,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAE5C,SAAS,SAAS,CAAC,GAAW;EAC5B,OAAO,GAAG,CAAC,OAAO,CAAC,KAAK,EAAC,EAAE,CAAC,CAAC;AAC/B,CAAC;AAED;;;;;;GAMG;AAMH,MAAM,OAAO,WAAW;;IA4Cd,aAAQ,GAAoB,EAAE,CAAC;IAS/B,YAAO,GAAmB,EAAE,CAAC;IAyB7B,kBAAa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,EAAE,CAC9B,EAAC,QAAQ;sBACP,WAAK,KAAK,EAAC,iCAAiC,IAAE,IAAI,CAAO;sBACxD,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC;wBAC5B,WAAK,KAAK,EAAC,4CAA4C,GAAO,CAEvD,CACZ,CACG;kBACN,CAAC;oBACD,WAAK,KAAK,EAAC,kCAAkC,QAEvC,CAEL,CACN,CACE,CAEH;QAGR,WAAK,KAAK,EAAC,0BAA0B;UACnC,eAAa,CACT,CACF,CACD,CACR,CAAC;EACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import {\n Component,\n Host,\n h,\n Element,\n Prop,\n Fragment,\n Watch\n} from \"@stencil/core\";\n\nimport {\n ContactNumber,\n ContactEmail,\n StzhContactAvailabilityItem\n} from \"../../index\";\n\nimport { hasSlot } from \"../../utils/utils\";\n\nfunction formatTel(tel: string) {\n return tel.replace(/\\s/g,'');\n}\n\n/**\n * @slot main-heading - slot for main heading\n * @slot image - slot for image\n * @slot address - slot for address (alternative for `address` property or separate properties `street`, `streetInfo`, `postalCode` & `location`)\n * @slot pobox - slot for pobox (alternative for `pobox` property or separate properties `poboxHeading`, `poboxTitle`, `poboxPostalCode` & `poboxLocation`)\n * @slot slot for additional (e.g. accordion with contact form, map or datalist)\n */\n@Component({\n tag: \"stzh-contact\",\n styleUrl: \"stzh-contact.scss\",\n scoped: true\n})\nexport class StzhContact {\n /** Type */\n @Prop() type: \"Organization\" | \"Person\" = \"Organization\";\n\n /** Main heading */\n @Prop() mainHeading: string;\n\n /** Main heading level */\n @Prop() mainHeadingLevel: \"1\" | \"2\" | \"3\" | \"4\" = \"2\";\n\n /** Heading */\n @Prop() heading: string;\n\n /** Heading level */\n @Prop() headingLevel: \"1\" | \"2\" | \"3\" | \"4\" = \"3\";\n\n /** Name */\n @Prop() name: string;\n\n /** Name heading level */\n @Prop() nameHeadingLevel: \"\" | \"1\" | \"2\" | \"3\" | \"4\" = \"\";\n\n /** Address (alternative for address slot or separate properties `street`, `streetInfo`, `postalCode` & `location`) */\n @Prop() address: string;\n\n /** Street */\n @Prop() street: string;\n\n /** Additional street info */\n @Prop() streetInfo: string;\n\n /** Postal code */\n @Prop() postalCode: string;\n\n /** Location / city */\n @Prop() location: string;\n\n /**\n * Numbers\n * Array of objects that can include the attributes `type` = `tel`|`fax`, `label`, `number`\n * and optionally `analyticsId` for setting `s-object-id` to the link element\n * (for Adobe Analytics, default value is `label` and `number`).\n */\n @Prop() numbers: ContactNumber[] | string = [];\n private _numbers: ContactNumber[] = [];\n\n /**\n * Numbers\n * Array of objects that can include the attributes `label`, `number`, `text`, `href`\n * and optionally `analyticsId` for setting `s-object-id` to the link element\n * (for Adobe Analytics, default value is `label` and `text`).\n */\n @Prop() emails: ContactEmail[] | string = [];\n private _emails: ContactEmail[] = [];\n\n /** Pobox (alternative for pobox slot or separate properties `poboxHeading`, `poboxTitle`, `poboxPostalCode` & `poboxLocation`) */\n @Prop() pobox: string;\n\n /** Post office box heading */\n @Prop() poboxHeading: string;\n\n /** Post office box title */\n @Prop() poboxTitle: string;\n\n /** Post office box postal code */\n @Prop() poboxPostalCode: string;\n\n /** Post office box location / city */\n @Prop() poboxLocation: string;\n\n /** Availability title */\n @Prop() availabilityTitle: string;\n\n /** Availability title level */\n @Prop() availabilityTitleLevel: \"1\" | \"2\" | \"3\" | \"4\" = \"3\";\n\n /** Availability times */\n @Prop() availability: string | StzhContactAvailabilityItem[];\n private _availability: StzhContactAvailabilityItem[] = [];\n // private _availabilityDataItems: StzhDatalistItemEntry[] = [];\n\n @Watch(\"availability\")\n availabilityWatcher(newValue: string | StzhContactAvailabilityItem[]) {\n if (typeof newValue === \"string\") {\n this._availability = JSON.parse(newValue);\n } else {\n this._availability = newValue;\n }\n\n // if (this._availability) {\n // this._availabilityDataItems = this._availability.map((item) => ({\n // value: item.hours.join(' | '),\n // label: item.weekday\n // }));\n // }\n }\n\n @Watch(\"numbers\")\n numbersWatcher(newValue: ContactNumber[] | string) {\n if (typeof newValue === \"string\") {\n this._numbers = JSON.parse(newValue);\n } else {\n this._numbers = newValue;\n }\n }\n\n @Watch(\"emails\")\n emailsWatcher(newValue: ContactEmail[] | string) {\n if (typeof newValue === \"string\") {\n this._emails = JSON.parse(newValue);\n } else {\n this._emails = newValue;\n }\n }\n\n @Element() element: HTMLStzhFigureElement;\n\n async componentWillLoad() {\n this.numbersWatcher(this.numbers);\n this.emailsWatcher(this.emails);\n this.availabilityWatcher(this.availability);\n }\n\n render() {\n const hasImage = hasSlot(this.element, \"image\");\n const hasAddress = !!this.address || hasSlot(this.element, \"address\");\n const hasAddons = hasSlot(this.element, \"addons\");\n const hasLinks = hasSlot(this.element, \"links\");\n\n const classes = {\n \"stzh-contact\": true,\n \"stzh-contact--has-image\": hasImage,\n \"stzh-contact--has-address\": hasAddress,\n \"stzh-contact--has-addons\": hasAddons,\n \"stzh-contact--has-links\": hasLinks\n };\n\n const HeadingLevel = `h${this.headingLevel}`;\n const NameHeadingLevel = this.nameHeadingLevel ? `h${this.nameHeadingLevel}` : 'div';\n const AvailabilityTitleElement = `h${this.availabilityTitleLevel}`;\n\n return (\n <Host>\n <div class={classes} itemscope itemtype={`http://schema.org/${this.type}`}>\n <div\n class=\"stzh-contact__main-heading\"\n itemprop={(this.type === \"Organization\" && !this.heading\n || this.type === \"Person\" && !this.name) ? \"name\" : null}\n >\n {this.mainHeading\n ? <stzh-heading level={this.mainHeadingLevel}>{this.mainHeading}</stzh-heading>\n : <slot name=\"main-heading\"></slot>\n }\n </div>\n\n <div class=\"stzh-contact__image-wrapper\">\n <div class=\"stzh-contact__image\">\n <slot name=\"image\"></slot>\n </div>\n </div>\n\n <div class=\"stzh-contact__info\">\n {this.heading &&\n <HeadingLevel\n class=\"stzh-contact__heading\"\n itemprop={this.type === \"Organization\" || !this.name ? \"name\" : null}\n innerHTML={this.heading}\n ></HeadingLevel>\n }\n\n {this.name &&\n <NameHeadingLevel\n class={{\n \"stzh-contact__name\": true,\n \"is-heading\": this.nameHeadingLevel !== \"\",\n }}\n itemprop={this.type === \"Person\" ? \"name\" : null}\n >\n {this.name}\n </NameHeadingLevel>\n }\n\n <div\n class=\"stzh-contact__address\"\n itemprop=\"address\"\n itemscope\n itemtype=\"http://schema.org/PostalAddress\"\n innerHTML={this.address}\n >\n {!this.address &&\n <Fragment>\n {this.street &&\n <div class=\"stzh-contact__street\" itemprop=\"streetAddress\">\n {this.street}\n {this.streetInfo &&\n <Fragment>\n <br /> {this.streetInfo}\n </Fragment>\n }\n </div>\n }\n\n {this.postalCode &&\n <span class=\"stzh-contact__postal-code\" itemprop=\"postalCode\">\n {this.postalCode}&nbsp;\n </span>\n }\n\n {this.location &&\n <span class=\"stzh-contact__locality\" itemprop=\"addressLocality\">\n {this.location}\n </span>\n }\n\n <slot name=\"address\"></slot>\n </Fragment>\n }\n </div>\n\n {this._numbers.length > 0 &&\n <div class=\"stzh-contact__numbers\">\n {this._numbers.map((number) =>\n <div class=\"stzh-contact__number\">\n <span>{number.label}&nbsp;</span>\n <stzh-link\n size=\"inherit\"\n height=\"auto\"\n class=\"stzh-contact__number-link\"\n href={`${number.type}:${formatTel(number.number)}`}\n analyticsId={number.analyticsId || (`${number.label} ${number.number}`)}\n itemprop={number.type === \"fax\" ? \"faxNumber\" : \"telephone\"}\n >\n {number.number}\n </stzh-link>\n </div>\n )}\n </div>\n }\n\n {this._emails.length > 0 &&\n <div class=\"stzh-contact__emails\">\n {this._emails.map((email) =>\n <div class=\"stzh-contact__email\">\n <span>{email.label}&nbsp;</span>\n {email.href\n ?\n <stzh-link\n size=\"inherit\"\n height=\"auto\"\n class=\"stzh-container__email-link\"\n href={`mailto:${email.href}`}\n analyticsId={email.analyticsId || (`${email.label} ${email.text}`)}\n itemprop=\"email\"\n >\n {email.text}\n </stzh-link>\n :\n <span\n class=\"stzh-container__email-link\"\n itemprop=\"email\"\n >\n {email.text}\n </span>\n }\n </div>\n )}\n </div>\n }\n\n <div\n class=\"stzh-contact__pobox\"\n innerHTML={this.pobox}\n >\n {!this.pobox &&\n <Fragment>\n {this.poboxHeading &&\n <div class=\"stzh-contact__pobox-heading\">{this.poboxHeading}</div>\n }\n {this.poboxTitle &&\n <div class=\"stzh-contact__pobox-title\">{this.poboxTitle}</div>\n }\n {this.poboxPostalCode &&\n <span class=\"stzh-contact__pobox-postal-code\">{this.poboxPostalCode}&nbsp;</span>\n }\n {this.poboxLocation &&\n <span class=\"stzh-contact__pobox-locality\">{this.poboxLocation}</span>\n }\n <slot name=\"pobox\"></slot>\n </Fragment>\n }\n </div>\n </div>\n\n {this.availability &&\n <div class=\"stzh-contact__availability\">\n {this.availabilityTitle &&\n <AvailabilityTitleElement\n class=\"stzh-contact__availability-title\"\n >\n {this.availabilityTitle}\n </AvailabilityTitleElement>\n }\n\n {this._availability.length > 0 &&\n <ul class=\"stzh-contact__availability-list\">\n {this._availability.map((item) =>\n <li class=\"stzh-contact__availability-list-item\">\n <div class=\"stzh-contact__availability-weekday\">{item.weekday}</div>\n {item.hours.length > 0\n ?\n <div class=\"stzh-contact__availability-hours\">\n {item.hours.map((hour, index) =>\n <Fragment>\n <div class=\"stzh-contact__availability-hour\">{hour}</div>\n {index < item.hours.length - 1 &&\n <div class=\"stzh-contact__availability-hours-separator\"></div>\n }\n </Fragment>\n )}\n </div>\n :\n <div class=\"stzh-contact__availability-hours\">\n -\n </div>\n }\n </li>\n )}\n </ul>\n }\n </div>\n }\n\n <div class=\"stzh-contact__additional\">\n <slot></slot>\n </div>\n </div>\n </Host>\n );\n }\n}\n"]}
@@ -2,7 +2,7 @@
2
2
  * Colors
3
3
  */
4
4
  /* Signal colors */
5
- /* Old colors (TODO: cleanup if not needed) */
5
+ /* Old colors (TODO: cleanup when not needed anymore) */
6
6
  /**
7
7
  * Base
8
8
  */
@@ -27,6 +27,9 @@
27
27
  /**
28
28
  * Header
29
29
  */
30
+ /**
31
+ * Fieldset
32
+ */
30
33
  /**
31
34
  * Progressbar
32
35
  */
@@ -2,7 +2,7 @@
2
2
  * Colors
3
3
  */
4
4
  /* Signal colors */
5
- /* Old colors (TODO: cleanup if not needed) */
5
+ /* Old colors (TODO: cleanup when not needed anymore) */
6
6
  /**
7
7
  * Base
8
8
  */
@@ -27,6 +27,9 @@
27
27
  /**
28
28
  * Header
29
29
  */
30
+ /**
31
+ * Fieldset
32
+ */
30
33
  /**
31
34
  * Progressbar
32
35
  */
@@ -2,7 +2,7 @@
2
2
  * Colors
3
3
  */
4
4
  /* Signal colors */
5
- /* Old colors (TODO: cleanup if not needed) */
5
+ /* Old colors (TODO: cleanup when not needed anymore) */
6
6
  /**
7
7
  * Base
8
8
  */
@@ -27,6 +27,9 @@
27
27
  /**
28
28
  * Header
29
29
  */
30
+ /**
31
+ * Fieldset
32
+ */
30
33
  /**
31
34
  * Progressbar
32
35
  */
@@ -507,19 +510,22 @@ stzh-cspace > .stzh-cspace > .section > :where(stzh-text[curve="p2"]), stzh-cspa
507
510
  margin-bottom: var(--stzh-space-large);
508
511
  }
509
512
  }
510
- stzh-cspace > .stzh-cspace > .section > stzh-input, stzh-cspace > .stzh-cspace > stzh-input, stzh-cspace > .stzh-cspace > .section > stzh-datepicker, stzh-cspace > .stzh-cspace > stzh-datepicker, stzh-cspace > .stzh-cspace > .section > stzh-dropdown, stzh-cspace > .stzh-cspace > stzh-dropdown, stzh-cspace > .stzh-cspace > .section > stzh-upload, stzh-cspace > .stzh-cspace > stzh-upload, stzh-cspace > .stzh-cspace > .section > stzh-checkbox, stzh-cspace > .stzh-cspace > stzh-checkbox, stzh-cspace > .stzh-cspace > .section > stzh-checkboxgroup, stzh-cspace > .stzh-cspace > stzh-checkboxgroup, stzh-cspace > .stzh-cspace > .section > stzh-radio, stzh-cspace > .stzh-cspace > stzh-radio, stzh-cspace > .stzh-cspace > .section > stzh-radiogroup, stzh-cspace > .stzh-cspace > stzh-radiogroup {
513
+ stzh-cspace > .stzh-cspace > .section > stzh-input, stzh-cspace > .stzh-cspace > stzh-input, stzh-cspace > .stzh-cspace > .section > stzh-datepicker, stzh-cspace > .stzh-cspace > stzh-datepicker, stzh-cspace > .stzh-cspace > .section > stzh-daterange, stzh-cspace > .stzh-cspace > stzh-daterange, stzh-cspace > .stzh-cspace > .section > stzh-dropdown, stzh-cspace > .stzh-cspace > stzh-dropdown, stzh-cspace > .stzh-cspace > .section > stzh-upload, stzh-cspace > .stzh-cspace > stzh-upload, stzh-cspace > .stzh-cspace > .section > stzh-checkbox, stzh-cspace > .stzh-cspace > stzh-checkbox, stzh-cspace > .stzh-cspace > .section > stzh-checkboxgroup, stzh-cspace > .stzh-cspace > stzh-checkboxgroup, stzh-cspace > .stzh-cspace > .section > stzh-radio, stzh-cspace > .stzh-cspace > stzh-radio, stzh-cspace > .stzh-cspace > .section > stzh-radiogroup, stzh-cspace > .stzh-cspace > stzh-radiogroup {
511
514
  margin-bottom: var(--stzh-space-xsmall);
512
515
  }
513
516
  @media screen and (min-width: 900px) {
514
- stzh-cspace > .stzh-cspace > .section > stzh-input, stzh-cspace > .stzh-cspace > stzh-input, stzh-cspace > .stzh-cspace > .section > stzh-datepicker, stzh-cspace > .stzh-cspace > stzh-datepicker, stzh-cspace > .stzh-cspace > .section > stzh-dropdown, stzh-cspace > .stzh-cspace > stzh-dropdown, stzh-cspace > .stzh-cspace > .section > stzh-upload, stzh-cspace > .stzh-cspace > stzh-upload, stzh-cspace > .stzh-cspace > .section > stzh-checkbox, stzh-cspace > .stzh-cspace > stzh-checkbox, stzh-cspace > .stzh-cspace > .section > stzh-checkboxgroup, stzh-cspace > .stzh-cspace > stzh-checkboxgroup, stzh-cspace > .stzh-cspace > .section > stzh-radio, stzh-cspace > .stzh-cspace > stzh-radio, stzh-cspace > .stzh-cspace > .section > stzh-radiogroup, stzh-cspace > .stzh-cspace > stzh-radiogroup {
517
+ stzh-cspace > .stzh-cspace > .section > stzh-input, stzh-cspace > .stzh-cspace > stzh-input, stzh-cspace > .stzh-cspace > .section > stzh-datepicker, stzh-cspace > .stzh-cspace > stzh-datepicker, stzh-cspace > .stzh-cspace > .section > stzh-daterange, stzh-cspace > .stzh-cspace > stzh-daterange, stzh-cspace > .stzh-cspace > .section > stzh-dropdown, stzh-cspace > .stzh-cspace > stzh-dropdown, stzh-cspace > .stzh-cspace > .section > stzh-upload, stzh-cspace > .stzh-cspace > stzh-upload, stzh-cspace > .stzh-cspace > .section > stzh-checkbox, stzh-cspace > .stzh-cspace > stzh-checkbox, stzh-cspace > .stzh-cspace > .section > stzh-checkboxgroup, stzh-cspace > .stzh-cspace > stzh-checkboxgroup, stzh-cspace > .stzh-cspace > .section > stzh-radio, stzh-cspace > .stzh-cspace > stzh-radio, stzh-cspace > .stzh-cspace > .section > stzh-radiogroup, stzh-cspace > .stzh-cspace > stzh-radiogroup {
515
518
  margin-bottom: var(--stzh-space-small);
516
519
  }
517
520
  }
518
521
  @media screen and (min-width: 1260px) {
519
- stzh-cspace > .stzh-cspace > .section > stzh-input, stzh-cspace > .stzh-cspace > stzh-input, stzh-cspace > .stzh-cspace > .section > stzh-datepicker, stzh-cspace > .stzh-cspace > stzh-datepicker, stzh-cspace > .stzh-cspace > .section > stzh-dropdown, stzh-cspace > .stzh-cspace > stzh-dropdown, stzh-cspace > .stzh-cspace > .section > stzh-upload, stzh-cspace > .stzh-cspace > stzh-upload, stzh-cspace > .stzh-cspace > .section > stzh-checkbox, stzh-cspace > .stzh-cspace > stzh-checkbox, stzh-cspace > .stzh-cspace > .section > stzh-checkboxgroup, stzh-cspace > .stzh-cspace > stzh-checkboxgroup, stzh-cspace > .stzh-cspace > .section > stzh-radio, stzh-cspace > .stzh-cspace > stzh-radio, stzh-cspace > .stzh-cspace > .section > stzh-radiogroup, stzh-cspace > .stzh-cspace > stzh-radiogroup {
522
+ stzh-cspace > .stzh-cspace > .section > stzh-input, stzh-cspace > .stzh-cspace > stzh-input, stzh-cspace > .stzh-cspace > .section > stzh-datepicker, stzh-cspace > .stzh-cspace > stzh-datepicker, stzh-cspace > .stzh-cspace > .section > stzh-daterange, stzh-cspace > .stzh-cspace > stzh-daterange, stzh-cspace > .stzh-cspace > .section > stzh-dropdown, stzh-cspace > .stzh-cspace > stzh-dropdown, stzh-cspace > .stzh-cspace > .section > stzh-upload, stzh-cspace > .stzh-cspace > stzh-upload, stzh-cspace > .stzh-cspace > .section > stzh-checkbox, stzh-cspace > .stzh-cspace > stzh-checkbox, stzh-cspace > .stzh-cspace > .section > stzh-checkboxgroup, stzh-cspace > .stzh-cspace > stzh-checkboxgroup, stzh-cspace > .stzh-cspace > .section > stzh-radio, stzh-cspace > .stzh-cspace > stzh-radio, stzh-cspace > .stzh-cspace > .section > stzh-radiogroup, stzh-cspace > .stzh-cspace > stzh-radiogroup {
520
523
  margin-bottom: var(--stzh-space-medium);
521
524
  }
522
525
  }
526
+ stzh-cspace > .stzh-cspace > .section > stzh-chipgroup, stzh-cspace > .stzh-cspace > stzh-chipgroup, stzh-cspace > .stzh-cspace > .section > stzh-chipselect, stzh-cspace > .stzh-cspace > stzh-chipselect {
527
+ margin-bottom: var(--stzh-space-xlarge);
528
+ }
523
529
  stzh-cspace > .stzh-cspace > .section > stzh-message, stzh-cspace > .stzh-cspace > stzh-message {
524
530
  margin-bottom: var(--stzh-space-xxlarge);
525
531
  }
@@ -533,16 +539,16 @@ stzh-cspace > .stzh-cspace > .section > stzh-message, stzh-cspace > .stzh-cspace
533
539
  margin-bottom: var(--stzh-space-xxxxlarge);
534
540
  }
535
541
  }
536
- stzh-cspace > .stzh-cspace > .section > stzh-chipgroup, stzh-cspace > .stzh-cspace > stzh-chipgroup, stzh-cspace > .stzh-cspace > .section > stzh-contact, stzh-cspace > .stzh-cspace > stzh-contact, stzh-cspace > .stzh-cspace > .section > stzh-accordion, stzh-cspace > .stzh-cspace > stzh-accordion, stzh-cspace > .stzh-cspace > .section > stzh-anchornav, stzh-cspace > .stzh-cspace > stzh-anchornav, stzh-cspace > .stzh-cspace > .section > stzh-audio, stzh-cspace > .stzh-cspace > stzh-audio, stzh-cspace > .stzh-cspace > .section > stzh-microsite-teaserlist, stzh-cspace > .stzh-cspace > stzh-microsite-teaserlist, stzh-cspace > .stzh-cspace > .section > stzh-gallery, stzh-cspace > .stzh-cspace > stzh-gallery, stzh-cspace > .stzh-cspace > .section > stzh-panorama, stzh-cspace > .stzh-cspace > stzh-panorama, stzh-cspace > .stzh-cspace > .section > stzh-chart, stzh-cspace > .stzh-cspace > stzh-chart, stzh-cspace > .stzh-cspace > .section > stzh-sitemap, stzh-cspace > .stzh-cspace > stzh-sitemap, stzh-cspace > .stzh-cspace > .section > stzh-hr, stzh-cspace > .stzh-cspace > stzh-hr, stzh-cspace > .stzh-cspace > .section > stzh-archivelist, stzh-cspace > .stzh-cspace > stzh-archivelist, stzh-cspace > .stzh-cspace > .section > stzh-figure, stzh-cspace > .stzh-cspace > stzh-figure, stzh-cspace > .stzh-cspace > stzh-iframe, stzh-cspace > .stzh-cspace > .section > stzh-youtube, stzh-cspace > .stzh-cspace > stzh-youtube, stzh-cspace > .stzh-cspace > .section > stzh-eventinfo, stzh-cspace > .stzh-cspace > stzh-eventinfo, stzh-cspace > .stzh-cspace > .section > stzh-vbz-ticker, stzh-cspace > .stzh-cspace > stzh-vbz-ticker {
542
+ stzh-cspace > .stzh-cspace > .section > stzh-contact, stzh-cspace > .stzh-cspace > stzh-contact, stzh-cspace > .stzh-cspace > .section > stzh-accordion, stzh-cspace > .stzh-cspace > stzh-accordion, stzh-cspace > .stzh-cspace > .section > stzh-anchornav, stzh-cspace > .stzh-cspace > stzh-anchornav, stzh-cspace > .stzh-cspace > .section > stzh-audio, stzh-cspace > .stzh-cspace > stzh-audio, stzh-cspace > .stzh-cspace > .section > stzh-microsite-teaserlist, stzh-cspace > .stzh-cspace > stzh-microsite-teaserlist, stzh-cspace > .stzh-cspace > .section > stzh-gallery, stzh-cspace > .stzh-cspace > stzh-gallery, stzh-cspace > .stzh-cspace > .section > stzh-panorama, stzh-cspace > .stzh-cspace > stzh-panorama, stzh-cspace > .stzh-cspace > .section > stzh-chart, stzh-cspace > .stzh-cspace > stzh-chart, stzh-cspace > .stzh-cspace > .section > stzh-sitemap, stzh-cspace > .stzh-cspace > stzh-sitemap, stzh-cspace > .stzh-cspace > .section > stzh-hr, stzh-cspace > .stzh-cspace > stzh-hr, stzh-cspace > .stzh-cspace > .section > stzh-archivelist, stzh-cspace > .stzh-cspace > stzh-archivelist, stzh-cspace > .stzh-cspace > .section > stzh-figure, stzh-cspace > .stzh-cspace > stzh-figure, stzh-cspace > .stzh-cspace > stzh-iframe, stzh-cspace > .stzh-cspace > .section > stzh-youtube, stzh-cspace > .stzh-cspace > stzh-youtube, stzh-cspace > .stzh-cspace > .section > stzh-eventinfo, stzh-cspace > .stzh-cspace > stzh-eventinfo, stzh-cspace > .stzh-cspace > .section > stzh-vbz-ticker, stzh-cspace > .stzh-cspace > stzh-vbz-ticker {
537
543
  margin-bottom: var(--stzh-space-xxlarge);
538
544
  }
539
545
  @media screen and (min-width: 900px) {
540
- stzh-cspace > .stzh-cspace > .section > stzh-chipgroup, stzh-cspace > .stzh-cspace > stzh-chipgroup, stzh-cspace > .stzh-cspace > .section > stzh-contact, stzh-cspace > .stzh-cspace > stzh-contact, stzh-cspace > .stzh-cspace > .section > stzh-accordion, stzh-cspace > .stzh-cspace > stzh-accordion, stzh-cspace > .stzh-cspace > .section > stzh-anchornav, stzh-cspace > .stzh-cspace > stzh-anchornav, stzh-cspace > .stzh-cspace > .section > stzh-audio, stzh-cspace > .stzh-cspace > stzh-audio, stzh-cspace > .stzh-cspace > .section > stzh-microsite-teaserlist, stzh-cspace > .stzh-cspace > stzh-microsite-teaserlist, stzh-cspace > .stzh-cspace > .section > stzh-gallery, stzh-cspace > .stzh-cspace > stzh-gallery, stzh-cspace > .stzh-cspace > .section > stzh-panorama, stzh-cspace > .stzh-cspace > stzh-panorama, stzh-cspace > .stzh-cspace > .section > stzh-chart, stzh-cspace > .stzh-cspace > stzh-chart, stzh-cspace > .stzh-cspace > .section > stzh-sitemap, stzh-cspace > .stzh-cspace > stzh-sitemap, stzh-cspace > .stzh-cspace > .section > stzh-hr, stzh-cspace > .stzh-cspace > stzh-hr, stzh-cspace > .stzh-cspace > .section > stzh-archivelist, stzh-cspace > .stzh-cspace > stzh-archivelist, stzh-cspace > .stzh-cspace > .section > stzh-figure, stzh-cspace > .stzh-cspace > stzh-figure, stzh-cspace > .stzh-cspace > stzh-iframe, stzh-cspace > .stzh-cspace > .section > stzh-youtube, stzh-cspace > .stzh-cspace > stzh-youtube, stzh-cspace > .stzh-cspace > .section > stzh-eventinfo, stzh-cspace > .stzh-cspace > stzh-eventinfo, stzh-cspace > .stzh-cspace > .section > stzh-vbz-ticker, stzh-cspace > .stzh-cspace > stzh-vbz-ticker {
546
+ stzh-cspace > .stzh-cspace > .section > stzh-contact, stzh-cspace > .stzh-cspace > stzh-contact, stzh-cspace > .stzh-cspace > .section > stzh-accordion, stzh-cspace > .stzh-cspace > stzh-accordion, stzh-cspace > .stzh-cspace > .section > stzh-anchornav, stzh-cspace > .stzh-cspace > stzh-anchornav, stzh-cspace > .stzh-cspace > .section > stzh-audio, stzh-cspace > .stzh-cspace > stzh-audio, stzh-cspace > .stzh-cspace > .section > stzh-microsite-teaserlist, stzh-cspace > .stzh-cspace > stzh-microsite-teaserlist, stzh-cspace > .stzh-cspace > .section > stzh-gallery, stzh-cspace > .stzh-cspace > stzh-gallery, stzh-cspace > .stzh-cspace > .section > stzh-panorama, stzh-cspace > .stzh-cspace > stzh-panorama, stzh-cspace > .stzh-cspace > .section > stzh-chart, stzh-cspace > .stzh-cspace > stzh-chart, stzh-cspace > .stzh-cspace > .section > stzh-sitemap, stzh-cspace > .stzh-cspace > stzh-sitemap, stzh-cspace > .stzh-cspace > .section > stzh-hr, stzh-cspace > .stzh-cspace > stzh-hr, stzh-cspace > .stzh-cspace > .section > stzh-archivelist, stzh-cspace > .stzh-cspace > stzh-archivelist, stzh-cspace > .stzh-cspace > .section > stzh-figure, stzh-cspace > .stzh-cspace > stzh-figure, stzh-cspace > .stzh-cspace > stzh-iframe, stzh-cspace > .stzh-cspace > .section > stzh-youtube, stzh-cspace > .stzh-cspace > stzh-youtube, stzh-cspace > .stzh-cspace > .section > stzh-eventinfo, stzh-cspace > .stzh-cspace > stzh-eventinfo, stzh-cspace > .stzh-cspace > .section > stzh-vbz-ticker, stzh-cspace > .stzh-cspace > stzh-vbz-ticker {
541
547
  margin-bottom: var(--stzh-space-xxxlarge);
542
548
  }
543
549
  }
544
550
  @media screen and (min-width: 1260px) {
545
- stzh-cspace > .stzh-cspace > .section > stzh-chipgroup, stzh-cspace > .stzh-cspace > stzh-chipgroup, stzh-cspace > .stzh-cspace > .section > stzh-contact, stzh-cspace > .stzh-cspace > stzh-contact, stzh-cspace > .stzh-cspace > .section > stzh-accordion, stzh-cspace > .stzh-cspace > stzh-accordion, stzh-cspace > .stzh-cspace > .section > stzh-anchornav, stzh-cspace > .stzh-cspace > stzh-anchornav, stzh-cspace > .stzh-cspace > .section > stzh-audio, stzh-cspace > .stzh-cspace > stzh-audio, stzh-cspace > .stzh-cspace > .section > stzh-microsite-teaserlist, stzh-cspace > .stzh-cspace > stzh-microsite-teaserlist, stzh-cspace > .stzh-cspace > .section > stzh-gallery, stzh-cspace > .stzh-cspace > stzh-gallery, stzh-cspace > .stzh-cspace > .section > stzh-panorama, stzh-cspace > .stzh-cspace > stzh-panorama, stzh-cspace > .stzh-cspace > .section > stzh-chart, stzh-cspace > .stzh-cspace > stzh-chart, stzh-cspace > .stzh-cspace > .section > stzh-sitemap, stzh-cspace > .stzh-cspace > stzh-sitemap, stzh-cspace > .stzh-cspace > .section > stzh-hr, stzh-cspace > .stzh-cspace > stzh-hr, stzh-cspace > .stzh-cspace > .section > stzh-archivelist, stzh-cspace > .stzh-cspace > stzh-archivelist, stzh-cspace > .stzh-cspace > .section > stzh-figure, stzh-cspace > .stzh-cspace > stzh-figure, stzh-cspace > .stzh-cspace > stzh-iframe, stzh-cspace > .stzh-cspace > .section > stzh-youtube, stzh-cspace > .stzh-cspace > stzh-youtube, stzh-cspace > .stzh-cspace > .section > stzh-eventinfo, stzh-cspace > .stzh-cspace > stzh-eventinfo, stzh-cspace > .stzh-cspace > .section > stzh-vbz-ticker, stzh-cspace > .stzh-cspace > stzh-vbz-ticker {
551
+ stzh-cspace > .stzh-cspace > .section > stzh-contact, stzh-cspace > .stzh-cspace > stzh-contact, stzh-cspace > .stzh-cspace > .section > stzh-accordion, stzh-cspace > .stzh-cspace > stzh-accordion, stzh-cspace > .stzh-cspace > .section > stzh-anchornav, stzh-cspace > .stzh-cspace > stzh-anchornav, stzh-cspace > .stzh-cspace > .section > stzh-audio, stzh-cspace > .stzh-cspace > stzh-audio, stzh-cspace > .stzh-cspace > .section > stzh-microsite-teaserlist, stzh-cspace > .stzh-cspace > stzh-microsite-teaserlist, stzh-cspace > .stzh-cspace > .section > stzh-gallery, stzh-cspace > .stzh-cspace > stzh-gallery, stzh-cspace > .stzh-cspace > .section > stzh-panorama, stzh-cspace > .stzh-cspace > stzh-panorama, stzh-cspace > .stzh-cspace > .section > stzh-chart, stzh-cspace > .stzh-cspace > stzh-chart, stzh-cspace > .stzh-cspace > .section > stzh-sitemap, stzh-cspace > .stzh-cspace > stzh-sitemap, stzh-cspace > .stzh-cspace > .section > stzh-hr, stzh-cspace > .stzh-cspace > stzh-hr, stzh-cspace > .stzh-cspace > .section > stzh-archivelist, stzh-cspace > .stzh-cspace > stzh-archivelist, stzh-cspace > .stzh-cspace > .section > stzh-figure, stzh-cspace > .stzh-cspace > stzh-figure, stzh-cspace > .stzh-cspace > stzh-iframe, stzh-cspace > .stzh-cspace > .section > stzh-youtube, stzh-cspace > .stzh-cspace > stzh-youtube, stzh-cspace > .stzh-cspace > .section > stzh-eventinfo, stzh-cspace > .stzh-cspace > stzh-eventinfo, stzh-cspace > .stzh-cspace > .section > stzh-vbz-ticker, stzh-cspace > .stzh-cspace > stzh-vbz-ticker {
546
552
  margin-bottom: var(--stzh-space-xxxxlarge);
547
553
  }
548
554
  }
@@ -2,7 +2,7 @@
2
2
  * Colors
3
3
  */
4
4
  /* Signal colors */
5
- /* Old colors (TODO: cleanup if not needed) */
5
+ /* Old colors (TODO: cleanup when not needed anymore) */
6
6
  /**
7
7
  * Base
8
8
  */
@@ -27,6 +27,9 @@
27
27
  /**
28
28
  * Header
29
29
  */
30
+ /**
31
+ * Fieldset
32
+ */
30
33
  /**
31
34
  * Progressbar
32
35
  */
@@ -159,8 +162,8 @@
159
162
  :host {
160
163
  --stzh-flyingfocus-color: var(--stzh-color-white);
161
164
  --background-color: var(--stzh-cta-background-color);
162
- --heading-color: var(--stzh-color-primary70);
163
- --lead-color: var(--stzh-color-primary70);
165
+ --heading-color: var(--stzh-color-white);
166
+ --lead-color: var(--stzh-color-white);
164
167
  --sticky-background-color: var(--background-color);
165
168
  --button-color: var(--stzh-color-white);
166
169
  --button-background-color: var(--stzh-color-primary70);
@@ -40,6 +40,13 @@ export class StzhCta {
40
40
  originalEvent: event
41
41
  });
42
42
  };
43
+ this.onClick = (event) => {
44
+ this.stzhClick.emit({
45
+ component: "stzh-cta",
46
+ originalEvent: event,
47
+ href: this.href
48
+ });
49
+ };
43
50
  this.handlePlaceholderButtonResize = () => {
44
51
  if (this.debounceResize) {
45
52
  window.cancelAnimationFrame(this.debounceResize);
@@ -94,7 +101,7 @@ export class StzhCta {
94
101
  return (h("div", { class: "stzh-cta__buttons" }, size === "small" &&
95
102
  h("div", { class: "stzh-cta__button is-placeholder", ref: (el) => (this.placeholderButton = el) }, h("span", { class: "stzh-cta__button-text" }, this.label), h("stzh-icon", { class: "stzh-cta__button-icon", name: "arrow-right" })), this.href
96
103
  ?
97
- h("a", { class: "stzh-cta__button", href: this.href, ref: (el) => (this.button = el), onFocus: this.onFocus, onBlur: this.onBlur }, h("span", { class: "stzh-cta__button-text" }, this.label), h("stzh-icon", { class: "stzh-cta__button-icon", name: "arrow-right" }))
104
+ h("a", { class: "stzh-cta__button", href: this.href, ref: (el) => (this.button = el), onFocus: this.onFocus, onBlur: this.onBlur, onClick: this.onClick }, h("span", { class: "stzh-cta__button-text" }, this.label), h("stzh-icon", { class: "stzh-cta__button-icon", name: "arrow-right" }))
98
105
  :
99
106
  h("button", { class: "stzh-cta__button", ref: (el) => (this.button = el), onFocus: this.onFocus, onBlur: this.onBlur }, h("span", { class: "stzh-cta__button-text" }, this.label), h("stzh-icon", { class: "stzh-cta__button-icon", name: "arrow-right" }))));
100
107
  }
@@ -237,7 +244,7 @@ export class StzhCta {
237
244
  "composed": true,
238
245
  "docs": {
239
246
  "tags": [],
240
- "text": "Input focus event"
247
+ "text": "Focus event"
241
248
  },
242
249
  "complexType": {
243
250
  "original": "StzhCtaFocusEvent",
@@ -258,7 +265,7 @@ export class StzhCta {
258
265
  "composed": true,
259
266
  "docs": {
260
267
  "tags": [],
261
- "text": "Input blur event"
268
+ "text": "Blur event"
262
269
  },
263
270
  "complexType": {
264
271
  "original": "StzhCtaBlurEvent",
@@ -271,6 +278,27 @@ export class StzhCta {
271
278
  }
272
279
  }
273
280
  }
281
+ }, {
282
+ "method": "stzhClick",
283
+ "name": "stzhClick",
284
+ "bubbles": true,
285
+ "cancelable": true,
286
+ "composed": true,
287
+ "docs": {
288
+ "tags": [],
289
+ "text": "Click event"
290
+ },
291
+ "complexType": {
292
+ "original": "StzhCtaClickEvent",
293
+ "resolved": "{ component: \"stzh-cta\"; originalEvent: MouseEvent; href: string; }",
294
+ "references": {
295
+ "StzhCtaClickEvent": {
296
+ "location": "import",
297
+ "path": "../../index",
298
+ "id": "src/index.ts::StzhCtaClickEvent"
299
+ }
300
+ }
301
+ }
274
302
  }];
275
303
  }
276
304
  static get elementRef() { return "element"; }
@@ -1 +1 @@
1
- {"version":3,"file":"stzh-cta.js","sourceRoot":"","sources":["../../../../src/components/stzh-cta/stzh-cta.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,IAAI,EACJ,CAAC,EACD,OAAO,EACP,IAAI,EACJ,KAAK,EACL,KAAK,GAEN,MAAM,eAAe,CAAC;AAOvB,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAE5C,IAAI,OAAO,GAAG,CAAC,CAAC;AAEhB;;;;GAIG;AAMH,MAAM,OAAO,OAAO;;IAiCV,mBAAc,GAAY,KAAK,CAAC;IAGhC,gBAAW,GAAG,GAAG,EAAE;MACzB,IAAI,CAAC,IAAI,CAAC,cAAc,EAAE;QACxB,IAAI,CAAC,MAAM,CAAC,KAAK,EAAE,CAAC;OACrB;MAED,IAAI,CAAC,cAAc,GAAG,KAAK,CAAC;IAC9B,CAAC,CAAA;IAEO,YAAO,GAAG,CAAC,KAAiB,EAAE,EAAE;MACtC,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC;MAE3B,MAAM,UAAU,GAAG,IAAI,UAAU,CAAC,OAAO,EAAE;QACzC,IAAI,EAAE,MAAM;QACZ,OAAO,EAAE,KAAK;QACd,UAAU,EAAE,KAAK;OAClB,CAAC,CAAC;MAEH,IAAI,CAAC,OAAO,CAAC,aAAa,CAAC,UAAU,CAAC,CAAC;MACvC,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC;QAClB,SAAS,EAAE,UAAU;QACrB,aAAa,EAAE,KAAK;OACrB,CAAC,C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nC,oBAAoB,EAAE,OAAO;MAC7B,CAAC,kBAAkB,IAAI,EAAE,CAAC,EAAE,CAAC,CAAC,IAAI;KACnC,CAAC;IAEF,OAAO,CACL,EAAC,IAAI,IAAC,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAC,IAAI,EAAC,OAAO,EAAE,IAAI,CAAC,WAAW;MACvD,eAAS,KAAK,EAAE,OAAO;QACrB,WAAK,KAAK,EAAC,mBAAmB;UAC5B,WAAK,KAAK,EAAC,mBAAmB,IAC3B,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,YAAM,IAAI,EAAC,SAAS,GAAQ,CACvD;UACN,WAAK,KAAK,EAAC,gBAAgB,IACxB,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,YAAM,IAAI,EAAC,MAAM,GAAQ,CAC9C;UACN,mBACE,IAAI,EAAC,KAAK,EACV,KAAK,EAAC,kBAAkB,EACxB,QAAQ,EAAC,OAAO,EAChB,QAAQ,QACR,mBAAmB,EAAE,IAAI,CAAC,cAAc,EACxC,gBAAgB,EAAE,IAAI,IAErB,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,CACb,CACV,CACE,CACL,CACR,CAAC;EACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import {\n Component,\n Host,\n h,\n Element,\n Prop,\n State,\n Event,\n EventEmitter,\n} from \"@stencil/core\";\n\nimport {\n StzhCtaFocusEvent,\n StzhCtaBlurEvent\n} from \"../../index\";\n\nimport { hasSlot } from \"../../utils/utils\";\n\nvar counter = 0;\n\n/**\n * @slot heading - Slot for heading as alternative for attribute\n * @slot lead - Slot for lead as alternative for attribute\n * @slot label - Slot for button label as alternative for attribute\n */\n@Component({\n tag: \"stzh-cta\",\n styleUrl: \"stzh-cta.scss\",\n scoped: true\n})\nexport class StzhCta {\n /** Heading */\n @Prop() heading: string = \"\";\n\n /** Lead */\n @Prop() lead: string = \"\";\n\n /** Button Label */\n @Prop() label: string = \"\";\n\n /** Button link */\n @Prop() href: string = \"\";\n\n /**\n * Whether sticky button is disabled.\n * Will be set to true automatically on,\n * when more than one cta is on the page.\n */\n @Prop() stickyDisabled: boolean = true;\n\n @State() loaded: boolean = false;\n\n @Element() element: HTMLStzhCtaElement;\n\n /** Input focus event */\n @Event() stzhFocus: EventEmitter<StzhCtaFocusEvent>;\n\n /** Input blur event */\n @Event() stzhBlur: EventEmitter<StzhCtaBlurEvent>;\n\n private button: HTMLButtonElement | HTMLAnchorElement;\n private placeholderButton: HTMLElement;\n private debounceResize: number;\n private focusedByInput: boolean = false;\n private placeholderButtonResizeObserver: ResizeObserver;\n\n private onRootFocus = () => {\n if (!this.focusedByInput) {\n this.button.focus();\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-cta\",\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-cta\",\n originalEvent: event\n });\n }\n\n private handlePlaceholderButtonResize = () => {\n if (this.debounceResize) {\n window.cancelAnimationFrame(this.debounceResize);\n }\n\n this.debounceResize = requestAnimationFrame(this.updateButtonWidthByResize);\n }\n\n private updateButtonWidthByResize = () => {\n if (!this.placeholderButton) {\n return;\n }\n\n const { width } = this.placeholderButton.getBoundingClientRect();\n this.element.style.setProperty(\"--button-width\", `${width}px`);\n }\n\n componentDidLoad() {\n this.stickyDisabled = counter > 1;\n\n this.placeholderButtonResizeObserver = new ResizeObserver(this.handlePlaceholderButtonResize);\n if (this.placeholderButton) {\n this.placeholderButtonResizeObserver.observe(this.placeholderButton);\n }\n\n requestAnimationFrame(() => {\n requestAnimationFrame(() => {\n this.updateButtonWidthByResize();\n\n window.setTimeout(() => {\n this.loaded = true;\n }, 250);\n });\n });\n }\n\n componentDidRender() {\n if (this.placeholderButton && this.placeholderButtonResizeObserver) {\n this.placeholderButtonResizeObserver.observe(this.placeholderButton);\n }\n }\n\n connectedCallback() {\n counter = counter + 1;\n }\n\n disconnectedCallback() {\n // current no way of sending events in disconnected callback, so we just decrease the counter now,\n // but the user has to set stickyDisabled=false by himself\n counter = counter - 1;\n\n this.placeholderButtonResizeObserver?.disconnect();\n }\n\n private renderButtons(size: \"default\" | \"small\") {\n return (\n <div class=\"stzh-cta__buttons\">\n {size === \"small\" &&\n <div\n class=\"stzh-cta__button is-placeholder\"\n ref={(el) => (this.placeholderButton = el as HTMLElement)}\n >\n <span class=\"stzh-cta__button-text\">{this.label}</span>\n <stzh-icon class=\"stzh-cta__button-icon\" name=\"arrow-right\"></stzh-icon>\n </div>\n }\n\n {this.href\n ?\n <a\n class=\"stzh-cta__button\"\n href={this.href}\n ref={(el) => (this.button = el as HTMLAnchorElement)}\n onFocus={this.onFocus}\n onBlur={this.onBlur}\n >\n <span class=\"stzh-cta__button-text\">{this.label}</span>\n <stzh-icon class=\"stzh-cta__button-icon\" name=\"arrow-right\"></stzh-icon>\n </a>\n :\n <button\n class=\"stzh-cta__button\"\n ref={(el) => (this.button = el as HTMLButtonElement)}\n onFocus={this.onFocus}\n onBlur={this.onBlur}\n >\n <span class=\"stzh-cta__button-text\">{this.label}</span>\n <stzh-icon class=\"stzh-cta__button-icon\" name=\"arrow-right\"></stzh-icon>\n </button>\n }\n </div>\n );\n }\n\n render() {\n const headingSlotUsed = hasSlot(this.element, 'heading');\n const leadSlotUsed = hasSlot(this.element, 'lead');\n\n const hasHeading = !!this.heading || headingSlotUsed;\n const hasLead = !!this.lead || leadSlotUsed;\n const hasHeadingOrLead = hasHeading || hasLead;\n\n const size = !hasHeadingOrLead\n ? \"small\"\n : \"default\";\n\n const classes = {\n \"stzh-cta\": true,\n \"stzh-cta--is-sticky-disabled\": this.stickyDisabled,\n \"stzh-cta--is-not-loaded\": !this.loaded,\n \"stzh-cta--has-heading\": hasHeading,\n \"stzh-cta--has-lead\": hasLead,\n [`stzh-cta--size-${size}`]: !!size,\n };\n\n return (\n <Host size={size} tabindex=\"-1\" onFocus={this.onRootFocus}>\n <article class={classes} data-stzh-sticky-width-container>\n <div class=\"stzh-cta__wrapper\">\n <div class=\"stzh-cta__heading\">\n {this.heading ? this.heading : <slot name=\"heading\"></slot>}\n </div>\n <div class=\"stzh-cta__lead\">\n {this.lead ? this.lead : <slot name=\"lead\"></slot>}\n </div>\n <stzh-sticky\n name=\"cta\"\n class=\"stzh-cta__sticky\"\n position=\"fixed\"\n bleeding\n disableStickyBottom={this.stickyDisabled}\n disableStickyTop={true}\n >\n {this.renderButtons(size)}\n </stzh-sticky>\n </div>\n </article>\n </Host>\n );\n }\n}\n"]}
1
+ {"version":3,"file":"stzh-cta.js","sourceRoot":"","sources":["../../../../src/components/stzh-cta/stzh-cta.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,IAAI,EACJ,CAAC,EACD,OAAO,EACP,IAAI,EACJ,KAAK,EACL,KAAK,GAEN,MAAM,eAAe,CAAC;AAOvB,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAE5C,IAAI,OAAO,GAAG,CAAC,CAAC;AAEhB;;;;GAIG;AAMH,MAAM,OAAO,OAAO;;IAoCV,mBAAc,GAAY,KAAK,CAAC;IAGhC,gBAAW,GAAG,GAAG,EAAE;MACzB,IAAI,CAAC,IAAI,CAAC,cAAc,EAAE;QACxB,IAAI,CAAC,MAAM,C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C,IAAI,CAAC,CAAC,CAAC,YAAM,IAAI,EAAC,MAAM,GAAQ,CAC9C;UACN,mBACE,IAAI,EAAC,KAAK,EACV,KAAK,EAAC,kBAAkB,EACxB,QAAQ,EAAC,OAAO,EAChB,QAAQ,QACR,mBAAmB,EAAE,IAAI,CAAC,cAAc,EACxC,gBAAgB,EAAE,IAAI,IAErB,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,CACb,CACV,CACE,CACL,CACR,CAAC;EACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import {\n Component,\n Host,\n h,\n Element,\n Prop,\n State,\n Event,\n EventEmitter,\n} from \"@stencil/core\";\n\nimport {\n StzhCtaFocusEvent,\n StzhCtaBlurEvent, StzhCtaClickEvent\n} from \"../../index\";\n\nimport { hasSlot } from \"../../utils/utils\";\n\nvar counter = 0;\n\n/**\n * @slot heading - Slot for heading as alternative for attribute\n * @slot lead - Slot for lead as alternative for attribute\n * @slot label - Slot for button label as alternative for attribute\n */\n@Component({\n tag: \"stzh-cta\",\n styleUrl: \"stzh-cta.scss\",\n scoped: true\n})\nexport class StzhCta {\n /** Heading */\n @Prop() heading: string = \"\";\n\n /** Lead */\n @Prop() lead: string = \"\";\n\n /** Button Label */\n @Prop() label: string = \"\";\n\n /** Button link */\n @Prop() href: string = \"\";\n\n /**\n * Whether sticky button is disabled.\n * Will be set to true automatically on,\n * when more than one cta is on the page.\n */\n @Prop() stickyDisabled: boolean = true;\n\n @State() loaded: boolean = false;\n\n @Element() element: HTMLStzhCtaElement;\n\n /** Focus event */\n @Event() stzhFocus: EventEmitter<StzhCtaFocusEvent>;\n\n /** Blur event */\n @Event() stzhBlur: EventEmitter<StzhCtaBlurEvent>;\n\n /** Click event */\n @Event() stzhClick: EventEmitter<StzhCtaClickEvent>;\n\n private button: HTMLButtonElement | HTMLAnchorElement;\n private placeholderButton: HTMLElement;\n private debounceResize: number;\n private focusedByInput: boolean = false;\n private placeholderButtonResizeObserver: ResizeObserver;\n\n private onRootFocus = () => {\n if (!this.focusedByInput) {\n this.button.focus();\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-cta\",\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-cta\",\n originalEvent: event\n });\n }\n\n private onClick = (event: MouseEvent) => {\n this.stzhClick.emit({\n component: \"stzh-cta\",\n originalEvent: event,\n href: this.href\n });\n }\n\n private handlePlaceholderButtonResize = () => {\n if (this.debounceResize) {\n window.cancelAnimationFrame(this.debounceResize);\n }\n\n this.debounceResize = requestAnimationFrame(this.updateButtonWidthByResize);\n }\n\n private updateButtonWidthByResize = () => {\n if (!this.placeholderButton) {\n return;\n }\n\n const { width } = this.placeholderButton.getBoundingClientRect();\n this.element.style.setProperty(\"--button-width\", `${width}px`);\n }\n\n componentDidLoad() {\n this.stickyDisabled = counter > 1;\n\n this.placeholderButtonResizeObserver = new ResizeObserver(this.handlePlaceholderButtonResize);\n if (this.placeholderButton) {\n this.placeholderButtonResizeObserver.observe(this.placeholderButton);\n }\n\n requestAnimationFrame(() => {\n requestAnimationFrame(() => {\n this.updateButtonWidthByResize();\n\n window.setTimeout(() => {\n this.loaded = true;\n }, 250);\n });\n });\n }\n\n componentDidRender() {\n if (this.placeholderButton && this.placeholderButtonResizeObserver) {\n this.placeholderButtonResizeObserver.observe(this.placeholderButton);\n }\n }\n\n connectedCallback() {\n counter = counter + 1;\n }\n\n disconnectedCallback() {\n // current no way of sending events in disconnected callback, so we just decrease the counter now,\n // but the user has to set stickyDisabled=false by himself\n counter = counter - 1;\n\n this.placeholderButtonResizeObserver?.disconnect();\n }\n\n private renderButtons(size: \"default\" | \"small\") {\n return (\n <div class=\"stzh-cta__buttons\">\n {size === \"small\" &&\n <div\n class=\"stzh-cta__button is-placeholder\"\n ref={(el) => (this.placeholderButton = el as HTMLElement)}\n >\n <span class=\"stzh-cta__button-text\">{this.label}</span>\n <stzh-icon class=\"stzh-cta__button-icon\" name=\"arrow-right\"></stzh-icon>\n </div>\n }\n\n {this.href\n ?\n <a\n class=\"stzh-cta__button\"\n href={this.href}\n ref={(el) => (this.button = el as HTMLAnchorElement)}\n onFocus={this.onFocus}\n onBlur={this.onBlur}\n onClick={this.onClick}\n >\n <span class=\"stzh-cta__button-text\">{this.label}</span>\n <stzh-icon class=\"stzh-cta__button-icon\" name=\"arrow-right\"></stzh-icon>\n </a>\n :\n <button\n class=\"stzh-cta__button\"\n ref={(el) => (this.button = el as HTMLButtonElement)}\n onFocus={this.onFocus}\n onBlur={this.onBlur}\n >\n <span class=\"stzh-cta__button-text\">{this.label}</span>\n <stzh-icon class=\"stzh-cta__button-icon\" name=\"arrow-right\"></stzh-icon>\n </button>\n }\n </div>\n );\n }\n\n render() {\n const headingSlotUsed = hasSlot(this.element, 'heading');\n const leadSlotUsed = hasSlot(this.element, 'lead');\n\n const hasHeading = !!this.heading || headingSlotUsed;\n const hasLead = !!this.lead || leadSlotUsed;\n const hasHeadingOrLead = hasHeading || hasLead;\n\n const size = !hasHeadingOrLead\n ? \"small\"\n : \"default\";\n\n const classes = {\n \"stzh-cta\": true,\n \"stzh-cta--is-sticky-disabled\": this.stickyDisabled,\n \"stzh-cta--is-not-loaded\": !this.loaded,\n \"stzh-cta--has-heading\": hasHeading,\n \"stzh-cta--has-lead\": hasLead,\n [`stzh-cta--size-${size}`]: !!size,\n };\n\n return (\n <Host size={size} tabindex=\"-1\" onFocus={this.onRootFocus}>\n <article class={classes} data-stzh-sticky-width-container>\n <div class=\"stzh-cta__wrapper\">\n <div class=\"stzh-cta__heading\">\n {this.heading ? this.heading : <slot name=\"heading\"></slot>}\n </div>\n <div class=\"stzh-cta__lead\">\n {this.lead ? this.lead : <slot name=\"lead\"></slot>}\n </div>\n <stzh-sticky\n name=\"cta\"\n class=\"stzh-cta__sticky\"\n position=\"fixed\"\n bleeding\n disableStickyBottom={this.stickyDisabled}\n disableStickyTop={true}\n >\n {this.renderButtons(size)}\n </stzh-sticky>\n </div>\n </article>\n </Host>\n );\n }\n}\n"]}