Skip to content
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

Prevent clicks from being called on disabled buttons (hack for angular bug) #16

Open
melcher opened this issue Jan 22, 2015 · 1 comment

Comments

@melcher
Copy link
Member

melcher commented Jan 22, 2015

There's a bug/feature in angular where calling .click() or .trigger('click') on a disabled button, which would normally do nothing in a regular browser/html situation, actually propagates the click event through the stack. This means that, in our testing, clicking "Save" on a disabled save button will totally do the save action. Who knew?
Seems like behave could step in here and not click on a disabled button/link (or maybe error?). The reproducible fiddle for angular is here:

http://jsfiddle.net/e78xjvLu/3/ (angular 1.2.28). This does not appear to be an issue in 1.21

@melcher
Copy link
Member Author

melcher commented Jan 22, 2015

Filed at angular/angular#451

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant