vxe-table 3.19.4 → 3.19.5

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 (48) hide show
  1. package/es/index.css +1 -1
  2. package/es/index.min.css +1 -1
  3. package/es/style.css +1 -1
  4. package/es/style.min.css +1 -1
  5. package/es/table/module/edit/mixin.js +13 -11
  6. package/es/table/src/methods.js +17 -1
  7. package/es/table/src/table.js +5 -1
  8. package/es/table/style.css +4 -3
  9. package/es/table/style.min.css +1 -1
  10. package/es/ui/index.js +1 -1
  11. package/es/ui/src/dom.js +17 -0
  12. package/es/ui/src/log.js +1 -1
  13. package/es/vxe-table/style.css +4 -3
  14. package/es/vxe-table/style.min.css +1 -1
  15. package/lib/index.css +1 -1
  16. package/lib/index.min.css +1 -1
  17. package/lib/index.umd.js +53 -14
  18. package/lib/index.umd.min.js +1 -1
  19. package/lib/style.css +1 -1
  20. package/lib/style.min.css +1 -1
  21. package/lib/table/module/edit/mixin.js +13 -11
  22. package/lib/table/module/edit/mixin.min.js +1 -1
  23. package/lib/table/src/methods.js +16 -0
  24. package/lib/table/src/methods.min.js +1 -1
  25. package/lib/table/src/table.js +5 -1
  26. package/lib/table/src/table.min.js +1 -1
  27. package/lib/table/style/style.css +4 -3
  28. package/lib/table/style/style.min.css +1 -1
  29. package/lib/ui/index.js +1 -1
  30. package/lib/ui/index.min.js +1 -1
  31. package/lib/ui/src/dom.js +18 -0
  32. package/lib/ui/src/dom.min.js +1 -1
  33. package/lib/ui/src/log.js +1 -1
  34. package/lib/ui/src/log.min.js +1 -1
  35. package/lib/vxe-table/style/style.css +4 -3
  36. package/lib/vxe-table/style/style.min.css +1 -1
  37. package/package.json +1 -1
  38. package/packages/table/module/edit/mixin.ts +13 -11
  39. package/packages/table/src/methods.ts +18 -1
  40. package/packages/table/src/table.ts +5 -1
  41. package/packages/ui/src/dom.ts +18 -0
  42. package/styles/components/table.scss +34 -3
  43. /package/es/{iconfont.1761699967297.ttf → iconfont.1761784799557.ttf} +0 -0
  44. /package/es/{iconfont.1761699967297.woff → iconfont.1761784799557.woff} +0 -0
  45. /package/es/{iconfont.1761699967297.woff2 → iconfont.1761784799557.woff2} +0 -0
  46. /package/lib/{iconfont.1761699967297.ttf → iconfont.1761784799557.ttf} +0 -0
  47. /package/lib/{iconfont.1761699967297.woff → iconfont.1761784799557.woff} +0 -0
  48. /package/lib/{iconfont.1761699967297.woff2 → iconfont.1761784799557.woff2} +0 -0
