@techv/design-system 0.1.2 → 0.1.4

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 CHANGED
@@ -27,7 +27,6 @@ pnpm add @techv/design-system styled-components
27
27
  Import the global CSS in your app entry point. This loads the CSS custom properties (design tokens) and dark mode support.
28
28
 
29
29
  ```tsx
30
- // index.tsx or App.tsx
31
30
  import '@techv/design-system/styles.css';
32
31
  ```
33
32
 
@@ -130,44 +129,238 @@ import { IconButton } from '@techv/design-system';
130
129
 
131
130
  ## Design Tokens
132
131
 
132
+ ### Setup
133
+
134
+ ```tsx
135
+ import '@techv/design-system/styles.css';
136
+ ```
137
+
138
+ ### Available exports
139
+
140
+ | Export | Purpose | Example |
141
+ |---|---|---|
142
+ | `colors` | Full color palette | `colors.red[500]` → `'#EF4444'` |
143
+ | `bg` | Background colors (alias of colors) | `bg.indigo[50]` → `'#EEF2FF'` |
144
+ | `tx` | Text colors (alias of colors) | `tx.gray[700]` → `'#374151'` |
145
+ | `bd` | Border colors (alias of colors) | `bd.gray[200]` → `'#E5E7EB'` |
146
+ | `fl` | SVG fill colors (alias of colors) | `fl.green[400]` → `'#4ADE80'` |
147
+ | `spacing` | 4px-base numeric scale | `spacing[4]` → `'16px'` |
148
+ | `fs` | Font sizes | `fs.sm` → `'14px'` |
149
+ | `fw` | Font weights | `fw[7]` → `'700'` |
150
+ | `lh` | Line heights | `lh.base` → `1.5` |
151
+ | `ta` | Text alignment | `ta.c` → `'center'` |
152
+ | `br` | Border radius | `br.full` → `'9999px'` |
153
+ | `bw` | Border widths | `bw[1]` → `'1px'` |
154
+ | `sh` | Shadows | `sh[3]` → md elevation |
155
+ | `op` | Opacity | `op[50]` → `'0.5'` |
156
+ | `duration` | Animation durations | `duration.normal` → `'200ms'` |
157
+ | `ease` | Easing curves | `ease.standard` |
158
+
133
159
  ### CSS Custom Properties
134
160
 
135
- Import `styles.css` to get all tokens as CSS variables on `:root`, usable anywhere in your app.
161
+ All tokens are also available as CSS variables:
136
162
 
137
163
  ```css
138
- .my-component {
139
- background-color: var(--color-brand-500);
140
- padding: var(--space-md);
141
- border-radius: var(--radius-lg);
142
- }
164
+ /* Colors */
165
+ background-color: var(--indigo-500);
166
+ color: var(--gray-700);
167
+ border-color: var(--red-200);
168
+
169
+ /* Spacing */
170
+ padding: var(--spacing-4); /* 16px */
171
+ gap: var(--spacing-2); /* 8px */
172
+
173
+ /* Typography */
174
+ font-size: var(--fs-lg); /* 18px */
175
+ font-weight: var(--fw-6); /* 600 */
176
+
177
+ /* Border radius / shadow */
178
+ border-radius: var(--br-lg); /* 8px */
179
+ box-shadow: var(--sh-3);
143
180
  ```
144
181
 
145
182
  ### JavaScript Tokens
146
183
 
