Commit 4ca8e36e authored by Coung Ngo's avatar Coung Ngo

Add internationalization to markdown textarea

Some sentences did not have internalization, which this commit
fixes
parent 39c1af46
<script>
/* eslint-disable @gitlab/vue-require-i18n-strings */
import { GlButton, GlLink, GlLoadingIcon } from '@gitlab/ui';
import { GlButton, GlLink, GlLoadingIcon, GlSprintf } from '@gitlab/ui';
export default {
components: {
GlButton,
GlLink,
GlLoadingIcon,
GlSprintf,
},
props: {
markdownDocsPath: {
......@@ -41,16 +41,27 @@ export default {
}}</gl-link>
</template>
<template v-if="hasQuickActionsDocsPath && markdownDocsPath">
<gl-link :href="markdownDocsPath" target="_blank">{{ __('Markdown') }}</gl-link>
and
<gl-link :href="quickActionsDocsPath" target="_blank">{{ __('quick actions') }}</gl-link>
are supported
<gl-sprintf
:message="
__(
'%{markdownDocsLinkStart}Markdown%{markdownDocsLinkEnd} and %{quickActionsDocsLinkStart}quick actions%{quickActionsDocsLinkEnd} are supported',
)
"
>
<template #markdownDocsLink="{content}">
<gl-link :href="markdownDocsPath" target="_blank">{{ content }}</gl-link>
</template>
<template #quickActionsDocsLink="{content}">
<gl-link :href="quickActionsDocsPath" target="_blank">{{ content }}</gl-link>
</template>
</gl-sprintf>
</template>
</div>
<span v-if="canAttachFile" class="uploading-container">
<span class="uploading-progress-container hide">
<i class="fa fa-file-image-o toolbar-button-icon" aria-hidden="true"></i>
<span class="attaching-file-message"></span>
<!-- eslint-disable-next-line @gitlab/vue-require-i18n-strings -->
<span class="uploading-progress">0%</span>
<gl-loading-icon inline class="align-text-bottom" />
</span>
......@@ -59,10 +70,21 @@ export default {
<i class="fa fa-file-image-o toolbar-button-icon" aria-hidden="true"></i>
</span>
<span class="uploading-error-message"></span>
<button class="retry-uploading-link" type="button">{{ __('Try again') }}</button> or
<button class="attach-new-file markdown-selector" type="button">
{{ __('attach a new file') }}
</button>
<gl-sprintf
:message="
__(
'%{retryButtonStart}Try again%{retryButtonEnd} or %{newFileButtonStart}attach a new file%{newFileButtonEnd}',
)
"
>
<template #retryButton="{content}">
<button class="retry-uploading-link" type="button">{{ content }}</button>
</template>
<template #newFileButton="{content}">
<button class="attach-new-file markdown-selector" type="button">{{ content }}</button>
</template>
</gl-sprintf>
</span>
<gl-button class="markdown-selector button-attach-file" variant="link">
<i class="fa fa-file-image-o toolbar-button-icon" aria-hidden="true"></i
......
......@@ -406,6 +406,9 @@ msgstr ""
msgid "%{lock_path} is locked by GitLab User %{lock_user_id}"
msgstr ""
msgid "%{markdownDocsLinkStart}Markdown%{markdownDocsLinkEnd} and %{quickActionsDocsLinkStart}quick actions%{quickActionsDocsLinkEnd} are supported"
msgstr ""
msgid "%{mergeLength}/%{usersLength} can merge"
msgstr ""
......@@ -479,6 +482,9 @@ msgid_plural "%{releases} releases"
msgstr[0] ""
msgstr[1] ""
msgid "%{retryButtonStart}Try again%{retryButtonEnd} or %{newFileButtonStart}attach a new file%{newFileButtonEnd}"
msgstr ""
msgid "%{screenreaderOnlyStart}Keyboard shorcuts%{screenreaderOnlyEnd} Disabled"
msgstr ""
......
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