Skip to main content
All docs
V24.1

DxHtmlEditorMention.SearchDelay Property

Specifies the time interval between the last search string change and the consequent search result update.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v24.1.dll

NuGet Package: DevExpress.Blazor

Declaration

[DefaultValue(500)]
[Parameter]
public int SearchDelay { get; set; }

Property Value

Type Default Description
Int32 500

The time interval in milliseconds.

Remarks

<DxHtmlEditor> supports mention functionality. When a user types a predefined marker, the component displays a list of available items. To enable search operations for mentions, specify the SearchFieldNames property.

Use the SearchDelay property to adjust the time interval between the last search string change and the consequent search result update.

Example

The following code snippet removes the delay before the start of a new search operation in the mention list:

<DxHtmlEditor Height="200px">
    <DxHtmlEditorMentions>
        <DxHtmlEditorMention Data="@EmployeesData"
                             DisplayFieldName="@nameof(MentionData.Name)"
                             SearchFieldNames="@SearchFieldNames"
                             SearchDelay="0" />
    </DxHtmlEditorMentions>
</DxHtmlEditor>

@code {
    string[] SearchFieldNames = { nameof(MentionData.Name) };

    class MentionData {
        public string Name { get; set; }
        public string Team { get; set; }
    }
    MentionData[] EmployeesData = {
        new MentionData() { Name = "John Heart", Team = "Engineering" },
        new MentionData() { Name = "Kevin Carter", Team = "Engineering" },
        new MentionData() { Name = "Olivia Peyton", Team = "Management" },
        new MentionData() { Name = "Robert Reagan", Team = "Management" },
        new MentionData() { Name = "Cynthia Stanwick", Team = "Engineering" },
        new MentionData() { Name = "Brett Wade", Team = "Analysis" },
        new MentionData() { Name = "Greta Sims", Team = "QA" },
    };
}
See Also