@ndla/ui 30.5.0 → 30.5.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.
- package/es/Animation/DisplayOnPageYOffset.js +9 -32
- package/es/Animation/Fade.js +11 -20
- package/es/Article/Article.js +50 -78
- package/es/Article/ArticleAccessMessage.js +4 -9
- package/es/Article/ArticleByline.js +16 -32
- package/es/Article/ArticleContent.js +9 -15
- package/es/Article/ArticleFootNotes.js +3 -7
- package/es/Article/ArticleHeaderWrapper.js +13 -37
- package/es/Article/ArticleNotions.js +8 -16
- package/es/Article/ArticleSideBar.js +15 -34
- package/es/Article/index.js +1 -0
- package/es/Aside/Aside.js +9 -14
- package/es/AudioPlayer/AudioPlayer.js +17 -48
- package/es/AudioPlayer/Controls.js +28 -83
- package/es/AudioPlayer/SpeechControl.js +4 -10
- package/es/AudioPlayer/initAudioPlayers.js +1 -9
- package/es/AuthorInfo/AuthorInfo.js +7 -12
- package/es/BannerCard/BannerCard.js +6 -15
- package/es/BannerCard/index.js +1 -0
- package/es/BlogPosts/BlogPost.js +14 -21
- package/es/BlogPosts/BlogPostWrapper.js +3 -5
- package/es/BlogPosts/index.js +1 -0
- package/es/Breadcrumb/ActionBreadcrumb.js +10 -14
- package/es/Breadcrumb/Breadcrumb.js +23 -40
- package/es/Breadcrumb/BreadcrumbItem.js +9 -16
- package/es/Breadcrumb/HeaderBreadcrumb.js +11 -12
- package/es/Breadcrumb/HomeBreadcrumb.js +9 -18
- package/es/Breadcrumb/index.js +1 -0
- package/es/Breadcrumblist/Breadcrumblist.js +29 -61
- package/es/CompetenceGoalTab/CompetenceGoalItem.js +6 -19
- package/es/CompetenceGoalTab/CompetenceGoalTab.js +11 -28
- package/es/CompetenceGoalTab/CompetenceItem.js +8 -26
- package/es/CompetenceGoalTab/SearchButton.js +6 -10
- package/es/CompetenceGoals/CompetenceGoalsDialog.js +11 -21
- package/es/ComponentCursor/ComponentCursor.js +9 -29
- package/es/ContentCard/ContentCard.js +11 -25
- package/es/ContentLoader/index.js +22 -29
- package/es/ContentPlaceholder/ContentPlaceholder.js +3 -9
- package/es/ContentPlaceholder/index.js +1 -0
- package/es/ContentTypeBadge/ContentTypeBadge.js +11 -29
- package/es/CopyParagraphButton/CopyParagraphButton.js +14 -33
- package/es/CopyParagraphButton/index.js +1 -0
- package/es/CopyParagraphButton/initCopyParagraphButtons.js +1 -6
- package/es/CreatedBy/CreatedBy.js +7 -14
- package/es/CreatedBy/index.js +1 -0
- package/es/Dialog/Dialog.js +21 -27
- package/es/Dialog/index.js +1 -0
- package/es/ErrorMessage/ErrorMessage.js +7 -12
- package/es/ErrorMessage/ErrorResourceAccessDenied.js +4 -9
- package/es/FactBox/FactBox.js +7 -16
- package/es/Figure/Figure.js +78 -89
- package/es/Figure/FigureBylineExpandButton.js +4 -4
- package/es/Figure/FigureExpandButton.js +4 -4
- package/es/Figure/FigureLicense.js +13 -15
- package/es/Figure/FigureLicenseDialog.js +13 -15
- package/es/Figure/FigureOpenDialogButton.js +4 -4
- package/es/Figure/index.js +1 -0
- package/es/FileList/File.js +3 -13
- package/es/FileList/FileList.js +4 -11
- package/es/Filter/FilterButtons.js +12 -35
- package/es/Filter/FilterCarousel.js +15 -43
- package/es/Filter/FilterList.js +27 -52
- package/es/Filter/FilterListPhone.js +36 -71
- package/es/Filter/ToggleItem.js +16 -21
- package/es/Filter/filterClasses.js +1 -0
- package/es/Filter/index.js +1 -0
- package/es/Footer/EditorName.js +4 -4
- package/es/Footer/Footer.js +9 -22
- package/es/Footer/FooterAuth.js +17 -26
- package/es/Footer/FooterLinks.js +4 -17
- package/es/Footer/FooterPrivacy.js +4 -11
- package/es/Footer/FooterText.js +2 -4
- package/es/Footer/index.js +1 -0
- package/es/Footer/privacy_en.js +1 -3
- package/es/Footer/privacy_nb.js +1 -3
- package/es/Footer/privacy_nn.js +1 -3
- package/es/Frontpage/FrontpageAllSubjects.js +11 -36
- package/es/Frontpage/FrontpageFilm.js +4 -11
- package/es/Frontpage/FrontpageHeader.js +5 -11
- package/es/Frontpage/FrontpageInfo.js +1 -4
- package/es/Frontpage/FrontpageMultidisciplinarySubject.js +4 -12
- package/es/Frontpage/FrontpageProgramMenu.js +10 -34
- package/es/Frontpage/FrontpageSearch.js +21 -37
- package/es/Frontpage/FrontpageToolbox.js +4 -12
- package/es/Frontpage/illustrations/Fellesfag.js +3 -5
- package/es/Frontpage/illustrations/FrontpageHeaderIllustration.js +3 -5
- package/es/Frontpage/illustrations/FrontpageIllustrations.js +0 -2
- package/es/Frontpage/illustrations/FrontpageSubjectIllustration.js +3 -6
- package/es/Frontpage/illustrations/MenuFellesfag.js +3 -5
- package/es/Frontpage/illustrations/MenuStudiespesialiserende.js +3 -5
- package/es/Frontpage/illustrations/MenuYrkesfag.js +3 -5
- package/es/Frontpage/illustrations/Studiespesialiserende.js +3 -5
- package/es/Frontpage/illustrations/Yrkesfag.js +3 -5
- package/es/Frontpage/sortCategories.js +1 -2
- package/es/Hero/Hero.js +7 -12
- package/es/Hero/index.js +1 -0
- package/es/Image/Image.js +18 -32
- package/es/Image/ImageLink.js +8 -16
- package/es/Image/LazyLoadImage.js +12 -19
- package/es/Image/index.js +1 -0
- package/es/InfoBlock/InfoBlock.js +5 -12
- package/es/InfoBox/InfoBox.js +1 -4
- package/es/InfoWidget/InfoWidget.js +7 -21
- package/es/LanguageSelector/LanguageSelector.js +17 -34
- package/es/LanguageSelector/LanguageSelectorContent.js +14 -13
- package/es/Layout/Content.js +2 -2
- package/es/Layout/LayoutItem.js +3 -7
- package/es/Layout/OneColumn.js +7 -12
- package/es/Layout/PageContainer.js +12 -15
- package/es/Layout/index.js +1 -0
- package/es/LearningPaths/LearningPathContent.js +2 -4
- package/es/LearningPaths/LearningPathInformation.js +8 -14
- package/es/LearningPaths/LearningPathLastStepNavigation.js +7 -16
- package/es/LearningPaths/LearningPathMenu.js +20 -34
- package/es/LearningPaths/LearningPathMenuAside.js +8 -14
- package/es/LearningPaths/LearningPathMenuAsideCopyright.js +4 -10
- package/es/LearningPaths/LearningPathMenuContent.js +12 -22
- package/es/LearningPaths/LearningPathMenuIntro.js +7 -18
- package/es/LearningPaths/LearningPathMenuModalWrapper.js +6 -11
- package/es/LearningPaths/LearningPathMobileHeader.js +11 -8
- package/es/LearningPaths/LearningPathMobileStepInfo.js +4 -9
- package/es/LearningPaths/LearningPathSticky.js +7 -11
- package/es/LearningPaths/LearningPathWrapper.js +3 -5
- package/es/LearningPaths/index.js +1 -0
- package/es/Logo/Logo.js +13 -19
- package/es/Logo/SvgLogo.js +9 -16
- package/es/Logo/index.js +1 -0
- package/es/Masthead/Masthead.js +15 -25
- package/es/Masthead/MastheadAuthModal.js +8 -17
- package/es/Masthead/MastheadSearchModal.js +7 -13
- package/es/Masthead/SkipToMainContent.js +2 -7
- package/es/Masthead/index.js +1 -0
- package/es/Masthead/utils.js +8 -17
- package/es/MediaList/MediaList.js +17 -23
- package/es/Messages/MessageBanner.js +8 -15
- package/es/Messages/MessageBox.js +10 -22
- package/es/Messages/MessageBoxTag.js +3 -8
- package/es/Messages/index.js +1 -0
- package/es/MultidisciplinarySubject/List.js +5 -15
- package/es/MultidisciplinarySubject/ListItem.js +9 -20
- package/es/MultidisciplinarySubject/MultidisciplinarySubject.js +8 -20
- package/es/MultidisciplinarySubject/MultidisciplinarySubjectHeader.js +7 -24
- package/es/MultidisciplinarySubject/index.js +1 -0
- package/es/MyNdla/Resource/Folder.js +20 -35
- package/es/MyNdla/Resource/FolderInput.js +23 -26
- package/es/MyNdla/Resource/index.js +1 -0
- package/es/NDLAFilm/AboutNdlaFilm.js +4 -9
- package/es/NDLAFilm/AllMoviesAlphabetically.js +12 -43
- package/es/NDLAFilm/CategorySelect.js +13 -42
- package/es/NDLAFilm/FilmContentCard.js +13 -20
- package/es/NDLAFilm/FilmContentCardTags.js +2 -7
- package/es/NDLAFilm/FilmMovieList.js +13 -19
- package/es/NDLAFilm/FilmMovieSearch.js +10 -16
- package/es/NDLAFilm/FilmSlideshow.js +24 -78
- package/es/NDLAFilm/MovieGrid.js +9 -15
- package/es/NDLAFilm/NavigationArrow.js +4 -8
- package/es/NDLAFilm/SlideshowIndicator.js +4 -8
- package/es/NDLAFilm/VisualElement.js +4 -9
- package/es/NDLAFilm/filmStyles.js +0 -2
- package/es/NDLAFilm/index.js +1 -0
- package/es/NDLAFilm/isLetter.js +1 -0
- package/es/NDLAFilm/types.js +1 -0
- package/es/Navigation/NavigationBox.js +16 -39
- package/es/Navigation/NavigationHeading.js +5 -12
- package/es/Navigation/NavigationTopicAbout.js +12 -31
- package/es/Navigation/index.js +1 -0
- package/es/NoContentBox/NoContentBox.js +5 -5
- package/es/NoContentBox/index.js +1 -0
- package/es/Notion/ConceptNotion.js +20 -27
- package/es/Notion/FigureNotion.js +26 -32
- package/es/Notion/Notion.js +11 -21
- package/es/Notion/NotionImage.js +6 -11
- package/es/Notion/NotionVisualElement.js +4 -17
- package/es/Portrait/Portrait.js +12 -7
- package/es/Portrait/index.js +1 -0
- package/es/Programme/Programme.js +9 -19
- package/es/Programme/ProgrammeSubjects.js +9 -15
- package/es/Programme/index.js +1 -0
- package/es/RadioButtonGroup/RadioButtonGroup.js +10 -37
- package/es/RadioButtonGroup/index.js +1 -0
- package/es/RelatedArticleList/RelatedArticleList.js +15 -21
- package/es/RelatedArticleList/index.js +1 -0
- package/es/Resource/BlockResource.js +25 -36
- package/es/Resource/ListResource.js +28 -42
- package/es/Resource/index.js +1 -1
- package/es/Resource/resourceComponents.js +15 -24
- package/es/ResourceBox/ResourceBox.js +6 -16
- package/es/ResourceBox/index.js +1 -0
- package/es/ResourceGroup/ResourceGroup.js +9 -14
- package/es/ResourceGroup/ResourceItem.js +18 -49
- package/es/ResourceGroup/ResourceList.js +15 -35
- package/es/ResourceGroup/index.js +1 -0
- package/es/ResourcesWrapper/ResourcesTitle.js +5 -10
- package/es/ResourcesWrapper/ResourcesTopicTitle.js +13 -28
- package/es/ResourcesWrapper/ResourcesWrapper.js +9 -14
- package/es/ResourcesWrapper/index.js +1 -0
- package/es/Search/ActiveFilterContent.js +4 -8
- package/es/Search/ActiveFilters.js +4 -16
- package/es/Search/ContentTypeResult.js +26 -46
- package/es/Search/LoadingWrapper.js +2 -5
- package/es/Search/SearchField.js +18 -30
- package/es/Search/SearchFieldForm.js +3 -5
- package/es/Search/SearchResult.js +10 -39
- package/es/Search/SearchResultSleeve.js +21 -59
- package/es/Search/ToggleSearchButton.js +10 -19
- package/es/Search/index.js +1 -0
- package/es/SearchTypeResult/ActiveFilterContent.js +5 -11
- package/es/SearchTypeResult/ActiveFilters.js +8 -17
- package/es/SearchTypeResult/PopupFilter.js +15 -35
- package/es/SearchTypeResult/ResultNavigation.js +8 -18
- package/es/SearchTypeResult/SearchFieldHeader.js +12 -32
- package/es/SearchTypeResult/SearchFilterContent.js +8 -15
- package/es/SearchTypeResult/SearchHeader.js +19 -42
- package/es/SearchTypeResult/SearchItem.js +13 -24
- package/es/SearchTypeResult/SearchItemList.js +14 -30
- package/es/SearchTypeResult/SearchItems.js +5 -10
- package/es/SearchTypeResult/SearchNotionItem.js +17 -36
- package/es/SearchTypeResult/SearchNotionsResult.js +6 -14
- package/es/SearchTypeResult/SearchSubjectItem.js +8 -16
- package/es/SearchTypeResult/SearchSubjectResult.js +2 -5
- package/es/SearchTypeResult/SearchTypeHeader.js +8 -23
- package/es/SearchTypeResult/SearchTypeResult.js +14 -21
- package/es/SearchTypeResult/SearchViewType.js +5 -15
- package/es/SearchTypeResult/components/ItemContexts.js +8 -23
- package/es/SearchTypeResult/components/ItemResourceHeader.js +8 -18
- package/es/SearchTypeResult/components/ItemTopicHeader.js +7 -16
- package/es/SearchTypeResult/components/SubjectFilters.js +21 -58
- package/es/SearchTypeResult/index.js +1 -0
- package/es/SectionHeading/SectionHeading.js +4 -8
- package/es/SnackBar/DefaultSnackbar.js +7 -15
- package/es/SnackBar/SnackbarProvider.js +16 -39
- package/es/SnackBar/index.js +1 -0
- package/es/Subject/Subject.js +8 -24
- package/es/Subject/SubjectAbout.js +8 -16
- package/es/Subject/SubjectArchive.js +16 -55
- package/es/Subject/SubjectBanner.js +2 -5
- package/es/Subject/SubjectCarousel.js +14 -27
- package/es/Subject/SubjectHeader.js +4 -10
- package/es/Subject/SubjectLinks.js +5 -15
- package/es/Subject/SubjectNewContent.js +3 -15
- package/es/Subject/SubjectShortcuts.js +12 -43
- package/es/Subject/SubjectSocial.js +4 -8
- package/es/Table/Table.js +9 -16
- package/es/Table/index.js +1 -0
- package/es/TagSelector/Control.js +12 -11
- package/es/TagSelector/DropdownIndicator.js +8 -18
- package/es/TagSelector/Input.js +4 -9
- package/es/TagSelector/Menu.js +6 -13
- package/es/TagSelector/MenuList.js +12 -10
- package/es/TagSelector/Option.js +9 -16
- package/es/TagSelector/SelectContainer.js +12 -11
- package/es/TagSelector/TagSelector.js +16 -39
- package/es/TagSelector/ValueButton.js +8 -13
- package/es/TagSelector/ariaMessages.js +17 -29
- package/es/TagSelector/index.js +1 -1
- package/es/TagSelector/types.js +1 -0
- package/es/ToolboxPage/ToolboxInfo.js +9 -15
- package/es/ToolboxPage/index.js +1 -0
- package/es/Topic/Loader.js +2 -4
- package/es/Topic/Topic.js +17 -41
- package/es/Topic/index.js +2 -1
- package/es/TopicIntroductionList/TopicIntroduction.js +13 -15
- package/es/TopicIntroductionList/TopicIntroductionList.js +16 -24
- package/es/TopicIntroductionList/TopicIntroductionShortcuts.js +19 -41
- package/es/TopicIntroductionList/TopicShortcutItem.js +10 -18
- package/es/TopicIntroductionList/index.js +1 -0
- package/es/TopicMenu/SubtopicLinkList.js +37 -66
- package/es/TopicMenu/TopicMenu.js +41 -68
- package/es/TopicMenu/TopicMenuButton.js +8 -15
- package/es/TopicMenu/index.js +1 -0
- package/es/Translation/Translation.js +6 -11
- package/es/Translation/TranslationBox.js +1 -3
- package/es/Translation/TranslationLine.js +10 -18
- package/es/TreeStructure/AddFolderButton.js +7 -16
- package/es/TreeStructure/ComboboxButton.js +14 -25
- package/es/TreeStructure/FolderItem.js +24 -46
- package/es/TreeStructure/FolderItems.js +19 -28
- package/es/TreeStructure/NavigationLink.js +19 -21
- package/es/TreeStructure/TreeStructure.js +33 -72
- package/es/TreeStructure/arrowNavigation.js +1 -8
- package/es/TreeStructure/helperFunctions.js +5 -11
- package/es/TreeStructure/index.js +1 -0
- package/es/TreeStructure/types.js +1 -0
- package/es/User/AuthModal.js +14 -26
- package/es/User/UserInfo.js +15 -23
- package/es/User/apiTypes.js +1 -0
- package/es/User/index.js +1 -0
- package/es/User/parseUserObject.js +21 -35
- package/es/all.css +1 -1
- package/es/i18n/formatMessage.js +4 -6
- package/es/i18n/formatNestedMessages.js +4 -5
- package/es/i18n/i18n.js +1 -0
- package/es/i18n/index.js +1 -0
- package/es/index-javascript.js +1 -0
- package/es/index.js +1 -0
- package/es/internal-icons/Book.js +2 -4
- package/es/internal-icons/Download.js +2 -4
- package/es/internal-icons/Embed.js +2 -4
- package/es/internal-icons/InsertTemplate.js +2 -4
- package/es/internal-icons/OpenWindow.js +2 -4
- package/es/locale/LocaleProvider.js +6 -11
- package/es/locale/messages-en.js +5 -11
- package/es/locale/messages-nb.js +5 -11
- package/es/locale/messages-nn.js +5 -11
- package/es/locale/messages-se.js +5 -11
- package/es/locale/messages-sma.js +5 -11
- package/es/model/ContentType.js +1 -2
- package/es/model/SubjectCategories.js +1 -0
- package/es/model/SubjectTypes.js +1 -0
- package/es/model/index.js +1 -0
- package/es/shapes.js +1 -0
- package/es/types.js +3 -1
- package/es/utils/createUniversalPortal.js +3 -4
- package/es/utils/resourceTypeColor.js +1 -9
- package/lib/Animation/DisplayOnPageYOffset.js +10 -41
- package/lib/Animation/Fade.js +11 -25
- package/lib/Animation/index.js +0 -3
- package/lib/Article/Article.js +51 -103
- package/lib/Article/ArticleAccessMessage.js +4 -17
- package/lib/Article/ArticleByline.js +16 -42
- package/lib/Article/ArticleContent.js +9 -25
- package/lib/Article/ArticleFootNotes.js +2 -8
- package/lib/Article/ArticleHeaderWrapper.js +14 -51
- package/lib/Article/ArticleNotions.js +10 -26
- package/lib/Article/ArticleSideBar.js +16 -44
- package/lib/Article/index.js +19 -30
- package/lib/Aside/Aside.js +8 -19
- package/lib/Aside/index.js +0 -3
- package/lib/AudioPlayer/AudioPlayer.js +18 -52
- package/lib/AudioPlayer/Controls.js +29 -71
- package/lib/AudioPlayer/SpeechControl.js +6 -20
- package/lib/AudioPlayer/index.js +1 -5
- package/lib/AudioPlayer/initAudioPlayers.js +2 -15
- package/lib/AuthorInfo/AuthorInfo.js +6 -15
- package/lib/AuthorInfo/index.js +0 -3
- package/lib/BannerCard/BannerCard.js +6 -15
- package/lib/BannerCard/index.js +0 -2
- package/lib/BlogPosts/BlogPost.js +12 -24
- package/lib/BlogPosts/BlogPostWrapper.js +3 -10
- package/lib/BlogPosts/index.js +4 -7
- package/lib/Breadcrumb/ActionBreadcrumb.js +9 -19
- package/lib/Breadcrumb/Breadcrumb.js +25 -51
- package/lib/Breadcrumb/BreadcrumbItem.js +10 -25
- package/lib/Breadcrumb/HeaderBreadcrumb.js +9 -16
- package/lib/Breadcrumb/HomeBreadcrumb.js +2 -21
- package/lib/Breadcrumb/index.js +6 -12
- package/lib/Breadcrumblist/Breadcrumblist.js +29 -69
- package/lib/Breadcrumblist/index.js +0 -3
- package/lib/CompetenceGoalTab/CompetenceGoalItem.js +4 -17
- package/lib/CompetenceGoalTab/CompetenceGoalTab.js +12 -39
- package/lib/CompetenceGoalTab/CompetenceItem.js +5 -22
- package/lib/CompetenceGoalTab/SearchButton.js +5 -14
- package/lib/CompetenceGoalTab/index.js +0 -3
- package/lib/CompetenceGoals/CompetenceGoalsDialog.js +11 -31
- package/lib/CompetenceGoals/index.js +0 -2
- package/lib/ComponentCursor/ComponentCursor.js +11 -37
- package/lib/ComponentCursor/index.js +0 -3
- package/lib/ContentCard/ContentCard.js +10 -23
- package/lib/ContentCard/index.js +0 -3
- package/lib/ContentLoader/index.js +20 -31
- package/lib/ContentPlaceholder/ContentPlaceholder.js +1 -10
- package/lib/ContentPlaceholder/index.js +0 -3
- package/lib/ContentTypeBadge/ContentTypeBadge.js +13 -61
- package/lib/ContentTypeBadge/index.js +14 -16
- package/lib/CopyParagraphButton/CopyParagraphButton.js +15 -44
- package/lib/CopyParagraphButton/index.js +1 -5
- package/lib/CopyParagraphButton/initCopyParagraphButtons.js +2 -11
- package/lib/CreatedBy/CreatedBy.js +5 -16
- package/lib/CreatedBy/index.js +0 -3
- package/lib/Dialog/Dialog.js +18 -33
- package/lib/Dialog/index.js +0 -2
- package/lib/ErrorMessage/ErrorMessage.js +6 -15
- package/lib/ErrorMessage/ErrorResourceAccessDenied.js +3 -16
- package/lib/ErrorMessage/index.js +0 -4
- package/lib/FactBox/FactBox.js +5 -21
- package/lib/FactBox/index.js +0 -3
- package/lib/Figure/Figure.js +75 -99
- package/lib/Figure/FigureBylineExpandButton.js +3 -8
- package/lib/Figure/FigureExpandButton.js +3 -8
- package/lib/Figure/FigureLicense.js +10 -24
- package/lib/Figure/FigureLicenseDialog.js +10 -20
- package/lib/Figure/FigureOpenDialogButton.js +3 -9
- package/lib/Figure/index.js +9 -17
- package/lib/FileList/File.js +2 -18
- package/lib/FileList/FileList.js +3 -13
- package/lib/FileList/index.js +0 -4
- package/lib/Filter/FilterButtons.js +13 -42
- package/lib/Filter/FilterCarousel.js +16 -52
- package/lib/Filter/FilterList.js +27 -61
- package/lib/Filter/FilterListPhone.js +36 -84
- package/lib/Filter/ToggleItem.js +14 -23
- package/lib/Filter/filterClasses.js +1 -3
- package/lib/Filter/index.js +6 -12
- package/lib/Footer/EditorName.js +3 -7
- package/lib/Footer/Footer.js +6 -22
- package/lib/Footer/FooterAuth.js +8 -27
- package/lib/Footer/FooterLinks.js +2 -16
- package/lib/Footer/FooterPrivacy.js +6 -24
- package/lib/Footer/FooterText.js +2 -9
- package/lib/Footer/index.js +8 -13
- package/lib/Footer/privacy_en.js +1 -6
- package/lib/Footer/privacy_nb.js +1 -6
- package/lib/Footer/privacy_nn.js +1 -6
- package/lib/Frontpage/FrontpageAllSubjects.js +12 -44
- package/lib/Frontpage/FrontpageFilm.js +3 -18
- package/lib/Frontpage/FrontpageHeader.js +4 -15
- package/lib/Frontpage/FrontpageInfo.js +1 -9
- package/lib/Frontpage/FrontpageMultidisciplinarySubject.js +7 -26
- package/lib/Frontpage/FrontpageProgramMenu.js +12 -38
- package/lib/Frontpage/FrontpageSearch.js +23 -53
- package/lib/Frontpage/FrontpageToolbox.js +3 -18
- package/lib/Frontpage/illustrations/Fellesfag.js +2 -6
- package/lib/Frontpage/illustrations/FrontpageHeaderIllustration.js +2 -6
- package/lib/Frontpage/illustrations/FrontpageIllustrations.js +1 -6
- package/lib/Frontpage/illustrations/FrontpageSubjectIllustration.js +1 -9
- package/lib/Frontpage/illustrations/MenuFellesfag.js +2 -6
- package/lib/Frontpage/illustrations/MenuStudiespesialiserende.js +2 -6
- package/lib/Frontpage/illustrations/MenuYrkesfag.js +2 -6
- package/lib/Frontpage/illustrations/Studiespesialiserende.js +2 -6
- package/lib/Frontpage/illustrations/Yrkesfag.js +2 -6
- package/lib/Frontpage/illustrations/index.js +10 -19
- package/lib/Frontpage/index.js +26 -36
- package/lib/Frontpage/sortCategories.js +1 -4
- package/lib/Hero/Hero.js +10 -40
- package/lib/Hero/index.js +16 -17
- package/lib/Image/Image.js +17 -38
- package/lib/Image/ImageLink.js +7 -20
- package/lib/Image/LazyLoadImage.js +9 -19
- package/lib/Image/index.js +8 -14
- package/lib/InfoBlock/InfoBlock.js +3 -12
- package/lib/InfoBlock/index.js +0 -1
- package/lib/InfoBox/InfoBox.js +1 -9
- package/lib/InfoBox/index.js +0 -2
- package/lib/InfoWidget/InfoWidget.js +6 -21
- package/lib/InfoWidget/index.js +0 -3
- package/lib/LanguageSelector/LanguageSelector.js +18 -47
- package/lib/LanguageSelector/LanguageSelectorContent.js +12 -14
- package/lib/LanguageSelector/index.js +0 -2
- package/lib/Layout/Content.js +2 -7
- package/lib/Layout/LayoutItem.js +3 -12
- package/lib/Layout/OneColumn.js +7 -19
- package/lib/Layout/PageContainer.js +11 -22
- package/lib/Layout/index.js +6 -12
- package/lib/LearningPaths/LearningPathContent.js +2 -9
- package/lib/LearningPaths/LearningPathInformation.js +7 -17
- package/lib/LearningPaths/LearningPathLastStepNavigation.js +5 -20
- package/lib/LearningPaths/LearningPathMenu.js +20 -50
- package/lib/LearningPaths/LearningPathMenuAside.js +7 -21
- package/lib/LearningPaths/LearningPathMenuAsideCopyright.js +3 -14
- package/lib/LearningPaths/LearningPathMenuContent.js +11 -27
- package/lib/LearningPaths/LearningPathMenuIntro.js +5 -20
- package/lib/LearningPaths/LearningPathMenuModalWrapper.js +7 -24
- package/lib/LearningPaths/LearningPathMobileHeader.js +9 -12
- package/lib/LearningPaths/LearningPathMobileStepInfo.js +4 -14
- package/lib/LearningPaths/LearningPathSticky.js +7 -22
- package/lib/LearningPaths/LearningPathWrapper.js +3 -11
- package/lib/LearningPaths/index.js +18 -27
- package/lib/Logo/Logo.js +12 -26
- package/lib/Logo/SvgLogo.js +7 -18
- package/lib/Logo/index.js +0 -3
- package/lib/Masthead/Masthead.js +16 -37
- package/lib/Masthead/MastheadAuthModal.js +6 -24
- package/lib/Masthead/MastheadSearchModal.js +5 -22
- package/lib/Masthead/SkipToMainContent.js +2 -13
- package/lib/Masthead/index.js +10 -18
- package/lib/Masthead/utils.js +7 -23
- package/lib/MediaList/MediaList.js +16 -44
- package/lib/MediaList/index.js +4 -5
- package/lib/Messages/MessageBanner.js +4 -15
- package/lib/Messages/MessageBox.js +6 -23
- package/lib/Messages/MessageBoxTag.js +2 -13
- package/lib/Messages/index.js +4 -8
- package/lib/MultidisciplinarySubject/Illustrations.js +1 -5
- package/lib/MultidisciplinarySubject/List.js +4 -17
- package/lib/MultidisciplinarySubject/ListItem.js +8 -18
- package/lib/MultidisciplinarySubject/MultidisciplinarySubject.js +9 -26
- package/lib/MultidisciplinarySubject/MultidisciplinarySubjectHeader.js +5 -24
- package/lib/MultidisciplinarySubject/index.js +0 -4
- package/lib/MyNdla/Resource/Folder.js +15 -45
- package/lib/MyNdla/Resource/FolderInput.js +17 -41
- package/lib/MyNdla/Resource/index.js +0 -3
- package/lib/MyNdla/index.js +0 -3
- package/lib/NDLAFilm/AboutNdlaFilm.js +6 -24
- package/lib/NDLAFilm/AllMoviesAlphabetically.js +13 -53
- package/lib/NDLAFilm/CategorySelect.js +14 -53
- package/lib/NDLAFilm/FilmContentCard.js +12 -24
- package/lib/NDLAFilm/FilmContentCardTags.js +2 -11
- package/lib/NDLAFilm/FilmMovieList.js +11 -25
- package/lib/NDLAFilm/FilmMovieSearch.js +9 -23
- package/lib/NDLAFilm/FilmSlideshow.js +24 -86
- package/lib/NDLAFilm/MovieGrid.js +8 -21
- package/lib/NDLAFilm/NavigationArrow.js +4 -13
- package/lib/NDLAFilm/SlideshowIndicator.js +4 -11
- package/lib/NDLAFilm/VisualElement.js +3 -13
- package/lib/NDLAFilm/filmStyles.js +1 -8
- package/lib/NDLAFilm/index.js +10 -17
- package/lib/NDLAFilm/isLetter.js +1 -2
- package/lib/NDLAFilm/types.js +5 -1
- package/lib/Navigation/NavigationBox.js +15 -40
- package/lib/Navigation/NavigationHeading.js +4 -15
- package/lib/Navigation/NavigationTopicAbout.js +10 -36
- package/lib/Navigation/index.js +0 -4
- package/lib/NoContentBox/NoContentBox.js +4 -9
- package/lib/NoContentBox/index.js +0 -3
- package/lib/Notion/ConceptNotion.js +13 -43
- package/lib/Notion/FigureNotion.js +18 -38
- package/lib/Notion/Notion.js +12 -28
- package/lib/Notion/NotionImage.js +6 -18
- package/lib/Notion/NotionVisualElement.js +4 -21
- package/lib/Notion/index.js +0 -4
- package/lib/Portrait/Portrait.js +11 -10
- package/lib/Portrait/index.js +0 -3
- package/lib/Programme/Programme.js +11 -30
- package/lib/Programme/ProgrammeSubjects.js +7 -21
- package/lib/Programme/index.js +0 -4
- package/lib/RadioButtonGroup/RadioButtonGroup.js +10 -42
- package/lib/RadioButtonGroup/index.js +0 -3
- package/lib/RelatedArticleList/RelatedArticleList.js +17 -37
- package/lib/RelatedArticleList/index.js +3 -8
- package/lib/Resource/BlockResource.js +19 -47
- package/lib/Resource/ListResource.js +22 -53
- package/lib/Resource/index.js +6 -15
- package/lib/Resource/resourceComponents.js +7 -32
- package/lib/ResourceBox/ResourceBox.js +6 -19
- package/lib/ResourceBox/index.js +0 -2
- package/lib/ResourceGroup/ResourceGroup.js +8 -16
- package/lib/ResourceGroup/ResourceItem.js +18 -56
- package/lib/ResourceGroup/ResourceList.js +13 -41
- package/lib/ResourceGroup/index.js +0 -3
- package/lib/ResourcesWrapper/ResourcesTitle.js +3 -13
- package/lib/ResourcesWrapper/ResourcesTopicTitle.js +14 -41
- package/lib/ResourcesWrapper/ResourcesWrapper.js +7 -17
- package/lib/ResourcesWrapper/index.js +0 -5
- package/lib/Search/ActiveFilterContent.js +3 -12
- package/lib/Search/ActiveFilters.js +7 -29
- package/lib/Search/ContentTypeResult.js +27 -58
- package/lib/Search/ContentTypeResultStyles.js +1 -6
- package/lib/Search/IsPathToHighlight.js +0 -2
- package/lib/Search/LoadingWrapper.js +1 -10
- package/lib/Search/SearchField.js +16 -39
- package/lib/Search/SearchFieldForm.js +3 -12
- package/lib/Search/SearchResult.js +11 -45
- package/lib/Search/SearchResultSleeve.js +22 -66
- package/lib/Search/ToggleSearchButton.js +8 -23
- package/lib/Search/index.js +6 -11
- package/lib/SearchTypeResult/ActiveFilterContent.js +3 -17
- package/lib/SearchTypeResult/ActiveFilters.js +9 -30
- package/lib/SearchTypeResult/PopupFilter.js +16 -42
- package/lib/SearchTypeResult/ResultNavigation.js +7 -20
- package/lib/SearchTypeResult/SearchFieldHeader.js +14 -41
- package/lib/SearchTypeResult/SearchFilterContent.js +6 -20
- package/lib/SearchTypeResult/SearchHeader.js +20 -48
- package/lib/SearchTypeResult/SearchItem.js +10 -25
- package/lib/SearchTypeResult/SearchItemList.js +14 -34
- package/lib/SearchTypeResult/SearchItems.js +7 -22
- package/lib/SearchTypeResult/SearchNotionItem.js +17 -41
- package/lib/SearchTypeResult/SearchNotionsResult.js +5 -16
- package/lib/SearchTypeResult/SearchSubjectItem.js +5 -18
- package/lib/SearchTypeResult/SearchSubjectResult.js +2 -10
- package/lib/SearchTypeResult/SearchTypeHeader.js +9 -29
- package/lib/SearchTypeResult/SearchTypeResult.js +15 -34
- package/lib/SearchTypeResult/SearchViewType.js +3 -19
- package/lib/SearchTypeResult/components/ItemContexts.js +8 -29
- package/lib/SearchTypeResult/components/ItemResourceHeader.js +8 -25
- package/lib/SearchTypeResult/components/ItemTopicHeader.js +4 -17
- package/lib/SearchTypeResult/components/SubjectFilters.js +21 -70
- package/lib/SearchTypeResult/index.js +8 -15
- package/lib/SectionHeading/SectionHeading.js +4 -13
- package/lib/SectionHeading/index.js +0 -3
- package/lib/SnackBar/DefaultSnackbar.js +6 -20
- package/lib/SnackBar/SnackbarProvider.js +18 -55
- package/lib/SnackBar/index.js +8 -11
- package/lib/Subject/Subject.js +8 -32
- package/lib/Subject/SubjectAbout.js +7 -17
- package/lib/Subject/SubjectArchive.js +16 -55
- package/lib/Subject/SubjectBanner.js +2 -10
- package/lib/Subject/SubjectCarousel.js +16 -37
- package/lib/Subject/SubjectHeader.js +3 -13
- package/lib/Subject/SubjectLinks.js +4 -18
- package/lib/Subject/SubjectNewContent.js +2 -14
- package/lib/Subject/SubjectShortcuts.js +13 -51
- package/lib/Subject/SubjectSocial.js +3 -14
- package/lib/Subject/index.js +34 -45
- package/lib/Table/Table.js +7 -22
- package/lib/Table/index.js +0 -3
- package/lib/TagSelector/Control.js +5 -16
- package/lib/TagSelector/DropdownIndicator.js +10 -31
- package/lib/TagSelector/Input.js +3 -16
- package/lib/TagSelector/Menu.js +5 -20
- package/lib/TagSelector/MenuList.js +5 -16
- package/lib/TagSelector/Option.js +7 -20
- package/lib/TagSelector/SelectContainer.js +5 -16
- package/lib/TagSelector/TagSelector.js +17 -58
- package/lib/TagSelector/ValueButton.js +6 -19
- package/lib/TagSelector/ariaMessages.js +17 -31
- package/lib/TagSelector/index.js +0 -4
- package/lib/TagSelector/types.js +5 -1
- package/lib/ToolboxPage/ToolboxInfo.js +7 -18
- package/lib/ToolboxPage/index.js +0 -2
- package/lib/Topic/Loader.js +1 -7
- package/lib/Topic/Topic.js +17 -50
- package/lib/Topic/index.js +2 -9
- package/lib/TopicIntroductionList/TopicIntroduction.js +12 -25
- package/lib/TopicIntroductionList/TopicIntroductionList.js +14 -30
- package/lib/TopicIntroductionList/TopicIntroductionShortcuts.js +26 -59
- package/lib/TopicIntroductionList/TopicShortcutItem.js +9 -25
- package/lib/TopicIntroductionList/index.js +0 -3
- package/lib/TopicMenu/SubtopicLinkList.js +42 -87
- package/lib/TopicMenu/TopicMenu.js +48 -104
- package/lib/TopicMenu/TopicMenuButton.js +6 -22
- package/lib/TopicMenu/index.js +0 -4
- package/lib/Translation/Translation.js +4 -14
- package/lib/Translation/TranslationBox.js +1 -7
- package/lib/Translation/TranslationLine.js +7 -19
- package/lib/Translation/index.js +0 -4
- package/lib/TreeStructure/AddFolderButton.js +8 -27
- package/lib/TreeStructure/ComboboxButton.js +16 -37
- package/lib/TreeStructure/FolderItem.js +25 -59
- package/lib/TreeStructure/FolderItems.js +16 -32
- package/lib/TreeStructure/NavigationLink.js +14 -32
- package/lib/TreeStructure/TreeStructure.js +34 -83
- package/lib/TreeStructure/arrowNavigation.js +1 -11
- package/lib/TreeStructure/helperFunctions.js +5 -15
- package/lib/TreeStructure/index.js +0 -2
- package/lib/TreeStructure/types.js +5 -1
- package/lib/User/AuthModal.js +15 -34
- package/lib/User/UserInfo.js +8 -29
- package/lib/User/apiTypes.js +5 -1
- package/lib/User/index.js +0 -4
- package/lib/User/parseUserObject.js +20 -37
- package/lib/all.css +1 -1
- package/lib/i18n/formatMessage.js +4 -10
- package/lib/i18n/formatNestedMessages.js +4 -7
- package/lib/i18n/i18n.js +1 -11
- package/lib/i18n/index.js +4 -7
- package/lib/index-javascript.js +3 -7
- package/lib/index.js +394 -474
- package/lib/internal-icons/Book.js +2 -7
- package/lib/internal-icons/Download.js +2 -7
- package/lib/internal-icons/Embed.js +2 -7
- package/lib/internal-icons/InsertTemplate.js +2 -7
- package/lib/internal-icons/OpenWindow.js +2 -7
- package/lib/locale/LocaleProvider.js +5 -14
- package/lib/locale/messages-en.d.ts +0 -1
- package/lib/locale/messages-en.js +5 -16
- package/lib/locale/messages-nb.d.ts +0 -1
- package/lib/locale/messages-nb.js +5 -16
- package/lib/locale/messages-nn.d.ts +0 -1
- package/lib/locale/messages-nn.js +5 -16
- package/lib/locale/messages-se.d.ts +0 -1
- package/lib/locale/messages-se.js +5 -16
- package/lib/locale/messages-sma.d.ts +0 -1
- package/lib/locale/messages-sma.js +5 -16
- package/lib/model/ContentType.js +2 -4
- package/lib/model/SubjectCategories.js +2 -2
- package/lib/model/SubjectTypes.js +2 -2
- package/lib/model/index.js +4 -10
- package/lib/shapes.js +5 -32
- package/lib/types.js +4 -0
- package/lib/utils/createUniversalPortal.js +3 -7
- package/lib/utils/resourceTypeColor.js +2 -16
- package/package.json +6 -6
- package/src/FactBox/component.factbox.scss +1 -1
- package/src/Figure/Figure.tsx +44 -46
- package/src/Figure/component.figure.scss +7 -0
- package/src/MyNdla/Resource/FolderInput.tsx +1 -0
- package/src/TopicMenu/TopicMenu.jsx +2 -2
- package/src/User/UserInfo.tsx +0 -2
- package/src/locale/messages-en.ts +0 -1
- package/src/locale/messages-nb.ts +0 -1
- package/src/locale/messages-nn.ts +0 -1
- package/src/locale/messages-se.ts +0 -1
- package/src/locale/messages-sma.ts +0 -1
package/es/i18n/formatMessage.js
CHANGED
|
@@ -5,21 +5,21 @@
|
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*
|
|
7
7
|
*/
|
|
8
|
+
|
|
8
9
|
import invariant from 'invariant';
|
|
9
10
|
export var formatMessage = function formatMessage(locale, messages, getMessageFormat, id) {
|
|
10
11
|
var values = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : {};
|
|
11
12
|
// `id` is a required parameter.
|
|
12
13
|
invariant(id, 'An `id` must be provided to format a message.');
|
|
13
14
|
var message = messages && messages[id];
|
|
14
|
-
var hasValues = Object.keys(values).length > 0;
|
|
15
|
-
// development messages will always be formatted in case of missing values.
|
|
15
|
+
var hasValues = Object.keys(values).length > 0;
|
|
16
16
|
|
|
17
|
+
// Avoid expensive message formatting for simple messages without values. In
|
|
18
|
+
// development messages will always be formatted in case of missing values.
|
|
17
19
|
if (!hasValues && process.env.NODE_ENV === 'production') {
|
|
18
20
|
return message || id;
|
|
19
21
|
}
|
|
20
|
-
|
|
21
22
|
var formattedMessage;
|
|
22
|
-
|
|
23
23
|
if (message) {
|
|
24
24
|
try {
|
|
25
25
|
var formatter = getMessageFormat(message, locale, {});
|
|
@@ -35,13 +35,11 @@ export var formatMessage = function formatMessage(locale, messages, getMessageFo
|
|
|
35
35
|
console.error("Missing message: \"".concat(id, "\" for locale: \"").concat(locale, "\", using id as fallback"));
|
|
36
36
|
return id;
|
|
37
37
|
}
|
|
38
|
-
|
|
39
38
|
if (!formattedMessage) {
|
|
40
39
|
if (process.env.NODE_ENV !== 'production') {
|
|
41
40
|
// eslint-disable-next-line no-console
|
|
42
41
|
console.error("Cannot format message: \"".concat(id, "\", using message source as fallback."));
|
|
43
42
|
}
|
|
44
43
|
}
|
|
45
|
-
|
|
46
44
|
return formattedMessage || message || id;
|
|
47
45
|
};
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
function _typeof(obj) { "@babel/helpers - typeof";
|
|
2
|
-
|
|
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); }
|
|
3
2
|
/**
|
|
4
3
|
* Copyright (c) 2017-present, NDLA.
|
|
5
4
|
*
|
|
@@ -7,17 +6,17 @@ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "functi
|
|
|
7
6
|
* LICENSE file in the root directory of this source tree.
|
|
8
7
|
*
|
|
9
8
|
*/
|
|
9
|
+
|
|
10
10
|
export var formatNestedMessages = function formatNestedMessages(phrases) {
|
|
11
11
|
var formattedMessages = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
12
12
|
var prefix = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : '';
|
|
13
|
-
var messages = formattedMessages;
|
|
13
|
+
var messages = formattedMessages;
|
|
14
14
|
|
|
15
|
+
// eslint-disable-next-line
|
|
15
16
|
Object.keys(phrases).forEach(function (key) {
|
|
16
17
|
var value = phrases[key];
|
|
17
|
-
|
|
18
18
|
if ({}.hasOwnProperty.call(phrases, key)) {
|
|
19
19
|
var keyWithPrefix = prefix ? "".concat(prefix, ".").concat(key) : key;
|
|
20
|
-
|
|
21
20
|
if (_typeof(value) === 'object') {
|
|
22
21
|
formatNestedMessages(value, formattedMessages, keyWithPrefix);
|
|
23
22
|
} else {
|
package/es/i18n/i18n.js
CHANGED
package/es/i18n/index.js
CHANGED
package/es/index-javascript.js
CHANGED
package/es/index.js
CHANGED
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
2
|
-
|
|
3
1
|
/**
|
|
4
2
|
* Copyright (c) 2016-present, NDLA.
|
|
5
3
|
*
|
|
@@ -7,9 +5,10 @@ import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
|
7
5
|
* LICENSE file in the root directory of this source tree.
|
|
8
6
|
*
|
|
9
7
|
*/
|
|
8
|
+
|
|
10
9
|
import React from 'react';
|
|
11
10
|
import PropTypes from 'prop-types';
|
|
12
|
-
|
|
11
|
+
import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
13
12
|
var Book = function Book(_ref) {
|
|
14
13
|
var className = _ref.className;
|
|
15
14
|
return _jsx("svg", {
|
|
@@ -24,7 +23,6 @@ var Book = function Book(_ref) {
|
|
|
24
23
|
})
|
|
25
24
|
});
|
|
26
25
|
};
|
|
27
|
-
|
|
28
26
|
Book.propTypes = {
|
|
29
27
|
className: PropTypes.string.isRequired
|
|
30
28
|
};
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
2
|
-
|
|
3
1
|
/**
|
|
4
2
|
* Copyright (c) 2016-present, NDLA.
|
|
5
3
|
*
|
|
@@ -7,9 +5,10 @@ import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
|
7
5
|
* LICENSE file in the root directory of this source tree.
|
|
8
6
|
*
|
|
9
7
|
*/
|
|
8
|
+
|
|
10
9
|
import React from 'react';
|
|
11
10
|
import PropTypes from 'prop-types';
|
|
12
|
-
|
|
11
|
+
import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
13
12
|
var Download = function Download(_ref) {
|
|
14
13
|
var className = _ref.className;
|
|
15
14
|
return _jsx("svg", {
|
|
@@ -23,7 +22,6 @@ var Download = function Download(_ref) {
|
|
|
23
22
|
})
|
|
24
23
|
});
|
|
25
24
|
};
|
|
26
|
-
|
|
27
25
|
Download.propTypes = {
|
|
28
26
|
className: PropTypes.string.isRequired
|
|
29
27
|
};
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
2
|
-
|
|
3
1
|
/**
|
|
4
2
|
* Copyright (c) 2016-present, NDLA.
|
|
5
3
|
*
|
|
@@ -7,9 +5,10 @@ import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
|
7
5
|
* LICENSE file in the root directory of this source tree.
|
|
8
6
|
*
|
|
9
7
|
*/
|
|
8
|
+
|
|
10
9
|
import React from 'react';
|
|
11
10
|
import PropTypes from 'prop-types';
|
|
12
|
-
|
|
11
|
+
import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
13
12
|
var Embed = function Embed(_ref) {
|
|
14
13
|
var className = _ref.className;
|
|
15
14
|
return _jsx("svg", {
|
|
@@ -21,7 +20,6 @@ var Embed = function Embed(_ref) {
|
|
|
21
20
|
})
|
|
22
21
|
});
|
|
23
22
|
};
|
|
24
|
-
|
|
25
23
|
Embed.propTypes = {
|
|
26
24
|
className: PropTypes.string.isRequired
|
|
27
25
|
};
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
2
|
-
|
|
3
1
|
/**
|
|
4
2
|
* Copyright (c) 2016-present, NDLA.
|
|
5
3
|
*
|
|
@@ -7,9 +5,10 @@ import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
|
7
5
|
* LICENSE file in the root directory of this source tree.
|
|
8
6
|
*
|
|
9
7
|
*/
|
|
8
|
+
|
|
10
9
|
import React from 'react';
|
|
11
10
|
import PropTypes from 'prop-types';
|
|
12
|
-
|
|
11
|
+
import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
13
12
|
var InsertTemplate = function InsertTemplate(_ref) {
|
|
14
13
|
var className = _ref.className;
|
|
15
14
|
return _jsx("svg", {
|
|
@@ -24,7 +23,6 @@ var InsertTemplate = function InsertTemplate(_ref) {
|
|
|
24
23
|
})
|
|
25
24
|
});
|
|
26
25
|
};
|
|
27
|
-
|
|
28
26
|
InsertTemplate.propTypes = {
|
|
29
27
|
className: PropTypes.string.isRequired
|
|
30
28
|
};
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
2
|
-
|
|
3
1
|
/**
|
|
4
2
|
* Copyright (c) 2016-present, NDLA.
|
|
5
3
|
*
|
|
@@ -7,9 +5,10 @@ import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
|
7
5
|
* LICENSE file in the root directory of this source tree.
|
|
8
6
|
*
|
|
9
7
|
*/
|
|
8
|
+
|
|
10
9
|
import React from 'react';
|
|
11
10
|
import PropTypes from 'prop-types';
|
|
12
|
-
|
|
11
|
+
import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
13
12
|
var OpenWindow = function OpenWindow(_ref) {
|
|
14
13
|
var className = _ref.className;
|
|
15
14
|
return _jsx("svg", {
|
|
@@ -21,7 +20,6 @@ var OpenWindow = function OpenWindow(_ref) {
|
|
|
21
20
|
})
|
|
22
21
|
});
|
|
23
22
|
};
|
|
24
|
-
|
|
25
23
|
OpenWindow.propTypes = {
|
|
26
24
|
className: PropTypes.string.isRequired
|
|
27
25
|
};
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
2
|
-
import { Fragment as _Fragment } from "@emotion/react/jsx-runtime";
|
|
3
|
-
|
|
4
1
|
/**
|
|
5
2
|
* Copyright (c) 2021-present, NDLA.
|
|
6
3
|
*
|
|
@@ -8,26 +5,25 @@ import { Fragment as _Fragment } from "@emotion/react/jsx-runtime";
|
|
|
8
5
|
* LICENSE file in the root directory of this source tree.
|
|
9
6
|
*
|
|
10
7
|
*/
|
|
8
|
+
|
|
11
9
|
import React from 'react';
|
|
12
10
|
import { I18nextProvider, useTranslation } from 'react-i18next';
|
|
13
11
|
import { i18nInstance } from '../i18n';
|
|
14
|
-
|
|
12
|
+
import { Fragment as _Fragment } from "@emotion/react/jsx-runtime";
|
|
13
|
+
import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
15
14
|
var InitI18nWrapper = function InitI18nWrapper(_ref) {
|
|
16
15
|
var locale = _ref.locale,
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
children = _ref.children;
|
|
19
17
|
var _useTranslation = useTranslation(),
|
|
20
|
-
|
|
21
|
-
|
|
18
|
+
i18n = _useTranslation.i18n;
|
|
22
19
|
i18n.language = locale;
|
|
23
20
|
return _jsx(_Fragment, {
|
|
24
21
|
children: children
|
|
25
22
|
});
|
|
26
23
|
};
|
|
27
|
-
|
|
28
24
|
var LocaleProvider = function LocaleProvider(_ref2) {
|
|
29
25
|
var locale = _ref2.locale,
|
|
30
|
-
|
|
26
|
+
children = _ref2.children;
|
|
31
27
|
return _jsx(I18nextProvider, {
|
|
32
28
|
i18n: i18nInstance,
|
|
33
29
|
children: _jsx(InitI18nWrapper, {
|
|
@@ -36,5 +32,4 @@ var LocaleProvider = function LocaleProvider(_ref2) {
|
|
|
36
32
|
})
|
|
37
33
|
});
|
|
38
34
|
};
|
|
39
|
-
|
|
40
35
|
export default LocaleProvider;
|
package/es/locale/messages-en.js
CHANGED
|
@@ -1,11 +1,7 @@
|
|
|
1
1
|
var _subjectCategories, _subjectTypes, _contentTypeResultsSh, _contentTypeResultsSh2, _contentTypeResultsNo;
|
|
2
|
-
|
|
3
|
-
function
|
|
4
|
-
|
|
5
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
6
|
-
|
|
2
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
3
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
7
4
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
8
|
-
|
|
9
5
|
/**
|
|
10
6
|
* Copyright (c) 2018-present, NDLA.
|
|
11
7
|
*
|
|
@@ -13,14 +9,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
13
9
|
* LICENSE file in the root directory of this source tree.
|
|
14
10
|
*
|
|
15
11
|
*/
|
|
12
|
+
|
|
16
13
|
import { contributorTypes } from '@ndla/licenses';
|
|
17
14
|
import constants from '../model';
|
|
18
15
|
var contentTypes = constants.contentTypes,
|
|
19
|
-
|
|
20
|
-
|
|
16
|
+
subjectCategories = constants.subjectCategories,
|
|
17
|
+
subjectTypes = constants.subjectTypes;
|
|
21
18
|
export { contentTypes, subjectCategories, subjectTypes };
|
|
22
19
|
var titleTemplate = ' - NDLA';
|
|
23
|
-
|
|
24
20
|
var messages = _objectSpread(_objectSpread({
|
|
25
21
|
treeStructure: {
|
|
26
22
|
folderChildOptions: {
|
|
@@ -959,7 +955,6 @@ var messages = _objectSpread(_objectSpread({
|
|
|
959
955
|
buttonLogOut: 'Log out',
|
|
960
956
|
generalFooter: 'Some resources may only be accessed by teachers who are logged in.',
|
|
961
957
|
modal: {
|
|
962
|
-
collectedInfo: 'We have collected the following information about you from Feide:',
|
|
963
958
|
general: 'Resources that require logging in with Feide, are tagged with the icon',
|
|
964
959
|
topic: 'Log in with Feide to access this topic.',
|
|
965
960
|
isAuth: 'User info',
|
|
@@ -1111,5 +1106,4 @@ var messages = _objectSpread(_objectSpread({
|
|
|
1111
1106
|
help: 'Help'
|
|
1112
1107
|
}
|
|
1113
1108
|
});
|
|
1114
|
-
|
|
1115
1109
|
export default messages;
|
package/es/locale/messages-nb.js
CHANGED
|
@@ -1,11 +1,7 @@
|
|
|
1
1
|
var _subjectCategories, _subjectTypes, _contentTypeResultsSh, _contentTypeResultsSh2, _contentTypeResultsNo;
|
|
2
|
-
|
|
3
|
-
function
|
|
4
|
-
|
|
5
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
6
|
-
|
|
2
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
3
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
7
4
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
8
|
-
|
|
9
5
|
/**
|
|
10
6
|
* Copyright (c) 2018-present, NDLA.
|
|
11
7
|
*
|
|
@@ -13,14 +9,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
13
9
|
* LICENSE file in the root directory of this source tree.
|
|
14
10
|
*
|
|
15
11
|
*/
|
|
12
|
+
|
|
16
13
|
import { contributorTypes } from '@ndla/licenses';
|
|
17
14
|
import constants from '../model';
|
|
18
15
|
var contentTypes = constants.contentTypes,
|
|
19
|
-
|
|
20
|
-
|
|
16
|
+
subjectCategories = constants.subjectCategories,
|
|
17
|
+
subjectTypes = constants.subjectTypes;
|
|
21
18
|
export { contentTypes, subjectCategories, subjectTypes };
|
|
22
19
|
var titleTemplate = ' - NDLA';
|
|
23
|
-
|
|
24
20
|
var messages = _objectSpread(_objectSpread({
|
|
25
21
|
treeStructure: {
|
|
26
22
|
folderChildOptions: {
|
|
@@ -959,7 +955,6 @@ var messages = _objectSpread(_objectSpread({
|
|
|
959
955
|
buttonLogOut: 'Logg ut',
|
|
960
956
|
generalFooter: 'Enkelte ressurser er bare tilgjengelige for påloggede lærere.',
|
|
961
957
|
modal: {
|
|
962
|
-
collectedInfo: 'Vi har hentet følgende informasjon om deg fra Feide:',
|
|
963
958
|
general: 'Ressursene som krever pålogging med Feide, vises med ikonet',
|
|
964
959
|
topic: 'Logg inn med Feide for å få tilgang til dette emnet.',
|
|
965
960
|
isAuth: 'Brukerinfo',
|
|
@@ -1111,5 +1106,4 @@ var messages = _objectSpread(_objectSpread({
|
|
|
1111
1106
|
help: 'Hjelp'
|
|
1112
1107
|
}
|
|
1113
1108
|
});
|
|
1114
|
-
|
|
1115
1109
|
export default messages;
|
package/es/locale/messages-nn.js
CHANGED
|
@@ -1,11 +1,7 @@
|
|
|
1
1
|
var _subjectCategories, _subjectTypes, _contentTypeResultsSh, _contentTypeResultsSh2, _contentTypeResultsNo;
|
|
2
|
-
|
|
3
|
-
function
|
|
4
|
-
|
|
5
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
6
|
-
|
|
2
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
3
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
7
4
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
8
|
-
|
|
9
5
|
/**
|
|
10
6
|
* Copyright (c) 2018-present, NDLA.
|
|
11
7
|
*
|
|
@@ -13,14 +9,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
13
9
|
* LICENSE file in the root directory of this source tree.
|
|
14
10
|
*
|
|
15
11
|
*/
|
|
12
|
+
|
|
16
13
|
import { contributorTypes } from '@ndla/licenses';
|
|
17
14
|
import constants from '../model';
|
|
18
15
|
var contentTypes = constants.contentTypes,
|
|
19
|
-
|
|
20
|
-
|
|
16
|
+
subjectCategories = constants.subjectCategories,
|
|
17
|
+
subjectTypes = constants.subjectTypes;
|
|
21
18
|
export { contentTypes, subjectCategories, subjectTypes };
|
|
22
19
|
var titleTemplate = ' - NDLA';
|
|
23
|
-
|
|
24
20
|
var messages = _objectSpread(_objectSpread({
|
|
25
21
|
treeStructure: {
|
|
26
22
|
folderChildOptions: {
|
|
@@ -959,7 +955,6 @@ var messages = _objectSpread(_objectSpread({
|
|
|
959
955
|
buttonLogOut: 'Logg ut',
|
|
960
956
|
generalFooter: 'Enkelte ressursar er berre tilgjengelege for pålogga lærarar.',
|
|
961
957
|
modal: {
|
|
962
|
-
collectedInfo: 'Vi har henta denne informasjonen om deg frå Feide:',
|
|
963
958
|
general: 'Ressursane som krev pålogging med Feide, vises med ikonet',
|
|
964
959
|
topic: ' Logg inn med Feide for å få tilgang til dette emnet.',
|
|
965
960
|
isAuth: 'Brukarinfo',
|
|
@@ -1111,5 +1106,4 @@ var messages = _objectSpread(_objectSpread({
|
|
|
1111
1106
|
help: 'Hjelp'
|
|
1112
1107
|
}
|
|
1113
1108
|
});
|
|
1114
|
-
|
|
1115
1109
|
export default messages;
|
package/es/locale/messages-se.js
CHANGED
|
@@ -1,11 +1,7 @@
|
|
|
1
1
|
var _subjectCategories, _subjectTypes, _contentTypeResultsSh, _contentTypeResultsSh2, _contentTypeResultsNo;
|
|
2
|
-
|
|
3
|
-
function
|
|
4
|
-
|
|
5
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
6
|
-
|
|
2
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
3
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
7
4
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
8
|
-
|
|
9
5
|
/**
|
|
10
6
|
* Copyright (c) 2018-present, NDLA.
|
|
11
7
|
*
|
|
@@ -13,14 +9,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
13
9
|
* LICENSE file in the root directory of this source tree.
|
|
14
10
|
*
|
|
15
11
|
*/
|
|
12
|
+
|
|
16
13
|
import { contributorTypes } from '@ndla/licenses';
|
|
17
14
|
import constants from '../model';
|
|
18
15
|
var contentTypes = constants.contentTypes,
|
|
19
|
-
|
|
20
|
-
|
|
16
|
+
subjectCategories = constants.subjectCategories,
|
|
17
|
+
subjectTypes = constants.subjectTypes;
|
|
21
18
|
export { contentTypes, subjectCategories, subjectTypes };
|
|
22
19
|
var titleTemplate = ' - NDLA';
|
|
23
|
-
|
|
24
20
|
var messages = _objectSpread(_objectSpread({
|
|
25
21
|
treeStructure: {
|
|
26
22
|
folderChildOptions: {
|
|
@@ -959,7 +955,6 @@ var messages = _objectSpread(_objectSpread({
|
|
|
959
955
|
buttonLogOut: 'Logge olggos',
|
|
960
956
|
generalFooter: 'Muhtin resurssat leat dušše olamuttus sisaloggejuvvon oahpaheddjiide.',
|
|
961
957
|
modal: {
|
|
962
|
-
collectedInfo: 'Čuovvovaš dieđut leat du birra vižžojuvvon Feide bokte:',
|
|
963
958
|
general: 'Resurssat mat gáibidit Feide sisaloggema leat merkejuvvon čuovvovaš ikonain',
|
|
964
959
|
topic: 'Logge sisa Feide bokte oažžun dihte beassanlági dán fáddái.',
|
|
965
960
|
isAuth: 'Geavaheaddjidieđut',
|
|
@@ -1111,5 +1106,4 @@ var messages = _objectSpread(_objectSpread({
|
|
|
1111
1106
|
help: 'Veahket'
|
|
1112
1107
|
}
|
|
1113
1108
|
});
|
|
1114
|
-
|
|
1115
1109
|
export default messages;
|
|
@@ -1,11 +1,7 @@
|
|
|
1
1
|
var _subjectCategories, _subjectTypes, _contentTypeResultsSh, _contentTypeResultsSh2, _contentTypeResultsNo;
|
|
2
|
-
|
|
3
|
-
function
|
|
4
|
-
|
|
5
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
6
|
-
|
|
2
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
3
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
7
4
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
8
|
-
|
|
9
5
|
/**
|
|
10
6
|
* Copyright (c) 2018-present, NDLA.
|
|
11
7
|
*
|
|
@@ -13,14 +9,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
13
9
|
* LICENSE file in the root directory of this source tree.
|
|
14
10
|
*
|
|
15
11
|
*/
|
|
12
|
+
|
|
16
13
|
import { contributorTypes } from '@ndla/licenses';
|
|
17
14
|
import constants from '../model';
|
|
18
15
|
var contentTypes = constants.contentTypes,
|
|
19
|
-
|
|
20
|
-
|
|
16
|
+
subjectCategories = constants.subjectCategories,
|
|
17
|
+
subjectTypes = constants.subjectTypes;
|
|
21
18
|
export { contentTypes, subjectCategories, subjectTypes };
|
|
22
19
|
var titleTemplate = ' - NDLA';
|
|
23
|
-
|
|
24
20
|
var messages = _objectSpread(_objectSpread({
|
|
25
21
|
treeStructure: {
|
|
26
22
|
folderChildOptions: {
|
|
@@ -959,7 +955,6 @@ var messages = _objectSpread(_objectSpread({
|
|
|
959
955
|
buttonLogOut: 'Logg ut',
|
|
960
956
|
generalFooter: 'Enkelte ressurser er bare tilgjengelige for påloggede lærere.',
|
|
961
957
|
modal: {
|
|
962
|
-
collectedInfo: 'Vi har hentet følgende informasjon om deg fra Feide:',
|
|
963
958
|
general: 'Ressursene som krever pålogging med Feide, vises med ikonet',
|
|
964
959
|
topic: 'Logg inn med Feide for å få tilgang til dette emnet.',
|
|
965
960
|
isAuth: 'Brukerinfo',
|
|
@@ -1111,5 +1106,4 @@ var messages = _objectSpread(_objectSpread({
|
|
|
1111
1106
|
help: 'Hjelp'
|
|
1112
1107
|
}
|
|
1113
1108
|
});
|
|
1114
|
-
|
|
1115
1109
|
export default messages;
|
package/es/model/ContentType.js
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
var _contentTypeMapping;
|
|
2
|
-
|
|
3
2
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
4
|
-
|
|
5
3
|
/**
|
|
6
4
|
* Copyright (c) 2017-present, NDLA.
|
|
7
5
|
*
|
|
@@ -9,6 +7,7 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
9
7
|
* LICENSE file in the root directory of this source tree.
|
|
10
8
|
*
|
|
11
9
|
*/
|
|
10
|
+
|
|
12
11
|
export var SUBJECT_MATERIAL = 'subject-material';
|
|
13
12
|
export var TASKS_AND_ACTIVITIES = 'tasks-and-activities';
|
|
14
13
|
export var ASSESSMENT_RESOURCES = 'assessment-resources';
|
package/es/model/SubjectTypes.js
CHANGED
package/es/model/index.js
CHANGED
package/es/shapes.js
CHANGED
package/es/types.js
CHANGED
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
2
|
-
|
|
3
1
|
/**
|
|
4
2
|
* Copyright (c) 2016-present, NDLA.
|
|
5
3
|
*
|
|
@@ -7,10 +5,12 @@ import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
|
7
5
|
* LICENSE file in the root directory of this source tree.
|
|
8
6
|
*
|
|
9
7
|
*/
|
|
8
|
+
|
|
10
9
|
// N.B This helper is intended to be used in https://github.com/ndlano/article-converter. It is not a general soultion for using portals in SSR applications.
|
|
10
|
+
|
|
11
11
|
import React from 'react';
|
|
12
12
|
import ReactDOM from 'react-dom';
|
|
13
|
-
|
|
13
|
+
import { jsx as _jsx } from "@emotion/react/jsx-runtime";
|
|
14
14
|
function canUseDOM() {
|
|
15
15
|
return !!(typeof window !== 'undefined' && window.document && !window.document.hidden); // window.document.hidden === jsdom check
|
|
16
16
|
}
|
|
@@ -22,6 +22,5 @@ export function createUniversalPortal(children, selector) {
|
|
|
22
22
|
children: children
|
|
23
23
|
});
|
|
24
24
|
}
|
|
25
|
-
|
|
26
25
|
return /*#__PURE__*/ReactDOM.createPortal(children, document.querySelector(selector));
|
|
27
26
|
}
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*
|
|
7
7
|
*/
|
|
8
|
+
|
|
8
9
|
import { colors } from '@ndla/core';
|
|
9
10
|
import constants from '../model';
|
|
10
11
|
var contentTypes = constants.contentTypes;
|
|
@@ -12,31 +13,22 @@ export var resourceTypeColor = function resourceTypeColor(type) {
|
|
|
12
13
|
switch (type) {
|
|
13
14
|
case contentTypes.SUBJECT_MATERIAL:
|
|
14
15
|
return colors.subjectMaterial.light;
|
|
15
|
-
|
|
16
16
|
case contentTypes.SUBJECT:
|
|
17
17
|
return colors.subject.light;
|
|
18
|
-
|
|
19
18
|
case contentTypes.TOPIC:
|
|
20
19
|
return colors.subject.light;
|
|
21
|
-
|
|
22
20
|
case contentTypes.TASKS_AND_ACTIVITIES:
|
|
23
21
|
return colors.tasksAndActivities.light;
|
|
24
|
-
|
|
25
22
|
case contentTypes.ASSESSMENT_RESOURCES:
|
|
26
23
|
return colors.assessmentResource.light;
|
|
27
|
-
|
|
28
24
|
case contentTypes.EXTERNAL_LEARNING_RESOURCES:
|
|
29
25
|
return colors.externalLearningResource.light;
|
|
30
|
-
|
|
31
26
|
case contentTypes.SOURCE_MATERIAL:
|
|
32
27
|
return colors.sourceMaterial.light;
|
|
33
|
-
|
|
34
28
|
case contentTypes.LEARNING_PATH:
|
|
35
29
|
return colors.learningPath.light;
|
|
36
|
-
|
|
37
30
|
case contentTypes.MULTIDISCIPLINARY_TOPIC:
|
|
38
31
|
return colors.learningPath.background;
|
|
39
|
-
|
|
40
32
|
default:
|
|
41
33
|
return '';
|
|
42
34
|
}
|