Commit 311ca606 authored by Ezekiel Kigbo's avatar Ezekiel Kigbo

Merge branch 'upgrade-eslint-plugin-10-0-0' into 'master'

Upgrade @gitlab/eslint-plugin to v10.0.0

See merge request gitlab-org/gitlab!73679
parents d7bba2c7 9d0020fe
......@@ -138,7 +138,7 @@ export default {
/>
</form>
<template #modal-footer>
<gl-button @click="onCancel">{{ s__('Cancel') }}</gl-button>
<gl-button @click="onCancel">{{ __('Cancel') }}</gl-button>
<gl-button
:disabled="!canSubmit"
category="secondary"
......
......@@ -3,7 +3,7 @@ import { GlDeprecatedSkeletonLoading as GlSkeletonLoading } from '@gitlab/ui';
import { GlSingleStat } from '@gitlab/ui/dist/charts';
import createFlash from '~/flash';
import { number } from '~/lib/utils/unit_format';
import { s__ } from '~/locale';
import { __, s__ } from '~/locale';
import usageTrendsCountQuery from '../graphql/queries/usage_trends_count.query.graphql';
const defaultPrecision = 0;
......@@ -52,7 +52,7 @@ export default {
mergeRequests: s__('UsageTrends|Merge requests'),
pipelines: s__('UsageTrends|Pipelines'),
},
loadCountsError: s__('Could not load usage counts. Please refresh the page to try again.'),
loadCountsError: __('Could not load usage counts. Please refresh the page to try again.'),
},
};
</script>
......
......@@ -2,7 +2,7 @@
import { GlSprintf, GlModal } from '@gitlab/ui';
import { mapState, mapActions } from 'vuex';
import createFlash from '~/flash';
import { s__ } from '~/locale';
import { __, s__ } from '~/locale';
import Badge from './badge.vue';
import BadgeForm from './badge_form.vue';
import BadgeList from './badge_list.vue';
......@@ -25,13 +25,13 @@ export default {
...mapState(['badgeInModal', 'isEditing']),
primaryProps() {
return {
text: s__('Delete badge'),
text: __('Delete badge'),
attributes: [{ category: 'primary' }, { variant: 'danger' }],
};
},
cancelProps() {
return {
text: s__('Cancel'),
text: __('Cancel'),
};
},
},
......
<script>
import { GlModal, GlSprintf, GlLink, GlButton } from '@gitlab/ui';
import Cookies from 'js-cookie';
import { s__ } from '~/locale';
import { __, s__ } from '~/locale';
import Tracking from '~/tracking';
const trackingMixin = Tracking.mixin();
......@@ -69,7 +69,7 @@ export default {
},
},
i18n: {
modalTitle: s__("That's it, well done!"),
modalTitle: __("That's it, well done!"),
pipelinesButton: s__('MR widget|See your pipeline in action'),
mergeRequestButton: s__('MR widget|Back to the Merge request'),
bodyMessage: s__(
......
......@@ -159,7 +159,7 @@ export default {
)
}}</span>
<template #modal-footer>
<gl-button variant="secondary" @click="handleCancel">{{ s__('Cancel') }}</gl-button>
<gl-button variant="secondary" @click="handleCancel">{{ __('Cancel') }}</gl-button>
<template v-if="confirmCleanup">
<gl-button
:disabled="!canSubmit"
......
......@@ -91,7 +91,7 @@ export const I18N_INSTALL_AGENT_MODAL = {
),
basicInstallTitle: s__('ClusterAgents|Recommended installation method'),
basicInstallBody: s__(
basicInstallBody: __(
`Open a CLI and connect to the cluster you want to install the Agent in. Use this installation method to minimize any manual steps. The token is already included in the command.`,
),
......@@ -100,7 +100,7 @@ export const I18N_INSTALL_AGENT_MODAL = {
'ClusterAgents|For alternative installation methods %{linkStart}go to the documentation%{linkEnd}.',
),
registrationErrorTitle: s__('Failed to register Agent'),
registrationErrorTitle: __('Failed to register Agent'),
unknownError: s__('ClusterAgents|An unknown error occurred. Please try again.'),
};
......
......@@ -62,7 +62,7 @@ export default {
</gl-sprintf>
{{ s__('DeployTokens|This action cannot be undone.') }}
<template #modal-footer>
<gl-button category="secondary" @click="cancelHandler">{{ s__('Cancel') }}</gl-button>
<gl-button category="secondary" @click="cancelHandler">{{ __('Cancel') }}</gl-button>
<gl-button
category="primary"
variant="danger"
......
......@@ -50,7 +50,7 @@ export default {
mixins: [glFeatureFlagsMixin(), IdState({ idProp: (vm) => vm.diffFile.file_hash })],
i18n: {
...DIFF_FILE_HEADER,
compareButtonLabel: s__('Compare submodule commit revisions'),
compareButtonLabel: __('Compare submodule commit revisions'),
},
props: {
discussionPath: {
......@@ -130,7 +130,7 @@ export default {
const truncatedOldSha = escape(truncateSha(this.diffFile.submodule_compare.old_sha));
const truncatedNewSha = escape(truncateSha(this.diffFile.submodule_compare.new_sha));
return sprintf(
s__('Compare %{oldCommitId}...%{newCommitId}'),
__('Compare %{oldCommitId}...%{newCommitId}'),
{
oldCommitId: `<span class="commit-sha">${truncatedOldSha}</span>`,
newCommitId: `<span class="commit-sha">${truncatedNewSha}</span>`,
......
<script>
import { GlTooltipDirective, GlModal } from '@gitlab/ui';
import { s__, sprintf } from '~/locale';
import { __, s__, sprintf } from '~/locale';
import eventHub from '../event_hub';
export default {
......@@ -27,7 +27,7 @@ export default {
},
cancelProps() {
return {
text: s__('Cancel'),
text: __('Cancel'),
};
},
confirmDeleteMessage() {
......
......@@ -6,7 +6,7 @@ import Visibility from 'visibilityjs';
import createFlash from '~/flash';
import Poll from '../../lib/utils/poll';
import { getParameterByName } from '../../lib/utils/url_utility';
import { s__ } from '../../locale';
import { s__, __ } from '../../locale';
import tabs from '../../vue_shared/components/navigation_tabs.vue';
import tablePagination from '../../vue_shared/components/pagination/table_pagination.vue';
import container from '../components/container.vue';
......@@ -207,13 +207,13 @@ export default {
tabs() {
return [
{
name: s__('Available'),
name: __('Available'),
scope: 'available',
count: this.state.availableCounter,
isActive: this.scope === 'available',
},
{
name: s__('Stopped'),
name: __('Stopped'),
scope: 'stopped',
count: this.state.stoppedCounter,
isActive: this.scope === 'stopped',
......
......@@ -2,7 +2,7 @@
import { GlModal, GlButton } from '@gitlab/ui';
import { mapActions, mapState, mapGetters } from 'vuex';
import createFlash from '~/flash';
import { __, sprintf, s__ } from '~/locale';
import { __, sprintf } from '~/locale';
import { modalTypes } from '../../constants';
import { trimPathComponents, getPathParent } from '../../utils';
......@@ -58,7 +58,7 @@ export default {
if (this.modalType === modalTypes.rename) {
if (this.entries[this.entryName] && !this.entries[this.entryName].deleted) {
createFlash({
message: sprintf(s__('The name "%{name}" is already taken in this directory.'), {
message: sprintf(__('The name "%{name}" is already taken in this directory.'), {
name: this.entryName,
}),
fadeTransition: false,
......
......@@ -517,7 +517,7 @@ export default {
<gl-empty-state
v-else-if="!hasGroups"
:title="s__('BulkImport|You have no groups to import')"
:description="s__('Check your source instance permissions.')"
:description="__('Check your source instance permissions.')"
/>
<template v-else>
<div
......
......@@ -166,7 +166,7 @@ export default {
</gl-sprintf>
</p>
<template #modal-footer>
<gl-button category="secondary" @click="cancelHandler">{{ s__('Cancel') }}</gl-button>
<gl-button category="secondary" @click="cancelHandler">{{ __('Cancel') }}</gl-button>
</template>
</gl-modal>
</div>
......
......@@ -4,7 +4,7 @@ import Visibility from 'visibilityjs';
import createFlash from '~/flash';
import Poll from '~/lib/utils/poll';
import { visitUrl } from '~/lib/utils/url_utility';
import { __, s__, sprintf } from '~/locale';
import { __, sprintf } from '~/locale';
import {
IssuableStatus,
IssuableStatusText,
......@@ -250,7 +250,7 @@ export default {
return false;
},
defaultErrorMessage() {
return sprintf(s__('Error updating %{issuableType}'), { issuableType: this.issuableType });
return sprintf(__('Error updating %{issuableType}'), { issuableType: this.issuableType });
},
isClosed() {
return this.issuableStatus === IssuableStatus.Closed;
......@@ -437,7 +437,7 @@ export default {
})
.catch(() => {
createFlash({
message: sprintf(s__('Error deleting %{issuableType}'), {
message: sprintf(__('Error deleting %{issuableType}'), {
issuableType: this.issuableType,
}),
});
......
......@@ -2,7 +2,7 @@
import { GlSafeHtmlDirective as SafeHtml } from '@gitlab/ui';
import $ from 'jquery';
import createFlash from '~/flash';
import { s__, sprintf } from '~/locale';
import { __, sprintf } from '~/locale';
import TaskList from '../../task_list';
import animateMixin from '../mixins/animate';
......@@ -104,7 +104,7 @@ export default {
taskListUpdateError() {
createFlash({
message: sprintf(
s__(
__(
'Someone edited this %{issueType} at the same time you did. The description has been updated and you will need to make your changes again.',
),
{
......
import { s__ } from '~/locale';
import { __, s__ } from '~/locale';
/**
* Generates empty state messages for Service Desk issues list.
......@@ -25,7 +25,7 @@ export function generateMessages(emptyStateMeta) {
const commonDescription = `
<span>${serviceDeskSupportedMessage}</span>
<a href="${serviceDeskHelpPage}">${s__('Learn more.')}</a>`;
<a href="${serviceDeskHelpPage}">${__('Learn more.')}</a>`;
return {
serviceDeskEnabledAndCanEditProjectSettings: {
......@@ -60,7 +60,7 @@ export function generateMessages(emptyStateMeta) {
'ServiceDesk|To enable Service Desk on this instance, an instance administrator must first set up incoming email.',
),
primaryLink: incomingEmailHelpPage,
primaryText: s__('Learn more.'),
primaryText: __('Learn more.'),
},
serviceDeskIsNotEnabled: {
title: s__('ServiceDesk|Service Desk is not enabled'),
......
......@@ -14,33 +14,33 @@ import { s__, n__, __, sprintf } from '../../../locale';
export const getMonthNames = (abbreviated) => {
if (abbreviated) {
return [
s__('Jan'),
s__('Feb'),
s__('Mar'),
s__('Apr'),
s__('May'),
s__('Jun'),
s__('Jul'),
s__('Aug'),
s__('Sep'),
s__('Oct'),
s__('Nov'),
s__('Dec'),
__('Jan'),
__('Feb'),
__('Mar'),
__('Apr'),
__('May'),
__('Jun'),
__('Jul'),
__('Aug'),
__('Sep'),
__('Oct'),
__('Nov'),
__('Dec'),
];
}
return [
s__('January'),
s__('February'),
s__('March'),
s__('April'),
s__('May'),
s__('June'),
s__('July'),
s__('August'),
s__('September'),
s__('October'),
s__('November'),
s__('December'),
__('January'),
__('February'),
__('March'),
__('April'),
__('May'),
__('June'),
__('July'),
__('August'),
__('September'),
__('October'),
__('November'),
__('December'),
];
};
......
......@@ -130,7 +130,7 @@ export default {
}}
<a :href="clusterApplicationsDocumentationPath">
<strong>
{{ s__('View Documentation') }}
{{ __('View Documentation') }}
</strong>
</a>
</gl-alert>
......
......@@ -63,7 +63,7 @@ export default {
return !(this.form.fileName && !this.form.fileName.endsWith('.yml'));
},
fileNameFeedback() {
return !this.fileNameState ? s__('The file name should have a .yml extension') : '';
return !this.fileNameState ? __('The file name should have a .yml extension') : '';
},
},
mounted() {
......
......@@ -78,8 +78,8 @@ export default {
v-if="resolveAllDiscussionsIssuePath && !allResolved"
v-gl-tooltip
:href="resolveAllDiscussionsIssuePath"
:title="s__('Create issue to resolve all threads')"
:aria-label="s__('Create issue to resolve all threads')"
:title="__('Create issue to resolve all threads')"
:aria-label="__('Create issue to resolve all threads')"
class="new-issue-for-discussion discussion-create-issue-btn"
icon="issue-new"
/>
......
......@@ -70,7 +70,7 @@ export default {
},
primaryProps() {
return {
text: s__('Delete project'),
text: __('Delete project'),
attributes: [{ variant: 'danger' }, { category: 'primary' }, { disabled: !this.canSubmit }],
};
},
......
......@@ -47,7 +47,7 @@ export default {
<template>
<new-namespace-page
:jump-to-last-persisted-panel="hasErrors"
:initial-breadcrumb="s__('New group')"
:initial-breadcrumb="__('New group')"
:panels="$options.PANELS"
:title="s__('GroupsNew|Create new group')"
persistence-key="new_group_last_active_tab"
......
......@@ -3,7 +3,7 @@ import { GlModal } from '@gitlab/ui';
import createFlash from '~/flash';
import axios from '~/lib/utils/axios_utils';
import { visitUrl } from '~/lib/utils/url_utility';
import { s__, sprintf } from '~/locale';
import { __, s__, sprintf } from '~/locale';
export default {
components: {
......@@ -83,7 +83,7 @@ export default {
attributes: [{ variant: 'warning' }],
},
cancelAction: {
text: s__('Cancel'),
text: __('Cancel'),
attributes: [],
},
};
......
......@@ -72,18 +72,18 @@ export default {
return [
{
value: KEY_EVERY_DAY,
text: sprintf(s__(`Every day (at %{time})`), { time: this.formattedTime }),
text: sprintf(__(`Every day (at %{time})`), { time: this.formattedTime }),
},
{
value: KEY_EVERY_WEEK,
text: sprintf(s__('Every week (%{weekday} at %{time})'), {
text: sprintf(__('Every week (%{weekday} at %{time})'), {
weekday: this.weekday,
time: this.formattedTime,
}),
},
{
value: KEY_EVERY_MONTH,
text: sprintf(s__('Every month (Day %{day} at %{time})'), {
text: sprintf(__('Every month (Day %{day} at %{time})'), {
day: this.randomDay,
time: this.formattedTime,
}),
......
......@@ -2,7 +2,7 @@
import { GlIcon, GlSprintf, GlLink, GlFormCheckbox, GlToggle } from '@gitlab/ui';
import settingsMixin from 'ee_else_ce/pages/projects/shared/permissions/mixins/settings_pannel_mixin';
import { s__ } from '~/locale';
import { __, s__ } from '~/locale';
import {
visibilityOptions,
visibilityLevelDescriptions,
......@@ -31,7 +31,7 @@ export default {
operationsLabel: s__('ProjectSettings|Operations'),
packagesLabel: s__('ProjectSettings|Packages'),
pagesLabel: s__('ProjectSettings|Pages'),
ciCdLabel: s__('CI/CD'),
ciCdLabel: __('CI/CD'),
repositoryLabel: s__('ProjectSettings|Repository'),
requirementsLabel: s__('ProjectSettings|Requirements'),
securityAndComplianceLabel: s__('ProjectSettings|Security & Compliance'),
......
......@@ -12,7 +12,7 @@ import {
import axios from '~/lib/utils/axios_utils';
import csrf from '~/lib/utils/csrf';
import { setUrlFragment } from '~/lib/utils/url_utility';
import { s__, sprintf } from '~/locale';
import { __, s__, sprintf } from '~/locale';
import Tracking from '~/tracking';
import MarkdownField from '~/vue_shared/components/markdown/field.vue';
import {
......@@ -83,7 +83,7 @@ export default {
),
},
},
feedbackTip: s__(
feedbackTip: __(
'Tell us your experiences with the new Markdown editor %{linkStart}in this feedback issue%{linkEnd}.',
),
},
......
<script>
import { GlButton, GlModal, GlModalDirective, GlSegmentedControl } from '@gitlab/ui';
import { s__ } from '~/locale';
import { __, s__ } from '~/locale';
import { sortOrders, sortOrderOptions } from '../constants';
import RequestWarning from './request_warning.vue';
......@@ -55,7 +55,7 @@ export default {
const summary = {};
if (!this.metricDetails.summaryOptions?.hideTotal) {
summary[s__('Total')] = this.metricDetails.calls;
summary[__('Total')] = this.metricDetails.calls;
}
if (!this.metricDetails.summaryOptions?.hideDuration) {
......
......@@ -12,7 +12,7 @@ import { produce } from 'immer';
import { fetchPolicies } from '~/lib/graphql';
import { historyPushState } from '~/lib/utils/common_utils';
import { setUrlParams } from '~/lib/utils/url_utility';
import { s__ } from '~/locale';
import { __ } from '~/locale';
import {
BRANCH_PAGINATION_LIMIT,
BRANCH_SEARCH_DEBOUNCE,
......@@ -25,9 +25,9 @@ import getLastCommitBranchQuery from '~/pipeline_editor/graphql/queries/client/l
export default {
i18n: {
dropdownHeader: s__('Switch branch'),
title: s__('Branches'),
fetchError: s__('Unable to fetch branch list for this project.'),
dropdownHeader: __('Switch branch'),
title: __('Branches'),
fetchError: __('Unable to fetch branch list for this project.'),
},
inputDebounce: BRANCH_SEARCH_DEBOUNCE,
components: {
......
......@@ -37,7 +37,7 @@ export default {
},
primaryProps() {
return {
text: s__('Delete account'),
text: __('Delete account'),
attributes: [
{ variant: 'danger', 'data-qa-selector': 'confirm_delete_account_button' },
{ category: 'primary' },
......@@ -47,7 +47,7 @@ export default {
},
cancelProps() {
return {
text: s__('Cancel'),
text: __('Cancel'),
};
},
canSubmit() {
......
......@@ -3,7 +3,7 @@ import { GlSafeHtmlDirective as SafeHtml, GlButton, GlModal, GlModalDirective }
import { escape } from 'lodash';
import createFlash from '~/flash';
import axios from '~/lib/utils/axios_utils';
import { s__, sprintf } from '~/locale';
import { __, s__, sprintf } from '~/locale';
export default {
components: {
......@@ -58,7 +58,7 @@ Please update your Git repository remotes as soon as possible.`),
},
primaryProps() {
return {
text: s__('Update username'),
text: __('Update username'),
attributes: [
{ variant: 'warning' },
{ category: 'primary' },
......@@ -68,7 +68,7 @@ Please update your Git repository remotes as soon as possible.`),
},
cancelProps() {
return {
text: s__('Cancel'),
text: __('Cancel'),
};
},
},
......
......@@ -95,7 +95,7 @@ export default {
<template>
<new-namespace-page
:initial-breadcrumb="s__('New project')"
:initial-breadcrumb="__('New project')"
:panels="availablePanels"
:jump-to-last-persisted-panel="hasErrors"
:title="s__('ProjectsNew|Create new project')"
......
......@@ -51,7 +51,7 @@ export const ERROR_MESSAGE = s__(
'UsageQuota|Something went wrong while fetching project storage statistics',
);
export const LEARN_MORE_LABEL = s__('Learn more.');
export const LEARN_MORE_LABEL = __('Learn more.');
export const USAGE_QUOTAS_LABEL = s__('UsageQuota|Usage Quotas');
export const HELP_LINK_ARIA_LABEL = s__('UsageQuota|%{linkTitle} help link');
export const TOTAL_USAGE_DEFAULT_TEXT = __('N/A');
......
......@@ -58,7 +58,7 @@ export default {
};
this.isLoading = false;
createFlash({
message: s__('Something went wrong on our end'),
message: __('Something went wrong on our end'),
});
},
initPolling() {
......
<script>
import { GlLink, GlLoadingIcon, GlIcon } from '@gitlab/ui';
import { mapState, mapActions } from 'vuex';
import { sprintf, n__, s__ } from '~/locale';
import { sprintf, __, n__ } from '~/locale';
import RelatedIssuableItem from '~/vue_shared/components/issue/related_issuable_item.vue';
import { parseIssuableData } from '../../issue_show/utils/parse_data';
......@@ -40,7 +40,7 @@ export default {
this.totalCount,
);
return sprintf(s__('%{mrText}, this issue will be closed automatically.'), { mrText });
return sprintf(__('%{mrText}, this issue will be closed automatically.'), { mrText });
},
},
mounted() {
......
import createFlash from '~/flash';
import axios from '~/lib/utils/axios_utils';
import { normalizeHeaders } from '~/lib/utils/common_utils';
import { s__ } from '~/locale';
import { __ } from '~/locale';
import * as types from './mutation_types';
const REQUEST_PAGE_COUNT = 100;
......@@ -30,7 +30,7 @@ export const fetchMergeRequests = ({ state, dispatch }) => {
.catch(() => {
dispatch('receiveDataError');
createFlash({
message: s__('Something went wrong while fetching related merge requests.'),
message: __('Something went wrong while fetching related merge requests.'),
});
});
};
<script>
import { GlFormRadioGroup, GlFormRadio } from '@gitlab/ui';
import { mapState, mapActions } from 'vuex';
import { sprintf, s__ } from '~/locale';
import { sprintf, __ } from '~/locale';
export default {
name: 'RadioFilter',
......@@ -49,7 +49,7 @@ export default {
...mapActions(['setQuery']),
radioLabel(filter) {
return filter.value === this.ANY.value
? sprintf(s__('Any %{header}'), { header: this.filterData.header.toLowerCase() })
? sprintf(__('Any %{header}'), { header: this.filterData.header.toLowerCase() })
: filter.label;
},
},
......
......@@ -30,7 +30,7 @@ export default {
updatedFileDescription() {
const { sourcePath } = this.appData;
return sprintf(s__('Update %{sourcePath} file'), { sourcePath });
return sprintf(__('Update %{sourcePath} file'), { sourcePath });
},
},
created() {
......
......@@ -23,7 +23,7 @@ export default {
translations: {
createdTimeagoLabel: s__('UserList|created %{timeago}'),
deleteListTitle: s__('UserList|Delete %{name}?'),
deleteListMessage: s__('User list %{name} will be removed. Are you sure?'),
deleteListMessage: __('User list %{name} will be removed. Are you sure?'),
editUserListLabel: s__('FeatureFlags|Edit User List'),
},
modal: {
......
......@@ -151,7 +151,7 @@ export default {
right
data-qa-selector="download_dropdown"
>
<gl-dropdown-section-header>{{ s__('Download as') }}</gl-dropdown-section-header>
<gl-dropdown-section-header>{{ __('Download as') }}</gl-dropdown-section-header>
<gl-dropdown-item
:href="mr.emailPatchesPath"
class="js-download-email-patches"
......
import { s__ } from '~/locale';
import { __ } from '~/locale';
/**
* Validation messages will take priority based on the property order.
......@@ -12,11 +12,11 @@ import { s__ } from '~/locale';
const defaultFeedbackMap = {
valueMissing: {
isInvalid: (el) => el.validity?.valueMissing,
message: s__('Please fill out this field.'),
message: __('Please fill out this field.'),
},
urlTypeMismatch: {
isInvalid: (el) => el.type === 'url' && el.validity?.typeMismatch,
message: s__('Please enter a valid URL format, ex: http://www.example.com/home'),
message: __('Please enter a valid URL format, ex: http://www.example.com/home'),
},
};
......
......@@ -15,7 +15,7 @@ import dateFormat from 'dateformat';
import { mapState } from 'vuex';
import { dateFormats } from '~/analytics/shared/constants';
import { approximateDuration, differenceInSeconds } from '~/lib/utils/datetime_utility';
import { s__, n__ } from '~/locale';
import { __, s__, n__ } from '~/locale';
import { filterToQueryObject } from '~/vue_shared/components/filtered_search_bar/filtered_search_utils';
import {
THROUGHPUT_TABLE_STRINGS,
......@@ -83,7 +83,7 @@ export default {
},
{
key: 'commits',
label: s__('Commits'),
label: __('Commits'),
tdClass: 'merge-request-analytics-td',
thAttr: TH_TEST_ID,
},
......
<script>
import { s__ } from '~/locale';
import { __, s__ } from '~/locale';
const HEADERS = {
name: s__('ApprovalRule|Name'),
members: s__('ApprovalRule|Approvers'),
approvalsRequired: s__('ApprovalRule|Approvals required'),
branches: s__('Target branch'),
branches: __('Target branch'),
};
export default {
......
......@@ -4,7 +4,7 @@ import { mapGetters } from 'vuex';
// extends a valid Vue single file component.
/* eslint-disable @gitlab/no-runtime-template-compiler */
import BoardListHeaderFoss from '~/boards/components/board_list_header.vue';
import { n__, __, sprintf, s__ } from '~/locale';
import { n__, __, sprintf } from '~/locale';
export default {
extends: BoardListHeaderFoss,
......@@ -34,7 +34,7 @@ export default {
const { totalWeight } = this.list;
if (this.weightFeatureAvailable) {
return sprintf(s__('%{totalWeight} total weight'), { totalWeight });
return sprintf(__('%{totalWeight} total weight'), { totalWeight });
}
return null;
......
......@@ -11,7 +11,7 @@ import {
} from '@gitlab/ui';
import { isEmpty } from 'lodash';
import { mapState, mapActions } from 'vuex';
import { s__ } from '~/locale';
import { __, s__ } from '~/locale';
import ProjectSelector from '~/vue_shared/components/project_selector/project_selector.vue';
import Environment from './environment.vue';
import ProjectHeader from './project_header.vue';
......@@ -30,7 +30,7 @@ export default {
"EnvironmentsDashboard|The environments dashboard provides a summary of each project's environments' status, including pipeline and alert statuses.",
),
viewDocumentationButton: s__('View documentation'),
viewDocumentationButton: __('View documentation'),
components: {
Environment,
......
......@@ -308,7 +308,7 @@ export const requestEpicCreateSuccess = (_, webUrl) => visitUrl(webUrl);
export const requestEpicCreateFailure = ({ commit }) => {
commit(types.REQUEST_EPIC_CREATE_FAILURE);
createFlash({
message: s__('Error creating epic'),
message: __('Error creating epic'),
});
};
export const createEpic = ({ state, dispatch }) => {
......
......@@ -16,7 +16,7 @@ export default {
SourceEditor,
},
i18n: {
helpText: s__(
helpText: __(
'This code snippet contains everything reflected in the configuration form. Copy and paste it into %{linkStart}.gitlab-ci.yml%{linkEnd} file and save your changes. Future %{scanType} scans will use these settings.',
),
modalTitle: s__('SecurityConfiguration|%{scanType} configuration code snippet'),
......
<script>
import { GlButton, GlModal, GlModalDirective } from '@gitlab/ui';
import { s__ } from '~/locale';
import { __, s__ } from '~/locale';
export default {
components: {
......@@ -21,11 +21,11 @@ export default {
},
modal: {
actionPrimary: {
text: s__('Delete corpus'),
text: __('Delete corpus'),
attributes: { variant: 'danger', 'data-testid': 'modal-confirm' },
},
actionCancel: {
text: s__('Cancel'),
text: __('Cancel'),
},
},
computed: {
......
<script>
import { GlAlert, GlLink, GlLoadingIcon, GlSprintf } from '@gitlab/ui';
import { s__ } from '~/locale';
import { __, s__ } from '~/locale';
import DismissibleFeedbackAlert from '~/vue_shared/components/dismissible_feedback_alert.vue';
import glFeatureFlagsMixin from '~/vue_shared/mixins/gl_feature_flags_mixin';
import ConfigurationPageLayout from '../../components/configuration_page_layout.vue';
......@@ -61,7 +61,7 @@ export default {
},
},
i18n: {
feedbackAlertMessage: s__(`
feedbackAlertMessage: __(`
As we continue to build more features for SAST, we'd love your feedback
on the SAST configuration feature in %{linkStart}this issue%{linkEnd}.`),
helpText: s__(
......
......@@ -139,8 +139,8 @@ export default {
cover all languages across your project, and only run if the language is
detected in the Merge Request.`,
),
analyzersTipHeading: s__('We recommend leaving all SAST analyzers enabled'),
analyzersTipBody: s__(
analyzersTipHeading: __('We recommend leaving all SAST analyzers enabled'),
analyzersTipBody: __(
'Keeping all SAST analyzers enabled future-proofs the project in case new languages are added later on. Determining which analyzers apply is a process that consumes minimal resources and adds minimal time to the pipeline. Leaving all SAST analyzers enabled ensures maximum coverage.',
),
},
......
......@@ -113,9 +113,9 @@ export default {
<slot v-if="showEmptyState" name="empty-state">
<gl-empty-state
:title="s__(`We've found no vulnerabilities`)"
:title="__(`We've found no vulnerabilities`)"
:description="
s__(
__(
`While it's rare to have no vulnerabilities, it can happen. In any event, we ask that you please double check your settings to make sure you've set up your dashboard correctly.`,
)
"
......
......@@ -12,7 +12,7 @@ export default {
description: s__(
'SecurityReports|Manage and track vulnerabilities identified in your selected projects. Vulnerabilities for selected projects with security testing configured are shown here.',
),
primaryButtonText: s__('Add projects'),
primaryButtonText: __('Add projects'),
secondaryButtonText: __('Learn more'),
},
};
......
......@@ -8,7 +8,7 @@ import {
GlDropdown,
GlDropdownDivider,
} from '@gitlab/ui';
import { s__ } from '~/locale';
import { __, s__ } from '~/locale';
import Tracking from '~/tracking';
import { healthStatusTextMap, I18N_DROPDOWN } from '../../constants';
......@@ -82,7 +82,7 @@ export default {
},
editTooltip() {
const tooltipText = !this.isOpen
? s__('Health status cannot be edited because this issue is closed')
? __('Health status cannot be edited because this issue is closed')
: '';
return {
......
......@@ -60,7 +60,7 @@ export const I18N_DROPDOWN = {
dropdownHeaderText: s__('Sidebar|Assign health status'),
noStatusText: s__('Sidebar|No status'),
noneText: s__('Sidebar|None'),
selectPlaceholderText: s__('Select health status'),
selectPlaceholderText: __('Select health status'),
};
export const CVE_ID_REQUEST_SIDEBAR_I18N = {
......
......@@ -48,7 +48,7 @@ export default {
<gl-modal
:modal-id="modalId"
:ok-disabled="isApproving"
:title="s__('Enter your password to approve')"
:title="__('Enter your password to approve')"
ok-variant="success"
modal-class="js-mr-approvals-modal"
@ok="approve"
......@@ -74,7 +74,7 @@ export default {
class="form-control"
:class="{ 'is-invalid': hasError }"
autocomplete="new-password"
:placeholder="s__('Password')"
:placeholder="__('Password')"
/>
</div>
</div>
......@@ -83,11 +83,11 @@ export default {
</div>
</form>
<template #modal-cancel>{{ s__('Cancel') }}</template>
<template #modal-cancel>{{ __('Cancel') }}</template>
<template #modal-ok>
<gl-loading-icon v-if="isApproving" size="sm" inline />
{{ s__('Approve') }}
{{ __('Approve') }}
</template>
</gl-modal>
</template>
import { n__, s__, sprintf } from '~/locale';
import { __, n__, s__, sprintf } from '~/locale';
import { LICENSE_APPROVAL_STATUS, REPORT_GROUPS } from '../constants';
import { addLicensesMatchingReportGroupStatus, reportGroupHasAtLeastOneLicense } from './utils';
......@@ -35,13 +35,13 @@ export const licenseReportLength = (_, getters) => {
export const licenseSummaryText = (state, getters) => {
if (getters.isLoading) {
return sprintf(s__('ciReport|Loading %{reportName} report'), {
reportName: s__('License Compliance'),
reportName: __('License Compliance'),
});
}
if (state.loadLicenseReportError) {
return sprintf(s__('ciReport|Failed to load %{reportName} report'), {
reportName: s__('License Compliance'),
reportName: __('License Compliance'),
});
}
......
......@@ -232,7 +232,7 @@ export default {
<vulnerability-detail v-if="crashState" :label="s__('Vulnerability|Crash state')">
<span ref="crashState"> {{ crashState }} </span>
</vulnerability-detail>
<vulnerability-detail v-if="stacktraceSnippet" :label="s__('Stacktrace snippet')">
<vulnerability-detail v-if="stacktraceSnippet" :label="__('Stacktrace snippet')">
<code-block ref="stacktraceSnippet" :code="stacktraceSnippet" max-height="225px" />
</vulnerability-detail>
<vulnerability-detail v-if="identifiers" :label="s__('Vulnerability|Identifiers')">
......
......@@ -22,7 +22,7 @@ export const i18n = {
),
helpPageLinkLabel: s__('VulnerabilityManagement|Read more about related issues'),
createNewIssueLinkText: s__('VulnerabilityManagement|Create Jira issue'),
loadingStateLabel: s__('VulnerabilityManagement, Fetching linked Jira issues'),
loadingStateLabel: s__('VulnerabilityManagement|Fetching linked Jira issues'),
};
export default {
......
import { s__ } from '~/locale';
import { __, s__ } from '~/locale';
import {
FEEDBACK_TYPE_ISSUE,
FEEDBACK_TYPE_MERGE_REQUEST,
......@@ -17,7 +17,7 @@ export const VULNERABILITY_STATE_OBJECTS = {
dismissed: {
action: 'dismiss',
state: 'dismissed',
displayName: s__('Dismiss'),
displayName: __('Dismiss'),
description: falsePositiveMessage,
payload: {
comment: falsePositiveMessage,
......@@ -26,13 +26,13 @@ export const VULNERABILITY_STATE_OBJECTS = {
confirmed: {
action: 'confirm',
state: 'confirmed',
displayName: s__('Confirm'),
displayName: __('Confirm'),
description: s__('VulnerabilityManagement|A true-positive and will fix'),
},
resolved: {
action: 'resolve',
state: 'resolved',
displayName: s__('Resolve'),
displayName: __('Resolve'),
description: s__('VulnerabilityManagement|Verified as fixed or mitigated'),
},
};
......
......@@ -38128,9 +38128,6 @@ msgstr ""
msgid "VulnerabilityChart|Severity"
msgstr ""
msgid "VulnerabilityManagement, Fetching linked Jira issues"
msgstr ""
msgid "VulnerabilityManagement|%{statusStart}Confirmed%{statusEnd} %{timeago} by %{user}"
msgstr ""
......@@ -38158,6 +38155,9 @@ msgstr ""
msgid "VulnerabilityManagement|Detected"
msgstr ""
msgid "VulnerabilityManagement|Fetching linked Jira issues"
msgstr ""
msgid "VulnerabilityManagement|Needs triage"
msgstr ""
......
......@@ -185,15 +185,15 @@ describe('dateInWords', () => {
const date = new Date('07/01/2016');
it('should return date in words', () => {
expect(datetimeUtility.dateInWords(date)).toEqual(s__('July 1, 2016'));
expect(datetimeUtility.dateInWords(date)).toEqual(__('July 1, 2016'));
});
it('should return abbreviated month name', () => {
expect(datetimeUtility.dateInWords(date, true)).toEqual(s__('Jul 1, 2016'));
expect(datetimeUtility.dateInWords(date, true)).toEqual(__('Jul 1, 2016'));
});
it('should return date in words without year', () => {
expect(datetimeUtility.dateInWords(date, true, true)).toEqual(s__('Jul 1'));
expect(datetimeUtility.dateInWords(date, true, true)).toEqual(__('Jul 1'));
});
});
......@@ -201,11 +201,11 @@ describe('monthInWords', () => {
const date = new Date('2017-01-20');
it('returns month name from provided date', () => {
expect(datetimeUtility.monthInWords(date)).toBe(s__('January'));
expect(datetimeUtility.monthInWords(date)).toBe(__('January'));
});
it('returns abbreviated month name from provided date', () => {
expect(datetimeUtility.monthInWords(date, true)).toBe(s__('Jan'));
expect(datetimeUtility.monthInWords(date, true)).toBe(__('Jan'));
});
});
......
......@@ -873,10 +873,10 @@
resolved "https://registry.yarnpkg.com/@gitlab/at.js/-/at.js-1.5.7.tgz#1ee6f838cc4410a1d797770934df91d90df8179e"
integrity sha512-c6ySRK/Ma7lxwpIVbSAF3P+xiTLrNTGTLRx4/pHK111AdFxwgUwrYF6aVZFXvmG65jHOJHoa0eQQ21RW6rm0Rg==
"@gitlab/eslint-plugin@9.4.0":
version "9.4.0"
resolved "https://registry.yarnpkg.com/@gitlab/eslint-plugin/-/eslint-plugin-9.4.0.tgz#cad8f63b7985c22865859cc7d2688eb446ad0bbb"
integrity sha512-llPypEQrm9/6Xas5GCoSPAK7W/DgO7CKhzDvAk/Ea9BP0rI2+t8Wg4PFhE1XDctYnnUIS/GrdqVKQkpODk24hQ==
"@gitlab/eslint-plugin@10.0.0":
version "10.0.0"
resolved "https://registry.yarnpkg.com/@gitlab/eslint-plugin/-/eslint-plugin-10.0.0.tgz#83430fb4d0a2467bb54975d0b5b9dc8016005722"
integrity sha512-frCYzjQQaZ5kW1on3XwuVGhvYa6XjD6Q1POTbxDpzl6tNxSeTwOJohC6Joyw76e0Kw4fPQd/fHAfKQAB0AVQ7A==
dependencies:
babel-eslint "^10.0.3"
eslint-config-airbnb-base "^14.2.1"
......
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