vxe-table 3.13.15 → 3.13.17

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 (41) hide show
  1. package/es/grid/src/grid.js +26 -13
  2. package/es/style.css +1 -1
  3. package/es/table/module/edit/mixin.js +4 -2
  4. package/es/table/module/keyboard/mixin.js +3 -2
  5. package/es/table/src/body.js +2 -2
  6. package/es/table/src/column.js +2 -2
  7. package/es/table/src/group.js +2 -2
  8. package/es/toolbar/src/toolbar.js +2 -2
  9. package/es/ui/index.js +1 -1
  10. package/es/ui/src/log.js +1 -1
  11. package/lib/grid/src/grid.js +27 -26
  12. package/lib/grid/src/grid.min.js +1 -1
  13. package/lib/index.umd.js +44 -39
  14. package/lib/index.umd.min.js +1 -1
  15. package/lib/style.css +1 -1
  16. package/lib/table/module/edit/mixin.js +4 -2
  17. package/lib/table/module/edit/mixin.min.js +1 -1
  18. package/lib/table/module/keyboard/mixin.js +3 -2
  19. package/lib/table/src/body.js +2 -1
  20. package/lib/table/src/body.min.js +1 -1
  21. package/lib/table/src/column.js +3 -2
  22. package/lib/table/src/group.js +3 -2
  23. package/lib/toolbar/src/toolbar.js +3 -2
  24. package/lib/ui/index.js +1 -1
  25. package/lib/ui/index.min.js +1 -1
  26. package/lib/ui/src/log.js +1 -1
  27. package/lib/ui/src/log.min.js +1 -1
  28. package/package.json +2 -2
  29. package/packages/grid/src/grid.ts +28 -13
  30. package/packages/table/module/edit/mixin.ts +4 -2
  31. package/packages/table/module/keyboard/mixin.ts +6 -2
  32. package/packages/table/src/body.ts +2 -2
  33. package/packages/table/src/column.ts +2 -2
  34. package/packages/table/src/group.ts +2 -2
  35. package/packages/toolbar/src/toolbar.ts +2 -2
  36. /package/es/{iconfont.1740723810366.ttf → iconfont.1741051533862.ttf} +0 -0
  37. /package/es/{iconfont.1740723810366.woff → iconfont.1741051533862.woff} +0 -0
  38. /package/es/{iconfont.1740723810366.woff2 → iconfont.1741051533862.woff2} +0 -0
  39. /package/lib/{iconfont.1740723810366.ttf → iconfont.1741051533862.ttf} +0 -0
  40. /package/lib/{iconfont.1740723810366.woff → iconfont.1741051533862.woff} +0 -0
  41. /package/lib/{iconfont.1740723810366.woff2 → iconfont.1741051533862.woff2} +0 -0
