@octoguide/mui-ui-toolkit 0.1.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/dist/index.js ADDED
@@ -0,0 +1,1762 @@
1
+ "use strict";
2
+ var __create = Object.create;
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __export = (target, all) => {
9
+ for (var name in all)
10
+ __defProp(target, name, { get: all[name], enumerable: true });
11
+ };
12
+ var __copyProps = (to, from, except, desc) => {
13
+ if (from && typeof from === "object" || typeof from === "function") {
14
+ for (let key of __getOwnPropNames(from))
15
+ if (!__hasOwnProp.call(to, key) && key !== except)
16
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
+ }
18
+ return to;
19
+ };
20
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
25
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
+ mod
27
+ ));
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
+
30
+ // src/index.ts
31
+ var index_exports = {};
32
+ __export(index_exports, {
33
+ Accordion: () => Accordion,
34
+ AccordionDetails: () => AccordionDetails,
35
+ AccordionSummary: () => AccordionSummary,
36
+ Alert: () => Alert,
37
+ AlertTitle: () => AlertTitle,
38
+ Avatar: () => Avatar,
39
+ AvatarGroup: () => import_AvatarGroup.default,
40
+ Body1: () => Body1,
41
+ Body2: () => Body2,
42
+ Button: () => Button,
43
+ Caption: () => Caption,
44
+ Card: () => Card,
45
+ CardActions: () => CardActions,
46
+ CardContent: () => CardContent,
47
+ CardHeader: () => CardHeader,
48
+ Chip: () => Chip,
49
+ DateCalendar: () => DateCalendar,
50
+ DateField: () => DateField,
51
+ DateLocalizationProvider: () => DateLocalizationProvider,
52
+ DatePicker: () => DatePicker,
53
+ DateRangePickerCalendar: () => DateRangePickerCalendar,
54
+ DateRangePickerInput: () => DateRangePickerInput,
55
+ DateTimeField: () => DateTimeField,
56
+ DateTimePicker: () => DateTimePicker,
57
+ DesktopDatePicker: () => DesktopDatePicker,
58
+ DesktopDateTimePicker: () => DesktopDateTimePicker,
59
+ DesktopTimePicker: () => DesktopTimePicker,
60
+ Grid: () => Grid,
61
+ H1: () => H1,
62
+ H2: () => H2,
63
+ H3: () => H3,
64
+ H4: () => H4,
65
+ H5: () => H5,
66
+ H6: () => H6,
67
+ MobileDatePicker: () => MobileDatePicker,
68
+ MobileDateTimePicker: () => MobileDateTimePicker,
69
+ MobileTimePicker: () => MobileTimePicker,
70
+ Overline: () => Overline,
71
+ StandaloneAccordion: () => StandaloneAccordion,
72
+ StaticDatePicker: () => StaticDatePicker,
73
+ StaticDateTimePicker: () => StaticDateTimePicker,
74
+ StaticTimePicker: () => StaticTimePicker,
75
+ Subtitle1: () => Subtitle1,
76
+ Subtitle2: () => Subtitle2,
77
+ TextField: () => TextField,
78
+ TimeField: () => TimeField,
79
+ TimePicker: () => TimePicker,
80
+ ToggleButton: () => ToggleButton,
81
+ ToggleButtonGroup: () => ToggleButtonGroup,
82
+ ToolkitThemeProvider: () => ToolkitThemeProvider,
83
+ TypographyButton: () => TypographyButton,
84
+ createMuiTheme: () => createMuiTheme,
85
+ getThemeTokens: () => getThemeTokens,
86
+ resolveThemeName: () => resolveThemeName,
87
+ themeRegistry: () => themeRegistry
88
+ });
89
+ module.exports = __toCommonJS(index_exports);
90
+
91
+ // src/ThemeProvider.tsx
92
+ var import_material = require("@mui/material");
93
+
94
+ // src/themes/defaultTheme.ts
95
+ var defaultTheme = {
96
+ colors: {
97
+ primary: "#BE0D00",
98
+ primaryDark: "#003c8f",
99
+ primaryLight: "#5e92f3",
100
+ primaryContrast: "#ffffff",
101
+ secondary: "#c95109",
102
+ secondaryDark: "#38006b",
103
+ secondaryLight: "#9c4dcc",
104
+ secondaryContrast: "#ffffff",
105
+ success: "#1A6D29",
106
+ warning: "#E6920A",
107
+ error: "#990000",
108
+ info: "#0288D1",
109
+ background: "#F5F7FA",
110
+ backgroundPaper: "#ffffff",
111
+ backgroundSubtle: "#EEF2F7",
112
+ textPrimary: "#1A2340",
113
+ textSecondary: "#546080",
114
+ textDisabled: "#A0AABF",
115
+ divider: "#DDE3EE",
116
+ border: "#C5CFE0",
117
+ borderFocus: "#1565C0",
118
+ overlayLight: "rgba(255, 255, 255, 0.8)",
119
+ overlayDark: "rgba(0, 0, 0, 0.12)"
120
+ },
121
+ typography: {
122
+ fontFamilyBase: '"Source Sans Pro", sans-serif',
123
+ fontFamilyMono: '"Inter", "Roboto", "Helvetica Neue", Arial, sans-serif',
124
+ // ── Sizes (identical across all themes) ──────────────────────────────
125
+ fontSizeXs: "0.625rem",
126
+ // 10px
127
+ fontSizeSm: "0.75rem",
128
+ // 12px
129
+ fontSizeMd: "0.875rem",
130
+ // 14px
131
+ fontSizeLg: "1rem",
132
+ // 16px
133
+ fontSizeXl: "1.125rem",
134
+ // 18px
135
+ fontSize2xl: "1.375rem",
136
+ // 22px
137
+ fontSize3xl: "1.75rem",
138
+ // 28px
139
+ // ── Weights (identical across all themes) ─────────────────────────────
140
+ fontWeightLight: 300,
141
+ fontWeightRegular: 400,
142
+ fontWeightMedium: 500,
143
+ fontWeightSemiBold: 600,
144
+ fontWeightBold: 700,
145
+ lineHeightTight: 1.2,
146
+ lineHeightBase: 1.5,
147
+ lineHeightRelaxed: 1.75,
148
+ letterSpacingTight: "-0.02em",
149
+ letterSpacingBase: "0em",
150
+ letterSpacingWide: "0.06em"
151
+ },
152
+ // ── Spacing (identical across all themes) ──────────────────────────────
153
+ spacing: {
154
+ unit: 8,
155
+ xs: "4px",
156
+ sm: "8px",
157
+ md: "16px",
158
+ lg: "24px",
159
+ xl: "32px",
160
+ xxl: "48px"
161
+ },
162
+ borderRadius: {
163
+ none: "0px",
164
+ xs: "2px",
165
+ sm: "4px",
166
+ md: "8px",
167
+ lg: "12px",
168
+ xl: "16px",
169
+ full: "9999px"
170
+ },
171
+ shadows: {
172
+ none: "none",
173
+ xs: "0 1px 2px rgba(0, 0, 0, 0.08)",
174
+ sm: "0 2px 6px rgba(0, 0, 0, 0.10)",
175
+ md: "0 4px 12px rgba(0, 0, 0, 0.12)",
176
+ lg: "0 8px 24px rgba(0, 0, 0, 0.14)",
177
+ xl: "0 16px 48px rgba(0, 0, 0, 0.18)"
178
+ },
179
+ transitions: {
180
+ durationFast: "120ms",
181
+ durationBase: "200ms",
182
+ durationSlow: "350ms",
183
+ easingDefault: "cubic-bezier(0.4, 0, 0.2, 1)",
184
+ easingIn: "cubic-bezier(0.4, 0, 1, 1)",
185
+ easingOut: "cubic-bezier(0, 0, 0.2, 1)"
186
+ },
187
+ // ── Z-index (identical across all themes) ──────────────────────────────
188
+ zIndex: {
189
+ base: 0,
190
+ dropdown: 100,
191
+ sticky: 200,
192
+ overlay: 300,
193
+ modal: 400,
194
+ popover: 500,
195
+ toast: 600,
196
+ tooltip: 700
197
+ },
198
+ components: {
199
+ button: {
200
+ // Sizes & paddings (identical across themes)
201
+ paddingX: "12px",
202
+ paddingY: "6px",
203
+ paddingXSm: "8px",
204
+ paddingYSm: "4px",
205
+ paddingXLg: "16px",
206
+ paddingYLg: "8px",
207
+ paddingXXl: "16px",
208
+ paddingYXl: "8px",
209
+ fontSizeSm: "0.8125rem",
210
+ fontSizeMd: "0.875rem",
211
+ fontSizeLg: "0.9375rem",
212
+ heightSm: "30px",
213
+ heightMd: "36px",
214
+ heightLg: "48px",
215
+ heightXl: "56px",
216
+ // Typography & style (identical across themes)
217
+ borderWidth: "1.5px",
218
+ fontWeight: 700,
219
+ letterSpacing: "0em",
220
+ textTransform: "none",
221
+ iconGap: "8px",
222
+ // Brand-specific — overridden per theme
223
+ borderRadius: "8px",
224
+ minWidth: "200px"
225
+ },
226
+ input: {
227
+ // Sizes & paddings (identical across themes)
228
+ paddingX: "14px",
229
+ paddingY: "10px",
230
+ borderWidthFocus: "2px",
231
+ background: "#ffffff",
232
+ labelFontSize: "0.875rem",
233
+ helperFontSize: "0.75rem",
234
+ // Brand-specific — overridden per theme
235
+ borderRadius: "8px",
236
+ borderWidth: "1px",
237
+ backgroundDisabled: "#F5F7FA",
238
+ minHeight: "44px"
239
+ },
240
+ card: {
241
+ // Layout (identical across themes)
242
+ padding: "24px",
243
+ paddingCompact: "16px",
244
+ borderWidth: "1px",
245
+ background: "#ffffff",
246
+ // Brand-specific — overridden per theme
247
+ borderRadius: "12px"
248
+ },
249
+ // ── Chip (identical across all themes) ───────────────────────────────
250
+ chip: {
251
+ height: "32px",
252
+ heightSm: "24px",
253
+ paddingX: "12px",
254
+ borderRadius: "9999px",
255
+ fontSize: "0.8125rem",
256
+ fontWeight: 500,
257
+ iconSize: "16px"
258
+ },
259
+ // ── Badge (identical across all themes) ──────────────────────────────
260
+ badge: {
261
+ height: "20px",
262
+ minWidth: "20px",
263
+ paddingX: "6px",
264
+ borderRadius: "9999px",
265
+ fontSize: "0.6875rem",
266
+ fontWeight: 700,
267
+ borderWidth: "2px"
268
+ },
269
+ tooltip: {
270
+ paddingX: "10px",
271
+ paddingY: "6px",
272
+ fontSize: "0.75rem",
273
+ maxWidth: "280px",
274
+ color: "#ffffff",
275
+ // Brand-specific — overridden per theme
276
+ borderRadius: "6px",
277
+ background: "#1A2340"
278
+ },
279
+ dialog: {
280
+ // Layout (identical across themes)
281
+ padding: "32px",
282
+ maxWidth: "600px",
283
+ background: "#ffffff",
284
+ // Brand-specific — overridden per theme
285
+ borderRadius: "16px"
286
+ },
287
+ table: {
288
+ // Layout (identical across themes)
289
+ cellPaddingX: "16px",
290
+ headerFontWeight: 600,
291
+ borderWidth: "1px",
292
+ // Brand-specific — overridden per theme
293
+ cellPaddingY: "12px",
294
+ headerBackground: "#EEF2F7",
295
+ rowHoverBackground: "#F5F7FA",
296
+ borderColor: "#DDE3EE"
297
+ },
298
+ avatar: {
299
+ // Sizes (identical across themes)
300
+ sizeXs: "24px",
301
+ sizeSm: "32px",
302
+ sizeMd: "40px",
303
+ sizeLg: "56px",
304
+ sizeXl: "80px",
305
+ sizeXxl: "128px",
306
+ // Style (identical across themes)
307
+ borderRadius: "50%",
308
+ groupSpacing: "-8px",
309
+ groupBorderWidth: "2px",
310
+ // Brand-specific — overridden per theme
311
+ borderRadiusRounded: "12px"
312
+ },
313
+ divider: {
314
+ thickness: "1px",
315
+ // Brand-specific — overridden per theme
316
+ color: "#DDE3EE"
317
+ },
318
+ alert: {
319
+ // Layout (identical across themes)
320
+ padding: "6px 16px",
321
+ // Brand-specific — overridden per theme
322
+ borderRadius: "8px"
323
+ },
324
+ accordion: {
325
+ // Layout (identical across themes)
326
+ standaloneRadius: "16px",
327
+ summaryPaddingX: "16px",
328
+ summaryPaddingY: "16px",
329
+ summaryFontWeight: 600,
330
+ detailsPaddingX: "16px",
331
+ detailsPaddingBottom: "16px",
332
+ standaloneBackground: "rgba(145, 158, 171, 0.08)",
333
+ standaloneBackgroundExpanded: "rgba(145, 158, 171, 0.16)",
334
+ // Brand-specific — overridden per theme
335
+ borderRadius: "8px"
336
+ },
337
+ toggleButton: {
338
+ borderRadius: "8px",
339
+ borderWidth: "1px",
340
+ paddingXSm: "7px",
341
+ paddingYSm: "5px",
342
+ paddingXMd: "11px",
343
+ paddingYMd: "11px",
344
+ paddingXLg: "15px",
345
+ paddingYLg: "15px",
346
+ fontWeight: 700
347
+ }
348
+ }
349
+ };
350
+ var defaultTheme_default = defaultTheme;
351
+
352
+ // src/themes/mergeTheme.ts
353
+ function isPlainObject(val) {
354
+ return typeof val === "object" && val !== null && !Array.isArray(val);
355
+ }
356
+ function deepMerge(base, overrides) {
357
+ const result = { ...base };
358
+ for (const key of Object.keys(overrides)) {
359
+ const baseVal = result[key];
360
+ const overrideVal = overrides[key];
361
+ if (isPlainObject(baseVal) && isPlainObject(overrideVal)) {
362
+ result[key] = deepMerge(baseVal, overrideVal);
363
+ } else if (overrideVal !== void 0) {
364
+ result[key] = overrideVal;
365
+ }
366
+ }
367
+ return result;
368
+ }
369
+ function mergeTheme(base, overrides) {
370
+ return deepMerge(base, overrides);
371
+ }
372
+
373
+ // src/themes/theme1/index.ts
374
+ var theme1Overrides = {
375
+ colors: {
376
+ primary: "#1565C0",
377
+ primaryDark: "#003c8f",
378
+ primaryLight: "#5e92f3",
379
+ primaryContrast: "#ffffff",
380
+ secondary: "#6A1B9A",
381
+ secondaryDark: "#38006b",
382
+ secondaryLight: "#9c4dcc",
383
+ secondaryContrast: "#ffffff",
384
+ success: "#2E7D32",
385
+ warning: "#ED6C02",
386
+ error: "#D32F2F",
387
+ info: "#0288D1",
388
+ background: "#F5F7FA",
389
+ backgroundPaper: "#ffffff",
390
+ backgroundSubtle: "#EEF2F7",
391
+ textPrimary: "#1A2340",
392
+ textSecondary: "#546080",
393
+ textDisabled: "#A0AABF",
394
+ divider: "#DDE3EE",
395
+ border: "#C5CFE0",
396
+ borderFocus: "#1565C0",
397
+ overlayLight: "rgba(255, 255, 255, 0.8)",
398
+ overlayDark: "rgba(21, 101, 192, 0.12)"
399
+ },
400
+ typography: {
401
+ fontFamilyBase: '"Inter", "Roboto", "Helvetica Neue", Arial, sans-serif',
402
+ fontFamilyMono: '"Fira Code", "Courier New", monospace',
403
+ lineHeightTight: 1.2,
404
+ lineHeightBase: 1.5,
405
+ lineHeightRelaxed: 1.75,
406
+ letterSpacingTight: "-0.02em",
407
+ letterSpacingWide: "0.06em"
408
+ },
409
+ borderRadius: {
410
+ xs: "2px",
411
+ sm: "4px",
412
+ md: "8px",
413
+ lg: "12px",
414
+ xl: "16px"
415
+ },
416
+ shadows: {
417
+ xs: "0 1px 2px rgba(21, 101, 192, 0.08)",
418
+ sm: "0 2px 6px rgba(21, 101, 192, 0.10)",
419
+ md: "0 4px 12px rgba(21, 101, 192, 0.12)",
420
+ lg: "0 8px 24px rgba(21, 101, 192, 0.14)",
421
+ xl: "0 16px 48px rgba(21, 101, 192, 0.18)"
422
+ },
423
+ transitions: {
424
+ durationFast: "120ms",
425
+ durationBase: "200ms",
426
+ durationSlow: "350ms"
427
+ },
428
+ components: {
429
+ button: { borderRadius: "8px" },
430
+ input: {
431
+ borderRadius: "8px",
432
+ borderWidth: "1px",
433
+ backgroundDisabled: "#F5F7FA",
434
+ minHeight: "44px"
435
+ },
436
+ card: { borderRadius: "12px" },
437
+ tooltip: {
438
+ borderRadius: "6px",
439
+ background: "#1A2340"
440
+ },
441
+ dialog: { borderRadius: "16px" },
442
+ table: {
443
+ cellPaddingY: "12px",
444
+ headerBackground: "#EEF2F7",
445
+ rowHoverBackground: "#F5F7FA",
446
+ borderColor: "#DDE3EE"
447
+ },
448
+ avatar: { borderRadiusRounded: "12px" },
449
+ divider: { color: "#DDE3EE" },
450
+ alert: { borderRadius: "8px" },
451
+ accordion: { borderRadius: "8px" }
452
+ }
453
+ };
454
+ var theme1_default = theme1Overrides;
455
+
456
+ // src/themes/theme2/index.ts
457
+ var theme2Overrides = {
458
+ colors: {
459
+ primary: "#2E7D32",
460
+ primaryDark: "#1B5E20",
461
+ primaryLight: "#60AD5E",
462
+ primaryContrast: "#ffffff",
463
+ secondary: "#F57F17",
464
+ secondaryDark: "#BC5100",
465
+ secondaryLight: "#FFAD42",
466
+ secondaryContrast: "#1A1A1A",
467
+ success: "#388E3C",
468
+ warning: "#F57C00",
469
+ error: "#C62828",
470
+ info: "#01579B",
471
+ background: "#F7F9F5",
472
+ backgroundPaper: "#ffffff",
473
+ backgroundSubtle: "#EDF3EB",
474
+ textPrimary: "#1C2A1E",
475
+ textSecondary: "#4A6350",
476
+ textDisabled: "#9DB09F",
477
+ divider: "#D4E5D0",
478
+ border: "#B8D4B2",
479
+ borderFocus: "#2E7D32",
480
+ overlayLight: "rgba(255, 255, 255, 0.8)",
481
+ overlayDark: "rgba(46, 125, 50, 0.12)"
482
+ },
483
+ typography: {
484
+ fontFamilyBase: '"DM Sans", "Roboto", "Helvetica Neue", Arial, sans-serif',
485
+ fontFamilyMono: '"JetBrains Mono", "Courier New", monospace',
486
+ lineHeightTight: 1.25,
487
+ lineHeightBase: 1.6,
488
+ lineHeightRelaxed: 1.8,
489
+ letterSpacingTight: "-0.01em",
490
+ letterSpacingWide: "0.04em"
491
+ },
492
+ borderRadius: {
493
+ xs: "4px",
494
+ sm: "8px",
495
+ md: "12px",
496
+ lg: "20px",
497
+ xl: "28px"
498
+ },
499
+ shadows: {
500
+ xs: "0 1px 2px rgba(46, 125, 50, 0.06)",
501
+ sm: "0 2px 8px rgba(46, 125, 50, 0.08)",
502
+ md: "0 4px 16px rgba(46, 125, 50, 0.10)",
503
+ lg: "0 8px 28px rgba(46, 125, 50, 0.13)",
504
+ xl: "0 16px 56px rgba(46, 125, 50, 0.16)"
505
+ },
506
+ transitions: {
507
+ durationFast: "150ms",
508
+ durationBase: "250ms",
509
+ durationSlow: "400ms"
510
+ },
511
+ components: {
512
+ button: { borderRadius: "12px" },
513
+ input: {
514
+ borderRadius: "12px",
515
+ borderWidth: "1.5px",
516
+ backgroundDisabled: "#F7F9F5",
517
+ minHeight: "46px"
518
+ },
519
+ card: { borderRadius: "20px" },
520
+ tooltip: {
521
+ borderRadius: "8px",
522
+ background: "#1C2A1E"
523
+ },
524
+ dialog: { borderRadius: "24px" },
525
+ table: {
526
+ cellPaddingY: "14px",
527
+ headerBackground: "#EDF3EB",
528
+ rowHoverBackground: "#F7F9F5",
529
+ borderColor: "#D4E5D0"
530
+ },
531
+ avatar: { borderRadiusRounded: "16px" },
532
+ divider: { color: "#D4E5D0" },
533
+ alert: { borderRadius: "12px" },
534
+ accordion: { borderRadius: "12px" }
535
+ }
536
+ };
537
+ var theme2_default = theme2Overrides;
538
+
539
+ // src/themes/cps/index.ts
540
+ var cpsThemeOverrides = {};
541
+ var cps_default = cpsThemeOverrides;
542
+
543
+ // src/themes/registry.ts
544
+ var themeRegistry = {
545
+ theme1: theme1_default,
546
+ theme2: theme2_default,
547
+ cpsTheme: cps_default
548
+ };
549
+ function getThemeTokens(name) {
550
+ const overrides = themeRegistry[name];
551
+ if (!overrides) {
552
+ const available = Object.keys(themeRegistry).join(", ");
553
+ throw new Error(`Unknown theme "${name}". Available themes: ${available}`);
554
+ }
555
+ return mergeTheme(defaultTheme_default, overrides);
556
+ }
557
+
558
+ // src/themes/config.ts
559
+ var import_meta = {};
560
+ function resolveThemeName() {
561
+ const importMetaEnv = typeof import_meta?.env === "object" ? import_meta.env : void 0;
562
+ const env = importMetaEnv || typeof globalThis !== "undefined" && globalThis.process?.env || {};
563
+ const raw = env["VITE_THEME"] || env["REACT_APP_THEME"] || env["NEXT_PUBLIC_THEME"] || "cpsTheme";
564
+ return raw;
565
+ }
566
+
567
+ // src/themes/createMuiTheme.ts
568
+ var import_styles = require("@mui/material/styles");
569
+ function createMuiTheme(tokens) {
570
+ return (0, import_styles.createTheme)({
571
+ palette: {
572
+ primary: {
573
+ main: tokens.colors.primary,
574
+ dark: tokens.colors.primaryDark,
575
+ light: tokens.colors.primaryLight,
576
+ contrastText: tokens.colors.primaryContrast
577
+ },
578
+ secondary: {
579
+ main: tokens.colors.secondary,
580
+ dark: tokens.colors.secondaryDark,
581
+ light: tokens.colors.secondaryLight,
582
+ contrastText: tokens.colors.secondaryContrast
583
+ },
584
+ success: { main: tokens.colors.success },
585
+ warning: { main: tokens.colors.warning },
586
+ error: { main: tokens.colors.error },
587
+ info: { main: tokens.colors.info },
588
+ background: {
589
+ default: tokens.colors.background,
590
+ paper: tokens.colors.backgroundPaper,
591
+ subtle: tokens.colors.backgroundSubtle
592
+ },
593
+ border: tokens.colors.border,
594
+ text: {
595
+ primary: tokens.colors.textPrimary,
596
+ secondary: tokens.colors.textSecondary,
597
+ disabled: tokens.colors.textDisabled
598
+ },
599
+ divider: tokens.colors.divider
600
+ },
601
+ typography: {
602
+ fontFamily: tokens.typography.fontFamilyBase,
603
+ fontWeightLight: tokens.typography.fontWeightLight,
604
+ fontWeightRegular: tokens.typography.fontWeightRegular,
605
+ fontWeightMedium: tokens.typography.fontWeightMedium,
606
+ fontWeightBold: tokens.typography.fontWeightBold,
607
+ fontSize: 14
608
+ // MUI base, actual sizes come from tokens
609
+ },
610
+ shape: {
611
+ borderRadius: 8
612
+ // MUI uses a number; components use tokens directly
613
+ },
614
+ spacing: tokens.spacing.unit,
615
+ zIndex: {
616
+ appBar: tokens.zIndex.sticky,
617
+ drawer: tokens.zIndex.overlay,
618
+ modal: tokens.zIndex.modal,
619
+ snackbar: tokens.zIndex.toast,
620
+ tooltip: tokens.zIndex.tooltip
621
+ },
622
+ components: {
623
+ MuiButton: {
624
+ defaultProps: {
625
+ disableElevation: true
626
+ },
627
+ styleOverrides: {
628
+ root: {
629
+ borderRadius: tokens.components.button.borderRadius,
630
+ fontWeight: tokens.components.button.fontWeight,
631
+ letterSpacing: tokens.components.button.letterSpacing,
632
+ textTransform: tokens.components.button.textTransform,
633
+ fontSize: tokens.components.button.fontSizeMd,
634
+ minHeight: tokens.components.button.heightMd,
635
+ paddingLeft: tokens.components.button.paddingX,
636
+ paddingRight: tokens.components.button.paddingX,
637
+ paddingTop: tokens.components.button.paddingY,
638
+ paddingBottom: tokens.components.button.paddingY,
639
+ boxShadow: tokens.shadows.none,
640
+ transition: `all ${tokens.transitions.durationBase} ${tokens.transitions.easingDefault}`,
641
+ "&:hover": {
642
+ boxShadow: tokens.shadows.none
643
+ }
644
+ },
645
+ sizeSmall: {
646
+ fontSize: tokens.components.button.fontSizeSm,
647
+ minHeight: tokens.components.button.heightSm,
648
+ paddingLeft: tokens.components.button.paddingXSm,
649
+ paddingRight: tokens.components.button.paddingXSm,
650
+ paddingTop: tokens.components.button.paddingYSm,
651
+ paddingBottom: tokens.components.button.paddingYSm
652
+ },
653
+ sizeLarge: {
654
+ fontSize: tokens.components.button.fontSizeLg,
655
+ minHeight: tokens.components.button.heightLg,
656
+ paddingLeft: tokens.components.button.paddingXLg,
657
+ paddingRight: tokens.components.button.paddingXLg,
658
+ paddingTop: tokens.components.button.paddingYLg,
659
+ paddingBottom: tokens.components.button.paddingYLg
660
+ }
661
+ },
662
+ variants: [
663
+ // xlarge size
664
+ {
665
+ props: { size: "xlarge" },
666
+ style: {
667
+ fontSize: tokens.components.button.fontSizeLg,
668
+ minHeight: tokens.components.button.heightXl,
669
+ paddingLeft: tokens.components.button.paddingXXl,
670
+ paddingRight: tokens.components.button.paddingXXl,
671
+ paddingTop: tokens.components.button.paddingYXl,
672
+ paddingBottom: tokens.components.button.paddingYXl
673
+ }
674
+ },
675
+ // soft variant — base (inherit/no color)
676
+ {
677
+ props: { variant: "soft" },
678
+ style: {
679
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.textSecondary, 0.12),
680
+ color: tokens.colors.textPrimary,
681
+ boxShadow: tokens.shadows.none,
682
+ "&:hover": {
683
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.textSecondary, 0.2),
684
+ boxShadow: tokens.shadows.none
685
+ },
686
+ "&.Mui-disabled": {
687
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.textDisabled, 0.12),
688
+ color: tokens.colors.textDisabled
689
+ }
690
+ }
691
+ },
692
+ // soft variant — primary
693
+ {
694
+ props: { variant: "soft", color: "primary" },
695
+ style: {
696
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.primary, 0.16),
697
+ color: tokens.colors.primaryDark,
698
+ "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.primary, 0.24) }
699
+ }
700
+ },
701
+ // soft variant — secondary
702
+ {
703
+ props: { variant: "soft", color: "secondary" },
704
+ style: {
705
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.secondary, 0.16),
706
+ color: tokens.colors.secondaryDark,
707
+ "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.secondary, 0.24) }
708
+ }
709
+ },
710
+ // soft variant — error
711
+ {
712
+ props: { variant: "soft", color: "error" },
713
+ style: {
714
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.error, 0.16),
715
+ color: (0, import_styles.darken)(tokens.colors.error, 0.2),
716
+ "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.error, 0.24) }
717
+ }
718
+ },
719
+ // soft variant — warning
720
+ {
721
+ props: { variant: "soft", color: "warning" },
722
+ style: {
723
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.warning, 0.16),
724
+ color: (0, import_styles.darken)(tokens.colors.warning, 0.2),
725
+ "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.warning, 0.24) }
726
+ }
727
+ },
728
+ // soft variant — success
729
+ {
730
+ props: { variant: "soft", color: "success" },
731
+ style: {
732
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.success, 0.16),
733
+ color: (0, import_styles.darken)(tokens.colors.success, 0.2),
734
+ "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.success, 0.24) }
735
+ }
736
+ },
737
+ // soft variant — info
738
+ {
739
+ props: { variant: "soft", color: "info" },
740
+ style: {
741
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.info, 0.16),
742
+ color: (0, import_styles.darken)(tokens.colors.info, 0.2),
743
+ "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.info, 0.24) }
744
+ }
745
+ }
746
+ ]
747
+ },
748
+ MuiTextField: {
749
+ styleOverrides: {
750
+ root: {
751
+ "& .MuiOutlinedInput-root": {
752
+ borderRadius: tokens.components.input.borderRadius,
753
+ backgroundColor: tokens.components.input.background,
754
+ minHeight: tokens.components.input.minHeight,
755
+ "& fieldset": {
756
+ borderWidth: tokens.components.input.borderWidth,
757
+ borderColor: tokens.colors.border
758
+ },
759
+ "&:hover fieldset": {
760
+ borderColor: tokens.colors.primary
761
+ },
762
+ "&.Mui-focused fieldset": {
763
+ borderWidth: tokens.components.input.borderWidthFocus,
764
+ borderColor: tokens.colors.borderFocus
765
+ },
766
+ "&.Mui-disabled": {
767
+ backgroundColor: tokens.components.input.backgroundDisabled
768
+ }
769
+ },
770
+ "& .MuiInputLabel-root": {
771
+ fontSize: tokens.components.input.labelFontSize
772
+ },
773
+ "& .MuiFormHelperText-root": {
774
+ fontSize: tokens.components.input.helperFontSize
775
+ }
776
+ }
777
+ }
778
+ },
779
+ MuiCard: {
780
+ styleOverrides: {
781
+ root: {
782
+ borderRadius: tokens.components.card.borderRadius,
783
+ backgroundColor: tokens.components.card.background,
784
+ boxShadow: tokens.shadows.sm,
785
+ border: `${tokens.components.card.borderWidth} solid ${tokens.colors.divider}`
786
+ }
787
+ }
788
+ },
789
+ MuiCardContent: {
790
+ styleOverrides: {
791
+ root: {
792
+ padding: tokens.components.card.padding,
793
+ "&:last-child": {
794
+ paddingBottom: tokens.components.card.padding
795
+ }
796
+ }
797
+ }
798
+ },
799
+ MuiChip: {
800
+ styleOverrides: {
801
+ root: {
802
+ height: tokens.components.chip.height,
803
+ borderRadius: tokens.components.chip.borderRadius,
804
+ fontSize: tokens.components.chip.fontSize,
805
+ fontWeight: tokens.components.chip.fontWeight,
806
+ paddingLeft: tokens.components.chip.paddingX,
807
+ paddingRight: tokens.components.chip.paddingX
808
+ },
809
+ sizeSmall: {
810
+ height: tokens.components.chip.heightSm
811
+ },
812
+ icon: {
813
+ width: tokens.components.chip.iconSize,
814
+ height: tokens.components.chip.iconSize
815
+ }
816
+ },
817
+ variants: [
818
+ // ── soft — base (default color) ───────────────────────────────────
819
+ {
820
+ props: { variant: "soft" },
821
+ style: {
822
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.textSecondary, 0.12),
823
+ color: tokens.colors.textPrimary,
824
+ "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.textSecondary, 0.2) },
825
+ "&.Mui-disabled": { opacity: 0.6 }
826
+ }
827
+ },
828
+ { props: { variant: "soft", color: "primary" }, style: { backgroundColor: (0, import_styles.alpha)(tokens.colors.primary, 0.16), color: (0, import_styles.darken)(tokens.colors.primary, 0.2), "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.primary, 0.24) } } },
829
+ { props: { variant: "soft", color: "secondary" }, style: { backgroundColor: (0, import_styles.alpha)(tokens.colors.secondary, 0.16), color: (0, import_styles.darken)(tokens.colors.secondary, 0.2), "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.secondary, 0.24) } } },
830
+ { props: { variant: "soft", color: "info" }, style: { backgroundColor: (0, import_styles.alpha)(tokens.colors.info, 0.16), color: (0, import_styles.darken)(tokens.colors.info, 0.2), "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.info, 0.24) } } },
831
+ { props: { variant: "soft", color: "success" }, style: { backgroundColor: (0, import_styles.alpha)(tokens.colors.success, 0.16), color: (0, import_styles.darken)(tokens.colors.success, 0.2), "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.success, 0.24) } } },
832
+ { props: { variant: "soft", color: "warning" }, style: { backgroundColor: (0, import_styles.alpha)(tokens.colors.warning, 0.16), color: (0, import_styles.darken)(tokens.colors.warning, 0.2), "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.warning, 0.24) } } },
833
+ { props: { variant: "soft", color: "error" }, style: { backgroundColor: (0, import_styles.alpha)(tokens.colors.error, 0.16), color: (0, import_styles.darken)(tokens.colors.error, 0.2), "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.error, 0.24) } } },
834
+ // ── black ─────────────────────────────────────────────────────────
835
+ { props: { variant: "filled", color: "black" }, style: { backgroundColor: tokens.colors.textPrimary, color: tokens.colors.backgroundPaper, "&:hover": { backgroundColor: (0, import_styles.darken)(tokens.colors.textPrimary, 0.1) } } },
836
+ { props: { variant: "outlined", color: "black" }, style: { borderColor: tokens.colors.textPrimary, color: tokens.colors.textPrimary } },
837
+ { props: { variant: "soft", color: "black" }, style: { backgroundColor: (0, import_styles.alpha)(tokens.colors.textPrimary, 0.12), color: tokens.colors.textPrimary, "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.textPrimary, 0.2) } } },
838
+ // ── white ─────────────────────────────────────────────────────────
839
+ { props: { variant: "filled", color: "white" }, style: { backgroundColor: tokens.colors.backgroundPaper, color: tokens.colors.textPrimary, border: `1px solid ${tokens.colors.divider}`, "&:hover": { backgroundColor: tokens.colors.backgroundSubtle } } },
840
+ { props: { variant: "outlined", color: "white" }, style: { borderColor: (0, import_styles.alpha)(tokens.colors.backgroundPaper, 0.32), color: tokens.colors.backgroundPaper } },
841
+ { props: { variant: "soft", color: "white" }, style: { backgroundColor: (0, import_styles.alpha)(tokens.colors.backgroundPaper, 0.16), color: tokens.colors.backgroundPaper, "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.backgroundPaper, 0.24) } } }
842
+ ]
843
+ },
844
+ MuiBadge: {
845
+ styleOverrides: {
846
+ badge: {
847
+ height: tokens.components.badge.height,
848
+ minWidth: tokens.components.badge.minWidth,
849
+ borderRadius: tokens.components.badge.borderRadius,
850
+ fontSize: tokens.components.badge.fontSize,
851
+ fontWeight: tokens.components.badge.fontWeight,
852
+ padding: `0 ${tokens.components.badge.paddingX}`
853
+ }
854
+ }
855
+ },
856
+ MuiTooltip: {
857
+ styleOverrides: {
858
+ tooltip: {
859
+ backgroundColor: tokens.components.tooltip.background,
860
+ color: tokens.components.tooltip.color,
861
+ borderRadius: tokens.components.tooltip.borderRadius,
862
+ fontSize: tokens.components.tooltip.fontSize,
863
+ padding: `${tokens.components.tooltip.paddingY} ${tokens.components.tooltip.paddingX}`,
864
+ maxWidth: tokens.components.tooltip.maxWidth
865
+ }
866
+ }
867
+ },
868
+ MuiDialog: {
869
+ styleOverrides: {
870
+ paper: {
871
+ borderRadius: tokens.components.dialog.borderRadius,
872
+ backgroundColor: tokens.components.dialog.background,
873
+ maxWidth: tokens.components.dialog.maxWidth
874
+ }
875
+ }
876
+ },
877
+ MuiDialogContent: {
878
+ styleOverrides: {
879
+ root: {
880
+ padding: tokens.components.dialog.padding
881
+ }
882
+ }
883
+ },
884
+ MuiTableCell: {
885
+ styleOverrides: {
886
+ root: {
887
+ paddingLeft: tokens.components.table.cellPaddingX,
888
+ paddingRight: tokens.components.table.cellPaddingX,
889
+ paddingTop: tokens.components.table.cellPaddingY,
890
+ paddingBottom: tokens.components.table.cellPaddingY,
891
+ borderBottom: `${tokens.components.table.borderWidth} solid ${tokens.components.table.borderColor}`
892
+ },
893
+ head: {
894
+ fontWeight: tokens.components.table.headerFontWeight,
895
+ backgroundColor: tokens.components.table.headerBackground
896
+ }
897
+ }
898
+ },
899
+ MuiTableRow: {
900
+ styleOverrides: {
901
+ root: {
902
+ "&:hover": {
903
+ backgroundColor: tokens.components.table.rowHoverBackground
904
+ }
905
+ }
906
+ }
907
+ },
908
+ MuiAvatar: {
909
+ styleOverrides: {
910
+ root: {
911
+ width: tokens.components.avatar.sizeMd,
912
+ height: tokens.components.avatar.sizeMd,
913
+ borderRadius: tokens.components.avatar.borderRadius,
914
+ fontSize: tokens.typography.fontSizeLg,
915
+ fontWeight: tokens.typography.fontWeightSemiBold
916
+ },
917
+ rounded: {
918
+ borderRadius: tokens.components.avatar.borderRadiusRounded
919
+ }
920
+ }
921
+ },
922
+ MuiAvatarGroup: {
923
+ styleOverrides: {
924
+ root: {
925
+ "& .MuiAvatar-root": {
926
+ marginLeft: tokens.components.avatar.groupSpacing,
927
+ border: `${tokens.components.avatar.groupBorderWidth} solid ${tokens.colors.backgroundPaper}`,
928
+ boxSizing: "content-box"
929
+ }
930
+ }
931
+ }
932
+ },
933
+ MuiDivider: {
934
+ styleOverrides: {
935
+ root: {
936
+ borderColor: tokens.components.divider.color,
937
+ borderBottomWidth: tokens.components.divider.thickness
938
+ }
939
+ }
940
+ },
941
+ MuiAlert: {
942
+ styleOverrides: {
943
+ root: {
944
+ alignItems: "center",
945
+ borderRadius: tokens.components.alert.borderRadius,
946
+ padding: tokens.components.alert.padding,
947
+ fontSize: tokens.typography.fontSizeMd
948
+ },
949
+ // ── Standard ──────────────────────────────────────────────────────
950
+ standardInfo: {
951
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.info, 0.16),
952
+ color: (0, import_styles.darken)(tokens.colors.info, 0.4),
953
+ "& .MuiAlert-icon": { color: tokens.colors.info }
954
+ },
955
+ standardSuccess: {
956
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.success, 0.16),
957
+ color: (0, import_styles.darken)(tokens.colors.success, 0.4),
958
+ "& .MuiAlert-icon": { color: tokens.colors.success }
959
+ },
960
+ standardWarning: {
961
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.warning, 0.16),
962
+ color: (0, import_styles.darken)(tokens.colors.warning, 0.4),
963
+ "& .MuiAlert-icon": { color: tokens.colors.warning }
964
+ },
965
+ standardError: {
966
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.error, 0.16),
967
+ color: (0, import_styles.darken)(tokens.colors.error, 0.4),
968
+ "& .MuiAlert-icon": { color: tokens.colors.error }
969
+ },
970
+ // ── Filled ────────────────────────────────────────────────────────
971
+ filledInfo: {
972
+ backgroundColor: tokens.colors.info,
973
+ color: tokens.colors.primaryContrast,
974
+ fontWeight: tokens.typography.fontWeightMedium
975
+ },
976
+ filledSuccess: {
977
+ backgroundColor: tokens.colors.success,
978
+ color: tokens.colors.primaryContrast,
979
+ fontWeight: tokens.typography.fontWeightMedium
980
+ },
981
+ filledWarning: {
982
+ backgroundColor: tokens.colors.warning,
983
+ // Warning is light enough to need dark text
984
+ color: tokens.colors.textPrimary,
985
+ fontWeight: tokens.typography.fontWeightMedium,
986
+ "& .MuiAlert-icon": { color: tokens.colors.textPrimary }
987
+ },
988
+ filledError: {
989
+ backgroundColor: tokens.colors.error,
990
+ color: tokens.colors.primaryContrast,
991
+ fontWeight: tokens.typography.fontWeightMedium
992
+ },
993
+ // ── Outlined ──────────────────────────────────────────────────────
994
+ outlinedInfo: {
995
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.info, 0.08),
996
+ color: (0, import_styles.darken)(tokens.colors.info, 0.2),
997
+ borderColor: (0, import_styles.alpha)(tokens.colors.info, 0.32),
998
+ "& .MuiAlert-icon": { color: tokens.colors.info }
999
+ },
1000
+ outlinedSuccess: {
1001
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.success, 0.08),
1002
+ color: (0, import_styles.darken)(tokens.colors.success, 0.2),
1003
+ borderColor: (0, import_styles.alpha)(tokens.colors.success, 0.32),
1004
+ "& .MuiAlert-icon": { color: tokens.colors.success }
1005
+ },
1006
+ outlinedWarning: {
1007
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.warning, 0.08),
1008
+ color: (0, import_styles.darken)(tokens.colors.warning, 0.2),
1009
+ borderColor: (0, import_styles.alpha)(tokens.colors.warning, 0.32),
1010
+ "& .MuiAlert-icon": { color: tokens.colors.warning }
1011
+ },
1012
+ outlinedError: {
1013
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.error, 0.08),
1014
+ color: (0, import_styles.darken)(tokens.colors.error, 0.2),
1015
+ borderColor: (0, import_styles.alpha)(tokens.colors.error, 0.32),
1016
+ "& .MuiAlert-icon": { color: tokens.colors.error }
1017
+ },
1018
+ icon: {
1019
+ opacity: 1,
1020
+ padding: 0
1021
+ },
1022
+ message: {
1023
+ padding: "4px 0"
1024
+ }
1025
+ }
1026
+ },
1027
+ MuiAlertTitle: {
1028
+ styleOverrides: {
1029
+ root: {
1030
+ fontWeight: tokens.typography.fontWeightSemiBold,
1031
+ marginBottom: "4px"
1032
+ }
1033
+ }
1034
+ },
1035
+ MuiAccordion: {
1036
+ styleOverrides: {
1037
+ root: {
1038
+ borderRadius: tokens.components.accordion.borderRadius,
1039
+ boxShadow: tokens.shadows.md,
1040
+ marginBottom: tokens.spacing.sm,
1041
+ "&:before": { display: "none" },
1042
+ "&.Mui-expanded": { margin: `0 0 ${tokens.spacing.sm}` },
1043
+ "&:first-of-type": { borderRadius: tokens.components.accordion.borderRadius },
1044
+ "&:last-of-type": { borderRadius: tokens.components.accordion.borderRadius }
1045
+ }
1046
+ }
1047
+ },
1048
+ MuiAccordionSummary: {
1049
+ styleOverrides: {
1050
+ root: {
1051
+ padding: `${tokens.components.accordion.summaryPaddingY} 8px ${tokens.components.accordion.summaryPaddingY} ${tokens.components.accordion.summaryPaddingX}`,
1052
+ fontWeight: tokens.components.accordion.summaryFontWeight,
1053
+ minHeight: "auto",
1054
+ "&.Mui-expanded": { minHeight: "auto" }
1055
+ },
1056
+ content: {
1057
+ margin: 0,
1058
+ "&.Mui-expanded": { margin: 0 }
1059
+ },
1060
+ expandIconWrapper: {
1061
+ color: tokens.colors.textSecondary
1062
+ }
1063
+ }
1064
+ },
1065
+ MuiAccordionDetails: {
1066
+ styleOverrides: {
1067
+ root: {
1068
+ padding: `0 ${tokens.components.accordion.detailsPaddingX} ${tokens.components.accordion.detailsPaddingBottom}`
1069
+ }
1070
+ }
1071
+ },
1072
+ MuiToggleButton: {
1073
+ styleOverrides: {
1074
+ root: {
1075
+ borderRadius: tokens.components.toggleButton.borderRadius,
1076
+ borderWidth: tokens.components.toggleButton.borderWidth,
1077
+ borderColor: tokens.colors.border,
1078
+ fontWeight: tokens.components.toggleButton.fontWeight,
1079
+ paddingLeft: tokens.components.toggleButton.paddingXMd,
1080
+ paddingRight: tokens.components.toggleButton.paddingXMd,
1081
+ paddingTop: tokens.components.toggleButton.paddingYMd,
1082
+ paddingBottom: tokens.components.toggleButton.paddingYMd,
1083
+ textTransform: "none",
1084
+ transition: `all ${tokens.transitions.durationBase} ${tokens.transitions.easingDefault}`,
1085
+ "&.Mui-selected": {
1086
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.textPrimary, 0.08),
1087
+ color: tokens.colors.textPrimary,
1088
+ "&:hover": {
1089
+ backgroundColor: (0, import_styles.alpha)(tokens.colors.textPrimary, 0.16)
1090
+ }
1091
+ },
1092
+ "&.Mui-disabled": {
1093
+ borderColor: tokens.colors.border
1094
+ }
1095
+ },
1096
+ sizeSmall: {
1097
+ paddingLeft: tokens.components.toggleButton.paddingXSm,
1098
+ paddingRight: tokens.components.toggleButton.paddingXSm,
1099
+ paddingTop: tokens.components.toggleButton.paddingYSm,
1100
+ paddingBottom: tokens.components.toggleButton.paddingYSm
1101
+ },
1102
+ sizeLarge: {
1103
+ paddingLeft: tokens.components.toggleButton.paddingXLg,
1104
+ paddingRight: tokens.components.toggleButton.paddingXLg,
1105
+ paddingTop: tokens.components.toggleButton.paddingYLg,
1106
+ paddingBottom: tokens.components.toggleButton.paddingYLg
1107
+ }
1108
+ },
1109
+ variants: [
1110
+ { props: { color: "primary" }, style: { "&.Mui-selected": { backgroundColor: (0, import_styles.alpha)(tokens.colors.primary, 0.16), color: tokens.colors.primary, "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.primary, 0.24) } } } },
1111
+ { props: { color: "secondary" }, style: { "&.Mui-selected": { backgroundColor: (0, import_styles.alpha)(tokens.colors.secondary, 0.16), color: tokens.colors.secondary, "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.secondary, 0.24) } } } },
1112
+ { props: { color: "info" }, style: { "&.Mui-selected": { backgroundColor: (0, import_styles.alpha)(tokens.colors.info, 0.16), color: tokens.colors.info, "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.info, 0.24) } } } },
1113
+ { props: { color: "success" }, style: { "&.Mui-selected": { backgroundColor: (0, import_styles.alpha)(tokens.colors.success, 0.16), color: tokens.colors.success, "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.success, 0.24) } } } },
1114
+ { props: { color: "warning" }, style: { "&.Mui-selected": { backgroundColor: (0, import_styles.alpha)(tokens.colors.warning, 0.16), color: tokens.colors.warning, "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.warning, 0.24) } } } },
1115
+ { props: { color: "error" }, style: { "&.Mui-selected": { backgroundColor: (0, import_styles.alpha)(tokens.colors.error, 0.16), color: tokens.colors.error, "&:hover": { backgroundColor: (0, import_styles.alpha)(tokens.colors.error, 0.24) } } } }
1116
+ ]
1117
+ },
1118
+ MuiToggleButtonGroup: {
1119
+ styleOverrides: {
1120
+ root: {
1121
+ borderRadius: tokens.components.toggleButton.borderRadius
1122
+ },
1123
+ grouped: {
1124
+ "&:not(:first-of-type)": {
1125
+ borderColor: tokens.colors.border
1126
+ }
1127
+ }
1128
+ }
1129
+ },
1130
+ MuiPaper: {
1131
+ styleOverrides: {
1132
+ root: {
1133
+ backgroundImage: "none"
1134
+ // Remove MUI's default gradient on dark mode
1135
+ },
1136
+ elevation1: { boxShadow: tokens.shadows.sm },
1137
+ elevation2: { boxShadow: tokens.shadows.md },
1138
+ elevation3: { boxShadow: tokens.shadows.lg }
1139
+ }
1140
+ }
1141
+ },
1142
+ // Attach the raw tokens to the theme so any component can access
1143
+ // values not already covered by MUI's built-in theme shape.
1144
+ // @ts-ignore — augmented in src/types/mui.d.ts
1145
+ tokens
1146
+ });
1147
+ }
1148
+
1149
+ // src/ThemeProvider.tsx
1150
+ var import_jsx_runtime = require("react/jsx-runtime");
1151
+ function ToolkitThemeProvider({
1152
+ theme,
1153
+ children,
1154
+ injectCssBaseline = true
1155
+ }) {
1156
+ const themeName = theme ?? resolveThemeName();
1157
+ const tokens = getThemeTokens(themeName);
1158
+ const muiTheme = createMuiTheme(tokens);
1159
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_material.ThemeProvider, { theme: muiTheme, children: [
1160
+ injectCssBaseline && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_material.CssBaseline, {}),
1161
+ children
1162
+ ] });
1163
+ }
1164
+
1165
+ // src/components/Button/Button.tsx
1166
+ var import_material2 = require("@mui/material");
1167
+ var import_styles2 = require("@mui/material/styles");
1168
+ var import_jsx_runtime2 = require("react/jsx-runtime");
1169
+ var StyledButton = (0, import_styles2.styled)(import_material2.Button)(({ theme }) => ({
1170
+ // Gap between icon and label — not surfaced by MUI's styleOverrides
1171
+ "& .MuiButton-startIcon": {
1172
+ marginRight: theme.tokens.components.button.iconGap
1173
+ },
1174
+ "& .MuiButton-endIcon": {
1175
+ marginLeft: theme.tokens.components.button.iconGap
1176
+ }
1177
+ }));
1178
+ function Button({ loading, disabled, children, ...props }) {
1179
+ const baseLabel = props["aria-label"] ?? (typeof children === "string" ? children : void 0);
1180
+ const ariaLabel = loading && baseLabel ? `${baseLabel}, loading` : props["aria-label"];
1181
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
1182
+ StyledButton,
1183
+ {
1184
+ ...props,
1185
+ disabled: disabled || loading,
1186
+ "aria-busy": loading || void 0,
1187
+ "aria-label": ariaLabel,
1188
+ startIcon: loading ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_material2.CircularProgress, { size: 16, color: "inherit" }) : props.startIcon,
1189
+ children
1190
+ }
1191
+ );
1192
+ }
1193
+ Button.displayName = "ToolkitButton";
1194
+
1195
+ // src/components/Chip/Chip.tsx
1196
+ var import_material3 = require("@mui/material");
1197
+ var import_jsx_runtime3 = require("react/jsx-runtime");
1198
+ function CircleXIcon(props) {
1199
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material3.SvgIcon, { ...props, viewBox: "0 0 24 24", children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
1200
+ "path",
1201
+ {
1202
+ fill: "currentColor",
1203
+ fillRule: "evenodd",
1204
+ d: "M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12S6.477 2 12 2s10 4.477 10 10M8.97 8.97a.75.75 0 0 1 1.06 0L12 10.94l1.97-1.97a.75.75 0 0 1 1.06 1.06L13.06 12l1.97 1.97a.75.75 0 0 1-1.06 1.06L12 13.06l-1.97 1.97a.75.75 0 0 1-1.06-1.06L10.94 12l-1.97-1.97a.75.75 0 0 1 0-1.06",
1205
+ clipRule: "evenodd"
1206
+ }
1207
+ ) });
1208
+ }
1209
+ function Chip({ deleteIcon, onDelete, ...props }) {
1210
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
1211
+ import_material3.Chip,
1212
+ {
1213
+ ...props,
1214
+ onDelete,
1215
+ deleteIcon: onDelete ? deleteIcon ?? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(CircleXIcon, {}) : void 0
1216
+ }
1217
+ );
1218
+ }
1219
+ Chip.displayName = "ToolkitChip";
1220
+
1221
+ // src/components/Card/Card.tsx
1222
+ var import_material4 = require("@mui/material");
1223
+ var import_styles3 = require("@mui/material/styles");
1224
+ var import_jsx_runtime4 = require("react/jsx-runtime");
1225
+ var StyledCard = (0, import_styles3.styled)(import_material4.Card, {
1226
+ shouldForwardProp: (prop) => prop !== "compact"
1227
+ })(({ theme, compact }) => ({
1228
+ padding: compact ? theme.tokens.components.card.paddingCompact : theme.tokens.components.card.padding,
1229
+ // Override MUI CardContent's own padding since we set it at the Card level
1230
+ "& .MuiCardContent-root": {
1231
+ padding: 0,
1232
+ "&:last-child": { paddingBottom: 0 }
1233
+ },
1234
+ "&:hover": {
1235
+ boxShadow: theme.tokens.shadows.md,
1236
+ transition: `box-shadow ${theme.tokens.transitions.durationBase} ${theme.tokens.transitions.easingDefault}`
1237
+ }
1238
+ }));
1239
+ function Card({ compact, children, ...props }) {
1240
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(StyledCard, { compact, ...props, children });
1241
+ }
1242
+ var CardContent = import_material4.CardContent;
1243
+ var CardHeader = import_material4.CardHeader;
1244
+ var CardActions = import_material4.CardActions;
1245
+ Card.displayName = "ToolkitCard";
1246
+
1247
+ // src/components/TextField/TextField.tsx
1248
+ var import_material5 = require("@mui/material");
1249
+ var import_styles4 = require("@mui/material/styles");
1250
+ var import_jsx_runtime5 = require("react/jsx-runtime");
1251
+ var StyledTextField = (0, import_styles4.styled)(import_material5.TextField)(({ theme }) => ({
1252
+ // Transition on the entire field when focus changes
1253
+ "& .MuiOutlinedInput-root": {
1254
+ transition: `box-shadow ${theme.tokens.transitions.durationFast} ${theme.tokens.transitions.easingDefault}`,
1255
+ "&.Mui-focused": {
1256
+ boxShadow: theme.tokens.shadows.xs
1257
+ }
1258
+ }
1259
+ }));
1260
+ function TextField({ error, FormHelperTextProps, inputProps, label, ...props }) {
1261
+ if (process.env.NODE_ENV !== "production") {
1262
+ if (!label && !props["aria-label"] && !props["aria-labelledby"] && !inputProps?.["aria-label"] && !inputProps?.["aria-labelledby"]) {
1263
+ console.warn("[ToolkitTextField] Missing accessible label. Provide `label`, `aria-label`, or `aria-labelledby`.");
1264
+ }
1265
+ }
1266
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1267
+ StyledTextField,
1268
+ {
1269
+ fullWidth: true,
1270
+ variant: "outlined",
1271
+ label,
1272
+ error,
1273
+ inputProps,
1274
+ FormHelperTextProps: error ? { role: "alert", ...FormHelperTextProps } : FormHelperTextProps,
1275
+ ...props
1276
+ }
1277
+ );
1278
+ }
1279
+ TextField.displayName = "ToolkitTextField";
1280
+
1281
+ // src/components/Alert/Alert.tsx
1282
+ var import_material6 = require("@mui/material");
1283
+ var import_jsx_runtime6 = require("react/jsx-runtime");
1284
+ var InfoIcon = /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_material6.SvgIcon, { viewBox: "0 0 24 24", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("path", { fill: "currentColor", fillRule: "evenodd", d: "M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12S6.477 2 12 2s10 4.477 10 10m-10 5.75a.75.75 0 0 0 .75-.75v-6a.75.75 0 0 0-1.5 0v6c0 .414.336.75.75.75M12 7a1 1 0 1 1 0 2a1 1 0 0 1 0-2", clipRule: "evenodd" }) });
1285
+ var SuccessIcon = /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_material6.SvgIcon, { viewBox: "0 0 24 24", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("path", { fill: "currentColor", fillRule: "evenodd", d: "M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12S6.477 2 12 2s10 4.477 10 10m-5.97-3.03a.75.75 0 0 1 0 1.06l-5 5a.75.75 0 0 1-1.06 0l-2-2a.75.75 0 1 1 1.06-1.06l1.47 1.47l2.235-2.235L14.97 8.97a.75.75 0 0 1 1.06 0", clipRule: "evenodd" }) });
1286
+ var WarningIcon = /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_material6.SvgIcon, { viewBox: "0 0 24 24", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("path", { fill: "currentColor", fillRule: "evenodd", d: "M5.312 10.762C8.23 5.587 9.689 3 12 3c2.31 0 3.77 2.587 6.688 7.762l.364.644c2.425 4.3 3.638 6.45 2.542 8.022S17.786 21 12.364 21h-.728c-5.422 0-8.134 0-9.23-1.572s.117-3.722 2.542-8.022zM12 7.25a.75.75 0 0 1 .75.75v5a.75.75 0 0 1-1.5 0V8a.75.75 0 0 1 .75-.75M12 17a1 1 0 1 0 0-2a1 1 0 0 0 0 2", clipRule: "evenodd" }) });
1287
+ var ErrorIcon = /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_material6.SvgIcon, { viewBox: "0 0 24 24", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("path", { fill: "currentColor", fillRule: "evenodd", d: "M7.843 3.802C9.872 2.601 10.886 2 12 2c1.114 0 2.128.6 4.157 1.802l.686.406c2.029 1.202 3.043 1.803 3.6 2.792c.557.99.557 2.19.557 4.594v.812c0 2.403 0 3.605-.557 4.594c-.557.99-1.571 1.59-3.6 2.791l-.686.407C14.128 21.399 13.114 22 12 22c-1.114 0-2.128-.6-4.157-1.802l-.686-.407c-2.029-1.2-3.043-1.802-3.6-2.791C3 16.01 3 14.81 3 12.406v-.812C3 9.19 3 7.989 3.557 7c.557-.99 1.571-1.59 3.6-2.792zM13 16a1 1 0 1 1-2 0a1 1 0 0 1 2 0m-1-9.75a.75.75 0 0 1 .75.75v6a.75.75 0 0 1-1.5 0V7a.75.75 0 0 1 .75-.75", clipRule: "evenodd" }) });
1288
+ var defaultIconMapping = {
1289
+ info: InfoIcon,
1290
+ success: SuccessIcon,
1291
+ warning: WarningIcon,
1292
+ error: ErrorIcon
1293
+ };
1294
+ function Alert({ iconMapping, ...props }) {
1295
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_material6.Alert, { iconMapping: { ...defaultIconMapping, ...iconMapping }, ...props });
1296
+ }
1297
+ function AlertTitle(props) {
1298
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_material6.AlertTitle, { ...props });
1299
+ }
1300
+ Alert.displayName = "ToolkitAlert";
1301
+ AlertTitle.displayName = "ToolkitAlertTitle";
1302
+
1303
+ // src/components/Accordion/Accordion.tsx
1304
+ var import_material7 = require("@mui/material");
1305
+ var import_styles5 = require("@mui/material/styles");
1306
+ var import_ExpandMore = __toESM(require("@mui/icons-material/ExpandMore"));
1307
+ var import_jsx_runtime7 = require("react/jsx-runtime");
1308
+ var StandaloneAccordion = (0, import_styles5.styled)(import_material7.Accordion)(({ theme }) => ({
1309
+ borderRadius: `${theme.tokens.components.accordion.standaloneRadius} !important`,
1310
+ backgroundColor: theme.tokens.components.accordion.standaloneBackground,
1311
+ boxShadow: "none",
1312
+ marginBottom: theme.spacing(1),
1313
+ "&.Mui-expanded": {
1314
+ backgroundColor: theme.tokens.components.accordion.standaloneBackgroundExpanded,
1315
+ margin: `0 0 ${theme.spacing(1)}`
1316
+ },
1317
+ "& .MuiAccordionSummary-root": {
1318
+ padding: `${theme.tokens.components.accordion.summaryPaddingY} ${theme.tokens.components.accordion.summaryPaddingX}`
1319
+ },
1320
+ "& .MuiAccordionDetails-root": {
1321
+ padding: `0 ${theme.tokens.components.accordion.detailsPaddingX} ${theme.tokens.components.accordion.detailsPaddingBottom}`
1322
+ }
1323
+ }));
1324
+ function Accordion(props) {
1325
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(import_material7.Accordion, { ...props });
1326
+ }
1327
+ function AccordionSummary({ expandIcon, ...props }) {
1328
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(import_material7.AccordionSummary, { expandIcon: expandIcon ?? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(import_ExpandMore.default, {}), ...props });
1329
+ }
1330
+ function AccordionDetails(props) {
1331
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(import_material7.AccordionDetails, { ...props });
1332
+ }
1333
+ Accordion.displayName = "ToolkitAccordion";
1334
+ AccordionSummary.displayName = "ToolkitAccordionSummary";
1335
+ AccordionDetails.displayName = "ToolkitAccordionDetails";
1336
+ StandaloneAccordion.displayName = "ToolkitStandaloneAccordion";
1337
+
1338
+ // src/components/Avatar/Avatar.tsx
1339
+ var import_Avatar = __toESM(require("@mui/material/Avatar"));
1340
+ var import_styles6 = require("@mui/material/styles");
1341
+ var import_AvatarGroup = __toESM(require("@mui/material/AvatarGroup"));
1342
+ var import_jsx_runtime8 = require("react/jsx-runtime");
1343
+ function getDimension(avatar, size) {
1344
+ const map = {
1345
+ xs: avatar.sizeXs,
1346
+ sm: avatar.sizeSm,
1347
+ md: avatar.sizeMd,
1348
+ lg: avatar.sizeLg,
1349
+ xl: avatar.sizeXl,
1350
+ xxl: avatar.sizeXxl
1351
+ };
1352
+ return map[size];
1353
+ }
1354
+ var StyledAvatar = (0, import_styles6.styled)(import_Avatar.default, {
1355
+ shouldForwardProp: (prop) => prop !== "size"
1356
+ })(({ theme, size = "md" }) => {
1357
+ const dimension = getDimension(theme.tokens.components.avatar, size);
1358
+ return {
1359
+ width: dimension,
1360
+ height: dimension
1361
+ };
1362
+ });
1363
+ function Avatar({ size = "md", ...props }) {
1364
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(StyledAvatar, { size, ...props });
1365
+ }
1366
+
1367
+ // src/components/ToggleButton/ToggleButton.tsx
1368
+ var import_material8 = require("@mui/material");
1369
+ var import_jsx_runtime9 = require("react/jsx-runtime");
1370
+ function ToggleButton(props) {
1371
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_material8.ToggleButton, { ...props });
1372
+ }
1373
+ ToggleButton.displayName = "ToolkitToggleButton";
1374
+ function ToggleButtonGroup(props) {
1375
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_material8.ToggleButtonGroup, { ...props });
1376
+ }
1377
+ ToggleButtonGroup.displayName = "ToolkitToggleButtonGroup";
1378
+
1379
+ // src/components/DatePicker/DatePicker.tsx
1380
+ var import_react = require("react");
1381
+ var import_AdapterDayjs = require("@mui/x-date-pickers/AdapterDayjs");
1382
+ var import_LocalizationProvider = require("@mui/x-date-pickers/LocalizationProvider");
1383
+ var import_DatePicker = require("@mui/x-date-pickers/DatePicker");
1384
+ var import_DesktopDatePicker = require("@mui/x-date-pickers/DesktopDatePicker");
1385
+ var import_MobileDatePicker = require("@mui/x-date-pickers/MobileDatePicker");
1386
+ var import_DateField = require("@mui/x-date-pickers/DateField");
1387
+ var import_StaticDatePicker = require("@mui/x-date-pickers/StaticDatePicker");
1388
+ var import_TimePicker = require("@mui/x-date-pickers/TimePicker");
1389
+ var import_DesktopTimePicker = require("@mui/x-date-pickers/DesktopTimePicker");
1390
+ var import_MobileTimePicker = require("@mui/x-date-pickers/MobileTimePicker");
1391
+ var import_TimeField = require("@mui/x-date-pickers/TimeField");
1392
+ var import_StaticTimePicker = require("@mui/x-date-pickers/StaticTimePicker");
1393
+ var import_DateTimePicker = require("@mui/x-date-pickers/DateTimePicker");
1394
+ var import_DesktopDateTimePicker = require("@mui/x-date-pickers/DesktopDateTimePicker");
1395
+ var import_MobileDateTimePicker = require("@mui/x-date-pickers/MobileDateTimePicker");
1396
+ var import_DateTimeField = require("@mui/x-date-pickers/DateTimeField");
1397
+ var import_StaticDateTimePicker = require("@mui/x-date-pickers/StaticDateTimePicker");
1398
+ var import_DateCalendar = require("@mui/x-date-pickers/DateCalendar");
1399
+ var import_Dialog = __toESM(require("@mui/material/Dialog"));
1400
+ var import_DialogContent = __toESM(require("@mui/material/DialogContent"));
1401
+ var import_DialogActions = __toESM(require("@mui/material/DialogActions"));
1402
+ var import_Button2 = __toESM(require("@mui/material/Button"));
1403
+ var import_Box = __toESM(require("@mui/material/Box"));
1404
+ var import_TextField2 = __toESM(require("@mui/material/TextField"));
1405
+ var import_styles7 = require("@mui/material/styles");
1406
+ var import_jsx_runtime10 = require("react/jsx-runtime");
1407
+ function DateLocalizationProvider({ children }) {
1408
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_LocalizationProvider.LocalizationProvider, { dateAdapter: import_AdapterDayjs.AdapterDayjs, children });
1409
+ }
1410
+ DateLocalizationProvider.displayName = "ToolkitDateLocalizationProvider";
1411
+ function DatePicker(props) {
1412
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_DatePicker.DatePicker, { ...props });
1413
+ }
1414
+ DatePicker.displayName = "ToolkitDatePicker";
1415
+ function DesktopDatePicker(props) {
1416
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_DesktopDatePicker.DesktopDatePicker, { ...props });
1417
+ }
1418
+ DesktopDatePicker.displayName = "ToolkitDesktopDatePicker";
1419
+ function MobileDatePicker(props) {
1420
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_MobileDatePicker.MobileDatePicker, { ...props });
1421
+ }
1422
+ MobileDatePicker.displayName = "ToolkitMobileDatePicker";
1423
+ function DateField(props) {
1424
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_DateField.DateField, { ...props });
1425
+ }
1426
+ DateField.displayName = "ToolkitDateField";
1427
+ function StaticDatePicker(props) {
1428
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_StaticDatePicker.StaticDatePicker, { ...props });
1429
+ }
1430
+ StaticDatePicker.displayName = "ToolkitStaticDatePicker";
1431
+ function TimePicker(props) {
1432
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_TimePicker.TimePicker, { ...props });
1433
+ }
1434
+ TimePicker.displayName = "ToolkitTimePicker";
1435
+ function DesktopTimePicker(props) {
1436
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_DesktopTimePicker.DesktopTimePicker, { ...props });
1437
+ }
1438
+ DesktopTimePicker.displayName = "ToolkitDesktopTimePicker";
1439
+ function MobileTimePicker(props) {
1440
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_MobileTimePicker.MobileTimePicker, { ...props });
1441
+ }
1442
+ MobileTimePicker.displayName = "ToolkitMobileTimePicker";
1443
+ function TimeField(props) {
1444
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_TimeField.TimeField, { ...props });
1445
+ }
1446
+ TimeField.displayName = "ToolkitTimeField";
1447
+ function StaticTimePicker(props) {
1448
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_StaticTimePicker.StaticTimePicker, { ...props });
1449
+ }
1450
+ StaticTimePicker.displayName = "ToolkitStaticTimePicker";
1451
+ function DateTimePicker(props) {
1452
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_DateTimePicker.DateTimePicker, { ...props });
1453
+ }
1454
+ DateTimePicker.displayName = "ToolkitDateTimePicker";
1455
+ function DesktopDateTimePicker(props) {
1456
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_DesktopDateTimePicker.DesktopDateTimePicker, { ...props });
1457
+ }
1458
+ DesktopDateTimePicker.displayName = "ToolkitDesktopDateTimePicker";
1459
+ function MobileDateTimePicker(props) {
1460
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_MobileDateTimePicker.MobileDateTimePicker, { ...props });
1461
+ }
1462
+ MobileDateTimePicker.displayName = "ToolkitMobileDateTimePicker";
1463
+ function DateTimeField(props) {
1464
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_DateTimeField.DateTimeField, { ...props });
1465
+ }
1466
+ DateTimeField.displayName = "ToolkitDateTimeField";
1467
+ function StaticDateTimePicker(props) {
1468
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_StaticDateTimePicker.StaticDateTimePicker, { ...props });
1469
+ }
1470
+ StaticDateTimePicker.displayName = "ToolkitStaticDateTimePicker";
1471
+ function DateCalendar(props) {
1472
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_DateCalendar.DateCalendar, { ...props });
1473
+ }
1474
+ DateCalendar.displayName = "ToolkitDateCalendar";
1475
+ var RangeRow = (0, import_styles7.styled)(import_Box.default)(({ theme }) => ({
1476
+ display: "flex",
1477
+ gap: theme.spacing(2),
1478
+ alignItems: "center"
1479
+ }));
1480
+ function DateRangePickerInput({
1481
+ value,
1482
+ onChange,
1483
+ startLabel = "Start date",
1484
+ endLabel = "End date",
1485
+ buttonLabel = "Click me!"
1486
+ }) {
1487
+ const [open, setOpen] = (0, import_react.useState)(false);
1488
+ const [draft, setDraft] = (0, import_react.useState)(value);
1489
+ const handleOpen = () => {
1490
+ setDraft(value);
1491
+ setOpen(true);
1492
+ };
1493
+ const handleCancel = () => setOpen(false);
1494
+ const handleOk = () => {
1495
+ onChange(draft);
1496
+ setOpen(false);
1497
+ };
1498
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
1499
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_Button2.default, { variant: "contained", color: "inherit", disableElevation: true, onClick: handleOpen, children: buttonLabel }),
1500
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_Dialog.default, { open, onClose: handleCancel, maxWidth: "sm", fullWidth: true, children: [
1501
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_DialogContent.default, { children: /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(RangeRow, { children: [
1502
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
1503
+ import_DatePicker.DatePicker,
1504
+ {
1505
+ label: startLabel,
1506
+ value: draft.start,
1507
+ onChange: (v) => setDraft((prev) => ({ ...prev, start: v })),
1508
+ slotProps: { textField: { fullWidth: true } }
1509
+ }
1510
+ ),
1511
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
1512
+ import_DatePicker.DatePicker,
1513
+ {
1514
+ label: endLabel,
1515
+ value: draft.end,
1516
+ onChange: (v) => setDraft((prev) => ({ ...prev, end: v })),
1517
+ slotProps: { textField: { fullWidth: true } }
1518
+ }
1519
+ )
1520
+ ] }) }),
1521
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_DialogActions.default, { children: [
1522
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_Button2.default, { onClick: handleCancel, color: "inherit", children: "Cancel" }),
1523
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_Button2.default, { onClick: handleOk, color: "inherit", children: "OK" })
1524
+ ] })
1525
+ ] })
1526
+ ] });
1527
+ }
1528
+ DateRangePickerInput.displayName = "ToolkitDateRangePickerInput";
1529
+ function DateRangePickerCalendar({
1530
+ value,
1531
+ onChange,
1532
+ buttonLabel = "Click me!"
1533
+ }) {
1534
+ const [open, setOpen] = (0, import_react.useState)(false);
1535
+ const [draft, setDraft] = (0, import_react.useState)(value);
1536
+ const [selecting, setSelecting] = (0, import_react.useState)("start");
1537
+ const handleOpen = () => {
1538
+ setDraft(value);
1539
+ setSelecting("start");
1540
+ setOpen(true);
1541
+ };
1542
+ const handleCancel = () => setOpen(false);
1543
+ const handleOk = () => {
1544
+ onChange(draft);
1545
+ setOpen(false);
1546
+ };
1547
+ const handleDaySelect = (date) => {
1548
+ if (selecting === "start") {
1549
+ setDraft({ start: date, end: null });
1550
+ setSelecting("end");
1551
+ } else {
1552
+ setDraft((prev) => ({ ...prev, end: date }));
1553
+ }
1554
+ };
1555
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
1556
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_Button2.default, { variant: "contained", color: "inherit", disableElevation: true, onClick: handleOpen, children: buttonLabel }),
1557
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_Dialog.default, { open, onClose: handleCancel, children: [
1558
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_DialogContent.default, { sx: { p: 1 }, children: [
1559
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_Box.default, { sx: { mb: 1, px: 1 }, children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
1560
+ import_TextField2.default,
1561
+ {
1562
+ size: "small",
1563
+ label: "Selecting",
1564
+ value: selecting === "start" ? "Start date" : "End date",
1565
+ inputProps: { readOnly: true },
1566
+ fullWidth: true
1567
+ }
1568
+ ) }),
1569
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
1570
+ import_DateCalendar.DateCalendar,
1571
+ {
1572
+ value: selecting === "start" ? draft.start : draft.end,
1573
+ onChange: handleDaySelect
1574
+ }
1575
+ )
1576
+ ] }),
1577
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_DialogActions.default, { children: [
1578
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_Button2.default, { onClick: handleCancel, color: "inherit", children: "Cancel" }),
1579
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_Button2.default, { onClick: handleOk, color: "inherit", children: "OK" })
1580
+ ] })
1581
+ ] })
1582
+ ] });
1583
+ }
1584
+ DateRangePickerCalendar.displayName = "ToolkitDateRangePickerCalendar";
1585
+
1586
+ // src/foundation/Grid/Grid.tsx
1587
+ var import_material9 = require("@mui/material");
1588
+ var import_jsx_runtime11 = require("react/jsx-runtime");
1589
+ function Grid({ container, spacing, ...props }) {
1590
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
1591
+ import_material9.Grid2,
1592
+ {
1593
+ container,
1594
+ spacing: container && spacing === void 0 ? 2 : spacing,
1595
+ ...props
1596
+ }
1597
+ );
1598
+ }
1599
+ Grid.displayName = "ToolkitGrid";
1600
+
1601
+ // src/foundation/H1/H1.tsx
1602
+ var import_material10 = require("@mui/material");
1603
+ var import_jsx_runtime12 = require("react/jsx-runtime");
1604
+ function H1({ color = "text.primary", children, ...props }) {
1605
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_material10.Typography, { variant: "h1", color, ...props, children });
1606
+ }
1607
+ H1.displayName = "ToolkitH1";
1608
+
1609
+ // src/foundation/H2/H2.tsx
1610
+ var import_material11 = require("@mui/material");
1611
+ var import_jsx_runtime13 = require("react/jsx-runtime");
1612
+ function H2({ color = "text.primary", children, ...props }) {
1613
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_material11.Typography, { variant: "h2", color, ...props, children });
1614
+ }
1615
+ H2.displayName = "ToolkitH2";
1616
+
1617
+ // src/foundation/H3/H3.tsx
1618
+ var import_material12 = require("@mui/material");
1619
+ var import_jsx_runtime14 = require("react/jsx-runtime");
1620
+ function H3({ color = "text.primary", children, ...props }) {
1621
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_material12.Typography, { variant: "h3", color, ...props, children });
1622
+ }
1623
+ H3.displayName = "ToolkitH3";
1624
+
1625
+ // src/foundation/H4/H4.tsx
1626
+ var import_material13 = require("@mui/material");
1627
+ var import_jsx_runtime15 = require("react/jsx-runtime");
1628
+ function H4({ color = "text.primary", children, ...props }) {
1629
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_material13.Typography, { variant: "h4", color, ...props, children });
1630
+ }
1631
+ H4.displayName = "ToolkitH4";
1632
+
1633
+ // src/foundation/H5/H5.tsx
1634
+ var import_material14 = require("@mui/material");
1635
+ var import_jsx_runtime16 = require("react/jsx-runtime");
1636
+ function H5({ color = "text.primary", children, ...props }) {
1637
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_material14.Typography, { variant: "h5", color, ...props, children });
1638
+ }
1639
+ H5.displayName = "ToolkitH5";
1640
+
1641
+ // src/foundation/H6/H6.tsx
1642
+ var import_material15 = require("@mui/material");
1643
+ var import_jsx_runtime17 = require("react/jsx-runtime");
1644
+ function H6({ color = "text.primary", children, ...props }) {
1645
+ return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_material15.Typography, { variant: "h6", color, ...props, children });
1646
+ }
1647
+ H6.displayName = "ToolkitH6";
1648
+
1649
+ // src/foundation/Subtitle1/Subtitle1.tsx
1650
+ var import_material16 = require("@mui/material");
1651
+ var import_jsx_runtime18 = require("react/jsx-runtime");
1652
+ function Subtitle1({ color = "text.primary", children, ...props }) {
1653
+ return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_material16.Typography, { variant: "subtitle1", color, ...props, children });
1654
+ }
1655
+ Subtitle1.displayName = "ToolkitSubtitle1";
1656
+
1657
+ // src/foundation/Subtitle2/Subtitle2.tsx
1658
+ var import_material17 = require("@mui/material");
1659
+ var import_jsx_runtime19 = require("react/jsx-runtime");
1660
+ function Subtitle2({ color = "text.primary", children, ...props }) {
1661
+ return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_material17.Typography, { variant: "subtitle2", color, ...props, children });
1662
+ }
1663
+ Subtitle2.displayName = "ToolkitSubtitle2";
1664
+
1665
+ // src/foundation/Body1/Body1.tsx
1666
+ var import_material18 = require("@mui/material");
1667
+ var import_jsx_runtime20 = require("react/jsx-runtime");
1668
+ function Body1({ color = "text.primary", children, ...props }) {
1669
+ return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_material18.Typography, { variant: "body1", color, ...props, children });
1670
+ }
1671
+ Body1.displayName = "ToolkitBody1";
1672
+
1673
+ // src/foundation/Body2/Body2.tsx
1674
+ var import_material19 = require("@mui/material");
1675
+ var import_jsx_runtime21 = require("react/jsx-runtime");
1676
+ function Body2({ color = "text.primary", children, ...props }) {
1677
+ return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_material19.Typography, { variant: "body2", color, ...props, children });
1678
+ }
1679
+ Body2.displayName = "ToolkitBody2";
1680
+
1681
+ // src/foundation/Caption/Caption.tsx
1682
+ var import_material20 = require("@mui/material");
1683
+ var import_jsx_runtime22 = require("react/jsx-runtime");
1684
+ function Caption({ color = "text.primary", children, ...props }) {
1685
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_material20.Typography, { variant: "caption", color, ...props, children });
1686
+ }
1687
+ Caption.displayName = "ToolkitCaption";
1688
+
1689
+ // src/foundation/Overline/Overline.tsx
1690
+ var import_material21 = require("@mui/material");
1691
+ var import_jsx_runtime23 = require("react/jsx-runtime");
1692
+ function Overline({ color = "text.primary", children, ...props }) {
1693
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_material21.Typography, { variant: "overline", color, ...props, children });
1694
+ }
1695
+ Overline.displayName = "ToolkitOverline";
1696
+
1697
+ // src/foundation/TypographyButton/TypographyButton.tsx
1698
+ var import_material22 = require("@mui/material");
1699
+ var import_jsx_runtime24 = require("react/jsx-runtime");
1700
+ function TypographyButton({ color = "text.primary", children, ...props }) {
1701
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_material22.Typography, { variant: "button", color, ...props, children });
1702
+ }
1703
+ TypographyButton.displayName = "ToolkitTypographyButton";
1704
+ // Annotate the CommonJS export names for ESM import in node:
1705
+ 0 && (module.exports = {
1706
+ Accordion,
1707
+ AccordionDetails,
1708
+ AccordionSummary,
1709
+ Alert,
1710
+ AlertTitle,
1711
+ Avatar,
1712
+ AvatarGroup,
1713
+ Body1,
1714
+ Body2,
1715
+ Button,
1716
+ Caption,
1717
+ Card,
1718
+ CardActions,
1719
+ CardContent,
1720
+ CardHeader,
1721
+ Chip,
1722
+ DateCalendar,
1723
+ DateField,
1724
+ DateLocalizationProvider,
1725
+ DatePicker,
1726
+ DateRangePickerCalendar,
1727
+ DateRangePickerInput,
1728
+ DateTimeField,
1729
+ DateTimePicker,
1730
+ DesktopDatePicker,
1731
+ DesktopDateTimePicker,
1732
+ DesktopTimePicker,
1733
+ Grid,
1734
+ H1,
1735
+ H2,
1736
+ H3,
1737
+ H4,
1738
+ H5,
1739
+ H6,
1740
+ MobileDatePicker,
1741
+ MobileDateTimePicker,
1742
+ MobileTimePicker,
1743
+ Overline,
1744
+ StandaloneAccordion,
1745
+ StaticDatePicker,
1746
+ StaticDateTimePicker,
1747
+ StaticTimePicker,
1748
+ Subtitle1,
1749
+ Subtitle2,
1750
+ TextField,
1751
+ TimeField,
1752
+ TimePicker,
1753
+ ToggleButton,
1754
+ ToggleButtonGroup,
1755
+ ToolkitThemeProvider,
1756
+ TypographyButton,
1757
+ createMuiTheme,
1758
+ getThemeTokens,
1759
+ resolveThemeName,
1760
+ themeRegistry
1761
+ });
1762
+ //# sourceMappingURL=index.js.map