Update app.py
Browse files
app.py
CHANGED
|
@@ -216,9 +216,15 @@ def quiz_app():
|
|
| 216 |
background_color = "#292D34" # Dark background for dark mode
|
| 217 |
else:
|
| 218 |
background_color = "#FFF" # White background for light mode
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 219 |
|
| 220 |
st.metric(label=f"**Final Score**", value=f"{correct_count} out of {len(st.session_state.quiz_data)}", delta=f"{percentage_correct:.0f}%", delta_color="off")
|
| 221 |
-
style_metric_cards(border_left_color=border_color, background_color="DEFAULT_BACKGROUND_COLOR")
|
| 222 |
|
| 223 |
# st.markdown(f"### Final Score: {correct_count} out of {len(st.session_state.quiz_data)} correct ({percentage_correct:.2f}%)")
|
| 224 |
st.session_state.score = correct_count # Store score in session state
|
|
|
|
| 216 |
background_color = "#292D34" # Dark background for dark mode
|
| 217 |
else:
|
| 218 |
background_color = "#FFF" # White background for light mode
|
| 219 |
+
|
| 220 |
+
custom_css = f"""
|
| 221 |
+
.e1fexwmo1 st-emotion-cache-1ksdj5j ex0cdmw0 {{
|
| 222 |
+
display: none;
|
| 223 |
+
}}
|
| 224 |
+
"""
|
| 225 |
|
| 226 |
st.metric(label=f"**Final Score**", value=f"{correct_count} out of {len(st.session_state.quiz_data)}", delta=f"{percentage_correct:.0f}%", delta_color="off")
|
| 227 |
+
style_metric_cards(border_left_color=border_color, background_color="DEFAULT_BACKGROUND_COLOR", css=custom_css)
|
| 228 |
|
| 229 |
# st.markdown(f"### Final Score: {correct_count} out of {len(st.session_state.quiz_data)} correct ({percentage_correct:.2f}%)")
|
| 230 |
st.session_state.score = correct_count # Store score in session state
|