@sparkle-learning/core 0.0.27 → 0.0.30

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 (697) hide show
  1. package/dist/cjs/{PrivateRoute-cee9b061.js → PrivateRoute-043bb7d3.js} +6 -40
  2. package/dist/cjs/{active-router-3bd7b540.js → active-router-eedb3bfe.js} +1 -1
  3. package/dist/cjs/{animation-05337433.js → animation-6132e37f.js} +28 -4
  4. package/dist/cjs/app-globals-9869bf67.js +9 -0
  5. package/dist/cjs/{auth.store-aba3d22f.js → auth.store-ff3fda09.js} +1869 -357
  6. package/dist/cjs/compass-svg.cjs.entry.js +1 -1
  7. package/dist/cjs/context-consumer.cjs.entry.js +1 -1
  8. package/dist/cjs/course-select.cjs.entry.js +1 -1
  9. package/dist/cjs/{cubic-bezier-24e309bf.js → cubic-bezier-293f4663.js} +3 -0
  10. package/dist/cjs/dir-5af5259a.js +20 -0
  11. package/dist/cjs/{facilitator.service-e1e2f719.js → facilitator.service-faac5c0c.js} +1 -1
  12. package/dist/cjs/feed.service-66405969.js +124 -0
  13. package/dist/cjs/focus-visible-ad3828a7.js +63 -0
  14. package/dist/cjs/framework-delegate-2470a246.js +113 -0
  15. package/dist/cjs/{gesture-controller-e824cfb3.js → gesture-controller-07c31f70.js} +3 -0
  16. package/dist/cjs/{haptic-415dac5b.js → haptic-91e86eb7.js} +3 -0
  17. package/dist/cjs/{hardware-back-button-ca468aae.js → hardware-back-button-f7b5d99e.js} +3 -0
  18. package/dist/cjs/header-mobile-collapse_61.cjs.entry.js +18001 -0
  19. package/dist/cjs/{helpers-26770c32.js → helpers-7e28976c.js} +122 -3
  20. package/dist/cjs/{icons-a0fef92b.js → icons-b8a2231a.js} +1 -1
  21. package/dist/cjs/{index-427d03fb.js → index-185f9c5a.js} +3 -0
  22. package/dist/cjs/{index-6eff209d.js → index-43642662.js} +24 -3
  23. package/dist/cjs/{index-7bcd36a0.js → index-459a5fa9.js} +20 -4
  24. package/dist/cjs/index-8540d72e.js +42 -0
  25. package/dist/cjs/{index-58b3ee93.js → index-b12edb26.js} +34 -5
  26. package/dist/cjs/{index-fbf4d3bf.js → index-bae2a754.js} +303 -207
  27. package/dist/cjs/index.cjs.js +8 -7
  28. package/dist/cjs/index.es-ef3efdfb.js +10671 -0
  29. package/dist/cjs/{input-shims-213e83f8.js → input-shims-6c442c9f.js} +34 -10
  30. package/dist/cjs/ion-accordion-group.cjs.entry.js +197 -0
  31. package/dist/cjs/ion-accordion.cjs.entry.js +340 -0
  32. package/dist/cjs/ion-action-sheet_4.cjs.entry.js +2203 -0
  33. package/dist/cjs/ion-app.cjs.entry.js +23 -8
  34. package/dist/cjs/ion-back-button.cjs.entry.js +14 -9
  35. package/dist/cjs/ion-backdrop.cjs.entry.js +3 -3
  36. package/dist/cjs/ion-badge.cjs.entry.js +3 -3
  37. package/dist/cjs/ion-breadcrumb.cjs.entry.js +103 -0
  38. package/dist/cjs/ion-breadcrumbs.cjs.entry.js +135 -0
  39. package/dist/cjs/ion-buttons_3.cjs.entry.js +7 -6
  40. package/dist/cjs/ion-card-header.cjs.entry.js +3 -3
  41. package/dist/cjs/ion-card-subtitle.cjs.entry.js +3 -3
  42. package/dist/cjs/ion-card-title.cjs.entry.js +3 -3
  43. package/dist/cjs/ion-chip.cjs.entry.js +3 -3
  44. package/dist/cjs/ion-content_2.cjs.entry.js +144 -56
  45. package/dist/cjs/ion-datetime.cjs.entry.js +1902 -779
  46. package/dist/cjs/ion-fab-button.cjs.entry.js +5 -4
  47. package/dist/cjs/ion-fab-list.cjs.entry.js +2 -2
  48. package/dist/cjs/ion-fab.cjs.entry.js +2 -2
  49. package/dist/cjs/ion-footer.cjs.entry.js +79 -4
  50. package/dist/cjs/ion-img.cjs.entry.js +33 -7
  51. package/dist/cjs/ion-infinite-scroll-content.cjs.entry.js +3 -3
  52. package/dist/cjs/ion-infinite-scroll.cjs.entry.js +4 -2
  53. package/dist/cjs/ion-item-divider.cjs.entry.js +3 -3
  54. package/dist/cjs/ion-item-group.cjs.entry.js +2 -2
  55. package/dist/cjs/ion-item-option.cjs.entry.js +4 -4
  56. package/dist/cjs/ion-item-options.cjs.entry.js +3 -3
  57. package/dist/cjs/ion-item-sliding.cjs.entry.js +52 -8
  58. package/dist/cjs/ion-loading.cjs.entry.js +23 -11
  59. package/dist/cjs/ion-menu-button.cjs.entry.js +17 -11
  60. package/dist/cjs/ion-menu-toggle.cjs.entry.js +7 -7
  61. package/dist/cjs/ion-menu.cjs.entry.js +141 -29
  62. package/dist/cjs/ion-modal.cjs.entry.js +649 -75
  63. package/dist/cjs/ion-nav-link.cjs.entry.js +4 -1
  64. package/dist/cjs/ion-nav.cjs.entry.js +140 -137
  65. package/dist/cjs/ion-picker-column-internal_2.cjs.entry.js +700 -0
  66. package/dist/cjs/ion-picker-column.cjs.entry.js +5 -5
  67. package/dist/cjs/ion-picker.cjs.entry.js +18 -11
  68. package/dist/cjs/ion-progress-bar.cjs.entry.js +17 -13
  69. package/dist/cjs/ion-refresher-content.cjs.entry.js +7 -6
  70. package/dist/cjs/ion-refresher.cjs.entry.js +83 -84
  71. package/dist/cjs/ion-reorder-group.cjs.entry.js +9 -8
  72. package/dist/cjs/ion-reorder.cjs.entry.js +5 -4
  73. package/dist/cjs/ion-route-redirect.cjs.entry.js +1 -1
  74. package/dist/cjs/ion-route.cjs.entry.js +1 -1
  75. package/dist/cjs/ion-router-link.cjs.entry.js +3 -3
  76. package/dist/cjs/ion-router-outlet.cjs.entry.js +50 -12
  77. package/dist/cjs/ion-router.cjs.entry.js +378 -234
  78. package/dist/cjs/ion-searchbar.cjs.entry.js +50 -17
  79. package/dist/cjs/ion-segment-button.cjs.entry.js +12 -9
  80. package/dist/cjs/ion-segment.cjs.entry.js +89 -10
  81. package/dist/cjs/ion-select_2.cjs.entry.js +64 -30
  82. package/dist/cjs/ion-skeleton-text.cjs.entry.js +4 -4
  83. package/dist/cjs/ion-slide.cjs.entry.js +2 -2
  84. package/dist/cjs/ion-slides.cjs.entry.js +19 -32
  85. package/dist/cjs/ion-split-pane.cjs.entry.js +8 -3
  86. package/dist/cjs/ion-tab-bar.cjs.entry.js +25 -12
  87. package/dist/cjs/ion-tab-button.cjs.entry.js +2 -2
  88. package/dist/cjs/ion-tab.cjs.entry.js +3 -2
  89. package/dist/cjs/ion-tabs.cjs.entry.js +1 -1
  90. package/dist/cjs/ion-textarea.cjs.entry.js +9 -8
  91. package/dist/cjs/ion-thumbnail.cjs.entry.js +2 -2
  92. package/dist/cjs/ion-toast.cjs.entry.js +37 -27
  93. package/dist/cjs/ion-toggle.cjs.entry.js +15 -15
  94. package/dist/cjs/ion-virtual-scroll.cjs.entry.js +13 -3
  95. package/dist/cjs/{ionic-global-4930d319.js → ionic-global-878073d1.js} +103 -77
  96. package/dist/cjs/{ios.transition-6e1fd3d6.js → ios.transition-c3bfb096.js} +8 -5
  97. package/dist/cjs/{keyboard-1dcbde6c.js → keyboard-dfd76ac3.js} +3 -0
  98. package/dist/cjs/loader.cjs.js +5 -5
  99. package/dist/cjs/localstorage.service-6346a41d.js +40 -0
  100. package/dist/cjs/{md.transition-3652ad78.js → md.transition-7eb9a1a7.js} +7 -4
  101. package/dist/cjs/{menu-toggle-util-a8fb4c56.js → menu-toggle-util-cb549c2c.js} +4 -1
  102. package/dist/cjs/{overlays-08a817ea.js → overlays-0a748609.js} +188 -47
  103. package/dist/cjs/{purify-596fc2d6.js → purify-d0ad2883.js} +187 -74
  104. package/dist/cjs/sparkle-animation-player.cjs.entry.js +56 -50
  105. package/dist/cjs/sparkle-character-intro.cjs.entry.js +26 -0
  106. package/dist/cjs/sparkle-code.cjs.entry.js +2 -2
  107. package/dist/cjs/sparkle-compass-post.cjs.entry.js +1 -1
  108. package/dist/cjs/sparkle-compass.cjs.entry.js +1 -1
  109. package/dist/cjs/sparkle-core.cjs.js +7 -7
  110. package/dist/cjs/sparkle-emoji.cjs.entry.js +1 -1
  111. package/dist/cjs/sparkle-facilitator-notes-form.cjs.entry.js +7 -7
  112. package/dist/cjs/sparkle-feed-post.cjs.entry.js +1 -1
  113. package/dist/cjs/sparkle-feedback.cjs.entry.js +7 -7
  114. package/dist/cjs/sparkle-goal-form.cjs.entry.js +15 -14
  115. package/dist/cjs/sparkle-gww-comment-list.cjs.entry.js +1 -1
  116. package/dist/cjs/sparkle-gww-graph.cjs.entry.js +1 -1
  117. package/dist/cjs/sparkle-lower-content-nav.cjs.entry.js +1 -1
  118. package/dist/cjs/sparkle-menu-collapsible.cjs.entry.js +2 -2
  119. package/dist/cjs/sparkle-modal-image.cjs.entry.js +1 -1
  120. package/dist/cjs/sparkle-notfound-page.cjs.entry.js +1 -1
  121. package/dist/cjs/sparkle-overlay.cjs.entry.js +1 -1
  122. package/dist/cjs/sparkle-poll.cjs.entry.js +1 -1
  123. package/dist/cjs/sparkle-quiz-container.cjs.entry.js +1 -1
  124. package/dist/cjs/sparkle-quiz-feedback_5.cjs.entry.js +1 -1
  125. package/dist/cjs/sparkle-quiz.cjs.entry.js +2 -2
  126. package/dist/cjs/sparkle-select.cjs.entry.js +1 -1
  127. package/dist/cjs/sparkle-sidebar.cjs.entry.js +1 -1
  128. package/dist/cjs/sparkle-tab.cjs.entry.js +1 -1
  129. package/dist/cjs/sparkle-table-of-contents.cjs.entry.js +1 -1
  130. package/dist/cjs/sparkle-tabs.cjs.entry.js +1 -1
  131. package/dist/cjs/sparkle-youtube.cjs.entry.js +2 -2
  132. package/dist/cjs/{spinner-configs-559523fd.js → spinner-configs-6f6b7ef0.js} +36 -1
  133. package/dist/cjs/status-tap-8697433c.js +40 -0
  134. package/dist/cjs/stencil-async-content.cjs.entry.js +1 -1
  135. package/dist/cjs/stencil-route-title.cjs.entry.js +2 -2
  136. package/dist/cjs/stencil-router-prompt.cjs.entry.js +2 -2
  137. package/dist/cjs/{student.service-41c7c78d.js → student.service-744c3155.js} +1 -1
  138. package/dist/cjs/{swipe-back-c1951cbd.js → swipe-back-7e08b5e0.js} +32 -8
  139. package/dist/cjs/{swiper.bundle-cbea42d8.js → swiper.bundle-8c897c07.js} +4 -4
  140. package/dist/cjs/{tap-click-cd858b48.js → tap-click-1caf1780.js} +8 -1
  141. package/dist/cjs/{theme-98ccfc24.js → theme-4252ac15.js} +3 -0
  142. package/dist/cjs/util-d383acb8.js +2462 -0
  143. package/dist/collection/collection-manifest.json +9 -2
  144. package/dist/collection/components/layout/page/page.js +1 -0
  145. package/dist/collection/components/sparkle-animation-player/sparkle-animation-player.js +78 -66
  146. package/dist/collection/components/sparkle-character-intro/assets/characters/character-img.jpg +0 -0
  147. package/dist/collection/components/sparkle-character-intro/assets/characters/jen.png +0 -0
  148. package/dist/collection/components/sparkle-character-intro/assets/characters/kimberly.png +0 -0
  149. package/dist/collection/components/sparkle-character-intro/assets/characters/valeria.png +0 -0
  150. package/dist/collection/components/sparkle-character-intro/assets/characters/yuna.png +0 -0
  151. package/dist/collection/components/sparkle-character-intro/assets/characters/zynab.png +0 -0
  152. package/dist/collection/components/sparkle-character-intro/sparkle-character-intro.css +67 -0
  153. package/dist/collection/components/sparkle-character-intro/sparkle-character-intro.js +64 -0
  154. package/dist/collection/components/sparkle-course-root/sparkle-course-root.js +48 -43
  155. package/dist/collection/components/sparkle-youtube/sparkle-youtube.js +6 -2
  156. package/dist/collection/util.js +1 -0
  157. package/dist/esm/{PrivateRoute-9f0973bb.js → PrivateRoute-b9937c45.js} +3 -37
  158. package/dist/esm/{active-router-b3ae32c7.js → active-router-909088d6.js} +1 -1
  159. package/dist/esm/{animation-72fdacfb.js → animation-b306f6c2.js} +28 -4
  160. package/dist/esm/app-globals-5c736ae5.js +7 -0
  161. package/dist/esm/auth.store-3ed2389e.js +4061 -0
  162. package/dist/esm/compass-svg.entry.js +1 -1
  163. package/dist/esm/context-consumer.entry.js +1 -1
  164. package/dist/esm/course-select.entry.js +1 -1
  165. package/dist/esm/{cubic-bezier-ed243a9b.js → cubic-bezier-a7ad9c8e.js} +3 -0
  166. package/dist/esm/dir-03012648.js +18 -0
  167. package/dist/esm/{facilitator.service-cddb2feb.js → facilitator.service-ec0a9739.js} +1 -1
  168. package/dist/esm/feed.service-33b83cb7.js +119 -0
  169. package/dist/esm/focus-visible-40cda868.js +61 -0
  170. package/dist/esm/framework-delegate-3bc58c27.js +109 -0
  171. package/dist/esm/{gesture-controller-604336b7.js → gesture-controller-686622ba.js} +3 -0
  172. package/dist/esm/{haptic-67928174.js → haptic-99c9e346.js} +4 -1
  173. package/dist/esm/{hardware-back-button-508e48cf.js → hardware-back-button-b6ccf74a.js} +3 -0
  174. package/dist/esm/header-mobile-collapse_61.entry.js +17937 -0
  175. package/dist/esm/{helpers-e7f66b2b.js → helpers-39367fe1.js} +119 -4
  176. package/dist/esm/{icons-33e5804c.js → icons-5debfbaf.js} +1 -1
  177. package/dist/esm/{index-cc97b114.js → index-435af8e6.js} +3 -0
  178. package/dist/esm/{index-55fc9f5e.js → index-5568e3fa.js} +303 -208
  179. package/dist/esm/{index-dc09784f.js → index-9594837e.js} +20 -4
  180. package/dist/esm/{index-b2ad0f1a.js → index-a12c14bd.js} +25 -4
  181. package/dist/esm/{index-a94619f9.js → index-c26d8655.js} +34 -5
  182. package/dist/esm/index-dc61f152.js +22 -0
  183. package/dist/esm/index.es-97dd8174.js +10585 -0
  184. package/dist/esm/index.js +8 -7
  185. package/dist/esm/{input-shims-3a97fa86.js → input-shims-cc98ea92.js} +34 -10
  186. package/dist/esm/ion-accordion-group.entry.js +193 -0
  187. package/dist/esm/ion-accordion.entry.js +336 -0
  188. package/dist/esm/ion-action-sheet_4.entry.js +2196 -0
  189. package/dist/esm/ion-app.entry.js +23 -8
  190. package/dist/esm/ion-back-button.entry.js +14 -9
  191. package/dist/esm/ion-backdrop.entry.js +3 -3
  192. package/dist/esm/ion-badge.entry.js +3 -3
  193. package/dist/esm/ion-breadcrumb.entry.js +99 -0
  194. package/dist/esm/ion-breadcrumbs.entry.js +131 -0
  195. package/dist/esm/ion-buttons_3.entry.js +7 -6
  196. package/dist/esm/ion-card-header.entry.js +3 -3
  197. package/dist/esm/ion-card-subtitle.entry.js +3 -3
  198. package/dist/esm/ion-card-title.entry.js +3 -3
  199. package/dist/esm/ion-chip.entry.js +3 -3
  200. package/dist/esm/ion-content_2.entry.js +144 -56
  201. package/dist/esm/ion-datetime.entry.js +1902 -779
  202. package/dist/esm/ion-fab-button.entry.js +5 -4
  203. package/dist/esm/ion-fab-list.entry.js +2 -2
  204. package/dist/esm/ion-fab.entry.js +2 -2
  205. package/dist/esm/ion-footer.entry.js +79 -4
  206. package/dist/esm/ion-img.entry.js +33 -7
  207. package/dist/esm/ion-infinite-scroll-content.entry.js +3 -3
  208. package/dist/esm/ion-infinite-scroll.entry.js +4 -2
  209. package/dist/esm/ion-item-divider.entry.js +3 -3
  210. package/dist/esm/ion-item-group.entry.js +2 -2
  211. package/dist/esm/ion-item-option.entry.js +4 -4
  212. package/dist/esm/ion-item-options.entry.js +3 -3
  213. package/dist/esm/ion-item-sliding.entry.js +52 -8
  214. package/dist/esm/ion-loading.entry.js +23 -11
  215. package/dist/esm/ion-menu-button.entry.js +17 -11
  216. package/dist/esm/ion-menu-toggle.entry.js +7 -7
  217. package/dist/esm/ion-menu.entry.js +141 -29
  218. package/dist/esm/ion-modal.entry.js +649 -75
  219. package/dist/esm/ion-nav-link.entry.js +4 -1
  220. package/dist/esm/ion-nav.entry.js +140 -137
  221. package/dist/esm/ion-picker-column-internal_2.entry.js +695 -0
  222. package/dist/esm/ion-picker-column.entry.js +5 -5
  223. package/dist/esm/ion-picker.entry.js +18 -11
  224. package/dist/esm/ion-progress-bar.entry.js +17 -13
  225. package/dist/esm/ion-refresher-content.entry.js +7 -6
  226. package/dist/esm/ion-refresher.entry.js +82 -83
  227. package/dist/esm/ion-reorder-group.entry.js +9 -8
  228. package/dist/esm/ion-reorder.entry.js +5 -4
  229. package/dist/esm/ion-route-redirect.entry.js +1 -1
  230. package/dist/esm/ion-route.entry.js +1 -1
  231. package/dist/esm/ion-router-link.entry.js +3 -3
  232. package/dist/esm/ion-router-outlet.entry.js +50 -12
  233. package/dist/esm/ion-router.entry.js +378 -234
  234. package/dist/esm/ion-searchbar.entry.js +50 -17
  235. package/dist/esm/ion-segment-button.entry.js +12 -9
  236. package/dist/esm/ion-segment.entry.js +89 -10
  237. package/dist/esm/ion-select_2.entry.js +64 -30
  238. package/dist/esm/ion-skeleton-text.entry.js +4 -4
  239. package/dist/esm/ion-slide.entry.js +2 -2
  240. package/dist/esm/ion-slides.entry.js +19 -32
  241. package/dist/esm/ion-split-pane.entry.js +8 -3
  242. package/dist/esm/ion-tab-bar.entry.js +25 -12
  243. package/dist/esm/ion-tab-button.entry.js +2 -2
  244. package/dist/esm/ion-tab.entry.js +3 -2
  245. package/dist/esm/ion-tabs.entry.js +1 -1
  246. package/dist/esm/ion-textarea.entry.js +9 -8
  247. package/dist/esm/ion-thumbnail.entry.js +2 -2
  248. package/dist/esm/ion-toast.entry.js +37 -27
  249. package/dist/esm/ion-toggle.entry.js +15 -15
  250. package/dist/esm/ion-virtual-scroll.entry.js +13 -3
  251. package/dist/esm/{ionic-global-1f9287cc.js → ionic-global-0939c477.js} +103 -77
  252. package/dist/esm/{ios.transition-d01abefd.js → ios.transition-b4ca8a33.js} +8 -5
  253. package/dist/esm/{keyboard-06906eac.js → keyboard-2503e874.js} +3 -0
  254. package/dist/esm/loader.js +5 -5
  255. package/dist/esm/localstorage.service-4bf408c8.js +36 -0
  256. package/dist/esm/{md.transition-245ffa55.js → md.transition-ca5e0322.js} +7 -4
  257. package/dist/esm/{menu-toggle-util-fe83fcf5.js → menu-toggle-util-7fa22c2f.js} +4 -1
  258. package/dist/esm/{overlays-8363621c.js → overlays-34cfa9e0.js} +187 -47
  259. package/dist/esm/polyfills/css-shim.js +1 -1
  260. package/dist/esm/polyfills/index.js +2 -2
  261. package/dist/esm/{purify-4247e2d0.js → purify-ffce2b4c.js} +185 -72
  262. package/dist/esm/sparkle-animation-player.entry.js +56 -50
  263. package/dist/esm/sparkle-character-intro.entry.js +22 -0
  264. package/dist/esm/sparkle-code.entry.js +2 -2
  265. package/dist/esm/sparkle-compass-post.entry.js +1 -1
  266. package/dist/esm/sparkle-compass.entry.js +1 -1
  267. package/dist/esm/sparkle-core.js +7 -7
  268. package/dist/esm/sparkle-emoji.entry.js +1 -1
  269. package/dist/esm/sparkle-facilitator-notes-form.entry.js +7 -7
  270. package/dist/esm/sparkle-feed-post.entry.js +1 -1
  271. package/dist/esm/sparkle-feedback.entry.js +7 -7
  272. package/dist/esm/sparkle-goal-form.entry.js +8 -7
  273. package/dist/esm/sparkle-gww-comment-list.entry.js +1 -1
  274. package/dist/esm/sparkle-gww-graph.entry.js +1 -1
  275. package/dist/esm/sparkle-lower-content-nav.entry.js +1 -1
  276. package/dist/esm/sparkle-menu-collapsible.entry.js +2 -2
  277. package/dist/esm/sparkle-modal-image.entry.js +1 -1
  278. package/dist/esm/sparkle-notfound-page.entry.js +1 -1
  279. package/dist/esm/sparkle-overlay.entry.js +1 -1
  280. package/dist/esm/sparkle-poll.entry.js +1 -1
  281. package/dist/esm/sparkle-quiz-container.entry.js +1 -1
  282. package/dist/esm/sparkle-quiz-feedback_5.entry.js +1 -1
  283. package/dist/esm/sparkle-quiz.entry.js +2 -2
  284. package/dist/esm/sparkle-select.entry.js +1 -1
  285. package/dist/esm/sparkle-sidebar.entry.js +1 -1
  286. package/dist/esm/sparkle-tab.entry.js +1 -1
  287. package/dist/esm/sparkle-table-of-contents.entry.js +1 -1
  288. package/dist/esm/sparkle-tabs.entry.js +1 -1
  289. package/dist/esm/sparkle-youtube.entry.js +2 -2
  290. package/dist/esm/{spinner-configs-9536fae2.js → spinner-configs-f609a655.js} +36 -1
  291. package/dist/esm/status-tap-6351a0cb.js +38 -0
  292. package/dist/esm/stencil-async-content.entry.js +1 -1
  293. package/dist/esm/stencil-route-title.entry.js +2 -2
  294. package/dist/esm/stencil-router-prompt.entry.js +2 -2
  295. package/dist/esm/{student.service-c36c5a75.js → student.service-29b688ba.js} +1 -1
  296. package/dist/esm/{swipe-back-21f58ecf.js → swipe-back-34251834.js} +32 -8
  297. package/dist/esm/{swiper.bundle-d4422d52.js → swiper.bundle-b6a959de.js} +4 -4
  298. package/dist/esm/{tap-click-8c728329.js → tap-click-13f1fb0d.js} +8 -1
  299. package/dist/esm/{theme-12606872.js → theme-c336c9d9.js} +3 -0
  300. package/dist/esm/util-6ef753e9.js +2451 -0
  301. package/dist/loader/index.d.ts +0 -1
  302. package/dist/node_modules/@ionic/core/dist/collection/components/accordion/accordion.ios.css +75 -0
  303. package/dist/node_modules/@ionic/core/dist/collection/components/accordion/accordion.md.css +72 -0
  304. package/dist/node_modules/@ionic/core/dist/collection/components/accordion-group/accordion-group.ios.css +25 -0
  305. package/dist/node_modules/@ionic/core/dist/collection/components/accordion-group/accordion-group.md.css +59 -0
  306. package/dist/node_modules/@ionic/core/dist/collection/components/action-sheet/action-sheet.ios.css +10 -19
  307. package/dist/node_modules/@ionic/core/dist/collection/components/action-sheet/action-sheet.md.css +19 -16
  308. package/dist/node_modules/@ionic/core/dist/collection/components/alert/alert.md.css +2 -2
  309. package/dist/node_modules/@ionic/core/dist/collection/components/back-button/back-button.ios.css +4 -0
  310. package/dist/node_modules/@ionic/core/dist/collection/components/back-button/back-button.md.css +4 -0
  311. package/dist/node_modules/@ionic/core/dist/collection/components/breadcrumb/breadcrumb.ios.css +234 -0
  312. package/dist/node_modules/@ionic/core/dist/collection/components/breadcrumb/breadcrumb.md.css +237 -0
  313. package/dist/node_modules/@ionic/core/dist/collection/components/breadcrumbs/breadcrumbs.ios.css +38 -0
  314. package/dist/node_modules/@ionic/core/dist/collection/components/breadcrumbs/breadcrumbs.md.css +37 -0
  315. package/dist/node_modules/@ionic/core/dist/collection/components/button/button.ios.css +0 -1
  316. package/dist/node_modules/@ionic/core/dist/collection/components/button/button.md.css +5 -5
  317. package/dist/node_modules/@ionic/core/dist/collection/components/content/content.css +60 -14
  318. package/dist/node_modules/@ionic/core/dist/collection/components/datetime/datetime.ios.css +586 -68
  319. package/dist/node_modules/@ionic/core/dist/collection/components/datetime/datetime.md.css +575 -68
  320. package/dist/node_modules/@ionic/core/dist/collection/components/footer/footer.ios.css +4 -0
  321. package/dist/node_modules/@ionic/core/dist/collection/components/header/header.ios.css +16 -0
  322. package/dist/node_modules/@ionic/core/dist/collection/components/input/input.ios.css +9 -0
  323. package/dist/node_modules/@ionic/core/dist/collection/components/input/input.md.css +9 -0
  324. package/dist/node_modules/@ionic/core/dist/collection/components/item/item.ios.css +105 -17
  325. package/dist/node_modules/@ionic/core/dist/collection/components/item/item.md.css +295 -22
  326. package/dist/node_modules/@ionic/core/dist/collection/components/item-options/item-options.ios.css +6 -6
  327. package/dist/node_modules/@ionic/core/dist/collection/components/item-options/item-options.md.css +6 -6
  328. package/dist/node_modules/@ionic/core/dist/collection/components/item-sliding/item-sliding.css +2 -2
  329. package/dist/node_modules/@ionic/core/dist/collection/components/label/label.ios.css +7 -3
  330. package/dist/node_modules/@ionic/core/dist/collection/components/label/label.md.css +100 -18
  331. package/dist/node_modules/@ionic/core/dist/collection/components/list/list.ios.css +1 -1
  332. package/dist/node_modules/@ionic/core/dist/collection/components/menu/menu.ios.css +2 -2
  333. package/dist/node_modules/@ionic/core/dist/collection/components/menu/menu.md.css +2 -2
  334. package/dist/node_modules/@ionic/core/dist/collection/components/modal/modal.ios.css +74 -11
  335. package/dist/node_modules/@ionic/core/dist/collection/components/modal/modal.md.css +48 -4
  336. package/dist/node_modules/@ionic/core/dist/collection/components/picker-column-internal/picker-column-internal.ios.css +59 -0
  337. package/dist/node_modules/@ionic/core/dist/collection/components/picker-column-internal/picker-column-internal.md.css +62 -0
  338. package/dist/node_modules/@ionic/core/dist/collection/components/picker-internal/picker-internal.ios.css +122 -0
  339. package/dist/node_modules/@ionic/core/dist/collection/components/picker-internal/picker-internal.md.css +118 -0
  340. package/dist/node_modules/@ionic/core/dist/collection/components/popover/popover.ios.css +83 -0
  341. package/dist/node_modules/@ionic/core/dist/collection/components/popover/popover.md.css +49 -0
  342. package/dist/node_modules/@ionic/core/dist/collection/components/progress-bar/progress-bar.ios.css +53 -38
  343. package/dist/node_modules/@ionic/core/dist/collection/components/progress-bar/progress-bar.md.css +53 -38
  344. package/dist/node_modules/@ionic/core/dist/collection/components/range/range.ios.css +3 -3
  345. package/dist/node_modules/@ionic/core/dist/collection/components/range/range.md.css +5 -5
  346. package/dist/node_modules/@ionic/core/dist/collection/components/refresher/refresher.ios.css +12 -0
  347. package/dist/node_modules/@ionic/core/dist/collection/components/refresher/refresher.md.css +2 -2
  348. package/dist/node_modules/@ionic/core/dist/collection/components/searchbar/searchbar.ios.css +1 -1
  349. package/dist/node_modules/@ionic/core/dist/collection/components/searchbar/searchbar.md.css +1 -1
  350. package/dist/node_modules/@ionic/core/dist/collection/components/segment-button/segment-button.ios.css +4 -0
  351. package/dist/node_modules/@ionic/core/dist/collection/components/segment-button/segment-button.md.css +4 -0
  352. package/dist/node_modules/@ionic/core/dist/collection/components/select/select.ios.css +1 -1
  353. package/dist/node_modules/@ionic/core/dist/collection/components/select/select.md.css +30 -2
  354. package/dist/node_modules/@ionic/core/dist/collection/components/select-popover/{select-popover.css → select-popover.ios.css} +4 -4
  355. package/dist/node_modules/@ionic/core/dist/collection/components/select-popover/select-popover.md.css +37 -0
  356. package/dist/node_modules/@ionic/core/dist/collection/components/skeleton-text/skeleton-text.css +4 -4
  357. package/dist/node_modules/@ionic/core/dist/collection/components/spinner/spinner.css +15 -2
  358. package/dist/node_modules/@ionic/core/dist/collection/components/tab-bar/tab-bar.ios.css +2 -1
  359. package/dist/node_modules/@ionic/core/dist/collection/components/tab-bar/tab-bar.md.css +1 -0
  360. package/dist/node_modules/@ionic/core/dist/collection/components/textarea/textarea.ios.css +9 -0
  361. package/dist/node_modules/@ionic/core/dist/collection/components/textarea/textarea.md.css +9 -0
  362. package/dist/node_modules/@ionic/core/dist/collection/components/title/title.ios.css +4 -3
  363. package/dist/node_modules/@ionic/core/dist/collection/components/toast/toast.ios.css +14 -2
  364. package/dist/node_modules/@ionic/core/dist/collection/components/toast/toast.md.css +14 -2
  365. package/dist/node_modules/@ionic/core/dist/collection/components/toggle/toggle.ios.css +1 -0
  366. package/dist/node_modules/@ionic/core/dist/collection/components/toggle/toggle.md.css +1 -0
  367. package/dist/node_modules/@ionic/core/dist/collection/components/toolbar/toolbar.ios.css +3 -2
  368. package/dist/node_modules/@ionic/core/dist/collection/components/toolbar/toolbar.md.css +2 -1
  369. package/dist/node_modules/@ionic/core/dist/collection/components/virtual-scroll/virtual-scroll.css +1 -1
  370. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/button/button.css +49 -0
  371. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/cards/card/card.css +208 -0
  372. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/cards/cards.css +31 -0
  373. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/code/code.css +245 -0
  374. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/dropdown/dropdown.css +115 -0
  375. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/header/header-mobile-collapse/header-mobile-collapse.css +255 -0
  376. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/header/header.css +232 -0
  377. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/menu/collapsible/collapsible.css +3 -0
  378. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/menu/menu-toggle/menu-toggle.css +25 -0
  379. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/menu/menu.css +71 -0
  380. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/nav/nav.css +194 -0
  381. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/notfound-page/notfound-page.css +4 -0
  382. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/overlay/overlay.css +67 -0
  383. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/page-footer/page-footer.css +18 -0
  384. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/pagination/pagination.css +89 -0
  385. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/select/select.css +52 -0
  386. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/sidebar/sidebar.css +98 -0
  387. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/sparkle-lower-content-nav/sparkle-lower-content-nav.css +8 -0
  388. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/table-of-contents/table-of-contents.css +37 -0
  389. package/dist/node_modules/@sparkle-learning/components/dist/collection/components/tabs/tabs.css +64 -0
  390. package/dist/sparkle-core/assets/characters/character-img.jpg +0 -0
  391. package/dist/sparkle-core/assets/characters/jen.png +0 -0
  392. package/dist/sparkle-core/assets/characters/kimberly.png +0 -0
  393. package/dist/sparkle-core/assets/characters/valeria.png +0 -0
  394. package/dist/sparkle-core/assets/characters/yuna.png +0 -0
  395. package/dist/sparkle-core/assets/characters/zynab.png +0 -0
  396. package/dist/sparkle-core/index.esm.js +1 -1
  397. package/dist/sparkle-core/p-0146afa0.entry.js +1 -0
  398. package/dist/sparkle-core/{p-52355989.entry.js → p-016a7aaf.entry.js} +1 -1
  399. package/dist/sparkle-core/p-0187adef.entry.js +1 -0
  400. package/dist/sparkle-core/p-03189863.js +1 -0
  401. package/dist/sparkle-core/{p-d4d9aa4a.entry.js → p-03ec54a8.entry.js} +1 -1
  402. package/dist/sparkle-core/p-04583c51.entry.js +1 -0
  403. package/dist/sparkle-core/{p-6d506f4e.js → p-052caa63.js} +1 -1
  404. package/dist/sparkle-core/{p-016bf847.entry.js → p-057f6a23.entry.js} +1 -1
  405. package/dist/sparkle-core/p-0580419b.entry.js +1 -0
  406. package/dist/sparkle-core/{p-c563b4de.js → p-063cd168.js} +4 -1
  407. package/dist/sparkle-core/p-081968cc.entry.js +1 -0
  408. package/dist/sparkle-core/p-0934f5dd.entry.js +1 -0
  409. package/dist/sparkle-core/{p-3f5d7a08.entry.js → p-11cf398a.entry.js} +1 -1
  410. package/dist/sparkle-core/p-1339830f.entry.js +1 -0
  411. package/dist/sparkle-core/p-145e40f5.entry.js +1 -0
  412. package/dist/sparkle-core/{p-68f3c93d.entry.js → p-1726da2f.entry.js} +1 -1
  413. package/dist/sparkle-core/p-173d5461.entry.js +7 -0
  414. package/dist/sparkle-core/p-18e62133.entry.js +1 -0
  415. package/dist/sparkle-core/p-1af044f7.js +3 -0
  416. package/dist/sparkle-core/p-1b78dea1.entry.js +1 -0
  417. package/dist/sparkle-core/p-1cef8572.js +4 -0
  418. package/dist/sparkle-core/p-1df05176.js +4 -0
  419. package/dist/sparkle-core/p-21bf4ca0.entry.js +1 -0
  420. package/dist/sparkle-core/p-21db4e8e.entry.js +1 -0
  421. package/dist/sparkle-core/p-23a9f7d1.entry.js +1 -0
  422. package/dist/sparkle-core/p-289a35ed.entry.js +1 -0
  423. package/dist/sparkle-core/p-2ee6a5f9.entry.js +1 -0
  424. package/dist/sparkle-core/p-350adbaa.entry.js +1 -0
  425. package/dist/sparkle-core/{p-bccd9036.entry.js → p-35a7bd6c.entry.js} +1 -1
  426. package/dist/sparkle-core/{p-66e3bd1c.entry.js → p-37c00e39.entry.js} +1 -1
  427. package/dist/sparkle-core/p-389500fd.js +4 -0
  428. package/dist/sparkle-core/p-39e5a90f.entry.js +1 -0
  429. package/dist/sparkle-core/{p-ac5e5308.entry.js → p-3a202a38.entry.js} +1 -1
  430. package/dist/sparkle-core/p-3defe550.entry.js +1 -0
  431. package/dist/sparkle-core/p-45e6db62.entry.js +1 -0
  432. package/dist/sparkle-core/{p-581ca370.entry.js → p-48f9b960.entry.js} +1 -1
  433. package/dist/sparkle-core/{p-0efbc0b3.entry.js → p-4dc3ef96.entry.js} +1 -1
  434. package/dist/sparkle-core/p-506221fe.js +4 -0
  435. package/dist/sparkle-core/p-50aac721.entry.js +7 -0
  436. package/dist/sparkle-core/p-513794b0.js +16 -0
  437. package/dist/sparkle-core/{p-2e4e8117.js → p-5264da79.js} +3 -0
  438. package/dist/sparkle-core/{p-40db85ac.entry.js → p-547b70c6.entry.js} +1 -1
  439. package/dist/sparkle-core/p-5598650a.entry.js +1 -0
  440. package/dist/sparkle-core/p-55ae49e1.js +4 -0
  441. package/dist/sparkle-core/p-58e98f89.entry.js +1 -0
  442. package/dist/sparkle-core/p-59f7bf6e.entry.js +1 -0
  443. package/dist/sparkle-core/p-5a3d0e6b.js +4 -0
  444. package/dist/sparkle-core/{p-85d31769.entry.js → p-5b40aae5.entry.js} +1 -1
  445. package/dist/sparkle-core/p-5c9aa1f9.entry.js +4 -0
  446. package/dist/sparkle-core/p-5d2e54ee.entry.js +1 -0
  447. package/dist/sparkle-core/p-5d409601.js +1 -0
  448. package/dist/sparkle-core/{p-afbaad64.entry.js → p-5f45d206.entry.js} +1 -1
  449. package/dist/sparkle-core/p-5ff6416d.entry.js +7 -0
  450. package/dist/sparkle-core/{p-cf2332bb.entry.js → p-62a6c96f.entry.js} +1 -1
  451. package/dist/sparkle-core/p-64e72f8f.js +4 -0
  452. package/dist/sparkle-core/p-660e0742.js +1 -0
  453. package/dist/sparkle-core/{p-d5023db0.entry.js → p-667accac.entry.js} +1 -1
  454. package/dist/sparkle-core/{p-9ca56f5d.entry.js → p-680663a2.entry.js} +1 -1
  455. package/dist/sparkle-core/{p-e975924a.entry.js → p-6823e6c1.entry.js} +1 -1
  456. package/dist/sparkle-core/p-69e7783d.js +4 -0
  457. package/dist/sparkle-core/p-6bbabb80.entry.js +1 -0
  458. package/dist/sparkle-core/p-6bf07a28.js +1 -0
  459. package/dist/sparkle-core/p-6c6145cd.js +4 -0
  460. package/dist/sparkle-core/p-6c90bde6.entry.js +5 -0
  461. package/dist/sparkle-core/p-6e88764b.entry.js +4 -0
  462. package/dist/sparkle-core/p-6ee40949.js +1 -0
  463. package/dist/sparkle-core/p-6fbe3ca3.entry.js +1 -0
  464. package/dist/sparkle-core/{p-f2660943.js → p-6fd4985d.js} +3 -0
  465. package/dist/sparkle-core/{p-8fc9298a.js → p-703ca87c.js} +3 -0
  466. package/dist/sparkle-core/{p-1bf8bed6.entry.js → p-7052c43a.entry.js} +1 -1
  467. package/dist/sparkle-core/{p-111520a0.js → p-70b2452c.js} +3 -0
  468. package/dist/sparkle-core/p-713590fc.js +5 -0
  469. package/dist/sparkle-core/p-7493ee15.entry.js +1 -0
  470. package/dist/sparkle-core/p-75572037.js +1 -0
  471. package/dist/sparkle-core/{p-eb56aa20.entry.js → p-768bcc9e.entry.js} +1 -1
  472. package/dist/sparkle-core/p-797c23ed.entry.js +1 -0
  473. package/dist/sparkle-core/{p-03eb2164.js → p-7c38a70b.js} +1 -1
  474. package/dist/sparkle-core/{p-09d43bee.entry.js → p-7d61177b.entry.js} +1 -1
  475. package/dist/sparkle-core/p-7dbfc316.js +1 -0
  476. package/dist/sparkle-core/p-7e61973d.entry.js +7 -0
  477. package/dist/sparkle-core/{p-3cd28c60.entry.js → p-82e98d07.entry.js} +1 -1
  478. package/dist/sparkle-core/p-838fa86d.entry.js +18 -0
  479. package/dist/sparkle-core/p-855ca600.js +1 -0
  480. package/dist/sparkle-core/p-857f3696.entry.js +1 -0
  481. package/dist/sparkle-core/{p-8f72be08.js → p-8c6b6038.js} +3 -0
  482. package/dist/sparkle-core/p-8fe2e51f.entry.js +4 -0
  483. package/dist/sparkle-core/{p-f72a6e6d.entry.js → p-90389886.entry.js} +1 -1
  484. package/dist/sparkle-core/p-932bfb69.entry.js +1 -0
  485. package/dist/sparkle-core/p-935e7cfc.js +1 -0
  486. package/dist/sparkle-core/{p-c70b9765.entry.js → p-941eaa3a.entry.js} +1 -1
  487. package/dist/sparkle-core/p-95004267.entry.js +1 -0
  488. package/dist/sparkle-core/p-950effe7.entry.js +1 -0
  489. package/dist/sparkle-core/{p-1ca4bf1d.entry.js → p-996361f9.entry.js} +1 -1
  490. package/dist/sparkle-core/p-9a17f2ad.js +4 -0
  491. package/dist/sparkle-core/p-9a443f51.js +1 -1
  492. package/dist/sparkle-core/p-9babd345.js +1 -0
  493. package/dist/sparkle-core/p-9cfdeb18.entry.js +1 -0
  494. package/dist/sparkle-core/p-a080e768.entry.js +1 -0
  495. package/dist/sparkle-core/p-a1cab0f3.js +4 -0
  496. package/dist/sparkle-core/p-a7cc0052.entry.js +4 -0
  497. package/dist/sparkle-core/p-a9ccb0df.js +4 -0
  498. package/dist/sparkle-core/p-a9ee3f6d.entry.js +1 -0
  499. package/dist/sparkle-core/{p-abe2676a.entry.js → p-aa87c7f0.entry.js} +1 -1
  500. package/dist/sparkle-core/{p-e818b11d.entry.js → p-aa9ebc39.entry.js} +1 -1
  501. package/dist/sparkle-core/p-ae1f145d.entry.js +1 -0
  502. package/dist/sparkle-core/{p-73a646fb.entry.js → p-b07a2cf2.entry.js} +1 -1
  503. package/dist/sparkle-core/{p-c82b05e0.entry.js → p-b3909012.entry.js} +1 -1
  504. package/dist/sparkle-core/p-b3e6427d.js +7 -0
  505. package/dist/sparkle-core/p-b49ca0ea.entry.js +1 -0
  506. package/dist/sparkle-core/p-b81e20fe.entry.js +4 -0
  507. package/dist/sparkle-core/p-bca0e465.entry.js +1 -0
  508. package/dist/sparkle-core/p-c1279cc9.entry.js +1 -0
  509. package/dist/sparkle-core/{p-82d95fcd.entry.js → p-c1376096.entry.js} +1 -1
  510. package/dist/sparkle-core/p-c3986a52.entry.js +1 -0
  511. package/dist/sparkle-core/p-c3d3d5c4.entry.js +1 -0
  512. package/dist/sparkle-core/p-c48bbc7c.entry.js +4 -0
  513. package/dist/sparkle-core/p-c5b9bdd6.entry.js +1 -0
  514. package/dist/sparkle-core/{p-15d68269.entry.js → p-c69b0a7a.entry.js} +1 -1
  515. package/dist/sparkle-core/p-cbbeed67.entry.js +1 -0
  516. package/dist/sparkle-core/p-d4a435f8.entry.js +1 -0
  517. package/dist/sparkle-core/p-d4c07aca.js +4 -0
  518. package/dist/sparkle-core/p-d5b05ece.entry.js +5 -0
  519. package/dist/sparkle-core/p-d7baf31e.entry.js +1 -0
  520. package/dist/sparkle-core/p-d8d3524a.js +1 -0
  521. package/dist/sparkle-core/p-df0070c5.entry.js +352 -0
  522. package/dist/sparkle-core/{p-22926eed.entry.js → p-e0fced48.entry.js} +1 -1
  523. package/dist/sparkle-core/p-e1cba44b.entry.js +4 -0
  524. package/dist/sparkle-core/p-e225581a.js +7 -0
  525. package/dist/sparkle-core/{p-4e28ca37.entry.js → p-e3fdd0a8.entry.js} +1 -1
  526. package/dist/sparkle-core/p-e72d4450.js +4 -0
  527. package/dist/sparkle-core/p-eb70a23c.entry.js +1 -0
  528. package/dist/sparkle-core/{p-f9143c5d.entry.js → p-ecd39170.entry.js} +1 -1
  529. package/dist/sparkle-core/{p-151afa9e.entry.js → p-ed0e9d29.entry.js} +1 -1
  530. package/dist/sparkle-core/{p-92d42c10.entry.js → p-ee0d7f19.entry.js} +1 -1
  531. package/dist/sparkle-core/p-f4001fdf.js +4 -0
  532. package/dist/sparkle-core/p-f9b73032.entry.js +1 -0
  533. package/dist/sparkle-core/p-faa912d7.entry.js +1 -0
  534. package/dist/sparkle-core/{p-a250e2ae.entry.js → p-fbd7eeca.entry.js} +1 -1
  535. package/dist/sparkle-core/p-fc933591.entry.js +1 -0
  536. package/dist/sparkle-core/p-fef04ab5.js +4 -0
  537. package/dist/sparkle-core/sparkle-core.css +1 -1
  538. package/dist/sparkle-core/sparkle-core.esm.js +1 -1
  539. package/dist/sparkle-core/svg/balloon-outline.svg +1 -0
  540. package/dist/sparkle-core/svg/balloon-sharp.svg +1 -0
  541. package/dist/sparkle-core/svg/balloon.svg +1 -0
  542. package/dist/sparkle-core/svg/bowling-ball-outline.svg +1 -0
  543. package/dist/sparkle-core/svg/bowling-ball-sharp.svg +1 -0
  544. package/dist/sparkle-core/svg/bowling-ball.svg +1 -0
  545. package/dist/sparkle-core/svg/calendar-number-outline.svg +1 -0
  546. package/dist/sparkle-core/svg/calendar-number-sharp.svg +1 -0
  547. package/dist/sparkle-core/svg/calendar-number.svg +1 -0
  548. package/dist/sparkle-core/svg/diamond-outline.svg +1 -0
  549. package/dist/sparkle-core/svg/diamond-sharp.svg +1 -0
  550. package/dist/sparkle-core/svg/diamond.svg +1 -0
  551. package/dist/sparkle-core/svg/footsteps-outline.svg +1 -0
  552. package/dist/sparkle-core/svg/footsteps-sharp.svg +1 -0
  553. package/dist/sparkle-core/svg/footsteps.svg +1 -0
  554. package/dist/sparkle-core/svg/id-card-outline.svg +1 -0
  555. package/dist/sparkle-core/svg/id-card-sharp.svg +1 -0
  556. package/dist/sparkle-core/svg/id-card.svg +1 -0
  557. package/dist/sparkle-core/svg/logo-apple-ar.svg +1 -0
  558. package/dist/sparkle-core/svg/prism-outline.svg +1 -0
  559. package/dist/sparkle-core/svg/prism-sharp.svg +1 -0
  560. package/dist/sparkle-core/svg/prism.svg +1 -0
  561. package/dist/sparkle-core/svg/scale-outline.svg +1 -0
  562. package/dist/sparkle-core/svg/scale-sharp.svg +1 -0
  563. package/dist/sparkle-core/svg/scale.svg +1 -0
  564. package/dist/sparkle-core/svg/shield-half-outline.svg +1 -0
  565. package/dist/sparkle-core/svg/shield-half-sharp.svg +1 -0
  566. package/dist/sparkle-core/svg/shield-half.svg +1 -0
  567. package/dist/sparkle-core/svg/sparkles-outline.svg +1 -0
  568. package/dist/sparkle-core/svg/sparkles-sharp.svg +1 -0
  569. package/dist/sparkle-core/svg/sparkles.svg +1 -0
  570. package/dist/sparkle-core/swiper/swiper.bundle.js +2 -2
  571. package/dist/types/components/sparkle-animation-player/sparkle-animation-player.d.ts +1 -0
  572. package/dist/types/components/sparkle-character-intro/sparkle-character-intro.d.ts +7 -0
  573. package/dist/types/components/sparkle-course-root/sparkle-course-root.d.ts +2 -2
  574. package/dist/types/components/sparkle-youtube/sparkle-youtube.d.ts +1 -1
  575. package/dist/types/components.d.ts +17 -0
  576. package/dist/types/models/definitions.d.ts +8 -0
  577. package/dist/types/stencil-public-runtime.d.ts +200 -190
  578. package/dist/types/util.d.ts +1 -0
  579. package/package.json +26 -26
  580. package/dist/cjs/app-globals-98121d6d.js +0 -9
  581. package/dist/cjs/button-active-9456fb4d.js +0 -66
  582. package/dist/cjs/feed.service-518d18fd.js +0 -5802
  583. package/dist/cjs/focus-visible-1583bc8e.js +0 -45
  584. package/dist/cjs/framework-delegate-72815681.js +0 -37
  585. package/dist/cjs/header-mobile-collapse_60.cjs.entry.js +0 -86
  586. package/dist/cjs/index.es-baef3314.js +0 -13834
  587. package/dist/cjs/ion-action-sheet.cjs.entry.js +0 -261
  588. package/dist/cjs/ion-alert.cjs.entry.js +0 -455
  589. package/dist/cjs/ion-note.cjs.entry.js +0 -29
  590. package/dist/cjs/ion-popover.cjs.entry.js +0 -365
  591. package/dist/cjs/ion-select-popover.cjs.entry.js +0 -35
  592. package/dist/cjs/status-tap-466a7c6a.js +0 -25
  593. package/dist/esm/app-globals-6451faf3.js +0 -7
  594. package/dist/esm/auth.store-dd944bc2.js +0 -2552
  595. package/dist/esm/button-active-97535443.js +0 -64
  596. package/dist/esm/feed.service-0fda1e36.js +0 -5787
  597. package/dist/esm/focus-visible-abf04ce3.js +0 -43
  598. package/dist/esm/framework-delegate-2c397da3.js +0 -34
  599. package/dist/esm/header-mobile-collapse_60.entry.js +0 -19
  600. package/dist/esm/index.es-a5bf9a49.js +0 -13748
  601. package/dist/esm/ion-action-sheet.entry.js +0 -257
  602. package/dist/esm/ion-alert.entry.js +0 -451
  603. package/dist/esm/ion-note.entry.js +0 -25
  604. package/dist/esm/ion-popover.entry.js +0 -361
  605. package/dist/esm/ion-select-popover.entry.js +0 -31
  606. package/dist/esm/status-tap-9221cd79.js +0 -23
  607. package/dist/sparkle-core/p-019d9d02.entry.js +0 -1
  608. package/dist/sparkle-core/p-02d6d899.js +0 -1
  609. package/dist/sparkle-core/p-03fd27d0.entry.js +0 -1
  610. package/dist/sparkle-core/p-07018d29.js +0 -1
  611. package/dist/sparkle-core/p-083d57a6.entry.js +0 -1
  612. package/dist/sparkle-core/p-090f2624.js +0 -1
  613. package/dist/sparkle-core/p-0e1c7c8c.js +0 -1
  614. package/dist/sparkle-core/p-101feae9.js +0 -1
  615. package/dist/sparkle-core/p-13b0cdfc.entry.js +0 -1
  616. package/dist/sparkle-core/p-13c9bf3a.entry.js +0 -1
  617. package/dist/sparkle-core/p-169920f1.js +0 -1
  618. package/dist/sparkle-core/p-1e1f5e98.entry.js +0 -1
  619. package/dist/sparkle-core/p-1e866c41.entry.js +0 -1
  620. package/dist/sparkle-core/p-2474bf60.entry.js +0 -1
  621. package/dist/sparkle-core/p-25bbf9b4.entry.js +0 -1
  622. package/dist/sparkle-core/p-2a45b732.js +0 -1
  623. package/dist/sparkle-core/p-2abf4d37.entry.js +0 -1
  624. package/dist/sparkle-core/p-2c5edb9f.entry.js +0 -1
  625. package/dist/sparkle-core/p-2d966d35.js +0 -1
  626. package/dist/sparkle-core/p-30b641a4.entry.js +0 -1
  627. package/dist/sparkle-core/p-34ea6639.entry.js +0 -1
  628. package/dist/sparkle-core/p-359422b6.entry.js +0 -1
  629. package/dist/sparkle-core/p-37bfb548.entry.js +0 -1
  630. package/dist/sparkle-core/p-38307b31.js +0 -1
  631. package/dist/sparkle-core/p-3a29a75b.entry.js +0 -1
  632. package/dist/sparkle-core/p-3bb55510.entry.js +0 -1
  633. package/dist/sparkle-core/p-3be0a218.js +0 -1
  634. package/dist/sparkle-core/p-417a8dd6.js +0 -1
  635. package/dist/sparkle-core/p-447163be.entry.js +0 -1
  636. package/dist/sparkle-core/p-49265a8e.entry.js +0 -1
  637. package/dist/sparkle-core/p-4950f841.entry.js +0 -1
  638. package/dist/sparkle-core/p-4b7db0e6.js +0 -1
  639. package/dist/sparkle-core/p-4d8cb365.entry.js +0 -1
  640. package/dist/sparkle-core/p-5073899e.entry.js +0 -1
  641. package/dist/sparkle-core/p-5b366c20.entry.js +0 -1
  642. package/dist/sparkle-core/p-5dce20b9.entry.js +0 -1
  643. package/dist/sparkle-core/p-6006beec.entry.js +0 -1
  644. package/dist/sparkle-core/p-600d04fc.entry.js +0 -1
  645. package/dist/sparkle-core/p-60828739.entry.js +0 -1
  646. package/dist/sparkle-core/p-6112b180.entry.js +0 -1
  647. package/dist/sparkle-core/p-66eb6b7a.entry.js +0 -1
  648. package/dist/sparkle-core/p-67ddec3f.entry.js +0 -1
  649. package/dist/sparkle-core/p-68cb7d41.entry.js +0 -1
  650. package/dist/sparkle-core/p-69cd49de.js +0 -1
  651. package/dist/sparkle-core/p-6edbdde5.entry.js +0 -1
  652. package/dist/sparkle-core/p-6f0ecbe3.js +0 -1
  653. package/dist/sparkle-core/p-765b8593.js +0 -1
  654. package/dist/sparkle-core/p-770128c8.js +0 -1
  655. package/dist/sparkle-core/p-7840618d.js +0 -1
  656. package/dist/sparkle-core/p-7b37d523.entry.js +0 -1
  657. package/dist/sparkle-core/p-7d83d006.entry.js +0 -1
  658. package/dist/sparkle-core/p-7f3d5344.js +0 -1
  659. package/dist/sparkle-core/p-81651f26.entry.js +0 -1
  660. package/dist/sparkle-core/p-86148067.entry.js +0 -1
  661. package/dist/sparkle-core/p-8b5bc1d6.entry.js +0 -1
  662. package/dist/sparkle-core/p-8c3ee44c.entry.js +0 -1
  663. package/dist/sparkle-core/p-9007a06b.entry.js +0 -1
  664. package/dist/sparkle-core/p-90482861.entry.js +0 -1
  665. package/dist/sparkle-core/p-a061537e.entry.js +0 -1
  666. package/dist/sparkle-core/p-a38ea475.js +0 -1
  667. package/dist/sparkle-core/p-ad1ddf1f.js +0 -483
  668. package/dist/sparkle-core/p-aef0bba0.js +0 -1
  669. package/dist/sparkle-core/p-b080c1e3.entry.js +0 -1
  670. package/dist/sparkle-core/p-b11fe0c7.js +0 -1
  671. package/dist/sparkle-core/p-bac45a26.entry.js +0 -1
  672. package/dist/sparkle-core/p-bbe5977b.entry.js +0 -1
  673. package/dist/sparkle-core/p-bc568dcb.js +0 -1
  674. package/dist/sparkle-core/p-bfb55f1d.js +0 -3
  675. package/dist/sparkle-core/p-c163c16d.entry.js +0 -1
  676. package/dist/sparkle-core/p-c3166584.entry.js +0 -1
  677. package/dist/sparkle-core/p-c34269ae.entry.js +0 -1
  678. package/dist/sparkle-core/p-c466ee32.js +0 -1
  679. package/dist/sparkle-core/p-c6710592.entry.js +0 -1
  680. package/dist/sparkle-core/p-c7022391.entry.js +0 -1
  681. package/dist/sparkle-core/p-d4ad796c.js +0 -1
  682. package/dist/sparkle-core/p-d6152660.entry.js +0 -1
  683. package/dist/sparkle-core/p-d63406d8.js +0 -1
  684. package/dist/sparkle-core/p-dba672d5.entry.js +0 -1
  685. package/dist/sparkle-core/p-dd73d01a.entry.js +0 -1
  686. package/dist/sparkle-core/p-de33872d.entry.js +0 -1
  687. package/dist/sparkle-core/p-dee2128a.entry.js +0 -1
  688. package/dist/sparkle-core/p-df07e132.entry.js +0 -1
  689. package/dist/sparkle-core/p-e5d5aaa5.js +0 -1
  690. package/dist/sparkle-core/p-e72c6d87.entry.js +0 -1
  691. package/dist/sparkle-core/p-e8df6ea6.entry.js +0 -1
  692. package/dist/sparkle-core/p-ef2a2172.js +0 -1
  693. package/dist/sparkle-core/p-f1a4ab33.entry.js +0 -1
  694. package/dist/sparkle-core/p-f43ac631.entry.js +0 -1
  695. package/dist/sparkle-core/p-f8063d7b.js +0 -1
  696. package/dist/sparkle-core/p-fd62283e.entry.js +0 -1
  697. package/dist/sparkle-core/p-fef71e0e.entry.js +0 -1
