From 948dd34c6d4f0e68307488707619ecb2ab714a10 Mon Sep 17 00:00:00 2001 From: protoclown Date: Mon, 26 Sep 2022 09:57:03 +0200 Subject: [PATCH] refactor: simplify logic with a unique variable --- extensions/tags/less/common/TagLabel.less | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/extensions/tags/less/common/TagLabel.less b/extensions/tags/less/common/TagLabel.less index dd3198332..f4378ca51 100644 --- a/extensions/tags/less/common/TagLabel.less +++ b/extensions/tags/less/common/TagLabel.less @@ -18,11 +18,7 @@ &.colored { &.tag-dark { - --tag-color: @body-bg; - - & when (@config-dark-mode = true) { - --tag-color: @text-color; - } + --tag-color: @text-on-dark; .TagLabel-text { color: var(--tag-color) !important; @@ -30,11 +26,7 @@ } &.tag-light { - --tag-color: @text-color; - - & when (@config-dark-mode = true) { - --tag-color: @body-bg; - } + --tag-color: @text-on-light; .TagLabel-text { color: var(--tag-color) !important;