This update introduces the ability to support multiple modals being shown at the same time. Previously, only one modal could be shown at a time. The changes include:
Global and Hook Hide Functions: Added new global and hook-based hide functions to manage modal hiding more effectively. This includes the deprecation of calling magicModal.hide without a modal ID.
Scrollable Modals: Added a new example and support for scrollable modals. This can be achieved by disabling swipe gestures using the swipeDirection: undefined option.
Readme Updates: Improved usage documentation with preferred patterns, including new examples for imperative hiding and using hooks within modals.
Tooling Updates: Updated various development dependencies, scripts, and configurations to ensure compatibility and improved development workflow.
Breaking Changes
The magicModal.hide function now requires a modal ID to hide a specific modal. This will affect any previous implementation that called hide without an ID.
Migration Guide
Update any calls to magicModal.hide to include the appropriate modal ID.
Review the updated usage patterns and examples in the README to adapt to the new preferred usage patterns.
This update introduces the ability to support multiple modals being shown at the same time. Previously, only one modal could be shown at a time. The changes include:
magicModal.hide
without a modal ID.swipeDirection: undefined
option.Breaking Changes
magicModal.hide
function now requires a modal ID to hide a specific modal. This will affect any previous implementation that calledhide
without an ID.Migration Guide
magicModal.hide
to include the appropriate modal ID.