DEV: Update markdown-it from 8.4.1 to 10.0.0 (#8164)

DEV: Update markdown-it from 8.4.1 to 10.0.0 (#8164)

diff --git a/package.json b/package.json
index bade0b9..b6cf230 100644
--- a/package.json
+++ b/package.json
@@ -23,7 +23,7 @@
     "jquery.autoellipsis": "https://github.com/pvdspek/jquery.autoellipsis",
     "jquery.cookie": "1.4.1",
     "magnific-popup": "1.1.0",
-    "markdown-it": "8.4.1",
+    "markdown-it": "10.0.0",
     "moment": "2.24.0",
     "moment-timezone": "0.5.25",
     "moment-timezone-names-translations": "https://github.com/discourse/moment-timezone-names-translations",
diff --git a/spec/fixtures/md/spec.txt b/spec/fixtures/md/spec.txt
index 08ce0a5..50a660f 100644
--- a/spec/fixtures/md/spec.txt
+++ b/spec/fixtures/md/spec.txt
@@ -1,8 +1,8 @@
 ---
 title: CommonMark Spec
 author: John MacFarlane
-version: 0.28
-date: '2017-08-01'
+version: 0.29
+date: '2019-04-06'
 license: '[CC-BY-SA 4.0](http://creativecommons.org/licenses/by-sa/4.0/)'
 ...
 
@@ -248,7 +248,7 @@ satisfactory replacement for a spec.
 
 Because there is no unambiguous spec, implementations have diverged
 considerably.  As a result, users are often surprised to find that
-a document that renders one way on one system (say, a github wiki)
+a document that renders one way on one system (say, a GitHub wiki)
 renders differently on another (say, converting to docbook using
 pandoc).  To make matters worse, because nothing in Markdown counts
 as a "syntax error," the divergence often isn't discovered right away.
@@ -326,10 +326,15 @@ A [space](@) is `U+0020`.
 A [non-whitespace character](@) is any character
 that is not a [whitespace character].
 
+An [ASCII control character](@) is a character between `U+0000–1F` (both
+including) or `U+007F`.
+
 An [ASCII punctuation character](@)
 is `!`, `"`, `#`, `$`, `%`, `&`, `'`, `(`, `)`,
-`*`, `+`, `,`, `-`, `.`, `/`, `:`, `;`, `<`, `=`, `>`, `?`, `@`,
-`[`, `\`, `]`, `^`, `_`, `` ` ``, `{`, `|`, `}`, or `~`.
+`*`, `+`, `,`, `-`, `.`, `/` (U+0021–2F), 
+`:`, `;`, `<`, `=`, `>`, `?`, `@` (U+003A–0040),
+`[`, `\`, `]`, `^`, `_`, `` ` `` (U+005B–0060), 
+`{`, `|`, `}`, or `~` (U+007B–007E).
 
 A [punctuation character](@) is an [ASCII
 punctuation character] or anything in
@@ -476,2173 +481,2545 @@ bar
 For security reasons, the Unicode character `U+0000` must be replaced
 with the REPLACEMENT CHARACTER (`U+FFFD`).
 
-# Blocks and inlines
-
-We can think of a document as a sequence of
-[blocks](@)---structural elements like paragraphs, block
-quotations, lists, headings, rules, and code blocks.  Some blocks (like
-block quotes and list items) contain other blocks; others (like
-headings and paragraphs) contain [inline](@) content---text,
-links, emphasized text, images, code spans, and so on.
 
-## Precedence
+## Backslash escapes
 
-Indicators of block structure always take precedence over indicators
-of inline structure.  So, for example, the following is a list with
-two items, not a list with one item containing a code span:
+Any ASCII punctuation character may be backslash-escaped:
 
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍```` example
-- `one
-- two`
+\!\"\#\$\%\&\'\(\)\*\+\,\-\.\/\:\;\<\=\>\?\@\[\\\]\^\_\`\{\|\}\~
 .
-<ul>
-<li>`one</li>
-<li>two`</li>
-</ul>
+<p>!&quot;#$%&amp;'()*+,-./:;&lt;=&gt;?@[\]^_`{|}~</p>
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍````
 
 
-This means that parsing can proceed in two steps:  first, the block
-structure of the document can be discerned; second, text lines inside
-paragraphs, headings, and other block constructs can be parsed for inline
-structure.  The second step requires information about link reference
-definitions that will be available only at the end of the first
-step.  Note that the first step requires processing lines in sequence,
-but the second can be parallelized, since the inline parsing of
-one block element does not affect the inline parsing of any other.
-
-## Container blocks and leaf blocks
-
-We can divide blocks into two types:
-[container block](@)s,
-which can contain other blocks, and [leaf block](@)s,
-which cannot.
-
-# Leaf blocks
+Backslashes before other characters are treated as literal
+backslashes:
 
