RobinHerbots / Inputmask

Input Mask plugin

Home Page:https://robinherbots.github.io/Inputmask/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Placeholder weird behavior

stsrki opened this issue · comments

We got this report from one of our users: Megabit/Blazorise#5560

I'm not sure if this is the correct behavior. I would assume that the placeholder would behave the same as for regular input, i.e., show a hint until the user starts to write value. But in this case, the placeholder becomes a part of the value.

Can you please clarify?

The behavior is correct. The placeholder is to pass a placeholder for the mask and not to be confused with the placeholder of the input. passing "" will fill the unfilled characters with "" (mask 99-99-99 => __-__-__), when passing a placeholder like "abcd" this wil be used to fill the unfilled characters. mask 99-99-99 => ab-cd-ab

See https://robinherbots.github.io/Inputmask/#/documentation#placeholder-1

Thanks for the clarification. It helps us to plan for the next steps.