Repository navigation
fix(angular): min/max validator for ion-input type number - #27993
Merged
Merged
Conversation
|
|
sean-perkins
marked this pull request as ready for review
August 15, 2023 15:37
sean-perkins
requested review from
a team and
brandyscarney
and removed request for
a team
August 15, 2023 15:40
brandyscarney
approved these changes
Aug 18, 2023
brandyscarney
left a comment
Member
There was a problem hiding this comment.
This looks good! Optional: do we want to add a test for it being valid?
Contributor
Author
|
The controls are initially valid when the test form page renders, so I can absolutely update the existing tests to check if the control is valid before modifying the input to an invalid state 👍 |
Member
|
That was fast! Haha looks good once it passes. 👍 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issue number: Resolves #23480
What is the current behavior?
Angular's min/max validators do not work with
ion-input[type=number]. Using the built-in validators withion-inputwill not update the control status to invalid, reflect theng-invalidclass or report the correct errors.What is the new behavior?
IonicModulenow includes two additional directive declarations that extend Angular's built-in min/max validators and target theion-inputcomponent when usingtype="number".Does this introduce a breaking change?
Other information