From 3e3f4ab6bfbabb31afdf28621056ba162c969e40 Mon Sep 17 00:00:00 2001 From: Yann Soubeyrand Date: Thu, 20 Oct 2022 18:54:43 +0200 Subject: [PATCH] add mixins to separately change main and heading colors for light/dark backgrounds --- css/theme/template/mixins.scss | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/css/theme/template/mixins.scss b/css/theme/template/mixins.scss index 17a3db5e609..44aec35b1f1 100644 --- a/css/theme/template/mixins.scss +++ b/css/theme/template/mixins.scss @@ -36,10 +36,38 @@ } } +@mixin light-bg-main-color( $color ) { + section.has-light-background { + color: $color; + } +} + +@mixin light-bg-heading-color( $color ) { + section.has-light-background { + h1, h2, h3, h4, h5, h6 { + color: $color; + } + } +} + @mixin dark-bg-text-color( $color ) { section.has-dark-background { &, h1, h2, h3, h4, h5, h6 { color: $color; } } -} \ No newline at end of file +} + +@mixin dark-bg-main-color( $color ) { + section.has-dark-background { + color: $color; + } +} + +@mixin dark-bg-heading-color( $color ) { + section.has-dark-background { + h1, h2, h3, h4, h5, h6 { + color: $color; + } + } +}