@railgun-community/shared-models 5.1.0 → 5.1.2

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.
Files changed (54) hide show
  1. package/dist/index.js +18 -2
  2. package/dist/index.js.map +1 -1
  3. package/dist/models/artifact.js +5 -2
  4. package/dist/models/artifact.js.map +1 -1
  5. package/dist/models/blocked-address.js +4 -1
  6. package/dist/models/blocked-address.js.map +1 -1
  7. package/dist/models/function-types.js +2 -1
  8. package/dist/models/index.d.ts +0 -1
  9. package/dist/models/index.js +26 -11
  10. package/dist/models/index.js.map +1 -1
  11. package/dist/models/merkletree-scan.js +5 -2
  12. package/dist/models/merkletree-scan.js.map +1 -1
  13. package/dist/models/network-config.js +35 -32
  14. package/dist/models/network-config.js.map +1 -1
  15. package/dist/models/proof.js +5 -2
  16. package/dist/models/proof.js.map +1 -1
  17. package/dist/models/relayer.js +5 -2
  18. package/dist/models/relayer.js.map +1 -1
  19. package/dist/models/response-types.d.ts +6 -2
  20. package/dist/models/response-types.js +11 -8
  21. package/dist/models/response-types.js.map +1 -1
  22. package/dist/models/transaction.js +2 -1
  23. package/dist/models/wallet.js +5 -2
  24. package/dist/models/wallet.js.map +1 -1
  25. package/dist/utils/artifact-v2.js +13 -5
  26. package/dist/utils/artifact-v2.js.map +1 -1
  27. package/dist/utils/available-rpc.js +11 -7
  28. package/dist/utils/available-rpc.js.map +1 -1
  29. package/dist/utils/compare.js +5 -1
  30. package/dist/utils/compare.js.map +1 -1
  31. package/dist/utils/error.js +5 -1
  32. package/dist/utils/error.js.map +1 -1
  33. package/dist/utils/fallback-provider.js +10 -6
  34. package/dist/utils/fallback-provider.js.map +1 -1
  35. package/dist/utils/format.js +5 -1
  36. package/dist/utils/format.js.map +1 -1
  37. package/dist/utils/gas.js +24 -16
  38. package/dist/utils/gas.js.map +1 -1
  39. package/dist/utils/index.js +26 -10
  40. package/dist/utils/index.js.map +1 -1
  41. package/dist/utils/median.js +5 -1
  42. package/dist/utils/median.js.map +1 -1
  43. package/dist/utils/network.js +7 -3
  44. package/dist/utils/network.js.map +1 -1
  45. package/dist/utils/polling-json-rpc-provider.js +6 -2
  46. package/dist/utils/polling-json-rpc-provider.js.map +1 -1
  47. package/dist/utils/promises.js +10 -4
  48. package/dist/utils/promises.js.map +1 -1
  49. package/dist/utils/versions.js +5 -1
  50. package/dist/utils/versions.js.map +1 -1
  51. package/package.json +1 -1
  52. package/dist/models/fee-token.d.ts +0 -4
  53. package/dist/models/fee-token.js +0 -2
  54. package/dist/models/fee-token.js.map +0 -1
package/dist/index.js CHANGED
@@ -1,3 +1,19 @@
1
- export * from './models';
2
- export * from './utils';
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("./models"), exports);
18
+ __exportStar(require("./utils"), exports);
3
19
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC","sourcesContent":["export * from './models';\nexport * from './utils';\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,2CAAyB;AACzB,0CAAwB","sourcesContent":["export * from './models';\nexport * from './utils';\n"]}
@@ -1,8 +1,11 @@
1
- export var ArtifactName;
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ArtifactName = void 0;
4
+ var ArtifactName;
2
5
  (function (ArtifactName) {
3
6
  ArtifactName["ZKEY"] = "zkey";
4
7
  ArtifactName["WASM"] = "wasm";
5
8
  ArtifactName["VKEY"] = "vkey";
6
9
  ArtifactName["DAT"] = "dat";
7
- })(ArtifactName || (ArtifactName = {}));
10
+ })(ArtifactName = exports.ArtifactName || (exports.ArtifactName = {}));
8
11
  //# sourceMappingURL=artifact.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"artifact.js","sourceRoot":"","sources":["../../src/models/artifact.ts"],"names":[],"mappings":"AAOA,MAAM,CAAN,IAAY,YAKX;AALD,WAAY,YAAY;IACtB,6BAAa,CAAA;IACb,6BAAa,CAAA;IACb,6BAAa,CAAA;IACb,2BAAW,CAAA;AACb,CAAC,EALW,YAAY,KAAZ,YAAY,QAKvB","sourcesContent":["export type Artifact = {\n zkey: ArrayLike<number>;\n wasm: Optional<ArrayLike<number>>;\n dat: Optional<ArrayLike<number>>;\n vkey: object;\n};\n\nexport enum ArtifactName {\n ZKEY = 'zkey',\n WASM = 'wasm',\n VKEY = 'vkey',\n DAT = 'dat',\n}\n\nexport type ArtifactMapping = {\n [name in ArtifactName]: string;\n};\n\nexport type ArtifactDownloadedGroup = {\n [name in ArtifactName]: boolean;\n};\n"]}
1
+ {"version":3,"file":"artifact.js","sourceRoot":"","sources":["../../src/models/artifact.ts"],"names":[],"mappings":";;;AAOA,IAAY,YAKX;AALD,WAAY,YAAY;IACtB,6BAAa,CAAA;IACb,6BAAa,CAAA;IACb,6BAAa,CAAA;IACb,2BAAW,CAAA;AACb,CAAC,EALW,YAAY,GAAZ,oBAAY,KAAZ,oBAAY,QAKvB","sourcesContent":["export type Artifact = {\n zkey: ArrayLike<number>;\n wasm: Optional<ArrayLike<number>>;\n dat: Optional<ArrayLike<number>>;\n vkey: object;\n};\n\nexport enum ArtifactName {\n ZKEY = 'zkey',\n WASM = 'wasm',\n VKEY = 'vkey',\n DAT = 'dat',\n}\n\nexport type ArtifactMapping = {\n [name in ArtifactName]: string;\n};\n\nexport type ArtifactDownloadedGroup = {\n [name in ArtifactName]: boolean;\n};\n"]}
@@ -1,5 +1,8 @@
1
+ "use strict";
1
2
  // NOTE: ENSURE ALL BLOCKED ADDRESSES ARE ENTIRELY LOWERCASE.
