vxe-table 4.21.0-beta.5 → 4.21.0-beta.7

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 (44) hide show
  1. package/README.md +1 -2
  2. package/dist/all.esm.js +23 -8
  3. package/dist/style.css +1 -1
  4. package/dist/style.min.css +1 -1
  5. package/es/index.css +1 -1
  6. package/es/index.min.css +1 -1
  7. package/es/style.css +1 -1
  8. package/es/style.min.css +1 -1
  9. package/es/table/src/body.js +12 -5
  10. package/es/table/src/util.js +9 -1
  11. package/es/table/style.css +9 -0
  12. package/es/table/style.min.css +1 -1
  13. package/es/ui/index.js +1 -1
  14. package/es/ui/src/log.js +1 -1
  15. package/es/vxe-table/style.css +9 -0
  16. package/es/vxe-table/style.min.css +1 -1
  17. package/lib/index.css +1 -1
  18. package/lib/index.min.css +1 -1
  19. package/lib/index.umd.js +29 -8
  20. package/lib/index.umd.min.js +1 -1
  21. package/lib/style.css +1 -1
  22. package/lib/style.min.css +1 -1
  23. package/lib/table/src/body.js +14 -5
  24. package/lib/table/src/body.min.js +1 -1
  25. package/lib/table/src/util.js +13 -1
  26. package/lib/table/src/util.min.js +1 -1
  27. package/lib/table/style/style.css +9 -0
  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/log.js +1 -1
  32. package/lib/ui/src/log.min.js +1 -1
  33. package/lib/vxe-table/style/style.css +9 -0
  34. package/lib/vxe-table/style/style.min.css +1 -1
  35. package/package.json +2 -2
  36. package/packages/table/src/body.ts +13 -5
  37. package/packages/table/src/util.ts +9 -1
  38. package/styles/components/table.scss +10 -0
  39. /package/es/{iconfont.1787220437603.ttf → iconfont.1787383502391.ttf} +0 -0
  40. /package/es/{iconfont.1787220437603.woff → iconfont.1787383502391.woff} +0 -0
  41. /package/es/{iconfont.1787220437603.woff2 → iconfont.1787383502391.woff2} +0 -0
  42. /package/lib/{iconfont.1787220437603.ttf → iconfont.1787383502391.ttf} +0 -0
  43. /package/lib/{iconfont.1787220437603.woff → iconfont.1787383502391.woff} +0 -0
  44. /package/lib/{iconfont.1787220437603.woff2 → iconfont.1787383502391.woff2} +0 -0
