sprawlify 0.0.104 → 0.0.106

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.
Files changed (2) hide show
  1. package/dist/index.mjs +91 -73
  2. package/package.json +1 -1
package/dist/index.mjs CHANGED
@@ -8,7 +8,7 @@ import { existsSync } from "fs";
8
8
  import prompts from "prompts";
9
9
  import { faker } from "@faker-js/faker";
10
10
  //#region package.json
11
- var version = "0.0.104";
11
+ var version = "0.0.106";
12
12
  //#endregion
13
13
  //#region src/utils/file-helper.ts
14
14
  const FILE_BACKUP_SUFFIX = ".bak";
@@ -178,20 +178,7 @@ const FRAMEWORKS = {
178
178
  svelte: { title: "Svelte" },
179
179
  vue: { title: "Vue" }
180
180
  };
181
- const METAFRAMEWORKS = {
182
- next: {
183
- title: "Next.js",
184
- frameworks: ["react"]
185
- },
186
- nuxt: {
187
- title: "Nuxt",
188
- frameworks: ["vue"]
189
- },
190
- sveltekit: {
191
- title: "SvelteKit",
192
- frameworks: ["svelte"]
193
- }
194
- };
181
+ const METAFRAMEWORKS = {};
195
182
  //#endregion
196
183
  //#region src/preset/presets.ts
