Blog

22 de June de 2023

CSS Variables

Variáveis CSS

To the css variables are values defined when programming your CSS, having specific values to be reused throughout the document. Thus, changing only the value of the variable changes the entire CSS.

To configure it, we use the following pattern –cor-principal: white; and are used with the function var() as color: var(–cor-principal);

In CSS we can put it like this:

	:root {
   --main-color: white;
   --secondary-color: black;
   }

P {
background-color: var(--secondary-color);
   color: var(--main-color);
   }
Share:
Others

Tips

Pseudo-Elementos

Pseudo-Elements

View more

Há quanto tempo foi atualizado?

How long has it been updated?

View more

Exemplo de PSD

PSD example

View more