Spaces:
Running
Running
import gradio as gr | |
with gr.Blocks() as demo: | |
t1 = gr.Label("Hello world!") | |
btn = gr.Button("Click me") | |
t2 = gr.Label("Hello world!", visible=False) | |
def update(): | |
return "abc", gr.update(visible=True) | |
btn.click(update, inputs=[], outputs=[t2, t2]) | |
# %% | |
demo.launch() |