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

SearchKit - Don't save on enter key #19643

Merged
merged 1 commit into from
Feb 23, 2021
Merged

Conversation

colemanw
Copy link
Member

Overview

In search kit, don't try to save when the user presses enter.

Before

Search saves when user presses enter.

After

Nothing happens when user presses enter.

Technical Details

Browsers automatically click the first <button type="submit"> they find when the user presses enter in a text field. So the fix was to make sure all buttons are type "button"

@civibot
Copy link

civibot bot commented Feb 21, 2021

(Standard links)

@civibot civibot bot added the master label Feb 21, 2021
@colemanw
Copy link
Member Author

@eileenmcnaughton doing search-on-enter caused problems with validation. This is at least better though.

@eileenmcnaughton
Copy link
Contributor

test this please

@colemanw colemanw merged commit d7c2db5 into civicrm:master Feb 23, 2021
@colemanw colemanw deleted the searchKitButtons branch February 23, 2021 18:42
@colemanw
Copy link
Member Author

colemanw commented Feb 23, 2021

@eileenmcnaughton I'll interpret that as approval cause I need this merged to prevent conflicts with my WIP :)
(and even if you wanted something different, this PR is simply fixing bad markup so it's still necessary)

@eileenmcnaughton
Copy link
Contributor

OK cool

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

Successfully merging this pull request may close these issues.

2 participants