@tria-sdk/constants 1.0.41 → 1.0.43

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,20 +1,4 @@
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
+ export * from "./src/config";
2
+ export * from "./src/chains";
3
+ export * from "./src/txn";
4
+ export * from "./src/connect";
@@ -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,26 +1,30 @@
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.polygonAmoy = exports.sepolia = exports.neoxTestnet = exports.bitlayerMainnet = exports.bitlayerTestnet = exports.zkLinkTestnet = exports.zkLink = void 0;
4
- exports.zkLink = "ZKLINK-NOVA";
5
- exports.zkLinkTestnet = "ZKLINK-NOVA-TESTNET";
6
- exports.bitlayerTestnet = "BITLAYER-TESTNET";
7
- exports.bitlayerMainnet = "BITLAYER-MAINNET";
8
- exports.neoxTestnet = "NEOX-TESTNET";
9
- exports.sepolia = "SEPOLIA";
10
- exports.polygonAmoy = "AMOY";
11
- 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 = [
12
15
  "MUMBAI",
13
16
  "FUSESPARK",
14
17
  "MANTA-TESTNET",
15
18
  "METIS-TESTNET",
16
19
  "MANTLE-TESTNET",
17
- exports.zkLinkTestnet,
18
- exports.bitlayerTestnet,
19
- exports.neoxTestnet,
20
- exports.sepolia,
21
- exports.polygonAmoy,
20
+ zkLinkTestnet,
21
+ bitlayerTestnet,
22
+ neoxTestnet,
23
+ sepolia,
24
+ polygonAmoy,
25
+ vanarTestnet,
22
26
  ];
23
- exports.SUPPORTED_EVM_CHAINS = [
27
+ export const SUPPORTED_EVM_CHAINS = [
24
28
  "ETH",
25
29
  "POLYGON",
26
30
  "AVALANCHE",
@@ -37,15 +41,16 @@ exports.SUPPORTED_EVM_CHAINS = [
37
41
  "METIS-TESTNET",
38
42
  "MANTLE",
39
43
  "MANTLE-TESTNET",
40
- exports.zkLink,
41
- exports.zkLinkTestnet,
42
- exports.bitlayerTestnet,
43
- exports.bitlayerMainnet,
44
- exports.neoxTestnet,
45
- exports.sepolia,
46
- exports.polygonAmoy,
44
+ zkLink,
45
+ zkLinkTestnet,
46
+ bitlayerTestnet,
47
+ bitlayerMainnet,
48
+ neoxTestnet,
49
+ sepolia,
50
+ polygonAmoy,
51
+ vanarTestnet,
47
52
  ];
48
- exports.AA_SUPPORTED_EVM_CHAINS = [
53
+ export const AA_SUPPORTED_EVM_CHAINS = [
49
54
  // "ETH",
50
55
  "POLYGON",
51
56
  // "AVALANCHE",
@@ -55,13 +60,13 @@ exports.AA_SUPPORTED_EVM_CHAINS = [
55
60
  "FUSE",
56
61
  "MUMBAI",
57
62
  // "MANTLE",
58
- exports.sepolia,
63
+ sepolia,
59
64
  "OPTIMISM",
60
65
  "ARBITRUM",
61
66
  "AVALANCHE",
62
67
  "MANTLE",
63
68
  ];
64
- exports.ALLCHAINS = [
69
+ export const ALLCHAINS = [
65
70
  "ETH",
66
71
  "POLYGON",
67
72
  "AVALANCHE",
@@ -79,24 +84,25 @@ exports.ALLCHAINS = [
79
84
  "MANTLE",
80
85
  "MANTLE-TESTNET",
81
86
  "SOLANA",
82
- exports.zkLink,
83
- exports.zkLinkTestnet,
84
- exports.bitlayerTestnet,
85
- exports.bitlayerMainnet,
86
- exports.neoxTestnet,
87
- exports.sepolia,
88
- exports.polygonAmoy,
87
+ zkLink,
88
+ zkLinkTestnet,
89
+ bitlayerTestnet,
90
+ bitlayerMainnet,
91
+ neoxTestnet,
92
+ sepolia,
93
+ polygonAmoy,
94
+ vanarTestnet,
89
95
  ];
90
96
  const baseLogoUrl = "https://static.tria.so/chain-logo-w";
91
97
  const baseLogoUrlBlack = "https://static.tria.so/chain-logo-b";
92
- exports.networks = [
98
+ export const networks = [
93
99
  {
94
100
  chainName: "ETH",
95
101
  logo: `${baseLogoUrl}/Ethereum.webp`,
96
102
  type: "mainnet",
97
103
  },
98
104
  {
99
- chainName: exports.sepolia,
105
+ chainName: sepolia,
100
106
  logo: `${baseLogoUrl}/Ethereum.webp`,
101
107
  type: "testnet",
102
108
  },
@@ -111,7 +117,7 @@ exports.networks = [
111
117
  type: "mainnet",
112
118
  },
113
119
  {
114
- chainName: exports.polygonAmoy,
120
+ chainName: polygonAmoy,
115
121
  logo: `${baseLogoUrl}/Polygon.svg`,
116
122
  type: "testnet",
117
123
  },
@@ -190,37 +196,42 @@ exports.networks = [
190
196
  type: "mainnet",
191
197
  },
192
198
  {
193
- chainName: exports.zkLink,
199
+ chainName: zkLink,
194
200
  logo: `${baseLogoUrl}/zklink.webp`,
195
201
  type: "mainnet",
196
202
  },
197
203
  {
198
- chainName: exports.zkLinkTestnet,
204
+ chainName: zkLinkTestnet,
199
205
  logo: `${baseLogoUrl}/zklink.webp`,
200
206
  type: "testnet",
201
207
  },
202
208
  {
203
- chainName: exports.bitlayerTestnet,
209
+ chainName: bitlayerTestnet,
204
210
  logo: `${baseLogoUrl}/bitlayer.webp`,
205
211
  type: "testnet",
206
212
  },
207
213
  {
208
- chainName: exports.bitlayerMainnet,
214
+ chainName: bitlayerMainnet,
209
215
  logo: `${baseLogoUrl}/bitlayer.webp`,
210
216
  type: "mainnet",
211
217
  },
212
218
  {
213
- chainName: exports.neoxTestnet,
219
+ chainName: neoxTestnet,
214
220
  logo: `${baseLogoUrl}/Neo.webp`,
215
221
  type: "testnet",
216
222
  },
223
+ {
224
+ chainName: vanarTestnet,
225
+ logo: "https://vanguard.vanarchain.com/assets/vanry-logo.png", //`${baseLogoUrl}/Vanguard.webp`,
226
+ type: "testnet",
227
+ },
217
228
  ];
218
- exports.chainNameToLogo = {
229
+ export const chainNameToLogo = {
219
230
  ETH: `${baseLogoUrl}/Ethereum.webp`,
220
- [exports.sepolia]: `${baseLogoUrl}/Ethereum.webp`,
231
+ [sepolia]: `${baseLogoUrl}/Ethereum.webp`,
221
232
  FANTOM: `${baseLogoUrl}/Fantom.webp`,
222
233
  POLYGON: `${baseLogoUrl}/Polygon.webp`,
223
- [exports.polygonAmoy]: `${baseLogoUrl}/Polygon.webp`,
234
+ [polygonAmoy]: `${baseLogoUrl}/Polygon.webp`,
224
235
  AVALANCHE: `${baseLogoUrl}/Avalanche.webp`,
225
236
  OPTIMISM: `${baseLogoUrl}/Optimism.webp`,
226
237
  ARBITRUM: `${baseLogoUrl}/Arbitrum.webp`,
@@ -236,19 +247,20 @@ exports.chainNameToLogo = {
236
247
  MANTLE: `${baseLogoUrl}/Mantle.webp`,
237
248
  "MANTLE-TESTNET": `${baseLogoUrl}/Mantle.webp`,
238
249
  SOLANA: `${baseLogoUrl}/Solana.webp`,
239
- [exports.zkLink]: `${baseLogoUrl}/zklink.webp`,
240
- [exports.zkLinkTestnet]: `${baseLogoUrl}/zklink.webp`,
241
- [exports.bitlayerTestnet]: `${baseLogoUrl}/bitlayer.webp`,
242
- [exports.bitlayerMainnet]: `${baseLogoUrl}/bitlayer.webp`,
243
- [exports.neoxTestnet]: `${baseLogoUrl}/Neo.webp`,
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`,
244
256
  };
245
- exports.chainNameToLogoBlack = {
257
+ export const chainNameToLogoBlack = {
246
258
  ETH: `${baseLogoUrlBlack}/Ethereum.webp`,
247
- [exports.sepolia]: `${baseLogoUrlBlack}/Ethereum.webp`,
259
+ [sepolia]: `${baseLogoUrlBlack}/Ethereum.webp`,
248
260
  BINANCE: `${baseLogoUrlBlack}/binance.webp`,
249
261
  FANTOM: `${baseLogoUrlBlack}/Fantom.webp`,
250
262
  POLYGON: `${baseLogoUrlBlack}/Polygon.webp`,
251
- [exports.polygonAmoy]: `${baseLogoUrlBlack}/Polygon.webp`,
263
+ [polygonAmoy]: `${baseLogoUrlBlack}/Polygon.webp`,
252
264
  AVALANCHE: `${baseLogoUrlBlack}/Avalanche.webp`,
253
265
  OPTIMISM: `${baseLogoUrlBlack}/Optimism.webp`,
254
266
  ARBITRUM: `${baseLogoUrlBlack}/Arbitrum.webp`,
@@ -263,9 +275,10 @@ exports.chainNameToLogoBlack = {
263
275
  MANTLE: `${baseLogoUrlBlack}/Mantle.webp`,
264
276
  "MANTLE-TESTNET": `${baseLogoUrlBlack}/Mantle.webp`,
265
277
  SOLANA: `${baseLogoUrlBlack}/Solana.webp`,
266
- [exports.zkLink]: `${baseLogoUrlBlack}/zklink.webp`,
267
- [exports.zkLinkTestnet]: `${baseLogoUrlBlack}/zklink.webp`,
268
- [exports.bitlayerTestnet]: `${baseLogoUrlBlack}/bitlayer.webp`,
269
- [exports.bitlayerMainnet]: `${baseLogoUrlBlack}/bitlayer.webp`,
270
- [exports.neoxTestnet]: `${baseLogoUrlBlack}/Neo.png`,
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`,
271
284
  };
@@ -1,21 +1,14 @@
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);
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
- exports.isEvmChain = isEvmChain;
10
- const isAaSupportedChain = (chainName) => {
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
- exports.isAaSupportedChain = isAaSupportedChain;
14
- const isChainSupported = (chainName) => {
15
- return chains_1.ALLCHAINS.includes(chainName);
9
+ export const isChainSupported = (chainName) => {
10
+ return ALLCHAINS.includes(chainName);
16
11
  };
17
- exports.isChainSupported = isChainSupported;
18
- const isTestnetChain = (chainName) => {
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;
@@ -1,7 +1,4 @@
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 = {
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
- exports.TRIA_WALLET_STORE = "tria.wallet.store";
22
- exports.TRIA_WALLET_SELECTED_CHAIN = "tria.wallet.selectedChain";
23
- exports.storageKeys = {
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
- exports.triaAuthUrl = "https://auth.tria.so";
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.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,12 +1,9 @@
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 = {
1
+ import { bitlayerTestnet, bitlayerMainnet, neoxTestnet, polygonAmoy, sepolia, zkLink, zkLinkTestnet, vanarTestnet, } from "./chains";
2
+ export const explorerBaseUrls = {
6
3
  ETH: "https://etherscan.io",
7
- [chains_1.sepolia]: "https://sepolia.etherscan.io",
4
+ [sepolia]: "https://sepolia.etherscan.io",
8
5
  POLYGON: "https://polygonscan.com",
9
- [chains_1.polygonAmoy]: "https://www.oklink.com/amoy",
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,44 +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
- [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",
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",
33
31
  };
34
- exports.txnBaseUrl = {
35
- ETH: `${exports.explorerBaseUrls.ETH}/tx`, // /txHash
36
- [chains_1.sepolia]: `${exports.explorerBaseUrls[chains_1.sepolia]}/tx`,
37
- POLYGON: `${exports.explorerBaseUrls.POLYGON}/tx`,
38
- [chains_1.polygonAmoy]: `${exports.explorerBaseUrls[chains_1.polygonAmoy]}/tx`,
39
- AVALANCHE: `${exports.explorerBaseUrls.AVALANCHE}/tx`,
40
- ARBITRUM: `${exports.explorerBaseUrls.ARBITRUM}/tx`,
41
- BINANCE: `${exports.explorerBaseUrls.BINANCE}/tx`,
42
- OPTIMISM: `${exports.explorerBaseUrls.OPTIMISM}/tx`,
43
- FANTOM: `${exports.explorerBaseUrls.FANTOM}/tx`,
44
- FUSE: `${exports.explorerBaseUrls.FUSE}/tx`,
45
- FUSESPARK: `${exports.explorerBaseUrls.FUSESPARK}/tx`,
46
- MUMBAI: `${exports.explorerBaseUrls.MUMBAI}/tx`,
47
- METIS: `${exports.explorerBaseUrls.METIS}/tx`,
48
- "METIS-TESTNET": `${exports.explorerBaseUrls["METIS-TESTNET"]}/tx`,
49
- MANTLE: `${exports.explorerBaseUrls.MANTLE}/tx`,
50
- "MANTLE-TESTNET": `${exports.explorerBaseUrls["MANTLE-TESTNET"]}/tx`,
51
- MANTA: `${exports.explorerBaseUrls.MANTA}/tx`,
52
- "MANTA-TESTNET": `${exports.explorerBaseUrls["MANTA-TESTNET"]}/tx`,
53
- [chains_1.zkLink]: `${exports.explorerBaseUrls[chains_1.zkLink]}/tx`,
54
- [chains_1.zkLinkTestnet]: `${exports.explorerBaseUrls[chains_1.zkLinkTestnet]}/tx`,
55
- [chains_1.bitlayerTestnet]: `${exports.explorerBaseUrls[chains_1.bitlayerTestnet]}/tx`,
56
- [chains_1.bitlayerMainnet]: `${exports.explorerBaseUrls[chains_1.bitlayerMainnet]}/tx`,
57
- [chains_1.neoxTestnet]: `${exports.explorerBaseUrls[chains_1.neoxTestnet]}/tx`,
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`,
58
57
  };
59
- exports.nativeTokenDetails = {
58
+ export const nativeTokenDetails = {
60
59
  ETH: {
61
60
  name: "Ether",
62
61
  symbol: "ETH",
63
62
  logoUrl: "https://www.datocms-assets.com/86369/1669619533-ethereum.png",
64
63
  },
65
- [chains_1.sepolia]: {
64
+ [sepolia]: {
66
65
  name: "Ether",
67
66
  symbol: "ETH",
68
67
  logoUrl: "https://www.datocms-assets.com/86369/1669619533-ethereum.png",
@@ -72,7 +71,7 @@ exports.nativeTokenDetails = {
72
71
  symbol: "MATIC",
73
72
  logoUrl: "https://logos.covalenthq.com/tokens/1/0x7d1afa7b718fb893db30a3abc0cfc608aacfebb0.png",
74
73
  },
75
- [chains_1.polygonAmoy]: {
74
+ [polygonAmoy]: {
76
75
  name: "Matic Token",
77
76
  symbol: "MATIC",
78
77
  logoUrl: "https://logos.covalenthq.com/tokens/1/0x7d1afa7b718fb893db30a3abc0cfc608aacfebb0.png",
@@ -152,37 +151,42 @@ exports.nativeTokenDetails = {
152
151
  symbol: "SOL",
153
152
  logoUrl: "https://static.tria.so/chain-logo-w/Solana.webp",
154
153
  },
155
- [chains_1.zkLink]: {
154
+ [zkLink]: {
156
155
  name: "Ether",
157
156
  symbol: "ETH",
158
157
  logoUrl: "https://static.tria.so/chain-logo-w/zklink.webp",
159
158
  },
160
- [chains_1.zkLinkTestnet]: {
159
+ [zkLinkTestnet]: {
161
160
  name: "Ether",
162
161
  symbol: "ETH",
163
162
  logoUrl: "https://static.tria.so/chain-logo-w/zklink.webp",
164
163
  },
165
- [chains_1.bitlayerTestnet]: {
164
+ [bitlayerTestnet]: {
166
165
  name: "Bitcoin",
167
166
  symbol: "BTC",
168
167
  logoUrl: "https://static.tria.so/chain-logo-w/bitlayer.webp",
169
168
  },
170
- [chains_1.bitlayerMainnet]: {
169
+ [bitlayerMainnet]: {
171
170
  name: "Bitcoin",
172
171
  symbol: "BTC",
173
172
  logoUrl: "https://static.tria.so/chain-logo-w/bitlayer.webp",
174
173
  },
175
- [chains_1.neoxTestnet]: {
174
+ [neoxTestnet]: {
176
175
  name: "Gas",
177
176
  symbol: "GAS",
178
177
  logoUrl: "https://assets.coingecko.com/coins/images/858/standard/GAS_512_512.png?1696501992",
179
178
  },
179
+ [vanarTestnet]: {
180
+ name: "Vanry",
181
+ symbol: "VG",
182
+ logoUrl: "https://explorer-vanguard.vanarchain.com/assets/network_icon_dark.svg",
183
+ },
180
184
  };
181
185
  const alchemyKey = "kcuWVV9ss_iLWJ2Lw6xdHbmtZYixfY7Z";
182
- exports.rpcUrls = {
186
+ export const rpcUrls = {
183
187
  MUMBAI: `https://polygon-mumbai.g.alchemy.com/v2/${alchemyKey}`, //'https://polygon-mumbai.blockpi.network/v1/rpc/public',
184
- [chains_1.polygonAmoy]: `https://polygon-amoy.g.alchemy.com/v2/${alchemyKey}`,
185
- [chains_1.sepolia]: `https://eth-sepolia.g.alchemy.com/v2/${alchemyKey}`,
188
+ [polygonAmoy]: `https://polygon-amoy.g.alchemy.com/v2/${alchemyKey}`,
189
+ [sepolia]: `https://eth-sepolia.g.alchemy.com/v2/${alchemyKey}`,
186
190
  ETH: "https://eth.llamarpc.com",
187
191
  POLYGON: `https://polygon-mainnet.g.alchemy.com/v2/${alchemyKey}`, // 'https://polygon.llamarpc.com',
188
192
  AVALANCHE: "https://avalanche-c-chain.publicnode.com",
@@ -198,16 +202,17 @@ exports.rpcUrls = {
198
202
  "METIS-TESTNET": "https://goerli.gateway.metisdevops.link",
199
203
  MANTLE: "https://rpc.mantle.xyz",
200
204
  "MANTLE-TESTNET": "https://rpc.testnet.mantle.xyz",
201
- [chains_1.zkLink]: "https://rpc.zklink.io",
202
- [chains_1.zkLinkTestnet]: "https://goerli.rpc.zklink.io",
203
- [chains_1.bitlayerTestnet]: "https://testnet-rpc.bitlayer.org",
204
- [chains_1.bitlayerMainnet]: "https://rpc.bitlayer.org",
205
- [chains_1.neoxTestnet]: "https://neoxseed1.ngd.network",
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",
206
211
  };
207
- exports.chainNameToChainId = {
212
+ export const chainNameToChainId = {
208
213
  MUMBAI: 80001,
209
- [chains_1.polygonAmoy]: 80002,
210
- [chains_1.sepolia]: 11155111,
214
+ [polygonAmoy]: 80002,
215
+ [sepolia]: 11155111,
211
216
  POLYGON: 137,
212
217
  ETH: 1,
213
218
  AVALANCHE: 43114,
@@ -223,16 +228,17 @@ exports.chainNameToChainId = {
223
228
  "METIS-TESTNET": 599,
224
229
  MANTLE: 5000,
225
230
  "MANTLE-TESTNET": 5001,
226
- [chains_1.zkLink]: 810180,
227
- [chains_1.zkLinkTestnet]: 810182,
228
- [chains_1.bitlayerTestnet]: 200810,
229
- [chains_1.bitlayerMainnet]: 200901,
230
- [chains_1.neoxTestnet]: 12227330,
231
+ [zkLink]: 810180,
232
+ [zkLinkTestnet]: 810182,
233
+ [bitlayerTestnet]: 200810,
234
+ [bitlayerMainnet]: 200901,
235
+ [neoxTestnet]: 12227330,
236
+ [vanarTestnet]: 78600,
231
237
  };
232
- exports.chainIdToChainName = {
238
+ export const chainIdToChainName = {
233
239
  80001: "MUMBAI",
234
- 80002: chains_1.polygonAmoy,
235
- 11155111: chains_1.sepolia,
240
+ 80002: polygonAmoy,
241
+ 11155111: sepolia,
236
242
  137: "POLYGON",
237
243
  1: "ETH",
238
244
  43114: "AVALANCHE",
@@ -248,9 +254,10 @@ exports.chainIdToChainName = {
248
254
  599: "METIS-TESTNET",
249
255
  169: "MANTA",
250
256
  3441005: "MANTA-TESTNET",
251
- 810180: chains_1.zkLink,
252
- 810182: chains_1.zkLinkTestnet,
253
- 200810: chains_1.bitlayerTestnet,
254
- 200901: chains_1.bitlayerMainnet,
255
- 12227330: chains_1.neoxTestnet,
257
+ 810180: zkLink,
258
+ 810182: zkLinkTestnet,
259
+ 200810: bitlayerTestnet,
260
+ 200901: bitlayerMainnet,
261
+ 12227330: neoxTestnet,
262
+ 78600: vanarTestnet,
256
263
  };
package/package.json CHANGED
@@ -1,18 +1,18 @@
1
1
  {
2
2
  "name": "@tria-sdk/constants",
3
- "version": "1.0.41",
3
+ "version": "1.0.43",
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": "CommonJS", // "CommonJS",
4
+ "module": "ES6", // "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
- // };