From 6d66d0145ffe5da44a132136df723746882a59ed Mon Sep 17 00:00:00 2001 From: Vladimir Enchev Date: Thu, 2 Jul 2026 11:57:46 +0300 Subject: [PATCH] FormField: fix invalid/empty label for association RadzenFormField rendered for="@Component" on the wrapping
(invalid -
does not take for) and on the label even when Component was unset, producing for="" which accessibility checkers flag as a label with no association. Removed the div for and only emit the label for when Component is set. Updated the FormFieldTextBox demo to give each input an id matching the FormField Component so the label resolves. --- Radzen.Blazor/RadzenFormField.razor | 4 ++-- RadzenBlazorDemos/Pages/FormFieldTextBox.razor | 16 ++++++++-------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/Radzen.Blazor/RadzenFormField.razor b/Radzen.Blazor/RadzenFormField.razor index 55b90601f..361270e7a 100644 --- a/Radzen.Blazor/RadzenFormField.razor +++ b/Radzen.Blazor/RadzenFormField.razor @@ -3,7 +3,7 @@ @if (Visible) { -
+
@if (Start != null) @@ -13,7 +13,7 @@
} @ChildContent - + @if (End != null) {
diff --git a/RadzenBlazorDemos/Pages/FormFieldTextBox.razor b/RadzenBlazorDemos/Pages/FormFieldTextBox.razor index c70e4d699..f31ac2e14 100644 --- a/RadzenBlazorDemos/Pages/FormFieldTextBox.razor +++ b/RadzenBlazorDemos/Pages/FormFieldTextBox.razor @@ -1,22 +1,22 @@ - - + + - - + + - - + + - - + +