mirror of
https://github.com/pezkuwichain/pezkuwi-mobile-app.git
synced 2026-05-30 12:21:01 +00:00
1 line
16 KiB
Plaintext
1 line
16 KiB
Plaintext
{"dependencies":[{"name":"@polkadot/types-codec","data":{"asyncType":null,"isESMImport":false,"locs":[{"start":{"line":4,"column":22,"index":173},"end":{"line":4,"column":54,"index":205}}],"key":"fW1yxuTjZe66ggmM4ihNuGjKSV0=","exportNames":["*"],"imports":1}},{"name":"@polkadot/util","data":{"asyncType":null,"isESMImport":false,"locs":[{"start":{"line":5,"column":15,"index":222},"end":{"line":5,"column":40,"index":247}}],"key":"u0mzEw2nilnHoUWtEdZl0JKHutA=","exportNames":["*"],"imports":1}},{"name":"@polkadot/util-crypto","data":{"asyncType":null,"isESMImport":false,"locs":[{"start":{"line":6,"column":22,"index":271},"end":{"line":6,"column":54,"index":303}}],"key":"ZJJnwX+B+oj5JQmnkWFMF+4Lj2M=","exportNames":["*"],"imports":1}},{"name":"../generic/AccountIndex.js","data":{"asyncType":null,"isESMImport":false,"locs":[{"start":{"line":7,"column":26,"index":331},"end":{"line":7,"column":63,"index":368}}],"key":"Y/qUd7J25OU9mckuo44DNQwpEdY=","exportNames":["*"],"imports":1}},{"name":"./AccountId.js","data":{"asyncType":null,"isESMImport":false,"locs":[{"start":{"line":8,"column":23,"index":393},"end":{"line":8,"column":48,"index":418}}],"key":"DxwzBWssNUDDyhGbvVAqSIPtM1A=","exportNames":["*"],"imports":1}}],"output":[{"data":{"code":"__d(function (global, require, _$$_IMPORT_DEFAULT, _$$_IMPORT_ALL, module, exports, _dependencyMap) {\n \"use strict\";\n\n Object.defineProperty(exports, \"__esModule\", {\n value: true\n });\n exports.GenericEthereumLookupSource = exports.ACCOUNT_ID_PREFIX = void 0;\n const types_codec_1 = require(_dependencyMap[0], \"@polkadot/types-codec\");\n const util_1 = require(_dependencyMap[1], \"@polkadot/util\");\n const util_crypto_1 = require(_dependencyMap[2], \"@polkadot/util-crypto\");\n const AccountIndex_js_1 = require(_dependencyMap[3], \"../generic/AccountIndex.js\");\n const AccountId_js_1 = require(_dependencyMap[4], \"./AccountId.js\");\n exports.ACCOUNT_ID_PREFIX = new Uint8Array([0xff]);\n /** @internal */\n function decodeString(registry, value) {\n const decoded = (0, util_crypto_1.decodeAddress)(value);\n return decoded.length === 20 ? registry.createTypeUnsafe('EthereumAccountId', [decoded]) : registry.createTypeUnsafe('AccountIndex', [(0, util_1.u8aToBn)(decoded)]);\n }\n /** @internal */\n function decodeU8a(registry, value) {\n // This allows us to instantiate an address with a raw publicKey. Do this first before\n // we checking the first byte, otherwise we may split an already-existent valid address\n if (value.length === 20) {\n return registry.createTypeUnsafe('EthereumAccountId', [value]);\n } else if (value[0] === 0xff) {\n return registry.createTypeUnsafe('EthereumAccountId', [value.subarray(1)]);\n }\n const [offset, length] = AccountIndex_js_1.GenericAccountIndex.readLength(value);\n return registry.createTypeUnsafe('AccountIndex', [(0, util_1.u8aToBn)(value.subarray(offset, offset + length))]);\n }\n function decodeAddressOrIndex(registry, value) {\n return value instanceof GenericEthereumLookupSource ? value.inner : value instanceof AccountId_js_1.GenericEthereumAccountId || value instanceof AccountIndex_js_1.GenericAccountIndex ? value : (0, util_1.isU8a)(value) || Array.isArray(value) || (0, util_1.isHex)(value) ? decodeU8a(registry, (0, util_1.u8aToU8a)(value)) : (0, util_1.isBn)(value) || (0, util_1.isNumber)(value) || (0, util_1.isBigInt)(value) ? registry.createTypeUnsafe('AccountIndex', [value]) : decodeString(registry, value);\n }\n /**\n * @name GenericEthereumLookupSource\n * @description\n * A wrapper around an EthereumAccountId and/or AccountIndex that is encoded with a prefix.\n * Since we are dealing with underlying publicKeys (or shorter encoded addresses),\n * we extend from Base with an AccountId/AccountIndex wrapper. Basically the Address\n * is encoded as `[ <prefix-byte>, ...publicKey/...bytes ]` as per spec\n */\n class GenericEthereumLookupSource extends types_codec_1.AbstractBase {\n constructor(registry, value = new Uint8Array()) {\n super(registry, decodeAddressOrIndex(registry, value));\n }\n /**\n * @description The length of the value when encoded as a Uint8Array\n */\n get encodedLength() {\n const rawLength = this._rawLength;\n return rawLength + (\n // for 1 byte AccountIndexes, we are not adding a specific prefix\n rawLength > 1 ? 1 : 0);\n }\n /**\n * @description The length of the raw value, either AccountIndex or AccountId\n */\n get _rawLength() {\n return this.inner instanceof AccountIndex_js_1.GenericAccountIndex ? AccountIndex_js_1.GenericAccountIndex.calcLength(this.inner) : this.inner.encodedLength;\n }\n /**\n * @description Returns a hex string representation of the value\n */\n toHex() {\n return (0, util_1.u8aToHex)(this.toU8a());\n }\n /**\n * @description Returns the base runtime type name for this instance\n */\n toRawType() {\n return 'Address';\n }\n /**\n * @description Encodes the value as a Uint8Array as per the SCALE specifications\n * @param isBare true when the value has none of the type-specific prefixes (internal)\n */\n toU8a(isBare) {\n const encoded = this.inner.toU8a().subarray(0, this._rawLength);\n return isBare ? encoded : (0, util_1.u8aConcat)(this.inner instanceof AccountIndex_js_1.GenericAccountIndex ? AccountIndex_js_1.GenericAccountIndex.writeLength(encoded) : exports.ACCOUNT_ID_PREFIX, encoded);\n }\n }\n exports.GenericEthereumLookupSource = GenericEthereumLookupSource;\n});","lineCount":83,"map":[[2,2,1,0],[2,14,1,12],[4,2,2,0,"Object"],[4,8,2,6],[4,9,2,7,"defineProperty"],[4,23,2,21],[4,24,2,22,"exports"],[4,31,2,29],[4,33,2,31],[4,45,2,43],[4,47,2,45],[5,4,2,47,"value"],[5,9,2,52],[5,11,2,54],[6,2,2,59],[6,3,2,60],[6,4,2,61],[7,2,3,0,"exports"],[7,9,3,7],[7,10,3,8,"GenericEthereumLookupSource"],[7,37,3,35],[7,40,3,38,"exports"],[7,47,3,45],[7,48,3,46,"ACCOUNT_ID_PREFIX"],[7,65,3,63],[7,68,3,66],[7,73,3,71],[7,74,3,72],[8,2,4,0],[8,8,4,6,"types_codec_1"],[8,21,4,19],[8,24,4,22,"require"],[8,31,4,29],[8,32,4,29,"_dependencyMap"],[8,46,4,29],[8,74,4,53],[8,75,4,54],[9,2,5,0],[9,8,5,6,"util_1"],[9,14,5,12],[9,17,5,15,"require"],[9,24,5,22],[9,25,5,22,"_dependencyMap"],[9,39,5,22],[9,60,5,39],[9,61,5,40],[10,2,6,0],[10,8,6,6,"util_crypto_1"],[10,21,6,19],[10,24,6,22,"require"],[10,31,6,29],[10,32,6,29,"_dependencyMap"],[10,46,6,29],[10,74,6,53],[10,75,6,54],[11,2,7,0],[11,8,7,6,"AccountIndex_js_1"],[11,25,7,23],[11,28,7,26,"require"],[11,35,7,33],[11,36,7,33,"_dependencyMap"],[11,50,7,33],[11,83,7,62],[11,84,7,63],[12,2,8,0],[12,8,8,6,"AccountId_js_1"],[12,22,8,20],[12,25,8,23,"require"],[12,32,8,30],[12,33,8,30,"_dependencyMap"],[12,47,8,30],[12,68,8,47],[12,69,8,48],[13,2,9,0,"exports"],[13,9,9,7],[13,10,9,8,"ACCOUNT_ID_PREFIX"],[13,27,9,25],[13,30,9,28],[13,34,9,32,"Uint8Array"],[13,44,9,42],[13,45,9,43],[13,46,9,44],[13,50,9,48],[13,51,9,49],[13,52,9,50],[14,2,10,0],[15,2,11,0],[15,11,11,9,"decodeString"],[15,23,11,21,"decodeString"],[15,24,11,22,"registry"],[15,32,11,30],[15,34,11,32,"value"],[15,39,11,37],[15,41,11,39],[16,4,12,4],[16,10,12,10,"decoded"],[16,17,12,17],[16,20,12,20],[16,21,12,21],[16,22,12,22],[16,24,12,24,"util_crypto_1"],[16,37,12,37],[16,38,12,38,"decodeAddress"],[16,51,12,51],[16,53,12,53,"value"],[16,58,12,58],[16,59,12,59],[17,4,13,4],[17,11,13,11,"decoded"],[17,18,13,18],[17,19,13,19,"length"],[17,25,13,25],[17,30,13,30],[17,32,13,32],[17,35,14,10,"registry"],[17,43,14,18],[17,44,14,19,"createTypeUnsafe"],[17,60,14,35],[17,61,14,36],[17,80,14,55],[17,82,14,57],[17,83,14,58,"decoded"],[17,90,14,65],[17,91,14,66],[17,92,14,67],[17,95,15,10,"registry"],[17,103,15,18],[17,104,15,19,"createTypeUnsafe"],[17,120,15,35],[17,121,15,36],[17,135,15,50],[17,137,15,52],[17,138,15,53],[17,139,15,54],[17,140,15,55],[17,142,15,57,"util_1"],[17,148,15,63],[17,149,15,64,"u8aToBn"],[17,156,15,71],[17,158,15,73,"decoded"],[17,165,15,80],[17,166,15,81],[17,167,15,82],[17,168,15,83],[18,2,16,0],[19,2,17,0],[20,2,18,0],[20,11,18,9,"decodeU8a"],[20,20,18,18,"decodeU8a"],[20,21,18,19,"registry"],[20,29,18,27],[20,31,18,29,"value"],[20,36,18,34],[20,38,18,36],[21,4,19,4],[22,4,20,4],[23,4,21,4],[23,8,21,8,"value"],[23,13,21,13],[23,14,21,14,"length"],[23,20,21,20],[23,25,21,25],[23,27,21,27],[23,29,21,29],[24,6,22,8],[24,13,22,15,"registry"],[24,21,22,23],[24,22,22,24,"createTypeUnsafe"],[24,38,22,40],[24,39,22,41],[24,58,22,60],[24,60,22,62],[24,61,22,63,"value"],[24,66,22,68],[24,67,22,69],[24,68,22,70],[25,4,23,4],[25,5,23,5],[25,11,24,9],[25,15,24,13,"value"],[25,20,24,18],[25,21,24,19],[25,22,24,20],[25,23,24,21],[25,28,24,26],[25,32,24,30],[25,34,24,32],[26,6,25,8],[26,13,25,15,"registry"],[26,21,25,23],[26,22,25,24,"createTypeUnsafe"],[26,38,25,40],[26,39,25,41],[26,58,25,60],[26,60,25,62],[26,61,25,63,"value"],[26,66,25,68],[26,67,25,69,"subarray"],[26,75,25,77],[26,76,25,78],[26,77,25,79],[26,78,25,80],[26,79,25,81],[26,80,25,82],[27,4,26,4],[28,4,27,4],[28,10,27,10],[28,11,27,11,"offset"],[28,17,27,17],[28,19,27,19,"length"],[28,25,27,25],[28,26,27,26],[28,29,27,29,"AccountIndex_js_1"],[28,46,27,46],[28,47,27,47,"GenericAccountIndex"],[28,66,27,66],[28,67,27,67,"readLength"],[28,77,27,77],[28,78,27,78,"value"],[28,83,27,83],[28,84,27,84],[29,4,28,4],[29,11,28,11,"registry"],[29,19,28,19],[29,20,28,20,"createTypeUnsafe"],[29,36,28,36],[29,37,28,37],[29,51,28,51],[29,53,28,53],[29,54,28,54],[29,55,28,55],[29,56,28,56],[29,58,28,58,"util_1"],[29,64,28,64],[29,65,28,65,"u8aToBn"],[29,72,28,72],[29,74,28,74,"value"],[29,79,28,79],[29,80,28,80,"subarray"],[29,88,28,88],[29,89,28,89,"offset"],[29,95,28,95],[29,97,28,97,"offset"],[29,103,28,103],[29,106,28,106,"length"],[29,112,28,112],[29,113,28,113],[29,114,28,114],[29,115,28,115],[29,116,28,116],[30,2,29,0],[31,2,30,0],[31,11,30,9,"decodeAddressOrIndex"],[31,31,30,29,"decodeAddressOrIndex"],[31,32,30,30,"registry"],[31,40,30,38],[31,42,30,40,"value"],[31,47,30,45],[31,49,30,47],[32,4,31,4],[32,11,31,11,"value"],[32,16,31,16],[32,28,31,28,"GenericEthereumLookupSource"],[32,55,31,55],[32,58,32,10,"value"],[32,63,32,15],[32,64,32,16,"inner"],[32,69,32,21],[32,72,33,10,"value"],[32,77,33,15],[32,89,33,27,"AccountId_js_1"],[32,103,33,41],[32,104,33,42,"GenericEthereumAccountId"],[32,128,33,66],[32,132,33,70,"value"],[32,137,33,75],[32,149,33,87,"AccountIndex_js_1"],[32,166,33,104],[32,167,33,105,"GenericAccountIndex"],[32,186,33,124],[32,189,34,14,"value"],[32,194,34,19],[32,197,35,14],[32,198,35,15],[32,199,35,16],[32,201,35,18,"util_1"],[32,207,35,24],[32,208,35,25,"isU8a"],[32,213,35,30],[32,215,35,32,"value"],[32,220,35,37],[32,221,35,38],[32,225,35,42,"Array"],[32,230,35,47],[32,231,35,48,"isArray"],[32,238,35,55],[32,239,35,56,"value"],[32,244,35,61],[32,245,35,62],[32,249,35,66],[32,250,35,67],[32,251,35,68],[32,253,35,70,"util_1"],[32,259,35,76],[32,260,35,77,"isHex"],[32,265,35,82],[32,267,35,84,"value"],[32,272,35,89],[32,273,35,90],[32,276,36,18,"decodeU8a"],[32,285,36,27],[32,286,36,28,"registry"],[32,294,36,36],[32,296,36,38],[32,297,36,39],[32,298,36,40],[32,300,36,42,"util_1"],[32,306,36,48],[32,307,36,49,"u8aToU8a"],[32,315,36,57],[32,317,36,59,"value"],[32,322,36,64],[32,323,36,65],[32,324,36,66],[32,327,37,18],[32,328,37,19],[32,329,37,20],[32,331,37,22,"util_1"],[32,337,37,28],[32,338,37,29,"isBn"],[32,342,37,33],[32,344,37,35,"value"],[32,349,37,40],[32,350,37,41],[32,354,37,45],[32,355,37,46],[32,356,37,47],[32,358,37,49,"util_1"],[32,364,37,55],[32,365,37,56,"isNumber"],[32,373,37,64],[32,375,37,66,"value"],[32,380,37,71],[32,381,37,72],[32,385,37,76],[32,386,37,77],[32,387,37,78],[32,389,37,80,"util_1"],[32,395,37,86],[32,396,37,87,"isBigInt"],[32,404,37,95],[32,406,37,97,"value"],[32,411,37,102],[32,412,37,103],[32,415,38,22,"registry"],[32,423,38,30],[32,424,38,31,"createTypeUnsafe"],[32,440,38,47],[32,441,38,48],[32,455,38,62],[32,457,38,64],[32,458,38,65,"value"],[32,463,38,70],[32,464,38,71],[32,465,38,72],[32,468,39,22,"decodeString"],[32,480,39,34],[32,481,39,35,"registry"],[32,489,39,43],[32,491,39,45,"value"],[32,496,39,50],[32,497,39,51],[33,2,40,0],[34,2,41,0],[35,0,42,0],[36,0,43,0],[37,0,44,0],[38,0,45,0],[39,0,46,0],[40,0,47,0],[41,0,48,0],[42,2,49,0],[42,8,49,6,"GenericEthereumLookupSource"],[42,35,49,33],[42,44,49,42,"types_codec_1"],[42,57,49,55],[42,58,49,56,"AbstractBase"],[42,70,49,68],[42,71,49,69],[43,4,50,4,"constructor"],[43,15,50,15,"constructor"],[43,16,50,16,"registry"],[43,24,50,24],[43,26,50,26,"value"],[43,31,50,31],[43,34,50,34],[43,38,50,38,"Uint8Array"],[43,48,50,48],[43,49,50,49],[43,50,50,50],[43,52,50,52],[44,6,51,8],[44,11,51,13],[44,12,51,14,"registry"],[44,20,51,22],[44,22,51,24,"decodeAddressOrIndex"],[44,42,51,44],[44,43,51,45,"registry"],[44,51,51,53],[44,53,51,55,"value"],[44,58,51,60],[44,59,51,61],[44,60,51,62],[45,4,52,4],[46,4,53,4],[47,0,54,0],[48,0,55,0],[49,4,56,4],[49,8,56,8,"encodedLength"],[49,21,56,21,"encodedLength"],[49,22,56,21],[49,24,56,24],[50,6,57,8],[50,12,57,14,"rawLength"],[50,21,57,23],[50,24,57,26],[50,28,57,30],[50,29,57,31,"_rawLength"],[50,39,57,41],[51,6,58,8],[51,13,58,15,"rawLength"],[51,22,58,24],[52,6,59,8],[53,6,60,8,"rawLength"],[53,15,60,17],[53,18,60,20],[53,19,60,21],[53,22,61,14],[53,23,61,15],[53,26,62,14],[53,27,62,15],[53,28,62,16],[54,4,63,4],[55,4,64,4],[56,0,65,0],[57,0,66,0],[58,4,67,4],[58,8,67,8,"_rawLength"],[58,18,67,18,"_rawLength"],[58,19,67,18],[58,21,67,21],[59,6,68,8],[59,13,68,15],[59,17,68,19],[59,18,68,20,"inner"],[59,23,68,25],[59,35,68,37,"AccountIndex_js_1"],[59,52,68,54],[59,53,68,55,"GenericAccountIndex"],[59,72,68,74],[59,75,69,14,"AccountIndex_js_1"],[59,92,69,31],[59,93,69,32,"GenericAccountIndex"],[59,112,69,51],[59,113,69,52,"calcLength"],[59,123,69,62],[59,124,69,63],[59,128,69,67],[59,129,69,68,"inner"],[59,134,69,73],[59,135,69,74],[59,138,70,14],[59,142,70,18],[59,143,70,19,"inner"],[59,148,70,24],[59,149,70,25,"encodedLength"],[59,162,70,38],[60,4,71,4],[61,4,72,4],[62,0,73,0],[63,0,74,0],[64,4,75,4,"toHex"],[64,9,75,9,"toHex"],[64,10,75,9],[64,12,75,12],[65,6,76,8],[65,13,76,15],[65,14,76,16],[65,15,76,17],[65,17,76,19,"util_1"],[65,23,76,25],[65,24,76,26,"u8aToHex"],[65,32,76,34],[65,34,76,36],[65,38,76,40],[65,39,76,41,"toU8a"],[65,44,76,46],[65,45,76,47],[65,46,76,48],[65,47,76,49],[66,4,77,4],[67,4,78,4],[68,0,79,0],[69,0,80,0],[70,4,81,4,"toRawType"],[70,13,81,13,"toRawType"],[70,14,81,13],[70,16,81,16],[71,6,82,8],[71,13,82,15],[71,22,82,24],[72,4,83,4],[73,4,84,4],[74,0,85,0],[75,0,86,0],[76,0,87,0],[77,4,88,4,"toU8a"],[77,9,88,9,"toU8a"],[77,10,88,10,"isBare"],[77,16,88,16],[77,18,88,18],[78,6,89,8],[78,12,89,14,"encoded"],[78,19,89,21],[78,22,89,24],[78,26,89,28],[78,27,89,29,"inner"],[78,32,89,34],[78,33,89,35,"toU8a"],[78,38,89,40],[78,39,89,41],[78,40,89,42],[78,41,89,43,"subarray"],[78,49,89,51],[78,50,89,52],[78,51,89,53],[78,53,89,55],[78,57,89,59],[78,58,89,60,"_rawLength"],[78,68,89,70],[78,69,89,71],[79,6,90,8],[79,13,90,15,"isBare"],[79,19,90,21],[79,22,91,14,"encoded"],[79,29,91,21],[79,32,92,14],[79,33,92,15],[79,34,92,16],[79,36,92,18,"util_1"],[79,42,92,24],[79,43,92,25,"u8aConcat"],[79,52,92,34],[79,54,92,36],[79,58,92,40],[79,59,92,41,"inner"],[79,64,92,46],[79,76,92,58,"AccountIndex_js_1"],[79,93,92,75],[79,94,92,76,"GenericAccountIndex"],[79,113,92,95],[79,116,93,18,"AccountIndex_js_1"],[79,133,93,35],[79,134,93,36,"GenericAccountIndex"],[79,153,93,55],[79,154,93,56,"writeLength"],[79,165,93,67],[79,166,93,68,"encoded"],[79,173,93,75],[79,174,93,76],[79,177,94,18,"exports"],[79,184,94,25],[79,185,94,26,"ACCOUNT_ID_PREFIX"],[79,202,94,43],[79,204,94,45,"encoded"],[79,211,94,52],[79,212,94,53],[80,4,95,4],[81,2,96,0],[82,2,97,0,"exports"],[82,9,97,7],[82,10,97,8,"GenericEthereumLookupSource"],[82,37,97,35],[82,40,97,38,"GenericEthereumLookupSource"],[82,67,97,65],[83,0,97,66],[83,3]],"functionMap":{"names":["<global>","decodeString","decodeU8a","decodeAddressOrIndex","GenericEthereumLookupSource","GenericEthereumLookupSource#constructor","GenericEthereumLookupSource#get__encodedLength","GenericEthereumLookupSource#get___rawLength","GenericEthereumLookupSource#toHex","GenericEthereumLookupSource#toRawType","GenericEthereumLookupSource#toU8a"],"mappings":"AAA;ACU;CDK;AEE;CFW;AGC;CHU;AIS;ICC;KDE;IEI;KFO;IGI;KHI;III;KJE;IKI;KLE;IMK;KNO;CJC"},"hasCjsExports":true},"type":"js/module"}]} |