-
-
Notifications
You must be signed in to change notification settings - Fork 621
Description
Hi everybody,
I'm new to the excellent Trumbowyg editor, and I'm trying the mention plugin for my project.
I'd like to have 2 "mention" buttons in the toolbar to separate the list of the plugin.
I explain it with the configuration I'd like to have :
`btns: [['mention', 'mention']],
plugins: {
mention: {
source: [
{descr: 'Client Name', code: '#Client_Nom#'},
{descr: 'Client FirstName', code: '#Client_FirstName#'},
],
source: [
{descr: 'Agency name', code: '#Agency_Nom#'},
{descr: 'Agency Adress', code: '#Agency_adress#'},
{descr: 'Agency Postal', code: '#Agency_postal#'},
],
formatDropdownItem: function (item) {
return item.descr;
},
formatResult: function (item) {
return item.code;
}
}
`
The fisrt "btns >mention" should be linked to the first "plugins > mention > source"
And the second "btns >mention" should be linked to the second "plugins > mention > source"
I don't know if it's possible to configure mention plugin like that, or if another plugin is appropriate to that, or if I have to create my own mention plugin.
Thanks a lot for your help