Skip to content

Commit cfc9b31

Browse files
committed
add features to overview
1 parent 8441ee3 commit cfc9b31

File tree

5 files changed

+27
-12
lines changed

5 files changed

+27
-12
lines changed
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
#highlighted-behavior
2+
**Example: Removing the highlighted item**
3+
4+
```C#
5+
var autoComplete = new RadAutoComplete();
6+
autoComplete.HighlightItemFunc = (filteredItems, searchText) => null;
7+
```
8+
9+
**Example: Setting the highlighted item to the last item from the SuggestionView**
10+
11+
```C#
12+
var autoComplete = new RadAutoComplete();
13+
autoComplete.HighlightItemFunc = (filteredItems, searchText) => filteredItems.LastOrDefault();
14+
```
15+
#end

controls/autocomplete/configuration.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,14 @@ By default the search is triggered as soon as the user types into the input fiel
6161

6262
<snippet id='autocomplete-searchthreshold'/>
6363

64+
## Highlight Item Behavior
65+
66+
When filtering is performed and there are matching items, the items are displayed in the `SuggestionView`.
67+
68+
By default, the first item in the `SuggestionView` is highlighted. To modify this behavior use the `HighlightItemFunc` (`Func<IEnumerable<object>, string, object>`) property. The function receives the filtered collection of items and the current search text as parameters and returns the item from the filtered collection that should be highlighted.
69+
70+
@[template](/_contentTemplates/controls/autocomplete.md#highlighted-behavior)
71+
6472
## SuggestionView Visibility
6573

6674
* `ShowSuggestionView` (`bool`)&mdash;Determine the visibility of the popup containing the search results of the AutoComplete. The default value is `True`.

controls/autocomplete/filtering.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -20,17 +20,7 @@ When filtering is performed and there are matching items, the items are displaye
2020

2121
**Example: Removing the highlighted item**
2222

23-
```C#
24-
var autoComplete = new RadAutoComplete();
25-
autoComplete.HighlightItemFunc = (filteredItems, searchText) => null;
26-
```
27-
28-
**Example: Setting the highlighted item to the last item from the SuggestionView**
29-
30-
```C#
31-
var autoComplete = new RadAutoComplete();
32-
autoComplete.HighlightItemFunc = (filteredItems, searchText) => filteredItems.LastOrDefault();
33-
```
23+
@[template](/_contentTemplates/controls/autocomplete.md#highlighted-behavior)
3424

3525
## Custom Filtering
3626

controls/autocomplete/overview.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@ The Telerik UI for .NET MAUI AutoComplete can automatically complete user input
2424
* [Remote Search]({%slug autocomplete-remote-search%})&mdash;Allows you to take the user input, trigger a custom searching algorithm and assign the results to the ItemSource of the AutoComplete.
2525
* [Suggestion view visibility]({%slug autocomplete-configuration%}#suggestionview-visibility)&mdash;AutoComplete provides the ability to hide the view with the suggestions.
2626
* [Suggestion view position]({%slug autocomplete-configuration%}#suggestionview-position)&mdash;AutoComplete gives you the option to specify whether the `SuggestionView` will be displayed&mdash;above or under the control.
27-
* [Highlight customization]({%slug autocomplete-styling%}#hightlight-customization)&mdash;You can customize the highlight color of the suggestion items.
27+
* [Highlight item behavior]({%slug autocomplete-configuration%}#highlight-item-behavior)&mdash;You can define whether the first item in the suggestion view will be highlighted automatically or not.
28+
* [Highlight item styling]({%slug autocomplete-styling%}#hightlight-customization)&mdash;You can customize the highlight color of the suggestion items.
2829
* [Keyboard navigation]({%slug autocomplete-keyboard-support%}) support&mdash;Use keyboard keys for navigation in the .NET MAUI AutoComplete suggestion view. This feature is available on WinUI and Mac Catalyst.
2930
* [Nested properties support]({%slug autocomplete-data-binding%})&mdash;This allows binding of a complex object to the `TextSearchPath` property.
3031
* [Styling options]({%slug autocomplete-styling%})&mdash;For changing the control's border brush and thickness, font options, suggestion item highlight text color and more.

controls/checkbox/overview.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ Telerik UI for .NET MAUI CheckBox is a control, which enables users to make a ch
2020
* [Checked states]({% slug checkbox-checked-states %})&mdash;The CheckBox delivers options for setting its state to checked and unchecked, and provides an additional indeterminate state which indicates the control is neither checked nor unchecked.
2121
* [Size]({% slug checkbox-configuration%}#size)&mdash;You can set the width and height of the CheckBox by adjusting only a single CheckBox property.
2222
* [Disable the animation]({%slug checkbox-configuration%}#remove-the-animation)&mdash;The CheckBox provides an option for turning off the animation when the CheckBox state changes.
23+
* [Events]({%slug checkbox-checked-states%}#events)&mdash;The CheckBox exposes events that allow you to track when the `IsChecked` state is changing or has changed.
2324
* [Flexible styling API]({% slug checkbox-styling %})&mdash;The CheckBox exposes a set of styling properties for customizing its visual appearance and enables you to set its background, border, and symbol color, as well as customize its layout, including the borders and the check mark.
2425

2526
## Next Steps

0 commit comments

Comments
 (0)