diff --git a/apps/www/app/(app)/themes/layout.tsx b/apps/www/app/(app)/themes/layout.tsx
index cbb27a03dd..e2763d3385 100644
--- a/apps/www/app/(app)/themes/layout.tsx
+++ b/apps/www/app/(app)/themes/layout.tsx
@@ -7,7 +7,8 @@ import {
PageHeaderDescription,
PageHeaderHeading,
} from "@/components/page-header"
-import { ThemeCustomizer } from "@/components/theme-customizer"
+import { Customizer } from "@/components/theme-customizer"
+import { Button } from "@/registry/new-york/ui/button"
const title = "Add colors. Make it yours."
const description =
@@ -48,10 +49,17 @@ export default function ThemesLayout({
-
- @layer base {
- :root {
-
- --background:{" "}
- {activeTheme?.cssVars.light["background"]};
-
-
- --foreground:{" "}
- {activeTheme?.cssVars.light["foreground"]};
-
- {[
- "card",
- "popover",
- "primary",
- "secondary",
- "muted",
- "accent",
- "destructive",
- ].map((prefix) => (
- <>
-
- --{prefix}:{" "}
- {
- activeTheme?.cssVars.light[
- prefix as keyof typeof activeTheme.cssVars.light
- ]
- }
- ;
-
-
- --{prefix}-foreground:{" "}
- {
- activeTheme?.cssVars.light[
- `${prefix}-foreground` as keyof typeof activeTheme.cssVars.light
- ]
- }
- ;
-
- >
- ))}
-
- --border:{" "}
- {activeTheme?.cssVars.light["border"]};
-
-
- --input:{" "}
- {activeTheme?.cssVars.light["input"]};
-
-
- --ring:{" "}
- {activeTheme?.cssVars.light["ring"]};
-
-
- --radius: {config.radius}rem;
-
- {["chart-1", "chart-2", "chart-3", "chart-4", "chart-5"].map(
- (prefix) => (
- <>
-
- --{prefix}:{" "}
- {
- activeTheme?.cssVars.light[
- prefix as keyof typeof activeTheme.cssVars.light
- ]
- }
- ;
-
- >
+
+
+
+ Tailwind v4
+ v3
+
+ {
+ copyToClipboardWithMeta(
+ themeVersion === "v3"
+ ? getThemeCode(activeTheme, config.radius)
+ : getThemeCodeOKLCH(activeThemeOKLCH, config.radius),
+ {
+ name: "copy_theme_code",
+ properties: {
+ theme: config.theme,
+ radius: config.radius,
+ },
+ }
)
- )}
- }
-
- .dark {
-
- --background:{" "}
- {activeTheme?.cssVars.dark["background"]};
-
-
- --foreground:{" "}
- {activeTheme?.cssVars.dark["foreground"]};
-
- {[
- "card",
- "popover",
- "primary",
- "secondary",
- "muted",
- "accent",
- "destructive",
- ].map((prefix) => (
- <>
+ setHasCopied(true)
+ }}
+ className="absolute right-0 top-0 shadow-none"
+ >
+ {hasCopied ? : }
+ Copy
+
+
+
+
+
+
+ :root {
- --{prefix}:{" "}
- {
- activeTheme?.cssVars.dark[
- prefix as keyof typeof activeTheme.cssVars.dark
- ]
- }
- ;
+ --radius: {config.radius}rem;
-
- --{prefix}-foreground:{" "}
- {
- activeTheme?.cssVars.dark[
- `${prefix}-foreground` as keyof typeof activeTheme.cssVars.dark
- ]
- }
- ;
-
- >
- ))}
-
- --border:{" "}
- {activeTheme?.cssVars.dark["border"]};
-
-
- --input:{" "}
- {activeTheme?.cssVars.dark["input"]};
-
-
- --ring:{" "}
- {activeTheme?.cssVars.dark["ring"]};
-
- {["chart-1", "chart-2", "chart-3", "chart-4", "chart-5"].map(
- (prefix) => (
- <>
-
- --{prefix}:{" "}
- {
- activeTheme?.cssVars.dark[
- prefix as keyof typeof activeTheme.cssVars.dark
- ]
- }
- ;
+ {Object.entries(activeThemeOKLCH?.light).map(([key, value]) => (
+
+ --{key}: {value};
- >
- )
- )}
- }
- }
-
-
-
+ ))}
+ }
+
+ .dark {
+ {Object.entries(activeThemeOKLCH?.dark).map(([key, value]) => (
+
+ --{key}: {value};
+
+ ))}
+ }
+
+
+
+
+ @layer base {
+
+ :root {
+
+
+ --background:{" "}
+ {activeTheme?.cssVars.light["background"]};
+
+
+ --foreground:{" "}
+ {activeTheme?.cssVars.light["foreground"]};
+
+ {[
+ "card",
+ "popover",
+ "primary",
+ "secondary",
+ "muted",
+ "accent",
+ "destructive",
+ ].map((prefix) => (
+ <>
+
+ --{prefix}:{" "}
+ {
+ activeTheme?.cssVars.light[
+ prefix as keyof typeof activeTheme.cssVars.light
+ ]
+ }
+ ;
+
+
+ --{prefix}-foreground:{" "}
+ {
+ activeTheme?.cssVars.light[
+ `${prefix}-foreground` as keyof typeof activeTheme.cssVars.light
+ ]
+ }
+ ;
+
+ >
+ ))}
+
+ --border:{" "}
+ {activeTheme?.cssVars.light["border"]};
+
+
+ --input:{" "}
+ {activeTheme?.cssVars.light["input"]};
+
+
+ --ring:{" "}
+ {activeTheme?.cssVars.light["ring"]};
+
+
+ --radius: {config.radius}rem;
+
+ {["chart-1", "chart-2", "chart-3", "chart-4", "chart-5"].map(
+ (prefix) => (
+ <>
+
+ --{prefix}:{" "}
+ {
+ activeTheme?.cssVars.light[
+ prefix as keyof typeof activeTheme.cssVars.light
+ ]
+ }
+ ;
+
+ >
+ )
+ )}
+ }
+
+
+ .dark {
+
+
+ --background:{" "}
+ {activeTheme?.cssVars.dark["background"]};
+
+
+ --foreground:{" "}
+ {activeTheme?.cssVars.dark["foreground"]};
+
+ {[
+ "card",
+ "popover",
+ "primary",
+ "secondary",
+ "muted",
+ "accent",
+ "destructive",
+ ].map((prefix) => (
+ <>
+
+ --{prefix}:{" "}
+ {
+ activeTheme?.cssVars.dark[
+ prefix as keyof typeof activeTheme.cssVars.dark
+ ]
+ }
+ ;
+
+
+ --{prefix}-foreground:{" "}
+ {
+ activeTheme?.cssVars.dark[
+ `${prefix}-foreground` as keyof typeof activeTheme.cssVars.dark
+ ]
+ }
+ ;
+
+ >
+ ))}
+
+ --border:{" "}
+ {activeTheme?.cssVars.dark["border"]};
+
+
+ --input:{" "}
+ {activeTheme?.cssVars.dark["input"]};
+
+
+ --ring:{" "}
+ {activeTheme?.cssVars.dark["ring"]};
+
+ {["chart-1", "chart-2", "chart-3", "chart-4", "chart-5"].map(
+ (prefix) => (
+ <>
+
+ --{prefix}:{" "}
+ {
+ activeTheme?.cssVars.dark[
+ prefix as keyof typeof activeTheme.cssVars.dark
+ ]
+ }
+ ;
+
+ >
+ )
+ )}
+ }
+ }
+
+
+