...@@ -10,7 +10,7 @@ const durationToMillis = duration => { ...@@ -10,7 +10,7 @@ const durationToMillis = duration => {
if (Object.entries(duration).length === 1 && Number.isFinite(duration.seconds)) { if (Object.entries(duration).length === 1 && Number.isFinite(duration.seconds)) {
return secondsToMilliseconds(duration.seconds); return secondsToMilliseconds(duration.seconds);
} }
// eslint-disable-next-line @gitlab/i18n/no-non-i18n-strings // eslint-disable-next-line @gitlab/require-i18n-strings
throw new Error('Invalid duration: only `seconds` is supported'); throw new Error('Invalid duration: only `seconds` is supported');
}; };
...@@ -131,7 +131,7 @@ const convertOpenToFixed = ({ anchor, direction }) => { ...@@ -131,7 +131,7 @@ const convertOpenToFixed = ({ anchor, direction }) => {
* Handles invalid date ranges * Handles invalid date ranges
*/ */
const handleInvalidRange = () => { const handleInvalidRange = () => {
// eslint-disable-next-line @gitlab/i18n/no-non-i18n-strings // eslint-disable-next-line @gitlab/require-i18n-strings
throw new Error('The input range does not have the right format.'); throw new Error('The input range does not have the right format.');
}; };
... ...
......
...@@ -13,7 +13,7 @@ function notificationGranted(message, opts, onclick) { ...@@ -13,7 +13,7 @@ function notificationGranted(message, opts, onclick) {
} }
function notifyPermissions() { function notifyPermissions() {
/* eslint-disable-next-line @gitlab/i18n/no-non-i18n-strings */ /* eslint-disable-next-line @gitlab/require-i18n-strings */
if ('Notification' in window) { if ('Notification' in window) {
return Notification.requestPermission(); return Notification.requestPermission();
} }
...@@ -25,7 +25,7 @@ function notifyMe(message, body, icon, onclick) { ...@@ -25,7 +25,7 @@ function notifyMe(message, body, icon, onclick) {
icon, icon,
}; };
// Let's check if the browser supports notifications // Let's check if the browser supports notifications
/* eslint-disable-next-line @gitlab/i18n/no-non-i18n-strings */ /* eslint-disable-next-line @gitlab/require-i18n-strings */
if (!('Notification' in window)) { if (!('Notification' in window)) {
// do nothing // do nothing
} else if (Notification.permission === 'granted') { } else if (Notification.permission === 'granted') {
... ...
......
...@@ -111,7 +111,7 @@ export const scaledSIFormatter = (unit = '', prefixOffset = 0) => { ...@@ -111,7 +111,7 @@ export const scaledSIFormatter = (unit = '', prefixOffset = 0) => {
}); });
if (!units.length) { if (!units.length) {
// eslint-disable-next-line @gitlab/i18n/no-non-i18n-strings // eslint-disable-next-line @gitlab/require-i18n-strings
throw new RangeError('The unit cannot be converted, please try a different scale'); throw new RangeError('The unit cannot be converted, please try a different scale');
} }
...@@ -122,7 +122,7 @@ export const scaledSIFormatter = (unit = '', prefixOffset = 0) => { ...@@ -122,7 +122,7 @@ export const scaledSIFormatter = (unit = '', prefixOffset = 0) => {
* Returns a function that formats a number scaled using SI units notation. * Returns a function that formats a number scaled using SI units notation.
*/ */
export const scaledBinaryFormatter = (unit = '', prefixOffset = 0) => { export const scaledBinaryFormatter = (unit = '', prefixOffset = 0) => {
// eslint-disable-next-line @gitlab/i18n/no-non-i18n-strings // eslint-disable-next-line @gitlab/require-i18n-strings
const multiplicative = ['Ki', 'Mi', 'Gi', 'Ti', 'Pi', 'Ei', 'Zi', 'Yi']; const multiplicative = ['Ki', 'Mi', 'Gi', 'Ti', 'Pi', 'Ei', 'Zi', 'Yi'];
const symbols = ['', ...multiplicative]; const symbols = ['', ...multiplicative];
...@@ -131,7 +131,7 @@ export const scaledBinaryFormatter = (unit = '', prefixOffset = 0) => { ...@@ -131,7 +131,7 @@ export const scaledBinaryFormatter = (unit = '', prefixOffset = 0) => {
}); });
if (!units.length) { if (!units.length) {
// eslint-disable-next-line @gitlab/i18n/no-non-i18n-strings // eslint-disable-next-line @gitlab/require-i18n-strings
throw new RangeError('The unit cannot be converted, please try a different scale'); throw new RangeError('The unit cannot be converted, please try a different scale');
} }
... ...
......
...@@ -49,7 +49,7 @@ window.$ = jQuery; ...@@ -49,7 +49,7 @@ window.$ = jQuery;
// Add nonce to jQuery script handler // Add nonce to jQuery script handler
jQuery.ajaxSetup({ jQuery.ajaxSetup({
converters: { converters: {
// eslint-disable-next-line @gitlab/i18n/no-non-i18n-strings, func-names // eslint-disable-next-line @gitlab/require-i18n-strings, func-names
'text script': function(text) { 'text script': function(text) {
jQuery.globalEval(text, { nonce: getCspNonceValue() }); jQuery.globalEval(text, { nonce: getCspNonceValue() });
return text; return text;
... ...
......
...@@ -68,7 +68,7 @@ export default { ...@@ -68,7 +68,7 @@ export default {
} }
}) })
.catch(e => { .catch(e => {
// eslint-disable-next-line no-console, @gitlab/i18n/no-non-i18n-strings // eslint-disable-next-line no-console, @gitlab/require-i18n-strings
console.error('SVG could not be rendered correctly: ', e); console.error('SVG could not be rendered correctly: ', e);
}); });
}, },
... ...
......
...@@ -327,7 +327,7 @@ export default { ...@@ -327,7 +327,7 @@ export default {
} }
}) })
.catch(e => { .catch(e => {
// eslint-disable-next-line no-console, @gitlab/i18n/no-non-i18n-strings // eslint-disable-next-line no-console, @gitlab/require-i18n-strings
console.error('SVG could not be rendered correctly: ', e); console.error('SVG could not be rendered correctly: ', e);
}); });
}, },
... ...
......
...@@ -95,7 +95,7 @@ export default { ...@@ -95,7 +95,7 @@ export default {
csvText() { csvText() {
const chartData = this.graphData.metrics[0].result[0].values; const chartData = this.graphData.metrics[0].result[0].values;
const yLabel = this.graphData.y_label; const yLabel = this.graphData.y_label;
const header = `timestamp,${yLabel}\r\n`; // eslint-disable-line @gitlab/i18n/no-non-i18n-strings const header = `timestamp,${yLabel}\r\n`; // eslint-disable-line @gitlab/require-i18n-strings
return chartData.reduce((csv, data) => { return chartData.reduce((csv, data) => {
const row = data.join(','); const row = data.join(',');
return `${csv}${row}\r\n`; return `${csv}${row}\r\n`;
... ...
......
...@@ -28,7 +28,7 @@ export const graphDataValidatorForValues = (isValues, graphData) => { ...@@ -28,7 +28,7 @@ export const graphDataValidatorForValues = (isValues, graphData) => {
); );
}; };
/* eslint-disable @gitlab/i18n/no-non-i18n-strings */ /* eslint-disable @gitlab/require-i18n-strings */
/** /**
* Checks that element that triggered event is located on cluster health check dashboard * Checks that element that triggered event is located on cluster health check dashboard
* @param {HTMLElement} element to check against * @param {HTMLElement} element to check against
... ...
......
<script> <script>
/* eslint-disable @gitlab/vue-i18n/no-bare-strings */ /* eslint-disable @gitlab/vue-require-i18n-strings */
import { GlPopover, GlSkeletonLoading } from '@gitlab/ui'; import { GlPopover, GlSkeletonLoading } from '@gitlab/ui';
import CiIcon from '../../vue_shared/components/ci_icon.vue'; import CiIcon from '../../vue_shared/components/ci_icon.vue';
import timeagoMixin from '../../vue_shared/mixins/timeago'; import timeagoMixin from '../../vue_shared/mixins/timeago';
...@@ -8,7 +8,7 @@ import { mrStates, humanMRStates } from '../constants'; ...@@ -8,7 +8,7 @@ import { mrStates, humanMRStates } from '../constants';
export default { export default {
// name: 'MRPopover' is a false positive: https://gitlab.com/gitlab-org/frontend/eslint-plugin-i18n/issues/25 // name: 'MRPopover' is a false positive: https://gitlab.com/gitlab-org/frontend/eslint-plugin-i18n/issues/25
name: 'MRPopover', // eslint-disable-line @gitlab/i18n/no-non-i18n-strings name: 'MRPopover', // eslint-disable-line @gitlab/require-i18n-strings
components: { components: {
GlPopover, GlPopover,
GlSkeletonLoading, GlSkeletonLoading,
...@@ -102,11 +102,11 @@ export default { ...@@ -102,11 +102,11 @@ export default {
<ci-icon v-if="detailedStatus" :status="detailedStatus" /> <ci-icon v-if="detailedStatus" :status="detailedStatus" />
</div> </div>
<h5 class="my-2">{{ mergeRequestTitle }}</h5> <h5 class="my-2">{{ mergeRequestTitle }}</h5>
<!-- eslint-disable @gitlab/vue-i18n/no-bare-strings --> <!-- eslint-disable @gitlab/vue-require-i18n-strings -->
<div class="text-secondary"> <div class="text-secondary">
{{ `${projectPath}!${mergeRequestIID}` }} {{ `${projectPath}!${mergeRequestIID}` }}
</div> </div>
<!-- eslint-enable @gitlab/vue-i18n/no-bare-strings --> <!-- eslint-enable @gitlab/vue-require-i18n-strings -->
</div> </div>
</gl-popover> </gl-popover>
</template> </template>
/* eslint-disable func-names, consistent-return, no-return-assign, no-else-return, @gitlab/i18n/no-non-i18n-strings */ /* eslint-disable func-names, consistent-return, no-return-assign, no-else-return, @gitlab/require-i18n-strings */
import $ from 'jquery'; import $ from 'jquery';
import RefSelectDropdown from './ref_select_dropdown'; import RefSelectDropdown from './ref_select_dropdown';
... ...
......
...@@ -29,6 +29,7 @@ export default { ...@@ -29,6 +29,7 @@ export default {
metadata: { metadata: {
type: Object, type: Object,
default: () => ({}), default: () => ({}),
required: false,
}, },
}, },
computed: { computed: {
... ...
......
...@@ -43,7 +43,7 @@ renderer.paragraph = t => { ...@@ -43,7 +43,7 @@ renderer.paragraph = t => {
if (typeof katex !== 'undefined') { if (typeof katex !== 'undefined') {
const katexString = text const katexString = text
.replace(/&amp;/g, '&') .replace(/&amp;/g, '&')
.replace(/&=&/g, '\\space=\\space') // eslint-disable-line @gitlab/i18n/no-non-i18n-strings .replace(/&=&/g, '\\space=\\space') // eslint-disable-line @gitlab/require-i18n-strings
.replace(/<(\/?)em>/g, '_'); .replace(/<(\/?)em>/g, '_');
const regex = new RegExp(katexRegexString, 'gi'); const regex = new RegExp(katexRegexString, 'gi');
const matchLocation = katexString.search(regex); const matchLocation = katexString.search(regex);
... ...
......
...@@ -25,7 +25,7 @@ export default { ...@@ -25,7 +25,7 @@ export default {
}, },
computed: { computed: {
imgSrc() { imgSrc() {
return `data:${this.outputType};base64,${this.rawCode}`; // eslint-disable-line @gitlab/i18n/no-non-i18n-strings return `data:${this.outputType};base64,${this.rawCode}`; // eslint-disable-line @gitlab/require-i18n-strings
}, },
showOutput() { showOutput() {
return this.index === 0; return this.index === 0;
... ...
......
...@@ -22,6 +22,7 @@ export default { ...@@ -22,6 +22,7 @@ export default {
metadata: { metadata: {
type: Object, type: Object,
default: () => ({}), default: () => ({}),
required: false,
}, },
}, },
methods: { methods: {
... ...
......
...@@ -39,7 +39,7 @@ export default { ...@@ -39,7 +39,7 @@ export default {
}, },
methods: { methods: {
cellType(type) { cellType(type) {
return `${type}-cell`; // eslint-disable-line @gitlab/i18n/no-non-i18n-strings return `${type}-cell`; // eslint-disable-line @gitlab/require-i18n-strings
}, },
}, },
}; };
... ...
......
<script> <script>
/* eslint-disable @gitlab/vue-i18n/no-bare-strings */ /* eslint-disable @gitlab/vue-require-i18n-strings */
import { mapState, mapActions } from 'vuex'; import { mapState, mapActions } from 'vuex';
import { GlSkeletonLoading } from '@gitlab/ui'; import { GlSkeletonLoading } from '@gitlab/ui';
import DiffFileHeader from '~/diffs/components/diff_file_header.vue'; import DiffFileHeader from '~/diffs/components/diff_file_header.vue';
... ...
......
<script> <script>
/* eslint-disable @gitlab/vue-i18n/no-bare-strings */ /* eslint-disable @gitlab/vue-require-i18n-strings */
import timeAgoTooltip from '../../vue_shared/components/time_ago_tooltip.vue'; import timeAgoTooltip from '../../vue_shared/components/time_ago_tooltip.vue';
export default { export default {
... ...
......
...@@ -54,14 +54,14 @@ export default { ...@@ -54,14 +54,14 @@ export default {
:description="s__('ExternalMetrics|Enter the URL of the dashboard you want to link to')" :description="s__('ExternalMetrics|Enter the URL of the dashboard you want to link to')"
> >
<!-- placeholder with a url is a false positive --> <!-- placeholder with a url is a false positive -->
<!-- eslint-disable @gitlab/vue-i18n/no-bare-attribute-strings --> <!-- eslint-disable @gitlab/vue-require-i18n-attribute-strings -->
<gl-form-input <gl-form-input
id="full-dashboard-url" id="full-dashboard-url"
v-model="userDashboardUrl" v-model="userDashboardUrl"
placeholder="https://my-org.gitlab.io/my-dashboards" placeholder="https://my-org.gitlab.io/my-dashboards"
@keydown.enter.native.prevent="updateExternalDashboardUrl" @keydown.enter.native.prevent="updateExternalDashboardUrl"
/> />
<!-- eslint-enable @gitlab/vue-i18n/no-bare-attribute-strings --> <!-- eslint-enable @gitlab/vue-require-i18n-attribute-strings -->
</gl-form-group> </gl-form-group>
<gl-button variant="success" @click="updateExternalDashboardUrl"> <gl-button variant="success" @click="updateExternalDashboardUrl">
{{ __('Save Changes') }} {{ __('Save Changes') }}
... ...
......
...@@ -19,7 +19,7 @@ function loadModalsConfigurationFromHtml(modalsElement) { ...@@ -19,7 +19,7 @@ function loadModalsConfigurationFromHtml(modalsElement) {
const modalsConfiguration = {}; const modalsConfiguration = {};
if (!modalsElement) { if (!modalsElement) {
/* eslint-disable-next-line @gitlab/i18n/no-non-i18n-strings */ /* eslint-disable-next-line @gitlab/require-i18n-strings */
throw new Error('Modals content element not found!'); throw new Error('Modals content element not found!');
} }
... ...
......
/* eslint-disable @gitlab/i18n/no-non-i18n-strings */ /* eslint-disable @gitlab/require-i18n-strings */
import Vue from 'vue'; import Vue from 'vue';
import axios from '~/lib/utils/axios_utils'; import axios from '~/lib/utils/axios_utils';
... ...
......