Hello,
I want to have round borders in my option_menu() component. Any idea how to do this? This is as far as I’ve been able to get, I can see the round border but the color of whatever is behind the option_menu() component is white by default and ideally it should be blue like the rest of the sidebar:
BONUS help: Can I change the color of the title’s icon to say, white, so it doesn’t show?
Here the code:
# Create a sidebar with options
with st.sidebar:
menu = option_menu(
menu_title="This is the title",
menu_icon="bi-box",
options=[
"Business",
"Model",
"Optimization",
"Media simulator",
"Business forecast",
],
icons=[
"briefcase",
"cpu",
"bar-chart",
"sliders",
"graph-up-arrow",
],
default_index=0,
orientation="vertical",
styles={
"container": {
"padding": "10px 0px",
"background-color": "#ffffff",
"margin": "0px auto",
"border": "1px solid #000000",
"border-radius": "20px",
},
"icon": {
"color": "#0069b4",
"font-size": "16px"
},
"nav-link": {
"font-size": "16px",
"text-align": "left",
"margin": "10px",
"--hover-color": "#B3D3F0"
},
"nav-link-selected": {
"background-color": "#0069b4",
"font-size": "16px",
},
}
)
I’ve tried all kinds of things, including using stylable containers, markdown, inspecting different divs, etc… no luck…
Hopefully someone has a solution…
Thank you!