From ba7a0633b09366d1fcbc7f8a84709f84d46a0118 Mon Sep 17 00:00:00 2001 From: Fred Tempez Date: Sun, 1 Nov 2020 19:00:24 +0100 Subject: [PATCH] colorvariants option rgb supprime la transparence --- core/class/helper.class.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/class/helper.class.php b/core/class/helper.class.php index f14395fc..58613dc0 100644 --- a/core/class/helper.class.php +++ b/core/class/helper.class.php @@ -219,7 +219,8 @@ class helper { 'normal' => 'rgba(' . $rgba[0] . ',' . $rgba[1] . ',' . $rgba[2] . ',' . $rgba[3] . ')', 'darken' => 'rgba(' . max(0, $rgba[0] - 15) . ',' . max(0, $rgba[1] - 15) . ',' . max(0, $rgba[2] - 15) . ',' . $rgba[3] . ')', 'veryDarken' => 'rgba(' . max(0, $rgba[0] - 20) . ',' . max(0, $rgba[1] - 20) . ',' . max(0, $rgba[2] - 20) . ',' . $rgba[3] . ')', - 'text' => self::relativeLuminanceW3C($rgba) > .22 ? "#222" : "#DDD" + 'text' => self::relativeLuminanceW3C($rgba) > .22 ? "#222" : "#DDD", + 'rgb' => 'rgb(' . $rgba[0] . ',' . $rgba[1] . ',' . $rgba[2] . ')' ]; }