Class Mention
Inheritance
Namespace: Syncfusion.EJ2.DropDowns
Assembly: Syncfusion.EJ2.dll
Syntax
public class Mention : EJTagHelper
Constructors
Mention()
Declaration
public Mention()
Properties
ActionBegin
Triggers before fetching data from the remote server.
Declaration
public string ActionBegin { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
ActionComplete
Triggers after data is fetched successfully from the remote server.
Declaration
public string ActionComplete { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
ActionFailure
Triggers when the data fetch request from the remote server fails.
Declaration
public string ActionFailure { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
AllowSpaces
Defines whether to allow the space in the middle of mention while searching. When disabled, the space ends the mention component search.
Declaration
public bool AllowSpaces { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | The default value is false |
BeforeOpen
Triggers before the popup is opened.
Declaration
public string BeforeOpen { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
Change
Triggers when an item in a popup is selected and updated in an editor.
Declaration
public string Change { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
Closed
Triggers after the popup is closed.
Declaration
public string Closed { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
ContentTemplate
To get or set value for ContentTemplate.
Declaration
public MvcTemplate<object> ContentTemplate { get; set; }
Property Value
Type |
---|
Syncfusion.EJ2.MvcTemplate<System.Object> |
Created
Triggers when the component is created.
Declaration
public string Created { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
CssClass
Defines class/multiple classes separated by a space for the mention component.
Declaration
public string CssClass { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
DataSource
Accepts the list items either through local or remote service and binds it to the component.
It can be an array of JSON Objects or an instance of DataManager
.
Declaration
public object DataSource { get; set; }
Property Value
Type | Description |
---|---|
System.Object | The default value is null |
Destroyed
Triggers when the component is destroyed.
Declaration
public string Destroyed { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
DisplayTemplate
Specifies the template for the selected value from the suggestion list.
Declaration
public string DisplayTemplate { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
Fields
Defines the fields of the Mention to map with the data source and binds the data to the component. text - Specifies the text that maps the text filed from the data source for each list item. value - Specifies the value that maps the value filed from the data source for each list item. iconCss - Specifies the iconCss that map the icon class filed from the data source for each list item. groupBy - Specifies the groupBy that groups the list items with its related items by mapping groupBy field.
Declaration
public MentionFieldSettings Fields { get; set; }
Property Value
Type | Description |
---|---|
MentionFieldSettings | The default value is null |
Filtering
Triggers on typing a character in the component.
Declaration
public string Filtering { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
FilterType
Determines on which filter type, the component needs to be considered on search action. and its supported data types are
Declaration
public FilterType FilterType { get; set; }
Property Value
Type | Description |
---|---|
FilterType | The default value is FilterType.Contains |
Highlight
Specifies whether to highlight the searched characters on suggestion list items.
Declaration
public bool Highlight { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | The default value is false |
HtmlAttributes
Allows additional HTML attributes such as title, name, etc., and accepts n number of attributes in a key-value pair format.
Declaration
public object HtmlAttributes { get; set; }
Property Value
Type |
---|
System.Object |
IgnoreCase
Specifies whether the searches are case sensitive to find suggestions.
Declaration
public bool IgnoreCase { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | The default value is true |
ItemTemplate
Specifies the template for the suggestion list.
Declaration
public string ItemTemplate { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
Locale
Overrides the global culture and localization value for this component. Default global culture is ‘en-US’.
Declaration
public string Locale { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is "en-US" |
MentionChar
Specifies the symbol or single character which triggers the search action in the mention component.
Declaration
public char MentionChar { get; set; }
Property Value
Type | Description |
---|---|
System.Char | The default value is '@' |
MinLength
Specifies the minimum length of user input to initiate the search action. The default value is zero, where suggestion the list opened as soon as the user inputs the mention character.
Declaration
public int MinLength { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 | The default value is 0 |
NoRecordsTemplate
Specifies the template for no matched item which is displayed when there are no items to display in the suggestion list.
Declaration
public string NoRecordsTemplate { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is "No records found" |
Opened
Triggers after the popup opens.
Declaration
public string Opened { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
PopupHeight
Specifies the height of the popup in pixels/number/percentage. The number value is considered as pixels.
Declaration
public string PopupHeight { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is "300px" |
PopupWidth
Specifies the width of the popup in pixels/number/percentage. The number value is considered as pixels.
Declaration
public string PopupWidth { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is "auto" |
Query
Specifies the external query, which can be customized and filtered against the data source.
Declaration
public string Query { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
Select
Triggers when an item in the popup is selected by the user either with the mouse/tap or with keyboard navigation.
Declaration
public string Select { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
ShowMentionChar
Specifies whether to show the configured mentionChar with the text.
Declaration
public bool ShowMentionChar { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | The default value is false |
SortOrder
Specifies the order to sort the data source. The possible sort orders are,
None
- The data source is not sorted.
Ascending
- The data source is sorted in ascending order.
Descending
- The data source is sorted in descending order.
Declaration
public SortOrder SortOrder { get; set; }
Property Value
Type | Description |
---|---|
SortOrder | The default value is SortOrder.None |
SpinnerTemplate
Specifies the template for showing until data is loaded in the popup.
Declaration
public string SpinnerTemplate { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
SuffixText
Specifies the custom suffix to append along with the mention component selected item while inserting. You can append space or new line character as suffix.
Declaration
public string SuffixText { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |
SuggestionCount
Specifies the number of items in the suggestion list.
Declaration
public int SuggestionCount { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 | The default value is 25 |
Target
Specifies the target selector where the mention component needs to be displayed. The mention component listens to the target's user input and displays suggestions as soon as the user inputs the mention character.
Declaration
public string Target { get; set; }
Property Value
Type | Description |
---|---|
System.String | The default value is null |