This commit is contained in:
2026-03-04 17:35:14 +01:00
parent f73b56cdc4
commit db26e26495
113 changed files with 12433 additions and 169 deletions
@@ -0,0 +1,41 @@
import { DetailedHTMLProps, HTMLAttributes } from "react";
import { DocsLinkType } from ".";
import Stack from "../../layout/Stack";
import TWUIDocsLink from "./TWUIDocsLink";
import { twMerge } from "tailwind-merge";
type Props = DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement> & {
DocsLinks: DocsLinkType[];
before?: React.ReactNode;
after?: React.ReactNode;
autoExpandAll?: boolean;
};
export default function TWUIDocsAside({
DocsLinks,
after,
before,
autoExpandAll,
...props
}: Props) {
return (
<aside
{...props}
className={twMerge(
"pb-10 hidden xl:flex sticky top-6",
props.className
)}
>
<Stack>
{before}
{DocsLinks.map((link, index) => (
<TWUIDocsLink
docLink={link}
key={index}
autoExpandAll={autoExpandAll}
/>
))}
{after}
</Stack>
</aside>
);
}