Spaces:
Paused
Paused
Highlight wins and loses
Browse files
server.py
CHANGED
|
@@ -222,7 +222,9 @@ class LeaderboardServer:
|
|
| 222 |
for c in df_css:
|
| 223 |
for i in range(len(df_css.index)):
|
| 224 |
if x[c].iloc[i] == True:
|
| 225 |
-
df_css[c].iloc[i] = 'background-color:
|
|
|
|
|
|
|
| 226 |
else:
|
| 227 |
df_css[c].iloc[i] = ''
|
| 228 |
return df_css
|
|
|
|
| 222 |
for c in df_css:
|
| 223 |
for i in range(len(df_css.index)):
|
| 224 |
if x[c].iloc[i] == True:
|
| 225 |
+
df_css[c].iloc[i] = 'background-color: rgba(0, 255, 0, 0.3);'
|
| 226 |
+
elif x[c].iloc[i] == False:
|
| 227 |
+
df_css[c].iloc[i] = 'background-color: rgba(255, 0, 0, 0.3);'
|
| 228 |
else:
|
| 229 |
df_css[c].iloc[i] = ''
|
| 230 |
return df_css
|