147
- Use typed token values directly in styled-components or inline styles.
184
+ #### Inline styles
185
+
186
+ Use tokens directly in React `style` props:
187
+
188
+ ```tsx
189
+ import { bg, tx, spacing, br, fs, fw } from '@techv/design-system';
190
+
191
+ function Badge({ children }: { children: React.ReactNode }) {
192
+ return (
193
+ <span
194
+ style={{
195
+ backgroundColor: bg.indigo[50],
196
+ color: tx.indigo[700],
197
+ padding: `${spacing[1]} ${spacing[2]}`,
198
+ borderRadius: br.full,
199
+ fontSize: fs.xs,
200
+ fontWeight: fw[5],
201
+ }}
202
+ >
203
+ {children}
204
+ </span>
205
+ );
206
+ }
207
+ ```
208
+
209
+ #### Alert / status banner
210
+
211
+ ```tsx
212
+ import { bg, tx, bd, spacing, br, fs, bw } from '@techv/design-system';
213
+
214
+ type AlertType = 'success' | 'danger' | 'warning';
215
+
216
+ const alertMap: Record<AlertType, React.CSSProperties> = {
217
+ success: { backgroundColor: bg.green[50], color: tx.green[700], border: `${bw[1]} solid ${bd.green[300]}` },
218
+ danger: { backgroundColor: bg.red[50], color: tx.red[700], border: `${bw[1]} solid ${bd.red[300]}` },
219
+ warning: { backgroundColor: bg.amber[50], color: tx.amber[700], border: `${bw[1]} solid ${bd.amber[300]}` },
220
+ };
221
+
222
+ function Alert({ type, message }: { type: AlertType; message: string }) {
223
+ return (
224
+ <div
225
+ role="alert"
226
+ style={{
227
+ ...alertMap[type],
228
+ padding: `${spacing[2]} ${spacing[4]}`,
229
+ borderRadius: br.md,
230
+ fontSize: fs.sm,
231
+ }}
232
+ >
233
+ {message}
234
+ </div>
235
+ );
236
+ }
237
+
238
+ <Alert type="success" message="Profile saved!" />
239
+ <Alert type="danger" message="Something went wrong." />
240
+ <Alert type="warning" message="Your session expires soon." />
241
+ ```
242
+
243
+ #### Card component
148
244
 
149
245
  ```tsx
150
- import { tokens, colors, spacing, radii } from '@techv/design-system';
246
+ import { bg, tx, bd, spacing, br, sh, fs, fw, bw } from '@techv/design-system';
247
+
248
+ function Card({ title, body }: { title: string; body: string }) {
249
+ return (
250
+ <div
251
+ style={{
252
+ backgroundColor: bg.white,
253
+ border: `${bw[1]} solid ${bd.gray[200]}`,
254
+ borderRadius: br['2xl'],
255
+ padding: spacing[8],
256
+ boxShadow: sh[3],
257
+ maxWidth: '400px',
258
+ }}
259
+ >
260
+ <h2
261
+ style={{
262
+ margin: 0,
263
+ fontSize: fs.lg,
264
+ fontWeight: fw[6],
265
+ color: tx.gray[900],
266
+ marginBottom: spacing[2],
267
+ }}
268
+ >
269
+ {title}
270
+ </h2>
271
+ <p
272
+ style={{
273
+ margin: 0,
274
+ fontSize: fs.sm,
275
+ color: tx.gray[500],
276
+ lineHeight: 1.6,
277
+ }}
278
+ >
279
+ {body}
280
+ </p>
281
+ </div>
282
+ );
283
+ }
284
+ ```
151
285
 
152
- // Full structured token object
153
- tokens.color.brand[500] // '#4F46E5'
154
- tokens.space.md // 16
155
- tokens.radius.lg // 8
156
- tokens.shadow.md // '0 4px 6px rgba(0,0,0,0.07)...'
157
- tokens.duration.normal // 200
158
- tokens.font.text // 'Inter'
159
- tokens.fontSize.h1 // '36px'
286
+ #### Tag
160
287
 
161
- // Flat named exports (convenience)
162
- colors.brand500 // '#4F46E5'
163
- colors.textPrimary // '#111827'
164
- colors.border // '#E5E7EB'
288
+ ```tsx
289
+ import { bg, tx, bd, spacing, br, fs, fw, bw } from '@techv/design-system';
290
+
291
+ function Tag({ label }: { label: string }) {
292
+ return (
293
+ <span
294
+ style={{
295
+ backgroundColor: bg.gray[100],
296
+ color: tx.gray[700],
297
+ padding: `${spacing[1]} ${spacing[2]}`,
298
+ borderRadius: br.md,
299
+ border: `${bw[1]} solid ${bd.gray[200]}`,
300
+ fontSize: fs.xs,
301
+ fontWeight: fw[5],
302
+ }}
303
+ >
304
+ {label}
305
+ </span>
306
+ );
307
+ }
308
+ ```
165
309
 
