czero 0.2.0 → 0.2.5
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 +209 -209
- package/dist/cli/index.js +970 -72
- package/dist/components.css +2158 -1913
- package/dist/react/core/component-defaults.d.ts.map +1 -1
- package/dist/react/core/types/config.d.ts +161 -2
- package/dist/react/core/types/config.d.ts.map +1 -1
- package/dist/react/index.cjs +695 -12
- package/dist/react/index.cjs.map +1 -1
- package/dist/react/index.d.ts +138 -11
- package/dist/react/index.js +693 -13
- package/dist/react/index.js.map +1 -1
- package/dist/react/react/components/button.d.ts +1 -0
- package/dist/react/react/components/button.d.ts.map +1 -1
- package/dist/react/react/components/data-table.d.ts +39 -0
- package/dist/react/react/components/data-table.d.ts.map +1 -0
- package/dist/react/react/components/input.d.ts +5 -2
- package/dist/react/react/components/input.d.ts.map +1 -1
- package/dist/react/react/components/modal.d.ts +44 -0
- package/dist/react/react/components/modal.d.ts.map +1 -0
- package/dist/react/react/components/search-input.d.ts +13 -0
- package/dist/react/react/components/search-input.d.ts.map +1 -0
- package/dist/react/react/components/status-badge.d.ts +11 -0
- package/dist/react/react/components/status-badge.d.ts.map +1 -0
- package/dist/react/react/components/tabs.d.ts +42 -7
- package/dist/react/react/components/tabs.d.ts.map +1 -1
- package/dist/react/react/index.d.ts +4 -1
- package/dist/react/react/index.d.ts.map +1 -1
- package/dist/reset.css +6 -15
- package/dist/styles.css +2244 -2008
- package/package.json +93 -92
- package/dist/cli-new/cli/build-css.d.ts +0 -19
- package/dist/cli-new/cli/build-css.js +0 -88
- package/dist/cli-new/cli/generators/button.d.ts +0 -9
- package/dist/cli-new/cli/generators/button.js +0 -224
- package/dist/cli-new/cli/generators/card.d.ts +0 -9
- package/dist/cli-new/cli/generators/card.js +0 -104
- package/dist/cli-new/cli/generators/checkbox.d.ts +0 -6
- package/dist/cli-new/cli/generators/checkbox.js +0 -163
- package/dist/cli-new/cli/generators/index.d.ts +0 -10
- package/dist/cli-new/cli/generators/index.js +0 -40
- package/dist/cli-new/cli/generators/input.d.ts +0 -9
- package/dist/cli-new/cli/generators/input.js +0 -231
- package/dist/cli-new/cli/generators/switch.d.ts +0 -6
- package/dist/cli-new/cli/generators/switch.js +0 -156
- package/dist/cli-new/cli/generators/utilities.d.ts +0 -9
- package/dist/cli-new/cli/generators/utilities.js +0 -150
- package/dist/cli-new/cli/index.d.ts +0 -8
- package/dist/cli-new/cli/index.js +0 -288
- package/dist/cli-new/cli/token-resolver.d.ts +0 -44
- package/dist/cli-new/cli/token-resolver.js +0 -137
- package/dist/cli-new/cli/utils/deep-merge.d.ts +0 -15
- package/dist/cli-new/cli/utils/deep-merge.js +0 -41
- package/dist/cli-new/cli/validate-config.d.ts +0 -19
- package/dist/cli-new/cli/validate-config.js +0 -151
- package/dist/cli-new/src/core/component-defaults.d.ts +0 -7
- package/dist/cli-new/src/core/component-defaults.js +0 -467
- package/dist/cli-new/src/core/types/config.d.ts +0 -489
- package/dist/cli-new/src/core/types/config.js +0 -5
- package/dist/cli-new/src/presets/index.d.ts +0 -44
- package/dist/cli-new/src/presets/index.js +0 -194
- package/dist/react/react/lib/cn.d.ts +0 -7
- package/dist/react/react/lib/cn.d.ts.map +0 -1
|
@@ -1,194 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CZero Theme Presets
|
|
3
|
-
* Pre-built theme configurations users can extend
|
|
4
|
-
*/
|
|
5
|
-
/**
|
|
6
|
-
* Default preset - balanced, professional look
|
|
7
|
-
*/
|
|
8
|
-
export const defaultPreset = {
|
|
9
|
-
// Uses all default values from component-defaults.ts
|
|
10
|
-
};
|
|
11
|
-
/**
|
|
12
|
-
* Compact preset - tighter spacing, smaller sizes
|
|
13
|
-
* Great for data-dense applications
|
|
14
|
-
*/
|
|
15
|
-
export const compact = {
|
|
16
|
-
spacing: {
|
|
17
|
-
xs: "0.125rem",
|
|
18
|
-
sm: "0.375rem",
|
|
19
|
-
md: "0.5rem",
|
|
20
|
-
lg: "0.75rem",
|
|
21
|
-
xl: "1rem",
|
|
22
|
-
},
|
|
23
|
-
components: {
|
|
24
|
-
button: {
|
|
25
|
-
height: { sm: "1.75rem", md: "2rem", lg: "2.5rem" },
|
|
26
|
-
paddingX: { sm: "0.5rem", md: "0.75rem", lg: "1rem" },
|
|
27
|
-
gap: "0.375rem",
|
|
28
|
-
},
|
|
29
|
-
input: {
|
|
30
|
-
height: { sm: "1.75rem", md: "2rem", lg: "2.5rem" },
|
|
31
|
-
paddingX: { sm: "0.375rem", md: "0.5rem", lg: "0.75rem" },
|
|
32
|
-
},
|
|
33
|
-
card: {
|
|
34
|
-
padding: "$spacing-md",
|
|
35
|
-
header: { paddingBottom: "$spacing-sm", marginBottom: "$spacing-sm" },
|
|
36
|
-
footer: { paddingTop: "$spacing-sm", marginTop: "$spacing-sm", gap: "0.375rem" },
|
|
37
|
-
},
|
|
38
|
-
switch: {
|
|
39
|
-
width: { sm: "1.75rem", md: "2.25rem", lg: "3rem" },
|
|
40
|
-
height: { sm: "1rem", md: "1.25rem", lg: "1.5rem" },
|
|
41
|
-
thumbSize: { sm: "0.75rem", md: "1rem", lg: "1.25rem" },
|
|
42
|
-
},
|
|
43
|
-
checkbox: {
|
|
44
|
-
size: { sm: "0.875rem", md: "1rem", lg: "1.25rem" },
|
|
45
|
-
iconSize: { sm: "8px", md: "10px", lg: "12px" },
|
|
46
|
-
labelGap: "0.375rem",
|
|
47
|
-
},
|
|
48
|
-
},
|
|
49
|
-
};
|
|
50
|
-
/**
|
|
51
|
-
* Comfortable preset - more spacing, larger touch targets
|
|
52
|
-
* Great for mobile-first or accessibility-focused apps
|
|
53
|
-
*/
|
|
54
|
-
export const comfortable = {
|
|
55
|
-
spacing: {
|
|
56
|
-
xs: "0.375rem",
|
|
57
|
-
sm: "0.75rem",
|
|
58
|
-
md: "1rem",
|
|
59
|
-
lg: "1.5rem",
|
|
60
|
-
xl: "2rem",
|
|
61
|
-
},
|
|
62
|
-
components: {
|
|
63
|
-
button: {
|
|
64
|
-
height: { sm: "2.5rem", md: "3rem", lg: "3.5rem" },
|
|
65
|
-
paddingX: { sm: "1rem", md: "1.5rem", lg: "2rem" },
|
|
66
|
-
gap: "0.75rem",
|
|
67
|
-
},
|
|
68
|
-
input: {
|
|
69
|
-
height: { sm: "2.5rem", md: "3rem", lg: "3.5rem" },
|
|
70
|
-
paddingX: { sm: "0.75rem", md: "1rem", lg: "1.25rem" },
|
|
71
|
-
},
|
|
72
|
-
card: {
|
|
73
|
-
padding: "$spacing-xl",
|
|
74
|
-
header: { paddingBottom: "$spacing-lg", marginBottom: "$spacing-lg" },
|
|
75
|
-
footer: { paddingTop: "$spacing-lg", marginTop: "$spacing-lg", gap: "0.75rem" },
|
|
76
|
-
},
|
|
77
|
-
switch: {
|
|
78
|
-
width: { sm: "2.5rem", md: "3.25rem", lg: "4rem" },
|
|
79
|
-
height: { sm: "1.375rem", md: "1.75rem", lg: "2.125rem" },
|
|
80
|
-
thumbSize: { sm: "1.125rem", md: "1.5rem", lg: "1.875rem" },
|
|
81
|
-
},
|
|
82
|
-
checkbox: {
|
|
83
|
-
size: { sm: "1.25rem", md: "1.5rem", lg: "1.75rem" },
|
|
84
|
-
iconSize: { sm: "12px", md: "14px", lg: "16px" },
|
|
85
|
-
labelGap: "0.75rem",
|
|
86
|
-
},
|
|
87
|
-
},
|
|
88
|
-
};
|
|
89
|
-
/**
|
|
90
|
-
* Rounded preset - increased border radius for a softer look
|
|
91
|
-
*/
|
|
92
|
-
export const rounded = {
|
|
93
|
-
radius: {
|
|
94
|
-
none: "0",
|
|
95
|
-
sm: "0.5rem",
|
|
96
|
-
md: "0.75rem",
|
|
97
|
-
lg: "1rem",
|
|
98
|
-
xl: "1.5rem",
|
|
99
|
-
full: "9999px",
|
|
100
|
-
},
|
|
101
|
-
components: {
|
|
102
|
-
button: {
|
|
103
|
-
borderRadius: "$radius-lg",
|
|
104
|
-
},
|
|
105
|
-
input: {
|
|
106
|
-
borderRadius: "$radius-lg",
|
|
107
|
-
},
|
|
108
|
-
card: {
|
|
109
|
-
borderRadius: "$radius-xl",
|
|
110
|
-
},
|
|
111
|
-
},
|
|
112
|
-
};
|
|
113
|
-
/**
|
|
114
|
-
* Sharp preset - no border radius for a modern, angular look
|
|
115
|
-
*/
|
|
116
|
-
export const sharp = {
|
|
117
|
-
radius: {
|
|
118
|
-
none: "0",
|
|
119
|
-
sm: "0",
|
|
120
|
-
md: "2px",
|
|
121
|
-
lg: "4px",
|
|
122
|
-
xl: "6px",
|
|
123
|
-
full: "9999px",
|
|
124
|
-
},
|
|
125
|
-
components: {
|
|
126
|
-
button: {
|
|
127
|
-
borderRadius: "$radius-sm",
|
|
128
|
-
},
|
|
129
|
-
input: {
|
|
130
|
-
borderRadius: "$radius-sm",
|
|
131
|
-
},
|
|
132
|
-
card: {
|
|
133
|
-
borderRadius: "$radius-md",
|
|
134
|
-
},
|
|
135
|
-
checkbox: {
|
|
136
|
-
borderRadius: "2px",
|
|
137
|
-
},
|
|
138
|
-
},
|
|
139
|
-
};
|
|
140
|
-
/**
|
|
141
|
-
* Minimal preset - reduced shadows, subtle borders
|
|
142
|
-
*/
|
|
143
|
-
export const minimal = {
|
|
144
|
-
shadow: {
|
|
145
|
-
none: "none",
|
|
146
|
-
sm: "none",
|
|
147
|
-
md: "0 1px 2px rgb(0 0 0 / 0.03)",
|
|
148
|
-
lg: "0 2px 4px rgb(0 0 0 / 0.05)",
|
|
149
|
-
},
|
|
150
|
-
components: {
|
|
151
|
-
button: {
|
|
152
|
-
states: {
|
|
153
|
-
hover: { opacity: "0.8" },
|
|
154
|
-
focus: { ringWidth: "1px", ringOffset: "1px" },
|
|
155
|
-
},
|
|
156
|
-
},
|
|
157
|
-
card: {
|
|
158
|
-
shadow: "none",
|
|
159
|
-
borderWidth: "1px",
|
|
160
|
-
},
|
|
161
|
-
},
|
|
162
|
-
};
|
|
163
|
-
/**
|
|
164
|
-
* Vibrant preset - bolder colors, more pronounced effects
|
|
165
|
-
*/
|
|
166
|
-
export const vibrant = {
|
|
167
|
-
shadow: {
|
|
168
|
-
none: "none",
|
|
169
|
-
sm: "0 2px 4px rgb(0 0 0 / 0.1)",
|
|
170
|
-
md: "0 4px 8px rgb(0 0 0 / 0.12)",
|
|
171
|
-
lg: "0 8px 16px rgb(0 0 0 / 0.15)",
|
|
172
|
-
},
|
|
173
|
-
components: {
|
|
174
|
-
button: {
|
|
175
|
-
states: {
|
|
176
|
-
hover: { opacity: "1", transform: "translateY(-1px)" },
|
|
177
|
-
focus: { ringWidth: "3px", ringOffset: "2px" },
|
|
178
|
-
},
|
|
179
|
-
},
|
|
180
|
-
card: {
|
|
181
|
-
shadow: "$shadow-md",
|
|
182
|
-
},
|
|
183
|
-
},
|
|
184
|
-
};
|
|
185
|
-
// Export all presets
|
|
186
|
-
export const presets = {
|
|
187
|
-
default: defaultPreset,
|
|
188
|
-
compact,
|
|
189
|
-
comfortable,
|
|
190
|
-
rounded,
|
|
191
|
-
sharp,
|
|
192
|
-
minimal,
|
|
193
|
-
vibrant,
|
|
194
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"cn.d.ts","sourceRoot":"","sources":["../../../../src/react/lib/cn.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAQ,KAAK,UAAU,EAAE,MAAM,MAAM,CAAC;AAG7C,wBAAgB,EAAE,CAAC,GAAG,MAAM,EAAE,UAAU,EAAE,GAAG,MAAM,CAElD"}
|