Skip to content

Commit 2cb2f7c

Browse files
committed
Added test example that exercises a single footnote being referenced in multiple places and multiple backrefs.
1 parent 272c999 commit 2cb2f7c

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

test/extensions.txt

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -702,6 +702,26 @@ Hi!
702702
</section>
703703
````````````````````````````````
704704

705+
## When a footnote is used multiple times, we insert multiple backrefs.
706+
707+
```````````````````````````````` example
708+
This is some text. It has a footnote[^a-footnote].
709+
710+
This footnote is referenced[^a-footnote] multiple times, in lots of different places.[^a-footnote]
711+
712+
[^a-footnote]: This footnote definition should have three backrefs.
713+
.
714+
<p>This is some text. It has a footnote<sup class="footnote-ref"><a href="#fn:a-footnote" id="fnref:a-footnote">1</a></sup>.</p>
715+
<p>This footnote is referenced<sup class="footnote-ref"><a href="#fn:a-footnote" id="fnref:a-footnote:2">1</a></sup> multiple times, in lots of different places.<sup class="footnote-ref"><a href="#fn:a-footnote" id="fnref:a-footnote:3">1</a></sup></p>
716+
<section class="footnotes">
717+
<ol>
718+
<li id="fn:a-footnote">
719+
<p>This footnote definition should have three backrefs. <a href="#fnref:a-footnote" class="footnote-backref">↩</a> <a href="#fnref:a-footnote:2" class="footnote-backref">↩<sup class="footnote-ref">2</sup></a> <a href="#fnref:a-footnote:3" class="footnote-backref">↩<sup class="footnote-ref">3</sup></a></p>
720+
</li>
721+
</ol>
722+
</section>
723+
````````````````````````````````
724+
705725
## Interop
706726

707727
Autolink and strikethrough.

0 commit comments

Comments
 (0)