Add translations for notification navigation

This commit is contained in:
Andreas Nedbal 2022-07-07 01:15:43 +02:00 committed by Georg Gadinger
parent af327b3f08
commit b551b7acdb
2 changed files with 47 additions and 4 deletions

View File

@ -6,16 +6,16 @@
%i.fa.fa-bell-o
- else
%i.fa.fa-bell
%span.sr-only Notifications
%span.sr-only= t('views.navigation.notifications')
%span.badge= notification_count
.dropdown-menu.dropdown-menu-right.notification-dropdown
- if notifications.count.zero?
.dropdown-item.text-center.p-2
%i.fa.fa-bell-o.notification__bell-icon
%p No new notifications.
%p= t(".none")
%a.dropdown-item.text-center{ href: notifications_path('all') }
%i.fa.fa-fw.fa-chevron-right
Show all notifications
= t(".all")
- else
- notifications.each do |notification|
.dropdown-item
@ -23,4 +23,4 @@
%a.dropdown-item.text-center{ href: notifications_path }
%i.fa.fa-fw.fa-chevron-right
Show all new notifications
= t(".new")

View File

@ -102,6 +102,41 @@ en:
permanent: "Permanent"
until: "Until %{until}"
expired: "Expired at %{until}"
navigation:
main:
notifications:
none: :notifications.index.none
all: "Show all notifications"
new: "Show all new notifications"
notifications:
index:
none_filtered: "No notifications."
none: "No new notifications."
type:
answer:
heading_html: "%{user} answered %{question} %{time} ago"
link_text: "your question"
comment:
heading: "%{user} commented on %{answer} %{time} ago"
active:
heading_html: :notifications.type.comment.heading
link_text: "your answer"
passive:
heading_html: :notifications.type.comment.heading
link_text: "their answer"
other:
heading_html: :notifications.type.comment.heading
link_text: "%{user}'s answer"
reaction:
heading: "%{user} smiled %{type} %{time} ago"
answer:
heading_html: :notifications.type.reaction.heading
link_text: "your answer"
comment:
heading_html: :notifications.type.reaction.heading
link_text: "your comment"
follow:
heading_html: "followed you %{time} ago"
services:
index:
title: "Service Settings"
@ -350,6 +385,14 @@ en:
url: "URL:"
confirm: "I understand the risk, proceed!"
tabs:
notifications:
all: "All notifications"
new: "New notifications"
answer: "Answers"
smile: "Smiles"
comment: "Comments"
commentsmile: "Comment Smiles"
relationship: "Followers"
settings:
account: "Account"
profile: "Profile"