Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
static init(rules, _opt = {}) {
let opt = isElement(_opt) ? {el: _opt} : _opt;
let fComponent = new FormCreate(rules, opt);
let $fCreate = _vue.extend(coreComponent(fComponent, mixin));
let $vm = new $fCreate().$mount();
return {
mount($el) {
if ($el && isElement($el))
$set(fComponent.options, 'el', $el);
fComponent.options.el.appendChild($vm.$el);
return fComponent.fCreateApi;
},
remove() {
fComponent.options.el.removeChild($vm.$el);
},
function margeGlobal(_options) {
if (isBool(_options.sumbitBtn))
$set(_options, 'sumbitBtn', {show: _options.sumbitBtn});
if (isBool(_options.resetBtn))
$set(_options, 'resetBtn', {show: _options.resetBtn});
let options = deepExtend(extend(drive.getConfig(), getBaseConfig()), _options);
$set(options, 'el', !options.el
? window.document.body
: (isElement(options.el)
? options.el
: document.querySelector(options.el)
));
return options;
}
mount($el) {
if ($el && isElement($el))
formCreate.options.el = $el;
formCreate.options.el.appendChild($vm.$el);
return formCreate.handle.fCreateApi;
},
remove() {
data() {
return {rule: rules, option: isElement(option) ? {el: option} : option};
},
render() {
static create(rules, _opt = {}, $parent = undefined) {
let opt = isElement(_opt) ? {el: _opt} : _opt;
let fComponent = new FormCreate(rules, opt),
$vm = fComponent.mount(_vue);
fComponent.$parent = $parent;
return fComponent.fCreateApi;
}
mount($el) {
if ($el && isElement($el))
$set(fComponent.options, 'el', $el);
fComponent.options.el.appendChild($vm.$el);
return fComponent.fCreateApi;
},
remove() {
function margeGlobal(config, _options) {
if (isBool(_options.sumbitBtn))
_options.sumbitBtn = {show: _options.sumbitBtn};
if (isBool(_options.resetBtn))
_options.resetBtn = {show: _options.resetBtn};
let options = deepExtend(config, _options);
$set(options, 'el', !options.el
? window.document.body
: (isElement(options.el)
? options.el
: document.querySelector(options.el)
));
return options;
}