vviinn-widgets 2.7.2 → 2.8.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 (357) hide show
  1. package/dist/components/Handler.js +270 -0
  2. package/dist/components/NonEmptyArray.js +5699 -0
  3. package/dist/components/cropper-handler.js +6 -0
  4. package/dist/components/cropper-handler2.js +39 -0
  5. package/dist/{cjs/customized-slots-06ca4007.js → components/customized-slots.js} +3 -6
  6. package/dist/components/highlight-box.js +6 -0
  7. package/dist/components/highlight-box2.js +52 -0
  8. package/dist/components/image-cropper.js +6 -0
  9. package/dist/components/image-cropper2.js +138 -0
  10. package/dist/components/imageSearch.store.js +10686 -0
  11. package/dist/components/index.js +1 -0
  12. package/dist/{esm/index-443468c7.js → components/index2.js} +2 -2
  13. package/dist/components/index3.js +130 -0
  14. package/dist/components/recommendations-sidebar.js +101 -0
  15. package/dist/components/resizer.worker.js +11 -0
  16. package/dist/components/search-filters.js +6 -0
  17. package/dist/components/search-filters2.js +89 -0
  18. package/dist/components/tracking.worker.js +11 -0
  19. package/dist/components/vviinn-carousel.js +6 -0
  20. package/dist/components/vviinn-carousel2.js +235 -0
  21. package/dist/components/vviinn-detected-object.js +6 -0
  22. package/dist/components/vviinn-detected-object2.js +67 -0
  23. package/dist/components/vviinn-empty-results.js +6 -0
  24. package/dist/components/vviinn-empty-results2.js +35 -0
  25. package/dist/components/vviinn-error.js +6 -0
  26. package/dist/components/vviinn-error2.js +28 -0
  27. package/dist/components/vviinn-example-image.js +6 -0
  28. package/dist/components/vviinn-example-image2.js +57 -0
  29. package/dist/components/vviinn-example-images.js +6 -0
  30. package/dist/components/vviinn-example-images2.js +53 -0
  31. package/dist/components/vviinn-image-selector.js +6 -0
  32. package/dist/components/vviinn-image-selector2.js +135 -0
  33. package/dist/components/vviinn-image-view.js +6 -0
  34. package/dist/components/vviinn-image-view2.js +95 -0
  35. package/dist/components/vviinn-modal.js +6 -0
  36. package/dist/components/vviinn-modal2.js +46 -0
  37. package/dist/components/vviinn-onboarding-card-1.js +6 -0
  38. package/dist/components/vviinn-onboarding-card-12.js +34 -0
  39. package/dist/components/vviinn-onboarding-card-2.js +6 -0
  40. package/dist/components/vviinn-onboarding-card-22.js +34 -0
  41. package/dist/components/vviinn-onboarding-card-3.js +6 -0
  42. package/dist/components/vviinn-onboarding-card-32.js +34 -0
  43. package/dist/components/vviinn-onboarding.js +6 -0
  44. package/dist/components/vviinn-onboarding2.js +63 -0
  45. package/dist/components/vviinn-overlay.js +6 -0
  46. package/dist/components/vviinn-overlay2.js +28 -0
  47. package/dist/components/vviinn-overlayed-modal.js +6 -0
  48. package/dist/components/vviinn-overlayed-modal2.js +45 -0
  49. package/dist/components/vviinn-preloader.js +6 -0
  50. package/dist/components/vviinn-preloader2.js +34 -0
  51. package/dist/components/vviinn-privacy-badge.js +6 -0
  52. package/dist/components/vviinn-privacy-badge2.js +33 -0
  53. package/dist/components/vviinn-product-card.js +6 -0
  54. package/dist/components/vviinn-product-card2.js +216 -0
  55. package/dist/components/vviinn-recommendations-sidebar.js +6 -0
  56. package/dist/components/vviinn-server-error.js +6 -0
  57. package/dist/components/vviinn-server-error2.js +35 -0
  58. package/dist/components/vviinn-slide.js +6 -0
  59. package/dist/components/vviinn-slide2.js +28 -0
  60. package/dist/components/vviinn-slider.js +6 -0
  61. package/dist/components/vviinn-slider2.js +159 -0
  62. package/dist/components/vviinn-teaser.js +6 -0
  63. package/dist/components/vviinn-teaser2.js +33 -0
  64. package/dist/components/vviinn-vpr-button.js +93 -0
  65. package/dist/components/vviinn-vpr-vidget.js +3360 -0
  66. package/dist/components/vviinn-vpr-widget.js +6 -0
  67. package/dist/components/vviinn-vps-button.js +224 -0
  68. package/dist/components/vviinn-vps-widget.js +6 -0
  69. package/dist/components/vviinn-vps-widget2.js +350 -0
  70. package/dist/components/vviinn-wrong-format.js +6 -0
  71. package/dist/components/vviinn-wrong-format2.js +35 -0
  72. package/dist/types/components/vviinn-product-card/vviinn-product-card.d.ts +1 -0
  73. package/dist/types/components/vviinn-vpr-button/stories/lol.d.ts +2 -0
  74. package/dist/types/components/vviinn-vpr-button/stories/vviinn-vpr-button.stories.d.ts +1 -1
  75. package/dist/vviinn-widgets/Array-bdfc75db.js +4870 -0
  76. package/dist/vviinn-widgets/Handler-edcb46f4.js +1422 -0
  77. package/dist/vviinn-widgets/NonEmptyArray-947ab7b3.js +4411 -0
  78. package/dist/{esm/app-globals-865bc7a7.js → vviinn-widgets/app-globals-c0aa8ec3.js} +922 -10
  79. package/dist/vviinn-widgets/cropper-handler.entry.js +23 -0
  80. package/dist/vviinn-widgets/css-shim-f0027935.js +4 -0
  81. package/dist/{esm/customized-slots-96902edf.js → vviinn-widgets/customized-slots-5c1c623a.js} +1 -1
  82. package/dist/vviinn-widgets/dom-db0073f0.js +73 -0
  83. package/dist/vviinn-widgets/highlight-box.entry.js +41 -0
  84. package/dist/{collection/components/image-search/image-view/image-cropper/image-cropper.js → vviinn-widgets/image-cropper.entry.js} +33 -70
  85. package/dist/{cjs/index-df6896e2.js → vviinn-widgets/imageSearch.store-0eed9a5c.js} +11598 -15320
  86. package/dist/{esm/index-2fdd499d.js → vviinn-widgets/imageSearch.store-b28bddb0.js} +11971 -15281
  87. package/dist/{collection/components/vviinn-icons/index.js → vviinn-widgets/index-44058ea2.js} +14 -11
  88. package/dist/vviinn-widgets/index-6c6de682.js +3857 -0
  89. package/dist/vviinn-widgets/index-de3e14da.js +3010 -0
  90. package/dist/vviinn-widgets/index.esm.js +1 -0
  91. package/dist/vviinn-widgets/number-171db649.js +1499 -0
  92. package/dist/vviinn-widgets/search-filters.entry.js +76 -0
  93. package/dist/vviinn-widgets/shadow-css-c1fdfa9f.js +389 -0
  94. package/dist/{collection/components/vviinn-carousel/vviinn-carousel.js → vviinn-widgets/vviinn-carousel.entry.js} +18 -113
  95. package/dist/vviinn-widgets/vviinn-detected-object.entry.js +54 -0
  96. package/dist/vviinn-widgets/vviinn-empty-results.entry.js +16 -0
  97. package/dist/vviinn-widgets/vviinn-error.entry.js +15 -0
  98. package/dist/vviinn-widgets/vviinn-example-image.entry.js +38 -0
  99. package/dist/vviinn-widgets/vviinn-example-images.entry.js +28 -0
  100. package/dist/vviinn-widgets/vviinn-image-selector.entry.js +31 -0
  101. package/dist/vviinn-widgets/vviinn-image-view.entry.js +55 -0
  102. package/dist/vviinn-widgets/vviinn-modal.entry.js +30 -0
  103. package/dist/vviinn-widgets/vviinn-onboarding-card-1.entry.js +21 -0
  104. package/dist/vviinn-widgets/vviinn-onboarding-card-2.entry.js +21 -0
  105. package/dist/vviinn-widgets/vviinn-onboarding-card-3.entry.js +21 -0
  106. package/dist/vviinn-widgets/vviinn-onboarding.entry.js +20 -0
  107. package/dist/vviinn-widgets/vviinn-overlay.entry.js +15 -0
  108. package/dist/vviinn-widgets/vviinn-overlayed-modal.entry.js +18 -0
  109. package/dist/vviinn-widgets/vviinn-preloader.entry.js +25 -0
  110. package/dist/vviinn-widgets/vviinn-privacy-badge.entry.js +20 -0
  111. package/dist/vviinn-widgets/vviinn-product-card.entry.js +188 -0
  112. package/dist/{esm → vviinn-widgets}/vviinn-recommendations-sidebar.entry.js +2 -2
  113. package/dist/vviinn-widgets/vviinn-server-error.entry.js +16 -0
  114. package/dist/vviinn-widgets/vviinn-slide.entry.js +15 -0
  115. package/dist/vviinn-widgets/vviinn-slider.entry.js +120 -0
  116. package/dist/vviinn-widgets/vviinn-teaser.entry.js +20 -0
  117. package/dist/{esm → vviinn-widgets}/vviinn-vpr-button.entry.js +2 -2
  118. package/dist/vviinn-widgets/vviinn-vpr-widget.entry.js +4588 -0
  119. package/dist/{esm → vviinn-widgets}/vviinn-vps-button.entry.js +3 -3
  120. package/dist/vviinn-widgets/vviinn-vps-widget.entry.js +170 -0
  121. package/dist/vviinn-widgets/vviinn-widgets.css +6 -1
  122. package/dist/vviinn-widgets/vviinn-widgets.esm.js +125 -1
  123. package/dist/vviinn-widgets/vviinn-wrong-format.entry.js +16 -0
  124. package/package.json +8 -2
  125. package/www/build/p-06c76b5e.js +1 -0
  126. package/www/build/p-07e16d04.js +15 -0
  127. package/{dist/vviinn-widgets/p-a6e0710f.entry.js → www/build/p-44bc50de.entry.js} +1 -1
  128. package/www/build/p-510922c6.js +1 -0
  129. package/www/build/p-57ce8de3.css +1 -0
  130. package/www/build/p-591cb193.entry.js +1 -0
  131. package/www/build/p-6b9d242e.js +1 -0
  132. package/www/build/p-880bccf1.js +1 -0
  133. package/www/build/p-b0ada114.entry.js +1 -0
  134. package/www/build/p-b7be7c70.entry.js +1 -0
  135. package/{dist/vviinn-widgets/p-166970f3.js → www/build/p-ea8dea5c.js} +1 -1
  136. package/www/build/vviinn-widgets.css +1 -1
  137. package/www/build/vviinn-widgets.esm.js +1 -1
  138. package/www/index.html +32261 -1
  139. package/www/sw.js +66 -0
  140. package/dist/cjs/app-globals-8db3bcbe.js +0 -6912
  141. package/dist/cjs/cropper-handler_27.cjs.entry.js +0 -1135
  142. package/dist/cjs/index-3c3ab815.js +0 -1354
  143. package/dist/cjs/index-f66cd8d1.js +0 -39
  144. package/dist/cjs/index.cjs.js +0 -2
  145. package/dist/cjs/loader.cjs.js +0 -23
  146. package/dist/cjs/vviinn-carousel_2.cjs.entry.js +0 -1001
  147. package/dist/cjs/vviinn-recommendations-sidebar.cjs.entry.js +0 -65
  148. package/dist/cjs/vviinn-vpr-button.cjs.entry.js +0 -49
  149. package/dist/cjs/vviinn-vps-button.cjs.entry.js +0 -43
  150. package/dist/cjs/vviinn-widgets.cjs.js +0 -21
  151. package/dist/collection/Image/error.js +0 -14
  152. package/dist/collection/Image/form.js +0 -5
  153. package/dist/collection/Image/fromFile.js +0 -18
  154. package/dist/collection/Image/imageToB64.js +0 -9
  155. package/dist/collection/Image/index.js +0 -0
  156. package/dist/collection/Image/renderPromise.js +0 -6
  157. package/dist/collection/Image/resizeImage.js +0 -28
  158. package/dist/collection/Image/sizing.js +0 -39
  159. package/dist/collection/Image/toFile.js +0 -17
  160. package/dist/collection/analytics/GAnalytics.js +0 -32
  161. package/dist/collection/analytics/GeneralAnalytics.js +0 -9
  162. package/dist/collection/analytics/GtagAnalytics.js +0 -35
  163. package/dist/collection/analytics/ProductAnalytics.js +0 -1
  164. package/dist/collection/campaign/Campaign.js +0 -8
  165. package/dist/collection/campaign/CampaignService.js +0 -5
  166. package/dist/collection/campaign/VCSCampaign.js +0 -1
  167. package/dist/collection/campaign/VCSCampaignResponse.js +0 -1
  168. package/dist/collection/campaign/VCSCampaignService.js +0 -7
  169. package/dist/collection/campaign/VPRCampaignResponse.js +0 -1
  170. package/dist/collection/campaign/VPRCampaignService.js +0 -7
  171. package/dist/collection/collection-manifest.json +0 -43
  172. package/dist/collection/components/customized-slots.js +0 -47
  173. package/dist/collection/components/image-search/image-view/highlight-box/highlight-box.css +0 -71
  174. package/dist/collection/components/image-search/image-view/highlight-box/highlight-box.js +0 -25
  175. package/dist/collection/components/image-search/image-view/image-cropper/cropper-handler/cropper-handler.css +0 -49
  176. package/dist/collection/components/image-search/image-view/image-cropper/cropper-handler/cropper-handler.js +0 -64
  177. package/dist/collection/components/image-search/image-view/image-cropper/image-cropper.css +0 -33
  178. package/dist/collection/components/image-search/search-filters/search-filters.css +0 -120
  179. package/dist/collection/components/image-search/search-filters/search-filters.js +0 -125
  180. package/dist/collection/components/vviinn-carousel/vviinn-carousel.css +0 -142
  181. package/dist/collection/components/vviinn-error/vviinn-empty-results/vviinn-empty-results.css +0 -7
  182. package/dist/collection/components/vviinn-error/vviinn-empty-results/vviinn-empty-results.js +0 -36
  183. package/dist/collection/components/vviinn-error/vviinn-error.css +0 -38
  184. package/dist/collection/components/vviinn-error/vviinn-error.js +0 -18
  185. package/dist/collection/components/vviinn-error/vviinn-server-error/vviinn-server-error.css +0 -3
  186. package/dist/collection/components/vviinn-error/vviinn-server-error/vviinn-server-error.js +0 -34
  187. package/dist/collection/components/vviinn-error/vviinn-wrong-format/vviinn-wrong-format.css +0 -3
  188. package/dist/collection/components/vviinn-error/vviinn-wrong-format/vviinn-wrong-format.js +0 -34
  189. package/dist/collection/components/vviinn-example-images/vviinn-example-image/vviinn-example-image.css +0 -34
  190. package/dist/collection/components/vviinn-example-images/vviinn-example-image/vviinn-example-image.js +0 -129
  191. package/dist/collection/components/vviinn-example-images/vviinn-example-images.css +0 -19
  192. package/dist/collection/components/vviinn-example-images/vviinn-example-images.js +0 -80
  193. package/dist/collection/components/vviinn-image-selector/vviinn-image-selector.css +0 -25
  194. package/dist/collection/components/vviinn-image-selector/vviinn-image-selector.js +0 -64
  195. package/dist/collection/components/vviinn-image-view/vviinn-detected-object/vviinn-detected-object.css +0 -47
  196. package/dist/collection/components/vviinn-image-view/vviinn-detected-object/vviinn-detected-object.js +0 -100
  197. package/dist/collection/components/vviinn-image-view/vviinn-image-view.css +0 -31
  198. package/dist/collection/components/vviinn-image-view/vviinn-image-view.js +0 -61
  199. package/dist/collection/components/vviinn-modal/vviinn-modal.css +0 -105
  200. package/dist/collection/components/vviinn-modal/vviinn-modal.js +0 -98
  201. package/dist/collection/components/vviinn-onboarding/onboarding-cards/onboarding-card.css +0 -41
  202. package/dist/collection/components/vviinn-onboarding/onboarding-cards/vviinn-onboarding-card-1/vviinn-onboarding-card-1.js +0 -26
  203. package/dist/collection/components/vviinn-onboarding/onboarding-cards/vviinn-onboarding-card-2/vviinn-onboarding-card-2.js +0 -26
  204. package/dist/collection/components/vviinn-onboarding/onboarding-cards/vviinn-onboarding-card-3/vviinn-onboarding-card-3.js +0 -26
  205. package/dist/collection/components/vviinn-onboarding/vviinn-onboarding.css +0 -58
  206. package/dist/collection/components/vviinn-onboarding/vviinn-onboarding.js +0 -28
  207. package/dist/collection/components/vviinn-overlay/vviinn-overlay.css +0 -33
  208. package/dist/collection/components/vviinn-overlay/vviinn-overlay.js +0 -15
  209. package/dist/collection/components/vviinn-overlayed-modal/vviinn-overlayed-modal.css +0 -29
  210. package/dist/collection/components/vviinn-overlayed-modal/vviinn-overlayed-modal.js +0 -71
  211. package/dist/collection/components/vviinn-preloader/vviinn-preloader.css +0 -37
  212. package/dist/collection/components/vviinn-preloader/vviinn-preloader.js +0 -20
  213. package/dist/collection/components/vviinn-privacy-badge/vviinn-privacy-badge.css +0 -19
  214. package/dist/collection/components/vviinn-privacy-badge/vviinn-privacy-badge.js +0 -27
  215. package/dist/collection/components/vviinn-product-card/render-helpers.js +0 -32
  216. package/dist/collection/components/vviinn-product-card/stories/args.js +0 -73
  217. package/dist/collection/components/vviinn-product-card/stories/decorators.js +0 -51
  218. package/dist/collection/components/vviinn-product-card/stories/vviinn-product-card.stories.js +0 -105
  219. package/dist/collection/components/vviinn-product-card/vviinn-product-card.css +0 -95
  220. package/dist/collection/components/vviinn-product-card/vviinn-product-card.js +0 -462
  221. package/dist/collection/components/vviinn-slider/arrow.js +0 -11
  222. package/dist/collection/components/vviinn-slider/vviinn-slide/vviinn-slide.css +0 -4
  223. package/dist/collection/components/vviinn-slider/vviinn-slide/vviinn-slide.js +0 -15
  224. package/dist/collection/components/vviinn-slider/vviinn-slider.css +0 -109
  225. package/dist/collection/components/vviinn-slider/vviinn-slider.js +0 -181
  226. package/dist/collection/components/vviinn-teaser/vviinn-teaser.css +0 -14
  227. package/dist/collection/components/vviinn-teaser/vviinn-teaser.js +0 -29
  228. package/dist/collection/components/vviinn-vpr-button/recommendations-sidebar/recommendations-sidebar.css +0 -238
  229. package/dist/collection/components/vviinn-vpr-button/recommendations-sidebar/recommendations-sidebar.js +0 -220
  230. package/dist/collection/components/vviinn-vpr-button/stories/args.js +0 -213
  231. package/dist/collection/components/vviinn-vpr-button/stories/vviinn-vpr-button.stories.js +0 -91
  232. package/dist/collection/components/vviinn-vpr-button/vviinn-vpr-button.css +0 -35
  233. package/dist/collection/components/vviinn-vpr-button/vviinn-vpr-button.js +0 -179
  234. package/dist/collection/components/vviinn-vpr-widget/stories/args.js +0 -197
  235. package/dist/collection/components/vviinn-vpr-widget/stories/decorators.js +0 -29
  236. package/dist/collection/components/vviinn-vpr-widget/stories/vviinn-vpr-widget.stories.js +0 -211
  237. package/dist/collection/components/vviinn-vpr-widget/token-helpers.js +0 -11
  238. package/dist/collection/components/vviinn-vpr-widget/vviinn-vpr-vidget.js +0 -510
  239. package/dist/collection/components/vviinn-vpr-widget/vviinn-vpr-widget.css +0 -79
  240. package/dist/collection/components/vviinn-vps-button/stories/vviinn-vps-button.stories.js +0 -35
  241. package/dist/collection/components/vviinn-vps-button/vviinn-vps-button.css +0 -3
  242. package/dist/collection/components/vviinn-vps-button/vviinn-vps-button.js +0 -195
  243. package/dist/collection/components/vviinn-vps-widget/stories/vviinn-vps-widget.stories.js +0 -37
  244. package/dist/collection/components/vviinn-vps-widget/vviinn-vps-widget.css +0 -350
  245. package/dist/collection/components/vviinn-vps-widget/vviinn-vps-widget.js +0 -375
  246. package/dist/collection/cropper/Cropper.js +0 -1
  247. package/dist/collection/cropper/Handler.js +0 -61
  248. package/dist/collection/dom/index.js +0 -3
  249. package/dist/collection/error.js +0 -14
  250. package/dist/collection/file/index.js +0 -4
  251. package/dist/collection/geometry/Clip.js +0 -14
  252. package/dist/collection/geometry/Point.js +0 -32
  253. package/dist/collection/geometry/Rectangle.js +0 -95
  254. package/dist/collection/geometry/RectangleAlt.js +0 -1
  255. package/dist/collection/geometry/Sized.js +0 -8
  256. package/dist/collection/global.js +0 -19
  257. package/dist/collection/index.js +0 -1
  258. package/dist/collection/interfaces/generated.js +0 -5
  259. package/dist/collection/interfaces/recommendation.js +0 -1
  260. package/dist/collection/network/apiClient.js +0 -9
  261. package/dist/collection/network/ion/File.js +0 -14
  262. package/dist/collection/network/ion/Form.js +0 -64
  263. package/dist/collection/network/ion/Link.js +0 -8
  264. package/dist/collection/network/ion/ValueObject.js +0 -23
  265. package/dist/collection/network/request.js +0 -19
  266. package/dist/collection/network/utils.js +0 -37
  267. package/dist/collection/openApi/index.js +0 -27
  268. package/dist/collection/recommendation/events.js +0 -1
  269. package/dist/collection/recommendation/recommendation.js +0 -1
  270. package/dist/collection/searchSession/searchSession.js +0 -31
  271. package/dist/collection/sentry.js +0 -14
  272. package/dist/collection/slider/GridMode.js +0 -1
  273. package/dist/collection/store/file-processing.js +0 -13
  274. package/dist/collection/store/imageSearch.store.js +0 -133
  275. package/dist/collection/store/store.js +0 -3
  276. package/dist/collection/store/tracking.store.js +0 -3
  277. package/dist/collection/stories/Button.js +0 -21
  278. package/dist/collection/stories/Button.stories.js +0 -42
  279. package/dist/collection/stories/Header.js +0 -45
  280. package/dist/collection/stories/Header.stories.js +0 -15
  281. package/dist/collection/stories/Page.js +0 -61
  282. package/dist/collection/stories/Page.stories.js +0 -19
  283. package/dist/collection/stories/assets/code-brackets.svg +0 -1
  284. package/dist/collection/stories/assets/colors.svg +0 -1
  285. package/dist/collection/stories/assets/comments.svg +0 -1
  286. package/dist/collection/stories/assets/direction.svg +0 -1
  287. package/dist/collection/stories/assets/flow.svg +0 -1
  288. package/dist/collection/stories/assets/plugin.svg +0 -1
  289. package/dist/collection/stories/assets/repo.svg +0 -1
  290. package/dist/collection/stories/assets/stackalt.svg +0 -1
  291. package/dist/collection/stories/image-selector.stories.js +0 -6
  292. package/dist/collection/stories/image-view.stories.js +0 -6
  293. package/dist/collection/stories/modal.stories.js +0 -12
  294. package/dist/collection/stories/onboarding.stories.js +0 -11
  295. package/dist/collection/stories/overlay.stories.js +0 -5
  296. package/dist/collection/stories/overlayedModal.stories.js +0 -8
  297. package/dist/collection/stories/privacy-badge.stories.js +0 -11
  298. package/dist/collection/stories/slider.stories.js +0 -17
  299. package/dist/collection/stories/teaser.stories.js +0 -5
  300. package/dist/collection/stories/vps-widget.stories.js +0 -47
  301. package/dist/collection/stories/vviinn-product.stories.js +0 -19
  302. package/dist/collection/tracking/event.js +0 -3
  303. package/dist/collection/tracking/filter.js +0 -5
  304. package/dist/collection/tracking/index.js +0 -13
  305. package/dist/collection/tracking/models.js +0 -6
  306. package/dist/collection/tracking/product.js +0 -18
  307. package/dist/collection/tracking/search.js +0 -5
  308. package/dist/collection/tracking/widget.js +0 -10
  309. package/dist/collection/utils/collections/collectionsUtils.js +0 -5
  310. package/dist/collection/utils/either.js +0 -3
  311. package/dist/collection/utils/enum/enumUtils.js +0 -3
  312. package/dist/collection/utils/event/Events.js +0 -1
  313. package/dist/collection/utils/number/index.js +0 -4
  314. package/dist/collection/utils/option/option.js +0 -4
  315. package/dist/collection/utils/semigroup/semigroupDiff.js +0 -6
  316. package/dist/collection/utils/token/tokenUtils.js +0 -9
  317. package/dist/esm/cropper-handler_27.entry.js +0 -1105
  318. package/dist/esm/index-51f71d18.js +0 -1323
  319. package/dist/esm/index.js +0 -1
  320. package/dist/esm/loader.js +0 -19
  321. package/dist/esm/polyfills/core-js.js +0 -11
  322. package/dist/esm/polyfills/css-shim.js +0 -1
  323. package/dist/esm/polyfills/dom.js +0 -79
  324. package/dist/esm/polyfills/es5-html-element.js +0 -1
  325. package/dist/esm/polyfills/index.js +0 -34
  326. package/dist/esm/polyfills/system.js +0 -6
  327. package/dist/esm/vviinn-carousel_2.entry.js +0 -996
  328. package/dist/esm/vviinn-widgets.js +0 -19
  329. package/dist/index.cjs.js +0 -1
  330. package/dist/index.js +0 -1
  331. package/dist/loader/cdn.js +0 -3
  332. package/dist/loader/index.cjs.js +0 -3
  333. package/dist/loader/index.d.ts +0 -12
  334. package/dist/loader/index.es2017.js +0 -3
  335. package/dist/loader/index.js +0 -4
  336. package/dist/loader/package.json +0 -10
  337. package/dist/vviinn-widgets/p-2dd35f19.entry.js +0 -1
  338. package/dist/vviinn-widgets/p-3469b71a.js +0 -1
  339. package/dist/vviinn-widgets/p-40bea5b5.entry.js +0 -1
  340. package/dist/vviinn-widgets/p-465d043d.js +0 -15
  341. package/dist/vviinn-widgets/p-59bd2a99.js +0 -1
  342. package/dist/vviinn-widgets/p-74ed36af.entry.js +0 -1
  343. package/dist/vviinn-widgets/p-9def6b8b.entry.js +0 -1
  344. package/dist/vviinn-widgets/p-cd995515.js +0 -1
  345. package/www/build/p-166970f3.js +0 -1
  346. package/www/build/p-2dd35f19.entry.js +0 -1
  347. package/www/build/p-3469b71a.js +0 -1
  348. package/www/build/p-40bea5b5.entry.js +0 -1
  349. package/www/build/p-465d043d.js +0 -15
  350. package/www/build/p-59bd2a99.js +0 -1
  351. package/www/build/p-61933b75.js +0 -1
  352. package/www/build/p-74ed36af.entry.js +0 -1
  353. package/www/build/p-9def6b8b.entry.js +0 -1
  354. package/www/build/p-a67898be.css +0 -1
  355. package/www/build/p-a6e0710f.entry.js +0 -1
  356. package/www/build/p-cd995515.js +0 -1
  357. package/www/favicon.ico +0 -0
