95 lines
4.6 KiB
Plaintext
95 lines
4.6 KiB
Plaintext
%li.list-group-item
|
|
.media
|
|
- case notification.target_type
|
|
- when "Answer"
|
|
.pull-left
|
|
%i.fa.fa-2x.fa-fw.fa-exclamation
|
|
.media-body
|
|
.notification--heading
|
|
%img.notification--img-sm{src: notification.target.user.profile_picture.url(:small)}
|
|
= user_screen_name notification.target.user
|
|
answered
|
|
= link_to "your question", show_user_answer_path(username: notification.target.user.screen_name, id: notification.target.id)
|
|
= time_tooltip(notification.target)
|
|
ago
|
|
.list-group.notification--list
|
|
.list-group-item
|
|
.media.question-media
|
|
.media-body
|
|
%h6.notification--list-heading question
|
|
.notification--list-content= markdown notification.target.question.content
|
|
.list-group-item
|
|
.media.question-media
|
|
.media-body
|
|
%h6.notification--list-heading answer
|
|
.notification--list-content= markdown notification.target.content
|
|
- when "Relationship"
|
|
.pull-left
|
|
%img.img-rounded.notification--dropdown-img{src: notification.target.source.profile_picture.url(:small)}
|
|
.media-body
|
|
%h6.media-heading.notification--dropdown-user
|
|
= user_screen_name notification.target.source
|
|
.notification--dropdown-text
|
|
= raw t('views.notifications.relationship.body', time: time_ago_in_words(notification.target.created_at))
|
|
- when "Smile"
|
|
.pull-left
|
|
%i.fa.fa-2x.fa-fw.fa-smile-o
|
|
.media-body
|
|
.notification--heading
|
|
%img.notification--img-sm{src: notification.target.user.profile_picture.url(:small)}
|
|
= user_screen_name notification.target.user
|
|
smiled
|
|
= link_to "your answer", show_user_answer_path(username: notification.target.user.screen_name, id: notification.target.answer.id)
|
|
= time_tooltip(notification.target)
|
|
ago
|
|
.list-group.notification--list
|
|
.list-group-item
|
|
.media.question-media
|
|
.media-body
|
|
%h6.notification--list-heading answer
|
|
.notification--list-content= markdown notification.target.answer.content
|
|
- when "CommentSmile"
|
|
.pull-left
|
|
%i.fa.fa-2x.fa-fw.fa-smile-o
|
|
.media-body
|
|
.notification--heading
|
|
%img.notification--img-sm{src: notification.target.user.profile_picture.url(:small)}
|
|
= user_screen_name notification.target.user
|
|
smiled
|
|
= link_to "your comment", show_user_answer_path(username: notification.target.user.screen_name, id: notification.target.comment.answer.id)
|
|
= time_tooltip(notification.target)
|
|
ago
|
|
.list-group.notification--list
|
|
.list-group-item
|
|
.media.question-media
|
|
.media-body
|
|
%h6.notification--list-heading comment
|
|
.notification--list-content= markdown notification.target.comment.content
|
|
- when "Comment"
|
|
.pull-left
|
|
%i.fa.fa-2x.fa-fw.fa-comments
|
|
.media-body
|
|
.notification--heading
|
|
%img.notification--img-sm{src: notification.target.user.profile_picture.url(:small)}
|
|
= user_screen_name notification.target.user
|
|
commented on
|
|
- if notification.target.answer.user == current_user
|
|
= link_to "your answer", show_user_answer_path(username: notification.target.user.screen_name, id: notification.target.answer.id)
|
|
- elsif notification.target.user == notification.target.answer.user
|
|
= link_to "their answer", show_user_answer_path(username: notification.target.user.screen_name, id: notification.target.answer.id)
|
|
- else
|
|
= link_to "#{notification.target.answer.user.screen_name}'s answer", show_user_answer_path(username: notification.target.user.screen_name, id: notification.target.answer.id)
|
|
= time_tooltip(notification.target)
|
|
ago
|
|
.list-group.notification--list
|
|
.list-group-item
|
|
.media.question-media
|
|
.media-body
|
|
%h6.notification--list-heading answer
|
|
.notification--list-content= markdown notification.target.answer.content
|
|
.list-group-item
|
|
.media.question-media
|
|
.media-body
|
|
%h6.notification--list-heading comment
|
|
.notification--list-content= markdown notification.target.content
|