Skip to content

Commit

Permalink
sidebar (wip)
Browse files Browse the repository at this point in the history
  • Loading branch information
a-hariti committed Jun 10, 2024
1 parent fcdcd6f commit 469d3cd
Show file tree
Hide file tree
Showing 3 changed files with 561 additions and 2 deletions.
3 changes: 3 additions & 0 deletions src/components/docPage/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import {CodeContextProvider} from '../codeContext';
import {GitHubCTA} from '../githubCTA';
import {Header} from '../header';
import {PlatformSdkDetail} from '../platformSdkDetail';
import {Sidebar} from '../sidebar';
import {TableOfContents} from '../tableOfContents';

type Props = {
Expand All @@ -29,6 +30,7 @@ export function DocPage({
frontMatter,
notoc = false,
fullWidth = false,
sidebar,
}: Props) {
const {rootNode, path} = serverContext();
const currentPlatform = getCurrentPlatform(rootNode, path);
Expand All @@ -50,6 +52,7 @@ export function DocPage({
<Header pathname={pathname} searchPlatforms={searchPlatforms} />

<section className="px-0 flex relative">
{sidebar ?? <Sidebar path={path} />}
<main className="main-content flex w-full mt-[var(--header-height)] flex-1 mx-auto">
<div
className={[
Expand Down
Loading

0 comments on commit 469d3cd

Please sign in to comment.