Bladeren bron

Make links open in a new tab

master
Fen Dweller 4 jaren geleden
bovenliggende
commit
a1958bf55b
1 gewijzigde bestanden met toevoegingen van 8 en 0 verwijderingen
  1. +8
    -0
      macrovision.js

+ 8
- 0
macrovision.js Bestand weergeven

@@ -1767,6 +1767,8 @@ function displayAttribution(file) {
const link = document.createElement("a"); const link = document.createElement("a");
link.href = author.url; link.href = author.url;
link.innerText = author.name; link.innerText = author.name;
link.rel = "noreferrer no opener";
link.target = "_blank";
authorEntry.appendChild(link); authorEntry.appendChild(link);
} else { } else {
const div = document.createElement("div"); const div = document.createElement("div");
@@ -1799,6 +1801,8 @@ function displayAttribution(file) {
const link = document.createElement("a"); const link = document.createElement("a");
link.href = owner.url; link.href = owner.url;
link.innerText = owner.name; link.innerText = owner.name;
link.rel = "noreferrer no opener";
link.target = "_blank";
ownerEntry.appendChild(link); ownerEntry.appendChild(link);
} else { } else {
const div = document.createElement("div"); const div = document.createElement("div");
@@ -1823,6 +1827,8 @@ function displayAttribution(file) {
link.style.display = "block"; link.style.display = "block";
link.href = citation; link.href = citation;
link.innerText = new URL(citation).host; link.innerText = new URL(citation).host;
link.rel = "noreferrer no opener";
link.target = "_blank";
citationEntry.appendChild(link); citationEntry.appendChild(link);
list.appendChild(citationEntry); list.appendChild(citationEntry);
}) })
@@ -1844,6 +1850,8 @@ function displayAttribution(file) {
link.style.display = "block"; link.style.display = "block";
link.href = source; link.href = source;
link.innerText = new URL(source).host; link.innerText = new URL(source).host;
link.rel = "noreferrer no opener";
link.target = "_blank";
sourceHolder.appendChild(link); sourceHolder.appendChild(link);
} }
} }


Laden…
Annuleren
Opslaan