@pie-element/math-templated 6.0.0-next.43 → 6.1.0-next.0
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.
- package/configure/lib/design.js +7 -9
- package/configure/lib/design.js.map +1 -1
- package/configure/lib/index.js +6 -7
- package/configure/lib/index.js.map +1 -1
- package/configure/package.json +8 -8
- package/controller/lib/index.js +5 -5
- package/controller/lib/index.js.map +1 -1
- package/controller/package.json +4 -7
- package/lib/index.js +2 -2
- package/lib/index.js.map +1 -1
- package/lib/main.js +6 -7
- package/lib/main.js.map +1 -1
- package/lib/print.js +2 -2
- package/lib/print.js.map +1 -1
- package/module/configure.js +1 -1
- package/module/controller.js +334 -1761
- package/module/element.js +1 -1
- package/module/index.html +1 -1
- package/module/manifest.json +5 -5
- package/module/print.html +1 -1
- package/module/print.js +1 -1
- package/package.json +11 -8
package/module/controller.js
CHANGED
|
@@ -1,122 +1,38 @@
|
|
|
1
1
|
import * as mv from '@pie-framework/math-validation';
|
|
2
2
|
|
|
3
|
-
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
4
|
-
|
|
5
|
-
/** Used for built-in method references. */
|
|
6
|
-
|
|
7
|
-
var objectProto$c = Object.prototype;
|
|
8
|
-
|
|
9
|
-
/**
|
|
10
|
-
* Checks if `value` is likely a prototype object.
|
|
11
|
-
*
|
|
12
|
-
* @private
|
|
13
|
-
* @param {*} value The value to check.
|
|
14
|
-
* @returns {boolean} Returns `true` if `value` is a prototype, else `false`.
|
|
15
|
-
*/
|
|
16
|
-
function isPrototype$2(value) {
|
|
17
|
-
var Ctor = value && value.constructor,
|
|
18
|
-
proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto$c;
|
|
19
|
-
|
|
20
|
-
return value === proto;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
var _isPrototype = isPrototype$2;
|
|
24
|
-
|
|
25
|
-
/**
|
|
26
|
-
* Creates a unary function that invokes `func` with its argument transformed.
|
|
27
|
-
*
|
|
28
|
-
* @private
|
|
29
|
-
* @param {Function} func The function to wrap.
|
|
30
|
-
* @param {Function} transform The argument transform.
|
|
31
|
-
* @returns {Function} Returns the new function.
|
|
32
|
-
*/
|
|
33
|
-
|
|
34
|
-
function overArg$1(func, transform) {
|
|
35
|
-
return function(arg) {
|
|
36
|
-
return func(transform(arg));
|
|
37
|
-
};
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
var _overArg = overArg$1;
|
|
41
|
-
|
|
42
|
-
var overArg = _overArg;
|
|
43
|
-
|
|
44
|
-
/* Built-in method references for those with the same name as other `lodash` methods. */
|
|
45
|
-
var nativeKeys$1 = overArg(Object.keys, Object);
|
|
46
|
-
|
|
47
|
-
var _nativeKeys = nativeKeys$1;
|
|
48
|
-
|
|
49
|
-
var isPrototype$1 = _isPrototype,
|
|
50
|
-
nativeKeys = _nativeKeys;
|
|
51
|
-
|
|
52
|
-
/** Used for built-in method references. */
|
|
53
|
-
var objectProto$b = Object.prototype;
|
|
54
|
-
|
|
55
|
-
/** Used to check objects for own properties. */
|
|
56
|
-
var hasOwnProperty$9 = objectProto$b.hasOwnProperty;
|
|
57
|
-
|
|
58
|
-
/**
|
|
59
|
-
* The base implementation of `_.keys` which doesn't treat sparse arrays as dense.
|
|
60
|
-
*
|
|
61
|
-
* @private
|
|
62
|
-
* @param {Object} object The object to query.
|
|
63
|
-
* @returns {Array} Returns the array of property names.
|
|
64
|
-
*/
|
|
65
|
-
function baseKeys$1(object) {
|
|
66
|
-
if (!isPrototype$1(object)) {
|
|
67
|
-
return nativeKeys(object);
|
|
68
|
-
}
|
|
69
|
-
var result = [];
|
|
70
|
-
for (var key in Object(object)) {
|
|
71
|
-
if (hasOwnProperty$9.call(object, key) && key != 'constructor') {
|
|
72
|
-
result.push(key);
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
return result;
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
var _baseKeys = baseKeys$1;
|
|
79
|
-
|
|
80
3
|
/** Detect free variable `global` from Node.js. */
|
|
4
|
+
var freeGlobal = typeof global == 'object' && global && global.Object === Object && global;
|
|
81
5
|
|
|
82
|
-
var freeGlobal$
|
|
83
|
-
|
|
84
|
-
var _freeGlobal$1 = freeGlobal$3;
|
|
85
|
-
|
|
86
|
-
var freeGlobal$2 = _freeGlobal$1;
|
|
6
|
+
var freeGlobal$1 = freeGlobal;
|
|
87
7
|
|
|
88
8
|
/** Detect free variable `self`. */
|
|
89
|
-
var freeSelf
|
|
9
|
+
var freeSelf = typeof self == 'object' && self && self.Object === Object && self;
|
|
90
10
|
|
|
91
11
|
/** Used as a reference to the global object. */
|
|
92
|
-
var root
|
|
93
|
-
|
|
94
|
-
var _root$1 = root$f;
|
|
12
|
+
var root = freeGlobal$1 || freeSelf || Function('return this')();
|
|
95
13
|
|
|
96
|
-
var root$
|
|
14
|
+
var root$1 = root;
|
|
97
15
|
|
|
98
16
|
/** Built-in value references. */
|
|
99
|
-
var Symbol$
|
|
17
|
+
var Symbol$1 = root$1.Symbol;
|
|
100
18
|
|
|
101
|
-
var
|
|
102
|
-
|
|
103
|
-
var Symbol$6 = _Symbol$1;
|
|
19
|
+
var Symbol$2 = Symbol$1;
|
|
104
20
|
|
|
105
21
|
/** Used for built-in method references. */
|
|
106
|
-
var objectProto$
|
|
22
|
+
var objectProto$6 = Object.prototype;
|
|
107
23
|
|
|
108
24
|
/** Used to check objects for own properties. */
|
|
109
|
-
var hasOwnProperty$
|
|
25
|
+
var hasOwnProperty$4 = objectProto$6.hasOwnProperty;
|
|
110
26
|
|
|
111
27
|
/**
|
|
112
28
|
* Used to resolve the
|
|
113
29
|
* [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
|
|
114
30
|
* of values.
|
|
115
31
|
*/
|
|
116
|
-
var nativeObjectToString$
|
|
32
|
+
var nativeObjectToString$1 = objectProto$6.toString;
|
|
117
33
|
|
|
118
34
|
/** Built-in value references. */
|
|
119
|
-
var symToStringTag$
|
|
35
|
+
var symToStringTag$1 = Symbol$2 ? Symbol$2.toStringTag : undefined;
|
|
120
36
|
|
|
121
37
|
/**
|
|
122
38
|
* A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.
|
|
@@ -125,38 +41,35 @@ var symToStringTag$3 = Symbol$6 ? Symbol$6.toStringTag : undefined;
|
|
|
125
41
|
* @param {*} value The value to query.
|
|
126
42
|
* @returns {string} Returns the raw `toStringTag`.
|
|
127
43
|
*/
|
|
128
|
-
function getRawTag
|
|
129
|
-
var isOwn = hasOwnProperty$
|
|
130
|
-
tag = value[symToStringTag$
|
|
44
|
+
function getRawTag(value) {
|
|
45
|
+
var isOwn = hasOwnProperty$4.call(value, symToStringTag$1),
|
|
46
|
+
tag = value[symToStringTag$1];
|
|
131
47
|
|
|
132
48
|
try {
|
|
133
|
-
value[symToStringTag$
|
|
49
|
+
value[symToStringTag$1] = undefined;
|
|
134
50
|
var unmasked = true;
|
|
135
51
|
} catch (e) {}
|
|
136
52
|
|
|
137
|
-
var result = nativeObjectToString$
|
|
53
|
+
var result = nativeObjectToString$1.call(value);
|
|
138
54
|
if (unmasked) {
|
|
139
55
|
if (isOwn) {
|
|
140
|
-
value[symToStringTag$
|
|
56
|
+
value[symToStringTag$1] = tag;
|
|
141
57
|
} else {
|
|
142
|
-
delete value[symToStringTag$
|
|
58
|
+
delete value[symToStringTag$1];
|
|
143
59
|
}
|
|
144
60
|
}
|
|
145
61
|
return result;
|
|
146
62
|
}
|
|
147
63
|
|
|
148
|
-
var _getRawTag$1 = getRawTag$3;
|
|
149
|
-
|
|
150
64
|
/** Used for built-in method references. */
|
|
151
|
-
|
|
152
|
-
var objectProto$9 = Object.prototype;
|
|
65
|
+
var objectProto$5 = Object.prototype;
|
|
153
66
|
|
|
154
67
|
/**
|
|
155
68
|
* Used to resolve the
|
|
156
69
|
* [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
|
|
157
70
|
* of values.
|
|
158
71
|
*/
|
|
159
|
-
var nativeObjectToString
|
|
72
|
+
var nativeObjectToString = objectProto$5.toString;
|
|
160
73
|
|
|
161
74
|
/**
|
|
162
75
|
* Converts `value` to a string using `Object.prototype.toString`.
|
|
@@ -165,22 +78,16 @@ var nativeObjectToString$2 = objectProto$9.toString;
|
|
|
165
78
|
* @param {*} value The value to convert.
|
|
166
79
|
* @returns {string} Returns the converted string.
|
|
167
80
|
*/
|
|
168
|
-
function objectToString
|
|
169
|
-
return nativeObjectToString
|
|
81
|
+
function objectToString(value) {
|
|
82
|
+
return nativeObjectToString.call(value);
|
|
170
83
|
}
|
|
171
84
|
|
|
172
|
-
var _objectToString$1 = objectToString$3;
|
|
173
|
-
|
|
174
|
-
var Symbol$5 = _Symbol$1,
|
|
175
|
-
getRawTag$2 = _getRawTag$1,
|
|
176
|
-
objectToString$2 = _objectToString$1;
|
|
177
|
-
|
|
178
85
|
/** `Object#toString` result references. */
|
|
179
|
-
var nullTag
|
|
180
|
-
undefinedTag
|
|
86
|
+
var nullTag = '[object Null]',
|
|
87
|
+
undefinedTag = '[object Undefined]';
|
|
181
88
|
|
|
182
89
|
/** Built-in value references. */
|
|
183
|
-
var symToStringTag
|
|
90
|
+
var symToStringTag = Symbol$2 ? Symbol$2.toStringTag : undefined;
|
|
184
91
|
|
|
185
92
|
/**
|
|
186
93
|
* The base implementation of `getTag` without fallbacks for buggy environments.
|
|
@@ -189,16 +96,69 @@ var symToStringTag$2 = Symbol$5 ? Symbol$5.toStringTag : undefined;
|
|
|
189
96
|
* @param {*} value The value to query.
|
|
190
97
|
* @returns {string} Returns the `toStringTag`.
|
|
191
98
|
*/
|
|
192
|
-
function baseGetTag
|
|
99
|
+
function baseGetTag(value) {
|
|
193
100
|
if (value == null) {
|
|
194
|
-
return value === undefined ? undefinedTag
|
|
101
|
+
return value === undefined ? undefinedTag : nullTag;
|
|
195
102
|
}
|
|
196
|
-
return (symToStringTag
|
|
197
|
-
? getRawTag
|
|
198
|
-
: objectToString
|
|
103
|
+
return (symToStringTag && symToStringTag in Object(value))
|
|
104
|
+
? getRawTag(value)
|
|
105
|
+
: objectToString(value);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
/**
|
|
109
|
+
* Checks if `value` is object-like. A value is object-like if it's not `null`
|
|
110
|
+
* and has a `typeof` result of "object".
|
|
111
|
+
*
|
|
112
|
+
* @static
|
|
113
|
+
* @memberOf _
|
|
114
|
+
* @since 4.0.0
|
|
115
|
+
* @category Lang
|
|
116
|
+
* @param {*} value The value to check.
|
|
117
|
+
* @returns {boolean} Returns `true` if `value` is object-like, else `false`.
|
|
118
|
+
* @example
|
|
119
|
+
*
|
|
120
|
+
* _.isObjectLike({});
|
|
121
|
+
* // => true
|
|
122
|
+
*
|
|
123
|
+
* _.isObjectLike([1, 2, 3]);
|
|
124
|
+
* // => true
|
|
125
|
+
*
|
|
126
|
+
* _.isObjectLike(_.noop);
|
|
127
|
+
* // => false
|
|
128
|
+
*
|
|
129
|
+
* _.isObjectLike(null);
|
|
130
|
+
* // => false
|
|
131
|
+
*/
|
|
132
|
+
function isObjectLike(value) {
|
|
133
|
+
return value != null && typeof value == 'object';
|
|
199
134
|
}
|
|
200
135
|
|
|
201
|
-
|
|
136
|
+
/**
|
|
137
|
+
* Checks if `value` is classified as an `Array` object.
|
|
138
|
+
*
|
|
139
|
+
* @static
|
|
140
|
+
* @memberOf _
|
|
141
|
+
* @since 0.1.0
|
|
142
|
+
* @category Lang
|
|
143
|
+
* @param {*} value The value to check.
|
|
144
|
+
* @returns {boolean} Returns `true` if `value` is an array, else `false`.
|
|
145
|
+
* @example
|
|
146
|
+
*
|
|
147
|
+
* _.isArray([1, 2, 3]);
|
|
148
|
+
* // => true
|
|
149
|
+
*
|
|
150
|
+
* _.isArray(document.body.children);
|
|
151
|
+
* // => false
|
|
152
|
+
*
|
|
153
|
+
* _.isArray('abc');
|
|
154
|
+
* // => false
|
|
155
|
+
*
|
|
156
|
+
* _.isArray(_.noop);
|
|
157
|
+
* // => false
|
|
158
|
+
*/
|
|
159
|
+
var isArray = Array.isArray;
|
|
160
|
+
|
|
161
|
+
var isArray$1 = isArray;
|
|
202
162
|
|
|
203
163
|
/**
|
|
204
164
|
* Checks if `value` is the
|
|
@@ -225,22 +185,16 @@ var _baseGetTag$1 = baseGetTag$8;
|
|
|
225
185
|
* _.isObject(null);
|
|
226
186
|
* // => false
|
|
227
187
|
*/
|
|
228
|
-
|
|
229
|
-
function isObject$5(value) {
|
|
188
|
+
function isObject(value) {
|
|
230
189
|
var type = typeof value;
|
|
231
190
|
return value != null && (type == 'object' || type == 'function');
|
|
232
191
|
}
|
|
233
192
|
|
|
234
|
-
var isObject_1$1 = isObject$5;
|
|
235
|
-
|
|
236
|
-
var baseGetTag$7 = _baseGetTag$1,
|
|
237
|
-
isObject$4 = isObject_1$1;
|
|
238
|
-
|
|
239
193
|
/** `Object#toString` result references. */
|
|
240
|
-
var asyncTag
|
|
241
|
-
funcTag$
|
|
242
|
-
genTag
|
|
243
|
-
proxyTag
|
|
194
|
+
var asyncTag = '[object AsyncFunction]',
|
|
195
|
+
funcTag$1 = '[object Function]',
|
|
196
|
+
genTag = '[object GeneratorFunction]',
|
|
197
|
+
proxyTag = '[object Proxy]';
|
|
244
198
|
|
|
245
199
|
/**
|
|
246
200
|
* Checks if `value` is classified as a `Function` object.
|
|
@@ -259,30 +213,24 @@ var asyncTag$1 = '[object AsyncFunction]',
|
|
|
259
213
|
* _.isFunction(/abc/);
|
|
260
214
|
* // => false
|
|
261
215
|
*/
|
|
262
|
-
function isFunction
|
|
263
|
-
if (!isObject
|
|
216
|
+
function isFunction(value) {
|
|
217
|
+
if (!isObject(value)) {
|
|
264
218
|
return false;
|
|
265
219
|
}
|
|
266
220
|
// The use of `Object#toString` avoids issues with the `typeof` operator
|
|
267
221
|
// in Safari 9 which returns 'object' for typed arrays and other constructors.
|
|
268
|
-
var tag = baseGetTag
|
|
269
|
-
return tag == funcTag$
|
|
222
|
+
var tag = baseGetTag(value);
|
|
223
|
+
return tag == funcTag$1 || tag == genTag || tag == asyncTag || tag == proxyTag;
|
|
270
224
|
}
|
|
271
225
|
|
|
272
|
-
var isFunction_1$1 = isFunction$4;
|
|
273
|
-
|
|
274
|
-
var root$d = _root$1;
|
|
275
|
-
|
|
276
226
|
/** Used to detect overreaching core-js shims. */
|
|
277
|
-
var coreJsData
|
|
278
|
-
|
|
279
|
-
var _coreJsData$1 = coreJsData$3;
|
|
227
|
+
var coreJsData = root$1['__core-js_shared__'];
|
|
280
228
|
|
|
281
|
-
var coreJsData$
|
|
229
|
+
var coreJsData$1 = coreJsData;
|
|
282
230
|
|
|
283
231
|
/** Used to detect methods masquerading as native. */
|
|
284
|
-
var maskSrcKey
|
|
285
|
-
var uid = /[^.]+$/.exec(coreJsData$
|
|
232
|
+
var maskSrcKey = (function() {
|
|
233
|
+
var uid = /[^.]+$/.exec(coreJsData$1 && coreJsData$1.keys && coreJsData$1.keys.IE_PROTO || '');
|
|
286
234
|
return uid ? ('Symbol(src)_1.' + uid) : '';
|
|
287
235
|
}());
|
|
288
236
|
|
|
@@ -293,18 +241,15 @@ var maskSrcKey$1 = (function() {
|
|
|
293
241
|
* @param {Function} func The function to check.
|
|
294
242
|
* @returns {boolean} Returns `true` if `func` is masked, else `false`.
|
|
295
243
|
*/
|
|
296
|
-
function isMasked
|
|
297
|
-
return !!maskSrcKey
|
|
244
|
+
function isMasked(func) {
|
|
245
|
+
return !!maskSrcKey && (maskSrcKey in func);
|
|
298
246
|
}
|
|
299
247
|
|
|
300
|
-
var _isMasked$1 = isMasked$3;
|
|
301
|
-
|
|
302
248
|
/** Used for built-in method references. */
|
|
303
|
-
|
|
304
|
-
var funcProto$3 = Function.prototype;
|
|
249
|
+
var funcProto$1 = Function.prototype;
|
|
305
250
|
|
|
306
251
|
/** Used to resolve the decompiled source of functions. */
|
|
307
|
-
var funcToString$
|
|
252
|
+
var funcToString$1 = funcProto$1.toString;
|
|
308
253
|
|
|
309
254
|
/**
|
|
310
255
|
* Converts `func` to its source code.
|
|
@@ -313,10 +258,10 @@ var funcToString$3 = funcProto$3.toString;
|
|
|
313
258
|
* @param {Function} func The function to convert.
|
|
314
259
|
* @returns {string} Returns the source code.
|
|
315
260
|
*/
|
|
316
|
-
function toSource
|
|
261
|
+
function toSource(func) {
|
|
317
262
|
if (func != null) {
|
|
318
263
|
try {
|
|
319
|
-
return funcToString$
|
|
264
|
+
return funcToString$1.call(func);
|
|
320
265
|
} catch (e) {}
|
|
321
266
|
try {
|
|
322
267
|
return (func + '');
|
|
@@ -325,35 +270,28 @@ function toSource$5(func) {
|
|
|
325
270
|
return '';
|
|
326
271
|
}
|
|
327
272
|
|
|
328
|
-
var _toSource$1 = toSource$5;
|
|
329
|
-
|
|
330
|
-
var isFunction$3 = isFunction_1$1,
|
|
331
|
-
isMasked$2 = _isMasked$1,
|
|
332
|
-
isObject$3 = isObject_1$1,
|
|
333
|
-
toSource$4 = _toSource$1;
|
|
334
|
-
|
|
335
273
|
/**
|
|
336
274
|
* Used to match `RegExp`
|
|
337
275
|
* [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).
|
|
338
276
|
*/
|
|
339
|
-
var reRegExpChar
|
|
277
|
+
var reRegExpChar = /[\\^$.*+?()[\]{}|]/g;
|
|
340
278
|
|
|
341
279
|
/** Used to detect host constructors (Safari). */
|
|
342
|
-
var reIsHostCtor
|
|
280
|
+
var reIsHostCtor = /^\[object .+?Constructor\]$/;
|
|
343
281
|
|
|
344
282
|
/** Used for built-in method references. */
|
|
345
|
-
var funcProto
|
|
346
|
-
objectProto$
|
|
283
|
+
var funcProto = Function.prototype,
|
|
284
|
+
objectProto$4 = Object.prototype;
|
|
347
285
|
|
|
348
286
|
/** Used to resolve the decompiled source of functions. */
|
|
349
|
-
var funcToString
|
|
287
|
+
var funcToString = funcProto.toString;
|
|
350
288
|
|
|
351
289
|
/** Used to check objects for own properties. */
|
|
352
|
-
var hasOwnProperty$
|
|
290
|
+
var hasOwnProperty$3 = objectProto$4.hasOwnProperty;
|
|
353
291
|
|
|
354
292
|
/** Used to detect if a method is native. */
|
|
355
|
-
var reIsNative
|
|
356
|
-
funcToString
|
|
293
|
+
var reIsNative = RegExp('^' +
|
|
294
|
+
funcToString.call(hasOwnProperty$3).replace(reRegExpChar, '\\$&')
|
|
357
295
|
.replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'
|
|
358
296
|
);
|
|
359
297
|
|
|
@@ -365,16 +303,14 @@ var reIsNative$1 = RegExp('^' +
|
|
|
365
303
|
* @returns {boolean} Returns `true` if `value` is a native function,
|
|
366
304
|
* else `false`.
|
|
367
305
|
*/
|
|
368
|
-
function baseIsNative
|
|
369
|
-
if (!isObject
|
|
306
|
+
function baseIsNative(value) {
|
|
307
|
+
if (!isObject(value) || isMasked(value)) {
|
|
370
308
|
return false;
|
|
371
309
|
}
|
|
372
|
-
var pattern = isFunction
|
|
373
|
-
return pattern.test(toSource
|
|
310
|
+
var pattern = isFunction(value) ? reIsNative : reIsHostCtor;
|
|
311
|
+
return pattern.test(toSource(value));
|
|
374
312
|
}
|
|
375
313
|
|
|
376
|
-
var _baseIsNative$1 = baseIsNative$3;
|
|
377
|
-
|
|
378
314
|
/**
|
|
379
315
|
* Gets the value at `key` of `object`.
|
|
380
316
|
*
|
|
@@ -383,16 +319,10 @@ var _baseIsNative$1 = baseIsNative$3;
|
|
|
383
319
|
* @param {string} key The key of the property to get.
|
|
384
320
|
* @returns {*} Returns the property value.
|
|
385
321
|
*/
|
|
386
|
-
|
|
387
|
-
function getValue$3(object, key) {
|
|
322
|
+
function getValue(object, key) {
|
|
388
323
|
return object == null ? undefined : object[key];
|
|
389
324
|
}
|
|
390
325
|
|
|
391
|
-
var _getValue$1 = getValue$3;
|
|
392
|
-
|
|
393
|
-
var baseIsNative$2 = _baseIsNative$1,
|
|
394
|
-
getValue$2 = _getValue$1;
|
|
395
|
-
|
|
396
326
|
/**
|
|
397
327
|
* Gets the native function at `key` of `object`.
|
|
398
328
|
*
|
|
@@ -401,173 +331,118 @@ var baseIsNative$2 = _baseIsNative$1,
|
|
|
401
331
|
* @param {string} key The key of the method to get.
|
|
402
332
|
* @returns {*} Returns the function if it's native, else `undefined`.
|
|
403
333
|
*/
|
|
404
|
-
function getNative
|
|
405
|
-
var value = getValue
|
|
406
|
-
return baseIsNative
|
|
334
|
+
function getNative(object, key) {
|
|
335
|
+
var value = getValue(object, key);
|
|
336
|
+
return baseIsNative(value) ? value : undefined;
|
|
407
337
|
}
|
|
408
338
|
|
|
409
|
-
var _getNative$1 = getNative$c;
|
|
410
|
-
|
|
411
|
-
var getNative$b = _getNative$1,
|
|
412
|
-
root$c = _root$1;
|
|
413
|
-
|
|
414
|
-
/* Built-in method references that are verified to be native. */
|
|
415
|
-
var DataView$3 = getNative$b(root$c, 'DataView');
|
|
416
|
-
|
|
417
|
-
var _DataView$1 = DataView$3;
|
|
418
|
-
|
|
419
|
-
var getNative$a = _getNative$1,
|
|
420
|
-
root$b = _root$1;
|
|
421
|
-
|
|
422
|
-
/* Built-in method references that are verified to be native. */
|
|
423
|
-
var Map$5 = getNative$a(root$b, 'Map');
|
|
424
|
-
|
|
425
|
-
var _Map$1 = Map$5;
|
|
426
|
-
|
|
427
|
-
var getNative$9 = _getNative$1,
|
|
428
|
-
root$a = _root$1;
|
|
429
|
-
|
|
430
|
-
/* Built-in method references that are verified to be native. */
|
|
431
|
-
var Promise$4 = getNative$9(root$a, 'Promise');
|
|
432
|
-
|
|
433
|
-
var _Promise$1 = Promise$4;
|
|
434
|
-
|
|
435
|
-
var getNative$8 = _getNative$1,
|
|
436
|
-
root$9 = _root$1;
|
|
437
|
-
|
|
438
|
-
/* Built-in method references that are verified to be native. */
|
|
439
|
-
var Set$3 = getNative$8(root$9, 'Set');
|
|
440
|
-
|
|
441
|
-
var _Set$1 = Set$3;
|
|
442
|
-
|
|
443
|
-
var getNative$7 = _getNative$1,
|
|
444
|
-
root$8 = _root$1;
|
|
445
|
-
|
|
446
339
|
/* Built-in method references that are verified to be native. */
|
|
447
|
-
var WeakMap
|
|
448
|
-
|
|
449
|
-
var _WeakMap$1 = WeakMap$3;
|
|
450
|
-
|
|
451
|
-
var DataView$2 = _DataView$1,
|
|
452
|
-
Map$4 = _Map$1,
|
|
453
|
-
Promise$3 = _Promise$1,
|
|
454
|
-
Set$2 = _Set$1,
|
|
455
|
-
WeakMap$2 = _WeakMap$1,
|
|
456
|
-
baseGetTag$6 = _baseGetTag$1,
|
|
457
|
-
toSource$3 = _toSource$1;
|
|
458
|
-
|
|
459
|
-
/** `Object#toString` result references. */
|
|
460
|
-
var mapTag$3 = '[object Map]',
|
|
461
|
-
objectTag$2 = '[object Object]',
|
|
462
|
-
promiseTag$1 = '[object Promise]',
|
|
463
|
-
setTag$3 = '[object Set]',
|
|
464
|
-
weakMapTag$2 = '[object WeakMap]';
|
|
340
|
+
var WeakMap = getNative(root$1, 'WeakMap');
|
|
465
341
|
|
|
466
|
-
var
|
|
342
|
+
var WeakMap$1 = WeakMap;
|
|
467
343
|
|
|
468
|
-
/** Used
|
|
469
|
-
var
|
|
470
|
-
mapCtorString$1 = toSource$3(Map$4),
|
|
471
|
-
promiseCtorString$1 = toSource$3(Promise$3),
|
|
472
|
-
setCtorString$1 = toSource$3(Set$2),
|
|
473
|
-
weakMapCtorString$1 = toSource$3(WeakMap$2);
|
|
344
|
+
/** Used as references for various `Number` constants. */
|
|
345
|
+
var MAX_SAFE_INTEGER = 9007199254740991;
|
|
474
346
|
|
|
475
347
|
/**
|
|
476
|
-
*
|
|
348
|
+
* Checks if `value` is a valid array-like length.
|
|
477
349
|
*
|
|
478
|
-
*
|
|
479
|
-
*
|
|
480
|
-
*
|
|
350
|
+
* **Note:** This method is loosely based on
|
|
351
|
+
* [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).
|
|
352
|
+
*
|
|
353
|
+
* @static
|
|
354
|
+
* @memberOf _
|
|
355
|
+
* @since 4.0.0
|
|
356
|
+
* @category Lang
|
|
357
|
+
* @param {*} value The value to check.
|
|
358
|
+
* @returns {boolean} Returns `true` if `value` is a valid length, else `false`.
|
|
359
|
+
* @example
|
|
360
|
+
*
|
|
361
|
+
* _.isLength(3);
|
|
362
|
+
* // => true
|
|
363
|
+
*
|
|
364
|
+
* _.isLength(Number.MIN_VALUE);
|
|
365
|
+
* // => false
|
|
366
|
+
*
|
|
367
|
+
* _.isLength(Infinity);
|
|
368
|
+
* // => false
|
|
369
|
+
*
|
|
370
|
+
* _.isLength('3');
|
|
371
|
+
* // => false
|
|
481
372
|
*/
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
if ((DataView$2 && getTag$2(new DataView$2(new ArrayBuffer(1))) != dataViewTag$2) ||
|
|
486
|
-
(Map$4 && getTag$2(new Map$4) != mapTag$3) ||
|
|
487
|
-
(Promise$3 && getTag$2(Promise$3.resolve()) != promiseTag$1) ||
|
|
488
|
-
(Set$2 && getTag$2(new Set$2) != setTag$3) ||
|
|
489
|
-
(WeakMap$2 && getTag$2(new WeakMap$2) != weakMapTag$2)) {
|
|
490
|
-
getTag$2 = function(value) {
|
|
491
|
-
var result = baseGetTag$6(value),
|
|
492
|
-
Ctor = result == objectTag$2 ? value.constructor : undefined,
|
|
493
|
-
ctorString = Ctor ? toSource$3(Ctor) : '';
|
|
494
|
-
|
|
495
|
-
if (ctorString) {
|
|
496
|
-
switch (ctorString) {
|
|
497
|
-
case dataViewCtorString$1: return dataViewTag$2;
|
|
498
|
-
case mapCtorString$1: return mapTag$3;
|
|
499
|
-
case promiseCtorString$1: return promiseTag$1;
|
|
500
|
-
case setCtorString$1: return setTag$3;
|
|
501
|
-
case weakMapCtorString$1: return weakMapTag$2;
|
|
502
|
-
}
|
|
503
|
-
}
|
|
504
|
-
return result;
|
|
505
|
-
};
|
|
373
|
+
function isLength(value) {
|
|
374
|
+
return typeof value == 'number' &&
|
|
375
|
+
value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
|
|
506
376
|
}
|
|
507
377
|
|
|
508
|
-
var _getTag = getTag$2;
|
|
509
|
-
|
|
510
378
|
/**
|
|
511
|
-
* Checks if `value` is
|
|
512
|
-
* and has a `
|
|
379
|
+
* Checks if `value` is array-like. A value is considered array-like if it's
|
|
380
|
+
* not a function and has a `value.length` that's an integer greater than or
|
|
381
|
+
* equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.
|
|
513
382
|
*
|
|
514
383
|
* @static
|
|
515
384
|
* @memberOf _
|
|
516
385
|
* @since 4.0.0
|
|
517
386
|
* @category Lang
|
|
518
387
|
* @param {*} value The value to check.
|
|
519
|
-
* @returns {boolean} Returns `true` if `value` is
|
|
388
|
+
* @returns {boolean} Returns `true` if `value` is array-like, else `false`.
|
|
520
389
|
* @example
|
|
521
390
|
*
|
|
522
|
-
* _.
|
|
391
|
+
* _.isArrayLike([1, 2, 3]);
|
|
523
392
|
* // => true
|
|
524
393
|
*
|
|
525
|
-
* _.
|
|
394
|
+
* _.isArrayLike(document.body.children);
|
|
526
395
|
* // => true
|
|
527
396
|
*
|
|
528
|
-
* _.
|
|
529
|
-
* // =>
|
|
397
|
+
* _.isArrayLike('abc');
|
|
398
|
+
* // => true
|
|
530
399
|
*
|
|
531
|
-
* _.
|
|
400
|
+
* _.isArrayLike(_.noop);
|
|
532
401
|
* // => false
|
|
533
402
|
*/
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
return value != null && typeof value == 'object';
|
|
403
|
+
function isArrayLike(value) {
|
|
404
|
+
return value != null && isLength(value.length) && !isFunction(value);
|
|
537
405
|
}
|
|
538
406
|
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
var baseGetTag$5 = _baseGetTag$1,
|
|
542
|
-
isObjectLike$5 = isObjectLike_1$1;
|
|
543
|
-
|
|
544
|
-
/** `Object#toString` result references. */
|
|
545
|
-
var argsTag$2 = '[object Arguments]';
|
|
407
|
+
/** Used for built-in method references. */
|
|
408
|
+
var objectProto$3 = Object.prototype;
|
|
546
409
|
|
|
547
410
|
/**
|
|
548
|
-
*
|
|
411
|
+
* Checks if `value` is likely a prototype object.
|
|
549
412
|
*
|
|
550
413
|
* @private
|
|
551
414
|
* @param {*} value The value to check.
|
|
552
|
-
* @returns {boolean} Returns `true` if `value` is
|
|
415
|
+
* @returns {boolean} Returns `true` if `value` is a prototype, else `false`.
|
|
553
416
|
*/
|
|
554
|
-
function
|
|
555
|
-
|
|
417
|
+
function isPrototype(value) {
|
|
418
|
+
var Ctor = value && value.constructor,
|
|
419
|
+
proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto$3;
|
|
420
|
+
|
|
421
|
+
return value === proto;
|
|
556
422
|
}
|
|
557
423
|
|
|
558
|
-
|
|
424
|
+
/** `Object#toString` result references. */
|
|
425
|
+
var argsTag$1 = '[object Arguments]';
|
|
559
426
|
|
|
560
|
-
|
|
561
|
-
|
|
427
|
+
/**
|
|
428
|
+
* The base implementation of `_.isArguments`.
|
|
429
|
+
*
|
|
430
|
+
* @private
|
|
431
|
+
* @param {*} value The value to check.
|
|
432
|
+
* @returns {boolean} Returns `true` if `value` is an `arguments` object,
|
|
433
|
+
*/
|
|
434
|
+
function baseIsArguments(value) {
|
|
435
|
+
return isObjectLike(value) && baseGetTag(value) == argsTag$1;
|
|
436
|
+
}
|
|
562
437
|
|
|
563
438
|
/** Used for built-in method references. */
|
|
564
|
-
var objectProto$
|
|
439
|
+
var objectProto$2 = Object.prototype;
|
|
565
440
|
|
|
566
441
|
/** Used to check objects for own properties. */
|
|
567
|
-
var hasOwnProperty$
|
|
442
|
+
var hasOwnProperty$2 = objectProto$2.hasOwnProperty;
|
|
568
443
|
|
|
569
444
|
/** Built-in value references. */
|
|
570
|
-
var propertyIsEnumerable
|
|
445
|
+
var propertyIsEnumerable = objectProto$2.propertyIsEnumerable;
|
|
571
446
|
|
|
572
447
|
/**
|
|
573
448
|
* Checks if `value` is likely an `arguments` object.
|
|
@@ -587,113 +462,12 @@ var propertyIsEnumerable$1 = objectProto$7.propertyIsEnumerable;
|
|
|
587
462
|
* _.isArguments([1, 2, 3]);
|
|
588
463
|
* // => false
|
|
589
464
|
*/
|
|
590
|
-
var isArguments
|
|
591
|
-
return isObjectLike
|
|
592
|
-
!propertyIsEnumerable
|
|
465
|
+
var isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {
|
|
466
|
+
return isObjectLike(value) && hasOwnProperty$2.call(value, 'callee') &&
|
|
467
|
+
!propertyIsEnumerable.call(value, 'callee');
|
|
593
468
|
};
|
|
594
469
|
|
|
595
|
-
var
|
|
596
|
-
|
|
597
|
-
/**
|
|
598
|
-
* Checks if `value` is classified as an `Array` object.
|
|
599
|
-
*
|
|
600
|
-
* @static
|
|
601
|
-
* @memberOf _
|
|
602
|
-
* @since 0.1.0
|
|
603
|
-
* @category Lang
|
|
604
|
-
* @param {*} value The value to check.
|
|
605
|
-
* @returns {boolean} Returns `true` if `value` is an array, else `false`.
|
|
606
|
-
* @example
|
|
607
|
-
*
|
|
608
|
-
* _.isArray([1, 2, 3]);
|
|
609
|
-
* // => true
|
|
610
|
-
*
|
|
611
|
-
* _.isArray(document.body.children);
|
|
612
|
-
* // => false
|
|
613
|
-
*
|
|
614
|
-
* _.isArray('abc');
|
|
615
|
-
* // => false
|
|
616
|
-
*
|
|
617
|
-
* _.isArray(_.noop);
|
|
618
|
-
* // => false
|
|
619
|
-
*/
|
|
620
|
-
|
|
621
|
-
var isArray$1 = Array.isArray;
|
|
622
|
-
|
|
623
|
-
var isArray_1 = isArray$1;
|
|
624
|
-
|
|
625
|
-
/** Used as references for various `Number` constants. */
|
|
626
|
-
|
|
627
|
-
var MAX_SAFE_INTEGER = 9007199254740991;
|
|
628
|
-
|
|
629
|
-
/**
|
|
630
|
-
* Checks if `value` is a valid array-like length.
|
|
631
|
-
*
|
|
632
|
-
* **Note:** This method is loosely based on
|
|
633
|
-
* [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).
|
|
634
|
-
*
|
|
635
|
-
* @static
|
|
636
|
-
* @memberOf _
|
|
637
|
-
* @since 4.0.0
|
|
638
|
-
* @category Lang
|
|
639
|
-
* @param {*} value The value to check.
|
|
640
|
-
* @returns {boolean} Returns `true` if `value` is a valid length, else `false`.
|
|
641
|
-
* @example
|
|
642
|
-
*
|
|
643
|
-
* _.isLength(3);
|
|
644
|
-
* // => true
|
|
645
|
-
*
|
|
646
|
-
* _.isLength(Number.MIN_VALUE);
|
|
647
|
-
* // => false
|
|
648
|
-
*
|
|
649
|
-
* _.isLength(Infinity);
|
|
650
|
-
* // => false
|
|
651
|
-
*
|
|
652
|
-
* _.isLength('3');
|
|
653
|
-
* // => false
|
|
654
|
-
*/
|
|
655
|
-
function isLength$2(value) {
|
|
656
|
-
return typeof value == 'number' &&
|
|
657
|
-
value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
|
|
658
|
-
}
|
|
659
|
-
|
|
660
|
-
var isLength_1 = isLength$2;
|
|
661
|
-
|
|
662
|
-
var isFunction$2 = isFunction_1$1,
|
|
663
|
-
isLength$1 = isLength_1;
|
|
664
|
-
|
|
665
|
-
/**
|
|
666
|
-
* Checks if `value` is array-like. A value is considered array-like if it's
|
|
667
|
-
* not a function and has a `value.length` that's an integer greater than or
|
|
668
|
-
* equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.
|
|
669
|
-
*
|
|
670
|
-
* @static
|
|
671
|
-
* @memberOf _
|
|
672
|
-
* @since 4.0.0
|
|
673
|
-
* @category Lang
|
|
674
|
-
* @param {*} value The value to check.
|
|
675
|
-
* @returns {boolean} Returns `true` if `value` is array-like, else `false`.
|
|
676
|
-
* @example
|
|
677
|
-
*
|
|
678
|
-
* _.isArrayLike([1, 2, 3]);
|
|
679
|
-
* // => true
|
|
680
|
-
*
|
|
681
|
-
* _.isArrayLike(document.body.children);
|
|
682
|
-
* // => true
|
|
683
|
-
*
|
|
684
|
-
* _.isArrayLike('abc');
|
|
685
|
-
* // => true
|
|
686
|
-
*
|
|
687
|
-
* _.isArrayLike(_.noop);
|
|
688
|
-
* // => false
|
|
689
|
-
*/
|
|
690
|
-
function isArrayLike$1(value) {
|
|
691
|
-
return value != null && isLength$1(value.length) && !isFunction$2(value);
|
|
692
|
-
}
|
|
693
|
-
|
|
694
|
-
var isArrayLike_1 = isArrayLike$1;
|
|
695
|
-
|
|
696
|
-
var isBuffer$2 = {exports: {}};
|
|
470
|
+
var isArguments$1 = isArguments;
|
|
697
471
|
|
|
698
472
|
/**
|
|
699
473
|
* This method returns `false`.
|
|
@@ -708,28 +482,21 @@ var isBuffer$2 = {exports: {}};
|
|
|
708
482
|
* _.times(2, _.stubFalse);
|
|
709
483
|
* // => [false, false]
|
|
710
484
|
*/
|
|
711
|
-
|
|
712
|
-
function stubFalse$1() {
|
|
485
|
+
function stubFalse() {
|
|
713
486
|
return false;
|
|
714
487
|
}
|
|
715
488
|
|
|
716
|
-
var stubFalse_1$1 = stubFalse$1;
|
|
717
|
-
|
|
718
|
-
(function (module, exports) {
|
|
719
|
-
var root = _root$1,
|
|
720
|
-
stubFalse = stubFalse_1$1;
|
|
721
|
-
|
|
722
489
|
/** Detect free variable `exports`. */
|
|
723
|
-
var freeExports = exports && !exports.nodeType && exports;
|
|
490
|
+
var freeExports$1 = typeof exports == 'object' && exports && !exports.nodeType && exports;
|
|
724
491
|
|
|
725
492
|
/** Detect free variable `module`. */
|
|
726
|
-
var freeModule = freeExports &&
|
|
493
|
+
var freeModule$1 = freeExports$1 && typeof module == 'object' && module && !module.nodeType && module;
|
|
727
494
|
|
|
728
495
|
/** Detect the popular CommonJS extension `module.exports`. */
|
|
729
|
-
var moduleExports = freeModule && freeModule.exports === freeExports;
|
|
496
|
+
var moduleExports$1 = freeModule$1 && freeModule$1.exports === freeExports$1;
|
|
730
497
|
|
|
731
498
|
/** Built-in value references. */
|
|
732
|
-
var Buffer = moduleExports ? root.Buffer : undefined;
|
|
499
|
+
var Buffer = moduleExports$1 ? root$1.Buffer : undefined;
|
|
733
500
|
|
|
734
501
|
/* Built-in method references for those with the same name as other `lodash` methods. */
|
|
735
502
|
var nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;
|
|
@@ -753,20 +520,15 @@ var nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;
|
|
|
753
520
|
*/
|
|
754
521
|
var isBuffer = nativeIsBuffer || stubFalse;
|
|
755
522
|
|
|
756
|
-
|
|
757
|
-
}(isBuffer$2, isBuffer$2.exports));
|
|
758
|
-
|
|
759
|
-
var baseGetTag$4 = _baseGetTag$1,
|
|
760
|
-
isLength = isLength_1,
|
|
761
|
-
isObjectLike$3 = isObjectLike_1$1;
|
|
523
|
+
var isBuffer$1 = isBuffer;
|
|
762
524
|
|
|
763
525
|
/** `Object#toString` result references. */
|
|
764
|
-
var argsTag
|
|
526
|
+
var argsTag = '[object Arguments]',
|
|
765
527
|
arrayTag = '[object Array]',
|
|
766
528
|
boolTag = '[object Boolean]',
|
|
767
529
|
dateTag = '[object Date]',
|
|
768
530
|
errorTag = '[object Error]',
|
|
769
|
-
funcTag
|
|
531
|
+
funcTag = '[object Function]',
|
|
770
532
|
mapTag$2 = '[object Map]',
|
|
771
533
|
numberTag = '[object Number]',
|
|
772
534
|
objectTag$1 = '[object Object]',
|
|
@@ -794,10 +556,10 @@ typedArrayTags[int8Tag] = typedArrayTags[int16Tag] =
|
|
|
794
556
|
typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =
|
|
795
557
|
typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =
|
|
796
558
|
typedArrayTags[uint32Tag] = true;
|
|
797
|
-
typedArrayTags[argsTag
|
|
559
|
+
typedArrayTags[argsTag] = typedArrayTags[arrayTag] =
|
|
798
560
|
typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =
|
|
799
561
|
typedArrayTags[dataViewTag$1] = typedArrayTags[dateTag] =
|
|
800
|
-
typedArrayTags[errorTag] = typedArrayTags[funcTag
|
|
562
|
+
typedArrayTags[errorTag] = typedArrayTags[funcTag] =
|
|
801
563
|
typedArrayTags[mapTag$2] = typedArrayTags[numberTag] =
|
|
802
564
|
typedArrayTags[objectTag$1] = typedArrayTags[regexpTag] =
|
|
803
565
|
typedArrayTags[setTag$2] = typedArrayTags[stringTag] =
|
|
@@ -810,13 +572,11 @@ typedArrayTags[weakMapTag$1] = false;
|
|
|
810
572
|
* @param {*} value The value to check.
|
|
811
573
|
* @returns {boolean} Returns `true` if `value` is a typed array, else `false`.
|
|
812
574
|
*/
|
|
813
|
-
function baseIsTypedArray
|
|
814
|
-
return isObjectLike
|
|
815
|
-
isLength(value.length) && !!typedArrayTags[baseGetTag
|
|
575
|
+
function baseIsTypedArray(value) {
|
|
576
|
+
return isObjectLike(value) &&
|
|
577
|
+
isLength(value.length) && !!typedArrayTags[baseGetTag(value)];
|
|
816
578
|
}
|
|
817
579
|
|
|
818
|
-
var _baseIsTypedArray = baseIsTypedArray$1;
|
|
819
|
-
|
|
820
580
|
/**
|
|
821
581
|
* The base implementation of `_.unary` without support for storing metadata.
|
|
822
582
|
*
|
|
@@ -824,31 +584,23 @@ var _baseIsTypedArray = baseIsTypedArray$1;
|
|
|
824
584
|
* @param {Function} func The function to cap arguments for.
|
|
825
585
|
* @returns {Function} Returns the new capped function.
|
|
826
586
|
*/
|
|
827
|
-
|
|
828
|
-
function baseUnary$1(func) {
|
|
587
|
+
function baseUnary(func) {
|
|
829
588
|
return function(value) {
|
|
830
589
|
return func(value);
|
|
831
590
|
};
|
|
832
591
|
}
|
|
833
592
|
|
|
834
|
-
var _baseUnary = baseUnary$1;
|
|
835
|
-
|
|
836
|
-
var _nodeUtil$1 = {exports: {}};
|
|
837
|
-
|
|
838
|
-
(function (module, exports) {
|
|
839
|
-
var freeGlobal = _freeGlobal$1;
|
|
840
|
-
|
|
841
593
|
/** Detect free variable `exports`. */
|
|
842
|
-
var freeExports = exports && !exports.nodeType && exports;
|
|
594
|
+
var freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;
|
|
843
595
|
|
|
844
596
|
/** Detect free variable `module`. */
|
|
845
|
-
var freeModule = freeExports &&
|
|
597
|
+
var freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;
|
|
846
598
|
|
|
847
599
|
/** Detect the popular CommonJS extension `module.exports`. */
|
|
848
600
|
var moduleExports = freeModule && freeModule.exports === freeExports;
|
|
849
601
|
|
|
850
602
|
/** Detect free variable `process` from Node.js. */
|
|
851
|
-
var freeProcess = moduleExports && freeGlobal.process;
|
|
603
|
+
var freeProcess = moduleExports && freeGlobal$1.process;
|
|
852
604
|
|
|
853
605
|
/** Used to access faster Node.js helpers. */
|
|
854
606
|
var nodeUtil = (function() {
|
|
@@ -865,12 +617,7 @@ var nodeUtil = (function() {
|
|
|
865
617
|
} catch (e) {}
|
|
866
618
|
}());
|
|
867
619
|
|
|
868
|
-
|
|
869
|
-
}(_nodeUtil$1, _nodeUtil$1.exports));
|
|
870
|
-
|
|
871
|
-
var baseIsTypedArray = _baseIsTypedArray,
|
|
872
|
-
baseUnary = _baseUnary,
|
|
873
|
-
nodeUtil$1 = _nodeUtil$1.exports;
|
|
620
|
+
var nodeUtil$1 = nodeUtil;
|
|
874
621
|
|
|
875
622
|
/* Node.js helper references. */
|
|
876
623
|
var nodeIsTypedArray = nodeUtil$1 && nodeUtil$1.isTypedArray;
|
|
@@ -892,28 +639,135 @@ var nodeIsTypedArray = nodeUtil$1 && nodeUtil$1.isTypedArray;
|
|
|
892
639
|
* _.isTypedArray([]);
|
|
893
640
|
* // => false
|
|
894
641
|
*/
|
|
895
|
-
var isTypedArray
|
|
642
|
+
var isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;
|
|
643
|
+
|
|
644
|
+
var isTypedArray$1 = isTypedArray;
|
|
645
|
+
|
|
646
|
+
/**
|
|
647
|
+
* Creates a unary function that invokes `func` with its argument transformed.
|
|
648
|
+
*
|
|
649
|
+
* @private
|
|
650
|
+
* @param {Function} func The function to wrap.
|
|
651
|
+
* @param {Function} transform The argument transform.
|
|
652
|
+
* @returns {Function} Returns the new function.
|
|
653
|
+
*/
|
|
654
|
+
function overArg(func, transform) {
|
|
655
|
+
return function(arg) {
|
|
656
|
+
return func(transform(arg));
|
|
657
|
+
};
|
|
658
|
+
}
|
|
659
|
+
|
|
660
|
+
/* Built-in method references for those with the same name as other `lodash` methods. */
|
|
661
|
+
var nativeKeys = overArg(Object.keys, Object);
|
|
662
|
+
|
|
663
|
+
var nativeKeys$1 = nativeKeys;
|
|
664
|
+
|
|
665
|
+
/** Used for built-in method references. */
|
|
666
|
+
var objectProto$1 = Object.prototype;
|
|
667
|
+
|
|
668
|
+
/** Used to check objects for own properties. */
|
|
669
|
+
var hasOwnProperty$1 = objectProto$1.hasOwnProperty;
|
|
670
|
+
|
|
671
|
+
/**
|
|
672
|
+
* The base implementation of `_.keys` which doesn't treat sparse arrays as dense.
|
|
673
|
+
*
|
|
674
|
+
* @private
|
|
675
|
+
* @param {Object} object The object to query.
|
|
676
|
+
* @returns {Array} Returns the array of property names.
|
|
677
|
+
*/
|
|
678
|
+
function baseKeys(object) {
|
|
679
|
+
if (!isPrototype(object)) {
|
|
680
|
+
return nativeKeys$1(object);
|
|
681
|
+
}
|
|
682
|
+
var result = [];
|
|
683
|
+
for (var key in Object(object)) {
|
|
684
|
+
if (hasOwnProperty$1.call(object, key) && key != 'constructor') {
|
|
685
|
+
result.push(key);
|
|
686
|
+
}
|
|
687
|
+
}
|
|
688
|
+
return result;
|
|
689
|
+
}
|
|
690
|
+
|
|
691
|
+
/* Built-in method references that are verified to be native. */
|
|
692
|
+
var Map$1 = getNative(root$1, 'Map');
|
|
693
|
+
|
|
694
|
+
var Map$2 = Map$1;
|
|
695
|
+
|
|
696
|
+
/* Built-in method references that are verified to be native. */
|
|
697
|
+
var DataView = getNative(root$1, 'DataView');
|
|
698
|
+
|
|
699
|
+
var DataView$1 = DataView;
|
|
700
|
+
|
|
701
|
+
/* Built-in method references that are verified to be native. */
|
|
702
|
+
var Promise$1 = getNative(root$1, 'Promise');
|
|
703
|
+
|
|
704
|
+
var Promise$2 = Promise$1;
|
|
896
705
|
|
|
897
|
-
|
|
706
|
+
/* Built-in method references that are verified to be native. */
|
|
707
|
+
var Set = getNative(root$1, 'Set');
|
|
898
708
|
|
|
899
|
-
var
|
|
900
|
-
getTag$1 = _getTag,
|
|
901
|
-
isArguments = isArguments_1,
|
|
902
|
-
isArray = isArray_1,
|
|
903
|
-
isArrayLike = isArrayLike_1,
|
|
904
|
-
isBuffer$1 = isBuffer$2.exports,
|
|
905
|
-
isPrototype = _isPrototype,
|
|
906
|
-
isTypedArray = isTypedArray_1;
|
|
709
|
+
var Set$1 = Set;
|
|
907
710
|
|
|
908
711
|
/** `Object#toString` result references. */
|
|
909
712
|
var mapTag$1 = '[object Map]',
|
|
910
|
-
|
|
713
|
+
objectTag = '[object Object]',
|
|
714
|
+
promiseTag = '[object Promise]',
|
|
715
|
+
setTag$1 = '[object Set]',
|
|
716
|
+
weakMapTag = '[object WeakMap]';
|
|
717
|
+
|
|
718
|
+
var dataViewTag = '[object DataView]';
|
|
719
|
+
|
|
720
|
+
/** Used to detect maps, sets, and weakmaps. */
|
|
721
|
+
var dataViewCtorString = toSource(DataView$1),
|
|
722
|
+
mapCtorString = toSource(Map$2),
|
|
723
|
+
promiseCtorString = toSource(Promise$2),
|
|
724
|
+
setCtorString = toSource(Set$1),
|
|
725
|
+
weakMapCtorString = toSource(WeakMap$1);
|
|
726
|
+
|
|
727
|
+
/**
|
|
728
|
+
* Gets the `toStringTag` of `value`.
|
|
729
|
+
*
|
|
730
|
+
* @private
|
|
731
|
+
* @param {*} value The value to query.
|
|
732
|
+
* @returns {string} Returns the `toStringTag`.
|
|
733
|
+
*/
|
|
734
|
+
var getTag = baseGetTag;
|
|
735
|
+
|
|
736
|
+
// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.
|
|
737
|
+
if ((DataView$1 && getTag(new DataView$1(new ArrayBuffer(1))) != dataViewTag) ||
|
|
738
|
+
(Map$2 && getTag(new Map$2) != mapTag$1) ||
|
|
739
|
+
(Promise$2 && getTag(Promise$2.resolve()) != promiseTag) ||
|
|
740
|
+
(Set$1 && getTag(new Set$1) != setTag$1) ||
|
|
741
|
+
(WeakMap$1 && getTag(new WeakMap$1) != weakMapTag)) {
|
|
742
|
+
getTag = function(value) {
|
|
743
|
+
var result = baseGetTag(value),
|
|
744
|
+
Ctor = result == objectTag ? value.constructor : undefined,
|
|
745
|
+
ctorString = Ctor ? toSource(Ctor) : '';
|
|
746
|
+
|
|
747
|
+
if (ctorString) {
|
|
748
|
+
switch (ctorString) {
|
|
749
|
+
case dataViewCtorString: return dataViewTag;
|
|
750
|
+
case mapCtorString: return mapTag$1;
|
|
751
|
+
case promiseCtorString: return promiseTag;
|
|
752
|
+
case setCtorString: return setTag$1;
|
|
753
|
+
case weakMapCtorString: return weakMapTag;
|
|
754
|
+
}
|
|
755
|
+
}
|
|
756
|
+
return result;
|
|
757
|
+
};
|
|
758
|
+
}
|
|
759
|
+
|
|
760
|
+
var getTag$1 = getTag;
|
|
761
|
+
|
|
762
|
+
/** `Object#toString` result references. */
|
|
763
|
+
var mapTag = '[object Map]',
|
|
764
|
+
setTag = '[object Set]';
|
|
911
765
|
|
|
912
766
|
/** Used for built-in method references. */
|
|
913
|
-
var objectProto
|
|
767
|
+
var objectProto = Object.prototype;
|
|
914
768
|
|
|
915
769
|
/** Used to check objects for own properties. */
|
|
916
|
-
var hasOwnProperty
|
|
770
|
+
var hasOwnProperty = objectProto.hasOwnProperty;
|
|
917
771
|
|
|
918
772
|
/**
|
|
919
773
|
* Checks if `value` is an empty object, collection, map, or set.
|
|
@@ -953,27 +807,25 @@ function isEmpty(value) {
|
|
|
953
807
|
return true;
|
|
954
808
|
}
|
|
955
809
|
if (isArrayLike(value) &&
|
|
956
|
-
(isArray(value) || typeof value == 'string' || typeof value.splice == 'function' ||
|
|
957
|
-
isBuffer$1(value) || isTypedArray(value) || isArguments(value))) {
|
|
810
|
+
(isArray$1(value) || typeof value == 'string' || typeof value.splice == 'function' ||
|
|
811
|
+
isBuffer$1(value) || isTypedArray$1(value) || isArguments$1(value))) {
|
|
958
812
|
return !value.length;
|
|
959
813
|
}
|
|
960
814
|
var tag = getTag$1(value);
|
|
961
|
-
if (tag == mapTag
|
|
815
|
+
if (tag == mapTag || tag == setTag) {
|
|
962
816
|
return !value.size;
|
|
963
817
|
}
|
|
964
818
|
if (isPrototype(value)) {
|
|
965
819
|
return !baseKeys(value).length;
|
|
966
820
|
}
|
|
967
821
|
for (var key in value) {
|
|
968
|
-
if (hasOwnProperty
|
|
822
|
+
if (hasOwnProperty.call(value, key)) {
|
|
969
823
|
return false;
|
|
970
824
|
}
|
|
971
825
|
}
|
|
972
826
|
return true;
|
|
973
827
|
}
|
|
974
828
|
|
|
975
|
-
var isEmpty_1 = isEmpty;
|
|
976
|
-
|
|
977
829
|
const isString = obj => typeof obj === 'string';
|
|
978
830
|
const defer = () => {
|
|
979
831
|
let res;
|
|
@@ -3482,1285 +3334,6 @@ const enabled = (config, env, defaultValue) => {
|
|
|
3482
3334
|
return typeof defaultValue === 'boolean' ? defaultValue : true;
|
|
3483
3335
|
};
|
|
3484
3336
|
|
|
3485
|
-
/** Detect free variable `global` from Node.js. */
|
|
3486
|
-
|
|
3487
|
-
var freeGlobal$1 = typeof commonjsGlobal == 'object' && commonjsGlobal && commonjsGlobal.Object === Object && commonjsGlobal;
|
|
3488
|
-
|
|
3489
|
-
var _freeGlobal = freeGlobal$1;
|
|
3490
|
-
|
|
3491
|
-
var freeGlobal = _freeGlobal;
|
|
3492
|
-
|
|
3493
|
-
/** Detect free variable `self`. */
|
|
3494
|
-
var freeSelf = typeof self == 'object' && self && self.Object === Object && self;
|
|
3495
|
-
|
|
3496
|
-
/** Used as a reference to the global object. */
|
|
3497
|
-
var root$7 = freeGlobal || freeSelf || Function('return this')();
|
|
3498
|
-
|
|
3499
|
-
var _root = root$7;
|
|
3500
|
-
|
|
3501
|
-
var root$6 = _root;
|
|
3502
|
-
|
|
3503
|
-
/** Built-in value references. */
|
|
3504
|
-
var Symbol$4 = root$6.Symbol;
|
|
3505
|
-
|
|
3506
|
-
var _Symbol = Symbol$4;
|
|
3507
|
-
|
|
3508
|
-
var Symbol$3 = _Symbol;
|
|
3509
|
-
|
|
3510
|
-
/** Used for built-in method references. */
|
|
3511
|
-
var objectProto$5 = Object.prototype;
|
|
3512
|
-
|
|
3513
|
-
/** Used to check objects for own properties. */
|
|
3514
|
-
var hasOwnProperty$4 = objectProto$5.hasOwnProperty;
|
|
3515
|
-
|
|
3516
|
-
/**
|
|
3517
|
-
* Used to resolve the
|
|
3518
|
-
* [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
|
|
3519
|
-
* of values.
|
|
3520
|
-
*/
|
|
3521
|
-
var nativeObjectToString$1 = objectProto$5.toString;
|
|
3522
|
-
|
|
3523
|
-
/** Built-in value references. */
|
|
3524
|
-
var symToStringTag$1 = Symbol$3 ? Symbol$3.toStringTag : undefined;
|
|
3525
|
-
|
|
3526
|
-
/**
|
|
3527
|
-
* A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.
|
|
3528
|
-
*
|
|
3529
|
-
* @private
|
|
3530
|
-
* @param {*} value The value to query.
|
|
3531
|
-
* @returns {string} Returns the raw `toStringTag`.
|
|
3532
|
-
*/
|
|
3533
|
-
function getRawTag$1(value) {
|
|
3534
|
-
var isOwn = hasOwnProperty$4.call(value, symToStringTag$1),
|
|
3535
|
-
tag = value[symToStringTag$1];
|
|
3536
|
-
|
|
3537
|
-
try {
|
|
3538
|
-
value[symToStringTag$1] = undefined;
|
|
3539
|
-
var unmasked = true;
|
|
3540
|
-
} catch (e) {}
|
|
3541
|
-
|
|
3542
|
-
var result = nativeObjectToString$1.call(value);
|
|
3543
|
-
if (unmasked) {
|
|
3544
|
-
if (isOwn) {
|
|
3545
|
-
value[symToStringTag$1] = tag;
|
|
3546
|
-
} else {
|
|
3547
|
-
delete value[symToStringTag$1];
|
|
3548
|
-
}
|
|
3549
|
-
}
|
|
3550
|
-
return result;
|
|
3551
|
-
}
|
|
3552
|
-
|
|
3553
|
-
var _getRawTag = getRawTag$1;
|
|
3554
|
-
|
|
3555
|
-
/** Used for built-in method references. */
|
|
3556
|
-
|
|
3557
|
-
var objectProto$4 = Object.prototype;
|
|
3558
|
-
|
|
3559
|
-
/**
|
|
3560
|
-
* Used to resolve the
|
|
3561
|
-
* [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
|
|
3562
|
-
* of values.
|
|
3563
|
-
*/
|
|
3564
|
-
var nativeObjectToString = objectProto$4.toString;
|
|
3565
|
-
|
|
3566
|
-
/**
|
|
3567
|
-
* Converts `value` to a string using `Object.prototype.toString`.
|
|
3568
|
-
*
|
|
3569
|
-
* @private
|
|
3570
|
-
* @param {*} value The value to convert.
|
|
3571
|
-
* @returns {string} Returns the converted string.
|
|
3572
|
-
*/
|
|
3573
|
-
function objectToString$1(value) {
|
|
3574
|
-
return nativeObjectToString.call(value);
|
|
3575
|
-
}
|
|
3576
|
-
|
|
3577
|
-
var _objectToString = objectToString$1;
|
|
3578
|
-
|
|
3579
|
-
var Symbol$2 = _Symbol,
|
|
3580
|
-
getRawTag = _getRawTag,
|
|
3581
|
-
objectToString = _objectToString;
|
|
3582
|
-
|
|
3583
|
-
/** `Object#toString` result references. */
|
|
3584
|
-
var nullTag = '[object Null]',
|
|
3585
|
-
undefinedTag = '[object Undefined]';
|
|
3586
|
-
|
|
3587
|
-
/** Built-in value references. */
|
|
3588
|
-
var symToStringTag = Symbol$2 ? Symbol$2.toStringTag : undefined;
|
|
3589
|
-
|
|
3590
|
-
/**
|
|
3591
|
-
* The base implementation of `getTag` without fallbacks for buggy environments.
|
|
3592
|
-
*
|
|
3593
|
-
* @private
|
|
3594
|
-
* @param {*} value The value to query.
|
|
3595
|
-
* @returns {string} Returns the `toStringTag`.
|
|
3596
|
-
*/
|
|
3597
|
-
function baseGetTag$3(value) {
|
|
3598
|
-
if (value == null) {
|
|
3599
|
-
return value === undefined ? undefinedTag : nullTag;
|
|
3600
|
-
}
|
|
3601
|
-
return (symToStringTag && symToStringTag in Object(value))
|
|
3602
|
-
? getRawTag(value)
|
|
3603
|
-
: objectToString(value);
|
|
3604
|
-
}
|
|
3605
|
-
|
|
3606
|
-
var _baseGetTag = baseGetTag$3;
|
|
3607
|
-
|
|
3608
|
-
/**
|
|
3609
|
-
* Checks if `value` is object-like. A value is object-like if it's not `null`
|
|
3610
|
-
* and has a `typeof` result of "object".
|
|
3611
|
-
*
|
|
3612
|
-
* @static
|
|
3613
|
-
* @memberOf _
|
|
3614
|
-
* @since 4.0.0
|
|
3615
|
-
* @category Lang
|
|
3616
|
-
* @param {*} value The value to check.
|
|
3617
|
-
* @returns {boolean} Returns `true` if `value` is object-like, else `false`.
|
|
3618
|
-
* @example
|
|
3619
|
-
*
|
|
3620
|
-
* _.isObjectLike({});
|
|
3621
|
-
* // => true
|
|
3622
|
-
*
|
|
3623
|
-
* _.isObjectLike([1, 2, 3]);
|
|
3624
|
-
* // => true
|
|
3625
|
-
*
|
|
3626
|
-
* _.isObjectLike(_.noop);
|
|
3627
|
-
* // => false
|
|
3628
|
-
*
|
|
3629
|
-
* _.isObjectLike(null);
|
|
3630
|
-
* // => false
|
|
3631
|
-
*/
|
|
3632
|
-
|
|
3633
|
-
function isObjectLike$2(value) {
|
|
3634
|
-
return value != null && typeof value == 'object';
|
|
3635
|
-
}
|
|
3636
|
-
|
|
3637
|
-
var isObjectLike_1 = isObjectLike$2;
|
|
3638
|
-
|
|
3639
|
-
/**
|
|
3640
|
-
* Checks if `value` is the
|
|
3641
|
-
* [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)
|
|
3642
|
-
* of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
|
|
3643
|
-
*
|
|
3644
|
-
* @static
|
|
3645
|
-
* @memberOf _
|
|
3646
|
-
* @since 0.1.0
|
|
3647
|
-
* @category Lang
|
|
3648
|
-
* @param {*} value The value to check.
|
|
3649
|
-
* @returns {boolean} Returns `true` if `value` is an object, else `false`.
|
|
3650
|
-
* @example
|
|
3651
|
-
*
|
|
3652
|
-
* _.isObject({});
|
|
3653
|
-
* // => true
|
|
3654
|
-
*
|
|
3655
|
-
* _.isObject([1, 2, 3]);
|
|
3656
|
-
* // => true
|
|
3657
|
-
*
|
|
3658
|
-
* _.isObject(_.noop);
|
|
3659
|
-
* // => true
|
|
3660
|
-
*
|
|
3661
|
-
* _.isObject(null);
|
|
3662
|
-
* // => false
|
|
3663
|
-
*/
|
|
3664
|
-
|
|
3665
|
-
function isObject$2(value) {
|
|
3666
|
-
var type = typeof value;
|
|
3667
|
-
return value != null && (type == 'object' || type == 'function');
|
|
3668
|
-
}
|
|
3669
|
-
|
|
3670
|
-
var isObject_1 = isObject$2;
|
|
3671
|
-
|
|
3672
|
-
var baseGetTag$2 = _baseGetTag,
|
|
3673
|
-
isObject$1 = isObject_1;
|
|
3674
|
-
|
|
3675
|
-
/** `Object#toString` result references. */
|
|
3676
|
-
var asyncTag = '[object AsyncFunction]',
|
|
3677
|
-
funcTag = '[object Function]',
|
|
3678
|
-
genTag = '[object GeneratorFunction]',
|
|
3679
|
-
proxyTag = '[object Proxy]';
|
|
3680
|
-
|
|
3681
|
-
/**
|
|
3682
|
-
* Checks if `value` is classified as a `Function` object.
|
|
3683
|
-
*
|
|
3684
|
-
* @static
|
|
3685
|
-
* @memberOf _
|
|
3686
|
-
* @since 0.1.0
|
|
3687
|
-
* @category Lang
|
|
3688
|
-
* @param {*} value The value to check.
|
|
3689
|
-
* @returns {boolean} Returns `true` if `value` is a function, else `false`.
|
|
3690
|
-
* @example
|
|
3691
|
-
*
|
|
3692
|
-
* _.isFunction(_);
|
|
3693
|
-
* // => true
|
|
3694
|
-
*
|
|
3695
|
-
* _.isFunction(/abc/);
|
|
3696
|
-
* // => false
|
|
3697
|
-
*/
|
|
3698
|
-
function isFunction$1(value) {
|
|
3699
|
-
if (!isObject$1(value)) {
|
|
3700
|
-
return false;
|
|
3701
|
-
}
|
|
3702
|
-
// The use of `Object#toString` avoids issues with the `typeof` operator
|
|
3703
|
-
// in Safari 9 which returns 'object' for typed arrays and other constructors.
|
|
3704
|
-
var tag = baseGetTag$2(value);
|
|
3705
|
-
return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;
|
|
3706
|
-
}
|
|
3707
|
-
|
|
3708
|
-
var isFunction_1 = isFunction$1;
|
|
3709
|
-
|
|
3710
|
-
var root$5 = _root;
|
|
3711
|
-
|
|
3712
|
-
/** Used to detect overreaching core-js shims. */
|
|
3713
|
-
var coreJsData$1 = root$5['__core-js_shared__'];
|
|
3714
|
-
|
|
3715
|
-
var _coreJsData = coreJsData$1;
|
|
3716
|
-
|
|
3717
|
-
var coreJsData = _coreJsData;
|
|
3718
|
-
|
|
3719
|
-
/** Used to detect methods masquerading as native. */
|
|
3720
|
-
var maskSrcKey = (function() {
|
|
3721
|
-
var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');
|
|
3722
|
-
return uid ? ('Symbol(src)_1.' + uid) : '';
|
|
3723
|
-
}());
|
|
3724
|
-
|
|
3725
|
-
/**
|
|
3726
|
-
* Checks if `func` has its source masked.
|
|
3727
|
-
*
|
|
3728
|
-
* @private
|
|
3729
|
-
* @param {Function} func The function to check.
|
|
3730
|
-
* @returns {boolean} Returns `true` if `func` is masked, else `false`.
|
|
3731
|
-
*/
|
|
3732
|
-
function isMasked$1(func) {
|
|
3733
|
-
return !!maskSrcKey && (maskSrcKey in func);
|
|
3734
|
-
}
|
|
3735
|
-
|
|
3736
|
-
var _isMasked = isMasked$1;
|
|
3737
|
-
|
|
3738
|
-
/** Used for built-in method references. */
|
|
3739
|
-
|
|
3740
|
-
var funcProto$1 = Function.prototype;
|
|
3741
|
-
|
|
3742
|
-
/** Used to resolve the decompiled source of functions. */
|
|
3743
|
-
var funcToString$1 = funcProto$1.toString;
|
|
3744
|
-
|
|
3745
|
-
/**
|
|
3746
|
-
* Converts `func` to its source code.
|
|
3747
|
-
*
|
|
3748
|
-
* @private
|
|
3749
|
-
* @param {Function} func The function to convert.
|
|
3750
|
-
* @returns {string} Returns the source code.
|
|
3751
|
-
*/
|
|
3752
|
-
function toSource$2(func) {
|
|
3753
|
-
if (func != null) {
|
|
3754
|
-
try {
|
|
3755
|
-
return funcToString$1.call(func);
|
|
3756
|
-
} catch (e) {}
|
|
3757
|
-
try {
|
|
3758
|
-
return (func + '');
|
|
3759
|
-
} catch (e) {}
|
|
3760
|
-
}
|
|
3761
|
-
return '';
|
|
3762
|
-
}
|
|
3763
|
-
|
|
3764
|
-
var _toSource = toSource$2;
|
|
3765
|
-
|
|
3766
|
-
var isFunction = isFunction_1,
|
|
3767
|
-
isMasked = _isMasked,
|
|
3768
|
-
isObject = isObject_1,
|
|
3769
|
-
toSource$1 = _toSource;
|
|
3770
|
-
|
|
3771
|
-
/**
|
|
3772
|
-
* Used to match `RegExp`
|
|
3773
|
-
* [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).
|
|
3774
|
-
*/
|
|
3775
|
-
var reRegExpChar = /[\\^$.*+?()[\]{}|]/g;
|
|
3776
|
-
|
|
3777
|
-
/** Used to detect host constructors (Safari). */
|
|
3778
|
-
var reIsHostCtor = /^\[object .+?Constructor\]$/;
|
|
3779
|
-
|
|
3780
|
-
/** Used for built-in method references. */
|
|
3781
|
-
var funcProto = Function.prototype,
|
|
3782
|
-
objectProto$3 = Object.prototype;
|
|
3783
|
-
|
|
3784
|
-
/** Used to resolve the decompiled source of functions. */
|
|
3785
|
-
var funcToString = funcProto.toString;
|
|
3786
|
-
|
|
3787
|
-
/** Used to check objects for own properties. */
|
|
3788
|
-
var hasOwnProperty$3 = objectProto$3.hasOwnProperty;
|
|
3789
|
-
|
|
3790
|
-
/** Used to detect if a method is native. */
|
|
3791
|
-
var reIsNative = RegExp('^' +
|
|
3792
|
-
funcToString.call(hasOwnProperty$3).replace(reRegExpChar, '\\$&')
|
|
3793
|
-
.replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'
|
|
3794
|
-
);
|
|
3795
|
-
|
|
3796
|
-
/**
|
|
3797
|
-
* The base implementation of `_.isNative` without bad shim checks.
|
|
3798
|
-
*
|
|
3799
|
-
* @private
|
|
3800
|
-
* @param {*} value The value to check.
|
|
3801
|
-
* @returns {boolean} Returns `true` if `value` is a native function,
|
|
3802
|
-
* else `false`.
|
|
3803
|
-
*/
|
|
3804
|
-
function baseIsNative$1(value) {
|
|
3805
|
-
if (!isObject(value) || isMasked(value)) {
|
|
3806
|
-
return false;
|
|
3807
|
-
}
|
|
3808
|
-
var pattern = isFunction(value) ? reIsNative : reIsHostCtor;
|
|
3809
|
-
return pattern.test(toSource$1(value));
|
|
3810
|
-
}
|
|
3811
|
-
|
|
3812
|
-
var _baseIsNative = baseIsNative$1;
|
|
3813
|
-
|
|
3814
|
-
/**
|
|
3815
|
-
* Gets the value at `key` of `object`.
|
|
3816
|
-
*
|
|
3817
|
-
* @private
|
|
3818
|
-
* @param {Object} [object] The object to query.
|
|
3819
|
-
* @param {string} key The key of the property to get.
|
|
3820
|
-
* @returns {*} Returns the property value.
|
|
3821
|
-
*/
|
|
3822
|
-
|
|
3823
|
-
function getValue$1(object, key) {
|
|
3824
|
-
return object == null ? undefined : object[key];
|
|
3825
|
-
}
|
|
3826
|
-
|
|
3827
|
-
var _getValue = getValue$1;
|
|
3828
|
-
|
|
3829
|
-
var baseIsNative = _baseIsNative,
|
|
3830
|
-
getValue = _getValue;
|
|
3831
|
-
|
|
3832
|
-
/**
|
|
3833
|
-
* Gets the native function at `key` of `object`.
|
|
3834
|
-
*
|
|
3835
|
-
* @private
|
|
3836
|
-
* @param {Object} object The object to query.
|
|
3837
|
-
* @param {string} key The key of the method to get.
|
|
3838
|
-
* @returns {*} Returns the function if it's native, else `undefined`.
|
|
3839
|
-
*/
|
|
3840
|
-
function getNative$6(object, key) {
|
|
3841
|
-
var value = getValue(object, key);
|
|
3842
|
-
return baseIsNative(value) ? value : undefined;
|
|
3843
|
-
}
|
|
3844
|
-
|
|
3845
|
-
var _getNative = getNative$6;
|
|
3846
|
-
|
|
3847
|
-
var getNative$5 = _getNative;
|
|
3848
|
-
|
|
3849
|
-
/* Built-in method references that are verified to be native. */
|
|
3850
|
-
var nativeCreate$4 = getNative$5(Object, 'create');
|
|
3851
|
-
|
|
3852
|
-
var _nativeCreate = nativeCreate$4;
|
|
3853
|
-
|
|
3854
|
-
var nativeCreate$3 = _nativeCreate;
|
|
3855
|
-
|
|
3856
|
-
/**
|
|
3857
|
-
* Removes all key-value entries from the hash.
|
|
3858
|
-
*
|
|
3859
|
-
* @private
|
|
3860
|
-
* @name clear
|
|
3861
|
-
* @memberOf Hash
|
|
3862
|
-
*/
|
|
3863
|
-
function hashClear$1() {
|
|
3864
|
-
this.__data__ = nativeCreate$3 ? nativeCreate$3(null) : {};
|
|
3865
|
-
this.size = 0;
|
|
3866
|
-
}
|
|
3867
|
-
|
|
3868
|
-
var _hashClear = hashClear$1;
|
|
3869
|
-
|
|
3870
|
-
/**
|
|
3871
|
-
* Removes `key` and its value from the hash.
|
|
3872
|
-
*
|
|
3873
|
-
* @private
|
|
3874
|
-
* @name delete
|
|
3875
|
-
* @memberOf Hash
|
|
3876
|
-
* @param {Object} hash The hash to modify.
|
|
3877
|
-
* @param {string} key The key of the value to remove.
|
|
3878
|
-
* @returns {boolean} Returns `true` if the entry was removed, else `false`.
|
|
3879
|
-
*/
|
|
3880
|
-
|
|
3881
|
-
function hashDelete$1(key) {
|
|
3882
|
-
var result = this.has(key) && delete this.__data__[key];
|
|
3883
|
-
this.size -= result ? 1 : 0;
|
|
3884
|
-
return result;
|
|
3885
|
-
}
|
|
3886
|
-
|
|
3887
|
-
var _hashDelete = hashDelete$1;
|
|
3888
|
-
|
|
3889
|
-
var nativeCreate$2 = _nativeCreate;
|
|
3890
|
-
|
|
3891
|
-
/** Used to stand-in for `undefined` hash values. */
|
|
3892
|
-
var HASH_UNDEFINED$1 = '__lodash_hash_undefined__';
|
|
3893
|
-
|
|
3894
|
-
/** Used for built-in method references. */
|
|
3895
|
-
var objectProto$2 = Object.prototype;
|
|
3896
|
-
|
|
3897
|
-
/** Used to check objects for own properties. */
|
|
3898
|
-
var hasOwnProperty$2 = objectProto$2.hasOwnProperty;
|
|
3899
|
-
|
|
3900
|
-
/**
|
|
3901
|
-
* Gets the hash value for `key`.
|
|
3902
|
-
*
|
|
3903
|
-
* @private
|
|
3904
|
-
* @name get
|
|
3905
|
-
* @memberOf Hash
|
|
3906
|
-
* @param {string} key The key of the value to get.
|
|
3907
|
-
* @returns {*} Returns the entry value.
|
|
3908
|
-
*/
|
|
3909
|
-
function hashGet$1(key) {
|
|
3910
|
-
var data = this.__data__;
|
|
3911
|
-
if (nativeCreate$2) {
|
|
3912
|
-
var result = data[key];
|
|
3913
|
-
return result === HASH_UNDEFINED$1 ? undefined : result;
|
|
3914
|
-
}
|
|
3915
|
-
return hasOwnProperty$2.call(data, key) ? data[key] : undefined;
|
|
3916
|
-
}
|
|
3917
|
-
|
|
3918
|
-
var _hashGet = hashGet$1;
|
|
3919
|
-
|
|
3920
|
-
var nativeCreate$1 = _nativeCreate;
|
|
3921
|
-
|
|
3922
|
-
/** Used for built-in method references. */
|
|
3923
|
-
var objectProto$1 = Object.prototype;
|
|
3924
|
-
|
|
3925
|
-
/** Used to check objects for own properties. */
|
|
3926
|
-
var hasOwnProperty$1 = objectProto$1.hasOwnProperty;
|
|
3927
|
-
|
|
3928
|
-
/**
|
|
3929
|
-
* Checks if a hash value for `key` exists.
|
|
3930
|
-
*
|
|
3931
|
-
* @private
|
|
3932
|
-
* @name has
|
|
3933
|
-
* @memberOf Hash
|
|
3934
|
-
* @param {string} key The key of the entry to check.
|
|
3935
|
-
* @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
|
|
3936
|
-
*/
|
|
3937
|
-
function hashHas$1(key) {
|
|
3938
|
-
var data = this.__data__;
|
|
3939
|
-
return nativeCreate$1 ? (data[key] !== undefined) : hasOwnProperty$1.call(data, key);
|
|
3940
|
-
}
|
|
3941
|
-
|
|
3942
|
-
var _hashHas = hashHas$1;
|
|
3943
|
-
|
|
3944
|
-
var nativeCreate = _nativeCreate;
|
|
3945
|
-
|
|
3946
|
-
/** Used to stand-in for `undefined` hash values. */
|
|
3947
|
-
var HASH_UNDEFINED = '__lodash_hash_undefined__';
|
|
3948
|
-
|
|
3949
|
-
/**
|
|
3950
|
-
* Sets the hash `key` to `value`.
|
|
3951
|
-
*
|
|
3952
|
-
* @private
|
|
3953
|
-
* @name set
|
|
3954
|
-
* @memberOf Hash
|
|
3955
|
-
* @param {string} key The key of the value to set.
|
|
3956
|
-
* @param {*} value The value to set.
|
|
3957
|
-
* @returns {Object} Returns the hash instance.
|
|
3958
|
-
*/
|
|
3959
|
-
function hashSet$1(key, value) {
|
|
3960
|
-
var data = this.__data__;
|
|
3961
|
-
this.size += this.has(key) ? 0 : 1;
|
|
3962
|
-
data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;
|
|
3963
|
-
return this;
|
|
3964
|
-
}
|
|
3965
|
-
|
|
3966
|
-
var _hashSet = hashSet$1;
|
|
3967
|
-
|
|
3968
|
-
var hashClear = _hashClear,
|
|
3969
|
-
hashDelete = _hashDelete,
|
|
3970
|
-
hashGet = _hashGet,
|
|
3971
|
-
hashHas = _hashHas,
|
|
3972
|
-
hashSet = _hashSet;
|
|
3973
|
-
|
|
3974
|
-
/**
|
|
3975
|
-
* Creates a hash object.
|
|
3976
|
-
*
|
|
3977
|
-
* @private
|
|
3978
|
-
* @constructor
|
|
3979
|
-
* @param {Array} [entries] The key-value pairs to cache.
|
|
3980
|
-
*/
|
|
3981
|
-
function Hash$1(entries) {
|
|
3982
|
-
var index = -1,
|
|
3983
|
-
length = entries == null ? 0 : entries.length;
|
|
3984
|
-
|
|
3985
|
-
this.clear();
|
|
3986
|
-
while (++index < length) {
|
|
3987
|
-
var entry = entries[index];
|
|
3988
|
-
this.set(entry[0], entry[1]);
|
|
3989
|
-
}
|
|
3990
|
-
}
|
|
3991
|
-
|
|
3992
|
-
// Add methods to `Hash`.
|
|
3993
|
-
Hash$1.prototype.clear = hashClear;
|
|
3994
|
-
Hash$1.prototype['delete'] = hashDelete;
|
|
3995
|
-
Hash$1.prototype.get = hashGet;
|
|
3996
|
-
Hash$1.prototype.has = hashHas;
|
|
3997
|
-
Hash$1.prototype.set = hashSet;
|
|
3998
|
-
|
|
3999
|
-
var _Hash = Hash$1;
|
|
4000
|
-
|
|
4001
|
-
/**
|
|
4002
|
-
* Removes all key-value entries from the list cache.
|
|
4003
|
-
*
|
|
4004
|
-
* @private
|
|
4005
|
-
* @name clear
|
|
4006
|
-
* @memberOf ListCache
|
|
4007
|
-
*/
|
|
4008
|
-
|
|
4009
|
-
function listCacheClear$1() {
|
|
4010
|
-
this.__data__ = [];
|
|
4011
|
-
this.size = 0;
|
|
4012
|
-
}
|
|
4013
|
-
|
|
4014
|
-
var _listCacheClear = listCacheClear$1;
|
|
4015
|
-
|
|
4016
|
-
/**
|
|
4017
|
-
* Performs a
|
|
4018
|
-
* [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
|
|
4019
|
-
* comparison between two values to determine if they are equivalent.
|
|
4020
|
-
*
|
|
4021
|
-
* @static
|
|
4022
|
-
* @memberOf _
|
|
4023
|
-
* @since 4.0.0
|
|
4024
|
-
* @category Lang
|
|
4025
|
-
* @param {*} value The value to compare.
|
|
4026
|
-
* @param {*} other The other value to compare.
|
|
4027
|
-
* @returns {boolean} Returns `true` if the values are equivalent, else `false`.
|
|
4028
|
-
* @example
|
|
4029
|
-
*
|
|
4030
|
-
* var object = { 'a': 1 };
|
|
4031
|
-
* var other = { 'a': 1 };
|
|
4032
|
-
*
|
|
4033
|
-
* _.eq(object, object);
|
|
4034
|
-
* // => true
|
|
4035
|
-
*
|
|
4036
|
-
* _.eq(object, other);
|
|
4037
|
-
* // => false
|
|
4038
|
-
*
|
|
4039
|
-
* _.eq('a', 'a');
|
|
4040
|
-
* // => true
|
|
4041
|
-
*
|
|
4042
|
-
* _.eq('a', Object('a'));
|
|
4043
|
-
* // => false
|
|
4044
|
-
*
|
|
4045
|
-
* _.eq(NaN, NaN);
|
|
4046
|
-
* // => true
|
|
4047
|
-
*/
|
|
4048
|
-
|
|
4049
|
-
function eq$1(value, other) {
|
|
4050
|
-
return value === other || (value !== value && other !== other);
|
|
4051
|
-
}
|
|
4052
|
-
|
|
4053
|
-
var eq_1 = eq$1;
|
|
4054
|
-
|
|
4055
|
-
var eq = eq_1;
|
|
4056
|
-
|
|
4057
|
-
/**
|
|
4058
|
-
* Gets the index at which the `key` is found in `array` of key-value pairs.
|
|
4059
|
-
*
|
|
4060
|
-
* @private
|
|
4061
|
-
* @param {Array} array The array to inspect.
|
|
4062
|
-
* @param {*} key The key to search for.
|
|
4063
|
-
* @returns {number} Returns the index of the matched value, else `-1`.
|
|
4064
|
-
*/
|
|
4065
|
-
function assocIndexOf$4(array, key) {
|
|
4066
|
-
var length = array.length;
|
|
4067
|
-
while (length--) {
|
|
4068
|
-
if (eq(array[length][0], key)) {
|
|
4069
|
-
return length;
|
|
4070
|
-
}
|
|
4071
|
-
}
|
|
4072
|
-
return -1;
|
|
4073
|
-
}
|
|
4074
|
-
|
|
4075
|
-
var _assocIndexOf = assocIndexOf$4;
|
|
4076
|
-
|
|
4077
|
-
var assocIndexOf$3 = _assocIndexOf;
|
|
4078
|
-
|
|
4079
|
-
/** Used for built-in method references. */
|
|
4080
|
-
var arrayProto = Array.prototype;
|
|
4081
|
-
|
|
4082
|
-
/** Built-in value references. */
|
|
4083
|
-
var splice = arrayProto.splice;
|
|
4084
|
-
|
|
4085
|
-
/**
|
|
4086
|
-
* Removes `key` and its value from the list cache.
|
|
4087
|
-
*
|
|
4088
|
-
* @private
|
|
4089
|
-
* @name delete
|
|
4090
|
-
* @memberOf ListCache
|
|
4091
|
-
* @param {string} key The key of the value to remove.
|
|
4092
|
-
* @returns {boolean} Returns `true` if the entry was removed, else `false`.
|
|
4093
|
-
*/
|
|
4094
|
-
function listCacheDelete$1(key) {
|
|
4095
|
-
var data = this.__data__,
|
|
4096
|
-
index = assocIndexOf$3(data, key);
|
|
4097
|
-
|
|
4098
|
-
if (index < 0) {
|
|
4099
|
-
return false;
|
|
4100
|
-
}
|
|
4101
|
-
var lastIndex = data.length - 1;
|
|
4102
|
-
if (index == lastIndex) {
|
|
4103
|
-
data.pop();
|
|
4104
|
-
} else {
|
|
4105
|
-
splice.call(data, index, 1);
|
|
4106
|
-
}
|
|
4107
|
-
--this.size;
|
|
4108
|
-
return true;
|
|
4109
|
-
}
|
|
4110
|
-
|
|
4111
|
-
var _listCacheDelete = listCacheDelete$1;
|
|
4112
|
-
|
|
4113
|
-
var assocIndexOf$2 = _assocIndexOf;
|
|
4114
|
-
|
|
4115
|
-
/**
|
|
4116
|
-
* Gets the list cache value for `key`.
|
|
4117
|
-
*
|
|
4118
|
-
* @private
|
|
4119
|
-
* @name get
|
|
4120
|
-
* @memberOf ListCache
|
|
4121
|
-
* @param {string} key The key of the value to get.
|
|
4122
|
-
* @returns {*} Returns the entry value.
|
|
4123
|
-
*/
|
|
4124
|
-
function listCacheGet$1(key) {
|
|
4125
|
-
var data = this.__data__,
|
|
4126
|
-
index = assocIndexOf$2(data, key);
|
|
4127
|
-
|
|
4128
|
-
return index < 0 ? undefined : data[index][1];
|
|
4129
|
-
}
|
|
4130
|
-
|
|
4131
|
-
var _listCacheGet = listCacheGet$1;
|
|
4132
|
-
|
|
4133
|
-
var assocIndexOf$1 = _assocIndexOf;
|
|
4134
|
-
|
|
4135
|
-
/**
|
|
4136
|
-
* Checks if a list cache value for `key` exists.
|
|
4137
|
-
*
|
|
4138
|
-
* @private
|
|
4139
|
-
* @name has
|
|
4140
|
-
* @memberOf ListCache
|
|
4141
|
-
* @param {string} key The key of the entry to check.
|
|
4142
|
-
* @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
|
|
4143
|
-
*/
|
|
4144
|
-
function listCacheHas$1(key) {
|
|
4145
|
-
return assocIndexOf$1(this.__data__, key) > -1;
|
|
4146
|
-
}
|
|
4147
|
-
|
|
4148
|
-
var _listCacheHas = listCacheHas$1;
|
|
4149
|
-
|
|
4150
|
-
var assocIndexOf = _assocIndexOf;
|
|
4151
|
-
|
|
4152
|
-
/**
|
|
4153
|
-
* Sets the list cache `key` to `value`.
|
|
4154
|
-
*
|
|
4155
|
-
* @private
|
|
4156
|
-
* @name set
|
|
4157
|
-
* @memberOf ListCache
|
|
4158
|
-
* @param {string} key The key of the value to set.
|
|
4159
|
-
* @param {*} value The value to set.
|
|
4160
|
-
* @returns {Object} Returns the list cache instance.
|
|
4161
|
-
*/
|
|
4162
|
-
function listCacheSet$1(key, value) {
|
|
4163
|
-
var data = this.__data__,
|
|
4164
|
-
index = assocIndexOf(data, key);
|
|
4165
|
-
|
|
4166
|
-
if (index < 0) {
|
|
4167
|
-
++this.size;
|
|
4168
|
-
data.push([key, value]);
|
|
4169
|
-
} else {
|
|
4170
|
-
data[index][1] = value;
|
|
4171
|
-
}
|
|
4172
|
-
return this;
|
|
4173
|
-
}
|
|
4174
|
-
|
|
4175
|
-
var _listCacheSet = listCacheSet$1;
|
|
4176
|
-
|
|
4177
|
-
var listCacheClear = _listCacheClear,
|
|
4178
|
-
listCacheDelete = _listCacheDelete,
|
|
4179
|
-
listCacheGet = _listCacheGet,
|
|
4180
|
-
listCacheHas = _listCacheHas,
|
|
4181
|
-
listCacheSet = _listCacheSet;
|
|
4182
|
-
|
|
4183
|
-
/**
|
|
4184
|
-
* Creates an list cache object.
|
|
4185
|
-
*
|
|
4186
|
-
* @private
|
|
4187
|
-
* @constructor
|
|
4188
|
-
* @param {Array} [entries] The key-value pairs to cache.
|
|
4189
|
-
*/
|
|
4190
|
-
function ListCache$1(entries) {
|
|
4191
|
-
var index = -1,
|
|
4192
|
-
length = entries == null ? 0 : entries.length;
|
|
4193
|
-
|
|
4194
|
-
this.clear();
|
|
4195
|
-
while (++index < length) {
|
|
4196
|
-
var entry = entries[index];
|
|
4197
|
-
this.set(entry[0], entry[1]);
|
|
4198
|
-
}
|
|
4199
|
-
}
|
|
4200
|
-
|
|
4201
|
-
// Add methods to `ListCache`.
|
|
4202
|
-
ListCache$1.prototype.clear = listCacheClear;
|
|
4203
|
-
ListCache$1.prototype['delete'] = listCacheDelete;
|
|
4204
|
-
ListCache$1.prototype.get = listCacheGet;
|
|
4205
|
-
ListCache$1.prototype.has = listCacheHas;
|
|
4206
|
-
ListCache$1.prototype.set = listCacheSet;
|
|
4207
|
-
|
|
4208
|
-
var _ListCache = ListCache$1;
|
|
4209
|
-
|
|
4210
|
-
var getNative$4 = _getNative,
|
|
4211
|
-
root$4 = _root;
|
|
4212
|
-
|
|
4213
|
-
/* Built-in method references that are verified to be native. */
|
|
4214
|
-
var Map$3 = getNative$4(root$4, 'Map');
|
|
4215
|
-
|
|
4216
|
-
var _Map = Map$3;
|
|
4217
|
-
|
|
4218
|
-
var Hash = _Hash,
|
|
4219
|
-
ListCache = _ListCache,
|
|
4220
|
-
Map$2 = _Map;
|
|
4221
|
-
|
|
4222
|
-
/**
|
|
4223
|
-
* Removes all key-value entries from the map.
|
|
4224
|
-
*
|
|
4225
|
-
* @private
|
|
4226
|
-
* @name clear
|
|
4227
|
-
* @memberOf MapCache
|
|
4228
|
-
*/
|
|
4229
|
-
function mapCacheClear$1() {
|
|
4230
|
-
this.size = 0;
|
|
4231
|
-
this.__data__ = {
|
|
4232
|
-
'hash': new Hash,
|
|
4233
|
-
'map': new (Map$2 || ListCache),
|
|
4234
|
-
'string': new Hash
|
|
4235
|
-
};
|
|
4236
|
-
}
|
|
4237
|
-
|
|
4238
|
-
var _mapCacheClear = mapCacheClear$1;
|
|
4239
|
-
|
|
4240
|
-
/**
|
|
4241
|
-
* Checks if `value` is suitable for use as unique object key.
|
|
4242
|
-
*
|
|
4243
|
-
* @private
|
|
4244
|
-
* @param {*} value The value to check.
|
|
4245
|
-
* @returns {boolean} Returns `true` if `value` is suitable, else `false`.
|
|
4246
|
-
*/
|
|
4247
|
-
|
|
4248
|
-
function isKeyable$1(value) {
|
|
4249
|
-
var type = typeof value;
|
|
4250
|
-
return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')
|
|
4251
|
-
? (value !== '__proto__')
|
|
4252
|
-
: (value === null);
|
|
4253
|
-
}
|
|
4254
|
-
|
|
4255
|
-
var _isKeyable = isKeyable$1;
|
|
4256
|
-
|
|
4257
|
-
var isKeyable = _isKeyable;
|
|
4258
|
-
|
|
4259
|
-
/**
|
|
4260
|
-
* Gets the data for `map`.
|
|
4261
|
-
*
|
|
4262
|
-
* @private
|
|
4263
|
-
* @param {Object} map The map to query.
|
|
4264
|
-
* @param {string} key The reference key.
|
|
4265
|
-
* @returns {*} Returns the map data.
|
|
4266
|
-
*/
|
|
4267
|
-
function getMapData$4(map, key) {
|
|
4268
|
-
var data = map.__data__;
|
|
4269
|
-
return isKeyable(key)
|
|
4270
|
-
? data[typeof key == 'string' ? 'string' : 'hash']
|
|
4271
|
-
: data.map;
|
|
4272
|
-
}
|
|
4273
|
-
|
|
4274
|
-
var _getMapData = getMapData$4;
|
|
4275
|
-
|
|
4276
|
-
var getMapData$3 = _getMapData;
|
|
4277
|
-
|
|
4278
|
-
/**
|
|
4279
|
-
* Removes `key` and its value from the map.
|
|
4280
|
-
*
|
|
4281
|
-
* @private
|
|
4282
|
-
* @name delete
|
|
4283
|
-
* @memberOf MapCache
|
|
4284
|
-
* @param {string} key The key of the value to remove.
|
|
4285
|
-
* @returns {boolean} Returns `true` if the entry was removed, else `false`.
|
|
4286
|
-
*/
|
|
4287
|
-
function mapCacheDelete$1(key) {
|
|
4288
|
-
var result = getMapData$3(this, key)['delete'](key);
|
|
4289
|
-
this.size -= result ? 1 : 0;
|
|
4290
|
-
return result;
|
|
4291
|
-
}
|
|
4292
|
-
|
|
4293
|
-
var _mapCacheDelete = mapCacheDelete$1;
|
|
4294
|
-
|
|
4295
|
-
var getMapData$2 = _getMapData;
|
|
4296
|
-
|
|
4297
|
-
/**
|
|
4298
|
-
* Gets the map value for `key`.
|
|
4299
|
-
*
|
|
4300
|
-
* @private
|
|
4301
|
-
* @name get
|
|
4302
|
-
* @memberOf MapCache
|
|
4303
|
-
* @param {string} key The key of the value to get.
|
|
4304
|
-
* @returns {*} Returns the entry value.
|
|
4305
|
-
*/
|
|
4306
|
-
function mapCacheGet$1(key) {
|
|
4307
|
-
return getMapData$2(this, key).get(key);
|
|
4308
|
-
}
|
|
4309
|
-
|
|
4310
|
-
var _mapCacheGet = mapCacheGet$1;
|
|
4311
|
-
|
|
4312
|
-
var getMapData$1 = _getMapData;
|
|
4313
|
-
|
|
4314
|
-
/**
|
|
4315
|
-
* Checks if a map value for `key` exists.
|
|
4316
|
-
*
|
|
4317
|
-
* @private
|
|
4318
|
-
* @name has
|
|
4319
|
-
* @memberOf MapCache
|
|
4320
|
-
* @param {string} key The key of the entry to check.
|
|
4321
|
-
* @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
|
|
4322
|
-
*/
|
|
4323
|
-
function mapCacheHas$1(key) {
|
|
4324
|
-
return getMapData$1(this, key).has(key);
|
|
4325
|
-
}
|
|
4326
|
-
|
|
4327
|
-
var _mapCacheHas = mapCacheHas$1;
|
|
4328
|
-
|
|
4329
|
-
var getMapData = _getMapData;
|
|
4330
|
-
|
|
4331
|
-
/**
|
|
4332
|
-
* Sets the map `key` to `value`.
|
|
4333
|
-
*
|
|
4334
|
-
* @private
|
|
4335
|
-
* @name set
|
|
4336
|
-
* @memberOf MapCache
|
|
4337
|
-
* @param {string} key The key of the value to set.
|
|
4338
|
-
* @param {*} value The value to set.
|
|
4339
|
-
* @returns {Object} Returns the map cache instance.
|
|
4340
|
-
*/
|
|
4341
|
-
function mapCacheSet$1(key, value) {
|
|
4342
|
-
var data = getMapData(this, key),
|
|
4343
|
-
size = data.size;
|
|
4344
|
-
|
|
4345
|
-
data.set(key, value);
|
|
4346
|
-
this.size += data.size == size ? 0 : 1;
|
|
4347
|
-
return this;
|
|
4348
|
-
}
|
|
4349
|
-
|
|
4350
|
-
var _mapCacheSet = mapCacheSet$1;
|
|
4351
|
-
|
|
4352
|
-
var mapCacheClear = _mapCacheClear,
|
|
4353
|
-
mapCacheDelete = _mapCacheDelete,
|
|
4354
|
-
mapCacheGet = _mapCacheGet,
|
|
4355
|
-
mapCacheHas = _mapCacheHas,
|
|
4356
|
-
mapCacheSet = _mapCacheSet;
|
|
4357
|
-
|
|
4358
|
-
/**
|
|
4359
|
-
* Creates a map cache object to store key-value pairs.
|
|
4360
|
-
*
|
|
4361
|
-
* @private
|
|
4362
|
-
* @constructor
|
|
4363
|
-
* @param {Array} [entries] The key-value pairs to cache.
|
|
4364
|
-
*/
|
|
4365
|
-
function MapCache$1(entries) {
|
|
4366
|
-
var index = -1,
|
|
4367
|
-
length = entries == null ? 0 : entries.length;
|
|
4368
|
-
|
|
4369
|
-
this.clear();
|
|
4370
|
-
while (++index < length) {
|
|
4371
|
-
var entry = entries[index];
|
|
4372
|
-
this.set(entry[0], entry[1]);
|
|
4373
|
-
}
|
|
4374
|
-
}
|
|
4375
|
-
|
|
4376
|
-
// Add methods to `MapCache`.
|
|
4377
|
-
MapCache$1.prototype.clear = mapCacheClear;
|
|
4378
|
-
MapCache$1.prototype['delete'] = mapCacheDelete;
|
|
4379
|
-
MapCache$1.prototype.get = mapCacheGet;
|
|
4380
|
-
MapCache$1.prototype.has = mapCacheHas;
|
|
4381
|
-
MapCache$1.prototype.set = mapCacheSet;
|
|
4382
|
-
|
|
4383
|
-
var _MapCache = MapCache$1;
|
|
4384
|
-
|
|
4385
|
-
var MapCache = _MapCache;
|
|
4386
|
-
|
|
4387
|
-
/** Error message constants. */
|
|
4388
|
-
var FUNC_ERROR_TEXT = 'Expected a function';
|
|
4389
|
-
|
|
4390
|
-
/**
|
|
4391
|
-
* Creates a function that memoizes the result of `func`. If `resolver` is
|
|
4392
|
-
* provided, it determines the cache key for storing the result based on the
|
|
4393
|
-
* arguments provided to the memoized function. By default, the first argument
|
|
4394
|
-
* provided to the memoized function is used as the map cache key. The `func`
|
|
4395
|
-
* is invoked with the `this` binding of the memoized function.
|
|
4396
|
-
*
|
|
4397
|
-
* **Note:** The cache is exposed as the `cache` property on the memoized
|
|
4398
|
-
* function. Its creation may be customized by replacing the `_.memoize.Cache`
|
|
4399
|
-
* constructor with one whose instances implement the
|
|
4400
|
-
* [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)
|
|
4401
|
-
* method interface of `clear`, `delete`, `get`, `has`, and `set`.
|
|
4402
|
-
*
|
|
4403
|
-
* @static
|
|
4404
|
-
* @memberOf _
|
|
4405
|
-
* @since 0.1.0
|
|
4406
|
-
* @category Function
|
|
4407
|
-
* @param {Function} func The function to have its output memoized.
|
|
4408
|
-
* @param {Function} [resolver] The function to resolve the cache key.
|
|
4409
|
-
* @returns {Function} Returns the new memoized function.
|
|
4410
|
-
* @example
|
|
4411
|
-
*
|
|
4412
|
-
* var object = { 'a': 1, 'b': 2 };
|
|
4413
|
-
* var other = { 'c': 3, 'd': 4 };
|
|
4414
|
-
*
|
|
4415
|
-
* var values = _.memoize(_.values);
|
|
4416
|
-
* values(object);
|
|
4417
|
-
* // => [1, 2]
|
|
4418
|
-
*
|
|
4419
|
-
* values(other);
|
|
4420
|
-
* // => [3, 4]
|
|
4421
|
-
*
|
|
4422
|
-
* object.a = 2;
|
|
4423
|
-
* values(object);
|
|
4424
|
-
* // => [1, 2]
|
|
4425
|
-
*
|
|
4426
|
-
* // Modify the result cache.
|
|
4427
|
-
* values.cache.set(object, ['a', 'b']);
|
|
4428
|
-
* values(object);
|
|
4429
|
-
* // => ['a', 'b']
|
|
4430
|
-
*
|
|
4431
|
-
* // Replace `_.memoize.Cache`.
|
|
4432
|
-
* _.memoize.Cache = WeakMap;
|
|
4433
|
-
*/
|
|
4434
|
-
function memoize$1(func, resolver) {
|
|
4435
|
-
if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {
|
|
4436
|
-
throw new TypeError(FUNC_ERROR_TEXT);
|
|
4437
|
-
}
|
|
4438
|
-
var memoized = function() {
|
|
4439
|
-
var args = arguments,
|
|
4440
|
-
key = resolver ? resolver.apply(this, args) : args[0],
|
|
4441
|
-
cache = memoized.cache;
|
|
4442
|
-
|
|
4443
|
-
if (cache.has(key)) {
|
|
4444
|
-
return cache.get(key);
|
|
4445
|
-
}
|
|
4446
|
-
var result = func.apply(this, args);
|
|
4447
|
-
memoized.cache = cache.set(key, result) || cache;
|
|
4448
|
-
return result;
|
|
4449
|
-
};
|
|
4450
|
-
memoized.cache = new (memoize$1.Cache || MapCache);
|
|
4451
|
-
return memoized;
|
|
4452
|
-
}
|
|
4453
|
-
|
|
4454
|
-
// Expose `MapCache`.
|
|
4455
|
-
memoize$1.Cache = MapCache;
|
|
4456
|
-
|
|
4457
|
-
var memoize_1 = memoize$1;
|
|
4458
|
-
|
|
4459
|
-
var memoize = memoize_1;
|
|
4460
|
-
|
|
4461
|
-
/** Used as the maximum memoize cache size. */
|
|
4462
|
-
var MAX_MEMOIZE_SIZE = 500;
|
|
4463
|
-
|
|
4464
|
-
/**
|
|
4465
|
-
* A specialized version of `_.memoize` which clears the memoized function's
|
|
4466
|
-
* cache when it exceeds `MAX_MEMOIZE_SIZE`.
|
|
4467
|
-
*
|
|
4468
|
-
* @private
|
|
4469
|
-
* @param {Function} func The function to have its output memoized.
|
|
4470
|
-
* @returns {Function} Returns the new memoized function.
|
|
4471
|
-
*/
|
|
4472
|
-
function memoizeCapped$1(func) {
|
|
4473
|
-
var result = memoize(func, function(key) {
|
|
4474
|
-
if (cache.size === MAX_MEMOIZE_SIZE) {
|
|
4475
|
-
cache.clear();
|
|
4476
|
-
}
|
|
4477
|
-
return key;
|
|
4478
|
-
});
|
|
4479
|
-
|
|
4480
|
-
var cache = result.cache;
|
|
4481
|
-
return result;
|
|
4482
|
-
}
|
|
4483
|
-
|
|
4484
|
-
var _memoizeCapped = memoizeCapped$1;
|
|
4485
|
-
|
|
4486
|
-
var memoizeCapped = _memoizeCapped;
|
|
4487
|
-
|
|
4488
|
-
/** Used to match property names within property paths. */
|
|
4489
|
-
var rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g;
|
|
4490
|
-
|
|
4491
|
-
/** Used to match backslashes in property paths. */
|
|
4492
|
-
var reEscapeChar = /\\(\\)?/g;
|
|
4493
|
-
|
|
4494
|
-
/**
|
|
4495
|
-
* Converts `string` to a property path array.
|
|
4496
|
-
*
|
|
4497
|
-
* @private
|
|
4498
|
-
* @param {string} string The string to convert.
|
|
4499
|
-
* @returns {Array} Returns the property path array.
|
|
4500
|
-
*/
|
|
4501
|
-
memoizeCapped(function(string) {
|
|
4502
|
-
var result = [];
|
|
4503
|
-
if (string.charCodeAt(0) === 46 /* . */) {
|
|
4504
|
-
result.push('');
|
|
4505
|
-
}
|
|
4506
|
-
string.replace(rePropName, function(match, number, quote, subString) {
|
|
4507
|
-
result.push(quote ? subString.replace(reEscapeChar, '$1') : (number || match));
|
|
4508
|
-
});
|
|
4509
|
-
return result;
|
|
4510
|
-
});
|
|
4511
|
-
|
|
4512
|
-
var Symbol$1 = _Symbol;
|
|
4513
|
-
|
|
4514
|
-
/** Used to convert symbols to primitives and strings. */
|
|
4515
|
-
var symbolProto = Symbol$1 ? Symbol$1.prototype : undefined;
|
|
4516
|
-
symbolProto ? symbolProto.toString : undefined;
|
|
4517
|
-
|
|
4518
|
-
var baseGetTag$1 = _baseGetTag,
|
|
4519
|
-
isObjectLike$1 = isObjectLike_1;
|
|
4520
|
-
|
|
4521
|
-
/** `Object#toString` result references. */
|
|
4522
|
-
var argsTag = '[object Arguments]';
|
|
4523
|
-
|
|
4524
|
-
/**
|
|
4525
|
-
* The base implementation of `_.isArguments`.
|
|
4526
|
-
*
|
|
4527
|
-
* @private
|
|
4528
|
-
* @param {*} value The value to check.
|
|
4529
|
-
* @returns {boolean} Returns `true` if `value` is an `arguments` object,
|
|
4530
|
-
*/
|
|
4531
|
-
function baseIsArguments$1(value) {
|
|
4532
|
-
return isObjectLike$1(value) && baseGetTag$1(value) == argsTag;
|
|
4533
|
-
}
|
|
4534
|
-
|
|
4535
|
-
var _baseIsArguments = baseIsArguments$1;
|
|
4536
|
-
|
|
4537
|
-
var baseIsArguments = _baseIsArguments,
|
|
4538
|
-
isObjectLike = isObjectLike_1;
|
|
4539
|
-
|
|
4540
|
-
/** Used for built-in method references. */
|
|
4541
|
-
var objectProto = Object.prototype;
|
|
4542
|
-
|
|
4543
|
-
/** Used to check objects for own properties. */
|
|
4544
|
-
var hasOwnProperty = objectProto.hasOwnProperty;
|
|
4545
|
-
|
|
4546
|
-
/** Built-in value references. */
|
|
4547
|
-
var propertyIsEnumerable = objectProto.propertyIsEnumerable;
|
|
4548
|
-
|
|
4549
|
-
/**
|
|
4550
|
-
* Checks if `value` is likely an `arguments` object.
|
|
4551
|
-
*
|
|
4552
|
-
* @static
|
|
4553
|
-
* @memberOf _
|
|
4554
|
-
* @since 0.1.0
|
|
4555
|
-
* @category Lang
|
|
4556
|
-
* @param {*} value The value to check.
|
|
4557
|
-
* @returns {boolean} Returns `true` if `value` is an `arguments` object,
|
|
4558
|
-
* else `false`.
|
|
4559
|
-
* @example
|
|
4560
|
-
*
|
|
4561
|
-
* _.isArguments(function() { return arguments; }());
|
|
4562
|
-
* // => true
|
|
4563
|
-
*
|
|
4564
|
-
* _.isArguments([1, 2, 3]);
|
|
4565
|
-
* // => false
|
|
4566
|
-
*/
|
|
4567
|
-
baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {
|
|
4568
|
-
return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&
|
|
4569
|
-
!propertyIsEnumerable.call(value, 'callee');
|
|
4570
|
-
};
|
|
4571
|
-
|
|
4572
|
-
var isBuffer = {exports: {}};
|
|
4573
|
-
|
|
4574
|
-
/**
|
|
4575
|
-
* This method returns `false`.
|
|
4576
|
-
*
|
|
4577
|
-
* @static
|
|
4578
|
-
* @memberOf _
|
|
4579
|
-
* @since 4.13.0
|
|
4580
|
-
* @category Util
|
|
4581
|
-
* @returns {boolean} Returns `false`.
|
|
4582
|
-
* @example
|
|
4583
|
-
*
|
|
4584
|
-
* _.times(2, _.stubFalse);
|
|
4585
|
-
* // => [false, false]
|
|
4586
|
-
*/
|
|
4587
|
-
|
|
4588
|
-
function stubFalse() {
|
|
4589
|
-
return false;
|
|
4590
|
-
}
|
|
4591
|
-
|
|
4592
|
-
var stubFalse_1 = stubFalse;
|
|
4593
|
-
|
|
4594
|
-
(function (module, exports) {
|
|
4595
|
-
var root = _root,
|
|
4596
|
-
stubFalse = stubFalse_1;
|
|
4597
|
-
|
|
4598
|
-
/** Detect free variable `exports`. */
|
|
4599
|
-
var freeExports = exports && !exports.nodeType && exports;
|
|
4600
|
-
|
|
4601
|
-
/** Detect free variable `module`. */
|
|
4602
|
-
var freeModule = freeExports && 'object' == 'object' && module && !module.nodeType && module;
|
|
4603
|
-
|
|
4604
|
-
/** Detect the popular CommonJS extension `module.exports`. */
|
|
4605
|
-
var moduleExports = freeModule && freeModule.exports === freeExports;
|
|
4606
|
-
|
|
4607
|
-
/** Built-in value references. */
|
|
4608
|
-
var Buffer = moduleExports ? root.Buffer : undefined;
|
|
4609
|
-
|
|
4610
|
-
/* Built-in method references for those with the same name as other `lodash` methods. */
|
|
4611
|
-
var nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;
|
|
4612
|
-
|
|
4613
|
-
/**
|
|
4614
|
-
* Checks if `value` is a buffer.
|
|
4615
|
-
*
|
|
4616
|
-
* @static
|
|
4617
|
-
* @memberOf _
|
|
4618
|
-
* @since 4.3.0
|
|
4619
|
-
* @category Lang
|
|
4620
|
-
* @param {*} value The value to check.
|
|
4621
|
-
* @returns {boolean} Returns `true` if `value` is a buffer, else `false`.
|
|
4622
|
-
* @example
|
|
4623
|
-
*
|
|
4624
|
-
* _.isBuffer(new Buffer(2));
|
|
4625
|
-
* // => true
|
|
4626
|
-
*
|
|
4627
|
-
* _.isBuffer(new Uint8Array(2));
|
|
4628
|
-
* // => false
|
|
4629
|
-
*/
|
|
4630
|
-
var isBuffer = nativeIsBuffer || stubFalse;
|
|
4631
|
-
|
|
4632
|
-
module.exports = isBuffer;
|
|
4633
|
-
}(isBuffer, isBuffer.exports));
|
|
4634
|
-
|
|
4635
|
-
var _nodeUtil = {exports: {}};
|
|
4636
|
-
|
|
4637
|
-
(function (module, exports) {
|
|
4638
|
-
var freeGlobal = _freeGlobal;
|
|
4639
|
-
|
|
4640
|
-
/** Detect free variable `exports`. */
|
|
4641
|
-
var freeExports = exports && !exports.nodeType && exports;
|
|
4642
|
-
|
|
4643
|
-
/** Detect free variable `module`. */
|
|
4644
|
-
var freeModule = freeExports && 'object' == 'object' && module && !module.nodeType && module;
|
|
4645
|
-
|
|
4646
|
-
/** Detect the popular CommonJS extension `module.exports`. */
|
|
4647
|
-
var moduleExports = freeModule && freeModule.exports === freeExports;
|
|
4648
|
-
|
|
4649
|
-
/** Detect free variable `process` from Node.js. */
|
|
4650
|
-
var freeProcess = moduleExports && freeGlobal.process;
|
|
4651
|
-
|
|
4652
|
-
/** Used to access faster Node.js helpers. */
|
|
4653
|
-
var nodeUtil = (function() {
|
|
4654
|
-
try {
|
|
4655
|
-
// Use `util.types` for Node.js 10+.
|
|
4656
|
-
var types = freeModule && freeModule.require && freeModule.require('util').types;
|
|
4657
|
-
|
|
4658
|
-
if (types) {
|
|
4659
|
-
return types;
|
|
4660
|
-
}
|
|
4661
|
-
|
|
4662
|
-
// Legacy `process.binding('util')` for Node.js < 10.
|
|
4663
|
-
return freeProcess && freeProcess.binding && freeProcess.binding('util');
|
|
4664
|
-
} catch (e) {}
|
|
4665
|
-
}());
|
|
4666
|
-
|
|
4667
|
-
module.exports = nodeUtil;
|
|
4668
|
-
}(_nodeUtil, _nodeUtil.exports));
|
|
4669
|
-
|
|
4670
|
-
var nodeUtil = _nodeUtil.exports;
|
|
4671
|
-
|
|
4672
|
-
/* Node.js helper references. */
|
|
4673
|
-
nodeUtil && nodeUtil.isTypedArray;
|
|
4674
|
-
|
|
4675
|
-
var getNative$3 = _getNative,
|
|
4676
|
-
root$3 = _root;
|
|
4677
|
-
|
|
4678
|
-
/* Built-in method references that are verified to be native. */
|
|
4679
|
-
var DataView$1 = getNative$3(root$3, 'DataView');
|
|
4680
|
-
|
|
4681
|
-
var _DataView = DataView$1;
|
|
4682
|
-
|
|
4683
|
-
var getNative$2 = _getNative,
|
|
4684
|
-
root$2 = _root;
|
|
4685
|
-
|
|
4686
|
-
/* Built-in method references that are verified to be native. */
|
|
4687
|
-
var Promise$2 = getNative$2(root$2, 'Promise');
|
|
4688
|
-
|
|
4689
|
-
var _Promise = Promise$2;
|
|
4690
|
-
|
|
4691
|
-
var getNative$1 = _getNative,
|
|
4692
|
-
root$1 = _root;
|
|
4693
|
-
|
|
4694
|
-
/* Built-in method references that are verified to be native. */
|
|
4695
|
-
var Set$1 = getNative$1(root$1, 'Set');
|
|
4696
|
-
|
|
4697
|
-
var _Set = Set$1;
|
|
4698
|
-
|
|
4699
|
-
var getNative = _getNative,
|
|
4700
|
-
root = _root;
|
|
4701
|
-
|
|
4702
|
-
/* Built-in method references that are verified to be native. */
|
|
4703
|
-
var WeakMap$1 = getNative(root, 'WeakMap');
|
|
4704
|
-
|
|
4705
|
-
var _WeakMap = WeakMap$1;
|
|
4706
|
-
|
|
4707
|
-
var DataView = _DataView,
|
|
4708
|
-
Map$1 = _Map,
|
|
4709
|
-
Promise$1 = _Promise,
|
|
4710
|
-
Set = _Set,
|
|
4711
|
-
WeakMap = _WeakMap,
|
|
4712
|
-
baseGetTag = _baseGetTag,
|
|
4713
|
-
toSource = _toSource;
|
|
4714
|
-
|
|
4715
|
-
/** `Object#toString` result references. */
|
|
4716
|
-
var mapTag = '[object Map]',
|
|
4717
|
-
objectTag = '[object Object]',
|
|
4718
|
-
promiseTag = '[object Promise]',
|
|
4719
|
-
setTag = '[object Set]',
|
|
4720
|
-
weakMapTag = '[object WeakMap]';
|
|
4721
|
-
|
|
4722
|
-
var dataViewTag = '[object DataView]';
|
|
4723
|
-
|
|
4724
|
-
/** Used to detect maps, sets, and weakmaps. */
|
|
4725
|
-
var dataViewCtorString = toSource(DataView),
|
|
4726
|
-
mapCtorString = toSource(Map$1),
|
|
4727
|
-
promiseCtorString = toSource(Promise$1),
|
|
4728
|
-
setCtorString = toSource(Set),
|
|
4729
|
-
weakMapCtorString = toSource(WeakMap);
|
|
4730
|
-
|
|
4731
|
-
/**
|
|
4732
|
-
* Gets the `toStringTag` of `value`.
|
|
4733
|
-
*
|
|
4734
|
-
* @private
|
|
4735
|
-
* @param {*} value The value to query.
|
|
4736
|
-
* @returns {string} Returns the `toStringTag`.
|
|
4737
|
-
*/
|
|
4738
|
-
var getTag = baseGetTag;
|
|
4739
|
-
|
|
4740
|
-
// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.
|
|
4741
|
-
if ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||
|
|
4742
|
-
(Map$1 && getTag(new Map$1) != mapTag) ||
|
|
4743
|
-
(Promise$1 && getTag(Promise$1.resolve()) != promiseTag) ||
|
|
4744
|
-
(Set && getTag(new Set) != setTag) ||
|
|
4745
|
-
(WeakMap && getTag(new WeakMap) != weakMapTag)) {
|
|
4746
|
-
getTag = function(value) {
|
|
4747
|
-
var result = baseGetTag(value),
|
|
4748
|
-
Ctor = result == objectTag ? value.constructor : undefined,
|
|
4749
|
-
ctorString = Ctor ? toSource(Ctor) : '';
|
|
4750
|
-
|
|
4751
|
-
if (ctorString) {
|
|
4752
|
-
switch (ctorString) {
|
|
4753
|
-
case dataViewCtorString: return dataViewTag;
|
|
4754
|
-
case mapCtorString: return mapTag;
|
|
4755
|
-
case promiseCtorString: return promiseTag;
|
|
4756
|
-
case setCtorString: return setTag;
|
|
4757
|
-
case weakMapCtorString: return weakMapTag;
|
|
4758
|
-
}
|
|
4759
|
-
}
|
|
4760
|
-
return result;
|
|
4761
|
-
};
|
|
4762
|
-
}
|
|
4763
|
-
|
|
4764
3337
|
// eslint-disable-next-line no-console
|
|
4765
3338
|
const lg = (n) => console[n].bind(console, 'controller-utils:');
|
|
4766
3339
|
lg('debug');
|
|
@@ -4847,7 +3420,7 @@ const getCorrectness = (question, env, session) => {
|
|
|
4847
3420
|
};
|
|
4848
3421
|
|
|
4849
3422
|
const getPartialScore = (question, session) => {
|
|
4850
|
-
if (!session ||
|
|
3423
|
+
if (!session || isEmpty(session)) {
|
|
4851
3424
|
return 0;
|
|
4852
3425
|
}
|
|
4853
3426
|
|
|
@@ -4856,7 +3429,7 @@ const getPartialScore = (question, session) => {
|
|
|
4856
3429
|
|
|
4857
3430
|
const outcome = (question, session, env) =>
|
|
4858
3431
|
new Promise((resolve) => {
|
|
4859
|
-
if (!session ||
|
|
3432
|
+
if (!session || isEmpty(session)) {
|
|
4860
3433
|
resolve({ score: 0, empty: true });
|
|
4861
3434
|
}
|
|
4862
3435
|
const partialScoringEnabled = enabled(question, env);
|
|
@@ -5021,7 +3594,7 @@ const validate = (model = {}, config = {}) => {
|
|
|
5021
3594
|
}
|
|
5022
3595
|
});
|
|
5023
3596
|
|
|
5024
|
-
if (!
|
|
3597
|
+
if (!isEmpty(responseError) || !isEmpty(alternatesErrors)) {
|
|
5025
3598
|
responsesErrors[index] = { ...responseError, ...alternatesErrors };
|
|
5026
3599
|
}
|
|
5027
3600
|
});
|
|
@@ -5034,7 +3607,7 @@ const validate = (model = {}, config = {}) => {
|
|
|
5034
3607
|
errors.responseAreas = 'There should be at least 1 response area defined.';
|
|
5035
3608
|
}
|
|
5036
3609
|
|
|
5037
|
-
if (!
|
|
3610
|
+
if (!isEmpty(responsesErrors)) {
|
|
5038
3611
|
errors.responses = responsesErrors;
|
|
5039
3612
|
}
|
|
5040
3613
|
|