diff --git a/CHANGES.md b/CHANGES.md index b9bf17528..8a9bf4a40 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -130,6 +130,7 @@ ### Features +- pat-inject: Don't rebase for some additional known prefixes to avoid that the links break when contained in an injected page snippet. - pat-gallery: Allow adding images directly to the gallery. - pat-validation: Allow for HTML5 style `required` attributes without a value. - pat-validation: Added the possibility to check for fields equality diff --git a/src/pat/inject/index.html b/src/pat/inject/index.html index 80791967d..31085e2a8 100644 --- a/src/pat/inject/index.html +++ b/src/pat/inject/index.html @@ -420,7 +420,7 @@

Inject and fix URLs of options

class="pat-inject" data-pat-inject="url:./index.html#rebase-url-demo; target: self::element" > - injection happens here! + injection happens here! Call for help diff --git a/src/pat/inject/inject.js b/src/pat/inject/inject.js index 17fffe0f9..c1af09a7e 100644 --- a/src/pat/inject/inject.js +++ b/src/pat/inject/inject.js @@ -911,6 +911,11 @@ const inject = { value.slice(0, 2) !== "@@" && value[0] !== "#" && value.slice(0, 7) !== "mailto:" && + value.slice(0, 4) !== "tel:" && + value.slice(0, 4) !== "fax:" && + value.slice(0, 7) !== "callto:" && + value.slice(0, 10) !== "ts3server:" && + value.slice(0, 6) !== "teams:" && value.slice(0, 11) !== "javascript:" ) { value = utils.rebaseURL(base, value);