@enterprise-ui-react/react 1.0.6

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.
@@ -0,0 +1,684 @@
1
+ 'use strict';
2
+
3
+ // src/tokens/colors.ts
4
+ var colors = {
5
+ // Light Theme - Neutral Base + Blue Accent (Gold Standard)
6
+ light: {
7
+ background: {
8
+ DEFAULT: "#F8FAFC",
9
+ surface: "#FFFFFF",
10
+ elevated: "#FFFFFF",
11
+ overlay: "rgba(15, 23, 42, 0.5)",
12
+ hover: "#F1F5F9",
13
+ active: "#E2E8F0"
14
+ },
15
+ border: {
16
+ DEFAULT: "#E2E8F0",
17
+ strong: "#CBD5E1",
18
+ subtle: "#F1F5F9",
19
+ focus: "#93C5FD"
20
+ },
21
+ text: {
22
+ primary: "#0F172A",
23
+ secondary: "#475569",
24
+ tertiary: "#64748B",
25
+ disabled: "#94A3B8",
26
+ inverse: "#FFFFFF",
27
+ link: "#2563EB",
28
+ linkHover: "#1D4ED8"
29
+ },
30
+ primary: {
31
+ DEFAULT: "#2563EB",
32
+ hover: "#1D4ED8",
33
+ active: "#1E40AF",
34
+ disabled: "#93C5FD",
35
+ text: "#FFFFFF",
36
+ light: "#DBEAFE",
37
+ lighter: "#EFF6FF",
38
+ dark: "#1E3A8A"
39
+ },
40
+ // Semantic colors (desaturated for enterprise)
41
+ success: {
42
+ DEFAULT: "#10B981",
43
+ hover: "#059669",
44
+ active: "#047857",
45
+ disabled: "#86EFAC",
46
+ text: "#FFFFFF",
47
+ light: "#D1FAE5",
48
+ lighter: "#ECFDF5",
49
+ dark: "#065F46"
50
+ },
51
+ warning: {
52
+ DEFAULT: "#F59E0B",
53
+ hover: "#D97706",
54
+ active: "#B45309",
55
+ disabled: "#FCD34D",
56
+ text: "#FFFFFF",
57
+ light: "#FEF3C7",
58
+ lighter: "#FFFBEB",
59
+ dark: "#92400E"
60
+ },
61
+ error: {
62
+ DEFAULT: "#EF4444",
63
+ hover: "#DC2626",
64
+ active: "#B91C1C",
65
+ disabled: "#FCA5A5",
66
+ text: "#FFFFFF",
67
+ light: "#FEE2E2",
68
+ lighter: "#FEF2F2",
69
+ dark: "#991B1B"
70
+ },
71
+ info: {
72
+ DEFAULT: "#3B82F6",
73
+ hover: "#2563EB",
74
+ active: "#1D4ED8",
75
+ disabled: "#93C5FD",
76
+ text: "#FFFFFF",
77
+ light: "#DBEAFE",
78
+ lighter: "#EFF6FF",
79
+ dark: "#1E40AF"
80
+ }
81
+ },
82
+ // Dark Theme - Modern Enterprise
83
+ dark: {
84
+ background: {
85
+ DEFAULT: "#0B1220",
86
+ surface: "#111827",
87
+ elevated: "#1F2937",
88
+ overlay: "rgba(0, 0, 0, 0.7)",
89
+ hover: "#1F2937",
90
+ active: "#374151"
91
+ },
92
+ border: {
93
+ DEFAULT: "#374151",
94
+ strong: "#4B5563",
95
+ subtle: "#1F2937",
96
+ focus: "#60A5FA"
97
+ },
98
+ text: {
99
+ primary: "#E5E7EB",
100
+ secondary: "#9CA3AF",
101
+ tertiary: "#6B7280",
102
+ disabled: "#4B5563",
103
+ inverse: "#0F172A",
104
+ link: "#60A5FA",
105
+ linkHover: "#93C5FD"
106
+ },
107
+ primary: {
108
+ DEFAULT: "#3B82F6",
109
+ hover: "#60A5FA",
110
+ active: "#93C5FD",
111
+ disabled: "#1E40AF",
112
+ text: "#FFFFFF",
113
+ light: "#1E3A8A",
114
+ lighter: "#1E40AF",
115
+ dark: "#DBEAFE"
116
+ },
117
+ success: {
118
+ DEFAULT: "#10B981",
119
+ hover: "#34D399",
120
+ active: "#6EE7B7",
121
+ disabled: "#065F46",
122
+ text: "#FFFFFF",
123
+ light: "#064E3B",
124
+ lighter: "#065F46",
125
+ dark: "#D1FAE5"
126
+ },
127
+ warning: {
128
+ DEFAULT: "#F59E0B",
129
+ hover: "#FBBF24",
130
+ active: "#FCD34D",
131
+ disabled: "#92400E",
132
+ text: "#FFFFFF",
133
+ light: "#78350F",
134
+ lighter: "#92400E",
135
+ dark: "#FEF3C7"
136
+ },
137
+ error: {
138
+ DEFAULT: "#EF4444",
139
+ hover: "#F87171",
140
+ active: "#FCA5A5",
141
+ disabled: "#991B1B",
142
+ text: "#FFFFFF",
143
+ light: "#7F1D1D",
144
+ lighter: "#991B1B",
145
+ dark: "#FEE2E2"
146
+ },
147
+ info: {
148
+ DEFAULT: "#3B82F6",
149
+ hover: "#60A5FA",
150
+ active: "#93C5FD",
151
+ disabled: "#1E40AF",
152
+ text: "#FFFFFF",
153
+ light: "#1E3A8A",
154
+ lighter: "#1E40AF",
155
+ dark: "#DBEAFE"
156
+ }
157
+ },
158
+ // Alternative: Teal (Professional but Fresh)
159
+ tealVariant: {
160
+ primary: {
161
+ DEFAULT: "#0F766E",
162
+ hover: "#0D9488",
163
+ active: "#14B8A6",
164
+ light: "#CCFBF1",
165
+ dark: "#134E4A"
166
+ }
167
+ }
168
+ };
169
+
170
+ // src/tokens/typography.ts
171
+ var typography = {
172
+ fontFamily: {
173
+ sans: [
174
+ "Inter",
175
+ "-apple-system",
176
+ "BlinkMacSystemFont",
177
+ "Segoe UI",
178
+ "Roboto",
179
+ "Helvetica Neue",
180
+ "Arial",
181
+ "sans-serif"
182
+ ].join(", "),
183
+ mono: [
184
+ "JetBrains Mono",
185
+ "SF Mono",
186
+ "Monaco",
187
+ "Inconsolata",
188
+ "Fira Code",
189
+ "Consolas",
190
+ "monospace"
191
+ ].join(", ")
192
+ },
193
+ fontSize: {
194
+ xs: { size: "0.75rem", lineHeight: "1rem" },
195
+ // 12px
196
+ sm: { size: "0.875rem", lineHeight: "1.25rem" },
197
+ // 14px
198
+ base: { size: "1rem", lineHeight: "1.5rem" },
199
+ // 16px
200
+ lg: { size: "1.125rem", lineHeight: "1.75rem" },
201
+ // 18px
202
+ xl: { size: "1.25rem", lineHeight: "1.75rem" },
203
+ // 20px
204
+ "2xl": { size: "1.5rem", lineHeight: "2rem" },
205
+ // 24px
206
+ "3xl": { size: "1.875rem", lineHeight: "2.25rem" },
207
+ // 30px
208
+ "4xl": { size: "2.25rem", lineHeight: "2.5rem" },
209
+ // 36px
210
+ "5xl": { size: "3rem", lineHeight: "1.2" },
211
+ // 48px
212
+ "6xl": { size: "3.75rem", lineHeight: "1.1" }
213
+ // 60px
214
+ },
215
+ fontWeight: {
216
+ normal: 400,
217
+ medium: 500,
218
+ semibold: 600,
219
+ bold: 700
220
+ },
221
+ letterSpacing: {
222
+ tight: "-0.025em",
223
+ normal: "0",
224
+ wide: "0.025em"
225
+ },
226
+ // Predefined text styles for common UI patterns
227
+ textStyles: {
228
+ // Headings
229
+ h1: {
230
+ fontSize: "3rem",
231
+ lineHeight: "1.2",
232
+ fontWeight: 700,
233
+ letterSpacing: "-0.025em"
234
+ },
235
+ h2: {
236
+ fontSize: "2.25rem",
237
+ lineHeight: "2.5rem",
238
+ fontWeight: 700,
239
+ letterSpacing: "-0.025em"
240
+ },
241
+ h3: {
242
+ fontSize: "1.875rem",
243
+ lineHeight: "2.25rem",
244
+ fontWeight: 600,
245
+ letterSpacing: "-0.025em"
246
+ },
247
+ h4: {
248
+ fontSize: "1.5rem",
249
+ lineHeight: "2rem",
250
+ fontWeight: 600
251
+ },
252
+ h5: {
253
+ fontSize: "1.25rem",
254
+ lineHeight: "1.75rem",
255
+ fontWeight: 600
256
+ },
257
+ h6: {
258
+ fontSize: "1.125rem",
259
+ lineHeight: "1.75rem",
260
+ fontWeight: 600
261
+ },
262
+ // Body text
263
+ bodyLarge: {
264
+ fontSize: "1.125rem",
265
+ lineHeight: "1.75rem",
266
+ fontWeight: 400
267
+ },
268
+ body: {
269
+ fontSize: "1rem",
270
+ lineHeight: "1.5rem",
271
+ fontWeight: 400
272
+ },
273
+ bodySmall: {
274
+ fontSize: "0.875rem",
275
+ lineHeight: "1.25rem",
276
+ fontWeight: 400
277
+ },
278
+ // UI text
279
+ label: {
280
+ fontSize: "0.875rem",
281
+ lineHeight: "1.25rem",
282
+ fontWeight: 500
283
+ },
284
+ caption: {
285
+ fontSize: "0.75rem",
286
+ lineHeight: "1rem",
287
+ fontWeight: 400
288
+ },
289
+ overline: {
290
+ fontSize: "0.75rem",
291
+ lineHeight: "1rem",
292
+ fontWeight: 600,
293
+ letterSpacing: "0.05em",
294
+ textTransform: "uppercase"
295
+ },
296
+ // Code
297
+ code: {
298
+ fontSize: "0.875rem",
299
+ lineHeight: "1.25rem",
300
+ fontWeight: 400,
301
+ fontFamily: [
302
+ "JetBrains Mono",
303
+ "SF Mono",
304
+ "Monaco",
305
+ "monospace"
306
+ ].join(", ")
307
+ }
308
+ }
309
+ };
310
+
311
+ // src/tokens/spacing.ts
312
+ var spacing = {
313
+ 0: "0",
314
+ 0.5: "0.125rem",
315
+ // 2px
316
+ 1: "0.25rem",
317
+ // 4px
318
+ 1.5: "0.375rem",
319
+ // 6px
320
+ 2: "0.5rem",
321
+ // 8px
322
+ 2.5: "0.625rem",
323
+ // 10px
324
+ 3: "0.75rem",
325
+ // 12px
326
+ 3.5: "0.875rem",
327
+ // 14px
328
+ 4: "1rem",
329
+ // 16px
330
+ 5: "1.25rem",
331
+ // 20px
332
+ 6: "1.5rem",
333
+ // 24px
334
+ 7: "1.75rem",
335
+ // 28px
336
+ 8: "2rem",
337
+ // 32px
338
+ 9: "2.25rem",
339
+ // 36px
340
+ 10: "2.5rem",
341
+ // 40px
342
+ 11: "2.75rem",
343
+ // 44px
344
+ 12: "3rem",
345
+ // 48px
346
+ 14: "3.5rem",
347
+ // 56px
348
+ 16: "4rem",
349
+ // 64px
350
+ 20: "5rem",
351
+ // 80px
352
+ 24: "6rem",
353
+ // 96px
354
+ 28: "7rem",
355
+ // 112px
356
+ 32: "8rem",
357
+ // 128px
358
+ 36: "9rem",
359
+ // 144px
360
+ 40: "10rem",
361
+ // 160px
362
+ 44: "11rem",
363
+ // 176px
364
+ 48: "12rem",
365
+ // 192px
366
+ 52: "13rem",
367
+ // 208px
368
+ 56: "14rem",
369
+ // 224px
370
+ 60: "15rem",
371
+ // 240px
372
+ 64: "16rem",
373
+ // 256px
374
+ 72: "18rem",
375
+ // 288px
376
+ 80: "20rem",
377
+ // 320px
378
+ 96: "24rem"
379
+ // 384px
380
+ };
381
+ var semanticSpacing = {
382
+ // Component padding
383
+ componentPaddingXs: spacing[2],
384
+ // 8px
385
+ componentPaddingSm: spacing[3],
386
+ // 12px
387
+ componentPaddingMd: spacing[4],
388
+ // 16px
389
+ componentPaddingLg: spacing[6],
390
+ // 24px
391
+ componentPaddingXl: spacing[8],
392
+ // 32px
393
+ // Component gaps
394
+ componentGapXs: spacing[1],
395
+ // 4px
396
+ componentGapSm: spacing[2],
397
+ // 8px
398
+ componentGapMd: spacing[3],
399
+ // 12px
400
+ componentGapLg: spacing[4],
401
+ // 16px
402
+ componentGapXl: spacing[6],
403
+ // 24px
404
+ // Layout spacing
405
+ layoutGapXs: spacing[4],
406
+ // 16px
407
+ layoutGapSm: spacing[6],
408
+ // 24px
409
+ layoutGapMd: spacing[8],
410
+ // 32px
411
+ layoutGapLg: spacing[12],
412
+ // 48px
413
+ layoutGapXl: spacing[16],
414
+ // 64px
415
+ // Section spacing
416
+ sectionGapSm: spacing[8],
417
+ // 32px
418
+ sectionGapMd: spacing[12],
419
+ // 48px
420
+ sectionGapLg: spacing[16],
421
+ // 64px
422
+ sectionGapXl: spacing[24]
423
+ // 96px
424
+ };
425
+
426
+ // src/tokens/borders.ts
427
+ var borders = {
428
+ width: {
429
+ none: "0",
430
+ thin: "1px",
431
+ medium: "2px",
432
+ thick: "3px",
433
+ heavy: "4px"
434
+ },
435
+ radius: {
436
+ none: "0",
437
+ xs: "0.125rem",
438
+ // 2px
439
+ sm: "0.25rem",
440
+ // 4px
441
+ DEFAULT: "0.375rem",
442
+ // 6px
443
+ md: "0.5rem",
444
+ // 8px
445
+ lg: "0.75rem",
446
+ // 12px
447
+ xl: "1rem",
448
+ // 16px
449
+ "2xl": "1.5rem",
450
+ // 24px
451
+ "3xl": "2rem",
452
+ // 32px
453
+ full: "9999px"
454
+ },
455
+ style: {
456
+ solid: "solid",
457
+ dashed: "dashed",
458
+ dotted: "dotted"
459
+ }
460
+ };
461
+ var semanticBorders = {
462
+ // Input borders
463
+ inputDefault: {
464
+ width: borders.width.thin,
465
+ style: borders.style.solid,
466
+ radius: borders.radius.md
467
+ },
468
+ inputFocus: {
469
+ width: borders.width.medium,
470
+ style: borders.style.solid,
471
+ radius: borders.radius.md
472
+ },
473
+ // Card borders
474
+ card: {
475
+ width: borders.width.thin,
476
+ style: borders.style.solid,
477
+ radius: borders.radius.lg
478
+ },
479
+ // Button borders
480
+ button: {
481
+ width: borders.width.thin,
482
+ style: borders.style.solid,
483
+ radius: borders.radius.md
484
+ },
485
+ // Modal/Dialog borders
486
+ modal: {
487
+ width: borders.width.none,
488
+ style: borders.style.solid,
489
+ radius: borders.radius.xl
490
+ }
491
+ };
492
+
493
+ // src/tokens/shadows.ts
494
+ var shadows = {
495
+ none: "none",
496
+ xs: "0 1px 2px 0 rgba(0, 0, 0, 0.05)",
497
+ sm: "0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06)",
498
+ DEFAULT: "0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06)",
499
+ md: "0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05)",
500
+ lg: "0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04)",
501
+ xl: "0 25px 50px -12px rgba(0, 0, 0, 0.25)",
502
+ "2xl": "0 30px 60px -15px rgba(0, 0, 0, 0.3)",
503
+ inner: "inset 0 2px 4px 0 rgba(0, 0, 0, 0.06)"
504
+ };
505
+ var darkShadows = {
506
+ none: "none",
507
+ xs: "0 1px 2px 0 rgba(0, 0, 0, 0.3)",
508
+ sm: "0 1px 3px 0 rgba(0, 0, 0, 0.4), 0 1px 2px 0 rgba(0, 0, 0, 0.3)",
509
+ DEFAULT: "0 4px 6px -1px rgba(0, 0, 0, 0.4), 0 2px 4px -1px rgba(0, 0, 0, 0.3)",
510
+ md: "0 10px 15px -3px rgba(0, 0, 0, 0.5), 0 4px 6px -2px rgba(0, 0, 0, 0.3)",
511
+ lg: "0 20px 25px -5px rgba(0, 0, 0, 0.6), 0 10px 10px -5px rgba(0, 0, 0, 0.4)",
512
+ xl: "0 25px 50px -12px rgba(0, 0, 0, 0.7)",
513
+ "2xl": "0 30px 60px -15px rgba(0, 0, 0, 0.8)",
514
+ inner: "inset 0 2px 4px 0 rgba(0, 0, 0, 0.3)"
515
+ };
516
+ var elevation = {
517
+ flat: shadows.none,
518
+ raised: shadows.sm,
519
+ floating: shadows.md,
520
+ overlay: shadows.lg,
521
+ modal: shadows.xl,
522
+ popover: shadows.lg,
523
+ dropdown: shadows.md,
524
+ tooltip: shadows.sm
525
+ };
526
+
527
+ // src/tokens/breakpoints.ts
528
+ var breakpoints = {
529
+ xs: "320px",
530
+ // Mobile small
531
+ sm: "640px",
532
+ // Mobile
533
+ md: "768px",
534
+ // Tablet
535
+ lg: "1024px",
536
+ // Desktop
537
+ xl: "1280px",
538
+ // Desktop large
539
+ "2xl": "1536px",
540
+ // Desktop extra large
541
+ "3xl": "1920px"
542
+ // Wide screen
543
+ };
544
+ var breakpointValues = {
545
+ xs: 320,
546
+ sm: 640,
547
+ md: 768,
548
+ lg: 1024,
549
+ xl: 1280,
550
+ "2xl": 1536,
551
+ "3xl": 1920
552
+ };
553
+ var mediaQueries = {
554
+ xs: `@media (min-width: ${breakpoints.xs})`,
555
+ sm: `@media (min-width: ${breakpoints.sm})`,
556
+ md: `@media (min-width: ${breakpoints.md})`,
557
+ lg: `@media (min-width: ${breakpoints.lg})`,
558
+ xl: `@media (min-width: ${breakpoints.xl})`,
559
+ "2xl": `@media (min-width: ${breakpoints["2xl"]})`,
560
+ "3xl": `@media (min-width: ${breakpoints["3xl"]})`
561
+ };
562
+
563
+ // src/tokens/motion.ts
564
+ var motion = {
565
+ duration: {
566
+ instant: "0ms",
567
+ fast: "100ms",
568
+ normal: "200ms",
569
+ moderate: "300ms",
570
+ slow: "400ms",
571
+ slower: "500ms",
572
+ slowest: "600ms"
573
+ },
574
+ easing: {
575
+ linear: "linear",
576
+ easeIn: "cubic-bezier(0.4, 0, 1, 1)",
577
+ easeOut: "cubic-bezier(0, 0, 0.2, 1)",
578
+ easeInOut: "cubic-bezier(0.4, 0, 0.2, 1)",
579
+ sharp: "cubic-bezier(0.4, 0, 0.6, 1)",
580
+ spring: "cubic-bezier(0.34, 1.56, 0.64, 1)"
581
+ },
582
+ // Framer Motion variants
583
+ variants: {
584
+ fadeIn: {
585
+ initial: { opacity: 0 },
586
+ animate: { opacity: 1 },
587
+ exit: { opacity: 0 },
588
+ transition: { duration: 0.2 }
589
+ },
590
+ fadeOut: {
591
+ initial: { opacity: 1 },
592
+ animate: { opacity: 0 },
593
+ exit: { opacity: 1 },
594
+ transition: { duration: 0.2 }
595
+ },
596
+ slideInRight: {
597
+ initial: { x: "100%", opacity: 0 },
598
+ animate: { x: 0, opacity: 1 },
599
+ exit: { x: "100%", opacity: 0 },
600
+ transition: { duration: 0.3, ease: [0, 0, 0.2, 1] }
601
+ },
602
+ slideInLeft: {
603
+ initial: { x: "-100%", opacity: 0 },
604
+ animate: { x: 0, opacity: 1 },
605
+ exit: { x: "-100%", opacity: 0 },
606
+ transition: { duration: 0.3, ease: [0, 0, 0.2, 1] }
607
+ },
608
+ slideInUp: {
609
+ initial: { y: "100%", opacity: 0 },
610
+ animate: { y: 0, opacity: 1 },
611
+ exit: { y: "100%", opacity: 0 },
612
+ transition: { duration: 0.3, ease: [0, 0, 0.2, 1] }
613
+ },
614
+ slideInDown: {
615
+ initial: { y: "-100%", opacity: 0 },
616
+ animate: { y: 0, opacity: 1 },
617
+ exit: { y: "-100%", opacity: 0 },
618
+ transition: { duration: 0.3, ease: [0, 0, 0.2, 1] }
619
+ },
620
+ scaleIn: {
621
+ initial: { scale: 0.95, opacity: 0 },
622
+ animate: { scale: 1, opacity: 1 },
623
+ exit: { scale: 0.95, opacity: 0 },
624
+ transition: { duration: 0.2, ease: [0, 0, 0.2, 1] }
625
+ },
626
+ scaleOut: {
627
+ initial: { scale: 1, opacity: 1 },
628
+ animate: { scale: 0.95, opacity: 0 },
629
+ exit: { scale: 1, opacity: 1 },
630
+ transition: { duration: 0.2, ease: [0.4, 0, 1, 1] }
631
+ }
632
+ },
633
+ // Micro-interactions
634
+ microInteractions: {
635
+ buttonPress: {
636
+ scale: 0.98,
637
+ transition: { duration: 0.1 }
638
+ },
639
+ buttonHover: {
640
+ scale: 1.02,
641
+ transition: { duration: 0.2 }
642
+ },
643
+ cardHover: {
644
+ y: -4,
645
+ transition: { duration: 0.2 }
646
+ },
647
+ ripple: {
648
+ scale: [0, 1],
649
+ opacity: [0.5, 0],
650
+ transition: { duration: 0.6 }
651
+ }
652
+ }
653
+ };
654
+
655
+ // src/tokens/zIndex.ts
656
+ var zIndex = {
657
+ base: 0,
658
+ dropdown: 1e3,
659
+ sticky: 1100,
660
+ fixed: 1200,
661
+ popover: 1300,
662
+ tooltip: 1400,
663
+ overlay: 1500,
664
+ modal: 1600,
665
+ toast: 1700,
666
+ commandPalette: 1800,
667
+ contextMenu: 1900,
668
+ max: 2147483647
669
+ };
670
+
671
+ exports.borders = borders;
672
+ exports.breakpointValues = breakpointValues;
673
+ exports.breakpoints = breakpoints;
674
+ exports.colors = colors;
675
+ exports.darkShadows = darkShadows;
676
+ exports.elevation = elevation;
677
+ exports.mediaQueries = mediaQueries;
678
+ exports.motion = motion;
679
+ exports.semanticBorders = semanticBorders;
680
+ exports.semanticSpacing = semanticSpacing;
681
+ exports.shadows = shadows;
682
+ exports.spacing = spacing;
683
+ exports.typography = typography;
684
+ exports.zIndex = zIndex;