You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Non-Firefox browsers dispatch "click" on descendants of <button>, which breaks
the submitHandler logic that adds a hidden field with the name and value of the
submit button (since it is not included in the submission if it did not
initiate the submission, which might be the case when using form.submit in
submitHandler and returning false). submitButton is instead a descendant of
<button> and the hidden field does not compensate for the lack of an actual
submit button.
This would fix crbug.com/668524 and make submitButton an actual button.
* Added HTML for button with descendants test
For testing that clicking on descendants of a button element still keeps the button element as the submit button.
* Added a test for button with descendants support
For testing that clicking on descendants of a button element still
keeps the button element as the submit button.
* Removed an extraneous submission from the test
Accidental copy-paste.
* Fixed some style warning
Forgot to wrap the parenthesized value with spaces.
* Fixed a style warning
Forgot to wrap a parenthesized value with spaces.
* Fixed a style warning
Forgot to add a blank line above a comment.
* Fixed the button with descendants test
Replaced a complex event initiation with a basic click().
* Fixed a style warning
Removed extraneous trailing spaces.
* Fixed some style warnings
Removed two unused variables.
* Fixed a submitButton regression
Instead of returning a DOM element, a jQuery element was returned.
Changed to return the original element in the target is already a button case.
* Simplified the button with descendants support
Instead of looking for the parent or ancestor of the target,
just used the currentTarget property.
* Added another test
Devised by @Arkni.
0 commit comments