Update app.py
Browse files
app.py
CHANGED
@@ -3,7 +3,7 @@ import streamlit as st
|
|
3 |
import time
|
4 |
|
5 |
# Inspect the header element, go to the "Computed" tab in styles, and find its height.
|
6 |
-
HEADER_HEIGHT = "
|
7 |
HEADER_SELECTOR = 'header[data-testid="stHeader"]'
|
8 |
|
9 |
# ---- SELECTOR FOR THE MAIN CONTENT AREA THAT NEEDS PADDING ----
|
@@ -43,10 +43,10 @@ custom_css = f"""
|
|
43 |
/* Optional: If your app is set to wide mode and the header isn't spanning full width */
|
44 |
/* This might be needed if the sticky positioning affects its width calculation. */
|
45 |
/*
|
46 |
-
{HEADER_SELECTOR} {{
|
47 |
-
|
48 |
-
}}
|
49 |
-
|
50 |
</style>
|
51 |
"""
|
52 |
|
@@ -54,18 +54,12 @@ custom_css = f"""
|
|
54 |
st.markdown(custom_css, unsafe_allow_html=True)
|
55 |
|
56 |
# --- Your Streamlit App ---
|
57 |
-
|
58 |
-
st.title("SBS V2.0 mapper")
|
59 |
st.sidebar.header("SBS V2.0 mapper")
|
60 |
st.sidebar.write("work in progress.")
|
61 |
st.sidebar.text("Demo by JA-RAD")
|
62 |
|
63 |
-
st.header("Main Content Section")
|
64 |
-
st.write(f"The header should be sticky. This content section has a top padding of approximately {HEADER_HEIGHT} to compensate for the header.")
|
65 |
-
st.info(f"Header Selector Used: `{HEADER_SELECTOR}`")
|
66 |
-
st.info(f"Main Content Selector Used: `{MAIN_CONTENT_SELECTOR}`")
|
67 |
-
|
68 |
-
|
69 |
# --- PAGE SETUP ---
|
70 |
type_text_page = st.Page(
|
71 |
page="pages/type_text.py",
|
|
|
3 |
import time
|
4 |
|
5 |
# Inspect the header element, go to the "Computed" tab in styles, and find its height.
|
6 |
+
HEADER_HEIGHT = "30px" # EXAMPLE: Adjust this (e.g., "56px", "4rem")
|
7 |
HEADER_SELECTOR = 'header[data-testid="stHeader"]'
|
8 |
|
9 |
# ---- SELECTOR FOR THE MAIN CONTENT AREA THAT NEEDS PADDING ----
|
|
|
43 |
/* Optional: If your app is set to wide mode and the header isn't spanning full width */
|
44 |
/* This might be needed if the sticky positioning affects its width calculation. */
|
45 |
/*
|
46 |
+
#{HEADER_SELECTOR} {{
|
47 |
+
# width: 100% !important;
|
48 |
+
#}}
|
49 |
+
#*/
|
50 |
</style>
|
51 |
"""
|
52 |
|
|
|
54 |
st.markdown(custom_css, unsafe_allow_html=True)
|
55 |
|
56 |
# --- Your Streamlit App ---
|
57 |
+
st.logo(image="images/menu_book_60dp_75FBFD.png")
|
58 |
+
#st.title("SBS V2.0 mapper")
|
59 |
st.sidebar.header("SBS V2.0 mapper")
|
60 |
st.sidebar.write("work in progress.")
|
61 |
st.sidebar.text("Demo by JA-RAD")
|
62 |
|
|
|
|
|
|
|
|
|
|
|
|
|
63 |
# --- PAGE SETUP ---
|
64 |
type_text_page = st.Page(
|
65 |
page="pages/type_text.py",
|