diff --git a/src/theme/NotFound/Content/index.tsx b/src/theme/NotFound/Content/index.tsx index 6d1fa37f59d..8600f218a57 100644 --- a/src/theme/NotFound/Content/index.tsx +++ b/src/theme/NotFound/Content/index.tsx @@ -12,16 +12,19 @@ import type { Props } from '@theme/NotFound/Content'; import Heading from '@theme/Heading'; import { Content, Section } from '@site/src/css/SharedStyling'; import { useLocation } from '@docusaurus/router'; +import styled from 'styled-components'; // Internal Components import Footer from '@site/src/segments/Footer'; export default function NotFoundContent({ className }: Props): JSX.Element { const location = useLocation(); - const pathname = location.pathname; + + // Determine if the pathname starts with '/docs' + const isDocsPage = location.pathname.startsWith('/docs'); return ( - <> +
@@ -58,7 +61,13 @@ export default function NotFoundContent({ className }: Props): JSX.Element {
- {location.pathname.startsWith('/docs') &&