Hello! For my web application I created custom Lit component containing a number of vaadin-text-field items. For each of items I have to get input value and valid status. No problem to get string value but invalid value is always indefined. I’m confused because at the backend side this works as well and I could get both string value and invalid status in Java code. Below is a snippet of component code to explain my problm:
private renderDialog = () => html`
<vaadin-vertical-layout style="width: 300px">
<vaadin-icon slot="prefix" icon="vaadin:database"></vaadin-icon>
<label>Database properties:</label>
<vaadin-text-field
label="Schema name"
id="schemaName"
required
pattern="[a-zA-Z0-9]+"
style="width: 100%"
@input="${(e: Event) => {
var schemaField = (e.target as TextField);
console.log("schemaField.invalid == " + schemaField.invalid);
console.log("schemaField.value == " + schemaField.value);
}}"
></vaadin-text-field>
So in browser’s console I see the following result:
Have no idea how to get actual invalid status. Please help