{
  "$schema": "https://ai.syncfusion.com/schema/registry-item.json",
  "name": "rich-text-editor-mention",
  "framework": "aspnet-mvc",
  "type": "registry:component",
  "component": "RichTextEditor",
  "variant": "mention",
  "dependencies": [
    "Syncfusion.AspNetMvc.RichTextEditor",
    "Syncfusion.AspNetMvc.Navigations"
  ],
  "description": "Rich text editor with at-mention dropdown that inserts users from a suggestion list.",
  "meta": {
    "essentialStudioRelease": "2026 Volume 3 (v35.1.37)",
    "license": "commercial-or-community",
    "licenseNote": "The Syncfusion package is licensed. The composition in this file is source you own and edit. See https://ai.syncfusion.com/licensing.md",
    "requiresLicenseKey": true,
    "requiresServerEndpoint": false,
    "platformIndex": "https://ai.syncfusion.com/aspnet-mvc/llms.txt",
    "skillPack": "syncfusion/aspnetmvc-ui-components-skills",
    "docs": "https://ai.syncfusion.com/gallery/aspnet-mvc/rich-text-editor-mention.md"
  },
  "files": [
    {
      "target": "src/components/rich-text-editor-mention/RichTextEditor.cshtml",
      "content": "@using Syncfusion.EJ2\n@using EJ2MVCSampleBrowser.Models\n@using Syncfusion.EJ2.DropDowns\n@section ControlsSection{\n    <div class=\"control-section\">\n        <div class=\"control-wrapper\">\n            @Html.EJS().RichTextEditor(\"mentionIntegration\").ActionBegin(\"actionBegin\").ContentTemplate(@<div>\n                <p>Hello <span contenteditable=\"false\" class=\"e-mention-chip\"><a href=\"mailto:maria@gmail.com\" title=\"maria@gmail.com\">@@Maria</a></span>&#8203;</p>\n                <p>Welcome to the mention integration with rich text editor demo. Type <code>@@</code> character and tag user from the suggestion list. </p>\n            </div>).Render()\n            @Html.EJS().Mention(\"mentionRTE\").MentionChar((char)ViewData[\"MentionChar\"]).Created(\"onMentionCreate\").Target(\"#mentionIntegration_rte-edit-view\").DataSource((IEnumerable<EmailData>)ViewData[\"emails\"]).AllowSpaces(true).Fields(new MentionFieldSettings { Text = \"Name\" }).SuggestionCount(8).Highlight(true).DisplayTemplate(\"<a href='mailto:${ EmailId}'>@${ Name}</a>\").ItemTemplate(\"<table><tr><td><div id=\\\"mention-TemplateList\\\"><img class=\\\"mentionEmpImage\\\" src=\\\"../Content/Images/RichTextEditor/${Eimg}.png\\\" alt=\\\"employee\\\" /><span class=\\\"e-badge e-badge-success e-badge-overlap e-badge-dot e-badge-bottom ${Status}\\\"></span></div></td><td><span class=\\\"person\\\">${Name}</span><span class=\\\"email\\\">${EmailId}</span></td</tr></table>\").PopupWidth(\"250px\").PopupHeight(\"200px\").Render()\n        </div>\n    </div>\n}\n\n<style>\n    #mention-TemplateList {\n        position: relative;\n        display: inline-block;\n        padding:2px;\n    }\n\n    .person, .email {\n        display: block;\n        line-height: 20px;\n        text-indent: 5px;\n    }\n\n    .person {\n        font-size: 16px;\n    }\n\n    .mentionEmpImage {\n        display: inline-block;\n        width: 46px;\n        height: 46px;\n        padding: 3px;\n        border-radius: 25px;\n    }\n\n    #mention-TemplateList .e-badge-success {\n        left: 76%;\n        bottom: 4px;\n        top: auto;\n    }\n\n    #mention_integration_rte-edit-view_popup .e-dropdownbase .e-list-item {\n        line-height: 8px;\n    }\n\n    #mention-TemplateList .e-badge-success {\n        background-color: #4d841d;\n        color: #fff;\n    }\n\n    #mention-TemplateList .e-badge-success.away {\n        background-color: #fedd2d;\n        color: #fff;\n    }\n\n    #mention-TemplateList .e-badge-success.busy {\n        background-color: #de1a1a;\n        color: #fff;\n    }\n\n    #mention-TemplateList .e-badge.e-badge-dot {\n        height: 10px;\n        width: 10px;\n    }\n    #mentionIntegration .e-mention-chip{\n         cursor: pointer;\n    }\n</style>\n\n<script>\n       var mentionObj;\n        function actionBegin(args) {\n            if (args.requestType === 'EnterAction' && mentionObj.element.classList.contains('e-popup-open')) {\n                args.cancel = true;\n            }\n        }\n        function onMentionCreate() {\n            mentionObj = this;\n        }\n</script>\n"
    },
    {
      "target": "src/components/rich-text-editor-mention/RichTextEditorController.cs",
      "content": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Threading.Tasks;\nusing System.Web.Mvc;\nusing EJ2MVCSampleBrowser.Models;\n\nnamespace EJ2MVCSampleBrowser.Models\n{\n    public class EmailData\n    {\n        public string Name;\n        public string EmailId;\n        public string Eimg;\n        public string Status;\n        public List<EmailData> EmailList()\n        {\n            return new List<EmailData>\n            {\n                new EmailData { Name = \"Selma Rose\",     EmailId = \"selma@company.com\", Eimg = \"1.png\",  Status = \"e-active\" },\n                new EmailData { Name = \"Russo Kay\",      EmailId = \"russo@company.com\", Eimg = \"2.png\",  Status = \"e-active\" },\n                new EmailData { Name = \"James Nick\",     EmailId = \"james@company.com\", Eimg = \"3.png\",  Status = \"e-active\" },\n                new EmailData { Name = \"Rhoda Barns\",    EmailId = \"rhoda@company.com\", Eimg = \"4.png\",  Status = \"e-active\" },\n                new EmailData { Name = \"Megan Warn\",     EmailId = \"megan@company.com\", Eimg = \"5.png\",  Status = \"e-active\" },\n                new EmailData { Name = \"Robert Bose\",    EmailId = \"robert@company.com\", Eimg = \"6.png\",  Status = \"e-active\" },\n                new EmailData { Name = \"Louise Rob\",     EmailId = \"louise@company.com\", Eimg = \"7.png\",  Status = \"e-active\" },\n                new EmailData { Name = \"Niko Natch\",     EmailId = \"niko@company.com\",  Eimg = \"8.png\",  Status = \"e-active\" },\n                new EmailData { Name = \"Mark Val\",       EmailId = \"mark@company.com\",  Eimg = \"9.png\",  Status = \"e-active\" },\n                new EmailData { Name = \"Tom Davy\",       EmailId = \"tom@company.com\",   Eimg = \"10.png\", Status = \"e-active\" }\n            };\n        }\n    }\n}\n\nnamespace EJ2MVCSampleBrowser.Controllers\n{\n    public partial class RichTextEditorController : Controller\n    {\n        public ActionResult MentionIntegration()\n        {\n            ViewData[\"emails\"] = new EmailData().EmailList();\n            ViewData[\"mentionChar\"] = '@';\n            return View(\"~/Views/Home/rich-text-editor/mention/RichTextEditor.cshtml\");\n        }\n    }\n}"
    }
  ]
}