import { ReactNode, useMemo } from 'react'
import { Outlet, useLocation } from '@remix-run/react'
import { MDXProvider } from '@mdx-js/react'
import { PencilSimple } from 'phosphor-react'
import { Header } from '../components/Header/Header'
import { Heading, HeadingProps } from '~/components/Text/Heading'
import { Copy, CopyProps } from '~/components/Text/Copy'
import { List, ListProps } from '~/components/Text/List'
import { Anchor, AnchorProps } from '~/components/Text/Anchor'
import { H } from '~/components/Code/H'
import { MenuDocs } from '~/components/Menu/MenuDocs'
import { MenuSticky } from '~/components/Menu/MenuSticky'
import { StickyAside } from '~/components/Asides/StickyAside'
import { Code } from '~/components/Code/Code'
import { LivePreviewStyles } from '~/components/Code/LivePreviewStyles'
import { Callout } from '~/components/Callout'
import { Feedback } from '~/components/Feedback/Feedback'
import {
flattenNavigationWithChildren,
getNavigations,
} from '~/helpers/navigation'
import { getDocFilePathToGithub } from '~/helpers/links'
import { useIsDarkTheme } from '~/hooks/useIsDarkTheme'
import { WidgetCarbon } from '~/components/Widgets/WidgetCarbon'
import {
h1,
h2,
h3,
h4,
h5,
list,
p,
article,
blockQuote,
editAnchor,
footer,
grid,
main,
mainStickyMenu,
} from '../styles/routes/docs.css'
const comps = {
h1: (props: HeadingProps) => (
,
ol: (props: ListProps) =>
,
a: (props: AnchorProps) =>
{children}
)
},
H,
warning: (props: { children?: ReactNode }) => (