197
184
  const PRESETS = {
@@ -201,7 +188,7 @@ const PRESETS = {
201
188
  dependencies: {
202
189
  "class-variance-authority": "^0.7.1",
203
190
  react: "^18.2.0",
204
- "@sprawlify/react": "^0.0.102",
191
+ "@sprawlify/react": "^0.0.106",
205
192
  clsx: "^2.1.1",
206
193
  "tailwind-merge": "^3.5.0"
207
194
  },
@@ -238,13 +225,13 @@ const PRESETS = {
238
225
  dependencies: {
239
226
  react: "^18.2.0",
240
227
  "class-variance-authority": "^0.7.1",
241
- "@sprawlify/react": "^0.0.102",
228
+ "@sprawlify/react": "^0.0.106",
242
229
  "lucide-react": "^0.577.0",
243
230
  clsx: "^2.1.1",
244
231
  "tailwind-merge": "^3.5.0"
245
232
  },
246
233
  devDependencies: {
247
- "tailwind-scrollbar": "^4.0.6",
234
+ "tailwind-scrollbar": "^4.0.2",
248
235
  "tw-animate-css": "^1.4.0"
249
236
  },
250
237
  tailwindcss: { css: "@import \"tailwindcss\";\n@import \"tw-animate-css\";\n@plugin 'tailwind-scrollbar';\n\n@custom-variant dark (&:is(.dark *));\n\n:root {\n --background: oklch(1 0 0);\n --foreground: oklch(0.145 0 0);\n --card: oklch(1 0 0);\n --card-foreground: oklch(0.145 0 0);\n --popover: oklch(1 0 0);\n --popover-foreground: oklch(0.145 0 0);\n --primary: oklch(0.205 0 0);\n --primary-foreground: oklch(0.985 0 0);\n --secondary: oklch(0.97 0 0);\n --secondary-foreground: oklch(0.205 0 0);\n --muted: oklch(0.97 0 0);\n --muted-foreground: oklch(0.556 0 0);\n --accent: oklch(0.97 0 0);\n --accent-foreground: oklch(0.205 0 0);\n --destructive: oklch(0.577 0.245 27.325);\n --destructive-foreground: oklch(0.577 0.245 27.325);\n --border: oklch(0.922 0 0);\n --input: oklch(0.922 0 0);\n --ring: oklch(0.708 0 0);\n --radius: 0.625rem;\n --sidebar: oklch(0.985 0 0);\n --sidebar-foreground: oklch(0.145 0 0);\n --sidebar-primary: oklch(0.205 0 0);\n --sidebar-primary-foreground: oklch(0.985 0 0);\n --sidebar-accent: oklch(0.97 0 0);\n --sidebar-accent-foreground: oklch(0.205 0 0);\n --sidebar-border: oklch(0.922 0 0);\n --sidebar-ring: oklch(0.708 0 0);\n}\n\n.dark {\n --background: oklch(0.145 0 0);\n --foreground: oklch(0.985 0 0);\n --card: oklch(0.145 0 0);\n --card-foreground: oklch(0.985 0 0);\n --popover: oklch(0.145 0 0);\n --popover-foreground: oklch(0.985 0 0);\n --primary: oklch(0.985 0 0);\n --primary-foreground: oklch(0.205 0 0);\n --secondary: oklch(0.269 0 0);\n --secondary-foreground: oklch(0.985 0 0);\n --muted: oklch(0.269 0 0);\n --muted-foreground: oklch(0.708 0 0);\n --accent: oklch(0.269 0 0);\n --accent-foreground: oklch(0.985 0 0);\n --destructive: oklch(0.396 0.141 25.723);\n --destructive-foreground: oklch(0.637 0.237 25.331);\n --border: oklch(0.269 0 0);\n --input: oklch(0.269 0 0);\n --ring: oklch(0.439 0 0);\n --sidebar: oklch(0.205 0 0);\n --sidebar-foreground: oklch(0.985 0 0);\n --sidebar-primary: oklch(0.488 0.243 264.376);\n --sidebar-primary-foreground: oklch(0.985 0 0);\n --sidebar-accent: oklch(0.269 0 0);\n --sidebar-accent-foreground: oklch(0.985 0 0);\n --sidebar-border: oklch(0.269 0 0);\n --sidebar-ring: oklch(0.439 0 0);\n}\n\n@theme inline {\n --color-background: var(--background);\n --color-foreground: var(--foreground);\n --color-card: var(--card);\n --color-card-foreground: var(--card-foreground);\n --color-popover: var(--popover);\n --color-popover-foreground: var(--popover-foreground);\n --color-primary: var(--primary);\n --color-primary-foreground: var(--primary-foreground);\n --color-secondary: var(--secondary);\n --color-secondary-foreground: var(--secondary-foreground);\n --color-muted: var(--muted);\n --color-muted-foreground: var(--muted-foreground);\n --color-accent: var(--accent);\n --color-accent-foreground: var(--accent-foreground);\n --color-destructive: var(--destructive);\n --color-destructive-foreground: var(--destructive-foreground);\n --color-border: var(--border);\n --color-input: var(--input);\n --color-ring: var(--ring);\n --radius-sm: calc(var(--radius) - 4px);\n --radius-md: calc(var(--radius) - 2px);\n --radius-lg: var(--radius);\n --radius-xl: calc(var(--radius) + 4px);\n --color-sidebar: var(--sidebar);\n --color-sidebar-foreground: var(--sidebar-foreground);\n --color-sidebar-primary: var(--sidebar-primary);\n --color-sidebar-primary-foreground: var(--sidebar-primary-foreground);\n --color-sidebar-accent: var(--sidebar-accent);\n --color-sidebar-accent-foreground: var(--sidebar-accent-foreground);\n --color-sidebar-border: var(--sidebar-border);\n --color-sidebar-ring: var(--sidebar-ring);\n}\n\n@layer base {\n * {\n @apply border-border outline-ring/50;\n }\n body {\n @apply bg-background text-foreground;\n }\n\n button:not(:disabled),\n [role=\"button\"]:not(:disabled) {\n cursor: pointer;\n }\n}\n" },
@@ -554,13 +541,13 @@ const PRESETS = {
554
541
  dependencies: {
555
542
  "solid-js": "^1.8.0",
556
543
  "class-variance-authority": "^0.7.1",
557
- "@sprawlify/solid": "^0.0.102",
544
+ "@sprawlify/solid": "^0.0.106",
558
545
  "lucide-solid": "^0.400.0",
559
546
  clsx: "^2.1.1",
560
547
  "tailwind-merge": "^3.5.0"
561
548
  },
562
549
  devDependencies: {
563
- "tailwind-scrollbar": "^4.0.6",
550
+ "tailwind-scrollbar": "^4.0.2",
564
551
  "tw-animate-css": "^1.4.0"
565
552
  },
566
553
  tailwindcss: { css: "@import \"tailwindcss\";\n@import \"tw-animate-css\";\n@plugin 'tailwind-scrollbar';\n\n@custom-variant dark (&:is(.dark *));\n\n:root {\n --background: oklch(1 0 0);\n --foreground: oklch(0.145 0 0);\n --card: oklch(1 0 0);\n --card-foreground: oklch(0.145 0 0);\n --popover: oklch(1 0 0);\n --popover-foreground: oklch(0.145 0 0);\n --primary: oklch(0.205 0 0);\n --primary-foreground: oklch(0.985 0 0);\n --secondary: oklch(0.97 0 0);\n --secondary-foreground: oklch(0.205 0 0);\n --muted: oklch(0.97 0 0);\n --muted-foreground: oklch(0.556 0 0);\n --accent: oklch(0.97 0 0);\n --accent-foreground: oklch(0.205 0 0);\n --destructive: oklch(0.577 0.245 27.325);\n --destructive-foreground: oklch(0.577 0.245 27.325);\n --border: oklch(0.922 0 0);\n --input: oklch(0.922 0 0);\n --ring: oklch(0.708 0 0);\n --radius: 0.625rem;\n --sidebar: oklch(0.985 0 0);\n --sidebar-foreground: oklch(0.145 0 0);\n --sidebar-primary: oklch(0.205 0 0);\n --sidebar-primary-foreground: oklch(0.985 0 0);\n --sidebar-accent: oklch(0.97 0 0);\n --sidebar-accent-foreground: oklch(0.205 0 0);\n --sidebar-border: oklch(0.922 0 0);\n --sidebar-ring: oklch(0.708 0 0);\n}\n\n.dark {\n --background: oklch(0.145 0 0);\n --foreground: oklch(0.985 0 0);\n --card: oklch(0.145 0 0);\n --card-foreground: oklch(0.985 0 0);\n --popover: oklch(0.145 0 0);\n --popover-foreground: oklch(0.985 0 0);\n --primary: oklch(0.985 0 0);\n --primary-foreground: oklch(0.205 0 0);\n --secondary: oklch(0.269 0 0);\n --secondary-foreground: oklch(0.985 0 0);\n --muted: oklch(0.269 0 0);\n --muted-foreground: oklch(0.708 0 0);\n --accent: oklch(0.269 0 0);\n --accent-foreground: oklch(0.985 0 0);\n --destructive: oklch(0.396 0.141 25.723);\n --destructive-foreground: oklch(0.637 0.237 25.331);\n --border: oklch(0.269 0 0);\n --input: oklch(0.269 0 0);\n --ring: oklch(0.439 0 0);\n --sidebar: oklch(0.205 0 0);\n --sidebar-foreground: oklch(0.985 0 0);\n --sidebar-primary: oklch(0.488 0.243 264.376);\n --sidebar-primary-foreground: oklch(0.985 0 0);\n --sidebar-accent: oklch(0.269 0 0);\n --sidebar-accent-foreground: oklch(0.985 0 0);\n --sidebar-border: oklch(0.269 0 0);\n --sidebar-ring: oklch(0.439 0 0);\n}\n\n@theme inline {\n --color-background: var(--background);\n --color-foreground: var(--foreground);\n --color-card: var(--card);\n --color-card-foreground: var(--card-foreground);\n --color-popover: var(--popover);\n --color-popover-foreground: var(--popover-foreground);\n --color-primary: var(--primary);\n --color-primary-foreground: var(--primary-foreground);\n --color-secondary: var(--secondary);\n --color-secondary-foreground: var(--secondary-foreground);\n --color-muted: var(--muted);\n --color-muted-foreground: var(--muted-foreground);\n --color-accent: var(--accent);\n --color-accent-foreground: var(--accent-foreground);\n --color-destructive: var(--destructive);\n --color-destructive-foreground: var(--destructive-foreground);\n --color-border: var(--border);\n --color-input: var(--input);\n --color-ring: var(--ring);\n --radius-sm: calc(var(--radius) - 4px);\n --radius-md: calc(var(--radius) - 2px);\n --radius-lg: var(--radius);\n --radius-xl: calc(var(--radius) + 4px);\n --color-sidebar: var(--sidebar);\n --color-sidebar-foreground: var(--sidebar-foreground);\n --color-sidebar-primary: var(--sidebar-primary);\n --color-sidebar-primary-foreground: var(--sidebar-primary-foreground);\n --color-sidebar-accent: var(--sidebar-accent);\n --color-sidebar-accent-foreground: var(--sidebar-accent-foreground);\n --color-sidebar-border: var(--sidebar-border);\n --color-sidebar-ring: var(--sidebar-ring);\n}\n\n@layer base {\n * {\n @apply border-border outline-ring/50;\n }\n body {\n @apply bg-background text-foreground;\n }\n\n button:not(:disabled),\n [role=\"button\"]:not(:disabled) {\n cursor: pointer;\n }\n}\n" },
@@ -876,15 +863,15 @@ const PRESETS = {
876
863
  },
877
864
  svelte: {
878
865
  dependencies: {
879
- "@sprawlify/svelte": "^0.0.102",
880
- svelte: "^4.0.0",
866
+ "@sprawlify/svelte": "^0.0.106",
867
+ svelte: "^5.54.0",
881
868
  "class-variance-authority": "^0.7.1",
882
869
  "lucide-svelte": "^0.400.0",
883
870
  clsx: "^2.1.1",
884
871
  "tailwind-merge": "^3.5.0"
885
872
  },
886
873
  devDependencies: {
887
- "tailwind-scrollbar": "^4.0.6",
874
+ "tailwind-scrollbar": "^4.0.2",
888
875
  "tw-animate-css": "^1.4.0"
889
876
  },
890
877
  tailwindcss: { css: "@import \"tailwindcss\";\n@import \"tw-animate-css\";\n@plugin 'tailwind-scrollbar';\n\n@custom-variant dark (&:is(.dark *));\n\n:root {\n --background: oklch(1 0 0);\n --foreground: oklch(0.145 0 0);\n --card: oklch(1 0 0);\n --card-foreground: oklch(0.145 0 0);\n --popover: oklch(1 0 0);\n --popover-foreground: oklch(0.145 0 0);\n --primary: oklch(0.205 0 0);\n --primary-foreground: oklch(0.985 0 0);\n --secondary: oklch(0.97 0 0);\n --secondary-foreground: oklch(0.205 0 0);\n --muted: oklch(0.97 0 0);\n --muted-foreground: oklch(0.556 0 0);\n --accent: oklch(0.97 0 0);\n --accent-foreground: oklch(0.205 0 0);\n --destructive: oklch(0.577 0.245 27.325);\n --destructive-foreground: oklch(0.577 0.245 27.325);\n --border: oklch(0.922 0 0);\n --input: oklch(0.922 0 0);\n --ring: oklch(0.708 0 0);\n --radius: 0.625rem;\n --sidebar: oklch(0.985 0 0);\n --sidebar-foreground: oklch(0.145 0 0);\n --sidebar-primary: oklch(0.205 0 0);\n --sidebar-primary-foreground: oklch(0.985 0 0);\n --sidebar-accent: oklch(0.97 0 0);\n --sidebar-accent-foreground: oklch(0.205 0 0);\n --sidebar-border: oklch(0.922 0 0);\n --sidebar-ring: oklch(0.708 0 0);\n}\n\n.dark {\n --background: oklch(0.145 0 0);\n --foreground: oklch(0.985 0 0);\n --card: oklch(0.145 0 0);\n --card-foreground: oklch(0.985 0 0);\n --popover: oklch(0.145 0 0);\n --popover-foreground: oklch(0.985 0 0);\n --primary: oklch(0.985 0 0);\n --primary-foreground: oklch(0.205 0 0);\n --secondary: oklch(0.269 0 0);\n --secondary-foreground: oklch(0.985 0 0);\n --muted: oklch(0.269 0 0);\n --muted-foreground: oklch(0.708 0 0);\n --accent: oklch(0.269 0 0);\n --accent-foreground: oklch(0.985 0 0);\n --destructive: oklch(0.396 0.141 25.723);\n --destructive-foreground: oklch(0.637 0.237 25.331);\n --border: oklch(0.269 0 0);\n --input: oklch(0.269 0 0);\n --ring: oklch(0.439 0 0);\n --sidebar: oklch(0.205 0 0);\n --sidebar-foreground: oklch(0.985 0 0);\n --sidebar-primary: oklch(0.488 0.243 264.376);\n --sidebar-primary-foreground: oklch(0.985 0 0);\n --sidebar-accent: oklch(0.269 0 0);\n --sidebar-accent-foreground: oklch(0.985 0 0);\n --sidebar-border: oklch(0.269 0 0);\n --sidebar-ring: oklch(0.439 0 0);\n}\n\n@theme inline {\n --color-background: var(--background);\n --color-foreground: var(--foreground);\n --color-card: var(--card);\n --color-card-foreground: var(--card-foreground);\n --color-popover: var(--popover);\n --color-popover-foreground: var(--popover-foreground);\n --color-primary: var(--primary);\n --color-primary-foreground: var(--primary-foreground);\n --color-secondary: var(--secondary);\n --color-secondary-foreground: var(--secondary-foreground);\n --color-muted: var(--muted);\n --color-muted-foreground: var(--muted-foreground);\n --color-accent: var(--accent);\n --color-accent-foreground: var(--accent-foreground);\n --color-destructive: var(--destructive);\n --color-destructive-foreground: var(--destructive-foreground);\n --color-border: var(--border);\n --color-input: var(--input);\n --color-ring: var(--ring);\n --radius-sm: calc(var(--radius) - 4px);\n --radius-md: calc(var(--radius) - 2px);\n --radius-lg: var(--radius);\n --radius-xl: calc(var(--radius) + 4px);\n --color-sidebar: var(--sidebar);\n --color-sidebar-foreground: var(--sidebar-foreground);\n --color-sidebar-primary: var(--sidebar-primary);\n --color-sidebar-primary-foreground: var(--sidebar-primary-foreground);\n --color-sidebar-accent: var(--sidebar-accent);\n --color-sidebar-accent-foreground: var(--sidebar-accent-foreground);\n --color-sidebar-border: var(--sidebar-border);\n --color-sidebar-ring: var(--sidebar-ring);\n}\n\n@layer base {\n * {\n @apply border-border outline-ring/50;\n }\n body {\n @apply bg-background text-foreground;\n }\n\n button:not(:disabled),\n [role=\"button\"]:not(:disabled) {\n cursor: pointer;\n }\n}\n" },
@@ -1668,7 +1655,7 @@ const PRESETS = {
1668
1655
  },
1669
1656
  vue: {
1670
1657
  dependencies: {
1671
- "@sprawlify/vue": "^0.0.102",
1658
+ "@sprawlify/vue": "^0.0.106",
1672
1659
  vue: "^3.4.0",
1673
1660
  "class-variance-authority": "^0.7.1",
1674
1661
  "lucide-vue-next": "^0.400.0",
@@ -1676,7 +1663,7 @@ const PRESETS = {
1676
1663
  "tailwind-merge": "^3.5.0"
1677
1664
  },
1678
1665
  devDependencies: {
1679
- "tailwind-scrollbar": "^4.0.6",
1666
+ "tailwind-scrollbar": "^4.0.2",
1680
1667
  "tw-animate-css": "^1.4.0"
1681
1668
  },
1682
1669
  tailwindcss: { css: "@import \"tailwindcss\";\n@import \"tw-animate-css\";\n@plugin 'tailwind-scrollbar';\n\n@custom-variant dark (&:is(.dark *));\n\n:root {\n --background: oklch(1 0 0);\n --foreground: oklch(0.145 0 0);\n --card: oklch(1 0 0);\n --card-foreground: oklch(0.145 0 0);\n --popover: oklch(1 0 0);\n --popover-foreground: oklch(0.145 0 0);\n --primary: oklch(0.205 0 0);\n --primary-foreground: oklch(0.985 0 0);\n --secondary: oklch(0.97 0 0);\n --secondary-foreground: oklch(0.205 0 0);\n --muted: oklch(0.97 0 0);\n --muted-foreground: oklch(0.556 0 0);\n --accent: oklch(0.97 0 0);\n --accent-foreground: oklch(0.205 0 0);\n --destructive: oklch(0.577 0.245 27.325);\n --destructive-foreground: oklch(0.577 0.245 27.325);\n --border: oklch(0.922 0 0);\n --input: oklch(0.922 0 0);\n --ring: oklch(0.708 0 0);\n --radius: 0.625rem;\n --sidebar: oklch(0.985 0 0);\n --sidebar-foreground: oklch(0.145 0 0);\n --sidebar-primary: oklch(0.205 0 0);\n --sidebar-primary-foreground: oklch(0.985 0 0);\n --sidebar-accent: oklch(0.97 0 0);\n --sidebar-accent-foreground: oklch(0.205 0 0);\n --sidebar-border: oklch(0.922 0 0);\n --sidebar-ring: oklch(0.708 0 0);\n}\n\n.dark {\n --background: oklch(0.145 0 0);\n --foreground: oklch(0.985 0 0);\n --card: oklch(0.145 0 0);\n --card-foreground: oklch(0.985 0 0);\n --popover: oklch(0.145 0 0);\n --popover-foreground: oklch(0.985 0 0);\n --primary: oklch(0.985 0 0);\n --primary-foreground: oklch(0.205 0 0);\n --secondary: oklch(0.269 0 0);\n --secondary-foreground: oklch(0.985 0 0);\n --muted: oklch(0.269 0 0);\n --muted-foreground: oklch(0.708 0 0);\n --accent: oklch(0.269 0 0);\n --accent-foreground: oklch(0.985 0 0);\n --destructive: oklch(0.396 0.141 25.723);\n --destructive-foreground: oklch(0.637 0.237 25.331);\n --border: oklch(0.269 0 0);\n --input: oklch(0.269 0 0);\n --ring: oklch(0.439 0 0);\n --sidebar: oklch(0.205 0 0);\n --sidebar-foreground: oklch(0.985 0 0);\n --sidebar-primary: oklch(0.488 0.243 264.376);\n --sidebar-primary-foreground: oklch(0.985 0 0);\n --sidebar-accent: oklch(0.269 0 0);\n --sidebar-accent-foreground: oklch(0.985 0 0);\n --sidebar-border: oklch(0.269 0 0);\n --sidebar-ring: oklch(0.439 0 0);\n}\n\n@theme inline {\n --color-background: var(--background);\n --color-foreground: var(--foreground);\n --color-card: var(--card);\n --color-card-foreground: var(--card-foreground);\n --color-popover: var(--popover);\n --color-popover-foreground: var(--popover-foreground);\n --color-primary: var(--primary);\n --color-primary-foreground: var(--primary-foreground);\n --color-secondary: var(--secondary);\n --color-secondary-foreground: var(--secondary-foreground);\n --color-muted: var(--muted);\n --color-muted-foreground: var(--muted-foreground);\n --color-accent: var(--accent);\n --color-accent-foreground: var(--accent-foreground);\n --color-destructive: var(--destructive);\n --color-destructive-foreground: var(--destructive-foreground);\n --color-border: var(--border);\n --color-input: var(--input);\n --color-ring: var(--ring);\n --radius-sm: calc(var(--radius) - 4px);\n --radius-md: calc(var(--radius) - 2px);\n --radius-lg: var(--radius);\n --radius-xl: calc(var(--radius) + 4px);\n --color-sidebar: var(--sidebar);\n --color-sidebar-foreground: var(--sidebar-foreground);\n --color-sidebar-primary: var(--sidebar-primary);\n --color-sidebar-primary-foreground: var(--sidebar-primary-foreground);\n --color-sidebar-accent: var(--sidebar-accent);\n --color-sidebar-accent-foreground: var(--sidebar-accent-foreground);\n --color-sidebar-border: var(--sidebar-border);\n --color-sidebar-ring: var(--sidebar-ring);\n}\n\n@layer base {\n * {\n @apply border-border outline-ring/50;\n }\n body {\n @apply bg-background text-foreground;\n }\n\n button:not(:disabled),\n [role=\"button\"]:not(:disabled) {\n cursor: pointer;\n }\n}\n" },
@@ -2686,8 +2673,8 @@ dist-ssr
2686
2673
  "preview": "vite preview"
2687
2674
  },
2688
2675
  "dependencies": {
2689
- "@sprawlify/primitives": "^0.0.102",
2690
- "@sprawlify/react": "^0.0.102",
2676
+ "@sprawlify/primitives": "^0.0.106",
2677
+ "@sprawlify/react": "^0.0.106",
2691
2678
  "react": "^19.2.4",
2692
2679
  "react-dom": "^19.2.4",
2693
2680
  "class-variance-authority": "^0.7.1",
@@ -2704,8 +2691,7 @@ dist-ssr
2704
2691
  "globals": "^17.4.0",
2705
2692
  "tailwindcss": "^4.2.2",
2706
2693
  "typescript": "^5.9.3",
2707
- "vite": "^8.0.1",
2708
- "vite-tsconfig-paths": "^6.1.1"
2694
+ "vite": "^8.0.1"
2709
2695
  }
2710
2696
  }`
2711
2697
  },
@@ -2733,10 +2719,7 @@ dist-ssr
2733
2719
  "noUnusedParameters": true,
2734
2720
  "erasableSyntaxOnly": true,
2735
2721
  "noFallthroughCasesInSwitch": true,
2736
- "noUncheckedSideEffectImports": true,
2737
- "paths": {
2738
- "@/*": ["./src/*"]
2739
- }
2722
+ "noUncheckedSideEffectImports": true
2740
2723
  },
2741
2724
  "include": ["src"]
2742
2725
  }`
@@ -2748,7 +2731,12 @@ dist-ssr
2748
2731
  "references": [
2749
2732
  { "path": "./tsconfig.app.json" },
2750
2733
  { "path": "./tsconfig.node.json" }
2751
- ]
2734
+ ],
2735
+ "compilerOptions": {
2736
+ "paths": {
2737
+ "@/*": ["./src/*"]
2738
+ }
2739
+ }
2752
2740
  }`
2753
2741
  },
2754
2742
  {
@@ -2773,10 +2761,7 @@ dist-ssr
2773
2761
  "noUnusedParameters": true,
2774
2762
  "erasableSyntaxOnly": true,
2775
2763
  "noFallthroughCasesInSwitch": true,
2776
- "noUncheckedSideEffectImports": true,
2777
- "paths": {
2778
- "@/*": ["./src/*"]
2779
- }
2764
+ "noUncheckedSideEffectImports": true
2780
2765
  },
2781
2766
  "include": ["vite.config.ts"]
2782
2767
  }`
@@ -2786,10 +2771,12 @@ dist-ssr
2786
2771
  content: `import { defineConfig } from "vite"
2787
2772
  import react from "@vitejs/plugin-react"
2788
2773
  import tailwindcss from "@tailwindcss/vite"
2789
- import tsconfigPaths from "vite-tsconfig-paths";
2790
2774
 
2791
2775
  export default defineConfig({
2792
- plugins: [tsconfigPaths(), tailwindcss(), react()],
2776
+ resolve: {
2777
+ tsconfigPaths: true,
2778
+ },
2779
+ plugins: [tailwindcss(), react()],
2793
2780
  })`
2794
2781
  }
2795
2782
  ] }),
@@ -2871,8 +2858,8 @@ dist-ssr
2871
2858
  "preview": "vite preview"
2872
2859
  },
2873
2860
  "dependencies": {
2874
- "@sprawlify/primitives": "^0.0.102",
2875
- "@sprawlify/solid": "^0.0.102",
2861
+ "@sprawlify/primitives": "^0.0.106",
2862
+ "@sprawlify/solid": "^0.0.106",
2876
2863
  "solid-js": "^1.9.11"
2877
2864
  },
2878
2865
  "devDependencies": {
@@ -2922,7 +2909,12 @@ dist-ssr
2922
2909
  "references": [
2923
2910
  { "path": "./tsconfig.app.json" },
2924
2911
  { "path": "./tsconfig.node.json" }
2925
- ]
2912
+ ],
2913
+ "compilerOptions": {
2914
+ "paths": {
2915
+ "@/*": ["./src/*"]
2916
+ }
2917
+ }
2926
2918
  }`
2927
2919
  },
2928
2920
  {
@@ -2959,6 +2951,9 @@ import solid from "vite-plugin-solid"
2959
2951
  import tailwindcss from "@tailwindcss/vite"
2960
2952
 
2961
2953
  export default defineConfig({
2954
+ resolve: {
2955
+ tsconfigPaths: true,
2956
+ },
2962
2957
  plugins: [tailwindcss(), solid()],
2963
2958
  })`
