n20-common-lib 2.19.13 → 3.0.0
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "n20-common-lib",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"scripts": {
|
|
6
6
|
"serve": "vue-cli-service serve",
|
|
@@ -18,7 +18,8 @@
|
|
|
18
18
|
"getI18n": "node ./node_modules/nstc-get-i18n --path ./server-config.jsonc --name lang",
|
|
19
19
|
"info": "node versionInfo.js",
|
|
20
20
|
"serve:theme": "vue-cli-service serve --testTheme",
|
|
21
|
-
"test": "vue-cli-service serve --test"
|
|
21
|
+
"test": "vue-cli-service serve --test",
|
|
22
|
+
"publish": "npm publish --tag legacy"
|
|
22
23
|
},
|
|
23
24
|
"main": "src/index.js",
|
|
24
25
|
"files": [
|
|
@@ -370,8 +370,8 @@ export default {
|
|
|
370
370
|
|
|
371
371
|
const width = column.minWidth || column.width
|
|
372
372
|
column['_width_'] = column['_width_'] || parseInt(width)
|
|
373
|
-
|
|
374
|
-
columnsWidth += column
|
|
373
|
+
column['width'] = parseInt(width)
|
|
374
|
+
columnsWidth += column.width
|
|
375
375
|
})
|
|
376
376
|
|
|
377
377
|
// 如果总宽度超过容器宽度,直接返回
|
|
@@ -383,7 +383,8 @@ export default {
|
|
|
383
383
|
return columns.map((column) => {
|
|
384
384
|
if (!column.type) {
|
|
385
385
|
const rate = column['_width_'] / columnsWidth
|
|
386
|
-
column['width'] = Math.max(windowWidth * rate, column.minWidth || column.width)
|
|
386
|
+
column['width'] = Math.floor(Math.max(windowWidth * rate, column.minWidth || column.width))
|
|
387
|
+
|
|
387
388
|
return column
|
|
388
389
|
}
|
|
389
390
|
return column
|