Closed blackfalcon closed 1 week ago
I don't think this is going to be CC specific... I suspect that the issue has to do with the logic for when we remove the error state generally in auro-input. This will require more debugging but I am willing to gamble that the issue is in that part of the logic.
@jason-capsule42 it's not CC specific.
For the second issue, reference these lines. It appears that when using only the
formatLength
value, this breaks the clearing function. This also means that the clearing function is not working on any sequence, just used34
as an example.
The second bug listed in this issue is no longer valid. This can be validated by following the steps shown above.
Needs validation in the Input Beta Branch
Neither of these bugs are no longer valid, as they have been tested and no longer exist. This issue will not be closed.
Describe the bug
This issue will report two bugs within the same area of functionality.
1
or a2
. When starting with a1
or a2
the validation will consider the card correct after only 2 numbers are entered.To Reproduce issue 1
Steps to reproduce the behavior:
1
1
To Reproduce issue 2
3434 44444
x
Expected behavior
All credit cards should validate at the correct minimum numbers required. All credit card values should be cleared by clicking the
x
.Additional context
With some investigation, the first issue has to do with this section of code. By only using the
formatMinLength
value, the validation sequence is not attributed to the DOM correctly.https://github.com/AlaskaAirlines/auro-input/blob/0ebc7192a8f88c09f9049cf4f2576848b0aa8b6b/src/base-input.js#L699-L712
For the second issue, reference these lines. It appears that when using only the
formatLength
value, this breaks the clearing function. This also means that the clearing function is not working on any sequence, just used34
as an example.https://github.com/AlaskaAirlines/auro-input/blob/0ebc7192a8f88c09f9049cf4f2576848b0aa8b6b/src/base-input.js#L720-L726