This issue has been created
 
 
XWiki Platform / cid:jira-generated-image-avatar-c544d5e9-38cf-45e6-a994-b401105a55e6 XWIKI-24087 Open

Inconsistent 'Language' field value when inserting Code Macro in different ways

 
View issue   ยท   Add comment
 

Issue created

 
cid:jira-generated-image-avatar-a238eb98-91a7-461e-8d75-85ae7a9baeb8 Ilie Andriuta created this issue on 05/Mar/26 16:34
 
Summary: Inconsistent 'Language' field value when inserting Code Macro in different ways
Issue Type: cid:jira-generated-image-avatar-c544d5e9-38cf-45e6-a994-b401105a55e6 Bug
Affects Versions: 17.10.3
Assignee: Unassigned
Attachments: Code_Language.png
Components: Rendering - Code Macro
Created: 05/Mar/26 16:34
Environment: Windows 11 Pro, Firefox 148, using an instance of XWiki 17.10.4 on Oracle 19c, Tomcat 11, Java 21
Priority: cid:jira-generated-image-static-major-8331ce54-7ce2-4478-b5ab-41851c6979da Major
Reporter: Ilie Andriuta
Description:

Steps to reproduce

  1. Edit a page with CKEditor
  2. Type / to trigger Quick Actions, then type "code"
  3. Select 'Code Snippet'
  4. Observe the Language field
  5. From the toolbar, click 'Insert' > 'Code Snippet'
  6. Observe the Language field
  7. From the toolbar, click 'Insert' > 'Other Macros' > 'Code'
  8. Observe the Language field

Expected results

The 'Language' field value is consistent (taking into consideration the autodetection feature of the Code Macro).

Actual results

When the Code Macro is inserted via Quick Actions or from the toolbar by clicking 'Insert' > 'Code Snippet', the 'Language' field is 'none', but when the macro is inserted from 'Insert' > 'Other Macros' > 'Code' or just pasted as {{code}}{{/code}} in Source mode, the 'Language' field is empty.