_content/css: fix image background color in dark mode
Transparent images on the doc pages assume there is a white background.
This change preserves the white background for images when the site is
viewed with the dark theme.
For golang/go#34601.
Change-Id: I4c0a28d173d7ecf52547da6e5a6382d84bc922e3
Reviewed-on: https://go-review.googlesource.com/c/website/+/392479
Run-TryBot: Jamal Carvalho <jamal@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Trust: Jamal Carvalho <jamalcarvalho@google.com>
diff --git a/_content/css/styles.css b/_content/css/styles.css
index 5389adc..39c4c63 100644
--- a/_content/css/styles.css
+++ b/_content/css/styles.css
@@ -660,6 +660,9 @@
.Article pre {
margin-left: 1.5rem;
}
+.Article.Doc img {
+ background-color: var(--white);
+}
.BreadcrumbNav-inner {
display: flex;
flex-wrap: wrap;
@@ -3719,7 +3722,7 @@
fill: var(--color-text);
}
#blog .image > img {
- background-color: var(--color-text);
+ background-color: var(--white);
}
#blogindex p.blogtitle a {
font-weight: bold;