diff options
author | 2021-05-28 00:17:39 +0200 | |
---|---|---|
committer | 2021-07-24 00:23:17 +0000 | |
commit | eee1d1483d8e3ebd467d37de1011492ed555e571 (patch) | |
tree | f73b9a0abf991fda83a1183f96c907c183d52dd2 /recipes/fastmail/webview-unsafe.js | |
parent | [googledrive] Context isolation support (diff) | |
download | ferdium-recipes-eee1d1483d8e3ebd467d37de1011492ed555e571.tar.gz ferdium-recipes-eee1d1483d8e3ebd467d37de1011492ed555e571.tar.zst ferdium-recipes-eee1d1483d8e3ebd467d37de1011492ed555e571.zip |
[fastmail] Context isolation support
Diffstat (limited to 'recipes/fastmail/webview-unsafe.js')
-rw-r--r-- | recipes/fastmail/webview-unsafe.js | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/recipes/fastmail/webview-unsafe.js b/recipes/fastmail/webview-unsafe.js new file mode 100644 index 0000000..7588988 --- /dev/null +++ b/recipes/fastmail/webview-unsafe.js | |||
@@ -0,0 +1,10 @@ | |||
1 | const interval = setInterval(() => { | ||
2 | if (!window.O || !window.O.WindowController) return; | ||
3 | window.O.WindowController.openExternal = function (href) { | ||
4 | const temp = document.createElement('a'); | ||
5 | temp.setAttribute('href', href); | ||
6 | temp.setAttribute('target', '_blank'); | ||
7 | temp.click(); | ||
8 | }; | ||
9 | clearInterval(interval); | ||
10 | }, 200); | ||