@@ -26,7 +26,9 @@ res_type: kb
2626
2727## Description
2828
29- This KB also answers the following questions:
29+ This KB article shows how to use disabled non-selectable items in the Telerik ComboBox, DropDownList, and MultiSelect components for Blazor.
30+
31+ The page also answers the following questions:
3032
3133* How to disable certain items in the ComboBox dropdown (popup)?
3234* How to denote if a DropDownList or MultiSelect item is selectable or disabled?
@@ -76,15 +78,15 @@ Reset the ComboBox value to default and then [`Rebind()`](slug:common-features-d
7678 {
7779 var newProduct = Products.FirstOrDefault(x => x.Id == newValue);
7880
79- // Select only enabled items or null
81+ // Select only enabled items or null.
8082 if (newProduct?.Enabled == true || !newValue.HasValue)
8183 {
8284 ComboBoxValue = newValue;
8385 }
8486 else
8587 {
86- // Skip disabled items during keyboard navigation
87- // For simplicity, this logic does not handle adjacent disabled items
88+ // Skip disabled items during keyboard navigation.
89+ // For simplicity, this logic does not handle adjacent disabled items.
8890 int oldProductIndex = Products.FindIndex(x => x.Id == ComboBoxValue);
8991 int newProductIndex = Products.FindIndex(x => x.Id == newValue);
9092
@@ -158,7 +160,7 @@ Unlike the ComboBox, the DropDownList does not need value resetting and `Rebind(
158160
159161 private void OnDropDownListItemRender(DropDownListItemRenderEventArgs<Product> args)
160162 {
161- // args.Item is null for the DefaultText item
163+ // args.Item is null for the DefaultText item.
162164 if (args.Item != null && !args.Item.Enabled)
163165 {
164166 args.Class = "k-disabled";
@@ -169,15 +171,15 @@ Unlike the ComboBox, the DropDownList does not need value resetting and `Rebind(
169171 {
170172 var newProduct = Products.FirstOrDefault(x => x.Id == newValue);
171173
172- // Select only enabled items or DefaultText
174+ // Select only enabled items or DefaultText.
173175 if (newProduct?.Enabled == true || !newValue.HasValue)
174176 {
175177 DropDownListValue = newValue;
176178 }
177179 else
178180 {
179- // Skip disabled items during keyboard navigation
180- // For simplicity, this logic does not handle adjacent disabled items
181+ // Skip disabled items during keyboard navigation.
182+ // For simplicity, this logic does not handle adjacent disabled items.
181183 int oldProductIndex = Products.FindIndex(x => x.Id == DropDownListValue);
182184 int newProductIndex = Products.FindIndex(x => x.Id == newValue);
183185
0 commit comments