Пример #1
0
 public void Show(LoadingOption option)
 {
     if (LoadingOptions.Any(x => x.Target.Id == option.Target.Id))
     {
         return;
     }
     LoadingOptions.Add(option);
 }
Пример #2
0
        internal async Task CurrentPageChangedAsync(int page)
        {
            CurrentPage = page;
            if (CurrentPageChanged.HasDelegate)
            {
                RequireRender = true;
                var option = new LoadingOption()
                {
                    Background = LoadingBackground,
                    Target     = Container,
                    IconClass  = LoadingIconClass,
                    Text       = LoadingText
                };
                LoadingService.LoadingOptions.Add(option);
                SelectedRows.Clear();
                await CurrentPageChanged.InvokeAsync(page);

                LoadingService.LoadingOptions.Remove(option);
            }
        }
Пример #3
0
        async Task ShowFullScreenLoadingAsync(LoadingOption option)
        {
            await Document.AppendAsync(option.Element);

            await Document.DisableScrollAsync();

            var style = option.Element.Dom(JSRuntime).Style;
            await style.SetAsync("display", "none");

            await style.SetAsync("width", "100%");

            await style.SetAsync("height", "100%");

            await style.SetAsync("position", "fixed");

            await style.SetAsync("top", "0");

            await style.SetAsync("bottom", "0");

            await style.SetAsync("display", "block");
        }
Пример #4
0
 async Task CloseFullScreenLoadingAsync(LoadingOption option)
 {
     await Document.EnableYScrollAsync();
 }