Add fallback UI, HTTP warning, and disable Wasm native builds
Added a fallback UI in `App.razor` to handle startup failures, including a message for unsupported browsers and a reload button. Updated `blazor.web.js` to use `autostart="false"` and added JavaScript for error handling. Introduced an HTTP warning in `LoginReceiverPage.razor` to alert users when using an unencrypted connection. Added the `IsSecureRequest` property to determine if the request is secure. Disabled native WebAssembly builds by setting `<WasmBuildNative>` to `false` in `EnvelopeGenerator.Server.Client.csproj` and `publish.bat`. Incremented version numbers in `EnvelopeGenerator.Server.csproj` to `1.11.0-beta`. Added new CSS classes for styling the fallback UI.
This commit is contained in:
@@ -29,6 +29,13 @@
|
||||
<p class="mb-0">@L("ReceiverLogin_InfoStep2", "Darin finden Sie den Zugangscode, den Sie hier eingeben müssen.")</p>
|
||||
</div>
|
||||
|
||||
@if (!IsSecureRequest)
|
||||
{
|
||||
<div class="alert alert-warning py-2" role="alert" style="font-size:0.85rem;">
|
||||
@L("ReceiverLogin_HttpWarning", "Sie verwenden derzeit eine unverschlüsselte HTTP-Verbindung. Bitte geben Sie Zugangsdaten nur in vertrauenswürdigen internen Netzwerken ein.")
|
||||
</div>
|
||||
}
|
||||
|
||||
@if (LoginResult == EnvelopeLoginResult.NotFound)
|
||||
{
|
||||
<div class="alert alert-warning d-flex align-items-start gap-2 py-2" role="alert">
|
||||
@@ -173,12 +180,15 @@
|
||||
bool ShowCode;
|
||||
bool IsLoading;
|
||||
bool IsResending;
|
||||
bool IsSecureRequest = true;
|
||||
bool ResendRequestFailed;
|
||||
EnvelopeLoginResult? LoginResult;
|
||||
SendAccessCodeResult? ResendResult;
|
||||
|
||||
protected override async Task OnInitializedAsync()
|
||||
{
|
||||
IsSecureRequest = Navigation.Uri.StartsWith("https://", StringComparison.OrdinalIgnoreCase);
|
||||
|
||||
if (string.IsNullOrWhiteSpace(EnvelopeKey))
|
||||
return;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user