# HG changeset patch # User Goffi # Date 1558901106 -7200 # Node ID a1fa6744c78e275412a12800a1007067de316d55 # Parent d5f4f29b1c5dc54534e1f1eb923f810398a5f8d8 base: handle notifications through "notifications" variable diff -r d5f4f29b1c5d -r a1fa6744c78e sat_templates/templates/default/base/base.html --- a/sat_templates/templates/default/base/base.html Sun May 05 20:36:00 2019 +0200 +++ b/sat_templates/templates/default/base/base.html Sun May 26 22:05:06 2019 +0200 @@ -104,6 +104,15 @@ {% endblock confirm %} {% endif %} + {% if notifications %} + {% block notifications %} + {% for notification in notifications %} +
+ {{ notification.message }} +
+ {% endfor %} + {% endblock notifications %} + {% endif %} diff -r d5f4f29b1c5d -r a1fa6744c78e sat_templates/templates/default/static/styles.css --- a/sat_templates/templates/default/static/styles.css Sun May 05 20:36:00 2019 +0200 +++ b/sat_templates/templates/default/static/styles.css Sun May 26 22:05:06 2019 +0200 @@ -1196,7 +1196,22 @@ * Notifications * *****************/ + +.notification { + text-align: center; + padding: 1em; + font-size: 1.2em; + font-weight: bold; + width: 60%; + margin: 1.5em auto; +} + +.notification--warning { + background-color: red; +} + .notification.retry { + /* FIXME: inconcistent naming */ position: fixed; top: 1rem; margin: auto;