File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
packages/@internationalized/number/src Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -164,9 +164,9 @@ class NumberParserImpl {
164
164
// extra step for rounding percents to what our formatter would output
165
165
let options = {
166
166
...this . options ,
167
- style : 'decimal' ,
168
- minimumFractionDigits : Math . min ( this . options . minimumFractionDigits + 2 , 20 ) ,
169
- maximumFractionDigits : Math . min ( this . options . maximumFractionDigits + 2 , 20 )
167
+ style : 'decimal' as const ,
168
+ minimumFractionDigits : Math . min ( ( this . options . minimumFractionDigits ?? 0 ) + 2 , 20 ) ,
169
+ maximumFractionDigits : Math . min ( ( this . options . maximumFractionDigits ?? 0 ) + 2 , 20 )
170
170
} ;
171
171
return ( new NumberParser ( this . locale , options ) ) . parse ( new NumberFormatter ( this . locale , options ) . format ( newValue ) ) ;
172
172
}
You can’t perform that action at this time.
0 commit comments