remove weird trailing tabs

master
Aevann1 2022-06-11 11:56:16 +02:00
parent c0da5ed7d9
commit a082105ab8
4 changed files with 11 additions and 11 deletions

View File

@ -388,7 +388,7 @@ class Comment(Base):
if v: body += f''' onchange="poll_vote('{c.id}', '{self.id}')"'''
else: body += f''' onchange="poll_vote_no_v('{c.id}', '{self.id}')"'''
body += f'''><label class="custom-control-label" for="{c.id}">{c.body_html}<span class="presult-{self.id}'''
if not self.total_poll_voted(v): body += ' d-none'
if not self.total_poll_voted(v): body += ' d-none'
body += f'"> - <a href="/votes?link=t3_{c.id}"><span id="poll-{c.id}">{c.upvotes}</span> votes</a></span></label></div>'
if self.choices:
@ -401,7 +401,7 @@ class Comment(Base):
body += f'''<div class="custom-control"><input name="choice-{self.id}" autocomplete="off" class="custom-control-input" type="radio" id="{c.id}" onchange="choice_vote('{c.id}','{self.id}')"'''
if c.poll_voted(v): body += " checked "
body += f'''><label class="custom-control-label" for="{c.id}">{c.body_html}<span class="presult-{self.id}'''
if not self.total_choice_voted(v): body += ' d-none'
if not self.total_choice_voted(v): body += ' d-none'
body += f'"> - <a href="/votes?link=t3_{c.id}"><span id="choice-{c.id}">{c.upvotes}</span> votes</a></span></label></div>'
if self.author.sig_html and (self.author_id == MOOSE_ID or (not self.ghost and not (v and v.sigs_disabled))):

View File

@ -114,7 +114,7 @@ def callback(attrs, new=False):
if not href.startswith('/') and not href.startswith(f'{SITE_FULL}/'):
attrs[(None, "target")] = "_blank"
attrs[(None, "rel")] = "nofollow noopener noreferrer"
attrs[(None, "rel")] = "nofollow noopener noreferrer"
return attrs
@ -397,4 +397,4 @@ def normalize_url(url):
url = imgur_regex.sub(r'\1_d.webp?maxwidth=9999&fidelity=high', url)
url = giphy_tenor_regex.sub(r'\1.webp', url)
return url
return url

View File

@ -1085,7 +1085,7 @@ def submit_post(v, sub=None):
name2 = name.replace('.webp', 'r.webp')
copyfile(name, name2)
post.thumburl = process_image(v.patron, name2, resize=100)
post.thumburl = process_image(v.patron, name2, resize=100)
elif file.content_type.startswith('video/'):
value = process_video(file)
if type(value) is str: post.url = value
@ -1212,7 +1212,7 @@ def submit_post(v, sub=None):
newposturl = post.url
if newposturl.startswith('/'): newposturl = f"{SITE_FULL}{newposturl}"
body += f"Snapshots:\n\n{rev}* [archive.org](https://web.archive.org/{newposturl})\n* [archive.ph](https://archive.ph/?url={quote(newposturl)}&run=1) (click to archive)\n* [ghostarchive.org](https://ghostarchive.org/search?term={quote(newposturl)}) (click to archive)\n\n"
body += f"Snapshots:\n\n{rev}* [archive.org](https://web.archive.org/{newposturl})\n* [archive.ph](https://archive.ph/?url={quote(newposturl)}&run=1) (click to archive)\n* [ghostarchive.org](https://ghostarchive.org/search?term={quote(newposturl)}) (click to archive)\n\n"
gevent.spawn(archiveorg, newposturl)
captured = []
@ -1224,7 +1224,7 @@ def submit_post(v, sub=None):
if not href: continue
title = i.group(2)
if "Snapshots:\n\n" not in body: body += "Snapshots:\n\n"
if "Snapshots:\n\n" not in body: body += "Snapshots:\n\n"
if f'**[{title}]({href})**:\n\n' not in body:
body += f'**[{title}]({href})**:\n\n'

View File

@ -230,7 +230,7 @@
{% if c.treasure_amount.startswith('l') %}
<img class="treasure" alt="treasure" src="/assets/images/treasure_tickets.webp" width="20" />
<em>Found {{c.treasure_amount.replace('l', '')}} Lottershe Tickets!</em>
{% elif '-' in c.treasure_amount %}
{% elif '-' in c.treasure_amount %}
<img class="treasure" alt="treasure" src="/assets/images/treasure_mimic.webp" width="20" />
<em>A Mimic Ate {{c.treasure_amount.replace('-', '')}} Coins!</em>
{% else %}
@ -281,7 +281,7 @@
25% {transform: rotate({{c.award_count("tilt")/4}}deg);}
75% {transform: rotate(-{{c.award_count("tilt")/4}}deg);}
100% {transform: rotate(0deg);}
}
}
}
.comment-{{c.id}}-only {
animation-name: c{{c.id}}-tilt !important;
@ -602,12 +602,12 @@
{% if request.path == '/notifications' and c.level == 1 and c.sentto and not c.parent_submission and c.author_id not in (NOTIFICATIONS_ID, AUTOJANNY_ID) %}
<a class="btn btn-primary mt-2" role="button" onclick="openReplyBox('reply-message-{{c.id}}')">Reply</a>
<div id="reply-message-{{c.id}}" class="d-none">
<div id="comment-form-space-{{c.id}}" class="comment-write collapsed child">
<div id="comment-form-space-{{c.id}}" class="comment-write collapsed child">
<form id="reply-to-message-{{c.id}}" action="/reply" method="post" class="input-group" enctype="multipart/form-data">
<input type="hidden" name="formkey" value="{{v.formkey}}">
<textarea required autocomplete="off" minlength="1" maxlength="10000" name="body" form="reply-to-t3_{{c.id}}" data-id="{{c.id}}" class="comment-box form-control rounded" id="reply-form-body-{{c.id}}" aria-label="With textarea" rows="3" oninput="markdown('reply-form-body-{{c.id}}', 'message-reply-{{c.id}}')"></textarea>
<div class="comment-format" id="comment-format-bar-{{c.id}}">
<div onclick="loadEmojis('reply-form-body-{{c.id}}')" class="btn btn-secondary m-0 mt-3 mr-1" aria-hidden="true" data-bs-toggle="modal" data-bs-target="#emojiModal" data-bs-toggle="tooltip" data-bs-placement="bottom" title="Add Emoji"><i class="fas fa-smile-beam"></i></div>
<div onclick="loadEmojis('reply-form-body-{{c.id}}')" class="btn btn-secondary m-0 mt-3 mr-1" aria-hidden="true" data-bs-toggle="modal" data-bs-target="#emojiModal" data-bs-toggle="tooltip" data-bs-placement="bottom" title="Add Emoji"><i class="fas fa-smile-beam"></i></div>
{% if c.sentto == 2 %}
<label class="btn btn-secondary m-0 mt-3" for="file-upload">