Skip to main content

Streamlit Styling Rules

Include the following file .streamlit/config.toml in every Streamlit app:

[theme]
primaryColor="#0C66E4"
backgroundColor="#FFFFFF"
secondaryBackgroundColor="#F7F8F9"
textColor="#091E42"
font="sans serif"

[browser]
gatherUsageStats=false

This will ensure the correct font and colors are used, aligned with those in use by Octostar.

Furthermore, include the following Streamlit function to be executed as the first Streamlit command, ONCE PER PAGE:

import streamlit as st
st.set_page_config(layout="wide")

The command can be customized as needed.

Finally, this other utility function (usually at the beginning of the streamlit loop() function) should be called:

hide_streamlit_header()

Which will hide the default header used by streamlit, replacing it with white space (this gives the app a cleaner appearance)