@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.
- package/es/Animation/index.js +0 -1
- package/es/Article/Article.js +1 -1
- package/es/Article/ArticleByline.js +1 -1
- package/es/AudioPlayer/AudioPlayer.js +1 -1
- package/es/AudioPlayer/Controls.js +1 -1
- package/es/BlogPost/BlogPost.js +4 -4
- package/es/Breadcrumb/Breadcrumb.js +2 -2
- package/es/CompetenceGoalTab/CompetenceGoalTab.js +1 -1
- package/es/CopyParagraphButton/CopyParagraphButton.js +1 -1
- package/es/CopyParagraphButton/CopyParagraphButtonV2.js +1 -1
- package/es/Embed/BrightcoveEmbed.js +1 -1
- package/es/Embed/ConceptEmbed.js +1 -1
- package/es/Embed/ImageEmbed.js +1 -1
- package/es/FactBox/FactBoxV2.js +1 -1
- package/es/Filter/FilterButtons.js +1 -1
- package/es/Filter/FilterCarousel.js +1 -1
- package/es/Filter/FilterList.js +1 -1
- package/es/Filter/FilterListPhone.js +1 -1
- package/es/Frontpage/FrontpageProgramMenu.js +1 -1
- package/es/Grid/Grid.js +16 -11
- package/es/KeyFigure/KeyFigure.js +10 -10
- package/es/LearningPaths/LearningPathMenu.js +1 -1
- package/es/LicenseByline/EmbedByline.js +4 -12
- package/es/LicenseByline/LicenseLink.js +2 -2
- package/es/Masthead/MastheadSearchModal.js +1 -1
- package/es/Masthead/utils.js +1 -1
- package/es/MultidisciplinarySubject/index.js +0 -2
- package/es/NDLAFilm/AllMoviesAlphabetically.js +1 -1
- package/es/NDLAFilm/CategorySelect.js +1 -1
- package/es/NDLAFilm/FilmSlideshow.js +1 -1
- package/es/Navigation/NavigationBox.js +1 -1
- package/es/ProgrammeCard/ProgrammeCard.js +1 -1
- package/es/RadioButtonGroup/RadioButtonGroup.js +2 -4
- package/es/RelatedArticleList/RelatedArticleV2.js +1 -1
- package/es/Search/ContentTypeResult.js +1 -1
- package/es/Search/SearchResultSleeve.js +1 -1
- package/es/SearchTypeResult/PopupFilter.js +1 -1
- package/es/SearchTypeResult/SearchFieldHeader.js +1 -1
- package/es/SearchTypeResult/SearchHeader.js +1 -1
- package/es/SearchTypeResult/components/SubjectFilters.js +1 -1
- package/es/SnackBar/SnackbarProvider.js +1 -1
- package/es/Table/Table.js +1 -1
- package/es/TagSelector/TagSelector.js +1 -1
- package/es/TreeStructure/FolderItem.js +1 -1
- package/es/TreeStructure/TreeStructure.js +2 -2
- package/es/User/UserInfo.js +1 -1
- package/es/User/parseUserObject.js +1 -1
- package/es/all.css +1 -1
- package/es/index.js +1 -6
- package/es/locale/messages-en.js +5 -5
- package/es/locale/messages-nb.js +5 -5
- package/es/locale/messages-nn.js +5 -5
- package/es/locale/messages-se.js +5 -5
- package/es/locale/messages-sma.js +5 -5
- package/lib/Animation/Fade.js +4 -4
- package/lib/Animation/index.d.ts +0 -1
- package/lib/Animation/index.js +2 -9
- package/lib/Article/Article.js +19 -19
- package/lib/Article/ArticleAccessMessage.js +6 -6
- package/lib/Article/ArticleByline.js +12 -12
- package/lib/Article/ArticleContent.js +3 -3
- package/lib/Article/ArticleFootNotes.js +5 -5
- package/lib/Article/ArticleHeaderWrapper.js +5 -5
- package/lib/Article/ArticleNotions.js +8 -8
- package/lib/Article/ArticleSideBar.js +5 -5
- package/lib/Article/index.js +10 -10
- package/lib/Aside/Aside.js +4 -4
- package/lib/Aside/index.js +4 -4
- package/lib/AudioPlayer/AudioPlayer.js +22 -22
- package/lib/AudioPlayer/Controls.js +26 -26
- package/lib/AudioPlayer/SpeechControl.js +5 -5
- package/lib/AudioPlayer/index.js +5 -5
- package/lib/AudioPlayer/initAudioPlayers.js +6 -6
- package/lib/BannerCard/BannerCard.js +10 -10
- package/lib/BannerCard/index.js +2 -2
- package/lib/BlogPost/BlogPost.js +10 -10
- package/lib/BlogPost/index.js +2 -2
- package/lib/BlogPosts/BlogPost.js +7 -7
- package/lib/BlogPosts/BlogPostWrapper.js +4 -4
- package/lib/BlogPosts/index.js +3 -3
- package/lib/Breadcrumb/ActionBreadcrumb.js +8 -8
- package/lib/Breadcrumb/Breadcrumb.js +9 -9
- package/lib/Breadcrumb/BreadcrumbItem.js +8 -8
- package/lib/Breadcrumb/HeaderBreadcrumb.js +7 -7
- package/lib/Breadcrumb/HomeBreadcrumb.js +10 -10
- package/lib/Breadcrumb/index.js +7 -7
- package/lib/CampaignBlock/CampaignBlock.js +7 -7
- package/lib/CampaignBlock/index.js +2 -2
- package/lib/CompetenceGoalTab/CompetenceGoalItem.js +10 -10
- package/lib/CompetenceGoalTab/CompetenceGoalTab.js +11 -11
- package/lib/CompetenceGoalTab/CompetenceItem.js +10 -10
- package/lib/CompetenceGoalTab/index.js +4 -4
- package/lib/ContactBlock/ContactBlock.js +15 -15
- package/lib/ContactBlock/index.js +4 -4
- package/lib/ContentLoader/index.js +3 -3
- package/lib/ContentPlaceholder/ContentPlaceholder.js +6 -6
- package/lib/ContentPlaceholder/index.js +4 -4
- package/lib/ContentTypeBadge/ContentTypeBadge.js +3 -3
- package/lib/ContentTypeBadge/index.js +2 -2
- package/lib/CopyParagraphButton/CopyParagraphButton.js +8 -8
- package/lib/CopyParagraphButton/CopyParagraphButtonV2.js +7 -7
- package/lib/CopyParagraphButton/index.js +7 -7
- package/lib/CopyParagraphButton/initCopyParagraphButtons.js +4 -4
- package/lib/CreatedBy/CreatedBy.js +8 -8
- package/lib/CreatedBy/index.js +4 -4
- package/lib/DefinitionList/DefinitionDescription.js +4 -4
- package/lib/DefinitionList/DefinitionTerm.js +4 -4
- package/lib/DefinitionList/index.js +3 -3
- package/lib/Dialog/Dialog.js +2 -2
- package/lib/Dialog/index.js +2 -2
- package/lib/Embed/AudioEmbed.js +6 -6
- package/lib/Embed/BrightcoveEmbed.js +8 -8
- package/lib/Embed/ConceptEmbed.js +14 -14
- package/lib/Embed/ConceptListEmbed.js +5 -5
- package/lib/Embed/ContentLinkEmbed.js +4 -4
- package/lib/Embed/EmbedErrorPlaceholder.js +5 -5
- package/lib/Embed/ExternalEmbed.js +5 -5
- package/lib/Embed/FootnoteEmbed.js +2 -2
- package/lib/Embed/H5pEmbed.js +5 -5
- package/lib/Embed/IframeEmbed.js +2 -2
- package/lib/Embed/ImageEmbed.js +7 -7
- package/lib/Embed/RelatedContentEmbed.js +2 -2
- package/lib/Embed/UnknownEmbed.js +4 -4
- package/lib/Embed/conceptComponents.js +9 -9
- package/lib/Embed/index.js +13 -13
- package/lib/ErrorMessage/ErrorMessage.js +10 -10
- package/lib/ErrorMessage/ErrorResourceAccessDenied.js +5 -5
- package/lib/ErrorMessage/index.js +5 -5
- package/lib/FactBox/FactBox.js +4 -4
- package/lib/FactBox/FactBoxV2.js +9 -9
- package/lib/FactBox/index.js +5 -5
- package/lib/Figure/Figure.js +5 -5
- package/lib/Figure/FigureBylineExpandButton.js +1 -1
- package/lib/Figure/FigureExpandButton.js +1 -1
- package/lib/Figure/FigureLicense.js +2 -2
- package/lib/Figure/FigureLicenseDialog.js +2 -2
- package/lib/Figure/FigureOpenDialogButton.js +1 -1
- package/lib/Figure/index.js +2 -2
- package/lib/FileList/File.js +7 -7
- package/lib/FileList/FileList.js +7 -7
- package/lib/FileList/FileListV2.js +6 -6
- package/lib/FileList/FileV2.js +4 -4
- package/lib/FileList/PdfFile.js +2 -2
- package/lib/FileList/index.js +8 -8
- package/lib/Filter/FilterButtons.js +16 -16
- package/lib/Filter/FilterCarousel.js +8 -8
- package/lib/Filter/FilterList.js +6 -6
- package/lib/Filter/FilterListPhone.js +9 -9
- package/lib/Filter/ToggleItem.js +3 -3
- package/lib/Filter/filterClasses.js +2 -2
- package/lib/Filter/index.js +5 -5
- package/lib/Footer/EditorName.js +1 -1
- package/lib/Footer/Footer.js +13 -13
- package/lib/Footer/FooterLinks.js +9 -9
- package/lib/Footer/FooterPrivacy.js +6 -6
- package/lib/Footer/FooterText.js +2 -2
- package/lib/Footer/index.js +2 -2
- package/lib/Frontpage/FrontpageAllSubjects.js +14 -14
- package/lib/Frontpage/FrontpageFilm.js +8 -8
- package/lib/Frontpage/FrontpageHeader.js +9 -9
- package/lib/Frontpage/FrontpageInfo.js +4 -4
- package/lib/Frontpage/FrontpageMultidisciplinarySubject.js +13 -13
- package/lib/Frontpage/FrontpageProgramMenu.js +10 -10
- package/lib/Frontpage/FrontpageSearch.js +7 -7
- package/lib/Frontpage/FrontpageToolbox.js +8 -8
- package/lib/Frontpage/illustrations/Fellesfag.js +3 -3
- package/lib/Frontpage/illustrations/FrontpageHeaderIllustration.js +3 -3
- package/lib/Frontpage/illustrations/FrontpageIllustrations.js +3 -3
- package/lib/Frontpage/illustrations/FrontpageSubjectIllustration.js +3 -3
- package/lib/Frontpage/illustrations/MenuFellesfag.js +3 -3
- package/lib/Frontpage/illustrations/MenuStudiespesialiserende.js +3 -3
- package/lib/Frontpage/illustrations/MenuYrkesfag.js +3 -3
- package/lib/Frontpage/illustrations/Studiespesialiserende.js +3 -3
- package/lib/Frontpage/illustrations/Yrkesfag.js +3 -3
- package/lib/Frontpage/illustrations/index.js +14 -14
- package/lib/Frontpage/index.js +9 -9
- package/lib/Grid/Grid.d.ts +3 -2
- package/lib/Grid/Grid.js +21 -16
- package/lib/Grid/index.js +2 -2
- package/lib/Hero/Hero.js +3 -3
- package/lib/Image/Image.js +5 -5
- package/lib/Image/ImageLink.js +2 -2
- package/lib/Image/LazyLoadImage.js +3 -3
- package/lib/Image/index.js +4 -4
- package/lib/InfoBlock/InfoBlock.js +8 -8
- package/lib/InfoBox/InfoBox.js +4 -4
- package/lib/InfoBox/index.js +2 -2
- package/lib/InfoWidget/InfoWidget.js +12 -12
- package/lib/InfoWidget/index.js +4 -4
- package/lib/KeyFigure/KeyFigure.js +17 -17
- package/lib/KeyFigure/index.js +2 -2
- package/lib/LanguageSelector/LanguageSelector.js +8 -8
- package/lib/LanguageSelector/index.js +2 -2
- package/lib/Layout/Content.js +3 -3
- package/lib/Layout/LayoutItem.js +3 -3
- package/lib/Layout/OneColumn.js +4 -4
- package/lib/Layout/PageContainer.js +4 -4
- package/lib/Layout/index.js +7 -7
- package/lib/LearningPaths/LearningPathContent.js +2 -2
- package/lib/LearningPaths/LearningPathInformation.js +4 -4
- package/lib/LearningPaths/LearningPathLastStepNavigation.js +8 -8
- package/lib/LearningPaths/LearningPathMenu.js +12 -12
- package/lib/LearningPaths/LearningPathMenuAside.js +5 -5
- package/lib/LearningPaths/LearningPathMenuAsideCopyright.js +5 -5
- package/lib/LearningPaths/LearningPathMenuContent.js +11 -11
- package/lib/LearningPaths/LearningPathMenuIntro.js +7 -7
- package/lib/LearningPaths/LearningPathMenuModalWrapper.js +4 -4
- package/lib/LearningPaths/LearningPathMobileHeader.js +5 -5
- package/lib/LearningPaths/LearningPathMobileStepInfo.js +4 -4
- package/lib/LearningPaths/LearningPathSticky.js +4 -4
- package/lib/LearningPaths/LearningPathWrapper.js +2 -2
- package/lib/LearningPaths/index.js +5 -5
- package/lib/LetterFilter/LetterFilter.js +6 -6
- package/lib/LetterFilter/index.js +4 -4
- package/lib/LicenseByline/EmbedByline.js +14 -22
- package/lib/LicenseByline/LicenseDescription.js +5 -5
- package/lib/LicenseByline/LicenseLink.js +7 -7
- package/lib/LicenseByline/index.js +2 -2
- package/lib/List/OrderedList.js +4 -4
- package/lib/List/UnOrderedList.js +4 -4
- package/lib/List/index.js +3 -3
- package/lib/Logo/Logo.js +7 -7
- package/lib/Logo/SvgLogo.js +3 -3
- package/lib/Logo/index.js +4 -4
- package/lib/Masthead/Masthead.js +8 -8
- package/lib/Masthead/MastheadSearchModal.js +8 -8
- package/lib/Masthead/SkipToMainContent.js +4 -4
- package/lib/Masthead/index.js +6 -6
- package/lib/Masthead/utils.js +1 -1
- package/lib/MediaList/MediaList.js +3 -3
- package/lib/Messages/MessageBanner.js +6 -6
- package/lib/Messages/MessageBox.js +10 -10
- package/lib/Messages/MessageBoxTag.js +4 -4
- package/lib/Messages/index.js +4 -4
- package/lib/MultidisciplinarySubject/List.js +7 -7
- package/lib/MultidisciplinarySubject/ListItem.js +11 -11
- package/lib/MultidisciplinarySubject/MultidisciplinarySubject.js +13 -13
- package/lib/MultidisciplinarySubject/index.d.ts +0 -2
- package/lib/MultidisciplinarySubject/index.js +4 -11
- package/lib/MyNdla/Resource/Folder.js +11 -11
- package/lib/MyNdla/Resource/FolderInput.js +6 -6
- package/lib/MyNdla/Resource/FolderMenu.js +9 -9
- package/lib/MyNdla/Resource/index.js +3 -3
- package/lib/MyNdla/SettingsMenu.js +7 -7
- package/lib/MyNdla/index.js +5 -5
- package/lib/NDLAFilm/AboutNdlaFilm.js +5 -5
- package/lib/NDLAFilm/AllMoviesAlphabetically.js +16 -16
- package/lib/NDLAFilm/CategorySelect.js +9 -9
- package/lib/NDLAFilm/FilmContentCard.js +7 -7
- package/lib/NDLAFilm/FilmContentCardTags.js +5 -5
- package/lib/NDLAFilm/FilmMovieList.js +5 -5
- package/lib/NDLAFilm/FilmMovieSearch.js +8 -8
- package/lib/NDLAFilm/FilmSlideshow.js +12 -12
- package/lib/NDLAFilm/MovieGrid.js +6 -6
- package/lib/NDLAFilm/NavigationArrow.js +5 -5
- package/lib/NDLAFilm/SlideshowIndicator.js +5 -5
- package/lib/NDLAFilm/VisualElement.js +5 -5
- package/lib/NDLAFilm/filmStyles.js +2 -2
- package/lib/NDLAFilm/index.js +7 -7
- package/lib/Navigation/NavigationBox.js +17 -17
- package/lib/Navigation/NavigationTopicAbout.js +13 -13
- package/lib/Navigation/index.js +3 -3
- package/lib/NoContentBox/NoContentBox.js +3 -3
- package/lib/NoContentBox/index.js +4 -4
- package/lib/Notion/ConceptNotion.js +10 -10
- package/lib/Notion/FigureNotion.js +4 -4
- package/lib/Notion/Notion.js +8 -8
- package/lib/Notion/NotionImage.js +3 -3
- package/lib/Notion/NotionVisualElement.js +5 -5
- package/lib/Notion/index.js +4 -4
- package/lib/Programme/Programme.js +12 -12
- package/lib/Programme/ProgrammeSubjects.js +5 -5
- package/lib/Programme/index.js +5 -5
- package/lib/ProgrammeCard/ProgrammeCard.js +7 -7
- package/lib/ProgrammeCard/index.js +2 -2
- package/lib/RadioButtonGroup/RadioButtonGroup.js +17 -19
- package/lib/RadioButtonGroup/index.js +4 -4
- package/lib/RelatedArticleList/RelatedArticleList.js +7 -7
- package/lib/RelatedArticleList/RelatedArticleV2.js +7 -7
- package/lib/RelatedArticleList/index.js +4 -4
- package/lib/Resource/BlockResource.js +13 -13
- package/lib/Resource/ListResource.js +13 -13
- package/lib/Resource/index.js +3 -3
- package/lib/Resource/resourceComponents.js +12 -12
- package/lib/ResourceBox/ResourceBox.js +9 -9
- package/lib/ResourceBox/index.js +2 -2
- package/lib/ResourceGroup/ResourceGroup.js +5 -5
- package/lib/ResourceGroup/ResourceItem.js +17 -17
- package/lib/ResourceGroup/ResourceList.js +6 -6
- package/lib/ResourceGroup/index.js +4 -4
- package/lib/ResourcesWrapper/ResourcesTopicTitle.js +11 -11
- package/lib/ResourcesWrapper/ResourcesWrapper.js +4 -4
- package/lib/ResourcesWrapper/index.js +5 -5
- package/lib/Search/ActiveFilterContent.js +6 -6
- package/lib/Search/ActiveFilters.js +9 -9
- package/lib/Search/ContentTypeResult.js +9 -9
- package/lib/Search/ContentTypeResultStyles.js +7 -7
- package/lib/Search/LoadingWrapper.js +4 -4
- package/lib/Search/SearchField.js +7 -7
- package/lib/Search/SearchFieldForm.js +2 -2
- package/lib/Search/SearchResult.js +15 -15
- package/lib/Search/SearchResultSleeve.js +14 -14
- package/lib/Search/ToggleSearchButton.js +5 -5
- package/lib/Search/index.js +4 -4
- package/lib/SearchTypeResult/ActiveFilterContent.js +6 -6
- package/lib/SearchTypeResult/ActiveFilters.js +10 -10
- package/lib/SearchTypeResult/PopupFilter.js +12 -12
- package/lib/SearchTypeResult/ResultNavigation.js +7 -7
- package/lib/SearchTypeResult/SearchFieldHeader.js +10 -10
- package/lib/SearchTypeResult/SearchFilterContent.js +6 -6
- package/lib/SearchTypeResult/SearchHeader.js +16 -16
- package/lib/SearchTypeResult/SearchItem.js +16 -16
- package/lib/SearchTypeResult/SearchItemList.js +19 -19
- package/lib/SearchTypeResult/SearchItems.js +7 -7
- package/lib/SearchTypeResult/SearchNotionsResult.js +7 -7
- package/lib/SearchTypeResult/SearchSubjectItem.js +7 -7
- package/lib/SearchTypeResult/SearchSubjectResult.js +5 -5
- package/lib/SearchTypeResult/SearchTypeHeader.js +14 -14
- package/lib/SearchTypeResult/SearchTypeResult.js +9 -9
- package/lib/SearchTypeResult/SearchViewType.js +7 -7
- package/lib/SearchTypeResult/components/ItemContexts.js +10 -10
- package/lib/SearchTypeResult/components/ItemResourceHeader.js +14 -14
- package/lib/SearchTypeResult/components/ItemTopicHeader.js +8 -8
- package/lib/SearchTypeResult/components/SubjectFilters.js +8 -8
- package/lib/SearchTypeResult/index.js +7 -7
- package/lib/SectionHeading/SectionHeading.js +3 -3
- package/lib/SectionHeading/index.js +4 -4
- package/lib/SnackBar/DefaultSnackbar.js +5 -5
- package/lib/SnackBar/SnackbarProvider.js +8 -8
- package/lib/SnackBar/index.js +2 -2
- package/lib/Subject/Subject.js +10 -10
- package/lib/Subject/SubjectBanner.js +4 -4
- package/lib/Subject/SubjectHeader.js +7 -7
- package/lib/Subject/SubjectNewContent.js +12 -12
- package/lib/Subject/SubjectSocial.js +3 -3
- package/lib/Subject/index.js +4 -4
- package/lib/Table/Table.js +10 -10
- package/lib/Table/index.js +4 -4
- package/lib/TagSelector/Control.js +4 -4
- package/lib/TagSelector/DropdownIndicator.js +5 -5
- package/lib/TagSelector/Input.js +3 -3
- package/lib/TagSelector/Menu.js +3 -3
- package/lib/TagSelector/MenuList.js +4 -4
- package/lib/TagSelector/Option.js +5 -5
- package/lib/TagSelector/SelectContainer.js +4 -4
- package/lib/TagSelector/TagSelector.js +16 -16
- package/lib/TagSelector/ValueButton.js +4 -4
- package/lib/TagSelector/index.js +2 -2
- package/lib/ToolboxPage/ToolboxInfo.js +4 -4
- package/lib/ToolboxPage/index.js +2 -2
- package/lib/Topic/Loader.js +4 -4
- package/lib/Topic/Topic.js +19 -19
- package/lib/Topic/index.js +4 -4
- package/lib/Translation/Translation.js +4 -4
- package/lib/Translation/TranslationLine.js +4 -4
- package/lib/Translation/index.js +3 -3
- package/lib/TreeStructure/AddFolderButton.js +7 -7
- package/lib/TreeStructure/ComboboxButton.js +7 -7
- package/lib/TreeStructure/FolderItem.js +12 -12
- package/lib/TreeStructure/FolderItems.js +6 -6
- package/lib/TreeStructure/TreeStructure.js +17 -17
- package/lib/TreeStructure/index.js +2 -2
- package/lib/Typography/Heading.js +2 -2
- package/lib/Typography/index.js +2 -2
- package/lib/User/UserInfo.js +4 -4
- package/lib/User/parseUserObject.js +3 -3
- package/lib/all.css +1 -1
- package/lib/i18n/i18n.js +7 -7
- package/lib/index.d.ts +1 -7
- package/lib/index.js +43 -84
- package/lib/locale/LocaleProvider.js +3 -3
- package/lib/locale/messages-en.js +11 -11
- package/lib/locale/messages-nb.js +11 -11
- package/lib/locale/messages-nn.js +11 -11
- package/lib/locale/messages-se.js +11 -11
- package/lib/locale/messages-sma.js +11 -11
- package/lib/model/index.js +3 -3
- package/lib/utils/createUniversalPortal.js +2 -2
- package/lib/utils/resourceTypeColor.js +4 -4
- package/package.json +14 -15
- package/src/Animation/index.ts +0 -2
- package/src/BlogPost/BlogPost.stories.tsx +1 -1
- package/src/BlogPost/BlogPost.tsx +1 -2
- package/src/CampaignBlock/CampaignBlock.stories.tsx +1 -1
- package/src/ContactBlock/Contactblock.stories.tsx +1 -1
- package/src/Embed/AudioEmbed.stories.tsx +1 -1
- package/src/Embed/BrightcoveEmbed.stories.tsx +1 -1
- package/src/Embed/ConceptEmbed.stories.tsx +1 -1
- package/src/Embed/ExternalEmbed.stories.tsx +1 -1
- package/src/Embed/H5pEmbed.stories.tsx +1 -1
- package/src/Embed/IframeEmbed.stories.tsx +1 -1
- package/src/Embed/ImageEmbed.stories.tsx +1 -1
- package/src/Grid/Grid.stories.tsx +6 -4
- package/src/Grid/Grid.tsx +52 -17
- package/src/KeyFigure/KeyFigure.stories.tsx +1 -1
- package/src/KeyFigure/KeyFigure.tsx +2 -3
- package/src/LanguageSelector/LanguageSelector.stories.tsx +1 -1
- package/src/LearningPaths/LearningPathMenu.stories.tsx +1 -1
- package/src/LetterFilter/LetterFilter.stories.tsx +1 -1
- package/src/LicenseByline/EmbedByline.stories.tsx +1 -1
- package/src/LicenseByline/EmbedByline.tsx +1 -0
- package/src/LicenseByline/LicenseLink.tsx +1 -0
- package/src/MultidisciplinarySubject/index.ts +0 -2
- package/src/MyNdla/Resource/Folder.stories.tsx +1 -1
- package/src/ProgrammeCard/ProgrammeCard.stories.tsx +1 -1
- package/src/Resource/BlockResource.stories.tsx +1 -1
- package/src/Resource/Resource.stories.tsx +1 -1
- package/src/Search/component.search-field.scss +0 -14
- package/src/index.ts +1 -11
- package/es/Animation/DisplayOnPageYOffset.js +0 -86
- package/es/AuthorInfo/AuthorInfo.js +0 -63
- package/es/AuthorInfo/index.js +0 -2
- package/es/Breadcrumblist/Breadcrumblist.js +0 -225
- package/es/Breadcrumblist/index.js +0 -2
- package/es/ContentCard/ContentCard.js +0 -95
- package/es/ContentCard/index.js +0 -2
- package/es/MultidisciplinarySubject/Illustrations.js +0 -76
- package/es/MultidisciplinarySubject/MultidisciplinarySubjectHeader.js +0 -112
- package/es/Portrait/Portrait.js +0 -42
- package/es/Portrait/index.js +0 -10
- package/lib/Animation/DisplayOnPageYOffset.d.ts +0 -27
- package/lib/Animation/DisplayOnPageYOffset.js +0 -93
- package/lib/AuthorInfo/AuthorInfo.d.ts +0 -16
- package/lib/AuthorInfo/AuthorInfo.js +0 -70
- package/lib/AuthorInfo/index.d.ts +0 -2
- package/lib/AuthorInfo/index.js +0 -10
- package/lib/Breadcrumblist/Breadcrumblist.d.ts +0 -29
- package/lib/Breadcrumblist/Breadcrumblist.js +0 -232
- package/lib/Breadcrumblist/index.d.ts +0 -3
- package/lib/Breadcrumblist/index.js +0 -10
- package/lib/ContentCard/ContentCard.d.ts +0 -12
- package/lib/ContentCard/ContentCard.js +0 -102
- package/lib/ContentCard/index.d.ts +0 -2
- package/lib/ContentCard/index.js +0 -10
- package/lib/MultidisciplinarySubject/Illustrations.d.ts +0 -29
- package/lib/MultidisciplinarySubject/Illustrations.js +0 -90
- package/lib/MultidisciplinarySubject/MultidisciplinarySubjectHeader.d.ts +0 -13
- package/lib/MultidisciplinarySubject/MultidisciplinarySubjectHeader.js +0 -118
- package/lib/Portrait/Portrait.d.ts +0 -15
- package/lib/Portrait/Portrait.js +0 -50
- package/lib/Portrait/index.d.ts +0 -9
- package/lib/Portrait/index.js +0 -17
- package/src/Animation/DisplayOnPageYOffset.tsx +0 -66
- package/src/AuthorInfo/AuthorInfo.tsx +0 -82
- package/src/AuthorInfo/index.ts +0 -3
- package/src/Breadcrumblist/Breadcrumblist.tsx +0 -320
- package/src/Breadcrumblist/index.ts +0 -4
- package/src/ContentCard/ContentCard.tsx +0 -152
- package/src/ContentCard/index.ts +0 -3
- package/src/MultidisciplinarySubject/Illustrations.tsx +0 -148
- package/src/MultidisciplinarySubject/MultidisciplinarySubjectHeader.tsx +0 -125
- package/src/Portrait/Portrait.tsx +0 -45
- package/src/Portrait/index.ts +0 -11
|
@@ -1,125 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import styled from '@emotion/styled';
|
|
3
|
-
import { useTranslation } from 'react-i18next';
|
|
4
|
-
import { breakpoints, mq, fonts, spacing } from '@ndla/core';
|
|
5
|
-
import SafeLink from '@ndla/safelink';
|
|
6
|
-
import {
|
|
7
|
-
ClimateIllustration,
|
|
8
|
-
DemocracyClimateIllustration,
|
|
9
|
-
DemocracyIllustration,
|
|
10
|
-
PublicHealthClimateIllustration,
|
|
11
|
-
PublicHealthDemocracyClimateIllustration,
|
|
12
|
-
PublicHealthDemocracyIllustration,
|
|
13
|
-
PublicHealthIllustration,
|
|
14
|
-
} from './Illustrations';
|
|
15
|
-
import { HomeBreadcrumb, SimpleBreadcrumbItem } from '../Breadcrumb';
|
|
16
|
-
|
|
17
|
-
const StyledWrapper = styled.div`
|
|
18
|
-
width: 100%;
|
|
19
|
-
background: linear-gradient(180deg, rgba(255, 255, 255, 0) 68.75%, #ffffff 100%),
|
|
20
|
-
linear-gradient(336.12deg, #efeedc 35.53%, #faf6f0 74.23%), #ddd8af;
|
|
21
|
-
|
|
22
|
-
display: flex;
|
|
23
|
-
justify-content: center;
|
|
24
|
-
align-items: stretch;
|
|
25
|
-
`;
|
|
26
|
-
|
|
27
|
-
const ContentWrapper = styled.div`
|
|
28
|
-
max-width: 1440px;
|
|
29
|
-
width: 100%;
|
|
30
|
-
display: flex;
|
|
31
|
-
flex-direction: column;
|
|
32
|
-
justify-content: flex-start;
|
|
33
|
-
`;
|
|
34
|
-
|
|
35
|
-
const TextWrapper = styled.div`
|
|
36
|
-
padding: 26px 26px 0;
|
|
37
|
-
display: flex;
|
|
38
|
-
flex-direction: column;
|
|
39
|
-
gap: ${spacing.small};
|
|
40
|
-
width: 100%;
|
|
41
|
-
z-index: 2;
|
|
42
|
-
${mq.range({ from: breakpoints.tablet })} {
|
|
43
|
-
padding: 44px 44px 0;
|
|
44
|
-
}
|
|
45
|
-
`;
|
|
46
|
-
|
|
47
|
-
const Heading = styled.div`
|
|
48
|
-
${fonts.sizes('18px', '24px')};
|
|
49
|
-
margin-bottom: 10px;
|
|
50
|
-
`;
|
|
51
|
-
|
|
52
|
-
const SubjectsWrapper = styled.div`
|
|
53
|
-
${fonts.sizes('14px', '18px')};
|
|
54
|
-
`;
|
|
55
|
-
|
|
56
|
-
type IllustrationsWrapperProps = {
|
|
57
|
-
subjectCount?: number;
|
|
58
|
-
};
|
|
59
|
-
const IllustrationsWrapper = styled.div<IllustrationsWrapperProps>`
|
|
60
|
-
display: flex;
|
|
61
|
-
align-items: flex-end;
|
|
62
|
-
margin-bottom: 24px;
|
|
63
|
-
`;
|
|
64
|
-
|
|
65
|
-
type subjects = 'climate' | 'democracy' | 'publicHealth';
|
|
66
|
-
|
|
67
|
-
type subjectLink = {
|
|
68
|
-
label: string;
|
|
69
|
-
url: string;
|
|
70
|
-
};
|
|
71
|
-
|
|
72
|
-
type Props = {
|
|
73
|
-
subjects?: subjects[];
|
|
74
|
-
subjectsLinks?: subjectLink[];
|
|
75
|
-
breadcrumbs?: SimpleBreadcrumbItem[];
|
|
76
|
-
};
|
|
77
|
-
|
|
78
|
-
const MultidisciplinarySubjectHeader = ({ subjects = [], subjectsLinks = [], breadcrumbs = [] }: Props) => {
|
|
79
|
-
const { t } = useTranslation();
|
|
80
|
-
const getIllustration = () => {
|
|
81
|
-
if (subjects.length === 3) {
|
|
82
|
-
return <PublicHealthDemocracyClimateIllustration />;
|
|
83
|
-
}
|
|
84
|
-
if (subjects.includes('publicHealth') && subjects.includes('democracy')) {
|
|
85
|
-
return <PublicHealthDemocracyIllustration />;
|
|
86
|
-
}
|
|
87
|
-
if (subjects.includes('climate') && subjects.includes('democracy')) {
|
|
88
|
-
return <DemocracyClimateIllustration />;
|
|
89
|
-
}
|
|
90
|
-
if (subjects.includes('climate') && subjects.includes('publicHealth')) {
|
|
91
|
-
return <PublicHealthClimateIllustration />;
|
|
92
|
-
}
|
|
93
|
-
return (
|
|
94
|
-
<>
|
|
95
|
-
{subjects.includes('publicHealth') && <PublicHealthIllustration />}
|
|
96
|
-
{subjects.includes('democracy') && <DemocracyIllustration />}
|
|
97
|
-
{subjects.includes('climate') && <ClimateIllustration />}
|
|
98
|
-
</>
|
|
99
|
-
);
|
|
100
|
-
};
|
|
101
|
-
return (
|
|
102
|
-
<StyledWrapper>
|
|
103
|
-
<ContentWrapper>
|
|
104
|
-
<TextWrapper>
|
|
105
|
-
<HomeBreadcrumb items={breadcrumbs} />
|
|
106
|
-
<Heading>{t('frontpageMultidisciplinarySubject.heading')}</Heading>
|
|
107
|
-
<SubjectsWrapper>
|
|
108
|
-
{t('multidisciplinarySubject.subjectsLinksDescription')}:{' '}
|
|
109
|
-
{subjectsLinks.map((subject, index) => {
|
|
110
|
-
return (
|
|
111
|
-
<span key={subject.label}>
|
|
112
|
-
{index > 0 && (index < subjectsLinks.length - 1 ? ', ' : ' og ')}
|
|
113
|
-
<SafeLink to={subject.url}>{subject.label}</SafeLink>
|
|
114
|
-
</span>
|
|
115
|
-
);
|
|
116
|
-
})}
|
|
117
|
-
</SubjectsWrapper>
|
|
118
|
-
</TextWrapper>
|
|
119
|
-
<IllustrationsWrapper subjectCount={subjects.length}>{getIllustration()}</IllustrationsWrapper>
|
|
120
|
-
</ContentWrapper>
|
|
121
|
-
</StyledWrapper>
|
|
122
|
-
);
|
|
123
|
-
};
|
|
124
|
-
|
|
125
|
-
export default MultidisciplinarySubjectHeader;
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright (c) 2016-present, NDLA.
|
|
3
|
-
*
|
|
4
|
-
* This source code is licensed under the GPLv3 license found in the
|
|
5
|
-
* LICENSE file in the root directory of this source tree.
|
|
6
|
-
*
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
import styled from '@emotion/styled';
|
|
10
|
-
import React from 'react';
|
|
11
|
-
|
|
12
|
-
interface PortraitWrapperProps {
|
|
13
|
-
size: string;
|
|
14
|
-
}
|
|
15
|
-
const PortraitWrapper = styled.div<PortraitWrapperProps>`
|
|
16
|
-
width: ${(p) => p.size};
|
|
17
|
-
height: ${(p) => p.size};
|
|
18
|
-
span {
|
|
19
|
-
display: block;
|
|
20
|
-
border-radius: 50%;
|
|
21
|
-
background-color: rgba(0, 0, 0, 0.16);
|
|
22
|
-
background-size: cover;
|
|
23
|
-
background-position: center center;
|
|
24
|
-
width: ${(p) => p.size};
|
|
25
|
-
height: ${(p) => p.size};
|
|
26
|
-
}
|
|
27
|
-
`;
|
|
28
|
-
|
|
29
|
-
interface Props {
|
|
30
|
-
src: string;
|
|
31
|
-
alt: string;
|
|
32
|
-
className?: string;
|
|
33
|
-
modifier?: 'small' | 'large';
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
const Portrait = ({ src, alt, modifier, className }: Props) => {
|
|
37
|
-
const size = modifier === 'small' ? '4rem' : modifier === 'large' ? '10rem' : '7rem';
|
|
38
|
-
return (
|
|
39
|
-
<PortraitWrapper size={size} className={className}>
|
|
40
|
-
<span role="img" aria-label={alt} style={{ backgroundImage: `url(${src})` }} />
|
|
41
|
-
</PortraitWrapper>
|
|
42
|
-
);
|
|
43
|
-
};
|
|
44
|
-
|
|
45
|
-
export default Portrait;
|
package/src/Portrait/index.ts
DELETED