public async ValueTask <bool> IsDevice() { CellBlazorService CellService = this; if (CellService.JsRuntime != null) { await CellBaseUtils.InvokeDeviceMode(CellService, CellService.JsRuntime); } return(CellService.IsDeviceMode); }
protected override async Task OnAfterRenderAsync(bool firstRender) { CellBaseComponent cellBaseComponent = this; if (firstRender) { cellBaseComponent.DotnetObjectReference = DotNetObjectReference.Create <object>((object)cellBaseComponent); cellBaseComponent.IsRendered = firstRender; await CellBaseUtils.ImportModule(cellBaseComponent.JSRuntime, CellScriptModules.CellBase); await CellBaseUtils.InvokeDeviceMode(cellBaseComponent.SyncfusionService, cellBaseComponent.JSRuntime); await CellBaseUtils.ImportModules(cellBaseComponent.JSRuntime, cellBaseComponent.DependentScripts, cellBaseComponent.SyncfusionService.ScriptHashKey); if (cellBaseComponent.ScriptModules != CellScriptModules.None) { await CellBaseUtils.ImportModule(cellBaseComponent.JSRuntime, cellBaseComponent.ScriptModules, cellBaseComponent.SyncfusionService.ScriptHashKey); } await cellBaseComponent.OnAfterScriptRendered(); } cellBaseComponent.PropertyChanges?.Clear(); }