Is it possible to combine different widgets?

Thanks for this amazing tool, I am wondering whether it’s possible to combine different widgets.
For instance, a normal radio button is followed by some text by defining"please select", ("choice 1", "choice 2"))
Is it possible to display another widget such as audio or image after the text prompt? which looks like"please select", ("choice 1: {insert image here}", "choice 2: {inseret image here"))

Thanks a lot!

Hi @wsstriving, welcome to the Streamlit community!

I’m not sure what you mean…are you trying to embed an image inside the radio button choices?


Hi, thanks for the reply. Yes, I mean embedding another widget into the radio button choices. Image can be an example, the image can be the extra information to better describe the choices.

I see…no, it’s not really possible to embed them like that. An interesting idea though, and possible to make into a Streamlit Component if there’s a JavaScript library that already exists that does that.