mirror of
https://github.com/ae-utbm/sith.git
synced 2024-11-26 02:54:20 +00:00
Sli
271d57051e
* Adapt fontawesome usage when needed * Fix uv guide not importing css * Remove utf8 usage for fontawesome
16 lines
521 B
Django/Jinja
16 lines
521 B
Django/Jinja
{% macro display_star(grade) -%}
|
|
|
|
{% if grade >= 0 %}
|
|
{% for i in range(5) %}
|
|
{% if i <= grade %}
|
|
<span class="fa-solid fa-star pedagogy star-checked grade-with-star"></span>
|
|
{% else %}
|
|
<span class="fa-solid fa-star pedagogy star-not-checked grade-with-star"></span>
|
|
{% endif %}
|
|
{% endfor %}
|
|
<span class="pedagogy grade-without-star">{{ grade }}/5</span>
|
|
{% else %}
|
|
<span class="grade-text"> {% trans %} not rated {% endtrans %} </span>
|
|
{% endif %}
|
|
|
|
{%- endmacro %} |