untitledui 0.1.7 → 0.1.8
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.
- package/config/styles/globals.css +0 -25
- package/config/styles/theme.css +1 -9
- package/dist/index.mjs +54 -16
- package/package.json +2 -1
|
@@ -5,23 +5,6 @@
|
|
|
5
5
|
@plugin "@tailwindcss/typography";
|
|
6
6
|
@plugin "tailwindcss-react-aria-components";
|
|
7
7
|
@plugin "tailwindcss-animate";
|
|
8
|
-
/*
|
|
9
|
-
The default border color has changed to `currentColor` in Tailwind CSS v4,
|
|
10
|
-
so we've added these compatibility styles to make sure everything still
|
|
11
|
-
looks the same as it did with Tailwind CSS v3.
|
|
12
|
-
|
|
13
|
-
If we ever want to remove these styles, we need to add an explicit border
|
|
14
|
-
color utility to any element that depends on these defaults.
|
|
15
|
-
*/
|
|
16
|
-
@layer base {
|
|
17
|
-
*,
|
|
18
|
-
::after,
|
|
19
|
-
::before,
|
|
20
|
-
::backdrop,
|
|
21
|
-
::file-selector-button {
|
|
22
|
-
border-color: var(--color-gray-200, currentColor);
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
8
|
|
|
26
9
|
@custom-variant dark (&:where(.dark-mode, .dark-mode *));
|
|
27
10
|
@custom-variant label (& [data-label]);
|
|
@@ -39,14 +22,6 @@
|
|
|
39
22
|
scrollbar-width: none; /* Firefox */
|
|
40
23
|
}
|
|
41
24
|
|
|
42
|
-
@utility animation-duration-150 {
|
|
43
|
-
animation-duration: 150ms;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
@utility animation-duration-300 {
|
|
47
|
-
animation-duration: 300ms;
|
|
48
|
-
}
|
|
49
|
-
|
|
50
25
|
@utility transition-inherit-all {
|
|
51
26
|
transition-property: inherit;
|
|
52
27
|
transition-duration: inherit;
|
package/config/styles/theme.css
CHANGED
|
@@ -789,10 +789,6 @@
|
|
|
789
789
|
--color-focus-ring: var(--color-brand-500);
|
|
790
790
|
--color-footer-button-fg: var(--color-brand-200);
|
|
791
791
|
--color-footer-button-fg_hover: var(--color-white);
|
|
792
|
-
--color-header-abstract-100-bg: var(--color-brand-100);
|
|
793
|
-
--color-header-abstract-200-bg: var(--color-brand-200);
|
|
794
|
-
--color-header-abstract-300-bg: var(--color-brand-300);
|
|
795
|
-
--color-header-abstract-50-bg: var(--color-brand-50);
|
|
796
792
|
--color-icon-fg-brand: var(--color-brand-600);
|
|
797
793
|
--color-icon-fg-brand_on-brand: var(--color-brand-200);
|
|
798
794
|
/* THESE NEED TO BE REMOED */
|
|
@@ -1128,7 +1124,7 @@
|
|
|
1128
1124
|
--color-border-disabled_subtle: var(--color-gray-dark-mode-800);
|
|
1129
1125
|
--color-border-tertiary: var(--color-gray-dark-mode-800);
|
|
1130
1126
|
--color-border-brand_alt: var(--color-gray-dark-mode-700);
|
|
1131
|
-
--color-border-secondary_alt: var(--color-gray-dark-mode-
|
|
1127
|
+
--color-border-secondary_alt: var(--color-gray-dark-mode-800);
|
|
1132
1128
|
|
|
1133
1129
|
/* FOREGROUND COLORS */
|
|
1134
1130
|
--color-fg-secondary: var(--color-gray-dark-mode-300);
|
|
@@ -1205,10 +1201,6 @@
|
|
|
1205
1201
|
--color-focus-ring: var(--color-brand-500);
|
|
1206
1202
|
--color-footer-button-fg: var(--color-gray-dark-mode-300);
|
|
1207
1203
|
--color-footer-button-fg_hover: var(--color-gray-dark-mode-100);
|
|
1208
|
-
--color-header-abstract-100-bg: var(--color-gray-dark-mode-800);
|
|
1209
|
-
--color-header-abstract-200-bg: var(--color-gray-dark-mode-700);
|
|
1210
|
-
--color-header-abstract-300-bg: var(--color-gray-dark-mode-600);
|
|
1211
|
-
--color-header-abstract-50-bg: var(--color-gray-dark-mode-900);
|
|
1212
1204
|
--color-icon-fg-brand: var(--color-gray-dark-mode-400);
|
|
1213
1205
|
--color-icon-fg-brand_on-brand: var(--color-gray-dark-mode-400);
|
|
1214
1206
|
--color-nav-item-button-icon-fg: var(--color-gray-dark-mode-400);
|
package/dist/index.mjs
CHANGED
|
@@ -1,20 +1,58 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{Command as
|
|
3
|
-
`),process.exit(1)},
|
|
4
|
-
Failed to add the component ${
|
|
5
|
-
Following files already exist in the directory.`),
|
|
6
|
-
|
|
7
|
-
|
|
2
|
+
import{Command as k3}from"commander";import C0 from"async-retry";import N from"chalk";import{Command as o0,Option as t0}from"commander";import{execa as $0}from"execa";import*as S from"fs";import z0 from"ora";import e0 from"os";import*as w from"path";import X0 from"prompts";import{Project as z3}from"ts-morph";import f0 from"node-fetch";import{Readable as g3,pipeline as m0}from"stream";import{x as h3}from"tar";import{promisify as c0}from"util";var m3=c0(m0);async function a(B){let z=`https://untitledui-docs.vercel.app/api/validate-key?key=${B}`;try{return(await f0(z)).status===200}catch{return!1}}import l0 from"node-fetch";async function K0(B,z,Q){try{return await(await l0("https://untitledui-docs.vercel.app/api/components",{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({type:B,components:z,key:Q})})).json()}catch(Y){return console.error(Y),null}}import w0 from"node-fetch";async function u0(B,z=""){let Q=`https://untitledui-docs.vercel.app/api/components/list?key=${z}&type=${B}`;try{let Y=await(await w0(Q)).json();if(!Y?.components?.length)return null;return Y}catch(X){return console.error(X),null}}async function T0(B=""){let z=`https://untitledui-docs.vercel.app/api/components/list?key=${B}`;try{let X=await(await w0(z)).json();if(!X?.types?.length)return null;return X}catch(Q){return console.error(Q),null}}import i0 from"fast-glob";import*as b0 from"path";import{Project as W1}from"ts-morph";import{loadConfig as p0}from"tsconfig-paths";import i3 from"prettier";import Z0 from"fast-glob";import*as W0 from"fs";import*as Y0 from"path";import{loadConfig as s0}from"tsconfig-paths";var h=["**/node_modules/**",".next","public","dist","build"],y0={"next-app":"Next.js (App)","next-pages":"Next.js (Pages)",vite:"Vite",other:"Other"};async function n(B){let z=W0.existsSync(Y0.resolve(B,"src")),Q=W0.existsSync(Y0.resolve(B,`${z?"src/":""}app`)),[X,Y,V,v]=await Promise.all([Z0.glob("**/{next,vite,astro}.config.*|gatsby-config.*",{cwd:B,deep:2,ignore:h}),a0(B),n0(B),r0(B)]),M={framework:"other",isTsx:Y,tailwindFile:V||null,aliasPrefix:v,isSrcDir:z,isUsingAppDir:Q};if(X.find((L)=>L.startsWith("next.config."))?.length)return M.framework=Q?"next-app":"next-pages",M;else if(X.find((L)=>L.startsWith("vite.config."))?.length)return M.framework="vite",M;else if(X?.length||W0.existsSync(Y0.resolve(B,"package.json")))return M.framework="other",M;return null}async function a0(B){return(await Z0.glob("tsconfig.*",{cwd:B,deep:2,ignore:h})).length>0}async function n0(B){let z=await Z0.glob("tailwind.config.*",{cwd:B,deep:2,ignore:h});if(!z.length)return null;return z[0]}async function r0(B){let z=await s0(B);if(z?.resultType==="failed"||!Object.keys(z.paths).length)return null;let Q={};for(let[X,Y]of Object.entries(z.paths)){let V=X.replace(/\/\*$/,"/");if(Y.some((v)=>v.includes("/app/*")))Q.appPrefix=V;else if(Y.some((v)=>v.includes("/components/*")))Q.componentsPrefix=V;else if(Y.some((v)=>v.includes("/utils/*")))Q.utilsPrefix=V;else if(Y.some((v)=>v.includes("/styles/*")))Q.stylesPrefix=V;else if(Y.some((v)=>v.includes("./*")||v.includes("/src/*")))Q.srcPrefix=V}return Q||null}function r(B){let z=p0(B),Q=i0.sync(["tailwind.config.*","**/globals.css","**/{layout,_app,main}.tsx","package.json"],{cwd:B,deep:4,absolute:!0,onlyFiles:!0,ignore:h}),X={tailwindFile:Q.find((Y)=>Y.includes("tailwind.config.")),cssFile:Q.find((Y)=>Y.includes("globals.css")),layoutFile:Q.find((Y)=>Y.includes("layout")),appFile:Q.find((Y)=>Y.includes("_app")),mainFile:Q.find((Y)=>Y.includes("main")),packageJson:Q.find((Y)=>Y.includes("package.json")),tsConfig:z?.resultType==="success"?z?.configFileAbsolutePath:void 0};if(z.resultType==="failed")throw new Error(`Failed to load tsconfig.json. ${z.message??""}`.trim());return X}function i(B,z,Q={},X=""){if(B.includes("components")){if(Q?.componentsPrefix)return B.replace(/@\/components\//,b0.posix.join(Q?.componentsPrefix,z?z.replace(/components\//,""):"","/"));if(z){let Y=Q?.srcPrefix?b0.posix.join(Q?.srcPrefix,z,"/"):X;return B.replace(/@\/components\//,Y)}}if(B.includes("app")&&Q?.appPrefix)return B.replace(/^@\/app\//,Q?.appPrefix);if(B.includes("utils")&&Q?.utilsPrefix)return B.replace(/^@\/utils\//,Q?.utilsPrefix);if(B.includes("styles")&&Q?.stylesPrefix)return B.replace(/^@\/styles\//,Q?.stylesPrefix);if(Q?.srcPrefix)return B.replace(/^@\//,Q?.srcPrefix);return B}function T(){if("bun/1.2.14 npm/? node/v22.6.0 darwin arm64".startsWith("yarn"))return"yarn";if("bun/1.2.14 npm/? node/v22.6.0 darwin arm64".startsWith("pnpm"))return"pnpm";if("bun/1.2.14 npm/? node/v22.6.0 darwin arm64".startsWith("bun"))return"bun";return"npm"}function S0(){switch(T()){case"yarn":return"yarn";case"pnpm":return"pnpx";case"bun":return"bun";default:return"npx"}}var B3=w.join(e0.homedir(),".untitledui"),m=w.join(B3,"config.json"),Z={components:[],path:"",type:void 0,license:""};if(S.existsSync(m)){let B=JSON.parse(S.readFileSync(m,"utf-8"));Z.license=B.license}var L0=(B)=>{if(B.aborted)process.stdout.write("\x1B[?25h"),process.stdout.write(`
|
|
3
|
+
`),process.exit(1)},x0=new o0().name("add").description("add a component to your project").argument("[components...]","the components to add").option("-a, --all","add all available components",!1).option("-o, --overwrite","overwrite existing files.",!1).option("-p, --path <path>","the path to add the component to.").option("-d, --dir <directory>","the directory where the project is located.").addOption(new t0("-l, --license <license-key>","Add a license key for adding components.").hideHelp()).option("-t, --type <shared|marketing|shared-assets|application|foundations>","the type of the component to add.").action(async(B,z)=>{if(B)Z.components=B;if(z)Z.all=z.all,Z.dir=z.dir,Z.path=z.path,Z.overwrite=z.overwrite,Z.license=z.license||Z.license;try{await Q3(Z)}catch(Q){console.error(N.red(Q))}});async function Q3(B){let z=z0().start(),Q=w.posix.join(process.cwd(),Z.dir||"");if(!S.existsSync(w.resolve(Q,"package.json")))z.warn("This command should be run in a project directory."),process.exit(1);let Y=await n(Q);if(Z.license){if(!await a(Z.license))z.fail("Invalid license key"),process.exit(1);if(!S.existsSync(m)){let U=w.dirname(m);S.mkdirSync(U,{recursive:!0}),S.writeFileSync(m,JSON.stringify({license:Z.license},null,2))}if(JSON.parse(S.readFileSync(m,"utf-8")).license!==Z.license)S.writeFileSync(m,JSON.stringify({license:Z.license},null,2),"utf-8")}z.stop();let V=[];if(Z.components.length){let q=await K0(Z.type,Z.components,Z.license);if(q&&q.pro&&q.pro.length>0){if(console.log(),q.pro.length===1){let W=q.pro[0]?.split("/")[1]||q.pro[0];console.log(N.yellow(`\uD83D\uDD12 The ${N.cyan(W)} component requires PRO access.`))}else console.log(N.yellow("\uD83D\uDD12 The following components require PRO access:")),q.pro.forEach((W)=>{let U=W?.split("/")[1]||W;console.log(` • ${N.cyan(U)}`)});console.log(),console.log("To access PRO components:"),console.log(` ${N.green("→")} If you've already purchased: ${N.cyan("npx untitledui@latest login")}`),console.log(` ${N.green("→")} To purchase PRO components: ${N.cyan("https://www.untitledui.com/buy/react")}`),console.log(),process.exit(1)}if(!q?.components.length)console.log("No components found"),process.exit(1);V.push(...q.components)}if(!Z?.type&&!Z?.components.length){let q=await T0(Z.license);if(!q)console.log("No component types found"),process.exit(1);let W=await X0({type:"select",name:"type",onState:L0,message:`What type of ${N.cyan("component")} are you adding?`,choices:q?.types.map((U)=>({title:U,value:U}))});Z.type=W.type}if(!Z?.path){let q=await X0({type:"text",name:"path",onState:L0,message:`Where would you like to add the ${N.cyan("components")}?`,initial:"components"});Z.path=q.path}if(!Z?.components.length){let q=await u0(Z?.type,Z.license);if(!q)console.log("No components found"),process.exit(1);let W=await X0({type:"multiselect",name:"components",onState:L0,message:`Which ${N.cyan("components")} would you like to add?`,choices:q?.components?.map((U)=>({title:U||"example",value:U||"example",selected:Z.components.includes(U)})),instructions:!1,hint:"- Space to select. Return to submit"});if(Z.components=W.components,!W.components||W.components.length===0)console.log("No option selected. Exiting..."),process.exit(1)}if(!Z.components?.length)z.warn("No components selected. Exiting."),process.exit(1);let v=r(Q),M=new Set,L=new Set,J=new Set,A=new z3({tsConfigFilePath:v?.tsConfig});if(Z.type&&Z.components.length){let q=await K0(Z.type,Z.components,Z.license);if(!q?.components.length)console.log("No components found"),process.exit(1);V.push(...q.components)}if(V.forEach((q)=>{let W=z0(`Adding ${q.name}...`).start(),U=q.files;q.dependencies.forEach((b)=>L.add(b)),q.devDependencies.forEach((b)=>J.add(b));try{if(U?.forEach(async({path:b,code:C})=>{let E=w.posix.join(Q,`${Y?.isSrcDir&&"src"}`,b.replace(/components\//,Z.path+"/")),x=w.dirname(E);if(S.existsSync(E)&&!Z.overwrite){if(S.readFileSync(E,"utf-8")!==C)M.add({code:C,path:E})}else{S.mkdirSync(x,{recursive:!0}),S.writeFileSync(E,C);let I=w.relative(w.resolve(Q,`${Y?.isSrcDir&&"src"}`,Z.path),E).split("/").length,y=I===1?"./":"../".repeat(I-1),k=A.addSourceFileAtPath(w.resolve(E));k.getImportDeclarations().forEach((F)=>{let e=F.getModuleSpecifierValue();F.setModuleSpecifier(i(e,Z.path,Y?.aliasPrefix,y))}),await k.save()}}),M.size)W.warn(`Some files of ${N.yellow(q.name)} already exist`);else W.succeed(`${N.green(q.name)} is added successfully`)}catch(b){W.fail(`
|
|
4
|
+
Failed to add the component ${N.red(q.name)}`),console.error(N.red(b)),process.exit(1)}}),M.size&&!Z?.overwrite)if(console.log(`
|
|
5
|
+
Following files already exist in the directory.`),M.forEach((W)=>{console.log(N.green(`- ${w.relative(Q,W.path)}`))}),(await X0({type:"confirm",name:"overwrite",message:"Do you want to overwrite the existing files?",initial:!0})).overwrite){let W=z0("Overwriting files").start();M.forEach((U)=>{let b=w.relative(w.resolve(Q,`${Y?.isSrcDir&&"src"}`,Z.path),U.path).split("/").length,C=b===1?"./":"../".repeat(b-1),E=A.addSourceFileAtPath(w.resolve(U.path));E.replaceWithText(U.code),E.getImportDeclarations().forEach((x)=>{let I=x.getModuleSpecifierValue();x.setModuleSpecifier(i(I,Z.path,Y?.aliasPrefix,C))}),E.saveSync()}),W.succeed("Files are overwritten")}else console.log(`Use ${N.cyan("--overwrite")} or ${N.cyan("-o")} to overwrite existing files, or refer to the documentation ${N.cyan("https://untitled.xyz/docs")} for manual installation. The rest of the files are added.`),process.exit(1);let K=T();if(L?.size){let q=z0("Installing dependencies").start();await C0(()=>$0("sh",["-c",`${Z?.dir?`cd ${Z?.dir} && `:""}${K} ${K==="npm"?"install":"add"} ${Array.from(L).join(" ")}`]).catch(async(W)=>{if(W.message.includes("peer"))q.warn("Dependency conflict detected. Retrying with --legacy-peer-deps..."),q.start("Installing dependencies with --legacy-peer-deps flag"),await $0("sh",["-c",`${Z?.dir?`cd ${Z?.dir} && `:""}${K} ${K==="npm"?"install":"add"} ${Array.from(L).join(" ")} --legacy-peer-deps`])}),{retries:1}),q.succeed("Dependencies are installed")}if(J?.size){let q=z0("Installing devDependencies").start();await C0(()=>$0("sh",["-c",`${Z?.dir?`cd ${Z?.dir} && `:""}${K} ${K==="npm"?"install":"add"} ${Array.from(J).join(" ")}`]).catch(async(W)=>{if(W.message.includes("peer"))q.warn("DevDependency conflict detected. Retrying with --legacy-peer-deps..."),q.start("Installing devDependencies with --legacy-peer-deps flag"),await $0("sh",["-c",`${Z?.dir?`cd ${Z?.dir} && `:""}${K} ${K==="npm"?"install":"add"} ${Array.from(J).join(" ")} --legacy-peer-deps`])}),{retries:1}),q.succeed("DevDependencies are installed")}process.exit(0)}import v0 from"chalk";import{Command as W3}from"commander";import*as d from"fs";import Y3 from"http";import Z3 from"open";import $3 from"ora";import X3 from"os";import*as G0 from"path";import{URL as q3}from"url";var H0=G0.join(X3.homedir(),".untitledui"),M0=G0.join(H0,"config.json"),k0=new W3().name("login").description("authenticate with Untitled UI to access PRO components").action(async()=>{let B=$3("Starting authentication...").start();try{await U3(B),B.succeed("Authentication completed successfully!"),console.log(v0.green(`
|
|
6
|
+
✨ You can now access PRO components with the CLI!`)),process.exit(0)}catch(z){B.fail(`Authentication failed: ${z instanceof Error?z.message:z}`),process.exit(1)}});async function U3(B){return new Promise((z,Q)=>{let X=Y3.createServer((Y,V)=>{let v=new q3(Y.url,"http://localhost");if(v.pathname==="/callback"){let M=v.searchParams.get("apiKey"),L=v.searchParams.get("error");if(L){V.writeHead(400,{"Content-Type":"text/html"}),V.end(`
|
|
7
|
+
<html>
|
|
8
|
+
<body style="font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; text-align: center; padding: 50px;">
|
|
9
|
+
<h1 style="color: #dc2626;">Authentication Failed</h1>
|
|
10
|
+
<p>${decodeURIComponent(L)}</p>
|
|
11
|
+
<p style="color: #6b7280;">You can close this tab and return to your terminal.</p>
|
|
12
|
+
</body>
|
|
13
|
+
</html>
|
|
14
|
+
`),X.close(),Q(new Error(decodeURIComponent(L)));return}if(!M){V.writeHead(400,{"Content-Type":"text/html"}),V.end(`
|
|
15
|
+
<html>
|
|
16
|
+
<body style="font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; text-align: center; padding: 50px;">
|
|
17
|
+
<h1 style="color: #dc2626;">Authentication Failed</h1>
|
|
18
|
+
<p>No API key received</p>
|
|
19
|
+
<p style="color: #6b7280;">You can close this tab and return to your terminal.</p>
|
|
20
|
+
</body>
|
|
21
|
+
</html>
|
|
22
|
+
`),X.close(),Q(new Error("No API key received"));return}try{V3(M),V.writeHead(200,{"Content-Type":"text/html"}),V.end(`
|
|
23
|
+
<html>
|
|
24
|
+
<body style="font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; text-align: center; padding: 50px;">
|
|
25
|
+
<h1 style="color: #16a34a;">Authentication Successful!</h1>
|
|
26
|
+
<p>Your CLI has been authenticated successfully.</p>
|
|
27
|
+
<p style="color: #6b7280;">You can now close this tab and return to your terminal.</p>
|
|
28
|
+
</body>
|
|
29
|
+
</html>
|
|
30
|
+
`),X.close(),z()}catch(J){V.writeHead(500,{"Content-Type":"text/html"}),V.end(`
|
|
31
|
+
<html>
|
|
32
|
+
<body style="font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; text-align: center; padding: 50px;">
|
|
33
|
+
<h1 style="color: #dc2626;">Authentication Failed</h1>
|
|
34
|
+
<p>Failed to save authentication data</p>
|
|
35
|
+
<p style="color: #6b7280;">You can close this tab and return to your terminal.</p>
|
|
36
|
+
</body>
|
|
37
|
+
</html>
|
|
38
|
+
`),X.close(),Q(J)}}else V.writeHead(404),V.end("Not found")});X.listen(0,"localhost",()=>{let v=`https://untitledui-docs.vercel.app/api/cli-auth?port=${X.address().port}`;B.text="Opening browser for authentication...",Z3(v).catch((M)=>{console.log(v0.yellow(`
|
|
39
|
+
Failed to open browser automatically: ${M.message}`)),console.log(v0.cyan(`Please manually open: ${v}
|
|
40
|
+
`))}),B.text="Waiting for authentication in browser..."}),setTimeout(()=>{X.close(),Q(new Error("Authentication timeout. Please try again."))},300000)})}function V3(B){if(!d.existsSync(H0))d.mkdirSync(H0,{recursive:!0});let z={};if(d.existsSync(M0))try{z=JSON.parse(d.readFileSync(M0,"utf-8"))}catch{z={}}z.license=B,d.writeFileSync(M0,JSON.stringify(z,null,2),"utf-8")}import N0 from"async-retry";import H from"chalk";import{Command as w3,Option as u3}from"commander";import{execa as B0}from"execa";import*as u from"fs";import Q0 from"ora";import T3 from"os";import*as G from"path";import l from"prompts";import{Project as y3}from"ts-morph";import J3 from"node-fetch";async function q0(B,z){try{let X=await J3("https://untitledui-docs.vercel.app/api/components/example",{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({example:B,key:z})});if(!X.ok){if(X.status===401||X.status===403)return{type:"error",status:X.status,message:"PRO access required"};return console.error(`API error: ${X.status} - ${X.statusText}`),null}return await X.json()}catch(X){return console.error(X?.message||"Error fetching example data."),null}}import V0 from"async-retry";import _ from"chalk";import{Command as G3}from"commander";import{execa as p}from"execa";import A0 from"fast-glob";import D from"fs";import o from"ora";import j3 from"os";import*as R from"path";import J0 from"prompts";import{Project as E3}from"ts-morph";import{fileURLToPath as R3}from"url";import K3 from"node-fetch";import{posix as P0,sep as b3}from"node:path";import{Readable as L3}from"node:stream";import{pipeline as M3}from"node:stream/promises";import{x as v3}from"tar";var F0=[".DS_Store",".git","node_modules","bun.lockb","yarn.lock","package-lock.json"];async function O0(B,{username:z,repo:Q,branch:X,template:Y}){try{let V=`https://codeload.github.com/${z}/${Q}/tar.gz/${X}`,v=await H3(V);await M3(v,v3({cwd:B,strip:1,filter:(M)=>{let L=M.split(P0.sep)?.pop()||"";if(F0.includes(L))return!1;if(Y)return M.split(b3).join(P0.sep).includes(Y);return!0}}))}catch(V){if(V instanceof Error)throw new Error(`Failed to download or extract repository: ${V.message}`);throw V}}async function H3(B){let z=await K3(B);if(!z.ok)throw new Error(`Failed to download: ${B} - Status: ${z.status} ${z.statusText}`);if(!z.body)throw new Error(`Failed to download: ${B} - No response body`);let Q=z.headers.get("content-type");if(Q&&!Q.includes("application/x-gzip")&&!Q.includes("application/octet-stream"))console.warn(`Warning: Unexpected content type: ${Q}. Expected application/x-gzip or application/octet-stream.`);return L3.from(z.body)}import j0 from"chalk";import*as f from"fs";import*as U0 from"path";function E0(B){if(!f.existsSync(U0.resolve(B)))console.log(j0.red(`Error: CSS file not found at ${B}`)),process.exit(1);let z=f.readFileSync(U0.resolve(B),"utf-8"),Q=/(--color-[a-zA-Z-]+-\d{1,3}):\s*(rgb\([^)]+\))/g,X={},Y;while((Y=Q.exec(z))!==null)if(Y[1]&&Y[2])X[Y[1]]=Y[2];return X}function R0(B,z,Q){let X=U0.resolve(Q);if(!f.existsSync(X)){console.log(j0.red(`Error: CSS file not found at ${X}`));return}let Y=f.readFileSync(X,"utf-8"),V=E0(Q),v={},M={};for(let[J,A]of Object.entries(V))if(J.startsWith(`--color-${B}-`)){let K=J.replace(`--color-${B}-`,"");v[K]=J}else if(J.startsWith(`--color-${z}-`)){let K=J.replace(`--color-${z}-`,"");M[K]=A}let L=!1;for(let[J,A]of Object.entries(v))if(M[J]){let K=M[J],q=new RegExp(`(${A}):\\s*rgb\\([^)]*\\);?`,"g");if(q.test(Y))Y=Y.replace(q,`$1: ${K};`),L=!0;else console.log(j0.yellow(`No match found for ${A}`))}if(L)f.writeFileSync(X,Y,"utf-8")}var A3=R3(import.meta.url),g0=R.dirname(A3),I3=R.join(j3.homedir(),".untitledui"),c=R.join(I3,"config.json"),_3={"nextjs-starter":"Next.js","vite-starter":"Vite"},N3="vite-starter",D3="nextjs-starter",P="",j={color:"",template:"",framework:void 0};if(D.existsSync(c)){let B=JSON.parse(D.readFileSync(c,"utf-8"));j.license=B.license}var I0=(B)=>{if(B.aborted)process.stdout.write("\x1B[?25h"),process.stdout.write(`
|
|
41
|
+
`),process.exit(1)},d0=new G3().name("init").description("initialize a new project or adjust an existing one").argument("[directory]").usage("[directory] [options]").helpOption("-h, --help","Display this help message.").option("--vite","Initialize a Vite project.",!1).option("--next","Initialize a Next.js project.",!1).option("-c, --color <color-name>","Specify a color for the project.").option("-o, --overwrite","Overwrite existing files.",!1).option("-l, --license <license-key>","Add a license key to download the repository.").action(async(B,z)=>{if(B)P=B;if(z){if(j.color=z.color,j.template=z.template,j.overwrite=z.overwrite,j.license=z.license||j.license,j.vite=z.vite,j.next=z.next,z.vite)j.framework=N3;if(z.next)j.framework=D3}try{await _0(z),process.exit(0)}catch(Q){console.error(_.red(Q)),process.exit(1)}});async function _0(B,z=null){let Q=process.cwd(),X=D.existsSync(R.resolve(Q,"package.json")),Y=R.resolve(R.join(g0,"../config/styles","theme.css")),V=E0(Y??""),v=Array.from(new Set(Object.keys(V).map((J)=>J?.split("--color-")?.[1]?.replace(/-\d{1,3}/,"")))),M=o().start(),L=await n(Q);if(j.license){if(!await a(j.license))M.fail("Invalid license key"),process.exit(1);if(!D.existsSync(c)){let K=R.dirname(c);D.mkdirSync(K,{recursive:!0}),D.writeFileSync(c,JSON.stringify({license:j.license},null,2))}if(JSON.parse(D.readFileSync(c,"utf-8")).license!==j.license)D.writeFileSync(c,JSON.stringify({license:j.license},null,2))}if(!X){if(M.stop(),!P){let J=await J0({onState:I0,type:"text",name:"path",message:"What is your project named?",initial:"untitled-ui"});if(typeof J.path==="string")P=J.path.trim()}if(z)z.projectPath=P;if(D.existsSync(R.resolve(R.posix.join(Q,P))))M.fail(_.red("Directory already exists!")),process.exit(1);if(j.vite&&j.next||!j.framework){let J=await J0({type:"select",name:"framework",onState:I0,message:`Which ${_.cyan("framework")} would you like to use?`,choices:[{title:_.cyan("Next"),value:"nextjs-starter"},{title:_.yellow("Vite"),value:"vite-starter"}]});j.framework=J.framework}M.succeed("Framework is selected: "+_.green(_3[j.framework]))}else if(L?.framework==="other")M.fail("Unsupported project framework"),console.log(`Please refer to the documentation ${_.cyan("https://untitled.xyz/docs")} for supported frameworks or proceed with manual installation.`),process.exit(1);else if(L?.framework.startsWith("next")||L?.framework.startsWith("vite"))M.succeed(_.yellow(`Detected ${y0[L.framework]} project, proceeding with the setup...`));if(!j.color){let J=await J0({type:"select",name:"color",onState:I0,initial:B.color??"",message:`Which ${_.cyan("color")} would you like to use as the ${_.cyanBright("brand")} color?`,choices:v.map((A)=>({title:A,value:A}))});j.color=J.color}if(P&&!X){let J=R.resolve(P);console.log(`
|
|
42
|
+
Creating a new project in ${_.blue(P)}`);let A=o("Downloading and extracting the repository...").start();try{D.mkdirSync(J,{recursive:!0}),await V0(()=>O0(J,{branch:"main",username:"a-peak-works",repo:j.framework}),{retries:2}),A.succeed("Files are downloaded and extracted successfully!");let K=o({text:"Installing dependencies..."}).start(),q=A0.sync(["**/styles/theme.css"],{cwd:J,absolute:!0,onlyFiles:!0})[0];if(R0("brand",j.color||"",q??""),await V0(()=>p("sh",["-c",`cd ${P} && ${T()} install && git init`]).catch(async(W)=>{if(W.message.includes("peer"))K.warn("Dependency conflict detected. Retrying with --legacy-peer-deps..."),K.start("Installing dependencies with --legacy-peer-deps flag"),await p("sh",["-c",`cd ${P} && ${T()==="npm"?"npm --legacy-peer-deps":T()} install && git init`])}),{retries:1}),K.succeed("Dependencies are installed"),!z)console.log(`
|
|
8
43
|
Your project is ready, to get staretd run the following commands:
|
|
9
44
|
|
|
10
|
-
cd ${
|
|
11
|
-
${
|
|
12
|
-
Failed to download and extract the repository`)),
|
|
13
|
-
`);
|
|
14
|
-
`),
|
|
45
|
+
cd ${_.cyan(P)}
|
|
46
|
+
${_.cyan(T())} run dev`)}catch(K){if(A.fail(_.red(`
|
|
47
|
+
Failed to download and extract the repository`)),K instanceof Error)console.error(K.message);else console.error(`
|
|
48
|
+
`);D.rmdirSync(J,{recursive:!0}),process.exit(1)}}else{let J=o("Copying files to the project directory").start(),A=new Set,K=r(Q),q=R.resolve(R.join(g0,"../config")),W=A0.sync(["**"],{cwd:q,onlyFiles:!0,ignore:h}),U=["tailwindcss","tailwindcss-animate","@tailwindcss/typography","tailwindcss-react-aria-components"],b=["@tailwindcss/postcss","postcss"];if(W.forEach((I)=>{let y=I.includes("postcss.config"),k=R.resolve(R.posix.join(q),I),F=R.resolve(Q,y?I:`${L?.isSrcDir?"src":""}/${I}`);if(D.existsSync(F)){if(j?.overwrite)D.copyFileSync(k,F);else{let e=D.readFileSync(F,"utf-8"),g=D.readFileSync(k,"utf-8");if(e!==g)A.add({targetFile:F,sourceFile:k})}return}D.mkdirSync(R.dirname(F),{recursive:!0}),D.writeFileSync(F,""),D.copyFileSync(k,F)}),!A.size)J.succeed("Files are copied successfully!");if(A.size&&!j?.overwrite)if(console.log(`
|
|
49
|
+
`),J.fail("Following files already exist in the directory."),A.forEach((y)=>{console.log(`- ${_.green(y.targetFile)}`)}),(await J0({type:"confirm",name:"overwrite",message:"Do you want to overwrite the existing files?",initial:!0})).overwrite){let y=o("Overwriting files").start();A.forEach((k)=>{D.copyFileSync(k.sourceFile,k.targetFile)}),y.succeed("Files are overwritten")}else console.log(`Use ${_.cyan("--overwrite")} or ${_.cyan("-o")} to overwrite existing files, or refer to the documentation ${_.cyan("https://untitled.xyz/docs")} for manual installation. The rest of the files are added.`);if(K?.tailwindFile)console.log(`
|
|
15
50
|
Tailwind config file exists in the project directory. You can add it to your globals.css as follows:`),console.log(`
|
|
16
|
-
${
|
|
17
|
-
`);let
|
|
18
|
-
`),
|
|
19
|
-
Ensure that the ${
|
|
20
|
-
Your project is ready, you can now start adding components.`)
|
|
51
|
+
${_.cyan(`@config "../${L?.isSrcDir&&"../"}${R.relative(Q,K.tailwindFile)}";`)}
|
|
52
|
+
`);let C=K?.layoutFile||K?.appFile||L?.framework==="vite"&&K?.mainFile||"";if(!C)console.log(`Import following files to your main file:
|
|
53
|
+
`),W.forEach((I)=>{console.log(_.cyan(I))});else{let y=new E3({tsConfigFilePath:R.resolve(K?.tsConfig||"")}).addSourceFileAtPath(R.resolve(C)),k="globals.css";y.getImportDeclarations().filter((g)=>g.getModuleSpecifierValue().includes("globals.css")).forEach((g)=>g.remove());let F=R.relative(R.resolve(Q,`${L?.isSrcDir&&"src"}`),C).split("/").length,e=L?.aliasPrefix?.stylesPrefix||L?.aliasPrefix?.srcPrefix||(F===1?"./":"../".repeat(F-1));y.addImportDeclarations(W.filter((g)=>g.includes("globals.css")).map((g)=>({moduleSpecifier:`${e}${L?.aliasPrefix?.stylesPrefix?g?.split("styles/")[1]:g}`}))),y.saveSync()}let E=o(),x=A0.sync(["**/styles/theme.css"],{cwd:Q,absolute:!0,onlyFiles:!0,ignore:h});if(!x?.length)return J.fail(`Failed to copy ${_.cyan("theme.css")} file.
|
|
54
|
+
Ensure that the ${_.cyan("theme.css")} file exists in the project directory under ${_.yellow("styles/")} folder.`);if(R0("brand",j.color||"",x[0]??""),E.start("Installing dependencies"),await V0(()=>p(T(),[T()==="npm"?"install":"add",...U]).catch(async(I)=>{if(I.message.includes("peer"))E.warn("Dependency conflict detected. Retrying with --legacy-peer-deps..."),E.start("Installing dependencies with --legacy-peer-deps flag"),await p(T(),[T()==="npm"?"install":"add",...U,"--legacy-peer-deps"])}),{retries:1}),await V0(()=>p(T(),[T()==="npm"?"install":"add",...b]).catch(async(I)=>{if(I.message.includes("peer"))E.warn("DevDependency conflict detected. Retrying with --legacy-peer-deps..."),E.start("Installing dependencies with --legacy-peer-deps flag"),await p(T(),[T()==="npm"?"install":"add",...b,"--legacy-peer-deps"])}),{retries:1}),E.succeed("Dependencies are installed"),J.succeed(_.green("Project setup is completed!")),!z?.projectPath)console.log(`
|
|
55
|
+
Your project is ready, you can now start adding components.`)}}var S3=G.join(T3.homedir(),".untitledui"),s=G.join(S3,"config.json"),$={path:"",example:"",license:"",components:[]},O={};if(u.existsSync(s)){let B=JSON.parse(u.readFileSync(s,"utf-8"));$.license=B.license}var t=(B)=>{if(B.aborted)process.stdout.write("\x1B[?25h"),process.stdout.write(`
|
|
56
|
+
`),process.exit(1)},h0=new w3().name("example").description("add an example to the project").argument("[example]","the example to add").option("-o, --overwrite","overwrite existing files.",!1).option("-p, --path <path>","the path to add the component to.").option("-e, --example-path <example-path>","the path to add the example file to.").addOption(new u3("-l, --license <license-key>","Add a license key for adding components.").hideHelp()).action(async(B,z)=>{if(B)$.example=B;if(z)$.path=z.path,$.overwrite=z.overwrite,$.examplePath=z.examplePath,$.license=z.license||$.license;try{await _0(z,O),await C3($)}catch(Q){console.error(H.red(Q))}});async function C3(B){let z=Q0().start(),Q=G.posix.join(process.cwd(),O?.projectPath||"");if(!u.existsSync(G.posix.join(G.resolve(Q,"package.json"))))z.warn("This command should be run in a project directory."),process.exit(1);let Y=await n(Q);if($.license){if(!await a($.license))z.fail("Invalid license key"),process.exit(1);if(!u.existsSync(s)){let b=G.dirname(s);u.mkdirSync(b,{recursive:!0}),u.writeFileSync(s,JSON.stringify({license:$.license},null,2))}if(JSON.parse(u.readFileSync(s,"utf-8")).license!==$.license)u.writeFileSync(s,JSON.stringify({license:$.license},null,2),"utf-8")}if(z.stop(),!$.example){let W=await l({type:"select",name:"example",onState:t,message:"Select which type of example you want to add",choices:[{title:"Application",value:"application"},{title:"Marketing",value:"marketing"}]});$.example=W.example}let V=null;if($.example){let W=await q0($.example,$.license);if(W?.type==="error"&&(W.status===401||W.status===403))console.log(),console.log(H.yellow(`\uD83D\uDD12 The ${H.cyan($.example)} example requires PRO access.`)),console.log(),console.log("To access PRO examples:"),console.log(` ${H.green("→")} If you've already purchased: ${H.cyan("npx untitledui@latest login")}`),console.log(` ${H.green("→")} To purchase PRO examples: ${H.cyan("https://www.untitledui.com/buy/react")}`),console.log(),process.exit(1);if(W?.type==="directory"){let U=await l({type:"select",name:"example",onState:t,message:`Select a folder or file in "${$.example}"`,choices:W.results.map((b)=>({title:b,value:b}))});if(!U.example)return;if($.example=U.example,W=await q0(U.example,$.license),W?.type==="error"&&(W.status===401||W.status===403))console.log(),console.log(H.yellow(`\uD83D\uDD12 The ${H.cyan(U.example)} example requires PRO access.`)),console.log(),console.log("To access PRO examples:"),console.log(` ${H.green("→")} If you've already purchased: ${H.cyan("npx untitledui@latest login")}`),console.log(` ${H.green("→")} To purchase PRO examples: ${H.cyan("https://www.untitledui.com/buy/react")}`),console.log(),process.exit(1)}if(W?.type==="json-files"){let U=await l({type:"select",name:"example",onState:t,message:`Select a JSON file in "${$.example}"`,choices:W.results.map((b)=>({title:b,value:`${$.example}/${b}`}))});if(!U.example)return;if($.example=U.example,W=await q0(U.example,$.license),W?.type==="error"&&(W.status===401||W.status===403))console.log(),console.log(H.yellow(`\uD83D\uDD12 The ${H.cyan(U.example)} example requires PRO access.`)),console.log(),console.log("To access PRO examples:"),console.log(` ${H.green("→")} If you've already purchased: ${H.cyan("npx untitledui@latest login")}`),console.log(` ${H.green("→")} To purchase PRO examples: ${H.cyan("https://www.untitledui.com/buy/react")}`),console.log(),process.exit(1)}if(W?.type==="json-file")V=W.content}if(!V)z.fail("No example found"),process.exit(1);if(!$?.examplePath){let W=Y?.isUsingAppDir?"app":"pages",U=Y?.isSrcDir?G.posix.join("src",W):W,b=await l({type:"text",name:"examplePath",onState:t,message:`Where would you like to add the ${H.cyan($?.example)} example?`,initial:U});$.examplePath=b.examplePath}else if(!u.existsSync(G.posix.join(Q,$.examplePath)))u.mkdirSync(G.posix.join(Q,$.examplePath),{recursive:!0}),console.log(H.green(`Created directory ${$.examplePath}`));if(!$?.path){let W=await l({type:"text",name:"path",onState:t,message:`Where would you like to add the ${H.cyan("components")}?`,initial:"components"});$.path=W.path}let v=V.components.filter((W)=>!u.existsSync(G.posix.join(Q,`${Y?.isSrcDir&&"src"}`,W?.path?.replace(/components\//,$.path+"/"))));if(v?.length){let W=await l({type:"multiselect",name:"components",onState:t,message:`Select which components you want to add from ${H.cyan(V.name)} example`,choices:v.map((U)=>({title:U?.name,value:U?.name})),instructions:!1,hint:"- Space to select. Return to submit"});if($.components=W.components,!v.length&&!W.components?.length)z.warn("No components selected")}let M=r(Q),L=new Set,J=new y3({tsConfigFilePath:M?.tsConfig}),A=Q0(`Adding ${$?.example}...`).start();try{if(V.files?.forEach(async({path:W,code:U})=>{let b=G.posix.join(Q,`${Y?.isSrcDir&&"src"}`,W.replace(/components\//,$.path+"/"));if(W.includes("examples")){let E=G.basename(W);b=G.posix.join(Q,$?.examplePath??"",E)}let C=G.dirname(b);if(u.existsSync(b)&&!$.overwrite){if(u.readFileSync(b,"utf-8")!==U)L.add({code:U,path:b})}else{u.mkdirSync(C,{recursive:!0}),u.writeFileSync(b,U);let E=G.relative(G.resolve(Q,`${Y?.isSrcDir&&"src"}`,$.path),b).split("/").length,x=E===1?"./":"../".repeat(E-1),I=J.addSourceFileAtPath(G.resolve(b));I.getImportDeclarations().forEach((y)=>{let k=y.getModuleSpecifierValue();y.setModuleSpecifier(i(k,$.path,Y?.aliasPrefix,x))}),await I.save()}}),L.size)A.warn(`Some files of ${H.yellow($?.example)} already exist`);else A.succeed(`${H.green($?.example)} is added successfully`)}catch(W){A.fail(`
|
|
57
|
+
Failed to add the component ${H.red($?.example)}`),console.error(H.red(W)),process.exit(1)}if(L.size&&!$?.overwrite)if(console.log(`
|
|
58
|
+
Following files already exist in the directory.`),L.forEach((U)=>{console.log(H.green(`- ${G.relative(Q,U.path)}`))}),(await l({type:"confirm",name:"overwrite",message:"Do you want to overwrite the existing files?",initial:!0})).overwrite){let U=Q0("Overwriting files").start();L.forEach((b)=>{let C=G.relative(G.resolve(Q,`${Y?.isSrcDir&&"src"}`,$.path),b.path).split("/").length,E=C===1?"./":"../".repeat(C-1),x=J.addSourceFileAtPath(G.resolve(b.path));x.replaceWithText(b.code),x.getImportDeclarations().forEach((I)=>{let y=I.getModuleSpecifierValue();I.setModuleSpecifier(i(y,$.path,Y?.aliasPrefix,E))}),x.saveSync()}),U.succeed("Files are overwritten")}else console.log(`Use ${H.cyan("--overwrite")} or ${H.cyan("-o")} to overwrite existing files, or refer to the documentation ${H.cyan("https://untitled.xyz/docs")} for manual installation. The rest of the files are added.`),process.exit(1);let K=T();if(V?.dependencies?.length){let W=Q0("Installing example dependencies").start();await N0(()=>B0("sh",["-c",`${O?.projectPath?`cd ${O?.projectPath} && `:""}${K} ${K==="npm"?"install":"add"} ${Array.from(V.dependencies).join(" ")}`]).catch(async(U)=>{if(U.message.includes("peer"))W.warn("Dependency conflict detected. Retrying with --legacy-peer-deps..."),W.start("Installing dependencies with --legacy-peer-deps flag"),await B0("sh",["-c",`${O?.projectPath?`cd ${O?.projectPath} && `:""}${K} ${K==="npm"?"install":"add"} ${Array.from(V.dependencies).join(" ")} --legacy-peer-deps`])}),{retries:1}),W.succeed("Example dependencies are installed")}if(V?.devDependencies?.length){let W=Q0("Installing example devDependencies").start();await N0(()=>B0("sh",["-c",`${O?.projectPath?`cd ${O?.projectPath} && `:""}${K} ${K==="npm"?"install":"add"} ${Array.from(V.devDependencies).join(" ")}`]).catch(async(U)=>{if(U.message.includes("peer"))W.warn("DevDependency conflict detected. Retrying with --legacy-peer-deps..."),W.start("Installing devDependencies with --legacy-peer-deps flag"),await B0("sh",["-c",`${O?.projectPath?`cd ${O?.projectPath} && `:""}${K} ${K==="npm"?"install":"add"} ${Array.from(V.devDependencies).join(" ")} --legacy-peer-deps`])}),{retries:1}),W.succeed("Example devDependencies are installed")}let q=S0();if($?.components?.length)await N0(()=>B0(q,["untitledui@latest","add",...$.components,"--path",$.path,"--dir",O?.projectPath||""],{stdio:"inherit"}),{retries:1});process.exit(0)}var D0={name:"untitledui",version:"0.1.7",main:"dist/index.mjs",description:"Untitled UI CLI",type:"module",publishConfig:{access:"public"},scripts:{test:'echo "Error: no test specified" && exit 1',dev:"bun build --entrypoints ./index.ts --entry-naming=[name].mjs --outdir=dist --target=node --minify --packages=external --env=inline --define=process.env.API_URL=http://localhost:3000/api --watch",build:"bun build --entrypoints ./index.ts --entry-naming=[name].mjs --outdir=dist --target=node --minify --packages=external --env=inline --define=process.env.API_URL=https://untitledui-docs.vercel.app/api","publish:npm":"bun run build && npm publish --access public",start:"node dist/index.mjs"},repository:{type:"git",url:"https://github.com/a-peak-works/untitledui-tailwind.git"},bugs:{url:"https://github.com/a-peak-works/untitledui-tailwind/issues"},homepage:"https://github.com/a-peak-works/untitledui-tailwind#readme",keywords:["untitled-ui","cli","tailwindcss","nextjs"],files:["dist","config"],author:"",license:"MIT",bin:{untitledui:"dist/index.mjs"},exports:"./dist/index.mjs",dependencies:{"async-retry":"^1.3.3",chalk:"^5.4.1",commander:"^13.1.0",execa:"^7.0.0","fast-glob":"^3.3.3","node-fetch":"^3.3.2",open:"^10.1.0",ora:"^8.2.0",prettier:"^3.5.3",prompts:"^2.4.2",tar:"^7.4.3","ts-morph":"^25.0.1","tsconfig-paths":"^4.2.0","update-check":"^1.5.4"},devDependencies:{"@types/async-retry":"^1.4.9","@types/prompts":"^2.4.9","@types/tar":"^6.1.13","type-fest":"^4.37.0",typescript:"^5.8.2"}};process.on("SIGINT",()=>process.exit(0));process.on("SIGTERM",()=>process.exit(0));async function F3(){let B=new k3().name(D0.name).version(D0.version);B.addCommand(d0).addCommand(x0).addCommand(h0).addCommand(k0),B.parse()}F3();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "untitledui",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.8",
|
|
4
4
|
"main": "dist/index.mjs",
|
|
5
5
|
"description": "Untitled UI CLI",
|
|
6
6
|
"type": "module",
|
|
@@ -45,6 +45,7 @@
|
|
|
45
45
|
"execa": "^7.0.0",
|
|
46
46
|
"fast-glob": "^3.3.3",
|
|
47
47
|
"node-fetch": "^3.3.2",
|
|
48
|
+
"open": "^10.1.0",
|
|
48
49
|
"ora": "^8.2.0",
|
|
49
50
|
"prettier": "^3.5.3",
|
|
50
51
|
"prompts": "^2.4.2",
|