Made strikethrough, highlight, strong, and em greedier

This commit is contained in:
j4nk 2024-02-28 19:14:20 -05:00
parent 0f26ff4a91
commit 0e2d7e7aeb
1 changed files with 4 additions and 4 deletions

View File

@ -63,11 +63,11 @@
"Process all inline elements of the LINE, return HTML."
;; Finally strikethrough
(replace-regexp-in-string
"~~\\(.*\\)~~"
"~~\\(.*?\\)~~"
"<s>\\1</s>"
;; Then highlight
(replace-regexp-in-string
"==\\(.*\\)=="
"==\\(.*?\\)=="
"<mark>\\1</mark>"
;; Then links
(replace-regexp-in-string
@ -83,11 +83,11 @@
(concat (md4tj-begin-tag "video" (list '("src" "\\2") '("type" "video/webm") '("controls" "true"))) "\\1" (md4tj-end-tag "video"))
;; Then emphasis
(replace-regexp-in-string
"\\*\\(.*\\)\\*"
"\\*\\(.*?\\)\\*"
"<em>\\1</em>"
;; Then strong
(replace-regexp-in-string
"\\*\\*\\(.*\\)\\*\\*"
"\\*\\*\\(.*?\\)\\*\\*"
"<strong>\\1</strong>"
;; First code
(replace-regexp-in-string