debian-mirror-gitlab/app/assets/javascripts/group_settings/mount_shared_runners.js
2021-12-11 22:18:48 +05:30

30 lines
731 B
JavaScript

import Vue from 'vue';
import UpdateSharedRunnersForm from './components/shared_runners_form.vue';
export default (containerId = 'update-shared-runners-form') => {
const containerEl = document.getElementById(containerId);
const {
updatePath,
sharedRunnersAvailability,
parentSharedRunnersAvailability,
runnerEnabled,
runnerDisabled,
runnerAllowOverride,
} = containerEl.dataset;
return new Vue({
el: containerEl,
provide: {
updatePath,
sharedRunnersAvailability,
parentSharedRunnersAvailability,
runnerEnabled,
runnerDisabled,
runnerAllowOverride,
},
render(createElement) {
return createElement(UpdateSharedRunnersForm);
},
});
};