The best way to control Claude Code, Codex and more from any computer or phone
Mirrored from https://github.com/Camo67/t3code.git
Synced Nov 21, 04:45 UTC
| 1 | import type { ComponentPropsWithoutRef } from "react"; |
| 2 | |
| 3 | import { cn } from "../lib/utils"; |
| 4 | |
| 5 | export type WorkspacePageWidth = "readable" | "wide" | "expanded"; |
| 6 | |
| 7 | const WIDTH_CLASS: Record<WorkspacePageWidth, string> = { |
| 8 | readable: "max-w-4xl", |
| 9 | wide: "max-w-5xl", |
| 10 | expanded: "max-w-6xl", |
| 11 | }; |
| 12 | |
| 13 | export function WorkspacePageContainer({ |
| 14 | width = "readable", |
| 15 | className, |
| 16 | ...props |
| 17 | }: ComponentPropsWithoutRef<"div"> & { readonly width?: WorkspacePageWidth }) { |
| 18 | return ( |
| 19 | <div |
| 20 | className={cn( |
| 21 | "mx-auto flex w-full flex-col gap-6 px-5 pt-6 pb-12 sm:px-6", |
| 22 | WIDTH_CLASS[width], |
| 23 | className, |
| 24 | )} |
| 25 | {...props} |
| 26 | /> |
| 27 | ); |
| 28 | } |