@redocly/theme 0.18.3-patch.0 → 0.18.3
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/I18n/LanguagePicker.d.ts +2 -7
- package/lib/I18n/LanguagePicker.js +3 -11
- package/lib/I18n/index.d.ts +0 -1
- package/lib/I18n/index.js +0 -15
- package/lib/components/Breadcrumbs/Breadcrumb.d.ts +1 -0
- package/lib/components/Breadcrumbs/Breadcrumb.js +3 -4
- package/lib/components/Breadcrumbs/Breadcrumbs.js +9 -2
- package/lib/components/Breadcrumbs/index.d.ts +0 -1
- package/lib/components/Breadcrumbs/index.js +0 -1
- package/lib/components/Button/Button.d.ts +3 -6
- package/lib/components/Button/Button.js +42 -40
- package/lib/components/Button/index.d.ts +0 -1
- package/lib/components/Button/index.js +0 -1
- package/lib/components/Catalog/Catalog.d.ts +0 -1
- package/lib/components/Catalog/Catalog.js +96 -99
- package/lib/components/Catalog/CatalogCard.js +58 -62
- package/lib/components/Catalog/index.d.ts +3 -4
- package/lib/components/Catalog/index.js +3 -4
- package/lib/components/Catalog/useCatalog.js +12 -1
- package/lib/components/CodeBlock/CodeBlockContainer.js +8 -35
- package/lib/components/CodeBlock/CodeBlockControlButton.d.ts +4 -3
- package/lib/components/CodeBlock/CodeBlockControlButton.js +19 -5
- package/lib/components/CodeBlock/CodeBlockControls.js +11 -10
- package/lib/components/CodeBlock/index.d.ts +0 -1
- package/lib/components/CodeBlock/index.js +0 -1
- package/lib/components/ColorModeSwitcher/ColorModeSwitcher.js +3 -0
- package/lib/components/Dropdown/Dropdown.d.ts +2 -7
- package/lib/components/Dropdown/Dropdown.js +4 -6
- package/lib/components/Dropdown/index.d.ts +0 -1
- package/lib/components/Dropdown/index.js +0 -1
- package/lib/components/EditPageButton/EditPageButton.js +2 -1
- package/lib/components/Feedback/Feedback.js +13 -3
- package/lib/components/Feedback/Reasons.js +1 -1
- package/lib/components/Feedback/Sentiment.js +6 -2
- package/lib/components/Feedback/Thumbs.js +4 -4
- package/lib/components/Filter/Filter.js +78 -101
- package/lib/components/Filter/index.d.ts +0 -2
- package/lib/components/Filter/index.js +0 -2
- package/lib/components/Footer/CustomFooterNavItem.js +1 -1
- package/lib/components/Footer/Footer.d.ts +3 -4
- package/lib/components/Footer/Footer.js +10 -27
- package/lib/components/Footer/FooterColumn.d.ts +3 -3
- package/lib/components/Footer/FooterColumn.js +64 -53
- package/lib/components/Footer/FooterColumns.js +4 -6
- package/lib/components/Footer/FooterCopyright.js +6 -11
- package/lib/components/Footer/index.d.ts +0 -1
- package/lib/components/Footer/index.js +0 -1
- package/lib/components/JsonViewer/JsonViewer.js +2 -2
- package/lib/components/Markdown/MarkdownWrapper.js +4 -2
- package/lib/components/Markdown/Mermaid.js +1 -1
- package/lib/components/Markdown/index.d.ts +0 -1
- package/lib/components/Markdown/index.js +0 -1
- package/lib/components/Menu/Menu.js +7 -5
- package/lib/components/Menu/MenuGroup.js +7 -12
- package/lib/components/Menu/MenuItemLabel.js +13 -7
- package/lib/components/Menu/MenuLinkItem.js +2 -1
- package/lib/components/Menu/MobileMenu.js +25 -20
- package/lib/components/Menu/MobileMenuGroup.js +1 -1
- package/lib/components/Menu/index.d.ts +0 -1
- package/lib/components/Menu/index.js +0 -1
- package/lib/components/{Profile → Navbar}/MobileUserProfile.js +28 -5
- package/lib/components/Navbar/Navbar.js +11 -10
- package/lib/components/Navbar/NavbarItem.d.ts +1 -1
- package/lib/components/Navbar/NavbarItem.js +6 -7
- package/lib/components/Navbar/NavbarMenu.js +2 -2
- package/lib/components/Navbar/index.d.ts +0 -1
- package/lib/components/Navbar/index.js +0 -1
- package/lib/components/NavbarLogo/NavbarLogo.d.ts +1 -4
- package/lib/components/NavbarLogo/NavbarLogo.js +6 -13
- package/lib/components/OpenApiDocs/DevOnboardingTryItSecurity.js +2 -2
- package/lib/components/OpenApiDocs/Dropdown.js +3 -3
- package/lib/components/OperationBadge/OperationBadge.d.ts +6 -0
- package/lib/components/OperationBadge/OperationBadge.js +68 -0
- package/lib/components/OperationBadge/index.d.ts +1 -0
- package/lib/{icons/ErrorIcon → components/OperationBadge}/index.js +1 -1
- package/lib/components/Panel/PanelHeader.js +0 -1
- package/lib/components/Panel/PanelHeaderTitle.js +4 -0
- package/lib/components/Panel/index.d.ts +0 -1
- package/lib/components/Panel/index.js +0 -1
- package/lib/components/Product/index.d.ts +0 -1
- package/lib/components/Product/index.js +0 -1
- package/lib/components/Profile/LoginLink.js +6 -2
- package/lib/components/Profile/Profile.js +22 -3
- package/lib/components/Profile/UserProfile.js +13 -21
- package/lib/components/Profile/index.d.ts +0 -1
- package/lib/components/Profile/index.js +0 -15
- package/lib/components/Search/CancelSearch.js +14 -2
- package/lib/components/Search/ProductTag.js +7 -7
- package/lib/components/Search/RecentSearches.js +5 -5
- package/lib/components/Search/Search.js +2 -0
- package/lib/components/Search/SearchIcon.js +2 -2
- package/lib/components/Search/SearchItem.js +4 -4
- package/lib/components/Search/SearchTrigger.js +5 -4
- package/lib/components/Search/ShortcutKey.js +5 -1
- package/lib/components/Search/SuggestedPages.js +3 -3
- package/lib/components/Search/index.d.ts +0 -1
- package/lib/components/Search/index.js +0 -1
- package/lib/components/Select/Select.d.ts +3 -10
- package/lib/components/Select/Select.js +6 -9
- package/lib/components/Select/index.d.ts +0 -1
- package/lib/components/Select/index.js +0 -1
- package/lib/components/Separator/SeparatorItem.js +5 -7
- package/lib/components/Sidebar/ApiCallItem.d.ts +6 -2
- package/lib/components/Sidebar/ApiCallItem.js +11 -13
- package/lib/components/Sidebar/FooterWrapper.js +4 -3
- package/lib/components/Sidebar/HeaderWrapper.js +2 -2
- package/lib/components/Sidebar/SidebarLayout.js +2 -1
- package/lib/components/Sidebar/VersionPicker.d.ts +1 -1
- package/lib/components/Sidebar/index.d.ts +0 -1
- package/lib/components/Sidebar/index.js +0 -1
- package/lib/components/SidebarActions/CollapseSidebarButton.js +1 -37
- package/lib/components/SidebarActions/SidebarActions.js +15 -3
- package/lib/components/SidebarActions/styled.js +14 -16
- package/lib/components/TableOfContent/TableOfContent.js +5 -3
- package/lib/components/TableOfContent/index.d.ts +0 -1
- package/lib/components/TableOfContent/index.js +0 -1
- package/lib/components/Tabs/Tab.js +1 -1
- package/lib/components/Tabs/Tabs.js +1 -1
- package/lib/components/Tags/Tags.d.ts +5 -0
- package/lib/components/Tags/Tags.js +32 -0
- package/lib/components/Tags/index.d.ts +1 -0
- package/lib/components/{Image → Tags}/index.js +1 -1
- package/lib/components/Tiles/TileText.js +1 -1
- package/lib/components/Tooltip/index.d.ts +0 -1
- package/lib/components/Tooltip/index.js +0 -1
- package/lib/components/Typography/Typography.js +1 -1
- package/lib/components/index.d.ts +2 -1
- package/lib/components/index.js +2 -1
- package/lib/config.d.ts +0 -6
- package/lib/config.js +0 -1
- package/lib/globalStyle.js +1967 -597
- package/lib/icons/ArrowIcon/ArrowIcon.js +1 -1
- package/lib/icons/CollapseIcon/CollapseIcon.d.ts +1 -1
- package/lib/icons/CollapseIcon/CollapseIcon.js +5 -5
- package/lib/icons/ColorModeIcon/ColorModeIcon.js +1 -1
- package/lib/icons/CopyIcon/CopyIcon.d.ts +2 -1
- package/lib/icons/CopyIcon/CopyIcon.js +4 -4
- package/lib/icons/DeselectIcon/DeselectIcon.d.ts +1 -1
- package/lib/icons/DeselectIcon/DeselectIcon.js +5 -5
- package/lib/icons/ExpandIcon/ExpandIcon.d.ts +2 -1
- package/lib/icons/ExpandIcon/ExpandIcon.js +5 -5
- package/lib/icons/FileIcon/FileIcon.d.ts +2 -1
- package/lib/icons/FileIcon/FileIcon.js +2 -2
- package/lib/icons/ReportIcon/ReportIcon.d.ts +2 -1
- package/lib/icons/ReportIcon/ReportIcon.js +3 -3
- package/lib/icons/SelectIcon/SelectIcon.d.ts +2 -1
- package/lib/icons/SelectIcon/SelectIcon.js +5 -5
- package/lib/icons/index.d.ts +0 -4
- package/lib/icons/index.js +0 -4
- package/lib/layouts/Forbidden.js +0 -4
- package/lib/layouts/NotFound.js +0 -4
- package/lib/types/portal/src/shared/types/nav.d.ts +0 -5
- package/lib/ui/Burger.js +1 -1
- package/lib/ui/Dropdown.js +7 -7
- package/lib/ui/Jumbotron.js +1 -1
- package/lib/ui/darkColors.js +84 -216
- package/package.json +2 -2
- package/src/I18n/LanguagePicker.tsx +4 -29
- package/src/I18n/index.ts +0 -1
- package/src/components/Breadcrumbs/Breadcrumb.tsx +9 -4
- package/src/components/Breadcrumbs/Breadcrumbs.tsx +14 -2
- package/src/components/Breadcrumbs/index.ts +0 -1
- package/src/components/Button/Button.tsx +48 -52
- package/src/components/Button/index.ts +0 -1
- package/src/components/Catalog/Catalog.tsx +115 -127
- package/src/components/Catalog/CatalogCard.tsx +61 -75
- package/src/components/Catalog/index.tsx +3 -0
- package/src/components/Catalog/useCatalog.ts +13 -1
- package/src/components/CodeBlock/CodeBlockContainer.tsx +7 -14
- package/src/components/CodeBlock/CodeBlockControlButton.tsx +19 -6
- package/src/components/CodeBlock/CodeBlockControls.tsx +11 -9
- package/src/components/CodeBlock/index.ts +0 -1
- package/src/components/ColorModeSwitcher/ColorModeSwitcher.tsx +4 -0
- package/src/components/Dropdown/Dropdown.tsx +4 -10
- package/src/components/Dropdown/index.ts +0 -1
- package/src/components/EditPageButton/EditPageButton.tsx +2 -1
- package/src/components/Feedback/Feedback.tsx +13 -3
- package/src/components/Feedback/Reasons.tsx +1 -1
- package/src/components/Feedback/Sentiment.tsx +10 -2
- package/src/components/Feedback/Thumbs.tsx +4 -4
- package/src/components/Filter/Filter.tsx +94 -127
- package/src/components/Filter/index.ts +0 -2
- package/src/components/Footer/CustomFooterNavItem.tsx +1 -1
- package/src/components/Footer/Footer.tsx +10 -32
- package/src/components/Footer/FooterColumn.tsx +64 -79
- package/src/components/Footer/FooterColumns.tsx +4 -6
- package/src/components/Footer/FooterCopyright.tsx +7 -13
- package/src/components/Footer/index.ts +0 -1
- package/src/components/JsonViewer/JsonViewer.tsx +2 -2
- package/src/components/Markdown/MarkdownWrapper.tsx +4 -2
- package/src/components/Markdown/Mermaid.tsx +1 -1
- package/src/components/Markdown/index.ts +0 -1
- package/src/components/Menu/Menu.tsx +7 -5
- package/src/components/Menu/MenuGroup.tsx +7 -15
- package/src/components/Menu/MenuItemLabel.tsx +13 -7
- package/src/components/Menu/MenuLinkItem.tsx +6 -1
- package/src/components/Menu/MobileMenu.tsx +25 -20
- package/src/components/Menu/MobileMenuGroup.tsx +1 -1
- package/src/components/Menu/index.ts +0 -1
- package/src/components/{Profile → Navbar}/MobileUserProfile.tsx +39 -5
- package/src/components/Navbar/Navbar.tsx +11 -10
- package/src/components/Navbar/NavbarItem.tsx +6 -6
- package/src/components/Navbar/NavbarMenu.tsx +2 -2
- package/src/components/Navbar/index.ts +0 -1
- package/src/components/NavbarLogo/NavbarLogo.tsx +12 -14
- package/src/components/OpenApiDocs/DevOnboardingTryItSecurity.tsx +2 -1
- package/src/components/OpenApiDocs/Dropdown.tsx +3 -3
- package/src/components/OperationBadge/OperationBadge.ts +62 -0
- package/src/components/OperationBadge/index.ts +1 -0
- package/src/components/Panel/PanelHeader.ts +0 -1
- package/src/components/Panel/PanelHeaderTitle.ts +4 -0
- package/src/components/Panel/index.ts +0 -1
- package/src/components/Product/index.ts +0 -1
- package/src/components/Profile/LoginLink.tsx +10 -2
- package/src/components/Profile/Profile.tsx +24 -1
- package/src/components/Profile/UserProfile.tsx +13 -21
- package/src/components/Profile/index.ts +0 -1
- package/src/components/Search/CancelSearch.tsx +15 -2
- package/src/components/Search/ProductTag.tsx +7 -7
- package/src/components/Search/RecentSearches.tsx +5 -5
- package/src/components/Search/Search.tsx +2 -0
- package/src/components/Search/SearchIcon.tsx +5 -10
- package/src/components/Search/SearchItem.tsx +4 -4
- package/src/components/Search/SearchTrigger.tsx +5 -4
- package/src/components/Search/ShortcutKey.tsx +5 -1
- package/src/components/Search/SuggestedPages.tsx +3 -3
- package/src/components/Search/index.ts +0 -1
- package/src/components/Select/Select.tsx +7 -20
- package/src/components/Select/index.ts +0 -1
- package/src/components/Separator/SeparatorItem.tsx +5 -7
- package/src/components/Sidebar/ApiCallItem.tsx +11 -13
- package/src/components/Sidebar/FooterWrapper.tsx +4 -3
- package/src/components/Sidebar/HeaderWrapper.tsx +2 -2
- package/src/components/Sidebar/SidebarLayout.tsx +6 -1
- package/src/components/Sidebar/index.ts +0 -1
- package/src/components/SidebarActions/CollapseSidebarButton.tsx +2 -18
- package/src/components/SidebarActions/SidebarActions.tsx +18 -3
- package/src/components/SidebarActions/styled.tsx +23 -16
- package/src/components/TableOfContent/TableOfContent.tsx +5 -2
- package/src/components/TableOfContent/index.ts +0 -1
- package/src/components/Tabs/Tab.tsx +1 -1
- package/src/components/Tabs/Tabs.tsx +1 -1
- package/src/components/Tags/Tags.tsx +36 -0
- package/src/components/Tags/index.ts +1 -0
- package/src/components/Tiles/TileText.tsx +1 -1
- package/src/components/Tooltip/index.ts +0 -1
- package/src/components/Typography/Typography.ts +1 -1
- package/src/components/index.ts +2 -1
- package/src/config.ts +0 -1
- package/src/globalStyle.ts +1976 -588
- package/src/icons/ArrowIcon/ArrowIcon.tsx +1 -1
- package/src/icons/CollapseIcon/CollapseIcon.tsx +5 -5
- package/src/icons/ColorModeIcon/ColorModeIcon.tsx +1 -1
- package/src/icons/CopyIcon/CopyIcon.tsx +5 -4
- package/src/icons/DeselectIcon/DeselectIcon.tsx +5 -5
- package/src/icons/ExpandIcon/ExpandIcon.tsx +6 -5
- package/src/icons/FileIcon/FileIcon.tsx +3 -2
- package/src/icons/ReportIcon/ReportIcon.tsx +4 -3
- package/src/icons/SelectIcon/SelectIcon.tsx +6 -5
- package/src/icons/index.ts +0 -4
- package/src/layouts/Forbidden.tsx +0 -4
- package/src/layouts/NotFound.tsx +0 -4
- package/src/types/portal/src/shared/types/nav.ts +0 -5
- package/src/ui/Burger.tsx +1 -1
- package/src/ui/Dropdown.tsx +7 -7
- package/src/ui/Jumbotron.tsx +1 -1
- package/src/ui/darkColors.tsx +84 -216
- package/lib/I18n/styledVariables.d.ts +0 -1
- package/lib/I18n/styledVariables.js +0 -39
- package/lib/components/Breadcrumbs/styledVariables.d.ts +0 -1
- package/lib/components/Breadcrumbs/styledVariables.js +0 -19
- package/lib/components/Button/styledVariables.d.ts +0 -1
- package/lib/components/Button/styledVariables.js +0 -94
- package/lib/components/Catalog/styledVariables.d.ts +0 -1
- package/lib/components/Catalog/styledVariables.js +0 -94
- package/lib/components/CodeBlock/styledVariables.d.ts +0 -1
- package/lib/components/CodeBlock/styledVariables.js +0 -90
- package/lib/components/Dropdown/styledVariables.d.ts +0 -1
- package/lib/components/Dropdown/styledVariables.js +0 -30
- package/lib/components/Filter/FilterContent.d.ts +0 -11
- package/lib/components/Filter/FilterContent.js +0 -50
- package/lib/components/Filter/FilterPopover.d.ts +0 -11
- package/lib/components/Filter/FilterPopover.js +0 -99
- package/lib/components/Filter/FilterTag.d.ts +0 -7
- package/lib/components/Filter/FilterTag.js +0 -33
- package/lib/components/Filter/FilterTags.d.ts +0 -7
- package/lib/components/Filter/FilterTags.js +0 -29
- package/lib/components/Filter/styledVariables.d.ts +0 -1
- package/lib/components/Filter/styledVariables.js +0 -112
- package/lib/components/Footer/styledVariables.d.ts +0 -1
- package/lib/components/Footer/styledVariables.js +0 -61
- package/lib/components/Image/Image.d.ts +0 -9
- package/lib/components/Image/Image.js +0 -31
- package/lib/components/Image/index.d.ts +0 -1
- package/lib/components/Markdown/styledVariables.d.ts +0 -2
- package/lib/components/Markdown/styledVariables.js +0 -221
- package/lib/components/Menu/styledVariables.d.ts +0 -2
- package/lib/components/Menu/styledVariables.js +0 -90
- package/lib/components/Navbar/styledVariables.d.ts +0 -1
- package/lib/components/Navbar/styledVariables.js +0 -40
- package/lib/components/Panel/styledVariables.d.ts +0 -2
- package/lib/components/Panel/styledVariables.js +0 -489
- package/lib/components/Product/styledVariables.d.ts +0 -2
- package/lib/components/Product/styledVariables.js +0 -41
- package/lib/components/Profile/UserProfileData.d.ts +0 -9
- package/lib/components/Profile/UserProfileData.js +0 -35
- package/lib/components/Profile/styledVariables.d.ts +0 -2
- package/lib/components/Profile/styledVariables.js +0 -55
- package/lib/components/Search/styledVariables.d.ts +0 -1
- package/lib/components/Search/styledVariables.js +0 -98
- package/lib/components/Select/styledVariables.d.ts +0 -1
- package/lib/components/Select/styledVariables.js +0 -33
- package/lib/components/Sidebar/styledVariables.d.ts +0 -2
- package/lib/components/Sidebar/styledVariables.js +0 -210
- package/lib/components/TableOfContent/styledVariables.d.ts +0 -1
- package/lib/components/TableOfContent/styledVariables.js +0 -46
- package/lib/components/Tag/Tag.d.ts +0 -16
- package/lib/components/Tag/Tag.js +0 -39
- package/lib/components/Tag/index.d.ts +0 -2
- package/lib/components/Tag/index.js +0 -19
- package/lib/components/Tag/styledVariables.d.ts +0 -1
- package/lib/components/Tag/styledVariables.js +0 -130
- package/lib/components/Tooltip/styledVariables.d.ts +0 -1
- package/lib/components/Tooltip/styledVariables.js +0 -21
- package/lib/icons/CheckboxIcon/CheckboxIcon.d.ts +0 -6
- package/lib/icons/CheckboxIcon/CheckboxIcon.js +0 -28
- package/lib/icons/CheckboxIcon/index.d.ts +0 -1
- package/lib/icons/CheckboxIcon/index.js +0 -6
- package/lib/icons/ErrorIcon/ErrorIcon.d.ts +0 -4
- package/lib/icons/ErrorIcon/ErrorIcon.js +0 -14
- package/lib/icons/ErrorIcon/index.d.ts +0 -1
- package/lib/icons/LanguageIcon/LanguageIcon.d.ts +0 -4
- package/lib/icons/LanguageIcon/LanguageIcon.js +0 -14
- package/lib/icons/LanguageIcon/index.d.ts +0 -1
- package/lib/icons/LanguageIcon/index.js +0 -18
- package/lib/icons/PlusIcon/PlusIcon.d.ts +0 -5
- package/lib/icons/PlusIcon/PlusIcon.js +0 -16
- package/lib/icons/PlusIcon/index.d.ts +0 -1
- package/lib/icons/PlusIcon/index.js +0 -18
- package/lib/icons/PointingArrowIcon/PointingArrowIcon.d.ts +0 -4
- package/lib/icons/PointingArrowIcon/PointingArrowIcon.js +0 -15
- package/lib/icons/PointingArrowIcon/index.d.ts +0 -1
- package/lib/icons/PointingArrowIcon/index.js +0 -18
- package/src/I18n/styledVariables.ts +0 -36
- package/src/components/Breadcrumbs/styledVariables.ts +0 -16
- package/src/components/Button/styledVariables.ts +0 -91
- package/src/components/Catalog/index.ts +0 -4
- package/src/components/Catalog/styledVariables.ts +0 -91
- package/src/components/CodeBlock/styledVariables.ts +0 -87
- package/src/components/Dropdown/styledVariables.ts +0 -27
- package/src/components/Filter/FilterContent.tsx +0 -75
- package/src/components/Filter/FilterPopover.tsx +0 -132
- package/src/components/Filter/FilterTag.tsx +0 -37
- package/src/components/Filter/FilterTags.tsx +0 -39
- package/src/components/Filter/styledVariables.ts +0 -109
- package/src/components/Footer/styledVariables.ts +0 -58
- package/src/components/Image/Image.tsx +0 -47
- package/src/components/Image/index.ts +0 -1
- package/src/components/Markdown/styledVariables.ts +0 -219
- package/src/components/Menu/styledVariables.ts +0 -88
- package/src/components/Navbar/styledVariables.ts +0 -37
- package/src/components/Panel/styledVariables.ts +0 -487
- package/src/components/Product/styledVariables.ts +0 -39
- package/src/components/Profile/UserProfileData.tsx +0 -40
- package/src/components/Profile/styledVariables.ts +0 -53
- package/src/components/Search/styledVariables.ts +0 -95
- package/src/components/Select/styledVariables.ts +0 -30
- package/src/components/Sidebar/styledVariables.ts +0 -208
- package/src/components/TableOfContent/styledVariables.ts +0 -43
- package/src/components/Tag/Tag.tsx +0 -62
- package/src/components/Tag/index.ts +0 -2
- package/src/components/Tag/styledVariables.ts +0 -127
- package/src/components/Tooltip/styledVariables.ts +0 -18
- package/src/icons/CheckboxIcon/CheckboxIcon.tsx +0 -64
- package/src/icons/CheckboxIcon/index.ts +0 -1
- package/src/icons/ErrorIcon/ErrorIcon.tsx +0 -15
- package/src/icons/ErrorIcon/index.ts +0 -1
- package/src/icons/LanguageIcon/LanguageIcon.tsx +0 -15
- package/src/icons/LanguageIcon/index.ts +0 -1
- package/src/icons/PlusIcon/PlusIcon.tsx +0 -19
- package/src/icons/PlusIcon/index.ts +0 -1
- package/src/icons/PointingArrowIcon/PointingArrowIcon.tsx +0 -16
- package/src/icons/PointingArrowIcon/index.ts +0 -1
- /package/lib/components/{Profile → Navbar}/MobileUserProfile.d.ts +0 -0
package/lib/ui/darkColors.js
CHANGED
|
@@ -3,222 +3,90 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.darkMode = void 0;
|
|
4
4
|
const styled_components_1 = require("styled-components");
|
|
5
5
|
exports.darkMode = (0, styled_components_1.css) `
|
|
6
|
-
/* === Dark Theme Colors === */
|
|
7
|
-
|
|
8
6
|
/**
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
--
|
|
14
|
-
--
|
|
15
|
-
--
|
|
16
|
-
--
|
|
17
|
-
--
|
|
18
|
-
--
|
|
19
|
-
--
|
|
20
|
-
--
|
|
21
|
-
--
|
|
22
|
-
--
|
|
23
|
-
|
|
24
|
-
--color-
|
|
25
|
-
--color-
|
|
26
|
-
--
|
|
27
|
-
--
|
|
28
|
-
--color-
|
|
29
|
-
--
|
|
30
|
-
--
|
|
31
|
-
--
|
|
32
|
-
--
|
|
33
|
-
--
|
|
34
|
-
|
|
35
|
-
--
|
|
36
|
-
--
|
|
37
|
-
--
|
|
38
|
-
--
|
|
39
|
-
--
|
|
40
|
-
--
|
|
41
|
-
--
|
|
42
|
-
--
|
|
43
|
-
--
|
|
44
|
-
--
|
|
45
|
-
|
|
46
|
-
--
|
|
47
|
-
--
|
|
48
|
-
--
|
|
49
|
-
--
|
|
50
|
-
--
|
|
51
|
-
--
|
|
52
|
-
--
|
|
53
|
-
--
|
|
54
|
-
--
|
|
55
|
-
--
|
|
56
|
-
|
|
57
|
-
--
|
|
58
|
-
--
|
|
59
|
-
--
|
|
60
|
-
--
|
|
61
|
-
--
|
|
62
|
-
--
|
|
63
|
-
--
|
|
64
|
-
--
|
|
65
|
-
--
|
|
66
|
-
--
|
|
67
|
-
|
|
68
|
-
--
|
|
69
|
-
--
|
|
70
|
-
--
|
|
71
|
-
--color-
|
|
72
|
-
--color-
|
|
73
|
-
--color-
|
|
74
|
-
--color-
|
|
75
|
-
--
|
|
76
|
-
--
|
|
77
|
-
--
|
|
78
|
-
|
|
79
|
-
--
|
|
80
|
-
--
|
|
81
|
-
--
|
|
82
|
-
--
|
|
83
|
-
--
|
|
84
|
-
--
|
|
85
|
-
--
|
|
86
|
-
--
|
|
87
|
-
--
|
|
88
|
-
--
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
--color-yellow-4: #7c6e14;
|
|
94
|
-
--color-yellow-5: #aa9514;
|
|
95
|
-
--color-yellow-6: #d8bd14;
|
|
96
|
-
--color-yellow-7: #e8d639;
|
|
97
|
-
--color-yellow-8: #f3ea62;
|
|
98
|
-
--color-yellow-9: #f8f48b;
|
|
99
|
-
--color-yellow-10: #fafab5;
|
|
100
|
-
|
|
101
|
-
--color-lime-1: #1f2611;
|
|
102
|
-
--color-lime-2: #2e3c10;
|
|
103
|
-
--color-lime-3: #3e4f13;
|
|
104
|
-
--color-lime-4: #536d13;
|
|
105
|
-
--color-lime-5: #6f9412;
|
|
106
|
-
--color-lime-6: #8bbb11;
|
|
107
|
-
--color-lime-7: #a9d134;
|
|
108
|
-
--color-lime-8: #c9e75d;
|
|
109
|
-
--color-lime-9: #e4f88b;
|
|
110
|
-
--color-lime-10: #f0fab5;
|
|
111
|
-
|
|
112
|
-
--color-geekblue-1: #131629;
|
|
113
|
-
--color-geekblue-2: #161d40;
|
|
114
|
-
--color-geekblue-3: #1c2755;
|
|
115
|
-
--color-geekblue-4: #203175;
|
|
116
|
-
--color-geekblue-5: #263ea0;
|
|
117
|
-
--color-geekblue-6: #2b4acb;
|
|
118
|
-
--color-geekblue-7: #5273e0;
|
|
119
|
-
--color-geekblue-8: #7f9ef3;
|
|
120
|
-
--color-geekblue-9: #a8c1f8;
|
|
121
|
-
--color-geekblue-10: #d2e0fa;
|
|
122
|
-
|
|
123
|
-
--color-primary-bg: #0d086e;
|
|
124
|
-
--color-primary-bg-hover: #161087;
|
|
125
|
-
--color-primary-border: #201dad;
|
|
126
|
-
--color-primary-border-hover: #2f31d4;
|
|
127
|
-
--color-primary-hover: #6678ff;
|
|
128
|
-
--color-primary-base: #434dfa;
|
|
129
|
-
--color-primary-active: #8a99ff;
|
|
130
|
-
--color-primary-text-hover: #adbcff;
|
|
131
|
-
--color-primary-text: #d6dfff;
|
|
132
|
-
--color-primary-text-active: #ebf0ff;
|
|
133
|
-
|
|
134
|
-
--color-success-bg: var(--color-green-1);
|
|
135
|
-
--color-success-bg-hover: var(--color-green-2);
|
|
136
|
-
--color-success-border: var(--color-green-3);
|
|
137
|
-
--color-success-border-hover: var(--color-green-4);
|
|
138
|
-
--color-success-hover: var(--color-green-7);
|
|
139
|
-
--color-success-base: var(--color-green-6);
|
|
140
|
-
--color-success-active: var(--color-green-5);
|
|
141
|
-
--color-success-text-hover: var(--color-green-8);
|
|
142
|
-
--color-success-text: var(--color-green-9);
|
|
143
|
-
--color-success-text-active: var(--color-green-10);
|
|
144
|
-
|
|
145
|
-
--color-warning-bg: var(--color-gold-1);
|
|
146
|
-
--color-warning-bg-hover: var(--color-gold-2);
|
|
147
|
-
--color-warning-border: var(--color-gold-3);
|
|
148
|
-
--color-warning-border-hover: var(--color-gold-4);
|
|
149
|
-
--color-warning-hover: var(--color-gold-7);
|
|
150
|
-
--color-warning-base: var(--color-gold-6);
|
|
151
|
-
--color-warning-active: var(--color-gold-5);
|
|
152
|
-
--color-warning-text-hover: var(--color-gold-8);
|
|
153
|
-
--color-warning-text: var(--color-gold-9);
|
|
154
|
-
--color-warning-text-active: var(--color-gold-10);
|
|
155
|
-
|
|
156
|
-
--color-error-bg: var(--color-red-1);
|
|
157
|
-
--color-error-bg-hover: var(--color-red-2);
|
|
158
|
-
--color-error-border: var(--color-red-3);
|
|
159
|
-
--color-error-border-hover: var(--color-red-4);
|
|
160
|
-
--color-error-hover: var(--color-red-7);
|
|
161
|
-
--color-error-base: var(--color-red-6);
|
|
162
|
-
--color-error-active: var(--color-red-5);
|
|
163
|
-
--color-error-text-hover: var(--color-red-8);
|
|
164
|
-
--color-error-text: var(--color-red-9);
|
|
165
|
-
--color-error-text-active: var(--color-red-10);
|
|
166
|
-
|
|
167
|
-
--color-info-bg: var(--color-blue-1);
|
|
168
|
-
--color-info-bg-hover: var(--color-blue-2);
|
|
169
|
-
--color-info-border: var(--color-blue-3);
|
|
170
|
-
--color-info-border-hover: var(--color-blue-4);
|
|
171
|
-
--color-info-hover: var(--color-blue-7);
|
|
172
|
-
--color-info-base: var(--color-blue-6);
|
|
173
|
-
--color-info-active: var(--color-blue-5);
|
|
174
|
-
--color-info-text-hover: var(--color-blue-8);
|
|
175
|
-
--color-info-text: var(--color-blue-9);
|
|
176
|
-
--color-info-text-active: var(--color-blue-10);
|
|
177
|
-
|
|
178
|
-
/**
|
|
179
|
-
* @tokens Dark Main Colors
|
|
180
|
-
* @presenter Color
|
|
181
|
-
*/
|
|
182
|
-
--color-bg-base: #ffffff;
|
|
183
|
-
--color-primary: var(--color-primary-base);
|
|
184
|
-
--color-error: var(--color-error-base);
|
|
185
|
-
--color-warning: var(--color-warning-base);
|
|
186
|
-
--color-success: var(--color-success-base);
|
|
187
|
-
--color-info: var(--color-info-base);
|
|
188
|
-
|
|
189
|
-
/**
|
|
190
|
-
* @tokens Font Colors
|
|
191
|
-
* @presenter Color
|
|
192
|
-
*/
|
|
193
|
-
--text-base: #ffffff; // The base color of the typography color tokens.
|
|
194
|
-
--text-light-solid: #ffffff; // The color of the objects that need to be white no matter what theme is enabled.
|
|
195
|
-
--text-primary: #e3e3e3; // Headers, Icon hover
|
|
196
|
-
--text-secondary: #b3b3b3; // Body text
|
|
197
|
-
--text-description: #8e8e8e; // Caption, Description, Icon
|
|
198
|
-
--text-placeholder: #7b7b7b; // Placeholder text, Disabled text
|
|
199
|
-
--text-link: var(--color-blue-6);
|
|
200
|
-
|
|
201
|
-
/**
|
|
202
|
-
* @tokens Elevation Colors
|
|
203
|
-
* @presenter Color
|
|
204
|
-
*/
|
|
205
|
-
|
|
206
|
-
--bg-sunken: #0d0d0d; // Sunken is the lowest elevation available.
|
|
207
|
-
--bg-base: #141414; // The default elevation is the baseline with respect to all other layers.
|
|
208
|
-
--bg-raised: #1f1f1f; // Cards, elements, inputs
|
|
209
|
-
--bg-overlay: #282828; // Overlay is the highest elevation available. Use for hovers
|
|
210
|
-
|
|
211
|
-
--bg-base-shadow: 0px 3px 5px rgba(0, 0, 0, 0.4), 0px 1px 4px rgba(0, 0, 0, 0.5); // Elements
|
|
212
|
-
--bg-raised-shadow: 0px 8px 12px rgba(0, 0, 0, 0.4), 0px 1px 4px rgba(0, 0, 0, 0.5); // Hovers for base. Menu
|
|
213
|
-
--bg-overlay-shadow: 0px 16px 32px rgba(0, 0, 0, 0.6), 0px 6px 6px rgba(0, 0, 0, 0.4); // Use for dropdowns
|
|
214
|
-
|
|
215
|
-
/**
|
|
216
|
-
* @tokens Border Colors
|
|
217
|
-
* @presenter Color
|
|
218
|
-
*/
|
|
219
|
-
--border-primary: #424242; // Raised dividers
|
|
220
|
-
--border-secondary: #222222; // Default dividers, borders
|
|
221
|
-
|
|
222
|
-
// @tokens End
|
|
7
|
+
* @tokens Dark Colors
|
|
8
|
+
* @presenter Color
|
|
9
|
+
*/
|
|
10
|
+
--background-color: #141414;
|
|
11
|
+
--footer-background-color: #1f1f1f;
|
|
12
|
+
--navbar-background-color: #1f1f1f;
|
|
13
|
+
--mobile-menu-background: #141414;
|
|
14
|
+
--mobile-menu-profile-background: var(--mobile-menu-background);
|
|
15
|
+
--mobile-menu-login-button-background: var(--mobile-menu-profile-background);
|
|
16
|
+
--mobile-menu-item-text-color: rgba(255, 255, 255, 0.6);
|
|
17
|
+
--mobile-menu-item-active-color: #1f1f1f;
|
|
18
|
+
--mobile-menu-item-active-text-color: rgba(255, 255, 255, 0.85);
|
|
19
|
+
--mobile-menu-control-button-color: #ffffff;
|
|
20
|
+
--mobile-menu-profile-border-color: #222222;
|
|
21
|
+
--color-primary-500: #57a5fd;
|
|
22
|
+
--color-primary-300: #15396e;
|
|
23
|
+
--color-secondary-300: #22262e;
|
|
24
|
+
--colors-translucent: rgb(50 63 75 / 40%);
|
|
25
|
+
--inline-code-text-color: #f76663;
|
|
26
|
+
--color-emphasis-400: #fff;
|
|
27
|
+
--link-hover-text-color: #57a5fd;
|
|
28
|
+
--link-text-color: #57a5fd;
|
|
29
|
+
--code-block-background-color: #1e2633;
|
|
30
|
+
--admonition-attention-background-color: var(--color-primary-300);
|
|
31
|
+
--admonition-attention-icon-color: var(--color-emphasis-700);
|
|
32
|
+
--admonition-warning-background-color: #614b17;
|
|
33
|
+
--admonition-warning-icon-color: #4c3b12;
|
|
34
|
+
--admonition-success-background-color: #267e74;
|
|
35
|
+
--admonition-success-icon-color: #38b9a5;
|
|
36
|
+
--admonition-danger-background-color: #d6524c;
|
|
37
|
+
--admonition-danger-icon-color: #d13e37;
|
|
38
|
+
--admonition-info-background-color: #696969;
|
|
39
|
+
--admonition-info-icon-color: #505050;
|
|
40
|
+
--inline-code-background-color: #1e2633;
|
|
41
|
+
--toc-item-active-background-color: #1e2633;
|
|
42
|
+
--sidebar-item-active-background-color: #1e2633;
|
|
43
|
+
--panel-response-success-heading-background-color: #38b9a5;
|
|
44
|
+
--panel-response-success-border-color: #38b9a5;
|
|
45
|
+
--panel-response-error-heading-background-color: #d6524c;
|
|
46
|
+
--panel-response-error-border-color: #d6524c;
|
|
47
|
+
--panel-samples-heading-background-color: #1e2633;
|
|
48
|
+
--panel-samples-body-background-color: #263041;
|
|
49
|
+
--panel-samples-tabs-hover-background-color: #1e2633;
|
|
50
|
+
--panel-samples-tabs-hover-border-color: #3f4f68;
|
|
51
|
+
--panel-try-it-action-button-hover-border-color: #2b4cc4;
|
|
52
|
+
--panel-try-it-action-button-hover-background-color: #2b4cc4;
|
|
53
|
+
--panel-try-it-action-button-background-color: #0065fb;
|
|
54
|
+
--button-background-color: #0065fb;
|
|
55
|
+
--button-border-color: #0065fb;
|
|
56
|
+
--button-hover-background-color: #2b4cc4;
|
|
57
|
+
--button-hover-border-color: #2b4cc4;
|
|
58
|
+
--search-input-background-color: #1b2738;
|
|
59
|
+
--search-popover-background-color: #1b2738;
|
|
60
|
+
--search-highlight-text-color: #ffff03;
|
|
61
|
+
--search-item-text-color: #ffffffcf;
|
|
62
|
+
--search-item-title-text-color: #ffffff;
|
|
63
|
+
--search-item-active-text-color: var(--text-color);
|
|
64
|
+
--search-item-active-title-text-color: var(--text-color);
|
|
65
|
+
--search-item-active-background-color: #1b2738;
|
|
66
|
+
--panel-try-it-nested-body-background-color: #263041;
|
|
67
|
+
--panel-try-it-tabs-active-background-color: #11151d;
|
|
68
|
+
--panel-try-it-tabs-hover-background-color: #141a26;
|
|
69
|
+
--color-emphasis-100: #16202e;
|
|
70
|
+
--color-secondary-400: #696969;
|
|
71
|
+
--color-emphasis-700: #fff;
|
|
72
|
+
--color-emphasis-800: #fff;
|
|
73
|
+
--copy-button-tooltip-text-color: #fff;
|
|
74
|
+
--copy-button-tooltip-background-color: var(--tooltip-background-color);
|
|
75
|
+
--tooltip-text-color: #fff;
|
|
76
|
+
--md-table-head-background-color: var(--color-secondary-300);
|
|
77
|
+
--md-tabs-hover-tab-border-color: var(--color-secondary-500);
|
|
78
|
+
--thin-tile-background-color: #1d242d;
|
|
79
|
+
--wide-tile-background-color: #1d242d;
|
|
80
|
+
--page-404-header-text-color: #fff;
|
|
81
|
+
--page-404-description-text-color: #fff;
|
|
82
|
+
--page-403-header-text-color: #fff;
|
|
83
|
+
--page-403-description-text-color: #fff;
|
|
84
|
+
--checkbox-backround-color: var(--color-secondary-900);
|
|
85
|
+
--checkbox-checked-backround-color: var(--color-primary-400);
|
|
86
|
+
--select-list-item-active-background-color: #282828;
|
|
87
|
+
--dropdown-list-item-active-background-color: #282828;
|
|
88
|
+
|
|
89
|
+
background-color: var(--background-color);
|
|
90
|
+
color: var(--text-color);
|
|
223
91
|
`;
|
|
224
92
|
//# sourceMappingURL=darkColors.js.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@redocly/theme",
|
|
3
|
-
"version": "0.18.3
|
|
3
|
+
"version": "0.18.3",
|
|
4
4
|
"description": "Shared UI components lib",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"theme",
|
|
@@ -81,7 +81,7 @@
|
|
|
81
81
|
"tsconfig-paths-webpack-plugin": "^3.5.2",
|
|
82
82
|
"typescript": "^4.8.4",
|
|
83
83
|
"webpack": "^5.72.0",
|
|
84
|
-
"@redocly/portal-types": "1.0.
|
|
84
|
+
"@redocly/portal-types": "1.0.2"
|
|
85
85
|
},
|
|
86
86
|
"dependencies": {
|
|
87
87
|
"@redocly/ajv": "^8.11.0",
|
|
@@ -5,16 +5,8 @@ import { getPathnameForLocale, withPathPrefix } from '@portal/utils';
|
|
|
5
5
|
import { usePreloadHistory } from '@portal/usePreloadHistory';
|
|
6
6
|
import { useI18nConfig } from '@portal/hooks';
|
|
7
7
|
import { Select, SelectInput, SelectList, SelectListItem } from '@theme/components/Select';
|
|
8
|
-
import { LanguageIcon } from '@theme/icons';
|
|
9
8
|
|
|
10
|
-
|
|
11
|
-
onChangeLanguage: (newLang: string) => void;
|
|
12
|
-
onlyIcon?: boolean;
|
|
13
|
-
placement?: 'top' | 'bottom';
|
|
14
|
-
alignment?: 'start' | 'end';
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
export const LanguagePicker = (props: LanguagePickerProps) => {
|
|
9
|
+
export const LanguagePicker = (props: { onChangeLanguage: (newLang: string) => void }) => {
|
|
18
10
|
const { currentLocale, locales, defaultLocale } = useI18nConfig();
|
|
19
11
|
const history = usePreloadHistory();
|
|
20
12
|
|
|
@@ -45,17 +37,7 @@ export const LanguagePicker = (props: LanguagePickerProps) => {
|
|
|
45
37
|
</LanguageItem>
|
|
46
38
|
));
|
|
47
39
|
|
|
48
|
-
return
|
|
49
|
-
<LanguageSelect
|
|
50
|
-
selected={selected}
|
|
51
|
-
options={languageItems}
|
|
52
|
-
triggerEvent="hover"
|
|
53
|
-
placement={props.placement}
|
|
54
|
-
alignment={props.alignment}
|
|
55
|
-
icon={<LanguageIcon />}
|
|
56
|
-
onlyIcon={props.onlyIcon}
|
|
57
|
-
/>
|
|
58
|
-
);
|
|
40
|
+
return <LanguageSelect selected={selected} options={languageItems} triggerEvent="hover" />;
|
|
59
41
|
};
|
|
60
42
|
|
|
61
43
|
const LanguageSelect = styled(Select).attrs(() => ({
|
|
@@ -69,19 +51,12 @@ const LanguageSelect = styled(Select).attrs(() => ({
|
|
|
69
51
|
line-height: var(--language-picker-line-height);
|
|
70
52
|
border-radius: var(--language-picker-border-radius);
|
|
71
53
|
color: var(--language-picker-text-color);
|
|
72
|
-
background-color: var(--language-picker-background-color);
|
|
73
54
|
|
|
74
55
|
${SelectInput} {
|
|
75
|
-
|
|
76
|
-
color: var(--language-picker-text-color);
|
|
77
|
-
border: 1px solid var(--language-picker-border-color);
|
|
56
|
+
color: var(--navbar-text-color);
|
|
78
57
|
border-radius: var(--language-picker-input-border-radius);
|
|
79
58
|
padding: var(--language-picker-input-padding-vertical)
|
|
80
59
|
var(--language-picker-input-padding-horizontal);
|
|
81
|
-
|
|
82
|
-
:hover {
|
|
83
|
-
border-color: var(--language-picker-hover-border-color);
|
|
84
|
-
}
|
|
85
60
|
}
|
|
86
61
|
|
|
87
62
|
${SelectList} {
|
|
@@ -112,7 +87,7 @@ const LanguageSelect = styled(Select).attrs(() => ({
|
|
|
112
87
|
|
|
113
88
|
:hover {
|
|
114
89
|
text-decoration: var(--navbar-item-hover-text-decoration);
|
|
115
|
-
background: var(--
|
|
90
|
+
background: var(--navbar-item-hover-background-color);
|
|
116
91
|
}
|
|
117
92
|
`;
|
|
118
93
|
const LanguageItem = styled.div``;
|
package/src/I18n/index.ts
CHANGED
|
@@ -3,14 +3,20 @@ import styled from 'styled-components';
|
|
|
3
3
|
|
|
4
4
|
import { Link } from '@portal/Link';
|
|
5
5
|
|
|
6
|
-
export const Breadcrumb = (props: {
|
|
7
|
-
|
|
6
|
+
export const Breadcrumb = (props: {
|
|
7
|
+
label: string;
|
|
8
|
+
link?: string;
|
|
9
|
+
isActive: boolean;
|
|
10
|
+
onClick?: () => void;
|
|
11
|
+
}) => {
|
|
12
|
+
const { label, link, isActive, onClick } = props;
|
|
8
13
|
|
|
9
14
|
return (
|
|
10
15
|
<BreadcrumbWrapper
|
|
11
16
|
data-component-name="Breadcrumbs/Breadcrumb"
|
|
12
17
|
isLink={link != null}
|
|
13
18
|
isActive={isActive}
|
|
19
|
+
onClick={onClick}
|
|
14
20
|
>
|
|
15
21
|
{link ? (
|
|
16
22
|
<BreadcrumbLink to={link}>{label}</BreadcrumbLink>
|
|
@@ -49,9 +55,8 @@ const BreadcrumbWrapper = styled.div<{ isActive: boolean; isLink: boolean }>`
|
|
|
49
55
|
|
|
50
56
|
const BreadcrumbLink = styled(Link)`
|
|
51
57
|
text-decoration: none;
|
|
52
|
-
color: var(--breadcrumbs-text-color);
|
|
53
58
|
|
|
54
59
|
&:visited {
|
|
55
|
-
color:
|
|
60
|
+
color: inherit;
|
|
56
61
|
}
|
|
57
62
|
`;
|
|
@@ -2,6 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import styled from 'styled-components';
|
|
3
3
|
|
|
4
4
|
import { useBreadcrumbs } from '@portal/Sidebar/useBreadcrumbs';
|
|
5
|
+
import { telemetry } from '@portal/telemetry';
|
|
5
6
|
|
|
6
7
|
import { Breadcrumb } from './Breadcrumb';
|
|
7
8
|
|
|
@@ -18,7 +19,18 @@ export const Breadcrumbs = (props: { className?: string }) => {
|
|
|
18
19
|
const isLast = idx === breadcrumbs.length - 1;
|
|
19
20
|
return (
|
|
20
21
|
<React.Fragment key={idx}>
|
|
21
|
-
<Breadcrumb
|
|
22
|
+
<Breadcrumb
|
|
23
|
+
link={breadcrumb.link}
|
|
24
|
+
label={breadcrumb.label}
|
|
25
|
+
isActive={isLast}
|
|
26
|
+
onClick={() => {
|
|
27
|
+
telemetry.send('breadcrumb_clicked', {
|
|
28
|
+
link: breadcrumb.link,
|
|
29
|
+
position: idx + 1,
|
|
30
|
+
total_breadcrumbs: breadcrumbs.length,
|
|
31
|
+
});
|
|
32
|
+
}}
|
|
33
|
+
/>
|
|
22
34
|
{isLast ? null : <div>/</div>}
|
|
23
35
|
</React.Fragment>
|
|
24
36
|
);
|
|
@@ -36,7 +48,7 @@ const Container = styled.div`
|
|
|
36
48
|
flex-wrap: wrap;
|
|
37
49
|
|
|
38
50
|
> div {
|
|
39
|
-
padding: var(--breadcrumbs-padding);
|
|
51
|
+
padding-right: var(--breadcrumbs-padding-horizontal);
|
|
40
52
|
}
|
|
41
53
|
|
|
42
54
|
@media print {
|
|
@@ -5,12 +5,11 @@ import type { FlattenSimpleInterpolation, Keyframes } from 'styled-components';
|
|
|
5
5
|
|
|
6
6
|
import { Link } from '@portal/Link';
|
|
7
7
|
|
|
8
|
-
export type ButtonSize = '
|
|
9
|
-
export type ButtonColor = '
|
|
10
|
-
export type ButtonVariant = 'outlined' | 'contained'
|
|
8
|
+
export type ButtonSize = 'small' | 'medium' | 'large' | 'xlarge' | string;
|
|
9
|
+
export type ButtonColor = 'primary' | 'secondary' | 'default' | string;
|
|
10
|
+
export type ButtonVariant = 'outlined' | 'contained';
|
|
11
11
|
|
|
12
12
|
export interface ButtonProps {
|
|
13
|
-
children?: React.ReactNode;
|
|
14
13
|
color?: ButtonColor;
|
|
15
14
|
disabled?: boolean;
|
|
16
15
|
blinking?: boolean;
|
|
@@ -19,8 +18,6 @@ export interface ButtonProps {
|
|
|
19
18
|
size?: ButtonSize;
|
|
20
19
|
extraClass?: string;
|
|
21
20
|
to?: string;
|
|
22
|
-
icon?: JSX.Element;
|
|
23
|
-
title?: string;
|
|
24
21
|
onClick?: (e?: any) => void;
|
|
25
22
|
}
|
|
26
23
|
|
|
@@ -40,57 +37,47 @@ const getBlink = (): Keyframes => keyframes`
|
|
|
40
37
|
}
|
|
41
38
|
`;
|
|
42
39
|
|
|
43
|
-
const getSize = (size: ButtonSize = '
|
|
40
|
+
const getSize = (size: ButtonSize = 'medium'): FlattenSimpleInterpolation => css`
|
|
44
41
|
font-size: var(--button-${size}-font-size);
|
|
45
42
|
padding: var(--button-${size}-padding);
|
|
46
43
|
min-width: var(--button-${size}-min-width);
|
|
47
44
|
`;
|
|
48
45
|
|
|
49
46
|
export const baseButtonStyles = css`
|
|
50
|
-
display: flex;
|
|
51
|
-
align-items: center;
|
|
52
|
-
justify-content: center;
|
|
53
|
-
gap: 5px;
|
|
54
47
|
outline: none;
|
|
48
|
+
border: none;
|
|
49
|
+
border-radius: var(--button-border-radius);
|
|
50
|
+
font-weight: var(--button-font-weight);
|
|
51
|
+
font-size: 14px;
|
|
52
|
+
padding: 2px 20px;
|
|
55
53
|
margin: var(--button-margin);
|
|
56
54
|
cursor: pointer;
|
|
55
|
+
transition: background-color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
|
|
57
56
|
line-height: 1;
|
|
58
57
|
|
|
59
|
-
color: var(--button-color);
|
|
60
|
-
background-color: var(--button-background-color);
|
|
61
|
-
border: var(--button-border-width) var(--button-border-style) var(--button-border-color);
|
|
62
|
-
border-radius: var(--button-border-radius);
|
|
63
|
-
|
|
64
|
-
font-size: var(--button-font-size);
|
|
65
58
|
font-family: var(--button-font-family);
|
|
66
|
-
font-weight: var(--button-font-weight);
|
|
67
59
|
box-shadow: var(--button-box-shadow);
|
|
68
60
|
|
|
69
61
|
&:hover {
|
|
70
62
|
box-shadow: var(--button-hover-box-shadow);
|
|
71
|
-
background-color: var(--button-hover-background-color);
|
|
72
|
-
border: var(--button-border-width) var(--button-border-style) var(--button-hover-border-color);
|
|
73
63
|
}
|
|
74
64
|
|
|
75
65
|
&:active {
|
|
76
66
|
box-shadow: var(--button-active-box-shadow);
|
|
77
|
-
background-color: var(--button-active-background-color);
|
|
78
|
-
border: var(--button-border-width) var(--button-border-style) var(--button-active-border-color);
|
|
79
67
|
}
|
|
80
68
|
`;
|
|
81
69
|
|
|
82
|
-
const StyledButtonLink = styled(Link)`
|
|
83
|
-
text-decoration: none;
|
|
84
|
-
`;
|
|
85
|
-
|
|
86
70
|
const StyledButton = styled.button.attrs(
|
|
87
71
|
({ color = 'default', extraClass, variant }: ButtonProps) => ({
|
|
88
|
-
className: `button-${color}${variant ? ` button-${variant}` : ''}${
|
|
72
|
+
className: `button-color-${color}${variant ? ` button-variant-${variant}` : ''}${
|
|
89
73
|
extraClass ? ` ${extraClass}` : ''
|
|
90
74
|
}`,
|
|
91
75
|
'data-component-name': 'Button/Button',
|
|
92
76
|
}),
|
|
93
77
|
)<ButtonProps>`
|
|
78
|
+
text-decoration: none;
|
|
79
|
+
text-align: center;
|
|
80
|
+
|
|
94
81
|
width: ${({ fullWidth }) => (fullWidth ? '100%' : 'auto')};
|
|
95
82
|
|
|
96
83
|
${baseButtonStyles}
|
|
@@ -98,20 +85,38 @@ const StyledButton = styled.button.attrs(
|
|
|
98
85
|
${({ variant }) =>
|
|
99
86
|
variant === 'outlined'
|
|
100
87
|
? css`
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
: variant === 'text'
|
|
104
|
-
? css`
|
|
105
|
-
border-color: transparent;
|
|
88
|
+
color: var(--button-background-color);
|
|
89
|
+
border: 2px solid var(--button-border-color);
|
|
106
90
|
background-color: transparent;
|
|
107
|
-
|
|
108
91
|
&:hover {
|
|
109
|
-
|
|
92
|
+
color: var(--button-hover-background-color);
|
|
93
|
+
border: 2px solid var(--button-hover-border-color);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
&:active {
|
|
97
|
+
color: var(--button-active-background-color);
|
|
98
|
+
border: 2px solid var(--button-active-border-color);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
&:disabled {
|
|
102
|
+
color: var(--button-disabled-color);
|
|
110
103
|
background-color: transparent;
|
|
111
|
-
box-shadow: none;
|
|
112
104
|
}
|
|
113
105
|
`
|
|
114
|
-
:
|
|
106
|
+
: css`
|
|
107
|
+
color: var(--button-color);
|
|
108
|
+
border: 2px solid var(--button-background-color);
|
|
109
|
+
background-color: var(--button-background-color);
|
|
110
|
+
&:hover {
|
|
111
|
+
border: 2px solid var(--button-hover-background-color);
|
|
112
|
+
background-color: var(--button-hover-background-color);
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
&:active {
|
|
116
|
+
border: 2px solid var(--button-active-background-color);
|
|
117
|
+
background-color: var(--button-active-background-color);
|
|
118
|
+
}
|
|
119
|
+
`};
|
|
115
120
|
|
|
116
121
|
${({ size }) => getSize(size)}
|
|
117
122
|
|
|
@@ -134,30 +139,21 @@ const StyledButton = styled.button.attrs(
|
|
|
134
139
|
cursor: default;
|
|
135
140
|
color: var(--button-disabled-color);
|
|
136
141
|
background-color: var(--button-disabled-background-color);
|
|
137
|
-
border-color: var(--button-disabled-
|
|
142
|
+
border-color: var(--button-disabled-background-color);
|
|
138
143
|
pointer-events: none;
|
|
139
144
|
}
|
|
140
145
|
`}
|
|
141
146
|
`;
|
|
142
147
|
|
|
143
|
-
const StyledIcon = styled.span`
|
|
144
|
-
display: block;
|
|
145
|
-
height: var(--button-icon-height);
|
|
146
|
-
width: var(--button-icon-width);
|
|
147
|
-
`;
|
|
148
|
-
|
|
149
148
|
const ButtonComponent: React.FC<ButtonProps> = (props) => {
|
|
150
|
-
const button = (
|
|
151
|
-
<StyledButton {...props}>
|
|
152
|
-
{props.icon ? <StyledIcon>{props.icon}</StyledIcon> : null}
|
|
153
|
-
{props.children}
|
|
154
|
-
</StyledButton>
|
|
155
|
-
);
|
|
156
|
-
|
|
157
149
|
if (props.to) {
|
|
158
|
-
return
|
|
150
|
+
return (
|
|
151
|
+
<Link to={props.to}>
|
|
152
|
+
<StyledButton {...props} />
|
|
153
|
+
</Link>
|
|
154
|
+
);
|
|
159
155
|
} else {
|
|
160
|
-
return
|
|
156
|
+
return <StyledButton {...props} />;
|
|
161
157
|
}
|
|
162
158
|
};
|
|
163
159
|
|