| Server IP : 68.183.124.220 / Your IP : 216.73.217.137 Web Server : Apache/2.4.18 (Ubuntu) System : Linux Sandbox-A 4.4.0-210-generic #242-Ubuntu SMP Fri Apr 16 09:57:56 UTC 2021 x86_64 User : gavin ( 1000) PHP Version : 7.0.33-0ubuntu0.16.04.16 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority, MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /home/gavin/workspace/happymandarin/node_modules/table/dist/ |
Upload File : |
'use strict';
Object.defineProperty(exports, "__esModule", {
value: true
});
var cov_2ah9qi3g32 = function () {
var path = '/Users/gajuskuizinas/Documents/dev/gajus/table/src/truncateTableData.js',
hash = '206286e5f3c48d9bf4d4c90ecb0d671778434f3b',
global = new Function('return this')(),
gcv = '__coverage__',
coverageData = {
path: '/Users/gajuskuizinas/Documents/dev/gajus/table/src/truncateTableData.js',
statementMap: {
'0': {
start: {
line: 10,
column: 2
},
end: {
line: 16,
column: 5
}
},
'1': {
start: {
line: 11,
column: 4
},
end: {
line: 15,
column: 7
}
},
'2': {
start: {
line: 12,
column: 6
},
end: {
line: 14,
column: 9
}
}
},
fnMap: {
'0': {
name: '(anonymous_0)',
decl: {
start: {
line: 9,
column: 15
},
end: {
line: 9,
column: 16
}
},
loc: {
start: {
line: 9,
column: 33
},
end: {
line: 17,
column: 1
}
}
},
'1': {
name: '(anonymous_1)',
decl: {
start: {
line: 10,
column: 21
},
end: {
line: 10,
column: 22
}
},
loc: {
start: {
line: 10,
column: 32
},
end: {
line: 16,
column: 3
}
}
},
'2': {
name: '(anonymous_2)',
decl: {
start: {
line: 11,
column: 24
},
end: {
line: 11,
column: 25
}
},
loc: {
start: {
line: 11,
column: 44
},
end: {
line: 15,
column: 5
}
}
}
},
branchMap: {},
s: {
'0': 0,
'1': 0,
'2': 0
},
f: {
'0': 0,
'1': 0,
'2': 0
},
b: {}
},
coverage = global[gcv] || (global[gcv] = {});
if (coverage[path] && coverage[path].hash === hash) {
return coverage[path];
}
coverageData.hash = hash;
return coverage[path] = coverageData;
}();
var _lodash = require('lodash');
var _lodash2 = _interopRequireDefault(_lodash);
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
/**
* @todo Make it work with ASCII content.
* @param {table~row[]} rows
* @param {Object} config
* @returns {table~row[]}
*/
exports.default = (rows, config) => {
++cov_2ah9qi3g32.f[0];
++cov_2ah9qi3g32.s[0];
return _lodash2.default.map(rows, cells => {
++cov_2ah9qi3g32.f[1];
++cov_2ah9qi3g32.s[1];
return _lodash2.default.map(cells, (content, index) => {
++cov_2ah9qi3g32.f[2];
++cov_2ah9qi3g32.s[2];
return _lodash2.default.truncate(content, {
length: config.columns[index].truncate
});
});
});
};
module.exports = exports['default'];