fix(Layout): refactor to sidebar layout component

This commit is contained in:
iCrawl
2022-07-24 18:28:32 +02:00
parent 200ab91f52
commit 41e4e10b48
3 changed files with 23 additions and 18 deletions

View File

@@ -7,6 +7,7 @@ import type { DocInterface } from '~/DocModel/DocInterface';
import type { DocTypeAlias } from '~/DocModel/DocTypeAlias';
import type { DocVariable } from '~/DocModel/DocVariable';
import type { ItemListProps } from '~/components/ItemSidebar';
import { SidebarLayout } from '~/components/SidebarLayout';
import { Class } from '~/components/model/Class';
import { Enum } from '~/components/model/Enum';
import { Function } from '~/components/model/Function';
@@ -106,7 +107,7 @@ export default function Slug(
) {
return props.error ? (
<div className="flex max-w-full h-full bg-white dark:bg-dark">{props.error}</div>
) : props.data?.member ? (
member(props.data.member)
) : null;
) : (
<SidebarLayout {...props}>{props.data?.member ? member(props.data.member) : null}</SidebarLayout>
);
}