Browse Source

improve the await button clicked demo in docs

Rodja Trappe 2 years ago
parent
commit
aacf7d9dc2
1 changed files with 7 additions and 2 deletions
  1. 7 2
      website/more_documentation/button_documentation.py

+ 7 - 2
website/more_documentation/button_documentation.py

@@ -14,5 +14,10 @@ def more() -> None:
     async def await_button_click() -> None:
         # @ui.page('/')
         # async def index():
-            await ui.button('What comes next?').clicked()
-            ui.label('Bam! This is the future!')
+            b = ui.button('Step')
+            await b.clicked()
+            ui.label('One')
+            await b.clicked()
+            ui.label('Two')
+            await b.clicked()
+            ui.label('Three')