diff --git a/components/Headlines.tsx b/components/Headlines.tsx index 3352cb0df..65ea052c6 100644 --- a/components/Headlines.tsx +++ b/components/Headlines.tsx @@ -53,14 +53,14 @@ const filterFragment = (children: string | React.ReactNode[]) => { type TagProps = { children: React.ReactNode, attributes: Record } const Headline1Tag = ({ children, attributes }: TagProps) => ( -

{children}

+

{children}

) const Headline2Tag = ({ children, attributes }: TagProps) => ( -

{children}

+

{children}

) const Headline3Tag = ({ children, attributes }: TagProps) => ( -

{children}

+

{children}

) const Headline4Tag = ({ children, attributes }: TagProps) => ( -

{children}

-) +

{children}

+) \ No newline at end of file diff --git a/components/JsonEditor.tsx b/components/JsonEditor.tsx index 13fce33ab..841134bb2 100644 --- a/components/JsonEditor.tsx +++ b/components/JsonEditor.tsx @@ -246,7 +246,7 @@ export default function JsonEditor ({ initialCode }: { initialCode: string }) { if (!link) return router.push(link) }} - className={classnames('p-b-2', textStyles)} + className={classnames('pb-2', textStyles)} title={leaf.syntaxPart?.type} {...attributes} >{children} diff --git a/components/Layout.tsx b/components/Layout.tsx index 5e4df7b65..1c15a608b 100644 --- a/components/Layout.tsx +++ b/components/Layout.tsx @@ -1,4 +1,4 @@ -import React, { useContext } from 'react' +import React, { useContext, useState } from 'react' import Head from 'next/head' import Link from 'next/link' import classnames from 'classnames' @@ -7,6 +7,8 @@ import { DocSearch } from '@docsearch/react' import { HOST } from '~/lib/config' import useStore from '~/store' import { SectionContext } from '~/context' +// import { SidebarData } from './SidebarData' + type Props = { children: React.ReactNode @@ -16,9 +18,10 @@ type Props = { hideAds?: boolean } -const responsiveClasses = 'w-full xl:w-[1200px] px-2 sm:px-4 lg:px-8' +const responsiveClasses = 'w-screen' export default function Layout({ children, mainClassName, metaTitle, whiteBg, hideAds }: Props) { + const showMobileNav = useStore(s => s.overlayNavigation === 'docs') const router = useRouter() React.useEffect(() => useStore.setState({ overlayNavigation: null }), [router.asPath]) @@ -29,246 +32,335 @@ export default function Layout({ children, mainClassName, metaTitle, whiteBg, hi JSON Schema {metaTitle ? ` - ${metaTitle}` : ''} + +
+
+
+
+ + +
+
-
-
-
- -
- -
- -
-
- {!hideAds && ( -
-