nice-modal-react icon indicating copy to clipboard operation
nice-modal-react copied to clipboard

Fix the issue where some dialogs cannot be closed when using nested providers

Open IVLIU opened this issue 8 months ago • 6 comments

relate issues

  • #100
  • #141

feature

  1. optimize parts of the TypeScript implementation.
  2. the issue of being unable to close the popup when using nested providers.

sample

Please refer to the following example. You can switch the imports to see the effects before and after the fix.

https://codesandbox.io/p/sandbox/nice-modal-sample-l4hj7d?file=%2Fsrc%2FApp.tsx%3A50%2C64

and

I tried to maintain compatibility as much as possible, so I added extra parameters to the show, hide, and remove methods to support dispatch definition.

IVLIU avatar Jun 04 '24 06:06 IVLIU