diff --git a/components/RichTextRenderer/RichTextRenderer.tsx b/components/RichTextRenderer/RichTextRenderer.tsx index bbbe7321..890045ea 100644 --- a/components/RichTextRenderer/RichTextRenderer.tsx +++ b/components/RichTextRenderer/RichTextRenderer.tsx @@ -19,7 +19,8 @@ const RichTextRenderer: React.FC = ({ // (e.g. very long runs of nbsp that prevent wrapping). const hasOverflowRiskNbsp = /(?: |\u00A0){6,}/.test(rawContent) || - /(?:\w(?: |\u00A0)){12,}\w/i.test(rawContent); + /(?:\w(?: |\u00A0)){12,}\w/i.test(rawContent) || + (rawContent.match(/ |\u00A0/g)?.length ?? 0) >= 10 const normalizedContent = hasOverflowRiskNbsp ? rawContent.replace(/ /g, ' ').replace(/\u00A0/g, ' ')