tty-table 4.1.6 → 4.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/package.json +6 -5
- package/src/factory.d.ts +1 -1
- package/src/format.js +2 -0
- package/src/render.js +1 -1
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# tty-table 端子台
|
|
2
2
|
|
|
3
|
-
[](http://badge.fury.io/js/tty-table) [](https://coveralls.io/github/tecfu/tty-table?branch=master)
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
Display your data in a table using a terminal, browser, or browser console.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tty-table",
|
|
3
|
-
"version": "4.1
|
|
3
|
+
"version": "4.2.1",
|
|
4
4
|
"description": "Node cli table",
|
|
5
5
|
"main": "src/main.js",
|
|
6
6
|
"types": "src/factory.d.ts",
|
|
@@ -54,17 +54,18 @@
|
|
|
54
54
|
"homepage": "https://github.com/tecfu/tty-table",
|
|
55
55
|
"dependencies": {
|
|
56
56
|
"chalk": "^4.1.2",
|
|
57
|
-
"csv": "^5.5.
|
|
58
|
-
"kleur": "^4.1.
|
|
57
|
+
"csv": "^5.5.3",
|
|
58
|
+
"kleur": "^4.1.5",
|
|
59
59
|
"smartwrap": "^2.0.2",
|
|
60
|
-
"strip-ansi": "^6.0.
|
|
60
|
+
"strip-ansi": "^6.0.1",
|
|
61
61
|
"wcwidth": "^1.0.1",
|
|
62
|
-
"yargs": "^17.
|
|
62
|
+
"yargs": "^17.7.1"
|
|
63
63
|
},
|
|
64
64
|
"devDependencies": {
|
|
65
65
|
"@rollup/plugin-commonjs": "^11.0.2",
|
|
66
66
|
"@rollup/plugin-node-resolve": "^7.1.1",
|
|
67
67
|
"@rollup/plugin-replace": "^2.3.1",
|
|
68
|
+
"axios-error": "^1.0.4",
|
|
68
69
|
"babel-core": "^6.26.3",
|
|
69
70
|
"babel-preset-babili": "0.1.4",
|
|
70
71
|
"babel-preset-es2015": "^6.24.1",
|
package/src/factory.d.ts
CHANGED
package/src/format.js
CHANGED
|
@@ -274,6 +274,8 @@ module.exports.getColumnWidths = (config, rows) => {
|
|
|
274
274
|
const totalRelativeWidths = relativeWidths.reduce((prev, current) => prev + current)
|
|
275
275
|
widths = (totalRelativeWidths < totalWidth) ? relativeWidths : widths
|
|
276
276
|
}
|
|
277
|
+
} else {
|
|
278
|
+
widths = widths.map(Math.floor)
|
|
277
279
|
}
|
|
278
280
|
|
|
279
281
|
return widths
|