fix: fix stong and em tokens in angle brackets (#3731)

This commit is contained in:
Tony Brix
2025-07-18 08:46:21 -06:00
committed by GitHub
parent eb3ad1a21f
commit ad8535c3ad
3 changed files with 3 additions and 1 deletions
+1 -1
View File
@@ -267,7 +267,7 @@ const _punctuationOrSpaceGfmStrongEm = /(?!~)[\s\p{P}\p{S}]/u;
const _notPunctuationOrSpaceGfmStrongEm = /(?:[^\s\p{P}\p{S}]|~)/u;
// sequences em should skip over [title](link), `code`, <html>
const blockSkip = /\[[^[\]]*?\]\((?:\\.|[^\\\(\)]|\((?:\\.|[^\\\(\)])*\))*\)|`[^`]*?`|<[^<>]*?>/g;
const blockSkip = /\[[^[\]]*?\]\((?:\\.|[^\\\(\)]|\((?:\\.|[^\\\(\)])*\))*\)|`[^`]*?`|<(?! )[^<>]*?>/g;
const emStrongLDelimCore = /^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/;
+1
View File
@@ -0,0 +1 @@
<p>1 &lt; 2 <strong>OR</strong> 4 &gt; 3</p>
+1
View File
@@ -0,0 +1 @@
1 < 2 **OR** 4 > 3