@@ -0,0 +1,3857 @@
1
+ import { a as commonjsGlobal, c as createCommonjsModule, g as getDefaultExportFromCjs, e as getAugmentedNamespace } from './NonEmptyArray-947ab7b3.js';
2
+
3
+ // Unique ID creation requires a high quality random # generator. In the browser we therefore
4
+ // require the crypto API and do not support built-in fallback to lower quality random number
5
+ // generators (like Math.random()).
6
+ var getRandomValues;
7
+ var rnds8 = new Uint8Array(16);
8
+ function rng() {
9
+ // lazy load so that environments that need to polyfill have a chance to do so
10
+ if (!getRandomValues) {
11
+ // getRandomValues needs to be invoked in a context where "this" is a Crypto implementation. Also,
12
+ // find the complete implementation of crypto (msCrypto) on IE11.
13
+ getRandomValues = typeof crypto !== 'undefined' && crypto.getRandomValues && crypto.getRandomValues.bind(crypto) || typeof msCrypto !== 'undefined' && typeof msCrypto.getRandomValues === 'function' && msCrypto.getRandomValues.bind(msCrypto);
14
+
15
+ if (!getRandomValues) {
16
+ throw new Error('crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported');
17
+ }
18
+ }
19
+
20
+ return getRandomValues(rnds8);
21
+ }
22
+
23
+ const REGEX = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;
24
+
25
+ function validate(uuid) {
26
+ return typeof uuid === 'string' && REGEX.test(uuid);
27
+ }
28
+
29
+ /**
30
+ * Convert array of 16 byte values to UUID string format of the form:
31
+ * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX
32
+ */
33
+
34
+ var byteToHex = [];
35
+
36
+ for (var i = 0; i < 256; ++i) {
37
+ byteToHex.push((i + 0x100).toString(16).substr(1));
38
+ }
39
+
40
+ function stringify$1(arr) {
41
+ var offset = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
42
+ // Note: Be careful editing this code! It's been tuned for performance
43
+ // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434
44
+ var uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one
45
+ // of the following:
46
+ // - One or more input array values don't map to a hex octet (leading to
47
+ // "undefined" in the uuid)
48
+ // - Invalid input values for the RFC `version` or `variant` fields
49
+
50
+ if (!validate(uuid)) {
51
+ throw TypeError('Stringified UUID is invalid');
52
+ }
53
+
54
+ return uuid;
55
+ }
56
+
57
+ //
58
+ // Inspired by https://github.com/LiosK/UUID.js
59
+ // and http://docs.python.org/library/uuid.html
60
+
61
+ var _nodeId;
62
+
63
+ var _clockseq; // Previous uuid creation time
64
+
65
+
66
+ var _lastMSecs = 0;
67
+ var _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details
68
+
69
+ function v1(options, buf, offset) {
70
+ var i = buf && offset || 0;
71
+ var b = buf || new Array(16);
72
+ options = options || {};
73
+ var node = options.node || _nodeId;
74
+ var clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not
75
+ // specified. We do this lazily to minimize issues related to insufficient
76
+ // system entropy. See #189
77
+
78
+ if (node == null || clockseq == null) {
79
+ var seedBytes = options.random || (options.rng || rng)();
80
+
81
+ if (node == null) {
82
+ // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1)
83
+ node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]];
84
+ }
85
+
86
+ if (clockseq == null) {
87
+ // Per 4.2.2, randomize (14 bit) clockseq
88
+ clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff;
89
+ }
90
+ } // UUID timestamps are 100 nano-second units since the Gregorian epoch,
91
+ // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so
92
+ // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs'
93
+ // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00.
94
+
95
+
96
+ var msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock
97
+ // cycle to simulate higher resolution clock
98
+
99
+ var nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs)
100
+
101
+ var dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression
102
+
103
+ if (dt < 0 && options.clockseq === undefined) {
104
+ clockseq = clockseq + 1 & 0x3fff;
105
+ } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new
106
+ // time interval
107
+
108
+
109
+ if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) {
110
+ nsecs = 0;
111
+ } // Per 4.2.1.2 Throw error if too many uuids are requested
112
+
113
+
114
+ if (nsecs >= 10000) {
115
+ throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");
116
+ }
117
+
118
+ _lastMSecs = msecs;
119
+ _lastNSecs = nsecs;
120
+ _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch
121
+
122
+ msecs += 12219292800000; // `time_low`
123
+
124
+ var tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000;
125
+ b[i++] = tl >>> 24 & 0xff;
126
+ b[i++] = tl >>> 16 & 0xff;
127
+ b[i++] = tl >>> 8 & 0xff;
128
+ b[i++] = tl & 0xff; // `time_mid`
129
+
130
+ var tmh = msecs / 0x100000000 * 10000 & 0xfffffff;
131
+ b[i++] = tmh >>> 8 & 0xff;
132
+ b[i++] = tmh & 0xff; // `time_high_and_version`
133
+
134
+ b[i++] = tmh >>> 24 & 0xf | 0x10; // include version
135
+
136
+ b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant)
137
+
138
+ b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low`
139
+
140
+ b[i++] = clockseq & 0xff; // `node`
141
+
142
+ for (var n = 0; n < 6; ++n) {
143
+ b[i + n] = node[n];
144
+ }
145
+
146
+ return buf || stringify$1(b);
147
+ }
148
+
149
+ function parse$1(uuid) {
150
+ if (!validate(uuid)) {
151
+ throw TypeError('Invalid UUID');
152
+ }
153
+
154
+ var v;
155
+ var arr = new Uint8Array(16); // Parse ########-....-....-....-............
156
+
157
+ arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24;
158
+ arr[1] = v >>> 16 & 0xff;
159
+ arr[2] = v >>> 8 & 0xff;
160
+ arr[3] = v & 0xff; // Parse ........-####-....-....-............
161
+
162
+ arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8;
163
+ arr[5] = v & 0xff; // Parse ........-....-####-....-............
164
+
165
+ arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8;
166
+ arr[7] = v & 0xff; // Parse ........-....-....-####-............
167
+
168
+ arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8;
169
+ arr[9] = v & 0xff; // Parse ........-....-....-....-############
170
+ // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes)
171
+
172
+ arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff;
173
+ arr[11] = v / 0x100000000 & 0xff;
174
+ arr[12] = v >>> 24 & 0xff;
175
+ arr[13] = v >>> 16 & 0xff;
176
+ arr[14] = v >>> 8 & 0xff;
177
+ arr[15] = v & 0xff;
178
+ return arr;
179
+ }
180
+
181
+ function stringToBytes(str) {
182
+ str = unescape(encodeURIComponent(str)); // UTF8 escape
183
+
184
+ var bytes = [];
185
+
186
+ for (var i = 0; i < str.length; ++i) {
187
+ bytes.push(str.charCodeAt(i));
188
+ }
189
+
190
+ return bytes;
191
+ }
192
+
193
+ var DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8';
194
+ var URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8';
195
+ function v35 (name, version, hashfunc) {
196
+ function generateUUID(value, namespace, buf, offset) {
197
+ if (typeof value === 'string') {
198
+ value = stringToBytes(value);
199
+ }
200
+
201
+ if (typeof namespace === 'string') {
202
+ namespace = parse$1(namespace);
203
+ }
204
+
205
+ if (namespace.length !== 16) {
206
+ throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)');
207
+ } // Compute hash of namespace and value, Per 4.3
208
+ // Future: Use spread syntax when supported on all platforms, e.g. `bytes =
209
+ // hashfunc([...namespace, ... value])`
210
+
211
+
212
+ var bytes = new Uint8Array(16 + value.length);
213
+ bytes.set(namespace);
214
+ bytes.set(value, namespace.length);
215
+ bytes = hashfunc(bytes);
216
+ bytes[6] = bytes[6] & 0x0f | version;
217
+ bytes[8] = bytes[8] & 0x3f | 0x80;
218
+
219
+ if (buf) {
220
+ offset = offset || 0;
221
+
222
+ for (var i = 0; i < 16; ++i) {
223
+ buf[offset + i] = bytes[i];
224
+ }
225
+
226
+ return buf;
227
+ }
228
+
229
+ return stringify$1(bytes);
230
+ } // Function#name is not settable on some platforms (#270)
231
+
232
+
233
+ try {
234
+ generateUUID.name = name; // eslint-disable-next-line no-empty
235
+ } catch (err) {} // For CommonJS default export support
236
+
237
+
238
+ generateUUID.DNS = DNS;
239
+ generateUUID.URL = URL;
240
+ return generateUUID;
241
+ }
242
+
243
+ /*
244
+ * Browser-compatible JavaScript MD5
245
+ *
246
+ * Modification of JavaScript MD5
247
+ * https://github.com/blueimp/JavaScript-MD5
248
+ *
249
+ * Copyright 2011, Sebastian Tschan
250
+ * https://blueimp.net
251
+ *
252
+ * Licensed under the MIT license:
253
+ * https://opensource.org/licenses/MIT
254
+ *
255
+ * Based on
256
+ * A JavaScript implementation of the RSA Data Security, Inc. MD5 Message
257
+ * Digest Algorithm, as defined in RFC 1321.
258
+ * Version 2.2 Copyright (C) Paul Johnston 1999 - 2009
259
+ * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet
260
+ * Distributed under the BSD License
261
+ * See http://pajhome.org.uk/crypt/md5 for more info.
262
+ */
263
+ function md5(bytes) {
264
+ if (typeof bytes === 'string') {
265
+ var msg = unescape(encodeURIComponent(bytes)); // UTF8 escape
266
+
267
+ bytes = new Uint8Array(msg.length);
268
+
269
+ for (var i = 0; i < msg.length; ++i) {
270
+ bytes[i] = msg.charCodeAt(i);
271
+ }
272
+ }
273
+
274
+ return md5ToHexEncodedArray(wordsToMd5(bytesToWords(bytes), bytes.length * 8));
275
+ }
276
+ /*
277
+ * Convert an array of little-endian words to an array of bytes
278
+ */
279
+
280
+
281
+ function md5ToHexEncodedArray(input) {
282
+ var output = [];
283
+ var length32 = input.length * 32;
284
+ var hexTab = '0123456789abcdef';
285
+
286
+ for (var i = 0; i < length32; i += 8) {
287
+ var x = input[i >> 5] >>> i % 32 & 0xff;
288
+ var hex = parseInt(hexTab.charAt(x >>> 4 & 0x0f) + hexTab.charAt(x & 0x0f), 16);
289
+ output.push(hex);
290
+ }
291
+
292
+ return output;
293
+ }
294
+ /**
295
+ * Calculate output length with padding and bit length
296
+ */
297
+
298
+
299
+ function getOutputLength(inputLength8) {
300
+ return (inputLength8 + 64 >>> 9 << 4) + 14 + 1;
301
+ }
302
+ /*
303
+ * Calculate the MD5 of an array of little-endian words, and a bit length.
304
+ */
305
+
306
+
307
+ function wordsToMd5(x, len) {
308
+ /* append padding */
309
+ x[len >> 5] |= 0x80 << len % 32;
310
+ x[getOutputLength(len) - 1] = len;
311
+ var a = 1732584193;
312
+ var b = -271733879;
313
+ var c = -1732584194;
314
+ var d = 271733878;
315
+
316
+ for (var i = 0; i < x.length; i += 16) {
317
+ var olda = a;
318
+ var oldb = b;
319
+ var oldc = c;
320
+ var oldd = d;
321
+ a = md5ff(a, b, c, d, x[i], 7, -680876936);
322
+ d = md5ff(d, a, b, c, x[i + 1], 12, -389564586);
323
+ c = md5ff(c, d, a, b, x[i + 2], 17, 606105819);
324
+ b = md5ff(b, c, d, a, x[i + 3], 22, -1044525330);
325
+ a = md5ff(a, b, c, d, x[i + 4], 7, -176418897);
326
+ d = md5ff(d, a, b, c, x[i + 5], 12, 1200080426);
327
+ c = md5ff(c, d, a, b, x[i + 6], 17, -1473231341);
328
+ b = md5ff(b, c, d, a, x[i + 7], 22, -45705983);
329
+ a = md5ff(a, b, c, d, x[i + 8], 7, 1770035416);
330
+ d = md5ff(d, a, b, c, x[i + 9], 12, -1958414417);
331
+ c = md5ff(c, d, a, b, x[i + 10], 17, -42063);
332
+ b = md5ff(b, c, d, a, x[i + 11], 22, -1990404162);
333
+ a = md5ff(a, b, c, d, x[i + 12], 7, 1804603682);
334
+ d = md5ff(d, a, b, c, x[i + 13], 12, -40341101);
335
+ c = md5ff(c, d, a, b, x[i + 14], 17, -1502002290);
336
+ b = md5ff(b, c, d, a, x[i + 15], 22, 1236535329);
337
+ a = md5gg(a, b, c, d, x[i + 1], 5, -165796510);
338
+ d = md5gg(d, a, b, c, x[i + 6], 9, -1069501632);
339
+ c = md5gg(c, d, a, b, x[i + 11], 14, 643717713);
340
+ b = md5gg(b, c, d, a, x[i], 20, -373897302);
341
+ a = md5gg(a, b, c, d, x[i + 5], 5, -701558691);
342
+ d = md5gg(d, a, b, c, x[i + 10], 9, 38016083);
343
+ c = md5gg(c, d, a, b, x[i + 15], 14, -660478335);
344
+ b = md5gg(b, c, d, a, x[i + 4], 20, -405537848);
345
+ a = md5gg(a, b, c, d, x[i + 9], 5, 568446438);
346
+ d = md5gg(d, a, b, c, x[i + 14], 9, -1019803690);
347
+ c = md5gg(c, d, a, b, x[i + 3], 14, -187363961);
348
+ b = md5gg(b, c, d, a, x[i + 8], 20, 1163531501);
349
+ a = md5gg(a, b, c, d, x[i + 13], 5, -1444681467);
350
+ d = md5gg(d, a, b, c, x[i + 2], 9, -51403784);
351
+ c = md5gg(c, d, a, b, x[i + 7], 14, 1735328473);
352
+ b = md5gg(b, c, d, a, x[i + 12], 20, -1926607734);
353
+ a = md5hh(a, b, c, d, x[i + 5], 4, -378558);
354
+ d = md5hh(d, a, b, c, x[i + 8], 11, -2022574463);
355
+ c = md5hh(c, d, a, b, x[i + 11], 16, 1839030562);
356
+ b = md5hh(b, c, d, a, x[i + 14], 23, -35309556);
357
+ a = md5hh(a, b, c, d, x[i + 1], 4, -1530992060);
358
+ d = md5hh(d, a, b, c, x[i + 4], 11, 1272893353);
359
+ c = md5hh(c, d, a, b, x[i + 7], 16, -155497632);
360
+ b = md5hh(b, c, d, a, x[i + 10], 23, -1094730640);
361
+ a = md5hh(a, b, c, d, x[i + 13], 4, 681279174);
362
+ d = md5hh(d, a, b, c, x[i], 11, -358537222);
363
+ c = md5hh(c, d, a, b, x[i + 3], 16, -722521979);
364
+ b = md5hh(b, c, d, a, x[i + 6], 23, 76029189);
365
+ a = md5hh(a, b, c, d, x[i + 9], 4, -640364487);
366
+ d = md5hh(d, a, b, c, x[i + 12], 11, -421815835);
367
+ c = md5hh(c, d, a, b, x[i + 15], 16, 530742520);
368
+ b = md5hh(b, c, d, a, x[i + 2], 23, -995338651);
369
+ a = md5ii(a, b, c, d, x[i], 6, -198630844);
370
+ d = md5ii(d, a, b, c, x[i + 7], 10, 1126891415);
371
+ c = md5ii(c, d, a, b, x[i + 14], 15, -1416354905);
372
+ b = md5ii(b, c, d, a, x[i + 5], 21, -57434055);
373
+ a = md5ii(a, b, c, d, x[i + 12], 6, 1700485571);
374
+ d = md5ii(d, a, b, c, x[i + 3], 10, -1894986606);
375
+ c = md5ii(c, d, a, b, x[i + 10], 15, -1051523);
376
+ b = md5ii(b, c, d, a, x[i + 1], 21, -2054922799);
377
+ a = md5ii(a, b, c, d, x[i + 8], 6, 1873313359);
378
+ d = md5ii(d, a, b, c, x[i + 15], 10, -30611744);
379
+ c = md5ii(c, d, a, b, x[i + 6], 15, -1560198380);
380
+ b = md5ii(b, c, d, a, x[i + 13], 21, 1309151649);
381
+ a = md5ii(a, b, c, d, x[i + 4], 6, -145523070);
382
+ d = md5ii(d, a, b, c, x[i + 11], 10, -1120210379);
383
+ c = md5ii(c, d, a, b, x[i + 2], 15, 718787259);
384
+ b = md5ii(b, c, d, a, x[i + 9], 21, -343485551);
385
+ a = safeAdd(a, olda);
386
+ b = safeAdd(b, oldb);
387
+ c = safeAdd(c, oldc);
388
+ d = safeAdd(d, oldd);
389
+ }
390
+
391
+ return [a, b, c, d];
392
+ }
393
+ /*
394
+ * Convert an array bytes to an array of little-endian words
395
+ * Characters >255 have their high-byte silently ignored.
396
+ */
397
+
398
+
399
+ function bytesToWords(input) {
400
+ if (input.length === 0) {
401
+ return [];
402
+ }
403
+
404
+ var length8 = input.length * 8;
405
+ var output = new Uint32Array(getOutputLength(length8));
406
+
407
+ for (var i = 0; i < length8; i += 8) {
408
+ output[i >> 5] |= (input[i / 8] & 0xff) << i % 32;
409
+ }
410
+
411
+ return output;
412
+ }
413
+ /*
414
+ * Add integers, wrapping at 2^32. This uses 16-bit operations internally
415
+ * to work around bugs in some JS interpreters.
416
+ */
417
+
418
+
419
+ function safeAdd(x, y) {
420
+ var lsw = (x & 0xffff) + (y & 0xffff);
421
+ var msw = (x >> 16) + (y >> 16) + (lsw >> 16);
422
+ return msw << 16 | lsw & 0xffff;
423
+ }
424
+ /*
425
+ * Bitwise rotate a 32-bit number to the left.
426
+ */
427
+
428
+
429
+ function bitRotateLeft(num, cnt) {
430
+ return num << cnt | num >>> 32 - cnt;
431
+ }
432
+ /*
433
+ * These functions implement the four basic operations the algorithm uses.
434
+ */
435
+
436
+
437
+ function md5cmn(q, a, b, x, s, t) {
438
+ return safeAdd(bitRotateLeft(safeAdd(safeAdd(a, q), safeAdd(x, t)), s), b);
439
+ }
440
+
441
+ function md5ff(a, b, c, d, x, s, t) {
442
+ return md5cmn(b & c | ~b & d, a, b, x, s, t);
443
+ }
444
+
445
+ function md5gg(a, b, c, d, x, s, t) {
446
+ return md5cmn(b & d | c & ~d, a, b, x, s, t);
447
+ }
448
+
449
+ function md5hh(a, b, c, d, x, s, t) {
450
+ return md5cmn(b ^ c ^ d, a, b, x, s, t);
451
+ }
452
+
453
+ function md5ii(a, b, c, d, x, s, t) {
454
+ return md5cmn(c ^ (b | ~d), a, b, x, s, t);
455
+ }
456
+
457
+ var v3 = v35('v3', 0x30, md5);
458
+
459
+ function v4(options, buf, offset) {
460
+ options = options || {};
461
+ var rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved`
462
+
463
+ rnds[6] = rnds[6] & 0x0f | 0x40;
464
+ rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided
465
+
466
+ if (buf) {
467
+ offset = offset || 0;
468
+
469
+ for (var i = 0; i < 16; ++i) {
470
+ buf[offset + i] = rnds[i];
471
+ }
472
+
473
+ return buf;
474
+ }
475
+
476
+ return stringify$1(rnds);
477
+ }
478
+
479
+ // Adapted from Chris Veness' SHA1 code at
480
+ // http://www.movable-type.co.uk/scripts/sha1.html
481
+ function f(s, x, y, z) {
482
+ switch (s) {
483
+ case 0:
484
+ return x & y ^ ~x & z;
485
+
486
+ case 1:
487
+ return x ^ y ^ z;
488
+
489
+ case 2:
490
+ return x & y ^ x & z ^ y & z;
491
+
492
+ case 3:
493
+ return x ^ y ^ z;
494
+ }
495
+ }
496
+
497
+ function ROTL(x, n) {
498
+ return x << n | x >>> 32 - n;
499
+ }
500
+
501
+ function sha1(bytes) {
502
+ var K = [0x5a827999, 0x6ed9eba1, 0x8f1bbcdc, 0xca62c1d6];
503
+ var H = [0x67452301, 0xefcdab89, 0x98badcfe, 0x10325476, 0xc3d2e1f0];
504
+
505
+ if (typeof bytes === 'string') {
506
+ var msg = unescape(encodeURIComponent(bytes)); // UTF8 escape
507
+
508
+ bytes = [];
509
+
510
+ for (var i = 0; i < msg.length; ++i) {
511
+ bytes.push(msg.charCodeAt(i));
512
+ }
513
+ } else if (!Array.isArray(bytes)) {
514
+ // Convert Array-like to Array
515
+ bytes = Array.prototype.slice.call(bytes);
516
+ }
517
+
518
+ bytes.push(0x80);
519
+ var l = bytes.length / 4 + 2;
520
+ var N = Math.ceil(l / 16);
521
+ var M = new Array(N);
522
+
523
+ for (var _i = 0; _i < N; ++_i) {
524
+ var arr = new Uint32Array(16);
525
+
526
+ for (var j = 0; j < 16; ++j) {
527
+ arr[j] = bytes[_i * 64 + j * 4] << 24 | bytes[_i * 64 + j * 4 + 1] << 16 | bytes[_i * 64 + j * 4 + 2] << 8 | bytes[_i * 64 + j * 4 + 3];
528
+ }
529
+
530
+ M[_i] = arr;
531
+ }
532
+
533
+ M[N - 1][14] = (bytes.length - 1) * 8 / Math.pow(2, 32);
534
+ M[N - 1][14] = Math.floor(M[N - 1][14]);
535
+ M[N - 1][15] = (bytes.length - 1) * 8 & 0xffffffff;
536
+
537
+ for (var _i2 = 0; _i2 < N; ++_i2) {
538
+ var W = new Uint32Array(80);
539
+
540
+ for (var t = 0; t < 16; ++t) {
541
+ W[t] = M[_i2][t];
542
+ }
543
+
544
+ for (var _t = 16; _t < 80; ++_t) {
545
+ W[_t] = ROTL(W[_t - 3] ^ W[_t - 8] ^ W[_t - 14] ^ W[_t - 16], 1);
546
+ }
547
+
548
+ var a = H[0];
549
+ var b = H[1];
550
+ var c = H[2];
551
+ var d = H[3];
552
+ var e = H[4];
553
+
554
+ for (var _t2 = 0; _t2 < 80; ++_t2) {
555
+ var s = Math.floor(_t2 / 20);
556
+ var T = ROTL(a, 5) + f(s, b, c, d) + e + K[s] + W[_t2] >>> 0;
557
+ e = d;
558
+ d = c;
559
+ c = ROTL(b, 30) >>> 0;
560
+ b = a;
561
+ a = T;
562
+ }
563
+
564
+ H[0] = H[0] + a >>> 0;
565
+ H[1] = H[1] + b >>> 0;
566
+ H[2] = H[2] + c >>> 0;
567
+ H[3] = H[3] + d >>> 0;
568
+ H[4] = H[4] + e >>> 0;
569
+ }
570
+
571
+ return [H[0] >> 24 & 0xff, H[0] >> 16 & 0xff, H[0] >> 8 & 0xff, H[0] & 0xff, H[1] >> 24 & 0xff, H[1] >> 16 & 0xff, H[1] >> 8 & 0xff, H[1] & 0xff, H[2] >> 24 & 0xff, H[2] >> 16 & 0xff, H[2] >> 8 & 0xff, H[2] & 0xff, H[3] >> 24 & 0xff, H[3] >> 16 & 0xff, H[3] >> 8 & 0xff, H[3] & 0xff, H[4] >> 24 & 0xff, H[4] >> 16 & 0xff, H[4] >> 8 & 0xff, H[4] & 0xff];
572
+ }
573
+
574
+ var v5 = v35('v5', 0x50, sha1);
575
+
576
+ const nil = '00000000-0000-0000-0000-000000000000';
577
+
578
+ function version(uuid) {
579
+ if (!validate(uuid)) {
580
+ throw TypeError('Invalid UUID');
581
+ }
582
+
583
+ return parseInt(uuid.substr(14, 1), 16);
584
+ }
585
+
586
+ 'use strict';
587
+
588
+ /**
589
+ * Check if we're required to add a port number.
590
+ *
591
+ * @see https://url.spec.whatwg.org/#default-port
592
+ * @param {Number|String} port Port number we need to check
593
+ * @param {String} protocol Protocol we need to check against.
594
+ * @returns {Boolean} Is it a default port for the given protocol
595
+ * @api private
596
+ */
597
+ var requiresPort = function required(port, protocol) {
598
+ protocol = protocol.split(':')[0];
599
+ port = +port;
600
+
601
+ if (!port) return false;
602
+
603
+ switch (protocol) {
604
+ case 'http':
605
+ case 'ws':
606
+ return port !== 80;
607
+
608
+ case 'https':
609
+ case 'wss':
610
+ return port !== 443;
611
+
612
+ case 'ftp':
613
+ return port !== 21;
614
+
615
+ case 'gopher':
616
+ return port !== 70;
617
+
618
+ case 'file':
619
+ return false;
620
+ }
621
+
622
+ return port !== 0;
623
+ };
624
+
625
+ 'use strict';
626
+
627
+ var has = Object.prototype.hasOwnProperty
628
+ , undef;
629
+
630
+ /**
631
+ * Decode a URI encoded string.
632
+ *
633
+ * @param {String} input The URI encoded string.
634
+ * @returns {String|Null} The decoded string.
635
+ * @api private
636
+ */
637
+ function decode$1(input) {
638
+ try {
639
+ return decodeURIComponent(input.replace(/\+/g, ' '));
640
+ } catch (e) {
641
+ return null;
642
+ }
643
+ }
644
+
645
+ /**
646
+ * Attempts to encode a given input.
647
+ *
648
+ * @param {String} input The string that needs to be encoded.
649
+ * @returns {String|Null} The encoded string.
650
+ * @api private
651
+ */
652
+ function encode(input) {
653
+ try {
654
+ return encodeURIComponent(input);
655
+ } catch (e) {
656
+ return null;
657
+ }
658
+ }
659
+
660
+ /**
661
+ * Simple query string parser.
662
+ *
663
+ * @param {String} query The query string that needs to be parsed.
664
+ * @returns {Object}
665
+ * @api public
666
+ */
667
+ function querystring(query) {
668
+ var parser = /([^=?#&]+)=?([^&]*)/g
669
+ , result = {}
670
+ , part;
671
+
672
+ while (part = parser.exec(query)) {
673
+ var key = decode$1(part[1])
674
+ , value = decode$1(part[2]);
675
+
676
+ //
677
+ // Prevent overriding of existing properties. This ensures that build-in
678
+ // methods like `toString` or __proto__ are not overriden by malicious
679
+ // querystrings.
680
+ //
681
+ // In the case if failed decoding, we want to omit the key/value pairs
682
+ // from the result.
683
+ //
684
+ if (key === null || value === null || key in result) continue;
685
+ result[key] = value;
686
+ }
687
+
688
+ return result;
689
+ }
690
+
691
+ /**
692
+ * Transform a query string to an object.
693
+ *
694
+ * @param {Object} obj Object that should be transformed.
695
+ * @param {String} prefix Optional prefix.
696
+ * @returns {String}
697
+ * @api public
698
+ */
699
+ function querystringify(obj, prefix) {
700
+ prefix = prefix || '';
701
+
702
+ var pairs = []
703
+ , value
704
+ , key;
705
+
706
+ //
707
+ // Optionally prefix with a '?' if needed
708
+ //
709
+ if ('string' !== typeof prefix) prefix = '?';
710
+
711
+ for (key in obj) {
712
+ if (has.call(obj, key)) {
713
+ value = obj[key];
714
+
715
+ //
716
+ // Edge cases where we actually want to encode the value to an empty
717
+ // string instead of the stringified value.
718
+ //
719
+ if (!value && (value === null || value === undef || isNaN(value))) {
720
+ value = '';
721
+ }
722
+
723
+ key = encode(key);
724
+ value = encode(value);
725
+
726
+ //
727
+ // If we failed to encode the strings, we should bail out as we don't
728
+ // want to add invalid strings to the query.
729
+ //
730
+ if (key === null || value === null) continue;
731
+ pairs.push(key +'='+ value);
732
+ }
733
+ }
734
+
735
+ return pairs.length ? prefix + pairs.join('&') : '';
736
+ }
737
+
738
+ //
739
+ // Expose the module.
740
+ //
741
+ var stringify = querystringify;
742
+ var parse = querystring;
743
+
744
+ var querystringify_1 = {
745
+ stringify: stringify,
746
+ parse: parse
747
+ };
748
+
749
+ 'use strict';
750
+
751
+ var controlOrWhitespace = /^[\x00-\x20\u00a0\u1680\u2000-\u200a\u2028\u2029\u202f\u205f\u3000\ufeff]+/
752
+ , CRHTLF = /[\n\r\t]/g
753
+ , slashes = /^[A-Za-z][A-Za-z0-9+-.]*:\/\//
754
+ , port = /:\d+$/
755
+ , protocolre = /^([a-z][a-z0-9.+-]*:)?(\/\/)?([\\/]+)?([\S\s]*)/i
756
+ , windowsDriveLetter = /^[a-zA-Z]:/;
757
+
758
+ /**
759
+ * Remove control characters and whitespace from the beginning of a string.
760
+ *
761
+ * @param {Object|String} str String to trim.
762
+ * @returns {String} A new string representing `str` stripped of control
763
+ * characters and whitespace from its beginning.
764
+ * @public
765
+ */
766
+ function trimLeft(str) {
767
+ return (str ? str : '').toString().replace(controlOrWhitespace, '');
768
+ }
769
+
770
+ /**
771
+ * These are the parse rules for the URL parser, it informs the parser
772
+ * about:
773
+ *
774
+ * 0. The char it Needs to parse, if it's a string it should be done using
775
+ * indexOf, RegExp using exec and NaN means set as current value.
776
+ * 1. The property we should set when parsing this value.
777
+ * 2. Indication if it's backwards or forward parsing, when set as number it's
778
+ * the value of extra chars that should be split off.
779
+ * 3. Inherit from location if non existing in the parser.
780
+ * 4. `toLowerCase` the resulting value.
781
+ */
782
+ var rules = [
783
+ ['#', 'hash'], // Extract from the back.
784
+ ['?', 'query'], // Extract from the back.
785
+ function sanitize(address, url) { // Sanitize what is left of the address
786
+ return isSpecial(url.protocol) ? address.replace(/\\/g, '/') : address;
787
+ },
788
+ ['/', 'pathname'], // Extract from the back.
789
+ ['@', 'auth', 1], // Extract from the front.
790
+ [NaN, 'host', undefined, 1, 1], // Set left over value.
791
+ [/:(\d*)$/, 'port', undefined, 1], // RegExp the back.
792
+ [NaN, 'hostname', undefined, 1, 1] // Set left over.
793
+ ];
794
+
795
+ /**
796
+ * These properties should not be copied or inherited from. This is only needed
797
+ * for all non blob URL's as a blob URL does not include a hash, only the
798
+ * origin.
799
+ *
800
+ * @type {Object}
801
+ * @private
802
+ */
803
+ var ignore = { hash: 1, query: 1 };
804
+
805
+ /**
806
+ * The location object differs when your code is loaded through a normal page,
807
+ * Worker or through a worker using a blob. And with the blobble begins the
808
+ * trouble as the location object will contain the URL of the blob, not the
809
+ * location of the page where our code is loaded in. The actual origin is
810
+ * encoded in the `pathname` so we can thankfully generate a good "default"
811
+ * location from it so we can generate proper relative URL's again.
812
+ *
813
+ * @param {Object|String} loc Optional default location object.
814
+ * @returns {Object} lolcation object.
815
+ * @public
816
+ */
817
+ function lolcation(loc) {
818
+ var globalVar;
819
+
820
+ if (typeof window !== 'undefined') globalVar = window;
821
+ else if (typeof commonjsGlobal !== 'undefined') globalVar = commonjsGlobal;
822
+ else if (typeof self !== 'undefined') globalVar = self;
823
+ else globalVar = {};
824
+
825
+ var location = globalVar.location || {};
826
+ loc = loc || location;
827
+
828
+ var finaldestination = {}
829
+ , type = typeof loc
830
+ , key;
831
+
832
+ if ('blob:' === loc.protocol) {
833
+ finaldestination = new Url(unescape(loc.pathname), {});
834
+ } else if ('string' === type) {
835
+ finaldestination = new Url(loc, {});
836
+ for (key in ignore) delete finaldestination[key];
837
+ } else if ('object' === type) {
838
+ for (key in loc) {
839
+ if (key in ignore) continue;
840
+ finaldestination[key] = loc[key];
841
+ }
842
+
843
+ if (finaldestination.slashes === undefined) {
844
+ finaldestination.slashes = slashes.test(loc.href);
845
+ }
846
+ }
847
+
848
+ return finaldestination;
849
+ }
850
+
851
+ /**
852
+ * Check whether a protocol scheme is special.
853
+ *
854
+ * @param {String} The protocol scheme of the URL
855
+ * @return {Boolean} `true` if the protocol scheme is special, else `false`
856
+ * @private
857
+ */
858
+ function isSpecial(scheme) {
859
+ return (
860
+ scheme === 'file:' ||
861
+ scheme === 'ftp:' ||
862
+ scheme === 'http:' ||
863
+ scheme === 'https:' ||
864
+ scheme === 'ws:' ||
865
+ scheme === 'wss:'
866
+ );
867
+ }
868
+
869
+ /**
870
+ * @typedef ProtocolExtract
871
+ * @type Object
872
+ * @property {String} protocol Protocol matched in the URL, in lowercase.
873
+ * @property {Boolean} slashes `true` if protocol is followed by "//", else `false`.
874
+ * @property {String} rest Rest of the URL that is not part of the protocol.
875
+ */
876
+
877
+ /**
878
+ * Extract protocol information from a URL with/without double slash ("//").
879
+ *
880
+ * @param {String} address URL we want to extract from.
881
+ * @param {Object} location
882
+ * @return {ProtocolExtract} Extracted information.
883
+ * @private
884
+ */
885
+ function extractProtocol(address, location) {
886
+ address = trimLeft(address);
887
+ address = address.replace(CRHTLF, '');
888
+ location = location || {};
889
+
890
+ var match = protocolre.exec(address);
891
+ var protocol = match[1] ? match[1].toLowerCase() : '';
892
+ var forwardSlashes = !!match[2];
893
+ var otherSlashes = !!match[3];
894
+ var slashesCount = 0;
895
+ var rest;
896
+
897
+ if (forwardSlashes) {
898
+ if (otherSlashes) {
899
+ rest = match[2] + match[3] + match[4];
900
+ slashesCount = match[2].length + match[3].length;
901
+ } else {
902
+ rest = match[2] + match[4];
903
+ slashesCount = match[2].length;
904
+ }
905
+ } else {
906
+ if (otherSlashes) {
907
+ rest = match[3] + match[4];
908
+ slashesCount = match[3].length;
909
+ } else {
910
+ rest = match[4];
911
+ }
912
+ }
913
+
914
+ if (protocol === 'file:') {
915
+ if (slashesCount >= 2) {
916
+ rest = rest.slice(2);
917
+ }
918
+ } else if (isSpecial(protocol)) {
919
+ rest = match[4];
920
+ } else if (protocol) {
921
+ if (forwardSlashes) {
922
+ rest = rest.slice(2);
923
+ }
924
+ } else if (slashesCount >= 2 && isSpecial(location.protocol)) {
925
+ rest = match[4];
926
+ }
927
+
928
+ return {
929
+ protocol: protocol,
930
+ slashes: forwardSlashes || isSpecial(protocol),
931
+ slashesCount: slashesCount,
932
+ rest: rest
933
+ };
934
+ }
935
+
936
+ /**
937
+ * Resolve a relative URL pathname against a base URL pathname.
938
+ *
939
+ * @param {String} relative Pathname of the relative URL.
940
+ * @param {String} base Pathname of the base URL.
941
+ * @return {String} Resolved pathname.
942
+ * @private
943
+ */
944
+ function resolve(relative, base) {
945
+ if (relative === '') return base;
946
+
947
+ var path = (base || '/').split('/').slice(0, -1).concat(relative.split('/'))
948
+ , i = path.length
949
+ , last = path[i - 1]
950
+ , unshift = false
951
+ , up = 0;
952
+
953
+ while (i--) {
954
+ if (path[i] === '.') {
955
+ path.splice(i, 1);
956
+ } else if (path[i] === '..') {
957
+ path.splice(i, 1);
958
+ up++;
959
+ } else if (up) {
960
+ if (i === 0) unshift = true;
961
+ path.splice(i, 1);
962
+ up--;
963
+ }
964
+ }
965
+
966
+ if (unshift) path.unshift('');
967
+ if (last === '.' || last === '..') path.push('');
968
+
969
+ return path.join('/');
970
+ }
971
+
972
+ /**
973
+ * The actual URL instance. Instead of returning an object we've opted-in to
974
+ * create an actual constructor as it's much more memory efficient and
975
+ * faster and it pleases my OCD.
976
+ *
977
+ * It is worth noting that we should not use `URL` as class name to prevent
978
+ * clashes with the global URL instance that got introduced in browsers.
979
+ *
980
+ * @constructor
981
+ * @param {String} address URL we want to parse.
982
+ * @param {Object|String} [location] Location defaults for relative paths.
983
+ * @param {Boolean|Function} [parser] Parser for the query string.
984
+ * @private
985
+ */
986
+ function Url(address, location, parser) {
987
+ address = trimLeft(address);
988
+ address = address.replace(CRHTLF, '');
989
+
990
+ if (!(this instanceof Url)) {
991
+ return new Url(address, location, parser);
992
+ }
993
+
994
+ var relative, extracted, parse, instruction, index, key
995
+ , instructions = rules.slice()
996
+ , type = typeof location
997
+ , url = this
998
+ , i = 0;
999
+
1000
+ //
1001
+ // The following if statements allows this module two have compatibility with
1002
+ // 2 different API:
1003
+ //
1004
+ // 1. Node.js's `url.parse` api which accepts a URL, boolean as arguments
1005
+ // where the boolean indicates that the query string should also be parsed.
1006
+ //
1007
+ // 2. The `URL` interface of the browser which accepts a URL, object as
1008
+ // arguments. The supplied object will be used as default values / fall-back
1009
+ // for relative paths.
1010
+ //
1011
+ if ('object' !== type && 'string' !== type) {
1012
+ parser = location;
1013
+ location = null;
1014
+ }
1015
+
1016
+ if (parser && 'function' !== typeof parser) parser = querystringify_1.parse;
1017
+
1018
+ location = lolcation(location);
1019
+
1020
+ //
1021
+ // Extract protocol information before running the instructions.
1022
+ //
1023
+ extracted = extractProtocol(address || '', location);
1024
+ relative = !extracted.protocol && !extracted.slashes;
1025
+ url.slashes = extracted.slashes || relative && location.slashes;
1026
+ url.protocol = extracted.protocol || location.protocol || '';
1027
+ address = extracted.rest;
1028
+
1029
+ //
1030
+ // When the authority component is absent the URL starts with a path
1031
+ // component.
1032
+ //
1033
+ if (
1034
+ extracted.protocol === 'file:' && (
1035
+ extracted.slashesCount !== 2 || windowsDriveLetter.test(address)) ||
1036
+ (!extracted.slashes &&
1037
+ (extracted.protocol ||
1038
+ extracted.slashesCount < 2 ||
1039
+ !isSpecial(url.protocol)))
1040
+ ) {
1041
+ instructions[3] = [/(.*)/, 'pathname'];
1042
+ }
1043
+
1044
+ for (; i < instructions.length; i++) {
1045
+ instruction = instructions[i];
1046
+
1047
+ if (typeof instruction === 'function') {
1048
+ address = instruction(address, url);
1049
+ continue;
1050
+ }
1051
+
1052
+ parse = instruction[0];
1053
+ key = instruction[1];
1054
+
1055
+ if (parse !== parse) {
1056
+ url[key] = address;
1057
+ } else if ('string' === typeof parse) {
1058
+ index = parse === '@'
1059
+ ? address.lastIndexOf(parse)
1060
+ : address.indexOf(parse);
1061
+
1062
+ if (~index) {
1063
+ if ('number' === typeof instruction[2]) {
1064
+ url[key] = address.slice(0, index);
1065
+ address = address.slice(index + instruction[2]);
1066
+ } else {
1067
+ url[key] = address.slice(index);
1068
+ address = address.slice(0, index);
1069
+ }
1070
+ }
1071
+ } else if ((index = parse.exec(address))) {
1072
+ url[key] = index[1];
1073
+ address = address.slice(0, index.index);
1074
+ }
1075
+
1076
+ url[key] = url[key] || (
1077
+ relative && instruction[3] ? location[key] || '' : ''
1078
+ );
1079
+
1080
+ //
1081
+ // Hostname, host and protocol should be lowercased so they can be used to
1082
+ // create a proper `origin`.
1083
+ //
1084
+ if (instruction[4]) url[key] = url[key].toLowerCase();
1085
+ }
1086
+
1087
+ //
1088
+ // Also parse the supplied query string in to an object. If we're supplied
1089
+ // with a custom parser as function use that instead of the default build-in
1090
+ // parser.
1091
+ //
1092
+ if (parser) url.query = parser(url.query);
1093
+
1094
+ //
1095
+ // If the URL is relative, resolve the pathname against the base URL.
1096
+ //
1097
+ if (
1098
+ relative
1099
+ && location.slashes
1100
+ && url.pathname.charAt(0) !== '/'
1101
+ && (url.pathname !== '' || location.pathname !== '')
1102
+ ) {
1103
+ url.pathname = resolve(url.pathname, location.pathname);
1104
+ }
1105
+
1106
+ //
1107
+ // Default to a / for pathname if none exists. This normalizes the URL
1108
+ // to always have a /
1109
+ //
1110
+ if (url.pathname.charAt(0) !== '/' && isSpecial(url.protocol)) {
1111
+ url.pathname = '/' + url.pathname;
1112
+ }
1113
+
1114
+ //
1115
+ // We should not add port numbers if they are already the default port number
1116
+ // for a given protocol. As the host also contains the port number we're going
1117
+ // override it with the hostname which contains no port number.
1118
+ //
1119
+ if (!requiresPort(url.port, url.protocol)) {
1120
+ url.host = url.hostname;
1121
+ url.port = '';
1122
+ }
1123
+
1124
+ //
1125
+ // Parse down the `auth` for the username and password.
1126
+ //
1127
+ url.username = url.password = '';
1128
+
1129
+ if (url.auth) {
1130
+ index = url.auth.indexOf(':');
1131
+
1132
+ if (~index) {
1133
+ url.username = url.auth.slice(0, index);
1134
+ url.username = encodeURIComponent(decodeURIComponent(url.username));
1135
+
1136
+ url.password = url.auth.slice(index + 1);
1137
+ url.password = encodeURIComponent(decodeURIComponent(url.password));
1138
+ } else {
1139
+ url.username = encodeURIComponent(decodeURIComponent(url.auth));
1140
+ }
1141
+
1142
+ url.auth = url.password ? url.username +':'+ url.password : url.username;
1143
+ }
1144
+
1145
+ url.origin = url.protocol !== 'file:' && isSpecial(url.protocol) && url.host
1146
+ ? url.protocol +'//'+ url.host
1147
+ : 'null';
1148
+
1149
+ //
1150
+ // The href is just the compiled result.
1151
+ //
1152
+ url.href = url.toString();
1153
+ }
1154
+
1155
+ /**
1156
+ * This is convenience method for changing properties in the URL instance to
1157
+ * insure that they all propagate correctly.
1158
+ *
1159
+ * @param {String} part Property we need to adjust.
1160
+ * @param {Mixed} value The newly assigned value.
1161
+ * @param {Boolean|Function} fn When setting the query, it will be the function
1162
+ * used to parse the query.
1163
+ * When setting the protocol, double slash will be
1164
+ * removed from the final url if it is true.
1165
+ * @returns {URL} URL instance for chaining.
1166
+ * @public
1167
+ */
1168
+ function set(part, value, fn) {
1169
+ var url = this;
1170
+
1171
+ switch (part) {
1172
+ case 'query':
1173
+ if ('string' === typeof value && value.length) {
1174
+ value = (fn || querystringify_1.parse)(value);
1175
+ }
1176
+
1177
+ url[part] = value;
1178
+ break;
1179
+
1180
+ case 'port':
1181
+ url[part] = value;
1182
+
1183
+ if (!requiresPort(value, url.protocol)) {
1184
+ url.host = url.hostname;
1185
+ url[part] = '';
1186
+ } else if (value) {
1187
+ url.host = url.hostname +':'+ value;
1188
+ }
1189
+
1190
+ break;
1191
+
1192
+ case 'hostname':
1193
+ url[part] = value;
1194
+
1195
+ if (url.port) value += ':'+ url.port;
1196
+ url.host = value;
1197
+ break;
1198
+
1199
+ case 'host':
1200
+ url[part] = value;
1201
+
1202
+ if (port.test(value)) {
1203
+ value = value.split(':');
1204
+ url.port = value.pop();
1205
+ url.hostname = value.join(':');
1206
+ } else {
1207
+ url.hostname = value;
1208
+ url.port = '';
1209
+ }
1210
+
1211
+ break;
1212
+
1213
+ case 'protocol':
1214
+ url.protocol = value.toLowerCase();
1215
+ url.slashes = !fn;
1216
+ break;
1217
+
1218
+ case 'pathname':
1219
+ case 'hash':
1220
+ if (value) {
1221
+ var char = part === 'pathname' ? '/' : '#';
1222
+ url[part] = value.charAt(0) !== char ? char + value : value;
1223
+ } else {
1224
+ url[part] = value;
1225
+ }
1226
+ break;
1227
+
1228
+ case 'username':
1229
+ case 'password':
1230
+ url[part] = encodeURIComponent(value);
1231
+ break;
1232
+
1233
+ case 'auth':
1234
+ var index = value.indexOf(':');
1235
+
1236
+ if (~index) {
1237
+ url.username = value.slice(0, index);
1238
+ url.username = encodeURIComponent(decodeURIComponent(url.username));
1239
+
1240
+ url.password = value.slice(index + 1);
1241
+ url.password = encodeURIComponent(decodeURIComponent(url.password));
1242
+ } else {
1243
+ url.username = encodeURIComponent(decodeURIComponent(value));
1244
+ }
1245
+ }
1246
+
1247
+ for (var i = 0; i < rules.length; i++) {
1248
+ var ins = rules[i];
1249
+
1250
+ if (ins[4]) url[ins[1]] = url[ins[1]].toLowerCase();
1251
+ }
1252
+
1253
+ url.auth = url.password ? url.username +':'+ url.password : url.username;
1254
+
1255
+ url.origin = url.protocol !== 'file:' && isSpecial(url.protocol) && url.host
1256
+ ? url.protocol +'//'+ url.host
1257
+ : 'null';
1258
+
1259
+ url.href = url.toString();
1260
+
1261
+ return url;
1262
+ }
1263
+
1264
+ /**
1265
+ * Transform the properties back in to a valid and full URL string.
1266
+ *
1267
+ * @param {Function} stringify Optional query stringify function.
1268
+ * @returns {String} Compiled version of the URL.
1269
+ * @public
1270
+ */
1271
+ function toString(stringify) {
1272
+ if (!stringify || 'function' !== typeof stringify) stringify = querystringify_1.stringify;
1273
+
1274
+ var query
1275
+ , url = this
1276
+ , host = url.host
1277
+ , protocol = url.protocol;
1278
+
1279
+ if (protocol && protocol.charAt(protocol.length - 1) !== ':') protocol += ':';
1280
+
1281
+ var result =
1282
+ protocol +
1283
+ ((url.protocol && url.slashes) || isSpecial(url.protocol) ? '//' : '');
1284
+
1285
+ if (url.username) {
1286
+ result += url.username;
1287
+ if (url.password) result += ':'+ url.password;
1288
+ result += '@';
1289
+ } else if (url.password) {
1290
+ result += ':'+ url.password;
1291
+ result += '@';
1292
+ } else if (
1293
+ url.protocol !== 'file:' &&
1294
+ isSpecial(url.protocol) &&
1295
+ !host &&
1296
+ url.pathname !== '/'
1297
+ ) {
1298
+ //
1299
+ // Add back the empty userinfo, otherwise the original invalid URL
1300
+ // might be transformed into a valid one with `url.pathname` as host.
1301
+ //
1302
+ result += '@';
1303
+ }
1304
+
1305
+ //
1306
+ // Trailing colon is removed from `url.host` when it is parsed. If it still
1307
+ // ends with a colon, then add back the trailing colon that was removed. This
1308
+ // prevents an invalid URL from being transformed into a valid one.
1309
+ //
1310
+ if (host[host.length - 1] === ':' || (port.test(url.hostname) && !url.port)) {
1311
+ host += ':';
1312
+ }
1313
+
1314
+ result += host + url.pathname;
1315
+
1316
+ query = 'object' === typeof url.query ? stringify(url.query) : url.query;
1317
+ if (query) result += '?' !== query.charAt(0) ? '?'+ query : query;
1318
+
1319
+ if (url.hash) result += url.hash;
1320
+
1321
+ return result;
1322
+ }
1323
+
1324
+ Url.prototype = { set: set, toString: toString };
1325
+
1326
+ //
1327
+ // Expose the URL parser and some additional properties that might be useful for
1328
+ // others or testing.
1329
+ //
1330
+ Url.extractProtocol = extractProtocol;
1331
+ Url.location = lolcation;
1332
+ Url.trimLeft = trimLeft;
1333
+ Url.qs = querystringify_1;
1334
+
1335
+ var urlParse = Url;
1336
+
1337
+ var rxjsStub = createCommonjsModule(function (module, exports) {
1338
+ "use strict";
1339
+ Object.defineProperty(exports, "__esModule", { value: true });
1340
+ exports.map = exports.mergeMap = exports.of = exports.from = exports.Observable = void 0;
1341
+ var Observable = (function () {
1342
+ function Observable(promise) {
1343
+ this.promise = promise;
1344
+ }
1345
+ Observable.prototype.toPromise = function () {
1346
+ return this.promise;
1347
+ };
1348
+ Observable.prototype.pipe = function (callback) {
1349
+ return new Observable(this.promise.then(callback));
1350
+ };
1351
+ return Observable;
1352
+ }());
1353
+ exports.Observable = Observable;
1354
+ function from(promise) {
1355
+ return new Observable(promise);
1356
+ }
1357
+ exports.from = from;
1358
+ function of(value) {
1359
+ return new Observable(Promise.resolve(value));
1360
+ }
1361
+ exports.of = of;
1362
+ function mergeMap(callback) {
1363
+ return function (value) { return callback(value).toPromise(); };
1364
+ }
1365
+ exports.mergeMap = mergeMap;
1366
+ function map(callback) {
1367
+ return callback;
1368
+ }
1369
+ exports.map = map;
1370
+ //# sourceMappingURL=rxjsStub.js.map
1371
+ });
1372
+
1373
+ const rxjsStub$1 = /*@__PURE__*/getDefaultExportFromCjs(rxjsStub);
1374
+
1375
+ var global =
1376
+ (typeof globalThis !== 'undefined' && globalThis) ||
1377
+ (typeof self !== 'undefined' && self) ||
1378
+ (typeof global !== 'undefined' && global);
1379
+
1380
+ var support = {
1381
+ searchParams: 'URLSearchParams' in global,
1382
+ iterable: 'Symbol' in global && 'iterator' in Symbol,
1383
+ blob:
1384
+ 'FileReader' in global &&
1385
+ 'Blob' in global &&
1386
+ (function() {
1387
+ try {
1388
+ new Blob();
1389
+ return true
1390
+ } catch (e) {
1391
+ return false
1392
+ }
1393
+ })(),
1394
+ formData: 'FormData' in global,
1395
+ arrayBuffer: 'ArrayBuffer' in global
1396
+ };
1397
+
1398
+ function isDataView(obj) {
1399
+ return obj && DataView.prototype.isPrototypeOf(obj)
1400
+ }
1401
+
1402
+ if (support.arrayBuffer) {
1403
+ var viewClasses = [
1404
+ '[object Int8Array]',
1405
+ '[object Uint8Array]',
1406
+ '[object Uint8ClampedArray]',
1407
+ '[object Int16Array]',
1408
+ '[object Uint16Array]',
1409
+ '[object Int32Array]',
1410
+ '[object Uint32Array]',
1411
+ '[object Float32Array]',
1412
+ '[object Float64Array]'
1413
+ ];
1414
+
1415
+ var isArrayBufferView =
1416
+ ArrayBuffer.isView ||
1417
+ function(obj) {
1418
+ return obj && viewClasses.indexOf(Object.prototype.toString.call(obj)) > -1
1419
+ };
1420
+ }
1421
+
1422
+ function normalizeName(name) {
1423
+ if (typeof name !== 'string') {
1424
+ name = String(name);
1425
+ }
1426
+ if (/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(name) || name === '') {
1427
+ throw new TypeError('Invalid character in header field name: "' + name + '"')
1428
+ }
1429
+ return name.toLowerCase()
1430
+ }
1431
+
1432
+ function normalizeValue(value) {
1433
+ if (typeof value !== 'string') {
1434
+ value = String(value);
1435
+ }
1436
+ return value
1437
+ }
1438
+
1439
+ // Build a destructive iterator for the value list
1440
+ function iteratorFor(items) {
1441
+ var iterator = {
1442
+ next: function() {
1443
+ var value = items.shift();
1444
+ return {done: value === undefined, value: value}
1445
+ }
1446
+ };
1447
+
1448
+ if (support.iterable) {
1449
+ iterator[Symbol.iterator] = function() {
1450
+ return iterator
1451
+ };
1452
+ }
1453
+
1454
+ return iterator
1455
+ }
1456
+
1457
+ function Headers(headers) {
1458
+ this.map = {};
1459
+
1460
+ if (headers instanceof Headers) {
1461
+ headers.forEach(function(value, name) {
1462
+ this.append(name, value);
1463
+ }, this);
1464
+ } else if (Array.isArray(headers)) {
1465
+ headers.forEach(function(header) {
1466
+ this.append(header[0], header[1]);
1467
+ }, this);
1468
+ } else if (headers) {
1469
+ Object.getOwnPropertyNames(headers).forEach(function(name) {
1470
+ this.append(name, headers[name]);
1471
+ }, this);
1472
+ }
1473
+ }
1474
+
1475
+ Headers.prototype.append = function(name, value) {
1476
+ name = normalizeName(name);
1477
+ value = normalizeValue(value);
1478
+ var oldValue = this.map[name];
1479
+ this.map[name] = oldValue ? oldValue + ', ' + value : value;
1480
+ };
1481
+
1482
+ Headers.prototype['delete'] = function(name) {
1483
+ delete this.map[normalizeName(name)];
1484
+ };
1485
+
1486
+ Headers.prototype.get = function(name) {
1487
+ name = normalizeName(name);
1488
+ return this.has(name) ? this.map[name] : null
1489
+ };
1490
+
1491
+ Headers.prototype.has = function(name) {
1492
+ return this.map.hasOwnProperty(normalizeName(name))
1493
+ };
1494
+
1495
+ Headers.prototype.set = function(name, value) {
1496
+ this.map[normalizeName(name)] = normalizeValue(value);
1497
+ };
1498
+
1499
+ Headers.prototype.forEach = function(callback, thisArg) {
1500
+ for (var name in this.map) {
1501
+ if (this.map.hasOwnProperty(name)) {
1502
+ callback.call(thisArg, this.map[name], name, this);
1503
+ }
1504
+ }
1505
+ };
1506
+
1507
+ Headers.prototype.keys = function() {
1508
+ var items = [];
1509
+ this.forEach(function(value, name) {
1510
+ items.push(name);
1511
+ });
1512
+ return iteratorFor(items)
1513
+ };
1514
+
1515
+ Headers.prototype.values = function() {
1516
+ var items = [];
1517
+ this.forEach(function(value) {
1518
+ items.push(value);
1519
+ });
1520
+ return iteratorFor(items)
1521
+ };
1522
+
1523
+ Headers.prototype.entries = function() {
1524
+ var items = [];
1525
+ this.forEach(function(value, name) {
1526
+ items.push([name, value]);
1527
+ });
1528
+ return iteratorFor(items)
1529
+ };
1530
+
1531
+ if (support.iterable) {
1532
+ Headers.prototype[Symbol.iterator] = Headers.prototype.entries;
1533
+ }
1534
+
1535
+ function consumed(body) {
1536
+ if (body.bodyUsed) {
1537
+ return Promise.reject(new TypeError('Already read'))
1538
+ }
1539
+ body.bodyUsed = true;
1540
+ }
1541
+
1542
+ function fileReaderReady(reader) {
1543
+ return new Promise(function(resolve, reject) {
1544
+ reader.onload = function() {
1545
+ resolve(reader.result);
1546
+ };
1547
+ reader.onerror = function() {
1548
+ reject(reader.error);
1549
+ };
1550
+ })
1551
+ }
1552
+
1553
+ function readBlobAsArrayBuffer(blob) {
1554
+ var reader = new FileReader();
1555
+ var promise = fileReaderReady(reader);
1556
+ reader.readAsArrayBuffer(blob);
1557
+ return promise
1558
+ }
1559
+
1560
+ function readBlobAsText(blob) {
1561
+ var reader = new FileReader();
1562
+ var promise = fileReaderReady(reader);
1563
+ reader.readAsText(blob);
1564
+ return promise
1565
+ }
1566
+
1567
+ function readArrayBufferAsText(buf) {
1568
+ var view = new Uint8Array(buf);
1569
+ var chars = new Array(view.length);
1570
+
1571
+ for (var i = 0; i < view.length; i++) {
1572
+ chars[i] = String.fromCharCode(view[i]);
1573
+ }
1574
+ return chars.join('')
1575
+ }
1576
+
1577
+ function bufferClone(buf) {
1578
+ if (buf.slice) {
1579
+ return buf.slice(0)
1580
+ } else {
1581
+ var view = new Uint8Array(buf.byteLength);
1582
+ view.set(new Uint8Array(buf));
1583
+ return view.buffer
1584
+ }
1585
+ }
1586
+
1587
+ function Body() {
1588
+ this.bodyUsed = false;
1589
+
1590
+ this._initBody = function(body) {
1591
+ /*
1592
+ fetch-mock wraps the Response object in an ES6 Proxy to
1593
+ provide useful test harness features such as flush. However, on
1594
+ ES5 browsers without fetch or Proxy support pollyfills must be used;
1595
+ the proxy-pollyfill is unable to proxy an attribute unless it exists
1596
+ on the object before the Proxy is created. This change ensures
1597
+ Response.bodyUsed exists on the instance, while maintaining the
1598
+ semantic of setting Request.bodyUsed in the constructor before
1599
+ _initBody is called.
1600
+ */
1601
+ this.bodyUsed = this.bodyUsed;
1602
+ this._bodyInit = body;
1603
+ if (!body) {
1604
+ this._bodyText = '';
1605
+ } else if (typeof body === 'string') {
1606
+ this._bodyText = body;
1607
+ } else if (support.blob && Blob.prototype.isPrototypeOf(body)) {
1608
+ this._bodyBlob = body;
1609
+ } else if (support.formData && FormData.prototype.isPrototypeOf(body)) {
1610
+ this._bodyFormData = body;
1611
+ } else if (support.searchParams && URLSearchParams.prototype.isPrototypeOf(body)) {
1612
+ this._bodyText = body.toString();
1613
+ } else if (support.arrayBuffer && support.blob && isDataView(body)) {
1614
+ this._bodyArrayBuffer = bufferClone(body.buffer);
1615
+ // IE 10-11 can't handle a DataView body.
1616
+ this._bodyInit = new Blob([this._bodyArrayBuffer]);
1617
+ } else if (support.arrayBuffer && (ArrayBuffer.prototype.isPrototypeOf(body) || isArrayBufferView(body))) {
1618
+ this._bodyArrayBuffer = bufferClone(body);
1619
+ } else {
1620
+ this._bodyText = body = Object.prototype.toString.call(body);
1621
+ }
1622
+
1623
+ if (!this.headers.get('content-type')) {
1624
+ if (typeof body === 'string') {
1625
+ this.headers.set('content-type', 'text/plain;charset=UTF-8');
1626
+ } else if (this._bodyBlob && this._bodyBlob.type) {
1627
+ this.headers.set('content-type', this._bodyBlob.type);
1628
+ } else if (support.searchParams && URLSearchParams.prototype.isPrototypeOf(body)) {
1629
+ this.headers.set('content-type', 'application/x-www-form-urlencoded;charset=UTF-8');
1630
+ }
1631
+ }
1632
+ };
1633
+
1634
+ if (support.blob) {
1635
+ this.blob = function() {
1636
+ var rejected = consumed(this);
1637
+ if (rejected) {
1638
+ return rejected
1639
+ }
1640
+
1641
+ if (this._bodyBlob) {
1642
+ return Promise.resolve(this._bodyBlob)
1643
+ } else if (this._bodyArrayBuffer) {
1644
+ return Promise.resolve(new Blob([this._bodyArrayBuffer]))
1645
+ } else if (this._bodyFormData) {
1646
+ throw new Error('could not read FormData body as blob')
1647
+ } else {
1648
+ return Promise.resolve(new Blob([this._bodyText]))
1649
+ }
1650
+ };
1651
+
1652
+ this.arrayBuffer = function() {
1653
+ if (this._bodyArrayBuffer) {
1654
+ var isConsumed = consumed(this);
1655
+ if (isConsumed) {
1656
+ return isConsumed
1657
+ }
1658
+ if (ArrayBuffer.isView(this._bodyArrayBuffer)) {
1659
+ return Promise.resolve(
1660
+ this._bodyArrayBuffer.buffer.slice(
1661
+ this._bodyArrayBuffer.byteOffset,
1662
+ this._bodyArrayBuffer.byteOffset + this._bodyArrayBuffer.byteLength
1663
+ )
1664
+ )
1665
+ } else {
1666
+ return Promise.resolve(this._bodyArrayBuffer)
1667
+ }
1668
+ } else {
1669
+ return this.blob().then(readBlobAsArrayBuffer)
1670
+ }
1671
+ };
1672
+ }
1673
+
1674
+ this.text = function() {
1675
+ var rejected = consumed(this);
1676
+ if (rejected) {
1677
+ return rejected
1678
+ }
1679
+
1680
+ if (this._bodyBlob) {
1681
+ return readBlobAsText(this._bodyBlob)
1682
+ } else if (this._bodyArrayBuffer) {
1683
+ return Promise.resolve(readArrayBufferAsText(this._bodyArrayBuffer))
1684
+ } else if (this._bodyFormData) {
1685
+ throw new Error('could not read FormData body as text')
1686
+ } else {
1687
+ return Promise.resolve(this._bodyText)
1688
+ }
1689
+ };
1690
+
1691
+ if (support.formData) {
1692
+ this.formData = function() {
1693
+ return this.text().then(decode)
1694
+ };
1695
+ }
1696
+
1697
+ this.json = function() {
1698
+ return this.text().then(JSON.parse)
1699
+ };
1700
+
1701
+ return this
1702
+ }
1703
+
1704
+ // HTTP methods whose capitalization should be normalized
1705
+ var methods = ['DELETE', 'GET', 'HEAD', 'OPTIONS', 'POST', 'PUT'];
1706
+
1707
+ function normalizeMethod(method) {
1708
+ var upcased = method.toUpperCase();
1709
+ return methods.indexOf(upcased) > -1 ? upcased : method
1710
+ }
1711
+
1712
+ function Request(input, options) {
1713
+ if (!(this instanceof Request)) {
1714
+ throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.')
1715
+ }
1716
+
1717
+ options = options || {};
1718
+ var body = options.body;
1719
+
1720
+ if (input instanceof Request) {
1721
+ if (input.bodyUsed) {
1722
+ throw new TypeError('Already read')
1723
+ }
1724
+ this.url = input.url;
1725
+ this.credentials = input.credentials;
1726
+ if (!options.headers) {
1727
+ this.headers = new Headers(input.headers);
1728
+ }
1729
+ this.method = input.method;
1730
+ this.mode = input.mode;
1731
+ this.signal = input.signal;
1732
+ if (!body && input._bodyInit != null) {
1733
+ body = input._bodyInit;
1734
+ input.bodyUsed = true;
1735
+ }
1736
+ } else {
1737
+ this.url = String(input);
1738
+ }
1739
+
1740
+ this.credentials = options.credentials || this.credentials || 'same-origin';
1741
+ if (options.headers || !this.headers) {
1742
+ this.headers = new Headers(options.headers);
1743
+ }
1744
+ this.method = normalizeMethod(options.method || this.method || 'GET');
1745
+ this.mode = options.mode || this.mode || null;
1746
+ this.signal = options.signal || this.signal;
1747
+ this.referrer = null;
1748
+
1749
+ if ((this.method === 'GET' || this.method === 'HEAD') && body) {
1750
+ throw new TypeError('Body not allowed for GET or HEAD requests')
1751
+ }
1752
+ this._initBody(body);
1753
+
1754
+ if (this.method === 'GET' || this.method === 'HEAD') {
1755
+ if (options.cache === 'no-store' || options.cache === 'no-cache') {
1756
+ // Search for a '_' parameter in the query string
1757
+ var reParamSearch = /([?&])_=[^&]*/;
1758
+ if (reParamSearch.test(this.url)) {
1759
+ // If it already exists then set the value with the current time
1760
+ this.url = this.url.replace(reParamSearch, '$1_=' + new Date().getTime());
1761
+ } else {
1762
+ // Otherwise add a new '_' parameter to the end with the current time
1763
+ var reQueryString = /\?/;
1764
+ this.url += (reQueryString.test(this.url) ? '&' : '?') + '_=' + new Date().getTime();
1765
+ }
1766
+ }
1767
+ }
1768
+ }
1769
+
1770
+ Request.prototype.clone = function() {
1771
+ return new Request(this, {body: this._bodyInit})
1772
+ };
1773
+
1774
+ function decode(body) {
1775
+ var form = new FormData();
1776
+ body
1777
+ .trim()
1778
+ .split('&')
1779
+ .forEach(function(bytes) {
1780
+ if (bytes) {
1781
+ var split = bytes.split('=');
1782
+ var name = split.shift().replace(/\+/g, ' ');
1783
+ var value = split.join('=').replace(/\+/g, ' ');
1784
+ form.append(decodeURIComponent(name), decodeURIComponent(value));
1785
+ }
1786
+ });
1787
+ return form
1788
+ }
1789
+
1790
+ function parseHeaders(rawHeaders) {
1791
+ var headers = new Headers();
1792
+ // Replace instances of \r\n and \n followed by at least one space or horizontal tab with a space
1793
+ // https://tools.ietf.org/html/rfc7230#section-3.2
1794
+ var preProcessedHeaders = rawHeaders.replace(/\r?\n[\t ]+/g, ' ');
1795
+ // Avoiding split via regex to work around a common IE11 bug with the core-js 3.6.0 regex polyfill
1796
+ // https://github.com/github/fetch/issues/748
1797
+ // https://github.com/zloirock/core-js/issues/751
1798
+ preProcessedHeaders
1799
+ .split('\r')
1800
+ .map(function(header) {
1801
+ return header.indexOf('\n') === 0 ? header.substr(1, header.length) : header
1802
+ })
1803
+ .forEach(function(line) {
1804
+ var parts = line.split(':');
1805
+ var key = parts.shift().trim();
1806
+ if (key) {
1807
+ var value = parts.join(':').trim();
1808
+ headers.append(key, value);
1809
+ }
1810
+ });
1811
+ return headers
1812
+ }
1813
+
1814
+ Body.call(Request.prototype);
1815
+
1816
+ function Response(bodyInit, options) {
1817
+ if (!(this instanceof Response)) {
1818
+ throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.')
1819
+ }
1820
+ if (!options) {
1821
+ options = {};
1822
+ }
1823
+
1824
+ this.type = 'default';
1825
+ this.status = options.status === undefined ? 200 : options.status;
1826
+ this.ok = this.status >= 200 && this.status < 300;
1827
+ this.statusText = options.statusText === undefined ? '' : '' + options.statusText;
1828
+ this.headers = new Headers(options.headers);
1829
+ this.url = options.url || '';
1830
+ this._initBody(bodyInit);
1831
+ }
1832
+
1833
+ Body.call(Response.prototype);
1834
+
1835
+ Response.prototype.clone = function() {
1836
+ return new Response(this._bodyInit, {
1837
+ status: this.status,
1838
+ statusText: this.statusText,
1839
+ headers: new Headers(this.headers),
1840
+ url: this.url
1841
+ })
1842
+ };
1843
+
1844
+ Response.error = function() {
1845
+ var response = new Response(null, {status: 0, statusText: ''});
1846
+ response.type = 'error';
1847
+ return response
1848
+ };
1849
+
1850
+ var redirectStatuses = [301, 302, 303, 307, 308];
1851
+
1852
+ Response.redirect = function(url, status) {
1853
+ if (redirectStatuses.indexOf(status) === -1) {
1854
+ throw new RangeError('Invalid status code')
1855
+ }
1856
+
1857
+ return new Response(null, {status: status, headers: {location: url}})
1858
+ };
1859
+
1860
+ var DOMException = global.DOMException;
1861
+ try {
1862
+ new DOMException();
1863
+ } catch (err) {
1864
+ DOMException = function(message, name) {
1865
+ this.message = message;
1866
+ this.name = name;
1867
+ var error = Error(message);
1868
+ this.stack = error.stack;
1869
+ };
1870
+ DOMException.prototype = Object.create(Error.prototype);
1871
+ DOMException.prototype.constructor = DOMException;
1872
+ }
1873
+
1874
+ function fetch$2(input, init) {
1875
+ return new Promise(function(resolve, reject) {
1876
+ var request = new Request(input, init);
1877
+
1878
+ if (request.signal && request.signal.aborted) {
1879
+ return reject(new DOMException('Aborted', 'AbortError'))
1880
+ }
1881
+
1882
+ var xhr = new XMLHttpRequest();
1883
+
1884
+ function abortXhr() {
1885
+ xhr.abort();
1886
+ }
1887
+
1888
+ xhr.onload = function() {
1889
+ var options = {
1890
+ status: xhr.status,
1891
+ statusText: xhr.statusText,
1892
+ headers: parseHeaders(xhr.getAllResponseHeaders() || '')
1893
+ };
1894
+ options.url = 'responseURL' in xhr ? xhr.responseURL : options.headers.get('X-Request-URL');
1895
+ var body = 'response' in xhr ? xhr.response : xhr.responseText;
1896
+ setTimeout(function() {
1897
+ resolve(new Response(body, options));
1898
+ }, 0);
1899
+ };
1900
+
1901
+ xhr.onerror = function() {
1902
+ setTimeout(function() {
1903
+ reject(new TypeError('Network request failed'));
1904
+ }, 0);
1905
+ };
1906
+
1907
+ xhr.ontimeout = function() {
1908
+ setTimeout(function() {
1909
+ reject(new TypeError('Network request failed'));
1910
+ }, 0);
1911
+ };
1912
+
1913
+ xhr.onabort = function() {
1914
+ setTimeout(function() {
1915
+ reject(new DOMException('Aborted', 'AbortError'));
1916
+ }, 0);
1917
+ };
1918
+
1919
+ function fixUrl(url) {
1920
+ try {
1921
+ return url === '' && global.location.href ? global.location.href : url
1922
+ } catch (e) {
1923
+ return url
1924
+ }
1925
+ }
1926
+
1927
+ xhr.open(request.method, fixUrl(request.url), true);
1928
+
1929
+ if (request.credentials === 'include') {
1930
+ xhr.withCredentials = true;
1931
+ } else if (request.credentials === 'omit') {
1932
+ xhr.withCredentials = false;
1933
+ }
1934
+
1935
+ if ('responseType' in xhr) {
1936
+ if (support.blob) {
1937
+ xhr.responseType = 'blob';
1938
+ } else if (
1939
+ support.arrayBuffer &&
1940
+ request.headers.get('Content-Type') &&
1941
+ request.headers.get('Content-Type').indexOf('application/octet-stream') !== -1
1942
+ ) {
1943
+ xhr.responseType = 'arraybuffer';
1944
+ }
1945
+ }
1946
+
1947
+ if (init && typeof init.headers === 'object' && !(init.headers instanceof Headers)) {
1948
+ Object.getOwnPropertyNames(init.headers).forEach(function(name) {
1949
+ xhr.setRequestHeader(name, normalizeValue(init.headers[name]));
1950
+ });
1951
+ } else {
1952
+ request.headers.forEach(function(value, name) {
1953
+ xhr.setRequestHeader(name, value);
1954
+ });
1955
+ }
1956
+
1957
+ if (request.signal) {
1958
+ request.signal.addEventListener('abort', abortXhr);
1959
+
1960
+ xhr.onreadystatechange = function() {
1961
+ // DONE (success or failure)
1962
+ if (xhr.readyState === 4) {
1963
+ request.signal.removeEventListener('abort', abortXhr);
1964
+ }
1965
+ };
1966
+ }
1967
+
1968
+ xhr.send(typeof request._bodyInit === 'undefined' ? null : request._bodyInit);
1969
+ })
1970
+ }
1971
+
1972
+ fetch$2.polyfill = true;
1973
+
1974
+ if (!global.fetch) {
1975
+ global.fetch = fetch$2;
1976
+ global.Headers = Headers;
1977
+ global.Request = Request;
1978
+ global.Response = Response;
1979
+ }
1980
+
1981
+ const fetch$3 = /*#__PURE__*/Object.freeze({
1982
+ __proto__: null,
1983
+ Headers: Headers,
1984
+ Request: Request,
1985
+ Response: Response,
1986
+ get DOMException () { return DOMException; },
1987
+ fetch: fetch$2
1988
+ });
1989
+
1990
+ const fetch$1 = /*@__PURE__*/getAugmentedNamespace(fetch$3);
1991
+
1992
+ var isomorphicFetch = createCommonjsModule(function (module, exports) {
1993
+ "use strict";
1994
+ Object.defineProperty(exports, "__esModule", { value: true });
1995
+ exports.IsomorphicFetchHttpLibrary = void 0;
1996
+
1997
+
1998
+
1999
+ var IsomorphicFetchHttpLibrary = (function () {
2000
+ function IsomorphicFetchHttpLibrary() {
2001
+ }
2002
+ IsomorphicFetchHttpLibrary.prototype.send = function (request) {
2003
+ var method = request.getHttpMethod().toString();
2004
+ var body = request.getBody();
2005
+ var resultPromise = fetch(request.getUrl(), {
2006
+ method: method,
2007
+ body: body,
2008
+ headers: request.getHeaders(),
2009
+ credentials: "same-origin"
2010
+ }).then(function (resp) {
2011
+ var headers = {};
2012
+ resp.headers.forEach(function (value, name) {
2013
+ headers[name] = value;
2014
+ });
2015
+ var body = {
2016
+ text: function () { return resp.text(); },
2017
+ binary: function () { return resp.blob(); }
2018
+ };
2019
+ return new http.ResponseContext(resp.status, headers, body);
2020
+ });
2021
+ return (0, rxjsStub.from)(resultPromise);
2022
+ };
2023
+ return IsomorphicFetchHttpLibrary;
2024
+ }());
2025
+ exports.IsomorphicFetchHttpLibrary = IsomorphicFetchHttpLibrary;
2026
+ //# sourceMappingURL=isomorphic-fetch.js.map
2027
+ });
2028
+
2029
+ const isomorphicFetch$1 = /*@__PURE__*/getDefaultExportFromCjs(isomorphicFetch);
2030
+
2031
+ var http = createCommonjsModule(function (module, exports) {
2032
+ "use strict";
2033
+ var __extends = (commonjsGlobal && commonjsGlobal.__extends) || (function () {
2034
+ var extendStatics = function (d, b) {
2035
+ extendStatics = Object.setPrototypeOf ||
2036
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
2037
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
2038
+ return extendStatics(d, b);
2039
+ };
2040
+ return function (d, b) {
2041
+ if (typeof b !== "function" && b !== null)
2042
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
2043
+ extendStatics(d, b);
2044
+ function __() { this.constructor = d; }
2045
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
2046
+ };
2047
+ })();
2048
+ var __createBinding = (commonjsGlobal && commonjsGlobal.__createBinding) || (Object.create ? (function(o, m, k, k2) {
2049
+ if (k2 === undefined) k2 = k;
2050
+ var desc = Object.getOwnPropertyDescriptor(m, k);
2051
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
2052
+ desc = { enumerable: true, get: function() { return m[k]; } };
2053
+ }
2054
+ Object.defineProperty(o, k2, desc);
2055
+ }) : (function(o, m, k, k2) {
2056
+ if (k2 === undefined) k2 = k;
2057
+ o[k2] = m[k];
2058
+ }));
2059
+ var __exportStar = (commonjsGlobal && commonjsGlobal.__exportStar) || function(m, exports) {
2060
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
2061
+ };
2062
+ var __awaiter = (commonjsGlobal && commonjsGlobal.__awaiter) || function (thisArg, _arguments, P, generator) {
2063
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
2064
+ return new (P || (P = Promise))(function (resolve, reject) {
2065
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
2066
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
2067
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
2068
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
2069
+ });
2070
+ };
2071
+ var __generator = (commonjsGlobal && commonjsGlobal.__generator) || function (thisArg, body) {
2072
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
2073
+ return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
2074
+ function verb(n) { return function (v) { return step([n, v]); }; }
2075
+ function step(op) {
2076
+ if (f) throw new TypeError("Generator is already executing.");
2077
+ while (_) try {
2078
+ 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;
2079
+ if (y = 0, t) op = [op[0] & 2, t.value];
2080
+ switch (op[0]) {
2081
+ case 0: case 1: t = op; break;
2082
+ case 4: _.label++; return { value: op[1], done: false };
2083
+ case 5: _.label++; y = op[1]; op = [0]; continue;
2084
+ case 7: op = _.ops.pop(); _.trys.pop(); continue;
2085
+ default:
2086
+ if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
2087
+ if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
2088
+ if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
2089
+ if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
2090
+ if (t[2]) _.ops.pop();
2091
+ _.trys.pop(); continue;
2092
+ }
2093
+ op = body.call(thisArg, _);
2094
+ } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
2095
+ if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
2096
+ }
2097
+ };
2098
+ Object.defineProperty(exports, "__esModule", { value: true });
2099
+ exports.wrapHttpLibrary = exports.ResponseContext = exports.SelfDecodingBody = exports.RequestContext = exports.HttpException = exports.HttpMethod = void 0;
2100
+
2101
+
2102
+ __exportStar(isomorphicFetch, exports);
2103
+ var HttpMethod;
2104
+ (function (HttpMethod) {
2105
+ HttpMethod["GET"] = "GET";
2106
+ HttpMethod["HEAD"] = "HEAD";
2107
+ HttpMethod["POST"] = "POST";
2108
+ HttpMethod["PUT"] = "PUT";
2109
+ HttpMethod["DELETE"] = "DELETE";
2110
+ HttpMethod["CONNECT"] = "CONNECT";
2111
+ HttpMethod["OPTIONS"] = "OPTIONS";
2112
+ HttpMethod["TRACE"] = "TRACE";
2113
+ HttpMethod["PATCH"] = "PATCH";
2114
+ })(HttpMethod = exports.HttpMethod || (exports.HttpMethod = {}));
2115
+ var HttpException = (function (_super) {
2116
+ __extends(HttpException, _super);
2117
+ function HttpException(msg) {
2118
+ return _super.call(this, msg) || this;
2119
+ }
2120
+ return HttpException;
2121
+ }(Error));
2122
+ exports.HttpException = HttpException;
2123
+ var RequestContext = (function () {
2124
+ function RequestContext(url, httpMethod) {
2125
+ this.httpMethod = httpMethod;
2126
+ this.headers = {};
2127
+ this.body = undefined;
2128
+ this.url = new urlParse(url, true);
2129
+ }
2130
+ RequestContext.prototype.getUrl = function () {
2131
+ return this.url.toString();
2132
+ };
2133
+ RequestContext.prototype.setUrl = function (url) {
2134
+ this.url = new urlParse(url, true);
2135
+ };
2136
+ RequestContext.prototype.setBody = function (body) {
2137
+ this.body = body;
2138
+ };
2139
+ RequestContext.prototype.getHttpMethod = function () {
2140
+ return this.httpMethod;
2141
+ };
2142
+ RequestContext.prototype.getHeaders = function () {
2143
+ return this.headers;
2144
+ };
2145
+ RequestContext.prototype.getBody = function () {
2146
+ return this.body;
2147
+ };
2148
+ RequestContext.prototype.setQueryParam = function (name, value) {
2149
+ var queryObj = this.url.query;
2150
+ queryObj[name] = value;
2151
+ this.url.set("query", queryObj);
2152
+ };
2153
+ RequestContext.prototype.addCookie = function (name, value) {
2154
+ if (!this.headers["Cookie"]) {
2155
+ this.headers["Cookie"] = "";
2156
+ }
2157
+ this.headers["Cookie"] += name + "=" + value + "; ";
2158
+ };
2159
+ RequestContext.prototype.setHeaderParam = function (key, value) {
2160
+ this.headers[key] = value;
2161
+ };
2162
+ return RequestContext;
2163
+ }());
2164
+ exports.RequestContext = RequestContext;
2165
+ var SelfDecodingBody = (function () {
2166
+ function SelfDecodingBody(dataSource) {
2167
+ this.dataSource = dataSource;
2168
+ }
2169
+ SelfDecodingBody.prototype.binary = function () {
2170
+ return this.dataSource;
2171
+ };
2172
+ SelfDecodingBody.prototype.text = function () {
2173
+ return __awaiter(this, void 0, void 0, function () {
2174
+ var data;
2175
+ return __generator(this, function (_a) {
2176
+ switch (_a.label) {
2177
+ case 0: return [4, this.dataSource];
2178
+ case 1:
2179
+ data = _a.sent();
2180
+ if (data.text) {
2181
+ return [2, data.text()];
2182
+ }
2183
+ return [2, new Promise(function (resolve, reject) {
2184
+ var reader = new FileReader();
2185
+ reader.addEventListener("load", function () { return resolve(reader.result); });
2186
+ reader.addEventListener("error", function () { return reject(reader.error); });
2187
+ reader.readAsText(data);
2188
+ })];
2189
+ }
2190
+ });
2191
+ });
2192
+ };
2193
+ return SelfDecodingBody;
2194
+ }());
2195
+ exports.SelfDecodingBody = SelfDecodingBody;
2196
+ var ResponseContext = (function () {
2197
+ function ResponseContext(httpStatusCode, headers, body) {
2198
+ this.httpStatusCode = httpStatusCode;
2199
+ this.headers = headers;
2200
+ this.body = body;
2201
+ }
2202
+ ResponseContext.prototype.getParsedHeader = function (headerName) {
2203
+ var result = {};
2204
+ if (!this.headers[headerName]) {
2205
+ return result;
2206
+ }
2207
+ var parameters = this.headers[headerName].split(";");
2208
+ for (var _i = 0, parameters_1 = parameters; _i < parameters_1.length; _i++) {
2209
+ var parameter = parameters_1[_i];
2210
+ var _a = parameter.split("=", 2), key = _a[0], value = _a[1];
2211
+ key = key.toLowerCase().trim();
2212
+ if (value === undefined) {
2213
+ result[""] = key;
2214
+ }
2215
+ else {
2216
+ value = value.trim();
2217
+ if (value.startsWith('"') && value.endsWith('"')) {
2218
+ value = value.substring(1, value.length - 1);
2219
+ }
2220
+ result[key] = value;
2221
+ }
2222
+ }
2223
+ return result;
2224
+ };
2225
+ ResponseContext.prototype.getBodyAsFile = function () {
2226
+ return __awaiter(this, void 0, void 0, function () {
2227
+ var data, fileName, contentType;
2228
+ return __generator(this, function (_a) {
2229
+ switch (_a.label) {
2230
+ case 0: return [4, this.body.binary()];
2231
+ case 1:
2232
+ data = _a.sent();
2233
+ fileName = this.getParsedHeader("content-disposition")["filename"] || "";
2234
+ contentType = this.headers["content-type"] || "";
2235
+ try {
2236
+ return [2, new File([data], fileName, { type: contentType })];
2237
+ }
2238
+ catch (error) {
2239
+ return [2, Object.assign(data, {
2240
+ name: fileName,
2241
+ type: contentType
2242
+ })];
2243
+ }
2244
+ return [2];
2245
+ }
2246
+ });
2247
+ });
2248
+ };
2249
+ ResponseContext.prototype.getBodyAsAny = function () {
2250
+ try {
2251
+ return this.body.text();
2252
+ }
2253
+ catch (_a) { }
2254
+ try {
2255
+ return this.body.binary();
2256
+ }
2257
+ catch (_b) { }
2258
+ return Promise.resolve(undefined);
2259
+ };
2260
+ return ResponseContext;
2261
+ }());
2262
+ exports.ResponseContext = ResponseContext;
2263
+ function wrapHttpLibrary(promiseHttpLibrary) {
2264
+ return {
2265
+ send: function (request) {
2266
+ return (0, rxjsStub.from)(promiseHttpLibrary.send(request));
2267
+ }
2268
+ };
2269
+ }
2270
+ exports.wrapHttpLibrary = wrapHttpLibrary;
2271
+ //# sourceMappingURL=http.js.map
2272
+ });
2273
+
2274
+ const http$1 = /*@__PURE__*/getDefaultExportFromCjs(http);
2275
+
2276
+ var auth = createCommonjsModule(function (module, exports) {
2277
+ "use strict";
2278
+ var __awaiter = (commonjsGlobal && commonjsGlobal.__awaiter) || function (thisArg, _arguments, P, generator) {
2279
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
2280
+ return new (P || (P = Promise))(function (resolve, reject) {
2281
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
2282
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
2283
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
2284
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
2285
+ });
2286
+ };
2287
+ var __generator = (commonjsGlobal && commonjsGlobal.__generator) || function (thisArg, body) {
2288
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
2289
+ return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
2290
+ function verb(n) { return function (v) { return step([n, v]); }; }
2291
+ function step(op) {
2292
+ if (f) throw new TypeError("Generator is already executing.");
2293
+ while (_) try {
2294
+ 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;
2295
+ if (y = 0, t) op = [op[0] & 2, t.value];
2296
+ switch (op[0]) {
2297
+ case 0: case 1: t = op; break;
2298
+ case 4: _.label++; return { value: op[1], done: false };
2299
+ case 5: _.label++; y = op[1]; op = [0]; continue;
2300
+ case 7: op = _.ops.pop(); _.trys.pop(); continue;
2301
+ default:
2302
+ if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
2303
+ if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
2304
+ if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
2305
+ if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
2306
+ if (t[2]) _.ops.pop();
2307
+ _.trys.pop(); continue;
2308
+ }
2309
+ op = body.call(thisArg, _);
2310
+ } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
2311
+ if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
2312
+ }
2313
+ };
2314
+ Object.defineProperty(exports, "__esModule", { value: true });
2315
+ exports.configureAuthMethods = exports.BearerAuthAuthentication = void 0;
2316
+ var BearerAuthAuthentication = (function () {
2317
+ function BearerAuthAuthentication(tokenProvider) {
2318
+ this.tokenProvider = tokenProvider;
2319
+ }
2320
+ BearerAuthAuthentication.prototype.getName = function () {
2321
+ return "bearerAuth";
2322
+ };
2323
+ BearerAuthAuthentication.prototype.applySecurityAuthentication = function (context) {
2324
+ return __awaiter(this, void 0, void 0, function () {
2325
+ var _a, _b, _c, _d;
2326
+ return __generator(this, function (_e) {
2327
+ switch (_e.label) {
2328
+ case 0:
2329
+ _b = (_a = context).setHeaderParam;
2330
+ _c = ["Authorization"];
2331
+ _d = "Bearer ";
2332
+ return [4, this.tokenProvider.getToken()];
2333
+ case 1:
2334
+ _b.apply(_a, _c.concat([_d + (_e.sent())]));
2335
+ return [2];
2336
+ }
2337
+ });
2338
+ });
2339
+ };
2340
+ return BearerAuthAuthentication;
2341
+ }());
2342
+ exports.BearerAuthAuthentication = BearerAuthAuthentication;
2343
+ function configureAuthMethods(config) {
2344
+ var authMethods = {};
2345
+ if (!config) {
2346
+ return authMethods;
2347
+ }
2348
+ authMethods["default"] = config["default"];
2349
+ if (config["bearerAuth"]) {
2350
+ authMethods["bearerAuth"] = new BearerAuthAuthentication(config["bearerAuth"]["tokenProvider"]);
2351
+ }
2352
+ return authMethods;
2353
+ }
2354
+ exports.configureAuthMethods = configureAuthMethods;
2355
+ //# sourceMappingURL=auth.js.map
2356
+ });
2357
+
2358
+ const auth$1 = /*@__PURE__*/getDefaultExportFromCjs(auth);
2359
+
2360
+ var ErrorObject_1 = createCommonjsModule(function (module, exports) {
2361
+ "use strict";
2362
+ Object.defineProperty(exports, "__esModule", { value: true });
2363
+ exports.ErrorObject = void 0;
2364
+ var ErrorObject = (function () {
2365
+ function ErrorObject() {
2366
+ }
2367
+ ErrorObject.getAttributeTypeMap = function () {
2368
+ return ErrorObject.attributeTypeMap;
2369
+ };
2370
+ ErrorObject.discriminator = undefined;
2371
+ ErrorObject.attributeTypeMap = [
2372
+ {
2373
+ "name": "domain",
2374
+ "baseName": "domain",
2375
+ "type": "string",
2376
+ "format": ""
2377
+ },
2378
+ {
2379
+ "name": "reason",
2380
+ "baseName": "reason",
2381
+ "type": "string",
2382
+ "format": ""
2383
+ },
2384
+ {
2385
+ "name": "message",
2386
+ "baseName": "message",
2387
+ "type": "string",
2388
+ "format": ""
2389
+ },
2390
+ {
2391
+ "name": "location",
2392
+ "baseName": "location",
2393
+ "type": "string",
2394
+ "format": ""
2395
+ },
2396
+ {
2397
+ "name": "location_type",
2398
+ "baseName": "location_type",
2399
+ "type": "string",
2400
+ "format": ""
2401
+ },
2402
+ {
2403
+ "name": "extended_help",
2404
+ "baseName": "extended_help",
2405
+ "type": "string",
2406
+ "format": ""
2407
+ },
2408
+ {
2409
+ "name": "send_report",
2410
+ "baseName": "send_report",
2411
+ "type": "string",
2412
+ "format": ""
2413
+ }
2414
+ ];
2415
+ return ErrorObject;
2416
+ }());
2417
+ exports.ErrorObject = ErrorObject;
2418
+ //# sourceMappingURL=ErrorObject.js.map
2419
+ });
2420
+
2421
+ const ErrorObject = /*@__PURE__*/getDefaultExportFromCjs(ErrorObject_1);
2422
+
2423
+ var ErrorResponse_1 = createCommonjsModule(function (module, exports) {
2424
+ "use strict";
2425
+ Object.defineProperty(exports, "__esModule", { value: true });
2426
+ exports.ErrorResponse = void 0;
2427
+ var ErrorResponse = (function () {
2428
+ function ErrorResponse() {
2429
+ }
2430
+ ErrorResponse.getAttributeTypeMap = function () {
2431
+ return ErrorResponse.attributeTypeMap;
2432
+ };
2433
+ ErrorResponse.discriminator = undefined;
2434
+ ErrorResponse.attributeTypeMap = [
2435
+ {
2436
+ "name": "code",
2437
+ "baseName": "code",
2438
+ "type": "number",
2439
+ "format": ""
2440
+ },
2441
+ {
2442
+ "name": "message",
2443
+ "baseName": "message",
2444
+ "type": "string",
2445
+ "format": ""
2446
+ },
2447
+ {
2448
+ "name": "errors",
2449
+ "baseName": "errors",
2450
+ "type": "Array<ErrorObject>",
2451
+ "format": ""
2452
+ }
2453
+ ];
2454
+ return ErrorResponse;
2455
+ }());
2456
+ exports.ErrorResponse = ErrorResponse;
2457
+ //# sourceMappingURL=ErrorResponse.js.map
2458
+ });
2459
+
2460
+ const ErrorResponse = /*@__PURE__*/getDefaultExportFromCjs(ErrorResponse_1);
2461
+
2462
+ var Event_1 = createCommonjsModule(function (module, exports) {
2463
+ "use strict";
2464
+ Object.defineProperty(exports, "__esModule", { value: true });
2465
+ exports.Event = void 0;
2466
+ var Event = (function () {
2467
+ function Event() {
2468
+ this.typ = "Event";
2469
+ }
2470
+ Event.getAttributeTypeMap = function () {
2471
+ return Event.attributeTypeMap;
2472
+ };
2473
+ Event.discriminator = "typ";
2474
+ Event.attributeTypeMap = [
2475
+ {
2476
+ "name": "session_id",
2477
+ "baseName": "session_id",
2478
+ "type": "string",
2479
+ "format": ""
2480
+ },
2481
+ {
2482
+ "name": "typ",
2483
+ "baseName": "typ",
2484
+ "type": "string",
2485
+ "format": ""
2486
+ }
2487
+ ];
2488
+ return Event;
2489
+ }());
2490
+ exports.Event = Event;
2491
+ //# sourceMappingURL=Event.js.map
2492
+ });
2493
+
2494
+ const Event = /*@__PURE__*/getDefaultExportFromCjs(Event_1);
2495
+
2496
+ var EventConfirmation_1 = createCommonjsModule(function (module, exports) {
2497
+ "use strict";
2498
+ Object.defineProperty(exports, "__esModule", { value: true });
2499
+ exports.EventConfirmation = void 0;
2500
+ var EventConfirmation = (function () {
2501
+ function EventConfirmation() {
2502
+ }
2503
+ EventConfirmation.getAttributeTypeMap = function () {
2504
+ return EventConfirmation.attributeTypeMap;
2505
+ };
2506
+ EventConfirmation.discriminator = undefined;
2507
+ EventConfirmation.attributeTypeMap = [
2508
+ {
2509
+ "name": "status",
2510
+ "baseName": "status",
2511
+ "type": "EventConfirmationStatusEnum",
2512
+ "format": ""
2513
+ }
2514
+ ];
2515
+ return EventConfirmation;
2516
+ }());
2517
+ exports.EventConfirmation = EventConfirmation;
2518
+ //# sourceMappingURL=EventConfirmation.js.map
2519
+ });
2520
+
2521
+ const EventConfirmation = /*@__PURE__*/getDefaultExportFromCjs(EventConfirmation_1);
2522
+
2523
+ var FilterAction = createCommonjsModule(function (module, exports) {
2524
+ "use strict";
2525
+ Object.defineProperty(exports, "__esModule", { value: true });
2526
+ //# sourceMappingURL=FilterAction.js.map
2527
+ });
2528
+
2529
+ const FilterAction$1 = /*@__PURE__*/getDefaultExportFromCjs(FilterAction);
2530
+
2531
+ var FilterEvent_1 = createCommonjsModule(function (module, exports) {
2532
+ "use strict";
2533
+ var __extends = (commonjsGlobal && commonjsGlobal.__extends) || (function () {
2534
+ var extendStatics = function (d, b) {
2535
+ extendStatics = Object.setPrototypeOf ||
2536
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
2537
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
2538
+ return extendStatics(d, b);
2539
+ };
2540
+ return function (d, b) {
2541
+ if (typeof b !== "function" && b !== null)
2542
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
2543
+ extendStatics(d, b);
2544
+ function __() { this.constructor = d; }
2545
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
2546
+ };
2547
+ })();
2548
+ Object.defineProperty(exports, "__esModule", { value: true });
2549
+ exports.FilterEvent = void 0;
2550
+
2551
+ var FilterEvent = (function (_super) {
2552
+ __extends(FilterEvent, _super);
2553
+ function FilterEvent() {
2554
+ var _this = _super.call(this) || this;
2555
+ _this.typ = "FilterEvent";
2556
+ return _this;
2557
+ }
2558
+ FilterEvent.getAttributeTypeMap = function () {
2559
+ return _super.getAttributeTypeMap.call(this).concat(FilterEvent.attributeTypeMap);
2560
+ };
2561
+ FilterEvent.discriminator = undefined;
2562
+ FilterEvent.attributeTypeMap = [
2563
+ {
2564
+ "name": "widget",
2565
+ "baseName": "widget",
2566
+ "type": "Widget",
2567
+ "format": ""
2568
+ },
2569
+ {
2570
+ "name": "action",
2571
+ "baseName": "action",
2572
+ "type": "FilterAction",
2573
+ "format": ""
2574
+ },
2575
+ {
2576
+ "name": "kind",
2577
+ "baseName": "kind",
2578
+ "type": "FilterKind",
2579
+ "format": ""
2580
+ }
2581
+ ];
2582
+ return FilterEvent;
2583
+ }(Event_1.Event));
2584
+ exports.FilterEvent = FilterEvent;
2585
+ //# sourceMappingURL=FilterEvent.js.map
2586
+ });
2587
+
2588
+ const FilterEvent = /*@__PURE__*/getDefaultExportFromCjs(FilterEvent_1);
2589
+
2590
+ var FilterEventAllOf_1 = createCommonjsModule(function (module, exports) {
2591
+ "use strict";
2592
+ Object.defineProperty(exports, "__esModule", { value: true });
2593
+ exports.FilterEventAllOf = void 0;
2594
+ var FilterEventAllOf = (function () {
2595
+ function FilterEventAllOf() {
2596
+ }
2597
+ FilterEventAllOf.getAttributeTypeMap = function () {
2598
+ return FilterEventAllOf.attributeTypeMap;
2599
+ };
2600
+ FilterEventAllOf.discriminator = undefined;
2601
+ FilterEventAllOf.attributeTypeMap = [
2602
+ {
2603
+ "name": "widget",
2604
+ "baseName": "widget",
2605
+ "type": "Widget",
2606
+ "format": ""
2607
+ },
2608
+ {
2609
+ "name": "action",
2610
+ "baseName": "action",
2611
+ "type": "FilterAction",
2612
+ "format": ""
2613
+ },
2614
+ {
2615
+ "name": "kind",
2616
+ "baseName": "kind",
2617
+ "type": "FilterKind",
2618
+ "format": ""
2619
+ }
2620
+ ];
2621
+ return FilterEventAllOf;
2622
+ }());
2623
+ exports.FilterEventAllOf = FilterEventAllOf;
2624
+ //# sourceMappingURL=FilterEventAllOf.js.map
2625
+ });
2626
+
2627
+ const FilterEventAllOf = /*@__PURE__*/getDefaultExportFromCjs(FilterEventAllOf_1);
2628
+
2629
+ var FilterKind = createCommonjsModule(function (module, exports) {
2630
+ "use strict";
2631
+ Object.defineProperty(exports, "__esModule", { value: true });
2632
+ //# sourceMappingURL=FilterKind.js.map
2633
+ });
2634
+
2635
+ const FilterKind$1 = /*@__PURE__*/getDefaultExportFromCjs(FilterKind);
2636
+
2637
+ var ProductClickEvent_1 = createCommonjsModule(function (module, exports) {
2638
+ "use strict";
2639
+ var __extends = (commonjsGlobal && commonjsGlobal.__extends) || (function () {
2640
+ var extendStatics = function (d, b) {
2641
+ extendStatics = Object.setPrototypeOf ||
2642
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
2643
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
2644
+ return extendStatics(d, b);
2645
+ };
2646
+ return function (d, b) {
2647
+ if (typeof b !== "function" && b !== null)
2648
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
2649
+ extendStatics(d, b);
2650
+ function __() { this.constructor = d; }
2651
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
2652
+ };
2653
+ })();
2654
+ Object.defineProperty(exports, "__esModule", { value: true });
2655
+ exports.ProductClickEvent = void 0;
2656
+
2657
+ var ProductClickEvent = (function (_super) {
2658
+ __extends(ProductClickEvent, _super);
2659
+ function ProductClickEvent() {
2660
+ var _this = _super.call(this) || this;
2661
+ _this.typ = "ProductClickEvent";
2662
+ return _this;
2663
+ }
2664
+ ProductClickEvent.getAttributeTypeMap = function () {
2665
+ return _super.getAttributeTypeMap.call(this).concat(ProductClickEvent.attributeTypeMap);
2666
+ };
2667
+ ProductClickEvent.discriminator = undefined;
2668
+ ProductClickEvent.attributeTypeMap = [
2669
+ {
2670
+ "name": "widget",
2671
+ "baseName": "widget",
2672
+ "type": "Widget",
2673
+ "format": ""
2674
+ },
2675
+ {
2676
+ "name": "product",
2677
+ "baseName": "product",
2678
+ "type": "string",
2679
+ "format": ""
2680
+ },
2681
+ {
2682
+ "name": "rank",
2683
+ "baseName": "rank",
2684
+ "type": "number",
2685
+ "format": ""
2686
+ }
2687
+ ];
2688
+ return ProductClickEvent;
2689
+ }(Event_1.Event));
2690
+ exports.ProductClickEvent = ProductClickEvent;
2691
+ //# sourceMappingURL=ProductClickEvent.js.map
2692
+ });
2693
+
2694
+ const ProductClickEvent = /*@__PURE__*/getDefaultExportFromCjs(ProductClickEvent_1);
2695
+
2696
+ var ProductViewEvent_1 = createCommonjsModule(function (module, exports) {
2697
+ "use strict";
2698
+ var __extends = (commonjsGlobal && commonjsGlobal.__extends) || (function () {
2699
+ var extendStatics = function (d, b) {
2700
+ extendStatics = Object.setPrototypeOf ||
2701
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
2702
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
2703
+ return extendStatics(d, b);
2704
+ };
2705
+ return function (d, b) {
2706
+ if (typeof b !== "function" && b !== null)
2707
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
2708
+ extendStatics(d, b);
2709
+ function __() { this.constructor = d; }
2710
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
2711
+ };
2712
+ })();
2713
+ Object.defineProperty(exports, "__esModule", { value: true });
2714
+ exports.ProductViewEvent = void 0;
2715
+
2716
+ var ProductViewEvent = (function (_super) {
2717
+ __extends(ProductViewEvent, _super);
2718
+ function ProductViewEvent() {
2719
+ var _this = _super.call(this) || this;
2720
+ _this.typ = "ProductViewEvent";
2721
+ return _this;
2722
+ }
2723
+ ProductViewEvent.getAttributeTypeMap = function () {
2724
+ return _super.getAttributeTypeMap.call(this).concat(ProductViewEvent.attributeTypeMap);
2725
+ };
2726
+ ProductViewEvent.discriminator = undefined;
2727
+ ProductViewEvent.attributeTypeMap = [
2728
+ {
2729
+ "name": "widget",
2730
+ "baseName": "widget",
2731
+ "type": "Widget",
2732
+ "format": ""
2733
+ },
2734
+ {
2735
+ "name": "product",
2736
+ "baseName": "product",
2737
+ "type": "string",
2738
+ "format": ""
2739
+ },
2740
+ {
2741
+ "name": "rank",
2742
+ "baseName": "rank",
2743
+ "type": "number",
2744
+ "format": ""
2745
+ }
2746
+ ];
2747
+ return ProductViewEvent;
2748
+ }(Event_1.Event));
2749
+ exports.ProductViewEvent = ProductViewEvent;
2750
+ //# sourceMappingURL=ProductViewEvent.js.map
2751
+ });
2752
+
2753
+ const ProductViewEvent = /*@__PURE__*/getDefaultExportFromCjs(ProductViewEvent_1);
2754
+
2755
+ var ProductViewEventAllOf_1 = createCommonjsModule(function (module, exports) {
2756
+ "use strict";
2757
+ Object.defineProperty(exports, "__esModule", { value: true });
2758
+ exports.ProductViewEventAllOf = void 0;
2759
+ var ProductViewEventAllOf = (function () {
2760
+ function ProductViewEventAllOf() {
2761
+ }
2762
+ ProductViewEventAllOf.getAttributeTypeMap = function () {
2763
+ return ProductViewEventAllOf.attributeTypeMap;
2764
+ };
2765
+ ProductViewEventAllOf.discriminator = undefined;
2766
+ ProductViewEventAllOf.attributeTypeMap = [
2767
+ {
2768
+ "name": "widget",
2769
+ "baseName": "widget",
2770
+ "type": "Widget",
2771
+ "format": ""
2772
+ },
2773
+ {
2774
+ "name": "product",
2775
+ "baseName": "product",
2776
+ "type": "string",
2777
+ "format": ""
2778
+ },
2779
+ {
2780
+ "name": "rank",
2781
+ "baseName": "rank",
2782
+ "type": "number",
2783
+ "format": ""
2784
+ }
2785
+ ];
2786
+ return ProductViewEventAllOf;
2787
+ }());
2788
+ exports.ProductViewEventAllOf = ProductViewEventAllOf;
2789
+ //# sourceMappingURL=ProductViewEventAllOf.js.map
2790
+ });
2791
+
2792
+ const ProductViewEventAllOf = /*@__PURE__*/getDefaultExportFromCjs(ProductViewEventAllOf_1);
2793
+
2794
+ var SearchArea = createCommonjsModule(function (module, exports) {
2795
+ "use strict";
2796
+ Object.defineProperty(exports, "__esModule", { value: true });
2797
+ //# sourceMappingURL=SearchArea.js.map
2798
+ });
2799
+
2800
+ const SearchArea$1 = /*@__PURE__*/getDefaultExportFromCjs(SearchArea);
2801
+
2802
+ var SearchEvent_1 = createCommonjsModule(function (module, exports) {
2803
+ "use strict";
2804
+ var __extends = (commonjsGlobal && commonjsGlobal.__extends) || (function () {
2805
+ var extendStatics = function (d, b) {
2806
+ extendStatics = Object.setPrototypeOf ||
2807
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
2808
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
2809
+ return extendStatics(d, b);
2810
+ };
2811
+ return function (d, b) {
2812
+ if (typeof b !== "function" && b !== null)
2813
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
2814
+ extendStatics(d, b);
2815
+ function __() { this.constructor = d; }
2816
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
2817
+ };
2818
+ })();
2819
+ Object.defineProperty(exports, "__esModule", { value: true });
2820
+ exports.SearchEvent = void 0;
2821
+
2822
+ var SearchEvent = (function (_super) {
2823
+ __extends(SearchEvent, _super);
2824
+ function SearchEvent() {
2825
+ var _this = _super.call(this) || this;
2826
+ _this.typ = "SearchEvent";
2827
+ return _this;
2828
+ }
2829
+ SearchEvent.getAttributeTypeMap = function () {
2830
+ return _super.getAttributeTypeMap.call(this).concat(SearchEvent.attributeTypeMap);
2831
+ };
2832
+ SearchEvent.discriminator = undefined;
2833
+ SearchEvent.attributeTypeMap = [
2834
+ {
2835
+ "name": "widget",
2836
+ "baseName": "widget",
2837
+ "type": "Widget",
2838
+ "format": ""
2839
+ },
2840
+ {
2841
+ "name": "source",
2842
+ "baseName": "source",
2843
+ "type": "SearchImageSource",
2844
+ "format": ""
2845
+ },
2846
+ {
2847
+ "name": "search_area",
2848
+ "baseName": "search_area",
2849
+ "type": "SearchArea",
2850
+ "format": ""
2851
+ }
2852
+ ];
2853
+ return SearchEvent;
2854
+ }(Event_1.Event));
2855
+ exports.SearchEvent = SearchEvent;
2856
+ //# sourceMappingURL=SearchEvent.js.map
2857
+ });
2858
+
2859
+ const SearchEvent = /*@__PURE__*/getDefaultExportFromCjs(SearchEvent_1);
2860
+
2861
+ var SearchEventAllOf_1 = createCommonjsModule(function (module, exports) {
2862
+ "use strict";
2863
+ Object.defineProperty(exports, "__esModule", { value: true });
2864
+ exports.SearchEventAllOf = void 0;
2865
+ var SearchEventAllOf = (function () {
2866
+ function SearchEventAllOf() {
2867
+ }
2868
+ SearchEventAllOf.getAttributeTypeMap = function () {
2869
+ return SearchEventAllOf.attributeTypeMap;
2870
+ };
2871
+ SearchEventAllOf.discriminator = undefined;
2872
+ SearchEventAllOf.attributeTypeMap = [
2873
+ {
2874
+ "name": "widget",
2875
+ "baseName": "widget",
2876
+ "type": "Widget",
2877
+ "format": ""
2878
+ },
2879
+ {
2880
+ "name": "source",
2881
+ "baseName": "source",
2882
+ "type": "SearchImageSource",
2883
+ "format": ""
2884
+ },
2885
+ {
2886
+ "name": "search_area",
2887
+ "baseName": "search_area",
2888
+ "type": "SearchArea",
2889
+ "format": ""
2890
+ }
2891
+ ];
2892
+ return SearchEventAllOf;
2893
+ }());
2894
+ exports.SearchEventAllOf = SearchEventAllOf;
2895
+ //# sourceMappingURL=SearchEventAllOf.js.map
2896
+ });
2897
+
2898
+ const SearchEventAllOf = /*@__PURE__*/getDefaultExportFromCjs(SearchEventAllOf_1);
2899
+
2900
+ var SearchImageSource = createCommonjsModule(function (module, exports) {
2901
+ "use strict";
2902
+ Object.defineProperty(exports, "__esModule", { value: true });
2903
+ //# sourceMappingURL=SearchImageSource.js.map
2904
+ });
2905
+
2906
+ const SearchImageSource$1 = /*@__PURE__*/getDefaultExportFromCjs(SearchImageSource);
2907
+
2908
+ var Widget = createCommonjsModule(function (module, exports) {
2909
+ "use strict";
2910
+ Object.defineProperty(exports, "__esModule", { value: true });
2911
+ //# sourceMappingURL=Widget.js.map
2912
+ });
2913
+
2914
+ const Widget$1 = /*@__PURE__*/getDefaultExportFromCjs(Widget);
2915
+
2916
+ var WidgetAction = createCommonjsModule(function (module, exports) {
2917
+ "use strict";
2918
+ Object.defineProperty(exports, "__esModule", { value: true });
2919
+ //# sourceMappingURL=WidgetAction.js.map
2920
+ });
2921
+
2922
+ const WidgetAction$1 = /*@__PURE__*/getDefaultExportFromCjs(WidgetAction);
2923
+
2924
+ var WidgetEvent_1 = createCommonjsModule(function (module, exports) {
2925
+ "use strict";
2926
+ var __extends = (commonjsGlobal && commonjsGlobal.__extends) || (function () {
2927
+ var extendStatics = function (d, b) {
2928
+ extendStatics = Object.setPrototypeOf ||
2929
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
2930
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
2931
+ return extendStatics(d, b);
2932
+ };
2933
+ return function (d, b) {
2934
+ if (typeof b !== "function" && b !== null)
2935
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
2936
+ extendStatics(d, b);
2937
+ function __() { this.constructor = d; }
2938
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
2939
+ };
2940
+ })();
2941
+ Object.defineProperty(exports, "__esModule", { value: true });
2942
+ exports.WidgetEvent = void 0;
2943
+
2944
+ var WidgetEvent = (function (_super) {
2945
+ __extends(WidgetEvent, _super);
2946
+ function WidgetEvent() {
2947
+ var _this = _super.call(this) || this;
2948
+ _this.typ = "WidgetEvent";
2949
+ return _this;
2950
+ }
2951
+ WidgetEvent.getAttributeTypeMap = function () {
2952
+ return _super.getAttributeTypeMap.call(this).concat(WidgetEvent.attributeTypeMap);
2953
+ };
2954
+ WidgetEvent.discriminator = undefined;
2955
+ WidgetEvent.attributeTypeMap = [
2956
+ {
2957
+ "name": "widget",
2958
+ "baseName": "widget",
2959
+ "type": "Widget",
2960
+ "format": ""
2961
+ },
2962
+ {
2963
+ "name": "action",
2964
+ "baseName": "action",
2965
+ "type": "WidgetAction",
2966
+ "format": ""
2967
+ }
2968
+ ];
2969
+ return WidgetEvent;
2970
+ }(Event_1.Event));
2971
+ exports.WidgetEvent = WidgetEvent;
2972
+ //# sourceMappingURL=WidgetEvent.js.map
2973
+ });
2974
+
2975
+ const WidgetEvent = /*@__PURE__*/getDefaultExportFromCjs(WidgetEvent_1);
2976
+
2977
+ var WidgetEventAllOf_1 = createCommonjsModule(function (module, exports) {
2978
+ "use strict";
2979
+ Object.defineProperty(exports, "__esModule", { value: true });
2980
+ exports.WidgetEventAllOf = void 0;
2981
+ var WidgetEventAllOf = (function () {
2982
+ function WidgetEventAllOf() {
2983
+ }
2984
+ WidgetEventAllOf.getAttributeTypeMap = function () {
2985
+ return WidgetEventAllOf.attributeTypeMap;
2986
+ };
2987
+ WidgetEventAllOf.discriminator = undefined;
2988
+ WidgetEventAllOf.attributeTypeMap = [
2989
+ {
2990
+ "name": "widget",
2991
+ "baseName": "widget",
2992
+ "type": "Widget",
2993
+ "format": ""
2994
+ },
2995
+ {
2996
+ "name": "action",
2997
+ "baseName": "action",
2998
+ "type": "WidgetAction",
2999
+ "format": ""
3000
+ }
3001
+ ];
3002
+ return WidgetEventAllOf;
3003
+ }());
3004
+ exports.WidgetEventAllOf = WidgetEventAllOf;
3005
+ //# sourceMappingURL=WidgetEventAllOf.js.map
3006
+ });
3007
+
3008
+ const WidgetEventAllOf = /*@__PURE__*/getDefaultExportFromCjs(WidgetEventAllOf_1);
3009
+
3010
+ var all = createCommonjsModule(function (module, exports) {
3011
+ "use strict";
3012
+ var __createBinding = (commonjsGlobal && commonjsGlobal.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3013
+ if (k2 === undefined) k2 = k;
3014
+ var desc = Object.getOwnPropertyDescriptor(m, k);
3015
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
3016
+ desc = { enumerable: true, get: function() { return m[k]; } };
3017
+ }
3018
+ Object.defineProperty(o, k2, desc);
3019
+ }) : (function(o, m, k, k2) {
3020
+ if (k2 === undefined) k2 = k;
3021
+ o[k2] = m[k];
3022
+ }));
3023
+ var __exportStar = (commonjsGlobal && commonjsGlobal.__exportStar) || function(m, exports) {
3024
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
3025
+ };
3026
+ Object.defineProperty(exports, "__esModule", { value: true });
3027
+ __exportStar(ErrorObject_1, exports);
3028
+ __exportStar(ErrorResponse_1, exports);
3029
+ __exportStar(Event_1, exports);
3030
+ __exportStar(EventConfirmation_1, exports);
3031
+ __exportStar(FilterAction, exports);
3032
+ __exportStar(FilterEvent_1, exports);
3033
+ __exportStar(FilterEventAllOf_1, exports);
3034
+ __exportStar(FilterKind, exports);
3035
+ __exportStar(ProductClickEvent_1, exports);
3036
+ __exportStar(ProductViewEvent_1, exports);
3037
+ __exportStar(ProductViewEventAllOf_1, exports);
3038
+ __exportStar(SearchArea, exports);
3039
+ __exportStar(SearchEvent_1, exports);
3040
+ __exportStar(SearchEventAllOf_1, exports);
3041
+ __exportStar(SearchImageSource, exports);
3042
+ __exportStar(Widget, exports);
3043
+ __exportStar(WidgetAction, exports);
3044
+ __exportStar(WidgetEvent_1, exports);
3045
+ __exportStar(WidgetEventAllOf_1, exports);
3046
+ //# sourceMappingURL=all.js.map
3047
+ });
3048
+
3049
+ const all$1 = /*@__PURE__*/getDefaultExportFromCjs(all);
3050
+
3051
+ var middleware = createCommonjsModule(function (module, exports) {
3052
+ "use strict";
3053
+ Object.defineProperty(exports, "__esModule", { value: true });
3054
+ exports.PromiseMiddlewareWrapper = void 0;
3055
+
3056
+ var PromiseMiddlewareWrapper = (function () {
3057
+ function PromiseMiddlewareWrapper(middleware) {
3058
+ this.middleware = middleware;
3059
+ }
3060
+ PromiseMiddlewareWrapper.prototype.pre = function (context) {
3061
+ return (0, rxjsStub.from)(this.middleware.pre(context));
3062
+ };
3063
+ PromiseMiddlewareWrapper.prototype.post = function (context) {
3064
+ return (0, rxjsStub.from)(this.middleware.post(context));
3065
+ };
3066
+ return PromiseMiddlewareWrapper;
3067
+ }());
3068
+ exports.PromiseMiddlewareWrapper = PromiseMiddlewareWrapper;
3069
+ //# sourceMappingURL=middleware.js.map
3070
+ });
3071
+
3072
+ const middleware$1 = /*@__PURE__*/getDefaultExportFromCjs(middleware);
3073
+
3074
+ var servers = createCommonjsModule(function (module, exports) {
3075
+ "use strict";
3076
+ Object.defineProperty(exports, "__esModule", { value: true });
3077
+ exports.servers = exports.server2 = exports.server1 = exports.ServerConfiguration = void 0;
3078
+
3079
+ var ServerConfiguration = (function () {
3080
+ function ServerConfiguration(url, variableConfiguration) {
3081
+ this.url = url;
3082
+ this.variableConfiguration = variableConfiguration;
3083
+ }
3084
+ ServerConfiguration.prototype.setVariables = function (variableConfiguration) {
3085
+ Object.assign(this.variableConfiguration, variableConfiguration);
3086
+ };
3087
+ ServerConfiguration.prototype.getConfiguration = function () {
3088
+ return this.variableConfiguration;
3089
+ };
3090
+ ServerConfiguration.prototype.getUrl = function () {
3091
+ var replacedUrl = this.url;
3092
+ for (var key in this.variableConfiguration) {
3093
+ var re = new RegExp("{" + key + "}", "g");
3094
+ replacedUrl = replacedUrl.replace(re, this.variableConfiguration[key]);
3095
+ }
3096
+ return replacedUrl;
3097
+ };
3098
+ ServerConfiguration.prototype.makeRequestContext = function (endpoint, httpMethod) {
3099
+ return new http.RequestContext(this.getUrl() + endpoint, httpMethod);
3100
+ };
3101
+ return ServerConfiguration;
3102
+ }());
3103
+ exports.ServerConfiguration = ServerConfiguration;
3104
+ exports.server1 = new ServerConfiguration("https://tracking.vviinn.com", {});
3105
+ exports.server2 = new ServerConfiguration("https://tracking.stage.vviinn.com", {});
3106
+ exports.servers = [exports.server1, exports.server2];
3107
+ //# sourceMappingURL=servers.js.map
3108
+ });
3109
+
3110
+ const servers$1 = /*@__PURE__*/getDefaultExportFromCjs(servers);
3111
+
3112
+ var configuration = createCommonjsModule(function (module, exports) {
3113
+ "use strict";
3114
+ Object.defineProperty(exports, "__esModule", { value: true });
3115
+ exports.createConfiguration = void 0;
3116
+
3117
+
3118
+
3119
+
3120
+ function createConfiguration(conf) {
3121
+ if (conf === void 0) { conf = {}; }
3122
+ var configuration = {
3123
+ baseServer: conf.baseServer !== undefined ? conf.baseServer : servers.server1,
3124
+ httpApi: conf.httpApi || new isomorphicFetch.IsomorphicFetchHttpLibrary(),
3125
+ middleware: conf.middleware || [],
3126
+ authMethods: (0, auth.configureAuthMethods)(conf.authMethods)
3127
+ };
3128
+ if (conf.promiseMiddleware) {
3129
+ conf.promiseMiddleware.forEach(function (m) { return configuration.middleware.push(new middleware.PromiseMiddlewareWrapper(m)); });
3130
+ }
3131
+ return configuration;
3132
+ }
3133
+ exports.createConfiguration = createConfiguration;
3134
+ //# sourceMappingURL=configuration.js.map
3135
+ });
3136
+
3137
+ const configuration$1 = /*@__PURE__*/getDefaultExportFromCjs(configuration);
3138
+
3139
+ var exception = createCommonjsModule(function (module, exports) {
3140
+ "use strict";
3141
+ var __extends = (commonjsGlobal && commonjsGlobal.__extends) || (function () {
3142
+ var extendStatics = function (d, b) {
3143
+ extendStatics = Object.setPrototypeOf ||
3144
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
3145
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
3146
+ return extendStatics(d, b);
3147
+ };
3148
+ return function (d, b) {
3149
+ if (typeof b !== "function" && b !== null)
3150
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
3151
+ extendStatics(d, b);
3152
+ function __() { this.constructor = d; }
3153
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
3154
+ };
3155
+ })();
3156
+ Object.defineProperty(exports, "__esModule", { value: true });
3157
+ exports.ApiException = void 0;
3158
+ var ApiException = (function (_super) {
3159
+ __extends(ApiException, _super);
3160
+ function ApiException(code, message, body, headers) {
3161
+ var _this = _super.call(this, "HTTP-Code: " + code + "\nMessage: " + message + "\nBody: " + JSON.stringify(body) + "\nHeaders: " +
3162
+ JSON.stringify(headers)) || this;
3163
+ _this.code = code;
3164
+ _this.body = body;
3165
+ _this.headers = headers;
3166
+ return _this;
3167
+ }
3168
+ return ApiException;
3169
+ }(Error));
3170
+ exports.ApiException = ApiException;
3171
+ //# sourceMappingURL=exception.js.map
3172
+ });
3173
+
3174
+ const exception$1 = /*@__PURE__*/getDefaultExportFromCjs(exception);
3175
+
3176
+ var baseapi = createCommonjsModule(function (module, exports) {
3177
+ "use strict";
3178
+ var __extends = (commonjsGlobal && commonjsGlobal.__extends) || (function () {
3179
+ var extendStatics = function (d, b) {
3180
+ extendStatics = Object.setPrototypeOf ||
3181
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
3182
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
3183
+ return extendStatics(d, b);
3184
+ };
3185
+ return function (d, b) {
3186
+ if (typeof b !== "function" && b !== null)
3187
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
3188
+ extendStatics(d, b);
3189
+ function __() { this.constructor = d; }
3190
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
3191
+ };
3192
+ })();
3193
+ Object.defineProperty(exports, "__esModule", { value: true });
3194
+ exports.RequiredError = exports.BaseAPIRequestFactory = exports.COLLECTION_FORMATS = void 0;
3195
+ exports.COLLECTION_FORMATS = {
3196
+ csv: ",",
3197
+ ssv: " ",
3198
+ tsv: "\t",
3199
+ pipes: "|",
3200
+ };
3201
+ var BaseAPIRequestFactory = (function () {
3202
+ function BaseAPIRequestFactory(configuration) {
3203
+ this.configuration = configuration;
3204
+ }
3205
+ return BaseAPIRequestFactory;
3206
+ }());
3207
+ exports.BaseAPIRequestFactory = BaseAPIRequestFactory;
3208
+ ;
3209
+ var RequiredError = (function (_super) {
3210
+ __extends(RequiredError, _super);
3211
+ function RequiredError(api, method, field) {
3212
+ var _this = _super.call(this, "Required parameter " + field + " was null or undefined when calling " + api + "." + method + ".") || this;
3213
+ _this.api = api;
3214
+ _this.method = method;
3215
+ _this.field = field;
3216
+ _this.name = "RequiredError";
3217
+ return _this;
3218
+ }
3219
+ return RequiredError;
3220
+ }(Error));
3221
+ exports.RequiredError = RequiredError;
3222
+ //# sourceMappingURL=baseapi.js.map
3223
+ });
3224
+
3225
+ const baseapi$1 = /*@__PURE__*/getDefaultExportFromCjs(baseapi);
3226
+
3227
+ var ObjectSerializer_1 = createCommonjsModule(function (module, exports) {
3228
+ "use strict";
3229
+ var __createBinding = (commonjsGlobal && commonjsGlobal.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3230
+ if (k2 === undefined) k2 = k;
3231
+ var desc = Object.getOwnPropertyDescriptor(m, k);
3232
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
3233
+ desc = { enumerable: true, get: function() { return m[k]; } };
3234
+ }
3235
+ Object.defineProperty(o, k2, desc);
3236
+ }) : (function(o, m, k, k2) {
3237
+ if (k2 === undefined) k2 = k;
3238
+ o[k2] = m[k];
3239
+ }));
3240
+ var __exportStar = (commonjsGlobal && commonjsGlobal.__exportStar) || function(m, exports) {
3241
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
3242
+ };
3243
+ Object.defineProperty(exports, "__esModule", { value: true });
3244
+ exports.ObjectSerializer = void 0;
3245
+ __exportStar(ErrorObject_1, exports);
3246
+ __exportStar(ErrorResponse_1, exports);
3247
+ __exportStar(Event_1, exports);
3248
+ __exportStar(EventConfirmation_1, exports);
3249
+ __exportStar(FilterAction, exports);
3250
+ __exportStar(FilterEvent_1, exports);
3251
+ __exportStar(FilterEventAllOf_1, exports);
3252
+ __exportStar(FilterKind, exports);
3253
+ __exportStar(ProductClickEvent_1, exports);
3254
+ __exportStar(ProductViewEvent_1, exports);
3255
+ __exportStar(ProductViewEventAllOf_1, exports);
3256
+ __exportStar(SearchArea, exports);
3257
+ __exportStar(SearchEvent_1, exports);
3258
+ __exportStar(SearchEventAllOf_1, exports);
3259
+ __exportStar(SearchImageSource, exports);
3260
+ __exportStar(Widget, exports);
3261
+ __exportStar(WidgetAction, exports);
3262
+ __exportStar(WidgetEvent_1, exports);
3263
+ __exportStar(WidgetEventAllOf_1, exports);
3264
+ var ErrorObject_1$1 = ErrorObject_1;
3265
+ var ErrorResponse_1$1 = ErrorResponse_1;
3266
+ var Event_1$1 = Event_1;
3267
+ var EventConfirmation_1$1 = EventConfirmation_1;
3268
+ var FilterEvent_1$1 = FilterEvent_1;
3269
+ var FilterEventAllOf_1$1 = FilterEventAllOf_1;
3270
+ var ProductClickEvent_1$1 = ProductClickEvent_1;
3271
+ var ProductViewEvent_1$1 = ProductViewEvent_1;
3272
+ var ProductViewEventAllOf_1$1 = ProductViewEventAllOf_1;
3273
+ var SearchEvent_1$1 = SearchEvent_1;
3274
+ var SearchEventAllOf_1$1 = SearchEventAllOf_1;
3275
+ var WidgetEvent_1$1 = WidgetEvent_1;
3276
+ var WidgetEventAllOf_1$1 = WidgetEventAllOf_1;
3277
+ var primitives = [
3278
+ "string",
3279
+ "boolean",
3280
+ "double",
3281
+ "integer",
3282
+ "long",
3283
+ "float",
3284
+ "number",
3285
+ "any"
3286
+ ];
3287
+ var supportedMediaTypes = {
3288
+ "application/json": Infinity,
3289
+ "application/octet-stream": 0,
3290
+ "application/x-www-form-urlencoded": 0
3291
+ };
3292
+ var enumsMap = new Set([
3293
+ "EventConfirmationStatusEnum",
3294
+ "FilterAction",
3295
+ "FilterKind",
3296
+ "SearchArea",
3297
+ "SearchImageSource",
3298
+ "Widget",
3299
+ "WidgetAction",
3300
+ ]);
3301
+ var typeMap = {
3302
+ "ErrorObject": ErrorObject_1$1.ErrorObject,
3303
+ "ErrorResponse": ErrorResponse_1$1.ErrorResponse,
3304
+ "Event": Event_1$1.Event,
3305
+ "EventConfirmation": EventConfirmation_1$1.EventConfirmation,
3306
+ "FilterEvent": FilterEvent_1$1.FilterEvent,
3307
+ "FilterEventAllOf": FilterEventAllOf_1$1.FilterEventAllOf,
3308
+ "ProductClickEvent": ProductClickEvent_1$1.ProductClickEvent,
3309
+ "ProductViewEvent": ProductViewEvent_1$1.ProductViewEvent,
3310
+ "ProductViewEventAllOf": ProductViewEventAllOf_1$1.ProductViewEventAllOf,
3311
+ "SearchEvent": SearchEvent_1$1.SearchEvent,
3312
+ "SearchEventAllOf": SearchEventAllOf_1$1.SearchEventAllOf,
3313
+ "WidgetEvent": WidgetEvent_1$1.WidgetEvent,
3314
+ "WidgetEventAllOf": WidgetEventAllOf_1$1.WidgetEventAllOf,
3315
+ };
3316
+ var ObjectSerializer = (function () {
3317
+ function ObjectSerializer() {
3318
+ }
3319
+ ObjectSerializer.findCorrectType = function (data, expectedType) {
3320
+ if (data == undefined) {
3321
+ return expectedType;
3322
+ }
3323
+ else if (primitives.indexOf(expectedType.toLowerCase()) !== -1) {
3324
+ return expectedType;
3325
+ }
3326
+ else if (expectedType === "Date") {
3327
+ return expectedType;
3328
+ }
3329
+ else {
3330
+ if (enumsMap.has(expectedType)) {
3331
+ return expectedType;
3332
+ }
3333
+ if (!typeMap[expectedType]) {
3334
+ return expectedType;
3335
+ }
3336
+ var discriminatorProperty = typeMap[expectedType].discriminator;
3337
+ if (discriminatorProperty == null) {
3338
+ return expectedType;
3339
+ }
3340
+ else {
3341
+ if (data[discriminatorProperty]) {
3342
+ var discriminatorType = data[discriminatorProperty];
3343
+ if (typeMap[discriminatorType]) {
3344
+ return discriminatorType;
3345
+ }
3346
+ else {
3347
+ return expectedType;
3348
+ }
3349
+ }
3350
+ else {
3351
+ return expectedType;
3352
+ }
3353
+ }
3354
+ }
3355
+ };
3356
+ ObjectSerializer.serialize = function (data, type, format) {
3357
+ if (data == undefined) {
3358
+ return data;
3359
+ }
3360
+ else if (primitives.indexOf(type.toLowerCase()) !== -1) {
3361
+ return data;
3362
+ }
3363
+ else if (type.lastIndexOf("Array<", 0) === 0) {
3364
+ var subType = type.replace("Array<", "");
3365
+ subType = subType.substring(0, subType.length - 1);
3366
+ var transformedData = [];
3367
+ for (var index in data) {
3368
+ var date = data[index];
3369
+ transformedData.push(ObjectSerializer.serialize(date, subType, format));
3370
+ }
3371
+ return transformedData;
3372
+ }
3373
+ else if (type === "Date") {
3374
+ if (format == "date") {
3375
+ var month = data.getMonth() + 1;
3376
+ month = month < 10 ? "0" + month.toString() : month.toString();
3377
+ var day = data.getDate();
3378
+ day = day < 10 ? "0" + day.toString() : day.toString();
3379
+ return data.getFullYear() + "-" + month + "-" + day;
3380
+ }
3381
+ else {
3382
+ return data.toISOString();
3383
+ }
3384
+ }
3385
+ else {
3386
+ if (enumsMap.has(type)) {
3387
+ return data;
3388
+ }
3389
+ if (!typeMap[type]) {
3390
+ return data;
3391
+ }
3392
+ type = this.findCorrectType(data, type);
3393
+ var attributeTypes = typeMap[type].getAttributeTypeMap();
3394
+ var instance = {};
3395
+ for (var index in attributeTypes) {
3396
+ var attributeType = attributeTypes[index];
3397
+ instance[attributeType.baseName] = ObjectSerializer.serialize(data[attributeType.name], attributeType.type, attributeType.format);
3398
+ }
3399
+ return instance;
3400
+ }
3401
+ };
3402
+ ObjectSerializer.deserialize = function (data, type, format) {
3403
+ type = ObjectSerializer.findCorrectType(data, type);
3404
+ if (data == undefined) {
3405
+ return data;
3406
+ }
3407
+ else if (primitives.indexOf(type.toLowerCase()) !== -1) {
3408
+ return data;
3409
+ }
3410
+ else if (type.lastIndexOf("Array<", 0) === 0) {
3411
+ var subType = type.replace("Array<", "");
3412
+ subType = subType.substring(0, subType.length - 1);
3413
+ var transformedData = [];
3414
+ for (var index in data) {
3415
+ var date = data[index];
3416
+ transformedData.push(ObjectSerializer.deserialize(date, subType, format));
3417
+ }
3418
+ return transformedData;
3419
+ }
3420
+ else if (type === "Date") {
3421
+ return new Date(data);
3422
+ }
3423
+ else {
3424
+ if (enumsMap.has(type)) {
3425
+ return data;
3426
+ }
3427
+ if (!typeMap[type]) {
3428
+ return data;
3429
+ }
3430
+ var instance = new typeMap[type]();
3431
+ var attributeTypes = typeMap[type].getAttributeTypeMap();
3432
+ for (var index in attributeTypes) {
3433
+ var attributeType = attributeTypes[index];
3434
+ instance[attributeType.name] = ObjectSerializer.deserialize(data[attributeType.baseName], attributeType.type, attributeType.format);
3435
+ }
3436
+ return instance;
3437
+ }
3438
+ };
3439
+ ObjectSerializer.normalizeMediaType = function (mediaType) {
3440
+ if (mediaType === undefined) {
3441
+ return undefined;
3442
+ }
3443
+ return mediaType.split(";")[0].trim().toLowerCase();
3444
+ };
3445
+ ObjectSerializer.getPreferredMediaType = function (mediaTypes) {
3446
+ if (!mediaTypes) {
3447
+ return "application/json";
3448
+ }
3449
+ var normalMediaTypes = mediaTypes.map(this.normalizeMediaType);
3450
+ var selectedMediaType = undefined;
3451
+ var selectedRank = -Infinity;
3452
+ for (var _i = 0, normalMediaTypes_1 = normalMediaTypes; _i < normalMediaTypes_1.length; _i++) {
3453
+ var mediaType = normalMediaTypes_1[_i];
3454
+ if (supportedMediaTypes[mediaType] > selectedRank) {
3455
+ selectedMediaType = mediaType;
3456
+ selectedRank = supportedMediaTypes[mediaType];
3457
+ }
3458
+ }
3459
+ if (selectedMediaType === undefined) {
3460
+ throw new Error("None of the given media types are supported: " + mediaTypes.join(", "));
3461
+ }
3462
+ return selectedMediaType;
3463
+ };
3464
+ ObjectSerializer.stringify = function (data, mediaType) {
3465
+ if (mediaType === "application/json") {
3466
+ return JSON.stringify(data);
3467
+ }
3468
+ throw new Error("The mediaType " + mediaType + " is not supported by ObjectSerializer.stringify.");
3469
+ };
3470
+ ObjectSerializer.parse = function (rawData, mediaType) {
3471
+ if (mediaType === undefined) {
3472
+ throw new Error("Cannot parse content. No Content-Type defined.");
3473
+ }
3474
+ if (mediaType === "application/json") {
3475
+ return JSON.parse(rawData);
3476
+ }
3477
+ throw new Error("The mediaType " + mediaType + " is not supported by ObjectSerializer.parse.");
3478
+ };
3479
+ return ObjectSerializer;
3480
+ }());
3481
+ exports.ObjectSerializer = ObjectSerializer;
3482
+ //# sourceMappingURL=ObjectSerializer.js.map
3483
+ });
3484
+
3485
+ const ObjectSerializer = /*@__PURE__*/getDefaultExportFromCjs(ObjectSerializer_1);
3486
+
3487
+ var util = createCommonjsModule(function (module, exports) {
3488
+ "use strict";
3489
+ Object.defineProperty(exports, "__esModule", { value: true });
3490
+ exports.canConsumeForm = exports.isCodeInRange = void 0;
3491
+ function isCodeInRange(codeRange, code) {
3492
+ if (codeRange === "0") {
3493
+ return true;
3494
+ }
3495
+ if (codeRange == code.toString()) {
3496
+ return true;
3497
+ }
3498
+ else {
3499
+ var codeString = code.toString();
3500
+ if (codeString.length != codeRange.length) {
3501
+ return false;
3502
+ }
3503
+ for (var i = 0; i < codeString.length; i++) {
3504
+ if (codeRange.charAt(i) != "X" && codeRange.charAt(i) != codeString.charAt(i)) {
3505
+ return false;
3506
+ }
3507
+ }
3508
+ return true;
3509
+ }
3510
+ }
3511
+ exports.isCodeInRange = isCodeInRange;
3512
+ function canConsumeForm(contentTypes) {
3513
+ return contentTypes.indexOf('multipart/form-data') !== -1;
3514
+ }
3515
+ exports.canConsumeForm = canConsumeForm;
3516
+ //# sourceMappingURL=util.js.map
3517
+ });
3518
+
3519
+ const util$1 = /*@__PURE__*/getDefaultExportFromCjs(util);
3520
+
3521
+ var DefaultApi = createCommonjsModule(function (module, exports) {
3522
+ "use strict";
3523
+ var __extends = (commonjsGlobal && commonjsGlobal.__extends) || (function () {
3524
+ var extendStatics = function (d, b) {
3525
+ extendStatics = Object.setPrototypeOf ||
3526
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
3527
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
3528
+ return extendStatics(d, b);
3529
+ };
3530
+ return function (d, b) {
3531
+ if (typeof b !== "function" && b !== null)
3532
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
3533
+ extendStatics(d, b);
3534
+ function __() { this.constructor = d; }
3535
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
3536
+ };
3537
+ })();
3538
+ var __awaiter = (commonjsGlobal && commonjsGlobal.__awaiter) || function (thisArg, _arguments, P, generator) {
3539
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3540
+ return new (P || (P = Promise))(function (resolve, reject) {
3541
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
3542
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
3543
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
3544
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
3545
+ });
3546
+ };
3547
+ var __generator = (commonjsGlobal && commonjsGlobal.__generator) || function (thisArg, body) {
3548
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
3549
+ return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
3550
+ function verb(n) { return function (v) { return step([n, v]); }; }
3551
+ function step(op) {
3552
+ if (f) throw new TypeError("Generator is already executing.");
3553
+ while (_) try {
3554
+ 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;
3555
+ if (y = 0, t) op = [op[0] & 2, t.value];
3556
+ switch (op[0]) {
3557
+ case 0: case 1: t = op; break;
3558
+ case 4: _.label++; return { value: op[1], done: false };
3559
+ case 5: _.label++; y = op[1]; op = [0]; continue;
3560
+ case 7: op = _.ops.pop(); _.trys.pop(); continue;
3561
+ default:
3562
+ if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
3563
+ if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
3564
+ if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
3565
+ if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
3566
+ if (t[2]) _.ops.pop();
3567
+ _.trys.pop(); continue;
3568
+ }
3569
+ op = body.call(thisArg, _);
3570
+ } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
3571
+ if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
3572
+ }
3573
+ };
3574
+ Object.defineProperty(exports, "__esModule", { value: true });
3575
+ exports.DefaultApiResponseProcessor = exports.DefaultApiRequestFactory = void 0;
3576
+
3577
+
3578
+
3579
+
3580
+
3581
+ var DefaultApiRequestFactory = (function (_super) {
3582
+ __extends(DefaultApiRequestFactory, _super);
3583
+ function DefaultApiRequestFactory() {
3584
+ return _super !== null && _super.apply(this, arguments) || this;
3585
+ }
3586
+ DefaultApiRequestFactory.prototype.trackEvent = function (product_view_event___product_click_event___widget_event___filter_event___search_event, _options) {
3587
+ var _a, _b, _c;
3588
+ return __awaiter(this, void 0, void 0, function () {
3589
+ var _config, localVarPath, requestContext, contentType, serializedBody, authMethod, defaultAuth;
3590
+ return __generator(this, function (_d) {
3591
+ switch (_d.label) {
3592
+ case 0:
3593
+ _config = _options || this.configuration;
3594
+ localVarPath = '/event';
3595
+ requestContext = _config.baseServer.makeRequestContext(localVarPath, http.HttpMethod.POST);
3596
+ requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
3597
+ contentType = ObjectSerializer_1.ObjectSerializer.getPreferredMediaType([
3598
+ "application/json"
3599
+ ]);
3600
+ requestContext.setHeaderParam("Content-Type", contentType);
3601
+ serializedBody = ObjectSerializer_1.ObjectSerializer.stringify(ObjectSerializer_1.ObjectSerializer.serialize(product_view_event___product_click_event___widget_event___filter_event___search_event, "ProductViewEvent | ProductClickEvent | WidgetEvent | FilterEvent | SearchEvent", ""), contentType);
3602
+ requestContext.setBody(serializedBody);
3603
+ authMethod = _config.authMethods["bearerAuth"];
3604
+ if (!(authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication)) return [3, 2];
3605
+ return [4, (authMethod === null || authMethod === void 0 ? void 0 : authMethod.applySecurityAuthentication(requestContext))];
3606
+ case 1:
3607
+ _d.sent();
3608
+ _d.label = 2;
3609
+ case 2:
3610
+ defaultAuth = ((_a = _options === null || _options === void 0 ? void 0 : _options.authMethods) === null || _a === void 0 ? void 0 : _a.default) || ((_c = (_b = this.configuration) === null || _b === void 0 ? void 0 : _b.authMethods) === null || _c === void 0 ? void 0 : _c.default);
3611
+ if (!(defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication)) return [3, 4];
3612
+ return [4, (defaultAuth === null || defaultAuth === void 0 ? void 0 : defaultAuth.applySecurityAuthentication(requestContext))];
3613
+ case 3:
3614
+ _d.sent();
3615
+ _d.label = 4;
3616
+ case 4: return [2, requestContext];
3617
+ }
3618
+ });
3619
+ });
3620
+ };
3621
+ return DefaultApiRequestFactory;
3622
+ }(baseapi.BaseAPIRequestFactory));
3623
+ exports.DefaultApiRequestFactory = DefaultApiRequestFactory;
3624
+ var DefaultApiResponseProcessor = (function () {
3625
+ function DefaultApiResponseProcessor() {
3626
+ }
3627
+ DefaultApiResponseProcessor.prototype.trackEvent = function (response) {
3628
+ return __awaiter(this, void 0, void 0, function () {
3629
+ var contentType, body, _a, _b, _c, _d, body, _e, _f, _g, _h, body, _j, _k, _l, _m, _o, _p;
3630
+ return __generator(this, function (_q) {
3631
+ switch (_q.label) {
3632
+ case 0:
3633
+ contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
3634
+ if (!(0, util.isCodeInRange)("200", response.httpStatusCode)) return [3, 2];
3635
+ _b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
3636
+ _d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
3637
+ return [4, response.body.text()];
3638
+ case 1:
3639
+ body = _b.apply(_a, [_d.apply(_c, [_q.sent(), contentType]),
3640
+ "EventConfirmation", ""]);
3641
+ return [2, body];
3642
+ case 2:
3643
+ if (!(0, util.isCodeInRange)("502", response.httpStatusCode)) return [3, 4];
3644
+ _f = (_e = ObjectSerializer_1.ObjectSerializer).deserialize;
3645
+ _h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
3646
+ return [4, response.body.text()];
3647
+ case 3:
3648
+ body = _f.apply(_e, [_h.apply(_g, [_q.sent(), contentType]),
3649
+ "ErrorResponse", ""]);
3650
+ throw new exception.ApiException(502, "an error occurred", body, response.headers);
3651
+ case 4:
3652
+ if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3, 6];
3653
+ _k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
3654
+ _m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
3655
+ return [4, response.body.text()];
3656
+ case 5:
3657
+ body = _k.apply(_j, [_m.apply(_l, [_q.sent(), contentType]),
3658
+ "EventConfirmation", ""]);
3659
+ return [2, body];
3660
+ case 6:
3661
+ _o = exception.ApiException.bind;
3662
+ _p = [void 0, response.httpStatusCode, "Unknown API Status Code!"];
3663
+ return [4, response.getBodyAsAny()];
3664
+ case 7: throw new (_o.apply(exception.ApiException, _p.concat([_q.sent(), response.headers])))();
3665
+ }
3666
+ });
3667
+ });
3668
+ };
3669
+ return DefaultApiResponseProcessor;
3670
+ }());
3671
+ exports.DefaultApiResponseProcessor = DefaultApiResponseProcessor;
3672
+ //# sourceMappingURL=DefaultApi.js.map
3673
+ });
3674
+
3675
+ const DefaultApi$1 = /*@__PURE__*/getDefaultExportFromCjs(DefaultApi);
3676
+
3677
+ var ObservableAPI = createCommonjsModule(function (module, exports) {
3678
+ "use strict";
3679
+ Object.defineProperty(exports, "__esModule", { value: true });
3680
+ exports.ObservableDefaultApi = void 0;
3681
+
3682
+ var rxjsStub_2 = rxjsStub;
3683
+
3684
+ var ObservableDefaultApi = (function () {
3685
+ function ObservableDefaultApi(configuration, requestFactory, responseProcessor) {
3686
+ this.configuration = configuration;
3687
+ this.requestFactory = requestFactory || new DefaultApi.DefaultApiRequestFactory(configuration);
3688
+ this.responseProcessor = responseProcessor || new DefaultApi.DefaultApiResponseProcessor();
3689
+ }
3690
+ ObservableDefaultApi.prototype.trackEvent = function (product_view_event___product_click_event___widget_event___filter_event___search_event, _options) {
3691
+ var _this = this;
3692
+ var requestContextPromise = this.requestFactory.trackEvent(product_view_event___product_click_event___widget_event___filter_event___search_event, _options);
3693
+ var middlewarePreObservable = (0, rxjsStub.from)(requestContextPromise);
3694
+ var _loop_1 = function (middleware) {
3695
+ middlewarePreObservable = middlewarePreObservable.pipe((0, rxjsStub_2.mergeMap)(function (ctx) { return middleware.pre(ctx); }));
3696
+ };
3697
+ for (var _i = 0, _a = this.configuration.middleware; _i < _a.length; _i++) {
3698
+ var middleware = _a[_i];
3699
+ _loop_1(middleware);
3700
+ }
3701
+ return middlewarePreObservable.pipe((0, rxjsStub_2.mergeMap)(function (ctx) { return _this.configuration.httpApi.send(ctx); })).
3702
+ pipe((0, rxjsStub_2.mergeMap)(function (response) {
3703
+ var middlewarePostObservable = (0, rxjsStub.of)(response);
3704
+ var _loop_2 = function (middleware) {
3705
+ middlewarePostObservable = middlewarePostObservable.pipe((0, rxjsStub_2.mergeMap)(function (rsp) { return middleware.post(rsp); }));
3706
+ };
3707
+ for (var _i = 0, _a = _this.configuration.middleware; _i < _a.length; _i++) {
3708
+ var middleware = _a[_i];
3709
+ _loop_2(middleware);
3710
+ }
3711
+ return middlewarePostObservable.pipe((0, rxjsStub_2.map)(function (rsp) { return _this.responseProcessor.trackEvent(rsp); }));
3712
+ }));
3713
+ };
3714
+ return ObservableDefaultApi;
3715
+ }());
3716
+ exports.ObservableDefaultApi = ObservableDefaultApi;
3717
+ //# sourceMappingURL=ObservableAPI.js.map
3718
+ });
3719
+
3720
+ const ObservableAPI$1 = /*@__PURE__*/getDefaultExportFromCjs(ObservableAPI);
3721
+
3722
+ var PromiseAPI = createCommonjsModule(function (module, exports) {
3723
+ "use strict";
3724
+ Object.defineProperty(exports, "__esModule", { value: true });
3725
+ exports.PromiseDefaultApi = void 0;
3726
+
3727
+ var PromiseDefaultApi = (function () {
3728
+ function PromiseDefaultApi(configuration, requestFactory, responseProcessor) {
3729
+ this.api = new ObservableAPI.ObservableDefaultApi(configuration, requestFactory, responseProcessor);
3730
+ }
3731
+ PromiseDefaultApi.prototype.trackEvent = function (product_view_event___product_click_event___widget_event___filter_event___search_event, _options) {
3732
+ var result = this.api.trackEvent(product_view_event___product_click_event___widget_event___filter_event___search_event, _options);
3733
+ return result.toPromise();
3734
+ };
3735
+ return PromiseDefaultApi;
3736
+ }());
3737
+ exports.PromiseDefaultApi = PromiseDefaultApi;
3738
+ //# sourceMappingURL=PromiseAPI.js.map
3739
+ });
3740
+
3741
+ const PromiseAPI$1 = /*@__PURE__*/getDefaultExportFromCjs(PromiseAPI);
3742
+
3743
+ var dist = createCommonjsModule(function (module, exports) {
3744
+ "use strict";
3745
+ var __createBinding = (commonjsGlobal && commonjsGlobal.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3746
+ if (k2 === undefined) k2 = k;
3747
+ var desc = Object.getOwnPropertyDescriptor(m, k);
3748
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
3749
+ desc = { enumerable: true, get: function() { return m[k]; } };
3750
+ }
3751
+ Object.defineProperty(o, k2, desc);
3752
+ }) : (function(o, m, k, k2) {
3753
+ if (k2 === undefined) k2 = k;
3754
+ o[k2] = m[k];
3755
+ }));
3756
+ var __exportStar = (commonjsGlobal && commonjsGlobal.__exportStar) || function(m, exports) {
3757
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
3758
+ };
3759
+ Object.defineProperty(exports, "__esModule", { value: true });
3760
+ exports.DefaultApi = exports.createConfiguration = void 0;
3761
+ __exportStar(http, exports);
3762
+ __exportStar(auth, exports);
3763
+ __exportStar(all, exports);
3764
+
3765
+ Object.defineProperty(exports, "createConfiguration", { enumerable: true, get: function () { return configuration.createConfiguration; } });
3766
+ __exportStar(exception, exports);
3767
+ __exportStar(servers, exports);
3768
+
3769
+ Object.defineProperty(exports, "DefaultApi", { enumerable: true, get: function () { return PromiseAPI.PromiseDefaultApi; } });
3770
+ //# sourceMappingURL=index.js.map
3771
+ });
3772
+
3773
+ const index = /*@__PURE__*/getDefaultExportFromCjs(dist);
3774
+
3775
+ const STAGE_SERVER_IDENTIFIER = "stage";
3776
+ const getTrackingServerByApiPath = (apiPath) => isProductionPath(apiPath) ? dist.servers[0] : dist.servers[1];
3777
+ const isProductionPath = (apiPath) => !apiPath.includes(STAGE_SERVER_IDENTIFIER);
3778
+ // TODO find way to utilize this function when we will use several openApi clients
3779
+ const createBearerAuth = (token) => {
3780
+ const provider = {
3781
+ getToken: () => {
3782
+ return new Promise((resolve) => resolve(token));
3783
+ },
3784
+ };
3785
+ const bearerConf = {
3786
+ tokenProvider: provider,
3787
+ };
3788
+ return {
3789
+ bearerAuth: bearerConf,
3790
+ };
3791
+ };
3792
+ const createTrackingApi = (apiPath, token) => {
3793
+ const baseServer = getTrackingServerByApiPath(apiPath);
3794
+ const authMethods = createBearerAuth(token);
3795
+ const configuration = {
3796
+ baseServer,
3797
+ authMethods,
3798
+ };
3799
+ return new dist.DefaultApi(dist.createConfiguration(configuration));
3800
+ };
3801
+
3802
+ const createTrackingEvent = (widget) => (eventData) => {
3803
+ return Object.assign(Object.assign({}, eventData), widget);
3804
+ };
3805
+
3806
+ const PRODUCT_CLICK_EVENT_TYPE = "product_click_event";
3807
+ const PRODUCT_VIEW_EVENT_TYPE = "product_view_event";
3808
+ const FILTER_EVENT_EVENT_TYPE = "filter_event";
3809
+ const SEARCH_EVENT_EVENT_TYPE = "search_event";
3810
+ const WIDGET_EVENT_EVENT_TYPE = "widget_event";
3811
+
3812
+ const filterEvent = {
3813
+ widget: "VPS",
3814
+ typ: FILTER_EVENT_EVENT_TYPE,
3815
+ };
3816
+
3817
+ const vprProductView = {
3818
+ widget: "VPR",
3819
+ typ: PRODUCT_VIEW_EVENT_TYPE,
3820
+ };
3821
+ const vpsProductView = {
3822
+ widget: "VPS",
3823
+ typ: PRODUCT_VIEW_EVENT_TYPE,
3824
+ };
3825
+ const vprProductClick = {
3826
+ widget: "VPR",
3827
+ typ: PRODUCT_CLICK_EVENT_TYPE,
3828
+ };
3829
+ const vpsProductClick = {
3830
+ widget: "VPS",
3831
+ typ: PRODUCT_CLICK_EVENT_TYPE,
3832
+ };
3833
+
3834
+ const searchEvent = {
3835
+ widget: "VPS",
3836
+ typ: SEARCH_EVENT_EVENT_TYPE,
3837
+ };
3838
+
3839
+ const vprWidget = {
3840
+ widget: "VPR",
3841
+ typ: WIDGET_EVENT_EVENT_TYPE,
3842
+ };
3843
+ const vpsWidget = {
3844
+ widget: "VPS",
3845
+ typ: WIDGET_EVENT_EVENT_TYPE,
3846
+ };
3847
+
3848
+ const createProductViewVprEvent = createTrackingEvent(vprProductView);
3849
+ const createProductViewVpsEvent = createTrackingEvent(vpsProductView);
3850
+ const createProductClickVprEvent = createTrackingEvent(vprProductClick);
3851
+ const createProductClickVpsEvent = createTrackingEvent(vpsProductClick);
3852
+ const createWidgetVprEvent = createTrackingEvent(vprWidget);
3853
+ const createWidgetVpsEvent = createTrackingEvent(vpsWidget);
3854
+ const createSearchEvent = createTrackingEvent(searchEvent);
3855
+ const createFilterEvent = createTrackingEvent(filterEvent);
3856
+
3857
+ export { createProductClickVpsEvent as a, createSearchEvent as b, createProductViewVpsEvent as c, createFilterEvent as d, createTrackingApi as e, createWidgetVpsEvent as f, createProductViewVprEvent as g, createProductClickVprEvent as h, createWidgetVprEvent as i, v4 as v };