diff --git a/static/nryg.less b/static/nryg.less
index e94aa47e..f33eb704 100644
--- a/static/nryg.less
+++ b/static/nryg.less
@@ -1,6 +1,8 @@
@background-color: #0d193b;
@text-color: #a0ccff;
@accent-color: white;
+@link-color: #00aaff;
+@visited-color: #aa66ff;
body {
font-family: sans-serif;
@@ -12,6 +14,18 @@ h1, h2, h3, h4, h5, h6 {
color: @accent-color;
}
+a {
+ color: @link-color;
+}
+
+a:active {
+ color: @link-color;
+}
+
+a:visited {
+ color: @visited-color;
+}
+
input[type="text"], input[type="password"] {
background-color: rgba(red(@text-color), green(@text-color), blue(@text-color), 0.1);
color: @text-color;
@@ -32,6 +46,7 @@ textarea {
margin: 1px;
border: 1px dotted @text-color;
width: 100%;
+ height: 300px;
}
button, input[type="submit"] {
diff --git a/webserver.py b/webserver.py
index 363b1102..c27a88d7 100644
--- a/webserver.py
+++ b/webserver.py
@@ -166,7 +166,7 @@ def page_wiki(key: str):
db_session.close()
if wiki_page is None:
return render_template("wiki.html", key=key)
- converted_md = Markup(markdown.markdown(escape(wiki_page.content)))
+ converted_md = Markup(markdown.markdown(escape(wiki_page.content), output_format="html5"))
return render_template("wiki.html", key=key, wiki_page=wiki_page, converted_md=converted_md,
wiki_log=wiki_latest_edit)
elif request.method == "POST":
@@ -186,12 +186,15 @@ def page_wiki(key: str):
new_log = db.WikiLog(editor=user, edited_key=key, timestamp=datetime.datetime.now(), reason=edit_reason)
db_session.add(new_log)
db_session.commit()
- telegram_bot.send_message(config["Telegram"]["main_group"],
- f'ℹ️ La pagina wiki {key} è stata'
- f' modificata da'
- f' {user.username}:'
- f' {"Nessun motivo specificato." if not edit_reason else edit_reason}',
- parse_mode="HTML")
+ try:
+ telegram_bot.send_message(config["Telegram"]["main_group"],
+ f'ℹ️ La pagina wiki {key} è stata'
+ f' modificata da'
+ f' {user.username}:'
+ f' {"Nessun motivo specificato." if not edit_reason else edit_reason}\n',
+ parse_mode="HTML")
+ except:
+ pass
return redirect(url_for("page_wiki", key=key))