Improve signature UI and refactor ReportViewer.razor

Updated the signature button text and SVG icon for clarity.
Enhanced the `DxPopup` component with better interaction
properties (`CloseOnEscape` and `CloseOnOutsideClick`).
Disabled the "Close" button in the popup when no signature
is captured.

Reformatted and restructured constants and fields in the
`@code` block for readability. Reintroduced previously
removed fields, constants, and methods to ensure
functionality. Added a conditional block in `LogoutAsync`
to open the signature popup when the user has access.

Performed general cleanup and code reorganization to
improve maintainability.
This commit is contained in:
2026-06-01 02:42:32 +02:00
parent d8781a4b41
commit 164dfacab3

View File

@@ -54,7 +54,7 @@
</svg>
<span>Unterschrift gespeichert</span>
} else {
<span>Unterschrift erstellen</span>
<span>Unterschrift &auml;ndern</span>
}
</button>
@if (_annotations.Count > 0) {
@@ -160,7 +160,7 @@
<div class="d-flex gap-2 flex-wrap justify-content-end w-100">
<button class="btn btn-outline-secondary" @onclick="RenewSignatureAsync">Unterschrift erneuern</button>
<button class="btn btn-primary" @onclick="SaveSignatureAsync">Speichern</button>
<button class="btn btn-secondary" @onclick="CloseSignaturePopup">Schliessen</button>
<button class="btn btn-secondary" @onclick="CloseSignaturePopup" disabled="@(_capturedSignature is null)">Schliessen</button>
</div>
</FooterContentTemplate>
</DxPopup>
@@ -233,6 +233,10 @@ int _lastOverlayViewerKey = -1;
Navigation.NavigateTo($"/login/{Uri.EscapeDataString(EnvelopeKey)}");
return;
}
else
{
await OpenSignaturePopupAsync();
}
}
_annotations = await AnnotationService.GetAnnotationsAsync(EnvelopeKey ?? "fake");