Skip to content

Commit

Permalink
🗜️ build [skip ci]
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkedJS bot committed Jul 11, 2022
1 parent 01c98d1 commit 9fb5721
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
5 changes: 3 additions & 2 deletions lib/marked.cjs
Expand Up @@ -622,7 +622,8 @@ var Tokenizer = /*#__PURE__*/function () {
if (!endEarly) {
var nextBulletRegex = new RegExp("^ {0," + Math.min(3, indent - 1) + "}(?:[*+-]|\\d{1,9}[.)])((?: [^\\n]*)?(?:\\n|$))");
var hrRegex = new RegExp("^ {0," + Math.min(3, indent - 1) + "}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)");
var fencesBeginRegex = new RegExp("^( {0," + Math.min(3, indent - 1) + "})(```|~~~)"); // Check if following lines should be included in List Item
var fencesBeginRegex = new RegExp("^ {0," + Math.min(3, indent - 1) + "}(?:```|~~~)");
var headingBeginRegex = new RegExp("^ {0," + Math.min(3, indent - 1) + "}#"); // Check if following lines should be included in List Item

while (src) {
rawLine = src.split('\n', 1)[0];
Expand All @@ -638,7 +639,7 @@ var Tokenizer = /*#__PURE__*/function () {
} // End list item if found start of new heading


if (this.rules.block.heading.test(line)) {
if (headingBeginRegex.test(line)) {
break;
} // End list item if found start of new bullet

Expand Down
5 changes: 3 additions & 2 deletions lib/marked.esm.js
Expand Up @@ -536,7 +536,8 @@ class Tokenizer {
if (!endEarly) {
const nextBulletRegex = new RegExp(`^ {0,${Math.min(3, indent - 1)}}(?:[*+-]|\\d{1,9}[.)])((?: [^\\n]*)?(?:\\n|$))`);
const hrRegex = new RegExp(`^ {0,${Math.min(3, indent - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`);
const fencesBeginRegex = new RegExp(`^( {0,${Math.min(3, indent - 1)}})(\`\`\`|~~~)`);
const fencesBeginRegex = new RegExp(`^ {0,${Math.min(3, indent - 1)}}(?:\`\`\`|~~~)`);
const headingBeginRegex = new RegExp(`^ {0,${Math.min(3, indent - 1)}}#`);

// Check if following lines should be included in List Item
while (src) {
Expand All @@ -554,7 +555,7 @@ class Tokenizer {
}

// End list item if found start of new heading
if (this.rules.block.heading.test(line)) {
if (headingBeginRegex.test(line)) {
break;
}

Expand Down
5 changes: 3 additions & 2 deletions lib/marked.umd.js
Expand Up @@ -624,7 +624,8 @@
if (!endEarly) {
var nextBulletRegex = new RegExp("^ {0," + Math.min(3, indent - 1) + "}(?:[*+-]|\\d{1,9}[.)])((?: [^\\n]*)?(?:\\n|$))");
var hrRegex = new RegExp("^ {0," + Math.min(3, indent - 1) + "}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)");
var fencesBeginRegex = new RegExp("^( {0," + Math.min(3, indent - 1) + "})(```|~~~)"); // Check if following lines should be included in List Item
var fencesBeginRegex = new RegExp("^ {0," + Math.min(3, indent - 1) + "}(?:```|~~~)");
var headingBeginRegex = new RegExp("^ {0," + Math.min(3, indent - 1) + "}#"); // Check if following lines should be included in List Item

while (src) {
rawLine = src.split('\n', 1)[0];
Expand All @@ -640,7 +641,7 @@
} // End list item if found start of new heading


if (this.rules.block.heading.test(line)) {
if (headingBeginRegex.test(line)) {
break;
} // End list item if found start of new bullet

Expand Down
2 changes: 1 addition & 1 deletion marked.min.js

Large diffs are not rendered by default.

0 comments on commit 9fb5721

Please sign in to comment.