@railgun-community/shared-models 6.4.7 → 7.0.0

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.
@@ -166,6 +166,6 @@ exports.OFAC_SANCTIONS_LIST_ADDRESSES = [
166
166
  '0xE950DC316b836e4EeFb8308bf32Bf7C72a1358FF',
167
167
  '0x21B8d56BDA776bbE68655A16895afd96F5534feD',
168
168
  '0x175d44451403Edf28469dF03A9280c1197ADb92c',
169
- '0x19F8f2B0915Daa12a3f5C9CF01dF9E24D53794F7',
169
+ '0x19F8f2B0915Daa12a3f5C9CF01dF9E24D53794F7'
170
170
  ].map(address => address.toLowerCase());
171
171
  //# sourceMappingURL=blocked-address.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"blocked-address.js","sourceRoot":"","sources":["../../src/models/blocked-address.ts"],"names":[],"mappings":";;;AAAa,QAAA,6BAA6B,GAAG;IAC3C,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;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,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5C,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;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;IAC5C,4CAA4C;CAC7C,CAAC,GAAG,CAAC,OAAO,CAAC,EAAE,CAAC,OAAO,CAAC,WAAW,EAAE,CAAC,CAAC","sourcesContent":["export const OFAC_SANCTIONS_LIST_ADDRESSES = [\n '0x01e2919679362dFBC9ee1644Ba9C6da6D6245BB1',\n '0x03893a7c7463AE47D46bc7f091665f1893656003',\n '0x04DBA1194ee10112fE6C3207C0687DEf0e78baCf',\n '0x05E0b5B40B7b66098C2161A5EE11C5740A3A7C45',\n '0x07687e702b410Fa43f4cB4Af7FA097918ffD2730',\n '0x0836222F2B2B24A3F36f98668Ed8F0B38D1a872f',\n '0x08723392Ed15743cc38513C4925f5e6be5c17243',\n '0x08b2eFdcdB8822EfE5ad0Eae55517cf5DC544251',\n '0x09193888b3f38C82dEdfda55259A82C0E7De875E',\n '0x098B716B8Aaf21512996dC57EB0615e2383E2f96',\n '0x0E3A09dDA6B20aFbB34aC7cD4A6881493f3E7bf7',\n '0x0Ee5067b06776A89CcC7dC8Ee369984AD7Db5e06',\n '0x12D66f87A04A9E220743712cE6d9bB1B5616B8Fc',\n '0x1356c899D8C9467C7f71C195612F8A395aBf2f0a',\n '0x169AD27A470D064DEDE56a2D3ff727986b15D52B',\n '0x178169B423a011fff22B9e3F3abeA13414dDD0F1',\n '0x179f48C78f57A3A78f0608cC9197B8972921d1D2',\n '0x1967D8Af5Bd86A497fb3DD7899A020e47560dAAF',\n '0x19Aa5Fe80D33a56D56c78e82eA5E50E5d80b4Dff',\n '0x1da5821544e25c636c1417Ba96Ade4Cf6D2f9B5A',\n '0x1E34A77868E19A6647b1f2F47B51ed72dEDE95DD',\n '0x22aaA7720ddd5388A3c0A3333430953C68f1849b',\n '0x23173fE8b96A4Ad8d2E17fB83EA5dcccdCa1Ae52',\n '0x23773E65ed146A459791799d01336DB287f25334',\n '0x242654336ca2205714071898f67E254EB49ACdCe',\n '0x2573BAc39EBe2901B4389CD468F2872cF7767FAF',\n '0x26903a5a198D571422b2b4EA08b56a37cbD68c89',\n '0x2717c5e28cf931547B621a5dddb772Ab6A35B701',\n '0x2f389cE8bD8ff92De3402FFCe4691d17fC4f6535',\n '0x2F50508a8a3D323B91336FA3eA6ae50E55f32185',\n '0x2FC93484614a34f26F7970CBB94615bA109BB4bf',\n '0x308eD4B7b49797e1A98D3818bFF6fe5385410370',\n '0x330bdFADE01eE9bF63C209Ee33102DD334618e0a',\n '0x35fB6f6DB4fb05e6A4cE86f2C93691425626d4b1',\n '0x38735f03b30FbC022DdD06ABED01F0Ca823C6a94',\n '0x39D908dac893CBCB53Cc86e0ECc369aA4DeF1A29',\n '0x3aac1cC67c2ec5Db4eA850957b967Ba153aD6279',\n '0x3AD9dB589d201A710Ed237c829c7860Ba86510Fc',\n '0x3CBdeD43EFdAf0FC77b9C55F6fC9988fCC9b757d',\n '0x3Cffd56B47B7b41c56258D9C7731ABaDc360E073',\n '0x3e37627dEAA754090fBFbb8bd226c1CE66D255e9',\n '0x3eFA30704D2b8BBAc821307230376556cF8CC39e',\n '0x407CcEeaA7c95d2FE2250Bf9F2c105aA7AAFB512',\n '0x4736dCf1b7A3d580672CcE6E7c65cd5cc9cFBa9D',\n '0x47CE0C6eD5B0Ce3d3A51fdb1C52DC66a7c3c2936',\n '0x48549A34AE37b12F6a30566245176994e17C6b4A',\n '0x4F47Bc496083C727c5fbe3CE9CDf2B0f6496270c',\n '0x502371699497d08D5339c870851898D6D72521Dd',\n '0x527653eA119F3E6a1F5BD18fbF4714081D7B31ce',\n '0x538Ab61E8A9fc1b2f93b3dd9011d662d89bE6FE6',\n '0x53b6936513e738f44FB50d2b9476730C0Ab3Bfc1',\n '0x5512d943eD1f7c8a43F3435C85F7aB68b30121b0',\n '0x57b2B8c82F065de8Ef5573f9730fC1449B403C9f',\n '0x58E8dCC13BE9780fC42E8723D8EaD4CF46943dF2',\n '0x5A14E72060c11313E38738009254a90968F58f51',\n '0x5cab7692D4E94096462119ab7bF57319726Eed2A',\n '0x5efda50f22d34F262c29268506C5Fa42cB56A1Ce',\n '0x5f6c97C6AD7bdd0AE7E0Dd4ca33A4ED3fDabD4D7',\n '0x610B717796ad172B316836AC95a2ffad065CeaB4',\n '0x653477c392c16b0765603074f157314Cc4f40c32',\n '0x67d40EE1A85bf4a4Bb7Ffae16De985e8427B6b45',\n '0x6aCDFBA02D390b97Ac2b2d42A63E85293BCc160e',\n '0x6Bf694a291DF3FeC1f7e69701E3ab6c592435Ae7',\n '0x6F1cA141A28907F78Ebaa64fb83A9088b02A8352',\n '0x722122dF12D4e14e13Ac3b6895a86e84145b6967',\n '0x723B78e67497E85279CB204544566F4dC5d2acA0',\n '0x72a5843cc08275C8171E582972Aa4fDa8C397B2A',\n '0x743494b60097A2230018079c02fe21a7B687EAA5',\n '0x746Aebc06D2aE31B71ac51429A19D54E797878E9',\n '0x756C4628E57F7e7f8a459EC2752968360Cf4D1AA',\n '0x76D85B4C0Fc497EeCc38902397aC608000A06607',\n '0x776198CCF446DFa168347089d7338879273172cF',\n '0x77777FeDdddFfC19Ff86DB637967013e6C6A116C',\n '0x7Db418b5D567A4e0E8c59Ad71BE1FcE48f3E6107',\n '0x7F19720A857F834887FC9A7bC0a0fBe7Fc7f8102',\n '0x7F367cC41522cE07553e823bf3be79A889DEbe1B',\n '0x7FF9cFad3877F21d41Da833E2F775dB0569eE3D9',\n '0x8281Aa6795aDE17C8973e1aedcA380258Bc124F9',\n '0x833481186f16Cece3f1Eeea1a694c42034c3a0dB',\n '0x83E5bC4Ffa856BB84Bb88581f5Dd62A433A25e0D',\n '0x84443CFd09A48AF6eF360C6976C5392aC5023a1F',\n '0x8576aCC5C05D6Ce88f4e49bf65BdF0C62F91353C',\n '0x8589427373D6D84E98730D7795D8f6f8731FDA16',\n '0x88fd245fEdeC4A936e700f9173454D1931B4C307',\n '0x901bb9583b24D97e995513C6778dc6888AB6870e',\n '0x910Cbd523D972eb0a6f4cAe4618aD62622b39DbF',\n '0x94A1B5CdB22c43faab4AbEb5c74999895464Ddaf',\n '0x94Be88213a387E992Dd87DE56950a9aef34b9448',\n '0x94C92F096437ab9958fC0A37F09348f30389Ae79',\n '0x97B1043ABD9E6FC31681635166d430a458D14F9C',\n '0x9AD122c22B14202B4490eDAf288FDb3C7cb3ff5E',\n '0x9F4cda013E354b8fC285BF4b9A60460cEe7f7Ea9',\n '0xa0e1c89Ef1a489c9C7dE96311eD5Ce5D32c20E4B',\n '0xA160cdAB225685dA1d56aa342Ad8841c3b53f291',\n '0xa5C2254e4253490C54cef0a4347fddb8f75A4998',\n '0xA60C772958a3eD56c1F15dD055bA37AC8e523a0D',\n '0xA7e5d5A720f06526557c513402f2e6B5fA20b008',\n '0xaEaaC358560e11f52454D997AAFF2c5731B6f8a6',\n '0xaf4c0B70B2Ea9FB7487C7CbB37aDa259579fe040',\n '0xaf8d1839c3c67cf571aa74B5c12398d4901147B3',\n '0xb04E030140b30C27bcdfaafFFA98C57d80eDa7B4',\n '0xb1C8094B234DcE6e03f10a5b673c1d8C69739A00',\n '0xB20c66C4DE72433F3cE747b58B86830c459CA911',\n '0xb541fc07bC7619fD4062A54d96268525cBC6FfEF',\n '0xb6f5ec1A0a9cd1526536D3F0426c429529471F40',\n '0xBA214C1c1928a32Bffe790263E38B4Af9bFCD659',\n '0xbB93e510BbCD0B7beb5A853875f9eC60275CF498',\n '0xc2a3829F459B3Edd87791c74cD45402BA0a20Be3',\n '0xC455f7fd3e0e12afd51fba5c106909934D8A0e4a',\n '0xCa0840578f57fE71599D29375e16783424023357',\n '0xCC84179FFD19A1627E79F8648d09e095252Bc418',\n '0xCEe71753C9820f063b38FDbE4cFDAf1d3D928A80',\n '0xD0975B32cEa532eaDDdFC9c60481976e39dB3472',\n '0xD21be7248e0197Ee08E0c20D4a96DEBdaC3D20Af',\n '0xd47438C816c9E7f2E2888E060936a499Af9582b3',\n '0xD4B88Df4D29F5CedD6857912842cff3b20C8Cfa3',\n '0xD5d6f8D9e784d0e26222ad3834500801a68D027D',\n '0xD691F27f38B395864Ea86CfC7253969B409c362d',\n '0xD692Fd2D0b2Fbd2e52CFa5B5b9424bC981C30696',\n '0xD82ed8786D7c69DC7e052F7A542AB047971E73d2',\n '0xd882cFc20F52f2599D84b8e8D58C7FB62cfE344b',\n '0xd8D7DE3349ccaA0Fde6298fe6D7b7d0d34586193',\n '0xd90e2f925DA726b50C4Ed8D0Fb90Ad053324F31b',\n '0xd96f2B1c14Db8458374d9Aca76E26c3D18364307',\n '0xDD4c48C0B24039969fC16D1cdF626eaB821d3384',\n '0xdf231d99Ff8b6c6CBF4E9B9a945CBAcEF9339178',\n '0xDF3A408c53E5078af6e8fb2A85088D46Ee09A61b',\n '0xe7aa314c77F4233C18C6CC84384A9247c0cf367B',\n '0xeDC5d01286f99A066559F60a585406f3878a033e',\n '0xEFE301d259F525cA1ba74A7977b80D5b060B3ccA',\n '0xf4B067dD14e95Bab89Be928c07Cb22E3c94E0DAA',\n '0xF60dD140cFf0706bAE9Cd734Ac3ae76AD9eBC32A',\n '0xF67721A2D8F736E75a49FdD7FAd2e31D8676542a',\n '0xF7B31119c2682c88d88D455dBb9d5932c65Cf1bE',\n '0xFD8610d20aA15b7B2E3Be39B396a1bC3516c7144',\n '0xfEC8A60023265364D066a1212fDE3930F6Ae8da7',\n '0xffbaC21a641Dcfe4552920138D90F3638B3c9fba',\n '0x905b63Fff465B9fFBF41DeA908CEb12478ec7601',\n '0x433830Bf9f152C4bfD444aFC684450Fd9F33494f',\n '0x96Ad914cBA965130B19610f9cF0AC405c2b6661C',\n '0xDc450aa52D6B3918d3f6f89a13F3F2f28871479E',\n '0xc5873E3ed3bA425acD18dcc6b4Af99A02897363E',\n '0x6baD91120e2171950A7d9a70c15e816cf48cE0de',\n '0x5d4163fAF150D2Ba76F5D15B18cE841169AcDaC1',\n '0x818FaAbD112FE24cC5d8B56A2B8dd0E1f370f330',\n '0xa108dfde99962808a7eD5C92439ec330717170ac',\n '0x1482CDf06702CA71eb8908ae699f0B36A2b16f2f',\n '0xdcbEfFBECcE100cCE9E4b153C4e15cB885643193',\n '0x5f48C2A71B2CC96e3F0CCae4E39318Ff0dc375b2',\n '0x5A7a51bFb49F190e5A6060a5bc6052Ac14a3b59f',\n '0xeD6e0A7e4Ac94D976eeBfB82ccf777A3c6baD921',\n '0x797d7Ae72EbddCDea2a346c1834E04d1F8dF102b',\n '0x931546D9e66836AbF687d2bc64B30407bAc8C568',\n '0x43fa21d92141BA9db43052492E0DeEE5aa5f0A93',\n '0x6Be0aE71e6c41f2f9D0D1A3B8d0f75E6f6A0b46e',\n '0x9C2Bc757B66F24D60F016B6237F8CdD414a879Fa',\n '0x961C5Be54a2ffC17CF4Cb021d863c42daCd47Fc1',\n '0x530A64c0Ce595026a4A556b703644228179E2d57',\n '0xFAC583C0cF07Ea434052c49115a4682172aB6b4F',\n '0x983a81ca6FB1e441266D2FbcB7D8E530AC2E05A2',\n '0xf3701F445b6BDaFeDbcA97D1e477357839e4120D',\n '0xE950DC316b836e4EeFb8308bf32Bf7C72a1358FF',\n '0x21B8d56BDA776bbE68655A16895afd96F5534feD',\n '0x175d44451403Edf28469dF03A9280c1197ADb92c',\n '0x19F8f2B0915Daa12a3f5C9CF01dF9E24D53794F7',\n].map(address => address.toLowerCase());\n"]}
