1
0
Fork 0
mirror of https://github.com/M66B/FairEmail.git synced 2025-03-03 10:16:45 +00:00

Decrypt: confirm opening links

This commit is contained in:
M66B 2022-10-19 13:37:41 +02:00
parent 6d7f36f2c8
commit 11c2b50977

View file

@ -128,6 +128,17 @@
form.password.value = ''; form.password.value = '';
message.innerHTML = clean; message.innerHTML = clean;
var a = message.getElementsByTagName('a');
for (let i = 0; i < a.length; i++)
if (a[i].href) {
a[i].rel = 'noopener noreferrer';
a[i].setAttribute('target', '_blank');
a[i].onclick = function() {
return confirm('Go to ' + a[i].href + ' ?');
};
}
form.style.display = 'none'; form.style.display = 'none';
content.style.display = 'block'; content.style.display = 'block';
} catch (e) { } catch (e) {