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

Validates on init instead of input or change #41

Open
xelra opened this issue Dec 28, 2017 · 1 comment
Open

Validates on init instead of input or change #41

xelra opened this issue Dec 28, 2017 · 1 comment

Comments

@xelra
Copy link

xelra commented Dec 28, 2017

When adding a validator, gold-password-input validates immediately instead of after the first input or change event.

<gold-password-input
	auto-validate
	validator="ssn-validator">
</gold-password-input>

This leads to invalid input fields right from the start. I've put gold-password-input into an SSN Validator Codepen to illustrate the problem in comparison with a paper-input.
image
https://codepen.io/anon/pen/ypMYjv?editors=1010

@xelra xelra changed the title Validates on init instead of input Validates on init instead of input or change Dec 28, 2017
@xelra
Copy link
Author

xelra commented Dec 28, 2017

Actually, after testing some more, even after setting the validator to return true;, it starts off as invalid. So I think that it doesn't validate at all on init, but just start off as invalid.

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

No branches or pull requests

1 participant