1
0
mirror of https://github.com/BoostIo/Boostnote synced 2025-12-13 01:36:22 +00:00

disable hyperlink for attachments

This commit is contained in:
Baptiste Augrain
2018-10-08 16:04:16 +02:00
parent 2ccd00a378
commit 944c79ec61

View File

@@ -52,7 +52,8 @@
if (className.indexOf('cm-url') !== -1) {
const match = /^\((.*)\)|\[(.*)\]|(.*)$/.exec(el.textContent)
return match[1] || match[2] || match[3]
const url = match[1] || match[2] || match[3]
return /^:storage\//.test(url) ? null : url
}
return null