1
+ {"version":3,"file":"blocked-address.js","sourceRoot":"","sources":["../../src/models/blocked-address.ts"],"names":[],"mappings":";;;AAAa,QAAA,6BAA6B,GAAG;IAC3C,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;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;IA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;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,GAAG,CAAC,OAAO,CAAC,EAAE,CAAC,OAAO,CAAC,WAAW,EAAE,CAAC,CAAC","sourcesContent":["export const OFAC_SANCTIONS_LIST_ADDRESSES = [\n '0x01e2919679362dFBC9ee1644Ba9C6da6D6245BB1',\n '0x03893a7c7463AE47D46bc7f091665f1893656003',\n '0x04DBA1194ee10112fE6C3207C0687DEf0e78baCf',\n '0x05E0b5B40B7b66098C2161A5EE11C5740A3A7C45',\n '0x07687e702b410Fa43f4cB4Af7FA097918ffD2730',\n '0x0836222F2B2B24A3F36f98668Ed8F0B38D1a872f',\n '0x08723392Ed15743cc38513C4925f5e6be5c17243',\n '0x08b2eFdcdB8822EfE5ad0Eae55517cf5DC544251',\n '0x09193888b3f38C82dEdfda55259A82C0E7De875E',\n '0x098B716B8Aaf21512996dC57EB0615e2383E2f96',\n '0x0E3A09dDA6B20aFbB34aC7cD4A6881493f3E7bf7',\n '0x0Ee5067b06776A89CcC7dC8Ee369984AD7Db5e06',\n '0x12D66f87A04A9E220743712cE6d9bB1B5616B8Fc',\n '0x1356c899D8C9467C7f71C195612F8A395aBf2f0a',\n '0x169AD27A470D064DEDE56a2D3ff727986b15D52B',\n '0x178169B423a011fff22B9e3F3abeA13414dDD0F1',\n '0x179f48C78f57A3A78f0608cC9197B8972921d1D2',\n '0x1967D8Af5Bd86A497fb3DD7899A020e47560dAAF',\n '0x19Aa5Fe80D33a56D56c78e82eA5E50E5d80b4Dff',\n '0x1da5821544e25c636c1417Ba96Ade4Cf6D2f9B5A',\n '0x1E34A77868E19A6647b1f2F47B51ed72dEDE95DD',\n '0x22aaA7720ddd5388A3c0A3333430953C68f1849b',\n '0x23173fE8b96A4Ad8d2E17fB83EA5dcccdCa1Ae52',\n '0x23773E65ed146A459791799d01336DB287f25334',\n '0x242654336ca2205714071898f67E254EB49ACdCe',\n '0x2573BAc39EBe2901B4389CD468F2872cF7767FAF',\n '0x26903a5a198D571422b2b4EA08b56a37cbD68c89',\n '0x2717c5e28cf931547B621a5dddb772Ab6A35B701',\n '0x2f389cE8bD8ff92De3402FFCe4691d17fC4f6535',\n '0x2F50508a8a3D323B91336FA3eA6ae50E55f32185',\n '0x2FC93484614a34f26F7970CBB94615bA109BB4bf',\n '0x308eD4B7b49797e1A98D3818bFF6fe5385410370',\n '0x330bdFADE01eE9bF63C209Ee33102DD334618e0a',\n '0x35fB6f6DB4fb05e6A4cE86f2C93691425626d4b1',\n '0x38735f03b30FbC022DdD06ABED01F0Ca823C6a94',\n '0x39D908dac893CBCB53Cc86e0ECc369aA4DeF1A29',\n '0x3aac1cC67c2ec5Db4eA850957b967Ba153aD6279',\n '0x3AD9dB589d201A710Ed237c829c7860Ba86510Fc',\n '0x3CBdeD43EFdAf0FC77b9C55F6fC9988fCC9b757d',\n '0x3Cffd56B47B7b41c56258D9C7731ABaDc360E073',\n '0x3e37627dEAA754090fBFbb8bd226c1CE66D255e9',\n '0x3eFA30704D2b8BBAc821307230376556cF8CC39e',\n '0x407CcEeaA7c95d2FE2250Bf9F2c105aA7AAFB512',\n '0x4736dCf1b7A3d580672CcE6E7c65cd5cc9cFBa9D',\n '0x47CE0C6eD5B0Ce3d3A51fdb1C52DC66a7c3c2936',\n '0x48549A34AE37b12F6a30566245176994e17C6b4A',\n '0x4F47Bc496083C727c5fbe3CE9CDf2B0f6496270c',\n '0x502371699497d08D5339c870851898D6D72521Dd',\n '0x527653eA119F3E6a1F5BD18fbF4714081D7B31ce',\n '0x538Ab61E8A9fc1b2f93b3dd9011d662d89bE6FE6',\n '0x53b6936513e738f44FB50d2b9476730C0Ab3Bfc1',\n '0x5512d943eD1f7c8a43F3435C85F7aB68b30121b0',\n '0x57b2B8c82F065de8Ef5573f9730fC1449B403C9f',\n '0x58E8dCC13BE9780fC42E8723D8EaD4CF46943dF2',\n '0x5A14E72060c11313E38738009254a90968F58f51',\n '0x5cab7692D4E94096462119ab7bF57319726Eed2A',\n '0x5efda50f22d34F262c29268506C5Fa42cB56A1Ce',\n '0x5f6c97C6AD7bdd0AE7E0Dd4ca33A4ED3fDabD4D7',\n '0x610B717796ad172B316836AC95a2ffad065CeaB4',\n '0x653477c392c16b0765603074f157314Cc4f40c32',\n '0x67d40EE1A85bf4a4Bb7Ffae16De985e8427B6b45',\n '0x6aCDFBA02D390b97Ac2b2d42A63E85293BCc160e',\n '0x6Bf694a291DF3FeC1f7e69701E3ab6c592435Ae7',\n '0x6F1cA141A28907F78Ebaa64fb83A9088b02A8352',\n '0x722122dF12D4e14e13Ac3b6895a86e84145b6967',\n '0x723B78e67497E85279CB204544566F4dC5d2acA0',\n '0x72a5843cc08275C8171E582972Aa4fDa8C397B2A',\n '0x743494b60097A2230018079c02fe21a7B687EAA5',\n '0x746Aebc06D2aE31B71ac51429A19D54E797878E9',\n '0x756C4628E57F7e7f8a459EC2752968360Cf4D1AA',\n '0x76D85B4C0Fc497EeCc38902397aC608000A06607',\n '0x776198CCF446DFa168347089d7338879273172cF',\n '0x77777FeDdddFfC19Ff86DB637967013e6C6A116C',\n '0x7Db418b5D567A4e0E8c59Ad71BE1FcE48f3E6107',\n '0x7F19720A857F834887FC9A7bC0a0fBe7Fc7f8102',\n '0x7F367cC41522cE07553e823bf3be79A889DEbe1B',\n '0x7FF9cFad3877F21d41Da833E2F775dB0569eE3D9',\n '0x8281Aa6795aDE17C8973e1aedcA380258Bc124F9',\n '0x833481186f16Cece3f1Eeea1a694c42034c3a0dB',\n '0x83E5bC4Ffa856BB84Bb88581f5Dd62A433A25e0D',\n '0x84443CFd09A48AF6eF360C6976C5392aC5023a1F',\n '0x8576aCC5C05D6Ce88f4e49bf65BdF0C62F91353C',\n '0x8589427373D6D84E98730D7795D8f6f8731FDA16',\n '0x88fd245fEdeC4A936e700f9173454D1931B4C307',\n '0x901bb9583b24D97e995513C6778dc6888AB6870e',\n '0x910Cbd523D972eb0a6f4cAe4618aD62622b39DbF',\n '0x94A1B5CdB22c43faab4AbEb5c74999895464Ddaf',\n '0x94Be88213a387E992Dd87DE56950a9aef34b9448',\n '0x94C92F096437ab9958fC0A37F09348f30389Ae79',\n '0x97B1043ABD9E6FC31681635166d430a458D14F9C',\n '0x9AD122c22B14202B4490eDAf288FDb3C7cb3ff5E',\n '0x9F4cda013E354b8fC285BF4b9A60460cEe7f7Ea9',\n '0xa0e1c89Ef1a489c9C7dE96311eD5Ce5D32c20E4B',\n '0xA160cdAB225685dA1d56aa342Ad8841c3b53f291',\n '0xa5C2254e4253490C54cef0a4347fddb8f75A4998',\n '0xA60C772958a3eD56c1F15dD055bA37AC8e523a0D',\n '0xA7e5d5A720f06526557c513402f2e6B5fA20b008',\n '0xaEaaC358560e11f52454D997AAFF2c5731B6f8a6',\n '0xaf4c0B70B2Ea9FB7487C7CbB37aDa259579fe040',\n '0xaf8d1839c3c67cf571aa74B5c12398d4901147B3',\n '0xb04E030140b30C27bcdfaafFFA98C57d80eDa7B4',\n '0xb1C8094B234DcE6e03f10a5b673c1d8C69739A00',\n '0xB20c66C4DE72433F3cE747b58B86830c459CA911',\n '0xb541fc07bC7619fD4062A54d96268525cBC6FfEF',\n '0xb6f5ec1A0a9cd1526536D3F0426c429529471F40',\n '0xBA214C1c1928a32Bffe790263E38B4Af9bFCD659',\n '0xbB93e510BbCD0B7beb5A853875f9eC60275CF498',\n '0xc2a3829F459B3Edd87791c74cD45402BA0a20Be3',\n '0xC455f7fd3e0e12afd51fba5c106909934D8A0e4a',\n '0xCa0840578f57fE71599D29375e16783424023357',\n '0xCC84179FFD19A1627E79F8648d09e095252Bc418',\n '0xCEe71753C9820f063b38FDbE4cFDAf1d3D928A80',\n '0xD0975B32cEa532eaDDdFC9c60481976e39dB3472',\n '0xD21be7248e0197Ee08E0c20D4a96DEBdaC3D20Af',\n '0xd47438C816c9E7f2E2888E060936a499Af9582b3',\n '0xD4B88Df4D29F5CedD6857912842cff3b20C8Cfa3',\n '0xD5d6f8D9e784d0e26222ad3834500801a68D027D',\n '0xD691F27f38B395864Ea86CfC7253969B409c362d',\n '0xD692Fd2D0b2Fbd2e52CFa5B5b9424bC981C30696',\n '0xD82ed8786D7c69DC7e052F7A542AB047971E73d2',\n '0xd882cFc20F52f2599D84b8e8D58C7FB62cfE344b',\n '0xd8D7DE3349ccaA0Fde6298fe6D7b7d0d34586193',\n '0xd90e2f925DA726b50C4Ed8D0Fb90Ad053324F31b',\n '0xd96f2B1c14Db8458374d9Aca76E26c3D18364307',\n '0xDD4c48C0B24039969fC16D1cdF626eaB821d3384',\n '0xdf231d99Ff8b6c6CBF4E9B9a945CBAcEF9339178',\n '0xDF3A408c53E5078af6e8fb2A85088D46Ee09A61b',\n '0xe7aa314c77F4233C18C6CC84384A9247c0cf367B',\n '0xeDC5d01286f99A066559F60a585406f3878a033e',\n '0xEFE301d259F525cA1ba74A7977b80D5b060B3ccA',\n '0xf4B067dD14e95Bab89Be928c07Cb22E3c94E0DAA',\n '0xF60dD140cFf0706bAE9Cd734Ac3ae76AD9eBC32A',\n '0xF67721A2D8F736E75a49FdD7FAd2e31D8676542a',\n '0xF7B31119c2682c88d88D455dBb9d5932c65Cf1bE',\n '0xFD8610d20aA15b7B2E3Be39B396a1bC3516c7144',\n '0xfEC8A60023265364D066a1212fDE3930F6Ae8da7',\n '0xffbaC21a641Dcfe4552920138D90F3638B3c9fba',\n '0x905b63Fff465B9fFBF41DeA908CEb12478ec7601',\n '0x433830Bf9f152C4bfD444aFC684450Fd9F33494f',\n '0x96Ad914cBA965130B19610f9cF0AC405c2b6661C',\n '0xDc450aa52D6B3918d3f6f89a13F3F2f28871479E',\n '0xc5873E3ed3bA425acD18dcc6b4Af99A02897363E',\n '0x6baD91120e2171950A7d9a70c15e816cf48cE0de',\n '0x5d4163fAF150D2Ba76F5D15B18cE841169AcDaC1',\n '0x818FaAbD112FE24cC5d8B56A2B8dd0E1f370f330',\n '0xa108dfde99962808a7eD5C92439ec330717170ac',\n '0x1482CDf06702CA71eb8908ae699f0B36A2b16f2f',\n '0xdcbEfFBECcE100cCE9E4b153C4e15cB885643193',\n '0x5f48C2A71B2CC96e3F0CCae4E39318Ff0dc375b2',\n '0x5A7a51bFb49F190e5A6060a5bc6052Ac14a3b59f',\n '0xeD6e0A7e4Ac94D976eeBfB82ccf777A3c6baD921',\n '0x797d7Ae72EbddCDea2a346c1834E04d1F8dF102b',\n '0x931546D9e66836AbF687d2bc64B30407bAc8C568',\n '0x43fa21d92141BA9db43052492E0DeEE5aa5f0A93',\n '0x6Be0aE71e6c41f2f9D0D1A3B8d0f75E6f6A0b46e',\n '0x9C2Bc757B66F24D60F016B6237F8CdD414a879Fa',\n '0x961C5Be54a2ffC17CF4Cb021d863c42daCd47Fc1',\n '0x530A64c0Ce595026a4A556b703644228179E2d57',\n '0xFAC583C0cF07Ea434052c49115a4682172aB6b4F',\n '0x983a81ca6FB1e441266D2FbcB7D8E530AC2E05A2',\n '0xf3701F445b6BDaFeDbcA97D1e477357839e4120D',\n '0xE950DC316b836e4EeFb8308bf32Bf7C72a1358FF',\n '0x21B8d56BDA776bbE68655A16895afd96F5534feD',\n '0x175d44451403Edf28469dF03A9280c1197ADb92c',\n '0x19F8f2B0915Daa12a3f5C9CF01dF9E24D53794F7'\n].map(address => address.toLowerCase());"]}
@@ -9,4 +9,4 @@ var RelayerConnectionStatus;
9
9
  RelayerConnectionStatus["Disconnected"] = "Disconnected";