2
- export const OFAC_TORNADO_CASH_SANCTIONS_LIST_ETH_ADDRESS = [
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.OFAC_TORNADO_CASH_SANCTIONS_LIST_ETH_ADDRESS = void 0;
5
+ exports.OFAC_TORNADO_CASH_SANCTIONS_LIST_ETH_ADDRESS = [
3
6
  '0x8589427373d6d84e98730d7795d8f6f8731fda16',
4
7
  '0x722122df12d4e14e13ac3b6895a86e84145b6967',
5
8
  '0xdd4c48c0b24039969fc16d1cdf626eab821d3384',
@@ -1 +1 @@
1
- {"version":3,"file":"blocked-address.js","sourceRoot":"","sources":["../../src/models/blocked-address.ts"],"names":[],"mappings":"AAAA,6DAA6D;AAE7D,MAAM,CAAC,MAAM,4CAA4C,GAAG;IAC1D,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;CAC7C,CAAC","sourcesContent":["// NOTE: ENSURE ALL BLOCKED ADDRESSES ARE ENTIRELY LOWERCASE.\n\nexport const OFAC_TORNADO_CASH_SANCTIONS_LIST_ETH_ADDRESS = [\n '0x8589427373d6d84e98730d7795d8f6f8731fda16',\n '0x722122df12d4e14e13ac3b6895a86e84145b6967',\n '0xdd4c48c0b24039969fc16d1cdf626eab821d3384',\n '0xd90e2f925da726b50c4ed8d0fb90ad053324f31b',\n '0xd96f2b1c14db8458374d9aca76e26c3d18364307',\n '0x4736dcf1b7a3d580672cce6e7c65cd5cc9cfba9d',\n '0xd4b88df4d29f5cedd6857912842cff3b20c8cfa3',\n '0x910cbd523d972eb0a6f4cae4618ad62622b39dbf',\n '0xa160cdab225685da1d56aa342ad8841c3b53f291',\n '0xfd8610d20aa15b7b2e3be39b396a1bc3516c7144',\n '0xf60dd140cff0706bae9cd734ac3ae76ad9ebc32a',\n '0x22aaa7720ddd5388a3c0a3333430953c68f1849b',\n '0xba214c1c1928a32bffe790263e38b4af9bfcd659',\n '0xb1c8094b234dce6e03f10a5b673c1d8c69739a00',\n '0x527653ea119f3e6a1f5bd18fbf4714081d7b31ce',\n '0x58e8dcc13be9780fc42e8723d8ead4cf46943df2',\n '0xd691f27f38b395864ea86cfc7253969b409c362d',\n '0xaeaac358560e11f52454d997aaff2c5731b6f8a6',\n '0x1356c899d8c9467c7f71c195612f8a395abf2f0a',\n '0xa60c772958a3ed56c1f15dd055ba37ac8e523a0d',\n '0x169ad27a470d064dede56a2d3ff727986b15d52b',\n '0x0836222f2b2b24a3f36f98668ed8f0b38d1a872f',\n '0xf67721a2d8f736e75a49fdd7fad2e31d8676542a',\n '0x9ad122c22b14202b4490edaf288fdb3c7cb3ff5e',\n '0x905b63fff465b9ffbf41dea908ceb12478ec7601',\n '0x07687e702b410fa43f4cb4af7fa097918ffd2730',\n '0x94a1b5cdb22c43faab4abeb5c74999895464ddaf',\n '0xb541fc07bc7619fd4062a54d96268525cbc6ffef',\n '0xd21be7248e0197ee08e0c20d4a96debdac3d20af',\n '0x12d66f87a04a9e220743712ce6d9bb1b5616b8fc',\n '0x47ce0c6ed5b0ce3d3a51fdb1c52dc66a7c3c2936',\n '0x23773e65ed146a459791799d01336db287f25334',\n '0x610b717796ad172b316836ac95a2ffad065ceab4',\n '0x178169b423a011fff22b9e3f3abea13414ddd0f1',\n '0xbb93e510bbcd0b7beb5a853875f9ec60275cf498',\n '0x2717c5e28cf931547b621a5dddb772ab6a35b701',\n '0x03893a7c7463ae47d46bc7f091665f1893656003',\n '0xca0840578f57fe71599d29375e16783424023357',\n '0x58e8dcc13be9780fc42e8723d8ead4cf46943df2',\n];\n"]}
1
+ {"version":3,"file":"blocked-address.js","sourceRoot":"","sources":["../../src/models/blocked-address.ts"],"names":[],"mappings":";AAAA,6DAA6D;;;AAEhD,QAAA,4CAA4C,GAAG;IAC1D,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;CAC7C,CAAC","sourcesContent":["// NOTE: ENSURE ALL BLOCKED ADDRESSES ARE ENTIRELY LOWERCASE.\n\nexport const OFAC_TORNADO_CASH_SANCTIONS_LIST_ETH_ADDRESS = [\n '0x8589427373d6d84e98730d7795d8f6f8731fda16',\n '0x722122df12d4e14e13ac3b6895a86e84145b6967',\n '0xdd4c48c0b24039969fc16d1cdf626eab821d3384',\n '0xd90e2f925da726b50c4ed8d0fb90ad053324f31b',\n '0xd96f2b1c14db8458374d9aca76e26c3d18364307',\n '0x4736dcf1b7a3d580672cce6e7c65cd5cc9cfba9d',\n '0xd4b88df4d29f5cedd6857912842cff3b20c8cfa3',\n '0x910cbd523d972eb0a6f4cae4618ad62622b39dbf',\n '0xa160cdab225685da1d56aa342ad8841c3b53f291',\n '0xfd8610d20aa15b7b2e3be39b396a1bc3516c7144',\n '0xf60dd140cff0706bae9cd734ac3ae76ad9ebc32a',\n '0x22aaa7720ddd5388a3c0a3333430953c68f1849b',\n '0xba214c1c1928a32bffe790263e38b4af9bfcd659',\n '0xb1c8094b234dce6e03f10a5b673c1d8c69739a00',\n '0x527653ea119f3e6a1f5bd18fbf4714081d7b31ce',\n '0x58e8dcc13be9780fc42e8723d8ead4cf46943df2',\n '0xd691f27f38b395864ea86cfc7253969b409c362d',\n '0xaeaac358560e11f52454d997aaff2c5731b6f8a6',\n '0x1356c899d8c9467c7f71c195612f8a395abf2f0a',\n '0xa60c772958a3ed56c1f15dd055ba37ac8e523a0d',\n '0x169ad27a470d064dede56a2d3ff727986b15d52b',\n '0x0836222f2b2b24a3f36f98668ed8f0b38d1a872f',\n '0xf67721a2d8f736e75a49fdd7fad2e31d8676542a',\n '0x9ad122c22b14202b4490edaf288fdb3c7cb3ff5e',\n '0x905b63fff465b9ffbf41dea908ceb12478ec7601',\n '0x07687e702b410fa43f4cb4af7fa097918ffd2730',\n '0x94a1b5cdb22c43faab4abeb5c74999895464ddaf',\n '0xb541fc07bc7619fd4062a54d96268525cbc6ffef',\n '0xd21be7248e0197ee08e0c20d4a96debdac3d20af',\n '0x12d66f87a04a9e220743712ce6d9bb1b5616b8fc',\n '0x47ce0c6ed5b0ce3d3a51fdb1c52dc66a7c3c2936',\n '0x23773e65ed146a459791799d01336db287f25334',\n '0x610b717796ad172b316836ac95a2ffad065ceab4',\n '0x178169b423a011fff22b9e3f3abea13414ddd0f1',\n '0xbb93e510bbcd0b7beb5a853875f9ec60275cf498',\n '0x2717c5e28cf931547b621a5dddb772ab6a35b701',\n '0x03893a7c7463ae47d46bc7f091665f1893656003',\n '0xca0840578f57fe71599d29375e16783424023357',\n '0x58e8dcc13be9780fc42e8723d8ead4cf46943df2',\n];\n"]}
@@ -1,2 +1,3 @@
1
- export {};
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
2
3
  //# sourceMappingURL=function-types.js.map
@@ -1,6 +1,5 @@
1
1
  export * from './artifact';
2
2
  export * from './blocked-address';
3
- export * from './fee-token';
4
3
  export * from './function-types';
5
4
  export * from './merkletree-scan';
6
5
  export * from './network-config';
@@ -1,12 +1,27 @@
1
- export * from './artifact';
2
- export * from './blocked-address';
3
- export * from './fee-token';
4
- export * from './function-types';
5
- export * from './merkletree-scan';
6
- export * from './network-config';
7
- export * from './proof';
8
- export * from './relayer';
9
- export * from './response-types';
10
- export * from './transaction';
11
- export * from './wallet';
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("./artifact"), exports);
18
+ __exportStar(require("./blocked-address"), exports);
19
+ __exportStar(require("./function-types"), exports);
20
+ __exportStar(require("./merkletree-scan"), exports);
21
+ __exportStar(require("./network-config"), exports);
22
+ __exportStar(require("./proof"), exports);
23
+ __exportStar(require("./relayer"), exports);
24
+ __exportStar(require("./response-types"), exports);
25
+ __exportStar(require("./transaction"), exports);
26
+ __exportStar(require("./wallet"), exports);
12
27
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/models/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC;AAC3B,cAAc,mBAAmB,CAAC;AAClC,cAAc,aAAa,CAAC;AAC5B,cAAc,kBAAkB,CAAC;AACjC,cAAc,mBAAmB,CAAC;AAClC,cAAc,kBAAkB,CAAC;AACjC,cAAc,SAAS,CAAC;AACxB,cAAc,WAAW,CAAC;AAC1B,cAAc,kBAAkB,CAAC;AACjC,cAAc,eAAe,CAAC;AAC9B,cAAc,UAAU,CAAC","sourcesContent":["export * from './artifact';\nexport * from './blocked-address';\nexport * from './fee-token';\nexport * from './function-types';\nexport * from './merkletree-scan';\nexport * from './network-config';\nexport * from './proof';\nexport * from './relayer';\nexport * from './response-types';\nexport * from './transaction';\nexport * from './wallet';\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/models/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,6CAA2B;AAC3B,oDAAkC;AAClC,mDAAiC;AACjC,oDAAkC;AAClC,mDAAiC;AACjC,0CAAwB;AACxB,4CAA0B;AAC1B,mDAAiC;AACjC,gDAA8B;AAC9B,2CAAyB","sourcesContent":["export * from './artifact';\nexport * from './blocked-address';\nexport * from './function-types';\nexport * from './merkletree-scan';\nexport * from './network-config';\nexport * from './proof';\nexport * from './relayer';\nexport * from './response-types';\nexport * from './transaction';\nexport * from './wallet';\n"]}
@@ -1,8 +1,11 @@
1
- export var MerkletreeScanStatus;
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.MerkletreeScanStatus = void 0;
4
+ var MerkletreeScanStatus;
2
5
  (function (MerkletreeScanStatus) {
3
6
  MerkletreeScanStatus["Started"] = "Started";
4
7
  MerkletreeScanStatus["Updated"] = "Updated";
5
8
  MerkletreeScanStatus["Complete"] = "Complete";
6
9
  MerkletreeScanStatus["Incomplete"] = "Incomplete";
7
- })(MerkletreeScanStatus || (MerkletreeScanStatus = {}));
10
+ })(MerkletreeScanStatus = exports.MerkletreeScanStatus || (exports.MerkletreeScanStatus = {}));
8
11
  //# sourceMappingURL=merkletree-scan.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"merkletree-scan.js","sourceRoot":"","sources":["../../src/models/merkletree-scan.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,oBAKX;AALD,WAAY,oBAAoB;IAC9B,2CAAmB,CAAA;IACnB,2CAAmB,CAAA;IACnB,6CAAqB,CAAA;IACrB,iDAAyB,CAAA;AAC3B,CAAC,EALW,oBAAoB,KAApB,oBAAoB,QAK/B","sourcesContent":["export enum MerkletreeScanStatus {\n Started = 'Started',\n Updated = 'Updated',\n Complete = 'Complete',\n Incomplete = 'Incomplete',\n}\n"]}
1
+ {"version":3,"file":"merkletree-scan.js","sourceRoot":"","sources":["../../src/models/merkletree-scan.ts"],"names":[],"mappings":";;;AAAA,IAAY,oBAKX;AALD,WAAY,oBAAoB;IAC9B,2CAAmB,CAAA;IACnB,2CAAmB,CAAA;IACnB,6CAAqB,CAAA;IACrB,iDAAyB,CAAA;AAC3B,CAAC,EALW,oBAAoB,GAApB,4BAAoB,KAApB,4BAAoB,QAK/B","sourcesContent":["export enum MerkletreeScanStatus {\n Started = 'Started',\n Updated = 'Updated',\n Complete = 'Complete',\n Incomplete = 'Incomplete',\n}\n"]}
@@ -1,8 +1,11 @@
1
- import { ChainType, EVMGasType } from './response-types';
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.NETWORK_CONFIG = exports.BaseTokenWrappedAddress = exports.RailgunProxyDeploymentBlock = exports.RelayAdaptContract = exports.RailgunProxyContract = exports.NetworkName = void 0;
4
+ const response_types_1 = require("./response-types");
2
5
  /**
3
6
  * DO NOT CHANGE THESE ENUM STRINGS.
4
7
  */
