]> Lady’s Gitweb - LesML/blobdiff - README.markdown
Add support for footnotes
[LesML] / README.markdown
index ac2d0dc5b89facc1fbea5275baed244f33140145..35f5a53727f6b3adbcccf1eacb4b363010c29d9d 100644 (file)
@@ -132,25 +132,25 @@ After this classification, each ordinary paragraph is further
     (`<html:h4>`).
 
 - If the paragraph begins with `•` or `🔢`, it is a primary unordered
-    or ordered list item (`<html:li class="unordered" data-level="1">`
-    or `<html:li class="ordered" data-level="1">`).
+    or ordered list item (`<html:li class="unordered" aria-level="1">`
+    or `<html:li class="ordered" aria-level="1">`).
 
 - If the paragraph begins with `◦` or `🔠`, it is a secondary unordered
-    or ordered list item (`<html:li class="unordered" data-level="2">`
-    or `<html:li class="ordered" data-level="2">`).
+    or ordered list item (`<html:li class="unordered" aria-level="2">`
+    or `<html:li class="ordered" aria-level="2">`).
   Secondary list items are considered to be nested inside of primary
     list items which precede them.
 
 - If the paragraph begins with `▪` or `🔡`, it is a tertiary unordered
-    or ordered list item (`<html:li class="unordered" data-level="3">`
-    or `<html:li class="ordered" data-level="3">`).
+    or ordered list item (`<html:li class="unordered" aria-level="3">`
+    or `<html:li class="ordered" aria-level="3">`).
   Tertiary list items are considered to be nested inside of primary
     and secondary list items which precede them.
 
 - If the paragraph begins with `⁃` or `🔣`, it is a quaternary
     unordered or ordered list item
-    (`<html:li class="unordered" data-level="4">` or
-    `<html:li class="ordered" data-level="4">`).
+    (`<html:li class="unordered" aria-level="4">` or
+    `<html:li class="ordered" aria-level="4">`).
   Quaternary list items are considered to be nested inside of primary,
     secondary, and tertiary list items which precede them.
 
@@ -169,15 +169,30 @@ After this classification, each ordinary paragraph is further
 - If the paragraph begins with `⚠︎`, it is a warning note
     (`<html:div role="note" class="warn">`).
 
+- If the paragraph begins with `^`, it is a footnote
+    (`<html:li class="ordered footnote" aria-level="1">`).
+  Footnotes are ignored unless their first paragraph has an i·d
+    (specified with `¶`) which is referenced by one or more footnote
+    references.
+  Footnotes are treated as level 1 ordered list items, so they can
+    contain nested lists.
+
+  Footnotes are removed from the normal document flow and placed in a
+    footer (`<html:section role="doc-endnotes">`) in order of first
+    reference.
+  It is recommended that the i·d¦s you choose are kept stable, so that
+    links to footnotes do not break.
+
 - If the paragraph begins with `#`, it is a comment.
   Comments produce X·M·L comment nodes and can be used to break up list
     items into separate lists.
 
 - If the paragraph begins with `⋯`, it is a continuation paragraph.
-  Continuation paragraphs may be used to continue a preceding div or
-    list item.
-  If there is no such preceding div or list item, they will attach to
-    adjacent heading elements to form heading groups (`<html:hgroup>`).
+  Continuation paragraphs may be used to continue a preceding note,
+    footnote, or list item.
+  If there is no such preceding note, footnote, or list item, they will
+    attach to adjacent heading elements to form heading groups
+    (`<html:hgroup>`).
   Otherwise, they will be treated as ordinary paragraphs.
 
 - Otherwise, it is an ordinary paragraph.
@@ -242,6 +257,11 @@ Markup within paragraphs is delimited with·out exception by pairs of
 
 - The characters `⹐` and `⹑` indicate emphasis (`<html:em>`).
 
+- The characters `^` and `.` indicate a footnote reference
+    (`<html:a role="doc-noteref">`).
+  The characters between these sigils must match the i·d of the first
+    paragraph of some footnote in the same document.
+
 Once the tree is built as above, it is remediated into its final form
   by the following steps :⁠—
 
This page took 0.028938 seconds and 4 git commands to generate.