/var/www/myprog.com.ua/server/node/node_modules/gauge
NameSizeModeActions
base-theme.js3950644editdlrm
CHANGELOG.md64310644editdlrm
error.js6160644editdlrm
has-color.js990644editdlrm
index.js69980644editdlrm
LICENSE7510644editdlrm
package.json14310644editdlrm
plumbing.js12690644editdlrm
process.js890644editdlrm
progress-bar.js10000644editdlrm
README.md154110644editdlrm
render-template.js56460644editdlrm
set-immediate.js1390644editdlrm
set-interval.js930644editdlrm
spin.js1050644editdlrm
template-item.js19030644editdlrm
theme-set.js36920644editdlrm
themes.js16530644editdlrm
wide-truncate.js8280644editdlrm
Edit: /var/www/myprog.com.ua/server/node/node_modules/gauge/wide-truncate.js (828B)
'use strict' var stringWidth = require('string-width') var stripAnsi = require('strip-ansi') module.exports = wideTruncate function wideTruncate (str, target) { if (stringWidth(str) === 0) return str if (target <= 0) return '' if (stringWidth(str) <= target) return str // We compute the number of bytes of ansi sequences here and add // that to our initial truncation to ensure that we don't slice one // that we want to keep in half. var noAnsi = stripAnsi(str) var ansiSize = str.length + noAnsi.length var truncated = str.slice(0, target + ansiSize) // we have to shrink the result to account for our ansi sequence buffer // (if an ansi sequence was truncated) and double width characters. while (stringWidth(truncated) > target) { truncated = truncated.slice(0, -1) } return truncated }