From 09d8cf20b83a0d2dc5b6e9347d21361f4d31f13e Mon Sep 17 00:00:00 2001 From: Steffen Becker Date: Sat, 8 Aug 2026 12:35:05 +0000 Subject: [PATCH] fix: break a word that is wider than its line MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit A long URL or a German compound ran straight past the right margin, where Word and LibreOffice break it — measured against LO in a 2cm column, the break now falls on the same character. `break-word` rather than `anywhere`, so a table column's minimum width is still its longest word. --- src/styles/editor.css | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/styles/editor.css b/src/styles/editor.css index b99875e..3d1f290 100644 --- a/src/styles/editor.css +++ b/src/styles/editor.css @@ -383,6 +383,10 @@ hanging into the margin, so lines break one word earlier than in Word/LibreOffice. `pre-wrap` lets it hang, as they do. */ white-space: pre-wrap; + /* A word too long for its line (a URL, a German compound) is broken by Word and + LibreOffice rather than run past the margin. `break-word`, not `anywhere`, so a + table column's min-content width is still the longest word. */ + overflow-wrap: break-word; } .paper .tiptap h1,