10
10
  RelayerConnectionStatus["AllUnavailable"] = "AllUnavailable";
11
11
  })(RelayerConnectionStatus || (exports.RelayerConnectionStatus = RelayerConnectionStatus = {}));
12
- //# sourceMappingURL=relayer.js.map
12
+ //# sourceMappingURL=broadcaster.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"broadcaster.js","sourceRoot":"","sources":["../../src/models/broadcaster.ts"],"names":[],"mappings":";;;AAiFA,IAAY,uBAMX;AAND,WAAY,uBAAuB;IACjC,0CAAe,CAAA;IACf,kDAAuB,CAAA;IACvB,kDAAuB,CAAA;IACvB,wDAA6B,CAAA;IAC7B,4DAAiC,CAAA;AACnC,CAAC,EANW,uBAAuB,uCAAvB,uBAAuB,QAMlC","sourcesContent":["import { TXIDVersion } from './engine';\nimport {\n ChainType,\n CommitmentCiphertextV2,\n CommitmentCiphertextV3,\n PreTransactionPOIsPerTxidLeafPerList,\n} 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 requiredPOIListKeys: 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 txidVersion: TXIDVersion;\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 to: string;\n data: string;\n minGasPrice: string;\n useRelayAdapt: boolean;\n preTransactionPOIsPerTxidLeafPerList: PreTransactionPOIsPerTxidLeafPerList;\n};\n\nexport type RelayerRawParamsPreAuthorize = RelayerRawParamsShared & {\n gasLimit: string;\n commitmentCiphertext: CommitmentCiphertextV2 | CommitmentCiphertextV3;\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"]}
@@ -6,7 +6,7 @@ export * from './merkletree-scan';
6
6
  export * from './network-config';
