I am trying to change color of sidebar background and also of the text of all the content in it including page navigations.
-
Referring this streamlit link I was able to change background color by theme settings
secondaryBackgroundColorbut this doesn’t provide changing any text color options only for sidebar so if background is black then text there is not visible. -
Referring this streamlit link2 I was able to change
background colorto black and also thecontent colorto white but it didn’t change the page navigation color. -
I have tried below code and they too didn’t change the page navigation colors.
st.markdown( """
<style>
[data-testid="stSidebarContent"] {
color: white;
background-color: #111;
}
</style>
""", unsafe_allow_html=True)
st.markdown( """
<style>
[data-testid="stSidebarNav"] {
color: white;
background-color: #111;
}
</style>
""", unsafe_allow_html=True)
below is the snapshot:
Please suggest how to change the color of all the elements in the sidebar including Page Navigations and Subheaders.
Thanks !!

