change cardinal-5 description
[cavote.git] / templates / vote.html
index 7e36224..d767473 100644 (file)
 <div class="span8">
   <h2 class='page-header'>Résultats</h2>
   <svg class="results cardinal-{{ vote.id_cardinal }}"
-       width="{{ 150 + (100 * 5) + 50 + 100 + 100 }}"
+       width="{{ 150 + (100 * 5) + 100 + 100 }}"
        height="{{25 + results.list|length * 20 + 40}}">
     <g class="choice" transform="translate(100,0)">
       <text class="choice-legend" x="-10" y="9.5" dy=".35em">Légende :</text>
+      {% for value in values %}
+      <g transform="translate({{ (loop.index0 * 750 / loop.length) }},0)">
+        <rect width="{{ 750 / loop.length + 1 }}" height="18"></rect>
+        <rect class="{{ value.class }}" x="1" y ="0" width="{{ 750 / loop.length - 1}}" height="18"></rect>
+        <text class="choice-legend-item" text-anchor="start" x="{{ 750 / loop.length - 2 }}" y="9.5" dy=".35em"
+         >{{ value.name }}</text>
+       </g>
+      {% endfor %}
      </g>
-    {% for value in values %}
-    <g transform="translate({{ 150 + (loop.index0 * 640 / loop.length) }},0)">
-      <rect width="{{ 640 / loop.length + 1 }}" height="18"></rect>
-      <rect class="{{ value.class }}" x="1" y ="0" width="{{ 640 / loop.length - 1}}" height="18"></rect>
-      <text class="choice-legend-item" text-anchor="start" x="{{ 640 / loop.length - 2 }}" y="9.5" dy=".35em"
-       >{{ value.name }}</text>
-     </g>
-    {% endfor %}
     <g transform="translate({{150 + (100 * 5) + 35}},20)">
       <text class="choice-sum-legend" x="20" y="9.5" dy=".35em">somme↓</text>
      </g>