New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I want to be able to disable a widget from my app script #862
Comments
I can see this appear two ways syntactically. foo = st.button("test", enabled = False) or foo = st.button("test")
foo.enabled = False |
That would be a most definitely wanted feature by many of us I think (myself included ;-) ) |
Very much interested in this feature too |
+1 |
Same here |
+1 |
1 similar comment
+1 |
Is there anyone working on this yet? |
I would definitely also be interested in this. The ability to disable a button as to lock a users initial choice. |
Also interested! |
Also very interested! |
+1. This is also very useful if you want to show some default options that can't be changed (e.g. you have 3 checkboxes and the first one should always be checked due to some other settings). |
+1 |
1 similar comment
+1 |
interested |
+1 |
12 similar comments
+1 |
+1 |
+1 |
+1 |
+1 |
+1 |
+1 |
+1 |
+1 |
+1 |
+1 |
+1 |
+1 |
1 similar comment
+1 |
+1 this would make more intutive UI possible |
+1 Wow this has been opened since 18th dec, it has gone unnoticed |
Also interested |
Just found this through Google again, so still +1 (+2?) 😆 |
|
I have done this by going through this approch:
hope it will help !!!!! |
+1 |
2 similar comments
+1 |
+1 |
how does this work? I can't disable a widget after creation. I want to disable or enable for example a checkbox based on another condition in my app! |
This was released already a while ago. Just pass a boolean value to the disabled = st.checkbox("Disable slider")
st.slider("My slider", disabled=disabled) |
This works beautifully! Can't believe such an easy solution is burried here, a lot of solution on SO are way too complicated for a simple thing to do here. |
Sometimes I want to show the user that a piece of UI exists, but is currently disabled until some condition is met. For example:
It would be useful if each widget function took an optional "enabled" flag.
The text was updated successfully, but these errors were encountered: