ngx-mask icon indicating copy to clipboard operation
ngx-mask copied to clipboard

Dynamic Mask Issue

Open drafenous opened this issue 7 years ago • 3 comments

Hi everyone, I'm using by the first time this module, and i trying to make a dynamic mask change for brazilian phone.

In brazil, we have 2 phone numbers formats: Residential numbers: (00) 0000-0000 (area code) 4 digits - 4 digits. Mobile numbers: (00) 90000-0000 (area code) 5 digits - 4 digits.

How to make to change this mask format when user is typing?

Kind Regards, Drafenous.

drafenous avatar Jan 24 '19 13:01 drafenous

<input type="text" [mask]="currentMask" [formControl]="splitCtrl">

TS file currentMask = '00:00:00.00';

it changed the mask in code now

spelbreker avatar Feb 04 '19 17:02 spelbreker

@drafenous Did you get it working? Could you provide your solution?

mrmokwa avatar May 03 '19 14:05 mrmokwa

@drafenous Did you get it working? Could you provide your solution?

Hi @drafenous, look this: https://github.com/JsDaddy/ngx-mask/issues/271#issuecomment-492841525

thaylongs avatar May 15 '19 22:05 thaylongs