Skip to content

Commit 3b20fc0

Browse files
committed
Enable nullable refernce types for RadzenDialg.razor.cs
1 parent 454ea9f commit 3b20fc0

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

Radzen.Blazor/RadzenDialog.razor.cs

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88

99
namespace Radzen.Blazor;
1010

11+
#nullable enable
12+
1113
/// <summary>
1214
/// Represents a dialog component in the Radzen framework.
1315
/// RadzenDialog is a reusable component that facilitates the creation of modal dialogs.
@@ -26,7 +28,7 @@ private string SideDialogContentCssClass
2628
}
2729
}
2830

29-
[Inject] private DialogService Service { get; set; }
31+
[Inject] private DialogService? Service { get; set; }
3032

3133
/// <summary>
3234
/// Gets or sets the close side dialog aria label text.
@@ -36,13 +38,13 @@ private string SideDialogContentCssClass
3638
public string CloseSideDialogAriaLabel { get; set; } = "Close side dialog";
3739

3840
private List<Dialog> dialogs = new List<Dialog>();
39-
private bool isSideDialogOpen = false;
40-
private RenderFragment sideDialogContent;
41-
private SideDialogOptions sideDialogOptions;
42-
private Dialog sideDialog;
41+
private bool isSideDialogOpen;
42+
private RenderFragment? sideDialogContent;
43+
private SideDialogOptions? sideDialogOptions;
44+
private Dialog? sideDialog;
4345
private ElementReference? resizeBarElement;
4446
private ElementReference? sideDialogElement;
45-
private IJSObjectReference sideDialogResizeHandleJsModule;
47+
private IJSObjectReference? sideDialogResizeHandleJsModule;
4648

4749
/// <summary>
4850
/// Opens a new dialog with specified parameters and options.

0 commit comments

Comments
 (0)