mirror of
https://gitdab.com/cadence/out-of-your-element.git
synced 2025-09-10 12:22:50 +02:00
Consistently add @ to m->d matrix mentions
This commit is contained in:
parent
f9eb043c10
commit
2c3b653b54
2 changed files with 2 additions and 2 deletions
|
@ -129,7 +129,7 @@ turndownService.addRule("inlineLink", {
|
|||
const href = node.getAttribute("href")
|
||||
content = content.replace(/ @.*/, "")
|
||||
if (href === content) return href
|
||||
if (href.startsWith("https://matrix.to/#/@") && content[0] !== "@") content = "@" + content
|
||||
if (decodeURIComponent(href).startsWith("https://matrix.to/#/@") && content[0] !== "@") content = "@" + content
|
||||
return "[" + content + "](" + href + ")"
|
||||
}
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue