Spaces:
Running
Running
Commit
·
587110e
1
Parent(s):
6ac3dec
Even better UI
Browse files- gradio_app.py +24 -15
gradio_app.py
CHANGED
@@ -3,7 +3,7 @@ from model.analyzer import analyze_content
|
|
3 |
import asyncio
|
4 |
import time
|
5 |
|
6 |
-
# Custom CSS for dark theme, animations, and
|
7 |
custom_css = """
|
8 |
.gradio-container {
|
9 |
background: #121212 !important;
|
@@ -24,20 +24,32 @@ custom_css = """
|
|
24 |
|
25 |
.treat-title h1 {
|
26 |
font-size: 5em;
|
27 |
-
color: #
|
28 |
margin-bottom: 10px;
|
29 |
font-weight: bold;
|
30 |
animation: fadeInText 1.5s ease-out;
|
31 |
}
|
32 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
33 |
.treat-title p {
|
34 |
font-size: 1.3em;
|
35 |
-
color: #
|
36 |
-
animation: fadeInText 1.5s ease-out
|
37 |
}
|
38 |
|
39 |
.highlight {
|
40 |
-
color: #
|
41 |
font-weight: bold;
|
42 |
}
|
43 |
|
@@ -62,11 +74,11 @@ custom_css = """
|
|
62 |
}
|
63 |
|
64 |
.gradio-textbox textarea:focus {
|
65 |
-
border-color: #
|
66 |
}
|
67 |
|
68 |
.gradio-button {
|
69 |
-
background-color: #
|
70 |
color: white !important;
|
71 |
border: none !important;
|
72 |
border-radius: 25px !important;
|
@@ -78,12 +90,12 @@ custom_css = """
|
|
78 |
|
79 |
.gradio-button:hover {
|
80 |
transform: scale(1.1) !important;
|
81 |
-
background-color: #
|
82 |
}
|
83 |
|
84 |
.gradio-button:active {
|
85 |
transform: scale(0.98) !important;
|
86 |
-
background-color: #
|
87 |
}
|
88 |
|
89 |
label {
|
@@ -108,7 +120,7 @@ label {
|
|
108 |
}
|
109 |
|
110 |
.footer p {
|
111 |
-
color: #
|
112 |
}
|
113 |
|
114 |
@keyframes slideInFromTop {
|
@@ -166,11 +178,8 @@ with gr.Blocks(css=custom_css, theme=gr.themes.Soft()) as iface:
|
|
166 |
gr.HTML("""
|
167 |
<div class="treat-title">
|
168 |
<h1>TREAT</h1>
|
169 |
-
<
|
170 |
-
|
171 |
-
<span class="highlight">E</span>njoyable and
|
172 |
-
<span class="highlight">A</span>ppropriate
|
173 |
-
<span class="highlight">T</span>elevision</p>
|
174 |
</div>
|
175 |
""")
|
176 |
|
|
|
3 |
import asyncio
|
4 |
import time
|
5 |
|
6 |
+
# Custom CSS for dark theme, animations, and new accent color
|
7 |
custom_css = """
|
8 |
.gradio-container {
|
9 |
background: #121212 !important;
|
|
|
24 |
|
25 |
.treat-title h1 {
|
26 |
font-size: 5em;
|
27 |
+
color: #4f46e5;
|
28 |
margin-bottom: 10px;
|
29 |
font-weight: bold;
|
30 |
animation: fadeInText 1.5s ease-out;
|
31 |
}
|
32 |
|
33 |
+
.treat-title span {
|
34 |
+
color: #fff;
|
35 |
+
}
|
36 |
+
|
37 |
+
.treat-title .web {
|
38 |
+
font-size: 0.4em;
|
39 |
+
color: #4f46e5;
|
40 |
+
margin-top: -15px;
|
41 |
+
display: block;
|
42 |
+
animation: fadeInText 1.5s ease-out 0.5s;
|
43 |
+
}
|
44 |
+
|
45 |
.treat-title p {
|
46 |
font-size: 1.3em;
|
47 |
+
color: #fff;
|
48 |
+
animation: fadeInText 1.5s ease-out 1s;
|
49 |
}
|
50 |
|
51 |
.highlight {
|
52 |
+
color: #4f46e5;
|
53 |
font-weight: bold;
|
54 |
}
|
55 |
|
|
|
74 |
}
|
75 |
|
76 |
.gradio-textbox textarea:focus {
|
77 |
+
border-color: #4f46e5 !important;
|
78 |
}
|
79 |
|
80 |
.gradio-button {
|
81 |
+
background-color: #4f46e5 !important;
|
82 |
color: white !important;
|
83 |
border: none !important;
|
84 |
border-radius: 25px !important;
|
|
|
90 |
|
91 |
.gradio-button:hover {
|
92 |
transform: scale(1.1) !important;
|
93 |
+
background-color: #3e38c2 !important;
|
94 |
}
|
95 |
|
96 |
.gradio-button:active {
|
97 |
transform: scale(0.98) !important;
|
98 |
+
background-color: #3530a8 !important;
|
99 |
}
|
100 |
|
101 |
label {
|
|
|
120 |
}
|
121 |
|
122 |
.footer p {
|
123 |
+
color: #4f46e5;
|
124 |
}
|
125 |
|
126 |
@keyframes slideInFromTop {
|
|
|
178 |
gr.HTML("""
|
179 |
<div class="treat-title">
|
180 |
<h1>TREAT</h1>
|
181 |
+
<span>Trigger Recognition for Enjoyable and Appropriate Television</span>
|
182 |
+
<div class="web">WEB</div>
|
|
|
|
|
|
|
183 |
</div>
|
184 |
""")
|
185 |
|