-This section describes the different kinds of leaf block that make up a
-Markdown document.
+`‍```‍```‍```‍```‍```‍```‍```‍```‍```‍```` example
+\→\A\a\ \3\φ\«
+.
+<p>\→\A\a\ \3\φ\«</p>
+`‍```‍```‍```‍```‍```‍```‍```‍```‍```‍````
 
-## Thematic breaks
 
-A line consisting of 0-3 spaces of indentation, followed by a sequence
-of three or more matching `-`, `_`, or `*` characters, each followed
-optionally by any number of spaces or tabs, forms a
-[thematic break](@).
+Escaped characters are treated as regular characters and do
+not have their usual Markdown meanings:
 
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍```` example
-***
----
-___
+\*not emphasized*
+\<br/> not a tag
+\[not a link](/foo)
+\`not code`
+1\. not a list
+\* not a list
+\# not a heading
+\[foo]: /url "not a reference"
+\&ouml; not a character entity
 .
-<hr />
-<hr />
-<hr />
+<p>*not emphasized*
+&lt;br/&gt; not a tag
+[not a link](/foo)
+`not code`
+1. not a list
+* not a list
+# not a heading
+[foo]: /url &quot;not a reference&quot;
+&amp;ouml; not a character entity</p>
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍````
 
 
-Wrong characters:
+If a backslash is itself escaped, the following character is not:
 
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍```` example
-+++
+\\*emphasis*
 .
-<p>+++</p>
+<p>\<em>emphasis</em></p>
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍````
 
 
+A backslash at the end of the line is a [hard line break]:
+
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍```` example
-===
+foo\
+bar
 .
-<p>===</p>
+<p>foo<br />
+bar</p>
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍````
 
 
-Not enough characters:
+Backslash escapes do not work in code blocks, code spans, autolinks, or
+raw HTML:
 
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍```` example
---
-**
-__
+`` \[\` ``
 .
-<p>--
-**
-__</p>
+<p><code>\[\`</code></p>
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍````
 
 
-One to three spaces indent are allowed:
-
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍```` example
- ***
-  ***
-   ***
+    \[\]
 .
-<hr />
-<hr />
-<hr />
+<pre><code>\[\]
+</code></pre>
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍````
 
 
-Four spaces is too many:
-
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍```` example
-    ***
+~~~
+\[\]
+~~~
 .
-<pre><code>***
+<pre><code>\[\]
 </code></pre>
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍````
 
 
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍```` example
-Foo
-    ***
+<http://example.com?find=\*>
 .
-<p>Foo
-***</p>
+<p><a href="http://example.com?find=%5C*">http://example.com?find=\*</a></p>
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍````
 
 
-More than three characters may be used:
-
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍```` example
-_____________________________________
+<a href="/bar\/)">
 .
-<hr />
+<a href="/bar\/)">
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍````
 
 
-Spaces are allowed between the characters:
+But they work in all other contexts, including URLs and link titles,
+link references, and [info strings] in [fenced code blocks]:
 
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍```` example
- - - -
+[foo](/bar\* "ti\*tle")
 .
-<hr />
+<p><a href="/bar*" title="ti*tle">foo</a></p>
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍````
 
 
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍```` example
- **  * ** * ** * **
+[foo]
+
+[foo]: /bar\* "ti\*tle"
 .
-<hr />
+<p><a href="/bar*" title="ti*tle">foo</a></p>
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍````
 
 
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍```` example
--     -      -      -
+`‍`` foo\+bar
+foo
+`‍``
 .
-<hr />
+<pre><code class="language-foo+bar">foo
+</code></pre>
 `‍```‍```‍```‍```‍```‍```‍```‍```‍```‍````
 
 
-Spaces are allowed at the end:
+## Entity and numeric character references
 
-`‍```‍```‍```‍```‍```‍```‍```‍```‍```‍```` example
-- - - -    
-.
-<hr />
-`‍```‍```‍```‍```‍```‍```‍```‍```‍```‍````
+Valid HTML entity references and numeric character references
+can be used in place of the corresponding Unicode character,
+with the following exceptions:
 
+- Entity and character references are not recognized in code
+  blocks and code spans.
 
-However, no other characters may occur in the line:
+- Entity and character references cannot stand in place of
+  special characters that define structural elements in
+  CommonMark.  For example, although `&#42;` can be used

[... diff too long, it was truncated ...]

GitHub sha: 20514f2e