Commit 3667dc8e authored by Marcel Amirault's avatar Marcel Amirault Committed by Kushal Pandya

Update Slack notifications integration UI text

parent 1d5f280e
......@@ -10,7 +10,7 @@ const typeWithPlaceholder = {
};
const placeholderForType = {
[typeWithPlaceholder.SLACK]: __('Slack channels (e.g. general, development)'),
[typeWithPlaceholder.SLACK]: __('general, development'),
[typeWithPlaceholder.MATTERMOST]: __('my-channel'),
};
......
......@@ -16,7 +16,7 @@ class SlackService < ChatNotificationService
end
def description
'Receive event notifications in Slack'
'Send notifications about project events to Slack.'
end
def self.to_param
......@@ -24,7 +24,7 @@ class SlackService < ChatNotificationService
end
def default_channel_placeholder
_('Slack channels (e.g. general, development)')
_('general, development')
end
def webhook_placeholder
......
- webhooks_link_url = 'https://slack.com/apps/A0F7XDUAZ-incoming-webhooks'
- webhooks_link_start = '<a href="%{url}" target="_blank" rel="noopener noreferrer">'.html_safe % { url: webhooks_link_url }
.info-well
.well-segment
%p= s_('SlackIntegration|This service sends notifications about project events to Slack channels. To set up this service:')
%ol
%li
= html_escape(s_('SlackIntegration|%{webhooks_link_start}Add an incoming webhook%{webhooks_link_end} in your Slack team. The default channel can be overridden for each event.')) % { webhooks_link_start: webhooks_link_start.html_safe, webhooks_link_end: '</a>'.html_safe }
%li
= html_escape(s_('SlackIntegration|Paste the %{strong_open}Webhook URL%{strong_close} into the field below.')) % { strong_open: '<strong>'.html_safe, strong_close: '</strong>'.html_safe }
%li
= html_escape(s_('SlackIntegration|Select events below to enable notifications. The %{strong_open}Slack channel names%{strong_close} and %{strong_open}Slack username%{strong_close} fields are optional.')) % { strong_open: '<strong>'.html_safe, strong_close: '</strong>'.html_safe }
%p.mt-3.mb-0
= html_escape(s_('SlackIntegration|%{strong_open}Note:%{strong_close} Usernames and private channels are not supported.')) % { strong_open: '<strong>'.html_safe, strong_close: '</strong>'.html_safe }
= link_to _('Learn more'), help_page_path('user/project/integrations/slack')
%p= s_('SlackIntegration|Sends notifications about project events to Slack channels.')
= link_to _('How do I set up this service?'), help_page_path('user/project/integrations/slack')
---
title: Update UI text for slack notifications integration
merge_request: 58845
author:
type: other
......@@ -900,6 +900,7 @@ RSpec.describe EE::NotificationService, :mailer do
let_it_be(:user) { create(:user) }
let_it_be(:alert) { create(:alert_management_alert) }
let_it_be(:project) { alert.project }
let(:tracking_params) do
{
event_names: 'i_incident_management_oncall_notification_sent',
......
......@@ -15708,6 +15708,9 @@ msgstr ""
msgid "How do I mirror repositories?"
msgstr ""
msgid "How do I set up this service?"
msgstr ""
msgid "How does cleanup work?"
msgstr ""
......@@ -28671,25 +28674,10 @@ msgstr ""
msgid "Slack application"
msgstr ""
msgid "Slack channels (e.g. general, development)"
msgstr ""
msgid "Slack integration allows you to interact with GitLab via slash commands in a chat window."
msgstr ""
msgid "SlackIntegration|%{strong_open}Note:%{strong_close} Usernames and private channels are not supported."
msgstr ""
msgid "SlackIntegration|%{webhooks_link_start}Add an incoming webhook%{webhooks_link_end} in your Slack team. The default channel can be overridden for each event."
msgstr ""
msgid "SlackIntegration|Paste the %{strong_open}Webhook URL%{strong_close} into the field below."
msgstr ""
msgid "SlackIntegration|Select events below to enable notifications. The %{strong_open}Slack channel names%{strong_close} and %{strong_open}Slack username%{strong_close} fields are optional."
msgstr ""
msgid "SlackIntegration|This service sends notifications about project events to Slack channels. To set up this service:"
msgid "SlackIntegration|Sends notifications about project events to Slack channels."
msgstr ""
msgid "SlackService|2. Paste the %{strong_open}Token%{strong_close} into the field below"
......@@ -36458,6 +36446,9 @@ msgid_plural "from %d jobs"
msgstr[0] ""
msgstr[1] ""
msgid "general, development"
msgstr ""
msgid "group"
msgstr ""
......
......@@ -138,11 +138,11 @@ describe('TriggerFields', () => {
const expectedResults = [
{
name: 'service[push_channel]',
placeholder: 'Slack channels (e.g. general, development)',
placeholder: 'general, development',
},
{
name: 'service[merge_request_channel]',
placeholder: 'Slack channels (e.g. general, development)',
placeholder: 'general, development',
},
];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment