mirror of
https://github.com/shadcn-ui/ui.git
synced 2026-07-09 06:55:07 +00:00
78 lines
2.7 KiB
TypeScript
78 lines
2.7 KiB
TypeScript
import Image from "next/image"
|
|
import Link from "next/link"
|
|
import { ChevronRight } from "lucide-react"
|
|
|
|
import { siteConfig } from "@/config/site"
|
|
import { cn } from "@/lib/utils"
|
|
import { buttonVariants } from "@/components/ui/button"
|
|
import { Separator } from "@/components/ui/separator"
|
|
import { ExamplesNav } from "@/components/examples-nav"
|
|
import { Icons } from "@/components/icons"
|
|
import {
|
|
PageHeader,
|
|
PageHeaderDescription,
|
|
PageHeaderHeading,
|
|
} from "@/components/page-header"
|
|
import { PromoVideo } from "@/components/promo-video"
|
|
import { StyleSwitcher } from "@/components/style-switcher"
|
|
import DashboardPage from "@/app/examples/dashboard/page"
|
|
|
|
export default function IndexPage() {
|
|
return (
|
|
<div className="container relative pb-10">
|
|
<StyleSwitcher />
|
|
<PageHeader>
|
|
<Link
|
|
href="/docs/components/data-table"
|
|
className="inline-flex items-center rounded-lg bg-muted px-3 py-1 text-sm font-medium"
|
|
>
|
|
🎉 <Separator className="mx-2 h-4" orientation="vertical" />{" "}
|
|
Introducing Table and Data Table{" "}
|
|
<ChevronRight className="ml-1 h-4 w-4" />
|
|
</Link>
|
|
<PageHeaderHeading>Build your component library.</PageHeaderHeading>
|
|
<PageHeaderDescription>
|
|
Beautifully designed components that you can copy and paste into your
|
|
apps. Accessible. Customizable. Open Source.
|
|
</PageHeaderDescription>
|
|
<div className="flex w-full items-center space-x-4 pb-8 pt-4 md:pb-10">
|
|
<Link href="/docs" className={cn(buttonVariants())}>
|
|
Get Started
|
|
</Link>
|
|
<Link
|
|
target="_blank"
|
|
rel="noreferrer"
|
|
href={siteConfig.links.github}
|
|
className={cn(buttonVariants({ variant: "outline" }))}
|
|
>
|
|
<Icons.gitHub className="mr-2 h-4 w-4" />
|
|
GitHub
|
|
</Link>
|
|
</div>
|
|
</PageHeader>
|
|
<ExamplesNav className="[&>a:first-child]:text-primary" />
|
|
<section className="space-y-8 overflow-hidden rounded-lg border-2 border-primary dark:border-muted md:hidden">
|
|
<Image
|
|
src="/examples/dashboard-light.png"
|
|
width={1280}
|
|
height={866}
|
|
alt="Dashboard"
|
|
className="block dark:hidden"
|
|
/>
|
|
<Image
|
|
src="/examples/dashboard-dark.png"
|
|
width={1280}
|
|
height={866}
|
|
alt="Dashboard"
|
|
className="hidden dark:block"
|
|
/>
|
|
</section>
|
|
<section className="hidden md:block">
|
|
<div className="overflow-hidden rounded-lg border bg-background shadow-xl">
|
|
<DashboardPage />
|
|
</div>
|
|
</section>
|
|
</div>
|
|
)
|
|
}
|