vxe-table 4.7.64 → 4.7.66

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 (109) hide show
  1. package/es/grid/src/grid.js +21 -11
  2. package/es/locale/lang/en-US.js +17 -8
  3. package/es/locale/lang/es-ES.js +17 -8
  4. package/es/locale/lang/hu-HU.js +624 -0
  5. package/es/locale/lang/ja-JP.js +17 -8
  6. package/es/locale/lang/ko-KR.js +634 -0
  7. package/es/locale/lang/pt-BR.js +17 -8
  8. package/es/locale/lang/ru-RU.js +634 -0
  9. package/es/locale/lang/vi-VN.js +634 -0
  10. package/es/locale/lang/zh-CN.js +17 -8
  11. package/es/locale/lang/zh-TC.js +75 -66
  12. package/es/style.css +1 -1
  13. package/es/style.min.css +1 -1
  14. package/es/table/module/custom/panel.js +12 -11
  15. package/es/table/module/edit/hook.js +11 -10
  16. package/es/table/module/export/hook.js +10 -6
  17. package/es/table/render/index.js +95 -84
  18. package/es/table/src/table.js +22 -2
  19. package/es/table/style.css +8 -4
  20. package/es/table/style.min.css +1 -1
  21. package/es/toolbar/src/toolbar.js +7 -7
  22. package/es/ui/index.js +6 -4
  23. package/es/ui/src/log.js +1 -1
  24. package/es/vxe-table/style.css +8 -4
  25. package/es/vxe-table/style.min.css +1 -1
  26. package/lib/grid/src/grid.js +25 -14
  27. package/lib/grid/src/grid.min.js +1 -1
  28. package/lib/index.umd.js +227 -150
  29. package/lib/index.umd.min.js +1 -1
  30. package/lib/locale/lang/en-US.js +17 -8
  31. package/lib/locale/lang/en-US.min.js +1 -1
  32. package/lib/locale/lang/en-US.umd.js +17 -8
  33. package/lib/locale/lang/es-ES.js +17 -8
  34. package/lib/locale/lang/es-ES.min.js +1 -1
  35. package/lib/locale/lang/es-ES.umd.js +17 -8
  36. package/lib/locale/lang/hu-HU.js +630 -0
  37. package/lib/locale/lang/hu-HU.min.js +1 -0
  38. package/lib/locale/lang/ja-JP.js +17 -8
  39. package/lib/locale/lang/ja-JP.min.js +1 -1
  40. package/lib/locale/lang/ja-JP.umd.js +17 -8
  41. package/lib/locale/lang/ko-KR.js +640 -0
  42. package/lib/locale/lang/ko-KR.min.js +1 -0
  43. package/lib/locale/lang/pt-BR.js +17 -8
  44. package/lib/locale/lang/pt-BR.min.js +1 -1
  45. package/lib/locale/lang/pt-BR.umd.js +17 -8
  46. package/lib/locale/lang/ru-RU.js +640 -0
  47. package/lib/locale/lang/ru-RU.min.js +1 -0
  48. package/lib/locale/lang/vi-VN.js +640 -0
  49. package/lib/locale/lang/vi-VN.min.js +1 -0
  50. package/lib/locale/lang/zh-CN.js +17 -8
  51. package/lib/locale/lang/zh-CN.min.js +1 -1
  52. package/lib/locale/lang/zh-CN.umd.js +17 -8
  53. package/lib/locale/lang/zh-HK.min.js +1 -1
  54. package/lib/locale/lang/zh-HK.umd.js +75 -66
  55. package/lib/locale/lang/zh-MO.min.js +1 -1
  56. package/lib/locale/lang/zh-MO.umd.js +75 -66
  57. package/lib/locale/lang/zh-TC.js +75 -66
  58. package/lib/locale/lang/zh-TC.min.js +1 -1
  59. package/lib/locale/lang/zh-TC.umd.js +75 -66
  60. package/lib/locale/lang/zh-TW.min.js +1 -1
  61. package/lib/locale/lang/zh-TW.umd.js +75 -66
  62. package/lib/style.css +1 -1
  63. package/lib/style.min.css +1 -1
  64. package/lib/table/module/custom/panel.js +18 -11
  65. package/lib/table/module/custom/panel.min.js +1 -1
  66. package/lib/table/module/edit/hook.js +11 -13
  67. package/lib/table/module/edit/hook.min.js +1 -1
  68. package/lib/table/module/export/hook.js +12 -6
  69. package/lib/table/module/export/hook.min.js +1 -1
  70. package/lib/table/render/index.js +98 -84
  71. package/lib/table/render/index.min.js +1 -1
  72. package/lib/table/src/table.js +22 -2
  73. package/lib/table/src/table.min.js +1 -1
  74. package/lib/table/style/style.css +8 -4
  75. package/lib/table/style/style.min.css +1 -1
  76. package/lib/toolbar/src/toolbar.js +17 -7
  77. package/lib/toolbar/src/toolbar.min.js +1 -1
  78. package/lib/ui/index.js +10 -8
  79. package/lib/ui/index.min.js +1 -1
  80. package/lib/ui/src/log.js +1 -1
  81. package/lib/ui/src/log.min.js +1 -1
  82. package/lib/vxe-table/style/style.css +8 -4
  83. package/lib/vxe-table/style/style.min.css +1 -1
  84. package/package.json +2 -2
  85. package/packages/grid/src/grid.ts +22 -11
  86. package/packages/locale/lang/en-US.ts +17 -8
  87. package/packages/locale/lang/es-ES.ts +17 -8
  88. package/packages/locale/lang/hu-HU.ts +626 -0
  89. package/packages/locale/lang/ja-JP.ts +17 -8
  90. package/packages/locale/lang/ko-KR.ts +636 -0
  91. package/packages/locale/lang/pt-BR.ts +17 -8
  92. package/packages/locale/lang/ru-RU.ts +636 -0
  93. package/packages/locale/lang/vi-VN.ts +636 -0
  94. package/packages/locale/lang/zh-CN.ts +17 -8
  95. package/packages/locale/lang/zh-TC.ts +75 -66
  96. package/packages/table/module/custom/panel.ts +13 -12
  97. package/packages/table/module/edit/hook.ts +11 -10
  98. package/packages/table/module/export/hook.ts +10 -6
  99. package/packages/table/render/index.ts +95 -84
  100. package/packages/table/src/table.ts +25 -3
  101. package/packages/toolbar/src/toolbar.ts +8 -8
  102. package/packages/ui/index.ts +4 -3
  103. package/styles/components/table.scss +6 -3
  104. /package/es/{iconfont.1723218795604.ttf → iconfont.1724145396059.ttf} +0 -0
  105. /package/es/{iconfont.1723218795604.woff → iconfont.1724145396059.woff} +0 -0
  106. /package/es/{iconfont.1723218795604.woff2 → iconfont.1724145396059.woff2} +0 -0
  107. /package/lib/{iconfont.1723218795604.ttf → iconfont.1724145396059.ttf} +0 -0
  108. /package/lib/{iconfont.1723218795604.woff → iconfont.1724145396059.woff} +0 -0
  109. /package/lib/{iconfont.1723218795604.woff2 → iconfont.1724145396059.woff2} +0 -0
