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

Form: click on input group button should not show validations #737

Conversation

jelhan
Copy link
Contributor

@jelhan jelhan commented Jan 2, 2019

Before this change a click on an input group button triggered validation to be shown by default if bubbling of focus out event was not prevented.

Before this change a click on an input group button triggered validation to be
shown by default if bubbling of focus out event was not prevented.
@jelhan jelhan force-pushed the fix-validation-should-not-be-shown-after-click-on-input-group-button branch from 74bd13d to 4ef8d38 Compare January 3, 2019 11:03
isArray(this.get('doNotShowValidationForEventTargets')) &&
this.get('doNotShowValidationForEventTargets.length') > 0 &&
[...this.element.querySelectorAll(this.get('doNotShowValidationForEventTargets').join(','))]
.some((el) => el.contains(target))
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

An element contains itself. A little bit confusing but therefore we don't need to check el === target.

Copy link
Contributor

@simonihmig simonihmig left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@simonihmig simonihmig changed the title fix(Form): click on input group button should not show validations Form: click on input group button should not show validations Jan 9, 2019
@simonihmig simonihmig added the bug label Jan 9, 2019
@simonihmig simonihmig merged commit f744de9 into ember-bootstrap:master Jan 9, 2019
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