I recently upgraded to 1.28.1 and now the st.dataframe has the download button on the top.
I have an application where I should not allow the user to do that.
How can it be hidden?
Will I need another CSS trick?
Nothing was mentioned on the Docs:
I recently upgraded to 1.28.1 and now the st.dataframe has the download button on the top.
I have an application where I should not allow the user to do that.
How can it be hidden?
Will I need another CSS trick?
Nothing was mentioned on the Docs:
How about if users just copy paste the table.
That is not my point here. What I don’t want is to “advertise” the download by showing a button every time he moves the mouse over.
For now I need to hide the button.
Also having this issue! would love if there was a way to disable it. Users currently can’t copy and paste from it so just need to have them not be able to download as well.
I have the same issue. I have created some code with my database being displayed as a dataframe for inspection. the last thing I want to do is to allow the user to either download it or copy paste it. (a simple enable copy / download true/false would do)
Yes this essential, when some new feature is added in streamlit, there should be always both enable and disable in APIs.
/* For Removing download icon on dataframe */
[data-testid="stElementToolbar"] {
display: none;
}
where do you add this (data-testid)? in a markdown block?
Facing similar issue.
Yes, add the following code snippet to the page that contains your dataframe:
st.markdown(
"""
<style>
[data-testid="stElementToolbar"] {
display: none;
}
</style>
""",
unsafe_allow_html=True
)
Thank you! This worked for me as well; I really want to hide the obvious “download” button. Thanks!
Is there any solution to hide search/download, without using unsafe_allow_html = True.
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.