v-mask
v-mask copied to clipboard
Mask characters visible on empty field
I have a mask for a US phone number, "(###) ###-####", but the field is also used alternately for an email address, which has no mask. There is a drop-down for communication preference that controls this. When you change preferences, I blank out the field, and set the mask as appropriate. My problem now is that when I programmatically set the mask and blank the field, the text box on-screen says "(". If I manually clear the field, then the input's placeholder text shows like it should, but when I clear it programmatically, I always get a lone Parenthesis, as if the mask is filling that part in for me.