From 93b582c385d23cb7d8d5dd44250266a3f852eca8 Mon Sep 17 00:00:00 2001 From: "alonso.torres" Date: Thu, 19 May 2022 14:16:48 +0200 Subject: [PATCH] :bug: Fix problem with small with texts --- frontend/src/app/main/ui/shapes/text/styles.cljs | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/frontend/src/app/main/ui/shapes/text/styles.cljs b/frontend/src/app/main/ui/shapes/text/styles.cljs index f6490e5fb..fb63acd0a 100644 --- a/frontend/src/app/main/ui/shapes/text/styles.cljs +++ b/frontend/src/app/main/ui/shapes/text/styles.cljs @@ -21,7 +21,7 @@ :width width :fontFamily "sourcesanspro" :display "flex" - :whiteSpace "pre-wrap"}] + :whiteSpace "break-spaces"}] (cond-> base (= valign "top") (obj/set! "alignItems" "flex-start") (= valign "center") (obj/set! "alignItems" "center") @@ -83,7 +83,9 @@ :lineHeight (or line-height "1.2") :color (if show-text? text-color "transparent") :caretColor (or text-color "black") - :overflowWrap "initial"} + :overflowWrap "initial" + :lineBreak "auto" + :whiteSpace "break-spaces"} fills (cond @@ -126,7 +128,4 @@ (obj/set! "fontWeight" font-weight)) (= grow-type :auto-width) - (obj/set! "whiteSpace" "pre") - - (not= grow-type :auto-width) - (obj/set! "whiteSpace" "pre-wrap"))))) + (obj/set! "whiteSpace" "pre")))))