Skip to content

Commit 597a313

Browse files
shellscapescottgonzalez
authored andcommitted
Button: adding event.preventDefault. Fixes #5945 - Disabled buttons still allow clicks
1 parent c49dbe0 commit 597a313

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

ui/jquery.ui.button.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,7 @@ $.widget( "ui.button", {
9797
})
9898
.bind( "click.button", function( event ) {
9999
if ( options.disabled ) {
100+
event.preventDefault();
100101
event.stopImmediatePropagation();
101102
}
102103
});

0 commit comments

Comments
 (0)