Show badges on quoted gifs
This commit is contained in:
parent
6c5f491ee0
commit
d6b8b386fa
2 changed files with 7 additions and 1 deletions
|
@ -661,7 +661,7 @@ video {
|
|||
}
|
||||
|
||||
.quote-badge {
|
||||
left: 0px;
|
||||
left: 6px;
|
||||
position: absolute;
|
||||
z-index: 1;
|
||||
align-self: flex-end;
|
||||
|
@ -673,4 +673,6 @@ video {
|
|||
border-radius: 4px;
|
||||
color: #fffffff0;
|
||||
padding: 0px 2px;
|
||||
font-size: 12px;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
|
|
@ -136,5 +136,9 @@ proc getQuoteMedia*(quote: var Quote; node: XmlNode) =
|
|||
quote.thumb = some(media.selectAttr("img", "src"))
|
||||
|
||||
let badge = node.querySelector(".AdaptiveMedia-badgeText")
|
||||
let gifBadge = node.querySelector(".Icon--gifBadge")
|
||||
|
||||
if not badge.isNil:
|
||||
quote.badge = some(badge.innerText())
|
||||
elif not gifBadge.isNil:
|
||||
quote.badge = some("GIF")
|
||||
|
|
Loading…
Reference in a new issue