diff options
Diffstat (limited to 'node_modules/utila/scripts/js/lib/string.js')
-rw-r--r-- | node_modules/utila/scripts/js/lib/string.js | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/node_modules/utila/scripts/js/lib/string.js b/node_modules/utila/scripts/js/lib/string.js new file mode 100644 index 000000000..d49a48ea2 --- /dev/null +++ b/node_modules/utila/scripts/js/lib/string.js @@ -0,0 +1,15 @@ +module.exports = { + pad: function(n, width, z) { + if (z == null) { + z = '0'; + } + n = n + ''; + if (n.length >= width) { + return n; + } else { + return new Array(width - n.length + 1).join(z) + n; + } + } +}; + +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic3RyaW5nLmpzIiwic291cmNlUm9vdCI6Ii4uXFwuLiIsInNvdXJjZXMiOlsiY29mZmVlXFxsaWJcXHN0cmluZy5jb2ZmZWUiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFJQUEsTUlBTSxDSUFDLE9JQVAsR0lLQztBSUFBLEVJQUEsR0lBQSxFSUFLLFNJQUMsQ0lBRCxFSUFJLEtJQUosRUlBVyxDSUFYLEdJQUE7O01JQVcsSUlBSTtLSUVuQjtBSUFBLElJQUEsQ0lBQSxHSUFJLENJQUEsR0lBSSxFSUFSLENJQUE7QUlFQSxJSUFBLElJQUcsQ0lBQyxDSUFDLE1JQUYsSUlBWSxLSUFmO2FJRUMsRUlGRDtLSUFBLE1JQUE7YUlNSyxJSUFBLEtJQUEsQ0lBTSxLSUFBLEdJQVEsQ0lBQyxDSUFDLE1JQVYsR0lBbUIsQ0lBekIsQ0lBMkIsQ0lBQyxJSUE1QixDSUFpQyxDSUFqQyxDSUFKLEdJQTBDLEVJTjNDO0tJSkk7RUlBQSxDSUFMO0NBTEQsQ0FBQSIsInNvdXJjZXNDb250ZW50IjpbIm1vZHVsZS5leHBvcnRzID0gYXJyYXkgPVxuXG5cdCMjI1xuXHRUcmllcyB0byB0dXJuIGFueXRoaW5nIGludG8gYW4gYXJyYX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