Skip to content

Commit

Permalink
Merge pull request #1779 from VisActor/1778-bug-tree-mode-with-rowhie…
Browse files Browse the repository at this point in the history
…rarchytextstartalignment-computcolwidth-error

1778 bug tree mode with rowhierarchytextstartalignment computcolwidth error
  • Loading branch information
fangsmile committed May 24, 2024
2 parents 6a2c40b + 33472bd commit 20c0c6b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"changes": [
{
"comment": "fix: first col tree mode compute col width error #1778\n\n",
"type": "none",
"packageName": "@visactor/vtable"
}
],
"packageName": "@visactor/vtable",
"email": "[email protected]"
}
2 changes: 1 addition & 1 deletion packages/vtable/src/scenegraph/layout/compute-col-width.ts
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,7 @@ function computeAutoColWidth(
if ((hd as HeaderData)?.define?.columnWidthComputeMode === 'only-body') {
continue;
}
if ((hd as HeaderData)?.hierarchyLevel) {
if (isValid((hd as HeaderData)?.hierarchyLevel)) {
cellHierarchyIndent =
((hd as HeaderData).hierarchyLevel ?? 0) * ((layoutMap as PivotHeaderLayoutMap).rowHierarchyIndent ?? 0);
if (
Expand Down

0 comments on commit 20c0c6b

Please sign in to comment.