hellux/jotdown

Ambiguity between alphabetical and Roman numeral lists

Closed this issue · 3 comments

Hi, great work with this library!

I've hit this bug in the list parsing: alphabetical lists are parsed correctly until C and D where they become Roman numeral lists. Those characters are ambiguous, so a little context is needed to know what kind of list item they are.

Example input:

A) first
B) second
C) third
D) fourth
E) fifth

Output:

<ol type="A">
<li>
first
</li>
<li>
second
</li>
</ol>
<ol start="100" type="I">
<li>
third
</li>
<li>
fourth
</li>
</ol>
<ol start="5" type="A">
<li>
fifth
</li>
</ol>
A) first
B) second
C) third
CI) fourth
E) fifth

fixed as of version 0.4.0

Thanks!