@ndla/ui 30.9.0 → 32.0.0

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 (155) hide show
  1. package/README.md +4 -0
  2. package/es/Animation/DisplayOnPageYOffset.js +1 -1
  3. package/es/Article/Article.js +3 -3
  4. package/es/Filter/FilterListPhone.js +1 -1
  5. package/es/NDLAFilm/AllMoviesAlphabetically.js +12 -12
  6. package/es/ResourceBox/ResourceBox.js +9 -11
  7. package/es/TopicMenu/TopicMenu.js +2 -2
  8. package/es/TreeStructure/AddFolderButton.js +2 -2
  9. package/es/TreeStructure/ComboboxButton.js +2 -2
  10. package/es/TreeStructure/FolderItem.js +11 -10
  11. package/es/TreeStructure/FolderItems.js +28 -37
  12. package/es/TreeStructure/TreeStructure.js +8 -8
  13. package/es/User/parseUserObject.js +1 -1
  14. package/lib/Animation/DisplayOnPageYOffset.js +2 -2
  15. package/lib/Article/Article.d.ts +5 -5
  16. package/lib/Article/Article.js +4 -4
  17. package/lib/Article/ArticleAccessMessage.d.ts +1 -1
  18. package/lib/Article/ArticleByline.d.ts +3 -3
  19. package/lib/Article/ArticleContent.d.ts +1 -1
  20. package/lib/Article/ArticleFootNotes.d.ts +1 -1
  21. package/lib/Article/ArticleHeaderWrapper.d.ts +2 -2
  22. package/lib/Article/ArticleNotions.d.ts +2 -2
  23. package/lib/Article/ArticleSideBar.d.ts +1 -1
  24. package/lib/AudioPlayer/AudioPlayer.d.ts +1 -1
  25. package/lib/AudioPlayer/Controls.d.ts +1 -1
  26. package/lib/AudioPlayer/SpeechControl.d.ts +1 -1
  27. package/lib/BannerCard/BannerCard.d.ts +2 -2
  28. package/lib/BlogPosts/BlogPost.d.ts +1 -1
  29. package/lib/Breadcrumblist/Breadcrumblist.d.ts +2 -2
  30. package/lib/CompetenceGoalTab/CompetenceGoalTab.d.ts +1 -1
  31. package/lib/CompetenceGoalTab/CompetenceItem.d.ts +5 -5
  32. package/lib/CompetenceGoalTab/SearchButton.d.ts +1 -1
  33. package/lib/ComponentCursor/ComponentCursor.d.ts +1 -1
  34. package/lib/CreatedBy/CreatedBy.d.ts +1 -1
  35. package/lib/ErrorMessage/ErrorResourceAccessDenied.d.ts +1 -1
  36. package/lib/Figure/Figure.d.ts +1 -1
  37. package/lib/Filter/FilterButtons.d.ts +2 -2
  38. package/lib/Filter/FilterListPhone.js +2 -2
  39. package/lib/Footer/EditorName.d.ts +1 -1
  40. package/lib/Footer/Footer.d.ts +1 -1
  41. package/lib/Footer/FooterLinks.d.ts +1 -1
  42. package/lib/Footer/FooterPrivacy.d.ts +1 -1
  43. package/lib/Footer/FooterText.d.ts +1 -1
  44. package/lib/Frontpage/FrontpageAllSubjects.d.ts +3 -3
  45. package/lib/Frontpage/FrontpageFilm.d.ts +1 -1
  46. package/lib/Frontpage/FrontpageInfo.d.ts +1 -1
  47. package/lib/Frontpage/FrontpageMultidisciplinarySubject.d.ts +1 -1
  48. package/lib/Frontpage/FrontpageProgramMenu.d.ts +1 -1
  49. package/lib/Frontpage/FrontpageSearch.d.ts +1 -1
  50. package/lib/Frontpage/FrontpageToolbox.d.ts +1 -1
  51. package/lib/Hero/Hero.d.ts +1 -1
  52. package/lib/LanguageSelector/LanguageSelector.d.ts +1 -1
  53. package/lib/LanguageSelector/LanguageSelectorContent.d.ts +1 -1
  54. package/lib/LearningPaths/LearningPathMenu.d.ts +1 -1
  55. package/lib/LearningPaths/LearningPathMenuAside.d.ts +1 -1
  56. package/lib/LearningPaths/LearningPathMenuAsideCopyright.d.ts +1 -1
  57. package/lib/LearningPaths/LearningPathMenuContent.d.ts +1 -1
  58. package/lib/LearningPaths/LearningPathMenuModalWrapper.d.ts +1 -1
  59. package/lib/LearningPaths/LearningPathMobileStepInfo.d.ts +1 -1
  60. package/lib/LearningPaths/LearningPathSticky.d.ts +1 -1
  61. package/lib/Messages/MessageBox.d.ts +1 -1
  62. package/lib/Messages/MessageBoxTag.d.ts +1 -1
  63. package/lib/MultidisciplinarySubject/List.d.ts +1 -1
  64. package/lib/MultidisciplinarySubject/ListItem.d.ts +1 -1
  65. package/lib/MultidisciplinarySubject/MultidisciplinarySubject.d.ts +1 -1
  66. package/lib/MultidisciplinarySubject/MultidisciplinarySubjectHeader.d.ts +3 -3
  67. package/lib/MyNdla/Resource/Folder.d.ts +1 -1
  68. package/lib/MyNdla/Resource/FolderInput.d.ts +1 -1
  69. package/lib/NDLAFilm/AllMoviesAlphabetically.js +13 -13
  70. package/lib/Navigation/NavigationBox.d.ts +3 -3
  71. package/lib/Navigation/NavigationHeading.d.ts +1 -1
  72. package/lib/Navigation/NavigationTopicAbout.d.ts +1 -1
  73. package/lib/Notion/Notion.d.ts +1 -1
  74. package/lib/Notion/NotionVisualElement.d.ts +1 -1
  75. package/lib/Programme/Programme.d.ts +1 -1
  76. package/lib/Programme/ProgrammeSubjects.d.ts +2 -2
  77. package/lib/Resource/resourceComponents.d.ts +1 -1
  78. package/lib/ResourceBox/ResourceBox.d.ts +2 -1
  79. package/lib/ResourceBox/ResourceBox.js +9 -11
  80. package/lib/ResourceGroup/ResourceGroup.d.ts +1 -1
  81. package/lib/ResourceGroup/ResourceItem.d.ts +1 -1
  82. package/lib/ResourceGroup/ResourceList.d.ts +1 -1
  83. package/lib/Search/ContentTypeResult.d.ts +1 -1
  84. package/lib/Search/ContentTypeResultStyles.d.ts +2 -2
  85. package/lib/Search/LoadingWrapper.d.ts +1 -1
  86. package/lib/Search/SearchResultSleeve.d.ts +1 -1
  87. package/lib/SearchTypeResult/ActiveFilterContent.d.ts +2 -2
  88. package/lib/SearchTypeResult/ActiveFilters.d.ts +1 -1
  89. package/lib/SearchTypeResult/PopupFilter.d.ts +2 -2
  90. package/lib/SearchTypeResult/ResultNavigation.d.ts +1 -1
  91. package/lib/SearchTypeResult/SearchFieldHeader.d.ts +1 -1
  92. package/lib/SearchTypeResult/SearchFilterContent.d.ts +1 -1
  93. package/lib/SearchTypeResult/SearchHeader.d.ts +1 -1
  94. package/lib/SearchTypeResult/SearchItem.d.ts +2 -2
  95. package/lib/SearchTypeResult/SearchItems.d.ts +1 -1
  96. package/lib/SearchTypeResult/SearchNotionItem.d.ts +1 -1
  97. package/lib/SearchTypeResult/SearchNotionsResult.d.ts +1 -1
  98. package/lib/SearchTypeResult/SearchSubjectItem.d.ts +2 -2
  99. package/lib/SearchTypeResult/SearchSubjectResult.d.ts +1 -1
  100. package/lib/SearchTypeResult/SearchTypeHeader.d.ts +2 -2
  101. package/lib/SearchTypeResult/SearchTypeResult.d.ts +2 -2
  102. package/lib/SearchTypeResult/SearchViewType.d.ts +1 -1
  103. package/lib/SearchTypeResult/components/ItemContexts.d.ts +2 -2
  104. package/lib/SearchTypeResult/components/ItemResourceHeader.d.ts +1 -1
  105. package/lib/SearchTypeResult/components/ItemTopicHeader.d.ts +1 -1
  106. package/lib/SearchTypeResult/components/SubjectFilters.d.ts +4 -4
  107. package/lib/Subject/SubjectBanner.d.ts +2 -2
  108. package/lib/Subject/SubjectHeader.d.ts +1 -1
  109. package/lib/Topic/Topic.d.ts +2 -2
  110. package/lib/TopicMenu/TopicMenu.js +3 -3
  111. package/lib/TreeStructure/AddFolderButton.d.ts +2 -2
  112. package/lib/TreeStructure/AddFolderButton.js +2 -2
  113. package/lib/TreeStructure/ComboboxButton.d.ts +7 -6
  114. package/lib/TreeStructure/ComboboxButton.js +2 -2
  115. package/lib/TreeStructure/FolderItem.d.ts +5 -3
  116. package/lib/TreeStructure/FolderItem.js +11 -10
  117. package/lib/TreeStructure/FolderItems.d.ts +4 -3
  118. package/lib/TreeStructure/FolderItems.js +28 -36
  119. package/lib/TreeStructure/TreeStructure.d.ts +3 -2
  120. package/lib/TreeStructure/TreeStructure.js +11 -11
  121. package/lib/TreeStructure/arrowNavigation.d.ts +2 -2
  122. package/lib/TreeStructure/helperFunctions.d.ts +3 -2
  123. package/lib/TreeStructure/index.d.ts +0 -1
  124. package/lib/TreeStructure/types.d.ts +8 -12
  125. package/lib/User/AuthModal.d.ts +1 -1
  126. package/lib/User/apiTypes.d.ts +3 -3
  127. package/lib/User/parseUserObject.d.ts +1 -1
  128. package/lib/User/parseUserObject.js +3 -2
  129. package/lib/index.d.ts +1 -1
  130. package/lib/locale/LocaleProvider.d.ts +1 -1
  131. package/lib/types.d.ts +11 -11
  132. package/package.json +10 -10
  133. package/src/Animation/DisplayOnPageYOffset.tsx +1 -1
  134. package/src/Article/Article.tsx +1 -1
  135. package/src/Filter/FilterListPhone.tsx +1 -1
  136. package/src/NDLAFilm/AllMoviesAlphabetically.tsx +1 -1
  137. package/src/ResourceBox/ResourceBox.tsx +3 -4
  138. package/src/TopicMenu/TopicMenu.jsx +1 -1
  139. package/src/TreeStructure/AddFolderButton.tsx +2 -2
  140. package/src/TreeStructure/ComboboxButton.tsx +7 -6
  141. package/src/TreeStructure/FolderItem.tsx +10 -7
  142. package/src/TreeStructure/FolderItems.tsx +31 -36
  143. package/src/TreeStructure/TreeStructure.tsx +7 -7
  144. package/src/TreeStructure/arrowNavigation.ts +5 -5
  145. package/src/TreeStructure/helperFunctions.ts +4 -3
  146. package/src/TreeStructure/index.ts +0 -1
  147. package/src/TreeStructure/types.ts +5 -10
  148. package/src/User/parseUserObject.ts +1 -1
  149. package/src/index.ts +1 -1
  150. package/es/LetterFilter/LetterFilter.stories.js +0 -44
  151. package/es/TreeStructure/NavigationLink.js +0 -91
  152. package/lib/LetterFilter/LetterFilter.stories.js +0 -45
  153. package/lib/TreeStructure/NavigationLink.d.ts +0 -14
  154. package/lib/TreeStructure/NavigationLink.js +0 -93
  155. package/src/TreeStructure/NavigationLink.tsx +0 -107
