diff --git a/packages/docusaurus-theme-classic/src/theme-classic.d.ts b/packages/docusaurus-theme-classic/src/theme-classic.d.ts index 4e9f0d995551..a3388507acc3 100644 --- a/packages/docusaurus-theme-classic/src/theme-classic.d.ts +++ b/packages/docusaurus-theme-classic/src/theme-classic.d.ts @@ -1110,6 +1110,14 @@ declare module '@theme/IconEdit' { export default function IconEdit(props: Props): JSX.Element; } +declare module '@theme/IconHome' { + import type {ComponentProps} from 'react'; + + export interface Props extends ComponentProps<'svg'> {} + + export default function IconHome(props: Props): JSX.Element; +} + declare module '@theme/IconLightMode' { import type {ComponentProps} from 'react'; diff --git a/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/index.tsx b/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/index.tsx index d273cc31700c..795a3d0b7187 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/index.tsx +++ b/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/index.tsx @@ -15,6 +15,7 @@ import styles from './styles.module.css'; import clsx from 'clsx'; import Link from '@docusaurus/Link'; import useBaseUrl from '@docusaurus/useBaseUrl'; +import IconHome from '@theme/IconHome'; // TODO move to design system folder function BreadcrumbsItemLink({ @@ -76,7 +77,7 @@ function HomeBreadcrumbItem() { - 🏠 + ); diff --git a/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/styles.module.css b/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/styles.module.css index a400c5d9e622..dcdcf466b47a 100644 --- a/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/styles.module.css +++ b/packages/docusaurus-theme-classic/src/theme/DocBreadcrumbs/styles.module.css @@ -9,3 +9,9 @@ --ifm-breadcrumb-size-multiplier: 0.8; margin-bottom: 0.8rem; } + +.icon { + vertical-align: middle; + height: 1rem; + width: 1rem; +} diff --git a/packages/docusaurus-theme-classic/src/theme/IconHome/index.tsx b/packages/docusaurus-theme-classic/src/theme/IconHome/index.tsx new file mode 100644 index 000000000000..8afdbc31defc --- /dev/null +++ b/packages/docusaurus-theme-classic/src/theme/IconHome/index.tsx @@ -0,0 +1,26 @@ +/** + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + +import React from 'react'; +import type {Props} from '@theme/IconHome'; + +export default function IconDarkMode(props: Props): JSX.Element { + return ( + + + + + ); +}