@@ -436,14 +436,14 @@ function oldFilterRender (renderOpts: any, params: any) {
436
436
 
437
437
  function handleFilterMethod ({ option, row, column }: any) {
438
438
  const { data } = option
439
- const cellValue = XEUtils.get(row, column.property)
439
+ const cellValue = XEUtils.get(row, column.field)
440
440
  /* eslint-disable eqeqeq */
441
441
  return cellValue == data
442
442
  }
443
443
 
444
444
  function handleInputFilterMethod ({ option, row, column }: any) {
445
445
  const { data } = option
446
- const cellValue = XEUtils.get(row, column.property)
446
+ const cellValue = XEUtils.get(row, column.field)
447
447
  /* eslint-disable eqeqeq */
448
448
  return XEUtils.toValueString(cellValue).indexOf(data) > -1
449
449
  }
@@ -501,7 +501,7 @@ function oldSelectEditRender (renderOpts: any, params: any) {
501
501
 
502
502
  function getSelectCellValue (renderOpts: any, { row, column }: any) {
503
503
  const { options, optionGroups, optionProps = {}, optionGroupProps = {} } = renderOpts
504
- const cellValue = XEUtils.get(row, column.property)
504
+ const cellValue = XEUtils.get(row, column.field)
505
505
  let selectItem: any
506
506
  const labelProp = optionProps.label || 'label'
507
507
  const valueProp = optionProps.value || 'value'
@@ -536,7 +536,7 @@ function handleExportSelectMethod (params: any) {
536
536
 
537
537
  function getTreeSelectCellValue (renderOpts: any, { row, column }: any) {
538
538
  const { options, optionProps = {} } = renderOpts
539
- const cellValue = XEUtils.get(row, column.property)
539
+ const cellValue = XEUtils.get(row, column.field)
540
540
  const labelProp = optionProps.label || 'label'
541
541
  const valueProp = optionProps.value || 'value'
542
542
  const childrenProp = optionProps.children || 'children'
@@ -564,23 +564,23 @@ function handleExportTreeSelectMethod (params: any) {
564
564
  */
565
565
  renderer.mixin({
566
566
  input: {
567
- autofocus: 'input',
568
- renderEdit: nativeEditRender,
569
- renderDefault: nativeEditRender,
570
- renderFilter: nativeFilterRender,
571
- defaultFilterMethod: handleInputFilterMethod
567
+ tableAutoFocus: 'input',
568
+ renderTableEdit: nativeEditRender,
569
+ renderTableDefault: nativeEditRender,
570
+ renderTableFilter: nativeFilterRender,
571
+ tableFilterDefaultMethod: handleInputFilterMethod
572
572
  },
573
573
  textarea: {
574
- autofocus: 'textarea',
575
- renderEdit: nativeEditRender
574
+ tableAutoFocus: 'textarea',
575
+ renderTableEdit: nativeEditRender
576
576
  },
577
577
  select: {
578
- renderEdit: nativeSelectEditRender,
579
- renderDefault: nativeSelectEditRender,
580
- renderCell (renderOpts, params) {
578
+ renderTableEdit: nativeSelectEditRender,
579
+ renderTableDefault: nativeSelectEditRender,
580
+ renderTableCell (renderOpts, params) {
581
581
  return getCellLabelVNs(renderOpts, params, getSelectCellValue(renderOpts, params))
582
582
  },
583
- renderFilter (renderOpts, params) {
583
+ renderTableFilter (renderOpts, params) {
584
584
  const { column } = params
585
585
  return column.filters.map((option, oIndex) => {
586
586
  return h('select', {
@@ -592,17 +592,17 @@ renderer.mixin({
592
592
  renderOpts.optionGroups ? renderNativeOptgroups(renderOpts, params, renderNativeOptions) : renderNativeOptions(renderOpts.options, renderOpts, params))
593
593
  })
594
594
  },
595
- defaultFilterMethod: handleFilterMethod,
596
- exportMethod: handleExportSelectMethod
595
+ tableFilterDefaultMethod: handleFilterMethod,
596
+ tableExportMethod: handleExportSelectMethod
597
597
  },
598
598
  VxeInput: {
599
- autofocus: 'input',
600
- renderEdit: defaultEditRender,
601
- renderCell (renderOpts, params) {
599
+ tableAutoFocus: 'input',
600
+ renderTableEdit: defaultEditRender,
601
+ renderTableCell (renderOpts, params) {
602
602
  const { props = {} } = renderOpts
603
603
  const { row, column } = params
604
604
  const digits = props.digits || getConfig().input?.digits || 2
605
- let cellValue = XEUtils.get(row, column.property)
605
+ let cellValue = XEUtils.get(row, column.field)
606
606
  if (cellValue) {
607
607
  switch (props.type) {
608
608
  case 'date':
@@ -619,18 +619,18 @@ renderer.mixin({
619
619
  }
620
620
  return getCellLabelVNs(renderOpts, params, cellValue)
621
621
  },
622
- renderDefault: defaultEditRender,
623
- renderFilter: defaultFilterRender,
624
- defaultFilterMethod: handleInputFilterMethod
622
+ renderTableDefault: defaultEditRender,
623
+ renderTableFilter: defaultFilterRender,
624
+ tableFilterDefaultMethod: handleInputFilterMethod
625
625
  },
626
626
  VxeNumberInput: {
627
- autofocus: 'input',
628
- renderEdit: defaultEditRender,
629
- renderCell (renderOpts, params) {
627
+ tableAutoFocus: 'input',
628
+ renderTableEdit: defaultEditRender,
629
+ renderTableCell (renderOpts, params) {
630
630
  const { props = {} } = renderOpts
631
631
  const { row, column } = params
632
632
  const digits = props.digits || getConfig().numberInput?.digits || 2
633
- let cellValue = XEUtils.get(row, column.property)
633
+ let cellValue = XEUtils.get(row, column.field)
634
634
  if (cellValue) {
635
635
  switch (props.type) {
636
636
  case 'float':
@@ -640,17 +640,17 @@ renderer.mixin({
640
640
  }
641
641
  return getCellLabelVNs(renderOpts, params, cellValue)
642
642
  },
643
- renderDefault: defaultEditRender,
644
- renderFilter: defaultFilterRender,
645
- defaultFilterMethod: handleInputFilterMethod
643
+ renderTableDefault: defaultEditRender,
644
+ renderTableFilter: defaultFilterRender,
645
+ tableFilterDefaultMethod: handleInputFilterMethod
646
646
  },
647
647
  VxeDatePicker: {
648
- autofocus: 'input',
649
- renderEdit: defaultEditRender,
650
- renderCell (renderOpts, params) {
648
+ tableAutoFocus: 'input',
649
+ renderTableEdit: defaultEditRender,
650
+ renderTableCell (renderOpts, params) {
651
651
  const { props = {} } = renderOpts
652
652
  const { row, column } = params
653
- let cellValue = XEUtils.get(row, column.property)
653
+ let cellValue = XEUtils.get(row, column.field)
654
654
  if (cellValue) {
655
655
  switch (props.type) {
656
656
  case 'date':
@@ -664,18 +664,18 @@ renderer.mixin({
664
664
  }
665
665
  return getCellLabelVNs(renderOpts, params, cellValue)
666
666
  },
667
- renderDefault: defaultEditRender,
668
- renderFilter: defaultFilterRender,
669
- defaultFilterMethod: handleFilterMethod
667
+ renderTableDefault: defaultEditRender,
668
+ renderTableFilter: defaultFilterRender,
669
+ tableFilterDefaultMethod: handleFilterMethod
670
670
  },
671
671
  VxeTextarea: {
672
- autofocus: 'VxeTextarea'
672
+ tableAutoFocus: 'VxeTextarea'
673
673
  },
674
674
  VxeButton: {
675
- renderDefault: buttonCellRender
675
+ renderTableDefault: buttonCellRender
676
676
  },
677
677
  VxeButtonGroup: {
678
- renderDefault (renderOpts, params) {
678
+ renderTableDefault (renderOpts, params) {
679
679
  const { options } = renderOpts
680
680
  return [
681
681
  h(getDefaultComponent(renderOpts), {
@@ -687,13 +687,13 @@ renderer.mixin({
687
687
  }
688
688
  },
689
689
  VxeSelect: {
690
- autofocus: 'input',
691
- renderEdit: defaultSelectEditRender,
692
- renderDefault: defaultSelectEditRender,
693
- renderCell (renderOpts, params) {
690
+ tableAutoFocus: 'input',
691
+ renderTableEdit: defaultSelectEditRender,
692
+ renderTableDefault: defaultSelectEditRender,
693
+ renderTableCell (renderOpts, params) {
694
694
  return getCellLabelVNs(renderOpts, params, getSelectCellValue(renderOpts, params))
695
695
  },
696
- renderFilter (renderOpts, params) {
696
+ renderTableFilter (renderOpts, params) {
697
697
  const { column } = params
698
698
  const { options, optionProps, optionGroups, optionGroupProps } = renderOpts
699
699
  return column.filters.map((option, oIndex) => {
@@ -705,35 +705,46 @@ renderer.mixin({
705
705
  })
706
706
  })
707
707
  },
708
- defaultFilterMethod: handleFilterMethod,
709
- exportMethod: handleExportSelectMethod
708
+ tableFilterDefaultMethod: handleFilterMethod,
709
+ tableExportMethod: handleExportSelectMethod
710
710
  },
711
711
  VxeTreeSelect: {
712
- autofocus: 'input',
713
- renderEdit: defaultTreeSelectEditRender,
714
- renderCell (renderOpts, params) {
712
+ tableAutoFocus: 'input',
713
+ renderTableEdit: defaultTreeSelectEditRender,
714
+ renderTableCell (renderOpts, params) {
715
715
  return getCellLabelVNs(renderOpts, params, getTreeSelectCellValue(renderOpts, params))
716
716
  },
717
- exportMethod: handleExportTreeSelectMethod
717
+ tableExportMethod: handleExportTreeSelectMethod
718
+ },
719
+ VxeIconPicker: {
720
+ tableAutoFocus: 'input',
721
+ renderTableEdit: defaultEditRender,
722
+ renderTableCell (renderOpts, params) {
723
+ const { row, column } = params
724
+ const cellValue = XEUtils.get(row, column.field)
725
+ return h('i', {
726
+ class: cellValue
727
+ })
728
+ }
718
729
  },
719
730
  VxeRadioGroup: {
720
- renderDefault: radioAndCheckboxEditRender
731
+ renderTableDefault: radioAndCheckboxEditRender
721
732
  },
722
733
  VxeCheckboxGroup: {
723
- renderDefault: radioAndCheckboxEditRender
734
+ renderTableDefault: radioAndCheckboxEditRender
724
735
  },
725
736
  VxeSwitch: {
726
- autofocus: 'button',
727
- renderEdit: defaultEditRender,
728
- renderDefault: defaultEditRender
737
+ tableAutoFocus: 'button',
738
+ renderTableEdit: defaultEditRender,
739
+ renderTableDefault: defaultEditRender
729
740
  },
730
741
  VxeUpload: {
731
- renderEdit: defaultEditRender,
732
- renderCell: defaultEditRender,
733
- renderDefault: defaultEditRender
742
+ renderTableEdit: defaultEditRender,
743
+ renderTableCell: defaultEditRender,
744
+ renderTableDefault: defaultEditRender
734
745
  },
735
746
  VxeImage: {
736
- renderDefault (renderOpts, params) {
747
+ renderTableDefault (renderOpts, params) {
737
748
  const { row, column } = params
738
749
  const { props } = renderOpts
739
750
  const cellValue = getCellValue(row, column)
@@ -747,7 +758,7 @@ renderer.mixin({
747
758
  }
748
759
  },
749
760
  VxeImageGroup: {
750
- renderDefault (renderOpts, params) {
761
+ renderTableDefault (renderOpts, params) {
751
762
  const { row, column } = params
752
763
  const { props } = renderOpts
753
764
  const cellValue = getCellValue(row, column)
@@ -763,13 +774,13 @@ renderer.mixin({
763
774
 
764
775
  // 以下已废弃
765
776
  $input: {
766
- autofocus: '.vxe-input--inner',
767
- renderEdit: oldEditRender,
768
- renderCell (renderOpts, params) {
777
+ tableAutoFocus: '.vxe-input--inner',
778
+ renderTableEdit: oldEditRender,
779
+ renderTableCell (renderOpts, params) {
769
780
  const { props = {} } = renderOpts
770
781
  const { row, column } = params
771
782
  const digits = props.digits || getConfig().input?.digits || 2
772
- let cellValue = XEUtils.get(row, column.property)
783
+ let cellValue = XEUtils.get(row, column.field)
773
784
  if (cellValue) {
774
785
  switch (props.type) {
775
786
  case 'date':
@@ -785,27 +796,27 @@ renderer.mixin({
785
796
  }
786
797
  return getCellLabelVNs(renderOpts, params, cellValue)
787
798
  },
788
- renderDefault: oldEditRender,
789
- renderFilter: oldFilterRender,
790
- defaultFilterMethod: handleInputFilterMethod
799
+ renderTableDefault: oldEditRender,
800
+ renderTableFilter: oldFilterRender,
801
+ tableFilterDefaultMethod: handleInputFilterMethod
791
802
  },
792
803
  $textarea: {
793
- autofocus: '.vxe-textarea--inner'
804
+ tableAutoFocus: '.vxe-textarea--inner'
794
805
  },
795
806
  $button: {
796
- renderDefault: oldButtonEditRender
807
+ renderTableDefault: oldButtonEditRender
797
808
  },
798
809
  $buttons: {
799
- renderDefault: oldButtonsEditRender
810
+ renderTableDefault: oldButtonsEditRender
800
811
  },
801
812
  $select: {
802
- autofocus: '.vxe-input--inner',
803
- renderEdit: oldSelectEditRender,
804
- renderDefault: oldSelectEditRender,
805
- renderCell (renderOpts, params) {
813
+ tableAutoFocus: '.vxe-input--inner',
814
+ renderTableEdit: oldSelectEditRender,
815
+ renderTableDefault: oldSelectEditRender,
816
+ renderTableCell (renderOpts, params) {
806
817
  return getCellLabelVNs(renderOpts, params, getSelectCellValue(renderOpts, params))
807
818
  },
808
- renderFilter (renderOpts, params) {
819
+ renderTableFilter (renderOpts, params) {
809
820
  const { column } = params
810
821
  const { options, optionProps, optionGroups, optionGroupProps } = renderOpts
811
822
  return column.filters.map((option, oIndex) => {
@@ -817,19 +828,19 @@ renderer.mixin({
817
828
  })
818
829
  })
819
830
  },
820
- defaultFilterMethod: handleFilterMethod,
821
- exportMethod: handleExportSelectMethod
831
+ tableFilterDefaultMethod: handleFilterMethod,
832
+ tableExportMethod: handleExportSelectMethod
822
833
  },
823
834
  $radio: {
824
- autofocus: '.vxe-radio--input'
835
+ tableAutoFocus: '.vxe-radio--input'
825
836
  },
826
837
  $checkbox: {
827
- autofocus: '.vxe-checkbox--input'
838
+ tableAutoFocus: '.vxe-checkbox--input'
828
839
  },
829
840
  $switch: {
830
- autofocus: '.vxe-switch--button',
831
- renderEdit: oldEditRender,
832
- renderDefault: oldEditRender
841
+ tableAutoFocus: '.vxe-switch--button',
842
+ renderTableEdit: oldEditRender,
843
+ renderTableDefault: oldEditRender
833
844
  }
834
845
  // 以上已废弃
835
846
  })
@@ -18,7 +18,7 @@ import TableImportPanelComponent from '../module/export/import-panel'
18
18
  import TableExportPanelComponent from '../module/export/export-panel'
19
19
  import TableMenuPanelComponent from '../module/menu/panel'
20
20
 
21
- import type { VxeLoadingComponent, VxeTooltipInstance, VxeTooltipComponent } from 'vxe-pc-ui'
21
+ import type { VxeLoadingComponent, VxeTooltipInstance, VxeTooltipComponent, VxeTabsConstructor, VxeTabsPrivateMethods } from 'vxe-pc-ui'
22
22
  import type { VxeGridConstructor, VxeGridPrivateMethods, VxeTableConstructor, TableReactData, TableInternalData, VxeTablePropTypes, VxeToolbarConstructor, TablePrivateMethods, VxeTablePrivateRef, VxeTablePrivateComputed, VxeTablePrivateMethods, TableMethods, VxeTableMethods, VxeTableDefines, VxeTableProps, VxeColumnPropTypes } from '../../../types'
23
23
 
24
24
  const { getConfig, getI18n, renderer, formats, createEvent, globalResize, interceptor, hooks, globalEvents, GLOBAL_EVENT_KEYS, useFns } = VxeUI
@@ -40,6 +40,8 @@ export default defineComponent({
40
40
  const VxeUILoadingComponent = VxeUI.getComponent<VxeLoadingComponent>('VxeLoading')
41
41
  const VxeUITooltipComponent = VxeUI.getComponent<VxeTooltipComponent>('VxeTooltip')
42
42
 
43
+ const $xeTabs = inject<(VxeTabsConstructor & VxeTabsPrivateMethods) | null>('$xeTabs', null)
44
+
43
45
  const { computeSize } = useFns.useSize(props)
44
46
 
45
47
  const reactData = reactive<TableReactData>({
@@ -3273,6 +3275,11 @@ export default defineComponent({
3273
3275
  const fullColumnFieldData = internalData.fullColumnFieldData
3274
3276
  return field && fullColumnFieldData[field] ? fullColumnFieldData[field].column : null
3275
3277
  },
3278
+ getParentColumn (fieldOrColumn) {
3279
+ const fullColumnIdData = internalData.fullColumnIdData
3280
+ const column = handleFieldOrColumn($xeTable, fieldOrColumn)
3281
+ return column && column.parentId && fullColumnIdData[column.parentId] ? fullColumnIdData[column.parentId].column : null
3282
+ },
3276
3283
  /**
3277
3284
  * 获取当前表格的列
3278
3285
  * 收集到的全量列、全量表头列、处理条件之后的全量表头列、当前渲染中的表头列
@@ -3551,10 +3558,14 @@ export default defineComponent({
3551
3558
  * 计算单元格列宽,动态分配可用剩余空间
3552
3559
  * 支持 width=? width=?px width=?% min-width=? min-width=?px min-width=?%
3553
3560
  */
3554
- recalculate (refull?: boolean) {
3561
+ recalculate (reFull?: boolean) {
3562
+ const el = refElem.value
3563
+ if (!el || !el.clientWidth) {
3564
+ return nextTick()
3565
+ }
3555
3566
  calcCellWidth()
3556
3567
  autoCellWidth()
3557
- if (refull === true) {
3568
+ if (reFull === true) {
3558
3569
  // 初始化时需要在列计算之后再执行优化运算,达到最优显示效果
3559
3570
  return computeScrollLoad().then(() => {
3560
3571
  autoCellWidth()
@@ -5251,6 +5262,10 @@ export default defineComponent({
5251
5262
  if ($xeTable.closeMenu) {
5252
5263
  $xeTable.closeMenu()
5253
5264
  }
5265
+ const el = refElem.value
5266
+ if (!el || !el.clientWidth) {
5267
+ return nextTick()
5268
+ }
5254
5269
  tableMethods.updateCellAreas()
5255
5270
  tableMethods.recalculate(true)
5256
5271
  }
@@ -6686,6 +6701,12 @@ export default defineComponent({
6686
6701
  })
6687
6702
  })
6688
6703
 
6704
+ if ($xeTabs) {
6705
+ watch(() => $xeTabs ? $xeTabs.reactData.resizeFlag : null, () => {
6706
+ handleGlobalResizeEvent()
6707
+ })
6708
+ }
6709
+
6689
6710
  hooks.forEach((options) => {
6690
6711
  const { setupTable } = options
6691
6712
  if (setupTable) {
@@ -6971,6 +6992,7 @@ export default defineComponent({
6971
6992
  'is--virtual-x': scrollXLoad,
6972
6993
  'is--virtual-y': scrollYLoad
6973
6994
  }],
6995
+ spellcheck: false,
6974
6996
  onKeydown: keydownEvent
6975
6997
  }, [
6976
6998
  /**
@@ -4,7 +4,7 @@ import { VxeUI } from '../../ui'
4
4
  import { getSlotVNs } from '../../ui/src/vn'
5
5
  import { warnLog, errLog } from '../../ui/src/log'
6
6
 
7
- import type { VxeButtonComponent } from 'vxe-pc-ui'
7
+ import type { VxeButtonComponent, VxeButtonEvents } from 'vxe-pc-ui'
8
8
  import type { VxeGridConstructor, GridPrivateMethods, ToolbarMethods, VxeToolbarConstructor, VxeToolbarEmits, VxeToolbarPropTypes, VxeTableConstructor, ToolbarPrivateRef, VxeTableMethods, VxeTablePrivateMethods, ToolbarReactData } from '../../../types'
9
9
 
10
10
  const { getConfig, getIcon, getI18n, renderer, commands, createEvent, useFns } = VxeUI
@@ -146,7 +146,7 @@ export default defineComponent({
146
146
  }
147
147
  }
148
148
 
149
- const refreshEvent = (evnt: KeyboardEvent) => {
149
+ const refreshEvent: VxeButtonEvents.Click = ({ $event }) => {
150
150
  const { isRefresh } = reactData
151
151
  const refreshOpts = computeRefreshOpts.value
152
152
  if (!isRefresh) {
@@ -162,16 +162,16 @@ export default defineComponent({
162
162
  }
163
163
  } else if ($xeGrid) {
164
164
  reactData.isRefresh = true
165
- $xeGrid.triggerToolbarCommitEvent({ code: refreshOpts.code || 'reload' }, evnt).catch((e) => e).then(() => {
165
+ $xeGrid.triggerToolbarCommitEvent({ code: refreshOpts.code || 'reload' }, $event).catch((e) => e).then(() => {
166
166
  reactData.isRefresh = false
167
167
  })
168
168
  }
169
169
  }
170
170
  }
171
171
 
172
- const zoomEvent = (evnt: Event) => {
172
+ const zoomEvent: VxeButtonEvents.Click = ({ $event }) => {
173
173
  if ($xeGrid) {
174
- $xeGrid.triggerZoomEvent(evnt)
174
+ $xeGrid.triggerZoomEvent($event)
175
175
  }
176
176
  }
177
177
 
@@ -270,7 +270,7 @@ export default defineComponent({
270
270
  round: child.round,
271
271
  status: child.status,
272
272
  content: child.name,
273
- onClick: (evnt: Event) => isBtn ? btnEvent(evnt, child) : tolEvent(evnt, child)
273
+ onClick: ({ $event }) => isBtn ? btnEvent($event, child) : tolEvent($event, child)
274
274
  })
275
275
  : createCommentVNode()
276
276
  })
@@ -319,7 +319,7 @@ export default defineComponent({
319
319
  destroyOnClose: item.destroyOnClose,
320
320
  placement: item.placement,
321
321
  transfer: item.transfer,
322
- onClick: (evnt: Event) => btnEvent(evnt, item)
322
+ onClick: ({ $event }) => btnEvent($event, item)
323
323
  }, dropdowns && dropdowns.length
324
324
  ? {
325
325
  dropdowns: () => renderDropdowns(item, true)
@@ -377,7 +377,7 @@ export default defineComponent({
377
377
  destroyOnClose: item.destroyOnClose,
378
378
  placement: item.placement,
379
379
  transfer: item.transfer,
380
- onClick: (evnt: Event) => tolEvent(evnt, item)
380
+ onClick: ({ $event }) => tolEvent($event, item)
381
381
  }, dropdowns && dropdowns.length
382
382
  ? {
383
383
  dropdowns: () => renderDropdowns(item, false)
@@ -280,6 +280,7 @@ export const use = VxeUI.use
280
280
  export const setup = (options?: VxeGlobalConfig) => {
281
281
  return VxeUI.setConfig(options)
282
282
  }
283
+ VxeUI.setup = setup
283
284
  /**
284
285
  * 已废弃
285
286
  * @deprecated
@@ -287,6 +288,7 @@ export const setup = (options?: VxeGlobalConfig) => {
287
288
  export const config = (options?: VxeGlobalConfig) => {
288
289
  return VxeUI.setConfig(options)
289
290
  }
291
+ VxeUI.config = config
290
292
  /**
291
293
  * 已废弃
292
294
  * @deprecated
@@ -294,6 +296,7 @@ export const config = (options?: VxeGlobalConfig) => {
294
296
  export const t = (key: string, args?: any) => {
295
297
  return VxeUI.getI18n(key, args)
296
298
  }
299
+ VxeUI.t = t
297
300
  /**
298
301
  * 已废弃
299
302
  * @deprecated
@@ -301,6 +304,7 @@ export const t = (key: string, args?: any) => {
301
304
  export const _t = (content: string | number | boolean | null | undefined, args?: any) => {
302
305
  return getFuncText(content, args)
303
306
  }
307
+ VxeUI._t = _t
304
308
 
305
309
  /**
306
310
  * 已废弃,兼容老版本
@@ -308,9 +312,6 @@ export const _t = (content: string | number | boolean | null | undefined, args?:
308
312
  */
309
313
  export const VXETable = VxeUI
310
314
 
311
- VXETable.setup = config
312
- VXETable.config = config
313
-
314
315
  /**
315
316
  * 已废弃,兼容老版本
316
317
  * @deprecated
@@ -94,7 +94,8 @@
94
94
  & > .vxe-select,
95
95
  & > .vxe-tree-select,
96
96
  & > .vxe-date-picker,
97
- & > .vxe-number-input {
97
+ & > .vxe-number-input,
98
+ & > .vxe-ico-picker {
98
99
  width: 100%;
99
100
  }
100
101
  & > .vxe-input > .vxe-input--inner,
@@ -111,7 +112,8 @@
111
112
  .vxe-select,
112
113
  .vxe-tree-select,
113
114
  .vxe-date-picker,
114
- .vxe-number-input {
115
+ .vxe-number-input,
116
+ .vxe-ico-picker {
115
117
  width: 100%;
116
118
  }
117
119
  .vxe-input > .vxe-input--inner,
@@ -1277,7 +1279,8 @@
1277
1279
  .vxe-default-select {
1278
1280
  border-color: var(--vxe-ui-table-validate-error-color);
1279
1281
  }
1280
- .vxe-input {
1282
+ .vxe-input,
1283
+ .vxe-ico-picker {
1281
1284
  border-color: var(--vxe-ui-table-validate-error-color);
1282
1285
  }
1283
1286
  }