@tria-sdk/constants 1.0.44 → 1.0.45
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +4 -20
- package/dist/src/chains.js +67 -70
- package/dist/src/config.js +10 -17
- package/dist/src/connect.js +5 -8
- package/dist/src/txn.js +71 -74
- package/package.json +1 -1
- package/tsconfig.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,20 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./src/config"), exports);
|
|
18
|
-
__exportStar(require("./src/chains"), exports);
|
|
19
|
-
__exportStar(require("./src/txn"), exports);
|
|
20
|
-
__exportStar(require("./src/connect"), exports);
|
|
1
|
+
export * from "./src/config";
|
|
2
|
+
export * from "./src/chains";
|
|
3
|
+
export * from "./src/txn";
|
|
4
|
+
export * from "./src/connect";
|
package/dist/src/chains.js
CHANGED
|
@@ -1,33 +1,30 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
exports.polygonAmoy = "AMOY";
|
|
16
|
-
exports.vanarTestnet = "VANGUARD-VANAR-TESTNET";
|
|
17
|
-
exports.TESTNET_CHAINS = [
|
|
1
|
+
export const mumbai = "MUMBAI";
|
|
2
|
+
export const polygon = "POLYGON";
|
|
3
|
+
export const ethereum = "ETH";
|
|
4
|
+
export const fuse = "FUSE";
|
|
5
|
+
export const fuseSpark = "FUSESPARK";
|
|
6
|
+
export const zkLink = "ZKLINK-NOVA";
|
|
7
|
+
export const zkLinkTestnet = "ZKLINK-NOVA-TESTNET";
|
|
8
|
+
export const bitlayerTestnet = "BITLAYER-TESTNET";
|
|
9
|
+
export const bitlayerMainnet = "BITLAYER-MAINNET";
|
|
10
|
+
export const neoxTestnet = "NEOX-TESTNET";
|
|
11
|
+
export const sepolia = "SEPOLIA";
|
|
12
|
+
export const polygonAmoy = "AMOY";
|
|
13
|
+
export const vanarTestnet = "VANGUARD-VANAR-TESTNET";
|
|
14
|
+
export const TESTNET_CHAINS = [
|
|
18
15
|
"MUMBAI",
|
|
19
16
|
"FUSESPARK",
|
|
20
17
|
"MANTA-TESTNET",
|
|
21
18
|
"METIS-TESTNET",
|
|
22
19
|
"MANTLE-TESTNET",
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
20
|
+
zkLinkTestnet,
|
|
21
|
+
bitlayerTestnet,
|
|
22
|
+
neoxTestnet,
|
|
23
|
+
sepolia,
|
|
24
|
+
polygonAmoy,
|
|
25
|
+
vanarTestnet,
|
|
29
26
|
];
|
|
30
|
-
|
|
27
|
+
export const SUPPORTED_EVM_CHAINS = [
|
|
31
28
|
"ETH",
|
|
32
29
|
"POLYGON",
|
|
33
30
|
"AVALANCHE",
|
|
@@ -44,16 +41,16 @@ exports.SUPPORTED_EVM_CHAINS = [
|
|
|
44
41
|
"METIS-TESTNET",
|
|
45
42
|
"MANTLE",
|
|
46
43
|
"MANTLE-TESTNET",
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
44
|
+
zkLink,
|
|
45
|
+
zkLinkTestnet,
|
|
46
|
+
bitlayerTestnet,
|
|
47
|
+
bitlayerMainnet,
|
|
48
|
+
neoxTestnet,
|
|
49
|
+
sepolia,
|
|
50
|
+
polygonAmoy,
|
|
51
|
+
vanarTestnet,
|
|
55
52
|
];
|
|
56
|
-
|
|
53
|
+
export const AA_SUPPORTED_EVM_CHAINS = [
|
|
57
54
|
// "ETH",
|
|
58
55
|
"POLYGON",
|
|
59
56
|
// "AVALANCHE",
|
|
@@ -63,13 +60,13 @@ exports.AA_SUPPORTED_EVM_CHAINS = [
|
|
|
63
60
|
"FUSE",
|
|
64
61
|
"MUMBAI",
|
|
65
62
|
// "MANTLE",
|
|
66
|
-
|
|
63
|
+
sepolia,
|
|
67
64
|
"OPTIMISM",
|
|
68
65
|
"ARBITRUM",
|
|
69
66
|
"AVALANCHE",
|
|
70
67
|
"MANTLE",
|
|
71
68
|
];
|
|
72
|
-
|
|
69
|
+
export const ALLCHAINS = [
|
|
73
70
|
"ETH",
|
|
74
71
|
"POLYGON",
|
|
75
72
|
"AVALANCHE",
|
|
@@ -87,25 +84,25 @@ exports.ALLCHAINS = [
|
|
|
87
84
|
"MANTLE",
|
|
88
85
|
"MANTLE-TESTNET",
|
|
89
86
|
"SOLANA",
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
87
|
+
zkLink,
|
|
88
|
+
zkLinkTestnet,
|
|
89
|
+
bitlayerTestnet,
|
|
90
|
+
bitlayerMainnet,
|
|
91
|
+
neoxTestnet,
|
|
92
|
+
sepolia,
|
|
93
|
+
polygonAmoy,
|
|
94
|
+
vanarTestnet,
|
|
98
95
|
];
|
|
99
96
|
const baseLogoUrl = "https://static.tria.so/chain-logo-w";
|
|
100
97
|
const baseLogoUrlBlack = "https://static.tria.so/chain-logo-b";
|
|
101
|
-
|
|
98
|
+
export const networks = [
|
|
102
99
|
{
|
|
103
100
|
chainName: "ETH",
|
|
104
101
|
logo: `${baseLogoUrl}/Ethereum.webp`,
|
|
105
102
|
type: "mainnet",
|
|
106
103
|
},
|
|
107
104
|
{
|
|
108
|
-
chainName:
|
|
105
|
+
chainName: sepolia,
|
|
109
106
|
logo: `${baseLogoUrl}/Ethereum.webp`,
|
|
110
107
|
type: "testnet",
|
|
111
108
|
},
|
|
@@ -120,7 +117,7 @@ exports.networks = [
|
|
|
120
117
|
type: "mainnet",
|
|
121
118
|
},
|
|
122
119
|
{
|
|
123
|
-
chainName:
|
|
120
|
+
chainName: polygonAmoy,
|
|
124
121
|
logo: `${baseLogoUrl}/Polygon.svg`,
|
|
125
122
|
type: "testnet",
|
|
126
123
|
},
|
|
@@ -199,42 +196,42 @@ exports.networks = [
|
|
|
199
196
|
type: "mainnet",
|
|
200
197
|
},
|
|
201
198
|
{
|
|
202
|
-
chainName:
|
|
199
|
+
chainName: zkLink,
|
|
203
200
|
logo: `${baseLogoUrl}/zklink.webp`,
|
|
204
201
|
type: "mainnet",
|
|
205
202
|
},
|
|
206
203
|
{
|
|
207
|
-
chainName:
|
|
204
|
+
chainName: zkLinkTestnet,
|
|
208
205
|
logo: `${baseLogoUrl}/zklink.webp`,
|
|
209
206
|
type: "testnet",
|
|
210
207
|
},
|
|
211
208
|
{
|
|
212
|
-
chainName:
|
|
209
|
+
chainName: bitlayerTestnet,
|
|
213
210
|
logo: `${baseLogoUrl}/bitlayer.webp`,
|
|
214
211
|
type: "testnet",
|
|
215
212
|
},
|
|
216
213
|
{
|
|
217
|
-
chainName:
|
|
214
|
+
chainName: bitlayerMainnet,
|
|
218
215
|
logo: `${baseLogoUrl}/bitlayer.webp`,
|
|
219
216
|
type: "mainnet",
|
|
220
217
|
},
|
|
221
218
|
{
|
|
222
|
-
chainName:
|
|
219
|
+
chainName: neoxTestnet,
|
|
223
220
|
logo: `${baseLogoUrl}/Neo.webp`,
|
|
224
221
|
type: "testnet",
|
|
225
222
|
},
|
|
226
223
|
{
|
|
227
|
-
chainName:
|
|
224
|
+
chainName: vanarTestnet,
|
|
228
225
|
logo: "https://vanguard.vanarchain.com/assets/vanry-logo.png", //`${baseLogoUrl}/Vanguard.webp`,
|
|
229
226
|
type: "testnet",
|
|
230
227
|
},
|
|
231
228
|
];
|
|
232
|
-
|
|
229
|
+
export const chainNameToLogo = {
|
|
233
230
|
ETH: `${baseLogoUrl}/Ethereum.webp`,
|
|
234
|
-
[
|
|
231
|
+
[sepolia]: `${baseLogoUrl}/Ethereum.webp`,
|
|
235
232
|
FANTOM: `${baseLogoUrl}/Fantom.webp`,
|
|
236
233
|
POLYGON: `${baseLogoUrl}/Polygon.webp`,
|
|
237
|
-
[
|
|
234
|
+
[polygonAmoy]: `${baseLogoUrl}/Polygon.webp`,
|
|
238
235
|
AVALANCHE: `${baseLogoUrl}/Avalanche.webp`,
|
|
239
236
|
OPTIMISM: `${baseLogoUrl}/Optimism.webp`,
|
|
240
237
|
ARBITRUM: `${baseLogoUrl}/Arbitrum.webp`,
|
|
@@ -250,20 +247,20 @@ exports.chainNameToLogo = {
|
|
|
250
247
|
MANTLE: `${baseLogoUrl}/Mantle.webp`,
|
|
251
248
|
"MANTLE-TESTNET": `${baseLogoUrl}/Mantle.webp`,
|
|
252
249
|
SOLANA: `${baseLogoUrl}/Solana.webp`,
|
|
253
|
-
[
|
|
254
|
-
[
|
|
255
|
-
[
|
|
256
|
-
[
|
|
257
|
-
[
|
|
258
|
-
[
|
|
250
|
+
[zkLink]: `${baseLogoUrl}/zklink.webp`,
|
|
251
|
+
[zkLinkTestnet]: `${baseLogoUrl}/zklink.webp`,
|
|
252
|
+
[bitlayerTestnet]: `${baseLogoUrl}/bitlayer.webp`,
|
|
253
|
+
[bitlayerMainnet]: `${baseLogoUrl}/bitlayer.webp`,
|
|
254
|
+
[neoxTestnet]: `${baseLogoUrl}/Neo.webp`,
|
|
255
|
+
[vanarTestnet]: "https://vanguard.vanarchain.com/assets/vanry-logo.png", //`${baseLogoUrl}/Vanguard.webp`,
|
|
259
256
|
};
|
|
260
|
-
|
|
257
|
+
export const chainNameToLogoBlack = {
|
|
261
258
|
ETH: `${baseLogoUrlBlack}/Ethereum.webp`,
|
|
262
|
-
[
|
|
259
|
+
[sepolia]: `${baseLogoUrlBlack}/Ethereum.webp`,
|
|
263
260
|
BINANCE: `${baseLogoUrlBlack}/binance.webp`,
|
|
264
261
|
FANTOM: `${baseLogoUrlBlack}/Fantom.webp`,
|
|
265
262
|
POLYGON: `${baseLogoUrlBlack}/Polygon.webp`,
|
|
266
|
-
[
|
|
263
|
+
[polygonAmoy]: `${baseLogoUrlBlack}/Polygon.webp`,
|
|
267
264
|
AVALANCHE: `${baseLogoUrlBlack}/Avalanche.webp`,
|
|
268
265
|
OPTIMISM: `${baseLogoUrlBlack}/Optimism.webp`,
|
|
269
266
|
ARBITRUM: `${baseLogoUrlBlack}/Arbitrum.webp`,
|
|
@@ -278,10 +275,10 @@ exports.chainNameToLogoBlack = {
|
|
|
278
275
|
MANTLE: `${baseLogoUrlBlack}/Mantle.webp`,
|
|
279
276
|
"MANTLE-TESTNET": `${baseLogoUrlBlack}/Mantle.webp`,
|
|
280
277
|
SOLANA: `${baseLogoUrlBlack}/Solana.webp`,
|
|
281
|
-
[
|
|
282
|
-
[
|
|
283
|
-
[
|
|
284
|
-
[
|
|
285
|
-
[
|
|
286
|
-
[
|
|
278
|
+
[zkLink]: `${baseLogoUrlBlack}/zklink.webp`,
|
|
279
|
+
[zkLinkTestnet]: `${baseLogoUrlBlack}/zklink.webp`,
|
|
280
|
+
[bitlayerTestnet]: `${baseLogoUrlBlack}/bitlayer.webp`,
|
|
281
|
+
[bitlayerMainnet]: `${baseLogoUrlBlack}/bitlayer.webp`,
|
|
282
|
+
[neoxTestnet]: `${baseLogoUrlBlack}/Neo.png`,
|
|
283
|
+
[vanarTestnet]: "https://vanguard.vanarchain.com/assets/vanry-logo.png", //`${baseLogoUrlBlack}/Vanguard.png`,
|
|
287
284
|
};
|
package/dist/src/config.js
CHANGED
|
@@ -1,21 +1,14 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
exports.prodApiUrl = "https://prod.tria.so";
|
|
6
|
-
const isEvmChain = (chainName) => {
|
|
7
|
-
return chains_1.SUPPORTED_EVM_CHAINS.includes(chainName);
|
|
1
|
+
import { AA_SUPPORTED_EVM_CHAINS, ALLCHAINS, SUPPORTED_EVM_CHAINS, TESTNET_CHAINS, } from "./chains";
|
|
2
|
+
export const prodApiUrl = "https://prod.tria.so";
|
|
3
|
+
export const isEvmChain = (chainName) => {
|
|
4
|
+
return SUPPORTED_EVM_CHAINS.includes(chainName);
|
|
8
5
|
};
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
return chains_1.AA_SUPPORTED_EVM_CHAINS.includes(chainName);
|
|
6
|
+
export const isAaSupportedChain = (chainName) => {
|
|
7
|
+
return AA_SUPPORTED_EVM_CHAINS.includes(chainName);
|
|
12
8
|
};
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
return chains_1.ALLCHAINS.includes(chainName);
|
|
9
|
+
export const isChainSupported = (chainName) => {
|
|
10
|
+
return ALLCHAINS.includes(chainName);
|
|
16
11
|
};
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
return chains_1.TESTNET_CHAINS.includes(chainName);
|
|
12
|
+
export const isTestnetChain = (chainName) => {
|
|
13
|
+
return TESTNET_CHAINS.includes(chainName);
|
|
20
14
|
};
|
|
21
|
-
exports.isTestnetChain = isTestnetChain;
|
package/dist/src/connect.js
CHANGED
|
@@ -1,7 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.triaAuthUrl = exports.storageKeys = exports.TRIA_WALLET_SELECTED_CHAIN = exports.TRIA_WALLET_STORE = exports.eventTypes = void 0;
|
|
4
|
-
exports.eventTypes = {
|
|
1
|
+
export const eventTypes = {
|
|
5
2
|
logIn: "Log in",
|
|
6
3
|
triaSignUp: "Tria Sign up",
|
|
7
4
|
emailPwSignUp: "Email Pwd Sign up",
|
|
@@ -18,12 +15,12 @@ exports.eventTypes = {
|
|
|
18
15
|
saveToAuth: "Save to Auth Iframe",
|
|
19
16
|
triaStoreSet: "triaStoreSet",
|
|
20
17
|
};
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
18
|
+
export const TRIA_WALLET_STORE = "tria.wallet.store";
|
|
19
|
+
export const TRIA_WALLET_SELECTED_CHAIN = "tria.wallet.selectedChain";
|
|
20
|
+
export const storageKeys = {
|
|
24
21
|
TRIA_WALLET_STORE: "tria.wallet.store",
|
|
25
22
|
TRIA_WALLET_SELECTED_CHAIN: "tria.wallet.selectedChain",
|
|
26
23
|
PERSIST_ROOT: "persist:root",
|
|
27
24
|
};
|
|
28
|
-
|
|
25
|
+
export const triaAuthUrl = "https://auth.tria.so";
|
|
29
26
|
// export const PARENT_URL = document?.referrer || window?.parent?.[0]?.location?.ancestorOrigins?.[0];
|
package/dist/src/txn.js
CHANGED
|
@@ -1,12 +1,9 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
exports.chainIdToChainName = exports.chainNameToChainId = exports.rpcUrls = exports.nativeTokenDetails = exports.txnBaseUrl = exports.explorerBaseUrls = void 0;
|
|
4
|
-
const chains_1 = require("./chains");
|
|
5
|
-
exports.explorerBaseUrls = {
|
|
1
|
+
import { bitlayerTestnet, bitlayerMainnet, neoxTestnet, polygonAmoy, sepolia, zkLink, zkLinkTestnet, vanarTestnet, } from "./chains";
|
|
2
|
+
export const explorerBaseUrls = {
|
|
6
3
|
ETH: "https://etherscan.io",
|
|
7
|
-
[
|
|
4
|
+
[sepolia]: "https://sepolia.etherscan.io",
|
|
8
5
|
POLYGON: "https://polygonscan.com",
|
|
9
|
-
[
|
|
6
|
+
[polygonAmoy]: "https://www.oklink.com/amoy",
|
|
10
7
|
AVALANCHE: "https://snowtrace.io",
|
|
11
8
|
ARBITRUM: "https://arbiscan.io",
|
|
12
9
|
BINANCE: "https://bscscan.com",
|
|
@@ -25,46 +22,46 @@ exports.explorerBaseUrls = {
|
|
|
25
22
|
"MANTLE-TESTNET": "https://explorer.testnet.mantle.xyz",
|
|
26
23
|
MANTA: "https://pacific-explorer.manta.network",
|
|
27
24
|
"MANTA-TESTNET": "https://manta-testnet.calderaexplorer.xyz",
|
|
28
|
-
[
|
|
29
|
-
[
|
|
30
|
-
[
|
|
31
|
-
[
|
|
32
|
-
[
|
|
33
|
-
[
|
|
25
|
+
[zkLink]: "https://explorer.zklink.io",
|
|
26
|
+
[zkLinkTestnet]: "https://goerli.explorer.zklink.io",
|
|
27
|
+
[bitlayerTestnet]: "https://testnet-scan.bitlayer.org/en-us",
|
|
28
|
+
[bitlayerMainnet]: "https://www.btrscan.com",
|
|
29
|
+
[neoxTestnet]: "https://xt2scan.ngd.network",
|
|
30
|
+
[vanarTestnet]: "https://explorer-vanguard.vanarchain.com",
|
|
34
31
|
};
|
|
35
|
-
|
|
36
|
-
ETH: `${
|
|
37
|
-
[
|
|
38
|
-
POLYGON: `${
|
|
39
|
-
[
|
|
40
|
-
AVALANCHE: `${
|
|
41
|
-
ARBITRUM: `${
|
|
42
|
-
BINANCE: `${
|
|
43
|
-
OPTIMISM: `${
|
|
44
|
-
FANTOM: `${
|
|
45
|
-
FUSE: `${
|
|
46
|
-
FUSESPARK: `${
|
|
47
|
-
MUMBAI: `${
|
|
48
|
-
METIS: `${
|
|
49
|
-
"METIS-TESTNET": `${
|
|
50
|
-
MANTLE: `${
|
|
51
|
-
"MANTLE-TESTNET": `${
|
|
52
|
-
MANTA: `${
|
|
53
|
-
"MANTA-TESTNET": `${
|
|
54
|
-
[
|
|
55
|
-
[
|
|
56
|
-
[
|
|
57
|
-
[
|
|
58
|
-
[
|
|
59
|
-
[
|
|
32
|
+
export const txnBaseUrl = {
|
|
33
|
+
ETH: `${explorerBaseUrls.ETH}/tx`, // /txHash
|
|
34
|
+
[sepolia]: `${explorerBaseUrls[sepolia]}/tx`,
|
|
35
|
+
POLYGON: `${explorerBaseUrls.POLYGON}/tx`,
|
|
36
|
+
[polygonAmoy]: `${explorerBaseUrls[polygonAmoy]}/tx`,
|
|
37
|
+
AVALANCHE: `${explorerBaseUrls.AVALANCHE}/tx`,
|
|
38
|
+
ARBITRUM: `${explorerBaseUrls.ARBITRUM}/tx`,
|
|
39
|
+
BINANCE: `${explorerBaseUrls.BINANCE}/tx`,
|
|
40
|
+
OPTIMISM: `${explorerBaseUrls.OPTIMISM}/tx`,
|
|
41
|
+
FANTOM: `${explorerBaseUrls.FANTOM}/tx`,
|
|
42
|
+
FUSE: `${explorerBaseUrls.FUSE}/tx`,
|
|
43
|
+
FUSESPARK: `${explorerBaseUrls.FUSESPARK}/tx`,
|
|
44
|
+
MUMBAI: `${explorerBaseUrls.MUMBAI}/tx`,
|
|
45
|
+
METIS: `${explorerBaseUrls.METIS}/tx`,
|
|
46
|
+
"METIS-TESTNET": `${explorerBaseUrls["METIS-TESTNET"]}/tx`,
|
|
47
|
+
MANTLE: `${explorerBaseUrls.MANTLE}/tx`,
|
|
48
|
+
"MANTLE-TESTNET": `${explorerBaseUrls["MANTLE-TESTNET"]}/tx`,
|
|
49
|
+
MANTA: `${explorerBaseUrls.MANTA}/tx`,
|
|
50
|
+
"MANTA-TESTNET": `${explorerBaseUrls["MANTA-TESTNET"]}/tx`,
|
|
51
|
+
[zkLink]: `${explorerBaseUrls[zkLink]}/tx`,
|
|
52
|
+
[zkLinkTestnet]: `${explorerBaseUrls[zkLinkTestnet]}/tx`,
|
|
53
|
+
[bitlayerTestnet]: `${explorerBaseUrls[bitlayerTestnet]}/tx`,
|
|
54
|
+
[bitlayerMainnet]: `${explorerBaseUrls[bitlayerMainnet]}/tx`,
|
|
55
|
+
[neoxTestnet]: `${explorerBaseUrls[neoxTestnet]}/tx`,
|
|
56
|
+
[vanarTestnet]: `${explorerBaseUrls[vanarTestnet]}/tx`,
|
|
60
57
|
};
|
|
61
|
-
|
|
58
|
+
export const nativeTokenDetails = {
|
|
62
59
|
ETH: {
|
|
63
60
|
name: "Ether",
|
|
64
61
|
symbol: "ETH",
|
|
65
62
|
logoUrl: "https://www.datocms-assets.com/86369/1669619533-ethereum.png",
|
|
66
63
|
},
|
|
67
|
-
[
|
|
64
|
+
[sepolia]: {
|
|
68
65
|
name: "Ether",
|
|
69
66
|
symbol: "ETH",
|
|
70
67
|
logoUrl: "https://www.datocms-assets.com/86369/1669619533-ethereum.png",
|
|
@@ -74,7 +71,7 @@ exports.nativeTokenDetails = {
|
|
|
74
71
|
symbol: "MATIC",
|
|
75
72
|
logoUrl: "https://logos.covalenthq.com/tokens/1/0x7d1afa7b718fb893db30a3abc0cfc608aacfebb0.png",
|
|
76
73
|
},
|
|
77
|
-
[
|
|
74
|
+
[polygonAmoy]: {
|
|
78
75
|
name: "Matic Token",
|
|
79
76
|
symbol: "MATIC",
|
|
80
77
|
logoUrl: "https://logos.covalenthq.com/tokens/1/0x7d1afa7b718fb893db30a3abc0cfc608aacfebb0.png",
|
|
@@ -154,42 +151,42 @@ exports.nativeTokenDetails = {
|
|
|
154
151
|
symbol: "SOL",
|
|
155
152
|
logoUrl: "https://static.tria.so/chain-logo-w/Solana.webp",
|
|
156
153
|
},
|
|
157
|
-
[
|
|
154
|
+
[zkLink]: {
|
|
158
155
|
name: "Ether",
|
|
159
156
|
symbol: "ETH",
|
|
160
157
|
logoUrl: "https://static.tria.so/chain-logo-w/zklink.webp",
|
|
161
158
|
},
|
|
162
|
-
[
|
|
159
|
+
[zkLinkTestnet]: {
|
|
163
160
|
name: "Ether",
|
|
164
161
|
symbol: "ETH",
|
|
165
162
|
logoUrl: "https://static.tria.so/chain-logo-w/zklink.webp",
|
|
166
163
|
},
|
|
167
|
-
[
|
|
164
|
+
[bitlayerTestnet]: {
|
|
168
165
|
name: "Bitcoin",
|
|
169
166
|
symbol: "BTC",
|
|
170
167
|
logoUrl: "https://static.tria.so/chain-logo-w/bitlayer.webp",
|
|
171
168
|
},
|
|
172
|
-
[
|
|
169
|
+
[bitlayerMainnet]: {
|
|
173
170
|
name: "Bitcoin",
|
|
174
171
|
symbol: "BTC",
|
|
175
172
|
logoUrl: "https://static.tria.so/chain-logo-w/bitlayer.webp",
|
|
176
173
|
},
|
|
177
|
-
[
|
|
174
|
+
[neoxTestnet]: {
|
|
178
175
|
name: "Gas",
|
|
179
176
|
symbol: "GAS",
|
|
180
177
|
logoUrl: "https://assets.coingecko.com/coins/images/858/standard/GAS_512_512.png?1696501992",
|
|
181
178
|
},
|
|
182
|
-
[
|
|
179
|
+
[vanarTestnet]: {
|
|
183
180
|
name: "Vanry",
|
|
184
181
|
symbol: "VG",
|
|
185
182
|
logoUrl: "https://explorer-vanguard.vanarchain.com/assets/network_icon_dark.svg",
|
|
186
183
|
},
|
|
187
184
|
};
|
|
188
185
|
const alchemyKey = "kcuWVV9ss_iLWJ2Lw6xdHbmtZYixfY7Z";
|
|
189
|
-
|
|
186
|
+
export const rpcUrls = {
|
|
190
187
|
MUMBAI: `https://polygon-mumbai.g.alchemy.com/v2/${alchemyKey}`, //'https://polygon-mumbai.blockpi.network/v1/rpc/public',
|
|
191
|
-
[
|
|
192
|
-
[
|
|
188
|
+
[polygonAmoy]: `https://polygon-amoy.g.alchemy.com/v2/${alchemyKey}`,
|
|
189
|
+
[sepolia]: `https://eth-sepolia.g.alchemy.com/v2/${alchemyKey}`,
|
|
193
190
|
ETH: "https://eth.llamarpc.com",
|
|
194
191
|
POLYGON: `https://polygon-mainnet.g.alchemy.com/v2/${alchemyKey}`, // 'https://polygon.llamarpc.com',
|
|
195
192
|
AVALANCHE: "https://avalanche-c-chain.publicnode.com",
|
|
@@ -205,17 +202,17 @@ exports.rpcUrls = {
|
|
|
205
202
|
"METIS-TESTNET": "https://goerli.gateway.metisdevops.link",
|
|
206
203
|
MANTLE: "https://rpc.mantle.xyz",
|
|
207
204
|
"MANTLE-TESTNET": "https://rpc.testnet.mantle.xyz",
|
|
208
|
-
[
|
|
209
|
-
[
|
|
210
|
-
[
|
|
211
|
-
[
|
|
212
|
-
[
|
|
213
|
-
[
|
|
205
|
+
[zkLink]: "https://rpc.zklink.io",
|
|
206
|
+
[zkLinkTestnet]: "https://goerli.rpc.zklink.io",
|
|
207
|
+
[bitlayerTestnet]: "https://testnet-rpc.bitlayer.org",
|
|
208
|
+
[bitlayerMainnet]: "https://rpc.bitlayer.org",
|
|
209
|
+
[neoxTestnet]: "https://neoxseed1.ngd.network",
|
|
210
|
+
[vanarTestnet]: "https://rpc-partners-vanguard.vanarchain.com", // "https://rpc-vanguard.vanarchain.com",
|
|
214
211
|
};
|
|
215
|
-
|
|
212
|
+
export const chainNameToChainId = {
|
|
216
213
|
MUMBAI: 80001,
|
|
217
|
-
[
|
|
218
|
-
[
|
|
214
|
+
[polygonAmoy]: 80002,
|
|
215
|
+
[sepolia]: 11155111,
|
|
219
216
|
POLYGON: 137,
|
|
220
217
|
ETH: 1,
|
|
221
218
|
AVALANCHE: 43114,
|
|
@@ -231,17 +228,17 @@ exports.chainNameToChainId = {
|
|
|
231
228
|
"METIS-TESTNET": 599,
|
|
232
229
|
MANTLE: 5000,
|
|
233
230
|
"MANTLE-TESTNET": 5001,
|
|
234
|
-
[
|
|
235
|
-
[
|
|
236
|
-
[
|
|
237
|
-
[
|
|
238
|
-
[
|
|
239
|
-
[
|
|
231
|
+
[zkLink]: 810180,
|
|
232
|
+
[zkLinkTestnet]: 810182,
|
|
233
|
+
[bitlayerTestnet]: 200810,
|
|
234
|
+
[bitlayerMainnet]: 200901,
|
|
235
|
+
[neoxTestnet]: 12227330,
|
|
236
|
+
[vanarTestnet]: 78600,
|
|
240
237
|
};
|
|
241
|
-
|
|
238
|
+
export const chainIdToChainName = {
|
|
242
239
|
80001: "MUMBAI",
|
|
243
|
-
80002:
|
|
244
|
-
11155111:
|
|
240
|
+
80002: polygonAmoy,
|
|
241
|
+
11155111: sepolia,
|
|
245
242
|
137: "POLYGON",
|
|
246
243
|
1: "ETH",
|
|
247
244
|
43114: "AVALANCHE",
|
|
@@ -257,10 +254,10 @@ exports.chainIdToChainName = {
|
|
|
257
254
|
599: "METIS-TESTNET",
|
|
258
255
|
169: "MANTA",
|
|
259
256
|
3441005: "MANTA-TESTNET",
|
|
260
|
-
810180:
|
|
261
|
-
810182:
|
|
262
|
-
200810:
|
|
263
|
-
200901:
|
|
264
|
-
12227330:
|
|
265
|
-
78600:
|
|
257
|
+
810180: zkLink,
|
|
258
|
+
810182: zkLinkTestnet,
|
|
259
|
+
200810: bitlayerTestnet,
|
|
260
|
+
200901: bitlayerMainnet,
|
|
261
|
+
12227330: neoxTestnet,
|
|
262
|
+
78600: vanarTestnet,
|
|
266
263
|
};
|
package/package.json
CHANGED