Place notifications in individual cards

This commit is contained in:
Karina Kwiatek 2022-07-20 17:00:15 +02:00 committed by Karina Kwiatek
parent 9a79670e53
commit 83e0f7a711
1 changed files with 13 additions and 13 deletions

View File

@ -1,16 +1,16 @@
.card
%ul.list-group#notifications
- if @notifications.count.zero?
%li.list-group-item.text-center
.notifications--none
%i.fa.fa-bell-o.notification__bell-icon
%p
- if params[:type] == 'all'
= t(".none_filtered")
- else
= t(".none")
- else
- @notifications.each do |notification|
%ul.list-group#notifications
- if @notifications.count.zero?
%li.list-group-item.text-center
.notifications--none
%i.fa.fa-bell-o.notification__bell-icon
%p
- if params[:type] == 'all'
= t(".none_filtered")
- else
= t(".none")
- else
- @notifications.each do |notification|
.card
%li.list-group-item
.media
= render "notifications/type/#{notification.target.class.name.downcase.split('::').last}", notification: notification