diaspora/app/views/notifications/_notification.haml
cmrd Senya a3f208c380
Notifications and search page backend updates
Updates introduce support for preloading contacts to Gon in order
to support client-side rendering of aspect membership dropdown box.
2016-08-08 17:21:38 +03:00

15 lines
783 B
Text

.media.stream_element{:data=>{:guid => note.id, :type => (Notification.types.key(note.type) || '') }, :class => (note.unread ? 'unread' : 'read')}
.unread-toggle.pull-right
%i.entypo-eye{title: (note.unread ? t("notifications.index.mark_read") : t("notifications.index.mark_unread"))}
- if note.type == "Notifications::StartedSharing" && (!defined?(no_aspect_dropdown) || !no_aspect_dropdown)
- if note.target.present?
- gon_load_contact(note.contact)
.pull-right
.aspect_membership_dropdown.placeholder{data: {person_id: note.target.id}}
.media-object.pull-left
= person_image_link note.actors.first, :size => :thumb_small, :class => 'hovercardable'
.media-body
= notification_message_for(note)
%div
= timeago(note.updated_at)