Skip to content

Commit

Permalink
Add new Sass/CSS variable to handle mark color + change dark mode bg …
Browse files Browse the repository at this point in the history
…color
  • Loading branch information
julien-deramond committed Sep 13, 2023
1 parent 2175b77 commit 6880cc2
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions scss/_reboot.scss
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,7 @@ small {

mark {
padding: $mark-padding;
color: var(--#{$prefix}highlight-color);
background-color: var(--#{$prefix}highlight-bg);
}

Expand Down
2 changes: 2 additions & 0 deletions scss/_root.scss
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@
}

--#{$prefix}code-color: #{$code-color};
--#{$prefix}highlight-color: #{$mark-color};
--#{$prefix}highlight-bg: #{$mark-bg};

// scss-docs-start root-border-var
Expand Down Expand Up @@ -171,6 +172,7 @@
--#{$prefix}link-hover-color-rgb: #{to-rgb($link-hover-color-dark)};

--#{$prefix}code-color: #{$code-color-dark};
--#{$prefix}highlight-color: #{$mark-color-dark};
--#{$prefix}highlight-bg: #{$mark-bg-dark};

--#{$prefix}border-color: #{$border-color-dark};
Expand Down
3 changes: 2 additions & 1 deletion scss/_variables-dark.scss
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@ $headings-color-dark: inherit !default;
$link-color-dark: tint-color($primary, 40%) !default;
$link-hover-color-dark: shift-color($link-color-dark, -$link-shade-percentage) !default;
$code-color-dark: tint-color($code-color, 40%) !default;
$mark-bg-dark: $mark-bg !default;
$mark-color-dark: $body-color-dark !default;
$mark-bg-dark: $yellow-800 !default;


//
Expand Down
1 change: 1 addition & 0 deletions scss/_variables.scss
Original file line number Diff line number Diff line change
Expand Up @@ -718,6 +718,7 @@ $dt-font-weight: $font-weight-bold !default;
$list-inline-padding: .5rem !default;

$mark-padding: .1875em !default;
$mark-color: $body-color !default;
$mark-bg: $yellow-100 !default;
// scss-docs-end type-variables

Expand Down

0 comments on commit 6880cc2

Please sign in to comment.