@cryptorubic/web3 1.0.2-alpha-rub-1224.0 → 1.0.2-alpha-rub-1224.1
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/package.json
CHANGED
|
@@ -20,10 +20,6 @@ class EvmAdapter extends abstract_adapter_1.AbstractAdapter {
|
|
|
20
20
|
return this.needApprove(token, contractAddress, walletAddress, amount);
|
|
21
21
|
}
|
|
22
22
|
async handlePreswap(contractAddress, walletAddress, tokenAmount) {
|
|
23
|
-
// const approveAmount =
|
|
24
|
-
// this.blockchain === BLOCKCHAIN_NAME.GNOSIS || this.blockchain === BLOCKCHAIN_NAME.CRONOS
|
|
25
|
-
// ? tokenAmount.stringWeiAmount
|
|
26
|
-
// : tokenAmount.stringTokenAmount;
|
|
27
23
|
const approveAmount = tokenAmount.stringTokenAmount;
|
|
28
24
|
const isNative = web3_pure_1.Web3Pure.isNativeAddress(this.blockchain, tokenAmount.address);
|
|
29
25
|
const fromTokenAddress = isNative && tokenAmount.blockchain === core_1.BLOCKCHAIN_NAME.METIS
|
|
@@ -237,25 +237,6 @@ exports.viemConfig = {
|
|
|
237
237
|
}
|
|
238
238
|
}
|
|
239
239
|
}),
|
|
240
|
-
// CRONOS: defineChain({
|
|
241
|
-
// blockExplorers: {
|
|
242
|
-
// default: {
|
|
243
|
-
// apiUrl: 'https://cronoscan.com/',
|
|
244
|
-
// name: 'CRONOS Explorer',
|
|
245
|
-
// url: 'https://cronoscan.com/'
|
|
246
|
-
// }
|
|
247
|
-
// },
|
|
248
|
-
// id: 25,
|
|
249
|
-
// name: 'Cronos Mainnet Beta',
|
|
250
|
-
// nativeCurrency: { decimals: 18, name: 'CRO', symbol: 'CRO' },
|
|
251
|
-
// rpcUrls: { default: { http: ['https://evm.cronos.org'] } },
|
|
252
|
-
// testnet: false,
|
|
253
|
-
// contracts: {
|
|
254
|
-
// multicall3: {
|
|
255
|
-
// address: '0x5e954f5972EC6BFc7dECd75779F10d848230345F'
|
|
256
|
-
// }
|
|
257
|
-
// }
|
|
258
|
-
// }),
|
|
259
240
|
MUMBAI: (0, viem_1.defineChain)({
|
|
260
241
|
blockExplorers: {
|
|
261
242
|
default: {
|
|
@@ -277,25 +258,6 @@ exports.viemConfig = {
|
|
|
277
258
|
}
|
|
278
259
|
}
|
|
279
260
|
}),
|
|
280
|
-
// GNOSIS: defineChain({
|
|
281
|
-
// blockExplorers: {
|
|
282
|
-
// default: {
|
|
283
|
-
// apiUrl: 'https://blockscout.com/xdai/mainnet/',
|
|
284
|
-
// name: 'GNOSIS Explorer',
|
|
285
|
-
// url: 'https://blockscout.com/xdai/mainnet/'
|
|
286
|
-
// }
|
|
287
|
-
// },
|
|
288
|
-
// id: 100,
|
|
289
|
-
// name: 'Gnosis Chain',
|
|
290
|
-
// nativeCurrency: { decimals: 18, name: 'xDAI', symbol: 'xDAI' },
|
|
291
|
-
// rpcUrls: { default: { http: ['https://rpc.gnosischain.com'] } },
|
|
292
|
-
// testnet: false,
|
|
293
|
-
// contracts: {
|
|
294
|
-
// multicall3: {
|
|
295
|
-
// address: '0x67dA5f2FfaDDfF067AB9d5F025F8810634d84287'
|
|
296
|
-
// }
|
|
297
|
-
// }
|
|
298
|
-
// }),
|
|
299
261
|
HARMONY: (0, viem_1.defineChain)({
|
|
300
262
|
blockExplorers: {
|
|
301
263
|
default: {
|
|
@@ -1048,25 +1010,6 @@ exports.viemConfig = {
|
|
|
1048
1010
|
}
|
|
1049
1011
|
}
|
|
1050
1012
|
}),
|
|
1051
|
-
// ROOTSTOCK: defineChain({
|
|
1052
|
-
// blockExplorers: {
|
|
1053
|
-
// default: {
|
|
1054
|
-
// apiUrl: 'https://explorer.rsk.co/',
|
|
1055
|
-
// name: 'ROOTSTOCK Explorer',
|
|
1056
|
-
// url: 'https://explorer.rsk.co/'
|
|
1057
|
-
// }
|
|
1058
|
-
// },
|
|
1059
|
-
// id: 30,
|
|
1060
|
-
// name: 'Rootstock',
|
|
1061
|
-
// nativeCurrency: { decimals: 18, name: 'RBTC', symbol: 'RBTC' },
|
|
1062
|
-
// rpcUrls: { default: { http: ['https://public-node.rsk.co'] } },
|
|
1063
|
-
// testnet: false,
|
|
1064
|
-
// contracts: {
|
|
1065
|
-
// multicall3: {
|
|
1066
|
-
// address: '0xcA11bde05977b3631167028862bE2a173976CA11'
|
|
1067
|
-
// }
|
|
1068
|
-
// }
|
|
1069
|
-
// }),
|
|
1070
1013
|
ZK_SYNC: (0, viem_1.defineChain)({
|
|
1071
1014
|
blockExplorers: {
|
|
1072
1015
|
default: {
|
|
@@ -17,9 +17,7 @@ exports.viemBlockchainMapping = {
|
|
|
17
17
|
[core_1.BLOCKCHAIN_NAME.AURORA]: chains_1.aurora,
|
|
18
18
|
[core_1.BLOCKCHAIN_NAME.TELOS]: chains_1.telos,
|
|
19
19
|
[core_1.BLOCKCHAIN_NAME.OPTIMISM]: chains_1.optimism,
|
|
20
|
-
// [BLOCKCHAIN_NAME.CRONOS]: cronos,
|
|
21
20
|
[core_1.BLOCKCHAIN_NAME.OKE_X_CHAIN]: chains_1.okc,
|
|
22
|
-
// [BLOCKCHAIN_NAME.GNOSIS]: gnosis,
|
|
23
21
|
[core_1.BLOCKCHAIN_NAME.FUSE]: chains_1.fuse,
|
|
24
22
|
[core_1.BLOCKCHAIN_NAME.MOONBEAM]: chains_1.moonbeam,
|
|
25
23
|
[core_1.BLOCKCHAIN_NAME.CELO]: chains_1.celo,
|
|
@@ -60,7 +58,6 @@ exports.viemBlockchainMapping = {
|
|
|
60
58
|
[core_1.BLOCKCHAIN_NAME.HOLESKY]: chains_1.holesky,
|
|
61
59
|
[core_1.BLOCKCHAIN_NAME.HORIZEN_EON]: chain_configs_1.viemConfig[core_1.BLOCKCHAIN_NAME.HORIZEN_EON],
|
|
62
60
|
[core_1.BLOCKCHAIN_NAME.MERLIN]: chain_configs_1.viemConfig[core_1.BLOCKCHAIN_NAME.MERLIN],
|
|
63
|
-
// [BLOCKCHAIN_NAME.ROOTSTOCK]: viemConfig[BLOCKCHAIN_NAME.ROOTSTOCK],
|
|
64
61
|
[core_1.BLOCKCHAIN_NAME.MODE]: chains_1.mode,
|
|
65
62
|
[core_1.BLOCKCHAIN_NAME.ZK_FAIR]: chains_1.zkFair,
|
|
66
63
|
[core_1.BLOCKCHAIN_NAME.ZK_LINK]: chain_configs_1.viemConfig[core_1.BLOCKCHAIN_NAME.ZK_LINK],
|