Update docs/examples/events/prevent.py

Co-authored-by: Rodrigo Girão Serrão <5621605+rodrigogiraoserrao@users.noreply.github.com>
This commit is contained in:
Will McGugan
2023-02-24 12:02:46 +00:00
committed by GitHub
parent 0999114811
commit 217956bbdf

View File

@@ -13,7 +13,7 @@ class PreventApp(App):
def on_button_pressed(self) -> None:
"""Clear the text input."""
input = self.query_one(Input)
with input.prevent(Input.Changed): # (1)
with input.prevent(Input.Changed): # (1)!
input.value = ""
def on_input_changed(self) -> None: