mirror of
https://github.com/pezkuwichain/pezkuwi-mobile-app.git
synced 2026-05-30 12:21:01 +00:00
1 line
7.8 KiB
Plaintext
1 line
7.8 KiB
Plaintext
{"dependencies":[{"name":"@polkadot/x-bigint","data":{"asyncType":null,"isESMImport":true,"locs":[{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":44,"index":44}}],"key":"Xafw1y4jIaVcNbHtayie8UfNWW8=","exportNames":["*"],"imports":1}},{"name":"./consts.js","data":{"asyncType":null,"isESMImport":true,"locs":[{"start":{"line":2,"column":0,"index":45},"end":{"line":2,"column":39,"index":84}}],"key":"EFXF1CrSZjyHGyhwYaAmgbHhDvg=","exportNames":["*"],"imports":1}},{"name":"./toBigInt.js","data":{"asyncType":null,"isESMImport":true,"locs":[{"start":{"line":3,"column":0,"index":85},"end":{"line":3,"column":42,"index":127}}],"key":"FNvzERCwuoCqDVQbKXyeboBuZC0=","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.nToU8a = nToU8a;\n var _polkadotXBigint = require(_dependencyMap[0], \"@polkadot/x-bigint\");\n var _constsJs = require(_dependencyMap[1], \"./consts.js\");\n var _toBigIntJs = require(_dependencyMap[2], \"./toBigInt.js\");\n const DIV = (0, _polkadotXBigint.BigInt)(256);\n const NEG_MASK = (0, _polkadotXBigint.BigInt)(0xff);\n function toU8a(value, isLe, isNegative) {\n const arr = [];\n const withSigned = isNegative && value < _constsJs._0n;\n if (withSigned) {\n value = (value + _constsJs._1n) * -_constsJs._1n;\n }\n while (value !== _constsJs._0n) {\n const mod = value % DIV;\n const val = Number(withSigned ? mod ^ NEG_MASK : mod);\n if (isLe) {\n arr.push(val);\n } else {\n arr.unshift(val);\n }\n value = (value - mod) / DIV;\n }\n return Uint8Array.from(arr);\n }\n /**\n * @name nToU8a\n * @summary Creates a Uint8Array object from a bigint.\n */\n function nToU8a(value, {\n bitLength = -1,\n isLe = true,\n isNegative = false\n } = {}) {\n const valueBi = (0, _toBigIntJs.nToBigInt)(value);\n if (valueBi === _constsJs._0n) {\n return bitLength === -1 ? new Uint8Array(1) : new Uint8Array(Math.ceil((bitLength || 0) / 8));\n }\n const u8a = toU8a(valueBi, isLe, isNegative);\n if (bitLength === -1) {\n return u8a;\n }\n const byteLength = Math.ceil((bitLength || 0) / 8);\n const output = new Uint8Array(byteLength);\n if (isNegative) {\n output.fill(0xff);\n }\n output.set(u8a, isLe ? 0 : byteLength - u8a.length);\n return output;\n }\n});","lineCount":56,"map":[[7,2,31,0,"exports"],[7,9,31,0],[7,10,31,0,"nToU8a"],[7,16,31,0],[7,19,31,0,"nToU8a"],[7,25,31,0],[8,2,1,0],[8,6,1,0,"_polkadotXBigint"],[8,22,1,0],[8,25,1,0,"require"],[8,32,1,0],[8,33,1,0,"_dependencyMap"],[8,47,1,0],[9,2,2,0],[9,6,2,0,"_constsJs"],[9,15,2,0],[9,18,2,0,"require"],[9,25,2,0],[9,26,2,0,"_dependencyMap"],[9,40,2,0],[10,2,3,0],[10,6,3,0,"_toBigIntJs"],[10,17,3,0],[10,20,3,0,"require"],[10,27,3,0],[10,28,3,0,"_dependencyMap"],[10,42,3,0],[11,2,4,0],[11,8,4,6,"DIV"],[11,11,4,9],[11,14,4,12],[11,18,4,12,"BigInt"],[11,34,4,18],[11,35,4,18,"BigInt"],[11,41,4,18],[11,43,4,19],[11,46,4,22],[11,47,4,23],[12,2,5,0],[12,8,5,6,"NEG_MASK"],[12,16,5,14],[12,19,5,17],[12,23,5,17,"BigInt"],[12,39,5,23],[12,40,5,23,"BigInt"],[12,46,5,23],[12,48,5,24],[12,52,5,28],[12,53,5,29],[13,2,6,0],[13,11,6,9,"toU8a"],[13,16,6,14,"toU8a"],[13,17,6,15,"value"],[13,22,6,20],[13,24,6,22,"isLe"],[13,28,6,26],[13,30,6,28,"isNegative"],[13,40,6,38],[13,42,6,40],[14,4,7,4],[14,10,7,10,"arr"],[14,13,7,13],[14,16,7,16],[14,18,7,18],[15,4,8,4],[15,10,8,10,"withSigned"],[15,20,8,20],[15,23,8,23,"isNegative"],[15,33,8,33],[15,37,8,38,"value"],[15,42,8,43],[15,45,8,46,"_0n"],[15,54,8,49],[15,55,8,49,"_0n"],[15,58,8,50],[16,4,9,4],[16,8,9,8,"withSigned"],[16,18,9,18],[16,20,9,20],[17,6,10,8,"value"],[17,11,10,13],[17,14,10,16],[17,15,10,17,"value"],[17,20,10,22],[17,23,10,25,"_1n"],[17,32,10,28],[17,33,10,28,"_1n"],[17,36,10,28],[17,40,10,32],[17,41,10,33,"_1n"],[17,50,10,36],[17,51,10,36,"_1n"],[17,54,10,36],[18,4,11,4],[19,4,12,4],[19,11,12,11,"value"],[19,16,12,16],[19,21,12,21,"_0n"],[19,30,12,24],[19,31,12,24,"_0n"],[19,34,12,24],[19,36,12,26],[20,6,13,8],[20,12,13,14,"mod"],[20,15,13,17],[20,18,13,20,"value"],[20,23,13,25],[20,26,13,28,"DIV"],[20,29,13,31],[21,6,14,8],[21,12,14,14,"val"],[21,15,14,17],[21,18,14,20,"Number"],[21,24,14,26],[21,25,14,27,"withSigned"],[21,35,14,37],[21,38,15,14,"mod"],[21,41,15,17],[21,44,15,20,"NEG_MASK"],[21,52,15,28],[21,55,16,14,"mod"],[21,58,16,17],[21,59,16,18],[22,6,17,8],[22,10,17,12,"isLe"],[22,14,17,16],[22,16,17,18],[23,8,18,12,"arr"],[23,11,18,15],[23,12,18,16,"push"],[23,16,18,20],[23,17,18,21,"val"],[23,20,18,24],[23,21,18,25],[24,6,19,8],[24,7,19,9],[24,13,20,13],[25,8,21,12,"arr"],[25,11,21,15],[25,12,21,16,"unshift"],[25,19,21,23],[25,20,21,24,"val"],[25,23,21,27],[25,24,21,28],[26,6,22,8],[27,6,23,8,"value"],[27,11,23,13],[27,14,23,16],[27,15,23,17,"value"],[27,20,23,22],[27,23,23,25,"mod"],[27,26,23,28],[27,30,23,32,"DIV"],[27,33,23,35],[28,4,24,4],[29,4,25,4],[29,11,25,11,"Uint8Array"],[29,21,25,21],[29,22,25,22,"from"],[29,26,25,26],[29,27,25,27,"arr"],[29,30,25,30],[29,31,25,31],[30,2,26,0],[31,2,27,0],[32,0,28,0],[33,0,29,0],[34,0,30,0],[35,2,31,7],[35,11,31,16,"nToU8a"],[35,17,31,22,"nToU8a"],[35,18,31,23,"value"],[35,23,31,28],[35,25,31,30],[36,4,31,32,"bitLength"],[36,13,31,41],[36,16,31,44],[36,17,31,45],[36,18,31,46],[37,4,31,48,"isLe"],[37,8,31,52],[37,11,31,55],[37,15,31,59],[38,4,31,61,"isNegative"],[38,14,31,71],[38,17,31,74],[39,2,31,80],[39,3,31,81],[39,6,31,84],[39,7,31,85],[39,8,31,86],[39,10,31,88],[40,4,32,4],[40,10,32,10,"valueBi"],[40,17,32,17],[40,20,32,20],[40,24,32,20,"nToBigInt"],[40,35,32,29],[40,36,32,29,"nToBigInt"],[40,45,32,29],[40,47,32,30,"value"],[40,52,32,35],[40,53,32,36],[41,4,33,4],[41,8,33,8,"valueBi"],[41,15,33,15],[41,20,33,20,"_0n"],[41,29,33,23],[41,30,33,23,"_0n"],[41,33,33,23],[41,35,33,25],[42,6,34,8],[42,13,34,15,"bitLength"],[42,22,34,24],[42,27,34,29],[42,28,34,30],[42,29,34,31],[42,32,35,14],[42,36,35,18,"Uint8Array"],[42,46,35,28],[42,47,35,29],[42,48,35,30],[42,49,35,31],[42,52,36,14],[42,56,36,18,"Uint8Array"],[42,66,36,28],[42,67,36,29,"Math"],[42,71,36,33],[42,72,36,34,"ceil"],[42,76,36,38],[42,77,36,39],[42,78,36,40,"bitLength"],[42,87,36,49],[42,91,36,53],[42,92,36,54],[42,96,36,58],[42,97,36,59],[42,98,36,60],[42,99,36,61],[43,4,37,4],[44,4,38,4],[44,10,38,10,"u8a"],[44,13,38,13],[44,16,38,16,"toU8a"],[44,21,38,21],[44,22,38,22,"valueBi"],[44,29,38,29],[44,31,38,31,"isLe"],[44,35,38,35],[44,37,38,37,"isNegative"],[44,47,38,47],[44,48,38,48],[45,4,39,4],[45,8,39,8,"bitLength"],[45,17,39,17],[45,22,39,22],[45,23,39,23],[45,24,39,24],[45,26,39,26],[46,6,40,8],[46,13,40,15,"u8a"],[46,16,40,18],[47,4,41,4],[48,4,42,4],[48,10,42,10,"byteLength"],[48,20,42,20],[48,23,42,23,"Math"],[48,27,42,27],[48,28,42,28,"ceil"],[48,32,42,32],[48,33,42,33],[48,34,42,34,"bitLength"],[48,43,42,43],[48,47,42,47],[48,48,42,48],[48,52,42,52],[48,53,42,53],[48,54,42,54],[49,4,43,4],[49,10,43,10,"output"],[49,16,43,16],[49,19,43,19],[49,23,43,23,"Uint8Array"],[49,33,43,33],[49,34,43,34,"byteLength"],[49,44,43,44],[49,45,43,45],[50,4,44,4],[50,8,44,8,"isNegative"],[50,18,44,18],[50,20,44,20],[51,6,45,8,"output"],[51,12,45,14],[51,13,45,15,"fill"],[51,17,45,19],[51,18,45,20],[51,22,45,24],[51,23,45,25],[52,4,46,4],[53,4,47,4,"output"],[53,10,47,10],[53,11,47,11,"set"],[53,14,47,14],[53,15,47,15,"u8a"],[53,18,47,18],[53,20,47,20,"isLe"],[53,24,47,24],[53,27,47,27],[53,28,47,28],[53,31,47,31,"byteLength"],[53,41,47,41],[53,44,47,44,"u8a"],[53,47,47,47],[53,48,47,48,"length"],[53,54,47,54],[53,55,47,55],[54,4,48,4],[54,11,48,11,"output"],[54,17,48,17],[55,2,49,0],[56,0,49,1],[56,3]],"functionMap":{"names":["<global>","toU8a","nToU8a"],"mappings":"AAA;ACK;CDoB;OEK;CFkB"},"hasCjsExports":false},"type":"js/module"}]} |