From b306c16a58e5cad4d51ca58472f54c4f676e1fdf Mon Sep 17 00:00:00 2001 From: linghaoSu Date: Wed, 24 Jul 2024 23:32:04 +0800 Subject: [PATCH] fix(text): not need fixed bounding box when contentWidth min than style width --- src/graphic/Text.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/graphic/Text.ts b/src/graphic/Text.ts index d7fd9f27e..fdb7d1efd 100644 --- a/src/graphic/Text.ts +++ b/src/graphic/Text.ts @@ -554,6 +554,7 @@ class ZRText extends Displayable implements GroupLike { const hasShadow = style.textShadowBlur > 0; const fixedBoundingRect = style.width != null + && text !== textLines[0] && (style.overflow === 'truncate' || style.overflow === 'break' || style.overflow === 'breakAll'); const calculatedLineHeight = contentBlock.calculatedLineHeight;