From 0c888f64034ea8842badabf1b25e36319fd5a308 Mon Sep 17 00:00:00 2001 From: protoclown Date: Mon, 26 Sep 2022 10:02:13 +0200 Subject: [PATCH] feat: add text color variables not depending on the dark/light mode --- framework/core/less/common/variables.less | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/framework/core/less/common/variables.less b/framework/core/less/common/variables.less index b82f33347..dd4b8ca2a 100644 --- a/framework/core/less/common/variables.less +++ b/framework/core/less/common/variables.less @@ -64,6 +64,13 @@ @code-color: #fff; } +// Beyond dark or light mode, we need stable colors depending on the luminosity +// of the parents element's background. This allow not to change the color +// variable depending on the dark/light mode to get the same final color, and +// thus to simplify the logic. +@text-on-dark: #ddd; +@text-on-light: #111; + @hero-bg: @control-bg; @hero-color: @control-color; @hero-muted-color: @control-color;