2964
2959
  }
@@ -3034,12 +3029,11 @@ dist-ssr
3034
3029
  "scripts": {
3035
3030
  "dev": "vite",
3036
3031
  "build": "vite build",
3037
- "preview": "vite preview",
3038
- "check": "svelte-check --tsconfig ./tsconfig.app.json && tsc -p tsconfig.node.json"
3032
+ "preview": "vite preview"
3039
3033
  },
3040
3034
  "dependencies": {
3041
- "@sprawlify/primitives": "^0.0.102",
3042
- "@sprawlify/svelte": "^0.0.102"
3035
+ "@sprawlify/primitives": "^0.0.106",
3036
+ "@sprawlify/svelte": "^0.0.106"
3043
3037
  },
3044
3038
  "devDependencies": {
3045
3039
  "@sveltejs/vite-plugin-svelte": "^7.0.0",
@@ -3047,10 +3041,10 @@ dist-ssr
3047
3041
  "@tsconfig/svelte": "^5.0.8",
3048
3042
  "@types/node": "^24.12.0",
3049
3043
  "svelte": "^5.54.0",
3050
- "svelte-check": "^4.4.5",
3051
3044
  "tailwindcss": "^4.2.2",
3052
3045
  "typescript": "^5.9.3",
3053
- "vite": "^8.0.1"
3046
+ "vite": "^8.0.1",
3047
+ "vite-tsconfig-paths": "^6.1.1"
3054
3048
  }
