@aws-amplify/core 5.3.2-unstable.ffe65ea.1 → 5.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (507) hide show
  1. package/internals/aws-client-utils/package.json +8 -0
  2. package/internals/aws-clients/pinpoint/package.json +8 -0
  3. package/lib/Amplify.js +18 -3
  4. package/lib/AwsClients/CognitoIdentity/base.d.ts +28 -0
  5. package/lib/AwsClients/CognitoIdentity/base.js +109 -0
  6. package/lib/AwsClients/CognitoIdentity/getCredentialsForIdentity.d.ts +12 -0
  7. package/lib/AwsClients/CognitoIdentity/getCredentialsForIdentity.js +82 -0
  8. package/lib/AwsClients/CognitoIdentity/getId.d.ts +12 -0
  9. package/lib/AwsClients/CognitoIdentity/getId.js +72 -0
  10. package/lib/AwsClients/CognitoIdentity/index.d.ts +2 -0
  11. package/lib/AwsClients/CognitoIdentity/index.js +9 -0
  12. package/lib/AwsClients/CognitoIdentity/types.d.ts +153 -0
  13. package/lib/AwsClients/CognitoIdentity/types.js +4 -0
  14. package/lib/AwsClients/Pinpoint/base.d.ts +17 -0
  15. package/lib/AwsClients/Pinpoint/base.js +39 -0
  16. package/lib/AwsClients/Pinpoint/getInAppMessages.d.ts +13 -0
  17. package/lib/AwsClients/Pinpoint/getInAppMessages.js +77 -0
  18. package/lib/AwsClients/Pinpoint/index.d.ts +4 -0
  19. package/lib/AwsClients/Pinpoint/index.js +11 -0
  20. package/lib/AwsClients/Pinpoint/putEvents.d.ts +13 -0
  21. package/lib/AwsClients/Pinpoint/putEvents.js +78 -0
  22. package/lib/AwsClients/Pinpoint/types.d.ts +836 -0
  23. package/lib/AwsClients/Pinpoint/types.js +5 -0
  24. package/lib/AwsClients/Pinpoint/updateEndpoint.d.ts +13 -0
  25. package/lib/AwsClients/Pinpoint/updateEndpoint.js +81 -0
  26. package/lib/ClientDevice/android.js +3 -2
  27. package/lib/ClientDevice/browser.js +1 -1
  28. package/lib/ClientDevice/index.js +3 -3
  29. package/lib/ClientDevice/ios.js +3 -2
  30. package/lib/ClientDevice/reactnative.js +3 -3
  31. package/lib/Credentials.js +176 -113
  32. package/lib/Errors.js +1 -1
  33. package/lib/Hub.d.ts +4 -4
  34. package/lib/Hub.js +47 -12
  35. package/lib/I18n/I18n.js +13 -3
  36. package/lib/I18n/index.js +1 -1
  37. package/lib/I18n/types.js +1 -1
  38. package/lib/JS.js +29 -17
  39. package/lib/Logger/ConsoleLogger.js +51 -17
  40. package/lib/Logger/index.js +3 -3
  41. package/lib/Logger/logger-interface.js +0 -1
  42. package/lib/OAuthHelper/FacebookOAuth.js +41 -6
  43. package/lib/OAuthHelper/GoogleOAuth.js +41 -6
  44. package/lib/OAuthHelper/index.js +1 -1
  45. package/lib/Platform/index.js +8 -7
  46. package/lib/Platform/version.d.ts +1 -1
  47. package/lib/Platform/version.js +2 -2
  48. package/lib/Providers/AWSCloudWatchProvider.js +104 -44
  49. package/lib/Providers/index.js +2 -2
  50. package/lib/RNComponents/index.js +2 -2
  51. package/lib/RNComponents/reactnative.js +7 -5
  52. package/lib/ServiceWorker/ServiceWorker.js +11 -11
  53. package/lib/ServiceWorker/index.js +2 -2
  54. package/lib/Signer.js +17 -7
  55. package/lib/StorageHelper/index.js +1 -1
  56. package/lib/StorageHelper/reactnative.js +5 -3
  57. package/lib/UniversalStorage/index.d.ts +2 -2
  58. package/lib/UniversalStorage/index.js +24 -6
  59. package/lib/Util/BackgroundProcessManager.js +84 -23
  60. package/lib/Util/Constants.js +1 -1
  61. package/lib/Util/DateUtils.js +18 -3
  62. package/lib/Util/Mutex.js +0 -1
  63. package/lib/Util/Reachability.d.ts +1 -1
  64. package/lib/Util/Reachability.js +18 -6
  65. package/lib/Util/Reachability.native.d.ts +1 -1
  66. package/lib/Util/Reachability.native.js +4 -3
  67. package/lib/Util/Retry.js +103 -26
  68. package/lib/Util/StringUtils.js +1 -1
  69. package/lib/Util/index.js +24 -21
  70. package/lib/clients/endpoints/getDnsSuffix.d.ts +11 -0
  71. package/lib/clients/endpoints/getDnsSuffix.js +49 -0
  72. package/lib/clients/endpoints/index.d.ts +1 -0
  73. package/lib/clients/endpoints/index.js +7 -0
  74. package/lib/clients/endpoints/partitions.d.ts +33 -0
  75. package/lib/clients/endpoints/partitions.js +41 -0
  76. package/lib/clients/handlers/authenticated.d.ts +5 -0
  77. package/lib/clients/handlers/authenticated.js +15 -0
  78. package/lib/clients/handlers/fetch.d.ts +4 -0
  79. package/lib/clients/handlers/fetch.js +123 -0
  80. package/lib/clients/handlers/unauthenticated.d.ts +4 -0
  81. package/lib/clients/handlers/unauthenticated.js +10 -0
  82. package/lib/clients/index.d.ts +8 -0
  83. package/lib/clients/index.js +37 -0
  84. package/lib/clients/internal/composeServiceApi.d.ts +8 -0
  85. package/lib/clients/internal/composeServiceApi.js +75 -0
  86. package/lib/clients/internal/composeTransferHandler.d.ts +29 -0
  87. package/lib/clients/internal/composeTransferHandler.js +26 -0
  88. package/lib/clients/middleware/retry/defaultRetryDecider.d.ts +6 -0
  89. package/lib/clients/middleware/retry/defaultRetryDecider.js +101 -0
  90. package/lib/clients/middleware/retry/index.d.ts +3 -0
  91. package/lib/clients/middleware/retry/index.js +11 -0
  92. package/lib/clients/middleware/retry/jitteredBackoff.d.ts +2 -0
  93. package/lib/clients/middleware/retry/jitteredBackoff.js +16 -0
  94. package/lib/clients/middleware/retry/middleware.d.ts +40 -0
  95. package/lib/clients/middleware/retry/middleware.js +143 -0
  96. package/lib/clients/middleware/signing/index.d.ts +1 -0
  97. package/lib/clients/middleware/signing/index.js +7 -0
  98. package/lib/clients/middleware/signing/middleware.d.ts +13 -0
  99. package/lib/clients/middleware/signing/middleware.js +101 -0
  100. package/lib/clients/middleware/signing/signer/signatureV4/constants.js +1 -1
  101. package/lib/clients/middleware/signing/signer/signatureV4/index.js +4 -4
  102. package/lib/clients/middleware/signing/signer/signatureV4/index.native.js +4 -4
  103. package/lib/clients/middleware/signing/signer/signatureV4/presignUrl.js +46 -8
  104. package/lib/clients/middleware/signing/signer/signatureV4/signRequest.js +22 -11
  105. package/lib/clients/middleware/signing/signer/signatureV4/types/index.js +0 -1
  106. package/lib/clients/middleware/signing/signer/signatureV4/types/signer.js +0 -1
  107. package/lib/clients/middleware/signing/signer/signatureV4/utils/dataHashHelpers.d.ts +3 -2
  108. package/lib/clients/middleware/signing/signer/signatureV4/utils/dataHashHelpers.js +7 -5
  109. package/lib/clients/middleware/signing/signer/signatureV4/utils/getCanonicalHeaders.d.ts +2 -1
  110. package/lib/clients/middleware/signing/signer/signatureV4/utils/getCanonicalHeaders.js +23 -7
  111. package/lib/clients/middleware/signing/signer/signatureV4/utils/getCanonicalQueryString.js +24 -8
  112. package/lib/clients/middleware/signing/signer/signatureV4/utils/getCanonicalRequest.js +8 -7
  113. package/lib/clients/middleware/signing/signer/signatureV4/utils/getCanonicalUri.js +3 -2
  114. package/lib/clients/middleware/signing/signer/signatureV4/utils/getCredentialScope.js +3 -2
  115. package/lib/clients/middleware/signing/signer/signatureV4/utils/getFormattedDates.js +3 -2
  116. package/lib/clients/middleware/signing/signer/signatureV4/utils/getHashedPayload.d.ts +2 -1
  117. package/lib/clients/middleware/signing/signer/signatureV4/utils/getHashedPayload.js +4 -3
  118. package/lib/clients/middleware/signing/signer/signatureV4/utils/getSignature.js +7 -6
  119. package/lib/clients/middleware/signing/signer/signatureV4/utils/getSignedHeaders.d.ts +2 -1
  120. package/lib/clients/middleware/signing/signer/signatureV4/utils/getSignedHeaders.js +3 -2
  121. package/lib/clients/middleware/signing/signer/signatureV4/utils/getSigningKey.js +8 -7
  122. package/lib/clients/middleware/signing/signer/signatureV4/utils/getSigningValues.js +5 -4
  123. package/lib/clients/middleware/signing/signer/signatureV4/utils/getStringToSign.js +3 -2
  124. package/lib/clients/middleware/signing/utils/extendedEncodeURIComponent.d.ts +10 -0
  125. package/lib/clients/middleware/signing/utils/extendedEncodeURIComponent.js +23 -0
  126. package/lib/clients/middleware/signing/utils/getSkewCorrectedDate.d.ts +10 -0
  127. package/lib/clients/middleware/signing/utils/getSkewCorrectedDate.js +18 -0
  128. package/lib/clients/middleware/signing/utils/getUpdatedSystemClockOffset.d.ts +9 -0
  129. package/lib/clients/middleware/signing/utils/getUpdatedSystemClockOffset.js +21 -0
  130. package/lib/clients/middleware/signing/utils/isClockSkewed.d.ts +11 -0
  131. package/lib/clients/middleware/signing/utils/isClockSkewed.js +23 -0
  132. package/lib/clients/middleware/userAgent/index.d.ts +1 -0
  133. package/lib/clients/middleware/userAgent/index.js +7 -0
  134. package/lib/clients/middleware/userAgent/middleware.d.ts +13 -0
  135. package/lib/clients/middleware/userAgent/middleware.js +77 -0
  136. package/lib/clients/serde/index.d.ts +2 -0
  137. package/lib/clients/serde/index.js +10 -0
  138. package/lib/clients/serde/json.d.ts +12 -0
  139. package/lib/clients/serde/json.js +115 -0
  140. package/lib/clients/serde/responseInfo.d.ts +3 -0
  141. package/lib/clients/serde/responseInfo.js +23 -0
  142. package/lib/clients/types/aws.d.ts +18 -1
  143. package/lib/clients/types/aws.js +0 -1
  144. package/lib/clients/types/core.d.ts +22 -0
  145. package/lib/clients/types/core.js +0 -1
  146. package/lib/clients/types/http.d.ts +8 -4
  147. package/lib/clients/types/http.js +0 -1
  148. package/lib/clients/types/index.d.ts +3 -2
  149. package/lib/clients/types/index.js +0 -1
  150. package/lib/clients/utils/isClockSkewError.d.ts +9 -0
  151. package/lib/clients/utils/isClockSkewError.js +27 -0
  152. package/lib/constants.js +1 -1
  153. package/lib/index.js +61 -60
  154. package/lib/parseAWSExports.js +15 -4
  155. package/lib/tsconfig.tsbuildinfo +1 -0
  156. package/lib/types/index.js +15 -1
  157. package/lib/types/types.d.ts +1 -1
  158. package/lib/types/types.js +0 -1
  159. package/lib-esm/Amplify.js +16 -2
  160. package/lib-esm/AwsClients/CognitoIdentity/base.d.ts +28 -0
  161. package/lib-esm/AwsClients/CognitoIdentity/base.js +104 -0
  162. package/lib-esm/AwsClients/CognitoIdentity/getCredentialsForIdentity.d.ts +12 -0
  163. package/lib-esm/AwsClients/CognitoIdentity/getCredentialsForIdentity.js +79 -0
  164. package/lib-esm/AwsClients/CognitoIdentity/getId.d.ts +12 -0
  165. package/lib-esm/AwsClients/CognitoIdentity/getId.js +69 -0
  166. package/lib-esm/AwsClients/CognitoIdentity/index.d.ts +2 -0
  167. package/lib-esm/AwsClients/CognitoIdentity/index.js +4 -0
  168. package/lib-esm/AwsClients/CognitoIdentity/types.d.ts +153 -0
  169. package/lib-esm/AwsClients/CognitoIdentity/types.js +3 -0
  170. package/lib-esm/AwsClients/Pinpoint/base.d.ts +17 -0
  171. package/lib-esm/AwsClients/Pinpoint/base.js +35 -0
  172. package/lib-esm/AwsClients/Pinpoint/getInAppMessages.d.ts +13 -0
  173. package/lib-esm/AwsClients/Pinpoint/getInAppMessages.js +74 -0
  174. package/lib-esm/AwsClients/Pinpoint/index.d.ts +4 -0
  175. package/lib-esm/AwsClients/Pinpoint/index.js +5 -0
  176. package/lib-esm/AwsClients/Pinpoint/putEvents.d.ts +13 -0
  177. package/lib-esm/AwsClients/Pinpoint/putEvents.js +75 -0
  178. package/lib-esm/AwsClients/Pinpoint/types.d.ts +836 -0
  179. package/lib-esm/AwsClients/Pinpoint/types.js +4 -0
  180. package/lib-esm/AwsClients/Pinpoint/updateEndpoint.d.ts +13 -0
  181. package/lib-esm/AwsClients/Pinpoint/updateEndpoint.js +78 -0
  182. package/lib-esm/ClientDevice/android.js +0 -1
  183. package/lib-esm/ClientDevice/browser.js +0 -1
  184. package/lib-esm/ClientDevice/index.js +0 -1
  185. package/lib-esm/ClientDevice/ios.js +0 -1
  186. package/lib-esm/ClientDevice/reactnative.js +0 -1
  187. package/lib-esm/Credentials.js +149 -87
  188. package/lib-esm/Errors.js +0 -1
  189. package/lib-esm/Hub.d.ts +4 -4
  190. package/lib-esm/Hub.js +43 -9
  191. package/lib-esm/I18n/I18n.js +11 -2
  192. package/lib-esm/I18n/index.js +0 -1
  193. package/lib-esm/I18n/types.js +0 -1
  194. package/lib-esm/JS.js +0 -1
  195. package/lib-esm/Logger/ConsoleLogger.js +49 -16
  196. package/lib-esm/Logger/index.js +0 -1
  197. package/lib-esm/Logger/logger-interface.js +1 -1
  198. package/lib-esm/OAuthHelper/FacebookOAuth.js +36 -2
  199. package/lib-esm/OAuthHelper/GoogleOAuth.js +36 -2
  200. package/lib-esm/OAuthHelper/index.js +0 -1
  201. package/lib-esm/Platform/index.js +5 -6
  202. package/lib-esm/Platform/version.d.ts +1 -1
  203. package/lib-esm/Platform/version.js +1 -2
  204. package/lib-esm/Providers/AWSCloudWatchProvider.js +75 -16
  205. package/lib-esm/Providers/index.js +0 -1
  206. package/lib-esm/RNComponents/index.js +0 -1
  207. package/lib-esm/RNComponents/reactnative.js +0 -1
  208. package/lib-esm/ServiceWorker/ServiceWorker.js +9 -10
  209. package/lib-esm/ServiceWorker/index.js +0 -1
  210. package/lib-esm/Signer.js +11 -2
  211. package/lib-esm/StorageHelper/index.js +0 -1
  212. package/lib-esm/StorageHelper/reactnative.js +0 -1
  213. package/lib-esm/UniversalStorage/index.d.ts +2 -2
  214. package/lib-esm/UniversalStorage/index.js +17 -3
  215. package/lib-esm/Util/BackgroundProcessManager.js +74 -14
  216. package/lib-esm/Util/Constants.js +0 -1
  217. package/lib-esm/Util/DateUtils.js +16 -2
  218. package/lib-esm/Util/Mutex.js +0 -1
  219. package/lib-esm/Util/Reachability.d.ts +1 -1
  220. package/lib-esm/Util/Reachability.js +11 -2
  221. package/lib-esm/Util/Reachability.native.d.ts +1 -1
  222. package/lib-esm/Util/Reachability.native.js +0 -1
  223. package/lib-esm/Util/Retry.js +92 -18
  224. package/lib-esm/Util/StringUtils.js +0 -1
  225. package/lib-esm/Util/index.js +0 -1
  226. package/lib-esm/clients/endpoints/getDnsSuffix.d.ts +11 -0
  227. package/lib-esm/clients/endpoints/getDnsSuffix.js +45 -0
  228. package/lib-esm/clients/endpoints/index.d.ts +1 -0
  229. package/lib-esm/clients/endpoints/index.js +3 -0
  230. package/lib-esm/clients/endpoints/partitions.d.ts +33 -0
  231. package/lib-esm/clients/endpoints/partitions.js +38 -0
  232. package/lib-esm/clients/handlers/authenticated.d.ts +5 -0
  233. package/lib-esm/clients/handlers/authenticated.js +12 -0
  234. package/lib-esm/clients/handlers/fetch.d.ts +4 -0
  235. package/lib-esm/clients/handlers/fetch.js +119 -0
  236. package/lib-esm/clients/handlers/unauthenticated.d.ts +4 -0
  237. package/lib-esm/clients/handlers/unauthenticated.js +7 -0
  238. package/lib-esm/clients/index.d.ts +8 -0
  239. package/lib-esm/clients/index.js +10 -0
  240. package/lib-esm/clients/internal/composeServiceApi.d.ts +8 -0
  241. package/lib-esm/clients/internal/composeServiceApi.js +71 -0
  242. package/lib-esm/clients/internal/composeTransferHandler.d.ts +29 -0
  243. package/lib-esm/clients/internal/composeTransferHandler.js +22 -0
  244. package/lib-esm/clients/middleware/retry/defaultRetryDecider.d.ts +6 -0
  245. package/lib-esm/clients/middleware/retry/defaultRetryDecider.js +97 -0
  246. package/lib-esm/clients/middleware/retry/index.d.ts +3 -0
  247. package/lib-esm/clients/middleware/retry/index.js +5 -0
  248. package/lib-esm/clients/middleware/retry/jitteredBackoff.d.ts +2 -0
  249. package/lib-esm/clients/middleware/retry/jitteredBackoff.js +12 -0
  250. package/lib-esm/clients/middleware/retry/middleware.d.ts +40 -0
  251. package/lib-esm/clients/middleware/retry/middleware.js +138 -0
  252. package/lib-esm/clients/middleware/signing/index.d.ts +1 -0
  253. package/lib-esm/clients/middleware/signing/index.js +3 -0
  254. package/lib-esm/clients/middleware/signing/middleware.d.ts +13 -0
  255. package/lib-esm/clients/middleware/signing/middleware.js +97 -0
  256. package/lib-esm/clients/middleware/signing/signer/signatureV4/constants.js +0 -1
  257. package/lib-esm/clients/middleware/signing/signer/signatureV4/index.js +0 -1
  258. package/lib-esm/clients/middleware/signing/signer/signatureV4/index.native.js +0 -1
  259. package/lib-esm/clients/middleware/signing/signer/signatureV4/presignUrl.js +39 -3
  260. package/lib-esm/clients/middleware/signing/signer/signatureV4/signRequest.js +15 -6
  261. package/lib-esm/clients/middleware/signing/signer/signatureV4/types/index.js +1 -1
  262. package/lib-esm/clients/middleware/signing/signer/signatureV4/types/signer.js +1 -1
  263. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/dataHashHelpers.d.ts +3 -2
  264. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/dataHashHelpers.js +0 -1
  265. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getCanonicalHeaders.d.ts +2 -1
  266. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getCanonicalHeaders.js +20 -6
  267. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getCanonicalQueryString.js +18 -4
  268. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getCanonicalRequest.js +0 -1
  269. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getCanonicalUri.js +0 -1
  270. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getCredentialScope.js +1 -2
  271. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getFormattedDates.js +0 -1
  272. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getHashedPayload.d.ts +2 -1
  273. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getHashedPayload.js +0 -1
  274. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getSignature.js +0 -1
  275. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getSignedHeaders.d.ts +2 -1
  276. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getSignedHeaders.js +0 -1
  277. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getSigningKey.js +1 -2
  278. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getSigningValues.js +0 -1
  279. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getStringToSign.js +0 -1
  280. package/lib-esm/clients/middleware/signing/utils/extendedEncodeURIComponent.d.ts +10 -0
  281. package/lib-esm/clients/middleware/signing/utils/extendedEncodeURIComponent.js +19 -0
  282. package/lib-esm/clients/middleware/signing/utils/getSkewCorrectedDate.d.ts +10 -0
  283. package/lib-esm/clients/middleware/signing/utils/getSkewCorrectedDate.js +14 -0
  284. package/lib-esm/clients/middleware/signing/utils/getUpdatedSystemClockOffset.d.ts +9 -0
  285. package/lib-esm/clients/middleware/signing/utils/getUpdatedSystemClockOffset.js +17 -0
  286. package/lib-esm/clients/middleware/signing/utils/isClockSkewed.d.ts +11 -0
  287. package/lib-esm/clients/middleware/signing/utils/isClockSkewed.js +19 -0
  288. package/lib-esm/clients/middleware/userAgent/index.d.ts +1 -0
  289. package/lib-esm/clients/middleware/userAgent/index.js +3 -0
  290. package/lib-esm/clients/middleware/userAgent/middleware.d.ts +13 -0
  291. package/lib-esm/clients/middleware/userAgent/middleware.js +73 -0
  292. package/lib-esm/clients/serde/index.d.ts +2 -0
  293. package/lib-esm/clients/serde/index.js +4 -0
  294. package/lib-esm/clients/serde/json.d.ts +12 -0
  295. package/lib-esm/clients/serde/json.js +110 -0
  296. package/lib-esm/clients/serde/responseInfo.d.ts +3 -0
  297. package/lib-esm/clients/serde/responseInfo.js +19 -0
  298. package/lib-esm/clients/types/aws.d.ts +18 -1
  299. package/lib-esm/clients/types/aws.js +1 -1
  300. package/lib-esm/clients/types/core.d.ts +22 -0
  301. package/lib-esm/clients/types/core.js +1 -1
  302. package/lib-esm/clients/types/http.d.ts +8 -4
  303. package/lib-esm/clients/types/http.js +1 -1
  304. package/lib-esm/clients/types/index.d.ts +3 -2
  305. package/lib-esm/clients/types/index.js +1 -1
  306. package/lib-esm/clients/utils/isClockSkewError.d.ts +9 -0
  307. package/lib-esm/clients/utils/isClockSkewError.js +23 -0
  308. package/lib-esm/constants.js +0 -1
  309. package/lib-esm/index.js +0 -1
  310. package/lib-esm/parseAWSExports.js +11 -2
  311. package/lib-esm/tsconfig.tsbuildinfo +1 -0
  312. package/lib-esm/types/index.js +1 -1
  313. package/lib-esm/types/types.d.ts +1 -1
  314. package/lib-esm/types/types.js +1 -1
  315. package/package.json +56 -22
  316. package/src/AwsClients/CognitoIdentity/base.ts +88 -0
  317. package/src/AwsClients/CognitoIdentity/getCredentialsForIdentity.ts +67 -0
  318. package/src/AwsClients/CognitoIdentity/getId.ts +58 -0
  319. package/src/AwsClients/CognitoIdentity/index.ts +9 -0
  320. package/src/AwsClients/CognitoIdentity/types.ts +159 -0
  321. package/src/AwsClients/Pinpoint/base.ts +41 -0
  322. package/src/AwsClients/Pinpoint/getInAppMessages.ts +56 -0
  323. package/src/AwsClients/Pinpoint/index.ts +15 -0
  324. package/src/AwsClients/Pinpoint/putEvents.ts +55 -0
  325. package/src/AwsClients/Pinpoint/types.ts +844 -0
  326. package/src/AwsClients/Pinpoint/updateEndpoint.ts +60 -0
  327. package/src/Credentials.ts +75 -100
  328. package/src/OAuthHelper/FacebookOAuth.ts +1 -1
  329. package/src/OAuthHelper/GoogleOAuth.ts +1 -1
  330. package/src/Platform/version.ts +1 -1
  331. package/src/StorageHelper/reactnative.ts +1 -1
  332. package/src/clients/endpoints/getDnsSuffix.ts +25 -0
  333. package/src/clients/endpoints/index.ts +4 -0
  334. package/src/clients/endpoints/partitions.ts +40 -0
  335. package/src/clients/handlers/authenticated.ts +19 -0
  336. package/src/clients/handlers/fetch.ts +75 -0
  337. package/src/clients/handlers/unauthenticated.ts +14 -0
  338. package/src/clients/index.ts +15 -0
  339. package/src/clients/internal/composeServiceApi.ts +50 -0
  340. package/src/clients/internal/composeTransferHandler.ts +89 -0
  341. package/src/clients/middleware/retry/defaultRetryDecider.ts +54 -0
  342. package/src/clients/middleware/retry/index.ts +6 -0
  343. package/src/clients/middleware/retry/jitteredBackoff.ts +16 -0
  344. package/src/clients/middleware/retry/middleware.ts +133 -0
  345. package/src/clients/middleware/signing/index.ts +4 -0
  346. package/src/clients/middleware/signing/middleware.ts +65 -0
  347. package/src/clients/middleware/signing/utils/extendedEncodeURIComponent.ts +21 -0
  348. package/src/clients/middleware/signing/utils/getSkewCorrectedDate.ts +14 -0
  349. package/src/clients/middleware/signing/utils/getUpdatedSystemClockOffset.ts +22 -0
  350. package/src/clients/middleware/signing/utils/isClockSkewed.ts +26 -0
  351. package/src/clients/middleware/userAgent/index.ts +4 -0
  352. package/src/clients/middleware/userAgent/middleware.ts +41 -0
  353. package/src/clients/serde/index.ts +5 -0
  354. package/src/clients/serde/json.ts +51 -0
  355. package/src/clients/serde/responseInfo.ts +20 -0
  356. package/src/clients/types/aws.ts +21 -0
  357. package/src/clients/types/core.ts +40 -0
  358. package/src/clients/types/http.ts +12 -2
  359. package/src/clients/types/index.ts +22 -2
  360. package/src/clients/utils/isClockSkewError.ts +24 -0
  361. package/lib/.tsbuildinfo +0 -3
  362. package/lib/Amplify.js.map +0 -1
  363. package/lib/ClientDevice/android.js.map +0 -1
  364. package/lib/ClientDevice/browser.js.map +0 -1
  365. package/lib/ClientDevice/index.js.map +0 -1
  366. package/lib/ClientDevice/ios.js.map +0 -1
  367. package/lib/ClientDevice/reactnative.js.map +0 -1
  368. package/lib/Credentials.js.map +0 -1
  369. package/lib/Errors.js.map +0 -1
  370. package/lib/Hub.js.map +0 -1
  371. package/lib/I18n/I18n.js.map +0 -1
  372. package/lib/I18n/index.js.map +0 -1
  373. package/lib/I18n/types.js.map +0 -1
  374. package/lib/JS.js.map +0 -1
  375. package/lib/Logger/ConsoleLogger.js.map +0 -1
  376. package/lib/Logger/index.js.map +0 -1
  377. package/lib/Logger/logger-interface.js.map +0 -1
  378. package/lib/OAuthHelper/FacebookOAuth.js.map +0 -1
  379. package/lib/OAuthHelper/GoogleOAuth.js.map +0 -1
  380. package/lib/OAuthHelper/index.js.map +0 -1
  381. package/lib/Platform/index.js.map +0 -1
  382. package/lib/Platform/version.js.map +0 -1
  383. package/lib/Providers/AWSCloudWatchProvider.js.map +0 -1
  384. package/lib/Providers/index.js.map +0 -1
  385. package/lib/RNComponents/index.js.map +0 -1
  386. package/lib/RNComponents/reactnative.js.map +0 -1
  387. package/lib/ServiceWorker/ServiceWorker.js.map +0 -1
  388. package/lib/ServiceWorker/index.js.map +0 -1
  389. package/lib/Signer.js.map +0 -1
  390. package/lib/StorageHelper/index.js.map +0 -1
  391. package/lib/StorageHelper/reactnative.js.map +0 -1
  392. package/lib/UniversalStorage/index.js.map +0 -1
  393. package/lib/Util/BackgroundProcessManager.js.map +0 -1
  394. package/lib/Util/CognitoIdentityClient.d.ts +0 -14
  395. package/lib/Util/CognitoIdentityClient.js +0 -31
  396. package/lib/Util/CognitoIdentityClient.js.map +0 -1
  397. package/lib/Util/Constants.js.map +0 -1
  398. package/lib/Util/DateUtils.js.map +0 -1
  399. package/lib/Util/Mutex.js.map +0 -1
  400. package/lib/Util/Reachability.js.map +0 -1
  401. package/lib/Util/Reachability.native.js.map +0 -1
  402. package/lib/Util/Retry.js.map +0 -1
  403. package/lib/Util/StringUtils.js.map +0 -1
  404. package/lib/Util/index.js.map +0 -1
  405. package/lib/clients/middleware/signing/signer/signatureV4/constants.js.map +0 -1
  406. package/lib/clients/middleware/signing/signer/signatureV4/index.js.map +0 -1
  407. package/lib/clients/middleware/signing/signer/signatureV4/index.native.js.map +0 -1
  408. package/lib/clients/middleware/signing/signer/signatureV4/presignUrl.js.map +0 -1
  409. package/lib/clients/middleware/signing/signer/signatureV4/signRequest.js.map +0 -1
  410. package/lib/clients/middleware/signing/signer/signatureV4/types/index.js.map +0 -1
  411. package/lib/clients/middleware/signing/signer/signatureV4/types/signer.js.map +0 -1
  412. package/lib/clients/middleware/signing/signer/signatureV4/utils/dataHashHelpers.js.map +0 -1
  413. package/lib/clients/middleware/signing/signer/signatureV4/utils/getCanonicalHeaders.js.map +0 -1
  414. package/lib/clients/middleware/signing/signer/signatureV4/utils/getCanonicalQueryString.js.map +0 -1
  415. package/lib/clients/middleware/signing/signer/signatureV4/utils/getCanonicalRequest.js.map +0 -1
  416. package/lib/clients/middleware/signing/signer/signatureV4/utils/getCanonicalUri.js.map +0 -1
  417. package/lib/clients/middleware/signing/signer/signatureV4/utils/getCredentialScope.js.map +0 -1
  418. package/lib/clients/middleware/signing/signer/signatureV4/utils/getFormattedDates.js.map +0 -1
  419. package/lib/clients/middleware/signing/signer/signatureV4/utils/getHashedPayload.js.map +0 -1
  420. package/lib/clients/middleware/signing/signer/signatureV4/utils/getSignature.js.map +0 -1
  421. package/lib/clients/middleware/signing/signer/signatureV4/utils/getSignedHeaders.js.map +0 -1
  422. package/lib/clients/middleware/signing/signer/signatureV4/utils/getSigningKey.js.map +0 -1
  423. package/lib/clients/middleware/signing/signer/signatureV4/utils/getSigningValues.js.map +0 -1
  424. package/lib/clients/middleware/signing/signer/signatureV4/utils/getStringToSign.js.map +0 -1
  425. package/lib/clients/types/aws.js.map +0 -1
  426. package/lib/clients/types/core.js.map +0 -1
  427. package/lib/clients/types/http.js.map +0 -1
  428. package/lib/clients/types/index.js.map +0 -1
  429. package/lib/constants.js.map +0 -1
  430. package/lib/index.js.map +0 -1
  431. package/lib/parseAWSExports.js.map +0 -1
  432. package/lib/types/index.js.map +0 -1
  433. package/lib/types/types.js.map +0 -1
  434. package/lib-esm/.tsbuildinfo +0 -3
  435. package/lib-esm/Amplify.js.map +0 -1
  436. package/lib-esm/ClientDevice/android.js.map +0 -1
  437. package/lib-esm/ClientDevice/browser.js.map +0 -1
  438. package/lib-esm/ClientDevice/index.js.map +0 -1
  439. package/lib-esm/ClientDevice/ios.js.map +0 -1
  440. package/lib-esm/ClientDevice/reactnative.js.map +0 -1
  441. package/lib-esm/Credentials.js.map +0 -1
  442. package/lib-esm/Errors.js.map +0 -1
  443. package/lib-esm/Hub.js.map +0 -1
  444. package/lib-esm/I18n/I18n.js.map +0 -1
  445. package/lib-esm/I18n/index.js.map +0 -1
  446. package/lib-esm/I18n/types.js.map +0 -1
  447. package/lib-esm/JS.js.map +0 -1
  448. package/lib-esm/Logger/ConsoleLogger.js.map +0 -1
  449. package/lib-esm/Logger/index.js.map +0 -1
  450. package/lib-esm/Logger/logger-interface.js.map +0 -1
  451. package/lib-esm/OAuthHelper/FacebookOAuth.js.map +0 -1
  452. package/lib-esm/OAuthHelper/GoogleOAuth.js.map +0 -1
  453. package/lib-esm/OAuthHelper/index.js.map +0 -1
  454. package/lib-esm/Platform/index.js.map +0 -1
  455. package/lib-esm/Platform/version.js.map +0 -1
  456. package/lib-esm/Providers/AWSCloudWatchProvider.js.map +0 -1
  457. package/lib-esm/Providers/index.js.map +0 -1
  458. package/lib-esm/RNComponents/index.js.map +0 -1
  459. package/lib-esm/RNComponents/reactnative.js.map +0 -1
  460. package/lib-esm/ServiceWorker/ServiceWorker.js.map +0 -1
  461. package/lib-esm/ServiceWorker/index.js.map +0 -1
  462. package/lib-esm/Signer.js.map +0 -1
  463. package/lib-esm/StorageHelper/index.js.map +0 -1
  464. package/lib-esm/StorageHelper/reactnative.js.map +0 -1
  465. package/lib-esm/UniversalStorage/index.js.map +0 -1
  466. package/lib-esm/Util/BackgroundProcessManager.js.map +0 -1
  467. package/lib-esm/Util/CognitoIdentityClient.d.ts +0 -14
  468. package/lib-esm/Util/CognitoIdentityClient.js +0 -27
  469. package/lib-esm/Util/CognitoIdentityClient.js.map +0 -1
  470. package/lib-esm/Util/Constants.js.map +0 -1
  471. package/lib-esm/Util/DateUtils.js.map +0 -1
  472. package/lib-esm/Util/Mutex.js.map +0 -1
  473. package/lib-esm/Util/Reachability.js.map +0 -1
  474. package/lib-esm/Util/Reachability.native.js.map +0 -1
  475. package/lib-esm/Util/Retry.js.map +0 -1
  476. package/lib-esm/Util/StringUtils.js.map +0 -1
  477. package/lib-esm/Util/index.js.map +0 -1
  478. package/lib-esm/clients/middleware/signing/signer/signatureV4/constants.js.map +0 -1
  479. package/lib-esm/clients/middleware/signing/signer/signatureV4/index.js.map +0 -1
  480. package/lib-esm/clients/middleware/signing/signer/signatureV4/index.native.js.map +0 -1
  481. package/lib-esm/clients/middleware/signing/signer/signatureV4/presignUrl.js.map +0 -1
  482. package/lib-esm/clients/middleware/signing/signer/signatureV4/signRequest.js.map +0 -1
  483. package/lib-esm/clients/middleware/signing/signer/signatureV4/types/index.js.map +0 -1
  484. package/lib-esm/clients/middleware/signing/signer/signatureV4/types/signer.js.map +0 -1
  485. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/dataHashHelpers.js.map +0 -1
  486. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getCanonicalHeaders.js.map +0 -1
  487. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getCanonicalQueryString.js.map +0 -1
  488. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getCanonicalRequest.js.map +0 -1
  489. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getCanonicalUri.js.map +0 -1
  490. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getCredentialScope.js.map +0 -1
  491. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getFormattedDates.js.map +0 -1
  492. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getHashedPayload.js.map +0 -1
  493. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getSignature.js.map +0 -1
  494. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getSignedHeaders.js.map +0 -1
  495. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getSigningKey.js.map +0 -1
  496. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getSigningValues.js.map +0 -1
  497. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getStringToSign.js.map +0 -1
  498. package/lib-esm/clients/types/aws.js.map +0 -1
  499. package/lib-esm/clients/types/core.js.map +0 -1
  500. package/lib-esm/clients/types/http.js.map +0 -1
  501. package/lib-esm/clients/types/index.js.map +0 -1
  502. package/lib-esm/constants.js.map +0 -1
  503. package/lib-esm/index.js.map +0 -1
  504. package/lib-esm/parseAWSExports.js.map +0 -1
  505. package/lib-esm/types/index.js.map +0 -1
  506. package/lib-esm/types/types.js.map +0 -1
  507. package/src/Util/CognitoIdentityClient.ts +0 -48
