Commit 1e015240 authored by Pierre M's avatar Pierre M
Browse files

code cosmetic changes


Signed-off-by: Pierre M's avatarPierre Mazière <pierre.maziere@gmx.com>
parent dab69783
......@@ -54,13 +54,18 @@
let checkbox = document.createElement("input");
checkbox.setAttribute("type","checkbox");
checkbox.setAttribute("id","closedAccounts");
checkbox.addEventListener("change",function(){plonkClosedAccounts=!plonkClosedAccounts; GM_setValue("plonkClosedAccounts",plonkClosedAccounts);});
checkbox.addEventListener("change",function(){
plonkClosedAccounts=!plonkClosedAccounts;
GM_setValue("plonkClosedAccounts",plonkClosedAccounts);
});
if(plonkClosedAccounts){
checkbox.setAttribute("checked","checked");
}
let label = document.createElement("label");
label.appendChild(checkbox);
label.appendChild(document.createTextNode("Plonker les comptes désactivés."));
label.appendChild(
document.createTextNode("Plonker les comptes désactivés.")
);
let div = document.createElement("div");
div.appendChild(label);
form.appendChild(div);
......@@ -68,13 +73,18 @@
checkbox = document.createElement("input");
checkbox.setAttribute("type","checkbox");
checkbox.setAttribute("id","unlistClosedAccounts");
checkbox.addEventListener("change",function(){unlistClosedAccounts=!unlistClosedAccounts; GM_setValue("unlistClosedAccounts",unlistClosedAccounts);});
checkbox.addEventListener("change",function(){
unlistClosedAccounts=!unlistClosedAccounts;
GM_setValue("unlistClosedAccounts",unlistClosedAccounts);
});
if(unlistClosedAccounts){
checkbox.setAttribute("checked","checked");
}
label = document.createElement("label");
label.appendChild(checkbox);
label.appendChild(document.createTextNode("Supprimer de la liste les comptes désactivés."));
label.appendChild(
document.createTextNode("Supprimer de la liste les comptes désactivés.")
);
div = document.createElement("div");
div.appendChild(label);
form.appendChild(div);
......@@ -94,7 +104,9 @@
let p = document.createElement("p");
let select = document.createElement("select");
if(plonkList.length){
p.appendChild(document.createTextNode("Liste des utilisateurs plonkés:"));
p.appendChild(
document.createTextNode("Liste des utilisateurs plonkés:")
);
select.setAttribute("id","plonkList");
select.setAttribute("multiple","multiple");
for (let i = 0; i < plonkList.length; i++){
......@@ -104,7 +116,9 @@
select.appendChild(option);
}
}else{
p.appendChild(document.createTextNode("Aucun utilisateur actif plonké pour le moment."));
p.appendChild(
document.createTextNode("Aucun utilisateur actif plonké pour le moment.")
);
select.remove();
select = null;
}
......@@ -195,7 +209,9 @@
let a = document.createElement("a");
let txt = document.createTextNode(" Plonk");
a.appendChild(txt);
a.addEventListener("click",function(){addToPlonkList(userLink.href.match(userRE)[1],userLink.textContent);},true);
a.addEventListener("click",function(){
addToPlonkList(userLink.href.match(userRE)[1],userLink.textContent);
},true);
a.href = "#";
sup.appendChild(a);
span.appendChild(sup);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment