vue-easy-form
Version:
<p align="left"> <a href="https://github.com/vuejs/vue"><img src="https://img.shields.io/badge/vue-2.6.10-brightgreen.svg" alt="vue"></a> <a href="https://www.npmjs.com/package/vue-easy-form"><img src="https://img.shields.io/npm/v/vue-easy-form.svg" a
20,523 lines • 673 kB
JavaScript
(function webpackUniversalModuleDefinition(root, factory) {
if(typeof exports === 'object' && typeof module === 'object')
module.exports = factory();
else if(typeof define === 'function' && define.amd)
define([], factory);
else if(typeof exports === 'object')
exports["esForm"] = factory();
else
root["esForm"] = factory();
})((typeof self !== 'undefined' ? self : this), function() {
return /******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/
/******/ // Check if module is in cache
/******/ if(installedModules[moduleId]) {
/******/ return installedModules[moduleId].exports;
/******/ }
/******/ // Create a new module (and put it into the cache)
/******/ var module = installedModules[moduleId] = {
/******/ i: moduleId,
/******/ l: false,
/******/ exports: {}
/******/ };
/******/
/******/ // Execute the module function
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/
/******/ // Flag the module as loaded
/******/ module.l = true;
/******/
/******/ // Return the exports of the module
/******/ return module.exports;
/******/ }
/******/
/******/
/******/ // expose the modules object (__webpack_modules__)
/******/ __webpack_require__.m = modules;
/******/
/******/ // expose the module cache
/******/ __webpack_require__.c = installedModules;
/******/
/******/ // define getter function for harmony exports
/******/ __webpack_require__.d = function(exports, name, getter) {
/******/ if(!__webpack_require__.o(exports, name)) {
/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter });
/******/ }
/******/ };
/******/
/******/ // define __esModule on exports
/******/ __webpack_require__.r = function(exports) {
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
/******/ }
/******/ Object.defineProperty(exports, '__esModule', { value: true });
/******/ };
/******/
/******/ // create a fake namespace object
/******/ // mode & 1: value is a module id, require it
/******/ // mode & 2: merge all properties of value into the ns
/******/ // mode & 4: return value when already ns object
/******/ // mode & 8|1: behave like require
/******/ __webpack_require__.t = function(value, mode) {
/******/ if(mode & 1) value = __webpack_require__(value);
/******/ if(mode & 8) return value;
/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
/******/ var ns = Object.create(null);
/******/ __webpack_require__.r(ns);
/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value });
/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
/******/ return ns;
/******/ };
/******/
/******/ // getDefaultExport function for compatibility with non-harmony modules
/******/ __webpack_require__.n = function(module) {
/******/ var getter = module && module.__esModule ?
/******/ function getDefault() { return module['default']; } :
/******/ function getModuleExports() { return module; };
/******/ __webpack_require__.d(getter, 'a', getter);
/******/ return getter;
/******/ };
/******/
/******/ // Object.prototype.hasOwnProperty.call
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
/******/
/******/ // __webpack_public_path__
/******/ __webpack_require__.p = "";
/******/
/******/
/******/ // Load entry module and return exports
/******/ return __webpack_require__(__webpack_require__.s = "fb15");
/******/ })
/************************************************************************/
/******/ ({
/***/ "01f9":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var LIBRARY = __webpack_require__("2d00");
var $export = __webpack_require__("5ca1");
var redefine = __webpack_require__("2aba");
var hide = __webpack_require__("32e9");
var Iterators = __webpack_require__("84f2");
var $iterCreate = __webpack_require__("41a0");
var setToStringTag = __webpack_require__("7f20");
var getPrototypeOf = __webpack_require__("38fd");
var ITERATOR = __webpack_require__("2b4c")('iterator');
var BUGGY = !([].keys && 'next' in [].keys()); // Safari has buggy iterators w/o `next`
var FF_ITERATOR = '@@iterator';
var KEYS = 'keys';
var VALUES = 'values';
var returnThis = function () { return this; };
module.exports = function (Base, NAME, Constructor, next, DEFAULT, IS_SET, FORCED) {
$iterCreate(Constructor, NAME, next);
var getMethod = function (kind) {
if (!BUGGY && kind in proto) return proto[kind];
switch (kind) {
case KEYS: return function keys() { return new Constructor(this, kind); };
case VALUES: return function values() { return new Constructor(this, kind); };
} return function entries() { return new Constructor(this, kind); };
};
var TAG = NAME + ' Iterator';
var DEF_VALUES = DEFAULT == VALUES;
var VALUES_BUG = false;
var proto = Base.prototype;
var $native = proto[ITERATOR] || proto[FF_ITERATOR] || DEFAULT && proto[DEFAULT];
var $default = $native || getMethod(DEFAULT);
var $entries = DEFAULT ? !DEF_VALUES ? $default : getMethod('entries') : undefined;
var $anyNative = NAME == 'Array' ? proto.entries || $native : $native;
var methods, key, IteratorPrototype;
// Fix native
if ($anyNative) {
IteratorPrototype = getPrototypeOf($anyNative.call(new Base()));
if (IteratorPrototype !== Object.prototype && IteratorPrototype.next) {
// Set @@toStringTag to native iterators
setToStringTag(IteratorPrototype, TAG, true);
// fix for some old engines
if (!LIBRARY && typeof IteratorPrototype[ITERATOR] != 'function') hide(IteratorPrototype, ITERATOR, returnThis);
}
}
// fix Array#{values, @@iterator}.name in V8 / FF
if (DEF_VALUES && $native && $native.name !== VALUES) {
VALUES_BUG = true;
$default = function values() { return $native.call(this); };
}
// Define iterator
if ((!LIBRARY || FORCED) && (BUGGY || VALUES_BUG || !proto[ITERATOR])) {
hide(proto, ITERATOR, $default);
}
// Plug for library
Iterators[NAME] = $default;
Iterators[TAG] = returnThis;
if (DEFAULT) {
methods = {
values: DEF_VALUES ? $default : getMethod(VALUES),
keys: IS_SET ? $default : getMethod(KEYS),
entries: $entries
};
if (FORCED) for (key in methods) {
if (!(key in proto)) redefine(proto, key, methods[key]);
} else $export($export.P + $export.F * (BUGGY || VALUES_BUG), NAME, methods);
}
return methods;
};
/***/ }),
/***/ "02f4":
/***/ (function(module, exports, __webpack_require__) {
var toInteger = __webpack_require__("4588");
var defined = __webpack_require__("be13");
// true -> String#at
// false -> String#codePointAt
module.exports = function (TO_STRING) {
return function (that, pos) {
var s = String(defined(that));
var i = toInteger(pos);
var l = s.length;
var a, b;
if (i < 0 || i >= l) return TO_STRING ? '' : undefined;
a = s.charCodeAt(i);
return a < 0xd800 || a > 0xdbff || i + 1 === l || (b = s.charCodeAt(i + 1)) < 0xdc00 || b > 0xdfff
? TO_STRING ? s.charAt(i) : a
: TO_STRING ? s.slice(i, i + 2) : (a - 0xd800 << 10) + (b - 0xdc00) + 0x10000;
};
};
/***/ }),
/***/ "0390":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var at = __webpack_require__("02f4")(true);
// `AdvanceStringIndex` abstract operation
// https://tc39.github.io/ecma262/#sec-advancestringindex
module.exports = function (S, index, unicode) {
return index + (unicode ? at(S, index).length : 1);
};
/***/ }),
/***/ "07e3":
/***/ (function(module, exports) {
var hasOwnProperty = {}.hasOwnProperty;
module.exports = function (it, key) {
return hasOwnProperty.call(it, key);
};
/***/ }),
/***/ "097d":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
// https://github.com/tc39/proposal-promise-finally
var $export = __webpack_require__("5ca1");
var core = __webpack_require__("8378");
var global = __webpack_require__("7726");
var speciesConstructor = __webpack_require__("ebd6");
var promiseResolve = __webpack_require__("bcaa");
$export($export.P + $export.R, 'Promise', { 'finally': function (onFinally) {
var C = speciesConstructor(this, core.Promise || global.Promise);
var isFunction = typeof onFinally == 'function';
return this.then(
isFunction ? function (x) {
return promiseResolve(C, onFinally()).then(function () { return x; });
} : onFinally,
isFunction ? function (e) {
return promiseResolve(C, onFinally()).then(function () { throw e; });
} : onFinally
);
} });
/***/ }),
/***/ "0a90":
/***/ (function(module, exports, __webpack_require__) {
var $export = __webpack_require__("63b6");
var $parseFloat = __webpack_require__("10ff");
// 18.2.4 parseFloat(string)
$export($export.G + $export.F * (parseFloat != $parseFloat), { parseFloat: $parseFloat });
/***/ }),
/***/ "0bfb":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
// 21.2.5.3 get RegExp.prototype.flags
var anObject = __webpack_require__("cb7c");
module.exports = function () {
var that = anObject(this);
var result = '';
if (that.global) result += 'g';
if (that.ignoreCase) result += 'i';
if (that.multiline) result += 'm';
if (that.unicode) result += 'u';
if (that.sticky) result += 'y';
return result;
};
/***/ }),
/***/ "0d58":
/***/ (function(module, exports, __webpack_require__) {
// 19.1.2.14 / 15.2.3.14 Object.keys(O)
var $keys = __webpack_require__("ce10");
var enumBugKeys = __webpack_require__("e11e");
module.exports = Object.keys || function keys(O) {
return $keys(O, enumBugKeys);
};
/***/ }),
/***/ "0fc9":
/***/ (function(module, exports, __webpack_require__) {
var toInteger = __webpack_require__("3a38");
var max = Math.max;
var min = Math.min;
module.exports = function (index, length) {
index = toInteger(index);
return index < 0 ? max(index + length, 0) : min(index, length);
};
/***/ }),
/***/ "10ff":
/***/ (function(module, exports, __webpack_require__) {
var $parseFloat = __webpack_require__("e53d").parseFloat;
var $trim = __webpack_require__("a1ce").trim;
module.exports = 1 / $parseFloat(__webpack_require__("e692") + '-0') !== -Infinity ? function parseFloat(str) {
var string = $trim(String(str), 3);
var result = $parseFloat(string);
return result === 0 && string.charAt(0) == '-' ? -0 : result;
} : $parseFloat;
/***/ }),
/***/ "11e9":
/***/ (function(module, exports, __webpack_require__) {
var pIE = __webpack_require__("52a7");
var createDesc = __webpack_require__("4630");
var toIObject = __webpack_require__("6821");
var toPrimitive = __webpack_require__("6a99");
var has = __webpack_require__("69a8");
var IE8_DOM_DEFINE = __webpack_require__("c69a");
var gOPD = Object.getOwnPropertyDescriptor;
exports.f = __webpack_require__("9e1e") ? gOPD : function getOwnPropertyDescriptor(O, P) {
O = toIObject(O);
P = toPrimitive(P, true);
if (IE8_DOM_DEFINE) try {
return gOPD(O, P);
} catch (e) { /* empty */ }
if (has(O, P)) return createDesc(!pIE.f.call(O, P), O[P]);
};
/***/ }),
/***/ "1495":
/***/ (function(module, exports, __webpack_require__) {
var dP = __webpack_require__("86cc");
var anObject = __webpack_require__("cb7c");
var getKeys = __webpack_require__("0d58");
module.exports = __webpack_require__("9e1e") ? Object.defineProperties : function defineProperties(O, Properties) {
anObject(O);
var keys = getKeys(Properties);
var length = keys.length;
var i = 0;
var P;
while (length > i) dP.f(O, P = keys[i++], Properties[P]);
return O;
};
/***/ }),
/***/ "14a3":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, ".es-form-array-tabs{overflow:hidden}.es-form-array-tabs .es-tabs-body{margin:0;padding:0;list-style:none;border:1px solid #e4e7ed;border-top:none;border-radius:0 0 4px 4px}.es-form-array-tabs .es-tabs-body li{position:relative;margin:0;padding:0;left:0;top:0}.es-form-array-tabs .es-tabs-body .empty-body-item{line-height:40px;font-size:13px;text-align:center;color:#b3b5b9}", ""]);
// exports
/***/ }),
/***/ "15b8":
/***/ (function(module, exports, __webpack_require__) {
module.exports = __webpack_require__("e1b7");
/***/ }),
/***/ "1654":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var $at = __webpack_require__("71c1")(true);
// 21.1.3.27 String.prototype[@@iterator]()
__webpack_require__("30f1")(String, 'String', function (iterated) {
this._t = String(iterated); // target
this._i = 0; // next index
// 21.1.5.2.1 %StringIteratorPrototype%.next()
}, function () {
var O = this._t;
var index = this._i;
var point;
if (index >= O.length) return { value: undefined, done: true };
point = $at(O, index);
this._i += point.length;
return { value: point, done: false };
});
/***/ }),
/***/ "1691":
/***/ (function(module, exports) {
// IE 8- don't enum bug keys
module.exports = (
'constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf'
).split(',');
/***/ }),
/***/ "18d0":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("1ed1");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("63bdfbfe", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "18d05":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_edit_bottom_btns_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("aa4c");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_edit_bottom_btns_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_edit_bottom_btns_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_edit_bottom_btns_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "1991":
/***/ (function(module, exports, __webpack_require__) {
var ctx = __webpack_require__("9b43");
var invoke = __webpack_require__("31f4");
var html = __webpack_require__("fab2");
var cel = __webpack_require__("230e");
var global = __webpack_require__("7726");
var process = global.process;
var setTask = global.setImmediate;
var clearTask = global.clearImmediate;
var MessageChannel = global.MessageChannel;
var Dispatch = global.Dispatch;
var counter = 0;
var queue = {};
var ONREADYSTATECHANGE = 'onreadystatechange';
var defer, channel, port;
var run = function () {
var id = +this;
// eslint-disable-next-line no-prototype-builtins
if (queue.hasOwnProperty(id)) {
var fn = queue[id];
delete queue[id];
fn();
}
};
var listener = function (event) {
run.call(event.data);
};
// Node.js 0.9+ & IE10+ has setImmediate, otherwise:
if (!setTask || !clearTask) {
setTask = function setImmediate(fn) {
var args = [];
var i = 1;
while (arguments.length > i) args.push(arguments[i++]);
queue[++counter] = function () {
// eslint-disable-next-line no-new-func
invoke(typeof fn == 'function' ? fn : Function(fn), args);
};
defer(counter);
return counter;
};
clearTask = function clearImmediate(id) {
delete queue[id];
};
// Node.js 0.8-
if (__webpack_require__("2d95")(process) == 'process') {
defer = function (id) {
process.nextTick(ctx(run, id, 1));
};
// Sphere (JS game engine) Dispatch API
} else if (Dispatch && Dispatch.now) {
defer = function (id) {
Dispatch.now(ctx(run, id, 1));
};
// Browsers with MessageChannel, includes WebWorkers
} else if (MessageChannel) {
channel = new MessageChannel();
port = channel.port2;
channel.port1.onmessage = listener;
defer = ctx(port.postMessage, port, 1);
// Browsers with postMessage, skip WebWorkers
// IE8 has postMessage, but it's sync & typeof its postMessage is 'object'
} else if (global.addEventListener && typeof postMessage == 'function' && !global.importScripts) {
defer = function (id) {
global.postMessage(id + '', '*');
};
global.addEventListener('message', listener, false);
// IE8-
} else if (ONREADYSTATECHANGE in cel('script')) {
defer = function (id) {
html.appendChild(cel('script'))[ONREADYSTATECHANGE] = function () {
html.removeChild(this);
run.call(id);
};
};
// Rest old browsers
} else {
defer = function (id) {
setTimeout(ctx(run, id, 1), 0);
};
}
}
module.exports = {
set: setTask,
clear: clearTask
};
/***/ }),
/***/ "1af6":
/***/ (function(module, exports, __webpack_require__) {
// 22.1.2.2 / 15.4.3.2 Array.isArray(arg)
var $export = __webpack_require__("63b6");
$export($export.S, 'Array', { isArray: __webpack_require__("9003") });
/***/ }),
/***/ "1bc3":
/***/ (function(module, exports, __webpack_require__) {
// 7.1.1 ToPrimitive(input [, PreferredType])
var isObject = __webpack_require__("f772");
// instead of the ES6 spec version, we didn't implement @@toPrimitive case
// and the second argument - flag - preferred type is a string
module.exports = function (it, S) {
if (!isObject(it)) return it;
var fn, val;
if (S && typeof (fn = it.toString) == 'function' && !isObject(val = fn.call(it))) return val;
if (typeof (fn = it.valueOf) == 'function' && !isObject(val = fn.call(it))) return val;
if (!S && typeof (fn = it.toString) == 'function' && !isObject(val = fn.call(it))) return val;
throw TypeError("Can't convert object to primitive value");
};
/***/ }),
/***/ "1ec9":
/***/ (function(module, exports, __webpack_require__) {
var isObject = __webpack_require__("f772");
var document = __webpack_require__("e53d").document;
// typeof document.createElement is 'object' in old IE
var is = isObject(document) && isObject(document.createElement);
module.exports = function (it) {
return is ? document.createElement(it) : {};
};
/***/ }),
/***/ "1ed1":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, ".es-console-box{position:absolute;left:0;top:0;overflow:visible}.es-console-box .console-btn{display:inline-block;line-height:1;white-space:nowrap;cursor:pointer;background:rgba(0,0,0,.5);border:1px solid #dcdfe6;color:#fff;-webkit-appearance:none;text-align:center;-webkit-box-sizing:border-box;box-sizing:border-box;outline:none;margin:0;-webkit-transition:.1s;transition:.1s;font-weight:500;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;padding:4px 10px;font-size:12px;border-radius:12px}.es-console-box .console-btn:hover{background:rgba(102,177,255,.4);color:#666;border-color:#79bbff}.es-console-panel{position:fixed;right:20px;top:20px;border:1px solid #b3d8ff;border-radius:5px;background:#fff;text-align:left;overflow:hidden;width:400px}.es-console-panel .console-header{background:#ecf5ff;cursor:move}.es-console-panel .console-header .panel-title{cursor:move;margin:0;padding:0 0 0 10px;line-height:40px;font-size:16px;font-weight:700}.es-console-panel .console-header *{cursor:\"move\"}.es-console-panel .console-close{position:absolute;top:12px;right:10px;color:#409eff;cursor:pointer;line-height:18px;font-size:14px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.es-console-panel .console-close:hover{color:#66b1ff;text-decoration:underline}.es-console-panel .panel-body{margin:0;padding:0 10px 10px 10px}.es-console-panel .panel-body .subtitle{margin:6px 0 0 5px;padding:0;line-height:20px;font-size:14px;font-weight:600}.es-console-panel .panel-body .question-box{margin-top:10px}.es-console-panel .panel-body .question{margin:0 5px;text-decoration:none;color:#409eff;outline:none;padding:0;line-height:15px;font-size:13px;font-weight:500}.es-console-panel .panel-body .question:hover{border-bottom:1px solid #409eff}.es-console-panel .panel-body .value-box{border:1px solid #dcdfe6;height:150px;border-radius:3px;padding:5px;overflow:auto;width:100%;min-width:100%;max-width:100%;outline:none;-webkit-box-sizing:border-box;box-sizing:border-box;font-size:13px;line-height:20px}", ""]);
// exports
/***/ }),
/***/ "1fa8":
/***/ (function(module, exports, __webpack_require__) {
// call something on iterator step with safe closing on error
var anObject = __webpack_require__("cb7c");
module.exports = function (iterator, fn, value, entries) {
try {
return entries ? fn(anObject(value)[0], value[1]) : fn(value);
// 7.4.6 IteratorClose(iterator, completion)
} catch (e) {
var ret = iterator['return'];
if (ret !== undefined) anObject(ret.call(iterator));
throw e;
}
};
/***/ }),
/***/ "20fd":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var $defineProperty = __webpack_require__("d9f6");
var createDesc = __webpack_require__("aebd");
module.exports = function (object, index, value) {
if (index in object) $defineProperty.f(object, index, createDesc(0, value));
else object[index] = value;
};
/***/ }),
/***/ "214f":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
__webpack_require__("b0c5");
var redefine = __webpack_require__("2aba");
var hide = __webpack_require__("32e9");
var fails = __webpack_require__("79e5");
var defined = __webpack_require__("be13");
var wks = __webpack_require__("2b4c");
var regexpExec = __webpack_require__("520a");
var SPECIES = wks('species');
var REPLACE_SUPPORTS_NAMED_GROUPS = !fails(function () {
// #replace needs built-in support for named groups.
// #match works fine because it just return the exec results, even if it has
// a "grops" property.
var re = /./;
re.exec = function () {
var result = [];
result.groups = { a: '7' };
return result;
};
return ''.replace(re, '$<a>') !== '7';
});
var SPLIT_WORKS_WITH_OVERWRITTEN_EXEC = (function () {
// Chrome 51 has a buggy "split" implementation when RegExp#exec !== nativeExec
var re = /(?:)/;
var originalExec = re.exec;
re.exec = function () { return originalExec.apply(this, arguments); };
var result = 'ab'.split(re);
return result.length === 2 && result[0] === 'a' && result[1] === 'b';
})();
module.exports = function (KEY, length, exec) {
var SYMBOL = wks(KEY);
var DELEGATES_TO_SYMBOL = !fails(function () {
// String methods call symbol-named RegEp methods
var O = {};
O[SYMBOL] = function () { return 7; };
return ''[KEY](O) != 7;
});
var DELEGATES_TO_EXEC = DELEGATES_TO_SYMBOL ? !fails(function () {
// Symbol-named RegExp methods call .exec
var execCalled = false;
var re = /a/;
re.exec = function () { execCalled = true; return null; };
if (KEY === 'split') {
// RegExp[@@split] doesn't call the regex's exec method, but first creates
// a new one. We need to return the patched regex when creating the new one.
re.constructor = {};
re.constructor[SPECIES] = function () { return re; };
}
re[SYMBOL]('');
return !execCalled;
}) : undefined;
if (
!DELEGATES_TO_SYMBOL ||
!DELEGATES_TO_EXEC ||
(KEY === 'replace' && !REPLACE_SUPPORTS_NAMED_GROUPS) ||
(KEY === 'split' && !SPLIT_WORKS_WITH_OVERWRITTEN_EXEC)
) {
var nativeRegExpMethod = /./[SYMBOL];
var fns = exec(
defined,
SYMBOL,
''[KEY],
function maybeCallNative(nativeMethod, regexp, str, arg2, forceStringMethod) {
if (regexp.exec === regexpExec) {
if (DELEGATES_TO_SYMBOL && !forceStringMethod) {
// The native String method already delegates to @@method (this
// polyfilled function), leasing to infinite recursion.
// We avoid it by directly calling the native @@method method.
return { done: true, value: nativeRegExpMethod.call(regexp, str, arg2) };
}
return { done: true, value: nativeMethod.call(str, regexp, arg2) };
}
return { done: false };
}
);
var strfn = fns[0];
var rxfn = fns[1];
redefine(String.prototype, KEY, strfn);
hide(RegExp.prototype, SYMBOL, length == 2
// 21.2.5.8 RegExp.prototype[@@replace](string, replaceValue)
// 21.2.5.11 RegExp.prototype[@@split](string, limit)
? function (string, arg) { return rxfn.call(string, this, arg); }
// 21.2.5.6 RegExp.prototype[@@match](string)
// 21.2.5.9 RegExp.prototype[@@search](string)
: function (string) { return rxfn.call(string, this); }
);
}
};
/***/ }),
/***/ "2223":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_object_table_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("ec12");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_object_table_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_object_table_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_object_table_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "230e":
/***/ (function(module, exports, __webpack_require__) {
var isObject = __webpack_require__("d3f4");
var document = __webpack_require__("7726").document;
// typeof document.createElement is 'object' in old IE
var is = isObject(document) && isObject(document.createElement);
module.exports = function (it) {
return is ? document.createElement(it) : {};
};
/***/ }),
/***/ "2350":
/***/ (function(module, exports) {
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Tobias Koppers @sokra
*/
// css base code, injected by the css-loader
module.exports = function(useSourceMap) {
var list = [];
// return the list of modules as css string
list.toString = function toString() {
return this.map(function (item) {
var content = cssWithMappingToString(item, useSourceMap);
if(item[2]) {
return "@media " + item[2] + "{" + content + "}";
} else {
return content;
}
}).join("");
};
// import a list of modules into the list
list.i = function(modules, mediaQuery) {
if(typeof modules === "string")
modules = [[null, modules, ""]];
var alreadyImportedModules = {};
for(var i = 0; i < this.length; i++) {
var id = this[i][0];
if(typeof id === "number")
alreadyImportedModules[id] = true;
}
for(i = 0; i < modules.length; i++) {
var item = modules[i];
// skip already imported module
// this implementation is not 100% perfect for weird media query combinations
// when a module is imported multiple times with different media queries.
// I hope this will never occur (Hey this way we have smaller bundles)
if(typeof item[0] !== "number" || !alreadyImportedModules[item[0]]) {
if(mediaQuery && !item[2]) {
item[2] = mediaQuery;
} else if(mediaQuery) {
item[2] = "(" + item[2] + ") and (" + mediaQuery + ")";
}
list.push(item);
}
}
};
return list;
};
function cssWithMappingToString(item, useSourceMap) {
var content = item[1] || '';
var cssMapping = item[3];
if (!cssMapping) {
return content;
}
if (useSourceMap && typeof btoa === 'function') {
var sourceMapping = toComment(cssMapping);
var sourceURLs = cssMapping.sources.map(function (source) {
return '/*# sourceURL=' + cssMapping.sourceRoot + source + ' */'
});
return [content].concat(sourceURLs).concat([sourceMapping]).join('\n');
}
return [content].join('\n');
}
// Adapted from convert-source-map (MIT)
function toComment(sourceMap) {
// eslint-disable-next-line no-undef
var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap))));
var data = 'sourceMappingURL=data:application/json;charset=utf-8;base64,' + base64;
return '/*# ' + data + ' */';
}
/***/ }),
/***/ "23c6":
/***/ (function(module, exports, __webpack_require__) {
// getting tag from 19.1.3.6 Object.prototype.toString()
var cof = __webpack_require__("2d95");
var TAG = __webpack_require__("2b4c")('toStringTag');
// ES3 wrong here
var ARG = cof(function () { return arguments; }()) == 'Arguments';
// fallback for IE11 Script Access Denied error
var tryGet = function (it, key) {
try {
return it[key];
} catch (e) { /* empty */ }
};
module.exports = function (it) {
var O, T, B;
return it === undefined ? 'Undefined' : it === null ? 'Null'
// @@toStringTag case
: typeof (T = tryGet(O = Object(it), TAG)) == 'string' ? T
// builtinTag case
: ARG ? cof(O)
// ES3 arguments fallback
: (B = cof(O)) == 'Object' && typeof O.callee == 'function' ? 'Arguments' : B;
};
/***/ }),
/***/ "241e":
/***/ (function(module, exports, __webpack_require__) {
// 7.1.13 ToObject(argument)
var defined = __webpack_require__("25eb");
module.exports = function (it) {
return Object(defined(it));
};
/***/ }),
/***/ "25eb":
/***/ (function(module, exports) {
// 7.2.1 RequireObjectCoercible(argument)
module.exports = function (it) {
if (it == undefined) throw TypeError("Can't call method on " + it);
return it;
};
/***/ }),
/***/ "2621":
/***/ (function(module, exports) {
exports.f = Object.getOwnPropertySymbols;
/***/ }),
/***/ "271b":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, ".es-form-container{overflow:hidden}.es-form-inner-wrap{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start;-webkit-box-align:start;-ms-flex-align:start;align-items:flex-start;-ms-flex-wrap:wrap;flex-wrap:wrap}.es-form-inner-wrap:after,.es-form-inner-wrap:before{content:\".\";display:block;overflow:hidden;visibility:hidden;font-size:0;line-height:0;width:0;height:0}.es-form-inner-wrap:after{clear:both}.es-form-inner-wrap .es-form-placeholder{-ms-flex-direction:row;flex-direction:row;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto;-ms-flex-pack:start;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.es-form-inner-wrap .es-form-object,.es-form-inner-wrap .es-form-placeholder{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-box-flex:0;-wekit-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-box-pack:start;justify-content:flex-start}.es-form-inner-wrap .es-form-object{-ms-flex-direction:row;flex-direction:row;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto;-ms-flex-pack:start;-webkit-box-align:start;-ms-flex-align:start;align-items:flex-start;padding:0}.es-form-inner-wrap .es-form-none{display:none}.es-form-inner-wrap .es-form-v{-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-align:stretch;-ms-flex-align:stretch;align-items:stretch}.es-form-inner-wrap .es-form-label-col{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto;-wekit-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box;width:115px;padding:0 10px 0 4px;text-align:right;line-height:1.2;white-space:nowrap;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:end;-ms-flex-pack:end;justify-content:flex-end}.es-form-inner-wrap .es-form-label-col-v{text-align:left;width:auto;line-height:20px;padding:2px 3px}.es-form-inner-wrap .es-form-label-col-v,.es-form-inner-wrap .es-form-label-left{-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start}.es-form-inner-wrap .es-form-label-center{-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.es-form-inner-wrap .es-form-label-right{-webkit-box-pack:end;-ms-flex-pack:end;justify-content:flex-end}.es-form-inner-wrap .es-form-colon{margin-left:3px}.es-form-inner-wrap .es-form-label-full{-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto;width:auto;padding:0 10px;text-align:center;white-space:nowrap}.es-form-inner-wrap .es-form-label-self{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto;width:auto;padding:0 10px;text-align:center;white-space:nowrap}.es-form-inner-wrap .es-form-comp-content{-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:start;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.es-form-inner-wrap .es-form-comp-content,.es-form-inner-wrap .es-form-props-content{-webkit-box-flex:1;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-box-pack:start;justify-content:flex-start;overflow:hidden}.es-form-inner-wrap .es-form-props-content{-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:start;-webkit-box-align:start;-ms-flex-align:start;align-items:flex-start}.es-form-inner-wrap .es-form-group-full{-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto;width:auto}.es-form-inner-wrap .es-form-group-self{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto;width:auto}.es-form-inner-wrap .es-form-placeholder-txt{-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto}", ""]);
// exports
/***/ }),
/***/ "27ee":
/***/ (function(module, exports, __webpack_require__) {
var classof = __webpack_require__("23c6");
var ITERATOR = __webpack_require__("2b4c")('iterator');
var Iterators = __webpack_require__("84f2");
module.exports = __webpack_require__("8378").getIteratorMethod = function (it) {
if (it != undefined) return it[ITERATOR]
|| it['@@iterator']
|| Iterators[classof(it)];
};
/***/ }),
/***/ "2877":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return normalizeComponent; });
/* globals __VUE_SSR_CONTEXT__ */
// IMPORTANT: Do NOT use ES2015 features in this file (except for modules).
// This module is a runtime utility for cleaner component module output and will
// be included in the final webpack user bundle.
function normalizeComponent (
scriptExports,
render,
staticRenderFns,
functionalTemplate,
injectStyles,
scopeId,
moduleIdentifier, /* server only */
shadowMode /* vue-cli only */
) {
// Vue.extend constructor export interop
var options = typeof scriptExports === 'function'
? scriptExports.options
: scriptExports
// render functions
if (render) {
options.render = render
options.staticRenderFns = staticRenderFns
options._compiled = true
}
// functional template
if (functionalTemplate) {
options.functional = true
}
// scopedId
if (scopeId) {
options._scopeId = 'data-v-' + scopeId
}
var hook
if (moduleIdentifier) { // server build
hook = function (context) {
// 2.3 injection
context =
context || // cached call
(this.$vnode && this.$vnode.ssrContext) || // stateful
(this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional
// 2.2 with runInNewContext: true
if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {
context = __VUE_SSR_CONTEXT__
}
// inject component styles
if (injectStyles) {
injectStyles.call(this, context)
}
// register component module identifier for async chunk inferrence
if (context && context._registeredComponents) {
context._registeredComponents.add(moduleIdentifier)
}
}
// used by ssr in case component is cached and beforeCreate
// never gets called
options._ssrRegister = hook
} else if (injectStyles) {
hook = shadowMode
? function () { injectStyles.call(this, this.$root.$options.shadowRoot) }
: injectStyles
}
if (hook) {
if (options.functional) {
// for template-only hot-reload because in that case the render fn doesn't
// go through the normalizer
options._injectStyles = hook
// register for functioal component in vue file
var originalRender = options.render
options.render = function renderWithStyleInjection (h, context) {
hook.call(context)
return originalRender(h, context)
}
} else {
// inject component registration as beforeCreate hook
var existing = options.beforeCreate
options.beforeCreate = existing
? [].concat(existing, hook)
: [hook]
}
}
return {
exports: scriptExports,
options: options
}
}
/***/ }),
/***/ "28a5":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var isRegExp = __webpack_require__("aae3");
var anObject = __webpack_require__("cb7c");
var speciesConstructor = __webpack_require__("ebd6");
var advanceStringIndex = __webpack_require__("0390");
var toLength = __webpack_require__("9def");
var callRegExpExec = __webpack_require__("5f1b");
var regexpExec = __webpack_require__("520a");
var fails = __webpack_require__("79e5");
var $min = Math.min;
var $push = [].push;
var $SPLIT = 'split';
var LENGTH = 'length';
var LAST_INDEX = 'lastIndex';
var MAX_UINT32 = 0xffffffff;
// babel-minify transpiles RegExp('x', 'y') -> /x/y and it causes SyntaxError
var SUPPORTS_Y = !fails(function () { RegExp(MAX_UINT32, 'y'); });
// @@split logic
__webpack_require__("214f")('split', 2, function (defined, SPLIT, $split, maybeCallNative) {
var internalSplit;
if (
'abbc'[$SPLIT](/(b)*/)[1] == 'c' ||
'test'[$SPLIT](/(?:)/, -1)[LENGTH] != 4 ||
'ab'[$SPLIT](/(?:ab)*/)[LENGTH] != 2 ||
'.'[$SPLIT](/(.?)(.?)/)[LENGTH] != 4 ||
'.'[$SPLIT](/()()/)[LENGTH] > 1 ||
''[$SPLIT](/.?/)[LENGTH]
) {
// based on es5-shim implementation, need to rework it
internalSplit = function (separator, limit) {
var string = String(this);
if (separator === undefined && limit === 0) return [];
// If `separator` is not a regex, use native split
if (!isRegExp(separator)) return $split.call(string, separator, limit);
var output = [];
var flags = (separator.ignoreCase ? 'i' : '') +
(separator.multiline ? 'm' : '') +
(separator.unicode ? 'u' : '') +
(separator.sticky ? 'y' : '');
var lastLastIndex = 0;
var splitLimit = limit === undefined ? MAX_UINT32 : limit >>> 0;
// Make `global` and avoid `lastIndex` issues by working with a copy
var separatorCopy = new RegExp(separator.source, flags + 'g');
var match, lastIndex, lastLength;
while (match = regexpExec.call(separatorCopy, string)) {
lastIndex = separatorCopy[LAST_INDEX];
if (lastIndex > lastLastIndex) {
output.push(string.slice(lastLastIndex, match.index));
if (match[LENGTH] > 1 && match.index < string[LENGTH]) $push.apply(output, match.slice(1));
lastLength = match[0][LENGTH];
lastLastIndex = lastIndex;
if (output[LENGTH] >= splitLimit) break;
}
if (separatorCopy[LAST_INDEX] === match.index) separatorCopy[LAST_INDEX]++; // Avoid an infinite loop
}
if (lastLastIndex === string[LENGTH]) {
if (lastLength || !separatorCopy.test('')) output.push('');
} else output.push(string.slice(lastLastIndex));
return output[LENGTH] > splitLimit ? output.slice(0, splitLimit) : output;
};
// Chakra, V8
} else if ('0'[$SPLIT](undefined, 0)[LENGTH]) {
internalSplit = function (separator, limit) {
return separator === undefined && limit === 0 ? [] : $split.call(this, separator, limit);
};
} else {
internalSplit = $split;
}
return [
// `String.prototype.split` method
// https://tc39.github.io/ecma262/#sec-string.prototype.split
function split(separator, limit) {
var O = defined(this);
var splitter = separator == undefined ? undefined : separator[SPLIT];
return splitter !== undefined
? splitter.call(separator, O, limit)
: internalSplit.call(String(O), separator, limit);
},
// `RegExp.prototype[@@split]` method
// https://tc39.github.io/ecma262/#sec-regexp.prototype-@@split
//
// NOTE: This cannot be properly polyfilled in engines that don't support
// the 'y' flag.
function (regexp, limit) {
var res = maybeCallNative(internalSplit, regexp, this, limit, internalSplit !== $split);
if (res.done) return res.value;
var rx = anObject(regexp);
var S = String(this);
var C = speciesConstructor(rx, RegExp);
var unicodeMatching = rx.unicode;
var flags = (rx.ignoreCase ? 'i' : '') +
(rx.multiline ? 'm' : '') +
(rx.unicode ? 'u' : '') +
(SUPPORTS_Y ? 'y' : 'g');
// ^(? + rx + ) is needed, in combination with some S slicing, to
// simulate the 'y' flag.
var splitter = new C(SUPPORTS_Y ? rx : '^(?:' + rx.source + ')', flags);
var lim = limit === undefined ? MAX_UINT32 : limit >>> 0;
if (lim === 0) return [];
if (S.length === 0) return callRegExpExec(splitter, S) === null ? [S] : [];
var p = 0;
var q = 0;
var A = [];
while (q < S.length) {
splitter.lastIndex = SUPPORTS_Y ? q : 0;
var z = callRegExpExec(splitter, SUPPORTS_Y ? S : S.slice(q));
var e;
if (
z === null ||
(e = $min(toLength(splitter.lastIndex + (SUPPORTS_Y ? 0 : q)), S.length)) === p
) {
q = advanceStringIndex(S, q, unicodeMatching);
} else {
A.push(S.slice(p, q));
if (A.length === lim) return A;
for (var i = 1; i <= z.length - 1; i++) {
A.push(z[i]);
if (A.length === lim) return A;
}
q = p = e;
}
}
A.push(S.slice(p));
return A;
}
];
});
/***/ }),
/***/ "294c":
/***/ (function(module, exports) {
module.exports = function (exec) {
try {
return !!exec();
} catch (e) {
return true;
}
};
/***/ }),
/***/ "2aba":
/***/ (function(module, exports, __webpack_require__) {
var global = __webpack_require__("7726");
var hide = __webpack_require__("32e9");
var has = __webpack_require__("69a8");
var SRC = __webpack_require__("ca5a")('src');
var $toString = __webpack_require__("fa5b");
var TO_STRING = 'toString';
var TPL = ('' + $toString).split(TO_STRING);
__webpack_require__("8378").inspectSource = function (it) {
return $toString.call(it);
};
(module.exports = function (O, key, val, safe) {
var isFunction = typeof val == 'function';
if (isFunction) has(val, 'name') || hide(val, 'name', key);
if (O[key] === val) return;
if (isFunction) has(val, SRC) || hide(val, SRC, O[key] ? '' + O[key] : TPL.join(String(key)));
if (O === global) {
O[key] = val;
} else if (!safe) {
delete O[key];
hide(O, key, val);
} else if (O[key]) {
O[key] = val;
} else {
hide(O, key, val);
}
// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative
})(Function.prototype, TO_STRING, function toString() {
return typeof this == 'function' && this[SRC] || $toString.call(this);
});
/***/ }),
/***/ "2aeb":
/***/ (function(module, exports, __webpack_require__) {
// 19.1.2.2 / 15.2.3.5 Object.create(O [, Properties])
var anObject = __webpack_require__("cb7c");
var dPs = __webpack_require__("1495");
var enumBugKeys = __webpack_require__("e11e");
var IE_PROTO = __webpack_require__("613b")('IE_PROTO');
var Empty = function () { /* empty */ };
var PROTOTYPE = 'prototype';
// Create object with fake `null` prototype: use iframe Object with cleared prototype
var createDict = function () {
// Thrash, waste and sodomy: IE GC bug
var iframe = __webpack_require__("230e")('iframe');
var i = enumBugKeys.length;
var lt = '<';
var gt = '>';
var iframeDocument;
iframe.style.display = 'none';
__webpack_require__("fab2").appendChild(iframe);
iframe.src = 'javascript:'; // eslint-disable-line no-script-url
// createDict = iframe.contentWindow.Object;
// html.removeChild(iframe);
iframeDocument = iframe.contentWindow.document;
iframeDocument.open();
iframeDocument.write(lt + 'script' + gt + 'document.F=Object' + lt + '/script' + gt);
iframeDocument.close();
createDict = iframeDocument.F;
while (i--) delete createDict[PROTOTYPE][enumBugKeys[i]];
return createDict();
};
module.exports = Object.create || function create(O, Properties) {
var result;
if (O !== null) {
Empty[PROTOTYPE] = anObject(O);
result = new Empty();
Empty[PROTOTYPE] = null;
// add "__proto__" for Object.getPrototypeOf polyfill
result[IE_PROTO] = O;
} else result = createDict();
return Properties === undefined ? result : dPs(result, Properties);
};
/***/ }),
/***/ "2b4c":
/***/ (function(module, exports, __webpack_require__) {
var store = __webpack_require__("5537")('wks');
var uid = __webpack_require__("ca5a");
var Symbol = __webpack_require__("7726").Symbol;
var USE_SYMBOL = typeof Symbol == 'function';
var $exports = module.exports = function (name) {
return store[name] || (store[name] =
USE_SYMBOL && Symbol[name] || (USE_SYMBOL ? Symbol : uid)('Symbol.' + name));
};
$exports.store = store;
/***/ }),
/***/ "2d00":
/***/ (function(module, exports) {
module.exports = false;
/***/ }),
/***/ "2d95":
/***/ (function(module, exports) {
var toString = {}.toString;
module.exports = function (it) {
return toString.call(it).slice(8, -1);
};
/***/ }),
/***/ "2d97":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_row_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("49e5");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_row_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_row_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_row_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "2fdb":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
// 21.1.3.7 String.prototype.includes(searchString, position = 0)
var $export = __webpack_require__("5ca1");
var context = __webpack_require__("d2c8");
var INCLUDES = 'includes';
$export($export.P + $export.F * __webpack_require__("5147")(INCLUDES), 'String', {
includes: function includes(searchString /* , position = 0 */) {
return !!~context(this, searchString, INCLUDES)
.indexOf(searchString, arguments.length > 1 ? arguments[1] : undefined);
}
});
/***/ }),
/***/ "30f1":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var LIBRARY = __webpack_require__("b8e3");
var $export = __webpack_require__("63b6");
var redefine = __webpack_require__("9138");
var hide = __webpack_require__("35e8");
var Iterators = __webpack_require__("481b");
var $iterCreate = __webpack_require__("8f60");
var setToStringTag = __webpack_require__("45f2");
var getPrototypeOf = __webpack_require__("53e2");
var ITERATOR = __webpack_require__("5168")('iterator');
var BUGGY = !([].keys && 'next' in [].keys()); // Safari has buggy iterators w/o `next`
var FF_ITERATOR = '@@iterator';
var KEYS = 'keys';
var VALUES = 'values';
var returnThis = function () { return this; };
module.exports = function (Base, NAME, Constructor, next, DEFAULT, IS_SET, FORCED) {
$iterCreate(Constructor, NAME, next);
var getMethod = function (kind) {
if (!BUGGY && kind in proto) return proto[kind];
switch (kind) {
case KEYS: return function keys() { return new Constructor(this, kind); };
case VALUES: return function values() { return new Constructor(this, kind); };
} return function entries() { return new Constructor(this, kind); };
};
var TAG = NAME + ' Iterator';
var DEF_VALUES = DEFAULT == VALUES;
var VALUES_BUG = false;
var proto = Base.prototype;
var $native = proto[ITERATOR] || proto[FF_ITERATOR] || DEFAULT && proto[DEFAULT];
var $default = $native || getMethod(DEFAULT);
var $entries = DEFAULT ? !DEF_VALUES ? $default : getMethod('entries') : undefined;
var $anyNative = NAME == 'Array' ? proto.entries || $native : $native;
var methods, key, IteratorPrototype;
// Fix native
if ($anyNative) {
IteratorPrototype = getPrototypeOf($anyNative.call(new Base()));
if (IteratorPrototype !== Object.prototype && IteratorPrototype.next) {
// Set @@toStringTag to native iterators
setToStringTag(IteratorPrototype, TAG, true);
// fix for some old engines
if (!LIBRARY && typeof IteratorPrototype[ITERATOR] != 'function') hide(IteratorPrototype, ITERATOR, returnThis);
}
}
// fix Array#{values, @@iterator}.name in V8 / FF
if (DEF_VALUES && $native && $native.name !== VALUES) {
VALUES_BUG = true;
$default = function values() { return $native.call(this); };
}
// Define iterator
if ((!LIBRARY || FORCED) && (BUGGY || VALUES_BUG || !proto[ITERATOR])) {
hide(proto, ITERATOR, $default);
}
// Plug for library
Iterators[NAME] = $default;
Iterators[TAG] = returnThis;
if (DEFAULT) {
methods = {
values: DEF_VALUES ? $default : getMethod(VALUES),
keys: IS_SET ? $default : getMethod(KEYS),
entries: $entries
};
if (FORCED) for (key in methods) {
if (!(key in proto)) redefine(proto, key, methods[key]);
} else $export($export.P + $export.F * (BUGGY || VALUES_BUG), NAME, methods);
}
return methods;
};
/***/ }),
/***/ "31f4":
/***/ (function(module, exports) {
// fast apply, http://jsperf.lnkit.com/fast-apply/5
module.exports = function (fn, args, that) {
var un = that === undefined;
switch (args.length) {
case 0: return un ? fn()
: fn.call(that);
case 1: return un ? fn(args[0])
: fn.call(that, args[0]);
case 2: return un ? fn(args[0], args[1])
: fn.call(that, args[0], args[1]);
case 3: return un ? fn(args[0], args[1], args[2])
: fn.call(that, args[0], args[1], args[2]);
case 4: return un ? fn(args[0], args[1], args[2], args[3])
: fn.call(that, args[0], args[1], args[2], args[3]);
} return fn.apply(that, args);
};
/***/ }),
/***/ "32a6":
/***/ (function(module, exports, __webpack_require__) {
// 19.1.2.14 Object.keys(O)
var toObject = __webpack_require__("241e");
var $keys = __webpack_require__("c3a1");
__webpack_require__("ce7e")('keys', function () {
return function keys(it) {
return $keys(toObject(it));
};
});
/***/ }),
/***/ "32e9":
/***/ (function(module, exports, __webpack_require__) {
var dP = __webpack_require__("86cc");
var createDesc = __webpack_require__("4630");
module.exports = __webpack_require__("9e1e") ? function (object, key, value) {
return dP.f(object, key, createDesc(1, value));
} : function (object, key, value) {
object[key] = value;
return object;
};
/***/ }),
/***/ "32fc":
/***/ (function(module, exports, __webpack_require__) {
var document = __webpack_require__("e53d").document;
module.exports = document && document.documentElement;
/***/ }),
/***/ "335c":
/***/ (function(module, exports, __webpack_require__) {
// fallback for non-array-like ES3 and non-enumerable old V8 strings
var cof = __webpack_require__("6b4c");
// eslint-disable-next-line no-prototype-builtins
module.exports = Object('z').propertyIsEnumerable(0) ? Object : function (it) {
return cof(it) == 'String' ? it.split('') : Object(it);
};
/***/ }),
/***/ "33a4":
/***/ (function(module, exports, __webpack_require__) {
// check on default Array iterator
var Iterators = __webpack_require__("84f2");
var ITERATOR = __webpack_require__("2b4c")('iterator');
var ArrayProto = Array.prototype;
module.exports = function (it) {
return it !== undefined && (Iterators.Array === it || ArrayProto[ITERATOR] === it);
};
/***/ }),
/***/ "34bc":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/parse-float.js
var parse_float = __webpack_require__("59ad");
var parse_float_default = /*#__PURE__*/__webpack_require__.n(parse_float);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.string.fixed.js
var es6_string_fixed = __webpack_require__("d263");
// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/object/assign.js
var object_assign = __webpack_require__("5176");
var assign_default = /*#__PURE__*/__webpack_require__.n(object_assign);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.number.constructor.js
var es6_number_constructor = __webpack_require__("c5f6");
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.regexp.match.js
var es6_regexp_match = __webpack_require__("4917");
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.regexp.split.js
var es6_regexp_split = __webpack_require__("28a5");
// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/parse-int.js
var parse_int = __webpack_require__("e814");
var parse_int_default = /*#__PURE__*/__webpack_require__.n(parse_int);
// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/array/is-array.js
var is_array = __webpack_require__("a745");
var is_array_default = /*#__PURE__*/__webpack_require__.n(is_array);
// CONCATENATED MODULE: ./node_modules/@babel/runtime-corejs2/helpers/esm/arrayWithoutHoles.js
function _arrayWithoutHoles(arr) {
if (is_array_default()(arr)) {
for (var i = 0, arr2 = new Array(arr.length); i < arr.length; i++) {
arr2[i] = arr[i];
}
return arr2;
}
}
// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/array/from.js
var from = __webpack_require__("774e");
var from_default = /*#__PURE__*/__webpack_require__.n(from);
// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/is-iterable.js
var is_iterable = __webpack_require__("c8bb");
var is_iterable_default = /*#__PURE__*/__webpack_require__.n(is_iterable);
// CONCATENATED MODULE: ./node_modules/@babel/runtime-corejs2/helpers/esm/iterableToArray.js
function _iterableToArray(iter) {
if (is_iterable_default()(Object(iter)) || Object.prototype.toString.call(iter) === "[object Arguments]") return from_default()(iter);
}
// CONCATENATED MODULE: ./node_modules/@babel/runtime-corejs2/helpers/esm/nonIterableSpread.js
function _nonIterableSpread() {
throw new TypeError("Invalid attempt to spread non-iterable instance");
}
// CONCATENATED MODULE: ./node_modules/@babel/runtime-corejs2/helpers/esm/toConsumableArray.js
function _toConsumableArray(arr) {
return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _nonIterableSpread();
}
// EXTERNAL MODULE: ./node_modules/core-js/modules/es7.array.includes.js
var es7_array_includes = __webpack_require__("6762");
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.string.includes.js
var es6_string_includes = __webpack_require__("2fdb");
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.dom.iterable.js
var web_dom_iterable = __webpack_require__("ac6a");
// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/object/keys.js
var object_keys = __webpack_require__("a4bb");
var keys_default = /*#__PURE__*/__webpack_require__.n(object_keys);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.function.name.js
var es6_function_name = __webpack_require__("7f7f");
// EXTERNAL MODULE: ./src/package/libs/parse.js
var parse = __webpack_require__("5f60");
// EXTERNAL MODULE: ./src/package/libs/global.js
var global = __webpack_require__("394e");
// EXTERNAL MODULE: ./src/package/libs/constant.js
var constant = __webpack_require__("890a");
// EXTERNAL MODULE: ./src/package/libs/utils.js
var utils = __webpack_require__("4513");
// CONCATENATED MODULE: ./src/package/libs/schema-rules.js
var schemaRules = {
isFunc: function isFunc(value) {
return utils["a" /* default */].isFunc(value);
},
isEs: function isEs(value) {
return parse["a" /* default */].isEsScript(value);
},
isStr: function isStr(value) {
return utils["a" /* default */].isStr(value);
},
/**
* [数值范围]
* @param {[String]} value [description]
* @return {Boolean} [description]
*/
// range: function(value, min, max, isInt) {
// if (utils.isNum(value)) {
// if (isInt) {
// return schemaRules.isInt(value, min, max);
// } else {
// var tmpMin = min;
// var tmpMax = max;
// if (utils.isNum(min) && utils.isNum(min) && min > max) {
// tmpMin = max;
// tmpMax = min;
// }
// if (utils.isNum(tmpMin) && value < tmpMin) {
// return false;
// } else if (utils.isNum(tmpMax) && value > tmpMax) {
// return false;
// } else {
// return true;
// }
// }
// } else {
// return false;
// }
// },
/**
* [isInt 是否整数]
* @param {[Number or String]} value [description]
* @param {[Number]} min [最小值(包含此值),因为这个很常用, 不写就不比较]
* @return {Boolean} [description]
*/
isInt: function isInt(value, min, max) {
var tmpMin = min;
var tmpMax = max;
if (utils["a" /* default */].isNum(min) && utils["a" /* default */].isNum(min) && min > max) {
tmpMin = max;
tmpMax = min;
}
if (utils["a" /* default */].isNum(value) && /^\d+$/.test(value + "")) {
if (utils["a" /* default */].isNum(tmpMin) && value < tmpMin) {
return false;
} else if (utils["a" /* default */].isNum(tmpMax) && value > tmpMax) {
return false;
} else {
return true;
}
} else {
return false;
}
}
};
/* harmony default export */ var schema_rules = (schemaRules);
// EXTERNAL MODULE: ./src/package/libs/form-utils.js
var form_utils = __webpack_require__("3be1");
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/help.vue?vue&type=template&id=289081a2&
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"es-help-box"},[(_vm.href)?_c('a',{staticClass:"help-btn",attrs:{"href":_vm.href,"target":"_blank"}},[_c('i',{ref:"icon",staticClass:"es-help-icon",on:{"mouseenter":_vm.enter,"mouseleave":_vm.leave}},[_vm._v("i")])]):_c('i',{ref:"icon",staticClass:"es-help-icon",on:{"mouseenter":_vm.enter,"mouseleave":_vm.leave}},[_vm._v("i")]),_c('transition',{attrs:{"name":"es-help-fade","mode":"out-in","appear":""},on:{"after-leave":_vm.popAnimateLeave}},[_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.showPop && _vm.content),expression:"showPop && content"}],ref:"pop",staticClass:"es-help-tip-box",style:({
left: _vm.popPosition.left + 'px',
top: _vm.popPosition.top + 'px',
maxWidth: _vm.maxWidth + 'px',
zIndex: _vm.popPosition.zindex + ''
}),on:{"mouseenter":_vm.popEnter,"mouseleave":_vm.popLeave}},[_c('div',{staticClass:"es-content-box",domProps:{"innerHTML":_vm._s(_vm.content)}}),(_vm.popArrow.direction)?_c('div',{class:'help-arrow-' + _vm.popArrow.direction,style:({ left: _vm.popArrow.left + 'px', top: _vm.popArrow.top + 'px' })}):_vm._e()])])],1)}
var staticRenderFns = []
// CONCATENATED MODULE: ./src/package/components/help.vue?vue&type=template&id=289081a2&
// EXTERNAL MODULE: ./src/package/libs/pop-utils.js
var pop_utils = __webpack_require__("dedd");
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/help.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
/* harmony default export */ var helpvue_type_script_lang_js_ = ({
/* ====================== 生命周期 ====================== */
created: function created() {
var _this = this;
this.$data.scrollWinHandler = function () {
_this.adjustPop();
};
},
/* ====================== 数据绑定 ====================== */
data: function data() {
return {
showPop: false,
scrollWinHandler: null,
popDom: null,
popLeaveDelay: 200,
// pop延迟消失的时间(ms)
popTimerId: null,
popPosition: {
left: 0,
top: 0,
zindex: 1
},
popArrow: {
direction: "",
left: 0,
top: 0
},
popInfo: {
popBorderRadius: 4,
viewSpace: 2,
// 距离判断边预留的空间
popArrowWH: 6,
// 箭头的宽度和高度
betweenSpace: 3 // pop与icon的空间
}
};
},
props: {
maxWidth: {
type: Number,
required: false,
default: 300
},
content: {
// 内容区
type: String,
required: false,
default: ""
},
href: {
// 若有些值,说是图标是一条链接
type: String,
required: false,
default: ""
},
placement: {
// pop的位置,当设置这个时,会优先考虑这个方向
type: String,
required: false,
default: "" //value: top right bottom left
}
},
watch: {},
/* ====================== 事件处理 ====================== */
methods: {
enter: function enter() {
var _this2 = this;
if (this.content) {
if (!this.$data.showPop) {
// 正常进来
this.$data.showPop = true;
this.addPopDom();
this.setScrollListen();
this.$data.popPosition.zindex = pop_utils["a" /* default */].getMaxZIndex() + 1;
this.$nextTick(function () {
_this2.adjustPop();
});
} else {
// 从pop进入来
this.cancelPopTimer();
}
}
},
leave: function leave() {
if (this.content) {
this.setCloseTimer();
}
},
popEnter: function popEnter() {
this.cancelPopTimer();
},
popLeave: function popLeave() {
this.setCloseTimer();
},
popAnimateLeave: function popAnimateLeave() {
// console.log("popAnimateLeave...");
this.cancelScrollListen();
this.$data.popPosition = {
//这样放在最左,可以保持其长度最大化
left: 0,
top: 0
};
},
addPopDom: function addPopDom() {
if (!this.$data.popDom) {
this.$data.popDom = this.$refs.pop;
document.body.appendChild(this.$data.popDom);
}
},
removePopDom: function removePopDom() {
if (this.$data.popDom) {
document.body.removeChild(this.$data.popDom);
this.$data.popDom = null;
}
},
setScrollListen: function setScrollListen() {
window.addEventListener("scroll", this.$data.scrollWinHandler, true);
},
cancelScrollListen: function cancelScrollListen() {
window.removeEventListener("scroll", this.$data.scrollWinHandler, true);
},
closePop: function closePop() {
this.cancelPopTimer();
this.$data.showPop = false;
},
setCloseTimer: function setCloseTimer() {
var _this3 = this;
this.$data.popTimerId = setTimeout(function () {
_this3.$data.popTimerId = null;
_this3.closePop();
}, this.$data.popLeaveDelay);
},
cancelPopTimer: function cancelPopTimer() {
if (this.$data.popTimerId !== null) {
clearTimeout(this.$data.popTimerId);
this.$data.popTimerId = null;
}
},
adjustPop: function adjustPop() {
var pop = this.$refs["pop"];
var icon = this.$refs["icon"];
var popRect = pop.getBoundingClientRect();
var iconRect = icon.getBoundingClientRect();
var uiInfo = pop_utils["a" /* default */].getPopUiInfo(popRect, iconRect, this.$data.popInfo, this.placement);
if (uiInfo) {
this.$data.popPosition = {
left: uiInfo.popLeft,
top: uiInfo.popTop
};
this.$data.popArrow = {
direction: uiInfo.arrowDirection,
left: uiInfo.arrowLeft,
top: uiInfo.arrowTop
};
} else {
this.closePop();
}
}
},
destroyed: function destroyed() {
if (this.$data.scrollWinHandler) {
this.cancelScrollListen();
}
this.$data.scrollWinHandler = null;
this.removePopDom();
}
});
// CONCATENATED MODULE: ./src/package/components/help.vue?vue&type=script&lang=js&
/* harmony default export */ var components_helpvue_type_script_lang_js_ = (helpvue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/components/help.vue?vue&type=style&index=0&lang=scss&
var helpvue_type_style_index_0_lang_scss_ = __webpack_require__("d0e9");
// EXTERNAL MODULE: ./node_modules/vue-loader/lib/runtime/componentNormalizer.js
var componentNormalizer = __webpack_require__("2877");
// CONCATENATED MODULE: ./src/package/components/help.vue
/* normalize component */
var component = Object(componentNormalizer["a" /* default */])(
components_helpvue_type_script_lang_js_,
render,
staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var components_help = (component.exports);
// EXTERNAL MODULE: ./src/package/libs/component-utils.js + 1 modules
var component_utils = __webpack_require__("45ac");
// CONCATENATED MODULE: ./src/package/libs/schema-utils.js
/**
* schema-utils.js
*
* Copyright (c) 2019 chengaohe All rights reserved.
*
* 用来标准化原始的表单schema
*
*/
// import sysExtRules from "./rules";
// 解析组件的方法
var m_currentFormId = undefined; // 应用于completeSchema,记录当前的解析是在哪个表单中
var schemaUtils = {
/**
* 用于检查rawSchema是否符合要求
* @param {*} rawSchema
*/
check: function check(rawSchema) {
try {
this.completeSchema(rawSchema);
} catch (e) {
return e;
}
return true;
},
/**
* 解析计划表schema的入口:把原始的schema转化为标准的schema
* 解析原则:
* 对于一个对象{}来说
* type === 'space'时,说明是占位空间,即使有component或properties, 也认为是占位空间,且解析时会把两个属性去掉
* else if :判断是否有properties且合法,即使有component也会去掉此属性
* else: 是component,即使没有component也会用系统的默认值
* 结论 >> 最后的输出是:
* type === 'space'、component、properties只有一个会输出;也是就if (item.layout.name === 'space')、if (item.component)、if (item.properties)中,只有一个为真
* @param {*} schema 原始的计划表
* @param {*} esFormId 哪个esFormId(应用于有jsx或是函数的组件)
*/
completeSchema: function completeSchema(schema, esFormId) {
// const constant.ARRAY_TABLE = "array-table";
m_currentFormId = esFormId;
var autoMatch;
if (utils["a" /* default */].isObj(schema)) {
var tmpSchema = utils["a" /* default */].deepCopy(schema);
var rootObj = tmpSchema;
var rootActions;
if (!utils["a" /* default */].isObj(tmpSchema.properties)) {
rootObj = {};
rootObj.title = false;
rootObj.layout = false;
rootObj.properties = tmpSchema; // 根节点有效的属性
autoMatch = false;
rootActions = null;
} else {
// 根节点有效的属性
autoMatch = rootObj.autoMatch === true ? true : false;
rootActions = Object(component_utils["c" /* parseActions */])(rootObj.actions, "根");
} // 基础设置,最外层的一些东西固定
rootObj.array = false; // 顶级是不支持数组的
rootObj.hidden = false; // 最外层也不支持隐藏
rootObj.isTmp = false; // 最外层也不支持临时值
rootObj.col = constant["a" /* default */].UI_MAX_COL; // 最外层保持最大
rootObj.label = {
text: false,
__rawText: false
}; // 顶级是不支持label
rootObj = this.__parseProp(rootObj, 1, "根", this.__getGlobalInheritObj(), // 取自global
""); //根节点有效的属性
rootObj.autoMatch = autoMatch;
rootObj.actions = rootActions;
this.__checkForTile(rootObj);
m_currentFormId = undefined; // 任务完成
return rootObj;
} else {
m_currentFormId = undefined;
throw "根schema是一个Object类型";
}
},
/**
* 解析项
*/
__parseProp: function __parseProp(propItem, curLevel, parentKey, inheritObj, myPathKey) {
if (utils["a" /* default */].isStr(propItem)) {
propItem = {
label: propItem
};
} else if (!utils["a" /* default */].isObj(propItem)) {
throw "第" + curLevel + "层的属性值(" + parentKey + ")必须是一个字符串或Object类型";
}
var newPropItem, propKeys, isArray, isNormalTabs;
if (this.__isSpaceItem(propItem)) {
// 占位空间 为什么用恒等,因为会严格判断是否是true/false, 同时也严格要求用户用true/false, 不要用1/0
propKeys = this.__getPropKeys("none");
newPropItem = this.__filterKeys(propItem, propKeys, inheritObj, myPathKey);
newPropItem.__info = {
pathKey: myPathKey,
idxChain: "",
index: -1
};
} else if (this.__isPropItem(propItem)) {
if (!this.__existEntityItem(propItem)) {
throw "属性" + parentKey + "没有具体的子节点(properties全为空)";
} // 是否数组(优先级最高)
isArray = this.__isArray(propItem.array);
propKeys = this.__getPropKeys("properties");
newPropItem = this.__filterKeys(propItem, propKeys, inheritObj, myPathKey);
var nextInheritObj = newPropItem.nextInherit;
newPropItem.nextInherit = null;
delete newPropItem.nextInherit;
if (isArray) {
if (utils["a" /* default */].isUndef(newPropItem.array.rowSpace)) {
// 当没有设置时,则取上一级的rowSpace
newPropItem.array.rowSpace = newPropItem.rowSpace;
}
} // 判断ui, 因为是数组的话,有些属性可能有会(ui.rowHeight可能很用到)
var newUi = newPropItem.ui ? newPropItem.ui : {
showBody: true
};
newUi.rowSpace = nextInheritObj.rowSpace;
newUi.rowHeight = nextInheritObj.rowHeight;
newPropItem.ui = newUi;
isNormalTabs = newPropItem.layout && newPropItem.layout.name === constant["a" /* default */].LAYOUT_TABS;
if (isArray && newPropItem.array.name == constant["a" /* default */].ARRAY_TABLE && isNormalTabs) {
// 数组是以table形式布局,子节点无法进行tabs布局
newPropItem.layout = false;
isNormalTabs = false; // 强制置为非tabs
console.warn("第" + curLevel + "层(" + parentKey + ")为table数组且子节点为tabs, 子节点为tabs将失效");
} //有下一级
if (propItem.component) {
//提示警告
parentKey = parentKey ? parentKey : "根";
parentKey += "节点";
console.warn("第" + curLevel + "层(" + parentKey + ")中同时存在properties和component, component将失效");
}
if (newPropItem.title) {
newPropItem.title.__level = curLevel; //用于字号
} // 记录节点的修改,用于事件
newPropItem.__info = {
pathKey: myPathKey,
idxChain: "",
index: -1
};
if (isNormalTabs) {
newPropItem.__tabsIndex = false;
} //递归,取出下一级的数据
var newProperties = {};
var hasChildRef = false;
for (var key in propItem.properties) {
if (!this.__isRightKey(key)) {
console.warn("属性" + key + "存在危险字符,会导致程序出错");
}
var nextRawPropItem = propItem.properties[key];
if (this.__isIngnoreItem(nextRawPropItem)) {
console.log("属性" + key + "为null/undefined/false时,将不设置");
} else {
var isSpaceItem = this.__isSpaceItem(nextRawPropItem);
if (isSpaceItem && newPropItem.array && newPropItem.array.name == constant["a" /* default */].ARRAY_TABLE) {
// 当父节点是table数组时,占位空间过滤掉
console.warn("属性" + key + "不符合" + constant["a" /* default */].ARRAY_TABLE + "布局的要求(properties存在占位空间), 将失效");
continue;
} else if (isSpaceItem && isNormalTabs) {
console.warn("属性" + key + "不符合" + constant["a" /* default */].LAYOUT_TABS + "布局的要求(properties存在占位空间), 将失效");
continue;
} else {// 符合要求了,进行下一步解析
}
var nextPropItem = this.__parseProp(nextRawPropItem, curLevel + 1, key, nextInheritObj, myPathKey ? myPathKey + "." + key : key);
if (isNormalTabs) {
// 是普通tabs
nextPropItem.__hasError = false;
}
if (isNormalTabs || newPropItem.array && newPropItem.array.name == constant["a" /* default */].ARRAY_TABLE) {
if (!nextPropItem.label) {
console.warn("当属性(" + parentKey + ")为" + constant["a" /* default */].LAYOUT_TABS + "或" + constant["a" /* default */].ARRAY_TABLE + "时,下一级的label必须存在, 否则用各自的key代表头部");
}
}
if (isNormalTabs || newPropItem.array && newPropItem.array.name == constant["a" /* default */].ARRAY_TABS) {
newPropItem.__tabsIndex = false;
newPropItem.__hasError = false; // 用来做复制
}
newProperties[key] = nextPropItem;
if (nextPropItem.__hasRef) {
hasChildRef = true;
}
}
}
if (keys_default()(newProperties).length <= 0) {
throw "properties不能为空,或其属性全部为空(null/undefined/false)";
}
newPropItem.properties = newProperties;
if (hasChildRef) {
newPropItem.__hasRef = hasChildRef;
} // 当是列表数组时,重新计算列宽,使其点100%
if (newPropItem.array && newPropItem.array.name == constant["a" /* default */].ARRAY_TABLE) {
//整理一下ref, 同一级别的只留最后一下
this.__updateTableCol(newPropItem);
} //整理一下ref, 同一级别的只留最后一下
this.__uniqueRef(newPropItem);
if (isNormalTabs || newPropItem.array && newPropItem.array.name == constant["a" /* default */].ARRAY_TABLE) {//当是tabs or constant.ARRAY_TABLE时,若是分组失效
// continue; //是占位空间,去掉
} else {
//直接改变newPropItem的值,设置分组情况
this.__reinitGroup(newPropItem);
}
if (newPropItem.array) {
//数组类型,可增删
//有值且合规范
if (!newPropItem.array.value) {
newPropItem.array.value = [];
} else if (!utils["a" /* default */].isArr(newPropItem.array.value)) {
throw "array的值必须是数组或不写";
}
newPropItem.__propSchemaList = []; // console.log("newPropItem.array.value", newPropItem.array.value);
form_utils["a" /* default */].setValue(newPropItem, newPropItem.array.value); // console.log("end ...");
delete newPropItem.array.value; //任务完成
} // 判断newPropItem下一级组件是否存在自定义长度
var nextNewproperties = newPropItem.properties;
if (this.__existCustomWidth(nextNewproperties)) {
newPropItem.__hasCustomWidth = true;
for (var nextKey in nextNewproperties) {
if ("rowSpace" in nextNewproperties[nextKey]) {
nextNewproperties[nextKey].rowSpace = newPropItem.ui.rowSpace;
nextNewproperties[nextKey].__rawRowSpace = newPropItem.ui.rowSpace;
}
}
}
} else {
// 是组件了
propKeys = this.__getPropKeys("component");
newPropItem = this.__filterKeys(propItem, propKeys, inheritObj, myPathKey);
if (this.__isTabsItem(propItem)) {
newPropItem.layout = false;
console.warn("当属性(" + parentKey + ")为叶子节点时," + constant["a" /* default */].LAYOUT_TABS + "将不起作用");
} else {
newPropItem.layout = false;
}
if (newPropItem.format) {
newPropItem.component.value = form_utils["a" /* default */].getFormatValue(newPropItem.format, newPropItem.component.value, true);
}
var eventOn = this.__fetchFormEvent(newPropItem);
newPropItem.component.__emitEvents = eventOn.__emitEvents;
newPropItem.component.__nativeEvents = eventOn.__nativeEvents;
newPropItem.__info = {
pathKey: myPathKey,
idxChain: "",
index: -1
}; // 是否数组(优先级最高)
isArray = this.__isArray(propItem.array);
if (isArray) {
//数组类型,可增删
//有值且合规范
if (!newPropItem.array.value) {
newPropItem.array.value = [];
} else if (!utils["a" /* default */].isArr(newPropItem.array.value)) {
throw "array.value的值必须是数组或不写";
}
if (utils["a" /* default */].isUndef(newPropItem.array.rowSpace)) {
// 当没有设置时,则取上一级的rowSpace
newPropItem.array.rowSpace = newPropItem.rowSpace;
}
if (newPropItem.array.name == constant["a" /* default */].ARRAY_TABS) {
newPropItem.__tabsIndex = false;
newPropItem.__hasError = false; // 用来做复制
}
newPropItem.__propSchemaList = [];
form_utils["a" /* default */].setValue(newPropItem, newPropItem.array.value);
delete newPropItem.array.value; //任务完成
}
}
newPropItem.__rawHidden = parse["a" /* default */].newEsFuncion(newPropItem.hidden);
newPropItem.__creatable = false; // 这个一定要设置要false, 说明初始化时是创建组件,一旦设置成true, 就改不回false
return newPropItem;
},
/**
* 对table数组布局,重新计算长度,使项相加为UI_MAX_COL(24列)
* @param {*} newSchema
*/
__updateTableCol: function __updateTableCol(newSchema) {
if (newSchema.properties) {
var curProp = newSchema.properties;
var nextPropItem, key, newCol;
var total = 0; // 判断是否合法
var isValidCol = true;
for (key in curProp) {
nextPropItem = curProp[key];
if (!utils["a" /* default */].isNum(nextPropItem.col)) {
isValidCol = false; // 存在不合法的长度
console.warn("table数组所有项的长度col只能设置为整数,不能是对象,否则每一项将均分长度;现项(key为" + key + ")设置长度为对象");
break;
}
}
if (!isValidCol) {
for (key in curProp) {
nextPropItem = curProp[key];
nextPropItem.col = constant["a" /* default */].UI_MAX_COL; // 均分
}
}
for (key in curProp) {
nextPropItem = curProp[key];
total += nextPropItem.col;
}
var newTotal = 0;
if (total !== constant["a" /* default */].UI_MAX_COL) {
for (key in curProp) {
nextPropItem = curProp[key];
newCol = Math.round(nextPropItem.col * constant["a" /* default */].UI_MAX_COL / total);
nextPropItem.col = newCol;
newTotal += newCol;
}
}
if (newTotal < constant["a" /* default */].UI_MAX_COL) {
// 不够100%, 补给后面的
curProp[key].col = curProp[key].col + (constant["a" /* default */].UI_MAX_COL - newTotal);
} // 计算转化为头部style
for (key in curProp) {
nextPropItem = curProp[key];
var headStyle = {
width: this.__intToPercent(nextPropItem.col),
padding: newSchema.ui.rowSpace / 2 + "px"
};
nextPropItem.__headStyle = headStyle;
}
}
},
/**
* 去掉同一级别的属性中,有相同的ref,保留最后一个
* @param {*} newSchema 已经整理好的schema
*/
__uniqueRef: function __uniqueRef(newSchema) {
if (newSchema.properties) {
var curProp = newSchema.properties;
var lastPropItem = {};
for (var key in curProp) {
// console.log("key: ", key);
var nextPropItem = curProp[key];
if (nextPropItem.component && nextPropItem.component.ref) {
var nextRef = nextPropItem.component.ref;
if (lastPropItem[nextRef] && nextPropItem.component.ref === lastPropItem[nextRef].component.ref) {
// 存在上一个,删除上一个的ref
var curCom = lastPropItem[nextRef].component; // console.log(curCom.ref);
delete curCom.ref;
}
lastPropItem[nextRef] = nextPropItem; // 我变为上一个,以便下一个使用
}
}
lastPropItem = null;
}
},
__existCustomWidth: function __existCustomWidth(newProperties) {
for (var key in newProperties) {
var nextPropItem = newProperties[key];
if (utils["a" /* default */].isObj(nextPropItem.col)) {
return true;
}
}
return false;
},
/**
* 判断属性是否合法
* @param {*} key
*/
__isRightKey: function __isRightKey(key) {
var illReg = /^[+-]?\d+$/;
if (key.trim() === "") {
throw "表单项的属性名不能为空值";
} else if (illReg.test(key)) {
throw "表单项的属性名不能是数字(如-1, 1, +1)";
}
var illChars = ["[", "]", ".", "{", "}", "(", ")"];
for (var i = 0; i < illChars.length; i++) {
if (key.indexOf(illChars[i]) >= 0) {
throw "表单项的属性名不能出现以下的危险字符:" + illChars.join(" ");
}
}
return true;
},
/**
* 整理出"表单"组件需要监听的外部事件
*/
__fetchFormEvent: function __fetchFormEvent(propItem) {
var emitEvents = [],
nativeEvents = [],
triggerList,
nativeName;
if (propItem.rules) {
var rules = propItem.rules;
var checkList = rules.checks;
if (checkList) {
checkList.forEach(function (checkItem) {
// 有检查
triggerList = checkItem.trigger;
triggerList.forEach(function (triggerItem) {
nativeName = Object(component_utils["b" /* getNativeName */])(triggerItem);
if (nativeName) {
// .native监听
nativeEvents.push(nativeName);
} else {
emitEvents.push(triggerItem);
}
});
});
}
}
if (propItem.isTrim || utils["a" /* default */].isUndef(propItem.isTrim) && global["a" /* default */].trimDoms.includes(propItem.component.name)) {
propItem.isTrim = true;
var componentName = propItem.component.name.toLowerCase ? propItem.component.name.toLowerCase() : propItem.component.name;
var curTrimEvent = constant["a" /* default */].FORM_INPUTS.includes(componentName) ? constant["a" /* default */].INPUT_CHANGE : global["a" /* default */].trimEvent; // 要去掉左右两边的空格,添此触发事件
nativeName = Object(component_utils["b" /* getNativeName */])(curTrimEvent);
if (nativeName) {
// .native监听
nativeEvents.push(nativeName);
} else {
emitEvents.push(curTrimEvent);
}
} // 自定义事件
if (propItem.component && propItem.component.actions) {
var actionInfo = Object(component_utils["a" /* fetchActionEvent */])(propItem.component.actions);
if (actionInfo.__emitEvents) {
emitEvents = emitEvents.concat(actionInfo.__emitEvents);
}
if (actionInfo.__nativeEvents) {
nativeEvents = nativeEvents.concat(actionInfo.__nativeEvents);
}
}
return {
__emitEvents: emitEvents.length ? utils["a" /* default */].unique(emitEvents) : null,
__nativeEvents: nativeEvents.length ? utils["a" /* default */].unique(nativeEvents) : null
};
},
/**
* 根据不同的类型,取出不同的属性
* @param {*} type
*/
__getPropKeys: function __getPropKeys(type) {
var propKeys = [];
switch (type) {
case "component":
propKeys = ["label", "rowHeight", "rowSpace", "labelWidth", "offsetLeft", "offsetRight", "hidden", "format", "hdValue", "colon", "group", // "value",
"isTrim", "help", "desc", "unit", "direction", "col", "rules", "component", "array", "layout", "isTmp"];
break;
case "properties":
propKeys = ["ui", "title", "label", "rowHeight", // "boxRowHeight",
"rowSpace", // "boxRowSpace",
"labelWidth", // "boxLabelWidth",
"nextInherit", // 这个比较特殊,不会对应哪个字段
"offsetLeft", "offsetRight", "hidden", "hdValue", "colon", "help", "desc", // "unit",
"direction", "col", "array", "layout", "isTmp"];
break;
default:
//占位空间
propKeys = ["col", "group", "hidden", "layout"];
break;
}
return propKeys;
},
/**
* 取出schema的属性的判断信息,用来判断是否合法或设置默认值
*/
__getNormalInfo: function __getNormalInfo(key) {
var keyInfos = [// {
// key: "value",
// enums: [],
// defaultValue: undefined
// },
{
key: "hidden",
enums: [true, false],
isOr: true,
// filters里面的关系,默认为false
filters: ["isEs", "isFunc"],
// 取schema-rules规则过滤
defaultValue: false
}, {
key: "hdValue",
enums: [],
defaultValue: undefined
}, {
key: "colon",
enums: [true, false],
defaultValue: global["a" /* default */].colon
}, {
key: "group",
enums: [],
filters: ["isStr"],
defaultValue: false
}, // {
// key: "col",
// enums: [],
// filters: [
// {
// name: "isInt",
// params: [1, constant.UI_MAX_COL]
// }
// ],
// defaultValue: constant.UI_MAX_COL
// },
{
key: "direction",
enums: ["h", "v"],
defaultValue: global["a" /* default */].direction
}, {
key: "isTrim",
enums: [true, false],
defaultValue: undefined // undefined代表是否删除空格取自于全局设置
}, {
key: "rowHeight",
enums: [],
filters: [{
name: "isInt",
params: [0]
}],
defaultValue: global["a" /* default */].boxRowHeight
}, {
key: "rowSpace",
enums: [],
filters: [{
name: "isInt",
params: [0]
}],
defaultValue: global["a" /* default */].boxRowSpace
}, {
key: "labelWidth",
enums: [],
filters: [{
name: "isInt",
params: [0]
}],
defaultValue: global["a" /* default */].boxLabelWidth
}, {
key: "offsetLeft",
enums: [],
filters: [{
name: "isInt",
params: [0]
}],
defaultValue: 0
}, {
key: "offsetRight",
enums: [],
filters: [{
name: "isInt",
params: [0]
}],
defaultValue: 0
}, {
key: "isTmp",
enums: [true, false],
defaultValue: false
}];
for (var i = 0; i < keyInfos.length; i++) {
if (keyInfos[i].key === key) {
return keyInfos[i];
}
}
return false;
},
/**
* 统一解析普通属性
* @param {*} propItem propItem or propItem.ui
* @param {*} keyInfo
* @param {*} inheritObj
*/
__parseNormalKey: function __parseNormalKey(propItem, keyInfo, inheritObj) {
var value = propItem[keyInfo.key];
var tmpDefaultValue = utils["a" /* default */].isUndef(inheritObj[keyInfo.key]) ? keyInfo.defaultValue : inheritObj[keyInfo.key];
if (utils["a" /* default */].isUndef(value)) {
return tmpDefaultValue;
} else if (keyInfo.enums && keyInfo.enums.length > 0 && keyInfo.enums.includes(value)) {
return value;
} else {
// 看过滤信息
var isOr = keyInfo.isOr ? true : false;
if (keyInfo.filters && keyInfo.filters.length > 0) {
var isRight = true;
var funcName, funcParams, filterFunc;
for (var filterIndex = 0; filterIndex < keyInfo.filters.length; filterIndex++) {
var filterItem = keyInfo.filters[filterIndex];
if (utils["a" /* default */].isStr(filterItem)) {
funcName = filterItem;
funcParams = [];
} else {
funcName = filterItem.name;
funcParams = utils["a" /* default */].isArr(filterItem.params) ? filterItem.params : [];
}
filterFunc = schema_rules[funcName];
if (filterFunc) {
var newParams = [value].concat(_toConsumableArray(funcParams)); // console.log(newParams);
var funcResult = filterFunc.apply(null, newParams);
if (isOr) {
// or 关系
if (funcResult === true) {
isRight = true;
break;
} else {
isRight = false;
}
} else {
// and 关系
if (funcResult !== true) {
isRight = false;
break;
} else {
isRight = true;
}
}
} else {
console.warn(funcName + "不存在,请检查");
}
}
if (isRight) {
// 走了一圈,此值正确
return value;
} else {
return tmpDefaultValue;
}
} else {
// 没有条件,那么就是正确的
return value;
}
}
},
/**
* 进出的值的格式转换
* @param {*} format
*/
__parseFormat: function __parseFormat(format) {
var newFormat;
if (utils["a" /* default */].isArr(format)) {
// 是枚举
newFormat = [];
format.forEach(function (item) {
if (!utils["a" /* default */].isUndef(item.outer) && !utils["a" /* default */].isUndef(item.inner)) {
newFormat.push(item);
} else {
console.warn("format属性:outer和inner必须成对定义");
}
});
return newFormat.length > 0 ? newFormat : false;
} else if (utils["a" /* default */].isObj(format)) {
newFormat = {};
if (utils["a" /* default */].isFunc(format.outer)) {
newFormat.outer = format.outer;
} else {
newFormat.outer = false;
}
if (utils["a" /* default */].isFunc(format.inner)) {
newFormat.inner = format.inner;
} else {
newFormat.inner = false;
}
return newFormat.outer || newFormat.inner ? newFormat : false;
} else {
// 格式不合法
return false;
}
},
__parseCol: function __parseCol(value) {
if (value && utils["a" /* default */].isStr(value)) {
value = {
width: value
};
}
if (utils["a" /* default */].isNum(value)) {
value = parse_int_default()(value);
if (value < 1 && value > constant["a" /* default */].UI_MAX_COL) {
value = constant["a" /* default */].UI_MAX_COL;
}
return value;
} else if (utils["a" /* default */].isObj(value)) {
var keys = keys_default()(value);
var newInfo = {
width: "100%"
};
keys.forEach(function (key) {
var widthValue = value[key];
if (widthValue === constant["a" /* default */].WIDTH_AUTO || utils["a" /* default */].isPercent(widthValue) || utils["a" /* default */].isPx(widthValue)) {
widthValue = widthValue.toLowerCase(); // 只支持三种长度(最小、最大、长度)
var keyWidth = "width";
var minWidth = "min-width";
var maxWidth = "max-width";
if (key === keyWidth) {
newInfo[keyWidth] = widthValue;
} else if (key === minWidth || key === "minWidth") {
newInfo[minWidth] = widthValue;
} else if (key === maxWidth || key === "maxWidth") {
newInfo[maxWidth] = widthValue;
}
}
});
return newInfo;
} else {
return constant["a" /* default */].UI_MAX_COL;
}
},
/**
* 解析项Label
*/
__parseLabel: function __parseLabel(value, myPathKey) {
var newLabel,
defaultAlign = false;
newLabel = Object(component_utils["i" /* parsePropComponent */])(value, m_currentFormId, myPathKey, true); // 因为label有点特殊,所以不能为false
if (newLabel) {
newLabel.flex = Object(component_utils["g" /* parseFlex */])(value.flex, value.size);
newLabel.align = Object(component_utils["d" /* parseAlign */])(value.align, defaultAlign);
newLabel.help = this.__parsePropHelp(value.help, myPathKey);
} else {// newLabel = {
// text: false,
// __rawText: false,
// flex: false,
// align: defaultAlign
// };
}
return newLabel;
},
/**
* 解析title
*/
__parseTitle: function __parseTitle(value, myPathKey) {
var newValue = Object(component_utils["i" /* parsePropComponent */])(value, m_currentFormId, myPathKey);
if (newValue) {
newValue.help = this.__parsePropHelp(value.help, myPathKey);
}
return newValue;
},
/**
* 解析boxUi, 只支持properites
*/
__parseBoxUi: function __parseBoxUi(ui) {
var newUi, type;
var types = ["bg", "block", "bg-block"];
if (utils["a" /* default */].isObj(ui) && keys_default()(ui).length > 0) {
newUi = {};
if (utils["a" /* default */].isBool(ui.showBody)) {
newUi.__hasToggle = true; // 有切换按钮
newUi.showBody = ui.showBody; // 只有__hasToggle为true时toggleTexts才有用
newUi.toggleTexts = this.__parseMulTexts(ui.toggleTexts, ["打开", "隐藏"]);
} else {
newUi.__hasToggle = false; // 无切换按钮
newUi.showBody = true;
}
type = utils["a" /* default */].isStr(ui.type) ? ui.type.trim() : "";
newUi.type = types.includes(type) ? type : "";
newUi.hasBorder = utils["a" /* default */].isBool(ui.hasBorder) ? ui.hasBorder : false;
newUi.padding = this.__parsePadding(ui.padding);
} else if (utils["a" /* default */].isStr(ui)) {
type = ui ? ui : "";
type = utils["a" /* default */].isStr(type) ? type.trim() : "";
if (types.includes(type)) {
newUi = {
// __hasToggle: false,
showBody: true,
type: type // hasBorder: false,
// padding: false
};
} else {
newUi = {
// __hasToggle: false,
showBody: true,
type: "" // hasBorder: false,
// padding: false
};
}
} else {
newUi = {
// __hasToggle: false,
showBody: true,
type: "" // hasBorder: false,
// padding: false
};
}
return newUi;
},
/**
* 过滤多个文本
* @param {*} texts 数组
* @param {*} defaultTexts 默认值。数组
*/
__parseMulTexts: function __parseMulTexts(texts, defaultTexts) {
if (utils["a" /* default */].isArr(defaultTexts) && defaultTexts.length > 0) {
var newTexts = [];
if (utils["a" /* default */].isArr(texts) && texts.length == defaultTexts.length) {
texts.forEach(function (text) {
text = utils["a" /* default */].isStr(text) ? text.trim() : "";
if (text) {
newTexts.push(text);
}
});
} // 值不合法,采用默认值
if (newTexts.length < defaultTexts.length) {
newTexts = defaultTexts; // 没有就取默认值
}
return newTexts;
} else {
throw new Error("__parseMulTexts参数不对:默认文本一定要是数组");
}
},
/**
* 块(properties)中提取可继承的属性,为下一组做准备
* @param {*} propItem
* @param {*} inheritObj 从上一级继承的数据
*/
__parseInherit: function __parseInherit(propItem, inheritObj) {
var _this = this;
var ui = utils["a" /* default */].isObj(propItem.ui) ? propItem.ui : {};
var keys = ["offsetLeft", "offsetRight", "direction", "colon", ["rowSpace", "boxRowSpace"], ["labelWidth", "boxLabelWidth"], ["rowHeight", "boxRowHeight"]];
var tmpUi = {};
var newInherit = {};
keys.forEach(function (key) {
var newKey, oldKey;
if (utils["a" /* default */].isStr(key)) {
newKey = key;
oldKey = false;
} else {
newKey = key[0];
oldKey = key[1];
}
var normalKeyInfo = _this.__getNormalInfo(newKey);
if (normalKeyInfo) {
var curValue = ui[newKey];
tmpUi[newKey] = curValue;
if (utils["a" /* default */].isUndef(curValue) && oldKey) {
if (!utils["a" /* default */].isUndef(propItem[oldKey])) {
tmpUi[newKey] = propItem[oldKey];
console.warn("属性" + oldKey + "已舍弃,请使用ui." + newKey);
}
} // console.log("-- tmpUi: ", tmpUi);
newInherit[newKey] = _this.__parseNormalKey(tmpUi, normalKeyInfo, inheritObj);
} else {
throw "BoxUi: 程序的key(" + key + ")不对应,请修改";
}
});
return newInherit;
},
/**
* 解析样式值:类似于padding margin(现仅支持px, 可以不写单位): 如20 或 “20px 20 30px”
* @param {*} value
* @param {*} canNegative 是否可以是负数;因为大多数时我们都不需要负数,所以默认为false
* @returns false 或 一个长度为4的类组
*/
__parsePadding: function __parsePadding(value, canNegative) {
var resultVals,
tmpVals,
max = 4;
if (utils["a" /* default */].isNum(value)) {
if (canNegative || value >= 0) {
resultVals = [value, value, value, value];
} else {
resultVals = [0, 0, 0, 0];
}
return resultVals.join("px ") + "px";
} else if (utils["a" /* default */].isStr(value)) {
value = value.trim();
if (value) {
tmpVals = value.split(/\s+/);
if (tmpVals.length <= max) {// 暂时合法,下面统一判断
} else {
tmpVals = false;
}
} else {
tmpVals = false;
}
} else if (utils["a" /* default */].isArr(value) && value.length <= max) {
// 暂时合法,下面统一判断
tmpVals = value;
} else {
return false;
} // string or array
if (tmpVals) {
// 看数组的内容是否正确
resultVals = [];
var reg1 = /^(-?\d+(\.\d+)?)(px)?$/; // 点号有数字
var reg2 = /^(-?\.\d+)(px)?$/; // 点号无数字
var numVal;
for (var i = 0; i < tmpVals.length; i++) {
var tmpVal = tmpVals[i];
if (utils["a" /* default */].isNum(tmpVal)) {
numVal = tmpVal;
if (canNegative || numVal >= 0) {
resultVals.push(numVal);
} else {
resultVals.push(0);
}
} else {
var match = tmpVal.match(reg1) || tmpVal.match(reg2);
if (match) {
numVal = Number(match[1]);
if (canNegative || numVal >= 0) {
resultVals.push(numVal);
} else {
resultVals.push(0);
}
} else {
break; // 不合法,退出循环
}
}
}
if (resultVals.length === tmpVals.length) {
// 解析是正确的,看个数
if (resultVals.length === 1) {
resultVals.push(resultVals[0], resultVals[0], resultVals[0]);
} else if (resultVals.length === 2) {
resultVals.push(resultVals[0], resultVals[1]);
} else if (resultVals.length === 3) {
resultVals.push(resultVals[1]);
} else {// 长度为4个
}
} else {
resultVals = false;
}
} else {
resultVals = false;
}
return resultVals ? resultVals.join("px ") + "px" : false;
},
/**
* 解析帮助
*/
__parsePropHelp: function __parsePropHelp(help, myPathKey) {
// console.log("help: ", help);
var gHelp = false;
if (utils["a" /* default */].isObj(help) && keys_default()(help).length > 0) {
gHelp = {};
assign_default()(gHelp, help);
if (!gHelp.name) {
gHelp.name = components_help;
}
gHelp = Object(component_utils["i" /* parsePropComponent */])(gHelp, m_currentFormId, myPathKey);
} else if (utils["a" /* default */].isStr(help)) {
gHelp = {
name: components_help,
props: {
content: help
}
};
gHelp = Object(component_utils["i" /* parsePropComponent */])(gHelp, m_currentFormId, myPathKey);
} else {
gHelp = false;
} // console.log("gHelp: ", gHelp);
return gHelp;
},
/**
* 解析规则
*/
__parsePropRules: function __parsePropRules(rules) {
var _this2 = this;
var tmpRawRequired = false,
// tmpRawCanOnlyWarn = false,
tmpCheckWarn = false,
tmpCheckList = [];
if (utils["a" /* default */].isObj(rules)) {
if (rules.check) {
console.warn("rules.check已经舍弃了,请使用rules.checks");
}
var rawCheckList;
if (rules.checks) {
rawCheckList = rules.checks;
} else if (rules.check) {
console.warn("rules.check已经舍弃了,请使用rules.checks");
rawCheckList = rules.check;
}
if (!rawCheckList) {
rawCheckList = [];
} else if (!utils["a" /* default */].isArr(rawCheckList)) {
rawCheckList = [rawCheckList];
}
rawCheckList.forEach(function (item) {
var newItem = _this2.__perfectCheckItem(item);
if (newItem) {
// 正确
tmpCheckList.push(newItem);
}
}); // 取出required
if (parse["a" /* default */].isEsOrFunc(rules.required)) {
tmpRawRequired = parse["a" /* default */].newEsFuncion(rules.required);
} else if (utils["a" /* default */].isBool(rules.required)) {
tmpRawRequired = rules.required;
} else {
tmpRawRequired = false;
} // 取出canOnlyWarn
// if (parse.isEsOrFunc(rules.canOnlyWarn)) {
// tmpRawCanOnlyWarn = parse.newEsFuncion(rules.canOnlyWarn);
// } else if (utils.isBool(rules.canOnlyWarn)) {
// tmpRawCanOnlyWarn = rules.canOnlyWarn;
// } else {
// tmpRawCanOnlyWarn = false;
// }
if (utils["a" /* default */].isBool(rules.checkWarn) || utils["a" /* default */].isFunc(rules.checkWarn)) {
tmpCheckWarn = rules.checkWarn;
}
} else if (utils["a" /* default */].isBool(rules)) {
tmpRawRequired = rules;
rules = {};
} else if (parse["a" /* default */].isEsOrFunc(rules)) {
tmpRawRequired = parse["a" /* default */].newEsFuncion(rules);
rules = {};
} else {
return false;
} // 当不是必须的和没有检查,等价于rules为false
if (tmpRawRequired || tmpCheckList.length > 0) {
var newRules = {};
var emptyMsg, errMsg; // 为true或为函数
if (tmpRawRequired) {
// 有为空检查
if (utils["a" /* default */].isStr(rules.emptyMsg)) {
emptyMsg = rules.emptyMsg.trim();
}
newRules.emptyMsg = emptyMsg ? emptyMsg : "不能为空";
if (utils["a" /* default */].isFunc(rules.emptyMethod)) {
newRules.emptyMethod = rules.emptyMethod;
}
newRules.showRequired = utils["a" /* default */].isBool(rules.showRequired) ? rules.showRequired : true;
} // 是动态,记录下来
if (utils["a" /* default */].isFunc(tmpRawRequired)) {
newRules.required = false; // 会动态解析
newRules.__rawRequired = tmpRawRequired;
} else {
newRules.required = tmpRawRequired;
} // 是动态,记录下来
// if (utils.isFunc(tmpRawCanOnlyWarn)) {
// newRules.canOnlyWarn = false; // 会动态解析
// newRules.__rawCanOnlyWarn = tmpRawCanOnlyWarn;
// } else {
// newRules.canOnlyWarn = tmpRawCanOnlyWarn;
// }
newRules.checkWarn = tmpCheckWarn;
if (tmpCheckList.length > 0) {
newRules.checks = tmpCheckList; // 有非空检查
if (utils["a" /* default */].isStr(rules.errMsg)) {
errMsg = rules.errMsg.trim();
}
newRules.errMsg = errMsg ? errMsg : "格式不对";
} // 提取class和style
assign_default()(newRules, Object(component_utils["e" /* parseClassStyle */])(rules));
return newRules;
} else {
return false;
}
},
/**
* array是否为数组
* @param {*} array
*/
__isArray: function __isArray(array) {
if (array) {
return true;
} else {
return false;
}
},
/**
* 是否为块(properties)
* @param {*} rawItem
*/
__isPropItem: function __isPropItem(rawItem) {
return !this.__isSpaceItem(rawItem) && utils["a" /* default */].isObj(rawItem.properties);
},
/**
* 块(properties)里面是否存在非空项
* @param {*} rawPropItem
*/
__existEntityItem: function __existEntityItem(rawPropItem) {
if (this.__isPropItem(rawPropItem)) {
for (var key in rawPropItem.properties) {
var nextRawProp = rawPropItem.properties[key];
if (this.__isIngnoreItem(nextRawProp)) {
continue;
}
if (!this.__isSpaceItem(nextRawProp)) {
return true; // 有一个即可以了
}
}
}
return false;
},
/**
* 项设置为null 或 undefined则忽略(在新增或编辑时特别有用)
* @param {*} rawPropItem
*/
__isIngnoreItem: function __isIngnoreItem(rawPropItem) {
if (utils["a" /* default */].isNull(rawPropItem) || utils["a" /* default */].isUndef(rawPropItem) || rawPropItem === false) {
return true;
} else {
return false;
}
},
/**
* 是否为space item
* @param {*} subitem
*/
__isSpaceItem: function __isSpaceItem(rawItem) {
if (utils["a" /* default */].isObj(rawItem) && (rawItem.layout === constant["a" /* default */].LAYOUT_SPACE || rawItem.layout && rawItem.layout.name === constant["a" /* default */].LAYOUT_SPACE)) {
return true;
}
return false;
},
/**
* 是否为tabs item
* @param {*} subitem
*/
__isTabsItem: function __isTabsItem(rawItem) {
if (rawItem.layout === constant["a" /* default */].LAYOUT_TABS || rawItem.layout && rawItem.layout.name === constant["a" /* default */].LAYOUT_TABS) {
return true;
}
return false;
},
/**
* 布局设置标准化
*/
__parsePropLayout: function __parsePropLayout(layout) {
var newLayout = {
name: false
};
var layoutTypes = [constant["a" /* default */].LAYOUT_SPACE, constant["a" /* default */].LAYOUT_TABS];
if (utils["a" /* default */].isStr(layout)) {
if (layoutTypes.includes(layout)) {
newLayout.name = layout;
layout = {};
}
} else if (utils["a" /* default */].isObj(layout)) {
if (layoutTypes.includes(layout.name)) {
newLayout.name = layout.name;
}
} else {// nothing
}
if (newLayout.name === false) {
// 没有布局
return false;
} else if (newLayout.name === constant["a" /* default */].LAYOUT_TABS) {
// 是子节点布局是tabs时所需要的一些参数
// var types = ["bg", "card", "line"];
newLayout.type = layout.type;
newLayout.hasBorder = utils["a" /* default */].isBool(layout.hasBorder) ? layout.hasBorder : true;
newLayout.padding = this.__parsePadding(layout.padding);
}
return newLayout;
},
/**
* 数组设置标准化
*/
__parsePropArray: function __parsePropArray(array, rawItem, myPathKey) {
if (this.__isArray(array)) {
var newArray = {};
var hasSort = false; //是否有排序按钮,默认为false
var hasDelete = true; //是否有删除按钮,默认为true
var hasAdd = true; //是否有添加按钮(下边的添加按钮),默认为true
var hasCopy = false; // //是否有拷贝添加按钮,默认为false
var max = 0; //不写或小于等于0代表不限制
var min = 0; //不写或小于等于0代表0
var fixed = 0; //不写或小于等于0代表0
var hasOrder = true; //是否有序号,默认为true
var headRequired = false; //此值当name为constant.ARRAY_TABLE有效,当设置为true时,“星号”在table头部显示,而不是在内容区随组件显示,默认为true;注意:当为true时,required的值不能受properties里面的属性影响
var hasDelWarn = true; // 删除是否有警告
var subLabel = false;
var rules = false;
var actions = false;
var value = [];
var rowSpace = undefined;
var type = null;
var hasBorder = true;
var insertValue = undefined;
var delMsg;
var delAllMsg;
var delWarnBtns;
var before = false;
var btnType = false;
if (utils["a" /* default */].isStr(array)) {
newArray.name = array;
} else if (!utils["a" /* default */].isObj(array)) {
newArray.name = constant["a" /* default */].ARRAY_ROW;
} else {
newArray.name = utils["a" /* default */].isStr(array.name) ? array.name : constant["a" /* default */].ARRAY_ROW;
hasSort = array.hasSort ? true : false;
hasDelete = utils["a" /* default */].isUndef(array.hasDelete) || array.hasDelete ? true : false;
hasAdd = utils["a" /* default */].isUndef(array.hasAdd) || array.hasAdd ? true : false;
hasCopy = array.hasCopy ? true : false;
min = utils["a" /* default */].isNum(array.min) && array.min > 0 ? array.min : 0;
max = utils["a" /* default */].isNum(array.max) && array.max > 0 ? array.max : 0;
fixed = utils["a" /* default */].isNum(array.fixed) && array.fixed > 0 ? array.fixed : 0;
hasOrder = utils["a" /* default */].isUndef(array.hasOrder) || array.hasOrder ? true : false;
headRequired = array.name == constant["a" /* default */].ARRAY_TABLE && array.headRequired ? true : false;
subLabel = Object(component_utils["i" /* parsePropComponent */])(array.subLabel, m_currentFormId, myPathKey);
if (!subLabel) {
// 不可以为false, 因为必须要显示
subLabel = {
hidden: false,
text: false
};
}
hasDelWarn = utils["a" /* default */].isUndef(array.hasDelWarn) || array.hasDelWarn ? true : false;
if (array.hasOwnProperty("delMsg")) {
delMsg = array.delMsg;
} else {
delMsg = "确定删除吗?";
}
delMsg = Object(component_utils["i" /* parsePropComponent */])(delMsg, m_currentFormId, myPathKey + "(数组)");
if (!delMsg) {
delMsg = {
hidden: false,
text: false
};
}
if (array.hasOwnProperty("delAllMsg")) {
delAllMsg = array.delAllMsg;
} else {
delAllMsg = "确定删除所有吗?";
}
delAllMsg = Object(component_utils["i" /* parsePropComponent */])(delAllMsg, m_currentFormId, myPathKey + "(数组)");
if (!delAllMsg) {
delAllMsg = {
hidden: false,
text: false
};
}
delWarnBtns = this.__parseMulTexts(array.delWarnBtns, ["确定", "取消"]);
before = utils["a" /* default */].isFunc(array.before) ? array.before : false;
value = utils["a" /* default */].isArr(array.value) ? array.value : [];
rules = this.__parsePropRules(array.rules);
actions = Object(component_utils["c" /* parseActions */])(array.actions, myPathKey);
rowSpace = utils["a" /* default */].isNum(array.rowSpace) ? array.rowSpace : undefined;
type = utils["a" /* default */].isStr(array.type) ? array.type : false;
var btnTypes = ["icon"];
btnType = btnTypes.includes(array.btnType) ? array.btnType : false;
hasBorder = utils["a" /* default */].isBool(array.hasBorder) ? array.hasBorder : true;
insertValue = utils["a" /* default */].isUndef(array.insertValue) ? undefined : array.insertValue;
}
if (!this.__isPropItem(rawItem) && newArray.name == constant["a" /* default */].ARRAY_TABLE) {
newArray.name = constant["a" /* default */].ARRAY_ROW;
console.warn(myPathKey + "叶子节点(组件)不支持为" + constant["a" /* default */].ARRAY_TABLE + "数组, " + constant["a" /* default */].ARRAY_TABLE + "将失效, 强制转化为" + constant["a" /* default */].ARRAY_ROW);
} else if (this.__isPropItem(rawItem) && newArray.name == constant["a" /* default */].ARRAY_CARD) {
newArray.name = constant["a" /* default */].ARRAY_ROW;
console.warn(myPathKey + "为非叶子节点(非组件),不支持为" + constant["a" /* default */].ARRAY_CARD + "数组, " + constant["a" /* default */].ARRAY_CARD + "将失效, 强制转化为" + constant["a" /* default */].ARRAY_ROW);
}
if (newArray.name == constant["a" /* default */].ARRAY_ROW || newArray.name == constant["a" /* default */].ARRAY_TABLE || newArray.name == constant["a" /* default */].ARRAY_TABS || newArray.name == constant["a" /* default */].ARRAY_CARD || newArray.name == constant["a" /* default */].ARRAY_LEGEND) {
newArray.hasSort = hasSort;
newArray.hasDelete = hasDelete;
newArray.hasDelWarn = hasDelWarn;
newArray.delMsg = delMsg;
newArray.delAllMsg = delAllMsg;
newArray.delWarnBtns = delWarnBtns;
newArray.hasAdd = hasAdd;
newArray.hasCopy = hasCopy;
newArray.btnType = btnType;
newArray.min = min;
newArray.max = max >= min ? max : 0;
newArray.fixed = fixed;
newArray.hasOrder = hasOrder;
newArray.headRequired = headRequired;
newArray.value = value;
newArray.rules = rules;
newArray.before = before;
newArray.actions = actions;
newArray.rowSpace = rowSpace;
if (newArray.name == constant["a" /* default */].ARRAY_TABS) {
newArray.subLabel = subLabel;
newArray.type = type;
newArray.hasBorder = hasBorder;
} else if (newArray.name == constant["a" /* default */].ARRAY_LEGEND) {
newArray.subLabel = subLabel;
}
if (!utils["a" /* default */].isUndef(insertValue)) {
newArray.insertValue = insertValue;
}
if (newArray.min > 0) {
var minMsg = utils["a" /* default */].isStr(array.minMsg) ? array.minMsg.trim() : "";
if (!minMsg) {
minMsg = "长度不能小于" + newArray.min;
}
newArray.minMsg = minMsg;
}
if (newArray.max > 0) {
var maxMsg = utils["a" /* default */].isStr(array.maxMsg) ? array.maxMsg.trim() : "";
if (!maxMsg) {
maxMsg = "长度不能大于" + newArray.max;
}
newArray.maxMsg = maxMsg;
}
} else {
throw "this.__parsePropArray: array.name不合法";
}
return newArray;
} else {
return false;
}
},
/**
* 验证函数标准化
*/
__perfectCheckItem: function __perfectCheckItem(item) {
if (utils["a" /* default */].isFunc(item)) {
return {
handler: item,
trigger: [constant["a" /* default */].INPUT_EVENT]
};
} else if (parse["a" /* default */].isEsScript(item)) {
return {
handler: parse["a" /* default */].newEsFuncion(item),
trigger: [constant["a" /* default */].INPUT_EVENT]
};
} else if (utils["a" /* default */].isObj(item) && (parse["a" /* default */].isEsOrFunc(item.handler) || parse["a" /* default */].isEsOrFunc(item.name))) {
var handler;
if (utils["a" /* default */].isFunc(item.handler)) {
handler = item.handler;
} else if (utils["a" /* default */].isFunc(item.name)) {
console.warn("rules.checks.name已经舍弃了,请使用rules.checks.handler");
handler = item.name;
} else if (parse["a" /* default */].isEsScript(item.handler)) {
throw "rules.check.handler已经舍弃了且规则不再支持es写法,请使用函数赋值rules.checks.handler";
} else {
throw "rules.check.name已经舍弃了且规则不再支持es写法,请使用函数赋值rules.checks.handler";
}
var newTrigger = Object(component_utils["j" /* parseTrigger */])(item.trigger);
newTrigger = newTrigger && newTrigger.length ? utils["a" /* default */].unique(newTrigger) : [constant["a" /* default */].INPUT_EVENT];
var newItem = {
handler: handler,
trigger: newTrigger
};
return newItem;
} else {
console.warn("rules.checks设置不正确: 正确的格式如:[{trigger, handler}], 错误的item为", item);
return false;
}
},
/**
* 标准化属性配置
* @param {*} propItem
* @param {*} propKeys
* @param {*} inheritObj
* @param {*} myPathKey
*/
__filterKeys: function __filterKeys(propItem, propKeys, inheritObj, myPathKey) {
var _this3 = this;
var newPropItem = {};
propKeys.forEach(function (key) {
if (key == "label") {
newPropItem[key] = _this3.__parseLabel(propItem[key], myPathKey);
return true;
}
if (key == "col") {
newPropItem[key] = _this3.__parseCol(propItem[key], myPathKey);
return true;
}
if (key == "title") {
newPropItem[key] = _this3.__parseTitle(propItem[key], myPathKey);
return true;
}
if (key == "ui") {
newPropItem[key] = _this3.__parseBoxUi(propItem.ui);
return true;
}
if (key == "nextInherit") {
newPropItem[key] = _this3.__parseInherit(propItem, inheritObj);
return true;
}
if (key == "format") {
newPropItem[key] = _this3.__parseFormat(propItem[key]);
return true;
}
if (key == "rules") {
newPropItem[key] = _this3.__parsePropRules(propItem[key]);
newPropItem.__invalidMsg = false;
return true;
}
if (key == "help") {
newPropItem[key] = _this3.__parsePropHelp(propItem[key], myPathKey);
return true;
}
if (key == "desc") {
newPropItem[key] = Object(component_utils["i" /* parsePropComponent */])(propItem[key], m_currentFormId, myPathKey);
return true;
}
if (key == "unit") {
newPropItem[key] = Object(component_utils["i" /* parsePropComponent */])(propItem[key], m_currentFormId, myPathKey);
return true;
}
if (key == "array") {
var arrayAttr = _this3.__parsePropArray(propItem[key], propItem, myPathKey);
newPropItem[key] = arrayAttr;
if (arrayAttr) {
newPropItem.__invalidMsg = false;
}
return true;
}
if (key == "layout") {
newPropItem[key] = _this3.__parsePropLayout(propItem[key]);
return true;
}
if (key == "component") {
var mainComponent = Object(component_utils["h" /* parseMainComponent */])(propItem, m_currentFormId, myPathKey);
newPropItem[key] = mainComponent;
if (mainComponent.ref) {
newPropItem.__hasRef = true;
}
return true;
}
var normalKeyInfo = _this3.__getNormalInfo(key);
if (normalKeyInfo) {
newPropItem[key] = _this3.__parseNormalKey(propItem, normalKeyInfo, inheritObj);
} else {
throw "程序的key(" + key + ")不对应,请修改";
}
});
if (!utils["a" /* default */].isUndef(newPropItem.rowSpace)) {
newPropItem.__rawRowSpace = newPropItem.rowSpace; // __rawRowSpace用于第一行计算或恢复,因为第一行可能会变为0
newPropItem.__style = null;
}
return newPropItem;
},
/**
* 取出全局设置的属性:以便继承
*/
__getGlobalInheritObj: function __getGlobalInheritObj() {
var keys = ["offsetLeft", "offsetRight", "direction", "colon", "rowSpace", "labelWidth", "rowHeight"];
var obj = {};
keys.forEach(function (key) {
obj[key] = global["a" /* default */][key];
}); // console.log("obj: ", obj);
return obj;
},
__reinitGroup: function __reinitGroup(propItem) {
var lastGroup = false;
var groups; // var colSum = 0;
var gFirstItem; //每一组的第一项
for (var key in propItem.properties) {
var item = propItem.properties[key];
var curGroup = item["group"];
if (curGroup) {
if (lastGroup) {
//已经存在了
if (lastGroup === curGroup) {
//是前面的那一组
groups.push(key); // colSum += item.col;
gFirstItem.__groupCol = this.__sumCol(gFirstItem.__groupCol, item.col); // colSum > constant.UI_MAX_COL ? constant.UI_MAX_COL : colSum;
} else {
//不是前面的那一组,重新开组
lastGroup = curGroup;
gFirstItem = item;
groups = [key];
item.__groups = groups;
item.__hiddenGroup = false; // item.col = constant.UI_MAX_COL;
// colSum = item.col;
gFirstItem.__groupCol = item.col; // colSum > constant.UI_MAX_COL ? constant.UI_MAX_COL : colSum;
}
} else {
//前面没有组,重新开组
lastGroup = curGroup;
gFirstItem = item;
groups = [key];
item.__groups = groups;
item.__hiddenGroup = false; // item.col = constant.UI_MAX_COL;
// colSum = item.col;
gFirstItem.__groupCol = item.col; // colSum > constant.UI_MAX_COL ? constant.UI_MAX_COL : colSum;
}
item.__inGroups = true; //记录此项在分组里面
} else {
lastGroup = false;
groups = null; // colSum = 0;
gFirstItem = null;
}
}
},
/**
* 合并两个长度
* @param {*} col1
* @param {*} col2
*/
__sumCol: function __sumCol(col1, col2) {
var _this4 = this;
// 都是整数
if (utils["a" /* default */].isNum(col1) && utils["a" /* default */].isNum(col2)) {
var colSum = col1 + col2;
colSum = colSum > constant["a" /* default */].UI_MAX_COL ? constant["a" /* default */].UI_MAX_COL : colSum;
return colSum;
} else {
// 存在非整数,转化为对象相加
var colObj1 = col1;
var colObj2 = col2;
if (!utils["a" /* default */].isObj(colObj1)) {
colObj1 = {
width: this.__intToPercent(colObj1)
};
}
if (!utils["a" /* default */].isObj(colObj2)) {
colObj2 = {
width: this.__intToPercent(colObj2)
};
}
var keyWidth = "width";
var minWidth = "min-width";
var maxWidth = "max-width";
var keys = [keyWidth, minWidth, maxWidth];
var newColObj = {};
keys.forEach(function (key) {
var valSum = _this4.__countValue(colObj1[key], colObj2[key]);
if (!valSum) {
if (keyWidth === key) {
newColObj[key] = _this4.__intToPercent(constant["a" /* default */].UI_MAX_COL);
} else if (minWidth === key) {
newColObj[key] = colObj1[key];
} else {// maxWidth不要了
}
} else {
newColObj[key] = valSum;
}
});
}
},
__intToPercent: function __intToPercent(col) {
if (utils["a" /* default */].isNum(col)) {
return Math.floor(col * 1000000 / constant["a" /* default */].UI_MAX_COL) / 10000 + "%"; // 保留4位
} else {
return col;
}
},
/**
* 计算两个值之和,不能相加就返回false
* @param {*} val1
* @param {*} val2
*/
__countValue: function __countValue(val1, val2) {
var unit, sum;
if (val1 === constant["a" /* default */].WIDTH_AUTO && val2 === constant["a" /* default */].WIDTH_AUTO) {
return constant["a" /* default */].WIDTH_AUTO;
} else if (utils["a" /* default */].isPercent(val1) && utils["a" /* default */].isPercent(val2)) {
unit = "%";
sum = parse_float_default()(val1.substr(0, val1.length - unit.length)) + parse_float_default()(val2.substr(0, val2.length - unit.length));
return (sum > 100 ? 100 : sum) + unit;
} else if (utils["a" /* default */].isPx(val1) && utils["a" /* default */].isPx(val2)) {
unit = "px";
sum = parse_float_default()(val1.substr(0, val1.length - unit.length)) + parse_float_default()(val2.substr(0, val2.length - unit.length));
return sum + unit;
} else {
return false;
}
},
/**
* 检查数据平铺时schema是否合法。也就是第一层的properies展开的key和第一层的key是否有重复印
* @param {*} schema // 已经整理过的schema
*/
__checkForTile: function __checkForTile(schema) {
if (schema.autoMatch) {
var keyTotals = {};
var firstPropSchema = schema.properties;
for (var key in firstPropSchema) {
// 第一层的key
if (keyTotals[key]) {
keyTotals[key] = keyTotals[key] + 1;
} else {
keyTotals[key] = 1;
}
var nextSchema = firstPropSchema[key];
if (nextSchema.properties && !nextSchema.array) {
var nextPropItem = nextSchema.properties;
for (var nextKey in nextPropItem) {
// 第二层的key
if (keyTotals[nextKey]) {
keyTotals[nextKey] = keyTotals[nextKey] + 1;
} else {
keyTotals[nextKey] = 1;
}
}
}
}
var errKeys = [];
for (var schemaKey in keyTotals) {
if (keyTotals[schemaKey] > 1) {
errKeys.push(schemaKey + "(共" + keyTotals[schemaKey] + "次)");
}
}
if (errKeys.length > 0) {
throw "属性" + errKeys.join("、") + "出错重复,无法做到自动匹配"; // return false;
}
return true;
} else {
return true;
}
}
};
/* harmony default export */ var schema_utils = __webpack_exports__["a"] = (schemaUtils);
/***/ }),
/***/ "355d":
/***/ (function(module, exports) {
exports.f = {}.propertyIsEnumerable;
/***/ }),
/***/ "35e8":
/***/ (function(module, exports, __webpack_require__) {
var dP = __webpack_require__("d9f6");
var createDesc = __webpack_require__("aebd");
module.exports = __webpack_require__("8e60") ? function (object, key, value) {
return dP.f(object, key, createDesc(1, value));
} : function (object, key, value) {
object[key] = value;
return object;
};
/***/ }),
/***/ "36c3":
/***/ (function(module, exports, __webpack_require__) {
// to indexed object, toObject with fallback for non-array-like ES3 strings
var IObject = __webpack_require__("335c");
var defined = __webpack_require__("25eb");
module.exports = function (it) {
return IObject(defined(it));
};
/***/ }),
/***/ "3702":
/***/ (function(module, exports, __webpack_require__) {
// check on default Array iterator
var Iterators = __webpack_require__("481b");
var ITERATOR = __webpack_require__("5168")('iterator');
var ArrayProto = Array.prototype;
module.exports = function (it) {
return it !== undefined && (Iterators.Array === it || ArrayProto[ITERATOR] === it);
};
/***/ }),
/***/ "3710":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_legend_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("b1bf");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_legend_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_legend_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_legend_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "3846":
/***/ (function(module, exports, __webpack_require__) {
// 21.2.5.3 get RegExp.prototype.flags()
if (__webpack_require__("9e1e") && /./g.flags != 'g') __webpack_require__("86cc").f(RegExp.prototype, 'flags', {
configurable: true,
get: __webpack_require__("0bfb")
});
/***/ }),
/***/ "386b":
/***/ (function(module, exports, __webpack_require__) {
var $export = __webpack_require__("5ca1");
var fails = __webpack_require__("79e5");
var defined = __webpack_require__("be13");
var quot = /"/g;
// B.2.3.2.1 CreateHTML(string, tag, attribute, value)
var createHTML = function (string, tag, attribute, value) {
var S = String(defined(string));
var p1 = '<' + tag;
if (attribute !== '') p1 += ' ' + attribute + '="' + String(value).replace(quot, '"') + '"';
return p1 + '>' + S + '</' + tag + '>';
};
module.exports = function (NAME, exec) {
var O = {};
O[NAME] = exec(createHTML);
$export($export.P + $export.F * fails(function () {
var test = ''[NAME]('"');
return test !== test.toLowerCase() || test.split('"').length > 3;
}), 'String', O);
};
/***/ }),
/***/ "38fd":
/***/ (function(module, exports, __webpack_require__) {
// 19.1.2.9 / 15.2.3.2 Object.getPrototypeOf(O)
var has = __webpack_require__("69a8");
var toObject = __webpack_require__("4bf8");
var IE_PROTO = __webpack_require__("613b")('IE_PROTO');
var ObjectProto = Object.prototype;
module.exports = Object.getPrototypeOf || function (O) {
O = toObject(O);
if (has(O, IE_PROTO)) return O[IE_PROTO];
if (typeof O.constructor == 'function' && O instanceof O.constructor) {
return O.constructor.prototype;
} return O instanceof Object ? ObjectProto : null;
};
/***/ }),
/***/ "394e":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
// import constant from "./constant";
// import esHelp from "../components/help.vue";
var global = {
boxRowHeight: 40,
boxRowSpace: 20,
boxLabelWidth: 100,
rowHeight: 40,
rowSpace: 20,
labelWidth: 100,
colon: false,
direction: "h",
offsetLeft: 0,
// 项的左边偏移
offsetRight: 0,
// // 项的右边偏移
defaultCom: "input",
defaultVal: "",
// 这个是对defaultCom的补充,当组件为defaultCom时且没有设置默认值,则取此值;注:此值对其它组件不补充
// help: { name: esHelp, props: {} },
trimDoms: ["input", "textarea", "el-input"],
// 经测试:在el-input里,change比change.native先触发
hasConsole: false,
// 是否有控制台,默认为false
trimEvent: "change.native"
/* 这个是form的表单项改变时,此事件触发后会去掉左右两边空格;一般都是change, 因为有些类库可以喜欢写changed */
};
/* harmony default export */ __webpack_exports__["a"] = (global);
/***/ }),
/***/ "3a38":
/***/ (function(module, exports) {
// 7.1.4 ToInteger
var ceil = Math.ceil;
var floor = Math.floor;
module.exports = function (it) {
return isNaN(it = +it) ? 0 : (it > 0 ? floor : ceil)(it);
};
/***/ }),
/***/ "3b2b":
/***/ (function(module, exports, __webpack_require__) {
var global = __webpack_require__("7726");
var inheritIfRequired = __webpack_require__("5dbc");
var dP = __webpack_require__("86cc").f;
var gOPN = __webpack_require__("9093").f;
var isRegExp = __webpack_require__("aae3");
var $flags = __webpack_require__("0bfb");
var $RegExp = global.RegExp;
var Base = $RegExp;
var proto = $RegExp.prototype;
var re1 = /a/g;
var re2 = /a/g;
// "new" creates a new object, old webkit buggy here
var CORRECT_NEW = new $RegExp(re1) !== re1;
if (__webpack_require__("9e1e") && (!CORRECT_NEW || __webpack_require__("79e5")(function () {
re2[__webpack_require__("2b4c")('match')] = false;
// RegExp constructor can alter flags and IsRegExp works correct with @@match
return $RegExp(re1) != re1 || $RegExp(re2) == re2 || $RegExp(re1, 'i') != '/a/i';
}))) {
$RegExp = function RegExp(p, f) {
var tiRE = this instanceof $RegExp;
var piRE = isRegExp(p);
var fiU = f === undefined;
return !tiRE && piRE && p.constructor === $RegExp && fiU ? p
: inheritIfRequired(CORRECT_NEW
? new Base(piRE && !fiU ? p.source : p, f)
: Base((piRE = p instanceof $RegExp) ? p.source : p, piRE && fiU ? $flags.call(p) : f)
, tiRE ? this : proto, $RegExp);
};
var proxy = function (key) {
key in $RegExp || dP($RegExp, key, {
configurable: true,
get: function () { return Base[key]; },
set: function (it) { Base[key] = it; }
});
};
for (var keys = gOPN(Base), i = 0; keys.length > i;) proxy(keys[i++]);
proto.constructor = $RegExp;
$RegExp.prototype = proto;
__webpack_require__("2aba")(global, 'RegExp', $RegExp);
}
__webpack_require__("7a56")('RegExp');
/***/ }),
/***/ "3be1":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var core_js_modules_es6_string_includes__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("2fdb");
/* harmony import */ var core_js_modules_es6_string_includes__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_string_includes__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_assign__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("5176");
/* harmony import */ var E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_assign__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_assign__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var core_js_modules_web_dom_iterable__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__("ac6a");
/* harmony import */ var core_js_modules_web_dom_iterable__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_iterable__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_parse_int__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__("e814");
/* harmony import */ var E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_parse_int__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_parse_int__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var core_js_modules_es6_regexp_match__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__("4917");
/* harmony import */ var core_js_modules_es6_regexp_match__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_regexp_match__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var core_js_modules_es6_regexp_split__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__("28a5");
/* harmony import */ var core_js_modules_es6_regexp_split__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_regexp_split__WEBPACK_IMPORTED_MODULE_5__);
/* harmony import */ var core_js_modules_es6_function_name__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__("7f7f");
/* harmony import */ var core_js_modules_es6_function_name__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_function_name__WEBPACK_IMPORTED_MODULE_6__);
/* harmony import */ var core_js_modules_es7_array_includes__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__("6762");
/* harmony import */ var core_js_modules_es7_array_includes__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es7_array_includes__WEBPACK_IMPORTED_MODULE_7__);
/* harmony import */ var E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_keys__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__("a4bb");
/* harmony import */ var E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_keys__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_keys__WEBPACK_IMPORTED_MODULE_8__);
/* harmony import */ var _parse__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__("5f60");
/* harmony import */ var _constant__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__("890a");
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__("4513");
/**
* form-utils.js
*
* Copyright (c) 2019 chengaohe All rights reserved.
*
* 标准化表单schema后:用户操作(如输入,设值等)引起的schema修改
*
*/
var formUtils = {
/**
* 判断值是否为空, 以下几种情况都认为是空值
*/
isEmpty: function isEmpty(value) {
if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isUndef(value) || _utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isNull(value) || _utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isStr(value) && !value || _utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isObj(value) && E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_keys__WEBPACK_IMPORTED_MODULE_8___default()(value).length <= 0 || _utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isArr(value) && value.length <= 0) {
return true;
}
return false;
},
/**
* 全局设置
* @param {*} propItem
* @param {*} value
*/
setValue: function setValue(propItem, value) {
this.__setValue(propItem, value);
},
/**
* 全局设置
* @param {*} propItem
* @param {*} value
* @param {*} hasIdxChainChanged //设置过程序是否idxChain做改变,因为父级改变,子级也做做出改变,所以子级就不用再重新设置,等值设置完后,再由父级改变idxChain
*/
__setValue: function __setValue(propItem, value) {
var hasIdxChainChanged = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
if (propItem.array) {
if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isArr(value)) {
var hasChanged = false;
var schemaList = propItem.__propSchemaList;
if (schemaList.length > value.length) {
schemaList = schemaList.splice(0, value.length);
propItem.__propSchemaList = schemaList;
} else {
//不够,补上后面的;比如数组是3个,现在直接给了4个;
for (var i = schemaList.length; i < value.length; i++) {
this.addArrayItem(propItem);
}
hasChanged = true;
}
var hasNextIdxChainChanged = hasChanged || hasIdxChainChanged ? true : false;
for (var j = 0; j < value.length; j++) {
this.__setValue(schemaList[j], value[j], hasNextIdxChainChanged);
} // console.log(120);
if (hasChanged && !hasIdxChainChanged) {
this.resetIndexArr(propItem, propItem.__info.idxChain, propItem.__info.pathKey);
}
} else {
// 值的格式不区配,不必理会
return true;
} // console.log("in-end...", propItem.__propSchemaList.length);
return true;
} // 不是数据组了
if (propItem.component) {
var tmpValue;
if (propItem.format) {
// 不是最终取值,或没有格式转换
tmpValue = this.getFormatValue(propItem.format, value, true); // console.log(tmpValue, value);
} else {
tmpValue = value;
}
propItem.component.value = tmpValue;
} else if (propItem.properties) {
if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isObj(value)) {
for (var key in propItem.properties) {
if (value.hasOwnProperty(key)) {
this.__setValue(propItem.properties[key], value[key], hasIdxChainChanged);
}
}
}
} else {//可能是占位对象
}
},
/**
* 添加项,注:为什么写这个,统一过滤array, 避免无限循环
* @param {*} list 数组长列表, 会改变其结构
* @param {*} item 需要添加的项
* @param {*} insertInfo 需要添加的默认值;有值时是一个对象:格式如{value}
*/
addArrayItem: function addArrayItem(schema, insertInfo) {
var newItem = {}; //排除一些可能排版重复的或不需要的
var excludeKeys = ["array", "__propSchemaList", "desc", "help", "hidden", "__rawHidden", "__creatable", "label", "title", "isTmp"];
for (var key in schema) {
if (!excludeKeys.includes(key)) {
newItem[key] = _utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].deepCopy(schema[key]);
}
}
if (newItem.hasOwnProperty("__invalidMsg")) {
newItem.__invalidMsg = false;
}
if (!_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isUndef(schema.array.subLabel)) {
newItem.subLabel = _utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].deepCopy(schema.array.subLabel); // newItem.__invalidMsg = false;
} // console.log("schema.layout.name == constant.LAYOUT_TABS:", schema.layout.name == constant.LAYOUT_TABS);
if (schema.layout && schema.layout.name == _constant__WEBPACK_IMPORTED_MODULE_10__[/* default */ "a"].LAYOUT_TABS) {
newItem.__tabsIndex = false;
} // newItem.array不可有此值
if (newItem.array) {
newItem.array = false;
} // 取出delMsg给每一项
newItem.delMsg = _utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].deepCopy(schema.array.delMsg);
newItem.delWarnBtns = _utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].deepCopy(schema.array.delWarnBtns);
if (insertInfo) {
this.__setValue(newItem, insertInfo.value);
if (schema.__propSchemaList.length <= insertInfo.position) {
schema.__propSchemaList.push(newItem);
} else {
// 插入中间某个位置
schema.__propSchemaList.splice(insertInfo.position, 0, newItem);
}
} else {
schema.__propSchemaList.push(newItem);
}
},
/**
* 全局设置
* @param {*} propItem
* @param {*} idxChain //父级的idxChain
*/
resetIndexArr: function resetIndexArr(propItem, idxChain, pathKey) // 来自propItem.__propSchemaList循环
{
var currentIndex = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : -1;
var fromArray = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : false;
// console.log(":", pathKey, ":", pathKey);
if (propItem.array) {
// 因为__propSchemaList里面的item不会含array
if (propItem.__info.idxChain != idxChain) {
propItem.__info.idxChain = idxChain;
}
if (propItem.__info.pathKey != pathKey) {
propItem.__info.pathKey = pathKey;
}
var schemaList = propItem.__propSchemaList;
for (var i = 0; i < schemaList.length; i++) {
var nextIdxChain = idxChain ? idxChain + "," + i : "" + i;
var nextPathKey = pathKey + "[" + i + "]";
this.resetIndexArr(schemaList[i], nextIdxChain, nextPathKey, i, true);
}
return true;
} // 不是数组
if (propItem.component) {
if (propItem.__info.idxChain != idxChain) {
propItem.__info.idxChain = idxChain;
}
if (propItem.__info.pathKey != pathKey) {
propItem.__info.pathKey = pathKey;
}
if (propItem.__info.index != currentIndex) {
propItem.__info.index = currentIndex;
}
} else if (propItem.properties) {
if (propItem.__info.idxChain != idxChain) {
propItem.__info.idxChain = idxChain;
}
if (propItem.__info.pathKey != pathKey) {
propItem.__info.pathKey = pathKey;
}
if (propItem.__info.index != currentIndex) {
propItem.__info.index = currentIndex;
}
for (var key in propItem.properties) {
this.resetIndexArr(propItem.properties[key], idxChain, pathKey + "." + key, fromArray ? currentIndex : -1, // 因为__propSchemaList的构成是[{properties: {}}]
false);
}
} else {
//可能是占位对象
if (propItem.__info.idxChain != idxChain) {
propItem.__info.idxChain = idxChain;
}
if (propItem.__info.pathKey != pathKey) {
propItem.__info.pathKey = pathKey;
}
if (propItem.__info.index != currentIndex) {
propItem.__info.index = currentIndex;
}
}
},
/**
* 获取某一个属性tabs的索引
* @param {*} schema
* @param {*} pathKey "age、more1[0].name"
* @param {*} index
*/
getTabsIndex: function getTabsIndex(schema, pathKey) {
var targetSchema = this.__getSchemaByKey(schema, pathKey);
if (targetSchema) {
if (targetSchema.layout && targetSchema.layout.name === _constant__WEBPACK_IMPORTED_MODULE_10__[/* default */ "a"].LAYOUT_TABS) {
// 一般tabs
return targetSchema.__tabsIndex;
} else if (targetSchema.array && targetSchema.array.name === _constant__WEBPACK_IMPORTED_MODULE_10__[/* default */ "a"].ARRAY_TABS) {
// 数组tabs
return targetSchema.__tabsIndex;
} else {
// 不是tabs
return false;
}
} else {
return false; // 路径不对
}
},
/**
* 切换properies隐藏/打开
* @param {*} schema
* @param {*} pathKey "age、more1[0].name"
*/
togglePropBody: function togglePropBody(schema, pathKey) {
var targetSchema = this.__getSchemaByKey(schema, pathKey);
if (targetSchema) {
if (targetSchema.ui) {
targetSchema.ui.showBody = !targetSchema.ui.showBody;
}
} else {// 路径不对,不用理会;不过这个是系统返回,一般不会执行到这里
}
},
/**
* 指定某一个tabs的索引
* @param {*} schema
* @param {*} pathKey "age、more1[0].name"
* @param {*} index
*/
setTabsIndex: function setTabsIndex(schema, pathKey, index) {
var targetSchema = this.__getSchemaByKey(schema, pathKey); // console.log("targetSchema, pathKey, index: ", targetSchema, pathKey, index);
if (targetSchema) {
if (this.__isRightTabsIndex(targetSchema, index)) {
// 一般tabs
targetSchema.__tabsIndex = index;
if (targetSchema.array && targetSchema.array.name === _constant__WEBPACK_IMPORTED_MODULE_10__[/* default */ "a"].ARRAY_TABS) {
// 数组tabs
if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isNum(index)) {
if (targetSchema.__propSchemaList[index].__hasError) {
targetSchema.__propSchemaList[index].__hasError = false;
}
} else {// array tabs要是整数
}
} else if (targetSchema.layout && targetSchema.layout.name === _constant__WEBPACK_IMPORTED_MODULE_10__[/* default */ "a"].LAYOUT_TABS) {
if (targetSchema.properties[index].__hasError) {
targetSchema.properties[index].__hasError = false;
}
}
} else {// 不是tabs, 不用理会
}
} else {// 路径不对,不用理会;不过这个是系统返回,一般不会执行到这里
}
},
/**
* 是否正确的tabs索引
* @param {*} targetSchema
* @param {*} index
*/
__isRightTabsIndex: function __isRightTabsIndex(targetSchema, index) {
var nextSchema, key;
if (targetSchema.array && targetSchema.array.name === _constant__WEBPACK_IMPORTED_MODULE_10__[/* default */ "a"].ARRAY_TABS) {
// 数组tabs
if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isNum(index)) {
var newIndex = Math.floor(index);
if (newIndex === index && newIndex >= 0 && newIndex < targetSchema.__propSchemaList.length) {
return true;
}
} else {// array tabs要是整数
}
} else if (targetSchema.layout && targetSchema.layout.name === _constant__WEBPACK_IMPORTED_MODULE_10__[/* default */ "a"].LAYOUT_TABS) {
// 一般tabs
for (key in targetSchema.properties) {
nextSchema = targetSchema.properties[key];
if (key == index && !nextSchema.hidden) {
return true;
}
}
} else {// 不是tabs, 不用理会
}
return false;
},
/**
* 取出指定的schema
* @param {*} schema
* @param {*} pathKey
*/
getSchemaByKey: function getSchemaByKey(schema, pathKey) {
// 这个函数可能对外单独使用,所以不可以使用this
return this.__getSchemaByKey(schema, pathKey);
},
/**
*
* @param {*} schema
* @param {*} pathKey 必须存在键名:如name 或name[0]; 单独[0]是不允许的,会返回false
*/
__getSchemaByKey: function __getSchemaByKey(schema, pathKey) {
if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isStr(pathKey)) {
if (!pathKey) {
return schema;
}
var seperator = ".";
var keys = pathKey.split(seperator);
var curPropItem = schema;
var curProperties;
var nextPropItem;
var reg = /([\s\S]+?)\[(\d+)\]$/;
for (var i = 0; i < keys.length; i++) {
if (!curPropItem) {
//没有这一级数据,直接退出
return false;
}
curProperties = curPropItem.properties;
if (curProperties && !curPropItem.array) {
var key = keys[i];
var arrayItemKeys = key.match(reg);
var isLastKey = i == keys.length - 1;
var realKey = key;
if (arrayItemKeys) {
realKey = arrayItemKeys[1];
var realIndex = E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_parse_int__WEBPACK_IMPORTED_MODULE_3___default()(arrayItemKeys[2]); // console.log("realKey: ", realKey); // 空格也没有事; 如:空格[0]
curPropItem = curProperties[realKey]; //取出下级继续扫描
if (!curPropItem) {
//没有这个属性,退出
return false;
}
if (isLastKey) {
//最后一个key,表明是设置值
if (curPropItem.array) {
//设置array中的某一行(项)
if (curPropItem.__propSchemaList && curPropItem.__propSchemaList.length > realIndex) {
nextPropItem = curPropItem.__propSchemaList[realIndex];
return nextPropItem;
} else {
return false; //超出索引,不符合要求,直接退出
}
} else {
return false; //不符合要求:key是array类型,而当前的curPropItem不是数组
}
} else {
if (curPropItem.array) {
//进入array中的某一行(项),对某个属性进行设置
if (curPropItem.__propSchemaList && curPropItem.__propSchemaList.length > realIndex) {
//有效
curPropItem = curPropItem.__propSchemaList[realIndex]; //继续下一级(上面已经建立了新的curPropItem)
} else {
return false; //超出索引,不符合要求
}
} else {
return false; //不符合要求:key是array类型,而当前的curPropItem不是数组
}
}
} else {
curPropItem = curProperties[realKey]; //取出下级继续扫描
if (!curPropItem) {
//没有这个属性,不符合要求
return false;
}
if (isLastKey) {
//最后一个key,表明是设置值
return curPropItem; // 不管是不是数组,直接取出
} else {
if (curPropItem.array) {
// 不是最后一个key, 但curPropItem又是array(因为此形式严格来讲就是一个叶子)
return false; //不符合要求,退出
} else {//继续下一级(上面已经建立了新的curPropItem)
}
}
}
} else {
return false; //没有这一级,不符合要求,退出
}
}
} else {
return false; //pathKey不符合要求,退出
}
},
/**
* 指定某一个属性设置
* @param {*} schema
* @param {*} pathKey "age、more1[0].name"
* @param {*} value
*/
setValueByKey: function setValueByKey(schema, pathKey, value) {
// console.log("schema, pathKey: ", schema, pathKey, value);
var targetSchema = this.__getSchemaByKey(schema, pathKey); // console.log("current schema: ", targetSchema);
if (targetSchema) {
if (targetSchema.component) {
if (targetSchema.array) {
//是组件数组
if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isArr(value) || _utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isNull(value)) {
//直接设置array的值
this.setValue(targetSchema, value ? value : []);
}
} else {
var tmpValue;
if (targetSchema.format) {
// 不是最终取值,或没有格式转换
tmpValue = this.getFormatValue(targetSchema.format, value, true); // console.log(tmpValue, value);
} else {
tmpValue = value;
}
targetSchema.component.value = tmpValue;
}
} else if (targetSchema.properties) {
if (targetSchema.array) {
// 是数组赋值
if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isArr(value) || _utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isNull(value)) {
//直接设置array的值
this.setValue(targetSchema, value ? value : []);
}
} else {
// properties赋值
if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isObj(value)) {
this.setValue(targetSchema, value);
}
}
}
} else {// 路径不对,不用理会;不过这个是系统返回,一般不会执行到这里
}
},
/**
* 指定某一个属性进行清除
* @param {Object} schema
* @param {String} pathKey "age、more1[0].name"
* @param {Boolean} clearNext 是否清除子级及以下
*/
clearErrMsgByKey: function clearErrMsgByKey(schema, pathKey, clearNext) {
var targetSchema = this.__getSchemaByKey(schema, pathKey);
if (targetSchema) {
if (!clearNext) {
if (targetSchema.__invalidMsg) {
targetSchema.__invalidMsg = false;
}
if (targetSchema.__hasError) {
targetSchema.__hasError = false;
}
} else {
// 清除自已和所有的后代
this.clearErrMsg(targetSchema);
}
} else {// 路径不对或没有错误信息:不用理会
}
},
/**
* 清除当前propItem
* @param {*} propItem
*/
clearErrMsg: function clearErrMsg(propItem) {
var _this = this;
// 无论是哪一种,统一判断
if (propItem.__invalidMsg) {
propItem.__invalidMsg = false;
}
if (propItem.__hasError) {
propItem.__hasError = false;
} // 是数组,清空数组
if (propItem.array) {
var schemaList = propItem.__propSchemaList || [];
schemaList.forEach(function (schema) {
_this.clearErrMsg(schema);
});
} // 不是数据组了
if (propItem.component) {// ...
} else if (propItem.properties) {
for (var key in propItem.properties) {
// 清除下一级
this.clearErrMsg(propItem.properties[key]);
}
} else {//可能是占位对象
}
},
/**
* 表单内部的结果
*/
getValue: function getValue(propItem) {
return this.__getValue(propItem);
},
/**
* 表单的最终结果(也就是表单值,非根值)
* @param {*} schema perfect后的schema
* @param {*} baseParseSources {global: globalData, rootData: formData, rootSchema: rootSchema}
* @param {*} globalData 表单的全局数据
* @param {*} formData 表单的内部值
*/
getFormValue: function getFormValue(schema, baseParseSources) {
if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isObj(baseParseSources.rootData)) {
var resultValue = this.__getValue(schema, baseParseSources);
return this.__tileResultValue(schema, resultValue);
} else {
throw "getFormValue: formData 必须是一个对象";
}
},
/**
* 取值
* @param {*} propItem
* @param {*} baseParseSources {global: globalData, rootData: formData(此时这个值不一定有传,没有传时说明是取表单内部传, 有传就取最终结果), rootSchema: rootSchema}
* @param {*} isParentHidden
* 当formData有值时,则取出的是表单用户值,propItem也就是rootSchema,此时rootSchema最外部是不能隐藏的
*/
__getValue: function __getValue(propItem) {
var baseParseSources = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
var isParentHidden = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
var parseSources = E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_assign__WEBPACK_IMPORTED_MODULE_1___default()({}, baseParseSources);
parseSources.index = propItem.__info.index;
parseSources.idxChain = propItem.__info.idxChain;
parseSources.pathKey = propItem.__info.pathKey;
var formData = baseParseSources.rootData; // 当false没有值时,证明是表单的内容取值,后不的解析不用执行,提高效率
// formData有值,说明propItem.hidden都是已经出来的了,不做es转换,省资源
var isHidden = formData && (isParentHidden || propItem.hidden) ? true : false;
var newValue, keyValue, newArr, i, schemaList;
if (propItem.component) {
// 内部值,也不隐藏
if (propItem.array) {
// 是数组
newArr = [];
schemaList = propItem.__propSchemaList;
for (i = 0; i < schemaList.length; i++) {
newValue = this.__getValue(schemaList[i], baseParseSources, isHidden);
newArr.push(newValue);
}
return newArr;
} else {
// 不是数组
if (formData) {
if (propItem.format) {
// 不是最终取值,或没有格式转换
return this.getFormatValue(propItem.format, propItem.component.value, false);
} else {
return propItem.component.value;
}
} else {
// form 内部取值
return propItem.component.value;
}
}
} else if (propItem.properties) {
if (propItem.array) {
newArr = [];
schemaList = propItem.__propSchemaList;
for (i = 0; i < schemaList.length; i++) {
newValue = this.__getValue(schemaList[i], baseParseSources, isHidden);
newArr.push(newValue);
}
return newArr;
} else {
newValue = {};
for (var key in propItem.properties) {
var nextPropItem = propItem.properties[key]; // 占位空间,不需要取出;往下取
if (nextPropItem.layout && nextPropItem.layout.name === _constant__WEBPACK_IMPORTED_MODULE_10__[/* default */ "a"].LAYOUT_SPACE) {
continue;
} else if (formData && nextPropItem.isTmp) {
// 是取表单数据且是临时值
continue;
}
var isNextHidden = formData && (isHidden || nextPropItem.hidden) ? true : false; // console.log("isNextHidden...: ", isNextHidden);
if (!isNextHidden) {
// 取表单内部值或用户数据时不隐藏
keyValue = this.__getValue(nextPropItem, baseParseSources, isHidden);
newValue[key] = keyValue;
} else {
// 说明是取表单用户数据且隐藏
if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isUndef(nextPropItem.hdValue)) {// ...说明是不取出
} else if (!_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isNull(nextPropItem.hdValue)) {
// ...直接返回
if (nextPropItem.format) {
// 不是最终取值,或没有格式转换
newValue[key] = this.getFormatValue(nextPropItem.format, nextPropItem.hdValue, false);
} else {
newValue[key] = nextPropItem.hdValue;
}
} else {
// 剩下null, 说明是取原始值,是什么是就什么
keyValue = this.__getValue(nextPropItem, baseParseSources, isHidden);
newValue[key] = keyValue;
}
}
}
return newValue;
}
} else {
return undefined;
}
},
/**
* 数值转换
* @param {*} format
* @param {*} outerToInner
*/
getFormatValue: function getFormatValue(format, curVal) {
var outerToInner = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
if (format) {
if (outerToInner) {
// 表单外部的值转换为表单内部的值
var curEmum, i;
if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isArr(format)) {
// 数组,说明是枚举转换
for (i = 0; i < format.length; i++) {
curEmum = format[i];
if (curEmum.outer == curVal) {
return curEmum.inner;
}
}
} else if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isFunc(format.outer)) {
// 有外部转换函数
return format.outer(curVal);
}
} else {
// 表单内部的值转换为表单外部的值
if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isArr(format)) {
// 数组,说明是枚举转换
for (i = 0; i < format.length; i++) {
curEmum = format[i];
if (curEmum.inner == curVal) {
return curEmum.outer;
}
}
} else if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isFunc(format.inner)) {
// 有内部转换函数
return format.inner(curVal);
}
}
}
return curVal;
},
clearErrorMsg: function clearErrorMsg(propItem) {
if (!_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isUndef(propItem.__invalidMsg)) {
propItem.__invalidMsg = false;
}
if (propItem.component) {// if (!utils.isUndef(propItem.__invalidMsg)) {
// propItem.__invalidMsg = false;
// }
} else if (propItem.properties) {
if (propItem.array) {
var schemaList = propItem.__propSchemaList; // console.log(propItem.__propSchemaList);
for (var i = 0; i < schemaList.length; i++) {
this.clearErrorMsg(schemaList[i]);
}
} else {
for (var key in propItem.properties) {
this.clearErrorMsg(propItem.properties[key]);
}
}
} else {// return undefined;
}
},
/**
* 根据formData, 分析界面的情况。现主要是解析第一行的情况和hidden, required
* @param {*} schema
* @param {*} baseParseSources {global: globalData, rootData: formData, rootSchema: rootSchema, isHidden: }
* @param {*} formData
* @param {*} rootSchema
*/
analyzeUiProps: function analyzeUiProps(propItem, baseParseSources) {
var sum = 0;
var isHidden, listLen, schemaList, i;
var parseSources = E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_assign__WEBPACK_IMPORTED_MODULE_1___default()({}, baseParseSources);
parseSources.index = propItem.__info.index;
parseSources.idxChain = propItem.__info.idxChain;
parseSources.pathKey = propItem.__info.pathKey;
if (propItem.component) {
if (propItem.__rawHidden) {
// false或为空都不用执行
isHidden = _parse__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].smartEsValue(propItem.__rawHidden, parseSources);
if (propItem.hidden != isHidden) {
propItem.hidden = isHidden;
}
}
if (propItem.hasOwnProperty("__creatable") && !propItem.hidden && !propItem.__creatable) {
// 只有false时才可修改
propItem.__creatable = true;
}
if (propItem.label) {
// 解析组件内的属性
this.__esParseComponent(propItem.label, parseSources);
if (propItem.label.help) {
// 解析组件内的属性
this.__esParseComponent(propItem.label.help, parseSources);
}
}
if (propItem.desc) {
// 解析组件内的属性
this.__esParseComponent(propItem.desc, parseSources);
}
if (propItem.unit) {
// 解析组件内的属性
this.__esParseComponent(propItem.unit, parseSources);
}
if (propItem.help) {
// 解析组件内的属性
this.__esParseComponent(propItem.help, parseSources);
}
if (propItem.subLabel) {
// 解析组件内的属性
this.__esParseComponent(propItem.subLabel, parseSources);
}
if (propItem.delMsg) {
// 解析数组组件内的属性
this.__esParseComponent(propItem.delMsg, parseSources);
}
if (propItem.array) {
// 数组
schemaList = propItem.__propSchemaList;
for (i = 0; i < schemaList.length; i++) {
this.analyzeUiProps(schemaList[i], baseParseSources);
} // 是数组array-tabs, 调整索引
if (propItem.array.name == _constant__WEBPACK_IMPORTED_MODULE_10__[/* default */ "a"].ARRAY_TABS) {
listLen = propItem.__propSchemaList.length;
if (listLen > 0) {
if (propItem.__tabsIndex === false) {
// 刚开始,取第一个
propItem.__tabsIndex = 0;
} else {
if (propItem.__tabsIndex < 0 || propItem.__tabsIndex >= listLen - 1) {
propItem.__tabsIndex = listLen - 1; // 取最后一个
} else {// 此范围索引合法
}
}
} else {
if (propItem.__tabsIndex !== false) {
propItem.__tabsIndex = false;
}
}
}
if (propItem.array.rules) {
this.__esParseRules(propItem.array.rules, parseSources);
}
if (propItem.array.delAllMsg) {
this.__esParseComponent(propItem.array.delAllMsg, parseSources);
}
} else {
/* 一般组件 */
if (propItem.rules) {
this.__esParseRules(propItem.rules, parseSources);
} // 解析组件内的属性
this.__esParseComponent(propItem.component, parseSources);
}
} else if (propItem.properties) {
if (propItem.__rawHidden) {
// false或为空都不用执行
isHidden = _parse__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].smartEsValue(propItem.__rawHidden, parseSources);
if (propItem.hidden != isHidden) {
propItem.hidden = isHidden;
}
}
if (propItem.hasOwnProperty("__creatable") && !propItem.hidden && !propItem.__creatable) {
// 只有false时才可修改
propItem.__creatable = true;
}
if (propItem.title) {
// 解析组件内的属性
this.__esParseComponent(propItem.title, parseSources);
if (propItem.title.help) {
// 解析组件内的属性
this.__esParseComponent(propItem.title.help, parseSources);
}
}
if (propItem.label) {
// 解析组件内的属性
this.__esParseComponent(propItem.label, parseSources);
if (propItem.label.help) {
// 解析组件内的属性
this.__esParseComponent(propItem.label.help, parseSources);
}
}
if (propItem.desc) {
// 解析组件内的属性
this.__esParseComponent(propItem.desc, parseSources);
}
if (propItem.unit) {
// 解析组件内的属性
this.__esParseComponent(propItem.unit, parseSources);
}
if (propItem.help) {
// 解析组件内的属性
this.__esParseComponent(propItem.help, parseSources);
}
if (propItem.subLabel) {
// 解析组件内的属性
this.__esParseComponent(propItem.subLabel, parseSources);
}
if (propItem.delMsg) {
// 解析数组组件内的属性
this.__esParseComponent(propItem.delMsg, parseSources);
}
if (propItem.array) {
schemaList = propItem.__propSchemaList;
for (i = 0; i < schemaList.length; i++) {
this.analyzeUiProps(schemaList[i], baseParseSources);
} // 是数组tabs, 调整索引
if (propItem.array.name == _constant__WEBPACK_IMPORTED_MODULE_10__[/* default */ "a"].ARRAY_TABS) {
listLen = propItem.__propSchemaList.length;
if (listLen > 0) {
if (propItem.__tabsIndex === false) {
// 刚开始,取第一个
propItem.__tabsIndex = 0;
} else {
if (propItem.__tabsIndex < 0 || propItem.__tabsIndex >= listLen - 1) {
propItem.__tabsIndex = listLen - 1; // 取最后一个
} else {// 此范围索引合法
}
}
} else {
if (propItem.__tabsIndex !== false) {
propItem.__tabsIndex = false;
}
}
}
if (propItem.array.rules) {
this.__esParseRules(propItem.array.rules, parseSources);
}
if (propItem.array.delAllMsg) {
this.__esParseComponent(propItem.array.delAllMsg, parseSources);
}
} else {
var nextPropItem, key;
if (propItem.layout && propItem.layout.name == _constant__WEBPACK_IMPORTED_MODULE_10__[/* default */ "a"].LAYOUT_TABS) {
// 是普通tabs
for (key in propItem.properties) {
nextPropItem = propItem.properties[key];
if (!nextPropItem.__style) {
this.__updatePropStyle(nextPropItem, undefined, nextPropItem.col);
} // 下一级
this.analyzeUiProps(nextPropItem, baseParseSources);
} //调整索引
if (propItem.__tabsIndex === false) {
for (key in propItem.properties) {
// 取第一个不是隐藏的key作为索引
nextPropItem = propItem.properties[key];
if (!nextPropItem.hidden) {
propItem.__tabsIndex = key;
break;
}
}
} else {
var curIndexPropItem = propItem.properties[propItem.__tabsIndex]; // console.log("curIndexPropItem: ", curIndexPropItem, propItem.__tabsIndex);
if (curIndexPropItem.hidden) {
// 当前的索引对应的tab隐藏了
var indexs = [];
for (key in propItem.properties) {
nextPropItem = propItem.properties[key];
if (key === propItem.__tabsIndex) {
indexs.push(key);
} else if (!nextPropItem.hidden) {
indexs.push(key);
}
}
if (indexs.length > 1) {
var curIndex = indexs.indexOf(propItem.__tabsIndex);
if (curIndex < indexs.length - 1) {
// 不是最后一个,取下一个
propItem.__tabsIndex = indexs[curIndex + 1];
} else {
// 取上一个
propItem.__tabsIndex = indexs[curIndex - 1];
}
} else {
propItem.__tabsIndex = false; // 没有索引或全部tabs隐藏
}
} else {// 值有效,不必理会
}
}
} else {
sum = 0;
var newRowSpace;
var hasCustomWidth = propItem.__hasCustomWidth;
for (key in propItem.properties) {
nextPropItem = propItem.properties[key];
var hasRowSpaceChanged = false;
var currentCol;
if (!hasCustomWidth) {
if (nextPropItem.__groups) {
//是一个组
isHidden = this.__isGroupHidden(propItem, nextPropItem.__groups, baseParseSources); // console.log("isHidden: " + isHidden);
if (!isHidden) {
//组不隐藏
sum += nextPropItem.__groupCol;
if (sum <= _constant__WEBPACK_IMPORTED_MODULE_10__[/* default */ "a"].UI_MAX_COL) {
//还在第一行
newRowSpace = 0;
} else {
newRowSpace = nextPropItem.__rawRowSpace;
}
if (!nextPropItem.__style || nextPropItem.rowSpace != newRowSpace) {
//还原
nextPropItem.rowSpace = newRowSpace;
hasRowSpaceChanged = true;
currentCol = nextPropItem.__groupCol;
}
} else {//不必理会
}
if (nextPropItem.__hiddenGroup != isHidden) {
nextPropItem.__hiddenGroup = isHidden;
}
} else if (nextPropItem.__inGroups) {
//组内成员
if (!nextPropItem.__style || nextPropItem.rowSpace != 0) {
nextPropItem.rowSpace = 0;
hasRowSpaceChanged = true;
currentCol = nextPropItem.col;
}
} else {
//正常成员
var nextParseSources = E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_assign__WEBPACK_IMPORTED_MODULE_1___default()({}, baseParseSources);
nextParseSources.index = nextPropItem.__info.index;
nextParseSources.idxChain = nextPropItem.__info.idxChain;
nextParseSources.pathKey = nextPropItem.__info.pathKey;
isHidden = _parse__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].smartEsValue(nextPropItem.__rawHidden, nextParseSources); // console.log(nextPropItem.col, isHidden);
if (!isHidden) {
sum += nextPropItem.col;
if (sum <= _constant__WEBPACK_IMPORTED_MODULE_10__[/* default */ "a"].UI_MAX_COL) {
//还在第一行
newRowSpace = 0;
} else {
newRowSpace = nextPropItem.__rawRowSpace;
}
if (!nextPropItem.__style || nextPropItem.rowSpace != newRowSpace) {
//还原
nextPropItem.rowSpace = newRowSpace;
hasRowSpaceChanged = true;
currentCol = nextPropItem.col;
}
} else {//不必理会
}
}
if (hasRowSpaceChanged) {
this.__updatePropStyle(nextPropItem, nextPropItem.rowSpace, currentCol);
}
} else {
if (nextPropItem.__groups) {
//是一个组
isHidden = this.__isGroupHidden(propItem, nextPropItem.__groups, baseParseSources); // console.log("isHidden: " + isHidden);
if (!isHidden) {
//组不隐藏
if (!nextPropItem.__style) {
this.__updatePropStyle(nextPropItem, nextPropItem.rowSpace, nextPropItem.__groupCol);
}
} else {//不必理会
}
if (nextPropItem.__hiddenGroup != isHidden) {
nextPropItem.__hiddenGroup = isHidden;
}
} else if (nextPropItem.__inGroups) {
//组内成员
if (!nextPropItem.__style) {
this.__updatePropStyle(nextPropItem, 0, nextPropItem.col);
}
} else {
//正常成员
if (!nextPropItem.__style) {
this.__updatePropStyle(nextPropItem, nextPropItem.rowSpace, nextPropItem.col);
}
}
} // 下一级
this.analyzeUiProps(nextPropItem, baseParseSources);
}
}
}
} else {
// 占位空间等
if (propItem.__rawHidden) {
// false或为空都不用执行
isHidden = _parse__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].smartEsValue(propItem.__rawHidden, parseSources);
if (propItem.hidden != isHidden) {
propItem.hidden = isHidden;
}
}
if (propItem.hasOwnProperty("__creatable") && !propItem.hidden && !propItem.__creatable) {
// 只有false时才可修改
propItem.__creatable = true;
}
}
},
__updatePropStyle: function __updatePropStyle(propItem, rowSpace, col) {
// console.log("col", col);
var style = {
// marginTop: rowSpace + "px",
paddingLeft: (propItem.offsetLeft ? propItem.offsetLeft : 0) + "px",
paddingRight: (propItem.offsetRight ? propItem.offsetRight : 0) + "px"
};
if (rowSpace) {
style.marginTop = rowSpace + "px";
}
if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isNum(col)) {
var width = Math.floor(col * 1000000 / _constant__WEBPACK_IMPORTED_MODULE_10__[/* default */ "a"].UI_MAX_COL) / 10000;
width += "%";
style.width = width;
} else {
style = E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_assign__WEBPACK_IMPORTED_MODULE_1___default()(style, col);
}
propItem.__style = style;
},
/**
* 运行时解析组件:比如label, desc, component, help, title, unit
* @param {*} component
* @param {*} parseSources
*/
__esParseComponent: function __esParseComponent(component, parseSources) {
var _this2 = this;
var isHidden, text, style, className, value;
if (component.hasOwnProperty("__refreshIndex")) {
component.__refreshIndex++;
if (component.__refreshIndex > 10000) {
component.__refreshIndex = 1;
}
} // 项组件是没有此值的
if (component.__rawHidden) {
isHidden = _parse__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].smartEsValue(component.__rawHidden, parseSources);
if (component.hidden != isHidden) {
component.hidden = isHidden;
}
} // 正常组件:有以下属性要解析
if (component.name) {
// 解析属性
if (component.__rawProps) {
var curProps = component.props;
var rawProps = component.__rawProps;
var staticPropNames = component.__staticPropNames;
staticPropNames = staticPropNames ? staticPropNames : [];
for (var key in rawProps) {
if (!staticPropNames.includes(key)) {
text = _parse__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].smartEsValue(rawProps[key], parseSources);
} else {
text = rawProps[key];
}
if (curProps[key] !== text) {
curProps[key] = text;
}
}
} // 解析指令
if (component.__rawDirectives) {
var curDirectives = component.directives;
var rawDirectives = component.__rawDirectives;
for (var i = 0; i < rawDirectives.length; i++) {
var rawDirective = rawDirectives[i];
value = _parse__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].smartEsValue(rawDirective.value, parseSources);
if (value !== curDirectives[i].value) {
curDirectives[i].value = value;
}
}
} // 解析style
if (component.__rawStyle) {
style = _parse__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].smartEsValue(component.__rawStyle, parseSources);
if (style !== component.style) {
component.style = style;
}
} // 解析class
if (component.__rawClass) {
className = _parse__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].smartEsValue(component.__rawClass, parseSources);
if (className !== component.class) {
component.class = className;
}
} // 有name, toComText解析text
if (component.__rawText) {
text = _parse__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].smartEsValue(component.__rawText, parseSources);
text = _utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].toComText(text);
if (text !== component.text) {
component.text = text;
}
} // 解析scopedSlots
if (component.scopedSlots) {
var scopedSlots = component.scopedSlots;
for (var slotName in scopedSlots) {
var values = scopedSlots[slotName];
if (!_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isArr(value)) {
values = [values];
}
values.forEach(function (value) {
if (!_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isVNode(value) && _utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isObj(value)) {
// 是组件,解析
_this2.__esParseComponent(value, parseSources);
}
});
values = null;
}
}
} else {
// 没name, toNormalText解析text
if (component.__rawText) {
text = _parse__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].smartEsValue(component.__rawText, parseSources);
text = _utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].toNormalText(text);
if (text !== component.text) {
component.text = text;
}
}
}
},
/**
*
* @param {*} propItem
* @param {*} groups
* @param {*} baseParseSources {global: globalData, rootData: formData, rootSchema: rootSchema}
*/
__isGroupHidden: function __isGroupHidden(propItem, groups, baseParseSources) {
// console.log("groups: ", groups);
var result = false;
for (var i = 0; i < groups.length; i++) {
var fieldKeyName = groups[i];
var propSchema = propItem.properties[fieldKeyName];
if (!propSchema.layout || propSchema.layout.name !== _constant__WEBPACK_IMPORTED_MODULE_10__[/* default */ "a"].LAYOUT_SPACE) {
var parseSources = E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_assign__WEBPACK_IMPORTED_MODULE_1___default()({}, baseParseSources);
parseSources.index = propSchema.__info.index;
parseSources.idxChain = propSchema.__info.idxChain;
parseSources.pathKey = propSchema.__info.pathKey;
result = _parse__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].smartEsValue(propSchema.__rawHidden, parseSources); // console.log("fieldKeyName: " + fieldKeyName, result);
} else {
//占位空间是不可见的
result = true;
}
if (!result) {
return result;
}
}
return result;
},
/**
* 运行时解析rules
* @param {*} rules
* @param {*} parseSources
*/
__esParseRules: function __esParseRules(rules, parseSources) {
// 是否必须
if (rules.__rawRequired) {
var isRequired = _parse__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].smartEsValue(rules.__rawRequired, parseSources);
if (rules.required != isRequired) {
rules.required = isRequired;
}
} // 是否必须
// if (rules.__rawCanOnlyWarn) {
// var canOnlyWarn = parse.smartEsValue(
// rules.__rawCanOnlyWarn,
// parseSources
// );
// if (rules.canOnlyWarn != canOnlyWarn) {
// rules.canOnlyWarn = canOnlyWarn;
// }
// }
// 解析style
if (rules.__rawStyle) {
var style = _parse__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].smartEsValue(rules.__rawStyle, parseSources);
if (style !== rules.style) {
rules.style = style;
}
} // 解析class
if (rules.__rawClass) {
var className = _parse__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].smartEsValue(rules.__rawClass, parseSources);
if (className !== rules.class) {
rules.class = className;
}
}
},
/**
* 组装平铺数据
* @param {*} schema // 已经整理过的schema
* @param {*} value
*/
perfectTileValue: function perfectTileValue(schema, value) {
if (schema.autoMatch && value) {
if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isStr(value)) {
// 是key
return this.__perfectTileKey(schema, value);
} else if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isObj(value)) {
// 是key-value
var newValue = {};
for (var key in value) {
var seperator = ".";
var keyPath = this.__perfectTileKey(schema, key);
if (keyPath.indexOf(seperator) > 0) {
var paths = keyPath.split(seperator); // 两个
var firstKey = paths[0];
var second = paths[1];
if (newValue[firstKey]) {// newValue[firstKey][second] = value[second];
} else if (_utils__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"].isObj(value[firstKey])) {
// 重复设值
newValue[firstKey] = value[firstKey];
} else {
newValue[firstKey] = {};
}
newValue[firstKey][second] = value[second];
} else {
newValue[key] = value[key];
}
} // console.log("newValue: ", newValue);
return newValue;
} else {
return value; // 不知类型,直接返回
}
} else {
return value; // 值不对或不需要自动匹配,直接返回
}
},
__perfectTileKey: function __perfectTileKey(schema, keyPath) {
var seperator = ".";
var keyArr = keyPath.split(seperator);
var firstKey = keyArr[0];
var firstPropSchema = schema.properties;
for (var key in firstPropSchema) {
// 第一层的key
if (key === firstKey) {
return keyPath;
}
var nextSchema = firstPropSchema[key];
if (nextSchema.properties && !nextSchema.array) {
var nextPropItem = nextSchema.properties;
for (var nextKey in nextPropItem) {
// 第二层的key
if (nextKey === firstKey) {
keyArr.unshift(key); // 前面加上第一层的key
return keyArr.join(seperator);
}
}
}
} // 没有找到,改造后直接返回
return keyPath;
},
/**
* 把结果数据平铺化
* @param {*} schema // 已经整理过的schema
* @param {*} value
*/
__tileResultValue: function __tileResultValue(schema, value) {
if (schema.autoMatch) {
var newValue = {};
var firstPropSchema = schema.properties;
for (var key in value) {
var nextSchema = firstPropSchema[key];
if (nextSchema.properties && !nextSchema.array) {
newValue = E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_assign__WEBPACK_IMPORTED_MODULE_1___default()(newValue, value[key]);
} else {
newValue[key] = value[key];
}
}
return newValue;
} else {
return value;
}
}
};
/* harmony default export */ __webpack_exports__["a"] = (formUtils);
/***/ }),
/***/ "40c3":
/***/ (function(module, exports, __webpack_require__) {
// getting tag from 19.1.3.6 Object.prototype.toString()
var cof = __webpack_require__("6b4c");
var TAG = __webpack_require__("5168")('toStringTag');
// ES3 wrong here
var ARG = cof(function () { return arguments; }()) == 'Arguments';
// fallback for IE11 Script Access Denied error
var tryGet = function (it, key) {
try {
return it[key];
} catch (e) { /* empty */ }
};
module.exports = function (it) {
var O, T, B;
return it === undefined ? 'Undefined' : it === null ? 'Null'
// @@toStringTag case
: typeof (T = tryGet(O = Object(it), TAG)) == 'string' ? T
// builtinTag case
: ARG ? cof(O)
// ES3 arguments fallback
: (B = cof(O)) == 'Object' && typeof O.callee == 'function' ? 'Arguments' : B;
};
/***/ }),
/***/ "41a0":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var create = __webpack_require__("2aeb");
var descriptor = __webpack_require__("4630");
var setToStringTag = __webpack_require__("7f20");
var IteratorPrototype = {};
// 25.1.2.1.1 %IteratorPrototype%[@@iterator]()
__webpack_require__("32e9")(IteratorPrototype, __webpack_require__("2b4c")('iterator'), function () { return this; });
module.exports = function (Constructor, NAME, next) {
Constructor.prototype = create(IteratorPrototype, { next: descriptor(1, next) });
setToStringTag(Constructor, NAME + ' Iterator');
};
/***/ }),
/***/ "4362":
/***/ (function(module, exports, __webpack_require__) {
exports.nextTick = function nextTick(fn) {
setTimeout(fn, 0);
};
exports.platform = exports.arch =
exports.execPath = exports.title = 'browser';
exports.pid = 1;
exports.browser = true;
exports.env = {};
exports.argv = [];
exports.binding = function (name) {
throw new Error('No such module. (Possibly not yet loaded)')
};
(function () {
var cwd = '/';
var path;
exports.cwd = function () { return cwd };
exports.chdir = function (dir) {
if (!path) path = __webpack_require__("df7c");
cwd = path.resolve(dir, cwd);
};
})();
exports.exit = exports.kill =
exports.umask = exports.dlopen =
exports.uptime = exports.memoryUsage =
exports.uvCounters = function() {};
exports.features = {};
/***/ }),
/***/ "4513":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var core_js_modules_es7_array_includes__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("6762");
/* harmony import */ var core_js_modules_es7_array_includes__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es7_array_includes__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var core_js_modules_es6_string_includes__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("2fdb");
/* harmony import */ var core_js_modules_es6_string_includes__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_string_includes__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_keys__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__("a4bb");
/* harmony import */ var E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_keys__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_keys__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var core_js_modules_web_dom_iterable__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__("ac6a");
/* harmony import */ var core_js_modules_web_dom_iterable__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_iterable__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_freeze__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__("15b8");
/* harmony import */ var E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_freeze__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_freeze__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var core_js_modules_es6_regexp_to_string__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__("6b54");
/* harmony import */ var core_js_modules_es6_regexp_to_string__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_regexp_to_string__WEBPACK_IMPORTED_MODULE_5__);
/* harmony import */ var core_js_modules_es6_regexp_replace__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__("a481");
/* harmony import */ var core_js_modules_es6_regexp_replace__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_regexp_replace__WEBPACK_IMPORTED_MODULE_6__);
/* harmony import */ var core_js_modules_es6_regexp_constructor__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__("3b2b");
/* harmony import */ var core_js_modules_es6_regexp_constructor__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_regexp_constructor__WEBPACK_IMPORTED_MODULE_7__);
/* harmony import */ var core_js_modules_es6_array_iterator__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__("cadf");
/* harmony import */ var core_js_modules_es6_array_iterator__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_array_iterator__WEBPACK_IMPORTED_MODULE_8__);
/* harmony import */ var core_js_modules_es6_promise__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__("551c");
/* harmony import */ var core_js_modules_es6_promise__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_promise__WEBPACK_IMPORTED_MODULE_9__);
/* harmony import */ var core_js_modules_es6_object_assign__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__("f751");
/* harmony import */ var core_js_modules_es6_object_assign__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_object_assign__WEBPACK_IMPORTED_MODULE_10__);
/* harmony import */ var core_js_modules_es7_promise_finally__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__("097d");
/* harmony import */ var core_js_modules_es7_promise_finally__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es7_promise_finally__WEBPACK_IMPORTED_MODULE_11__);
// import constant from "./constant";
var utils = {
__Vue: null,
__key: 0,
initVue: function initVue(Vue) {
this.__Vue = Vue;
},
/**
* unicode letters used for parsing html tags, component names and property paths.
* using https://www.w3.org/TR/html53/semantics-scripting.html#potentialcustomelementname
* skipping \u10000-\uEFFFF due to it freezing up PhantomJS
*
* from vue source code
*/
unicodeRegExp: /a-zA-Z\u00B7\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u037D\u037F-\u1FFF\u200C-\u200D\u203F-\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD/,
validateComponentName: function validateComponentName(name) {
var reg = new RegExp("^[a-zA-Z][\\-\\.0-9_" + this.unicodeRegExp.source + "]*$");
return reg.test(name);
},
newUid: function newUid(prefix) {
utils.__key++;
return prefix ? prefix + "_" + utils.__key : utils.__key;
},
/**
* [trim 删除字符左右两的字符:默认为空格和换行符]
* @param {[String]} value [description]
* @param {[type]} reg [description]
* @return {[type]} [description]
*/
trim: function trim(value, reg) {
var tmpValue = value + "";
reg = reg ? reg : /^(\s|\r|\n|\t)+|(\s|\r|\n|\t)+$/g; //不传就直接删除前后的空格,换行; 若是只删空格就这样:/^\s+|\s+$/g
return tmpValue.replace(reg, "");
},
type: function type(obj) {
var toString = Object.prototype.toString;
var map = {
"[object Boolean]": "boolean",
"[object Number]": "number",
"[object String]": "string",
"[object Function]": "function",
"[object Array]": "array",
"[object Date]": "date",
"[object RegExp]": "regExp",
"[object Undefined]": "undefined",
"[object Null]": "null",
"[object Object]": "object"
};
var value = map[toString.call(obj)];
if (!value) {
//不是基本类型
if (obj instanceof Element) {
//dom节点,
return "element";
}
}
return value;
},
isBool: function isBool(value) {
return utils.type(value) === "boolean";
},
isNum: function isNum(value) {
return utils.type(value) === "number";
},
isStr: function isStr(value) {
return utils.type(value) === "string";
},
isFunc: function isFunc(value) {
return utils.type(value) === "function";
},
isArr: function isArr(value) {
return utils.type(value) === "array";
},
isDate: function isDate(value) {
return utils.type(value) === "date";
},
isReg: function isReg(value) {
return utils.type(value) === "regExp";
},
isUndef: function isUndef(value) {
return utils.type(value) === "undefined";
},
isNull: function isNull(value) {
return utils.type(value) === "null";
},
isObj: function isObj(value) {
return utils.type(value) === "object";
},
/**
* 是否scopedSlot为空
* @param {*} value
*/
isSlotUndef: function isSlotUndef(value) {
return this.isUndef(value) || this.isNull(value) || false;
},
/**
* 判断是否一个Vue实例:包括Vue或VueComponent实例
* @param {*} value
*/
isVue: function isVue(value) {
return value instanceof this.__Vue;
},
/**
* 判断是否一个虚拟节点
* @param {*} value
*/
isVNode: function isVNode(value) {
var VNode = this.__VNode;
if (!VNode) {
var Vue = this.__Vue;
var instance = new Vue();
var vnode = instance.$createElement("span", "");
VNode = vnode.constructor;
this.__VNode = VNode;
vnode = null;
instance = null;
}
return value instanceof VNode;
},
isVueObj: function isVueObj(value) {
if (this.isObj(value)) {
if (value.template || value.staticRenderFns && value.__file) {
return true;
} else {
return false;
}
} else {
return false;
}
},
isRefVal: function isRefVal(value) {
return this.isObj(value) || this.isArr(value);
},
/**
* [deepCopy 深拷贝, 深拷贝的数据是object和array]
* @param {[type]} data [description]
* @return {[type]} [description]
*/
deepCopy: function deepCopy(data) {
var rawRefs = [];
var newRefs = [];
var newData = this.__deepCopy(data, rawRefs, newRefs);
rawRefs = null;
newRefs = null;
return newData;
},
/**
* [deepCopy 深拷贝, 深拷贝的数据是object和array]
* @param {[type]} data [description]
* @return {[Array]} [rawRefs] 记录原始的object and array
* @return {[Array]} [newRefs] 记录新的object and array
* rawRefs和newRefs是一对一的关系,作用防止数据中某个地方存在循环的问题
*/
__deepCopy: function __deepCopy(data, rawRefs, newRefs) {
var type = utils.type(data);
var newData, rawIndex;
if (this.isVNode(data) || this.isVue(data)) {
// 虚拟节点,vue组件实例,不用深度拷贝
rawIndex = rawRefs.indexOf(data); // console.log("__deepCopy vnode");
if (rawIndex < 0) {
// 一对一保存; 先保存索引地址,下一级的deep可能会用到
rawRefs.push(data);
newRefs.push(data);
}
return data;
} else if (type == "array") {
rawIndex = rawRefs.indexOf(data);
if (rawIndex < 0) {
newData = []; // 一对一保存; 先保存索引地址,下一级的deep可能会用到
rawRefs.push(data);
newRefs.push(newData);
for (var i = 0; i < data.length; ++i) {
newData[i] = this.__deepCopy(data[i], rawRefs, newRefs);
}
return newData;
} else {
// 已经存在的数据,则取出上个拷贝的数组
return newRefs[rawIndex];
}
} else if (type === "object") {
rawIndex = rawRefs.indexOf(data);
if (rawIndex < 0) {
newData = {}; // 一对一保存; 先保存索引地址,下一级的deep可能会用到
rawRefs.push(data);
newRefs.push(newData);
for (var key in data) {
newData[key] = this.__deepCopy(data[key], rawRefs, newRefs);
}
return newData;
} else {
// 已经存在的数据,则取出上个拷贝的对象
return newRefs[rawIndex];
}
} else {
return data;
}
},
/**
* 处理可以有回调的钩子函数:主要是before、after
* @param {*} handle 句柄
* @param {*} context 上下文对象(指出来自哪里)
* @param {*} data 句柄所需要的数据
* @param {*} callback 回调
*/
execCbHook: function execCbHook(handle, context, data, callback) {
var hasExecuted = false; // 保存程序只执行一次
if (handle) {
var done = function done(result) {
if (!hasExecuted) {
hasExecuted = true;
} else {
// 已经执行过,无需要再执行
console.warn("done只能执行一次,不能执行多次;第二次执行done将无效");
return false;
}
if (callback) {
callback.call(context, result);
}
context = null;
};
handle.call(context, done, this.deepCopy(data));
data = null;
done = null;
} else {
if (callback) {
callback.call(context);
}
data = null;
context = null;
}
},
/**
* [deepFreeze 深冻结的数据是object和array]
* @param {[type]} data [description]
* @return {[type]} [description]
*/
deepFreeze: function deepFreeze(data) {
var rawRefs = [];
var newRefs = [];
var newData = this.__deepFreeze(data, rawRefs, newRefs);
rawRefs = null;
newRefs = null;
return newData;
},
/**
* [deepFreeze 深冻结的数据是object和array]
* @param {[type]} data [description]
* @return {[Array]} [rawRefs] 记录原始的object and array
* rawRefs作用防止数据中某个地方存在循环的问题
*/
__deepFreeze: function __deepFreeze(data, rawRefs) {
var type = utils.type(data);
var rawIndex;
if (this.isVNode(data) || this.isVue(data)) {
// 虚拟节点,vue组件实例,不用冻结
rawIndex = rawRefs.indexOf(data);
if (rawIndex < 0) {
// 一对一保存; 先保存索引地址,下一级的deep可能会用到
rawRefs.push(data);
}
} else if (type == "array") {
rawIndex = rawRefs.indexOf(data);
if (rawIndex < 0) {
// 一对一保存; 先保存索引地址,下一级的deep可能会用到
rawRefs.push(data); // 冻结这一层
E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_freeze__WEBPACK_IMPORTED_MODULE_4___default()(data);
for (var i = 0; i < data.length; ++i) {
this.__deepFreeze(data[i], rawRefs); // 继续走下一级
}
} else {// 已经存在的数据,则说明已经处理过,无需处理了
}
} else if (type === "object") {
rawIndex = rawRefs.indexOf(data);
if (rawIndex < 0) {
// 一对一保存; 先保存索引地址,下一级的deep可能会用到
rawRefs.push(data); // 冻结这一层
E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_freeze__WEBPACK_IMPORTED_MODULE_4___default()(data);
for (var key in data) {
this.__deepFreeze(data[key], rawRefs);
}
} else {// 已经存在的数据,则说明已经处理过,无需处理了
}
} else {// 其它类型,无需要理会
}
},
/**
* 数组去重
* @param {Array} arr
*/
unique: function unique(arr) {
var newArr = [];
if (this.isArr(arr)) {
var tmpObj = {};
arr.forEach(function (item) {
tmpObj[item] = 1;
});
newArr = E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_keys__WEBPACK_IMPORTED_MODULE_2___default()(tmpObj);
}
return newArr;
},
/* 两个数组是否有交集 */
isInter: function isInter(arr1, arr2) {
for (var i = 0; i < arr1.length; i++) {
if (arr2.includes(arr1[i])) {
return true;
}
}
return false;
},
isPercent: function isPercent(value) {
var reg = /^\d+(.\d+)?%$/i;
if (utils.isStr(value) && reg.test(value)) {
return true;
}
return false;
},
isPx: function isPx(value) {
var reg = /^\d+(.\d+)?px$/i;
if (utils.isStr(value) && reg.test(value)) {
return true;
}
return false;
},
/**
* 转在vue的驼峰形式
* @param {*} value
* 经在Vue的实例中测试,Vue对props属性名的解析有:
* 1. "text-Str" "text-str" 都会转成"textStr", 但"text--str"会报错,主要是template无法显示
* 1. "text-8str" 都会转成"text8str"
*/
vueCamelCase: function vueCamelCase(value) {
var reg = /-(\w)/g;
return value.replace(reg, function ($0, $1) {
return $1.toUpperCase();
});
},
/**
* 切换组件的text为字符串:支持string, number, boolean;
* 与toNormalText相比,范围要大于或等于
* @param {*} value
*/
toComText: function toComText(value) {
var newValue;
if (this.isStr(value)) {
newValue = value.trim();
newValue = newValue ? newValue : undefined;
} else if (this.isNum(value) || this.isBool(value)) {
newValue = value + "";
} else {
newValue = undefined;
}
return newValue;
},
/**
* 切换一般的text为字符串:只支持string, number, 因为有些组件对布尔型有特殊作用
* @param {*} value
*/
toNormalText: function toNormalText(value) {
var newValue;
if (this.isStr(value)) {
newValue = value.trim();
newValue = newValue ? newValue : undefined;
} else if (this.isNum(value)) {
newValue = value + "";
} else {
newValue = undefined;
}
return newValue;
},
/* 与toNormalText是对应的 */
isNormalText: function isNormalText(value) {
if (this.isStr(value)) {
return true;
} else if (this.isNum(value)) {
return true;
} else {
return false;
}
},
/**
* 随机产生一定长度的字符串:只有数字和字母
* @param {*} min 最小长度,默认为10,必须大于0
* @param {*} max 最大长度,默认为10,必须大于0
*/
randStr: function randStr(min, max) {
var chars = ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z", "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z"];
var len;
var isRightMax = true;
if (!this.isNum(min) || min < 1) {
min = 10;
}
if (!this.isNum(max) || max < 1) {
isRightMax = false;
max = 10;
}
if (!isRightMax) {
len = min;
} else {
if (min >= max) {
len = max;
} else {
// 取出min和max的随机长度
len = min + Math.round(Math.random() * (max - min));
}
}
var randStr = "",
randIndex;
var charsLen = chars.length;
for (var i = 0; i < len; i++) {
randIndex = Math.floor(Math.random() * charsLen);
randStr += chars[randIndex];
}
return randStr;
},
mergeGlobal: function mergeGlobal(global, extra) {
if (utils.isObj(extra)) {
for (var key in extra) {
if (!utils.isUndef(global[key])) {
var value = extra[key];
switch (key) {
case "boxRowHeight":
case "boxRowSpace":
case "boxLabelWidth":
case "rowHeight":
case "rowSpace":
case "labelWidth":
case "offsetLeft":
case "offsetRight":
if (key == "boxRowHeight") {
console.warn("全局设置boxRowHeight已经弃用,请改用为rowHeight");
key = "rowHeight";
} else if (key == "boxRowSpace") {
console.warn("全局设置boxRowSpace已经弃用,请改用为rowSpace");
key = "rowSpace";
} else if (key == "boxLabelWidth") {
console.warn("全局设置boxLabelWidth已经弃用,请改用为labelWidth");
key = "labelWidth";
}
if (utils.isNum(value) && value >= 0) {
global[key] = value;
} else {
console.warn("mergeGlobal: key(" + key + ")的值不是数值且大于等于0;此默认值将不重设");
}
break;
case "colon":
if (utils.isBool(value)) {
global[key] = value;
} else {
console.warn("mergeGlobal: key(" + key + ")的值不是true/false;此默认值将不重设");
}
break;
case "direction":
if (["v", "h"].includes(value)) {
global[key] = value;
} else {
console.warn("mergeGlobal: key(" + key + ')的值不是数组["v", "h"];此默认值将不重设');
}
break;
case "defaultCom":
if (value && utils.isStr(value) && value.trim()) {
var defaltName = value.trim();
if (utils.validateComponentName(defaltName)) {
global[key] = defaltName;
} else {
console.warn("mergeGlobal: key(" + key + ")的值有误(组件名存在html非法字符);此默认值将不重设");
}
} else {
console.warn("mergeGlobal: key(" + key + ")的值有误(1. 不能为空; 2. 是字符串);此默认值将不重设");
}
break;
case "trimEvent":
console.warn("trimEvent已经移走了,请关注trimDoms");
break;
case "trimDoms":
var tmpValue;
if (utils.isStr(value)) {
tmpValue = [value.trim()];
} else if (utils.isArr(value)) {
tmpValue = value.map(function (item) {
if (utils.isStr(item)) {
return item.trim();
} else {
return item;
}
});
} else {
console.warn("mergeGlobal: key(" + key + ")的值有误, 必须是一个组件名或一个组件;此默认值将不重设");
}
if (tmpValue) {
tmpValue = tmpValue.filter(function (item) {
return item ? true : false;
});
if (tmpValue.length <= 0) {
console.log("trimDoms的长度为0");
} // console.log("tmpValue", tmpValue);
global[key] = tmpValue;
}
break;
case "defaultVal":
if (!utils.isUndef(value)) {
global[key] = value;
} else {
console.warn("mergeGlobal: key(" + key + ")不能设置为undefined;此默认值将不重设");
}
break;
case "hasConsole":
if (utils.isBool(value)) {
global[key] = value;
} else {
console.warn("mergeGlobal: key(" + key + ")不能设置为非true/false;此默认值将不重设");
}
break;
default:
break;
}
} else {
console.warn("mergeGlobal: key(" + key + ")不存在");
}
}
}
}
};
/* harmony default export */ __webpack_exports__["a"] = (utils);
/***/ }),
/***/ "4588":
/***/ (function(module, exports) {
// 7.1.4 ToInteger
var ceil = Math.ceil;
var floor = Math.floor;
module.exports = function (it) {
return isNaN(it = +it) ? 0 : (it > 0 ? floor : ceil)(it);
};
/***/ }),
/***/ "45ac":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.string.includes.js
var es6_string_includes = __webpack_require__("2fdb");
// EXTERNAL MODULE: ./node_modules/core-js/modules/es7.array.includes.js
var es7_array_includes = __webpack_require__("6762");
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.regexp.split.js
var es6_regexp_split = __webpack_require__("28a5");
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.dom.iterable.js
var web_dom_iterable = __webpack_require__("ac6a");
// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/object/assign.js
var object_assign = __webpack_require__("5176");
var assign_default = /*#__PURE__*/__webpack_require__.n(object_assign);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.function.name.js
var es6_function_name = __webpack_require__("7f7f");
// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/object/keys.js
var keys = __webpack_require__("a4bb");
var keys_default = /*#__PURE__*/__webpack_require__.n(keys);
// EXTERNAL MODULE: ./src/package/libs/utils.js
var utils = __webpack_require__("4513");
// EXTERNAL MODULE: ./src/package/libs/constant.js
var constant = __webpack_require__("890a");
// CONCATENATED MODULE: ./src/package/libs/submit.js
/* 应用于表单组件函数,不能作为其它用途:因为this代表的是表单 */
var onlySubmit = function onlySubmit() {
this.submit();
};
/**
* 应用于表单组件函数,不能作为其它用途:因为this代表的是表单, event代表的是keyup事件
* 参数就是组件事件所对就的参数
* @param {*} value 当前组件的值
* @param {*} key 组件的源key
* @param {*} event 事件所携带的事件
*/
var enterSubmit = function enterSubmit(options) {
// console.log("value: ", value);
// console.log("key: ", key);
if (options.event && options.event.keyCode === 13) {
this.submit();
}
};
// EXTERNAL MODULE: ./src/package/libs/parse.js
var parse = __webpack_require__("5f60");
// EXTERNAL MODULE: ./src/package/libs/global.js
var global = __webpack_require__("394e");
// CONCATENATED MODULE: ./src/package/libs/component-utils.js
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "h", function() { return parseMainComponent; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "i", function() { return parsePropComponent; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return parseComponent; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return parseActions; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "j", function() { return parseTrigger; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return parseClassStyle; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return fetchActionEvent; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return getNativeName; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return parseAlign; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "g", function() { return parseFlex; });
/**
* component-utils.js
*
* Copyright (c) 2020 chengaohe All rights reserved.
*
* 解析表单所需要的组件
*/
"use strict";
/**
* 解析主组件:如也就是右栏的组件
*/
function parseMainComponent(propItem, formId, myPathKey) {
var component = propItem.component;
var newComponent,
defaultAlign = false;
if (utils["a" /* default */].isVNode(component)) {
throw myPathKey + " > 主组件暂不支持直接配置虚拟节点";
} else if (utils["a" /* default */].isObj(component) && keys_default()(component).length > 0) {
if (!component.name) {
component = assign_default()({}, component, {
name: global["a" /* default */].defaultCom
}); // 补上组件name
}
newComponent = parseComponent(component, myPathKey); // 主组特有配置
var ref = utils["a" /* default */].isStr(component.ref) ? component.ref.trim() : null;
if (ref) {
newComponent.ref = ref;
}
newComponent.align = parseAlign(component.align, defaultAlign);
newComponent.flex = parseFlex(component.flex, component.size); // value
if (propItem.hasOwnProperty("value")) {
newComponent.value = propItem.value;
} else if (component.hasOwnProperty("value")) {
newComponent.value = component.value;
} else {
// 自动补充value: 因为是表单组件
newComponent.value = component.name === global["a" /* default */].defaultCom ? global["a" /* default */].defaultVal : undefined;
}
} else if (utils["a" /* default */].isStr(component)) {
// 要自动补充value
newComponent = {
name: component,
actions: [],
align: defaultAlign,
flex: false,
value: propItem.hasOwnProperty("value") ? propItem.value : global["a" /* default */].defaultCom === component ? global["a" /* default */].defaultVal : undefined
};
} else {
// 要自动补充value
newComponent = {
name: global["a" /* default */].defaultCom,
actions: [],
align: defaultAlign,
flex: false,
value: global["a" /* default */].defaultVal
};
} // 判断名称是否合法
// if (
// utils.isStr(newComponent.name) &&
// !utils.validateComponentName(newComponent.name)
// ) {
// throw "组件名(" + newComponent.name + ")存在html非法字符";
// }
newComponent.__formId = formId; // newComponent.props = newComponent.props ? newComponent.props : {};
return newComponent;
}
/**
* 解析一般属性组件:如label, desc
*/
function parsePropComponent(value, formId, myPathKey) {
var canEmpty = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;
var newComponent;
if (utils["a" /* default */].isVNode(value)) {
throw myPathKey + " > 组件暂不支持直接配置虚拟节点";
} else if (utils["a" /* default */].isObj(value) && keys_default()(value).length > 0) {
newComponent = {};
var name = utils["a" /* default */].isStr(value.name) ? value.name.trim() : value.name;
if (name) {
newComponent = parseComponent(value, myPathKey);
if (!newComponent) {
return false;
}
} else {
var rawText = value.text;
if (!utils["a" /* default */].isFunc(rawText)) {
rawText = utils["a" /* default */].toNormalText(rawText); // 转换为文本
}
if (rawText || canEmpty) {
// 如label可为空
var tmpValue = assign_default()({}, value, {
name: "span"
});
newComponent = parseComponent(tmpValue, myPathKey);
tmpValue = null;
if (newComponent) {
if (newComponent.hasOwnProperty("name")) {
delete newComponent.name; // 本来就没有或为空,删除它
}
} else {
return false;
}
} else {
return false;
}
} // if (rawText) {
// newComponent.text = rawText;
// if (parse.isEsOrFunc(rawText)) {
// newComponent.__rawText = parse.newEsFuncion(rawText);
// }
// } else {
// newComponent.text = rawText;
// }
// if (!newComponent.text && !name && !canEmpty) {
// // 不符合要求,说明为空
// return false;
// }
if (parse["a" /* default */].isEsOrFunc(value.hidden)) {
newComponent.hidden = false;
newComponent.__rawHidden = parse["a" /* default */].newEsFuncion(value.hidden);
} else {
newComponent.hidden = !!value.hidden;
}
} else if (utils["a" /* default */].isNormalText(value)) {
value = utils["a" /* default */].toNormalText(value);
if (value || canEmpty) {
if (parse["a" /* default */].isEsOrFunc(value)) {
newComponent = {
text: value,
__rawText: parse["a" /* default */].newEsFuncion(value),
hidden: false
};
} else {
newComponent = {
text: value,
hidden: false
};
}
} else {
return false;
}
} else if (utils["a" /* default */].isFunc(value)) {
newComponent = {
text: value,
__rawText: value,
hidden: false
};
} else {
return false;
}
newComponent.__formId = formId;
return newComponent;
}
/**
* 解析标准组件:一个要是一个对象{name: xx}
* @param {*} component
* @param {*} myPathKey
* @param {*} canNone 当格式不合法时返回false(现在只有名字为空时返回false)。默认为false
* @param {*} needParse 是否需要解析,静态是不需要动态解析的。默认为true
* @returns {Object} 标准对象写法
*/
function parseComponent(component, myPathKey) {
var canNone = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
var needParse = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : true;
if (utils["a" /* default */].isObj(component) && component.name) {
var newComponent = {};
var name = utils["a" /* default */].isStr(component.name) ? component.name.trim() : component.name;
if (name) {
if (utils["a" /* default */].isStr(name) && !utils["a" /* default */].validateComponentName(name)) {
throw "组件名(" + " > " + name + ")存在html非法字符";
}
newComponent.name = name;
newComponent.actions = parseActions(component.actions, myPathKey); // 属性
var propInfo = parseComProps(component.props, ["style", "class"], needParse); // console.log(propInfo);
if (propInfo.new) {
newComponent.props = propInfo.new;
}
if (propInfo.raw) {
newComponent.__rawProps = propInfo.raw;
}
if (propInfo.staticNames) {
newComponent.__staticPropNames = propInfo.staticNames;
} // 指令
var directiveInfo = parseDirectives(utils["a" /* default */].isUndef(component.directives) ? component.v : component.directives, needParse);
if (directiveInfo.new) {
newComponent.directives = directiveInfo.new;
}
if (directiveInfo.raw) {
newComponent.__rawDirectives = directiveInfo.raw;
} // 提取class和style
assign_default()(newComponent, parseClassStyle(component, needParse));
var slotInfo = parseScopedSlots(component.scopedSlots, myPathKey, needParse);
if (slotInfo) {
if (slotInfo.hasRuntime) {
// 需要检测
newComponent.__refreshIndex = 0;
}
newComponent.scopedSlots = slotInfo.scopedSlots;
} // value
if (component.hasOwnProperty("value")) {
newComponent.value = component.value;
} else {// 无value, 证明不用双向绑定:这个不同于项组件的value, 人家会自动补充,这里没有
}
var rawText = component.text;
if (needParse && parse["a" /* default */].isEsOrFunc(rawText)) {
newComponent.text = rawText;
if (parse["a" /* default */].isEsOrFunc(rawText)) {
newComponent.__rawText = parse["a" /* default */].newEsFuncion(rawText);
}
} else {
newComponent.text = utils["a" /* default */].toComText(rawText);
}
} else {
if (!canNone) {
throw myPathKey + "组件格式不正确,必须是一个对象,且name必须存在.";
} else {
return false;
}
}
if (needParse && parse["a" /* default */].isEsOrFunc(component.hidden)) {
newComponent.hidden = false;
newComponent.__rawHidden = parse["a" /* default */].newEsFuncion(component.hidden);
} else {
newComponent.hidden = !!component.hidden;
}
} else {
if (!canNone) {
throw myPathKey + "组件格式不正确,必须是一个对象,且name必须存在";
} else {
return false;
}
}
newComponent.props = newComponent.props ? newComponent.props : {}; // 提取出所需要的监听事件(可以再次改造,如主组件去掉左中两边空格的事件就要重新改造合并)
var eventOn = fetchActionEvent(newComponent.actions);
newComponent.__emitEvents = eventOn.__emitEvents;
newComponent.__nativeEvents = eventOn.__nativeEvents;
return newComponent;
}
/**
* 解析/标准化项组件的事件
* @param {*} actions
* @param {*} myPathKey
*/
function parseActions(actions, myPathKey) {
// 解析是否为特殊写法
var newActions = [];
if (utils["a" /* default */].isObj(actions) && keys_default()(actions).length > 0 || utils["a" /* default */].isArr(actions) && actions.length > 0 || utils["a" /* default */].isFunc(actions) || utils["a" /* default */].isStr(actions)) {
var tmpActions;
if (utils["a" /* default */].isFunc(actions)) {
tmpActions = [{
trigger: constant["a" /* default */].CLICK_EVENT,
handler: actions
}];
} else if (utils["a" /* default */].isObj(actions)) {
tmpActions = [actions];
} else if (utils["a" /* default */].isStr(actions)) {
tmpActions = [actions];
} else {
// 就是数组了
tmpActions = actions;
}
tmpActions.forEach(function (tmpAction) {
var newTrigger, newAction;
if (utils["a" /* default */].isStr(tmpAction)) {
tmpAction = tmpAction.trim();
if (tmpAction == constant["a" /* default */].ENTER_SUBMIT) {
// keyup.native提交事件
newActions.push({
trigger: [constant["a" /* default */].KEYUP_NATIVE],
handler: enterSubmit
});
} else {
var actionInfos = tmpAction.split(/\s*=\s*/);
if (actionInfos && actionInfos.length == 2 && actionInfos[1] == constant["a" /* default */].ONLY_SUBMIT) {
// newActions.push({trigger: actionInfos[0], handler: onlySubmit});
newAction = {};
newTrigger = parseTrigger(actionInfos[0]);
newAction.trigger = newTrigger && newTrigger.length > 0 ? newTrigger : [constant["a" /* default */].CLICK_EVENT];
newAction.handler = onlySubmit;
newActions.push(newAction);
} else {
console.warn("key(" + myPathKey + ")存在不合法的事件,将过滤去掉,不会执行.");
}
}
} else if (utils["a" /* default */].isFunc(tmpAction.handler)) {
newAction = {};
newTrigger = parseTrigger(tmpAction.trigger);
newAction.trigger = newTrigger && newTrigger.length > 0 ? newTrigger : [constant["a" /* default */].CLICK_EVENT];
newAction.handler = tmpAction.handler;
newActions.push(newAction);
} else {
// 非法写,不是函数,去掉它
console.warn("key(" + myPathKey + ")存在不合法的事件,将过滤去掉,不会执行");
}
});
} else {// console.warn("key(" + myPathKey + ")component事件类型不合法.");
}
return newActions.length > 0 ? newActions : null;
}
/**
* 解析触发事件
* @param {*} trigger
* 1. 事件字件串或者以空格隔开的事件所组成的字符串,如"click" or "click change"
* 2. 事件组成的数组
* @returns 返回数据组,没有时返回一个null
*/
function parseTrigger(trigger) {
var tmpTriggers;
if (trigger === true) {
trigger = constant["a" /* default */].INPUT_EVENT;
}
if (utils["a" /* default */].isArr(trigger) || utils["a" /* default */].isStr(trigger)) {
if (utils["a" /* default */].isStr(trigger)) {
trigger = trigger.trim();
tmpTriggers = trigger.split(/\s+/);
} else {
tmpTriggers = [];
trigger.forEach(function (item) {
if (utils["a" /* default */].isStr(item)) {
item = item.trim();
tmpTriggers = tmpTriggers.concat(item.split(/\s+/));
} else if (item === true) {
tmpTriggers.push(constant["a" /* default */].INPUT_EVENT);
}
});
}
tmpTriggers = tmpTriggers.map(function (item) {
if (!item) {
// 为空,直接写默认事件
return constant["a" /* default */].CLICK_EVENT;
} else if (item.indexOf(".") === 0) {
// 只有修改,前面加默认事件
return constant["a" /* default */].CLICK_EVENT + item;
} else {
// 合法
return item;
}
});
} else {
tmpTriggers = null;
}
return tmpTriggers && tmpTriggers.length > 0 ? tmpTriggers : null;
}
/**
* 提取出class和style
* @param {*} item
* @returns {class和style}
*/
function parseClassStyle(item) {
var needParse = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
var newItem = {};
if (needParse && parse["a" /* default */].isEsOrFunc(item.class)) {
newItem.class = null;
newItem.__rawClass = parse["a" /* default */].newEsFuncion(item.class);
} else {
if (item.class) {
newItem.class = utils["a" /* default */].deepCopy(item.class);
}
}
if (needParse && parse["a" /* default */].isEsOrFunc(item.style)) {
newItem.style = null;
newItem.__rawStyle = parse["a" /* default */].newEsFuncion(item.style);
} else {
if (utils["a" /* default */].isObj(item.style) && keys_default()(item.style).length) {
newItem.style = utils["a" /* default */].deepCopy(item.style);
}
}
return newItem;
}
/**
* 整理出"表单"组件需要监听的外部事件
*/
function fetchActionEvent(actions) {
var emitEvents = [];
var nativeEvents = [];
var triggerList, nativeName; // 自定义事件
if (actions) {
actions.forEach(function (actionItem) {
triggerList = actionItem.trigger;
triggerList.forEach(function (triggerItem) {
nativeName = getNativeName(triggerItem);
if (nativeName) {
// .native监听
nativeEvents.push(nativeName);
} else {
emitEvents.push(triggerItem);
}
});
});
}
return {
__emitEvents: emitEvents.length ? utils["a" /* default */].unique(emitEvents) : null,
__nativeEvents: nativeEvents.length ? utils["a" /* default */].unique(nativeEvents) : null
};
}
/**
* 提取是否为.native事件
* @param {*} eventName
*/
function getNativeName(eventName) {
var dotNative = "." + constant["a" /* default */].ADJ_NATIVE;
var lastIndex = eventName.lastIndexOf(dotNative);
if (lastIndex != -1 && eventName.substr(lastIndex) === dotNative) {
// .native监听
var nativeName = eventName.substr(0, lastIndex);
if (nativeName) {
return nativeName;
} else {
return false; //因为eventName是经过处理的,不会出现点在前面,所以不会进入这里
}
} else {
return false;
}
}
/**
* 解析项label和项组件的对齐方式
*/
function parseAlign(align) {
var defaultVal = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "left";
var aligns = ["left", "center", "right"];
if (aligns.includes(align)) {
return align;
}
return defaultVal;
}
/**
* 解析项label和项组件的在弹性布局中的占位情况
*/
function parseFlex(flex, size) {
var flexs = ["self", "full"];
if (flexs.includes(flex)) {
return flex;
} // 兼容一下之前的东西
var sizes = ["fixed", "auto"];
var sizeIndex = sizes.indexOf(size);
if (sizeIndex >= 0) {
console.warn('label.size and component.size ["fixed", "auto"]已经舍弃了,请使用flex ["self", "full"]');
return flexs[sizeIndex];
}
return false;
}
/**
* 解析组件属性
*/
function parseComProps(props, excludeKeys) {
var needParse = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
var newProps = {},
rawProps = {};
var staticNames = [];
if (!utils["a" /* default */].isObj(props)) {
props = {};
}
var hasEsFunc = false; // var PREFIXS = constant.PREFIX_STATIC_FUNC;
var realKey, newRealKey;
var staticKey, isStatic;
var value, newValue;
for (var key in props) {
realKey = key; // 会保留空格的
staticKey = needParse ? parse["a" /* default */].getStaticKey(realKey) : false; // 取静态key,不是返回false
// console.log(staticKey);
isStatic = staticKey !== false ? true : false;
if (isStatic) {
realKey = staticKey;
}
if (!realKey.trim()) {
// 全空,不必理会
break;
}
newRealKey = utils["a" /* default */].vueCamelCase(realKey);
if (excludeKeys.includes(newRealKey)) {
// 存在不能包括的属性,不必理会
break;
}
value = props[key];
if (needParse) {
if (!isStatic && parse["a" /* default */].isEsOrFunc(props[key])) {
// 不是静态且需要转化
hasEsFunc = true;
newValue = parse["a" /* default */].newEsFuncion(value);
newProps[newRealKey] = newValue;
rawProps[newRealKey] = newValue;
} else if (!isStatic || !utils["a" /* default */].isFunc(value)) {
// 不是静态或是(静态,其值不是函数),保持原样
newProps[newRealKey] = value;
rawProps[newRealKey] = value;
} else {
// 是静态属性、值是函数
newProps[newRealKey] = value;
rawProps[newRealKey] = value; // 保持前缀,因为解析需要用到;为什么要这样
staticNames.push(newRealKey); // 记录下来
}
} else {
// 无需要解析
newProps[newRealKey] = value;
rawProps[newRealKey] = value;
}
}
if (hasEsFunc) {
for (var tmpkey in newProps) {
newProps[tmpkey] = null;
}
} else {
rawProps = {};
}
rawProps = keys_default()(rawProps).length > 0 ? rawProps : false;
return {
new: newProps,
raw: rawProps,
staticNames: staticNames.length ? staticNames : false
};
}
/**
* 解析指令
*/
function parseDirectives(directives) {
var needParse = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
var newDirectives = [],
rawDirectives = [];
if (!utils["a" /* default */].isArr(directives)) {
directives = [directives];
}
var hasEsFunc = false; // 转化为数组了
directives.forEach(function (directiveItem) {
var directive;
if (utils["a" /* default */].isStr(directiveItem)) {
directive = {
name: directiveItem
};
} else if (!utils["a" /* default */].isObj(directiveItem)) {
// 不合法,去掉
return false;
} else {
directive = directiveItem;
} // 全部转成对象了
var name, value, expression, arg, modifiers;
name = directive.name;
var prefix = "v-";
if (utils["a" /* default */].isStr(name)) {
name = name.trim();
if (name.indexOf(prefix) === 0) {
name = name.substr(prefix.length);
}
} else {
name = false;
} // 指令名合法
if (name) {
expression = utils["a" /* default */].isStr(directive.expression) ? directive.expression.trim() : undefined;
expression = expression ? expression : undefined;
arg = utils["a" /* default */].isStr(directive.arg) ? directive.arg.trim() : undefined;
arg = arg ? arg : undefined;
modifiers = utils["a" /* default */].isObj(directive.modifiers) ? utils["a" /* default */].deepCopy(directive.modifiers) : {};
if (needParse && parse["a" /* default */].isEsOrFunc(directive.value)) {
hasEsFunc = true;
value = parse["a" /* default */].newEsFuncion(directive.value);
} else {
value = utils["a" /* default */].deepCopy(directive.value);
}
var rawDirective = {
name: name,
value: value,
expression: expression,
arg: arg,
modifiers: modifiers
};
rawDirectives.push(rawDirective);
}
});
if (hasEsFunc) {
rawDirectives.forEach(function (rawDirective) {
var newDirective = {};
assign_default()(newDirective, rawDirective);
newDirective.value = null;
newDirectives.push(newDirective);
});
} else {
newDirectives = rawDirectives;
rawDirectives = false;
}
newDirectives = newDirectives.length > 0 ? newDirectives : false;
return {
new: newDirectives,
raw: rawDirectives
};
}
/**
* 解析scopedSlots
*/
function parseScopedSlots(scopedSlots, myPathKey) {
var needParse = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
var newScopedSlots = {};
var newSlots;
var hasRuntime = false; // 根据vue源代码, VNode是不会被劫持的
if (utils["a" /* default */].isVNode(scopedSlots)) {
// 要先判断VNode,因为VNode也属于Object
console.warn("插槽暂不支持直接配置虚拟节点,虚拟节点必须用函数包含并返回。此配置将忽略!");
} else if (utils["a" /* default */].isArr(scopedSlots)) {
newSlots = checkSlotArr(scopedSlots, "scopedSlots", myPathKey);
if (newSlots.length) {
newScopedSlots.default = newSlots;
}
} else if (!utils["a" /* default */].isObj(scopedSlots) && isSlotType(scopedSlots)) {
newScopedSlots.default = scopedSlots;
if (utils["a" /* default */].isFunc(scopedSlots)) {
hasRuntime = true;
}
} else if (utils["a" /* default */].isObj(scopedSlots) && keys_default()(scopedSlots).length > 0) {
for (var key in scopedSlots) {
var value = scopedSlots[key];
if (utils["a" /* default */].isArr(value)) {
newSlots = checkSlotArr(value, key, myPathKey);
if (newSlots.length) {
newScopedSlots[key] = newSlots;
}
} else if (isSlotType(value)) {
if (utils["a" /* default */].isObj(value)) {
newScopedSlots[key] = parseComponent(value, myPathKey + " > scopedSlots > " + key, true, needParse);
} else {
newScopedSlots[key] = value;
}
if (utils["a" /* default */].isFunc(value)) {
hasRuntime = true;
}
} else {
if (!(utils["a" /* default */].isUndef(value) || utils["a" /* default */].isNull(value))) {
console.warn("插槽(" + myPathKey + " > " + key + ")的值不合法,将忽略(值必须是虚拟节点、函数、数字、字符串、布尔型)");
}
}
}
} else {
if (!(utils["a" /* default */].isUndef(scopedSlots) || utils["a" /* default */].isNull(scopedSlots))) {
console.warn("插槽(" + myPathKey + " > " + key + ")的值不合法,将忽略(值必须是虚拟节点、函数、数字、字符串、布尔型)");
}
}
return keys_default()(newScopedSlots).length > 0 ? {
scopedSlots: newScopedSlots,
hasRuntime: hasRuntime
} : undefined;
}
function checkSlotArr(slots, key, myPathKey) {
var newSlots = [];
slots.forEach(function (slot, index) {
if (utils["a" /* default */].isVNode()) {
console.warn("插槽暂不支持直接配置,请用函数包含并返回。此配置将忽略。");
} else if (utils["a" /* default */].isFunc(slot)) {
throw "插槽(" + myPathKey + " > " + key + ")的数组不能存在函数,但可以用函数返回数组";
} else if (isSlotType(slot)) {
if (utils["a" /* default */].isObj(slot)) {
// 是一个标准的配置型组件
var newComponent = parseComponent(slot, myPathKey + " > scopedSlots > " + key, true);
if (newComponent) {
newSlots.push(newComponent);
}
} else {
newSlots.push(slot);
}
} else {
console.warn("插槽(" + myPathKey + " > " + key + ")中的数组存在(第" + (index + 1) + "个)不合法的,将忽略(数组中的值必须是虚拟节点、数字、字符串、布尔型)");
}
});
return newSlots;
}
/**
* 是否是scopedSlot支持的类型
* @param {*} value
*/
function isSlotType(value) {
var isValidName = false;
if (utils["a" /* default */].isObj(value)) {
// 判断对象是否正常的组件配置
var name = utils["a" /* default */].isStr(value.name) ? value.name.trim() : value.name;
if (name) {
isValidName = true;
} else {
isValidName = false;
}
}
return isValidName || utils["a" /* default */].isFunc(value) || utils["a" /* default */].isStr(value) || utils["a" /* default */].isNum(value) || utils["a" /* default */].isBool(value) || false;
}
/***/ }),
/***/ "45f2":
/***/ (function(module, exports, __webpack_require__) {
var def = __webpack_require__("d9f6").f;
var has = __webpack_require__("07e3");
var TAG = __webpack_require__("5168")('toStringTag');
module.exports = function (it, tag, stat) {
if (it && !has(it = stat ? it : it.prototype, TAG)) def(it, TAG, { configurable: true, value: tag });
};
/***/ }),
/***/ "4630":
/***/ (function(module, exports) {
module.exports = function (bitmap, value) {
return {
enumerable: !(bitmap & 1),
configurable: !(bitmap & 2),
writable: !(bitmap & 4),
value: value
};
};
/***/ }),
/***/ "481b":
/***/ (function(module, exports) {
module.exports = {};
/***/ }),
/***/ "4917":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var anObject = __webpack_require__("cb7c");
var toLength = __webpack_require__("9def");
var advanceStringIndex = __webpack_require__("0390");
var regExpExec = __webpack_require__("5f1b");
// @@match logic
__webpack_require__("214f")('match', 1, function (defined, MATCH, $match, maybeCallNative) {
return [
// `String.prototype.match` method
// https://tc39.github.io/ecma262/#sec-string.prototype.match
function match(regexp) {
var O = defined(this);
var fn = regexp == undefined ? undefined : regexp[MATCH];
return fn !== undefined ? fn.call(regexp, O) : new RegExp(regexp)[MATCH](String(O));
},
// `RegExp.prototype[@@match]` method
// https://tc39.github.io/ecma262/#sec-regexp.prototype-@@match
function (regexp) {
var res = maybeCallNative($match, regexp, this);
if (res.done) return res.value;
var rx = anObject(regexp);
var S = String(this);
if (!rx.global) return regExpExec(rx, S);
var fullUnicode = rx.unicode;
rx.lastIndex = 0;
var A = [];
var n = 0;
var result;
while ((result = regExpExec(rx, S)) !== null) {
var matchStr = String(result[0]);
A[n] = matchStr;
if (matchStr === '') rx.lastIndex = advanceStringIndex(S, toLength(rx.lastIndex), fullUnicode);
n++;
}
return n === 0 ? null : A;
}
];
});
/***/ }),
/***/ "499e":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
__webpack_require__.r(__webpack_exports__);
// CONCATENATED MODULE: ./node_modules/vue-style-loader/lib/listToStyles.js
/**
* Translates the list format produced by css-loader into something
* easier to manipulate.
*/
function listToStyles (parentId, list) {
var styles = []
var newStyles = {}
for (var i = 0; i < list.length; i++) {
var item = list[i]
var id = item[0]
var css = item[1]
var media = item[2]
var sourceMap = item[3]
var part = {
id: parentId + ':' + i,
css: css,
media: media,
sourceMap: sourceMap
}
if (!newStyles[id]) {
styles.push(newStyles[id] = { id: id, parts: [part] })
} else {
newStyles[id].parts.push(part)
}
}
return styles
}
// CONCATENATED MODULE: ./node_modules/vue-style-loader/lib/addStylesClient.js
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return addStylesClient; });
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Tobias Koppers @sokra
Modified by Evan You @yyx990803
*/
var hasDocument = typeof document !== 'undefined'
if (typeof DEBUG !== 'undefined' && DEBUG) {
if (!hasDocument) {
throw new Error(
'vue-style-loader cannot be used in a non-browser environment. ' +
"Use { target: 'node' } in your Webpack config to indicate a server-rendering environment."
) }
}
/*
type StyleObject = {
id: number;
parts: Array<StyleObjectPart>
}
type StyleObjectPart = {
css: string;
media: string;
sourceMap: ?string
}
*/
var stylesInDom = {/*
[id: number]: {
id: number,
refs: number,
parts: Array<(obj?: StyleObjectPart) => void>
}
*/}
var head = hasDocument && (document.head || document.getElementsByTagName('head')[0])
var singletonElement = null
var singletonCounter = 0
var isProduction = false
var noop = function () {}
var options = null
var ssrIdKey = 'data-vue-ssr-id'
// Force single-tag solution on IE6-9, which has a hard limit on the # of <style>
// tags it will allow on a page
var isOldIE = typeof navigator !== 'undefined' && /msie [6-9]\b/.test(navigator.userAgent.toLowerCase())
function addStylesClient (parentId, list, _isProduction, _options) {
isProduction = _isProduction
options = _options || {}
var styles = listToStyles(parentId, list)
addStylesToDom(styles)
return function update (newList) {
var mayRemove = []
for (var i = 0; i < styles.length; i++) {
var item = styles[i]
var domStyle = stylesInDom[item.id]
domStyle.refs--
mayRemove.push(domStyle)
}
if (newList) {
styles = listToStyles(parentId, newList)
addStylesToDom(styles)
} else {
styles = []
}
for (var i = 0; i < mayRemove.length; i++) {
var domStyle = mayRemove[i]
if (domStyle.refs === 0) {
for (var j = 0; j < domStyle.parts.length; j++) {
domStyle.parts[j]()
}
delete stylesInDom[domStyle.id]
}
}
}
}
function addStylesToDom (styles /* Array<StyleObject> */) {
for (var i = 0; i < styles.length; i++) {
var item = styles[i]
var domStyle = stylesInDom[item.id]
if (domStyle) {
domStyle.refs++
for (var j = 0; j < domStyle.parts.length; j++) {
domStyle.parts[j](item.parts[j])
}
for (; j < item.parts.length; j++) {
domStyle.parts.push(addStyle(item.parts[j]))
}
if (domStyle.parts.length > item.parts.length) {
domStyle.parts.length = item.parts.length
}
} else {
var parts = []
for (var j = 0; j < item.parts.length; j++) {
parts.push(addStyle(item.parts[j]))
}
stylesInDom[item.id] = { id: item.id, refs: 1, parts: parts }
}
}
}
function createStyleElement () {
var styleElement = document.createElement('style')
styleElement.type = 'text/css'
head.appendChild(styleElement)
return styleElement
}
function addStyle (obj /* StyleObjectPart */) {
var update, remove
var styleElement = document.querySelector('style[' + ssrIdKey + '~="' + obj.id + '"]')
if (styleElement) {
if (isProduction) {
// has SSR styles and in production mode.
// simply do nothing.
return noop
} else {
// has SSR styles but in dev mode.
// for some reason Chrome can't handle source map in server-rendered
// style tags - source maps in <style> only works if the style tag is
// created and inserted dynamically. So we remove the server rendered
// styles and inject new ones.
styleElement.parentNode.removeChild(styleElement)
}
}
if (isOldIE) {
// use singleton mode for IE9.
var styleIndex = singletonCounter++
styleElement = singletonElement || (singletonElement = createStyleElement())
update = applyToSingletonTag.bind(null, styleElement, styleIndex, false)
remove = applyToSingletonTag.bind(null, styleElement, styleIndex, true)
} else {
// use multi-style-tag mode in all other cases
styleElement = createStyleElement()
update = applyToTag.bind(null, styleElement)
remove = function () {
styleElement.parentNode.removeChild(styleElement)
}
}
update(obj)
return function updateStyle (newObj /* StyleObjectPart */) {
if (newObj) {
if (newObj.css === obj.css &&
newObj.media === obj.media &&
newObj.sourceMap === obj.sourceMap) {
return
}
update(obj = newObj)
} else {
remove()
}
}
}
var replaceText = (function () {
var textStore = []
return function (index, replacement) {
textStore[index] = replacement
return textStore.filter(Boolean).join('\n')
}
})()
function applyToSingletonTag (styleElement, index, remove, obj) {
var css = remove ? '' : obj.css
if (styleElement.styleSheet) {
styleElement.styleSheet.cssText = replaceText(index, css)
} else {
var cssNode = document.createTextNode(css)
var childNodes = styleElement.childNodes
if (childNodes[index]) styleElement.removeChild(childNodes[index])
if (childNodes.length) {
styleElement.insertBefore(cssNode, childNodes[index])
} else {
styleElement.appendChild(cssNode)
}
}
}
function applyToTag (styleElement, obj) {
var css = obj.css
var media = obj.media
var sourceMap = obj.sourceMap
if (media) {
styleElement.setAttribute('media', media)
}
if (options.ssrId) {
styleElement.setAttribute(ssrIdKey, obj.id)
}
if (sourceMap) {
// https://developer.chrome.com/devtools/docs/javascript-debugging
// this makes source maps inside style tags work properly in Chrome
css += '\n/*# sourceURL=' + sourceMap.sources[0] + ' */'
// http://stackoverflow.com/a/26603875
css += '\n/*# sourceMappingURL=data:application/json;base64,' + btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))) + ' */'
}
if (styleElement.styleSheet) {
styleElement.styleSheet.cssText = css
} else {
while (styleElement.firstChild) {
styleElement.removeChild(styleElement.firstChild)
}
styleElement.appendChild(document.createTextNode(css))
}
}
/***/ }),
/***/ "49e5":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("75bc");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("4f0063b5", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "4a59":
/***/ (function(module, exports, __webpack_require__) {
var ctx = __webpack_require__("9b43");
var call = __webpack_require__("1fa8");
var isArrayIter = __webpack_require__("33a4");
var anObject = __webpack_require__("cb7c");
var toLength = __webpack_require__("9def");
var getIterFn = __webpack_require__("27ee");
var BREAK = {};
var RETURN = {};
var exports = module.exports = function (iterable, entries, fn, that, ITERATOR) {
var iterFn = ITERATOR ? function () { return iterable; } : getIterFn(iterable);
var f = ctx(fn, that, entries ? 2 : 1);
var index = 0;
var length, step, iterator, result;
if (typeof iterFn != 'function') throw TypeError(iterable + ' is not iterable!');
// fast case for arrays with default iterator
if (isArrayIter(iterFn)) for (length = toLength(iterable.length); length > index; index++) {
result = entries ? f(anObject(step = iterable[index])[0], step[1]) : f(iterable[index]);
if (result === BREAK || result === RETURN) return result;
} else for (iterator = iterFn.call(iterable); !(step = iterator.next()).done;) {
result = call(iterator, f, step.value, entries);
if (result === BREAK || result === RETURN) return result;
}
};
exports.BREAK = BREAK;
exports.RETURN = RETURN;
/***/ }),
/***/ "4bf8":
/***/ (function(module, exports, __webpack_require__) {
// 7.1.13 ToObject(argument)
var defined = __webpack_require__("be13");
module.exports = function (it) {
return Object(defined(it));
};
/***/ }),
/***/ "4ee1":
/***/ (function(module, exports, __webpack_require__) {
var ITERATOR = __webpack_require__("5168")('iterator');
var SAFE_CLOSING = false;
try {
var riter = [7][ITERATOR]();
riter['return'] = function () { SAFE_CLOSING = true; };
// eslint-disable-next-line no-throw-literal
Array.from(riter, function () { throw 2; });
} catch (e) { /* empty */ }
module.exports = function (exec, skipClosing) {
if (!skipClosing && !SAFE_CLOSING) return false;
var safe = false;
try {
var arr = [7];
var iter = arr[ITERATOR]();
iter.next = function () { return { done: safe = true }; };
arr[ITERATOR] = function () { return iter; };
exec(arr);
} catch (e) { /* empty */ }
return safe;
};
/***/ }),
/***/ "4ee3":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("bab9");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("01942441", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "50ed":
/***/ (function(module, exports) {
module.exports = function (done, value) {
return { value: value, done: !!done };
};
/***/ }),
/***/ "5100":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_tabs_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("be1e");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_tabs_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_tabs_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_tabs_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "5147":
/***/ (function(module, exports, __webpack_require__) {
var MATCH = __webpack_require__("2b4c")('match');
module.exports = function (KEY) {
var re = /./;
try {
'/./'[KEY](re);
} catch (e) {
try {
re[MATCH] = false;
return !'/./'[KEY](re);
} catch (f) { /* empty */ }
} return true;
};
/***/ }),
/***/ "5168":
/***/ (function(module, exports, __webpack_require__) {
var store = __webpack_require__("dbdb")('wks');
var uid = __webpack_require__("62a0");
var Symbol = __webpack_require__("e53d").Symbol;
var USE_SYMBOL = typeof Symbol == 'function';
var $exports = module.exports = function (name) {
return store[name] || (store[name] =
USE_SYMBOL && Symbol[name] || (USE_SYMBOL ? Symbol : uid)('Symbol.' + name));
};
$exports.store = store;
/***/ }),
/***/ "5176":
/***/ (function(module, exports, __webpack_require__) {
module.exports = __webpack_require__("51b6");
/***/ }),
/***/ "51b6":
/***/ (function(module, exports, __webpack_require__) {
__webpack_require__("a3c3");
module.exports = __webpack_require__("584a").Object.assign;
/***/ }),
/***/ "520a":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var regexpFlags = __webpack_require__("0bfb");
var nativeExec = RegExp.prototype.exec;
// This always refers to the native implementation, because the
// String#replace polyfill uses ./fix-regexp-well-known-symbol-logic.js,
// which loads this file before patching the method.
var nativeReplace = String.prototype.replace;
var patchedExec = nativeExec;
var LAST_INDEX = 'lastIndex';
var UPDATES_LAST_INDEX_WRONG = (function () {
var re1 = /a/,
re2 = /b*/g;
nativeExec.call(re1, 'a');
nativeExec.call(re2, 'a');
return re1[LAST_INDEX] !== 0 || re2[LAST_INDEX] !== 0;
})();
// nonparticipating capturing group, copied from es5-shim's String#split patch.
var NPCG_INCLUDED = /()??/.exec('')[1] !== undefined;
var PATCH = UPDATES_LAST_INDEX_WRONG || NPCG_INCLUDED;
if (PATCH) {
patchedExec = function exec(str) {
var re = this;
var lastIndex, reCopy, match, i;
if (NPCG_INCLUDED) {
reCopy = new RegExp('^' + re.source + '$(?!\\s)', regexpFlags.call(re));
}
if (UPDATES_LAST_INDEX_WRONG) lastIndex = re[LAST_INDEX];
match = nativeExec.call(re, str);
if (UPDATES_LAST_INDEX_WRONG && match) {
re[LAST_INDEX] = re.global ? match.index + match[0].length : lastIndex;
}
if (NPCG_INCLUDED && match && match.length > 1) {
// Fix browsers whose `exec` methods don't consistently return `undefined`
// for NPCG, like IE8. NOTE: This doesn' work for /(.?)?/
// eslint-disable-next-line no-loop-func
nativeReplace.call(match[0], reCopy, function () {
for (i = 1; i < arguments.length - 2; i++) {
if (arguments[i] === undefined) match[i] = undefined;
}
});
}
return match;
};
}
module.exports = patchedExec;
/***/ }),
/***/ "522e":
/***/ (function(module, exports, __webpack_require__) {
// 19.1.2.5 Object.freeze(O)
var isObject = __webpack_require__("f772");
var meta = __webpack_require__("ebfd").onFreeze;
__webpack_require__("ce7e")('freeze', function ($freeze) {
return function freeze(it) {
return $freeze && isObject(it) ? $freeze(meta(it)) : it;
};
});
/***/ }),
/***/ "52a7":
/***/ (function(module, exports) {
exports.f = {}.propertyIsEnumerable;
/***/ }),
/***/ "53e2":
/***/ (function(module, exports, __webpack_require__) {
// 19.1.2.9 / 15.2.3.2 Object.getPrototypeOf(O)
var has = __webpack_require__("07e3");
var toObject = __webpack_require__("241e");
var IE_PROTO = __webpack_require__("5559")('IE_PROTO');
var ObjectProto = Object.prototype;
module.exports = Object.getPrototypeOf || function (O) {
O = toObject(O);
if (has(O, IE_PROTO)) return O[IE_PROTO];
if (typeof O.constructor == 'function' && O instanceof O.constructor) {
return O.constructor.prototype;
} return O instanceof Object ? ObjectProto : null;
};
/***/ }),
/***/ "549b":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var ctx = __webpack_require__("d864");
var $export = __webpack_require__("63b6");
var toObject = __webpack_require__("241e");
var call = __webpack_require__("b0dc");
var isArrayIter = __webpack_require__("3702");
var toLength = __webpack_require__("b447");
var createProperty = __webpack_require__("20fd");
var getIterFn = __webpack_require__("7cd6");
$export($export.S + $export.F * !__webpack_require__("4ee1")(function (iter) { Array.from(iter); }), 'Array', {
// 22.1.2.1 Array.from(arrayLike, mapfn = undefined, thisArg = undefined)
from: function from(arrayLike /* , mapfn = undefined, thisArg = undefined */) {
var O = toObject(arrayLike);
var C = typeof this == 'function' ? this : Array;
var aLen = arguments.length;
var mapfn = aLen > 1 ? arguments[1] : undefined;
var mapping = mapfn !== undefined;
var index = 0;
var iterFn = getIterFn(O);
var length, result, step, iterator;
if (mapping) mapfn = ctx(mapfn, aLen > 2 ? arguments[2] : undefined, 2);
// if object isn't iterable or it's array with default iterator - use simple case
if (iterFn != undefined && !(C == Array && isArrayIter(iterFn))) {
for (iterator = iterFn.call(O), result = new C(); !(step = iterator.next()).done; index++) {
createProperty(result, index, mapping ? call(iterator, mapfn, [step.value, index], true) : step.value);
}
} else {
length = toLength(O.length);
for (result = new C(length); length > index; index++) {
createProperty(result, index, mapping ? mapfn(O[index], index) : O[index]);
}
}
result.length = index;
return result;
}
});
/***/ }),
/***/ "54a1":
/***/ (function(module, exports, __webpack_require__) {
__webpack_require__("6c1c");
__webpack_require__("1654");
module.exports = __webpack_require__("95d5");
/***/ }),
/***/ "551c":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var LIBRARY = __webpack_require__("2d00");
var global = __webpack_require__("7726");
var ctx = __webpack_require__("9b43");
var classof = __webpack_require__("23c6");
var $export = __webpack_require__("5ca1");
var isObject = __webpack_require__("d3f4");
var aFunction = __webpack_require__("d8e8");
var anInstance = __webpack_require__("f605");
var forOf = __webpack_require__("4a59");
var speciesConstructor = __webpack_require__("ebd6");
var task = __webpack_require__("1991").set;
var microtask = __webpack_require__("8079")();
var newPromiseCapabilityModule = __webpack_require__("a5b8");
var perform = __webpack_require__("9c80");
var userAgent = __webpack_require__("a25f");
var promiseResolve = __webpack_require__("bcaa");
var PROMISE = 'Promise';
var TypeError = global.TypeError;
var process = global.process;
var versions = process && process.versions;
var v8 = versions && versions.v8 || '';
var $Promise = global[PROMISE];
var isNode = classof(process) == 'process';
var empty = function () { /* empty */ };
var Internal, newGenericPromiseCapability, OwnPromiseCapability, Wrapper;
var newPromiseCapability = newGenericPromiseCapability = newPromiseCapabilityModule.f;
var USE_NATIVE = !!function () {
try {
// correct subclassing with @@species support
var promise = $Promise.resolve(1);
var FakePromise = (promise.constructor = {})[__webpack_require__("2b4c")('species')] = function (exec) {
exec(empty, empty);
};
// unhandled rejections tracking support, NodeJS Promise without it fails @@species test
return (isNode || typeof PromiseRejectionEvent == 'function')
&& promise.then(empty) instanceof FakePromise
// v8 6.6 (Node 10 and Chrome 66) have a bug with resolving custom thenables
// https://bugs.chromium.org/p/chromium/issues/detail?id=830565
// we can't detect it synchronously, so just check versions
&& v8.indexOf('6.6') !== 0
&& userAgent.indexOf('Chrome/66') === -1;
} catch (e) { /* empty */ }
}();
// helpers
var isThenable = function (it) {
var then;
return isObject(it) && typeof (then = it.then) == 'function' ? then : false;
};
var notify = function (promise, isReject) {
if (promise._n) return;
promise._n = true;
var chain = promise._c;
microtask(function () {
var value = promise._v;
var ok = promise._s == 1;
var i = 0;
var run = function (reaction) {
var handler = ok ? reaction.ok : reaction.fail;
var resolve = reaction.resolve;
var reject = reaction.reject;
var domain = reaction.domain;
var result, then, exited;
try {
if (handler) {
if (!ok) {
if (promise._h == 2) onHandleUnhandled(promise);
promise._h = 1;
}
if (handler === true) result = value;
else {
if (domain) domain.enter();
result = handler(value); // may throw
if (domain) {
domain.exit();
exited = true;
}
}
if (result === reaction.promise) {
reject(TypeError('Promise-chain cycle'));
} else if (then = isThenable(result)) {
then.call(result, resolve, reject);
} else resolve(result);
} else reject(value);
} catch (e) {
if (domain && !exited) domain.exit();
reject(e);
}
};
while (chain.length > i) run(chain[i++]); // variable length - can't use forEach
promise._c = [];
promise._n = false;
if (isReject && !promise._h) onUnhandled(promise);
});
};
var onUnhandled = function (promise) {
task.call(global, function () {
var value = promise._v;
var unhandled = isUnhandled(promise);
var result, handler, console;
if (unhandled) {
result = perform(function () {
if (isNode) {
process.emit('unhandledRejection', value, promise);
} else if (handler = global.onunhandledrejection) {
handler({ promise: promise, reason: value });
} else if ((console = global.console) && console.error) {
console.error('Unhandled promise rejection', value);
}
});
// Browsers should not trigger `rejectionHandled` event if it was handled here, NodeJS - should
promise._h = isNode || isUnhandled(promise) ? 2 : 1;
} promise._a = undefined;
if (unhandled && result.e) throw result.v;
});
};
var isUnhandled = function (promise) {
return promise._h !== 1 && (promise._a || promise._c).length === 0;
};
var onHandleUnhandled = function (promise) {
task.call(global, function () {
var handler;
if (isNode) {
process.emit('rejectionHandled', promise);
} else if (handler = global.onrejectionhandled) {
handler({ promise: promise, reason: promise._v });
}
});
};
var $reject = function (value) {
var promise = this;
if (promise._d) return;
promise._d = true;
promise = promise._w || promise; // unwrap
promise._v = value;
promise._s = 2;
if (!promise._a) promise._a = promise._c.slice();
notify(promise, true);
};
var $resolve = function (value) {
var promise = this;
var then;
if (promise._d) return;
promise._d = true;
promise = promise._w || promise; // unwrap
try {
if (promise === value) throw TypeError("Promise can't be resolved itself");
if (then = isThenable(value)) {
microtask(function () {
var wrapper = { _w: promise, _d: false }; // wrap
try {
then.call(value, ctx($resolve, wrapper, 1), ctx($reject, wrapper, 1));
} catch (e) {
$reject.call(wrapper, e);
}
});
} else {
promise._v = value;
promise._s = 1;
notify(promise, false);
}
} catch (e) {
$reject.call({ _w: promise, _d: false }, e); // wrap
}
};
// constructor polyfill
if (!USE_NATIVE) {
// 25.4.3.1 Promise(executor)
$Promise = function Promise(executor) {
anInstance(this, $Promise, PROMISE, '_h');
aFunction(executor);
Internal.call(this);
try {
executor(ctx($resolve, this, 1), ctx($reject, this, 1));
} catch (err) {
$reject.call(this, err);
}
};
// eslint-disable-next-line no-unused-vars
Internal = function Promise(executor) {
this._c = []; // <- awaiting reactions
this._a = undefined; // <- checked in isUnhandled reactions
this._s = 0; // <- state
this._d = false; // <- done
this._v = undefined; // <- value
this._h = 0; // <- rejection state, 0 - default, 1 - handled, 2 - unhandled
this._n = false; // <- notify
};
Internal.prototype = __webpack_require__("dcbc")($Promise.prototype, {
// 25.4.5.3 Promise.prototype.then(onFulfilled, onRejected)
then: function then(onFulfilled, onRejected) {
var reaction = newPromiseCapability(speciesConstructor(this, $Promise));
reaction.ok = typeof onFulfilled == 'function' ? onFulfilled : true;
reaction.fail = typeof onRejected == 'function' && onRejected;
reaction.domain = isNode ? process.domain : undefined;
this._c.push(reaction);
if (this._a) this._a.push(reaction);
if (this._s) notify(this, false);
return reaction.promise;
},
// 25.4.5.1 Promise.prototype.catch(onRejected)
'catch': function (onRejected) {
return this.then(undefined, onRejected);
}
});
OwnPromiseCapability = function () {
var promise = new Internal();
this.promise = promise;
this.resolve = ctx($resolve, promise, 1);
this.reject = ctx($reject, promise, 1);
};
newPromiseCapabilityModule.f = newPromiseCapability = function (C) {
return C === $Promise || C === Wrapper
? new OwnPromiseCapability(C)
: newGenericPromiseCapability(C);
};
}
$export($export.G + $export.W + $export.F * !USE_NATIVE, { Promise: $Promise });
__webpack_require__("7f20")($Promise, PROMISE);
__webpack_require__("7a56")(PROMISE);
Wrapper = __webpack_require__("8378")[PROMISE];
// statics
$export($export.S + $export.F * !USE_NATIVE, PROMISE, {
// 25.4.4.5 Promise.reject(r)
reject: function reject(r) {
var capability = newPromiseCapability(this);
var $$reject = capability.reject;
$$reject(r);
return capability.promise;
}
});
$export($export.S + $export.F * (LIBRARY || !USE_NATIVE), PROMISE, {
// 25.4.4.6 Promise.resolve(x)
resolve: function resolve(x) {
return promiseResolve(LIBRARY && this === Wrapper ? $Promise : this, x);
}
});
$export($export.S + $export.F * !(USE_NATIVE && __webpack_require__("5cc5")(function (iter) {
$Promise.all(iter)['catch'](empty);
})), PROMISE, {
// 25.4.4.1 Promise.all(iterable)
all: function all(iterable) {
var C = this;
var capability = newPromiseCapability(C);
var resolve = capability.resolve;
var reject = capability.reject;
var result = perform(function () {
var values = [];
var index = 0;
var remaining = 1;
forOf(iterable, false, function (promise) {
var $index = index++;
var alreadyCalled = false;
values.push(undefined);
remaining++;
C.resolve(promise).then(function (value) {
if (alreadyCalled) return;
alreadyCalled = true;
values[$index] = value;
--remaining || resolve(values);
}, reject);
});
--remaining || resolve(values);
});
if (result.e) reject(result.v);
return capability.promise;
},
// 25.4.4.4 Promise.race(iterable)
race: function race(iterable) {
var C = this;
var capability = newPromiseCapability(C);
var reject = capability.reject;
var result = perform(function () {
forOf(iterable, false, function (promise) {
C.resolve(promise).then(capability.resolve, reject);
});
});
if (result.e) reject(result.v);
return capability.promise;
}
});
/***/ }),
/***/ "5537":
/***/ (function(module, exports, __webpack_require__) {
var core = __webpack_require__("8378");
var global = __webpack_require__("7726");
var SHARED = '__core-js_shared__';
var store = global[SHARED] || (global[SHARED] = {});
(module.exports = function (key, value) {
return store[key] || (store[key] = value !== undefined ? value : {});
})('versions', []).push({
version: core.version,
mode: __webpack_require__("2d00") ? 'pure' : 'global',
copyright: '© 2019 Denis Pushkarev (zloirock.ru)'
});
/***/ }),
/***/ "5559":
/***/ (function(module, exports, __webpack_require__) {
var shared = __webpack_require__("dbdb")('keys');
var uid = __webpack_require__("62a0");
module.exports = function (key) {
return shared[key] || (shared[key] = uid(key));
};
/***/ }),
/***/ "584a":
/***/ (function(module, exports) {
var core = module.exports = { version: '2.6.5' };
if (typeof __e == 'number') __e = core; // eslint-disable-line no-undef
/***/ }),
/***/ "59ad":
/***/ (function(module, exports, __webpack_require__) {
module.exports = __webpack_require__("7be7");
/***/ }),
/***/ "5b0d":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_edit_btns_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("73e7");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_edit_btns_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_edit_btns_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_edit_btns_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "5b4e":
/***/ (function(module, exports, __webpack_require__) {
// false -> Array#indexOf
// true -> Array#includes
var toIObject = __webpack_require__("36c3");
var toLength = __webpack_require__("b447");
var toAbsoluteIndex = __webpack_require__("0fc9");
module.exports = function (IS_INCLUDES) {
return function ($this, el, fromIndex) {
var O = toIObject($this);
var length = toLength(O.length);
var index = toAbsoluteIndex(fromIndex, length);
var value;
// Array#includes uses SameValueZero equality algorithm
// eslint-disable-next-line no-self-compare
if (IS_INCLUDES && el != el) while (length > index) {
value = O[index++];
// eslint-disable-next-line no-self-compare
if (value != value) return true;
// Array#indexOf ignores holes, Array#includes - not
} else for (;length > index; index++) if (IS_INCLUDES || index in O) {
if (O[index] === el) return IS_INCLUDES || index || 0;
} return !IS_INCLUDES && -1;
};
};
/***/ }),
/***/ "5bb4":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_console_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("18d0");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_console_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_console_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_console_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "5ca1":
/***/ (function(module, exports, __webpack_require__) {
var global = __webpack_require__("7726");
var core = __webpack_require__("8378");
var hide = __webpack_require__("32e9");
var redefine = __webpack_require__("2aba");
var ctx = __webpack_require__("9b43");
var PROTOTYPE = 'prototype';
var $export = function (type, name, source) {
var IS_FORCED = type & $export.F;
var IS_GLOBAL = type & $export.G;
var IS_STATIC = type & $export.S;
var IS_PROTO = type & $export.P;
var IS_BIND = type & $export.B;
var target = IS_GLOBAL ? global : IS_STATIC ? global[name] || (global[name] = {}) : (global[name] || {})[PROTOTYPE];
var exports = IS_GLOBAL ? core : core[name] || (core[name] = {});
var expProto = exports[PROTOTYPE] || (exports[PROTOTYPE] = {});
var key, own, out, exp;
if (IS_GLOBAL) source = name;
for (key in source) {
// contains in native
own = !IS_FORCED && target && target[key] !== undefined;
// export native or passed
out = (own ? target : source)[key];
// bind timers to global for call from export context
exp = IS_BIND && own ? ctx(out, global) : IS_PROTO && typeof out == 'function' ? ctx(Function.call, out) : out;
// extend global
if (target) redefine(target, key, out, type & $export.U);
// export
if (exports[key] != out) hide(exports, key, exp);
if (IS_PROTO && expProto[key] != out) expProto[key] = out;
}
};
global.core = core;
// type bitmap
$export.F = 1; // forced
$export.G = 2; // global
$export.S = 4; // static
$export.P = 8; // proto
$export.B = 16; // bind
$export.W = 32; // wrap
$export.U = 64; // safe
$export.R = 128; // real proto method for `library`
module.exports = $export;
/***/ }),
/***/ "5cc5":
/***/ (function(module, exports, __webpack_require__) {
var ITERATOR = __webpack_require__("2b4c")('iterator');
var SAFE_CLOSING = false;
try {
var riter = [7][ITERATOR]();
riter['return'] = function () { SAFE_CLOSING = true; };
// eslint-disable-next-line no-throw-literal
Array.from(riter, function () { throw 2; });
} catch (e) { /* empty */ }
module.exports = function (exec, skipClosing) {
if (!skipClosing && !SAFE_CLOSING) return false;
var safe = false;
try {
var arr = [7];
var iter = arr[ITERATOR]();
iter.next = function () { return { done: safe = true }; };
arr[ITERATOR] = function () { return iter; };
exec(arr);
} catch (e) { /* empty */ }
return safe;
};
/***/ }),
/***/ "5d6b":
/***/ (function(module, exports, __webpack_require__) {
var $parseInt = __webpack_require__("e53d").parseInt;
var $trim = __webpack_require__("a1ce").trim;
var ws = __webpack_require__("e692");
var hex = /^[-+]?0[xX]/;
module.exports = $parseInt(ws + '08') !== 8 || $parseInt(ws + '0x16') !== 22 ? function parseInt(str, radix) {
var string = $trim(String(str), 3);
return $parseInt(string, (radix >>> 0) || (hex.test(string) ? 16 : 10));
} : $parseInt;
/***/ }),
/***/ "5dbc":
/***/ (function(module, exports, __webpack_require__) {
var isObject = __webpack_require__("d3f4");
var setPrototypeOf = __webpack_require__("8b97").set;
module.exports = function (that, target, C) {
var S = target.constructor;
var P;
if (S !== C && typeof S == 'function' && (P = S.prototype) !== C.prototype && isObject(P) && setPrototypeOf) {
setPrototypeOf(that, P);
} return that;
};
/***/ }),
/***/ "5e25":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("ef3b");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("2fec248d", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "5f1b":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var classof = __webpack_require__("23c6");
var builtinExec = RegExp.prototype.exec;
// `RegExpExec` abstract operation
// https://tc39.github.io/ecma262/#sec-regexpexec
module.exports = function (R, S) {
var exec = R.exec;
if (typeof exec === 'function') {
var result = exec.call(R, S);
if (typeof result !== 'object') {
throw new TypeError('RegExp exec method returned something other than an Object or null');
}
return result;
}
if (classof(R) !== 'RegExp') {
throw new TypeError('RegExp#exec called on incompatible receiver');
}
return builtinExec.call(R, S);
};
/***/ }),
/***/ "5f60":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var core_js_modules_es6_regexp_constructor__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("3b2b");
/* harmony import */ var core_js_modules_es6_regexp_constructor__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_regexp_constructor__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var core_js_modules_es6_regexp_replace__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("a481");
/* harmony import */ var core_js_modules_es6_regexp_replace__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_regexp_replace__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var core_js_modules_web_dom_iterable__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__("ac6a");
/* harmony import */ var core_js_modules_web_dom_iterable__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_iterable__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var core_js_modules_es6_regexp_match__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__("4917");
/* harmony import */ var core_js_modules_es6_regexp_match__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_regexp_match__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var core_js_modules_es6_regexp_split__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__("28a5");
/* harmony import */ var core_js_modules_es6_regexp_split__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_regexp_split__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__("4513");
/* harmony import */ var _constant__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__("890a");
/**
* parse.js
*
* Copyright (c) 2019 chengaohe All rights reserved.
*
* 用于解析es语句
*
*/
var parse = {
/**
* 判断是否正确的es语句或函数
* @param {*} scriptTxt
* @param {*} expPrefix
*/
isEsOrFunc: function isEsOrFunc(scriptTxt) {
var expPrefix = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "es:";
if (_utils__WEBPACK_IMPORTED_MODULE_5__[/* default */ "a"].isFunc(scriptTxt)) {
return true;
} else {
return this.isEsScript(scriptTxt, expPrefix);
}
},
getStaticKey: function getStaticKey(key) {
var prefixs = _constant__WEBPACK_IMPORTED_MODULE_6__[/* default */ "a"].PREFIX_STATIC_FUNC;
for (var i = 0; i < prefixs.length; i++) {
var prefix = prefixs[i];
if (key.indexOf(prefix) === 0) {
return key.substr(prefix.length);
}
}
return false;
},
/**
* 判断是否正确的es语句
* @param {*} scriptTxt
* @param {*} expPrefix
*/
isEsScript: function isEsScript(scriptTxt) {
var expPrefix = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "es:";
if (_utils__WEBPACK_IMPORTED_MODULE_5__[/* default */ "a"].isStr(scriptTxt)) {
var esIndex = scriptTxt.indexOf(expPrefix);
if (esIndex === 0) {
var execStr = scriptTxt.substr(expPrefix.length);
if (execStr && execStr.trim()) {
return true;
} else {
return false; // 为空,也不是
}
} else {
return false;
}
} else {
return false;
}
},
/**
* 智能解析脚本
* @param {*} scriptTxt
* @param {*} parseSources
* scriptTxt情况:
* 1. 普通值直接返回
* 2. 函数类型返回执行后的值
*/
smartEsValue: function smartEsValue(scriptTxt, // {
// global = {},
// rootData = {},
// index = -1,
// idxChain = "",
// pathKey = "",
// rootSchema = {},
// isHidden
// } = {}
parseSources) {
if (_utils__WEBPACK_IMPORTED_MODULE_5__[/* default */ "a"].isFunc(scriptTxt)) {
var options;
if (scriptTxt.__esFuncName === _constant__WEBPACK_IMPORTED_MODULE_6__[/* default */ "a"].ES_FUNC_NAME) {
// es: 转过来的函数
options = {
global: parseSources.global,
root: parseSources.rootData,
idxChains: parseSources.idxChain ? parseSources.idxChain.split(",") : [],
index: parseSources.index,
// rootSchema: parseSources.rootSchema,
isHidden: parseSources.isHidden
};
} else {
// 自定义函数
options = {
global: parseSources.global,
rootData: parseSources.rootData,
// 兼容1.7.0以前,不包括1.7.0
root: parseSources.rootData,
idxChain: parseSources.idxChain,
index: parseSources.index,
pathKey: parseSources.pathKey,
$hidden: parseSources.isHidden
};
}
return scriptTxt(options);
} else if (!parse.isEsScript(scriptTxt)) {
return scriptTxt;
} else {
throw "还有es: parse ....: " + scriptTxt;
}
},
/**
* 将es转换成为Function
* @param {*} scriptTxt
* @param {*} expPrefix
*/
newEsFuncion: function newEsFuncion(scriptTxt) {
var expPrefix = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "es:";
var result;
if (parse.isEsScript(scriptTxt)) {
var options;
(function () {
// 索引链变量名,以免用户调用
var varIdxChains = "__esIdxChains" + Math.floor(Math.random() * 99);
options = [{
symbol: "$global",
paramKey: "global"
}, {
symbol: "$root",
paramKey: "root"
}, {
symbol: "$index",
paramKey: "index"
}];
scriptTxt = scriptTxt.substring(expPrefix.length);
scriptTxt = scriptTxt.trim(); // 与isEsScript判断一致
// 解析$hidden
var hiddenPatt = /\{{(\s*\$hidden\()(.+?)(\)\s*}})/gi;
var hiddenResult = null;
var hiddenTargetPiece = "";
var hiddenPathKey = "";
var hiddenFunTxt = "";
var newScriptTxt = "";
var curSliceIndex = 0; // let hasHiddenFun = false;
hiddenResult = hiddenPatt.exec(scriptTxt);
var _loop = function _loop() {
// hasHiddenFun = true; // 有隐藏函数
//若有值,会分成三段 如:["{{$hidden( tt[i].age )}}", "$hidden(", " tt[i].age ", ")}}"]
hiddenTargetPiece = hiddenResult[0];
hiddenPathKey = hiddenResult[2]; // 去掉单双引号和$root若存在
hiddenPathKey = hiddenPathKey.trim();
hiddenPathKey = hiddenPathKey.replace(/^('|")|('|")$/g, "");
hiddenPathKey = hiddenPathKey.trim(); //去掉$root;若存在
hiddenPathKey = hiddenPathKey.replace(/^\$root(\.)?/g, "");
hiddenPathKey = parse.chainPathKey(hiddenPathKey, _constant__WEBPACK_IMPORTED_MODULE_6__[/* default */ "a"].IDX_CHAIN_KEY);
var chainPieces = hiddenPathKey.split(_constant__WEBPACK_IMPORTED_MODULE_6__[/* default */ "a"].IDX_CHAIN_KEY);
var chainPiecesLen = chainPieces.length;
var chainPiecesTempVal = "";
chainPieces.forEach(function (piece, index) {
if (index < chainPiecesLen - 1) {
chainPiecesTempVal += piece + "[' + (".concat(varIdxChains, "[") + index + "]) + ']";
} else {
chainPiecesTempVal += piece;
}
});
hiddenPathKey = chainPiecesTempVal;
hiddenFunTxt = "$hidden('" + hiddenPathKey + "')"; // 后面会进行解析替换
newScriptTxt += scriptTxt.slice(curSliceIndex, hiddenPatt.lastIndex - hiddenTargetPiece.length) + hiddenFunTxt;
curSliceIndex = hiddenPatt.lastIndex;
hiddenResult = hiddenPatt.exec(scriptTxt);
};
while (hiddenResult) {
_loop();
}
newScriptTxt += scriptTxt.slice(curSliceIndex); // 最后的片段
// 假设val为:es: {{$root.persons[i].age}} > 1 && {{$root.persons[i].age}} < 18
var matchs = newScriptTxt.match(/\{{.*?}}/g) || []; // matchs值:["{{$root.persons[i].age}}", "{{$root.persons[i].age}}"]
matchs.forEach(function (mItem) {
// mItem值:"{{$root.persons[i].age}}"
// console.log("1 mItem: ", mItem);
var tmpItem;
var tempVal;
if (mItem.indexOf(_constant__WEBPACK_IMPORTED_MODULE_6__[/* default */ "a"].IDX_CHAIN_KEY) > 0) {
// 数组的,不再转换:让用户自己控制,表达式更加强大
tmpItem = mItem;
tempVal = ""; //找出[i],按顺序说明出处
var pieces = tmpItem.split(_constant__WEBPACK_IMPORTED_MODULE_6__[/* default */ "a"].IDX_CHAIN_KEY);
var piecesLen = pieces.length;
pieces.forEach(function (piece, index) {
if (index < piecesLen - 1) {
tempVal += piece + "[" + varIdxChains + "[" + index + "]]";
} else {
tempVal += piece;
}
}); //替换数据源: 去掉左右两边的分隔符
tempVal = tempVal.replace(/^{{|}}$/g, ""); // console.log("tempVal1: ", tempVal);
} else {
// 一般表达式,旧式写法,就按旧的来,不做改动
tempVal = parse.chainPathKey(mItem, _constant__WEBPACK_IMPORTED_MODULE_6__[/* default */ "a"].IDX_CHAIN_KEY); //替换数据源
options.forEach(function (item) {
tempVal = tempVal.replace(new RegExp("\\{{\\s*\\".concat(item.symbol, "(\\.\\S*)?\\s*}}")), "$".concat(item.paramKey, "$1"));
}); // console.log("tempVal2: ", tempVal);
}
newScriptTxt = newScriptTxt.replace(mItem, tempVal);
});
var prefixScript = "";
options.forEach(function (item) {
prefixScript += "var $".concat(item.paramKey, " = ").concat(_constant__WEBPACK_IMPORTED_MODULE_6__[/* default */ "a"].ES_OPTIONS, ".").concat(item.paramKey, "; ");
});
prefixScript += "var ".concat(varIdxChains, " = ").concat(_constant__WEBPACK_IMPORTED_MODULE_6__[/* default */ "a"].ES_OPTIONS, ".idxChains; ");
prefixScript += "var $hidden = ".concat(_constant__WEBPACK_IMPORTED_MODULE_6__[/* default */ "a"].ES_OPTIONS, ".isHidden; ");
newScriptTxt = prefixScript + " return (" + newScriptTxt + ");"; // console.log("newScriptTxt: ", newScriptTxt);
result = new Function(_constant__WEBPACK_IMPORTED_MODULE_6__[/* default */ "a"].ES_OPTIONS, newScriptTxt);
result.__esFuncName = _constant__WEBPACK_IMPORTED_MODULE_6__[/* default */ "a"].ES_FUNC_NAME;
})();
} else {
result = scriptTxt;
}
return result;
},
/**
* rawRathKey把pathKey转化为标准的链式形式
* 如:base["person"].name => base.person.name
* 小括号会直接掉
* @param {*} rawRathKey
* @param {*} exclude 如[i]不需要解析,它有特定的含义
*/
chainPathKey: function chainPathKey(rawRathKey, exclude) {
var parenthesesReg = /\(|\)/g;
var tmpRathKey = rawRathKey.replace(parenthesesReg, "");
var sumTxt;
if (rawRathKey.indexOf("[") >= 0) {
// 进行解析
var mBracketReg = /\[('|")?(.+?)\1\]/g;
var curExec,
lastIndex = 0;
sumTxt = "";
var numReg = /^\d+$/;
curExec = mBracketReg.exec(tmpRathKey);
while (curExec) {
var fullKey = curExec[0];
var subKey = curExec[2].trim();
sumTxt += tmpRathKey.substr(lastIndex, curExec.index - lastIndex);
if (exclude != fullKey) {
if (numReg.test(subKey)) {
sumTxt += "[" + subKey + "]";
} else {
sumTxt += "." + subKey;
}
} else {
sumTxt += fullKey;
}
lastIndex = curExec.index + fullKey.length;
curExec = mBracketReg.exec(tmpRathKey);
} // 补上最后的字段
sumTxt += tmpRathKey.substr(lastIndex);
} else {
// 不需要转换,土又白目直接返回
sumTxt = tmpRathKey;
}
return sumTxt;
}
};
/* harmony default export */ __webpack_exports__["a"] = (parse);
/***/ }),
/***/ "613b":
/***/ (function(module, exports, __webpack_require__) {
var shared = __webpack_require__("5537")('keys');
var uid = __webpack_require__("ca5a");
module.exports = function (key) {
return shared[key] || (shared[key] = uid(key));
};
/***/ }),
/***/ "626a":
/***/ (function(module, exports, __webpack_require__) {
// fallback for non-array-like ES3 and non-enumerable old V8 strings
var cof = __webpack_require__("2d95");
// eslint-disable-next-line no-prototype-builtins
module.exports = Object('z').propertyIsEnumerable(0) ? Object : function (it) {
return cof(it) == 'String' ? it.split('') : Object(it);
};
/***/ }),
/***/ "62a0":
/***/ (function(module, exports) {
var id = 0;
var px = Math.random();
module.exports = function (key) {
return 'Symbol('.concat(key === undefined ? '' : key, ')_', (++id + px).toString(36));
};
/***/ }),
/***/ "63b6":
/***/ (function(module, exports, __webpack_require__) {
var global = __webpack_require__("e53d");
var core = __webpack_require__("584a");
var ctx = __webpack_require__("d864");
var hide = __webpack_require__("35e8");
var has = __webpack_require__("07e3");
var PROTOTYPE = 'prototype';
var $export = function (type, name, source) {
var IS_FORCED = type & $export.F;
var IS_GLOBAL = type & $export.G;
var IS_STATIC = type & $export.S;
var IS_PROTO = type & $export.P;
var IS_BIND = type & $export.B;
var IS_WRAP = type & $export.W;
var exports = IS_GLOBAL ? core : core[name] || (core[name] = {});
var expProto = exports[PROTOTYPE];
var target = IS_GLOBAL ? global : IS_STATIC ? global[name] : (global[name] || {})[PROTOTYPE];
var key, own, out;
if (IS_GLOBAL) source = name;
for (key in source) {
// contains in native
own = !IS_FORCED && target && target[key] !== undefined;
if (own && has(exports, key)) continue;
// export native or passed
out = own ? target[key] : source[key];
// prevent global pollution for namespaces
exports[key] = IS_GLOBAL && typeof target[key] != 'function' ? source[key]
// bind timers to global for call from export context
: IS_BIND && own ? ctx(out, global)
// wrap global constructors for prevent change them in library
: IS_WRAP && target[key] == out ? (function (C) {
var F = function (a, b, c) {
if (this instanceof C) {
switch (arguments.length) {
case 0: return new C();
case 1: return new C(a);
case 2: return new C(a, b);
} return new C(a, b, c);
} return C.apply(this, arguments);
};
F[PROTOTYPE] = C[PROTOTYPE];
return F;
// make static versions for prototype methods
})(out) : IS_PROTO && typeof out == 'function' ? ctx(Function.call, out) : out;
// export proto methods to core.%CONSTRUCTOR%.methods.%NAME%
if (IS_PROTO) {
(exports.virtual || (exports.virtual = {}))[key] = out;
// export proto methods to core.%CONSTRUCTOR%.prototype.%NAME%
if (type & $export.R && expProto && !expProto[key]) hide(expProto, key, out);
}
}
};
// type bitmap
$export.F = 1; // forced
$export.G = 2; // global
$export.S = 4; // static
$export.P = 8; // proto
$export.B = 16; // bind
$export.W = 32; // wrap
$export.U = 64; // safe
$export.R = 128; // real proto method for `library`
module.exports = $export;
/***/ }),
/***/ "6762":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
// https://github.com/tc39/Array.prototype.includes
var $export = __webpack_require__("5ca1");
var $includes = __webpack_require__("c366")(true);
$export($export.P, 'Array', {
includes: function includes(el /* , fromIndex = 0 */) {
return $includes(this, el, arguments.length > 1 ? arguments[1] : undefined);
}
});
__webpack_require__("9c6c")('includes');
/***/ }),
/***/ "6821":
/***/ (function(module, exports, __webpack_require__) {
// to indexed object, toObject with fallback for non-array-like ES3 strings
var IObject = __webpack_require__("626a");
var defined = __webpack_require__("be13");
module.exports = function (it) {
return IObject(defined(it));
};
/***/ }),
/***/ "69a8":
/***/ (function(module, exports) {
var hasOwnProperty = {}.hasOwnProperty;
module.exports = function (it, key) {
return hasOwnProperty.call(it, key);
};
/***/ }),
/***/ "6a99":
/***/ (function(module, exports, __webpack_require__) {
// 7.1.1 ToPrimitive(input [, PreferredType])
var isObject = __webpack_require__("d3f4");
// instead of the ES6 spec version, we didn't implement @@toPrimitive case
// and the second argument - flag - preferred type is a string
module.exports = function (it, S) {
if (!isObject(it)) return it;
var fn, val;
if (S && typeof (fn = it.toString) == 'function' && !isObject(val = fn.call(it))) return val;
if (typeof (fn = it.valueOf) == 'function' && !isObject(val = fn.call(it))) return val;
if (!S && typeof (fn = it.toString) == 'function' && !isObject(val = fn.call(it))) return val;
throw TypeError("Can't convert object to primitive value");
};
/***/ }),
/***/ "6b4c":
/***/ (function(module, exports) {
var toString = {}.toString;
module.exports = function (it) {
return toString.call(it).slice(8, -1);
};
/***/ }),
/***/ "6b54":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
__webpack_require__("3846");
var anObject = __webpack_require__("cb7c");
var $flags = __webpack_require__("0bfb");
var DESCRIPTORS = __webpack_require__("9e1e");
var TO_STRING = 'toString';
var $toString = /./[TO_STRING];
var define = function (fn) {
__webpack_require__("2aba")(RegExp.prototype, TO_STRING, fn, true);
};
// 21.2.5.14 RegExp.prototype.toString()
if (__webpack_require__("79e5")(function () { return $toString.call({ source: 'a', flags: 'b' }) != '/a/b'; })) {
define(function toString() {
var R = anObject(this);
return '/'.concat(R.source, '/',
'flags' in R ? R.flags : !DESCRIPTORS && R instanceof RegExp ? $flags.call(R) : undefined);
});
// FF44- RegExp#toString has a wrong name
} else if ($toString.name != TO_STRING) {
define(function toString() {
return $toString.call(this);
});
}
/***/ }),
/***/ "6c1c":
/***/ (function(module, exports, __webpack_require__) {
__webpack_require__("c367");
var global = __webpack_require__("e53d");
var hide = __webpack_require__("35e8");
var Iterators = __webpack_require__("481b");
var TO_STRING_TAG = __webpack_require__("5168")('toStringTag');
var DOMIterables = ('CSSRuleList,CSSStyleDeclaration,CSSValueList,ClientRectList,DOMRectList,DOMStringList,' +
'DOMTokenList,DataTransferItemList,FileList,HTMLAllCollection,HTMLCollection,HTMLFormElement,HTMLSelectElement,' +
'MediaList,MimeTypeArray,NamedNodeMap,NodeList,PaintRequestList,Plugin,PluginArray,SVGLengthList,SVGNumberList,' +
'SVGPathSegList,SVGPointList,SVGStringList,SVGTransformList,SourceBufferList,StyleSheetList,TextTrackCueList,' +
'TextTrackList,TouchList').split(',');
for (var i = 0; i < DOMIterables.length; i++) {
var NAME = DOMIterables[i];
var Collection = global[NAME];
var proto = Collection && Collection.prototype;
if (proto && !proto[TO_STRING_TAG]) hide(proto, TO_STRING_TAG, NAME);
Iterators[NAME] = Iterators.Array;
}
/***/ }),
/***/ "6fe2":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_table_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("b3b7");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_table_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_table_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_table_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "71c1":
/***/ (function(module, exports, __webpack_require__) {
var toInteger = __webpack_require__("3a38");
var defined = __webpack_require__("25eb");
// true -> String#at
// false -> String#codePointAt
module.exports = function (TO_STRING) {
return function (that, pos) {
var s = String(defined(that));
var i = toInteger(pos);
var l = s.length;
var a, b;
if (i < 0 || i >= l) return TO_STRING ? '' : undefined;
a = s.charCodeAt(i);
return a < 0xd800 || a > 0xdbff || i + 1 === l || (b = s.charCodeAt(i + 1)) < 0xdc00 || b > 0xdfff
? TO_STRING ? s.charAt(i) : a
: TO_STRING ? s.slice(i, i + 2) : (a - 0xd800 << 10) + (b - 0xdc00) + 0x10000;
};
};
/***/ }),
/***/ "7333":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
// 19.1.2.1 Object.assign(target, source, ...)
var getKeys = __webpack_require__("0d58");
var gOPS = __webpack_require__("2621");
var pIE = __webpack_require__("52a7");
var toObject = __webpack_require__("4bf8");
var IObject = __webpack_require__("626a");
var $assign = Object.assign;
// should work with symbols and should have deterministic property order (V8 bug)
module.exports = !$assign || __webpack_require__("79e5")(function () {
var A = {};
var B = {};
// eslint-disable-next-line no-undef
var S = Symbol();
var K = 'abcdefghijklmnopqrst';
A[S] = 7;
K.split('').forEach(function (k) { B[k] = k; });
return $assign({}, A)[S] != 7 || Object.keys($assign({}, B)).join('') != K;
}) ? function assign(target, source) { // eslint-disable-line no-unused-vars
var T = toObject(target);
var aLen = arguments.length;
var index = 1;
var getSymbols = gOPS.f;
var isEnum = pIE.f;
while (aLen > index) {
var S = IObject(arguments[index++]);
var keys = getSymbols ? getKeys(S).concat(getSymbols(S)) : getKeys(S);
var length = keys.length;
var j = 0;
var key;
while (length > j) if (isEnum.call(S, key = keys[j++])) T[key] = S[key];
} return T;
} : $assign;
/***/ }),
/***/ "73c1":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("f3a6");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("157dcdca", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "73e7":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("96da");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("59b35121", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "7445":
/***/ (function(module, exports, __webpack_require__) {
var $export = __webpack_require__("63b6");
var $parseInt = __webpack_require__("5d6b");
// 18.2.5 parseInt(string, radix)
$export($export.G + $export.F * (parseInt != $parseInt), { parseInt: $parseInt });
/***/ }),
/***/ "75bc":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, ".es-form-array-box{display:-webkit-box;display:-ms-flexbox;display:flex}.es-form-array-box:after,.es-form-array-box:before{content:\".\";display:block;overflow:hidden;visibility:hidden;font-size:0;line-height:0;width:0;height:0}.es-form-array-box:after{clear:both}.es-form-array-box .es-form-array-wrap{-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto}.es-form-array-box .es-order-list-box{margin:0 0 0 0;padding:0;list-style:none}.es-form-array-box .list-item{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;margin:20px 0 0 0;padding:0}.es-form-array-box .es-order-box{width:40px}.es-form-array-box .es-order-box,.es-form-array-box .es-order-box-required{text-align:center;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto}.es-form-array-box .es-order-box-required{width:14px}.es-form-array-box .es-order-box-required .es-required{margin-right:0}.es-form-array-box .es-array-row-body{-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto}.es-form-array-box .es-btn-box{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;margin-left:5px}.es-form-array-box .es-btn-footer{text-align:center;margin-top:20px}", ""]);
// exports
/***/ }),
/***/ "7726":
/***/ (function(module, exports) {
// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
var global = module.exports = typeof window != 'undefined' && window.Math == Math
? window : typeof self != 'undefined' && self.Math == Math ? self
// eslint-disable-next-line no-new-func
: Function('return this')();
if (typeof __g == 'number') __g = global; // eslint-disable-line no-undef
/***/ }),
/***/ "774e":
/***/ (function(module, exports, __webpack_require__) {
module.exports = __webpack_require__("d2d5");
/***/ }),
/***/ "77f1":
/***/ (function(module, exports, __webpack_require__) {
var toInteger = __webpack_require__("4588");
var max = Math.max;
var min = Math.min;
module.exports = function (index, length) {
index = toInteger(index);
return index < 0 ? max(index + length, 0) : min(index, length);
};
/***/ }),
/***/ "794b":
/***/ (function(module, exports, __webpack_require__) {
module.exports = !__webpack_require__("8e60") && !__webpack_require__("294c")(function () {
return Object.defineProperty(__webpack_require__("1ec9")('div'), 'a', { get: function () { return 7; } }).a != 7;
});
/***/ }),
/***/ "79aa":
/***/ (function(module, exports) {
module.exports = function (it) {
if (typeof it != 'function') throw TypeError(it + ' is not a function!');
return it;
};
/***/ }),
/***/ "79e5":
/***/ (function(module, exports) {
module.exports = function (exec) {
try {
return !!exec();
} catch (e) {
return true;
}
};
/***/ }),
/***/ "7a56":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var global = __webpack_require__("7726");
var dP = __webpack_require__("86cc");
var DESCRIPTORS = __webpack_require__("9e1e");
var SPECIES = __webpack_require__("2b4c")('species');
module.exports = function (KEY) {
var C = global[KEY];
if (DESCRIPTORS && C && !C[SPECIES]) dP.f(C, SPECIES, {
configurable: true,
get: function () { return this; }
});
};
/***/ }),
/***/ "7be7":
/***/ (function(module, exports, __webpack_require__) {
__webpack_require__("0a90");
module.exports = __webpack_require__("584a").parseFloat;
/***/ }),
/***/ "7cd6":
/***/ (function(module, exports, __webpack_require__) {
var classof = __webpack_require__("40c3");
var ITERATOR = __webpack_require__("5168")('iterator');
var Iterators = __webpack_require__("481b");
module.exports = __webpack_require__("584a").getIteratorMethod = function (it) {
if (it != undefined) return it[ITERATOR]
|| it['@@iterator']
|| Iterators[classof(it)];
};
/***/ }),
/***/ "7e62":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_index_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("9289");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_index_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_index_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_index_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "7e90":
/***/ (function(module, exports, __webpack_require__) {
var dP = __webpack_require__("d9f6");
var anObject = __webpack_require__("e4ae");
var getKeys = __webpack_require__("c3a1");
module.exports = __webpack_require__("8e60") ? Object.defineProperties : function defineProperties(O, Properties) {
anObject(O);
var keys = getKeys(Properties);
var length = keys.length;
var i = 0;
var P;
while (length > i) dP.f(O, P = keys[i++], Properties[P]);
return O;
};
/***/ }),
/***/ "7f20":
/***/ (function(module, exports, __webpack_require__) {
var def = __webpack_require__("86cc").f;
var has = __webpack_require__("69a8");
var TAG = __webpack_require__("2b4c")('toStringTag');
module.exports = function (it, tag, stat) {
if (it && !has(it = stat ? it : it.prototype, TAG)) def(it, TAG, { configurable: true, value: tag });
};
/***/ }),
/***/ "7f7f":
/***/ (function(module, exports, __webpack_require__) {
var dP = __webpack_require__("86cc").f;
var FProto = Function.prototype;
var nameRE = /^\s*function ([^ (]*)/;
var NAME = 'name';
// 19.2.4.2 name
NAME in FProto || __webpack_require__("9e1e") && dP(FProto, NAME, {
configurable: true,
get: function () {
try {
return ('' + this).match(nameRE)[1];
} catch (e) {
return '';
}
}
});
/***/ }),
/***/ "8079":
/***/ (function(module, exports, __webpack_require__) {
var global = __webpack_require__("7726");
var macrotask = __webpack_require__("1991").set;
var Observer = global.MutationObserver || global.WebKitMutationObserver;
var process = global.process;
var Promise = global.Promise;
var isNode = __webpack_require__("2d95")(process) == 'process';
module.exports = function () {
var head, last, notify;
var flush = function () {
var parent, fn;
if (isNode && (parent = process.domain)) parent.exit();
while (head) {
fn = head.fn;
head = head.next;
try {
fn();
} catch (e) {
if (head) notify();
else last = undefined;
throw e;
}
} last = undefined;
if (parent) parent.enter();
};
// Node.js
if (isNode) {
notify = function () {
process.nextTick(flush);
};
// browsers with MutationObserver, except iOS Safari - https://github.com/zloirock/core-js/issues/339
} else if (Observer && !(global.navigator && global.navigator.standalone)) {
var toggle = true;
var node = document.createTextNode('');
new Observer(flush).observe(node, { characterData: true }); // eslint-disable-line no-new
notify = function () {
node.data = toggle = !toggle;
};
// environments with maybe non-completely correct, but existent Promise
} else if (Promise && Promise.resolve) {
// Promise.resolve without an argument throws an error in LG WebOS 2
var promise = Promise.resolve(undefined);
notify = function () {
promise.then(flush);
};
// for other environments - macrotask based on:
// - setImmediate
// - MessageChannel
// - window.postMessag
// - onreadystatechange
// - setTimeout
} else {
notify = function () {
// strange IE + webpack dev server bug - use .call(global)
macrotask.call(global, flush);
};
}
return function (fn) {
var task = { fn: fn, next: undefined };
if (last) last.next = task;
if (!head) {
head = task;
notify();
} last = task;
};
};
/***/ }),
/***/ "8378":
/***/ (function(module, exports) {
var core = module.exports = { version: '2.6.5' };
if (typeof __e == 'number') __e = core; // eslint-disable-line no-undef
/***/ }),
/***/ "8436":
/***/ (function(module, exports) {
module.exports = function () { /* empty */ };
/***/ }),
/***/ "84f2":
/***/ (function(module, exports) {
module.exports = {};
/***/ }),
/***/ "86cc":
/***/ (function(module, exports, __webpack_require__) {
var anObject = __webpack_require__("cb7c");
var IE8_DOM_DEFINE = __webpack_require__("c69a");
var toPrimitive = __webpack_require__("6a99");
var dP = Object.defineProperty;
exports.f = __webpack_require__("9e1e") ? Object.defineProperty : function defineProperty(O, P, Attributes) {
anObject(O);
P = toPrimitive(P, true);
anObject(Attributes);
if (IE8_DOM_DEFINE) try {
return dP(O, P, Attributes);
} catch (e) { /* empty */ }
if ('get' in Attributes || 'set' in Attributes) throw TypeError('Accessors not supported!');
if ('value' in Attributes) O[P] = Attributes.value;
return O;
};
/***/ }),
/***/ "8744":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_tabs_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("f504");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_tabs_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_tabs_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_tabs_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "890a":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
var constant = {
// HELP_NAME: "es-help", //注册时用的全局名字
UI_MAX_COL: 24,
//整修个布局分为多少列,这个值不要随便改, 要跟object.vue的UI_MAX_COL对应
WIDTH_AUTO: "auto",
ARRAY_TABLE: "array-table",
// 只支持properities(非叶子)
ARRAY_TABS: "array-tabs",
ARRAY_LEGEND: "array-legend",
ARRAY_ROW: "array",
ARRAY_CARD: "array-card",
// 只支持组件(叶子)
POINT_CENTER_CENTER: "center-center",
// tip框与源icon可以居中指向
POINT_ARROW_CENTER: "arrow-center",
// tip框偏移,但指向源icon中间
POINT_ARROW_OFFSET: "arrow-offset",
// tip框偏移,也不指向源icon中间
ADJ_NATIVE: "native",
// 将原生事件绑定到组件; 本身是区分大小写的;keyup.native为例:原生input.text监听不到,但组件(就只有一个input.text)可以监听到事件,
INPUT_EVENT: "input",
CHANGE_EVENT: "change",
// 应用于数组改变
CLICK_EVENT: "click",
TAG_INPUT: "input",
TYPE_RADIO: "radio",
TYPE_CHECKBOX: "checkbox",
KEYUP_NATIVE: "keyup.native",
ENTER_SUBMIT: "@enterSubmit",
ONLY_SUBMIT: "@submit",
// TYPE_TMP: "tmp", // 表单的临时值,跟组件没有什么区别;只是不会取出;使用场景:快速做标题或编辑时,某些项需要显示但又不需要提交给后台
LAYOUT_SPACE: "space",
// 占位符; space不可以乱改,因为其它地方(.vue)有用到
LAYOUT_TABS: "tabs",
// properties的子属性是tabs布局; space不可以乱改,因为其它地方(.vue)有用到
UI_FORM: "_es_form_qwerty_",
// 说明界面属于哪种类型
UI_ITEM: "_es_item_qwerrf_",
UI_ARRAY: "_es_array_aadfsd_",
ES_FUNC_NAME: "__E0S1_2F3U4NC_N4AM5E__",
ES_OPTIONS: "__es__Options__",
// 此值要是正规的命名
PREFIX_STATIC_FUNC: ["s:"],
// 对于props里面的属性,以PRE_STATIC_FUNC开头的且是函数,则说明是静态,不解析
// 原生的表单组件,主要是用来过滤空格
FORM_INPUTS: ["input", "textarea"],
INPUT_CHANGE: "change",
IDX_CHAIN_KEY: "[i]",
// 数组链的代替字符,不可随便改
COM_TARGET_REF: "__comTarget__"
};
/* harmony default export */ __webpack_exports__["a"] = (constant);
/***/ }),
/***/ "8925":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, ".es-form-table-container{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row}.es-form-table-container .es-table-required{display:block;margin-right:5px}", ""]);
// exports
/***/ }),
/***/ "8aae":
/***/ (function(module, exports, __webpack_require__) {
__webpack_require__("32a6");
module.exports = __webpack_require__("584a").Object.keys;
/***/ }),
/***/ "8b97":
/***/ (function(module, exports, __webpack_require__) {
// Works with __proto__ only. Old v8 can't work with null proto objects.
/* eslint-disable no-proto */
var isObject = __webpack_require__("d3f4");
var anObject = __webpack_require__("cb7c");
var check = function (O, proto) {
anObject(O);
if (!isObject(proto) && proto !== null) throw TypeError(proto + ": can't set as prototype!");
};
module.exports = {
set: Object.setPrototypeOf || ('__proto__' in {} ? // eslint-disable-line
function (test, buggy, set) {
try {
set = __webpack_require__("9b43")(Function.call, __webpack_require__("11e9").f(Object.prototype, '__proto__').set, 2);
set(test, []);
buggy = !(test instanceof Array);
} catch (e) { buggy = true; }
return function setPrototypeOf(O, proto) {
check(O, proto);
if (buggy) O.__proto__ = proto;
else set(O, proto);
return O;
};
}({}, false) : undefined),
check: check
};
/***/ }),
/***/ "8e60":
/***/ (function(module, exports, __webpack_require__) {
// Thank's IE8 for his funny defineProperty
module.exports = !__webpack_require__("294c")(function () {
return Object.defineProperty({}, 'a', { get: function () { return 7; } }).a != 7;
});
/***/ }),
/***/ "8f60":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var create = __webpack_require__("a159");
var descriptor = __webpack_require__("aebd");
var setToStringTag = __webpack_require__("45f2");
var IteratorPrototype = {};
// 25.1.2.1.1 %IteratorPrototype%[@@iterator]()
__webpack_require__("35e8")(IteratorPrototype, __webpack_require__("5168")('iterator'), function () { return this; });
module.exports = function (Constructor, NAME, next) {
Constructor.prototype = create(IteratorPrototype, { next: descriptor(1, next) });
setToStringTag(Constructor, NAME + ' Iterator');
};
/***/ }),
/***/ "9003":
/***/ (function(module, exports, __webpack_require__) {
// 7.2.2 IsArray(argument)
var cof = __webpack_require__("6b4c");
module.exports = Array.isArray || function isArray(arg) {
return cof(arg) == 'Array';
};
/***/ }),
/***/ "9093":
/***/ (function(module, exports, __webpack_require__) {
// 19.1.2.7 / 15.2.3.4 Object.getOwnPropertyNames(O)
var $keys = __webpack_require__("ce10");
var hiddenKeys = __webpack_require__("e11e").concat('length', 'prototype');
exports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
return $keys(O, hiddenKeys);
};
/***/ }),
/***/ "9138":
/***/ (function(module, exports, __webpack_require__) {
module.exports = __webpack_require__("35e8");
/***/ }),
/***/ "9289":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("dcae");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("770b20ea", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "9306":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
// 19.1.2.1 Object.assign(target, source, ...)
var getKeys = __webpack_require__("c3a1");
var gOPS = __webpack_require__("9aa9");
var pIE = __webpack_require__("355d");
var toObject = __webpack_require__("241e");
var IObject = __webpack_require__("335c");
var $assign = Object.assign;
// should work with symbols and should have deterministic property order (V8 bug)
module.exports = !$assign || __webpack_require__("294c")(function () {
var A = {};
var B = {};
// eslint-disable-next-line no-undef
var S = Symbol();
var K = 'abcdefghijklmnopqrst';
A[S] = 7;
K.split('').forEach(function (k) { B[k] = k; });
return $assign({}, A)[S] != 7 || Object.keys($assign({}, B)).join('') != K;
}) ? function assign(target, source) { // eslint-disable-line no-unused-vars
var T = toObject(target);
var aLen = arguments.length;
var index = 1;
var getSymbols = gOPS.f;
var isEnum = pIE.f;
while (aLen > index) {
var S = IObject(arguments[index++]);
var keys = getSymbols ? getKeys(S).concat(getSymbols(S)) : getKeys(S);
var length = keys.length;
var j = 0;
var key;
while (length > j) if (isEnum.call(S, key = keys[j++])) T[key] = S[key];
} return T;
} : $assign;
/***/ }),
/***/ "95d5":
/***/ (function(module, exports, __webpack_require__) {
var classof = __webpack_require__("40c3");
var ITERATOR = __webpack_require__("5168")('iterator');
var Iterators = __webpack_require__("481b");
module.exports = __webpack_require__("584a").isIterable = function (it) {
var O = Object(it);
return O[ITERATOR] !== undefined
|| '@@iterator' in O
// eslint-disable-next-line no-prototype-builtins
|| Iterators.hasOwnProperty(classof(O));
};
/***/ }),
/***/ "96da":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, ".es-form-edit-btns{display:inline-block}", ""]);
// exports
/***/ }),
/***/ "9742":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("271b");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("7c8966c3", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "9aa9":
/***/ (function(module, exports) {
exports.f = Object.getOwnPropertySymbols;
/***/ }),
/***/ "9b43":
/***/ (function(module, exports, __webpack_require__) {
// optional / simple context binding
var aFunction = __webpack_require__("d8e8");
module.exports = function (fn, that, length) {
aFunction(fn);
if (that === undefined) return fn;
switch (length) {
case 1: return function (a) {
return fn.call(that, a);
};
case 2: return function (a, b) {
return fn.call(that, a, b);
};
case 3: return function (a, b, c) {
return fn.call(that, a, b, c);
};
}
return function (/* ...args */) {
return fn.apply(that, arguments);
};
};
/***/ }),
/***/ "9c6c":
/***/ (function(module, exports, __webpack_require__) {
// 22.1.3.31 Array.prototype[@@unscopables]
var UNSCOPABLES = __webpack_require__("2b4c")('unscopables');
var ArrayProto = Array.prototype;
if (ArrayProto[UNSCOPABLES] == undefined) __webpack_require__("32e9")(ArrayProto, UNSCOPABLES, {});
module.exports = function (key) {
ArrayProto[UNSCOPABLES][key] = true;
};
/***/ }),
/***/ "9c80":
/***/ (function(module, exports) {
module.exports = function (exec) {
try {
return { e: false, v: exec() };
} catch (e) {
return { e: true, v: e };
}
};
/***/ }),
/***/ "9def":
/***/ (function(module, exports, __webpack_require__) {
// 7.1.15 ToLength
var toInteger = __webpack_require__("4588");
var min = Math.min;
module.exports = function (it) {
return it > 0 ? min(toInteger(it), 0x1fffffffffffff) : 0; // pow(2, 53) - 1 == 9007199254740991
};
/***/ }),
/***/ "9e1e":
/***/ (function(module, exports, __webpack_require__) {
// Thank's IE8 for his funny defineProperty
module.exports = !__webpack_require__("79e5")(function () {
return Object.defineProperty({}, 'a', { get: function () { return 7; } }).a != 7;
});
/***/ }),
/***/ "a159":
/***/ (function(module, exports, __webpack_require__) {
// 19.1.2.2 / 15.2.3.5 Object.create(O [, Properties])
var anObject = __webpack_require__("e4ae");
var dPs = __webpack_require__("7e90");
var enumBugKeys = __webpack_require__("1691");
var IE_PROTO = __webpack_require__("5559")('IE_PROTO');
var Empty = function () { /* empty */ };
var PROTOTYPE = 'prototype';
// Create object with fake `null` prototype: use iframe Object with cleared prototype
var createDict = function () {
// Thrash, waste and sodomy: IE GC bug
var iframe = __webpack_require__("1ec9")('iframe');
var i = enumBugKeys.length;
var lt = '<';
var gt = '>';
var iframeDocument;
iframe.style.display = 'none';
__webpack_require__("32fc").appendChild(iframe);
iframe.src = 'javascript:'; // eslint-disable-line no-script-url
// createDict = iframe.contentWindow.Object;
// html.removeChild(iframe);
iframeDocument = iframe.contentWindow.document;
iframeDocument.open();
iframeDocument.write(lt + 'script' + gt + 'document.F=Object' + lt + '/script' + gt);
iframeDocument.close();
createDict = iframeDocument.F;
while (i--) delete createDict[PROTOTYPE][enumBugKeys[i]];
return createDict();
};
module.exports = Object.create || function create(O, Properties) {
var result;
if (O !== null) {
Empty[PROTOTYPE] = anObject(O);
result = new Empty();
Empty[PROTOTYPE] = null;
// add "__proto__" for Object.getPrototypeOf polyfill
result[IE_PROTO] = O;
} else result = createDict();
return Properties === undefined ? result : dPs(result, Properties);
};
/***/ }),
/***/ "a1ce":
/***/ (function(module, exports, __webpack_require__) {
var $export = __webpack_require__("63b6");
var defined = __webpack_require__("25eb");
var fails = __webpack_require__("294c");
var spaces = __webpack_require__("e692");
var space = '[' + spaces + ']';
var non = '\u200b\u0085';
var ltrim = RegExp('^' + space + space + '*');
var rtrim = RegExp(space + space + '*$');
var exporter = function (KEY, exec, ALIAS) {
var exp = {};
var FORCE = fails(function () {
return !!spaces[KEY]() || non[KEY]() != non;
});
var fn = exp[KEY] = FORCE ? exec(trim) : spaces[KEY];
if (ALIAS) exp[ALIAS] = fn;
$export($export.P + $export.F * FORCE, 'String', exp);
};
// 1 -> String#trimLeft
// 2 -> String#trimRight
// 3 -> String#trim
var trim = exporter.trim = function (string, TYPE) {
string = String(defined(string));
if (TYPE & 1) string = string.replace(ltrim, '');
if (TYPE & 2) string = string.replace(rtrim, '');
return string;
};
module.exports = exporter;
/***/ }),
/***/ "a21f":
/***/ (function(module, exports, __webpack_require__) {
var core = __webpack_require__("584a");
var $JSON = core.JSON || (core.JSON = { stringify: JSON.stringify });
module.exports = function stringify(it) { // eslint-disable-line no-unused-vars
return $JSON.stringify.apply($JSON, arguments);
};
/***/ }),
/***/ "a25f":
/***/ (function(module, exports, __webpack_require__) {
var global = __webpack_require__("7726");
var navigator = global.navigator;
module.exports = navigator && navigator.userAgent || '';
/***/ }),
/***/ "a3c3":
/***/ (function(module, exports, __webpack_require__) {
// 19.1.3.1 Object.assign(target, source)
var $export = __webpack_require__("63b6");
$export($export.S + $export.F, 'Object', { assign: __webpack_require__("9306") });
/***/ }),
/***/ "a481":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var anObject = __webpack_require__("cb7c");
var toObject = __webpack_require__("4bf8");
var toLength = __webpack_require__("9def");
var toInteger = __webpack_require__("4588");
var advanceStringIndex = __webpack_require__("0390");
var regExpExec = __webpack_require__("5f1b");
var max = Math.max;
var min = Math.min;
var floor = Math.floor;
var SUBSTITUTION_SYMBOLS = /\$([$&`']|\d\d?|<[^>]*>)/g;
var SUBSTITUTION_SYMBOLS_NO_NAMED = /\$([$&`']|\d\d?)/g;
var maybeToString = function (it) {
return it === undefined ? it : String(it);
};
// @@replace logic
__webpack_require__("214f")('replace', 2, function (defined, REPLACE, $replace, maybeCallNative) {
return [
// `String.prototype.replace` method
// https://tc39.github.io/ecma262/#sec-string.prototype.replace
function replace(searchValue, replaceValue) {
var O = defined(this);
var fn = searchValue == undefined ? undefined : searchValue[REPLACE];
return fn !== undefined
? fn.call(searchValue, O, replaceValue)
: $replace.call(String(O), searchValue, replaceValue);
},
// `RegExp.prototype[@@replace]` method
// https://tc39.github.io/ecma262/#sec-regexp.prototype-@@replace
function (regexp, replaceValue) {
var res = maybeCallNative($replace, regexp, this, replaceValue);
if (res.done) return res.value;
var rx = anObject(regexp);
var S = String(this);
var functionalReplace = typeof replaceValue === 'function';
if (!functionalReplace) replaceValue = String(replaceValue);
var global = rx.global;
if (global) {
var fullUnicode = rx.unicode;
rx.lastIndex = 0;
}
var results = [];
while (true) {
var result = regExpExec(rx, S);
if (result === null) break;
results.push(result);
if (!global) break;
var matchStr = String(result[0]);
if (matchStr === '') rx.lastIndex = advanceStringIndex(S, toLength(rx.lastIndex), fullUnicode);
}
var accumulatedResult = '';
var nextSourcePosition = 0;
for (var i = 0; i < results.length; i++) {
result = results[i];
var matched = String(result[0]);
var position = max(min(toInteger(result.index), S.length), 0);
var captures = [];
// NOTE: This is equivalent to
// captures = result.slice(1).map(maybeToString)
// but for some reason `nativeSlice.call(result, 1, result.length)` (called in
// the slice polyfill when slicing native arrays) "doesn't work" in safari 9 and
// causes a crash (https://pastebin.com/N21QzeQA) when trying to debug it.
for (var j = 1; j < result.length; j++) captures.push(maybeToString(result[j]));
var namedCaptures = result.groups;
if (functionalReplace) {
var replacerArgs = [matched].concat(captures, position, S);
if (namedCaptures !== undefined) replacerArgs.push(namedCaptures);
var replacement = String(replaceValue.apply(undefined, replacerArgs));
} else {
replacement = getSubstitution(matched, S, position, captures, namedCaptures, replaceValue);
}
if (position >= nextSourcePosition) {
accumulatedResult += S.slice(nextSourcePosition, position) + replacement;
nextSourcePosition = position + matched.length;
}
}
return accumulatedResult + S.slice(nextSourcePosition);
}
];
// https://tc39.github.io/ecma262/#sec-getsubstitution
function getSubstitution(matched, str, position, captures, namedCaptures, replacement) {
var tailPos = position + matched.length;
var m = captures.length;
var symbols = SUBSTITUTION_SYMBOLS_NO_NAMED;
if (namedCaptures !== undefined) {
namedCaptures = toObject(namedCaptures);
symbols = SUBSTITUTION_SYMBOLS;
}
return $replace.call(replacement, symbols, function (match, ch) {
var capture;
switch (ch.charAt(0)) {
case '$': return '$';
case '&': return matched;
case '`': return str.slice(0, position);
case "'": return str.slice(tailPos);
case '<':
capture = namedCaptures[ch.slice(1, -1)];
break;
default: // \d\d?
var n = +ch;
if (n === 0) return match;
if (n > m) {
var f = floor(n / 10);
if (f === 0) return match;
if (f <= m) return captures[f - 1] === undefined ? ch.charAt(1) : captures[f - 1] + ch.charAt(1);
return match;
}
capture = captures[n - 1];
}
return capture === undefined ? '' : capture;
});
}
});
/***/ }),
/***/ "a4bb":
/***/ (function(module, exports, __webpack_require__) {
module.exports = __webpack_require__("8aae");
/***/ }),
/***/ "a5b8":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
// 25.4.1.5 NewPromiseCapability(C)
var aFunction = __webpack_require__("d8e8");
function PromiseCapability(C) {
var resolve, reject;
this.promise = new C(function ($$resolve, $$reject) {
if (resolve !== undefined || reject !== undefined) throw TypeError('Bad Promise constructor');
resolve = $$resolve;
reject = $$reject;
});
this.resolve = aFunction(resolve);
this.reject = aFunction(reject);
}
module.exports.f = function (C) {
return new PromiseCapability(C);
};
/***/ }),
/***/ "a745":
/***/ (function(module, exports, __webpack_require__) {
module.exports = __webpack_require__("f410");
/***/ }),
/***/ "a864":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, ".es-form-array-table .es-table{width:100%;max-width:100%;background-color:transparent;border-collapse:separate;border-spacing:0;border-radius:4px;border:1px solid #e6ebf5}.es-form-array-table .es-table .thead{margin:0;padding:0}.es-form-array-table .es-table td,.es-form-array-table .es-table th{text-align:center;padding:10px;vertical-align:top;border-top:1px solid #e6ebf5;border-right:1px solid #e6ebf5;white-space:nowrap}.es-form-array-table .es-table td:last-child,.es-form-array-table .es-table th:last-child{border-right:none}.es-form-array-table .es-table th{border-top:none}.es-form-array-table .es-table tfoot tr:last-child td{border-bottom:none}.es-form-array-table .es-table .es-order-fixed{width:40px}.es-form-array-table .es-table .es-order-txt{display:block}.es-form-array-table .es-table .es-form-table-head{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.es-form-array-table .es-table .es-table-required{display:block;margin-right:5px}.es-form-array-table .es-table .es-form-table-content{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row}.es-form-array-table .es-table .es-btn-box{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}", ""]);
// exports
/***/ }),
/***/ "aa4c":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("e931");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("57947ff6", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "aa77":
/***/ (function(module, exports, __webpack_require__) {
var $export = __webpack_require__("5ca1");
var defined = __webpack_require__("be13");
var fails = __webpack_require__("79e5");
var spaces = __webpack_require__("fdef");
var space = '[' + spaces + ']';
var non = '\u200b\u0085';
var ltrim = RegExp('^' + space + space + '*');
var rtrim = RegExp(space + space + '*$');
var exporter = function (KEY, exec, ALIAS) {
var exp = {};
var FORCE = fails(function () {
return !!spaces[KEY]() || non[KEY]() != non;
});
var fn = exp[KEY] = FORCE ? exec(trim) : spaces[KEY];
if (ALIAS) exp[ALIAS] = fn;
$export($export.P + $export.F * FORCE, 'String', exp);
};
// 1 -> String#trimLeft
// 2 -> String#trimRight
// 3 -> String#trim
var trim = exporter.trim = function (string, TYPE) {
string = String(defined(string));
if (TYPE & 1) string = string.replace(ltrim, '');
if (TYPE & 2) string = string.replace(rtrim, '');
return string;
};
module.exports = exporter;
/***/ }),
/***/ "aae3":
/***/ (function(module, exports, __webpack_require__) {
// 7.2.8 IsRegExp(argument)
var isObject = __webpack_require__("d3f4");
var cof = __webpack_require__("2d95");
var MATCH = __webpack_require__("2b4c")('match');
module.exports = function (it) {
var isRegExp;
return isObject(it) && ((isRegExp = it[MATCH]) !== undefined ? !!isRegExp : cof(it) == 'RegExp');
};
/***/ }),
/***/ "ac2a":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_object_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("9742");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_object_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_object_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_object_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "ac6a":
/***/ (function(module, exports, __webpack_require__) {
var $iterators = __webpack_require__("cadf");
var getKeys = __webpack_require__("0d58");
var redefine = __webpack_require__("2aba");
var global = __webpack_require__("7726");
var hide = __webpack_require__("32e9");
var Iterators = __webpack_require__("84f2");
var wks = __webpack_require__("2b4c");
var ITERATOR = wks('iterator');
var TO_STRING_TAG = wks('toStringTag');
var ArrayValues = Iterators.Array;
var DOMIterables = {
CSSRuleList: true, // TODO: Not spec compliant, should be false.
CSSStyleDeclaration: false,
CSSValueList: false,
ClientRectList: false,
DOMRectList: false,
DOMStringList: false,
DOMTokenList: true,
DataTransferItemList: false,
FileList: false,
HTMLAllCollection: false,
HTMLCollection: false,
HTMLFormElement: false,
HTMLSelectElement: false,
MediaList: true, // TODO: Not spec compliant, should be false.
MimeTypeArray: false,
NamedNodeMap: false,
NodeList: true,
PaintRequestList: false,
Plugin: false,
PluginArray: false,
SVGLengthList: false,
SVGNumberList: false,
SVGPathSegList: false,
SVGPointList: false,
SVGStringList: false,
SVGTransformList: false,
SourceBufferList: false,
StyleSheetList: true, // TODO: Not spec compliant, should be false.
TextTrackCueList: false,
TextTrackList: false,
TouchList: false
};
for (var collections = getKeys(DOMIterables), i = 0; i < collections.length; i++) {
var NAME = collections[i];
var explicit = DOMIterables[NAME];
var Collection = global[NAME];
var proto = Collection && Collection.prototype;
var key;
if (proto) {
if (!proto[ITERATOR]) hide(proto, ITERATOR, ArrayValues);
if (!proto[TO_STRING_TAG]) hide(proto, TO_STRING_TAG, NAME);
Iterators[NAME] = ArrayValues;
if (explicit) for (key in $iterators) if (!proto[key]) redefine(proto, key, $iterators[key], true);
}
}
/***/ }),
/***/ "aebd":
/***/ (function(module, exports) {
module.exports = function (bitmap, value) {
return {
enumerable: !(bitmap & 1),
configurable: !(bitmap & 2),
writable: !(bitmap & 4),
value: value
};
};
/***/ }),
/***/ "aef7":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_tabs_nav_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("4ee3");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_tabs_nav_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_tabs_nav_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_tabs_nav_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "af3d":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_card_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("5e25");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_card_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_card_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_array_card_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "b0c5":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var regexpExec = __webpack_require__("520a");
__webpack_require__("5ca1")({
target: 'RegExp',
proto: true,
forced: regexpExec !== /./.exec
}, {
exec: regexpExec
});
/***/ }),
/***/ "b0dc":
/***/ (function(module, exports, __webpack_require__) {
// call something on iterator step with safe closing on error
var anObject = __webpack_require__("e4ae");
module.exports = function (iterator, fn, value, entries) {
try {
return entries ? fn(anObject(value)[0], value[1]) : fn(value);
// 7.4.6 IteratorClose(iterator, completion)
} catch (e) {
var ret = iterator['return'];
if (ret !== undefined) anObject(ret.call(iterator));
throw e;
}
};
/***/ }),
/***/ "b1bf":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("b578");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("7ee41e87", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "b3b7":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("a864");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("14078435", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "b447":
/***/ (function(module, exports, __webpack_require__) {
// 7.1.15 ToLength
var toInteger = __webpack_require__("3a38");
var min = Math.min;
module.exports = function (it) {
return it > 0 ? min(toInteger(it), 0x1fffffffffffff) : 0; // pow(2, 53) - 1 == 9007199254740991
};
/***/ }),
/***/ "b578":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, ".es-form-array-legend{display:-webkit-box;display:-ms-flexbox;display:flex}.es-form-array-legend:after,.es-form-array-legend:before{content:\".\";display:block;overflow:hidden;visibility:hidden;font-size:0;line-height:0;width:0;height:0}.es-form-array-legend:after{clear:both}.es-form-array-legend .es-form-array-wrap{-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto}.es-form-array-legend .es-order-list-box{margin:0 0 0 0;padding:0;list-style:none}.es-form-array-legend .list-item{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;margin:20px 0 0 0;padding:0}.es-form-array-legend .es-order-box{width:40px;text-align:center;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto}.es-form-array-legend .es-array-fieldset-box{padding-top:12px;-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto}.es-form-array-legend .es-array-fieldset{position:relative;padding:20px 20px 15px 20px;border:1px solid #dcdfe6;border-radius:4px}.es-form-array-legend .es-array-fieldset .es-legend{position:absolute;left:10px;top:-12px;background:#fff;line-height:24px;font-size:16px;font-weight:500;padding:0 10px;border-radius:10px;white-space:nowrap}.es-form-array-legend .es-array-fieldset .es-single-pannel{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.es-form-array-legend .es-array-fieldset .es-single-box{-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto}.es-form-array-legend .es-btn-panel{position:absolute;right:5px;top:5px}.es-form-array-legend .es-btn-box{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.es-form-array-legend .es-single-btn-box{margin-left:10px;-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto}.es-form-array-legend .es-btn-footer{text-align:center;margin-top:20px}", ""]);
// exports
/***/ }),
/***/ "b8e3":
/***/ (function(module, exports) {
module.exports = true;
/***/ }),
/***/ "b9e9":
/***/ (function(module, exports, __webpack_require__) {
__webpack_require__("7445");
module.exports = __webpack_require__("584a").parseInt;
/***/ }),
/***/ "bab9":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, ".es-tabs-nav-box{position:relative;margin:0 0 0 0;padding:0;border-bottom:1px solid #dcdfe6;-webkit-box-sizing:border-box;box-sizing:border-box;height:40px;display:-webkit-box;display:-ms-flexbox;display:flex}.es-tabs-nav-box .es-tabs-scroll-box{margin:0;padding:0;margin-bottom:-1px;overflow:hidden;-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto}.es-tabs-nav-box .es-tabs-scroll-box:after,.es-tabs-nav-box .es-tabs-scroll-box:before{content:\".\";display:block;overflow:hidden;visibility:hidden;font-size:0;line-height:0;width:0;height:0}.es-tabs-nav-box .es-tabs-scroll-box:after{clear:both}.es-tabs-nav-box .help-box{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;overflow:hidden}.es-tabs-nav-box .es-tabs-scroll-wrap{position:relative;margin:0;padding:0;height:40px;max-width:100%}.es-tabs-nav-box .es-tabs-prev-btn{display:none;position:absolute;height:36px;border-radius:3px;padding:0 3px;left:3px;top:1px;cursor:pointer}.es-tabs-nav-box .es-tabs-prev-btn .es-arrow{margin:0;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:4px 4px 4px 0;border-color:transparent #7b808c transparent transparent;position:relative}.es-tabs-nav-box .es-tabs-prev-btn .es-arrow:before{content:\"\";display:block;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:4px 4px 4px 0;border-color:transparent #fbfbfb transparent transparent;margin:0;position:absolute;top:-4px;left:1px}.es-tabs-nav-box .es-tabs-prev-btn:not(.disabled):hover{background:#eee}.es-tabs-nav-box .es-tabs-prev-btn:not(.disabled):hover .es-arrow{border-right-color:#409eff}.es-tabs-nav-box .es-tabs-prev-btn:not(.disabled):hover .es-arrow:before{border-right-color:#eee}.es-tabs-nav-box .es-tabs-prev-btn.disabled .es-arrow{border-right-color:#d5d7dc;cursor:not-allowed}.es-tabs-nav-box .es-tabs-next-btn{display:none;position:absolute;height:36px;border-radius:3px;padding:0 3px;right:3px;top:2px;cursor:pointer}.es-tabs-nav-box .es-tabs-next-btn .es-arrow{margin:0;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:4px 0 4px 4px;border-color:transparent transparent transparent #7b808c;position:relative}.es-tabs-nav-box .es-tabs-next-btn .es-arrow:before{content:\"\";display:block;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:4px 0 4px 4px;border-color:transparent transparent transparent #fbfbfb;margin:0;position:absolute;top:-4px;left:-5px}.es-tabs-nav-box .es-tabs-next-btn:not(.disabled):hover{background:#eee}.es-tabs-nav-box .es-tabs-next-btn:not(.disabled):hover .es-arrow{border-left-color:#409eff}.es-tabs-nav-box .es-tabs-next-btn:not(.disabled):hover .es-arrow:before{border-left-color:#eee}.es-tabs-nav-box .es-tabs-next-btn.disabled .es-arrow{border-left-color:#d5d7dc;cursor:not-allowed}.es-tabs-nav-box .es-tabs-scroll-wrap.es-has-toggle .es-tabs-next-btn,.es-tabs-nav-box .es-tabs-scroll-wrap.es-has-toggle .es-tabs-prev-btn{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.es-tabs-nav-box .es-tabs-nav-wrap{margin:0;padding:0;-webkit-box-sizing:border-box;box-sizing:border-box;float:left;height:40px;max-width:100%;position:relative}.es-tabs-nav-box .es-tabs-nav-wrap.es-has-add{padding-right:28px}.es-tabs-nav-box .es-tabs-nav-scroll{overflow:hidden;-webkit-box-sizing:border-box;box-sizing:border-box;border-bottom:none;height:40px}.es-tabs-nav-box .es-tabs-nav{float:left;margin:0 0 0 0;padding:0;list-style:none;white-space:nowrap;-webkit-transition:left .3s;transition:left .3s;z-index:2}.es-tabs-nav-box .es-tabs-nav,.es-tabs-nav-box .es-tabs-nav li{position:relative;-webkit-box-sizing:border-box;box-sizing:border-box}.es-tabs-nav-box .es-tabs-nav li{display:inline-block;height:40px;border-bottom:1px solid transparent;cursor:default;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.es-tabs-nav-box .es-tabs-nav li .es-tabs-nav-item-cnt{margin:0;white-space:nowrap;padding:0 19px;height:39px;-webkit-box-sizing:border-box;box-sizing:border-box;display:inline-block;list-style:none;font-size:15px;color:#303133;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;position:relative;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;border:1px solid transparent;transition:border-color .1s cubic-bezier(.645,.045,.355,1),padding .3s cubic-bezier(.645,.045,.355,1);-webkit-transition:border-color .1s cubic-bezier(.645,.045,.355,1),padding .3s cubic-bezier(.645,.045,.355,1)}.es-tabs-nav-box .es-tabs-nav li .es-tabs-nav-item-cnt>*{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto}.es-tabs-nav-box .es-tabs-nav li .es-tabs-nav-item-cnt.es-error{border-color:#f64a4a;border-radius:2px}.es-tabs-nav-box .es-tabs-nav li.is-active .es-tabs-nav-item-cnt,.es-tabs-nav-box .es-tabs-nav li:hover .es-tabs-nav-item-cnt{color:#409eff}.es-tabs-nav-box .es-tabs-nav li.has-close.has-pop .es-tabs-nav-item-cnt,.es-tabs-nav-box .es-tabs-nav li.has-close.is-active .es-tabs-nav-item-cnt,.es-tabs-nav-box .es-tabs-nav li.has-close:hover .es-tabs-nav-item-cnt{padding-left:13px;padding-right:9px}.es-tabs-nav-box .es-tabs-nav li.has-pop .es-tabs-close-box,.es-tabs-nav-box .es-tabs-nav li.is-active .es-tabs-close-box,.es-tabs-nav-box .es-tabs-nav li:hover .es-tabs-close-box{width:16px}.es-tabs-nav-box .es-tabs-nav li:hover .es-tabs-left-btn,.es-tabs-nav-box .es-tabs-nav li:hover .es-tabs-right-btn{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.es-tabs-nav-box .es-tabs-nav li.is-active{border-bottom-color:#fff}.es-tabs-nav-box.es-type-card .es-tabs-nav li{border-top:1px solid #dcdfe6;border-right:1px solid #dcdfe6}.es-tabs-nav-box.es-type-card .es-tabs-nav li:first-child{border-left:1px solid #dcdfe6;border-top-left-radius:4px}.es-tabs-nav-box.es-type-card .es-tabs-nav li:last-child{border-top-right-radius:4px}.es-tabs-nav-box.es-type-border-card{border-top:1px solid #dcdfe6;border-right:1px solid #dcdfe6;border-left:1px solid #dcdfe6;background:#f5f7fa}.es-tabs-nav-box.es-type-border-card .es-tabs-nav li{border-right:1px solid #dcdfe6;height:39px}.es-tabs-nav-box.es-type-border-card .es-tabs-nav li.is-active{background:#fff}.es-tabs-nav-box.es-type-border-card .es-tabs-nav li .es-tabs-nav-item-cnt{height:39px;line-height:39px}.es-tabs-nav-box.es-type-line .es-tabs-nav li.is-active{border-bottom-width:2px;border-bottom-color:#409eff}.es-tabs-nav-box .es-tabs-add{margin:0;padding:0;font-size:14px;width:18px;height:18px;line-height:16px;border:1px solid #dcdfe6;-webkit-box-sizing:border-box;box-sizing:border-box;border-radius:3px;text-align:center;cursor:pointer;position:absolute;right:2px;top:11px}.es-tabs-nav-box .es-tabs-add:before{top:7px;left:3px;width:10px;height:2px}.es-tabs-nav-box .es-tabs-add:after,.es-tabs-nav-box .es-tabs-add:before{content:\"\";display:block;position:absolute;border-radius:3px;background:#7b808c}.es-tabs-nav-box .es-tabs-add:after{top:3px;left:7px;width:2px;height:10px}.es-tabs-nav-box .es-tabs-add.disabled:after,.es-tabs-nav-box .es-tabs-add.disabled:before{background:#d5d7dc}.es-tabs-nav-box .es-tabs-close-box{margin:2px 0 0 0;padding:0;width:0;height:13px;line-height:13px;text-align:right;overflow:hidden;position:relative;-webkit-transition:all .3s cubic-bezier(.645,.045,.355,1);transition:all .3s cubic-bezier(.645,.045,.355,1)}.es-tabs-nav-box .es-tabs-close{margin:0;padding:0;width:13px;height:13px;line-height:16px;border:none;-webkit-box-sizing:border-box;box-sizing:border-box;border-radius:50%;cursor:pointer;outline:none;background-color:#fbfbfb;display:block;position:relative;background:transparent;transform:rotate(45deg);-webkit-transform:rotate(45deg);overflow:hidden;-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto}.es-tabs-nav-box .es-tabs-close:not(.disabled):hover{background:#c0c4cc!important}.es-tabs-nav-box .es-tabs-close:before{content:\"\";display:block;position:absolute;top:6px;left:2px;width:9px;height:1px;background:#409eff}.es-tabs-nav-box .es-tabs-close:after{content:\"\";display:block;position:absolute;border-radius:3px;top:2px;left:6px;width:1px;height:9px;background:#409eff}.es-tabs-nav-box .es-tabs-close:not(.disabled):hover:after,.es-tabs-nav-box .es-tabs-close:not(.disabled):hover:before{background:#fff}.es-tabs-nav-box .es-tabs-close.disabled:after,.es-tabs-nav-box .es-tabs-close.disabled:before{background:#d5d7dc}.es-tabs-nav-box .es-tabs-close.disabled{cursor:not-allowed}.es-tabs-nav-box .es-tabs-left-btn{display:none;margin:0;padding:0;width:13px;height:13px;line-height:16px;border:none;-webkit-box-sizing:border-box;box-sizing:border-box;border-radius:50%;cursor:pointer;outline:none;background-color:#fbfbfb;position:absolute;left:1px;top:1px}.es-tabs-nav-box .es-tabs-left-btn:not(.disabled):hover{background:#c0c4cc!important}.es-tabs-nav-box .es-tabs-left-btn .es-arrow{margin:0;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:4px 4px 4px 0;border-color:transparent #409eff transparent transparent;position:relative;margin-right:1px}.es-tabs-nav-box .es-tabs-left-btn .es-arrow:before{content:\"\";display:block;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:4px 4px 4px 0;border-color:transparent #fbfbfb transparent transparent;margin:0;position:absolute;top:-4px;left:1px}.es-tabs-nav-box .es-tabs-left-btn:not(.disabled):hover .es-arrow{border-right-color:#fff}.es-tabs-nav-box .es-tabs-left-btn:not(.disabled):hover .es-arrow:before{border-right-color:#c0c4cc}.es-tabs-nav-box .es-tabs-left-btn.disabled .es-arrow{border-right-color:#d5d7dc;cursor:not-allowed}.es-tabs-nav-box .es-tabs-right-btn{display:none;margin:0;padding:0;width:13px;height:13px;line-height:16px;border:none;-webkit-box-sizing:border-box;box-sizing:border-box;border-radius:50%;cursor:pointer;outline:none;background-color:#fbfbfb;position:absolute;right:1px;top:1px}.es-tabs-nav-box .es-tabs-right-btn:not(.disabled):hover{background:#c0c4cc!important}.es-tabs-nav-box .es-tabs-right-btn .es-arrow{margin:0;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:4px 0 4px 4px;border-color:transparent transparent transparent #409eff;position:relative;margin-left:1px}.es-tabs-nav-box .es-tabs-right-btn .es-arrow:before{content:\"\";display:block;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:4px 0 4px 4px;border-color:transparent transparent transparent #fbfbfb;margin:0;position:absolute;top:-4px;left:-5px}.es-tabs-nav-box .es-tabs-right-btn:not(.disabled):hover .es-arrow{border-left-color:#fff}.es-tabs-nav-box .es-tabs-right-btn:not(.disabled):hover .es-arrow:before{border-left-color:#c0c4cc}.es-tabs-nav-box .es-tabs-right-btn.disabled .es-arrow{border-left-color:#d5d7dc;cursor:not-allowed}", ""]);
// exports
/***/ }),
/***/ "bcaa":
/***/ (function(module, exports, __webpack_require__) {
var anObject = __webpack_require__("cb7c");
var isObject = __webpack_require__("d3f4");
var newPromiseCapability = __webpack_require__("a5b8");
module.exports = function (C, x) {
anObject(C);
if (isObject(x) && x.constructor === C) return x;
var promiseCapability = newPromiseCapability.f(C);
var resolve = promiseCapability.resolve;
resolve(x);
return promiseCapability.promise;
};
/***/ }),
/***/ "bdcb":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* WEBPACK VAR INJECTION */(function(process) {/* harmony import */ var E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_keys__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("a4bb");
/* harmony import */ var E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_keys__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_keys__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _index_vue__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("d23b");
/* harmony import */ var _libs_schema_utils__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__("34bc");
/* harmony import */ var _libs_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__("4513");
/* harmony import */ var _libs_global_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__("394e");
// import esBase from "./base";
// import esRules from "./libs/rules.js";
// import esConstant from "./libs/constant";
var install = function install(Vue) {
var globalOpts = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
/* istanbul ignore if */
if (install.installed) return; // 保存外部传入来的Vue(如用来判断vnode)
_libs_utils__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].initVue(Vue);
if (E_my_projects_vue_easy_form_node_modules_babel_runtime_corejs2_core_js_object_keys__WEBPACK_IMPORTED_MODULE_0___default()(globalOpts).length > 0) {
_libs_utils__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].mergeGlobal(_libs_global_js__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"], globalOpts); // console.log(esGlobal);
} // Vue.component(esConstant.HELP_NAME, esHelp);
// Vue.component("es-base", esBase);
Vue.component("es-form", _index_vue__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"]);
};
var check = function check(schema) {
return _libs_schema_utils__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].check(schema);
};
/* istanbul ignore if */
if (typeof window !== "undefined" && window.Vue) {
install(window.Vue);
}
/* harmony default export */ __webpack_exports__["a"] = ({
version: typeof process != "undefined" ? "1.8.6" : "??",
install: install,
esForm: _index_vue__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"],
check: check
});
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__("4362")))
/***/ }),
/***/ "be13":
/***/ (function(module, exports) {
// 7.2.1 RequireObjectCoercible(argument)
module.exports = function (it) {
if (it == undefined) throw TypeError("Can't call method on " + it);
return it;
};
/***/ }),
/***/ "be1e":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("14a3");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("bd46342e", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "bfe4":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, ".es-form-layout-tabs{overflow:hidden}.es-form-layout-tabs .es-tabs-body{margin:0;padding:0;list-style:none;border-style:solid;border-color:#e4e7ed;border-top:none;border-radius:0 0 4px 4px;text-align:left}.es-form-layout-tabs .es-tabs-body li{position:relative;margin:0 auto 0 0;padding:0;left:0;top:0}", ""]);
// exports
/***/ }),
/***/ "c366":
/***/ (function(module, exports, __webpack_require__) {
// false -> Array#indexOf
// true -> Array#includes
var toIObject = __webpack_require__("6821");
var toLength = __webpack_require__("9def");
var toAbsoluteIndex = __webpack_require__("77f1");
module.exports = function (IS_INCLUDES) {
return function ($this, el, fromIndex) {
var O = toIObject($this);
var length = toLength(O.length);
var index = toAbsoluteIndex(fromIndex, length);
var value;
// Array#includes uses SameValueZero equality algorithm
// eslint-disable-next-line no-self-compare
if (IS_INCLUDES && el != el) while (length > index) {
value = O[index++];
// eslint-disable-next-line no-self-compare
if (value != value) return true;
// Array#indexOf ignores holes, Array#includes - not
} else for (;length > index; index++) if (IS_INCLUDES || index in O) {
if (O[index] === el) return IS_INCLUDES || index || 0;
} return !IS_INCLUDES && -1;
};
};
/***/ }),
/***/ "c367":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var addToUnscopables = __webpack_require__("8436");
var step = __webpack_require__("50ed");
var Iterators = __webpack_require__("481b");
var toIObject = __webpack_require__("36c3");
// 22.1.3.4 Array.prototype.entries()
// 22.1.3.13 Array.prototype.keys()
// 22.1.3.29 Array.prototype.values()
// 22.1.3.30 Array.prototype[@@iterator]()
module.exports = __webpack_require__("30f1")(Array, 'Array', function (iterated, kind) {
this._t = toIObject(iterated); // target
this._i = 0; // next index
this._k = kind; // kind
// 22.1.5.2.1 %ArrayIteratorPrototype%.next()
}, function () {
var O = this._t;
var kind = this._k;
var index = this._i++;
if (!O || index >= O.length) {
this._t = undefined;
return step(1);
}
if (kind == 'keys') return step(0, index);
if (kind == 'values') return step(0, O[index]);
return step(0, [index, O[index]]);
}, 'values');
// argumentsList[@@iterator] is %ArrayProto_values% (9.4.4.6, 9.4.4.7)
Iterators.Arguments = Iterators.Array;
addToUnscopables('keys');
addToUnscopables('values');
addToUnscopables('entries');
/***/ }),
/***/ "c3a1":
/***/ (function(module, exports, __webpack_require__) {
// 19.1.2.14 / 15.2.3.14 Object.keys(O)
var $keys = __webpack_require__("e6f3");
var enumBugKeys = __webpack_require__("1691");
module.exports = Object.keys || function keys(O) {
return $keys(O, enumBugKeys);
};
/***/ }),
/***/ "c5f6":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var global = __webpack_require__("7726");
var has = __webpack_require__("69a8");
var cof = __webpack_require__("2d95");
var inheritIfRequired = __webpack_require__("5dbc");
var toPrimitive = __webpack_require__("6a99");
var fails = __webpack_require__("79e5");
var gOPN = __webpack_require__("9093").f;
var gOPD = __webpack_require__("11e9").f;
var dP = __webpack_require__("86cc").f;
var $trim = __webpack_require__("aa77").trim;
var NUMBER = 'Number';
var $Number = global[NUMBER];
var Base = $Number;
var proto = $Number.prototype;
// Opera ~12 has broken Object#toString
var BROKEN_COF = cof(__webpack_require__("2aeb")(proto)) == NUMBER;
var TRIM = 'trim' in String.prototype;
// 7.1.3 ToNumber(argument)
var toNumber = function (argument) {
var it = toPrimitive(argument, false);
if (typeof it == 'string' && it.length > 2) {
it = TRIM ? it.trim() : $trim(it, 3);
var first = it.charCodeAt(0);
var third, radix, maxCode;
if (first === 43 || first === 45) {
third = it.charCodeAt(2);
if (third === 88 || third === 120) return NaN; // Number('+0x1') should be NaN, old V8 fix
} else if (first === 48) {
switch (it.charCodeAt(1)) {
case 66: case 98: radix = 2; maxCode = 49; break; // fast equal /^0b[01]+$/i
case 79: case 111: radix = 8; maxCode = 55; break; // fast equal /^0o[0-7]+$/i
default: return +it;
}
for (var digits = it.slice(2), i = 0, l = digits.length, code; i < l; i++) {
code = digits.charCodeAt(i);
// parseInt parses a string to a first unavailable symbol
// but ToNumber should return NaN if a string contains unavailable symbols
if (code < 48 || code > maxCode) return NaN;
} return parseInt(digits, radix);
}
} return +it;
};
if (!$Number(' 0o1') || !$Number('0b1') || $Number('+0x1')) {
$Number = function Number(value) {
var it = arguments.length < 1 ? 0 : value;
var that = this;
return that instanceof $Number
// check on 1..constructor(foo) case
&& (BROKEN_COF ? fails(function () { proto.valueOf.call(that); }) : cof(that) != NUMBER)
? inheritIfRequired(new Base(toNumber(it)), that, $Number) : toNumber(it);
};
for (var keys = __webpack_require__("9e1e") ? gOPN(Base) : (
// ES3:
'MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,' +
// ES6 (in case, if modules with ES6 Number statics required before):
'EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,' +
'MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger'
).split(','), j = 0, key; keys.length > j; j++) {
if (has(Base, key = keys[j]) && !has($Number, key)) {
dP($Number, key, gOPD(Base, key));
}
}
$Number.prototype = proto;
proto.constructor = $Number;
__webpack_require__("2aba")(global, NUMBER, $Number);
}
/***/ }),
/***/ "c69a":
/***/ (function(module, exports, __webpack_require__) {
module.exports = !__webpack_require__("9e1e") && !__webpack_require__("79e5")(function () {
return Object.defineProperty(__webpack_require__("230e")('div'), 'a', { get: function () { return 7; } }).a != 7;
});
/***/ }),
/***/ "c8bb":
/***/ (function(module, exports, __webpack_require__) {
module.exports = __webpack_require__("54a1");
/***/ }),
/***/ "ca5a":
/***/ (function(module, exports) {
var id = 0;
var px = Math.random();
module.exports = function (key) {
return 'Symbol('.concat(key === undefined ? '' : key, ')_', (++id + px).toString(36));
};
/***/ }),
/***/ "cadf":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var addToUnscopables = __webpack_require__("9c6c");
var step = __webpack_require__("d53b");
var Iterators = __webpack_require__("84f2");
var toIObject = __webpack_require__("6821");
// 22.1.3.4 Array.prototype.entries()
// 22.1.3.13 Array.prototype.keys()
// 22.1.3.29 Array.prototype.values()
// 22.1.3.30 Array.prototype[@@iterator]()
module.exports = __webpack_require__("01f9")(Array, 'Array', function (iterated, kind) {
this._t = toIObject(iterated); // target
this._i = 0; // next index
this._k = kind; // kind
// 22.1.5.2.1 %ArrayIteratorPrototype%.next()
}, function () {
var O = this._t;
var kind = this._k;
var index = this._i++;
if (!O || index >= O.length) {
this._t = undefined;
return step(1);
}
if (kind == 'keys') return step(0, index);
if (kind == 'values') return step(0, O[index]);
return step(0, [index, O[index]]);
}, 'values');
// argumentsList[@@iterator] is %ArrayProto_values% (9.4.4.6, 9.4.4.7)
Iterators.Arguments = Iterators.Array;
addToUnscopables('keys');
addToUnscopables('values');
addToUnscopables('entries');
/***/ }),
/***/ "cb7c":
/***/ (function(module, exports, __webpack_require__) {
var isObject = __webpack_require__("d3f4");
module.exports = function (it) {
if (!isObject(it)) throw TypeError(it + ' is not an object!');
return it;
};
/***/ }),
/***/ "cbef":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("e5a0");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("2f1e47df", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "ce10":
/***/ (function(module, exports, __webpack_require__) {
var has = __webpack_require__("69a8");
var toIObject = __webpack_require__("6821");
var arrayIndexOf = __webpack_require__("c366")(false);
var IE_PROTO = __webpack_require__("613b")('IE_PROTO');
module.exports = function (object, names) {
var O = toIObject(object);
var i = 0;
var result = [];
var key;
for (key in O) if (key != IE_PROTO) has(O, key) && result.push(key);
// Don't enum bug & hidden keys
while (names.length > i) if (has(O, key = names[i++])) {
~arrayIndexOf(result, key) || result.push(key);
}
return result;
};
/***/ }),
/***/ "ce7e":
/***/ (function(module, exports, __webpack_require__) {
// most Object methods by ES6 should accept primitives
var $export = __webpack_require__("63b6");
var core = __webpack_require__("584a");
var fails = __webpack_require__("294c");
module.exports = function (KEY, exec) {
var fn = (core.Object || {})[KEY] || Object[KEY];
var exp = {};
exp[KEY] = exec(fn);
$export($export.S + $export.F * fails(function () { fn(1); }), 'Object', exp);
};
/***/ }),
/***/ "d0e9":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_help_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("73c1");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_help_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_help_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_help_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "d23b":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/index.vue?vue&type=template&id=92363cec&
var packagevue_type_template_id_92363cec_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"es-form"},[_c('form-item',{ref:"formFrame",attrs:{"schema":_vm.formSchema}}),(_vm.canConsole)?_c('consolePanel',{attrs:{"rootValue":_vm.csRootValue,"formValue":_vm.csFormValue}}):_vm._e()],1)}
var staticRenderFns = []
// CONCATENATED MODULE: ./src/package/index.vue?vue&type=template&id=92363cec&
// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/json/stringify.js
var stringify = __webpack_require__("f499");
var stringify_default = /*#__PURE__*/__webpack_require__.n(stringify);
// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/object/assign.js
var object_assign = __webpack_require__("5176");
var assign_default = /*#__PURE__*/__webpack_require__.n(object_assign);
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.dom.iterable.js
var web_dom_iterable = __webpack_require__("ac6a");
// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/object/keys.js
var object_keys = __webpack_require__("a4bb");
var keys_default = /*#__PURE__*/__webpack_require__.n(object_keys);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.function.name.js
var es6_function_name = __webpack_require__("7f7f");
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.regexp.replace.js
var es6_regexp_replace = __webpack_require__("a481");
// EXTERNAL MODULE: ./node_modules/core-js/modules/es7.array.includes.js
var es7_array_includes = __webpack_require__("6762");
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.string.includes.js
var es6_string_includes = __webpack_require__("2fdb");
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.regexp.split.js
var es6_regexp_split = __webpack_require__("28a5");
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/form-item.vue?vue&type=template&id=50cb9797&
var form_itemvue_type_template_id_50cb9797_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"es-form-item"},[(_vm.needHeader)?_c('div',{class:['es-form-header', _vm.schema.ui ? 'es-form-' + _vm.schema.ui.type : '']},[(_vm.schema.title && !_vm.schema.title.hidden)?_c('div',{class:['es-form-title', 'es-title-l' + _vm.schema.title.__level]},[(!_vm.schema.title.name)?_c('span',[_vm._v("\n "+_vm._s(_vm.schema.title.text)+"\n ")]):_c('es-base',{attrs:{"config":_vm.schema.title,"info":_vm.schema.__info}}),(_vm.schema.title.help && !_vm.schema.title.help.hidden)?_c('div',{staticClass:"es-form-label-help"},[_c('es-base',{attrs:{"config":_vm.schema.title.help,"info":_vm.schema.__info}})],1):_vm._e()],1):_c('div',{staticClass:"es-form-title es-title-empty"},[_vm._v(" ")]),(_vm.schema.ui && _vm.schema.ui.__hasToggle)?_c('div',{staticClass:"es-more-btn",on:{"click":_vm.toggleBody}},[_vm._v("\n "+_vm._s(_vm.schema.ui.showBody
? _vm.schema.ui.toggleTexts[1]
: _vm.schema.ui.toggleTexts[0])+"\n ")]):_vm._e(),(_vm.schema.help && !_vm.schema.help.hidden)?_c('div',{staticClass:"es-form-help"},[_c('es-base',{attrs:{"config":_vm.schema.help,"info":_vm.schema.__info}})],1):_vm._e()]):_vm._e(),_c('div',{directives:[{name:"show",rawName:"v-show",value:(!_vm.schema.properties || _vm.schema.ui.showBody),expression:"!schema.properties || schema.ui.showBody"}],class:[
'es-form-body',
_vm.schema.ui && _vm.schema.ui.hasBorder ? 'es-body-border' : ''
],style:(_vm.bodyStyle)},[(!_vm.schema.array)?[(_vm.schema.component)?_c('div',{class:[
'es-form-component',
_vm.schema.component.align
? 'es-form-component-' + _vm.schema.component.align
: ''
]},[_c('div',{class:[
'es-form-component-wrap',
_vm.schema.component.flex
? 'es-form-wrap-' + _vm.schema.component.flex
: ''
]},[_c('es-base',{ref:_vm.schema.component.ref,class:[
_vm.schema.component.flex
? 'es-form-component-' + _vm.schema.component.flex
: ''
],attrs:{"info":_vm.schema.__info,"is-main":true,"config":_vm.schema.component},on:{"trigger":_vm.triggerHandler}})],1),(_vm.schema.unit && !_vm.schema.unit.hidden && !_vm.schema.__inGroups)?[(_vm.schema.unit.name)?_c('div',{staticClass:"es-form-unit"},[_c('es-base',{attrs:{"config":_vm.schema.unit,"info":_vm.schema.__info}})],1):_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.schema.unit.text),expression:"schema.unit.text"}],staticClass:"es-form-unit"},[_vm._v("\n "+_vm._s(_vm.schema.unit.text)+"\n ")])]:_vm._e(),(_vm.schema.help && !_vm.schema.help.hidden && !_vm.schema.__inGroups)?_c('div',{staticClass:"es-form-help"},[_c('es-base',{attrs:{"config":_vm.schema.help,"info":_vm.schema.__info}})],1):_vm._e()],2):(
_vm.schema.properties && _vm.schema.layout && _vm.schema.layout.name === 'tabs'
)?_c('tabs',{tag:"component",attrs:{"schema":_vm.schema}},[_vm._l((_vm.schema.properties),function(fieldSchema,fieldName){return _c('template',{slot:fieldName},[_c('form-item',{key:fieldName,ref:fieldSchema.__hasRef && !fieldSchema.hidden
? _vm.REF_FORM_ITEM
: undefined,refInFor:true,attrs:{"schema":fieldSchema,"refName":fieldName}})],1)})],2):(_vm.schema.properties)?_c('es-object',{tag:"component",attrs:{"schema":_vm.schema}},[_vm._l((_vm.schema.properties),function(fieldSchema,fieldName){return _c('template',{slot:fieldName},[_c('form-item',{key:fieldName,ref:fieldSchema.__hasRef && !fieldSchema.hidden
? _vm.REF_FORM_ITEM
: undefined,refInFor:true,attrs:{"schema":fieldSchema,"refName":fieldName}})],1)})],2):_vm._e()]:[(_vm.schema.array.name == 'array')?_c('array-row',{tag:"component",attrs:{"schema":_vm.schema},on:{"input":_vm.formArrayInput},scopedSlots:_vm._u([_vm._l((_vm.schema.properties),function(fieldSchema,fieldName){return {key:fieldName,fn:function(props){return [_c('form-item',{key:fieldName,ref:fieldSchema.__hasRef ? _vm.REF_FORM_ITEM : undefined,refInFor:true,attrs:{"schema":props.schema,"refName":props.refName}})]}}}),{key:"default",fn:function(props){return (_vm.schema.component)?_c('div',{staticClass:"es-form-component-list"},_vm._l((1),function(key){return _c('form-item',{key:key,ref:_vm.schema.__hasRef ? _vm.REF_FORM_ITEM : undefined,refInFor:true,attrs:{"schema":props.schema,"refName":props.refName}})}),1):_vm._e()}}],null,true)}):_vm._e(),(_vm.schema.array.name == 'array-legend')?_c('array-legend',{tag:"component",attrs:{"schema":_vm.schema},on:{"input":_vm.formArrayInput},scopedSlots:_vm._u([_vm._l((_vm.schema.properties),function(fieldSchema,fieldName){return {key:fieldName,fn:function(props){return [_c('form-item',{key:fieldName,ref:fieldSchema.__hasRef ? _vm.REF_FORM_ITEM : undefined,refInFor:true,attrs:{"schema":props.schema,"refName":props.refName}})]}}}),{key:"default",fn:function(props){return (_vm.schema.component)?_c('div',{staticClass:"es-form-component-list"},_vm._l((1),function(key){return _c('form-item',{key:key,ref:_vm.schema.__hasRef ? _vm.REF_FORM_ITEM : undefined,refInFor:true,attrs:{"schema":props.schema,"refName":props.refName}})}),1):_vm._e()}}],null,true)}):_vm._e(),(_vm.schema.array.name == 'array-card')?_c('array-card',{tag:"component",attrs:{"schema":_vm.schema},on:{"input":_vm.formArrayInput},scopedSlots:_vm._u([{key:"default",fn:function(props){return (_vm.schema.component)?_c('div',{staticClass:"es-form-component-list"},_vm._l((1),function(key){return _c('form-item',{key:key,ref:_vm.schema.__hasRef ? _vm.REF_FORM_ITEM : undefined,refInFor:true,attrs:{"schema":props.schema,"refName":props.refName}})}),1):_vm._e()}}],null,true)}):(_vm.schema.array.name == 'array-table')?_c('array-table',{tag:"component",attrs:{"schema":_vm.schema},on:{"input":_vm.formArrayInput},scopedSlots:_vm._u([_vm._l((_vm.schema.properties),function(fieldSchema,fieldName){return {key:fieldName,fn:function(props){return [_c('form-item',{key:fieldName,ref:fieldSchema.__hasRef ? _vm.REF_FORM_ITEM : undefined,refInFor:true,attrs:{"schema":props.schema,"refName":props.refName}})]}}})],null,true)}):(_vm.schema.array && _vm.schema.array.name == 'array-tabs')?_c('array-tabs',{tag:"component",attrs:{"schema":_vm.schema},on:{"input":_vm.formArrayInput},scopedSlots:_vm._u([_vm._l((_vm.schema.properties),function(fieldSchema,fieldName){return {key:fieldName,fn:function(props){return [_c('form-item',{key:fieldName,ref:fieldSchema.__hasRef ? _vm.REF_FORM_ITEM : undefined,refInFor:true,attrs:{"schema":props.schema,"refName":props.refName}})]}}}),{key:"default",fn:function(props){return (_vm.schema.component)?_c('div',{staticClass:"es-form-component-list"},_vm._l((1),function(key){return _c('form-item',{key:key,ref:_vm.schema.__hasRef ? _vm.REF_FORM_ITEM : undefined,refInFor:true,attrs:{"schema":props.schema,"refName":props.refName}})}),1):_vm._e()}}],null,true)}):_vm._e()],(!_vm.schema.array)?[(_vm.schema.rules)?_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.schema.__invalidMsg),expression:"schema.__invalidMsg"}],staticClass:"es-form-error",class:_vm.schema.rules.class,style:(_vm.schema.rules.style)},[_vm._v("\n "+_vm._s(_vm.schema.__invalidMsg)+"\n ")]):_vm._e()]:[(_vm.schema.array.rules)?_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.schema.__invalidMsg),expression:"schema.__invalidMsg"}],staticClass:"es-form-error",class:_vm.schema.array.rules.class,style:(_vm.schema.array.rules.style)},[_vm._v("\n "+_vm._s(_vm.schema.__invalidMsg)+"\n ")]):_vm._e()],(_vm.schema.desc && !_vm.schema.desc.hidden)?[(_vm.schema.desc.name)?_c('div',{staticClass:"es-form-desc"},[_c('es-base',{attrs:{"config":_vm.schema.desc,"info":_vm.schema.__info}})],1):_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.schema.desc.text),expression:"schema.desc.text"}],staticClass:"es-form-desc"},[_vm._v("\n "+_vm._s(_vm.schema.desc.text)+"\n ")])]:_vm._e()],2)])}
var form_itemvue_type_template_id_50cb9797_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/form-item.vue?vue&type=template&id=50cb9797&
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/object.vue?vue&type=template&id=3ebaa6c6&
var objectvue_type_template_id_3ebaa6c6_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"es-form-container"},[_c('div',{staticClass:"es-form-inner-wrap",style:(_vm.schema.__hasCustomWidth
? { marginTop: -_vm.schema.ui.rowSpace + 'px' }
: null)},[_vm._l((_vm.schema.properties),function(fieldSchema,fieldName){return [(fieldSchema.__groups)?_c('div',{directives:[{name:"show",rawName:"v-show",value:(!fieldSchema.__hiddenGroup),expression:"!fieldSchema.__hiddenGroup"}],key:'groups-' + fieldName,staticClass:"es-form-object",style:(fieldSchema.__style)},[_vm._l((fieldSchema.__groups),function(fieldKeyName){return [(_vm.schema.properties[fieldKeyName].component)?[(
_vm.schema.properties[fieldKeyName].__creatable &&
_vm.schema.properties[fieldKeyName].label &&
!_vm.schema.properties[fieldKeyName].label.hidden
)?_c('label',{directives:[{name:"show",rawName:"v-show",value:(!_vm.schema.properties[fieldKeyName].hidden),expression:"!schema.properties[fieldKeyName].hidden"}],key:'label-' + fieldKeyName,class:[
'es-form-label-col',
_vm.schema.properties[fieldKeyName].label.flex
? 'es-form-label-' +
_vm.schema.properties[fieldKeyName].label.flex
: '',
_vm.schema.properties[fieldKeyName].label.align
? 'es-form-label-' +
_vm.schema.properties[fieldKeyName].label.align
: ''
],style:([
{
height: _vm.schema.properties[fieldKeyName].rowHeight + 'px',
lineHeight:
_vm.schema.properties[fieldKeyName].rowHeight + 'px',
marginLeft:
_vm.schema.properties[fieldKeyName].offsetLeft + 'px'
},
_vm.schema.properties[fieldKeyName].label.flex
? ''
: {
width: _vm.schema.properties[fieldKeyName].labelWidth + 'px'
}
])},[(
(_vm.schema.properties[fieldKeyName].array &&
_vm.schema.properties[fieldKeyName].array.rules &&
_vm.schema.properties[fieldKeyName].array.rules.required &&
_vm.schema.properties[fieldKeyName].array.rules
.showRequired) ||
(_vm.schema.properties[fieldKeyName].rules &&
!_vm.schema.properties[fieldKeyName].array &&
_vm.schema.properties[fieldKeyName].rules.required &&
_vm.schema.properties[fieldKeyName].rules.showRequired)
)?_c('span',{staticClass:"es-required"},[_vm._v("*")]):_vm._e(),(!_vm.schema.properties[fieldKeyName].label.name)?[_c('span',[_vm._v(_vm._s(_vm.schema.properties[fieldKeyName].label.text))])]:_c('span',{staticClass:"es-form-label-box"},[_c('es-base',{attrs:{"config":_vm.schema.properties[fieldKeyName].label,"info":_vm.schema.properties[fieldKeyName].__info}})],1),(
_vm.schema.properties[fieldKeyName].label.help &&
!_vm.schema.properties[fieldKeyName].label.help.hidden
)?_c('span',{staticClass:"es-form-label-help"},[_c('es-base',{attrs:{"config":_vm.schema.properties[fieldKeyName].label.help,"info":_vm.schema.properties[fieldKeyName].__info}})],1):_vm._e(),(_vm.schema.properties[fieldKeyName].colon)?_c('span',{staticClass:"es-form-colon"},[_vm._v(":")]):_vm._e()],2):_vm._e(),(_vm.schema.properties[fieldKeyName].__creatable)?_c('div',{directives:[{name:"show",rawName:"v-show",value:(!_vm.schema.properties[fieldKeyName].hidden),expression:"!schema.properties[fieldKeyName].hidden"}],key:'content-' + fieldKeyName,class:[
'es-form-comp-content',
_vm.schema.properties[fieldKeyName].component &&
_vm.schema.properties[fieldKeyName].component.flex
? 'es-form-group-' +
_vm.schema.properties[fieldKeyName].component.flex
: ''
],style:([
{
minHeight: _vm.schema.properties[fieldKeyName].rowHeight + 'px',
marginLeft:
!_vm.schema.properties[fieldKeyName].label ||
_vm.schema.properties[fieldKeyName].label.hidden
? _vm.schema.properties[fieldKeyName].offsetLeft + 'px'
: false,
marginRight:
_vm.schema.properties[fieldKeyName].offsetRight + 'px'
}
])},[_vm._t(fieldKeyName,null,{"schema":_vm.schema.properties[fieldKeyName]})],2):_vm._e(),(
_vm.schema.properties[fieldKeyName].unit &&
!_vm.schema.properties[fieldKeyName].unit.hidden &&
_vm.schema.properties[fieldKeyName].__creatable
)?[(_vm.schema.properties[fieldKeyName].unit.name)?_c('div',{directives:[{name:"show",rawName:"v-show",value:(!_vm.schema.properties[fieldKeyName].hidden),expression:"!schema.properties[fieldKeyName].hidden"}],key:'unit-' + fieldKeyName,staticClass:"es-form-unit",style:([
{ height: _vm.schema.properties[fieldKeyName].rowHeight + 'px' }
])},[_c('es-base',{attrs:{"config":_vm.schema.properties[fieldKeyName].unit,"info":_vm.schema.properties[fieldKeyName].__info}})],1):_c('div',{directives:[{name:"show",rawName:"v-show",value:(
!_vm.schema.properties[fieldKeyName].hidden &&
_vm.schema.properties[fieldKeyName].unit.text
),expression:"\n !schema.properties[fieldKeyName].hidden &&\n schema.properties[fieldKeyName].unit.text\n "}],key:'unit-' + fieldKeyName,staticClass:"es-form-unit",style:([
{ height: _vm.schema.properties[fieldKeyName].rowHeight + 'px' }
])},[_vm._v("\n "+_vm._s(_vm.schema.properties[fieldKeyName].unit.text)+"\n ")])]:_vm._e(),(
_vm.schema.properties[fieldKeyName].help &&
!_vm.schema.properties[fieldKeyName].help.hidden &&
_vm.schema.properties[fieldKeyName].__creatable
)?_c('div',{directives:[{name:"show",rawName:"v-show",value:(!_vm.schema.properties[fieldKeyName].hidden),expression:"!schema.properties[fieldKeyName].hidden"}],key:'help-' + fieldKeyName,staticClass:"es-form-help",style:([
{ height: _vm.schema.properties[fieldKeyName].rowHeight + 'px' }
])},[_c('es-base',{attrs:{"config":_vm.schema.properties[fieldKeyName].help,"info":_vm.schema.properties[fieldKeyName].__info}})],1):_vm._e()]:_c('div',{directives:[{name:"show",rawName:"v-show",value:(!_vm.schema.properties[fieldKeyName].hidden),expression:"!schema.properties[fieldKeyName].hidden"}],key:fieldKeyName,staticClass:"es-form-placeholder",style:(_vm.schema.properties[fieldKeyName].__style)})]})],2):(
!fieldSchema.__inGroups &&
(!fieldSchema.layout || fieldSchema.layout.name !== 'space')
)?[(fieldSchema.__creatable)?_c('div',{directives:[{name:"show",rawName:"v-show",value:(!fieldSchema.hidden),expression:"!fieldSchema.hidden"}],key:fieldName,class:[
'es-form-object',
fieldSchema.direction == 'v' ? 'es-form-v' : ''
],style:(fieldSchema.__style)},[(fieldSchema.label && !fieldSchema.label.hidden)?_c('label',{class:[
'es-form-label-col',
fieldSchema.direction == 'v' ? 'es-form-label-col-v' : '',
fieldSchema.label.flex
? 'es-form-label-' + fieldSchema.label.flex
: '',
fieldSchema.label.align
? 'es-form-label-' + fieldSchema.label.align
: ''
],style:(fieldSchema.direction == 'h'
? [
{
height: fieldSchema.rowHeight + 'px',
lineHeight: fieldSchema.rowHeight + 'px'
},
fieldSchema.label.flex
? {}
: {
width: fieldSchema.labelWidth + 'px'
}
]
: {})},[(
(fieldSchema.array &&
fieldSchema.array.rules &&
fieldSchema.array.rules.required &&
fieldSchema.array.rules.showRequired) ||
(fieldSchema.rules &&
!fieldSchema.array &&
fieldSchema.rules.required &&
fieldSchema.rules.showRequired)
)?_c('span',{staticClass:"es-required"},[_vm._v("*")]):_vm._e(),(!fieldSchema.label.name)?[_c('span',[_vm._v(_vm._s(fieldSchema.direction != "v" || fieldSchema.label.text
? fieldSchema.label.text
: " "))])]:_c('span',{staticClass:"es-form-label-box"},[_c('es-base',{attrs:{"config":fieldSchema.label,"info":fieldSchema.__info}})],1),(fieldSchema.label.help && !fieldSchema.label.help.hidden)?_c('span',{staticClass:"es-form-label-help"},[_c('es-base',{attrs:{"config":fieldSchema.label.help,"info":fieldSchema.__info}})],1):_vm._e(),(fieldSchema.colon)?_c('span',{staticClass:"es-form-colon"},[_vm._v(":")]):_vm._e()],2):_vm._e(),_c('div',{class:fieldSchema.properties
? 'es-form-props-content'
: 'es-form-comp-content',style:(fieldSchema.direction == 'h'
? [{ minHeight: fieldSchema.rowHeight + 'px' }]
: '')},[_vm._t(fieldName)],2)]):_vm._e()]:(!fieldSchema.__inGroups && !fieldSchema.component)?_c('div',{directives:[{name:"show",rawName:"v-show",value:(!fieldSchema.hidden),expression:"!fieldSchema.hidden"}],key:fieldName,staticClass:"es-form-object",style:(fieldSchema.__style)}):_vm._e()]})],2)])}
var objectvue_type_template_id_3ebaa6c6_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/layout/object.vue?vue&type=template&id=3ebaa6c6&
// CONCATENATED MODULE: ./src/package/mixins/item-mixin.js
/* harmony default export */ var item_mixin = ({
props: {
schema: {
type: Object,
default: function _default() {
return {};
}
}
}
});
// EXTERNAL MODULE: ./src/package/libs/utils.js
var utils = __webpack_require__("4513");
// EXTERNAL MODULE: ./src/package/libs/constant.js
var constant = __webpack_require__("890a");
// CONCATENATED MODULE: ./src/package/libs/data-cache.js
/**
* data-cache.js
*
* Copyright (c) 2020 chengaohe All rights reserved.
*
* 用于记录表单数据
*
*/
// import utils from "./utils";
// import constant from "./constant";
var formDataMap = {}; // window.formDataMap = formDataMap;
var dataCache = {
__getData: function __getData(formId) {
if (!formDataMap[formId]) {
formDataMap[formId] = {};
}
return formDataMap[formId];
},
getRoot: function getRoot(formId, defaultValue) {
var data = this.__getData(formId);
return data.root ? data.root : defaultValue;
},
setRoot: function setRoot(formId, value) {
var data = this.__getData(formId);
data.root = value;
},
getGlobal: function getGlobal(formId, defaultValue) {
var data = this.__getData(formId);
return data.global ? data.global : defaultValue;
},
setGlobal: function setGlobal(formId, value) {
var data = this.__getData(formId);
data.global = value;
},
getHiddenFunc: function getHiddenFunc(formId) {
var data = this.__getData(formId);
return data.hiddenFunc;
},
setHiddenFunc: function setHiddenFunc(formId, value) {
var data = this.__getData(formId);
data.hiddenFunc = value;
},
remove: function remove(formId) {
if (formDataMap.hasOwnProperty(formId)) {
formDataMap[formId].hiddenFunc = null;
delete formDataMap[formId];
}
}
}; // window.dataCache = dataCache;
/* harmony default export */ var data_cache = (dataCache);
// EXTERNAL MODULE: ./src/package/libs/component-utils.js + 1 modules
var component_utils = __webpack_require__("45ac");
// CONCATENATED MODULE: ./src/package/base.js
/**
* base.js
*
* Copyright (c) 2019 chengaohe All rights reserved.
*
* 无缝对接vue组件
*
*/
"use strict";
/* harmony default export */ var base = ({
render: function render(createElement) {
return this.renderUi(createElement, this.config, false, constant["a" /* default */].COM_TARGET_REF);
},
// inheritAttrs: false,
props: {
config: {
type: Object,
required: true,
default: function _default() {
return {
name: "" //lg-element 组件 原生组件
// value: "",
// attrs: {},
// style: {},
// class: {},
// props: {}
};
}
},
// 当!!this.info为非真时,处理事件会让父级处理
info: {
type: Object,
required: true,
default: undefined
},
/* 是否是主组件:也就是右边的组件;当为真时,处理事件会让父级处理 */
isMain: {
type: Boolean,
required: false,
default: false
}
},
data: function data() {
return {
emitOn: null,
nativeOn: null,
scopedSlots: undefined
};
},
created: function created() {
this.initUi();
},
methods: {
initUi: function initUi() {
var ref = constant["a" /* default */].COM_TARGET_REF;
this.$data.emitOn = this.createEmitOn(this.config, this.isMain, ref);
this.$data.nativeOn = this.createNativeOn(this.config, this.isMain, ref);
this.$data.scopedSlots = this.createScopedSlots(this.config, ref);
},
/**
* 渲染函数
* @param {*} createElement 创建VNode的函数
* @param {*} config 组件设置
* @param {*} isSlotCom 是否插槽的组件,因为事件不一样,插槽数据也不一样
* @returns VNode
*/
renderUi: function renderUi(createElement, config, isSlotCom, ref) {
var vnode; // 根据vue源代码, VNode是不会被劫持的
if (utils["a" /* default */].isVNode(config)) {
vnode = config;
} else if (utils["a" /* default */].isObj(config)) {
if (!config.name) {
console.error("错误的config: ", config);
throw "es-base config.name必须存在";
} // 防止props不存在
var configProps = config.props ? config.props : {}; // 计算出props, attrs
var newProps = {};
var newAttrs = {};
var domProps = {};
var directives = config.directives ? utils["a" /* default */].deepCopy(config.directives) : []; // false, 不是数组也没有事
var componentName = config.name.toLowerCase ? config.name.toLowerCase() : config.name;
if (componentName === constant["a" /* default */].TAG_INPUT && ( // 不区分大小写
configProps.type === constant["a" /* default */].TYPE_RADIO || configProps.type === constant["a" /* default */].TYPE_CHECKBOX)) {
if (configProps.type === constant["a" /* default */].TYPE_RADIO) {
assign_default()(newAttrs, configProps);
if (config.hasOwnProperty("value")) {
// 用户设置了value的情况
newAttrs.checked = config.value === configProps.value;
} else {
// 没有用户value
newAttrs.checked = configProps.hasOwnProperty("checked") && configProps.checked !== false ? true : false;
}
assign_default()(newProps, configProps);
if (newProps.hasOwnProperty("checked")) {
delete newProps.checked;
}
domProps.checked = newAttrs.checked;
} else {
var checked = false;
if (config.hasOwnProperty("value")) {
if (!utils["a" /* default */].isUndef(configProps.trueValue)) {
// 经测试,若指定了trueValue,无论falseValue是否指定,只有值等于trueValue,checked才为true
if (config.value === configProps.trueValue) {
checked = true;
} else {
checked = false;
}
} else if (!utils["a" /* default */].isUndef(configProps.falseValue)) {
// 经测试:当trueValue没有指定,falseValue指定,只有值等于falseValue,checked才为false
if (config.value === configProps.falseValue) {
checked = false;
} else {
checked = true;
}
} else {
// 经测试:当trueValue和falseValue没有指定,checked才为!!config.value
checked = !!config.value;
}
} else {
checked = configProps.hasOwnProperty("checked") && configProps.checked !== false ? true : false;
}
assign_default()(newAttrs, configProps);
newAttrs.checked = checked;
assign_default()(newProps, configProps);
if (newProps.hasOwnProperty("checked")) {
delete newProps.checked;
}
domProps.checked = newAttrs.checked;
}
} else {
var newValue;
if (config.hasOwnProperty("value")) {
newValue = utils["a" /* default */].isRefVal(config.value) ? utils["a" /* default */].deepCopy(config.value) : config.value; // 这样防止引用地址被组件内部修改
} else {
newValue = configProps.value;
}
if (!constant["a" /* default */].FORM_INPUTS.includes(componentName)) {
assign_default()(newAttrs, configProps);
if (newAttrs.hasOwnProperty("value")) {
delete newAttrs.value;
}
assign_default()(newProps, configProps);
newProps.value = newValue;
} else {
assign_default()(newAttrs, configProps);
if (newAttrs.hasOwnProperty("value")) {
delete newAttrs.value;
}
assign_default()(newProps, configProps);
if (newProps.hasOwnProperty("value")) {
delete newProps.value;
} // 经测试(value):
// textarea必须要在domProps才能显示;
// input第一次可以在newAttrs写,之后也要在domProps才能显示值,所以也要是domProps才保险
domProps.value = newValue;
}
}
var emitOn, nativeOn, scopedSlots, tmpRef;
if (!isSlotCom) {
// 内容组件,非插槽组件: 因为常用,所以计算好(为什么这里要弄一个副本,因为this.$data.emitOn直接赋值于createElement事件on中,在初化时会执行两次,具体原因估计看vue的实现方式)
emitOn = this.$data.emitOn ? assign_default()({}, this.$data.emitOn) : null;
nativeOn = this.$data.nativeOn ? assign_default()({}, this.$data.nativeOn) : null;
scopedSlots = this.$data.scopedSlots;
} else {
// 很少用,且scopedSlots有可能包含函数,必须实时解析
emitOn = this.createEmitOn(config, false, ref);
nativeOn = this.createNativeOn(config, false, ref);
scopedSlots = this.createScopedSlots(config, ref);
} // COM_TARGET_REF时ref必须存在,因为要搜索
if (ref === constant["a" /* default */].COM_TARGET_REF || emitOn || nativeOn) {
tmpRef = ref;
}
vnode = createElement(config.name, // tag name 标签名称 https://www.cnblogs.com/tugenhua0707/p/7528621.html
{
attrs: newAttrs,
//attrs为原生属性
// 类型要求见:https://cn.vuejs.org/v2/guide/class-and-style.html
// config.class必须是String,Object, Array才能有效;当然传入其它类型也可以,只是没有效果,也不会报错,因为createElement会做处理
class: config.class,
style: config.style,
// config.style必须是一个对象才能有效;原理同上
domProps: domProps,
// DOM属性
props: newProps,
// 组件props
// 事件监听基于 "on"
// 所以不再支持如 "v-on:keyup.enter" 修饰语
// 需要手动匹配 KeyCode
on: emitOn,
// 仅对于组件,用于监听原生事件,而不是组件内部使用 `vm.$emit` 触发的事件。
nativeOn: nativeOn,
// 自定义指令。注意事项:不能对绑定的旧值设值
// Vue 会为您持续追踪
directives: directives,
// Scoped slots in the form of
scopedSlots: scopedSlots,
ref: tmpRef
}, config.text); // 去除多余的原生属性;去不去掉感觉都没有什么,好像没有影响到功能,只是页面上会显示原生属性
var componentOptions = vnode.componentOptions;
var dataAttrs = {};
var comProps = componentOptions && componentOptions.Ctor.options.props ? componentOptions.Ctor.options.props : false;
if (keys_default()(newProps || {}).length) {
var comPropsKeys = keys_default()(comProps || {}); // 经测试:就算在定义中声明为中划线形式,这里也会返回驼峰式,如 'text-str' => 'textStr'
var key;
for (key in newProps) {
if (!comPropsKeys.includes(key)) {
dataAttrs[key] = newProps[key];
}
} // newAttrs要在newProps后处理,因为在vnode.data.attrs要保留newAttrs的值
for (key in newAttrs) {
if (!comPropsKeys.includes(key)) {
dataAttrs[key] = newAttrs[key];
}
} // if (config.name === "el-input") {
// console.log("dataAttrs", utils.deepCopy(dataAttrs));
// console.log("1 vnode.data.attrs", utils.deepCopy(vnode.data.attrs));
// console.log("newProps", utils.deepCopy(newProps));
// }
if (vnode.data) {
vnode.data.attrs = dataAttrs;
} // if (config.name === "g-test-com") {
// console.log("2 vnode.data.attrs", utils.deepCopy(vnode.data.attrs));
// }
}
newAttrs = null;
newProps = null;
domProps = null;
directives = null;
configProps = null;
} else if (utils["a" /* default */].isFunc(config)) {
var options = {
global: data_cache.getGlobal(this.config.__formId),
// 直接取组件__formId,插槽是没有__formId的
rootData: data_cache.getRoot(this.config.__formId),
// 兼容1.7.0以前,不包括1.7.0
root: data_cache.getRoot(this.config.__formId),
idxChain: this.info.idxChain,
index: this.info.index,
pathKey: this.info.pathKey,
$hidden: data_cache.getHiddenFunc(this.config.__formId)
};
vnode = config(options);
if (!utils["a" /* default */].isVNode(vnode)) {
vnode = this.renderUi(createElement, vnode, isSlotCom, ref);
}
options = null;
} else if (utils["a" /* default */].isStr(vnode) || utils["a" /* default */].isUndef(vnode) || utils["a" /* default */].isNum(vnode) || utils["a" /* default */].isBool(vnode) || utils["a" /* default */].isNull(vnode)) {
vnode = createElement("span", vnode); // 经验证,这样写没有问题:vnode不用加""
} else {
console.error("错误的config: ", config);
throw "es-base config当是一个函数时,其返回值必须是一个虚拟节点或字符串";
} // 这个不能删除:vue机制,主要是为了执行config.__refreshIndex;当表单改变时,同步更新页面
if (!isSlotCom && config && config.__refreshIndex && this.__slotUpdateTime) {
// 永远都不会进入这,因为__slotUpdateTime没有值的
this.__slotUpdateTime++;
}
return vnode;
},
eventHandler: function eventHandler(config, eventName, args, isMain, ref) {
args = args ? args : []; // console.log("this.$refs", this.$refs);
if (isMain) {
// 主组件:让父类去处理
this.$emit("trigger", eventName, args, this.$refs[ref]);
} else {
// 一般组件,自己处理
var options = {
value: utils["a" /* default */].deepCopy(config.value),
event: args[0],
args: args,
pathKey: this.info.pathKey,
index: this.info.index,
idxChain: this.info.idxChain,
target: this.$refs[ref]
};
var handlers = [];
var actions = config.actions;
if (actions) {
actions.forEach(function (action) {
if (action.trigger && action.trigger.includes(eventName)) {
handlers.push(action.handler);
}
});
}
if (handlers.length > 0) {
var thisFrom = this.__getForm();
thisFrom._handleEvents(handlers, options);
}
}
},
__getForm: function __getForm() {
var formItem = this.$parent;
while (formItem) {
var type = formItem._getType ? formItem._getType() : "";
if (type == constant["a" /* default */].UI_FORM) {
// formItem._syncFormUi(checkSchema, eventNames, targetValue, eventData); // 最外层的表单层同步所有的ui及数位
return formItem; // 到达表单层
} else if (type == constant["a" /* default */].UI_ARRAY) {// checkSchema.push(formItem._getSchema());
} else {// ... 往上派
}
formItem = formItem.$parent;
}
},
__parseInputEvent: function __parseInputEvent(config, eventData) {
var eventValue;
if (eventData && eventData.target && eventData.target.nodeName) {
var tagName = eventData.target.tagName;
var nodeType = eventData.target.type;
if (tagName.toLowerCase() === constant["a" /* default */].TAG_INPUT) {
var configProps;
if (nodeType === constant["a" /* default */].TYPE_RADIO) {
// 防止props不存在
configProps = config.props ? config.props : {};
if (eventData.target.checked) {
eventValue = configProps.value;
} else {
eventValue = undefined;
}
} else if (nodeType === constant["a" /* default */].TYPE_CHECKBOX) {
// 防止props不存在
configProps = config.props ? config.props : {};
if (eventData.target.checked) {
eventValue = true;
if (!utils["a" /* default */].isUndef(configProps.trueValue)) {
eventValue = configProps.trueValue;
}
} else {
eventValue = false;
if (!utils["a" /* default */].isUndef(configProps.falseValue)) {
eventValue = configProps.falseValue;
}
}
} else {
eventValue = eventData.target.value;
}
} else {
eventValue = eventData.target.value;
}
} else {
eventValue = eventData;
}
return eventValue;
},
/**
* 创建emit派发所需要监听的事件
*/
createEmitOn: function createEmitOn(config, isMain, ref) {
var _thisVm = this;
var hasOwnValue = config.hasOwnProperty("value");
var emitEvents;
if (config.__emitEvents) {
emitEvents = utils["a" /* default */].deepCopy(config.__emitEvents);
if (hasOwnValue && !emitEvents.includes(constant["a" /* default */].INPUT_EVENT)) {
emitEvents.push(constant["a" /* default */].INPUT_EVENT);
}
} else {
if (hasOwnValue) {
emitEvents = [constant["a" /* default */].INPUT_EVENT];
} else {
emitEvents = [];
}
} // emit发出的事件
var emitOn = {};
emitEvents.forEach(function (eventName) {
if (eventName == constant["a" /* default */].INPUT_EVENT && hasOwnValue) {
emitOn[eventName] = function (eventData) {
var eventValue = _thisVm.__parseInputEvent(config, eventData);
if (config.value !== eventValue) {
config.value = eventValue;
_thisVm.eventHandler(config, eventName, arguments, isMain, ref);
}
};
} else {
emitOn[eventName] = function () {
_thisVm.eventHandler(config, eventName, arguments, isMain, ref);
};
}
});
if (keys_default()(emitOn).length > 0) {
return emitOn;
} else {
_thisVm = undefined; // 没有关联清除
return null;
}
},
/**
* 创建原生事件所需要监听的事件
*/
createNativeOn: function createNativeOn(config, isMain, ref) {
// emit发出的事件
if (config.__nativeEvents && config.__nativeEvents.length > 0) {
var _thisVm = this;
var nativeOn = {};
var nativeEvents = utils["a" /* default */].deepCopy(config.__nativeEvents);
nativeEvents.forEach(function (eventName) {
nativeOn[eventName] = function () {
_thisVm.eventHandler(config, eventName + "." + constant["a" /* default */].ADJ_NATIVE, arguments, isMain, ref);
};
});
if (keys_default()(nativeOn).length > 0) {
return nativeOn;
} else {
_thisVm = undefined;
return null;
}
} else {
return null;
}
},
createScopedSlots: function createScopedSlots(config, pref) {
var scopedSlots = config.scopedSlots;
if (scopedSlots) {
var newScopedSlots = {};
for (var key in scopedSlots) {
newScopedSlots[key] = this.newSlotFunc(key, scopedSlots[key], pref);
}
return newScopedSlots;
} else {
return undefined;
}
},
newSlotFunc: function newSlotFunc(key, slotValue, pref) {
var vm = this;
return function (scoped) {
var vnodes;
if (utils["a" /* default */].isFunc(slotValue)) {
var options = {
global: data_cache.getGlobal(vm.config.__formId),
rootData: data_cache.getRoot(vm.config.__formId),
// 兼容1.7.0以前,不包括1.7.0
root: data_cache.getRoot(vm.config.__formId),
idxChain: vm.info.idxChain,
index: vm.info.index,
pathKey: vm.info.pathKey,
$hidden: data_cache.getHiddenFunc(vm.config.__formId)
};
scoped = scoped ? scoped : {};
vnodes = slotValue(options, scoped);
if (!utils["a" /* default */].isArr(vnodes)) {
vnodes = [vnodes];
}
var tmpVNodes = [];
vnodes.forEach(function (vnode) {
if (!utils["a" /* default */].isVNode(vnode) && utils["a" /* default */].isObj(vnode)) {
var newComponent = Object(component_utils["f" /* parseComponent */])(vnode, vm.info.pathKey + "> scopeSlots(function返回值) > " + key, true, false);
if (newComponent) {
tmpVNodes.push(newComponent);
}
} else {
tmpVNodes.push(vnode);
}
});
vnodes = tmpVNodes;
} else {
vnodes = [slotValue];
}
var newVNode,
newVNodes = [];
vnodes.forEach(function (vnode, index) {
if (!utils["a" /* default */].isVNode(vnode) && utils["a" /* default */].isObj(vnode)) {
if (!vnode.hidden) {
newVNode = vm.renderUi(vm.$createElement, vnode, true, pref + "_" + index);
newVNodes.push(newVNode);
}
} else {
newVNodes.push(vnode);
}
});
if (newVNodes.length <= 0) {
newVNodes = undefined;
}
return newVNodes;
};
}
},
destroyed: function destroyed() {
this.$data.emitOn = null;
this.$data.nativeOn = null;
this.$data.scopedSlots = null;
},
watch: {
config: {
handler: function handler()
/* newVal, oldVal */
{
this.initUi();
},
deep: false
}
}
});
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/object.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
/* harmony default export */ var objectvue_type_script_lang_js_ = ({
mixins: [item_mixin],
data: function data() {
return {};
},
components: {
esBase: base
},
methods: {}
});
// CONCATENATED MODULE: ./src/package/layout/object.vue?vue&type=script&lang=js&
/* harmony default export */ var layout_objectvue_type_script_lang_js_ = (objectvue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/layout/object.vue?vue&type=style&index=0&lang=scss&
var objectvue_type_style_index_0_lang_scss_ = __webpack_require__("ac2a");
// EXTERNAL MODULE: ./node_modules/vue-loader/lib/runtime/componentNormalizer.js
var componentNormalizer = __webpack_require__("2877");
// CONCATENATED MODULE: ./src/package/layout/object.vue
/* normalize component */
var component = Object(componentNormalizer["a" /* default */])(
layout_objectvue_type_script_lang_js_,
objectvue_type_template_id_3ebaa6c6_render,
objectvue_type_template_id_3ebaa6c6_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var object = (component.exports);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/array-row.vue?vue&type=template&id=74bbd219&
var array_rowvue_type_template_id_74bbd219_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"es-form-array-box"},[_c('div',{staticClass:"es-form-array-wrap"},[_c('ul',{staticClass:"es-order-list-box"},_vm._l((_vm.schema.__propSchemaList),function(itemSchema,index){return _c('li',{key:index,staticClass:"list-item",style:({
marginTop: (index > 0 ? _vm.schema.array.rowSpace : 0) + 'px'
})},[(_vm.schema.array.hasOrder !== false)?_c('div',{staticClass:"es-order-box",style:({
height: _vm.schema.properties
? _vm.schema.ui.rowHeight + 'px'
: _vm.schema.rowHeight + 'px'
})},[(
itemSchema.rules &&
itemSchema.rules.required &&
itemSchema.rules.showRequired
)?_c('span',{staticClass:"es-required"},[_vm._v("*")]):_vm._e(),(_vm.schema.array.hasOrder !== false)?[_vm._v(_vm._s(index + 1)+".")]:_vm._e()],2):(
itemSchema.rules &&
itemSchema.rules.required &&
itemSchema.rules.showRequired
)?_c('div',{staticClass:"es-order-box-required",style:({
height: _vm.schema.properties
? _vm.schema.ui.rowHeight + 'px'
: _vm.schema.rowHeight + 'px'
})},[_c('span',{staticClass:"es-required"},[_vm._v("*")])]):_vm._e(),_c('div',{staticClass:"es-array-row-body"},[(
itemSchema.properties &&
itemSchema.layout &&
itemSchema.layout.name === 'tabs'
)?_c('tabs',{tag:"component",attrs:{"schema":itemSchema}},[_vm._l((itemSchema.properties),function(fieldSchema,fieldName){return _c('template',{slot:fieldName},[_vm._t(fieldName,null,{"refName":fieldName + '_' + index,"schema":fieldSchema})],2)})],2):(itemSchema.properties)?_c('es-object',{attrs:{"schema":itemSchema}},[_vm._l((itemSchema.properties),function(fieldSchema,fieldName){return _c('template',{slot:fieldName},[_vm._t(fieldName,null,{"refName":fieldName + '_' + index,"schema":fieldSchema})],2)})],2):[_vm._t("default",null,{"refName":index + '',"schema":itemSchema})]],2),(
_vm.schema.array.hasDelete ||
_vm.schema.array.hasSort ||
_vm.schema.array.hasCopy
)?_c('div',{staticClass:"es-btn-box",style:({
height: _vm.schema.properties
? _vm.schema.ui.rowHeight + 'px'
: _vm.schema.rowHeight + 'px'
})},[(_vm.schema.array.btnType !== 'icon')?_c('edit-btns',{attrs:{"has-delete":_vm.schema.array.hasDelete,"has-sort":_vm.schema.array.hasSort,"can-delete":_vm.schema.__propSchemaList.length > _vm.schema.array.min,"fixed":_vm.schema.array.fixed,"is-first":index == 0,"is-last":index == _vm.schema.__propSchemaList.length - 1,"index":index,"has-del-warn":_vm.schema.array.hasDelWarn,"can-add":_vm.schema.array.max <= 0 ||
_vm.schema.__propSchemaList.length < _vm.schema.array.max,"has-add":_vm.schema.array.hasCopy,"del-msg":itemSchema.delMsg,"del-warn-btns":itemSchema.delWarnBtns,"info":itemSchema.__info},on:{"copyItem":_vm.copyItem,"delItem":_vm.delItem,"upItem":_vm.upItem,"downItem":_vm.downItem}}):_c('edit-abbr-btns',{attrs:{"has-delete":_vm.schema.array.hasDelete,"has-sort":_vm.schema.array.hasSort,"can-delete":_vm.schema.__propSchemaList.length > _vm.schema.array.min,"fixed":_vm.schema.array.fixed,"is-first":index == 0,"is-last":index == _vm.schema.__propSchemaList.length - 1,"index":index,"has-del-warn":_vm.schema.array.hasDelWarn,"can-add":_vm.schema.array.max <= 0 ||
_vm.schema.__propSchemaList.length < _vm.schema.array.max,"has-add":_vm.schema.array.hasCopy,"del-msg":itemSchema.delMsg,"del-warn-btns":itemSchema.delWarnBtns,"info":itemSchema.__info},on:{"copyItem":_vm.copyItem,"delItem":_vm.delItem,"upItem":_vm.upItem,"downItem":_vm.downItem}})],1):_vm._e()])}),0),(_vm.schema.array.hasDelete || _vm.schema.array.hasAdd)?_c('div',{staticClass:"es-btn-footer",style:({
marginTop:
_vm.schema.__propSchemaList.length > 0
? Math.round(
Math.min(
Math.max(_vm.schema.array.rowSpace / 2, 10),
_vm.schema.array.rowSpace
)
) + 'px'
: '0px'
})},[_c('edit-bottom-btns',{attrs:{"has-delete":_vm.schema.array.hasDelete &&
_vm.schema.array.min <= 0 &&
_vm.schema.array.fixed <= 0,"has-add":_vm.schema.array.hasAdd,"can-delete":_vm.schema.__propSchemaList.length > 0 &&
_vm.schema.array.fixed <= 0 &&
_vm.schema.array.min <= 0,"can-add":_vm.schema.array.max <= 0 ||
_vm.schema.__propSchemaList.length < _vm.schema.array.max,"index":-1,"has-del-warn":_vm.schema.array.hasDelWarn,"del-msg":_vm.schema.array.delAllMsg,"del-warn-btns":_vm.schema.array.delWarnBtns,"info":_vm.schema.__info},on:{"delItem":_vm.delAllItems,"addItem":_vm.addItem}})],1):_vm._e()]),(_vm.schema.help && !_vm.schema.help.hidden && _vm.schema.component)?_c('div',{staticClass:"es-form-help",style:({
height: _vm.schema.properties
? _vm.schema.ui.rowHeight + 'px'
: _vm.schema.rowHeight + 'px'
})},[_c('es-base',{attrs:{"config":_vm.schema.help,"info":_vm.schema.__info}})],1):_vm._e()])}
var array_rowvue_type_template_id_74bbd219_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/layout/array-row.vue?vue&type=template&id=74bbd219&
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/tabs.vue?vue&type=template&id=43474d40&
var tabsvue_type_template_id_43474d40_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"es-form-layout-tabs"},[_c('es-tabs-nav',{attrs:{"type":_vm.schema.layout.type}},[_vm._l((_vm.schema.properties),function(itemSchema,fieldName){return [(!itemSchema.hidden)?_c('es-tabs-nav-item',{key:fieldName,attrs:{"is-active":fieldName === _vm.schema.__tabsIndex,"has-error":itemSchema.__hasError,"index":fieldName,"info":itemSchema.__info},on:{"clickActive":_vm.clickActiveHandler}},[_c('div',{staticClass:"es-tabs-item-label"},[(
(itemSchema.array &&
itemSchema.array.rules &&
itemSchema.array.rules.required &&
itemSchema.array.rules.showRequired) ||
(itemSchema.rules &&
!itemSchema.array &&
itemSchema.rules.required &&
itemSchema.rules.showRequired)
)?_c('span',{staticClass:"es-required"},[_vm._v("*")]):_vm._e(),(itemSchema.label && !itemSchema.label.hidden)?[(!itemSchema.label.name)?_c('span',[_vm._v(_vm._s(itemSchema.label.text ? itemSchema.label.text : fieldName + ""))]):_c('span',{staticClass:"es-form-label-box"},[_c('es-base',{attrs:{"config":itemSchema.label,"info":itemSchema.__info}})],1),(itemSchema.label.help && !itemSchema.label.help.hidden)?_c('span',{staticClass:"es-form-label-help"},[_c('es-base',{attrs:{"config":itemSchema.label.help,"info":itemSchema.__info}})],1):_vm._e()]:_c('span',[_vm._v(_vm._s(fieldName + ""))])],2)]):_vm._e()]})],2),_c('ul',{staticClass:"es-tabs-body",style:({
padding: _vm.schema.layout.hasBorder
? _vm.schema.layout.padding
? _vm.schema.layout.padding
: Math.min(_vm.schema.ui.rowSpace, 10) + 'px'
: _vm.schema.layout.padding
? _vm.schema.layout.padding
: Math.min(_vm.schema.ui.rowSpace, 10) + 'px 0 0 0',
'border-width': _vm.schema.layout.hasBorder ? '1px' : '0px'
})},[_vm._l((_vm.schema.properties),function(itemSchema,fieldName){return [(itemSchema.__creatable)?_c('li',{directives:[{name:"show",rawName:"v-show",value:(fieldName === _vm.schema.__tabsIndex && !itemSchema.hidden),expression:"fieldName === schema.__tabsIndex && !itemSchema.hidden"}],key:fieldName,style:(itemSchema.__style)},[_vm._t(fieldName)],2):_vm._e()]})],2)],1)}
var tabsvue_type_template_id_43474d40_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/layout/tabs.vue?vue&type=template&id=43474d40&
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/tabs-nav.vue?vue&type=template&id=49e2eb46&
var tabs_navvue_type_template_id_49e2eb46_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{class:_vm.boxClass},[_c('div',{ref:"scrollBox",staticClass:"es-tabs-scroll-box"},[_c('div',{class:['es-tabs-scroll-wrap', _vm.showToggle ? 'es-has-toggle' : ''],style:({ padding: _vm.showToggle ? '0 ' + _vm.toggleZoneWidth + 'px' : '0' })},[_c('div',{class:['es-tabs-nav-wrap', _vm.hasAdd ? 'es-has-add' : '']},[_c('div',{staticClass:"es-tabs-nav-scroll"},[_c('ul',{ref:"scrollWrap",staticClass:"es-tabs-nav",style:({
left: _vm.navX + 'px'
})},[_vm._t("default")],2)]),(_vm.hasAdd)?_c('es-tabs-btn',{staticClass:"es-tabs-add es-btn",attrs:{"disabled":_vm.canAdd},on:{"click":_vm.addItemHandler}}):_vm._e()],1),_c('span',{staticClass:"es-tabs-prev-btn",on:{"click":_vm.clickPrevHandler}},[_c('span',{staticClass:"es-arrow"})]),_c('span',{staticClass:"es-tabs-next-btn",on:{"click":_vm.clickNextHandler}},[_c('span',{staticClass:"es-arrow"})])])]),_c('div',{staticClass:"help-box"},[_vm._t("help")],2)])}
var tabs_navvue_type_template_id_49e2eb46_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/components/tabs-nav.vue?vue&type=template&id=49e2eb46&
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.number.constructor.js
var es6_number_constructor = __webpack_require__("c5f6");
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.regexp.match.js
var es6_regexp_match = __webpack_require__("4917");
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/tabs-btn.vue?vue&type=template&id=2d16675f&
var tabs_btnvue_type_template_id_2d16675f_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('button',{class:[_vm.disabled ? 'disabled' : ''],on:{"click":_vm.clickHandler}},[_vm._t("default")],2)}
var tabs_btnvue_type_template_id_2d16675f_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/components/tabs-btn.vue?vue&type=template&id=2d16675f&
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/tabs-btn.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
/* harmony default export */ var tabs_btnvue_type_script_lang_js_ = ({
data: function data() {
return {};
},
props: {
disabled: {
type: Boolean,
required: false,
default: false
}
},
methods: {
clickHandler: function clickHandler(event) {
if (!this.disabled) {
this.$emit("click", event);
} else {// do nothing
}
}
}
});
// CONCATENATED MODULE: ./src/package/components/tabs-btn.vue?vue&type=script&lang=js&
/* harmony default export */ var components_tabs_btnvue_type_script_lang_js_ = (tabs_btnvue_type_script_lang_js_);
// CONCATENATED MODULE: ./src/package/components/tabs-btn.vue
/* normalize component */
var tabs_btn_component = Object(componentNormalizer["a" /* default */])(
components_tabs_btnvue_type_script_lang_js_,
tabs_btnvue_type_template_id_2d16675f_render,
tabs_btnvue_type_template_id_2d16675f_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var tabs_btn = (tabs_btn_component.exports);
// CONCATENATED MODULE: ./src/package/libs/tabs-observer.js
/**
* tabs-observer.js
*
* Copyright (c) 2019 chengaohe All rights reserved.
*
* 用于监听tabs的变化: 这样做的目标是使所有的tabs都来自同上个监听
*
*/
var tabsObserver = {
__INTERVAL: 50,
__listeners: [],
__observer: null,
__resizeWinHandler: null,
__throttleTimer: null,
/**
* 移除某个监听
* @param {*} callback
*/
add: function add(callback) {
if (utils["a" /* default */].isFunc(callback)) {
if (this.__listeners.length <= 0) {
this.__listeners.push(callback);
this.__start();
} else if (!this.__listeners.includes(callback)) {
this.__listeners.push(callback);
}
} else {
console.warn("tabsObserver.add(callback)中callback不是一个函数");
}
},
/**
* 移除某个监听
* @param {*} callback
*/
remove: function remove(callback) {
var index = this.__listeners.indexOf(callback);
if (index >= 0) {
this.__listeners.splice(index, 1);
if (this.__listeners.length <= 0) {
this.__stop();
}
}
},
/**
* 窗体改变时执行回调:当是resize时entries为undefined
*/
__observerHandler: function __observerHandler(entries) {
this.__listeners.forEach(function (cbItem) {
cbItem(entries);
});
},
/**
* 启动监听
*/
__start: function __start() {
var _this = this;
if (this.__observer) {
return true; // 已经存在,不用重构
} // console.log("start...");
this.__resizeWinHandler = function () {
if (!_this.__throttleTimer) _this.__throttleTimer = setTimeout(function () {
_this.__throttleTimer = null;
_this.__observerHandler();
}, _this.__INTERVAL);
};
window.addEventListener("resize", this.__resizeWinHandler, true);
var MutationObserver = window.MutationObserver || window.WebKitMutationObserver || window.MozMutationObserver;
this.__observer = new MutationObserver(function (entries) {
_this.__observerHandler(entries);
});
this.__observer.observe(document.body, {
childList: true,
subtree: true,
attributes: true,
characterData: true
});
},
/**
* 停止监听
*/
__stop: function __stop() {
// console.log("stop...");
if (this.__observer) {
this.__observer.disconnect();
this.__observer.takeRecords();
this.__observer = null;
}
if (this.__resizeWinHandler) {
window.removeEventListener("resize", this.__resizeWinHandler, true);
this.__resizeWinHandler = null;
}
if (this.__throttleTimer) {
clearTimeout(this.__throttleTimer);
this.__throttleTimer = null;
}
}
};
/* harmony default export */ var tabs_observer = (tabsObserver);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/tabs-nav.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
// import esTabsNavItem from "./tabs-nav-item";
/* harmony default export */ var tabs_navvue_type_script_lang_js_ = ({
// mixins: [itemMixin, arrayMixins],
components: {
// esObject,
// esTabsNavItem,
esTabsBtn: tabs_btn
},
props: {
hasAdd: {
type: Boolean,
required: false,
default: false
},
canAdd: {
type: Boolean,
required: false,
default: false
},
type: {
type: [String, Boolean],
required: false,
default: ""
}
},
computed: {
boxClass: function boxClass() {
var tClass = ["es-tabs-nav-box"];
switch (this.type) {
case "bg":
tClass.push("es-type-border-card");
break;
case "line":
tClass.push("es-type-line");
break;
case "card":
default:
tClass.push("es-type-card");
break;
}
return tClass;
}
},
data: function data() {
return {
// activeIndex: 0, // 只能设置为0
showToggle: false,
navX: 0,
toggleZoneWidth: 20,
// 当出现左右箭头时,左右区域的宽度
lockObserver: false,
oldRecord: {
// 记录下旧的宽高数据,避免重复触发回调函数
mainWidth: 0,
navWidth: 0
}
};
},
mounted: function mounted() {
var _this = this;
// 初始化页面数据
var navBox = this.$refs.scrollWrap;
var mainScrollBox = this.$refs.scrollBox; // 这个没有涉及到界面,所以不在data里
this.$data.navBox = navBox;
this.$data.navWrap = navBox.parentNode.parentNode;
this.$data.mainScrollBox = mainScrollBox;
this.$data.fromAdd = false; // window resize
this.$data.resizeCallback = function (mutationsList) {
var canDo = true;
if (_this.$data.lockObserver) {
canDo = false;
} else if (mutationsList && mutationsList.length == 1) {
var mutation = mutationsList[0]; // console.log("mutation.target == this.$data.navBox: ", mutation.target == this.$data.navBox);
if (mutation.target == _this.$data.navBox && mutation.type == "attributes" && mutation.attributeName == "style") {
canDo = false;
}
}
if (canDo) {
_this.resizeHandler(0);
}
}; // 启用监听
tabs_observer.add(this.$data.resizeCallback);
this.resizeHandler();
},
methods: {
addItemHandler: function addItemHandler() {
this.$data.fromAdd = true;
this.$emit("addItem");
},
/**
* offset = -1 来自于clickPrevHandler
* offset = 0 来自于MutationObserver或window resize
* offset = 1 来自于clickNextHandler
*/
resizeHandler: function resizeHandler() {
var _this2 = this;
var offset = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
var mainWidth = this.getAttrValue(this.$data.mainScrollBox, "width");
var navWidth = this.getAttrValue(this.$data.navBox, "width");
if (mainWidth <= 0 && navWidth <= 0) {
// console.log("tabs is not visible");
return false;
} // console.log(mainWidth, navWidth);
if (offset == 0 && mainWidth === this.oldRecord.mainWidth && navWidth === this.oldRecord.navWidth) {
// 来自MutationObserver or window.resize变化,但节点尺寸不变,不理会
this.$data.fromAdd = false;
return false; // 与之前的一样,不用做什么
}
var addBtnZoneWidth = this.getAttrValue(this.$data.navWrap, "padding-right");
var borderWidth = 0; // 0 是父容器左右的边框
var needTotalWidth = navWidth + borderWidth + addBtnZoneWidth;
var twoToggleWidth = 0;
var newNavX = false;
if (mainWidth < needTotalWidth) {
// 会出现切换按钮
this.$data.showToggle = true;
twoToggleWidth = this.$data.toggleZoneWidth * 2;
var minNavX;
minNavX = Math.floor(mainWidth - borderWidth - addBtnZoneWidth - navWidth - twoToggleWidth); // 为什么写这个Math.floor,因为有些机器是会有小数的,所以取小一点才能显示全部
if (this.$data.fromAdd) {
// 来自点击添加
if (newNavX > 0) {
minNavX = 0;
}
newNavX = minNavX;
} else {
// 来自删除或内容改动等
if (offset == 0) {
if (this.$data.navX < minNavX) {
// 原内容偏移了左边,靠右
newNavX = minNavX;
} else {// 保持内容不变
}
} else {
var offsetWidth = mainWidth - borderWidth - addBtnZoneWidth - twoToggleWidth; // 偏移量,也就是一个导航的宽度
if (offset < 0) {
newNavX = this.$data.navX + offsetWidth;
} else {
newNavX = this.$data.navX - offsetWidth;
}
if (newNavX > 0) {
newNavX = 0;
} else if (newNavX < minNavX) {
// 原内容偏移了左边,靠右
newNavX = minNavX;
} // this.$data.navX = newNavX;
}
}
} else {
if (this.$data.showToggle != false) {
this.$data.showToggle = false;
} // 菜单置0放在最左
if (this.$data.navX != 0) {
newNavX = 0;
}
}
this.oldRecord = {
mainWidth: mainWidth,
navWidth: navWidth
};
this.$data.fromAdd = false;
if (newNavX !== false) {
this.$data.lockObserver = true;
this.$nextTick(function () {
_this2.$data.lockObserver = false;
_this2.$data.navX = newNavX;
});
}
},
clickPrevHandler: function clickPrevHandler() {
if (this.$data.showToggle) {
this.resizeHandler(-1); // 向左偏移
}
},
clickNextHandler: function clickNextHandler() {
if (this.$data.showToggle) {
this.resizeHandler(1); // 向右偏移
}
},
getAttrValue: function getAttrValue(element, attrName) {
// console.log("element", element);
var valueStr = window.getComputedStyle(element).getPropertyValue(attrName ? attrName : "width"); // valueStr = "px";
// console.log("element", valueStr);
var reg = /^(\d*(\.\d+)?)\s*px$/i;
var txtArr = valueStr.match(reg);
var value = 0;
if (txtArr && txtArr[1]) {
value = Number(txtArr[1]);
} // console.log(valueStr, value);
return value;
}
},
beforeDestroy: function beforeDestroy() {
tabs_observer.remove(this.$data.resizeCallback);
this.$data.navBox = null;
this.$data.navWrap = null;
this.$data.mainScrollBox = null;
this.$data.fromAdd = false;
}
});
// CONCATENATED MODULE: ./src/package/components/tabs-nav.vue?vue&type=script&lang=js&
/* harmony default export */ var components_tabs_navvue_type_script_lang_js_ = (tabs_navvue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/components/tabs-nav.vue?vue&type=style&index=0&lang=scss&
var tabs_navvue_type_style_index_0_lang_scss_ = __webpack_require__("aef7");
// CONCATENATED MODULE: ./src/package/components/tabs-nav.vue
/* normalize component */
var tabs_nav_component = Object(componentNormalizer["a" /* default */])(
components_tabs_navvue_type_script_lang_js_,
tabs_navvue_type_template_id_49e2eb46_render,
tabs_navvue_type_template_id_49e2eb46_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var tabs_nav = (tabs_nav_component.exports);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/tabs-nav-item.vue?vue&type=template&id=5fb1ec9b&
var tabs_nav_itemvue_type_template_id_5fb1ec9b_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('li',{class:{
'is-active': _vm.isActive,
'has-close': _vm.hasDelete,
'has-pop': _vm.showPop
}},[_c('div',{class:{ 'es-tabs-nav-item-cnt': true, 'es-error': _vm.hasError },on:{"click":_vm.clickCntHandler}},[_c('div',[_vm._t("default")],2),(_vm.hasDelete)?_c('div',{staticClass:"es-tabs-close-box"},[_c('es-tabs-btn',{ref:"delBtn",staticClass:"es-tabs-close",attrs:{"disabled":_vm.index + 1 <= _vm.fixed || !_vm.canDelete},on:{"click":_vm.clickDeletBtn}}),(_vm.canPop)?_c('transition',{attrs:{"name":"es-fade","mode":"out-in","appear":""}},[_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.showPop),expression:"showPop"}],ref:"pop",staticClass:"es-form-pop-box",style:({
left: _vm.popPosition.left + 'px',
top: _vm.popPosition.top + 'px',
zIndex: _vm.popPosition.zindex + ''
}),on:{"click":function($event){$event.preventDefault();$event.stopPropagation();}}},[_c('div',{staticClass:"es-form-pop-content"},[_c('div',{staticClass:"content-box"},[(!_vm.delMsg.name)?_c('span',{staticClass:"content"},[_vm._v(_vm._s(_vm.delMsg.text))]):_c('es-base',{attrs:{"config":_vm.delMsg,"info":_vm.info}})],1),_c('div',{staticClass:"es-btn-row"},[_c('div',{staticClass:"es-btn-group"},[_c('es-btn',{staticClass:"es-btn",on:{"click":_vm.clickPopConfirm}},[_vm._v("\n "+_vm._s(_vm.delWarnBtns[0])+"\n ")]),_c('es-btn',{staticClass:"es-btn",on:{"click":_vm.closePop}},[_vm._v("\n "+_vm._s(_vm.delWarnBtns[1])+"\n ")])],1)])]),(_vm.popArrow.direction)?_c('div',{class:'es-pop-arrow-' + _vm.popArrow.direction,style:({ left: _vm.popArrow.left + 'px', top: _vm.popArrow.top + 'px' })}):_vm._e()])]):_vm._e()],1):_vm._e()]),(_vm.hasSort)?_c('es-tabs-btn',{staticClass:"es-tabs-left-btn",attrs:{"disabled":_vm.isFirst || _vm.index <= _vm.fixed},on:{"click":_vm.upItem}},[_c('span',{staticClass:"es-arrow"})]):_vm._e(),(_vm.hasSort)?_c('es-tabs-btn',{staticClass:"es-tabs-right-btn",attrs:{"disabled":_vm.isLast || _vm.index < _vm.fixed},on:{"click":_vm.downItem}},[_c('span',{staticClass:"es-arrow"})]):_vm._e()],1)}
var tabs_nav_itemvue_type_template_id_5fb1ec9b_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/components/tabs-nav-item.vue?vue&type=template&id=5fb1ec9b&
// CONCATENATED MODULE: ./src/package/mixins/array-edit-item-mixin.js
/* harmony default export */ var array_edit_item_mixin = ({
data: function data() {
return {};
},
props: {
canDelete: {
type: Boolean,
required: false,
default: true
},
hasSort: {
type: Boolean,
required: false,
default: false
},
isFirst: {
type: Boolean,
required: false,
default: false
},
isLast: {
type: Boolean,
required: false,
default: false
},
fixed: {
// 固定行(前几)
type: Number,
required: false,
default: 0
}
},
methods: {
upItem: function upItem() {
if (!this.isFirst) {
this.$emit("upItem", this.index);
}
},
downItem: function downItem() {
if (!this.isLast) {
this.$emit("downItem", this.index);
}
}
}
});
// EXTERNAL MODULE: ./src/package/libs/pop-utils.js
var pop_utils = __webpack_require__("dedd");
// CONCATENATED MODULE: ./src/package/mixins/array-del-pop-mixin.js
// import utils from "../libs/utils";
/* harmony default export */ var array_del_pop_mixin = ({
data: function data() {
return {
showPop: false,
popDom: null,
clickDocHandler: null,
scrollWinHandler: null,
placement: "bottom",
popPosition: {
left: 0,
top: 0,
zindex: 1
},
popArrow: {
direction: "",
left: 0,
top: 0
},
popInfo: {
popBorderRadius: 4,
viewSpace: 2,
// 距离判断边预留的空间
popArrowWH: 6,
// 箭头的宽度和高度
betweenSpace: 3 // pop与icon的空间
}
};
},
props: {
hasDelete: {
type: Boolean,
required: false,
default: false
},
hasDelWarn: {
type: Boolean,
required: false,
default: true
},
index: {
type: [Number, String],
required: false,
default: -1 // 设置为-1;低于索引值
},
delMsg: {
type: Object,
required: false,
default: function _default() {
return {};
}
},
delWarnBtns: {
type: Array,
required: false,
default: function _default() {
return [];
}
},
info: {
type: Object,
required: true,
default: function _default() {
return {};
}
}
},
computed: {
canPop: function canPop() {
return this.hasDelWarn;
}
},
created: function created() {
var _this = this;
if (this.canPop) {
this.$data.clickDocHandler = function (event) {
if (!_this.isFromDelBtn(event.target)) {
_this.$data.showPop = false;
_this.cancelDocListen();
} else {//...
}
};
this.$data.scrollWinHandler = function () {
_this.adjustPop();
};
}
},
methods: {
showPopHandler: function showPopHandler() {
var _this2 = this;
// 有警告
this.$data.showPop = !this.$data.showPop;
if (this.$data.showPop) {
this.addPopDom();
this.setDocListen();
this.$data.popPosition.zindex = pop_utils["a" /* default */].getMaxZIndex() + 1; // console.log("this.$data.popPosition.zindex = ", this.$data.popPosition.zindex);
this.$nextTick(function () {
_this2.adjustPop();
});
} else {
this.cancelDocListen();
}
},
clickDeletBtn: function clickDeletBtn() {
if (this.canPop && this.hasDelWarn && !this.delMsg.hidden && (this.delMsg.name || this.delMsg.text)) {
this.showPopHandler();
} else {
// 没有警告
this.$emit("delItem", this.index);
}
},
clickPopConfirm: function clickPopConfirm() {
this.$data.showPop = false;
this.$emit("delItem", this.index);
this.cancelDocListen();
},
closePop: function closePop() {
this.$data.showPop = false;
this.cancelDocListen();
},
setDocListen: function setDocListen() {
window.addEventListener("scroll", this.$data.scrollWinHandler, true);
document.addEventListener("click", this.$data.clickDocHandler);
},
cancelDocListen: function cancelDocListen() {
document.removeEventListener("click", this.$data.clickDocHandler);
window.removeEventListener("scroll", this.$data.scrollWinHandler, true);
},
isFromDelBtn: function isFromDelBtn(target) {
var myDelBtn = this.$refs["delBtn"];
if (!this.$refs["delBtn"]) {
return false;
}
myDelBtn = myDelBtn.$el ? myDelBtn.$el : myDelBtn;
while (target) {
if (target == myDelBtn) {
return true;
}
target = target.parentNode;
}
return false;
},
adjustPop: function adjustPop() {
var pop = this.$refs["pop"];
var icon = this.$refs["delBtn"].$el ? this.$refs["delBtn"].$el : this.$refs["delBtn"];
var popRect = pop.getBoundingClientRect();
var iconRect = icon.getBoundingClientRect();
var uiInfo = pop_utils["a" /* default */].getPopUiInfo(popRect, iconRect, this.$data.popInfo, this.$data.placement);
if (uiInfo) {
this.$data.popPosition = {
left: uiInfo.popLeft,
top: uiInfo.popTop
};
this.$data.popArrow = {
direction: uiInfo.arrowDirection,
left: uiInfo.arrowLeft,
top: uiInfo.arrowTop
};
} else {
this.closePop();
}
},
addPopDom: function addPopDom() {
if (!this.$data.popDom) {
this.$data.popDom = this.$refs.pop;
document.body.appendChild(this.$data.popDom);
}
},
removePopDom: function removePopDom() {
if (this.$data.popDom) {
document.body.removeChild(this.$data.popDom);
this.$data.popDom = null;
}
}
},
destroyed: function destroyed() {
if (this.$data.scrollWinHandler || this.$data.clickDocHandler) {
this.$data.showPop = false;
this.cancelDocListen();
this.$data.clickDocHandler = null;
this.$data.scrollWinHandler = null;
}
this.removePopDom();
}
});
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/btn.vue?vue&type=template&id=3a7afff6&
var btnvue_type_template_id_3a7afff6_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('button',{class:['es-btn', _vm.disabled ? 'disabled' : ''],on:{"click":_vm.clickHandler}},[_vm._t("default")],2)}
var btnvue_type_template_id_3a7afff6_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/components/btn.vue?vue&type=template&id=3a7afff6&
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/btn.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
/* harmony default export */ var btnvue_type_script_lang_js_ = ({
data: function data() {
return {};
},
props: {
disabled: {
type: Boolean,
required: false,
default: false
}
},
methods: {
clickHandler: function clickHandler($event) {
if (!this.disabled) {
this.$emit("click", $event);
}
}
}
});
// CONCATENATED MODULE: ./src/package/components/btn.vue?vue&type=script&lang=js&
/* harmony default export */ var components_btnvue_type_script_lang_js_ = (btnvue_type_script_lang_js_);
// CONCATENATED MODULE: ./src/package/components/btn.vue
/* normalize component */
var btn_component = Object(componentNormalizer["a" /* default */])(
components_btnvue_type_script_lang_js_,
btnvue_type_template_id_3a7afff6_render,
btnvue_type_template_id_3a7afff6_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var btn = (btn_component.exports);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/tabs-nav-item.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
// import utils from "../libs/utils";
/* harmony default export */ var tabs_nav_itemvue_type_script_lang_js_ = ({
mixins: [array_edit_item_mixin, array_del_pop_mixin],
components: {
esBtn: btn,
esTabsBtn: tabs_btn,
esBase: base
},
data: function data() {
return {
placement: "top",
popInfo: {
popBorderRadius: 4,
viewSpace: 2,
// 距离判断边预留的空间
popArrowWH: 6,
// 箭头的宽度和高度
betweenSpace: 6 // pop与icon的空间
}
};
},
props: {
// tabsName: {
// type: String,
// required: true,
// default: "???"
// },
isActive: {
type: Boolean,
required: true,
default: false
},
hasError: {
type: Boolean,
required: false,
default: false
},
info: {
type: Object,
required: true // default: false
}
},
methods: {
clickCntHandler: function clickCntHandler(event) {
if (!this.isActive && !this.isFromDelBtn(event.target)) {
this.$emit("clickActive", this.index);
} else {//不用理会,这个点击有其它作用
}
}
},
mounted: function mounted() {// if (utils.isStr(this.index)) {
// // 来自布局tabs
// this.$emit("reactive", this.index);
// }
},
beforeDestroy: function beforeDestroy() {// console.log("emit reactive... 1");
// if (this.isActive) {
// // console.log("emit reactive... 2");
// this.$emit("reactive");
// }
}
});
// CONCATENATED MODULE: ./src/package/components/tabs-nav-item.vue?vue&type=script&lang=js&
/* harmony default export */ var components_tabs_nav_itemvue_type_script_lang_js_ = (tabs_nav_itemvue_type_script_lang_js_);
// CONCATENATED MODULE: ./src/package/components/tabs-nav-item.vue
/* normalize component */
var tabs_nav_item_component = Object(componentNormalizer["a" /* default */])(
components_tabs_nav_itemvue_type_script_lang_js_,
tabs_nav_itemvue_type_template_id_5fb1ec9b_render,
tabs_nav_itemvue_type_template_id_5fb1ec9b_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var tabs_nav_item = (tabs_nav_item_component.exports);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/tabs.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
/* harmony default export */ var tabsvue_type_script_lang_js_ = ({
mixins: [item_mixin],
components: {
esTabsNav: tabs_nav,
esTabsNavItem: tabs_nav_item,
esBase: base
},
data: function data() {
return {};
},
methods: {
clickActiveHandler: function clickActiveHandler(index) {
var form = this.__getForm();
form._toggleUi("tabs", {
key: this.schema.__info.pathKey,
index: index
});
},
__getForm: function __getForm() {
var formItem = this.$parent;
while (formItem) {
var type = formItem._getType ? formItem._getType() : "";
if (type == constant["a" /* default */].UI_FORM) {
// formItem._syncFormUi(checkSchema, eventNames, targetValue, eventData); // 最外层的表单层同步所有的ui及数位
return formItem; // 到达表单层
} else if (type == constant["a" /* default */].UI_ARRAY) {// checkSchema.push(formItem._getSchema());
} else {// ... 往上派
}
formItem = formItem.$parent;
}
}
},
created: function created() {},
mounted: function mounted() {},
beforeDestroy: function beforeDestroy() {}
});
// CONCATENATED MODULE: ./src/package/layout/tabs.vue?vue&type=script&lang=js&
/* harmony default export */ var layout_tabsvue_type_script_lang_js_ = (tabsvue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/layout/tabs.vue?vue&type=style&index=0&lang=scss&
var tabsvue_type_style_index_0_lang_scss_ = __webpack_require__("8744");
// CONCATENATED MODULE: ./src/package/layout/tabs.vue
/* normalize component */
var tabs_component = Object(componentNormalizer["a" /* default */])(
layout_tabsvue_type_script_lang_js_,
tabsvue_type_template_id_43474d40_render,
tabsvue_type_template_id_43474d40_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var tabs = (tabs_component.exports);
// EXTERNAL MODULE: ./src/package/libs/form-utils.js
var form_utils = __webpack_require__("3be1");
// CONCATENATED MODULE: ./src/package/mixins/array-mixin.js
// import utils from "../libs/utils";
/* 这个几个不可随便更改,因为对外,用户有可能会使用 */
var ARR_OP_TYPE_DEL_ONE = "delete"; // 单个delete
var ARR_OP_TYPE_DEL_ALL = "deleteAll"; // 所有delete
var ARR_OP_TYPE_ADD = "add"; // add
var ARR_OP_TYPE_COPY = "copy"; // copy
var ARR_OP_TYPE_MOVE_UP = "up"; // up
var ARR_OP_TYPE_MOVE_DOWN = "down"; // down
/* harmony default export */ var array_mixin = ({
created: function created() {},
data: function data() {
return {};
},
methods: {
addItem: function addItem() {
this.__addItem();
},
copyItem: function copyItem(index) {
this.__addItem(index);
},
delItem: function delItem(index) {
var _this = this;
if (index >= 0 && index < this.schema.__propSchemaList.length) {
var oldValues = form_utils["a" /* default */].getValue(this.schema);
var eventData = {
type: ARR_OP_TYPE_DEL_ONE,
index: index,
data: utils["a" /* default */].deepCopy(oldValues[index])
};
if (this.schema.array.before) {
var form = this.__getForm();
var data = this.__createHookData(oldValues, eventData, form);
utils["a" /* default */].execCbHook(this.schema.array.before, form, data, function (result) {
if (result !== false) {
_this.__doDelItem(index, eventData);
} else {//返回false,说明什么都不用做
}
});
data = null;
form = null;
} else {
this.__doDelItem(index, eventData);
}
}
},
__doDelItem: function __doDelItem(index, eventData) {
if (index >= 0 && index < this.schema.__propSchemaList.length) {
this.schema.__propSchemaList.splice(index, 1);
form_utils["a" /* default */].resetIndexArr(this.schema, this.schema.__info.idxChain, this.schema.__info.pathKey);
var newValue = form_utils["a" /* default */].getValue(this.schema);
this.$emit("input", newValue, eventData);
}
},
delAllItems: function delAllItems() {
var _this2 = this;
if (this.schema.__propSchemaList.length > 0) {
var oldValues = form_utils["a" /* default */].getValue(this.schema);
var eventData = {
type: ARR_OP_TYPE_DEL_ALL,
index: -1,
data: oldValues
};
if (this.schema.array.before) {
var form = this.__getForm();
var data = this.__createHookData(oldValues, eventData, form);
utils["a" /* default */].execCbHook(this.schema.array.before, form, data, function (result) {
if (result !== false) {
_this2.__doDelAllItems(eventData);
} else {//返回false,说明什么都不用做
}
});
data = null;
form = null;
} else {
this.__doDelAllItems(eventData);
}
}
},
__doDelAllItems: function __doDelAllItems(eventData) {
if (this.schema.__propSchemaList.length > 0) {
this.schema.__propSchemaList = [];
var newValue = form_utils["a" /* default */].getValue(this.schema);
this.$emit("input", newValue, eventData);
}
},
upItem: function upItem(index) {
var _this3 = this;
if (index > 0 && index < this.schema.__propSchemaList.length) {
var oldValues = form_utils["a" /* default */].getValue(this.schema);
var eventData = {
type: ARR_OP_TYPE_MOVE_UP,
index: index
};
if (this.schema.array.before) {
var form = this.__getForm();
var data = this.__createHookData(oldValues, eventData, form);
utils["a" /* default */].execCbHook(this.schema.array.before, form, data, function (result) {
if (result !== false) {
_this3.__doUpItem(index, eventData);
} else {//返回false,说明什么都不用做
}
});
data = null;
form = null;
} else {
this.__doUpItem(index, eventData);
}
}
},
__doUpItem: function __doUpItem(index, eventData) {
if (index > 0 && index < this.schema.__propSchemaList.length) {
this.schema.__propSchemaList.splice(index - 1, 0, this.schema.__propSchemaList.splice(index, 1)[0]);
form_utils["a" /* default */].resetIndexArr(this.schema, this.schema.__info.idxChain, this.schema.__info.pathKey);
var newValue = form_utils["a" /* default */].getValue(this.schema);
this.$emit("input", newValue, eventData);
}
},
downItem: function downItem(index) {
var _this4 = this;
if (index >= 0 && index < this.schema.__propSchemaList.length - 1) {
var oldValues = form_utils["a" /* default */].getValue(this.schema);
var eventData = {
type: ARR_OP_TYPE_MOVE_DOWN,
index: index
};
if (this.schema.array.before) {
var form = this.__getForm();
var data = this.__createHookData(oldValues, eventData, form);
utils["a" /* default */].execCbHook(this.schema.array.before, form, data, function (result) {
if (result !== false) {
_this4.__doDownItem(index, eventData);
} else {//返回false,说明什么都不用做
}
});
data = null;
form = null;
} else {
this.__doDownItem(index, eventData);
}
}
},
__doDownItem: function __doDownItem(index, eventData) {
if (index >= 0 && index < this.schema.__propSchemaList.length - 1) {
this.schema.__propSchemaList.splice(index + 1, 0, this.schema.__propSchemaList.splice(index, 1)[0]);
form_utils["a" /* default */].resetIndexArr(this.schema, this.schema.__info.idxChain, this.schema.__info.pathKey);
var newValue = form_utils["a" /* default */].getValue(this.schema);
this.$emit("input", newValue, eventData);
}
},
__addItem: function __addItem(index) {
var _this5 = this;
var oldValues = form_utils["a" /* default */].getValue(this.schema);
var isIndex = utils["a" /* default */].isNum(index);
var curIndex = isIndex ? index : this.schema.__propSchemaList.length; // __propSchemaList现在还是旧的
var eventData = {
type: isIndex ? ARR_OP_TYPE_COPY : ARR_OP_TYPE_ADD,
index: curIndex // 比change少了个data,因为刚开始有可能不知初始值是什么,所以统一不做
};
if (this.schema.array.before) {
var form = this.__getForm();
var data = this.__createHookData(oldValues, eventData, form);
utils["a" /* default */].execCbHook(this.schema.array.before, form, data, function (result) {
if (result !== false) {
_this5.__doAddItem(index);
} else {//返回false,说明什么都不用做
}
});
data = null;
form = null;
} else {
this.__doAddItem(index);
}
},
__doAddItem: function __doAddItem(index) {
var insertInfo = false,
oldValues,
position;
oldValues = form_utils["a" /* default */].getValue(this.schema);
var isIndex = utils["a" /* default */].isNum(index);
position = isIndex ? index + 1 : this.schema.__propSchemaList.length;
var insertValue = this.schema.array.insertValue;
if (!utils["a" /* default */].isUndef(insertValue)) {
if (utils["a" /* default */].isFunc(insertValue)) {
// 是一个函数,过滤
var thisFrom = this.__getForm();
var rawDefaultValue = utils["a" /* default */].deepCopy(oldValues[index]);
var options = {
oldValues: oldValues,
position: position,
type: isIndex ? ARR_OP_TYPE_COPY : ARR_OP_TYPE_ADD,
instance: thisFrom
};
var newDefaultValue = insertValue.call(thisFrom, options);
options = null;
if (utils["a" /* default */].isUndef(newDefaultValue)) {
if (isIndex) {
insertInfo = {
value: rawDefaultValue,
// 没有默认值,那就取拷贝的那行
position: position
};
} else {
insertInfo = false; // 没有返回值,那就不设置
}
} else {
insertInfo = {
value: newDefaultValue,
position: position
};
}
} else {
insertInfo = {
value: utils["a" /* default */].deepCopy(insertValue),
position: position
}; // 固定的值
}
} else if (isIndex) {
insertInfo = {
value: utils["a" /* default */].deepCopy(oldValues[index]),
position: position
}; // 固定的值
}
form_utils["a" /* default */].addArrayItem(this.schema, insertInfo);
form_utils["a" /* default */].resetIndexArr(this.schema, this.schema.__info.idxChain, this.schema.__info.pathKey);
var newValue = form_utils["a" /* default */].getValue(this.schema);
var curIndex = isIndex ? index : this.schema.__propSchemaList.length - 1;
var eventData = {
type: isIndex ? ARR_OP_TYPE_COPY : ARR_OP_TYPE_ADD,
index: curIndex,
data: utils["a" /* default */].deepCopy(newValue[curIndex]) // 比before多了这个
};
this.$emit("input", newValue, eventData); //同步更新的
},
__createHookData: function __createHookData(value, eventData, formInstance) {
return {
value: value,
event: eventData,
args: [eventData],
pathKey: this.schema.__info.pathKey,
index: this.schema.__info.index,
idxChain: this.schema.__info.idxChain,
target: null,
instance: formInstance
};
},
__getForm: function __getForm() {
var formItem = this.$parent;
while (formItem) {
var type = formItem._getType ? formItem._getType() : "";
if (type == constant["a" /* default */].UI_FORM) {
// formItem._syncFormUi(checkSchema, eventNames, targetValue, eventData); // 最外层的表单层同步所有的ui及数位
return formItem; // 到达表单层
} else if (type == constant["a" /* default */].UI_ARRAY) {// checkSchema.push(formItem._getSchema());
} else {// ... 往上派
}
formItem = formItem.$parent;
}
}
}
});
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/edit-btns.vue?vue&type=template&id=6b003e39&
var edit_btnsvue_type_template_id_6b003e39_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"es-form-edit-btns"},[_c('div',{staticClass:"es-btn-group"},[(_vm.hasDelete)?_c('es-btn',{ref:"delBtn",attrs:{"disabled":_vm.index + 1 <= _vm.fixed || !_vm.canDelete},on:{"click":_vm.clickDeletBtn}},[_c('div',{staticClass:"es-circle-delete"})]):_vm._e(),(_vm.hasAdd)?_c('es-btn',{attrs:{"disabled":!_vm.canAdd},on:{"click":_vm.copyItem}},[_c('div',{staticClass:"es-normal-plus"})]):_vm._e(),(_vm.hasSort)?_c('es-btn',{attrs:{"disabled":_vm.isFirst || _vm.index <= _vm.fixed},on:{"click":_vm.upItem}},[_c('div',{staticClass:"es-triangle-border-up"})]):_vm._e(),(_vm.hasSort)?_c('es-btn',{attrs:{"disabled":_vm.isLast || _vm.index < _vm.fixed},on:{"click":_vm.downItem}},[_c('div',{staticClass:"es-triangle-border-down"})]):_vm._e()],1),(_vm.canPop)?_c('transition',{attrs:{"name":"es-fade","mode":"out-in","appear":""}},[_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.showPop),expression:"showPop"}],ref:"pop",staticClass:"es-form-pop-box",style:({
left: _vm.popPosition.left + 'px',
top: _vm.popPosition.top + 'px',
zIndex: _vm.popPosition.zindex + ''
}),on:{"click":function($event){$event.preventDefault();$event.stopPropagation();}}},[_c('div',{staticClass:"es-form-pop-content"},[_c('div',{staticClass:"content-box"},[(!_vm.delMsg.name)?_c('span',{staticClass:"content"},[_vm._v(_vm._s(_vm.delMsg.text))]):_c('es-base',{attrs:{"config":_vm.delMsg,"info":_vm.info}})],1),_c('div',{staticClass:"es-btn-row"},[_c('div',{staticClass:"es-btn-group"},[_c('es-btn',{staticClass:"es-btn",on:{"click":_vm.clickPopConfirm}},[_vm._v("\n "+_vm._s(_vm.delWarnBtns[0])+"\n ")]),_c('es-btn',{staticClass:"es-btn",on:{"click":_vm.closePop}},[_vm._v("\n "+_vm._s(_vm.delWarnBtns[1])+"\n ")])],1)])]),(_vm.popArrow.direction)?_c('div',{class:'es-pop-arrow-' + _vm.popArrow.direction,style:({ left: _vm.popArrow.left + 'px', top: _vm.popArrow.top + 'px' })}):_vm._e()])]):_vm._e()],1)}
var edit_btnsvue_type_template_id_6b003e39_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/components/edit-btns.vue?vue&type=template&id=6b003e39&
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/edit-btns.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
/* harmony default export */ var edit_btnsvue_type_script_lang_js_ = ({
mixins: [array_del_pop_mixin],
components: {
esBtn: btn,
esBase: base
},
data: function data() {
return {};
},
props: {
canDelete: {
type: Boolean,
required: false,
default: true
},
hasSort: {
type: Boolean,
required: false,
default: true
},
isFirst: {
type: Boolean,
required: false,
default: false
},
isLast: {
type: Boolean,
required: false,
default: false
},
fixed: {
// 固定行(前几)
type: Number,
required: true,
default: 0
},
index: {
type: Number,
required: true,
default: 0
},
canAdd: {
type: Boolean,
required: false,
default: true
},
hasAdd: {
type: Boolean,
required: false,
default: false
}
},
methods: {
upItem: function upItem() {
if (!this.isFirst) {
this.$emit("upItem", this.index);
}
},
copyItem: function copyItem() {
this.$emit("copyItem", this.index);
},
downItem: function downItem() {
if (!this.isLast) {
this.$emit("downItem", this.index);
}
}
}
});
// CONCATENATED MODULE: ./src/package/components/edit-btns.vue?vue&type=script&lang=js&
/* harmony default export */ var components_edit_btnsvue_type_script_lang_js_ = (edit_btnsvue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/components/edit-btns.vue?vue&type=style&index=0&lang=scss&
var edit_btnsvue_type_style_index_0_lang_scss_ = __webpack_require__("5b0d");
// CONCATENATED MODULE: ./src/package/components/edit-btns.vue
/* normalize component */
var edit_btns_component = Object(componentNormalizer["a" /* default */])(
components_edit_btnsvue_type_script_lang_js_,
edit_btnsvue_type_template_id_6b003e39_render,
edit_btnsvue_type_template_id_6b003e39_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var edit_btns = (edit_btns_component.exports);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/edit-abbr-btns.vue?vue&type=template&id=de802532&
var edit_abbr_btnsvue_type_template_id_de802532_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"es-form-edit-btns"},[_c('div',{staticClass:"btn-list-box"},[_c('span',{ref:"delBtn",class:'es-addr-btns-box' + (_vm.size ? ' ' + _vm.size : ''),on:{"click":_vm.clickEditHandler}})]),_c('transition',{attrs:{"name":"es-fade","mode":"out-in","appear":""}},[_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.showPop),expression:"showPop"}],ref:"pop",staticClass:"es-form-pop-box",style:({
left: _vm.popPosition.left + 'px',
top: _vm.popPosition.top + 'px',
zIndex: _vm.popPosition.zindex + ''
}),on:{"click":function($event){$event.preventDefault();$event.stopPropagation();}}},[(_vm.showBtn)?_c('div',{staticClass:"es-form-pop-content es-thin"},[_c('div',{staticClass:"es-btn-group"},[(_vm.hasDelete)?_c('es-btn',{attrs:{"disabled":_vm.index + 1 <= _vm.fixed || !_vm.canDelete},on:{"click":_vm.clickDeletBtn}},[_c('div',{staticClass:"es-circle-delete"})]):_vm._e(),(_vm.hasAdd)?_c('es-btn',{attrs:{"disabled":!_vm.canAdd},on:{"click":_vm.copyItem}},[_c('div',{staticClass:"es-normal-plus"})]):_vm._e(),(_vm.hasSort)?_c('es-btn',{attrs:{"disabled":_vm.isFirst || _vm.index <= _vm.fixed},on:{"click":_vm.upItem}},[(_vm.isHArrow)?_c('div',{staticClass:"es-triangle-border-up es-left"}):_c('div',{staticClass:"es-triangle-border-up"})]):_vm._e(),(_vm.hasSort)?_c('es-btn',{attrs:{"disabled":_vm.isLast || _vm.index < _vm.fixed},on:{"click":_vm.downItem}},[(_vm.isHArrow)?_c('div',{staticClass:"es-triangle-border-down es-right"}):_c('div',{staticClass:"es-triangle-border-down"})]):_vm._e()],1)]):_c('div',{staticClass:"es-form-pop-content"},[_c('div',{staticClass:"content-box"},[(!_vm.delMsg.name)?_c('span',{staticClass:"content"},[_vm._v(_vm._s(_vm.delMsg.text))]):_c('es-base',{attrs:{"config":_vm.delMsg,"info":_vm.info}})],1),_c('div',{staticClass:"es-btn-row"},[_c('div',{staticClass:"es-btn-group"},[_c('es-btn',{staticClass:"es-btn",on:{"click":_vm.clickPopConfirm}},[_vm._v("\n "+_vm._s(_vm.delWarnBtns[0])+"\n ")]),_c('es-btn',{staticClass:"es-btn",on:{"click":_vm.showEditBtn}},[_vm._v("\n "+_vm._s(_vm.delWarnBtns[1])+"\n ")])],1)])]),(_vm.popArrow.direction)?_c('div',{class:'es-pop-arrow-' + _vm.popArrow.direction,style:({ left: _vm.popArrow.left + 'px', top: _vm.popArrow.top + 'px' })}):_vm._e()])])],1)}
var edit_abbr_btnsvue_type_template_id_de802532_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/components/edit-abbr-btns.vue?vue&type=template&id=de802532&
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/edit-abbr-btns.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
/* harmony default export */ var edit_abbr_btnsvue_type_script_lang_js_ = ({
mixins: [array_del_pop_mixin],
components: {
esBtn: btn,
esBase: base
},
data: function data() {
return {
showBtn: false,
placement: "top"
};
},
props: {
canDelete: {
type: Boolean,
required: false,
default: true
},
hasSort: {
type: Boolean,
required: false,
default: true
},
isFirst: {
type: Boolean,
required: false,
default: false
},
isLast: {
type: Boolean,
required: false,
default: false
},
fixed: {
// 固定行(前几)
type: Number,
required: true,
default: 0
},
index: {
type: Number,
required: true,
default: 0
},
canAdd: {
type: Boolean,
required: false,
default: true
},
hasAdd: {
type: Boolean,
required: false,
default: false
},
size: {
type: String,
required: false,
default: ""
},
isHArrow: {
type: Boolean,
required: false,
default: false
}
},
computed: {
canPop: function canPop() {
return true;
}
},
methods: {
upItem: function upItem() {
if (!this.isFirst) {
this.$data.showPop = false;
this.$emit("upItem", this.index);
this.cancelDocListen();
}
},
copyItem: function copyItem() {
this.$data.showPop = false;
this.$emit("copyItem", this.index);
this.cancelDocListen();
},
downItem: function downItem() {
if (!this.isLast) {
this.$data.showPop = false;
this.$emit("downItem", this.index);
this.cancelDocListen();
}
},
/* 重载 */
clickDeletBtn: function clickDeletBtn() {
var _this = this;
if (this.hasDelWarn && !this.delMsg.hidden && (this.delMsg.name || this.delMsg.text)) {
// this.showPopHandler();
this.$data.showBtn = false;
this.$nextTick(function () {
_this.adjustPop();
});
} else {
// 没有警告
// this.$emit("delItem", this.index);
this.$data.showPop = false;
this.$emit("delItem", this.index);
this.cancelDocListen();
}
},
showEditBtn: function showEditBtn() {
var _this2 = this;
this.$data.showBtn = true;
this.$nextTick(function () {
_this2.adjustPop();
});
},
clickEditHandler: function clickEditHandler() {
this.showPopHandler();
this.$data.showBtn = true;
}
}
});
// CONCATENATED MODULE: ./src/package/components/edit-abbr-btns.vue?vue&type=script&lang=js&
/* harmony default export */ var components_edit_abbr_btnsvue_type_script_lang_js_ = (edit_abbr_btnsvue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/components/edit-abbr-btns.vue?vue&type=style&index=0&lang=scss&
var edit_abbr_btnsvue_type_style_index_0_lang_scss_ = __webpack_require__("fa00");
// CONCATENATED MODULE: ./src/package/components/edit-abbr-btns.vue
/* normalize component */
var edit_abbr_btns_component = Object(componentNormalizer["a" /* default */])(
components_edit_abbr_btnsvue_type_script_lang_js_,
edit_abbr_btnsvue_type_template_id_de802532_render,
edit_abbr_btnsvue_type_template_id_de802532_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var edit_abbr_btns = (edit_abbr_btns_component.exports);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/edit-bottom-btns.vue?vue&type=template&id=399c89c0&
var edit_bottom_btnsvue_type_template_id_399c89c0_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"es-form-bottom-btns"},[_c('div',{staticClass:"es-btn-group"},[(_vm.hasDelete)?_c('es-btn',{ref:"delBtn",attrs:{"disabled":!_vm.canDelete},on:{"click":_vm.clickDeletBtn}},[_c('div',{staticClass:"es-circle-delete"})]):_vm._e(),(_vm.hasAdd)?_c('es-btn',{attrs:{"disabled":!_vm.canAdd},on:{"click":_vm.addItem}},[_c('div',{staticClass:"es-normal-plus"})]):_vm._e()],1),(_vm.canPop)?_c('transition',{attrs:{"name":"es-fade","mode":"out-in","appear":""}},[_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.showPop),expression:"showPop"}],ref:"pop",staticClass:"es-form-pop-box",style:({
left: _vm.popPosition.left + 'px',
top: _vm.popPosition.top + 'px',
zIndex: _vm.popPosition.zindex + ''
}),on:{"click":function($event){$event.preventDefault();$event.stopPropagation();}}},[_c('div',{staticClass:"es-form-pop-content"},[_c('div',{staticClass:"content-box"},[(!_vm.delMsg.name)?_c('span',{staticClass:"content"},[_vm._v(_vm._s(_vm.delMsg.text))]):_c('es-base',{attrs:{"config":_vm.delMsg,"info":_vm.info}})],1),_c('div',{staticClass:"es-btn-row"},[_c('div',{staticClass:"es-btn-group"},[_c('es-btn',{staticClass:"es-btn",on:{"click":_vm.clickPopConfirm}},[_vm._v("\n "+_vm._s(_vm.delWarnBtns[0])+"\n ")]),_c('es-btn',{staticClass:"es-btn",on:{"click":_vm.closePop}},[_vm._v("\n "+_vm._s(_vm.delWarnBtns[1])+"\n ")])],1)])]),(_vm.popArrow.direction)?_c('div',{class:'es-pop-arrow-' + _vm.popArrow.direction,style:({ left: _vm.popArrow.left + 'px', top: _vm.popArrow.top + 'px' })}):_vm._e()])]):_vm._e()],1)}
var edit_bottom_btnsvue_type_template_id_399c89c0_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/components/edit-bottom-btns.vue?vue&type=template&id=399c89c0&
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/edit-bottom-btns.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
/* harmony default export */ var edit_bottom_btnsvue_type_script_lang_js_ = ({
mixins: [array_del_pop_mixin],
data: function data() {
return {};
},
components: {
esBtn: btn,
esBase: base
},
props: {
canDelete: {
type: Boolean,
required: false,
default: true
},
canAdd: {
type: Boolean,
required: false,
default: true
},
hasDelete: {
type: Boolean,
required: false,
default: true
},
hasAdd: {
type: Boolean,
required: false,
default: true
}
},
created: function created() {
this.$data.placement = "top"; // 设置pop在上面优先
},
methods: {
addItem: function addItem() {
if (this.canAdd) {
this.$emit("addItem");
}
}
}
});
// CONCATENATED MODULE: ./src/package/components/edit-bottom-btns.vue?vue&type=script&lang=js&
/* harmony default export */ var components_edit_bottom_btnsvue_type_script_lang_js_ = (edit_bottom_btnsvue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/components/edit-bottom-btns.vue?vue&type=style&index=0&lang=scss&
var edit_bottom_btnsvue_type_style_index_0_lang_scss_ = __webpack_require__("18d05");
// CONCATENATED MODULE: ./src/package/components/edit-bottom-btns.vue
/* normalize component */
var edit_bottom_btns_component = Object(componentNormalizer["a" /* default */])(
components_edit_bottom_btnsvue_type_script_lang_js_,
edit_bottom_btnsvue_type_template_id_399c89c0_render,
edit_bottom_btnsvue_type_template_id_399c89c0_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var edit_bottom_btns = (edit_bottom_btns_component.exports);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/array-row.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
/* harmony default export */ var array_rowvue_type_script_lang_js_ = ({
mixins: [item_mixin, array_mixin],
components: {
esObject: object,
editBtns: edit_btns,
editAbbrBtns: edit_abbr_btns,
editBottomBtns: edit_bottom_btns,
tabs: tabs,
esBase: base
},
methods: {}
});
// CONCATENATED MODULE: ./src/package/layout/array-row.vue?vue&type=script&lang=js&
/* harmony default export */ var layout_array_rowvue_type_script_lang_js_ = (array_rowvue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/layout/array-row.vue?vue&type=style&index=0&lang=scss&
var array_rowvue_type_style_index_0_lang_scss_ = __webpack_require__("2d97");
// CONCATENATED MODULE: ./src/package/layout/array-row.vue
/* normalize component */
var array_row_component = Object(componentNormalizer["a" /* default */])(
layout_array_rowvue_type_script_lang_js_,
array_rowvue_type_template_id_74bbd219_render,
array_rowvue_type_template_id_74bbd219_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var array_row = (array_row_component.exports);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/array-legend.vue?vue&type=template&id=7e48e6b3&
var array_legendvue_type_template_id_7e48e6b3_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"es-form-array-legend"},[_c('div',{staticClass:"es-form-array-wrap"},[_c('ul',{staticClass:"es-order-list-box"},_vm._l((_vm.schema.__propSchemaList),function(itemSchema,index){return _c('li',{key:index,staticClass:"list-item",style:({
marginTop: (index > 0 ? _vm.schema.array.rowSpace : 0) + 'px'
})},[(_vm.schema.array.hasOrder !== false)?_c('div',{staticClass:"es-order-box",style:({
height: _vm.schema.properties
? _vm.schema.ui.rowHeight + 'px'
: _vm.schema.rowHeight + 'px'
})},[_vm._v("\n "+_vm._s(index + 1)+".\n ")]):_vm._e(),_c('div',{staticClass:"es-array-fieldset-box"},[_c('div',{staticClass:"es-array-fieldset"},[_c('div',{staticClass:"es-legend"},[(
itemSchema.rules &&
itemSchema.rules.required &&
itemSchema.rules.showRequired
)?_c('span',[_c('span',{staticClass:"es-required"},[_vm._v("*")])]):_vm._e(),(!itemSchema.subLabel.name || itemSchema.subLabel.hidden)?_c('span',[_vm._v(_vm._s(itemSchema.subLabel.text && !itemSchema.subLabel.hidden
? itemSchema.subLabel.text
: index + 1 + ""))]):_c('span',{staticClass:"es-form-label-box"},[_c('es-base',{attrs:{"config":itemSchema.subLabel,"info":itemSchema.__info}})],1)]),(itemSchema.properties)?[(itemSchema.layout && itemSchema.layout.name === 'tabs')?_c('tabs',{tag:"component",attrs:{"schema":itemSchema}},[_vm._l((itemSchema.properties),function(fieldSchema,fieldName){return _c('template',{slot:fieldName},[_vm._t(fieldName,null,{"refName":fieldName + '_' + index,"schema":fieldSchema})],2)})],2):_c('es-object',{attrs:{"schema":itemSchema}},[_vm._l((itemSchema.properties),function(fieldSchema,fieldName){return _c('template',{slot:fieldName},[_vm._t(fieldName,null,{"refName":fieldName + '_' + index,"schema":fieldSchema})],2)})],2),(
_vm.schema.array.hasDelete ||
_vm.schema.array.hasSort ||
_vm.schema.array.hasCopy
)?_c('div',{staticClass:"es-btn-panel"},[_c('div',{staticClass:"es-btn-box",style:({
height: _vm.schema.properties
? _vm.schema.ui.rowHeight + 'px'
: _vm.schema.rowHeight + 'px'
})},[(_vm.schema.array.btnType !== 'icon')?_c('edit-btns',{attrs:{"has-delete":_vm.schema.array.hasDelete,"has-sort":_vm.schema.array.hasSort,"can-delete":_vm.schema.__propSchemaList.length > _vm.schema.array.min,"fixed":_vm.schema.array.fixed,"is-first":index == 0,"is-last":index == _vm.schema.__propSchemaList.length - 1,"index":index,"has-del-warn":_vm.schema.array.hasDelWarn,"can-add":_vm.schema.array.max <= 0 ||
_vm.schema.__propSchemaList.length < _vm.schema.array.max,"has-add":_vm.schema.array.hasCopy,"del-msg":itemSchema.delMsg,"del-warn-btns":itemSchema.delWarnBtns,"info":itemSchema.__info},on:{"copyItem":_vm.copyItem,"delItem":_vm.delItem,"upItem":_vm.upItem,"downItem":_vm.downItem}}):_c('edit-abbr-btns',{attrs:{"has-delete":_vm.schema.array.hasDelete,"has-sort":_vm.schema.array.hasSort,"can-delete":_vm.schema.__propSchemaList.length > _vm.schema.array.min,"fixed":_vm.schema.array.fixed,"is-first":index == 0,"is-last":index == _vm.schema.__propSchemaList.length - 1,"index":index,"has-del-warn":_vm.schema.array.hasDelWarn,"can-add":_vm.schema.array.max <= 0 ||
_vm.schema.__propSchemaList.length < _vm.schema.array.max,"has-add":_vm.schema.array.hasCopy,"del-msg":itemSchema.delMsg,"del-warn-btns":itemSchema.delWarnBtns,"info":itemSchema.__info},on:{"copyItem":_vm.copyItem,"delItem":_vm.delItem,"upItem":_vm.upItem,"downItem":_vm.downItem}})],1)]):_vm._e()]:[_c('div',{staticClass:"es-single-pannel"},[_c('div',{staticClass:"es-single-box"},[_vm._t("default",null,{"schema":itemSchema,"refName":index + ''})],2),(
_vm.schema.array.hasDelete ||
_vm.schema.array.hasSort ||
_vm.schema.array.hasCopy
)?_c('div',{staticClass:"es-btn-box es-single-btn-box",style:({
height: _vm.schema.properties
? _vm.schema.ui.rowHeight + 'px'
: _vm.schema.rowHeight + 'px'
})},[(_vm.schema.array.btnType !== 'icon')?_c('edit-btns',{attrs:{"has-delete":_vm.schema.array.hasDelete,"has-sort":_vm.schema.array.hasSort,"can-delete":_vm.schema.__propSchemaList.length > _vm.schema.array.min,"fixed":_vm.schema.array.fixed,"is-first":index == 0,"is-last":index == _vm.schema.__propSchemaList.length - 1,"index":index,"has-del-warn":_vm.schema.array.hasDelWarn,"can-add":_vm.schema.array.max <= 0 ||
_vm.schema.__propSchemaList.length < _vm.schema.array.max,"has-add":_vm.schema.array.hasCopy,"del-msg":itemSchema.delMsg,"del-warn-btns":itemSchema.delWarnBtns,"info":itemSchema.__info},on:{"copyItem":_vm.copyItem,"delItem":_vm.delItem,"upItem":_vm.upItem,"downItem":_vm.downItem}}):_c('edit-abbr-btns',{attrs:{"has-delete":_vm.schema.array.hasDelete,"has-sort":_vm.schema.array.hasSort,"can-delete":_vm.schema.__propSchemaList.length > _vm.schema.array.min,"fixed":_vm.schema.array.fixed,"is-first":index == 0,"is-last":index == _vm.schema.__propSchemaList.length - 1,"index":index,"has-del-warn":_vm.schema.array.hasDelWarn,"can-add":_vm.schema.array.max <= 0 ||
_vm.schema.__propSchemaList.length < _vm.schema.array.max,"has-add":_vm.schema.array.hasCopy,"del-msg":itemSchema.delMsg,"del-warn-btns":itemSchema.delWarnBtns,"info":itemSchema.__info},on:{"copyItem":_vm.copyItem,"delItem":_vm.delItem,"upItem":_vm.upItem,"downItem":_vm.downItem}})],1):_vm._e()])]],2)])])}),0),(_vm.schema.array.hasDelete || _vm.schema.array.hasAdd)?_c('div',{staticClass:"es-btn-footer",style:({
marginTop:
_vm.schema.__propSchemaList.length > 0
? Math.round(
Math.min(
Math.max(_vm.schema.array.rowSpace / 2, 10),
_vm.schema.array.rowSpace
)
) + 'px'
: '0px'
})},[_c('edit-bottom-btns',{attrs:{"has-delete":_vm.schema.array.hasDelete &&
_vm.schema.array.min <= 0 &&
_vm.schema.array.fixed <= 0,"has-add":_vm.schema.array.hasAdd,"can-delete":_vm.schema.__propSchemaList.length > 0 &&
_vm.schema.array.fixed <= 0 &&
_vm.schema.array.min <= 0,"can-add":_vm.schema.array.max <= 0 ||
_vm.schema.__propSchemaList.length < _vm.schema.array.max,"index":-1,"has-del-warn":_vm.schema.array.hasDelWarn,"del-msg":_vm.schema.array.delAllMsg,"del-warn-btns":_vm.schema.array.delWarnBtns,"info":_vm.schema.__info},on:{"delItem":_vm.delAllItems,"addItem":_vm.addItem}})],1):_vm._e()]),(_vm.schema.help && !_vm.schema.help.hidden && _vm.schema.component)?_c('div',{staticClass:"es-form-help",style:({
height: _vm.schema.properties
? _vm.schema.ui.rowHeight + 'px'
: _vm.schema.rowHeight + 'px'
})},[_c('es-base',{attrs:{"config":_vm.schema.help,"info":_vm.schema.__info}})],1):_vm._e()])}
var array_legendvue_type_template_id_7e48e6b3_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/layout/array-legend.vue?vue&type=template&id=7e48e6b3&
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/array-legend.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
/* harmony default export */ var array_legendvue_type_script_lang_js_ = ({
mixins: [item_mixin, array_mixin],
components: {
esObject: object,
editBtns: edit_btns,
editAbbrBtns: edit_abbr_btns,
editBottomBtns: edit_bottom_btns,
tabs: tabs,
esBase: base
},
methods: {}
});
// CONCATENATED MODULE: ./src/package/layout/array-legend.vue?vue&type=script&lang=js&
/* harmony default export */ var layout_array_legendvue_type_script_lang_js_ = (array_legendvue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/layout/array-legend.vue?vue&type=style&index=0&lang=scss&
var array_legendvue_type_style_index_0_lang_scss_ = __webpack_require__("3710");
// CONCATENATED MODULE: ./src/package/layout/array-legend.vue
/* normalize component */
var array_legend_component = Object(componentNormalizer["a" /* default */])(
layout_array_legendvue_type_script_lang_js_,
array_legendvue_type_template_id_7e48e6b3_render,
array_legendvue_type_template_id_7e48e6b3_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var array_legend = (array_legend_component.exports);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/array-card.vue?vue&type=template&id=4ab3e209&
var array_cardvue_type_template_id_4ab3e209_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"es-form-array-card"},[_c('ul',{staticClass:"es-order-list-box",style:({
marginBottom:
_vm.schema.__propSchemaList.length > 0
? -Math.floor(_vm.schema.array.rowSpace) + 'px'
: 0
})},_vm._l((_vm.schema.__propSchemaList),function(itemSchema,index){return _c('li',{key:index,staticClass:"list-item",style:({
marginRight: _vm.schema.array.rowSpace + 'px',
marginBottom: Math.floor(_vm.schema.array.rowSpace) + 'px'
})},[(
(itemSchema.rules &&
itemSchema.rules.required &&
itemSchema.rules.showRequired) ||
_vm.schema.array.hasOrder ||
_vm.schema.array.hasDelete ||
_vm.schema.array.hasSort ||
_vm.schema.array.hasCopy
)?_c('div',{staticClass:"es-btn-box"},[_c('div',{staticClass:"es-array-row-head"},[(_vm.schema.array.hasOrder)?_c('span',{staticClass:"order-txt"},[(
itemSchema.rules &&
itemSchema.rules.required &&
itemSchema.rules.showRequired
)?_c('span',{staticClass:"es-required"},[_vm._v("*")]):_vm._e(),_vm._v(_vm._s(index + 1)+".")]):(
itemSchema.rules &&
itemSchema.rules.required &&
itemSchema.rules.showRequired
)?_c('span',{staticClass:"order-txt"},[_c('span',{staticClass:"es-required"},[_vm._v("*")])]):_vm._e(),_c('span',{staticClass:"order-full"}),(
_vm.schema.array.hasDelete ||
_vm.schema.array.hasSort ||
_vm.schema.array.hasCopy
)?_c('span',{staticClass:"head-edit-wrap"},[_c('edit-abbr-btns',{attrs:{"has-delete":_vm.schema.array.hasDelete,"has-sort":_vm.schema.array.hasSort,"can-delete":_vm.schema.__propSchemaList.length > _vm.schema.array.min,"fixed":_vm.schema.array.fixed,"is-first":index == 0,"is-last":index == _vm.schema.__propSchemaList.length - 1,"index":index,"has-del-warn":_vm.schema.array.hasDelWarn,"can-add":_vm.schema.array.max <= 0 ||
_vm.schema.__propSchemaList.length < _vm.schema.array.max,"has-add":_vm.schema.array.hasCopy,"del-msg":itemSchema.delMsg,"del-warn-btns":itemSchema.delWarnBtns,"info":itemSchema.__info,"size":"small","isHArrow":true},on:{"copyItem":_vm.copyItem,"delItem":_vm.delItem,"upItem":_vm.upItem,"downItem":_vm.downItem}})],1):_vm._e()])]):_vm._e(),_c('div',{staticClass:"es-array-row-body"},[_vm._t("default",null,{"schema":itemSchema,"refName":index + ''})],2)])}),0),(_vm.schema.array.hasAdd)?_c('div',{staticClass:"es-card-add-box",style:({
height: _vm.schema.properties
? _vm.schema.ui.rowHeight + 'px'
: _vm.schema.rowHeight + 'px'
})},[(_vm.schema.array.hasAdd)?_c('es-btn',{staticClass:"es-btn es-plus-btn",attrs:{"disabled":_vm.schema.array.max > 0 &&
_vm.schema.__propSchemaList.length >= _vm.schema.array.max},on:{"click":_vm.addItem}}):_vm._e()],1):_vm._e(),(_vm.schema.help && !_vm.schema.help.hidden && _vm.schema.component)?_c('div',{staticClass:"es-form-help",style:({
height: _vm.schema.properties
? _vm.schema.ui.rowHeight + 'px'
: _vm.schema.rowHeight + 'px'
})},[_c('es-base',{attrs:{"config":_vm.schema.help,"info":_vm.schema.__info}})],1):_vm._e()])}
var array_cardvue_type_template_id_4ab3e209_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/layout/array-card.vue?vue&type=template&id=4ab3e209&
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/array-card.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
// import editBottomBtns from "../components/edit-bottom-btns";
/* harmony default export */ var array_cardvue_type_script_lang_js_ = ({
mixins: [item_mixin, array_mixin],
components: {
esObject: object,
editAbbrBtns: edit_abbr_btns,
// editBottomBtns,
tabs: tabs,
esBase: base,
esBtn: btn
},
methods: {}
});
// CONCATENATED MODULE: ./src/package/layout/array-card.vue?vue&type=script&lang=js&
/* harmony default export */ var layout_array_cardvue_type_script_lang_js_ = (array_cardvue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/layout/array-card.vue?vue&type=style&index=0&lang=scss&
var array_cardvue_type_style_index_0_lang_scss_ = __webpack_require__("af3d");
// CONCATENATED MODULE: ./src/package/layout/array-card.vue
/* normalize component */
var array_card_component = Object(componentNormalizer["a" /* default */])(
layout_array_cardvue_type_script_lang_js_,
array_cardvue_type_template_id_4ab3e209_render,
array_cardvue_type_template_id_4ab3e209_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var array_card = (array_card_component.exports);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/array-table.vue?vue&type=template&id=6145121c&
var array_tablevue_type_template_id_6145121c_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"es-form-array-table"},[_c('table',{staticClass:"es-table"},[_c('thead',[(_vm.schema.array.hasOrder !== false)?_c('th',{staticClass:"es-order-fixed",style:({ padding: _vm.schema.ui.rowSpace / 2 + 'px' })},[_vm._v("\n 序号\n ")]):_vm._e(),_vm._l((_vm.schema.properties),function(headerSchema,headerFieldName){return [(_vm.schema.properties[headerFieldName].__rawHidden !== true)?_c('th',{key:headerFieldName,style:(headerSchema.__headStyle)},[_c('div',{class:[
'es-form-table-head',
headerSchema.label && headerSchema.label.align
? 'es-form-component-' + headerSchema.label.align
: ''
]},[(
_vm.schema.array.headRequired &&
headerSchema.rules &&
headerSchema.rules.required &&
headerSchema.rules.showRequired
)?_c('span',{staticClass:"es-required"},[_vm._v("*")]):_vm._e(),(headerSchema.label && !headerSchema.label.hidden)?[(!headerSchema.label.name)?_c('span',[_vm._v("\n "+_vm._s(headerSchema.label.text
? headerSchema.label.text
: headerFieldName + "")+"\n ")]):_c('span',{staticClass:"es-form-label-box"},[_c('es-base',{attrs:{"config":headerSchema.label,"info":headerSchema.__info}})],1),(
headerSchema.label.help && !headerSchema.label.help.hidden
)?_c('span',{staticClass:"es-form-label-help"},[_c('es-base',{attrs:{"config":headerSchema.label.help,"info":headerSchema.__info}})],1):_vm._e()]:[_vm._v("\n "+_vm._s(headerFieldName + "")+"\n ")]],2)]):_vm._e()]}),(_vm.schema.array.hasDelete || _vm.schema.array.hasSort)?_c('th',{staticClass:"es-btn-fixed",style:({ padding: _vm.schema.ui.rowSpace / 2 + 'px' })},[_vm._v("\n 操作\n ")]):_vm._e()],2),_c('tbody',_vm._l((_vm.schema.__propSchemaList),function(itemSchema,index){return _c('tr',{key:index},[(_vm.schema.array.hasOrder !== false)?_c('td',{style:({ padding: _vm.schema.array.rowSpace / 2 + 'px' })},[_c('span',{staticClass:"es-order-txt",style:({
height: _vm.schema.ui.rowHeight + 'px',
lineHeight: _vm.schema.ui.rowHeight + 'px'
})},[_vm._v(_vm._s(index + 1)+".")])]):_vm._e(),_vm._l((itemSchema.properties),function(fieldSchema,fieldName){return [(_vm.schema.properties[fieldName].__rawHidden !== true)?_c('td',{key:fieldName,style:({
padding: _vm.schema.array.rowSpace / 2 + 'px',
textAlign: fieldSchema.label.align
})},[_c('es-object-table',{attrs:{"schema":fieldSchema,"has-required":!_vm.schema.array.headRequired}},[_vm._t(fieldName,null,{"schema":fieldSchema,"index":index,"refName":fieldName + '_' + index})],2)],1):_vm._e()]}),(
_vm.schema.array.hasDelete ||
_vm.schema.array.hasSort ||
_vm.schema.array.hasCopy
)?_c('td',{style:({ padding: _vm.schema.array.rowSpace / 2 + 'px' })},[_c('div',{staticClass:"es-btn-box",style:({ height: _vm.schema.ui.rowHeight + 'px' })},[(_vm.schema.array.btnType !== 'icon')?_c('edit-btns',{attrs:{"has-delete":_vm.schema.array.hasDelete,"has-sort":_vm.schema.array.hasSort,"can-delete":_vm.schema.__propSchemaList.length > _vm.schema.array.min,"fixed":_vm.schema.array.fixed,"is-first":index == 0,"is-last":index == _vm.schema.__propSchemaList.length - 1,"index":index,"has-del-warn":_vm.schema.array.hasDelWarn,"can-add":_vm.schema.array.max <= 0 ||
_vm.schema.__propSchemaList.length < _vm.schema.array.max,"has-add":_vm.schema.array.hasCopy,"del-msg":itemSchema.delMsg,"del-warn-btns":itemSchema.delWarnBtns,"info":itemSchema.__info},on:{"copyItem":_vm.copyItem,"delItem":_vm.delItem,"upItem":_vm.upItem,"downItem":_vm.downItem}}):_c('edit-abbr-btns',{attrs:{"has-delete":_vm.schema.array.hasDelete,"has-sort":_vm.schema.array.hasSort,"can-delete":_vm.schema.__propSchemaList.length > _vm.schema.array.min,"fixed":_vm.schema.array.fixed,"is-first":index == 0,"is-last":index == _vm.schema.__propSchemaList.length - 1,"index":index,"has-del-warn":_vm.schema.array.hasDelWarn,"can-add":_vm.schema.array.max <= 0 ||
_vm.schema.__propSchemaList.length < _vm.schema.array.max,"has-add":_vm.schema.array.hasCopy,"del-msg":itemSchema.delMsg,"del-warn-btns":itemSchema.delWarnBtns,"info":itemSchema.__info},on:{"copyItem":_vm.copyItem,"delItem":_vm.delItem,"upItem":_vm.upItem,"downItem":_vm.downItem}})],1)]):_vm._e()],2)}),0),(_vm.schema.array.hasDelete || _vm.schema.array.hasAdd)?_c('tfoot',[_c('tr',[_c('td',{style:({ padding: _vm.schema.array.rowSpace / 2 + 'px' }),attrs:{"colspan":"100%"}},[_c('edit-bottom-btns',{attrs:{"has-delete":_vm.schema.array.hasDelete &&
_vm.schema.array.min <= 0 &&
_vm.schema.array.fixed <= 0,"has-add":_vm.schema.array.hasAdd,"can-delete":_vm.schema.__propSchemaList.length > 0 &&
_vm.schema.array.fixed <= 0 &&
_vm.schema.array.min <= 0,"index":-1,"has-del-warn":_vm.schema.array.hasDelWarn,"can-add":_vm.schema.array.max <= 0 ||
_vm.schema.__propSchemaList.length < _vm.schema.array.max,"del-msg":_vm.schema.array.delAllMsg,"del-warn-btns":_vm.schema.array.delWarnBtns,"info":_vm.schema.__info},on:{"delItem":_vm.delAllItems,"addItem":_vm.addItem}})],1)])]):_vm._e()])])}
var array_tablevue_type_template_id_6145121c_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/layout/array-table.vue?vue&type=template&id=6145121c&
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/object-table.vue?vue&type=template&id=16c65a0a&
var object_tablevue_type_template_id_16c65a0a_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{directives:[{name:"show",rawName:"v-show",value:(!_vm.schema.hidden),expression:"!schema.hidden"}],staticClass:"es-form-table-container"},[(
_vm.hasRequired &&
_vm.schema.rules &&
_vm.schema.rules.required &&
_vm.schema.rules.showRequired
)?_c('span',{staticClass:"es-table-required es-required",style:({
height: _vm.schema.rowHeight + 'px',
lineHeight: _vm.schema.rowHeight + 'px'
})},[_vm._v("*")]):_vm._e(),_c('div',{staticClass:"es-form-comp-content"},[_vm._t("default")],2)])}
var object_tablevue_type_template_id_16c65a0a_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/layout/object-table.vue?vue&type=template&id=16c65a0a&
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/object-table.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
/* harmony default export */ var object_tablevue_type_script_lang_js_ = ({
mixins: [item_mixin],
data: function data() {
return {};
},
props: {
hasRequired: true
},
methods: {}
});
// CONCATENATED MODULE: ./src/package/layout/object-table.vue?vue&type=script&lang=js&
/* harmony default export */ var layout_object_tablevue_type_script_lang_js_ = (object_tablevue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/layout/object-table.vue?vue&type=style&index=0&lang=scss&
var object_tablevue_type_style_index_0_lang_scss_ = __webpack_require__("2223");
// CONCATENATED MODULE: ./src/package/layout/object-table.vue
/* normalize component */
var object_table_component = Object(componentNormalizer["a" /* default */])(
layout_object_tablevue_type_script_lang_js_,
object_tablevue_type_template_id_16c65a0a_render,
object_tablevue_type_template_id_16c65a0a_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var object_table = (object_table_component.exports);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/array-table.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
/* harmony default export */ var array_tablevue_type_script_lang_js_ = ({
mixins: [item_mixin, array_mixin],
components: {
esBase: base,
esObjectTable: object_table,
editBtns: edit_btns,
editAbbrBtns: edit_abbr_btns,
editBottomBtns: edit_bottom_btns
},
methods: {}
});
// CONCATENATED MODULE: ./src/package/layout/array-table.vue?vue&type=script&lang=js&
/* harmony default export */ var layout_array_tablevue_type_script_lang_js_ = (array_tablevue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/layout/array-table.vue?vue&type=style&index=0&lang=scss&
var array_tablevue_type_style_index_0_lang_scss_ = __webpack_require__("6fe2");
// CONCATENATED MODULE: ./src/package/layout/array-table.vue
/* normalize component */
var array_table_component = Object(componentNormalizer["a" /* default */])(
layout_array_tablevue_type_script_lang_js_,
array_tablevue_type_template_id_6145121c_render,
array_tablevue_type_template_id_6145121c_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var array_table = (array_table_component.exports);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/array-tabs.vue?vue&type=template&id=5bf66d41&
var array_tabsvue_type_template_id_5bf66d41_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"es-form-array-tabs"},[_c('es-tabs-nav',{attrs:{"hasAdd":_vm.schema.array.hasAdd,"canAdd":_vm.schema.array.max > 0 &&
_vm.schema.__propSchemaList.length >= _vm.schema.array.max,"type":_vm.schema.array.type},on:{"addItem":_vm.addItemHandler}},[_vm._l((_vm.schema.__propSchemaList),function(itemSchema,index){return [_c('es-tabs-nav-item',{key:index,attrs:{"is-active":index === _vm.schema.__tabsIndex,"has-error":itemSchema.__hasError,"has-delete":_vm.schema.array.hasDelete,"has-sort":_vm.schema.array.hasSort,"can-delete":_vm.schema.__propSchemaList.length > _vm.schema.array.min,"fixed":_vm.schema.array.fixed,"is-first":index == 0,"is-last":index == _vm.schema.__propSchemaList.length - 1,"index":index,"has-del-warn":_vm.schema.array.hasDelWarn,"del-msg":itemSchema.delMsg,"del-warn-btns":itemSchema.delWarnBtns,"info":itemSchema.__info},on:{"delItem":_vm.delItemHandler,"upItem":_vm.upItem,"downItem":_vm.downItem,"clickActive":_vm.clickActiveHandler}},[(
itemSchema.rules &&
itemSchema.rules.required &&
itemSchema.rules.showRequired
)?_c('span',{staticClass:"order-txt"},[_c('span',{staticClass:"es-required"},[_vm._v("*")])]):_vm._e(),(_vm.schema.array.hasOrder)?_c('span',{staticClass:"order-txt"},[_vm._v(_vm._s(index + 1)+".")]):_vm._e(),(!itemSchema.subLabel.name || itemSchema.subLabel.hidden)?[(
!(
_vm.schema.array.hasOrder &&
(!itemSchema.subLabel.text || itemSchema.subLabel.hidden)
)
)?_c('span',[_vm._v(_vm._s(itemSchema.subLabel.text && !itemSchema.subLabel.hidden
? itemSchema.subLabel.text
: _vm.schema.array.hasOrder
? ""
: index + 1 + "")+"\n ")]):_vm._e()]:_c('span',{staticClass:"es-form-label-box"},[_c('es-base',{attrs:{"config":itemSchema.subLabel,"info":itemSchema.__info}})],1)],2)]}),(_vm.schema.help && !_vm.schema.help.hidden && _vm.schema.component)?_c('div',{staticClass:"es-form-help",attrs:{"slot":"help"},slot:"help"},[_c('es-base',{attrs:{"config":_vm.schema.help,"info":_vm.schema.__info}})],1):_vm._e()],2),(_vm.schema.__propSchemaList.length)?_c('ul',{staticClass:"es-tabs-body",style:({
padding: _vm.schema.array.hasBorder
? _vm.schema.array.padding
? _vm.schema.array.padding
: Math.min(_vm.schema.array.rowSpace, 10) + 'px'
: _vm.schema.array.padding
? _vm.schema.array.padding
: Math.min(_vm.schema.array.rowSpace, 10) + 'px 0 0 0',
'border-width': _vm.schema.array.hasBorder ? '1px' : '0px'
})},_vm._l((_vm.schema.__propSchemaList),function(itemSchema,index){return _c('li',{directives:[{name:"show",rawName:"v-show",value:(index === _vm.schema.__tabsIndex),expression:"index === schema.__tabsIndex"}],key:index},[(
itemSchema.properties &&
itemSchema.layout &&
itemSchema.layout.name === 'tabs'
)?_c('tabs',{tag:"component",attrs:{"schema":itemSchema}},[_vm._l((itemSchema.properties),function(fieldSchema,fieldName){return _c('template',{slot:fieldName},[_vm._t(fieldName,null,{"refName":fieldName + '_' + index,"schema":fieldSchema})],2)})],2):(itemSchema.properties)?_c('es-object',{attrs:{"schema":itemSchema}},[_vm._l((itemSchema.properties),function(fieldSchema,fieldName){return _c('template',{slot:fieldName},[_vm._t(fieldName,null,{"refName":fieldName + '_' + index,"schema":fieldSchema,"index":index})],2)})],2):[_vm._t("default",null,{"schema":itemSchema,"refName":index + ''})]],2)}),0):_vm._e()],1)}
var array_tabsvue_type_template_id_5bf66d41_staticRenderFns = []
// CONCATENATED MODULE: ./src/package/layout/array-tabs.vue?vue&type=template&id=5bf66d41&
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/layout/array-tabs.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
// import constant from "../libs/constant";
/* harmony default export */ var array_tabsvue_type_script_lang_js_ = ({
mixins: [item_mixin, array_mixin],
components: {
esObject: object,
esTabsNav: tabs_nav,
esTabsNavItem: tabs_nav_item,
tabs: tabs,
esBase: base
},
data: function data() {
return {};
},
methods: {
clickActiveHandler: function clickActiveHandler(index) {
var form = this.__getForm();
form._toggleUi("tabs", {
key: this.schema.__info.pathKey,
index: index
});
},
delItemHandler: function delItemHandler(index) {
var newIndex = false;
if (index < this.schema.__tabsIndex) {
// 删除的tab在当前高亮之前
newIndex = this.schema.__tabsIndex - 1;
} // console.log("newIndex: ", newIndex, index, this.schema.__tabsIndex);
this.delItem(index); // 这里会对this.schema.__propSchemaList进行减少
if (newIndex !== false) {
var form = this.__getForm();
form._toggleUi("tabs", {
key: this.schema.__info.pathKey,
index: newIndex
});
}
},
addItemHandler: function addItemHandler() {
this.addItem(); // 这里会对this.schema.__propSchemaList进行添加
var form = this.__getForm();
form._toggleUi("tabs", {
key: this.schema.__info.pathKey,
index: this.schema.__propSchemaList.length - 1
});
}
},
mounted: function mounted() {},
beforeDestroy: function beforeDestroy() {}
});
// CONCATENATED MODULE: ./src/package/layout/array-tabs.vue?vue&type=script&lang=js&
/* harmony default export */ var layout_array_tabsvue_type_script_lang_js_ = (array_tabsvue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/layout/array-tabs.vue?vue&type=style&index=0&lang=scss&
var array_tabsvue_type_style_index_0_lang_scss_ = __webpack_require__("5100");
// CONCATENATED MODULE: ./src/package/layout/array-tabs.vue
/* normalize component */
var array_tabs_component = Object(componentNormalizer["a" /* default */])(
layout_array_tabsvue_type_script_lang_js_,
array_tabsvue_type_template_id_5bf66d41_render,
array_tabsvue_type_template_id_5bf66d41_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var array_tabs = (array_tabs_component.exports);
// EXTERNAL MODULE: ./src/package/libs/global.js
var global = __webpack_require__("394e");
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/form-item.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
/* harmony default export */ var form_itemvue_type_script_lang_js_ = ({
name: "form-item",
// 声明name可以嵌套自身
mixins: [item_mixin],
data: function data() {
return {
REF_FORM_ITEM: "REF_FORM_ITEM" // unwatch: false,
// showBody: true,
// isChanged: false,
// triggerList: []
};
},
props: {
refName: {
// 此值用来记录当前ref的索引,用来区分哪个组件(因为取出来是一个数组)
type: String,
default: ""
}
},
components: {
esBase: base,
esObject: object,
arrayRow: array_row,
arrayTable: array_table,
arrayTabs: array_tabs,
arrayCard: array_card,
arrayLegend: array_legend,
tabs: tabs
},
created: function created() {},
computed: {
needHeader: function needHeader() {
return this.schema.properties && (this.schema.title && !this.schema.title.hidden && (this.schema.title.name || this.schema.title.text || this.schema.title.help && this.schema.title.help.hidden) || this.schema.ui.__hasToggle || this.schema.help) ? true : false; // 是否有头部
},
bodyStyle: function bodyStyle() {
//是properties且有头部
var hasBorder = this.schema.ui && this.schema.ui.hasBorder ? this.schema.ui.hasBorder : false;
var style = null; // 是否有头部
if (this.needHeader) {
if (hasBorder) {
style = {
padding: this.schema.ui.padding ? this.schema.ui.padding : Math.min(this.schema.ui.rowSpace, 10) + "px"
}; //有边框时的样式
} else {
style = {
padding: this.schema.ui.padding ? this.schema.ui.padding : Math.min(this.schema.ui.rowSpace, 10) + "px 0 0 0"
}; //无边框时的样式
}
} else {
if (hasBorder) {
style = {
padding: this.schema.ui.padding ? this.schema.ui.padding : Math.min(this.schema.ui.rowSpace, 10) + "px"
}; //有边框时的样式
}
}
return style;
}
},
methods: {
/* 下划线一杠代表对内使用 */
_getType: function _getType() {
return this.schema.array ? constant["a" /* default */].UI_ARRAY : constant["a" /* default */].UI_ITEM;
},
/* 下划线一杠代表对内使用 */
_getSchema: function _getSchema() {
return this.schema;
},
getRef: function getRef(name, hasEmpty) {
function filterTarget(targets) {
var copyTargets = [];
targets.forEach(function (target) {
if (utils["a" /* default */].isArr(target)) {
var nextCopyTarget = filterTarget(target);
if (nextCopyTarget) {
copyTargets.push(nextCopyTarget);
}
} else if (target) {
copyTargets.push(target);
}
});
return copyTargets.length > 0 ? copyTargets : null;
}
var ignoreKeys = [];
var info = this.__getLastRefs(name, ignoreKeys);
var refTarget = info && info.target ? info.target : null; // console.log("ignoreKeys: ", ignoreKeys);
if (utils["a" /* default */].isArr(refTarget) && !hasEmpty) {
// 去掉null(为了以后的扩展,才这样返回)
refTarget = filterTarget(refTarget);
}
ignoreKeys = null;
return refTarget;
},
__getRefStatKey: function __getRefStatKey() {
if (this.schema.hidden) {
return ""; // 返回空值,说明此组件是隐藏了,用户根据此状态判断
} else {
return this.refName;
}
},
/* 取出最后的,跟vue ref保持一致;也就是后面的会代表前面的 */
__getLastRefs: function __getLastRefs(name, ignoreKeys) {
var refRecord;
var newTargetInfo, nextTargetInfo, props, key;
if (!this.schema.array) {
// 非数组
if (this.schema.properties) {
refRecord = this.__createRefRecord(this.$refs[this.REF_FORM_ITEM]);
props = this.schema.properties;
for (key in props) {
if (refRecord[key]) {
nextTargetInfo = refRecord[key].__getLastRefs(name, ignoreKeys);
if (nextTargetInfo) {
if (!ignoreKeys.includes(nextTargetInfo.sourceKey)) {
if (newTargetInfo && !ignoreKeys.includes(newTargetInfo.sourceKey)) {
ignoreKeys.push(newTargetInfo.sourceKey);
}
newTargetInfo = nextTargetInfo; // 后面的代替前面的,跟原生vue ref保持一致
}
}
}
}
} else {
// 组件/叶子节点,直接取出
var refTarget = this.$refs[name];
if (refTarget) {
newTargetInfo = {
target: refTarget.$refs[constant["a" /* default */].COM_TARGET_REF],
sourceKey: this.schema.__info.pathKey.replace(/\[\d+\]/g, "[i]")
};
} else {
newTargetInfo = null;
}
}
} else {
refRecord = this.__createRefRecord(this.$refs[this.REF_FORM_ITEM]); // 数组
if (this.schema.properties) {
var standardRecord = this.__parseArrRecord(refRecord);
props = this.schema.properties;
for (key in props) {
var arrayRecord = standardRecord[key];
if (arrayRecord) {
var nextTargetInfos = [];
this.schema.__propSchemaList.forEach(function (item, index) {
if (arrayRecord[index]) {
var tmpNextTargetInfo = arrayRecord[index].__getLastRefs(name, ignoreKeys);
if (!tmpNextTargetInfo || ignoreKeys.includes(tmpNextTargetInfo.sourceKey)) {
nextTargetInfos.push(null); // 占位,把个数补充完整
} else {
nextTargetInfos.push(tmpNextTargetInfo);
}
} else {
nextTargetInfos.push(null); // 占位,把个数补充完整
}
}); // 取最后一个
var lastSourceKey;
nextTargetInfos.forEach(function (nextTargetInfo) {
if (nextTargetInfo) {
lastSourceKey = nextTargetInfo.sourceKey;
}
});
if (lastSourceKey) {
// 存在目标组件
if (newTargetInfo && !ignoreKeys.includes(newTargetInfo.sourceKey)) {
ignoreKeys.push(newTargetInfo.sourceKey);
}
var tmpTargets = [];
nextTargetInfos.forEach(function (nextTargetInfo) {
if (nextTargetInfo && nextTargetInfo.sourceKey === lastSourceKey) {
var target = nextTargetInfo.target; // if (utils.isArr(target)) {
// tmpTargets = tmpTargets.concat(target);
// } else {
tmpTargets.push(target); // }
} else {
tmpTargets.push(null); // 占位,把个数补充完整
}
});
newTargetInfo = {
target: tmpTargets,
sourceKey: lastSourceKey
}; // 后面的代替前面的,跟原生vue ref保持一致
}
}
}
} else if (this.schema.component) {
// 组件组成的数组
newTargetInfo = {
target: [],
sourceKey: ""
};
this.schema.__propSchemaList.forEach(function (item, index) {
if (refRecord[index]) {
var tmpTargetInfo = refRecord[index].__getLastRefs(name, ignoreKeys);
if (tmpTargetInfo) {
newTargetInfo.target.push(tmpTargetInfo.target);
newTargetInfo.sourceKey = tmpTargetInfo.sourceKey;
} else {
newTargetInfo.target.push(null); // 占位,把个数补充完整
}
} else {
newTargetInfo.target.push(null); // 占位,把个数补充完整
}
});
var hasTarget = newTargetInfo.target.some(function (item) {
return !!item;
});
if (!hasTarget) {
newTargetInfo = null;
} else if (!newTargetInfo.sourceKey || ignoreKeys.includes(newTargetInfo.sourceKey)) {
newTargetInfo = null;
}
} else {
newTargetInfo = null;
}
}
return newTargetInfo;
},
__parseArrRecord: function __parseArrRecord(arrayRecord) {
var newRecord = {};
for (var key in arrayRecord) {
if (arrayRecord[key]) {
var sperator = "_";
var lastPosition = key.lastIndexOf(sperator);
var refName = key.substr(0, lastPosition);
var index = key.substr(lastPosition + 1);
if (!newRecord[refName]) {
newRecord[refName] = {};
}
newRecord[refName][index] = arrayRecord[key];
}
}
return newRecord;
},
__createRefRecord: function __createRefRecord(comRefs) {
var refRecord = {};
if (comRefs) {
comRefs.forEach(function (formItem) {
var refStatKey = formItem.__getRefStatKey();
if (refStatKey !== "") {
refRecord[refStatKey] = formItem;
}
});
}
return refRecord;
},
toggleBody: function toggleBody() {
var form = this.__getForm();
form._toggleUi("toggle", {
key: this.schema.__info.pathKey
});
},
// 只有组件会触发
triggerHandler: function triggerHandler(eventName, args, target) {
var eventData = args[0];
var checkSchema = [this.schema];
var eventNames = [eventName];
var targetValue = this.schema.component.value;
if (this.schema.isTrim && utils["a" /* default */].isStr(targetValue) && (eventName == global["a" /* default */].trimEvent || constant["a" /* default */].FORM_INPUTS.includes(this.schema.component.name) && eventName == constant["a" /* default */].INPUT_CHANGE)) {
// global.trimEvent暂不会是constant.INPUT_EVENT事件,因为初始化时就不给设置为此值
var tmpValue = targetValue.trim();
if (tmpValue !== targetValue) {
this.schema.component.value = tmpValue;
targetValue = tmpValue;
eventNames.push(constant["a" /* default */].INPUT_EVENT); // 值有所改变,同时input一下
}
}
var options = {
value: utils["a" /* default */].deepCopy(targetValue),
event: eventData,
args: args,
pathKey: this.schema.__info.pathKey,
index: this.schema.__info.index,
idxChain: this.schema.__info.idxChain,
target: target
};
var form = this.__getForm();
form._syncFormUi(checkSchema, eventNames, options);
},
/**
* 数组改变:添加、删除、移动
* handlers 需要处理的input and change actions
* eventData 事件本身的参数;具体看array-mixin.js
*/
formArrayInput: function formArrayInput(targetValue, eventData) {
var checkSchema = [this.schema];
var eventNames = [constant["a" /* default */].INPUT_EVENT, constant["a" /* default */].CHANGE_EVENT];
var options = {
value: targetValue,
event: eventData,
args: [eventData],
pathKey: this.schema.__info.pathKey,
index: this.schema.__info.index,
idxChain: this.schema.__info.idxChain,
target: null
};
var form = this.__getForm();
form._syncFormUi(checkSchema, eventNames, options); // 最外层的表单层同步所有的ui及数位
},
__getForm: function __getForm() {
var formItem = this.$parent;
while (formItem) {
var type = formItem._getType ? formItem._getType() : "";
if (type == constant["a" /* default */].UI_FORM) {
return formItem; // 到达表单层
} else if (type == constant["a" /* default */].UI_ARRAY) {// checkSchema.push(formItem._getSchema());
} else {// ... 往上派
}
formItem = formItem.$parent;
}
}
},
watch: {}
});
// CONCATENATED MODULE: ./src/package/form-item.vue?vue&type=script&lang=js&
/* harmony default export */ var package_form_itemvue_type_script_lang_js_ = (form_itemvue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/form-item.vue?vue&type=style&index=0&lang=scss&
var form_itemvue_type_style_index_0_lang_scss_ = __webpack_require__("fae7");
// CONCATENATED MODULE: ./src/package/form-item.vue
/* normalize component */
var form_item_component = Object(componentNormalizer["a" /* default */])(
package_form_itemvue_type_script_lang_js_,
form_itemvue_type_template_id_50cb9797_render,
form_itemvue_type_template_id_50cb9797_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var form_item = (form_item_component.exports);
// EXTERNAL MODULE: ./src/package/libs/schema-utils.js + 10 modules
var schema_utils = __webpack_require__("34bc");
// EXTERNAL MODULE: ./src/package/libs/parse.js
var parse = __webpack_require__("5f60");
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"13ad4c70-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/console.vue?vue&type=template&id=5937f053&
var consolevue_type_template_id_5937f053_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"es-console-box",style:({ zIndex: _vm.boxZIndex })},[_c('button',{staticClass:"console-btn",on:{"click":_vm.clickHandler}},[_vm._v("C")]),(_vm.hadShow)?_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.showPanel),expression:"showPanel"}],ref:"panel",staticClass:"es-console-panel",style:({
right: _vm.positions.right + 'px',
top: _vm.positions.top + 'px',
zIndex: _vm.positions.zIndex
})},[_c('div',{staticClass:"console-header",on:{"mousedown":_vm.startDragHandler}},[_c('h2',{staticClass:"panel-title"},[_vm._v("esForm调试面板")])]),_c('div',{staticClass:"console-close",on:{"click":function($event){_vm.showPanel = false}}},[_vm._v("Close")]),(_vm.showPanel)?_c('div',{staticClass:"panel-body"},[_vm._m(0),_c('h3',{staticClass:"subtitle"},[_vm._v("根值(rootValue) => getValue取出")]),_c('textarea',{staticClass:"value-box",attrs:{"readonly":"readonly"},domProps:{"value":_vm.toJson(_vm.rootValue)}}),_c('h3',{staticClass:"subtitle"},[_vm._v("表单值(formValue) => getFormValue取出")]),_c('textarea',{staticClass:"value-box",attrs:{"readonly":"readonly"},domProps:{"value":_vm.toJson(_vm.formValue)}})]):_vm._e()]):_vm._e()])}
var consolevue_type_template_id_5937f053_staticRenderFns = [function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"question-box"},[_c('a',{staticClass:"question",attrs:{"href":"https://chengaohe45.github.io/vue-easy-form-docs/dist/base/console.html","target":"_blank"}},[_vm._v("如何打开面板?")]),_c('a',{staticClass:"question",attrs:{"href":"https://chengaohe45.github.io/vue-easy-form-docs/dist/base/explain.html#根值","target":"_blank"}},[_vm._v("什么是根值?")]),_c('a',{staticClass:"question",attrs:{"href":"https://chengaohe45.github.io/vue-easy-form-docs/dist/base/explain.html#表单值","target":"_blank"}},[_vm._v("什么是表单值?")])])}]
// CONCATENATED MODULE: ./src/package/components/console.vue?vue&type=template&id=5937f053&
// EXTERNAL MODULE: ./node_modules/core-js/modules/es6.regexp.constructor.js
var es6_regexp_constructor = __webpack_require__("3b2b");
// CONCATENATED MODULE: ./src/package/libs/drag.js
/**
* 点击拖拽
* @param {*} event mousedown事件
* @param {*} callback 回调函数。mousemove返回偏移量,mouseup返回false
*/
function esDrag(event, callback) {
// The mouse position (in window coordinates)
// at which the drag begins
var cb = callback;
var startX = event.clientX,
startY = event.clientY; // var deltaX = startX - origX, deltaY = startY - origY;
document.addEventListener("mousemove", moveHandler, true);
document.addEventListener("mouseup", upHandler, true);
window.addEventListener("blur", upHandler, true); // We've handled this event. Don't let anybody else see it.
if (event.stopPropagation) event.stopPropagation(); // DOM Level 2
else event.cancelBubble = true; // IE
// Now prevent any default action.
if (event.preventDefault) event.preventDefault(); // DOM Level 2
else event.returnValue = false; // IE
/**
* This is the handler that captures mousemove events when an element
* is being dragged. It is responsible for moving the element.
**/
function moveHandler(e) {
if (!e) e = window.event; // IE Event Model
// Move the element to the current mouse position, adjusted as
// necessary by the offset of the initial mouse-click.
// elementToDrag.style.left = (e.clientX - deltaX) + "px";
// elementToDrag.style.top = (e.clientY - deltaY) + "px";
var offsetX = e.clientX - startX;
var offsetY = e.clientY - startY;
cb({
offsetX: offsetX,
offsetY: offsetY
}); // And don't let anyone else see this event.
if (e.stopPropagation) e.stopPropagation(); // DOM Level 2
else e.cancelBubble = true; // IE
}
/**
* This is the handler that captures the final mouseup event that
* occurs at the end of a drag.
**/
function upHandler(e) {
if (!e) e = window.event; // IE Event Model
document.removeEventListener("mousemove", moveHandler, true);
document.removeEventListener("mouseup", upHandler, true);
window.removeEventListener("blur", upHandler, true);
cb(false);
cb = null; // And don't let the event propagate any further.
if (e.stopPropagation) e.stopPropagation(); // DOM Level 2
else e.cancelBubble = true; // IE
}
event = null;
callback = null;
}
/* harmony default export */ var drag = (esDrag);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/components/console.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
/* harmony default export */ var consolevue_type_script_lang_js_ = ({
data: function data() {
return {
hadShow: false,
// 是否打开过panel
showPanel: false,
boxZIndex: false,
positions: {
right: 2,
top: 2,
zIndex: 1 // _esStartPoint: {
// x,
// y
// }
}
};
},
created: function created() {},
mounted: function mounted() {
this.$data.boxZIndex = this.getMaxZIndex() + 1;
},
props: {
rootValue: {
type: Object,
required: false,
default: function _default() {
return {};
}
},
formValue: {
type: Object,
required: false,
default: function _default() {
return {};
}
}
},
methods: {
/**
* 变为JSON输出,增强可读性
* @param source 解析源
* @param curTimes 解析了多少次了
*/
toJson: function toJson(source) {
var curTimes = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 1;
var MAX = 3; // 大于3次就不做变换了
var CAN_REPLACE = curTimes <= MAX ? true : false;
var UNDEFINED = curTimes < MAX ? utils["a" /* default */].randStr(15, 20) : "undefined值";
var undefinedObj = {},
hasSameUndefined = false;
var newSource = stringify_default()(source, function (key, value) {
if (key === UNDEFINED || value === UNDEFINED) {
// 出现相同的字符串,说明UNDEFINED值不可用(只是存在理论上的可能,比当上联合国秘书长的概率还低)
hasSameUndefined = true;
} else if (value === undefined) {
value = UNDEFINED;
undefinedObj[key] = value;
}
return value;
}, 2); // 不需要做那么漂亮,这种东西会影响性能的
// newSource = newSource.replace(/"([^\\"]+?)":/g, "$1:");
if (CAN_REPLACE) {
if (!hasSameUndefined) {
// 没有有相同的字符串,替换
if (keys_default()(undefinedObj).length > 0) {
// 需要替挽
// undefined 代替
// 因为数据是来自于开发者,这个基本可以控制字符串有UNDEFINED
var undefinedReg = new RegExp('"' + UNDEFINED + '"', "g");
newSource = newSource.replace(undefinedReg, "undefined");
}
return newSource;
} else {
// 有相同的字符串,重来一次
newSource = null;
var nextTime = curTimes + 1;
return this.toJson(source, nextTime);
}
} else {
// 直接输出;不做替换了;因为之前做过了MAX次了;理论就不会进入这里,进入这里只是备用做展示,对功能没有什么影响
return newSource;
}
},
clickHandler: function clickHandler() {
var _this = this;
if (!this.$data.showPanel) {
this.$data.positions.right = 2;
this.$data.positions.top = 2;
this.$data.positions.zIndex = this.getMaxZIndex() + 1;
} else {// ...
}
this.$data.showPanel = !this.$data.showPanel;
if (this.$data.showPanel && !this.$data.hadShow) {
this.$data.hadShow = true;
this.$nextTick(function () {
_this.addPopDom();
});
}
},
startDragHandler: function startDragHandler(event) {
var _this2 = this;
this._esStartPoint = {
right: this.$data.positions.right,
top: this.$data.positions.top
};
drag(event, function (info) {
if (info) {
var right = _this2._esStartPoint.right - info.offsetX;
var top = _this2._esStartPoint.top + info.offsetY;
_this2.$data.positions.right = right;
_this2.$data.positions.top = top;
} else {
_this2._esStartPoint = null;
}
});
},
getMaxZIndex: function getMaxZIndex() {
var _this3 = this;
// var childNodes = document.body.childNodes;
var childNodes = document.all || document.querySelectorAll("*");
var maxZIndex = 0;
childNodes.forEach(function (node) {
var tmpZIndex = _this3.getAttrValue(node, "z-index");
maxZIndex = Math.max(maxZIndex, tmpZIndex);
});
return maxZIndex;
},
getAttrValue: function getAttrValue(element, attrName) {
// console.log("element", element);
var value = 0;
if (element.nodeType == 1) {
var valueStr = window.getComputedStyle(element).getPropertyValue(attrName); // valueStr = "px";
// console.log("element", valueStr);
valueStr = valueStr + "";
var reg = /^\d+$/i;
var txtArr = valueStr.match(reg);
if (txtArr && txtArr[0]) {
value = Number(txtArr[0]);
}
} // console.log(valueStr, value);
return value;
},
addPopDom: function addPopDom() {
if (!this.$data.popDom && this.$refs.panel) {
this.$data.popDom = this.$refs.panel;
document.body.appendChild(this.$data.popDom);
}
},
removePopDom: function removePopDom() {
if (this.$data.popDom) {
document.body.removeChild(this.$data.popDom);
this.$data.popDom = null;
}
}
},
beforeDestroy: function beforeDestroy() {
this._esStartPoint = null;
this.removePopDom();
}
});
// CONCATENATED MODULE: ./src/package/components/console.vue?vue&type=script&lang=js&
/* harmony default export */ var components_consolevue_type_script_lang_js_ = (consolevue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/components/console.vue?vue&type=style&index=0&lang=scss&
var consolevue_type_style_index_0_lang_scss_ = __webpack_require__("5bb4");
// CONCATENATED MODULE: ./src/package/components/console.vue
/* normalize component */
var console_component = Object(componentNormalizer["a" /* default */])(
components_consolevue_type_script_lang_js_,
consolevue_type_template_id_5937f053_render,
consolevue_type_template_id_5937f053_staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var components_console = (console_component.exports);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/package/index.vue?vue&type=script&lang=js&
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
/* harmony default export */ var packagevue_type_script_lang_js_ = ({
/* ====================== 生命周期 ====================== */
created: function created() {
this.$data.canConsole = utils["a" /* default */].isBool(this.hasConsole) ? this.hasConsole : global["a" /* default */].hasConsole;
this._esHiddenLevel = 0; // 层级设置为0
this._esLockSubmit = false;
var hiddenFunc = this.isHidden;
data_cache.setHiddenFunc(this.$data.id, hiddenFunc.bind(this)); // 用于作隐藏解析
data_cache.setGlobal(this.$data.id, this.global ? utils["a" /* default */].deepCopy(this.global) : {});
this.__initUi(this.schema);
},
mounted: function mounted() {},
destroyed: function destroyed() {},
data: function data() {
return {
id: utils["a" /* default */].newUid("es"),
/* _es这些属性都不涉及页面的控制,所以不设置为data
_esHiddenLevel: 0,
_esOriginalSchemaValue: null, // schema里面的初始值,不包括formValue
_esOriginalRootValue: null, // schema里面的初始值和formValue结合组成的初始值
_esFormValue: null,
_esLockSubmit: false // 开始是false,
_esWarns: []
*/
canConsole: true,
csRootValue: null,
// 用于console, 只有当canConsole为true时才有值
csFormValue: null,
formSchema: {},
// $data有这个值说明是es-form
isInited: false
};
},
/* ====================== 引用组件 ====================== */
components: {
formItem: form_item,
consolePanel: components_console
},
/* ====================== 数据绑定 ====================== */
props: {
// 基础的类型检查 (`null` 和 `undefined` 会通过任何类型验证)
global: {
// 经测试:当传为null时,global的值就为null, 当传为undefined时,global的值就为default
// 用来接受外部数据
type: Object,
// 经测试:当传为null或undefined时,validator中的value参数都为default,跟global有点不同,奇怪吧
// validator: function (value) {
// console.log("value: ", value);
// return value !== null;
// },
default: function _default() {
return {};
}
},
schema: {
type: Object
},
value: {
type: Object,
required: false,
default: function _default() {
return {};
}
},
hasConsole: {
type: Boolean,
required: false,
default: undefined // 不能设置true/false,因为没设置会去匹配global
}
},
/* ====================== 事件处理 ====================== */
methods: {
/**
* @param name 索引值
* @param hasEmpty 是否过滤空值,true为不需要
* @param idxChain 组件所在的位置 如: 1,2 或 0
*/
getRef: function getRef(name, hasEmpty, idxChain) {
if (utils["a" /* default */].isNum(hasEmpty) || utils["a" /* default */].isStr(hasEmpty)) {
idxChain = hasEmpty;
hasEmpty = false;
} // var start = +new Date();
var ref = this.$refs.formFrame.getRef(name, hasEmpty); // console.log("ref: ", ref);
if (ref && utils["a" /* default */].isArr(ref)) {
if (utils["a" /* default */].isNum(idxChain)) {
ref = ref[idxChain];
} else if (idxChain && utils["a" /* default */].isStr(idxChain)) {
var indexs = idxChain.split(",");
var curLevel = ref;
for (var i = 0; i < indexs.length; i++) {
var index = indexs[i];
if (utils["a" /* default */].isArr(curLevel) && index !== "" && curLevel[index]) {
curLevel = curLevel[index];
} else {
curLevel = null;
break;
}
}
ref = curLevel;
}
} // var end = +new Date();
// console.log("expired = ", end - start);
return ref ? ref : null;
},
/**
* 对外调用,取值
* 实时取值,表单存在的值;也是getRootData的别名
*/
getValue: function getValue() {
return utils["a" /* default */].deepCopy(data_cache.getRoot(this.$data.id)); //为什么不直接返回this.value? 因为watch是异步监听的,若设置为this.value, 当setValue,再getValue,那么取的数据就不一致了
},
/**
* 对外调用,取值
* 实时取值,表单存在的值;也是getValue的别名
*/
getRootData: function getRootData() {
return utils["a" /* default */].deepCopy(data_cache.getRoot(this.$data.id));
},
/**
* 对外调用,取值
* 实时取值,用户提交所需要的值,不包括隐藏的或临时的;也就是v-model
*/
getFormValue: function getFormValue() {
return utils["a" /* default */].deepCopy(this._esFormValue); //为什么不直接返回this.value? 因为watch是异步监听的,若设置为this.value, 当setValue,再getValue,那么取的数据就不一致了
},
/**
* 对外调用,取值
*/
getGlobal: function getGlobal() {
return utils["a" /* default */].deepCopy(this.global ? this.global : {}); // 防止null情况
},
/**
* 对外调用,设置值
*/
setValue: function setValue(pathKey, value) {
if (utils["a" /* default */].isStr(pathKey)) {
pathKey = parse["a" /* default */].chainPathKey(pathKey); // 转链式,如:base["person"].name => base.person.name
//是字符串时,则值是键值,设置某个值
this.__setValueByKey(this.$data.formSchema, pathKey, value);
this.__syncValue();
} else if (utils["a" /* default */].isObj(pathKey)) {
//是object,全局设置
this.__setValue(this.$data.formSchema, pathKey);
this.__syncValue();
}
},
/**
* 清除错误信息
* @param pathKey 指定清除哪一个,若不写则全部清除
* @param clearNext 当pathKey有值时,子级及以下是否清除
*/
clearErrMsg: function clearErrMsg(pathKey, clearNext) {
if (pathKey && utils["a" /* default */].isStr(pathKey)) {
form_utils["a" /* default */].clearErrMsgByKey(this.$data.formSchema, form_utils["a" /* default */].perfectTileValue(this.$data.formSchema, pathKey), clearNext ? true : false);
} else {
form_utils["a" /* default */].clearErrMsg(this.$data.formSchema);
}
},
/*
判断某项是否处于隐藏
注:此函数有容灾处理,一定要执行到最后,不能中途退出
*/
isHidden: function isHidden(pathKey) {
var _this = this;
if (pathKey && utils["a" /* default */].isStr(pathKey)) {
pathKey = parse["a" /* default */].chainPathKey(pathKey); // 转链式,如:base["person"].name => base.person.name
} else {
throw "isHidden: 参数必须是字符串且不能为空";
}
this._esHiddenLevel++;
var MAX_TOTAL = 50;
if (this._esHiddenLevel > MAX_TOTAL) {
// 实际上不会这么深的(虽然理论上存在)
throw "解析$hidden:[" + pathKey + "]出错,系统执行$hidden超过" + MAX_TOTAL + "次,可能为死循环";
}
var curHiddenValue = false;
var rootSchema = this.$data.formSchema;
var targetSchema = form_utils["a" /* default */].getSchemaByKey(rootSchema, pathKey); // 看看最后一个是否存在
if (!targetSchema) {
if (this.$data.canConsole) {
// 说明是调试状才打印
if (!this._esWarns) {
this._esWarns = [pathKey];
this.$nextTick(function () {
if (_this._esWarns) {
console.warn("无法匹配" + _this._esWarns.join("、") + ",系统则认为其hidden为false");
_this._esWarns = null;
}
});
} else if (!this._esWarns.includes(pathKey)) {
this._esWarns.push(pathKey);
}
}
curHiddenValue = false;
} else {
var seperator = ".";
var keys = pathKey.split(seperator);
var parentPathKey = "",
tmpParentPathKey;
var reg = /\[\d+\]$/;
var arraySymbol = "[";
var key;
var len = keys.length - 1;
for (var i = 0; i <= len; i++) {
key = keys[i];
if (key.indexOf(arraySymbol) >= 0) {
key = key.replace(reg, "");
}
tmpParentPathKey = parentPathKey ? parentPathKey + seperator + key : key;
parentPathKey = parentPathKey ? parentPathKey + seperator + keys[i] : keys[i]; // 为什么写tmpParentPathKey == pathKey, 防止test.name[0]这种情况
var itemSchema = tmpParentPathKey == pathKey ? targetSchema : form_utils["a" /* default */].getSchemaByKey(rootSchema, tmpParentPathKey);
var parseSources = {
global: this.global ? this.global : {},
// 防止null情况
rootData: data_cache.getRoot(this.$data.id),
index: itemSchema.__info.index,
idxChain: itemSchema.__info.idxChain,
pathKey: itemSchema.__info.pathKey,
rootSchema: rootSchema,
isHidden: data_cache.getHiddenFunc(this.$data.id)
};
if (parse["a" /* default */].smartEsValue(itemSchema.__rawHidden, parseSources)) {
curHiddenValue = true;
break;
} else {// 父节点是显示的,继续
}
}
}
this._esHiddenLevel--; // 全部都没有隐藏
return curHiddenValue;
},
//检查整个表单
checkAll: function checkAll(showOnlyWarn) {
var validResult = this.__checkProp(this.$data.formSchema, this.$data.formSchema, showOnlyWarn);
return validResult.isValid;
},
// 对外调用,发出提交事件
submit: function submit() {
this.__submit();
},
/**
* 对外调用,取某一个tabs的索引
*/
getTabsIndex: function getTabsIndex(pathKey) {
if (pathKey && utils["a" /* default */].isStr(pathKey)) {
pathKey = parse["a" /* default */].chainPathKey(pathKey); // 转链式,如:base["person"].name => base.person.name
} else {
throw "isHidden: 参数必须是字符串且不能为空";
}
return form_utils["a" /* default */].getTabsIndex(this.$data.formSchema, pathKey);
},
/**
* 对外调用,设某一个tabs的索引
*/
setTabsIndex: function setTabsIndex(pathKey, index) {
if (pathKey && utils["a" /* default */].isStr(pathKey)) {
pathKey = parse["a" /* default */].chainPathKey(pathKey); // 转链式,如:base["person"].name => base.person.name
} else {
throw "isHidden: 参数必须是字符串且不能为空";
}
form_utils["a" /* default */].setTabsIndex(this.$data.formSchema, pathKey, index);
},
/**
* 对外调用,重置值
*/
reset: function reset(onlySchema) {
if (true !== onlySchema) {
this.setValue(this._esOriginalRootValue);
} else {
this.setValue(this._esOriginalSchemaValue);
} //去年所有的错误提示
form_utils["a" /* default */].clearErrorMsg(this.$data.formSchema);
},
/* 下划线一杠代表对内使用 */
_getType: function _getType() {
return constant["a" /* default */].UI_FORM;
},
/* 下划线一杠代表对内使用 */
_getSchema: function _getSchema() {
return this.$data.formSchema;
},
__initUi: function __initUi(schema) {
var _this2 = this;
this.$data.isInited = false;
var tmpSchema = schema_utils["a" /* default */].completeSchema(schema, this.$data.id); // 取出schema中的值,用于重置
this._esOriginalSchemaValue = utils["a" /* default */].deepCopy(form_utils["a" /* default */].getValue(tmpSchema)); //将value的值同步到schema中
this.__setValue(tmpSchema, this.value); //进行初始化
this.$data.formSchema = tmpSchema;
this.__syncValue(); // 取出第一次设置的值,用于重置
this._esOriginalRootValue = utils["a" /* default */].deepCopy(data_cache.getRoot(this.$data.id));
this.$nextTick(function () {
_this2.$data.isInited = true; // 为什么要写这个,因为开发过程中,有些组件的默认值需要转化,导致会触发checkRules, 体验不好
// this.$emit("inited", utils.deepCopy(this._esFormValue));
_this2.__execEmit("inited", [utils["a" /* default */].deepCopy(_this2._esFormValue)]);
});
},
__checkProp: function __checkProp(schema, rootSchema, showOnlyWarn) {
//idxChain要与每一form-item的idxitem是一样的,否则判断会出现不一致,要小心
var isValid = true;
var hasErrMsg = false; //是否隐藏,隐藏就不用检查有效性了
var isHidden = schema.hidden; // 省资源,不做es转
if (isHidden) {
return {
isValid: isValid,
hasErrMsg: hasErrMsg
};
}
var validResult, checkedResult, warnResult, isTabs, tabsIndex, nextPropItem, i, arrayValue, schemaList;
if (schema.properties) {
if (schema.array) {
if (schema.array.rules) {
arrayValue = form_utils["a" /* default */].getValue(schema);
warnResult = this.__execCheckWarn(schema, arrayValue, showOnlyWarn);
checkedResult = warnResult.errMsg ? warnResult.errMsg : this.__checkRules(schema, arrayValue, "");
if (checkedResult === true) {
schema.__invalidMsg = false;
} else {
schema.__invalidMsg = checkedResult;
if (!warnResult.warn || !showOnlyWarn) {
isValid = false;
} else {// 当检查只显示错误信息
}
hasErrMsg = true;
}
}
isTabs = schema.array.name == constant["a" /* default */].ARRAY_TABS ? true : false;
tabsIndex = isTabs ? schema.__tabsIndex : false;
schemaList = schema.__propSchemaList;
for (i = 0; i < schemaList.length; i++) {
nextPropItem = schemaList[i];
validResult = this.__checkProp(nextPropItem, rootSchema, showOnlyWarn);
if (isTabs) {
// 父节点是tabs
if (validResult.hasErrMsg && i !== tabsIndex) {
// 有错,tab是隐藏的
if (!nextPropItem.__hasError) {
nextPropItem.__hasError = true;
}
} else {
// 没有错或当前的tabs是我这一tab
if (nextPropItem.__hasError) {
nextPropItem.__hasError = false;
}
}
} // rules = nextPropItem.rules || {}
if (validResult.hasErrMsg) {
hasErrMsg = true;
} // if (!rules.canOnlyWarn || !showOnlyWarn) {
isValid = !isValid ? isValid : validResult.isValid; // } else {
// // 当检查只显示错误信息
// }
}
if (hasErrMsg && schema.ui && !schema.ui.showBody) {
// 有错 schema.title为null, 可能是ARRAY_TABS的item
schema.ui.showBody = true;
}
} else {
isTabs = schema.layout && schema.layout.name == constant["a" /* default */].LAYOUT_TABS ? true : false;
tabsIndex = isTabs ? schema.__tabsIndex : false;
for (var key in schema.properties) {
nextPropItem = schema.properties[key];
validResult = this.__checkProp(nextPropItem, rootSchema, showOnlyWarn);
if (isTabs) {
// 父节点是tabs
if (validResult.hasErrMsg && key !== tabsIndex) {
// 有错,tab是隐藏的
if (!nextPropItem.__hasError) {
nextPropItem.__hasError = true;
}
} else {
// 没有错或当前的tabs是我这一tab
if (nextPropItem.__hasError) {
nextPropItem.__hasError = false;
}
}
} // rules = nextPropItem.rules || {}
if (validResult.hasErrMsg) {
hasErrMsg = true;
} // if (!rules.canOnlyWarn || !showOnlyWarn) {
isValid = !isValid ? isValid : validResult.isValid; // } else {
// // 当检查只显示错误信息
// }
}
if (hasErrMsg && schema.title && !schema.title.showBody) {
// 有错
schema.title.showBody = true;
}
}
} else if (schema.component) {
if (!schema.array) {
// 是叶子,但也不是数组
warnResult = this.__execCheckWarn(schema, schema.component.value, showOnlyWarn);
checkedResult = warnResult.errMsg ? warnResult.errMsg : this.__checkRules(schema, schema.component.value, "");
if (checkedResult === true) {
schema.__invalidMsg = false;
} else {
schema.__invalidMsg = checkedResult;
if (!warnResult.warn || !showOnlyWarn) {
isValid = false;
} else {// 当检查只显示错误信息
}
hasErrMsg = true;
}
} else {
// 是叶子,但也是数组
if (schema.array.rules) {
arrayValue = form_utils["a" /* default */].getValue(schema);
warnResult = this.__execCheckWarn(schema, arrayValue, showOnlyWarn);
checkedResult = warnResult.errMsg ? warnResult.errMsg : this.__checkRules(schema, arrayValue, "");
if (checkedResult === true) {
schema.__invalidMsg = false;
} else {
schema.__invalidMsg = checkedResult;
if (!warnResult.warn || !showOnlyWarn) {
isValid = false;
} else {// 当检查只显示错误信息
}
hasErrMsg = true;
}
}
isTabs = schema.array.name == constant["a" /* default */].ARRAY_TABS ? true : false;
tabsIndex = isTabs ? schema.__tabsIndex : false;
schemaList = schema.__propSchemaList;
for (i = 0; i < schemaList.length; i++) {
nextPropItem = schemaList[i];
validResult = this.__checkProp(nextPropItem, rootSchema, showOnlyWarn);
if (isTabs) {
// 父节点是tabs
if (validResult.hasErrMsg && i !== tabsIndex) {
// 有错,tab是隐藏的
if (!nextPropItem.__hasError) {
nextPropItem.__hasError = true;
}
} else {
// 没有错或当前的tabs是我这一tab
if (nextPropItem.__hasError) {
nextPropItem.__hasError = false;
}
}
} // rules = nextPropItem.rules || {}
if (validResult.hasErrMsg) {
hasErrMsg = true;
} // if (!rules.canOnlyWarn || !showOnlyWarn) {
isValid = !isValid ? isValid : validResult.isValid; // } else {
// // 当检查只显示错误信息
// }
}
}
} // parseSources = null;
// console.log('{ isValid, hasErrMsg }', { isValid, hasErrMsg })
return {
isValid: isValid,
hasErrMsg: hasErrMsg
};
},
// 发出提交事件
__submit: function __submit() {
var _this3 = this;
if (!this.$data._esLockSubmit) {
this.$data._esLockSubmit = true; // 加锁,保存只触发一次
this.$nextTick(function () {
_this3.$data._esLockSubmit = false;
if (_this3.$data.isInited) {
// this.$emit("submit", utils.deepCopy(this._esFormValue));
_this3.__execEmit("submit", [utils["a" /* default */].deepCopy(_this3._esFormValue)]);
} else {
console.warn("表单还未初始化完成,无法派发submit事件");
}
});
}
},
/*
把value赋给(同步)给某一项
*/
__setValueByKey: function __setValueByKey(schema, key, value) {
if (key && utils["a" /* default */].isStr(key)) {
form_utils["a" /* default */].setValueByKey(schema, form_utils["a" /* default */].perfectTileValue(schema, key), utils["a" /* default */].deepCopy(value));
}
},
/*
把value赋给(同步)schema
*/
__setValue: function __setValue(schema, value) {
if (utils["a" /* default */].isObj(value) && keys_default()(value).length > 0) {
//value没有值
form_utils["a" /* default */].setValue(schema, form_utils["a" /* default */].perfectTileValue(schema, utils["a" /* default */].deepCopy(value)));
}
},
/**
* 当表单组件发生改变时:处理事件,同步项
*/
_syncFormUi: function _syncFormUi(checkSchemas, eventNames, options) {
var _this4 = this;
var sourcePathKey = checkSchemas[0].__info.pathKey; // checkSchemas必有值
if (eventNames.includes(constant["a" /* default */].INPUT_EVENT)) {
// 需要同步
this.__syncValue(sourcePathKey); // 第一个就是触发源
}
if (this.isInited) {
var inputSchema = checkSchemas[0]; // 验证当前的输入框
var parseSources = {
global: this.global ? this.global : {},
// 防止null情况
rootData: data_cache.getRoot(this.$data.id),
index: inputSchema.__info.index,
idxChain: inputSchema.__info.idxChain,
pathKey: inputSchema.__info.pathKey,
rootSchema: this.$data.formSchema,
isHidden: data_cache.getHiddenFunc(this.$data.id)
}; // 为什么要写这个,因为开发过程中,有些组件的默认值需要转化,导致会触发checkRules, 体验不好
var checkedResult = this.__checkRules(inputSchema, options.value, eventNames, parseSources);
if (checkedResult === true) {
inputSchema.__invalidMsg = false;
} else if (checkedResult !== false) {
// 字符串,错误
inputSchema.__invalidMsg = checkedResult;
} else {} // 为false, 不是目标事件,不用理会
// 取出所有需要执行的事件
var handlers = [];
var actions = inputSchema.array ? inputSchema.array.actions : inputSchema.component.actions;
if (actions) {
actions.forEach(function (action) {
if (utils["a" /* default */].isInter(action.trigger, eventNames)) {
handlers.push(action.handler);
}
});
}
if (handlers.length > 0 || eventNames.includes(constant["a" /* default */].INPUT_EVENT)) {
// 这个可以记录是什么导致表单改变
if (handlers.length > 0) {
var infoData = assign_default()({
instance: this
}, options);
handlers.forEach(function (handler) {
handler.call(_this4, infoData);
});
infoData = null;
}
if (eventNames.includes(constant["a" /* default */].INPUT_EVENT)) {
// this.$emit(
// "change",
// utils.deepCopy(this._esFormValue),
// sourcePathKey
// );
this.__execEmit("change", [utils["a" /* default */].deepCopy(this._esFormValue), sourcePathKey]);
}
}
/* 释放内存 */
checkSchemas = null;
eventNames = undefined;
options = null;
handlers = null;
}
},
/**
* 执行事件:一般用于非组件表单,只是执行事件
*/
_handleEvents: function _handleEvents(handlers, options) {
var _this5 = this;
var infoData = assign_default()({
instance: this
}, options);
handlers.forEach(function (handler) {
handler.call(_this5, infoData);
});
infoData = null;
},
_toggleUi: function _toggleUi(type, data) {
switch (type) {
case "tabs":
// tabs头部触发 data: {key, index}
form_utils["a" /* default */].setTabsIndex(this.$data.formSchema, data.key, data.index); // 更改目标的tabs的索引
break;
case "toggle":
// properies 隐藏或打开触发 data: {key}
form_utils["a" /* default */].togglePropBody(this.$data.formSchema, data.key); // 切换隐藏/打开
break;
default:
break;
}
},
__syncValue: function __syncValue(sourcePathKey) {
// 不单只是执行actions
var rootValue = form_utils["a" /* default */].getValue(this.$data.formSchema);
data_cache.setRoot(this.$data.id, rootValue);
var baseParseSources = {
global: this.global ? this.global : {},
// 防止null情况
rootData: rootValue,
rootSchema: this.$data.formSchema,
isHidden: data_cache.getHiddenFunc(this.$data.id)
};
form_utils["a" /* default */].analyzeUiProps(this.$data.formSchema, baseParseSources);
var formValue = form_utils["a" /* default */].getFormValue(this.$data.formSchema, baseParseSources); // 缓存,以便多次调用
this._esFormValue = formValue; // this.$emit(
// constant.INPUT_EVENT,
// utils.deepCopy(formValue),
// sourcePathKey ? sourcePathKey : false
// );
this.__execEmit(constant["a" /* default */].INPUT_EVENT, [utils["a" /* default */].deepCopy(formValue), sourcePathKey ? sourcePathKey : false]);
if (this.$data.canConsole) {
this.$data.csRootValue = utils["a" /* default */].deepCopy(rootValue);
this.$data.csFormValue = utils["a" /* default */].deepCopy(formValue);
}
baseParseSources = null;
formValue = null;
},
__execCheckWarn: function __execCheckWarn(schema, value, showOnlyWarn) {
var rules,
warn = false,
errMsg = '';
if (showOnlyWarn) {
if (schema.array) {
if (schema.array.rules) {
rules = schema.array.rules;
}
} else {
rules = schema.rules;
}
if (rules) {
if (utils["a" /* default */].isFunc(rules.checkWarn)) {
var newOptions = {};
newOptions.value = value;
newOptions.pathKey = schema.__info.pathKey;
newOptions.idxChain = schema.__info.idxChain;
newOptions.index = schema.__info.index;
newOptions.instance = this;
newOptions.rules = assign_default()({}, rules);
var checkResult = rules.checkWarn(newOptions);
if (utils["a" /* default */].isObj(checkResult)) {
warn = !!checkResult.warn;
errMsg = utils["a" /* default */].isStr(checkResult.errMsg) ? checkResult.errMsg.trim() : '';
} else {
warn = !!checkResult;
}
} else {
warn = rules.checkWarn;
}
}
} // console.log({warn, errMsg, showOnlyWarn})
return {
warn: warn,
errMsg: errMsg
};
},
/**
*
* @param {*} schema 这个东西已经是解析过了,不用重新解析
* @param {*} value
* @param {*} triggers 当triggers没有时,说明rules的规则无论是什么条件触发都要判断一遍
* @returns Boolean or string
* true 是需要检查的,并且正确
* false 不需要检查
* string 是需要检查的,但不正确
*/
__checkRules: function __checkRules(schema, value, triggers) {
var rules, fromArray;
if (schema.array) {
if (schema.array.rules) {
rules = schema.array.rules;
fromArray = true;
}
} else {
rules = schema.rules;
fromArray = false;
}
if (!rules) {
//没有规则
return true;
} // 是数组,检查min, max
if (!triggers && fromArray) {
// 数据提交时再检查
if (schema.array.min > 0 && schema.__propSchemaList.length < schema.array.min) {
return schema.array.minMsg;
} else if (schema.array.max > 0 && schema.__propSchemaList.length > schema.array.max) {
return schema.array.maxMsg;
}
}
var newOptions, checkResult;
var isRequired = rules.required;
if (isRequired) {
//空要检查
if (rules.emptyMethod) {
if (!newOptions) {
newOptions = {};
newOptions.value = value;
newOptions.pathKey = schema.__info.pathKey;
newOptions.idxChain = schema.__info.idxChain;
newOptions.index = schema.__info.index;
newOptions.instance = this;
}
checkResult = rules.emptyMethod.call(this, newOptions);
if (checkResult === true) {
return rules.emptyMsg;
} else if (utils["a" /* default */].isStr(checkResult)) {
return checkResult.trim() || rules.emptyMsg;
} else {// 不为空;往下走
}
} else if (form_utils["a" /* default */].isEmpty(value)) {
return rules.emptyMsg;
}
} else if (!isRequired && form_utils["a" /* default */].isEmpty(value)) {
//空时不检查,场景:当埋写邮件地址时,要么不写要么写正确
return true;
} //非空情况
var checkList = rules.checks;
var errMsg = true;
var checkFun; // var newParseSources;
if (checkList && checkList.length > 0) {
var hadChecked = false;
for (var i = 0; i < checkList.length; i++) {
var checkItem = checkList[i];
var checkTriggers = checkItem.trigger; //检查时机,默认为实时
// triggers为空时,就无条件检查(checkAll); 不为空时就条件触发
if (!triggers || utils["a" /* default */].isInter(checkTriggers, triggers)) {
checkFun = checkItem.handler;
hadChecked = true;
var result = true;
if (!newOptions) {
newOptions = {};
newOptions.value = value;
newOptions.pathKey = schema.__info.pathKey;
newOptions.idxChain = schema.__info.idxChain;
newOptions.index = schema.__info.index;
newOptions.instance = this;
}
result = checkFun.call(this, newOptions);
if (result !== true) {
if (utils["a" /* default */].isStr(result)) {
//直接返回错误信息
errMsg = result.trim();
if (!errMsg) {
errMsg = rules.errMsg;
}
} else {
//用统一的错误信息
errMsg = rules.errMsg;
}
break;
}
}
}
if (!hadChecked) {
// 当triggers为空时是不会进入这里的,所以triggers不会为空
/* 若是正在输入且之前的错误信息为空提示则删掉 */
if (triggers.includes(constant["a" /* default */].INPUT_EVENT) && schema.__invalidMsg === rules.emptyMsg) {
errMsg = true;
} else if (fromArray) {
if (schema.array.min > 0 && schema.__propSchemaList.length >= schema.array.min && schema.__invalidMsg === schema.array.minMsg) {
// 之前是最小提示有误;现在去掉
errMsg = true;
} else if (schema.array.max > 0 && schema.__propSchemaList.length <= schema.array.max && schema.__invalidMsg === schema.array.maxMsg) {
// 之前是最大提示有误;现在去掉
errMsg = true;
} else {
errMsg = false; // 保持原样
}
} else {
errMsg = false;
}
}
} else {
// 没有要验证的东西
errMsg = true;
if (triggers && fromArray) {
// 数组非提交时
if (triggers.includes(constant["a" /* default */].INPUT_EVENT) && schema.__invalidMsg === rules.emptyMsg) {
errMsg = true;
} else if (schema.array.min > 0 && schema.__propSchemaList.length >= schema.array.min && schema.__invalidMsg === schema.array.minMsg) {
// 之前是最小提示有误;现在去掉
errMsg = true;
} else if (schema.array.max > 0 && schema.__propSchemaList.length <= schema.array.max && schema.__invalidMsg === schema.array.maxMsg) {
// 之前是最大提示有误;现在去掉
errMsg = true;
} else {
errMsg = false; // 保持原样
}
}
} // newParseSources = null;
newOptions = null;
return errMsg;
},
__execEmit: function __execEmit(eventName, params) {
var _this6 = this;
var handlers = [];
var actions = this.$data.formSchema.actions;
if (actions) {
var eventNames = [eventName];
actions.forEach(function (action) {
if (utils["a" /* default */].isInter(action.trigger, eventNames)) {
handlers.push(action.handler);
}
});
}
if (handlers.length > 0) {
// schema中存在表单事件,不需要往上派发
handlers.forEach(function (handler) {
handler.apply(_this6, params);
});
} // 往上派发
params.unshift(eventName);
this.$emit.apply(this, params);
}
},
watch: {
//watch是异步监听的,而$emit("input"...)是同步的
schema: {
handler: function handler(newVal) {
if (utils["a" /* default */].isObj(newVal) && keys_default()(newVal).length > 0) {
this.__initUi(newVal);
}
},
deep: false
},
//watch是异步监听的,而$emit("input"...)是同步的
value: {
handler: function handler(newVal) {
if (stringify_default()(newVal) !== stringify_default()(this._esFormValue)) {
this.__setValue(this.$data.formSchema, newVal);
this.__syncValue();
} else {// ...
}
},
deep: false
},
global: {
/**
* 注:不是深度改变时,newVal和oldVal是一样的
*/
handler: function handler(newVal, oldVal) {
// console.log("newValue: ", newVal, oldVal, this.global);
data_cache.setGlobal(this.$data.id, newVal ? utils["a" /* default */].deepCopy(newVal) : {});
if (utils["a" /* default */].isObj(newVal)) {
// undefined也就变为{default}, 从而下入这里
if (newVal === oldVal) {
// 深度改变
// console.log("=== here...");
this.__syncValue();
} else if (stringify_default()(newVal) !== stringify_default()(oldVal)) {
// 地址改变且值不同
// console.log("!== here...");
this.__syncValue();
}
} else if (newVal === null) {
// global的值变为null,需要做兼容
// console.log("123");
this.__syncValue();
}
},
deep: true
}
},
beforeDestroy: function beforeDestroy() {
this._esOriginalRootValue = null;
this._esOriginalSchemaValue = null;
this._esFormValue = null;
data_cache.remove(this.$data.id);
}
});
// CONCATENATED MODULE: ./src/package/index.vue?vue&type=script&lang=js&
/* harmony default export */ var src_packagevue_type_script_lang_js_ = (packagevue_type_script_lang_js_);
// EXTERNAL MODULE: ./src/package/index.vue?vue&type=style&index=0&lang=scss&
var packagevue_type_style_index_0_lang_scss_ = __webpack_require__("7e62");
// CONCATENATED MODULE: ./src/package/index.vue
/* normalize component */
var package_component = Object(componentNormalizer["a" /* default */])(
src_packagevue_type_script_lang_js_,
packagevue_type_template_id_92363cec_render,
staticRenderFns,
false,
null,
null,
null
)
/* harmony default export */ var src_package = __webpack_exports__["a"] = (package_component.exports);
/***/ }),
/***/ "d263":
/***/ (function(module, exports, __webpack_require__) {
"use strict";
// B.2.3.6 String.prototype.fixed()
__webpack_require__("386b")('fixed', function (createHTML) {
return function fixed() {
return createHTML(this, 'tt', '', '');
};
});
/***/ }),
/***/ "d2c8":
/***/ (function(module, exports, __webpack_require__) {
// helper for String#{startsWith, endsWith, includes}
var isRegExp = __webpack_require__("aae3");
var defined = __webpack_require__("be13");
module.exports = function (that, searchString, NAME) {
if (isRegExp(searchString)) throw TypeError('String#' + NAME + " doesn't accept regex!");
return String(defined(that));
};
/***/ }),
/***/ "d2d5":
/***/ (function(module, exports, __webpack_require__) {
__webpack_require__("1654");
__webpack_require__("549b");
module.exports = __webpack_require__("584a").Array.from;
/***/ }),
/***/ "d3f4":
/***/ (function(module, exports) {
module.exports = function (it) {
return typeof it === 'object' ? it !== null : typeof it === 'function';
};
/***/ }),
/***/ "d53b":
/***/ (function(module, exports) {
module.exports = function (done, value) {
return { value: value, done: !!done };
};
/***/ }),
/***/ "d864":
/***/ (function(module, exports, __webpack_require__) {
// optional / simple context binding
var aFunction = __webpack_require__("79aa");
module.exports = function (fn, that, length) {
aFunction(fn);
if (that === undefined) return fn;
switch (length) {
case 1: return function (a) {
return fn.call(that, a);
};
case 2: return function (a, b) {
return fn.call(that, a, b);
};
case 3: return function (a, b, c) {
return fn.call(that, a, b, c);
};
}
return function (/* ...args */) {
return fn.apply(that, arguments);
};
};
/***/ }),
/***/ "d8e8":
/***/ (function(module, exports) {
module.exports = function (it) {
if (typeof it != 'function') throw TypeError(it + ' is not a function!');
return it;
};
/***/ }),
/***/ "d9f6":
/***/ (function(module, exports, __webpack_require__) {
var anObject = __webpack_require__("e4ae");
var IE8_DOM_DEFINE = __webpack_require__("794b");
var toPrimitive = __webpack_require__("1bc3");
var dP = Object.defineProperty;
exports.f = __webpack_require__("8e60") ? Object.defineProperty : function defineProperty(O, P, Attributes) {
anObject(O);
P = toPrimitive(P, true);
anObject(Attributes);
if (IE8_DOM_DEFINE) try {
return dP(O, P, Attributes);
} catch (e) { /* empty */ }
if ('get' in Attributes || 'set' in Attributes) throw TypeError('Accessors not supported!');
if ('value' in Attributes) O[P] = Attributes.value;
return O;
};
/***/ }),
/***/ "dbdb":
/***/ (function(module, exports, __webpack_require__) {
var core = __webpack_require__("584a");
var global = __webpack_require__("e53d");
var SHARED = '__core-js_shared__';
var store = global[SHARED] || (global[SHARED] = {});
(module.exports = function (key, value) {
return store[key] || (store[key] = value !== undefined ? value : {});
})('versions', []).push({
version: core.version,
mode: __webpack_require__("b8e3") ? 'pure' : 'global',
copyright: '© 2019 Denis Pushkarev (zloirock.ru)'
});
/***/ }),
/***/ "dc7b":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("e36a");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("cfcef70e", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "dcae":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, "@charset \"UTF-8\";.es-form{position:relative;line-height:normal}.es-form .es-required{color:#f64a4a;vertical-align:middle;margin-right:3px;font-weight:400}.es-form .es-form-unit{margin:0 2px 0 5px;-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;color:#606266;font-size:95%}.es-form .es-fade-enter-active,.es-form .es-fade-leave-active{-webkit-transition:opacity .1s ease;transition:opacity .1s ease}.es-form .es-fade-enter,.es-form .es-fade-leave-to{opacity:0}.es-btn-group{margin:0 auto;display:block;font-size:0}.es-btn,.es-btn-group{position:relative;white-space:nowrap;text-align:center}.es-btn{display:inline-block;line-height:1;cursor:pointer;background:#fff;border:1px solid #dcdfe6;border-color:#dcdfe6;color:#606266;-webkit-appearance:none;-webkit-box-sizing:border-box;box-sizing:border-box;outline:none;margin:0;-webkit-transition:.1s;transition:.1s;font-weight:500;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;padding:0 10px;font-size:13px;border-radius:4px;height:30px;z-index:1;vertical-align:middle}.es-btn:not(.disabled):hover{border-color:#c6e2ff;background:#ecf5ff;z-index:2;color:#409eff}.es-btn.disabled{color:#c0c4cc;cursor:not-allowed;background-image:none;background-color:#fff;border-color:#ebeef5;z-index:0}.es-btn-group .es-btn:not(:first-child):not(:last-child){border-radius:0}.es-btn-group .es-btn:not(:last-child){margin-right:-1px}.es-btn-group .es-btn:first-child:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0}.es-btn-group .es-btn:last-child:not(:first-child){border-top-left-radius:0;border-bottom-left-radius:0}.es-addr-btns-box{margin:0;-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto;display:block;border-radius:50%;border:1px solid #dcdfe6;width:24px;height:24px;text-align:center;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;overflow:hidden}.es-addr-btns-box:hover{background-color:#ecf5ff}.es-addr-btns-box:before{content:\"\\B7\\B7\\B7\";display:block;text-align:center;width:24px;height:16px;line-height:16px;-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto;color:#606266}.es-addr-btns-box.small{width:20px;height:20px}.es-addr-btns-box.small:before{width:20px}.es-plus-btn{margin:0 auto;padding:0;font-size:14px;width:18px;height:18px;line-height:16px;border:1px solid #dcdfe6;-webkit-box-sizing:border-box;box-sizing:border-box;border-radius:3px;text-align:center;cursor:pointer}.es-plus-btn:before{top:7px;left:3px;width:10px;height:2px}.es-plus-btn:after,.es-plus-btn:before{content:\"\";display:block;position:absolute;border-radius:3px;background:#7b808c}.es-plus-btn:after{top:3px;left:7px;width:2px;height:10px}.es-plus-btn.disabled:after,.es-plus-btn.disabled:before{background:#d5d7dc}.es-circle-delete{margin:0 auto;padding:0;width:14px;height:14px;border-radius:50%;background:#f56c6c;position:relative}.es-circle-delete:before{margin:0 auto;padding:0;content:\"\";display:block;width:8px;height:2px;position:absolute;top:6px;left:3px;background:#fff;border-radius:1px}.es-btn.disabled .es-circle-delete{background:#fab6b6}.es-normal-plus{margin:0 auto;padding:0;width:10px;height:10px;position:relative}.es-normal-plus:before{top:4px;left:0;width:10px;height:2px}.es-normal-plus:after,.es-normal-plus:before{content:\"\";display:block;position:absolute;border-radius:3px;background:#7b808c}.es-normal-plus:after{top:0;left:4px;width:2px;height:10px}.es-btn.disabled .es-normal-plus:after,.es-btn.disabled .es-normal-plus:before{background:#d5d7dc}.es-triangle-border-up.es-left{transform:rotate(-90deg);-webkit-transform:rotate(-90deg)}.es-triangle-border-up{border-color:transparent transparent #333 transparent;position:relative}.es-triangle-border-up,.es-triangle-border-up:before{margin:0;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:0 6px 6px 6px}.es-triangle-border-up:before{content:\"\";display:block;border-color:transparent transparent #fff transparent;position:absolute;top:1px;left:-6px}.es-btn.disabled .es-triangle-border-up{border-bottom-color:#c0c4cc}.es-btn:not(.disabled):hover .es-triangle-border-up:before{border-bottom-color:#ecf5ff}.es-triangle-border-down{border-color:#333 transparent transparent transparent;position:relative}.es-triangle-border-down,.es-triangle-border-down:before{margin:0;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:6px 6px 0 6px}.es-triangle-border-down:before{content:\"\";display:block;border-color:#fff transparent transparent transparent;position:absolute;top:-7px;left:-6px}.es-triangle-border-down.es-right{transform:rotate(-90deg);-webkit-transform:rotate(-90deg)}.es-btn.disabled .es-triangle-border-down{border-top-color:#c0c4cc}.es-btn:not(.disabled):hover .es-triangle-border-down:before{border-top-color:#ecf5ff}.es-form-pop-box{display:block;min-height:16px;position:absolute;top:0;left:0;margin:auto auto;color:#fff;font-size:12px;line-height:16px;z-index:1999}.es-form-pop-box .es-form-pop-content{background:#fbfbfb;border-radius:4px;border:1px solid #dcdfe6;padding:10px 10px 10px 10px;max-width:300px;color:#606266;line-height:24px;text-align:justify;font-size:14px;-webkit-box-shadow:0 2px 12px 0 rgba(0,0,0,.1);box-shadow:0 2px 12px 0 rgba(0,0,0,.1);font-size:13px;text-align:center}.es-form-pop-box .es-form-pop-content .content-box{padding:3px 3px}.es-form-pop-box .es-form-pop-content .content{display:inline-block;text-align:left}.es-form-pop-box .es-form-pop-content.es-thin{padding:5px 8px}.es-form-pop-box .es-btn-row{margin-top:5px;font-size:12px}.es-form-pop-box .es-pop-arrow-top{border-color:transparent transparent #d6d9de transparent;position:relative;position:absolute}.es-form-pop-box .es-pop-arrow-top,.es-form-pop-box .es-pop-arrow-top:before{margin:0;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:0 6px 6px 6px}.es-form-pop-box .es-pop-arrow-top:before{content:\"\";display:block;border-color:transparent transparent #fbfbfb transparent;position:absolute;top:1px;left:-6px}.es-form-pop-box .es-pop-arrow-right{border-color:transparent transparent transparent #d6d9de;position:relative;position:absolute;left:auto}.es-form-pop-box .es-pop-arrow-right,.es-form-pop-box .es-pop-arrow-right:before{margin:0;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:6px 0 6px 6px}.es-form-pop-box .es-pop-arrow-right:before{content:\"\";display:block;border-color:transparent transparent transparent #fbfbfb;position:absolute;top:-6px;left:-7px}.es-form-pop-box .es-pop-arrow-bottom{border-color:#d6d9de transparent transparent transparent;position:relative;position:absolute}.es-form-pop-box .es-pop-arrow-bottom,.es-form-pop-box .es-pop-arrow-bottom:before{margin:0;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:6px 6px 0 6px}.es-form-pop-box .es-pop-arrow-bottom:before{content:\"\";display:block;border-color:#fbfbfb transparent transparent transparent;position:absolute;top:-7px;left:-6px}.es-form-pop-box .es-pop-arrow-left{border-color:transparent #d6d9de transparent transparent;position:relative;position:absolute}.es-form-pop-box .es-pop-arrow-left,.es-form-pop-box .es-pop-arrow-left:before{margin:0;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:6px 6px 6px 0}.es-form-pop-box .es-pop-arrow-left:before{content:\"\";display:block;border-color:transparent #fbfbfb transparent transparent;position:absolute;top:-6px;left:1px}", ""]);
// exports
/***/ }),
/***/ "dcbc":
/***/ (function(module, exports, __webpack_require__) {
var redefine = __webpack_require__("2aba");
module.exports = function (target, src, safe) {
for (var key in src) redefine(target, key, src[key], safe);
return target;
};
/***/ }),
/***/ "dedd":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var core_js_modules_es6_number_constructor__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("c5f6");
/* harmony import */ var core_js_modules_es6_number_constructor__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_number_constructor__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var core_js_modules_es6_regexp_match__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("4917");
/* harmony import */ var core_js_modules_es6_regexp_match__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_regexp_match__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var core_js_modules_web_dom_iterable__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__("ac6a");
/* harmony import */ var core_js_modules_web_dom_iterable__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_iterable__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var _constant__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__("890a");
var popUtils = {
getPopUiInfo: function getPopUiInfo(popRect, iconRect, popInfo, placement) {
var uiInfo = false;
switch (placement) {
case "top":
//优化取上边
uiInfo = this.getTopCenter(popRect, iconRect, popInfo) || this.getRightCenter(popRect, iconRect, popInfo) || this.getBottomCenter(popRect, iconRect, popInfo) || this.getLeftCenter(popRect, iconRect, popInfo);
break;
case "right":
//优化取右边
uiInfo = this.getRightCenter(popRect, iconRect, popInfo) || this.getTopCenter(popRect, iconRect, popInfo) || this.getBottomCenter(popRect, iconRect, popInfo) || this.getLeftCenter(popRect, iconRect, popInfo);
break;
case "bottom":
//优化取下边
uiInfo = this.getBottomCenter(popRect, iconRect, popInfo) || this.getTopCenter(popRect, iconRect, popInfo) || this.getRightCenter(popRect, iconRect, popInfo) || this.getLeftCenter(popRect, iconRect, popInfo);
break;
case "left":
//优化取左边
uiInfo = this.getLeftCenter(popRect, iconRect, popInfo) || this.getTopCenter(popRect, iconRect, popInfo) || this.getRightCenter(popRect, iconRect, popInfo) || this.getBottomCenter(popRect, iconRect, popInfo);
break;
default:
// 先取上右下左:有constant.POINT_CENTER_CENTER,再constant.POINT_ARROW_CENTER,最后constant.POINT_ARROW_OFFSET
var topUiInfo, rightUiInfo, bottomUiInfo, leftUiInfo; //取出数据据,判断是否居中
topUiInfo = this.getTopCenter(popRect, iconRect, popInfo);
if (topUiInfo && topUiInfo.pointType == _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_CENTER_CENTER) {
return topUiInfo; // 上边居中了
}
rightUiInfo = this.getRightCenter(popRect, iconRect, popInfo);
if (rightUiInfo && rightUiInfo.pointType == _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_CENTER_CENTER) {
return rightUiInfo; // 右边居中了
}
bottomUiInfo = this.getLeftCenter(popRect, iconRect, popInfo);
if (bottomUiInfo && bottomUiInfo.pointType == _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_CENTER_CENTER) {
return bottomUiInfo; // 左边居中了
}
leftUiInfo = this.getLeftCenter(popRect, iconRect, popInfo);
if (leftUiInfo && leftUiInfo.pointType == _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_CENTER_CENTER) {
return leftUiInfo; // 左边居中了
} // 判断icon是否居中
if (topUiInfo && topUiInfo.pointType == _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_CENTER) {
return topUiInfo; // icon居中了
}
if (rightUiInfo && rightUiInfo.pointType == _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_CENTER) {
return rightUiInfo; // icon居中了
}
if (bottomUiInfo && bottomUiInfo.pointType == _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_CENTER) {
return bottomUiInfo; // icon居中了
}
if (leftUiInfo && leftUiInfo.pointType == _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_CENTER) {
return leftUiInfo; // icon居中了
} // 判断icon是否偏移
if (topUiInfo && topUiInfo.pointType == _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_OFFSET) {
return topUiInfo; // icon偏移
}
if (rightUiInfo && rightUiInfo.pointType == _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_OFFSET) {
return rightUiInfo; // icon偏移
}
if (bottomUiInfo && bottomUiInfo.pointType == _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_OFFSET) {
return bottomUiInfo; // icon偏移
}
if (leftUiInfo && leftUiInfo.pointType == _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_OFFSET) {
return leftUiInfo; // icon偏移
}
break;
}
return uiInfo;
},
getWinSize: function getWinSize() {
var winWidth = window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth; //浏览器视口宽度(不包括工具栏和滚动条)
var winHeight = window.inneHeight || document.documentElement.clientHeight || document.body.clientHeight; //浏览器视口高度(不包括工具栏和滚动条)
var scrollLeft = window.pageXOffset || document.documentElement.scrollLeft || document.body.scrollLeft || 0;
var scrollTop = window.pageYOffset || document.documentElement.scrollTop || document.body.scrollTop || 0;
return {
width: winWidth,
height: winHeight,
scrollLeft: scrollLeft,
scrollTop: scrollTop
};
},
/**
* 顶部居中
*/
getTopCenter: function getTopCenter(popRect, iconRect, popInfo) {
var winSize = this.getWinSize();
var arrowDirection = "bottom";
var arrowLeft, arrowTop;
var pointType; // 居中判断
var popTop = iconRect.top - popInfo.betweenSpace - popInfo.popArrowWH - popRect.height;
if (popTop < popInfo.viewSpace) {
return false;
}
var popLeft = iconRect.left + iconRect.width / 2 - popRect.width / 2;
if (popLeft < popInfo.viewSpace || popLeft + popRect.width + popInfo.viewSpace > winSize.width) {
if (popLeft < popInfo.viewSpace) {
// 左边不够,让pop靠左,再看看右边
popLeft = popInfo.viewSpace;
if (popLeft + popRect.width + popInfo.viewSpace > winSize.width) {
// 右边不够
return false;
}
} else {
// 右边不够,让期靠右,再看看左边
popLeft = winSize.width - popInfo.viewSpace - popRect.width;
if (popLeft < popInfo.viewSpace) {
// 左边不够
return false;
}
}
pointType = _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_CENTER;
} else {
// 可以居中
pointType = _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_CENTER_CENTER;
} // 计算箭头的位置
arrowLeft = iconRect.left + iconRect.width / 2 - popLeft - popInfo.popArrowWH;
if (arrowLeft < popInfo.popBorderRadius || arrowLeft > popRect.width - popInfo.popBorderRadius - popInfo.popArrowWH * 2) {
// 箭头在圆角区域, 调整
if (arrowLeft < popInfo.popBorderRadius) {
arrowLeft = popInfo.popBorderRadius;
} else {
arrowLeft = popRect.width - popInfo.popBorderRadius - popInfo.popArrowWH * 2;
}
var arrowPointLeft = arrowLeft + popLeft + popInfo.popArrowWH;
if (arrowPointLeft < iconRect.left || arrowPointLeft > iconRect.left + iconRect.width) {
// 指向不了icon
return false;
}
pointType = _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_OFFSET;
}
arrowTop = popRect.height;
return {
popLeft: popLeft + winSize.scrollLeft,
popTop: popTop + winSize.scrollTop,
arrowDirection: arrowDirection,
arrowLeft: arrowLeft,
arrowTop: arrowTop,
pointType: pointType
};
},
/**
* 右边居中
*/
getRightCenter: function getRightCenter(popRect, iconRect, popInfo) {
var winSize = this.getWinSize();
var arrowDirection = "left";
var arrowLeft, arrowTop;
var pointType; // 居中判断
var popTop = iconRect.top + iconRect.height / 2 - popRect.height / 2;
if (popTop < popInfo.viewSpace || popTop + popRect.height + popInfo.viewSpace > winSize.height) {
if (popTop < popInfo.viewSpace) {
// 上边不够,让pop靠上,再看看下边
popTop = popInfo.viewSpace;
if (popTop + popRect.height + popInfo.viewSpace > winSize.height) {
// 下边不够
return false;
}
} else {
// 右边不够,让期靠右,再看看左边
popTop = winSize.height - popInfo.viewSpace - popRect.height;
if (popTop < popInfo.viewSpace) {
// 左边不够
return false;
}
}
pointType = _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_CENTER;
} else {
// 可以居中
pointType = _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_CENTER_CENTER;
}
var popLeft = iconRect.left + iconRect.width + popInfo.betweenSpace + popInfo.popArrowWH;
if (popLeft + popRect.width + popInfo.viewSpace > winSize.width) {
return false;
} // 计算箭头的位置
arrowTop = iconRect.top + iconRect.height / 2 - popTop - popInfo.popArrowWH;
if (arrowTop < popInfo.popBorderRadius || arrowTop > popRect.height - popInfo.popBorderRadius - popInfo.popArrowWH * 2) {
// 箭头在圆角区域, 调整
if (arrowTop < popInfo.popBorderRadius) {
arrowTop = popInfo.popBorderRadius;
} else {
arrowTop = popRect.height - popInfo.popBorderRadius - popInfo.popArrowWH * 2;
}
var arrowPointTop = arrowTop + popTop + popInfo.popArrowWH;
if (arrowPointTop < iconRect.top || arrowPointTop > iconRect.top + iconRect.height) {
// 指向不了icon
return false;
}
pointType = _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_OFFSET;
}
arrowLeft = -popInfo.popArrowWH;
return {
popLeft: popLeft + winSize.scrollLeft,
popTop: popTop + winSize.scrollTop,
arrowDirection: arrowDirection,
arrowLeft: arrowLeft,
arrowTop: arrowTop,
pointType: pointType
};
},
/**
* 底部居中
*/
getBottomCenter: function getBottomCenter(popRect, iconRect, popInfo) {
var winSize = this.getWinSize();
var arrowDirection = "top";
var arrowLeft, arrowTop;
var pointType; // 居中判断
var popTop = iconRect.top + iconRect.height + popInfo.betweenSpace + popInfo.popArrowWH;
if (popTop + popInfo.viewSpace + popRect.height > winSize.height) {
return false;
}
var popLeft = iconRect.left + iconRect.width / 2 - popRect.width / 2;
if (popLeft < popInfo.viewSpace || popLeft + popRect.width + popInfo.viewSpace > winSize.width) {
if (popLeft < popInfo.viewSpace) {
// 左边不够,让pop靠左,再看看右边
popLeft = popInfo.viewSpace;
if (popLeft + popRect.width + popInfo.viewSpace > winSize.width) {
// 右边不够
return false;
}
} else {
// 右边不够,让期靠右,再看看左边
popLeft = winSize.width - popInfo.viewSpace - popRect.width;
if (popLeft < popInfo.viewSpace) {
// 左边不够
return false;
}
}
pointType = _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_CENTER;
} else {
// 可以居中
pointType = _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_CENTER_CENTER;
} // 计算箭头的位置
arrowLeft = iconRect.left + iconRect.width / 2 - popLeft - popInfo.popArrowWH;
if (arrowLeft < popInfo.popBorderRadius || arrowLeft > popRect.width - popInfo.popBorderRadius - popInfo.popArrowWH * 2) {
// 箭头在圆角区域, 调整
if (arrowLeft < popInfo.popBorderRadius) {
arrowLeft = popInfo.popBorderRadius;
} else {
arrowLeft = popRect.width - popInfo.popBorderRadius - popInfo.popArrowWH * 2;
}
var arrowPointLeft = arrowLeft + popLeft + popInfo.popArrowWH;
if (arrowPointLeft < iconRect.left || arrowPointLeft > iconRect.left + iconRect.width) {
// 指向不了icon
return false;
}
pointType = _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_OFFSET;
}
arrowTop = -popInfo.popArrowWH;
return {
popLeft: popLeft + winSize.scrollLeft,
popTop: popTop + winSize.scrollTop,
arrowDirection: arrowDirection,
arrowLeft: arrowLeft,
arrowTop: arrowTop,
pointType: pointType
};
},
/**
* 底部居中
*/
getLeftCenter: function getLeftCenter(popRect, iconRect, popInfo) {
var winSize = this.getWinSize();
var arrowDirection = "right";
var arrowLeft, arrowTop;
var pointType; // 居中判断
var popTop = iconRect.top + iconRect.height / 2 - popRect.height / 2;
if (popTop < popInfo.viewSpace || popTop + popRect.height + popInfo.viewSpace > winSize.height) {
if (popTop < popInfo.viewSpace) {
// 上边不够,让pop靠上,再看看下边
popTop = popInfo.viewSpace;
if (popTop + popRect.height + popInfo.viewSpace > winSize.height) {
// 下边不够
return false;
}
} else {
// 右边不够,让期靠右,再看看左边
popTop = winSize.height - popInfo.viewSpace - popRect.height;
if (popTop < popInfo.viewSpace) {
// 左边不够
return false;
}
}
pointType = _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_CENTER;
} else {
// 可以居中
pointType = _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_CENTER_CENTER;
}
var popLeft = iconRect.left - popInfo.betweenSpace - popInfo.popArrowWH - popRect.width;
if (popLeft < popInfo.viewSpace) {
return false;
} // 计算箭头的位置
arrowTop = iconRect.top + iconRect.height / 2 - popTop - popInfo.popArrowWH;
if (arrowTop < popInfo.popBorderRadius || arrowTop > popRect.height - popInfo.popBorderRadius - popInfo.popArrowWH * 2) {
// 箭头在圆角区域, 调整
if (arrowTop < popInfo.popBorderRadius) {
arrowTop = popInfo.popBorderRadius;
} else {
arrowTop = popRect.height - popInfo.popBorderRadius - popInfo.popArrowWH * 2;
}
var arrowPointTop = arrowTop + popTop + popInfo.popArrowWH;
if (arrowPointTop < iconRect.top || arrowPointTop > iconRect.top + iconRect.height) {
// 指向不了icon
return false;
}
pointType = _constant__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].POINT_ARROW_OFFSET;
}
arrowLeft = popRect.width;
return {
popLeft: popLeft + winSize.scrollLeft,
popTop: popTop + winSize.scrollTop,
arrowDirection: arrowDirection,
arrowLeft: arrowLeft,
arrowTop: arrowTop,
pointType: pointType
};
},
getMaxZIndex: function getMaxZIndex() {
var _this = this;
// var childNodes = document.body.childNodes;
var childNodes = document.all || document.querySelectorAll("*");
var maxZIndex = 0;
childNodes.forEach(function (node) {
var tmpZIndex = _this.getAttrValue(node, "z-index");
maxZIndex = Math.max(maxZIndex, tmpZIndex);
});
return maxZIndex;
},
getAttrValue: function getAttrValue(element, attrName) {
// console.log("element", element);
var value = 0;
if (element.nodeType == 1) {
var valueStr = window.getComputedStyle(element).getPropertyValue(attrName); // valueStr = "px";
// console.log("element", valueStr);
valueStr = valueStr + "";
var reg = /^\d+$/i;
var txtArr = valueStr.match(reg);
if (txtArr && txtArr[0]) {
value = Number(txtArr[0]);
}
} // console.log(valueStr, value);
return value;
}
};
/* harmony default export */ __webpack_exports__["a"] = (popUtils);
/***/ }),
/***/ "df7c":
/***/ (function(module, exports, __webpack_require__) {
/* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the
// "Software"), to deal in the Software without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Software, and to permit
// persons to whom the Software is furnished to do so, subject to the
// following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
// USE OR OTHER DEALINGS IN THE SOFTWARE.
// resolves . and .. elements in a path array with directory names there
// must be no slashes, empty elements, or device names (c:\) in the array
// (so also no leading and trailing slashes - it does not distinguish
// relative and absolute paths)
function normalizeArray(parts, allowAboveRoot) {
// if the path tries to go above the root, `up` ends up > 0
var up = 0;
for (var i = parts.length - 1; i >= 0; i--) {
var last = parts[i];
if (last === '.') {
parts.splice(i, 1);
} else if (last === '..') {
parts.splice(i, 1);
up++;
} else if (up) {
parts.splice(i, 1);
up--;
}
}
// if the path is allowed to go above the root, restore leading ..s
if (allowAboveRoot) {
for (; up--; up) {
parts.unshift('..');
}
}
return parts;
}
// Split a filename into [root, dir, basename, ext], unix version
// 'root' is just a slash, or nothing.
var splitPathRe =
/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/;
var splitPath = function(filename) {
return splitPathRe.exec(filename).slice(1);
};
// path.resolve([from ...], to)
// posix version
exports.resolve = function() {
var resolvedPath = '',
resolvedAbsolute = false;
for (var i = arguments.length - 1; i >= -1 && !resolvedAbsolute; i--) {
var path = (i >= 0) ? arguments[i] : process.cwd();
// Skip empty and invalid entries
if (typeof path !== 'string') {
throw new TypeError('Arguments to path.resolve must be strings');
} else if (!path) {
continue;
}
resolvedPath = path + '/' + resolvedPath;
resolvedAbsolute = path.charAt(0) === '/';
}
// At this point the path should be resolved to a full absolute path, but
// handle relative paths to be safe (might happen when process.cwd() fails)
// Normalize the path
resolvedPath = normalizeArray(filter(resolvedPath.split('/'), function(p) {
return !!p;
}), !resolvedAbsolute).join('/');
return ((resolvedAbsolute ? '/' : '') + resolvedPath) || '.';
};
// path.normalize(path)
// posix version
exports.normalize = function(path) {
var isAbsolute = exports.isAbsolute(path),
trailingSlash = substr(path, -1) === '/';
// Normalize the path
path = normalizeArray(filter(path.split('/'), function(p) {
return !!p;
}), !isAbsolute).join('/');
if (!path && !isAbsolute) {
path = '.';
}
if (path && trailingSlash) {
path += '/';
}
return (isAbsolute ? '/' : '') + path;
};
// posix version
exports.isAbsolute = function(path) {
return path.charAt(0) === '/';
};
// posix version
exports.join = function() {
var paths = Array.prototype.slice.call(arguments, 0);
return exports.normalize(filter(paths, function(p, index) {
if (typeof p !== 'string') {
throw new TypeError('Arguments to path.join must be strings');
}
return p;
}).join('/'));
};
// path.relative(from, to)
// posix version
exports.relative = function(from, to) {
from = exports.resolve(from).substr(1);
to = exports.resolve(to).substr(1);
function trim(arr) {
var start = 0;
for (; start < arr.length; start++) {
if (arr[start] !== '') break;
}
var end = arr.length - 1;
for (; end >= 0; end--) {
if (arr[end] !== '') break;
}
if (start > end) return [];
return arr.slice(start, end - start + 1);
}
var fromParts = trim(from.split('/'));
var toParts = trim(to.split('/'));
var length = Math.min(fromParts.length, toParts.length);
var samePartsLength = length;
for (var i = 0; i < length; i++) {
if (fromParts[i] !== toParts[i]) {
samePartsLength = i;
break;
}
}
var outputParts = [];
for (var i = samePartsLength; i < fromParts.length; i++) {
outputParts.push('..');
}
outputParts = outputParts.concat(toParts.slice(samePartsLength));
return outputParts.join('/');
};
exports.sep = '/';
exports.delimiter = ':';
exports.dirname = function(path) {
var result = splitPath(path),
root = result[0],
dir = result[1];
if (!root && !dir) {
// No dirname whatsoever
return '.';
}
if (dir) {
// It has a dirname, strip trailing slash
dir = dir.substr(0, dir.length - 1);
}
return root + dir;
};
exports.basename = function(path, ext) {
var f = splitPath(path)[2];
// TODO: make this comparison case-insensitive on windows?
if (ext && f.substr(-1 * ext.length) === ext) {
f = f.substr(0, f.length - ext.length);
}
return f;
};
exports.extname = function(path) {
return splitPath(path)[3];
};
function filter (xs, f) {
if (xs.filter) return xs.filter(f);
var res = [];
for (var i = 0; i < xs.length; i++) {
if (f(xs[i], i, xs)) res.push(xs[i]);
}
return res;
}
// String.prototype.substr - negative index don't work in IE8
var substr = 'ab'.substr(-1) === 'b'
? function (str, start, len) { return str.substr(start, len) }
: function (str, start, len) {
if (start < 0) start = str.length + start;
return str.substr(start, len);
}
;
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__("4362")))
/***/ }),
/***/ "e11e":
/***/ (function(module, exports) {
// IE 8- don't enum bug keys
module.exports = (
'constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf'
).split(',');
/***/ }),
/***/ "e1b7":
/***/ (function(module, exports, __webpack_require__) {
__webpack_require__("522e");
module.exports = __webpack_require__("584a").Object.freeze;
/***/ }),
/***/ "e36a":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, ".es-form-edit-btns .btn-list-box{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}", ""]);
// exports
/***/ }),
/***/ "e4ae":
/***/ (function(module, exports, __webpack_require__) {
var isObject = __webpack_require__("f772");
module.exports = function (it) {
if (!isObject(it)) throw TypeError(it + ' is not an object!');
return it;
};
/***/ }),
/***/ "e53d":
/***/ (function(module, exports) {
// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
var global = module.exports = typeof window != 'undefined' && window.Math == Math
? window : typeof self != 'undefined' && self.Math == Math ? self
// eslint-disable-next-line no-new-func
: Function('return this')();
if (typeof __g == 'number') __g = global; // eslint-disable-line no-undef
/***/ }),
/***/ "e5a0":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, ".es-form-item{-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto;overflow:hidden}.es-form-item .es-form-header,.es-form-item .es-title{margin:0 0 0 0;padding:3px 0 0 0;text-align:left;font-weight:400;font-size:16px;line-height:18px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.es-form-item .es-title-l1{margin:0 0 0 0;font-weight:400;font-size:24px;line-height:26px}.es-form-item .es-title-l2{margin:0 0 0 0;font-weight:400;font-size:22px;line-height:24px}.es-form-item .es-title-l3{margin:0 0 0 0;font-weight:400;font-size:20px;line-height:22px}.es-form-item .es-form-header.es-form-bg{background:#d6d7da;border-top-left-radius:4px;border-top-right-radius:4px;padding:5px 0 3px 10px}.es-form-item .es-form-header.es-form-block{padding:1px 0 1px 10px;border-left:4px solid #909399}.es-form-item .es-form-header.es-form-bg-block{background:#d6d7da;border-top-left-radius:4px;border-top-right-radius:4px;padding:5px 0 3px 10px;border-left:4px solid #909399}.es-form-item .es-form-body.es-body-border{border:1px solid #dcdfe6;border-radius:4px}.es-form-item .es-form-header+.es-body-border{margin-top:10px}.es-form-item .es-form-header.es-form-bg+.es-body-border,.es-form-item .es-form-header.es-form-bg-block+.es-body-border{margin-top:0;border-top:none;border-top-left-radius:0;border-top-right-radius:0}.es-form-item .es-form-title{-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto;text-align:left;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.es-form-item .es-title-empty{min-height:32px}.es-form-item .es-more-btn{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto;font-size:15px;line-height:18px;margin:0 10px 0 6px;cursor:pointer;text-decoration:underline;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.es-form-item .es-more-btn:hover{color:#409eff}.es-form-item .es-form-component,.es-form-item .es-form-component-list{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.es-form-item .es-form-component-left{-webkit-box-pack:start!important;-ms-flex-pack:start!important;justify-content:flex-start!important}.es-form-item .es-form-component-center{-webkit-box-pack:center!important;-ms-flex-pack:center!important;justify-content:center!important}.es-form-item .es-form-component-right{-webkit-box-pack:end!important;-ms-flex-pack:end!important;justify-content:flex-end!important}.es-form-item .es-tabs-item-label{display:-webkit-box;display:-ms-flexbox;display:flex}.es-form-item .es-form-label-box,.es-form-item .es-tabs-item-label{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.es-form-item .es-form-label-box{display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex}.es-form-item .es-form-component-full{-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto;width:auto;white-space:nowrap}.es-form-item .es-form-component-self{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto;width:auto;text-align:center;white-space:nowrap}.es-form-item .es-form-component-wrap{-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto;overflow:hidden}.es-form-item .es-form-component-wrap.es-form-wrap-full{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto;width:auto;white-space:nowrap}.es-form-item .es-form-component-wrap.es-form-wrap-self{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto;width:auto;text-align:center;white-space:nowrap}.es-form-item .es-form-error{margin:3px 0 0 5px;text-align:left;color:#f64a4a;font-size:13px}.es-form-item .es-form-desc{margin:4px 0 0 3px;text-align:left;color:#b3b5b9;font-size:13px;line-height:16px}.es-form-item .es-form-label-help{margin:0 0 0 3px}.es-form-item .es-form-help,.es-form-item .es-form-label-help{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto}.es-form-item .es-form-help{margin:0 8px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.es-form-item .es-form-help-icon{display:block;width:16px;height:16px;border-radius:50%;line-height:16px;background:#333;text-align:center;font-size:13px;color:#fff;font-style:italic;font-family:Times New Roman,Times;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}", ""]);
// exports
/***/ }),
/***/ "e692":
/***/ (function(module, exports) {
module.exports = '\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003' +
'\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF';
/***/ }),
/***/ "e6f3":
/***/ (function(module, exports, __webpack_require__) {
var has = __webpack_require__("07e3");
var toIObject = __webpack_require__("36c3");
var arrayIndexOf = __webpack_require__("5b4e")(false);
var IE_PROTO = __webpack_require__("5559")('IE_PROTO');
module.exports = function (object, names) {
var O = toIObject(object);
var i = 0;
var result = [];
var key;
for (key in O) if (key != IE_PROTO) has(O, key) && result.push(key);
// Don't enum bug & hidden keys
while (names.length > i) if (has(O, key = names[i++])) {
~arrayIndexOf(result, key) || result.push(key);
}
return result;
};
/***/ }),
/***/ "e814":
/***/ (function(module, exports, __webpack_require__) {
module.exports = __webpack_require__("b9e9");
/***/ }),
/***/ "e931":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, ".es-form-bottom-btns{position:relative}.es-form-bottom-btns .es-btn{padding-left:13px;padding-right:13px}", ""]);
// exports
/***/ }),
/***/ "ebd6":
/***/ (function(module, exports, __webpack_require__) {
// 7.3.20 SpeciesConstructor(O, defaultConstructor)
var anObject = __webpack_require__("cb7c");
var aFunction = __webpack_require__("d8e8");
var SPECIES = __webpack_require__("2b4c")('species');
module.exports = function (O, D) {
var C = anObject(O).constructor;
var S;
return C === undefined || (S = anObject(C)[SPECIES]) == undefined ? D : aFunction(S);
};
/***/ }),
/***/ "ebfd":
/***/ (function(module, exports, __webpack_require__) {
var META = __webpack_require__("62a0")('meta');
var isObject = __webpack_require__("f772");
var has = __webpack_require__("07e3");
var setDesc = __webpack_require__("d9f6").f;
var id = 0;
var isExtensible = Object.isExtensible || function () {
return true;
};
var FREEZE = !__webpack_require__("294c")(function () {
return isExtensible(Object.preventExtensions({}));
});
var setMeta = function (it) {
setDesc(it, META, { value: {
i: 'O' + ++id, // object ID
w: {} // weak collections IDs
} });
};
var fastKey = function (it, create) {
// return primitive with prefix
if (!isObject(it)) return typeof it == 'symbol' ? it : (typeof it == 'string' ? 'S' : 'P') + it;
if (!has(it, META)) {
// can't set metadata to uncaught frozen object
if (!isExtensible(it)) return 'F';
// not necessary to add metadata
if (!create) return 'E';
// add missing metadata
setMeta(it);
// return object ID
} return it[META].i;
};
var getWeak = function (it, create) {
if (!has(it, META)) {
// can't set metadata to uncaught frozen object
if (!isExtensible(it)) return true;
// not necessary to add metadata
if (!create) return false;
// add missing metadata
setMeta(it);
// return hash weak collections IDs
} return it[META].w;
};
// add metadata on freeze-family methods calling
var onFreeze = function (it) {
if (FREEZE && meta.NEED && isExtensible(it) && !has(it, META)) setMeta(it);
return it;
};
var meta = module.exports = {
KEY: META,
NEED: false,
fastKey: fastKey,
getWeak: getWeak,
onFreeze: onFreeze
};
/***/ }),
/***/ "ec12":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("8925");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("2f883485", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "ef3b":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, ".es-form-array-card{display:-webkit-box;display:-ms-flexbox;display:flex;overflow:hidden}.es-form-array-card:after,.es-form-array-card:before{content:\".\";display:block;overflow:hidden;visibility:hidden;font-size:0;line-height:0;width:0;height:0}.es-form-array-card:after{clear:both}.es-form-array-card .es-order-list-box{list-style:none;-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto;-ms-flex-wrap:wrap;flex-wrap:wrap;-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start;-webkit-box-align:start;-ms-flex-align:start;align-items:flex-start;-ms-flex-line-pack:start;align-content:flex-start}.es-form-array-card .es-order-list-box,.es-form-array-card .list-item{margin:0 0 0 0;padding:0;display:-webkit-box;display:-ms-flexbox;display:flex}.es-form-array-card .list-item{-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column}.es-form-array-card .es-array-row-head{margin:0 5px 2px 5px;line-height:1.6;text-align:left;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.es-form-array-card .es-array-row-head,.es-form-array-card .es-array-row-head .order-txt{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto}.es-form-array-card .es-array-row-head .order-full{-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto}.es-form-array-card .es-array-row-head .head-edit-wrap{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.es-form-array-card .es-array-row-body{-webkit-box-flex:1;-ms-flex:1;flex:1;-ms-flex-preferred-size:auto;flex-basis:auto}.es-form-array-card .es-card-add-box{margin:0 0 0 10px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-negative:0;flex-shrink:0;-ms-flex-preferred-size:auto;flex-basis:auto;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer}.es-form-array-card .es-addr-btns-box{margin-left:5px}", ""]);
// exports
/***/ }),
/***/ "f3a6":
/***/ (function(module, exports, __webpack_require__) {
exports = module.exports = __webpack_require__("2350")(false);
// imports
// module
exports.push([module.i, ".es-help-box{padding:0}.es-help-box,.es-help-box .es-help-icon{display:block;margin:0 auto;width:16px;height:16px}.es-help-box .es-help-icon{line-height:16px;border-radius:50%;background:#303133;color:#fff;text-align:center;font-size:12px;font-family:Times New Roman,Times,Georgia,Serif;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;outline:none}.es-help-box .es-help-icon:hover{background:#409eff}.es-help-box .help-btn{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;outline:none;text-decoration:none}.es-help-tip-box{display:block;min-height:16px;position:absolute;top:0;left:0;margin:auto auto;color:#fff;font-size:12px;line-height:16px;z-index:10001}.es-help-tip-box .es-content-box{background:#303133;border-radius:4px;border:1px solid #d6d7da;-webkit-box-sizing:border-box;box-sizing:border-box;padding:9px;text-align:left}.es-help-tip-box .help-arrow-top{border-color:transparent transparent #d6d7da transparent;position:relative;position:absolute}.es-help-tip-box .help-arrow-top,.es-help-tip-box .help-arrow-top:before{margin:0;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:0 6px 6px 6px}.es-help-tip-box .help-arrow-top:before{content:\"\";display:block;border-color:transparent transparent #303133 transparent;position:absolute;top:1px;left:-6px}.es-help-tip-box .help-arrow-right{border-color:transparent transparent transparent #d6d7da;position:relative;position:absolute;left:auto}.es-help-tip-box .help-arrow-right,.es-help-tip-box .help-arrow-right:before{margin:0;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:6px 0 6px 6px}.es-help-tip-box .help-arrow-right:before{content:\"\";display:block;border-color:transparent transparent transparent #303133;position:absolute;top:-6px;left:-7px}.es-help-tip-box .help-arrow-bottom{border-color:#d6d7da transparent transparent transparent;position:relative;position:absolute}.es-help-tip-box .help-arrow-bottom,.es-help-tip-box .help-arrow-bottom:before{margin:0;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:6px 6px 0 6px}.es-help-tip-box .help-arrow-bottom:before{content:\"\";display:block;border-color:#303133 transparent transparent transparent;position:absolute;top:-7px;left:-6px}.es-help-tip-box .help-arrow-left{border-color:transparent #d6d7da transparent transparent;position:relative;position:absolute}.es-help-tip-box .help-arrow-left,.es-help-tip-box .help-arrow-left:before{margin:0;padding:0;width:0;height:0;font-size:0;border-style:solid;border-width:6px 6px 6px 0}.es-help-tip-box .help-arrow-left:before{content:\"\";display:block;border-color:transparent #303133 transparent transparent;position:absolute;top:-6px;left:1px}.es-help-fade-enter-active,.es-help-fade-leave-active{-webkit-transition:opacity .4s ease;transition:opacity .4s ease}.es-help-fade-enter,.es-help-fade-leave-to{opacity:0}", ""]);
// exports
/***/ }),
/***/ "f410":
/***/ (function(module, exports, __webpack_require__) {
__webpack_require__("1af6");
module.exports = __webpack_require__("584a").Array.isArray;
/***/ }),
/***/ "f499":
/***/ (function(module, exports, __webpack_require__) {
module.exports = __webpack_require__("a21f");
/***/ }),
/***/ "f504":
/***/ (function(module, exports, __webpack_require__) {
// style-loader: Adds some css to the DOM by adding a <style> tag
// load the styles
var content = __webpack_require__("bfe4");
if(typeof content === 'string') content = [[module.i, content, '']];
if(content.locals) module.exports = content.locals;
// add the styles to the DOM
var add = __webpack_require__("499e").default
var update = add("c0b07dfe", content, true, {"sourceMap":false,"shadowMode":false});
/***/ }),
/***/ "f605":
/***/ (function(module, exports) {
module.exports = function (it, Constructor, name, forbiddenField) {
if (!(it instanceof Constructor) || (forbiddenField !== undefined && forbiddenField in it)) {
throw TypeError(name + ': incorrect invocation!');
} return it;
};
/***/ }),
/***/ "f751":
/***/ (function(module, exports, __webpack_require__) {
// 19.1.3.1 Object.assign(target, source)
var $export = __webpack_require__("5ca1");
$export($export.S + $export.F, 'Object', { assign: __webpack_require__("7333") });
/***/ }),
/***/ "f772":
/***/ (function(module, exports) {
module.exports = function (it) {
return typeof it === 'object' ? it !== null : typeof it === 'function';
};
/***/ }),
/***/ "fa00":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_edit_abbr_btns_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("dc7b");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_edit_abbr_btns_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_edit_abbr_btns_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_edit_abbr_btns_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "fa5b":
/***/ (function(module, exports, __webpack_require__) {
module.exports = __webpack_require__("5537")('native-function-to-string', Function.toString);
/***/ }),
/***/ "fab2":
/***/ (function(module, exports, __webpack_require__) {
var document = __webpack_require__("7726").document;
module.exports = document && document.documentElement;
/***/ }),
/***/ "fae7":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_form_item_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("cbef");
/* harmony import */ var _node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_form_item_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_form_item_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
/* unused harmony reexport * */
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_vue_style_loader_index_js_ref_8_oneOf_1_0_node_modules_css_loader_index_js_ref_8_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_8_oneOf_1_3_node_modules_sass_loader_lib_loader_js_ref_8_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_form_item_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "fb15":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
__webpack_require__.r(__webpack_exports__);
// CONCATENATED MODULE: ./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js
// This file is imported into lib/wc client bundles.
if (typeof window !== 'undefined') {
var i
if ((i = window.document.currentScript) && (i = i.src.match(/(.+\/)[^/]+\.js(\?.*)?$/))) {
__webpack_require__.p = i[1] // eslint-disable-line
}
}
// Indicate to webpack that this file can be concatenated
/* harmony default export */ var setPublicPath = (null);
// EXTERNAL MODULE: ./src/package/index.js
var src_package = __webpack_require__("bdcb");
// CONCATENATED MODULE: ./node_modules/@vue/cli-service/lib/commands/build/entry-lib.js
/* harmony default export */ var entry_lib = __webpack_exports__["default"] = (src_package["a" /* default */]);
/***/ }),
/***/ "fdef":
/***/ (function(module, exports) {
module.exports = '\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003' +
'\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF';
/***/ })
/******/ })["default"];
});