mirror of
https://github.com/hanzoai/shadcn.git
synced 2026-10-30 18:22:59 +00:00
Upstream sync from shadcn-ui/ui (1686 commits since last merge base). Key changes: - packages/shadcn upgraded to 4.1.0 (CLI font transformers, scaffold from github, chart colors) - apps/v4 replaces apps/www as the primary docs/registry app - Font system: 25+ heading font registries, font markers utility, @supports override - Chart improvements: recharts v3 compat, radial chart fixes - templates/ updated with monorepo variants (astro, vite, react-router, start) - skills/shadcn AI skill definitions added - deprecated/ removed (auth, auth-firebase, cli, www) Preserved Hanzo-only paths: app/, pkg/, demo/, docs/, template/next/
149 lines
3.2 KiB
JavaScript
149 lines
3.2 KiB
JavaScript
import path from "path"
|
|
import { createMDX } from "fumadocs-mdx/next"
|
|
|
|
/** @type {import('next').NextConfig} */
|
|
const nextConfig = {
|
|
devIndicators: false,
|
|
typescript: {
|
|
ignoreBuildErrors: true,
|
|
},
|
|
outputFileTracingIncludes: {
|
|
"/*": ["./registry/**/*"],
|
|
},
|
|
images: {
|
|
remotePatterns: [
|
|
{
|
|
protocol: "https",
|
|
hostname: "avatars.githubusercontent.com",
|
|
},
|
|
{
|
|
protocol: "https",
|
|
hostname: "images.unsplash.com",
|
|
},
|
|
{
|
|
protocol: "https",
|
|
hostname: "avatar.vercel.sh",
|
|
},
|
|
],
|
|
},
|
|
turbopack: {
|
|
root: path.resolve(import.meta.dirname, "../.."),
|
|
},
|
|
experimental: {
|
|
turbopackFileSystemCacheForDev: true,
|
|
},
|
|
redirects() {
|
|
return [
|
|
// Form redirects to /docs/forms.
|
|
{
|
|
source: "/docs/components/form",
|
|
destination: "/docs/forms",
|
|
permanent: true,
|
|
},
|
|
{
|
|
source: "/docs/components/radix/form",
|
|
destination: "/docs/forms",
|
|
permanent: true,
|
|
},
|
|
{
|
|
source: "/docs/components/base/form",
|
|
destination: "/docs/forms",
|
|
permanent: true,
|
|
},
|
|
// Component redirects (default to radix).
|
|
{
|
|
source: "/docs/components/:name((?!radix|base|form)[^/]+)",
|
|
destination: "/docs/components/radix/:name",
|
|
permanent: false,
|
|
},
|
|
{
|
|
source: "/docs/components/:name((?!radix|base|form)[^/]+).md",
|
|
destination: "/docs/components/radix/:name.md",
|
|
permanent: false,
|
|
},
|
|
// Other redirects.
|
|
{
|
|
source: "/components",
|
|
destination: "/docs/components",
|
|
permanent: true,
|
|
},
|
|
{
|
|
source: "/docs/primitives/:path*",
|
|
destination: "/docs/components/:path*",
|
|
permanent: true,
|
|
},
|
|
{
|
|
source: "/figma",
|
|
destination: "/docs/figma",
|
|
permanent: true,
|
|
},
|
|
{
|
|
source: "/sidebar",
|
|
destination: "/docs/components/sidebar",
|
|
permanent: true,
|
|
},
|
|
{
|
|
source: "/react-19",
|
|
destination: "/docs/react-19",
|
|
permanent: true,
|
|
},
|
|
{
|
|
source: "/charts",
|
|
destination: "/charts/area",
|
|
permanent: true,
|
|
},
|
|
{
|
|
source: "/view/styles/:style/:name",
|
|
destination: "/view/:name",
|
|
permanent: true,
|
|
},
|
|
{
|
|
source: "/docs/:path*.mdx",
|
|
destination: "/docs/:path*.md",
|
|
permanent: true,
|
|
},
|
|
{
|
|
source: "/mcp",
|
|
destination: "/docs/mcp",
|
|
permanent: false,
|
|
},
|
|
{
|
|
source: "/directory",
|
|
destination: "/docs/directory",
|
|
permanent: false,
|
|
},
|
|
{
|
|
source: "/new",
|
|
destination: "/docs/new",
|
|
permanent: false,
|
|
},
|
|
{
|
|
source: "/skills",
|
|
destination: "/docs/skills",
|
|
permanent: true,
|
|
},
|
|
{
|
|
source: "/cli",
|
|
destination: "/docs/cli",
|
|
permanent: true,
|
|
},
|
|
]
|
|
},
|
|
rewrites() {
|
|
return [
|
|
{
|
|
source: "/docs/:path*.md",
|
|
destination: "/llm/:path*",
|
|
},
|
|
{
|
|
source: "/init.md",
|
|
destination: "/init/md",
|
|
},
|
|
]
|
|
},
|
|
}
|
|
|
|
const withMDX = createMDX({})
|
|
|
|
export default withMDX(nextConfig)
|