@aws-amplify/storage 4.5.9-unstable.1 → 4.5.9-unstable.2

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.
@@ -410,12 +410,8 @@ __webpack_require__.r(__webpack_exports__);
410
410
  /* harmony import */ var _whatwgEncodingApi__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./whatwgEncodingApi */ "../../node_modules/@aws-crypto/crc32/node_modules/@aws-sdk/util-utf8-browser/dist-es/whatwgEncodingApi.js");
411
411
 
412
412
 
413
- var fromUtf8 = function (input) {
414
- return typeof TextEncoder === "function" ? Object(_whatwgEncodingApi__WEBPACK_IMPORTED_MODULE_1__["fromUtf8"])(input) : Object(_pureJs__WEBPACK_IMPORTED_MODULE_0__["fromUtf8"])(input);
415
- };
416
- var toUtf8 = function (input) {
417
- return typeof TextDecoder === "function" ? Object(_whatwgEncodingApi__WEBPACK_IMPORTED_MODULE_1__["toUtf8"])(input) : Object(_pureJs__WEBPACK_IMPORTED_MODULE_0__["toUtf8"])(input);
418
- };
413
+ const fromUtf8 = (input) => typeof TextEncoder === "function" ? Object(_whatwgEncodingApi__WEBPACK_IMPORTED_MODULE_1__["fromUtf8"])(input) : Object(_pureJs__WEBPACK_IMPORTED_MODULE_0__["fromUtf8"])(input);
414
+ const toUtf8 = (input) => typeof TextDecoder === "function" ? Object(_whatwgEncodingApi__WEBPACK_IMPORTED_MODULE_1__["toUtf8"])(input) : Object(_pureJs__WEBPACK_IMPORTED_MODULE_0__["toUtf8"])(input);
419
415
 
420
416
 
421
417
  /***/ }),
