I use the package ngx-mask version: 8.14 and
@ng-bootstrap/ng-bootstrap version: 4.0.0
I have an input component using mask inside in the accordion:
class="form-control col-xl-8 col-lg-8 col-md-8"
id="input-initialValue"
name="initialValue"
type="text"
[(ngModel)]="initialValue"
mask="separator.2"
thousandSeparator="."
separatorLimit="9999999999999999"
(focus)="selectAllContent($event)"
/>
When I click on accordion, and my input has the initial value of "5,25", it expands and then when I click again, the comma disappears and the value becomes: "525"
I noticed that this setting passing a float value, the format is invalid.
changing the (.) for (,) in the float number the mask works but this is not correct.
Ex:
2800.99 -> 280.099
2800,99 -> 2.800,99
Ref: #624
@lramondev If you use separator with thousandSeparator '.' default decimaMarker is ',' in another cases default decimalMarker - '.'
In 8.1.7
mask="separator.2"
thousandSeparator="."
decimalMarker=","
value = 9800.5
expected = 9.800,50
returned = 9.800,5 <----------where is the zero?
In 8.1.7
mask="separator.2" thousandSeparator="." decimalMarker=","value = 9800.5
expected = 9.800,50
returned = 9.800,5 <----------where is zero?
any progress ?
Hi, any update on this or can you tell when we can expect a fix? Thanks very much in advance
Most helpful comment
In 8.1.7
value = 9800.5
expected = 9.800,50
returned = 9.800,5 <----------where is the zero?