Context:
To allow localization and customization of footnotes and backlink markers Parsoid introduced CSS counter-styles, while on the HTML output it's emitting only integer numbers in both cases. Parsoid should instead emit the literal text such as [3], [٣] or a according to content language, custom group or backlink marker configuration. This is already how the legacy parser works.
Many sites currently need to set these CSS customizations so that their Parsoid output aligns with the legacy output. These customizations need to be considered when migrating. When this epic is complete, the CSS customizations could be removed while having the parsers aligned on the footnote and backlink rendering outputs.
Motivations:
- Makes it possible to do localization and alternative counter markers along with programmatic document rendering.
- Consolidate to a single mechanism.
- Plaintext compatibility (eg. copy and paste).
- Consistency in VE (TBD: explain in more detail)
- Prerequisite implement sub-referencing
Historical notes:
- The legacy Cite parser has always used explicit numbering.
- T156351: Add wiki-specific CSS styles for Parsoid Cite output so that it renders exactly like core Cite output
- CSS counter-reset numbering was first introduced into Parsoid in T86782: Use CSS to style Parsoid's Cite extension output to work around customization. At the time, Parsoid was written in JS and couldn't conveniently tap into the PHP i18n which provides custom numbering.
Out of scope: some related tasks will be implemented separately. Experience gained during this task can be applied to the other issues, we'll refine the other tasks' descriptions to add this info.