vxe-table 3.13.10 → 3.13.11

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.
@@ -500,16 +500,10 @@ function updateStyle($xeTable) {
500
500
  if (layout === 'header') {
501
501
  // 表头体样式处理
502
502
  // 横向滚动渲染
503
- let tWidth = tableWidth;
504
503
  let renderColumnList = tableColumn;
505
504
  let isOptimizeMode = false;
506
505
  if (isGroup) {
507
506
  renderColumnList = visibleColumn;
508
- if (fixedType) {
509
- if (wrapperElem) {
510
- wrapperElem.style.width = tWidth ? `${tWidth}px` : '';
511
- }
512
- }
513
507
  }
514
508
  else {
515
509
  // 如果是使用优化模式
@@ -527,14 +521,28 @@ function updateStyle($xeTable) {
527
521
  if (isOptimizeMode) {
528
522
  renderColumnList = fixedColumn || [];
529
523
  }
530
- if (!isOptimizeMode) {
524
+ }
525
+ }
526
+ const tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
527
+ if (fixedType) {
528
+ if (isGroup) {
529
+ if (wrapperElem) {
530
+ wrapperElem.style.width = tableWidth ? `${tableWidth}px` : '';
531
+ }
532
+ }
533
+ else {
534
+ if (isOptimizeMode) {
531
535
  if (wrapperElem) {
532
536
  wrapperElem.style.width = tWidth ? `${tWidth}px` : '';
533
537
  }
534
538
  }
539
+ else {
540
+ if (wrapperElem) {
541
+ wrapperElem.style.width = tableWidth ? `${tableWidth}px` : '';
542
+ }
543
+ }
535
544
  }
536
545
  }
537
- tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
538
546
  if (currScrollElem) {
539
547
  currScrollElem.style.height = `${headerHeight}px`;
540
548
  }
@@ -586,7 +594,6 @@ function updateStyle($xeTable) {
586
594
  fixedWrapperElem.style.height = `${customHeight > 0 ? customHeight : (tableHeight + headerHeight + footerHeight + osbHeight)}px`;
587
595
  fixedWrapperElem.style.width = `${fixedColumn.reduce((previous, column) => previous + column.renderWidth, 0)}px`;
588
596
  }
589
- let tWidth = tableWidth;
590
597
  let renderColumnList = tableColumn;
591
598
  let isOptimizeMode = false;
592
599
  // 如果是使用优化模式
@@ -603,13 +610,20 @@ function updateStyle($xeTable) {
603
610
  if (isOptimizeMode) {
604
611
  renderColumnList = fixedColumn || [];
605
612
  }
606
- if (!isOptimizeMode) {
613
+ }
614
+ const tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
615
+ if (fixedType) {
616
+ if (isOptimizeMode) {
607
617
  if (wrapperElem) {
608
618
  wrapperElem.style.width = tWidth ? `${tWidth}px` : '';
609
619
  }
610
620
  }
621
+ else {
622
+ if (wrapperElem) {
623
+ wrapperElem.style.width = tableWidth ? `${tableWidth}px` : '';
624
+ }
625
+ }
611
626
  }
612
- tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
613
627
  if (tableElem) {
614
628
  tableElem.style.width = tWidth ? `${tWidth}px` : '';
615
629
  // 兼容性处理
@@ -621,7 +635,6 @@ function updateStyle($xeTable) {
621
635
  }
622
636
  }
623
637
  else if (layout === 'footer') {
624
- let tWidth = tableWidth;
625
638
  let renderColumnList = tableColumn;
626
639
  let isOptimizeMode = false;
627
640
  // 如果是使用优化模式
@@ -638,13 +651,20 @@ function updateStyle($xeTable) {
638
651
  if (isOptimizeMode) {
639
652
  renderColumnList = fixedColumn || [];
640
653
  }
641
- if (!isOptimizeMode) {
654
+ }
655
+ const tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
656
+ if (fixedType) {
657
+ if (isOptimizeMode) {
642
658
  if (wrapperElem) {
643
659
  wrapperElem.style.width = tWidth ? `${tWidth}px` : '';
644
660
  }
645
661
  }
662
+ else {
663
+ if (wrapperElem) {
664
+ wrapperElem.style.width = tableWidth ? `${tableWidth}px` : '';
665
+ }
666
+ }
646
667
  }
647
- tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
648
668
  if (currScrollElem) {
649
669
  currScrollElem.style.height = `${footerHeight}px`;
650
670
  // 如果是固定列
package/es/ui/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { VxeUI } from '@vxe-ui/core';
2
2
  import { getFuncText } from './src/utils';
3
- export const version = "3.13.10";
3
+ export const version = "3.13.11";
4
4
  VxeUI.version = version;
5
5
  VxeUI.tableVersion = version;
6
6
  VxeUI.setConfig({
package/es/ui/src/log.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { VxeUI } from '@vxe-ui/core';
2
2
  const { log } = VxeUI;
3
- const version = `table v${"3.13.10"}`;
3
+ const version = `table v${"3.13.11"}`;
4
4
  export const warnLog = log.create('warn', version);
5
5
  export const errLog = log.create('error', version);
package/lib/index.umd.js CHANGED
@@ -3201,7 +3201,7 @@ function getClass(property, params) {
3201
3201
  ;// ./packages/ui/index.ts
3202
3202
 
3203
3203
 
3204
- const version = "3.13.10";
3204
+ const version = "3.13.11";
3205
3205
  core_.VxeUI.version = version;
3206
3206
  core_.VxeUI.tableVersion = version;
3207
3207
  core_.VxeUI.setConfig({
@@ -3828,7 +3828,7 @@ var es_iterator_map = __webpack_require__(1701);
3828
3828
  const {
3829
3829
  log: log_log
3830
3830
  } = core_.VxeUI;
3831
- const log_version = `table v${"3.13.10"}`;
3831
+ const log_version = `table v${"3.13.11"}`;
3832
3832
  const warnLog = log_log.create('warn', log_version);
3833
3833
  const errLog = log_log.create('error', log_version);
3834
3834
  ;// ./packages/table/src/columnInfo.ts
@@ -6725,16 +6725,10 @@ function updateStyle($xeTable) {
6725
6725
  if (layout === 'header') {
6726
6726
  // 表头体样式处理
6727
6727
  // 横向滚动渲染
6728
- let tWidth = tableWidth;
6729
6728
  let renderColumnList = tableColumn;
6730
6729
  let isOptimizeMode = false;
6731
6730
  if (isGroup) {
6732
6731
  renderColumnList = visibleColumn;
6733
- if (fixedType) {
6734
- if (wrapperElem) {
6735
- wrapperElem.style.width = tWidth ? `${tWidth}px` : '';
6736
- }
6737
- }
6738
6732
  } else {
6739
6733
  // 如果是使用优化模式
6740
6734
  if (scrollXLoad || scrollYLoad || allColumnHeaderOverflow) {
@@ -6750,14 +6744,26 @@ function updateStyle($xeTable) {
6750
6744
  if (isOptimizeMode) {
6751
6745
  renderColumnList = fixedColumn || [];
6752
6746
  }
6753
- if (!isOptimizeMode) {
6747
+ }
6748
+ }
6749
+ const tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
6750
+ if (fixedType) {
6751
+ if (isGroup) {
6752
+ if (wrapperElem) {
6753
+ wrapperElem.style.width = tableWidth ? `${tableWidth}px` : '';
6754
+ }
6755
+ } else {
6756
+ if (isOptimizeMode) {
6754
6757
  if (wrapperElem) {
6755
6758
  wrapperElem.style.width = tWidth ? `${tWidth}px` : '';
6756
6759
  }
6760
+ } else {
6761
+ if (wrapperElem) {
6762
+ wrapperElem.style.width = tableWidth ? `${tableWidth}px` : '';
6763
+ }
6757
6764
  }
6758
6765
  }
6759
6766
  }
6760
- tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
6761
6767
  if (currScrollElem) {
6762
6768
  currScrollElem.style.height = `${headerHeight}px`;
6763
6769
  }
@@ -6812,7 +6818,6 @@ function updateStyle($xeTable) {
6812
6818
  fixedWrapperElem.style.height = `${customHeight > 0 ? customHeight : tableHeight + headerHeight + footerHeight + osbHeight}px`;
6813
6819
  fixedWrapperElem.style.width = `${fixedColumn.reduce((previous, column) => previous + column.renderWidth, 0)}px`;
6814
6820
  }
6815
- let tWidth = tableWidth;
6816
6821
  let renderColumnList = tableColumn;
6817
6822
  let isOptimizeMode = false;
6818
6823
  // 如果是使用优化模式
@@ -6828,13 +6833,19 @@ function updateStyle($xeTable) {
6828
6833
  if (isOptimizeMode) {
6829
6834
  renderColumnList = fixedColumn || [];
6830
6835
  }
6831
- if (!isOptimizeMode) {
6836
+ }
6837
+ const tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
6838
+ if (fixedType) {
6839
+ if (isOptimizeMode) {
6832
6840
  if (wrapperElem) {
6833
6841
  wrapperElem.style.width = tWidth ? `${tWidth}px` : '';
6834
6842
  }
6843
+ } else {
6844
+ if (wrapperElem) {
6845
+ wrapperElem.style.width = tableWidth ? `${tableWidth}px` : '';
6846
+ }
6835
6847
  }
6836
6848
  }
6837
- tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
6838
6849
  if (tableElem) {
6839
6850
  tableElem.style.width = tWidth ? `${tWidth}px` : '';
6840
6851
  // 兼容性处理
@@ -6845,7 +6856,6 @@ function updateStyle($xeTable) {
6845
6856
  emptyBlockElem.style.width = tWidth ? `${tWidth}px` : '';
6846
6857
  }
6847
6858
  } else if (layout === 'footer') {
6848
- let tWidth = tableWidth;
6849
6859
  let renderColumnList = tableColumn;
6850
6860
  let isOptimizeMode = false;
6851
6861
  // 如果是使用优化模式
@@ -6861,13 +6871,19 @@ function updateStyle($xeTable) {
6861
6871
  if (isOptimizeMode) {
6862
6872
  renderColumnList = fixedColumn || [];
6863
6873
  }
6864
- if (!isOptimizeMode) {
6874
+ }
6875
+ const tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
6876
+ if (fixedType) {
6877
+ if (isOptimizeMode) {
6865
6878
  if (wrapperElem) {
6866
6879
  wrapperElem.style.width = tWidth ? `${tWidth}px` : '';
6867
6880
  }
6881
+ } else {
6882
+ if (wrapperElem) {
6883
+ wrapperElem.style.width = tableWidth ? `${tableWidth}px` : '';
6884
+ }
6868
6885
  }
6869
6886
  }
6870
- tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
6871
6887
  if (currScrollElem) {
6872
6888
  currScrollElem.style.height = `${footerHeight}px`;
6873
6889
  // 如果是固定列