Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -91,9 +91,10 @@ def ui():
|
|
| 91 |
container = st.container()
|
| 92 |
|
| 93 |
with container:
|
| 94 |
-
|
| 95 |
-
|
| 96 |
-
|
|
|
|
| 97 |
if submit_button and audio_file:
|
| 98 |
output_file_path = "./output_audio.mp3"
|
| 99 |
save_uploaded_file_as_mp3(audio_file,output_file_path )
|
|
|
|
| 91 |
container = st.container()
|
| 92 |
|
| 93 |
with container:
|
| 94 |
+
with st.form(key='my_form', clear_on_submit=True)
|
| 95 |
+
audio_file = audiorecorder("Click to record", "Recording...")
|
| 96 |
+
audio_file=audio_file.tobytes()
|
| 97 |
+
submit_button = st.form_submit_button(label='Send')
|
| 98 |
if submit_button and audio_file:
|
| 99 |
output_file_path = "./output_audio.mp3"
|
| 100 |
save_uploaded_file_as_mp3(audio_file,output_file_path )
|