@ndla/ui 41.2.4 → 41.2.5

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 (453) hide show
  1. package/es/Animation/index.js +0 -1
  2. package/es/Article/Article.js +1 -1
  3. package/es/Article/ArticleByline.js +1 -1
  4. package/es/AudioPlayer/AudioPlayer.js +1 -1
  5. package/es/AudioPlayer/Controls.js +1 -1
  6. package/es/BlogPost/BlogPost.js +4 -4
  7. package/es/Breadcrumb/Breadcrumb.js +2 -2
  8. package/es/CompetenceGoalTab/CompetenceGoalTab.js +1 -1
  9. package/es/CopyParagraphButton/CopyParagraphButton.js +1 -1
  10. package/es/CopyParagraphButton/CopyParagraphButtonV2.js +1 -1
  11. package/es/Embed/BrightcoveEmbed.js +1 -1
  12. package/es/Embed/ConceptEmbed.js +1 -1
  13. package/es/Embed/ImageEmbed.js +1 -1
  14. package/es/FactBox/FactBoxV2.js +1 -1
  15. package/es/Filter/FilterButtons.js +1 -1
  16. package/es/Filter/FilterCarousel.js +1 -1
  17. package/es/Filter/FilterList.js +1 -1
  18. package/es/Filter/FilterListPhone.js +1 -1
  19. package/es/Frontpage/FrontpageProgramMenu.js +1 -1
  20. package/es/Grid/Grid.js +16 -11
  21. package/es/KeyFigure/KeyFigure.js +10 -10
  22. package/es/LearningPaths/LearningPathMenu.js +1 -1
  23. package/es/LicenseByline/EmbedByline.js +4 -12
  24. package/es/LicenseByline/LicenseLink.js +2 -2
  25. package/es/Masthead/MastheadSearchModal.js +1 -1
  26. package/es/Masthead/utils.js +1 -1
  27. package/es/MultidisciplinarySubject/index.js +0 -2
  28. package/es/NDLAFilm/AllMoviesAlphabetically.js +1 -1
  29. package/es/NDLAFilm/CategorySelect.js +1 -1
  30. package/es/NDLAFilm/FilmSlideshow.js +1 -1
  31. package/es/Navigation/NavigationBox.js +1 -1
  32. package/es/ProgrammeCard/ProgrammeCard.js +1 -1
  33. package/es/RadioButtonGroup/RadioButtonGroup.js +2 -4
  34. package/es/RelatedArticleList/RelatedArticleV2.js +1 -1
  35. package/es/Search/ContentTypeResult.js +1 -1
  36. package/es/Search/SearchResultSleeve.js +1 -1
  37. package/es/SearchTypeResult/PopupFilter.js +1 -1
  38. package/es/SearchTypeResult/SearchFieldHeader.js +1 -1
  39. package/es/SearchTypeResult/SearchHeader.js +1 -1
  40. package/es/SearchTypeResult/components/SubjectFilters.js +1 -1
  41. package/es/SnackBar/SnackbarProvider.js +1 -1
  42. package/es/Table/Table.js +1 -1
  43. package/es/TagSelector/TagSelector.js +1 -1
  44. package/es/TreeStructure/FolderItem.js +1 -1
  45. package/es/TreeStructure/TreeStructure.js +2 -2
  46. package/es/User/UserInfo.js +1 -1
  47. package/es/User/parseUserObject.js +1 -1
  48. package/es/all.css +1 -1
  49. package/es/index.js +1 -6
  50. package/es/locale/messages-en.js +5 -5
  51. package/es/locale/messages-nb.js +5 -5
  52. package/es/locale/messages-nn.js +5 -5
  53. package/es/locale/messages-se.js +5 -5
  54. package/es/locale/messages-sma.js +5 -5
  55. package/lib/Animation/Fade.js +4 -4
  56. package/lib/Animation/index.d.ts +0 -1
  57. package/lib/Animation/index.js +2 -9
  58. package/lib/Article/Article.js +19 -19
  59. package/lib/Article/ArticleAccessMessage.js +6 -6
  60. package/lib/Article/ArticleByline.js +12 -12
  61. package/lib/Article/ArticleContent.js +3 -3
  62. package/lib/Article/ArticleFootNotes.js +5 -5
  63. package/lib/Article/ArticleHeaderWrapper.js +5 -5
  64. package/lib/Article/ArticleNotions.js +8 -8
  65. package/lib/Article/ArticleSideBar.js +5 -5
  66. package/lib/Article/index.js +10 -10
  67. package/lib/Aside/Aside.js +4 -4
  68. package/lib/Aside/index.js +4 -4
  69. package/lib/AudioPlayer/AudioPlayer.js +22 -22
  70. package/lib/AudioPlayer/Controls.js +26 -26
  71. package/lib/AudioPlayer/SpeechControl.js +5 -5
  72. package/lib/AudioPlayer/index.js +5 -5
  73. package/lib/AudioPlayer/initAudioPlayers.js +6 -6
  74. package/lib/BannerCard/BannerCard.js +10 -10
  75. package/lib/BannerCard/index.js +2 -2
  76. package/lib/BlogPost/BlogPost.js +10 -10
  77. package/lib/BlogPost/index.js +2 -2
  78. package/lib/BlogPosts/BlogPost.js +7 -7
  79. package/lib/BlogPosts/BlogPostWrapper.js +4 -4
  80. package/lib/BlogPosts/index.js +3 -3
  81. package/lib/Breadcrumb/ActionBreadcrumb.js +8 -8
  82. package/lib/Breadcrumb/Breadcrumb.js +9 -9
  83. package/lib/Breadcrumb/BreadcrumbItem.js +8 -8
  84. package/lib/Breadcrumb/HeaderBreadcrumb.js +7 -7
  85. package/lib/Breadcrumb/HomeBreadcrumb.js +10 -10
  86. package/lib/Breadcrumb/index.js +7 -7
  87. package/lib/CampaignBlock/CampaignBlock.js +7 -7
  88. package/lib/CampaignBlock/index.js +2 -2
  89. package/lib/CompetenceGoalTab/CompetenceGoalItem.js +10 -10
  90. package/lib/CompetenceGoalTab/CompetenceGoalTab.js +11 -11
  91. package/lib/CompetenceGoalTab/CompetenceItem.js +10 -10
  92. package/lib/CompetenceGoalTab/index.js +4 -4
  93. package/lib/ContactBlock/ContactBlock.js +15 -15
  94. package/lib/ContactBlock/index.js +4 -4
  95. package/lib/ContentLoader/index.js +3 -3
  96. package/lib/ContentPlaceholder/ContentPlaceholder.js +6 -6
  97. package/lib/ContentPlaceholder/index.js +4 -4
  98. package/lib/ContentTypeBadge/ContentTypeBadge.js +3 -3
  99. package/lib/ContentTypeBadge/index.js +2 -2
  100. package/lib/CopyParagraphButton/CopyParagraphButton.js +8 -8
  101. package/lib/CopyParagraphButton/CopyParagraphButtonV2.js +7 -7
  102. package/lib/CopyParagraphButton/index.js +7 -7
  103. package/lib/CopyParagraphButton/initCopyParagraphButtons.js +4 -4
  104. package/lib/CreatedBy/CreatedBy.js +8 -8
  105. package/lib/CreatedBy/index.js +4 -4
  106. package/lib/DefinitionList/DefinitionDescription.js +4 -4
  107. package/lib/DefinitionList/DefinitionTerm.js +4 -4
  108. package/lib/DefinitionList/index.js +3 -3
  109. package/lib/Dialog/Dialog.js +2 -2
  110. package/lib/Dialog/index.js +2 -2
  111. package/lib/Embed/AudioEmbed.js +6 -6
  112. package/lib/Embed/BrightcoveEmbed.js +8 -8
  113. package/lib/Embed/ConceptEmbed.js +14 -14
  114. package/lib/Embed/ConceptListEmbed.js +5 -5
  115. package/lib/Embed/ContentLinkEmbed.js +4 -4
  116. package/lib/Embed/EmbedErrorPlaceholder.js +5 -5
  117. package/lib/Embed/ExternalEmbed.js +5 -5
  118. package/lib/Embed/FootnoteEmbed.js +2 -2
  119. package/lib/Embed/H5pEmbed.js +5 -5
  120. package/lib/Embed/IframeEmbed.js +2 -2
  121. package/lib/Embed/ImageEmbed.js +7 -7
  122. package/lib/Embed/RelatedContentEmbed.js +2 -2
  123. package/lib/Embed/UnknownEmbed.js +4 -4
  124. package/lib/Embed/conceptComponents.js +9 -9
  125. package/lib/Embed/index.js +13 -13
  126. package/lib/ErrorMessage/ErrorMessage.js +10 -10
  127. package/lib/ErrorMessage/ErrorResourceAccessDenied.js +5 -5
  128. package/lib/ErrorMessage/index.js +5 -5
  129. package/lib/FactBox/FactBox.js +4 -4
  130. package/lib/FactBox/FactBoxV2.js +9 -9
  131. package/lib/FactBox/index.js +5 -5
  132. package/lib/Figure/Figure.js +5 -5
  133. package/lib/Figure/FigureBylineExpandButton.js +1 -1
  134. package/lib/Figure/FigureExpandButton.js +1 -1
  135. package/lib/Figure/FigureLicense.js +2 -2
  136. package/lib/Figure/FigureLicenseDialog.js +2 -2
  137. package/lib/Figure/FigureOpenDialogButton.js +1 -1
  138. package/lib/Figure/index.js +2 -2
  139. package/lib/FileList/File.js +7 -7
  140. package/lib/FileList/FileList.js +7 -7
  141. package/lib/FileList/FileListV2.js +6 -6
  142. package/lib/FileList/FileV2.js +4 -4
  143. package/lib/FileList/PdfFile.js +2 -2
  144. package/lib/FileList/index.js +8 -8
  145. package/lib/Filter/FilterButtons.js +16 -16
  146. package/lib/Filter/FilterCarousel.js +8 -8
  147. package/lib/Filter/FilterList.js +6 -6
  148. package/lib/Filter/FilterListPhone.js +9 -9
  149. package/lib/Filter/ToggleItem.js +3 -3
  150. package/lib/Filter/filterClasses.js +2 -2
  151. package/lib/Filter/index.js +5 -5
  152. package/lib/Footer/EditorName.js +1 -1
  153. package/lib/Footer/Footer.js +13 -13
  154. package/lib/Footer/FooterLinks.js +9 -9
  155. package/lib/Footer/FooterPrivacy.js +6 -6
  156. package/lib/Footer/FooterText.js +2 -2
  157. package/lib/Footer/index.js +2 -2
  158. package/lib/Frontpage/FrontpageAllSubjects.js +14 -14
  159. package/lib/Frontpage/FrontpageFilm.js +8 -8
  160. package/lib/Frontpage/FrontpageHeader.js +9 -9
  161. package/lib/Frontpage/FrontpageInfo.js +4 -4
  162. package/lib/Frontpage/FrontpageMultidisciplinarySubject.js +13 -13
  163. package/lib/Frontpage/FrontpageProgramMenu.js +10 -10
  164. package/lib/Frontpage/FrontpageSearch.js +7 -7
  165. package/lib/Frontpage/FrontpageToolbox.js +8 -8
  166. package/lib/Frontpage/illustrations/Fellesfag.js +3 -3
  167. package/lib/Frontpage/illustrations/FrontpageHeaderIllustration.js +3 -3
  168. package/lib/Frontpage/illustrations/FrontpageIllustrations.js +3 -3
  169. package/lib/Frontpage/illustrations/FrontpageSubjectIllustration.js +3 -3
  170. package/lib/Frontpage/illustrations/MenuFellesfag.js +3 -3
  171. package/lib/Frontpage/illustrations/MenuStudiespesialiserende.js +3 -3
  172. package/lib/Frontpage/illustrations/MenuYrkesfag.js +3 -3
  173. package/lib/Frontpage/illustrations/Studiespesialiserende.js +3 -3
  174. package/lib/Frontpage/illustrations/Yrkesfag.js +3 -3
  175. package/lib/Frontpage/illustrations/index.js +14 -14
  176. package/lib/Frontpage/index.js +9 -9
  177. package/lib/Grid/Grid.d.ts +3 -2
  178. package/lib/Grid/Grid.js +21 -16
  179. package/lib/Grid/index.js +2 -2
  180. package/lib/Hero/Hero.js +3 -3
  181. package/lib/Image/Image.js +5 -5
  182. package/lib/Image/ImageLink.js +2 -2
  183. package/lib/Image/LazyLoadImage.js +3 -3
  184. package/lib/Image/index.js +4 -4
  185. package/lib/InfoBlock/InfoBlock.js +8 -8
  186. package/lib/InfoBox/InfoBox.js +4 -4
  187. package/lib/InfoBox/index.js +2 -2
  188. package/lib/InfoWidget/InfoWidget.js +12 -12
  189. package/lib/InfoWidget/index.js +4 -4
  190. package/lib/KeyFigure/KeyFigure.js +17 -17
  191. package/lib/KeyFigure/index.js +2 -2
  192. package/lib/LanguageSelector/LanguageSelector.js +8 -8
  193. package/lib/LanguageSelector/index.js +2 -2
  194. package/lib/Layout/Content.js +3 -3
  195. package/lib/Layout/LayoutItem.js +3 -3
  196. package/lib/Layout/OneColumn.js +4 -4
  197. package/lib/Layout/PageContainer.js +4 -4
  198. package/lib/Layout/index.js +7 -7
  199. package/lib/LearningPaths/LearningPathContent.js +2 -2
  200. package/lib/LearningPaths/LearningPathInformation.js +4 -4
  201. package/lib/LearningPaths/LearningPathLastStepNavigation.js +8 -8
  202. package/lib/LearningPaths/LearningPathMenu.js +12 -12
  203. package/lib/LearningPaths/LearningPathMenuAside.js +5 -5
  204. package/lib/LearningPaths/LearningPathMenuAsideCopyright.js +5 -5
  205. package/lib/LearningPaths/LearningPathMenuContent.js +11 -11
  206. package/lib/LearningPaths/LearningPathMenuIntro.js +7 -7
  207. package/lib/LearningPaths/LearningPathMenuModalWrapper.js +4 -4
  208. package/lib/LearningPaths/LearningPathMobileHeader.js +5 -5
  209. package/lib/LearningPaths/LearningPathMobileStepInfo.js +4 -4
  210. package/lib/LearningPaths/LearningPathSticky.js +4 -4
  211. package/lib/LearningPaths/LearningPathWrapper.js +2 -2
  212. package/lib/LearningPaths/index.js +5 -5
  213. package/lib/LetterFilter/LetterFilter.js +6 -6
  214. package/lib/LetterFilter/index.js +4 -4
  215. package/lib/LicenseByline/EmbedByline.js +14 -22
  216. package/lib/LicenseByline/LicenseDescription.js +5 -5
  217. package/lib/LicenseByline/LicenseLink.js +7 -7
  218. package/lib/LicenseByline/index.js +2 -2
  219. package/lib/List/OrderedList.js +4 -4
  220. package/lib/List/UnOrderedList.js +4 -4
  221. package/lib/List/index.js +3 -3
  222. package/lib/Logo/Logo.js +7 -7
  223. package/lib/Logo/SvgLogo.js +3 -3
  224. package/lib/Logo/index.js +4 -4
  225. package/lib/Masthead/Masthead.js +8 -8
  226. package/lib/Masthead/MastheadSearchModal.js +8 -8
  227. package/lib/Masthead/SkipToMainContent.js +4 -4
  228. package/lib/Masthead/index.js +6 -6
  229. package/lib/Masthead/utils.js +1 -1
  230. package/lib/MediaList/MediaList.js +3 -3
  231. package/lib/Messages/MessageBanner.js +6 -6
  232. package/lib/Messages/MessageBox.js +10 -10
  233. package/lib/Messages/MessageBoxTag.js +4 -4
  234. package/lib/Messages/index.js +4 -4
  235. package/lib/MultidisciplinarySubject/List.js +7 -7
  236. package/lib/MultidisciplinarySubject/ListItem.js +11 -11
  237. package/lib/MultidisciplinarySubject/MultidisciplinarySubject.js +13 -13
  238. package/lib/MultidisciplinarySubject/index.d.ts +0 -2
  239. package/lib/MultidisciplinarySubject/index.js +4 -11
  240. package/lib/MyNdla/Resource/Folder.js +11 -11
  241. package/lib/MyNdla/Resource/FolderInput.js +6 -6
  242. package/lib/MyNdla/Resource/FolderMenu.js +9 -9
  243. package/lib/MyNdla/Resource/index.js +3 -3
  244. package/lib/MyNdla/SettingsMenu.js +7 -7
  245. package/lib/MyNdla/index.js +5 -5
  246. package/lib/NDLAFilm/AboutNdlaFilm.js +5 -5
  247. package/lib/NDLAFilm/AllMoviesAlphabetically.js +16 -16
  248. package/lib/NDLAFilm/CategorySelect.js +9 -9
  249. package/lib/NDLAFilm/FilmContentCard.js +7 -7
  250. package/lib/NDLAFilm/FilmContentCardTags.js +5 -5
  251. package/lib/NDLAFilm/FilmMovieList.js +5 -5
  252. package/lib/NDLAFilm/FilmMovieSearch.js +8 -8
  253. package/lib/NDLAFilm/FilmSlideshow.js +12 -12
  254. package/lib/NDLAFilm/MovieGrid.js +6 -6
  255. package/lib/NDLAFilm/NavigationArrow.js +5 -5
  256. package/lib/NDLAFilm/SlideshowIndicator.js +5 -5
  257. package/lib/NDLAFilm/VisualElement.js +5 -5
  258. package/lib/NDLAFilm/filmStyles.js +2 -2
  259. package/lib/NDLAFilm/index.js +7 -7
  260. package/lib/Navigation/NavigationBox.js +17 -17
  261. package/lib/Navigation/NavigationTopicAbout.js +13 -13
  262. package/lib/Navigation/index.js +3 -3
  263. package/lib/NoContentBox/NoContentBox.js +3 -3
  264. package/lib/NoContentBox/index.js +4 -4
  265. package/lib/Notion/ConceptNotion.js +10 -10
  266. package/lib/Notion/FigureNotion.js +4 -4
  267. package/lib/Notion/Notion.js +8 -8
  268. package/lib/Notion/NotionImage.js +3 -3
  269. package/lib/Notion/NotionVisualElement.js +5 -5
  270. package/lib/Notion/index.js +4 -4
  271. package/lib/Programme/Programme.js +12 -12
  272. package/lib/Programme/ProgrammeSubjects.js +5 -5
  273. package/lib/Programme/index.js +5 -5
  274. package/lib/ProgrammeCard/ProgrammeCard.js +7 -7
  275. package/lib/ProgrammeCard/index.js +2 -2
  276. package/lib/RadioButtonGroup/RadioButtonGroup.js +17 -19
  277. package/lib/RadioButtonGroup/index.js +4 -4
  278. package/lib/RelatedArticleList/RelatedArticleList.js +7 -7
  279. package/lib/RelatedArticleList/RelatedArticleV2.js +7 -7
  280. package/lib/RelatedArticleList/index.js +4 -4
  281. package/lib/Resource/BlockResource.js +13 -13
  282. package/lib/Resource/ListResource.js +13 -13
  283. package/lib/Resource/index.js +3 -3
  284. package/lib/Resource/resourceComponents.js +12 -12
  285. package/lib/ResourceBox/ResourceBox.js +9 -9
  286. package/lib/ResourceBox/index.js +2 -2
  287. package/lib/ResourceGroup/ResourceGroup.js +5 -5
  288. package/lib/ResourceGroup/ResourceItem.js +17 -17
  289. package/lib/ResourceGroup/ResourceList.js +6 -6
  290. package/lib/ResourceGroup/index.js +4 -4
  291. package/lib/ResourcesWrapper/ResourcesTopicTitle.js +11 -11
  292. package/lib/ResourcesWrapper/ResourcesWrapper.js +4 -4
  293. package/lib/ResourcesWrapper/index.js +5 -5
  294. package/lib/Search/ActiveFilterContent.js +6 -6
  295. package/lib/Search/ActiveFilters.js +9 -9
  296. package/lib/Search/ContentTypeResult.js +9 -9
  297. package/lib/Search/ContentTypeResultStyles.js +7 -7
  298. package/lib/Search/LoadingWrapper.js +4 -4
  299. package/lib/Search/SearchField.js +7 -7
  300. package/lib/Search/SearchFieldForm.js +2 -2
  301. package/lib/Search/SearchResult.js +15 -15
  302. package/lib/Search/SearchResultSleeve.js +14 -14
  303. package/lib/Search/ToggleSearchButton.js +5 -5
  304. package/lib/Search/index.js +4 -4
  305. package/lib/SearchTypeResult/ActiveFilterContent.js +6 -6
  306. package/lib/SearchTypeResult/ActiveFilters.js +10 -10
  307. package/lib/SearchTypeResult/PopupFilter.js +12 -12
  308. package/lib/SearchTypeResult/ResultNavigation.js +7 -7
  309. package/lib/SearchTypeResult/SearchFieldHeader.js +10 -10
  310. package/lib/SearchTypeResult/SearchFilterContent.js +6 -6
  311. package/lib/SearchTypeResult/SearchHeader.js +16 -16
  312. package/lib/SearchTypeResult/SearchItem.js +16 -16
  313. package/lib/SearchTypeResult/SearchItemList.js +19 -19
  314. package/lib/SearchTypeResult/SearchItems.js +7 -7
  315. package/lib/SearchTypeResult/SearchNotionsResult.js +7 -7
  316. package/lib/SearchTypeResult/SearchSubjectItem.js +7 -7
  317. package/lib/SearchTypeResult/SearchSubjectResult.js +5 -5
  318. package/lib/SearchTypeResult/SearchTypeHeader.js +14 -14
  319. package/lib/SearchTypeResult/SearchTypeResult.js +9 -9
  320. package/lib/SearchTypeResult/SearchViewType.js +7 -7
  321. package/lib/SearchTypeResult/components/ItemContexts.js +10 -10
  322. package/lib/SearchTypeResult/components/ItemResourceHeader.js +14 -14
  323. package/lib/SearchTypeResult/components/ItemTopicHeader.js +8 -8
  324. package/lib/SearchTypeResult/components/SubjectFilters.js +8 -8
  325. package/lib/SearchTypeResult/index.js +7 -7
  326. package/lib/SectionHeading/SectionHeading.js +3 -3
  327. package/lib/SectionHeading/index.js +4 -4
  328. package/lib/SnackBar/DefaultSnackbar.js +5 -5
  329. package/lib/SnackBar/SnackbarProvider.js +8 -8
  330. package/lib/SnackBar/index.js +2 -2
  331. package/lib/Subject/Subject.js +10 -10
  332. package/lib/Subject/SubjectBanner.js +4 -4
  333. package/lib/Subject/SubjectHeader.js +7 -7
  334. package/lib/Subject/SubjectNewContent.js +12 -12
  335. package/lib/Subject/SubjectSocial.js +3 -3
  336. package/lib/Subject/index.js +4 -4
  337. package/lib/Table/Table.js +10 -10
  338. package/lib/Table/index.js +4 -4
  339. package/lib/TagSelector/Control.js +4 -4
  340. package/lib/TagSelector/DropdownIndicator.js +5 -5
  341. package/lib/TagSelector/Input.js +3 -3
  342. package/lib/TagSelector/Menu.js +3 -3
  343. package/lib/TagSelector/MenuList.js +4 -4
  344. package/lib/TagSelector/Option.js +5 -5
  345. package/lib/TagSelector/SelectContainer.js +4 -4
  346. package/lib/TagSelector/TagSelector.js +16 -16
  347. package/lib/TagSelector/ValueButton.js +4 -4
  348. package/lib/TagSelector/index.js +2 -2
  349. package/lib/ToolboxPage/ToolboxInfo.js +4 -4
  350. package/lib/ToolboxPage/index.js +2 -2
  351. package/lib/Topic/Loader.js +4 -4
  352. package/lib/Topic/Topic.js +19 -19
  353. package/lib/Topic/index.js +4 -4
  354. package/lib/Translation/Translation.js +4 -4
  355. package/lib/Translation/TranslationLine.js +4 -4
  356. package/lib/Translation/index.js +3 -3
  357. package/lib/TreeStructure/AddFolderButton.js +7 -7
  358. package/lib/TreeStructure/ComboboxButton.js +7 -7
  359. package/lib/TreeStructure/FolderItem.js +12 -12
  360. package/lib/TreeStructure/FolderItems.js +6 -6
  361. package/lib/TreeStructure/TreeStructure.js +17 -17
  362. package/lib/TreeStructure/index.js +2 -2
  363. package/lib/Typography/Heading.js +2 -2
  364. package/lib/Typography/index.js +2 -2
  365. package/lib/User/UserInfo.js +4 -4
  366. package/lib/User/parseUserObject.js +3 -3
  367. package/lib/all.css +1 -1
  368. package/lib/i18n/i18n.js +7 -7
  369. package/lib/index.d.ts +1 -7
  370. package/lib/index.js +43 -84
  371. package/lib/locale/LocaleProvider.js +3 -3
  372. package/lib/locale/messages-en.js +11 -11
  373. package/lib/locale/messages-nb.js +11 -11
  374. package/lib/locale/messages-nn.js +11 -11
  375. package/lib/locale/messages-se.js +11 -11
  376. package/lib/locale/messages-sma.js +11 -11
  377. package/lib/model/index.js +3 -3
  378. package/lib/utils/createUniversalPortal.js +2 -2
  379. package/lib/utils/resourceTypeColor.js +4 -4
  380. package/package.json +14 -15
  381. package/src/Animation/index.ts +0 -2
  382. package/src/BlogPost/BlogPost.stories.tsx +1 -1
  383. package/src/BlogPost/BlogPost.tsx +1 -2
  384. package/src/CampaignBlock/CampaignBlock.stories.tsx +1 -1
  385. package/src/ContactBlock/Contactblock.stories.tsx +1 -1
  386. package/src/Embed/AudioEmbed.stories.tsx +1 -1
  387. package/src/Embed/BrightcoveEmbed.stories.tsx +1 -1
  388. package/src/Embed/ConceptEmbed.stories.tsx +1 -1
  389. package/src/Embed/ExternalEmbed.stories.tsx +1 -1
  390. package/src/Embed/H5pEmbed.stories.tsx +1 -1
  391. package/src/Embed/IframeEmbed.stories.tsx +1 -1
  392. package/src/Embed/ImageEmbed.stories.tsx +1 -1
  393. package/src/Grid/Grid.stories.tsx +6 -4
  394. package/src/Grid/Grid.tsx +52 -17
  395. package/src/KeyFigure/KeyFigure.stories.tsx +1 -1
  396. package/src/KeyFigure/KeyFigure.tsx +2 -3
  397. package/src/LanguageSelector/LanguageSelector.stories.tsx +1 -1
  398. package/src/LearningPaths/LearningPathMenu.stories.tsx +1 -1
  399. package/src/LetterFilter/LetterFilter.stories.tsx +1 -1
  400. package/src/LicenseByline/EmbedByline.stories.tsx +1 -1
  401. package/src/LicenseByline/EmbedByline.tsx +1 -0
  402. package/src/LicenseByline/LicenseLink.tsx +1 -0
  403. package/src/MultidisciplinarySubject/index.ts +0 -2
  404. package/src/MyNdla/Resource/Folder.stories.tsx +1 -1
  405. package/src/ProgrammeCard/ProgrammeCard.stories.tsx +1 -1
  406. package/src/Resource/BlockResource.stories.tsx +1 -1
  407. package/src/Resource/Resource.stories.tsx +1 -1
  408. package/src/Search/component.search-field.scss +0 -14
  409. package/src/index.ts +1 -11
  410. package/es/Animation/DisplayOnPageYOffset.js +0 -86
  411. package/es/AuthorInfo/AuthorInfo.js +0 -63
  412. package/es/AuthorInfo/index.js +0 -2
  413. package/es/Breadcrumblist/Breadcrumblist.js +0 -225
  414. package/es/Breadcrumblist/index.js +0 -2
  415. package/es/ContentCard/ContentCard.js +0 -95
  416. package/es/ContentCard/index.js +0 -2
  417. package/es/MultidisciplinarySubject/Illustrations.js +0 -76
  418. package/es/MultidisciplinarySubject/MultidisciplinarySubjectHeader.js +0 -112
  419. package/es/Portrait/Portrait.js +0 -42
  420. package/es/Portrait/index.js +0 -10
  421. package/lib/Animation/DisplayOnPageYOffset.d.ts +0 -27
  422. package/lib/Animation/DisplayOnPageYOffset.js +0 -93
  423. package/lib/AuthorInfo/AuthorInfo.d.ts +0 -16
  424. package/lib/AuthorInfo/AuthorInfo.js +0 -70
  425. package/lib/AuthorInfo/index.d.ts +0 -2
  426. package/lib/AuthorInfo/index.js +0 -10
  427. package/lib/Breadcrumblist/Breadcrumblist.d.ts +0 -29
  428. package/lib/Breadcrumblist/Breadcrumblist.js +0 -232
  429. package/lib/Breadcrumblist/index.d.ts +0 -3
  430. package/lib/Breadcrumblist/index.js +0 -10
  431. package/lib/ContentCard/ContentCard.d.ts +0 -12
  432. package/lib/ContentCard/ContentCard.js +0 -102
  433. package/lib/ContentCard/index.d.ts +0 -2
  434. package/lib/ContentCard/index.js +0 -10
  435. package/lib/MultidisciplinarySubject/Illustrations.d.ts +0 -29
  436. package/lib/MultidisciplinarySubject/Illustrations.js +0 -90
  437. package/lib/MultidisciplinarySubject/MultidisciplinarySubjectHeader.d.ts +0 -13
  438. package/lib/MultidisciplinarySubject/MultidisciplinarySubjectHeader.js +0 -118
  439. package/lib/Portrait/Portrait.d.ts +0 -15
  440. package/lib/Portrait/Portrait.js +0 -50
  441. package/lib/Portrait/index.d.ts +0 -9
  442. package/lib/Portrait/index.js +0 -17
  443. package/src/Animation/DisplayOnPageYOffset.tsx +0 -66
  444. package/src/AuthorInfo/AuthorInfo.tsx +0 -82
  445. package/src/AuthorInfo/index.ts +0 -3
  446. package/src/Breadcrumblist/Breadcrumblist.tsx +0 -320
  447. package/src/Breadcrumblist/index.ts +0 -4
  448. package/src/ContentCard/ContentCard.tsx +0 -152
  449. package/src/ContentCard/index.ts +0 -3
  450. package/src/MultidisciplinarySubject/Illustrations.tsx +0 -148
  451. package/src/MultidisciplinarySubject/MultidisciplinarySubjectHeader.tsx +0 -125
  452. package/src/Portrait/Portrait.tsx +0 -45
  453. package/src/Portrait/index.ts +0 -11
