GitHub CSS for `[` and `]` around footnote calls interfering with user content
wooorm opened this issue · 2 comments
wooorm commented
(Note: this is more an issue with GH CSS rather than cmark-gfm
or GFM)
Users are able to write HTML in markdown on GitHub. For example:
Hi, <sup><a href="#">world</a></sup>
The new footnotes use similar markup and use CSS to add brackets around footnote:
.markdown-body sup > a::before {
content: "[";
}
.markdown-body sup > a::after {
content: "]";
}
This results in the previous markdown being rendered as:
Hi, world
Would it perhaps make sense to use:
[data-footnote-ref]::before {
content: "[";
}
[data-footnote-ref]::after {
content: "]";
}
nylen commented
I noticed the same issue while writing ClassicPress/ClassicPress#791 (comment).
wooorm commented
I guess this was fixed? GH’s CSS seems to include what I proposed. Closing.