vxe-table 4.7.79 → 4.7.81

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.
Files changed (117) hide show
  1. package/README.ja-JP.md +1 -1
  2. package/README.md +1 -1
  3. package/es/grid/src/grid.js +17 -10
  4. package/es/locale/lang/en-US.js +0 -7
  5. package/es/locale/lang/hu-HU.d.ts +2 -0
  6. package/es/locale/lang/hu-HU.js +496 -501
  7. package/es/locale/lang/ja-JP.js +0 -7
  8. package/es/locale/lang/ko-KR.d.ts +2 -0
  9. package/es/locale/lang/ko-KR.js +0 -7
  10. package/es/locale/lang/pt-BR.js +0 -7
  11. package/es/locale/lang/ru-RU.d.ts +2 -0
  12. package/es/locale/lang/ru-RU.js +496 -503
  13. package/es/locale/lang/uk-UA.d.ts +2 -0
  14. package/es/locale/lang/uk-UA.js +666 -0
  15. package/es/locale/lang/vi-VN.js +0 -7
  16. package/es/locale/lang/zh-CHT.js +666 -0
  17. package/es/locale/lang/zh-CN.js +0 -7
  18. package/es/locale/lang/zh-HK.js +2 -2
  19. package/es/locale/lang/zh-MO.js +2 -2
  20. package/es/locale/lang/zh-TC.js +2 -673
  21. package/es/locale/lang/zh-TW.js +2 -2
  22. package/es/style.css +1 -1
  23. package/es/style.min.css +1 -1
  24. package/es/table/render/index.js +2 -10
  25. package/es/table/src/table.js +18 -7
  26. package/es/table/style.css +2 -2
  27. package/es/table/style.min.css +1 -1
  28. package/es/toolbar/src/toolbar.js +5 -0
  29. package/es/ui/index.js +2 -2
  30. package/es/ui/src/log.js +1 -1
  31. package/es/vxe-table/style.css +2 -2
  32. package/es/vxe-table/style.min.css +1 -1
  33. package/lib/grid/src/grid.js +18 -11
  34. package/lib/grid/src/grid.min.js +1 -1
  35. package/lib/index.umd.js +45 -38
  36. package/lib/index.umd.min.js +1 -1
  37. package/lib/locale/lang/en-US.js +0 -7
  38. package/lib/locale/lang/en-US.umd.js +0 -7
  39. package/lib/locale/lang/hu-HU.d.ts +2 -0
  40. package/lib/locale/lang/hu-HU.js +496 -501
  41. package/lib/locale/lang/hu-HU.min.js +1 -1
  42. package/lib/locale/lang/hu-HU.umd.js +686 -0
  43. package/lib/locale/lang/ja-JP.js +0 -7
  44. package/lib/locale/lang/ja-JP.umd.js +0 -7
  45. package/lib/locale/lang/ko-KR.d.ts +2 -0
  46. package/lib/locale/lang/ko-KR.js +0 -7
  47. package/lib/locale/lang/ko-KR.min.js +1 -1
  48. package/lib/locale/lang/ko-KR.umd.js +686 -0
  49. package/lib/locale/lang/pt-BR.js +0 -7
  50. package/lib/locale/lang/pt-BR.umd.js +0 -7
  51. package/lib/locale/lang/ru-RU.d.ts +2 -0
  52. package/lib/locale/lang/ru-RU.js +496 -503
  53. package/lib/locale/lang/ru-RU.min.js +1 -1
  54. package/lib/locale/lang/ru-RU.umd.js +686 -0
  55. package/lib/locale/lang/uk-UA.d.ts +2 -0
  56. package/lib/locale/lang/uk-UA.js +672 -0
  57. package/lib/locale/lang/uk-UA.min.js +1 -0
  58. package/lib/locale/lang/uk-UA.umd.js +686 -0
  59. package/lib/locale/lang/vi-VN.js +0 -7
  60. package/lib/locale/lang/zh-CHT.js +672 -0
  61. package/lib/locale/lang/zh-CHT.min.js +1 -0
  62. package/lib/locale/lang/zh-CN.js +0 -7
  63. package/lib/locale/lang/zh-CN.umd.js +0 -7
  64. package/lib/locale/lang/zh-HK.js +2 -2
  65. package/lib/locale/lang/zh-HK.min.js +1 -1
  66. package/lib/locale/lang/zh-HK.umd.js +7 -677
  67. package/lib/locale/lang/zh-MO.js +2 -2
  68. package/lib/locale/lang/zh-MO.min.js +1 -1
  69. package/lib/locale/lang/zh-MO.umd.js +7 -677
  70. package/lib/locale/lang/zh-TC.js +3 -673
  71. package/lib/locale/lang/zh-TC.min.js +1 -1
  72. package/lib/locale/lang/zh-TC.umd.js +7 -677
  73. package/lib/locale/lang/zh-TW.js +2 -2
  74. package/lib/locale/lang/zh-TW.min.js +1 -1
  75. package/lib/locale/lang/zh-TW.umd.js +7 -677
  76. package/lib/style.css +1 -1
  77. package/lib/style.min.css +1 -1
  78. package/lib/table/render/index.js +2 -10
  79. package/lib/table/render/index.min.js +1 -1
  80. package/lib/table/src/table.js +17 -7
  81. package/lib/table/src/table.min.js +1 -1
  82. package/lib/table/style/style.css +2 -2
  83. package/lib/table/style/style.min.css +1 -1
  84. package/lib/toolbar/src/toolbar.js +5 -0
  85. package/lib/toolbar/src/toolbar.min.js +1 -1
  86. package/lib/ui/index.js +2 -2
  87. package/lib/ui/index.min.js +1 -1
  88. package/lib/ui/src/log.js +1 -1
  89. package/lib/ui/src/log.min.js +1 -1
  90. package/lib/vxe-table/style/style.css +2 -2
  91. package/lib/vxe-table/style/style.min.css +1 -1
  92. package/package.json +4 -4
  93. package/packages/grid/src/grid.ts +16 -9
  94. package/packages/locale/lang/en-US.ts +0 -9
  95. package/packages/locale/lang/hu-HU.ts +496 -503
  96. package/packages/locale/lang/ja-JP.ts +0 -9
  97. package/packages/locale/lang/ko-KR.ts +0 -9
  98. package/packages/locale/lang/pt-BR.ts +0 -9
  99. package/packages/locale/lang/ru-RU.ts +496 -505
  100. package/packages/locale/lang/uk-UA.ts +666 -0
  101. package/packages/locale/lang/vi-VN.ts +0 -9
  102. package/packages/locale/lang/zh-CHT.ts +666 -0
  103. package/packages/locale/lang/zh-CN.ts +0 -9
  104. package/packages/locale/lang/zh-HK.ts +2 -2
  105. package/packages/locale/lang/zh-MO.ts +2 -2
  106. package/packages/locale/lang/zh-TC.ts +2 -674
  107. package/packages/locale/lang/zh-TW.ts +2 -2
  108. package/packages/table/render/index.ts +2 -10
  109. package/packages/table/src/table.ts +17 -7
  110. package/packages/toolbar/src/toolbar.ts +5 -0
  111. package/styles/components/table.scss +2 -2
  112. /package/es/{iconfont.1726116305532.ttf → iconfont.1727054403308.ttf} +0 -0
  113. /package/es/{iconfont.1726116305532.woff → iconfont.1727054403308.woff} +0 -0
  114. /package/es/{iconfont.1726116305532.woff2 → iconfont.1727054403308.woff2} +0 -0
  115. /package/lib/{iconfont.1726116305532.ttf → iconfont.1727054403308.ttf} +0 -0
  116. /package/lib/{iconfont.1726116305532.woff → iconfont.1727054403308.woff} +0 -0
  117. /package/lib/{iconfont.1726116305532.woff2 → iconfont.1727054403308.woff2} +0 -0