3055
3049
  }`
3056
3050
  },
@@ -3084,7 +3078,12 @@ export default {}`
3084
3078
  "references": [
3085
3079
  { "path": "./tsconfig.app.json" },
3086
3080
  { "path": "./tsconfig.node.json" }
3087
- ]
3081
+ ],
3082
+ "compilerOptions": {
3083
+ "paths": {
3084
+ "@/*": ["./src/*"]
3085
+ }
3086
+ }
3088
3087
  }`
3089
3088
  },
3090
3089
  {
@@ -3121,6 +3120,9 @@ import { svelte } from "@sveltejs/vite-plugin-svelte"
3121
3120
  import tailwindcss from "@tailwindcss/vite"
3122
3121
 
3123
3122
  export default defineConfig({
3123
+ resolve: {
3124
+ tsconfigPaths: true,
3125
+ },
3124
3126
  plugins: [tailwindcss(), svelte()],
3125
3127
  })`
3126
3128
  }
@@ -3197,8 +3199,8 @@ dist-ssr
3197
3199
  "preview": "vite preview"
3198
3200
  },
3199
3201
  "dependencies": {
3200
- "@sprawlify/primitives": "^0.0.102",
3201
- "@sprawlify/vue": "^0.0.102",
3202
+ "@sprawlify/primitives": "^0.0.106",
3203
+ "@sprawlify/vue": "^0.0.106",
3202
3204
  "vue": "^3.5.30"
3203
3205
  },
