@city-of-helsinki/react-helsinki-headless-cms 3.0.0-rc.1 → 3.0.0-rc.2

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 (473) hide show
  1. package/dist/LICENSE +21 -0
  2. package/dist/README.md +442 -0
  3. package/dist/__generated__-mcycL1jB.d.ts +7192 -0
  4. package/dist/apollo.d.ts +168 -0
  5. package/dist/apollo.js +194 -0
  6. package/dist/apollo.js.map +1 -0
  7. package/dist/archiveSearchPageContent.module-DmpLBZP5.js +4078 -0
  8. package/dist/archiveSearchPageContent.module-DmpLBZP5.js.map +1 -0
  9. package/dist/cjs/apollo.js +227 -0
  10. package/dist/cjs/apollo.js.map +1 -0
  11. package/dist/cjs/archiveSearchPageContent.module-Hcb4WVMf.js +4143 -0
  12. package/dist/cjs/archiveSearchPageContent.module-Hcb4WVMf.js.map +1 -0
  13. package/dist/cjs/defaultConfig-dV2AVA5S.js +19908 -0
  14. package/dist/cjs/defaultConfig-dV2AVA5S.js.map +1 -0
  15. package/dist/cjs/index-Eg-NhhyT.js +799 -0
  16. package/dist/cjs/index-Eg-NhhyT.js.map +1 -0
  17. package/dist/cjs/index.js +439 -0
  18. package/dist/cjs/index.js.map +1 -0
  19. package/dist/cjs/jest-setup.d.ts +1 -0
  20. package/dist/cjs/nextjs.js +74 -0
  21. package/dist/cjs/nextjs.js.map +1 -0
  22. package/dist/cjs/src/apollo/apollo-custom-template.stories.d.ts +12 -0
  23. package/dist/cjs/src/apollo/apollo.stories.d.ts +24 -0
  24. package/dist/cjs/src/apollo/index.d.ts +17 -0
  25. package/dist/cjs/src/apollo/navigation/Navigation.d.ts +13 -0
  26. package/dist/cjs/src/apollo/navigation/__tests__/Navigation.test.d.ts +1 -0
  27. package/dist/cjs/src/apollo/notification/Notification.d.ts +4 -0
  28. package/dist/cjs/src/apollo/notification/__tests__/Notification.test.d.ts +1 -0
  29. package/dist/cjs/src/apollo/page/ApolloPageContextProvider.d.ts +5 -0
  30. package/dist/cjs/src/apollo/page/Page.d.ts +14 -0
  31. package/dist/cjs/src/apollo/page/apolloPageContext.d.ts +13 -0
  32. package/dist/cjs/src/apollo/page/useApolloPageContext.d.ts +4 -0
  33. package/dist/cjs/src/apollo/pageContent/PageContent.d.ts +9 -0
  34. package/dist/cjs/src/apollo/pageWithTemplateContent/PageWithTemplateContent.d.ts +14 -0
  35. package/dist/cjs/src/common/components/container/Container.d.ts +13 -0
  36. package/dist/cjs/src/common/components/grid/Grid.d.ts +16 -0
  37. package/dist/cjs/src/common/components/grid/Grid.stories.d.ts +8 -0
  38. package/dist/cjs/src/common/components/htmlToReact/HtmlToReact.d.ts +38 -0
  39. package/dist/cjs/src/common/components/htmlToReact/HtmlToReact.stories.d.ts +13 -0
  40. package/dist/cjs/src/common/components/htmlToReact/__tests__/HtmlToReact.tests.d.ts +1 -0
  41. package/dist/cjs/src/common/components/htmlToReact/replaceComponents/DefaultH2.d.ts +4 -0
  42. package/dist/cjs/src/common/components/htmlToReact/replaceComponents/DefaultP.d.ts +4 -0
  43. package/dist/cjs/src/common/components/htmlToReact/replaceComponents/IframeForEmbeddedMedia.d.ts +6 -0
  44. package/dist/cjs/src/common/components/htmlToReact/replaceComponents/index.d.ts +3 -0
  45. package/dist/cjs/src/common/components/icons/index.d.ts +5 -0
  46. package/dist/cjs/src/common/components/list/List.d.ts +13 -0
  47. package/dist/cjs/src/common/components/list/List.stories.d.ts +13 -0
  48. package/dist/cjs/src/common/components/tag/Tag.d.ts +26 -0
  49. package/dist/cjs/src/common/components/tag/Tag.stories.d.ts +80 -0
  50. package/dist/cjs/src/common/components/tag/__tests__/Tag.test.d.ts +1 -0
  51. package/dist/cjs/src/common/components/tag/tagThemes.d.ts +3 -0
  52. package/dist/cjs/src/common/components/text/Text.d.ts +27 -0
  53. package/dist/cjs/src/common/components/text/Text.stories.d.ts +14 -0
  54. package/dist/cjs/src/common/constants.d.ts +2 -0
  55. package/dist/cjs/src/common/eventsService/__generated__.d.ts +1420 -0
  56. package/dist/cjs/src/common/eventsService/events.d.ts +12 -0
  57. package/dist/cjs/src/common/eventsService/types.d.ts +2 -0
  58. package/dist/cjs/src/common/eventsService/utils.d.ts +7 -0
  59. package/dist/cjs/src/common/headlessService/__generated__.d.ts +20878 -0
  60. package/dist/cjs/src/common/headlessService/article.d.ts +7 -0
  61. package/dist/cjs/src/common/headlessService/articles.d.ts +17 -0
  62. package/dist/cjs/src/common/headlessService/categories.d.ts +13 -0
  63. package/dist/cjs/src/common/headlessService/category.d.ts +9 -0
  64. package/dist/cjs/src/common/headlessService/constants.d.ts +7 -0
  65. package/dist/cjs/src/common/headlessService/landingPage.d.ts +9 -0
  66. package/dist/cjs/src/common/headlessService/languages.d.ts +8 -0
  67. package/dist/cjs/src/common/headlessService/makeQueryWithApolloClientFromConfig.d.ts +12 -0
  68. package/dist/cjs/src/common/headlessService/menu.d.ts +10 -0
  69. package/dist/cjs/src/common/headlessService/notification.d.ts +7 -0
  70. package/dist/cjs/src/common/headlessService/page.d.ts +8 -0
  71. package/dist/cjs/src/common/headlessService/pageByTemplate.d.ts +9 -0
  72. package/dist/cjs/src/common/headlessService/pages.d.ts +13 -0
  73. package/dist/cjs/src/common/headlessService/tag.d.ts +9 -0
  74. package/dist/cjs/src/common/headlessService/tags.d.ts +13 -0
  75. package/dist/cjs/src/common/headlessService/types.d.ts +17 -0
  76. package/dist/cjs/src/common/headlessService/utils.d.ts +909 -0
  77. package/dist/cjs/src/common/utils/customRender.d.ts +4 -0
  78. package/dist/cjs/src/common/utils/dates.d.ts +20 -0
  79. package/dist/cjs/src/common/utils/getIsValidHttpUrl.d.ts +5 -0
  80. package/dist/cjs/src/common/utils/hash.d.ts +1 -0
  81. package/dist/cjs/src/common/utils/makeLocaleStorageValue.d.ts +6 -0
  82. package/dist/cjs/src/common/utils/testImage.d.ts +9 -0
  83. package/dist/cjs/src/common/venuesService/__generated__.d.ts +254 -0
  84. package/dist/cjs/src/common/venuesService/makeQueryWithVenuesApolloClientFromConfig.d.ts +7 -0
  85. package/dist/cjs/src/common/venuesService/types.d.ts +2 -0
  86. package/dist/cjs/src/constants.d.ts +5 -0
  87. package/dist/cjs/src/core/archiveSearchPage/ArchivePageMeta.d.ts +13 -0
  88. package/dist/cjs/src/core/archiveSearchPage/ArchiveSearchPage.d.ts +16 -0
  89. package/dist/cjs/src/core/archiveSearchPage/ArchiveSearchPage.stories.d.ts +50 -0
  90. package/dist/cjs/src/core/archiveSearchPageContent/ArchiveSearchPageContent.d.ts +92 -0
  91. package/dist/cjs/src/core/button/LoadingButton.d.ts +8 -0
  92. package/dist/cjs/src/core/card/Card.d.ts +102 -0
  93. package/dist/cjs/src/core/card/Card.stories.d.ts +99 -0
  94. package/dist/cjs/src/core/card/LargeCard.d.ts +68 -0
  95. package/dist/cjs/src/core/card/LargeCard.stories.d.ts +16 -0
  96. package/dist/cjs/src/core/cardsList/CardsList.d.ts +16 -0
  97. package/dist/cjs/src/core/cardsList/CardsList.stories.d.ts +22 -0
  98. package/dist/cjs/src/core/carousel/Carousel.d.ts +3 -0
  99. package/dist/cjs/src/core/carousel/Carousel.stories.d.ts +34 -0
  100. package/dist/cjs/src/core/carousel/__tests__/Carousel.test.d.ts +1 -0
  101. package/dist/cjs/src/core/carousel/components/CarouselSlideButton.d.ts +3 -0
  102. package/dist/cjs/src/core/carousel/components/CarouselSlider.d.ts +3 -0
  103. package/dist/cjs/src/core/carousel/components/CarouselSliderDot.d.ts +2 -0
  104. package/dist/cjs/src/core/carousel/components/CarouselSliderPage.d.ts +5 -0
  105. package/dist/cjs/src/core/carousel/components/__tests__/CarouselSlideButton.test.d.ts +1 -0
  106. package/dist/cjs/src/core/carousel/components/__tests__/CarouselSlider.test.d.ts +1 -0
  107. package/dist/cjs/src/core/carousel/components/__tests__/CarouselSliderDot.test.d.ts +1 -0
  108. package/dist/cjs/src/core/carousel/components/__tests__/CarouselSliderPage.test.d.ts +1 -0
  109. package/dist/cjs/src/core/carousel/constants.d.ts +20 -0
  110. package/dist/cjs/src/core/carousel/context/CarouselContext.d.ts +4 -0
  111. package/dist/cjs/src/core/carousel/context/CarouselContextProvider.d.ts +7 -0
  112. package/dist/cjs/src/core/carousel/types.d.ts +147 -0
  113. package/dist/cjs/src/core/carousel/utils/utils.d.ts +27 -0
  114. package/dist/cjs/src/core/collection/Collection.d.ts +102 -0
  115. package/dist/cjs/src/core/collection/Collection.stories.d.ts +48 -0
  116. package/dist/cjs/src/core/collection/__tests__/Collection.test.d.ts +1 -0
  117. package/dist/cjs/src/core/collection/constants.d.ts +1 -0
  118. package/dist/cjs/src/core/collection/types.d.ts +28 -0
  119. package/dist/cjs/src/core/collection/utils.d.ts +36 -0
  120. package/dist/cjs/src/core/configProvider/ConfigProvider.d.ts +13 -0
  121. package/dist/cjs/src/core/configProvider/configContext.d.ts +130 -0
  122. package/dist/cjs/src/core/configProvider/defaultConfig.d.ts +61 -0
  123. package/dist/cjs/src/core/configProvider/useApolloClientFromConfig.d.ts +1 -0
  124. package/dist/cjs/src/core/configProvider/useConfig.d.ts +2 -0
  125. package/dist/cjs/src/core/configProvider/useEventsApolloClientFromConfig.d.ts +1 -0
  126. package/dist/cjs/src/core/configProvider/useHeadlessCmsLink.d.ts +2 -0
  127. package/dist/cjs/src/core/configProvider/useVenuesApolloClientFromConfig.d.ts +1 -0
  128. package/dist/cjs/src/core/contentContainer/ContentContainer.d.ts +12 -0
  129. package/dist/cjs/src/core/contentContainer/ContentContainer.stories.d.ts +8 -0
  130. package/dist/cjs/src/core/hero/Hero.d.ts +33 -0
  131. package/dist/cjs/src/core/hero/Hero.stories.d.ts +23 -0
  132. package/dist/cjs/src/core/hooks/useResolveImageUrl.d.ts +6 -0
  133. package/dist/cjs/src/core/image/BackgroundImage.d.ts +20 -0
  134. package/dist/cjs/src/core/image/Image.d.ts +24 -0
  135. package/dist/cjs/src/core/image/__tests__/BackgroundImage.test.d.ts +1 -0
  136. package/dist/cjs/src/core/image/__tests__/Image.test.d.ts +1 -0
  137. package/dist/cjs/src/core/imageGallery/ImageGallery.d.ts +25 -0
  138. package/dist/cjs/src/core/imageGallery/ImageGalleryContext.d.ts +32 -0
  139. package/dist/cjs/src/core/imageGallery/ImageGalleryProvider.d.ts +10 -0
  140. package/dist/cjs/src/core/imageGallery/ImageItem.d.ts +26 -0
  141. package/dist/cjs/src/core/imageGallery/ImagesGrid.d.ts +26 -0
  142. package/dist/cjs/src/core/imageGallery/Lightbox.d.ts +24 -0
  143. package/dist/cjs/src/core/imageGallery/types.d.ts +6 -0
  144. package/dist/cjs/src/core/imageGallery/useImageGalleryContext.d.ts +1 -0
  145. package/dist/cjs/src/core/index.d.ts +43 -0
  146. package/dist/cjs/src/core/language/__tests__/languageSorter.test.d.ts +1 -0
  147. package/dist/cjs/src/core/language/constants.d.ts +6 -0
  148. package/dist/cjs/src/core/language/findLanguage.d.ts +10 -0
  149. package/dist/cjs/src/core/language/index.d.ts +6 -0
  150. package/dist/cjs/src/core/language/languageSorter.d.ts +4 -0
  151. package/dist/cjs/src/core/language/toPrimaryLanguageOption.d.ts +5 -0
  152. package/dist/cjs/src/core/language/typeGuards.d.ts +3 -0
  153. package/dist/cjs/src/core/language/types.d.ts +5 -0
  154. package/dist/cjs/src/core/link/Link.d.ts +44 -0
  155. package/dist/cjs/src/core/link/Link.stories.d.ts +33 -0
  156. package/dist/cjs/src/core/link/LinkBase.d.ts +106 -0
  157. package/dist/cjs/src/core/link/SecondaryLink.d.ts +3 -0
  158. package/dist/cjs/src/core/link/__tests__/Link.test.d.ts +1 -0
  159. package/dist/cjs/src/core/linkBox/Link.stories.d.ts +23 -0
  160. package/dist/cjs/src/core/linkBox/LinkBox.d.ts +20 -0
  161. package/dist/cjs/src/core/navigation/Navigation.d.ts +15 -0
  162. package/dist/cjs/src/core/notification/Notification.d.ts +9 -0
  163. package/dist/cjs/src/core/notification/__tests__/Notification.test.d.ts +1 -0
  164. package/dist/cjs/src/core/notification/utils/getIsNotificationActive.d.ts +2 -0
  165. package/dist/cjs/src/core/notification/utils/getNotificationHash.d.ts +2 -0
  166. package/dist/cjs/src/core/page/Page.d.ts +9 -0
  167. package/dist/cjs/src/core/page/Page.stories.d.ts +40 -0
  168. package/dist/cjs/src/core/pageContent/PageContent.d.ts +11 -0
  169. package/dist/cjs/src/core/pageContent/PageContent.stories.d.ts +1146 -0
  170. package/dist/cjs/src/core/pageContent/PageContentBreadcrumb.d.ts +5 -0
  171. package/dist/cjs/src/core/pageContent/PageContentLayout.d.ts +16 -0
  172. package/dist/cjs/src/core/pageContent/PageMainContent.d.ts +11 -0
  173. package/dist/cjs/src/core/pageContent/__tests__/Page.test.d.ts +1 -0
  174. package/dist/cjs/src/core/pageContent/meta/PageMeta.d.ts +9 -0
  175. package/dist/cjs/src/core/pageContent/sidebarContent/SidebarCardsList.d.ts +5 -0
  176. package/dist/cjs/src/core/pageContent/sidebarContent/SidebarContent.d.ts +15 -0
  177. package/dist/cjs/src/core/pageContent/sidebarContent/SidebarContentCard.d.ts +12 -0
  178. package/dist/cjs/src/core/pageContent/sidebarContent/SidebarContentLinkList.d.ts +5 -0
  179. package/dist/cjs/src/core/pageContent/sidebarContent/SidebarPostListItem.d.ts +8 -0
  180. package/dist/cjs/src/core/pageContent/sidebarContent/__tests__/SidebarContent.test.d.ts +1 -0
  181. package/dist/cjs/src/core/pageContent/types.d.ts +36 -0
  182. package/dist/cjs/src/core/pageContent/utils.d.ts +28 -0
  183. package/dist/cjs/src/core/pageContextProvider/PageContext.d.ts +6 -0
  184. package/dist/cjs/src/core/pageContextProvider/PageContextProvider.d.ts +6 -0
  185. package/dist/cjs/src/core/pageContextProvider/__tests__/PageContextProvider.test.d.ts +1 -0
  186. package/dist/cjs/src/core/pageContextProvider/usePageContext.d.ts +1 -0
  187. package/dist/cjs/src/core/pageModules/CardModule/CardModule.d.ts +3 -0
  188. package/dist/cjs/src/core/pageModules/CardModule/CardModule.stories.d.ts +7 -0
  189. package/dist/cjs/src/core/pageModules/CardsModule/CardsModule.d.ts +17 -0
  190. package/dist/cjs/src/core/pageModules/CardsModule/CardsModule.stories.d.ts +7 -0
  191. package/dist/cjs/src/core/pageModules/CardsModule/Icon.d.ts +6 -0
  192. package/dist/cjs/src/core/pageModules/CardsModule/SimpleCard.d.ts +13 -0
  193. package/dist/cjs/src/core/pageModules/ContentModule/ContentModule.d.ts +7 -0
  194. package/dist/cjs/src/core/pageModules/ContentModule/ContentModule.stories.d.ts +7 -0
  195. package/dist/cjs/src/core/pageModules/ImageGalleryModule/ImageGalleryModule.d.ts +3 -0
  196. package/dist/cjs/src/core/pageModules/ImageGalleryModule/ImageGalleryModule.stories.d.ts +7 -0
  197. package/dist/cjs/src/core/pageModules/SocialMediaFeedModule/SocialMediaFeedModule.d.ts +7 -0
  198. package/dist/cjs/src/core/pageModules/SocialMediaFeedModule/SocialMediaFeedModule.stories.d.ts +7 -0
  199. package/dist/cjs/src/core/pageModules/StepsModule/StepsModule.d.ts +14 -0
  200. package/dist/cjs/src/core/pageModules/StepsModule/StepsModule.stories.d.ts +7 -0
  201. package/dist/cjs/src/core/pageModules/constants.d.ts +1 -0
  202. package/dist/cjs/src/core/pageSection/PageSection.d.ts +32 -0
  203. package/dist/cjs/src/core/pageSection/PageSection.stories.d.ts +7 -0
  204. package/dist/cjs/src/core/pageSection/__tests__/PageSection.test.d.ts +1 -0
  205. package/dist/cjs/src/core/storyContainer/StoryContainer.d.ts +6 -0
  206. package/dist/cjs/src/core/translation/__tests__/getTranslationWithFallback.test.d.ts +1 -0
  207. package/dist/cjs/src/core/translation/constants.d.ts +12 -0
  208. package/dist/cjs/src/core/translation/getTranslationWithFallback.d.ts +4 -0
  209. package/dist/cjs/src/core/translation/types.d.ts +8 -0
  210. package/dist/cjs/src/core/translation/useTranslationWithFallback.d.ts +4 -0
  211. package/dist/cjs/src/core/utils/__tests__/findAllElementsOfType.test.d.ts +1 -0
  212. package/dist/cjs/src/core/utils/__tests__/getChildrenByType.test.d.ts +1 -0
  213. package/dist/cjs/src/core/utils/__tests__/recursiveMap.test.d.ts +1 -0
  214. package/dist/cjs/src/core/utils/createHashKey.d.ts +1 -0
  215. package/dist/cjs/src/core/utils/findAllElementsOfType.d.ts +5 -0
  216. package/dist/cjs/src/core/utils/getChildrenByType.d.ts +18 -0
  217. package/dist/cjs/src/core/utils/isTrustedOrigin.d.ts +1 -0
  218. package/dist/cjs/src/core/utils/recursiveMap.d.ts +15 -0
  219. package/dist/cjs/src/core/utils/string.d.ts +27 -0
  220. package/dist/cjs/src/core/utils/validateTrustedOriginsFormat.d.ts +1 -0
  221. package/dist/cjs/src/linkedEvents/utils/normalizeKey.d.ts +10 -0
  222. package/dist/cjs/src/linkedEvents/utils/normalizeKeys.d.ts +28 -0
  223. package/dist/cjs/src/mocks/handlers.d.ts +1 -0
  224. package/dist/cjs/src/mocks/queries/cms/languages.d.ts +1 -0
  225. package/dist/cjs/src/mocks/queries/cms/menu.d.ts +1 -0
  226. package/dist/cjs/src/mocks/queries/cms/notification.d.ts +1 -0
  227. package/dist/cjs/src/mocks/queries/cms/page.d.ts +1 -0
  228. package/dist/cjs/src/mocks/queries/linkedEvents/eventList.d.ts +242 -0
  229. package/dist/cjs/src/mocks/queries/linkedEvents/eventsByIds.d.ts +224 -0
  230. package/dist/cjs/src/mocks/responses/linkedEvents/eventMocks.d.ts +1112 -0
  231. package/dist/cjs/src/mocks/server.d.ts +1 -0
  232. package/dist/cjs/src/nextjs/getLanguageStaticProps.d.ts +3 -0
  233. package/dist/cjs/src/nextjs/getMenuStaticProps.d.ts +7 -0
  234. package/dist/cjs/src/nextjs/getPageStaticProps.d.ts +7 -0
  235. package/dist/cjs/src/nextjs/index.d.ts +3 -0
  236. package/dist/cjs/src/storybook-common/HelmetWrapper.d.ts +4 -0
  237. package/dist/cjs/src/storybook-common/constants.d.ts +9 -0
  238. package/dist/cjs/src/storybook-common/useCmsEndpointConfig.d.ts +3 -0
  239. package/dist/cjs/src/tests/apolloConfig.d.ts +2 -0
  240. package/dist/cjs/src/tests/hideConsoleMessages.d.ts +11 -0
  241. package/dist/configContext-BjJVyERb.d.ts +791 -0
  242. package/dist/defaultConfig-B0wJw6Kr.js +19810 -0
  243. package/dist/defaultConfig-B0wJw6Kr.js.map +1 -0
  244. package/dist/index-B0pDvzoV.js +2 -0
  245. package/dist/index-B0pDvzoV.js.map +1 -0
  246. package/dist/index.d.ts +1432 -0
  247. package/dist/index.js +333 -0
  248. package/dist/index.js.map +1 -0
  249. package/dist/jest-setup.d.ts +1 -0
  250. package/dist/nextjs.d.ts +17 -0
  251. package/dist/nextjs.js +70 -0
  252. package/dist/nextjs.js.map +1 -0
  253. package/dist/package.json +182 -0
  254. package/dist/src/apollo/apollo-custom-template.stories.d.ts +12 -0
  255. package/dist/src/apollo/apollo.stories.d.ts +24 -0
  256. package/dist/src/apollo/index.d.ts +17 -0
  257. package/dist/src/apollo/navigation/Navigation.d.ts +13 -0
  258. package/dist/src/apollo/navigation/__tests__/Navigation.test.d.ts +1 -0
  259. package/dist/src/apollo/notification/Notification.d.ts +4 -0
  260. package/dist/src/apollo/notification/__tests__/Notification.test.d.ts +1 -0
  261. package/dist/src/apollo/page/ApolloPageContextProvider.d.ts +5 -0
  262. package/dist/src/apollo/page/Page.d.ts +14 -0
  263. package/dist/src/apollo/page/apolloPageContext.d.ts +13 -0
  264. package/dist/src/apollo/page/useApolloPageContext.d.ts +4 -0
  265. package/dist/src/apollo/pageContent/PageContent.d.ts +9 -0
  266. package/dist/src/apollo/pageWithTemplateContent/PageWithTemplateContent.d.ts +14 -0
  267. package/dist/src/common/components/container/Container.d.ts +13 -0
  268. package/dist/src/common/components/grid/Grid.d.ts +16 -0
  269. package/dist/src/common/components/grid/Grid.stories.d.ts +8 -0
  270. package/dist/src/common/components/htmlToReact/HtmlToReact.d.ts +38 -0
  271. package/dist/src/common/components/htmlToReact/HtmlToReact.stories.d.ts +13 -0
  272. package/dist/src/common/components/htmlToReact/__tests__/HtmlToReact.tests.d.ts +1 -0
  273. package/dist/src/common/components/htmlToReact/replaceComponents/DefaultH2.d.ts +4 -0
  274. package/dist/src/common/components/htmlToReact/replaceComponents/DefaultP.d.ts +4 -0
  275. package/dist/src/common/components/htmlToReact/replaceComponents/IframeForEmbeddedMedia.d.ts +6 -0
  276. package/dist/src/common/components/htmlToReact/replaceComponents/index.d.ts +3 -0
  277. package/dist/src/common/components/icons/index.d.ts +5 -0
  278. package/dist/src/common/components/list/List.d.ts +13 -0
  279. package/dist/src/common/components/list/List.stories.d.ts +13 -0
  280. package/dist/src/common/components/tag/Tag.d.ts +26 -0
  281. package/dist/src/common/components/tag/Tag.stories.d.ts +80 -0
  282. package/dist/src/common/components/tag/__tests__/Tag.test.d.ts +1 -0
  283. package/dist/src/common/components/tag/tagThemes.d.ts +3 -0
  284. package/dist/src/common/components/text/Text.d.ts +27 -0
  285. package/dist/src/common/components/text/Text.stories.d.ts +14 -0
  286. package/dist/src/common/constants.d.ts +2 -0
  287. package/dist/src/common/eventsService/__generated__.d.ts +1420 -0
  288. package/dist/src/common/eventsService/events.d.ts +12 -0
  289. package/dist/src/common/eventsService/types.d.ts +2 -0
  290. package/dist/src/common/eventsService/utils.d.ts +7 -0
  291. package/dist/src/common/headlessService/__generated__.d.ts +20878 -0
  292. package/dist/src/common/headlessService/article.d.ts +7 -0
  293. package/dist/src/common/headlessService/articles.d.ts +17 -0
  294. package/dist/src/common/headlessService/categories.d.ts +13 -0
  295. package/dist/src/common/headlessService/category.d.ts +9 -0
  296. package/dist/src/common/headlessService/constants.d.ts +7 -0
  297. package/dist/src/common/headlessService/landingPage.d.ts +9 -0
  298. package/dist/src/common/headlessService/languages.d.ts +8 -0
  299. package/dist/src/common/headlessService/makeQueryWithApolloClientFromConfig.d.ts +12 -0
  300. package/dist/src/common/headlessService/menu.d.ts +10 -0
  301. package/dist/src/common/headlessService/notification.d.ts +7 -0
  302. package/dist/src/common/headlessService/page.d.ts +8 -0
  303. package/dist/src/common/headlessService/pageByTemplate.d.ts +9 -0
  304. package/dist/src/common/headlessService/pages.d.ts +13 -0
  305. package/dist/src/common/headlessService/tag.d.ts +9 -0
  306. package/dist/src/common/headlessService/tags.d.ts +13 -0
  307. package/dist/src/common/headlessService/types.d.ts +17 -0
  308. package/dist/src/common/headlessService/utils.d.ts +909 -0
  309. package/dist/src/common/utils/customRender.d.ts +4 -0
  310. package/dist/src/common/utils/dates.d.ts +20 -0
  311. package/dist/src/common/utils/getIsValidHttpUrl.d.ts +5 -0
  312. package/dist/src/common/utils/hash.d.ts +1 -0
  313. package/dist/src/common/utils/makeLocaleStorageValue.d.ts +6 -0
  314. package/dist/src/common/utils/testImage.d.ts +9 -0
  315. package/dist/src/common/venuesService/__generated__.d.ts +254 -0
  316. package/dist/src/common/venuesService/makeQueryWithVenuesApolloClientFromConfig.d.ts +7 -0
  317. package/dist/src/common/venuesService/types.d.ts +2 -0
  318. package/dist/src/constants.d.ts +5 -0
  319. package/dist/src/core/archiveSearchPage/ArchivePageMeta.d.ts +13 -0
  320. package/dist/src/core/archiveSearchPage/ArchiveSearchPage.d.ts +16 -0
  321. package/dist/src/core/archiveSearchPage/ArchiveSearchPage.stories.d.ts +50 -0
  322. package/dist/src/core/archiveSearchPageContent/ArchiveSearchPageContent.d.ts +92 -0
  323. package/dist/src/core/button/LoadingButton.d.ts +8 -0
  324. package/dist/src/core/card/Card.d.ts +102 -0
  325. package/dist/src/core/card/Card.stories.d.ts +99 -0
  326. package/dist/src/core/card/LargeCard.d.ts +68 -0
  327. package/dist/src/core/card/LargeCard.stories.d.ts +16 -0
  328. package/dist/src/core/cardsList/CardsList.d.ts +16 -0
  329. package/dist/src/core/cardsList/CardsList.stories.d.ts +22 -0
  330. package/dist/src/core/carousel/Carousel.d.ts +3 -0
  331. package/dist/src/core/carousel/Carousel.stories.d.ts +34 -0
  332. package/dist/src/core/carousel/__tests__/Carousel.test.d.ts +1 -0
  333. package/dist/src/core/carousel/components/CarouselSlideButton.d.ts +3 -0
  334. package/dist/src/core/carousel/components/CarouselSlider.d.ts +3 -0
  335. package/dist/src/core/carousel/components/CarouselSliderDot.d.ts +2 -0
  336. package/dist/src/core/carousel/components/CarouselSliderPage.d.ts +5 -0
  337. package/dist/src/core/carousel/components/__tests__/CarouselSlideButton.test.d.ts +1 -0
  338. package/dist/src/core/carousel/components/__tests__/CarouselSlider.test.d.ts +1 -0
  339. package/dist/src/core/carousel/components/__tests__/CarouselSliderDot.test.d.ts +1 -0
  340. package/dist/src/core/carousel/components/__tests__/CarouselSliderPage.test.d.ts +1 -0
  341. package/dist/src/core/carousel/constants.d.ts +20 -0
  342. package/dist/src/core/carousel/context/CarouselContext.d.ts +4 -0
  343. package/dist/src/core/carousel/context/CarouselContextProvider.d.ts +7 -0
  344. package/dist/src/core/carousel/types.d.ts +147 -0
  345. package/dist/src/core/carousel/utils/utils.d.ts +27 -0
  346. package/dist/src/core/collection/Collection.d.ts +102 -0
  347. package/dist/src/core/collection/Collection.stories.d.ts +48 -0
  348. package/dist/src/core/collection/__tests__/Collection.test.d.ts +1 -0
  349. package/dist/src/core/collection/constants.d.ts +1 -0
  350. package/dist/src/core/collection/types.d.ts +28 -0
  351. package/dist/src/core/collection/utils.d.ts +36 -0
  352. package/dist/src/core/configProvider/ConfigProvider.d.ts +13 -0
  353. package/dist/src/core/configProvider/configContext.d.ts +130 -0
  354. package/dist/src/core/configProvider/defaultConfig.d.ts +61 -0
  355. package/dist/src/core/configProvider/useApolloClientFromConfig.d.ts +1 -0
  356. package/dist/src/core/configProvider/useConfig.d.ts +2 -0
  357. package/dist/src/core/configProvider/useEventsApolloClientFromConfig.d.ts +1 -0
  358. package/dist/src/core/configProvider/useHeadlessCmsLink.d.ts +2 -0
  359. package/dist/src/core/configProvider/useVenuesApolloClientFromConfig.d.ts +1 -0
  360. package/dist/src/core/contentContainer/ContentContainer.d.ts +12 -0
  361. package/dist/src/core/contentContainer/ContentContainer.stories.d.ts +8 -0
  362. package/dist/src/core/hero/Hero.d.ts +33 -0
  363. package/dist/src/core/hero/Hero.stories.d.ts +23 -0
  364. package/dist/src/core/hooks/useResolveImageUrl.d.ts +6 -0
  365. package/dist/src/core/image/BackgroundImage.d.ts +20 -0
  366. package/dist/src/core/image/Image.d.ts +24 -0
  367. package/dist/src/core/image/__tests__/BackgroundImage.test.d.ts +1 -0
  368. package/dist/src/core/image/__tests__/Image.test.d.ts +1 -0
  369. package/dist/src/core/imageGallery/ImageGallery.d.ts +25 -0
  370. package/dist/src/core/imageGallery/ImageGalleryContext.d.ts +32 -0
  371. package/dist/src/core/imageGallery/ImageGalleryProvider.d.ts +10 -0
  372. package/dist/src/core/imageGallery/ImageItem.d.ts +26 -0
  373. package/dist/src/core/imageGallery/ImagesGrid.d.ts +26 -0
  374. package/dist/src/core/imageGallery/Lightbox.d.ts +24 -0
  375. package/dist/src/core/imageGallery/types.d.ts +6 -0
  376. package/dist/src/core/imageGallery/useImageGalleryContext.d.ts +1 -0
  377. package/dist/src/core/index.d.ts +43 -0
  378. package/dist/src/core/language/__tests__/languageSorter.test.d.ts +1 -0
  379. package/dist/src/core/language/constants.d.ts +6 -0
  380. package/dist/src/core/language/findLanguage.d.ts +10 -0
  381. package/dist/src/core/language/index.d.ts +6 -0
  382. package/dist/src/core/language/languageSorter.d.ts +4 -0
  383. package/dist/src/core/language/toPrimaryLanguageOption.d.ts +5 -0
  384. package/dist/src/core/language/typeGuards.d.ts +3 -0
  385. package/dist/src/core/language/types.d.ts +5 -0
  386. package/dist/src/core/link/Link.d.ts +44 -0
  387. package/dist/src/core/link/Link.stories.d.ts +33 -0
  388. package/dist/src/core/link/LinkBase.d.ts +106 -0
  389. package/dist/src/core/link/SecondaryLink.d.ts +3 -0
  390. package/dist/src/core/link/__tests__/Link.test.d.ts +1 -0
  391. package/dist/src/core/linkBox/Link.stories.d.ts +23 -0
  392. package/dist/src/core/linkBox/LinkBox.d.ts +20 -0
  393. package/dist/src/core/navigation/Navigation.d.ts +15 -0
  394. package/dist/src/core/notification/Notification.d.ts +9 -0
  395. package/dist/src/core/notification/__tests__/Notification.test.d.ts +1 -0
  396. package/dist/src/core/notification/utils/getIsNotificationActive.d.ts +2 -0
  397. package/dist/src/core/notification/utils/getNotificationHash.d.ts +2 -0
  398. package/dist/src/core/page/Page.d.ts +9 -0
  399. package/dist/src/core/page/Page.stories.d.ts +40 -0
  400. package/dist/src/core/pageContent/PageContent.d.ts +11 -0
  401. package/dist/src/core/pageContent/PageContent.stories.d.ts +1146 -0
  402. package/dist/src/core/pageContent/PageContentBreadcrumb.d.ts +5 -0
  403. package/dist/src/core/pageContent/PageContentLayout.d.ts +16 -0
  404. package/dist/src/core/pageContent/PageMainContent.d.ts +11 -0
  405. package/dist/src/core/pageContent/__tests__/Page.test.d.ts +1 -0
  406. package/dist/src/core/pageContent/meta/PageMeta.d.ts +9 -0
  407. package/dist/src/core/pageContent/sidebarContent/SidebarCardsList.d.ts +5 -0
  408. package/dist/src/core/pageContent/sidebarContent/SidebarContent.d.ts +15 -0
  409. package/dist/src/core/pageContent/sidebarContent/SidebarContentCard.d.ts +12 -0
  410. package/dist/src/core/pageContent/sidebarContent/SidebarContentLinkList.d.ts +5 -0
  411. package/dist/src/core/pageContent/sidebarContent/SidebarPostListItem.d.ts +8 -0
  412. package/dist/src/core/pageContent/sidebarContent/__tests__/SidebarContent.test.d.ts +1 -0
  413. package/dist/src/core/pageContent/types.d.ts +36 -0
  414. package/dist/src/core/pageContent/utils.d.ts +28 -0
  415. package/dist/src/core/pageContextProvider/PageContext.d.ts +6 -0
  416. package/dist/src/core/pageContextProvider/PageContextProvider.d.ts +6 -0
  417. package/dist/src/core/pageContextProvider/__tests__/PageContextProvider.test.d.ts +1 -0
  418. package/dist/src/core/pageContextProvider/usePageContext.d.ts +1 -0
  419. package/dist/src/core/pageModules/CardModule/CardModule.d.ts +3 -0
  420. package/dist/src/core/pageModules/CardModule/CardModule.stories.d.ts +7 -0
  421. package/dist/src/core/pageModules/CardsModule/CardsModule.d.ts +17 -0
  422. package/dist/src/core/pageModules/CardsModule/CardsModule.stories.d.ts +7 -0
  423. package/dist/src/core/pageModules/CardsModule/Icon.d.ts +6 -0
  424. package/dist/src/core/pageModules/CardsModule/SimpleCard.d.ts +13 -0
  425. package/dist/src/core/pageModules/ContentModule/ContentModule.d.ts +7 -0
  426. package/dist/src/core/pageModules/ContentModule/ContentModule.stories.d.ts +7 -0
  427. package/dist/src/core/pageModules/ImageGalleryModule/ImageGalleryModule.d.ts +3 -0
  428. package/dist/src/core/pageModules/ImageGalleryModule/ImageGalleryModule.stories.d.ts +7 -0
  429. package/dist/src/core/pageModules/SocialMediaFeedModule/SocialMediaFeedModule.d.ts +7 -0
  430. package/dist/src/core/pageModules/SocialMediaFeedModule/SocialMediaFeedModule.stories.d.ts +7 -0
  431. package/dist/src/core/pageModules/StepsModule/StepsModule.d.ts +14 -0
  432. package/dist/src/core/pageModules/StepsModule/StepsModule.stories.d.ts +7 -0
  433. package/dist/src/core/pageModules/constants.d.ts +1 -0
  434. package/dist/src/core/pageSection/PageSection.d.ts +32 -0
  435. package/dist/src/core/pageSection/PageSection.stories.d.ts +7 -0
  436. package/dist/src/core/pageSection/__tests__/PageSection.test.d.ts +1 -0
  437. package/dist/src/core/storyContainer/StoryContainer.d.ts +6 -0
  438. package/dist/src/core/translation/__tests__/getTranslationWithFallback.test.d.ts +1 -0
  439. package/dist/src/core/translation/constants.d.ts +12 -0
  440. package/dist/src/core/translation/getTranslationWithFallback.d.ts +4 -0
  441. package/dist/src/core/translation/types.d.ts +8 -0
  442. package/dist/src/core/translation/useTranslationWithFallback.d.ts +4 -0
  443. package/dist/src/core/utils/__tests__/findAllElementsOfType.test.d.ts +1 -0
  444. package/dist/src/core/utils/__tests__/getChildrenByType.test.d.ts +1 -0
  445. package/dist/src/core/utils/__tests__/recursiveMap.test.d.ts +1 -0
  446. package/dist/src/core/utils/createHashKey.d.ts +1 -0
  447. package/dist/src/core/utils/findAllElementsOfType.d.ts +5 -0
  448. package/dist/src/core/utils/getChildrenByType.d.ts +18 -0
  449. package/dist/src/core/utils/isTrustedOrigin.d.ts +1 -0
  450. package/dist/src/core/utils/recursiveMap.d.ts +15 -0
  451. package/dist/src/core/utils/string.d.ts +27 -0
  452. package/dist/src/core/utils/validateTrustedOriginsFormat.d.ts +1 -0
  453. package/dist/src/linkedEvents/utils/normalizeKey.d.ts +10 -0
  454. package/dist/src/linkedEvents/utils/normalizeKeys.d.ts +28 -0
  455. package/dist/src/mocks/handlers.d.ts +1 -0
  456. package/dist/src/mocks/queries/cms/languages.d.ts +1 -0
  457. package/dist/src/mocks/queries/cms/menu.d.ts +1 -0
  458. package/dist/src/mocks/queries/cms/notification.d.ts +1 -0
  459. package/dist/src/mocks/queries/cms/page.d.ts +1 -0
  460. package/dist/src/mocks/queries/linkedEvents/eventList.d.ts +242 -0
  461. package/dist/src/mocks/queries/linkedEvents/eventsByIds.d.ts +224 -0
  462. package/dist/src/mocks/responses/linkedEvents/eventMocks.d.ts +1112 -0
  463. package/dist/src/mocks/server.d.ts +1 -0
  464. package/dist/src/nextjs/getLanguageStaticProps.d.ts +3 -0
  465. package/dist/src/nextjs/getMenuStaticProps.d.ts +7 -0
  466. package/dist/src/nextjs/getPageStaticProps.d.ts +7 -0
  467. package/dist/src/nextjs/index.d.ts +3 -0
  468. package/dist/src/storybook-common/HelmetWrapper.d.ts +4 -0
  469. package/dist/src/storybook-common/constants.d.ts +9 -0
  470. package/dist/src/storybook-common/useCmsEndpointConfig.d.ts +3 -0
  471. package/dist/src/tests/apolloConfig.d.ts +2 -0
  472. package/dist/src/tests/hideConsoleMessages.d.ts +11 -0
  473. package/package.json +1 -1