package/README.md CHANGED
@@ -128,7 +128,6 @@
128
128
  * [x] ([企业版](https://store.vxeui.com)) 单元格区域选取
129
129
  * [x] ([企业版](https://store.vxeui.com)) 单元格复制/粘贴
130
130
  * [x] ([企业版](https://store.vxeui.com)) 单元格查找和替换
131
- * [x] ([企业版](https://store.vxeui.com)) 全键盘操作
132
131
  * [x] ([企业版](https://store.vxeui.com)) 集成图表
133
132
 
134
133
  ## 安装
@@ -156,7 +155,7 @@ createApp(App).use(VxeUITable).mount('#app')
156
155
  ### CDN
157
156
 
158
157
  使用第三方 CDN 方式记得锁定版本号,避免受到非兼容性更新的影响
159
- ***不建议将第三方的 CDN 地址用于正式环境,因为该连接随时都可能会失效***
158
+ **不建议将第三方的 CDN 地址用于正式环境,因为该连接随时都可能会失效**
160
159
 
161
160
  ```HTML
162
161
  <!DOCTYPE html>
package/dist/all.esm.js CHANGED
@@ -47,7 +47,7 @@ function getDefaultConfig(val1, def1) {
47
47
  return XEUtils.eqNull(val1) ? def1 : val1;
48
48
  }
49
49
 
50
- const version = "4.21.0-beta.5";
50
+ const version = "4.21.0-beta.7";
51
51
  VxeUI.version = version;
52
52
  VxeUI.tableVersion = version;
53
53
  VxeUI.setConfig({
@@ -769,7 +769,7 @@ function wheelScrollTopTo(diffNum, cb) {
769
769
  }
770
770
 
771
771
  const { log } = VxeUI;
772
- const tableVersion = `table v${"4.21.0-beta.5"}`;
772
+ const tableVersion = `table v${"4.21.0-beta.7"}`;
773
773
  function createComponentLog(name) {
774
774
  const uiVersion = VxeUI.uiVersion ? `ui v${VxeUI.uiVersion}` : '';
775
775
  const ganttVersion = VxeUI.ganttVersion ? `gantt v${VxeUI.ganttVersion}` : '';
@@ -1621,7 +1621,15 @@ function handleRowidOrRow($xeTable, rowidOrRow) {
1621
1621
  return null;
1622
1622
  }
1623
1623
  function getCellRestHeight(rowRest, cellOpts, rowOpts, defaultRowHeight) {
1624
- return rowRest.resizeHeight || cellOpts.height || rowOpts.height || rowRest.height || defaultRowHeight;
1624
+ const { height, minHeight, maxHeight } = cellOpts;
1625
+ let cellHeight = rowRest.resizeHeight || height || rowOpts.height || rowRest.height || defaultRowHeight;
1626
+ if (maxHeight && maxHeight < cellHeight) {
1627
+ cellHeight = maxHeight;
1628
+ }
1629
+ if (minHeight && minHeight > cellHeight) {
1630
+ cellHeight = minHeight;
1631
+ }
1632
+ return cellHeight;
1625
1633
  }
1626
1634
  function getPaddingLeftRightSize(elem) {
1627
1635
  if (elem) {
@@ -4163,7 +4171,7 @@ var TableBodyComponent = defineVxeComponent({
4163
4171
  const cellOffsetWidth = computeCellOffsetWidth.value;
4164
4172
  const { selectCellToRow } = areaOpts;
4165
4173
  const { field, type, cellRender, editRender, align, showOverflow, className, treeNode, rowResize, padding, verticalAlign, slots } = column;
4166
- const { verticalAlign: allVerticalAlign } = cellOpts;
4174
+ const { verticalAlign: allVerticalAlign, minHeight, maxHeight } = cellOpts;
4167
4175
  const { actived } = editStore;
4168
4176
  const rowRest = fullAllDataRowIdData[rowid] || {};
4169
4177
  const colid = column.id;
@@ -4345,6 +4353,9 @@ var TableBodyComponent = defineVxeComponent({
4345
4353
  }
4346
4354
  }
4347
4355
  const tcStyle = {};
4356
+ if (maxHeight) {
4357
+ tcStyle.maxHeight = maxHeight + 'px';
4358
+ }
4348
4359
  if (hasEllipsis && resizeWidthFlag) {
4349
4360
  let mergeColWidth = 0;
4350
4361
  if (mergeColspan > 1) {
@@ -4355,13 +4366,16 @@ var TableBodyComponent = defineVxeComponent({
4355
4366
  }
4356
4367
  }
4357
4368
  }
4358
- tcStyle.width = `${column.renderWidth + mergeColWidth - cellOffsetWidth}px`;
4369
+ tcStyle.width = (column.renderWidth + mergeColWidth - cellOffsetWidth) + 'px';
4359
4370
  }
4360
4371
  if (scrollYLoad || scrollXLoad || hasEllipsis || isCsHeight || isRsHeight) {
4361
- tcStyle.height = `${cellHeight}px`;
4372
+ tcStyle.height = cellHeight + 'px';
4362
4373
  }
4363
4374
  else {
4364
- tcStyle.minHeight = `${cellHeight}px`;
4375
+ tcStyle.minHeight = cellHeight + 'px';
4376
+ }
4377
+ if (minHeight) {
4378
+ tcStyle.minHeight = minHeight + 'px';
4365
4379
  }
4366
4380
  const tdVNs = [];
4367
4381
  if (fixedHiddenColumn && isAllOverflow) {
@@ -4407,7 +4421,7 @@ var TableBodyComponent = defineVxeComponent({
4407
4421
  class: ['vxe-cell--valid-error-tip', getPropClass(validOpts.className, validParams)],
4408
4422
  style: errRule && errRule.maxWidth
4409
4423
  ? {
4410
- width: `${errRule.maxWidth}px`
4424
+ width: errRule.maxWidth + 'px'
4411
4425
  }
4412
4426
  : null
4413
4427
  }, [
@@ -4462,6 +4476,7 @@ var TableBodyComponent = defineVxeComponent({
4462
4476
  'col--rs-height': isRsHeight,
4463
4477
  'col--to-row': showAreaRowStatus,
4464
4478
  'col--auto-height': isVNAutoHeight,
4479
+ 'col--max-height': maxHeight,
4465
4480
  'fixed--width': !isAutoCellWidth,
4466
4481
  'fixed--hidden': fixedHiddenColumn,
4467
4482
  'is--padding': isCellPadding,