diff --git a/.eslintrc.yml b/.eslintrc.yml index f5814639b361554ec849170e21f81710a7a39906..7f45fd912a91cd531c04a989854f3a2d357d7116 100644 --- a/.eslintrc.yml +++ b/.eslintrc.yml @@ -93,6 +93,10 @@ rules: group: internal alphabetize: order: ignore + 'no-restricted-syntax': + - error + - selector: ImportSpecifier[imported.name='GlSkeletonLoading'] + message: 'Migrate to GlSkeletonLoader, or import GlDeprecatedSkeletonLoading.' overrides: - files: - '{,ee/,jh/}spec/frontend*/**/*' @@ -107,6 +111,8 @@ overrides: message: 'Using $nextTick from a component instance is discouraged. Import nextTick directly from the Vue package.' - selector: Identifier[name='setImmediate'] message: 'Prefer explicit waitForPromises (or equivalent), or jest.runAllTimers (or equivalent) to vague setImmediate calls.' + - selector: ImportSpecifier[imported.name='GlSkeletonLoading'] + message: 'Migrate to GlSkeletonLoader, or import GlDeprecatedSkeletonLoading.' - files: - 'config/**/*' - 'scripts/**/*' diff --git a/app/assets/javascripts/runner/components/runner_jobs.vue b/app/assets/javascripts/runner/components/runner_jobs.vue index eb77babcc57b66bd81bd832a0340fb76741a98c6..b25d92d049ebeb17658997120060550d852db691 100644 --- a/app/assets/javascripts/runner/components/runner_jobs.vue +++ b/app/assets/javascripts/runner/components/runner_jobs.vue @@ -1,5 +1,5 @@ <script> -import { GlSkeletonLoading } from '@gitlab/ui'; +import { GlDeprecatedSkeletonLoading as GlSkeletonLoading } from '@gitlab/ui'; import { createAlert } from '~/flash'; import runnerJobsQuery from '../graphql/details/runner_jobs.query.graphql'; import { I18N_FETCH_ERROR, I18N_NO_JOBS_FOUND, RUNNER_DETAILS_JOBS_PAGE_SIZE } from '../constants'; diff --git a/app/assets/javascripts/runner/components/runner_projects.vue b/app/assets/javascripts/runner/components/runner_projects.vue index f8ec29b8a24d6cabd85ed63093617653694334e9..d080d34fdd3533fbab8b6958946969b055cda7e5 100644 --- a/app/assets/javascripts/runner/components/runner_projects.vue +++ b/app/assets/javascripts/runner/components/runner_projects.vue @@ -1,5 +1,5 @@ <script> -import { GlSkeletonLoading } from '@gitlab/ui'; +import { GlDeprecatedSkeletonLoading as GlSkeletonLoading } from '@gitlab/ui'; import { sprintf, formatNumber } from '~/locale'; import { createAlert } from '~/flash'; import runnerProjectsQuery from '../graphql/details/runner_projects.query.graphql'; diff --git a/app/assets/javascripts/vue_shared/issuable/list/components/issuable_list_root.vue b/app/assets/javascripts/vue_shared/issuable/list/components/issuable_list_root.vue index 028d48e7e8aa2ec7a35f080184f3ccb0ac556df8..20f178dfb7ded3fb01e6762074ee8a0d6d517fee 100644 --- a/app/assets/javascripts/vue_shared/issuable/list/components/issuable_list_root.vue +++ b/app/assets/javascripts/vue_shared/issuable/list/components/issuable_list_root.vue @@ -1,5 +1,10 @@ <script> -import { GlAlert, GlKeysetPagination, GlSkeletonLoading, GlPagination } from '@gitlab/ui'; +import { + GlAlert, + GlKeysetPagination, + GlDeprecatedSkeletonLoading as GlSkeletonLoading, + GlPagination, +} from '@gitlab/ui'; import { uniqueId } from 'lodash'; import { getIdFromGraphQLId } from '~/graphql_shared/utils'; import { updateHistory, setUrlParams } from '~/lib/utils/url_utility'; diff --git a/ee/app/assets/javascripts/security_dashboard/components/shared/vulnerability_report/vulnerability_counts.vue b/ee/app/assets/javascripts/security_dashboard/components/shared/vulnerability_report/vulnerability_counts.vue index 2eecb3c7e8b5870f8239964a853c2cdb0a1fe13d..154797d85a34fc9ffe49d5b25ff35193b4a324dc 100644 --- a/ee/app/assets/javascripts/security_dashboard/components/shared/vulnerability_report/vulnerability_counts.vue +++ b/ee/app/assets/javascripts/security_dashboard/components/shared/vulnerability_report/vulnerability_counts.vue @@ -1,5 +1,5 @@ <script> -import { GlCard, GlSkeletonLoading } from '@gitlab/ui'; +import { GlCard, GlDeprecatedSkeletonLoading as GlSkeletonLoading } from '@gitlab/ui'; import SeverityBadge from 'ee/vue_shared/security_reports/components/severity_badge.vue'; import { DASHBOARD_TYPES } from 'ee/security_dashboard/store/constants'; import createFlash from '~/flash'; diff --git a/ee/app/assets/javascripts/security_dashboard/components/shared/vulnerability_report/vulnerability_list.vue b/ee/app/assets/javascripts/security_dashboard/components/shared/vulnerability_report/vulnerability_list.vue index f2bbad42968810aa00756214522796692d98ea7f..1732e1b8b29e0f1619c2881ea95e3104eba9cc6e 100644 --- a/ee/app/assets/javascripts/security_dashboard/components/shared/vulnerability_report/vulnerability_list.vue +++ b/ee/app/assets/javascripts/security_dashboard/components/shared/vulnerability_report/vulnerability_list.vue @@ -4,7 +4,7 @@ import { GlLink, GlSprintf, GlTruncate, - GlSkeletonLoading, + GlDeprecatedSkeletonLoading as GlSkeletonLoading, GlTooltipDirective, GlTable, } from '@gitlab/ui'; diff --git a/ee/app/assets/javascripts/threat_monitoring/components/alerts/alerts_list.vue b/ee/app/assets/javascripts/threat_monitoring/components/alerts/alerts_list.vue index 68a22eb752201837f3e6a42939e8eaeb1aca7970..7a4376db3758307f87a09f184778902b7a000722 100644 --- a/ee/app/assets/javascripts/threat_monitoring/components/alerts/alerts_list.vue +++ b/ee/app/assets/javascripts/threat_monitoring/components/alerts/alerts_list.vue @@ -8,7 +8,7 @@ import { GlLoadingIcon, GlTable, GlLink, - GlSkeletonLoading, + GlDeprecatedSkeletonLoading as GlSkeletonLoading, GlSprintf, GlTooltipDirective, } from '@gitlab/ui'; diff --git a/ee/spec/frontend/security_dashboard/components/shared/vulnerability_report/vulnerability_counts_spec.js b/ee/spec/frontend/security_dashboard/components/shared/vulnerability_report/vulnerability_counts_spec.js index 00eb831bb9f1cbb8d4e5eef330b90deddb824eba..245652eb5635909153222f3ee5785ba6140e5051 100644 --- a/ee/spec/frontend/security_dashboard/components/shared/vulnerability_report/vulnerability_counts_spec.js +++ b/ee/spec/frontend/security_dashboard/components/shared/vulnerability_report/vulnerability_counts_spec.js @@ -1,4 +1,4 @@ -import { GlCard, GlSkeletonLoading } from '@gitlab/ui'; +import { GlCard, GlDeprecatedSkeletonLoading as GlSkeletonLoading } from '@gitlab/ui'; import Vue, { nextTick } from 'vue'; import VueApollo from 'vue-apollo'; diff --git a/ee/spec/frontend/security_dashboard/components/shared/vulnerability_report/vulnerability_list_spec.js b/ee/spec/frontend/security_dashboard/components/shared/vulnerability_report/vulnerability_list_spec.js index d2912848e6bed7d57c5169ef449db81afffdbd3e..f3dd3f206a2599ea708af8babe6caf9a0150340e 100644 --- a/ee/spec/frontend/security_dashboard/components/shared/vulnerability_report/vulnerability_list_spec.js +++ b/ee/spec/frontend/security_dashboard/components/shared/vulnerability_report/vulnerability_list_spec.js @@ -1,4 +1,9 @@ -import { GlSkeletonLoading, GlTable, GlTruncate, GlFormCheckbox } from '@gitlab/ui'; +import { + GlDeprecatedSkeletonLoading as GlSkeletonLoading, + GlTable, + GlTruncate, + GlFormCheckbox, +} from '@gitlab/ui'; import { capitalize } from 'lodash'; import { Portal } from 'portal-vue'; import { nextTick } from 'vue'; diff --git a/ee/spec/frontend/threat_monitoring/components/alerts/alerts_list_spec.js b/ee/spec/frontend/threat_monitoring/components/alerts/alerts_list_spec.js index ae11ec354ceed1f51c724ef6c2a80ae079577979..ef752cc50818356a972df5371c55744ca8dfdbf1 100644 --- a/ee/spec/frontend/threat_monitoring/components/alerts/alerts_list_spec.js +++ b/ee/spec/frontend/threat_monitoring/components/alerts/alerts_list_spec.js @@ -1,4 +1,7 @@ -import { GlIntersectionObserver, GlSkeletonLoading } from '@gitlab/ui'; +import { + GlIntersectionObserver, + GlDeprecatedSkeletonLoading as GlSkeletonLoading, +} from '@gitlab/ui'; import { createLocalVue } from '@vue/test-utils'; import VueApollo from 'vue-apollo'; import { nextTick } from 'vue'; diff --git a/spec/frontend/ide/components/ide_side_bar_spec.js b/spec/frontend/ide/components/ide_side_bar_spec.js index 34f14ef23a4da32ad08ec6d37e6338467bb4c96b..ace8988b8c96c97d91e13ac7782ecb58e3af7efd 100644 --- a/spec/frontend/ide/components/ide_side_bar_spec.js +++ b/spec/frontend/ide/components/ide_side_bar_spec.js @@ -1,4 +1,4 @@ -import { GlSkeletonLoading } from '@gitlab/ui'; +import { GlDeprecatedSkeletonLoading as GlSkeletonLoading } from '@gitlab/ui'; import { mount } from '@vue/test-utils'; import Vue, { nextTick } from 'vue'; import Vuex from 'vuex'; diff --git a/spec/frontend/runner/components/runner_jobs_spec.js b/spec/frontend/runner/components/runner_jobs_spec.js index 9abb28610053d7fdf08485a74b041d8711bcd241..9e40e91144800243ab74a7d6b803c188112dd453 100644 --- a/spec/frontend/runner/components/runner_jobs_spec.js +++ b/spec/frontend/runner/components/runner_jobs_spec.js @@ -1,4 +1,4 @@ -import { GlSkeletonLoading } from '@gitlab/ui'; +import { GlDeprecatedSkeletonLoading as GlSkeletonLoading } from '@gitlab/ui'; import Vue from 'vue'; import VueApollo from 'vue-apollo'; import { shallowMountExtended } from 'helpers/vue_test_utils_helper'; diff --git a/spec/frontend/runner/components/runner_projects_spec.js b/spec/frontend/runner/components/runner_projects_spec.js index 96de8d11bca26a151f06a1b93eab1929f82ee26a..62ebc6539e2844a901f713a8664aa87743056923 100644 --- a/spec/frontend/runner/components/runner_projects_spec.js +++ b/spec/frontend/runner/components/runner_projects_spec.js @@ -1,4 +1,4 @@ -import { GlSkeletonLoading } from '@gitlab/ui'; +import { GlDeprecatedSkeletonLoading as GlSkeletonLoading } from '@gitlab/ui'; import Vue from 'vue'; import VueApollo from 'vue-apollo'; import { shallowMountExtended } from 'helpers/vue_test_utils_helper'; diff --git a/spec/frontend/vue_shared/issuable/list/components/issuable_list_root_spec.js b/spec/frontend/vue_shared/issuable/list/components/issuable_list_root_spec.js index 64823cd4c6c89cfd663748c976009fde126c22d0..058cb30c1d57e7c1f45c1e8b6c272335e6cb9b63 100644 --- a/spec/frontend/vue_shared/issuable/list/components/issuable_list_root_spec.js +++ b/spec/frontend/vue_shared/issuable/list/components/issuable_list_root_spec.js @@ -1,4 +1,9 @@ -import { GlAlert, GlKeysetPagination, GlSkeletonLoading, GlPagination } from '@gitlab/ui'; +import { + GlAlert, + GlKeysetPagination, + GlDeprecatedSkeletonLoading as GlSkeletonLoading, + GlPagination, +} from '@gitlab/ui'; import { shallowMount } from '@vue/test-utils'; import VueDraggable from 'vuedraggable';