[v11.2.x] Table: Fix edge case where text wrapping crashes on undefined header widths (#91961)
Table: Fix edge case where text wrapping crashes on undefined header widths (#91850)
Make sure we don't read from header groups if it's undefined
(cherry picked from commit 40144eb3c8)
Co-authored-by: Kyle Cunningham <codeincarnate@users.noreply.github.com>
This commit is contained in:
co-authored by
Kyle Cunningham
parent
59476ab8f8
commit
3b37be93e9
@@ -645,7 +645,7 @@ export function guessTextBoundingBox(
|
|||||||
lineHeight: number,
|
lineHeight: number,
|
||||||
defaultRowHeight: number
|
defaultRowHeight: number
|
||||||
) {
|
) {
|
||||||
const width = Number(headerGroup.width ?? 300);
|
const width = Number(headerGroup?.width ?? 300);
|
||||||
const LINE_SCALE_FACTOR = 1.17;
|
const LINE_SCALE_FACTOR = 1.17;
|
||||||
const LOW_LINE_PAD = 42;
|
const LOW_LINE_PAD = 42;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user