2020-04-25 08:51:00 -07:00
|
|
|
.card
|
2020-05-10 02:10:06 -07:00
|
|
|
%ul.list-group#notifications
|
|
|
|
- if @notifications.count.zero?
|
2020-04-25 08:51:00 -07:00
|
|
|
%li.list-group-item.text-center
|
|
|
|
.notifications--none
|
2020-05-08 15:50:46 -07:00
|
|
|
%i.fa.fa-bell-o.notification__bell-icon
|
2020-04-25 08:51:00 -07:00
|
|
|
%p
|
2020-05-10 02:10:06 -07:00
|
|
|
- if params[:type] != 'all'
|
2020-04-25 08:51:00 -07:00
|
|
|
No new notifications.
|
|
|
|
- else
|
|
|
|
No notifications.
|
|
|
|
- else
|
|
|
|
- @notifications.each do |notification|
|
2020-04-26 06:26:55 -07:00
|
|
|
%li.list-group-item
|
|
|
|
.media
|
|
|
|
= render "notifications/type/#{notification.target_type.downcase}", notification: notification
|
2020-04-25 08:51:00 -07:00
|
|
|
|
2020-05-08 19:39:09 -07:00
|
|
|
- unless @notifications.count.zero?
|
|
|
|
= render 'shared/cursored_pagination_dummy', more_data_available: @more_data_available, last_id: @notifications_last_id, permitted_params: %i[type]
|
2020-04-25 08:51:00 -07:00
|
|
|
|
2020-05-08 19:39:09 -07:00
|
|
|
- if @more_data_available
|
2020-05-10 02:10:06 -07:00
|
|
|
%button.btn.btn-default#load-more-btn{ type: :button, data: { last_id: @notifications_last_id } }
|
2020-05-08 19:39:09 -07:00
|
|
|
Load more
|