debian-mirror-gitlab/app/assets/javascripts/commons/bootstrap.js
2018-12-13 13:39:08 +05:30

18 lines
316 B
JavaScript

import $ from 'jquery';
// bootstrap jQuery plugins
import 'bootstrap';
// custom jQuery functions
$.fn.extend({
disable() {
return $(this)
.prop('disabled', true)
.addClass('disabled');
},
enable() {
return $(this)
.prop('disabled', false)
.removeClass('disabled');
},
});