@proton/wrap-constants 0.0.6 → 0.0.11
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/coins.d.ts +14 -2
- package/dist/parsers.d.ts +2 -0
- package/dist/wrap-constants.cjs.development.js +171 -44
- package/dist/wrap-constants.cjs.development.js.map +1 -1
- package/dist/wrap-constants.cjs.production.min.js +1 -1
- package/dist/wrap-constants.cjs.production.min.js.map +1 -1
- package/dist/wrap-constants.esm.js +171 -44
- package/dist/wrap-constants.esm.js.map +1 -1
- package/package.json +2 -2
- package/src/coins.ts +205 -94
- package/src/parsers.ts +2 -1
package/dist/coins.d.ts
CHANGED
|
@@ -5,14 +5,20 @@ export declare enum Chains {
|
|
|
5
5
|
EthereumMainnet = "Ethereum",
|
|
6
6
|
EthereumRopsten = "Ethereum (Ropsten)",
|
|
7
7
|
LitecoinMainnet = "Litecoin",
|
|
8
|
+
LitecoinTestnet = "Litecoin (Testnet)",
|
|
8
9
|
BitcoinCashMainnet = "Bitcoin Cash",
|
|
10
|
+
BitcoinCashTestnet = "Bitcoin Cash (Testnet)",
|
|
9
11
|
StellarMainnet = "Stellar",
|
|
12
|
+
StellarTestnet = "Stellar (Testnet)",
|
|
10
13
|
ProtonMainnet = "Proton",
|
|
11
14
|
ProtonTestnet = "Proton (Testnet)",
|
|
12
15
|
PolkadotMainnet = "Polkadot",
|
|
13
16
|
BinanceBEP2 = "Binance (BEP2)",
|
|
14
17
|
BinanceBEP20 = "Binance (BEP20)",
|
|
15
|
-
EosMainnet = "EOS"
|
|
18
|
+
EosMainnet = "EOS",
|
|
19
|
+
EosTestnet = "EOS (Jungle Testnet)",
|
|
20
|
+
HederaMainnet = "Hedera (Mainnet)",
|
|
21
|
+
HederaTestnet = "Hedera (Testnet)"
|
|
16
22
|
}
|
|
17
23
|
export declare enum Networks {
|
|
18
24
|
Mainnet = "mainnet",
|
|
@@ -51,14 +57,20 @@ export declare const explorerLinkByChain: {
|
|
|
51
57
|
Ethereum: (txid: string) => string;
|
|
52
58
|
"Ethereum (Ropsten)": (txid: string) => string;
|
|
53
59
|
Litecoin: (txid: string) => string;
|
|
60
|
+
"Litecoin (Testnet)": (txid: string) => string;
|
|
54
61
|
"Bitcoin Cash": (txid: string) => string;
|
|
62
|
+
"Bitcoin Cash (Testnet)": (txid: string) => string;
|
|
55
63
|
Stellar: (txid: string) => string;
|
|
64
|
+
"Stellar (Testnet)": (txid: string) => string;
|
|
56
65
|
Proton: (txid: string) => string;
|
|
57
66
|
"Proton (Testnet)": (txid: string) => string;
|
|
58
67
|
Polkadot: (txid: string) => string;
|
|
59
|
-
EOS: (txid: string) => string;
|
|
60
68
|
"Binance (BEP2)": (txid: string) => string;
|
|
61
69
|
"Binance (BEP20)": (txid: string) => string;
|
|
70
|
+
EOS: (txid: string) => string;
|
|
71
|
+
"EOS (Jungle Testnet)": (txid: string) => string;
|
|
72
|
+
"Hedera (Mainnet)": (txid: string) => string;
|
|
73
|
+
"Hedera (Testnet)": (txid: string) => string;
|
|
62
74
|
};
|
|
63
75
|
export declare const initializeCoins: (protonChain: string) => {
|
|
64
76
|
allCoins: Coin[];
|
package/dist/parsers.d.ts
CHANGED
|
@@ -399,9 +399,11 @@ export declare const withdrawBodyParser: z.ZodObject<{
|
|
|
399
399
|
}[];
|
|
400
400
|
}>;
|
|
401
401
|
quoteId: z.ZodString;
|
|
402
|
+
provider: z.ZodUnion<[z.ZodString, z.ZodUndefined]>;
|
|
402
403
|
}, {
|
|
403
404
|
strict: true;
|
|
404
405
|
}, {
|
|
406
|
+
provider?: string | undefined;
|
|
405
407
|
signer: {
|
|
406
408
|
actor: string;
|
|
407
409
|
permission: string;
|
|
@@ -12,14 +12,20 @@ var _explorerLinkByChain;
|
|
|
12
12
|
Chains["EthereumMainnet"] = "Ethereum";
|
|
13
13
|
Chains["EthereumRopsten"] = "Ethereum (Ropsten)";
|
|
14
14
|
Chains["LitecoinMainnet"] = "Litecoin";
|
|
15
|
+
Chains["LitecoinTestnet"] = "Litecoin (Testnet)";
|
|
15
16
|
Chains["BitcoinCashMainnet"] = "Bitcoin Cash";
|
|
17
|
+
Chains["BitcoinCashTestnet"] = "Bitcoin Cash (Testnet)";
|
|
16
18
|
Chains["StellarMainnet"] = "Stellar";
|
|
19
|
+
Chains["StellarTestnet"] = "Stellar (Testnet)";
|
|
17
20
|
Chains["ProtonMainnet"] = "Proton";
|
|
18
21
|
Chains["ProtonTestnet"] = "Proton (Testnet)";
|
|
19
22
|
Chains["PolkadotMainnet"] = "Polkadot";
|
|
20
23
|
Chains["BinanceBEP2"] = "Binance (BEP2)";
|
|
21
24
|
Chains["BinanceBEP20"] = "Binance (BEP20)";
|
|
22
25
|
Chains["EosMainnet"] = "EOS";
|
|
26
|
+
Chains["EosTestnet"] = "EOS (Jungle Testnet)";
|
|
27
|
+
Chains["HederaMainnet"] = "Hedera (Mainnet)";
|
|
28
|
+
Chains["HederaTestnet"] = "Hedera (Testnet)";
|
|
23
29
|
})(exports.Chains || (exports.Chains = {}));
|
|
24
30
|
|
|
25
31
|
(function (Networks) {
|
|
@@ -40,29 +46,41 @@ var explorerLinkByChain = (_explorerLinkByChain = {}, _explorerLinkByChain[expor
|
|
|
40
46
|
return "https://ropsten.etherscan.io/tx/" + txid;
|
|
41
47
|
}, _explorerLinkByChain[exports.Chains.LitecoinMainnet] = function (txid) {
|
|
42
48
|
return "https://blockchair.com/litecoin/transaction/" + txid;
|
|
49
|
+
}, _explorerLinkByChain[exports.Chains.LitecoinTestnet] = function (txid) {
|
|
50
|
+
return "https://blockexplorer.one/litecoin/testnet/blockHash/" + txid;
|
|
43
51
|
}, _explorerLinkByChain[exports.Chains.BitcoinCashMainnet] = function (txid) {
|
|
44
52
|
return "https://blockchair.com/bitcoin-cash/transaction/" + txid;
|
|
53
|
+
}, _explorerLinkByChain[exports.Chains.BitcoinCashTestnet] = function (txid) {
|
|
54
|
+
return "https://blockexplorer.one/bitcoin-cash/testnet/blockHash/" + txid;
|
|
45
55
|
}, _explorerLinkByChain[exports.Chains.StellarMainnet] = function (txid) {
|
|
46
56
|
return "https://blockchair.com/stellar/transaction/" + txid;
|
|
57
|
+
}, _explorerLinkByChain[exports.Chains.StellarTestnet] = function (txid) {
|
|
58
|
+
return "https://testnet.steexp.com/tx/" + txid;
|
|
47
59
|
}, _explorerLinkByChain[exports.Chains.ProtonMainnet] = function (txid) {
|
|
48
60
|
return "https://proton.bloks.io/transaction/" + txid;
|
|
49
61
|
}, _explorerLinkByChain[exports.Chains.ProtonTestnet] = function (txid) {
|
|
50
62
|
return "https://proton-test.bloks.io/transaction/" + txid;
|
|
51
63
|
}, _explorerLinkByChain[exports.Chains.PolkadotMainnet] = function (txid) {
|
|
52
64
|
return "https://polkadot.subscan.io/extrinsic/" + txid;
|
|
53
|
-
}, _explorerLinkByChain[exports.Chains.EosMainnet] = function (txid) {
|
|
54
|
-
return "https://bloks.io/transaction/" + txid;
|
|
55
65
|
}, _explorerLinkByChain[exports.Chains.BinanceBEP2] = function (txid) {
|
|
56
66
|
return "https://binance.mintscan.io/txs/" + txid;
|
|
57
67
|
}, _explorerLinkByChain[exports.Chains.BinanceBEP20] = function (txid) {
|
|
58
68
|
return "https://bscscan.com/tx/" + txid;
|
|
69
|
+
}, _explorerLinkByChain[exports.Chains.EosMainnet] = function (txid) {
|
|
70
|
+
return "https://bloks.io/transaction/" + txid;
|
|
71
|
+
}, _explorerLinkByChain[exports.Chains.EosTestnet] = function (txid) {
|
|
72
|
+
return "https://jungle.bloks.io/transaction/" + txid;
|
|
73
|
+
}, _explorerLinkByChain[exports.Chains.HederaMainnet] = function (txid) {
|
|
74
|
+
return "https://app.dragonglass.me/transactions/" + txid;
|
|
75
|
+
}, _explorerLinkByChain[exports.Chains.HederaTestnet] = function (txid) {
|
|
76
|
+
return "https://testnet.dragonglass.me/transactions/" + txid;
|
|
59
77
|
}, _explorerLinkByChain);
|
|
60
78
|
var initializeCoins = function initializeCoins(protonChain) {
|
|
61
79
|
var IS_MAINNET = protonChain === 'proton';
|
|
62
80
|
var IS_TESTNET = protonChain === 'proton-test';
|
|
63
81
|
var coins = [{
|
|
64
82
|
allowSwap: true,
|
|
65
|
-
allowBridge:
|
|
83
|
+
allowBridge: IS_MAINNET,
|
|
66
84
|
allowLend: false,
|
|
67
85
|
allowBorrow: false,
|
|
68
86
|
name: 'Proton',
|
|
@@ -70,7 +88,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
70
88
|
xtokenSymbol: 'XPR',
|
|
71
89
|
xtokenPrecision: 4,
|
|
72
90
|
xtokenContract: 'eosio.token',
|
|
73
|
-
wallets: [{
|
|
91
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
74
92
|
wallet: 'XPR-ERC20',
|
|
75
93
|
symbol: 'XPR',
|
|
76
94
|
chain: exports.Chains.EthereumMainnet,
|
|
@@ -78,7 +96,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
78
96
|
precision: 4,
|
|
79
97
|
contract: '0xD7EFB00D12C2C13131FD319336FDF952525DA2AF',
|
|
80
98
|
hasWithdrawMemo: false
|
|
81
|
-
}
|
|
99
|
+
}, {
|
|
82
100
|
wallet: 'XPR-BEP20',
|
|
83
101
|
symbol: 'XPR',
|
|
84
102
|
chain: exports.Chains.BinanceBEP20,
|
|
@@ -98,7 +116,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
98
116
|
xtokenSymbol: 'XUSDC',
|
|
99
117
|
xtokenPrecision: 6,
|
|
100
118
|
xtokenContract: 'xtokens',
|
|
101
|
-
wallets: [{
|
|
119
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
102
120
|
wallet: 'USDC',
|
|
103
121
|
symbol: 'USDC',
|
|
104
122
|
chain: exports.Chains.EthereumMainnet,
|
|
@@ -106,11 +124,27 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
106
124
|
precision: 6,
|
|
107
125
|
contract: '0xA0B86991C6218B36C1D19D4A2E9EB0CE3606EB48',
|
|
108
126
|
hasWithdrawMemo: false
|
|
109
|
-
}
|
|
127
|
+
}, {
|
|
128
|
+
wallet: 'USDC-BEP20',
|
|
129
|
+
symbol: 'USDC',
|
|
130
|
+
chain: exports.Chains.BinanceBEP20,
|
|
131
|
+
network: exports.Networks.BEP20,
|
|
132
|
+
precision: 18,
|
|
133
|
+
contract: '0x8AC76A51CC950D9822D68B83FE1AD97B32CD580D',
|
|
134
|
+
hasWithdrawMemo: false
|
|
135
|
+
}] : [], IS_TESTNET ? [{
|
|
136
|
+
wallet: 'USDC',
|
|
137
|
+
symbol: 'USDC',
|
|
138
|
+
chain: exports.Chains.EthereumRopsten,
|
|
139
|
+
network: exports.Networks.Ropsten,
|
|
140
|
+
precision: 6,
|
|
141
|
+
contract: '0xA0B86991C6218B36C1D19D4A2E9EB0CE3606EB48',
|
|
142
|
+
hasWithdrawMemo: false
|
|
143
|
+
}] : []),
|
|
110
144
|
image: '/img/tokens/xusdc.png'
|
|
111
145
|
}, {
|
|
112
146
|
allowSwap: true,
|
|
113
|
-
allowBridge:
|
|
147
|
+
allowBridge: IS_MAINNET,
|
|
114
148
|
allowLend: false,
|
|
115
149
|
allowBorrow: false,
|
|
116
150
|
name: 'Metal',
|
|
@@ -118,7 +152,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
118
152
|
xtokenSymbol: 'XMT',
|
|
119
153
|
xtokenPrecision: 8,
|
|
120
154
|
xtokenContract: 'xtokens',
|
|
121
|
-
wallets: [{
|
|
155
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
122
156
|
wallet: 'MTL',
|
|
123
157
|
symbol: 'MTL',
|
|
124
158
|
chain: exports.Chains.EthereumMainnet,
|
|
@@ -126,7 +160,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
126
160
|
precision: 8,
|
|
127
161
|
contract: '0xF433089366899D83A9F26A773D59EC7ECF30355E',
|
|
128
162
|
hasWithdrawMemo: false
|
|
129
|
-
}],
|
|
163
|
+
}] : []),
|
|
130
164
|
image: '/img/tokens/xmt.png'
|
|
131
165
|
}, {
|
|
132
166
|
allowSwap: true,
|
|
@@ -138,7 +172,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
138
172
|
xtokenSymbol: 'XBTC',
|
|
139
173
|
xtokenPrecision: 8,
|
|
140
174
|
xtokenContract: 'xtokens',
|
|
141
|
-
wallets: [{
|
|
175
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
142
176
|
wallet: 'BTC',
|
|
143
177
|
symbol: 'BTC',
|
|
144
178
|
chain: exports.Chains.BitcoinMainnet,
|
|
@@ -146,7 +180,15 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
146
180
|
precision: 8,
|
|
147
181
|
contract: undefined,
|
|
148
182
|
hasWithdrawMemo: false
|
|
149
|
-
}],
|
|
183
|
+
}] : [], IS_TESTNET ? [{
|
|
184
|
+
wallet: 'BTC',
|
|
185
|
+
symbol: 'BTC',
|
|
186
|
+
chain: exports.Chains.BitcoinTestnet,
|
|
187
|
+
network: exports.Networks.Testnet,
|
|
188
|
+
precision: 8,
|
|
189
|
+
contract: undefined,
|
|
190
|
+
hasWithdrawMemo: false
|
|
191
|
+
}] : []),
|
|
150
192
|
image: '/img/tokens/xbtc.png'
|
|
151
193
|
}, {
|
|
152
194
|
allowSwap: true,
|
|
@@ -158,7 +200,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
158
200
|
xtokenSymbol: 'XETH',
|
|
159
201
|
xtokenPrecision: 8,
|
|
160
202
|
xtokenContract: 'xtokens',
|
|
161
|
-
wallets: [{
|
|
203
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
162
204
|
wallet: 'ETH',
|
|
163
205
|
symbol: 'ETH',
|
|
164
206
|
chain: exports.Chains.EthereumMainnet,
|
|
@@ -166,7 +208,15 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
166
208
|
precision: 18,
|
|
167
209
|
contract: '0x0000000000000000000000000000000000000000',
|
|
168
210
|
hasWithdrawMemo: false
|
|
169
|
-
}],
|
|
211
|
+
}] : [], IS_TESTNET ? [{
|
|
212
|
+
wallet: 'ETH',
|
|
213
|
+
symbol: 'ETH',
|
|
214
|
+
chain: exports.Chains.EthereumRopsten,
|
|
215
|
+
network: exports.Networks.Ropsten,
|
|
216
|
+
precision: 18,
|
|
217
|
+
contract: '0x0000000000000000000000000000000000000000',
|
|
218
|
+
hasWithdrawMemo: false
|
|
219
|
+
}] : []),
|
|
170
220
|
image: '/img/tokens/xeth.png'
|
|
171
221
|
}, {
|
|
172
222
|
allowSwap: IS_MAINNET,
|
|
@@ -178,7 +228,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
178
228
|
xtokenSymbol: 'XUSDT',
|
|
179
229
|
xtokenPrecision: 6,
|
|
180
230
|
xtokenContract: 'xtokens',
|
|
181
|
-
wallets: [{
|
|
231
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
182
232
|
wallet: 'USDT',
|
|
183
233
|
symbol: 'USDT',
|
|
184
234
|
chain: exports.Chains.EthereumMainnet,
|
|
@@ -186,11 +236,19 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
186
236
|
precision: 6,
|
|
187
237
|
contract: '0xDAC17F958D2EE523A2206206994597C13D831EC7',
|
|
188
238
|
hasWithdrawMemo: false
|
|
189
|
-
}],
|
|
239
|
+
}] : [], IS_TESTNET ? [{
|
|
240
|
+
wallet: 'USDT',
|
|
241
|
+
symbol: 'USDT',
|
|
242
|
+
chain: exports.Chains.EthereumRopsten,
|
|
243
|
+
network: exports.Networks.Ropsten,
|
|
244
|
+
precision: 6,
|
|
245
|
+
contract: '0xDAC17F958D2EE523A2206206994597C13D831EC7',
|
|
246
|
+
hasWithdrawMemo: false
|
|
247
|
+
}] : []),
|
|
190
248
|
image: '/img/tokens/xusdt.png'
|
|
191
249
|
}, {
|
|
192
250
|
allowSwap: false,
|
|
193
|
-
allowBridge:
|
|
251
|
+
allowBridge: IS_MAINNET,
|
|
194
252
|
allowLend: false,
|
|
195
253
|
allowBorrow: false,
|
|
196
254
|
name: 'TrueUSD',
|
|
@@ -198,7 +256,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
198
256
|
xtokenSymbol: 'XTUSD',
|
|
199
257
|
xtokenPrecision: 6,
|
|
200
258
|
xtokenContract: 'xtokens',
|
|
201
|
-
wallets: [{
|
|
259
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
202
260
|
wallet: 'TUSD',
|
|
203
261
|
symbol: 'TUSD',
|
|
204
262
|
chain: exports.Chains.EthereumMainnet,
|
|
@@ -206,11 +264,11 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
206
264
|
precision: 18,
|
|
207
265
|
contract: '0x0000000000085D4780B73119B644AE5ECD22B376',
|
|
208
266
|
hasWithdrawMemo: false
|
|
209
|
-
}],
|
|
267
|
+
}] : []),
|
|
210
268
|
image: '/img/tokens/xtusd.png'
|
|
211
269
|
}, {
|
|
212
270
|
allowSwap: false,
|
|
213
|
-
allowBridge:
|
|
271
|
+
allowBridge: IS_MAINNET,
|
|
214
272
|
allowLend: false,
|
|
215
273
|
allowBorrow: false,
|
|
216
274
|
name: 'Paxos Standard',
|
|
@@ -218,7 +276,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
218
276
|
xtokenSymbol: 'XPAX',
|
|
219
277
|
xtokenPrecision: 6,
|
|
220
278
|
xtokenContract: 'xtokens',
|
|
221
|
-
wallets: [{
|
|
279
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
222
280
|
wallet: 'PAX',
|
|
223
281
|
symbol: 'PAX',
|
|
224
282
|
chain: exports.Chains.EthereumMainnet,
|
|
@@ -226,7 +284,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
226
284
|
precision: 18,
|
|
227
285
|
contract: '0x8E870D67F660D95D5BE530380D0EC0BD388289E1',
|
|
228
286
|
hasWithdrawMemo: false
|
|
229
|
-
}],
|
|
287
|
+
}] : []),
|
|
230
288
|
image: '/img/tokens/xpax.png'
|
|
231
289
|
}, {
|
|
232
290
|
allowSwap: false,
|
|
@@ -238,7 +296,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
238
296
|
xtokenSymbol: 'XPAXG',
|
|
239
297
|
xtokenPrecision: 8,
|
|
240
298
|
xtokenContract: 'xtokens',
|
|
241
|
-
wallets: [{
|
|
299
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
242
300
|
wallet: 'PAXG',
|
|
243
301
|
symbol: 'PAXG',
|
|
244
302
|
chain: exports.Chains.EthereumMainnet,
|
|
@@ -246,7 +304,15 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
246
304
|
precision: 18,
|
|
247
305
|
contract: '0x45804880DE22913DAFE09F4980848ECE6ECBAF78',
|
|
248
306
|
hasWithdrawMemo: false
|
|
249
|
-
}],
|
|
307
|
+
}] : [], IS_TESTNET ? [{
|
|
308
|
+
wallet: 'PAXG',
|
|
309
|
+
symbol: 'PAXG',
|
|
310
|
+
chain: exports.Chains.EthereumRopsten,
|
|
311
|
+
network: exports.Networks.Ropsten,
|
|
312
|
+
precision: 18,
|
|
313
|
+
contract: '0x45804880DE22913DAFE09F4980848ECE6ECBAF78',
|
|
314
|
+
hasWithdrawMemo: false
|
|
315
|
+
}] : []),
|
|
250
316
|
image: '/img/tokens/xpaxg.png'
|
|
251
317
|
}, {
|
|
252
318
|
allowSwap: IS_MAINNET,
|
|
@@ -258,7 +324,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
258
324
|
xtokenSymbol: 'XUNI',
|
|
259
325
|
xtokenPrecision: 6,
|
|
260
326
|
xtokenContract: 'xtokens',
|
|
261
|
-
wallets: [{
|
|
327
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
262
328
|
wallet: 'UNI',
|
|
263
329
|
symbol: 'UNI',
|
|
264
330
|
chain: exports.Chains.EthereumMainnet,
|
|
@@ -266,7 +332,15 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
266
332
|
precision: 18,
|
|
267
333
|
contract: '0x1F9840A85D5AF5BF1D1762F925BDADDC4201F984',
|
|
268
334
|
hasWithdrawMemo: false
|
|
269
|
-
}],
|
|
335
|
+
}] : [], IS_TESTNET ? [{
|
|
336
|
+
wallet: 'UNI',
|
|
337
|
+
symbol: 'UNI',
|
|
338
|
+
chain: exports.Chains.EthereumRopsten,
|
|
339
|
+
network: exports.Networks.Ropsten,
|
|
340
|
+
precision: 18,
|
|
341
|
+
contract: '0x1F9840A85D5AF5BF1D1762F925BDADDC4201F984',
|
|
342
|
+
hasWithdrawMemo: false
|
|
343
|
+
}] : []),
|
|
270
344
|
image: '/img/tokens/xuni.png'
|
|
271
345
|
}, {
|
|
272
346
|
allowSwap: false,
|
|
@@ -278,7 +352,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
278
352
|
xtokenSymbol: 'XINCH',
|
|
279
353
|
xtokenPrecision: 6,
|
|
280
354
|
xtokenContract: 'xtokens',
|
|
281
|
-
wallets: [{
|
|
355
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
282
356
|
wallet: '1INCH',
|
|
283
357
|
symbol: '1INCH',
|
|
284
358
|
chain: exports.Chains.EthereumMainnet,
|
|
@@ -286,7 +360,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
286
360
|
precision: 18,
|
|
287
361
|
contract: '0x111111111117DC0AA78B770FA6A738034120C302',
|
|
288
362
|
hasWithdrawMemo: false
|
|
289
|
-
}],
|
|
363
|
+
}] : []),
|
|
290
364
|
image: '/img/tokens/xinch.png'
|
|
291
365
|
}, {
|
|
292
366
|
allowSwap: false,
|
|
@@ -298,7 +372,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
298
372
|
xtokenSymbol: 'XLINK',
|
|
299
373
|
xtokenPrecision: 6,
|
|
300
374
|
xtokenContract: 'xtokens',
|
|
301
|
-
wallets: [{
|
|
375
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
302
376
|
wallet: 'LINK',
|
|
303
377
|
symbol: 'LINK',
|
|
304
378
|
chain: exports.Chains.EthereumMainnet,
|
|
@@ -306,7 +380,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
306
380
|
precision: 18,
|
|
307
381
|
contract: '0x514910771AF9CA656AF840DFF83E8264ECF986CA',
|
|
308
382
|
hasWithdrawMemo: false
|
|
309
|
-
}],
|
|
383
|
+
}] : []),
|
|
310
384
|
image: '/img/tokens/xlink.png'
|
|
311
385
|
}, {
|
|
312
386
|
allowSwap: IS_MAINNET,
|
|
@@ -318,7 +392,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
318
392
|
xtokenSymbol: 'XLTC',
|
|
319
393
|
xtokenPrecision: 8,
|
|
320
394
|
xtokenContract: 'xtokens',
|
|
321
|
-
wallets: [{
|
|
395
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
322
396
|
wallet: 'LTC',
|
|
323
397
|
symbol: 'LTC',
|
|
324
398
|
chain: exports.Chains.LitecoinMainnet,
|
|
@@ -326,7 +400,15 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
326
400
|
precision: 8,
|
|
327
401
|
contract: undefined,
|
|
328
402
|
hasWithdrawMemo: false
|
|
329
|
-
}],
|
|
403
|
+
}] : [], IS_TESTNET ? [{
|
|
404
|
+
wallet: 'LTC',
|
|
405
|
+
symbol: 'LTC',
|
|
406
|
+
chain: exports.Chains.LitecoinTestnet,
|
|
407
|
+
network: exports.Networks.Testnet,
|
|
408
|
+
precision: 8,
|
|
409
|
+
contract: undefined,
|
|
410
|
+
hasWithdrawMemo: false
|
|
411
|
+
}] : []),
|
|
330
412
|
image: '/img/tokens/xltc.png'
|
|
331
413
|
}, {
|
|
332
414
|
allowSwap: IS_MAINNET,
|
|
@@ -338,7 +420,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
338
420
|
xtokenSymbol: 'XBCH',
|
|
339
421
|
xtokenPrecision: 8,
|
|
340
422
|
xtokenContract: 'xtokens',
|
|
341
|
-
wallets: [{
|
|
423
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
342
424
|
wallet: 'BCH',
|
|
343
425
|
symbol: 'BCH',
|
|
344
426
|
chain: exports.Chains.BitcoinCashMainnet,
|
|
@@ -346,7 +428,15 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
346
428
|
precision: 8,
|
|
347
429
|
contract: undefined,
|
|
348
430
|
hasWithdrawMemo: false
|
|
349
|
-
}],
|
|
431
|
+
}] : [], IS_TESTNET ? [{
|
|
432
|
+
wallet: 'BCH',
|
|
433
|
+
symbol: 'BCH',
|
|
434
|
+
chain: exports.Chains.BitcoinCashTestnet,
|
|
435
|
+
network: exports.Networks.Testnet,
|
|
436
|
+
precision: 8,
|
|
437
|
+
contract: undefined,
|
|
438
|
+
hasWithdrawMemo: false
|
|
439
|
+
}] : []),
|
|
350
440
|
image: '/img/tokens/xbch.png'
|
|
351
441
|
}, {
|
|
352
442
|
allowSwap: false,
|
|
@@ -358,7 +448,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
358
448
|
xtokenSymbol: 'XXLM',
|
|
359
449
|
xtokenPrecision: 6,
|
|
360
450
|
xtokenContract: 'xtokens',
|
|
361
|
-
wallets: [{
|
|
451
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
362
452
|
wallet: 'XLM',
|
|
363
453
|
symbol: 'XLM',
|
|
364
454
|
chain: exports.Chains.StellarMainnet,
|
|
@@ -366,7 +456,15 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
366
456
|
precision: 7,
|
|
367
457
|
contract: undefined,
|
|
368
458
|
hasWithdrawMemo: false
|
|
369
|
-
}],
|
|
459
|
+
}] : [], IS_TESTNET ? [{
|
|
460
|
+
wallet: 'XLM',
|
|
461
|
+
symbol: 'XLM',
|
|
462
|
+
chain: exports.Chains.StellarTestnet,
|
|
463
|
+
network: exports.Networks.Testnet,
|
|
464
|
+
precision: 7,
|
|
465
|
+
contract: undefined,
|
|
466
|
+
hasWithdrawMemo: false
|
|
467
|
+
}] : []),
|
|
370
468
|
image: '/img/tokens/xxlm.png'
|
|
371
469
|
}, {
|
|
372
470
|
allowSwap: IS_MAINNET,
|
|
@@ -390,7 +488,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
390
488
|
xtokenSymbol: 'XDOT',
|
|
391
489
|
xtokenPrecision: 8,
|
|
392
490
|
xtokenContract: 'xtokens',
|
|
393
|
-
wallets: [{
|
|
491
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
394
492
|
wallet: 'DOT',
|
|
395
493
|
symbol: 'DOT',
|
|
396
494
|
chain: exports.Chains.PolkadotMainnet,
|
|
@@ -398,11 +496,11 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
398
496
|
precision: 10,
|
|
399
497
|
contract: undefined,
|
|
400
498
|
hasWithdrawMemo: false
|
|
401
|
-
}],
|
|
499
|
+
}] : []),
|
|
402
500
|
image: '/img/tokens/xdot.png'
|
|
403
501
|
}, {
|
|
404
502
|
allowSwap: true,
|
|
405
|
-
allowBridge:
|
|
503
|
+
allowBridge: IS_MAINNET,
|
|
406
504
|
allowLend: false,
|
|
407
505
|
allowBorrow: false,
|
|
408
506
|
name: 'Binance Coin',
|
|
@@ -410,7 +508,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
410
508
|
xtokenSymbol: 'XBNB',
|
|
411
509
|
xtokenPrecision: 8,
|
|
412
510
|
xtokenContract: 'xtokens',
|
|
413
|
-
wallets: [{
|
|
511
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
414
512
|
wallet: 'BNB',
|
|
415
513
|
symbol: 'BNB',
|
|
416
514
|
chain: exports.Chains.BinanceBEP20,
|
|
@@ -418,7 +516,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
418
516
|
precision: 18,
|
|
419
517
|
contract: undefined,
|
|
420
518
|
hasWithdrawMemo: false
|
|
421
|
-
}],
|
|
519
|
+
}] : []),
|
|
422
520
|
image: '/img/tokens/xbnb.png'
|
|
423
521
|
}, {
|
|
424
522
|
allowSwap: true,
|
|
@@ -430,7 +528,7 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
430
528
|
xtokenSymbol: 'XEOS',
|
|
431
529
|
xtokenPrecision: 4,
|
|
432
530
|
xtokenContract: 'xtokens',
|
|
433
|
-
wallets: [{
|
|
531
|
+
wallets: [].concat(IS_MAINNET ? [{
|
|
434
532
|
wallet: 'EOS',
|
|
435
533
|
symbol: 'EOS',
|
|
436
534
|
chain: exports.Chains.EosMainnet,
|
|
@@ -438,8 +536,36 @@ var initializeCoins = function initializeCoins(protonChain) {
|
|
|
438
536
|
precision: 4,
|
|
439
537
|
contract: undefined,
|
|
440
538
|
hasWithdrawMemo: true
|
|
441
|
-
}],
|
|
539
|
+
}] : [], IS_TESTNET ? [{
|
|
540
|
+
wallet: 'EOS',
|
|
541
|
+
symbol: 'EOS',
|
|
542
|
+
chain: exports.Chains.EosTestnet,
|
|
543
|
+
network: exports.Networks.Testnet,
|
|
544
|
+
precision: 4,
|
|
545
|
+
contract: undefined,
|
|
546
|
+
hasWithdrawMemo: true
|
|
547
|
+
}] : []),
|
|
442
548
|
image: '/img/tokens/xeos.png'
|
|
549
|
+
}, {
|
|
550
|
+
allowSwap: false,
|
|
551
|
+
allowBridge: false,
|
|
552
|
+
allowLend: false,
|
|
553
|
+
allowBorrow: false,
|
|
554
|
+
name: 'HBAR',
|
|
555
|
+
coin: 'HBAR',
|
|
556
|
+
xtokenSymbol: 'XHBAR',
|
|
557
|
+
xtokenPrecision: 8,
|
|
558
|
+
xtokenContract: 'xtokens',
|
|
559
|
+
wallets: [].concat(IS_TESTNET ? [{
|
|
560
|
+
wallet: 'HBAR',
|
|
561
|
+
symbol: 'HBAR',
|
|
562
|
+
chain: exports.Chains.HederaTestnet,
|
|
563
|
+
network: exports.Networks.Testnet,
|
|
564
|
+
precision: 8,
|
|
565
|
+
contract: undefined,
|
|
566
|
+
hasWithdrawMemo: true
|
|
567
|
+
}] : []),
|
|
568
|
+
image: '/img/tokens/xhbar.png'
|
|
443
569
|
}, // Synthethic
|
|
444
570
|
{
|
|
445
571
|
allowSwap: IS_MAINNET,
|
|
@@ -721,7 +847,8 @@ var withdrawBodyParser = /*#__PURE__*/z.object({
|
|
|
721
847
|
authorization: z.array(authorizationParser).min(1)
|
|
722
848
|
})).min(1)
|
|
723
849
|
})),
|
|
724
|
-
quoteId: /*#__PURE__*/z.string()
|
|
850
|
+
quoteId: /*#__PURE__*/z.string(),
|
|
851
|
+
provider: /*#__PURE__*/z.string().optional()
|
|
725
852
|
});
|
|
726
853
|
var withdrawMetalResponseParser = /*#__PURE__*/z.object({
|
|
727
854
|
success: /*#__PURE__*/z.boolean(),
|