7
7
  export * from './proof';
8
8
  export * from './proof-of-innocence';
9
- export * from './relayer';
9
+ export * from './broadcaster';
10
10
  export * from './response-types';
11
11
  export * from './transaction';
12
12
  export * from './wallet';
@@ -22,7 +22,7 @@ __exportStar(require("./merkletree-scan"), exports);
22
22
  __exportStar(require("./network-config"), exports);
23
23
  __exportStar(require("./proof"), exports);
24
24
  __exportStar(require("./proof-of-innocence"), exports);
25
- __exportStar(require("./relayer"), exports);
25
+ __exportStar(require("./broadcaster"), exports);
26
26
  __exportStar(require("./response-types"), exports);
27
27
  __exportStar(require("./transaction"), exports);
28
28
  __exportStar(require("./wallet"), exports);
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/models/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,6CAA2B;AAC3B,oDAAkC;AAClC,2CAAyB;AACzB,mDAAiC;AACjC,oDAAkC;AAClC,mDAAiC;AACjC,0CAAwB;AACxB,uDAAqC;AACrC,4CAA0B;AAC1B,mDAAiC;AACjC,gDAA8B;AAC9B,2CAAyB;AACzB,4CAA0B","sourcesContent":["export * from './artifact';\nexport * from './blocked-address';\nexport * from './engine';\nexport * from './function-types';\nexport * from './merkletree-scan';\nexport * from './network-config';\nexport * from './proof';\nexport * from './proof-of-innocence';\nexport * from './relayer';\nexport * from './response-types';\nexport * from './transaction';\nexport * from './wallet';\nexport * from './balance';\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/models/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,6CAA2B;AAC3B,oDAAkC;AAClC,2CAAyB;AACzB,mDAAiC;AACjC,oDAAkC;AAClC,mDAAiC;AACjC,0CAAwB;AACxB,uDAAqC;AACrC,gDAA8B;AAC9B,mDAAiC;AACjC,gDAA8B;AAC9B,2CAAyB;AACzB,4CAA0B","sourcesContent":["export * from './artifact';\nexport * from './blocked-address';\nexport * from './engine';\nexport * from './function-types';\nexport * from './merkletree-scan';\nexport * from './network-config';\nexport * from './proof';\nexport * from './proof-of-innocence';\nexport * from './broadcaster';\nexport * from './response-types';\nexport * from './transaction';\nexport * from './wallet';\nexport * from './balance';\n"]}
@@ -117,7 +117,7 @@ export type RailgunPopulateTransactionResponse = {
117
117
  };
118
118
  export type RailgunTransactionGasEstimateResponse = {
119
119
  gasEstimate: bigint;
120
- relayerFeeCommitment?: CommitmentSummary;
120
+ broadcasterFeeCommitment?: CommitmentSummary;
121
121
  };
