using MudBlazor; using SteUp.Shared.Components.SingleElements.Modal; using SteUp.Shared.Core.Dto; namespace SteUp.Shared.Core.Helpers; public abstract class ModalHelper { public static async Task OpenSelectShop(IDialogService dialog) { var modal = await dialog.ShowAsync( "ModalSelectShop", new DialogParameters(), new DialogOptions { FullScreen = false, CloseButton = false, NoHeader = true, BackdropClick = true } ); return await modal.Result; } public static async Task OpenFormScheda(IDialogService dialog, string codMdep, DateOnly data) { var modal = await dialog.ShowAsync( "ModalFormScheda", new DialogParameters { { x => x.CodMdep, codMdep }, { x => x.Data, data }, }, new DialogOptions { FullScreen = true, CloseButton = false, NoHeader = true } ); return await modal.Result; } public static async Task OpenAddAttached(IDialogService dialog) { var modal = await dialog.ShowAsync( "Add attached", new DialogParameters(), new DialogOptions { FullScreen = false, CloseButton = false, NoHeader = true, BackdropClick = false } ); return await modal.Result; } public static async Task OpenSuggestActivityDescription(IDialogService dialog, List? activityTypers) { var modal = await dialog.ShowAsync( "Suggest activity description", new DialogParameters { { x => x.ActivityTypers, activityTypers } }, new DialogOptions { FullScreen = false, CloseButton = false, NoHeader = true, BackdropClick = true } ); return await modal.Result; } }