mirror of
https://github.com/pezkuwichain/pezkuwi-mobile-app.git
synced 2026-05-30 10:01:02 +00:00
1 line
6.3 KiB
Plaintext
1 line
6.3 KiB
Plaintext
{"dependencies":[{"name":"rxjs","data":{"asyncType":null,"isESMImport":false,"locs":[{"start":{"line":5,"column":15,"index":165},"end":{"line":5,"column":30,"index":180}}],"key":"atDzfUGaJNRNtwyVumomzH/5ygw=","exportNames":["*"],"imports":1}},{"name":"../util/index.js","data":{"asyncType":null,"isESMImport":false,"locs":[{"start":{"line":6,"column":19,"index":201},"end":{"line":6,"column":46,"index":228}}],"key":"H94lp+EitftSFqDHaenrSs5zKB0=","exportNames":["*"],"imports":1}},{"name":"./util.js","data":{"asyncType":null,"isESMImport":false,"locs":[{"start":{"line":7,"column":18,"index":248},"end":{"line":7,"column":38,"index":268}}],"key":"RHtkf1pyimtRfZWAvWBZ833kE8E=","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.stakerSlashes = void 0;\n exports._stakerSlashes = _stakerSlashes;\n var rxjs_1 = require(_dependencyMap[0], \"rxjs\");\n var index_js_1 = require(_dependencyMap[1], \"../util/index.js\");\n var util_js_1 = require(_dependencyMap[2], \"./util.js\");\n function _stakerSlashes(instanceId, api) {\n return (0, index_js_1.memo)(instanceId, function (accountId, eras, withActive) {\n var stakerId = api.registry.createType('AccountId', accountId).toString();\n return api.derive.staking._erasSlashes(eras, withActive).pipe((0, rxjs_1.map)(function (slashes) {\n return slashes.map(function (_ref) {\n var era = _ref.era,\n nominators = _ref.nominators,\n validators = _ref.validators;\n return {\n era: era,\n total: nominators[stakerId] || validators[stakerId] || api.registry.createType('Balance')\n };\n });\n }));\n });\n }\n /**\n * @name stakerSlashes\n * @param { Uint8Array | string } accountId The stakers AccountId.\n * @param { boolean } withActive Whether to include the active era.\n * @description Retrieve the historical slashes (penalties) for a given staker.\n * @example\n * ```javascript\n * const stakerSlashes = await api.derive.staking.stakerSlashes(\n * ALICE, //Alice accountId\n * true\n * );\n * console.log(\n * 'Staker Slashes:',\n * stakerSlashes.map(({ era, total }) => `Era ${era}: Slashed ${total.toString()}`)\n * );\n * ```\n */\n exports.stakerSlashes = (0, util_js_1.erasHistoricApplyAccount)('_stakerSlashes');\n});","lineCount":46,"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,"stakerSlashes"],[7,23,3,21],[7,26,3,24],[7,31,3,29],[7,32,3,30],[8,2,4,0,"exports"],[8,9,4,7],[8,10,4,8,"_stakerSlashes"],[8,24,4,22],[8,27,4,25,"_stakerSlashes"],[8,41,4,39],[9,2,5,0],[9,6,5,6,"rxjs_1"],[9,12,5,12],[9,15,5,15,"require"],[9,22,5,22],[9,23,5,22,"_dependencyMap"],[9,37,5,22],[9,48,5,29],[9,49,5,30],[10,2,6,0],[10,6,6,6,"index_js_1"],[10,16,6,16],[10,19,6,19,"require"],[10,26,6,26],[10,27,6,26,"_dependencyMap"],[10,41,6,26],[10,64,6,45],[10,65,6,46],[11,2,7,0],[11,6,7,6,"util_js_1"],[11,15,7,15],[11,18,7,18,"require"],[11,25,7,25],[11,26,7,25,"_dependencyMap"],[11,40,7,25],[11,56,7,37],[11,57,7,38],[12,2,8,0],[12,11,8,9,"_stakerSlashes"],[12,25,8,23,"_stakerSlashes"],[12,26,8,24,"instanceId"],[12,36,8,34],[12,38,8,36,"api"],[12,41,8,39],[12,43,8,41],[13,4,9,4],[13,11,9,11],[13,12,9,12],[13,13,9,13],[13,15,9,15,"index_js_1"],[13,25,9,25],[13,26,9,26,"memo"],[13,30,9,30],[13,32,9,32,"instanceId"],[13,42,9,42],[13,44,9,44],[13,54,9,45,"accountId"],[13,63,9,54],[13,65,9,56,"eras"],[13,69,9,60],[13,71,9,62,"withActive"],[13,81,9,72],[13,83,9,77],[14,6,10,8],[14,10,10,14,"stakerId"],[14,18,10,22],[14,21,10,25,"api"],[14,24,10,28],[14,25,10,29,"registry"],[14,33,10,37],[14,34,10,38,"createType"],[14,44,10,48],[14,45,10,49],[14,56,10,60],[14,58,10,62,"accountId"],[14,67,10,71],[14,68,10,72],[14,69,10,73,"toString"],[14,77,10,81],[14,78,10,82],[14,79,10,83],[15,6,11,8],[15,13,11,15,"api"],[15,16,11,18],[15,17,11,19,"derive"],[15,23,11,25],[15,24,11,26,"staking"],[15,31,11,33],[15,32,11,34,"_erasSlashes"],[15,44,11,46],[15,45,11,47,"eras"],[15,49,11,51],[15,51,11,53,"withActive"],[15,61,11,63],[15,62,11,64],[15,63,11,65,"pipe"],[15,67,11,69],[15,68,11,70],[15,69,11,71],[15,70,11,72],[15,72,11,74,"rxjs_1"],[15,78,11,80],[15,79,11,81,"map"],[15,82,11,84],[15,84,11,86],[15,94,11,87,"slashes"],[15,101,11,94],[16,8,11,94],[16,15,11,99,"slashes"],[16,22,11,106],[16,23,11,107,"map"],[16,26,11,110],[16,27,11,111],[16,37,11,111,"_ref"],[16,41,11,111],[17,10,11,111],[17,14,11,114,"era"],[17,17,11,117],[17,20,11,117,"_ref"],[17,24,11,117],[17,25,11,114,"era"],[17,28,11,117],[18,12,11,119,"nominators"],[18,22,11,129],[18,25,11,129,"_ref"],[18,29,11,129],[18,30,11,119,"nominators"],[18,40,11,129],[19,12,11,131,"validators"],[19,22,11,141],[19,25,11,141,"_ref"],[19,29,11,141],[19,30,11,131,"validators"],[19,40,11,141],[20,10,11,141],[20,17,11,149],[21,12,12,12,"era"],[21,15,12,15],[21,17,12,12,"era"],[21,20,12,15],[22,12,13,12,"total"],[22,17,13,17],[22,19,13,19,"nominators"],[22,29,13,29],[22,30,13,30,"stakerId"],[22,38,13,38],[22,39,13,39],[22,43,13,43,"validators"],[22,53,13,53],[22,54,13,54,"stakerId"],[22,62,13,62],[22,63,13,63],[22,67,13,67,"api"],[22,70,13,70],[22,71,13,71,"registry"],[22,79,13,79],[22,80,13,80,"createType"],[22,90,13,90],[22,91,13,91],[22,100,13,100],[23,10,14,8],[23,11,14,9],[24,8,14,9],[24,9,14,10],[24,10,14,11],[25,6,14,11],[25,8,14,12],[25,9,14,13],[26,4,15,4],[26,5,15,5],[26,6,15,6],[27,2,16,0],[28,2,17,0],[29,0,18,0],[30,0,19,0],[31,0,20,0],[32,0,21,0],[33,0,22,0],[34,0,23,0],[35,0,24,0],[36,0,25,0],[37,0,26,0],[38,0,27,0],[39,0,28,0],[40,0,29,0],[41,0,30,0],[42,0,31,0],[43,0,32,0],[44,0,33,0],[45,2,34,0,"exports"],[45,9,34,7],[45,10,34,8,"stakerSlashes"],[45,23,34,21],[45,26,34,24],[45,27,34,25],[45,28,34,26],[45,30,34,28,"util_js_1"],[45,39,34,37],[45,40,34,38,"erasHistoricApplyAccount"],[45,64,34,62],[45,66,34,64],[45,82,34,80],[45,83,34,81],[46,0,34,82],[46,3]],"functionMap":{"names":["<global>","_stakerSlashes","<anonymous>","slashes.map$argument_0"],"mappings":"AAA;ACO;4CCC;+GCE;UDG;KDC;CDC"},"hasCjsExports":true},"type":"js/module"}]} |