Skip to content

Commit

Permalink
💄 Adjust colors in tooltip & locator maps to match updated legend colors
Browse files Browse the repository at this point in the history
  • Loading branch information
jh0ker committed Oct 30, 2024
1 parent 7eb743d commit 2c2aca4
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion ddj_cloud/scrapers/talsperren/locator_maps.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@


color_map_fill = {
0: "rgb(158, 103, 0)",
0: "rgb(227, 6, 20)",
25: "rgb(252, 199, 87)",
50: "rgb(119, 219, 249)",
75: "rgb(82, 157, 220)",
Expand Down
4 changes: 2 additions & 2 deletions ddj_cloud/scrapers/talsperren/tooltips/map.html
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<big>
<div style="margin-bottom: 10px">
<div style="background: #f2f2f2; width: 180px; height: 22px; display: flex; align-items: center">
<div style="display:flex; background: {{ fill_percent >= 90 ? "darkblue" : fill_percent >= 75 ? "#4489cf" : fill_percent >= 50 ? "lightblue" : fill_percent >= 25 ? "yellow" : "#eb3620" }}; align-items:center; height:100%; width: {{fill_percent}}%">
<span style='color: {{ fill_percent >= 90 ? "white" : fill_percent >= 75 ? "white" : fill_percent >= 50 ? "black" : fill_percent >= 25 ? "black" : "black" }}; font-weight: bold; margin: 0px 5px; margin-left: {{ fill_percent >= 25 ? "5px" : "30px" }}'>{{ FORMAT(fill_percent, '0.0') }}%</span>
<div style="display:flex; background: {{ fill_percent >= 100 ? "#e30614" : fill_percent >= 90 ? "#0048a2" : fill_percent >= 75 ? "#529ddc" : fill_percent >= 50 ? "#77dbf9" : fill_percent >= 25 ? "#fcc757" : "#e30614" }}; align-items:center; height:100%; width: {{fill_percent}}%">
<span style='color: {{ fill_percent >= 90 ? "white" : fill_percent >= 75 ? "white" : fill_percent >= 50 ? "black" : fill_percent >= 25 ? "black" : "white" }}; font-weight: bold; margin: 0px 5px; margin-left: {{ fill_percent >= 25 ? "5px" : "30px" }}'> {{ FORMAT(fill_percent, '0.0')}}%{{ fill_percent >= 100 ? " &#8594; TS läuft über" : ""}}</span>
</div>
</div>
</div>
Expand Down
4 changes: 2 additions & 2 deletions ddj_cloud/scrapers/talsperren/tooltips/map_no_graphs.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
<big>
<div style="margin-bottom: 6px">
<div style="background: #f2f2f2; width: 100%; height: 22px; display: flex; align-items: center">
<div style="display:flex; background: {{ fill_percent >= 100 ? "#e30614" : fill_percent >= 90 ? "#0048a2" : fill_percent >= 75 ? "#529ddc" : fill_percent >= 50 ? "#77dbf9" : fill_percent >= 25 ? "#eb3620" : "#eb3620" }}; align-items:center; height:100%; width: {{fill_percent}}%">
<span style='color: {{ fill_percent >= 90 ? "white" : fill_percent >= 75 ? "white" : fill_percent >= 50 ? "black" : fill_percent >= 25 ? "black" : "black" }}; font-weight: bold; margin: 0px 5px; margin-left: {{ fill_percent >= 25 ? "5px" : "30px" }}'> {{ FORMAT(fill_percent, '0.0')}}%{{ fill_percent >= 100 ? " &#8594; TS läuft über" : ""}}</span>
<div style="display:flex; background: {{ fill_percent >= 100 ? "#e30614" : fill_percent >= 90 ? "#0048a2" : fill_percent >= 75 ? "#529ddc" : fill_percent >= 50 ? "#77dbf9" : fill_percent >= 25 ? "#fcc757" : "#e30614" }}; align-items:center; height:100%; width: {{fill_percent}}%">
<span style='color: {{ fill_percent >= 90 ? "white" : fill_percent >= 75 ? "white" : fill_percent >= 50 ? "black" : fill_percent >= 25 ? "black" : "white" }}; font-weight: bold; margin: 0px 5px; margin-left: {{ fill_percent >= 25 ? "5px" : "30px" }}'> {{ FORMAT(fill_percent, '0.0')}}%{{ fill_percent >= 100 ? " &#8594; TS läuft über" : ""}}</span>
</div>
</div>
</div>
Expand Down

0 comments on commit 2c2aca4

Please sign in to comment.