Spaces:
Runtime error
Runtime error
clean components value when switch (#8)
Browse files- clean components value when switch (db27f1665aae51a21cc7949d0528bf6c62a7d4aa)
Co-authored-by: Radamés Ajna <[email protected]>
app.py
CHANGED
@@ -34,9 +34,9 @@ examples = [['test.wav', "This is real time voice cloning on huggingface spaces"
|
|
34 |
|
35 |
def toggle(choice):
|
36 |
if choice == "mic":
|
37 |
-
return gr.update(visible=True), gr.update(visible=False)
|
38 |
else:
|
39 |
-
return gr.update(visible=False), gr.update(visible=True)
|
40 |
|
41 |
|
42 |
with gr.Blocks() as demo:
|
|
|
34 |
|
35 |
def toggle(choice):
|
36 |
if choice == "mic":
|
37 |
+
return gr.update(visible=True, value=None), gr.update(visible=False, value=None)
|
38 |
else:
|
39 |
+
return gr.update(visible=False, value=None), gr.update(visible=True, value=None)
|
40 |
|
41 |
|
42 |
with gr.Blocks() as demo:
|