bookwyrm/bookwyrm/static/css/vendor/bulma/sass/helpers/color.sass
Mouse Reeve 6daaffeaa7
Compiles css framework from sass (#1956)
* Compiles css framework from sass

* Adds watch commands

* Copies existing css to sass file

* Moves sass out of static path

* Removes global linter

I wasn't sure how to customize this, and it's not providing a lot of
additional value on top of the domain-specific linters

* Reverts invalid change to dockerfile

* Changes stylelint path

* Remove unused bulma files

* Properly minifies generated css

* Fixes regression in thread display

* rgba function only works with percents for whatever reason

* Hush stylelint

* Removes trailing zeros

* Compile sass in Django

Co-authored-by: Joachim <joachim.robert@protonmail.com>

* Python formatting

* Updates linter

* Updates commands

* Adds css-config file

Co-authored-by: Joachim <joachim.robert@protonmail.com>

* Stylelint fix

* Removes unused compiled bulma files

Co-authored-by: Joachim <joachim.robert@protonmail.com>
2022-02-19 15:29:47 -08:00

40 lines
1.1 KiB
Sass

@import "../utilities/derived-variables"
@each $name, $pair in $colors
$color: nth($pair, 1)
.has-text-#{$name}
color: $color !important
a.has-text-#{$name}
&:hover,
&:focus
color: bulmaDarken($color, 10%) !important
.has-background-#{$name}
background-color: $color !important
@if length($pair) >= 4
$color-light: nth($pair, 3)
$color-dark: nth($pair, 4)
// Light
.has-text-#{$name}-light
color: $color-light !important
a.has-text-#{$name}-light
&:hover,
&:focus
color: bulmaDarken($color-light, 10%) !important
.has-background-#{$name}-light
background-color: $color-light !important
// Dark
.has-text-#{$name}-dark
color: $color-dark !important
a.has-text-#{$name}-dark
&:hover,
&:focus
color: bulmaLighten($color-dark, 10%) !important
.has-background-#{$name}-dark
background-color: $color-dark !important
@each $name, $shade in $shades
.has-text-#{$name}
color: $shade !important
.has-background-#{$name}
background-color: $shade !important