@redocly/theme 0.82.2-rc.2 → 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.
- package/lib/components/Badge/Badge.d.ts +8 -5
- package/lib/components/Badge/Badge.js +9 -3
- package/lib/components/Breadcrumbs/Breadcrumb.d.ts +1 -1
- package/lib/components/Breadcrumbs/Breadcrumb.js +2 -2
- package/lib/components/Breadcrumbs/Breadcrumbs.d.ts +3 -3
- package/lib/components/Breadcrumbs/Breadcrumbs.js +2 -2
- package/lib/components/Button/Button.js +1 -1
- package/lib/components/Buttons/CopyButton.d.ts +2 -2
- package/lib/components/Buttons/CopyButton.js +3 -3
- package/lib/components/Buttons/EditPageButton.d.ts +2 -3
- package/lib/components/Buttons/EditPageButton.js +2 -2
- package/lib/components/Buttons/EmailButton.d.ts +4 -5
- package/lib/components/Buttons/EmailButton.js +2 -2
- package/lib/components/Buttons/NewTabButton.d.ts +4 -5
- package/lib/components/Buttons/NewTabButton.js +2 -2
- package/lib/components/Catalog/Catalog.d.ts +3 -2
- package/lib/components/Catalog/Catalog.js +1 -5
- package/lib/components/Catalog/CatalogActions.d.ts +1 -2
- package/lib/components/Catalog/CatalogCard.d.ts +1 -2
- package/lib/components/Catalog/CatalogCard.js +4 -5
- package/lib/components/Catalog/CatalogHighlight.d.ts +1 -2
- package/lib/components/Catalog/CatalogInfoBlock.d.ts +1 -2
- package/lib/components/CodeBlock/CodeBlock.js +1 -1
- package/lib/components/CodeBlock/CodeBlockContainer.d.ts +14 -5
- package/lib/components/CodeBlock/CodeBlockContainer.js +9 -4
- package/lib/components/CodeBlock/CodeBlockControls.js +2 -0
- package/lib/components/CodeBlock/CodeBlockTabs.d.ts +1 -2
- package/lib/components/CodeBlock/variables.js +2 -2
- package/lib/components/ColorModeSwitcher/ColorModeIcon.d.ts +4 -8
- package/lib/components/ColorModeSwitcher/ColorModeIcon.js +5 -3
- package/lib/components/ColorModeSwitcher/ColorModeSwitcher.d.ts +1 -2
- package/lib/components/DatePicker/DatePicker.d.ts +2 -3
- package/lib/components/Dropdown/Dropdown.d.ts +2 -3
- package/lib/components/Dropdown/Dropdown.js +10 -5
- package/lib/components/Dropdown/DropdownMenu.d.ts +1 -2
- package/lib/components/Dropdown/DropdownMenuItem.d.ts +1 -2
- package/lib/components/Dropdown/DropdownMenuItem.js +22 -5
- package/lib/components/Dropdown/variables.js +5 -1
- package/lib/components/Feedback/Comment.d.ts +2 -1
- package/lib/components/Feedback/Comment.js +3 -3
- package/lib/components/Feedback/Mood.js +4 -4
- package/lib/components/Feedback/Rating.js +1 -1
- package/lib/components/Feedback/ReportDialog.js +1 -1
- package/lib/components/Feedback/Scale.js +1 -1
- package/lib/components/Feedback/Sentiment.js +3 -3
- package/lib/components/Filter/FilterContent.d.ts +1 -3
- package/lib/components/Filter/FilterContent.js +4 -4
- package/lib/components/Filter/FilterInput.d.ts +1 -2
- package/lib/components/Filter/FilterOption.d.ts +8 -4
- package/lib/components/Filter/FilterOption.js +7 -4
- package/lib/components/Filter/FilterOptionLabel.d.ts +5 -3
- package/lib/components/Filter/FilterOptionLabel.js +6 -3
- package/lib/components/Filter/FilterOptions.d.ts +5 -3
- package/lib/components/Filter/FilterOptions.js +6 -3
- package/lib/components/Filter/FilterPopover.d.ts +1 -2
- package/lib/components/Filter/FilterSelect.js +1 -4
- package/lib/components/Filter/FilterTitle.d.ts +5 -3
- package/lib/components/Filter/FilterTitle.js +6 -3
- package/lib/components/Filter/variables.js +2 -1
- package/lib/components/Footer/Footer.d.ts +1 -2
- package/lib/components/Footer/FooterColumn.d.ts +1 -2
- package/lib/components/Footer/FooterCopyright.d.ts +1 -2
- package/lib/components/Footer/FooterItem.d.ts +1 -2
- package/lib/components/Footer/FooterLogo.d.ts +3 -4
- package/lib/components/Footer/FooterLogo.js +6 -1
- package/lib/components/Image/Image.d.ts +2 -2
- package/lib/components/JsonViewer/JsonViewer.d.ts +2 -2
- package/lib/components/LanguagePicker/LanguagePicker.d.ts +1 -2
- package/lib/components/LanguagePicker/LanguagePicker.js +5 -2
- package/lib/components/LanguagePicker/variables.js +4 -1
- package/lib/components/LastUpdated/LastUpdated.d.ts +1 -1
- package/lib/components/Link/Link.d.ts +1 -1
- package/lib/components/Loading/Loading.d.ts +2 -2
- package/lib/components/Logo/Logo.d.ts +1 -2
- package/lib/components/Markdown/Markdown.d.ts +12 -0
- package/lib/components/Markdown/Markdown.js +12 -13
- package/lib/components/Markdown/variables.js +10 -5
- package/lib/components/Menu/Menu.d.ts +1 -2
- package/lib/components/Menu/MenuContainer.d.ts +4 -4
- package/lib/components/Menu/MenuContainer.js +10 -3
- package/lib/components/Menu/MenuMobile.d.ts +1 -2
- package/lib/components/Menu/variables.js +2 -0
- package/lib/components/Navbar/NavbarItem.d.ts +1 -2
- package/lib/components/Navbar/NavbarItem.js +1 -1
- package/lib/components/Navbar/NavbarLogo.d.ts +3 -4
- package/lib/components/Navbar/NavbarLogo.js +6 -3
- package/lib/components/Navbar/NavbarMenu.d.ts +1 -2
- package/lib/components/PageNavigation/NextButton.d.ts +1 -2
- package/lib/components/PageNavigation/PageNavigation.d.ts +1 -2
- package/lib/components/PageNavigation/PreviousButton.d.ts +1 -2
- package/lib/components/Panel/Panel.d.ts +1 -2
- package/lib/components/Panel/PanelBody.d.ts +2 -3
- package/lib/components/Portal/Portal.d.ts +2 -3
- package/lib/components/Portal/Portal.js +2 -2
- package/lib/components/Product/Product.d.ts +1 -2
- package/lib/components/Product/ProductPicker.js +4 -1
- package/lib/components/Product/variables.js +4 -1
- package/lib/components/Search/Search.d.ts +1 -2
- package/lib/components/Search/SearchDialog.d.ts +1 -2
- package/lib/components/Search/SearchInput.d.ts +1 -2
- package/lib/components/Search/SearchItem.d.ts +1 -1
- package/lib/components/Search/SearchRecent.d.ts +1 -2
- package/lib/components/Search/SearchShortcut.d.ts +1 -2
- package/lib/components/Search/SearchSuggestedPages.d.ts +1 -2
- package/lib/components/Search/SearchTrigger.d.ts +1 -2
- package/lib/components/Search/variables.js +2 -2
- package/lib/components/Segmented/Segmented.d.ts +1 -1
- package/lib/components/Select/Select.d.ts +3 -3
- package/lib/components/Sidebar/Sidebar.d.ts +1 -2
- package/lib/components/SidebarActions/ChangeViewButton.d.ts +2 -3
- package/lib/components/SidebarActions/SidebarActions.d.ts +2 -2
- package/lib/components/SidebarLogo/SidebarLogo.d.ts +3 -3
- package/lib/components/TableOfContent/TableOfContent.d.ts +1 -2
- package/lib/components/Tag/Tag.d.ts +1 -1
- package/lib/components/Tooltip/Tooltip.js +2 -2
- package/lib/components/Tooltip/variables.js +4 -0
- package/lib/components/Typography/H1.js +1 -1
- package/lib/components/Typography/H2.js +1 -1
- package/lib/components/Typography/H3.js +1 -1
- package/lib/components/Typography/H4.js +1 -1
- package/lib/components/UserMenu/UserAvatar.d.ts +1 -2
- package/lib/components/UserMenu/UserInfoMenuItem.d.ts +1 -2
- package/lib/components/UserMenu/UserMenu.d.ts +1 -2
- package/lib/components/UserMenu/UserMenu.js +4 -1
- package/lib/components/UserMenu/UserMenuMobile.d.ts +1 -2
- package/lib/components/UserMenu/variables.js +4 -1
- package/lib/components/VersionPicker/VersionPicker.d.ts +1 -1
- package/lib/core/types/catalog.d.ts +3 -0
- package/lib/core/types/hooks.d.ts +3 -1
- package/lib/layouts/DocumentationLayout.js +7 -0
- package/lib/layouts/NotFound.js +2 -2
- package/lib/layouts/RootLayout.d.ts +2 -3
- package/lib/markdoc/components/InlineSvg/InlineSvg.d.ts +2 -1
- package/lib/markdoc/components/InlineSvg/InlineSvg.js +2 -2
- package/lib/markdoc/components/Tabs/variables.js +5 -5
- package/package.json +4 -4
- package/src/components/Badge/Badge.tsx +13 -3
- package/src/components/Breadcrumbs/Breadcrumb.tsx +2 -2
- package/src/components/Breadcrumbs/Breadcrumbs.tsx +2 -2
- package/src/components/Button/Button.tsx +5 -1
- package/src/components/Buttons/CopyButton.tsx +7 -5
- package/src/components/Buttons/EditPageButton.tsx +3 -3
- package/src/components/Buttons/EmailButton.tsx +4 -4
- package/src/components/Buttons/NewTabButton.tsx +7 -4
- package/src/components/Catalog/Catalog.tsx +5 -7
- package/src/components/Catalog/CatalogActions.tsx +1 -1
- package/src/components/Catalog/CatalogCard.tsx +23 -24
- package/src/components/Catalog/CatalogHighlight.tsx +1 -1
- package/src/components/Catalog/CatalogInfoBlock.tsx +1 -1
- package/src/components/CodeBlock/CodeBlock.tsx +1 -1
- package/src/components/CodeBlock/CodeBlockContainer.tsx +19 -6
- package/src/components/CodeBlock/CodeBlockControls.tsx +2 -0
- package/src/components/CodeBlock/CodeBlockTabs.tsx +1 -1
- package/src/components/CodeBlock/variables.ts +2 -2
- package/src/components/ColorModeSwitcher/ColorModeIcon.tsx +8 -4
- package/src/components/ColorModeSwitcher/ColorModeSwitcher.tsx +1 -1
- package/src/components/DatePicker/DatePicker.tsx +2 -2
- package/src/components/Dropdown/Dropdown.tsx +14 -8
- package/src/components/Dropdown/DropdownMenu.tsx +1 -1
- package/src/components/Dropdown/DropdownMenuItem.tsx +25 -6
- package/src/components/Dropdown/variables.ts +5 -1
- package/src/components/Feedback/Comment.tsx +4 -2
- package/src/components/Feedback/Mood.tsx +5 -4
- package/src/components/Feedback/Rating.tsx +1 -1
- package/src/components/Feedback/ReportDialog.tsx +1 -0
- package/src/components/Feedback/Scale.tsx +1 -1
- package/src/components/Feedback/Sentiment.tsx +4 -3
- package/src/components/Filter/FilterContent.tsx +3 -3
- package/src/components/Filter/FilterInput.tsx +1 -1
- package/src/components/Filter/FilterOption.tsx +20 -4
- package/src/components/Filter/FilterOptionLabel.tsx +10 -3
- package/src/components/Filter/FilterOptions.tsx +10 -3
- package/src/components/Filter/FilterPopover.tsx +1 -1
- package/src/components/Filter/FilterSelect.tsx +1 -4
- package/src/components/Filter/FilterTitle.tsx +10 -3
- package/src/components/Filter/variables.ts +2 -1
- package/src/components/Footer/Footer.tsx +1 -1
- package/src/components/Footer/FooterColumn.tsx +1 -1
- package/src/components/Footer/FooterCopyright.tsx +1 -1
- package/src/components/Footer/FooterItem.tsx +1 -1
- package/src/components/Footer/FooterLogo.tsx +8 -1
- package/src/components/Image/Image.tsx +1 -1
- package/src/components/JsonViewer/JsonViewer.tsx +2 -2
- package/src/components/LanguagePicker/LanguagePicker.tsx +6 -3
- package/src/components/LanguagePicker/variables.ts +4 -1
- package/src/components/LastUpdated/LastUpdated.tsx +1 -1
- package/src/components/Link/Link.tsx +1 -1
- package/src/components/Loading/Loading.tsx +2 -2
- package/src/components/Logo/Logo.tsx +1 -1
- package/src/components/Markdown/Markdown.tsx +23 -14
- package/src/components/Markdown/variables.ts +10 -5
- package/src/components/Menu/Menu.tsx +1 -1
- package/src/components/Menu/MenuContainer.tsx +9 -5
- package/src/components/Menu/MenuMobile.tsx +1 -1
- package/src/components/Menu/variables.ts +2 -0
- package/src/components/Navbar/Navbar.tsx +1 -0
- package/src/components/Navbar/NavbarItem.tsx +2 -2
- package/src/components/Navbar/NavbarLogo.tsx +8 -3
- package/src/components/Navbar/NavbarMenu.tsx +1 -1
- package/src/components/PageNavigation/NextButton.tsx +1 -1
- package/src/components/PageNavigation/PageNavigation.tsx +1 -1
- package/src/components/PageNavigation/PreviousButton.tsx +1 -1
- package/src/components/Panel/Panel.tsx +1 -1
- package/src/components/Panel/PanelBody.ts +2 -2
- package/src/components/Portal/Portal.tsx +6 -3
- package/src/components/Product/Product.tsx +1 -1
- package/src/components/Product/ProductPicker.tsx +4 -1
- package/src/components/Product/variables.ts +4 -1
- package/src/components/Search/Search.tsx +1 -1
- package/src/components/Search/SearchDialog.tsx +1 -1
- package/src/components/Search/SearchInput.tsx +1 -1
- package/src/components/Search/SearchItem.tsx +1 -1
- package/src/components/Search/SearchRecent.tsx +1 -1
- package/src/components/Search/SearchShortcut.tsx +1 -1
- package/src/components/Search/SearchSuggestedPages.tsx +1 -1
- package/src/components/Search/SearchTrigger.tsx +1 -1
- package/src/components/Search/variables.ts +2 -2
- package/src/components/Segmented/Segmented.tsx +1 -1
- package/src/components/Select/Select.tsx +3 -3
- package/src/components/Sidebar/Sidebar.tsx +1 -1
- package/src/components/SidebarActions/ChangeViewButton.tsx +2 -2
- package/src/components/SidebarActions/SidebarActions.tsx +2 -2
- package/src/components/SidebarLogo/SidebarLogo.tsx +3 -3
- package/src/components/TableOfContent/TableOfContent.tsx +1 -1
- package/src/components/Tag/Tag.tsx +1 -1
- package/src/components/Tooltip/Tooltip.tsx +2 -2
- package/src/components/Tooltip/variables.ts +4 -0
- package/src/components/Typography/H1.ts +1 -1
- package/src/components/Typography/H2.ts +1 -1
- package/src/components/Typography/H3.ts +1 -1
- package/src/components/Typography/H4.ts +1 -1
- package/src/components/UserMenu/UserAvatar.tsx +1 -1
- package/src/components/UserMenu/UserInfoMenuItem.tsx +1 -1
- package/src/components/UserMenu/UserMenu.tsx +5 -2
- package/src/components/UserMenu/UserMenuMobile.tsx +1 -1
- package/src/components/UserMenu/variables.ts +4 -1
- package/src/core/types/catalog.ts +3 -1
- package/src/core/types/hooks.ts +3 -1
- package/src/layouts/DocumentationLayout.tsx +7 -0
- package/src/layouts/NotFound.tsx +3 -3
- package/src/layouts/RootLayout.tsx +2 -2
- package/src/markdoc/components/InlineSvg/InlineSvg.tsx +8 -1
- package/src/markdoc/components/Tabs/variables.ts +5 -5
|
@@ -13,6 +13,6 @@ exports.H1 = styled_components_1.default.h1.attrs(({ className }) => ({
|
|
|
13
13
|
color: var(--h1-text-color);
|
|
14
14
|
margin: var(--h1-margin-top) 0 var(--h1-margin-bottom);
|
|
15
15
|
|
|
16
|
-
${(0, utils_1.typography)('h1'
|
|
16
|
+
${(0, utils_1.typography)('h1')};
|
|
17
17
|
`;
|
|
18
18
|
//# sourceMappingURL=H1.js.map
|
|
@@ -13,6 +13,6 @@ exports.H2 = styled_components_1.default.h2.attrs(({ className }) => ({
|
|
|
13
13
|
color: var(--h2-text-color);
|
|
14
14
|
margin: var(--h2-margin-top) 0 var(--h2-margin-bottom);
|
|
15
15
|
|
|
16
|
-
${(0, utils_1.typography)('h2'
|
|
16
|
+
${(0, utils_1.typography)('h2')};
|
|
17
17
|
`;
|
|
18
18
|
//# sourceMappingURL=H2.js.map
|
|
@@ -13,6 +13,6 @@ exports.H3 = styled_components_1.default.h3.attrs(({ className }) => ({
|
|
|
13
13
|
color: var(--h3-text-color);
|
|
14
14
|
margin: var(--h3-margin-top) 0 var(--h3-margin-bottom);
|
|
15
15
|
|
|
16
|
-
${(0, utils_1.typography)('h3'
|
|
16
|
+
${(0, utils_1.typography)('h3')};
|
|
17
17
|
`;
|
|
18
18
|
//# sourceMappingURL=H3.js.map
|
|
@@ -13,6 +13,6 @@ exports.H4 = styled_components_1.default.h4.attrs(({ className }) => ({
|
|
|
13
13
|
color: var(--h4-text-color);
|
|
14
14
|
margin: var(--h4-margin-top) 0 var(--h4-margin-bottom);
|
|
15
15
|
|
|
16
|
-
${(0, utils_1.typography)('h4'
|
|
16
|
+
${(0, utils_1.typography)('h4')};
|
|
17
17
|
`;
|
|
18
18
|
//# sourceMappingURL=H4.js.map
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
type UserAvatarProps = {
|
|
2
|
+
export type UserAvatarProps = {
|
|
3
3
|
picture?: string;
|
|
4
4
|
className?: string;
|
|
5
5
|
height?: `var(${string})` | `${number}px`;
|
|
6
6
|
width?: `var(${string})` | `${number}px`;
|
|
7
7
|
};
|
|
8
8
|
export declare function UserAvatar({ picture, className, height, width, }: UserAvatarProps): JSX.Element;
|
|
9
|
-
export {};
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
type UserInfoMenuItemProps = {
|
|
2
|
+
export type UserInfoMenuItemProps = {
|
|
3
3
|
name: string;
|
|
4
4
|
email?: string;
|
|
5
5
|
picture?: string;
|
|
6
6
|
className?: string;
|
|
7
7
|
};
|
|
8
8
|
export declare function UserInfoMenuItem({ name, picture, email, className, }: UserInfoMenuItemProps): JSX.Element;
|
|
9
|
-
export {};
|
|
@@ -72,7 +72,6 @@ const StyledDropdown = (0, styled_components_1.default)(Dropdown_1.Dropdown).att
|
|
|
72
72
|
--dropdown-menu-padding: var(--user-menu-dropdown-padding);
|
|
73
73
|
--dropdown-menu-border-radius: var(--user-menu-dropdown-border-radius);
|
|
74
74
|
--dropdown-menu-box-shadow: var(--user-menu-dropdown-box-shadow);
|
|
75
|
-
--dropdown-menu-color-disabled: var(--user-menu-dropdown-color-disabled);
|
|
76
75
|
--dropdown-menu-border-color: var(--user-menu-dropdown-border-color);
|
|
77
76
|
--dropdown-menu-bg-color: var(--user-menu-dropdown-bg-color);
|
|
78
77
|
--dropdown-menu-item-padding-horizontal: var(--user-menu-dropdown-item-padding-horizontal);
|
|
@@ -84,9 +83,13 @@ const StyledDropdown = (0, styled_components_1.default)(Dropdown_1.Dropdown).att
|
|
|
84
83
|
--dropdown-menu-item-border-radius: var(--user-menu-dropdown-item-border-radius);
|
|
85
84
|
--dropdown-menu-item-bg-color-active: var(--user-menu-dropdown-item-bg-color-active);
|
|
86
85
|
--dropdown-menu-item-bg-color-hover: var(--user-menu-dropdown-item-bg-color-hover);
|
|
86
|
+
--dropdown-menu-item-bg-color-disabled: var(--user-menu-dropdown-item-bg-color-disabled);
|
|
87
87
|
--dropdown-menu-item-separator-border-color: var(
|
|
88
88
|
--user-menu-dropdown-item-separator-border-color
|
|
89
89
|
);
|
|
90
90
|
--dropdown-menu-item-color-dangerous: var(--user-menu-dropdown-item-color-dangerous);
|
|
91
|
+
--dropdown-menu-item-color-disabled: var(--user-menu-dropdown-item-color-disabled);
|
|
92
|
+
--dropdown-menu-item-color-active: var(--user-menu-dropdown-item-color-active);
|
|
93
|
+
--dropdown-menu-item-color-hover: var(--user-menu-dropdown-item-color-hover);
|
|
91
94
|
`;
|
|
92
95
|
//# sourceMappingURL=UserMenu.js.map
|
|
@@ -44,7 +44,6 @@ exports.userMenu = (0, styled_components_1.css) `
|
|
|
44
44
|
--user-menu-dropdown-padding: var(--dropdown-menu-padding ); // @presenter Spacing
|
|
45
45
|
--user-menu-dropdown-border-radius: var(--dropdown-menu-border-radius); // @presenter BorderRadius
|
|
46
46
|
--user-menu-dropdown-box-shadow: var(--dropdown-menu-box-shadow); // @presenter Shadow
|
|
47
|
-
--user-menu-dropdown-color-disabled: var(--dropdown-menu-color-disabled); // @presenter Color
|
|
48
47
|
--user-menu-dropdown-border-color: var(--dropdown-menu-border-color); // @presenter Color
|
|
49
48
|
--user-menu-dropdown-bg-color: var(--dropdown-menu-bg-color); // @presenter Color
|
|
50
49
|
|
|
@@ -55,8 +54,12 @@ exports.userMenu = (0, styled_components_1.css) `
|
|
|
55
54
|
--user-menu-dropdown-item-border-radius: var(--dropdown-menu-item-border-radius ); // @presenter BorderRadius
|
|
56
55
|
--user-menu-dropdown-item-bg-color-active: var(--dropdown-menu-item-bg-color-active); // @presenter Color
|
|
57
56
|
--user-menu-dropdown-item-bg-color-hover: var(--dropdown-menu-item-bg-color-hover); // @presenter Color
|
|
57
|
+
--user-menu-dropdown-item-bg-color-disabled: var(--dropdown-menu-item-bg-color-disabled); // @presenter Color
|
|
58
58
|
--user-menu-dropdown-item-separator-border-color: var(--dropdown-menu-item-separator-border-color); // @presenter Color
|
|
59
59
|
--user-menu-dropdown-item-color-dangerous: var(--dropdown-menu-item-color-dangerous);
|
|
60
|
+
--user-menu-dropdown-item-color-disabled: var(--dropdown-menu-item-color-disabled);
|
|
61
|
+
--user-menu-dropdown-item-color-active: var(--dropdown-menu-item-color-active);
|
|
62
|
+
--user-menu-dropdown-item-color-hover: var(--dropdown-menu-item-color-hover);
|
|
60
63
|
--user-menu-dropdown-item-border-color-focused: var(--dropdown-menu-item-border-color-focused);
|
|
61
64
|
|
|
62
65
|
// @tokens End
|
|
@@ -7,4 +7,4 @@ export declare function VersionPicker(props: {
|
|
|
7
7
|
versions?: Version[];
|
|
8
8
|
onChange: (v: Version) => void;
|
|
9
9
|
}): React.JSX.Element | null;
|
|
10
|
-
export declare const VersionPickerSelect: import("styled-components").StyledComponent<typeof Select, any, SelectProps
|
|
10
|
+
export declare const VersionPickerSelect: import("styled-components").StyledComponent<typeof Select, any, SelectProps, never>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import type { ResolvedNavItemWithLink, Version } from '@redocly/config';
|
|
2
|
+
import type { PageProps, ResolvedNavItemWithLink, Version } from '@redocly/config';
|
|
3
3
|
import type { Callback, TFunction as TFunc } from 'i18next';
|
|
4
4
|
import type { To, Location } from 'react-router-dom';
|
|
5
5
|
import type { CatalogConfig, ProductUiConfig } from '../../config';
|
|
@@ -60,6 +60,8 @@ export type ThemeHooks = {
|
|
|
60
60
|
useTelemetry: () => {
|
|
61
61
|
send(action: TelemetryEvent, data: unknown): void;
|
|
62
62
|
};
|
|
63
|
+
useUserTeams: () => string[];
|
|
64
|
+
usePageProps: <T extends Record<string, unknown>>() => PageProps & T;
|
|
63
65
|
};
|
|
64
66
|
export type I18nConfig = {
|
|
65
67
|
currentLocale: string;
|
|
@@ -35,6 +35,13 @@ const LayoutWrapper = styled_components_1.default.div.attrs(({ className }) => (
|
|
|
35
35
|
width: 100%;
|
|
36
36
|
`;
|
|
37
37
|
const ContentWrapper = styled_components_1.default.section `
|
|
38
|
+
--md-content-font-size: var(--font-size-lg);
|
|
39
|
+
--md-content-line-height: var(--line-height-lg);
|
|
40
|
+
--md-table-font-size: var(--md-content-font-size);
|
|
41
|
+
--md-table-line-height: var(--md-content-line-height);
|
|
42
|
+
--md-tabs-content-font-size: var(--md-content-font-size);
|
|
43
|
+
--md-tabs-content-line-height: var(--md-content-line-height);
|
|
44
|
+
|
|
38
45
|
max-width: var(--md-content-max-width);
|
|
39
46
|
width: 90%;
|
|
40
47
|
margin: 0 auto;
|
package/lib/layouts/NotFound.js
CHANGED
|
@@ -12,14 +12,14 @@ const ArrowLeftIcon_1 = require("../icons/ArrowLeftIcon/ArrowLeftIcon");
|
|
|
12
12
|
function NotFound() {
|
|
13
13
|
const { useTranslate } = (0, hooks_1.useThemeHooks)();
|
|
14
14
|
const { translate } = useTranslate();
|
|
15
|
-
return (react_1.default.createElement(
|
|
15
|
+
return (react_1.default.createElement(NotFoundWrapper, { "data-component-name": "Pages/NotFound" },
|
|
16
16
|
react_1.default.createElement(StatusText, null, "404"),
|
|
17
17
|
react_1.default.createElement(Title, { "data-translation-key": "theme.page.notFound.title" }, translate('theme.page.notFound.title', 'Something went missing...')),
|
|
18
18
|
react_1.default.createElement(Description, { "data-translation-key": "theme.page.notFound.description" }, translate('theme.page.notFound.description', "The page you were trying to reach doesn't exist or may have been moved. You can go back to the previous page, return to the homepage, or use the search bar to find what you're looking for.")),
|
|
19
19
|
react_1.default.createElement(Button_1.Button, { variant: "primary", size: "large", to: "/", "data-translation-key": "theme.page.homeButton", icon: react_1.default.createElement(ArrowLeftIcon_1.ArrowLeftIcon, null) }, translate('theme.page.homeButton', 'Go home'))));
|
|
20
20
|
}
|
|
21
21
|
exports.NotFound = NotFound;
|
|
22
|
-
const
|
|
22
|
+
const NotFoundWrapper = styled_components_1.default.div `
|
|
23
23
|
height: 100%;
|
|
24
24
|
max-width: var(--page-404-max-width);
|
|
25
25
|
display: flex;
|
|
@@ -25,8 +25,8 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
26
|
exports.InlineSvg = void 0;
|
|
27
27
|
const React = __importStar(require("react"));
|
|
28
|
-
function InlineSvg({ fileRawContent }) {
|
|
29
|
-
return (React.createElement("span", { "data-component-name": "Markdoc/InlineSvg/InlineSvg", dangerouslySetInnerHTML: { __html: fileRawContent } }));
|
|
28
|
+
function InlineSvg({ fileRawContent, className, }) {
|
|
29
|
+
return (React.createElement("span", { className: className, "data-component-name": "Markdoc/InlineSvg/InlineSvg", dangerouslySetInnerHTML: { __html: fileRawContent } }));
|
|
30
30
|
}
|
|
31
31
|
exports.InlineSvg = InlineSvg;
|
|
32
32
|
//# sourceMappingURL=InlineSvg.js.map
|
|
@@ -8,8 +8,8 @@ exports.markdownTabs = (0, styled_components_1.css) `
|
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
--md-tabs-container-text-color: inherit; // @presenter Color
|
|
11
|
-
--md-tabs-container-font-size: var(--font-size
|
|
12
|
-
--md-tabs-container-font-family: var(--font-
|
|
11
|
+
--md-tabs-container-font-size: var(--md-content-font-size); // @presenter FontSize
|
|
12
|
+
--md-tabs-container-font-family: var(--md-content-font-family); // @presenter FontFamily
|
|
13
13
|
--md-tabs-container-font-style: normal; // @presenter FontStyle
|
|
14
14
|
--md-tabs-container-font-weight: var(--font-weight-regular); // @presenter FontWeight
|
|
15
15
|
--md-tabs-container-bg-color: inherit; // @presenter Color
|
|
@@ -22,8 +22,8 @@ exports.markdownTabs = (0, styled_components_1.css) `
|
|
|
22
22
|
--md-tabs-padding: 0; // @presenter Spacing
|
|
23
23
|
|
|
24
24
|
--md-tabs-content-text-color: inherit; // @presenter Color
|
|
25
|
-
--md-tabs-content-font-size: var(--font-size
|
|
26
|
-
--md-tabs-content-font-family: var(--font-
|
|
25
|
+
--md-tabs-content-font-size: var(--md-content-font-size); // @presenter FontSize
|
|
26
|
+
--md-tabs-content-font-family: var(--md-content-font-family); // @presenter FontFamily
|
|
27
27
|
--md-tabs-content-font-style: normal; // @presenter FontStyle
|
|
28
28
|
--md-tabs-content-font-weight: var(--font-weight-regular); // @presenter FontWeight
|
|
29
29
|
--md-tabs-content-bg-color: inherit; // @presenter Color
|
|
@@ -33,7 +33,7 @@ exports.markdownTabs = (0, styled_components_1.css) `
|
|
|
33
33
|
|
|
34
34
|
--md-tabs-tab-text-color: var(--text-color-primary); // @presenter Color
|
|
35
35
|
--md-tabs-tab-font-size: var(--font-size-lg); // @presenter FontSize
|
|
36
|
-
--md-tabs-tab-font-family: var(--font-
|
|
36
|
+
--md-tabs-tab-font-family: var(--md-content-font-family); // @presenter FontFamily
|
|
37
37
|
--md-tabs-tab-font-style: normal; // @presenter FontStyle
|
|
38
38
|
--md-tabs-tab-font-weight: var(--font-weight-bold); // @presenter FontWeight
|
|
39
39
|
--md-tabs-tab-bg-color: none; // @presenter Color
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@redocly/theme",
|
|
3
|
-
"version": "0.82.
|
|
3
|
+
"version": "0.82.4-rc.1",
|
|
4
4
|
"description": "Shared UI components lib",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"theme",
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
"json-schema-to-ts": "2.7.2",
|
|
73
73
|
"lodash.throttle": "4.1.1",
|
|
74
74
|
"npm-run-all2": "5.0.2",
|
|
75
|
-
"react-refresh": "0.14.
|
|
75
|
+
"react-refresh": "0.14.2",
|
|
76
76
|
"react-router-dom": "6.21.1",
|
|
77
77
|
"rimraf": "5.0.5",
|
|
78
78
|
"storybook": "7.6.4",
|
|
@@ -87,7 +87,7 @@
|
|
|
87
87
|
"tsconfig-paths": "4.2.0",
|
|
88
88
|
"tsconfig-paths-webpack-plugin": "3.5.2",
|
|
89
89
|
"typescript": "5.2.2",
|
|
90
|
-
"webpack": "5.
|
|
90
|
+
"webpack": "5.91.0"
|
|
91
91
|
},
|
|
92
92
|
"dependencies": {
|
|
93
93
|
"copy-to-clipboard": "^3.3.3",
|
|
@@ -98,7 +98,7 @@
|
|
|
98
98
|
"timeago.js": "^4.0.2",
|
|
99
99
|
"i18next": "^22.4.12",
|
|
100
100
|
"nprogress": "^0.2.0",
|
|
101
|
-
"@redocly/config": "0.82.
|
|
101
|
+
"@redocly/config": "0.82.4-rc.1"
|
|
102
102
|
},
|
|
103
103
|
"scripts": {
|
|
104
104
|
"start": "npm-run-all --parallel storybook storybook:tokens:watch",
|
|
@@ -1,8 +1,18 @@
|
|
|
1
|
+
import React, { type PropsWithChildren } from 'react';
|
|
1
2
|
import styled, { css } from 'styled-components';
|
|
2
3
|
|
|
3
|
-
export
|
|
4
|
-
|
|
5
|
-
|
|
4
|
+
export type BadgeProps = PropsWithChildren<{
|
|
5
|
+
deprecated?: boolean;
|
|
6
|
+
color?: string;
|
|
7
|
+
key?: string;
|
|
8
|
+
className?: string;
|
|
9
|
+
}>;
|
|
10
|
+
|
|
11
|
+
export function Badge(props: BadgeProps): JSX.Element {
|
|
12
|
+
return <BadgeComponent {...props} data-component-name="Badge/Badge" />;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
const BadgeComponent = styled.span<BadgeProps>`
|
|
6
16
|
display: inline-block;
|
|
7
17
|
padding: 0 var(--spacing-xs);
|
|
8
18
|
vertical-align: middle;
|
|
@@ -10,7 +10,7 @@ type BreadcrumbProps = {
|
|
|
10
10
|
onClick?: () => void;
|
|
11
11
|
};
|
|
12
12
|
|
|
13
|
-
export
|
|
13
|
+
export function Breadcrumb({ label, link, isActive, onClick }: BreadcrumbProps): JSX.Element {
|
|
14
14
|
return (
|
|
15
15
|
<BreadcrumbWrapper
|
|
16
16
|
data-component-name="Breadcrumbs/Breadcrumb"
|
|
@@ -25,7 +25,7 @@ export const Breadcrumb = ({ label, link, isActive, onClick }: BreadcrumbProps):
|
|
|
25
25
|
)}
|
|
26
26
|
</BreadcrumbWrapper>
|
|
27
27
|
);
|
|
28
|
-
}
|
|
28
|
+
}
|
|
29
29
|
|
|
30
30
|
const BreadcrumbText = styled.div`
|
|
31
31
|
cursor: default;
|
|
@@ -4,7 +4,7 @@ import styled from 'styled-components';
|
|
|
4
4
|
import { useThemeHooks } from '@redocly/theme/core/hooks';
|
|
5
5
|
import { Breadcrumb } from '@redocly/theme/components/Breadcrumbs/Breadcrumb';
|
|
6
6
|
|
|
7
|
-
export
|
|
7
|
+
export function Breadcrumbs(props: { className?: string }): JSX.Element | null {
|
|
8
8
|
const { useBreadcrumbs, useTelemetry } = useThemeHooks();
|
|
9
9
|
const telemetry = useTelemetry();
|
|
10
10
|
const breadcrumbs = useBreadcrumbs();
|
|
@@ -37,7 +37,7 @@ export const Breadcrumbs = (props: { className?: string }) => {
|
|
|
37
37
|
})}
|
|
38
38
|
</BreadcrumbsWrapper>
|
|
39
39
|
);
|
|
40
|
-
}
|
|
40
|
+
}
|
|
41
41
|
|
|
42
42
|
const BreadcrumbsWrapper = styled.div`
|
|
43
43
|
display: flex;
|
|
@@ -191,7 +191,11 @@ const ButtonComponent: React.FC<ButtonProps> = (props) => {
|
|
|
191
191
|
);
|
|
192
192
|
|
|
193
193
|
if (props.to) {
|
|
194
|
-
return
|
|
194
|
+
return (
|
|
195
|
+
<StyledButtonLink to={props.to} onClick={props.onClick}>
|
|
196
|
+
{button}
|
|
197
|
+
</StyledButtonLink>
|
|
198
|
+
);
|
|
195
199
|
} else {
|
|
196
200
|
return button;
|
|
197
201
|
}
|
|
@@ -9,7 +9,7 @@ import { Button } from '@redocly/theme/components/Button/Button';
|
|
|
9
9
|
import { CopyIcon } from '@redocly/theme/icons/CopyIcon/CopyIcon';
|
|
10
10
|
import { Tooltip } from '@redocly/theme/components/Tooltip/Tooltip';
|
|
11
11
|
|
|
12
|
-
type CopyButtonProps = {
|
|
12
|
+
export type CopyButtonProps = {
|
|
13
13
|
data: unknown;
|
|
14
14
|
type?: ControlItemType;
|
|
15
15
|
toasterPlacement?: TooltipProps['placement'];
|
|
@@ -19,9 +19,10 @@ type CopyButtonProps = {
|
|
|
19
19
|
onCopyClick?: (e: React.MouseEvent<HTMLElement>) => void;
|
|
20
20
|
dataTestId?: string;
|
|
21
21
|
className?: string;
|
|
22
|
+
variant?: string;
|
|
22
23
|
};
|
|
23
24
|
|
|
24
|
-
|
|
25
|
+
function CopyButtonComponent({
|
|
25
26
|
data,
|
|
26
27
|
type = 'icon',
|
|
27
28
|
toasterPlacement = 'top',
|
|
@@ -31,7 +32,8 @@ const CopyButtonComponent = ({
|
|
|
31
32
|
onCopyClick,
|
|
32
33
|
dataTestId = 'copy-button',
|
|
33
34
|
className,
|
|
34
|
-
|
|
35
|
+
variant = 'text',
|
|
36
|
+
}: CopyButtonProps): JSX.Element {
|
|
35
37
|
const { useTranslate } = useThemeHooks();
|
|
36
38
|
const tooltip = useControl();
|
|
37
39
|
const { translate } = useTranslate();
|
|
@@ -64,12 +66,12 @@ const CopyButtonComponent = ({
|
|
|
64
66
|
data-testid={dataTestId}
|
|
65
67
|
icon={type === 'icon' ? <CopyIcon /> : undefined}
|
|
66
68
|
size="small"
|
|
67
|
-
variant=
|
|
69
|
+
variant={variant}
|
|
68
70
|
>
|
|
69
71
|
{type !== 'icon' && translate('theme.codeSnippet.copy.toasterText', buttonText || 'Copy')}
|
|
70
72
|
</Button>
|
|
71
73
|
</Tooltip>
|
|
72
74
|
);
|
|
73
|
-
}
|
|
75
|
+
}
|
|
74
76
|
|
|
75
77
|
export const CopyButton = memo<CopyButtonProps>(CopyButtonComponent);
|
|
@@ -5,11 +5,11 @@ import { useThemeHooks } from '@redocly/theme/core/hooks';
|
|
|
5
5
|
import { EditIcon } from '@redocly/theme/icons/EditIcon/EditIcon';
|
|
6
6
|
import { Link } from '@redocly/theme/components/Link/Link';
|
|
7
7
|
|
|
8
|
-
type EditPageButtonProps = {
|
|
8
|
+
export type EditPageButtonProps = {
|
|
9
9
|
to: string;
|
|
10
10
|
};
|
|
11
11
|
|
|
12
|
-
export
|
|
12
|
+
export function EditPageButton({ to }: EditPageButtonProps): JSX.Element {
|
|
13
13
|
const { useTranslate, useTelemetry } = useThemeHooks();
|
|
14
14
|
const { translate } = useTranslate();
|
|
15
15
|
const telemetry = useTelemetry();
|
|
@@ -26,7 +26,7 @@ export const EditPageButton = ({ to }: EditPageButtonProps): JSX.Element => {
|
|
|
26
26
|
</ButtonText>
|
|
27
27
|
</EditPageButtonWrapper>
|
|
28
28
|
);
|
|
29
|
-
}
|
|
29
|
+
}
|
|
30
30
|
|
|
31
31
|
const EditPageButtonWrapper = styled(Link)`
|
|
32
32
|
height: fit-content;
|
|
@@ -3,12 +3,12 @@ import React from 'react';
|
|
|
3
3
|
import { Button } from '@redocly/theme/components/Button/Button';
|
|
4
4
|
import { EmailIcon } from '@redocly/theme/icons/EmailIcon/EmailIcon';
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
export type EmailButtonProps = {
|
|
7
7
|
data: string;
|
|
8
8
|
dataTestId?: string;
|
|
9
|
-
}
|
|
9
|
+
};
|
|
10
10
|
|
|
11
|
-
export
|
|
11
|
+
export function EmailButton({ data, dataTestId = 'email-button' }: EmailButtonProps): JSX.Element {
|
|
12
12
|
const onClick = () => {
|
|
13
13
|
window.location.href = `mailto:${data}`;
|
|
14
14
|
};
|
|
@@ -25,4 +25,4 @@ export const EmailButton = ({ data, dataTestId = 'email-button' }: EmailButtonPr
|
|
|
25
25
|
/>
|
|
26
26
|
</div>
|
|
27
27
|
);
|
|
28
|
-
}
|
|
28
|
+
}
|
|
@@ -3,12 +3,15 @@ import React from 'react';
|
|
|
3
3
|
import { Button } from '@redocly/theme/components/Button/Button';
|
|
4
4
|
import { ArrowUpRightIcon } from '@redocly/theme/icons/ArrowUpRightIcon/ArrowUpRightIcon';
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
export type NewTabButtonProps = {
|
|
7
7
|
data: string;
|
|
8
8
|
dataTestId?: string;
|
|
9
|
-
}
|
|
9
|
+
};
|
|
10
10
|
|
|
11
|
-
export
|
|
11
|
+
export function NewTabButton({
|
|
12
|
+
data,
|
|
13
|
+
dataTestId = 'new-tab-button',
|
|
14
|
+
}: NewTabButtonProps): JSX.Element {
|
|
12
15
|
const onClick = () => {
|
|
13
16
|
window.open(data, '_blank');
|
|
14
17
|
};
|
|
@@ -25,4 +28,4 @@ export const NewTabButton = ({ data, dataTestId = 'new-tab-button' }: NewTabButt
|
|
|
25
28
|
/>
|
|
26
29
|
</div>
|
|
27
30
|
);
|
|
28
|
-
}
|
|
31
|
+
}
|
|
@@ -12,15 +12,16 @@ import { FilterPopover } from '@redocly/theme/components/Filter/FilterPopover';
|
|
|
12
12
|
import { HighlightContext } from '@redocly/theme/components/Catalog/CatalogHighlight';
|
|
13
13
|
import { CatalogActions } from '@redocly/theme/components/Catalog/CatalogActions';
|
|
14
14
|
import { Sidebar } from '@redocly/theme/components/Sidebar/Sidebar';
|
|
15
|
-
import { MenuContainer } from '@redocly/theme/components/Menu/MenuContainer';
|
|
16
15
|
import { CounterTag } from '@redocly/theme/components/Tags/CounterTag';
|
|
17
16
|
|
|
18
|
-
export
|
|
17
|
+
export type CatalogProps = {
|
|
19
18
|
pageProps: {
|
|
20
19
|
catalogId: string;
|
|
21
20
|
catalogConfig: CatalogConfig;
|
|
22
21
|
};
|
|
23
|
-
}
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
export default function Catalog(props: CatalogProps): JSX.Element {
|
|
24
25
|
const { catalogConfig } = props.pageProps;
|
|
25
26
|
const { useTranslate, useCatalog } = useThemeHooks();
|
|
26
27
|
|
|
@@ -184,8 +185,5 @@ const FiltersSidebar = styled(Sidebar)`
|
|
|
184
185
|
@media screen and (min-width: ${breakpoints.medium}) {
|
|
185
186
|
display: flex;
|
|
186
187
|
}
|
|
187
|
-
|
|
188
|
-
${MenuContainer} {
|
|
189
|
-
padding: 0;
|
|
190
|
-
}
|
|
188
|
+
--menu-container-padding-top: 0;
|
|
191
189
|
`;
|
|
@@ -9,7 +9,7 @@ import { Button } from '@redocly/theme/components/Button/Button';
|
|
|
9
9
|
import { FilterIcon } from '@redocly/theme/icons/FilterIcon/FilterIcon';
|
|
10
10
|
import { CounterTag } from '@redocly/theme/components/Tags/CounterTag';
|
|
11
11
|
|
|
12
|
-
type CatalogActionsProps = {
|
|
12
|
+
export type CatalogActionsProps = {
|
|
13
13
|
onOpenFilter: () => void;
|
|
14
14
|
filters: ResolvedFilter[];
|
|
15
15
|
filterTerm: string;
|
|
@@ -11,12 +11,13 @@ import { Tag } from '@redocly/theme/components/Tag/Tag';
|
|
|
11
11
|
import { CatalogHighlight } from '@redocly/theme/components/Catalog/CatalogHighlight';
|
|
12
12
|
import { Button } from '@redocly/theme/components/Button/Button';
|
|
13
13
|
|
|
14
|
-
type CatalogCardProps = {
|
|
14
|
+
export type CatalogCardProps = {
|
|
15
|
+
item: CatalogItem;
|
|
16
|
+
};
|
|
15
17
|
|
|
16
18
|
export function CatalogCard({ item }: CatalogCardProps): JSX.Element {
|
|
17
19
|
const { useTelemetry } = useThemeHooks();
|
|
18
20
|
const telemetry = useTelemetry();
|
|
19
|
-
const hasTags = item.scorecardLevel || item.tags?.length;
|
|
20
21
|
return (
|
|
21
22
|
<Link key={item.docsLink || item.link} to={item.docsLink || item.link}>
|
|
22
23
|
<StyledCard
|
|
@@ -34,28 +35,26 @@ export function CatalogCard({ item }: CatalogCardProps): JSX.Element {
|
|
|
34
35
|
</CardDescription>
|
|
35
36
|
</CardContent>
|
|
36
37
|
<CardFooter>
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
{
|
|
40
|
-
<
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
>
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
</CardTags>
|
|
58
|
-
)}
|
|
38
|
+
<CardTags>
|
|
39
|
+
{((item.tags as string[]) || []).map((tag, index) => (
|
|
40
|
+
<CardTag key={tag + index} color={slug(tag)}>
|
|
41
|
+
<CatalogHighlight>{capitalize(tag)}</CatalogHighlight>
|
|
42
|
+
</CardTag>
|
|
43
|
+
))}
|
|
44
|
+
{(item.scorecardLevel && (
|
|
45
|
+
<Tag
|
|
46
|
+
borderless
|
|
47
|
+
withStatusDot
|
|
48
|
+
statusDotColor={`var(${getScorecardColorVariable(
|
|
49
|
+
item.scorecardLevelIdx || 0,
|
|
50
|
+
Object.keys(item.scorecardLevels || {}).length,
|
|
51
|
+
)})`}
|
|
52
|
+
>
|
|
53
|
+
<CatalogHighlight>{item.scorecardLevel}</CatalogHighlight>
|
|
54
|
+
</Tag>
|
|
55
|
+
)) ||
|
|
56
|
+
null}
|
|
57
|
+
</CardTags>
|
|
59
58
|
<SelectButton size="medium" variant="secondary" icon={<ArrowRightIcon />} />
|
|
60
59
|
</CardFooter>
|
|
61
60
|
</StyledCard>
|
|
@@ -4,7 +4,7 @@ import styled from 'styled-components';
|
|
|
4
4
|
|
|
5
5
|
export const HighlightContext = React.createContext<string[]>([]);
|
|
6
6
|
|
|
7
|
-
type CatalogHighlightProps = React.PropsWithChildren;
|
|
7
|
+
export type CatalogHighlightProps = React.PropsWithChildren;
|
|
8
8
|
|
|
9
9
|
export function CatalogHighlight(props: CatalogHighlightProps): JSX.Element | null {
|
|
10
10
|
const { children } = props;
|
|
@@ -6,7 +6,7 @@ import { getScorecardColorVariable } from '@redocly/theme/core/utils';
|
|
|
6
6
|
import { Tag } from '@redocly/theme/components/Tag/Tag';
|
|
7
7
|
import { Link } from '@redocly/theme/components/Link/Link';
|
|
8
8
|
|
|
9
|
-
type CatalogInfoBlockProps = {
|
|
9
|
+
export type CatalogInfoBlockProps = {
|
|
10
10
|
metadata?: {
|
|
11
11
|
scorecardLevel?: string;
|
|
12
12
|
scoreCardSlug?: string;
|
|
@@ -69,7 +69,7 @@ export function CodeBlock({
|
|
|
69
69
|
(source || externalSource?.sample?.get?.(externalSource)) ?? '',
|
|
70
70
|
);
|
|
71
71
|
|
|
72
|
-
const highlightedCode = highlightedHtml || children ? null : highlight(sourceCode, lang);
|
|
72
|
+
const highlightedCode = highlightedHtml || (children ? null : highlight(sourceCode, lang));
|
|
73
73
|
|
|
74
74
|
// The same initial value should be returned for ssr and frontend to avoid issues
|
|
75
75
|
// Because we don't have session storage in ssr and can't get the security details there
|