git.99rst.org
/
flatnotes.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
| inline |
side by side
(parent:
c4dc61c
)
#310 Update wikilink regex to ignore empty brackets
author
Adam Dullage
<redacted>
Wed, 21 May 2025 11:41:21 +0000
(12:41 +0100)
committer
Adam Dullage
<redacted>
Wed, 21 May 2025 11:41:21 +0000
(12:41 +0100)
client/components/toastui/extendedAutolinks.js
patch
|
blob
|
history
diff --git
a/client/components/toastui/extendedAutolinks.js
b/client/components/toastui/extendedAutolinks.js
index 7e2c73f214b36dcbd517c2db406b996a86a52fce..ef2fd51b50ce38c172053767cdb9c24cac605004 100644
(file)
--- a/
client/components/toastui/extendedAutolinks.js
+++ b/
client/components/toastui/extendedAutolinks.js
@@
-76,7
+76,7
@@
export function parseUrlLink(source) {
// end of raw toast-ui source
function parseWikiLink(source) {
- const matched = source.matchAll(/\[\[
(.*?)
\]\]/g);
+ const matched = source.matchAll(/\[\[
\s*(\S(?:[^\[\]]*?\S)?)\s*
\]\]/g);
if (matched) {
return Array.from(matched).map((match) => {
const text = match[1];
git clone https://git.99rst.org/PROJECT