Commit 4a8fa7fa authored by Tim Zallmann's avatar Tim Zallmann

Merge branch 'vue-i18n-js-ide-directory' into 'master'

Vue-i18n: autofix for app/assets/javascripts/ide directory

See merge request gitlab-org/gitlab-ce!29967
parents c1d250c2 11be4df3
......@@ -107,7 +107,8 @@ export default {
@click="openFileInEditor"
>
<span class="multi-file-commit-list-file-path d-flex align-items-center">
<file-icon :file-name="file.name" class="append-right-8" />{{ file.name }}
<file-icon :file-name="file.name" class="append-right-8" />
{{ file.name }}
</span>
<div class="ml-auto d-flex align-items-center">
<div class="d-flex align-items-center ide-commit-list-changed-icon">
......
......@@ -27,7 +27,7 @@ export default {
target="_blank"
rel="noopener noreferrer"
>
<span class="vertical-align-middle">Open in file view</span>
<span class="vertical-align-middle">{{ __('Open in file view') }}</span>
<icon :size="16" name="external-link" css-classes="vertical-align-middle space-right" />
</a>
</div>
......
......@@ -8,6 +8,7 @@ import { activityBarViews, viewerTypes } from '../constants';
import Editor from '../lib/editor';
import ExternalLink from './external_link.vue';
import FileTemplatesBar from './file_templates/bar.vue';
import { __ } from '~/locale';
export default {
components: {
......@@ -160,7 +161,14 @@ export default {
this.createEditorInstance();
})
.catch(err => {
flash('Error setting up editor. Please try again.', 'alert', document, null, false, true);
flash(
__('Error setting up editor. Please try again.'),
'alert',
document,
null,
false,
true,
);
throw err;
});
},
......@@ -247,12 +255,8 @@ export default {
role="button"
@click.prevent="setFileViewMode({ file, viewMode: 'editor' })"
>
<template v-if="viewer === $options.viewerTypes.edit">
{{ __('Edit') }}
</template>
<template v-else>
{{ __('Review') }}
</template>
<template v-if="viewer === $options.viewerTypes.edit">{{ __('Edit') }}</template>
<template v-else>{{ __('Review') }}</template>
</a>
</li>
<li v-if="file.previewMode" :class="previewTabCSS">
......@@ -260,9 +264,8 @@ export default {
href="javascript:void(0);"
role="button"
@click.prevent="setFileViewMode({ file, viewMode: 'preview' })"
>{{ file.previewMode.previewTitle }}</a
>
{{ file.previewMode.previewTitle }}
</a>
</li>
</ul>
<external-link :file="file" />
......
<script>
import { __, sprintf } from '~/locale';
import icon from '~/vue_shared/components/icon.vue';
import tooltip from '~/vue_shared/directives/tooltip';
import '~/lib/utils/datetime_utility';
......@@ -18,7 +19,9 @@ export default {
},
computed: {
lockTooltip() {
return `Locked by ${this.file.file_lock.user.name}`;
return sprintf(__(`Locked by %{fileLockUserName}`), {
fileLockUserName: this.file.file_lock.user.name,
});
},
},
};
......
<script>
import { __, sprintf } from '~/locale';
import { mapActions } from 'vuex';
import FileIcon from '~/vue_shared/components/file_icon.vue';
......@@ -27,9 +28,9 @@ export default {
computed: {
closeLabel() {
if (this.fileHasChanged) {
return `${this.tab.name} changed`;
return sprintf(__(`%{tabname} changed`), { tabname: this.tab.name });
}
return `Close ${this.tab.name}`;
return sprintf(__(`Close %{tabname}`, { tabname: this.tab.name }));
},
showChangedIcon() {
if (this.tab.pending) return true;
......
......@@ -231,6 +231,9 @@ msgid_plural "%{strong_start}%{tag_count}%{strong_end} Tags"
msgstr[0] ""
msgstr[1] ""
msgid "%{tabname} changed"
msgstr ""
msgid "%{text} %{files}"
msgid_plural "%{text} %{files} files"
msgstr[0] ""
......@@ -2212,6 +2215,9 @@ msgstr ""
msgid "Close"
msgstr ""
msgid "Close %{tabname}"
msgstr ""
msgid "Close milestone"
msgstr ""
......@@ -4226,6 +4232,9 @@ msgstr ""
msgid "Error saving label update."
msgstr ""
msgid "Error setting up editor. Please try again."
msgstr ""
msgid "Error updating %{issuableType}"
msgstr ""
......@@ -6088,6 +6097,9 @@ msgstr ""
msgid "Locked"
msgstr ""
msgid "Locked by %{fileLockUserName}"
msgstr ""
msgid "Locked to current projects"
msgstr ""
......@@ -7052,6 +7064,9 @@ msgstr ""
msgid "Open in Xcode"
msgstr ""
msgid "Open in file view"
msgstr ""
msgid "Open issues"
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