web-components
web-components copied to clipboard
[text-field] invalid event not fired, validity and validationMessage not available
I'm trying to use client side validation with vaadin-text-field. When calling .checkValidity() the state is reported correctly (true/false), but both .validity and .validationMessage are not available on vaadin-text-field even though they are correctly set on the native input element. Also the "invalid" event is not fired. It would be nice if these methods would be exposed on vaadin-text-field according to the spec: https://developer.mozilla.org/en-US/docs/Web/API/Constraint_validation
Also a reportValidity() would be great to be able to validate and show validation messages programmtically.