3204
3206
  "devDependencies": {
@@ -3238,7 +3240,12 @@ dist-ssr
3238
3240
  "references": [
3239
3241
  { "path": "./tsconfig.app.json" },
3240
3242
  { "path": "./tsconfig.node.json" }
3241
- ]
3243
+ ],
3244
+ "compilerOptions": {
3245
+ "paths": {
3246
+ "@/*": ["./src/*"]
3247
+ }
3248
+ }
3242
3249
  }`
3243
3250
  },
3244
3251
  {
@@ -3275,6 +3282,9 @@ import vue from "@vitejs/plugin-vue"
3275
3282
  import tailwindcss from "@tailwindcss/vite"
3276
3283
 
3277
3284
  export default defineConfig({
3285
+ resolve: {
3286
+ tsconfigPaths: true,
3287
+ },
3278
3288
  plugins: [tailwindcss(), vue()],
3279
3289
  })`
3280
3290
  }
@@ -3361,16 +3371,24 @@ async function applyPresetPackageDependencies(cwd, frameworkPreset, packageNames
3361
3371
  }
3362
3372
  continue;
3363
3373
  }
3364
- const devDependencyVersion = frameworkPreset.devDependencies?.[packageName];
3365
- if (devDependencyVersion) {
3366
- if (!packageJson.devDependencies[packageName]) {
3367
- packageJson.devDependencies[packageName] = devDependencyVersion;
3368
- didChange = true;
3369
- }
3370
- continue;
3374
+ }
3375
+ if (frameworkPreset.devDependencies) {
3376
+ for (const [devDependencyName, devDependencyVersion] of Object.entries(frameworkPreset.devDependencies)) if (!packageJson.devDependencies[devDependencyName]) {
3377
+ packageJson.devDependencies[devDependencyName] = devDependencyVersion;
3378
+ didChange = true;
3371
3379
  }
3372
3380
  }
