Fix CSL citation ordering in footnotes#14313
Conversation
Hey @marifer-perezh!Thank you for contributing to JabRef! Your help is truly appreciated ❤️. We have automatic checks in place, based on which you will soon get automated feedback if any of them are failing. We also use TragBot with custom rules that scans your changes and provides some preliminary comments, before a maintainer takes a look. TragBot is still learning, and may not always be accurate. In the "Files changed" tab, you can go through its comments and just click on "Resolve conversation" if you are sure that it is incorrect, or comment on the conversation if you are doubtful. Please re-check our contribution guide in case of any other doubts related to our contribution workflow. |
|
Your code currently does not meet JabRef's code guidelines. We use Checkstyle to identify issues. You can see which checks are failing by locating the box "Some checks were not successful" on the pull request page. To see the test output, locate "Source Code Tests / Checkstyle (pull_request)" and click on it. In case of issues with the import order, double check that you activated Auto Import. You can trigger fixing imports by pressing Ctrl+Alt+O to trigger Optimize Imports. Please carefully follow the setup guide for the codestyle. Afterwards, please run checkstyle locally and fix the issues, commit, and push. |
|
Your entire steps to test description is AI generated |
Closes #12484
Reworked CSL reference mark sorting to build partition-aware range entries and remap footnote citations to their footnote markers before ordering, ensuring numbering reflects footnote placement.
Added comparison logic that uses in-text ordering when possible and falls back to partition indices so citations within the same footnote keep their textual sequence
Steps to test
####Automated verification
####Manual verification in LibreOffice
Mandatory checks
CHANGELOG.mdin a way that is understandable for the average user (if change is visible to the user)