Merge branch 'i18n-notifications-of-user-profile' into 'master'
Externalize strings of notifications page in user profile See merge request gitlab-org/gitlab-ce!28745
This commit is contained in:
commit
1215a3f1ad
|
@ -14,9 +14,9 @@ class Profiles::NotificationsController < Profiles::ApplicationController
|
|||
result = Users::UpdateService.new(current_user, user_params.merge(user: current_user)).execute
|
||||
|
||||
if result[:status] == :success
|
||||
flash[:notice] = "Notification settings saved"
|
||||
flash[:notice] = _("Notification settings saved")
|
||||
else
|
||||
flash[:alert] = "Failed to save new settings"
|
||||
flash[:alert] = _("Failed to save new settings")
|
||||
end
|
||||
|
||||
redirect_back_or_default(default: profile_notifications_path)
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
- page_title "Notifications"
|
||||
- page_title _('Notifications')
|
||||
- @content_class = "limit-container-width" unless fluid_layout
|
||||
|
||||
%div
|
||||
|
@ -14,12 +14,12 @@
|
|||
%h4.prepend-top-0
|
||||
= page_title
|
||||
%p
|
||||
You can specify notification level per group or per project.
|
||||
= _('You can specify notification level per group or per project.')
|
||||
%p
|
||||
By default, all projects and groups will use the global notifications setting.
|
||||
= _('By default, all projects and groups will use the global notifications setting.')
|
||||
.col-lg-8
|
||||
%h5.prepend-top-0
|
||||
Global notification settings
|
||||
= _('Global notification settings')
|
||||
|
||||
= form_for @user, url: profile_notifications_path, method: :put, html: { class: 'update-notifications prepend-top-default' } do |f|
|
||||
= render_if_exists 'profiles/notifications/email_settings', form: f
|
||||
|
@ -35,19 +35,19 @@
|
|||
= form_for @user, url: profile_notifications_path, method: :put do |f|
|
||||
%label{ for: 'user_notified_of_own_activity' }
|
||||
= f.check_box :notified_of_own_activity
|
||||
%span Receive notifications about your own activity
|
||||
%span= _('Receive notifications about your own activity')
|
||||
|
||||
%hr
|
||||
%h5
|
||||
Groups (#{@group_notifications.count})
|
||||
= _('Groups (%{count})') % { count: @group_notifications.count }
|
||||
%div
|
||||
%ul.bordered-list
|
||||
- @group_notifications.each do |setting|
|
||||
= render 'group_settings', setting: setting, group: setting.source
|
||||
%h5
|
||||
Projects (#{@project_notifications.count})
|
||||
= _('Projects (%{count})') % { count: @project_notifications.count }
|
||||
%p.account-well
|
||||
To specify the notification level per project of a group you belong to, you need to visit project page and change notification level there.
|
||||
= _('To specify the notification level per project of a group you belong to, you need to visit project page and change notification level there.')
|
||||
.append-bottom-default
|
||||
%ul.bordered-list
|
||||
- @project_notifications.each do |setting|
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
= icon('caret-down')
|
||||
.sr-only Toggle dropdown
|
||||
- else
|
||||
%button.dropdown-new.btn.btn-default.has-tooltip.notifications-btn#notifications-button{ type: "button", title: "Notification setting", class: "#{btn_class}", "aria-label" => "Notification setting: #{notification_title(notification_setting.level)}", data: { container: "body", toggle: "dropdown", target: notifications_menu_identifier("dropdown", notification_setting), flip: "false" } }
|
||||
%button.dropdown-new.btn.btn-default.has-tooltip.notifications-btn#notifications-button{ type: "button", title: _("Notification setting"), class: "#{btn_class}", "aria-label" => _("Notification setting - %{notification_title}") % { notification_title: notification_title(notification_setting.level) }, data: { container: "body", toggle: "dropdown", target: notifications_menu_identifier("dropdown", notification_setting), flip: "false" } }
|
||||
= icon("bell", class: "js-notification-loading")
|
||||
= notification_title(notification_setting.level)
|
||||
= icon("caret-down")
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
= sprite_icon("arrow-down", css_class: "icon mr-0")
|
||||
.sr-only Toggle dropdown
|
||||
- else
|
||||
%button.dropdown-new.btn.btn-default.has-tooltip.notifications-btn#notifications-button{ type: "button", title: "Notification setting - #{notification_title(notification_setting.level)}", class: "#{btn_class}", "aria-label" => "Notification setting: #{notification_title(notification_setting.level)}", data: { container: "body", placement: 'top', toggle: "dropdown", target: notifications_menu_identifier("dropdown", notification_setting), flip: "false" } }
|
||||
%button.dropdown-new.btn.btn-default.has-tooltip.notifications-btn#notifications-button{ type: "button", title: _("Notification setting - %{notification_title}") % { notification_title: notification_title(notification_setting.level) }, class: "#{btn_class}", "aria-label" => _("Notification setting - %{notification_title}") % { notification_title: notification_title(notification_setting.level) }, data: { container: "body", placement: 'top', toggle: "dropdown", target: notifications_menu_identifier("dropdown", notification_setting), flip: "false" } }
|
||||
= notification_setting_icon(notification_setting)
|
||||
%span.js-notification-loading.fa.hidden
|
||||
= sprite_icon("arrow-down", css_class: "icon")
|
||||
|
|
|
@ -8,5 +8,5 @@
|
|||
%li.divider
|
||||
%li
|
||||
%a.update-notification{ href: "#", role: "button", class: ("is-active" if notification_setting.custom?), data: { toggle: "modal", target: "#" + notifications_menu_identifier("modal", notification_setting), notification_level: "custom", notification_title: "Custom" } }
|
||||
%strong.dropdown-menu-inner-title Custom
|
||||
%strong.dropdown-menu-inner-title= s_('NotificationSetting|Custom')
|
||||
%span.dropdown-menu-inner-content= notification_description("custom")
|
||||
|
|
|
@ -1629,6 +1629,9 @@ msgstr ""
|
|||
msgid "By default GitLab sends emails in HTML and plain text formats so mail clients can choose what format to use. Disable this option if you only want to send emails in plain text format."
|
||||
msgstr ""
|
||||
|
||||
msgid "By default, all projects and groups will use the global notifications setting."
|
||||
msgstr ""
|
||||
|
||||
msgid "ByAuthor|by"
|
||||
msgstr ""
|
||||
|
||||
|
@ -4653,6 +4656,9 @@ msgstr ""
|
|||
msgid "Given access %{time_ago}"
|
||||
msgstr ""
|
||||
|
||||
msgid "Global notification settings"
|
||||
msgstr ""
|
||||
|
||||
msgid "Go Back"
|
||||
msgstr ""
|
||||
|
||||
|
@ -4809,6 +4815,9 @@ msgstr ""
|
|||
msgid "Groups"
|
||||
msgstr ""
|
||||
|
||||
msgid "Groups (%{count})"
|
||||
msgstr ""
|
||||
|
||||
msgid "Groups can also be nested by creating %{subgroup_docs_link_start}subgroups%{subgroup_docs_link_end}."
|
||||
msgstr ""
|
||||
|
||||
|
@ -6557,6 +6566,9 @@ msgstr ""
|
|||
msgid "Notification setting - %{notification_title}"
|
||||
msgstr ""
|
||||
|
||||
msgid "Notification settings saved"
|
||||
msgstr ""
|
||||
|
||||
msgid "NotificationEvent|Close issue"
|
||||
msgstr ""
|
||||
|
||||
|
@ -6608,6 +6620,9 @@ msgstr ""
|
|||
msgid "NotificationLevel|Watch"
|
||||
msgstr ""
|
||||
|
||||
msgid "NotificationSetting|Custom"
|
||||
msgstr ""
|
||||
|
||||
msgid "Notifications"
|
||||
msgstr ""
|
||||
|
||||
|
@ -7771,6 +7786,9 @@ msgstr ""
|
|||
msgid "Projects"
|
||||
msgstr ""
|
||||
|
||||
msgid "Projects (%{count})"
|
||||
msgstr ""
|
||||
|
||||
msgid "Projects Successfully Retrieved"
|
||||
msgstr ""
|
||||
|
||||
|
@ -7999,6 +8017,9 @@ msgstr ""
|
|||
msgid "Real-time features"
|
||||
msgstr ""
|
||||
|
||||
msgid "Receive notifications about your own activity"
|
||||
msgstr ""
|
||||
|
||||
msgid "Recent Project Activity"
|
||||
msgstr ""
|
||||
|
||||
|
@ -10324,6 +10345,9 @@ msgstr ""
|
|||
msgid "To preserve performance only <strong>%{display_size} of %{real_size}</strong> files are displayed."
|
||||
msgstr ""
|
||||
|
||||
msgid "To specify the notification level per project of a group you belong to, you need to visit project page and change notification level there."
|
||||
msgstr ""
|
||||
|
||||
msgid "To start serving your jobs you can add Runners to your group"
|
||||
msgstr ""
|
||||
|
||||
|
@ -11313,6 +11337,9 @@ msgstr ""
|
|||
msgid "You can set up jobs to only use Runners with specific tags. Separate tags with commas."
|
||||
msgstr ""
|
||||
|
||||
msgid "You can specify notification level per group or per project."
|
||||
msgstr ""
|
||||
|
||||
msgid "You can test your .gitlab-ci.yml in %{linkStart}CI Lint%{linkEnd}."
|
||||
msgstr ""
|
||||
|
||||
|
|
Loading…
Reference in New Issue