forked from MarseyWorld/MarseyWorld
dfsfds
parent
4964480c3e
commit
ed49a4d561
|
@ -221,11 +221,13 @@ def sanitize(sanitized, noimages=False):
|
|||
emojis = re.sub(f'\w*(?<!"):{emoji}:', f'<img loading="lazy" data-bs-toggle="tooltip" alt=":{emoji}:" title=":{emoji}:" delay="0" height=60 src="https://{site}/assets/images/emojis/{emoji}.webp">', emojis)
|
||||
if emoji in session["favorite_emojis"]: session["favorite_emojis"][emoji] += 1
|
||||
else: session["favorite_emojis"][emoji] = 1
|
||||
print(emojis)
|
||||
emojis = emojis.replace("<p>", "<p style='margin-bottom:0 !important'>")
|
||||
print(emojis)
|
||||
print(sanitized)
|
||||
sanitized = sanitized.replace(i.group(1), emojis)
|
||||
print(sanitized)
|
||||
|
||||
print('last')
|
||||
print(sanitized)
|
||||
for i in re.finditer('\w*(?<!"):([^ ]{1,30}?):', sanitized):
|
||||
emoji = i.group(1).lower()
|
||||
if path.isfile(f'./files/assets/images/emojis/{emoji}.webp'):
|
||||
|
|
Loading…
Reference in New Issue