forked from MarseyWorld/MarseyWorld
disallow bounce cide repititive nesting
parent
11e15a0b24
commit
bbdd279772
|
@ -5508,6 +5508,10 @@ span > img[src$="/i/love-background.webp"] {
|
|||
animation-timing-function: linear;
|
||||
}
|
||||
|
||||
[cide] [cide], [bounce] [bounce] {
|
||||
animation: none;
|
||||
}
|
||||
|
||||
/* Fix for <ol> being populated with <li><p></p></li> in many contexts. */
|
||||
.post-body li > p:first-child,
|
||||
.comment-text li > p:first-child,
|
||||
|
|
|
@ -456,9 +456,6 @@ def sanitize(sanitized, golden=True, limit_pings=0, showmore=False, count_emojis
|
|||
|
||||
soup = BeautifulSoup(sanitized, 'lxml')
|
||||
|
||||
if len(soup.select('[bounce], [cide]')) > 5:
|
||||
error("Max 5 usages of 'bounce' and 'cide'!")
|
||||
|
||||
for tag in soup.find_all("img"):
|
||||
if tag.get("src") and not tag["src"].startswith('/pp/') and not (snappy and tag["src"].startswith(f'{SITE_FULL_IMAGES}/e/')):
|
||||
if not is_safe_url(tag["src"]):
|
||||
|
|
Loading…
Reference in New Issue