@dinachi/cli 0.5.0 → 0.6.0
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/README.md +13 -5
- package/dist/index.js +1086 -349
- package/package.json +17 -9
- package/templates/accordion/accordion.tsx +8 -3
- package/templates/alert-dialog/alert-dialog.tsx +24 -25
- package/templates/alert-dialog/index.ts +1 -1
- package/templates/autocomplete/autocomplete.tsx +0 -1
- package/templates/avatar/avatar.tsx +1 -3
- package/templates/badge/badge.tsx +167 -0
- package/templates/badge/index.ts +2 -0
- package/templates/button/button.tsx +6 -6
- package/templates/button/index.ts +2 -2
- package/templates/card/card.tsx +78 -0
- package/templates/card/index.ts +1 -0
- package/templates/checkbox/checkbox.tsx +2 -3
- package/templates/checkbox-group/checkbox-group.tsx +1 -3
- package/templates/collapsible/collapsible.tsx +1 -2
- package/templates/combobox/combobox.tsx +0 -1
- package/templates/context-menu/context-menu.tsx +0 -1
- package/templates/dialog/dialog.tsx +1 -1
- package/templates/drawer/drawer.tsx +0 -1
- package/templates/field/field.tsx +69 -85
- package/templates/fieldset/fieldset.tsx +0 -1
- package/templates/form/form.tsx +36 -28
- package/templates/input/index.ts +1 -2
- package/templates/input/input.tsx +0 -1
- package/templates/menu/menu.tsx +0 -1
- package/templates/menubar/menubar.tsx +21 -22
- package/templates/meter/meter.tsx +0 -1
- package/templates/navigation-menu/index.ts +1 -13
- package/templates/navigation-menu/navigation-menu.tsx +1 -3
- package/templates/number-field/number-field.tsx +0 -1
- package/templates/popover/popover.tsx +0 -1
- package/templates/preview-card/preview-card.tsx +0 -1
- package/templates/progress/progress.tsx +0 -1
- package/templates/radio/radio.tsx +0 -1
- package/templates/scroll-area/scroll-area.tsx +0 -1
- package/templates/select/select.tsx +1 -4
- package/templates/separator/separator.tsx +0 -1
- package/templates/slider/index.ts +10 -0
- package/templates/slider/slider.tsx +1 -3
- package/templates/switch/switch.tsx +0 -1
- package/templates/tabs/index.ts +8 -0
- package/templates/tabs/tabs.tsx +8 -3
- package/templates/textarea/index.ts +2 -0
- package/templates/textarea/textarea.tsx +23 -0
- package/templates/toast/toast.tsx +3 -2
- package/templates/toggle/toggle.tsx +0 -1
- package/templates/toggle-group/toggle-group.tsx +0 -1
- package/templates/toolbar/toolbar.tsx +0 -1
- package/templates/tooltip/tooltip.tsx +0 -1
- package/templates/tsconfig.json +20 -0
- package/templates/utils/utils.ts +0 -1
- package/templates/utils/variants.ts +0 -1
package/README.md
CHANGED
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
A CLI for adding Dinachi UI components to your project. Just like shadcn/ui, this tool copies component source code directly into your project, giving you full ownership and control.
|
|
4
4
|
|
|
5
|
+
Best fit: React projects using Tailwind CSS (Next.js, Vite, Remix, CRA, and similar layouts).
|
|
6
|
+
|
|
5
7
|
## Installation
|
|
6
8
|
|
|
7
9
|
```bash
|
|
@@ -48,7 +50,7 @@ This will:
|
|
|
48
50
|
- Set up the project configuration
|
|
49
51
|
- Install required dependencies
|
|
50
52
|
- Create utility functions
|
|
51
|
-
- Generate a `components.json` config file
|
|
53
|
+
- Generate a `components.json` config file with normalized project paths
|
|
52
54
|
|
|
53
55
|
### Add components
|
|
54
56
|
|
|
@@ -61,13 +63,16 @@ npx @dinachi/cli add button
|
|
|
61
63
|
This will:
|
|
62
64
|
- Copy the button component source code to your project
|
|
63
65
|
- Place it in your configured components directory
|
|
64
|
-
-
|
|
66
|
+
- Install any missing dependencies (or print them when using `--skip-install`)
|
|
65
67
|
|
|
66
68
|
### Available Commands
|
|
67
69
|
|
|
68
70
|
- `dinachi init` - Initialize Dinachi UI in your project
|
|
71
|
+
- `dinachi init --skip-install` - Initialize without package installation
|
|
69
72
|
- `dinachi add <component>` - Add a component to your project
|
|
70
73
|
- `dinachi add <component> --overwrite` - Overwrite existing component files
|
|
74
|
+
- `dinachi add --all` - Install all registered components
|
|
75
|
+
- `dinachi add <component> --skip-install` - Add files without installing packages
|
|
71
76
|
|
|
72
77
|
### Available Components
|
|
73
78
|
|
|
@@ -113,7 +118,7 @@ This will:
|
|
|
113
118
|
Unlike traditional component libraries, Dinachi UI copies the actual source code into your project. This means:
|
|
114
119
|
|
|
115
120
|
✅ **Full ownership** - The code is yours to modify
|
|
116
|
-
✅ **
|
|
121
|
+
✅ **Dependencies stay in your app** - Required packages are installed directly into your project
|
|
117
122
|
✅ **Complete customization** - Change variants, styles, and behavior as needed
|
|
118
123
|
✅ **Zero abstractions** - See exactly how components work
|
|
119
124
|
|
|
@@ -133,8 +138,11 @@ After running `dinachi init`, you'll have a `components.json` file:
|
|
|
133
138
|
"cssVariables": true
|
|
134
139
|
},
|
|
135
140
|
"aliases": {
|
|
136
|
-
"components": "./src/components
|
|
137
|
-
"utils": "./src/lib/utils"
|
|
141
|
+
"components": "./src/components",
|
|
142
|
+
"utils": "./src/lib/utils",
|
|
143
|
+
"ui": "./src/components/ui",
|
|
144
|
+
"lib": "./src/lib",
|
|
145
|
+
"hooks": "./src/hooks"
|
|
138
146
|
}
|
|
139
147
|
}
|
|
140
148
|
```
|