Skip to content

Commit

Permalink
fix: fix empty line display in multilinesForXTable mode
Browse files Browse the repository at this point in the history
  • Loading branch information
Rui-Sun committed Jul 10, 2024
1 parent fc01717 commit 3fc3611
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions packages/vtable/src/scenegraph/utils/break-string.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,14 @@ export function breakString(textStr: string, table: BaseTableAPI) {
text.pop();
}

if (table.options.customConfig?.multilinesForXTable && !table.internalProps.autoWrapText) {
// clear empty string in array start;
// align width xtable display
while (text.length && text.length > 1 && !text[0]) {
text.shift();
}
}

return {
text,
moreThanMaxCharacters
Expand Down

0 comments on commit 3fc3611

Please sign in to comment.