72 lines
3.1 KiB
Plaintext
72 lines
3.1 KiB
Plaintext
@using Microsoft.AspNetCore.Components.Web
|
|
@using Radzen.Blazor
|
|
@namespace EgwCoreLib.BlazorTest.Pages
|
|
@addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers
|
|
|
|
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="utf-8" />
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
<base href="~/" />
|
|
<link rel="stylesheet" href="lib/bootstrap/css/bootstrap.min.css" />
|
|
<link rel="stylesheet" href="lib/font-awesome/css/all.min.css" />
|
|
<link rel="stylesheet" href="css/site.css" />
|
|
<link rel="stylesheet" href="EgwCoreLib.BlazorTest.styles.css" />
|
|
<component type="typeof(HeadOutlet)" render-mode="ServerPrerendered" />
|
|
<component type="typeof(RadzenTheme)" render-mode="ServerPrerendered" param-Theme="@("material")" />
|
|
</head>
|
|
<body>
|
|
@RenderBody()
|
|
|
|
<div id="blazor-error-ui">
|
|
<environment include="Staging,Production">
|
|
An error has occurred. This application may no longer respond until reloaded.
|
|
</environment>
|
|
<environment include="Development">
|
|
An unhandled exception has occurred. See browser dev tools for details.
|
|
</environment>
|
|
<a href="" class="reload">Reload</a>
|
|
<a class="dismiss">🗙</a>
|
|
</div>
|
|
|
|
<script src="lib/bootstrap/js/bootstrap.bundle.js"></script>
|
|
<script src="lib/bootstrapModalHelper.js"></script>
|
|
@* <script src="https://cdn.jsdelivr.net/npm/chart.js"></script> *@
|
|
<script src="~/lib/Chart.js/chart.umd.js"></script>
|
|
|
|
<script src="_framework/blazor.server.js" autostart="false"></script>
|
|
|
|
@*Gestione autoriconnessione: https://github.com/dotnet/aspnetcore/issues/38305 (vedere anche https://docs.microsoft.com/it-it/aspnet/core/blazor/fundamentals/signalr?view=aspnetcore-6.0#modify-the-reconnection-handler-blazor-server)*@
|
|
<script>
|
|
Blazor.start({
|
|
reconnectionOptions: {
|
|
maxRetries: 1500,
|
|
retryIntervalMilliseconds: 4000
|
|
},
|
|
reconnectionHandler: {
|
|
onConnectionDown: (options, error) => console.error(error),
|
|
onConnectionUp: () => console.log("Connection up!,restarting!")
|
|
}
|
|
}).then(() => {
|
|
Object.defineProperty(Blazor.defaultReconnectionHandler, '_reconnectionDisplay', {
|
|
get() {
|
|
return this.__reconnectionDisplay;
|
|
},
|
|
set(value) {
|
|
this.__reconnectionDisplay = {
|
|
show: () => value.show(),
|
|
update: (d) => value.update(d),
|
|
rejected: (d) => document.location.reload()
|
|
}
|
|
}
|
|
});
|
|
});
|
|
</script>
|
|
@*Gestione ricollegamento successivo: https://learn.microsoft.com/en-us/aspnet/core/blazor/fundamentals/signalr?view=aspnetcore-6.0*@
|
|
@* <script>Blazor.defaultReconnectionHandler._reconnectCallback = function (d) { document.location.reload(); }</script> *@
|
|
|
|
<script src="_content/Radzen.Blazor/Radzen.Blazor.js?v=@(typeof(Radzen.Colors).Assembly.GetName().Version)"></script>
|
|
</body>
|
|
</html>
|