@@ -431,44 +427,44 @@ var toUtf8 = function (input) {
431
427
  __webpack_require__.r(__webpack_exports__);
432
428
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "fromUtf8", function() { return fromUtf8; });
433
429
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "toUtf8", function() { return toUtf8; });
434
- var fromUtf8 = function (input) {
435
- var bytes = [];
436
- for (var i = 0, len = input.length; i < len; i++) {
437
- var value = input.charCodeAt(i);
430
+ const fromUtf8 = (input) => {
431
+ const bytes = [];
432
+ for (let i = 0, len = input.length; i < len; i++) {
433
+ const value = input.charCodeAt(i);
438
434
  if (value < 0x80) {
439
435
  bytes.push(value);
440
436
  }
441
437
  else if (value < 0x800) {
442
- bytes.push((value >> 6) | 192, (value & 63) | 128);
438
+ bytes.push((value >> 6) | 0b11000000, (value & 0b111111) | 0b10000000);
443
439
  }
444
440
  else if (i + 1 < input.length && (value & 0xfc00) === 0xd800 && (input.charCodeAt(i + 1) & 0xfc00) === 0xdc00) {
445
- var surrogatePair = 0x10000 + ((value & 1023) << 10) + (input.charCodeAt(++i) & 1023);
446
- bytes.push((surrogatePair >> 18) | 240, ((surrogatePair >> 12) & 63) | 128, ((surrogatePair >> 6) & 63) | 128, (surrogatePair & 63) | 128);
441
+ const surrogatePair = 0x10000 + ((value & 0b1111111111) << 10) + (input.charCodeAt(++i) & 0b1111111111);
442
+ bytes.push((surrogatePair >> 18) | 0b11110000, ((surrogatePair >> 12) & 0b111111) | 0b10000000, ((surrogatePair >> 6) & 0b111111) | 0b10000000, (surrogatePair & 0b111111) | 0b10000000);
447
443
  }
448
444
  else {
449
- bytes.push((value >> 12) | 224, ((value >> 6) & 63) | 128, (value & 63) | 128);
445
+ bytes.push((value >> 12) | 0b11100000, ((value >> 6) & 0b111111) | 0b10000000, (value & 0b111111) | 0b10000000);
450
446
  }
451
447
  }
452
448
  return Uint8Array.from(bytes);
453
449
  };
454
- var toUtf8 = function (input) {
455
- var decoded = "";
456
- for (var i = 0, len = input.length; i < len; i++) {
457
- var byte = input[i];
450
+ const toUtf8 = (input) => {
451
+ let decoded = "";
452
+ for (let i = 0, len = input.length; i < len; i++) {
453
+ const byte = input[i];
458
454
  if (byte < 0x80) {
459
455
  decoded += String.fromCharCode(byte);
460
456
  }
461
- else if (192 <= byte && byte < 224) {
462
- var nextByte = input[++i];
463
- decoded += String.fromCharCode(((byte & 31) << 6) | (nextByte & 63));
457
+ else if (0b11000000 <= byte && byte < 0b11100000) {
458
+ const nextByte = input[++i];
459
+ decoded += String.fromCharCode(((byte & 0b11111) << 6) | (nextByte & 0b111111));
464
460
  }
465
- else if (240 <= byte && byte < 365) {
466
- var surrogatePair = [byte, input[++i], input[++i], input[++i]];
467
- var encoded = "%" + surrogatePair.map(function (byteValue) { return byteValue.toString(16); }).join("%");
461
+ else if (0b11110000 <= byte && byte < 0b101101101) {
462
+ const surrogatePair = [byte, input[++i], input[++i], input[++i]];
463
+ const encoded = "%" + surrogatePair.map((byteValue) => byteValue.toString(16)).join("%");
468
464
  decoded += decodeURIComponent(encoded);
469
465
  }
470
466
  else {
471
- decoded += String.fromCharCode(((byte & 15) << 12) | ((input[++i] & 63) << 6) | (input[++i] & 63));
467
+ decoded += String.fromCharCode(((byte & 0b1111) << 12) | ((input[++i] & 0b111111) << 6) | (input[++i] & 0b111111));
472
468
  }
473
469
  }
474
470
  return decoded;
@@ -1060,12 +1056,8 @@ __webpack_require__.r(__webpack_exports__);
1060
1056
  /* harmony import */ var _whatwgEncodingApi__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./whatwgEncodingApi */ "../../node_modules/@aws-crypto/sha256-browser/node_modules/@aws-sdk/util-utf8-browser/dist-es/whatwgEncodingApi.js");
1061
1057
 
1062
1058
 
1063
- var fromUtf8 = function (input) {
1064
- return typeof TextEncoder === "function" ? Object(_whatwgEncodingApi__WEBPACK_IMPORTED_MODULE_1__["fromUtf8"])(input) : Object(_pureJs__WEBPACK_IMPORTED_MODULE_0__["fromUtf8"])(input);
1065
- };
1066
- var toUtf8 = function (input) {
1067
- return typeof TextDecoder === "function" ? Object(_whatwgEncodingApi__WEBPACK_IMPORTED_MODULE_1__["toUtf8"])(input) : Object(_pureJs__WEBPACK_IMPORTED_MODULE_0__["toUtf8"])(input);
1068
- };
1059
+ const fromUtf8 = (input) => typeof TextEncoder === "function" ? Object(_whatwgEncodingApi__WEBPACK_IMPORTED_MODULE_1__["fromUtf8"])(input) : Object(_pureJs__WEBPACK_IMPORTED_MODULE_0__["fromUtf8"])(input);
1060
+ const toUtf8 = (input) => typeof TextDecoder === "function" ? Object(_whatwgEncodingApi__WEBPACK_IMPORTED_MODULE_1__["toUtf8"])(input) : Object(_pureJs__WEBPACK_IMPORTED_MODULE_0__["toUtf8"])(input);
1069
1061
 
1070
1062
 
1071
1063
  /***/ }),
@@ -1081,44 +1073,44 @@ var toUtf8 = function (input) {
1081
1073
  __webpack_require__.r(__webpack_exports__);
1082
1074
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "fromUtf8", function() { return fromUtf8; });
1083
1075
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "toUtf8", function() { return toUtf8; });
1084
- var fromUtf8 = function (input) {
1085
- var bytes = [];
1086
- for (var i = 0, len = input.length; i < len; i++) {
1087
- var value = input.charCodeAt(i);
1076
+ const fromUtf8 = (input) => {
1077
+ const bytes = [];
1078
+ for (let i = 0, len = input.length; i < len; i++) {
1079
+ const value = input.charCodeAt(i);
1088
1080
  if (value < 0x80) {
1089
1081
  bytes.push(value);
1090
1082
  }
1091
1083
  else if (value < 0x800) {
1092
- bytes.push((value >> 6) | 192, (value & 63) | 128);
1084
+ bytes.push((value >> 6) | 0b11000000, (value & 0b111111) | 0b10000000);
1093
1085
  }
1094
1086
  else if (i + 1 < input.length && (value & 0xfc00) === 0xd800 && (input.charCodeAt(i + 1) & 0xfc00) === 0xdc00) {
1095
- var surrogatePair = 0x10000 + ((value & 1023) << 10) + (input.charCodeAt(++i) & 1023);
1096
- bytes.push((surrogatePair >> 18) | 240, ((surrogatePair >> 12) & 63) | 128, ((surrogatePair >> 6) & 63) | 128, (surrogatePair & 63) | 128);
1087
+ const surrogatePair = 0x10000 + ((value & 0b1111111111) << 10) + (input.charCodeAt(++i) & 0b1111111111);
1088
+ bytes.push((surrogatePair >> 18) | 0b11110000, ((surrogatePair >> 12) & 0b111111) | 0b10000000, ((surrogatePair >> 6) & 0b111111) | 0b10000000, (surrogatePair & 0b111111) | 0b10000000);
1097
1089
  }
1098
1090
  else {
1099
- bytes.push((value >> 12) | 224, ((value >> 6) & 63) | 128, (value & 63) | 128);
1091
+ bytes.push((value >> 12) | 0b11100000, ((value >> 6) & 0b111111) | 0b10000000, (value & 0b111111) | 0b10000000);
1100
1092
  }
1101
1093
  }
1102
1094
  return Uint8Array.from(bytes);
1103
1095
  };
1104
- var toUtf8 = function (input) {
1105
- var decoded = "";
1106
- for (var i = 0, len = input.length; i < len; i++) {
1107
- var byte = input[i];
1096
+ const toUtf8 = (input) => {
1097
+ let decoded = "";
1098
+ for (let i = 0, len = input.length; i < len; i++) {
1099
+ const byte = input[i];
1108
1100
  if (byte < 0x80) {
1109
1101
  decoded += String.fromCharCode(byte);
1110
1102
  }
1111
- else if (192 <= byte && byte < 224) {
1112
- var nextByte = input[++i];
1113
- decoded += String.fromCharCode(((byte & 31) << 6) | (nextByte & 63));
1103
+ else if (0b11000000 <= byte && byte < 0b11100000) {
1104
+ const nextByte = input[++i];
1105
+ decoded += String.fromCharCode(((byte & 0b11111) << 6) | (nextByte & 0b111111));
1114
1106
  }
1115
- else if (240 <= byte && byte < 365) {
1116
- var surrogatePair = [byte, input[++i], input[++i], input[++i]];
1117
- var encoded = "%" + surrogatePair.map(function (byteValue) { return byteValue.toString(16); }).join("%");
1107
+ else if (0b11110000 <= byte && byte < 0b101101101) {
1108
+ const surrogatePair = [byte, input[++i], input[++i], input[++i]];
1109
+ const encoded = "%" + surrogatePair.map((byteValue) => byteValue.toString(16)).join("%");
1118
1110
  decoded += decodeURIComponent(encoded);
1119
1111
  }
1120
1112
  else {
1121
- decoded += String.fromCharCode(((byte & 15) << 12) | ((input[++i] & 63) << 6) | (input[++i] & 63));
1113
+ decoded += String.fromCharCode(((byte & 0b1111) << 12) | ((input[++i] & 0b111111) << 6) | (input[++i] & 0b111111));
1122
1114
  }
1123
1115
  }
1124
1116
  return decoded;
@@ -1655,12 +1647,8 @@ __webpack_require__.r(__webpack_exports__);
1655
1647
  /* harmony import */ var _whatwgEncodingApi__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./whatwgEncodingApi */ "../../node_modules/@aws-crypto/sha256-js/node_modules/@aws-sdk/util-utf8-browser/dist-es/whatwgEncodingApi.js");
1656
1648
 
1657
1649
 
1658
- var fromUtf8 = function (input) {
1659
- return typeof TextEncoder === "function" ? Object(_whatwgEncodingApi__WEBPACK_IMPORTED_MODULE_1__["fromUtf8"])(input) : Object(_pureJs__WEBPACK_IMPORTED_MODULE_0__["fromUtf8"])(input);
1660
- };
1661
- var toUtf8 = function (input) {
1662
- return typeof TextDecoder === "function" ? Object(_whatwgEncodingApi__WEBPACK_IMPORTED_MODULE_1__["toUtf8"])(input) : Object(_pureJs__WEBPACK_IMPORTED_MODULE_0__["toUtf8"])(input);
1663
- };
1650
+ const fromUtf8 = (input) => typeof TextEncoder === "function" ? Object(_whatwgEncodingApi__WEBPACK_IMPORTED_MODULE_1__["fromUtf8"])(input) : Object(_pureJs__WEBPACK_IMPORTED_MODULE_0__["fromUtf8"])(input);
1651
+ const toUtf8 = (input) => typeof TextDecoder === "function" ? Object(_whatwgEncodingApi__WEBPACK_IMPORTED_MODULE_1__["toUtf8"])(input) : Object(_pureJs__WEBPACK_IMPORTED_MODULE_0__["toUtf8"])(input);
1664
1652
 
1665
1653
 
1666
1654
  /***/ }),
@@ -1676,44 +1664,44 @@ var toUtf8 = function (input) {
1676
1664
  __webpack_require__.r(__webpack_exports__);
1677
1665
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "fromUtf8", function() { return fromUtf8; });
1678
1666
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "toUtf8", function() { return toUtf8; });
1679
- var fromUtf8 = function (input) {
1680
- var bytes = [];
1681
- for (var i = 0, len = input.length; i < len; i++) {
1682
- var value = input.charCodeAt(i);
1667
+ const fromUtf8 = (input) => {
1668
+ const bytes = [];
1669
+ for (let i = 0, len = input.length; i < len; i++) {
1670
+ const value = input.charCodeAt(i);
1683
1671
  if (value < 0x80) {
1684
1672
  bytes.push(value);
1685
1673
  }
1686
1674
  else if (value < 0x800) {
1687
- bytes.push((value >> 6) | 192, (value & 63) | 128);
1675
+ bytes.push((value >> 6) | 0b11000000, (value & 0b111111) | 0b10000000);
1688
1676
  }
1689
1677
  else if (i + 1 < input.length && (value & 0xfc00) === 0xd800 && (input.charCodeAt(i + 1) & 0xfc00) === 0xdc00) {
1690
- var surrogatePair = 0x10000 + ((value & 1023) << 10) + (input.charCodeAt(++i) & 1023);
1691
- bytes.push((surrogatePair >> 18) | 240, ((surrogatePair >> 12) & 63) | 128, ((surrogatePair >> 6) & 63) | 128, (surrogatePair & 63) | 128);
1678
+ const surrogatePair = 0x10000 + ((value & 0b1111111111) << 10) + (input.charCodeAt(++i) & 0b1111111111);
1679
+ bytes.push((surrogatePair >> 18) | 0b11110000, ((surrogatePair >> 12) & 0b111111) | 0b10000000, ((surrogatePair >> 6) & 0b111111) | 0b10000000, (surrogatePair & 0b111111) | 0b10000000);
1692
1680
  }
1693
1681
  else {
1694
- bytes.push((value >> 12) | 224, ((value >> 6) & 63) | 128, (value & 63) | 128);
1682
+ bytes.push((value >> 12) | 0b11100000, ((value >> 6) & 0b111111) | 0b10000000, (value & 0b111111) | 0b10000000);
1695
1683
  }
1696
1684
  }
1697
1685
  return Uint8Array.from(bytes);
1698
1686
  };
1699
- var toUtf8 = function (input) {
1700
- var decoded = "";
1701
- for (var i = 0, len = input.length; i < len; i++) {
1702
- var byte = input[i];
1687
+ const toUtf8 = (input) => {
1688
+ let decoded = "";
1689
+ for (let i = 0, len = input.length; i < len; i++) {
1690
+ const byte = input[i];
1703
1691
  if (byte < 0x80) {
1704
1692
  decoded += String.fromCharCode(byte);
1705
1693
  }
1706
- else if (192 <= byte && byte < 224) {
1707
- var nextByte = input[++i];
1708
- decoded += String.fromCharCode(((byte & 31) << 6) | (nextByte & 63));
1694
+ else if (0b11000000 <= byte && byte < 0b11100000) {
1695
+ const nextByte = input[++i];
1696
+ decoded += String.fromCharCode(((byte & 0b11111) << 6) | (nextByte & 0b111111));
1709
1697
  }
1710
- else if (240 <= byte && byte < 365) {
1711
- var surrogatePair = [byte, input[++i], input[++i], input[++i]];
1712
- var encoded = "%" + surrogatePair.map(function (byteValue) { return byteValue.toString(16); }).join("%");
1698
+ else if (0b11110000 <= byte && byte < 0b101101101) {
1699
+ const surrogatePair = [byte, input[++i], input[++i], input[++i]];
1700
+ const encoded = "%" + surrogatePair.map((byteValue) => byteValue.toString(16)).join("%");
1713
1701
  decoded += decodeURIComponent(encoded);
1714
1702
  }
1715
1703
  else {
1716
- decoded += String.fromCharCode(((byte & 15) << 12) | ((input[++i] & 63) << 6) | (input[++i] & 63));
1704
+ decoded += String.fromCharCode(((byte & 0b1111) << 12) | ((input[++i] & 0b111111) << 6) | (input[++i] & 0b111111));
1717
1705
  }
1718
1706
  }
1719
1707
  return decoded;
@@ -41702,7 +41690,7 @@ function calculateBodyLength(body) {
41702
41690
  "use strict";
41703
41691
  __webpack_require__.r(__webpack_exports__);
41704
41692
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "locateWindow", function() { return locateWindow; });
41705
- var fallbackWindow = {};
41693
+ const fallbackWindow = {};
41706
41694
  function locateWindow() {
41707
41695
  if (typeof window !== "undefined") {
41708
41696
  return window;