ModalProvider: onClose
causing Type Error before opening any modal
#5577
Labels
Fixed patch
Completed issues that will be published with next patch (1.0.X)
Dependencies check up
What version of @mantine/* packages do you have in package.json?
7.4.1
What package has an issue?
@mantine/modals
What framework do you use?
Next.js
In which browsers you can reproduce the issue?
Chrome
Describe the bug
ModalProvider:
onClose
causing Type Error before opening any modal.Esc key triggers onClose without an id.
Not sure if it's caused by
trapFocus: false
only.. But you'd expect onClose only to closeModal when an id is available.mantine/packages/@mantine/modals/src/ModalsProvider.tsx
Line 211 in 703bf44
If possible, include a link to a codesandbox with a minimal reproduction
https://codesandbox.io/p/sandbox/jolly-boyd-45rsvz
Possible fix
No response
Self-service
The text was updated successfully, but these errors were encountered: