Page MenuHomePhabricator

Add a warning when <ref> tags are in a message, but no <references /> tag.
Open, Needs TriagePublic

Description

Footnotes are displayed properly (auto-inclusion) on MassMessage preview, via the auto-generated <references />, which may cause issues during the distribution if <references /> is not included manually.

On F5350835, you can see <ref>Reference</ref> in the text, and, in the preview, it shows 1 - Reference as a footnote. However, if I send that message to a page, the footnote will be displayed at the very bottom of that page, which causes issues once another new section is added under the message with the <ref> (the footnote(s) appear to belong to the wrong message).

To avoid that, I would advise to have a message that warns the mass message sender during the Preview stage. Something like:

A <ref> tag is used, but a <references /> tag is missing. To avoid confusion by having footnotes far from the text you are going to send, consider adding a <references group=foo /> tag and group all the references to that, with <ref group=foo>.

Event Timeline

Legoktm subscribed.

I haven't checked yet, but we'll probably need Cite to expose some metadata indicating that the references tag was auto appended. Then we can warn about it in MM.