Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

demo css dynamic colour palette #210

Open
wants to merge 12 commits into
base: main
Choose a base branch
from
3 changes: 1 addition & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,11 @@ Documentation was added for future OpenProblems v2. This is still in development

* `More information/Troubleshooting`: Describes the most common errors that can occur when contributing/developing.

# openproblems.bio v2.1.2

## MINOR CHANGES

* Updating task images from `.png` to `.svg` (#205).
* Set funkyheatmap colors for dark mode via js instead of css (#208).
* Set color palette dynamically for funkyheatmap (#210).

# openproblems.bio v2.1.1

Expand Down
2 changes: 1 addition & 1 deletion results/_blocks/_summary_figure.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,6 @@ funkyheatmap(
funkyheatmap = (await require('d3@7').then(d3 => {
window.d3 = d3;
window._ = _;
return import('https://unpkg.com/[email protected].8');
return import('https://unpkg.com/[email protected].9');
})).default;
```
5 changes: 5 additions & 0 deletions results/task_template.css
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,8 @@ div.dtsp-panesContainer div.dataTables_wrapper div.dataTables_scrollBody {
section#details details img.img-fluid {
filter: invert(var(--invert-colors));
}

/* funkyheatmap */
.quarto-figure .funkyheatmap .fh-geom {
filter: brightness(var(--brightness-dim));
}
4 changes: 4 additions & 0 deletions theme-dark.scss
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,7 @@ $body-bg: #1d2527;
--shadow-color: #000;
--card-bg-color: #323839;
}

.quarto-figure .funkyheatmap {
--brightness-dim: 85%;
}
6 changes: 5 additions & 1 deletion theme-light.scss
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,8 @@
.card-shadow {
--shadow-color: #5a6268;
--card-bg-color: #ffffff;
}
}

.quarto-figure .funkyheatmap {
--brightness-dim: 100%;
}