Changes for page MentionsMacro

Last modified by Ludovic Dubost on 2024/07/22 15:59

From version 4.1
edited by Ludovic Dubost
on 2022/08/01 13:48
Change comment: Migrated property [defaultCategories] from class [XWiki.WikiMacroClass]
To version 1.1
edited by Ludovic Dubost
on 2021/02/05 15:07
Change comment: Install extension [org.xwiki.platform:xwiki-platform-mentions-ui/12.10.2]

Summary

Details

XWiki.JavaScriptExtension[0]
Code
... ... @@ -1,6 +1,7 @@
1 1  require.config({
2 2   paths: {
3 - 'xwiki-suggestUsers': $jsontool.serialize($xwiki.getSkinFile('uicomponents/suggest/suggestUsersAndGroups.js', true))
3 + 'xwiki-suggestUsers': "$xwiki.getSkinFile('uicomponents/suggest/suggestUsersAndGroups.js', true))" +
4 + "?v=$escapetool.url($xwiki.version)"
4 4   }
5 5  });
6 6  require(['deferred!ckeditor', 'xwiki-suggestUsers', 'jquery', 'xwiki-meta'], function (ckeditorPromise, suggestUsers, $, xm) {
... ... @@ -82,7 +82,7 @@
82 82   editor.once('afterInsertHtml', function () {
83 83   editor.execCommand('xwiki-macro-insert', {
84 84   name: 'mention',
85 - inline: 'enforce',
86 + inline: true,
86 86   parameters: {
87 87   reference: param.id,
88 88   style: 'FULL_NAME',
... ... @@ -98,7 +98,7 @@
98 98   }
99 99  
100 100   function updateConf(config, name) {
101 - const newConf = config || {};
102 + const newConf = config;
102 102   newConf.mentions = newConf.mentions || [];
103 103   newConf.mentions.push(confMentions(name));
104 104   return newConf;
XWiki.WikiMacroClass[0]
Default category
... ... @@ -1,1 +1,0 @@
1 -Notifications
Macro description
... ... @@ -1,1 +1,1 @@
1 -Inserts a user mention.
1 +Insert a user mention.