@@ -25,7 +25,7 @@ function getFormatDate (value: any, props: any, defaultFormat: string) {
25
25
  }
26
26
 
27
27
  function getLabelFormatDate (value: any, props: any) {
28
- return getFormatDate(value, props, getI18n(`vxe.input.date.labelFormat.${props.type}`))
28
+ return getFormatDate(value, props, getI18n(`vxe.input.date.labelFormat.${props.type || 'date'}`))
29
29
  }
30
30
 
31
31
  /**
@@ -629,15 +629,7 @@ renderer.mixin({
629
629
  const { row, column } = params
630
630
  let cellValue = XEUtils.get(row, column.field)
631
631
  if (cellValue) {
632
- switch (props.type) {
633
- case 'date':
634
- case 'week':
635
- case 'month':
636
- case 'quarter':
637
- case 'year':
638
- cellValue = getLabelFormatDate(cellValue, props)
639
- break
640
- }
632
+ cellValue = getLabelFormatDate(cellValue, props)
641
633
  }
642
634
  return getCellLabelVNs(renderOpts, params, cellValue)
643
635
  },
@@ -410,7 +410,7 @@ export default defineComponent({
410
410
  return Object.assign({}, getConfig().table.rowConfig, props.rowConfig) as VxeTablePropTypes.RowOpts
411
411
  })
412
412
 
413
- const computeResizeleOpts = computed(() => {
413
+ const computeResizeOpts = computed(() => {
414
414
  return Object.assign({}, getConfig().table.resizeConfig, props.resizeConfig) as VxeTablePropTypes.ResizeOpts
415
415
  })
416
416
 
@@ -647,7 +647,7 @@ export default defineComponent({
647
647
  computeSYOpts,
648
648
  computeColumnOpts,
649
649
  computeRowOpts,
650
- computeResizeleOpts,
650
+ computeResizeOpts,
651
651
  computeResizableOpts,
652
652
  computeSeqOpts,
653
653
  computeRadioOpts,
@@ -1132,10 +1132,20 @@ export default defineComponent({
1132
1132
  paddingSize = Math.floor(XEUtils.toNumber(cellStyle.paddingLeft) + XEUtils.toNumber(cellStyle.paddingRight)) + 2
1133
1133
  }
1134
1134
  let colWidth = column.renderAutoWidth - paddingSize
1135
- XEUtils.arrayEach(cellElList, (cellEl) => {
1136
- const labelEl = cellEl.firstChild as HTMLElement
1137
- if (labelEl) {
1138
- colWidth = Math.max(colWidth, Math.ceil(labelEl.offsetWidth) + 4)
1135
+ XEUtils.arrayEach(cellElList, (itemEl) => {
1136
+ const cellEl = itemEl as HTMLElement
1137
+ const thElem = cellEl.parentNode as HTMLElement
1138
+ let titleWidth = 0
1139
+ if (`${thElem.tagName}`.toLowerCase() === 'th') {
1140
+ XEUtils.arrayEach(cellEl.children, (btnEl) => {
1141
+ titleWidth += (btnEl as HTMLElement).offsetWidth + 1
1142
+ })
1143
+ } else {
1144
+ const labelEl = cellEl.firstChild as HTMLElement
1145
+ titleWidth = labelEl.offsetWidth
1146
+ }
1147
+ if (titleWidth) {
1148
+ colWidth = Math.max(colWidth, Math.ceil(titleWidth) + 4)
1139
1149
  }
1140
1150
  })
1141
1151
  column.renderAutoWidth = colWidth + paddingSize
@@ -6936,7 +6946,7 @@ export default defineComponent({
6936
6946
  })
6937
6947
 
6938
6948
  if (props.autoResize) {
6939
- const resizeOpts = computeResizeleOpts.value
6949
+ const resizeOpts = computeResizeOpts.value
6940
6950
  const { refreshDelay } = resizeOpts
6941
6951
  const el = refElem.value
6942
6952
  const parentEl = tablePrivateMethods.getParentElem()
@@ -310,6 +310,8 @@ export default defineComponent({
310
310
  round: child.round,
311
311
  status: child.status,
312
312
  content: child.name,
313
+ routerLink: item.routerLink,
314
+ permissionCode: item.permissionCode,
313
315
  onClick: ({ $event }) => isBtn ? btnEvent($event, child) : tolEvent($event, child)
314
316
  })
315
317
  : createCommentVNode()
@@ -352,6 +354,7 @@ export default defineComponent({
352
354
  round: item.round,
353
355
  status: item.status,
354
356
  content: item.name,
357
+ routerLink: item.routerLink,
355
358
  permissionCode: item.permissionCode,
356
359
  destroyOnClose: item.destroyOnClose,
357
360
  placement: item.placement,
@@ -408,6 +411,8 @@ export default defineComponent({
408
411
  round: item.round,
409
412
  status: item.status,
410
413
  content: item.name,
414
+ routerLink: item.routerLink,
415
+ permissionCode: item.permissionCode,
411
416
  destroyOnClose: item.destroyOnClose,
412
417
  placement: item.placement,
413
418
  transfer: item.transfer,
@@ -456,12 +456,12 @@
456
456
  // vertical-align: middle;
457
457
  // }
458
458
  .vxe-cell--required-icon {
459
- margin-right: 0.1em;
459
+ padding-right: 0.1em;
460
460
  }
461
461
  .vxe-cell--edit-icon,
462
462
  .vxe-cell-title-prefix-icon,
463
463
  .vxe-cell-title-suffix-icon {
464
- margin-right: 0.2em;
464
+ padding: 0.2em;
465
465
  }
466
466
  .vxe-cell-title-prefix-icon,
467
467
  .vxe-cell-title-suffix-icon {