@@ -149,7 +149,7 @@ function renderForm(h, _vm) {
149
149
  if (hasForm) {
150
150
  return h('div', {
151
151
  key: 'form',
152
- ref: 'formWrapper',
152
+ ref: 'refFormWrapper',
153
153
  class: 'vxe-grid--form-wrapper'
154
154
  }, formSlot ? formSlot.call(_vm, { $grid: _vm }, h) : renderDefaultForm(h, _vm));
155
155
  }
@@ -165,7 +165,7 @@ function renderToolbar(h, _vm) {
165
165
  if (hasToolbar) {
166
166
  return h('div', {
167
167
  key: 'toolbar',
168
- ref: 'toolbarWrapper',
168
+ ref: 'refToolbarWrapper',
169
169
  class: 'vxe-grid--toolbar-wrapper'
170
170
  }, toolbarSlot
171
171
  ? toolbarSlot.call(_vm, { $grid: _vm }, h)
@@ -188,7 +188,7 @@ function renderTop(h, _vm) {
188
188
  return topSlot
189
189
  ? h('div', {
190
190
  key: 'top',
191
- ref: 'topWrapper',
191
+ ref: 'refTopWrapper',
192
192
  class: 'vxe-grid--top-wrapper'
193
193
  }, topSlot.call(_vm, { $grid: _vm }, h))
194
194
  : _e();
@@ -239,7 +239,7 @@ function renderBottom(h, _vm) {
239
239
  return bottomSlot
240
240
  ? h('div', {
241
241
  key: 'bottom',
242
- ref: 'bottomWrapper',
242
+ ref: 'refBottomWrapper',
243
243
  class: 'vxe-grid--bottom-wrapper'
244
244
  }, bottomSlot.call(_vm, { $grid: _vm }, h))
245
245
  : _e();
@@ -257,7 +257,7 @@ function renderPager(h, $xeGrid) {
257
257
  if (hasPager) {
258
258
  return h('div', {
259
259
  key: 'pager',
260
- ref: 'pagerWrapper',
260
+ ref: 'refPagerWrapper',
261
261
  class: 'vxe-grid--pager-wrapper'
262
262
  }, pagerSlot
263
263
  ? pagerSlot.call($xeGrid, { $grid: $xeGrid }, h)
@@ -577,6 +577,7 @@ export default {
577
577
  const vSize = $xeGrid.computeSize;
578
578
  const styles = $xeGrid.computeStyles;
579
579
  return h('div', {
580
+ ref: 'refElem',
580
581
  class: ['vxe-grid', {
581
582
  [`size--${vSize}`]: vSize,
582
583
  'is--animat': !!this.animat,
@@ -599,18 +600,30 @@ export default {
599
600
  }
600
601
  return [];
601
602
  },
602
- getParentHeight() {
603
- const { $el, isZMax } = this;
604
- return (isZMax ? getDomNode().visibleHeight : XEUtils.toNumber(getComputedStyle($el.parentNode).height)) - this.getExcludeHeight();
605
- },
606
603
  /**
607
604
  * 获取需要排除的高度
608
605
  */
609
606
  getExcludeHeight() {
610
- const { $refs, $el, isZMax, height } = this;
611
- const { formWrapper, toolbarWrapper, topWrapper, bottomWrapper, pagerWrapper } = $refs;
612
- const parentPaddingSize = isZMax || !(height === 'auto' || height === '100%') ? 0 : getPaddingTopBottomSize($el.parentNode);
613
- return parentPaddingSize + getPaddingTopBottomSize($el) + getOffsetHeight(formWrapper) + getOffsetHeight(toolbarWrapper) + getOffsetHeight(topWrapper) + getOffsetHeight(bottomWrapper) + getOffsetHeight(pagerWrapper);
607
+ const $xeGrid = this;
608
+ const reactData = $xeGrid;
609
+ const { isZMax } = reactData;
610
+ const el = $xeGrid.$refs.refElem;
611
+ const formWrapper = $xeGrid.$refs.refFormWrapper;
612
+ const toolbarWrapper = $xeGrid.$refs.refToolbarWrapper;
613
+ const topWrapper = $xeGrid.$refs.refTopWrapper;
614
+ const bottomWrapper = $xeGrid.$refs.refBottomWrapper;
615
+ const pagerWrapper = $xeGrid.$refs.refPagerWrapper;
616
+ const parentPaddingSize = isZMax ? 0 : getPaddingTopBottomSize(el.parentNode);
617
+ return parentPaddingSize + getPaddingTopBottomSize(el) + getOffsetHeight(formWrapper) + getOffsetHeight(toolbarWrapper) + getOffsetHeight(topWrapper) + getOffsetHeight(bottomWrapper) + getOffsetHeight(pagerWrapper);
618
+ },
619
+ getParentHeight() {
620
+ const $xeGrid = this;
621
+ const reactData = $xeGrid;
622
+ const el = $xeGrid.$refs.refElem;
623
+ if (el) {
624
+ return (reactData.isZMax ? getDomNode().visibleHeight : XEUtils.toNumber(getComputedStyle(el.parentNode).height)) - $xeGrid.getExcludeHeight();
625
+ }
626
+ return 0;
614
627
  },
615
628
  initToolbar() {
616
629
  this.$nextTick(() => {