vxe-table 4.11.10 → 4.11.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.
@@ -1819,16 +1819,10 @@ export default defineComponent({
1819
1819
  if (layout === 'header') {
1820
1820
  // 表头体样式处理
1821
1821
  // 横向滚动渲染
1822
- let tWidth = tableWidth;
1823
1822
  let renderColumnList = tableColumn;
1824
1823
  let isOptimizeMode = false;
1825
1824
  if (isGroup) {
1826
1825
  renderColumnList = visibleColumn;
1827
- if (fixedType) {
1828
- if (wrapperElem) {
1829
- wrapperElem.style.width = tWidth ? `${tWidth}px` : '';
1830
- }
1831
- }
1832
1826
  }
1833
1827
  else {
1834
1828
  // 如果是使用优化模式
@@ -1846,24 +1840,34 @@ export default defineComponent({
1846
1840
  if (isOptimizeMode) {
1847
1841
  renderColumnList = fixedColumn || [];
1848
1842
  }
1849
- if (!isOptimizeMode) {
1843
+ }
1844
+ }
1845
+ const tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
1846
+ if (fixedType) {
1847
+ if (isGroup) {
1848
+ if (wrapperElem) {
1849
+ wrapperElem.style.width = tableWidth ? `${tableWidth}px` : '';
1850
+ }
1851
+ }
1852
+ else {
1853
+ if (isOptimizeMode) {
1850
1854
  if (wrapperElem) {
1851
1855
  wrapperElem.style.width = tWidth ? `${tWidth}px` : '';
1852
1856
  }
1853
1857
  }
1858
+ else {
1859
+ if (wrapperElem) {
1860
+ wrapperElem.style.width = tableWidth ? `${tableWidth}px` : '';
1861
+ }
1862
+ }
1854
1863
  }
1855
1864
  }
1856
- tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
1857
1865
  if (currScrollElem) {
1858
1866
  currScrollElem.style.height = `${headerHeight}px`;
1859
1867
  }
1860
1868
  if (tableElem) {
1861
1869
  tableElem.style.width = tWidth ? `${tWidth}px` : '';
1862
1870
  }
1863
- const repairElem = getRefElem(elemStore[`${name}-${layout}-repair`]);
1864
- if (repairElem) {
1865
- repairElem.style.width = `${tableWidth}px`;
1866
- }
1867
1871
  const listElem = getRefElem(elemStore[`${name}-${layout}-list`]);
1868
1872
  if (isGroup && listElem) {
1869
1873
  XEUtils.arrayEach(listElem.querySelectorAll('.col--group'), (thElem) => {
@@ -1905,7 +1909,6 @@ export default defineComponent({
1905
1909
  fixedWrapperElem.style.height = `${customHeight > 0 ? customHeight : (tableHeight + headerHeight + footerHeight + osbHeight)}px`;
1906
1910
  fixedWrapperElem.style.width = `${fixedColumn.reduce((previous, column) => previous + column.renderWidth, 0)}px`;
1907
1911
  }
1908
- let tWidth = tableWidth;
1909
1912
  let renderColumnList = tableColumn;
1910
1913
  let isOptimizeMode = false;
1911
1914
  // 如果是使用优化模式
@@ -1922,13 +1925,20 @@ export default defineComponent({
1922
1925
  if (isOptimizeMode) {
1923
1926
  renderColumnList = fixedColumn || [];
1924
1927
  }
1925
- if (!isOptimizeMode) {
1928
+ }
1929
+ const tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
1930
+ if (fixedType) {
1931
+ if (isOptimizeMode) {
1926
1932
  if (wrapperElem) {
1927
1933
  wrapperElem.style.width = tWidth ? `${tWidth}px` : '';
1928
1934
  }
1929
1935
  }
1936
+ else {
1937
+ if (wrapperElem) {
1938
+ wrapperElem.style.width = tableWidth ? `${tableWidth}px` : '';
1939
+ }
1940
+ }
1930
1941
  }
1931
- tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
1932
1942
  if (tableElem) {
1933
1943
  tableElem.style.width = tWidth ? `${tWidth}px` : '';
1934
1944
  // 兼容性处理
@@ -1940,7 +1950,6 @@ export default defineComponent({
1940
1950
  }
1941
1951
  }
1942
1952
  else if (layout === 'footer') {
1943
- let tWidth = tableWidth;
1944
1953
  let renderColumnList = tableColumn;
1945
1954
  let isOptimizeMode = false;
1946
1955
  // 如果是使用优化模式
@@ -1957,13 +1966,20 @@ export default defineComponent({
1957
1966
  if (isOptimizeMode) {
1958
1967
  renderColumnList = fixedColumn || [];
1959
1968
  }
1960
- if (!isOptimizeMode) {
1969
+ }
1970
+ const tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
1971
+ if (fixedType) {
1972
+ if (isOptimizeMode) {
1961
1973
  if (wrapperElem) {
1962
1974
  wrapperElem.style.width = tWidth ? `${tWidth}px` : '';
1963
1975
  }
1964
1976
  }
1977
+ else {
1978
+ if (wrapperElem) {
1979
+ wrapperElem.style.width = tableWidth ? `${tableWidth}px` : '';
1980
+ }
1981
+ }
1965
1982
  }
1966
- tWidth = renderColumnList.reduce((previous, column) => previous + column.renderWidth, 0);
1967
1983
  if (currScrollElem) {
1968
1984
  currScrollElem.style.height = `${footerHeight}px`;
1969
1985
  // 如果是固定列
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 = "4.11.10";
3
+ export const version = "4.11.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${"4.11.10"}`;
3
+ const version = `table v${"4.11.11"}`;
4
4
  export const warnLog = log.create('warn', version);
5
5
  export const errLog = log.create('error', version);