Color Templates / CSS Variables

Am I wrong in assuming that the templates for colors in Pro uses CSS variables to assign the pre defined colors to elements where you select them?

If so, what’s the way to use these variables on other elements with custom CSS? For instance, I would like to assign my main brand color defined as a template to all my .x-section elements.

1 Like

Hi @zedinho,

Thanks for writing in.

No, you are not wrong. X and Pro uses a predefined class to assign colors and design to each elements.

For more predefined classes, you can check the link below,

If you want to use a different color for your sections, Use this code below and add this in your custom CSS in your customizer:

ex.

.x-section{
background-color:#000;
}

It will change all your section background color to black.

Hope it helps.

Thanks.

No no no… we have a misunderstanding here. I am talking about the colors you can set as templates and assign to certain elements in the header builder and in the theme options and then, when you change the color in the template, the colors are changed throughout the site. I am talking about this: https://theme.co/apex/forum/t/features-color-manager/102

Now, in the builder not every element has those templates in the color picker. For instance, for the section background you can’t pick one of these template colors and therefore the color won’t change when you change it in the template.

Basically I would like to know how I can assign one of those template colors to one of my elements in the custom CSS section.

Hello There,

Thank you for the clarifications. As of this moments, those presets were hardcoded in the builder. It is not saved as css and there is no way you can assign it to other elements in your elements in the custom css section. We certainly appreciate your feedback! This is something we can add to our list of feature requests. This way it can be taken into consideration for future development. All of these items are discussed with our team internally and prioritized based on the amount of interest a particular feature might receive.

Thanks!

I am also very interested in seeing a development in this area.

Hi,

Template Manager is now available in the latest version of the theme.

Kindly refer to the link below for more details.

https://theme.co/changelog/#theme-pro-2-0-0

Thanks