showModal method
Show a OverlayModal in foreground
Only one modal can be display at the same time if you want to insert multiple OverlayModal show enqueue function.
Implementation
Future<void> showModal(
OverlayModal overlayModal,
) async {
if (mounted) {
await dismissModal();
modal = overlayModal;
await overlayModal.insert();
}
}