Dear all,
There are several posts asking how to hide the burger / spinner / “Made with Streamlit”, and the advise solution is to use the code below.
It works well when the user navigate through the app by clicking buttons. But When pressing ctrl+F5 or entering for the first time on the app, the decoration are not masked during the first page loading.
Is there a way to prevent decorations to appear at the first loading ?
> hide_streamlit_style = """
> <style>
> #MainMenu {visibility: hidden;}
> footer {visibility: hidden;}
> </style>
> """
>
> st.markdown(hide_streamlit_style, unsafe_allow_html=True)
>
> hide_decoration_bar_style = '''
> <style>
> header {visibility: hidden;}
> </style>
> '''
> st.markdown("""
> <style>
> .css-15zrgzn {display: none}
> .css-eczf16 {display: none}
> .css-jn99sy {display: none}
> </style>
> """, unsafe_allow_html=True)
> st.markdown(hide_decoration_bar_style, unsafe_allow_html=True)
> st.markdown(
> f'''
> <style>
> .sidebar .sidebar-content {{
> width: 375px;
> }}
> </style>
> ''',
> unsafe_allow_html=True
> )