@gitlab/ui
Version:
GitLab UI Components
24 lines (18 loc) • 490 B
JavaScript
import { extend } from '../vue';
import { PROP_TYPE_STRING } from '../constants/props';
import { makePropsConfigurable, makeProp } from '../utils/props';
// --- Props ---
const props = makePropsConfigurable({
size: makeProp(PROP_TYPE_STRING)
}, 'formControls');
// --- Mixin ---
// @vue/component
const formSizeMixin = extend({
props,
computed: {
sizeFormClass() {
return [this.size ? `form-control-${this.size}` : null];
}
}
});
export { formSizeMixin, props };