@redocly/theme 0.69.0 → 0.70.0-next.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (181) hide show
  1. package/lib/components/Buttons/DownloadButton.js +13 -3
  2. package/lib/components/Catalog/Catalog.d.ts +2 -2
  3. package/lib/components/Catalog/CatalogActionsRow.d.ts +3 -2
  4. package/lib/components/Catalog/CatalogCardView/CatalogCard.d.ts +2 -2
  5. package/lib/components/Catalog/CatalogEntities.d.ts +2 -2
  6. package/lib/components/Catalog/CatalogEntitiesEmptyState.d.ts +1 -1
  7. package/lib/components/Catalog/CatalogEntity/CatalogEntityGraph/CatalogEntityRelationsGraph.d.ts +2 -2
  8. package/lib/components/Catalog/CatalogEntity/CatalogEntityGraph/CatalogEntityRelationsGraph.js +1 -2
  9. package/lib/components/Catalog/CatalogEntity/CatalogEntityHistory/CatalogEntityHistoryButton.d.ts +3 -1
  10. package/lib/components/Catalog/CatalogEntity/CatalogEntityHistory/CatalogEntityHistoryButton.js +45 -23
  11. package/lib/components/Catalog/CatalogEntity/CatalogEntityHistory/CatalogEntityHistorySidebar.js +67 -33
  12. package/lib/components/Catalog/CatalogEntity/CatalogEntityHistory/CatalogEntityRevisionItem.d.ts +3 -1
  13. package/lib/components/Catalog/CatalogEntity/CatalogEntityHistory/CatalogEntityRevisionItem.js +15 -3
  14. package/lib/components/Catalog/CatalogEntity/CatalogEntityHistory/CatalogEntityVersionItem.d.ts +3 -1
  15. package/lib/components/Catalog/CatalogEntity/CatalogEntityHistory/CatalogEntityVersionItem.js +48 -57
  16. package/lib/components/Catalog/CatalogEntity/CatalogEntityInfoBar.d.ts +1 -1
  17. package/lib/components/Catalog/CatalogEntity/CatalogEntityLinks.d.ts +1 -1
  18. package/lib/components/Catalog/CatalogEntity/CatalogEntityMetadata.d.ts +1 -1
  19. package/lib/components/Catalog/CatalogEntity/CatalogEntityMethodAndPath.d.ts +1 -1
  20. package/lib/components/Catalog/CatalogEntity/CatalogEntityProperties/CatalogEntityProperties.d.ts +2 -2
  21. package/lib/components/Catalog/CatalogEntity/CatalogEntityProperties/CatalogEntityPropertyCard.d.ts +1 -1
  22. package/lib/components/Catalog/CatalogEntity/CatalogEntityProperties/ContactProperty.d.ts +2 -2
  23. package/lib/components/Catalog/CatalogEntity/CatalogEntityProperties/DomainsProperty.d.ts +2 -2
  24. package/lib/components/Catalog/CatalogEntity/CatalogEntityProperties/EntityTypeProperty.d.ts +2 -2
  25. package/lib/components/Catalog/CatalogEntity/CatalogEntityProperties/FormatProperty.d.ts +2 -2
  26. package/lib/components/Catalog/CatalogEntity/CatalogEntityProperties/GitProperty.d.ts +2 -2
  27. package/lib/components/Catalog/CatalogEntity/CatalogEntityProperties/OwnersProperty.d.ts +2 -2
  28. package/lib/components/Catalog/CatalogEntity/CatalogEntityProperties/OwnersProperty.js +1 -2
  29. package/lib/components/Catalog/CatalogEntity/CatalogEntityProperties/TagsProperty.d.ts +2 -2
  30. package/lib/components/Catalog/CatalogEntity/CatalogEntityProperties/UserEmailProperty.d.ts +2 -2
  31. package/lib/components/Catalog/CatalogEntity/CatalogEntityRelations/CatalogEntityApiDescriptionRelations.d.ts +1 -1
  32. package/lib/components/Catalog/CatalogEntity/CatalogEntityRelations/CatalogEntityDefaultRelations.d.ts +2 -3
  33. package/lib/components/Catalog/CatalogEntity/CatalogEntityRelations/CatalogEntityRelations.d.ts +1 -1
  34. package/lib/components/Catalog/CatalogEntity/CatalogEntityRelations/CatalogEntityRelationsTable.d.ts +3 -4
  35. package/lib/components/Catalog/CatalogEntity/CatalogEntityRelations/CatalogEntityRelationsTableContent.d.ts +3 -4
  36. package/lib/components/Catalog/CatalogEntity/CatalogEntityRelations/CatalogEntityTeamRelations.d.ts +1 -1
  37. package/lib/components/Catalog/CatalogEntity/CatalogEntitySchema.js +1 -2
  38. package/lib/components/Catalog/CatalogEntityIcon.d.ts +1 -1
  39. package/lib/components/Catalog/CatalogEntityTypeTag.d.ts +2 -2
  40. package/lib/components/Catalog/CatalogFilter/CatalogFilterContent.d.ts +1 -1
  41. package/lib/components/Catalog/CatalogFilter/CatalogFilterContent.js +1 -2
  42. package/lib/components/Catalog/CatalogHighlight.d.ts +2 -1
  43. package/lib/components/Catalog/CatalogMobileFiltersPanel/CatalogMobileFiltersPanel.d.ts +2 -1
  44. package/lib/components/Catalog/CatalogMobileFiltersPanel/CatalogMobileFiltersPanelHeader.d.ts +1 -1
  45. package/lib/components/Catalog/CatalogMobileFiltersPanel/CatalogMobileFiltersPanelOverlay.d.ts +2 -1
  46. package/lib/components/Catalog/CatalogMobileTopBar/CatalogMobileTopBar.d.ts +2 -2
  47. package/lib/components/Catalog/CatalogMobileTopBar/CatalogMobileTopBarControls.d.ts +2 -2
  48. package/lib/components/Catalog/CatalogMobileTopBar/CatalogMobileTopBarFiltersButton.d.ts +1 -1
  49. package/lib/components/Catalog/CatalogSelector.d.ts +3 -2
  50. package/lib/components/Catalog/CatalogTableView/CatalogEntityCell.d.ts +1 -1
  51. package/lib/components/Catalog/CatalogTableView/CatalogTableHeaderCell.d.ts +1 -1
  52. package/lib/components/Catalog/CatalogTableView/CatalogTableView.d.ts +2 -1
  53. package/lib/components/Catalog/CatalogTableView/CatalogTableViewRow.d.ts +2 -1
  54. package/lib/components/Catalog/CatalogTableView/CatalogTagsCell.d.ts +1 -1
  55. package/lib/components/Catalog/CatalogTags.d.ts +2 -2
  56. package/lib/components/Catalog/CatalogViewModeToggle.d.ts +1 -1
  57. package/lib/components/Catalog/variables.js +24 -33
  58. package/lib/components/CatalogClassic/CatalogClassicInfoBlock.d.ts +1 -1
  59. package/lib/components/CatalogClassic/CatalogClassicInfoBlock.js +1 -2
  60. package/lib/components/CatalogClassic/CatalogClassicVirtualizedGroups.d.ts +1 -1
  61. package/lib/components/CodeBlock/CodeBlockControls.d.ts +1 -1
  62. package/lib/components/Dropdown/Dropdown.js +7 -1
  63. package/lib/components/Filter/FilterOptionLabel.d.ts +1 -1
  64. package/lib/components/LoadMore/LoadMore.d.ts +1 -1
  65. package/lib/components/MCP/McpConnectionTabs.js +2 -2
  66. package/lib/components/PageActions/PageActions.d.ts +1 -1
  67. package/lib/components/Search/SearchAiDialog.d.ts +1 -1
  68. package/lib/components/Search/SearchAiMessage.d.ts +1 -2
  69. package/lib/components/Search/SearchAiMessage.js +8 -10
  70. package/lib/components/Search/SearchAiResponse.d.ts +1 -1
  71. package/lib/components/Search/SearchGroups.d.ts +1 -1
  72. package/lib/core/constants/markdown.d.ts +2 -0
  73. package/lib/core/constants/markdown.js +3 -1
  74. package/lib/core/hooks/catalog/use-catalog-entity-schema.d.ts +1 -1
  75. package/lib/core/hooks/catalog/use-catalog-table-header-cell-actions.d.ts +1 -1
  76. package/lib/core/hooks/catalog/use-graph.d.ts +3 -3
  77. package/lib/core/hooks/use-active-section-id.js +6 -0
  78. package/lib/core/hooks/use-element-size.d.ts +1 -1
  79. package/lib/core/types/catalog.d.ts +2 -3
  80. package/lib/core/types/common.d.ts +1 -1
  81. package/lib/core/types/hooks.d.ts +4 -7
  82. package/lib/core/utils/mcp.d.ts +0 -1
  83. package/lib/core/utils/mcp.js +0 -13
  84. package/lib/core/utils/menu.d.ts +2 -2
  85. package/lib/core/utils/urls.js +1 -3
  86. package/lib/ext/use-configure-replay.d.ts +1 -1
  87. package/lib/layouts/OIDCForbidden.js +1 -1
  88. package/lib/markdoc/components/CodeWalkthrough/CodePanelPreview.d.ts +1 -2
  89. package/lib/markdoc/components/Diagram/Diagram.d.ts +1 -1
  90. package/lib/markdoc/components/Diagram/Diagram.js +1 -2
  91. package/lib/markdoc/components/Tabs/Tab.d.ts +1 -1
  92. package/lib/markdoc/components/Tabs/TabList.d.ts +1 -1
  93. package/lib/markdoc/tags/code-walkthrough.d.ts +1 -1
  94. package/lib/markdoc/tags/markdoc-example.js +34 -22
  95. package/package.json +2 -2
  96. package/src/components/Buttons/DownloadButton.tsx +16 -8
  97. package/src/components/Catalog/Catalog.tsx +4 -4
  98. package/src/components/Catalog/CatalogActionsRow.tsx +3 -2
  99. package/src/components/Catalog/CatalogCardView/CatalogCard.tsx +3 -2
  100. package/src/components/Catalog/CatalogEntities.tsx +3 -2
  101. package/src/components/Catalog/CatalogEntitiesEmptyState.tsx +2 -1
  102. package/src/components/Catalog/CatalogEntity/CatalogEntity.tsx +6 -2
  103. package/src/components/Catalog/CatalogEntity/CatalogEntityGraph/CatalogEntityRelationsGraph.tsx +4 -5
  104. package/src/components/Catalog/CatalogEntity/CatalogEntityHistory/CatalogEntityHistoryButton.tsx +56 -35
  105. package/src/components/Catalog/CatalogEntity/CatalogEntityHistory/CatalogEntityHistorySidebar.tsx +80 -42
  106. package/src/components/Catalog/CatalogEntity/CatalogEntityHistory/CatalogEntityRevisionItem.tsx +18 -2
  107. package/src/components/Catalog/CatalogEntity/CatalogEntityHistory/CatalogEntityVersionItem.tsx +61 -75
  108. package/src/components/Catalog/CatalogEntity/CatalogEntityInfoBar.tsx +2 -1
  109. package/src/components/Catalog/CatalogEntity/CatalogEntityLinks.tsx +1 -1
  110. package/src/components/Catalog/CatalogEntity/CatalogEntityMetadata.tsx +1 -1
  111. package/src/components/Catalog/CatalogEntity/CatalogEntityMethodAndPath.tsx +1 -1
  112. package/src/components/Catalog/CatalogEntity/CatalogEntityProperties/CatalogEntityProperties.tsx +3 -2
  113. package/src/components/Catalog/CatalogEntity/CatalogEntityProperties/CatalogEntityPropertyCard.tsx +2 -1
  114. package/src/components/Catalog/CatalogEntity/CatalogEntityProperties/ContactProperty.tsx +3 -2
  115. package/src/components/Catalog/CatalogEntity/CatalogEntityProperties/DomainsProperty.tsx +3 -2
  116. package/src/components/Catalog/CatalogEntity/CatalogEntityProperties/EntityTypeProperty.tsx +3 -2
  117. package/src/components/Catalog/CatalogEntity/CatalogEntityProperties/FormatProperty.tsx +3 -2
  118. package/src/components/Catalog/CatalogEntity/CatalogEntityProperties/GitProperty.tsx +3 -2
  119. package/src/components/Catalog/CatalogEntity/CatalogEntityProperties/OwnersProperty.tsx +3 -4
  120. package/src/components/Catalog/CatalogEntity/CatalogEntityProperties/TagsProperty.tsx +3 -2
  121. package/src/components/Catalog/CatalogEntity/CatalogEntityProperties/UserEmailProperty.tsx +3 -2
  122. package/src/components/Catalog/CatalogEntity/CatalogEntityRelations/CatalogEntityApiDescriptionRelations.tsx +2 -1
  123. package/src/components/Catalog/CatalogEntity/CatalogEntityRelations/CatalogEntityDefaultRelations.tsx +7 -4
  124. package/src/components/Catalog/CatalogEntity/CatalogEntityRelations/CatalogEntityRelations.tsx +2 -1
  125. package/src/components/Catalog/CatalogEntity/CatalogEntityRelations/CatalogEntityRelationsTable.tsx +7 -4
  126. package/src/components/Catalog/CatalogEntity/CatalogEntityRelations/CatalogEntityRelationsTableContent.tsx +3 -4
  127. package/src/components/Catalog/CatalogEntity/CatalogEntityRelations/CatalogEntityTeamRelations.tsx +3 -2
  128. package/src/components/Catalog/CatalogEntity/CatalogEntitySchema.tsx +1 -2
  129. package/src/components/Catalog/CatalogEntityIcon.tsx +3 -2
  130. package/src/components/Catalog/CatalogEntityTypeTag.tsx +3 -2
  131. package/src/components/Catalog/CatalogFilter/CatalogFilterContent.tsx +2 -4
  132. package/src/components/Catalog/CatalogHighlight.tsx +2 -1
  133. package/src/components/Catalog/CatalogMobileFiltersPanel/CatalogMobileFiltersPanel.tsx +2 -1
  134. package/src/components/Catalog/CatalogMobileFiltersPanel/CatalogMobileFiltersPanelHeader.tsx +2 -1
  135. package/src/components/Catalog/CatalogMobileFiltersPanel/CatalogMobileFiltersPanelOverlay.tsx +2 -1
  136. package/src/components/Catalog/CatalogMobileTopBar/CatalogMobileTopBar.tsx +3 -2
  137. package/src/components/Catalog/CatalogMobileTopBar/CatalogMobileTopBarControls.tsx +3 -2
  138. package/src/components/Catalog/CatalogMobileTopBar/CatalogMobileTopBarFiltersButton.tsx +2 -1
  139. package/src/components/Catalog/CatalogSelector.tsx +3 -2
  140. package/src/components/Catalog/CatalogTableView/CatalogEntityCell.tsx +1 -1
  141. package/src/components/Catalog/CatalogTableView/CatalogTableHeaderCell.tsx +1 -1
  142. package/src/components/Catalog/CatalogTableView/CatalogTableView.tsx +2 -1
  143. package/src/components/Catalog/CatalogTableView/CatalogTableViewRow.tsx +2 -1
  144. package/src/components/Catalog/CatalogTableView/CatalogTagsCell.tsx +1 -1
  145. package/src/components/Catalog/CatalogTags.tsx +4 -2
  146. package/src/components/Catalog/CatalogViewModeToggle.tsx +1 -1
  147. package/src/components/Catalog/variables.ts +24 -33
  148. package/src/components/CatalogClassic/CatalogClassicInfoBlock.tsx +2 -5
  149. package/src/components/CatalogClassic/CatalogClassicVirtualizedGroups.tsx +1 -1
  150. package/src/components/CodeBlock/CodeBlockControls.tsx +2 -1
  151. package/src/components/Dropdown/Dropdown.tsx +5 -1
  152. package/src/components/Filter/FilterOptionLabel.tsx +1 -1
  153. package/src/components/LoadMore/LoadMore.tsx +2 -1
  154. package/src/components/MCP/McpConnectionTabs.tsx +3 -4
  155. package/src/components/PageActions/PageActions.tsx +2 -1
  156. package/src/components/Search/SearchAiDialog.tsx +1 -1
  157. package/src/components/Search/SearchAiMessage.tsx +3 -6
  158. package/src/components/Search/SearchAiResponse.tsx +2 -4
  159. package/src/components/Search/SearchGroups.tsx +1 -5
  160. package/src/core/constants/markdown.ts +4 -0
  161. package/src/core/hooks/catalog/use-catalog-entity-schema.ts +1 -1
  162. package/src/core/hooks/catalog/use-catalog-table-header-cell-actions.ts +1 -1
  163. package/src/core/hooks/catalog/use-graph.ts +4 -4
  164. package/src/core/hooks/menu/__mocks__/use-mobile-menu-items.ts +1 -1
  165. package/src/core/hooks/use-active-section-id.ts +8 -0
  166. package/src/core/hooks/use-element-size.ts +2 -1
  167. package/src/core/types/catalog.ts +7 -3
  168. package/src/core/types/common.ts +1 -1
  169. package/src/core/types/hooks.ts +15 -13
  170. package/src/core/utils/mcp.ts +0 -17
  171. package/src/core/utils/menu.ts +2 -2
  172. package/src/core/utils/urls.ts +1 -3
  173. package/src/ext/use-configure-replay.ts +3 -3
  174. package/src/layouts/OIDCForbidden.tsx +1 -1
  175. package/src/markdoc/components/CodeWalkthrough/CodePanelPreview.tsx +2 -2
  176. package/src/markdoc/components/CodeWalkthrough/CodeWalkthrough.tsx +2 -4
  177. package/src/markdoc/components/Diagram/Diagram.tsx +2 -5
  178. package/src/markdoc/components/Tabs/Tab.tsx +1 -1
  179. package/src/markdoc/components/Tabs/TabList.tsx +1 -1
  180. package/src/markdoc/tags/code-walkthrough.ts +2 -1
  181. package/src/markdoc/tags/markdoc-example.ts +45 -28
