Closed guillermodelagala closed 1 year ago
Hey! Import FormsModule, and add [(ngModel)]="value" to your input, it should work just fine!
Hi! I have the same issue. And I have FormsModule imported & [(ngModule)] defined. There's an initialization issue that appears with the 13.1.10 update. It might be related to locale (German here). Stackblitz demo: https://stackblitz.com/edit/angular-opspqb?file=src/app/app.component.html We decided to migrate away from ngx-mask because of this.
Same for me, reproduces in my project. Since it's quite a critical issue, I'm considering moving away from ngx-mask as well.
Also, this seems to be a duplicate of https://github.com/JsDaddy/ngx-mask/issues/1042
Also, this seems to be a duplicate of #1042
this is 1042 XD
@guillermodelagala Thanks for your using Ngx-Mask. Please update to latest version. It example, all work as expected - https://stackblitz.com/edit/angular-7uobnu?file=src%2Fmain.ts In the future we are considering support Angular version 15,14
Thanks for fixing. At the moment I'm using Angular 15, so please notify me when the dependency is compatible again with the latest Angular version. Regards.
🐞 bug report
Is this a regression?
Yes, the previous version in which this bug was not present was: 13.1.9
Description
Having the following input with an initial value of: 5.000,000 , the input displays the placeholder instead of the value. <input class="input" type="text" formControlName="quantity" [placeholder]="getNumberPlaceholder()" mask="separator.3" [decimalMarker]="getDecimalMarker()" [thousandSeparator]="getThousandSeparator()" [dropSpecialCharacters]="false" [matTooltip]="form.controls.quantity.value" matTooltipPosition="above" [ngClass]="{ 'has-error': form.controls.quantity.errors }" />
🔬 Minimal Reproduction
I can't create a reproduction. At the moment I'll work with version 13.1.9, but please investigate the changes you did between 13.1.9 and 13.1.10. I'm working with Angular 14.2.4.
Angular Version: