How to configure input mask correctly