MarseyWorld/files/templates/awards.html

50 lines
1.9 KiB
HTML
Raw Normal View History

<div id="awards-container" class="w-100 h-100">
2023-09-28 23:58:09 +00:00
{% macro stackable_award(award, src, alt) %}
<div class="stackable-container">
2023-10-04 13:05:43 +00:00
{% for i in range(p.award_count(award, v)) %}
<div class="{{award}}">
<img loading="lazy" alt="{{alt}}" src="{{src}}">
</div>
{% endfor %}
</div>
2023-09-28 23:58:09 +00:00
{% endmacro %}
{% if p.award_count("emoji", v) or p.award_count("emoji-hz", v) %}
{% for kind in ["emoji", "emoji-hz"] %}
<div class="stackable-container">
2023-12-25 01:18:48 +00:00
{% for emoji in p.emoji_awards_emojis(v, kind, NSFW_EMOJIS) %}
{% set src = '/e/' + emoji + '.webp' %}
{% set alt = 'emoji-award-' + emoji %}
{% set delay = 'animation-delay-' ~ ((loop.index-1)/4)|int %}
<div class="{{kind}}-award {{delay}}">
2024-02-05 04:25:42 +00:00
<img class="{{delay}} {% if emoji in ['marseywalking', 'capywalking', 'capycarp', 'marseyskinnedwalk', 'reindeer', 'marseyzombiewolftrample', 'taywalking', 'parrotmoonwalking', 'donkeykongwalk', 'dixiekongwalk', 'boosterwalking', 'marseydance', 'hamtarotreadmill', 'marseykatamarireddit', 'marseytrain2', 'marseysperm'] %}reversed{% endif %}" loading="lazy" alt="{{alt}}" src="{{src}}">
</div>
{% endfor %}
</div>
{% endfor %}
2023-09-28 23:58:09 +00:00
{% endif %}
2023-09-28 23:58:09 +00:00
{% if p.award_count("firework", v) %}
<script defer src="{{'js/fireworks.js' | asset}}"></script>
{{stackable_award('firework')}}
{% endif %}
2024-04-27 21:07:25 +00:00
{% if p.award_count("confetti", v) or IS_BDAY() %}
2023-09-28 23:58:09 +00:00
<div class="confetti w-100 h-100"></div>
{% endif %}
2022-11-09 05:39:05 +00:00
2023-09-28 23:58:09 +00:00
{% if p.award_count("ricardo", v) %}
{% for i in range(min(p.award_count("ricardo", v), 3)) %}
{% set i = i + 1 %}
<div class="ricardo ricardo{{i}}">
{% if IS_HOMOWEEN() %}
{% set src = SITE_FULL_IMAGES ~ "/assets/events/homoween/images/ricardo" ~ i ~ ".webp" %}
{% else %}
{% set src = SITE_FULL_IMAGES ~ "/i/ricardo" ~ i ~ ".webp" %}
{% endif %}
<img loading="lazy" src="{{src}}">
</div>
{% endfor %}
{% endif %}
</div>