mirror of
https://github.com/pezkuwichain/pezkuwi-mobile-app.git
synced 2026-05-30 06:31:03 +00:00
1 line
2.6 KiB
Plaintext
1 line
2.6 KiB
Plaintext
{"dependencies":[],"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.stringShorten = stringShorten;\n /**\n * @name stringShorten\n * @summary Returns a string with maximum length\n * @description\n * Checks the string against the `prefixLength`, if longer than double this, shortens it by placing `..` in the middle of it\n * @example\n * <BR>\n *\n * ```javascript\n * import { stringShorten } from '@polkadot/util';\n *\n * stringShorten('1234567890', 2); // => 12..90\n * ```\n */\n function stringShorten(value) {\n var prefixLength = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 6;\n return value.length <= 2 + 2 * prefixLength ? value.toString() : `${value.substring(0, prefixLength)}…${value.slice(-prefixLength)}`;\n }\n});","lineCount":26,"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,"stringShorten"],[7,23,3,21],[7,26,3,24,"stringShorten"],[7,39,3,37],[8,2,4,0],[9,0,5,0],[10,0,6,0],[11,0,7,0],[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,2,18,0],[22,11,18,9,"stringShorten"],[22,24,18,22,"stringShorten"],[22,25,18,23,"value"],[22,30,18,28],[22,32,18,48],[23,4,18,48],[23,8,18,30,"prefixLength"],[23,20,18,42],[23,23,18,42,"arguments"],[23,32,18,42],[23,33,18,42,"length"],[23,39,18,42],[23,47,18,42,"arguments"],[23,56,18,42],[23,64,18,42,"undefined"],[23,73,18,42],[23,76,18,42,"arguments"],[23,85,18,42],[23,91,18,45],[23,92,18,46],[24,4,19,4],[24,11,19,11,"value"],[24,16,19,16],[24,17,19,17,"length"],[24,23,19,23],[24,27,19,27],[24,28,19,28],[24,31,19,31],[24,32,19,32],[24,35,19,35,"prefixLength"],[24,47,19,47],[24,50,20,10,"value"],[24,55,20,15],[24,56,20,16,"toString"],[24,64,20,24],[24,65,20,25],[24,66,20,26],[24,69,21,10],[24,72,21,13,"value"],[24,77,21,18],[24,78,21,19,"substring"],[24,87,21,28],[24,88,21,29],[24,89,21,30],[24,91,21,32,"prefixLength"],[24,103,21,44],[24,104,21,45],[24,108,21,49,"value"],[24,113,21,54],[24,114,21,55,"slice"],[24,119,21,60],[24,120,21,61],[24,121,21,62,"prefixLength"],[24,133,21,74],[24,134,21,75],[24,136,21,77],[25,2,22,0],[26,0,22,1],[26,3]],"functionMap":{"names":["<global>","stringShorten"],"mappings":"AAA;ACiB;CDI"},"hasCjsExports":true},"type":"js/module"}]} |