defaultValue |
default value |
ContentState, you can use Mention.toContentState or Mention.toEditorState to convert text to ContentState |
null |
disabled |
Tell if the input is disabled. |
boolean |
false |
getSuggestionContainer |
rendered to the root of the menu. Default rendered to the body dom. If gets any problem of the menu while scrolling. Try to make the root the dom scrolled, and make it position relative. |
function |
() => document.body |
loading |
loading mode |
boolean |
false |
multiLines |
multilines mode |
boolean |
false |
notFoundContent |
suggestion when suggestions empty |
string |
'无匹配结果,轻敲空格完成输入' |
placeholder |
placeholder of input |
string |
null |
placement |
The position of the suggestion relative to the target, which can be one of top and bottom |
string |
'bottom'. |
prefix |
character which will trigger Mention to show mention list |
string or Array |
'@' |
readOnly |
Tell if the input is readonly. |
boolean |
false |
suggestions |
suggestion content |
Array<string|Mention.Nav> |
[] |
suggestionStyle |
style of suggestion container |
object |
{} |
value |
core state of mention |
ContentState |
null |
onBlur |
Callback function called when mention component blur |
function(e) |
null |
onChange |
Callback function called when content of input changes |
function(contentState: ContentState) |
null |
onFocus |
Callback function called when mention component get focus |
functione) |
null |
onSearchChange |
Callback function called when search content changes |
function(value:string, trigger: string) |
[] |
onSelect |
Callback function called when select from suggestions |
function(suggestion: string, data?: any) |
null |