diff options
Diffstat (limited to 'app/assets/javascripts/projects/settings_service_desk')
3 files changed, 30 insertions, 6 deletions
diff --git a/app/assets/javascripts/projects/settings_service_desk/components/custom_email_form.vue b/app/assets/javascripts/projects/settings_service_desk/components/custom_email_form.vue index 4affcd926d4..09bc275cbd4 100644 --- a/app/assets/javascripts/projects/settings_service_desk/components/custom_email_form.vue +++ b/app/assets/javascripts/projects/settings_service_desk/components/custom_email_form.vue @@ -1,5 +1,14 @@ <script> -import { GlButton, GlForm, GlFormGroup, GlFormInputGroup, GlFormInput } from '@gitlab/ui'; +import { + GlButton, + GlForm, + GlFormGroup, + GlFormInputGroup, + GlFormInput, + GlLink, + GlSprintf, +} from '@gitlab/ui'; +import { helpPagePath } from '~/helpers/help_page_helper'; import { isEmptyValue, hasMinimumLength, isIntegerGreaterThan, isEmail } from '~/lib/utils/forms'; import ClipboardButton from '~/vue_shared/components/clipboard_button.vue'; import { @@ -23,6 +32,9 @@ import { } from '../custom_email_constants'; export default { + customEmailHelpUrl: helpPagePath('user/project/service_desk/configure.html', { + anchor: 'custom-email-address', + }), components: { ClipboardButton, GlButton, @@ -30,6 +42,8 @@ export default { GlFormGroup, GlFormInputGroup, GlFormInput, + GlLink, + GlSprintf, }, I18N_FORM_INTRODUCTION_PARAGRAPH, I18N_FORM_CUSTOM_EMAIL_LABEL, @@ -137,7 +151,19 @@ export default { <template> <div> - <p>{{ $options.I18N_FORM_INTRODUCTION_PARAGRAPH }}</p> + <p> + <gl-sprintf :message="$options.I18N_FORM_INTRODUCTION_PARAGRAPH"> + <template #link="{ content }"> + <gl-link + :href="$options.customEmailHelpUrl" + class="gl-display-inline-block" + target="_blank" + > + {{ content }} + </gl-link> + </template> + </gl-sprintf> + </p> <gl-form class="js-quick-submit" @submit.prevent="onSubmit"> <gl-form-group :label="$options.I18N_FORM_FORWARDING_LABEL" @@ -149,7 +175,6 @@ export default { id="custom-email-form-forwarding" ref="service-desk-incoming-email" type="text" - data-testid="custom-email-form-forwarding" :aria-label="$options.I18N_FORM_FORWARDING_LABEL" :value="incomingEmail" :disabled="true" @@ -167,7 +192,6 @@ export default { <gl-form-group :label="$options.I18N_FORM_CUSTOM_EMAIL_LABEL" label-for="custom-email-form-custom-email" - data-testid="form-group-custom-email" :invalid-feedback="$options.I18N_FORM_INVALID_FEEDBACK_CUSTOM_EMAIL" class="gl-mt-3" :description="$options.I18N_FORM_CUSTOM_EMAIL_DESCRIPTION" @@ -191,7 +215,6 @@ export default { <gl-form-group :label="$options.I18N_FORM_SMTP_ADDRESS_LABEL" label-for="custom-email-form-smtp-address" - data-testid="form-group-smtp-address" :invalid-feedback="$options.I18N_FORM_INVALID_FEEDBACK_SMTP_ADDRESS" class="gl-mt-3" > diff --git a/app/assets/javascripts/projects/settings_service_desk/components/custom_email_wrapper.vue b/app/assets/javascripts/projects/settings_service_desk/components/custom_email_wrapper.vue index 7e040e6001a..03ba99bcf71 100644 --- a/app/assets/javascripts/projects/settings_service_desk/components/custom_email_wrapper.vue +++ b/app/assets/javascripts/projects/settings_service_desk/components/custom_email_wrapper.vue @@ -233,6 +233,7 @@ export default { <gl-link :href="$options.FEEDBACK_ISSUE_URL" target="_blank" + data-testid="feedback-link" class="gl-text-blue-600 font-size-inherit" >{{ content }} </gl-link> diff --git a/app/assets/javascripts/projects/settings_service_desk/custom_email_constants.js b/app/assets/javascripts/projects/settings_service_desk/custom_email_constants.js index cdf2e53982e..aafd77bd25e 100644 --- a/app/assets/javascripts/projects/settings_service_desk/custom_email_constants.js +++ b/app/assets/javascripts/projects/settings_service_desk/custom_email_constants.js @@ -17,7 +17,7 @@ export const I18N_TOAST_ENABLED = s__('ServiceDesk|Custom email enabled.'); export const I18N_TOAST_DISABLED = s__('ServiceDesk|Custom email disabled.'); export const I18N_FORM_INTRODUCTION_PARAGRAPH = s__( - 'ServiceDesk|Connect a custom email address your customers can use to create Service Desk issues. Forward all emails from your custom email address to the Service Desk email address of this project. GitLab will send Service Desk emails from the custom address on your behalf using your SMTP credentials.', + 'ServiceDesk|Connect a custom email address your customers can use to create Service Desk issues. Forward all emails from your custom email address to the Service Desk email address of this project. GitLab will send Service Desk emails from the custom address on your behalf using your SMTP credentials. %{linkStart}Learn more about prerequisites and the verification process%{linkEnd}.', ); export const I18N_FORM_FORWARDING_LABEL = s__( 'ServiceDesk|Service Desk email address to forward emails to', |