Skip to content

Commit cf2301d

Browse files
committed
docstrings
1 parent 202f216 commit cf2301d

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

src/textual/app.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -837,6 +837,7 @@ def __init_subclass__(cls, *args, **kwargs) -> None:
837837
return super().__init_subclass__(*args, **kwargs)
838838

839839
def _get_dom_base(self) -> DOMNode:
840+
"""When querying from the app, we want to query the default screen."""
840841
return self.default_screen
841842

842843
def validate_title(self, title: Any) -> str:

src/textual/dom.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -238,6 +238,9 @@ def __init__(
238238
def _get_dom_base(self) -> DOMNode:
239239
"""Get the DOM base node (typically self).
240240
241+
All DOM queries on this node will use the return value as the root node.
242+
This method allows the App to query the default screen, and not the active screen.
243+
241244
Returns:
242245
DOMNode.
243246
"""

0 commit comments

Comments
 (0)