@@ -6,13 +6,13 @@
6
6
  *
7
7
  */
8
8
  import { ReactNode } from 'react';
9
- declare type AuthorProps = {
9
+ type AuthorProps = {
10
10
  name: string;
11
11
  };
12
- declare type SupplierProps = {
12
+ type SupplierProps = {
13
13
  name: string;
14
14
  };
15
- declare type Props = {
15
+ type Props = {
16
16
  authors?: AuthorProps[];
17
17
  suppliers?: SupplierProps[];
18
18
  published: string;
@@ -1,5 +1,5 @@
1
1
  import { Locale } from '../types';
2
- declare type Props = {
2
+ type Props = {
3
3
  content: string;
4
4
  locale: Locale;
5
5
  };
@@ -1,5 +1,5 @@
1
1
  import { FootNote as FootNoteType } from '../types';
2
- declare type ArticleFootNotesProps = {
2
+ type ArticleFootNotesProps = {
3
3
  footNotes: Array<FootNoteType>;
4
4
  };
5
5
  declare const ArticleFootNotes: ({ footNotes }: ArticleFootNotesProps) => import("@emotion/react/jsx-runtime").JSX.Element;
@@ -6,12 +6,12 @@
6
6
  *
7
7
  */
8
8
  import { ComponentType, ReactNode } from 'react';
9
- declare type OpenButtonProps = {
9
+ type OpenButtonProps = {
10
10
  onClick: () => void;
11
11
  children: ReactNode;
12
12
  };
13
13
  export declare const OpenButton: ({ children, onClick }: OpenButtonProps) => import("@emotion/react/jsx-runtime").JSX.Element;
14
- declare type Props = {
14
+ type Props = {
15
15
  competenceGoals?: ((inp: {
16
16
  Dialog: ComponentType;
17
17
  dialogProps: {
@@ -6,11 +6,11 @@
6
6
  *
7
7
  */
8
8
  import { ConceptNotionType } from '../Notion/ConceptNotion';
9
- export declare type NotionRelatedContent = {
9
+ export type NotionRelatedContent = {
10
10
  url: string;
11
11
  label: string;
12
12
  };
13
- declare type ArticleNotionsProps = {
13
+ type ArticleNotionsProps = {
14
14
  notions: ConceptNotionType[];
15
15
  relatedContent?: NotionRelatedContent[];
16
16
  buttonOffsetRight: number;
@@ -1,5 +1,5 @@
1
1
  import { MouseEvent, ReactNode, RefObject } from 'react';
2
- declare type Props = {
2
+ type Props = {
3
3
  linkToResources?: string;
4
4
  onLinkToResourcesClick?: (e: MouseEvent<HTMLElement>) => void;
5
5
  copyPageUrlLink?: string;
@@ -7,7 +7,7 @@
7
7
  */
8
8
  import { ReactNode } from 'react';
9
9
  export declare const truncateDescription: (el: HTMLElement, readMoreLabel: string | null) => void;
10
- declare type Props = {
10
+ type Props = {
11
11
  src: string;
12
12
  title: string;
13
13
  subtitle?: {
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
7
  */
8
- declare type Props = {
8
+ type Props = {
9
9
  src: string;
10
10
  title: string;
11
11
  };
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
7
  */
8
- declare type Props = {
8
+ type Props = {
9
9
  src: string;
10
10
  title: string;
11
11
  };
@@ -1,8 +1,8 @@
1
- declare type ImageProps = {
1
+ type ImageProps = {
2
2
  altText: string;
3
3
  imageSrc: string;
4
4
  };
5
- declare type BannerProps = {
5
+ type BannerProps = {
6
6
  link: string;
7
7
  image: ImageProps;
8
8
  title: string;
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
7
  */
8
- declare type Props = {
8
+ type Props = {
9
9
  text: string;
10
10
  externalLink: string;
11
11
  linkText: string;
@@ -6,7 +6,7 @@
6
6
  *
7
7
  */
8
8
  import { ReactNode, MouseEvent } from 'react';
9
- export declare type BreadcrumbItemProps = {
9
+ export type BreadcrumbItemProps = {
10
10
  id: string | number;
11
11
  label: string;
12
12
  url: string;
@@ -14,7 +14,7 @@ export declare type BreadcrumbItemProps = {
14
14
  isCurrent?: boolean | false;
15
15
  icon?: ReactNode;
16
16
  };
17
- declare type BreadCrumbProps = {
17
+ type BreadCrumbProps = {
18
18
  children?: ReactNode;
19
19
  items: BreadcrumbItemProps[];
20
20
  startOffset?: number;
@@ -6,7 +6,7 @@
6
6
  *
7
7
  */
8
8
  import { ListItemProp } from './CompetenceItem';
9
- declare type CompetenceProps = {
9
+ type CompetenceProps = {
10
10
  list: ListItemProp[];
11
11
  highlightSearchBox?: boolean;
12
12
  isOembed?: boolean;
@@ -6,23 +6,23 @@
6
6
  *
7
7
  */
8
8
  import { CompetenceGoalsItemType } from '../types';
9
- export declare type CompetenceTypeProps = 'competenceGoals' | 'coreElement';
10
- export declare type CompetenceGoals = {
9
+ export type CompetenceTypeProps = 'competenceGoals' | 'coreElement';
10
+ export type CompetenceGoals = {
11
11
  title?: string;
12
12
  elements: CompetenceGoalsItemType[];
13
13
  };
14
- export declare type CoreElementItems = {
14
+ export type CoreElementItems = {
15
15
  title?: string;
16
16
  elements: any;
17
17
  };
18
- export declare type ListItemProp = {
18
+ export type ListItemProp = {
19
19
  id: string;
20
20
  title: string;
21
21
  type: CompetenceTypeProps;
22
22
  groupedCompetenceGoals?: CompetenceGoals[];
23
23
  groupedCoreElementItems?: CoreElementItems[];
24
24
  };
25
- export declare type ListItemProps = {
25
+ export type ListItemProps = {
26
26
  item: ListItemProp;
27
27
  isOembed?: boolean;
28
28
  };
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
7
  */
8
- declare type Props = {
8
+ type Props = {
9
9
  to: string;
10
10
  text: string;
11
11
  target?: string;
@@ -1,4 +1,4 @@
1
- declare type Props = {
1
+ type Props = {
2
2
  variant: string;
3
3
  text?: string;
4
4
  };
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
7
  */
8
- declare type Props = {
8
+ type Props = {
9
9
  name: string;
10
10
  description: string;
11
11
  url?: string;
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
7
  */
8
- declare type Props = {
8
+ type Props = {
9
9
  onAuthenticateClick: () => void;
10
10
  };
11
11
  declare const ErrorResourceAccessDenied: ({ onAuthenticateClick }: Props) => import("@emotion/react/jsx-runtime").JSX.Element;
@@ -42,7 +42,7 @@ interface FigureCaptionProps {
42
42
  };
43
43
  }
44
44
  declare const Figure: ({ children, type, resizeIframe, ...rest }: Props) => import("@emotion/react/jsx-runtime").JSX.Element;
45
- export declare type FigureType = 'full' | 'full-column' | 'left' | 'small-left' | 'right' | 'small-right' | 'xsmall-right' | 'xsmall-left';
45
+ export type FigureType = 'full' | 'full-column' | 'left' | 'small-left' | 'right' | 'small-right' | 'xsmall-right' | 'xsmall-left';
46
46
  interface Props {
47
47
  id?: string;
48
48
  children: ReactNode | ((params: {
@@ -1,9 +1,9 @@
1
- export declare type ItemProps = {
1
+ export type ItemProps = {
2
2
  label: string;
3
3
  value: string;
4
4
  selected?: boolean;
5
5
  };
6
- export declare type FilterButtonsProps = {
6
+ export type FilterButtonsProps = {
7
7
  heading?: string;
8
8
  items: ItemProps[];
9
9
  onFilterToggle: (value: string) => void;
@@ -9,7 +9,7 @@ var _react = _interopRequireWildcard(require("react"));
9
9
  var _common = require("@ndla/icons/common");
10
10
  var _modal = _interopRequireWildcard(require("@ndla/modal"));
11
11
  var _button = _interopRequireDefault(require("@ndla/button"));
12
- var _lodash = require("lodash");
12
+ var _debounce = _interopRequireDefault(require("lodash/debounce"));
13
13
  var _filterClasses = require("./filterClasses");
14
14
  var _ToggleItem = _interopRequireDefault(require("./ToggleItem"));
15
15
  var _ActiveFilters = _interopRequireDefault(require("../Search/ActiveFilters"));
@@ -66,7 +66,7 @@ var FilterListPhone = function FilterListPhone(_ref) {
66
66
  setVisibleCount = _useState4[1];
67
67
  (0, _react.useEffect)(function () {
68
68
  setScreenSize(true);
69
- var debounced = (0, _lodash.debounce)(function () {
69
+ var debounced = (0, _debounce["default"])(function () {
70
70
  return setScreenSize(false);
71
71
  }, 50);
72
72
  window.addEventListener('resize', debounced);
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
7
  */
8
- declare type EditorNameProps = {
8
+ type EditorNameProps = {
9
9
  title: string;
10
10
  name: string;
11
11
  };
@@ -7,7 +7,7 @@
7
7
  */
8
8
  import { ReactNode } from 'react';
9
9
  import { Locale } from '../types';
10
- declare type Props = {
10
+ type Props = {
11
11
  children: ReactNode;
12
12
  lang: Locale;
13
13
  links?: [
@@ -1,5 +1,5 @@
1
1
  import { ReactNode } from 'react';
2
- declare type FooterLinksProps = {
2
+ type FooterLinksProps = {
3
3
  links: [
4
4
  {
5
5
  to: string;
@@ -6,7 +6,7 @@
6
6
  *
7
7
  */
8
8
  import { Locale } from '../types';
9
- declare type FooterPrivacyProps = {
9
+ type FooterPrivacyProps = {
10
10
  label: string;
11
11
  lang: Locale;
12
12
  };
@@ -6,7 +6,7 @@
6
6
  *
7
7
  */
8
8
  import { ReactNode } from 'react';
9
- declare type FooterTextProps = {
9
+ type FooterTextProps = {
10
10
  children: ReactNode;
11
11
  };
12
12
  export declare const FooterText: ({ children }: FooterTextProps) => import("@emotion/react/jsx-runtime").JSX.Element;
@@ -1,17 +1,17 @@
1
- declare type subjectProps = {
1
+ type subjectProps = {
2
2
  name: string;
3
3
  url?: string;
4
4
  path?: string;
5
5
  id?: string;
6
6
  };
7
- declare type categoryProps = {
7
+ type categoryProps = {
8
8
  type?: string;
9
9
  name?: string;
10
10
  visible?: boolean;
11
11
  message?: string;
12
12
  subjects: subjectProps[];
13
13
  };
14
- export declare type subjectsProps = {
14
+ export type subjectsProps = {
15
15
  categories: categoryProps[];
16
16
  subjectViewType?: 'link' | 'checkbox';
17
17
  onToggleSubject?: (id: string) => void;
@@ -1,4 +1,4 @@
1
- declare type Props = {
1
+ type Props = {
2
2
  url: string;
3
3
  imageUrl: string;
4
4
  };
@@ -1,5 +1,5 @@
1
1
  import { ReactNode } from 'react';
2
- declare type Props = {
2
+ type Props = {
3
3
  children: ReactNode;
4
4
  };
5
5
  declare const FrontpageInfo: ({ children }: Props) => import("@emotion/react/jsx-runtime").JSX.Element;
@@ -19,7 +19,7 @@ export declare const StyledText: import("@emotion/styled").StyledComponent<{
19
19
  theme?: import("@emotion/react").Theme | undefined;
20
20
  as?: React.ElementType<any> | undefined;
21
21
  }, React.DetailedHTMLProps<React.HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
22
- declare type Props = {
22
+ type Props = {
23
23
  url: string;
24
24
  topics?: {
25
25
  url: string;
@@ -1,6 +1,6 @@
1
1
  import { ItemProps } from '../Navigation/NavigationBox';
2
2
  import { subjectsProps } from './FrontpageAllSubjects';
3
- declare type Props = {
3
+ type Props = {
4
4
  programItems: ItemProps[];
5
5
  subjectCategories: subjectsProps['categories'];
6
6
  showBetaCursor?: boolean;
@@ -1,6 +1,6 @@
1
1
  import { FormEvent } from 'react';
2
2
  import { ContentTypeResultType, Resource } from '../types';
3
- declare type Props = {
3
+ type Props = {
4
4
  inputHasFocus: boolean;
5
5
  searchFieldValue: string;
6
6
  onSearchFieldChange: (searchValue: string) => void;
@@ -1,4 +1,4 @@
1
- declare type Props = {
1
+ type Props = {
2
2
  urlStudents: string;
3
3
  urlTeachers: string;
4
4
  };
@@ -6,7 +6,7 @@
6
6
  *
7
7
  */
8
8
  import { ReactNode } from 'react';
9
- export declare type HeroContentType = 'subject-material' | 'tasks-and-activities' | 'assessment-resources' | 'subject' | 'external-learning-resources' | 'source-material' | 'learning-path' | 'topic' | 'beta' | 'ndla-film' | 'ndla-film has-image';
9
+ export type HeroContentType = 'subject-material' | 'tasks-and-activities' | 'assessment-resources' | 'subject' | 'external-learning-resources' | 'source-material' | 'learning-path' | 'topic' | 'beta' | 'ndla-film' | 'ndla-film has-image';
10
10
  interface HeroProps {
11
11
  children?: ReactNode;
12
12
  contentType?: HeroContentType;
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
7
  */
8
- declare type Props = {
8
+ type Props = {
9
9
  options: {
10
10
  [key: string]: {
11
11
  name: string;
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
7
  */
8
- declare type Props = {
8
+ type Props = {
9
9
  currentLanguage: string;
10
10
  setInfoLocale(arg: string): void;
11
11
  infoLocale: string;
@@ -6,7 +6,7 @@
6
6
  *
7
7
  */
8
8
  import { ReactNode } from 'react';
9
- export declare type StepProps = {
9
+ export type StepProps = {
10
10
  title: string;
11
11
  type: string;
12
12
  id: number;
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
7
  */
8
- declare type Props = {
8
+ type Props = {
9
9
  isOpen: boolean;
10
10
  lastUpdated: string;
11
11
  learningPathURL: string;
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
7
  */
8
- declare type Props = {
8
+ type Props = {
9
9
  copyright: {
10
10
  contributors: {
11
11
  type: string;
@@ -6,7 +6,7 @@
6
6
  *
7
7
  */
8
8
  import { StepProps } from './LearningPathMenu';
9
- declare type Props = {
9
+ type Props = {
10
10
  learningsteps: StepProps[];
11
11
  learningPathId: number;
12
12
  isOpen: boolean;
@@ -6,7 +6,7 @@
6
6
  *
7
7
  */
8
8
  import { ReactChild, ReactChildren, ReactNode } from 'react';
9
- declare type ModalWrapperProps = {
9
+ type ModalWrapperProps = {
10
10
  innerWidth: number;
11
11
  children: (arg: VoidFunction) => ReactChild | ReactChildren | ReactNode;
12
12
  };
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
7
  */
8
- declare type Props = {
8
+ type Props = {
9
9
  total: number;
10
10
  current: number;
11
11
  };
@@ -16,7 +16,7 @@ export declare const LearningPathSticky: {
16
16
  children: PropTypes.Requireable<PropTypes.ReactNodeLike>;
17
17
  };
18
18
  };
19
- declare type PropsSiblings = {
19
+ type PropsSiblings = {
20
20
  title: string;
21
21
  toLearningPathUrl(pathId: number, stepId: number): string;
22
22
  arrow?: 'left' | 'right';
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
7
  */
8
- declare type MessageBoxType = 'ghost' | 'danger';
8
+ type MessageBoxType = 'ghost' | 'danger';
9
9
  interface LinkProps {
10
10
  href?: string;
11
11
  text?: string;
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
7
  */
8
- declare type Props = {
8
+ type Props = {
9
9
  tagMessage: string;
10
10
  };
11
11
  export declare const MessageBoxTag: ({ tagMessage }: Props) => import("@emotion/react/jsx-runtime").JSX.Element;
@@ -1,5 +1,5 @@
1
1
  import { ListItemProps } from './ListItem';
2
- export declare type ListProps = {
2
+ export type ListProps = {
3
3
  items: ListItemProps[];
4
4
  totalCount: number;
5
5
  };
@@ -1,4 +1,4 @@
1
- export declare type ListItemProps = {
1
+ export type ListItemProps = {
2
2
  title: string;
3
3
  introduction: string;
4
4
  url: string;
@@ -1,6 +1,6 @@
1
1
  import { ReactNode } from 'react';
2
2
  import { ListItemProps } from './ListItem';
3
- declare type Props = {
3
+ type Props = {
4
4
  cards: ListItemProps[];
5
5
  children: ReactNode;
6
6
  totalCardCount: number;
@@ -1,9 +1,9 @@
1
- declare type subjects = 'climate' | 'democracy' | 'publicHealth';
2
- declare type subjectLink = {
1
+ type subjects = 'climate' | 'democracy' | 'publicHealth';
2
+ type subjectLink = {
3
3
  label: string;
4
4
  url: string;
5
5
  };
6
- declare type Props = {
6
+ type Props = {
7
7
  subjects?: subjects[];
8
8
  subjectsLinks?: subjectLink[];
9
9
  };
@@ -6,7 +6,7 @@
6
6
  *
7
7
  */
8
8
  import { MenuItemProps } from '@ndla/button';
9
- declare type LayoutType = 'list' | 'listLarger' | 'block';
9
+ type LayoutType = 'list' | 'listLarger' | 'block';
10
10
  interface Props {
11
11
  id: string;
12
12
  title: string;
@@ -12,5 +12,5 @@ interface Props extends ComponentProps<typeof InputV2> {
12
12
  onClose?: () => void;
13
13
  onSave: () => void;
14
14
  }
15
- declare const FolderInput: React.ForwardRefExoticComponent<Pick<Props, "max" | "required" | "type" | "data" | "error" | "default" | "high" | "low" | "key" | "id" | "media" | "height" | "width" | "start" | "open" | "name" | "color" | "content" | "translate" | "value" | "loading" | "hidden" | "cite" | "form" | "label" | "slot" | "span" | "style" | "summary" | "title" | "dir" | "pattern" | "acceptCharset" | "action" | "method" | "noValidate" | "target" | "accessKey" | "draggable" | "lang" | "className" | "prefix" | "after" | "before" | "children" | "contentEditable" | "inputMode" | "nonce" | "tabIndex" | "async" | "disabled" | "multiple" | "size" | "manifest" | "white" | "wrap" | "src" | "accept" | "allowFullScreen" | "allowTransparency" | "alt" | "as" | "autoComplete" | "autoFocus" | "autoPlay" | "capture" | "cellPadding" | "cellSpacing" | "charSet" | "challenge" | "checked" | "classID" | "cols" | "colSpan" | "controls" | "coords" | "crossOrigin" | "dateTime" | "defer" | "download" | "encType" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "frameBorder" | "headers" | "href" | "hrefLang" | "htmlFor" | "httpEquiv" | "integrity" | "keyParams" | "keyType" | "kind" | "list" | "loop" | "marginHeight" | "marginWidth" | "maxLength" | "mediaGroup" | "min" | "minLength" | "muted" | "optimum" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "contextMenu" | "placeholder" | "spellCheck" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "playsInline" | "poster" | "preload" | "readOnly" | "rel" | "reversed" | "rows" | "rowSpan" | "sandbox" | "scope" | "scoped" | "scrolling" | "seamless" | "selected" | "shape" | "sizes" | "srcDoc" | "srcLang" | "srcSet" | "step" | "useMap" | "wmode" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "onClose" | "customCss" | "labelHidden" | "onSave"> & React.RefAttributes<HTMLInputElement>>;
15
+ declare const FolderInput: React.ForwardRefExoticComponent<Pick<Props, "max" | "required" | "type" | "data" | "error" | "default" | "high" | "low" | "key" | "id" | "media" | "height" | "width" | "start" | "open" | "name" | "color" | "content" | "translate" | "value" | "loading" | "hidden" | "cite" | "form" | "label" | "slot" | "span" | "style" | "summary" | "title" | "dir" | "pattern" | "acceptCharset" | "action" | "method" | "noValidate" | "target" | "accessKey" | "draggable" | "lang" | "className" | "prefix" | "role" | "after" | "before" | "children" | "contentEditable" | "inputMode" | "nonce" | "tabIndex" | "async" | "disabled" | "multiple" | "size" | "manifest" | "white" | "wrap" | "src" | "accept" | "allowFullScreen" | "allowTransparency" | "alt" | "as" | "autoComplete" | "autoFocus" | "autoPlay" | "capture" | "cellPadding" | "cellSpacing" | "charSet" | "challenge" | "checked" | "classID" | "cols" | "colSpan" | "controls" | "coords" | "crossOrigin" | "dateTime" | "defer" | "download" | "encType" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "frameBorder" | "headers" | "href" | "hrefLang" | "htmlFor" | "httpEquiv" | "integrity" | "keyParams" | "keyType" | "kind" | "list" | "loop" | "marginHeight" | "marginWidth" | "maxLength" | "mediaGroup" | "min" | "minLength" | "muted" | "optimum" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "contextMenu" | "placeholder" | "spellCheck" | "radioGroup" | "about" | "datatype" | "inlist" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "playsInline" | "poster" | "preload" | "readOnly" | "rel" | "reversed" | "rows" | "rowSpan" | "sandbox" | "scope" | "scoped" | "scrolling" | "seamless" | "selected" | "shape" | "sizes" | "srcDoc" | "srcLang" | "srcSet" | "step" | "useMap" | "wmode" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "onClose" | "customCss" | "labelHidden" | "onSave"> & React.RefAttributes<HTMLInputElement>>;
16
16
  export default FolderInput;