This issue has been created
 
 
XWiki Rendering / cid:jira-generated-image-avatar-8259cc2a-1ec3-4365-8483-7db81858c8ec XRENDERING-829 Open

A putFootnotes macro in a list item breaks the footnotes of the page

 
View issue   ยท   Add comment
 

Issue created

 
cid:jira-generated-image-avatar-19c623bd-dcbc-4647-8d26-1c994299c1b6 Charpentier Lucas created this issue on 23/Oct/26 13:44
 
Summary: A putFootnotes macro in a list item breaks the footnotes of the page
Issue Type: cid:jira-generated-image-avatar-8259cc2a-1ec3-4365-8483-7db81858c8ec Bug
Affects Versions: 17.10.14, 18.8.0
Assignee: Unassigned
Components: Macro - Footnotes
Created: 23/Oct/26 13:44
Priority: cid:jira-generated-image-static-major-33ee3b18-b5ad-4cca-9388-b54980fe0ce4 Major
Reporter: Charpentier Lucas
Description:

When the putFootnotes macro is placed in a list item or a table cell, it fails with "The [putFootnotes] macro is a standalone macro and it cannot be used inline.", and the footnotes of the whole page break with it: since the page has a putFootnotes macro, the footnote macro does not add the list of footnotes at the end of the page, and the text of each footnote is rendered inside the sentence, with no number and no link.

Steps to reproduce

  1. Edit a page in the wiki editor with this content:
    A{{footnote}}N1{{/footnote}}.
    
    * one
    * {{putFootnotes/}}
    
  2. View the page.
  • Expected: a footnote number after "A" and the list of footnotes, either where putFootnotes is or at the end of the page.
  • Actual: "AN1.", the footnote text glued to the sentence, then the standalone error in the list.

The fix is in FootnoteMacro.java and PutFootnotesMacro.java: a putFootnotes macro that fails should not prevent the footnotes from being listed, for example by adding them at the end of the page as when there is no putFootnotes macro. XWIKI-23501 covers the standalone error itself.

KOs covered

Macro Criterion Problem
putFootnotes E3 nesting In a list item or a table cell the macro fails with the standalone error, and the footnotes of the page break too: none is listed at the end and their text is glued to the sentence.

Impact found on macro fluidity

This KO comes from the WYSIWYG usability audit of the macros, under the criterion E3 nesting of its usability criteria. The page of the macro, linked in the table, has the full notes and the steps to reproduce.