codeforgso / GoVote

Local voter registration and election candidate application.
http://govotegso.org/
GNU General Public License v3.0
24 stars 46 forks source link

changed button to submit type and moved handler to form #173

Closed zenlex closed 4 years ago

zenlex commented 4 years ago

Description

Changed 'search' button to type = submit Removed onClick handler from 'search' button Assigned onSubmit={submitHandler} to

element instead. Tested locally and it works

Related Issue

https://github.com/codeforgso/GoVote/issues/162

Motivation and Context

Accessibility best practices and ease of usage.

How Has This Been Tested?

Tested in localhost on the link in the issue as well as the 'can I vote' instance of the form. Both work as expected.

Screenshots (if appropriate):

Checklist:

  • [x ] My code follows the code style of this project.
  • [ ] My change requires a change to the documentation.
  • [ ] I have updated the documentation accordingly.
  • [ ] I have read the CONTRIBUTING document.
  • [ ] I have added tests to cover my changes.
  • [ ] All new and existing tests passed.