File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change 88 " modal" ,
99 " useModal"
1010 ],
11- "version" : " 0.2.1 " ,
11+ "version" : " 0.2.2 " ,
1212 "main" : " lib/index" ,
1313 "types" : " lib" ,
1414 "files" : [
Original file line number Diff line number Diff line change @@ -38,7 +38,7 @@ export const ModalProvider: React.FC<ModalProviderProps> = ({
3838 const showModal = useCallback (
3939 ( content : React . ReactNode , options ?: Partial < ModalProps > ) => {
4040 setContent ( content ) ;
41- if ( options ) optionsRef . current = options ;
41+ optionsRef . current = options ;
4242 } ,
4343 [ ] ,
4444 ) ;
@@ -47,10 +47,10 @@ export const ModalProvider: React.FC<ModalProviderProps> = ({
4747 setContent ( null ) ;
4848 } , [ ] ) ;
4949
50- const value = useMemo ( ( ) => ( { showModal , closeModal } ) , [
51- showModal ,
52- closeModal ,
53- ] ) ;
50+ const value = useMemo (
51+ ( ) => ( { showModal, closeModal } ) ,
52+ [ showModal , closeModal ] ,
53+ ) ;
5454
5555 return (
5656 < ModalContext . Provider value = { value } >
You can’t perform that action at this time.
0 commit comments