Spaces:
Paused
Paused
Add 3in logo file and aggressively fix desktop centering
Browse files- Add 3in par-ity project horizontal logo.png to repository
- Apply aggressive flexbox centering to all containers
- Remove all Streamlit default top padding and margins
- Force center alignment on element containers and blocks
- Reduce container padding-top to 0.5rem for minimal spacing
- Ensure logo is perfectly centered on desktop and mobile
app/3in par-ity project horizontal logo.png
ADDED
|
Git LFS Details
|
app/streamlit_app.py
CHANGED
|
@@ -647,8 +647,9 @@ def main():
|
|
| 647 |
|
| 648 |
/* Remove all default Streamlit spacing around logo */
|
| 649 |
.main .block-container {
|
| 650 |
-
padding-top:
|
| 651 |
padding-bottom: 0rem !important;
|
|
|
|
| 652 |
}
|
| 653 |
|
| 654 |
/* Eliminate column spacing */
|
|
@@ -679,6 +680,29 @@ def main():
|
|
| 679 |
margin-top: 0 !important;
|
| 680 |
}
|
| 681 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 682 |
|
| 683 |
|
| 684 |
|
|
@@ -757,7 +781,7 @@ def main():
|
|
| 757 |
""", unsafe_allow_html=True)
|
| 758 |
|
| 759 |
# Centered logo at the top - minimal spacing
|
| 760 |
-
st.markdown('<div style="text-align: center; width: 100%;">', unsafe_allow_html=True)
|
| 761 |
try:
|
| 762 |
# Try multiple possible paths for the logo file
|
| 763 |
logo_paths = [
|
|
|
|
| 647 |
|
| 648 |
/* Remove all default Streamlit spacing around logo */
|
| 649 |
.main .block-container {
|
| 650 |
+
padding-top: 0.5rem !important;
|
| 651 |
padding-bottom: 0rem !important;
|
| 652 |
+
max-width: 100% !important;
|
| 653 |
}
|
| 654 |
|
| 655 |
/* Eliminate column spacing */
|
|
|
|
| 680 |
margin-top: 0 !important;
|
| 681 |
}
|
| 682 |
|
| 683 |
+
/* Force center alignment for all containers */
|
| 684 |
+
.element-container, .stVerticalBlock, .stHorizontalBlock {
|
| 685 |
+
display: flex !important;
|
| 686 |
+
justify-content: center !important;
|
| 687 |
+
align-items: center !important;
|
| 688 |
+
text-align: center !important;
|
| 689 |
+
width: 100% !important;
|
| 690 |
+
}
|
| 691 |
+
|
| 692 |
+
/* Remove Streamlit's default top padding entirely */
|
| 693 |
+
.appview-container .main .block-container {
|
| 694 |
+
padding-top: 0 !important;
|
| 695 |
+
margin-top: 0 !important;
|
| 696 |
+
}
|
| 697 |
+
|
| 698 |
+
/* Ensure the entire app container centers content */
|
| 699 |
+
.main {
|
| 700 |
+
display: flex !important;
|
| 701 |
+
flex-direction: column !important;
|
| 702 |
+
align-items: center !important;
|
| 703 |
+
justify-content: flex-start !important;
|
| 704 |
+
}
|
| 705 |
+
|
| 706 |
|
| 707 |
|
| 708 |
|
|
|
|
| 781 |
""", unsafe_allow_html=True)
|
| 782 |
|
| 783 |
# Centered logo at the top - minimal spacing
|
| 784 |
+
st.markdown('<div style="text-align: center; width: 100%; margin: 0; padding: 0; display: flex; justify-content: center; align-items: center;">', unsafe_allow_html=True)
|
| 785 |
try:
|
| 786 |
# Try multiple possible paths for the logo file
|
| 787 |
logo_paths = [
|