@redocly/theme 0.82.2-rc.3 → 0.82.4-rc.1

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 (200) hide show
  1. package/lib/components/Badge/Badge.d.ts +8 -5
  2. package/lib/components/Badge/Badge.js +9 -3
  3. package/lib/components/Breadcrumbs/Breadcrumb.d.ts +1 -1
  4. package/lib/components/Breadcrumbs/Breadcrumb.js +2 -2
  5. package/lib/components/Breadcrumbs/Breadcrumbs.d.ts +3 -3
  6. package/lib/components/Breadcrumbs/Breadcrumbs.js +2 -2
  7. package/lib/components/Buttons/CopyButton.d.ts +2 -2
  8. package/lib/components/Buttons/CopyButton.js +3 -3
  9. package/lib/components/Buttons/EditPageButton.d.ts +2 -3
  10. package/lib/components/Buttons/EditPageButton.js +2 -2
  11. package/lib/components/Buttons/EmailButton.d.ts +4 -5
  12. package/lib/components/Buttons/EmailButton.js +2 -2
  13. package/lib/components/Buttons/NewTabButton.d.ts +4 -5
  14. package/lib/components/Buttons/NewTabButton.js +2 -2
  15. package/lib/components/Catalog/Catalog.d.ts +3 -2
  16. package/lib/components/Catalog/Catalog.js +1 -5
  17. package/lib/components/Catalog/CatalogActions.d.ts +1 -2
  18. package/lib/components/Catalog/CatalogCard.d.ts +1 -2
  19. package/lib/components/Catalog/CatalogHighlight.d.ts +1 -2
  20. package/lib/components/Catalog/CatalogInfoBlock.d.ts +1 -2
  21. package/lib/components/CodeBlock/CodeBlockContainer.d.ts +14 -5
  22. package/lib/components/CodeBlock/CodeBlockContainer.js +9 -4
  23. package/lib/components/CodeBlock/CodeBlockControls.js +2 -0
  24. package/lib/components/CodeBlock/CodeBlockTabs.d.ts +1 -2
  25. package/lib/components/CodeBlock/variables.js +2 -2
  26. package/lib/components/ColorModeSwitcher/ColorModeIcon.d.ts +4 -8
  27. package/lib/components/ColorModeSwitcher/ColorModeIcon.js +5 -3
  28. package/lib/components/ColorModeSwitcher/ColorModeSwitcher.d.ts +1 -2
  29. package/lib/components/DatePicker/DatePicker.d.ts +2 -3
  30. package/lib/components/Dropdown/Dropdown.d.ts +2 -3
  31. package/lib/components/Dropdown/DropdownMenu.d.ts +1 -2
  32. package/lib/components/Dropdown/DropdownMenuItem.d.ts +1 -2
  33. package/lib/components/Feedback/Comment.d.ts +2 -1
  34. package/lib/components/Feedback/Comment.js +3 -3
  35. package/lib/components/Feedback/ReportDialog.js +1 -1
  36. package/lib/components/Filter/FilterContent.d.ts +1 -3
  37. package/lib/components/Filter/FilterContent.js +3 -3
  38. package/lib/components/Filter/FilterInput.d.ts +1 -2
  39. package/lib/components/Filter/FilterOption.d.ts +8 -4
  40. package/lib/components/Filter/FilterOption.js +7 -4
  41. package/lib/components/Filter/FilterOptionLabel.d.ts +5 -3
  42. package/lib/components/Filter/FilterOptionLabel.js +6 -3
  43. package/lib/components/Filter/FilterOptions.d.ts +5 -3
  44. package/lib/components/Filter/FilterOptions.js +6 -3
  45. package/lib/components/Filter/FilterPopover.d.ts +1 -2
  46. package/lib/components/Filter/FilterSelect.js +1 -4
  47. package/lib/components/Filter/FilterTitle.d.ts +5 -3
  48. package/lib/components/Filter/FilterTitle.js +6 -3
  49. package/lib/components/Filter/variables.js +2 -1
  50. package/lib/components/Footer/Footer.d.ts +1 -2
  51. package/lib/components/Footer/FooterColumn.d.ts +1 -2
  52. package/lib/components/Footer/FooterCopyright.d.ts +1 -2
  53. package/lib/components/Footer/FooterItem.d.ts +1 -2
  54. package/lib/components/Footer/FooterLogo.d.ts +3 -4
  55. package/lib/components/Footer/FooterLogo.js +6 -1
  56. package/lib/components/Image/Image.d.ts +2 -2
  57. package/lib/components/JsonViewer/JsonViewer.d.ts +2 -2
  58. package/lib/components/LanguagePicker/LanguagePicker.d.ts +1 -2
  59. package/lib/components/LastUpdated/LastUpdated.d.ts +1 -1
  60. package/lib/components/Link/Link.d.ts +1 -1
  61. package/lib/components/Loading/Loading.d.ts +2 -2
  62. package/lib/components/Logo/Logo.d.ts +1 -2
  63. package/lib/components/Markdown/Markdown.d.ts +12 -0
  64. package/lib/components/Markdown/Markdown.js +6 -7
  65. package/lib/components/Markdown/variables.js +10 -5
  66. package/lib/components/Menu/Menu.d.ts +1 -2
  67. package/lib/components/Menu/MenuContainer.d.ts +4 -4
  68. package/lib/components/Menu/MenuContainer.js +10 -3
  69. package/lib/components/Menu/MenuMobile.d.ts +1 -2
  70. package/lib/components/Menu/variables.js +2 -0
  71. package/lib/components/Navbar/NavbarItem.d.ts +1 -2
  72. package/lib/components/Navbar/NavbarItem.js +1 -1
  73. package/lib/components/Navbar/NavbarLogo.d.ts +3 -4
  74. package/lib/components/Navbar/NavbarLogo.js +6 -3
  75. package/lib/components/Navbar/NavbarMenu.d.ts +1 -2
  76. package/lib/components/PageNavigation/NextButton.d.ts +1 -2
  77. package/lib/components/PageNavigation/PageNavigation.d.ts +1 -2
  78. package/lib/components/PageNavigation/PreviousButton.d.ts +1 -2
  79. package/lib/components/Panel/Panel.d.ts +1 -2
  80. package/lib/components/Panel/PanelBody.d.ts +2 -3
  81. package/lib/components/Portal/Portal.d.ts +2 -3
  82. package/lib/components/Portal/Portal.js +2 -2
  83. package/lib/components/Product/Product.d.ts +1 -2
  84. package/lib/components/Search/Search.d.ts +1 -2
  85. package/lib/components/Search/SearchDialog.d.ts +1 -2
  86. package/lib/components/Search/SearchInput.d.ts +1 -2
  87. package/lib/components/Search/SearchItem.d.ts +1 -1
  88. package/lib/components/Search/SearchRecent.d.ts +1 -2
  89. package/lib/components/Search/SearchShortcut.d.ts +1 -2
  90. package/lib/components/Search/SearchSuggestedPages.d.ts +1 -2
  91. package/lib/components/Search/SearchTrigger.d.ts +1 -2
  92. package/lib/components/Search/variables.js +2 -2
  93. package/lib/components/Segmented/Segmented.d.ts +1 -1
  94. package/lib/components/Select/Select.d.ts +3 -3
  95. package/lib/components/Sidebar/Sidebar.d.ts +1 -2
  96. package/lib/components/SidebarActions/ChangeViewButton.d.ts +2 -3
  97. package/lib/components/SidebarActions/SidebarActions.d.ts +2 -2
  98. package/lib/components/SidebarLogo/SidebarLogo.d.ts +3 -3
  99. package/lib/components/TableOfContent/TableOfContent.d.ts +1 -2
  100. package/lib/components/Tag/Tag.d.ts +1 -1
  101. package/lib/components/UserMenu/UserAvatar.d.ts +1 -2
  102. package/lib/components/UserMenu/UserInfoMenuItem.d.ts +1 -2
  103. package/lib/components/UserMenu/UserMenu.d.ts +1 -2
  104. package/lib/components/UserMenu/UserMenuMobile.d.ts +1 -2
  105. package/lib/components/VersionPicker/VersionPicker.d.ts +1 -1
  106. package/lib/layouts/DocumentationLayout.js +7 -0
  107. package/lib/layouts/NotFound.js +2 -2
  108. package/lib/layouts/RootLayout.d.ts +2 -3
  109. package/lib/markdoc/components/InlineSvg/InlineSvg.d.ts +2 -1
  110. package/lib/markdoc/components/InlineSvg/InlineSvg.js +2 -2
  111. package/lib/markdoc/components/Tabs/variables.js +5 -5
  112. package/package.json +4 -4
  113. package/src/components/Badge/Badge.tsx +13 -3
  114. package/src/components/Breadcrumbs/Breadcrumb.tsx +2 -2
  115. package/src/components/Breadcrumbs/Breadcrumbs.tsx +2 -2
  116. package/src/components/Buttons/CopyButton.tsx +7 -5
  117. package/src/components/Buttons/EditPageButton.tsx +3 -3
  118. package/src/components/Buttons/EmailButton.tsx +4 -4
  119. package/src/components/Buttons/NewTabButton.tsx +7 -4
  120. package/src/components/Catalog/Catalog.tsx +5 -7
  121. package/src/components/Catalog/CatalogActions.tsx +1 -1
  122. package/src/components/Catalog/CatalogCard.tsx +3 -1
  123. package/src/components/Catalog/CatalogHighlight.tsx +1 -1
  124. package/src/components/Catalog/CatalogInfoBlock.tsx +1 -1
  125. package/src/components/CodeBlock/CodeBlockContainer.tsx +19 -6
  126. package/src/components/CodeBlock/CodeBlockControls.tsx +2 -0
  127. package/src/components/CodeBlock/CodeBlockTabs.tsx +1 -1
  128. package/src/components/CodeBlock/variables.ts +2 -2
  129. package/src/components/ColorModeSwitcher/ColorModeIcon.tsx +8 -4
  130. package/src/components/ColorModeSwitcher/ColorModeSwitcher.tsx +1 -1
  131. package/src/components/DatePicker/DatePicker.tsx +2 -2
  132. package/src/components/Dropdown/Dropdown.tsx +2 -2
  133. package/src/components/Dropdown/DropdownMenu.tsx +1 -1
  134. package/src/components/Dropdown/DropdownMenuItem.tsx +1 -1
  135. package/src/components/Feedback/Comment.tsx +4 -2
  136. package/src/components/Feedback/ReportDialog.tsx +1 -0
  137. package/src/components/Filter/FilterContent.tsx +2 -2
  138. package/src/components/Filter/FilterInput.tsx +1 -1
  139. package/src/components/Filter/FilterOption.tsx +20 -4
  140. package/src/components/Filter/FilterOptionLabel.tsx +10 -3
  141. package/src/components/Filter/FilterOptions.tsx +10 -3
  142. package/src/components/Filter/FilterPopover.tsx +1 -1
  143. package/src/components/Filter/FilterSelect.tsx +1 -4
  144. package/src/components/Filter/FilterTitle.tsx +10 -3
  145. package/src/components/Filter/variables.ts +2 -1
  146. package/src/components/Footer/Footer.tsx +1 -1
  147. package/src/components/Footer/FooterColumn.tsx +1 -1
  148. package/src/components/Footer/FooterCopyright.tsx +1 -1
  149. package/src/components/Footer/FooterItem.tsx +1 -1
  150. package/src/components/Footer/FooterLogo.tsx +8 -1
  151. package/src/components/Image/Image.tsx +1 -1
  152. package/src/components/JsonViewer/JsonViewer.tsx +2 -2
  153. package/src/components/LanguagePicker/LanguagePicker.tsx +1 -1
  154. package/src/components/LastUpdated/LastUpdated.tsx +1 -1
  155. package/src/components/Link/Link.tsx +1 -1
  156. package/src/components/Loading/Loading.tsx +2 -2
  157. package/src/components/Logo/Logo.tsx +1 -1
  158. package/src/components/Markdown/Markdown.tsx +17 -8
  159. package/src/components/Markdown/variables.ts +10 -5
  160. package/src/components/Menu/Menu.tsx +1 -1
  161. package/src/components/Menu/MenuContainer.tsx +9 -5
  162. package/src/components/Menu/MenuMobile.tsx +1 -1
  163. package/src/components/Menu/variables.ts +2 -0
  164. package/src/components/Navbar/Navbar.tsx +1 -0
  165. package/src/components/Navbar/NavbarItem.tsx +2 -2
  166. package/src/components/Navbar/NavbarLogo.tsx +8 -3
  167. package/src/components/Navbar/NavbarMenu.tsx +1 -1
  168. package/src/components/PageNavigation/NextButton.tsx +1 -1
  169. package/src/components/PageNavigation/PageNavigation.tsx +1 -1
  170. package/src/components/PageNavigation/PreviousButton.tsx +1 -1
  171. package/src/components/Panel/Panel.tsx +1 -1
  172. package/src/components/Panel/PanelBody.ts +2 -2
  173. package/src/components/Portal/Portal.tsx +6 -3
  174. package/src/components/Product/Product.tsx +1 -1
  175. package/src/components/Search/Search.tsx +1 -1
  176. package/src/components/Search/SearchDialog.tsx +1 -1
  177. package/src/components/Search/SearchInput.tsx +1 -1
  178. package/src/components/Search/SearchItem.tsx +1 -1
  179. package/src/components/Search/SearchRecent.tsx +1 -1
  180. package/src/components/Search/SearchShortcut.tsx +1 -1
  181. package/src/components/Search/SearchSuggestedPages.tsx +1 -1
  182. package/src/components/Search/SearchTrigger.tsx +1 -1
  183. package/src/components/Search/variables.ts +2 -2
  184. package/src/components/Segmented/Segmented.tsx +1 -1
  185. package/src/components/Select/Select.tsx +3 -3
  186. package/src/components/Sidebar/Sidebar.tsx +1 -1
  187. package/src/components/SidebarActions/ChangeViewButton.tsx +2 -2
  188. package/src/components/SidebarActions/SidebarActions.tsx +2 -2
  189. package/src/components/SidebarLogo/SidebarLogo.tsx +3 -3
  190. package/src/components/TableOfContent/TableOfContent.tsx +1 -1
  191. package/src/components/Tag/Tag.tsx +1 -1
  192. package/src/components/UserMenu/UserAvatar.tsx +1 -1
  193. package/src/components/UserMenu/UserInfoMenuItem.tsx +1 -1
  194. package/src/components/UserMenu/UserMenu.tsx +1 -1
  195. package/src/components/UserMenu/UserMenuMobile.tsx +1 -1
  196. package/src/layouts/DocumentationLayout.tsx +7 -0
  197. package/src/layouts/NotFound.tsx +3 -3
  198. package/src/layouts/RootLayout.tsx +2 -2
  199. package/src/markdoc/components/InlineSvg/InlineSvg.tsx +8 -1
  200. package/src/markdoc/components/Tabs/variables.ts +5 -5
