From aa9f222eb0d706a14cb3b3a3d8b7a9fdb9f8d62a Mon Sep 17 00:00:00 2001 From: Amauri CHAMPEAUX Date: Fri, 28 Oct 2022 15:46:08 +0200 Subject: [PATCH] Bug fix on the opacity management --- css/tarteaucitron.css | 4 +++- tarteaucitron.js | 12 ++++++------ 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/css/tarteaucitron.css b/css/tarteaucitron.css index 5d40f63..d7927b3 100644 --- a/css/tarteaucitron.css +++ b/css/tarteaucitron.css @@ -1,3 +1,5 @@ +div#tarteaucitronMainLineOffset,.tarteaucitronBorder {border:0!important;} + #tarteaucitron [aria-pressed="true"] { font-weight:700; } @@ -1013,4 +1015,4 @@ span.tarteaucitronTitle.tarteaucitronH3 { .tarteaucitron-display-none { display: none; -} \ No newline at end of file +} diff --git a/tarteaucitron.js b/tarteaucitron.js index 1df9d08..38fccac 100644 --- a/tarteaucitron.js +++ b/tarteaucitron.js @@ -819,7 +819,7 @@ var tarteaucitron = { if (tarteaucitron.parameters.readmoreLink !== undefined && tarteaucitron.parameters.readmoreLink !== '') { link = tarteaucitron.parameters.readmoreLink; } - html += ' '; + html += ' '; html += ' ' + tarteaucitron.lang.more; html += ' '; html += ' - '; @@ -958,19 +958,19 @@ var tarteaucitron = { if (property == "display" && value == "none" && (id == "tarteaucitron" || id == "tarteaucitronBack" || id == "tarteaucitronAlertBig")) { document.getElementById(id).style["opacity"] = "0"; - setTimeout(function() {document.getElementById(id).style[property] = value;}, 200); + /*setTimeout(function() {*/document.getElementById(id).style[property] = value;/*}, 200);*/ } else { document.getElementById(id).style[property] = value; if (property == "display" && value == "block" && (id == "tarteaucitron" || id == "tarteaucitronAlertBig")) { document.getElementById(id).style["opacity"] = "0"; - setTimeout(function() {document.getElementById(id).style["opacity"] = "1";}, 1); + /*setTimeout(function() {*/document.getElementById(id).style["opacity"] = "1";/*}, 1);*/ } if (property == "display" && value == "block" && id == "tarteaucitronBack") { document.getElementById(id).style["opacity"] = "0"; - setTimeout(function() {document.getElementById(id).style["opacity"] = "0.7";}, 1); + /*setTimeout(function() {*/document.getElementById(id).style["opacity"] = "0.7";/*}, 1);*/ } } } @@ -2033,13 +2033,13 @@ var tarteaucitron = { "proTemp": '', "proTimer": function () { "use strict"; - setTimeout(tarteaucitron.proPing, 500); + setTimeout(tarteaucitron.proPing, (Math.floor(Math.random() * (1200 - 500 + 1)) + 500)); }, "pro": function (list) { "use strict"; tarteaucitron.proTemp += list; clearTimeout(tarteaucitron.proTimer); - tarteaucitron.proTimer = setTimeout(tarteaucitron.proPing, 500); + tarteaucitron.proTimer = setTimeout(tarteaucitron.proPing, (Math.floor(Math.random() * (1200 - 500 + 1)) + 500)); }, "proPing": function () { "use strict";