sidebars: Express heading colors as CSS variables.

This commit is contained in:
Karl Stolley
2023-11-08 12:21:17 -06:00
committed by Tim Abbott
parent df703f847c
commit ee32654723
2 changed files with 11 additions and 6 deletions

View File

@@ -445,11 +445,6 @@
opacity: 0.5;
}
.sidebar-title {
color: inherit;
opacity: 0.75;
}
.rendered_markdown button,
.new-style .button {
background-color: hsl(0deg 0% 0% / 20%);

View File

@@ -254,6 +254,7 @@ body {
--color-text-item: hsl(0deg 0% 40%);
--color-text-personal-menu-no-status: hsl(0deg 0% 50%);
--color-text-personal-menu-some-status: hsl(0deg 0% 40%);
--color-text-sidebar-heading: hsl(0deg 0% 43%);
/* Icon colors */
--color-icon-bot: hsl(180deg 8% 65% / 100%);
@@ -464,6 +465,15 @@ body {
--color-text-item: hsl(0deg 0% 50%);
--color-text-personal-menu-no-status: hsl(0deg 0% 100% 35%);
--color-text-personal-menu-some-status: hsl(0deg 0% 100% 50%);
/* 75% opacity of --color-text-default against --color-background.
We use color-mix here to avoid defining a separate, compounding
`opacity` property, and also to preserve a record of the
relationship of the color of sidebar headings to other colors. */
--color-text-sidebar-heading: color-mix(
in srgb,
hsl(0deg 0% 75%) 75%,
hsl(0deg 0% 11%)
);
/* Icon colors */
--color-icon-bot: hsl(180deg 5% 50% / 100%);
@@ -1162,7 +1172,7 @@ strong {
}
.sidebar-title {
color: hsl(0deg 0% 43%);
color: var(--color-text-sidebar-heading);
font-size: inherit;
font-weight: normal;
display: inline;