@coinbase/cds-web 9.0.0-rc.1 → 9.0.0-rc.3
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/CHANGELOG.md +81 -0
- package/dts/buttons/IconButton.d.ts +15 -1
- package/dts/buttons/IconButton.d.ts.map +1 -1
- package/dts/chips/TabbedChips.d.ts.map +1 -1
- package/dts/collapsible/Collapsible.d.ts.map +1 -1
- package/dts/controls/InputLabel.d.ts.map +1 -1
- package/dts/controls/SearchInput.d.ts +2 -0
- package/dts/controls/SearchInput.d.ts.map +1 -1
- package/dts/controls/TextInput.d.ts.map +1 -1
- package/dts/core/createThemeCssVars.d.ts.map +1 -1
- package/dts/core/theme.d.ts +15 -0
- package/dts/core/theme.d.ts.map +1 -1
- package/dts/illustrations/HeroSquare.d.ts.map +1 -1
- package/dts/illustrations/Pictogram.d.ts.map +1 -1
- package/dts/illustrations/SpotIcon.d.ts.map +1 -1
- package/dts/illustrations/SpotRectangle.d.ts.map +1 -1
- package/dts/illustrations/SpotSquare.d.ts.map +1 -1
- package/dts/illustrations/createIllustration.d.ts +19 -3
- package/dts/illustrations/createIllustration.d.ts.map +1 -1
- package/dts/navigation/NavigationBar.d.ts.map +1 -1
- package/dts/page/PageFooter.d.ts +4 -0
- package/dts/page/PageFooter.d.ts.map +1 -1
- package/dts/system/ThemeProvider.d.ts.map +1 -1
- package/dts/tabs/DefaultTab.d.ts +11 -2
- package/dts/tabs/DefaultTab.d.ts.map +1 -1
- package/dts/tabs/SegmentedTab.d.ts +13 -12
- package/dts/tabs/SegmentedTab.d.ts.map +1 -1
- package/dts/tabs/Tabs.d.ts +9 -3
- package/dts/tabs/Tabs.d.ts.map +1 -1
- package/dts/tag/Tag.d.ts +3 -2
- package/dts/tag/Tag.d.ts.map +1 -1
- package/dts/themes/coinbaseDenseTheme.d.ts +34 -2
- package/dts/themes/coinbaseDenseTheme.d.ts.map +1 -1
- package/dts/themes/coinbaseHighContrastTheme.d.ts +32 -0
- package/dts/themes/coinbaseHighContrastTheme.d.ts.map +1 -1
- package/dts/themes/coinbaseTheme.d.ts +34 -2
- package/dts/themes/coinbaseTheme.d.ts.map +1 -1
- package/dts/themes/defaultHighContrastTheme.d.ts +32 -0
- package/dts/themes/defaultHighContrastTheme.d.ts.map +1 -1
- package/dts/themes/defaultTheme.d.ts +34 -2
- package/dts/themes/defaultTheme.d.ts.map +1 -1
- package/dts/visualizations/chart/PeriodSelector.d.ts.map +1 -1
- package/esm/buttons/IconButton.js +26 -5
- package/esm/chips/TabbedChips.js +4 -2
- package/esm/collapsible/Collapsible.js +11 -15
- package/esm/controls/InputLabel.js +4 -3
- package/esm/controls/TextInput.js +7 -1
- package/esm/core/createThemeCssVars.js +23 -0
- package/esm/core/theme.js +3 -0
- package/esm/illustrations/HeroSquare.js +2 -1
- package/esm/illustrations/Pictogram.js +2 -1
- package/esm/illustrations/SpotIcon.js +2 -1
- package/esm/illustrations/SpotRectangle.js +2 -1
- package/esm/illustrations/SpotSquare.js +2 -1
- package/esm/illustrations/createIllustration.js +65 -19
- package/esm/navigation/NavigationBar.js +14 -10
- package/esm/page/PageFooter.js +20 -4
- package/esm/page/__figma__/PageFooter.figma.js +50 -6
- package/esm/system/ThemeProvider.js +3 -1
- package/esm/tabs/DefaultTab.css +1 -2
- package/esm/tabs/DefaultTab.js +6 -5
- package/esm/tabs/Tabs.js +8 -2
- package/esm/tag/Tag.js +13 -3
- package/esm/themes/coinbaseHighContrastTheme.js +32 -0
- package/esm/themes/coinbaseTheme.js +34 -2
- package/esm/themes/defaultHighContrastTheme.js +32 -0
- package/esm/themes/defaultTheme.js +34 -2
- package/esm/visualizations/chart/PeriodSelector.js +4 -3
- package/package.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coinbaseDenseTheme.d.ts","sourceRoot":"","sources":["../../src/themes/coinbaseDenseTheme.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,oBAAoB,mBAAmB,CAAC;AAErD;;;GAGG;AACH,eAAO,MAAM,kBAAkB
|
|
1
|
+
{"version":3,"file":"coinbaseDenseTheme.d.ts","sourceRoot":"","sources":["../../src/themes/coinbaseDenseTheme.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,oBAAoB,mBAAmB,CAAC;AAErD;;;GAGG;AACH,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAsGC,CAAC"}
|
|
@@ -531,6 +531,38 @@ export declare const coinbaseHighContrastTheme: {
|
|
|
531
531
|
readonly caption: 'uppercase';
|
|
532
532
|
readonly legal: 'none';
|
|
533
533
|
};
|
|
534
|
+
readonly lightIllustrationColor: {
|
|
535
|
+
readonly primary: 'rgb(0,82,255)';
|
|
536
|
+
readonly black: 'rgb(10,11,13)';
|
|
537
|
+
readonly white: 'rgb(255,255,255)';
|
|
538
|
+
readonly gray: 'rgb(206,210,219)';
|
|
539
|
+
readonly gray2: 'rgb(10, 11, 15)';
|
|
540
|
+
readonly gray3: 'rgb(206, 210, 220)';
|
|
541
|
+
readonly positive: 'rgb(60,194,138)';
|
|
542
|
+
readonly negative: 'rgb(225,57,71)';
|
|
543
|
+
readonly accent1: 'rgb(255, 210, 0)';
|
|
544
|
+
readonly accent2: 'rgb(93,226,248)';
|
|
545
|
+
readonly accent3: 'rgb(237,112,47)';
|
|
546
|
+
readonly accent4: 'rgb(115,162,255)';
|
|
547
|
+
readonly invert: 'rgb(10, 11, 14)';
|
|
548
|
+
readonly invert2: 'rgb(255, 255, 254)';
|
|
549
|
+
};
|
|
550
|
+
readonly darkIllustrationColor: {
|
|
551
|
+
readonly primary: 'rgb(87,139,250)';
|
|
552
|
+
readonly black: 'rgb(10,11,13)';
|
|
553
|
+
readonly white: 'rgb(255,255,255)';
|
|
554
|
+
readonly gray: 'rgb(70,75,85)';
|
|
555
|
+
readonly gray2: 'rgb(70,75,85)';
|
|
556
|
+
readonly gray3: 'rgb(255,255,255)';
|
|
557
|
+
readonly positive: 'rgb(68,194,141)';
|
|
558
|
+
readonly negative: 'rgb(240,97,109)';
|
|
559
|
+
readonly accent1: 'rgb(236, 208, 105)';
|
|
560
|
+
readonly accent2: 'rgb(69,217,245)';
|
|
561
|
+
readonly accent3: 'rgb(240,120,54)';
|
|
562
|
+
readonly accent4: 'rgb(143,178,255)';
|
|
563
|
+
readonly invert: 'rgb(255,255,255)';
|
|
564
|
+
readonly invert2: 'rgb(114,120,134)';
|
|
565
|
+
};
|
|
534
566
|
readonly shadow: {
|
|
535
567
|
readonly elevation1: '0px 8px 12px rgba(0, 0, 0, 0.12)';
|
|
536
568
|
readonly elevation2: '0px 8px 24px rgba(0, 0, 0, 0.12)';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coinbaseHighContrastTheme.d.ts","sourceRoot":"","sources":["../../src/themes/coinbaseHighContrastTheme.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,2BAA2B,2BAA2B,CAAC;AAsSpE,eAAO,MAAM,yBAAyB
|
|
1
|
+
{"version":3,"file":"coinbaseHighContrastTheme.d.ts","sourceRoot":"","sources":["../../src/themes/coinbaseHighContrastTheme.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,2BAA2B,2BAA2B,CAAC;AAsSpE,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAoSN,CAAC"}
|
|
@@ -312,7 +312,7 @@ export declare const coinbaseTheme: {
|
|
|
312
312
|
readonly bgNegativeWash: 'rgb(255,245,246)';
|
|
313
313
|
readonly bgPositive: 'rgb(9,133,81)';
|
|
314
314
|
readonly bgPositiveWash: 'rgb(245,255,251)';
|
|
315
|
-
readonly bgWarning: 'rgb(
|
|
315
|
+
readonly bgWarning: 'rgb(207,71,14)';
|
|
316
316
|
readonly bgWarningWash: 'rgb(255,250,245)';
|
|
317
317
|
readonly currentColor: 'currentColor';
|
|
318
318
|
readonly bgLine: 'rgba(91,97,110,0.2)';
|
|
@@ -357,7 +357,7 @@ export declare const coinbaseTheme: {
|
|
|
357
357
|
readonly bgNegativeWash: 'rgb(51,0,4)';
|
|
358
358
|
readonly bgPositive: 'rgb(39,173,117)';
|
|
359
359
|
readonly bgPositiveWash: 'rgb(0,31,18)';
|
|
360
|
-
readonly bgWarning: 'rgb(
|
|
360
|
+
readonly bgWarning: 'rgb(240,120,54)';
|
|
361
361
|
readonly bgWarningWash: 'rgb(51,13,0)';
|
|
362
362
|
readonly currentColor: 'currentColor';
|
|
363
363
|
readonly bgLine: 'rgba(138,145,158,0.2)';
|
|
@@ -535,5 +535,37 @@ export declare const coinbaseTheme: {
|
|
|
535
535
|
readonly elevation1: '0px 8px 12px rgba(0, 0, 0, 0.12)';
|
|
536
536
|
readonly elevation2: '0px 8px 24px rgba(0, 0, 0, 0.12)';
|
|
537
537
|
};
|
|
538
|
+
readonly lightIllustrationColor: {
|
|
539
|
+
readonly primary: 'rgb(0,82,255)';
|
|
540
|
+
readonly black: 'rgb(10,11,13)';
|
|
541
|
+
readonly white: 'rgb(255,255,255)';
|
|
542
|
+
readonly gray: 'rgb(206,210,219)';
|
|
543
|
+
readonly gray2: 'rgb(10, 11, 15)';
|
|
544
|
+
readonly gray3: 'rgb(206, 210, 220)';
|
|
545
|
+
readonly positive: 'rgb(60,194,138)';
|
|
546
|
+
readonly negative: 'rgb(225,57,71)';
|
|
547
|
+
readonly accent1: 'rgb(255, 210, 0)';
|
|
548
|
+
readonly accent2: 'rgb(93,226,248)';
|
|
549
|
+
readonly accent3: 'rgb(237,112,47)';
|
|
550
|
+
readonly accent4: 'rgb(115,162,255)';
|
|
551
|
+
readonly invert: 'rgb(10, 11, 14)';
|
|
552
|
+
readonly invert2: 'rgb(255, 255, 254)';
|
|
553
|
+
};
|
|
554
|
+
readonly darkIllustrationColor: {
|
|
555
|
+
readonly primary: 'rgb(87,139,250)';
|
|
556
|
+
readonly black: 'rgb(10,11,13)';
|
|
557
|
+
readonly white: 'rgb(255,255,255)';
|
|
558
|
+
readonly gray: 'rgb(70,75,85)';
|
|
559
|
+
readonly gray2: 'rgb(70,75,85)';
|
|
560
|
+
readonly gray3: 'rgb(255,255,255)';
|
|
561
|
+
readonly positive: 'rgb(68,194,141)';
|
|
562
|
+
readonly negative: 'rgb(240,97,109)';
|
|
563
|
+
readonly accent1: 'rgb(236, 208, 105)';
|
|
564
|
+
readonly accent2: 'rgb(69,217,245)';
|
|
565
|
+
readonly accent3: 'rgb(240,120,54)';
|
|
566
|
+
readonly accent4: 'rgb(132,170,253)';
|
|
567
|
+
readonly invert: 'rgb(255,255,255)';
|
|
568
|
+
readonly invert2: 'rgb(114,120,134)';
|
|
569
|
+
};
|
|
538
570
|
};
|
|
539
571
|
//# sourceMappingURL=coinbaseTheme.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coinbaseTheme.d.ts","sourceRoot":"","sources":["../../src/themes/coinbaseTheme.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,eAAe,aAAa,CAAC;AAsS1C,eAAO,MAAM,aAAa
|
|
1
|
+
{"version":3,"file":"coinbaseTheme.d.ts","sourceRoot":"","sources":["../../src/themes/coinbaseTheme.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,eAAe,aAAa,CAAC;AAsS1C,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAoSM,CAAC"}
|
|
@@ -531,6 +531,38 @@ export declare const defaultHighContrastTheme: {
|
|
|
531
531
|
readonly caption: 'uppercase';
|
|
532
532
|
readonly legal: 'none';
|
|
533
533
|
};
|
|
534
|
+
readonly lightIllustrationColor: {
|
|
535
|
+
readonly primary: 'rgb(0,82,255)';
|
|
536
|
+
readonly black: 'rgb(10,11,13)';
|
|
537
|
+
readonly white: 'rgb(255,255,255)';
|
|
538
|
+
readonly gray: 'rgb(206,210,219)';
|
|
539
|
+
readonly gray2: 'rgb(10, 11, 15)';
|
|
540
|
+
readonly gray3: 'rgb(206, 210, 220)';
|
|
541
|
+
readonly positive: 'rgb(60,194,138)';
|
|
542
|
+
readonly negative: 'rgb(225,57,71)';
|
|
543
|
+
readonly accent1: 'rgb(255, 210, 0)';
|
|
544
|
+
readonly accent2: 'rgb(93,226,248)';
|
|
545
|
+
readonly accent3: 'rgb(237,112,47)';
|
|
546
|
+
readonly accent4: 'rgb(115,162,255)';
|
|
547
|
+
readonly invert: 'rgb(10, 11, 14)';
|
|
548
|
+
readonly invert2: 'rgb(255, 255, 254)';
|
|
549
|
+
};
|
|
550
|
+
readonly darkIllustrationColor: {
|
|
551
|
+
readonly primary: 'rgb(87,139,250)';
|
|
552
|
+
readonly black: 'rgb(10,11,13)';
|
|
553
|
+
readonly white: 'rgb(255,255,255)';
|
|
554
|
+
readonly gray: 'rgb(70,75,85)';
|
|
555
|
+
readonly gray2: 'rgb(70,75,85)';
|
|
556
|
+
readonly gray3: 'rgb(255,255,255)';
|
|
557
|
+
readonly positive: 'rgb(68,194,141)';
|
|
558
|
+
readonly negative: 'rgb(240,97,109)';
|
|
559
|
+
readonly accent1: 'rgb(236, 208, 105)';
|
|
560
|
+
readonly accent2: 'rgb(69,217,245)';
|
|
561
|
+
readonly accent3: 'rgb(240,120,54)';
|
|
562
|
+
readonly accent4: 'rgb(143,178,255)';
|
|
563
|
+
readonly invert: 'rgb(255,255,255)';
|
|
564
|
+
readonly invert2: 'rgb(114,120,134)';
|
|
565
|
+
};
|
|
534
566
|
readonly shadow: {
|
|
535
567
|
readonly elevation1: '0px 8px 12px rgba(0, 0, 0, 0.12)';
|
|
536
568
|
readonly elevation2: '0px 8px 24px rgba(0, 0, 0, 0.12)';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"defaultHighContrastTheme.d.ts","sourceRoot":"","sources":["../../src/themes/defaultHighContrastTheme.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,0BAA0B,8BAA8B,CAAC;AAsStE,eAAO,MAAM,wBAAwB
|
|
1
|
+
{"version":3,"file":"defaultHighContrastTheme.d.ts","sourceRoot":"","sources":["../../src/themes/defaultHighContrastTheme.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,0BAA0B,8BAA8B,CAAC;AAsStE,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAoSL,CAAC"}
|
|
@@ -312,7 +312,7 @@ export declare const defaultTheme: {
|
|
|
312
312
|
readonly bgNegativeWash: 'rgb(255,245,246)';
|
|
313
313
|
readonly bgPositive: 'rgb(9,133,81)';
|
|
314
314
|
readonly bgPositiveWash: 'rgb(245,255,251)';
|
|
315
|
-
readonly bgWarning: 'rgb(
|
|
315
|
+
readonly bgWarning: 'rgb(207,71,14)';
|
|
316
316
|
readonly bgWarningWash: 'rgb(255,250,245)';
|
|
317
317
|
readonly currentColor: 'currentColor';
|
|
318
318
|
readonly bgLine: 'rgba(91,97,110,0.2)';
|
|
@@ -357,7 +357,7 @@ export declare const defaultTheme: {
|
|
|
357
357
|
readonly bgNegativeWash: 'rgb(51,0,4)';
|
|
358
358
|
readonly bgPositive: 'rgb(39,173,117)';
|
|
359
359
|
readonly bgPositiveWash: 'rgb(0,31,18)';
|
|
360
|
-
readonly bgWarning: 'rgb(
|
|
360
|
+
readonly bgWarning: 'rgb(240,120,54)';
|
|
361
361
|
readonly bgWarningWash: 'rgb(51,13,0)';
|
|
362
362
|
readonly currentColor: 'currentColor';
|
|
363
363
|
readonly bgLine: 'rgba(138,145,158,0.2)';
|
|
@@ -381,6 +381,38 @@ export declare const defaultTheme: {
|
|
|
381
381
|
readonly accentBoldGray: 'rgb(193,198,207)';
|
|
382
382
|
readonly transparent: 'rgba(10,11,13,0)';
|
|
383
383
|
};
|
|
384
|
+
readonly lightIllustrationColor: {
|
|
385
|
+
readonly primary: 'rgb(0,82,255)';
|
|
386
|
+
readonly black: 'rgb(10,11,13)';
|
|
387
|
+
readonly white: 'rgb(255,255,255)';
|
|
388
|
+
readonly gray: 'rgb(206,210,219)';
|
|
389
|
+
readonly gray2: 'rgb(10, 11, 15)';
|
|
390
|
+
readonly gray3: 'rgb(206, 210, 220)';
|
|
391
|
+
readonly positive: 'rgb(60,194,138)';
|
|
392
|
+
readonly negative: 'rgb(225,57,71)';
|
|
393
|
+
readonly accent1: 'rgb(255, 210, 0)';
|
|
394
|
+
readonly accent2: 'rgb(93,226,248)';
|
|
395
|
+
readonly accent3: 'rgb(237,112,47)';
|
|
396
|
+
readonly accent4: 'rgb(115,162,255)';
|
|
397
|
+
readonly invert: 'rgb(10, 11, 14)';
|
|
398
|
+
readonly invert2: 'rgb(255, 255, 254)';
|
|
399
|
+
};
|
|
400
|
+
readonly darkIllustrationColor: {
|
|
401
|
+
readonly primary: 'rgb(87,139,250)';
|
|
402
|
+
readonly black: 'rgb(10,11,13)';
|
|
403
|
+
readonly white: 'rgb(255,255,255)';
|
|
404
|
+
readonly gray: 'rgb(70,75,85)';
|
|
405
|
+
readonly gray2: 'rgb(70,75,85)';
|
|
406
|
+
readonly gray3: 'rgb(255,255,255)';
|
|
407
|
+
readonly positive: 'rgb(68,194,141)';
|
|
408
|
+
readonly negative: 'rgb(240,97,109)';
|
|
409
|
+
readonly accent1: 'rgb(236, 208, 105)';
|
|
410
|
+
readonly accent2: 'rgb(69,217,245)';
|
|
411
|
+
readonly accent3: 'rgb(240,120,54)';
|
|
412
|
+
readonly accent4: 'rgb(132,170,253)';
|
|
413
|
+
readonly invert: 'rgb(255,255,255)';
|
|
414
|
+
readonly invert2: 'rgb(114,120,134)';
|
|
415
|
+
};
|
|
384
416
|
readonly space: {
|
|
385
417
|
readonly '0': 0;
|
|
386
418
|
readonly '0.25': 2;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"defaultTheme.d.ts","sourceRoot":"","sources":["../../src/themes/defaultTheme.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,cAAc,gBAAgB,CAAC;AAsS5C,eAAO,MAAM,YAAY
|
|
1
|
+
{"version":3,"file":"defaultTheme.d.ts","sourceRoot":"","sources":["../../src/themes/defaultTheme.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,cAAc,gBAAgB,CAAC;AAsS5C,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAoSO,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PeriodSelector.d.ts","sourceRoot":"","sources":["../../../src/visualizations/chart/PeriodSelector.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoC,MAAM,OAAO,CAAC;AAIzD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAG3D,OAAO,EAEL,KAAK,kBAAkB,EAEvB,KAAK,wBAAwB,EAE9B,MAAM,YAAY,CAAC;AAEpB,OAAO,EAAQ,KAAK,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAK5D,eAAO,MAAM,6BAA6B,qGAQrC,wBAAwB,oDA0B5B,CAAC;AAEF,eAAO,MAAM,0BAA0B,SAAS,CAAC;AAEjD,MAAM,MAAM,0BAA0B,GAAG,OAAO,0BAA0B,CAAC;AAE3E,MAAM,MAAM,qBAAqB,GAAG,aAAa,GAAG;IAClD;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB,CAAC;AAEF,MAAM,MAAM,iBAAiB,CAAC,WAAW,SAAS,KAAK,CAAC,WAAW,IAAI,WAAW,CAAC,KAAK,CACtF,WAAW,EACX,qBAAqB,CACtB,CAAC;AAYF,KAAK,qBAAqB,GAAG,CAAC,CAAC,WAAW,SAAS,KAAK,CAAC,WAAW,GAAG,0BAA0B,EAC/F,KAAK,EAAE,iBAAiB,CAAC,WAAW,CAAC,KAClC,WAAW,CAAC,WAAW,CAAC,GAC3B,WAAW,CAAC,UAAU,CAAC;AAEzB,eAAO,MAAM,YAAY,EAAE,qBAiC1B,CAAC;AASF,MAAM,MAAM,mBAAmB,GAAG,kBAAkB,CAAC;AAErD;;;GAGG;AACH,eAAO,MAAM,cAAc;;YA1GvB,CADJ;WAG0B,CAAC;uBAEY,CAAC;;;YAOf,CAAC;WACb,CAAC;uBAGN,CAAP;;
|
|
1
|
+
{"version":3,"file":"PeriodSelector.d.ts","sourceRoot":"","sources":["../../../src/visualizations/chart/PeriodSelector.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoC,MAAM,OAAO,CAAC;AAIzD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAG3D,OAAO,EAEL,KAAK,kBAAkB,EAEvB,KAAK,wBAAwB,EAE9B,MAAM,YAAY,CAAC;AAEpB,OAAO,EAAQ,KAAK,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAK5D,eAAO,MAAM,6BAA6B,qGAQrC,wBAAwB,oDA0B5B,CAAC;AAEF,eAAO,MAAM,0BAA0B,SAAS,CAAC;AAEjD,MAAM,MAAM,0BAA0B,GAAG,OAAO,0BAA0B,CAAC;AAE3E,MAAM,MAAM,qBAAqB,GAAG,aAAa,GAAG;IAClD;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB,CAAC;AAEF,MAAM,MAAM,iBAAiB,CAAC,WAAW,SAAS,KAAK,CAAC,WAAW,IAAI,WAAW,CAAC,KAAK,CACtF,WAAW,EACX,qBAAqB,CACtB,CAAC;AAYF,KAAK,qBAAqB,GAAG,CAAC,CAAC,WAAW,SAAS,KAAK,CAAC,WAAW,GAAG,0BAA0B,EAC/F,KAAK,EAAE,iBAAiB,CAAC,WAAW,CAAC,KAClC,WAAW,CAAC,WAAW,CAAC,GAC3B,WAAW,CAAC,UAAU,CAAC;AAEzB,eAAO,MAAM,YAAY,EAAE,qBAiC1B,CAAC;AASF,MAAM,MAAM,mBAAmB,GAAG,kBAAkB,CAAC;AAErD;;;GAGG;AACH,eAAO,MAAM,cAAc;;YA1GvB,CADJ;WAG0B,CAAC;uBAEY,CAAC;;;YAOf,CAAC;WACb,CAAC;uBAGN,CAAP;;qCAqIA,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const _excluded = ["as", "variant", "transparent", "compact", "background", "color", "borderColor", "borderRadius", "borderWidth", "alignItems", "justifyContent", "className", "style", "padding", "name", "iconSize", "active", "flush", "loading", "progressCircleSize", "accessibilityLabel", "accessibilityHint"];
|
|
1
|
+
const _excluded = ["as", "variant", "transparent", "compact", "background", "color", "borderColor", "borderRadius", "borderWidth", "alignItems", "justifyContent", "className", "style", "padding", "name", "iconSize", "active", "flush", "loading", "progressCircleSize", "accessibilityLabel", "accessibilityHint", "styles", "classNames"];
|
|
2
2
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3
3
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
4
|
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
@@ -16,7 +16,18 @@ import { Icon } from '../icons/Icon';
|
|
|
16
16
|
import { Pressable } from '../system/Pressable';
|
|
17
17
|
import { ProgressCircle } from '../visualizations/ProgressCircle';
|
|
18
18
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
19
|
-
|
|
19
|
+
/**
|
|
20
|
+
* Static class names for IconButton component parts.
|
|
21
|
+
* Use these selectors to target specific elements with CSS.
|
|
22
|
+
*/
|
|
23
|
+
export const iconButtonClassNames = {
|
|
24
|
+
/** Root button element */
|
|
25
|
+
root: 'cds-IconButton',
|
|
26
|
+
/** Inner icon glyph element */
|
|
27
|
+
icon: 'cds-IconButton-icon',
|
|
28
|
+
/** Loading progress circle element */
|
|
29
|
+
progressCircle: 'cds-IconButton-progressCircle'
|
|
30
|
+
};
|
|
20
31
|
export const iconButtonDefaultElement = 'button';
|
|
21
32
|
const baseCss = "baseCss-b1po8mo6";
|
|
22
33
|
export const IconButton = /*#__PURE__*/memo(/*#__PURE__*/forwardRef((_props, ref) => {
|
|
@@ -44,7 +55,9 @@ export const IconButton = /*#__PURE__*/memo(/*#__PURE__*/forwardRef((_props, ref
|
|
|
44
55
|
loading,
|
|
45
56
|
progressCircleSize,
|
|
46
57
|
accessibilityLabel,
|
|
47
|
-
accessibilityHint
|
|
58
|
+
accessibilityHint,
|
|
59
|
+
styles,
|
|
60
|
+
classNames
|
|
48
61
|
} = mergedProps,
|
|
49
62
|
props = _objectWithoutProperties(mergedProps, _excluded);
|
|
50
63
|
const Component = as !== null && as !== void 0 ? as : iconButtonDefaultElement;
|
|
@@ -76,7 +89,7 @@ export const IconButton = /*#__PURE__*/memo(/*#__PURE__*/forwardRef((_props, ref
|
|
|
76
89
|
borderColor: borderColorValue,
|
|
77
90
|
borderRadius: borderRadius,
|
|
78
91
|
borderWidth: borderWidth,
|
|
79
|
-
className: cx(
|
|
92
|
+
className: cx(iconButtonClassNames.root, baseCss, classNames === null || classNames === void 0 ? void 0 : classNames.root, className),
|
|
80
93
|
color: colorValue,
|
|
81
94
|
"data-compact": compact,
|
|
82
95
|
"data-flush": flush,
|
|
@@ -91,15 +104,23 @@ export const IconButton = /*#__PURE__*/memo(/*#__PURE__*/forwardRef((_props, ref
|
|
|
91
104
|
children: loading ? /*#__PURE__*/_jsx(ProgressCircle, {
|
|
92
105
|
indeterminate: true,
|
|
93
106
|
accessibilityLabel: "Loading",
|
|
107
|
+
className: cx(iconButtonClassNames.progressCircle, classNames === null || classNames === void 0 ? void 0 : classNames.progressCircle),
|
|
94
108
|
color: "currentColor",
|
|
95
109
|
size: progressCircleSize !== null && progressCircleSize !== void 0 ? progressCircleSize : iconSizeValue,
|
|
110
|
+
style: styles === null || styles === void 0 ? void 0 : styles.progressCircle,
|
|
96
111
|
testID: props.testID ? "".concat(props.testID, "-progress-circle") : undefined,
|
|
97
112
|
weight: "thin"
|
|
98
113
|
}) : /*#__PURE__*/_jsx(Icon, {
|
|
99
114
|
active: active,
|
|
115
|
+
classNames: {
|
|
116
|
+
icon: cx(iconButtonClassNames.icon, classNames === null || classNames === void 0 ? void 0 : classNames.icon)
|
|
117
|
+
},
|
|
100
118
|
color: "currentColor",
|
|
101
119
|
name: name,
|
|
102
|
-
size: iconSize
|
|
120
|
+
size: iconSize,
|
|
121
|
+
styles: {
|
|
122
|
+
icon: styles === null || styles === void 0 ? void 0 : styles.icon
|
|
123
|
+
}
|
|
103
124
|
})
|
|
104
125
|
}));
|
|
105
126
|
}));
|
package/esm/chips/TabbedChips.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const _excluded = ["label", "id"],
|
|
2
|
-
_excluded2 = ["tabs", "value", "onChange", "Component", "paddleStyle", "testID", "background", "gap", "role", "previousArrowAccessibilityLabel", "nextArrowAccessibilityLabel", "width"];
|
|
2
|
+
_excluded2 = ["tabs", "value", "onChange", "Component", "paddleStyle", "testID", "background", "gap", "role", "previousArrowAccessibilityLabel", "nextArrowAccessibilityLabel", "width", "color"];
|
|
3
3
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
4
4
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
5
5
|
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
@@ -64,7 +64,8 @@ const TabbedChipsComponent = /*#__PURE__*/memo(/*#__PURE__*/forwardRef(function
|
|
|
64
64
|
role,
|
|
65
65
|
previousArrowAccessibilityLabel = 'Previous',
|
|
66
66
|
nextArrowAccessibilityLabel = 'Next',
|
|
67
|
-
width = '100%'
|
|
67
|
+
width = '100%',
|
|
68
|
+
color
|
|
68
69
|
} = mergedProps,
|
|
69
70
|
props = _objectWithoutProperties(mergedProps, _excluded2);
|
|
70
71
|
const [scrollTarget, setScrollTarget] = useState(null);
|
|
@@ -122,6 +123,7 @@ const TabbedChipsComponent = /*#__PURE__*/memo(/*#__PURE__*/forwardRef(function
|
|
|
122
123
|
TabsActiveIndicatorComponent: TabsActiveIndicatorComponent,
|
|
123
124
|
activeTab: activeTab || null,
|
|
124
125
|
background: background,
|
|
126
|
+
color: color,
|
|
125
127
|
gap: gap,
|
|
126
128
|
onActiveTabElementChange: setScrollTarget,
|
|
127
129
|
onChange: handleChange,
|
|
@@ -54,27 +54,23 @@ export const Collapsible = /*#__PURE__*/memo(/*#__PURE__*/forwardRef((_props, fo
|
|
|
54
54
|
};
|
|
55
55
|
}, [direction, maxWidth, maxHeight]);
|
|
56
56
|
|
|
57
|
-
//
|
|
58
|
-
|
|
59
|
-
//
|
|
60
|
-
|
|
61
|
-
|
|
57
|
+
// display: none is applied after the collapse animation completes so the element no longer
|
|
58
|
+
// participates in layout and its children are not focusable. It is restored immediately when
|
|
59
|
+
// expanding so the animation has content to reveal.
|
|
60
|
+
const [isDisplayNone, setIsDisplayNone] = useState(collapsed);
|
|
61
|
+
if (!collapsed && isDisplayNone) {
|
|
62
|
+
setIsDisplayNone(false);
|
|
62
63
|
}
|
|
63
|
-
|
|
64
|
-
// when the animation completes, set the visibility to "hidden" if the content should be collapsed
|
|
65
|
-
// this is to prevent children of the Collapsible element from being focusable in this state
|
|
66
64
|
const handleAnimationComplete = useCallback(() => {
|
|
67
65
|
if (collapsed) {
|
|
68
|
-
|
|
66
|
+
setIsDisplayNone(true);
|
|
69
67
|
}
|
|
70
68
|
}, [collapsed]);
|
|
71
|
-
|
|
72
|
-
// merge visible style with the computed framer-motion styles
|
|
73
69
|
const style = useMemo(() => {
|
|
74
|
-
return _objectSpread(_objectSpread({}, motionStyle), {}, {
|
|
75
|
-
|
|
76
|
-
});
|
|
77
|
-
}, [
|
|
70
|
+
return isDisplayNone ? _objectSpread(_objectSpread({}, motionStyle), {}, {
|
|
71
|
+
display: 'none'
|
|
72
|
+
}) : motionStyle;
|
|
73
|
+
}, [motionStyle, isDisplayNone]);
|
|
78
74
|
return (
|
|
79
75
|
/*#__PURE__*/
|
|
80
76
|
// TODO: Remove type assertion after upgrading framer-motion to v11+ for React 19 compatibility
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const _excluded = ["color", "disabled"];
|
|
1
|
+
const _excluded = ["color", "disabled", "font"];
|
|
2
2
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3
3
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
4
|
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
@@ -12,7 +12,8 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
12
12
|
export const InputLabel = /*#__PURE__*/memo(function InputLabel(_ref) {
|
|
13
13
|
let {
|
|
14
14
|
color = 'fg',
|
|
15
|
-
disabled = false
|
|
15
|
+
disabled = false,
|
|
16
|
+
font = 'label1'
|
|
16
17
|
} = _ref,
|
|
17
18
|
props = _objectWithoutProperties(_ref, _excluded);
|
|
18
19
|
return /*#__PURE__*/_jsx(Text, _objectSpread({
|
|
@@ -20,7 +21,7 @@ export const InputLabel = /*#__PURE__*/memo(function InputLabel(_ref) {
|
|
|
20
21
|
color: color,
|
|
21
22
|
disabled: disabled,
|
|
22
23
|
display: "block",
|
|
23
|
-
font:
|
|
24
|
+
font: font,
|
|
24
25
|
paddingY: 0.5
|
|
25
26
|
}, props));
|
|
26
27
|
});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const _excluded = ["label", "accessibilityLabel", "helperText", "variant", "testID", "testIDMap", "start", "end", "width", "disabled", "align", "font", "compact", "suffix", "onFocus", "onBlur", "borderRadius", "height", "inputNode", "bordered", "focusedBorderWidth", "enableColorSurge", "helperTextErrorIconAccessibilityLabel", "labelVariant", "labelNode", "inputBackground"];
|
|
1
|
+
const _excluded = ["label", "labelFont", "labelColor", "accessibilityLabel", "helperText", "variant", "testID", "testIDMap", "start", "end", "width", "disabled", "align", "font", "compact", "suffix", "onFocus", "onBlur", "borderRadius", "height", "inputNode", "bordered", "focusedBorderWidth", "enableColorSurge", "helperTextErrorIconAccessibilityLabel", "labelVariant", "labelNode", "inputBackground"];
|
|
2
2
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3
3
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
4
|
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
@@ -48,6 +48,8 @@ export const TextInput = /*#__PURE__*/memo(/*#__PURE__*/forwardRef(function Text
|
|
|
48
48
|
const mergedProps = useComponentConfig('TextInput', _props);
|
|
49
49
|
const {
|
|
50
50
|
label,
|
|
51
|
+
labelFont = 'label1',
|
|
52
|
+
labelColor = 'fg',
|
|
51
53
|
accessibilityLabel,
|
|
52
54
|
helperText = '',
|
|
53
55
|
variant = 'foregroundMuted',
|
|
@@ -202,6 +204,8 @@ export const TextInput = /*#__PURE__*/memo(/*#__PURE__*/forwardRef(function Text
|
|
|
202
204
|
}) : labelNode : !!label && /*#__PURE__*/_jsx(InputLabel, {
|
|
203
205
|
background: labelVariant === 'inside' ? readOnlyInputBackground : undefined,
|
|
204
206
|
className: cx(labelVariant === 'inside' && insideLabelCss, labelVariant === 'inside' && !!start && insideLabelCssStartCss),
|
|
207
|
+
color: labelColor,
|
|
208
|
+
font: labelFont,
|
|
205
209
|
htmlFor: shouldSetLabelId ? labelId : undefined,
|
|
206
210
|
testID: (_testIDMap$label = testIDMap === null || testIDMap === void 0 ? void 0 : testIDMap.label) !== null && _testIDMap$label !== void 0 ? _testIDMap$label : '',
|
|
207
211
|
children: label
|
|
@@ -216,6 +220,8 @@ export const TextInput = /*#__PURE__*/memo(/*#__PURE__*/forwardRef(function Text
|
|
|
216
220
|
paddingStart: compact && hasLabel ? 2 : undefined,
|
|
217
221
|
testID: (_testIDMap$start = testIDMap === null || testIDMap === void 0 ? void 0 : testIDMap.start) !== null && _testIDMap$start !== void 0 ? _testIDMap$start : '',
|
|
218
222
|
children: [compact && (labelNode ? labelNode : !!label && /*#__PURE__*/_jsx(InputLabel, {
|
|
223
|
+
color: labelColor,
|
|
224
|
+
font: labelFont,
|
|
219
225
|
htmlFor: shouldSetLabelId ? labelId : undefined,
|
|
220
226
|
children: label
|
|
221
227
|
})), !!start && /*#__PURE__*/_jsx(_Fragment, {
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
import { styleVarPrefixes } from './theme';
|
|
2
2
|
const periodsRegex = /\./g;
|
|
3
3
|
|
|
4
|
+
// Converts a camelCase illustration theme key to the kebab-case CSS var suffix that
|
|
5
|
+
// the generated themeable SVGs expect: accent1 → accent-1, gray2 → gray-2.
|
|
6
|
+
const toIllustrationVarSuffix = key => key.replace(/([a-z])(\d+)$/i, '$1-$2');
|
|
7
|
+
|
|
4
8
|
/** Takes a theme object and formats its keys as CSS variables to be used in inline styles. */
|
|
5
9
|
export const createThemeCssVars = theme => {
|
|
6
10
|
const themeCss = {};
|
|
@@ -14,6 +18,25 @@ export const createThemeCssVars = theme => {
|
|
|
14
18
|
themeCss['--activeColorScheme'] = theme.activeColorScheme;
|
|
15
19
|
continue;
|
|
16
20
|
}
|
|
21
|
+
|
|
22
|
+
// lightIllustrationColor/darkIllustrationColor are resolved into theme.illustrationColor by ThemeProvider.
|
|
23
|
+
// Skip them here to avoid emitting --lightIllustrationColor-* / --darkIllustrationColor-* vars.
|
|
24
|
+
if (key === 'lightIllustrationColor' || key === 'darkIllustrationColor') {
|
|
25
|
+
continue;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
// Illustration colors use a kebab-converted key format to match the var(--illustration-accent-1)
|
|
29
|
+
// tokens in the generated themeable SVGs, so they need special handling rather than the default
|
|
30
|
+
// period-to-underscore substitution.
|
|
31
|
+
if (key === 'illustrationColor') {
|
|
32
|
+
for (const varName of Object.keys(themeVars)) {
|
|
33
|
+
const value = themeVars[varName];
|
|
34
|
+
if (value !== undefined) {
|
|
35
|
+
themeCss["--illustration-".concat(toIllustrationVarSuffix(varName))] = value;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
continue;
|
|
39
|
+
}
|
|
17
40
|
const prefix = styleVarPrefixes[key];
|
|
18
41
|
const cssVarPrefix = prefix ? "--".concat(prefix, "-") : '--';
|
|
19
42
|
const varNames = Object.keys(themeVars);
|
package/esm/core/theme.js
CHANGED
|
@@ -4,6 +4,9 @@ export const styleVarPrefixes = {
|
|
|
4
4
|
darkSpectrum: 'dark',
|
|
5
5
|
lightColor: 'lightColor',
|
|
6
6
|
darkColor: 'darkColor',
|
|
7
|
+
lightIllustrationColor: 'lightIllustrationColor',
|
|
8
|
+
darkIllustrationColor: 'darkIllustrationColor',
|
|
9
|
+
illustrationColor: 'illustration',
|
|
7
10
|
spectrum: '',
|
|
8
11
|
color: 'color',
|
|
9
12
|
space: 'space',
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import heroSquareSvgEsmMap from '@coinbase/cds-illustrations/__generated__/heroSquare/data/svgEsmMap';
|
|
1
2
|
import heroSquareVersionMap from '@coinbase/cds-illustrations/__generated__/heroSquare/data/versionMap';
|
|
2
3
|
import { createIllustration } from './createIllustration';
|
|
3
|
-
export const HeroSquare = createIllustration('heroSquare', heroSquareVersionMap);
|
|
4
|
+
export const HeroSquare = createIllustration('heroSquare', heroSquareVersionMap, heroSquareSvgEsmMap);
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import pictogramSvgEsmMap from '@coinbase/cds-illustrations/__generated__/pictogram/data/svgEsmMap';
|
|
1
2
|
import pictogramVersionMap from '@coinbase/cds-illustrations/__generated__/pictogram/data/versionMap';
|
|
2
3
|
import { createIllustration } from './createIllustration';
|
|
3
|
-
export const Pictogram = createIllustration('pictogram', pictogramVersionMap);
|
|
4
|
+
export const Pictogram = createIllustration('pictogram', pictogramVersionMap, pictogramSvgEsmMap);
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import spotIconSvgEsmMap from '@coinbase/cds-illustrations/__generated__/spotIcon/data/svgEsmMap';
|
|
1
2
|
import spotIconVersionMap from '@coinbase/cds-illustrations/__generated__/spotIcon/data/versionMap';
|
|
2
3
|
import { createIllustration } from './createIllustration';
|
|
3
|
-
export const SpotIcon = createIllustration('spotIcon', spotIconVersionMap);
|
|
4
|
+
export const SpotIcon = createIllustration('spotIcon', spotIconVersionMap, spotIconSvgEsmMap);
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import spotRectangleSvgEsmMap from '@coinbase/cds-illustrations/__generated__/spotRectangle/data/svgEsmMap';
|
|
1
2
|
import spotRectangleVersionMap from '@coinbase/cds-illustrations/__generated__/spotRectangle/data/versionMap';
|
|
2
3
|
import { createIllustration } from './createIllustration';
|
|
3
|
-
export const SpotRectangle = createIllustration('spotRectangle', spotRectangleVersionMap);
|
|
4
|
+
export const SpotRectangle = createIllustration('spotRectangle', spotRectangleVersionMap, spotRectangleSvgEsmMap);
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import spotSquareSvgEsmMap from '@coinbase/cds-illustrations/__generated__/spotSquare/data/svgEsmMap';
|
|
1
2
|
import spotSquareVersionMap from '@coinbase/cds-illustrations/__generated__/spotSquare/data/versionMap';
|
|
2
3
|
import { createIllustration } from './createIllustration';
|
|
3
|
-
export const SpotSquare = createIllustration('spotSquare', spotSquareVersionMap);
|
|
4
|
+
export const SpotSquare = createIllustration('spotSquare', spotSquareVersionMap, spotSquareSvgEsmMap);
|