Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions src/textual/widgets/_markdown.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
from textual.app import ComposeResult
from textual.await_complete import AwaitComplete
from textual.containers import Horizontal, Vertical, VerticalScroll
from textual.css.query import NoMatches
from textual.events import Mount
from textual.message import Message
from textual.reactive import reactive, var
Expand Down Expand Up @@ -425,7 +426,7 @@ class MarkdownOrderedList(MarkdownList):

MarkdownOrderedList Vertical {
height: auto;
width: 1fr;
width: 1fr;
}
"""

Expand Down Expand Up @@ -651,7 +652,10 @@ def _retheme(self) -> None:
if self.app.current_theme.dark
else self._markdown.code_light_theme
)
self.get_child_by_type(Static).update(self._block())
try:
self.get_child_by_type(Static).update(self._block())
except NoMatches:
pass

def compose(self) -> ComposeResult:
yield Static(
Expand Down
Loading