166
- spacing.md // '16px'
167
- spacing.lg // '24px'
310
+ #### Animated element
168
311
 
169
- radii.sm // '4px'
170
- radii.full // '9999px'
312
+ ```tsx
313
+ import { bg, br, spacing, duration, ease } from '@techv/design-system';
314
+
315
+ function FadeInBox({ children }: { children: React.ReactNode }) {
316
+ return (
317
+ <div
318
+ style={{
319
+ padding: spacing[6],
320
+ backgroundColor: bg.indigo[50],
321
+ borderRadius: br.xl,
322
+ transition: `opacity ${duration.normal} ${ease.standard}`,
323
+ }}
324
+ >
325
+ {children}
326
+ </div>
327
+ );
328
+ }
329
+ ```
330
+
331
+ #### Quick reference
332
+
333
+ ```tsx
334
+ import { bg, tx, bd, fl, spacing, fs, fw, lh, ta, br, bw, sh, op, duration, ease } from '@techv/design-system';
335
+
336
+ bg.indigo[50]
337
+ tx.gray[700]
338
+ bd.gray[200]
339
+ fl.green[400]
340
+ bg.red[500]
341
+ bg.white
342
+ bg.black
343
+
344
+ spacing[1]
345
+ spacing[2]
346
+ spacing[4]
347
+ spacing[6]
348
+ spacing[8]
349
+ spacing.full
350
+
351
+ fs.xs
352
+ fs.lg
353
+ fw[4]
354
+ lh.tight
355
+ ta.c
356
+
357
+ br.sm
358
+ bw[1]
359
+ sh[1]
360
+ op[50]
361
+
362
+ duration.fast
363
+ ease.standard
171
364
  ```
172
365
 
173
366
  ### Token Reference
@@ -216,10 +409,8 @@ radii.full // '9999px'
216
409
  The library ships with a built-in dark mode. Toggle it by setting `data-theme="dark"` on any ancestor element (typically `<html>` or `<body>`).
217
410
 
218
411
  ```tsx
219
- // Enable dark mode
220
412
  document.documentElement.setAttribute('data-theme', 'dark');
221
413
 
222
- // Disable dark mode
223
414
  document.documentElement.removeAttribute('data-theme');
224
415
  ```
225
416
 
@@ -241,13 +432,24 @@ import type { ButtonProps, IconButtonProps } from '@techv/design-system';
241
432
 
242
433
  ```tsx
243
434
  import styled from 'styled-components';
244
- import { tokens } from '@techv/design-system';
435
+ import { bg, bd, tx, spacing, br, sh, fs, fw, bw } from '@techv/design-system';
245
436
 
246
437
  const Card = styled.div`
247
- background: ${tokens.semantic.surface};
248
- border: 1px solid ${tokens.semantic.border};
249
- border-radius: ${tokens.radius.xl}px;
250
- padding: ${tokens.space.lg}px;
251
- box-shadow: ${tokens.shadow.md};
438
+ background: ${bg.white};
439
+ border: ${bw[1]} solid ${bd.gray[200]};
440
+ border-radius: ${br['2xl']};
441
+ padding: ${spacing[8]};
442
+ box-shadow: ${sh[3]};
443
+ `;
444
+
445
+ const Heading = styled.h2`
446
+ font-size: ${fs.lg};
447
+ font-weight: ${fw[6]};
448
+ color: ${tx.gray[900]};
449
+ `;
450
+
451
+ const Body = styled.p`
452
+ font-size: ${fs.sm};
453
+ color: ${tx.gray[500]};
252
454
  `;
253
455
  ```
