Files
medusa-store/www/apps/user-guide/app/layout.tsx
Shahed Nasser 0a37675f0e docs: add routing page (#9550)
- Add a new homepage to `book` project for the routing page
- Move all main doc pages to be under `/v2/learn` (and added redirects + fixed links across docs)
- Other: add admin components to resources dropdown + fixes to search on mobile.

Closes DX-955

Preview: https://docs-v2-git-docs-router-page-medusajs.vercel.app/v2
2024-10-18 08:24:34 +00:00

53 lines
1.3 KiB
TypeScript

import type { Metadata } from "next"
import { Inter, Roboto_Mono } from "next/font/google"
import Providers from "@/providers"
import "../css/globals.css"
import { BareboneLayout, TightLayout } from "docs-ui"
import { config } from "@/config"
import clsx from "clsx"
import Feedback from "../components/Feedback"
import EditButton from "../components/EditButton"
export const metadata: Metadata = {
title: {
template: `%s - ${config.titleSuffix}`,
default: config.titleSuffix || "",
},
description: "Explore and learn how to use the Medusa Admin.",
metadataBase: new URL(
process.env.NEXT_PUBLIC_BASE_URL || "http://localhost:3000"
),
}
export const inter = Inter({
subsets: ["latin"],
variable: "--font-inter",
weight: ["400", "500"],
})
export const robotoMono = Roboto_Mono({
subsets: ["latin"],
variable: "--font-roboto-mono",
})
export default function RootLayout({
children,
}: {
children: React.ReactNode
}) {
return (
<BareboneLayout htmlClassName={clsx(inter.variable, robotoMono.variable)}>
<TightLayout
sidebarProps={{
expandItems: true,
}}
ProvidersComponent={Providers}
>
{children}
<Feedback className="my-2" />
<EditButton />
</TightLayout>
</BareboneLayout>
)
}