@seamly/web-ui 20.2.0-alpha.4 → 20.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.
- package/build/dist/lib/index.debug.js +72 -73
- package/build/dist/lib/index.debug.min.js +1 -1
- package/build/dist/lib/index.debug.min.js.LICENSE.txt +24 -24
- package/build/dist/lib/index.js +2733 -2505
- package/build/dist/lib/index.min.js +1 -1
- package/build/dist/lib/standalone.js +1636 -1330
- package/build/dist/lib/standalone.min.js +1 -1
- package/package.json +1 -1
- package/src/.DS_Store +0 -0
|
@@ -165,6 +165,13 @@ module.exports = __webpack_require__(8933);
|
|
|
165
165
|
|
|
166
166
|
/***/ }),
|
|
167
167
|
|
|
168
|
+
/***/ 925:
|
|
169
|
+
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
170
|
+
|
|
171
|
+
module.exports = __webpack_require__(5838);
|
|
172
|
+
|
|
173
|
+
/***/ }),
|
|
174
|
+
|
|
168
175
|
/***/ 1942:
|
|
169
176
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
170
177
|
|
|
@@ -172,6 +179,13 @@ module.exports = __webpack_require__(3383);
|
|
|
172
179
|
|
|
173
180
|
/***/ }),
|
|
174
181
|
|
|
182
|
+
/***/ 4943:
|
|
183
|
+
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
184
|
+
|
|
185
|
+
module.exports = __webpack_require__(4471);
|
|
186
|
+
|
|
187
|
+
/***/ }),
|
|
188
|
+
|
|
175
189
|
/***/ 368:
|
|
176
190
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
177
191
|
|
|
@@ -305,13 +319,6 @@ module.exports = __webpack_require__(2209);
|
|
|
305
319
|
|
|
306
320
|
/***/ }),
|
|
307
321
|
|
|
308
|
-
/***/ 6976:
|
|
309
|
-
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
310
|
-
|
|
311
|
-
module.exports = __webpack_require__(1258);
|
|
312
|
-
|
|
313
|
-
/***/ }),
|
|
314
|
-
|
|
315
322
|
/***/ 5683:
|
|
316
323
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
317
324
|
|
|
@@ -319,13 +326,6 @@ module.exports = __webpack_require__(9447);
|
|
|
319
326
|
|
|
320
327
|
/***/ }),
|
|
321
328
|
|
|
322
|
-
/***/ 8317:
|
|
323
|
-
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
324
|
-
|
|
325
|
-
module.exports = __webpack_require__(4408);
|
|
326
|
-
|
|
327
|
-
/***/ }),
|
|
328
|
-
|
|
329
329
|
/***/ 2088:
|
|
330
330
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
331
331
|
|
|
@@ -360,19 +360,15 @@ module.exports = __webpack_require__(3799);
|
|
|
360
360
|
"use strict";
|
|
361
361
|
|
|
362
362
|
|
|
363
|
-
var _sliceInstanceProperty = __webpack_require__(3649);
|
|
364
|
-
|
|
365
|
-
var _Array$from = __webpack_require__(6419);
|
|
366
|
-
|
|
367
363
|
var _Symbol = __webpack_require__(5420);
|
|
368
364
|
|
|
369
|
-
var
|
|
365
|
+
var _getIteratorMethod = __webpack_require__(9996);
|
|
366
|
+
|
|
367
|
+
var _Array$from = __webpack_require__(6419);
|
|
370
368
|
|
|
371
369
|
var _Array$isArray = __webpack_require__(1511);
|
|
372
370
|
|
|
373
|
-
var
|
|
374
|
-
|
|
375
|
-
var _context2;
|
|
371
|
+
var _sliceInstanceProperty = __webpack_require__(3649);
|
|
376
372
|
|
|
377
373
|
function _toConsumableArray(arr) {
|
|
378
374
|
return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();
|
|
@@ -382,6 +378,71 @@ function _nonIterableSpread() {
|
|
|
382
378
|
throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
383
379
|
}
|
|
384
380
|
|
|
381
|
+
function _iterableToArray(iter) {
|
|
382
|
+
if (typeof _Symbol !== "undefined" && _getIteratorMethod(iter) != null || iter["@@iterator"] != null) return _Array$from(iter);
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
function _arrayWithoutHoles(arr) {
|
|
386
|
+
if (_Array$isArray(arr)) return _arrayLikeToArray(arr);
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
function _createForOfIteratorHelper(o, allowArrayLike) {
|
|
390
|
+
var it = typeof _Symbol !== "undefined" && _getIteratorMethod(o) || o["@@iterator"];
|
|
391
|
+
|
|
392
|
+
if (!it) {
|
|
393
|
+
if (_Array$isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") {
|
|
394
|
+
if (it) o = it;
|
|
395
|
+
var i = 0;
|
|
396
|
+
|
|
397
|
+
var F = function F() {};
|
|
398
|
+
|
|
399
|
+
return {
|
|
400
|
+
s: F,
|
|
401
|
+
n: function n() {
|
|
402
|
+
if (i >= o.length) return {
|
|
403
|
+
done: true
|
|
404
|
+
};
|
|
405
|
+
return {
|
|
406
|
+
done: false,
|
|
407
|
+
value: o[i++]
|
|
408
|
+
};
|
|
409
|
+
},
|
|
410
|
+
e: function e(_e) {
|
|
411
|
+
throw _e;
|
|
412
|
+
},
|
|
413
|
+
f: F
|
|
414
|
+
};
|
|
415
|
+
}
|
|
416
|
+
|
|
417
|
+
throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
418
|
+
}
|
|
419
|
+
|
|
420
|
+
var normalCompletion = true,
|
|
421
|
+
didErr = false,
|
|
422
|
+
err;
|
|
423
|
+
return {
|
|
424
|
+
s: function s() {
|
|
425
|
+
it = it.call(o);
|
|
426
|
+
},
|
|
427
|
+
n: function n() {
|
|
428
|
+
var step = it.next();
|
|
429
|
+
normalCompletion = step.done;
|
|
430
|
+
return step;
|
|
431
|
+
},
|
|
432
|
+
e: function e(_e2) {
|
|
433
|
+
didErr = true;
|
|
434
|
+
err = _e2;
|
|
435
|
+
},
|
|
436
|
+
f: function f() {
|
|
437
|
+
try {
|
|
438
|
+
if (!normalCompletion && it.return != null) it.return();
|
|
439
|
+
} finally {
|
|
440
|
+
if (didErr) throw err;
|
|
441
|
+
}
|
|
442
|
+
}
|
|
443
|
+
};
|
|
444
|
+
}
|
|
445
|
+
|
|
385
446
|
function _unsupportedIterableToArray(o, minLen) {
|
|
386
447
|
var _context;
|
|
387
448
|
|
|
@@ -395,14 +456,6 @@ function _unsupportedIterableToArray(o, minLen) {
|
|
|
395
456
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
|
|
396
457
|
}
|
|
397
458
|
|
|
398
|
-
function _iterableToArray(iter) {
|
|
399
|
-
if (typeof _Symbol !== "undefined" && _isIterable(Object(iter))) return _Array$from(iter);
|
|
400
|
-
}
|
|
401
|
-
|
|
402
|
-
function _arrayWithoutHoles(arr) {
|
|
403
|
-
if (_Array$isArray(arr)) return _arrayLikeToArray(arr);
|
|
404
|
-
}
|
|
405
|
-
|
|
406
459
|
function _arrayLikeToArray(arr, len) {
|
|
407
460
|
if (len == null || len > arr.length) len = arr.length;
|
|
408
461
|
|
|
@@ -417,8 +470,9 @@ function Agent() {
|
|
|
417
470
|
this._defaults = [];
|
|
418
471
|
}
|
|
419
472
|
|
|
420
|
-
|
|
421
|
-
// Default setting for all requests from this agent
|
|
473
|
+
var _loop = function _loop() {
|
|
474
|
+
var fn = _arr[_i]; // Default setting for all requests from this agent
|
|
475
|
+
|
|
422
476
|
Agent.prototype[fn] = function () {
|
|
423
477
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
424
478
|
args[_key] = arguments[_key];
|
|
@@ -431,14 +485,26 @@ _forEachInstanceProperty(_context2 = ['use', 'on', 'once', 'set', 'query', 'type
|
|
|
431
485
|
|
|
432
486
|
return this;
|
|
433
487
|
};
|
|
434
|
-
}
|
|
488
|
+
};
|
|
435
489
|
|
|
436
|
-
|
|
437
|
-
|
|
490
|
+
for (var _i = 0, _arr = ['use', 'on', 'once', 'set', 'query', 'type', 'accept', 'auth', 'withCredentials', 'sortQuery', 'retry', 'ok', 'redirects', 'timeout', 'buffer', 'serialize', 'parse', 'ca', 'key', 'pfx', 'cert', 'disableTLSCerts']; _i < _arr.length; _i++) {
|
|
491
|
+
_loop();
|
|
492
|
+
}
|
|
438
493
|
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
494
|
+
Agent.prototype._setDefaults = function (request) {
|
|
495
|
+
var _iterator = _createForOfIteratorHelper(this._defaults),
|
|
496
|
+
_step;
|
|
497
|
+
|
|
498
|
+
try {
|
|
499
|
+
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
500
|
+
var def = _step.value;
|
|
501
|
+
request[def.fn].apply(request, _toConsumableArray(def.args));
|
|
502
|
+
}
|
|
503
|
+
} catch (err) {
|
|
504
|
+
_iterator.e(err);
|
|
505
|
+
} finally {
|
|
506
|
+
_iterator.f();
|
|
507
|
+
}
|
|
442
508
|
};
|
|
443
509
|
|
|
444
510
|
module.exports = Agent;
|
|
@@ -455,38 +521,112 @@ var _Symbol = __webpack_require__(5420);
|
|
|
455
521
|
|
|
456
522
|
var _Symbol$iterator = __webpack_require__(8341);
|
|
457
523
|
|
|
458
|
-
var
|
|
524
|
+
var _getIteratorMethod = __webpack_require__(9996);
|
|
459
525
|
|
|
460
526
|
var _Array$isArray = __webpack_require__(1511);
|
|
461
527
|
|
|
462
|
-
var
|
|
528
|
+
var _sliceInstanceProperty = __webpack_require__(3649);
|
|
529
|
+
|
|
530
|
+
var _Array$from = __webpack_require__(6419);
|
|
531
|
+
|
|
532
|
+
var _trimInstanceProperty = __webpack_require__(5843);
|
|
463
533
|
|
|
464
534
|
var _concatInstanceProperty = __webpack_require__(7766);
|
|
465
535
|
|
|
466
536
|
var _indexOfInstanceProperty = __webpack_require__(1643);
|
|
467
537
|
|
|
468
|
-
var _sliceInstanceProperty = __webpack_require__(3649);
|
|
469
|
-
|
|
470
538
|
var _setTimeout = __webpack_require__(3032);
|
|
471
539
|
|
|
472
540
|
var _bindInstanceProperty = __webpack_require__(4103);
|
|
473
541
|
|
|
474
|
-
var _context4;
|
|
475
|
-
|
|
476
542
|
function _typeof(obj) {
|
|
477
543
|
"@babel/helpers - typeof";
|
|
478
544
|
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
}
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
545
|
+
return _typeof = "function" == typeof _Symbol && "symbol" == typeof _Symbol$iterator ? function (obj) {
|
|
546
|
+
return typeof obj;
|
|
547
|
+
} : function (obj) {
|
|
548
|
+
return obj && "function" == typeof _Symbol && obj.constructor === _Symbol && obj !== _Symbol.prototype ? "symbol" : typeof obj;
|
|
549
|
+
}, _typeof(obj);
|
|
550
|
+
}
|
|
551
|
+
|
|
552
|
+
function _createForOfIteratorHelper(o, allowArrayLike) {
|
|
553
|
+
var it = typeof _Symbol !== "undefined" && _getIteratorMethod(o) || o["@@iterator"];
|
|
554
|
+
|
|
555
|
+
if (!it) {
|
|
556
|
+
if (_Array$isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") {
|
|
557
|
+
if (it) o = it;
|
|
558
|
+
var i = 0;
|
|
559
|
+
|
|
560
|
+
var F = function F() {};
|
|
561
|
+
|
|
562
|
+
return {
|
|
563
|
+
s: F,
|
|
564
|
+
n: function n() {
|
|
565
|
+
if (i >= o.length) return {
|
|
566
|
+
done: true
|
|
567
|
+
};
|
|
568
|
+
return {
|
|
569
|
+
done: false,
|
|
570
|
+
value: o[i++]
|
|
571
|
+
};
|
|
572
|
+
},
|
|
573
|
+
e: function e(_e) {
|
|
574
|
+
throw _e;
|
|
575
|
+
},
|
|
576
|
+
f: F
|
|
577
|
+
};
|
|
578
|
+
}
|
|
579
|
+
|
|
580
|
+
throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
581
|
+
}
|
|
582
|
+
|
|
583
|
+
var normalCompletion = true,
|
|
584
|
+
didErr = false,
|
|
585
|
+
err;
|
|
586
|
+
return {
|
|
587
|
+
s: function s() {
|
|
588
|
+
it = it.call(o);
|
|
589
|
+
},
|
|
590
|
+
n: function n() {
|
|
591
|
+
var step = it.next();
|
|
592
|
+
normalCompletion = step.done;
|
|
593
|
+
return step;
|
|
594
|
+
},
|
|
595
|
+
e: function e(_e2) {
|
|
596
|
+
didErr = true;
|
|
597
|
+
err = _e2;
|
|
598
|
+
},
|
|
599
|
+
f: function f() {
|
|
600
|
+
try {
|
|
601
|
+
if (!normalCompletion && it.return != null) it.return();
|
|
602
|
+
} finally {
|
|
603
|
+
if (didErr) throw err;
|
|
604
|
+
}
|
|
605
|
+
}
|
|
606
|
+
};
|
|
607
|
+
}
|
|
608
|
+
|
|
609
|
+
function _unsupportedIterableToArray(o, minLen) {
|
|
610
|
+
var _context;
|
|
611
|
+
|
|
612
|
+
if (!o) return;
|
|
613
|
+
if (typeof o === "string") return _arrayLikeToArray(o, minLen);
|
|
614
|
+
|
|
615
|
+
var n = _sliceInstanceProperty(_context = Object.prototype.toString.call(o)).call(_context, 8, -1);
|
|
616
|
+
|
|
617
|
+
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
618
|
+
if (n === "Map" || n === "Set") return _Array$from(o);
|
|
619
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
|
|
620
|
+
}
|
|
621
|
+
|
|
622
|
+
function _arrayLikeToArray(arr, len) {
|
|
623
|
+
if (len == null || len > arr.length) len = arr.length;
|
|
624
|
+
|
|
625
|
+
for (var i = 0, arr2 = new Array(len); i < len; i++) {
|
|
626
|
+
arr2[i] = arr[i];
|
|
487
627
|
}
|
|
488
628
|
|
|
489
|
-
return
|
|
629
|
+
return arr2;
|
|
490
630
|
}
|
|
491
631
|
/**
|
|
492
632
|
* Root reference for iframes.
|
|
@@ -511,11 +651,14 @@ var Emitter = __webpack_require__(8767);
|
|
|
511
651
|
|
|
512
652
|
var safeStringify = __webpack_require__(4445);
|
|
513
653
|
|
|
514
|
-
var qs = __webpack_require__(
|
|
654
|
+
var qs = __webpack_require__(2501);
|
|
515
655
|
|
|
516
656
|
var RequestBase = __webpack_require__(8842);
|
|
517
657
|
|
|
518
|
-
var
|
|
658
|
+
var _require = __webpack_require__(6244),
|
|
659
|
+
isObject = _require.isObject,
|
|
660
|
+
mixin = _require.mixin,
|
|
661
|
+
hasOwn = _require.hasOwn;
|
|
519
662
|
|
|
520
663
|
var ResponseBase = __webpack_require__(1253);
|
|
521
664
|
|
|
@@ -559,19 +702,27 @@ request.getXHR = function () {
|
|
|
559
702
|
|
|
560
703
|
try {
|
|
561
704
|
return new ActiveXObject('Microsoft.XMLHTTP');
|
|
562
|
-
} catch (_unused) {
|
|
705
|
+
} catch (_unused) {
|
|
706
|
+
/**/
|
|
707
|
+
}
|
|
563
708
|
|
|
564
709
|
try {
|
|
565
710
|
return new ActiveXObject('Msxml2.XMLHTTP.6.0');
|
|
566
|
-
} catch (_unused2) {
|
|
711
|
+
} catch (_unused2) {
|
|
712
|
+
/**/
|
|
713
|
+
}
|
|
567
714
|
|
|
568
715
|
try {
|
|
569
716
|
return new ActiveXObject('Msxml2.XMLHTTP.3.0');
|
|
570
|
-
} catch (_unused3) {
|
|
717
|
+
} catch (_unused3) {
|
|
718
|
+
/**/
|
|
719
|
+
}
|
|
571
720
|
|
|
572
721
|
try {
|
|
573
722
|
return new ActiveXObject('Msxml2.XMLHTTP');
|
|
574
|
-
} catch (_unused4) {
|
|
723
|
+
} catch (_unused4) {
|
|
724
|
+
/**/
|
|
725
|
+
}
|
|
575
726
|
|
|
576
727
|
throw new Error('Browser-only version of superagent could not find XHR');
|
|
577
728
|
};
|
|
@@ -597,12 +748,12 @@ var trim = _trimInstanceProperty('') ? function (s) {
|
|
|
597
748
|
* @api private
|
|
598
749
|
*/
|
|
599
750
|
|
|
600
|
-
function serialize(
|
|
601
|
-
if (!isObject(
|
|
751
|
+
function serialize(object) {
|
|
752
|
+
if (!isObject(object)) return object;
|
|
602
753
|
var pairs = [];
|
|
603
754
|
|
|
604
|
-
for (var key in
|
|
605
|
-
if (
|
|
755
|
+
for (var key in object) {
|
|
756
|
+
if (hasOwn(object, key)) pushEncodedKeyValuePair(pairs, key, object[key]);
|
|
606
757
|
}
|
|
607
758
|
|
|
608
759
|
return pairs.join('&');
|
|
@@ -617,26 +768,36 @@ function serialize(obj) {
|
|
|
617
768
|
*/
|
|
618
769
|
|
|
619
770
|
|
|
620
|
-
function pushEncodedKeyValuePair(pairs, key,
|
|
621
|
-
if (
|
|
771
|
+
function pushEncodedKeyValuePair(pairs, key, value) {
|
|
772
|
+
if (value === undefined) return;
|
|
622
773
|
|
|
623
|
-
if (
|
|
774
|
+
if (value === null) {
|
|
624
775
|
pairs.push(encodeURI(key));
|
|
625
776
|
return;
|
|
626
777
|
}
|
|
627
778
|
|
|
628
|
-
if (_Array$isArray(
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
});
|
|
632
|
-
} else if (isObject(val)) {
|
|
633
|
-
for (var subkey in val) {
|
|
634
|
-
var _context;
|
|
779
|
+
if (_Array$isArray(value)) {
|
|
780
|
+
var _iterator = _createForOfIteratorHelper(value),
|
|
781
|
+
_step;
|
|
635
782
|
|
|
636
|
-
|
|
783
|
+
try {
|
|
784
|
+
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
785
|
+
var v = _step.value;
|
|
786
|
+
pushEncodedKeyValuePair(pairs, key, v);
|
|
787
|
+
}
|
|
788
|
+
} catch (err) {
|
|
789
|
+
_iterator.e(err);
|
|
790
|
+
} finally {
|
|
791
|
+
_iterator.f();
|
|
792
|
+
}
|
|
793
|
+
} else if (isObject(value)) {
|
|
794
|
+
for (var subkey in value) {
|
|
795
|
+
var _context2;
|
|
796
|
+
|
|
797
|
+
if (hasOwn(value, subkey)) pushEncodedKeyValuePair(pairs, _concatInstanceProperty(_context2 = "".concat(key, "[")).call(_context2, subkey, "]"), value[subkey]);
|
|
637
798
|
}
|
|
638
799
|
} else {
|
|
639
|
-
pairs.push(encodeURI(key) + '=' + encodeURIComponent(
|
|
800
|
+
pairs.push(encodeURI(key) + '=' + encodeURIComponent(value));
|
|
640
801
|
}
|
|
641
802
|
}
|
|
642
803
|
/**
|
|
@@ -653,24 +814,24 @@ request.serializeObject = serialize;
|
|
|
653
814
|
* @api private
|
|
654
815
|
*/
|
|
655
816
|
|
|
656
|
-
function parseString(
|
|
657
|
-
var
|
|
658
|
-
var pairs =
|
|
817
|
+
function parseString(string_) {
|
|
818
|
+
var object = {};
|
|
819
|
+
var pairs = string_.split('&');
|
|
659
820
|
var pair;
|
|
660
821
|
var pos;
|
|
661
822
|
|
|
662
|
-
for (var i = 0,
|
|
823
|
+
for (var i = 0, length_ = pairs.length; i < length_; ++i) {
|
|
663
824
|
pair = pairs[i];
|
|
664
825
|
pos = _indexOfInstanceProperty(pair).call(pair, '=');
|
|
665
826
|
|
|
666
827
|
if (pos === -1) {
|
|
667
|
-
|
|
828
|
+
object[decodeURIComponent(pair)] = '';
|
|
668
829
|
} else {
|
|
669
|
-
|
|
830
|
+
object[decodeURIComponent(_sliceInstanceProperty(pair).call(pair, 0, pos))] = decodeURIComponent(_sliceInstanceProperty(pair).call(pair, pos + 1));
|
|
670
831
|
}
|
|
671
832
|
}
|
|
672
833
|
|
|
673
|
-
return
|
|
834
|
+
return object;
|
|
674
835
|
}
|
|
675
836
|
/**
|
|
676
837
|
* Expose parser.
|
|
@@ -728,15 +889,15 @@ request.parse = {
|
|
|
728
889
|
* @api private
|
|
729
890
|
*/
|
|
730
891
|
|
|
731
|
-
function parseHeader(
|
|
732
|
-
var lines =
|
|
892
|
+
function parseHeader(string_) {
|
|
893
|
+
var lines = string_.split(/\r?\n/);
|
|
733
894
|
var fields = {};
|
|
734
895
|
var index;
|
|
735
896
|
var line;
|
|
736
897
|
var field;
|
|
737
|
-
var
|
|
898
|
+
var value;
|
|
738
899
|
|
|
739
|
-
for (var i = 0,
|
|
900
|
+
for (var i = 0, length_ = lines.length; i < length_; ++i) {
|
|
740
901
|
line = lines[i];
|
|
741
902
|
index = _indexOfInstanceProperty(line).call(line, ':');
|
|
742
903
|
|
|
@@ -746,8 +907,8 @@ function parseHeader(str) {
|
|
|
746
907
|
}
|
|
747
908
|
|
|
748
909
|
field = _sliceInstanceProperty(line).call(line, 0, index).toLowerCase();
|
|
749
|
-
|
|
750
|
-
fields[field] =
|
|
910
|
+
value = trim(_sliceInstanceProperty(line).call(line, index + 1));
|
|
911
|
+
fields[field] = value;
|
|
751
912
|
}
|
|
752
913
|
|
|
753
914
|
return fields;
|
|
@@ -813,8 +974,8 @@ function isJSON(mime) {
|
|
|
813
974
|
*/
|
|
814
975
|
|
|
815
976
|
|
|
816
|
-
function Response(
|
|
817
|
-
this.req =
|
|
977
|
+
function Response(request_) {
|
|
978
|
+
this.req = request_;
|
|
818
979
|
this.xhr = this.req.xhr; // responseText is accessible only if responseType is '' or 'text' and on older browsers
|
|
819
980
|
|
|
820
981
|
this.text = this.req.method !== 'HEAD' && (this.xhr.responseType === '' || this.xhr.responseType === 'text') || typeof this.xhr.responseType === 'undefined' ? this.xhr.responseText : null;
|
|
@@ -836,15 +997,14 @@ function Response(req) {
|
|
|
836
997
|
|
|
837
998
|
this._setHeaderProperties(this.header);
|
|
838
999
|
|
|
839
|
-
if (this.text === null &&
|
|
1000
|
+
if (this.text === null && request_._responseType) {
|
|
840
1001
|
this.body = this.xhr.response;
|
|
841
1002
|
} else {
|
|
842
1003
|
this.body = this.req.method === 'HEAD' ? null : this._parseBody(this.text ? this.text : this.xhr.response);
|
|
843
1004
|
}
|
|
844
|
-
}
|
|
845
|
-
|
|
1005
|
+
}
|
|
846
1006
|
|
|
847
|
-
|
|
1007
|
+
mixin(Response.prototype, ResponseBase.prototype);
|
|
848
1008
|
/**
|
|
849
1009
|
* Parse the given body `str`.
|
|
850
1010
|
*
|
|
@@ -856,18 +1016,18 @@ ResponseBase(Response.prototype);
|
|
|
856
1016
|
* @api private
|
|
857
1017
|
*/
|
|
858
1018
|
|
|
859
|
-
Response.prototype._parseBody = function (
|
|
1019
|
+
Response.prototype._parseBody = function (string_) {
|
|
860
1020
|
var parse = request.parse[this.type];
|
|
861
1021
|
|
|
862
1022
|
if (this.req._parser) {
|
|
863
|
-
return this.req._parser(this,
|
|
1023
|
+
return this.req._parser(this, string_);
|
|
864
1024
|
}
|
|
865
1025
|
|
|
866
1026
|
if (!parse && isJSON(this.type)) {
|
|
867
1027
|
parse = request.parse['application/json'];
|
|
868
1028
|
}
|
|
869
1029
|
|
|
870
|
-
return parse &&
|
|
1030
|
+
return parse && string_ && (string_.length > 0 || string_ instanceof Object) ? parse(string_) : null;
|
|
871
1031
|
};
|
|
872
1032
|
/**
|
|
873
1033
|
* Return an `Error` representative of this response.
|
|
@@ -878,19 +1038,19 @@ Response.prototype._parseBody = function (str) {
|
|
|
878
1038
|
|
|
879
1039
|
|
|
880
1040
|
Response.prototype.toError = function () {
|
|
881
|
-
var
|
|
1041
|
+
var _context3, _context4;
|
|
882
1042
|
|
|
883
1043
|
var req = this.req;
|
|
884
1044
|
var method = req.method;
|
|
885
1045
|
var url = req.url;
|
|
886
1046
|
|
|
887
|
-
var
|
|
1047
|
+
var message = _concatInstanceProperty(_context3 = _concatInstanceProperty(_context4 = "cannot ".concat(method, " ")).call(_context4, url, " (")).call(_context3, this.status, ")");
|
|
888
1048
|
|
|
889
|
-
var
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
return
|
|
1049
|
+
var error = new Error(message);
|
|
1050
|
+
error.status = this.status;
|
|
1051
|
+
error.method = method;
|
|
1052
|
+
error.url = url;
|
|
1053
|
+
return error;
|
|
894
1054
|
};
|
|
895
1055
|
/**
|
|
896
1056
|
* Expose `Response`.
|
|
@@ -916,47 +1076,47 @@ function Request(method, url) {
|
|
|
916
1076
|
this._header = {}; // coerces header names to lowercase
|
|
917
1077
|
|
|
918
1078
|
this.on('end', function () {
|
|
919
|
-
var
|
|
1079
|
+
var error = null;
|
|
920
1080
|
var res = null;
|
|
921
1081
|
|
|
922
1082
|
try {
|
|
923
1083
|
res = new Response(self);
|
|
924
|
-
} catch (
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
1084
|
+
} catch (error_) {
|
|
1085
|
+
error = new Error('Parser is unable to parse the response');
|
|
1086
|
+
error.parse = true;
|
|
1087
|
+
error.original = error_; // issue #675: return the raw response if the response parsing fails
|
|
928
1088
|
|
|
929
1089
|
if (self.xhr) {
|
|
930
1090
|
// ie9 doesn't have 'response' property
|
|
931
|
-
|
|
1091
|
+
error.rawResponse = typeof self.xhr.responseType === 'undefined' ? self.xhr.responseText : self.xhr.response; // issue #876: return the http status code if the response parsing fails
|
|
932
1092
|
|
|
933
|
-
|
|
934
|
-
|
|
1093
|
+
error.status = self.xhr.status ? self.xhr.status : null;
|
|
1094
|
+
error.statusCode = error.status; // backwards-compat only
|
|
935
1095
|
} else {
|
|
936
|
-
|
|
937
|
-
|
|
1096
|
+
error.rawResponse = null;
|
|
1097
|
+
error.status = null;
|
|
938
1098
|
}
|
|
939
1099
|
|
|
940
|
-
return self.callback(
|
|
1100
|
+
return self.callback(error);
|
|
941
1101
|
}
|
|
942
1102
|
|
|
943
1103
|
self.emit('response', res);
|
|
944
|
-
var
|
|
1104
|
+
var new_error;
|
|
945
1105
|
|
|
946
1106
|
try {
|
|
947
1107
|
if (!self._isResponseOK(res)) {
|
|
948
|
-
|
|
1108
|
+
new_error = new Error(res.statusText || res.text || 'Unsuccessful HTTP response');
|
|
949
1109
|
}
|
|
950
|
-
} catch (
|
|
951
|
-
|
|
1110
|
+
} catch (err) {
|
|
1111
|
+
new_error = err; // ok() callback can throw
|
|
952
1112
|
} // #1000 don't catch errors from the callback to avoid double calling it
|
|
953
1113
|
|
|
954
1114
|
|
|
955
|
-
if (
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
self.callback(
|
|
1115
|
+
if (new_error) {
|
|
1116
|
+
new_error.original = error;
|
|
1117
|
+
new_error.response = res;
|
|
1118
|
+
new_error.status = res.status;
|
|
1119
|
+
self.callback(new_error, res);
|
|
960
1120
|
} else {
|
|
961
1121
|
self.callback(null, res);
|
|
962
1122
|
}
|
|
@@ -968,9 +1128,8 @@ function Request(method, url) {
|
|
|
968
1128
|
// eslint-disable-next-line new-cap
|
|
969
1129
|
|
|
970
1130
|
|
|
971
|
-
Emitter(Request.prototype);
|
|
972
|
-
|
|
973
|
-
RequestBase(Request.prototype);
|
|
1131
|
+
Emitter(Request.prototype);
|
|
1132
|
+
mixin(Request.prototype, RequestBase.prototype);
|
|
974
1133
|
/**
|
|
975
1134
|
* Set Content-Type to `type`, mapping values from `request.types`.
|
|
976
1135
|
*
|
|
@@ -1073,9 +1232,9 @@ Request.prototype.auth = function (user, pass, options) {
|
|
|
1073
1232
|
*/
|
|
1074
1233
|
|
|
1075
1234
|
|
|
1076
|
-
Request.prototype.query = function (
|
|
1077
|
-
if (typeof
|
|
1078
|
-
if (
|
|
1235
|
+
Request.prototype.query = function (value) {
|
|
1236
|
+
if (typeof value !== 'string') value = serialize(value);
|
|
1237
|
+
if (value) this._query.push(value);
|
|
1079
1238
|
return this;
|
|
1080
1239
|
};
|
|
1081
1240
|
/**
|
|
@@ -1125,20 +1284,20 @@ Request.prototype._getFormData = function () {
|
|
|
1125
1284
|
*/
|
|
1126
1285
|
|
|
1127
1286
|
|
|
1128
|
-
Request.prototype.callback = function (
|
|
1129
|
-
if (this._shouldRetry(
|
|
1287
|
+
Request.prototype.callback = function (error, res) {
|
|
1288
|
+
if (this._shouldRetry(error, res)) {
|
|
1130
1289
|
return this._retry();
|
|
1131
1290
|
}
|
|
1132
1291
|
|
|
1133
1292
|
var fn = this._callback;
|
|
1134
1293
|
this.clearTimeout();
|
|
1135
1294
|
|
|
1136
|
-
if (
|
|
1137
|
-
if (this._maxRetries)
|
|
1138
|
-
this.emit('error',
|
|
1295
|
+
if (error) {
|
|
1296
|
+
if (this._maxRetries) error.retries = this._retries - 1;
|
|
1297
|
+
this.emit('error', error);
|
|
1139
1298
|
}
|
|
1140
1299
|
|
|
1141
|
-
fn(
|
|
1300
|
+
fn(error, res);
|
|
1142
1301
|
};
|
|
1143
1302
|
/**
|
|
1144
1303
|
* Invoke callback with x-domain error.
|
|
@@ -1148,12 +1307,12 @@ Request.prototype.callback = function (err, res) {
|
|
|
1148
1307
|
|
|
1149
1308
|
|
|
1150
1309
|
Request.prototype.crossDomainError = function () {
|
|
1151
|
-
var
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
this.callback(
|
|
1310
|
+
var error = new Error('Request has been terminated\nPossible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.');
|
|
1311
|
+
error.crossDomain = true;
|
|
1312
|
+
error.status = this.status;
|
|
1313
|
+
error.method = this.method;
|
|
1314
|
+
error.url = this.url;
|
|
1315
|
+
this.callback(error);
|
|
1157
1316
|
}; // This only warns, because the request is still likely to work
|
|
1158
1317
|
|
|
1159
1318
|
|
|
@@ -1179,9 +1338,9 @@ Request.prototype.pipe = Request.prototype.write;
|
|
|
1179
1338
|
* @api private
|
|
1180
1339
|
*/
|
|
1181
1340
|
|
|
1182
|
-
Request.prototype._isHost = function (
|
|
1341
|
+
Request.prototype._isHost = function (object) {
|
|
1183
1342
|
// Native objects stringify to [object File], [object Blob], [object FormData], etc.
|
|
1184
|
-
return
|
|
1343
|
+
return object && _typeof(object) === 'object' && !_Array$isArray(object) && Object.prototype.toString.call(object) !== '[object Object]';
|
|
1185
1344
|
};
|
|
1186
1345
|
/**
|
|
1187
1346
|
* Initiate request, invoking callback `fn(res)`
|
|
@@ -1228,7 +1387,7 @@ Request.prototype._end = function () {
|
|
|
1228
1387
|
this._setTimeouts(); // state change
|
|
1229
1388
|
|
|
1230
1389
|
|
|
1231
|
-
xhr.
|
|
1390
|
+
xhr.addEventListener('readystatechange', function () {
|
|
1232
1391
|
var readyState = xhr.readyState;
|
|
1233
1392
|
|
|
1234
1393
|
if (readyState >= 2 && self._responseTimeoutTimer) {
|
|
@@ -1255,8 +1414,7 @@ Request.prototype._end = function () {
|
|
|
1255
1414
|
}
|
|
1256
1415
|
|
|
1257
1416
|
self.emit('end');
|
|
1258
|
-
}; // progress
|
|
1259
|
-
|
|
1417
|
+
}); // progress
|
|
1260
1418
|
|
|
1261
1419
|
var handleProgress = function handleProgress(direction, e) {
|
|
1262
1420
|
if (e.total > 0) {
|
|
@@ -1319,7 +1477,7 @@ Request.prototype._end = function () {
|
|
|
1319
1477
|
|
|
1320
1478
|
for (var field in this.header) {
|
|
1321
1479
|
if (this.header[field] === null) continue;
|
|
1322
|
-
if (
|
|
1480
|
+
if (hasOwn(this.header, field)) xhr.setRequestHeader(field, this.header[field]);
|
|
1323
1481
|
}
|
|
1324
1482
|
|
|
1325
1483
|
if (this._responseType) {
|
|
@@ -1337,19 +1495,25 @@ request.agent = function () {
|
|
|
1337
1495
|
return new Agent();
|
|
1338
1496
|
};
|
|
1339
1497
|
|
|
1340
|
-
|
|
1498
|
+
var _loop = function _loop() {
|
|
1499
|
+
var method = _arr[_i];
|
|
1500
|
+
|
|
1341
1501
|
Agent.prototype[method.toLowerCase()] = function (url, fn) {
|
|
1342
|
-
var
|
|
1502
|
+
var request_ = new request.Request(method, url);
|
|
1343
1503
|
|
|
1344
|
-
this._setDefaults(
|
|
1504
|
+
this._setDefaults(request_);
|
|
1345
1505
|
|
|
1346
1506
|
if (fn) {
|
|
1347
|
-
|
|
1507
|
+
request_.end(fn);
|
|
1348
1508
|
}
|
|
1349
1509
|
|
|
1350
|
-
return
|
|
1510
|
+
return request_;
|
|
1351
1511
|
};
|
|
1352
|
-
}
|
|
1512
|
+
};
|
|
1513
|
+
|
|
1514
|
+
for (var _i = 0, _arr = ['GET', 'POST', 'OPTIONS', 'PATCH', 'PUT', 'DELETE']; _i < _arr.length; _i++) {
|
|
1515
|
+
_loop();
|
|
1516
|
+
}
|
|
1353
1517
|
|
|
1354
1518
|
Agent.prototype.del = Agent.prototype.delete;
|
|
1355
1519
|
/**
|
|
@@ -1363,16 +1527,16 @@ Agent.prototype.del = Agent.prototype.delete;
|
|
|
1363
1527
|
*/
|
|
1364
1528
|
|
|
1365
1529
|
request.get = function (url, data, fn) {
|
|
1366
|
-
var
|
|
1530
|
+
var request_ = request('GET', url);
|
|
1367
1531
|
|
|
1368
1532
|
if (typeof data === 'function') {
|
|
1369
1533
|
fn = data;
|
|
1370
1534
|
data = null;
|
|
1371
1535
|
}
|
|
1372
1536
|
|
|
1373
|
-
if (data)
|
|
1374
|
-
if (fn)
|
|
1375
|
-
return
|
|
1537
|
+
if (data) request_.query(data);
|
|
1538
|
+
if (fn) request_.end(fn);
|
|
1539
|
+
return request_;
|
|
1376
1540
|
};
|
|
1377
1541
|
/**
|
|
1378
1542
|
* HEAD `url` with optional callback `fn(res)`.
|
|
@@ -1386,16 +1550,16 @@ request.get = function (url, data, fn) {
|
|
|
1386
1550
|
|
|
1387
1551
|
|
|
1388
1552
|
request.head = function (url, data, fn) {
|
|
1389
|
-
var
|
|
1553
|
+
var request_ = request('HEAD', url);
|
|
1390
1554
|
|
|
1391
1555
|
if (typeof data === 'function') {
|
|
1392
1556
|
fn = data;
|
|
1393
1557
|
data = null;
|
|
1394
1558
|
}
|
|
1395
1559
|
|
|
1396
|
-
if (data)
|
|
1397
|
-
if (fn)
|
|
1398
|
-
return
|
|
1560
|
+
if (data) request_.query(data);
|
|
1561
|
+
if (fn) request_.end(fn);
|
|
1562
|
+
return request_;
|
|
1399
1563
|
};
|
|
1400
1564
|
/**
|
|
1401
1565
|
* OPTIONS query to `url` with optional callback `fn(res)`.
|
|
@@ -1409,16 +1573,16 @@ request.head = function (url, data, fn) {
|
|
|
1409
1573
|
|
|
1410
1574
|
|
|
1411
1575
|
request.options = function (url, data, fn) {
|
|
1412
|
-
var
|
|
1576
|
+
var request_ = request('OPTIONS', url);
|
|
1413
1577
|
|
|
1414
1578
|
if (typeof data === 'function') {
|
|
1415
1579
|
fn = data;
|
|
1416
1580
|
data = null;
|
|
1417
1581
|
}
|
|
1418
1582
|
|
|
1419
|
-
if (data)
|
|
1420
|
-
if (fn)
|
|
1421
|
-
return
|
|
1583
|
+
if (data) request_.send(data);
|
|
1584
|
+
if (fn) request_.end(fn);
|
|
1585
|
+
return request_;
|
|
1422
1586
|
};
|
|
1423
1587
|
/**
|
|
1424
1588
|
* DELETE `url` with optional `data` and callback `fn(res)`.
|
|
@@ -1432,16 +1596,16 @@ request.options = function (url, data, fn) {
|
|
|
1432
1596
|
|
|
1433
1597
|
|
|
1434
1598
|
function del(url, data, fn) {
|
|
1435
|
-
var
|
|
1599
|
+
var request_ = request('DELETE', url);
|
|
1436
1600
|
|
|
1437
1601
|
if (typeof data === 'function') {
|
|
1438
1602
|
fn = data;
|
|
1439
1603
|
data = null;
|
|
1440
1604
|
}
|
|
1441
1605
|
|
|
1442
|
-
if (data)
|
|
1443
|
-
if (fn)
|
|
1444
|
-
return
|
|
1606
|
+
if (data) request_.send(data);
|
|
1607
|
+
if (fn) request_.end(fn);
|
|
1608
|
+
return request_;
|
|
1445
1609
|
}
|
|
1446
1610
|
|
|
1447
1611
|
request.del = del;
|
|
@@ -1457,16 +1621,16 @@ request.delete = del;
|
|
|
1457
1621
|
*/
|
|
1458
1622
|
|
|
1459
1623
|
request.patch = function (url, data, fn) {
|
|
1460
|
-
var
|
|
1624
|
+
var request_ = request('PATCH', url);
|
|
1461
1625
|
|
|
1462
1626
|
if (typeof data === 'function') {
|
|
1463
1627
|
fn = data;
|
|
1464
1628
|
data = null;
|
|
1465
1629
|
}
|
|
1466
1630
|
|
|
1467
|
-
if (data)
|
|
1468
|
-
if (fn)
|
|
1469
|
-
return
|
|
1631
|
+
if (data) request_.send(data);
|
|
1632
|
+
if (fn) request_.end(fn);
|
|
1633
|
+
return request_;
|
|
1470
1634
|
};
|
|
1471
1635
|
/**
|
|
1472
1636
|
* POST `url` with optional `data` and callback `fn(res)`.
|
|
@@ -1480,16 +1644,16 @@ request.patch = function (url, data, fn) {
|
|
|
1480
1644
|
|
|
1481
1645
|
|
|
1482
1646
|
request.post = function (url, data, fn) {
|
|
1483
|
-
var
|
|
1647
|
+
var request_ = request('POST', url);
|
|
1484
1648
|
|
|
1485
1649
|
if (typeof data === 'function') {
|
|
1486
1650
|
fn = data;
|
|
1487
1651
|
data = null;
|
|
1488
1652
|
}
|
|
1489
1653
|
|
|
1490
|
-
if (data)
|
|
1491
|
-
if (fn)
|
|
1492
|
-
return
|
|
1654
|
+
if (data) request_.send(data);
|
|
1655
|
+
if (fn) request_.end(fn);
|
|
1656
|
+
return request_;
|
|
1493
1657
|
};
|
|
1494
1658
|
/**
|
|
1495
1659
|
* PUT `url` with optional `data` and callback `fn(res)`.
|
|
@@ -1503,62 +1667,20 @@ request.post = function (url, data, fn) {
|
|
|
1503
1667
|
|
|
1504
1668
|
|
|
1505
1669
|
request.put = function (url, data, fn) {
|
|
1506
|
-
var
|
|
1670
|
+
var request_ = request('PUT', url);
|
|
1507
1671
|
|
|
1508
1672
|
if (typeof data === 'function') {
|
|
1509
1673
|
fn = data;
|
|
1510
1674
|
data = null;
|
|
1511
1675
|
}
|
|
1512
1676
|
|
|
1513
|
-
if (data)
|
|
1514
|
-
if (fn)
|
|
1515
|
-
return
|
|
1677
|
+
if (data) request_.send(data);
|
|
1678
|
+
if (fn) request_.end(fn);
|
|
1679
|
+
return request_;
|
|
1516
1680
|
};
|
|
1517
1681
|
|
|
1518
1682
|
/***/ }),
|
|
1519
1683
|
|
|
1520
|
-
/***/ 3508:
|
|
1521
|
-
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
1522
|
-
|
|
1523
|
-
"use strict";
|
|
1524
|
-
|
|
1525
|
-
|
|
1526
|
-
var _Symbol = __webpack_require__(5420);
|
|
1527
|
-
|
|
1528
|
-
var _Symbol$iterator = __webpack_require__(8341);
|
|
1529
|
-
|
|
1530
|
-
function _typeof(obj) {
|
|
1531
|
-
"@babel/helpers - typeof";
|
|
1532
|
-
|
|
1533
|
-
if (typeof _Symbol === "function" && typeof _Symbol$iterator === "symbol") {
|
|
1534
|
-
_typeof = function _typeof(obj) {
|
|
1535
|
-
return typeof obj;
|
|
1536
|
-
};
|
|
1537
|
-
} else {
|
|
1538
|
-
_typeof = function _typeof(obj) {
|
|
1539
|
-
return obj && typeof _Symbol === "function" && obj.constructor === _Symbol && obj !== _Symbol.prototype ? "symbol" : typeof obj;
|
|
1540
|
-
};
|
|
1541
|
-
}
|
|
1542
|
-
|
|
1543
|
-
return _typeof(obj);
|
|
1544
|
-
}
|
|
1545
|
-
/**
|
|
1546
|
-
* Check if `obj` is an object.
|
|
1547
|
-
*
|
|
1548
|
-
* @param {Object} obj
|
|
1549
|
-
* @return {Boolean}
|
|
1550
|
-
* @api private
|
|
1551
|
-
*/
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
function isObject(obj) {
|
|
1555
|
-
return obj !== null && _typeof(obj) === 'object';
|
|
1556
|
-
}
|
|
1557
|
-
|
|
1558
|
-
module.exports = isObject;
|
|
1559
|
-
|
|
1560
|
-
/***/ }),
|
|
1561
|
-
|
|
1562
1684
|
/***/ 8842:
|
|
1563
1685
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
1564
1686
|
|
|
@@ -1592,24 +1714,22 @@ var _setTimeout = __webpack_require__(3032);
|
|
|
1592
1714
|
function _typeof(obj) {
|
|
1593
1715
|
"@babel/helpers - typeof";
|
|
1594
1716
|
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
}
|
|
1600
|
-
_typeof = function _typeof(obj) {
|
|
1601
|
-
return obj && typeof _Symbol === "function" && obj.constructor === _Symbol && obj !== _Symbol.prototype ? "symbol" : typeof obj;
|
|
1602
|
-
};
|
|
1603
|
-
}
|
|
1604
|
-
|
|
1605
|
-
return _typeof(obj);
|
|
1717
|
+
return _typeof = "function" == typeof _Symbol && "symbol" == typeof _Symbol$iterator ? function (obj) {
|
|
1718
|
+
return typeof obj;
|
|
1719
|
+
} : function (obj) {
|
|
1720
|
+
return obj && "function" == typeof _Symbol && obj.constructor === _Symbol && obj !== _Symbol.prototype ? "symbol" : typeof obj;
|
|
1721
|
+
}, _typeof(obj);
|
|
1606
1722
|
}
|
|
1723
|
+
|
|
1724
|
+
var semver = __webpack_require__(3695);
|
|
1607
1725
|
/**
|
|
1608
1726
|
* Module of mixed-in functions shared between node and client code
|
|
1609
1727
|
*/
|
|
1610
1728
|
|
|
1611
1729
|
|
|
1612
|
-
var
|
|
1730
|
+
var _require = __webpack_require__(6244),
|
|
1731
|
+
isObject = _require.isObject,
|
|
1732
|
+
hasOwn = _require.hasOwn;
|
|
1613
1733
|
/**
|
|
1614
1734
|
* Expose `RequestBase`.
|
|
1615
1735
|
*/
|
|
@@ -1622,25 +1742,7 @@ module.exports = RequestBase;
|
|
|
1622
1742
|
* @api public
|
|
1623
1743
|
*/
|
|
1624
1744
|
|
|
1625
|
-
function RequestBase(
|
|
1626
|
-
if (object) return mixin(object);
|
|
1627
|
-
}
|
|
1628
|
-
/**
|
|
1629
|
-
* Mixin the prototype properties.
|
|
1630
|
-
*
|
|
1631
|
-
* @param {Object} obj
|
|
1632
|
-
* @return {Object}
|
|
1633
|
-
* @api private
|
|
1634
|
-
*/
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
function mixin(object) {
|
|
1638
|
-
for (var key in RequestBase.prototype) {
|
|
1639
|
-
if (Object.prototype.hasOwnProperty.call(RequestBase.prototype, key)) object[key] = RequestBase.prototype[key];
|
|
1640
|
-
}
|
|
1641
|
-
|
|
1642
|
-
return object;
|
|
1643
|
-
}
|
|
1745
|
+
function RequestBase() {}
|
|
1644
1746
|
/**
|
|
1645
1747
|
* Clear previous timeout.
|
|
1646
1748
|
*
|
|
@@ -1733,7 +1835,7 @@ RequestBase.prototype.timeout = function (options) {
|
|
|
1733
1835
|
}
|
|
1734
1836
|
|
|
1735
1837
|
for (var option in options) {
|
|
1736
|
-
if (
|
|
1838
|
+
if (hasOwn(options, option)) {
|
|
1737
1839
|
switch (option) {
|
|
1738
1840
|
case 'deadline':
|
|
1739
1841
|
this._timeout = options.deadline;
|
|
@@ -1801,19 +1903,19 @@ var STATUS_CODES = new _Set([408, 413, 429, 500, 502, 503, 504, 521, 522, 524]);
|
|
|
1801
1903
|
* @returns {Boolean} if segment should be retried
|
|
1802
1904
|
*/
|
|
1803
1905
|
|
|
1804
|
-
RequestBase.prototype._shouldRetry = function (
|
|
1906
|
+
RequestBase.prototype._shouldRetry = function (error, res) {
|
|
1805
1907
|
if (!this._maxRetries || this._retries++ >= this._maxRetries) {
|
|
1806
1908
|
return false;
|
|
1807
1909
|
}
|
|
1808
1910
|
|
|
1809
1911
|
if (this._retryCallback) {
|
|
1810
1912
|
try {
|
|
1811
|
-
var override = this._retryCallback(
|
|
1913
|
+
var override = this._retryCallback(error, res);
|
|
1812
1914
|
|
|
1813
1915
|
if (override === true) return true;
|
|
1814
1916
|
if (override === false) return false; // undefined falls back to defaults
|
|
1815
|
-
} catch (
|
|
1816
|
-
console.error(
|
|
1917
|
+
} catch (error_) {
|
|
1918
|
+
console.error(error_);
|
|
1817
1919
|
}
|
|
1818
1920
|
} // TODO: we would need to make this easily configurable before adding it in (e.g. some might want to add POST)
|
|
1819
1921
|
|
|
@@ -1829,11 +1931,11 @@ RequestBase.prototype._shouldRetry = function (err, res) {
|
|
|
1829
1931
|
|
|
1830
1932
|
if (res && res.status && STATUS_CODES.has(res.status)) return true;
|
|
1831
1933
|
|
|
1832
|
-
if (
|
|
1833
|
-
if (
|
|
1934
|
+
if (error) {
|
|
1935
|
+
if (error.code && ERROR_CODES.has(error.code)) return true; // Superagent timeout
|
|
1834
1936
|
|
|
1835
|
-
if (
|
|
1836
|
-
if (
|
|
1937
|
+
if (error.timeout && error.code === 'ECONNABORTED') return true;
|
|
1938
|
+
if (error.crossDomain) return true;
|
|
1837
1939
|
}
|
|
1838
1940
|
|
|
1839
1941
|
return false;
|
|
@@ -1889,15 +1991,15 @@ RequestBase.prototype.then = function (resolve, reject) {
|
|
|
1889
1991
|
return;
|
|
1890
1992
|
}
|
|
1891
1993
|
|
|
1892
|
-
var
|
|
1893
|
-
|
|
1894
|
-
|
|
1895
|
-
|
|
1896
|
-
|
|
1897
|
-
reject(
|
|
1994
|
+
var error = new Error('Aborted');
|
|
1995
|
+
error.code = 'ABORTED';
|
|
1996
|
+
error.status = _this.status;
|
|
1997
|
+
error.method = _this.method;
|
|
1998
|
+
error.url = _this.url;
|
|
1999
|
+
reject(error);
|
|
1898
2000
|
});
|
|
1899
|
-
self.end(function (
|
|
1900
|
-
if (
|
|
2001
|
+
self.end(function (error, res) {
|
|
2002
|
+
if (error) reject(error);else resolve(res);
|
|
1901
2003
|
});
|
|
1902
2004
|
});
|
|
1903
2005
|
}
|
|
@@ -1986,7 +2088,7 @@ RequestBase.prototype.getHeader = RequestBase.prototype.get;
|
|
|
1986
2088
|
RequestBase.prototype.set = function (field, value) {
|
|
1987
2089
|
if (isObject(field)) {
|
|
1988
2090
|
for (var key in field) {
|
|
1989
|
-
if (
|
|
2091
|
+
if (hasOwn(field, key)) this.set(key, field[key]);
|
|
1990
2092
|
}
|
|
1991
2093
|
|
|
1992
2094
|
return this;
|
|
@@ -2031,12 +2133,13 @@ RequestBase.prototype.unset = function (field) {
|
|
|
2031
2133
|
*
|
|
2032
2134
|
* @param {String|Object} name name of field
|
|
2033
2135
|
* @param {String|Blob|File|Buffer|fs.ReadStream} val value of field
|
|
2136
|
+
* @param {String} options extra options, e.g. 'blob'
|
|
2034
2137
|
* @return {Request} for chaining
|
|
2035
2138
|
* @api public
|
|
2036
2139
|
*/
|
|
2037
2140
|
|
|
2038
2141
|
|
|
2039
|
-
RequestBase.prototype.field = function (name, value) {
|
|
2142
|
+
RequestBase.prototype.field = function (name, value, options) {
|
|
2040
2143
|
// name should be either a string or an object.
|
|
2041
2144
|
if (name === null || undefined === name) {
|
|
2042
2145
|
throw new Error('.field(name, val) name can not be empty');
|
|
@@ -2048,7 +2151,7 @@ RequestBase.prototype.field = function (name, value) {
|
|
|
2048
2151
|
|
|
2049
2152
|
if (isObject(name)) {
|
|
2050
2153
|
for (var key in name) {
|
|
2051
|
-
if (
|
|
2154
|
+
if (hasOwn(name, key)) this.field(key, name[key]);
|
|
2052
2155
|
}
|
|
2053
2156
|
|
|
2054
2157
|
return this;
|
|
@@ -2056,7 +2159,7 @@ RequestBase.prototype.field = function (name, value) {
|
|
|
2056
2159
|
|
|
2057
2160
|
if (_Array$isArray(value)) {
|
|
2058
2161
|
for (var i in value) {
|
|
2059
|
-
if (
|
|
2162
|
+
if (hasOwn(value, i)) this.field(name, value[i]);
|
|
2060
2163
|
}
|
|
2061
2164
|
|
|
2062
2165
|
return this;
|
|
@@ -2071,7 +2174,7 @@ RequestBase.prototype.field = function (name, value) {
|
|
|
2071
2174
|
value = String(value);
|
|
2072
2175
|
}
|
|
2073
2176
|
|
|
2074
|
-
this._getFormData().append(name, value);
|
|
2177
|
+
this._getFormData().append(name, value, options);
|
|
2075
2178
|
|
|
2076
2179
|
return this;
|
|
2077
2180
|
};
|
|
@@ -2091,7 +2194,30 @@ RequestBase.prototype.abort = function () {
|
|
|
2091
2194
|
this._aborted = true;
|
|
2092
2195
|
if (this.xhr) this.xhr.abort(); // browser
|
|
2093
2196
|
|
|
2094
|
-
if (this.req)
|
|
2197
|
+
if (this.req) {
|
|
2198
|
+
// Node v13 has major differences in `abort()`
|
|
2199
|
+
// https://github.com/nodejs/node/blob/v12.x/lib/internal/streams/end-of-stream.js
|
|
2200
|
+
// https://github.com/nodejs/node/blob/v13.x/lib/internal/streams/end-of-stream.js
|
|
2201
|
+
// https://github.com/nodejs/node/blob/v14.x/lib/internal/streams/end-of-stream.js
|
|
2202
|
+
// (if you run a diff across these you will see the differences)
|
|
2203
|
+
//
|
|
2204
|
+
// References:
|
|
2205
|
+
// <https://github.com/nodejs/node/issues/31630>
|
|
2206
|
+
// <https://github.com/visionmedia/superagent/pull/1084/commits/dc18679a7c5ccfc6046d882015e5126888973bc8>
|
|
2207
|
+
//
|
|
2208
|
+
// Thanks to @shadowgate15 and @niftylettuce
|
|
2209
|
+
if (semver.gte(process.version, 'v13.0.0') && semver.lt(process.version, 'v14.0.0')) {
|
|
2210
|
+
// Note that the reason this doesn't work is because in v13 as compared to v14
|
|
2211
|
+
// there is no `callback = nop` set in end-of-stream.js above
|
|
2212
|
+
throw new Error('Superagent does not work in v13 properly with abort() due to Node.js core changes');
|
|
2213
|
+
} else if (semver.gte(process.version, 'v14.0.0')) {
|
|
2214
|
+
// We have to manually set `destroyed` to `true` in order for this to work
|
|
2215
|
+
// (see core internals of end-of-stream.js above in v14 branch as compared to v12)
|
|
2216
|
+
this.req.destroyed = true;
|
|
2217
|
+
}
|
|
2218
|
+
|
|
2219
|
+
this.req.abort(); // node
|
|
2220
|
+
}
|
|
2095
2221
|
|
|
2096
2222
|
this.clearTimeout();
|
|
2097
2223
|
this.emit('abort');
|
|
@@ -2251,7 +2377,7 @@ RequestBase.prototype.send = function (data) {
|
|
|
2251
2377
|
|
|
2252
2378
|
if (isObject_ && isObject(this._data)) {
|
|
2253
2379
|
for (var key in data) {
|
|
2254
|
-
if (
|
|
2380
|
+
if (hasOwn(data, key)) this._data[key] = data[key];
|
|
2255
2381
|
}
|
|
2256
2382
|
} else if (typeof data === 'string') {
|
|
2257
2383
|
var _context2;
|
|
@@ -2369,14 +2495,14 @@ RequestBase.prototype._timeoutError = function (reason, timeout, errno) {
|
|
|
2369
2495
|
return;
|
|
2370
2496
|
}
|
|
2371
2497
|
|
|
2372
|
-
var
|
|
2373
|
-
|
|
2374
|
-
|
|
2375
|
-
|
|
2498
|
+
var error = new Error("".concat(reason + timeout, "ms exceeded"));
|
|
2499
|
+
error.timeout = timeout;
|
|
2500
|
+
error.code = 'ECONNABORTED';
|
|
2501
|
+
error.errno = errno;
|
|
2376
2502
|
this.timedout = true;
|
|
2377
|
-
this.timedoutError =
|
|
2503
|
+
this.timedoutError = error;
|
|
2378
2504
|
this.abort();
|
|
2379
|
-
this.callback(
|
|
2505
|
+
this.callback(error);
|
|
2380
2506
|
};
|
|
2381
2507
|
|
|
2382
2508
|
RequestBase.prototype._setTimeouts = function () {
|
|
@@ -2407,6 +2533,8 @@ RequestBase.prototype._setTimeouts = function () {
|
|
|
2407
2533
|
* Module dependencies.
|
|
2408
2534
|
*/
|
|
2409
2535
|
|
|
2536
|
+
var _Math$trunc = __webpack_require__(925);
|
|
2537
|
+
|
|
2410
2538
|
var utils = __webpack_require__(6244);
|
|
2411
2539
|
/**
|
|
2412
2540
|
* Expose `ResponseBase`.
|
|
@@ -2420,25 +2548,7 @@ module.exports = ResponseBase;
|
|
|
2420
2548
|
* @api public
|
|
2421
2549
|
*/
|
|
2422
2550
|
|
|
2423
|
-
function ResponseBase(
|
|
2424
|
-
if (obj) return mixin(obj);
|
|
2425
|
-
}
|
|
2426
|
-
/**
|
|
2427
|
-
* Mixin the prototype properties.
|
|
2428
|
-
*
|
|
2429
|
-
* @param {Object} obj
|
|
2430
|
-
* @return {Object}
|
|
2431
|
-
* @api private
|
|
2432
|
-
*/
|
|
2433
|
-
|
|
2434
|
-
|
|
2435
|
-
function mixin(obj) {
|
|
2436
|
-
for (var key in ResponseBase.prototype) {
|
|
2437
|
-
if (Object.prototype.hasOwnProperty.call(ResponseBase.prototype, key)) obj[key] = ResponseBase.prototype[key];
|
|
2438
|
-
}
|
|
2439
|
-
|
|
2440
|
-
return obj;
|
|
2441
|
-
}
|
|
2551
|
+
function ResponseBase() {}
|
|
2442
2552
|
/**
|
|
2443
2553
|
* Get case-insensitive `field` value.
|
|
2444
2554
|
*
|
|
@@ -2471,10 +2581,10 @@ ResponseBase.prototype._setHeaderProperties = function (header) {
|
|
|
2471
2581
|
var ct = header['content-type'] || '';
|
|
2472
2582
|
this.type = utils.type(ct); // params
|
|
2473
2583
|
|
|
2474
|
-
var
|
|
2584
|
+
var parameters = utils.params(ct);
|
|
2475
2585
|
|
|
2476
|
-
for (var key in
|
|
2477
|
-
if (Object.prototype.hasOwnProperty.call(
|
|
2586
|
+
for (var key in parameters) {
|
|
2587
|
+
if (Object.prototype.hasOwnProperty.call(parameters, key)) this[key] = parameters[key];
|
|
2478
2588
|
}
|
|
2479
2589
|
|
|
2480
2590
|
this.links = {}; // links
|
|
@@ -2509,7 +2619,8 @@ ResponseBase.prototype._setHeaderProperties = function (header) {
|
|
|
2509
2619
|
|
|
2510
2620
|
|
|
2511
2621
|
ResponseBase.prototype._setStatusProperties = function (status) {
|
|
2512
|
-
var type = status / 100
|
|
2622
|
+
var type = _Math$trunc(status / 100); // status / class
|
|
2623
|
+
|
|
2513
2624
|
|
|
2514
2625
|
this.statusCode = status;
|
|
2515
2626
|
this.status = this.statusCode;
|
|
@@ -2543,20 +2654,30 @@ ResponseBase.prototype._setStatusProperties = function (status) {
|
|
|
2543
2654
|
|
|
2544
2655
|
var _Symbol = __webpack_require__(5420);
|
|
2545
2656
|
|
|
2657
|
+
var _Symbol$iterator = __webpack_require__(8341);
|
|
2658
|
+
|
|
2546
2659
|
var _getIteratorMethod = __webpack_require__(9996);
|
|
2547
2660
|
|
|
2548
2661
|
var _Array$isArray = __webpack_require__(1511);
|
|
2549
2662
|
|
|
2550
|
-
var _getIterator = __webpack_require__(6976);
|
|
2551
|
-
|
|
2552
2663
|
var _sliceInstanceProperty = __webpack_require__(3649);
|
|
2553
2664
|
|
|
2554
2665
|
var _Array$from = __webpack_require__(6419);
|
|
2555
2666
|
|
|
2667
|
+
function _typeof(obj) {
|
|
2668
|
+
"@babel/helpers - typeof";
|
|
2669
|
+
|
|
2670
|
+
return _typeof = "function" == typeof _Symbol && "symbol" == typeof _Symbol$iterator ? function (obj) {
|
|
2671
|
+
return typeof obj;
|
|
2672
|
+
} : function (obj) {
|
|
2673
|
+
return obj && "function" == typeof _Symbol && obj.constructor === _Symbol && obj !== _Symbol.prototype ? "symbol" : typeof obj;
|
|
2674
|
+
}, _typeof(obj);
|
|
2675
|
+
}
|
|
2676
|
+
|
|
2556
2677
|
function _createForOfIteratorHelper(o, allowArrayLike) {
|
|
2557
|
-
var it;
|
|
2678
|
+
var it = typeof _Symbol !== "undefined" && _getIteratorMethod(o) || o["@@iterator"];
|
|
2558
2679
|
|
|
2559
|
-
if (
|
|
2680
|
+
if (!it) {
|
|
2560
2681
|
if (_Array$isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") {
|
|
2561
2682
|
if (it) o = it;
|
|
2562
2683
|
var i = 0;
|
|
@@ -2589,7 +2710,7 @@ function _createForOfIteratorHelper(o, allowArrayLike) {
|
|
|
2589
2710
|
err;
|
|
2590
2711
|
return {
|
|
2591
2712
|
s: function s() {
|
|
2592
|
-
it =
|
|
2713
|
+
it = it.call(o);
|
|
2593
2714
|
},
|
|
2594
2715
|
n: function n() {
|
|
2595
2716
|
var step = it.next();
|
|
@@ -2641,8 +2762,8 @@ function _arrayLikeToArray(arr, len) {
|
|
|
2641
2762
|
*/
|
|
2642
2763
|
|
|
2643
2764
|
|
|
2644
|
-
exports.type = function (
|
|
2645
|
-
return
|
|
2765
|
+
exports.type = function (string_) {
|
|
2766
|
+
return string_.split(/ *; */).shift();
|
|
2646
2767
|
};
|
|
2647
2768
|
/**
|
|
2648
2769
|
* Return header field parameters.
|
|
@@ -2653,21 +2774,21 @@ exports.type = function (str) {
|
|
|
2653
2774
|
*/
|
|
2654
2775
|
|
|
2655
2776
|
|
|
2656
|
-
exports.params = function (
|
|
2657
|
-
var
|
|
2777
|
+
exports.params = function (value) {
|
|
2778
|
+
var object = {};
|
|
2658
2779
|
|
|
2659
|
-
var _iterator = _createForOfIteratorHelper(
|
|
2780
|
+
var _iterator = _createForOfIteratorHelper(value.split(/ *; */)),
|
|
2660
2781
|
_step;
|
|
2661
2782
|
|
|
2662
2783
|
try {
|
|
2663
2784
|
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
2664
|
-
var
|
|
2665
|
-
var parts =
|
|
2785
|
+
var string_ = _step.value;
|
|
2786
|
+
var parts = string_.split(/ *= */);
|
|
2666
2787
|
var key = parts.shift();
|
|
2667
2788
|
|
|
2668
|
-
var
|
|
2789
|
+
var _value = parts.shift();
|
|
2669
2790
|
|
|
2670
|
-
if (key &&
|
|
2791
|
+
if (key && _value) object[key] = _value;
|
|
2671
2792
|
}
|
|
2672
2793
|
} catch (err) {
|
|
2673
2794
|
_iterator.e(err);
|
|
@@ -2675,7 +2796,7 @@ exports.params = function (val) {
|
|
|
2675
2796
|
_iterator.f();
|
|
2676
2797
|
}
|
|
2677
2798
|
|
|
2678
|
-
return
|
|
2799
|
+
return object;
|
|
2679
2800
|
};
|
|
2680
2801
|
/**
|
|
2681
2802
|
* Parse Link header fields.
|
|
@@ -2686,24 +2807,24 @@ exports.params = function (val) {
|
|
|
2686
2807
|
*/
|
|
2687
2808
|
|
|
2688
2809
|
|
|
2689
|
-
exports.parseLinks = function (
|
|
2690
|
-
var
|
|
2810
|
+
exports.parseLinks = function (value) {
|
|
2811
|
+
var object = {};
|
|
2691
2812
|
|
|
2692
|
-
var _iterator2 = _createForOfIteratorHelper(
|
|
2813
|
+
var _iterator2 = _createForOfIteratorHelper(value.split(/ *, */)),
|
|
2693
2814
|
_step2;
|
|
2694
2815
|
|
|
2695
2816
|
try {
|
|
2696
2817
|
for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
|
|
2697
2818
|
var _context2, _context3;
|
|
2698
2819
|
|
|
2699
|
-
var
|
|
2700
|
-
var parts =
|
|
2820
|
+
var string_ = _step2.value;
|
|
2821
|
+
var parts = string_.split(/ *; */);
|
|
2701
2822
|
|
|
2702
2823
|
var url = _sliceInstanceProperty(_context2 = parts[0]).call(_context2, 1, -1);
|
|
2703
2824
|
|
|
2704
2825
|
var rel = _sliceInstanceProperty(_context3 = parts[1].split(/ *= */)[1]).call(_context3, 1, -1);
|
|
2705
2826
|
|
|
2706
|
-
|
|
2827
|
+
object[rel] = url;
|
|
2707
2828
|
}
|
|
2708
2829
|
} catch (err) {
|
|
2709
2830
|
_iterator2.e(err);
|
|
@@ -2711,7 +2832,7 @@ exports.parseLinks = function (val) {
|
|
|
2711
2832
|
_iterator2.f();
|
|
2712
2833
|
}
|
|
2713
2834
|
|
|
2714
|
-
return
|
|
2835
|
+
return object;
|
|
2715
2836
|
};
|
|
2716
2837
|
/**
|
|
2717
2838
|
* Strip content related fields from `header`.
|
|
@@ -2735,6 +2856,975 @@ exports.cleanHeader = function (header, changesOrigin) {
|
|
|
2735
2856
|
|
|
2736
2857
|
return header;
|
|
2737
2858
|
};
|
|
2859
|
+
/**
|
|
2860
|
+
* Check if `obj` is an object.
|
|
2861
|
+
*
|
|
2862
|
+
* @param {Object} object
|
|
2863
|
+
* @return {Boolean}
|
|
2864
|
+
* @api private
|
|
2865
|
+
*/
|
|
2866
|
+
|
|
2867
|
+
|
|
2868
|
+
exports.isObject = function (object) {
|
|
2869
|
+
return object !== null && _typeof(object) === 'object';
|
|
2870
|
+
};
|
|
2871
|
+
/**
|
|
2872
|
+
* Object.hasOwn fallback/polyfill.
|
|
2873
|
+
*
|
|
2874
|
+
* @type {(object: object, property: string) => boolean} object
|
|
2875
|
+
* @api private
|
|
2876
|
+
*/
|
|
2877
|
+
|
|
2878
|
+
|
|
2879
|
+
exports.hasOwn = Object.hasOwn || function (object, property) {
|
|
2880
|
+
if (object == null) {
|
|
2881
|
+
throw new TypeError('Cannot convert undefined or null to object');
|
|
2882
|
+
}
|
|
2883
|
+
|
|
2884
|
+
return Object.prototype.hasOwnProperty.call(new Object(object), property);
|
|
2885
|
+
};
|
|
2886
|
+
|
|
2887
|
+
exports.mixin = function (target, source) {
|
|
2888
|
+
for (var key in source) {
|
|
2889
|
+
if (exports.hasOwn(source, key)) {
|
|
2890
|
+
target[key] = source[key];
|
|
2891
|
+
}
|
|
2892
|
+
}
|
|
2893
|
+
};
|
|
2894
|
+
|
|
2895
|
+
/***/ }),
|
|
2896
|
+
|
|
2897
|
+
/***/ 3718:
|
|
2898
|
+
/***/ (function(module) {
|
|
2899
|
+
|
|
2900
|
+
"use strict";
|
|
2901
|
+
|
|
2902
|
+
|
|
2903
|
+
var replace = String.prototype.replace;
|
|
2904
|
+
var percentTwenties = /%20/g;
|
|
2905
|
+
var Format = {
|
|
2906
|
+
RFC1738: 'RFC1738',
|
|
2907
|
+
RFC3986: 'RFC3986'
|
|
2908
|
+
};
|
|
2909
|
+
module.exports = {
|
|
2910
|
+
'default': Format.RFC3986,
|
|
2911
|
+
formatters: {
|
|
2912
|
+
RFC1738: function (value) {
|
|
2913
|
+
return replace.call(value, percentTwenties, '+');
|
|
2914
|
+
},
|
|
2915
|
+
RFC3986: function (value) {
|
|
2916
|
+
return String(value);
|
|
2917
|
+
}
|
|
2918
|
+
},
|
|
2919
|
+
RFC1738: Format.RFC1738,
|
|
2920
|
+
RFC3986: Format.RFC3986
|
|
2921
|
+
};
|
|
2922
|
+
|
|
2923
|
+
/***/ }),
|
|
2924
|
+
|
|
2925
|
+
/***/ 2501:
|
|
2926
|
+
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
2927
|
+
|
|
2928
|
+
"use strict";
|
|
2929
|
+
|
|
2930
|
+
|
|
2931
|
+
var stringify = __webpack_require__(4383);
|
|
2932
|
+
|
|
2933
|
+
var parse = __webpack_require__(4409);
|
|
2934
|
+
|
|
2935
|
+
var formats = __webpack_require__(3718);
|
|
2936
|
+
|
|
2937
|
+
module.exports = {
|
|
2938
|
+
formats: formats,
|
|
2939
|
+
parse: parse,
|
|
2940
|
+
stringify: stringify
|
|
2941
|
+
};
|
|
2942
|
+
|
|
2943
|
+
/***/ }),
|
|
2944
|
+
|
|
2945
|
+
/***/ 4409:
|
|
2946
|
+
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
2947
|
+
|
|
2948
|
+
"use strict";
|
|
2949
|
+
|
|
2950
|
+
|
|
2951
|
+
var _Array$isArray = __webpack_require__(1511);
|
|
2952
|
+
|
|
2953
|
+
var _parseInt = __webpack_require__(4198);
|
|
2954
|
+
|
|
2955
|
+
var _indexOfInstanceProperty = __webpack_require__(1643);
|
|
2956
|
+
|
|
2957
|
+
var _sliceInstanceProperty = __webpack_require__(3649);
|
|
2958
|
+
|
|
2959
|
+
var _concatInstanceProperty = __webpack_require__(7766);
|
|
2960
|
+
|
|
2961
|
+
var _Object$create = __webpack_require__(4943);
|
|
2962
|
+
|
|
2963
|
+
var _Object$keys = __webpack_require__(6902);
|
|
2964
|
+
|
|
2965
|
+
var utils = __webpack_require__(4753);
|
|
2966
|
+
|
|
2967
|
+
var has = Object.prototype.hasOwnProperty;
|
|
2968
|
+
var isArray = _Array$isArray;
|
|
2969
|
+
var defaults = {
|
|
2970
|
+
allowDots: false,
|
|
2971
|
+
allowPrototypes: false,
|
|
2972
|
+
allowSparse: false,
|
|
2973
|
+
arrayLimit: 20,
|
|
2974
|
+
charset: 'utf-8',
|
|
2975
|
+
charsetSentinel: false,
|
|
2976
|
+
comma: false,
|
|
2977
|
+
decoder: utils.decode,
|
|
2978
|
+
delimiter: '&',
|
|
2979
|
+
depth: 5,
|
|
2980
|
+
ignoreQueryPrefix: false,
|
|
2981
|
+
interpretNumericEntities: false,
|
|
2982
|
+
parameterLimit: 1000,
|
|
2983
|
+
parseArrays: true,
|
|
2984
|
+
plainObjects: false,
|
|
2985
|
+
strictNullHandling: false
|
|
2986
|
+
};
|
|
2987
|
+
|
|
2988
|
+
var interpretNumericEntities = function (str) {
|
|
2989
|
+
return str.replace(/&#(\d+);/g, function ($0, numberStr) {
|
|
2990
|
+
return String.fromCharCode(_parseInt(numberStr, 10));
|
|
2991
|
+
});
|
|
2992
|
+
};
|
|
2993
|
+
|
|
2994
|
+
var parseArrayValue = function (val, options) {
|
|
2995
|
+
if (val && typeof val === 'string' && options.comma && _indexOfInstanceProperty(val).call(val, ',') > -1) {
|
|
2996
|
+
return val.split(',');
|
|
2997
|
+
}
|
|
2998
|
+
|
|
2999
|
+
return val;
|
|
3000
|
+
}; // This is what browsers will submit when the ✓ character occurs in an
|
|
3001
|
+
// application/x-www-form-urlencoded body and the encoding of the page containing
|
|
3002
|
+
// the form is iso-8859-1, or when the submitted form has an accept-charset
|
|
3003
|
+
// attribute of iso-8859-1. Presumably also with other charsets that do not contain
|
|
3004
|
+
// the ✓ character, such as us-ascii.
|
|
3005
|
+
|
|
3006
|
+
|
|
3007
|
+
var isoSentinel = 'utf8=%26%2310003%3B'; // encodeURIComponent('✓')
|
|
3008
|
+
// These are the percent-encoded utf-8 octets representing a checkmark, indicating that the request actually is utf-8 encoded.
|
|
3009
|
+
|
|
3010
|
+
var charsetSentinel = 'utf8=%E2%9C%93'; // encodeURIComponent('✓')
|
|
3011
|
+
|
|
3012
|
+
var parseValues = function parseQueryStringValues(str, options) {
|
|
3013
|
+
var obj = {};
|
|
3014
|
+
var cleanStr = options.ignoreQueryPrefix ? str.replace(/^\?/, '') : str;
|
|
3015
|
+
var limit = options.parameterLimit === Infinity ? undefined : options.parameterLimit;
|
|
3016
|
+
var parts = cleanStr.split(options.delimiter, limit);
|
|
3017
|
+
var skipIndex = -1; // Keep track of where the utf8 sentinel was found
|
|
3018
|
+
|
|
3019
|
+
var i;
|
|
3020
|
+
var charset = options.charset;
|
|
3021
|
+
|
|
3022
|
+
if (options.charsetSentinel) {
|
|
3023
|
+
for (i = 0; i < parts.length; ++i) {
|
|
3024
|
+
var _context;
|
|
3025
|
+
|
|
3026
|
+
if (_indexOfInstanceProperty(_context = parts[i]).call(_context, 'utf8=') === 0) {
|
|
3027
|
+
if (parts[i] === charsetSentinel) {
|
|
3028
|
+
charset = 'utf-8';
|
|
3029
|
+
} else if (parts[i] === isoSentinel) {
|
|
3030
|
+
charset = 'iso-8859-1';
|
|
3031
|
+
}
|
|
3032
|
+
|
|
3033
|
+
skipIndex = i;
|
|
3034
|
+
i = parts.length; // The eslint settings do not allow break;
|
|
3035
|
+
}
|
|
3036
|
+
}
|
|
3037
|
+
}
|
|
3038
|
+
|
|
3039
|
+
for (i = 0; i < parts.length; ++i) {
|
|
3040
|
+
if (i === skipIndex) {
|
|
3041
|
+
continue;
|
|
3042
|
+
}
|
|
3043
|
+
|
|
3044
|
+
var part = parts[i];
|
|
3045
|
+
|
|
3046
|
+
var bracketEqualsPos = _indexOfInstanceProperty(part).call(part, ']=');
|
|
3047
|
+
|
|
3048
|
+
var pos = bracketEqualsPos === -1 ? _indexOfInstanceProperty(part).call(part, '=') : bracketEqualsPos + 1;
|
|
3049
|
+
var key, val;
|
|
3050
|
+
|
|
3051
|
+
if (pos === -1) {
|
|
3052
|
+
key = options.decoder(part, defaults.decoder, charset, 'key');
|
|
3053
|
+
val = options.strictNullHandling ? null : '';
|
|
3054
|
+
} else {
|
|
3055
|
+
key = options.decoder(_sliceInstanceProperty(part).call(part, 0, pos), defaults.decoder, charset, 'key');
|
|
3056
|
+
val = utils.maybeMap(parseArrayValue(_sliceInstanceProperty(part).call(part, pos + 1), options), function (encodedVal) {
|
|
3057
|
+
return options.decoder(encodedVal, defaults.decoder, charset, 'value');
|
|
3058
|
+
});
|
|
3059
|
+
}
|
|
3060
|
+
|
|
3061
|
+
if (val && options.interpretNumericEntities && charset === 'iso-8859-1') {
|
|
3062
|
+
val = interpretNumericEntities(val);
|
|
3063
|
+
}
|
|
3064
|
+
|
|
3065
|
+
if (_indexOfInstanceProperty(part).call(part, '[]=') > -1) {
|
|
3066
|
+
val = isArray(val) ? [val] : val;
|
|
3067
|
+
}
|
|
3068
|
+
|
|
3069
|
+
if (has.call(obj, key)) {
|
|
3070
|
+
obj[key] = utils.combine(obj[key], val);
|
|
3071
|
+
} else {
|
|
3072
|
+
obj[key] = val;
|
|
3073
|
+
}
|
|
3074
|
+
}
|
|
3075
|
+
|
|
3076
|
+
return obj;
|
|
3077
|
+
};
|
|
3078
|
+
|
|
3079
|
+
var parseObject = function (chain, val, options, valuesParsed) {
|
|
3080
|
+
var leaf = valuesParsed ? val : parseArrayValue(val, options);
|
|
3081
|
+
|
|
3082
|
+
for (var i = chain.length - 1; i >= 0; --i) {
|
|
3083
|
+
var obj;
|
|
3084
|
+
var root = chain[i];
|
|
3085
|
+
|
|
3086
|
+
if (root === '[]' && options.parseArrays) {
|
|
3087
|
+
var _context2;
|
|
3088
|
+
|
|
3089
|
+
obj = _concatInstanceProperty(_context2 = []).call(_context2, leaf);
|
|
3090
|
+
} else {
|
|
3091
|
+
obj = options.plainObjects ? _Object$create(null) : {};
|
|
3092
|
+
var cleanRoot = root.charAt(0) === '[' && root.charAt(root.length - 1) === ']' ? _sliceInstanceProperty(root).call(root, 1, -1) : root;
|
|
3093
|
+
|
|
3094
|
+
var index = _parseInt(cleanRoot, 10);
|
|
3095
|
+
|
|
3096
|
+
if (!options.parseArrays && cleanRoot === '') {
|
|
3097
|
+
obj = {
|
|
3098
|
+
0: leaf
|
|
3099
|
+
};
|
|
3100
|
+
} else if (!isNaN(index) && root !== cleanRoot && String(index) === cleanRoot && index >= 0 && options.parseArrays && index <= options.arrayLimit) {
|
|
3101
|
+
obj = [];
|
|
3102
|
+
obj[index] = leaf;
|
|
3103
|
+
} else if (cleanRoot !== '__proto__') {
|
|
3104
|
+
obj[cleanRoot] = leaf;
|
|
3105
|
+
}
|
|
3106
|
+
}
|
|
3107
|
+
|
|
3108
|
+
leaf = obj;
|
|
3109
|
+
}
|
|
3110
|
+
|
|
3111
|
+
return leaf;
|
|
3112
|
+
};
|
|
3113
|
+
|
|
3114
|
+
var parseKeys = function parseQueryStringKeys(givenKey, val, options, valuesParsed) {
|
|
3115
|
+
if (!givenKey) {
|
|
3116
|
+
return;
|
|
3117
|
+
} // Transform dot notation to bracket notation
|
|
3118
|
+
|
|
3119
|
+
|
|
3120
|
+
var key = options.allowDots ? givenKey.replace(/\.([^.[]+)/g, '[$1]') : givenKey; // The regex chunks
|
|
3121
|
+
|
|
3122
|
+
var brackets = /(\[[^[\]]*])/;
|
|
3123
|
+
var child = /(\[[^[\]]*])/g; // Get the parent
|
|
3124
|
+
|
|
3125
|
+
var segment = options.depth > 0 && brackets.exec(key);
|
|
3126
|
+
var parent = segment ? _sliceInstanceProperty(key).call(key, 0, segment.index) : key; // Stash the parent if it exists
|
|
3127
|
+
|
|
3128
|
+
var keys = [];
|
|
3129
|
+
|
|
3130
|
+
if (parent) {
|
|
3131
|
+
// If we aren't using plain objects, optionally prefix keys that would overwrite object prototype properties
|
|
3132
|
+
if (!options.plainObjects && has.call(Object.prototype, parent)) {
|
|
3133
|
+
if (!options.allowPrototypes) {
|
|
3134
|
+
return;
|
|
3135
|
+
}
|
|
3136
|
+
}
|
|
3137
|
+
|
|
3138
|
+
keys.push(parent);
|
|
3139
|
+
} // Loop through children appending to the array until we hit depth
|
|
3140
|
+
|
|
3141
|
+
|
|
3142
|
+
var i = 0;
|
|
3143
|
+
|
|
3144
|
+
while (options.depth > 0 && (segment = child.exec(key)) !== null && i < options.depth) {
|
|
3145
|
+
var _context3;
|
|
3146
|
+
|
|
3147
|
+
i += 1;
|
|
3148
|
+
|
|
3149
|
+
if (!options.plainObjects && has.call(Object.prototype, _sliceInstanceProperty(_context3 = segment[1]).call(_context3, 1, -1))) {
|
|
3150
|
+
if (!options.allowPrototypes) {
|
|
3151
|
+
return;
|
|
3152
|
+
}
|
|
3153
|
+
}
|
|
3154
|
+
|
|
3155
|
+
keys.push(segment[1]);
|
|
3156
|
+
} // If there's a remainder, just add whatever is left
|
|
3157
|
+
|
|
3158
|
+
|
|
3159
|
+
if (segment) {
|
|
3160
|
+
keys.push('[' + _sliceInstanceProperty(key).call(key, segment.index) + ']');
|
|
3161
|
+
}
|
|
3162
|
+
|
|
3163
|
+
return parseObject(keys, val, options, valuesParsed);
|
|
3164
|
+
};
|
|
3165
|
+
|
|
3166
|
+
var normalizeParseOptions = function normalizeParseOptions(opts) {
|
|
3167
|
+
if (!opts) {
|
|
3168
|
+
return defaults;
|
|
3169
|
+
}
|
|
3170
|
+
|
|
3171
|
+
if (opts.decoder !== null && opts.decoder !== undefined && typeof opts.decoder !== 'function') {
|
|
3172
|
+
throw new TypeError('Decoder has to be a function.');
|
|
3173
|
+
}
|
|
3174
|
+
|
|
3175
|
+
if (typeof opts.charset !== 'undefined' && opts.charset !== 'utf-8' && opts.charset !== 'iso-8859-1') {
|
|
3176
|
+
throw new TypeError('The charset option must be either utf-8, iso-8859-1, or undefined');
|
|
3177
|
+
}
|
|
3178
|
+
|
|
3179
|
+
var charset = typeof opts.charset === 'undefined' ? defaults.charset : opts.charset;
|
|
3180
|
+
return {
|
|
3181
|
+
allowDots: typeof opts.allowDots === 'undefined' ? defaults.allowDots : !!opts.allowDots,
|
|
3182
|
+
allowPrototypes: typeof opts.allowPrototypes === 'boolean' ? opts.allowPrototypes : defaults.allowPrototypes,
|
|
3183
|
+
allowSparse: typeof opts.allowSparse === 'boolean' ? opts.allowSparse : defaults.allowSparse,
|
|
3184
|
+
arrayLimit: typeof opts.arrayLimit === 'number' ? opts.arrayLimit : defaults.arrayLimit,
|
|
3185
|
+
charset: charset,
|
|
3186
|
+
charsetSentinel: typeof opts.charsetSentinel === 'boolean' ? opts.charsetSentinel : defaults.charsetSentinel,
|
|
3187
|
+
comma: typeof opts.comma === 'boolean' ? opts.comma : defaults.comma,
|
|
3188
|
+
decoder: typeof opts.decoder === 'function' ? opts.decoder : defaults.decoder,
|
|
3189
|
+
delimiter: typeof opts.delimiter === 'string' || utils.isRegExp(opts.delimiter) ? opts.delimiter : defaults.delimiter,
|
|
3190
|
+
// eslint-disable-next-line no-implicit-coercion, no-extra-parens
|
|
3191
|
+
depth: typeof opts.depth === 'number' || opts.depth === false ? +opts.depth : defaults.depth,
|
|
3192
|
+
ignoreQueryPrefix: opts.ignoreQueryPrefix === true,
|
|
3193
|
+
interpretNumericEntities: typeof opts.interpretNumericEntities === 'boolean' ? opts.interpretNumericEntities : defaults.interpretNumericEntities,
|
|
3194
|
+
parameterLimit: typeof opts.parameterLimit === 'number' ? opts.parameterLimit : defaults.parameterLimit,
|
|
3195
|
+
parseArrays: opts.parseArrays !== false,
|
|
3196
|
+
plainObjects: typeof opts.plainObjects === 'boolean' ? opts.plainObjects : defaults.plainObjects,
|
|
3197
|
+
strictNullHandling: typeof opts.strictNullHandling === 'boolean' ? opts.strictNullHandling : defaults.strictNullHandling
|
|
3198
|
+
};
|
|
3199
|
+
};
|
|
3200
|
+
|
|
3201
|
+
module.exports = function (str, opts) {
|
|
3202
|
+
var options = normalizeParseOptions(opts);
|
|
3203
|
+
|
|
3204
|
+
if (str === '' || str === null || typeof str === 'undefined') {
|
|
3205
|
+
return options.plainObjects ? _Object$create(null) : {};
|
|
3206
|
+
}
|
|
3207
|
+
|
|
3208
|
+
var tempObj = typeof str === 'string' ? parseValues(str, options) : str;
|
|
3209
|
+
var obj = options.plainObjects ? _Object$create(null) : {}; // Iterate over the keys and setup the new object
|
|
3210
|
+
|
|
3211
|
+
var keys = _Object$keys(tempObj);
|
|
3212
|
+
|
|
3213
|
+
for (var i = 0; i < keys.length; ++i) {
|
|
3214
|
+
var key = keys[i];
|
|
3215
|
+
var newObj = parseKeys(key, tempObj[key], options, typeof str === 'string');
|
|
3216
|
+
obj = utils.merge(obj, newObj, options);
|
|
3217
|
+
}
|
|
3218
|
+
|
|
3219
|
+
if (options.allowSparse === true) {
|
|
3220
|
+
return obj;
|
|
3221
|
+
}
|
|
3222
|
+
|
|
3223
|
+
return utils.compact(obj);
|
|
3224
|
+
};
|
|
3225
|
+
|
|
3226
|
+
/***/ }),
|
|
3227
|
+
|
|
3228
|
+
/***/ 4383:
|
|
3229
|
+
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
3230
|
+
|
|
3231
|
+
"use strict";
|
|
3232
|
+
|
|
3233
|
+
|
|
3234
|
+
var _Array$isArray = __webpack_require__(1511);
|
|
3235
|
+
|
|
3236
|
+
var _Object$keys = __webpack_require__(6902);
|
|
3237
|
+
|
|
3238
|
+
var _sortInstanceProperty = __webpack_require__(7302);
|
|
3239
|
+
|
|
3240
|
+
var _filterInstanceProperty = __webpack_require__(116);
|
|
3241
|
+
|
|
3242
|
+
var getSideChannel = __webpack_require__(7478);
|
|
3243
|
+
|
|
3244
|
+
var utils = __webpack_require__(4753);
|
|
3245
|
+
|
|
3246
|
+
var formats = __webpack_require__(3718);
|
|
3247
|
+
|
|
3248
|
+
var has = Object.prototype.hasOwnProperty;
|
|
3249
|
+
var arrayPrefixGenerators = {
|
|
3250
|
+
brackets: function brackets(prefix) {
|
|
3251
|
+
return prefix + '[]';
|
|
3252
|
+
},
|
|
3253
|
+
comma: 'comma',
|
|
3254
|
+
indices: function indices(prefix, key) {
|
|
3255
|
+
return prefix + '[' + key + ']';
|
|
3256
|
+
},
|
|
3257
|
+
repeat: function repeat(prefix) {
|
|
3258
|
+
return prefix;
|
|
3259
|
+
}
|
|
3260
|
+
};
|
|
3261
|
+
var isArray = _Array$isArray;
|
|
3262
|
+
var split = String.prototype.split;
|
|
3263
|
+
var push = Array.prototype.push;
|
|
3264
|
+
|
|
3265
|
+
var pushToArray = function (arr, valueOrArray) {
|
|
3266
|
+
push.apply(arr, isArray(valueOrArray) ? valueOrArray : [valueOrArray]);
|
|
3267
|
+
};
|
|
3268
|
+
|
|
3269
|
+
var toISO = Date.prototype.toISOString;
|
|
3270
|
+
var defaultFormat = formats['default'];
|
|
3271
|
+
var defaults = {
|
|
3272
|
+
addQueryPrefix: false,
|
|
3273
|
+
allowDots: false,
|
|
3274
|
+
charset: 'utf-8',
|
|
3275
|
+
charsetSentinel: false,
|
|
3276
|
+
delimiter: '&',
|
|
3277
|
+
encode: true,
|
|
3278
|
+
encoder: utils.encode,
|
|
3279
|
+
encodeValuesOnly: false,
|
|
3280
|
+
format: defaultFormat,
|
|
3281
|
+
formatter: formats.formatters[defaultFormat],
|
|
3282
|
+
// deprecated
|
|
3283
|
+
indices: false,
|
|
3284
|
+
serializeDate: function serializeDate(date) {
|
|
3285
|
+
return toISO.call(date);
|
|
3286
|
+
},
|
|
3287
|
+
skipNulls: false,
|
|
3288
|
+
strictNullHandling: false
|
|
3289
|
+
};
|
|
3290
|
+
|
|
3291
|
+
var isNonNullishPrimitive = function isNonNullishPrimitive(v) {
|
|
3292
|
+
return typeof v === 'string' || typeof v === 'number' || typeof v === 'boolean' || typeof v === 'symbol' || typeof v === 'bigint';
|
|
3293
|
+
};
|
|
3294
|
+
|
|
3295
|
+
var sentinel = {};
|
|
3296
|
+
|
|
3297
|
+
var stringify = function stringify(object, prefix, generateArrayPrefix, strictNullHandling, skipNulls, encoder, filter, sort, allowDots, serializeDate, format, formatter, encodeValuesOnly, charset, sideChannel) {
|
|
3298
|
+
var obj = object;
|
|
3299
|
+
var tmpSc = sideChannel;
|
|
3300
|
+
var step = 0;
|
|
3301
|
+
var findFlag = false;
|
|
3302
|
+
|
|
3303
|
+
while ((tmpSc = tmpSc.get(sentinel)) !== void undefined && !findFlag) {
|
|
3304
|
+
// Where object last appeared in the ref tree
|
|
3305
|
+
var pos = tmpSc.get(object);
|
|
3306
|
+
step += 1;
|
|
3307
|
+
|
|
3308
|
+
if (typeof pos !== 'undefined') {
|
|
3309
|
+
if (pos === step) {
|
|
3310
|
+
throw new RangeError('Cyclic object value');
|
|
3311
|
+
} else {
|
|
3312
|
+
findFlag = true; // Break while
|
|
3313
|
+
}
|
|
3314
|
+
}
|
|
3315
|
+
|
|
3316
|
+
if (typeof tmpSc.get(sentinel) === 'undefined') {
|
|
3317
|
+
step = 0;
|
|
3318
|
+
}
|
|
3319
|
+
}
|
|
3320
|
+
|
|
3321
|
+
if (typeof filter === 'function') {
|
|
3322
|
+
obj = filter(prefix, obj);
|
|
3323
|
+
} else if (obj instanceof Date) {
|
|
3324
|
+
obj = serializeDate(obj);
|
|
3325
|
+
} else if (generateArrayPrefix === 'comma' && isArray(obj)) {
|
|
3326
|
+
obj = utils.maybeMap(obj, function (value) {
|
|
3327
|
+
if (value instanceof Date) {
|
|
3328
|
+
return serializeDate(value);
|
|
3329
|
+
}
|
|
3330
|
+
|
|
3331
|
+
return value;
|
|
3332
|
+
});
|
|
3333
|
+
}
|
|
3334
|
+
|
|
3335
|
+
if (obj === null) {
|
|
3336
|
+
if (strictNullHandling) {
|
|
3337
|
+
return encoder && !encodeValuesOnly ? encoder(prefix, defaults.encoder, charset, 'key', format) : prefix;
|
|
3338
|
+
}
|
|
3339
|
+
|
|
3340
|
+
obj = '';
|
|
3341
|
+
}
|
|
3342
|
+
|
|
3343
|
+
if (isNonNullishPrimitive(obj) || utils.isBuffer(obj)) {
|
|
3344
|
+
if (encoder) {
|
|
3345
|
+
var keyValue = encodeValuesOnly ? prefix : encoder(prefix, defaults.encoder, charset, 'key', format);
|
|
3346
|
+
|
|
3347
|
+
if (generateArrayPrefix === 'comma' && encodeValuesOnly) {
|
|
3348
|
+
var valuesArray = split.call(String(obj), ',');
|
|
3349
|
+
var valuesJoined = '';
|
|
3350
|
+
|
|
3351
|
+
for (var i = 0; i < valuesArray.length; ++i) {
|
|
3352
|
+
valuesJoined += (i === 0 ? '' : ',') + formatter(encoder(valuesArray[i], defaults.encoder, charset, 'value', format));
|
|
3353
|
+
}
|
|
3354
|
+
|
|
3355
|
+
return [formatter(keyValue) + '=' + valuesJoined];
|
|
3356
|
+
}
|
|
3357
|
+
|
|
3358
|
+
return [formatter(keyValue) + '=' + formatter(encoder(obj, defaults.encoder, charset, 'value', format))];
|
|
3359
|
+
}
|
|
3360
|
+
|
|
3361
|
+
return [formatter(prefix) + '=' + formatter(String(obj))];
|
|
3362
|
+
}
|
|
3363
|
+
|
|
3364
|
+
var values = [];
|
|
3365
|
+
|
|
3366
|
+
if (typeof obj === 'undefined') {
|
|
3367
|
+
return values;
|
|
3368
|
+
}
|
|
3369
|
+
|
|
3370
|
+
var objKeys;
|
|
3371
|
+
|
|
3372
|
+
if (generateArrayPrefix === 'comma' && isArray(obj)) {
|
|
3373
|
+
// we need to join elements in
|
|
3374
|
+
objKeys = [{
|
|
3375
|
+
value: obj.length > 0 ? obj.join(',') || null : void undefined
|
|
3376
|
+
}];
|
|
3377
|
+
} else if (isArray(filter)) {
|
|
3378
|
+
objKeys = filter;
|
|
3379
|
+
} else {
|
|
3380
|
+
var keys = _Object$keys(obj);
|
|
3381
|
+
|
|
3382
|
+
objKeys = sort ? _sortInstanceProperty(keys).call(keys, sort) : keys;
|
|
3383
|
+
}
|
|
3384
|
+
|
|
3385
|
+
for (var j = 0; j < objKeys.length; ++j) {
|
|
3386
|
+
var key = objKeys[j];
|
|
3387
|
+
var value = typeof key === 'object' && typeof key.value !== 'undefined' ? key.value : obj[key];
|
|
3388
|
+
|
|
3389
|
+
if (skipNulls && value === null) {
|
|
3390
|
+
continue;
|
|
3391
|
+
}
|
|
3392
|
+
|
|
3393
|
+
var keyPrefix = isArray(obj) ? typeof generateArrayPrefix === 'function' ? generateArrayPrefix(prefix, key) : prefix : prefix + (allowDots ? '.' + key : '[' + key + ']');
|
|
3394
|
+
sideChannel.set(object, step);
|
|
3395
|
+
var valueSideChannel = getSideChannel();
|
|
3396
|
+
valueSideChannel.set(sentinel, sideChannel);
|
|
3397
|
+
pushToArray(values, stringify(value, keyPrefix, generateArrayPrefix, strictNullHandling, skipNulls, encoder, filter, sort, allowDots, serializeDate, format, formatter, encodeValuesOnly, charset, valueSideChannel));
|
|
3398
|
+
}
|
|
3399
|
+
|
|
3400
|
+
return values;
|
|
3401
|
+
};
|
|
3402
|
+
|
|
3403
|
+
var normalizeStringifyOptions = function normalizeStringifyOptions(opts) {
|
|
3404
|
+
if (!opts) {
|
|
3405
|
+
return defaults;
|
|
3406
|
+
}
|
|
3407
|
+
|
|
3408
|
+
if (opts.encoder !== null && typeof opts.encoder !== 'undefined' && typeof opts.encoder !== 'function') {
|
|
3409
|
+
throw new TypeError('Encoder has to be a function.');
|
|
3410
|
+
}
|
|
3411
|
+
|
|
3412
|
+
var charset = opts.charset || defaults.charset;
|
|
3413
|
+
|
|
3414
|
+
if (typeof opts.charset !== 'undefined' && opts.charset !== 'utf-8' && opts.charset !== 'iso-8859-1') {
|
|
3415
|
+
throw new TypeError('The charset option must be either utf-8, iso-8859-1, or undefined');
|
|
3416
|
+
}
|
|
3417
|
+
|
|
3418
|
+
var format = formats['default'];
|
|
3419
|
+
|
|
3420
|
+
if (typeof opts.format !== 'undefined') {
|
|
3421
|
+
if (!has.call(formats.formatters, opts.format)) {
|
|
3422
|
+
throw new TypeError('Unknown format option provided.');
|
|
3423
|
+
}
|
|
3424
|
+
|
|
3425
|
+
format = opts.format;
|
|
3426
|
+
}
|
|
3427
|
+
|
|
3428
|
+
var formatter = formats.formatters[format];
|
|
3429
|
+
|
|
3430
|
+
var filter = _filterInstanceProperty(defaults);
|
|
3431
|
+
|
|
3432
|
+
if (typeof _filterInstanceProperty(opts) === 'function' || isArray(_filterInstanceProperty(opts))) {
|
|
3433
|
+
filter = _filterInstanceProperty(opts);
|
|
3434
|
+
}
|
|
3435
|
+
|
|
3436
|
+
return {
|
|
3437
|
+
addQueryPrefix: typeof opts.addQueryPrefix === 'boolean' ? opts.addQueryPrefix : defaults.addQueryPrefix,
|
|
3438
|
+
allowDots: typeof opts.allowDots === 'undefined' ? defaults.allowDots : !!opts.allowDots,
|
|
3439
|
+
charset: charset,
|
|
3440
|
+
charsetSentinel: typeof opts.charsetSentinel === 'boolean' ? opts.charsetSentinel : defaults.charsetSentinel,
|
|
3441
|
+
delimiter: typeof opts.delimiter === 'undefined' ? defaults.delimiter : opts.delimiter,
|
|
3442
|
+
encode: typeof opts.encode === 'boolean' ? opts.encode : defaults.encode,
|
|
3443
|
+
encoder: typeof opts.encoder === 'function' ? opts.encoder : defaults.encoder,
|
|
3444
|
+
encodeValuesOnly: typeof opts.encodeValuesOnly === 'boolean' ? opts.encodeValuesOnly : defaults.encodeValuesOnly,
|
|
3445
|
+
filter: filter,
|
|
3446
|
+
format: format,
|
|
3447
|
+
formatter: formatter,
|
|
3448
|
+
serializeDate: typeof opts.serializeDate === 'function' ? opts.serializeDate : defaults.serializeDate,
|
|
3449
|
+
skipNulls: typeof opts.skipNulls === 'boolean' ? opts.skipNulls : defaults.skipNulls,
|
|
3450
|
+
sort: typeof _sortInstanceProperty(opts) === 'function' ? _sortInstanceProperty(opts) : null,
|
|
3451
|
+
strictNullHandling: typeof opts.strictNullHandling === 'boolean' ? opts.strictNullHandling : defaults.strictNullHandling
|
|
3452
|
+
};
|
|
3453
|
+
};
|
|
3454
|
+
|
|
3455
|
+
module.exports = function (object, opts) {
|
|
3456
|
+
var obj = object;
|
|
3457
|
+
var options = normalizeStringifyOptions(opts);
|
|
3458
|
+
var objKeys;
|
|
3459
|
+
var filter;
|
|
3460
|
+
|
|
3461
|
+
if (typeof _filterInstanceProperty(options) === 'function') {
|
|
3462
|
+
filter = _filterInstanceProperty(options);
|
|
3463
|
+
obj = filter('', obj);
|
|
3464
|
+
} else if (isArray(_filterInstanceProperty(options))) {
|
|
3465
|
+
filter = _filterInstanceProperty(options);
|
|
3466
|
+
objKeys = filter;
|
|
3467
|
+
}
|
|
3468
|
+
|
|
3469
|
+
var keys = [];
|
|
3470
|
+
|
|
3471
|
+
if (typeof obj !== 'object' || obj === null) {
|
|
3472
|
+
return '';
|
|
3473
|
+
}
|
|
3474
|
+
|
|
3475
|
+
var arrayFormat;
|
|
3476
|
+
|
|
3477
|
+
if (opts && opts.arrayFormat in arrayPrefixGenerators) {
|
|
3478
|
+
arrayFormat = opts.arrayFormat;
|
|
3479
|
+
} else if (opts && 'indices' in opts) {
|
|
3480
|
+
arrayFormat = opts.indices ? 'indices' : 'repeat';
|
|
3481
|
+
} else {
|
|
3482
|
+
arrayFormat = 'indices';
|
|
3483
|
+
}
|
|
3484
|
+
|
|
3485
|
+
var generateArrayPrefix = arrayPrefixGenerators[arrayFormat];
|
|
3486
|
+
|
|
3487
|
+
if (!objKeys) {
|
|
3488
|
+
objKeys = _Object$keys(obj);
|
|
3489
|
+
}
|
|
3490
|
+
|
|
3491
|
+
if (_sortInstanceProperty(options)) {
|
|
3492
|
+
_sortInstanceProperty(objKeys).call(objKeys, _sortInstanceProperty(options));
|
|
3493
|
+
}
|
|
3494
|
+
|
|
3495
|
+
var sideChannel = getSideChannel();
|
|
3496
|
+
|
|
3497
|
+
for (var i = 0; i < objKeys.length; ++i) {
|
|
3498
|
+
var key = objKeys[i];
|
|
3499
|
+
|
|
3500
|
+
if (options.skipNulls && obj[key] === null) {
|
|
3501
|
+
continue;
|
|
3502
|
+
}
|
|
3503
|
+
|
|
3504
|
+
pushToArray(keys, stringify(obj[key], key, generateArrayPrefix, options.strictNullHandling, options.skipNulls, options.encode ? options.encoder : null, _filterInstanceProperty(options), _sortInstanceProperty(options), options.allowDots, options.serializeDate, options.format, options.formatter, options.encodeValuesOnly, options.charset, sideChannel));
|
|
3505
|
+
}
|
|
3506
|
+
|
|
3507
|
+
var joined = keys.join(options.delimiter);
|
|
3508
|
+
var prefix = options.addQueryPrefix === true ? '?' : '';
|
|
3509
|
+
|
|
3510
|
+
if (options.charsetSentinel) {
|
|
3511
|
+
if (options.charset === 'iso-8859-1') {
|
|
3512
|
+
// encodeURIComponent('✓'), the "numeric entity" representation of a checkmark
|
|
3513
|
+
prefix += 'utf8=%26%2310003%3B&';
|
|
3514
|
+
} else {
|
|
3515
|
+
// encodeURIComponent('✓')
|
|
3516
|
+
prefix += 'utf8=%E2%9C%93&';
|
|
3517
|
+
}
|
|
3518
|
+
}
|
|
3519
|
+
|
|
3520
|
+
return joined.length > 0 ? prefix + joined : '';
|
|
3521
|
+
};
|
|
3522
|
+
|
|
3523
|
+
/***/ }),
|
|
3524
|
+
|
|
3525
|
+
/***/ 4753:
|
|
3526
|
+
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
3527
|
+
|
|
3528
|
+
"use strict";
|
|
3529
|
+
|
|
3530
|
+
|
|
3531
|
+
var _Array$isArray = __webpack_require__(1511);
|
|
3532
|
+
|
|
3533
|
+
var _Object$create = __webpack_require__(4943);
|
|
3534
|
+
|
|
3535
|
+
var _concatInstanceProperty = __webpack_require__(7766);
|
|
3536
|
+
|
|
3537
|
+
var _forEachInstanceProperty = __webpack_require__(8914);
|
|
3538
|
+
|
|
3539
|
+
var _reduceInstanceProperty = __webpack_require__(2366);
|
|
3540
|
+
|
|
3541
|
+
var _Object$keys = __webpack_require__(6902);
|
|
3542
|
+
|
|
3543
|
+
var _Symbol = __webpack_require__(5420);
|
|
3544
|
+
|
|
3545
|
+
var _parseInt = __webpack_require__(4198);
|
|
3546
|
+
|
|
3547
|
+
var _sliceInstanceProperty = __webpack_require__(3649);
|
|
3548
|
+
|
|
3549
|
+
var _indexOfInstanceProperty = __webpack_require__(1643);
|
|
3550
|
+
|
|
3551
|
+
var formats = __webpack_require__(3718);
|
|
3552
|
+
|
|
3553
|
+
var has = Object.prototype.hasOwnProperty;
|
|
3554
|
+
var isArray = _Array$isArray;
|
|
3555
|
+
|
|
3556
|
+
var hexTable = function () {
|
|
3557
|
+
var array = [];
|
|
3558
|
+
|
|
3559
|
+
for (var i = 0; i < 256; ++i) {
|
|
3560
|
+
array.push('%' + ((i < 16 ? '0' : '') + i.toString(16)).toUpperCase());
|
|
3561
|
+
}
|
|
3562
|
+
|
|
3563
|
+
return array;
|
|
3564
|
+
}();
|
|
3565
|
+
|
|
3566
|
+
var compactQueue = function compactQueue(queue) {
|
|
3567
|
+
while (queue.length > 1) {
|
|
3568
|
+
var item = queue.pop();
|
|
3569
|
+
var obj = item.obj[item.prop];
|
|
3570
|
+
|
|
3571
|
+
if (isArray(obj)) {
|
|
3572
|
+
var compacted = [];
|
|
3573
|
+
|
|
3574
|
+
for (var j = 0; j < obj.length; ++j) {
|
|
3575
|
+
if (typeof obj[j] !== 'undefined') {
|
|
3576
|
+
compacted.push(obj[j]);
|
|
3577
|
+
}
|
|
3578
|
+
}
|
|
3579
|
+
|
|
3580
|
+
item.obj[item.prop] = compacted;
|
|
3581
|
+
}
|
|
3582
|
+
}
|
|
3583
|
+
};
|
|
3584
|
+
|
|
3585
|
+
var arrayToObject = function arrayToObject(source, options) {
|
|
3586
|
+
var obj = options && options.plainObjects ? _Object$create(null) : {};
|
|
3587
|
+
|
|
3588
|
+
for (var i = 0; i < source.length; ++i) {
|
|
3589
|
+
if (typeof source[i] !== 'undefined') {
|
|
3590
|
+
obj[i] = source[i];
|
|
3591
|
+
}
|
|
3592
|
+
}
|
|
3593
|
+
|
|
3594
|
+
return obj;
|
|
3595
|
+
};
|
|
3596
|
+
|
|
3597
|
+
var merge = function merge(target, source, options) {
|
|
3598
|
+
var _context2;
|
|
3599
|
+
|
|
3600
|
+
/* eslint no-param-reassign: 0 */
|
|
3601
|
+
if (!source) {
|
|
3602
|
+
return target;
|
|
3603
|
+
}
|
|
3604
|
+
|
|
3605
|
+
if (typeof source !== 'object') {
|
|
3606
|
+
if (isArray(target)) {
|
|
3607
|
+
target.push(source);
|
|
3608
|
+
} else if (target && typeof target === 'object') {
|
|
3609
|
+
if (options && (options.plainObjects || options.allowPrototypes) || !has.call(Object.prototype, source)) {
|
|
3610
|
+
target[source] = true;
|
|
3611
|
+
}
|
|
3612
|
+
} else {
|
|
3613
|
+
return [target, source];
|
|
3614
|
+
}
|
|
3615
|
+
|
|
3616
|
+
return target;
|
|
3617
|
+
}
|
|
3618
|
+
|
|
3619
|
+
if (!target || typeof target !== 'object') {
|
|
3620
|
+
var _context;
|
|
3621
|
+
|
|
3622
|
+
return _concatInstanceProperty(_context = [target]).call(_context, source);
|
|
3623
|
+
}
|
|
3624
|
+
|
|
3625
|
+
var mergeTarget = target;
|
|
3626
|
+
|
|
3627
|
+
if (isArray(target) && !isArray(source)) {
|
|
3628
|
+
mergeTarget = arrayToObject(target, options);
|
|
3629
|
+
}
|
|
3630
|
+
|
|
3631
|
+
if (isArray(target) && isArray(source)) {
|
|
3632
|
+
_forEachInstanceProperty(source).call(source, function (item, i) {
|
|
3633
|
+
if (has.call(target, i)) {
|
|
3634
|
+
var targetItem = target[i];
|
|
3635
|
+
|
|
3636
|
+
if (targetItem && typeof targetItem === 'object' && item && typeof item === 'object') {
|
|
3637
|
+
target[i] = merge(targetItem, item, options);
|
|
3638
|
+
} else {
|
|
3639
|
+
target.push(item);
|
|
3640
|
+
}
|
|
3641
|
+
} else {
|
|
3642
|
+
target[i] = item;
|
|
3643
|
+
}
|
|
3644
|
+
});
|
|
3645
|
+
|
|
3646
|
+
return target;
|
|
3647
|
+
}
|
|
3648
|
+
|
|
3649
|
+
return _reduceInstanceProperty(_context2 = _Object$keys(source)).call(_context2, function (acc, key) {
|
|
3650
|
+
var value = source[key];
|
|
3651
|
+
|
|
3652
|
+
if (has.call(acc, key)) {
|
|
3653
|
+
acc[key] = merge(acc[key], value, options);
|
|
3654
|
+
} else {
|
|
3655
|
+
acc[key] = value;
|
|
3656
|
+
}
|
|
3657
|
+
|
|
3658
|
+
return acc;
|
|
3659
|
+
}, mergeTarget);
|
|
3660
|
+
};
|
|
3661
|
+
|
|
3662
|
+
var assign = function assignSingleSource(target, source) {
|
|
3663
|
+
var _context3;
|
|
3664
|
+
|
|
3665
|
+
return _reduceInstanceProperty(_context3 = _Object$keys(source)).call(_context3, function (acc, key) {
|
|
3666
|
+
acc[key] = source[key];
|
|
3667
|
+
return acc;
|
|
3668
|
+
}, target);
|
|
3669
|
+
};
|
|
3670
|
+
|
|
3671
|
+
var decode = function (str, decoder, charset) {
|
|
3672
|
+
var strWithoutPlus = str.replace(/\+/g, ' ');
|
|
3673
|
+
|
|
3674
|
+
if (charset === 'iso-8859-1') {
|
|
3675
|
+
// unescape never throws, no try...catch needed:
|
|
3676
|
+
return strWithoutPlus.replace(/%[0-9a-f]{2}/gi, unescape);
|
|
3677
|
+
} // utf-8
|
|
3678
|
+
|
|
3679
|
+
|
|
3680
|
+
try {
|
|
3681
|
+
return decodeURIComponent(strWithoutPlus);
|
|
3682
|
+
} catch (e) {
|
|
3683
|
+
return strWithoutPlus;
|
|
3684
|
+
}
|
|
3685
|
+
};
|
|
3686
|
+
|
|
3687
|
+
var encode = function encode(str, defaultEncoder, charset, kind, format) {
|
|
3688
|
+
// This code was originally written by Brian White (mscdex) for the io.js core querystring library.
|
|
3689
|
+
// It has been adapted here for stricter adherence to RFC 3986
|
|
3690
|
+
if (str.length === 0) {
|
|
3691
|
+
return str;
|
|
3692
|
+
}
|
|
3693
|
+
|
|
3694
|
+
var string = str;
|
|
3695
|
+
|
|
3696
|
+
if (typeof str === 'symbol') {
|
|
3697
|
+
string = _Symbol.prototype.toString.call(str);
|
|
3698
|
+
} else if (typeof str !== 'string') {
|
|
3699
|
+
string = String(str);
|
|
3700
|
+
}
|
|
3701
|
+
|
|
3702
|
+
if (charset === 'iso-8859-1') {
|
|
3703
|
+
return escape(string).replace(/%u[0-9a-f]{4}/gi, function ($0) {
|
|
3704
|
+
return '%26%23' + _parseInt(_sliceInstanceProperty($0).call($0, 2), 16) + '%3B';
|
|
3705
|
+
});
|
|
3706
|
+
}
|
|
3707
|
+
|
|
3708
|
+
var out = '';
|
|
3709
|
+
|
|
3710
|
+
for (var i = 0; i < string.length; ++i) {
|
|
3711
|
+
var c = string.charCodeAt(i);
|
|
3712
|
+
|
|
3713
|
+
if (c === 0x2D // -
|
|
3714
|
+
|| c === 0x2E // .
|
|
3715
|
+
|| c === 0x5F // _
|
|
3716
|
+
|| c === 0x7E // ~
|
|
3717
|
+
|| c >= 0x30 && c <= 0x39 // 0-9
|
|
3718
|
+
|| c >= 0x41 && c <= 0x5A // a-z
|
|
3719
|
+
|| c >= 0x61 && c <= 0x7A // A-Z
|
|
3720
|
+
|| format === formats.RFC1738 && (c === 0x28 || c === 0x29) // ( )
|
|
3721
|
+
) {
|
|
3722
|
+
out += string.charAt(i);
|
|
3723
|
+
continue;
|
|
3724
|
+
}
|
|
3725
|
+
|
|
3726
|
+
if (c < 0x80) {
|
|
3727
|
+
out = out + hexTable[c];
|
|
3728
|
+
continue;
|
|
3729
|
+
}
|
|
3730
|
+
|
|
3731
|
+
if (c < 0x800) {
|
|
3732
|
+
out = out + (hexTable[0xC0 | c >> 6] + hexTable[0x80 | c & 0x3F]);
|
|
3733
|
+
continue;
|
|
3734
|
+
}
|
|
3735
|
+
|
|
3736
|
+
if (c < 0xD800 || c >= 0xE000) {
|
|
3737
|
+
out = out + (hexTable[0xE0 | c >> 12] + hexTable[0x80 | c >> 6 & 0x3F] + hexTable[0x80 | c & 0x3F]);
|
|
3738
|
+
continue;
|
|
3739
|
+
}
|
|
3740
|
+
|
|
3741
|
+
i += 1;
|
|
3742
|
+
c = 0x10000 + ((c & 0x3FF) << 10 | string.charCodeAt(i) & 0x3FF);
|
|
3743
|
+
/* eslint operator-linebreak: [2, "before"] */
|
|
3744
|
+
|
|
3745
|
+
out += hexTable[0xF0 | c >> 18] + hexTable[0x80 | c >> 12 & 0x3F] + hexTable[0x80 | c >> 6 & 0x3F] + hexTable[0x80 | c & 0x3F];
|
|
3746
|
+
}
|
|
3747
|
+
|
|
3748
|
+
return out;
|
|
3749
|
+
};
|
|
3750
|
+
|
|
3751
|
+
var compact = function compact(value) {
|
|
3752
|
+
var queue = [{
|
|
3753
|
+
obj: {
|
|
3754
|
+
o: value
|
|
3755
|
+
},
|
|
3756
|
+
prop: 'o'
|
|
3757
|
+
}];
|
|
3758
|
+
var refs = [];
|
|
3759
|
+
|
|
3760
|
+
for (var i = 0; i < queue.length; ++i) {
|
|
3761
|
+
var item = queue[i];
|
|
3762
|
+
var obj = item.obj[item.prop];
|
|
3763
|
+
|
|
3764
|
+
var keys = _Object$keys(obj);
|
|
3765
|
+
|
|
3766
|
+
for (var j = 0; j < keys.length; ++j) {
|
|
3767
|
+
var key = keys[j];
|
|
3768
|
+
var val = obj[key];
|
|
3769
|
+
|
|
3770
|
+
if (typeof val === 'object' && val !== null && _indexOfInstanceProperty(refs).call(refs, val) === -1) {
|
|
3771
|
+
queue.push({
|
|
3772
|
+
obj: obj,
|
|
3773
|
+
prop: key
|
|
3774
|
+
});
|
|
3775
|
+
refs.push(val);
|
|
3776
|
+
}
|
|
3777
|
+
}
|
|
3778
|
+
}
|
|
3779
|
+
|
|
3780
|
+
compactQueue(queue);
|
|
3781
|
+
return value;
|
|
3782
|
+
};
|
|
3783
|
+
|
|
3784
|
+
var isRegExp = function isRegExp(obj) {
|
|
3785
|
+
return Object.prototype.toString.call(obj) === '[object RegExp]';
|
|
3786
|
+
};
|
|
3787
|
+
|
|
3788
|
+
var isBuffer = function isBuffer(obj) {
|
|
3789
|
+
if (!obj || typeof obj !== 'object') {
|
|
3790
|
+
return false;
|
|
3791
|
+
}
|
|
3792
|
+
|
|
3793
|
+
return !!(obj.constructor && obj.constructor.isBuffer && obj.constructor.isBuffer(obj));
|
|
3794
|
+
};
|
|
3795
|
+
|
|
3796
|
+
var combine = function combine(a, b) {
|
|
3797
|
+
var _context4;
|
|
3798
|
+
|
|
3799
|
+
return _concatInstanceProperty(_context4 = []).call(_context4, a, b);
|
|
3800
|
+
};
|
|
3801
|
+
|
|
3802
|
+
var maybeMap = function maybeMap(val, fn) {
|
|
3803
|
+
if (isArray(val)) {
|
|
3804
|
+
var mapped = [];
|
|
3805
|
+
|
|
3806
|
+
for (var i = 0; i < val.length; i += 1) {
|
|
3807
|
+
mapped.push(fn(val[i]));
|
|
3808
|
+
}
|
|
3809
|
+
|
|
3810
|
+
return mapped;
|
|
3811
|
+
}
|
|
3812
|
+
|
|
3813
|
+
return fn(val);
|
|
3814
|
+
};
|
|
3815
|
+
|
|
3816
|
+
module.exports = {
|
|
3817
|
+
arrayToObject: arrayToObject,
|
|
3818
|
+
assign: assign,
|
|
3819
|
+
combine: combine,
|
|
3820
|
+
compact: compact,
|
|
3821
|
+
decode: decode,
|
|
3822
|
+
encode: encode,
|
|
3823
|
+
isBuffer: isBuffer,
|
|
3824
|
+
isRegExp: isRegExp,
|
|
3825
|
+
maybeMap: maybeMap,
|
|
3826
|
+
merge: merge
|
|
3827
|
+
};
|
|
2738
3828
|
|
|
2739
3829
|
/***/ }),
|
|
2740
3830
|
|
|
@@ -3514,6 +4604,17 @@ module.exports = function stringify(it, replacer, space) {
|
|
|
3514
4604
|
};
|
|
3515
4605
|
|
|
3516
4606
|
|
|
4607
|
+
/***/ }),
|
|
4608
|
+
|
|
4609
|
+
/***/ 9179:
|
|
4610
|
+
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
4611
|
+
|
|
4612
|
+
__webpack_require__(8103);
|
|
4613
|
+
var path = __webpack_require__(4058);
|
|
4614
|
+
|
|
4615
|
+
module.exports = path.Math.trunc;
|
|
4616
|
+
|
|
4617
|
+
|
|
3517
4618
|
/***/ }),
|
|
3518
4619
|
|
|
3519
4620
|
/***/ 5999:
|
|
@@ -3525,6 +4626,21 @@ var path = __webpack_require__(4058);
|
|
|
3525
4626
|
module.exports = path.Object.assign;
|
|
3526
4627
|
|
|
3527
4628
|
|
|
4629
|
+
/***/ }),
|
|
4630
|
+
|
|
4631
|
+
/***/ 5254:
|
|
4632
|
+
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
4633
|
+
|
|
4634
|
+
__webpack_require__(3882);
|
|
4635
|
+
var path = __webpack_require__(4058);
|
|
4636
|
+
|
|
4637
|
+
var Object = path.Object;
|
|
4638
|
+
|
|
4639
|
+
module.exports = function create(P, D) {
|
|
4640
|
+
return Object.create(P, D);
|
|
4641
|
+
};
|
|
4642
|
+
|
|
4643
|
+
|
|
3528
4644
|
/***/ }),
|
|
3529
4645
|
|
|
3530
4646
|
/***/ 7702:
|
|
@@ -3790,19 +4906,6 @@ var getIteratorMethod = __webpack_require__(2902);
|
|
|
3790
4906
|
module.exports = getIteratorMethod;
|
|
3791
4907
|
|
|
3792
4908
|
|
|
3793
|
-
/***/ }),
|
|
3794
|
-
|
|
3795
|
-
/***/ 1258:
|
|
3796
|
-
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
3797
|
-
|
|
3798
|
-
__webpack_require__(6274);
|
|
3799
|
-
__webpack_require__(7971);
|
|
3800
|
-
__webpack_require__(7634);
|
|
3801
|
-
var getIterator = __webpack_require__(429);
|
|
3802
|
-
|
|
3803
|
-
module.exports = getIterator;
|
|
3804
|
-
|
|
3805
|
-
|
|
3806
4909
|
/***/ }),
|
|
3807
4910
|
|
|
3808
4911
|
/***/ 9447:
|
|
@@ -3813,19 +4916,6 @@ var parent = __webpack_require__(4570);
|
|
|
3813
4916
|
module.exports = parent;
|
|
3814
4917
|
|
|
3815
4918
|
|
|
3816
|
-
/***/ }),
|
|
3817
|
-
|
|
3818
|
-
/***/ 4408:
|
|
3819
|
-
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
3820
|
-
|
|
3821
|
-
__webpack_require__(6274);
|
|
3822
|
-
__webpack_require__(7971);
|
|
3823
|
-
__webpack_require__(7634);
|
|
3824
|
-
var isIterable = __webpack_require__(663);
|
|
3825
|
-
|
|
3826
|
-
module.exports = isIterable;
|
|
3827
|
-
|
|
3828
|
-
|
|
3829
4919
|
/***/ }),
|
|
3830
4920
|
|
|
3831
4921
|
/***/ 269:
|
|
@@ -5437,22 +6527,6 @@ module.exports = function (it) {
|
|
|
5437
6527
|
};
|
|
5438
6528
|
|
|
5439
6529
|
|
|
5440
|
-
/***/ }),
|
|
5441
|
-
|
|
5442
|
-
/***/ 429:
|
|
5443
|
-
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
5444
|
-
|
|
5445
|
-
var anObject = __webpack_require__(6059);
|
|
5446
|
-
var getIteratorMethod = __webpack_require__(2902);
|
|
5447
|
-
|
|
5448
|
-
module.exports = function (it) {
|
|
5449
|
-
var iteratorMethod = getIteratorMethod(it);
|
|
5450
|
-
if (typeof iteratorMethod != 'function') {
|
|
5451
|
-
throw TypeError(String(it) + ' is not iterable');
|
|
5452
|
-
} return anObject(iteratorMethod.call(it));
|
|
5453
|
-
};
|
|
5454
|
-
|
|
5455
|
-
|
|
5456
6530
|
/***/ }),
|
|
5457
6531
|
|
|
5458
6532
|
/***/ 1899:
|
|
@@ -5811,26 +6885,6 @@ var POLYFILL = isForced.POLYFILL = 'P';
|
|
|
5811
6885
|
module.exports = isForced;
|
|
5812
6886
|
|
|
5813
6887
|
|
|
5814
|
-
/***/ }),
|
|
5815
|
-
|
|
5816
|
-
/***/ 663:
|
|
5817
|
-
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
5818
|
-
|
|
5819
|
-
var classof = __webpack_require__(9697);
|
|
5820
|
-
var wellKnownSymbol = __webpack_require__(9813);
|
|
5821
|
-
var Iterators = __webpack_require__(2077);
|
|
5822
|
-
|
|
5823
|
-
var ITERATOR = wellKnownSymbol('iterator');
|
|
5824
|
-
|
|
5825
|
-
module.exports = function (it) {
|
|
5826
|
-
var O = Object(it);
|
|
5827
|
-
return O[ITERATOR] !== undefined
|
|
5828
|
-
|| '@@iterator' in O
|
|
5829
|
-
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
5830
|
-
|| Iterators.hasOwnProperty(classof(O));
|
|
5831
|
-
};
|
|
5832
|
-
|
|
5833
|
-
|
|
5834
6888
|
/***/ }),
|
|
5835
6889
|
|
|
5836
6890
|
/***/ 941:
|
|
@@ -8194,6 +9248,25 @@ setToStringTag(global.JSON, 'JSON', true);
|
|
|
8194
9248
|
// empty
|
|
8195
9249
|
|
|
8196
9250
|
|
|
9251
|
+
/***/ }),
|
|
9252
|
+
|
|
9253
|
+
/***/ 8103:
|
|
9254
|
+
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
9255
|
+
|
|
9256
|
+
var $ = __webpack_require__(6887);
|
|
9257
|
+
|
|
9258
|
+
var ceil = Math.ceil;
|
|
9259
|
+
var floor = Math.floor;
|
|
9260
|
+
|
|
9261
|
+
// `Math.trunc` method
|
|
9262
|
+
// https://tc39.es/ecma262/#sec-math.trunc
|
|
9263
|
+
$({ target: 'Math', stat: true }, {
|
|
9264
|
+
trunc: function trunc(it) {
|
|
9265
|
+
return (it > 0 ? floor : ceil)(it);
|
|
9266
|
+
}
|
|
9267
|
+
});
|
|
9268
|
+
|
|
9269
|
+
|
|
8197
9270
|
/***/ }),
|
|
8198
9271
|
|
|
8199
9272
|
/***/ 9221:
|
|
@@ -8210,6 +9283,22 @@ $({ target: 'Object', stat: true, forced: Object.assign !== assign }, {
|
|
|
8210
9283
|
});
|
|
8211
9284
|
|
|
8212
9285
|
|
|
9286
|
+
/***/ }),
|
|
9287
|
+
|
|
9288
|
+
/***/ 3882:
|
|
9289
|
+
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
9290
|
+
|
|
9291
|
+
var $ = __webpack_require__(6887);
|
|
9292
|
+
var DESCRIPTORS = __webpack_require__(5746);
|
|
9293
|
+
var create = __webpack_require__(9290);
|
|
9294
|
+
|
|
9295
|
+
// `Object.create` method
|
|
9296
|
+
// https://tc39.es/ecma262/#sec-object.create
|
|
9297
|
+
$({ target: 'Object', stat: true, sham: !DESCRIPTORS }, {
|
|
9298
|
+
create: create
|
|
9299
|
+
});
|
|
9300
|
+
|
|
9301
|
+
|
|
8213
9302
|
/***/ }),
|
|
8214
9303
|
|
|
8215
9304
|
/***/ 4979:
|
|
@@ -9871,6 +10960,16 @@ var parent = __webpack_require__(4426);
|
|
|
9871
10960
|
module.exports = parent;
|
|
9872
10961
|
|
|
9873
10962
|
|
|
10963
|
+
/***/ }),
|
|
10964
|
+
|
|
10965
|
+
/***/ 5838:
|
|
10966
|
+
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
10967
|
+
|
|
10968
|
+
var parent = __webpack_require__(9179);
|
|
10969
|
+
|
|
10970
|
+
module.exports = parent;
|
|
10971
|
+
|
|
10972
|
+
|
|
9874
10973
|
/***/ }),
|
|
9875
10974
|
|
|
9876
10975
|
/***/ 3383:
|
|
@@ -9881,6 +10980,16 @@ var parent = __webpack_require__(5999);
|
|
|
9881
10980
|
module.exports = parent;
|
|
9882
10981
|
|
|
9883
10982
|
|
|
10983
|
+
/***/ }),
|
|
10984
|
+
|
|
10985
|
+
/***/ 4471:
|
|
10986
|
+
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
10987
|
+
|
|
10988
|
+
var parent = __webpack_require__(5254);
|
|
10989
|
+
|
|
10990
|
+
module.exports = parent;
|
|
10991
|
+
|
|
10992
|
+
|
|
9884
10993
|
/***/ }),
|
|
9885
10994
|
|
|
9886
10995
|
/***/ 7396:
|
|
@@ -10143,59 +11252,101 @@ stringify.default = stringify
|
|
|
10143
11252
|
stringify.stable = deterministicStringify
|
|
10144
11253
|
stringify.stableStringify = deterministicStringify
|
|
10145
11254
|
|
|
11255
|
+
var LIMIT_REPLACE_NODE = '[...]'
|
|
11256
|
+
var CIRCULAR_REPLACE_NODE = '[Circular]'
|
|
11257
|
+
|
|
10146
11258
|
var arr = []
|
|
10147
11259
|
var replacerStack = []
|
|
10148
11260
|
|
|
11261
|
+
function defaultOptions () {
|
|
11262
|
+
return {
|
|
11263
|
+
depthLimit: Number.MAX_SAFE_INTEGER,
|
|
11264
|
+
edgesLimit: Number.MAX_SAFE_INTEGER
|
|
11265
|
+
}
|
|
11266
|
+
}
|
|
11267
|
+
|
|
10149
11268
|
// Regular stringify
|
|
10150
|
-
function stringify (obj, replacer, spacer) {
|
|
10151
|
-
|
|
10152
|
-
|
|
10153
|
-
if (replacerStack.length === 0) {
|
|
10154
|
-
res = JSON.stringify(obj, replacer, spacer)
|
|
10155
|
-
} else {
|
|
10156
|
-
res = JSON.stringify(obj, replaceGetterValues(replacer), spacer)
|
|
11269
|
+
function stringify (obj, replacer, spacer, options) {
|
|
11270
|
+
if (typeof options === 'undefined') {
|
|
11271
|
+
options = defaultOptions()
|
|
10157
11272
|
}
|
|
10158
|
-
|
|
10159
|
-
|
|
10160
|
-
|
|
10161
|
-
|
|
11273
|
+
|
|
11274
|
+
decirc(obj, '', 0, [], undefined, 0, options)
|
|
11275
|
+
var res
|
|
11276
|
+
try {
|
|
11277
|
+
if (replacerStack.length === 0) {
|
|
11278
|
+
res = JSON.stringify(obj, replacer, spacer)
|
|
10162
11279
|
} else {
|
|
10163
|
-
|
|
11280
|
+
res = JSON.stringify(obj, replaceGetterValues(replacer), spacer)
|
|
11281
|
+
}
|
|
11282
|
+
} catch (_) {
|
|
11283
|
+
return JSON.stringify('[unable to serialize, circular reference is too complex to analyze]')
|
|
11284
|
+
} finally {
|
|
11285
|
+
while (arr.length !== 0) {
|
|
11286
|
+
var part = arr.pop()
|
|
11287
|
+
if (part.length === 4) {
|
|
11288
|
+
Object.defineProperty(part[0], part[1], part[3])
|
|
11289
|
+
} else {
|
|
11290
|
+
part[0][part[1]] = part[2]
|
|
11291
|
+
}
|
|
10164
11292
|
}
|
|
10165
11293
|
}
|
|
10166
11294
|
return res
|
|
10167
11295
|
}
|
|
10168
|
-
|
|
11296
|
+
|
|
11297
|
+
function setReplace (replace, val, k, parent) {
|
|
11298
|
+
var propertyDescriptor = Object.getOwnPropertyDescriptor(parent, k)
|
|
11299
|
+
if (propertyDescriptor.get !== undefined) {
|
|
11300
|
+
if (propertyDescriptor.configurable) {
|
|
11301
|
+
Object.defineProperty(parent, k, { value: replace })
|
|
11302
|
+
arr.push([parent, k, val, propertyDescriptor])
|
|
11303
|
+
} else {
|
|
11304
|
+
replacerStack.push([val, k, replace])
|
|
11305
|
+
}
|
|
11306
|
+
} else {
|
|
11307
|
+
parent[k] = replace
|
|
11308
|
+
arr.push([parent, k, val])
|
|
11309
|
+
}
|
|
11310
|
+
}
|
|
11311
|
+
|
|
11312
|
+
function decirc (val, k, edgeIndex, stack, parent, depth, options) {
|
|
11313
|
+
depth += 1
|
|
10169
11314
|
var i
|
|
10170
11315
|
if (typeof val === 'object' && val !== null) {
|
|
10171
11316
|
for (i = 0; i < stack.length; i++) {
|
|
10172
11317
|
if (stack[i] === val) {
|
|
10173
|
-
|
|
10174
|
-
if (propertyDescriptor.get !== undefined) {
|
|
10175
|
-
if (propertyDescriptor.configurable) {
|
|
10176
|
-
Object.defineProperty(parent, k, { value: '[Circular]' })
|
|
10177
|
-
arr.push([parent, k, val, propertyDescriptor])
|
|
10178
|
-
} else {
|
|
10179
|
-
replacerStack.push([val, k])
|
|
10180
|
-
}
|
|
10181
|
-
} else {
|
|
10182
|
-
parent[k] = '[Circular]'
|
|
10183
|
-
arr.push([parent, k, val])
|
|
10184
|
-
}
|
|
11318
|
+
setReplace(CIRCULAR_REPLACE_NODE, val, k, parent)
|
|
10185
11319
|
return
|
|
10186
11320
|
}
|
|
10187
11321
|
}
|
|
11322
|
+
|
|
11323
|
+
if (
|
|
11324
|
+
typeof options.depthLimit !== 'undefined' &&
|
|
11325
|
+
depth > options.depthLimit
|
|
11326
|
+
) {
|
|
11327
|
+
setReplace(LIMIT_REPLACE_NODE, val, k, parent)
|
|
11328
|
+
return
|
|
11329
|
+
}
|
|
11330
|
+
|
|
11331
|
+
if (
|
|
11332
|
+
typeof options.edgesLimit !== 'undefined' &&
|
|
11333
|
+
edgeIndex + 1 > options.edgesLimit
|
|
11334
|
+
) {
|
|
11335
|
+
setReplace(LIMIT_REPLACE_NODE, val, k, parent)
|
|
11336
|
+
return
|
|
11337
|
+
}
|
|
11338
|
+
|
|
10188
11339
|
stack.push(val)
|
|
10189
11340
|
// Optimize for Arrays. Big arrays could kill the performance otherwise!
|
|
10190
11341
|
if (Array.isArray(val)) {
|
|
10191
11342
|
for (i = 0; i < val.length; i++) {
|
|
10192
|
-
decirc(val[i], i, stack, val)
|
|
11343
|
+
decirc(val[i], i, i, stack, val, depth, options)
|
|
10193
11344
|
}
|
|
10194
11345
|
} else {
|
|
10195
11346
|
var keys = Object.keys(val)
|
|
10196
11347
|
for (i = 0; i < keys.length; i++) {
|
|
10197
11348
|
var key = keys[i]
|
|
10198
|
-
decirc(val[key], key, stack, val)
|
|
11349
|
+
decirc(val[key], key, i, stack, val, depth, options)
|
|
10199
11350
|
}
|
|
10200
11351
|
}
|
|
10201
11352
|
stack.pop()
|
|
@@ -10213,53 +11364,74 @@ function compareFunction (a, b) {
|
|
|
10213
11364
|
return 0
|
|
10214
11365
|
}
|
|
10215
11366
|
|
|
10216
|
-
function deterministicStringify (obj, replacer, spacer) {
|
|
10217
|
-
|
|
10218
|
-
|
|
10219
|
-
if (replacerStack.length === 0) {
|
|
10220
|
-
res = JSON.stringify(tmp, replacer, spacer)
|
|
10221
|
-
} else {
|
|
10222
|
-
res = JSON.stringify(tmp, replaceGetterValues(replacer), spacer)
|
|
11367
|
+
function deterministicStringify (obj, replacer, spacer, options) {
|
|
11368
|
+
if (typeof options === 'undefined') {
|
|
11369
|
+
options = defaultOptions()
|
|
10223
11370
|
}
|
|
10224
|
-
|
|
10225
|
-
|
|
10226
|
-
|
|
10227
|
-
|
|
11371
|
+
|
|
11372
|
+
var tmp = deterministicDecirc(obj, '', 0, [], undefined, 0, options) || obj
|
|
11373
|
+
var res
|
|
11374
|
+
try {
|
|
11375
|
+
if (replacerStack.length === 0) {
|
|
11376
|
+
res = JSON.stringify(tmp, replacer, spacer)
|
|
10228
11377
|
} else {
|
|
10229
|
-
|
|
11378
|
+
res = JSON.stringify(tmp, replaceGetterValues(replacer), spacer)
|
|
11379
|
+
}
|
|
11380
|
+
} catch (_) {
|
|
11381
|
+
return JSON.stringify('[unable to serialize, circular reference is too complex to analyze]')
|
|
11382
|
+
} finally {
|
|
11383
|
+
// Ensure that we restore the object as it was.
|
|
11384
|
+
while (arr.length !== 0) {
|
|
11385
|
+
var part = arr.pop()
|
|
11386
|
+
if (part.length === 4) {
|
|
11387
|
+
Object.defineProperty(part[0], part[1], part[3])
|
|
11388
|
+
} else {
|
|
11389
|
+
part[0][part[1]] = part[2]
|
|
11390
|
+
}
|
|
10230
11391
|
}
|
|
10231
11392
|
}
|
|
10232
11393
|
return res
|
|
10233
11394
|
}
|
|
10234
11395
|
|
|
10235
|
-
function deterministicDecirc (val, k, stack, parent) {
|
|
11396
|
+
function deterministicDecirc (val, k, edgeIndex, stack, parent, depth, options) {
|
|
11397
|
+
depth += 1
|
|
10236
11398
|
var i
|
|
10237
11399
|
if (typeof val === 'object' && val !== null) {
|
|
10238
11400
|
for (i = 0; i < stack.length; i++) {
|
|
10239
11401
|
if (stack[i] === val) {
|
|
10240
|
-
|
|
10241
|
-
|
|
10242
|
-
|
|
10243
|
-
|
|
10244
|
-
|
|
10245
|
-
|
|
10246
|
-
replacerStack.push([val, k])
|
|
10247
|
-
}
|
|
10248
|
-
} else {
|
|
10249
|
-
parent[k] = '[Circular]'
|
|
10250
|
-
arr.push([parent, k, val])
|
|
10251
|
-
}
|
|
11402
|
+
setReplace(CIRCULAR_REPLACE_NODE, val, k, parent)
|
|
11403
|
+
return
|
|
11404
|
+
}
|
|
11405
|
+
}
|
|
11406
|
+
try {
|
|
11407
|
+
if (typeof val.toJSON === 'function') {
|
|
10252
11408
|
return
|
|
10253
11409
|
}
|
|
11410
|
+
} catch (_) {
|
|
11411
|
+
return
|
|
10254
11412
|
}
|
|
10255
|
-
|
|
11413
|
+
|
|
11414
|
+
if (
|
|
11415
|
+
typeof options.depthLimit !== 'undefined' &&
|
|
11416
|
+
depth > options.depthLimit
|
|
11417
|
+
) {
|
|
11418
|
+
setReplace(LIMIT_REPLACE_NODE, val, k, parent)
|
|
10256
11419
|
return
|
|
10257
11420
|
}
|
|
11421
|
+
|
|
11422
|
+
if (
|
|
11423
|
+
typeof options.edgesLimit !== 'undefined' &&
|
|
11424
|
+
edgeIndex + 1 > options.edgesLimit
|
|
11425
|
+
) {
|
|
11426
|
+
setReplace(LIMIT_REPLACE_NODE, val, k, parent)
|
|
11427
|
+
return
|
|
11428
|
+
}
|
|
11429
|
+
|
|
10258
11430
|
stack.push(val)
|
|
10259
11431
|
// Optimize for Arrays. Big arrays could kill the performance otherwise!
|
|
10260
11432
|
if (Array.isArray(val)) {
|
|
10261
11433
|
for (i = 0; i < val.length; i++) {
|
|
10262
|
-
deterministicDecirc(val[i], i, stack, val)
|
|
11434
|
+
deterministicDecirc(val[i], i, i, stack, val, depth, options)
|
|
10263
11435
|
}
|
|
10264
11436
|
} else {
|
|
10265
11437
|
// Create a temporary object in the required way
|
|
@@ -10267,10 +11439,10 @@ function deterministicDecirc (val, k, stack, parent) {
|
|
|
10267
11439
|
var keys = Object.keys(val).sort(compareFunction)
|
|
10268
11440
|
for (i = 0; i < keys.length; i++) {
|
|
10269
11441
|
var key = keys[i]
|
|
10270
|
-
deterministicDecirc(val[key], key, stack, val)
|
|
11442
|
+
deterministicDecirc(val[key], key, i, stack, val, depth, options)
|
|
10271
11443
|
tmp[key] = val[key]
|
|
10272
11444
|
}
|
|
10273
|
-
if (parent !== undefined) {
|
|
11445
|
+
if (typeof parent !== 'undefined') {
|
|
10274
11446
|
arr.push([parent, k, val])
|
|
10275
11447
|
parent[k] = tmp
|
|
10276
11448
|
} else {
|
|
@@ -10282,15 +11454,20 @@ function deterministicDecirc (val, k, stack, parent) {
|
|
|
10282
11454
|
}
|
|
10283
11455
|
|
|
10284
11456
|
// wraps replacer function to handle values we couldn't replace
|
|
10285
|
-
// and mark them as
|
|
11457
|
+
// and mark them as replaced value
|
|
10286
11458
|
function replaceGetterValues (replacer) {
|
|
10287
|
-
replacer =
|
|
11459
|
+
replacer =
|
|
11460
|
+
typeof replacer !== 'undefined'
|
|
11461
|
+
? replacer
|
|
11462
|
+
: function (k, v) {
|
|
11463
|
+
return v
|
|
11464
|
+
}
|
|
10288
11465
|
return function (key, val) {
|
|
10289
11466
|
if (replacerStack.length > 0) {
|
|
10290
11467
|
for (var i = 0; i < replacerStack.length; i++) {
|
|
10291
11468
|
var part = replacerStack[i]
|
|
10292
11469
|
if (part[1] === key && part[0] === val) {
|
|
10293
|
-
val =
|
|
11470
|
+
val = part[2]
|
|
10294
11471
|
replacerStack.splice(i, 1)
|
|
10295
11472
|
break
|
|
10296
11473
|
}
|
|
@@ -11567,884 +12744,6 @@ module.exports = function isArguments(value) {
|
|
|
11567
12744
|
};
|
|
11568
12745
|
|
|
11569
12746
|
|
|
11570
|
-
/***/ }),
|
|
11571
|
-
|
|
11572
|
-
/***/ 5798:
|
|
11573
|
-
/***/ (function(module) {
|
|
11574
|
-
|
|
11575
|
-
"use strict";
|
|
11576
|
-
|
|
11577
|
-
|
|
11578
|
-
var replace = String.prototype.replace;
|
|
11579
|
-
var percentTwenties = /%20/g;
|
|
11580
|
-
|
|
11581
|
-
var Format = {
|
|
11582
|
-
RFC1738: 'RFC1738',
|
|
11583
|
-
RFC3986: 'RFC3986'
|
|
11584
|
-
};
|
|
11585
|
-
|
|
11586
|
-
module.exports = {
|
|
11587
|
-
'default': Format.RFC3986,
|
|
11588
|
-
formatters: {
|
|
11589
|
-
RFC1738: function (value) {
|
|
11590
|
-
return replace.call(value, percentTwenties, '+');
|
|
11591
|
-
},
|
|
11592
|
-
RFC3986: function (value) {
|
|
11593
|
-
return String(value);
|
|
11594
|
-
}
|
|
11595
|
-
},
|
|
11596
|
-
RFC1738: Format.RFC1738,
|
|
11597
|
-
RFC3986: Format.RFC3986
|
|
11598
|
-
};
|
|
11599
|
-
|
|
11600
|
-
|
|
11601
|
-
/***/ }),
|
|
11602
|
-
|
|
11603
|
-
/***/ 129:
|
|
11604
|
-
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
11605
|
-
|
|
11606
|
-
"use strict";
|
|
11607
|
-
|
|
11608
|
-
|
|
11609
|
-
var stringify = __webpack_require__(8261);
|
|
11610
|
-
var parse = __webpack_require__(5235);
|
|
11611
|
-
var formats = __webpack_require__(5798);
|
|
11612
|
-
|
|
11613
|
-
module.exports = {
|
|
11614
|
-
formats: formats,
|
|
11615
|
-
parse: parse,
|
|
11616
|
-
stringify: stringify
|
|
11617
|
-
};
|
|
11618
|
-
|
|
11619
|
-
|
|
11620
|
-
/***/ }),
|
|
11621
|
-
|
|
11622
|
-
/***/ 5235:
|
|
11623
|
-
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
11624
|
-
|
|
11625
|
-
"use strict";
|
|
11626
|
-
|
|
11627
|
-
|
|
11628
|
-
var utils = __webpack_require__(2769);
|
|
11629
|
-
|
|
11630
|
-
var has = Object.prototype.hasOwnProperty;
|
|
11631
|
-
var isArray = Array.isArray;
|
|
11632
|
-
|
|
11633
|
-
var defaults = {
|
|
11634
|
-
allowDots: false,
|
|
11635
|
-
allowPrototypes: false,
|
|
11636
|
-
allowSparse: false,
|
|
11637
|
-
arrayLimit: 20,
|
|
11638
|
-
charset: 'utf-8',
|
|
11639
|
-
charsetSentinel: false,
|
|
11640
|
-
comma: false,
|
|
11641
|
-
decoder: utils.decode,
|
|
11642
|
-
delimiter: '&',
|
|
11643
|
-
depth: 5,
|
|
11644
|
-
ignoreQueryPrefix: false,
|
|
11645
|
-
interpretNumericEntities: false,
|
|
11646
|
-
parameterLimit: 1000,
|
|
11647
|
-
parseArrays: true,
|
|
11648
|
-
plainObjects: false,
|
|
11649
|
-
strictNullHandling: false
|
|
11650
|
-
};
|
|
11651
|
-
|
|
11652
|
-
var interpretNumericEntities = function (str) {
|
|
11653
|
-
return str.replace(/&#(\d+);/g, function ($0, numberStr) {
|
|
11654
|
-
return String.fromCharCode(parseInt(numberStr, 10));
|
|
11655
|
-
});
|
|
11656
|
-
};
|
|
11657
|
-
|
|
11658
|
-
var parseArrayValue = function (val, options) {
|
|
11659
|
-
if (val && typeof val === 'string' && options.comma && val.indexOf(',') > -1) {
|
|
11660
|
-
return val.split(',');
|
|
11661
|
-
}
|
|
11662
|
-
|
|
11663
|
-
return val;
|
|
11664
|
-
};
|
|
11665
|
-
|
|
11666
|
-
// This is what browsers will submit when the ✓ character occurs in an
|
|
11667
|
-
// application/x-www-form-urlencoded body and the encoding of the page containing
|
|
11668
|
-
// the form is iso-8859-1, or when the submitted form has an accept-charset
|
|
11669
|
-
// attribute of iso-8859-1. Presumably also with other charsets that do not contain
|
|
11670
|
-
// the ✓ character, such as us-ascii.
|
|
11671
|
-
var isoSentinel = 'utf8=%26%2310003%3B'; // encodeURIComponent('✓')
|
|
11672
|
-
|
|
11673
|
-
// These are the percent-encoded utf-8 octets representing a checkmark, indicating that the request actually is utf-8 encoded.
|
|
11674
|
-
var charsetSentinel = 'utf8=%E2%9C%93'; // encodeURIComponent('✓')
|
|
11675
|
-
|
|
11676
|
-
var parseValues = function parseQueryStringValues(str, options) {
|
|
11677
|
-
var obj = {};
|
|
11678
|
-
var cleanStr = options.ignoreQueryPrefix ? str.replace(/^\?/, '') : str;
|
|
11679
|
-
var limit = options.parameterLimit === Infinity ? undefined : options.parameterLimit;
|
|
11680
|
-
var parts = cleanStr.split(options.delimiter, limit);
|
|
11681
|
-
var skipIndex = -1; // Keep track of where the utf8 sentinel was found
|
|
11682
|
-
var i;
|
|
11683
|
-
|
|
11684
|
-
var charset = options.charset;
|
|
11685
|
-
if (options.charsetSentinel) {
|
|
11686
|
-
for (i = 0; i < parts.length; ++i) {
|
|
11687
|
-
if (parts[i].indexOf('utf8=') === 0) {
|
|
11688
|
-
if (parts[i] === charsetSentinel) {
|
|
11689
|
-
charset = 'utf-8';
|
|
11690
|
-
} else if (parts[i] === isoSentinel) {
|
|
11691
|
-
charset = 'iso-8859-1';
|
|
11692
|
-
}
|
|
11693
|
-
skipIndex = i;
|
|
11694
|
-
i = parts.length; // The eslint settings do not allow break;
|
|
11695
|
-
}
|
|
11696
|
-
}
|
|
11697
|
-
}
|
|
11698
|
-
|
|
11699
|
-
for (i = 0; i < parts.length; ++i) {
|
|
11700
|
-
if (i === skipIndex) {
|
|
11701
|
-
continue;
|
|
11702
|
-
}
|
|
11703
|
-
var part = parts[i];
|
|
11704
|
-
|
|
11705
|
-
var bracketEqualsPos = part.indexOf(']=');
|
|
11706
|
-
var pos = bracketEqualsPos === -1 ? part.indexOf('=') : bracketEqualsPos + 1;
|
|
11707
|
-
|
|
11708
|
-
var key, val;
|
|
11709
|
-
if (pos === -1) {
|
|
11710
|
-
key = options.decoder(part, defaults.decoder, charset, 'key');
|
|
11711
|
-
val = options.strictNullHandling ? null : '';
|
|
11712
|
-
} else {
|
|
11713
|
-
key = options.decoder(part.slice(0, pos), defaults.decoder, charset, 'key');
|
|
11714
|
-
val = utils.maybeMap(
|
|
11715
|
-
parseArrayValue(part.slice(pos + 1), options),
|
|
11716
|
-
function (encodedVal) {
|
|
11717
|
-
return options.decoder(encodedVal, defaults.decoder, charset, 'value');
|
|
11718
|
-
}
|
|
11719
|
-
);
|
|
11720
|
-
}
|
|
11721
|
-
|
|
11722
|
-
if (val && options.interpretNumericEntities && charset === 'iso-8859-1') {
|
|
11723
|
-
val = interpretNumericEntities(val);
|
|
11724
|
-
}
|
|
11725
|
-
|
|
11726
|
-
if (part.indexOf('[]=') > -1) {
|
|
11727
|
-
val = isArray(val) ? [val] : val;
|
|
11728
|
-
}
|
|
11729
|
-
|
|
11730
|
-
if (has.call(obj, key)) {
|
|
11731
|
-
obj[key] = utils.combine(obj[key], val);
|
|
11732
|
-
} else {
|
|
11733
|
-
obj[key] = val;
|
|
11734
|
-
}
|
|
11735
|
-
}
|
|
11736
|
-
|
|
11737
|
-
return obj;
|
|
11738
|
-
};
|
|
11739
|
-
|
|
11740
|
-
var parseObject = function (chain, val, options, valuesParsed) {
|
|
11741
|
-
var leaf = valuesParsed ? val : parseArrayValue(val, options);
|
|
11742
|
-
|
|
11743
|
-
for (var i = chain.length - 1; i >= 0; --i) {
|
|
11744
|
-
var obj;
|
|
11745
|
-
var root = chain[i];
|
|
11746
|
-
|
|
11747
|
-
if (root === '[]' && options.parseArrays) {
|
|
11748
|
-
obj = [].concat(leaf);
|
|
11749
|
-
} else {
|
|
11750
|
-
obj = options.plainObjects ? Object.create(null) : {};
|
|
11751
|
-
var cleanRoot = root.charAt(0) === '[' && root.charAt(root.length - 1) === ']' ? root.slice(1, -1) : root;
|
|
11752
|
-
var index = parseInt(cleanRoot, 10);
|
|
11753
|
-
if (!options.parseArrays && cleanRoot === '') {
|
|
11754
|
-
obj = { 0: leaf };
|
|
11755
|
-
} else if (
|
|
11756
|
-
!isNaN(index)
|
|
11757
|
-
&& root !== cleanRoot
|
|
11758
|
-
&& String(index) === cleanRoot
|
|
11759
|
-
&& index >= 0
|
|
11760
|
-
&& (options.parseArrays && index <= options.arrayLimit)
|
|
11761
|
-
) {
|
|
11762
|
-
obj = [];
|
|
11763
|
-
obj[index] = leaf;
|
|
11764
|
-
} else {
|
|
11765
|
-
obj[cleanRoot] = leaf;
|
|
11766
|
-
}
|
|
11767
|
-
}
|
|
11768
|
-
|
|
11769
|
-
leaf = obj;
|
|
11770
|
-
}
|
|
11771
|
-
|
|
11772
|
-
return leaf;
|
|
11773
|
-
};
|
|
11774
|
-
|
|
11775
|
-
var parseKeys = function parseQueryStringKeys(givenKey, val, options, valuesParsed) {
|
|
11776
|
-
if (!givenKey) {
|
|
11777
|
-
return;
|
|
11778
|
-
}
|
|
11779
|
-
|
|
11780
|
-
// Transform dot notation to bracket notation
|
|
11781
|
-
var key = options.allowDots ? givenKey.replace(/\.([^.[]+)/g, '[$1]') : givenKey;
|
|
11782
|
-
|
|
11783
|
-
// The regex chunks
|
|
11784
|
-
|
|
11785
|
-
var brackets = /(\[[^[\]]*])/;
|
|
11786
|
-
var child = /(\[[^[\]]*])/g;
|
|
11787
|
-
|
|
11788
|
-
// Get the parent
|
|
11789
|
-
|
|
11790
|
-
var segment = options.depth > 0 && brackets.exec(key);
|
|
11791
|
-
var parent = segment ? key.slice(0, segment.index) : key;
|
|
11792
|
-
|
|
11793
|
-
// Stash the parent if it exists
|
|
11794
|
-
|
|
11795
|
-
var keys = [];
|
|
11796
|
-
if (parent) {
|
|
11797
|
-
// If we aren't using plain objects, optionally prefix keys that would overwrite object prototype properties
|
|
11798
|
-
if (!options.plainObjects && has.call(Object.prototype, parent)) {
|
|
11799
|
-
if (!options.allowPrototypes) {
|
|
11800
|
-
return;
|
|
11801
|
-
}
|
|
11802
|
-
}
|
|
11803
|
-
|
|
11804
|
-
keys.push(parent);
|
|
11805
|
-
}
|
|
11806
|
-
|
|
11807
|
-
// Loop through children appending to the array until we hit depth
|
|
11808
|
-
|
|
11809
|
-
var i = 0;
|
|
11810
|
-
while (options.depth > 0 && (segment = child.exec(key)) !== null && i < options.depth) {
|
|
11811
|
-
i += 1;
|
|
11812
|
-
if (!options.plainObjects && has.call(Object.prototype, segment[1].slice(1, -1))) {
|
|
11813
|
-
if (!options.allowPrototypes) {
|
|
11814
|
-
return;
|
|
11815
|
-
}
|
|
11816
|
-
}
|
|
11817
|
-
keys.push(segment[1]);
|
|
11818
|
-
}
|
|
11819
|
-
|
|
11820
|
-
// If there's a remainder, just add whatever is left
|
|
11821
|
-
|
|
11822
|
-
if (segment) {
|
|
11823
|
-
keys.push('[' + key.slice(segment.index) + ']');
|
|
11824
|
-
}
|
|
11825
|
-
|
|
11826
|
-
return parseObject(keys, val, options, valuesParsed);
|
|
11827
|
-
};
|
|
11828
|
-
|
|
11829
|
-
var normalizeParseOptions = function normalizeParseOptions(opts) {
|
|
11830
|
-
if (!opts) {
|
|
11831
|
-
return defaults;
|
|
11832
|
-
}
|
|
11833
|
-
|
|
11834
|
-
if (opts.decoder !== null && opts.decoder !== undefined && typeof opts.decoder !== 'function') {
|
|
11835
|
-
throw new TypeError('Decoder has to be a function.');
|
|
11836
|
-
}
|
|
11837
|
-
|
|
11838
|
-
if (typeof opts.charset !== 'undefined' && opts.charset !== 'utf-8' && opts.charset !== 'iso-8859-1') {
|
|
11839
|
-
throw new TypeError('The charset option must be either utf-8, iso-8859-1, or undefined');
|
|
11840
|
-
}
|
|
11841
|
-
var charset = typeof opts.charset === 'undefined' ? defaults.charset : opts.charset;
|
|
11842
|
-
|
|
11843
|
-
return {
|
|
11844
|
-
allowDots: typeof opts.allowDots === 'undefined' ? defaults.allowDots : !!opts.allowDots,
|
|
11845
|
-
allowPrototypes: typeof opts.allowPrototypes === 'boolean' ? opts.allowPrototypes : defaults.allowPrototypes,
|
|
11846
|
-
allowSparse: typeof opts.allowSparse === 'boolean' ? opts.allowSparse : defaults.allowSparse,
|
|
11847
|
-
arrayLimit: typeof opts.arrayLimit === 'number' ? opts.arrayLimit : defaults.arrayLimit,
|
|
11848
|
-
charset: charset,
|
|
11849
|
-
charsetSentinel: typeof opts.charsetSentinel === 'boolean' ? opts.charsetSentinel : defaults.charsetSentinel,
|
|
11850
|
-
comma: typeof opts.comma === 'boolean' ? opts.comma : defaults.comma,
|
|
11851
|
-
decoder: typeof opts.decoder === 'function' ? opts.decoder : defaults.decoder,
|
|
11852
|
-
delimiter: typeof opts.delimiter === 'string' || utils.isRegExp(opts.delimiter) ? opts.delimiter : defaults.delimiter,
|
|
11853
|
-
// eslint-disable-next-line no-implicit-coercion, no-extra-parens
|
|
11854
|
-
depth: (typeof opts.depth === 'number' || opts.depth === false) ? +opts.depth : defaults.depth,
|
|
11855
|
-
ignoreQueryPrefix: opts.ignoreQueryPrefix === true,
|
|
11856
|
-
interpretNumericEntities: typeof opts.interpretNumericEntities === 'boolean' ? opts.interpretNumericEntities : defaults.interpretNumericEntities,
|
|
11857
|
-
parameterLimit: typeof opts.parameterLimit === 'number' ? opts.parameterLimit : defaults.parameterLimit,
|
|
11858
|
-
parseArrays: opts.parseArrays !== false,
|
|
11859
|
-
plainObjects: typeof opts.plainObjects === 'boolean' ? opts.plainObjects : defaults.plainObjects,
|
|
11860
|
-
strictNullHandling: typeof opts.strictNullHandling === 'boolean' ? opts.strictNullHandling : defaults.strictNullHandling
|
|
11861
|
-
};
|
|
11862
|
-
};
|
|
11863
|
-
|
|
11864
|
-
module.exports = function (str, opts) {
|
|
11865
|
-
var options = normalizeParseOptions(opts);
|
|
11866
|
-
|
|
11867
|
-
if (str === '' || str === null || typeof str === 'undefined') {
|
|
11868
|
-
return options.plainObjects ? Object.create(null) : {};
|
|
11869
|
-
}
|
|
11870
|
-
|
|
11871
|
-
var tempObj = typeof str === 'string' ? parseValues(str, options) : str;
|
|
11872
|
-
var obj = options.plainObjects ? Object.create(null) : {};
|
|
11873
|
-
|
|
11874
|
-
// Iterate over the keys and setup the new object
|
|
11875
|
-
|
|
11876
|
-
var keys = Object.keys(tempObj);
|
|
11877
|
-
for (var i = 0; i < keys.length; ++i) {
|
|
11878
|
-
var key = keys[i];
|
|
11879
|
-
var newObj = parseKeys(key, tempObj[key], options, typeof str === 'string');
|
|
11880
|
-
obj = utils.merge(obj, newObj, options);
|
|
11881
|
-
}
|
|
11882
|
-
|
|
11883
|
-
if (options.allowSparse === true) {
|
|
11884
|
-
return obj;
|
|
11885
|
-
}
|
|
11886
|
-
|
|
11887
|
-
return utils.compact(obj);
|
|
11888
|
-
};
|
|
11889
|
-
|
|
11890
|
-
|
|
11891
|
-
/***/ }),
|
|
11892
|
-
|
|
11893
|
-
/***/ 8261:
|
|
11894
|
-
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
11895
|
-
|
|
11896
|
-
"use strict";
|
|
11897
|
-
|
|
11898
|
-
|
|
11899
|
-
var getSideChannel = __webpack_require__(7478);
|
|
11900
|
-
var utils = __webpack_require__(2769);
|
|
11901
|
-
var formats = __webpack_require__(5798);
|
|
11902
|
-
var has = Object.prototype.hasOwnProperty;
|
|
11903
|
-
|
|
11904
|
-
var arrayPrefixGenerators = {
|
|
11905
|
-
brackets: function brackets(prefix) {
|
|
11906
|
-
return prefix + '[]';
|
|
11907
|
-
},
|
|
11908
|
-
comma: 'comma',
|
|
11909
|
-
indices: function indices(prefix, key) {
|
|
11910
|
-
return prefix + '[' + key + ']';
|
|
11911
|
-
},
|
|
11912
|
-
repeat: function repeat(prefix) {
|
|
11913
|
-
return prefix;
|
|
11914
|
-
}
|
|
11915
|
-
};
|
|
11916
|
-
|
|
11917
|
-
var isArray = Array.isArray;
|
|
11918
|
-
var push = Array.prototype.push;
|
|
11919
|
-
var pushToArray = function (arr, valueOrArray) {
|
|
11920
|
-
push.apply(arr, isArray(valueOrArray) ? valueOrArray : [valueOrArray]);
|
|
11921
|
-
};
|
|
11922
|
-
|
|
11923
|
-
var toISO = Date.prototype.toISOString;
|
|
11924
|
-
|
|
11925
|
-
var defaultFormat = formats['default'];
|
|
11926
|
-
var defaults = {
|
|
11927
|
-
addQueryPrefix: false,
|
|
11928
|
-
allowDots: false,
|
|
11929
|
-
charset: 'utf-8',
|
|
11930
|
-
charsetSentinel: false,
|
|
11931
|
-
delimiter: '&',
|
|
11932
|
-
encode: true,
|
|
11933
|
-
encoder: utils.encode,
|
|
11934
|
-
encodeValuesOnly: false,
|
|
11935
|
-
format: defaultFormat,
|
|
11936
|
-
formatter: formats.formatters[defaultFormat],
|
|
11937
|
-
// deprecated
|
|
11938
|
-
indices: false,
|
|
11939
|
-
serializeDate: function serializeDate(date) {
|
|
11940
|
-
return toISO.call(date);
|
|
11941
|
-
},
|
|
11942
|
-
skipNulls: false,
|
|
11943
|
-
strictNullHandling: false
|
|
11944
|
-
};
|
|
11945
|
-
|
|
11946
|
-
var isNonNullishPrimitive = function isNonNullishPrimitive(v) {
|
|
11947
|
-
return typeof v === 'string'
|
|
11948
|
-
|| typeof v === 'number'
|
|
11949
|
-
|| typeof v === 'boolean'
|
|
11950
|
-
|| typeof v === 'symbol'
|
|
11951
|
-
|| typeof v === 'bigint';
|
|
11952
|
-
};
|
|
11953
|
-
|
|
11954
|
-
var stringify = function stringify(
|
|
11955
|
-
object,
|
|
11956
|
-
prefix,
|
|
11957
|
-
generateArrayPrefix,
|
|
11958
|
-
strictNullHandling,
|
|
11959
|
-
skipNulls,
|
|
11960
|
-
encoder,
|
|
11961
|
-
filter,
|
|
11962
|
-
sort,
|
|
11963
|
-
allowDots,
|
|
11964
|
-
serializeDate,
|
|
11965
|
-
format,
|
|
11966
|
-
formatter,
|
|
11967
|
-
encodeValuesOnly,
|
|
11968
|
-
charset,
|
|
11969
|
-
sideChannel
|
|
11970
|
-
) {
|
|
11971
|
-
var obj = object;
|
|
11972
|
-
|
|
11973
|
-
if (sideChannel.has(object)) {
|
|
11974
|
-
throw new RangeError('Cyclic object value');
|
|
11975
|
-
}
|
|
11976
|
-
|
|
11977
|
-
if (typeof filter === 'function') {
|
|
11978
|
-
obj = filter(prefix, obj);
|
|
11979
|
-
} else if (obj instanceof Date) {
|
|
11980
|
-
obj = serializeDate(obj);
|
|
11981
|
-
} else if (generateArrayPrefix === 'comma' && isArray(obj)) {
|
|
11982
|
-
obj = utils.maybeMap(obj, function (value) {
|
|
11983
|
-
if (value instanceof Date) {
|
|
11984
|
-
return serializeDate(value);
|
|
11985
|
-
}
|
|
11986
|
-
return value;
|
|
11987
|
-
});
|
|
11988
|
-
}
|
|
11989
|
-
|
|
11990
|
-
if (obj === null) {
|
|
11991
|
-
if (strictNullHandling) {
|
|
11992
|
-
return encoder && !encodeValuesOnly ? encoder(prefix, defaults.encoder, charset, 'key', format) : prefix;
|
|
11993
|
-
}
|
|
11994
|
-
|
|
11995
|
-
obj = '';
|
|
11996
|
-
}
|
|
11997
|
-
|
|
11998
|
-
if (isNonNullishPrimitive(obj) || utils.isBuffer(obj)) {
|
|
11999
|
-
if (encoder) {
|
|
12000
|
-
var keyValue = encodeValuesOnly ? prefix : encoder(prefix, defaults.encoder, charset, 'key', format);
|
|
12001
|
-
return [formatter(keyValue) + '=' + formatter(encoder(obj, defaults.encoder, charset, 'value', format))];
|
|
12002
|
-
}
|
|
12003
|
-
return [formatter(prefix) + '=' + formatter(String(obj))];
|
|
12004
|
-
}
|
|
12005
|
-
|
|
12006
|
-
var values = [];
|
|
12007
|
-
|
|
12008
|
-
if (typeof obj === 'undefined') {
|
|
12009
|
-
return values;
|
|
12010
|
-
}
|
|
12011
|
-
|
|
12012
|
-
var objKeys;
|
|
12013
|
-
if (generateArrayPrefix === 'comma' && isArray(obj)) {
|
|
12014
|
-
// we need to join elements in
|
|
12015
|
-
objKeys = [{ value: obj.length > 0 ? obj.join(',') || null : undefined }];
|
|
12016
|
-
} else if (isArray(filter)) {
|
|
12017
|
-
objKeys = filter;
|
|
12018
|
-
} else {
|
|
12019
|
-
var keys = Object.keys(obj);
|
|
12020
|
-
objKeys = sort ? keys.sort(sort) : keys;
|
|
12021
|
-
}
|
|
12022
|
-
|
|
12023
|
-
for (var i = 0; i < objKeys.length; ++i) {
|
|
12024
|
-
var key = objKeys[i];
|
|
12025
|
-
var value = typeof key === 'object' && key.value !== undefined ? key.value : obj[key];
|
|
12026
|
-
|
|
12027
|
-
if (skipNulls && value === null) {
|
|
12028
|
-
continue;
|
|
12029
|
-
}
|
|
12030
|
-
|
|
12031
|
-
var keyPrefix = isArray(obj)
|
|
12032
|
-
? typeof generateArrayPrefix === 'function' ? generateArrayPrefix(prefix, key) : prefix
|
|
12033
|
-
: prefix + (allowDots ? '.' + key : '[' + key + ']');
|
|
12034
|
-
|
|
12035
|
-
sideChannel.set(object, true);
|
|
12036
|
-
var valueSideChannel = getSideChannel();
|
|
12037
|
-
pushToArray(values, stringify(
|
|
12038
|
-
value,
|
|
12039
|
-
keyPrefix,
|
|
12040
|
-
generateArrayPrefix,
|
|
12041
|
-
strictNullHandling,
|
|
12042
|
-
skipNulls,
|
|
12043
|
-
encoder,
|
|
12044
|
-
filter,
|
|
12045
|
-
sort,
|
|
12046
|
-
allowDots,
|
|
12047
|
-
serializeDate,
|
|
12048
|
-
format,
|
|
12049
|
-
formatter,
|
|
12050
|
-
encodeValuesOnly,
|
|
12051
|
-
charset,
|
|
12052
|
-
valueSideChannel
|
|
12053
|
-
));
|
|
12054
|
-
}
|
|
12055
|
-
|
|
12056
|
-
return values;
|
|
12057
|
-
};
|
|
12058
|
-
|
|
12059
|
-
var normalizeStringifyOptions = function normalizeStringifyOptions(opts) {
|
|
12060
|
-
if (!opts) {
|
|
12061
|
-
return defaults;
|
|
12062
|
-
}
|
|
12063
|
-
|
|
12064
|
-
if (opts.encoder !== null && opts.encoder !== undefined && typeof opts.encoder !== 'function') {
|
|
12065
|
-
throw new TypeError('Encoder has to be a function.');
|
|
12066
|
-
}
|
|
12067
|
-
|
|
12068
|
-
var charset = opts.charset || defaults.charset;
|
|
12069
|
-
if (typeof opts.charset !== 'undefined' && opts.charset !== 'utf-8' && opts.charset !== 'iso-8859-1') {
|
|
12070
|
-
throw new TypeError('The charset option must be either utf-8, iso-8859-1, or undefined');
|
|
12071
|
-
}
|
|
12072
|
-
|
|
12073
|
-
var format = formats['default'];
|
|
12074
|
-
if (typeof opts.format !== 'undefined') {
|
|
12075
|
-
if (!has.call(formats.formatters, opts.format)) {
|
|
12076
|
-
throw new TypeError('Unknown format option provided.');
|
|
12077
|
-
}
|
|
12078
|
-
format = opts.format;
|
|
12079
|
-
}
|
|
12080
|
-
var formatter = formats.formatters[format];
|
|
12081
|
-
|
|
12082
|
-
var filter = defaults.filter;
|
|
12083
|
-
if (typeof opts.filter === 'function' || isArray(opts.filter)) {
|
|
12084
|
-
filter = opts.filter;
|
|
12085
|
-
}
|
|
12086
|
-
|
|
12087
|
-
return {
|
|
12088
|
-
addQueryPrefix: typeof opts.addQueryPrefix === 'boolean' ? opts.addQueryPrefix : defaults.addQueryPrefix,
|
|
12089
|
-
allowDots: typeof opts.allowDots === 'undefined' ? defaults.allowDots : !!opts.allowDots,
|
|
12090
|
-
charset: charset,
|
|
12091
|
-
charsetSentinel: typeof opts.charsetSentinel === 'boolean' ? opts.charsetSentinel : defaults.charsetSentinel,
|
|
12092
|
-
delimiter: typeof opts.delimiter === 'undefined' ? defaults.delimiter : opts.delimiter,
|
|
12093
|
-
encode: typeof opts.encode === 'boolean' ? opts.encode : defaults.encode,
|
|
12094
|
-
encoder: typeof opts.encoder === 'function' ? opts.encoder : defaults.encoder,
|
|
12095
|
-
encodeValuesOnly: typeof opts.encodeValuesOnly === 'boolean' ? opts.encodeValuesOnly : defaults.encodeValuesOnly,
|
|
12096
|
-
filter: filter,
|
|
12097
|
-
format: format,
|
|
12098
|
-
formatter: formatter,
|
|
12099
|
-
serializeDate: typeof opts.serializeDate === 'function' ? opts.serializeDate : defaults.serializeDate,
|
|
12100
|
-
skipNulls: typeof opts.skipNulls === 'boolean' ? opts.skipNulls : defaults.skipNulls,
|
|
12101
|
-
sort: typeof opts.sort === 'function' ? opts.sort : null,
|
|
12102
|
-
strictNullHandling: typeof opts.strictNullHandling === 'boolean' ? opts.strictNullHandling : defaults.strictNullHandling
|
|
12103
|
-
};
|
|
12104
|
-
};
|
|
12105
|
-
|
|
12106
|
-
module.exports = function (object, opts) {
|
|
12107
|
-
var obj = object;
|
|
12108
|
-
var options = normalizeStringifyOptions(opts);
|
|
12109
|
-
|
|
12110
|
-
var objKeys;
|
|
12111
|
-
var filter;
|
|
12112
|
-
|
|
12113
|
-
if (typeof options.filter === 'function') {
|
|
12114
|
-
filter = options.filter;
|
|
12115
|
-
obj = filter('', obj);
|
|
12116
|
-
} else if (isArray(options.filter)) {
|
|
12117
|
-
filter = options.filter;
|
|
12118
|
-
objKeys = filter;
|
|
12119
|
-
}
|
|
12120
|
-
|
|
12121
|
-
var keys = [];
|
|
12122
|
-
|
|
12123
|
-
if (typeof obj !== 'object' || obj === null) {
|
|
12124
|
-
return '';
|
|
12125
|
-
}
|
|
12126
|
-
|
|
12127
|
-
var arrayFormat;
|
|
12128
|
-
if (opts && opts.arrayFormat in arrayPrefixGenerators) {
|
|
12129
|
-
arrayFormat = opts.arrayFormat;
|
|
12130
|
-
} else if (opts && 'indices' in opts) {
|
|
12131
|
-
arrayFormat = opts.indices ? 'indices' : 'repeat';
|
|
12132
|
-
} else {
|
|
12133
|
-
arrayFormat = 'indices';
|
|
12134
|
-
}
|
|
12135
|
-
|
|
12136
|
-
var generateArrayPrefix = arrayPrefixGenerators[arrayFormat];
|
|
12137
|
-
|
|
12138
|
-
if (!objKeys) {
|
|
12139
|
-
objKeys = Object.keys(obj);
|
|
12140
|
-
}
|
|
12141
|
-
|
|
12142
|
-
if (options.sort) {
|
|
12143
|
-
objKeys.sort(options.sort);
|
|
12144
|
-
}
|
|
12145
|
-
|
|
12146
|
-
var sideChannel = getSideChannel();
|
|
12147
|
-
for (var i = 0; i < objKeys.length; ++i) {
|
|
12148
|
-
var key = objKeys[i];
|
|
12149
|
-
|
|
12150
|
-
if (options.skipNulls && obj[key] === null) {
|
|
12151
|
-
continue;
|
|
12152
|
-
}
|
|
12153
|
-
pushToArray(keys, stringify(
|
|
12154
|
-
obj[key],
|
|
12155
|
-
key,
|
|
12156
|
-
generateArrayPrefix,
|
|
12157
|
-
options.strictNullHandling,
|
|
12158
|
-
options.skipNulls,
|
|
12159
|
-
options.encode ? options.encoder : null,
|
|
12160
|
-
options.filter,
|
|
12161
|
-
options.sort,
|
|
12162
|
-
options.allowDots,
|
|
12163
|
-
options.serializeDate,
|
|
12164
|
-
options.format,
|
|
12165
|
-
options.formatter,
|
|
12166
|
-
options.encodeValuesOnly,
|
|
12167
|
-
options.charset,
|
|
12168
|
-
sideChannel
|
|
12169
|
-
));
|
|
12170
|
-
}
|
|
12171
|
-
|
|
12172
|
-
var joined = keys.join(options.delimiter);
|
|
12173
|
-
var prefix = options.addQueryPrefix === true ? '?' : '';
|
|
12174
|
-
|
|
12175
|
-
if (options.charsetSentinel) {
|
|
12176
|
-
if (options.charset === 'iso-8859-1') {
|
|
12177
|
-
// encodeURIComponent('✓'), the "numeric entity" representation of a checkmark
|
|
12178
|
-
prefix += 'utf8=%26%2310003%3B&';
|
|
12179
|
-
} else {
|
|
12180
|
-
// encodeURIComponent('✓')
|
|
12181
|
-
prefix += 'utf8=%E2%9C%93&';
|
|
12182
|
-
}
|
|
12183
|
-
}
|
|
12184
|
-
|
|
12185
|
-
return joined.length > 0 ? prefix + joined : '';
|
|
12186
|
-
};
|
|
12187
|
-
|
|
12188
|
-
|
|
12189
|
-
/***/ }),
|
|
12190
|
-
|
|
12191
|
-
/***/ 2769:
|
|
12192
|
-
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
12193
|
-
|
|
12194
|
-
"use strict";
|
|
12195
|
-
|
|
12196
|
-
|
|
12197
|
-
var formats = __webpack_require__(5798);
|
|
12198
|
-
|
|
12199
|
-
var has = Object.prototype.hasOwnProperty;
|
|
12200
|
-
var isArray = Array.isArray;
|
|
12201
|
-
|
|
12202
|
-
var hexTable = (function () {
|
|
12203
|
-
var array = [];
|
|
12204
|
-
for (var i = 0; i < 256; ++i) {
|
|
12205
|
-
array.push('%' + ((i < 16 ? '0' : '') + i.toString(16)).toUpperCase());
|
|
12206
|
-
}
|
|
12207
|
-
|
|
12208
|
-
return array;
|
|
12209
|
-
}());
|
|
12210
|
-
|
|
12211
|
-
var compactQueue = function compactQueue(queue) {
|
|
12212
|
-
while (queue.length > 1) {
|
|
12213
|
-
var item = queue.pop();
|
|
12214
|
-
var obj = item.obj[item.prop];
|
|
12215
|
-
|
|
12216
|
-
if (isArray(obj)) {
|
|
12217
|
-
var compacted = [];
|
|
12218
|
-
|
|
12219
|
-
for (var j = 0; j < obj.length; ++j) {
|
|
12220
|
-
if (typeof obj[j] !== 'undefined') {
|
|
12221
|
-
compacted.push(obj[j]);
|
|
12222
|
-
}
|
|
12223
|
-
}
|
|
12224
|
-
|
|
12225
|
-
item.obj[item.prop] = compacted;
|
|
12226
|
-
}
|
|
12227
|
-
}
|
|
12228
|
-
};
|
|
12229
|
-
|
|
12230
|
-
var arrayToObject = function arrayToObject(source, options) {
|
|
12231
|
-
var obj = options && options.plainObjects ? Object.create(null) : {};
|
|
12232
|
-
for (var i = 0; i < source.length; ++i) {
|
|
12233
|
-
if (typeof source[i] !== 'undefined') {
|
|
12234
|
-
obj[i] = source[i];
|
|
12235
|
-
}
|
|
12236
|
-
}
|
|
12237
|
-
|
|
12238
|
-
return obj;
|
|
12239
|
-
};
|
|
12240
|
-
|
|
12241
|
-
var merge = function merge(target, source, options) {
|
|
12242
|
-
/* eslint no-param-reassign: 0 */
|
|
12243
|
-
if (!source) {
|
|
12244
|
-
return target;
|
|
12245
|
-
}
|
|
12246
|
-
|
|
12247
|
-
if (typeof source !== 'object') {
|
|
12248
|
-
if (isArray(target)) {
|
|
12249
|
-
target.push(source);
|
|
12250
|
-
} else if (target && typeof target === 'object') {
|
|
12251
|
-
if ((options && (options.plainObjects || options.allowPrototypes)) || !has.call(Object.prototype, source)) {
|
|
12252
|
-
target[source] = true;
|
|
12253
|
-
}
|
|
12254
|
-
} else {
|
|
12255
|
-
return [target, source];
|
|
12256
|
-
}
|
|
12257
|
-
|
|
12258
|
-
return target;
|
|
12259
|
-
}
|
|
12260
|
-
|
|
12261
|
-
if (!target || typeof target !== 'object') {
|
|
12262
|
-
return [target].concat(source);
|
|
12263
|
-
}
|
|
12264
|
-
|
|
12265
|
-
var mergeTarget = target;
|
|
12266
|
-
if (isArray(target) && !isArray(source)) {
|
|
12267
|
-
mergeTarget = arrayToObject(target, options);
|
|
12268
|
-
}
|
|
12269
|
-
|
|
12270
|
-
if (isArray(target) && isArray(source)) {
|
|
12271
|
-
source.forEach(function (item, i) {
|
|
12272
|
-
if (has.call(target, i)) {
|
|
12273
|
-
var targetItem = target[i];
|
|
12274
|
-
if (targetItem && typeof targetItem === 'object' && item && typeof item === 'object') {
|
|
12275
|
-
target[i] = merge(targetItem, item, options);
|
|
12276
|
-
} else {
|
|
12277
|
-
target.push(item);
|
|
12278
|
-
}
|
|
12279
|
-
} else {
|
|
12280
|
-
target[i] = item;
|
|
12281
|
-
}
|
|
12282
|
-
});
|
|
12283
|
-
return target;
|
|
12284
|
-
}
|
|
12285
|
-
|
|
12286
|
-
return Object.keys(source).reduce(function (acc, key) {
|
|
12287
|
-
var value = source[key];
|
|
12288
|
-
|
|
12289
|
-
if (has.call(acc, key)) {
|
|
12290
|
-
acc[key] = merge(acc[key], value, options);
|
|
12291
|
-
} else {
|
|
12292
|
-
acc[key] = value;
|
|
12293
|
-
}
|
|
12294
|
-
return acc;
|
|
12295
|
-
}, mergeTarget);
|
|
12296
|
-
};
|
|
12297
|
-
|
|
12298
|
-
var assign = function assignSingleSource(target, source) {
|
|
12299
|
-
return Object.keys(source).reduce(function (acc, key) {
|
|
12300
|
-
acc[key] = source[key];
|
|
12301
|
-
return acc;
|
|
12302
|
-
}, target);
|
|
12303
|
-
};
|
|
12304
|
-
|
|
12305
|
-
var decode = function (str, decoder, charset) {
|
|
12306
|
-
var strWithoutPlus = str.replace(/\+/g, ' ');
|
|
12307
|
-
if (charset === 'iso-8859-1') {
|
|
12308
|
-
// unescape never throws, no try...catch needed:
|
|
12309
|
-
return strWithoutPlus.replace(/%[0-9a-f]{2}/gi, unescape);
|
|
12310
|
-
}
|
|
12311
|
-
// utf-8
|
|
12312
|
-
try {
|
|
12313
|
-
return decodeURIComponent(strWithoutPlus);
|
|
12314
|
-
} catch (e) {
|
|
12315
|
-
return strWithoutPlus;
|
|
12316
|
-
}
|
|
12317
|
-
};
|
|
12318
|
-
|
|
12319
|
-
var encode = function encode(str, defaultEncoder, charset, kind, format) {
|
|
12320
|
-
// This code was originally written by Brian White (mscdex) for the io.js core querystring library.
|
|
12321
|
-
// It has been adapted here for stricter adherence to RFC 3986
|
|
12322
|
-
if (str.length === 0) {
|
|
12323
|
-
return str;
|
|
12324
|
-
}
|
|
12325
|
-
|
|
12326
|
-
var string = str;
|
|
12327
|
-
if (typeof str === 'symbol') {
|
|
12328
|
-
string = Symbol.prototype.toString.call(str);
|
|
12329
|
-
} else if (typeof str !== 'string') {
|
|
12330
|
-
string = String(str);
|
|
12331
|
-
}
|
|
12332
|
-
|
|
12333
|
-
if (charset === 'iso-8859-1') {
|
|
12334
|
-
return escape(string).replace(/%u[0-9a-f]{4}/gi, function ($0) {
|
|
12335
|
-
return '%26%23' + parseInt($0.slice(2), 16) + '%3B';
|
|
12336
|
-
});
|
|
12337
|
-
}
|
|
12338
|
-
|
|
12339
|
-
var out = '';
|
|
12340
|
-
for (var i = 0; i < string.length; ++i) {
|
|
12341
|
-
var c = string.charCodeAt(i);
|
|
12342
|
-
|
|
12343
|
-
if (
|
|
12344
|
-
c === 0x2D // -
|
|
12345
|
-
|| c === 0x2E // .
|
|
12346
|
-
|| c === 0x5F // _
|
|
12347
|
-
|| c === 0x7E // ~
|
|
12348
|
-
|| (c >= 0x30 && c <= 0x39) // 0-9
|
|
12349
|
-
|| (c >= 0x41 && c <= 0x5A) // a-z
|
|
12350
|
-
|| (c >= 0x61 && c <= 0x7A) // A-Z
|
|
12351
|
-
|| (format === formats.RFC1738 && (c === 0x28 || c === 0x29)) // ( )
|
|
12352
|
-
) {
|
|
12353
|
-
out += string.charAt(i);
|
|
12354
|
-
continue;
|
|
12355
|
-
}
|
|
12356
|
-
|
|
12357
|
-
if (c < 0x80) {
|
|
12358
|
-
out = out + hexTable[c];
|
|
12359
|
-
continue;
|
|
12360
|
-
}
|
|
12361
|
-
|
|
12362
|
-
if (c < 0x800) {
|
|
12363
|
-
out = out + (hexTable[0xC0 | (c >> 6)] + hexTable[0x80 | (c & 0x3F)]);
|
|
12364
|
-
continue;
|
|
12365
|
-
}
|
|
12366
|
-
|
|
12367
|
-
if (c < 0xD800 || c >= 0xE000) {
|
|
12368
|
-
out = out + (hexTable[0xE0 | (c >> 12)] + hexTable[0x80 | ((c >> 6) & 0x3F)] + hexTable[0x80 | (c & 0x3F)]);
|
|
12369
|
-
continue;
|
|
12370
|
-
}
|
|
12371
|
-
|
|
12372
|
-
i += 1;
|
|
12373
|
-
c = 0x10000 + (((c & 0x3FF) << 10) | (string.charCodeAt(i) & 0x3FF));
|
|
12374
|
-
out += hexTable[0xF0 | (c >> 18)]
|
|
12375
|
-
+ hexTable[0x80 | ((c >> 12) & 0x3F)]
|
|
12376
|
-
+ hexTable[0x80 | ((c >> 6) & 0x3F)]
|
|
12377
|
-
+ hexTable[0x80 | (c & 0x3F)];
|
|
12378
|
-
}
|
|
12379
|
-
|
|
12380
|
-
return out;
|
|
12381
|
-
};
|
|
12382
|
-
|
|
12383
|
-
var compact = function compact(value) {
|
|
12384
|
-
var queue = [{ obj: { o: value }, prop: 'o' }];
|
|
12385
|
-
var refs = [];
|
|
12386
|
-
|
|
12387
|
-
for (var i = 0; i < queue.length; ++i) {
|
|
12388
|
-
var item = queue[i];
|
|
12389
|
-
var obj = item.obj[item.prop];
|
|
12390
|
-
|
|
12391
|
-
var keys = Object.keys(obj);
|
|
12392
|
-
for (var j = 0; j < keys.length; ++j) {
|
|
12393
|
-
var key = keys[j];
|
|
12394
|
-
var val = obj[key];
|
|
12395
|
-
if (typeof val === 'object' && val !== null && refs.indexOf(val) === -1) {
|
|
12396
|
-
queue.push({ obj: obj, prop: key });
|
|
12397
|
-
refs.push(val);
|
|
12398
|
-
}
|
|
12399
|
-
}
|
|
12400
|
-
}
|
|
12401
|
-
|
|
12402
|
-
compactQueue(queue);
|
|
12403
|
-
|
|
12404
|
-
return value;
|
|
12405
|
-
};
|
|
12406
|
-
|
|
12407
|
-
var isRegExp = function isRegExp(obj) {
|
|
12408
|
-
return Object.prototype.toString.call(obj) === '[object RegExp]';
|
|
12409
|
-
};
|
|
12410
|
-
|
|
12411
|
-
var isBuffer = function isBuffer(obj) {
|
|
12412
|
-
if (!obj || typeof obj !== 'object') {
|
|
12413
|
-
return false;
|
|
12414
|
-
}
|
|
12415
|
-
|
|
12416
|
-
return !!(obj.constructor && obj.constructor.isBuffer && obj.constructor.isBuffer(obj));
|
|
12417
|
-
};
|
|
12418
|
-
|
|
12419
|
-
var combine = function combine(a, b) {
|
|
12420
|
-
return [].concat(a, b);
|
|
12421
|
-
};
|
|
12422
|
-
|
|
12423
|
-
var maybeMap = function maybeMap(val, fn) {
|
|
12424
|
-
if (isArray(val)) {
|
|
12425
|
-
var mapped = [];
|
|
12426
|
-
for (var i = 0; i < val.length; i += 1) {
|
|
12427
|
-
mapped.push(fn(val[i]));
|
|
12428
|
-
}
|
|
12429
|
-
return mapped;
|
|
12430
|
-
}
|
|
12431
|
-
return fn(val);
|
|
12432
|
-
};
|
|
12433
|
-
|
|
12434
|
-
module.exports = {
|
|
12435
|
-
arrayToObject: arrayToObject,
|
|
12436
|
-
assign: assign,
|
|
12437
|
-
combine: combine,
|
|
12438
|
-
compact: compact,
|
|
12439
|
-
decode: decode,
|
|
12440
|
-
encode: encode,
|
|
12441
|
-
isBuffer: isBuffer,
|
|
12442
|
-
isRegExp: isRegExp,
|
|
12443
|
-
maybeMap: maybeMap,
|
|
12444
|
-
merge: merge
|
|
12445
|
-
};
|
|
12446
|
-
|
|
12447
|
-
|
|
12448
12747
|
/***/ }),
|
|
12449
12748
|
|
|
12450
12749
|
/***/ 7478:
|
|
@@ -14386,6 +14685,13 @@ exports["default"] = xs;
|
|
|
14386
14685
|
|
|
14387
14686
|
/* (ignored) */
|
|
14388
14687
|
|
|
14688
|
+
/***/ }),
|
|
14689
|
+
|
|
14690
|
+
/***/ 3695:
|
|
14691
|
+
/***/ (function() {
|
|
14692
|
+
|
|
14693
|
+
/* (ignored) */
|
|
14694
|
+
|
|
14389
14695
|
/***/ })
|
|
14390
14696
|
|
|
14391
14697
|
/******/ });
|
|
@@ -33682,7 +33988,7 @@ class API {
|
|
|
33682
33988
|
return {
|
|
33683
33989
|
clientName: "@seamly/web-ui",
|
|
33684
33990
|
clientVariant: this.layoutMode,
|
|
33685
|
-
clientVersion: "20.2.0
|
|
33991
|
+
clientVersion: "20.2.0",
|
|
33686
33992
|
currentUrl: window.location.toString(),
|
|
33687
33993
|
screenResolution: `${window.screen.width}x${window.screen.height}`,
|
|
33688
33994
|
timezone: getTimeZone(),
|