Skip to content

Commit 6eb12f6

Browse files
authored
Merge pull request #5009 from VisActor/release/1.23.2
[Auto release] release 1.23.2
2 parents 281f1df + 8ab5fb6 commit 6eb12f6

File tree

91 files changed

+7904
-151
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

91 files changed

+7904
-151
lines changed
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
[{"definitionName":"lockStepVersion","policyName":"vtableMain","version":"1.23.1","mainProject":"@visactor/vtable","nextBump":"patch"}]
1+
[{"definitionName":"lockStepVersion","policyName":"vtableMain","version":"1.23.2","mainProject":"@visactor/vtable","nextBump":"patch"}]

docs/assets/api/en/icon/base-icon.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,8 @@ enum IconFuncTypeEnum {
6565
dropDownState = 'dropDownState',
6666
play = 'play',
6767
damagePic = 'damagePic',
68+
imageDamagePic = 'imageDamagePic',
69+
videoDamagePic = 'videoDamagePic',
6870
expand = 'expand',
6971
collapse = 'collapse',
7072
drillDown = 'drillDown',

docs/assets/api/zh/icon/base-icon.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,8 @@ enum IconFuncTypeEnum {
6565
dropDownState = 'dropDownState',
6666
play = 'play',
6767
damagePic = 'damagePic',
68+
imageDamagePic = 'imageDamagePic',
69+
videoDamagePic = 'videoDamagePic',
6870
expand = 'expand',
6971
collapse = 'collapse',
7072
drillDown = 'drillDown',

docs/assets/changelog/en/release.md

Lines changed: 42 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,55 @@
1+
# v1.23.1
2+
3+
2026-02-05
4+
5+
6+
**🆕 New feature**
7+
8+
- **@visactor/vtable**: add componentLayoutOrder api [#4965](https://github.com/VisActor/VTable/issues/4965)
9+
- **@visactor/vtable**: optimize search latency
10+
- **@visactor/vtable**: add batch update cell value api and optimize filter state data sync
11+
- **@visactor/vtable**: add syncRecordOperationsToSourceRecords option to support sync operations to source data
12+
- **@visactor/vtable-sheet**: add updateOption api and optimize formula calculation
13+
- **@visactor/vtable-sheet**: add editable option to support edit cell
14+
15+
**🐛 Bug fix**
16+
17+
- **@visactor/vtable**: fix prepareEdit occor error [#4871](https://github.com/VisActor/VTable/issues/4871)
18+
- **@visactor/vtable**: updateOption run resize logic [#4965](https://github.com/VisActor/VTable/issues/4965)
19+
- **@visactor/vtable**: fix add record position error in filter state
20+
- **@visactor/vtable**: handle escape option correctly for CSV export
21+
- **@visactor/vtable**: set white background for media overlay image
22+
23+
**🔨 Refactor**
24+
25+
- **@visactor/vtable**: legend and title component position calculation logic [#4965](https://github.com/VisActor/VTable/issues/4965)
26+
27+
28+
29+
[more detail about v1.23.1](https://github.com/VisActor/VTable/releases/tag/v1.23.1)
30+
131
# v1.23.0
232

333
2026-01-29
434

535

636
**🆕 New feature**
7-
8-
- **@visactor/vtable-sheet**: add event system for vtable sheet [#4861](https://github.com/VisActor/VTable/issues/4861)
37+
38+
- **@visactor/vtable-sheet**: add event system for vtable sheet [#4861](https://github.com/VisActor/VTable/issues/4861)
939

1040
**🐛 Bug fix**
11-
12-
- **@visactor/vtable**: when dimension value is empty string should different from no dimension value [#4935](https://github.com/VisActor/VTable/issues/4935)
13-
- **@visactor/vtable**: when no columnTree to adjust columnWidthConfig [#4935](https://github.com/VisActor/VTable/issues/4935)
14-
- **@visactor/vtable**: change dimension value to recalculate totalTree [#4953](https://github.com/VisActor/VTable/issues/4953)
15-
- **@visactor/vtable**: when change dimenison value should update cached changedTree value
16-
- **@visactor/vtable**: to update formula after add records
17-
- **@visactor/vtable**: react type define
41+
42+
- **@visactor/vtable**: when dimension value is empty string should different from no dimension value [#4935](https://github.com/VisActor/VTable/issues/4935)
43+
- **@visactor/vtable**: when no columnTree to adjust columnWidthConfig [#4935](https://github.com/VisActor/VTable/issues/4935)
44+
- **@visactor/vtable**: change dimension value to recalculate totalTree [#4953](https://github.com/VisActor/VTable/issues/4953)
45+
- **@visactor/vtable**: when change dimenison value should update cached changedTree value
46+
- **@visactor/vtable**: to update formula after add records
47+
- **@visactor/vtable**: react type define
1848

1949
**🔨 Refactor**
20-
21-
- **@visactor/vtable**: pivotTable have to distinguishing no dimension and dimension value is null character string
22-
50+
51+
- **@visactor/vtable**: pivotTable have to distinguishing no dimension and dimension value is null character string
52+
2353

2454

2555
[more detail about v1.23.0](https://github.com/VisActor/VTable/releases/tag/v1.23.0)

docs/assets/changelog/zh/release.md

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,34 @@
1+
# v1.23.1
2+
3+
2026-02-05
4+
5+
6+
**🆕 新增功能**
7+
8+
- **@visactor/vtable**: 新增 componentLayoutOrder 接口 [#4965](https://github.com/VisActor/VTable/issues/4965)
9+
- **@visactor/vtable**: 优化搜索性能
10+
- **@visactor/vtable**: 新增基于记录索引的单元格值修改方法及优化范围删除性能
11+
- **@visactor/vtable**: 新增 syncRecordOperationsToSourceRecords 选项支持同步操作到源数据
12+
- **@visactor/vtable**: 新增批量修改单元格值接口及优化筛选态数据同步
13+
- **@visactor/vtable-sheet**: 新增 updateOption 接口 及优化公式计算
14+
- **@visactor/vtable-sheet**: 新增 editable 选项支持编辑单元格
15+
16+
**🐛 功能修复**
17+
18+
- **@visactor/vtable**: 修复 prepareEdit 方法执行错误问题 [#4871](https://github.com/VisActor/VTable/issues/4871)
19+
- **@visactor/vtable**: 修复 updateOption 方法执行时触发 resize 逻辑问题 [#4965](https://github.com/VisActor/VTable/issues/4965)
20+
- **@visactor/vtable**: 修复过滤状态下新增记录位置错误问题
21+
- **@visactor/vtable**: 修复 CSV 导出时 escape 选项处理错误问题
22+
- **@visactor/vtable**: 修复媒体覆盖图片背景设置为白色问题
23+
24+
**🔨 功能重构**
25+
26+
- **@visactor/vtable**: 优化图例和标题组件位置计算逻辑 [#4965](https://github.com/VisActor/VTable/issues/4965)
27+
28+
29+
30+
[更多详情请查看 v1.23.1](https://github.com/VisActor/VTable/releases/tag/v1.23.1)
31+
132
# v1.23.0
233

334
2026-01-29

docs/assets/demo/en/gantt/gantt-datazoom.md

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -891,10 +891,27 @@ function createZoomControls(ganttInstance) {
891891

892892
radio.onchange = () => {
893893
if (radio.checked) {
894-
// Switch to middle state of corresponding level
894+
// 🎯 Zoom with view center as anchor point
895+
// 1. Get the time point corresponding to the current view center
896+
const scrollLeft = ganttInstance.stateManager.scrollLeft;
897+
const viewportWidth = ganttInstance.tableNoFrameWidth;
898+
const centerScrollPos = scrollLeft + viewportWidth / 2;
899+
900+
const currentMsPerPixel = ganttInstance.getCurrentMillisecondsPerPixel();
901+
const centerTime = ganttInstance.parsedOptions._minDateTime + centerScrollPos * currentMsPerPixel;
902+
903+
// 2. Switch to corresponding level
895904
ganttInstance.zoomScaleManager?.setZoomPosition({
896905
levelNum: index
897906
});
907+
908+
// 3. Adjust scroll position to keep center time point at view center
909+
const newMsPerPixel = ganttInstance.getCurrentMillisecondsPerPixel();
910+
const newCenterScrollPos = (centerTime - ganttInstance.parsedOptions._minDateTime) / newMsPerPixel;
911+
const newScrollLeft = newCenterScrollPos - viewportWidth / 2;
912+
913+
ganttInstance.stateManager.setScrollLeft(Math.max(0, newScrollLeft));
914+
898915
updateStatusDisplay();
899916
}
900917
};

docs/assets/demo/en/gantt/gantt-zoom.md

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -911,10 +911,27 @@ function createZoomControls(ganttInstance) {
911911

912912
radio.onchange = () => {
913913
if (radio.checked) {
914-
// Switch to the middle state of the corresponding level
914+
// 🎯 Zoom with view center as anchor point
915+
// 1. Get the time point corresponding to the current view center
916+
const scrollLeft = ganttInstance.stateManager.scrollLeft;
917+
const viewportWidth = ganttInstance.tableNoFrameWidth;
918+
const centerScrollPos = scrollLeft + viewportWidth / 2;
919+
920+
const currentMsPerPixel = ganttInstance.getCurrentMillisecondsPerPixel();
921+
const centerTime = ganttInstance.parsedOptions._minDateTime + centerScrollPos * currentMsPerPixel;
922+
923+
// 2. Switch to corresponding level
915924
ganttInstance.zoomScaleManager?.setZoomPosition({
916925
levelNum: index
917926
});
927+
928+
// 3. Adjust scroll position to keep center time point at view center
929+
const newMsPerPixel = ganttInstance.getCurrentMillisecondsPerPixel();
930+
const newCenterScrollPos = (centerTime - ganttInstance.parsedOptions._minDateTime) / newMsPerPixel;
931+
const newScrollLeft = newCenterScrollPos - viewportWidth / 2;
932+
933+
ganttInstance.stateManager.setScrollLeft(Math.max(0, newScrollLeft));
934+
918935
updateStatusDisplay();
919936
}
920937
};

docs/assets/demo/zh/gantt/gantt-datazoom.md

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -892,10 +892,27 @@ function createZoomControls(ganttInstance) {
892892

893893
radio.onchange = () => {
894894
if (radio.checked) {
895-
// 切换到对应级别的中间状态
895+
// 🎯 以视图中心为缩放中心
896+
// 1. 获取当前视图中心对应的时间点
897+
const scrollLeft = ganttInstance.stateManager.scrollLeft;
898+
const viewportWidth = ganttInstance.tableNoFrameWidth;
899+
const centerScrollPos = scrollLeft + viewportWidth / 2;
900+
901+
const currentMsPerPixel = ganttInstance.getCurrentMillisecondsPerPixel();
902+
const centerTime = ganttInstance.parsedOptions._minDateTime + centerScrollPos * currentMsPerPixel;
903+
904+
// 2. 切换到对应级别
896905
ganttInstance.zoomScaleManager?.setZoomPosition({
897906
levelNum: index
898907
});
908+
909+
// 3. 调整滚动位置,使中心时间点保持在视图中心
910+
const newMsPerPixel = ganttInstance.getCurrentMillisecondsPerPixel();
911+
const newCenterScrollPos = (centerTime - ganttInstance.parsedOptions._minDateTime) / newMsPerPixel;
912+
const newScrollLeft = newCenterScrollPos - viewportWidth / 2;
913+
914+
ganttInstance.stateManager.setScrollLeft(Math.max(0, newScrollLeft));
915+
899916
updateStatusDisplay();
900917
}
901918
};

docs/assets/demo/zh/gantt/gantt-zoom.md

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -882,10 +882,27 @@ function createZoomControls(ganttInstance) {
882882

883883
radio.onchange = () => {
884884
if (radio.checked) {
885-
// 切换到对应级别的中间状态
885+
// 🎯 以视图中心为缩放中心
886+
// 1. 获取当前视图中心对应的时间点
887+
const scrollLeft = ganttInstance.stateManager.scrollLeft;
888+
const viewportWidth = ganttInstance.tableNoFrameWidth;
889+
const centerScrollPos = scrollLeft + viewportWidth / 2;
890+
891+
const currentMsPerPixel = ganttInstance.getCurrentMillisecondsPerPixel();
892+
const centerTime = ganttInstance.parsedOptions._minDateTime + centerScrollPos * currentMsPerPixel;
893+
894+
// 2. 切换到对应级别
886895
ganttInstance.zoomScaleManager?.setZoomPosition({
887896
levelNum: index
888897
});
898+
899+
// 3. 调整滚动位置,使中心时间点保持在视图中心
900+
const newMsPerPixel = ganttInstance.getCurrentMillisecondsPerPixel();
901+
const newCenterScrollPos = (centerTime - ganttInstance.parsedOptions._minDateTime) / newMsPerPixel;
902+
const newScrollLeft = newCenterScrollPos - viewportWidth / 2;
903+
904+
ganttInstance.stateManager.setScrollLeft(Math.max(0, newScrollLeft));
905+
889906
updateStatusDisplay();
890907
}
891908
};

docs/assets/guide/en/cell_type/cellType.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -254,6 +254,8 @@ The following shows an example of `cellType: ()=>{}`: (Please refer to [Example]
254254
}
255255
```
256256
257+
The headerType in the rows and columns of the pivot table, and the cellType in the indicators also support the function form.
258+
257259
## Extension: Custom Column Types (TypeScript)
258260
259261
In real-world applications, in addition to VTable’s built-in `cellType` values (such as `text`, `link`, `image`, `video`, `progressbar`, `sparkline`, and `chart`), it is often necessary to attach **business-specific configurations** to column definitions, for example:

0 commit comments

Comments
 (0)