# Override programmatic color generation

**URL:** https://meta.discourse.org/t/override-programmatic-color-generation/89670
**Category:** Support
**Created:** [June 12, 2018, 9:59am UTC](https://meta.discourse.org/t/override-programmatic-color-generation/89670 "2018-06-12T09:59:35Z")
**Posts on this page:** 1
**Showing post:** 4

<div class="post-metadata">

### Author: ![awesomerobot](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/awesomerobot/32/142900_2.png) [@awesomerobot](https://meta.discourse.org/u/awesomerobot)
#### Post date: [June 13, 2018, 4:52am UTC](https://meta.discourse.org/t/override-programmatic-color-generation/89670/4 "2018-06-13T04:52:19Z")

</div>

You can’t override core variables in theme CSS at the moment, related request:

> [@Override global Sass variables from theme](https://meta.discourse.org/t/override-global-sass-variables-from-theme/68146):
>
> Continuing the discussion from [Cleaning up our color palette artist_palette](https://meta.discourse.org/t/cleaning-up-our-color-palette/61263/18): Themes already have the ability to define sass variables: However, from personal testing, these seem to be local to the theme’s stylesheets, and won’t globally override a variable. If they did it would prove incredibly useful for theme development, as it would allow the theme to specify exactly what colour should be used as $primary-medium, $tertiary-low and so on - rather than have it automagically calculated o…

I think it _could_ be useful to override the core variables, it might save you some work… but I suspect it’s not as much as you’d expect.

Say you want to change $primary-low because you want all post borders to be red. Well, `$primary-low` is also used in 100+ instances that _aren’t_ that border you just wanted to change… so now you still have a bunch of elements you still need to write CSS for anyway. Then you also have situations where `$primary-low: red` is fine when the background is `$secondary` but doesn’t work when the background is `$primary-high`… so you run into some relational issues as well that also need custom CSS.

In theory there’s probably a more useful middle-ground somewhere in our SCSS where we’re taking our small number of core color transformations and inputting them into a much larger set of element variables and/or mixins… and then someone with a little SASS experience can override _those_ and not have to worry as much because they’re more specific.

For example, you’d have definitions like `$post-borders: $primary-low`, `$button-background: $primary-low`, etc… and for the basic admin the core color transformations work the same as always. But now the slightly more advanced admin could say `$post-borders: red` without impacting `$button-background`.

---

_[View the full topic](https://meta.discourse.org/t/override-programmatic-color-generation/89670)._
