BoldSign®Effortlessly integrate e-signatures into your app with the BoldSign® API. Create a sandbox account!
Hello i wonder that have syncfusion team implemented mention feature for document editor like in rich text editor yet. At the moment, i need this feature, but from what i read from official docs, it's not available. Or if you have any alternative way in your library, suggest me. I really need the mention feature for document editor component
Hi Phong,
Currently we are checking the scenario and will update the details by 18 August, 2023.
Regards,
Kavitha M
Hi Phong,
The document editor provides a keydown event which will be triggered every time
a key is pressed in the editor.
You can find more information about it here: https://ej2.syncfusion.com/react/documentation/api/document-editor/#keydown
Using this event, we can detect the "@" key and display the EJ2
autocomplete component inside the EJ2 dialog to show a list of suggestions.
Once an item is typed in the autocomplete element, you can choose the item from
the suggestion list.
Once an item is selected, we can insert it into the editor using the insertText
API of the editor module.
You can find more information about the insertText API here: https://ej2.syncfusion.com/react/documentation/api/document-editor/editor/#inserttext
For your reference, we have prepared a sample. Please check the stackblitz link
below and let us know if you have any concerns.
Stackblitz Link: https://stackblitz.com/edit/react-jjxniz-mbrt6f?file=index.js
As mentioned in the above sample, we have bound the keydown event of the
document editor to the functionality of showing the dialog inside the
autocomplete component. The selected item in the autocomplete element will be
inserted as text in the document editor.
Please check it and let us know if this meets your needs.
Regards,
Kavitha M
It is not user friendly to show popup box, user feel he is out of document , we need mentioned feature in document Editor like you have in rich text editor,
Hi Phong Nguyentien,
The Document Editor does not support mentions within the document itself. Mentions are only supported in the comments section of the Document Editor.
Demo Sample - https://ej2.syncfusion.com/react/demos/#/fluent2/document-editor/comments
Regards,
Mohammed Affan C