Closed elenatorro closed 5 years ago
Good job. And great trick with the alpha values.
I'll pick it up this evening where you left it, adding the whole range of components to check if they get modified by modifying the root variables.
Closing in favor of https://github.com/CartoDB/airship/pull/568
Fix #558
This first approach adds a set of css variables to allow changes in colors with alpha value. Right now,
rgba
function doesn't allow css variables that has a hexadecimal value.The following code doesn't work:
However, we can use directly the hexadecimal color that includes the alpha code, it works:
So, if we can change the colors with alpha values, we can directly change those variables. An example would be, if we want to have colors that fit for a dark mode (set by default, but the user change use their own)
CSS Variables example:
Dark Mode example:
The only css variables that needed to changed were the following:
To be done: