[Button] disabled props not working with Reference
See original GitHub issue- The issue is present in the latest release.
- I have searched the issues of this repository and believe that this is not a duplicate.
Current Behavior 😯
buttonRef.current.disabled = true; not disabling button
Expected Behavior 🤔
buttonRef.current.disabled = true; should disable button
Steps to Reproduce 🕹
https://codesandbox.io/s/material-ui-issue-forked-gn2qt?file=/src/Demo.js:181-215
Context 🔦
Your Environment 🌎
`npx @material-ui/envinfo`
Don't forget to mention which browser you used.
Output from `npx @material-ui/envinfo` goes here.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:2
- Comments:10 (4 by maintainers)
Top Results From Across the Web
JQuery prop function does not work to disabled a button
I'm using JQuery function "prop" to change the state of a button to disabled for a while, when finish de process it usign...
Read more >Button is not getting disable if adding disable attribute through ...
Steps: create button component using material-ui; create ref and pass it to button; pass that reference into any other component (B); In ...
Read more >Binding Functions and Enable/Disable State in HTML Buttons ...
In your component's constructor, go ahead and define the isDisabled state with an initial value of false . This tells the user that...
Read more >The Button element - HTML: HyperText Markup Language
If the button is a submit button, this Boolean attribute specifies that the form is not to be validated when it is submitted....
Read more >Disable button in jQuery [With examples] - Alvaro Trigo
Select the button you want to disable. Use the jQuery prop method. Set the disabled property to true. The prop method admits two...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@Frekansapp Actually, the issue I recall might have been on another component. I have run a deep search in the history and can’t find anything on the button. In all these years a little level of request for it, this IMHO signal that it something we should ignore. Other perspectives, welcome.
@Frekansapp I am also able to reproduce the issue. Looks like the click behaviour is not associated with the button.