rippleui-cli 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,19 @@
1
+ import fs from "fs/promises";
2
+ import path from "path";
3
+ const configPath = path.resolve(process.cwd(), "components.json");
4
+ export const readConfig = async () => {
5
+ try {
6
+ const raw = await fs.readFile(configPath, "utf-8");
7
+ return JSON.parse(raw);
8
+ }
9
+ catch { }
10
+ };
11
+ export const writeConfig = async (config) => {
12
+ await fs.writeFile(configPath, JSON.stringify(config, null, 2) + "\n");
13
+ };
14
+ export const requireConfig = (config) => {
15
+ if (!config) {
16
+ console.error('No components.json found. Run "ripple-ui init" first.');
17
+ process.exit(1);
18
+ }
19
+ };
@@ -0,0 +1,149 @@
1
+ import fs from 'fs/promises';
2
+ import { accentThemes, bases } from './themes.js';
3
+ export const updateCss = async (cssPath, baseName, accentName) => {
4
+ const marker = '/* Ripple UI Theme */';
5
+ let existingContent = '';
6
+ try {
7
+ existingContent = await fs.readFile(cssPath, 'utf-8');
8
+ }
9
+ catch { }
10
+ const markerIdx = existingContent.indexOf(marker);
11
+ const userContent = markerIdx !== -1
12
+ ? existingContent.slice(0, markerIdx).trimEnd()
13
+ : existingContent.trimEnd();
14
+ const b = bases[baseName];
15
+ const a = accentThemes[accentName];
16
+ const content = `/* Ripple UI Theme */
17
+ @import "tw-animate-css";
18
+ @import "@fontsource-variable/geist";
19
+
20
+ @custom-variant dark (&:is(.dark *));
21
+
22
+ @theme inline {
23
+ --font-heading: var(--font-sans);
24
+ --font-sans: 'Geist Variable', sans-serif;
25
+ --color-sidebar-ring: var(--sidebar-ring);
26
+ --color-sidebar-border: var(--sidebar-border);
27
+ --color-sidebar-accent-foreground: var(--sidebar-accent-foreground);
28
+ --color-sidebar-accent: var(--sidebar-accent);
29
+ --color-sidebar-primary-foreground: var(--sidebar-primary-foreground);
30
+ --color-sidebar-primary: var(--sidebar-primary);
31
+ --color-sidebar-foreground: var(--sidebar-foreground);
32
+ --color-sidebar: var(--sidebar);
33
+ --color-chart-5: var(--chart-5);
34
+ --color-chart-4: var(--chart-4);
35
+ --color-chart-3: var(--chart-3);
36
+ --color-chart-2: var(--chart-2);
37
+ --color-chart-1: var(--chart-1);
38
+ --color-ring: var(--ring);
39
+ --color-input: var(--input);
40
+ --color-border: var(--border);
41
+ --color-destructive: var(--destructive);
42
+ --color-accent-foreground: var(--accent-foreground);
43
+ --color-accent: var(--accent);
44
+ --color-muted-foreground: var(--muted-foreground);
45
+ --color-muted: var(--muted);
46
+ --color-secondary-foreground: var(--secondary-foreground);
47
+ --color-secondary: var(--secondary);
48
+ --color-primary-foreground: var(--primary-foreground);
49
+ --color-primary: var(--primary);
50
+ --color-popover-foreground: var(--popover-foreground);
51
+ --color-popover: var(--popover);
52
+ --color-card-foreground: var(--card-foreground);
53
+ --color-card: var(--card);
54
+ --color-foreground: var(--foreground);
55
+ --color-background: var(--background);
56
+ --radius-sm: calc(var(--radius) * 0.6);
57
+ --radius-md: calc(var(--radius) * 0.8);
58
+ --radius-lg: var(--radius);
59
+ --radius-xl: calc(var(--radius) * 1.4);
60
+ --radius-2xl: calc(var(--radius) * 1.8);
61
+ --radius-3xl: calc(var(--radius) * 2.2);
62
+ --radius-4xl: calc(var(--radius) * 2.6);
63
+ }
64
+
65
+ :root {
66
+ --background: ${b.root.bg};
67
+ --foreground: ${b.root.fg};
68
+ --card: ${b.root.card.bg};
69
+ --card-foreground: ${b.root.card.fg};
70
+ --popover: ${b.root.popover.bg};
71
+ --popover-foreground: ${b.root.popover.fg};
72
+ --primary: ${a.root.primary.bg};
73
+ --primary-foreground: ${a.root.primary.fg};
74
+ --secondary: ${b.root.secondary.bg};
75
+ --secondary-foreground: ${b.root.secondary.fg};
76
+ --muted: ${b.root.muted.bg};
77
+ --muted-foreground: ${b.root.muted.fg};
78
+ --accent: ${b.root.accent.bg};
79
+ --accent-foreground: ${b.root.accent.fg};
80
+ --destructive: ${b.root.destructive};
81
+ --border: ${b.root.border};
82
+ --input: ${b.root.input};
83
+ --ring: ${b.root.ring};
84
+ --chart-1: ${b.root.charts[0]};
85
+ --chart-2: ${b.root.charts[1]};
86
+ --chart-3: ${b.root.charts[2]};
87
+ --chart-4: ${b.root.charts[3]};
88
+ --chart-5: ${b.root.charts[4]};
89
+ --radius: ${a.radius};
90
+ --sidebar: ${b.root.sidebar.bg};
91
+ --sidebar-foreground: ${b.root.sidebar.fg};
92
+ --sidebar-primary: ${a.root.sidebar.primary.bg};
93
+ --sidebar-primary-foreground: ${a.root.sidebar.primary.fg};
94
+ --sidebar-accent: ${b.root.sidebar.accent.bg};
95
+ --sidebar-accent-foreground: ${b.root.sidebar.accent.fg};
96
+ --sidebar-border: ${b.root.sidebar.border};
97
+ --sidebar-ring: ${b.root.sidebar.ring};
98
+ }
99
+
100
+ .dark {
101
+ --background: ${b.dark.bg};
102
+ --foreground: ${b.dark.fg};
103
+ --card: ${b.dark.card.bg};
104
+ --card-foreground: ${b.dark.card.fg};
105
+ --popover: ${b.dark.popover.bg};
106
+ --popover-foreground: ${b.dark.popover.fg};
107
+ --primary: ${a.dark.primary.bg};
108
+ --primary-foreground: ${a.dark.primary.fg};
109
+ --secondary: ${b.dark.secondary.bg};
110
+ --secondary-foreground: ${b.dark.secondary.fg};
111
+ --muted: ${b.dark.muted.bg};
112
+ --muted-foreground: ${b.dark.muted.fg};
113
+ --accent: ${b.dark.accent.bg};
114
+ --accent-foreground: ${b.dark.accent.fg};
115
+ --destructive: ${b.dark.destructive};
116
+ --border: ${b.dark.border};
117
+ --input: ${b.dark.input};
118
+ --ring: ${b.dark.ring};
119
+ --chart-1: ${b.dark.charts[0]};
120
+ --chart-2: ${b.dark.charts[1]};
121
+ --chart-3: ${b.dark.charts[2]};
122
+ --chart-4: ${b.dark.charts[3]};
123
+ --chart-5: ${b.dark.charts[4]};
124
+ --sidebar: ${b.dark.sidebar.bg};
125
+ --sidebar-foreground: ${b.dark.sidebar.fg};
126
+ --sidebar-primary: ${a.dark.sidebar.primary.bg};
127
+ --sidebar-primary-foreground: ${a.dark.sidebar.primary.fg};
128
+ --sidebar-accent: ${b.dark.sidebar.accent.bg};
129
+ --sidebar-accent-foreground: ${b.dark.sidebar.accent.fg};
130
+ --sidebar-border: ${b.dark.sidebar.border};
131
+ --sidebar-ring: ${b.dark.sidebar.ring};
132
+ }
133
+
134
+ @layer base {
135
+ * {
136
+ @apply border-border outline-ring/50;
137
+ }
138
+ body {
139
+ @apply bg-background text-foreground;
140
+ }
141
+ html {
142
+ @apply font-sans;
143
+ }
144
+ }`;
145
+ const newContent = userContent
146
+ ? `${userContent}\n\n${content}\n`
147
+ : `${content}\n`;
148
+ await fs.writeFile(cssPath, newContent);
149
+ };
@@ -0,0 +1,79 @@
1
+ import fs from "fs/promises";
2
+ import path from "path";
3
+ export const detectPackageManager = async (cwd) => {
4
+ try {
5
+ const raw = await fs.readFile(path.join(cwd, "package.json"), "utf-8");
6
+ const pkg = JSON.parse(raw);
7
+ if (pkg.packageManager) {
8
+ // e.g. "pnpm@10.32.1" → "pnpm"
9
+ return pkg.packageManager.split("@")[0];
10
+ }
11
+ }
12
+ catch { }
13
+ return "npm";
14
+ };
15
+ export const detectTailwind = async (cwd) => {
16
+ try {
17
+ const raw = await fs.readFile(path.join(cwd, "package.json"), "utf-8");
18
+ const pkg = JSON.parse(raw);
19
+ const deps = {
20
+ ...pkg.dependencies,
21
+ ...pkg.devDependencies,
22
+ };
23
+ return "tailwindcss" in deps;
24
+ }
25
+ catch (e) {
26
+ return false;
27
+ }
28
+ };
29
+ export const detectCssFile = async (cwd) => {
30
+ const paths = ["src/index.css", "src/main.css", "src/styles.css"];
31
+ for (const relPath of paths) {
32
+ const fullPath = path.resolve(cwd, relPath);
33
+ try {
34
+ await fs.access(fullPath);
35
+ console.log(`✔ Found main CSS file: ${relPath}`);
36
+ return relPath;
37
+ }
38
+ catch { }
39
+ }
40
+ return null;
41
+ };
42
+ export const detectImportAlias = async (cwd) => {
43
+ const viteConfigNames = [
44
+ "vite.config.ts",
45
+ "vite.config.js",
46
+ "vite.config.mts",
47
+ "vite.config.mjs",
48
+ ];
49
+ for (const configName of viteConfigNames) {
50
+ const fullPath = path.join(cwd, configName);
51
+ try {
52
+ const raw = await fs.readFile(fullPath, "utf-8");
53
+ const objectAliasMatch = raw.match(/alias\s*:\s*\{([^}]+)\}/s);
54
+ if (objectAliasMatch?.[1]) {
55
+ const entryMatch = objectAliasMatch[1].match(/['"]?(@[^'":/\s]+|[^'":/\s]+)['"]?\s*:/);
56
+ if (entryMatch?.[1]) {
57
+ return entryMatch[1];
58
+ }
59
+ }
60
+ const arrayFindMatch = raw.match(/find\s*:\s*['"]([^'"]+)['"]/);
61
+ if (arrayFindMatch?.[1]) {
62
+ return arrayFindMatch[1];
63
+ }
64
+ }
65
+ catch { }
66
+ }
67
+ // Fall back to tsconfig.json
68
+ try {
69
+ const raw = await fs.readFile(path.join(cwd, "tsconfig.json"), "utf-8");
70
+ const tsconfig = JSON.parse(raw);
71
+ const paths = tsconfig.compilerOptions?.paths ?? {};
72
+ for (const alias of Object.keys(paths)) {
73
+ return alias.replace(/\/\*$/, "");
74
+ }
75
+ }
76
+ catch { }
77
+ console.error("No import alias found.");
78
+ process.exit(1);
79
+ };
@@ -0,0 +1,54 @@
1
+ import { execSync } from "child_process";
2
+ import fs from "fs/promises";
3
+ import path from "path";
4
+ import { detectPackageManager } from "./detect.js";
5
+ import { fetchFile, fetchRegistry } from "./registry.js";
6
+ export const resolveTargetDir = (name, entry, config) => {
7
+ // utils
8
+ if (entry.target)
9
+ return config.utilsDir ?? entry.target;
10
+ return `${config.componentsDir}/${name}`;
11
+ };
12
+ export async function installNpmDeps(packages, cwd) {
13
+ if (packages.length === 0)
14
+ return;
15
+ const pm = await detectPackageManager(cwd);
16
+ const cmd = pm === "npm" ? "npm install" : `${pm} add`;
17
+ console.log(`\nInstalling npm packages with ${pm}: ${packages.join(", ")}`);
18
+ execSync(`${cmd} ${packages.join(" ")}`, { cwd, stdio: "inherit" });
19
+ }
20
+ export const installEntry = async (name, config, installed = new Set(), npmDeps = new Set()) => {
21
+ if (installed.has(name))
22
+ return;
23
+ installed.add(name);
24
+ const registry = await fetchRegistry();
25
+ const entry = registry[name];
26
+ if (!entry)
27
+ throw new Error(`"${name}" not found in registry`);
28
+ for (const pkg of entry.npmDependencies ?? []) {
29
+ npmDeps.add(pkg);
30
+ }
31
+ for (const dep of entry.dependencies ?? []) {
32
+ await installEntry(dep, config, installed, npmDeps);
33
+ }
34
+ const targetDir = resolveTargetDir(name, entry, config);
35
+ const targetPath = path.resolve(process.cwd(), targetDir);
36
+ await fs.mkdir(targetPath, { recursive: true });
37
+ await Promise.all(entry.files.map(async (file) => {
38
+ let content = await fetchFile(`${entry.path}/${file}`);
39
+ content = updateImports(content, config);
40
+ const dest = path.resolve(targetPath, file);
41
+ await fs.writeFile(dest, content);
42
+ }));
43
+ console.log(`✔ Installed: ${name} → ${targetPath}`);
44
+ if (npmDeps.size > 0) {
45
+ await installNpmDeps([...npmDeps], process.cwd());
46
+ npmDeps.clear();
47
+ }
48
+ };
49
+ export const updateImports = (content, config) => {
50
+ return content
51
+ .replace(/@\/components/g, config.aliases.components)
52
+ .replace(/@\/lib/g, config.aliases.utils)
53
+ .replace(/@\/utils/g, config.aliases.utils);
54
+ };
@@ -0,0 +1,15 @@
1
+ const GITHUB_RAW = "https://raw.githubusercontent.com/radeqq007/ripple-ui/main";
2
+ const REGISTRY_URL = `${GITHUB_RAW}/registry.json`;
3
+ export const fetchRegistry = async () => {
4
+ const res = await fetch(REGISTRY_URL);
5
+ if (!res.ok)
6
+ throw new Error(`Failed to fetch registry: ${res.statusText}`);
7
+ return res.json();
8
+ };
9
+ export const fetchFile = async (path) => {
10
+ const url = `${GITHUB_RAW}/${path}`;
11
+ const res = await fetch(url);
12
+ if (!res.ok)
13
+ throw new Error(`Failed to fetch file ${path}: ${res.statusText}`);
14
+ return res.text();
15
+ };
@@ -0,0 +1,332 @@
1
+ // ─── Shared types ────────────────────────────────────────────────────────────
2
+ export const bases = {
3
+ stone: {
4
+ root: {
5
+ bg: 'oklch(1 0 0)',
6
+ fg: 'oklch(0.145 0 0)',
7
+ card: { bg: 'oklch(1 0 0)', fg: 'oklch(0.145 0 0)' },
8
+ popover: { bg: 'oklch(1 0 0)', fg: 'oklch(0.145 0 0)' },
9
+ secondary: { bg: 'oklch(0.97 0 0)', fg: 'oklch(0.205 0 0)' },
10
+ muted: { bg: 'oklch(0.97 0 0)', fg: 'oklch(0.556 0 0)' },
11
+ accent: { bg: 'oklch(0.97 0 0)', fg: 'oklch(0.205 0 0)' },
12
+ destructive: 'oklch(0.577 0.245 27.325)',
13
+ border: 'oklch(0.922 0 0)',
14
+ input: 'oklch(0.922 0 0)',
15
+ ring: 'oklch(0.708 0 0)',
16
+ charts: [
17
+ 'oklch(0.87 0 0)',
18
+ 'oklch(0.556 0 0)',
19
+ 'oklch(0.439 0 0)',
20
+ 'oklch(0.371 0 0)',
21
+ 'oklch(0.269 0 0)',
22
+ ],
23
+ sidebar: {
24
+ bg: 'oklch(0.985 0 0)',
25
+ fg: 'oklch(0.145 0 0)',
26
+ accent: { bg: 'oklch(0.97 0 0)', fg: 'oklch(0.205 0 0)' },
27
+ border: 'oklch(0.922 0 0)',
28
+ ring: 'oklch(0.708 0 0)',
29
+ },
30
+ },
31
+ dark: {
32
+ bg: 'oklch(0.145 0 0)',
33
+ fg: 'oklch(0.985 0 0)',
34
+ card: { bg: 'oklch(0.205 0 0)', fg: 'oklch(0.985 0 0)' },
35
+ popover: { bg: 'oklch(0.205 0 0)', fg: 'oklch(0.985 0 0)' },
36
+ secondary: { bg: 'oklch(0.269 0 0)', fg: 'oklch(0.985 0 0)' },
37
+ muted: { bg: 'oklch(0.269 0 0)', fg: 'oklch(0.708 0 0)' },
38
+ accent: { bg: 'oklch(0.269 0 0)', fg: 'oklch(0.985 0 0)' },
39
+ destructive: 'oklch(0.704 0.191 22.216)',
40
+ border: 'oklch(1 0 0 / 10%)',
41
+ input: 'oklch(1 0 0 / 15%)',
42
+ ring: 'oklch(0.556 0 0)',
43
+ charts: [
44
+ 'oklch(0.87 0 0)',
45
+ 'oklch(0.556 0 0)',
46
+ 'oklch(0.439 0 0)',
47
+ 'oklch(0.371 0 0)',
48
+ 'oklch(0.269 0 0)',
49
+ ],
50
+ sidebar: {
51
+ bg: 'oklch(0.205 0 0)',
52
+ fg: 'oklch(0.985 0 0)',
53
+ accent: { bg: 'oklch(0.269 0 0)', fg: 'oklch(0.985 0 0)' },
54
+ border: 'oklch(1 0 0 / 10%)',
55
+ ring: 'oklch(0.556 0 0)',
56
+ },
57
+ },
58
+ },
59
+ zinc: {
60
+ root: {
61
+ bg: 'oklch(1 0 0)',
62
+ fg: 'oklch(0.141 0.005 285.823)',
63
+ card: { bg: 'oklch(1 0 0)', fg: 'oklch(0.141 0.005 285.823)' },
64
+ popover: { bg: 'oklch(1 0 0)', fg: 'oklch(0.141 0.005 285.823)' },
65
+ secondary: {
66
+ bg: 'oklch(0.967 0.001 286.375)',
67
+ fg: 'oklch(0.21 0.006 285.885)',
68
+ },
69
+ muted: {
70
+ bg: 'oklch(0.967 0.001 286.375)',
71
+ fg: 'oklch(0.552 0.016 285.938)',
72
+ },
73
+ accent: {
74
+ bg: 'oklch(0.967 0.001 286.375)',
75
+ fg: 'oklch(0.21 0.006 285.885)',
76
+ },
77
+ destructive: 'oklch(0.577 0.245 27.325)',
78
+ border: 'oklch(0.92 0.004 286.32)',
79
+ input: 'oklch(0.92 0.004 286.32)',
80
+ ring: 'oklch(0.705 0.015 286.067)',
81
+ charts: [
82
+ 'oklch(0.869 0.005 286.286)',
83
+ 'oklch(0.552 0.016 285.938)',
84
+ 'oklch(0.442 0.017 285.786)',
85
+ 'oklch(0.37 0.013 285.805)',
86
+ 'oklch(0.274 0.006 286.033)',
87
+ ],
88
+ sidebar: {
89
+ bg: 'oklch(0.985 0.002 286.067)',
90
+ fg: 'oklch(0.141 0.005 285.823)',
91
+ accent: {
92
+ bg: 'oklch(0.967 0.001 286.375)',
93
+ fg: 'oklch(0.21 0.006 285.885)',
94
+ },
95
+ border: 'oklch(0.92 0.004 286.32)',
96
+ ring: 'oklch(0.705 0.015 286.067)',
97
+ },
98
+ },
99
+ dark: {
100
+ bg: 'oklch(0.141 0.005 285.823)',
101
+ fg: 'oklch(0.985 0 0)',
102
+ card: {
103
+ bg: 'oklch(0.21 0.006 285.885)',
104
+ fg: 'oklch(0.985 0 0)',
105
+ },
106
+ popover: {
107
+ bg: 'oklch(0.21 0.006 285.885)',
108
+ fg: 'oklch(0.985 0 0)',
109
+ },
110
+ secondary: {
111
+ bg: 'oklch(0.274 0.006 286.033)',
112
+ fg: 'oklch(0.985 0 0)',
113
+ },
114
+ muted: {
115
+ bg: 'oklch(0.274 0.006 286.033)',
116
+ fg: 'oklch(0.705 0.015 286.067)',
117
+ },
118
+ accent: {
119
+ bg: 'oklch(0.274 0.006 286.033)',
120
+ fg: 'oklch(0.985 0 0)',
121
+ },
122
+ destructive: 'oklch(0.704 0.191 22.216)',
123
+ border: 'oklch(1 0 0 / 10%)',
124
+ input: 'oklch(1 0 0 / 15%)',
125
+ ring: 'oklch(0.552 0.016 285.938)',
126
+ charts: [
127
+ 'oklch(0.869 0.005 286.286)',
128
+ 'oklch(0.552 0.016 285.938)',
129
+ 'oklch(0.442 0.017 285.786)',
130
+ 'oklch(0.37 0.013 285.805)',
131
+ 'oklch(0.274 0.006 286.033)',
132
+ ],
133
+ sidebar: {
134
+ bg: 'oklch(0.21 0.006 285.885)',
135
+ fg: 'oklch(0.985 0 0)',
136
+ accent: {
137
+ bg: 'oklch(0.274 0.006 286.033)',
138
+ fg: 'oklch(0.985 0 0)',
139
+ },
140
+ border: 'oklch(1 0 0 / 10%)',
141
+ ring: 'oklch(0.552 0.016 285.938)',
142
+ },
143
+ },
144
+ },
145
+ slate: {
146
+ root: {
147
+ bg: 'oklch(1 0 0)',
148
+ fg: 'oklch(0.129 0.042 264.695)',
149
+ card: { bg: 'oklch(1 0 0)', fg: 'oklch(0.129 0.042 264.695)' },
150
+ popover: { bg: 'oklch(1 0 0)', fg: 'oklch(0.129 0.042 264.695)' },
151
+ secondary: {
152
+ bg: 'oklch(0.968 0.007 247.896)',
153
+ fg: 'oklch(0.208 0.042 265.755)',
154
+ },
155
+ muted: {
156
+ bg: 'oklch(0.968 0.007 247.896)',
157
+ fg: 'oklch(0.554 0.046 257.417)',
158
+ },
159
+ accent: {
160
+ bg: 'oklch(0.968 0.007 247.896)',
161
+ fg: 'oklch(0.208 0.042 265.755)',
162
+ },
163
+ destructive: 'oklch(0.577 0.245 27.325)',
164
+ border: 'oklch(0.929 0.013 255.508)',
165
+ input: 'oklch(0.929 0.013 255.508)',
166
+ ring: 'oklch(0.704 0.04 256.788)',
167
+ charts: [
168
+ 'oklch(0.868 0.017 252.894)',
169
+ 'oklch(0.554 0.046 257.417)',
170
+ 'oklch(0.446 0.043 257.281)',
171
+ 'oklch(0.372 0.044 257.287)',
172
+ 'oklch(0.279 0.041 260.031)',
173
+ ],
174
+ sidebar: {
175
+ bg: 'oklch(0.984 0.003 247.858)',
176
+ fg: 'oklch(0.129 0.042 264.695)',
177
+ accent: {
178
+ bg: 'oklch(0.968 0.007 247.896)',
179
+ fg: 'oklch(0.208 0.042 265.755)',
180
+ },
181
+ border: 'oklch(0.929 0.013 255.508)',
182
+ ring: 'oklch(0.704 0.04 256.788)',
183
+ },
184
+ },
185
+ dark: {
186
+ bg: 'oklch(0.129 0.042 264.695)',
187
+ fg: 'oklch(0.984 0.003 247.858)',
188
+ card: {
189
+ bg: 'oklch(0.208 0.042 265.755)',
190
+ fg: 'oklch(0.984 0.003 247.858)',
191
+ },
192
+ popover: {
193
+ bg: 'oklch(0.208 0.042 265.755)',
194
+ fg: 'oklch(0.984 0.003 247.858)',
195
+ },
196
+ secondary: {
197
+ bg: 'oklch(0.279 0.041 260.031)',
198
+ fg: 'oklch(0.984 0.003 247.858)',
199
+ },
200
+ muted: {
201
+ bg: 'oklch(0.279 0.041 260.031)',
202
+ fg: 'oklch(0.704 0.04 256.788)',
203
+ },
204
+ accent: {
205
+ bg: 'oklch(0.279 0.041 260.031)',
206
+ fg: 'oklch(0.984 0.003 247.858)',
207
+ },
208
+ destructive: 'oklch(0.704 0.191 22.216)',
209
+ border: 'oklch(1 0 0 / 10%)',
210
+ input: 'oklch(1 0 0 / 15%)',
211
+ ring: 'oklch(0.554 0.046 257.417)',
212
+ charts: [
213
+ 'oklch(0.868 0.017 252.894)',
214
+ 'oklch(0.554 0.046 257.417)',
215
+ 'oklch(0.446 0.043 257.281)',
216
+ 'oklch(0.372 0.044 257.287)',
217
+ 'oklch(0.279 0.041 260.031)',
218
+ ],
219
+ sidebar: {
220
+ bg: 'oklch(0.208 0.042 265.755)',
221
+ fg: 'oklch(0.984 0.003 247.858)',
222
+ accent: {
223
+ bg: 'oklch(0.279 0.041 260.031)',
224
+ fg: 'oklch(0.984 0.003 247.858)',
225
+ },
226
+ border: 'oklch(1 0 0 / 10%)',
227
+ ring: 'oklch(0.554 0.046 257.417)',
228
+ },
229
+ },
230
+ },
231
+ };
232
+ export const accentThemes = {
233
+ neutral: {
234
+ radius: '0.625rem',
235
+ root: {
236
+ primary: { bg: 'oklch(0.205 0 0)', fg: 'oklch(0.986 0 0)' },
237
+ sidebar: {
238
+ primary: { bg: 'oklch(0.205 0 0)', fg: 'oklch(0.985 0 0)' },
239
+ },
240
+ },
241
+ dark: {
242
+ primary: { bg: 'oklch(0.922 0 0)', fg: 'oklch(0.205 0 0)' },
243
+ sidebar: {
244
+ primary: { bg: 'oklch(0.488 0.243 264.376)', fg: 'oklch(0.985 0 0)' },
245
+ },
246
+ },
247
+ },
248
+ blue: {
249
+ radius: '0.5rem',
250
+ root: {
251
+ primary: { bg: 'oklch(0.546 0.245 262.881)', fg: 'oklch(0.985 0 0)' },
252
+ sidebar: {
253
+ primary: {
254
+ bg: 'oklch(0.546 0.245 262.881)',
255
+ fg: 'oklch(0.985 0 0)',
256
+ },
257
+ },
258
+ },
259
+ dark: {
260
+ primary: { bg: 'oklch(0.623 0.214 259.815)', fg: 'oklch(0.985 0 0)' },
261
+ sidebar: {
262
+ primary: {
263
+ bg: 'oklch(0.623 0.214 259.815)',
264
+ fg: 'oklch(0.985 0 0)',
265
+ },
266
+ },
267
+ },
268
+ },
269
+ violet: {
270
+ radius: '0.75rem',
271
+ root: {
272
+ primary: { bg: 'oklch(0.541 0.281 293.009)', fg: 'oklch(0.985 0 0)' },
273
+ sidebar: {
274
+ primary: {
275
+ bg: 'oklch(0.541 0.281 293.009)',
276
+ fg: 'oklch(0.985 0 0)',
277
+ },
278
+ },
279
+ },
280
+ dark: {
281
+ primary: { bg: 'oklch(0.606 0.25 292.717)', fg: 'oklch(0.985 0 0)' },
282
+ sidebar: {
283
+ primary: {
284
+ bg: 'oklch(0.606 0.25 292.717)',
285
+ fg: 'oklch(0.985 0 0)',
286
+ },
287
+ },
288
+ },
289
+ },
290
+ rose: {
291
+ radius: '0.5rem',
292
+ root: {
293
+ primary: { bg: 'oklch(0.586 0.253 17.585)', fg: 'oklch(0.985 0 0)' },
294
+ sidebar: {
295
+ primary: {
296
+ bg: 'oklch(0.586 0.253 17.585)',
297
+ fg: 'oklch(0.985 0 0)',
298
+ },
299
+ },
300
+ },
301
+ dark: {
302
+ primary: { bg: 'oklch(0.645 0.246 16.439)', fg: 'oklch(0.985 0 0)' },
303
+ sidebar: {
304
+ primary: {
305
+ bg: 'oklch(0.645 0.246 16.439)',
306
+ fg: 'oklch(0.985 0 0)',
307
+ },
308
+ },
309
+ },
310
+ },
311
+ orange: {
312
+ radius: '0.625rem',
313
+ root: {
314
+ primary: { bg: 'oklch(0.646 0.222 41.116)', fg: 'oklch(0.985 0 0)' },
315
+ sidebar: {
316
+ primary: {
317
+ bg: 'oklch(0.646 0.222 41.116)',
318
+ fg: 'oklch(0.985 0 0)',
319
+ },
320
+ },
321
+ },
322
+ dark: {
323
+ primary: { bg: 'oklch(0.702 0.191 42.842)', fg: 'oklch(0.985 0 0)' },
324
+ sidebar: {
325
+ primary: {
326
+ bg: 'oklch(0.702 0.191 42.842)',
327
+ fg: 'oklch(0.985 0 0)',
328
+ },
329
+ },
330
+ },
331
+ },
332
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "rippleui-cli",
3
- "version": "0.1.1",
3
+ "version": "0.1.2",
4
4
  "description": "shadcn/ui inspired components library for Ripple TS",
5
5
  "type": "module",
6
6
  "scripts": {