aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig
diff options
context:
space:
mode:
Diffstat (limited to 'src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig')
-rw-r--r--src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig45
1 files changed, 45 insertions, 0 deletions
diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig
index 2dab1c18..6e2828de 100644
--- a/src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig
+++ b/src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig
@@ -105,6 +105,13 @@
105 <i class="material-icons">search</i> 105 <i class="material-icons">search</i>
106 </a> 106 </a>
107 </li> 107 </li>
108 <li id="button_notifications">
109 {% set unreadNotifs = app.user.notifications | unread_notif | length %}
110 <a class="nav-panel-menu button-collapse-right tooltipped js-notifications-action" data-position="bottom" data-delay="50" data-tooltip="{{ 'menu.top.notifications' | trans }}" href="#" data-activates="notifications">
111 <i class="material-icons">notifications{% if unreadNotifs == 0 %}_none{% endif %}</i>
112 {% if unreadNotifs > 0 %}<span id="notifications-count" class="red-text text-accent-2">{{ unreadNotifs }}</span>{% endif %}
113 </a>
114 </li>
108 <li id="button_filters"> 115 <li id="button_filters">
109 <a class="nav-panel-menu button-collapse-right tooltipped js-filters-action" data-position="bottom" data-delay="50" data-tooltip="{{ 'menu.top.filter_entries'|trans }}" href="#" data-activates="filters"> 116 <a class="nav-panel-menu button-collapse-right tooltipped js-filters-action" data-position="bottom" data-delay="50" data-tooltip="{{ 'menu.top.filter_entries'|trans }}" href="#" data-activates="filters">
110 <i class="material-icons">filter_list</i> 117 <i class="material-icons">filter_list</i>
@@ -130,6 +137,44 @@
130 </nav> 137 </nav>
131{% endblock %} 138{% endblock %}
132 139
140{% block content %}
141
142 <div id="notifications" class="side-nav">
143 <ul class="collection">
144 {% for notification in app.user.notifications | slice(0, 10) %}
145 <li class="notification collection-item avatar{% if not notification.read %} light-blue lighten-5{% else %} grey-text{% endif %}">
146 <i class="material-icons circle">{% spaceless %}
147 {% if notification.type == constant('TYPE_ADMIN', notification) %}
148 build
149 {% elseif notification.type == constant('TYPE_USER', notification) %}
150 person
151 {% elseif notification.type == constant('TYPE_RELEASE', notification) %}
152 new_releases
153 {% endif %}
154 {% endspaceless %}</i>
155 <span class="title">{{ notification.title }}</span>
156 <p><em>{{ notification.timestamp | date }}</em></p>
157 <div>
158 {% for action in notification.actions %}
159 <a class="btn waves-effect waves-light {% spaceless %}
160 {% if action.type == constant('TYPE_OK', action) %}
161 {% elseif action.type == constant('TYPE_YES', action) %}
162 cyan
163 {% elseif action.type == constant('TYPE_NO', action) %}
164 red
165 {% elseif action.type == constant('TYPE_INFO', action) %}
166 blue-grey
167 {% endif %}
168 {% endspaceless %}" href="{{ action.link }}">{{ action.label }}</a>
169 {% endfor %}
170 </div>
171 </li>
172 {% endfor %}
173 </ul>
174 <a class="waves-effect waves-light btn" href="{{ path('notifications-all') }}">{{ 'notifications.sidebar.view_more' | trans }}</a>
175 </div>
176{% endblock %}
177
133{% block footer %} 178{% block footer %}
134 <footer class="page-footer cyan darken-2"> 179 <footer class="page-footer cyan darken-2">
135 <div class="footer-copyright"> 180 <div class="footer-copyright">