Long story short, st.expander() gives me something like this:
… but what I really want is this (from the layout options post from a while ago):

I don’t dig the box. How do I remove the box!
Thanks!
Long story short, st.expander() gives me something like this:
… but what I really want is this (from the layout options post from a while ago):

I don’t dig the box. How do I remove the box!
Thanks!
Hi @Raihaan 
You can use a CSS selector in conjunction with st.markdown to hide the expander border. Here’s an example:
import streamlit as st
hide_expander_border = """
<style>
.st-bd {border-style: none;}
</style>
"""
if st.checkbox("Remove expander border"):
st.markdown(hide_expander_border, unsafe_allow_html=True)
with st.expander("Click to expand"):
st.header("Test")

Happy Streamlit-ing! 
Snehan
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.