Commit 1a4ed9bd authored by Jose Ivan Vargas's avatar Jose Ivan Vargas

Merge branch '293643-aqualls-source-branch-message-fix' into 'master'

Standardize language on branch deletion

See merge request gitlab-org/gitlab!62949
parents 8fc4998c 1d4c5266
<script>
import { GlIcon, GlSprintf, GlTooltipDirective } from '@gitlab/ui';
import { GlIcon, GlTooltipDirective } from '@gitlab/ui';
import { __ } from '../../locale';
export default {
i18n: {
removesBranchText: __('%{strongStart}Deletes%{strongEnd} source branch'),
removesBranchText: __('The source branch will be deleted'),
tooltipTitle: __('A user with write access to the source branch selected this option'),
},
components: {
GlIcon,
GlSprintf,
},
directives: {
GlTooltip: GlTooltipDirective,
......@@ -20,11 +19,7 @@ export default {
<template>
<p v-once class="mr-info-list gl-ml-7 gl-pb-5 gl-mb-0">
<span class="status-text">
<gl-sprintf :message="$options.i18n.removesBranchText">
<template #strong="{ content }">
<strong>{{ content }}</strong>
</template>
</gl-sprintf>
{{ $options.i18n.removesBranchText }}
</span>
<gl-icon
v-gl-tooltip.hover
......
......@@ -1104,7 +1104,7 @@ describe('ee merge request widget options', () => {
nextTick(() => {
const tooltip = wrapper.find('[data-testid="question-o-icon"]');
expect(wrapper.text()).toContain('Deletes source branch');
expect(wrapper.text()).toContain('The source branch will be deleted');
expect(tooltip.attributes('title')).toBe(
'A user with write access to the source branch selected this option',
);
......
......@@ -854,9 +854,6 @@ msgstr ""
msgid "%{state} epics"
msgstr ""
msgid "%{strongStart}Deletes%{strongEnd} source branch"
msgstr ""
msgid "%{strongStart}Tip:%{strongEnd} You can also checkout merge requests locally by %{linkStart}following these guidelines%{linkEnd}"
msgstr ""
......@@ -32784,6 +32781,9 @@ msgstr ""
msgid "The snippet is visible to any logged in user except external users."
msgstr ""
msgid "The source branch will be deleted"
msgstr ""
msgid "The specified tab is invalid, please select another"
msgstr ""
......
......@@ -432,7 +432,7 @@ RSpec.describe 'Merge request > User sees merge widget', :js do
it 'user cannot remove source branch', :sidekiq_might_not_need_inline do
expect(page).not_to have_field('remove-source-branch-input')
expect(page).to have_content('Deletes source branch')
expect(page).to have_content('The source branch will be deleted')
end
end
......
......@@ -532,7 +532,7 @@ describe('MrWidgetOptions', () => {
nextTick(() => {
const tooltip = wrapper.find('[data-testid="question-o-icon"]');
expect(wrapper.text()).toContain('Deletes source branch');
expect(wrapper.text()).toContain('The source branch will be deleted');
expect(tooltip.attributes('title')).toBe(
'A user with write access to the source branch selected this option',
);
......@@ -548,7 +548,7 @@ describe('MrWidgetOptions', () => {
nextTick(() => {
expect(wrapper.text()).toContain('The source branch has been deleted');
expect(wrapper.text()).not.toContain('Deletes source branch');
expect(wrapper.text()).not.toContain('The source branch will be deleted');
done();
});
......
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