package/src/Grid/Grid.tsx CHANGED
@@ -11,39 +11,63 @@ import { breakpoints, colors, misc, mq, spacing } from '@ndla/core';
11
11
  import { ReactNode } from 'react';
12
12
 
13
13
  export interface GridProps {
14
- columns: 2 | 4;
14
+ columns: '2' | '4' | '2x2';
15
15
  border?: 'none' | 'lightBlue';
16
16
  background?: 'transparent' | 'white';
17
+ size?: boolean;
17
18
  children?: ReactNode[];
18
19
  }
19
20
 
20
21
  const GridContainer = styled.div`
21
22
  display: grid;
22
- grid-template-columns: auto;
23
23
  justify-content: center;
24
- grid-gap: ${spacing.large};
25
-
26
- padding: ${spacing.xsmall};
27
24
  border-radius: ${misc.borderRadius};
25
+ grid-template-columns: 1fr;
26
+ grid-gap: ${spacing.normal};
28
27
 
29
- &[data-border='lightBlue'] {
30
- border: 1px solid ${colors.brand.light};
31
- }
32
-
33
- &[data-background='white'] {
34
- background-color: ${colors.white};
28
+ ${mq.range({ until: breakpoints.tabletWide })} {
29
+ &[data-columns='2x2'],
30
+ &[data-columns='3'],
31
+ &[data-columns='4'] {
32
+ padding: ${spacing.normal};
33
+ grid-template-columns: repeat(2, minmax(0, 1fr));
34
+ }
35
35
  }
36
36
 
37
- ${mq.range({ from: breakpoints.mobileWide })} {
38
- grid-template-columns: repeat(2, 1fr);
37
+ ${mq.range({ until: breakpoints.desktop })} {
38
+ > div:nth-child(3):last-child {
39
+ display: flex;
40
+ flex-flow: column;
41
+ justify-content: center;
42
+ align-items: center;
43
+ grid-column: span 2;
44
+ }
39
45
  }
40
46
 
41
47
  ${mq.range({ from: breakpoints.tabletWide })} {
48
+ grid-template-columns: repeat(2, minmax(0, 1fr));
49
+ padding: ${spacing.medium};
50
+
51
+ &[data-columns='3'] {
52
+ grid-template-columns: repeat(3, minmax(0, 1fr));
53
+ }
54
+
42
55
  &[data-columns='4'] {
43
- grid-template-columns: repeat(4, 1fr);
56
+ grid-template-columns: repeat(4, minmax(0, 1fr));
44
57
  }
45
58
  }
46
59
 
60
+ &[data-frontpage='true'] {
61
+ grid-gap: ${spacing.large};
62
+ }
63
+
64
+ &[data-border='lightBlue'] {
65
+ border: 1px solid ${colors.brand.light};
66
+ }
67
+ &[data-background='white'] {
68
+ background-color: ${colors.white};
69
+ }
70
+
47
71
  p {
48
72
  word-break: break-word;
49
73
  }
@@ -60,14 +84,25 @@ const GridContainer = styled.div`
60
84
  const OuterContainer = styled.div`
61
85
  display: flex;
62
86
  width: 100%;
63
- justify-content: center;
64
87
  align-items: center;
88
+
89
+ &[data-columns='2x2'] {
90
+ justify-content: center;
91
+ }
65
92
  `;
