Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -4,9 +4,11 @@ from TTS.api import TTS
|
|
4 |
css = """
|
5 |
#warning {background-color: #FFCCCB !important}
|
6 |
.feedback label textarea {height: auto !important;
|
7 |
-
font-size:
|
8 |
-
font-weight:
|
9 |
-
text-align: center !important
|
|
|
|
|
10 |
#alert {background-color: #fff !important}
|
11 |
"""
|
12 |
|
@@ -48,11 +50,12 @@ def toggle(choice):
|
|
48 |
return gr.update(visible=True, value=None), gr.update(visible=False, value=None)
|
49 |
else:
|
50 |
return gr.update(visible=False, value=None), gr.update(visible=True, value=None)
|
|
|
51 |
def change_color(text_input):
|
52 |
if len(text_input) == 0:
|
53 |
-
return gr.update(elem_id="warning")
|
54 |
else:
|
55 |
-
return gr.update(elem_id="alert")
|
56 |
|
57 |
with gr.Blocks(css=css) as demo:
|
58 |
with gr.Row():
|
|
|
4 |
css = """
|
5 |
#warning {background-color: #FFCCCB !important}
|
6 |
.feedback label textarea {height: auto !important;
|
7 |
+
font-size: 22px !important;
|
8 |
+
font-weight: 800 !important;
|
9 |
+
text-align: center !important;
|
10 |
+
color: #801313 !important;
|
11 |
+
padding: 0px !important}
|
12 |
#alert {background-color: #fff !important}
|
13 |
"""
|
14 |
|
|
|
50 |
return gr.update(visible=True, value=None), gr.update(visible=False, value=None)
|
51 |
else:
|
52 |
return gr.update(visible=False, value=None), gr.update(visible=True, value=None)
|
53 |
+
|
54 |
def change_color(text_input):
|
55 |
if len(text_input) == 0:
|
56 |
+
return gr.update(elem_id="warning", autofocus=True)
|
57 |
else:
|
58 |
+
return gr.update(elem_id="alert", autofocus=False)
|
59 |
|
60 |
with gr.Blocks(css=css) as demo:
|
61 |
with gr.Row():
|