Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -205,62 +205,49 @@ def create_leaderboard_ui():
|
|
205 |
}}
|
206 |
.leaderboard-table td {{
|
207 |
padding: 12px 14px;
|
208 |
-
border-bottom: 1px solid #
|
|
|
|
|
209 |
}}
|
210 |
-
.leaderboard-table tr:
|
211 |
-
background-color: #
|
212 |
-
}}
|
213 |
-
.leaderboard-table tr:nth-child(odd) {{
|
214 |
-
background-color: white;
|
215 |
-
}}
|
216 |
-
.leaderboard-table tr:hover {{
|
217 |
-
background-color: #e7f5ff;
|
218 |
-
}}
|
219 |
-
.leaderboard-table tr:nth-child(1) {{
|
220 |
-
background-color: #fff7e6;
|
221 |
-
}}
|
222 |
-
.leaderboard-table tr:nth-child(2) {{
|
223 |
-
background-color: #f8f9fa;
|
224 |
-
}}
|
225 |
-
.leaderboard-table tr:nth-child(3) {{
|
226 |
-
background-color: #fff5f5;
|
227 |
}}
|
228 |
.leaderboard-table tr:nth-child(1) td:first-child {{
|
229 |
background-color: #ffd700;
|
230 |
color: #333;
|
231 |
font-weight: bold;
|
232 |
text-align: center;
|
233 |
-
border-right: 1px solid #
|
234 |
}}
|
235 |
.leaderboard-table tr:nth-child(2) td:first-child {{
|
236 |
background-color: #c0c0c0;
|
237 |
color: #333;
|
238 |
font-weight: bold;
|
239 |
text-align: center;
|
240 |
-
border-right: 1px solid #
|
241 |
}}
|
242 |
.leaderboard-table tr:nth-child(3) td:first-child {{
|
243 |
background-color: #cd7f32;
|
244 |
color: #333;
|
245 |
font-weight: bold;
|
246 |
text-align: center;
|
247 |
-
border-right: 1px solid #
|
248 |
}}
|
249 |
.leaderboard-table tr:nth-child(1) td:nth-child(2) {{
|
250 |
font-weight: bold;
|
251 |
-
color: #
|
252 |
}}
|
253 |
.leaderboard-table tr:nth-child(2) td:nth-child(2) {{
|
254 |
font-weight: bold;
|
255 |
-
color: #
|
256 |
}}
|
257 |
.leaderboard-table tr:nth-child(3) td:nth-child(2) {{
|
258 |
font-weight: bold;
|
259 |
-
color: #
|
260 |
}}
|
261 |
</style>
|
262 |
{df_html}
|
263 |
-
<p><small>Note: This leaderboard shows user contributions to the BLEND-ES project across all countries.</small></p>
|
264 |
</div>
|
265 |
"""
|
266 |
return styled_html
|
@@ -271,11 +258,9 @@ def refresh_data():
|
|
271 |
last_update_time = 0
|
272 |
return create_leaderboard_ui()
|
273 |
|
274 |
-
with gr.Blocks(theme=gr.themes.
|
275 |
with gr.Column(scale=1):
|
276 |
-
gr.Markdown("""
|
277 |
-
# 🏆 Hackaton Leaderboard
|
278 |
-
""")
|
279 |
|
280 |
leaderboard_html = gr.HTML(create_leaderboard_ui)
|
281 |
|
|
|
205 |
}}
|
206 |
.leaderboard-table td {{
|
207 |
padding: 12px 14px;
|
208 |
+
border-bottom: 1px solid #333;
|
209 |
+
background-color: #222;
|
210 |
+
color: #fff;
|
211 |
}}
|
212 |
+
.leaderboard-table tr:hover td {{
|
213 |
+
background-color: #2a2a3a;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
214 |
}}
|
215 |
.leaderboard-table tr:nth-child(1) td:first-child {{
|
216 |
background-color: #ffd700;
|
217 |
color: #333;
|
218 |
font-weight: bold;
|
219 |
text-align: center;
|
220 |
+
border-right: 1px solid #333;
|
221 |
}}
|
222 |
.leaderboard-table tr:nth-child(2) td:first-child {{
|
223 |
background-color: #c0c0c0;
|
224 |
color: #333;
|
225 |
font-weight: bold;
|
226 |
text-align: center;
|
227 |
+
border-right: 1px solid #333;
|
228 |
}}
|
229 |
.leaderboard-table tr:nth-child(3) td:first-child {{
|
230 |
background-color: #cd7f32;
|
231 |
color: #333;
|
232 |
font-weight: bold;
|
233 |
text-align: center;
|
234 |
+
border-right: 1px solid #333;
|
235 |
}}
|
236 |
.leaderboard-table tr:nth-child(1) td:nth-child(2) {{
|
237 |
font-weight: bold;
|
238 |
+
color: #ffd700;
|
239 |
}}
|
240 |
.leaderboard-table tr:nth-child(2) td:nth-child(2) {{
|
241 |
font-weight: bold;
|
242 |
+
color: #c0c0c0;
|
243 |
}}
|
244 |
.leaderboard-table tr:nth-child(3) td:nth-child(2) {{
|
245 |
font-weight: bold;
|
246 |
+
color: #cd7f32;
|
247 |
}}
|
248 |
</style>
|
249 |
{df_html}
|
250 |
+
<p style="color: #ccc;"><small>Note: This leaderboard shows user contributions to the BLEND-ES project across all countries.</small></p>
|
251 |
</div>
|
252 |
"""
|
253 |
return styled_html
|
|
|
258 |
last_update_time = 0
|
259 |
return create_leaderboard_ui()
|
260 |
|
261 |
+
with gr.Blocks(theme=gr.themes.Default()) as demo:
|
262 |
with gr.Column(scale=1):
|
263 |
+
gr.Markdown("""# 🏆 Hackaton Leaderboard""")
|
|
|
|
|
264 |
|
265 |
leaderboard_html = gr.HTML(create_leaderboard_ui)
|
266 |
|