line 51 of _notification.html.haml line 57 of _notifications.html.haml
This commit is contained in:
parent
b8c0032986
commit
f564ef724e
|
@ -55,16 +55,10 @@
|
|||
%h6.media-heading.notification--dropdown-user
|
||||
= user_screen_name notification.target.user
|
||||
.notification--dropdown-text
|
||||
/ TODO: holy fuck I'm not going to touch this with locales for now, this one will be complicated.
|
||||
commented on
|
||||
%a{href: show_user_answer_path(username: notification.target.user.screen_name, id: notification.target.answer.id), title: "#{notification.target.answer.content[0..40]}...", data: { toggle: :tooltip, placement: :top }}
|
||||
- if notification.target.answer.user == current_user
|
||||
your
|
||||
- elsif notification.target.user == notification.target.answer.user
|
||||
their
|
||||
- else
|
||||
= user_screen_name(notification.target.answer.user, false, false) + "'s"
|
||||
answer
|
||||
= time_ago_in_words notification.target.created_at
|
||||
ago
|
||||
- if notification.target.answer.user == current_user
|
||||
= raw t('views.notifications.comment.body', content: link_to(t('views.notifications.comment.your', user: user_screen_name(current_user, false, false)), show_user_answer_path(username: notification.target.user.screen_name, id: notification.target.answer.id)), time: time_tooltip(notification.target))
|
||||
- elsif notification.target.user == notification.target.answer.user
|
||||
= raw t('views.notifications.comment.body', content: link_to(t('views.notifications.comment.their', user: user_screen_name(notification.target.answer.user, false, false)), show_user_answer_path(username: notification.target.user.screen_name, id: notification.target.answer.id)), time: time_tooltip(notification.target))
|
||||
- else
|
||||
= raw t('views.notifications.comment.body', content: link_to(t('views.notifications.comment.user', user: user_screen_name(notification.target.user, false, false)), show_user_answer_path(username: notification.target.user.screen_name, id: notification.target.answer.id)), time: time_tooltip(notification.target))
|
||||
%li= link_to "#{t('views.notifications.show')}#{t('views.notifications.mark') if notifications.pluck(:new).any?}", notifications_path
|
||||
|
|
|
@ -48,18 +48,11 @@
|
|||
%h6.media-heading.notification--user
|
||||
= user_screen_name notification.target.user
|
||||
%p.notification--text
|
||||
/ TODO: holy fuck I'm not going to touch this with locales for now, this one will be complicated.
|
||||
commented on
|
||||
%a{href: show_user_answer_path(username: notification.target.user.screen_name, id: notification.target.answer.id), title: "#{notification.target.answer.content[0..40]}...", data: { toggle: :tooltip, placement: :top }}
|
||||
- if notification.target.answer.user == current_user
|
||||
your
|
||||
- elsif notification.target.user == notification.target.answer.user
|
||||
their
|
||||
- else
|
||||
= user_screen_name(notification.target.answer.user, false, false) + "'s"
|
||||
answer
|
||||
%span{title: notification.target.created_at, data: { toggle: :tooltip, placement: :bottom }}
|
||||
= time_ago_in_words notification.target.created_at
|
||||
ago
|
||||
- if notification.target.answer.user == current_user
|
||||
= raw t('views.notifications.comment.body', content: link_to(t('views.notifications.comment.your', user: user_screen_name(current_user, false, false)), show_user_answer_path(username: notification.target.user.screen_name, id: notification.target.answer.id)), time: time_tooltip(notification.target))
|
||||
- elsif notification.target.user == notification.target.answer.user
|
||||
= raw t('views.notifications.comment.body', content: link_to(t('views.notifications.comment.their', user: user_screen_name(notification.target.answer.user, false, false)), show_user_answer_path(username: notification.target.user.screen_name, id: notification.target.answer.id)), time: time_tooltip(notification.target))
|
||||
- else
|
||||
= raw t('views.notifications.comment.body', content: link_to(t('views.notifications.comment.user', user: user_screen_name(notification.target.user, false, false)), show_user_answer_path(username: notification.target.user.screen_name, id: notification.target.answer.id)), time: time_tooltip(notification.target))
|
||||
.notification--icon
|
||||
%i.fa.fa-comments
|
||||
|
|
|
@ -32,9 +32,15 @@ en:
|
|||
relationship:
|
||||
body: "followed you %{time} ago"
|
||||
smile:
|
||||
body: "smiled at %{content} %{time} ago" # content v
|
||||
answer: "your answer" # content if smile
|
||||
comment: "your comment" # content if commentsmile
|
||||
body: "smiled at %{content} %{time} ago" # see below for 'content' vvvv
|
||||
answer: "your answer" # content if smile, 'smiled at your answer'
|
||||
comment: "your comment" # content if commentsmile, 'smiled at your comment'
|
||||
comment:
|
||||
body: 'commented on %{content} %{time} ago' # see below for 'content' vvvv
|
||||
your: 'your answer' # 'commented on your answer'
|
||||
their: 'their answer' # 'commented on their answer'
|
||||
user: '#{user}\'s answer' # 'commented on user's asnwer'
|
||||
# all three have the 'user' variable
|
||||
tabs:
|
||||
all: "All notifications"
|
||||
answer: "Answers"
|
||||
|
|
Loading…
Reference in New Issue