3373
- if (didChange) await fsExtra.writeJson(packageJsonPath, packageJson, { spaces: 2 });
3381
+ if (didChange) {
3382
+ if (packageJson.dependencies && Object.keys(packageJson.dependencies).length > 0) packageJson.dependencies = Object.keys(packageJson.dependencies).sort().reduce((sorted, key) => {
3383
+ sorted[key] = packageJson.dependencies[key];
3384
+ return sorted;
3385
+ }, {});
3386
+ if (packageJson.devDependencies && Object.keys(packageJson.devDependencies).length > 0) packageJson.devDependencies = Object.keys(packageJson.devDependencies).sort().reduce((sorted, key) => {
3387
+ sorted[key] = packageJson.devDependencies[key];
3388
+ return sorted;
3389
+ }, {});
3390
+ await fsExtra.writeJson(packageJsonPath, packageJson, { spaces: 2 });
3391
+ }
3374
3392
  }
3375
3393
  async function runInit(options) {
3376
3394
  let cwd = options.cwd;
@@ -3382,16 +3400,10 @@ async function runInit(options) {
3382
3400
  const selectedTemplate = options.framework && options.framework in templates ? templates[options.framework] : void 0;
3383
3401
  if (selectedTemplate?.files.length) for (const file of selectedTemplate.files) {
3384
3402
  const targetPath = path.resolve(cwd, file.path);
3385
- if (fsExtra.existsSync(targetPath) && !options.override) {
3386
- logger.warn(`Skipping ${highlighter.info(file.path)} because it already exists. Use ${highlighter.info("--override")} to replace it.`);
3387
- continue;
3388
- }
3389
3403
  await fsExtra.ensureDir(path.dirname(targetPath));
3390
3404
  await fsExtra.writeFile(targetPath, file.content, "utf8");
3391
- logger.success(`Created ${highlighter.info(file.path)} template file.`);
3392
3405
  }
3393
3406
  const componentsJsonPath = path.resolve(cwd, "components.json");
3394
- logger.info("Starting project initialization...");
3395
3407
  const frameworkPreset = getFrameworkPreset(options.preset, options.framework);
3396
3408
  const tailwindcss = {
3397
3409
  cwd: tailwindCssPathPrefix(cwd),
@@ -3423,7 +3435,6 @@ async function runInit(options) {
3423
3435
  if (backupPath && fsExtra.existsSync(backupPath)) {
3424
3436
  fsExtra.copyFileSync(backupPath, componentsJsonPath);
3425
3437
  fsExtra.unlinkSync(backupPath);
3426
- logger.info("Restored original configuration file.");
3427
3438
  }
3428
3439
  throw error;
3429
3440
  }
@@ -3434,7 +3445,6 @@ async function runInit(options) {
3434
3445
  return;
3435
3446
  }
3436
3447
  await applyPresetPackageDependencies(cwd, frameworkPreset, packageNames);
3437
- logger.info(`Applying preset components: ${itemsToApply.map((item) => highlighter.info(item.name)).join(", ")}.`);
3438
3448
  for (const item of itemsToApply) for (const file of item.files ?? []) {
3439
3449
  const targetPath = resolvePresetFilePath(cwd, file);
3440
3450
  if (fsExtra.existsSync(targetPath) && !options.override) {
@@ -3443,12 +3453,21 @@ async function runInit(options) {
3443
3453
  }
3444
3454
  await fsExtra.ensureDir(path.dirname(targetPath));
3445
3455
  await fsExtra.writeFile(targetPath, file.content, "utf8");
3446
- logger.success(`Created ${highlighter.info(path.relative(cwd, targetPath))} from preset component ${highlighter.info(item.name)}.`);
3447
3456
  }
3448
3457
  }
3449
3458
  //#endregion
3459
+ //#region src/commands/init/done.ts
3460
+ const sleep = (ms) => new Promise((resolve) => setTimeout(resolve, ms));
3461
+ async function doneInit(options) {
3462
+ const projectDir = path.relative(process.cwd(), options.cwd);
3463
+ logger.log(`\nThat's it!`);
3464
+ logger.log(`Enter your project directory using ${highlighter.info(`cd .${path.sep}${projectDir}`)}.`);
3465
+ logger.log(`Install dependencies using ${highlighter.info("npm install")}.`);
3466
+ await sleep(200);
3467
+ }
3468
+ //#endregion
3450
3469
  //#region src/commands/init.ts
3451
- const init = new Command().name("init").alias("create").description("initialize your project and install dependencies").argument("[components...]", "names, url or local path to component").option("-p, --preset <preset>", "the preset to use. (monochrome, clay)").option("-f, --framework <framework>", "the framework to use. (react, solid, svelte, vue)").option("--metaframework <metaframework>", "the metaframework to use. (next, react-router, nuxt, sveltekit)").option("-y, --yes", "skip confirmation prompt.", true).option("-d, --defaults", "use default configuration: --preset=monochrome --framework=react --metaframework=vanilla", false).option("-o, --override", "override existing configuration.", false).option("-c, --cwd <cwd>", "the working directory. defaults to the current directory.", process.cwd()).option("-n, --name <name>", "the name for the new project.").option("-s, --silent", "mute output.", false).option("--reinstall", "re-install existing UI components.").option("--no-reinstall", "do not re-install existing UI components.").action(async (components, opts) => {
3470
+ const init = new Command().name("init").alias("create").description("initialize your project and install dependencies").argument("[components...]", "names, url or local path to component").option("-p, --preset <preset>", "the preset to use. (monochrome, clay)").option("-f, --framework <framework>", "the framework to use. (react, solid, svelte, vue)").option("--metaframework <metaframework>", "the metaframework to use. (next, react-router, nuxt, sveltekit)").option("-y, --yes", "skip confirmation prompt.", true).option("-d, --defaults", "use default configuration: --preset=monochrome --framework=react --metaframework=none", false).option("-o, --override", "override existing configuration.", false).option("-c, --cwd <cwd>", "the working directory. defaults to the current directory.", process.cwd()).option("-n, --name <name>", "the name for the new project.").option("-s, --silent", "mute output.", false).option("--reinstall", "re-install existing UI components.").option("--no-reinstall", "do not re-install existing UI components.").action(async (components, opts) => {
3452
3471
  try {
3453
3472
  const options = parseInitOptions(opts);
3454
3473
  applyDefaultInitOptions(options);
@@ -3458,8 +3477,7 @@ const init = new Command().name("init").alias("create").description("initialize
3458
3477
  options.components = components;
3459
3478
  await loadEnvFiles(options.cwd);
3460
3479
  await runInit(options);
3461
- logger.break();
3462
- logger.log(`Project initialization completed in ${highlighter.info(options.cwd)}.\nYou may now add components.`);
3480
+ await doneInit(options);
3463
3481
  deleteFileBackup(path.resolve(options.cwd, "components.json"));
3464
3482
  logger.break();
3465
3483
  } catch (error) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sprawlify",
3
- "version": "0.0.104",
3
+ "version": "0.0.106",
4
4
  "type": "module",
5
5
  "description": "A command-line interface for Sprawlify.",
6
6
  "author": "sprawlify <npm@sprawlify.com>",