I have a function that checks if a field is less than 3 when giving focus (click) on input Email
.
In short:
If CPF and RG is less than 3, it displays label[for="label-custom-field2"]
and label[for="label-custom-field3
If Only RG is less than 3, it displays label[for="label-custom-field3"]
and hides label[for="label-custom-field2
.
If Only CPF is less than 3, it displays label[for="label-custom-field2"]
and hides label[for="label-custom-field3
.
But even though the RG is populated when focusing on the email field, label[for="label-custom-field3
is displayed.