@rango-dev/ui 0.1.10-next.91 → 0.1.10-next.92
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/components/Alert/Alert.d.ts +3 -2
- package/dist/components/Button/Button.d.ts +3 -3
- package/dist/components/Icon/ChevronRightIcon.d.ts +3 -0
- package/dist/components/Icon/DisconnectIcon.d.ts +3 -0
- package/dist/components/Icon/index.d.ts +2 -0
- package/dist/components/Icon/types.d.ts +1 -1
- package/dist/components/Spacer/Spacer.d.ts +1 -1
- package/dist/components/TextField/TextField.stories.d.ts +1 -1
- package/dist/components/Typography/Typography.d.ts +3 -2
- package/dist/containers/ConfirmWallets/ConfirmWallets.d.ts +3 -5
- package/dist/ui.cjs.development.js +643 -445
- package/dist/ui.cjs.development.js.map +1 -1
- package/dist/ui.cjs.production.min.js +1 -1
- package/dist/ui.cjs.production.min.js.map +1 -1
- package/dist/ui.esm.js +644 -448
- package/dist/ui.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/Alert/Alert.tsx +40 -37
- package/src/components/BestRoute/BestRoute.tsx +28 -19
- package/src/components/BlockchainSelector/BlockchainSelector.tsx +1 -3
- package/src/components/Button/Button.stories.tsx +1 -1
- package/src/components/Button/Button.tsx +35 -23
- package/src/components/Chip/Chip.tsx +7 -4
- package/src/components/Icon/ChevronRightIcon.tsx +29 -0
- package/src/components/Icon/DisconnectIcon.tsx +31 -0
- package/src/components/Icon/HistoryIcon.tsx +12 -18
- package/src/components/Icon/RetryIcon.tsx +13 -13
- package/src/components/Icon/SettingIcon.tsx +6 -14
- package/src/components/Icon/index.ts +2 -0
- package/src/components/Icon/types.tsx +1 -1
- package/src/components/LiquiditySourceList/LiquiditySourceList.tsx +34 -10
- package/src/components/LiquiditySourcesSelector/LiquiditySourcesSelector.tsx +1 -1
- package/src/components/Radio/Radio.tsx +5 -4
- package/src/components/SelectableWalletList/SelectableWalletList.tsx +0 -1
- package/src/components/Settings/Settings.tsx +22 -6
- package/src/components/Spacer/Spacer.tsx +31 -1
- package/src/components/StepDetail/StepDetail.tsx +18 -7
- package/src/components/SwapContainer/SwapContainer.tsx +1 -1
- package/src/components/Switch/Switch.tsx +7 -5
- package/src/components/TextField/TextField.tsx +2 -1
- package/src/components/Typography/Typography.stories.tsx +4 -0
- package/src/components/Typography/Typography.tsx +20 -9
- package/src/components/Wallet/State.tsx +2 -3
- package/src/components/Wallet/Wallet.tsx +32 -5
- package/src/containers/ConfirmSwap/ConfirmSwap.tsx +0 -2
- package/src/containers/ConfirmWallets/ConfirmWallets.tsx +76 -51
- package/src/theme.ts +4 -2
|
@@ -6,6 +6,7 @@ function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'defau
|
|
|
6
6
|
|
|
7
7
|
var React = require('react');
|
|
8
8
|
var React__default = _interopDefault(React);
|
|
9
|
+
var RadixTooltip = require('@radix-ui/react-tooltip');
|
|
9
10
|
var RadixCheckbox = require('@radix-ui/react-checkbox');
|
|
10
11
|
var reactDom = require('react-dom');
|
|
11
12
|
var walletsShared = require('@rango-dev/wallets-shared');
|
|
@@ -14,7 +15,6 @@ var RadioGroup = require('@radix-ui/react-radio-group');
|
|
|
14
15
|
var reactWindow = require('react-window');
|
|
15
16
|
var InfiniteLoader = _interopDefault(require('react-window-infinite-loader'));
|
|
16
17
|
var AutoSizer = _interopDefault(require('react-virtualized-auto-sizer'));
|
|
17
|
-
var RadixTooltip = require('@radix-ui/react-tooltip');
|
|
18
18
|
var reactColor = require('react-color');
|
|
19
19
|
|
|
20
20
|
function _extends() {
|
|
@@ -85,7 +85,9 @@ var theme = {
|
|
|
85
85
|
error100: '#F7D4D6',
|
|
86
86
|
error300: '#FF3333',
|
|
87
87
|
error500: '#FF0000',
|
|
88
|
-
error700: '#E60000'
|
|
88
|
+
error700: '#E60000',
|
|
89
|
+
// Only use this color when you are going to use white for both dark and light theme.
|
|
90
|
+
white: '#fff'
|
|
89
91
|
},
|
|
90
92
|
space: {
|
|
91
93
|
2: '2px',
|
|
@@ -140,8 +142,8 @@ var theme = {
|
|
|
140
142
|
borderWidths: {},
|
|
141
143
|
borderStyles: {},
|
|
142
144
|
radii: {
|
|
143
|
-
5: '
|
|
144
|
-
10: '
|
|
145
|
+
5: '8px',
|
|
146
|
+
10: '12px'
|
|
145
147
|
},
|
|
146
148
|
shadows: {
|
|
147
149
|
s: '0px 3px 5px 3px #f0f2f5, 0px 6px 10px 3px #f0f2f5, 0px 1px 18px 3px #f0f2f5'
|
|
@@ -536,26 +538,34 @@ var HistoryIcon = function HistoryIcon(_ref) {
|
|
|
536
538
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
537
539
|
color = _ref.color,
|
|
538
540
|
props = _objectWithoutPropertiesLoose(_ref, _excluded$a);
|
|
539
|
-
return React.createElement(
|
|
541
|
+
return React.createElement(SvgWithStrokeColor, Object.assign({
|
|
540
542
|
width: size,
|
|
541
543
|
height: size,
|
|
542
544
|
viewBox: "0 0 24 24",
|
|
543
545
|
color: color,
|
|
544
546
|
fill: "none",
|
|
547
|
+
stroke: "currentColor",
|
|
548
|
+
"stroke-width": "2",
|
|
549
|
+
"stroke-linecap": "round",
|
|
550
|
+
"stroke-linejoin": "round",
|
|
545
551
|
xmlns: "http://www.w3.org/2000/svg",
|
|
546
552
|
className: "_icon"
|
|
547
553
|
}, props), React.createElement("path", {
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
}), React.createElement("
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
554
|
+
d: "M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"
|
|
555
|
+
}), React.createElement("polyline", {
|
|
556
|
+
points: "14 2 14 8 20 8"
|
|
557
|
+
}), React.createElement("line", {
|
|
558
|
+
x1: "16",
|
|
559
|
+
y1: "13",
|
|
560
|
+
x2: "8",
|
|
561
|
+
y2: "13"
|
|
562
|
+
}), React.createElement("line", {
|
|
563
|
+
x1: "16",
|
|
564
|
+
y1: "17",
|
|
565
|
+
x2: "8",
|
|
566
|
+
y2: "17"
|
|
567
|
+
}), React.createElement("polyline", {
|
|
568
|
+
points: "10 9 9 9 8 9"
|
|
559
569
|
}));
|
|
560
570
|
};
|
|
561
571
|
HistoryIcon.toString = function () {
|
|
@@ -603,21 +613,19 @@ var SettingsIcon = function SettingsIcon(_ref) {
|
|
|
603
613
|
height: size,
|
|
604
614
|
viewBox: "0 0 24 24",
|
|
605
615
|
color: color,
|
|
616
|
+
stroke: "currentColor",
|
|
617
|
+
"stroke-width": "2",
|
|
618
|
+
"stroke-linecap": "round",
|
|
619
|
+
"stroke-linejoin": "round",
|
|
606
620
|
fill: "none",
|
|
607
621
|
xmlns: "http://www.w3.org/2000/svg",
|
|
608
622
|
className: "_icon"
|
|
609
|
-
}, props), React.createElement("
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
strokeLinecap: "round",
|
|
614
|
-
strokeLinejoin: "round"
|
|
623
|
+
}, props), React.createElement("circle", {
|
|
624
|
+
cx: "12",
|
|
625
|
+
cy: "12",
|
|
626
|
+
r: "3"
|
|
615
627
|
}), React.createElement("path", {
|
|
616
|
-
d: "
|
|
617
|
-
strokeWidth: 1.5,
|
|
618
|
-
strokeMiterlimit: 10,
|
|
619
|
-
strokeLinecap: "round",
|
|
620
|
-
strokeLinejoin: "round"
|
|
628
|
+
d: "M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 0 1 0 2.83 2 2 0 0 1-2.83 0l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 0 1-2 2 2 2 0 0 1-2-2v-.09A1.65 1.65 0 0 0 9 19.4a1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 0 1-2.83 0 2 2 0 0 1 0-2.83l.06-.06a1.65 1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 0 1-2-2 2 2 0 0 1 2-2h.09A1.65 1.65 0 0 0 4.6 9a1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 0 1 0-2.83 2 2 0 0 1 2.83 0l.06.06a1.65 1.65 0 0 0 1.82.33H9a1.65 1.65 0 0 0 1-1.51V3a2 2 0 0 1 2-2 2 2 0 0 1 2 2v.09a1.65 1.65 0 0 0 1 1.51 1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 0 1 2.83 0 2 2 0 0 1 0 2.83l-.06.06a1.65 1.65 0 0 0-.33 1.82V9a1.65 1.65 0 0 0 1.51 1H21a2 2 0 0 1 2 2 2 2 0 0 1-2 2h-.09a1.65 1.65 0 0 0-1.51 1z"
|
|
621
629
|
}));
|
|
622
630
|
};
|
|
623
631
|
SettingsIcon.toString = function () {
|
|
@@ -833,12 +841,41 @@ DownloadIcon.toString = function () {
|
|
|
833
841
|
return '._icon';
|
|
834
842
|
};
|
|
835
843
|
|
|
836
|
-
var _excluded$l = ["
|
|
844
|
+
var _excluded$l = ["color", "size"];
|
|
845
|
+
var ChevronRightIcon = /*#__PURE__*/React.forwardRef(function (_ref, forwardedRef) {
|
|
846
|
+
var _ref$color = _ref.color,
|
|
847
|
+
color = _ref$color === void 0 ? 'black' : _ref$color,
|
|
848
|
+
_ref$size = _ref.size,
|
|
849
|
+
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
850
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$l);
|
|
851
|
+
return React.createElement(SvgWithStrokeColor, Object.assign({
|
|
852
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
853
|
+
width: size,
|
|
854
|
+
height: size,
|
|
855
|
+
color: color,
|
|
856
|
+
viewBox: "0 0 24 24",
|
|
857
|
+
fill: "none",
|
|
858
|
+
stroke: "currentColor",
|
|
859
|
+
"stroke-width": "2",
|
|
860
|
+
"stroke-linecap": "round",
|
|
861
|
+
"stroke-linejoin": "round",
|
|
862
|
+
className: "_icon"
|
|
863
|
+
}, props, {
|
|
864
|
+
ref: forwardedRef
|
|
865
|
+
}), React.createElement("polyline", {
|
|
866
|
+
points: "9 18 15 12 9 6"
|
|
867
|
+
}));
|
|
868
|
+
});
|
|
869
|
+
ChevronRightIcon.toString = function () {
|
|
870
|
+
return '._icon';
|
|
871
|
+
};
|
|
872
|
+
|
|
873
|
+
var _excluded$m = ["size", "color"];
|
|
837
874
|
var RetryRightIcon = function RetryRightIcon(_ref) {
|
|
838
875
|
var _ref$size = _ref.size,
|
|
839
876
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
840
877
|
color = _ref.color,
|
|
841
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
878
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$m);
|
|
842
879
|
return React.createElement(SvgWithStrokeColor, Object.assign({
|
|
843
880
|
width: size,
|
|
844
881
|
height: size,
|
|
@@ -858,12 +895,12 @@ RetryRightIcon.toString = function () {
|
|
|
858
895
|
return '._icon';
|
|
859
896
|
};
|
|
860
897
|
|
|
861
|
-
var _excluded$
|
|
898
|
+
var _excluded$n = ["size", "color"];
|
|
862
899
|
var RetryLeftIcon = function RetryLeftIcon(_ref) {
|
|
863
900
|
var _ref$size = _ref.size,
|
|
864
901
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
865
902
|
color = _ref.color,
|
|
866
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
903
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$n);
|
|
867
904
|
return React.createElement(SvgWithStrokeColor, Object.assign({
|
|
868
905
|
width: size,
|
|
869
906
|
height: size,
|
|
@@ -883,12 +920,12 @@ RetryLeftIcon.toString = function () {
|
|
|
883
920
|
return '._icon';
|
|
884
921
|
};
|
|
885
922
|
|
|
886
|
-
var _excluded$
|
|
923
|
+
var _excluded$o = ["size", "color"];
|
|
887
924
|
var TryAgainIcon = function TryAgainIcon(_ref) {
|
|
888
925
|
var _ref$size = _ref.size,
|
|
889
926
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
890
927
|
color = _ref.color,
|
|
891
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
928
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$o);
|
|
892
929
|
return React.createElement(SvgWithStrokeColor, Object.assign({
|
|
893
930
|
width: size,
|
|
894
931
|
height: size,
|
|
@@ -908,12 +945,12 @@ TryAgainIcon.toString = function () {
|
|
|
908
945
|
return '._icon';
|
|
909
946
|
};
|
|
910
947
|
|
|
911
|
-
var _excluded$
|
|
948
|
+
var _excluded$p = ["size", "color"];
|
|
912
949
|
var VerticalSwapIcon = function VerticalSwapIcon(_ref) {
|
|
913
950
|
var _ref$size = _ref.size,
|
|
914
951
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
915
952
|
color = _ref.color,
|
|
916
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
953
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$p);
|
|
917
954
|
return React.createElement(SvgWithStrokeColor, Object.assign({
|
|
918
955
|
width: size,
|
|
919
956
|
height: size,
|
|
@@ -939,12 +976,12 @@ VerticalSwapIcon.toString = function () {
|
|
|
939
976
|
return '._icon';
|
|
940
977
|
};
|
|
941
978
|
|
|
942
|
-
var _excluded$
|
|
979
|
+
var _excluded$q = ["size", "color"];
|
|
943
980
|
var HorizontalSwapIcon = function HorizontalSwapIcon(_ref) {
|
|
944
981
|
var _ref$size = _ref.size,
|
|
945
982
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
946
983
|
color = _ref.color,
|
|
947
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
984
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$q);
|
|
948
985
|
return React.createElement(SvgWithStrokeColor, Object.assign({
|
|
949
986
|
width: size,
|
|
950
987
|
height: size,
|
|
@@ -970,39 +1007,43 @@ HorizontalSwapIcon.toString = function () {
|
|
|
970
1007
|
return '._icon';
|
|
971
1008
|
};
|
|
972
1009
|
|
|
973
|
-
var _excluded$
|
|
1010
|
+
var _excluded$r = ["color", "size"];
|
|
974
1011
|
var RetryIcon = /*#__PURE__*/React.forwardRef(function (_ref, forwardedRef) {
|
|
975
|
-
var color = _ref.color,
|
|
1012
|
+
var _ref$color = _ref.color,
|
|
1013
|
+
color = _ref$color === void 0 ? 'black' : _ref$color,
|
|
976
1014
|
_ref$size = _ref.size,
|
|
977
1015
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
978
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
979
|
-
return React.createElement(
|
|
1016
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$r);
|
|
1017
|
+
return React.createElement(SvgWithStrokeColor, Object.assign({
|
|
1018
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
980
1019
|
width: size,
|
|
981
1020
|
height: size,
|
|
982
|
-
fill: "none",
|
|
983
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
984
|
-
viewBox: "0 0 24 24",
|
|
985
1021
|
color: color,
|
|
1022
|
+
viewBox: "0 0 24 24",
|
|
1023
|
+
fill: "none",
|
|
1024
|
+
stroke: "currentColor",
|
|
1025
|
+
"stroke-width": "2",
|
|
1026
|
+
"stroke-linecap": "round",
|
|
1027
|
+
"stroke-linejoin": "round",
|
|
986
1028
|
className: "_icon"
|
|
987
1029
|
}, props, {
|
|
988
1030
|
ref: forwardedRef
|
|
1031
|
+
}), React.createElement("polyline", {
|
|
1032
|
+
points: "23 4 23 10 17 10"
|
|
989
1033
|
}), React.createElement("path", {
|
|
990
|
-
|
|
991
|
-
clipRule: "evenodd",
|
|
992
|
-
d: "M17.016 13.45c.199-.384.002-.842-.397-1.005-.406-.166-.864.033-1.077.416A6.17 6.17 0 0 1 13 15.345a6.051 6.051 0 0 1-4.244.513 6.127 6.127 0 0 1-3.543-2.425 6.286 6.286 0 0 1 .73-8.095A6.089 6.089 0 0 1 9.86 3.604a6.07 6.07 0 0 1 4.083 1.286 6.196 6.196 0 0 1 1.65 1.97l-1.053.363a.302.302 0 0 0-.073.534l2.607 1.758a.3.3 0 0 0 .45-.155l1.01-3.007a.298.298 0 0 0-.38-.378l-1.057.365a7.79 7.79 0 0 0-2.194-2.713 7.627 7.627 0 0 0-5.13-1.615A7.65 7.65 0 0 0 4.852 4.19a7.898 7.898 0 0 0-.917 10.17 7.7 7.7 0 0 0 4.452 3.048 7.604 7.604 0 0 0 5.333-.644 7.757 7.757 0 0 0 3.297-3.315Z",
|
|
993
|
-
fill: color
|
|
1034
|
+
d: "M20.49 15a9 9 0 1 1-2.12-9.36L23 10"
|
|
994
1035
|
}));
|
|
995
1036
|
});
|
|
996
1037
|
RetryIcon.toString = function () {
|
|
997
1038
|
return '._icon';
|
|
998
1039
|
};
|
|
999
1040
|
|
|
1000
|
-
var _excluded$
|
|
1041
|
+
var _excluded$s = ["size", "color"];
|
|
1001
1042
|
var WalletIcon = function WalletIcon(_ref) {
|
|
1002
1043
|
var _ref$size = _ref.size,
|
|
1003
1044
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
1004
1045
|
color = _ref.color,
|
|
1005
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
1046
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$s);
|
|
1006
1047
|
return React.createElement(SvgWithFillColor, Object.assign({
|
|
1007
1048
|
width: size,
|
|
1008
1049
|
height: size,
|
|
@@ -1029,12 +1070,12 @@ WalletIcon.toString = function () {
|
|
|
1029
1070
|
return '._icon';
|
|
1030
1071
|
};
|
|
1031
1072
|
|
|
1032
|
-
var _excluded$
|
|
1073
|
+
var _excluded$t = ["size", "color"];
|
|
1033
1074
|
var AddWalletIcon = function AddWalletIcon(_ref) {
|
|
1034
1075
|
var _ref$size = _ref.size,
|
|
1035
1076
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
1036
1077
|
color = _ref.color,
|
|
1037
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
1078
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$t);
|
|
1038
1079
|
return React.createElement(SvgWithFillColor, Object.assign({
|
|
1039
1080
|
width: size,
|
|
1040
1081
|
height: size,
|
|
@@ -1069,12 +1110,12 @@ AddWalletIcon.toString = function () {
|
|
|
1069
1110
|
return '._icon';
|
|
1070
1111
|
};
|
|
1071
1112
|
|
|
1072
|
-
var _excluded$
|
|
1113
|
+
var _excluded$u = ["size", "color"];
|
|
1073
1114
|
var DeleteWalletIcon = function DeleteWalletIcon(_ref) {
|
|
1074
1115
|
var _ref$size = _ref.size,
|
|
1075
1116
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
1076
1117
|
color = _ref.color,
|
|
1077
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
1118
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$u);
|
|
1078
1119
|
return React.createElement(SvgWithFillColor, Object.assign({
|
|
1079
1120
|
width: size,
|
|
1080
1121
|
height: size,
|
|
@@ -1109,12 +1150,12 @@ DeleteWalletIcon.toString = function () {
|
|
|
1109
1150
|
return '._icon';
|
|
1110
1151
|
};
|
|
1111
1152
|
|
|
1112
|
-
var _excluded$
|
|
1153
|
+
var _excluded$v = ["size", "color"];
|
|
1113
1154
|
var CheckWalletIcon = function CheckWalletIcon(_ref) {
|
|
1114
1155
|
var _ref$size = _ref.size,
|
|
1115
1156
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
1116
1157
|
color = _ref.color,
|
|
1117
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
1158
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$v);
|
|
1118
1159
|
return React.createElement(SvgWithFillColor, Object.assign({
|
|
1119
1160
|
width: size,
|
|
1120
1161
|
height: size,
|
|
@@ -1145,12 +1186,12 @@ CheckWalletIcon.toString = function () {
|
|
|
1145
1186
|
return '._icon';
|
|
1146
1187
|
};
|
|
1147
1188
|
|
|
1148
|
-
var _excluded$
|
|
1189
|
+
var _excluded$w = ["size", "color"];
|
|
1149
1190
|
var SwapWalletIcon = function SwapWalletIcon(_ref) {
|
|
1150
1191
|
var _ref$size = _ref.size,
|
|
1151
1192
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
1152
1193
|
color = _ref.color,
|
|
1153
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
1194
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$w);
|
|
1154
1195
|
return React.createElement(SvgWithFillColor, Object.assign({
|
|
1155
1196
|
width: size,
|
|
1156
1197
|
height: size,
|
|
@@ -1185,12 +1226,48 @@ SwapWalletIcon.toString = function () {
|
|
|
1185
1226
|
return '._icon';
|
|
1186
1227
|
};
|
|
1187
1228
|
|
|
1188
|
-
var _excluded$
|
|
1229
|
+
var _excluded$x = ["color", "size"];
|
|
1230
|
+
var DisconnectIcon = /*#__PURE__*/React.forwardRef(function (_ref, forwardedRef) {
|
|
1231
|
+
var _ref$color = _ref.color,
|
|
1232
|
+
color = _ref$color === void 0 ? 'black' : _ref$color,
|
|
1233
|
+
_ref$size = _ref.size,
|
|
1234
|
+
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
1235
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$x);
|
|
1236
|
+
return React.createElement(SvgWithStrokeColor, Object.assign({
|
|
1237
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
1238
|
+
width: size,
|
|
1239
|
+
height: size,
|
|
1240
|
+
color: color,
|
|
1241
|
+
viewBox: "0 0 24 24",
|
|
1242
|
+
fill: "none",
|
|
1243
|
+
stroke: "currentColor",
|
|
1244
|
+
"stroke-width": "2",
|
|
1245
|
+
"stroke-linecap": "round",
|
|
1246
|
+
"stroke-linejoin": "round",
|
|
1247
|
+
className: "_icon"
|
|
1248
|
+
}, props, {
|
|
1249
|
+
ref: forwardedRef
|
|
1250
|
+
}), React.createElement("path", {
|
|
1251
|
+
d: "M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4"
|
|
1252
|
+
}), React.createElement("polyline", {
|
|
1253
|
+
points: "16 17 21 12 16 7"
|
|
1254
|
+
}), React.createElement("line", {
|
|
1255
|
+
x1: "21",
|
|
1256
|
+
y1: "12",
|
|
1257
|
+
x2: "9",
|
|
1258
|
+
y2: "12"
|
|
1259
|
+
}));
|
|
1260
|
+
});
|
|
1261
|
+
DisconnectIcon.toString = function () {
|
|
1262
|
+
return '._icon';
|
|
1263
|
+
};
|
|
1264
|
+
|
|
1265
|
+
var _excluded$y = ["size", "color"];
|
|
1189
1266
|
var BagIcon = function BagIcon(_ref) {
|
|
1190
1267
|
var _ref$size = _ref.size,
|
|
1191
1268
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
1192
1269
|
color = _ref.color,
|
|
1193
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
1270
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$y);
|
|
1194
1271
|
return React.createElement(SvgWithStrokeColor, Object.assign({
|
|
1195
1272
|
width: size,
|
|
1196
1273
|
height: size,
|
|
@@ -1220,11 +1297,11 @@ BagIcon.toString = function () {
|
|
|
1220
1297
|
return '._icon';
|
|
1221
1298
|
};
|
|
1222
1299
|
|
|
1223
|
-
var _excluded$
|
|
1300
|
+
var _excluded$z = ["size"];
|
|
1224
1301
|
var TimeIcon = /*#__PURE__*/React.forwardRef(function (_ref, forwardedRef) {
|
|
1225
1302
|
var _ref$size = _ref.size,
|
|
1226
1303
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
1227
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
1304
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$z);
|
|
1228
1305
|
return React.createElement(SvgWithStrokeColor, Object.assign({
|
|
1229
1306
|
width: size,
|
|
1230
1307
|
height: size,
|
|
@@ -1257,12 +1334,12 @@ CloseIcon.toString = function () {
|
|
|
1257
1334
|
return '._icon';
|
|
1258
1335
|
};
|
|
1259
1336
|
|
|
1260
|
-
var _excluded$
|
|
1337
|
+
var _excluded$A = ["size", "color"];
|
|
1261
1338
|
var SignatureIcon = function SignatureIcon(_ref) {
|
|
1262
1339
|
var _ref$size = _ref.size,
|
|
1263
1340
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
1264
1341
|
color = _ref.color,
|
|
1265
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
1342
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$A);
|
|
1266
1343
|
return React.createElement(SvgWithFillColor, Object.assign({
|
|
1267
1344
|
width: size,
|
|
1268
1345
|
height: size,
|
|
@@ -1283,12 +1360,12 @@ SignatureIcon.toString = function () {
|
|
|
1283
1360
|
return '._icon';
|
|
1284
1361
|
};
|
|
1285
1362
|
|
|
1286
|
-
var _excluded$
|
|
1363
|
+
var _excluded$B = ["size", "color"];
|
|
1287
1364
|
var CopyIcon = function CopyIcon(_ref) {
|
|
1288
1365
|
var _ref$size = _ref.size,
|
|
1289
1366
|
size = _ref$size === void 0 ? 16 : _ref$size,
|
|
1290
1367
|
color = _ref.color,
|
|
1291
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
1368
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$B);
|
|
1292
1369
|
return React.createElement(SvgWithFillColor, Object.assign({
|
|
1293
1370
|
width: size,
|
|
1294
1371
|
height: size,
|
|
@@ -1314,10 +1391,9 @@ CopyIcon.toString = function () {
|
|
|
1314
1391
|
return '._icon';
|
|
1315
1392
|
};
|
|
1316
1393
|
|
|
1317
|
-
var _excluded$
|
|
1394
|
+
var _excluded$C = ["children", "className", "color"];
|
|
1318
1395
|
var TypographyContainer = /*#__PURE__*/styled('span', {
|
|
1319
1396
|
margin: 0,
|
|
1320
|
-
color: '$foreground',
|
|
1321
1397
|
display: 'inline-block',
|
|
1322
1398
|
variants: {
|
|
1323
1399
|
variant: {
|
|
@@ -1363,13 +1439,7 @@ var TypographyContainer = /*#__PURE__*/styled('span', {
|
|
|
1363
1439
|
},
|
|
1364
1440
|
h5: {
|
|
1365
1441
|
fontSize: '$16',
|
|
1366
|
-
fontWeight: '$600'
|
|
1367
|
-
'@md': {
|
|
1368
|
-
fontSize: '$18'
|
|
1369
|
-
},
|
|
1370
|
-
'@lg': {
|
|
1371
|
-
fontSize: '$20'
|
|
1372
|
-
}
|
|
1442
|
+
fontWeight: '$600'
|
|
1373
1443
|
},
|
|
1374
1444
|
h6: {
|
|
1375
1445
|
fontSize: '$14',
|
|
@@ -1398,6 +1468,10 @@ var TypographyContainer = /*#__PURE__*/styled('span', {
|
|
|
1398
1468
|
fontSize: '$16'
|
|
1399
1469
|
}
|
|
1400
1470
|
},
|
|
1471
|
+
body3: {
|
|
1472
|
+
fontSize: '$12',
|
|
1473
|
+
fontWeight: '$400'
|
|
1474
|
+
},
|
|
1401
1475
|
caption: {
|
|
1402
1476
|
fontSize: '$10',
|
|
1403
1477
|
fontWeight: '$400',
|
|
@@ -1483,9 +1557,16 @@ var TypographyContainer = /*#__PURE__*/styled('span', {
|
|
|
1483
1557
|
function Typography(_ref) {
|
|
1484
1558
|
var children = _ref.children,
|
|
1485
1559
|
className = _ref.className,
|
|
1486
|
-
|
|
1560
|
+
color = _ref.color,
|
|
1561
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$C);
|
|
1562
|
+
var customCss = color ? {
|
|
1563
|
+
color: color.startsWith('$') ? color : "$" + color
|
|
1564
|
+
} : {
|
|
1565
|
+
color: '$foreground'
|
|
1566
|
+
};
|
|
1487
1567
|
return React__default.createElement(TypographyContainer, Object.assign({
|
|
1488
|
-
className: "_typography _text " + className
|
|
1568
|
+
className: "_typography _text " + (className || ''),
|
|
1569
|
+
css: customCss
|
|
1489
1570
|
}, props), children);
|
|
1490
1571
|
}
|
|
1491
1572
|
Typography.toString = function () {
|
|
@@ -1510,12 +1591,20 @@ var Logo = /*#__PURE__*/styled('img', {
|
|
|
1510
1591
|
height: '$28',
|
|
1511
1592
|
borderRadius: '50%'
|
|
1512
1593
|
});
|
|
1513
|
-
var ChainLogo = /*#__PURE__*/styled('
|
|
1594
|
+
var ChainLogo = /*#__PURE__*/styled('div', {
|
|
1514
1595
|
position: 'absolute',
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1596
|
+
right: -4,
|
|
1597
|
+
bottom: -4,
|
|
1598
|
+
width: '$16',
|
|
1599
|
+
height: '$16',
|
|
1600
|
+
padding: '$2',
|
|
1601
|
+
borderRadius: '50%',
|
|
1602
|
+
backgroundColor: '$background',
|
|
1603
|
+
border: '1px solid $neutrals400',
|
|
1604
|
+
img: {
|
|
1605
|
+
width: '100%',
|
|
1606
|
+
display: 'block'
|
|
1607
|
+
}
|
|
1519
1608
|
});
|
|
1520
1609
|
var StepContainer = /*#__PURE__*/styled('div', {
|
|
1521
1610
|
display: 'flex',
|
|
@@ -1565,17 +1654,18 @@ function StepDetail(_ref) {
|
|
|
1565
1654
|
}, React__default.createElement(Logo, {
|
|
1566
1655
|
src: logo,
|
|
1567
1656
|
alt: symbol
|
|
1568
|
-
}), React__default.createElement(ChainLogo, {
|
|
1657
|
+
}), React__default.createElement(ChainLogo, null, React__default.createElement("img", {
|
|
1569
1658
|
src: chainLogo,
|
|
1570
1659
|
alt: blockchain
|
|
1571
|
-
})), React__default.createElement(Detail, {
|
|
1660
|
+
}))), React__default.createElement(Detail, {
|
|
1572
1661
|
pl: direction === 'horizontal'
|
|
1573
1662
|
}, React__default.createElement(Typography, {
|
|
1574
1663
|
noWrap: true,
|
|
1575
1664
|
variant: direction === 'vertical' ? 'body2' : 'h6'
|
|
1576
1665
|
}, amount ? parseFloat(amount).toFixed(2) : '?', " ", symbol), React__default.createElement(SubTitle, {
|
|
1577
1666
|
noWrap: true,
|
|
1578
|
-
variant: "caption"
|
|
1667
|
+
variant: "caption",
|
|
1668
|
+
color: "neutrals800"
|
|
1579
1669
|
}, "on ", blockchain)));
|
|
1580
1670
|
}
|
|
1581
1671
|
|
|
@@ -1704,6 +1794,99 @@ function Spinner(_ref) {
|
|
|
1704
1794
|
});
|
|
1705
1795
|
}
|
|
1706
1796
|
|
|
1797
|
+
var TooltipTrigger = /*#__PURE__*/styled(RadixTooltip.Trigger, {
|
|
1798
|
+
border: 0,
|
|
1799
|
+
padding: 0,
|
|
1800
|
+
backgroundColor: 'transparent'
|
|
1801
|
+
});
|
|
1802
|
+
var TooltipContent = /*#__PURE__*/styled(RadixTooltip.Content, {
|
|
1803
|
+
borderRadius: '$5',
|
|
1804
|
+
padding: '$4 $8',
|
|
1805
|
+
fontSize: '$14',
|
|
1806
|
+
animationDuration: '400ms',
|
|
1807
|
+
animationTimingFunction: 'cubic-bezier(0.16, 1, 0.3, 1)',
|
|
1808
|
+
willChange: 'transform, opacity',
|
|
1809
|
+
variants: {
|
|
1810
|
+
color: {
|
|
1811
|
+
primary: {
|
|
1812
|
+
backgroundColor: '$primary',
|
|
1813
|
+
color: '$white'
|
|
1814
|
+
},
|
|
1815
|
+
error: {
|
|
1816
|
+
backgroundColor: '$error',
|
|
1817
|
+
color: '$white'
|
|
1818
|
+
},
|
|
1819
|
+
warning: {
|
|
1820
|
+
backgroundColor: '$warning',
|
|
1821
|
+
color: '$white'
|
|
1822
|
+
},
|
|
1823
|
+
success: {
|
|
1824
|
+
backgroundColor: '$success',
|
|
1825
|
+
color: '$white'
|
|
1826
|
+
},
|
|
1827
|
+
gray: {
|
|
1828
|
+
backgroundColor: '$neutrals300',
|
|
1829
|
+
color: '$black'
|
|
1830
|
+
},
|
|
1831
|
+
black: {
|
|
1832
|
+
backgroundColor: '$black',
|
|
1833
|
+
color: '$white'
|
|
1834
|
+
},
|
|
1835
|
+
white: {
|
|
1836
|
+
backgroundColor: '$white',
|
|
1837
|
+
color: '$black'
|
|
1838
|
+
}
|
|
1839
|
+
}
|
|
1840
|
+
}
|
|
1841
|
+
});
|
|
1842
|
+
var TooltipArrow = /*#__PURE__*/styled(RadixTooltip.Arrow, {
|
|
1843
|
+
variants: {
|
|
1844
|
+
color: {
|
|
1845
|
+
primary: {
|
|
1846
|
+
fill: '$primary'
|
|
1847
|
+
},
|
|
1848
|
+
error: {
|
|
1849
|
+
fill: '$error'
|
|
1850
|
+
},
|
|
1851
|
+
warning: {
|
|
1852
|
+
fill: '$warning'
|
|
1853
|
+
},
|
|
1854
|
+
success: {
|
|
1855
|
+
fill: '$success'
|
|
1856
|
+
},
|
|
1857
|
+
gray: {
|
|
1858
|
+
fill: '$neutrals300'
|
|
1859
|
+
},
|
|
1860
|
+
black: {
|
|
1861
|
+
fill: '$black'
|
|
1862
|
+
},
|
|
1863
|
+
white: {
|
|
1864
|
+
fill: '$white'
|
|
1865
|
+
}
|
|
1866
|
+
}
|
|
1867
|
+
}
|
|
1868
|
+
});
|
|
1869
|
+
var ChildrenWrapper = /*#__PURE__*/styled('div', {
|
|
1870
|
+
display: 'inline-block'
|
|
1871
|
+
});
|
|
1872
|
+
function Tooltip(_ref) {
|
|
1873
|
+
var children = _ref.children,
|
|
1874
|
+
content = _ref.content,
|
|
1875
|
+
_ref$side = _ref.side,
|
|
1876
|
+
side = _ref$side === void 0 ? 'top' : _ref$side,
|
|
1877
|
+
_ref$color = _ref.color,
|
|
1878
|
+
color = _ref$color === void 0 ? 'gray' : _ref$color;
|
|
1879
|
+
return React__default.createElement(RadixTooltip.Provider, null, React__default.createElement(RadixTooltip.Root, null, React__default.createElement(TooltipTrigger, {
|
|
1880
|
+
asChild: true
|
|
1881
|
+
}, React__default.createElement(ChildrenWrapper, null, children)), React__default.createElement(RadixTooltip.Portal, null, React__default.createElement(TooltipContent, {
|
|
1882
|
+
color: color,
|
|
1883
|
+
side: side,
|
|
1884
|
+
sideOffset: 5
|
|
1885
|
+
}, content, React__default.createElement(TooltipArrow, {
|
|
1886
|
+
color: color
|
|
1887
|
+
})))));
|
|
1888
|
+
}
|
|
1889
|
+
|
|
1707
1890
|
var Container = /*#__PURE__*/styled('div', {
|
|
1708
1891
|
borderRadius: '$5',
|
|
1709
1892
|
border: '1px solid $neutrals300',
|
|
@@ -1738,7 +1921,7 @@ var Line = /*#__PURE__*/styled('div', {
|
|
|
1738
1921
|
});
|
|
1739
1922
|
var HR = /*#__PURE__*/styled('hr', {
|
|
1740
1923
|
width: '100%',
|
|
1741
|
-
|
|
1924
|
+
border: '1px solid $neutrals400',
|
|
1742
1925
|
margin: '$8 0'
|
|
1743
1926
|
});
|
|
1744
1927
|
var SwapperLogo = /*#__PURE__*/styled('img', {
|
|
@@ -1796,7 +1979,7 @@ var GasContainer = /*#__PURE__*/styled('div', {
|
|
|
1796
1979
|
margin: '$8'
|
|
1797
1980
|
}
|
|
1798
1981
|
});
|
|
1799
|
-
var
|
|
1982
|
+
var CostContainer = /*#__PURE__*/styled('div', {
|
|
1800
1983
|
display: 'flex',
|
|
1801
1984
|
flexDirection: 'column',
|
|
1802
1985
|
alignItems: 'center',
|
|
@@ -1839,7 +2022,9 @@ function BestRoute(props) {
|
|
|
1839
2022
|
return React__default.createElement(Container, null, loading ? React__default.createElement(SkeletonContainer$1, null, React__default.createElement(Skeleton, {
|
|
1840
2023
|
width: 48,
|
|
1841
2024
|
height: 94
|
|
1842
|
-
})) : React__default.createElement(GasContainer, null, React__default.createElement(
|
|
2025
|
+
})) : React__default.createElement(GasContainer, null, React__default.createElement(Tooltip, {
|
|
2026
|
+
content: "Transaction cost (fee)"
|
|
2027
|
+
}, React__default.createElement(CostContainer, {
|
|
1843
2028
|
warning: feeWarning
|
|
1844
2029
|
}, React__default.createElement(GasIcon, {
|
|
1845
2030
|
size: 20,
|
|
@@ -1849,13 +2034,17 @@ function BestRoute(props) {
|
|
|
1849
2034
|
align: "center",
|
|
1850
2035
|
variant: "caption",
|
|
1851
2036
|
warning: feeWarning
|
|
1852
|
-
}, error && '-', !!data && "$" + totalFee)), React__default.createElement(HR, null), React__default.createElement(
|
|
2037
|
+
}, error && '-', !!data && "$" + totalFee))), React__default.createElement(HR, null), React__default.createElement(Tooltip, {
|
|
2038
|
+
content: "Time estimate"
|
|
2039
|
+
}, React__default.createElement(CostContainer, {
|
|
2040
|
+
warning: feeWarning
|
|
2041
|
+
}, React__default.createElement(TimeIcon, {
|
|
1853
2042
|
size: 20
|
|
1854
2043
|
}), React__default.createElement(Typography, {
|
|
1855
2044
|
mt: 4,
|
|
1856
2045
|
align: "center",
|
|
1857
2046
|
variant: "caption"
|
|
1858
|
-
}, error && '-', !!data && "~" + totalTime + "m")), React__default.createElement(BestRouteContainer, null, loading && React__default.createElement(Spinner, {
|
|
2047
|
+
}, error && '-', !!data && "~" + totalTime + "m")))), React__default.createElement(BestRouteContainer, null, loading && React__default.createElement(Spinner, {
|
|
1859
2048
|
color: "primary"
|
|
1860
2049
|
}), error && React__default.createElement(ErrorMsg, {
|
|
1861
2050
|
variant: "caption"
|
|
@@ -1886,8 +2075,8 @@ function BestRoute(props) {
|
|
|
1886
2075
|
}, "No routes found")));
|
|
1887
2076
|
}
|
|
1888
2077
|
|
|
1889
|
-
var _excluded$
|
|
1890
|
-
var _ghost, _css, _css2, _css3
|
|
2078
|
+
var _excluded$D = ["children", "loading", "disabled", "prefix", "suffix", "align", "flexContent"];
|
|
2079
|
+
var _ghost, _css, _css2, _css3;
|
|
1891
2080
|
var ButtonContainer = /*#__PURE__*/styled('button', {
|
|
1892
2081
|
borderRadius: '$5',
|
|
1893
2082
|
fontSize: '$16',
|
|
@@ -1897,6 +2086,11 @@ var ButtonContainer = /*#__PURE__*/styled('button', {
|
|
|
1897
2086
|
display: 'flex',
|
|
1898
2087
|
alignItems: 'center',
|
|
1899
2088
|
justifyContent: 'center',
|
|
2089
|
+
transition: 'all 0.35s',
|
|
2090
|
+
border: '0',
|
|
2091
|
+
'&:active': {
|
|
2092
|
+
transform: 'scale(0.95)'
|
|
2093
|
+
},
|
|
1900
2094
|
variants: {
|
|
1901
2095
|
align: {
|
|
1902
2096
|
start: {
|
|
@@ -1909,6 +2103,7 @@ var ButtonContainer = /*#__PURE__*/styled('button', {
|
|
|
1909
2103
|
}
|
|
1910
2104
|
},
|
|
1911
2105
|
size: {
|
|
2106
|
+
compact: {},
|
|
1912
2107
|
small: {
|
|
1913
2108
|
height: '$32'
|
|
1914
2109
|
},
|
|
@@ -1925,28 +2120,29 @@ var ButtonContainer = /*#__PURE__*/styled('button', {
|
|
|
1925
2120
|
color: '$foreground',
|
|
1926
2121
|
border: 0,
|
|
1927
2122
|
'&:hover': {
|
|
1928
|
-
backgroundColor: '$neutrals200'
|
|
1929
|
-
color: '$foreground'
|
|
2123
|
+
backgroundColor: '$neutrals200'
|
|
1930
2124
|
},
|
|
1931
2125
|
'&:disabled': {
|
|
1932
|
-
background: '$neutrals400
|
|
2126
|
+
background: '$neutrals400'
|
|
2127
|
+
},
|
|
2128
|
+
'&:disabled:hover': {
|
|
2129
|
+
background: '$neutrals400',
|
|
2130
|
+
transform: 'unset'
|
|
1933
2131
|
}
|
|
1934
2132
|
},
|
|
1935
2133
|
outlined: {
|
|
1936
|
-
backgroundColor: '$background
|
|
1937
|
-
|
|
2134
|
+
backgroundColor: '$background',
|
|
2135
|
+
border: 1,
|
|
2136
|
+
borderStyle: 'solid',
|
|
2137
|
+
borderColor: '$neutrals400',
|
|
1938
2138
|
color: '$foreground',
|
|
1939
2139
|
'&:hover': {
|
|
1940
|
-
borderColor: '$neutrals600
|
|
1941
|
-
color: '$neutrals500 !important'
|
|
2140
|
+
borderColor: '$neutrals600'
|
|
1942
2141
|
},
|
|
1943
2142
|
'&:disabled': {
|
|
1944
|
-
borderColor: '$neutrals300
|
|
1945
|
-
color: '$neutrals400
|
|
1946
|
-
}
|
|
1947
|
-
background: 'transparent',
|
|
1948
|
-
border: 1,
|
|
1949
|
-
borderStyle: 'solid'
|
|
2143
|
+
borderColor: '$neutrals300',
|
|
2144
|
+
color: '$neutrals400'
|
|
2145
|
+
}
|
|
1950
2146
|
},
|
|
1951
2147
|
ghost: (_ghost = {
|
|
1952
2148
|
color: '$foreground',
|
|
@@ -1980,24 +2176,25 @@ var ButtonContainer = /*#__PURE__*/styled('button', {
|
|
|
1980
2176
|
compoundVariants: [{
|
|
1981
2177
|
type: 'primary',
|
|
1982
2178
|
variant: 'contained',
|
|
1983
|
-
css:
|
|
1984
|
-
background: '$primary',
|
|
1985
|
-
|
|
1986
|
-
|
|
1987
|
-
|
|
1988
|
-
|
|
1989
|
-
|
|
1990
|
-
|
|
1991
|
-
|
|
1992
|
-
|
|
1993
|
-
|
|
1994
|
-
|
|
1995
|
-
|
|
1996
|
-
|
|
1997
|
-
|
|
2179
|
+
css: {
|
|
2180
|
+
background: '$primary',
|
|
2181
|
+
color: '$white',
|
|
2182
|
+
'&:hover': {
|
|
2183
|
+
background: '$primary700'
|
|
2184
|
+
},
|
|
2185
|
+
'&:visited': {
|
|
2186
|
+
background: '$primary900'
|
|
2187
|
+
},
|
|
2188
|
+
'&:focus': {
|
|
2189
|
+
background: '$primary600'
|
|
2190
|
+
}
|
|
2191
|
+
}
|
|
2192
|
+
}, {
|
|
2193
|
+
type: 'primary',
|
|
2194
|
+
variant: 'outlined',
|
|
1998
2195
|
css: {
|
|
1999
2196
|
color: '$primary !important',
|
|
2000
|
-
borderColor: '$primary
|
|
2197
|
+
borderColor: '$primary',
|
|
2001
2198
|
'&:hover': {
|
|
2002
2199
|
color: '$primary700 !important',
|
|
2003
2200
|
borderColor: '$primary700 !important'
|
|
@@ -2029,24 +2226,24 @@ var ButtonContainer = /*#__PURE__*/styled('button', {
|
|
|
2029
2226
|
}, {
|
|
2030
2227
|
type: 'error',
|
|
2031
2228
|
variant: 'contained',
|
|
2032
|
-
css: (
|
|
2229
|
+
css: (_css = {
|
|
2033
2230
|
background: '$error',
|
|
2034
2231
|
$$color: '$colors$background'
|
|
2035
|
-
},
|
|
2232
|
+
}, _css["." + darkTheme + " &"] = {
|
|
2036
2233
|
$$color: '$colors$foreground'
|
|
2037
|
-
},
|
|
2234
|
+
}, _css.color = '$$color !important', _css['&:hover'] = {
|
|
2038
2235
|
background: '$error300'
|
|
2039
|
-
},
|
|
2236
|
+
}, _css['&:visited'] = {
|
|
2040
2237
|
background: '$error700'
|
|
2041
|
-
},
|
|
2238
|
+
}, _css['&:focus'] = {
|
|
2042
2239
|
background: '$error700'
|
|
2043
|
-
},
|
|
2240
|
+
}, _css)
|
|
2044
2241
|
}, {
|
|
2045
2242
|
type: 'error',
|
|
2046
2243
|
variant: 'outlined',
|
|
2047
2244
|
css: {
|
|
2048
2245
|
color: '$error !important',
|
|
2049
|
-
borderColor: '$error
|
|
2246
|
+
borderColor: '$error',
|
|
2050
2247
|
'&:hover': {
|
|
2051
2248
|
color: '$error300 !important',
|
|
2052
2249
|
borderColor: '$error300 !important'
|
|
@@ -2078,24 +2275,24 @@ var ButtonContainer = /*#__PURE__*/styled('button', {
|
|
|
2078
2275
|
}, {
|
|
2079
2276
|
type: 'warning',
|
|
2080
2277
|
variant: 'contained',
|
|
2081
|
-
css: (
|
|
2278
|
+
css: (_css2 = {
|
|
2082
2279
|
background: '$warning',
|
|
2083
2280
|
$$color: '$colors$background'
|
|
2084
|
-
},
|
|
2281
|
+
}, _css2["." + darkTheme + " &"] = {
|
|
2085
2282
|
$$color: '$colors$foreground'
|
|
2086
|
-
},
|
|
2283
|
+
}, _css2.color = '$$color !important', _css2['&:hover'] = {
|
|
2087
2284
|
background: '$warning300'
|
|
2088
|
-
},
|
|
2285
|
+
}, _css2['&:visited'] = {
|
|
2089
2286
|
background: '$warning700'
|
|
2090
|
-
},
|
|
2287
|
+
}, _css2['&:focus'] = {
|
|
2091
2288
|
background: '$warning700'
|
|
2092
|
-
},
|
|
2289
|
+
}, _css2)
|
|
2093
2290
|
}, {
|
|
2094
2291
|
type: 'warning',
|
|
2095
2292
|
variant: 'outlined',
|
|
2096
2293
|
css: {
|
|
2097
2294
|
color: '$warning !important',
|
|
2098
|
-
borderColor: '$warning
|
|
2295
|
+
borderColor: '$warning',
|
|
2099
2296
|
'&:hover': {
|
|
2100
2297
|
color: '$warning300 !important',
|
|
2101
2298
|
borderColor: '$warning300 !important'
|
|
@@ -2127,24 +2324,24 @@ var ButtonContainer = /*#__PURE__*/styled('button', {
|
|
|
2127
2324
|
}, {
|
|
2128
2325
|
type: 'success',
|
|
2129
2326
|
variant: 'contained',
|
|
2130
|
-
css: (
|
|
2327
|
+
css: (_css3 = {
|
|
2131
2328
|
background: '$success',
|
|
2132
2329
|
$$color: '$colors$background'
|
|
2133
|
-
},
|
|
2330
|
+
}, _css3["." + darkTheme + " &"] = {
|
|
2134
2331
|
$$color: '$colors$foreground'
|
|
2135
|
-
},
|
|
2332
|
+
}, _css3.color = '$$color !important', _css3['&:hover'] = {
|
|
2136
2333
|
background: '$success300'
|
|
2137
|
-
},
|
|
2334
|
+
}, _css3['&:visited'] = {
|
|
2138
2335
|
background: '$success700'
|
|
2139
|
-
},
|
|
2336
|
+
}, _css3['&:focus'] = {
|
|
2140
2337
|
background: '$success700'
|
|
2141
|
-
},
|
|
2338
|
+
}, _css3)
|
|
2142
2339
|
}, {
|
|
2143
2340
|
type: 'success',
|
|
2144
2341
|
variant: 'outlined',
|
|
2145
2342
|
css: {
|
|
2146
2343
|
color: '$success !important',
|
|
2147
|
-
borderColor: '$success
|
|
2344
|
+
borderColor: '$success',
|
|
2148
2345
|
'&:hover': {
|
|
2149
2346
|
color: '$success300 !important',
|
|
2150
2347
|
borderColor: '$success300 !important'
|
|
@@ -2173,6 +2370,12 @@ var ButtonContainer = /*#__PURE__*/styled('button', {
|
|
|
2173
2370
|
color: '$success700'
|
|
2174
2371
|
}
|
|
2175
2372
|
}
|
|
2373
|
+
}, {
|
|
2374
|
+
size: 'compact',
|
|
2375
|
+
css: {
|
|
2376
|
+
padding: '$2 $4',
|
|
2377
|
+
fontSize: '$12'
|
|
2378
|
+
}
|
|
2176
2379
|
}],
|
|
2177
2380
|
defaultVariants: {
|
|
2178
2381
|
size: 'medium',
|
|
@@ -2216,7 +2419,7 @@ function Button(_ref) {
|
|
|
2216
2419
|
suffix = _ref.suffix,
|
|
2217
2420
|
align = _ref.align,
|
|
2218
2421
|
flexContent = _ref.flexContent,
|
|
2219
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
2422
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$D);
|
|
2220
2423
|
var isDisabled = loading || disabled;
|
|
2221
2424
|
return React__default.createElement(ButtonContainer, Object.assign({
|
|
2222
2425
|
disabled: isDisabled
|
|
@@ -2292,7 +2495,7 @@ function BlockchainsList(props) {
|
|
|
2292
2495
|
}));
|
|
2293
2496
|
}
|
|
2294
2497
|
|
|
2295
|
-
var _excluded$
|
|
2498
|
+
var _excluded$E = ["label", "prefix", "suffix", "children", "size", "style"];
|
|
2296
2499
|
var InputContainer = /*#__PURE__*/styled('div', {
|
|
2297
2500
|
backgroundColor: '$background',
|
|
2298
2501
|
boxSizing: 'border-box',
|
|
@@ -2306,7 +2509,8 @@ var InputContainer = /*#__PURE__*/styled('div', {
|
|
|
2306
2509
|
color: '$foreground',
|
|
2307
2510
|
transition: 'border-color ease .3s',
|
|
2308
2511
|
'&:focus-within': {
|
|
2309
|
-
borderColor: '$
|
|
2512
|
+
borderColor: '$success',
|
|
2513
|
+
outline: '1px solid $success'
|
|
2310
2514
|
},
|
|
2311
2515
|
variants: {
|
|
2312
2516
|
size: {
|
|
@@ -2377,7 +2581,7 @@ var TextField = /*#__PURE__*/React__default.forwardRef(function (props, ref) {
|
|
|
2377
2581
|
suffix = props.suffix,
|
|
2378
2582
|
size = props.size,
|
|
2379
2583
|
style = props.style,
|
|
2380
|
-
inputAttributes = _objectWithoutPropertiesLoose(props, _excluded$
|
|
2584
|
+
inputAttributes = _objectWithoutPropertiesLoose(props, _excluded$E);
|
|
2381
2585
|
return React__default.createElement(React__default.Fragment, null, label && React__default.createElement(Label, Object.assign({
|
|
2382
2586
|
className: "_text"
|
|
2383
2587
|
}, inputAttributes.id && {
|
|
@@ -2457,61 +2661,182 @@ function SecondaryPage(props) {
|
|
|
2457
2661
|
})), React__default.createElement(ContentContainer, null, props.textField && (props.children == null ? void 0 : props.children(searchedFor)), !props.textField && props.children), Footer);
|
|
2458
2662
|
}
|
|
2459
2663
|
|
|
2664
|
+
var SpacerContainer = /*#__PURE__*/styled('div', {
|
|
2665
|
+
variants: {
|
|
2666
|
+
size: {
|
|
2667
|
+
4: {},
|
|
2668
|
+
8: {},
|
|
2669
|
+
12: {},
|
|
2670
|
+
16: {},
|
|
2671
|
+
18: {},
|
|
2672
|
+
20: {},
|
|
2673
|
+
24: {}
|
|
2674
|
+
},
|
|
2675
|
+
direction: {
|
|
2676
|
+
vertical: {},
|
|
2677
|
+
horizontal: {}
|
|
2678
|
+
}
|
|
2679
|
+
},
|
|
2680
|
+
compoundVariants: [{
|
|
2681
|
+
size: 4,
|
|
2682
|
+
direction: 'horizontal',
|
|
2683
|
+
css: {
|
|
2684
|
+
width: '$4'
|
|
2685
|
+
}
|
|
2686
|
+
}, {
|
|
2687
|
+
size: 4,
|
|
2688
|
+
direction: 'vertical',
|
|
2689
|
+
css: {
|
|
2690
|
+
height: '$4'
|
|
2691
|
+
}
|
|
2692
|
+
}, {
|
|
2693
|
+
size: 8,
|
|
2694
|
+
direction: 'horizontal',
|
|
2695
|
+
css: {
|
|
2696
|
+
width: '$8'
|
|
2697
|
+
}
|
|
2698
|
+
}, {
|
|
2699
|
+
size: 8,
|
|
2700
|
+
direction: 'vertical',
|
|
2701
|
+
css: {
|
|
2702
|
+
height: '$8'
|
|
2703
|
+
}
|
|
2704
|
+
}, {
|
|
2705
|
+
size: 12,
|
|
2706
|
+
direction: 'horizontal',
|
|
2707
|
+
css: {
|
|
2708
|
+
width: '$12'
|
|
2709
|
+
}
|
|
2710
|
+
}, {
|
|
2711
|
+
size: 12,
|
|
2712
|
+
direction: 'vertical',
|
|
2713
|
+
css: {
|
|
2714
|
+
height: '$12'
|
|
2715
|
+
}
|
|
2716
|
+
}, {
|
|
2717
|
+
size: 16,
|
|
2718
|
+
direction: 'horizontal',
|
|
2719
|
+
css: {
|
|
2720
|
+
width: '$16'
|
|
2721
|
+
}
|
|
2722
|
+
}, {
|
|
2723
|
+
size: 16,
|
|
2724
|
+
direction: 'vertical',
|
|
2725
|
+
css: {
|
|
2726
|
+
height: '$16'
|
|
2727
|
+
}
|
|
2728
|
+
}, {
|
|
2729
|
+
size: 18,
|
|
2730
|
+
direction: 'horizontal',
|
|
2731
|
+
css: {
|
|
2732
|
+
width: '$18'
|
|
2733
|
+
}
|
|
2734
|
+
}, {
|
|
2735
|
+
size: 18,
|
|
2736
|
+
direction: 'vertical',
|
|
2737
|
+
css: {
|
|
2738
|
+
height: '$18'
|
|
2739
|
+
}
|
|
2740
|
+
}, {
|
|
2741
|
+
size: 20,
|
|
2742
|
+
direction: 'horizontal',
|
|
2743
|
+
css: {
|
|
2744
|
+
width: '$20'
|
|
2745
|
+
}
|
|
2746
|
+
}, {
|
|
2747
|
+
size: 20,
|
|
2748
|
+
direction: 'vertical',
|
|
2749
|
+
css: {
|
|
2750
|
+
height: '$20'
|
|
2751
|
+
}
|
|
2752
|
+
}, {
|
|
2753
|
+
size: 24,
|
|
2754
|
+
direction: 'horizontal',
|
|
2755
|
+
css: {
|
|
2756
|
+
width: '$24'
|
|
2757
|
+
}
|
|
2758
|
+
}, {
|
|
2759
|
+
size: 24,
|
|
2760
|
+
direction: 'vertical',
|
|
2761
|
+
css: {
|
|
2762
|
+
height: '$24'
|
|
2763
|
+
}
|
|
2764
|
+
}]
|
|
2765
|
+
});
|
|
2766
|
+
function Spacer(_ref) {
|
|
2767
|
+
var _ref$size = _ref.size,
|
|
2768
|
+
size = _ref$size === void 0 ? 12 : _ref$size,
|
|
2769
|
+
_ref$direction = _ref.direction,
|
|
2770
|
+
direction = _ref$direction === void 0 ? 'horizontal' : _ref$direction;
|
|
2771
|
+
return React__default.createElement(SpacerContainer, {
|
|
2772
|
+
size: size,
|
|
2773
|
+
direction: direction
|
|
2774
|
+
});
|
|
2775
|
+
}
|
|
2776
|
+
|
|
2460
2777
|
var MainContainer = /*#__PURE__*/styled('div', {
|
|
2461
|
-
display: 'flex',
|
|
2462
2778
|
width: '100%',
|
|
2463
|
-
alignItems: 'center',
|
|
2464
2779
|
padding: '$16',
|
|
2465
2780
|
borderRadius: '$5',
|
|
2781
|
+
backgroundColor: '$neutrals300',
|
|
2782
|
+
color: '$neutrals800',
|
|
2783
|
+
'.main': {
|
|
2784
|
+
display: 'flex',
|
|
2785
|
+
alignItems: 'center'
|
|
2786
|
+
},
|
|
2787
|
+
'.footer': {
|
|
2788
|
+
paddingTop: '$8'
|
|
2789
|
+
},
|
|
2790
|
+
'&.hasIcon .footer': {
|
|
2791
|
+
paddingLeft: '$32'
|
|
2792
|
+
},
|
|
2466
2793
|
variants: {
|
|
2467
2794
|
type: {
|
|
2468
2795
|
primary: {
|
|
2469
|
-
|
|
2796
|
+
color: '$primary200'
|
|
2470
2797
|
},
|
|
2471
2798
|
secondary: {
|
|
2472
|
-
|
|
2799
|
+
color: '$secondary'
|
|
2473
2800
|
},
|
|
2474
2801
|
success: {
|
|
2475
|
-
|
|
2802
|
+
color: '$success300'
|
|
2476
2803
|
},
|
|
2477
2804
|
warning: {
|
|
2478
|
-
|
|
2805
|
+
color: '$warning500'
|
|
2479
2806
|
},
|
|
2480
2807
|
error: {
|
|
2481
|
-
|
|
2808
|
+
color: '$error300'
|
|
2482
2809
|
}
|
|
2483
2810
|
}
|
|
2484
2811
|
}
|
|
2485
2812
|
});
|
|
2486
|
-
var ContentContainer$1 = /*#__PURE__*/styled('div', {});
|
|
2487
|
-
var TitleContainer = /*#__PURE__*/styled('div', {
|
|
2488
|
-
marginBottom: '$8'
|
|
2489
|
-
});
|
|
2490
|
-
var IconContainer = /*#__PURE__*/styled('div', {
|
|
2491
|
-
marginRight: '$24'
|
|
2492
|
-
});
|
|
2493
|
-
var StyledTypography = /*#__PURE__*/styled(Typography, {
|
|
2494
|
-
color: darkTheme.colors.foreground.value
|
|
2495
|
-
});
|
|
2496
2813
|
function Alert(props) {
|
|
2497
2814
|
var type = props.type,
|
|
2498
2815
|
children = props.children,
|
|
2499
2816
|
title = props.title;
|
|
2500
2817
|
var showIcon = ['error', 'success', 'warning'].includes(type);
|
|
2501
2818
|
return React__default.createElement(MainContainer, {
|
|
2502
|
-
type: type
|
|
2503
|
-
|
|
2504
|
-
|
|
2505
|
-
|
|
2819
|
+
type: type,
|
|
2820
|
+
className: showIcon ? 'hasIcon' : ''
|
|
2821
|
+
}, React__default.createElement("div", {
|
|
2822
|
+
className: "main"
|
|
2823
|
+
}, showIcon && React__default.createElement(React__default.Fragment, null, type === 'success' && React__default.createElement(CheckCircleIcon, {
|
|
2824
|
+
color: type,
|
|
2825
|
+
size: 24
|
|
2506
2826
|
}), type === 'warning' && React__default.createElement(WarningIcon, {
|
|
2507
|
-
color:
|
|
2508
|
-
size:
|
|
2827
|
+
color: type,
|
|
2828
|
+
size: 24
|
|
2509
2829
|
}), type === 'error' && React__default.createElement(InfoCircleIcon, {
|
|
2510
|
-
color:
|
|
2511
|
-
size:
|
|
2512
|
-
})
|
|
2513
|
-
|
|
2514
|
-
}, title
|
|
2830
|
+
color: type,
|
|
2831
|
+
size: 24
|
|
2832
|
+
}), React__default.createElement(Spacer, {
|
|
2833
|
+
size: 8
|
|
2834
|
+
})), title && React__default.createElement(Typography, {
|
|
2835
|
+
variant: "h6",
|
|
2836
|
+
color: type
|
|
2837
|
+
}, title), children), props.footer ? React__default.createElement("div", {
|
|
2838
|
+
className: "footer"
|
|
2839
|
+
}, props.footer) : null);
|
|
2515
2840
|
}
|
|
2516
2841
|
|
|
2517
2842
|
var containsText = function containsText(text, searchText) {
|
|
@@ -2563,15 +2888,11 @@ function BlockchainSelector(props) {
|
|
|
2563
2888
|
multiSelect: multiSelect,
|
|
2564
2889
|
selectedList: selectedList,
|
|
2565
2890
|
onChange: onChange
|
|
2566
|
-
}) : React__default.createElement(Alert,
|
|
2567
|
-
type: "secondary"
|
|
2568
|
-
}, React__default.createElement(Typography, {
|
|
2569
|
-
variant: "body2"
|
|
2570
|
-
}, searchedFor + " not found"))));
|
|
2891
|
+
}) : React__default.createElement(Alert, null, searchedFor + " not found")));
|
|
2571
2892
|
});
|
|
2572
2893
|
}
|
|
2573
2894
|
|
|
2574
|
-
var _excluded$
|
|
2895
|
+
var _excluded$F = ["label", "id"];
|
|
2575
2896
|
var CheckboxContainer = /*#__PURE__*/styled('div', {
|
|
2576
2897
|
display: 'flex',
|
|
2577
2898
|
alignItems: 'center'
|
|
@@ -2596,7 +2917,7 @@ var Label$1 = /*#__PURE__*/styled('label', {
|
|
|
2596
2917
|
function Checkbox(_ref) {
|
|
2597
2918
|
var label = _ref.label,
|
|
2598
2919
|
id = _ref.id,
|
|
2599
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
2920
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$F);
|
|
2600
2921
|
return React__default.createElement(CheckboxContainer, null, React__default.createElement(CheckboxRoot, Object.assign({
|
|
2601
2922
|
id: id
|
|
2602
2923
|
}, props), React__default.createElement(RadixCheckbox.Indicator, null, React__default.createElement(CheckIcon, {
|
|
@@ -2616,13 +2937,17 @@ var ChipCointainer = /*#__PURE__*/styled('div', {
|
|
|
2616
2937
|
height: '32',
|
|
2617
2938
|
fontSize: '$14',
|
|
2618
2939
|
cursor: 'pointer',
|
|
2940
|
+
transition: 'all 0.35s',
|
|
2941
|
+
color: '$foreground',
|
|
2619
2942
|
'&:hover': {
|
|
2620
|
-
backgroundColor: '$
|
|
2943
|
+
backgroundColor: '$success700',
|
|
2944
|
+
color: '$background'
|
|
2621
2945
|
},
|
|
2622
2946
|
variants: {
|
|
2623
2947
|
selected: {
|
|
2624
2948
|
"true": {
|
|
2625
|
-
backgroundColor: '$
|
|
2949
|
+
backgroundColor: '$success',
|
|
2950
|
+
color: '$background'
|
|
2626
2951
|
},
|
|
2627
2952
|
"false": {
|
|
2628
2953
|
backgroundColor: '$background'
|
|
@@ -2641,9 +2966,7 @@ function Chip(props) {
|
|
|
2641
2966
|
selected: selected,
|
|
2642
2967
|
onClick: onClick,
|
|
2643
2968
|
style: style
|
|
2644
|
-
}, prefix || null,
|
|
2645
|
-
variant: "body2"
|
|
2646
|
-
}, label), suffix || null);
|
|
2969
|
+
}, prefix || null, label, suffix || null);
|
|
2647
2970
|
}
|
|
2648
2971
|
|
|
2649
2972
|
var BackDrop = /*#__PURE__*/styled('div', {
|
|
@@ -2677,7 +3000,7 @@ var ModalHeader = /*#__PURE__*/styled('div', {
|
|
|
2677
3000
|
position: 'relative',
|
|
2678
3001
|
marginBottom: '$16'
|
|
2679
3002
|
});
|
|
2680
|
-
var ContentContainer$
|
|
3003
|
+
var ContentContainer$1 = /*#__PURE__*/styled('div', {});
|
|
2681
3004
|
function Modal(props) {
|
|
2682
3005
|
var title = props.title,
|
|
2683
3006
|
content = props.content,
|
|
@@ -2701,7 +3024,7 @@ function Modal(props) {
|
|
|
2701
3024
|
}, title), React__default.createElement(Row, null, action, React__default.createElement(CloseIcon, {
|
|
2702
3025
|
size: 24,
|
|
2703
3026
|
onClick: onClose
|
|
2704
|
-
}))), React__default.createElement(ContentContainer$
|
|
3027
|
+
}))), React__default.createElement(ContentContainer$1, {
|
|
2705
3028
|
style: contentStyle
|
|
2706
3029
|
}, content))), document.body));
|
|
2707
3030
|
}
|
|
@@ -2727,7 +3050,7 @@ var State = function State(_ref) {
|
|
|
2727
3050
|
}, React__default.createElement(DownloadIcon, {
|
|
2728
3051
|
size: 24,
|
|
2729
3052
|
color: "success"
|
|
2730
|
-
})), walletState === exports.WalletState.CONNECTING && React__default.createElement(Spinner, null), walletState === exports.WalletState.CONNECTED && React__default.createElement(
|
|
3053
|
+
})), walletState === exports.WalletState.CONNECTING && React__default.createElement(Spinner, null), walletState === exports.WalletState.CONNECTED && React__default.createElement(DisconnectIcon, null)));
|
|
2731
3054
|
};
|
|
2732
3055
|
|
|
2733
3056
|
var WalletImage = /*#__PURE__*/styled('img', {
|
|
@@ -2735,6 +3058,23 @@ var WalletImage = /*#__PURE__*/styled('img', {
|
|
|
2735
3058
|
height: '$24',
|
|
2736
3059
|
marginRight: '$12'
|
|
2737
3060
|
});
|
|
3061
|
+
var Text = /*#__PURE__*/styled('div', {
|
|
3062
|
+
display: 'flex',
|
|
3063
|
+
flexDirection: 'column'
|
|
3064
|
+
});
|
|
3065
|
+
var ExtendedButton = /*#__PURE__*/styled(Button, {
|
|
3066
|
+
variants: {
|
|
3067
|
+
type: {
|
|
3068
|
+
primary: {
|
|
3069
|
+
outline: '1px solid $primary',
|
|
3070
|
+
borderColor: '$primary',
|
|
3071
|
+
'&:hover': {
|
|
3072
|
+
borderColor: '$primary'
|
|
3073
|
+
}
|
|
3074
|
+
}
|
|
3075
|
+
}
|
|
3076
|
+
}
|
|
3077
|
+
});
|
|
2738
3078
|
function Wallet(props) {
|
|
2739
3079
|
var name = props.name,
|
|
2740
3080
|
type = props.type,
|
|
@@ -2742,7 +3082,7 @@ function Wallet(props) {
|
|
|
2742
3082
|
state = props.state,
|
|
2743
3083
|
_onClick = props.onClick,
|
|
2744
3084
|
installLink = props.installLink;
|
|
2745
|
-
return React__default.createElement(
|
|
3085
|
+
return React__default.createElement(ExtendedButton, {
|
|
2746
3086
|
type: state === exports.WalletState.CONNECTED ? 'primary' : undefined,
|
|
2747
3087
|
disabled: !state,
|
|
2748
3088
|
onClick: function onClick() {
|
|
@@ -2760,10 +3100,14 @@ function Wallet(props) {
|
|
|
2760
3100
|
walletState: state,
|
|
2761
3101
|
installLink: installLink
|
|
2762
3102
|
})
|
|
2763
|
-
}, React__default.createElement(Typography, {
|
|
3103
|
+
}, React__default.createElement(Text, null, React__default.createElement(Typography, {
|
|
2764
3104
|
variant: "h5",
|
|
2765
3105
|
noWrap: false
|
|
2766
|
-
}, name)
|
|
3106
|
+
}, name), state === exports.WalletState.CONNECTED ? React__default.createElement(Typography, {
|
|
3107
|
+
variant: "caption",
|
|
3108
|
+
noWrap: false,
|
|
3109
|
+
color: "primary"
|
|
3110
|
+
}, "Connected") : null));
|
|
2767
3111
|
}
|
|
2768
3112
|
|
|
2769
3113
|
var ModalContent = /*#__PURE__*/styled('div', {
|
|
@@ -2795,107 +3139,21 @@ function ConnectWalletsModal(props) {
|
|
|
2795
3139
|
});
|
|
2796
3140
|
}
|
|
2797
3141
|
|
|
2798
|
-
var SpacerContainer = /*#__PURE__*/styled('div', {
|
|
2799
|
-
variants: {
|
|
2800
|
-
size: {
|
|
2801
|
-
12: {},
|
|
2802
|
-
16: {},
|
|
2803
|
-
18: {},
|
|
2804
|
-
20: {},
|
|
2805
|
-
24: {}
|
|
2806
|
-
},
|
|
2807
|
-
direction: {
|
|
2808
|
-
vertical: {},
|
|
2809
|
-
horizontal: {}
|
|
2810
|
-
}
|
|
2811
|
-
},
|
|
2812
|
-
compoundVariants: [{
|
|
2813
|
-
size: 12,
|
|
2814
|
-
direction: 'horizontal',
|
|
2815
|
-
css: {
|
|
2816
|
-
width: '$12'
|
|
2817
|
-
}
|
|
2818
|
-
}, {
|
|
2819
|
-
size: 12,
|
|
2820
|
-
direction: 'vertical',
|
|
2821
|
-
css: {
|
|
2822
|
-
height: '$12'
|
|
2823
|
-
}
|
|
2824
|
-
}, {
|
|
2825
|
-
size: 16,
|
|
2826
|
-
direction: 'horizontal',
|
|
2827
|
-
css: {
|
|
2828
|
-
width: '$16'
|
|
2829
|
-
}
|
|
2830
|
-
}, {
|
|
2831
|
-
size: 16,
|
|
2832
|
-
direction: 'vertical',
|
|
2833
|
-
css: {
|
|
2834
|
-
height: '$16'
|
|
2835
|
-
}
|
|
2836
|
-
}, {
|
|
2837
|
-
size: 18,
|
|
2838
|
-
direction: 'horizontal',
|
|
2839
|
-
css: {
|
|
2840
|
-
width: '$18'
|
|
2841
|
-
}
|
|
2842
|
-
}, {
|
|
2843
|
-
size: 18,
|
|
2844
|
-
direction: 'vertical',
|
|
2845
|
-
css: {
|
|
2846
|
-
height: '$18'
|
|
2847
|
-
}
|
|
2848
|
-
}, {
|
|
2849
|
-
size: 20,
|
|
2850
|
-
direction: 'horizontal',
|
|
2851
|
-
css: {
|
|
2852
|
-
width: '$20'
|
|
2853
|
-
}
|
|
2854
|
-
}, {
|
|
2855
|
-
size: 20,
|
|
2856
|
-
direction: 'vertical',
|
|
2857
|
-
css: {
|
|
2858
|
-
height: '$20'
|
|
2859
|
-
}
|
|
2860
|
-
}, {
|
|
2861
|
-
size: 24,
|
|
2862
|
-
direction: 'horizontal',
|
|
2863
|
-
css: {
|
|
2864
|
-
width: '$24'
|
|
2865
|
-
}
|
|
2866
|
-
}, {
|
|
2867
|
-
size: 24,
|
|
2868
|
-
direction: 'vertical',
|
|
2869
|
-
css: {
|
|
2870
|
-
height: '$24'
|
|
2871
|
-
}
|
|
2872
|
-
}]
|
|
2873
|
-
});
|
|
2874
|
-
function Spacer(_ref) {
|
|
2875
|
-
var _ref$size = _ref.size,
|
|
2876
|
-
size = _ref$size === void 0 ? 12 : _ref$size,
|
|
2877
|
-
_ref$direction = _ref.direction,
|
|
2878
|
-
direction = _ref$direction === void 0 ? 'horizontal' : _ref$direction;
|
|
2879
|
-
return React__default.createElement(SpacerContainer, {
|
|
2880
|
-
size: size,
|
|
2881
|
-
direction: direction
|
|
2882
|
-
});
|
|
2883
|
-
}
|
|
2884
|
-
|
|
2885
3142
|
var StyledSwitchRoot = /*#__PURE__*/styled(RadixSwitch.Root, {
|
|
2886
3143
|
boxSizing: 'border-box',
|
|
2887
3144
|
boxShadow: 'none',
|
|
2888
3145
|
borderStyle: 'solid',
|
|
2889
3146
|
width: '42px',
|
|
2890
3147
|
height: '22px',
|
|
2891
|
-
backgroundColor: '$
|
|
2892
|
-
borderColor: '$
|
|
3148
|
+
backgroundColor: '$neutrals600',
|
|
3149
|
+
borderColor: '$neutrals600',
|
|
2893
3150
|
borderRadius: '99999px',
|
|
2894
3151
|
position: 'relative',
|
|
2895
3152
|
padding: '0',
|
|
2896
3153
|
cursor: 'pointer',
|
|
2897
3154
|
'&[data-state="checked"]': {
|
|
2898
|
-
backgroundColor: '$
|
|
3155
|
+
backgroundColor: '$success',
|
|
3156
|
+
borderColor: '$success'
|
|
2899
3157
|
},
|
|
2900
3158
|
'-webkit-tap-highlight-color': 'rgba(0, 0, 0, 0)'
|
|
2901
3159
|
});
|
|
@@ -2906,13 +3164,12 @@ var StyledSwitchThumb = /*#__PURE__*/styled(RadixSwitch.Thumb, {
|
|
|
2906
3164
|
display: 'block',
|
|
2907
3165
|
width: '18px',
|
|
2908
3166
|
height: '18px',
|
|
2909
|
-
backgroundColor: '$
|
|
3167
|
+
backgroundColor: '$white',
|
|
2910
3168
|
transition: ' transform 300ms',
|
|
2911
3169
|
borderRadius: '999999px',
|
|
2912
3170
|
willChange: 'transform',
|
|
2913
3171
|
'&[data-state="checked"]': {
|
|
2914
|
-
transform: 'translateX(20px)'
|
|
2915
|
-
backgroundColor: '$primary'
|
|
3172
|
+
transform: 'translateX(20px)'
|
|
2916
3173
|
}
|
|
2917
3174
|
});
|
|
2918
3175
|
function Switch(props) {
|
|
@@ -2934,9 +3191,11 @@ var groupLiquiditySources = function groupLiquiditySources(liquiditySources) {
|
|
|
2934
3191
|
})
|
|
2935
3192
|
};
|
|
2936
3193
|
};
|
|
2937
|
-
var LiquiditySourceType = /*#__PURE__*/styled(
|
|
3194
|
+
var LiquiditySourceType = /*#__PURE__*/styled('div', {
|
|
2938
3195
|
position: 'sticky',
|
|
2939
|
-
display: '
|
|
3196
|
+
display: 'flex',
|
|
3197
|
+
justifyContent: 'space-between',
|
|
3198
|
+
alignItems: 'center',
|
|
2940
3199
|
top: '0',
|
|
2941
3200
|
marginTop: '$8',
|
|
2942
3201
|
marginBottom: '$8',
|
|
@@ -2979,28 +3238,42 @@ function LiquiditySourceList(props) {
|
|
|
2979
3238
|
return item.selected;
|
|
2980
3239
|
}));
|
|
2981
3240
|
}, [list]);
|
|
3241
|
+
var sections = groupLiquiditySources(list);
|
|
3242
|
+
var bridges = sections.bridge;
|
|
3243
|
+
var exchanges = sections.exchange;
|
|
3244
|
+
var totalBridges = bridges.length;
|
|
3245
|
+
var totalExchanges = exchanges.length;
|
|
3246
|
+
// TODO: This is not performant
|
|
3247
|
+
var totalSelectedBridges = bridges.filter(isSelected).length;
|
|
3248
|
+
var totalSelectedExchanges = exchanges.filter(isSelected).length;
|
|
2982
3249
|
return React__default.createElement("div", {
|
|
2983
3250
|
style: _extends({
|
|
2984
3251
|
height: '450px'
|
|
2985
3252
|
}, listContainerStyle)
|
|
2986
|
-
}, React__default.createElement("div", null, React__default.createElement(LiquiditySourceType, {
|
|
3253
|
+
}, React__default.createElement("div", null, React__default.createElement(LiquiditySourceType, null, React__default.createElement(Typography, {
|
|
2987
3254
|
variant: "h5"
|
|
2988
|
-
}, "Bridges"), React__default.createElement(
|
|
2989
|
-
|
|
3255
|
+
}, "Bridges"), React__default.createElement(Typography, {
|
|
3256
|
+
variant: "body1",
|
|
3257
|
+
color: "neutrals800"
|
|
3258
|
+
}, totalSelectedBridges === totalBridges ? totalBridges : totalSelectedBridges + " / " + totalBridges)), React__default.createElement(Spacer, {
|
|
3259
|
+
size: 12,
|
|
2990
3260
|
direction: "vertical"
|
|
2991
|
-
}),
|
|
3261
|
+
}), bridges.map(function (liquiditySource, index) {
|
|
2992
3262
|
return React__default.createElement(LiquiditySourceItem, {
|
|
2993
3263
|
liquiditySource: liquiditySource,
|
|
2994
3264
|
key: index,
|
|
2995
3265
|
selected: isSelected(liquiditySource),
|
|
2996
3266
|
onChange: changeLiquiditySources
|
|
2997
3267
|
});
|
|
2998
|
-
})), React__default.createElement("div", null, React__default.createElement(LiquiditySourceType, {
|
|
3268
|
+
})), React__default.createElement("div", null, React__default.createElement(LiquiditySourceType, null, React__default.createElement(Typography, {
|
|
2999
3269
|
variant: "h5"
|
|
3000
|
-
}, "Exchanges"), React__default.createElement(
|
|
3001
|
-
|
|
3270
|
+
}, "Exchanges"), React__default.createElement(Typography, {
|
|
3271
|
+
variant: "body1",
|
|
3272
|
+
color: "neutrals800"
|
|
3273
|
+
}, totalSelectedExchanges === totalExchanges ? totalExchanges : totalSelectedExchanges + " / " + totalExchanges)), React__default.createElement(Spacer, {
|
|
3274
|
+
size: 12,
|
|
3002
3275
|
direction: "vertical"
|
|
3003
|
-
}),
|
|
3276
|
+
}), exchanges.map(function (liquiditySource, index) {
|
|
3004
3277
|
return React__default.createElement(LiquiditySourceItem, {
|
|
3005
3278
|
liquiditySource: liquiditySource,
|
|
3006
3279
|
key: index,
|
|
@@ -3026,7 +3299,6 @@ var LiquiditySourceItem = function LiquiditySourceItem(_ref) {
|
|
|
3026
3299
|
style: {
|
|
3027
3300
|
marginBottom: '12px'
|
|
3028
3301
|
},
|
|
3029
|
-
type: selected ? 'primary' : undefined,
|
|
3030
3302
|
onClick: onChange.bind(null, liquiditySource)
|
|
3031
3303
|
}, React__default.createElement(Typography, {
|
|
3032
3304
|
variant: "body1"
|
|
@@ -3059,7 +3331,7 @@ function LiquiditySourcesSelector(props) {
|
|
|
3059
3331
|
onClick: toggleAll
|
|
3060
3332
|
}, list.find(function (item) {
|
|
3061
3333
|
return item.selected;
|
|
3062
|
-
}) ? '
|
|
3334
|
+
}) ? 'Deselect all' : 'Select all'),
|
|
3063
3335
|
hasHeader: hasHeader,
|
|
3064
3336
|
onBack: onBack
|
|
3065
3337
|
}, function (searchedFor) {
|
|
@@ -3073,8 +3345,7 @@ function LiquiditySourcesSelector(props) {
|
|
|
3073
3345
|
|
|
3074
3346
|
var Row$1 = /*#__PURE__*/styled('div', {
|
|
3075
3347
|
display: 'flex',
|
|
3076
|
-
flexWrap: 'wrap'
|
|
3077
|
-
justifyContent: 'center'
|
|
3348
|
+
flexWrap: 'wrap'
|
|
3078
3349
|
});
|
|
3079
3350
|
var Circle = /*#__PURE__*/styled('div', {
|
|
3080
3351
|
width: 12,
|
|
@@ -3199,14 +3470,14 @@ var ItemContainer = /*#__PURE__*/styled('div', {
|
|
|
3199
3470
|
});
|
|
3200
3471
|
var StyledItem = /*#__PURE__*/styled(RadioGroup.Item, {
|
|
3201
3472
|
padding: '0',
|
|
3202
|
-
backgroundColor: '$neutrals300',
|
|
3203
3473
|
width: '20px',
|
|
3204
3474
|
height: '20px',
|
|
3205
3475
|
borderRadius: '100%',
|
|
3206
|
-
border: 'none',
|
|
3207
3476
|
cursor: 'pointer',
|
|
3477
|
+
backgroundColor: '$background',
|
|
3478
|
+
border: '1px solid $neutrals400',
|
|
3208
3479
|
'&:hover': {
|
|
3209
|
-
|
|
3480
|
+
borderColor: '$neutrals600'
|
|
3210
3481
|
}
|
|
3211
3482
|
});
|
|
3212
3483
|
var Container$3 = /*#__PURE__*/styled('div', {
|
|
@@ -3225,7 +3496,7 @@ var StyledIndicator = /*#__PURE__*/styled(RadioGroup.Indicator, {
|
|
|
3225
3496
|
width: '10px',
|
|
3226
3497
|
height: '10px',
|
|
3227
3498
|
borderRadius: '50%',
|
|
3228
|
-
backgroundColor: '$
|
|
3499
|
+
backgroundColor: '$success'
|
|
3229
3500
|
}
|
|
3230
3501
|
});
|
|
3231
3502
|
var Label$2 = /*#__PURE__*/styled('label', {
|
|
@@ -3261,7 +3532,7 @@ function Radio(props) {
|
|
|
3261
3532
|
|
|
3262
3533
|
var BaseContainer = /*#__PURE__*/styled('div', {
|
|
3263
3534
|
borderRadius: '$5',
|
|
3264
|
-
backgroundColor: '$
|
|
3535
|
+
backgroundColor: '$neutrals300',
|
|
3265
3536
|
padding: '$16'
|
|
3266
3537
|
});
|
|
3267
3538
|
var Title = /*#__PURE__*/styled(Typography, {
|
|
@@ -3294,6 +3565,12 @@ var LiquiditySourceNumber = /*#__PURE__*/styled('div', {
|
|
|
3294
3565
|
var ThemesContainer = /*#__PURE__*/styled(BaseContainer, {
|
|
3295
3566
|
marginTop: '$32'
|
|
3296
3567
|
});
|
|
3568
|
+
var Head = /*#__PURE__*/styled('div', {
|
|
3569
|
+
display: 'flex',
|
|
3570
|
+
justifyContent: 'space-between',
|
|
3571
|
+
alignItems: 'center',
|
|
3572
|
+
paddingBottom: '$16'
|
|
3573
|
+
});
|
|
3297
3574
|
function Settings(props) {
|
|
3298
3575
|
var slippages = props.slippages,
|
|
3299
3576
|
selectedLiquiditySources = props.selectedLiquiditySources,
|
|
@@ -3316,9 +3593,12 @@ function Settings(props) {
|
|
|
3316
3593
|
setSelectedSlippage(slippage);
|
|
3317
3594
|
onSlippageChange(slippage);
|
|
3318
3595
|
};
|
|
3319
|
-
var PageContent = React__default.createElement(React__default.Fragment, null, React__default.createElement(BaseContainer, null, React__default.createElement(
|
|
3596
|
+
var PageContent = React__default.createElement(React__default.Fragment, null, React__default.createElement(BaseContainer, null, React__default.createElement(Head, null, React__default.createElement(Typography, {
|
|
3320
3597
|
variant: "body1"
|
|
3321
|
-
}, "Slippage tolerance per swap"), React__default.createElement(
|
|
3598
|
+
}, "Slippage tolerance per swap"), customSlippage ? React__default.createElement(Typography, {
|
|
3599
|
+
variant: "caption",
|
|
3600
|
+
color: "error"
|
|
3601
|
+
}, customSlippage, "% Custom") : undefined), React__default.createElement(SlippageChipsContainer, null, slippages.map(function (slippage, index) {
|
|
3322
3602
|
return React__default.createElement(Chip, {
|
|
3323
3603
|
key: index,
|
|
3324
3604
|
onClick: function onClick() {
|
|
@@ -3326,7 +3606,7 @@ function Settings(props) {
|
|
|
3326
3606
|
changeSlippage(slippage);
|
|
3327
3607
|
},
|
|
3328
3608
|
selected: !customSlippage && slippage === selectedSlippage,
|
|
3329
|
-
label: slippage.toString() + "
|
|
3609
|
+
label: slippage.toString() + "%",
|
|
3330
3610
|
style: {
|
|
3331
3611
|
marginRight: '8px'
|
|
3332
3612
|
}
|
|
@@ -3342,11 +3622,10 @@ function Settings(props) {
|
|
|
3342
3622
|
variant: "body2"
|
|
3343
3623
|
}, "%"),
|
|
3344
3624
|
size: "small",
|
|
3345
|
-
placeholder: "Custom",
|
|
3625
|
+
placeholder: "Custom %",
|
|
3346
3626
|
style: {
|
|
3347
3627
|
width: '128px',
|
|
3348
|
-
flexGrow: 'initial'
|
|
3349
|
-
borderColor: customSlippage ? '$success' : 'initial'
|
|
3628
|
+
flexGrow: 'initial'
|
|
3350
3629
|
}
|
|
3351
3630
|
}))), React__default.createElement(ThemesContainer, null, React__default.createElement(Title, {
|
|
3352
3631
|
variant: "body2"
|
|
@@ -3379,8 +3658,9 @@ function Settings(props) {
|
|
|
3379
3658
|
}, React__default.createElement(Typography, {
|
|
3380
3659
|
variant: "body1"
|
|
3381
3660
|
}, "Liquidity Sources"), React__default.createElement(LiquiditySourceNumber, null, React__default.createElement(Typography, {
|
|
3382
|
-
variant: "body2"
|
|
3383
|
-
|
|
3661
|
+
variant: "body2",
|
|
3662
|
+
color: "neutrals800"
|
|
3663
|
+
}, liquiditySources.length !== selectedLiquiditySources.length ? selectedLiquiditySources.length + " / " + liquiditySources.length : liquiditySources.length), React__default.createElement(StyledAngleRight, null))));
|
|
3384
3664
|
return React__default.createElement(SecondaryPage, {
|
|
3385
3665
|
title: "Settings",
|
|
3386
3666
|
textField: false,
|
|
@@ -3399,11 +3679,11 @@ var MainContainer$1 = /*#__PURE__*/styled('div', {
|
|
|
3399
3679
|
display: 'flex',
|
|
3400
3680
|
flexDirection: 'column',
|
|
3401
3681
|
alignItems: 'end',
|
|
3402
|
-
padding: '$16
|
|
3682
|
+
padding: '$16',
|
|
3403
3683
|
boxSizing: 'border-box',
|
|
3404
3684
|
position: 'relative'
|
|
3405
3685
|
});
|
|
3406
|
-
var ContentContainer$
|
|
3686
|
+
var ContentContainer$2 = /*#__PURE__*/styled('div', {
|
|
3407
3687
|
width: '100%'
|
|
3408
3688
|
});
|
|
3409
3689
|
function SwapContainer(props) {
|
|
@@ -3412,7 +3692,7 @@ function SwapContainer(props) {
|
|
|
3412
3692
|
return React__default.createElement(MainContainer$1, {
|
|
3413
3693
|
style: style,
|
|
3414
3694
|
id: "swap-box"
|
|
3415
|
-
}, React__default.createElement(ContentContainer$
|
|
3695
|
+
}, React__default.createElement(ContentContainer$2, null, children));
|
|
3416
3696
|
}
|
|
3417
3697
|
|
|
3418
3698
|
var Container$4 = /*#__PURE__*/styled('div', {
|
|
@@ -3620,7 +3900,7 @@ function TokenItem(props) {
|
|
|
3620
3900
|
}, token.name))));
|
|
3621
3901
|
}
|
|
3622
3902
|
|
|
3623
|
-
var _excluded$
|
|
3903
|
+
var _excluded$G = ["style"];
|
|
3624
3904
|
var PAGE_SIZE = 20;
|
|
3625
3905
|
function TokenList(props) {
|
|
3626
3906
|
var list = props.list,
|
|
@@ -3660,7 +3940,7 @@ function TokenList(props) {
|
|
|
3660
3940
|
}, [tokens.length]);
|
|
3661
3941
|
var innerElementType = React.forwardRef(function (_ref, ref) {
|
|
3662
3942
|
var style = _ref.style,
|
|
3663
|
-
rest = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
3943
|
+
rest = _objectWithoutPropertiesLoose(_ref, _excluded$G);
|
|
3664
3944
|
return React__default.createElement("div", Object.assign({
|
|
3665
3945
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3666
3946
|
ref: ref,
|
|
@@ -3724,99 +4004,6 @@ function TokenSelector(props) {
|
|
|
3724
4004
|
});
|
|
3725
4005
|
}
|
|
3726
4006
|
|
|
3727
|
-
var TooltipTrigger = /*#__PURE__*/styled(RadixTooltip.Trigger, {
|
|
3728
|
-
border: 0,
|
|
3729
|
-
padding: 0,
|
|
3730
|
-
backgroundColor: 'transparent'
|
|
3731
|
-
});
|
|
3732
|
-
var TooltipContent = /*#__PURE__*/styled(RadixTooltip.Content, {
|
|
3733
|
-
borderRadius: '$5',
|
|
3734
|
-
padding: '$4 $8',
|
|
3735
|
-
fontSize: '$14',
|
|
3736
|
-
animationDuration: '400ms',
|
|
3737
|
-
animationTimingFunction: 'cubic-bezier(0.16, 1, 0.3, 1)',
|
|
3738
|
-
willChange: 'transform, opacity',
|
|
3739
|
-
variants: {
|
|
3740
|
-
color: {
|
|
3741
|
-
primary: {
|
|
3742
|
-
backgroundColor: '$primary',
|
|
3743
|
-
color: '$white'
|
|
3744
|
-
},
|
|
3745
|
-
error: {
|
|
3746
|
-
backgroundColor: '$error',
|
|
3747
|
-
color: '$white'
|
|
3748
|
-
},
|
|
3749
|
-
warning: {
|
|
3750
|
-
backgroundColor: '$warning',
|
|
3751
|
-
color: '$white'
|
|
3752
|
-
},
|
|
3753
|
-
success: {
|
|
3754
|
-
backgroundColor: '$success',
|
|
3755
|
-
color: '$white'
|
|
3756
|
-
},
|
|
3757
|
-
gray: {
|
|
3758
|
-
backgroundColor: '$neutrals300',
|
|
3759
|
-
color: '$black'
|
|
3760
|
-
},
|
|
3761
|
-
black: {
|
|
3762
|
-
backgroundColor: '$black',
|
|
3763
|
-
color: '$white'
|
|
3764
|
-
},
|
|
3765
|
-
white: {
|
|
3766
|
-
backgroundColor: '$white',
|
|
3767
|
-
color: '$black'
|
|
3768
|
-
}
|
|
3769
|
-
}
|
|
3770
|
-
}
|
|
3771
|
-
});
|
|
3772
|
-
var TooltipArrow = /*#__PURE__*/styled(RadixTooltip.Arrow, {
|
|
3773
|
-
variants: {
|
|
3774
|
-
color: {
|
|
3775
|
-
primary: {
|
|
3776
|
-
fill: '$primary'
|
|
3777
|
-
},
|
|
3778
|
-
error: {
|
|
3779
|
-
fill: '$error'
|
|
3780
|
-
},
|
|
3781
|
-
warning: {
|
|
3782
|
-
fill: '$warning'
|
|
3783
|
-
},
|
|
3784
|
-
success: {
|
|
3785
|
-
fill: '$success'
|
|
3786
|
-
},
|
|
3787
|
-
gray: {
|
|
3788
|
-
fill: '$neutrals300'
|
|
3789
|
-
},
|
|
3790
|
-
black: {
|
|
3791
|
-
fill: '$black'
|
|
3792
|
-
},
|
|
3793
|
-
white: {
|
|
3794
|
-
fill: '$white'
|
|
3795
|
-
}
|
|
3796
|
-
}
|
|
3797
|
-
}
|
|
3798
|
-
});
|
|
3799
|
-
var ChildrenWrapper = /*#__PURE__*/styled('div', {
|
|
3800
|
-
display: 'inline-block'
|
|
3801
|
-
});
|
|
3802
|
-
function Tooltip(_ref) {
|
|
3803
|
-
var children = _ref.children,
|
|
3804
|
-
content = _ref.content,
|
|
3805
|
-
_ref$side = _ref.side,
|
|
3806
|
-
side = _ref$side === void 0 ? 'top' : _ref$side,
|
|
3807
|
-
_ref$color = _ref.color,
|
|
3808
|
-
color = _ref$color === void 0 ? 'gray' : _ref$color;
|
|
3809
|
-
return React__default.createElement(RadixTooltip.Provider, null, React__default.createElement(RadixTooltip.Root, null, React__default.createElement(TooltipTrigger, {
|
|
3810
|
-
asChild: true
|
|
3811
|
-
}, React__default.createElement(ChildrenWrapper, null, children)), React__default.createElement(RadixTooltip.Portal, null, React__default.createElement(TooltipContent, {
|
|
3812
|
-
color: color,
|
|
3813
|
-
side: side,
|
|
3814
|
-
sideOffset: 5
|
|
3815
|
-
}, content, React__default.createElement(TooltipArrow, {
|
|
3816
|
-
color: color
|
|
3817
|
-
})))));
|
|
3818
|
-
}
|
|
3819
|
-
|
|
3820
4007
|
var Container$5 = /*#__PURE__*/styled('div', {
|
|
3821
4008
|
position: 'relative'
|
|
3822
4009
|
});
|
|
@@ -4033,13 +4220,6 @@ var ArrowDown = /*#__PURE__*/styled('div', {
|
|
|
4033
4220
|
borderTop: '5px solid $foreground',
|
|
4034
4221
|
marginLeft: '$8'
|
|
4035
4222
|
});
|
|
4036
|
-
var UpdateIcon = /*#__PURE__*/styled(RetryIcon, {
|
|
4037
|
-
position: 'absolute',
|
|
4038
|
-
right: '0'
|
|
4039
|
-
});
|
|
4040
|
-
var StyledUpdateIcon = /*#__PURE__*/styled(UpdateIcon, {
|
|
4041
|
-
cursor: 'pointer'
|
|
4042
|
-
});
|
|
4043
4223
|
var BestRouteContainer$1 = /*#__PURE__*/styled('div', {
|
|
4044
4224
|
overflow: 'auto'
|
|
4045
4225
|
});
|
|
@@ -4049,7 +4229,6 @@ var Alerts = /*#__PURE__*/styled('div', {
|
|
|
4049
4229
|
function ConfirmSwap(props) {
|
|
4050
4230
|
var _bestRoute$result;
|
|
4051
4231
|
var bestRoute = props.bestRoute,
|
|
4052
|
-
onRefresh = props.onRefresh,
|
|
4053
4232
|
onBack = props.onBack,
|
|
4054
4233
|
onConfirm = props.onConfirm,
|
|
4055
4234
|
loading = props.loading,
|
|
@@ -4069,11 +4248,7 @@ function ConfirmSwap(props) {
|
|
|
4069
4248
|
variant: "contained",
|
|
4070
4249
|
onClick: onConfirm,
|
|
4071
4250
|
disabled: confirmButtonDisabled
|
|
4072
|
-
}, confirmButtonTitle))
|
|
4073
|
-
TopButton: React__default.createElement(StyledUpdateIcon, {
|
|
4074
|
-
size: 24,
|
|
4075
|
-
onClick: onRefresh
|
|
4076
|
-
})
|
|
4251
|
+
}, confirmButtonTitle))
|
|
4077
4252
|
}, React__default.createElement(MainContainer$2, null, React__default.createElement("div", null, extraMessages || null, React__default.createElement(Alerts, null, errors == null ? void 0 : errors.map(function (error, index) {
|
|
4078
4253
|
return React__default.createElement(React__default.Fragment, null, React__default.createElement(Spacer, {
|
|
4079
4254
|
direction: "vertical"
|
|
@@ -4117,6 +4292,11 @@ function ConfirmSwap(props) {
|
|
|
4117
4292
|
}))));
|
|
4118
4293
|
}
|
|
4119
4294
|
|
|
4295
|
+
var Section = /*#__PURE__*/styled('div', {
|
|
4296
|
+
paddingBottom: '$32',
|
|
4297
|
+
marginBottom: '$32',
|
|
4298
|
+
borderBottom: '1px solid $neutrals400'
|
|
4299
|
+
});
|
|
4120
4300
|
var Footer$2 = /*#__PURE__*/styled('div', {
|
|
4121
4301
|
display: 'flex',
|
|
4122
4302
|
alignItems: 'center'
|
|
@@ -4127,22 +4307,36 @@ var AlertContainer = /*#__PURE__*/styled('div', {
|
|
|
4127
4307
|
var ConfirmButton = /*#__PURE__*/styled(Button, {
|
|
4128
4308
|
marginTop: '$16'
|
|
4129
4309
|
});
|
|
4310
|
+
var Container$6 = /*#__PURE__*/styled('div', {
|
|
4311
|
+
paddingBottom: '$24',
|
|
4312
|
+
'.title': {
|
|
4313
|
+
paddingBottom: '$8',
|
|
4314
|
+
display: 'flex',
|
|
4315
|
+
alignItems: 'center'
|
|
4316
|
+
},
|
|
4317
|
+
'.num': {
|
|
4318
|
+
backgroundColor: '$neutrals300',
|
|
4319
|
+
display: 'inline-flex',
|
|
4320
|
+
width: '24px',
|
|
4321
|
+
height: '24px',
|
|
4322
|
+
color: '$neutrals800',
|
|
4323
|
+
borderRadius: '50%',
|
|
4324
|
+
fontSize: '$14',
|
|
4325
|
+
border: '1px solid $neutrals400',
|
|
4326
|
+
justifyContent: 'center',
|
|
4327
|
+
alignItems: 'center'
|
|
4328
|
+
}
|
|
4329
|
+
});
|
|
4130
4330
|
function ConfirmWallets(props) {
|
|
4131
|
-
var _swap$result, _swap$result2, _swap$result3;
|
|
4132
4331
|
var onBack = props.onBack,
|
|
4133
4332
|
loading = props.loading,
|
|
4134
4333
|
onConfirm = props.onConfirm,
|
|
4135
|
-
swap = props.swap,
|
|
4136
4334
|
requiredWallets = props.requiredWallets,
|
|
4137
4335
|
selectableWallets = props.selectableWallets,
|
|
4138
4336
|
onChange = props.onChange,
|
|
4139
4337
|
confirmDisabled = props.confirmDisabled,
|
|
4140
4338
|
isExperimentalChain = props.isExperimentalChain,
|
|
4141
|
-
handleConnectChain = props.handleConnectChain
|
|
4142
|
-
fromAmount = props.fromAmount,
|
|
4143
|
-
toAmount = props.toAmount;
|
|
4144
|
-
var firstStep = swap == null ? void 0 : (_swap$result = swap.result) == null ? void 0 : _swap$result.swaps[0];
|
|
4145
|
-
var lastStep = swap == null ? void 0 : (_swap$result2 = swap.result) == null ? void 0 : _swap$result2.swaps[((_swap$result3 = swap.result) == null ? void 0 : _swap$result3.swaps.length) - 1];
|
|
4339
|
+
handleConnectChain = props.handleConnectChain;
|
|
4146
4340
|
return React__default.createElement(SecondaryPage, {
|
|
4147
4341
|
textField: false,
|
|
4148
4342
|
title: "Confirm Swap",
|
|
@@ -4154,25 +4348,27 @@ function ConfirmWallets(props) {
|
|
|
4154
4348
|
variant: "contained",
|
|
4155
4349
|
onClick: onConfirm,
|
|
4156
4350
|
disabled: confirmDisabled
|
|
4157
|
-
}, "Confirm"))
|
|
4158
|
-
}, React__default.createElement(
|
|
4159
|
-
|
|
4160
|
-
|
|
4161
|
-
}
|
|
4351
|
+
}, "Confirm Swap"))
|
|
4352
|
+
}, props.previewInputs || props.previewRoutes ? React__default.createElement(Section, null, props.previewInputs, !!props.previewRoutes ? React__default.createElement(Spacer, {
|
|
4353
|
+
size: 16,
|
|
4354
|
+
direction: "vertical"
|
|
4355
|
+
}) : null, props.previewRoutes) : null, requiredWallets.map(function (wallet, index) {
|
|
4162
4356
|
var list = selectableWallets.filter(function (w) {
|
|
4163
4357
|
return wallet === w.chain;
|
|
4164
4358
|
});
|
|
4165
|
-
return React__default.createElement(
|
|
4359
|
+
return React__default.createElement(Container$6, {
|
|
4166
4360
|
key: index
|
|
4167
|
-
}, React__default.createElement(
|
|
4168
|
-
|
|
4169
|
-
|
|
4170
|
-
|
|
4171
|
-
}, index + 1
|
|
4172
|
-
|
|
4173
|
-
}, React__default.createElement(Typography, {
|
|
4361
|
+
}, React__default.createElement("div", {
|
|
4362
|
+
className: "title"
|
|
4363
|
+
}, React__default.createElement("div", {
|
|
4364
|
+
className: "num"
|
|
4365
|
+
}, index + 1), React__default.createElement(Spacer, {
|
|
4366
|
+
size: 8
|
|
4367
|
+
}), React__default.createElement(Typography, {
|
|
4174
4368
|
variant: "body2"
|
|
4175
|
-
}, "
|
|
4369
|
+
}, "Your ", wallet, " Wallet")), list.length === 0 && React__default.createElement(React__default.Fragment, null, React__default.createElement(AlertContainer, null, React__default.createElement(Alert, {
|
|
4370
|
+
type: "error"
|
|
4371
|
+
}, "You need to connect a compatible wallet with ", wallet)), (isExperimentalChain == null ? void 0 : isExperimentalChain(wallet)) && React__default.createElement(Button, {
|
|
4176
4372
|
variant: "contained",
|
|
4177
4373
|
type: "primary",
|
|
4178
4374
|
align: "grow",
|
|
@@ -4183,7 +4379,7 @@ function ConfirmWallets(props) {
|
|
|
4183
4379
|
list: list,
|
|
4184
4380
|
onChange: onChange
|
|
4185
4381
|
}));
|
|
4186
|
-
}))
|
|
4382
|
+
}));
|
|
4187
4383
|
}
|
|
4188
4384
|
|
|
4189
4385
|
function groupingOfSwaps(list) {
|
|
@@ -4473,6 +4669,7 @@ exports.CheckIcon = CheckIcon;
|
|
|
4473
4669
|
exports.CheckSquareIcon = CheckSquareIcon;
|
|
4474
4670
|
exports.CheckWalletIcon = CheckWalletIcon;
|
|
4475
4671
|
exports.Checkbox = Checkbox;
|
|
4672
|
+
exports.ChevronRightIcon = ChevronRightIcon;
|
|
4476
4673
|
exports.Chip = Chip;
|
|
4477
4674
|
exports.CloseIcon = CloseIcon;
|
|
4478
4675
|
exports.ColorPicker = ColorPicker;
|
|
@@ -4482,6 +4679,7 @@ exports.ConnectWalletsModal = ConnectWalletsModal;
|
|
|
4482
4679
|
exports.CopyIcon = CopyIcon;
|
|
4483
4680
|
exports.DeleteCircleIcon = DeleteCircleIcon;
|
|
4484
4681
|
exports.DeleteWalletIcon = DeleteWalletIcon;
|
|
4682
|
+
exports.DisconnectIcon = DisconnectIcon;
|
|
4485
4683
|
exports.DownloadIcon = DownloadIcon;
|
|
4486
4684
|
exports.Drawer = Drawer;
|
|
4487
4685
|
exports.FilledCircle = FilledCircle;
|