66
93
 
67
- const Grid = ({ columns, border, children, background, ...rest }: GridProps) => {
94
+ const Grid = ({ columns, border, children, background, size, ...rest }: GridProps) => {
95
+ const amountOfColumns = children?.length === 3 ? '3' : columns;
96
+
68
97
  return (
69
98
  <OuterContainer>
70
- <GridContainer data-border={border} data-columns={columns} data-background={background} {...rest}>
99
+ <GridContainer
100
+ data-frontpage={size}
101
+ data-border={border}
102
+ data-columns={amountOfColumns}
103
+ data-background={background}
104
+ {...rest}
105
+ >
71
106
  {children}
72
107
  </GridContainer>
73
108
  </OuterContainer>
@@ -20,7 +20,7 @@ const args = {
20
20
  };
21
21
 
22
22
  export default {
23
- title: 'Enkle komponenter/Nøkkeltall',
23
+ title: 'Components/Nøkkeltall',
24
24
  component: KeyFigure,
25
25
  tags: ['autodocs'],
26
26
  parameters: {
@@ -16,10 +16,11 @@ const ContentWrapper = styled.div`
16
16
  align-items: center;
17
17
  padding: ${spacing.small};
18
18
  align-items: center;
19
+ max-width: 215px;
19
20
  `;
20
21
 
21
22
  const StyledImage = styled.img`
22
- max-width: 150px;
23
+ width: 100%;
23
24
  `;
24
25
 
25
26
  const TitleWrapper = styled.div`
@@ -29,7 +30,6 @@ const TitleWrapper = styled.div`
29
30
  overflow-wrap: break-word;
30
31
  ${fonts.sizes('38px', '48px')};
31
32
  text-align: center;
32
- max-width: 240px;
33
33
 
34
34
  ${mq.range({ until: breakpoints.tabletWide })} {
35
35
  ${fonts.sizes('30px', '36px')};
@@ -43,7 +43,6 @@ const SubTitleWrapper = styled.div`
43
43
  color: ${colors.text.primary};
44
44
  font-weight: ${fonts.weight.normal};
45
45
  font-family: ${fonts.sans};
46
- max-width: 240px;
47
46
 
48
47
  ${mq.range({ until: breakpoints.tabletWide })} {
49
48
  padding-top: ${spacing.xxsmall};
@@ -13,7 +13,7 @@ import styled from '@emotion/styled';
13
13
  import { colors, spacing } from '@ndla/core';
14
14
  import { defaultParameters } from '../../../../stories/defaults';
15
15
  export default {
16
- title: 'Enkle komponenter/LanguageSelector',
16
+ title: 'Components/LanguageSelector',
17
17
  tags: ['autodocs'],
18
18
  component: LanguageSelector,
19
19
  parameters: {
@@ -50,7 +50,7 @@ const args = {
50
50
  };
51
51
 
52
52
  export default {
53
- title: 'Sammensatte moduler/Læringssti-meny',
53
+ title: 'Patterns/Læringssti-meny',
54
54
  component: LearningPathMenu,
55
55
  tags: ['autodocs'],
56
56
  parameters: {
@@ -13,7 +13,7 @@ import { defaultParameters } from '../../../../stories/defaults';
13
13
  import LetterFilter from './LetterFilter';
14
14
 
15
15
  export default {
16
- title: 'Enkle komponenter/LetterFilter',
16
+ title: 'Components/LetterFilter',
17
17
  component: LetterFilter,
18
18
  tags: ['autodocs'],
19
19
  parameters: {
@@ -28,7 +28,7 @@ const ButtonWrapper = styled.div`
28
28
  `;
29
29
 
30
30
  export default {
31
- title: 'Enkle komponenter/EmbedByline',
31
+ title: 'Components/EmbedByline',
32
32
  component: EmbedByline,
33
33
  tags: ['autodocs'],
34
34
  parameters: {
@@ -114,6 +114,7 @@ const StyledSpan = styled.span`
114
114
 
115
115
  const LicenseInformationWrapper = styled.div`
116
116
  flex: 1;
117
+ padding-right: ${spacing.xsmall}}
117
118
  `;
118
119
 
119
120
  const EmbedByline = ({
@@ -20,6 +20,7 @@ const StyledSafeLink = styled(SafeLink)`
20
20
  color: ${colors.brand.primary};
21
21
  font-weight: ${fonts.weight.bold};
22
22
  text-decoration: underline;
23
+ white-space: nowrap;
23
24
  box-shadow: none;
24
25
  &:hover,
25
26
  &:focus-within {
@@ -7,7 +7,5 @@
7
7
  */
8
8
 
9
9
  import MultidisciplinarySubject from './MultidisciplinarySubject';
10
- import MultidisciplinarySubjectHeader from './MultidisciplinarySubjectHeader';
11
10
 
12
- export { MultidisciplinarySubjectHeader };
13
11
  export default MultidisciplinarySubject;
@@ -7,7 +7,7 @@ import { defaultParameters } from '../../../../../stories/defaults';
7
7
  import Folder from './Folder';
8
8
 
9
9
  export default {
10
- title: 'Enkle komponenter/Mappe',
10
+ title: 'Components/Mappe',
11
11
  component: Folder,
12
12
  tags: ['autodocs'],
13
13
  parameters: {
@@ -12,7 +12,7 @@ import ProgrammeCard from './ProgrammeCard';
12
12
  import { defaultParameters } from '../../../../stories/defaults';
13
13
 
14
14
  export default {
15
- title: 'Enkle komponenter/ProgrammeCard',
15
+ title: 'Components/ProgrammeCard',
16
16
  component: ProgrammeCard,
17
17
  tags: ['autodocs'],
18
18
  parameters: {
@@ -12,7 +12,7 @@ import { defaultParameters } from '../../../../stories/defaults';
12
12
  import BlockResource from './BlockResource';
13
13
 
14
14
  export default {
15
- title: 'Enkle komponenter/Ressurser/BlockResource',
15
+ title: 'Components/Ressurser/BlockResource',
16
16
  component: BlockResource,
17
17
  tags: ['autodocs'],
18
18
  parameters: {
@@ -12,7 +12,7 @@ import { defaultParameters } from '../../../../stories/defaults';
12
12
  import ListResource from './ListResource';
13
13
 
14
14
  export default {
15
- title: 'Enkle komponenter/Ressurser/ListResource',
15
+ title: 'Components/Ressurser/ListResource',
16
16
  component: ListResource,
17
17
  tags: ['autodocs'],
18
18
  parameters: {
@@ -103,20 +103,6 @@
103
103
  position: relative;
104
104
  padding: 0;
105
105
  }
106
-
107
- &--with-icon {
108
- &:after {
109
- content: '';
110
- display: block;
111
- position: absolute;
112
- @include svg_icon(search, $brand-grey);
113
- background-size: 24px 24px;
114
- background-position: center center;
115
- background-repeat: no-repeat;
116
- width: $spacing--large;
117
- height: 24px;
118
- }
119
- }
120
106
  }
121
107
 
122
108
  /** Header adjustments... */
package/src/index.ts CHANGED
@@ -48,8 +48,6 @@ export { default as NoContentBox } from './NoContentBox';
48
48
 
49
49
  export { default as Masthead, MastheadItem, getMastheadHeight, useMastheadHeight, SkipToMainContent } from './Masthead';
50
50
 
51
- export { default as Portrait } from './Portrait';
52
-
53
51
  export { default as ContentLoader } from './ContentLoader';
54
52
 
55
53
  export { default as RelatedArticleList, RelatedArticle, RelatedArticleListV2 } from './RelatedArticleList';
@@ -146,8 +144,6 @@ export { default as resourceTypeColor } from './utils/resourceTypeColor';
146
144
 
147
145
  export { default as CreatedBy } from './CreatedBy';
148
146
 
149
- export { default as Breadcrumblist } from './Breadcrumblist';
150
-
151
147
  export { MessageBox, MessageBoxTag, MessageBanner } from './Messages';
152
148
 
153
149
  export { ResourceBox } from './ResourceBox';
@@ -160,7 +156,7 @@ export { default as Programme } from './Programme';
160
156
 
161
157
  export { default as CompetenceGoalTab } from './CompetenceGoalTab';
162
158
 
163
- export { default as MultidisciplinarySubject, MultidisciplinarySubjectHeader } from './MultidisciplinarySubject';
159
+ export { default as MultidisciplinarySubject } from './MultidisciplinarySubject';
164
160
 
165
161
  export {
166
162
  SearchTypeResult,
@@ -185,12 +181,10 @@ export { ToolboxInfo } from './ToolboxPage';
185
181
  export { default as Topic } from './Topic';
186
182
  export type { TopicProps } from './Topic';
187
183
  export { default as Aside } from './Aside';
188
- export { default as AuthorInfo } from './AuthorInfo';
189
184
 
190
185
  export { default as Breadcrumb, HeaderBreadcrumb, HomeBreadcrumb, ActionBreadcrumb } from './Breadcrumb';
191
186
  export type { SimpleBreadcrumbItem, IndexedBreadcrumbItem } from './Breadcrumb';
192
187
 
193
- export type { BreadcrumbItemProps } from './Breadcrumblist';
194
188
  export { i18nInstance, formatNestedMessages } from './i18n';
195
189
  export { default as ResourceGroup } from './ResourceGroup';
196
190
 
@@ -205,8 +199,6 @@ export {
205
199
  AllMoviesAlphabetically,
206
200
  } from './NDLAFilm';
207
201
 
208
- export { DisplayOnPageYOffset } from './Animation';
209
-
210
202
  export {
211
203
  MediaList,
212
204
  MediaListItem,
@@ -242,8 +234,6 @@ export {
242
234
  SubjectBanner,
243
235
  } from './Subject';
244
236
 
245
- export { default as ContentCard } from './ContentCard';
246
-
247
237
  export { default as CopyParagraphButton, CopyParagraphButtonV2 } from './CopyParagraphButton';
248
238
 
249
239
  export { default as ContentPlaceholder } from './ContentPlaceholder';
@@ -1,86 +0,0 @@
1
- function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
2
- function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
3
- function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
4
- function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
5
- function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
6
- function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
7
- function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
8
- function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
9
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
10
- function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
11
- function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
12
- function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
13
- function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
14
- function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
15
- /**
16
- * Copyright (c) 2016-present, NDLA.
17
- *
18
- * This source code is licensed under the GPLv3 license found in the
19
- * LICENSE file in the root directory of this source tree.
20
- *
21
- */
22
-
23
- import React, { Component } from 'react';
24
- import throttle from 'lodash/throttle';
25
- import Fade from './Fade';
26
- import { jsx as _jsx } from "@emotion/react/jsx-runtime";
27
- var DisplayOnPageYOffset = /*#__PURE__*/function (_Component) {
28
- _inherits(DisplayOnPageYOffset, _Component);
29
- var _super = _createSuper(DisplayOnPageYOffset);
30
- function DisplayOnPageYOffset(props) {
31
- var _this;
32
- _classCallCheck(this, DisplayOnPageYOffset);
33
- _this = _super.call(this, props);
34
- _this.state = {
35
- show: props.yOffsetMin === 0
36
- };
37
- _this.handleScroll = throttle(_this.handleScroll.bind(_assertThisInitialized(_this)), 50);
38
- return _this;
39
- }
40
- _createClass(DisplayOnPageYOffset, [{
41
- key: "componentDidMount",
42
- value: function componentDidMount() {
43
- if (window) {
44
- window.addEventListener('scroll', this.handleScroll);
45
- this.handleScroll();
46
- }
47
- }
48
- }, {
49
- key: "componentWillUnmount",
50
- value: function componentWillUnmount() {
51
- if (window) {
52
- window.removeEventListener('scroll', this.handleScroll);
53
- }
54
- }
55
- }, {
56
- key: "handleScroll",
57
- value: function handleScroll() {
58
- var _this$props$yOffsetMa;
59
- if (window.pageYOffset >= this.props.yOffsetMin && (this.props.yOffsetMax === null || window.pageYOffset <= ((_this$props$yOffsetMa = this.props.yOffsetMax) !== null && _this$props$yOffsetMa !== void 0 ? _this$props$yOffsetMa : 0))) {
60
- if (!this.state.show) {
61
- this.setState({
62
- show: true
63
- });
64
- }
65
- } else if (this.state.show) {
66
- this.setState({
67
- show: false
68
- });
69
- }
70
- }
71
- }, {
72
- key: "render",
73
- value: function render() {
74
- var children = this.props.children;
75
- return _jsx(Fade, {
76
- show: this.state.show,
77
- children: children
78
- });
79
- }
80
- }]);
81
- return DisplayOnPageYOffset;
82
- }(Component);
83
- _defineProperty(DisplayOnPageYOffset, "defaultProps", {
84
- yOffsetMax: null
85
- });
86
- export { DisplayOnPageYOffset as default };
@@ -1,63 +0,0 @@
1
- import _styled from "@emotion/styled/base";
2
- /**
3
- * Copyright (c) 2018-present, NDLA.
4
- *
5
- * This source code is licensed under the GPLv3 license found in the
6
- * LICENSE file in the root directory of this source tree.
7
- *
8
- */
9
-
10
- import React from 'react';
11
- import SafeLink from '@ndla/safelink';
12
- import { breakpoints, fonts, mq, spacing } from '@ndla/core';
13
- import Portrait from '../Portrait';
14
- import { jsx as _jsx } from "@emotion/react/jsx-runtime";
15
- import { jsxs as _jsxs } from "@emotion/react/jsx-runtime";
16
- var AuthorInfoSection = /*#__PURE__*/_styled("section", {
17
- target: "e1gqd7zh2",
18
- label: "AuthorInfoSection"
19
- })("display:flex;align-items:flex-start;padding-bottom:", spacing.large, ";font-family:", fonts.sans, ";p,a{margin:0;", mq.range({
20
- until: breakpoints.tablet
21
- }), "{", fonts.sizes('14px', '22px'), ";}}" + (process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIkF1dGhvckluZm8udHN4Il0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQXNCd0MiLCJmaWxlIjoiQXV0aG9ySW5mby50c3giLCJzb3VyY2VzQ29udGVudCI6WyIvKipcb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vbmUgfTogUHJvcHMpID0+IChcbiAgPEF1dGhvckluZm9TZWN0aW9uPlxuICAgIHtpbWFnZSAmJiA8U3R5bGVkUG9ydHJhaXQgc3JjPXtpbWFnZX0gYWx0PXthdXRob3JOYW1lfSBtb2RpZmllcj1cImxhcmdlXCIgLz59XG4gICAgPGRpdj5cbiAgICAgIDxTdHlsZWRIZWFkaW5nPnthdXRob3JOYW1lfTwvU3R5bGVkSGVhZGluZz5cbiAgICAgIDxwPnthdXRob3JSb2xlfTwvcD5cbiAgICAgIHtwaG9uZSAmJiA8cD57cGhvbmV9PC9wPn1cbiAgICAgIHtlbWFpbCAmJiA8U2FmZUxpbmsgdG89e2BtYWlsdG86JHtlbWFpbH1gfT57ZW1haWx9PC9TYWZlTGluaz59XG4gICAgPC9kaXY+XG4gIDwvQXV0aG9ySW5mb1NlY3Rpb24+XG4pO1xuXG5leHBvcnQgZGVmYXVsdCBBdXRob3JJbmZvO1xuIl19 */"));
22
- var StyledPortrait = /*#__PURE__*/_styled(Portrait, {
23
- target: "e1gqd7zh1",
24
- label: "StyledPortrait"
25
- })("margin-right:", spacing.large, ";", mq.range({
26
- until: breakpoints.desktop
27
- }), "{margin-right:", spacing.medium, ";width:7rem;height:7rem;span{width:7rem;height:7rem;}}", mq.range({
28
- until: breakpoints.desktop
29
- }), "{margin-right:", spacing.small, ";width:4rem;height:4rem;span{width:4rem;height:4rem;}}" + (process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIkF1dGhvckluZm8udHN4Il0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQW9DdUMiLCJmaWxlIjoiQXV0aG9ySW5mby50c3giLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIENvcHlyaWdodCAoYykgMjAxOC1wcmVzZW50LCBORExBLlxuICpcbiAqIFRoaXMgc291cmNlIGNvZGUgaXMgbGljZW5zZWQgdW5kZXIg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tpbWFnZX0gYWx0PXthdXRob3JOYW1lfSBtb2RpZmllcj1cImxhcmdlXCIgLz59XG4gICAgPGRpdj5cbiAgICAgIDxTdHlsZWRIZWFkaW5nPnthdXRob3JOYW1lfTwvU3R5bGVkSGVhZGluZz5cbiAgICAgIDxwPnthdXRob3JSb2xlfTwvcD5cbiAgICAgIHtwaG9uZSAmJiA8cD57cGhvbmV9PC9wPn1cbiAgICAgIHtlbWFpbCAmJiA8U2FmZUxpbmsgdG89e2BtYWlsdG86JHtlbWFpbH1gfT57ZW1haWx9PC9TYWZlTGluaz59XG4gICAgPC9kaXY+XG4gIDwvQXV0aG9ySW5mb1NlY3Rpb24+XG4pO1xuXG5leHBvcnQgZGVmYXVsdCBBdXRob3JJbmZvO1xuIl19 */"));
30
- var StyledHeading = /*#__PURE__*/_styled("h1", {
31
- target: "e1gqd7zh0",
32
- label: "StyledHeading"
33
- })("margin:0 0 ", spacing.small, ";", mq.range({
34
- until: breakpoints.desktop
35
- }), "{", fonts.sizes('22px', '22px'), ";}", mq.range({
36
- until: breakpoints.tablet
37
- }), "{", fonts.sizes('18px', '18px'), ";margin-bottom:", spacing.xsmall, ";}" + (process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIkF1dGhvckluZm8udHN4Il0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQTBEK0IiLCJmaWxlIjoiQXV0aG9ySW5mby50c3giLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIENvcHlyaWdodCAoYykgMjAxOC1wcmVzZW50LCBORExBLlxuICpcbiAqIFRoaXMgc291cmNlIGNvZGUgaXMgbGljZW5zZWQgdW5kZXIgdGhlIEdQTHYzIGxpY2Vuc2UgZm91bmQgaW4gdGhlXG4gKiBMSUNFTlNFIGZpbGUgaW4gdGhlIHJvb3QgZGlyZWN0b3J5IG9mIHRoaXMgc291cmNlIHRyZWUuXG4gKl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kSGVhZGluZz5cbiAgICAgIDxwPnthdXRob3JSb2xlfTwvcD5cbiAgICAgIHtwaG9uZSAmJiA8cD57cGhvbmV9PC9wPn1cbiAgICAgIHtlbWFpbCAmJiA8U2FmZUxpbmsgdG89e2BtYWlsdG86JHtlbWFpbH1gfT57ZW1haWx9PC9TYWZlTGluaz59XG4gICAgPC9kaXY+XG4gIDwvQXV0aG9ySW5mb1NlY3Rpb24+XG4pO1xuXG5leHBvcnQgZGVmYXVsdCBBdXRob3JJbmZvO1xuIl19 */"));
38
- var AuthorInfo = function AuthorInfo(_ref) {
39
- var authorName = _ref.authorName,
40
- authorRole = _ref.authorRole,
41
- email = _ref.email,
42
- image = _ref.image,
43
- phone = _ref.phone;
44
- return _jsxs(AuthorInfoSection, {
45
- children: [image && _jsx(StyledPortrait, {
46
- src: image,
47
- alt: authorName,
48
- modifier: "large"
49
- }), _jsxs("div", {
50
- children: [_jsx(StyledHeading, {
51
- children: authorName
52
- }), _jsx("p", {
53
- children: authorRole
54
- }), phone && _jsx("p", {
55
- children: phone
56
- }), email && _jsx(SafeLink, {
57
- to: "mailto:".concat(email),
58
- children: email
59
- })]
60
- })]
61
- });
62
- };
63
- export default AuthorInfo;
@@ -1,2 +0,0 @@
1
- import AuthorInfo from './AuthorInfo';
2
- export default AuthorInfo;