JsDaddy / ngx-mask

Angular Plugin to make masks on form fields and html elements.
https://jsdaddy.github.io/ngx-mask
MIT License
1.15k stars 298 forks source link

Input marked dirty after updating to Angular 17 #1357

Closed patrickuhlmann closed 2 months ago

patrickuhlmann commented 5 months ago

When we updated from Angular 16 to Angular 17 (which included updating related libraries like ngx-mask), we faced a regression. A input field in a form was marked dirty right after initialisation. I created a StackBliz to reproduce the problem. Just click the button "Check dirty" and you will see as output that the input field using ngx-mask is dirty while the others are not dirty. All are assigned the same way.

I am not sure if this is related to a number of other issues that are already closed regarding wrong "dirty" behavior.

As a workaround we are currently using Version 16.4.2 of ngx-mask with Angular 17. This seems to work.

achapman009 commented 5 months ago

16.4.2

We are facing the same issue. Thank you for providing a version to fallback to in the meantime.

joelryan2k commented 5 months ago

I'm seeing this behavior when upgrading from ngx-mask 17.0.5 to 17.0.6

I forked the above stackblitz and just backed off to 17.0.5 and the input is not dirty

matviienko-danylo commented 4 months ago

Do you have an approximate time frame when this fix (1358): add trailing zero when mask="separator.1" and leadZero="true" will work with Angular 17 ?

HabooshHaddad commented 2 months ago

Hello any updates on this bug ?

andriikamaldinov1 commented 2 months ago

@HabooshHaddad @joelryan2k @achapman009 @patrickuhlmann Thanks for using Ngx-mask. Please update to latest version. It example all work as expected - https://stackblitz.com/edit/stackblitz-starters-2ws8jj?file=package.json

andriikamaldinov1 commented 2 months ago

@matviienko-danylo this request was merged with version 17.0.8