@vunk/form 2.0.2 → 2.2.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.
Files changed (62) hide show
  1. package/components/card-input-collection/index.cjs +256 -0
  2. package/components/card-input-collection/index.css +21 -0
  3. package/components/card-input-collection/index.d.ts +4 -0
  4. package/components/card-input-collection/index.mjs +250 -0
  5. package/components/card-input-collection/src/ctx.d.ts +82 -0
  6. package/components/card-input-collection/src/index.vue.d.ts +542 -0
  7. package/components/card-input-collection/src/types.d.ts +1 -0
  8. package/components/cascader/src/ctx.d.ts +1 -1
  9. package/components/cascader/src/index.vue.d.ts +1 -1
  10. package/components/checkbox/src/ctx.d.ts +1 -1
  11. package/components/checkbox/src/index.vue.d.ts +2 -2
  12. package/components/cloneDeep.cjs +2029 -0
  13. package/components/cloneDeep.mjs +2027 -0
  14. package/components/date-picker/src/ctx.d.ts +1 -1
  15. package/components/date-picker/src/index.vue.d.ts +2 -2
  16. package/components/esri-input-geojson/index.cjs +484 -2
  17. package/components/esri-input-geojson/index.mjs +483 -1
  18. package/components/esri-input-geojson/src/ctx.d.ts +1 -1
  19. package/components/esri-input-geojson/src/index.vue.d.ts +2 -2
  20. package/components/form/src/ctx.d.ts +1 -1
  21. package/components/form/src/index.vue.d.ts +1 -1
  22. package/components/index2.cjs +0 -19
  23. package/components/index2.mjs +1 -19
  24. package/components/input/src/ctx.d.ts +1 -1
  25. package/components/input/src/index.vue.d.ts +2 -2
  26. package/components/input-collection/index.cjs +4 -2029
  27. package/components/input-collection/index.mjs +4 -2029
  28. package/components/input-collection/src/index.vue.d.ts +1 -1
  29. package/components/input-link/src/index.vue.d.ts +1 -1
  30. package/components/input-number/src/ctx.d.ts +1 -1
  31. package/components/input-number/src/index.vue.d.ts +3 -3
  32. package/components/radio/src/index.vue.d.ts +1 -1
  33. package/components/select/index.cjs +12 -0
  34. package/components/select/index.d.ts +1 -0
  35. package/components/select/index.mjs +12 -1
  36. package/components/select/src/ctx.d.ts +2 -0
  37. package/components/select/src/index.vue.d.ts +2 -2
  38. package/components/slider/src/index.vue.d.ts +1 -1
  39. package/components/switch/src/index.vue.d.ts +1 -1
  40. package/components/tables-select/index.cjs +225 -0
  41. package/components/tables-select/index.css +3 -0
  42. package/components/tables-select/index.d.ts +4 -0
  43. package/components/tables-select/index.mjs +219 -0
  44. package/components/tables-select/src/ctx.d.ts +338 -0
  45. package/components/tables-select/src/index.vue.d.ts +4953 -0
  46. package/components/tables-select/src/types.d.ts +1 -0
  47. package/components/upload/index.mjs +1 -1
  48. package/components/upload-plus/index.mjs +1 -1
  49. package/components/vditor/src/index.vue.d.ts +1 -1
  50. package/index.css +26 -41
  51. package/package.json +17 -9
  52. package/shared/element-plus/ctx.d.ts +1 -1
  53. package/components/geoinput-update/index.cjs +0 -406
  54. package/components/geoinput-update/index.css +0 -40
  55. package/components/geoinput-update/index.d.ts +0 -5
  56. package/components/geoinput-update/index.mjs +0 -399
  57. package/components/geoinput-update/src/append.vue.d.ts +0 -815
  58. package/components/geoinput-update/src/ctx.d.ts +0 -219
  59. package/components/geoinput-update/src/index.vue.d.ts +0 -1143
  60. package/components/geoinput-update/src/types.d.ts +0 -6
  61. package/components/index3.cjs +0 -486
  62. package/components/index3.mjs +0 -484
