feat: add Checkbox docs in route

This commit is contained in:
p-sw 2024-06-02 03:24:24 +09:00
parent efac10d91b
commit d48a31c170

View File

@ -14,6 +14,7 @@ import DocsIntroduction from "./docs/docs/introduction.mdx";
import DocsInstallation from "./docs/docs/installation.mdx"; import DocsInstallation from "./docs/docs/installation.mdx";
import ComponentsButton from "./docs/components/Button.mdx"; import ComponentsButton from "./docs/components/Button.mdx";
import ComponentsCheckbox from "./docs/components/Checkbox.mdx";
const overrideComponents = { const overrideComponents = {
pre: (props: any) => <pre {...props} className={`${props.className} hljs`} />, pre: (props: any) => <pre {...props} className={`${props.className} hljs`} />,
@ -34,7 +35,7 @@ const router = createBrowserRouter(
createRoutesFromElements( createRoutesFromElements(
<Route path="/" element={<MainLayout />} errorElement={<ErrorBoundary />}> <Route path="/" element={<MainLayout />} errorElement={<ErrorBoundary />}>
<Route index element={<Home />} /> <Route index element={<Home />} />
<Route path="/docs" element={<DocsLayout />}> <Route path="docs" element={<DocsLayout />}>
<Route index element={<DocsIntroduction />} /> <Route index element={<DocsIntroduction />} />
<Route path="installation" element={<DocsInstallation />} /> <Route path="installation" element={<DocsInstallation />} />
<Route path="components"> <Route path="components">
@ -43,6 +44,10 @@ const router = createBrowserRouter(
path="button" path="button"
element={<ComponentsButton components={overrideComponents} />} element={<ComponentsButton components={overrideComponents} />}
/> />
<Route
path="checkbox"
element={<ComponentsCheckbox components={overrideComponents} />}
/>
</Route> </Route>
</Route> </Route>
</Route> </Route>