We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 083e9c5 commit 558a206Copy full SHA for 558a206
1 file changed
src/Masa.Stack.Components/Shared/IntegrationComponents/Confirm/SSimpleConfirm.razor
@@ -1,6 +1,7 @@
1
@inherits Masa.Blazor.Popup.Components.AlertingPopupComponentBase
2
3
<MDialog @bind-Value="@Visible"
4
+ @bind-Value:after="OnVisibleChanged"
5
Class="pa-6"
6
ContentClass="pa-6 white rounded-5"
7
Width="400">
@@ -69,9 +70,16 @@
69
70
[Parameter]
71
public EventCallback OnOk { get; set; }
72
- private I18n? _languageProvider;
73
private string ComputedCancelText => CancelText ?? T("Cancel");
74
private string ComputedOkText => OkText ?? T("Ok");
75
+
76
+ private async Task OnVisibleChanged()
77
+ {
78
+ if (!Visible)
79
80
+ await SetResult(false);
81
+ }
82
83
84
public virtual async Task HandleOnCancel()
85
{
0 commit comments