5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2024-11-25 10:06:37 +00:00

no filtrar información a direcciones externas

ni permitirles modificar la ventana de origen
This commit is contained in:
f 2020-09-15 12:12:05 -03:00
parent bc5ac322f7
commit 6d3b2dac16
2 changed files with 7 additions and 6 deletions

View file

@ -1,5 +1,6 @@
$(document).on('turbolinks:load', function() {
$("a[href^='http://']").attr('target', '_blank');
$("a[href^='https://']").attr('target', '_blank');
$("a[href^='//']").attr('target', '_blank');
});
document.addEventListener('turbolinks:load', () => {
document.querySelectorAll("a[href^='http://'],a[href^='https://'],a[href^='//']").forEach(a => {
a.rel = "noopener"
a.target = "_blank"
})
})

View file

@ -7,7 +7,7 @@
%meta{ name: 'color-scheme', content: 'light dark' }/
%meta{ name: 'viewport',
content: 'width=device-width, initial-scale=1.0' }/
%meta{ name: 'referrer', content: 'origin' }/
%meta{ name: 'referrer', content: 'same-origin' }/
%title Sutty