Skip to content
Source
Sign inSign up
fuko/trytanstackdb-v2
Open History to see the last commit

guide-panel.tsx

35 lines1.0 KB

1import { ThemeToggle } from "@/components/theme/theme-toggle";
2​
3import { DevSectionPicker } from "./dev-section-picker";
4import { GuideDocument } from "./guide-document";
5​
6export function GuidePanel() {
7 return (
8 <div className="@container/guide flex h-full min-h-0 flex-col">
9 <div className="flex h-12 shrink-0 items-center gap-2 border-b px-3 @md/guide:px-4">
10 <TanStackDbMark />
11 <span className="hidden truncate text-sm font-semibold tracking-tight @md/guide:inline">
12 Try TanStack DB
13 </span>
14 <div className="ml-auto flex min-w-0 items-center gap-2">
15 {import.meta.env.DEV && <DevSectionPicker />}
16 <ThemeToggle />
17 </div>
18 </div>
19 <div className="min-h-0 flex-1 overflow-y-auto overscroll-contain">
20 <GuideDocument />
21 </div>
22 </div>
23 );
25​
26function TanStackDbMark() {
27 return (
28 <span
29 aria-hidden
30 className="grid size-6 place-items-center rounded-md bg-guide-accent text-[11px] font-black text-white"
31 >
32 DB
33 </span>
34 );