web: contain markdown tables inside the phone transcript

Wrap each table in its own scroll frame and let the markdown grid shrink, so a
wide table scrolls sideways instead of pushing the chat content past its div.
This commit is contained in:
2026-10-20 11:50:27 +01:00
parent 443986498d
commit 74b74adee7
2 changed files with 14 additions and 5 deletions
+4 -1
View File
@@ -3184,7 +3184,10 @@ function renderMarkdownBlock(block) {
body.append(tr);
}
table.append(body);
return table;
// A markdown table must never widen the message bubble. Scroll it sideways
// inside its own frame on a phone instead of pushing the transcript past its
// right edge.
return h("div", { class: "md-table-wrap" }, table);
}
// Anything outside the subset stays plain text and is never dropped.
return h("p", { class: "md-paragraph", text: block.text ?? "" });