forked from rDrama/rDrama
increase emoji award display cap from 4 to 10
parent
9640c59c9b
commit
687d310327
|
@ -32,10 +32,22 @@
|
|||
}
|
||||
|
||||
@keyframes emojiX {
|
||||
100% {transform: translateX(98vw)}
|
||||
0% {
|
||||
opacity: 1;
|
||||
}
|
||||
100% {
|
||||
opacity: 1;
|
||||
transform: translateX(98vw);
|
||||
}
|
||||
}
|
||||
@keyframes emojiY {
|
||||
100% {transform: translateY(80vh)}
|
||||
0% {
|
||||
opacity: 1;
|
||||
}
|
||||
100% {
|
||||
opacity: 1;
|
||||
transform: translateY(80vh);
|
||||
}
|
||||
}
|
||||
|
||||
.train:nth-child(1), .scooter:nth-child(1) {top:2%}
|
||||
|
@ -271,3 +283,40 @@
|
|||
color: var(--black);
|
||||
font-weight: 400;
|
||||
}
|
||||
|
||||
.animation-delay-1 {
|
||||
opacity: 0;
|
||||
animation-delay: 1s;
|
||||
}
|
||||
.animation-delay-2 {
|
||||
opacity: 0;
|
||||
animation-delay: 2s;
|
||||
}
|
||||
.animation-delay-3 {
|
||||
opacity: 0;
|
||||
animation-delay: 3s;
|
||||
}
|
||||
.animation-delay-4 {
|
||||
opacity: 0;
|
||||
animation-delay: 4s;
|
||||
}
|
||||
.animation-delay-5 {
|
||||
opacity: 0;
|
||||
animation-delay: 5s;
|
||||
}
|
||||
.animation-delay-6 {
|
||||
opacity: 0;
|
||||
animation-delay: 6s;
|
||||
}
|
||||
.animation-delay-7 {
|
||||
opacity: 0;
|
||||
animation-delay: 7s;
|
||||
}
|
||||
.animation-delay-8 {
|
||||
opacity: 0;
|
||||
animation-delay: 8s;
|
||||
}
|
||||
.animation-delay-9 {
|
||||
opacity: 0;
|
||||
animation-delay: 9s;
|
||||
}
|
||||
|
|
|
@ -323,8 +323,8 @@ class Comment(Base):
|
|||
@lazy
|
||||
def emoji_award_emojis(self, v, OVER_18_EMOJIS):
|
||||
if g.show_nsfw:
|
||||
return [x.note for x in self.awards if x.kind == "emoji"][:4]
|
||||
return [x.note for x in self.awards if x.kind == "emoji" and x.note not in OVER_18_EMOJIS][:4]
|
||||
return [x.note for x in self.awards if x.kind == "emoji"][:10]
|
||||
return [x.note for x in self.awards if x.kind == "emoji" and x.note not in OVER_18_EMOJIS][:10]
|
||||
|
||||
@property
|
||||
@lazy
|
||||
|
|
|
@ -266,8 +266,8 @@ class Post(Base):
|
|||
@lazy
|
||||
def emoji_award_emojis(self, v, OVER_18_EMOJIS):
|
||||
if g.show_nsfw:
|
||||
return [x.note for x in self.awards if x.kind == "emoji"][:4]
|
||||
return [x.note for x in self.awards if x.kind == "emoji" and x.note not in OVER_18_EMOJIS][:4]
|
||||
return [x.note for x in self.awards if x.kind == "emoji"][:10]
|
||||
return [x.note for x in self.awards if x.kind == "emoji" and x.note not in OVER_18_EMOJIS][:10]
|
||||
|
||||
@lazy
|
||||
def realurl(self, v):
|
||||
|
|
|
@ -14,8 +14,9 @@
|
|||
{% for emoji in p.emoji_award_emojis(v, OVER_18_EMOJIS) %}
|
||||
{% set src = '/e/' + emoji + '.webp' %}
|
||||
{% set alt = ':#' + emoji + ':' %}
|
||||
<div class="emoji-award">
|
||||
<img loading="lazy" alt="{{alt}}" src="{{src}}">
|
||||
{% set delay = 'animation-delay-' ~ (loop.index-1) %}
|
||||
<div class="emoji-award {{delay}}">
|
||||
<img class="{{delay}}" loading="lazy" alt="{{alt}}" src="{{src}}">
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue