@rango-dev/ui 0.17.1-next.5 → 0.17.1-next.7
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 +6 -6
- package/dist/index.js.map +4 -4
- package/dist/widget/ui/src/components/Alert/Alert.styles.d.ts +3 -0
- package/dist/widget/ui/src/components/Alert/Alert.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/BestRoute/BestRoute.styles.d.ts +9 -0
- package/dist/widget/ui/src/components/BestRoute/BestRoute.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/BestRoute/BestRouteSkeleton.styles.d.ts +2 -0
- package/dist/widget/ui/src/components/BestRoute/BestRouteSkeleton.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/BestRoute/RouteSummary.styles.d.ts +1 -0
- package/dist/widget/ui/src/components/BestRoute/RouteSummary.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/BlockchainsChip/BlockchainsChip.styles.d.ts +1 -0
- package/dist/widget/ui/src/components/BlockchainsChip/BlockchainsChip.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/BottomLogo/BottomLogo.styles.d.ts +2 -0
- package/dist/widget/ui/src/components/BottomLogo/BottomLogo.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Button/Button.styles.d.ts +3 -0
- package/dist/widget/ui/src/components/Button/Button.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/ChainToken/ChainToken.styles.d.ts +2 -0
- package/dist/widget/ui/src/components/ChainToken/ChainToken.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Checkbox/Checkbox.styles.d.ts +4 -0
- package/dist/widget/ui/src/components/Checkbox/Checkbox.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Chip/Chip.styles.d.ts +1 -0
- package/dist/widget/ui/src/components/Chip/Chip.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Collapsible/Collapsible.styles.d.ts +1 -0
- package/dist/widget/ui/src/components/Collapsible/Collapsible.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Drawer/Drawer.styles.d.ts +5 -0
- package/dist/widget/ui/src/components/Drawer/Drawer.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Header/Header.styles.d.ts +2 -0
- package/dist/widget/ui/src/components/Header/Header.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Icon/CloseIcon.d.ts +1 -0
- package/dist/widget/ui/src/components/Icon/CloseIcon.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Icon/common.d.ts +2 -0
- package/dist/widget/ui/src/components/Icon/common.d.ts.map +1 -1
- package/dist/widget/ui/src/components/List/List.styles.d.ts +1 -0
- package/dist/widget/ui/src/components/List/List.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/ListItem/ListItem.styles.d.ts +1 -0
- package/dist/widget/ui/src/components/ListItem/ListItem.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/ListItemButton/ListItemButton.styles.d.ts +1 -0
- package/dist/widget/ui/src/components/ListItemButton/ListItemButton.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/MessageBox/CollapsibleMessageBox.styles.d.ts +1 -0
- package/dist/widget/ui/src/components/MessageBox/CollapsibleMessageBox.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/MessageBox/MessageBox.styles.d.ts +3 -0
- package/dist/widget/ui/src/components/MessageBox/MessageBox.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Modal/Modal.styles.d.ts +6 -0
- package/dist/widget/ui/src/components/Modal/Modal.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/NotFound/NotFound.styles.d.ts +1 -0
- package/dist/widget/ui/src/components/NotFound/NotFound.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Popover/Popover.styles.d.ts +2 -0
- package/dist/widget/ui/src/components/Popover/Popover.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/PriceImpact/PriceImpact.styles.d.ts +1 -0
- package/dist/widget/ui/src/components/PriceImpact/PriceImpact.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Radio/Radio.styles.d.ts +2 -0
- package/dist/widget/ui/src/components/Radio/Radio.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/RadioGroup/RadioGroup.styles.d.ts +4 -0
- package/dist/widget/ui/src/components/RadioGroup/RadioGroup.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/RouteCost/RouteCost.styles.d.ts +1 -0
- package/dist/widget/ui/src/components/RouteCost/RouteCost.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/RoutesOverview/RoutesOverview.d.ts +1 -0
- package/dist/widget/ui/src/components/RoutesOverview/RoutesOverview.d.ts.map +1 -1
- package/dist/widget/ui/src/components/SelectableCategoryList/SelectableCategoryList.styles.d.ts +3 -0
- package/dist/widget/ui/src/components/SelectableCategoryList/SelectableCategoryList.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Skeleton/Skeleton.styles.d.ts +1 -0
- package/dist/widget/ui/src/components/Skeleton/Skeleton.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/StepDetails/StepDetails.styles.d.ts +5 -0
- package/dist/widget/ui/src/components/StepDetails/StepDetails.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/SvgIcon/SvgIcon.style.d.ts +1 -0
- package/dist/widget/ui/src/components/SvgIcon/SvgIcon.style.d.ts.map +1 -1
- package/dist/widget/ui/src/components/SwapDetailsPlaceholder/SwapDetailsPlaceholder.d.ts +1 -0
- package/dist/widget/ui/src/components/SwapDetailsPlaceholder/SwapDetailsPlaceholder.d.ts.map +1 -1
- package/dist/widget/ui/src/components/SwapListItem/SwapListItem.styles.d.ts +6 -0
- package/dist/widget/ui/src/components/SwapListItem/SwapListItem.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/SwapListItem/SwapToken.styles.d.ts +9 -0
- package/dist/widget/ui/src/components/SwapListItem/SwapToken.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Switch/Switch.styles.d.ts +2 -0
- package/dist/widget/ui/src/components/Switch/Switch.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/TextField/TextField.styles.d.ts +3 -0
- package/dist/widget/ui/src/components/TextField/TextField.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Tooltip/Tooltip.styles.d.ts +3 -0
- package/dist/widget/ui/src/components/Tooltip/Tooltip.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Typography/Typography.styles.d.ts +1 -0
- package/dist/widget/ui/src/components/Typography/Typography.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Wallet/Wallet.styles.d.ts +5 -0
- package/dist/widget/ui/src/components/Wallet/Wallet.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/common/FilledCircle.d.ts +1 -0
- package/dist/widget/ui/src/components/common/FilledCircle.d.ts.map +1 -1
- package/dist/widget/ui/src/components/common/styles.d.ts +1 -0
- package/dist/widget/ui/src/components/common/styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/index.d.ts +0 -1
- package/dist/widget/ui/src/components/index.d.ts.map +1 -1
- package/dist/widget/ui/src/containers/SwapHistory/SwapHistory.d.ts +10 -0
- package/dist/widget/ui/src/containers/SwapHistory/SwapHistory.d.ts.map +1 -1
- package/dist/widget/ui/src/containers/SwapInput/SwapInput.styles.d.ts +3 -0
- package/dist/widget/ui/src/containers/SwapInput/SwapInput.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/containers/SwapInput/TokenSection.styles.d.ts +2 -0
- package/dist/widget/ui/src/containers/SwapInput/TokenSection.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/containers/TokenSelector/TokenSelector.d.ts +1 -0
- package/dist/widget/ui/src/containers/TokenSelector/TokenSelector.d.ts.map +1 -1
- package/dist/widget/ui/src/theme.d.ts +10 -0
- package/dist/widget/ui/src/theme.d.ts.map +1 -1
- package/package.json +1 -3
- package/src/components/index.ts +0 -1
- package/src/theme.ts +3 -2
- package/dist/widget/ui/src/components/ColorPicker/ColorPicker.d.ts +0 -10
- package/dist/widget/ui/src/components/ColorPicker/ColorPicker.d.ts.map +0 -1
- package/dist/widget/ui/src/components/ColorPicker/ColorPicker.stories.d.ts +0 -6
- package/dist/widget/ui/src/components/ColorPicker/ColorPicker.stories.d.ts.map +0 -1
- package/dist/widget/ui/src/components/ColorPicker/index.d.ts +0 -2
- package/dist/widget/ui/src/components/ColorPicker/index.d.ts.map +0 -1
- package/src/components/ColorPicker/ColorPicker.stories.tsx +0 -46
- package/src/components/ColorPicker/ColorPicker.tsx +0 -107
- package/src/components/ColorPicker/index.ts +0 -1
|
@@ -52,6 +52,7 @@ export declare const SwapperContainer: import("@stitches/react/types/styled-comp
|
|
|
52
52
|
warning500: string;
|
|
53
53
|
warning600: string;
|
|
54
54
|
warning700: string;
|
|
55
|
+
info: string;
|
|
55
56
|
info100: string;
|
|
56
57
|
info300: string;
|
|
57
58
|
info500: string;
|
|
@@ -208,6 +209,7 @@ export declare const BodyError: import("@stitches/react/types/styled-component")
|
|
|
208
209
|
warning500: string;
|
|
209
210
|
warning600: string;
|
|
210
211
|
warning700: string;
|
|
212
|
+
info: string;
|
|
211
213
|
info100: string;
|
|
212
214
|
info300: string;
|
|
213
215
|
info500: string;
|
|
@@ -364,6 +366,7 @@ export declare const ErrorMsg: import("@stitches/react/types/styled-component").
|
|
|
364
366
|
warning500: string;
|
|
365
367
|
warning600: string;
|
|
366
368
|
warning700: string;
|
|
369
|
+
info: string;
|
|
367
370
|
info100: string;
|
|
368
371
|
info300: string;
|
|
369
372
|
info500: string;
|
|
@@ -520,6 +523,7 @@ export declare const FeeContainer: import("@stitches/react/types/styled-componen
|
|
|
520
523
|
warning500: string;
|
|
521
524
|
warning600: string;
|
|
522
525
|
warning700: string;
|
|
526
|
+
info: string;
|
|
523
527
|
info100: string;
|
|
524
528
|
info300: string;
|
|
525
529
|
info500: string;
|
|
@@ -676,6 +680,7 @@ export declare const Fee: import("@stitches/react/types/styled-component").Style
|
|
|
676
680
|
warning500: string;
|
|
677
681
|
warning600: string;
|
|
678
682
|
warning700: string;
|
|
683
|
+
info: string;
|
|
679
684
|
info100: string;
|
|
680
685
|
info300: string;
|
|
681
686
|
info500: string;
|
|
@@ -832,6 +837,7 @@ export declare const RelativeContainer: import("@stitches/react/types/styled-com
|
|
|
832
837
|
warning500: string;
|
|
833
838
|
warning600: string;
|
|
834
839
|
warning700: string;
|
|
840
|
+
info: string;
|
|
835
841
|
info100: string;
|
|
836
842
|
info300: string;
|
|
837
843
|
info500: string;
|
|
@@ -988,6 +994,7 @@ export declare const Footer: import("@stitches/react/types/styled-component").St
|
|
|
988
994
|
warning500: string;
|
|
989
995
|
warning600: string;
|
|
990
996
|
warning700: string;
|
|
997
|
+
info: string;
|
|
991
998
|
info100: string;
|
|
992
999
|
info300: string;
|
|
993
1000
|
info500: string;
|
|
@@ -1144,6 +1151,7 @@ export declare const Dot: import("@stitches/react/types/styled-component").Style
|
|
|
1144
1151
|
warning500: string;
|
|
1145
1152
|
warning600: string;
|
|
1146
1153
|
warning700: string;
|
|
1154
|
+
info: string;
|
|
1147
1155
|
info100: string;
|
|
1148
1156
|
info300: string;
|
|
1149
1157
|
info500: string;
|
|
@@ -1300,6 +1308,7 @@ export declare const ArrowDown: import("@stitches/react/types/styled-component")
|
|
|
1300
1308
|
warning500: string;
|
|
1301
1309
|
warning600: string;
|
|
1302
1310
|
warning700: string;
|
|
1311
|
+
info: string;
|
|
1303
1312
|
info100: string;
|
|
1304
1313
|
info300: string;
|
|
1305
1314
|
info500: string;
|
|
@@ -1456,6 +1465,7 @@ export declare const Line: import("@stitches/react/types/styled-component").Styl
|
|
|
1456
1465
|
warning500: string;
|
|
1457
1466
|
warning600: string;
|
|
1458
1467
|
warning700: string;
|
|
1468
|
+
info: string;
|
|
1459
1469
|
info100: string;
|
|
1460
1470
|
info300: string;
|
|
1461
1471
|
info500: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SwapHistory.d.ts","sourceRoot":"","sources":["../../../../../../src/containers/SwapHistory/SwapHistory.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,IAAI,qBAAqB,EAAE,MAAM,gBAAgB,CAAC;AACzE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAEpD,OAAO,KAAmB,MAAM,OAAO,CAAC;AAExC,OAAO,EASL,UAAU,EACX,MAAM,kBAAkB,CAAC;AAU1B,eAAO,MAAM,KAAK;;;CAUhB,CAAC;AAEH,eAAO,MAAM,gBAAgB
|
|
1
|
+
{"version":3,"file":"SwapHistory.d.ts","sourceRoot":"","sources":["../../../../../../src/containers/SwapHistory/SwapHistory.tsx"],"names":[],"mappings":"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"}
|
|
@@ -46,6 +46,7 @@ export declare const Container: import("@stitches/react/types/styled-component")
|
|
|
46
46
|
warning500: string;
|
|
47
47
|
warning600: string;
|
|
48
48
|
warning700: string;
|
|
49
|
+
info: string;
|
|
49
50
|
info100: string;
|
|
50
51
|
info300: string;
|
|
51
52
|
info500: string;
|
|
@@ -211,6 +212,7 @@ export declare const InputAmount: import("@stitches/react/types/styled-component
|
|
|
211
212
|
warning500: string;
|
|
212
213
|
warning600: string;
|
|
213
214
|
warning700: string;
|
|
215
|
+
info: string;
|
|
214
216
|
info100: string;
|
|
215
217
|
info300: string;
|
|
216
218
|
info500: string;
|
|
@@ -646,6 +648,7 @@ export declare const MaxButton: import("@stitches/react/types/styled-component")
|
|
|
646
648
|
warning500: string;
|
|
647
649
|
warning600: string;
|
|
648
650
|
warning700: string;
|
|
651
|
+
info: string;
|
|
649
652
|
info100: string;
|
|
650
653
|
info300: string;
|
|
651
654
|
info500: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SwapInput.styles.d.ts","sourceRoot":"","sources":["../../../../../../src/containers/SwapInput/SwapInput.styles.ts"],"names":[],"mappings":";;;AAGA,eAAO,MAAM,SAAS
|
|
1
|
+
{"version":3,"file":"SwapInput.styles.d.ts","sourceRoot":"","sources":["../../../../../../src/containers/SwapInput/SwapInput.styles.ts"],"names":[],"mappings":";;;AAGA,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;+DAyCpB,CAAC;AAEH,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;+DAUtB,CAAC;AACH,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;+DAMpB,CAAC"}
|
|
@@ -323,6 +323,7 @@ export declare const Container: import("@stitches/react/types/styled-component")
|
|
|
323
323
|
warning500: string;
|
|
324
324
|
warning600: string;
|
|
325
325
|
warning700: string;
|
|
326
|
+
info: string;
|
|
326
327
|
info100: string;
|
|
327
328
|
info300: string;
|
|
328
329
|
info500: string;
|
|
@@ -479,6 +480,7 @@ export declare const TokenSectionContainer: import("@stitches/react/types/styled
|
|
|
479
480
|
warning500: string;
|
|
480
481
|
warning600: string;
|
|
481
482
|
warning700: string;
|
|
483
|
+
info: string;
|
|
482
484
|
info100: string;
|
|
483
485
|
info300: string;
|
|
484
486
|
info500: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TokenSection.styles.d.ts","sourceRoot":"","sources":["../../../../../../src/containers/SwapInput/TokenSection.styles.ts"],"names":[],"mappings":";;;AAGA,eAAO,MAAM,SAAS
|
|
1
|
+
{"version":3,"file":"TokenSection.styles.d.ts","sourceRoot":"","sources":["../../../../../../src/containers/SwapInput/TokenSection.styles.ts"],"names":[],"mappings":";;;AAGA,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;+DAwBpB,CAAC;AAEH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;+DAmBhC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TokenSelector.d.ts","sourceRoot":"","sources":["../../../../../../src/containers/TokenSelector/TokenSelector.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAIjD,OAAO,EAEL,eAAe,EAChB,MAAM,sCAAsC,CAAC;AAE9C,eAAO,MAAM,eAAe
|
|
1
|
+
{"version":3,"file":"TokenSelector.d.ts","sourceRoot":"","sources":["../../../../../../src/containers/TokenSelector/TokenSelector.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAIjD,OAAO,EAEL,eAAe,EAChB,MAAM,sCAAsC,CAAC;AAE9C,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;+DAM1B,CAAC;AACH,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,eAAe,EAAE,CAAC;IACxB,IAAI,CAAC,EAAE,QAAQ,GAAG,aAAa,CAAC;IAChC,QAAQ,EAAE,eAAe,GAAG,IAAI,CAAC;IACjC,QAAQ,EAAE,CAAC,KAAK,EAAE,eAAe,KAAK,IAAI,CAAC;IAC3C,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,aAAa,EAAE,aAAa,CAAC;IAC7B,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAUD,wBAAgB,aAAa,CAAC,KAAK,EAAE,SAAS,qBAkC7C"}
|
|
@@ -35,6 +35,7 @@ export declare const theme: {
|
|
|
35
35
|
warning500: string;
|
|
36
36
|
warning600: string;
|
|
37
37
|
warning700: string;
|
|
38
|
+
info: string;
|
|
38
39
|
info100: string;
|
|
39
40
|
info300: string;
|
|
40
41
|
info500: string;
|
|
@@ -209,6 +210,7 @@ export declare const styled: <Type extends import("react").ComponentType<any> |
|
|
|
209
210
|
warning500: string;
|
|
210
211
|
warning600: string;
|
|
211
212
|
warning700: string;
|
|
213
|
+
info: string;
|
|
212
214
|
info100: string;
|
|
213
215
|
info300: string;
|
|
214
216
|
info500: string;
|
|
@@ -375,6 +377,7 @@ export declare const styled: <Type extends import("react").ComponentType<any> |
|
|
|
375
377
|
warning500: string;
|
|
376
378
|
warning600: string;
|
|
377
379
|
warning700: string;
|
|
380
|
+
info: string;
|
|
378
381
|
info100: string;
|
|
379
382
|
info300: string;
|
|
380
383
|
info500: string;
|
|
@@ -528,6 +531,7 @@ export declare const styled: <Type extends import("react").ComponentType<any> |
|
|
|
528
531
|
warning500: string;
|
|
529
532
|
warning600: string;
|
|
530
533
|
warning700: string;
|
|
534
|
+
info: string;
|
|
531
535
|
info100: string;
|
|
532
536
|
info300: string;
|
|
533
537
|
info500: string;
|
|
@@ -690,6 +694,7 @@ export declare const styled: <Type extends import("react").ComponentType<any> |
|
|
|
690
694
|
warning500?: string | number | boolean | undefined;
|
|
691
695
|
warning600?: string | number | boolean | undefined;
|
|
692
696
|
warning700?: string | number | boolean | undefined;
|
|
697
|
+
info?: string | number | boolean | undefined;
|
|
693
698
|
info100?: string | number | boolean | undefined;
|
|
694
699
|
info300?: string | number | boolean | undefined;
|
|
695
700
|
info500?: string | number | boolean | undefined;
|
|
@@ -842,6 +847,7 @@ export declare const styled: <Type extends import("react").ComponentType<any> |
|
|
|
842
847
|
warning500?: string | number | boolean | undefined;
|
|
843
848
|
warning600?: string | number | boolean | undefined;
|
|
844
849
|
warning700?: string | number | boolean | undefined;
|
|
850
|
+
info?: string | number | boolean | undefined;
|
|
845
851
|
info100?: string | number | boolean | undefined;
|
|
846
852
|
info300?: string | number | boolean | undefined;
|
|
847
853
|
info500?: string | number | boolean | undefined;
|
|
@@ -1002,6 +1008,7 @@ export declare const styled: <Type extends import("react").ComponentType<any> |
|
|
|
1002
1008
|
warning500: string;
|
|
1003
1009
|
warning600: string;
|
|
1004
1010
|
warning700: string;
|
|
1011
|
+
info: string;
|
|
1005
1012
|
info100: string;
|
|
1006
1013
|
info300: string;
|
|
1007
1014
|
info500: string;
|
|
@@ -1163,6 +1170,7 @@ export declare const styled: <Type extends import("react").ComponentType<any> |
|
|
|
1163
1170
|
warning500: string;
|
|
1164
1171
|
warning600: string;
|
|
1165
1172
|
warning700: string;
|
|
1173
|
+
info: string;
|
|
1166
1174
|
info100: string;
|
|
1167
1175
|
info300: string;
|
|
1168
1176
|
info500: string;
|
|
@@ -1315,6 +1323,7 @@ export declare const styled: <Type extends import("react").ComponentType<any> |
|
|
|
1315
1323
|
warning500: string;
|
|
1316
1324
|
warning600: string;
|
|
1317
1325
|
warning700: string;
|
|
1326
|
+
info: string;
|
|
1318
1327
|
info100: string;
|
|
1319
1328
|
info300: string;
|
|
1320
1329
|
info500: string;
|
|
@@ -1469,6 +1478,7 @@ export declare const styled: <Type extends import("react").ComponentType<any> |
|
|
|
1469
1478
|
warning500: string;
|
|
1470
1479
|
warning600: string;
|
|
1471
1480
|
warning700: string;
|
|
1481
|
+
info: string;
|
|
1472
1482
|
info100: string;
|
|
1473
1483
|
info300: string;
|
|
1474
1484
|
info500: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../../../src/theme.ts"],"names":[],"mappings":";AAGA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAMpE,eAAO,MAAM,KAAK
|
|
1
|
+
{"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../../../src/theme.ts"],"names":[],"mappings":";AAGA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAMpE,eAAO,MAAM,KAAK;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+JjB,CAAC;AAYF,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;CAuBtB,CAAC;AAMF,eAAO,MAAQ,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;0BAAE,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;SAAE,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4KAAE,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAAE,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;gDAAE,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAKjE,CAAC;AAEL,eAAO,MAAM,UAAU;;;gEAAoC,CAAC;AAE5D,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;MAKpB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rango-dev/ui",
|
|
3
|
-
"version": "0.17.1-next.
|
|
3
|
+
"version": "0.17.1-next.7",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "./dist/index.js",
|
|
@@ -65,9 +65,7 @@
|
|
|
65
65
|
"@radix-ui/react-tooltip": "^1.0.2",
|
|
66
66
|
"@rango-dev/wallets-shared": "^0.17.0",
|
|
67
67
|
"@stitches/react": "^1.2.8",
|
|
68
|
-
"@types/react-color": "^3.0.6",
|
|
69
68
|
"rango-sdk": "^0.1.35",
|
|
70
|
-
"react-color": "^2.19.3",
|
|
71
69
|
"react-virtualized-auto-sizer": "^1.0.7",
|
|
72
70
|
"react-window": "^1.8.8",
|
|
73
71
|
"react-window-infinite-loader": "^1.0.8",
|
package/src/components/index.ts
CHANGED
package/src/theme.ts
CHANGED
|
@@ -47,6 +47,7 @@ export const theme = {
|
|
|
47
47
|
warning600: '#38271F',
|
|
48
48
|
warning700: '#1A1412',
|
|
49
49
|
|
|
50
|
+
info: '#5BABFF',
|
|
50
51
|
info100: '#E9F3FF',
|
|
51
52
|
info300: '#C8E2FF',
|
|
52
53
|
info500: '#5BABFF',
|
|
@@ -213,9 +214,9 @@ export const { styled, css, createTheme, keyframes, globalCss, config } =
|
|
|
213
214
|
utils,
|
|
214
215
|
});
|
|
215
216
|
|
|
216
|
-
export const lightTheme = createTheme({});
|
|
217
|
+
export const lightTheme = createTheme('light-theme-ui', {});
|
|
217
218
|
|
|
218
|
-
export const darkTheme = createTheme({
|
|
219
|
+
export const darkTheme = createTheme('dark-theme-ui', {
|
|
219
220
|
colors: darkColors,
|
|
220
221
|
shadows: {
|
|
221
222
|
s: '0px 3px 5px 3px #222, 0px 6px 10px 3px #222, 0px 1px 18px 3px #222',
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export interface PropTypes {
|
|
3
|
-
color?: string;
|
|
4
|
-
place: 'top' | 'bottom' | 'left' | 'right';
|
|
5
|
-
onChangeColor: (color?: string) => void;
|
|
6
|
-
label?: string;
|
|
7
|
-
placeholder?: string;
|
|
8
|
-
}
|
|
9
|
-
export declare function ColorPicker({ color, onChangeColor, label, place, placeholder, }: PropTypes): React.JSX.Element;
|
|
10
|
-
//# sourceMappingURL=ColorPicker.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ColorPicker.d.ts","sourceRoot":"","sources":["../../../../../../src/components/ColorPicker/ColorPicker.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AA6CxC,MAAM,WAAW,SAAS;IACxB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,KAAK,GAAG,QAAQ,GAAG,MAAM,GAAG,OAAO,CAAC;IAC3C,aAAa,EAAE,CAAC,KAAK,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AASD,wBAAgB,WAAW,CAAC,EAC1B,KAAK,EACL,aAAa,EACb,KAAK,EACL,KAAK,EACL,WAAW,GACZ,EAAE,SAAS,qBAwCX"}
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { PropTypes } from './ColorPicker';
|
|
3
|
-
declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, PropTypes>;
|
|
4
|
-
export default _default;
|
|
5
|
-
export declare const Main: (args: PropTypes) => React.JSX.Element;
|
|
6
|
-
//# sourceMappingURL=ColorPicker.stories.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ColorPicker.stories.d.ts","sourceRoot":"","sources":["../../../../../../src/components/ColorPicker/ColorPicker.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAExC,OAAO,EAAe,SAAS,EAAE,MAAM,eAAe,CAAC;;AAEvD,wBAmB8B;AAE9B,eAAO,MAAM,IAAI,SAAU,SAAS,sBAoBnC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/components/ColorPicker/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC"}
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
import React, { useState } from 'react';
|
|
2
|
-
import { Meta } from '@storybook/react';
|
|
3
|
-
import { ColorPicker, PropTypes } from './ColorPicker';
|
|
4
|
-
|
|
5
|
-
export default {
|
|
6
|
-
title: 'Components/ColorPicker',
|
|
7
|
-
component: ColorPicker,
|
|
8
|
-
args: {
|
|
9
|
-
place: 'left',
|
|
10
|
-
},
|
|
11
|
-
argTypes: {
|
|
12
|
-
place: {
|
|
13
|
-
name: 'place',
|
|
14
|
-
control: { type: 'select' },
|
|
15
|
-
options: ['top', 'bottom', 'left', 'right'],
|
|
16
|
-
defaultValue: 'top',
|
|
17
|
-
},
|
|
18
|
-
placeholder: {
|
|
19
|
-
name: 'placeholder',
|
|
20
|
-
control: { type: 'text' },
|
|
21
|
-
defaultValue: 'Choose a color',
|
|
22
|
-
},
|
|
23
|
-
},
|
|
24
|
-
} as Meta<typeof ColorPicker>;
|
|
25
|
-
|
|
26
|
-
export const Main = (args: PropTypes) => {
|
|
27
|
-
const [color, setColor] = useState<string | undefined>('#5FA425');
|
|
28
|
-
return (
|
|
29
|
-
<div
|
|
30
|
-
style={{
|
|
31
|
-
height: 400,
|
|
32
|
-
display: 'flex',
|
|
33
|
-
justifyContent: 'center',
|
|
34
|
-
alignItems: 'center',
|
|
35
|
-
}}
|
|
36
|
-
>
|
|
37
|
-
<ColorPicker
|
|
38
|
-
{...args}
|
|
39
|
-
color={color}
|
|
40
|
-
onChangeColor={(color) => {
|
|
41
|
-
console.log(color);
|
|
42
|
-
setColor(color)}}
|
|
43
|
-
/>
|
|
44
|
-
</div>
|
|
45
|
-
);
|
|
46
|
-
};
|
|
@@ -1,107 +0,0 @@
|
|
|
1
|
-
import React, { useState } from 'react';
|
|
2
|
-
import { ChromePicker } from 'react-color';
|
|
3
|
-
import rgbHex from 'rgb-hex';
|
|
4
|
-
|
|
5
|
-
import { styled } from '../../theme';
|
|
6
|
-
import { Button } from '../Button';
|
|
7
|
-
import { CloseIcon } from '../Icon';
|
|
8
|
-
|
|
9
|
-
const Container = styled('div', {
|
|
10
|
-
position: 'relative',
|
|
11
|
-
});
|
|
12
|
-
|
|
13
|
-
const Color = styled('div', {
|
|
14
|
-
border: '1px solid $background',
|
|
15
|
-
borderRadius: '$xs',
|
|
16
|
-
width: '$32',
|
|
17
|
-
height: '$32',
|
|
18
|
-
});
|
|
19
|
-
const Cover = styled('div', {
|
|
20
|
-
position: 'fixed',
|
|
21
|
-
top: '0px',
|
|
22
|
-
right: '0px',
|
|
23
|
-
bottom: '0px',
|
|
24
|
-
left: '0px',
|
|
25
|
-
});
|
|
26
|
-
const Popover = styled('div', {
|
|
27
|
-
position: 'absolute',
|
|
28
|
-
zIndex: '2',
|
|
29
|
-
variants: {
|
|
30
|
-
place: {
|
|
31
|
-
top: {
|
|
32
|
-
top: '-241px',
|
|
33
|
-
},
|
|
34
|
-
bottom: {},
|
|
35
|
-
left: {
|
|
36
|
-
top: '-50%',
|
|
37
|
-
left: '-225px',
|
|
38
|
-
},
|
|
39
|
-
right: {
|
|
40
|
-
top: '-50%',
|
|
41
|
-
right: '-225px',
|
|
42
|
-
},
|
|
43
|
-
},
|
|
44
|
-
},
|
|
45
|
-
});
|
|
46
|
-
export interface PropTypes {
|
|
47
|
-
color?: string;
|
|
48
|
-
place: 'top' | 'bottom' | 'left' | 'right';
|
|
49
|
-
onChangeColor: (color?: string) => void;
|
|
50
|
-
label?: string;
|
|
51
|
-
placeholder?: string;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
const Label = styled('label', {
|
|
55
|
-
display: 'inline-block',
|
|
56
|
-
fontSize: '$14',
|
|
57
|
-
marginBottom: '$4',
|
|
58
|
-
color: '$foreground',
|
|
59
|
-
});
|
|
60
|
-
|
|
61
|
-
export function ColorPicker({
|
|
62
|
-
color,
|
|
63
|
-
onChangeColor,
|
|
64
|
-
label,
|
|
65
|
-
place,
|
|
66
|
-
placeholder,
|
|
67
|
-
}: PropTypes) {
|
|
68
|
-
const [displayColorPicker, setDisplayColorPicker] = useState<boolean>(false);
|
|
69
|
-
|
|
70
|
-
return (
|
|
71
|
-
<Container>
|
|
72
|
-
<Label className="_text">{label}</Label>
|
|
73
|
-
<Button
|
|
74
|
-
variant="outlined"
|
|
75
|
-
prefix={<Color style={{ backgroundColor: color }} />}
|
|
76
|
-
fullWidth
|
|
77
|
-
size="large"
|
|
78
|
-
suffix={
|
|
79
|
-
color && (
|
|
80
|
-
<div
|
|
81
|
-
onClick={(e) => {
|
|
82
|
-
e.stopPropagation();
|
|
83
|
-
onChangeColor(undefined);
|
|
84
|
-
}}>
|
|
85
|
-
<CloseIcon size={20} />
|
|
86
|
-
</div>
|
|
87
|
-
)
|
|
88
|
-
}
|
|
89
|
-
onClick={() => setDisplayColorPicker((prev) => !prev)}>
|
|
90
|
-
{color || placeholder}
|
|
91
|
-
</Button>
|
|
92
|
-
|
|
93
|
-
{displayColorPicker && (
|
|
94
|
-
<Popover place={place}>
|
|
95
|
-
<Cover onClick={() => setDisplayColorPicker(false)} />
|
|
96
|
-
<ChromePicker
|
|
97
|
-
color={color}
|
|
98
|
-
onChange={(c) => {
|
|
99
|
-
const color = '#' + rgbHex(c.rgb.r, c.rgb.g, c.rgb.b, c.rgb.a);
|
|
100
|
-
onChangeColor(color);
|
|
101
|
-
}}
|
|
102
|
-
/>
|
|
103
|
-
</Popover>
|
|
104
|
-
)}
|
|
105
|
-
</Container>
|
|
106
|
-
);
|
|
107
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { ColorPicker } from './ColorPicker';
|