Commit 01587498 authored by Denys Mishunov's avatar Denys Mishunov

Merge branch 'jnnkl-remove-event-listener-dom-content-loaded' into 'master'

Remove obsolete DOMContentLoadedEventListener

See merge request gitlab-org/gitlab!67411
parents 6affbcaa 96622a10
import initFilePickers from '~/file_pickers';
document.addEventListener('DOMContentLoaded', initFilePickers);
initFilePickers();
import initSettingsPanels from '~/settings_panels';
document.addEventListener('DOMContentLoaded', () => {
// Initialize expandable settings panels
initSettingsPanels();
// Initialize expandable settings panels
initSettingsPanels();
const domainCard = document.querySelector('.js-domain-cert-show');
const domainForm = document.querySelector('.js-domain-cert-inputs');
const domainReplaceButton = document.querySelector('.js-domain-cert-replace-btn');
const domainSubmitButton = document.querySelector('.js-serverless-domain-submit');
const domainCard = document.querySelector('.js-domain-cert-show');
const domainForm = document.querySelector('.js-domain-cert-inputs');
const domainReplaceButton = document.querySelector('.js-domain-cert-replace-btn');
const domainSubmitButton = document.querySelector('.js-serverless-domain-submit');
if (domainReplaceButton && domainCard && domainForm) {
domainReplaceButton.addEventListener('click', () => {
domainCard.classList.add('hidden');
domainForm.classList.remove('hidden');
domainSubmitButton.removeAttribute('disabled');
});
}
});
if (domainReplaceButton && domainCard && domainForm) {
domainReplaceButton.addEventListener('click', () => {
domainCard.classList.add('hidden');
domainForm.classList.remove('hidden');
domainSubmitButton.removeAttribute('disabled');
});
}
......@@ -5,6 +5,4 @@ import Translate from '~/vue_shared/translate';
Vue.use(Translate);
document.addEventListener('DOMContentLoaded', () => {
mountBadgeSettings(GROUP_BADGE);
});
mountBadgeSettings(GROUP_BADGE);
import mountImportProjectsTable from '~/import_entities/import_projects';
document.addEventListener('DOMContentLoaded', () => {
const mountElement = document.getElementById('import-projects-mount-element');
const mountElement = document.getElementById('import-projects-mount-element');
mountImportProjectsTable(mountElement);
});
mountImportProjectsTable(mountElement);
......@@ -5,9 +5,7 @@ import initCompareSelector from '~/projects/compare';
initCompareSelector();
document.addEventListener('DOMContentLoaded', () => {
new Diff(); // eslint-disable-line no-new
const paddingTop = 16;
initChangesDropdown(document.querySelector('.navbar-gitlab').offsetHeight - paddingTop);
GpgBadges.fetch();
});
new Diff(); // eslint-disable-line no-new
const paddingTop = 16;
initChangesDropdown(document.querySelector('.navbar-gitlab').offsetHeight - paddingTop);
GpgBadges.fetch();
import initCycleAnalytics from '~/cycle_analytics';
document.addEventListener('DOMContentLoaded', initCycleAnalytics);
initCycleAnalytics();
import initContributorsGraphs from '~/contributors';
document.addEventListener('DOMContentLoaded', initContributorsGraphs);
initContributorsGraphs();
import mountJiraImportApp from '~/jira_import';
document.addEventListener('DOMContentLoaded', mountJiraImportApp);
mountJiraImportApp();
import initForm from 'ee_else_ce/pages/projects/issues/form';
document.addEventListener('DOMContentLoaded', initForm);
initForm();
import initTerminal from '~/terminal/';
document.addEventListener('DOMContentLoaded', initTerminal);
initTerminal();
import initForm from '~/pages/projects/pages_domains/form';
document.addEventListener('DOMContentLoaded', initForm);
initForm();
import initForm from '~/pages/projects/pages_domains/form';
document.addEventListener('DOMContentLoaded', initForm);
initForm();
import Vue from 'vue';
import PipelineSchedulesCallout from '../shared/components/pipeline_schedules_callout.vue';
document.addEventListener('DOMContentLoaded', () => {
function initPipelineSchedules() {
const el = document.getElementById('pipeline-schedules-callout');
if (!el) {
......@@ -21,4 +21,6 @@ document.addEventListener('DOMContentLoaded', () => {
return createElement(PipelineSchedulesCallout);
},
});
});
}
initPipelineSchedules();
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