Update app.py
Browse files
app.py
CHANGED
|
@@ -7,8 +7,9 @@ def update_options(selected_option):
|
|
| 7 |
# new_options = 'Something '+ selected_option
|
| 8 |
new_options = [selected_option + str(x) for x in range(1, 4)]
|
| 9 |
print(new_options)
|
| 10 |
-
DROPDOWN.update(choices=new_options)
|
| 11 |
# return new_options[0] # Return current selection to persist it in the first dropdown
|
|
|
|
| 12 |
|
| 13 |
with gr.Blocks() as interface:
|
| 14 |
dropdown = gr.Dropdown(choices=["Anna", "Christine", "Phoebe"])
|
|
|
|
| 7 |
# new_options = 'Something '+ selected_option
|
| 8 |
new_options = [selected_option + str(x) for x in range(1, 4)]
|
| 9 |
print(new_options)
|
| 10 |
+
# DROPDOWN.update(choices=new_options)
|
| 11 |
# return new_options[0] # Return current selection to persist it in the first dropdown
|
| 12 |
+
return gr.Dropdown(choices=new_options, interactive=True)
|
| 13 |
|
| 14 |
with gr.Blocks() as interface:
|
| 15 |
dropdown = gr.Dropdown(choices=["Anna", "Christine", "Phoebe"])
|