package/dist/cjs/index.js CHANGED
@@ -5,10 +5,24 @@ var Button = require('./ui/dist/esm/components/Button/Button.js');
5
5
 
6
6
 
7
7
 
8
+ exports.bd = index.bd;
9
+ exports.bg = index.bg;
10
+ exports.br = index.br;
11
+ exports.bw = index.bw;
8
12
  exports.colors = index.colors;
13
+ exports.duration = index.duration;
14
+ exports.ease = index.ease;
15
+ exports.fl = index.fl;
16
+ exports.fs = index.fs;
17
+ exports.fw = index.fw;
18
+ exports.lh = index.lh;
19
+ exports.op = index.op;
9
20
  exports.radii = index.radii;
21
+ exports.sh = index.sh;
10
22
  exports.spacing = index.spacing;
23
+ exports.ta = index.ta;
11
24
  exports.tokens = index.tokens;
25
+ exports.tx = index.tx;
12
26
  exports.Button = Button.Button;
13
27
  exports.IconButton = Button.IconButton;
14
28
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,32 +1,166 @@
1
1
  'use strict';
2
2
 
3
+ const palette = {
4
+ red: { 50: '#FEF2F2', 100: '#FEE2E2', 200: '#FECACA', 300: '#FCA5A5', 400: '#F87171', 500: '#EF4444', 600: '#DC2626', 700: '#B91C1C', 800: '#991B1B', 900: '#7F1D1D' },
5
+ orange: { 50: '#FFF7ED', 100: '#FFEDD5', 200: '#FED7AA', 300: '#FDBA74', 400: '#FB923C', 500: '#F97316', 600: '#EA580C', 700: '#C2410C', 800: '#9A3412', 900: '#7C2D12' },
6
+ amber: { 50: '#FFFBEB', 100: '#FEF3C7', 200: '#FDE68A', 300: '#FCD34D', 400: '#FBBF24', 500: '#F59E0B', 600: '#D97706', 700: '#B45309', 800: '#92400E', 900: '#78350F' },
7
+ yellow: { 50: '#FEFCE8', 100: '#FEF9C3', 200: '#FEF08A', 300: '#FDE047', 400: '#FACC15', 500: '#EAB308', 600: '#CA8A04', 700: '#A16207', 800: '#854D0E', 900: '#713F12' },
8
+ lime: { 50: '#F7FEE7', 100: '#ECFCCB', 200: '#D9F99D', 300: '#BEF264', 400: '#A3E635', 500: '#84CC16', 600: '#65A30D', 700: '#4D7C0F', 800: '#3F6212', 900: '#365314' },
9
+ green: { 50: '#F0FDF4', 100: '#DCFCE7', 200: '#BBF7D0', 300: '#86EFAC', 400: '#4ADE80', 500: '#22C55E', 600: '#16A34A', 700: '#15803D', 800: '#166534', 900: '#14532D' },
10
+ teal: { 50: '#F0FDFA', 100: '#CCFBF1', 200: '#99F6E4', 300: '#5EEAD4', 400: '#2DD4BF', 500: '#14B8A6', 600: '#0D9488', 700: '#0F766E', 800: '#115E59', 900: '#134E4A' },
11
+ cyan: { 50: '#ECFEFF', 100: '#CFFAFE', 200: '#A5F3FC', 300: '#67E8F9', 400: '#22D3EE', 500: '#06B6D4', 600: '#0891B2', 700: '#0E7490', 800: '#155E75', 900: '#164E63' },
12
+ sky: { 50: '#F0F9FF', 100: '#E0F2FE', 200: '#BAE6FD', 300: '#7DD3FC', 400: '#38BDF8', 500: '#0EA5E9', 600: '#0284C7', 700: '#0369A1', 800: '#075985', 900: '#0C4A6E' },
13
+ blue: { 50: '#EFF6FF', 100: '#DBEAFE', 200: '#BFDBFE', 300: '#93C5FD', 400: '#60A5FA', 500: '#3B82F6', 600: '#2563EB', 700: '#1D4ED8', 800: '#1E40AF', 900: '#1E3A8A' },
14
+ indigo: { 50: '#EEF2FF', 100: '#E0E7FF', 200: '#C7D2FE', 300: '#A5B4FC', 400: '#818CF8', 500: '#6366F1', 600: '#4F46E5', 700: '#4338CA', 800: '#3730A3', 900: '#312E81' },
15
+ violet: { 50: '#F5F3FF', 100: '#EDE9FE', 200: '#DDD6FE', 300: '#C4B5FD', 400: '#A78BFA', 500: '#8B5CF6', 600: '#7C3AED', 700: '#6D28D9', 800: '#5B21B6', 900: '#4C1D95' },
16
+ purple: { 50: '#FAF5FF', 100: '#F3E8FF', 200: '#E9D5FF', 300: '#D8B4FE', 400: '#C084FC', 500: '#A855F7', 600: '#9333EA', 700: '#7E22CE', 800: '#6B21A8', 900: '#581C87' },
17
+ fuchsia: { 50: '#FDF4FF', 100: '#FAE8FF', 200: '#F5D0FE', 300: '#F0ABFC', 400: '#E879F9', 500: '#D946EF', 600: '#C026D3', 700: '#A21CAF', 800: '#86198F', 900: '#701A75' },
18
+ pink: { 50: '#FDF2F8', 100: '#FCE7F3', 200: '#FBCFE8', 300: '#F9A8D4', 400: '#F472B6', 500: '#EC4899', 600: '#DB2777', 700: '#BE185D', 800: '#9D174D', 900: '#831843' },
19
+ rose: { 50: '#FFF1F2', 100: '#FFE4E6', 200: '#FECDD3', 300: '#FDA4AF', 400: '#FB7185', 500: '#F43F5E', 600: '#E11D48', 700: '#BE123C', 800: '#9F1239', 900: '#881337' },
20
+ slate: { 50: '#F8FAFC', 100: '#F1F5F9', 200: '#E2E8F0', 300: '#CBD5E1', 400: '#94A3B8', 500: '#64748B', 600: '#475569', 700: '#334155', 800: '#1E293B', 900: '#0F172A' },
21
+ gray: { 50: '#F9FAFB', 100: '#F3F4F6', 200: '#E5E7EB', 300: '#D1D5DB', 400: '#9CA3AF', 500: '#6B7280', 600: '#4B5563', 700: '#374151', 800: '#1F2937', 900: '#111827' },
22
+ zinc: { 50: '#FAFAFA', 100: '#F4F4F5', 200: '#E4E4E7', 300: '#D4D4D8', 400: '#A1A1AA', 500: '#71717A', 600: '#52525B', 700: '#3F3F46', 800: '#27272A', 900: '#18181B' },
23
+ neutral: { 50: '#FAFAFA', 100: '#F5F5F5', 200: '#E5E5E5', 300: '#D4D4D4', 400: '#A3A3A3', 500: '#737373', 600: '#525252', 700: '#404040', 800: '#262626', 900: '#171717' },
24
+ stone: { 50: '#FAFAF9', 100: '#F5F5F4', 200: '#E7E5E4', 300: '#D6D3D1', 400: '#A8A29E', 500: '#78716C', 600: '#57534E', 700: '#44403C', 800: '#292524', 900: '#1C1917' },
25
+ white: '#FFFFFF',
26
+ black: '#000000',
27
+ };
28
+ const colors = palette;
29
+ const bg = palette;
30
+ const tx = palette;
31
+ const bd = palette;
32
+ const fl = palette;
33
+ const spacing = {
34
+ px: '1px',
35
+ 0: '0px',
36
+ 0.5: '2px',
37
+ 1: '4px',
38
+ 1.5: '6px',
39
+ 2: '8px',
40
+ 2.5: '10px',
41
+ 3: '12px',
42
+ 3.5: '14px',
43
+ 4: '16px',
44
+ 5: '20px',
45
+ 6: '24px',
46
+ 7: '28px',
47
+ 8: '32px',
48
+ 9: '36px',
49
+ 10: '40px',
50
+ 11: '44px',
51
+ 12: '48px',
52
+ 14: '56px',
53
+ 16: '64px',
54
+ 20: '80px',
55
+ 24: '96px',
56
+ 28: '112px',
57
+ 32: '128px',
58
+ 36: '144px',
59
+ 40: '160px',
60
+ 48: '192px',
61
+ 56: '224px',
62
+ 64: '256px',
63
+ full: '100%',
64
+ auto: 'auto',
65
+ };
66
+ const fs = {
67
+ xs: '12px',
68
+ sm: '14px',
69
+ md: '16px',
70
+ lg: '18px',
71
+ xl: '20px',
72
+ '2xl': '24px',
73
+ '3xl': '30px',
74
+ '4xl': '36px',
75
+ '5xl': '48px',
76
+ };
77
+ const fw = {
78
+ 3: '300',
79
+ 4: '400',
80
+ 5: '500',
81
+ 6: '600',
82
+ 7: '700',
83
+ 8: '800',
84
+ 9: '900',
85
+ };
86
+ const lh = {
87
+ none: 1,
88
+ tight: 1.25,
89
+ snug: 1.375,
90
+ base: 1.5,
91
+ relaxed: 1.625,
92
+ loose: 2,
93
+ };
94
+ const ta = {
95
+ l: 'left',
96
+ r: 'right',
97
+ c: 'center',
98
+ j: 'justify',
99
+ };
100
+ const br = {
101
+ none: '0px',
102
+ sm: '2px',
103
+ md: '4px',
104
+ lg: '8px',
105
+ xl: '12px',
106
+ '2xl': '16px',
107
+ '3xl': '24px',
108
+ full: '9999px',
109
+ };
110
+ const bw = {
111
+ 0: '0px',
112
+ 1: '1px',
113
+ 2: '2px',
114
+ 4: '4px',
115
+ 8: '8px',
116
+ };
117
+ const sh = {
118
+ none: 'none',
119
+ 1: '0 1px 2px rgba(0,0,0,0.05)',
120
+ 2: '0 1px 3px rgba(0,0,0,0.10), 0 1px 2px rgba(0,0,0,0.06)',
121
+ 3: '0 4px 6px rgba(0,0,0,0.07), 0 2px 4px rgba(0,0,0,0.06)',
122
+ 4: '0 10px 15px rgba(0,0,0,0.08), 0 4px 6px rgba(0,0,0,0.05)',
123
+ 5: '0 20px 25px rgba(0,0,0,0.10), 0 8px 10px rgba(0,0,0,0.04)',
124
+ };
125
+ const op = {
126
+ 0: '0',
127
+ 5: '0.05',
128
+ 10: '0.1',
129
+ 20: '0.2',
130
+ 25: '0.25',
131
+ 30: '0.3',
132
+ 40: '0.4',
133
+ 50: '0.5',
134
+ 60: '0.6',
135
+ 70: '0.7',
136
+ 75: '0.75',
137
+ 80: '0.8',
138
+ 90: '0.9',
139
+ 95: '0.95',
140
+ 100: '1',
141
+ };
142
+ const duration = {
143
+ instant: '50ms',
144
+ fast: '100ms',
145
+ normal: '200ms',
146
+ slow: '300ms',
147
+ deliberate: '500ms',
148
+ };
149
+ const ease = {
150
+ standard: 'cubic-bezier(0.4, 0, 0.2, 1)',
151
+ decelerate: 'cubic-bezier(0, 0, 0.2, 1)',
152
+ accelerate: 'cubic-bezier(0.4, 0, 1, 1)',
153
+ spring: 'cubic-bezier(0.34, 1.56, 0.64, 1)',
154
+ };
155
+ const radii = br;
3
156
  const tokens = {
4
157
  color: {
5
- brand: {
6
- 50: '#EEF2FF',
7
- 100: '#C7D2FE',
8
- 300: '#A5B4FC',
9
- 500: '#4F46E5',
10
- 600: '#4338CA',
11
- 700: '#3730A3',
12
- 900: '#312E81',
13
- },
14
- success: { 50: '#ECFDF5', 500: '#10B981' },
15
- danger: { 50: '#FEF2F2', 500: '#EF4444' },
16
- warning: { 50: '#FFFBEB', 500: '#F59E0B' },
17
- info: { 50: '#EFF6FF', 500: '#3B82F6' },
18
- gray: {
19
- 50: '#F9FAFB',
20
- 100: '#F3F4F6',
21
- 200: '#E5E7EB',
22
- 300: '#D1D5DB',
23
- 400: '#9CA3AF',
24
- 500: '#6B7280',
25
- 600: '#4B5563',
26
- 700: '#374151',
27
- 800: '#1F2937',
28
- 900: '#111827',
29
- },
158
+ brand: palette.indigo,
159
+ success: palette.green,
160
+ danger: palette.red,
161
+ warning: palette.amber,
162
+ info: palette.blue,
163
+ gray: palette.gray,
30
164
  },
31
165
  semantic: {
32
166
  surface: '#FFFFFF',
@@ -39,126 +173,49 @@ const tokens = {
39
173
  focusRing: '#4F46E5',
40
174
  },
41
175
  space: {
42
- '2xs': 2,
43
- xs: 4,
44
- sm: 8,
45
- md: 16,
46
- lg: 24,
47
- xl: 32,
48
- '2xl': 48,
49
- '3xl': 64,
176
+ '2xs': 2, xs: 4, sm: 8, md: 16, lg: 24, xl: 32, '2xl': 48, '3xl': 64,
50
177
  },
51
178
  radius: {
52
- none: 0,
53
- xs: 2,
54
- sm: 4,
55
- md: 6,
56
- lg: 8,
57
- xl: 12,
58
- '2xl': 16,
59
- full: 9999,
179
+ none: 0, xs: 2, sm: 4, md: 6, lg: 8, xl: 12, '2xl': 16, full: 9999,
60
180
  },
61
181
  shadow: {
62
182
  none: 'none',
63
- xs: '0 1px 2px rgba(0,0,0,0.05)',
64
- sm: '0 1px 3px rgba(0,0,0,0.10), 0 1px 2px rgba(0,0,0,0.06)',
65
- md: '0 4px 6px rgba(0,0,0,0.07), 0 2px 4px rgba(0,0,0,0.06)',
66
- lg: '0 10px 15px rgba(0,0,0,0.08), 0 4px 6px rgba(0,0,0,0.05)',
67
- xl: '0 20px 25px rgba(0,0,0,0.10), 0 8px 10px rgba(0,0,0,0.04)',
68
- },
69
- duration: {
70
- instant: 50,
71
- fast: 100,
72
- normal: 200,
73
- slow: 300,
74
- deliberate: 500,
75
- },
76
- ease: {
77
- standard: 'cubic-bezier(0.4, 0, 0.2, 1)',
78
- decelerate: 'cubic-bezier(0, 0, 0.2, 1)',
79
- accelerate: 'cubic-bezier(0.4, 0, 1, 1)',
80
- spring: 'cubic-bezier(0.34, 1.56, 0.64, 1)',
81
- },
82
- font: {
83
- display: 'Plus Jakarta Sans',
84
- text: 'Inter',
85
- mono: 'JetBrains Mono',
183
+ xs: sh[1],
184
+ sm: sh[2],
185
+ md: sh[3],
186
+ lg: sh[4],
187
+ xl: sh[5],
86
188
  },
189
+ duration: { instant: 50, fast: 100, normal: 200, slow: 300, deliberate: 500 },
190
+ ease,
191
+ font: { display: 'Plus Jakarta Sans', text: 'Inter', mono: 'JetBrains Mono' },
87
192
  fontSize: {
88
- h1: '36px',
89
- h2: '28px',
90
- h3: '22px',
91
- h4: '18px',
92
- h5: '16px',
93
- bodyLg: '16px',
94
- bodyMd: '14px',
95
- caption: '12px',
96
- code: '12px',
193
+ h1: '36px', h2: '28px', h3: '22px', h4: '18px', h5: '16px',
194
+ bodyLg: '16px', bodyMd: '14px', caption: '12px', code: '12px',
97
195
  },
98
196
  component: {
99
197
  buttonHeight: { xs: '28px', sm: '32px', md: '36px', lg: '42px', xl: '50px' },
100
- radiusButton: '8px',
101
- radiusCard: '12px',
102
- radiusModal: '16px',
103
- radiusBadge: '9999px',
104
- focusRingWidth: '3px',
105
- focusRingOffset: '2px',
198
+ radiusButton: '8px', radiusCard: '12px', radiusModal: '16px', radiusBadge: '9999px',
199
+ focusRingWidth: '3px', focusRingOffset: '2px',
106
200
  },
107
201
  };
108
- // Flat named exports for backwards-compat convenience
109
- const colors = {
110
- brand500: tokens.color.brand[500],
111
- brand600: tokens.color.brand[600],
112
- brand700: tokens.color.brand[700],
113
- brand50: tokens.color.brand[50],
114
- danger500: tokens.color.danger[500],
115
- danger50: tokens.color.danger[50],
116
- success500: tokens.color.success[500],
117
- success50: tokens.color.success[50],
118
- warning500: tokens.color.warning[500],
119
- warning50: tokens.color.warning[50],
120
- gray50: tokens.color.gray[50],
121
- gray100: tokens.color.gray[100],
122
- gray200: tokens.color.gray[200],
123
- gray300: tokens.color.gray[300],
124
- gray400: tokens.color.gray[400],
125
- gray500: tokens.color.gray[500],
126
- gray600: tokens.color.gray[600],
127
- gray700: tokens.color.gray[700],
128
- gray800: tokens.color.gray[800],
129
- gray900: tokens.color.gray[900],
130
- surface: tokens.semantic.surface,
131
- bg: tokens.semantic.bg,
132
- textPrimary: tokens.semantic.textPrimary,
133
- textSecondary: tokens.semantic.textSecondary,
134
- textDisabled: tokens.semantic.textDisabled,
135
- border: tokens.semantic.border,
136
- borderStrong: tokens.semantic.borderStrong,
137
- focusRing: tokens.semantic.focusRing,
138
- };
139
- const spacing = {
140
- '2xs': '2px',
141
- xs: '4px',
142
- sm: '8px',
143
- md: '16px',
144
- lg: '24px',
145
- xl: '32px',
146
- '2xl': '48px',
147
- '3xl': '64px',
148
- };
149
- const radii = {
150
- none: '0',
151
- xs: '2px',
152
- sm: '4px',
153
- md: '6px',
154
- lg: '8px',
155
- xl: '12px',
156
- '2xl': '16px',
157
- full: '9999px',
158
- };
159
202
 
203
+ exports.bd = bd;
204
+ exports.bg = bg;
205
+ exports.br = br;
206
+ exports.bw = bw;
160
207
  exports.colors = colors;
208
+ exports.duration = duration;
209
+ exports.ease = ease;
210
+ exports.fl = fl;
211
+ exports.fs = fs;
212
+ exports.fw = fw;
213
+ exports.lh = lh;
214
+ exports.op = op;
161
215
  exports.radii = radii;
216
+ exports.sh = sh;
162
217
  exports.spacing = spacing;
218
+ exports.ta = ta;
163
219
  exports.tokens = tokens;
220
+ exports.tx = tx;
164
221
  //# sourceMappingURL=index.js.map