diff --git a/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/index.tsx
index f651f16771e7..8eecbe54170a 100644
--- a/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/index.tsx
+++ b/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/index.tsx
@@ -5,34 +5,37 @@
* LICENSE file in the root directory of this source tree.
*/
-import React from 'react';
+import React, {type ReactNode} from 'react';
import {ThemeClassNames, useSidebarBreadcrumbs} from '@docusaurus/theme-common';
import styles from './styles.module.css';
import clsx from 'clsx';
-import type {PropSidebarBreadcrumbsItem} from '@docusaurus/plugin-content-docs';
import Link from '@docusaurus/Link';
+import useBaseUrl from '@docusaurus/useBaseUrl';
-function DocBreadcrumbsItemContent({
- item,
+// TODO move to design system folder
+function BreadcrumbsItemLink({
+ children,
+ href,
}: {
- item: PropSidebarBreadcrumbsItem;
+ children: ReactNode;
+ href?: string;
}): JSX.Element {
- const className = clsx('breadcrumbs__link', styles.breadcrumbItem);
-
- return item.href ? (
-
- {item.label}
+ const className = clsx('breadcrumbs__link', styles.breadcrumbsItemLink);
+ return href ? (
+
+ {children}
) : (
- {item.label}
+ {children}
);
}
-function DocBreadcrumbsItem({
- item,
+// TODO move to design system folder
+function BreadcrumbsItem({
+ children,
active,
}: {
- item: PropSidebarBreadcrumbsItem;
+ children: ReactNode;
active?: boolean;
}): JSX.Element {
return (
@@ -40,11 +43,20 @@ function DocBreadcrumbsItem({
className={clsx('breadcrumbs__item', {
'breadcrumbs__item--active': active,
})}>
-