Skip to content

Commit

Permalink
feat: upgrade vtable to 1.14.1
Browse files Browse the repository at this point in the history
  • Loading branch information
xuefei1313 committed Dec 25, 2024
1 parent 2794533 commit f382b8e
Show file tree
Hide file tree
Showing 11 changed files with 276 additions and 249 deletions.
361 changes: 186 additions & 175 deletions common/config/rush/pnpm-lock.yaml

Large diffs are not rendered by default.

12 changes: 6 additions & 6 deletions packages/vstory-animate/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,12 @@
"test-watch": "DEBUG_MODE=1 jest --watch"
},
"dependencies": {
"@visactor/vchart": "1.13.2-vstory.2",
"@visactor/vtable": "1.10.1",
"@visactor/vrender": "0.21.5-vstory.2",
"@visactor/vrender-core": "0.21.5-vstory.2",
"@visactor/vrender-kits": "0.21.5-vstory.2",
"@visactor/vrender-components": "0.21.5-vstory.2",
"@visactor/vchart": "1.13.1-vstory.3",
"@visactor/vtable": "1.14.1",
"@visactor/vrender": "0.21.2-vstory.3",
"@visactor/vrender-core": "0.21.2-vstory.3",
"@visactor/vrender-kits": "0.21.2-vstory.3",
"@visactor/vrender-components": "0.21.2-vstory.3",
"@visactor/vutils": "~0.18.17",
"@visactor/vchart-extension": "0.0.3-vstory.2",
"@visactor/vdataset": "~0.18.17",
Expand Down
12 changes: 6 additions & 6 deletions packages/vstory-core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,12 @@
"test-watch": "DEBUG_MODE=1 jest --watch"
},
"dependencies": {
"@visactor/vchart": "1.13.2-vstory.2",
"@visactor/vtable": "1.10.1",
"@visactor/vrender": "0.21.5-vstory.2",
"@visactor/vrender-core": "0.21.5-vstory.2",
"@visactor/vrender-kits": "0.21.5-vstory.2",
"@visactor/vrender-components": "0.21.5-vstory.2",
"@visactor/vchart": "1.13.1-vstory.3",
"@visactor/vtable": "1.14.1",
"@visactor/vrender": "0.21.2-vstory.3",
"@visactor/vrender-core": "0.21.2-vstory.3",
"@visactor/vrender-kits": "0.21.2-vstory.3",
"@visactor/vrender-components": "0.21.2-vstory.3",
"@visactor/vutils": "~0.18.17",
"@visactor/vchart-extension": "0.0.3-vstory.2",
"@visactor/vdataset": "~0.18.17",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,8 @@ export class VTableRender extends DefaultCanvasRectRender implements IGraphicRen
matrix.translate(table.vTableAutoTranslate.x, table.vTableAutoTranslate.y);
const stageMatrix = table.stage.window.getViewBoxTransform().clone();
stageMatrix.multiply(matrix.a, matrix.b, matrix.c, matrix.d, matrix.e, matrix.f);
vTableStage.window.setViewBoxTransform(
// vTableStage.setViewBox();
vTable.setViewBoxTransform(
stageMatrix.a,
stageMatrix.b,
stageMatrix.c,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ export class CommonSpecRuntime implements ITableCharacterRuntime {
// spec.hover = spec.hover ?? {};
// // spec.select.disableSelect = true;
// // spec.hover.disableHover = true;
spec.columnResizeMode = 'none';
spec.rowResizeMode = 'none';
// spec.columnResizeMode = 'none';
// spec.rowResizeMode = 'none';
/** 控制拖拽表头移动位置顺序开关 */
spec.dragHeaderMode = 'none';
// spec.dragHeaderMode = 'none';

spec.chartOption = {
// disableInteraction: true,
Expand Down
12 changes: 6 additions & 6 deletions packages/vstory-editor/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,12 @@
"test-watch": "DEBUG_MODE=1 jest --watch"
},
"dependencies": {
"@visactor/vchart": "1.13.2-vstory.2",
"@visactor/vtable": "1.10.1",
"@visactor/vrender": "0.21.5-vstory.2",
"@visactor/vrender-core": "0.21.5-vstory.2",
"@visactor/vrender-kits": "0.21.5-vstory.2",
"@visactor/vrender-components": "0.21.5-vstory.2",
"@visactor/vchart": "1.13.1-vstory.3",
"@visactor/vtable": "1.14.1",
"@visactor/vrender": "0.21.2-vstory.3",
"@visactor/vrender-core": "0.21.2-vstory.3",
"@visactor/vrender-kits": "0.21.2-vstory.3",
"@visactor/vrender-components": "0.21.2-vstory.3",
"@visactor/vutils": "~0.18.17",
"@visactor/vchart-extension": "0.0.3-vstory.2",
"@visactor/vdataset": "~0.18.17",
Expand Down
12 changes: 6 additions & 6 deletions packages/vstory-external/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,12 @@
"test-watch": "DEBUG_MODE=1 jest --watch"
},
"dependencies": {
"@visactor/vchart": "1.13.2-vstory.2",
"@visactor/vtable": "1.10.1",
"@visactor/vrender": "0.21.5-vstory.2",
"@visactor/vrender-core": "0.21.5-vstory.2",
"@visactor/vrender-kits": "0.21.5-vstory.2",
"@visactor/vrender-components": "0.21.5-vstory.2",
"@visactor/vchart": "1.13.1-vstory.3",
"@visactor/vtable": "1.14.1",
"@visactor/vrender": "0.21.2-vstory.3",
"@visactor/vrender-core": "0.21.2-vstory.3",
"@visactor/vrender-kits": "0.21.2-vstory.3",
"@visactor/vrender-components": "0.21.2-vstory.3",
"@visactor/vutils": "~0.18.17",
"@visactor/vchart-extension": "0.0.3-vstory.2",
"@visactor/vdataset": "~0.18.17",
Expand Down
12 changes: 6 additions & 6 deletions packages/vstory-player/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,12 @@
"test-watch": "DEBUG_MODE=1 jest --watch"
},
"dependencies": {
"@visactor/vchart": "1.13.2-vstory.2",
"@visactor/vtable": "1.10.1",
"@visactor/vrender": "0.21.5-vstory.2",
"@visactor/vrender-core": "0.21.5-vstory.2",
"@visactor/vrender-kits": "0.21.5-vstory.2",
"@visactor/vrender-components": "0.21.5-vstory.2",
"@visactor/vchart": "1.13.1-vstory.3",
"@visactor/vtable": "1.14.1",
"@visactor/vrender": "0.21.2-vstory.3",
"@visactor/vrender-core": "0.21.2-vstory.3",
"@visactor/vrender-kits": "0.21.2-vstory.3",
"@visactor/vrender-components": "0.21.2-vstory.3",
"@visactor/vutils": "~0.18.17",
"@visactor/vchart-extension": "0.0.3-vstory.2",
"@visactor/vdataset": "~0.18.17",
Expand Down
12 changes: 6 additions & 6 deletions packages/vstory-templates/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,12 @@
"test-watch": "DEBUG_MODE=1 jest --watch"
},
"dependencies": {
"@visactor/vchart": "1.13.2-vstory.2",
"@visactor/vtable": "1.10.1",
"@visactor/vrender": "0.21.5-vstory.2",
"@visactor/vrender-core": "0.21.5-vstory.2",
"@visactor/vrender-kits": "0.21.5-vstory.2",
"@visactor/vrender-components": "0.21.5-vstory.2",
"@visactor/vchart": "1.13.1-vstory.3",
"@visactor/vtable": "1.14.1",
"@visactor/vrender": "0.21.2-vstory.3",
"@visactor/vrender-core": "0.21.2-vstory.3",
"@visactor/vrender-kits": "0.21.2-vstory.3",
"@visactor/vrender-components": "0.21.2-vstory.3",
"@visactor/vutils": "~0.18.17",
"@visactor/vchart-extension": "0.0.3-vstory.2",
"@visactor/vdataset": "~0.18.17",
Expand Down
2 changes: 1 addition & 1 deletion packages/vstory/demo/src/demos/table/base.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ function loadDSL() {
zIndex: 10,
position: {
top: 20,
left: 560,
left: 540,
width: 600,
height: 630
},
Expand Down
81 changes: 48 additions & 33 deletions packages/vstory/demo/src/demos/table/option-list-table.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,50 @@
const columns = [
{
field: 'group',
title: 'department',
width: 'auto',
tree: true,
fieldFormat(rec) {
return rec['department'] ?? rec['group'] ?? rec['name'];
}
},
{
field: 'total_children',
title: 'memebers count',
width: 'auto',
fieldFormat(rec) {
if (rec?.['position']) {
return `position: ${rec['position']}`;
} else return rec?.['total_children'];
}
},
{
field: 'monthly_expense',
title: 'monthly expense',
width: 'auto',
fieldFormat(rec) {
if (rec?.['salary']) {
return `salary: ${rec['salary']}`;
} else return rec?.['monthly_expense'];
}
},
{
field: 'new_hires_this_month',
title: 'new hires this month',
width: 'auto'
},
{
field: 'resignations_this_month',
title: 'resignations this month',
width: 'auto'
},
{
field: 'complaints_and_suggestions',
title: 'recived complaints counts',
width: 'auto'
}
];

export const listTableOption = {
records: [
{
Expand Down Expand Up @@ -423,38 +470,6 @@ export const listTableOption = {
hierarchyState: 'collapse'
}
],
columns: [
{
field: 'group',
title: 'department',
width: 'auto',
tree: true
},
{
field: 'total_children',
title: 'memebers count',
width: 'auto'
},
{
field: 'monthly_expense',
title: 'monthly expense',
width: 'auto'
},
{
field: 'new_hires_this_month',
title: 'new hires this month',
width: 'auto'
},
{
field: 'resignations_this_month',
title: 'resignations this month',
width: 'auto'
},
{
field: 'complaints_and_suggestions',
title: 'recived complaints counts',
width: 'auto'
}
],
columns,
widthMode: 'standard'
};

0 comments on commit f382b8e

Please sign in to comment.