From 75b2852f6e83717546e5024a6cf15e5184cdb020 Mon Sep 17 00:00:00 2001 From: Zlatin Balevsky Date: Mon, 16 Dec 2019 18:30:39 +0000 Subject: [PATCH] convert table to div.right for links --- webui/src/main/js/trustUsers.js | 38 ++++++++++++++++----------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/webui/src/main/js/trustUsers.js b/webui/src/main/js/trustUsers.js index 8bcc54e2..0301a6f0 100644 --- a/webui/src/main/js/trustUsers.js +++ b/webui/src/main/js/trustUsers.js @@ -11,19 +11,21 @@ class Persona { getMapping(trusted) { var mapping = new Map() - var nameHtml = "" + var nameHtml = this.user if (trusted) { - nameHtml += "
" + this.user + "

" + nameHtml += "

" nameHtml += this.getNeutralLink() nameHtml += " " - nameHtml += this.getDistrustedBlock() - nameHtml += "

" + nameHtml += this.getDistrustedLink() + nameHtml += "" + nameHtml += "
" } else { - nameHtml += "

" - nameHtml += this.getTrustedBlock() + nameHtml += "

" + nameHtml += this.getTrustedLink() nameHtml += " " nameHtml += this.getNeutralLink() - nameHtml += "

" + nameHtml += "
" + nameHtml += "
" } mapping.set("User", nameHtml) @@ -39,24 +41,22 @@ class Persona { return mapping } - getTrustedBlock() { - var link = "" + _t("Mark Trusted") + "" - var block = "" + link + "" - block += "" - return block + getTrustedLink() { + var link = new Link(_t("Mark Trusted"), "markTrusted", [this.userB64]) + var span = "" + link.render() + "" + return span + } + + getDistrustedLink() { + var link = new Link(_t("Mark Distrusted"), "markDistrusted", [this.userB64]) + var span = "" + link.render() + "" + return span } getNeutralLink() { return "" + _t("Mark Neutral") + "" } - getDistrustedBlock() { - var link = "" + _t("Mark Distrusted") + "" - var block = "" + link + "" - block += "" - return block - } - getSubscribeLink() { return "" + _t("Subscribe") + "" }