@@ -38,6 +38,9 @@ def on_mount(self) -> None:
3838 # self.query_one("#output", RichLog).write("Screen started")
3939 ```
4040
41+ Args:
42+ selector: A TCSS selector, e.g. "#mywidget". Or a widget type, i.e. `Input`.
43+ expect_type: The type of the expected widget, e.g. `Input`, if the first argument is a selector.
4144
4245 """
4346
@@ -46,6 +49,11 @@ def on_mount(self) -> None:
4649
4750 @overload
4851 def __init__ (self , selector : str ) -> None :
52+ """
53+
54+ Args:
55+ selector: A TCSS selector, e.g. "#mywidget"
56+ """
4957 self .selector = selector
5058 self .expect_type = Widget
5159
@@ -103,7 +111,7 @@ class child_by_id(Generic[QueryType]):
103111 """Create a child_by_id property, which returns the child with the given ID.
104112
105113 This is similar using [query_one][textual.getters.query_one] with an id selector, except that
106- only the immediate children are considered. It is also more efficient, as it doesn't need to search the DOM.
114+ only the immediate children are considered. It is also more efficient as it doesn't need to search the DOM.
107115
108116
109117 Example:
@@ -122,6 +130,9 @@ def on_mount(self) -> None:
122130 self.output_log.write("Screen started")
123131 ```
124132
133+ Args:
134+ child_id: The `id` of the widget to get (not a selector).
135+ expect_type: The type of the expected widget, e.g. `Input`.
125136
126137 """
127138
0 commit comments