forked from rDrama/rDrama
show ALL timestamps in user's timezone + move scripts to the bottom of HTML templates to mimic rocketloader's behavior on localhost (for testing)
parent
55abb8bd72
commit
382df30e1f
|
@ -39,24 +39,33 @@ class Badge(Base):
|
||||||
def __repr__(self):
|
def __repr__(self):
|
||||||
return f"<Badge(user_id={self.user_id}, badge_id={self.badge_id})>"
|
return f"<Badge(user_id={self.user_id}, badge_id={self.badge_id})>"
|
||||||
|
|
||||||
|
@property
|
||||||
|
@lazy
|
||||||
|
def until(self):
|
||||||
|
if self.badge_id == 28: return self.user.agendaposter
|
||||||
|
if self.badge_id == 94: return self.user.progressivestack
|
||||||
|
if self.badge_id == 95: return self.user.bird
|
||||||
|
if self.badge_id == 96: return self.user.flairchanged
|
||||||
|
if self.badge_id == 97: return self.user.longpost
|
||||||
|
if self.badge_id == 98: return self.user.marseyawarded
|
||||||
|
if self.badge_id == 109: return self.user.rehab
|
||||||
|
return None
|
||||||
|
|
||||||
@property
|
@property
|
||||||
@lazy
|
@lazy
|
||||||
def text(self):
|
def text(self):
|
||||||
if self.name == "Chud":
|
if self.badge_id == 28:
|
||||||
ti = self.user.agendaposter
|
if ti: text = self.badge.description + " until"
|
||||||
if ti: text = self.badge.description + " until " + datetime.utcfromtimestamp(ti).strftime('%Y-%m-%d %H:%M:%S')
|
|
||||||
else: text = self.badge.description + " permanently"
|
else: text = self.badge.description + " permanently"
|
||||||
elif self.badge_id in {94,95,96,97,98,109}:
|
elif self.badge_id in {94,95,96,97,98,109}:
|
||||||
if self.badge_id == 94: ti = self.user.progressivestack
|
text = self.badge.description + " until"
|
||||||
elif self.badge_id == 95: ti = self.user.bird
|
elif self.description:
|
||||||
elif self.badge_id == 96: ti = self.user.flairchanged
|
text = self.description
|
||||||
elif self.badge_id == 97: ti = self.user.longpost
|
elif self.badge.description:
|
||||||
elif self.badge_id == 98: ti = self.user.marseyawarded
|
text = self.badge.description
|
||||||
elif self.badge_id == 109: ti = self.user.rehab
|
else:
|
||||||
text = self.badge.description + " until " + datetime.utcfromtimestamp(ti).strftime('%Y-%m-%d %H:%M:%S')
|
return self.name
|
||||||
elif self.description: text = self.description
|
|
||||||
elif self.badge.description: text = self.badge.description
|
|
||||||
else: return self.name
|
|
||||||
return f'{self.name} - {text}'
|
return f'{self.name} - {text}'
|
||||||
|
|
||||||
@property
|
@property
|
||||||
|
|
|
@ -3,7 +3,6 @@ from .get import *
|
||||||
from os import listdir, environ
|
from os import listdir, environ
|
||||||
from .const import *
|
from .const import *
|
||||||
import time
|
import time
|
||||||
from datetime import datetime
|
|
||||||
|
|
||||||
@app.template_filter("post_embed")
|
@app.template_filter("post_embed")
|
||||||
def post_embed(id, v):
|
def post_embed(id, v):
|
||||||
|
@ -54,7 +53,7 @@ def inject_constants():
|
||||||
"AUTOJANNY_ID":AUTOJANNY_ID, "PUSHER_ID":PUSHER_ID,
|
"AUTOJANNY_ID":AUTOJANNY_ID, "PUSHER_ID":PUSHER_ID,
|
||||||
"CC":CC, "CC_TITLE":CC_TITLE, "listdir":listdir, "MOOSE_ID":MOOSE_ID, "AEVANN_ID":AEVANN_ID,
|
"CC":CC, "CC_TITLE":CC_TITLE, "listdir":listdir, "MOOSE_ID":MOOSE_ID, "AEVANN_ID":AEVANN_ID,
|
||||||
"PIZZASHILL_ID":PIZZASHILL_ID, "DEFAULT_COLOR":DEFAULT_COLOR,
|
"PIZZASHILL_ID":PIZZASHILL_ID, "DEFAULT_COLOR":DEFAULT_COLOR,
|
||||||
"COLORS":COLORS, "ADMIGGERS":ADMIGGERS, "datetime":datetime, "time":time,
|
"COLORS":COLORS, "ADMIGGERS":ADMIGGERS, "time":time,
|
||||||
"HOLE_NAME": HOLE_NAME, "HOLE_STYLE_FLAIR": HOLE_STYLE_FLAIR, "HOLE_REQUIRED": HOLE_REQUIRED,
|
"HOLE_NAME": HOLE_NAME, "HOLE_STYLE_FLAIR": HOLE_STYLE_FLAIR, "HOLE_REQUIRED": HOLE_REQUIRED,
|
||||||
"LOTTERY_ENABLED": LOTTERY_ENABLED, "GUMROAD_LINK": GUMROAD_LINK,
|
"LOTTERY_ENABLED": LOTTERY_ENABLED, "GUMROAD_LINK": GUMROAD_LINK,
|
||||||
"DEFAULT_THEME": DEFAULT_THEME, "DESCRIPTION": DESCRIPTION, "PERMS": PERMS,
|
"DEFAULT_THEME": DEFAULT_THEME, "DESCRIPTION": DESCRIPTION, "PERMS": PERMS,
|
||||||
|
|
|
@ -246,7 +246,7 @@ def random_user(v):
|
||||||
u = g.db.query(User.username).filter(User.song != None).order_by(func.random()).first()
|
u = g.db.query(User.username).filter(User.song != None).order_by(func.random()).first()
|
||||||
|
|
||||||
if u: u = u[0]
|
if u: u = u[0]
|
||||||
else: abort(404)
|
else: return "No users have set a profile anthem so far!"
|
||||||
|
|
||||||
return redirect(f"/@{u}")
|
return redirect(f"/@{u}")
|
||||||
|
|
||||||
|
|
|
@ -4,8 +4,6 @@
|
||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
|
|
||||||
<script src="/assets/js/sort_table.js?v=243"></script>
|
|
||||||
|
|
||||||
<pre class="d-none d-md-inline-block"></pre>
|
<pre class="d-none d-md-inline-block"></pre>
|
||||||
<h5 style="font-weight:bold;">Admins</h5>
|
<h5 style="font-weight:bold;">Admins</h5>
|
||||||
<pre></pre>
|
<pre></pre>
|
||||||
|
@ -30,4 +28,7 @@
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<script src="/assets/js/sort_table.js?v=243"></script>
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
{% extends "default.html" %}
|
{% extends "default.html" %}
|
||||||
{% block content %}
|
{% block content %}
|
||||||
<script src="/assets/js/sort_table.js?v=243"></script>
|
|
||||||
<pre>
|
<pre>
|
||||||
|
|
||||||
|
|
||||||
|
@ -37,4 +36,7 @@
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<script src="/assets/js/sort_table.js?v=243"></script>
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
|
@ -1,6 +1,4 @@
|
||||||
|
|
||||||
<script src="/assets/js/ban_modal.js?v=242"></script>
|
|
||||||
|
|
||||||
<div class="modal fade" id="banModal" tabindex="-1" role="dialog" aria-labelledby="banModalTitle" aria-hidden="true">
|
<div class="modal fade" id="banModal" tabindex="-1" role="dialog" aria-labelledby="banModalTitle" aria-hidden="true">
|
||||||
<div class="modal-dialog modal-dialog-centered" role="document">
|
<div class="modal-dialog modal-dialog-centered" role="document">
|
||||||
<div class="modal-content">
|
<div class="modal-content">
|
||||||
|
@ -36,3 +34,5 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<script src="/assets/js/ban_modal.js?v=242"></script>
|
|
@ -109,8 +109,6 @@
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
<script src="{{asset('js/bootstrap.js')}}"></script>
|
|
||||||
|
|
||||||
{% include "header.html" %}
|
{% include "header.html" %}
|
||||||
|
|
||||||
<div class="container pb-4">
|
<div class="container pb-4">
|
||||||
|
@ -196,6 +194,7 @@
|
||||||
<input id="site_name" type="hidden" value="{{SITE_NAME}}">
|
<input id="site_name" type="hidden" value="{{SITE_NAME}}">
|
||||||
<input id="slurreplacer" type="hidden" value="{{v.slurreplacer}}">
|
<input id="slurreplacer" type="hidden" value="{{v.slurreplacer}}">
|
||||||
|
|
||||||
|
<script src="{{asset('js/bootstrap.js')}}"></script>
|
||||||
<script src="/chat.js?v=23"></script>
|
<script src="/chat.js?v=23"></script>
|
||||||
|
|
||||||
{% include "emoji_modal.html" %}
|
{% include "emoji_modal.html" %}
|
||||||
|
|
|
@ -11,7 +11,6 @@
|
||||||
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline' ajax.cloudflare.com; connect-src 'self'; object-src 'none';">
|
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline' ajax.cloudflare.com; connect-src 'self'; object-src 'none';">
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
<script src="{{asset('js/bootstrap.js')}}"></script>
|
|
||||||
{% if v %}
|
{% if v %}
|
||||||
<style>:root{--primary:#{{v.themecolor}}}</style>
|
<style>:root{--primary:#{{v.themecolor}}}</style>
|
||||||
<link rel="stylesheet" href="{{asset('css/main.css')}}">
|
<link rel="stylesheet" href="{{asset('css/main.css')}}">
|
||||||
|
@ -377,6 +376,8 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<script src="{{asset('js/bootstrap.js')}}"></script>
|
||||||
|
|
||||||
<script src="{{asset('js/lozad.js')}}"></script>
|
<script src="{{asset('js/lozad.js')}}"></script>
|
||||||
|
|
||||||
{% if v %}
|
{% if v %}
|
||||||
|
|
|
@ -1,5 +1,3 @@
|
||||||
<script src="/assets/js/delete_post_modal.js?v=240"></script>
|
|
||||||
|
|
||||||
<div class="modal fade" id="deletePostModal" tabindex="-1" role="dialog" aria-labelledby="deletePostModalTitle" aria-hidden="true">
|
<div class="modal fade" id="deletePostModal" tabindex="-1" role="dialog" aria-labelledby="deletePostModalTitle" aria-hidden="true">
|
||||||
<div class="modal-dialog modal-dialog-centered" role="document">
|
<div class="modal-dialog modal-dialog-centered" role="document">
|
||||||
<div class="modal-content">
|
<div class="modal-content">
|
||||||
|
@ -28,3 +26,5 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<script src="/assets/js/delete_post_modal.js?v=240"></script>
|
|
@ -1,6 +1,5 @@
|
||||||
{% extends "default.html" %}
|
{% extends "default.html" %}
|
||||||
{% block content %}
|
{% block content %}
|
||||||
<script src="/assets/js/followers.js?v=241"></script>
|
|
||||||
<pre>
|
<pre>
|
||||||
|
|
||||||
|
|
||||||
|
@ -30,4 +29,6 @@
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
|
<script src="/assets/js/followers.js?v=241"></script>
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
|
@ -1,6 +1,5 @@
|
||||||
{% extends "default.html" %}
|
{% extends "default.html" %}
|
||||||
{% block content %}
|
{% block content %}
|
||||||
<script src="/assets/js/following.js?v=241"></script>
|
|
||||||
<pre>
|
<pre>
|
||||||
|
|
||||||
|
|
||||||
|
@ -30,4 +29,6 @@
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
|
<script src="/assets/js/following.js?v=241"></script>
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
|
@ -10,35 +10,6 @@
|
||||||
</style>
|
</style>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% if v and FP %}
|
|
||||||
{% if not v.fp %}
|
|
||||||
<script>
|
|
||||||
function fp(fp) {
|
|
||||||
const xhr = new XMLHttpRequest();
|
|
||||||
xhr.open("POST", '/fp/'+fp);
|
|
||||||
xhr.setRequestHeader('xhr', 'xhr');
|
|
||||||
var form = new FormData()
|
|
||||||
form.append("formkey", formkey());
|
|
||||||
xhr.send(form);
|
|
||||||
};
|
|
||||||
|
|
||||||
const fpPromise = new Promise((resolve, reject) => {
|
|
||||||
const script = document.createElement('script');
|
|
||||||
script.onload = resolve;
|
|
||||||
script.onerror = reject;
|
|
||||||
script.async = true;
|
|
||||||
script.src = "/assets/js/fp.js?v=240";
|
|
||||||
document.head.appendChild(script);
|
|
||||||
})
|
|
||||||
.then(() => FingerprintJS.load({token: '{{FP}}'}));
|
|
||||||
|
|
||||||
fpPromise
|
|
||||||
.then(fp => fp.get())
|
|
||||||
.then(result => {if (result.visitorId != '{{v.fp}}') fp(result.visitorId);})
|
|
||||||
</script>
|
|
||||||
{% endif %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
<div class="row" style="overflow: visible;padding-top:5px;">
|
<div class="row" style="overflow: visible;padding-top:5px;">
|
||||||
<div class="col">
|
<div class="col">
|
||||||
{% if sub %}
|
{% if sub %}
|
||||||
|
@ -243,4 +214,33 @@
|
||||||
</style>
|
</style>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
{% if v and FP %}
|
||||||
|
{% if not v.fp %}
|
||||||
|
<script>
|
||||||
|
function fp(fp) {
|
||||||
|
const xhr = new XMLHttpRequest();
|
||||||
|
xhr.open("POST", '/fp/'+fp);
|
||||||
|
xhr.setRequestHeader('xhr', 'xhr');
|
||||||
|
var form = new FormData()
|
||||||
|
form.append("formkey", formkey());
|
||||||
|
xhr.send(form);
|
||||||
|
};
|
||||||
|
|
||||||
|
const fpPromise = new Promise((resolve, reject) => {
|
||||||
|
const script = document.createElement('script');
|
||||||
|
script.onload = resolve;
|
||||||
|
script.onerror = reject;
|
||||||
|
script.async = true;
|
||||||
|
script.src = "/assets/js/fp.js?v=240";
|
||||||
|
document.head.appendChild(script);
|
||||||
|
})
|
||||||
|
.then(() => FingerprintJS.load({token: '{{FP}}'}));
|
||||||
|
|
||||||
|
fpPromise
|
||||||
|
.then(fp => fp.get())
|
||||||
|
.then(result => {if (result.visitorId != '{{v.fp}}') fp(result.visitorId);})
|
||||||
|
</script>
|
||||||
|
{% endif %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
|
@ -9,8 +9,6 @@
|
||||||
<meta name="description" content="{{DESCRIPTION}}">
|
<meta name="description" content="{{DESCRIPTION}}">
|
||||||
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
||||||
|
|
||||||
<script src="{{asset('js/bootstrap.js')}}"></script>
|
|
||||||
|
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||||
|
|
||||||
|
@ -120,6 +118,8 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<script src="{{asset('js/bootstrap.js')}}"></script>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
|
|
||||||
</html>
|
</html>
|
||||||
|
|
|
@ -9,8 +9,6 @@
|
||||||
|
|
||||||
{% if thing %}
|
{% if thing %}
|
||||||
|
|
||||||
<script src="/assets/js/sort_table.js?v=243"></script>
|
|
||||||
|
|
||||||
<pre>
|
<pre>
|
||||||
|
|
||||||
</pre>
|
</pre>
|
||||||
|
@ -43,6 +41,8 @@
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<script src="/assets/js/sort_table.js?v=243"></script>
|
||||||
|
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -6,8 +6,6 @@
|
||||||
<meta name="description" content="{{DESCRIPTION}}">
|
<meta name="description" content="{{DESCRIPTION}}">
|
||||||
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
||||||
|
|
||||||
<script src="{{asset('js/bootstrap.js')}}"></script>
|
|
||||||
|
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||||
|
|
||||||
|
@ -262,6 +260,8 @@
|
||||||
|
|
||||||
{% block onload %}{% endblock %}
|
{% block onload %}{% endblock %}
|
||||||
|
|
||||||
|
<script src="{{asset('js/bootstrap.js')}}"></script>
|
||||||
|
|
||||||
<script src="/assets/js/clipboard.js?v=240"></script>
|
<script src="/assets/js/clipboard.js?v=240"></script>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
|
|
|
@ -7,8 +7,6 @@
|
||||||
<meta name="description" content="{{DESCRIPTION}}">
|
<meta name="description" content="{{DESCRIPTION}}">
|
||||||
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
||||||
|
|
||||||
<script src="{{asset('js/bootstrap.js')}}"></script>
|
|
||||||
|
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||||
|
|
||||||
|
@ -172,6 +170,8 @@
|
||||||
{% block scripts %}
|
{% block scripts %}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
|
<script src="{{asset('js/bootstrap.js')}}"></script>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
|
|
||||||
</html>
|
</html>
|
|
@ -4,8 +4,6 @@
|
||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
|
|
||||||
<script src="/assets/js/settings_blocks.js?v=241"></script>
|
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
|
|
||||||
<div class="col">
|
<div class="col">
|
||||||
|
@ -118,4 +116,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<script src="/assets/js/settings_blocks.js?v=241"></script>
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
|
@ -463,14 +463,9 @@
|
||||||
<label class="text-black w-lg-25">Flair</label>
|
<label class="text-black w-lg-25">Flair</label>
|
||||||
|
|
||||||
<div class="w-lg-100">
|
<div class="w-lg-100">
|
||||||
|
|
||||||
{% if v.flairchanged %}
|
|
||||||
{% set ti = datetime.utcfromtimestamp(v.flairchanged).strftime('%Y-%m-%d %H:%M:%S') %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
<form id="profile-settings" action="/settings/title_change" method="post">
|
<form id="profile-settings" action="/settings/title_change" method="post">
|
||||||
<input type="hidden" name="formkey" value="{{v.formkey}}">
|
<input type="hidden" name="formkey" value="{{v.formkey}}">
|
||||||
<input maxlength=100 {% if v.flairchanged %}disabled{% endif %} autocomplete="off" id="customtitlebody" type="text" name="title" class="form-control" placeholder='Enter a flair here' value="{% if v.flairchanged %}Your flair has been locked until {{ti}}{% elif v.customtitleplain %}{{v.customtitleplain}}{% endif %}">
|
<input maxlength=100 {% if v.flairchanged %}disabled{% endif %} autocomplete="off" id="customtitlebody" type="text" name="title" class="form-control" placeholder='Enter a flair here' value="{% if v.customtitleplain %}{{v.customtitleplain}}{% endif %}">
|
||||||
<div class="d-flex mt-2">
|
<div class="d-flex mt-2">
|
||||||
<a class="format" role="button"><i class="btn btn-secondary format d-inline-block m-0 fas fa-smile-beam" onclick="loadEmojis('customtitlebody')" aria-hidden="true" data-bs-toggle="modal" data-bs-target="#emojiModal" data-bs-toggle="tooltip" data-bs-placement="bottom" title="Add Emoji"></i></a>
|
<a class="format" role="button"><i class="btn btn-secondary format d-inline-block m-0 fas fa-smile-beam" onclick="loadEmojis('customtitlebody')" aria-hidden="true" data-bs-toggle="modal" data-bs-target="#emojiModal" data-bs-toggle="tooltip" data-bs-placement="bottom" title="Add Emoji"></i></a>
|
||||||
|
|
||||||
|
@ -738,9 +733,17 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<script src="/assets/js/settings_profile.js?v=256"></script>
|
|
||||||
|
|
||||||
{% include "emoji_modal.html" %}
|
{% include "emoji_modal.html" %}
|
||||||
{% include "gif_modal.html" %}
|
{% include "gif_modal.html" %}
|
||||||
|
|
||||||
|
{% if v.flairchanged %}
|
||||||
|
<script>
|
||||||
|
const date = new Date({{v.flairchanged}}*1000).toString();
|
||||||
|
const text = ` - Your flair has been locked until ${date}`
|
||||||
|
document.getElementById('customtitlebody').value += text;
|
||||||
|
</script>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
<script src="/assets/js/settings_profile.js?v=256"></script>
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
|
@ -4,8 +4,6 @@
|
||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
|
|
||||||
<script src="/assets/js/settings_security.js?v=241"></script>
|
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
|
|
||||||
<div class="col col-lg-8">
|
<div class="col col-lg-8">
|
||||||
|
@ -265,4 +263,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<script src="/assets/js/settings_security.js?v=241"></script>
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
|
@ -8,8 +8,6 @@
|
||||||
<meta name="description" content="{{DESCRIPTION}}">
|
<meta name="description" content="{{DESCRIPTION}}">
|
||||||
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
||||||
|
|
||||||
<script src="{{asset('js/bootstrap.js')}}"></script>
|
|
||||||
|
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||||
|
|
||||||
|
@ -151,6 +149,8 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<script src="{{asset('js/bootstrap.js')}}"></script>
|
||||||
|
|
||||||
<script src="/assets/js/signup.js?v=240"></script>
|
<script src="/assets/js/signup.js?v=240"></script>
|
||||||
|
|
||||||
{% if hcaptcha %}
|
{% if hcaptcha %}
|
||||||
|
|
|
@ -9,8 +9,6 @@
|
||||||
<meta name="description" content="{{DESCRIPTION}}">
|
<meta name="description" content="{{DESCRIPTION}}">
|
||||||
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
||||||
|
|
||||||
<script src="{{asset('js/bootstrap.js')}}"></script>
|
|
||||||
|
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||||
|
|
||||||
|
@ -102,6 +100,8 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<script src="{{asset('js/bootstrap.js')}}"></script>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
|
|
||||||
</html>
|
</html>
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
{% extends "default.html" %}
|
{% extends "default.html" %}
|
||||||
{% block content %}
|
{% block content %}
|
||||||
<script src="/assets/js/sort_table.js?v=243"></script>
|
|
||||||
|
|
||||||
<pre>
|
<pre>
|
||||||
|
|
||||||
|
|
||||||
|
@ -31,4 +29,7 @@
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<script src="/assets/js/sort_table.js?v=243"></script>
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
|
@ -22,97 +22,12 @@
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
{% if success %}
|
|
||||||
<script>
|
|
||||||
history.pushState(null, null, '{{p.permalink}}');
|
|
||||||
localStorage.setItem("post_title", "")
|
|
||||||
localStorage.setItem("post_text", "")
|
|
||||||
localStorage.setItem("post_url", "")
|
|
||||||
localStorage.setItem("sub", "")
|
|
||||||
</script>
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
|
|
||||||
{% if p.award_count("crab", v) %}
|
|
||||||
<script>
|
|
||||||
let audio = new Audio('/assets/media/crab.mp3');
|
|
||||||
audio.loop=true;
|
|
||||||
|
|
||||||
audio.play();
|
|
||||||
window.addEventListener('click', () => {
|
|
||||||
if (audio.paused) audio.play();
|
|
||||||
}, {once : true});
|
|
||||||
</script>
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if fart and not (v and v.has_badge(128)) %}
|
|
||||||
<script>
|
|
||||||
fart = Math.floor(Math.random() * 5) + 1
|
|
||||||
let audio = new Audio(`/assets/images/${fart}.webp`);
|
|
||||||
|
|
||||||
audio.play();
|
|
||||||
if (audio.paused) {
|
|
||||||
window.addEventListener('click', () => {
|
|
||||||
if (audio.paused) audio.play();
|
|
||||||
}, {once : true})
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if SITE_NAME == 'PCM' %}
|
{% if SITE_NAME == 'PCM' %}
|
||||||
{% set wholesome = '/i/wholesome.webp' %}
|
{% set wholesome = '/i/wholesome.webp' %}
|
||||||
{% else %}
|
{% else %}
|
||||||
{% set wholesome = '/e/marseywholesome.webp' %}
|
{% set wholesome = '/e/marseywholesome.webp' %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% if p.award_count("confetti", v) %}
|
|
||||||
<div id="post-award-confetti"></div>
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if p.award_count("firework", v) %}
|
|
||||||
<script src="/assets/js/fireworks.js?v=18"></script>
|
|
||||||
<div class="firework">
|
|
||||||
<img src="">
|
|
||||||
</div>
|
|
||||||
|
|
||||||
{% if p.award_count("firework", v) > 1 %}
|
|
||||||
<div class="firework">
|
|
||||||
<img src="">
|
|
||||||
</div>
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if p.award_count("firework", v) > 2 %}
|
|
||||||
<div class="firework">
|
|
||||||
<img src="">
|
|
||||||
</div>
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if p.award_count("firework", v) > 3 %}
|
|
||||||
<div class="firework">
|
|
||||||
<img src="">
|
|
||||||
</div>
|
|
||||||
{% endif %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if p.award_count("ricardo", v) %}
|
|
||||||
<script src="/assets/js/ricardo.js?v=18"></script>
|
|
||||||
<div id="ricardo1" class="ricardo ricardoleft">
|
|
||||||
<img src="/i/ricardo1.webp">
|
|
||||||
</div>
|
|
||||||
|
|
||||||
{% if p.award_count("ricardo", v) > 1 %}
|
|
||||||
<div id="ricardo2" class="ricardo">
|
|
||||||
<img src="/i/ricardo2.webp" style="max-height:200px">
|
|
||||||
</div>
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if p.award_count("ricardo", v) > 2 %}
|
|
||||||
<div id="ricardo3" class="ricardo">
|
|
||||||
<img src="/i/ricardo3.webp" style="max-height:150px">
|
|
||||||
</div>
|
|
||||||
{% endif %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if g.inferior_browser %}
|
{% if g.inferior_browser %}
|
||||||
{% if p.award_count("wholesome", v) %}
|
{% if p.award_count("wholesome", v) %}
|
||||||
<style>
|
<style>
|
||||||
|
@ -1216,4 +1131,91 @@
|
||||||
{% endif %}
|
{% endif %}
|
||||||
})()
|
})()
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
{% if success %}
|
||||||
|
<script>
|
||||||
|
history.pushState(null, null, '{{p.permalink}}');
|
||||||
|
localStorage.setItem("post_title", "")
|
||||||
|
localStorage.setItem("post_text", "")
|
||||||
|
localStorage.setItem("post_url", "")
|
||||||
|
localStorage.setItem("sub", "")
|
||||||
|
</script>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
|
||||||
|
{% if p.award_count("crab", v) %}
|
||||||
|
<script>
|
||||||
|
let audio = new Audio('/assets/media/crab.mp3');
|
||||||
|
audio.loop=true;
|
||||||
|
|
||||||
|
audio.play();
|
||||||
|
window.addEventListener('click', () => {
|
||||||
|
if (audio.paused) audio.play();
|
||||||
|
}, {once : true});
|
||||||
|
</script>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if fart and not (v and v.has_badge(128)) %}
|
||||||
|
<script>
|
||||||
|
fart = Math.floor(Math.random() * 5) + 1
|
||||||
|
let audio = new Audio(`/assets/images/${fart}.webp`);
|
||||||
|
|
||||||
|
audio.play();
|
||||||
|
if (audio.paused) {
|
||||||
|
window.addEventListener('click', () => {
|
||||||
|
if (audio.paused) audio.play();
|
||||||
|
}, {once : true})
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
|
||||||
|
{% if p.award_count("confetti", v) %}
|
||||||
|
<div id="post-award-confetti"></div>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if p.award_count("firework", v) %}
|
||||||
|
<script src="/assets/js/fireworks.js?v=18"></script>
|
||||||
|
<div class="firework">
|
||||||
|
<img src="">
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{% if p.award_count("firework", v) > 1 %}
|
||||||
|
<div class="firework">
|
||||||
|
<img src="">
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if p.award_count("firework", v) > 2 %}
|
||||||
|
<div class="firework">
|
||||||
|
<img src="">
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if p.award_count("firework", v) > 3 %}
|
||||||
|
<div class="firework">
|
||||||
|
<img src="">
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if p.award_count("ricardo", v) %}
|
||||||
|
<script src="/assets/js/ricardo.js?v=18"></script>
|
||||||
|
<div id="ricardo1" class="ricardo ricardoleft">
|
||||||
|
<img src="/i/ricardo1.webp">
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{% if p.award_count("ricardo", v) > 1 %}
|
||||||
|
<div id="ricardo2" class="ricardo">
|
||||||
|
<img src="/i/ricardo2.webp" style="max-height:200px">
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if p.award_count("ricardo", v) > 2 %}
|
||||||
|
<div id="ricardo3" class="ricardo">
|
||||||
|
<img src="/i/ricardo3.webp" style="max-height:150px">
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
|
@ -6,8 +6,6 @@
|
||||||
<meta name="description" content="{{DESCRIPTION}}">
|
<meta name="description" content="{{DESCRIPTION}}">
|
||||||
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
||||||
|
|
||||||
<script src="{{asset('js/bootstrap.js')}}"></script>
|
|
||||||
|
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||||
|
|
||||||
|
@ -225,6 +223,7 @@
|
||||||
</script>
|
</script>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
<script src="{{asset('js/bootstrap.js')}}"></script>
|
||||||
<script src="{{asset('js/marked.js')}}"></script>
|
<script src="{{asset('js/marked.js')}}"></script>
|
||||||
<script src="{{asset('js/formatting.js')}}"></script>
|
<script src="{{asset('js/formatting.js')}}"></script>
|
||||||
<script src="{{asset('js/submit.js')}}"></script>
|
<script src="{{asset('js/submit.js')}}"></script>
|
||||||
|
|
|
@ -340,13 +340,12 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="profile--badges">
|
<div id="profile--badges">
|
||||||
{% for b in u.badges %}
|
{% for b in u.badges %}
|
||||||
{% if b.url %}
|
{% if b.url %}
|
||||||
<a rel="nofollow noopener noreferrer" href="{{b.url}}"><img alt="{{b.name}}" width=55 height=60 loading="lazy" src="{{b.path}}?v=1021" data-bs-toggle="tooltip" data-bs-placement="bottom" title="{{b.text}}"></a>
|
<a rel="nofollow noopener noreferrer" href="{{b.url}}"><img alt="{{b.name}}" width=55 height=60 loading="lazy" src="{{b.path}}?v=1021" data-bs-toggle="tooltip" data-bs-placement="bottom" title="{{b.text}}" {% if b.until %}data-until="{{b.until}}" onmouseover="badge_timestamp(this)"{% endif %}>></a>
|
||||||
{% else %}
|
{% else %}
|
||||||
<img alt="{{b.name}}" width=55 height=60 loading="lazy" src="{{b.path}}?v=1021" data-bs-toggle="tooltip" data-bs-placement="bottom" title="{{b.text}}">
|
<img alt="{{b.name}}" width=55 height=60 loading="lazy" src="{{b.path}}?v=1021" data-bs-toggle="tooltip" data-bs-placement="bottom" title="{{b.text}}" {% if b.until %}data-until="{{b.until}}" onmouseover="badge_timestamp(this)"{% endif %}>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</div>
|
</div>
|
||||||
|
@ -478,9 +477,9 @@
|
||||||
<div class="mb-3" id="profile--badges">
|
<div class="mb-3" id="profile--badges">
|
||||||
{% for b in u.badges %}
|
{% for b in u.badges %}
|
||||||
{% if b.url %}
|
{% if b.url %}
|
||||||
<a rel="nofollow noopener noreferrer" href="{{b.url}}"><img alt="{{b.name}}" width=29.33 height=32 loading="lazy" src="{{b.path}}?v=1021" data-bs-toggle="tooltip" data-bs-placement="bottom" title="{{b.text}}"></a>
|
<a rel="nofollow noopener noreferrer" href="{{b.url}}"><img alt="{{b.name}}" width=29.33 height=32 loading="lazy" src="{{b.path}}?v=1021" data-bs-toggle="tooltip" data-bs-placement="bottom" title="{{b.text}}" {% if b.until %}data-until="{{b.until}}" onmouseover="badge_timestamp(this)"{% endif %}>></a>
|
||||||
{% else %}
|
{% else %}
|
||||||
<img alt="{{b.name}}" width=29.33 height=32 loading="lazy" src="{{b.path}}?v=1021" data-bs-toggle="tooltip" data-bs-placement="bottom" title="{{b.text}}">
|
<img alt="{{b.name}}" width=29.33 height=32 loading="lazy" src="{{b.path}}?v=1021" data-bs-toggle="tooltip" data-bs-placement="bottom" title="{{b.text}}" {% if b.until %}data-until="{{b.until}}" onmouseover="badge_timestamp(this)"{% endif %}>>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</div>
|
</div>
|
||||||
|
@ -786,8 +785,9 @@
|
||||||
</nav>
|
</nav>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
<script src="{{asset('js/marked.js')}}"></script>
|
{% if not request.path.endswith('/comments') %}
|
||||||
|
<script src="{{asset('js/marked.js')}}"></script>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
{% if v and v.id != u.id and '/comments' not in request.path %}
|
{% if v and v.id != u.id and '/comments' not in request.path %}
|
||||||
{% include "emoji_modal.html" %}
|
{% include "emoji_modal.html" %}
|
||||||
|
|
|
@ -117,8 +117,8 @@
|
||||||
|
|
||||||
{% if v %}
|
{% if v %}
|
||||||
<div id='tax' class="d-none">{% if v.patron or u.patron %}0{% else %}0.03{% endif %}</div>
|
<div id='tax' class="d-none">{% if v.patron or u.patron %}0{% else %}0.03{% endif %}</div>
|
||||||
<script src="{{asset('js/userpage_v.js')}}"></script>
|
|
||||||
<div id="username" class="d-none">{{u.username}}</div>
|
<div id="username" class="d-none">{{u.username}}</div>
|
||||||
|
<script src="{{asset('js/userpage_v.js')}}"></script>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
<script src="{{asset('js/userpage.js')}}"></script>
|
<script src="{{asset('js/userpage.js')}}"></script>
|
||||||
|
|
|
@ -31,14 +31,12 @@
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% if v %}
|
{% if v %}
|
||||||
<div id='tax' class="d-none">{% if v.patron or u.patron %}0{% else %}0.03{% endif %}</div>
|
<div id='tax' class="d-none">{% if v.patron or u.patron %}0{% else %}0.03{% endif %}</div>
|
||||||
<script src="{{asset('js/userpage_v.js')}}"></script>
|
<div id="username" class="d-none">{{u.username}}</div>
|
||||||
<div id="username" class="d-none">{{u.username}}</div>
|
{%- include "emoji_modal.html" -%}
|
||||||
|
<script src="{{asset('js/userpage_v.js')}}"></script>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
<script src="{{asset('js/userpage.js')}}"></script>
|
<script src="{{asset('js/userpage.js')}}"></script>
|
||||||
|
|
||||||
{% if v -%}
|
|
||||||
{%- include "emoji_modal.html" -%}
|
|
||||||
{%- endif %}
|
|
||||||
{% endblock %}
|
{% endblock %}
|
|
@ -16,7 +16,7 @@ set CACHE_VER = {
|
||||||
'css/win98.css': 61,
|
'css/win98.css': 61,
|
||||||
|
|
||||||
'js/award_modal.js': 253,
|
'js/award_modal.js': 253,
|
||||||
'js/bootstrap.js': 274,
|
'js/bootstrap.js': 275,
|
||||||
'js/comments+submission_listing.js': 263,
|
'js/comments+submission_listing.js': 263,
|
||||||
'js/submission_listing.js': 261,
|
'js/submission_listing.js': 261,
|
||||||
'js/emoji_modal.js': 297,
|
'js/emoji_modal.js': 297,
|
||||||
|
@ -24,7 +24,7 @@ set CACHE_VER = {
|
||||||
'js/lottery.js': 256,
|
'js/lottery.js': 256,
|
||||||
'js/marked.js': 280,
|
'js/marked.js': 280,
|
||||||
'js/submit.js': 265,
|
'js/submit.js': 265,
|
||||||
'js/userpage.js': 241,
|
'js/userpage.js': 242,
|
||||||
'js/userpage_v.js': 245,
|
'js/userpage_v.js': 245,
|
||||||
'js/lozad.js': 260,
|
'js/lozad.js': 260,
|
||||||
|
|
||||||
|
|
|
@ -9,8 +9,6 @@
|
||||||
|
|
||||||
{% if thing %}
|
{% if thing %}
|
||||||
|
|
||||||
<script src="/assets/js/sort_table.js?v=243"></script>
|
|
||||||
|
|
||||||
<pre>
|
<pre>
|
||||||
|
|
||||||
</pre>
|
</pre>
|
||||||
|
@ -82,6 +80,9 @@
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<script src="/assets/js/sort_table.js?v=243"></script>
|
||||||
|
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue