Update app.py
Browse files
app.py
CHANGED
|
@@ -20,6 +20,8 @@ def generate(prompt):
|
|
| 20 |
with gr.Blocks() as demo:
|
| 21 |
image = gr.Image()
|
| 22 |
prompt = gr.Textbox(max_lines=1)
|
|
|
|
| 23 |
prompt.submit(generate, [prompt], [image])
|
|
|
|
| 24 |
|
| 25 |
demo.launch()
|
|
|
|
| 20 |
with gr.Blocks() as demo:
|
| 21 |
image = gr.Image()
|
| 22 |
prompt = gr.Textbox(max_lines=1)
|
| 23 |
+
button = gr.Button("Chain")
|
| 24 |
prompt.submit(generate, [prompt], [image])
|
| 25 |
+
button.click(lambda x:x+x, button, button).then(generate, [prompt], [image])
|
| 26 |
|
| 27 |
demo.launch()
|