chdemko/pandoc-numbering

View on GitHub
docs/images/pandoc-numbering-sample.html

Summary

Maintainability
Test Coverage
<h1 class="pandoc-numbering-listing example unnumbered unlisted"
id="list-of-examples">List of examples</h1>
<ul>
<li><a href="#example:1.1"><span
class="pandoc-numbering-entry example">Example 1.1</span></a></li>
<li><a href="#example:1.2"><span
class="pandoc-numbering-entry example">Example 1.2</span></a></li>
<li><a href="#example:2.1"><span
class="pandoc-numbering-entry example">Example 2.1</span></a></li>
<li><a href="#example:2.2"><span
class="pandoc-numbering-entry example">Example 2.2</span></a></li>
</ul>
<h1 class="pandoc-numbering-listing exercise unnumbered unlisted"
id="list-of-exercises">List of exercises</h1>
<ul>
<li><a href="#exercise:1"><span
class="pandoc-numbering-entry exercise">Exercise 1</span></a></li>
<li><a href="#exercise:second"><span
class="pandoc-numbering-entry exercise">This is the second
exercise</span></a></li>
<li><a href="#exercise:last"><span
class="pandoc-numbering-entry exercise">Exercise 3</span></a></li>
</ul>
<h1 class="pandoc-numbering-listing theorem unnumbered unlisted"
id="list-of-theorems">List of theorems</h1>
<ul>
<li><a href="#theorem:first"><span
class="pandoc-numbering-entry theorem">Needed for the <span>second
exercise</span></span></a></li>
<li><a href="#theorem:2.1"><span
class="pandoc-numbering-entry theorem"><span
class="math inline"><em>a</em> = <em>b</em></span></span></a></li>
<li><a href="#theorem:2.2"><span
class="pandoc-numbering-entry theorem">Theorem 2.2</span></a></li>
</ul>
<h1 id="this-is-the-first-section">This is the first section</h1>
<p><span></span><span id="exercise:1"
class="pandoc-numbering-text exercise"><strong>Exercise
1</strong></span></p>
<p>This is the first exercise. Have also a look at the <a
href="#theorem:first"
title="Theorem 1.1 (Needed for the second exercise)"><span
class="pandoc-numbering-link theorem">Theorem 1.1 (Needed for the
<span>second exercise</span>)</span></a>, the <a href="#exercise:second"
title="Exercise 2 (This is the second exercise)"><span
class="pandoc-numbering-link exercise">Exercise 2 (This is the second
exercise)</span></a> and the <a href="#exercise:last"
title="Exercise 3"><span class="pandoc-numbering-link exercise">Exercise
3</span></a>.</p>
<blockquote>
<p><span
id="theorem:this-is-the-first-section.needed-for-the-second-exercise"></span><span
id="theorem:first" class="pandoc-numbering-text theorem"><em>Theorem
1.1: Needed for the <a href="#exercise:second">second
exercise</a></em></span></p>
<p>This is a the first theorem. Look at the <a href="#exercise:second"
title="Go to the exercise 2">exercise</a>.</p>
</blockquote>
<p><span id="exercise:this-is-the-second-exercise"></span><span
id="exercise:second"
class="pandoc-numbering-text exercise"><strong>Exercise 2</strong>
<em>(This is the second exercise)</em></span></p>
<p>Use <a href="#theorem:first"><em>theorem 1.1</em> page %p</a></p>
<dl>
<dt><span id="example:this-is-the-first-section.1"></span><span
id="example:1.1" class="pandoc-numbering-text example"><strong>Example
1</strong></span></dt>
<dd>
This is the first example of the first section
</dd>
<dt><span id="example:this-is-the-first-section.2"></span><span
id="example:1.2" class="pandoc-numbering-text example"><strong>Example
2</strong></span></dt>
<dd>
This is the second example of the first section
</dd>
</dl>
<h1 id="this-is-the-second-section">This is the second section</h1>
<dl>
<dt><span id="example:this-is-the-second-section.1"></span><span
id="example:2.1" class="pandoc-numbering-text example"><strong>Example
1</strong></span></dt>
<dd>
This is the first example of the second section
</dd>
</dl>
<blockquote>
<p><span id="theorem:this-is-the-second-section.a-b"></span><span
id="theorem:2.1" class="pandoc-numbering-text theorem"><em>Theorem 2.1:
<span class="math inline"><em>a</em> = <em>b</em></span></em></span></p>
<p>Another theorem. Can be useful in <a href="#exercise:1"></a></p>
</blockquote>
<blockquote>
<p><span id="theorem:this-is-the-second-section.2"></span><span
id="theorem:2.2" class="pandoc-numbering-text theorem"><em>Theorem
2.2</em></span></p>
<p>A last theorem.</p>
</blockquote>
<dl>
<dt><span id="example:this-is-the-second-section.2"></span><span
id="example:2.2" class="pandoc-numbering-text example"><strong>Example
2</strong></span></dt>
<dd>
This is the second example of the second section
</dd>
</dl>
<p><span id="exercise:3"></span><span id="exercise:last"
class="pandoc-numbering-text exercise"><strong>Exercise
3</strong></span></p>
<p>This is the third exercise.</p>
<p>Unnumbered #</p>