Feature idea: Setting "id" and "class" tag for Streamlit elements

As far as I am aware it is not possible to set the id or class tag for Streamlit elements that will be used when rendered to HTML.

Giving an id tag would allow to adress a desired element, e.g. a specific input element or whatever could be adressed for specific styling via CSS.

Hello!

There are two issues on this already: Give each element a unique HTML `id` · Issue #3888 · streamlit/streamlit · GitHub and Widget attribute to hook into for custom CSS · Issue #5437 · streamlit/streamlit · GitHub

Feel free to comment your use cases on both of those, ie what you are trying to build exactly!

Have a nice day,
Fanilo

2 Likes

Oh, I see, sorry for double posting on this.

Best regards
Dirk

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.