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

fix(stark-ui): generic-search trigger search on enter #3459

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

mhenkens
Copy link
Contributor

@mhenkens mhenkens commented Sep 14, 2022

When press Enter key now the search is trigger

ISSUES CLOSED: #3116

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

[x] Bugfix
[ ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[ ] Documentation content changes
[ ] Other... Please describe:

What is the current behavior?

Issue Number: #3116

What is the new behavior?

When press the Enter key, the form is sbmitted.

Does this PR introduce a breaking change?

[X] Yes
[] No

The search form search component should implement the new property submitEvent.

In the component template add (ngSubmit)="submitEvent.next()" attribute to the <form>

inside the <form> add
<button [hidden]="true" type="submit"></button>

see the showcase adaptation

Other information

@coveralls
Copy link

coveralls commented Sep 14, 2022

Coverage Status

Coverage decreased (-0.04%) to 88.125% when pulling 16f85f6 on mhenkens:bugfix/3116 into cece193 on NationalBankBelgium:master.

When press Enter key now the search is trigger

Braking Change:

The Components implementing
`StarkSearchFormComponent` must implement `submitEvent`
In the component template in the <form > tag
`(ngSubmit)="submitEvent.next()" and add `<button [hidden]="true" type="submit"></button>`

ISSUES CLOSED: NationalBankBelgium#3116
@mhenkens mhenkens force-pushed the bugfix/3116 branch 2 times, most recently from bff1817 to 5a60f11 Compare September 19, 2022 08:15
When press Enter key now the search is trigger
Braking Change:
The Components
implementing
`StarkSearchFormComponent` must implement `submitEvent`
In the component template in
the <form > tag
`(ngSubmit)="submitEvent.next()" and add `<button [hidden]="true"
type="submit"></button>`
ISSUES CLOSED: NationalBankBelgium#3116
@sonarcloud
Copy link

sonarcloud bot commented Sep 19, 2022

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

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

Successfully merging this pull request may close these issues.

ui: generic-search - conflict with ngxFormErrors + form not submitted when press Enter key
2 participants