@byteluck-fe/model-driven-engine 2.7.0-alpha.23 → 2.7.0-alpha.25

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,10 +1,10 @@
1
- function _array_like_to_array(arr, len) {
1
+ function _arrayLikeToArray(arr, len) {
2
2
  if (len == null || len > arr.length) len = arr.length;
3
3
  for(var i = 0, arr2 = new Array(len); i < len; i++)arr2[i] = arr[i];
4
4
  return arr2;
5
5
  }
6
- function _array_without_holes(arr) {
7
- if (Array.isArray(arr)) return _array_like_to_array(arr);
6
+ function _arrayWithoutHoles(arr) {
7
+ if (Array.isArray(arr)) return _arrayLikeToArray(arr);
8
8
  }
9
9
  function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
10
10
  try {
@@ -20,7 +20,7 @@ function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
20
20
  Promise.resolve(value).then(_next, _throw);
21
21
  }
22
22
  }
23
- function _async_to_generator(fn) {
23
+ function _asyncToGenerator(fn) {
24
24
  return function() {
25
25
  var self = this, args = arguments;
26
26
  return new Promise(function(resolve, reject) {
@@ -35,7 +35,7 @@ function _async_to_generator(fn) {
35
35
  });
36
36
  };
37
37
  }
38
- function _class_call_check(instance, Constructor) {
38
+ function _classCallCheck(instance, Constructor) {
39
39
  if (!(instance instanceof Constructor)) {
40
40
  throw new TypeError("Cannot call a class as a function");
41
41
  }
@@ -49,12 +49,12 @@ function _defineProperties(target, props) {
49
49
  Object.defineProperty(target, descriptor.key, descriptor);
50
50
  }
51
51
  }
52
- function _create_class(Constructor, protoProps, staticProps) {
52
+ function _createClass(Constructor, protoProps, staticProps) {
53
53
  if (protoProps) _defineProperties(Constructor.prototype, protoProps);
54
54
  if (staticProps) _defineProperties(Constructor, staticProps);
55
55
  return Constructor;
56
56
  }
57
- function _define_property(obj, key, value) {
57
+ function _defineProperty(obj, key, value) {
58
58
  if (key in obj) {
59
59
  Object.defineProperty(obj, key, {
60
60
  value: value,
@@ -67,24 +67,24 @@ function _define_property(obj, key, value) {
67
67
  }
68
68
  return obj;
69
69
  }
70
- function _iterable_to_array(iter) {
70
+ function _iterableToArray(iter) {
71
71
  if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
72
72
  }
73
- function _non_iterable_spread() {
73
+ function _nonIterableSpread() {
74
74
  throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
75
75
  }
76
- function _to_consumable_array(arr) {
77
- return _array_without_holes(arr) || _iterable_to_array(arr) || _unsupported_iterable_to_array(arr) || _non_iterable_spread();
76
+ function _toConsumableArray(arr) {
77
+ return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();
78
78
  }
79
- function _unsupported_iterable_to_array(o, minLen) {
79
+ function _unsupportedIterableToArray(o, minLen) {
80
80
  if (!o) return;
81
- if (typeof o === "string") return _array_like_to_array(o, minLen);
81
+ if (typeof o === "string") return _arrayLikeToArray(o, minLen);
82
82
  var n = Object.prototype.toString.call(o).slice(8, -1);
83
83
  if (n === "Object" && o.constructor) n = o.constructor.name;
84
84
  if (n === "Map" || n === "Set") return Array.from(n);
85
- if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
85
+ if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
86
86
  }
87
- function _ts_generator(thisArg, body) {
87
+ var __generator = this && this.__generator || function(thisArg, body) {
88
88
  var f, y, t, g, _ = {
89
89
  label: 0,
90
90
  sent: function() {
@@ -178,22 +178,22 @@ function _ts_generator(thisArg, body) {
178
178
  done: true
179
179
  };
180
180
  }
181
- }
181
+ };
182
182
  import { error, logerror } from "@byteluck-fe/model-driven-shared";
183
183
  export var ActionManager = /*#__PURE__*/ function() {
184
184
  "use strict";
185
185
  function ActionManager() {
186
- _class_call_check(this, ActionManager);
187
- _define_property(this, "actionMap", new Map());
188
- _define_property(this, "buildinActions", {});
186
+ _classCallCheck(this, ActionManager);
187
+ _defineProperty(this, "actionMap", new Map());
188
+ _defineProperty(this, "buildinActions", {});
189
189
  /**
190
190
  * 执行action的时候,作为第二个参数传递给方法,可以通过外部挂载
191
- */ _define_property(this, "actionUtils", {});
191
+ */ _defineProperty(this, "actionUtils", {});
192
192
  /**
193
193
  * 用于存储es module解析出来的源码,CustomVueControlPlugin
194
- */ _define_property(this, "sources", {});
194
+ */ _defineProperty(this, "sources", {});
195
195
  }
196
- _create_class(ActionManager, [
196
+ _createClass(ActionManager, [
197
197
  {
198
198
  key: "execAction",
199
199
  value: function execAction(name, context) {
@@ -201,9 +201,9 @@ export var ActionManager = /*#__PURE__*/ function() {
201
201
  args[_key - 2] = arguments[_key];
202
202
  }
203
203
  var _this = this;
204
- return _async_to_generator(function() {
204
+ return _asyncToGenerator(function() {
205
205
  var action, _action_func, result, e;
206
- return _ts_generator(this, function(_state) {
206
+ return __generator(this, function(_state) {
207
207
  switch(_state.label){
208
208
  case 0:
209
209
  action = _this.actionMap.get(name);
@@ -225,7 +225,7 @@ export var ActionManager = /*#__PURE__*/ function() {
225
225
  (_action_func = action.func).call.apply(_action_func, [
226
226
  null,
227
227
  context
228
- ].concat(_to_consumable_array(args)))
228
+ ].concat(_toConsumableArray(args)))
229
229
  ];
230
230
  case 2:
231
231
  result = _state.sent();
@@ -265,9 +265,9 @@ export var ActionManager = /*#__PURE__*/ function() {
265
265
  }();
266
266
  var Action = function Action(id, func) {
267
267
  "use strict";
268
- _class_call_check(this, Action);
269
- _define_property(this, "func", void 0);
270
- _define_property(this, "id", "");
268
+ _classCallCheck(this, Action);
269
+ _defineProperty(this, "func", void 0);
270
+ _defineProperty(this, "id", "");
271
271
  this.id = id;
272
272
  this.func = func;
273
273
  };
@@ -12,7 +12,7 @@ function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
12
12
  Promise.resolve(value).then(_next, _throw);
13
13
  }
14
14
  }
15
- function _async_to_generator(fn) {
15
+ function _asyncToGenerator(fn) {
16
16
  return function() {
17
17
  var self = this, args = arguments;
18
18
  return new Promise(function(resolve, reject) {
@@ -27,7 +27,7 @@ function _async_to_generator(fn) {
27
27
  });
28
28
  };
29
29
  }
30
- function _class_call_check(instance, Constructor) {
30
+ function _classCallCheck(instance, Constructor) {
31
31
  if (!(instance instanceof Constructor)) {
32
32
  throw new TypeError("Cannot call a class as a function");
33
33
  }
@@ -41,12 +41,12 @@ function _defineProperties(target, props) {
41
41
  Object.defineProperty(target, descriptor.key, descriptor);
42
42
  }
43
43
  }
44
- function _create_class(Constructor, protoProps, staticProps) {
44
+ function _createClass(Constructor, protoProps, staticProps) {
45
45
  if (protoProps) _defineProperties(Constructor.prototype, protoProps);
46
46
  if (staticProps) _defineProperties(Constructor, staticProps);
47
47
  return Constructor;
48
48
  }
49
- function _define_property(obj, key, value) {
49
+ function _defineProperty(obj, key, value) {
50
50
  if (key in obj) {
51
51
  Object.defineProperty(obj, key, {
52
52
  value: value,
@@ -59,7 +59,7 @@ function _define_property(obj, key, value) {
59
59
  }
60
60
  return obj;
61
61
  }
62
- function _ts_generator(thisArg, body) {
62
+ var __generator = this && this.__generator || function(thisArg, body) {
63
63
  var f, y, t, g, _ = {
64
64
  label: 0,
65
65
  sent: function() {
@@ -153,17 +153,17 @@ function _ts_generator(thisArg, body) {
153
153
  done: true
154
154
  };
155
155
  }
156
- }
156
+ };
157
157
  import { JSONCopy, logerror } from "@byteluck-fe/model-driven-shared";
158
158
  export var DataManager = /*#__PURE__*/ function() {
159
159
  "use strict";
160
160
  function DataManager(callbackExecuter) {
161
- _class_call_check(this, DataManager);
162
- _define_property(this, "_dataStore", new Map());
163
- _define_property(this, "executer", void 0);
161
+ _classCallCheck(this, DataManager);
162
+ _defineProperty(this, "_dataStore", new Map());
163
+ _defineProperty(this, "executer", void 0);
164
164
  this.executer = callbackExecuter;
165
165
  }
166
- _create_class(DataManager, [
166
+ _createClass(DataManager, [
167
167
  {
168
168
  key: "add",
169
169
  value: function add(key, data) {
@@ -187,8 +187,8 @@ export var DataManager = /*#__PURE__*/ function() {
187
187
  key: "getRemoteData",
188
188
  value: function getRemoteData(payload) {
189
189
  var _this = this;
190
- return _async_to_generator(function() {
191
- return _ts_generator(this, function(_state) {
190
+ return _asyncToGenerator(function() {
191
+ return __generator(this, function(_state) {
192
192
  if (_this.executer === undefined) {
193
193
  logerror("未初始化executer");
194
194
  return [