@@ -0,0 +1,5 @@
1
+ import React from 'react';
2
+ import type { BreadcrumbUnionType } from './types';
3
+ export declare function PageContentBreadcrumb({ breadcrumbs, }: {
4
+ breadcrumbs: BreadcrumbUnionType;
5
+ }): React.JSX.Element;
@@ -0,0 +1,16 @@
1
+ import React from 'react';
2
+ import type { HeroProps } from './types';
3
+ export type PageContentLayoutProps = {
4
+ id: string;
5
+ breadcrumbs?: React.ReactNode;
6
+ heroContainer?: JSX.Element;
7
+ content: React.ReactNode;
8
+ shareLinks?: React.ReactNode;
9
+ collections?: React.ReactNode;
10
+ sidebarContent: React.ReactNode;
11
+ imageSrc?: string | null;
12
+ imageAlt?: string;
13
+ imageLabel?: string;
14
+ backUrl?: string;
15
+ } & HeroProps;
16
+ export declare function PageContentLayout({ id, breadcrumbs, heroContainer, content, shareLinks, collections, sidebarContent, imageSrc, imageAlt, imageLabel, backUrl, ...heroProps }: PageContentLayoutProps): React.JSX.Element;
@@ -0,0 +1,11 @@
1
+ import React from 'react';
2
+ import type { ArticleType } from '../../common/headlessService/types';
3
+ export type PageMainContentProps = {
4
+ title: string;
5
+ content: string;
6
+ date?: string;
7
+ categories?: NonNullable<ArticleType>['categories'];
8
+ contentModules?: React.ReactNode[];
9
+ onArticlesSearch?: (tag: string) => void;
10
+ };
11
+ export declare function PageMainContent({ title, content, date, categories, contentModules, onArticlesSearch, }: PageMainContentProps): React.JSX.Element;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ import type { ArticleType, PageType } from '../../../common/headlessService/types';
3
+ export type PageMetaProps = {
4
+ page?: PageType | ArticleType;
5
+ headComponent: React.ComponentType<{
6
+ children: React.ReactNode;
7
+ }>;
8
+ };
9
+ export declare function PageMeta({ page, headComponent: Head }: PageMetaProps): React.JSX.Element;
@@ -0,0 +1,5 @@
1
+ import React from 'react';
2
+ import type { LayoutCards } from '../../../common/headlessService/types';
3
+ type CardsListItemProps = Omit<LayoutCards, '__typename'>;
4
+ export default function SidebarCardsList({ cards }: CardsListItemProps): React.JSX.Element | null;
5
+ export {};
@@ -0,0 +1,15 @@
1
+ import React from 'react';
2
+ import List from '../../../common/components/list/List';
3
+ import type { SidebarContent as SidebarContentType } from '../../../common/headlessService/types';
4
+ import SidebarContentLinkList from './SidebarContentLinkList';
5
+ import SidebarPostListItem from './SidebarPostListItem';
6
+ import SidebarCardsList from './SidebarCardsList';
7
+ type SidebarContentProps = {
8
+ content?: SidebarContentType;
9
+ SidebarContentLinkListComponent?: typeof SidebarContentLinkList;
10
+ SidebarPostListComponent?: typeof List;
11
+ SideBarPostListItemComponent?: typeof SidebarPostListItem;
12
+ SideBarCardsListComponent?: typeof SidebarCardsList;
13
+ };
14
+ export default function SidebarContent({ content, SidebarContentLinkListComponent, SidebarPostListComponent, SideBarPostListItemComponent, SideBarCardsListComponent, }: SidebarContentProps): React.JSX.Element;
15
+ export {};
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ type SidebarContentCardProps = {
3
+ id: string;
4
+ title: string;
5
+ url: string;
6
+ imageUrl?: string;
7
+ imageAlt?: string;
8
+ description?: string;
9
+ publishingDate?: string;
10
+ };
11
+ export default function SidebarContentCard({ id, title, url, imageUrl, imageAlt, description, publishingDate, }: SidebarContentCardProps): React.JSX.Element;
12
+ export {};
@@ -0,0 +1,5 @@
1
+ import React from 'react';
2
+ import type { LayoutLinkList } from '../../../common/headlessService/types';
3
+ type SidebarContentLinkListProps = Omit<LayoutLinkList, '__typename'>;
4
+ export default function SidebarContentLinkList({ anchor, title, description, links, }: SidebarContentLinkListProps): React.JSX.Element;
5
+ export {};
@@ -0,0 +1,8 @@
1
+ import React from 'react';
2
+ import type { ModuleItemTypeEnum } from '../../../common/headlessService/constants';
3
+ import type { LayoutArticle, LayoutPage } from '../../../common/headlessService/types';
4
+ type PostListItemProps = (NonNullable<LayoutArticle['articles']>[number] | NonNullable<LayoutPage['pages']>[number]) & {
5
+ moduleItemType: ModuleItemTypeEnum;
6
+ };
7
+ export default function PostListItem({ id, moduleItemType, title, link, featuredImage, date, }: PostListItemProps): React.JSX.Element | null;
8
+ export {};
@@ -0,0 +1,36 @@
1
+ import type { BreadcrumbListItem, BreadcrumbProps, KorosType } from 'hds-react';
2
+ import type { ArticleType, PageType } from '../../common/headlessService/types';
3
+ import type { Breadcrumb as CmsBreadcrumb } from '../../common/headlessService/__generated__';
4
+ import type { Collection } from '../collection/Collection';
5
+ import type SidebarContent from './sidebarContent/SidebarContent';
6
+ import type { PageContentLayout } from './PageContentLayout';
7
+ export type HeroProps = {
8
+ title?: string;
9
+ description?: string;
10
+ backgroundColor?: string;
11
+ korosType?: KorosType;
12
+ actionUrl?: string;
13
+ actionUrlTarget?: string;
14
+ actionText?: string;
15
+ isPageType?: boolean;
16
+ };
17
+ export type LinkItem = {
18
+ target?: string | null;
19
+ title: string;
20
+ url: string;
21
+ };
22
+ export type BreadcrumbUnionType = BreadcrumbProps | BreadcrumbListItem[] | CmsBreadcrumb[];
23
+ export type PageContentProps = {
24
+ page?: PageType | ArticleType;
25
+ breadcrumbs?: BreadcrumbUnionType | ((page?: PageType | ArticleType) => BreadcrumbUnionType);
26
+ content?: React.ReactNode | ((page: PageType | ArticleType) => React.ReactNode);
27
+ shareLinks?: React.ReactNode;
28
+ collections?: React.ReactElement<typeof Collection>[] | ((page: PageType | ArticleType) => React.ReactElement<typeof Collection>[]);
29
+ heroContainer?: JSX.Element;
30
+ backUrl?: string;
31
+ sidebarContentProps?: Partial<typeof SidebarContent>;
32
+ PageContentLayoutComponent?: typeof PageContentLayout;
33
+ className?: string;
34
+ onArticlesSearch?: (tag: string) => void;
35
+ [x: string]: any;
36
+ } & Partial<typeof PageContentLayout>;
@@ -0,0 +1,28 @@
1
+ import type { BreadcrumbListItem, BreadcrumbProps } from 'hds-react';
2
+ import type { EventType } from '../../common/eventsService/types';
3
+ import type { ArticleType, PageModule, PageType } from '../../common/headlessService/types';
4
+ import type { VenueType } from '../../common/venuesService/types';
5
+ import type { CardProps } from '../card/Card';
6
+ import { type CollectionProps } from '../collection/Collection';
7
+ import type { CollectionType } from '../collection/types';
8
+ import type { Breadcrumb as CmsBreadcrumb } from '../../common/headlessService/__generated__';
9
+ import type { BreadcrumbUnionType, HeroProps } from './types';
10
+ export declare function getCollections(pageModules: PageModule[], isEventSearchCollectionsEnables?: boolean): CollectionType[];
11
+ export declare function getArticlePageCardProps(item: ArticleType | PageType): CardProps;
12
+ export declare function getEventCardProps(item: EventType, organisationPrefixes: string[], locale?: string): CardProps;
13
+ export declare function getLocationCardProps(item: VenueType): CardProps;
14
+ export declare function getCollectionCards(collection: CollectionType, organisationPrefixes: string[], locale?: string): CardProps[];
15
+ export declare function getCollectionUIType(collection: CollectionType): CollectionProps['type'];
16
+ /**
17
+ * Create Breadcrumb list items from the pages' and articles' breadcrumbs.
18
+ * The duplicated root (and other duplicated links) are removed.
19
+ * @param page a page or an article
20
+ * @returns an unique list of breadcrumb list items
21
+ * */
22
+ export declare const getBreadcrumbsFromPage: (page: PageType | ArticleType) => BreadcrumbListItem[];
23
+ export declare function isHdsBreadcrumb(item: BreadcrumbUnionType): item is BreadcrumbProps;
24
+ export declare function isHdsBreadcrumbListItem(item: unknown): item is BreadcrumbListItem;
25
+ export declare function isCmsBreadcrumb(item: unknown): item is CmsBreadcrumb;
26
+ export declare function getHeroProps(page: PageType | ArticleType): HeroProps;
27
+ export declare function disableBreadcrumbsLastLink(breadcrumbs: BreadcrumbListItem[]): BreadcrumbListItem[];
28
+ export declare function getBreadcrumbListItems(breadcrumbs: BreadcrumbUnionType, forceLastItemWithoutLink?: boolean): BreadcrumbListItem[];
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ import type { ArticleType, PageType } from '../../common/headlessService/types';
3
+ export type PageContextProps = {
4
+ page: PageType | ArticleType;
5
+ };
6
+ export declare const PageContext: React.Context<PageContextProps>;
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ import type { PageContextProps } from './PageContext';
3
+ export type PageContextProviderProps = PageContextProps & {
4
+ children: React.ReactNode;
5
+ };
6
+ export declare function PageContextProvider({ page, children, }: PageContextProviderProps): React.JSX.Element;
@@ -0,0 +1 @@
1
+ import '@testing-library/jest-dom';
@@ -0,0 +1 @@
1
+ export declare function usePageContext(): import("./PageContext").PageContextProps;
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ import type { CardProps } from '../../card/Card';
3
+ export declare function CardModule(props: CardProps): React.JSX.Element;
@@ -0,0 +1,7 @@
1
+ import type { Meta } from '@storybook/react-webpack5';
2
+ import { CardModule } from './CardModule';
3
+ declare const _default: Meta<typeof CardModule>;
4
+ export default _default;
5
+ export declare const CardModuleDefault: {
6
+ render: import("storybook/internal/csf").AnnotatedStoryFn<import("@storybook/react").ReactRenderer, import("../..").CardProps>;
7
+ };
@@ -0,0 +1,17 @@
1
+ import React from 'react';
2
+ type Card = {
3
+ backgroundColor?: string;
4
+ description?: string;
5
+ icon?: string;
6
+ title?: string;
7
+ link?: {
8
+ target?: string;
9
+ title?: string;
10
+ url?: string;
11
+ };
12
+ };
13
+ export type CardsModuleProps = {
14
+ items: Card[];
15
+ };
16
+ export declare function CardsModule({ items }: CardsModuleProps): React.JSX.Element;
17
+ export {};
@@ -0,0 +1,7 @@
1
+ import type { Meta } from '@storybook/react-webpack5';
2
+ import { CardsModule } from './CardsModule';
3
+ declare const _default: Meta<typeof CardsModule>;
4
+ export default _default;
5
+ export declare const CardsModuleDefault: {
6
+ render: import("storybook/internal/csf").AnnotatedStoryFn<import("@storybook/react").ReactRenderer, import("./CardsModule").CardsModuleProps>;
7
+ };
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ type IconProps = {
3
+ name: string;
4
+ };
5
+ export declare function Icon({ name }: IconProps): React.JSX.Element;
6
+ export {};
@@ -0,0 +1,13 @@
1
+ import React from 'react';
2
+ type CardProps = {
3
+ title?: string;
4
+ description?: string;
5
+ backgroundColor?: string;
6
+ icon?: string;
7
+ linkTitle?: string;
8
+ linkTarget?: string;
9
+ linkUrl?: string;
10
+ direction?: 'vertical' | 'horisontal';
11
+ };
12
+ export declare function SimpleCard({ title, description, backgroundColor, icon, linkTitle, linkTarget, linkUrl, direction, }: CardProps): React.JSX.Element;
13
+ export {};
@@ -0,0 +1,7 @@
1
+ import React from 'react';
2
+ export type ContentModuleProps = {
3
+ content?: string;
4
+ backgroundColor?: string;
5
+ className?: string;
6
+ };
7
+ export declare function ContentModule({ content, backgroundColor, className, }: ContentModuleProps): React.JSX.Element;
@@ -0,0 +1,7 @@
1
+ import type { Meta } from '@storybook/react-webpack5';
2
+ import { ContentModule } from './ContentModule';
3
+ declare const _default: Meta<typeof ContentModule>;
4
+ export default _default;
5
+ export declare const ContentModuleDefault: {
6
+ render: import("storybook/internal/csf").AnnotatedStoryFn<import("@storybook/react").ReactRenderer, import("./ContentModule").ContentModuleProps>;
7
+ };
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ import type { ImageGalleryProps } from '../../imageGallery/ImageGallery';
3
+ export declare function ImageGalleryModule(props: ImageGalleryProps): React.JSX.Element;
@@ -0,0 +1,7 @@
1
+ import type { Meta } from '@storybook/react-webpack5';
2
+ import { ImageGalleryModule } from './ImageGalleryModule';
3
+ declare const _default: Meta<typeof ImageGalleryModule>;
4
+ export default _default;
5
+ export declare const ImageGalleryModuleDefault: {
6
+ render: import("storybook/internal/csf").AnnotatedStoryFn<import("@storybook/react").ReactRenderer, import("../../imageGallery/ImageGallery").ImageGalleryProps>;
7
+ };
@@ -0,0 +1,7 @@
1
+ import React from 'react';
2
+ export interface SocialMediaFeedModuleProps {
3
+ anchor: string;
4
+ title?: string;
5
+ script?: string;
6
+ }
7
+ export declare function SocialMediaFeedModule({ anchor, title, script, }: SocialMediaFeedModuleProps): React.JSX.Element;
@@ -0,0 +1,7 @@
1
+ import type { Meta } from '@storybook/react-webpack5';
2
+ import { SocialMediaFeedModule } from './SocialMediaFeedModule';
3
+ declare const _default: Meta<typeof SocialMediaFeedModule>;
4
+ export default _default;
5
+ export declare const SocialMediaFeedModuleDefault: {
6
+ render: import("storybook/internal/csf").AnnotatedStoryFn<import("@storybook/react").ReactRenderer, import("./SocialMediaFeedModule").SocialMediaFeedModuleProps>;
7
+ };
@@ -0,0 +1,14 @@
1
+ import React from 'react';
2
+ export type Step = {
3
+ content: string;
4
+ title: string;
5
+ };
6
+ export type StepsModuleProps = {
7
+ steps?: Step[];
8
+ title?: string;
9
+ helpText?: string;
10
+ color?: string;
11
+ type?: string;
12
+ className?: string;
13
+ };
14
+ export declare function StepsModule({ title, helpText, color, steps, type, className, }: StepsModuleProps): React.JSX.Element;
@@ -0,0 +1,7 @@
1
+ import type { Meta } from '@storybook/react-webpack5';
2
+ import { StepsModule } from './StepsModule';
3
+ declare const _default: Meta<typeof StepsModule>;
4
+ export default _default;
5
+ export declare const StepsModuleDefault: {
6
+ render: import("storybook/internal/csf").AnnotatedStoryFn<import("@storybook/react").ReactRenderer, import("./StepsModule").StepsModuleProps>;
7
+ };
@@ -0,0 +1 @@
1
+ export declare const SELECT_COLORS: string[];
@@ -0,0 +1,32 @@
1
+ import React from 'react';
2
+ export type PageSectionProps = {
3
+ /**
4
+ * Additional children to render inside the Page section.
5
+ */
6
+ children: React.ReactNode;
7
+ /**
8
+ * Additional classname for the Page section.
9
+ */
10
+ className?: string;
11
+ /**
12
+ * Boolean indicating whether the koros top shouyld be displayed.
13
+ */
14
+ korosTop?: boolean;
15
+ /**
16
+ * Custom top koros classname.
17
+ */
18
+ korosTopClassName?: string;
19
+ /**
20
+ * Boolean indicating whether the koros bottom shouyld be displayed.
21
+ */
22
+ korosBottom?: boolean;
23
+ /**
24
+ * Custom bottom koros classname.
25
+ */
26
+ korosBottomClassName?: string;
27
+ /**
28
+ * Backgroud image url.
29
+ */
30
+ backgroundImageUrl?: string;
31
+ };
32
+ export declare function PageSection({ className, children, korosTop, korosTopClassName, korosBottom, korosBottomClassName, backgroundImageUrl, }: PageSectionProps): React.JSX.Element;
@@ -0,0 +1,7 @@
1
+ import type { Meta } from '@storybook/react-webpack5';
2
+ import { PageSection } from './PageSection';
3
+ declare const _default: Meta<typeof PageSection>;
4
+ export default _default;
5
+ export declare const CardDefault: {
6
+ render: import("storybook/internal/csf").AnnotatedStoryFn<import("@storybook/react").ReactRenderer, import("./PageSection").PageSectionProps>;
7
+ };
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ export type StoryContainerProps = {
3
+ children: React.ReactNode;
4
+ maxWidth?: number;
5
+ };
6
+ export declare function StoryContainer({ children, maxWidth }: StoryContainerProps): React.JSX.Element;
@@ -0,0 +1,12 @@
1
+ import type { LanguageCodeEnum } from '../../apollo';
2
+ type TranslationDictionary = Record<LanguageCodeEnum, string>;
3
+ export declare const FALLBACK_TRANSLATION_KEYS: readonly ["headerActionBarLogoAlt", "headerActionBarLogoAriaLabel", "headerActionBarLogoSrc", "headerUniversalBarPrimaryLinkHref", "headerUniversalBarPrimaryLinkText", "carouselRegionLabelText", "carouselSliderRegionLabelText", "carouselSliderDotNavLabelText"];
4
+ export declare const CITY_OF_HELSINKI_TRANSLATIONS: TranslationDictionary;
5
+ export declare const HELSINKI_TRANSLATIONS: TranslationDictionary;
6
+ export declare const LOCALIZED_HELSINKI_LOGO_SVG_CONTENTS: TranslationDictionary;
7
+ export declare const LOCALIZED_HELSINKI_WEBSITE_URL: TranslationDictionary;
8
+ export declare const CAROUSEL_REGION_LABEL_TEXT: TranslationDictionary;
9
+ export declare const CAROUSEL_SLIDER_REGION_LABEL_TEXT: TranslationDictionary;
10
+ export declare const CAROUSEL_SLIDER_DOT_NAV_LABEL_TEXT: TranslationDictionary;
11
+ export declare const FALLBACK_TRANSLATIONS: Record<(typeof FALLBACK_TRANSLATION_KEYS)[number], TranslationDictionary>;
12
+ export {};
@@ -0,0 +1,4 @@
1
+ import type { LanguageCodeEnum } from '../../common/headlessService/__generated__';
2
+ import type { Config } from '../configProvider/configContext';
3
+ import type { FallbackTranslationKey } from './types';
4
+ export declare const getTranslationWithFallback: (config: Config, field: FallbackTranslationKey, language: LanguageCodeEnum) => string;
@@ -0,0 +1,8 @@
1
+ import type { LanguageCodeEnum } from '../../common/headlessService/__generated__';
2
+ import type { FALLBACK_TRANSLATION_KEYS } from './constants';
3
+ export type FallbackTranslationKey = (typeof FALLBACK_TRANSLATION_KEYS)[number];
4
+ export type FallbackTranslation = Record<LanguageCodeEnum, string>;
5
+ export type FallbackTranslations = Record<FallbackTranslationKey, FallbackTranslation>;
6
+ export type OptionalTranslationsWithFallbacks = {
7
+ [key in FallbackTranslationKey]?: string;
8
+ };
@@ -0,0 +1,4 @@
1
+ import type { FallbackTranslationKey } from './types';
2
+ export declare function useTranslationWithFallback(): {
3
+ t: (field: FallbackTranslationKey) => string;
4
+ };
@@ -0,0 +1 @@
1
+ export default function createHashKey(source: string | object): string;
@@ -0,0 +1,5 @@
1
+ /**
2
+ * Find all elements of defined types recursively from a ReactNode.
3
+ * @returns a list of elements of specified types that could be found from inside the ReactNode.
4
+ */
5
+ export declare const findAllElementsOfType: (children: React.ReactNode, types: string[]) => import("react").ReactNode[];
@@ -0,0 +1,18 @@
1
+ import React from 'react';
2
+ /**
3
+ * Gets the string type of the component or core html (JSX) element.
4
+ * React Fragments will return type 'react.fragment'.
5
+ * Priority will be given to the prop '__TYPE'.
6
+ */
7
+ export declare const typeOfComponent: (component: React.ReactElement) => string;
8
+ /**
9
+ * Gets all children by specified type.
10
+ * This function will check the prop '__TYPE' first
11
+ * and then the 'type' string to match core html elements.
12
+ * To find a React Fragment, search for type 'react.fragment'.
13
+ *
14
+ * @example
15
+ * // Finds all occurrences of ToDo (custom component), div, and React Fragment
16
+ * getChildrenByType(children, ['ToDo', 'div', 'react.fragment']);
17
+ */
18
+ export declare const getChildrenByType: (children: React.ReactNode, types: string[]) => React.ReactNode[];
@@ -0,0 +1 @@
1
+ export default function isTrustedOrigin(testedOrigin: string, trustedOrigins: string[]): boolean;
@@ -0,0 +1,15 @@
1
+ import React from 'react';
2
+ /**
3
+ * Recursively loops through the children of a ReactNode
4
+ * and runs the given function from arguments to the every child.
5
+ *
6
+ * If the child is a ReactElement and it has children,
7
+ * the children will be recursively called with the given function.
8
+ *
9
+ * If the child is not a valid ReactElement,
10
+ * which would mean that it is for example a string content of an HTML-element,
11
+ * it is directly returned.
12
+ *
13
+ * See the unit tests for some examples.
14
+ */
15
+ export declare const recursiveMap: (children: React.ReactNode, fn: (children: React.ReactNode) => React.ReactNode) => React.ReactNode;
@@ -0,0 +1,27 @@
1
+ export declare const SELECT_COLORS_LIGHT: string[];
2
+ /**
3
+ * Converts a string (e.g., 'coat-of-arms') into PascalCase (e.g., 'CoatOfArms').
4
+ * @param {string} color The color string to convert.
5
+ * @returns {string} The color string in PascalCase format.
6
+ */
7
+ export declare const getColor: (color: string) => string;
8
+ /**
9
+ * Prepends 'icon-' to a name and converts it to PascalCase (e.g., 'icon-alert' to 'IconAlert').
10
+ * @param {string} name The icon name part.
11
+ * @returns {string} The icon name in PascalCase format.
12
+ */
13
+ export declare const getIconName: (name: string) => string;
14
+ /**
15
+ * Strips all HTML tags from a string and decodes HTML entities.
16
+ * Uses a safe regex (/<[^>]*>/gi) to prevent ReDoS (Regular Expression Denial of Service).
17
+ *
18
+ * @param {string} html The input string containing HTML markup.
19
+ * @returns {string} The resulting text string with all HTML tags removed and entities decoded.
20
+ */
21
+ export declare const getTextFromHtml: (html: string) => string;
22
+ /**
23
+ * Checks if the text color should be white based on the background color.
24
+ * @param {string} color The background color string.
25
+ * @returns {boolean} True if white text should be used, false otherwise.
26
+ */
27
+ export declare const isWhiteText: (color: string) => boolean;
@@ -0,0 +1 @@
1
+ export default function validateTrustedOriginsFormat(trustedOrigins?: string[]): void;
@@ -0,0 +1,10 @@
1
+ /** Cloned from the events-proxy https://github.com/City-of-Helsinki/events-helsinki-api-proxy/tree/master/src/utils */
2
+ /**
3
+ * Normalize snake case keys to a form that GraphlQL can use
4
+ * Keys with @-prefix are replacing with internal-prefix
5
+ * e.g
6
+ * @event_type => internalEventType
7
+ * event_end_date => eventEndDate
8
+ */
9
+ declare const _default: (snakecase: string) => string;
10
+ export default _default;
@@ -0,0 +1,28 @@
1
+ /**
2
+ * Normalizes an object or array of objects by converting keys from snake_case to camelCase.
3
+ * This function handles nested objects and arrays recursively.
4
+ *
5
+ * Example:
6
+ * Before:
7
+ * {
8
+ * @id: "123",
9
+ * event_type: "foo",
10
+ * event_price: {
11
+ * is_free: false
12
+ * }
13
+ * }
14
+ * After:
15
+ * {
16
+ * internalId: "123",
17
+ * eventType: "foo",
18
+ * eventPrice: {
19
+ * isFree: false
20
+ * }
21
+ * }
22
+ *
23
+ * @template T - The type of the input value.
24
+ * @param {T} value - The object, array, or primitive to normalize.
25
+ * @returns {T} - A new object or array with normalized keys, or the original value if it's a primitive.
26
+ */
27
+ declare function normalizeKeys<T>(value: T): T;
28
+ export default normalizeKeys;
@@ -0,0 +1 @@
1
+ export declare const handlers: import("msw").GraphQLHandler[];
@@ -0,0 +1 @@
1
+ export declare const queryLanguages: () => import("msw").GraphQLHandler;
@@ -0,0 +1 @@
1
+ export declare const queryMenu: () => import("msw").GraphQLHandler;
@@ -0,0 +1 @@
1
+ export declare const queryNotification: () => import("msw").GraphQLHandler;
@@ -0,0 +1 @@
1
+ export declare const queryPage: () => import("msw").GraphQLHandler;