From fa74ec4220f6160ad82bc5e0f0dc084d824984ff Mon Sep 17 00:00:00 2001 From: Devil1716 Date: Sat, 18 Jul 2026 13:15:50 +0530 Subject: [PATCH] Use Content tooltips for Markdown table cells compose() passed cell.plain (str) into with_tooltip, which renders markup-enabled and raises MarkupError for bracketed cell text like ([sys:LOCK=SAFE]). Pass the Content object instead, matching the streaming _update_rows path. Fixes #6642 Co-authored-by: Cursor --- src/textual/widgets/_markdown.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/textual/widgets/_markdown.py b/src/textual/widgets/_markdown.py index 847f5cfa5a..6b5a04cde3 100644 --- a/src/textual/widgets/_markdown.py +++ b/src/textual/widgets/_markdown.py @@ -676,7 +676,7 @@ def compose(self) -> ComposeResult: cell, classes=f"row{row_index} cell", name=f"cell{row_index}.{cell_index}", - ).with_tooltip(cell.plain) + ).with_tooltip(cell) self.last_row = row_index def _update_content(self, headers: list[Content], rows: list[list[Content]]):