@@ -1,2552 +0,0 @@
1
- import { c as getRenderingRef, f as forceUpdate } from './index-55fc9f5e.js';
2
- import { E as EnvironmentConfigService } from './environment-config.service-2b5d692b.js';
3
- import { t as toastController } from './overlays-8363621c.js';
4
-
5
- var bind = function bind(fn, thisArg) {
6
- return function wrap() {
7
- var args = new Array(arguments.length);
8
- for (var i = 0; i < args.length; i++) {
9
- args[i] = arguments[i];
10
- }
11
- return fn.apply(thisArg, args);
12
- };
13
- };
14
-
15
- /*global toString:true*/
16
-
17
- // utils is a library of generic helper functions non-specific to axios
18
-
19
- var toString = Object.prototype.toString;
20
-
21
- /**
22
- * Determine if a value is an Array
23
- *
24
- * @param {Object} val The value to test
25
- * @returns {boolean} True if value is an Array, otherwise false
26
- */
27
- function isArray(val) {
28
- return toString.call(val) === '[object Array]';
29
- }
30
-
31
- /**
32
- * Determine if a value is undefined
33
- *
34
- * @param {Object} val The value to test
35
- * @returns {boolean} True if the value is undefined, otherwise false
36
- */
37
- function isUndefined(val) {
38
- return typeof val === 'undefined';
39
- }
40
-
41
- /**
42
- * Determine if a value is a Buffer
43
- *
44
- * @param {Object} val The value to test
45
- * @returns {boolean} True if value is a Buffer, otherwise false
46
- */
47
- function isBuffer(val) {
48
- return val !== null && !isUndefined(val) && val.constructor !== null && !isUndefined(val.constructor)
49
- && typeof val.constructor.isBuffer === 'function' && val.constructor.isBuffer(val);
50
- }
51
-
52
- /**
53
- * Determine if a value is an ArrayBuffer
54
- *
55
- * @param {Object} val The value to test
56
- * @returns {boolean} True if value is an ArrayBuffer, otherwise false
57
- */
58
- function isArrayBuffer(val) {
59
- return toString.call(val) === '[object ArrayBuffer]';
60
- }
61
-
62
- /**
63
- * Determine if a value is a FormData
64
- *
65
- * @param {Object} val The value to test
66
- * @returns {boolean} True if value is an FormData, otherwise false
67
- */
68
- function isFormData(val) {
69
- return (typeof FormData !== 'undefined') && (val instanceof FormData);
70
- }
71
-
72
- /**
73
- * Determine if a value is a view on an ArrayBuffer
74
- *
75
- * @param {Object} val The value to test
76
- * @returns {boolean} True if value is a view on an ArrayBuffer, otherwise false
77
- */
78
- function isArrayBufferView(val) {
79
- var result;
80
- if ((typeof ArrayBuffer !== 'undefined') && (ArrayBuffer.isView)) {
81
- result = ArrayBuffer.isView(val);
82
- } else {
83
- result = (val) && (val.buffer) && (val.buffer instanceof ArrayBuffer);
84
- }
85
- return result;
86
- }
87
-
88
- /**
89
- * Determine if a value is a String
90
- *
91
- * @param {Object} val The value to test
92
- * @returns {boolean} True if value is a String, otherwise false
93
- */
94
- function isString(val) {
95
- return typeof val === 'string';
96
- }
97
-
98
- /**
99
- * Determine if a value is a Number
100
- *
101
- * @param {Object} val The value to test
102
- * @returns {boolean} True if value is a Number, otherwise false
103
- */
104
- function isNumber(val) {
105
- return typeof val === 'number';
106
- }
107
-
108
- /**
109
- * Determine if a value is an Object
110
- *
111
- * @param {Object} val The value to test
112
- * @returns {boolean} True if value is an Object, otherwise false
113
- */
114
- function isObject(val) {
115
- return val !== null && typeof val === 'object';
116
- }
117
-
118
- /**
119
- * Determine if a value is a plain Object
120
- *
121
- * @param {Object} val The value to test
122
- * @return {boolean} True if value is a plain Object, otherwise false
123
- */
124
- function isPlainObject(val) {
125
- if (toString.call(val) !== '[object Object]') {
126
- return false;
127
- }
128
-
129
- var prototype = Object.getPrototypeOf(val);
130
- return prototype === null || prototype === Object.prototype;
131
- }
132
-
133
- /**
134
- * Determine if a value is a Date
135
- *
136
- * @param {Object} val The value to test
137
- * @returns {boolean} True if value is a Date, otherwise false
138
- */
139
- function isDate(val) {
140
- return toString.call(val) === '[object Date]';
141
- }
142
-
143
- /**
144
- * Determine if a value is a File
145
- *
146
- * @param {Object} val The value to test
147
- * @returns {boolean} True if value is a File, otherwise false
148
- */
149
- function isFile(val) {
150
- return toString.call(val) === '[object File]';
151
- }
152
-
153
- /**
154
- * Determine if a value is a Blob
155
- *
156
- * @param {Object} val The value to test
157
- * @returns {boolean} True if value is a Blob, otherwise false
158
- */
159
- function isBlob(val) {
160
- return toString.call(val) === '[object Blob]';
161
- }
162
-
163
- /**
164
- * Determine if a value is a Function
165
- *
166
- * @param {Object} val The value to test
167
- * @returns {boolean} True if value is a Function, otherwise false
168
- */
169
- function isFunction(val) {
170
- return toString.call(val) === '[object Function]';
171
- }
172
-
173
- /**
174
- * Determine if a value is a Stream
175
- *
176
- * @param {Object} val The value to test
177
- * @returns {boolean} True if value is a Stream, otherwise false
178
- */
179
- function isStream(val) {
180
- return isObject(val) && isFunction(val.pipe);
181
- }
182
-
183
- /**
184
- * Determine if a value is a URLSearchParams object
185
- *
186
- * @param {Object} val The value to test
187
- * @returns {boolean} True if value is a URLSearchParams object, otherwise false
188
- */
189
- function isURLSearchParams(val) {
190
- return typeof URLSearchParams !== 'undefined' && val instanceof URLSearchParams;
191
- }
192
-
193
- /**
194
- * Trim excess whitespace off the beginning and end of a string
195
- *
196
- * @param {String} str The String to trim
197
- * @returns {String} The String freed of excess whitespace
198
- */
199
- function trim(str) {
200
- return str.replace(/^\s*/, '').replace(/\s*$/, '');
201
- }
202
-
203
- /**
204
- * Determine if we're running in a standard browser environment
205
- *
206
- * This allows axios to run in a web worker, and react-native.
207
- * Both environments support XMLHttpRequest, but not fully standard globals.
208
- *
209
- * web workers:
210
- * typeof window -> undefined
211
- * typeof document -> undefined
212
- *
213
- * react-native:
214
- * navigator.product -> 'ReactNative'
215
- * nativescript
216
- * navigator.product -> 'NativeScript' or 'NS'
217
- */
218
- function isStandardBrowserEnv() {
219
- if (typeof navigator !== 'undefined' && (navigator.product === 'ReactNative' ||
220
- navigator.product === 'NativeScript' ||
221
- navigator.product === 'NS')) {
222
- return false;
223
- }
224
- return (
225
- typeof window !== 'undefined' &&
226
- typeof document !== 'undefined'
227
- );
228
- }
229
-
230
- /**
231
- * Iterate over an Array or an Object invoking a function for each item.
232
- *
233
- * If `obj` is an Array callback will be called passing
234
- * the value, index, and complete array for each item.
235
- *
236
- * If 'obj' is an Object callback will be called passing
237
- * the value, key, and complete object for each property.
238
- *
239
- * @param {Object|Array} obj The object to iterate
240
- * @param {Function} fn The callback to invoke for each item
241
- */
242
- function forEach(obj, fn) {
243
- // Don't bother if no value provided
244
- if (obj === null || typeof obj === 'undefined') {
245
- return;
246
- }
247
-
248
- // Force an array if not already something iterable
249
- if (typeof obj !== 'object') {
250
- /*eslint no-param-reassign:0*/
251
- obj = [obj];
252
- }
253
-
254
- if (isArray(obj)) {
255
- // Iterate over array values
256
- for (var i = 0, l = obj.length; i < l; i++) {
257
- fn.call(null, obj[i], i, obj);
258
- }
259
- } else {
260
- // Iterate over object keys
261
- for (var key in obj) {
262
- if (Object.prototype.hasOwnProperty.call(obj, key)) {
263
- fn.call(null, obj[key], key, obj);
264
- }
265
- }
266
- }
267
- }
268
-
269
- /**
270
- * Accepts varargs expecting each argument to be an object, then
271
- * immutably merges the properties of each object and returns result.
272
- *
273
- * When multiple objects contain the same key the later object in
274
- * the arguments list will take precedence.
275
- *
276
- * Example:
277
- *
278
- * ```js
279
- * var result = merge({foo: 123}, {foo: 456});
280
- * console.log(result.foo); // outputs 456
281
- * ```
282
- *
283
- * @param {Object} obj1 Object to merge
284
- * @returns {Object} Result of all merge properties
285
- */
286
- function merge(/* obj1, obj2, obj3, ... */) {
287
- var result = {};
288
- function assignValue(val, key) {
289
- if (isPlainObject(result[key]) && isPlainObject(val)) {
290
- result[key] = merge(result[key], val);
291
- } else if (isPlainObject(val)) {
292
- result[key] = merge({}, val);
293
- } else if (isArray(val)) {
294
- result[key] = val.slice();
295
- } else {
296
- result[key] = val;
297
- }
298
- }
299
-
300
- for (var i = 0, l = arguments.length; i < l; i++) {
301
- forEach(arguments[i], assignValue);
302
- }
303
- return result;
304
- }
305
-
306
- /**
307
- * Extends object a by mutably adding to it the properties of object b.
308
- *
309
- * @param {Object} a The object to be extended
310
- * @param {Object} b The object to copy properties from
311
- * @param {Object} thisArg The object to bind function to
312
- * @return {Object} The resulting value of object a
313
- */
314
- function extend(a, b, thisArg) {
315
- forEach(b, function assignValue(val, key) {
316
- if (thisArg && typeof val === 'function') {
317
- a[key] = bind(val, thisArg);
318
- } else {
319
- a[key] = val;
320
- }
321
- });
322
- return a;
323
- }
324
-
325
- /**
326
- * Remove byte order marker. This catches EF BB BF (the UTF-8 BOM)
327
- *
328
- * @param {string} content with BOM
329
- * @return {string} content value without BOM
330
- */
331
- function stripBOM(content) {
332
- if (content.charCodeAt(0) === 0xFEFF) {
333
- content = content.slice(1);
334
- }
335
- return content;
336
- }
337
-
338
- var utils = {
339
- isArray: isArray,
340
- isArrayBuffer: isArrayBuffer,
341
- isBuffer: isBuffer,
342
- isFormData: isFormData,
343
- isArrayBufferView: isArrayBufferView,
344
- isString: isString,
345
- isNumber: isNumber,
346
- isObject: isObject,
347
- isPlainObject: isPlainObject,
348
- isUndefined: isUndefined,
349
- isDate: isDate,
350
- isFile: isFile,
351
- isBlob: isBlob,
352
- isFunction: isFunction,
353
- isStream: isStream,
354
- isURLSearchParams: isURLSearchParams,
355
- isStandardBrowserEnv: isStandardBrowserEnv,
356
- forEach: forEach,
357
- merge: merge,
358
- extend: extend,
359
- trim: trim,
360
- stripBOM: stripBOM
361
- };
362
-
363
- function encode(val) {
364
- return encodeURIComponent(val).
365
- replace(/%3A/gi, ':').
366
- replace(/%24/g, '$').
367
- replace(/%2C/gi, ',').
368
- replace(/%20/g, '+').
369
- replace(/%5B/gi, '[').
370
- replace(/%5D/gi, ']');
371
- }
372
-
373
- /**
374
- * Build a URL by appending params to the end
375
- *
376
- * @param {string} url The base of the url (e.g., http://www.google.com)
377
- * @param {object} [params] The params to be appended
378
- * @returns {string} The formatted url
379
- */
380
- var buildURL = function buildURL(url, params, paramsSerializer) {
381
- /*eslint no-param-reassign:0*/
382
- if (!params) {
383
- return url;
384
- }
385
-
386
- var serializedParams;
387
- if (paramsSerializer) {
388
- serializedParams = paramsSerializer(params);
389
- } else if (utils.isURLSearchParams(params)) {
390
- serializedParams = params.toString();
391
- } else {
392
- var parts = [];
393
-
394
- utils.forEach(params, function serialize(val, key) {
395
- if (val === null || typeof val === 'undefined') {
396
- return;
397
- }
398
-
399
- if (utils.isArray(val)) {
400
- key = key + '[]';
401
- } else {
402
- val = [val];
403
- }
404
-
405
- utils.forEach(val, function parseValue(v) {
406
- if (utils.isDate(v)) {
407
- v = v.toISOString();
408
- } else if (utils.isObject(v)) {
409
- v = JSON.stringify(v);
410
- }
411
- parts.push(encode(key) + '=' + encode(v));
412
- });
413
- });
414
-
415
- serializedParams = parts.join('&');
416
- }
417
-
418
- if (serializedParams) {
419
- var hashmarkIndex = url.indexOf('#');
420
- if (hashmarkIndex !== -1) {
421
- url = url.slice(0, hashmarkIndex);
422
- }
423
-
424
- url += (url.indexOf('?') === -1 ? '?' : '&') + serializedParams;
425
- }
426
-
427
- return url;
428
- };
429
-
430
- function InterceptorManager() {
431
- this.handlers = [];
432
- }
433
-
434
- /**
435
- * Add a new interceptor to the stack
436
- *
437
- * @param {Function} fulfilled The function to handle `then` for a `Promise`
438
- * @param {Function} rejected The function to handle `reject` for a `Promise`
439
- *
440
- * @return {Number} An ID used to remove interceptor later
441
- */
442
- InterceptorManager.prototype.use = function use(fulfilled, rejected) {
443
- this.handlers.push({
444
- fulfilled: fulfilled,
445
- rejected: rejected
446
- });
447
- return this.handlers.length - 1;
448
- };
449
-
450
- /**
451
- * Remove an interceptor from the stack
452
- *
453
- * @param {Number} id The ID that was returned by `use`
454
- */
455
- InterceptorManager.prototype.eject = function eject(id) {
456
- if (this.handlers[id]) {
457
- this.handlers[id] = null;
458
- }
459
- };
460
-
461
- /**
462
- * Iterate over all the registered interceptors
463
- *
464
- * This method is particularly useful for skipping over any
465
- * interceptors that may have become `null` calling `eject`.
466
- *
467
- * @param {Function} fn The function to call for each interceptor
468
- */
469
- InterceptorManager.prototype.forEach = function forEach(fn) {
470
- utils.forEach(this.handlers, function forEachHandler(h) {
471
- if (h !== null) {
472
- fn(h);
473
- }
474
- });
475
- };
476
-
477
- var InterceptorManager_1 = InterceptorManager;
478
-
479
- /**
480
- * Transform the data for a request or a response
481
- *
482
- * @param {Object|String} data The data to be transformed
483
- * @param {Array} headers The headers for the request or response
484
- * @param {Array|Function} fns A single function or Array of functions
485
- * @returns {*} The resulting transformed data
486
- */
487
- var transformData = function transformData(data, headers, fns) {
488
- /*eslint no-param-reassign:0*/
489
- utils.forEach(fns, function transform(fn) {
490
- data = fn(data, headers);
491
- });
492
-
493
- return data;
494
- };
495
-
496
- var isCancel = function isCancel(value) {
497
- return !!(value && value.__CANCEL__);
498
- };
499
-
500
- var normalizeHeaderName = function normalizeHeaderName(headers, normalizedName) {
501
- utils.forEach(headers, function processHeader(value, name) {
502
- if (name !== normalizedName && name.toUpperCase() === normalizedName.toUpperCase()) {
503
- headers[normalizedName] = value;
504
- delete headers[name];
505
- }
506
- });
507
- };
508
-
509
- /**
510
- * Update an Error with the specified config, error code, and response.
511
- *
512
- * @param {Error} error The error to update.
513
- * @param {Object} config The config.
514
- * @param {string} [code] The error code (for example, 'ECONNABORTED').
515
- * @param {Object} [request] The request.
516
- * @param {Object} [response] The response.
517
- * @returns {Error} The error.
518
- */
519
- var enhanceError = function enhanceError(error, config, code, request, response) {
520
- error.config = config;
521
- if (code) {
522
- error.code = code;
523
- }
524
-
525
- error.request = request;
526
- error.response = response;
527
- error.isAxiosError = true;
528
-
529
- error.toJSON = function toJSON() {
530
- return {
531
- // Standard
532
- message: this.message,
533
- name: this.name,
534
- // Microsoft
535
- description: this.description,
536
- number: this.number,
537
- // Mozilla
538
- fileName: this.fileName,
539
- lineNumber: this.lineNumber,
540
- columnNumber: this.columnNumber,
541
- stack: this.stack,
542
- // Axios
543
- config: this.config,
544
- code: this.code
545
- };
546
- };
547
- return error;
548
- };
549
-
550
- /**
551
- * Create an Error with the specified message, config, error code, request and response.
552
- *
553
- * @param {string} message The error message.
554
- * @param {Object} config The config.
555
- * @param {string} [code] The error code (for example, 'ECONNABORTED').
556
- * @param {Object} [request] The request.
557
- * @param {Object} [response] The response.
558
- * @returns {Error} The created error.
559
- */
560
- var createError = function createError(message, config, code, request, response) {
561
- var error = new Error(message);
562
- return enhanceError(error, config, code, request, response);
563
- };
564
-
565
- /**
566
- * Resolve or reject a Promise based on response status.
567
- *
568
- * @param {Function} resolve A function that resolves the promise.
569
- * @param {Function} reject A function that rejects the promise.
570
- * @param {object} response The response.
571
- */
572
- var settle = function settle(resolve, reject, response) {
573
- var validateStatus = response.config.validateStatus;
574
- if (!response.status || !validateStatus || validateStatus(response.status)) {
575
- resolve(response);
576
- } else {
577
- reject(createError(
578
- 'Request failed with status code ' + response.status,
579
- response.config,
580
- null,
581
- response.request,
582
- response
583
- ));
584
- }
585
- };
586
-
587
- var cookies = (
588
- utils.isStandardBrowserEnv() ?
589
-
590
- // Standard browser envs support document.cookie
591
- (function standardBrowserEnv() {
592
- return {
593
- write: function write(name, value, expires, path, domain, secure) {
594
- var cookie = [];
595
- cookie.push(name + '=' + encodeURIComponent(value));
596
-
597
- if (utils.isNumber(expires)) {
598
- cookie.push('expires=' + new Date(expires).toGMTString());
599
- }
600
-
601
- if (utils.isString(path)) {
602
- cookie.push('path=' + path);
603
- }
604
-
605
- if (utils.isString(domain)) {
606
- cookie.push('domain=' + domain);
607
- }
608
-
609
- if (secure === true) {
610
- cookie.push('secure');
611
- }
612
-
613
- document.cookie = cookie.join('; ');
614
- },
615
-
616
- read: function read(name) {
617
- var match = document.cookie.match(new RegExp('(^|;\\s*)(' + name + ')=([^;]*)'));
618
- return (match ? decodeURIComponent(match[3]) : null);
619
- },
620
-
621
- remove: function remove(name) {
622
- this.write(name, '', Date.now() - 86400000);
623
- }
624
- };
625
- })() :
626
-
627
- // Non standard browser env (web workers, react-native) lack needed support.
628
- (function nonStandardBrowserEnv() {
629
- return {
630
- write: function write() {},
631
- read: function read() { return null; },
632
- remove: function remove() {}
633
- };
634
- })()
635
- );
636
-
637
- /**
638
- * Determines whether the specified URL is absolute
639
- *
640
- * @param {string} url The URL to test
641
- * @returns {boolean} True if the specified URL is absolute, otherwise false
642
- */
643
- var isAbsoluteURL = function isAbsoluteURL(url) {
644
- // A URL is considered absolute if it begins with "<scheme>://" or "//" (protocol-relative URL).
645
- // RFC 3986 defines scheme name as a sequence of characters beginning with a letter and followed
646
- // by any combination of letters, digits, plus, period, or hyphen.
647
- return /^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(url);
648
- };
649
-
650
- /**
651
- * Creates a new URL by combining the specified URLs
652
- *
653
- * @param {string} baseURL The base URL
654
- * @param {string} relativeURL The relative URL
655
- * @returns {string} The combined URL
656
- */
657
- var combineURLs = function combineURLs(baseURL, relativeURL) {
658
- return relativeURL
659
- ? baseURL.replace(/\/+$/, '') + '/' + relativeURL.replace(/^\/+/, '')
660
- : baseURL;
661
- };
662
-
663
- /**
664
- * Creates a new URL by combining the baseURL with the requestedURL,
665
- * only when the requestedURL is not already an absolute URL.
666
- * If the requestURL is absolute, this function returns the requestedURL untouched.
667
- *
668
- * @param {string} baseURL The base URL
669
- * @param {string} requestedURL Absolute or relative URL to combine
670
- * @returns {string} The combined full path
671
- */
672
- var buildFullPath = function buildFullPath(baseURL, requestedURL) {
673
- if (baseURL && !isAbsoluteURL(requestedURL)) {
674
- return combineURLs(baseURL, requestedURL);
675
- }
676
- return requestedURL;
677
- };
678
-
679
- // Headers whose duplicates are ignored by node
680
- // c.f. https://nodejs.org/api/http.html#http_message_headers
681
- var ignoreDuplicateOf = [
682
- 'age', 'authorization', 'content-length', 'content-type', 'etag',
683
- 'expires', 'from', 'host', 'if-modified-since', 'if-unmodified-since',
684
- 'last-modified', 'location', 'max-forwards', 'proxy-authorization',
685
- 'referer', 'retry-after', 'user-agent'
686
- ];
687
-
688
- /**
689
- * Parse headers into an object
690
- *
691
- * ```
692
- * Date: Wed, 27 Aug 2014 08:58:49 GMT
693
- * Content-Type: application/json
694
- * Connection: keep-alive
695
- * Transfer-Encoding: chunked
696
- * ```
697
- *
698
- * @param {String} headers Headers needing to be parsed
699
- * @returns {Object} Headers parsed into an object
700
- */
701
- var parseHeaders = function parseHeaders(headers) {
702
- var parsed = {};
703
- var key;
704
- var val;
705
- var i;
706
-
707
- if (!headers) { return parsed; }
708
-
709
- utils.forEach(headers.split('\n'), function parser(line) {
710
- i = line.indexOf(':');
711
- key = utils.trim(line.substr(0, i)).toLowerCase();
712
- val = utils.trim(line.substr(i + 1));
713
-
714
- if (key) {
715
- if (parsed[key] && ignoreDuplicateOf.indexOf(key) >= 0) {
716
- return;
717
- }
718
- if (key === 'set-cookie') {
719
- parsed[key] = (parsed[key] ? parsed[key] : []).concat([val]);
720
- } else {
721
- parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val;
722
- }
723
- }
724
- });
725
-
726
- return parsed;
727
- };
728
-
729
- var isURLSameOrigin = (
730
- utils.isStandardBrowserEnv() ?
731
-
732
- // Standard browser envs have full support of the APIs needed to test
733
- // whether the request URL is of the same origin as current location.
734
- (function standardBrowserEnv() {
735
- var msie = /(msie|trident)/i.test(navigator.userAgent);
736
- var urlParsingNode = document.createElement('a');
737
- var originURL;
738
-
739
- /**
740
- * Parse a URL to discover it's components
741
- *
742
- * @param {String} url The URL to be parsed
743
- * @returns {Object}
744
- */
745
- function resolveURL(url) {
746
- var href = url;
747
-
748
- if (msie) {
749
- // IE needs attribute set twice to normalize properties
750
- urlParsingNode.setAttribute('href', href);
751
- href = urlParsingNode.href;
752
- }
753
-
754
- urlParsingNode.setAttribute('href', href);
755
-
756
- // urlParsingNode provides the UrlUtils interface - http://url.spec.whatwg.org/#urlutils
757
- return {
758
- href: urlParsingNode.href,
759
- protocol: urlParsingNode.protocol ? urlParsingNode.protocol.replace(/:$/, '') : '',
760
- host: urlParsingNode.host,
761
- search: urlParsingNode.search ? urlParsingNode.search.replace(/^\?/, '') : '',
762
- hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '',
763
- hostname: urlParsingNode.hostname,
764
- port: urlParsingNode.port,
765
- pathname: (urlParsingNode.pathname.charAt(0) === '/') ?
766
- urlParsingNode.pathname :
767
- '/' + urlParsingNode.pathname
768
- };
769
- }
770
-
771
- originURL = resolveURL(window.location.href);
772
-
773
- /**
774
- * Determine if a URL shares the same origin as the current location
775
- *
776
- * @param {String} requestURL The URL to test
777
- * @returns {boolean} True if URL shares the same origin, otherwise false
778
- */
779
- return function isURLSameOrigin(requestURL) {
780
- var parsed = (utils.isString(requestURL)) ? resolveURL(requestURL) : requestURL;
781
- return (parsed.protocol === originURL.protocol &&
782
- parsed.host === originURL.host);
783
- };
784
- })() :
785
-
786
- // Non standard browser envs (web workers, react-native) lack needed support.
787
- (function nonStandardBrowserEnv() {
788
- return function isURLSameOrigin() {
789
- return true;
790
- };
791
- })()
792
- );
793
-
794
- var xhr = function xhrAdapter(config) {
795
- return new Promise(function dispatchXhrRequest(resolve, reject) {
796
- var requestData = config.data;
797
- var requestHeaders = config.headers;
798
-
799
- if (utils.isFormData(requestData)) {
800
- delete requestHeaders['Content-Type']; // Let the browser set it
801
- }
802
-
803
- var request = new XMLHttpRequest();
804
-
805
- // HTTP basic authentication
806
- if (config.auth) {
807
- var username = config.auth.username || '';
808
- var password = config.auth.password ? unescape(encodeURIComponent(config.auth.password)) : '';
809
- requestHeaders.Authorization = 'Basic ' + btoa(username + ':' + password);
810
- }
811
-
812
- var fullPath = buildFullPath(config.baseURL, config.url);
813
- request.open(config.method.toUpperCase(), buildURL(fullPath, config.params, config.paramsSerializer), true);
814
-
815
- // Set the request timeout in MS
816
- request.timeout = config.timeout;
817
-
818
- // Listen for ready state
819
- request.onreadystatechange = function handleLoad() {
820
- if (!request || request.readyState !== 4) {
821
- return;
822
- }
823
-
824
- // The request errored out and we didn't get a response, this will be
825
- // handled by onerror instead
826
- // With one exception: request that using file: protocol, most browsers
827
- // will return status as 0 even though it's a successful request
828
- if (request.status === 0 && !(request.responseURL && request.responseURL.indexOf('file:') === 0)) {
829
- return;
830
- }
831
-
832
- // Prepare the response
833
- var responseHeaders = 'getAllResponseHeaders' in request ? parseHeaders(request.getAllResponseHeaders()) : null;
834
- var responseData = !config.responseType || config.responseType === 'text' ? request.responseText : request.response;
835
- var response = {
836
- data: responseData,
837
- status: request.status,
838
- statusText: request.statusText,
839
- headers: responseHeaders,
840
- config: config,
841
- request: request
842
- };
843
-
844
- settle(resolve, reject, response);
845
-
846
- // Clean up request
847
- request = null;
848
- };
849
-
850
- // Handle browser request cancellation (as opposed to a manual cancellation)
851
- request.onabort = function handleAbort() {
852
- if (!request) {
853
- return;
854
- }
855
-
856
- reject(createError('Request aborted', config, 'ECONNABORTED', request));
857
-
858
- // Clean up request
859
- request = null;
860
- };
861
-
862
- // Handle low level network errors
863
- request.onerror = function handleError() {
864
- // Real errors are hidden from us by the browser
865
- // onerror should only fire if it's a network error
866
- reject(createError('Network Error', config, null, request));
867
-
868
- // Clean up request
869
- request = null;
870
- };
871
-
872
- // Handle timeout
873
- request.ontimeout = function handleTimeout() {
874
- var timeoutErrorMessage = 'timeout of ' + config.timeout + 'ms exceeded';
875
- if (config.timeoutErrorMessage) {
876
- timeoutErrorMessage = config.timeoutErrorMessage;
877
- }
878
- reject(createError(timeoutErrorMessage, config, 'ECONNABORTED',
879
- request));
880
-
881
- // Clean up request
882
- request = null;
883
- };
884
-
885
- // Add xsrf header
886
- // This is only done if running in a standard browser environment.
887
- // Specifically not if we're in a web worker, or react-native.
888
- if (utils.isStandardBrowserEnv()) {
889
- // Add xsrf header
890
- var xsrfValue = (config.withCredentials || isURLSameOrigin(fullPath)) && config.xsrfCookieName ?
891
- cookies.read(config.xsrfCookieName) :
892
- undefined;
893
-
894
- if (xsrfValue) {
895
- requestHeaders[config.xsrfHeaderName] = xsrfValue;
896
- }
897
- }
898
-
899
- // Add headers to the request
900
- if ('setRequestHeader' in request) {
901
- utils.forEach(requestHeaders, function setRequestHeader(val, key) {
902
- if (typeof requestData === 'undefined' && key.toLowerCase() === 'content-type') {
903
- // Remove Content-Type if data is undefined
904
- delete requestHeaders[key];
905
- } else {
906
- // Otherwise add header to the request
907
- request.setRequestHeader(key, val);
908
- }
909
- });
910
- }
911
-
912
- // Add withCredentials to request if needed
913
- if (!utils.isUndefined(config.withCredentials)) {
914
- request.withCredentials = !!config.withCredentials;
915
- }
916
-
917
- // Add responseType to request if needed
918
- if (config.responseType) {
919
- try {
920
- request.responseType = config.responseType;
921
- } catch (e) {
922
- // Expected DOMException thrown by browsers not compatible XMLHttpRequest Level 2.
923
- // But, this can be suppressed for 'json' type as it can be parsed by default 'transformResponse' function.
924
- if (config.responseType !== 'json') {
925
- throw e;
926
- }
927
- }
928
- }
929
-
930
- // Handle progress if needed
931
- if (typeof config.onDownloadProgress === 'function') {
932
- request.addEventListener('progress', config.onDownloadProgress);
933
- }
934
-
935
- // Not all browsers support upload events
936
- if (typeof config.onUploadProgress === 'function' && request.upload) {
937
- request.upload.addEventListener('progress', config.onUploadProgress);
938
- }
939
-
940
- if (config.cancelToken) {
941
- // Handle cancellation
942
- config.cancelToken.promise.then(function onCanceled(cancel) {
943
- if (!request) {
944
- return;
945
- }
946
-
947
- request.abort();
948
- reject(cancel);
949
- // Clean up request
950
- request = null;
951
- });
952
- }
953
-
954
- if (!requestData) {
955
- requestData = null;
956
- }
957
-
958
- // Send the request
959
- request.send(requestData);
960
- });
961
- };
962
-
963
- var DEFAULT_CONTENT_TYPE = {
964
- 'Content-Type': 'application/x-www-form-urlencoded'
965
- };
966
-
967
- function setContentTypeIfUnset(headers, value) {
968
- if (!utils.isUndefined(headers) && utils.isUndefined(headers['Content-Type'])) {
969
- headers['Content-Type'] = value;
970
- }
971
- }
972
-
973
- function getDefaultAdapter() {
974
- var adapter;
975
- if (typeof XMLHttpRequest !== 'undefined') {
976
- // For browsers use XHR adapter
977
- adapter = xhr;
978
- } else if (typeof process !== 'undefined' && Object.prototype.toString.call(process) === '[object process]') {
979
- // For node use HTTP adapter
980
- adapter = xhr;
981
- }
982
- return adapter;
983
- }
984
-
985
- var defaults = {
986
- adapter: getDefaultAdapter(),
987
-
988
- transformRequest: [function transformRequest(data, headers) {
989
- normalizeHeaderName(headers, 'Accept');
990
- normalizeHeaderName(headers, 'Content-Type');
991
- if (utils.isFormData(data) ||
992
- utils.isArrayBuffer(data) ||
993
- utils.isBuffer(data) ||
994
- utils.isStream(data) ||
995
- utils.isFile(data) ||
996
- utils.isBlob(data)
997
- ) {
998
- return data;
999
- }
1000
- if (utils.isArrayBufferView(data)) {
1001
- return data.buffer;
1002
- }
1003
- if (utils.isURLSearchParams(data)) {
1004
- setContentTypeIfUnset(headers, 'application/x-www-form-urlencoded;charset=utf-8');
1005
- return data.toString();
1006
- }
1007
- if (utils.isObject(data)) {
1008
- setContentTypeIfUnset(headers, 'application/json;charset=utf-8');
1009
- return JSON.stringify(data);
1010
- }
1011
- return data;
1012
- }],
1013
-
1014
- transformResponse: [function transformResponse(data) {
1015
- /*eslint no-param-reassign:0*/
1016
- if (typeof data === 'string') {
1017
- try {
1018
- data = JSON.parse(data);
1019
- } catch (e) { /* Ignore */ }
1020
- }
1021
- return data;
1022
- }],
1023
-
1024
- /**
1025
- * A timeout in milliseconds to abort a request. If set to 0 (default) a
1026
- * timeout is not created.
1027
- */
1028
- timeout: 0,
1029
-
1030
- xsrfCookieName: 'XSRF-TOKEN',
1031
- xsrfHeaderName: 'X-XSRF-TOKEN',
1032
-
1033
- maxContentLength: -1,
1034
- maxBodyLength: -1,
1035
-
1036
- validateStatus: function validateStatus(status) {
1037
- return status >= 200 && status < 300;
1038
- }
1039
- };
1040
-
1041
- defaults.headers = {
1042
- common: {
1043
- 'Accept': 'application/json, text/plain, */*'
1044
- }
1045
- };
1046
-
1047
- utils.forEach(['delete', 'get', 'head'], function forEachMethodNoData(method) {
1048
- defaults.headers[method] = {};
1049
- });
1050
-
1051
- utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) {
1052
- defaults.headers[method] = utils.merge(DEFAULT_CONTENT_TYPE);
1053
- });
1054
-
1055
- var defaults_1 = defaults;
1056
-
1057
- /**
1058
- * Throws a `Cancel` if cancellation has been requested.
1059
- */
1060
- function throwIfCancellationRequested(config) {
1061
- if (config.cancelToken) {
1062
- config.cancelToken.throwIfRequested();
1063
- }
1064
- }
1065
-
1066
- /**
1067
- * Dispatch a request to the server using the configured adapter.
1068
- *
1069
- * @param {object} config The config that is to be used for the request
1070
- * @returns {Promise} The Promise to be fulfilled
1071
- */
1072
- var dispatchRequest = function dispatchRequest(config) {
1073
- throwIfCancellationRequested(config);
1074
-
1075
- // Ensure headers exist
1076
- config.headers = config.headers || {};
1077
-
1078
- // Transform request data
1079
- config.data = transformData(
1080
- config.data,
1081
- config.headers,
1082
- config.transformRequest
1083
- );
1084
-
1085
- // Flatten headers
1086
- config.headers = utils.merge(
1087
- config.headers.common || {},
1088
- config.headers[config.method] || {},
1089
- config.headers
1090
- );
1091
-
1092
- utils.forEach(
1093
- ['delete', 'get', 'head', 'post', 'put', 'patch', 'common'],
1094
- function cleanHeaderConfig(method) {
1095
- delete config.headers[method];
1096
- }
1097
- );
1098
-
1099
- var adapter = config.adapter || defaults_1.adapter;
1100
-
1101
- return adapter(config).then(function onAdapterResolution(response) {
1102
- throwIfCancellationRequested(config);
1103
-
1104
- // Transform response data
1105
- response.data = transformData(
1106
- response.data,
1107
- response.headers,
1108
- config.transformResponse
1109
- );
1110
-
1111
- return response;
1112
- }, function onAdapterRejection(reason) {
1113
- if (!isCancel(reason)) {
1114
- throwIfCancellationRequested(config);
1115
-
1116
- // Transform response data
1117
- if (reason && reason.response) {
1118
- reason.response.data = transformData(
1119
- reason.response.data,
1120
- reason.response.headers,
1121
- config.transformResponse
1122
- );
1123
- }
1124
- }
1125
-
1126
- return Promise.reject(reason);
1127
- });
1128
- };
1129
-
1130
- /**
1131
- * Config-specific merge-function which creates a new config-object
1132
- * by merging two configuration objects together.
1133
- *
1134
- * @param {Object} config1
1135
- * @param {Object} config2
1136
- * @returns {Object} New object resulting from merging config2 to config1
1137
- */
1138
- var mergeConfig = function mergeConfig(config1, config2) {
1139
- // eslint-disable-next-line no-param-reassign
1140
- config2 = config2 || {};
1141
- var config = {};
1142
-
1143
- var valueFromConfig2Keys = ['url', 'method', 'data'];
1144
- var mergeDeepPropertiesKeys = ['headers', 'auth', 'proxy', 'params'];
1145
- var defaultToConfig2Keys = [
1146
- 'baseURL', 'transformRequest', 'transformResponse', 'paramsSerializer',
1147
- 'timeout', 'timeoutMessage', 'withCredentials', 'adapter', 'responseType', 'xsrfCookieName',
1148
- 'xsrfHeaderName', 'onUploadProgress', 'onDownloadProgress', 'decompress',
1149
- 'maxContentLength', 'maxBodyLength', 'maxRedirects', 'transport', 'httpAgent',
1150
- 'httpsAgent', 'cancelToken', 'socketPath', 'responseEncoding'
1151
- ];
1152
- var directMergeKeys = ['validateStatus'];
1153
-
1154
- function getMergedValue(target, source) {
1155
- if (utils.isPlainObject(target) && utils.isPlainObject(source)) {
1156
- return utils.merge(target, source);
1157
- } else if (utils.isPlainObject(source)) {
1158
- return utils.merge({}, source);
1159
- } else if (utils.isArray(source)) {
1160
- return source.slice();
1161
- }
1162
- return source;
1163
- }
1164
-
1165
- function mergeDeepProperties(prop) {
1166
- if (!utils.isUndefined(config2[prop])) {
1167
- config[prop] = getMergedValue(config1[prop], config2[prop]);
1168
- } else if (!utils.isUndefined(config1[prop])) {
1169
- config[prop] = getMergedValue(undefined, config1[prop]);
1170
- }
1171
- }
1172
-
1173
- utils.forEach(valueFromConfig2Keys, function valueFromConfig2(prop) {
1174
- if (!utils.isUndefined(config2[prop])) {
1175
- config[prop] = getMergedValue(undefined, config2[prop]);
1176
- }
1177
- });
1178
-
1179
- utils.forEach(mergeDeepPropertiesKeys, mergeDeepProperties);
1180
-
1181
- utils.forEach(defaultToConfig2Keys, function defaultToConfig2(prop) {
1182
- if (!utils.isUndefined(config2[prop])) {
1183
- config[prop] = getMergedValue(undefined, config2[prop]);
1184
- } else if (!utils.isUndefined(config1[prop])) {
1185
- config[prop] = getMergedValue(undefined, config1[prop]);
1186
- }
1187
- });
1188
-
1189
- utils.forEach(directMergeKeys, function merge(prop) {
1190
- if (prop in config2) {
1191
- config[prop] = getMergedValue(config1[prop], config2[prop]);
1192
- } else if (prop in config1) {
1193
- config[prop] = getMergedValue(undefined, config1[prop]);
1194
- }
1195
- });
1196
-
1197
- var axiosKeys = valueFromConfig2Keys
1198
- .concat(mergeDeepPropertiesKeys)
1199
- .concat(defaultToConfig2Keys)
1200
- .concat(directMergeKeys);
1201
-
1202
- var otherKeys = Object
1203
- .keys(config1)
1204
- .concat(Object.keys(config2))
1205
- .filter(function filterAxiosKeys(key) {
1206
- return axiosKeys.indexOf(key) === -1;
1207
- });
1208
-
1209
- utils.forEach(otherKeys, mergeDeepProperties);
1210
-
1211
- return config;
1212
- };
1213
-
1214
- /**
1215
- * Create a new instance of Axios
1216
- *
1217
- * @param {Object} instanceConfig The default config for the instance
1218
- */
1219
- function Axios(instanceConfig) {
1220
- this.defaults = instanceConfig;
1221
- this.interceptors = {
1222
- request: new InterceptorManager_1(),
1223
- response: new InterceptorManager_1()
1224
- };
1225
- }
1226
-
1227
- /**
1228
- * Dispatch a request
1229
- *
1230
- * @param {Object} config The config specific for this request (merged with this.defaults)
1231
- */
1232
- Axios.prototype.request = function request(config) {
1233
- /*eslint no-param-reassign:0*/
1234
- // Allow for axios('example/url'[, config]) a la fetch API
1235
- if (typeof config === 'string') {
1236
- config = arguments[1] || {};
1237
- config.url = arguments[0];
1238
- } else {
1239
- config = config || {};
1240
- }
1241
-
1242
- config = mergeConfig(this.defaults, config);
1243
-
1244
- // Set config.method
1245
- if (config.method) {
1246
- config.method = config.method.toLowerCase();
1247
- } else if (this.defaults.method) {
1248
- config.method = this.defaults.method.toLowerCase();
1249
- } else {
1250
- config.method = 'get';
1251
- }
1252
-
1253
- // Hook up interceptors middleware
1254
- var chain = [dispatchRequest, undefined];
1255
- var promise = Promise.resolve(config);
1256
-
1257
- this.interceptors.request.forEach(function unshiftRequestInterceptors(interceptor) {
1258
- chain.unshift(interceptor.fulfilled, interceptor.rejected);
1259
- });
1260
-
1261
- this.interceptors.response.forEach(function pushResponseInterceptors(interceptor) {
1262
- chain.push(interceptor.fulfilled, interceptor.rejected);
1263
- });
1264
-
1265
- while (chain.length) {
1266
- promise = promise.then(chain.shift(), chain.shift());
1267
- }
1268
-
1269
- return promise;
1270
- };
1271
-
1272
- Axios.prototype.getUri = function getUri(config) {
1273
- config = mergeConfig(this.defaults, config);
1274
- return buildURL(config.url, config.params, config.paramsSerializer).replace(/^\?/, '');
1275
- };
1276
-
1277
- // Provide aliases for supported request methods
1278
- utils.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) {
1279
- /*eslint func-names:0*/
1280
- Axios.prototype[method] = function(url, config) {
1281
- return this.request(mergeConfig(config || {}, {
1282
- method: method,
1283
- url: url,
1284
- data: (config || {}).data
1285
- }));
1286
- };
1287
- });
1288
-
1289
- utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) {
1290
- /*eslint func-names:0*/
1291
- Axios.prototype[method] = function(url, data, config) {
1292
- return this.request(mergeConfig(config || {}, {
1293
- method: method,
1294
- url: url,
1295
- data: data
1296
- }));
1297
- };
1298
- });
1299
-
1300
- var Axios_1 = Axios;
1301
-
1302
- /**
1303
- * A `Cancel` is an object that is thrown when an operation is canceled.
1304
- *
1305
- * @class
1306
- * @param {string=} message The message.
1307
- */
1308
- function Cancel(message) {
1309
- this.message = message;
1310
- }
1311
-
1312
- Cancel.prototype.toString = function toString() {
1313
- return 'Cancel' + (this.message ? ': ' + this.message : '');
1314
- };
1315
-
1316
- Cancel.prototype.__CANCEL__ = true;
1317
-
1318
- var Cancel_1 = Cancel;
1319
-
1320
- /**
1321
- * A `CancelToken` is an object that can be used to request cancellation of an operation.
1322
- *
1323
- * @class
1324
- * @param {Function} executor The executor function.
1325
- */
1326
- function CancelToken(executor) {
1327
- if (typeof executor !== 'function') {
1328
- throw new TypeError('executor must be a function.');
1329
- }
1330
-
1331
- var resolvePromise;
1332
- this.promise = new Promise(function promiseExecutor(resolve) {
1333
- resolvePromise = resolve;
1334
- });
1335
-
1336
- var token = this;
1337
- executor(function cancel(message) {
1338
- if (token.reason) {
1339
- // Cancellation has already been requested
1340
- return;
1341
- }
1342
-
1343
- token.reason = new Cancel_1(message);
1344
- resolvePromise(token.reason);
1345
- });
1346
- }
1347
-
1348
- /**
1349
- * Throws a `Cancel` if cancellation has been requested.
1350
- */
1351
- CancelToken.prototype.throwIfRequested = function throwIfRequested() {
1352
- if (this.reason) {
1353
- throw this.reason;
1354
- }
1355
- };
1356
-
1357
- /**
1358
- * Returns an object that contains a new `CancelToken` and a function that, when called,
1359
- * cancels the `CancelToken`.
1360
- */
1361
- CancelToken.source = function source() {
1362
- var cancel;
1363
- var token = new CancelToken(function executor(c) {
1364
- cancel = c;
1365
- });
1366
- return {
1367
- token: token,
1368
- cancel: cancel
1369
- };
1370
- };
1371
-
1372
- var CancelToken_1 = CancelToken;
1373
-
1374
- /**
1375
- * Syntactic sugar for invoking a function and expanding an array for arguments.
1376
- *
1377
- * Common use case would be to use `Function.prototype.apply`.
1378
- *
1379
- * ```js
1380
- * function f(x, y, z) {}
1381
- * var args = [1, 2, 3];
1382
- * f.apply(null, args);
1383
- * ```
1384
- *
1385
- * With `spread` this example can be re-written.
1386
- *
1387
- * ```js
1388
- * spread(function(x, y, z) {})([1, 2, 3]);
1389
- * ```
1390
- *
1391
- * @param {Function} callback
1392
- * @returns {Function}
1393
- */
1394
- var spread = function spread(callback) {
1395
- return function wrap(arr) {
1396
- return callback.apply(null, arr);
1397
- };
1398
- };
1399
-
1400
- /**
1401
- * Determines whether the payload is an error thrown by Axios
1402
- *
1403
- * @param {*} payload The value to test
1404
- * @returns {boolean} True if the payload is an error thrown by Axios, otherwise false
1405
- */
1406
- var isAxiosError = function isAxiosError(payload) {
1407
- return (typeof payload === 'object') && (payload.isAxiosError === true);
1408
- };
1409
-
1410
- /**
1411
- * Create an instance of Axios
1412
- *
1413
- * @param {Object} defaultConfig The default config for the instance
1414
- * @return {Axios} A new instance of Axios
1415
- */
1416
- function createInstance(defaultConfig) {
1417
- var context = new Axios_1(defaultConfig);
1418
- var instance = bind(Axios_1.prototype.request, context);
1419
-
1420
- // Copy axios.prototype to instance
1421
- utils.extend(instance, Axios_1.prototype, context);
1422
-
1423
- // Copy context to instance
1424
- utils.extend(instance, context);
1425
-
1426
- return instance;
1427
- }
1428
-
1429
- // Create the default instance to be exported
1430
- var axios = createInstance(defaults_1);
1431
-
1432
- // Expose Axios class to allow class inheritance
1433
- axios.Axios = Axios_1;
1434
-
1435
- // Factory for creating new instances
1436
- axios.create = function create(instanceConfig) {
1437
- return createInstance(mergeConfig(axios.defaults, instanceConfig));
1438
- };
1439
-
1440
- // Expose Cancel & CancelToken
1441
- axios.Cancel = Cancel_1;
1442
- axios.CancelToken = CancelToken_1;
1443
- axios.isCancel = isCancel;
1444
-
1445
- // Expose all/spread
1446
- axios.all = function all(promises) {
1447
- return Promise.all(promises);
1448
- };
1449
- axios.spread = spread;
1450
-
1451
- // Expose isAxiosError
1452
- axios.isAxiosError = isAxiosError;
1453
-
1454
- var axios_1 = axios;
1455
-
1456
- // Allow use of default import syntax in TypeScript
1457
- var _default = axios;
1458
- axios_1.default = _default;
1459
-
1460
- var axios$1 = axios_1;
1461
-
1462
- var replace = String.prototype.replace;
1463
- var percentTwenties = /%20/g;
1464
-
1465
- var Format = {
1466
- RFC1738: 'RFC1738',
1467
- RFC3986: 'RFC3986'
1468
- };
1469
-
1470
- var formats = {
1471
- 'default': Format.RFC3986,
1472
- formatters: {
1473
- RFC1738: function (value) {
1474
- return replace.call(value, percentTwenties, '+');
1475
- },
1476
- RFC3986: function (value) {
1477
- return String(value);
1478
- }
1479
- },
1480
- RFC1738: Format.RFC1738,
1481
- RFC3986: Format.RFC3986
1482
- };
1483
-
1484
- var has = Object.prototype.hasOwnProperty;
1485
- var isArray$1 = Array.isArray;
1486
-
1487
- var hexTable = (function () {
1488
- var array = [];
1489
- for (var i = 0; i < 256; ++i) {
1490
- array.push('%' + ((i < 16 ? '0' : '') + i.toString(16)).toUpperCase());
1491
- }
1492
-
1493
- return array;
1494
- }());
1495
-
1496
- var compactQueue = function compactQueue(queue) {
1497
- while (queue.length > 1) {
1498
- var item = queue.pop();
1499
- var obj = item.obj[item.prop];
1500
-
1501
- if (isArray$1(obj)) {
1502
- var compacted = [];
1503
-
1504
- for (var j = 0; j < obj.length; ++j) {
1505
- if (typeof obj[j] !== 'undefined') {
1506
- compacted.push(obj[j]);
1507
- }
1508
- }
1509
-
1510
- item.obj[item.prop] = compacted;
1511
- }
1512
- }
1513
- };
1514
-
1515
- var arrayToObject = function arrayToObject(source, options) {
1516
- var obj = options && options.plainObjects ? Object.create(null) : {};
1517
- for (var i = 0; i < source.length; ++i) {
1518
- if (typeof source[i] !== 'undefined') {
1519
- obj[i] = source[i];
1520
- }
1521
- }
1522
-
1523
- return obj;
1524
- };
1525
-
1526
- var merge$1 = function merge(target, source, options) {
1527
- /* eslint no-param-reassign: 0 */
1528
- if (!source) {
1529
- return target;
1530
- }
1531
-
1532
- if (typeof source !== 'object') {
1533
- if (isArray$1(target)) {
1534
- target.push(source);
1535
- } else if (target && typeof target === 'object') {
1536
- if ((options && (options.plainObjects || options.allowPrototypes)) || !has.call(Object.prototype, source)) {
1537
- target[source] = true;
1538
- }
1539
- } else {
1540
- return [target, source];
1541
- }
1542
-
1543
- return target;
1544
- }
1545
-
1546
- if (!target || typeof target !== 'object') {
1547
- return [target].concat(source);
1548
- }
1549
-
1550
- var mergeTarget = target;
1551
- if (isArray$1(target) && !isArray$1(source)) {
1552
- mergeTarget = arrayToObject(target, options);
1553
- }
1554
-
1555
- if (isArray$1(target) && isArray$1(source)) {
1556
- source.forEach(function (item, i) {
1557
- if (has.call(target, i)) {
1558
- var targetItem = target[i];
1559
- if (targetItem && typeof targetItem === 'object' && item && typeof item === 'object') {
1560
- target[i] = merge(targetItem, item, options);
1561
- } else {
1562
- target.push(item);
1563
- }
1564
- } else {
1565
- target[i] = item;
1566
- }
1567
- });
1568
- return target;
1569
- }
1570
-
1571
- return Object.keys(source).reduce(function (acc, key) {
1572
- var value = source[key];
1573
-
1574
- if (has.call(acc, key)) {
1575
- acc[key] = merge(acc[key], value, options);
1576
- } else {
1577
- acc[key] = value;
1578
- }
1579
- return acc;
1580
- }, mergeTarget);
1581
- };
1582
-
1583
- var assign = function assignSingleSource(target, source) {
1584
- return Object.keys(source).reduce(function (acc, key) {
1585
- acc[key] = source[key];
1586
- return acc;
1587
- }, target);
1588
- };
1589
-
1590
- var decode = function (str, decoder, charset) {
1591
- var strWithoutPlus = str.replace(/\+/g, ' ');
1592
- if (charset === 'iso-8859-1') {
1593
- // unescape never throws, no try...catch needed:
1594
- return strWithoutPlus.replace(/%[0-9a-f]{2}/gi, unescape);
1595
- }
1596
- // utf-8
1597
- try {
1598
- return decodeURIComponent(strWithoutPlus);
1599
- } catch (e) {
1600
- return strWithoutPlus;
1601
- }
1602
- };
1603
-
1604
- var encode$1 = function encode(str, defaultEncoder, charset, kind, format) {
1605
- // This code was originally written by Brian White (mscdex) for the io.js core querystring library.
1606
- // It has been adapted here for stricter adherence to RFC 3986
1607
- if (str.length === 0) {
1608
- return str;
1609
- }
1610
-
1611
- var string = str;
1612
- if (typeof str === 'symbol') {
1613
- string = Symbol.prototype.toString.call(str);
1614
- } else if (typeof str !== 'string') {
1615
- string = String(str);
1616
- }
1617
-
1618
- if (charset === 'iso-8859-1') {
1619
- return escape(string).replace(/%u[0-9a-f]{4}/gi, function ($0) {
1620
- return '%26%23' + parseInt($0.slice(2), 16) + '%3B';
1621
- });
1622
- }
1623
-
1624
- var out = '';
1625
- for (var i = 0; i < string.length; ++i) {
1626
- var c = string.charCodeAt(i);
1627
-
1628
- if (
1629
- c === 0x2D // -
1630
- || c === 0x2E // .
1631
- || c === 0x5F // _
1632
- || c === 0x7E // ~
1633
- || (c >= 0x30 && c <= 0x39) // 0-9
1634
- || (c >= 0x41 && c <= 0x5A) // a-z
1635
- || (c >= 0x61 && c <= 0x7A) // A-Z
1636
- || (format === formats.RFC1738 && (c === 0x28 || c === 0x29)) // ( )
1637
- ) {
1638
- out += string.charAt(i);
1639
- continue;
1640
- }
1641
-
1642
- if (c < 0x80) {
1643
- out = out + hexTable[c];
1644
- continue;
1645
- }
1646
-
1647
- if (c < 0x800) {
1648
- out = out + (hexTable[0xC0 | (c >> 6)] + hexTable[0x80 | (c & 0x3F)]);
1649
- continue;
1650
- }
1651
-
1652
- if (c < 0xD800 || c >= 0xE000) {
1653
- out = out + (hexTable[0xE0 | (c >> 12)] + hexTable[0x80 | ((c >> 6) & 0x3F)] + hexTable[0x80 | (c & 0x3F)]);
1654
- continue;
1655
- }
1656
-
1657
- i += 1;
1658
- c = 0x10000 + (((c & 0x3FF) << 10) | (string.charCodeAt(i) & 0x3FF));
1659
- out += hexTable[0xF0 | (c >> 18)]
1660
- + hexTable[0x80 | ((c >> 12) & 0x3F)]
1661
- + hexTable[0x80 | ((c >> 6) & 0x3F)]
1662
- + hexTable[0x80 | (c & 0x3F)];
1663
- }
1664
-
1665
- return out;
1666
- };
1667
-
1668
- var compact = function compact(value) {
1669
- var queue = [{ obj: { o: value }, prop: 'o' }];
1670
- var refs = [];
1671
-
1672
- for (var i = 0; i < queue.length; ++i) {
1673
- var item = queue[i];
1674
- var obj = item.obj[item.prop];
1675
-
1676
- var keys = Object.keys(obj);
1677
- for (var j = 0; j < keys.length; ++j) {
1678
- var key = keys[j];
1679
- var val = obj[key];
1680
- if (typeof val === 'object' && val !== null && refs.indexOf(val) === -1) {
1681
- queue.push({ obj: obj, prop: key });
1682
- refs.push(val);
1683
- }
1684
- }
1685
- }
1686
-
1687
- compactQueue(queue);
1688
-
1689
- return value;
1690
- };
1691
-
1692
- var isRegExp = function isRegExp(obj) {
1693
- return Object.prototype.toString.call(obj) === '[object RegExp]';
1694
- };
1695
-
1696
- var isBuffer$1 = function isBuffer(obj) {
1697
- if (!obj || typeof obj !== 'object') {
1698
- return false;
1699
- }
1700
-
1701
- return !!(obj.constructor && obj.constructor.isBuffer && obj.constructor.isBuffer(obj));
1702
- };
1703
-
1704
- var combine = function combine(a, b) {
1705
- return [].concat(a, b);
1706
- };
1707
-
1708
- var maybeMap = function maybeMap(val, fn) {
1709
- if (isArray$1(val)) {
1710
- var mapped = [];
1711
- for (var i = 0; i < val.length; i += 1) {
1712
- mapped.push(fn(val[i]));
1713
- }
1714
- return mapped;
1715
- }
1716
- return fn(val);
1717
- };
1718
-
1719
- var utils$1 = {
1720
- arrayToObject: arrayToObject,
1721
- assign: assign,
1722
- combine: combine,
1723
- compact: compact,
1724
- decode: decode,
1725
- encode: encode$1,
1726
- isBuffer: isBuffer$1,
1727
- isRegExp: isRegExp,
1728
- maybeMap: maybeMap,
1729
- merge: merge$1
1730
- };
1731
-
1732
- var has$1 = Object.prototype.hasOwnProperty;
1733
-
1734
- var arrayPrefixGenerators = {
1735
- brackets: function brackets(prefix) {
1736
- return prefix + '[]';
1737
- },
1738
- comma: 'comma',
1739
- indices: function indices(prefix, key) {
1740
- return prefix + '[' + key + ']';
1741
- },
1742
- repeat: function repeat(prefix) {
1743
- return prefix;
1744
- }
1745
- };
1746
-
1747
- var isArray$2 = Array.isArray;
1748
- var push = Array.prototype.push;
1749
- var pushToArray = function (arr, valueOrArray) {
1750
- push.apply(arr, isArray$2(valueOrArray) ? valueOrArray : [valueOrArray]);
1751
- };
1752
-
1753
- var toISO = Date.prototype.toISOString;
1754
-
1755
- var defaultFormat = formats['default'];
1756
- var defaults$1 = {
1757
- addQueryPrefix: false,
1758
- allowDots: false,
1759
- charset: 'utf-8',
1760
- charsetSentinel: false,
1761
- delimiter: '&',
1762
- encode: true,
1763
- encoder: utils$1.encode,
1764
- encodeValuesOnly: false,
1765
- format: defaultFormat,
1766
- formatter: formats.formatters[defaultFormat],
1767
- // deprecated
1768
- indices: false,
1769
- serializeDate: function serializeDate(date) {
1770
- return toISO.call(date);
1771
- },
1772
- skipNulls: false,
1773
- strictNullHandling: false
1774
- };
1775
-
1776
- var isNonNullishPrimitive = function isNonNullishPrimitive(v) {
1777
- return typeof v === 'string'
1778
- || typeof v === 'number'
1779
- || typeof v === 'boolean'
1780
- || typeof v === 'symbol'
1781
- || typeof v === 'bigint';
1782
- };
1783
-
1784
- var stringify = function stringify(
1785
- object,
1786
- prefix,
1787
- generateArrayPrefix,
1788
- strictNullHandling,
1789
- skipNulls,
1790
- encoder,
1791
- filter,
1792
- sort,
1793
- allowDots,
1794
- serializeDate,
1795
- format,
1796
- formatter,
1797
- encodeValuesOnly,
1798
- charset
1799
- ) {
1800
- var obj = object;
1801
- if (typeof filter === 'function') {
1802
- obj = filter(prefix, obj);
1803
- } else if (obj instanceof Date) {
1804
- obj = serializeDate(obj);
1805
- } else if (generateArrayPrefix === 'comma' && isArray$2(obj)) {
1806
- obj = utils$1.maybeMap(obj, function (value) {
1807
- if (value instanceof Date) {
1808
- return serializeDate(value);
1809
- }
1810
- return value;
1811
- });
1812
- }
1813
-
1814
- if (obj === null) {
1815
- if (strictNullHandling) {
1816
- return encoder && !encodeValuesOnly ? encoder(prefix, defaults$1.encoder, charset, 'key', format) : prefix;
1817
- }
1818
-
1819
- obj = '';
1820
- }
1821
-
1822
- if (isNonNullishPrimitive(obj) || utils$1.isBuffer(obj)) {
1823
- if (encoder) {
1824
- var keyValue = encodeValuesOnly ? prefix : encoder(prefix, defaults$1.encoder, charset, 'key', format);
1825
- return [formatter(keyValue) + '=' + formatter(encoder(obj, defaults$1.encoder, charset, 'value', format))];
1826
- }
1827
- return [formatter(prefix) + '=' + formatter(String(obj))];
1828
- }
1829
-
1830
- var values = [];
1831
-
1832
- if (typeof obj === 'undefined') {
1833
- return values;
1834
- }
1835
-
1836
- var objKeys;
1837
- if (generateArrayPrefix === 'comma' && isArray$2(obj)) {
1838
- // we need to join elements in
1839
- objKeys = [{ value: obj.length > 0 ? obj.join(',') || null : undefined }];
1840
- } else if (isArray$2(filter)) {
1841
- objKeys = filter;
1842
- } else {
1843
- var keys = Object.keys(obj);
1844
- objKeys = sort ? keys.sort(sort) : keys;
1845
- }
1846
-
1847
- for (var i = 0; i < objKeys.length; ++i) {
1848
- var key = objKeys[i];
1849
- var value = typeof key === 'object' && key.value !== undefined ? key.value : obj[key];
1850
-
1851
- if (skipNulls && value === null) {
1852
- continue;
1853
- }
1854
-
1855
- var keyPrefix = isArray$2(obj)
1856
- ? typeof generateArrayPrefix === 'function' ? generateArrayPrefix(prefix, key) : prefix
1857
- : prefix + (allowDots ? '.' + key : '[' + key + ']');
1858
-
1859
- pushToArray(values, stringify(
1860
- value,
1861
- keyPrefix,
1862
- generateArrayPrefix,
1863
- strictNullHandling,
1864
- skipNulls,
1865
- encoder,
1866
- filter,
1867
- sort,
1868
- allowDots,
1869
- serializeDate,
1870
- format,
1871
- formatter,
1872
- encodeValuesOnly,
1873
- charset
1874
- ));
1875
- }
1876
-
1877
- return values;
1878
- };
1879
-
1880
- var normalizeStringifyOptions = function normalizeStringifyOptions(opts) {
1881
- if (!opts) {
1882
- return defaults$1;
1883
- }
1884
-
1885
- if (opts.encoder !== null && opts.encoder !== undefined && typeof opts.encoder !== 'function') {
1886
- throw new TypeError('Encoder has to be a function.');
1887
- }
1888
-
1889
- var charset = opts.charset || defaults$1.charset;
1890
- if (typeof opts.charset !== 'undefined' && opts.charset !== 'utf-8' && opts.charset !== 'iso-8859-1') {
1891
- throw new TypeError('The charset option must be either utf-8, iso-8859-1, or undefined');
1892
- }
1893
-
1894
- var format = formats['default'];
1895
- if (typeof opts.format !== 'undefined') {
1896
- if (!has$1.call(formats.formatters, opts.format)) {
1897
- throw new TypeError('Unknown format option provided.');
1898
- }
1899
- format = opts.format;
1900
- }
1901
- var formatter = formats.formatters[format];
1902
-
1903
- var filter = defaults$1.filter;
1904
- if (typeof opts.filter === 'function' || isArray$2(opts.filter)) {
1905
- filter = opts.filter;
1906
- }
1907
-
1908
- return {
1909
- addQueryPrefix: typeof opts.addQueryPrefix === 'boolean' ? opts.addQueryPrefix : defaults$1.addQueryPrefix,
1910
- allowDots: typeof opts.allowDots === 'undefined' ? defaults$1.allowDots : !!opts.allowDots,
1911
- charset: charset,
1912
- charsetSentinel: typeof opts.charsetSentinel === 'boolean' ? opts.charsetSentinel : defaults$1.charsetSentinel,
1913
- delimiter: typeof opts.delimiter === 'undefined' ? defaults$1.delimiter : opts.delimiter,
1914
- encode: typeof opts.encode === 'boolean' ? opts.encode : defaults$1.encode,
1915
- encoder: typeof opts.encoder === 'function' ? opts.encoder : defaults$1.encoder,
1916
- encodeValuesOnly: typeof opts.encodeValuesOnly === 'boolean' ? opts.encodeValuesOnly : defaults$1.encodeValuesOnly,
1917
- filter: filter,
1918
- format: format,
1919
- formatter: formatter,
1920
- serializeDate: typeof opts.serializeDate === 'function' ? opts.serializeDate : defaults$1.serializeDate,
1921
- skipNulls: typeof opts.skipNulls === 'boolean' ? opts.skipNulls : defaults$1.skipNulls,
1922
- sort: typeof opts.sort === 'function' ? opts.sort : null,
1923
- strictNullHandling: typeof opts.strictNullHandling === 'boolean' ? opts.strictNullHandling : defaults$1.strictNullHandling
1924
- };
1925
- };
1926
-
1927
- var stringify_1 = function (object, opts) {
1928
- var obj = object;
1929
- var options = normalizeStringifyOptions(opts);
1930
-
1931
- var objKeys;
1932
- var filter;
1933
-
1934
- if (typeof options.filter === 'function') {
1935
- filter = options.filter;
1936
- obj = filter('', obj);
1937
- } else if (isArray$2(options.filter)) {
1938
- filter = options.filter;
1939
- objKeys = filter;
1940
- }
1941
-
1942
- var keys = [];
1943
-
1944
- if (typeof obj !== 'object' || obj === null) {
1945
- return '';
1946
- }
1947
-
1948
- var arrayFormat;
1949
- if (opts && opts.arrayFormat in arrayPrefixGenerators) {
1950
- arrayFormat = opts.arrayFormat;
1951
- } else if (opts && 'indices' in opts) {
1952
- arrayFormat = opts.indices ? 'indices' : 'repeat';
1953
- } else {
1954
- arrayFormat = 'indices';
1955
- }
1956
-
1957
- var generateArrayPrefix = arrayPrefixGenerators[arrayFormat];
1958
-
1959
- if (!objKeys) {
1960
- objKeys = Object.keys(obj);
1961
- }
1962
-
1963
- if (options.sort) {
1964
- objKeys.sort(options.sort);
1965
- }
1966
-
1967
- for (var i = 0; i < objKeys.length; ++i) {
1968
- var key = objKeys[i];
1969
-
1970
- if (options.skipNulls && obj[key] === null) {
1971
- continue;
1972
- }
1973
- pushToArray(keys, stringify(
1974
- obj[key],
1975
- key,
1976
- generateArrayPrefix,
1977
- options.strictNullHandling,
1978
- options.skipNulls,
1979
- options.encode ? options.encoder : null,
1980
- options.filter,
1981
- options.sort,
1982
- options.allowDots,
1983
- options.serializeDate,
1984
- options.format,
1985
- options.formatter,
1986
- options.encodeValuesOnly,
1987
- options.charset
1988
- ));
1989
- }
1990
-
1991
- var joined = keys.join(options.delimiter);
1992
- var prefix = options.addQueryPrefix === true ? '?' : '';
1993
-
1994
- if (options.charsetSentinel) {
1995
- if (options.charset === 'iso-8859-1') {
1996
- // encodeURIComponent('&#10003;'), the "numeric entity" representation of a checkmark
1997
- prefix += 'utf8=%26%2310003%3B&';
1998
- } else {
1999
- // encodeURIComponent('✓')
2000
- prefix += 'utf8=%E2%9C%93&';
2001
- }
2002
- }
2003
-
2004
- return joined.length > 0 ? prefix + joined : '';
2005
- };
2006
-
2007
- var has$2 = Object.prototype.hasOwnProperty;
2008
- var isArray$3 = Array.isArray;
2009
-
2010
- var defaults$2 = {
2011
- allowDots: false,
2012
- allowPrototypes: false,
2013
- arrayLimit: 20,
2014
- charset: 'utf-8',
2015
- charsetSentinel: false,
2016
- comma: false,
2017
- decoder: utils$1.decode,
2018
- delimiter: '&',
2019
- depth: 5,
2020
- ignoreQueryPrefix: false,
2021
- interpretNumericEntities: false,
2022
- parameterLimit: 1000,
2023
- parseArrays: true,
2024
- plainObjects: false,
2025
- strictNullHandling: false
2026
- };
2027
-
2028
- var interpretNumericEntities = function (str) {
2029
- return str.replace(/&#(\d+);/g, function ($0, numberStr) {
2030
- return String.fromCharCode(parseInt(numberStr, 10));
2031
- });
2032
- };
2033
-
2034
- var parseArrayValue = function (val, options) {
2035
- if (val && typeof val === 'string' && options.comma && val.indexOf(',') > -1) {
2036
- return val.split(',');
2037
- }
2038
-
2039
- return val;
2040
- };
2041
-
2042
- // This is what browsers will submit when the ✓ character occurs in an
2043
- // application/x-www-form-urlencoded body and the encoding of the page containing
2044
- // the form is iso-8859-1, or when the submitted form has an accept-charset
2045
- // attribute of iso-8859-1. Presumably also with other charsets that do not contain
2046
- // the ✓ character, such as us-ascii.
2047
- var isoSentinel = 'utf8=%26%2310003%3B'; // encodeURIComponent('&#10003;')
2048
-
2049
- // These are the percent-encoded utf-8 octets representing a checkmark, indicating that the request actually is utf-8 encoded.
2050
- var charsetSentinel = 'utf8=%E2%9C%93'; // encodeURIComponent('✓')
2051
-
2052
- var parseValues = function parseQueryStringValues(str, options) {
2053
- var obj = {};
2054
- var cleanStr = options.ignoreQueryPrefix ? str.replace(/^\?/, '') : str;
2055
- var limit = options.parameterLimit === Infinity ? undefined : options.parameterLimit;
2056
- var parts = cleanStr.split(options.delimiter, limit);
2057
- var skipIndex = -1; // Keep track of where the utf8 sentinel was found
2058
- var i;
2059
-
2060
- var charset = options.charset;
2061
- if (options.charsetSentinel) {
2062
- for (i = 0; i < parts.length; ++i) {
2063
- if (parts[i].indexOf('utf8=') === 0) {
2064
- if (parts[i] === charsetSentinel) {
2065
- charset = 'utf-8';
2066
- } else if (parts[i] === isoSentinel) {
2067
- charset = 'iso-8859-1';
2068
- }
2069
- skipIndex = i;
2070
- i = parts.length; // The eslint settings do not allow break;
2071
- }
2072
- }
2073
- }
2074
-
2075
- for (i = 0; i < parts.length; ++i) {
2076
- if (i === skipIndex) {
2077
- continue;
2078
- }
2079
- var part = parts[i];
2080
-
2081
- var bracketEqualsPos = part.indexOf(']=');
2082
- var pos = bracketEqualsPos === -1 ? part.indexOf('=') : bracketEqualsPos + 1;
2083
-
2084
- var key, val;
2085
- if (pos === -1) {
2086
- key = options.decoder(part, defaults$2.decoder, charset, 'key');
2087
- val = options.strictNullHandling ? null : '';
2088
- } else {
2089
- key = options.decoder(part.slice(0, pos), defaults$2.decoder, charset, 'key');
2090
- val = utils$1.maybeMap(
2091
- parseArrayValue(part.slice(pos + 1), options),
2092
- function (encodedVal) {
2093
- return options.decoder(encodedVal, defaults$2.decoder, charset, 'value');
2094
- }
2095
- );
2096
- }
2097
-
2098
- if (val && options.interpretNumericEntities && charset === 'iso-8859-1') {
2099
- val = interpretNumericEntities(val);
2100
- }
2101
-
2102
- if (part.indexOf('[]=') > -1) {
2103
- val = isArray$3(val) ? [val] : val;
2104
- }
2105
-
2106
- if (has$2.call(obj, key)) {
2107
- obj[key] = utils$1.combine(obj[key], val);
2108
- } else {
2109
- obj[key] = val;
2110
- }
2111
- }
2112
-
2113
- return obj;
2114
- };
2115
-
2116
- var parseObject = function (chain, val, options, valuesParsed) {
2117
- var leaf = valuesParsed ? val : parseArrayValue(val, options);
2118
-
2119
- for (var i = chain.length - 1; i >= 0; --i) {
2120
- var obj;
2121
- var root = chain[i];
2122
-
2123
- if (root === '[]' && options.parseArrays) {
2124
- obj = [].concat(leaf);
2125
- } else {
2126
- obj = options.plainObjects ? Object.create(null) : {};
2127
- var cleanRoot = root.charAt(0) === '[' && root.charAt(root.length - 1) === ']' ? root.slice(1, -1) : root;
2128
- var index = parseInt(cleanRoot, 10);
2129
- if (!options.parseArrays && cleanRoot === '') {
2130
- obj = { 0: leaf };
2131
- } else if (
2132
- !isNaN(index)
2133
- && root !== cleanRoot
2134
- && String(index) === cleanRoot
2135
- && index >= 0
2136
- && (options.parseArrays && index <= options.arrayLimit)
2137
- ) {
2138
- obj = [];
2139
- obj[index] = leaf;
2140
- } else {
2141
- obj[cleanRoot] = leaf;
2142
- }
2143
- }
2144
-
2145
- leaf = obj;
2146
- }
2147
-
2148
- return leaf;
2149
- };
2150
-
2151
- var parseKeys = function parseQueryStringKeys(givenKey, val, options, valuesParsed) {
2152
- if (!givenKey) {
2153
- return;
2154
- }
2155
-
2156
- // Transform dot notation to bracket notation
2157
- var key = options.allowDots ? givenKey.replace(/\.([^.[]+)/g, '[$1]') : givenKey;
2158
-
2159
- // The regex chunks
2160
-
2161
- var brackets = /(\[[^[\]]*])/;
2162
- var child = /(\[[^[\]]*])/g;
2163
-
2164
- // Get the parent
2165
-
2166
- var segment = options.depth > 0 && brackets.exec(key);
2167
- var parent = segment ? key.slice(0, segment.index) : key;
2168
-
2169
- // Stash the parent if it exists
2170
-
2171
- var keys = [];
2172
- if (parent) {
2173
- // If we aren't using plain objects, optionally prefix keys that would overwrite object prototype properties
2174
- if (!options.plainObjects && has$2.call(Object.prototype, parent)) {
2175
- if (!options.allowPrototypes) {
2176
- return;
2177
- }
2178
- }
2179
-
2180
- keys.push(parent);
2181
- }
2182
-
2183
- // Loop through children appending to the array until we hit depth
2184
-
2185
- var i = 0;
2186
- while (options.depth > 0 && (segment = child.exec(key)) !== null && i < options.depth) {
2187
- i += 1;
2188
- if (!options.plainObjects && has$2.call(Object.prototype, segment[1].slice(1, -1))) {
2189
- if (!options.allowPrototypes) {
2190
- return;
2191
- }
2192
- }
2193
- keys.push(segment[1]);
2194
- }
2195
-
2196
- // If there's a remainder, just add whatever is left
2197
-
2198
- if (segment) {
2199
- keys.push('[' + key.slice(segment.index) + ']');
2200
- }
2201
-
2202
- return parseObject(keys, val, options, valuesParsed);
2203
- };
2204
-
2205
- var normalizeParseOptions = function normalizeParseOptions(opts) {
2206
- if (!opts) {
2207
- return defaults$2;
2208
- }
2209
-
2210
- if (opts.decoder !== null && opts.decoder !== undefined && typeof opts.decoder !== 'function') {
2211
- throw new TypeError('Decoder has to be a function.');
2212
- }
2213
-
2214
- if (typeof opts.charset !== 'undefined' && opts.charset !== 'utf-8' && opts.charset !== 'iso-8859-1') {
2215
- throw new TypeError('The charset option must be either utf-8, iso-8859-1, or undefined');
2216
- }
2217
- var charset = typeof opts.charset === 'undefined' ? defaults$2.charset : opts.charset;
2218
-
2219
- return {
2220
- allowDots: typeof opts.allowDots === 'undefined' ? defaults$2.allowDots : !!opts.allowDots,
2221
- allowPrototypes: typeof opts.allowPrototypes === 'boolean' ? opts.allowPrototypes : defaults$2.allowPrototypes,
2222
- arrayLimit: typeof opts.arrayLimit === 'number' ? opts.arrayLimit : defaults$2.arrayLimit,
2223
- charset: charset,
2224
- charsetSentinel: typeof opts.charsetSentinel === 'boolean' ? opts.charsetSentinel : defaults$2.charsetSentinel,
2225
- comma: typeof opts.comma === 'boolean' ? opts.comma : defaults$2.comma,
2226
- decoder: typeof opts.decoder === 'function' ? opts.decoder : defaults$2.decoder,
2227
- delimiter: typeof opts.delimiter === 'string' || utils$1.isRegExp(opts.delimiter) ? opts.delimiter : defaults$2.delimiter,
2228
- // eslint-disable-next-line no-implicit-coercion, no-extra-parens
2229
- depth: (typeof opts.depth === 'number' || opts.depth === false) ? +opts.depth : defaults$2.depth,
2230
- ignoreQueryPrefix: opts.ignoreQueryPrefix === true,
2231
- interpretNumericEntities: typeof opts.interpretNumericEntities === 'boolean' ? opts.interpretNumericEntities : defaults$2.interpretNumericEntities,
2232
- parameterLimit: typeof opts.parameterLimit === 'number' ? opts.parameterLimit : defaults$2.parameterLimit,
2233
- parseArrays: opts.parseArrays !== false,
2234
- plainObjects: typeof opts.plainObjects === 'boolean' ? opts.plainObjects : defaults$2.plainObjects,
2235
- strictNullHandling: typeof opts.strictNullHandling === 'boolean' ? opts.strictNullHandling : defaults$2.strictNullHandling
2236
- };
2237
- };
2238
-
2239
- var parse = function (str, opts) {
2240
- var options = normalizeParseOptions(opts);
2241
-
2242
- if (str === '' || str === null || typeof str === 'undefined') {
2243
- return options.plainObjects ? Object.create(null) : {};
2244
- }
2245
-
2246
- var tempObj = typeof str === 'string' ? parseValues(str, options) : str;
2247
- var obj = options.plainObjects ? Object.create(null) : {};
2248
-
2249
- // Iterate over the keys and setup the new object
2250
-
2251
- var keys = Object.keys(tempObj);
2252
- for (var i = 0; i < keys.length; ++i) {
2253
- var key = keys[i];
2254
- var newObj = parseKeys(key, tempObj[key], options, typeof str === 'string');
2255
- obj = utils$1.merge(obj, newObj, options);
2256
- }
2257
-
2258
- return utils$1.compact(obj);
2259
- };
2260
-
2261
- var lib = {
2262
- formats: formats,
2263
- parse: parse,
2264
- stringify: stringify_1
2265
- };
2266
-
2267
- const appendToMap = (map, propName, value) => {
2268
- const items = map.get(propName);
2269
- if (!items) {
2270
- map.set(propName, [value]);
2271
- }
2272
- else if (!items.includes(value)) {
2273
- items.push(value);
2274
- }
2275
- };
2276
- const debounce = (fn, ms) => {
2277
- let timeoutId;
2278
- return (...args) => {
2279
- if (timeoutId) {
2280
- clearTimeout(timeoutId);
2281
- }
2282
- timeoutId = setTimeout(() => {
2283
- timeoutId = 0;
2284
- fn(...args);
2285
- }, ms);
2286
- };
2287
- };
2288
-
2289
- /**
2290
- * Check if a possible element isConnected.
2291
- * The property might not be there, so we check for it.
2292
- *
2293
- * We want it to return true if isConnected is not a property,
2294
- * otherwise we would remove these elements and would not update.
2295
- *
2296
- * Better leak in Edge than to be useless.
2297
- */
2298
- const isConnected = (maybeElement) => !('isConnected' in maybeElement) || maybeElement.isConnected;
2299
- const cleanupElements = debounce((map) => {
2300
- for (let key of map.keys()) {
2301
- map.set(key, map.get(key).filter(isConnected));
2302
- }
2303
- }, 2000);
2304
- const stencilSubscription = ({ on }) => {
2305
- const elmsToUpdate = new Map();
2306
- if (typeof getRenderingRef === 'function') {
2307
- // If we are not in a stencil project, we do nothing.
2308
- // This function is not really exported by @stencil/core.
2309
- on('dispose', () => {
2310
- elmsToUpdate.clear();
2311
- });
2312
- on('get', (propName) => {
2313
- const elm = getRenderingRef();
2314
- if (elm) {
2315
- appendToMap(elmsToUpdate, propName, elm);
2316
- }
2317
- });
2318
- on('set', (propName) => {
2319
- const elements = elmsToUpdate.get(propName);
2320
- if (elements) {
2321
- elmsToUpdate.set(propName, elements.filter(forceUpdate));
2322
- }
2323
- cleanupElements(elmsToUpdate);
2324
- });
2325
- on('reset', () => {
2326
- elmsToUpdate.forEach((elms) => elms.forEach(forceUpdate));
2327
- cleanupElements(elmsToUpdate);
2328
- });
2329
- }
2330
- };
2331
-
2332
- const createObservableMap = (defaultState, shouldUpdate = (a, b) => a !== b) => {
2333
- let states = new Map(Object.entries(defaultState !== null && defaultState !== void 0 ? defaultState : {}));
2334
- const handlers = {
2335
- dispose: [],
2336
- get: [],
2337
- set: [],
2338
- reset: [],
2339
- };
2340
- const reset = () => {
2341
- states = new Map(Object.entries(defaultState !== null && defaultState !== void 0 ? defaultState : {}));
2342
- handlers.reset.forEach((cb) => cb());
2343
- };
2344
- const dispose = () => {
2345
- // Call first dispose as resetting the state would
2346
- // cause less updates ;)
2347
- handlers.dispose.forEach((cb) => cb());
2348
- reset();
2349
- };
2350
- const get = (propName) => {
2351
- handlers.get.forEach((cb) => cb(propName));
2352
- return states.get(propName);
2353
- };
2354
- const set = (propName, value) => {
2355
- const oldValue = states.get(propName);
2356
- if (shouldUpdate(value, oldValue, propName)) {
2357
- states.set(propName, value);
2358
- handlers.set.forEach((cb) => cb(propName, value, oldValue));
2359
- }
2360
- };
2361
- const state = (typeof Proxy === 'undefined'
2362
- ? {}
2363
- : new Proxy(defaultState, {
2364
- get(_, propName) {
2365
- return get(propName);
2366
- },
2367
- ownKeys(_) {
2368
- return Array.from(states.keys());
2369
- },
2370
- getOwnPropertyDescriptor() {
2371
- return {
2372
- enumerable: true,
2373
- configurable: true,
2374
- };
2375
- },
2376
- has(_, propName) {
2377
- return states.has(propName);
2378
- },
2379
- set(_, propName, value) {
2380
- set(propName, value);
2381
- return true;
2382
- },
2383
- }));
2384
- const on = (eventName, callback) => {
2385
- handlers[eventName].push(callback);
2386
- return () => {
2387
- removeFromArray(handlers[eventName], callback);
2388
- };
2389
- };
2390
- const onChange = (propName, cb) => {
2391
- const unSet = on('set', (key, newValue) => {
2392
- if (key === propName) {
2393
- cb(newValue);
2394
- }
2395
- });
2396
- const unReset = on('reset', () => cb(defaultState[propName]));
2397
- return () => {
2398
- unSet();
2399
- unReset();
2400
- };
2401
- };
2402
- const use = (...subscriptions) => subscriptions.forEach((subscription) => {
2403
- if (subscription.set) {
2404
- on('set', subscription.set);
2405
- }
2406
- if (subscription.get) {
2407
- on('get', subscription.get);
2408
- }
2409
- if (subscription.reset) {
2410
- on('reset', subscription.reset);
2411
- }
2412
- });
2413
- return {
2414
- state,
2415
- get,
2416
- set,
2417
- on,
2418
- onChange,
2419
- use,
2420
- dispose,
2421
- reset,
2422
- };
2423
- };
2424
- const removeFromArray = (array, item) => {
2425
- const index = array.indexOf(item);
2426
- if (index >= 0) {
2427
- array[index] = array[array.length - 1];
2428
- array.length--;
2429
- }
2430
- };
2431
-
2432
- const createStore = (defaultState, shouldUpdate) => {
2433
- const map = createObservableMap(defaultState, shouldUpdate);
2434
- stencilSubscription(map);
2435
- return map;
2436
- };
2437
-
2438
- const { state, onChange, reset } = createStore({
2439
- toc: undefined,
2440
- });
2441
- const TocStore = { state, onChange, reset };
2442
-
2443
- class HttpService {
2444
- constructor() { }
2445
- static getInstance() {
2446
- if (!HttpService.instance) {
2447
- HttpService.instance = new HttpService();
2448
- }
2449
- return HttpService.instance;
2450
- }
2451
- static init() {
2452
- var sparkleConfig = EnvironmentConfigService.getInstance().get('sparkle');
2453
- this.http = axios$1.create({
2454
- baseURL: sparkleConfig.apiUrl,
2455
- headers: {
2456
- 'Content-Type': 'application/json'
2457
- },
2458
- timeout: 30000,
2459
- paramsSerializer: function (params) {
2460
- return lib.stringify(params, {
2461
- encode: false,
2462
- });
2463
- },
2464
- });
2465
- this.http.interceptors.request.use(function (config) {
2466
- if (!!sparkleConfig && !!sparkleConfig.auth && !!sparkleConfig.auth.getToken()) {
2467
- config.headers.common['Authorization'] = 'Bearer ' + sparkle.auth.getToken();
2468
- }
2469
- // //config.headers.common['.AspNetCore.Culture'] = sparkle.utils.getCookieValue('Sparkle.Localization.CultureName');
2470
- config.headers.common['Sparkle.CourseId'] = sparkleConfig.courseId;
2471
- console.log(TocStore.state.pageInfo);
2472
- if (TocStore.state.pageInfo) {
2473
- config.headers.common['Sparkle.CourseModuleId'] = TocStore.state.pageInfo.courseModuleId;
2474
- config.headers.common['Sparkle.SessionId'] = TocStore.state.pageInfo.sessionId;
2475
- config.headers.common['Sparkle.PageId'] = TocStore.state.pageInfo.pageId;
2476
- }
2477
- return config;
2478
- }, function (error) {
2479
- return Promise.reject(error);
2480
- });
2481
- this.http.interceptors.response.use(async (response) => {
2482
- if (response.data.Message) {
2483
- const toast = await toastController.create({
2484
- message: response.data.Message,
2485
- duration: 3000
2486
- });
2487
- toast.present();
2488
- }
2489
- return response.data.Failed ? null : response.data;
2490
- }, async (error) => {
2491
- if (error.response && error.response.data && error.response.data.ErrorMessage) {
2492
- // The request was made and the server responded with a status code
2493
- // that falls out of the range of 2xx
2494
- const toast = await toastController.create({
2495
- message: error.response.data.ErrorMessage,
2496
- duration: 3000
2497
- });
2498
- toast.present();
2499
- return Promise.reject(error);
2500
- }
2501
- else if (error.response && error.response.data && error.response.status == 400) {
2502
- // The request was made and the server responded with a status code
2503
- // that falls out of the range of 2xx
2504
- const toast = await toastController.create({
2505
- message: error.response.data.Message,
2506
- duration: 3000
2507
- });
2508
- toast.present();
2509
- return Promise.reject(error.response.data);
2510
- }
2511
- else if (error.response && error.response.data && error.response.data.Message) {
2512
- // The request was made and the server responded with a status code
2513
- // that falls out of the range of 2xx
2514
- const toast = await toastController.create({
2515
- message: error.response.data.Message,
2516
- duration: 3000
2517
- });
2518
- toast.present();
2519
- return Promise.reject(error);
2520
- }
2521
- else if (error.request) {
2522
- // The request was made but no response was received
2523
- // `error.request` is an instance of XMLHttpRequest in the browser and an instance of
2524
- // http.ClientRequest in node.js
2525
- console.log(error.request);
2526
- }
2527
- else {
2528
- const toast = await toastController.create({
2529
- message: "Unknown Error",
2530
- duration: 3000
2531
- });
2532
- toast.present();
2533
- }
2534
- setTimeout(() => { }, 1000);
2535
- return Promise.reject(error);
2536
- });
2537
- }
2538
- }
2539
-
2540
- const { state: state$1, onChange: onChange$1, reset: reset$1 } = createStore({
2541
- authUser: null,
2542
- bearer: 'Bearer ',
2543
- isAuthenticated: false,
2544
- loading: false
2545
- });
2546
- onChange$1('authUser', (authUser) => {
2547
- state$1.bearer = `Bearer ${authUser ? authUser.JWToken : ''}`;
2548
- state$1.isAuthenticated = authUser && !!authUser.Id;
2549
- });
2550
- const AuthStore = { state: state$1, onChange: onChange$1, reset: reset$1 };
2551
-
2552
- export { AuthStore as A, HttpService as H, TocStore as T, createStore as c };