Update my_pages/information_loss.py
Browse files- my_pages/information_loss.py +4 -13
my_pages/information_loss.py
CHANGED
|
@@ -1,7 +1,6 @@
|
|
| 1 |
import pandas as pd
|
| 2 |
import streamlit as st
|
| 3 |
from utils import go_to
|
| 4 |
-
from streamlit_modal import Modal
|
| 5 |
|
| 6 |
ALL_FEATURES = [
|
| 7 |
("Liquid Assets", "Liquid Assets", None),
|
|
@@ -78,21 +77,13 @@ def render():
|
|
| 78 |
st.session_state.show_message = (feature[2])
|
| 79 |
st.rerun()
|
| 80 |
|
| 81 |
-
modal = Modal("My Modal", key="my_modal")
|
| 82 |
if "show_message" in st.session_state:
|
| 83 |
del st.session_state.show_message
|
| 84 |
|
| 85 |
-
|
| 86 |
-
|
| 87 |
-
|
| 88 |
-
|
| 89 |
-
modal.open()
|
| 90 |
-
|
| 91 |
-
if modal.is_open():
|
| 92 |
-
with modal.container():
|
| 93 |
-
st.write("Here's the message!")
|
| 94 |
-
if st.button("OK"):
|
| 95 |
-
modal.close()
|
| 96 |
|
| 97 |
# st.markdown("---")
|
| 98 |
|
|
|
|
| 1 |
import pandas as pd
|
| 2 |
import streamlit as st
|
| 3 |
from utils import go_to
|
|
|
|
| 4 |
|
| 5 |
ALL_FEATURES = [
|
| 6 |
("Liquid Assets", "Liquid Assets", None),
|
|
|
|
| 77 |
st.session_state.show_message = (feature[2])
|
| 78 |
st.rerun()
|
| 79 |
|
|
|
|
| 80 |
if "show_message" in st.session_state:
|
| 81 |
del st.session_state.show_message
|
| 82 |
|
| 83 |
+
st.markdown(
|
| 84 |
+
f"<div style='text-align:center; color:#c0392b; font-size:20px; font-weight:bold; margin:14px 0;'>{st.session_state.show_message}</div>",
|
| 85 |
+
unsafe_allow_html=True,
|
| 86 |
+
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 87 |
|
| 88 |
# st.markdown("---")
|
| 89 |
|