@@ -12,16 +12,26 @@ export type CatalogEntityRevisionItemProps = {
12
12
  revisionItem: CatalogEntityRevision;
13
13
  basePath: string;
14
14
  version?: string | null;
15
+ /** The version's own page URL (from the host's usePageVersions). */
16
+ versionLink?: string;
15
17
  };
16
18
 
17
19
  export function CatalogEntityRevisionItem({
18
20
  revisionItem,
19
21
  basePath,
20
22
  version,
23
+ versionLink,
21
24
  }: CatalogEntityRevisionItemProps): React.ReactElement {
22
25
  const { useTranslate } = useThemeHooks();
23
26
  const { translate } = useTranslate();
24
- const revisionFilter = buildRevisionUrl(basePath, revisionItem.revisionDate, version) ?? basePath;
27
+ // The current revision links to the version's live page. Older revisions
28
+ // add ?revision= to that URL. Hosts without page-version links keep the
29
+ // legacy ?revision=&version= contract.
30
+ const base = versionLink ?? basePath;
31
+ const revisionFilter = revisionItem.isCurrent
32
+ ? base
33
+ : (buildRevisionUrl(base, revisionItem.revisionDate, versionLink ? undefined : version) ??
34
+ base);
25
35
  const isActive = revisionItem.isActive ?? false;
26
36
 
27
37
  return (
@@ -56,12 +66,18 @@ const RevisionItemWrapper = styled(Link)<{ $isActive?: boolean }>`
56
66
  padding-left: var(--catalog-history-sidebar-revisions-padding-left);
57
67
  border-radius: var(--catalog-history-sidebar-revision-item-border-radius);
58
68
  transition: 0.2s ease;
59
- text-decoration: none;
60
69
  color: inherit;
61
70
  cursor: pointer;
62
71
  background-color: ${({ $isActive }) =>
63
72
  $isActive ? 'var(--catalog-history-sidebar-revision-item-bg-color-active)' : 'transparent'};
64
73
 
74
+ &,
75
+ &:hover,
76
+ &:focus,
77
+ &:visited {
78
+ text-decoration: none;
79
+ }
80
+
65
81
  &:hover {
66
82
  background-color: ${({ $isActive }) =>
67
83
  $isActive
@@ -5,10 +5,9 @@ import type { CatalogEntityVersionHistoryGroup } from '@redocly/theme/core/types
5
5
 
6
6
  import { ChevronDownIcon } from '@redocly/theme/icons/ChevronDownIcon/ChevronDownIcon';
7
7
  import { ChevronRightIcon } from '@redocly/theme/icons/ChevronRightIcon/ChevronRightIcon';
8
- import { CheckmarkOutlineIcon } from '@redocly/theme/icons/CheckmarkOutlineIcon/CheckmarkOutlineIcon';
8
+ import { RadioCheckButtonIcon } from '@redocly/theme/icons/RadioCheckButtonIcon/RadioCheckButtonIcon';
9
9
  import { NavaidMilitaryIcon } from '@redocly/theme/icons/NavaidMilitaryIcon/NavaidMilitaryIcon';
10
10
  import { Link } from '@redocly/theme/components/Link/Link';
11
- import { Tag } from '@redocly/theme/components/Tag/Tag';
12
11
  import { useThemeHooks } from '@redocly/theme/core/hooks';
13
12
  import { ShowMoreButton } from '@redocly/theme/components/Catalog/CatalogEntity/ShowMoreButton';
14
13
  import { CatalogEntityRevisionItem } from '@redocly/theme/components/Catalog/CatalogEntity/CatalogEntityHistory/CatalogEntityRevisionItem';
@@ -23,6 +22,8 @@ export type CatalogEntityVersionItemProps = {
23
22
  basePath: string;
24
23
  isExpanded: boolean;
25
24
  onToggle: (version: string) => void;
25
+ /** This version's own page URL (from the host's usePageVersions). */
26
+ versionLink?: string;
26
27
  };
27
28
 
28
29
  export function CatalogEntityVersionItem({
@@ -30,13 +31,16 @@ export function CatalogEntityVersionItem({
30
31
  basePath,
31
32
  isExpanded,
32
33
  onToggle,
34
+ versionLink,
33
35
  }: CatalogEntityVersionItemProps): React.ReactElement {
34
36
  const { useTranslate } = useThemeHooks();
35
37
  const { translate } = useTranslate();
36
38
  const [showAllRevisions, setShowAllRevisions] = useState(false);
37
39
 
38
40
  const revisions = group.revisions || [];
39
- const hasRevisions = revisions.length > 0;
41
+ // A version with one revision links straight to its page instead of
42
+ // expanding.
43
+ const hasExpandableRevisions = revisions.length > 1;
40
44
  const hasMoreThanMax = revisions.length > MAX_INITIAL_REVISIONS;
41
45
  const hasMoreThanLimit = revisions.length > MAX_REVISIONS;
42
46
  const displayedRevisions = showAllRevisions
@@ -51,55 +55,43 @@ export function CatalogEntityVersionItem({
51
55
 
52
56
  const isNotSpecifiedVersion = group.version === VERSION_NOT_SPECIFIED;
53
57
 
54
- const singleRevisionLink = buildRevisionUrl(basePath, group.singleRevisionDate, group.version);
58
+ // Hosts without page-version links (catalog entities) keep the legacy
59
+ // ?revision=&version= contract.
60
+ const versionRowLink = hasExpandableRevisions
61
+ ? undefined
62
+ : (versionLink ?? buildRevisionUrl(basePath, group.singleRevisionDate, group.version));
55
63
 
56
- const versionTitle = isNotSpecifiedVersion
57
- ? `${translate('catalog.history.version.label', 'Version')}:\u00a0${translate('catalog.history.version.notSpecified', 'not specified')}`
58
- : `${translate('catalog.history.version.label', 'Version')}:\u00a0${group.version}`;
64
+ const versionName = isNotSpecifiedVersion
65
+ ? translate('catalog.history.version.notSpecified', 'not specified')
66
+ : group.version;
67
+ const latestWord = translate('catalog.history.version.latest', 'latest');
68
+ // A version named "latest" already says it: no "(latest)" suffix.
69
+ const latestSuffix =
70
+ group.isDefaultVersion && versionName.toLowerCase() !== latestWord.toLowerCase()
71
+ ? ` (${latestWord})`
72
+ : '';
73
+ const versionTitle = `${translate('catalog.history.version.label', 'Version')}:\u00a0${versionName}${latestSuffix}`;
59
74
 
60
75
  const versionButton = (
61
76
  <VersionButton
62
77
  type="button"
63
- onClick={() => hasRevisions && onToggle(group.version)}
78
+ onClick={() => hasExpandableRevisions && onToggle(group.version)}
64
79
  $isCurrent={group.isCurrent}
65
80
  >
66
81
  <VersionIcon $isCurrent={group.isCurrent}>
67
82
  {group.isCurrent ? (
68
- <CheckmarkOutlineIcon
69
- size="16px"
70
- color="--catalog-history-sidebar-version-icon-color-current"
71
- />
83
+ <CurrentVersionIcon />
72
84
  ) : (
73
- <NavaidMilitaryIcon size="16px" color="--catalog-history-sidebar-version-icon-color" />
85
+ <NavaidMilitaryIcon size="14px" color="--catalog-history-sidebar-version-icon-color" />
74
86
  )}
75
87
  </VersionIcon>
76
- <VersionInfo>
77
- <VersionTitleRow>
78
- <VersionTitle>{versionTitle}</VersionTitle>
79
- {group.isDefaultVersion && (
80
- <Tag
81
- color="grey"
82
- borderless
83
- textTransform="lowercase"
84
- style={{
85
- fontSize: 'var(--font-size-xs)',
86
- borderRadius: 'var(--catalog-history-sidebar-version-tag-border-radius)',
87
- flexShrink: 0,
88
- marginLeft: 'var(--spacing-xxs)',
89
- }}
90
- >
91
- {translate('catalog.history.version.default', 'default')}
92
- </Tag>
93
- )}
94
- </VersionTitleRow>
95
- {!isNotSpecifiedVersion && <VersionDate>{group.date}</VersionDate>}
96
- </VersionInfo>
97
- {hasRevisions && (
88
+ <VersionTitle>{versionTitle}</VersionTitle>
89
+ {hasExpandableRevisions && (
98
90
  <ChevronIcon>
99
91
  {isExpanded ? (
100
- <ChevronDownIcon size="16px" color="--catalog-history-sidebar-chevron-icon-color" />
92
+ <ChevronDownIcon size="12px" color="--catalog-history-sidebar-chevron-icon-color" />
101
93
  ) : (
102
- <ChevronRightIcon size="16px" color="--catalog-history-sidebar-chevron-icon-color" />
94
+ <ChevronRightIcon size="12px" color="--catalog-history-sidebar-chevron-icon-color" />
103
95
  )}
104
96
  </ChevronIcon>
105
97
  )}
@@ -108,9 +100,13 @@ export function CatalogEntityVersionItem({
108
100
 
109
101
  return (
110
102
  <li>
111
- {singleRevisionLink ? <Link to={singleRevisionLink}>{versionButton}</Link> : versionButton}
103
+ {versionRowLink ? (
104
+ <VersionLinkWrapper to={versionRowLink}>{versionButton}</VersionLinkWrapper>
105
+ ) : (
106
+ versionButton
107
+ )}
112
108
 
113
- {hasRevisions && isExpanded && (
109
+ {hasExpandableRevisions && isExpanded && (
114
110
  <RevisionsList>
115
111
  {displayedRevisions.map((revisionItem) => (
116
112
  <CatalogEntityRevisionItem
@@ -118,6 +114,7 @@ export function CatalogEntityVersionItem({
118
114
  revisionItem={revisionItem}
119
115
  basePath={basePath}
120
116
  version={group.version}
117
+ versionLink={versionLink}
121
118
  />
122
119
  ))}
123
120
  {hasMoreThanLimit && showAllRevisions && (
@@ -150,32 +147,41 @@ export function CatalogEntityVersionItem({
150
147
  );
151
148
  }
152
149
 
150
+ const VersionLinkWrapper = styled(Link)`
151
+ display: block;
152
+ color: inherit;
153
+
154
+ &,
155
+ &:hover,
156
+ &:focus,
157
+ &:visited {
158
+ text-decoration: none;
159
+ }
160
+ `;
161
+
153
162
  const VersionButton = styled.button<{
154
163
  $isCurrent?: boolean;
155
164
  }>`
156
165
  all: unset;
166
+ box-sizing: border-box;
157
167
  display: flex;
158
168
  align-items: center;
159
- width: calc(100% - var(--catalog-history-sidebar-version-icon-margin-right));
169
+ width: 100%;
160
170
  padding: var(--catalog-history-sidebar-version-header-padding);
161
171
  cursor: pointer;
162
172
  border-radius: var(--catalog-history-sidebar-version-header-border-radius);
163
173
  transition: 0.2s ease;
164
174
  text-decoration: none;
165
175
  color: inherit;
166
- background-color: 'transparent';
176
+ background-color: ${({ $isCurrent }) =>
177
+ $isCurrent ? 'var(--catalog-history-sidebar-version-header-bg-color-current)' : 'transparent'};
167
178
 
168
179
  &:hover {
169
- background-color: var(--catalog-history-sidebar-version-header-bg-color-hover);
180
+ background-color: ${({ $isCurrent }) =>
181
+ $isCurrent
182
+ ? 'var(--catalog-history-sidebar-version-header-bg-color-current)'
183
+ : 'var(--catalog-history-sidebar-version-header-bg-color-hover)'};
170
184
  }
171
-
172
- ${({ $isCurrent }) =>
173
- !$isCurrent &&
174
- `
175
- &:hover ${VersionIcon} {
176
- background-color: var(--color-static-white);
177
- }
178
- `}
179
185
  `;
180
186
 
181
187
  const VersionIcon = styled.div<{ $isCurrent?: boolean }>`
@@ -190,25 +196,13 @@ const VersionIcon = styled.div<{ $isCurrent?: boolean }>`
190
196
  $isCurrent
191
197
  ? 'var(--color-primary-base, var(--color-blueberry-6))'
192
198
  : 'var(--catalog-avatar-bg-color)'};
193
- transition: background-color 0.2s ease;
194
199
  margin-right: var(--catalog-history-sidebar-version-icon-margin-right);
195
-
196
- svg path {
197
- transition: fill 0.2s ease;
198
- }
199
- `;
200
-
201
- const VersionInfo = styled.div`
202
- display: flex;
203
- flex-direction: column;
204
- align-items: flex-start;
205
- gap: var(--catalog-history-sidebar-version-info-gap);
206
200
  `;
207
201
 
208
- const VersionTitleRow = styled.div`
209
- display: flex;
210
- align-items: center;
211
- gap: var(--spacing-xs, 8px);
202
+ const CurrentVersionIcon = styled(RadioCheckButtonIcon)`
203
+ width: 14px;
204
+ height: 14px;
205
+ color: var(--catalog-history-sidebar-version-icon-color-current);
212
206
  `;
213
207
 
214
208
  const VersionTitle = styled.span`
@@ -223,14 +217,6 @@ const VersionTitle = styled.span`
223
217
  word-break: break-word;
224
218
  `;
225
219
 
226
- const VersionDate = styled.span`
227
- font-family: var(--catalog-history-sidebar-version-date-font-family);
228
- font-size: var(--catalog-history-sidebar-version-date-font-size);
229
- font-weight: var(--catalog-history-sidebar-version-date-font-weight);
230
- line-height: var(--catalog-history-sidebar-version-date-line-height);
231
- color: var(--catalog-history-sidebar-version-date-color);
232
- `;
233
-
234
220
  const ChevronIcon = styled.div`
235
221
  display: flex;
236
222
  align-items: center;
@@ -250,7 +236,7 @@ const RevisionsList = styled.ul`
250
236
  &::before {
251
237
  content: '';
252
238
  position: absolute;
253
- left: 22px;
239
+ left: var(--catalog-history-sidebar-revision-line-left);
254
240
  top: 0;
255
241
  bottom: var(--catalog-history-sidebar-revisions-padding-bottom);
256
242
  width: 1px;
@@ -1,4 +1,5 @@
1
- import React, { ReactNode, JSX } from 'react';
1
+ import type { ReactNode, JSX } from 'react';
2
+ import React from 'react';
2
3
  import styled from 'styled-components';
3
4
 
4
5
  export type CatalogEntityInfoBarProps = {
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  import styled from 'styled-components';
3
3
 
4
- import { BffCatalogEntity } from '@redocly/theme/core/types';
4
+ import type { BffCatalogEntity } from '@redocly/theme/core/types';
5
5
  import { LaunchIcon } from '@redocly/theme/icons/LaunchIcon/LaunchIcon';
6
6
  import { LinkIcon } from '@redocly/theme/icons/LinkIcon/LinkIcon';
7
7
  import { CatalogEntityInfoBar } from '@redocly/theme/components/Catalog/CatalogEntity/CatalogEntityInfoBar';
@@ -1,7 +1,7 @@
1
1
  import React, { useState } from 'react';
2
2
  import styled from 'styled-components';
3
3
 
4
- import { BffCatalogEntity } from '@redocly/theme/core/types';
4
+ import type { BffCatalogEntity } from '@redocly/theme/core/types';
5
5
  import { JsonViewer } from '@redocly/theme/components/JsonViewer/JsonViewer';
6
6
  import { capitalize, isPlainObject } from '@redocly/theme/core/utils';
7
7
  import { useThemeHooks } from '@redocly/theme/core/hooks';
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  import styled from 'styled-components';
3
3
 
4
- import { BffCatalogEntity } from '@redocly/theme/core/types';
4
+ import type { BffCatalogEntity } from '@redocly/theme/core/types';
5
5
  import { CatalogEntityInfoBar } from '@redocly/theme/components/Catalog/CatalogEntity/CatalogEntityInfoBar';
6
6
  import { HttpTag } from '@redocly/theme/components/Tags/HttpTag';
7
7
  import { useThemeHooks } from '@redocly/theme/core/hooks';
@@ -1,7 +1,8 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
  import styled from 'styled-components';
3
4
 
4
- import { BffCatalogEntity } from '@redocly/theme/core/types';
5
+ import type { BffCatalogEntity } from '@redocly/theme/core/types';
5
6
  import { EntityTypeProperty } from '@redocly/theme/components/Catalog/CatalogEntity/CatalogEntityProperties/EntityTypeProperty';
6
7
  import { GitProperty } from '@redocly/theme/components/Catalog/CatalogEntity/CatalogEntityProperties/GitProperty';
7
8
  import { TagsProperty } from '@redocly/theme/components/Catalog/CatalogEntity/CatalogEntityProperties/TagsProperty';
@@ -1,4 +1,5 @@
1
- import React, { ReactNode, JSX } from 'react';
1
+ import type { ReactNode, JSX } from 'react';
2
+ import React from 'react';
2
3
  import styled from 'styled-components';
3
4
 
4
5
  export type CatalogEntityPropertyCardProps = {
@@ -1,6 +1,7 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
 
3
- import { BffCatalogEntity } from '@redocly/theme/core/types';
4
+ import type { BffCatalogEntity } from '@redocly/theme/core/types';
4
5
  import { SlackIcon } from '@redocly/theme/icons/SlackIcon/SlackIcon';
5
6
  import { CatalogEntityPropertyCard } from '@redocly/theme/components/Catalog/CatalogEntity/CatalogEntityProperties/CatalogEntityPropertyCard';
6
7
  import { useThemeHooks } from '@redocly/theme/core/hooks';
@@ -1,6 +1,7 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
 
3
- import { BffCatalogEntity, CatalogEntityPageProps } from '@redocly/theme/core/types';
4
+ import type { BffCatalogEntity, CatalogEntityPageProps } from '@redocly/theme/core/types';
4
5
  import { GraphIcon } from '@redocly/theme/icons/GraphIcon/GraphIcon';
5
6
  import { CatalogEntityPropertyCard } from '@redocly/theme/components/Catalog/CatalogEntity/CatalogEntityProperties/CatalogEntityPropertyCard';
6
7
  import { useCatalogEntityLink, useThemeHooks } from '@redocly/theme/core/hooks';
@@ -1,6 +1,7 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
 
3
- import { BffCatalogEntity } from '@redocly/theme/core/types';
4
+ import type { BffCatalogEntity } from '@redocly/theme/core/types';
4
5
  import { EntityTypeIcon } from '@redocly/theme/icons/EntityTypeIcon/EntityTypeIcon';
5
6
  import { capitalize } from '@redocly/theme/core/utils';
6
7
  import { CatalogEntityTypeIcon } from '@redocly/theme/components/Catalog/CatalogEntityTypeIcon';
@@ -1,6 +1,7 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
 
3
- import { BffCatalogEntity } from '@redocly/theme/core/types';
4
+ import type { BffCatalogEntity } from '@redocly/theme/core/types';
4
5
  import { NotesIcon } from '@redocly/theme/icons/NotesIcon/NotesIcon';
5
6
  import { Tag } from '@redocly/theme/components/Tag/Tag';
6
7
  import { CatalogEntityPropertyCard } from '@redocly/theme/components/Catalog/CatalogEntity/CatalogEntityProperties/CatalogEntityPropertyCard';
@@ -1,6 +1,7 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
 
3
- import { BffCatalogEntity } from '@redocly/theme/core/types';
4
+ import type { BffCatalogEntity } from '@redocly/theme/core/types';
4
5
  import { GithubIcon } from '@redocly/theme/icons/GithubIcon/GithubIcon';
5
6
  import { removeLeadingSlash } from '@redocly/theme/core/utils';
6
7
  import { Tag } from '@redocly/theme/components/Tag/Tag';
@@ -1,10 +1,9 @@
1
- import React, { JSX } from 'react';
1
+ import React, { type JSX } from 'react';
2
2
 
3
- import { BffCatalogEntity, CatalogEntityPageProps } from '@redocly/theme/core/types';
4
- import { useCatalogEntityLink } from '@redocly/theme/core/hooks';
3
+ import type { BffCatalogEntity, CatalogEntityPageProps } from '@redocly/theme/core/types';
4
+ import { useCatalogEntityLink, useThemeHooks } from '@redocly/theme/core/hooks';
5
5
  import { PeopleIcon } from '@redocly/theme/icons/PeopleIcon/PeopleIcon';
6
6
  import { CatalogEntityPropertyCard } from '@redocly/theme/components/Catalog/CatalogEntity/CatalogEntityProperties/CatalogEntityPropertyCard';
7
- import { useThemeHooks } from '@redocly/theme/core/hooks';
8
7
  import { Button } from '@redocly/theme/components/Button/Button';
9
8
  import { CatalogAvatar } from '@redocly/theme/components/Catalog/CatalogAvatar';
10
9
 
@@ -1,6 +1,7 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
 
3
- import { BffCatalogEntity } from '@redocly/theme/core/types';
4
+ import type { BffCatalogEntity } from '@redocly/theme/core/types';
4
5
  import { TagsIcon } from '@redocly/theme/icons/TagsIcon/TagsIcon';
5
6
  import { CatalogTags } from '@redocly/theme/components/Catalog/CatalogTags';
6
7
  import { CatalogEntityPropertyCard } from '@redocly/theme/components/Catalog/CatalogEntity/CatalogEntityProperties/CatalogEntityPropertyCard';
@@ -1,6 +1,7 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
 
3
- import { BffCatalogEntity } from '@redocly/theme/core/types';
4
+ import type { BffCatalogEntity } from '@redocly/theme/core/types';
4
5
  import { EmailIcon } from '@redocly/theme/icons/EmailIcon/EmailIcon';
5
6
  import { CatalogEntityPropertyCard } from '@redocly/theme/components/Catalog/CatalogEntity/CatalogEntityProperties/CatalogEntityPropertyCard';
6
7
  import { Email } from '@redocly/theme/components/Catalog/CatalogTableView/CatalogUserEntityCell';
@@ -1,4 +1,5 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
  import styled from 'styled-components';
3
4
 
4
5
  import type { CatalogEntityConfig, EntitiesCatalogConfig } from '@redocly/config';
@@ -1,10 +1,13 @@
1
- import React, { JSX } from 'react';
1
+ import React, { type JSX } from 'react';
2
2
 
3
3
  import type { CatalogEntityConfig, EntitiesCatalogConfig } from '@redocly/config';
4
- import type { ListType } from '@redocly/theme/core/types';
5
- import type { BffCatalogEntity, BffCatalogRelatedEntity } from '@redocly/theme/core/types';
4
+ import type {
5
+ ListType,
6
+ BffCatalogEntity,
7
+ BffCatalogRelatedEntity,
8
+ } from '@redocly/theme/core/types';
6
9
 
7
- import { CatalogColumn } from '@redocly/theme/components/Catalog/CatalogTableView/CatalogTableView';
10
+ import type { CatalogColumn } from '@redocly/theme/components/Catalog/CatalogTableView/CatalogTableView';
8
11
  import { CatalogEntityCell } from '@redocly/theme/components/Catalog/CatalogTableView/CatalogEntityCell';
9
12
  import { CatalogEntityRelationsTable } from '@redocly/theme/components/Catalog/CatalogEntity/CatalogEntityRelations/CatalogEntityRelationsTable';
10
13
  import { CatalogEntityTypeTag } from '@redocly/theme/components/Catalog/CatalogEntityTypeTag';
@@ -1,4 +1,5 @@
1
- import React, { JSX, useState, useMemo } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React, { useState, useMemo } from 'react';
2
3
 
3
4
  import type { CatalogEntityConfig, EntitiesCatalogConfig } from '@redocly/config';
4
5
  import type { BffCatalogEntity, BffCatalogRelatedEntityList } from '@redocly/theme/core/types';
@@ -1,11 +1,14 @@
1
- import React, { JSX } from 'react';
1
+ import React, { type JSX } from 'react';
2
2
  import styled from 'styled-components';
3
3
 
4
4
  import type { CatalogEntityConfig, EntitiesCatalogConfig } from '@redocly/config';
5
- import type { ListType } from '@redocly/theme/core/types';
6
- import type { BffCatalogEntity, BffCatalogRelatedEntity } from '@redocly/theme/core/types';
5
+ import type {
6
+ ListType,
7
+ BffCatalogEntity,
8
+ BffCatalogRelatedEntity,
9
+ } from '@redocly/theme/core/types';
7
10
 
8
- import { CatalogColumn } from '@redocly/theme/components/Catalog/CatalogTableView/CatalogTableView';
11
+ import type { CatalogColumn } from '@redocly/theme/components/Catalog/CatalogTableView/CatalogTableView';
9
12
  import { CatalogActionsRow } from '@redocly/theme/components/Catalog/CatalogActionsRow';
10
13
  import { CatalogEntityRelationsTableContent } from '@redocly/theme/components/Catalog/CatalogEntity/CatalogEntityRelations/CatalogEntityRelationsTableContent';
11
14
  import { useThemeHooks } from '@redocly/theme/core/hooks';
@@ -1,14 +1,13 @@
1
- import React, { JSX } from 'react';
1
+ import React, { type JSX } from 'react';
2
2
  import styled from 'styled-components';
3
3
 
4
4
  import type { CatalogEntityConfig, EntitiesCatalogConfig } from '@redocly/config';
5
- import type { ListType } from '@redocly/theme/core/types';
6
- import type { BffCatalogRelatedEntity } from '@redocly/theme/core/types';
5
+ import type { ListType, BffCatalogRelatedEntity } from '@redocly/theme/core/types';
7
6
 
8
7
  import { ArrowDownIcon } from '@redocly/theme/icons/ArrowDownIcon/ArrowDownIcon';
9
8
  import { LoadMore } from '@redocly/theme/components/LoadMore/LoadMore';
10
9
  import {
11
- CatalogColumn,
10
+ type CatalogColumn,
12
11
  CatalogTableView,
13
12
  } from '@redocly/theme/components/Catalog/CatalogTableView/CatalogTableView';
14
13
  import { HighlightContext } from '@redocly/theme/components/Catalog/CatalogHighlight';
@@ -1,4 +1,5 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
  import styled from 'styled-components';
3
4
 
4
5
  import type { CatalogEntityConfig, EntitiesCatalogConfig } from '@redocly/config';
@@ -8,7 +9,7 @@ import { Tabs, TabsSize } from '@redocly/theme/markdoc/components/Tabs/Tabs';
8
9
  import { TabItemFragment } from '@redocly/theme/markdoc/components/Tabs/TabItemFragment';
9
10
  import { PeopleIcon } from '@redocly/theme/icons/PeopleIcon/PeopleIcon';
10
11
  import { EntityTypeIcon } from '@redocly/theme/icons/EntityTypeIcon/EntityTypeIcon';
11
- import { CatalogColumn } from '@redocly/theme/components/Catalog/CatalogTableView/CatalogTableView';
12
+ import type { CatalogColumn } from '@redocly/theme/components/Catalog/CatalogTableView/CatalogTableView';
12
13
  import { Tag } from '@redocly/theme/components/Tag/Tag';
13
14
  import { CatalogEntityRelationsTable } from '@redocly/theme/components/Catalog/CatalogEntity/CatalogEntityRelations/CatalogEntityRelationsTable';
14
15
  import { CatalogUserEntityCell } from '@redocly/theme/components/Catalog/CatalogTableView/CatalogUserEntityCell';
@@ -5,8 +5,7 @@ import * as Sampler from 'openapi-sampler';
5
5
  import type { CatalogEntityConfig } from '@redocly/config';
6
6
  import type { BffCatalogEntity, BffCatalogRelatedEntity } from '@redocly/theme/core/types';
7
7
 
8
- import { useThemeHooks } from '@redocly/theme/core/hooks';
9
- import { useCatalogEntitySchema } from '@redocly/theme/core/hooks';
8
+ import { useThemeHooks, useCatalogEntitySchema } from '@redocly/theme/core/hooks';
10
9
  import { getBaseDataAttributes } from '@redocly/theme/core/utils';
11
10
  import { JsonViewer } from '@redocly/theme/components/JsonViewer/JsonViewer';
12
11
  import { CopyButton } from '@redocly/theme/components/Buttons/CopyButton';
@@ -1,8 +1,9 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
 
3
4
  import type { UiAccessibleConfig } from '@redocly/config';
4
5
 
5
- import { EntityType } from '@redocly/theme/core/types';
6
+ import type { EntityType } from '@redocly/theme/core/types';
6
7
  import { CodeIcon } from '@redocly/theme/icons/CodeIcon/CodeIcon';
7
8
  import { GraphIcon } from '@redocly/theme/icons/GraphIcon/GraphIcon';
8
9
  import { PeopleIcon } from '@redocly/theme/icons/PeopleIcon/PeopleIcon';
@@ -1,7 +1,8 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
  import styled from 'styled-components';
3
4
 
4
- import { EntityType } from '@redocly/theme/core/types';
5
+ import type { EntityType } from '@redocly/theme/core/types';
5
6
  import { Tag } from '@redocly/theme/components/Tag/Tag';
6
7
  import { CatalogHighlight } from '@redocly/theme/components/Catalog/CatalogHighlight';
7
8
  import { PREDEFINED_ENTITY_TYPES } from '@redocly/theme/core';
@@ -1,15 +1,13 @@
1
- import React from 'react';
1
+ import React, { type JSX, type ReactNode } from 'react';
2
2
  import styled from 'styled-components';
3
3
 
4
- import type { JSX, ReactNode } from 'react';
5
4
  import type { ResolvedFilter } from '@redocly/theme/core/types';
6
5
  import type { RedoclyConfig } from '@redocly/theme/config';
7
6
 
8
7
  import { useThemeHooks } from '@redocly/theme/core/hooks';
9
8
  import { Button } from '@redocly/theme/components/Button/Button';
10
9
  import { CatalogFilter } from '@redocly/theme/components/Catalog/CatalogFilter/CatalogFilter';
11
- import { breakpoints } from '@redocly/theme/core/utils';
12
- import { isFromToSelectedOptions } from '@redocly/theme/core/utils';
10
+ import { breakpoints, isFromToSelectedOptions } from '@redocly/theme/core/utils';
13
11
 
14
12
  export type CatalogFilterContentProps = {
15
13
  onClear: () => void;
@@ -1,4 +1,5 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
  import { findAll } from 'highlight-words-core';
3
4
  import styled from 'styled-components';
4
5
 
@@ -1,4 +1,5 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
  import styled from 'styled-components';
3
4
 
4
5
  import { CatalogMobileFiltersPanelHeader } from '@redocly/theme/components/Catalog/CatalogMobileFiltersPanel/CatalogMobileFiltersPanelHeader';
@@ -1,4 +1,5 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
  import styled from 'styled-components';
3
4
 
4
5
  import { Button } from '@redocly/theme/components/Button/Button';
@@ -1,4 +1,5 @@
1
- import React, { JSX } from 'react';
1
+ import type { JSX } from 'react';
2
+ import React from 'react';
2
3
  import styled from 'styled-components';
3
4
 
4
5
  import { breakpoints } from '@redocly/theme/core';