122
122
  export type RailgunERC20Recipient = {
123
123
  tokenAddress: string;
@@ -210,7 +210,7 @@ export type TransactionHistoryItem = {
210
210
  receiveERC20Amounts: RailgunHistoryReceiveERC20Amount[];
211
211
  transferERC20Amounts: RailgunHistorySendERC20Amount[];
212
212
  changeERC20Amounts: RailgunHistoryERC20Amount[];
213
- relayerFeeERC20Amount?: RailgunHistoryERC20Amount;
213
+ broadcasterFeeERC20Amount?: RailgunHistoryERC20Amount;
214
214
  unshieldERC20Amounts: RailgunHistoryUnshieldERC20Amount[];
215
215
  receiveNFTAmounts: RailgunHistoryReceiveNFTAmount[];
216
216
  transferNFTAmounts: RailgunHistorySendNFTAmount[];
@@ -1 +1 @@
1
- {"version":3,"file":"response-types.js","sourceRoot":"","sources":["../../src/models/response-types.ts"],"names":[],"mappings":";;;AAYA;;;GAGG;AACH,IAAY,UAIX;AAJD,WAAY,UAAU;IACpB,6CAAS,CAAA;IACT,6CAAS,CAAA;IACT,6CAAS,CAAA;AACX,CAAC,EAJW,UAAU,0BAAV,UAAU,QAIrB;AA+BD,IAAY,SAEX;AAFD,WAAY,SAAS;IACnB,uCAAO,CAAA;AACT,CAAC,EAFW,SAAS,yBAAT,SAAS,QAEpB;AAgBD,IAAY,mBAKX;AALD,WAAY,mBAAmB;IAC7B,4DAAqC,CAAA;IACrC,gDAAyB,CAAA;IACzB,sCAAe,CAAA;IACf,gEAAyC,CAAA;AAC3C,CAAC,EALW,mBAAmB,mCAAnB,mBAAmB,QAK9B;AA4FD;;GAEG;AACH,IAAY,YAGX;AAHD,WAAY,YAAY;IACtB,mDAAU,CAAA;IACV,qDAAW,CAAA;AACb,CAAC,EAHW,YAAY,4BAAZ,YAAY,QAGvB;AAqFD,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,8CAA9B,8BAA8B,QAMzC;AAyBD,IAAY,0BAGX;AAHD,WAAY,0BAA0B;IACpC,iDAAmB,CAAA;IACnB,iEAAmC,CAAA;AACrC,CAAC,EAHW,0BAA0B,0CAA1B,0BAA0B,QAGrC","sourcesContent":["/// <reference types=\"../types/global\" />\nimport { ContractTransaction } from 'ethers';\nimport { MerkletreeScanStatus } from './merkletree-scan';\nimport { FeesSerialized } from './network-config';\nimport { TXIDVersion } from './engine';\nimport { RailgunWalletBalanceBucket } from './balance';\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 txidVersion: TXIDVersion;\n chain: Chain;\n railgunWalletID: string;\n balanceBucket: RailgunWalletBalanceBucket;\n erc20Amounts: RailgunERC20Amount[];\n nftAmounts: RailgunNFTAmount[];\n};\n\nexport enum POIProofEventStatus {\n LoadingNextBatch = 'LoadingNextBatch',\n InProgress = 'InProgress',\n Error = 'Error',\n AllProofsCompleted = 'AllProofsCompleted',\n}\n\nexport type POIProofProgressEvent = {\n status: POIProofEventStatus;\n txidVersion: TXIDVersion;\n chain: Chain;\n railgunWalletID: string;\n progress: number;\n listKey: string;\n txid: string;\n railgunTxid: string;\n index: number;\n totalCount: number;\n errMessage: Optional<string>;\n};\n\nexport type ProofProgressEvent = {\n progress: number;\n status: 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 Proof = {\n pi_a: [string, string];\n pi_b: [[string, string], [string, string]];\n pi_c: [string, string];\n};\n\nexport type PreTransactionPOI = {\n snarkProof: Proof;\n txidMerkleroot: string;\n poiMerkleroots: string[];\n blindedCommitmentsOut: string[];\n railgunTxidIfHasUnshield: string;\n};\n\nexport type PreTransactionPOIsPerTxidLeafPerList = Record<\n string, // listKey\n Record<\n string, // txidLeafHash\n PreTransactionPOI\n >\n>;\n\nexport type RailgunPopulateTransactionResponse = {\n transaction: ContractTransaction;\n nullifiers?: string[];\n preTransactionPOIsPerTxidLeafPerList: PreTransactionPOIsPerTxidLeafPerList;\n};\n\nexport type RailgunTransactionGasEstimateResponse = {\n gasEstimate: bigint;\n relayerFeeCommitment?: CommitmentSummary;\n};\n\nexport type RailgunERC20Recipient = {\n tokenAddress: string;\n recipientAddress: string;\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 NFTAmount = {\n nftAddress: string;\n nftTokenType: NFTTokenType;\n tokenSubID: string;\n amountString: string;\n};\n\nexport type NFTAmountRecipient = NFTAmount & {\n recipientAddress: string;\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 hasValidPOIForActiveLists: boolean;\n};\n\ntype HistoryAdditionalData = {\n hasValidPOIForActiveLists: boolean;\n};\n\nexport type RailgunHistoryERC20Amount = RailgunERC20Amount &\n HistoryAdditionalData;\n\nexport type RailgunHistoryNFTAmount = RailgunNFTAmount & HistoryAdditionalData;\n\nexport type RailgunHistorySendERC20Amount = RailgunHistoryERC20Amount &\n SendAdditionalData;\n\nexport type RailgunHistorySendNFTAmount = RailgunHistoryNFTAmount &\n SendAdditionalData;\n\ntype UnshieldAdditonalData = {\n unshieldFee: Optional<string>;\n hasValidPOIForActiveLists: boolean;\n};\n\nexport type RailgunHistoryUnshieldERC20Amount = RailgunHistorySendERC20Amount &\n UnshieldAdditonalData;\n\nexport type RailgunHistoryUnshieldNFTAmount = RailgunHistorySendNFTAmount &\n UnshieldAdditonalData;\n\ntype ReceiveAdditionalData = {\n senderAddress: Optional<string>;\n memoText: Optional<string>;\n shieldFee: Optional<string>;\n hasValidPOIForActiveLists: boolean;\n balanceBucket: RailgunWalletBalanceBucket;\n};\n\nexport type RailgunHistoryReceiveERC20Amount = RailgunHistoryERC20Amount &\n ReceiveAdditionalData;\n\nexport type RailgunHistoryReceiveNFTAmount = RailgunHistoryNFTAmount &\n 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 txidVersion: TXIDVersion;\n txid: string;\n version: number;\n timestamp: Optional<number>;\n blockNumber: Optional<number>;\n receiveERC20Amounts: RailgunHistoryReceiveERC20Amount[];\n transferERC20Amounts: RailgunHistorySendERC20Amount[];\n changeERC20Amounts: RailgunHistoryERC20Amount[];\n relayerFeeERC20Amount?: RailgunHistoryERC20Amount;\n unshieldERC20Amounts: RailgunHistoryUnshieldERC20Amount[];\n receiveNFTAmounts: RailgunHistoryReceiveNFTAmount[];\n transferNFTAmounts: RailgunHistorySendNFTAmount[];\n unshieldNFTAmounts: RailgunHistoryUnshieldNFTAmount[];\n category: TransactionHistoryItemCategory;\n};\n\ntype Ciphertext = {\n iv: string;\n tag: string;\n data: string[];\n};\n\nexport enum XChaChaEncryptionAlgorithm {\n XChaCha = 'XChaCha',\n XChaChaPoly1305 = 'XChaChaPoly1305',\n}\n\nexport type CiphertextXChaCha = {\n algorithm: XChaChaEncryptionAlgorithm;\n nonce: string;\n bundle: string;\n};\n\nexport type CommitmentCiphertextV2 = {\n ciphertext: Ciphertext;\n blindedSenderViewingKey: string;\n blindedReceiverViewingKey: string;\n annotationData: string;\n memo: string;\n};\n\nexport type CommitmentCiphertextV3 = {\n ciphertext: CiphertextXChaCha;\n blindedSenderViewingKey: string;\n blindedReceiverViewingKey: string;\n};\n\nexport type CommitmentSummary = {\n commitmentCiphertext: CommitmentCiphertextV2 | CommitmentCiphertextV3;\n commitmentHash: string;\n};\n"]}
1
+ {"version":3,"file":"response-types.js","sourceRoot":"","sources":["../../src/models/response-types.ts"],"names":[],"mappings":";;;AAYA;;;GAGG;AACH,IAAY,UAIX;AAJD,WAAY,UAAU;IACpB,6CAAS,CAAA;IACT,6CAAS,CAAA;IACT,6CAAS,CAAA;AACX,CAAC,EAJW,UAAU,0BAAV,UAAU,QAIrB;AA+BD,IAAY,SAEX;AAFD,WAAY,SAAS;IACnB,uCAAO,CAAA;AACT,CAAC,EAFW,SAAS,yBAAT,SAAS,QAEpB;AAgBD,IAAY,mBAKX;AALD,WAAY,mBAAmB;IAC7B,4DAAqC,CAAA;IACrC,gDAAyB,CAAA;IACzB,sCAAe,CAAA;IACf,gEAAyC,CAAA;AAC3C,CAAC,EALW,mBAAmB,mCAAnB,mBAAmB,QAK9B;AA4FD;;GAEG;AACH,IAAY,YAGX;AAHD,WAAY,YAAY;IACtB,mDAAU,CAAA;IACV,qDAAW,CAAA;AACb,CAAC,EAHW,YAAY,4BAAZ,YAAY,QAGvB;AAqFD,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,8CAA9B,8BAA8B,QAMzC;AAyBD,IAAY,0BAGX;AAHD,WAAY,0BAA0B;IACpC,iDAAmB,CAAA;IACnB,iEAAmC,CAAA;AACrC,CAAC,EAHW,0BAA0B,0CAA1B,0BAA0B,QAGrC","sourcesContent":["/// <reference types=\"../types/global\" />\nimport { ContractTransaction } from 'ethers';\nimport { MerkletreeScanStatus } from './merkletree-scan';\nimport { FeesSerialized } from './network-config';\nimport { TXIDVersion } from './engine';\nimport { RailgunWalletBalanceBucket } from './balance';\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 txidVersion: TXIDVersion;\n chain: Chain;\n railgunWalletID: string;\n balanceBucket: RailgunWalletBalanceBucket;\n erc20Amounts: RailgunERC20Amount[];\n nftAmounts: RailgunNFTAmount[];\n};\n\nexport enum POIProofEventStatus {\n LoadingNextBatch = 'LoadingNextBatch',\n InProgress = 'InProgress',\n Error = 'Error',\n AllProofsCompleted = 'AllProofsCompleted',\n}\n\nexport type POIProofProgressEvent = {\n status: POIProofEventStatus;\n txidVersion: TXIDVersion;\n chain: Chain;\n railgunWalletID: string;\n progress: number;\n listKey: string;\n txid: string;\n railgunTxid: string;\n index: number;\n totalCount: number;\n errMessage: Optional<string>;\n};\n\nexport type ProofProgressEvent = {\n progress: number;\n status: 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 Proof = {\n pi_a: [string, string];\n pi_b: [[string, string], [string, string]];\n pi_c: [string, string];\n};\n\nexport type PreTransactionPOI = {\n snarkProof: Proof;\n txidMerkleroot: string;\n poiMerkleroots: string[];\n blindedCommitmentsOut: string[];\n railgunTxidIfHasUnshield: string;\n};\n\nexport type PreTransactionPOIsPerTxidLeafPerList = Record<\n string, // listKey\n Record<\n string, // txidLeafHash\n PreTransactionPOI\n >\n>;\n\nexport type RailgunPopulateTransactionResponse = {\n transaction: ContractTransaction;\n nullifiers?: string[];\n preTransactionPOIsPerTxidLeafPerList: PreTransactionPOIsPerTxidLeafPerList;\n};\n\nexport type RailgunTransactionGasEstimateResponse = {\n gasEstimate: bigint;\n broadcasterFeeCommitment?: CommitmentSummary;\n};\n\nexport type RailgunERC20Recipient = {\n tokenAddress: string;\n recipientAddress: string;\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 NFTAmount = {\n nftAddress: string;\n nftTokenType: NFTTokenType;\n tokenSubID: string;\n amountString: string;\n};\n\nexport type NFTAmountRecipient = NFTAmount & {\n recipientAddress: string;\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 hasValidPOIForActiveLists: boolean;\n};\n\ntype HistoryAdditionalData = {\n hasValidPOIForActiveLists: boolean;\n};\n\nexport type RailgunHistoryERC20Amount = RailgunERC20Amount &\n HistoryAdditionalData;\n\nexport type RailgunHistoryNFTAmount = RailgunNFTAmount & HistoryAdditionalData;\n\nexport type RailgunHistorySendERC20Amount = RailgunHistoryERC20Amount &\n SendAdditionalData;\n\nexport type RailgunHistorySendNFTAmount = RailgunHistoryNFTAmount &\n SendAdditionalData;\n\ntype UnshieldAdditonalData = {\n unshieldFee: Optional<string>;\n hasValidPOIForActiveLists: boolean;\n};\n\nexport type RailgunHistoryUnshieldERC20Amount = RailgunHistorySendERC20Amount &\n UnshieldAdditonalData;\n\nexport type RailgunHistoryUnshieldNFTAmount = RailgunHistorySendNFTAmount &\n UnshieldAdditonalData;\n\ntype ReceiveAdditionalData = {\n senderAddress: Optional<string>;\n memoText: Optional<string>;\n shieldFee: Optional<string>;\n hasValidPOIForActiveLists: boolean;\n balanceBucket: RailgunWalletBalanceBucket;\n};\n\nexport type RailgunHistoryReceiveERC20Amount = RailgunHistoryERC20Amount &\n ReceiveAdditionalData;\n\nexport type RailgunHistoryReceiveNFTAmount = RailgunHistoryNFTAmount &\n 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 txidVersion: TXIDVersion;\n txid: string;\n version: number;\n timestamp: Optional<number>;\n blockNumber: Optional<number>;\n receiveERC20Amounts: RailgunHistoryReceiveERC20Amount[];\n transferERC20Amounts: RailgunHistorySendERC20Amount[];\n changeERC20Amounts: RailgunHistoryERC20Amount[];\n broadcasterFeeERC20Amount?: RailgunHistoryERC20Amount;\n unshieldERC20Amounts: RailgunHistoryUnshieldERC20Amount[];\n receiveNFTAmounts: RailgunHistoryReceiveNFTAmount[];\n transferNFTAmounts: RailgunHistorySendNFTAmount[];\n unshieldNFTAmounts: RailgunHistoryUnshieldNFTAmount[];\n category: TransactionHistoryItemCategory;\n};\n\ntype Ciphertext = {\n iv: string;\n tag: string;\n data: string[];\n};\n\nexport enum XChaChaEncryptionAlgorithm {\n XChaCha = 'XChaCha',\n XChaChaPoly1305 = 'XChaChaPoly1305',\n}\n\nexport type CiphertextXChaCha = {\n algorithm: XChaChaEncryptionAlgorithm;\n nonce: string;\n bundle: string;\n};\n\nexport type CommitmentCiphertextV2 = {\n ciphertext: Ciphertext;\n blindedSenderViewingKey: string;\n blindedReceiverViewingKey: string;\n annotationData: string;\n memo: string;\n};\n\nexport type CommitmentCiphertextV3 = {\n ciphertext: CiphertextXChaCha;\n blindedSenderViewingKey: string;\n blindedReceiverViewingKey: string;\n};\n\nexport type CommitmentSummary = {\n commitmentCiphertext: CommitmentCiphertextV2 | CommitmentCiphertextV3;\n commitmentHash: string;\n};\n"]}
@@ -48,8 +48,8 @@ const sanitizeError = (cause) => {
48
48
  return new Error('Error while connecting to RPC provider. Please try again.', { cause });
49
49
  }
50
50
  if (lowercaseMsg.includes('spendable private balance too low') &&
51
- lowercaseMsg.includes('relayer fee')) {
52
- return new Error('Private balance too low to pay relayer fee.', {
51
+ lowercaseMsg.includes('broadcaster fee')) {
52
+ return new Error('Private balance too low to pay broadcaster fee.', {
53
53
  cause,
54
54
  });
55
55
  }
@@ -1 +1 @@
1
- {"version":3,"file":"error.js","sourceRoot":"","sources":["../../src/utils/error.ts"],"names":[],"mappings":";;;AAAA,iCAAmC;AAEnC,MAAM,uCAAuC,GAAG,KAAK,CAAC;AAEtD,MAAM,UAAU,GAAG,CAAC,GAAW,EAAE,EAAE;IACjC,OAAO,GAAG,CAAC,OAAO;IAChB,6CAA6C;IAC7C,iEAAiE,EACjE,EAAE,CACH,CAAC;AACJ,CAAC,CAAC;AAEK,MAAM,aAAa,GAAG,CAAC,KAAY,EAAS,EAAE;IACnD,IAAI,IAAA,gBAAS,EAAC,KAAK,CAAC,IAAI,KAAK,CAAC,OAAO,EAAE;QACrC,MAAM,YAAY,GAAG,KAAK,CAAC,OAAO,CAAC,WAAW,EAAE,CAAC;QACjD,IACE,YAAY,CAAC,QAAQ,CAAC,QAAQ,CAAC;YAC/B,YAAY,CAAC,QAAQ,CAAC,sBAAsB,CAAC,EAC7C;YACA,OAAO,IAAI,KAAK,CAAC,oBAAoB,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;SACnD;QACD,IAAI,YAAY,CAAC,QAAQ,CAAC,uBAAuB,CAAC,EAAE;YAClD,OAAO,IAAI,KAAK,CAAC,2BAA2B,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;SAC1D;QACD,IAAI,YAAY,CAAC,QAAQ,CAAC,eAAe,CAAC,EAAE;YAC1C,OAAO,IAAI,KAAK,CACd,4DAA4D,EAC5D,E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CAAC;aACH;YACD,IAAI,YAAY,CAAC,QAAQ,CAAC,qBAAqB,CAAC,EAAE;gBAChD,OAAO,IAAI,KAAK,CACd,4EAA4E,EAC5E,EAAE,KAAK,EAAE,CACV,CAAC;aACH;SACF;QAED,OAAO,IAAI,KAAK,CACd,UAAU,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,OAAO,CAC/B,IAAI,uCAAuC,EAAE,EAC7C,IAAI,CACL,CACF,CAAC;KACH;IAED,OAAO,IAAI,KAAK,CAAC,kCAAkC,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;AAClE,CAAC,CAAC;AAzIW,QAAA,aAAa,iBAyIxB","sourcesContent":["import { isDefined } from './util';\n\nconst STRING_PREFIX_AFTER_UNICODE_REPLACEMENT = 'y %';\n\nconst validAscii = (str: string) => {\n return str.replace(\n // eslint-disable-next-line no-useless-escape\n /[^A-Za-z 0-9 \\.,\\?\"\"!@#\\$%\\^&\\*\\(\\)-_=\\+;:<>\\/\\\\\\|\\}\\{\\[\\]`~]*/g,\n '',\n );\n};\n\nexport const sanitizeError = (cause: Error): Error => {\n if (isDefined(cause) && cause.message) {\n const lowercaseMsg = cause.message.toLowerCase();\n if (\n lowercaseMsg.includes('quorum') ||\n lowercaseMsg.includes('could not connect to')\n ) {\n return new Error('Could not connect.', { cause });\n }\n if (lowercaseMsg.includes('call revert exception')) {\n return new Error('Failed to connect to RPC.', { cause });\n }\n if (lowercaseMsg.includes('already known')) {\n return new Error(\n 'Transaction successful but ethers request for TXID failed.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('missing revert data')) {\n return new Error('RPC connection error.', { cause });\n }\n if (\n lowercaseMsg.includes(\n 'transaction may fail or may require manual gas limit',\n )\n ) {\n return new Error('Unknown error. Transaction failed.', { cause });\n }\n if (lowercaseMsg.includes('replacement fee too low')) {\n return new Error(\n 'Nonce is used in a pending transaction, and replacement fee is too low. Please increase your network fee to replace the pending transaction.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('intrinsic gas too low')) {\n return new Error(\n 'Gas price rejected. Please select a higher gas price or resubmit.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('transaction underpriced')) {\n return new Error(\n 'Gas fee too low. Please select a higher gas price and resubmit.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('insufficient funds for intrinsic')) {\n return new Error('Insufficient gas to process transaction.', { cause });\n }\n if (lowercaseMsg.includes('nonce has already been used')) {\n return new Error(\n // Do not change 'Nonce already used' string of Error message.\n 'Nonce already used: the transaction was already completed.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('error while dialing dial tcp')) {\n return new Error(\n 'Error while connecting to RPC provider. Please try again.',\n { cause },\n );\n }\n if (\n lowercaseMsg.includes('spendable private balance too low') &&\n lowercaseMsg.includes('relayer fee')\n ) {\n return new Error('Private balance too low to pay relayer fee.', {\n cause,\n });\n }\n\n // Custom RAILGUN contract error messages\n if (lowercaseMsg.includes('railgunsmartwallet')) {\n if (lowercaseMsg.includes('invalid nft note value')) {\n return new Error('RailgunSmartWallet: Invalid NFT Note Value.', {\n cause,\n });\n }\n if (lowercaseMsg.includes('unsupported token')) {\n return new Error(\n 'RailgunSmartWallet: Unsupported Token. This token cannot interact with the RAILGUN contract.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('invalid note value')) {\n return new Error(\n 'RailgunSmartWallet: Invalid Note Value. Please submit transaction with a corrected amount.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('invalid adapt contract as sender')) {\n return new Error(\n 'RailgunSmartWallet: Invalid Adapt Contract as Sender. Please update your frontend to current Adapt module versions.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('invalid merkle root')) {\n return new Error(\n 'RailgunSmartWallet: Invalid Merkle Root. Please sync your balances and try again.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('note already spent')) {\n return new Error(\n 'RailgunSmartWallet: Note Already Spent. Please sync your balances and try again.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('invalid note ciphertext array length')) {\n return new Error(\n 'RailgunSmartWallet: Invalid Note Ciphertext Array Length. Please sync balances and re-prove your transaction.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('invalid withdraw note')) {\n return new Error(\n 'RailgunSmartWallet: Invalid Unshield Note. Please sync balances and re-prove your transaction.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('invalid snark proof')) {\n return new Error(\n 'RailgunSmartWallet: Invalid Snark Proof. Please re-prove your transaction.',\n { cause },\n );\n }\n }\n\n return new Error(\n validAscii(cause.message).replace(\n `:${STRING_PREFIX_AFTER_UNICODE_REPLACEMENT}`,\n ': ',\n ),\n );\n }\n\n return new Error('Unknown error. Please try again.', { cause });\n};\n"]}
1
+ {"version":3,"file":"error.js","sourceRoot":"","sources":["../../src/utils/error.ts"],"names":[],"mappings":";;;AAAA,iCAAmC;AAEnC,MAAM,uCAAuC,GAAG,KAAK,CAAC;AAEtD,MAAM,UAAU,GAAG,CAAC,GAAW,EAAE,EAAE;IACjC,OAAO,GAAG,CAAC,OAAO;IAChB,6CAA6C;IAC7C,iEAAiE,EACjE,EAAE,CACH,CAAC;AACJ,CAAC,CAAC;AAEK,MAAM,aAAa,GAAG,CAAC,KAAY,EAAS,EAAE;IACnD,IAAI,IAAA,gBAAS,EAAC,KAAK,CAAC,IAAI,KAAK,CAAC,OAAO,EAAE;QACrC,MAAM,YAAY,GAAG,KAAK,CAAC,OAAO,CAAC,WAAW,EAAE,CAAC;QACjD,IACE,YAAY,CAAC,QAAQ,CAAC,QAAQ,CAAC;YAC/B,YAAY,CAAC,QAAQ,CAAC,sBAAsB,CAAC,EAC7C;YACA,OAAO,IAAI,KAAK,CAAC,oBAAoB,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;SACnD;QACD,IAAI,YAAY,CAAC,QAAQ,CAAC,uBAAuB,CAAC,EAAE;YAClD,OAAO,IAAI,KAAK,CAAC,2BAA2B,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;SAC1D;QACD,IAAI,YAAY,CAAC,QAAQ,CAAC,eAAe,C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AAO,IAAI,KAAK,CACd,gGAAgG,EAChG,EAAE,KAAK,EAAE,CACV,CAAC;aACH;YACD,IAAI,YAAY,CAAC,QAAQ,CAAC,qBAAqB,CAAC,EAAE;gBAChD,OAAO,IAAI,KAAK,CACd,4EAA4E,EAC5E,EAAE,KAAK,EAAE,CACV,CAAC;aACH;SACF;QAED,OAAO,IAAI,KAAK,CACd,UAAU,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,OAAO,CAC/B,IAAI,uCAAuC,EAAE,EAC7C,IAAI,CACL,CACF,CAAC;KACH;IAED,OAAO,IAAI,KAAK,CAAC,kCAAkC,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;AAClE,CAAC,CAAC;AAzIW,QAAA,aAAa,iBAyIxB","sourcesContent":["import { isDefined } from './util';\n\nconst STRING_PREFIX_AFTER_UNICODE_REPLACEMENT = 'y %';\n\nconst validAscii = (str: string) => {\n return str.replace(\n // eslint-disable-next-line no-useless-escape\n /[^A-Za-z 0-9 \\.,\\?\"\"!@#\\$%\\^&\\*\\(\\)-_=\\+;:<>\\/\\\\\\|\\}\\{\\[\\]`~]*/g,\n '',\n );\n};\n\nexport const sanitizeError = (cause: Error): Error => {\n if (isDefined(cause) && cause.message) {\n const lowercaseMsg = cause.message.toLowerCase();\n if (\n lowercaseMsg.includes('quorum') ||\n lowercaseMsg.includes('could not connect to')\n ) {\n return new Error('Could not connect.', { cause });\n }\n if (lowercaseMsg.includes('call revert exception')) {\n return new Error('Failed to connect to RPC.', { cause });\n }\n if (lowercaseMsg.includes('already known')) {\n return new Error(\n 'Transaction successful but ethers request for TXID failed.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('missing revert data')) {\n return new Error('RPC connection error.', { cause });\n }\n if (\n lowercaseMsg.includes(\n 'transaction may fail or may require manual gas limit',\n )\n ) {\n return new Error('Unknown error. Transaction failed.', { cause });\n }\n if (lowercaseMsg.includes('replacement fee too low')) {\n return new Error(\n 'Nonce is used in a pending transaction, and replacement fee is too low. Please increase your network fee to replace the pending transaction.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('intrinsic gas too low')) {\n return new Error(\n 'Gas price rejected. Please select a higher gas price or resubmit.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('transaction underpriced')) {\n return new Error(\n 'Gas fee too low. Please select a higher gas price and resubmit.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('insufficient funds for intrinsic')) {\n return new Error('Insufficient gas to process transaction.', { cause });\n }\n if (lowercaseMsg.includes('nonce has already been used')) {\n return new Error(\n // Do not change 'Nonce already used' string of Error message.\n 'Nonce already used: the transaction was already completed.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('error while dialing dial tcp')) {\n return new Error(\n 'Error while connecting to RPC provider. Please try again.',\n { cause },\n );\n }\n if (\n lowercaseMsg.includes('spendable private balance too low') &&\n lowercaseMsg.includes('broadcaster fee')\n ) {\n return new Error('Private balance too low to pay broadcaster fee.', {\n cause,\n });\n }\n\n // Custom RAILGUN contract error messages\n if (lowercaseMsg.includes('railgunsmartwallet')) {\n if (lowercaseMsg.includes('invalid nft note value')) {\n return new Error('RailgunSmartWallet: Invalid NFT Note Value.', {\n cause,\n });\n }\n if (lowercaseMsg.includes('unsupported token')) {\n return new Error(\n 'RailgunSmartWallet: Unsupported Token. This token cannot interact with the RAILGUN contract.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('invalid note value')) {\n return new Error(\n 'RailgunSmartWallet: Invalid Note Value. Please submit transaction with a corrected amount.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('invalid adapt contract as sender')) {\n return new Error(\n 'RailgunSmartWallet: Invalid Adapt Contract as Sender. Please update your frontend to current Adapt module versions.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('invalid merkle root')) {\n return new Error(\n 'RailgunSmartWallet: Invalid Merkle Root. Please sync your balances and try again.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('note already spent')) {\n return new Error(\n 'RailgunSmartWallet: Note Already Spent. Please sync your balances and try again.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('invalid note ciphertext array length')) {\n return new Error(\n 'RailgunSmartWallet: Invalid Note Ciphertext Array Length. Please sync balances and re-prove your transaction.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('invalid withdraw note')) {\n return new Error(\n 'RailgunSmartWallet: Invalid Unshield Note. Please sync balances and re-prove your transaction.',\n { cause },\n );\n }\n if (lowercaseMsg.includes('invalid snark proof')) {\n return new Error(\n 'RailgunSmartWallet: Invalid Snark Proof. Please re-prove your transaction.',\n { cause },\n );\n }\n }\n\n return new Error(\n validAscii(cause.message).replace(\n `:${STRING_PREFIX_AFTER_UNICODE_REPLACEMENT}`,\n ': ',\n ),\n );\n }\n\n return new Error('Unknown error. Please try again.', { cause });\n};\n"]}
package/dist/utils/gas.js CHANGED
@@ -6,7 +6,7 @@ const response_types_1 = require("../models/response-types");
6
6
  const getEVMGasTypeForTransaction = (networkName, sendWithPublicWallet) => {
7
7
  const { defaultEVMGasType } = network_config_1.NETWORK_CONFIG[networkName];
8
8
  if (defaultEVMGasType === response_types_1.EVMGasType.Type2 && !sendWithPublicWallet) {
9
- // Relayer transactions require overallBatchMinGasPrice.
9
+ // Broadcaster transactions require overallBatchMinGasPrice.
10
10
  // This is only supported by type 1 transactions.
11
11
  return response_types_1.EVMGasType.Type1;
12
12
  }
@@ -1 +1 @@
1
- {"version":3,"file":"gas.js","sourceRoot":"","sources":["../../src/utils/gas.ts"],"names":[],"mappings":";;;AAAA,6DAAuE;AACvE,6DAA6E;AAEtE,MAAM,2BAA2B,GAAG,CACzC,WAAwB,EACxB,oBAA6B,EACjB,EAAE;IACd,MAAM,EAAE,iBAAiB,EAAE,GAAG,+BAAc,CAAC,WAAW,CAAC,CAAC;IAE1D,IAAI,iBAAiB,KAAK,2BAAU,CAAC,KAAK,IAAI,CAAC,oBAAoB,EAAE;QACnE,wDAAwD;QACxD,iDAAiD;QACjD,OAAO,2BAAU,CAAC,KAAK,CAAC;KACzB;IAED,OAAO,iBAAiB,CAAC;AAC3B,CAAC,CAAC;AAbW,QAAA,2BAA2B,+BAatC;AAEK,MAAM,iBAAiB,GAAG,CAAC,WAAmB,EAAU,EAAE;IAC/D,sCAAsC;IACtC,OAAO,CAAC,WAAW,GAAG,MAAM,CAAC,GAAG,MAAM,CAAC;AACzC,CAAC,CAAC;AAHW,QAAA,iBAAiB,qBAG5B;AAEK,MAAM,iBAAiB,GAAG,CAAC,UAAiC,EAAE,EAAE;IACrE,QAAQ,UAAU,CAAC,UAAU,EAAE;QAC7B,KAAK,2BAAU,CAAC,KAAK,CAAC;QACtB,KAAK,2BAAU,CAAC,KAAK,CAAC,CAAC;YACrB,OAAO,UAAU,CAAC,QAAQ,CAAC;SAC5B;QACD,KAAK,2BAAU,CAAC,KAAK,CAAC,CAAC;YACrB,OAAO,UAAU,CAAC,YAAY,CAAC;SAChC;KACF;AACH,CAAC,CAAC;AAVW,QAAA,iBAAiB,qBAU5B;AAEK,MAAM,iBAAiB,GAAG,CAC/B,qBAA4C,EAC5C,EAAE;IACF,MAAM,QAAQ,GAAG,IAAA,yBAAiB,EAAC,qBAAqB,CAAC,CAAC;IAC1D,MAAM,EAAE,WAAW,EAAE,GAAG,qBAAqB,CAAC;IAC9C,OAAO,WAAW,GAAG,QAAQ,CAAC;AAChC,CAAC,CAAC;AANW,QAAA,iBAAiB,qBAM5B;AAEK,MAAM,mBAAmB,GAAG,CACjC,qBAA4C,EACpC,EAAE;IACV,MAAM,QAAQ,GAAG,IAAA,yBAAiB,EAAC,qBAAqB,CAAC,CAAC;IAC1D,MAAM,EAAE,WAAW,EAAE,GAAG,qBAAqB,CAAC;IAC9C,OAAO,IAAA,yBAAiB,EAAC,WAAW,CAAC,GAAG,QAAQ,CAAC;AACnD,CAAC,CAAC;AANW,QAAA,mBAAmB,uBAM9B","sourcesContent":["import { NetworkName, NETWORK_CONFIG } from '../models/network-config';\nimport { EVMGasType, TransactionGasDetails } from '../models/response-types';\n\nexport const getEVMGasTypeForTransaction = (\n networkName: NetworkName,\n sendWithPublicWallet: boolean,\n): EVMGasType => {\n const { defaultEVMGasType } = NETWORK_CONFIG[networkName];\n\n if (defaultEVMGasType === EVMGasType.Type2 && !sendWithPublicWallet) {\n // Relayer transactions require overallBatchMinGasPrice.\n // This is only supported by type 1 transactions.\n return EVMGasType.Type1;\n }\n\n return defaultEVMGasType;\n};\n\nexport const calculateGasLimit = (gasEstimate: bigint): bigint => {\n // Gas Limit: Add 20% to gas estimate.\n return (gasEstimate * 12000n) / 10000n;\n};\n\nexport const calculateGasPrice = (gasDetails: TransactionGasDetails) => {\n switch (gasDetails.evmGasType) {\n case EVMGasType.Type0:\n case EVMGasType.Type1: {\n return gasDetails.gasPrice;\n }\n case EVMGasType.Type2: {\n return gasDetails.maxFeePerGas;\n }\n }\n};\n\nexport const calculateTotalGas = (\n transactionGasDetails: TransactionGasDetails,\n) => {\n const gasPrice = calculateGasPrice(transactionGasDetails);\n const { gasEstimate } = transactionGasDetails;\n return gasEstimate * gasPrice;\n};\n\nexport const calculateMaximumGas = (\n transactionGasDetails: TransactionGasDetails,\n): bigint => {\n const gasPrice = calculateGasPrice(transactionGasDetails);\n const { gasEstimate } = transactionGasDetails;\n return calculateGasLimit(gasEstimate) * gasPrice;\n};\n"]}
1
+ {"version":3,"file":"gas.js","sourceRoot":"","sources":["../../src/utils/gas.ts"],"names":[],"mappings":";;;AAAA,6DAAuE;AACvE,6DAA6E;AAEtE,MAAM,2BAA2B,GAAG,CACzC,WAAwB,EACxB,oBAA6B,EACjB,EAAE;IACd,MAAM,EAAE,iBAAiB,EAAE,GAAG,+BAAc,CAAC,WAAW,CAAC,CAAC;IAE1D,IAAI,iBAAiB,KAAK,2BAAU,CAAC,KAAK,IAAI,CAAC,oBAAoB,EAAE;QACnE,4DAA4D;QAC5D,iDAAiD;QACjD,OAAO,2BAAU,CAAC,KAAK,CAAC;KACzB;IAED,OAAO,iBAAiB,CAAC;AAC3B,CAAC,CAAC;AAbW,QAAA,2BAA2B,+BAatC;AAEK,MAAM,iBAAiB,GAAG,CAAC,WAAmB,EAAU,EAAE;IAC/D,sCAAsC;IACtC,OAAO,CAAC,WAAW,GAAG,MAAM,CAAC,GAAG,MAAM,CAAC;AACzC,CAAC,CAAC;AAHW,QAAA,iBAAiB,qBAG5B;AAEK,MAAM,iBAAiB,GAAG,CAAC,UAAiC,EAAE,EAAE;IACrE,QAAQ,UAAU,CAAC,UAAU,EAAE;QAC7B,KAAK,2BAAU,CAAC,KAAK,CAAC;QACtB,KAAK,2BAAU,CAAC,KAAK,CAAC,CAAC;YACrB,OAAO,UAAU,CAAC,QAAQ,CAAC;SAC5B;QACD,KAAK,2BAAU,CAAC,KAAK,CAAC,CAAC;YACrB,OAAO,UAAU,CAAC,YAAY,CAAC;SAChC;KACF;AACH,CAAC,CAAC;AAVW,QAAA,iBAAiB,qBAU5B;AAEK,MAAM,iBAAiB,GAAG,CAC/B,qBAA4C,EAC5C,EAAE;IACF,MAAM,QAAQ,GAAG,IAAA,yBAAiB,EAAC,qBAAqB,CAAC,CAAC;IAC1D,MAAM,EAAE,WAAW,EAAE,GAAG,qBAAqB,CAAC;IAC9C,OAAO,WAAW,GAAG,QAAQ,CAAC;AAChC,CAAC,CAAC;AANW,QAAA,iBAAiB,qBAM5B;AAEK,MAAM,mBAAmB,GAAG,CACjC,qBAA4C,EACpC,EAAE;IACV,MAAM,QAAQ,GAAG,IAAA,yBAAiB,EAAC,qBAAqB,CAAC,CAAC;IAC1D,MAAM,EAAE,WAAW,EAAE,GAAG,qBAAqB,CAAC;IAC9C,OAAO,IAAA,yBAAiB,EAAC,WAAW,CAAC,GAAG,QAAQ,CAAC;AACnD,CAAC,CAAC;AANW,QAAA,mBAAmB,uBAM9B","sourcesContent":["import { NetworkName, NETWORK_CONFIG } from '../models/network-config';\nimport { EVMGasType, TransactionGasDetails } from '../models/response-types';\n\nexport const getEVMGasTypeForTransaction = (\n networkName: NetworkName,\n sendWithPublicWallet: boolean,\n): EVMGasType => {\n const { defaultEVMGasType } = NETWORK_CONFIG[networkName];\n\n if (defaultEVMGasType === EVMGasType.Type2 && !sendWithPublicWallet) {\n // Broadcaster transactions require overallBatchMinGasPrice.\n // This is only supported by type 1 transactions.\n return EVMGasType.Type1;\n }\n\n return defaultEVMGasType;\n};\n\nexport const calculateGasLimit = (gasEstimate: bigint): bigint => {\n // Gas Limit: Add 20% to gas estimate.\n return (gasEstimate * 12000n) / 10000n;\n};\n\nexport const calculateGasPrice = (gasDetails: TransactionGasDetails) => {\n switch (gasDetails.evmGasType) {\n case EVMGasType.Type0:\n case EVMGasType.Type1: {\n return gasDetails.gasPrice;\n }\n case EVMGasType.Type2: {\n return gasDetails.maxFeePerGas;\n }\n }\n};\n\nexport const calculateTotalGas = (\n transactionGasDetails: TransactionGasDetails,\n) => {\n const gasPrice = calculateGasPrice(transactionGasDetails);\n const { gasEstimate } = transactionGasDetails;\n return gasEstimate * gasPrice;\n};\n\nexport const calculateMaximumGas = (\n transactionGasDetails: TransactionGasDetails,\n): bigint => {\n const gasPrice = calculateGasPrice(transactionGasDetails);\n const { gasEstimate } = transactionGasDetails;\n return calculateGasLimit(gasEstimate) * gasPrice;\n};\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@railgun-community/shared-models",
3
- "version": "6.4.7",
3
+ "version": "7.0.0",
4
4
  "license": "MIT",
5
5
  "main": "dist/index.js",
6
6
  "files": [
@@ -1 +0,0 @@
1
- {"version":3,"file":"relayer.js","sourceRoot":"","sources":["../../src/models/relayer.ts"],"names":[],"mappings":";;;AAiFA,IAAY,uBAMX;AAND,WAAY,uBAAuB;IACjC,0CAAe,CAAA;IACf,kDAAuB,CAAA;IACvB,kDAAuB,CAAA;IACvB,wDAA6B,CAAA;IAC7B,4DAAiC,CAAA;AACnC,CAAC,EANW,uBAAuB,uCAAvB,uBAAuB,QAMlC","sourcesContent":["import { TXIDVersion } from './engine';\nimport {\n ChainType,\n CommitmentCiphertextV2,\n CommitmentCiphertextV3,\n PreTransactionPOIsPerTxidLeafPerList,\n} 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 requiredPOIListKeys: 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 txidVersion: TXIDVersion;\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 to: string;\n data: string;\n minGasPrice: string;\n useRelayAdapt: boolean;\n preTransactionPOIsPerTxidLeafPerList: PreTransactionPOIsPerTxidLeafPerList;\n};\n\nexport type RelayerRawParamsPreAuthorize = RelayerRawParamsShared & {\n gasLimit: string;\n commitmentCiphertext: CommitmentCiphertextV2 | CommitmentCiphertextV3;\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"]}
File without changes