package/lib/index.umd.js CHANGED
@@ -2005,7 +2005,7 @@ function getClass(property, params) {
2005
2005
  ;// CONCATENATED MODULE: ./packages/ui/index.ts
2006
2006
 
2007
2007
 
2008
- const version = "3.19.4";
2008
+ const version = "3.19.5";
2009
2009
  core_.VxeUI.version = version;
2010
2010
  core_.VxeUI.tableVersion = version;
2011
2011
  core_.VxeUI.setConfig({
@@ -2622,6 +2622,23 @@ function updateCellTitle(overflowElem, column) {
2622
2622
  overflowElem.setAttribute('title', content);
2623
2623
  }
2624
2624
  }
2625
+ function checkTargetElement(target, exEls, endEl) {
2626
+ let targetEl = target;
2627
+ if (!exEls || !exEls.length) {
2628
+ return false;
2629
+ }
2630
+ const [exEl1, exEl2, exEl3] = exEls;
2631
+ while (targetEl) {
2632
+ if (exEl1 === targetEl || exEl2 && targetEl === exEl2 || exEl3 && targetEl === exEl3) {
2633
+ return true;
2634
+ }
2635
+ if (endEl && targetEl === endEl) {
2636
+ return false;
2637
+ }
2638
+ targetEl = targetEl.parentElement;
2639
+ }
2640
+ return false;
2641
+ }
2625
2642
  /**
2626
2643
  * 检查触发源是否属于目标节点
2627
2644
  */
@@ -2696,7 +2713,7 @@ function isNodeElement(elem) {
2696
2713
  const {
2697
2714
  log: log_log
2698
2715
  } = core_.VxeUI;
2699
- const log_version = `table v${"3.19.4"}`;
2716
+ const log_version = `table v${"3.19.5"}`;
2700
2717
  const warnLog = log_log.create('warn', log_version);
2701
2718
  const errLog = log_log.create('error', log_version);
2702
2719
  ;// CONCATENATED MODULE: ./packages/table/src/columnInfo.ts
@@ -18635,6 +18652,7 @@ const Methods = {
18635
18652
  },
18636
18653
  triggerBodyWheelEvent(evnt) {
18637
18654
  const $xeTable = this;
18655
+ const $xeParentTable = $xeTable.$xeParentTable;
18638
18656
  const tableProps = $xeTable;
18639
18657
  const reactData = $xeTable;
18640
18658
  const internalData = $xeTable;
@@ -18708,6 +18726,21 @@ const Methods = {
18708
18726
  return;
18709
18727
  }
18710
18728
  }
18729
+ // 展开行处理,如果展开行嵌入表格中
18730
+ if ($xeParentTable) {
18731
+ if (isRollY) {
18732
+ if (checkTargetElement(evnt.target, [leftScrollElem, bodyScrollElem, rightScrollElem], evnt.currentTarget)) {
18733
+ evnt.stopPropagation();
18734
+ return;
18735
+ }
18736
+ }
18737
+ if (isRollX) {
18738
+ if (checkTargetElement(evnt.target, [headerScrollElem, bodyScrollElem, footerScrollElem], evnt.currentTarget)) {
18739
+ evnt.stopPropagation();
18740
+ return;
18741
+ }
18742
+ }
18743
+ }
18711
18744
  if (!(leftFixedWidth || rightFixedWidth || expandColumn)) {
18712
18745
  return;
18713
18746
  }
@@ -25358,16 +25391,16 @@ function insertTreeRow($xeTable, newRecords, isAppend) {
25358
25391
  } = matchObj;
25359
25392
  const parentRest = fullAllDataRowIdData[getRowid($xeTable, parentRow)];
25360
25393
  const parentLevel = parentRest ? parentRest.level : 0;
25361
- let parentChilds = parentRow[childrenField];
25362
- let mapChilds = parentRow[mapChildrenField];
25363
- if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(parentChilds)) {
25364
- parentChilds = parentRow[childrenField] = [];
25394
+ let pChilds = parentRow[childrenField];
25395
+ let pMapChilds = parentRow[mapChildrenField];
25396
+ if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(pChilds)) {
25397
+ pChilds = parentRow[childrenField] = [];
25365
25398
  }
25366
- if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(mapChilds)) {
25367
- mapChilds = parentRow[childrenField] = [];
25399
+ if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(pMapChilds)) {
25400
+ pMapChilds = parentRow[mapChildrenField] = [];
25368
25401
  }
25369
- parentChilds[funcName](item);
25370
- mapChilds[funcName](item);
25402
+ pChilds[funcName](item);
25403
+ pMapChilds[funcName](item);
25371
25404
  const rest = {
25372
25405
  row: item,
25373
25406
  rowid,
@@ -25377,7 +25410,7 @@ function insertTreeRow($xeTable, newRecords, isAppend) {
25377
25410
  $index: -1,
25378
25411
  treeIndex: -1,
25379
25412
  _tIndex: -1,
25380
- items: parentChilds,
25413
+ items: pChilds,
25381
25414
  parent: parentRow,
25382
25415
  level: parentLevel + 1,
25383
25416
  height: 0,
@@ -25560,13 +25593,15 @@ function handleInsertRowAt($xeTable, records, targetRow, isInsertNextRow) {
25560
25593
  treeRecords.forEach((row, i) => {
25561
25594
  if (parentRow) {
25562
25595
  if (row[parentField] !== parentRow[rowField]) {
25563
- row[parentField] = parentRow[rowField];
25564
25596
  errLog('vxe.error.errProp', [`${parentField}=${row[parentField]}`, `${parentField}=${parentRow[rowField]}`]);
25597
+ row[parentField] = parentRow[rowField];
25565
25598
  }
25566
25599
  } else {
25567
25600
  if (row[parentField] !== null) {
25601
+ if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eqNull(row[parentField])) {
25602
+ errLog('vxe.error.errProp', [`${parentField}=${row[parentField]}`, 'null']);
25603
+ }
25568
25604
  row[parentField] = null;
25569
- errLog('vxe.error.errProp', [`${parentField}=${row[parentField]}`, 'null']);
25570
25605
  }
25571
25606
  }
25572
25607
  let targetIndex = matchMapObj.index + i;
@@ -30681,6 +30716,10 @@ function renderBody(h, $xeTable) {
30681
30716
  $xeTabs: {
30682
30717
  default: null
30683
30718
  },
30719
+ $xeParentTable: {
30720
+ from: '$xeTable',
30721
+ default: null
30722
+ },
30684
30723
  $xeGrid: {
30685
30724
  default: null
30686
30725
  },
@@ -31645,7 +31684,7 @@ function renderBody(h, $xeTable) {
31645
31684
  const {
31646
31685
  initStatus
31647
31686
  } = this;
31648
- if (value && value.length >= 50000) {
31687
+ if (value && value.length >= 20000) {
31649
31688
  warnLog('vxe.error.errLargeData', ['loadData(data), reloadData(data)']);
31650
31689
  }
31651
31690
  this.loadTableData(value || [], true).then(() => {