File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change 11{
22 "name" : " react-number-format" ,
33 "description" : " React component to format number in an input or as a text." ,
4- "version" : " 5.1.1 " ,
4+ "version" : " 5.1.2 " ,
55 "main" : " dist/react-number-format.cjs.js" ,
66 "module" : " dist/react-number-format.es.js" ,
77 "types" : " types/index.d.ts" ,
Original file line number Diff line number Diff line change @@ -336,7 +336,7 @@ export default function NumberFormatBase<BaseType = InputAttributes>(
336336 const _onFocus = ( e : React . FocusEvent < HTMLInputElement > ) => {
337337 // Workaround Chrome and Safari bug https://bugs.chromium.org/p/chromium/issues/detail?id=779328
338338 // (onFocus event target selectionStart is always 0 before setTimeout)
339- e . persist ( ) ;
339+ if ( e . persist ) e . persist ( ) ;
340340
341341 const el = e . target ;
342342 focusedElm . current = el ;
You can’t perform that action at this time.
0 commit comments