Initial commit
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
@using MudBlazor
|
||||
|
||||
<MudDialog>
|
||||
<TitleContent>
|
||||
<MudText Typo="Typo.h6">Cancel Mission</MudText>
|
||||
</TitleContent>
|
||||
<DialogContent>
|
||||
<MudText Typo="Typo.body1" Class="mb-3">
|
||||
Are you sure you want to cancel mission <strong>@MissionName</strong>?
|
||||
</MudText>
|
||||
<MudTextField @bind-Value="_reason"
|
||||
Label="Reason (optional)"
|
||||
Placeholder="Enter reason for cancellation..."
|
||||
Variant="Variant.Outlined"
|
||||
Lines="3"
|
||||
Counter="200"
|
||||
MaxLength="200" />
|
||||
</DialogContent>
|
||||
<DialogActions>
|
||||
<MudButton OnClick="Cancel">Cancel</MudButton>
|
||||
<MudButton Variant="Variant.Filled" Color="Color.Error" OnClick="Confirm">Cancel Mission</MudButton>
|
||||
</DialogActions>
|
||||
</MudDialog>
|
||||
|
||||
@code {
|
||||
[CascadingParameter] IMudDialogInstance Dialog { get; set; } = null!;
|
||||
[Parameter] public string MissionName { get; set; } = "";
|
||||
|
||||
private string _reason = "";
|
||||
|
||||
private void Cancel() => Dialog.Cancel();
|
||||
|
||||
private void Confirm() => Dialog.Close(DialogResult.Ok(_reason?.Trim() ?? ""));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user