aboutsummaryrefslogtreecommitdiffstats
path: root/python/fatcat_web/templates/base.html
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@robocracy.org>2021-02-26 11:30:18 -0800
committerBryan Newbold <bnewbold@robocracy.org>2021-02-26 12:03:32 -0800
commitfc9edfb1b65260f41f204d11bf130ceb35cb84e0 (patch)
tree3620d3c2c5b40e4b6a9c5cac7bb63f7a284eedc5 /python/fatcat_web/templates/base.html
parent901e4f4c23398e19e2595c374f2fa45e4773e992 (diff)
downloadfatcat-fc9edfb1b65260f41f204d11bf130ceb35cb84e0.tar.gz
fatcat-fc9edfb1b65260f41f204d11bf130ceb35cb84e0.zip
web: reduce flash() usage; have logins redirect
Diffstat (limited to 'python/fatcat_web/templates/base.html')
-rw-r--r--python/fatcat_web/templates/base.html17
1 files changed, 10 insertions, 7 deletions
diff --git a/python/fatcat_web/templates/base.html b/python/fatcat_web/templates/base.html
index 8cdc3fbf..73f33d0d 100644
--- a/python/fatcat_web/templates/base.html
+++ b/python/fatcat_web/templates/base.html
@@ -101,14 +101,17 @@
<main class="ui main container" style="margin-top: 6em; margin-bottom: 2em;" {% block main_extra_attr %}{% endblock %}>
{% with messages = get_flashed_messages() %}
{% if messages %}
- <div class="ui message">
+ <div class="ui info message" style="margin: 1em auto; max-width: 45em;">
{# Needs more javascript: <i class="close icon"></i> #}
- <div class="header">Flash Message!</div>
- <ul class="list">
- {% for message in messages %}
- <li>{{ message|safe }}
- {% endfor %}
- </ul>
+ {% if messages|length == 1 %}
+ <div class="header">{{ messages[0]|safe }}</div>
+ {% else %}
+ <ul class="list">
+ {% for message in messages %}
+ <li>{{ message|safe }}
+ {% endfor %}
+ </ul>
+ {% endif %}
</div>
{% endif %}
{% endwith %}