5
- export var NetworkName;
8
+ var NetworkName;
6
9
  (function (NetworkName) {
7
10
  // Mainnets
8
11
  NetworkName["Railgun"] = "Railgun";
@@ -17,8 +20,8 @@ export var NetworkName;
17
20
  NetworkName["ArbitrumGoerli"] = "Arbitrum_Goerli";
18
21
  // Dev only
19
22
  NetworkName["Hardhat"] = "Hardhat";
20
- })(NetworkName || (NetworkName = {}));
21
- export var RailgunProxyContract;
23
+ })(NetworkName = exports.NetworkName || (exports.NetworkName = {}));
24
+ var RailgunProxyContract;
22
25
  (function (RailgunProxyContract) {
23
26
  RailgunProxyContract["Ethereum"] = "0xfa7093cdd9ee6932b4eb2c9e1cde7ce00b1fa4b9";
24
27
  RailgunProxyContract["BNBChain"] = "0x590162bf4b50f6576a459b75309ee21d92178a10";
@@ -30,8 +33,8 @@ export var RailgunProxyContract;
30
33
  RailgunProxyContract["PolygonMumbai"] = "0x3ee8306321d992483BDC9c69B8F622Ba3FFF05B6";
31
34
  RailgunProxyContract["ArbitrumGoerli"] = "0xA0603e598F9Ac2fc7475a3fA08D0794066615D9a";
32
35
  RailgunProxyContract["Hardhat"] = "0x610178dA211FEF7D417bC0e6FeD39F05609AD788";
33
- })(RailgunProxyContract || (RailgunProxyContract = {}));
34
- export var RelayAdaptContract;
36
+ })(RailgunProxyContract = exports.RailgunProxyContract || (exports.RailgunProxyContract = {}));
37
+ var RelayAdaptContract;
35
38
  (function (RelayAdaptContract) {
36
39
  RelayAdaptContract["Ethereum"] = "0x4025ee6512DBbda97049Bcf5AA5D38C54aF6bE8a";
37
40
  RelayAdaptContract["BNBChain"] = "0x741936fb83DDf324636D3048b3E6bC800B8D9e12";
@@ -43,8 +46,8 @@ export var RelayAdaptContract;
43
46
  RelayAdaptContract["PolygonMumbai"] = "0x17D36875D723Cf0dA250d404Ef4cA0aABE105837";
44
47
  RelayAdaptContract["ArbitrumGoerli"] = "0x3eAf99B5EDc79D833AA8B6d18F0a8dd041e13eF6";
45
48
  RelayAdaptContract["Hardhat"] = "0x0355B7B8cb128fA5692729Ab3AAa199C1753f726";
46
- })(RelayAdaptContract || (RelayAdaptContract = {}));
47
- export var RailgunProxyDeploymentBlock;
49
+ })(RelayAdaptContract = exports.RelayAdaptContract || (exports.RelayAdaptContract = {}));
50
+ var RailgunProxyDeploymentBlock;
48
51
  (function (RailgunProxyDeploymentBlock) {
49
52
  RailgunProxyDeploymentBlock[RailgunProxyDeploymentBlock["Ethereum"] = 14737691] = "Ethereum";
50
53
  RailgunProxyDeploymentBlock[RailgunProxyDeploymentBlock["BNBChain"] = 17633701] = "BNBChain";
@@ -56,8 +59,8 @@ export var RailgunProxyDeploymentBlock;
56
59
  RailgunProxyDeploymentBlock[RailgunProxyDeploymentBlock["PolygonMumbai"] = 28697343] = "PolygonMumbai";
57
60
  RailgunProxyDeploymentBlock[RailgunProxyDeploymentBlock["ArbitrumGoerli"] = 2611949] = "ArbitrumGoerli";
58
61
  RailgunProxyDeploymentBlock[RailgunProxyDeploymentBlock["Hardhat"] = 0] = "Hardhat";
59
- })(RailgunProxyDeploymentBlock || (RailgunProxyDeploymentBlock = {}));
60
- export var BaseTokenWrappedAddress;
62
+ })(RailgunProxyDeploymentBlock = exports.RailgunProxyDeploymentBlock || (exports.RailgunProxyDeploymentBlock = {}));
63
+ var BaseTokenWrappedAddress;
61
64
  (function (BaseTokenWrappedAddress) {
62
65
  BaseTokenWrappedAddress["EthereumWETH"] = "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2";
63
66
  BaseTokenWrappedAddress["BinanceWBNB"] = "0xbb4cdb9cbd36b01bd1cbaebf2de08d9173bc095c";
@@ -69,11 +72,11 @@ export var BaseTokenWrappedAddress;
69
72
  BaseTokenWrappedAddress["PolygonMumbaiWMATIC"] = "0x9c3C9283D3e44854697Cd22D3Faa240Cfb032889";
70
73
  BaseTokenWrappedAddress["ArbitrumGoerliWETH"] = "0xe39Ab88f8A4777030A534146A9Ca3B52bd5D43A3";
71
74
  BaseTokenWrappedAddress["HardhatWETH"] = "0x09635F643e140090A9A8Dcd712eD6285858ceBef";
72
- })(BaseTokenWrappedAddress || (BaseTokenWrappedAddress = {}));
73
- export const NETWORK_CONFIG = {
75
+ })(BaseTokenWrappedAddress = exports.BaseTokenWrappedAddress || (exports.BaseTokenWrappedAddress = {}));
76
+ exports.NETWORK_CONFIG = {
74
77
  [NetworkName.Railgun]: {
75
78
  chain: {
76
- type: ChainType.EVM,
79
+ type: response_types_1.ChainType.EVM,
77
80
  id: -1,
78
81
  },
79
82
  name: NetworkName.Railgun,
@@ -84,12 +87,12 @@ export const NETWORK_CONFIG = {
84
87
  proxyContract: RailgunProxyContract.Ethereum,
85
88
  relayAdaptContract: RelayAdaptContract.Ethereum,
86
89
  deploymentBlock: RailgunProxyDeploymentBlock.Ethereum,
87
- defaultEVMGasType: EVMGasType.Type2,
90
+ defaultEVMGasType: response_types_1.EVMGasType.Type2,
88
91
  shouldQuickSync: false,
89
92
  },
90
93
  [NetworkName.Ethereum]: {
91
94
  chain: {
92
- type: ChainType.EVM,
95
+ type: response_types_1.ChainType.EVM,
93
96
  id: 1,
94
97
  },
95
98
  name: NetworkName.Ethereum,
@@ -105,12 +108,12 @@ export const NETWORK_CONFIG = {
105
108
  proxyContract: RailgunProxyContract.Ethereum,
106
109
  relayAdaptContract: RelayAdaptContract.Ethereum,
107
110
  deploymentBlock: RailgunProxyDeploymentBlock.Ethereum,
108
- defaultEVMGasType: EVMGasType.Type2,
111
+ defaultEVMGasType: response_types_1.EVMGasType.Type2,
109
112
  shouldQuickSync: true,
110
113
  },
111
114
  [NetworkName.BNBChain]: {
112
115
  chain: {
113
- type: ChainType.EVM,
116
+ type: response_types_1.ChainType.EVM,
114
117
  id: 56,
115
118
  },
116
119
  name: NetworkName.BNBChain,
@@ -126,12 +129,12 @@ export const NETWORK_CONFIG = {
126
129
  proxyContract: RailgunProxyContract.BNBChain,
127
130
  relayAdaptContract: RelayAdaptContract.BNBChain,
128
131
  deploymentBlock: RailgunProxyDeploymentBlock.BNBChain,
129
- defaultEVMGasType: EVMGasType.Type0,
132
+ defaultEVMGasType: response_types_1.EVMGasType.Type0,
130
133
  shouldQuickSync: true,
131
134
  },
132
135
  [NetworkName.Polygon]: {
133
136
  chain: {
134
- type: ChainType.EVM,
137
+ type: response_types_1.ChainType.EVM,
135
138
  id: 137,
136
139
  },
137
140
  name: NetworkName.Polygon,
@@ -147,12 +150,12 @@ export const NETWORK_CONFIG = {
147
150
  proxyContract: RailgunProxyContract.PolygonPOS,
148
151
  relayAdaptContract: RelayAdaptContract.PolygonPOS,
149
152
  deploymentBlock: RailgunProxyDeploymentBlock.PolygonPOS,
150
- defaultEVMGasType: EVMGasType.Type2,
153
+ defaultEVMGasType: response_types_1.EVMGasType.Type2,
151
154
  shouldQuickSync: true,
152
155
  },
153
156
  [NetworkName.Arbitrum]: {
154
157
  chain: {
155
- type: ChainType.EVM,
158
+ type: response_types_1.ChainType.EVM,
156
159
  id: 42161,
157
160
  },
158
161
  name: NetworkName.Arbitrum,
@@ -168,14 +171,14 @@ export const NETWORK_CONFIG = {
168
171
  proxyContract: RailgunProxyContract.Arbitrum,
169
172
  relayAdaptContract: RelayAdaptContract.Arbitrum,
170
173
  deploymentBlock: RailgunProxyDeploymentBlock.Arbitrum,
171
- defaultEVMGasType: EVMGasType.Type2,
174
+ defaultEVMGasType: response_types_1.EVMGasType.Type2,
172
175
  shouldQuickSync: true,
173
176
  },
174
177
  // TEST NETS
175
178
  [NetworkName.EthereumRopsten_DEPRECATED]: {
176
179
  deprecated: true,
177
180
  chain: {
178
- type: ChainType.EVM,
181
+ type: response_types_1.ChainType.EVM,
179
182
  id: 3,
180
183
  },
181
184
  name: NetworkName.EthereumRopsten_DEPRECATED,
@@ -193,12 +196,12 @@ export const NETWORK_CONFIG = {
193
196
  deploymentBlock: RailgunProxyDeploymentBlock.EthereumRopsten,
194
197
  isDevOnlyNetwork: true,
195
198
  isTestnet: true,
196
- defaultEVMGasType: EVMGasType.Type2,
199
+ defaultEVMGasType: response_types_1.EVMGasType.Type2,
197
200
  shouldQuickSync: false,
198
201
  },
199
202
  [NetworkName.EthereumGoerli]: {
200
203
  chain: {
201
- type: ChainType.EVM,
204
+ type: response_types_1.ChainType.EVM,
202
205
  id: 5,
203
206
  },
204
207
  name: NetworkName.EthereumGoerli,
@@ -216,12 +219,12 @@ export const NETWORK_CONFIG = {
216
219
  deploymentBlock: RailgunProxyDeploymentBlock.EthereumGoerli,
217
220
  isDevOnlyNetwork: true,
218
221
  isTestnet: true,
219
- defaultEVMGasType: EVMGasType.Type2,
222
+ defaultEVMGasType: response_types_1.EVMGasType.Type2,
220
223
  shouldQuickSync: true,
221
224
  },
222
225
  [NetworkName.PolygonMumbai]: {
223
226
  chain: {
224
- type: ChainType.EVM,
227
+ type: response_types_1.ChainType.EVM,
225
228
  id: 80001,
226
229
  },
227
230
  name: NetworkName.PolygonMumbai,
@@ -239,12 +242,12 @@ export const NETWORK_CONFIG = {
239
242
  deploymentBlock: RailgunProxyDeploymentBlock.PolygonMumbai,
240
243
  isDevOnlyNetwork: true,
241
244
  isTestnet: true,
242
- defaultEVMGasType: EVMGasType.Type2,
245
+ defaultEVMGasType: response_types_1.EVMGasType.Type2,
243
246
  shouldQuickSync: true,
244
247
  },
245
248
  [NetworkName.ArbitrumGoerli]: {
246
249
  chain: {
247
- type: ChainType.EVM,
250
+ type: response_types_1.ChainType.EVM,
248
251
  id: 421613,
249
252
  },
250
253
  name: NetworkName.ArbitrumGoerli,
@@ -262,12 +265,12 @@ export const NETWORK_CONFIG = {
262
265
  deploymentBlock: RailgunProxyDeploymentBlock.ArbitrumGoerli,
263
266
  isDevOnlyNetwork: true,
264
267
  isTestnet: true,
265
- defaultEVMGasType: EVMGasType.Type2,
268
+ defaultEVMGasType: response_types_1.EVMGasType.Type2,
266
269
  shouldQuickSync: true,
267
270
  },
268
271
  [NetworkName.Hardhat]: {
269
272
  chain: {
270
- type: ChainType.EVM,
273
+ type: response_types_1.ChainType.EVM,
271
274
  id: 31337,
272
275
  },
273
276
  name: NetworkName.Hardhat,
@@ -285,7 +288,7 @@ export const NETWORK_CONFIG = {
285
288
  deploymentBlock: RailgunProxyDeploymentBlock.Hardhat,
286
289
  isDevOnlyNetwork: true,
287
290
  isTestnet: true,
288
- defaultEVMGasType: EVMGasType.Type2,
291
+ defaultEVMGasType: response_types_1.EVMGasType.Type2,
289
292
  shouldQuickSync: false,
290
293
  },
291
294
  };
@@ -1 +1 @@
1
- {"version":3,"file":"network-config.js","sourceRoot":"","sources":["../../src/models/network-config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAS,SAAS,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAEhE;;GAEG;AACH,MAAM,CAAN,IAAY,WAgBX;AAhBD,WAAY,WAAW;IACrB,WAAW;IACX,kCAAmB,CAAA;IACnB,oCAAqB,CAAA;IACrB,qCAAsB,CAAA;IACtB,kCAAmB,CAAA;IACnB,oCAAqB,CAAA;IAErB,WAAW;IACX,8DAA+C,CAAA;IAC/C,iDAAkC,CAAA;IAClC,+CAAgC,CAAA;IAChC,iDAAkC,CAAA;IAElC,WAAW;IACX,kCAAmB,CAAA;AACrB,CAAC,EAhBW,WAAW,KAAX,WAAW,QAgBtB;AAgCD,MAAM,CAAN,IAAY,oBAYX;AAZD,WAAY,oBAAoB;IAC9B,+EAAuD,CAAA;IACvD,+EAAuD,CAAA;IACvD,iFAAyD,CAAA;I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c;QAC3D,gBAAgB,EAAE,IAAI;QACtB,SAAS,EAAE,IAAI;QACf,iBAAiB,EAAE,UAAU,CAAC,KAAK;QACnC,eAAe,EAAE,IAAI;KACtB;IACD,CAAC,WAAW,CAAC,OAAO,CAAC,EAAE;QACrB,KAAK,EAAE;YACL,IAAI,EAAE,SAAS,CAAC,GAAG;YACnB,EAAE,EAAE,KAAK;SACV;QACD,IAAI,EAAE,WAAW,CAAC,OAAO;QACzB,UAAU,EAAE,iBAAiB;QAC7B,eAAe,EAAE,SAAS;QAC1B,WAAW,EAAE,EAAE;QACf,SAAS,EAAE;YACT,MAAM,EAAE,KAAK;YACb,aAAa,EAAE,MAAM;YACrB,cAAc,EAAE,uBAAuB,CAAC,WAAW;YACnD,QAAQ,EAAE,EAAE;SACb;QACD,aAAa,EAAE,oBAAoB,CAAC,OAAO;QAC3C,kBAAkB,EAAE,kBAAkB,CAAC,OAAO;QAC9C,eAAe,EAAE,2BAA2B,CAAC,OAAO;QACpD,gBAAgB,EAAE,IAAI;QACtB,SAAS,EAAE,IAAI;QACf,iBAAiB,EAAE,UAAU,CAAC,KAAK;QACnC,eAAe,EAAE,KAAK;KACvB;CACF,CAAC","sourcesContent":["import { Chain, ChainType, EVMGasType } from './response-types';\n\n/**\n * DO NOT CHANGE THESE ENUM STRINGS.\n */\nexport enum NetworkName {\n // Mainnets\n Railgun = 'Railgun',\n Ethereum = 'Ethereum',\n BNBChain = 'BNB_Chain',\n Polygon = 'Polygon',\n Arbitrum = 'Arbitrum',\n\n // Testnets\n EthereumRopsten_DEPRECATED = 'Ethereum_Ropsten',\n EthereumGoerli = 'Ethereum_Goerli',\n PolygonMumbai = 'Polygon_Mumbai',\n ArbitrumGoerli = 'Arbitrum_Goerli',\n\n // Dev only\n Hardhat = 'Hardhat',\n}\n\nexport type FeesSerialized = {\n shield: string;\n unshield: string;\n nft: string;\n};\n\ntype BaseToken = {\n symbol: string;\n wrappedSymbol: string;\n wrappedAddress: BaseTokenWrappedAddress;\n decimals: number;\n};\n\nexport type Network = {\n chain: Chain;\n name: NetworkName;\n publicName: string;\n shortPublicName: string;\n coingeckoId: string;\n baseToken: BaseToken;\n proxyContract: RailgunProxyContract;\n relayAdaptContract: RelayAdaptContract;\n deploymentBlock: RailgunProxyDeploymentBlock;\n isDevOnlyNetwork?: boolean;\n isTestnet?: boolean;\n defaultEVMGasType: EVMGasType;\n shouldQuickSync: boolean;\n deprecated?: boolean;\n};\n\nexport enum RailgunProxyContract {\n Ethereum = '0xfa7093cdd9ee6932b4eb2c9e1cde7ce00b1fa4b9',\n BNBChain = '0x590162bf4b50f6576a459b75309ee21d92178a10',\n PolygonPOS = '0x19b620929f97b7b990801496c3b361ca5def8c71',\n Arbitrum = '0xFA7093CDD9EE6932B4eb2c9e1cde7CE00B1FA4b9',\n\n // Test nets\n EthereumRopsten = '',\n EthereumGoerli = '0xe8bEa99BB438C2f3D533604D33258d74d5eE4824',\n PolygonMumbai = '0x3ee8306321d992483BDC9c69B8F622Ba3FFF05B6',\n ArbitrumGoerli = '0xA0603e598F9Ac2fc7475a3fA08D0794066615D9a',\n Hardhat = '0x610178dA211FEF7D417bC0e6FeD39F05609AD788',\n}\n\nexport enum RelayAdaptContract {\n Ethereum = '0x4025ee6512DBbda97049Bcf5AA5D38C54aF6bE8a',\n BNBChain = '0x741936fb83DDf324636D3048b3E6bC800B8D9e12',\n PolygonPOS = '0xc7FfA542736321A3dd69246d73987566a5486968',\n Arbitrum = '0x5aD95C537b002770a39dea342c4bb2b68B1497aA',\n\n // Test nets\n EthereumRopsten = '',\n EthereumGoerli = '0x14a57CA7C5c1AD54fB6c642f428d973fcD696ED4',\n PolygonMumbai = '0x17D36875D723Cf0dA250d404Ef4cA0aABE105837',\n ArbitrumGoerli = '0x3eAf99B5EDc79D833AA8B6d18F0a8dd041e13eF6',\n Hardhat = '0x0355B7B8cb128fA5692729Ab3AAa199C1753f726',\n}\n\nexport enum RailgunProxyDeploymentBlock {\n Ethereum = 14737691,\n BNBChain = 17633701,\n PolygonPOS = 28083766,\n Arbitrum = 56109834,\n\n // Test nets\n EthereumRopsten = 12226000,\n EthereumGoerli = 7795991,\n PolygonMumbai = 28697343,\n ArbitrumGoerli = 2611949,\n Hardhat = 0,\n}\n\nexport enum BaseTokenWrappedAddress {\n EthereumWETH = '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', // WETH\n BinanceWBNB = '0xbb4cdb9cbd36b01bd1cbaebf2de08d9173bc095c', // WBNB\n PolygonWMATIC = '0x0d500b1d8e8ef31e21c99d1db9a6444d3adf1270', // WMATIC\n ArbitrumWETH = '0x82af49447d8a07e3bd95bd0d56f35241523fbab1', // (Arbitrum) WETH\n\n // Test nets\n EthereumRopstenWETH = '0xc778417e063141139fce010982780140aa0cd5ab', // (Ropsten) WETH\n EthereumGoerliWETH = '0xb4fbf271143f4fbf7b91a5ded31805e42b2208d6', // (Goerli) WETH\n PolygonMumbaiWMATIC = '0x9c3C9283D3e44854697Cd22D3Faa240Cfb032889', // (Mumbai) WMATIC\n ArbitrumGoerliWETH = '0xe39Ab88f8A4777030A534146A9Ca3B52bd5D43A3', // (Arbitrum Goerli) WETH\n HardhatWETH = '0x09635F643e140090A9A8Dcd712eD6285858ceBef', // (Hardhat) WETH\n}\n\nexport const NETWORK_CONFIG: { [name in NetworkName]: Network } = {\n [NetworkName.Railgun]: {\n chain: {\n type: ChainType.EVM,\n id: -1,\n },\n name: NetworkName.Railgun,\n publicName: 'RAILGUN',\n shortPublicName: '',\n coingeckoId: '',\n baseToken: {} as BaseToken,\n proxyContract: RailgunProxyContract.Ethereum,\n relayAdaptContract: RelayAdaptContract.Ethereum,\n deploymentBlock: RailgunProxyDeploymentBlock.Ethereum,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: false,\n },\n [NetworkName.Ethereum]: {\n chain: {\n type: ChainType.EVM,\n id: 1,\n },\n name: NetworkName.Ethereum,\n publicName: 'Ethereum',\n shortPublicName: 'Ethereum',\n coingeckoId: 'ethereum',\n baseToken: {\n symbol: 'ETH',\n wrappedSymbol: 'WETH',\n wrappedAddress: BaseTokenWrappedAddress.EthereumWETH,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.Ethereum,\n relayAdaptContract: RelayAdaptContract.Ethereum,\n deploymentBlock: RailgunProxyDeploymentBlock.Ethereum,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: true,\n },\n [NetworkName.BNBChain]: {\n chain: {\n type: ChainType.EVM,\n id: 56,\n },\n name: NetworkName.BNBChain,\n publicName: 'BNB Smart Chain',\n shortPublicName: 'BSC',\n coingeckoId: 'binance-smart-chain',\n baseToken: {\n symbol: 'BNB',\n wrappedSymbol: 'WBNB',\n wrappedAddress: BaseTokenWrappedAddress.BinanceWBNB,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.BNBChain,\n relayAdaptContract: RelayAdaptContract.BNBChain,\n deploymentBlock: RailgunProxyDeploymentBlock.BNBChain,\n defaultEVMGasType: EVMGasType.Type0,\n shouldQuickSync: true,\n },\n [NetworkName.Polygon]: {\n chain: {\n type: ChainType.EVM,\n id: 137,\n },\n name: NetworkName.Polygon,\n publicName: 'Polygon',\n shortPublicName: 'Polygon',\n coingeckoId: 'polygon-pos',\n baseToken: {\n symbol: 'MATIC',\n wrappedSymbol: 'WMATIC',\n wrappedAddress: BaseTokenWrappedAddress.PolygonWMATIC,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.PolygonPOS,\n relayAdaptContract: RelayAdaptContract.PolygonPOS,\n deploymentBlock: RailgunProxyDeploymentBlock.PolygonPOS,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: true,\n },\n [NetworkName.Arbitrum]: {\n chain: {\n type: ChainType.EVM,\n id: 42161,\n },\n name: NetworkName.Arbitrum,\n publicName: 'Arbitrum',\n shortPublicName: 'Arbitrum',\n coingeckoId: 'arbitrum-one',\n baseToken: {\n symbol: 'ETH',\n wrappedSymbol: 'WETH',\n wrappedAddress: BaseTokenWrappedAddress.ArbitrumWETH,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.Arbitrum,\n relayAdaptContract: RelayAdaptContract.Arbitrum,\n deploymentBlock: RailgunProxyDeploymentBlock.Arbitrum,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: true,\n },\n\n // TEST NETS\n [NetworkName.EthereumRopsten_DEPRECATED]: {\n deprecated: true,\n chain: {\n type: ChainType.EVM,\n id: 3,\n },\n name: NetworkName.EthereumRopsten_DEPRECATED,\n publicName: 'Ropsten Testnet',\n shortPublicName: 'Ropsten',\n coingeckoId: 'ethereum',\n baseToken: {\n symbol: 'ETH',\n wrappedSymbol: 'WETH',\n wrappedAddress: BaseTokenWrappedAddress.EthereumRopstenWETH,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.EthereumRopsten,\n relayAdaptContract: RelayAdaptContract.EthereumRopsten,\n deploymentBlock: RailgunProxyDeploymentBlock.EthereumRopsten,\n isDevOnlyNetwork: true,\n isTestnet: true,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: false,\n },\n [NetworkName.EthereumGoerli]: {\n chain: {\n type: ChainType.EVM,\n id: 5,\n },\n name: NetworkName.EthereumGoerli,\n publicName: 'Görli Testnet',\n shortPublicName: 'Görli',\n coingeckoId: 'ethereum',\n baseToken: {\n symbol: 'ETH',\n wrappedSymbol: 'WETH',\n wrappedAddress: BaseTokenWrappedAddress.EthereumGoerliWETH,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.EthereumGoerli,\n relayAdaptContract: RelayAdaptContract.EthereumGoerli,\n deploymentBlock: RailgunProxyDeploymentBlock.EthereumGoerli,\n isDevOnlyNetwork: true,\n isTestnet: true,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: true,\n },\n [NetworkName.PolygonMumbai]: {\n chain: {\n type: ChainType.EVM,\n id: 80001,\n },\n name: NetworkName.PolygonMumbai,\n publicName: 'Mumbai Testnet',\n shortPublicName: 'Mumbai',\n coingeckoId: 'polygon-pos',\n baseToken: {\n symbol: 'MATIC',\n wrappedSymbol: 'WMATIC',\n wrappedAddress: BaseTokenWrappedAddress.PolygonMumbaiWMATIC,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.PolygonMumbai,\n relayAdaptContract: RelayAdaptContract.PolygonMumbai,\n deploymentBlock: RailgunProxyDeploymentBlock.PolygonMumbai,\n isDevOnlyNetwork: true,\n isTestnet: true,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: true,\n },\n [NetworkName.ArbitrumGoerli]: {\n chain: {\n type: ChainType.EVM,\n id: 421613,\n },\n name: NetworkName.ArbitrumGoerli,\n publicName: 'Arbitrum Görli Testnet',\n shortPublicName: 'Arbitrum Görli',\n coingeckoId: 'arbitrum-one',\n baseToken: {\n symbol: 'ETH',\n wrappedSymbol: 'WETH',\n wrappedAddress: BaseTokenWrappedAddress.ArbitrumGoerliWETH,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.ArbitrumGoerli,\n relayAdaptContract: RelayAdaptContract.ArbitrumGoerli,\n deploymentBlock: RailgunProxyDeploymentBlock.ArbitrumGoerli,\n isDevOnlyNetwork: true,\n isTestnet: true,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: true,\n },\n [NetworkName.Hardhat]: {\n chain: {\n type: ChainType.EVM,\n id: 31337,\n },\n name: NetworkName.Hardhat,\n publicName: 'Hardhat Testnet',\n shortPublicName: 'Hardhat',\n coingeckoId: '',\n baseToken: {\n symbol: 'ETH',\n wrappedSymbol: 'WETH',\n wrappedAddress: BaseTokenWrappedAddress.HardhatWETH,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.Hardhat,\n relayAdaptContract: RelayAdaptContract.Hardhat,\n deploymentBlock: RailgunProxyDeploymentBlock.Hardhat,\n isDevOnlyNetwork: true,\n isTestnet: true,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: false,\n },\n};\n"]}
1
+ {"version":3,"file":"network-config.js","sourceRoot":"","sources":["../../src/models/network-config.ts"],"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E,KAAK;KACvB;CACF,CAAC","sourcesContent":["import { Chain, ChainType, EVMGasType } from './response-types';\n\n/**\n * DO NOT CHANGE THESE ENUM STRINGS.\n */\nexport enum NetworkName {\n // Mainnets\n Railgun = 'Railgun',\n Ethereum = 'Ethereum',\n BNBChain = 'BNB_Chain',\n Polygon = 'Polygon',\n Arbitrum = 'Arbitrum',\n\n // Testnets\n EthereumRopsten_DEPRECATED = 'Ethereum_Ropsten',\n EthereumGoerli = 'Ethereum_Goerli',\n PolygonMumbai = 'Polygon_Mumbai',\n ArbitrumGoerli = 'Arbitrum_Goerli',\n\n // Dev only\n Hardhat = 'Hardhat',\n}\n\nexport type FeesSerialized = {\n shield: string;\n unshield: string;\n nft: string;\n};\n\ntype BaseToken = {\n symbol: string;\n wrappedSymbol: string;\n wrappedAddress: BaseTokenWrappedAddress;\n decimals: number;\n};\n\nexport type Network = {\n chain: Chain;\n name: NetworkName;\n publicName: string;\n shortPublicName: string;\n coingeckoId: string;\n baseToken: BaseToken;\n proxyContract: RailgunProxyContract;\n relayAdaptContract: RelayAdaptContract;\n deploymentBlock: RailgunProxyDeploymentBlock;\n isDevOnlyNetwork?: boolean;\n isTestnet?: boolean;\n defaultEVMGasType: EVMGasType;\n shouldQuickSync: boolean;\n deprecated?: boolean;\n};\n\nexport enum RailgunProxyContract {\n Ethereum = '0xfa7093cdd9ee6932b4eb2c9e1cde7ce00b1fa4b9',\n BNBChain = '0x590162bf4b50f6576a459b75309ee21d92178a10',\n PolygonPOS = '0x19b620929f97b7b990801496c3b361ca5def8c71',\n Arbitrum = '0xFA7093CDD9EE6932B4eb2c9e1cde7CE00B1FA4b9',\n\n // Test nets\n EthereumRopsten = '',\n EthereumGoerli = '0xe8bEa99BB438C2f3D533604D33258d74d5eE4824',\n PolygonMumbai = '0x3ee8306321d992483BDC9c69B8F622Ba3FFF05B6',\n ArbitrumGoerli = '0xA0603e598F9Ac2fc7475a3fA08D0794066615D9a',\n Hardhat = '0x610178dA211FEF7D417bC0e6FeD39F05609AD788',\n}\n\nexport enum RelayAdaptContract {\n Ethereum = '0x4025ee6512DBbda97049Bcf5AA5D38C54aF6bE8a',\n BNBChain = '0x741936fb83DDf324636D3048b3E6bC800B8D9e12',\n PolygonPOS = '0xc7FfA542736321A3dd69246d73987566a5486968',\n Arbitrum = '0x5aD95C537b002770a39dea342c4bb2b68B1497aA',\n\n // Test nets\n EthereumRopsten = '',\n EthereumGoerli = '0x14a57CA7C5c1AD54fB6c642f428d973fcD696ED4',\n PolygonMumbai = '0x17D36875D723Cf0dA250d404Ef4cA0aABE105837',\n ArbitrumGoerli = '0x3eAf99B5EDc79D833AA8B6d18F0a8dd041e13eF6',\n Hardhat = '0x0355B7B8cb128fA5692729Ab3AAa199C1753f726',\n}\n\nexport enum RailgunProxyDeploymentBlock {\n Ethereum = 14737691,\n BNBChain = 17633701,\n PolygonPOS = 28083766,\n Arbitrum = 56109834,\n\n // Test nets\n EthereumRopsten = 12226000,\n EthereumGoerli = 7795991,\n PolygonMumbai = 28697343,\n ArbitrumGoerli = 2611949,\n Hardhat = 0,\n}\n\nexport enum BaseTokenWrappedAddress {\n EthereumWETH = '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', // WETH\n BinanceWBNB = '0xbb4cdb9cbd36b01bd1cbaebf2de08d9173bc095c', // WBNB\n PolygonWMATIC = '0x0d500b1d8e8ef31e21c99d1db9a6444d3adf1270', // WMATIC\n ArbitrumWETH = '0x82af49447d8a07e3bd95bd0d56f35241523fbab1', // (Arbitrum) WETH\n\n // Test nets\n EthereumRopstenWETH = '0xc778417e063141139fce010982780140aa0cd5ab', // (Ropsten) WETH\n EthereumGoerliWETH = '0xb4fbf271143f4fbf7b91a5ded31805e42b2208d6', // (Goerli) WETH\n PolygonMumbaiWMATIC = '0x9c3C9283D3e44854697Cd22D3Faa240Cfb032889', // (Mumbai) WMATIC\n ArbitrumGoerliWETH = '0xe39Ab88f8A4777030A534146A9Ca3B52bd5D43A3', // (Arbitrum Goerli) WETH\n HardhatWETH = '0x09635F643e140090A9A8Dcd712eD6285858ceBef', // (Hardhat) WETH\n}\n\nexport const NETWORK_CONFIG: { [name in NetworkName]: Network } = {\n [NetworkName.Railgun]: {\n chain: {\n type: ChainType.EVM,\n id: -1,\n },\n name: NetworkName.Railgun,\n publicName: 'RAILGUN',\n shortPublicName: '',\n coingeckoId: '',\n baseToken: {} as BaseToken,\n proxyContract: RailgunProxyContract.Ethereum,\n relayAdaptContract: RelayAdaptContract.Ethereum,\n deploymentBlock: RailgunProxyDeploymentBlock.Ethereum,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: false,\n },\n [NetworkName.Ethereum]: {\n chain: {\n type: ChainType.EVM,\n id: 1,\n },\n name: NetworkName.Ethereum,\n publicName: 'Ethereum',\n shortPublicName: 'Ethereum',\n coingeckoId: 'ethereum',\n baseToken: {\n symbol: 'ETH',\n wrappedSymbol: 'WETH',\n wrappedAddress: BaseTokenWrappedAddress.EthereumWETH,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.Ethereum,\n relayAdaptContract: RelayAdaptContract.Ethereum,\n deploymentBlock: RailgunProxyDeploymentBlock.Ethereum,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: true,\n },\n [NetworkName.BNBChain]: {\n chain: {\n type: ChainType.EVM,\n id: 56,\n },\n name: NetworkName.BNBChain,\n publicName: 'BNB Smart Chain',\n shortPublicName: 'BSC',\n coingeckoId: 'binance-smart-chain',\n baseToken: {\n symbol: 'BNB',\n wrappedSymbol: 'WBNB',\n wrappedAddress: BaseTokenWrappedAddress.BinanceWBNB,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.BNBChain,\n relayAdaptContract: RelayAdaptContract.BNBChain,\n deploymentBlock: RailgunProxyDeploymentBlock.BNBChain,\n defaultEVMGasType: EVMGasType.Type0,\n shouldQuickSync: true,\n },\n [NetworkName.Polygon]: {\n chain: {\n type: ChainType.EVM,\n id: 137,\n },\n name: NetworkName.Polygon,\n publicName: 'Polygon',\n shortPublicName: 'Polygon',\n coingeckoId: 'polygon-pos',\n baseToken: {\n symbol: 'MATIC',\n wrappedSymbol: 'WMATIC',\n wrappedAddress: BaseTokenWrappedAddress.PolygonWMATIC,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.PolygonPOS,\n relayAdaptContract: RelayAdaptContract.PolygonPOS,\n deploymentBlock: RailgunProxyDeploymentBlock.PolygonPOS,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: true,\n },\n [NetworkName.Arbitrum]: {\n chain: {\n type: ChainType.EVM,\n id: 42161,\n },\n name: NetworkName.Arbitrum,\n publicName: 'Arbitrum',\n shortPublicName: 'Arbitrum',\n coingeckoId: 'arbitrum-one',\n baseToken: {\n symbol: 'ETH',\n wrappedSymbol: 'WETH',\n wrappedAddress: BaseTokenWrappedAddress.ArbitrumWETH,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.Arbitrum,\n relayAdaptContract: RelayAdaptContract.Arbitrum,\n deploymentBlock: RailgunProxyDeploymentBlock.Arbitrum,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: true,\n },\n\n // TEST NETS\n [NetworkName.EthereumRopsten_DEPRECATED]: {\n deprecated: true,\n chain: {\n type: ChainType.EVM,\n id: 3,\n },\n name: NetworkName.EthereumRopsten_DEPRECATED,\n publicName: 'Ropsten Testnet',\n shortPublicName: 'Ropsten',\n coingeckoId: 'ethereum',\n baseToken: {\n symbol: 'ETH',\n wrappedSymbol: 'WETH',\n wrappedAddress: BaseTokenWrappedAddress.EthereumRopstenWETH,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.EthereumRopsten,\n relayAdaptContract: RelayAdaptContract.EthereumRopsten,\n deploymentBlock: RailgunProxyDeploymentBlock.EthereumRopsten,\n isDevOnlyNetwork: true,\n isTestnet: true,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: false,\n },\n [NetworkName.EthereumGoerli]: {\n chain: {\n type: ChainType.EVM,\n id: 5,\n },\n name: NetworkName.EthereumGoerli,\n publicName: 'Görli Testnet',\n shortPublicName: 'Görli',\n coingeckoId: 'ethereum',\n baseToken: {\n symbol: 'ETH',\n wrappedSymbol: 'WETH',\n wrappedAddress: BaseTokenWrappedAddress.EthereumGoerliWETH,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.EthereumGoerli,\n relayAdaptContract: RelayAdaptContract.EthereumGoerli,\n deploymentBlock: RailgunProxyDeploymentBlock.EthereumGoerli,\n isDevOnlyNetwork: true,\n isTestnet: true,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: true,\n },\n [NetworkName.PolygonMumbai]: {\n chain: {\n type: ChainType.EVM,\n id: 80001,\n },\n name: NetworkName.PolygonMumbai,\n publicName: 'Mumbai Testnet',\n shortPublicName: 'Mumbai',\n coingeckoId: 'polygon-pos',\n baseToken: {\n symbol: 'MATIC',\n wrappedSymbol: 'WMATIC',\n wrappedAddress: BaseTokenWrappedAddress.PolygonMumbaiWMATIC,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.PolygonMumbai,\n relayAdaptContract: RelayAdaptContract.PolygonMumbai,\n deploymentBlock: RailgunProxyDeploymentBlock.PolygonMumbai,\n isDevOnlyNetwork: true,\n isTestnet: true,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: true,\n },\n [NetworkName.ArbitrumGoerli]: {\n chain: {\n type: ChainType.EVM,\n id: 421613,\n },\n name: NetworkName.ArbitrumGoerli,\n publicName: 'Arbitrum Görli Testnet',\n shortPublicName: 'Arbitrum Görli',\n coingeckoId: 'arbitrum-one',\n baseToken: {\n symbol: 'ETH',\n wrappedSymbol: 'WETH',\n wrappedAddress: BaseTokenWrappedAddress.ArbitrumGoerliWETH,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.ArbitrumGoerli,\n relayAdaptContract: RelayAdaptContract.ArbitrumGoerli,\n deploymentBlock: RailgunProxyDeploymentBlock.ArbitrumGoerli,\n isDevOnlyNetwork: true,\n isTestnet: true,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: true,\n },\n [NetworkName.Hardhat]: {\n chain: {\n type: ChainType.EVM,\n id: 31337,\n },\n name: NetworkName.Hardhat,\n publicName: 'Hardhat Testnet',\n shortPublicName: 'Hardhat',\n coingeckoId: '',\n baseToken: {\n symbol: 'ETH',\n wrappedSymbol: 'WETH',\n wrappedAddress: BaseTokenWrappedAddress.HardhatWETH,\n decimals: 18,\n },\n proxyContract: RailgunProxyContract.Hardhat,\n relayAdaptContract: RelayAdaptContract.Hardhat,\n deploymentBlock: RailgunProxyDeploymentBlock.Hardhat,\n isDevOnlyNetwork: true,\n isTestnet: true,\n defaultEVMGasType: EVMGasType.Type2,\n shouldQuickSync: false,\n },\n};\n"]}
@@ -1,8 +1,11 @@
1
- export var ProofType;
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ProofType = void 0;
4
+ var ProofType;
2
5
  (function (ProofType) {
3
6
  ProofType["Transfer"] = "Transfer";
4
7
  ProofType["Unshield"] = "Unshield";
5
8
  ProofType["UnshieldBaseToken"] = "UnshieldBaseToken";
6
9
  ProofType["CrossContractCalls"] = "CrossContractCalls";
7
- })(ProofType || (ProofType = {}));
10
+ })(ProofType = exports.ProofType || (exports.ProofType = {}));
8
11
  //# sourceMappingURL=proof.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"proof.js","sourceRoot":"","sources":["../../src/models/proof.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,SAKX;AALD,WAAY,SAAS;IACnB,kCAAqB,CAAA;IACrB,kCAAqB,CAAA;IACrB,oDAAuC,CAAA;IACvC,sDAAyC,CAAA;AAC3C,CAAC,EALW,SAAS,KAAT,SAAS,QAKpB","sourcesContent":["export enum ProofType {\n Transfer = 'Transfer',\n Unshield = 'Unshield',\n UnshieldBaseToken = 'UnshieldBaseToken',\n CrossContractCalls = 'CrossContractCalls',\n}\n"]}
1
+ {"version":3,"file":"proof.js","sourceRoot":"","sources":["../../src/models/proof.ts"],"names":[],"mappings":";;;AAAA,IAAY,SAKX;AALD,WAAY,SAAS;IACnB,kCAAqB,CAAA;IACrB,kCAAqB,CAAA;IACrB,oDAAuC,CAAA;IACvC,sDAAyC,CAAA;AAC3C,CAAC,EALW,SAAS,GAAT,iBAAS,KAAT,iBAAS,QAKpB","sourcesContent":["export enum ProofType {\n Transfer = 'Transfer',\n Unshield = 'Unshield',\n UnshieldBaseToken = 'UnshieldBaseToken',\n CrossContractCalls = 'CrossContractCalls',\n}\n"]}
@@ -1,9 +1,12 @@
1
- export var RelayerConnectionStatus;
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.RelayerConnectionStatus = void 0;
4
+ var RelayerConnectionStatus;
2
5
  (function (RelayerConnectionStatus) {
3
6
  RelayerConnectionStatus["Error"] = "Error";
4
7
  RelayerConnectionStatus["Searching"] = "Searching";
5
8
  RelayerConnectionStatus["Connected"] = "Connected";
6
9
  RelayerConnectionStatus["Disconnected"] = "Disconnected";
7
10
  RelayerConnectionStatus["AllUnavailable"] = "AllUnavailable";
8
- })(RelayerConnectionStatus || (RelayerConnectionStatus = {}));
11
+ })(RelayerConnectionStatus = exports.RelayerConnectionStatus || (exports.RelayerConnectionStatus = {}));
9
12
  //# sourceMappingURL=relayer.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"relayer.js","sourceRoot":"","sources":["../../src/models/relayer.ts"],"names":[],"mappings":"AAuEA,MAAM,CAAN,IAAY,uBAMX;AAND,WAAY,uBAAuB;IACjC,0CAAe,CAAA;IACf,kDAAuB,CAAA;IACvB,kDAAuB,CAAA;IACvB,wDAA6B,CAAA;IAC7B,4DAAiC,CAAA;AACnC,CAAC,EANW,uBAAuB,KAAvB,uBAAuB,QAMlC","sourcesContent":["import { ChainType, CommitmentCiphertext } from './response-types';\n\nexport type RelayerFeeMessageData = {\n fees: MapType<string>;\n feeExpiration: number;\n feesID: string;\n railgunAddress: string;\n identifier: Optional<string>;\n availableWallets: number;\n version: string;\n relayAdapt: string;\n};\n\nexport type RelayerFeeMessage = {\n data: string; // hex-encoded FeeMessageData\n signature: string; // hex-encoded signature\n};\n\ntype EncryptedData = [string, string];\n\nexport type RelayerEncryptedMethodParams = {\n pubkey: string;\n encryptedData: EncryptedData;\n};\n\ntype RelayerRawParamsShared = {\n chainID: number;\n chainType: ChainType;\n feesID: string;\n relayerViewingKey: string;\n devLog: boolean;\n minVersion: string;\n maxVersion: string;\n};\n\nexport type RelayerRawParamsTransact = RelayerRawParamsShared & {\n serializedTransaction: string;\n minGasPrice: string;\n useRelayAdapt: boolean;\n};\n\nexport type RelayerRawParamsPreAuthorize = RelayerRawParamsShared & {\n gasLimit: string;\n commitmentCiphertext: CommitmentCiphertext;\n commitmentHash: string;\n};\n\nexport type RelayerPreAuthorization = {\n gasLimit: string;\n commitmentHash: string;\n expiration: number;\n};\n\nexport type RelayerSignedPreAuthorization = RelayerPreAuthorization & {\n signature: string;\n};\n\nexport type CachedTokenFee = {\n feePerUnitGas: string;\n expiration: number;\n feesID: string;\n availableWallets: number;\n relayAdapt: string;\n};\n\nexport type SelectedRelayer = {\n railgunAddress: string;\n tokenAddress: string;\n tokenFee: CachedTokenFee;\n};\n\nexport enum RelayerConnectionStatus {\n Error = 'Error',\n Searching = 'Searching',\n Connected = 'Connected',\n Disconnected = 'Disconnected',\n AllUnavailable = 'AllUnavailable',\n}\n"]}
1
+ {"version":3,"file":"relayer.js","sourceRoot":"","sources":["../../src/models/relayer.ts"],"names":[],"mappings":";;;AAuEA,IAAY,uBAMX;AAND,WAAY,uBAAuB;IACjC,0CAAe,CAAA;IACf,kDAAuB,CAAA;IACvB,kDAAuB,CAAA;IACvB,wDAA6B,CAAA;IAC7B,4DAAiC,CAAA;AACnC,CAAC,EANW,uBAAuB,GAAvB,+BAAuB,KAAvB,+BAAuB,QAMlC","sourcesContent":["import { ChainType, CommitmentCiphertext } from './response-types';\n\nexport type RelayerFeeMessageData = {\n fees: MapType<string>;\n feeExpiration: number;\n feesID: string;\n railgunAddress: string;\n identifier: Optional<string>;\n availableWallets: number;\n version: string;\n relayAdapt: string;\n};\n\nexport type RelayerFeeMessage = {\n data: string; // hex-encoded FeeMessageData\n signature: string; // hex-encoded signature\n};\n\ntype EncryptedData = [string, string];\n\nexport type RelayerEncryptedMethodParams = {\n pubkey: string;\n encryptedData: EncryptedData;\n};\n\ntype RelayerRawParamsShared = {\n chainID: number;\n chainType: ChainType;\n feesID: string;\n relayerViewingKey: string;\n devLog: boolean;\n minVersion: string;\n maxVersion: string;\n};\n\nexport type RelayerRawParamsTransact = RelayerRawParamsShared & {\n serializedTransaction: string;\n minGasPrice: string;\n useRelayAdapt: boolean;\n};\n\nexport type RelayerRawParamsPreAuthorize = RelayerRawParamsShared & {\n gasLimit: string;\n commitmentCiphertext: CommitmentCiphertext;\n commitmentHash: string;\n};\n\nexport type RelayerPreAuthorization = {\n gasLimit: string;\n commitmentHash: string;\n expiration: number;\n};\n\nexport type RelayerSignedPreAuthorization = RelayerPreAuthorization & {\n signature: string;\n};\n\nexport type CachedTokenFee = {\n feePerUnitGas: string;\n expiration: number;\n feesID: string;\n availableWallets: number;\n relayAdapt: string;\n};\n\nexport type SelectedRelayer = {\n railgunAddress: string;\n tokenAddress: string;\n tokenFee: CachedTokenFee;\n};\n\nexport enum RelayerConnectionStatus {\n Error = 'Error',\n Searching = 'Searching',\n Connected = 'Connected',\n Disconnected = 'Disconnected',\n AllUnavailable = 'AllUnavailable',\n}\n"]}
@@ -1,5 +1,5 @@
1
1
  /// <reference types="../types/global" />
2
- import { PreparedTransactionRequest } from 'ethers';
2
+ import { ContractTransaction } from 'ethers';
3
3
  import { MerkletreeScanStatus } from './merkletree-scan';
4
4
  import { FeesSerialized } from './network-config';
5
5
  export declare type RailgunAPICiphertext = {
@@ -32,6 +32,10 @@ export declare type TransactionGasDetailsType2 = {
32
32
  maxFeePerGas: bigint;
33
33
  maxPriorityFeePerGas: bigint;
34
34
  };
35
+ export declare type FeeTokenDetails = {
36
+ tokenAddress: string;
37
+ feePerUnitGas: bigint;
38
+ };
35
39
  export declare enum ChainType {
36
40
  EVM = 0
37
41
  }
@@ -65,7 +69,7 @@ export declare type RailgunTxidFromNullifiersResponse = {
65
69
  txid?: string;
66
70
  };
67
71
  export declare type RailgunPopulateTransactionResponse = {
68
- transaction: PreparedTransactionRequest;
72
+ transaction: ContractTransaction;
69
73
  nullifiers?: string[];
70
74
  };
71
75
  export declare type RailgunTransactionGasEstimateResponse = {
@@ -1,31 +1,34 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TransactionHistoryItemCategory = exports.NFTTokenType = exports.ChainType = exports.EVMGasType = void 0;
1
4
  /**
2
5
  * Type0 / Type1 = non-EIP-1559 (gasPrice).
3
6
  * Type2 = EIP-1559 (maxFeePerGas and maxPriorityFeePerGas).
4
7
  */
5
- export var EVMGasType;
8
+ var EVMGasType;
6
9
  (function (EVMGasType) {
7
10
  EVMGasType[EVMGasType["Type0"] = 0] = "Type0";
8
11
  EVMGasType[EVMGasType["Type1"] = 1] = "Type1";
9
12
  EVMGasType[EVMGasType["Type2"] = 2] = "Type2";
10
- })(EVMGasType || (EVMGasType = {}));
11
- export var ChainType;
13
+ })(EVMGasType = exports.EVMGasType || (exports.EVMGasType = {}));
14
+ var ChainType;
12
15
  (function (ChainType) {
13
16
  ChainType[ChainType["EVM"] = 0] = "EVM";
14
- })(ChainType || (ChainType = {}));
17
+ })(ChainType = exports.ChainType || (exports.ChainType = {}));
15
18
  /**
16
19
  * Synced NFT types from TokenType (@railgun-community/engine).
17
20
  */
18
- export var NFTTokenType;
21
+ var NFTTokenType;
19
22
  (function (NFTTokenType) {
20
23
  NFTTokenType[NFTTokenType["ERC721"] = 1] = "ERC721";
21
24
  NFTTokenType[NFTTokenType["ERC1155"] = 2] = "ERC1155";
22
- })(NFTTokenType || (NFTTokenType = {}));
23
- export var TransactionHistoryItemCategory;
25
+ })(NFTTokenType = exports.NFTTokenType || (exports.NFTTokenType = {}));
26
+ var TransactionHistoryItemCategory;
24
27
  (function (TransactionHistoryItemCategory) {
25
28
  TransactionHistoryItemCategory["ShieldERC20s"] = "ShieldERC20s";
26
29
  TransactionHistoryItemCategory["UnshieldERC20s"] = "UnshieldERC20s";
27
30
  TransactionHistoryItemCategory["TransferSendERC20s"] = "TransferSendERC20s";
28
31
  TransactionHistoryItemCategory["TransferReceiveERC20s"] = "TransferReceiveERC20s";
29
32
  TransactionHistoryItemCategory["Unknown"] = "Unknown";
30
- })(TransactionHistoryItemCategory || (TransactionHistoryItemCategory = {}));
33
+ })(TransactionHistoryItemCategory = exports.TransactionHistoryItemCategory || (exports.TransactionHistoryItemCategory = {}));
31
34
  //# sourceMappingURL=response-types.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"response-types.js","sourceRoot":"","sources":["../../src/models/response-types.ts"],"names":[],"mappings":"AAUA;;;GAGG;AACH,MAAM,CAAN,IAAY,UAIX;AAJD,WAAY,UAAU;IACpB,6CAAS,CAAA;IACT,6CAAS,CAAA;IACT,6CAAS,CAAA;AACX,CAAC,EAJW,UAAU,KAAV,UAAU,QAIrB;AA0BD,MAAM,CAAN,IAAY,SAEX;AAFD,WAAY,SAAS;IACnB,uCAAO,CAAA;AACT,CAAC,EAFW,SAAS,KAAT,SAAS,QAEpB;AAyDD;;GAEG;AACH,MAAM,CAAN,IAAY,YAGX;AAHD,WAAY,YAAY;IACtB,mDAAU,CAAA;IACV,qDAAW,CAAA;AACb,CAAC,EAHW,YAAY,KAAZ,YAAY,QAGvB;AA0DD,MAAM,CAAN,IAAY,8BAMX;AAND,WAAY,8BAA8B;IACxC,+DAA6B,CAAA;IAC7B,mEAAiC,CAAA;IACjC,2EAAyC,CAAA;IACzC,iFAA+C,CAAA;IAC/C,qDAAmB,CAAA;AACrB,CAAC,EANW,8BAA8B,KAA9B,8BAA8B,QAMzC","sourcesContent":["/// <reference types=\"../types/global\" />\nimport { PreparedTransactionRequest } from 'ethers';\nimport { MerkletreeScanStatus } from './merkletree-scan';\nimport { FeesSerialized } from './network-config';\n\nexport type RailgunAPICiphertext = {\n iv: string;\n data: string[];\n};\n\n/**\n * Type0 / Type1 = non-EIP-1559 (gasPrice).\n * Type2 = EIP-1559 (maxFeePerGas and maxPriorityFeePerGas).\n */\nexport enum EVMGasType {\n Type0 = 0,\n Type1 = 1,\n Type2 = 2,\n}\n\nexport type TransactionGasDetails =\n | TransactionGasDetailsType0\n | TransactionGasDetailsType1\n | TransactionGasDetailsType2;\n\nexport type TransactionGasDetailsType0 = {\n evmGasType: EVMGasType.Type0;\n gasEstimate: bigint;\n gasPrice: bigint;\n};\n\nexport type TransactionGasDetailsType1 = {\n evmGasType: EVMGasType.Type1;\n gasEstimate: bigint;\n gasPrice: bigint;\n};\n\nexport type TransactionGasDetailsType2 = {\n evmGasType: EVMGasType.Type2;\n gasEstimate: bigint;\n maxFeePerGas: bigint;\n maxPriorityFeePerGas: bigint;\n};\n\nexport enum ChainType {\n EVM = 0,\n}\n\nexport type Chain = {\n type: ChainType;\n id: number;\n};\n\nexport type RailgunBalancesEvent = {\n chain: Chain;\n erc20Amounts: RailgunERC20Amount[];\n nftAmounts: RailgunNFTAmount[];\n railgunWalletID: string;\n};\n\nexport type MerkletreeScanUpdateEvent = {\n chain: Chain;\n scanStatus: MerkletreeScanStatus;\n progress: number;\n};\n\nexport type LoadProviderResponse = {\n feesSerialized: FeesSerialized;\n};\n\nexport type RailgunWalletInfo = {\n id: string;\n railgunAddress: string;\n};\n\nexport type RailgunWalletAddressData = {\n masterPublicKey: bigint;\n viewingPublicKey: bigint;\n};\n\nexport type RailgunTxidFromNullifiersResponse = {\n txid?: string;\n};\n\nexport type RailgunPopulateTransactionResponse = {\n transaction: PreparedTransactionRequest;\n nullifiers?: string[];\n};\n\nexport type RailgunTransactionGasEstimateResponse = {\n gasEstimate: bigint;\n relayerFeeCommitment?: CommitmentSummary;\n};\n\nexport type RailgunERC20Amount = {\n tokenAddress: string;\n amount: bigint;\n};\n\nexport type RailgunERC20AmountRecipient = RailgunERC20Amount & {\n recipientAddress: string;\n};\n\n/**\n * Synced NFT types from TokenType (@railgun-community/engine).\n */\nexport enum NFTTokenType {\n ERC721 = 1,\n ERC1155 = 2,\n}\n\nexport type RailgunNFTAmount = {\n nftAddress: string;\n nftTokenType: NFTTokenType;\n tokenSubID: string;\n amount: bigint;\n};\n\nexport type RailgunNFTAmountRecipient = RailgunNFTAmount & {\n recipientAddress: string;\n};\n\nexport type EncryptDataWithSharedKeyResponse = {\n encryptedData: [string, string];\n randomPubKey: string;\n sharedKey: Uint8Array;\n};\n\nexport type EncryptDataWithSharedKeySerialized = {\n encryptedData: [string, string];\n randomPubKey: string;\n sharedKey: string;\n};\n\nexport type Pbkdf2Response = string;\n\ntype SendAdditionalData = {\n recipientAddress: Optional<string>;\n walletSource: Optional<string>;\n memoText: Optional<string>;\n};\n\nexport type RailgunSendERC20Amount = RailgunERC20Amount & SendAdditionalData;\n\nexport type RailgunSendNFTAmount = RailgunNFTAmount & SendAdditionalData;\n\ntype UnshieldAdditonalData = {\n unshieldFee: Optional<string>;\n};\n\nexport type RailgunUnshieldERC20Amount = RailgunSendERC20Amount &\n UnshieldAdditonalData;\n\nexport type RailgunUnshieldNFTAmount = RailgunSendNFTAmount &\n UnshieldAdditonalData;\n\ntype ReceiveAdditionalData = {\n senderAddress: Optional<string>;\n memoText: Optional<string>;\n shieldFee: Optional<string>;\n};\n\nexport type RailgunReceiveERC20Amount = RailgunERC20Amount &\n ReceiveAdditionalData;\n\nexport type RailgunReceiveNFTAmount = RailgunNFTAmount & ReceiveAdditionalData;\n\nexport enum TransactionHistoryItemCategory {\n ShieldERC20s = 'ShieldERC20s',\n UnshieldERC20s = 'UnshieldERC20s',\n TransferSendERC20s = 'TransferSendERC20s',\n TransferReceiveERC20s = 'TransferReceiveERC20s',\n Unknown = 'Unknown',\n}\n\nexport type TransactionHistoryItem = {\n txid: string;\n version: number;\n timestamp: Optional<number>;\n blockNumber: Optional<number>;\n receiveERC20Amounts: RailgunReceiveERC20Amount[];\n transferERC20Amounts: RailgunSendERC20Amount[];\n changeERC20Amounts: RailgunERC20Amount[];\n relayerFeeERC20Amount?: RailgunERC20Amount;\n unshieldERC20Amounts: RailgunUnshieldERC20Amount[];\n receiveNFTAmounts: RailgunReceiveNFTAmount[];\n transferNFTAmounts: RailgunSendNFTAmount[];\n unshieldNFTAmounts: RailgunUnshieldNFTAmount[];\n category: TransactionHistoryItemCategory;\n};\n\ntype Ciphertext = {\n iv: string;\n tag: string;\n data: string[];\n};\n\nexport type CommitmentCiphertext = {\n ciphertext: Ciphertext;\n blindedSenderViewingKey: string;\n blindedReceiverViewingKey: string;\n annotationData: string;\n memo: string;\n};\n\nexport type CommitmentSummary = {\n commitmentCiphertext: CommitmentCiphertext;\n commitmentHash: string;\n};\n"]}
1
+ {"version":3,"file":"response-types.js","sourceRoot":"","sources":["../../src/models/response-types.ts"],"names":[],"mappings":";;;AAUA;;;GAGG;AACH,IAAY,UAIX;AAJD,WAAY,UAAU;IACpB,6CAAS,CAAA;IACT,6CAAS,CAAA;IACT,6CAAS,CAAA;AACX,CAAC,EAJW,UAAU,GAAV,kBAAU,KAAV,kBAAU,QAIrB;AA+BD,IAAY,SAEX;AAFD,WAAY,SAAS;IACnB,uCAAO,CAAA;AACT,CAAC,EAFW,SAAS,GAAT,iBAAS,KAAT,iBAAS,QAEpB;AAyDD;;GAEG;AACH,IAAY,YAGX;AAHD,WAAY,YAAY;IACtB,mDAAU,CAAA;IACV,qDAAW,CAAA;AACb,CAAC,EAHW,YAAY,GAAZ,oBAAY,KAAZ,oBAAY,QAGvB;AA0DD,IAAY,8BAMX;AAND,WAAY,8BAA8B;IACxC,+DAA6B,CAAA;IAC7B,mEAAiC,CAAA;IACjC,2EAAyC,CAAA;IACzC,iFAA+C,CAAA;IAC/C,qDAAmB,CAAA;AACrB,CAAC,EANW,8BAA8B,GAA9B,sCAA8B,KAA9B,sCAA8B,QAMzC","sourcesContent":["/// <reference types=\"../types/global\" />\nimport { ContractTransaction } from 'ethers';\nimport { MerkletreeScanStatus } from './merkletree-scan';\nimport { FeesSerialized } from './network-config';\n\nexport type RailgunAPICiphertext = {\n iv: string;\n data: string[];\n};\n\n/**\n * Type0 / Type1 = non-EIP-1559 (gasPrice).\n * Type2 = EIP-1559 (maxFeePerGas and maxPriorityFeePerGas).\n */\nexport enum EVMGasType {\n Type0 = 0,\n Type1 = 1,\n Type2 = 2,\n}\n\nexport type TransactionGasDetails =\n | TransactionGasDetailsType0\n | TransactionGasDetailsType1\n | TransactionGasDetailsType2;\n\nexport type TransactionGasDetailsType0 = {\n evmGasType: EVMGasType.Type0;\n gasEstimate: bigint;\n gasPrice: bigint;\n};\n\nexport type TransactionGasDetailsType1 = {\n evmGasType: EVMGasType.Type1;\n gasEstimate: bigint;\n gasPrice: bigint;\n};\n\nexport type TransactionGasDetailsType2 = {\n evmGasType: EVMGasType.Type2;\n gasEstimate: bigint;\n maxFeePerGas: bigint;\n maxPriorityFeePerGas: bigint;\n};\n\nexport type FeeTokenDetails = {\n tokenAddress: string;\n feePerUnitGas: bigint;\n};\n\nexport enum ChainType {\n EVM = 0,\n}\n\nexport type Chain = {\n type: ChainType;\n id: number;\n};\n\nexport type RailgunBalancesEvent = {\n chain: Chain;\n erc20Amounts: RailgunERC20Amount[];\n nftAmounts: RailgunNFTAmount[];\n railgunWalletID: string;\n};\n\nexport type MerkletreeScanUpdateEvent = {\n chain: Chain;\n scanStatus: MerkletreeScanStatus;\n progress: number;\n};\n\nexport type LoadProviderResponse = {\n feesSerialized: FeesSerialized;\n};\n\nexport type RailgunWalletInfo = {\n id: string;\n railgunAddress: string;\n};\n\nexport type RailgunWalletAddressData = {\n masterPublicKey: bigint;\n viewingPublicKey: bigint;\n};\n\nexport type RailgunTxidFromNullifiersResponse = {\n txid?: string;\n};\n\nexport type RailgunPopulateTransactionResponse = {\n transaction: ContractTransaction;\n nullifiers?: string[];\n};\n\nexport type RailgunTransactionGasEstimateResponse = {\n gasEstimate: bigint;\n relayerFeeCommitment?: CommitmentSummary;\n};\n\nexport type RailgunERC20Amount = {\n tokenAddress: string;\n amount: bigint;\n};\n\nexport type RailgunERC20AmountRecipient = RailgunERC20Amount & {\n recipientAddress: string;\n};\n\n/**\n * Synced NFT types from TokenType (@railgun-community/engine).\n */\nexport enum NFTTokenType {\n ERC721 = 1,\n ERC1155 = 2,\n}\n\nexport type RailgunNFTAmount = {\n nftAddress: string;\n nftTokenType: NFTTokenType;\n tokenSubID: string;\n amount: bigint;\n};\n\nexport type RailgunNFTAmountRecipient = RailgunNFTAmount & {\n recipientAddress: string;\n};\n\nexport type EncryptDataWithSharedKeyResponse = {\n encryptedData: [string, string];\n randomPubKey: string;\n sharedKey: Uint8Array;\n};\n\nexport type EncryptDataWithSharedKeySerialized = {\n encryptedData: [string, string];\n randomPubKey: string;\n sharedKey: string;\n};\n\nexport type Pbkdf2Response = string;\n\ntype SendAdditionalData = {\n recipientAddress: Optional<string>;\n walletSource: Optional<string>;\n memoText: Optional<string>;\n};\n\nexport type RailgunSendERC20Amount = RailgunERC20Amount & SendAdditionalData;\n\nexport type RailgunSendNFTAmount = RailgunNFTAmount & SendAdditionalData;\n\ntype UnshieldAdditonalData = {\n unshieldFee: Optional<string>;\n};\n\nexport type RailgunUnshieldERC20Amount = RailgunSendERC20Amount &\n UnshieldAdditonalData;\n\nexport type RailgunUnshieldNFTAmount = RailgunSendNFTAmount &\n UnshieldAdditonalData;\n\ntype ReceiveAdditionalData = {\n senderAddress: Optional<string>;\n memoText: Optional<string>;\n shieldFee: Optional<string>;\n};\n\nexport type RailgunReceiveERC20Amount = RailgunERC20Amount &\n ReceiveAdditionalData;\n\nexport type RailgunReceiveNFTAmount = RailgunNFTAmount & ReceiveAdditionalData;\n\nexport enum TransactionHistoryItemCategory {\n ShieldERC20s = 'ShieldERC20s',\n UnshieldERC20s = 'UnshieldERC20s',\n TransferSendERC20s = 'TransferSendERC20s',\n TransferReceiveERC20s = 'TransferReceiveERC20s',\n Unknown = 'Unknown',\n}\n\nexport type TransactionHistoryItem = {\n txid: string;\n version: number;\n timestamp: Optional<number>;\n blockNumber: Optional<number>;\n receiveERC20Amounts: RailgunReceiveERC20Amount[];\n transferERC20Amounts: RailgunSendERC20Amount[];\n changeERC20Amounts: RailgunERC20Amount[];\n relayerFeeERC20Amount?: RailgunERC20Amount;\n unshieldERC20Amounts: RailgunUnshieldERC20Amount[];\n receiveNFTAmounts: RailgunReceiveNFTAmount[];\n transferNFTAmounts: RailgunSendNFTAmount[];\n unshieldNFTAmounts: RailgunUnshieldNFTAmount[];\n category: TransactionHistoryItemCategory;\n};\n\ntype Ciphertext = {\n iv: string;\n tag: string;\n data: string[];\n};\n\nexport type CommitmentCiphertext = {\n ciphertext: Ciphertext;\n blindedSenderViewingKey: string;\n blindedReceiverViewingKey: string;\n annotationData: string;\n memo: string;\n};\n\nexport type CommitmentSummary = {\n commitmentCiphertext: CommitmentCiphertext;\n commitmentHash: string;\n};\n"]}
@@ -1,2 +1,3 @@
1
- export {};
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
2
3
  //# sourceMappingURL=transaction.js.map