@@ -1,10 +1,15 @@
1
+ import React from 'react';
1
2
  import styled from 'styled-components';
2
3
 
4
+ import type { LogoProps } from '@redocly/theme/components/Logo/Logo';
5
+
3
6
  import { Logo } from '@redocly/theme/components/Logo/Logo';
4
7
 
5
- export const NavbarLogo = styled(Logo).attrs({
6
- 'data-component-name': 'Navbar/NavbarLogo',
7
- })`
8
+ export function NavbarLogo(props: LogoProps) {
9
+ return <NavbarLogoComponent {...props} data-component-name="Navbar/NavbarLogo" />;
10
+ }
11
+
12
+ const NavbarLogoComponent = styled(Logo)<LogoProps>`
8
13
  --logo-height: var(--navbar-logo-height);
9
14
  --logo-width: var(--navbar-logo-width);
10
15
  --logo-margin: var(--navbar-logo-margin);
@@ -6,7 +6,7 @@ import type { ResolvedConfigLinks, ResolvedNavItem } from '@redocly/config';
6
6
  import { breakpoints, isPrimitive } from '@redocly/theme/core/utils';
7
7
  import { NavbarItem } from '@redocly/theme/components/Navbar/NavbarItem';
8
8
 
9
- type NavbarMenuProps = {
9
+ export type NavbarMenuProps = {
10
10
  menuItems: ResolvedConfigLinks;
11
11
  className?: string;
12
12
  };
@@ -7,7 +7,7 @@ import { useThemeHooks, useThemeConfig } from '@redocly/theme/core/hooks';
7
7
  import { Button } from '@redocly/theme/components/Button/Button';
8
8
  import { ArrowRightIcon } from '@redocly/theme/icons/ArrowRightIcon/ArrowRightIcon';
9
9
 
10
- type NextPageType = {
10
+ export type NextPageType = {
11
11
  nextPage?: ResolvedNavItemWithLink | null;
12
12
  className?: string;
13
13
  };
@@ -7,7 +7,7 @@ import { useThemeConfig } from '@redocly/theme/core/hooks';
7
7
  import { PreviousButton } from '@redocly/theme/components/PageNavigation/PreviousButton';
8
8
  import { NextButton } from '@redocly/theme/components/PageNavigation/NextButton';
9
9
 
10
- type PageNavigationType = {
10
+ export type PageNavigationType = {
11
11
  nextPage?: ResolvedNavItemWithLink | null;
12
12
  prevPage?: ResolvedNavItemWithLink | null;
13
13
  className?: string;
@@ -7,7 +7,7 @@ import { useThemeHooks, useThemeConfig } from '@redocly/theme/core/hooks';
7
7
  import { Button } from '@redocly/theme/components/Button/Button';
8
8
  import { ArrowLeftIcon } from '@redocly/theme/icons/ArrowLeftIcon/ArrowLeftIcon';
9
9
 
10
- type PreviousPageType = {
10
+ export type PreviousPageType = {
11
11
  prevPage?: ResolvedNavItemWithLink | null;
12
12
  className?: string;
13
13
  };
@@ -10,7 +10,7 @@ import { PanelHeaderTitle } from '@redocly/theme/components/Panel/PanelHeaderTit
10
10
  import { ChevronDownIcon } from '@redocly/theme/icons/ChevronDownIcon/ChevronDownIcon';
11
11
  import { ChevronRightIcon } from '@redocly/theme/icons/ChevronRightIcon/ChevronRightIcon';
12
12
 
13
- type PanelProps = {
13
+ export type PanelProps = {
14
14
  expanded?: boolean;
15
15
  isExpandable?: boolean;
16
16
  className?: string;
@@ -13,10 +13,10 @@ const showPanelAnimation = css`
13
13
  animation: ${showPanel} 0.2s;
14
14
  `;
15
15
 
16
- interface PanelBodyProps {
16
+ export type PanelBodyProps = {
17
17
  animate?: boolean;
18
18
  hidden?: boolean;
19
- }
19
+ };
20
20
 
21
21
  export const PanelBody = styled.div.attrs<{ className?: string }>(({ className }) => ({
22
22
  'data-component-name': 'Panel/PanelBody',
@@ -5,11 +5,14 @@ import type { PropsWithChildren } from 'react';
5
5
 
6
6
  import { IS_BROWSER } from '@redocly/theme/core/utils';
7
7
 
8
- type PortalProps = {
8
+ export type PortalProps = {
9
9
  mountId?: string;
10
10
  };
11
11
 
12
- export const Portal = ({ children, mountId = 'root' }: PropsWithChildren<PortalProps>) => {
12
+ export function Portal({
13
+ children,
14
+ mountId = 'root',
15
+ }: PropsWithChildren<PortalProps>): React.ReactPortal | JSX.Element {
13
16
  const mount = IS_BROWSER ? document.getElementById(mountId) || document.body : null;
14
17
 
15
18
  if (!mount) {
@@ -17,4 +20,4 @@ export const Portal = ({ children, mountId = 'root' }: PropsWithChildren<PortalP
17
20
  }
18
21
 
19
22
  return createPortal(children, mount);
20
- };
23
+ }
@@ -3,7 +3,7 @@ import styled from 'styled-components';
3
3
 
4
4
  import type { ProductConfig } from '@redocly/theme/config';
5
5
 
6
- type ProductProps = {
6
+ export type ProductProps = {
7
7
  product: ProductConfig;
8
8
  className?: string;
9
9
  };
@@ -5,7 +5,7 @@ import { SearchTrigger } from '@redocly/theme/components/Search/SearchTrigger';
5
5
  import { SearchDialog } from '@redocly/theme/components/Search/SearchDialog';
6
6
  import { useSearch } from '@redocly/theme/core/hooks';
7
7
 
8
- type SearchProps = {
8
+ export type SearchProps = {
9
9
  className?: string;
10
10
  };
11
11
 
@@ -15,7 +15,7 @@ import { useThemeHooks, useDialogHotKeys } from '@redocly/theme/core/hooks';
15
15
  import { Tag } from '@redocly/theme/components/Tag/Tag';
16
16
  import { CloseIcon } from '@redocly/theme/icons/CloseIcon/CloseIcon';
17
17
 
18
- type SearchDialogProps = {
18
+ export type SearchDialogProps = {
19
19
  onClose: () => void;
20
20
  className?: string;
21
21
  };
@@ -9,7 +9,7 @@ import { CloseIcon } from '@redocly/theme/icons/CloseIcon/CloseIcon';
9
9
  import { Button } from '@redocly/theme/components/Button/Button';
10
10
  import { useThemeHooks } from '@redocly/theme/core/hooks';
11
11
 
12
- type SearchInputProps = {
12
+ export type SearchInputProps = {
13
13
  placeholder?: string;
14
14
  value: string;
15
15
  onChange(value: string): void;
@@ -9,7 +9,7 @@ import { Image } from '@redocly/theme/components/Image/Image';
9
9
  import { highlight } from '@redocly/theme/components/Search/SearchHighlight';
10
10
 
11
11
  type ActiveItem<T> = T & { active?: boolean };
12
- type SearchItemProps = {
12
+ export type SearchItemProps = {
13
13
  item: ActiveItem<SearchDocument>;
14
14
  product?: {
15
15
  name: string;
@@ -7,7 +7,7 @@ import { CloseIcon } from '@redocly/theme/icons/CloseIcon/CloseIcon';
7
7
  import { RecentlyViewedIcon } from '@redocly/theme/icons/RecentlyViewedIcon/RecentlyViewedIcon';
8
8
  import { Button } from '@redocly/theme/components/Button/Button';
9
9
 
10
- type SearchRecentProps = {
10
+ export type SearchRecentProps = {
11
11
  onSelect: (value: string) => void;
12
12
  className?: string;
13
13
  };
@@ -1,7 +1,7 @@
1
1
  import * as React from 'react';
2
2
  import styled from 'styled-components';
3
3
 
4
- type SearchShortcutProps = {
4
+ export type SearchShortcutProps = {
5
5
  combination: string;
6
6
  text: string;
7
7
  className?: string;
@@ -5,7 +5,7 @@ import { useThemeHooks, useSuggestedPages } from '@redocly/theme/core/hooks';
5
5
  import { RecentlyViewedIcon } from '@redocly/theme/icons/RecentlyViewedIcon/RecentlyViewedIcon';
6
6
  import { Link } from '@redocly/theme/components/Link/Link';
7
7
 
8
- type SearchSuggestedPagesProps = {
8
+ export type SearchSuggestedPagesProps = {
9
9
  className?: string;
10
10
  };
11
11
 
@@ -6,7 +6,7 @@ import { Button } from '@redocly/theme/components/Button/Button';
6
6
  import { SearchIcon } from '@redocly/theme/icons/SearchIcon/SearchIcon';
7
7
  import { breakpoints } from '@redocly/theme/core/utils';
8
8
 
9
- type SearchTriggerProps = {
9
+ export type SearchTriggerProps = {
10
10
  onClick: () => void;
11
11
  className?: string;
12
12
  };
@@ -49,7 +49,7 @@ export const search = css`
49
49
  --search-recent-item-line-height: var(--line-height-base); // @presenter LineHeight
50
50
  --search-recent-item-padding: var(--spacing-xs) var(--spacing-lg);
51
51
  --search-recent-item-text-color: var(--search-item-text-color); // @presenter Color
52
- --search-recent-item-text-color-hover: var(--search-item-text-color-active); // @presenter Color
52
+ --search-recent-item-text-color-hover: var(--search-item-text-color-hover); // @presenter Color
53
53
  --search-recent-item-bg-color-hover: var(--search-item-bg-color-hover); // @presenter Color
54
54
  --search-recent-item-title-font-size: var(--font-size-base); // @presenter FontSize
55
55
  --search-recent-item-title-font-weight: var(--font-weight-semibold); // @presenter FontWeight
@@ -64,7 +64,7 @@ export const search = css`
64
64
  --search-suggested-item-line-height: var(--line-height-base); // @presenter LineHeight
65
65
  --search-suggested-item-padding: var(--spacing-xs) var(--spacing-lg);
66
66
  --search-suggested-item-text-color: var(--search-item-text-color); // @presenter Color
67
- --search-suggested-item-text-color-hover: var(--search-item-text-color-active); // @presenter Color
67
+ --search-suggested-item-text-color-hover: var(--search-item-text-color-hover); // @presenter Color
68
68
  --search-suggested-item-bg-color-hover: var(--search-item-bg-color-hover); // @presenter Color
69
69
  --search-suggested-item-title-font-size: var(--font-size-base); // @presenter FontSize
70
70
  --search-suggested-item-title-font-weight: var(--font-weight-semibold); // @presenter FontWeight
@@ -6,7 +6,7 @@ import type { SelectOption } from '@redocly/theme/core/types/select-option';
6
6
 
7
7
  import { typedMemo } from '@redocly/theme/core/hoc/typedMemo';
8
8
 
9
- type SegmentedProps<T> = {
9
+ export type SegmentedProps<T> = {
10
10
  options: SelectOption<T>[];
11
11
  value: T;
12
12
  onChange: ({ label, value }: { label: string; value: T }) => void;
@@ -6,7 +6,7 @@ import { ChevronDownIcon } from '@redocly/theme/icons/ChevronDownIcon/ChevronDow
6
6
  import { ChevronUpIcon } from '@redocly/theme/icons/ChevronUpIcon/ChevronUpIcon';
7
7
  import { CheckmarkIcon } from '@redocly/theme/icons/CheckmarkIcon/CheckmarkIcon';
8
8
 
9
- export interface SelectProps<T = any> {
9
+ export type SelectProps<T = any> = {
10
10
  value: T;
11
11
  options: {
12
12
  element: React.ReactNode | JSX.Element | string;
@@ -25,9 +25,9 @@ export interface SelectProps<T = any> {
25
25
  placeholder?: string;
26
26
  disabled?: boolean;
27
27
  renderInput?: (props: { isOpen: boolean }) => React.ReactElement;
28
- }
28
+ };
29
29
 
30
- export function Select<T>(props: SelectProps<T>) {
30
+ export function Select<T>(props: SelectProps<T>): JSX.Element {
31
31
  const {
32
32
  className,
33
33
  value,
@@ -7,7 +7,7 @@ import { breakpoints } from '@redocly/theme/core/utils';
7
7
  import { useThemeConfig, useMobileMenu } from '@redocly/theme/core/hooks';
8
8
  import { MenuContainer } from '@redocly/theme/components/Menu/MenuContainer';
9
9
 
10
- type SidebarProps = {
10
+ export type SidebarProps = {
11
11
  versions?: React.ReactNode;
12
12
  menu?: React.ReactNode;
13
13
  backLink?: {
@@ -9,11 +9,11 @@ import {
9
9
  } from '@redocly/theme/components/SidebarActions/styled';
10
10
  import { useThemeHooks } from '@redocly/theme/core/hooks';
11
11
 
12
- interface ChangeViewButtonProps {
12
+ export type ChangeViewButtonProps = {
13
13
  layout: LayoutVariant;
14
14
  collapsedSidebar: boolean;
15
15
  onClick: () => void;
16
- }
16
+ };
17
17
 
18
18
  export const ChangeViewButton = ({
19
19
  layout,
@@ -13,7 +13,7 @@ import {
13
13
 
14
14
  export { LayoutVariant };
15
15
 
16
- interface SidebarActionsProps {
16
+ export type SidebarActionsProps = {
17
17
  layout: LayoutVariant;
18
18
  collapsedSidebar: boolean;
19
19
  isOpenapiDocs: boolean;
@@ -22,7 +22,7 @@ interface SidebarActionsProps {
22
22
  onChangeCollapseSidebarClick: () => void;
23
23
  requestAccessButton?: React.ReactElement | null;
24
24
  className?: string;
25
- }
25
+ };
26
26
 
27
27
  export const SidebarActions = ({
28
28
  layout,
@@ -1,14 +1,14 @@
1
1
  import React from 'react';
2
2
  import styled from 'styled-components';
3
3
 
4
- export interface LogoProps {
4
+ export type SidebarLogoProps = {
5
5
  imageUrl?: string;
6
6
  href?: string;
7
7
  altText?: string;
8
8
  dataTestId?: string;
9
9
  backgroundColor?: string;
10
10
  className?: string;
11
- }
11
+ };
12
12
 
13
13
  export function SidebarLogo({
14
14
  imageUrl,
@@ -17,7 +17,7 @@ export function SidebarLogo({
17
17
  backgroundColor,
18
18
  dataTestId,
19
19
  className,
20
- }: LogoProps = {}): JSX.Element | null {
20
+ }: SidebarLogoProps = {}): JSX.Element | null {
21
21
  if (!imageUrl) {
22
22
  return null;
23
23
  }
@@ -16,7 +16,7 @@ import {
16
16
  getLeastDepth,
17
17
  } from '@redocly/theme/core/utils';
18
18
 
19
- type TableOfContentProps = {
19
+ export type TableOfContentProps = {
20
20
  headings?: Array<MdHeading | null> | null | undefined;
21
21
  contentWrapper: HTMLDivElement | null;
22
22
  className?: string;
@@ -19,7 +19,7 @@ type Color =
19
19
  | 'geekblue'
20
20
  | 'yellow';
21
21
 
22
- type TagProps = {
22
+ export type TagProps = {
23
23
  className?: string;
24
24
  children?: React.ReactNode;
25
25
  closable?: boolean;
@@ -3,7 +3,7 @@ import styled from 'styled-components';
3
3
 
4
4
  import { UserIcon } from '@redocly/theme/icons/UserIcon/UserIcon';
5
5
 
6
- type UserAvatarProps = {
6
+ export type UserAvatarProps = {
7
7
  picture?: string;
8
8
  className?: string;
9
9
  height?: `var(${string})` | `${number}px`;
@@ -4,7 +4,7 @@ import styled from 'styled-components';
4
4
  import { DropdownMenuItem } from '@redocly/theme/components/Dropdown/DropdownMenuItem';
5
5
  import { UserAvatar } from '@redocly/theme/components/UserMenu/UserAvatar';
6
6
 
7
- type UserInfoMenuItemProps = {
7
+ export type UserInfoMenuItemProps = {
8
8
  name: string;
9
9
  email?: string;
10
10
  picture?: string;
@@ -13,7 +13,7 @@ import { UserInfoMenuItem } from '@redocly/theme/components/UserMenu/UserInfoMen
13
13
  import { Dropdown } from '@redocly/theme/components/Dropdown/Dropdown';
14
14
  import { LogoutMenuItem } from '@redocly/theme/components/UserMenu/LogoutMenuItem';
15
15
 
16
- type UserMenuProps = {
16
+ export type UserMenuProps = {
17
17
  className?: string;
18
18
  };
19
19
 
@@ -6,7 +6,7 @@ import { UserAvatar } from '@redocly/theme/components/UserMenu/UserAvatar';
6
6
  import { LogoutMenuItem } from '@redocly/theme/components/UserMenu/LogoutMenuItem';
7
7
  import { LoginButton } from '@redocly/theme/components/UserMenu/LoginButton';
8
8
 
9
- type UserMenuMobileProps = {
9
+ export type UserMenuMobileProps = {
10
10
  className?: string;
11
11
  };
12
12
 
@@ -63,6 +63,13 @@ const LayoutWrapper = styled.div.attrs(({ className }) => ({
63
63
  `;
64
64
 
65
65
  const ContentWrapper = styled.section<{ withToc: boolean }>`
66
+ --md-content-font-size: var(--font-size-lg);
67
+ --md-content-line-height: var(--line-height-lg);
68
+ --md-table-font-size: var(--md-content-font-size);
69
+ --md-table-line-height: var(--md-content-line-height);
70
+ --md-tabs-content-font-size: var(--md-content-font-size);
71
+ --md-tabs-content-line-height: var(--md-content-line-height);
72
+
66
73
  max-width: var(--md-content-max-width);
67
74
  width: 90%;
68
75
  margin: 0 auto;
@@ -10,7 +10,7 @@ export function NotFound(): JSX.Element {
10
10
  const { translate } = useTranslate();
11
11
 
12
12
  return (
13
- <Wrapper data-component-name="Pages/NotFound">
13
+ <NotFoundWrapper data-component-name="Pages/NotFound">
14
14
  <StatusText>404</StatusText>
15
15
  <Title data-translation-key="theme.page.notFound.title">
16
16
  {translate('theme.page.notFound.title', 'Something went missing...')}
@@ -30,11 +30,11 @@ export function NotFound(): JSX.Element {
30
30
  >
31
31
  {translate('theme.page.homeButton', 'Go home')}
32
32
  </Button>
33
- </Wrapper>
33
+ </NotFoundWrapper>
34
34
  );
35
35
  }
36
36
 
37
- const Wrapper = styled.div`
37
+ const NotFoundWrapper = styled.div`
38
38
  height: 100%;
39
39
  max-width: var(--page-404-max-width);
40
40
  display: flex;
@@ -3,9 +3,9 @@ import React from 'react';
3
3
  import { Navbar } from '@redocly/theme/components/Navbar/Navbar';
4
4
  import { Footer } from '@redocly/theme/components/Footer/Footer';
5
5
 
6
- interface LayoutConfig {
6
+ export type LayoutConfig = {
7
7
  children: React.ReactNode;
8
- }
8
+ };
9
9
 
10
10
  export function RootLayout({ children }: LayoutConfig): JSX.Element {
11
11
  return (
@@ -1,8 +1,15 @@
1
1
  import * as React from 'react';
2
2
 
3
- export function InlineSvg({ fileRawContent }: { fileRawContent: string }) {
3
+ export function InlineSvg({
4
+ fileRawContent,
5
+ className,
6
+ }: {
7
+ fileRawContent: string;
8
+ className?: string;
9
+ }) {
4
10
  return (
5
11
  <span
12
+ className={className}
6
13
  data-component-name="Markdoc/InlineSvg/InlineSvg"
7
14
  dangerouslySetInnerHTML={{ __html: fileRawContent }}
8
15
  />
@@ -6,8 +6,8 @@ import { css } from "styled-components";
6
6
  */
7
7
 
8
8
  --md-tabs-container-text-color: inherit; // @presenter Color
9
- --md-tabs-container-font-size: var(--font-size-base); // @presenter FontSize
10
- --md-tabs-container-font-family: var(--font-size-base); // @presenter FontFamily
9
+ --md-tabs-container-font-size: var(--md-content-font-size); // @presenter FontSize
10
+ --md-tabs-container-font-family: var(--md-content-font-family); // @presenter FontFamily
11
11
  --md-tabs-container-font-style: normal; // @presenter FontStyle
12
12
  --md-tabs-container-font-weight: var(--font-weight-regular); // @presenter FontWeight
13
13
  --md-tabs-container-bg-color: inherit; // @presenter Color
@@ -20,8 +20,8 @@ import { css } from "styled-components";
20
20
  --md-tabs-padding: 0; // @presenter Spacing
21
21
 
22
22
  --md-tabs-content-text-color: inherit; // @presenter Color
23
- --md-tabs-content-font-size: var(--font-size-base); // @presenter FontSize
24
- --md-tabs-content-font-family: var(--font-size-base); // @presenter FontFamily
23
+ --md-tabs-content-font-size: var(--md-content-font-size); // @presenter FontSize
24
+ --md-tabs-content-font-family: var(--md-content-font-family); // @presenter FontFamily
25
25
  --md-tabs-content-font-style: normal; // @presenter FontStyle
26
26
  --md-tabs-content-font-weight: var(--font-weight-regular); // @presenter FontWeight
27
27
  --md-tabs-content-bg-color: inherit; // @presenter Color
@@ -31,7 +31,7 @@ import { css } from "styled-components";
31
31
 
32
32
  --md-tabs-tab-text-color: var(--text-color-primary); // @presenter Color
33
33
  --md-tabs-tab-font-size: var(--font-size-lg); // @presenter FontSize
34
- --md-tabs-tab-font-family: var(--font-size-base); // @presenter FontFamily
34
+ --md-tabs-tab-font-family: var(--md-content-font-family); // @presenter FontFamily
35
35
  --md-tabs-tab-font-style: normal; // @presenter FontStyle
36
36
  --md-tabs-tab-font-weight: var(--font-weight-bold); // @presenter FontWeight
37
37
  --md-tabs-tab-bg-color: none; // @presenter Color