@@ -1,9 +1,23 @@
1
1
  "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ var __importDefault = (this && this.__importDefault) || function (mod) {
14
+ return (mod && mod.__esModule) ? mod : { "default": mod };
15
+ };
2
16
  Object.defineProperty(exports, "__esModule", { value: true });
3
- var tslib_1 = require("tslib");
4
- var universal_cookie_1 = tslib_1.__importDefault(require("universal-cookie"));
17
+ exports.UniversalStorage = void 0;
18
+ var universal_cookie_1 = __importDefault(require("universal-cookie"));
5
19
  var JS_1 = require("../JS");
6
- var isBrowser = JS_1.browserOrNode().isBrowser;
20
+ var isBrowser = (0, JS_1.browserOrNode)().isBrowser;
7
21
  var ONE_YEAR_IN_MS = 365 * 24 * 60 * 60 * 1000;
8
22
  var UniversalStorage = /** @class */ (function () {
9
23
  function UniversalStorage(context) {
@@ -19,7 +33,7 @@ var UniversalStorage = /** @class */ (function () {
19
33
  get: function () {
20
34
  return Object.entries(this.store).length;
21
35
  },
22
- enumerable: true,
36
+ enumerable: false,
23
37
  configurable: true
24
38
  });
25
39
  UniversalStorage.prototype.clear = function () {
@@ -68,6 +82,11 @@ var UniversalStorage = /** @class */ (function () {
68
82
  'refreshToken',
69
83
  // Required for CognitoUserSession
70
84
  'idToken',
85
+ // userData is used when `Auth.currentAuthenticatedUser({ bypassCache: false })`.
86
+ // Can be persisted to speed up calls to `Auth.currentAuthenticatedUser()`
87
+ // 'userData',
88
+ // Ignoring clockDrift on the server for now, but needs testing
89
+ // 'clockDrift',
71
90
  ];
72
91
  if (sessionTokenTypes.includes(tokenType !== null && tokenType !== void 0 ? tokenType : '')) {
73
92
  this.setUniversalItem(key, value, {
@@ -80,7 +99,7 @@ var UniversalStorage = /** @class */ (function () {
80
99
  };
81
100
  UniversalStorage.prototype.setUniversalItem = function (key, value, options) {
82
101
  if (options === void 0) { options = {}; }
83
- this.cookies.set(key, value, tslib_1.__assign(tslib_1.__assign({}, options), { path: '/',
102
+ this.cookies.set(key, value, __assign(__assign({}, options), { path: '/',
84
103
  // `httpOnly` cannot be set via JavaScript: https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies#JavaScript_access_using_Document.cookie
85
104
  sameSite: true,
86
105
  // Allow unsecure requests to http://localhost:3000/ when in development.
@@ -89,4 +108,3 @@ var UniversalStorage = /** @class */ (function () {
89
108
  return UniversalStorage;
90
109
  }());
91
110
  exports.UniversalStorage = UniversalStorage;
92
- //# sourceMappingURL=index.js.map
@@ -1,6 +1,68 @@
1
1
  "use strict";
2
+ var __extends = (this && this.__extends) || (function () {
3
+ var extendStatics = function (d, b) {
4
+ extendStatics = Object.setPrototypeOf ||
5
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
6
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
7
+ return extendStatics(d, b);
8
+ };
9
+ return function (d, b) {
10
+ if (typeof b !== "function" && b !== null)
11
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
12
+ extendStatics(d, b);
13
+ function __() { this.constructor = d; }
14
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
15
+ };
16
+ })();
17
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
18
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
19
+ return new (P || (P = Promise))(function (resolve, reject) {
20
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
21
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
22
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
23
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
24
+ });
25
+ };
26
+ var __generator = (this && this.__generator) || function (thisArg, body) {
27
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
28
+ return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
29
+ function verb(n) { return function (v) { return step([n, v]); }; }
30
+ function step(op) {
31
+ if (f) throw new TypeError("Generator is already executing.");
32
+ while (g && (g = 0, op[0] && (_ = 0)), _) try {
33
+ if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
34
+ if (y = 0, t) op = [op[0] & 2, t.value];
35
+ switch (op[0]) {
36
+ case 0: case 1: t = op; break;
37
+ case 4: _.label++; return { value: op[1], done: false };
38
+ case 5: _.label++; y = op[1]; op = [0]; continue;
39
+ case 7: op = _.ops.pop(); _.trys.pop(); continue;
40
+ default:
41
+ if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
42
+ if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
43
+ if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
44
+ if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
45
+ if (t[2]) _.ops.pop();
46
+ _.trys.pop(); continue;
47
+ }
48
+ op = body.call(thisArg, _);
49
+ } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
50
+ if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
51
+ }
52
+ };
53
+ var __values = (this && this.__values) || function(o) {
54
+ var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
55
+ if (m) return m.call(o);
56
+ if (o && typeof o.length === "number") return {
57
+ next: function () {
58
+ if (o && i >= o.length) o = void 0;
59
+ return { value: o && o[i++], done: !o };
60
+ }
61
+ };
62
+ throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
63
+ };
2
64
  Object.defineProperty(exports, "__esModule", { value: true });
3
- var tslib_1 = require("tslib");
65
+ exports.BackgroundProcessManagerState = exports.BackgroundManagerNotOpenError = exports.BackgroundProcessManager = void 0;
4
66
  /**
5
67
  * @private For internal Amplify use.
6
68
  *
@@ -69,8 +131,8 @@ var BackgroundProcessManager = /** @class */ (function () {
69
131
  BackgroundProcessManager.prototype.addCleaner = function (clean, description) {
70
132
  var _this = this;
71
133
  var _a = this.addHook(description), resolve = _a.resolve, onTerminate = _a.onTerminate;
72
- var proxy = function () { return tslib_1.__awaiter(_this, void 0, void 0, function () {
73
- return tslib_1.__generator(this, function (_a) {
134
+ var proxy = function () { return __awaiter(_this, void 0, void 0, function () {
135
+ return __generator(this, function (_a) {
74
136
  switch (_a.label) {
75
137
  case 0: return [4 /*yield*/, clean()];
76
138
  case 1:
@@ -104,7 +166,7 @@ var BackgroundProcessManager = /** @class */ (function () {
104
166
  };
105
167
  BackgroundProcessManager.prototype.addManager = function (manager, description) {
106
168
  var _this = this;
107
- this.addCleaner(function () { return tslib_1.__awaiter(_this, void 0, void 0, function () { return tslib_1.__generator(this, function (_a) {
169
+ this.addCleaner(function () { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
108
170
  switch (_a.label) {
109
171
  case 0: return [4 /*yield*/, manager.close()];
110
172
  case 1: return [2 /*return*/, _a.sent()];
@@ -190,7 +252,7 @@ var BackgroundProcessManager = /** @class */ (function () {
190
252
  get: function () {
191
253
  return this.jobs.size;
192
254
  },
193
- enumerable: true,
255
+ enumerable: false,
194
256
  configurable: true
195
257
  });
196
258
  Object.defineProperty(BackgroundProcessManager.prototype, "state", {
@@ -204,7 +266,7 @@ var BackgroundProcessManager = /** @class */ (function () {
204
266
  get: function () {
205
267
  return this._state;
206
268
  },
207
- enumerable: true,
269
+ enumerable: false,
208
270
  configurable: true
209
271
  });
210
272
  Object.defineProperty(BackgroundProcessManager.prototype, "pending", {
@@ -216,7 +278,7 @@ var BackgroundProcessManager = /** @class */ (function () {
216
278
  get: function () {
217
279
  return Array.from(this.jobs).map(function (job) { return job.description; });
218
280
  },
219
- enumerable: true,
281
+ enumerable: false,
220
282
  configurable: true
221
283
  });
222
284
  Object.defineProperty(BackgroundProcessManager.prototype, "isOpen", {
@@ -226,7 +288,7 @@ var BackgroundProcessManager = /** @class */ (function () {
226
288
  get: function () {
227
289
  return this._state === BackgroundProcessManagerState.Open;
228
290
  },
229
- enumerable: true,
291
+ enumerable: false,
230
292
  configurable: true
231
293
  });
232
294
  Object.defineProperty(BackgroundProcessManager.prototype, "isClosing", {
@@ -237,7 +299,7 @@ var BackgroundProcessManager = /** @class */ (function () {
237
299
  get: function () {
238
300
  return this._state === BackgroundProcessManagerState.Closing;
239
301
  },
240
- enumerable: true,
302
+ enumerable: false,
241
303
  configurable: true
242
304
  });
243
305
  Object.defineProperty(BackgroundProcessManager.prototype, "isClosed", {
@@ -248,17 +310,17 @@ var BackgroundProcessManager = /** @class */ (function () {
248
310
  get: function () {
249
311
  return this._state === BackgroundProcessManagerState.Closed;
250
312
  },
251
- enumerable: true,
313
+ enumerable: false,
252
314
  configurable: true
253
315
  });
254
316
  BackgroundProcessManager.prototype.closedFailure = function (description) {
255
317
  if (!this.isOpen) {
256
318
  return Promise.reject(new BackgroundManagerNotOpenError([
257
- "The manager is " + this.state + ".",
258
- "You tried to add \"" + description + "\".",
259
- "Pending jobs: [\n" + this.pending
319
+ "The manager is ".concat(this.state, "."),
320
+ "You tried to add \"".concat(description, "\"."),
321
+ "Pending jobs: [\n".concat(this.pending
260
322
  .map(function (t) { return ' ' + t; })
261
- .join(',\n') + "\n]",
323
+ .join(',\n'), "\n]"),
262
324
  ].join('\n')));
263
325
  }
264
326
  };
@@ -280,16 +342,16 @@ var BackgroundProcessManager = /** @class */ (function () {
280
342
  * manager's `close()` was called in an `Open` state.
281
343
  */
282
344
  BackgroundProcessManager.prototype.close = function () {
283
- return tslib_1.__awaiter(this, void 0, void 0, function () {
345
+ return __awaiter(this, void 0, void 0, function () {
284
346
  var _a, _b, job;
285
347
  var e_1, _c;
286
- return tslib_1.__generator(this, function (_d) {
348
+ return __generator(this, function (_d) {
287
349
  switch (_d.label) {
288
350
  case 0:
289
351
  if (!this.isOpen) return [3 /*break*/, 2];
290
352
  this._state = BackgroundProcessManagerState.Closing;
291
353
  try {
292
- for (_a = tslib_1.__values(Array.from(this.jobs)), _b = _a.next(); !_b.done; _b = _a.next()) {
354
+ for (_a = __values(Array.from(this.jobs)), _b = _a.next(); !_b.done; _b = _a.next()) {
293
355
  job = _b.value;
294
356
  try {
295
357
  job.terminate();
@@ -298,7 +360,7 @@ var BackgroundProcessManager = /** @class */ (function () {
298
360
  // Due to potential races with a job's natural completion, it's
299
361
  // reasonable to expect the termination call to fail. Hence,
300
362
  // not logging as an error.
301
- console.warn("Failed to send termination signal to job. Error: " + error.message, job);
363
+ console.warn("Failed to send termination signal to job. Error: ".concat(error.message), job);
302
364
  }
303
365
  }
304
366
  }
@@ -334,8 +396,8 @@ var BackgroundProcessManager = /** @class */ (function () {
334
396
  * updates the state and returns.
335
397
  */
336
398
  BackgroundProcessManager.prototype.open = function () {
337
- return tslib_1.__awaiter(this, void 0, void 0, function () {
338
- return tslib_1.__generator(this, function (_a) {
399
+ return __awaiter(this, void 0, void 0, function () {
400
+ return __generator(this, function (_a) {
339
401
  switch (_a.label) {
340
402
  case 0:
341
403
  if (!this.isClosing) return [3 /*break*/, 2];
@@ -357,9 +419,9 @@ exports.BackgroundProcessManager = BackgroundProcessManager;
357
419
  *
358
420
  */
359
421
  var BackgroundManagerNotOpenError = /** @class */ (function (_super) {
360
- tslib_1.__extends(BackgroundManagerNotOpenError, _super);
422
+ __extends(BackgroundManagerNotOpenError, _super);
361
423
  function BackgroundManagerNotOpenError(message) {
362
- return _super.call(this, "BackgroundManagerNotOpenError: " + message) || this;
424
+ return _super.call(this, "BackgroundManagerNotOpenError: ".concat(message)) || this;
363
425
  }
364
426
  return BackgroundManagerNotOpenError;
365
427
  }(Error));
@@ -382,4 +444,3 @@ var BackgroundProcessManagerState;
382
444
  */
383
445
  BackgroundProcessManagerState["Closed"] = "Closed";
384
446
  })(BackgroundProcessManagerState = exports.BackgroundProcessManagerState || (exports.BackgroundProcessManagerState = {}));
385
- //# sourceMappingURL=BackgroundProcessManager.js.map
@@ -2,6 +2,7 @@
2
2
  // Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
3
  // SPDX-License-Identifier: Apache-2.0
4
4
  Object.defineProperty(exports, "__esModule", { value: true });
5
+ exports.RETRY_ERROR_CODES = exports.NO_CREDS_ERROR_STRING = exports.AWS_CLOUDWATCH_PROVIDER_NAME = exports.AWS_CLOUDWATCH_MAX_EVENT_SIZE = exports.AWS_CLOUDWATCH_MAX_BATCH_EVENT_SIZE = exports.AWS_CLOUDWATCH_CATEGORY = exports.AWS_CLOUDWATCH_BASE_BUFFER_SIZE = void 0;
5
6
  // Logging constants
6
7
  var AWS_CLOUDWATCH_BASE_BUFFER_SIZE = 26;
7
8
  exports.AWS_CLOUDWATCH_BASE_BUFFER_SIZE = AWS_CLOUDWATCH_BASE_BUFFER_SIZE;
@@ -20,4 +21,3 @@ var RETRY_ERROR_CODES = [
20
21
  'InvalidSequenceTokenException',
21
22
  ];
22
23
  exports.RETRY_ERROR_CODES = RETRY_ERROR_CODES;
23
- //# sourceMappingURL=Constants.js.map
@@ -5,8 +5,24 @@
5
5
  *
6
6
  * @see https://github.com/aws/aws-sdk-js/blob/6edf586dcc1de7fe8fbfbbd9a0d2b1847921e6e1/lib/util.js#L262
7
7
  */
8
+ var __read = (this && this.__read) || function (o, n) {
9
+ var m = typeof Symbol === "function" && o[Symbol.iterator];
10
+ if (!m) return o;
11
+ var i = m.call(o), r, ar = [], e;
12
+ try {
13
+ while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
14
+ }
15
+ catch (error) { e = { error: error }; }
16
+ finally {
17
+ try {
18
+ if (r && !r.done && (m = i["return"])) m.call(i);
19
+ }
20
+ finally { if (e) throw e.error; }
21
+ }
22
+ return ar;
23
+ };
8
24
  Object.defineProperty(exports, "__esModule", { value: true });
9
- var tslib_1 = require("tslib");
25
+ exports.DateUtils = void 0;
10
26
  // Comment - TODO: remove
11
27
  var FIVE_MINUTES_IN_MS = 1000 * 60 * 5;
12
28
  exports.DateUtils = {
@@ -33,7 +49,7 @@ exports.DateUtils = {
33
49
  return date.toISOString().replace(/[:\-]|\.\d{3}/g, '');
34
50
  },
35
51
  getDateFromHeaderString: function (header) {
36
- var _a = tslib_1.__read(header.match(/^(\d{4})(\d{2})(\d{2})T(\d{2})(\d{2})(\d{2}).+/), 7), year = _a[1], month = _a[2], day = _a[3], hour = _a[4], minute = _a[5], second = _a[6];
52
+ var _a = __read(header.match(/^(\d{4})(\d{2})(\d{2})T(\d{2})(\d{2})(\d{2}).+/), 7), year = _a[1], month = _a[2], day = _a[3], hour = _a[4], minute = _a[5], second = _a[6];
37
53
  return new Date(Date.UTC(Number(year), Number(month) - 1, Number(day), Number(hour), Number(minute), Number(second)));
38
54
  },
39
55
  isClockSkewed: function (serverDate) {
@@ -55,4 +71,3 @@ exports.DateUtils = {
55
71
  exports.DateUtils.clockOffset = offset;
56
72
  },
57
73
  };
58
- //# sourceMappingURL=DateUtils.js.map
package/lib/Util/Mutex.js CHANGED
@@ -69,4 +69,3 @@ var Mutex = /** @class */ (function () {
69
69
  return Mutex;
70
70
  }());
71
71
  exports.default = Mutex;
72
- //# sourceMappingURL=Mutex.js.map
@@ -1,5 +1,5 @@
1
1
  import Observable from 'zen-observable-ts';
2
- declare type NetworkStatus = {
2
+ type NetworkStatus = {
3
3
  online: boolean;
4
4
  };
5
5
  export default class ReachabilityNavigator implements Reachability {
@@ -1,16 +1,29 @@
1
1
  "use strict";
2
+ var __values = (this && this.__values) || function(o) {
3
+ var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
4
+ if (m) return m.call(o);
5
+ if (o && typeof o.length === "number") return {
6
+ next: function () {
7
+ if (o && i >= o.length) o = void 0;
8
+ return { value: o && o[i++], done: !o };
9
+ }
10
+ };
11
+ throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
12
+ };
13
+ var __importDefault = (this && this.__importDefault) || function (mod) {
14
+ return (mod && mod.__esModule) ? mod : { "default": mod };
15
+ };
2
16
  Object.defineProperty(exports, "__esModule", { value: true });
3
- var tslib_1 = require("tslib");
4
17
  var core_1 = require("@aws-amplify/core");
5
- var zen_observable_ts_1 = tslib_1.__importDefault(require("zen-observable-ts"));
18
+ var zen_observable_ts_1 = __importDefault(require("zen-observable-ts"));
6
19
  var ReachabilityNavigator = /** @class */ (function () {
7
20
  function ReachabilityNavigator() {
8
21
  }
9
22
  ReachabilityNavigator.prototype.networkMonitor = function (netInfo) {
10
- if (core_1.browserOrNode().isNode) {
23
+ if ((0, core_1.browserOrNode)().isNode) {
11
24
  return zen_observable_ts_1.default.from([{ online: true }]);
12
25
  }
13
- var globalObj = core_1.isWebWorker() ? self : window;
26
+ var globalObj = (0, core_1.isWebWorker)() ? self : window;
14
27
  return new zen_observable_ts_1.default(function (observer) {
15
28
  observer.next({ online: globalObj.navigator.onLine });
16
29
  var notifyOnline = function () { return observer.next({ online: true }); };
@@ -36,7 +49,7 @@ var ReachabilityNavigator = /** @class */ (function () {
36
49
  observer.next(status);
37
50
  };
38
51
  try {
39
- for (var _b = tslib_1.__values(ReachabilityNavigator._observers), _c = _b.next(); !_c.done; _c = _b.next()) {
52
+ for (var _b = __values(ReachabilityNavigator._observers), _c = _b.next(); !_c.done; _c = _b.next()) {
40
53
  var observer = _c.value;
41
54
  _loop_1(observer);
42
55
  }
@@ -53,4 +66,3 @@ var ReachabilityNavigator = /** @class */ (function () {
53
66
  return ReachabilityNavigator;
54
67
  }());
55
68
  exports.default = ReachabilityNavigator;
56
- //# sourceMappingURL=Reachability.js.map
@@ -1,5 +1,5 @@
1
1
  import Observable from 'zen-observable-ts';
2
- declare type NetworkStatus = {
2
+ type NetworkStatus = {
3
3
  online: boolean;
4
4
  };
5
5
  export default class ReachabilityNavigator implements Reachability {
@@ -1,7 +1,9 @@
1
1
  "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
2
5
  Object.defineProperty(exports, "__esModule", { value: true });
3
- var tslib_1 = require("tslib");
4
- var zen_observable_ts_1 = tslib_1.__importDefault(require("zen-observable-ts"));
6
+ var zen_observable_ts_1 = __importDefault(require("zen-observable-ts"));
5
7
  var Logger_1 = require("../Logger");
6
8
  var logger = new Logger_1.ConsoleLogger('Reachability', 'DEBUG');
7
9
  var ReachabilityNavigator = /** @class */ (function () {
@@ -38,4 +40,3 @@ var ReachabilityNavigator = /** @class */ (function () {
38
40
  return ReachabilityNavigator;
39
41
  }());
40
42
  exports.default = ReachabilityNavigator;
41
- //# sourceMappingURL=Reachability.native.js.map
package/lib/Util/Retry.js CHANGED
@@ -1,10 +1,86 @@
1
1
  "use strict";
2
+ var __extends = (this && this.__extends) || (function () {
3
+ var extendStatics = function (d, b) {
4
+ extendStatics = Object.setPrototypeOf ||
5
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
6
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
7
+ return extendStatics(d, b);
8
+ };
9
+ return function (d, b) {
10
+ if (typeof b !== "function" && b !== null)
11
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
12
+ extendStatics(d, b);
13
+ function __() { this.constructor = d; }
14
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
15
+ };
16
+ })();
17
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
18
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
19
+ return new (P || (P = Promise))(function (resolve, reject) {
20
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
21
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
22
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
23
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
24
+ });
25
+ };
26
+ var __generator = (this && this.__generator) || function (thisArg, body) {
27
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
28
+ return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
29
+ function verb(n) { return function (v) { return step([n, v]); }; }
30
+ function step(op) {
31
+ if (f) throw new TypeError("Generator is already executing.");
32
+ while (g && (g = 0, op[0] && (_ = 0)), _) try {
33
+ if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
34
+ if (y = 0, t) op = [op[0] & 2, t.value];
35
+ switch (op[0]) {
36
+ case 0: case 1: t = op; break;
37
+ case 4: _.label++; return { value: op[1], done: false };
38
+ case 5: _.label++; y = op[1]; op = [0]; continue;
39
+ case 7: op = _.ops.pop(); _.trys.pop(); continue;
40
+ default:
41
+ if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
42
+ if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
43
+ if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
44
+ if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
45
+ if (t[2]) _.ops.pop();
46
+ _.trys.pop(); continue;
47
+ }
48
+ op = body.call(thisArg, _);
49
+ } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
50
+ if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
51
+ }
52
+ };
53
+ var __read = (this && this.__read) || function (o, n) {
54
+ var m = typeof Symbol === "function" && o[Symbol.iterator];
55
+ if (!m) return o;
56
+ var i = m.call(o), r, ar = [], e;
57
+ try {
58
+ while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
59
+ }
60
+ catch (error) { e = { error: error }; }
61
+ finally {
62
+ try {
63
+ if (r && !r.done && (m = i["return"])) m.call(i);
64
+ }
65
+ finally { if (e) throw e.error; }
66
+ }
67
+ return ar;
68
+ };
69
+ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
70
+ if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
71
+ if (ar || !(i in from)) {
72
+ if (!ar) ar = Array.prototype.slice.call(from, 0, i);
73
+ ar[i] = from[i];
74
+ }
75
+ }
76
+ return to.concat(ar || Array.prototype.slice.call(from));
77
+ };
2
78
  Object.defineProperty(exports, "__esModule", { value: true });
3
- var tslib_1 = require("tslib");
79
+ exports.jitteredExponentialRetry = exports.jitteredBackoff = exports.retry = exports.isNonRetryableError = exports.NonRetryableError = void 0;
4
80
  var ConsoleLogger_1 = require("../Logger/ConsoleLogger");
5
81
  var logger = new ConsoleLogger_1.ConsoleLogger('Util');
6
82
  var NonRetryableError = /** @class */ (function (_super) {
7
- tslib_1.__extends(NonRetryableError, _super);
83
+ __extends(NonRetryableError, _super);
8
84
  function NonRetryableError(message) {
9
85
  var _this = _super.call(this, message) || this;
10
86
  _this.nonRetryable = true;
@@ -13,24 +89,25 @@ var NonRetryableError = /** @class */ (function (_super) {
13
89
  return NonRetryableError;
14
90
  }(Error));
15
91
  exports.NonRetryableError = NonRetryableError;
16
- exports.isNonRetryableError = function (obj) {
92
+ var isNonRetryableError = function (obj) {
17
93
  var key = 'nonRetryable';
18
94
  return obj && obj[key];
19
95
  };
96
+ exports.isNonRetryableError = isNonRetryableError;
20
97
  /**
21
98
  * @private
22
99
  * Internal use of Amplify only
23
100
  */
24
101
  function retry(functionToRetry, args, delayFn, onTerminate) {
25
- return tslib_1.__awaiter(this, void 0, void 0, function () {
102
+ return __awaiter(this, void 0, void 0, function () {
26
103
  var _this = this;
27
- return tslib_1.__generator(this, function (_a) {
104
+ return __generator(this, function (_a) {
28
105
  if (typeof functionToRetry !== 'function') {
29
106
  throw Error('functionToRetry must be a function');
30
107
  }
31
- return [2 /*return*/, new Promise(function (resolve, reject) { return tslib_1.__awaiter(_this, void 0, void 0, function () {
108
+ return [2 /*return*/, new Promise(function (resolve, reject) { return __awaiter(_this, void 0, void 0, function () {
32
109
  var attempt, terminated, timeout, wakeUp, lastError, _loop_1, state_1;
33
- return tslib_1.__generator(this, function (_a) {
110
+ return __generator(this, function (_a) {
34
111
  switch (_a.label) {
35
112
  case 0:
36
113
  attempt = 0;
@@ -45,29 +122,29 @@ function retry(functionToRetry, args, delayFn, onTerminate) {
45
122
  wakeUp();
46
123
  });
47
124
  _loop_1 = function () {
48
- var _a, _b, err_1, retryIn_1;
49
- return tslib_1.__generator(this, function (_c) {
50
- switch (_c.label) {
125
+ var _b, _c, err_1, retryIn_1;
126
+ return __generator(this, function (_d) {
127
+ switch (_d.label) {
51
128
  case 0:
52
129
  attempt++;
53
- logger.debug(functionToRetry.name + " attempt #" + attempt + " with this vars: " + JSON.stringify(args));
54
- _c.label = 1;
130
+ logger.debug("".concat(functionToRetry.name, " attempt #").concat(attempt, " with this vars: ").concat(JSON.stringify(args)));
131
+ _d.label = 1;
55
132
  case 1:
56
- _c.trys.push([1, 3, , 7]);
57
- _a = {};
58
- _b = resolve;
59
- return [4 /*yield*/, functionToRetry.apply(void 0, tslib_1.__spread(args))];
60
- case 2: return [2 /*return*/, (_a.value = _b.apply(void 0, [_c.sent()]), _a)];
133
+ _d.trys.push([1, 3, , 7]);
134
+ _b = {};
135
+ _c = resolve;
136
+ return [4 /*yield*/, functionToRetry.apply(void 0, __spreadArray([], __read(args), false))];
137
+ case 2: return [2 /*return*/, (_b.value = _c.apply(void 0, [_d.sent()]), _b)];
61
138
  case 3:
62
- err_1 = _c.sent();
139
+ err_1 = _d.sent();
63
140
  lastError = err_1;
64
- logger.debug("error on " + functionToRetry.name, err_1);
65
- if (exports.isNonRetryableError(err_1)) {
66
- logger.debug(functionToRetry.name + " non retryable error", err_1);
141
+ logger.debug("error on ".concat(functionToRetry.name), err_1);
142
+ if ((0, exports.isNonRetryableError)(err_1)) {
143
+ logger.debug("".concat(functionToRetry.name, " non retryable error"), err_1);
67
144
  return [2 /*return*/, { value: reject(err_1) }];
68
145
  }
69
146
  retryIn_1 = delayFn(attempt, args, err_1);
70
- logger.debug(functionToRetry.name + " retrying in " + retryIn_1 + " ms");
147
+ logger.debug("".concat(functionToRetry.name, " retrying in ").concat(retryIn_1, " ms"));
71
148
  if (!(retryIn_1 === false || terminated)) return [3 /*break*/, 4];
72
149
  return [2 /*return*/, { value: reject(err_1) }];
73
150
  case 4: return [4 /*yield*/, new Promise(function (r) {
@@ -75,8 +152,8 @@ function retry(functionToRetry, args, delayFn, onTerminate) {
75
152
  timeout = setTimeout(wakeUp, retryIn_1);
76
153
  })];
77
154
  case 5:
78
- _c.sent();
79
- _c.label = 6;
155
+ _d.sent();
156
+ _d.label = 6;
80
157
  case 6: return [3 /*break*/, 7];
81
158
  case 7: return [2 /*return*/];
82
159
  }
@@ -121,8 +198,8 @@ exports.jitteredBackoff = jitteredBackoff;
121
198
  * @private
122
199
  * Internal use of Amplify only
123
200
  */
124
- exports.jitteredExponentialRetry = function (functionToRetry, args, maxDelayMs, onTerminate) {
201
+ var jitteredExponentialRetry = function (functionToRetry, args, maxDelayMs, onTerminate) {
125
202
  if (maxDelayMs === void 0) { maxDelayMs = MAX_DELAY_MS; }
126
203
  return retry(functionToRetry, args, jitteredBackoff(maxDelayMs), onTerminate);
127
204
  };
128
- //# sourceMappingURL=Retry.js.map
205
+ exports.jitteredExponentialRetry = jitteredExponentialRetry;
@@ -1,5 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.urlSafeDecode = exports.urlSafeEncode = void 0;
3
4
  function urlSafeEncode(str) {
4
5
  return str
5
6
  .split('')
@@ -19,4 +20,3 @@ function urlSafeDecode(hex) {
19
20
  .join('');
20
21
  }
21
22
  exports.urlSafeDecode = urlSafeDecode;
22
- //# sourceMappingURL=StringUtils.js.map