File size: 338 Bytes
9c90079
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
import gradio as gr

with gr.Blocks() as demo:
    text_count = gr.Slider(1, 10, step=1, label="Textbox Count")

    @gr.render(inputs=[text_count], triggers=[text_count.change])
    def render_count(count):
        for i in range(count):
            gr.Textbox(key=i)

    gr.Button("Merge")

if __name__ == "__main__":
    demo.launch()