Add missing round to svg sparkline graph

This commit is contained in:
Peter Stockings
2023-12-09 20:55:17 +11:00
parent f9b3854544
commit c4a4af6307

View File

@@ -57,11 +57,15 @@
{% endfor %}
{% for pos, message in plot_labels %}
{% set x = (pos * vb_width) - (stroke_width/2) + margin %}
{% set y = 0 %}
{% set width = stroke_width %}
{% set height = vb_height + margin %}
<rect
x="{{ (pos * vb_width) - (stroke_width/2) + margin }}"
y="{{ 0 }}"
width="{{ stroke_width }}"
height="{{ vb_height + margin }}"
x="{{ x | round(precision) }}"
y="{{ y | round(precision) }}"
width="{{ width | round(precision) }}"
height="{{ height | round(precision) }}"
class="plot_point"
data-message="{{ message }}"
fill-opacity="0%"></rect>