fix(ui): chat bubble text wrapping — replace break-words with overflow-wrap:anywhere
Fixes MascotChatbot messages wrapping 1 character per line. overflow-wrap:anywhere handles long unbroken strings better than break-words which only breaks at word boundaries.
This commit is contained in:
@@ -188,7 +188,7 @@ export function MascotChatbot({
|
|||||||
)}
|
)}
|
||||||
<div
|
<div
|
||||||
className={cn(
|
className={cn(
|
||||||
"max-w-xs px-3 py-2 rounded-xl text-sm break-words leading-relaxed",
|
"max-w-xs px-3 py-2 rounded-xl text-sm leading-relaxed [overflow-wrap:anywhere]",
|
||||||
message.role === "user"
|
message.role === "user"
|
||||||
? "bg-[#23a1eb] text-white rounded-br-[4px]"
|
? "bg-[#23a1eb] text-white rounded-br-[4px]"
|
||||||
: "bg-[#f5f5f5] text-[#1a1a1a] rounded-bl-[4px]",
|
: "bg-[#f5f5f5] text-[#1a1a1a] rounded-bl-[4px]",
|
||||||
|
|||||||
Reference in New Issue
Block a user