@@ -0,0 +1,2027 @@
1
+ /** Detect free variable `global` from Node.js. */
2
+ var freeGlobal = typeof global == 'object' && global && global.Object === Object && global;
3
+
4
+ /** Detect free variable `self`. */
5
+ var freeSelf = typeof self == 'object' && self && self.Object === Object && self;
6
+
7
+ /** Used as a reference to the global object. */
8
+ var root = freeGlobal || freeSelf || Function('return this')();
9
+
10
+ /** Built-in value references. */
11
+ var Symbol = root.Symbol;
12
+
13
+ /** Used for built-in method references. */
14
+ var objectProto$b = Object.prototype;
15
+
16
+ /** Used to check objects for own properties. */
17
+ var hasOwnProperty$8 = objectProto$b.hasOwnProperty;
18
+
19
+ /**
20
+ * Used to resolve the
21
+ * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
22
+ * of values.
23
+ */
24
+ var nativeObjectToString$1 = objectProto$b.toString;
25
+
26
+ /** Built-in value references. */
27
+ var symToStringTag$1 = Symbol ? Symbol.toStringTag : undefined;
28
+
29
+ /**
30
+ * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.
31
+ *
32
+ * @private
33
+ * @param {*} value The value to query.
34
+ * @returns {string} Returns the raw `toStringTag`.
35
+ */
36
+ function getRawTag(value) {
37
+ var isOwn = hasOwnProperty$8.call(value, symToStringTag$1),
38
+ tag = value[symToStringTag$1];
39
+
40
+ try {
41
+ value[symToStringTag$1] = undefined;
42
+ var unmasked = true;
43
+ } catch (e) {}
44
+
45
+ var result = nativeObjectToString$1.call(value);
46
+ if (unmasked) {
47
+ if (isOwn) {
48
+ value[symToStringTag$1] = tag;
49
+ } else {
50
+ delete value[symToStringTag$1];
51
+ }
52
+ }
53
+ return result;
54
+ }
55
+
56
+ /** Used for built-in method references. */
57
+ var objectProto$a = Object.prototype;
58
+
59
+ /**
60
+ * Used to resolve the
61
+ * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
62
+ * of values.
63
+ */
64
+ var nativeObjectToString = objectProto$a.toString;
65
+
66
+ /**
67
+ * Converts `value` to a string using `Object.prototype.toString`.
68
+ *
69
+ * @private
70
+ * @param {*} value The value to convert.
71
+ * @returns {string} Returns the converted string.
72
+ */
73
+ function objectToString(value) {
74
+ return nativeObjectToString.call(value);
75
+ }
76
+
77
+ /** `Object#toString` result references. */
78
+ var nullTag = '[object Null]',
79
+ undefinedTag = '[object Undefined]';
80
+
81
+ /** Built-in value references. */
82
+ var symToStringTag = Symbol ? Symbol.toStringTag : undefined;
83
+
84
+ /**
85
+ * The base implementation of `getTag` without fallbacks for buggy environments.
86
+ *
87
+ * @private
88
+ * @param {*} value The value to query.
89
+ * @returns {string} Returns the `toStringTag`.
90
+ */
91
+ function baseGetTag(value) {
92
+ if (value == null) {
93
+ return value === undefined ? undefinedTag : nullTag;
94
+ }
95
+ return (symToStringTag && symToStringTag in Object(value))
96
+ ? getRawTag(value)
97
+ : objectToString(value);
98
+ }
99
+
100
+ /**
101
+ * Checks if `value` is object-like. A value is object-like if it's not `null`
102
+ * and has a `typeof` result of "object".
103
+ *
104
+ * @static
105
+ * @memberOf _
106
+ * @since 4.0.0
107
+ * @category Lang
108
+ * @param {*} value The value to check.
109
+ * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
110
+ * @example
111
+ *
112
+ * _.isObjectLike({});
113
+ * // => true
114
+ *
115
+ * _.isObjectLike([1, 2, 3]);
116
+ * // => true
117
+ *
118
+ * _.isObjectLike(_.noop);
119
+ * // => false
120
+ *
121
+ * _.isObjectLike(null);
122
+ * // => false
123
+ */
124
+ function isObjectLike(value) {
125
+ return value != null && typeof value == 'object';
126
+ }
127
+
128
+ /**
129
+ * Checks if `value` is classified as an `Array` object.
130
+ *
131
+ * @static
132
+ * @memberOf _
133
+ * @since 0.1.0
134
+ * @category Lang
135
+ * @param {*} value The value to check.
136
+ * @returns {boolean} Returns `true` if `value` is an array, else `false`.
137
+ * @example
138
+ *
139
+ * _.isArray([1, 2, 3]);
140
+ * // => true
141
+ *
142
+ * _.isArray(document.body.children);
143
+ * // => false
144
+ *
145
+ * _.isArray('abc');
146
+ * // => false
147
+ *
148
+ * _.isArray(_.noop);
149
+ * // => false
150
+ */
151
+ var isArray = Array.isArray;
152
+
153
+ /**
154
+ * Checks if `value` is the
155
+ * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)
156
+ * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
157
+ *
158
+ * @static
159
+ * @memberOf _
160
+ * @since 0.1.0
161
+ * @category Lang
162
+ * @param {*} value The value to check.
163
+ * @returns {boolean} Returns `true` if `value` is an object, else `false`.
164
+ * @example
165
+ *
166
+ * _.isObject({});
167
+ * // => true
168
+ *
169
+ * _.isObject([1, 2, 3]);
170
+ * // => true
171
+ *
172
+ * _.isObject(_.noop);
173
+ * // => true
174
+ *
175
+ * _.isObject(null);
176
+ * // => false
177
+ */
178
+ function isObject(value) {
179
+ var type = typeof value;
180
+ return value != null && (type == 'object' || type == 'function');
181
+ }
182
+
183
+ /** `Object#toString` result references. */
184
+ var asyncTag = '[object AsyncFunction]',
185
+ funcTag$2 = '[object Function]',
186
+ genTag$1 = '[object GeneratorFunction]',
187
+ proxyTag = '[object Proxy]';
188
+
189
+ /**
190
+ * Checks if `value` is classified as a `Function` object.
191
+ *
192
+ * @static
193
+ * @memberOf _
194
+ * @since 0.1.0
195
+ * @category Lang
196
+ * @param {*} value The value to check.
197
+ * @returns {boolean} Returns `true` if `value` is a function, else `false`.
198
+ * @example
199
+ *
200
+ * _.isFunction(_);
201
+ * // => true
202
+ *
203
+ * _.isFunction(/abc/);
204
+ * // => false
205
+ */
206
+ function isFunction(value) {
207
+ if (!isObject(value)) {
208
+ return false;
209
+ }
210
+ // The use of `Object#toString` avoids issues with the `typeof` operator
211
+ // in Safari 9 which returns 'object' for typed arrays and other constructors.
212
+ var tag = baseGetTag(value);
213
+ return tag == funcTag$2 || tag == genTag$1 || tag == asyncTag || tag == proxyTag;
214
+ }
215
+
216
+ /** Used to detect overreaching core-js shims. */
217
+ var coreJsData = root['__core-js_shared__'];
218
+
219
+ /** Used to detect methods masquerading as native. */
220
+ var maskSrcKey = (function() {
221
+ var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');
222
+ return uid ? ('Symbol(src)_1.' + uid) : '';
223
+ }());
224
+
225
+ /**
226
+ * Checks if `func` has its source masked.
227
+ *
228
+ * @private
229
+ * @param {Function} func The function to check.
230
+ * @returns {boolean} Returns `true` if `func` is masked, else `false`.
231
+ */
232
+ function isMasked(func) {
233
+ return !!maskSrcKey && (maskSrcKey in func);
234
+ }
235
+
236
+ /** Used for built-in method references. */
237
+ var funcProto$1 = Function.prototype;
238
+
239
+ /** Used to resolve the decompiled source of functions. */
240
+ var funcToString$1 = funcProto$1.toString;
241
+
242
+ /**
243
+ * Converts `func` to its source code.
244
+ *
245
+ * @private
246
+ * @param {Function} func The function to convert.
247
+ * @returns {string} Returns the source code.
248
+ */
249
+ function toSource(func) {
250
+ if (func != null) {
251
+ try {
252
+ return funcToString$1.call(func);
253
+ } catch (e) {}
254
+ try {
255
+ return (func + '');
256
+ } catch (e) {}
257
+ }
258
+ return '';
259
+ }
260
+
261
+ /**
262
+ * Used to match `RegExp`
263
+ * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).
264
+ */
265
+ var reRegExpChar = /[\\^$.*+?()[\]{}|]/g;
266
+
267
+ /** Used to detect host constructors (Safari). */
268
+ var reIsHostCtor = /^\[object .+?Constructor\]$/;
269
+
270
+ /** Used for built-in method references. */
271
+ var funcProto = Function.prototype,
272
+ objectProto$9 = Object.prototype;
273
+
274
+ /** Used to resolve the decompiled source of functions. */
275
+ var funcToString = funcProto.toString;
276
+
277
+ /** Used to check objects for own properties. */
278
+ var hasOwnProperty$7 = objectProto$9.hasOwnProperty;
279
+
280
+ /** Used to detect if a method is native. */
281
+ var reIsNative = RegExp('^' +
282
+ funcToString.call(hasOwnProperty$7).replace(reRegExpChar, '\\$&')
283
+ .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'
284
+ );
285
+
286
+ /**
287
+ * The base implementation of `_.isNative` without bad shim checks.
288
+ *
289
+ * @private
290
+ * @param {*} value The value to check.
291
+ * @returns {boolean} Returns `true` if `value` is a native function,
292
+ * else `false`.
293
+ */
294
+ function baseIsNative(value) {
295
+ if (!isObject(value) || isMasked(value)) {
296
+ return false;
297
+ }
298
+ var pattern = isFunction(value) ? reIsNative : reIsHostCtor;
299
+ return pattern.test(toSource(value));
300
+ }
301
+
302
+ /**
303
+ * Gets the value at `key` of `object`.
304
+ *
305
+ * @private
306
+ * @param {Object} [object] The object to query.
307
+ * @param {string} key The key of the property to get.
308
+ * @returns {*} Returns the property value.
309
+ */
310
+ function getValue(object, key) {
311
+ return object == null ? undefined : object[key];
312
+ }
313
+
314
+ /**
315
+ * Gets the native function at `key` of `object`.
316
+ *
317
+ * @private
318
+ * @param {Object} object The object to query.
319
+ * @param {string} key The key of the method to get.
320
+ * @returns {*} Returns the function if it's native, else `undefined`.
321
+ */
322
+ function getNative(object, key) {
323
+ var value = getValue(object, key);
324
+ return baseIsNative(value) ? value : undefined;
325
+ }
326
+
327
+ /* Built-in method references that are verified to be native. */
328
+ var WeakMap = getNative(root, 'WeakMap');
329
+
330
+ /** Built-in value references. */
331
+ var objectCreate = Object.create;
332
+
333
+ /**
334
+ * The base implementation of `_.create` without support for assigning
335
+ * properties to the created object.
336
+ *
337
+ * @private
338
+ * @param {Object} proto The object to inherit from.
339
+ * @returns {Object} Returns the new object.
340
+ */
341
+ var baseCreate = (function() {
342
+ function object() {}
343
+ return function(proto) {
344
+ if (!isObject(proto)) {
345
+ return {};
346
+ }
347
+ if (objectCreate) {
348
+ return objectCreate(proto);
349
+ }
350
+ object.prototype = proto;
351
+ var result = new object;
352
+ object.prototype = undefined;
353
+ return result;
354
+ };
355
+ }());
356
+
357
+ var defineProperty = (function() {
358
+ try {
359
+ var func = getNative(Object, 'defineProperty');
360
+ func({}, '', {});
361
+ return func;
362
+ } catch (e) {}
363
+ }());
364
+
365
+ /**
366
+ * A specialized version of `_.forEach` for arrays without support for
367
+ * iteratee shorthands.
368
+ *
369
+ * @private
370
+ * @param {Array} [array] The array to iterate over.
371
+ * @param {Function} iteratee The function invoked per iteration.
372
+ * @returns {Array} Returns `array`.
373
+ */
374
+ function arrayEach(array, iteratee) {
375
+ var index = -1,
376
+ length = array == null ? 0 : array.length;
377
+
378
+ while (++index < length) {
379
+ if (iteratee(array[index], index, array) === false) {
380
+ break;
381
+ }
382
+ }
383
+ return array;
384
+ }
385
+
386
+ /** Used as references for various `Number` constants. */
387
+ var MAX_SAFE_INTEGER$1 = 9007199254740991;
388
+
389
+ /** Used to detect unsigned integer values. */
390
+ var reIsUint = /^(?:0|[1-9]\d*)$/;
391
+
392
+ /**
393
+ * Checks if `value` is a valid array-like index.
394
+ *
395
+ * @private
396
+ * @param {*} value The value to check.
397
+ * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.
398
+ * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.
399
+ */
400
+ function isIndex(value, length) {
401
+ var type = typeof value;
402
+ length = length == null ? MAX_SAFE_INTEGER$1 : length;
403
+
404
+ return !!length &&
405
+ (type == 'number' ||
406
+ (type != 'symbol' && reIsUint.test(value))) &&
407
+ (value > -1 && value % 1 == 0 && value < length);
408
+ }
409
+
410
+ /**
411
+ * The base implementation of `assignValue` and `assignMergeValue` without
412
+ * value checks.
413
+ *
414
+ * @private
415
+ * @param {Object} object The object to modify.
416
+ * @param {string} key The key of the property to assign.
417
+ * @param {*} value The value to assign.
418
+ */
419
+ function baseAssignValue(object, key, value) {
420
+ if (key == '__proto__' && defineProperty) {
421
+ defineProperty(object, key, {
422
+ 'configurable': true,
423
+ 'enumerable': true,
424
+ 'value': value,
425
+ 'writable': true
426
+ });
427
+ } else {
428
+ object[key] = value;
429
+ }
430
+ }
431
+
432
+ /**
433
+ * Performs a
434
+ * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
435
+ * comparison between two values to determine if they are equivalent.
436
+ *
437
+ * @static
438
+ * @memberOf _
439
+ * @since 4.0.0
440
+ * @category Lang
441
+ * @param {*} value The value to compare.
442
+ * @param {*} other The other value to compare.
443
+ * @returns {boolean} Returns `true` if the values are equivalent, else `false`.
444
+ * @example
445
+ *
446
+ * var object = { 'a': 1 };
447
+ * var other = { 'a': 1 };
448
+ *
449
+ * _.eq(object, object);
450
+ * // => true
451
+ *
452
+ * _.eq(object, other);
453
+ * // => false
454
+ *
455
+ * _.eq('a', 'a');
456
+ * // => true
457
+ *
458
+ * _.eq('a', Object('a'));
459
+ * // => false
460
+ *
461
+ * _.eq(NaN, NaN);
462
+ * // => true
463
+ */
464
+ function eq(value, other) {
465
+ return value === other || (value !== value && other !== other);
466
+ }
467
+
468
+ /** Used for built-in method references. */
469
+ var objectProto$8 = Object.prototype;
470
+
471
+ /** Used to check objects for own properties. */
472
+ var hasOwnProperty$6 = objectProto$8.hasOwnProperty;
473
+
474
+ /**
475
+ * Assigns `value` to `key` of `object` if the existing value is not equivalent
476
+ * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
477
+ * for equality comparisons.
478
+ *
479
+ * @private
480
+ * @param {Object} object The object to modify.
481
+ * @param {string} key The key of the property to assign.
482
+ * @param {*} value The value to assign.
483
+ */
484
+ function assignValue(object, key, value) {
485
+ var objValue = object[key];
486
+ if (!(hasOwnProperty$6.call(object, key) && eq(objValue, value)) ||
487
+ (value === undefined && !(key in object))) {
488
+ baseAssignValue(object, key, value);
489
+ }
490
+ }
491
+
492
+ /** Used as references for various `Number` constants. */
493
+ var MAX_SAFE_INTEGER = 9007199254740991;
494
+
495
+ /**
496
+ * Checks if `value` is a valid array-like length.
497
+ *
498
+ * **Note:** This method is loosely based on
499
+ * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).
500
+ *
501
+ * @static
502
+ * @memberOf _
503
+ * @since 4.0.0
504
+ * @category Lang
505
+ * @param {*} value The value to check.
506
+ * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.
507
+ * @example
508
+ *
509
+ * _.isLength(3);
510
+ * // => true
511
+ *
512
+ * _.isLength(Number.MIN_VALUE);
513
+ * // => false
514
+ *
515
+ * _.isLength(Infinity);
516
+ * // => false
517
+ *
518
+ * _.isLength('3');
519
+ * // => false
520
+ */
521
+ function isLength(value) {
522
+ return typeof value == 'number' &&
523
+ value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
524
+ }
525
+
526
+ /**
527
+ * Checks if `value` is array-like. A value is considered array-like if it's
528
+ * not a function and has a `value.length` that's an integer greater than or
529
+ * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.
530
+ *
531
+ * @static
532
+ * @memberOf _
533
+ * @since 4.0.0
534
+ * @category Lang
535
+ * @param {*} value The value to check.
536
+ * @returns {boolean} Returns `true` if `value` is array-like, else `false`.
537
+ * @example
538
+ *
539
+ * _.isArrayLike([1, 2, 3]);
540
+ * // => true
541
+ *
542
+ * _.isArrayLike(document.body.children);
543
+ * // => true
544
+ *
545
+ * _.isArrayLike('abc');
546
+ * // => true
547
+ *
548
+ * _.isArrayLike(_.noop);
549
+ * // => false
550
+ */
551
+ function isArrayLike(value) {
552
+ return value != null && isLength(value.length) && !isFunction(value);
553
+ }
554
+
555
+ /** Used for built-in method references. */
556
+ var objectProto$7 = Object.prototype;
557
+
558
+ /**
559
+ * Checks if `value` is likely a prototype object.
560
+ *
561
+ * @private
562
+ * @param {*} value The value to check.
563
+ * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.
564
+ */
565
+ function isPrototype(value) {
566
+ var Ctor = value && value.constructor,
567
+ proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto$7;
568
+
569
+ return value === proto;
570
+ }
571
+
572
+ /**
573
+ * The base implementation of `_.times` without support for iteratee shorthands
574
+ * or max array length checks.
575
+ *
576
+ * @private
577
+ * @param {number} n The number of times to invoke `iteratee`.
578
+ * @param {Function} iteratee The function invoked per iteration.
579
+ * @returns {Array} Returns the array of results.
580
+ */
581
+ function baseTimes(n, iteratee) {
582
+ var index = -1,
583
+ result = Array(n);
584
+
585
+ while (++index < n) {
586
+ result[index] = iteratee(index);
587
+ }
588
+ return result;
589
+ }
590
+
591
+ /** `Object#toString` result references. */
592
+ var argsTag$2 = '[object Arguments]';
593
+
594
+ /**
595
+ * The base implementation of `_.isArguments`.
596
+ *
597
+ * @private
598
+ * @param {*} value The value to check.
599
+ * @returns {boolean} Returns `true` if `value` is an `arguments` object,
600
+ */
601
+ function baseIsArguments(value) {
602
+ return isObjectLike(value) && baseGetTag(value) == argsTag$2;
603
+ }
604
+
605
+ /** Used for built-in method references. */
606
+ var objectProto$6 = Object.prototype;
607
+
608
+ /** Used to check objects for own properties. */
609
+ var hasOwnProperty$5 = objectProto$6.hasOwnProperty;
610
+
611
+ /** Built-in value references. */
612
+ var propertyIsEnumerable$1 = objectProto$6.propertyIsEnumerable;
613
+
614
+ /**
615
+ * Checks if `value` is likely an `arguments` object.
616
+ *
617
+ * @static
618
+ * @memberOf _
619
+ * @since 0.1.0
620
+ * @category Lang
621
+ * @param {*} value The value to check.
622
+ * @returns {boolean} Returns `true` if `value` is an `arguments` object,
623
+ * else `false`.
624
+ * @example
625
+ *
626
+ * _.isArguments(function() { return arguments; }());
627
+ * // => true
628
+ *
629
+ * _.isArguments([1, 2, 3]);
630
+ * // => false
631
+ */
632
+ var isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {
633
+ return isObjectLike(value) && hasOwnProperty$5.call(value, 'callee') &&
634
+ !propertyIsEnumerable$1.call(value, 'callee');
635
+ };
636
+
637
+ /**
638
+ * This method returns `false`.
639
+ *
640
+ * @static
641
+ * @memberOf _
642
+ * @since 4.13.0
643
+ * @category Util
644
+ * @returns {boolean} Returns `false`.
645
+ * @example
646
+ *
647
+ * _.times(2, _.stubFalse);
648
+ * // => [false, false]
649
+ */
650
+ function stubFalse() {
651
+ return false;
652
+ }
653
+
654
+ /** Detect free variable `exports`. */
655
+ var freeExports$2 = typeof exports == 'object' && exports && !exports.nodeType && exports;
656
+
657
+ /** Detect free variable `module`. */
658
+ var freeModule$2 = freeExports$2 && typeof module == 'object' && module && !module.nodeType && module;
659
+
660
+ /** Detect the popular CommonJS extension `module.exports`. */
661
+ var moduleExports$2 = freeModule$2 && freeModule$2.exports === freeExports$2;
662
+
663
+ /** Built-in value references. */
664
+ var Buffer$1 = moduleExports$2 ? root.Buffer : undefined;
665
+
666
+ /* Built-in method references for those with the same name as other `lodash` methods. */
667
+ var nativeIsBuffer = Buffer$1 ? Buffer$1.isBuffer : undefined;
668
+
669
+ /**
670
+ * Checks if `value` is a buffer.
671
+ *
672
+ * @static
673
+ * @memberOf _
674
+ * @since 4.3.0
675
+ * @category Lang
676
+ * @param {*} value The value to check.
677
+ * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.
678
+ * @example
679
+ *
680
+ * _.isBuffer(new Buffer(2));
681
+ * // => true
682
+ *
683
+ * _.isBuffer(new Uint8Array(2));
684
+ * // => false
685
+ */
686
+ var isBuffer = nativeIsBuffer || stubFalse;
687
+
688
+ /** `Object#toString` result references. */
689
+ var argsTag$1 = '[object Arguments]',
690
+ arrayTag$1 = '[object Array]',
691
+ boolTag$2 = '[object Boolean]',
692
+ dateTag$2 = '[object Date]',
693
+ errorTag$1 = '[object Error]',
694
+ funcTag$1 = '[object Function]',
695
+ mapTag$4 = '[object Map]',
696
+ numberTag$2 = '[object Number]',
697
+ objectTag$2 = '[object Object]',
698
+ regexpTag$2 = '[object RegExp]',
699
+ setTag$4 = '[object Set]',
700
+ stringTag$2 = '[object String]',
701
+ weakMapTag$2 = '[object WeakMap]';
702
+
703
+ var arrayBufferTag$2 = '[object ArrayBuffer]',
704
+ dataViewTag$3 = '[object DataView]',
705
+ float32Tag$2 = '[object Float32Array]',
706
+ float64Tag$2 = '[object Float64Array]',
707
+ int8Tag$2 = '[object Int8Array]',
708
+ int16Tag$2 = '[object Int16Array]',
709
+ int32Tag$2 = '[object Int32Array]',
710
+ uint8Tag$2 = '[object Uint8Array]',
711
+ uint8ClampedTag$2 = '[object Uint8ClampedArray]',
712
+ uint16Tag$2 = '[object Uint16Array]',
713
+ uint32Tag$2 = '[object Uint32Array]';
714
+
715
+ /** Used to identify `toStringTag` values of typed arrays. */
716
+ var typedArrayTags = {};
717
+ typedArrayTags[float32Tag$2] = typedArrayTags[float64Tag$2] =
718
+ typedArrayTags[int8Tag$2] = typedArrayTags[int16Tag$2] =
719
+ typedArrayTags[int32Tag$2] = typedArrayTags[uint8Tag$2] =
720
+ typedArrayTags[uint8ClampedTag$2] = typedArrayTags[uint16Tag$2] =
721
+ typedArrayTags[uint32Tag$2] = true;
722
+ typedArrayTags[argsTag$1] = typedArrayTags[arrayTag$1] =
723
+ typedArrayTags[arrayBufferTag$2] = typedArrayTags[boolTag$2] =
724
+ typedArrayTags[dataViewTag$3] = typedArrayTags[dateTag$2] =
725
+ typedArrayTags[errorTag$1] = typedArrayTags[funcTag$1] =
726
+ typedArrayTags[mapTag$4] = typedArrayTags[numberTag$2] =
727
+ typedArrayTags[objectTag$2] = typedArrayTags[regexpTag$2] =
728
+ typedArrayTags[setTag$4] = typedArrayTags[stringTag$2] =
729
+ typedArrayTags[weakMapTag$2] = false;
730
+
731
+ /**
732
+ * The base implementation of `_.isTypedArray` without Node.js optimizations.
733
+ *
734
+ * @private
735
+ * @param {*} value The value to check.
736
+ * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.
737
+ */
738
+ function baseIsTypedArray(value) {
739
+ return isObjectLike(value) &&
740
+ isLength(value.length) && !!typedArrayTags[baseGetTag(value)];
741
+ }
742
+
743
+ /**
744
+ * The base implementation of `_.unary` without support for storing metadata.
745
+ *
746
+ * @private
747
+ * @param {Function} func The function to cap arguments for.
748
+ * @returns {Function} Returns the new capped function.
749
+ */
750
+ function baseUnary(func) {
751
+ return function(value) {
752
+ return func(value);
753
+ };
754
+ }
755
+
756
+ /** Detect free variable `exports`. */
757
+ var freeExports$1 = typeof exports == 'object' && exports && !exports.nodeType && exports;
758
+
759
+ /** Detect free variable `module`. */
760
+ var freeModule$1 = freeExports$1 && typeof module == 'object' && module && !module.nodeType && module;
761
+
762
+ /** Detect the popular CommonJS extension `module.exports`. */
763
+ var moduleExports$1 = freeModule$1 && freeModule$1.exports === freeExports$1;
764
+
765
+ /** Detect free variable `process` from Node.js. */
766
+ var freeProcess = moduleExports$1 && freeGlobal.process;
767
+
768
+ /** Used to access faster Node.js helpers. */
769
+ var nodeUtil = (function() {
770
+ try {
771
+ // Use `util.types` for Node.js 10+.
772
+ var types = freeModule$1 && freeModule$1.require && freeModule$1.require('util').types;
773
+
774
+ if (types) {
775
+ return types;
776
+ }
777
+
778
+ // Legacy `process.binding('util')` for Node.js < 10.
779
+ return freeProcess && freeProcess.binding && freeProcess.binding('util');
780
+ } catch (e) {}
781
+ }());
782
+
783
+ /* Node.js helper references. */
784
+ var nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;
785
+
786
+ /**
787
+ * Checks if `value` is classified as a typed array.
788
+ *
789
+ * @static
790
+ * @memberOf _
791
+ * @since 3.0.0
792
+ * @category Lang
793
+ * @param {*} value The value to check.
794
+ * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.
795
+ * @example
796
+ *
797
+ * _.isTypedArray(new Uint8Array);
798
+ * // => true
799
+ *
800
+ * _.isTypedArray([]);
801
+ * // => false
802
+ */
803
+ var isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;
804
+
805
+ /** Used for built-in method references. */
806
+ var objectProto$5 = Object.prototype;
807
+
808
+ /** Used to check objects for own properties. */
809
+ var hasOwnProperty$4 = objectProto$5.hasOwnProperty;
810
+
811
+ /**
812
+ * Creates an array of the enumerable property names of the array-like `value`.
813
+ *
814
+ * @private
815
+ * @param {*} value The value to query.
816
+ * @param {boolean} inherited Specify returning inherited property names.
817
+ * @returns {Array} Returns the array of property names.
818
+ */
819
+ function arrayLikeKeys(value, inherited) {
820
+ var isArr = isArray(value),
821
+ isArg = !isArr && isArguments(value),
822
+ isBuff = !isArr && !isArg && isBuffer(value),
823
+ isType = !isArr && !isArg && !isBuff && isTypedArray(value),
824
+ skipIndexes = isArr || isArg || isBuff || isType,
825
+ result = skipIndexes ? baseTimes(value.length, String) : [],
826
+ length = result.length;
827
+
828
+ for (var key in value) {
829
+ if ((hasOwnProperty$4.call(value, key)) &&
830
+ !(skipIndexes && (
831
+ // Safari 9 has enumerable `arguments.length` in strict mode.
832
+ key == 'length' ||
833
+ // Node.js 0.10 has enumerable non-index properties on buffers.
834
+ (isBuff && (key == 'offset' || key == 'parent')) ||
835
+ // PhantomJS 2 has enumerable non-index properties on typed arrays.
836
+ (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||
837
+ // Skip index properties.
838
+ isIndex(key, length)
839
+ ))) {
840
+ result.push(key);
841
+ }
842
+ }
843
+ return result;
844
+ }
845
+
846
+ /**
847
+ * Creates a unary function that invokes `func` with its argument transformed.
848
+ *
849
+ * @private
850
+ * @param {Function} func The function to wrap.
851
+ * @param {Function} transform The argument transform.
852
+ * @returns {Function} Returns the new function.
853
+ */
854
+ function overArg(func, transform) {
855
+ return function(arg) {
856
+ return func(transform(arg));
857
+ };
858
+ }
859
+
860
+ /* Built-in method references for those with the same name as other `lodash` methods. */
861
+ var nativeKeys = overArg(Object.keys, Object);
862
+
863
+ /** Used for built-in method references. */
864
+ var objectProto$4 = Object.prototype;
865
+
866
+ /** Used to check objects for own properties. */
867
+ var hasOwnProperty$3 = objectProto$4.hasOwnProperty;
868
+
869
+ /**
870
+ * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.
871
+ *
872
+ * @private
873
+ * @param {Object} object The object to query.
874
+ * @returns {Array} Returns the array of property names.
875
+ */
876
+ function baseKeys(object) {
877
+ if (!isPrototype(object)) {
878
+ return nativeKeys(object);
879
+ }
880
+ var result = [];
881
+ for (var key in Object(object)) {
882
+ if (hasOwnProperty$3.call(object, key) && key != 'constructor') {
883
+ result.push(key);
884
+ }
885
+ }
886
+ return result;
887
+ }
888
+
889
+ /**
890
+ * Creates an array of the own enumerable property names of `object`.
891
+ *
892
+ * **Note:** Non-object values are coerced to objects. See the
893
+ * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)
894
+ * for more details.
895
+ *
896
+ * @static
897
+ * @since 0.1.0
898
+ * @memberOf _
899
+ * @category Object
900
+ * @param {Object} object The object to query.
901
+ * @returns {Array} Returns the array of property names.
902
+ * @example
903
+ *
904
+ * function Foo() {
905
+ * this.a = 1;
906
+ * this.b = 2;
907
+ * }
908
+ *
909
+ * Foo.prototype.c = 3;
910
+ *
911
+ * _.keys(new Foo);
912
+ * // => ['a', 'b'] (iteration order is not guaranteed)
913
+ *
914
+ * _.keys('hi');
915
+ * // => ['0', '1']
916
+ */
917
+ function keys(object) {
918
+ return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);
919
+ }
920
+
921
+ /* Built-in method references that are verified to be native. */
922
+ var nativeCreate = getNative(Object, 'create');
923
+
924
+ /**
925
+ * Removes all key-value entries from the hash.
926
+ *
927
+ * @private
928
+ * @name clear
929
+ * @memberOf Hash
930
+ */
931
+ function hashClear() {
932
+ this.__data__ = nativeCreate ? nativeCreate(null) : {};
933
+ this.size = 0;
934
+ }
935
+
936
+ /**
937
+ * Removes `key` and its value from the hash.
938
+ *
939
+ * @private
940
+ * @name delete
941
+ * @memberOf Hash
942
+ * @param {Object} hash The hash to modify.
943
+ * @param {string} key The key of the value to remove.
944
+ * @returns {boolean} Returns `true` if the entry was removed, else `false`.
945
+ */
946
+ function hashDelete(key) {
947
+ var result = this.has(key) && delete this.__data__[key];
948
+ this.size -= result ? 1 : 0;
949
+ return result;
950
+ }
951
+
952
+ /** Used to stand-in for `undefined` hash values. */
953
+ var HASH_UNDEFINED$1 = '__lodash_hash_undefined__';
954
+
955
+ /** Used for built-in method references. */
956
+ var objectProto$3 = Object.prototype;
957
+
958
+ /** Used to check objects for own properties. */
959
+ var hasOwnProperty$2 = objectProto$3.hasOwnProperty;
960
+
961
+ /**
962
+ * Gets the hash value for `key`.
963
+ *
964
+ * @private
965
+ * @name get
966
+ * @memberOf Hash
967
+ * @param {string} key The key of the value to get.
968
+ * @returns {*} Returns the entry value.
969
+ */
970
+ function hashGet(key) {
971
+ var data = this.__data__;
972
+ if (nativeCreate) {
973
+ var result = data[key];
974
+ return result === HASH_UNDEFINED$1 ? undefined : result;
975
+ }
976
+ return hasOwnProperty$2.call(data, key) ? data[key] : undefined;
977
+ }
978
+
979
+ /** Used for built-in method references. */
980
+ var objectProto$2 = Object.prototype;
981
+
982
+ /** Used to check objects for own properties. */
983
+ var hasOwnProperty$1 = objectProto$2.hasOwnProperty;
984
+
985
+ /**
986
+ * Checks if a hash value for `key` exists.
987
+ *
988
+ * @private
989
+ * @name has
990
+ * @memberOf Hash
991
+ * @param {string} key The key of the entry to check.
992
+ * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
993
+ */
994
+ function hashHas(key) {
995
+ var data = this.__data__;
996
+ return nativeCreate ? (data[key] !== undefined) : hasOwnProperty$1.call(data, key);
997
+ }
998
+
999
+ /** Used to stand-in for `undefined` hash values. */
1000
+ var HASH_UNDEFINED = '__lodash_hash_undefined__';
1001
+
1002
+ /**
1003
+ * Sets the hash `key` to `value`.
1004
+ *
1005
+ * @private
1006
+ * @name set
1007
+ * @memberOf Hash
1008
+ * @param {string} key The key of the value to set.
1009
+ * @param {*} value The value to set.
1010
+ * @returns {Object} Returns the hash instance.
1011
+ */
1012
+ function hashSet(key, value) {
1013
+ var data = this.__data__;
1014
+ this.size += this.has(key) ? 0 : 1;
1015
+ data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;
1016
+ return this;
1017
+ }
1018
+
1019
+ /**
1020
+ * Creates a hash object.
1021
+ *
1022
+ * @private
1023
+ * @constructor
1024
+ * @param {Array} [entries] The key-value pairs to cache.
1025
+ */
1026
+ function Hash(entries) {
1027
+ var index = -1,
1028
+ length = entries == null ? 0 : entries.length;
1029
+
1030
+ this.clear();
1031
+ while (++index < length) {
1032
+ var entry = entries[index];
1033
+ this.set(entry[0], entry[1]);
1034
+ }
1035
+ }
1036
+
1037
+ // Add methods to `Hash`.
1038
+ Hash.prototype.clear = hashClear;
1039
+ Hash.prototype['delete'] = hashDelete;
1040
+ Hash.prototype.get = hashGet;
1041
+ Hash.prototype.has = hashHas;
1042
+ Hash.prototype.set = hashSet;
1043
+
1044
+ /**
1045
+ * Removes all key-value entries from the list cache.
1046
+ *
1047
+ * @private
1048
+ * @name clear
1049
+ * @memberOf ListCache
1050
+ */
1051
+ function listCacheClear() {
1052
+ this.__data__ = [];
1053
+ this.size = 0;
1054
+ }
1055
+
1056
+ /**
1057
+ * Gets the index at which the `key` is found in `array` of key-value pairs.
1058
+ *
1059
+ * @private
1060
+ * @param {Array} array The array to inspect.
1061
+ * @param {*} key The key to search for.
1062
+ * @returns {number} Returns the index of the matched value, else `-1`.
1063
+ */
1064
+ function assocIndexOf(array, key) {
1065
+ var length = array.length;
1066
+ while (length--) {
1067
+ if (eq(array[length][0], key)) {
1068
+ return length;
1069
+ }
1070
+ }
1071
+ return -1;
1072
+ }
1073
+
1074
+ /** Used for built-in method references. */
1075
+ var arrayProto = Array.prototype;
1076
+
1077
+ /** Built-in value references. */
1078
+ var splice = arrayProto.splice;
1079
+
1080
+ /**
1081
+ * Removes `key` and its value from the list cache.
1082
+ *
1083
+ * @private
1084
+ * @name delete
1085
+ * @memberOf ListCache
1086
+ * @param {string} key The key of the value to remove.
1087
+ * @returns {boolean} Returns `true` if the entry was removed, else `false`.
1088
+ */
1089
+ function listCacheDelete(key) {
1090
+ var data = this.__data__,
1091
+ index = assocIndexOf(data, key);
1092
+
1093
+ if (index < 0) {
1094
+ return false;
1095
+ }
1096
+ var lastIndex = data.length - 1;
1097
+ if (index == lastIndex) {
1098
+ data.pop();
1099
+ } else {
1100
+ splice.call(data, index, 1);
1101
+ }
1102
+ --this.size;
1103
+ return true;
1104
+ }
1105
+
1106
+ /**
1107
+ * Gets the list cache value for `key`.
1108
+ *
1109
+ * @private
1110
+ * @name get
1111
+ * @memberOf ListCache
1112
+ * @param {string} key The key of the value to get.
1113
+ * @returns {*} Returns the entry value.
1114
+ */
1115
+ function listCacheGet(key) {
1116
+ var data = this.__data__,
1117
+ index = assocIndexOf(data, key);
1118
+
1119
+ return index < 0 ? undefined : data[index][1];
1120
+ }
1121
+
1122
+ /**
1123
+ * Checks if a list cache value for `key` exists.
1124
+ *
1125
+ * @private
1126
+ * @name has
1127
+ * @memberOf ListCache
1128
+ * @param {string} key The key of the entry to check.
1129
+ * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
1130
+ */
1131
+ function listCacheHas(key) {
1132
+ return assocIndexOf(this.__data__, key) > -1;
1133
+ }
1134
+
1135
+ /**
1136
+ * Sets the list cache `key` to `value`.
1137
+ *
1138
+ * @private
1139
+ * @name set
1140
+ * @memberOf ListCache
1141
+ * @param {string} key The key of the value to set.
1142
+ * @param {*} value The value to set.
1143
+ * @returns {Object} Returns the list cache instance.
1144
+ */
1145
+ function listCacheSet(key, value) {
1146
+ var data = this.__data__,
1147
+ index = assocIndexOf(data, key);
1148
+
1149
+ if (index < 0) {
1150
+ ++this.size;
1151
+ data.push([key, value]);
1152
+ } else {
1153
+ data[index][1] = value;
1154
+ }
1155
+ return this;
1156
+ }
1157
+
1158
+ /**
1159
+ * Creates an list cache object.
1160
+ *
1161
+ * @private
1162
+ * @constructor
1163
+ * @param {Array} [entries] The key-value pairs to cache.
1164
+ */
1165
+ function ListCache(entries) {
1166
+ var index = -1,
1167
+ length = entries == null ? 0 : entries.length;
1168
+
1169
+ this.clear();
1170
+ while (++index < length) {
1171
+ var entry = entries[index];
1172
+ this.set(entry[0], entry[1]);
1173
+ }
1174
+ }
1175
+
1176
+ // Add methods to `ListCache`.
1177
+ ListCache.prototype.clear = listCacheClear;
1178
+ ListCache.prototype['delete'] = listCacheDelete;
1179
+ ListCache.prototype.get = listCacheGet;
1180
+ ListCache.prototype.has = listCacheHas;
1181
+ ListCache.prototype.set = listCacheSet;
1182
+
1183
+ /* Built-in method references that are verified to be native. */
1184
+ var Map = getNative(root, 'Map');
1185
+
1186
+ /**
1187
+ * Removes all key-value entries from the map.
1188
+ *
1189
+ * @private
1190
+ * @name clear
1191
+ * @memberOf MapCache
1192
+ */
1193
+ function mapCacheClear() {
1194
+ this.size = 0;
1195
+ this.__data__ = {
1196
+ 'hash': new Hash,
1197
+ 'map': new (Map || ListCache),
1198
+ 'string': new Hash
1199
+ };
1200
+ }
1201
+
1202
+ /**
1203
+ * Checks if `value` is suitable for use as unique object key.
1204
+ *
1205
+ * @private
1206
+ * @param {*} value The value to check.
1207
+ * @returns {boolean} Returns `true` if `value` is suitable, else `false`.
1208
+ */
1209
+ function isKeyable(value) {
1210
+ var type = typeof value;
1211
+ return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')
1212
+ ? (value !== '__proto__')
1213
+ : (value === null);
1214
+ }
1215
+
1216
+ /**
1217
+ * Gets the data for `map`.
1218
+ *
1219
+ * @private
1220
+ * @param {Object} map The map to query.
1221
+ * @param {string} key The reference key.
1222
+ * @returns {*} Returns the map data.
1223
+ */
1224
+ function getMapData(map, key) {
1225
+ var data = map.__data__;
1226
+ return isKeyable(key)
1227
+ ? data[typeof key == 'string' ? 'string' : 'hash']
1228
+ : data.map;
1229
+ }
1230
+
1231
+ /**
1232
+ * Removes `key` and its value from the map.
1233
+ *
1234
+ * @private
1235
+ * @name delete
1236
+ * @memberOf MapCache
1237
+ * @param {string} key The key of the value to remove.
1238
+ * @returns {boolean} Returns `true` if the entry was removed, else `false`.
1239
+ */
1240
+ function mapCacheDelete(key) {
1241
+ var result = getMapData(this, key)['delete'](key);
1242
+ this.size -= result ? 1 : 0;
1243
+ return result;
1244
+ }
1245
+
1246
+ /**
1247
+ * Gets the map value for `key`.
1248
+ *
1249
+ * @private
1250
+ * @name get
1251
+ * @memberOf MapCache
1252
+ * @param {string} key The key of the value to get.
1253
+ * @returns {*} Returns the entry value.
1254
+ */
1255
+ function mapCacheGet(key) {
1256
+ return getMapData(this, key).get(key);
1257
+ }
1258
+
1259
+ /**
1260
+ * Checks if a map value for `key` exists.
1261
+ *
1262
+ * @private
1263
+ * @name has
1264
+ * @memberOf MapCache
1265
+ * @param {string} key The key of the entry to check.
1266
+ * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
1267
+ */
1268
+ function mapCacheHas(key) {
1269
+ return getMapData(this, key).has(key);
1270
+ }
1271
+
1272
+ /**
1273
+ * Sets the map `key` to `value`.
1274
+ *
1275
+ * @private
1276
+ * @name set
1277
+ * @memberOf MapCache
1278
+ * @param {string} key The key of the value to set.
1279
+ * @param {*} value The value to set.
1280
+ * @returns {Object} Returns the map cache instance.
1281
+ */
1282
+ function mapCacheSet(key, value) {
1283
+ var data = getMapData(this, key),
1284
+ size = data.size;
1285
+
1286
+ data.set(key, value);
1287
+ this.size += data.size == size ? 0 : 1;
1288
+ return this;
1289
+ }
1290
+
1291
+ /**
1292
+ * Creates a map cache object to store key-value pairs.
1293
+ *
1294
+ * @private
1295
+ * @constructor
1296
+ * @param {Array} [entries] The key-value pairs to cache.
1297
+ */
1298
+ function MapCache(entries) {
1299
+ var index = -1,
1300
+ length = entries == null ? 0 : entries.length;
1301
+
1302
+ this.clear();
1303
+ while (++index < length) {
1304
+ var entry = entries[index];
1305
+ this.set(entry[0], entry[1]);
1306
+ }
1307
+ }
1308
+
1309
+ // Add methods to `MapCache`.
1310
+ MapCache.prototype.clear = mapCacheClear;
1311
+ MapCache.prototype['delete'] = mapCacheDelete;
1312
+ MapCache.prototype.get = mapCacheGet;
1313
+ MapCache.prototype.has = mapCacheHas;
1314
+ MapCache.prototype.set = mapCacheSet;
1315
+
1316
+ /**
1317
+ * Appends the elements of `values` to `array`.
1318
+ *
1319
+ * @private
1320
+ * @param {Array} array The array to modify.
1321
+ * @param {Array} values The values to append.
1322
+ * @returns {Array} Returns `array`.
1323
+ */
1324
+ function arrayPush(array, values) {
1325
+ var index = -1,
1326
+ length = values.length,
1327
+ offset = array.length;
1328
+
1329
+ while (++index < length) {
1330
+ array[offset + index] = values[index];
1331
+ }
1332
+ return array;
1333
+ }
1334
+
1335
+ /** Built-in value references. */
1336
+ var getPrototype = overArg(Object.getPrototypeOf, Object);
1337
+
1338
+ /**
1339
+ * Removes all key-value entries from the stack.
1340
+ *
1341
+ * @private
1342
+ * @name clear
1343
+ * @memberOf Stack
1344
+ */
1345
+ function stackClear() {
1346
+ this.__data__ = new ListCache;
1347
+ this.size = 0;
1348
+ }
1349
+
1350
+ /**
1351
+ * Removes `key` and its value from the stack.
1352
+ *
1353
+ * @private
1354
+ * @name delete
1355
+ * @memberOf Stack
1356
+ * @param {string} key The key of the value to remove.
1357
+ * @returns {boolean} Returns `true` if the entry was removed, else `false`.
1358
+ */
1359
+ function stackDelete(key) {
1360
+ var data = this.__data__,
1361
+ result = data['delete'](key);
1362
+
1363
+ this.size = data.size;
1364
+ return result;
1365
+ }
1366
+
1367
+ /**
1368
+ * Gets the stack value for `key`.
1369
+ *
1370
+ * @private
1371
+ * @name get
1372
+ * @memberOf Stack
1373
+ * @param {string} key The key of the value to get.
1374
+ * @returns {*} Returns the entry value.
1375
+ */
1376
+ function stackGet(key) {
1377
+ return this.__data__.get(key);
1378
+ }
1379
+
1380
+ /**
1381
+ * Checks if a stack value for `key` exists.
1382
+ *
1383
+ * @private
1384
+ * @name has
1385
+ * @memberOf Stack
1386
+ * @param {string} key The key of the entry to check.
1387
+ * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
1388
+ */
1389
+ function stackHas(key) {
1390
+ return this.__data__.has(key);
1391
+ }
1392
+
1393
+ /** Used as the size to enable large array optimizations. */
1394
+ var LARGE_ARRAY_SIZE = 200;
1395
+
1396
+ /**
1397
+ * Sets the stack `key` to `value`.
1398
+ *
1399
+ * @private
1400
+ * @name set
1401
+ * @memberOf Stack
1402
+ * @param {string} key The key of the value to set.
1403
+ * @param {*} value The value to set.
1404
+ * @returns {Object} Returns the stack cache instance.
1405
+ */
1406
+ function stackSet(key, value) {
1407
+ var data = this.__data__;
1408
+ if (data instanceof ListCache) {
1409
+ var pairs = data.__data__;
1410
+ if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {
1411
+ pairs.push([key, value]);
1412
+ this.size = ++data.size;
1413
+ return this;
1414
+ }
1415
+ data = this.__data__ = new MapCache(pairs);
1416
+ }
1417
+ data.set(key, value);
1418
+ this.size = data.size;
1419
+ return this;
1420
+ }
1421
+
1422
+ /**
1423
+ * Creates a stack cache object to store key-value pairs.
1424
+ *
1425
+ * @private
1426
+ * @constructor
1427
+ * @param {Array} [entries] The key-value pairs to cache.
1428
+ */
1429
+ function Stack(entries) {
1430
+ var data = this.__data__ = new ListCache(entries);
1431
+ this.size = data.size;
1432
+ }
1433
+
1434
+ // Add methods to `Stack`.
1435
+ Stack.prototype.clear = stackClear;
1436
+ Stack.prototype['delete'] = stackDelete;
1437
+ Stack.prototype.get = stackGet;
1438
+ Stack.prototype.has = stackHas;
1439
+ Stack.prototype.set = stackSet;
1440
+
1441
+ /** Detect free variable `exports`. */
1442
+ var freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;
1443
+
1444
+ /** Detect free variable `module`. */
1445
+ var freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;
1446
+
1447
+ /** Detect the popular CommonJS extension `module.exports`. */
1448
+ var moduleExports = freeModule && freeModule.exports === freeExports;
1449
+
1450
+ /** Built-in value references. */
1451
+ var Buffer = moduleExports ? root.Buffer : undefined;
1452
+ Buffer ? Buffer.allocUnsafe : undefined;
1453
+
1454
+ /**
1455
+ * Creates a clone of `buffer`.
1456
+ *
1457
+ * @private
1458
+ * @param {Buffer} buffer The buffer to clone.
1459
+ * @param {boolean} [isDeep] Specify a deep clone.
1460
+ * @returns {Buffer} Returns the cloned buffer.
1461
+ */
1462
+ function cloneBuffer(buffer, isDeep) {
1463
+ {
1464
+ return buffer.slice();
1465
+ }
1466
+ }
1467
+
1468
+ /**
1469
+ * A specialized version of `_.filter` for arrays without support for
1470
+ * iteratee shorthands.
1471
+ *
1472
+ * @private
1473
+ * @param {Array} [array] The array to iterate over.
1474
+ * @param {Function} predicate The function invoked per iteration.
1475
+ * @returns {Array} Returns the new filtered array.
1476
+ */
1477
+ function arrayFilter(array, predicate) {
1478
+ var index = -1,
1479
+ length = array == null ? 0 : array.length,
1480
+ resIndex = 0,
1481
+ result = [];
1482
+
1483
+ while (++index < length) {
1484
+ var value = array[index];
1485
+ if (predicate(value, index, array)) {
1486
+ result[resIndex++] = value;
1487
+ }
1488
+ }
1489
+ return result;
1490
+ }
1491
+
1492
+ /**
1493
+ * This method returns a new empty array.
1494
+ *
1495
+ * @static
1496
+ * @memberOf _
1497
+ * @since 4.13.0
1498
+ * @category Util
1499
+ * @returns {Array} Returns the new empty array.
1500
+ * @example
1501
+ *
1502
+ * var arrays = _.times(2, _.stubArray);
1503
+ *
1504
+ * console.log(arrays);
1505
+ * // => [[], []]
1506
+ *
1507
+ * console.log(arrays[0] === arrays[1]);
1508
+ * // => false
1509
+ */
1510
+ function stubArray() {
1511
+ return [];
1512
+ }
1513
+
1514
+ /** Used for built-in method references. */
1515
+ var objectProto$1 = Object.prototype;
1516
+
1517
+ /** Built-in value references. */
1518
+ var propertyIsEnumerable = objectProto$1.propertyIsEnumerable;
1519
+
1520
+ /* Built-in method references for those with the same name as other `lodash` methods. */
1521
+ var nativeGetSymbols = Object.getOwnPropertySymbols;
1522
+
1523
+ /**
1524
+ * Creates an array of the own enumerable symbols of `object`.
1525
+ *
1526
+ * @private
1527
+ * @param {Object} object The object to query.
1528
+ * @returns {Array} Returns the array of symbols.
1529
+ */
1530
+ var getSymbols = !nativeGetSymbols ? stubArray : function(object) {
1531
+ if (object == null) {
1532
+ return [];
1533
+ }
1534
+ object = Object(object);
1535
+ return arrayFilter(nativeGetSymbols(object), function(symbol) {
1536
+ return propertyIsEnumerable.call(object, symbol);
1537
+ });
1538
+ };
1539
+
1540
+ /**
1541
+ * The base implementation of `getAllKeys` and `getAllKeysIn` which uses
1542
+ * `keysFunc` and `symbolsFunc` to get the enumerable property names and
1543
+ * symbols of `object`.
1544
+ *
1545
+ * @private
1546
+ * @param {Object} object The object to query.
1547
+ * @param {Function} keysFunc The function to get the keys of `object`.
1548
+ * @param {Function} symbolsFunc The function to get the symbols of `object`.
1549
+ * @returns {Array} Returns the array of property names and symbols.
1550
+ */
1551
+ function baseGetAllKeys(object, keysFunc, symbolsFunc) {
1552
+ var result = keysFunc(object);
1553
+ return isArray(object) ? result : arrayPush(result, symbolsFunc(object));
1554
+ }
1555
+
1556
+ /**
1557
+ * Creates an array of own enumerable property names and symbols of `object`.
1558
+ *
1559
+ * @private
1560
+ * @param {Object} object The object to query.
1561
+ * @returns {Array} Returns the array of property names and symbols.
1562
+ */
1563
+ function getAllKeys(object) {
1564
+ return baseGetAllKeys(object, keys, getSymbols);
1565
+ }
1566
+
1567
+ /* Built-in method references that are verified to be native. */
1568
+ var DataView = getNative(root, 'DataView');
1569
+
1570
+ /* Built-in method references that are verified to be native. */
1571
+ var Promise$1 = getNative(root, 'Promise');
1572
+
1573
+ /* Built-in method references that are verified to be native. */
1574
+ var Set = getNative(root, 'Set');
1575
+
1576
+ /** `Object#toString` result references. */
1577
+ var mapTag$3 = '[object Map]',
1578
+ objectTag$1 = '[object Object]',
1579
+ promiseTag = '[object Promise]',
1580
+ setTag$3 = '[object Set]',
1581
+ weakMapTag$1 = '[object WeakMap]';
1582
+
1583
+ var dataViewTag$2 = '[object DataView]';
1584
+
1585
+ /** Used to detect maps, sets, and weakmaps. */
1586
+ var dataViewCtorString = toSource(DataView),
1587
+ mapCtorString = toSource(Map),
1588
+ promiseCtorString = toSource(Promise$1),
1589
+ setCtorString = toSource(Set),
1590
+ weakMapCtorString = toSource(WeakMap);
1591
+
1592
+ /**
1593
+ * Gets the `toStringTag` of `value`.
1594
+ *
1595
+ * @private
1596
+ * @param {*} value The value to query.
1597
+ * @returns {string} Returns the `toStringTag`.
1598
+ */
1599
+ var getTag = baseGetTag;
1600
+
1601
+ // Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.
1602
+ if ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag$2) ||
1603
+ (Map && getTag(new Map) != mapTag$3) ||
1604
+ (Promise$1 && getTag(Promise$1.resolve()) != promiseTag) ||
1605
+ (Set && getTag(new Set) != setTag$3) ||
1606
+ (WeakMap && getTag(new WeakMap) != weakMapTag$1)) {
1607
+ getTag = function(value) {
1608
+ var result = baseGetTag(value),
1609
+ Ctor = result == objectTag$1 ? value.constructor : undefined,
1610
+ ctorString = Ctor ? toSource(Ctor) : '';
1611
+
1612
+ if (ctorString) {
1613
+ switch (ctorString) {
1614
+ case dataViewCtorString: return dataViewTag$2;
1615
+ case mapCtorString: return mapTag$3;
1616
+ case promiseCtorString: return promiseTag;
1617
+ case setCtorString: return setTag$3;
1618
+ case weakMapCtorString: return weakMapTag$1;
1619
+ }
1620
+ }
1621
+ return result;
1622
+ };
1623
+ }
1624
+
1625
+ var getTag$1 = getTag;
1626
+
1627
+ /** Used for built-in method references. */
1628
+ var objectProto = Object.prototype;
1629
+
1630
+ /** Used to check objects for own properties. */
1631
+ var hasOwnProperty = objectProto.hasOwnProperty;
1632
+
1633
+ /**
1634
+ * Initializes an array clone.
1635
+ *
1636
+ * @private
1637
+ * @param {Array} array The array to clone.
1638
+ * @returns {Array} Returns the initialized clone.
1639
+ */
1640
+ function initCloneArray(array) {
1641
+ var length = array.length,
1642
+ result = new array.constructor(length);
1643
+
1644
+ // Add properties assigned by `RegExp#exec`.
1645
+ if (length && typeof array[0] == 'string' && hasOwnProperty.call(array, 'index')) {
1646
+ result.index = array.index;
1647
+ result.input = array.input;
1648
+ }
1649
+ return result;
1650
+ }
1651
+
1652
+ /** Built-in value references. */
1653
+ var Uint8Array = root.Uint8Array;
1654
+
1655
+ /**
1656
+ * Creates a clone of `arrayBuffer`.
1657
+ *
1658
+ * @private
1659
+ * @param {ArrayBuffer} arrayBuffer The array buffer to clone.
1660
+ * @returns {ArrayBuffer} Returns the cloned array buffer.
1661
+ */
1662
+ function cloneArrayBuffer(arrayBuffer) {
1663
+ var result = new arrayBuffer.constructor(arrayBuffer.byteLength);
1664
+ new Uint8Array(result).set(new Uint8Array(arrayBuffer));
1665
+ return result;
1666
+ }
1667
+
1668
+ /**
1669
+ * Creates a clone of `dataView`.
1670
+ *
1671
+ * @private
1672
+ * @param {Object} dataView The data view to clone.
1673
+ * @param {boolean} [isDeep] Specify a deep clone.
1674
+ * @returns {Object} Returns the cloned data view.
1675
+ */
1676
+ function cloneDataView(dataView, isDeep) {
1677
+ var buffer = cloneArrayBuffer(dataView.buffer) ;
1678
+ return new dataView.constructor(buffer, dataView.byteOffset, dataView.byteLength);
1679
+ }
1680
+
1681
+ /** Used to match `RegExp` flags from their coerced string values. */
1682
+ var reFlags = /\w*$/;
1683
+
1684
+ /**
1685
+ * Creates a clone of `regexp`.
1686
+ *
1687
+ * @private
1688
+ * @param {Object} regexp The regexp to clone.
1689
+ * @returns {Object} Returns the cloned regexp.
1690
+ */
1691
+ function cloneRegExp(regexp) {
1692
+ var result = new regexp.constructor(regexp.source, reFlags.exec(regexp));
1693
+ result.lastIndex = regexp.lastIndex;
1694
+ return result;
1695
+ }
1696
+
1697
+ /** Used to convert symbols to primitives and strings. */
1698
+ var symbolProto = Symbol ? Symbol.prototype : undefined,
1699
+ symbolValueOf = symbolProto ? symbolProto.valueOf : undefined;
1700
+
1701
+ /**
1702
+ * Creates a clone of the `symbol` object.
1703
+ *
1704
+ * @private
1705
+ * @param {Object} symbol The symbol object to clone.
1706
+ * @returns {Object} Returns the cloned symbol object.
1707
+ */
1708
+ function cloneSymbol(symbol) {
1709
+ return symbolValueOf ? Object(symbolValueOf.call(symbol)) : {};
1710
+ }
1711
+
1712
+ /**
1713
+ * Creates a clone of `typedArray`.
1714
+ *
1715
+ * @private
1716
+ * @param {Object} typedArray The typed array to clone.
1717
+ * @param {boolean} [isDeep] Specify a deep clone.
1718
+ * @returns {Object} Returns the cloned typed array.
1719
+ */
1720
+ function cloneTypedArray(typedArray, isDeep) {
1721
+ var buffer = cloneArrayBuffer(typedArray.buffer) ;
1722
+ return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length);
1723
+ }
1724
+
1725
+ /** `Object#toString` result references. */
1726
+ var boolTag$1 = '[object Boolean]',
1727
+ dateTag$1 = '[object Date]',
1728
+ mapTag$2 = '[object Map]',
1729
+ numberTag$1 = '[object Number]',
1730
+ regexpTag$1 = '[object RegExp]',
1731
+ setTag$2 = '[object Set]',
1732
+ stringTag$1 = '[object String]',
1733
+ symbolTag$1 = '[object Symbol]';
1734
+
1735
+ var arrayBufferTag$1 = '[object ArrayBuffer]',
1736
+ dataViewTag$1 = '[object DataView]',
1737
+ float32Tag$1 = '[object Float32Array]',
1738
+ float64Tag$1 = '[object Float64Array]',
1739
+ int8Tag$1 = '[object Int8Array]',
1740
+ int16Tag$1 = '[object Int16Array]',
1741
+ int32Tag$1 = '[object Int32Array]',
1742
+ uint8Tag$1 = '[object Uint8Array]',
1743
+ uint8ClampedTag$1 = '[object Uint8ClampedArray]',
1744
+ uint16Tag$1 = '[object Uint16Array]',
1745
+ uint32Tag$1 = '[object Uint32Array]';
1746
+
1747
+ /**
1748
+ * Initializes an object clone based on its `toStringTag`.
1749
+ *
1750
+ * **Note:** This function only supports cloning values with tags of
1751
+ * `Boolean`, `Date`, `Error`, `Map`, `Number`, `RegExp`, `Set`, or `String`.
1752
+ *
1753
+ * @private
1754
+ * @param {Object} object The object to clone.
1755
+ * @param {string} tag The `toStringTag` of the object to clone.
1756
+ * @param {boolean} [isDeep] Specify a deep clone.
1757
+ * @returns {Object} Returns the initialized clone.
1758
+ */
1759
+ function initCloneByTag(object, tag, isDeep) {
1760
+ var Ctor = object.constructor;
1761
+ switch (tag) {
1762
+ case arrayBufferTag$1:
1763
+ return cloneArrayBuffer(object);
1764
+
1765
+ case boolTag$1:
1766
+ case dateTag$1:
1767
+ return new Ctor(+object);
1768
+
1769
+ case dataViewTag$1:
1770
+ return cloneDataView(object);
1771
+
1772
+ case float32Tag$1: case float64Tag$1:
1773
+ case int8Tag$1: case int16Tag$1: case int32Tag$1:
1774
+ case uint8Tag$1: case uint8ClampedTag$1: case uint16Tag$1: case uint32Tag$1:
1775
+ return cloneTypedArray(object);
1776
+
1777
+ case mapTag$2:
1778
+ return new Ctor;
1779
+
1780
+ case numberTag$1:
1781
+ case stringTag$1:
1782
+ return new Ctor(object);
1783
+
1784
+ case regexpTag$1:
1785
+ return cloneRegExp(object);
1786
+
1787
+ case setTag$2:
1788
+ return new Ctor;
1789
+
1790
+ case symbolTag$1:
1791
+ return cloneSymbol(object);
1792
+ }
1793
+ }
1794
+
1795
+ /**
1796
+ * Initializes an object clone.
1797
+ *
1798
+ * @private
1799
+ * @param {Object} object The object to clone.
1800
+ * @returns {Object} Returns the initialized clone.
1801
+ */
1802
+ function initCloneObject(object) {
1803
+ return (typeof object.constructor == 'function' && !isPrototype(object))
1804
+ ? baseCreate(getPrototype(object))
1805
+ : {};
1806
+ }
1807
+
1808
+ /** `Object#toString` result references. */
1809
+ var mapTag$1 = '[object Map]';
1810
+
1811
+ /**
1812
+ * The base implementation of `_.isMap` without Node.js optimizations.
1813
+ *
1814
+ * @private
1815
+ * @param {*} value The value to check.
1816
+ * @returns {boolean} Returns `true` if `value` is a map, else `false`.
1817
+ */
1818
+ function baseIsMap(value) {
1819
+ return isObjectLike(value) && getTag$1(value) == mapTag$1;
1820
+ }
1821
+
1822
+ /* Node.js helper references. */
1823
+ var nodeIsMap = nodeUtil && nodeUtil.isMap;
1824
+
1825
+ /**
1826
+ * Checks if `value` is classified as a `Map` object.
1827
+ *
1828
+ * @static
1829
+ * @memberOf _
1830
+ * @since 4.3.0
1831
+ * @category Lang
1832
+ * @param {*} value The value to check.
1833
+ * @returns {boolean} Returns `true` if `value` is a map, else `false`.
1834
+ * @example
1835
+ *
1836
+ * _.isMap(new Map);
1837
+ * // => true
1838
+ *
1839
+ * _.isMap(new WeakMap);
1840
+ * // => false
1841
+ */
1842
+ var isMap = nodeIsMap ? baseUnary(nodeIsMap) : baseIsMap;
1843
+
1844
+ /** `Object#toString` result references. */
1845
+ var setTag$1 = '[object Set]';
1846
+
1847
+ /**
1848
+ * The base implementation of `_.isSet` without Node.js optimizations.
1849
+ *
1850
+ * @private
1851
+ * @param {*} value The value to check.
1852
+ * @returns {boolean} Returns `true` if `value` is a set, else `false`.
1853
+ */
1854
+ function baseIsSet(value) {
1855
+ return isObjectLike(value) && getTag$1(value) == setTag$1;
1856
+ }
1857
+
1858
+ /* Node.js helper references. */
1859
+ var nodeIsSet = nodeUtil && nodeUtil.isSet;
1860
+
1861
+ /**
1862
+ * Checks if `value` is classified as a `Set` object.
1863
+ *
1864
+ * @static
1865
+ * @memberOf _
1866
+ * @since 4.3.0
1867
+ * @category Lang
1868
+ * @param {*} value The value to check.
1869
+ * @returns {boolean} Returns `true` if `value` is a set, else `false`.
1870
+ * @example
1871
+ *
1872
+ * _.isSet(new Set);
1873
+ * // => true
1874
+ *
1875
+ * _.isSet(new WeakSet);
1876
+ * // => false
1877
+ */
1878
+ var isSet = nodeIsSet ? baseUnary(nodeIsSet) : baseIsSet;
1879
+
1880
+ /** `Object#toString` result references. */
1881
+ var argsTag = '[object Arguments]',
1882
+ arrayTag = '[object Array]',
1883
+ boolTag = '[object Boolean]',
1884
+ dateTag = '[object Date]',
1885
+ errorTag = '[object Error]',
1886
+ funcTag = '[object Function]',
1887
+ genTag = '[object GeneratorFunction]',
1888
+ mapTag = '[object Map]',
1889
+ numberTag = '[object Number]',
1890
+ objectTag = '[object Object]',
1891
+ regexpTag = '[object RegExp]',
1892
+ setTag = '[object Set]',
1893
+ stringTag = '[object String]',
1894
+ symbolTag = '[object Symbol]',
1895
+ weakMapTag = '[object WeakMap]';
1896
+
1897
+ var arrayBufferTag = '[object ArrayBuffer]',
1898
+ dataViewTag = '[object DataView]',
1899
+ float32Tag = '[object Float32Array]',
1900
+ float64Tag = '[object Float64Array]',
1901
+ int8Tag = '[object Int8Array]',
1902
+ int16Tag = '[object Int16Array]',
1903
+ int32Tag = '[object Int32Array]',
1904
+ uint8Tag = '[object Uint8Array]',
1905
+ uint8ClampedTag = '[object Uint8ClampedArray]',
1906
+ uint16Tag = '[object Uint16Array]',
1907
+ uint32Tag = '[object Uint32Array]';
1908
+
1909
+ /** Used to identify `toStringTag` values supported by `_.clone`. */
1910
+ var cloneableTags = {};
1911
+ cloneableTags[argsTag] = cloneableTags[arrayTag] =
1912
+ cloneableTags[arrayBufferTag] = cloneableTags[dataViewTag] =
1913
+ cloneableTags[boolTag] = cloneableTags[dateTag] =
1914
+ cloneableTags[float32Tag] = cloneableTags[float64Tag] =
1915
+ cloneableTags[int8Tag] = cloneableTags[int16Tag] =
1916
+ cloneableTags[int32Tag] = cloneableTags[mapTag] =
1917
+ cloneableTags[numberTag] = cloneableTags[objectTag] =
1918
+ cloneableTags[regexpTag] = cloneableTags[setTag] =
1919
+ cloneableTags[stringTag] = cloneableTags[symbolTag] =
1920
+ cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] =
1921
+ cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true;
1922
+ cloneableTags[errorTag] = cloneableTags[funcTag] =
1923
+ cloneableTags[weakMapTag] = false;
1924
+
1925
+ /**
1926
+ * The base implementation of `_.clone` and `_.cloneDeep` which tracks
1927
+ * traversed objects.
1928
+ *
1929
+ * @private
1930
+ * @param {*} value The value to clone.
1931
+ * @param {boolean} bitmask The bitmask flags.
1932
+ * 1 - Deep clone
1933
+ * 2 - Flatten inherited properties
1934
+ * 4 - Clone symbols
1935
+ * @param {Function} [customizer] The function to customize cloning.
1936
+ * @param {string} [key] The key of `value`.
1937
+ * @param {Object} [object] The parent object of `value`.
1938
+ * @param {Object} [stack] Tracks traversed objects and their clone counterparts.
1939
+ * @returns {*} Returns the cloned value.
1940
+ */
1941
+ function baseClone(value, bitmask, customizer, key, object, stack) {
1942
+ var result;
1943
+ if (result !== undefined) {
1944
+ return result;
1945
+ }
1946
+ if (!isObject(value)) {
1947
+ return value;
1948
+ }
1949
+ var isArr = isArray(value);
1950
+ if (isArr) {
1951
+ result = initCloneArray(value);
1952
+ } else {
1953
+ var tag = getTag$1(value),
1954
+ isFunc = tag == funcTag || tag == genTag;
1955
+
1956
+ if (isBuffer(value)) {
1957
+ return cloneBuffer(value);
1958
+ }
1959
+ if (tag == objectTag || tag == argsTag || (isFunc && !object)) {
1960
+ result = (isFunc) ? {} : initCloneObject(value);
1961
+ } else {
1962
+ if (!cloneableTags[tag]) {
1963
+ return object ? value : {};
1964
+ }
1965
+ result = initCloneByTag(value, tag);
1966
+ }
1967
+ }
1968
+ // Check for circular references and return its corresponding clone.
1969
+ stack || (stack = new Stack);
1970
+ var stacked = stack.get(value);
1971
+ if (stacked) {
1972
+ return stacked;
1973
+ }
1974
+ stack.set(value, result);
1975
+
1976
+ if (isSet(value)) {
1977
+ value.forEach(function(subValue) {
1978
+ result.add(baseClone(subValue, bitmask, customizer, subValue, value, stack));
1979
+ });
1980
+ } else if (isMap(value)) {
1981
+ value.forEach(function(subValue, key) {
1982
+ result.set(key, baseClone(subValue, bitmask, customizer, key, value, stack));
1983
+ });
1984
+ }
1985
+
1986
+ var keysFunc = (getAllKeys)
1987
+ ;
1988
+
1989
+ var props = isArr ? undefined : keysFunc(value);
1990
+ arrayEach(props || value, function(subValue, key) {
1991
+ if (props) {
1992
+ key = subValue;
1993
+ subValue = value[key];
1994
+ }
1995
+ // Recursively populate clone (susceptible to call stack limits).
1996
+ assignValue(result, key, baseClone(subValue, bitmask, customizer, key, value, stack));
1997
+ });
1998
+ return result;
1999
+ }
2000
+
2001
+ /** Used to compose bitmasks for cloning. */
2002
+ var CLONE_DEEP_FLAG = 1,
2003
+ CLONE_SYMBOLS_FLAG = 4;
2004
+
2005
+ /**
2006
+ * This method is like `_.clone` except that it recursively clones `value`.
2007
+ *
2008
+ * @static
2009
+ * @memberOf _
2010
+ * @since 1.0.0
2011
+ * @category Lang
2012
+ * @param {*} value The value to recursively clone.
2013
+ * @returns {*} Returns the deep cloned value.
2014
+ * @see _.clone
2015
+ * @example
2016
+ *
2017
+ * var objects = [{ 'a': 1 }, { 'b': 2 }];
2018
+ *
2019
+ * var deep = _.cloneDeep(objects);
2020
+ * console.log(deep[0] === objects[0]);
2021
+ * // => false
2022
+ */
2023
+ function cloneDeep(value) {
2024
+ return baseClone(value, CLONE_DEEP_FLAG | CLONE_SYMBOLS_FLAG);
2025
+ }
2026
+
2027
+ export { cloneDeep as c };