From 612a6bbdafd07b86176dcad30660adc3f966f585 Mon Sep 17 00:00:00 2001 From: Gren Paut <90505696+AnotherDork@users.noreply.github.com> Date: Tue, 25 Aug 2026 16:31:04 +0300 Subject: [PATCH] Wrap wide editor tables instead of scrolling them Document tables render at width:max-content, so a table wider than the editor column never wraps its cells and can only be read by scrolling .tableWrapper sideways. Documents imported with unset colwidth attributes hit this for almost every table, because prosemirror-tables only overrides the width inline once every column has an explicit width. Cap the table at the container width. Narrow tables keep their max-content width, wide ones wrap their cells, and a cell holding an unbreakable token still falls back to the wrapper's scroll. Signed-off-by: Gren Paut <90505696+AnotherDork@users.noreply.github.com> --- packages/ui/src/rich-editor.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/ui/src/rich-editor.css b/packages/ui/src/rich-editor.css index 2631eafb57..a6d68242b4 100644 --- a/packages/ui/src/rich-editor.css +++ b/packages/ui/src/rich-editor.css @@ -59,7 +59,7 @@ } table { - @apply border border-border-mid border-collapse w-max; + @apply border border-border-mid border-collapse w-max max-w-full; tbody { @apply border border-border-mid border-collapse; }