mirror of
https://github.com/pezkuwichain/pezkuwi-mobile-app.git
synced 2026-05-30 06:31:03 +00:00
1 line
7.2 KiB
Plaintext
1 line
7.2 KiB
Plaintext
{"dependencies":[{"name":"@polkadot/util","data":{"asyncType":null,"isESMImport":false,"locs":[{"start":{"line":4,"column":15,"index":118},"end":{"line":4,"column":40,"index":143}}],"key":"u0mzEw2nilnHoUWtEdZl0JKHutA=","exportNames":["*"],"imports":1}},{"name":"./Getters.js","data":{"asyncType":null,"isESMImport":false,"locs":[{"start":{"line":5,"column":21,"index":166},"end":{"line":5,"column":44,"index":189}}],"key":"BQbG96NY/7NRJg7jb6Gfs81D2N8=","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.ApiBase = void 0;\n const util_1 = require(_dependencyMap[0], \"@polkadot/util\");\n const Getters_js_1 = require(_dependencyMap[1], \"./Getters.js\");\n class ApiBase extends Getters_js_1.Getters {\n /**\n * @description Create an instance of the class\n *\n * @param options Options object to create API instance or a Provider instance\n *\n * @example\n * <BR>\n *\n * ```javascript\n * import Api from '@polkadot/api/promise';\n *\n * const api = new Api().isReady();\n *\n * api.rpc.subscribeNewHeads((header) => {\n * console.log(`new block #${header.number.toNumber()}`);\n * });\n * ```\n */\n constructor(options = {}, type, decorateMethod) {\n super(options, type, decorateMethod);\n }\n /**\n * @description Connect from the underlying provider, halting all network traffic\n */\n connect() {\n return this._rpcCore.connect();\n }\n /**\n * @description Disconnect from the underlying provider, halting all network traffic\n */\n disconnect() {\n this._unsubscribe();\n return this._rpcCore.disconnect();\n }\n /**\n * @description Set an external signer which will be used to sign extrinsic when account passed in is not KeyringPair\n */\n setSigner(signer) {\n this._rx.signer = signer;\n }\n /**\n * @description Signs a raw signer payload, string or Uint8Array\n */\n async sign(address, data, {\n signer\n } = {}) {\n if ((0, util_1.isString)(address)) {\n const _signer = signer || this._rx.signer;\n if (!_signer?.signRaw) {\n throw new Error('No signer exists with a signRaw interface. You possibly need to pass through an explicit keypair for the origin so it can be used for signing.');\n }\n return (await _signer.signRaw((0, util_1.objectSpread)({\n type: 'bytes'\n }, data, {\n address\n }))).signature;\n }\n return (0, util_1.u8aToHex)(address.sign((0, util_1.u8aToU8a)(data.data)));\n }\n }\n exports.ApiBase = ApiBase;\n});","lineCount":72,"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,"ApiBase"],[7,17,3,15],[7,20,3,18],[7,25,3,23],[7,26,3,24],[8,2,4,0],[8,8,4,6,"util_1"],[8,14,4,12],[8,17,4,15,"require"],[8,24,4,22],[8,25,4,22,"_dependencyMap"],[8,39,4,22],[8,60,4,39],[8,61,4,40],[9,2,5,0],[9,8,5,6,"Getters_js_1"],[9,20,5,18],[9,23,5,21,"require"],[9,30,5,28],[9,31,5,28,"_dependencyMap"],[9,45,5,28],[9,64,5,43],[9,65,5,44],[10,2,6,0],[10,8,6,6,"ApiBase"],[10,15,6,13],[10,24,6,22,"Getters_js_1"],[10,36,6,34],[10,37,6,35,"Getters"],[10,44,6,42],[10,45,6,43],[11,4,7,4],[12,0,8,0],[13,0,9,0],[14,0,10,0],[15,0,11,0],[16,0,12,0],[17,0,13,0],[18,0,14,0],[19,0,15,0],[20,0,16,0],[21,0,17,0],[22,0,18,0],[23,0,19,0],[24,0,20,0],[25,0,21,0],[26,0,22,0],[27,0,23,0],[28,0,24,0],[29,4,25,4,"constructor"],[29,15,25,15,"constructor"],[29,16,25,16,"options"],[29,23,25,23],[29,26,25,26],[29,27,25,27],[29,28,25,28],[29,30,25,30,"type"],[29,34,25,34],[29,36,25,36,"decorateMethod"],[29,50,25,50],[29,52,25,52],[30,6,26,8],[30,11,26,13],[30,12,26,14,"options"],[30,19,26,21],[30,21,26,23,"type"],[30,25,26,27],[30,27,26,29,"decorateMethod"],[30,41,26,43],[30,42,26,44],[31,4,27,4],[32,4,28,4],[33,0,29,0],[34,0,30,0],[35,4,31,4,"connect"],[35,11,31,11,"connect"],[35,12,31,11],[35,14,31,14],[36,6,32,8],[36,13,32,15],[36,17,32,19],[36,18,32,20,"_rpcCore"],[36,26,32,28],[36,27,32,29,"connect"],[36,34,32,36],[36,35,32,37],[36,36,32,38],[37,4,33,4],[38,4,34,4],[39,0,35,0],[40,0,36,0],[41,4,37,4,"disconnect"],[41,14,37,14,"disconnect"],[41,15,37,14],[41,17,37,17],[42,6,38,8],[42,10,38,12],[42,11,38,13,"_unsubscribe"],[42,23,38,25],[42,24,38,26],[42,25,38,27],[43,6,39,8],[43,13,39,15],[43,17,39,19],[43,18,39,20,"_rpcCore"],[43,26,39,28],[43,27,39,29,"disconnect"],[43,37,39,39],[43,38,39,40],[43,39,39,41],[44,4,40,4],[45,4,41,4],[46,0,42,0],[47,0,43,0],[48,4,44,4,"setSigner"],[48,13,44,13,"setSigner"],[48,14,44,14,"signer"],[48,20,44,20],[48,22,44,22],[49,6,45,8],[49,10,45,12],[49,11,45,13,"_rx"],[49,14,45,16],[49,15,45,17,"signer"],[49,21,45,23],[49,24,45,26,"signer"],[49,30,45,32],[50,4,46,4],[51,4,47,4],[52,0,48,0],[53,0,49,0],[54,4,50,4],[54,10,50,10,"sign"],[54,14,50,14,"sign"],[54,15,50,15,"address"],[54,22,50,22],[54,24,50,24,"data"],[54,28,50,28],[54,30,50,30],[55,6,50,32,"signer"],[56,4,50,39],[56,5,50,40],[56,8,50,43],[56,9,50,44],[56,10,50,45],[56,12,50,47],[57,6,51,8],[57,10,51,12],[57,11,51,13],[57,12,51,14],[57,14,51,16,"util_1"],[57,20,51,22],[57,21,51,23,"isString"],[57,29,51,31],[57,31,51,33,"address"],[57,38,51,40],[57,39,51,41],[57,41,51,43],[58,8,52,12],[58,14,52,18,"_signer"],[58,21,52,25],[58,24,52,28,"signer"],[58,30,52,34],[58,34,52,38],[58,38,52,42],[58,39,52,43,"_rx"],[58,42,52,46],[58,43,52,47,"signer"],[58,49,52,53],[59,8,53,12],[59,12,53,16],[59,13,53,17,"_signer"],[59,20,53,24],[59,22,53,26,"signRaw"],[59,29,53,33],[59,31,53,35],[60,10,54,16],[60,16,54,22],[60,20,54,26,"Error"],[60,25,54,31],[60,26,54,32],[60,170,54,176],[60,171,54,177],[61,8,55,12],[62,8,56,12],[62,15,56,19],[62,16,56,20],[62,22,56,26,"_signer"],[62,29,56,33],[62,30,56,34,"signRaw"],[62,37,56,41],[62,38,56,42],[62,39,56,43],[62,40,56,44],[62,42,56,46,"util_1"],[62,48,56,52],[62,49,56,53,"objectSpread"],[62,61,56,65],[62,63,56,67],[63,10,56,69,"type"],[63,14,56,73],[63,16,56,75],[64,8,56,83],[64,9,56,84],[64,11,56,86,"data"],[64,15,56,90],[64,17,56,92],[65,10,56,94,"address"],[66,8,56,102],[66,9,56,103],[66,10,56,104],[66,11,56,105],[66,13,56,107,"signature"],[66,22,56,116],[67,6,57,8],[68,6,58,8],[68,13,58,15],[68,14,58,16],[68,15,58,17],[68,17,58,19,"util_1"],[68,23,58,25],[68,24,58,26,"u8aToHex"],[68,32,58,34],[68,34,58,36,"address"],[68,41,58,43],[68,42,58,44,"sign"],[68,46,58,48],[68,47,58,49],[68,48,58,50],[68,49,58,51],[68,51,58,53,"util_1"],[68,57,58,59],[68,58,58,60,"u8aToU8a"],[68,66,58,68],[68,68,58,70,"data"],[68,72,58,74],[68,73,58,75,"data"],[68,77,58,79],[68,78,58,80],[68,79,58,81],[68,80,58,82],[69,4,59,4],[70,2,60,0],[71,2,61,0,"exports"],[71,9,61,7],[71,10,61,8,"ApiBase"],[71,17,61,15],[71,20,61,18,"ApiBase"],[71,27,61,25],[72,0,61,26],[72,3]],"functionMap":{"names":["<global>","ApiBase","ApiBase#constructor","ApiBase#connect","ApiBase#disconnect","ApiBase#setSigner","ApiBase#sign"],"mappings":"AAA;ACK;ICmB;KDE;IEI;KFE;IGI;KHG;III;KJE;IKI;KLS;CDC"},"hasCjsExports":true},"type":"js/module"}]} |