From db2d21fb7fd85eff8152202467019ea107bc229a Mon Sep 17 00:00:00 2001 From: Benoit Bovy Date: Mon, 7 Jul 2025 10:22:06 +0200 Subject: [PATCH] temp fix xarray repr dark mode (pydata theme) --- docs/_static/style.css | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/_static/style.css b/docs/_static/style.css index d97a63f..c3e4794 100644 --- a/docs/_static/style.css +++ b/docs/_static/style.css @@ -12,3 +12,11 @@ .gp { color: darkorange; } + +/* workaround Pydata Sphinx theme using light colors for widget cell outputs in dark-mode */ +/* works for many widgets but not for Xarray html reprs */ +/* https://github.com/pydata/pydata-sphinx-theme/issues/2189 */ +html[data-theme="dark"] div.cell_output .text_html:has(div.xr-wrap) { + background-color: var(--pst-color-on-background) !important; + color: var(--pst-color-text-base) !important; +}