You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Esc or ABBRECHEN discards a typed CO reading and typed Einsatzdaten without asking #652
Two editors throw away typed input on Esc or ABBRECHEN without asking:
CO-Messprotokoll. The reading editor's ABBRECHEN drops the buffer (CoMessprotokollViewModel.cs:1406-1413, CloseEditor → Editor = null), and Esc is bound to the same command (CoMessprotokollView.axaml:259, b:Overlay.CancelCommand="{Binding CloseEditorCommand}"). Every removal in this view asks first; losing a typed ppm value does not. A reading that has not been recorded is a gap in the Messreihe.
Einsatzdaten dialog.Cancel() just raises Closed (IncidentDataDialogViewModel.cs:91), and Esc maps to it (IncidentDataDialogView.axaml:13). Typed Stichwort, Einsatznummer and address are discarded. Lower risk — four fields — but the same pattern.
Expected
If the buffer differs from what is stored, Esc and ABBRECHEN ask first ("Änderungen verwerfen?"), with focus on ABBRECHEN as the destructive-confirm rule from epic: keyboard-only operation (tracking) #545 requires. If nothing changed, they close straight away, so the keyboard flow stays fast.
CO: the editor already knows what changed (HasStatusChange, HasCoValueChange, HasDetailChange, HasLabelChange); reuse the in-view confirm the building removal uses.
Einsatzdaten: compare the fields to the session values and raise a ConfirmDialogViewModel.
Notes
Tests: type a value, cancel, assert the editor is still open and the confirm is showing; cancel with no change, assert it closes.
Check KeystrokeBudgetTests still pass — the unchanged path must not gain a keystroke.
This touches the UI, so the PR needs a before/after screenshot pair.
Activity
feat: ask before Esc or ABBRECHEN discards a typed CO reading or Eins…