@idealyst/components 1.0.23 → 1.0.25
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 +567 -567
- package/package.json +2 -6
- package/plugin/web.js +319 -185
- package/src/Avatar/Avatar.native.tsx +43 -43
- package/src/Avatar/Avatar.styles.tsx +66 -66
- package/src/Avatar/Avatar.web.tsx +50 -50
- package/src/Avatar/index.native.ts +1 -1
- package/src/Avatar/index.ts +1 -1
- package/src/Avatar/index.web.ts +1 -1
- package/src/Avatar/types.ts +42 -42
- package/src/Badge/Badge.native.tsx +42 -42
- package/src/Badge/Badge.styles.tsx +153 -153
- package/src/Badge/Badge.web.tsx +44 -44
- package/src/Badge/index.native.ts +1 -1
- package/src/Badge/index.ts +1 -1
- package/src/Badge/index.web.ts +1 -1
- package/src/Badge/types.ts +33 -33
- package/src/Button/Button.native.tsx +38 -38
- package/src/Button/Button.styles.tsx +214 -214
- package/src/Button/Button.types.ts +11 -11
- package/src/Button/Button.web.tsx +55 -55
- package/src/Button/index.native.ts +2 -2
- package/src/Button/index.ts +4 -4
- package/src/Button/index.web.ts +2 -2
- package/src/Button/types.ts +48 -48
- package/src/Card/Card.native.tsx +51 -51
- package/src/Card/Card.styles.tsx +239 -239
- package/src/Card/Card.web.tsx +61 -61
- package/src/Card/index.native.ts +2 -2
- package/src/Card/index.ts +4 -4
- package/src/Card/index.web.ts +2 -2
- package/src/Card/types.ts +58 -58
- package/src/Checkbox/Checkbox.native.tsx +98 -98
- package/src/Checkbox/Checkbox.styles.tsx +291 -291
- package/src/Checkbox/Checkbox.web.tsx +130 -130
- package/src/Checkbox/index.native.ts +2 -2
- package/src/Checkbox/index.ts +4 -4
- package/src/Checkbox/index.web.ts +2 -2
- package/src/Checkbox/types.ts +78 -78
- package/src/Divider/Divider.native.tsx +144 -144
- package/src/Divider/Divider.styles.tsx +601 -601
- package/src/Divider/Divider.web.tsx +72 -72
- package/src/Divider/index.native.ts +2 -2
- package/src/Divider/index.ts +4 -4
- package/src/Divider/index.web.ts +2 -2
- package/src/Divider/types.ts +53 -53
- package/src/Icon/Icon.native.tsx +38 -38
- package/src/Icon/Icon.styles.tsx +49 -49
- package/src/Icon/Icon.web.tsx +46 -46
- package/src/Icon/icon-types.ts +7452 -7452
- package/src/Icon/index.native.ts +2 -2
- package/src/Icon/index.ts +4 -4
- package/src/Icon/index.web.ts +2 -2
- package/src/Icon/types.ts +35 -35
- package/src/Input/Input.native.tsx +74 -74
- package/src/Input/Input.styles.tsx +176 -176
- package/src/Input/Input.web.tsx +70 -70
- package/src/Input/index.native.ts +2 -2
- package/src/Input/index.ts +4 -4
- package/src/Input/index.web.ts +2 -2
- package/src/Input/types.ts +68 -68
- package/src/Screen/Screen.native.tsx +40 -40
- package/src/Screen/Screen.styles.tsx +59 -59
- package/src/Screen/Screen.web.tsx +32 -32
- package/src/Screen/index.native.ts +1 -1
- package/src/Screen/index.ts +1 -1
- package/src/Screen/index.web.ts +1 -1
- package/src/Screen/types.ts +37 -37
- package/src/Text/Text.native.tsx +35 -35
- package/src/Text/Text.styles.tsx +66 -66
- package/src/Text/Text.web.tsx +40 -40
- package/src/Text/index.native.ts +2 -2
- package/src/Text/index.ts +4 -4
- package/src/Text/index.web.ts +2 -2
- package/src/Text/types.ts +38 -38
- package/src/View/View.native.tsx +55 -55
- package/src/View/View.styles.tsx +102 -102
- package/src/View/View.web.tsx +59 -59
- package/src/View/index.native.ts +2 -2
- package/src/View/index.ts +4 -4
- package/src/View/index.web.ts +2 -2
- package/src/View/types.ts +72 -72
- package/src/examples/AllExamples.tsx +71 -71
- package/src/examples/AvatarExamples.tsx +96 -96
- package/src/examples/BadgeExamples.tsx +199 -199
- package/src/examples/ButtonExamples.tsx +149 -149
- package/src/examples/CardExamples.tsx +175 -175
- package/src/examples/CheckboxExamples.tsx +216 -216
- package/src/examples/DividerExamples.tsx +217 -217
- package/src/examples/IconExamples.tsx +341 -341
- package/src/examples/InputExamples.tsx +133 -133
- package/src/examples/README.md +135 -135
- package/src/examples/ScreenExamples.tsx +153 -153
- package/src/examples/TextExamples.tsx +88 -88
- package/src/examples/ThemeExtensionExamples.tsx +90 -90
- package/src/examples/ValidationExamples.tsx +94 -94
- package/src/examples/ViewExamples.tsx +128 -128
- package/src/examples/extendedTheme.ts +328 -328
- package/src/examples/index.ts +14 -14
- package/src/index.native.ts +48 -48
- package/src/index.ts +47 -47
- package/src/theme/breakpoints.ts +8 -8
- package/src/theme/colorResolver.ts +217 -217
- package/src/theme/colors.ts +314 -314
- package/src/theme/defaultThemes.ts +325 -325
- package/src/theme/index.ts +187 -187
- package/src/theme/themeBuilder.ts +601 -601
- package/src/theme/unistyles.d.ts +5 -5
- package/src/theme/variantHelpers.ts +583 -583
- package/src/theme/variants.ts +55 -55
package/src/theme/colors.ts
CHANGED
|
@@ -1,315 +1,315 @@
|
|
|
1
|
-
// Base color palettes - these are the source of truth for all colors
|
|
2
|
-
export const colorPalettes = {
|
|
3
|
-
blue: {
|
|
4
|
-
50: '#eff6ff',
|
|
5
|
-
100: '#dbeafe',
|
|
6
|
-
200: '#bfdbfe',
|
|
7
|
-
300: '#93c5fd',
|
|
8
|
-
400: '#60a5fa',
|
|
9
|
-
500: '#3b82f6',
|
|
10
|
-
600: '#2563eb',
|
|
11
|
-
700: '#1d4ed8',
|
|
12
|
-
800: '#1e40af',
|
|
13
|
-
900: '#1e3a8a',
|
|
14
|
-
},
|
|
15
|
-
|
|
16
|
-
green: {
|
|
17
|
-
50: '#f0fdf4',
|
|
18
|
-
100: '#dcfce7',
|
|
19
|
-
200: '#bbf7d0',
|
|
20
|
-
300: '#86efac',
|
|
21
|
-
400: '#4ade80',
|
|
22
|
-
500: '#22c55e',
|
|
23
|
-
600: '#16a34a',
|
|
24
|
-
700: '#15803d',
|
|
25
|
-
800: '#166534',
|
|
26
|
-
900: '#14532d',
|
|
27
|
-
},
|
|
28
|
-
|
|
29
|
-
red: {
|
|
30
|
-
50: '#fef2f2',
|
|
31
|
-
100: '#fee2e2',
|
|
32
|
-
200: '#fecaca',
|
|
33
|
-
300: '#fca5a5',
|
|
34
|
-
400: '#f87171',
|
|
35
|
-
500: '#ef4444',
|
|
36
|
-
600: '#dc2626',
|
|
37
|
-
700: '#b91c1c',
|
|
38
|
-
800: '#991b1b',
|
|
39
|
-
900: '#7f1d1d',
|
|
40
|
-
},
|
|
41
|
-
|
|
42
|
-
amber: {
|
|
43
|
-
50: '#fffbeb',
|
|
44
|
-
100: '#fef3c7',
|
|
45
|
-
200: '#fde68a',
|
|
46
|
-
300: '#fcd34d',
|
|
47
|
-
400: '#fbbf24',
|
|
48
|
-
500: '#f59e0b',
|
|
49
|
-
600: '#d97706',
|
|
50
|
-
700: '#b45309',
|
|
51
|
-
800: '#92400e',
|
|
52
|
-
900: '#78350f',
|
|
53
|
-
},
|
|
54
|
-
|
|
55
|
-
gray: {
|
|
56
|
-
50: '#f9fafb',
|
|
57
|
-
100: '#f3f4f6',
|
|
58
|
-
200: '#e5e7eb',
|
|
59
|
-
300: '#d1d5db',
|
|
60
|
-
400: '#9ca3af',
|
|
61
|
-
500: '#6b7280',
|
|
62
|
-
600: '#4b5563',
|
|
63
|
-
700: '#374151',
|
|
64
|
-
800: '#1f2937',
|
|
65
|
-
900: '#111827',
|
|
66
|
-
},
|
|
67
|
-
|
|
68
|
-
purple: {
|
|
69
|
-
50: '#f8fafc',
|
|
70
|
-
100: '#f1f5f9',
|
|
71
|
-
200: '#e2e8f0',
|
|
72
|
-
300: '#cbd5e1',
|
|
73
|
-
400: '#94a3b8',
|
|
74
|
-
500: '#64748b',
|
|
75
|
-
600: '#475569',
|
|
76
|
-
700: '#334155',
|
|
77
|
-
800: '#1e293b',
|
|
78
|
-
900: '#0f172a',
|
|
79
|
-
},
|
|
80
|
-
|
|
81
|
-
pink: {
|
|
82
|
-
50: '#fdf2f8',
|
|
83
|
-
100: '#fce7f3',
|
|
84
|
-
200: '#fbcfe8',
|
|
85
|
-
300: '#f9a8d4',
|
|
86
|
-
400: '#f472b6',
|
|
87
|
-
500: '#ec4899',
|
|
88
|
-
600: '#db2777',
|
|
89
|
-
700: '#be185d',
|
|
90
|
-
800: '#9d174d',
|
|
91
|
-
900: '#831843',
|
|
92
|
-
},
|
|
93
|
-
|
|
94
|
-
cyan: {
|
|
95
|
-
50: '#ecfeff',
|
|
96
|
-
100: '#cffafe',
|
|
97
|
-
200: '#a5f3fc',
|
|
98
|
-
300: '#67e8f9',
|
|
99
|
-
400: '#22d3ee',
|
|
100
|
-
500: '#06b6d4',
|
|
101
|
-
600: '#0891b2',
|
|
102
|
-
700: '#0e7490',
|
|
103
|
-
800: '#155e75',
|
|
104
|
-
900: '#164e63',
|
|
105
|
-
},
|
|
106
|
-
} as const;
|
|
107
|
-
|
|
108
|
-
// Intent system - maps semantic meanings to color palettes
|
|
109
|
-
export const intentMappings = {
|
|
110
|
-
primary: {
|
|
111
|
-
palette: 'blue' as const,
|
|
112
|
-
main: 500 as const,
|
|
113
|
-
on: '#ffffff',
|
|
114
|
-
container: 100 as const,
|
|
115
|
-
onContainer: 800 as const,
|
|
116
|
-
light: 200 as const,
|
|
117
|
-
dark: 700 as const,
|
|
118
|
-
border: 300 as const,
|
|
119
|
-
},
|
|
120
|
-
|
|
121
|
-
success: {
|
|
122
|
-
palette: 'green' as const,
|
|
123
|
-
main: 500 as const,
|
|
124
|
-
on: '#ffffff',
|
|
125
|
-
container: 100 as const,
|
|
126
|
-
onContainer: 800 as const,
|
|
127
|
-
light: 200 as const,
|
|
128
|
-
dark: 700 as const,
|
|
129
|
-
border: 300 as const,
|
|
130
|
-
},
|
|
131
|
-
|
|
132
|
-
error: {
|
|
133
|
-
palette: 'red' as const,
|
|
134
|
-
main: 500 as const,
|
|
135
|
-
on: '#ffffff',
|
|
136
|
-
container: 100 as const,
|
|
137
|
-
onContainer: 800 as const,
|
|
138
|
-
light: 200 as const,
|
|
139
|
-
dark: 700 as const,
|
|
140
|
-
border: 300 as const,
|
|
141
|
-
},
|
|
142
|
-
|
|
143
|
-
warning: {
|
|
144
|
-
palette: 'amber' as const,
|
|
145
|
-
main: 500 as const,
|
|
146
|
-
on: '#ffffff',
|
|
147
|
-
container: 100 as const,
|
|
148
|
-
onContainer: 800 as const,
|
|
149
|
-
light: 200 as const,
|
|
150
|
-
dark: 700 as const,
|
|
151
|
-
border: 300 as const,
|
|
152
|
-
},
|
|
153
|
-
|
|
154
|
-
neutral: {
|
|
155
|
-
palette: 'gray' as const,
|
|
156
|
-
main: 500 as const,
|
|
157
|
-
on: '#ffffff',
|
|
158
|
-
container: 100 as const,
|
|
159
|
-
onContainer: 800 as const,
|
|
160
|
-
light: 200 as const,
|
|
161
|
-
dark: 700 as const,
|
|
162
|
-
border: 300 as const,
|
|
163
|
-
},
|
|
164
|
-
|
|
165
|
-
info: {
|
|
166
|
-
palette: 'cyan' as const,
|
|
167
|
-
main: 500 as const,
|
|
168
|
-
on: '#ffffff',
|
|
169
|
-
container: 100 as const,
|
|
170
|
-
onContainer: 800 as const,
|
|
171
|
-
light: 200 as const,
|
|
172
|
-
dark: 700 as const,
|
|
173
|
-
border: 300 as const,
|
|
174
|
-
},
|
|
175
|
-
} as const;
|
|
176
|
-
|
|
177
|
-
// Color system for display components (non-actionable)
|
|
178
|
-
export const colorMappings = {
|
|
179
|
-
// Text colors
|
|
180
|
-
text: {
|
|
181
|
-
primary: 'gray.900' as const,
|
|
182
|
-
secondary: 'gray.600' as const,
|
|
183
|
-
disabled: 'gray.400' as const,
|
|
184
|
-
inverse: '#ffffff',
|
|
185
|
-
},
|
|
186
|
-
|
|
187
|
-
// Surface colors
|
|
188
|
-
surface: {
|
|
189
|
-
primary: '#ffffff',
|
|
190
|
-
secondary: 'gray.50' as const,
|
|
191
|
-
tertiary: 'gray.100' as const,
|
|
192
|
-
inverse: 'gray.900' as const,
|
|
193
|
-
},
|
|
194
|
-
|
|
195
|
-
// Border colors
|
|
196
|
-
border: {
|
|
197
|
-
primary: 'gray.200' as const,
|
|
198
|
-
secondary: 'gray.300' as const,
|
|
199
|
-
focus: 'primary' as const, // References intent.primary.main
|
|
200
|
-
},
|
|
201
|
-
|
|
202
|
-
// Direct color references (for backward compatibility and special cases)
|
|
203
|
-
primary: 'primary' as const, // References intent.primary.main
|
|
204
|
-
success: 'success' as const, // References intent.success.main
|
|
205
|
-
error: 'error' as const, // References intent.error.main
|
|
206
|
-
warning: 'warning' as const, // References intent.warning.main
|
|
207
|
-
neutral: 'neutral' as const, // References intent.neutral.main
|
|
208
|
-
info: 'info' as const, // References intent.info.main
|
|
209
|
-
} as const;
|
|
210
|
-
|
|
211
|
-
// Dark theme overrides
|
|
212
|
-
export const darkThemeOverrides = {
|
|
213
|
-
colorMappings: {
|
|
214
|
-
text: {
|
|
215
|
-
primary: 'gray.50' as const,
|
|
216
|
-
secondary: 'gray.300' as const,
|
|
217
|
-
disabled: 'gray.500' as const,
|
|
218
|
-
inverse: 'gray.900' as const,
|
|
219
|
-
},
|
|
220
|
-
|
|
221
|
-
surface: {
|
|
222
|
-
primary: 'gray.900' as const,
|
|
223
|
-
secondary: 'gray.800' as const,
|
|
224
|
-
tertiary: 'gray.700' as const,
|
|
225
|
-
inverse: '#ffffff',
|
|
226
|
-
},
|
|
227
|
-
|
|
228
|
-
border: {
|
|
229
|
-
primary: 'gray.700' as const,
|
|
230
|
-
secondary: 'gray.600' as const,
|
|
231
|
-
focus: 'primary' as const,
|
|
232
|
-
},
|
|
233
|
-
},
|
|
234
|
-
|
|
235
|
-
// Dark theme intent adjustments
|
|
236
|
-
intentMappings: {
|
|
237
|
-
primary: {
|
|
238
|
-
palette: 'blue' as const,
|
|
239
|
-
main: 400 as const, // Lighter blue for dark theme
|
|
240
|
-
on: 'gray.900' as const, // Dark text on light blue
|
|
241
|
-
container: 900 as const, // Very dark blue container
|
|
242
|
-
onContainer: 100 as const, // Light text on dark container
|
|
243
|
-
light: 800 as const,
|
|
244
|
-
dark: 300 as const,
|
|
245
|
-
border: 400 as const,
|
|
246
|
-
},
|
|
247
|
-
|
|
248
|
-
success: {
|
|
249
|
-
palette: 'green' as const,
|
|
250
|
-
main: 400 as const,
|
|
251
|
-
on: 'gray.900' as const,
|
|
252
|
-
container: 900 as const,
|
|
253
|
-
onContainer: 100 as const,
|
|
254
|
-
light: 800 as const,
|
|
255
|
-
dark: 300 as const,
|
|
256
|
-
border: 400 as const,
|
|
257
|
-
},
|
|
258
|
-
|
|
259
|
-
error: {
|
|
260
|
-
palette: 'red' as const,
|
|
261
|
-
main: 400 as const,
|
|
262
|
-
on: 'gray.900' as const,
|
|
263
|
-
container: 900 as const,
|
|
264
|
-
onContainer: 100 as const,
|
|
265
|
-
light: 800 as const,
|
|
266
|
-
dark: 300 as const,
|
|
267
|
-
border: 400 as const,
|
|
268
|
-
},
|
|
269
|
-
|
|
270
|
-
warning: {
|
|
271
|
-
palette: 'amber' as const,
|
|
272
|
-
main: 400 as const,
|
|
273
|
-
on: 'gray.900' as const,
|
|
274
|
-
container: 900 as const,
|
|
275
|
-
onContainer: 100 as const,
|
|
276
|
-
light: 800 as const,
|
|
277
|
-
dark: 300 as const,
|
|
278
|
-
border: 400 as const,
|
|
279
|
-
},
|
|
280
|
-
|
|
281
|
-
neutral: {
|
|
282
|
-
palette: 'gray' as const,
|
|
283
|
-
main: 400 as const,
|
|
284
|
-
on: 'gray.900' as const,
|
|
285
|
-
container: 800 as const,
|
|
286
|
-
onContainer: 100 as const,
|
|
287
|
-
light: 700 as const,
|
|
288
|
-
dark: 300 as const,
|
|
289
|
-
border: 400 as const,
|
|
290
|
-
},
|
|
291
|
-
|
|
292
|
-
info: {
|
|
293
|
-
palette: 'cyan' as const,
|
|
294
|
-
main: 400 as const,
|
|
295
|
-
on: 'gray.900' as const,
|
|
296
|
-
container: 900 as const,
|
|
297
|
-
onContainer: 100 as const,
|
|
298
|
-
light: 800 as const,
|
|
299
|
-
dark: 300 as const,
|
|
300
|
-
border: 400 as const,
|
|
301
|
-
},
|
|
302
|
-
},
|
|
303
|
-
} as const;
|
|
304
|
-
|
|
305
|
-
// Import variant types
|
|
306
|
-
import type { IntentVariant, ColorVariant, ColorPaletteShade } from './variants';
|
|
307
|
-
|
|
308
|
-
// Export types for TypeScript
|
|
309
|
-
export type ColorPalette = keyof typeof colorPalettes;
|
|
310
|
-
export type ColorShade = keyof typeof colorPalettes.blue;
|
|
311
|
-
export type IntentName = keyof typeof intentMappings;
|
|
312
|
-
export type ColorName = keyof typeof colorMappings;
|
|
313
|
-
|
|
314
|
-
// Ensure our variant types match the actual data structures
|
|
1
|
+
// Base color palettes - these are the source of truth for all colors
|
|
2
|
+
export const colorPalettes = {
|
|
3
|
+
blue: {
|
|
4
|
+
50: '#eff6ff',
|
|
5
|
+
100: '#dbeafe',
|
|
6
|
+
200: '#bfdbfe',
|
|
7
|
+
300: '#93c5fd',
|
|
8
|
+
400: '#60a5fa',
|
|
9
|
+
500: '#3b82f6',
|
|
10
|
+
600: '#2563eb',
|
|
11
|
+
700: '#1d4ed8',
|
|
12
|
+
800: '#1e40af',
|
|
13
|
+
900: '#1e3a8a',
|
|
14
|
+
},
|
|
15
|
+
|
|
16
|
+
green: {
|
|
17
|
+
50: '#f0fdf4',
|
|
18
|
+
100: '#dcfce7',
|
|
19
|
+
200: '#bbf7d0',
|
|
20
|
+
300: '#86efac',
|
|
21
|
+
400: '#4ade80',
|
|
22
|
+
500: '#22c55e',
|
|
23
|
+
600: '#16a34a',
|
|
24
|
+
700: '#15803d',
|
|
25
|
+
800: '#166534',
|
|
26
|
+
900: '#14532d',
|
|
27
|
+
},
|
|
28
|
+
|
|
29
|
+
red: {
|
|
30
|
+
50: '#fef2f2',
|
|
31
|
+
100: '#fee2e2',
|
|
32
|
+
200: '#fecaca',
|
|
33
|
+
300: '#fca5a5',
|
|
34
|
+
400: '#f87171',
|
|
35
|
+
500: '#ef4444',
|
|
36
|
+
600: '#dc2626',
|
|
37
|
+
700: '#b91c1c',
|
|
38
|
+
800: '#991b1b',
|
|
39
|
+
900: '#7f1d1d',
|
|
40
|
+
},
|
|
41
|
+
|
|
42
|
+
amber: {
|
|
43
|
+
50: '#fffbeb',
|
|
44
|
+
100: '#fef3c7',
|
|
45
|
+
200: '#fde68a',
|
|
46
|
+
300: '#fcd34d',
|
|
47
|
+
400: '#fbbf24',
|
|
48
|
+
500: '#f59e0b',
|
|
49
|
+
600: '#d97706',
|
|
50
|
+
700: '#b45309',
|
|
51
|
+
800: '#92400e',
|
|
52
|
+
900: '#78350f',
|
|
53
|
+
},
|
|
54
|
+
|
|
55
|
+
gray: {
|
|
56
|
+
50: '#f9fafb',
|
|
57
|
+
100: '#f3f4f6',
|
|
58
|
+
200: '#e5e7eb',
|
|
59
|
+
300: '#d1d5db',
|
|
60
|
+
400: '#9ca3af',
|
|
61
|
+
500: '#6b7280',
|
|
62
|
+
600: '#4b5563',
|
|
63
|
+
700: '#374151',
|
|
64
|
+
800: '#1f2937',
|
|
65
|
+
900: '#111827',
|
|
66
|
+
},
|
|
67
|
+
|
|
68
|
+
purple: {
|
|
69
|
+
50: '#f8fafc',
|
|
70
|
+
100: '#f1f5f9',
|
|
71
|
+
200: '#e2e8f0',
|
|
72
|
+
300: '#cbd5e1',
|
|
73
|
+
400: '#94a3b8',
|
|
74
|
+
500: '#64748b',
|
|
75
|
+
600: '#475569',
|
|
76
|
+
700: '#334155',
|
|
77
|
+
800: '#1e293b',
|
|
78
|
+
900: '#0f172a',
|
|
79
|
+
},
|
|
80
|
+
|
|
81
|
+
pink: {
|
|
82
|
+
50: '#fdf2f8',
|
|
83
|
+
100: '#fce7f3',
|
|
84
|
+
200: '#fbcfe8',
|
|
85
|
+
300: '#f9a8d4',
|
|
86
|
+
400: '#f472b6',
|
|
87
|
+
500: '#ec4899',
|
|
88
|
+
600: '#db2777',
|
|
89
|
+
700: '#be185d',
|
|
90
|
+
800: '#9d174d',
|
|
91
|
+
900: '#831843',
|
|
92
|
+
},
|
|
93
|
+
|
|
94
|
+
cyan: {
|
|
95
|
+
50: '#ecfeff',
|
|
96
|
+
100: '#cffafe',
|
|
97
|
+
200: '#a5f3fc',
|
|
98
|
+
300: '#67e8f9',
|
|
99
|
+
400: '#22d3ee',
|
|
100
|
+
500: '#06b6d4',
|
|
101
|
+
600: '#0891b2',
|
|
102
|
+
700: '#0e7490',
|
|
103
|
+
800: '#155e75',
|
|
104
|
+
900: '#164e63',
|
|
105
|
+
},
|
|
106
|
+
} as const;
|
|
107
|
+
|
|
108
|
+
// Intent system - maps semantic meanings to color palettes
|
|
109
|
+
export const intentMappings = {
|
|
110
|
+
primary: {
|
|
111
|
+
palette: 'blue' as const,
|
|
112
|
+
main: 500 as const,
|
|
113
|
+
on: '#ffffff',
|
|
114
|
+
container: 100 as const,
|
|
115
|
+
onContainer: 800 as const,
|
|
116
|
+
light: 200 as const,
|
|
117
|
+
dark: 700 as const,
|
|
118
|
+
border: 300 as const,
|
|
119
|
+
},
|
|
120
|
+
|
|
121
|
+
success: {
|
|
122
|
+
palette: 'green' as const,
|
|
123
|
+
main: 500 as const,
|
|
124
|
+
on: '#ffffff',
|
|
125
|
+
container: 100 as const,
|
|
126
|
+
onContainer: 800 as const,
|
|
127
|
+
light: 200 as const,
|
|
128
|
+
dark: 700 as const,
|
|
129
|
+
border: 300 as const,
|
|
130
|
+
},
|
|
131
|
+
|
|
132
|
+
error: {
|
|
133
|
+
palette: 'red' as const,
|
|
134
|
+
main: 500 as const,
|
|
135
|
+
on: '#ffffff',
|
|
136
|
+
container: 100 as const,
|
|
137
|
+
onContainer: 800 as const,
|
|
138
|
+
light: 200 as const,
|
|
139
|
+
dark: 700 as const,
|
|
140
|
+
border: 300 as const,
|
|
141
|
+
},
|
|
142
|
+
|
|
143
|
+
warning: {
|
|
144
|
+
palette: 'amber' as const,
|
|
145
|
+
main: 500 as const,
|
|
146
|
+
on: '#ffffff',
|
|
147
|
+
container: 100 as const,
|
|
148
|
+
onContainer: 800 as const,
|
|
149
|
+
light: 200 as const,
|
|
150
|
+
dark: 700 as const,
|
|
151
|
+
border: 300 as const,
|
|
152
|
+
},
|
|
153
|
+
|
|
154
|
+
neutral: {
|
|
155
|
+
palette: 'gray' as const,
|
|
156
|
+
main: 500 as const,
|
|
157
|
+
on: '#ffffff',
|
|
158
|
+
container: 100 as const,
|
|
159
|
+
onContainer: 800 as const,
|
|
160
|
+
light: 200 as const,
|
|
161
|
+
dark: 700 as const,
|
|
162
|
+
border: 300 as const,
|
|
163
|
+
},
|
|
164
|
+
|
|
165
|
+
info: {
|
|
166
|
+
palette: 'cyan' as const,
|
|
167
|
+
main: 500 as const,
|
|
168
|
+
on: '#ffffff',
|
|
169
|
+
container: 100 as const,
|
|
170
|
+
onContainer: 800 as const,
|
|
171
|
+
light: 200 as const,
|
|
172
|
+
dark: 700 as const,
|
|
173
|
+
border: 300 as const,
|
|
174
|
+
},
|
|
175
|
+
} as const;
|
|
176
|
+
|
|
177
|
+
// Color system for display components (non-actionable)
|
|
178
|
+
export const colorMappings = {
|
|
179
|
+
// Text colors
|
|
180
|
+
text: {
|
|
181
|
+
primary: 'gray.900' as const,
|
|
182
|
+
secondary: 'gray.600' as const,
|
|
183
|
+
disabled: 'gray.400' as const,
|
|
184
|
+
inverse: '#ffffff',
|
|
185
|
+
},
|
|
186
|
+
|
|
187
|
+
// Surface colors
|
|
188
|
+
surface: {
|
|
189
|
+
primary: '#ffffff',
|
|
190
|
+
secondary: 'gray.50' as const,
|
|
191
|
+
tertiary: 'gray.100' as const,
|
|
192
|
+
inverse: 'gray.900' as const,
|
|
193
|
+
},
|
|
194
|
+
|
|
195
|
+
// Border colors
|
|
196
|
+
border: {
|
|
197
|
+
primary: 'gray.200' as const,
|
|
198
|
+
secondary: 'gray.300' as const,
|
|
199
|
+
focus: 'primary' as const, // References intent.primary.main
|
|
200
|
+
},
|
|
201
|
+
|
|
202
|
+
// Direct color references (for backward compatibility and special cases)
|
|
203
|
+
primary: 'primary' as const, // References intent.primary.main
|
|
204
|
+
success: 'success' as const, // References intent.success.main
|
|
205
|
+
error: 'error' as const, // References intent.error.main
|
|
206
|
+
warning: 'warning' as const, // References intent.warning.main
|
|
207
|
+
neutral: 'neutral' as const, // References intent.neutral.main
|
|
208
|
+
info: 'info' as const, // References intent.info.main
|
|
209
|
+
} as const;
|
|
210
|
+
|
|
211
|
+
// Dark theme overrides
|
|
212
|
+
export const darkThemeOverrides = {
|
|
213
|
+
colorMappings: {
|
|
214
|
+
text: {
|
|
215
|
+
primary: 'gray.50' as const,
|
|
216
|
+
secondary: 'gray.300' as const,
|
|
217
|
+
disabled: 'gray.500' as const,
|
|
218
|
+
inverse: 'gray.900' as const,
|
|
219
|
+
},
|
|
220
|
+
|
|
221
|
+
surface: {
|
|
222
|
+
primary: 'gray.900' as const,
|
|
223
|
+
secondary: 'gray.800' as const,
|
|
224
|
+
tertiary: 'gray.700' as const,
|
|
225
|
+
inverse: '#ffffff',
|
|
226
|
+
},
|
|
227
|
+
|
|
228
|
+
border: {
|
|
229
|
+
primary: 'gray.700' as const,
|
|
230
|
+
secondary: 'gray.600' as const,
|
|
231
|
+
focus: 'primary' as const,
|
|
232
|
+
},
|
|
233
|
+
},
|
|
234
|
+
|
|
235
|
+
// Dark theme intent adjustments
|
|
236
|
+
intentMappings: {
|
|
237
|
+
primary: {
|
|
238
|
+
palette: 'blue' as const,
|
|
239
|
+
main: 400 as const, // Lighter blue for dark theme
|
|
240
|
+
on: 'gray.900' as const, // Dark text on light blue
|
|
241
|
+
container: 900 as const, // Very dark blue container
|
|
242
|
+
onContainer: 100 as const, // Light text on dark container
|
|
243
|
+
light: 800 as const,
|
|
244
|
+
dark: 300 as const,
|
|
245
|
+
border: 400 as const,
|
|
246
|
+
},
|
|
247
|
+
|
|
248
|
+
success: {
|
|
249
|
+
palette: 'green' as const,
|
|
250
|
+
main: 400 as const,
|
|
251
|
+
on: 'gray.900' as const,
|
|
252
|
+
container: 900 as const,
|
|
253
|
+
onContainer: 100 as const,
|
|
254
|
+
light: 800 as const,
|
|
255
|
+
dark: 300 as const,
|
|
256
|
+
border: 400 as const,
|
|
257
|
+
},
|
|
258
|
+
|
|
259
|
+
error: {
|
|
260
|
+
palette: 'red' as const,
|
|
261
|
+
main: 400 as const,
|
|
262
|
+
on: 'gray.900' as const,
|
|
263
|
+
container: 900 as const,
|
|
264
|
+
onContainer: 100 as const,
|
|
265
|
+
light: 800 as const,
|
|
266
|
+
dark: 300 as const,
|
|
267
|
+
border: 400 as const,
|
|
268
|
+
},
|
|
269
|
+
|
|
270
|
+
warning: {
|
|
271
|
+
palette: 'amber' as const,
|
|
272
|
+
main: 400 as const,
|
|
273
|
+
on: 'gray.900' as const,
|
|
274
|
+
container: 900 as const,
|
|
275
|
+
onContainer: 100 as const,
|
|
276
|
+
light: 800 as const,
|
|
277
|
+
dark: 300 as const,
|
|
278
|
+
border: 400 as const,
|
|
279
|
+
},
|
|
280
|
+
|
|
281
|
+
neutral: {
|
|
282
|
+
palette: 'gray' as const,
|
|
283
|
+
main: 400 as const,
|
|
284
|
+
on: 'gray.900' as const,
|
|
285
|
+
container: 800 as const,
|
|
286
|
+
onContainer: 100 as const,
|
|
287
|
+
light: 700 as const,
|
|
288
|
+
dark: 300 as const,
|
|
289
|
+
border: 400 as const,
|
|
290
|
+
},
|
|
291
|
+
|
|
292
|
+
info: {
|
|
293
|
+
palette: 'cyan' as const,
|
|
294
|
+
main: 400 as const,
|
|
295
|
+
on: 'gray.900' as const,
|
|
296
|
+
container: 900 as const,
|
|
297
|
+
onContainer: 100 as const,
|
|
298
|
+
light: 800 as const,
|
|
299
|
+
dark: 300 as const,
|
|
300
|
+
border: 400 as const,
|
|
301
|
+
},
|
|
302
|
+
},
|
|
303
|
+
} as const;
|
|
304
|
+
|
|
305
|
+
// Import variant types
|
|
306
|
+
import type { IntentVariant, ColorVariant, ColorPaletteShade } from './variants';
|
|
307
|
+
|
|
308
|
+
// Export types for TypeScript
|
|
309
|
+
export type ColorPalette = keyof typeof colorPalettes;
|
|
310
|
+
export type ColorShade = keyof typeof colorPalettes.blue;
|
|
311
|
+
export type IntentName = keyof typeof intentMappings;
|
|
312
|
+
export type ColorName = keyof typeof colorMappings;
|
|
313
|
+
|
|
314
|
+
// Ensure our variant types match the actual data structures
|
|
315
315
|
export type { IntentVariant, ColorVariant, ColorPaletteShade };
|