@tria-sdk/constants 1.0.42 → 1.0.44

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