@flarehr/apollo-super-selection 3.14.52544 → 3.17.52781

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 (281) hide show
  1. package/package.json +1 -1
  2. package/dist/lib/apollo-super-selection/apollo-super-selection.esm.js +0 -1
  3. package/dist/lib/apollo-super-selection/apollo-super-selection.js +0 -130
  4. package/dist/lib/apollo-super-selection/index.esm.js +0 -0
  5. package/dist/lib/apollo-super-selection/p-13573238.system.js +0 -15
  6. package/dist/lib/apollo-super-selection/p-27129f6d.system.js +0 -1
  7. package/dist/lib/apollo-super-selection/p-2bbd0732.system.entry.js +0 -1
  8. package/dist/lib/apollo-super-selection/p-2bd70644.system.entry.js +0 -1
  9. package/dist/lib/apollo-super-selection/p-30bebd30.entry.js +0 -1
  10. package/dist/lib/apollo-super-selection/p-31a3ef1a.entry.js +0 -14
  11. package/dist/lib/apollo-super-selection/p-342cee5a.js +0 -1
  12. package/dist/lib/apollo-super-selection/p-381262c1.system.js +0 -1
  13. package/dist/lib/apollo-super-selection/p-38f24f69.js +0 -1
  14. package/dist/lib/apollo-super-selection/p-48e99aba.system.js +0 -1
  15. package/dist/lib/apollo-super-selection/p-4ceefd14.system.entry.js +0 -1
  16. package/dist/lib/apollo-super-selection/p-50ea2036.system.js +0 -1
  17. package/dist/lib/apollo-super-selection/p-52cb55a8.system.entry.js +0 -1
  18. package/dist/lib/apollo-super-selection/p-55737760.entry.js +0 -1
  19. package/dist/lib/apollo-super-selection/p-59a986b0.js +0 -1
  20. package/dist/lib/apollo-super-selection/p-7b72a245.system.entry.js +0 -1
  21. package/dist/lib/apollo-super-selection/p-7dbe5a2f.system.js +0 -1
  22. package/dist/lib/apollo-super-selection/p-84240b0b.entry.js +0 -1
  23. package/dist/lib/apollo-super-selection/p-943b206b.entry.js +0 -1
  24. package/dist/lib/apollo-super-selection/p-9b5fb4bc.system.js +0 -1
  25. package/dist/lib/apollo-super-selection/p-cbe37145.js +0 -1
  26. package/dist/lib/apollo-super-selection/p-cc209002.system.entry.js +0 -1
  27. package/dist/lib/apollo-super-selection/p-cc9c37a4.entry.js +0 -1
  28. package/dist/lib/apollo-super-selection/p-dd3a95d5.system.entry.js +0 -69
  29. package/dist/lib/apollo-super-selection/p-df9ce4b7.js +0 -15
  30. package/dist/lib/apollo-super-selection/p-fbcce741.entry.js +0 -1
  31. package/dist/lib/cjs/active-router-08eabf9a.js +0 -75
  32. package/dist/lib/cjs/apollo-super-selection.cjs.js +0 -23
  33. package/dist/lib/cjs/app-globals-45007120.js +0 -25
  34. package/dist/lib/cjs/context-consumer.cjs.entry.js +0 -29
  35. package/dist/lib/cjs/datorama-akita-7f4b082a.js +0 -2704
  36. package/dist/lib/cjs/delay-81aff2f1.js +0 -955
  37. package/dist/lib/cjs/fl-button_43.cjs.entry.js +0 -16969
  38. package/dist/lib/cjs/fl-style-guide.cjs.entry.js +0 -90
  39. package/dist/lib/cjs/index-b2214bec.js +0 -1764
  40. package/dist/lib/cjs/index.cjs.js +0 -2
  41. package/dist/lib/cjs/loader.cjs.js +0 -25
  42. package/dist/lib/cjs/stencil-async-content.cjs.entry.js +0 -32
  43. package/dist/lib/cjs/stencil-route-title.cjs.entry.js +0 -32
  44. package/dist/lib/cjs/stencil-router-prompt.cjs.entry.js +0 -59
  45. package/dist/lib/cjs/stencil-router-redirect.cjs.entry.js +0 -32
  46. package/dist/lib/collection/collection-manifest.json +0 -125
  47. package/dist/lib/collection/components/app-host/loading-page.js +0 -9
  48. package/dist/lib/collection/components/app-host/services/app-configuration.query.js +0 -18
  49. package/dist/lib/collection/components/app-host/services/app-configuration.service.js +0 -25
  50. package/dist/lib/collection/components/app-host/services/appinsights.service.js +0 -43
  51. package/dist/lib/collection/components/app-host/services/authentication.query.js +0 -21
  52. package/dist/lib/collection/components/app-host/services/authentication.service.js +0 -50
  53. package/dist/lib/collection/components/app-host/services/interop/host-interop.service.js +0 -31
  54. package/dist/lib/collection/components/app-host/services/interop/iframe-interop.service.js +0 -30
  55. package/dist/lib/collection/components/app-host/services/interop/react-native-interop.service.js +0 -20
  56. package/dist/lib/collection/components/app-host/services/interop.query.js +0 -26
  57. package/dist/lib/collection/components/app-host/services/session.store.js +0 -37
  58. package/dist/lib/collection/components/app-host/super-selection-app-host.css +0 -28
  59. package/dist/lib/collection/components/app-host/super-selection-app-host.js +0 -92
  60. package/dist/lib/collection/components/super-selection-app/api/api-client.js +0 -14
  61. package/dist/lib/collection/components/super-selection-app/api/event-tracking.api.js +0 -9
  62. package/dist/lib/collection/components/super-selection-app/api/super-selection-events.model.js +0 -1
  63. package/dist/lib/collection/components/super-selection-app/api/super-selection.api.dto.js +0 -1
  64. package/dist/lib/collection/components/super-selection-app/api/super-selection.api.js +0 -30
  65. package/dist/lib/collection/components/super-selection-app/app-state-pages/success.js +0 -31
  66. package/dist/lib/collection/components/super-selection-app/footer-section/footer-section.css +0 -11
  67. package/dist/lib/collection/components/super-selection-app/footer-section/footer-section.js +0 -29
  68. package/dist/lib/collection/components/super-selection-app/funds/constants.js +0 -13
  69. package/dist/lib/collection/components/super-selection-app/funds/custom-fund/api/custom-fund-choice.api.dto.js +0 -1
  70. package/dist/lib/collection/components/super-selection-app/funds/custom-fund/api/custom-fund-choice.api.js +0 -31
  71. package/dist/lib/collection/components/super-selection-app/funds/custom-fund/custom-fund.js +0 -68
  72. package/dist/lib/collection/components/super-selection-app/funds/custom-fund/custom-fund.store.js +0 -53
  73. package/dist/lib/collection/components/super-selection-app/funds/custom-fund/default-fund/default-fund.js +0 -108
  74. package/dist/lib/collection/components/super-selection-app/funds/custom-fund/my-own-fund/my-own-fund-inputs.js +0 -93
  75. package/dist/lib/collection/components/super-selection-app/funds/custom-fund/my-own-fund/my-own-fund.js +0 -103
  76. package/dist/lib/collection/components/super-selection-app/funds/custom-fund/self-managed-fund/bankBsbNumbers.js +0 -111
  77. package/dist/lib/collection/components/super-selection-app/funds/custom-fund/self-managed-fund/self-managed-fund-inputs.js +0 -153
  78. package/dist/lib/collection/components/super-selection-app/funds/custom-fund/self-managed-fund/self-managed-fund.form.js +0 -1
  79. package/dist/lib/collection/components/super-selection-app/funds/custom-fund/self-managed-fund/self-managed-fund.js +0 -96
  80. package/dist/lib/collection/components/super-selection-app/funds/qsuper/api/qsuper-choice.api.dto.js +0 -1
  81. package/dist/lib/collection/components/super-selection-app/funds/qsuper/api/qsuper-choice.api.js +0 -13
  82. package/dist/lib/collection/components/super-selection-app/funds/qsuper/helpers/confirmCheck.js +0 -37
  83. package/dist/lib/collection/components/super-selection-app/funds/qsuper/helpers/continueCheck.js +0 -13
  84. package/dist/lib/collection/components/super-selection-app/funds/qsuper/helpers/getNextRoute.js +0 -89
  85. package/dist/lib/collection/components/super-selection-app/funds/qsuper/helpers/resetState.js +0 -31
  86. package/dist/lib/collection/components/super-selection-app/funds/qsuper/qsuper-confirm-header.js +0 -38
  87. package/dist/lib/collection/components/super-selection-app/funds/qsuper/qsuper-confirm-selection/qsuper-confirm-selection.js +0 -63
  88. package/dist/lib/collection/components/super-selection-app/funds/qsuper/qsuper-confirmation.css +0 -0
  89. package/dist/lib/collection/components/super-selection-app/funds/qsuper/qsuper-consent/qsuper-consent.js +0 -95
  90. package/dist/lib/collection/components/super-selection-app/funds/qsuper/qsuper-insurance-opt-in.js +0 -99
  91. package/dist/lib/collection/components/super-selection-app/funds/qsuper/qsuper-insurance-questions.js +0 -18
  92. package/dist/lib/collection/components/super-selection-app/funds/qsuper/qsuper-layout.js +0 -95
  93. package/dist/lib/collection/components/super-selection-app/funds/qsuper/qsuper.css +0 -50
  94. package/dist/lib/collection/components/super-selection-app/funds/qsuper/questions/question1/question1.js +0 -10
  95. package/dist/lib/collection/components/super-selection-app/funds/qsuper/questions/question2/question2.js +0 -10
  96. package/dist/lib/collection/components/super-selection-app/funds/qsuper/questions/question3/question3.js +0 -10
  97. package/dist/lib/collection/components/super-selection-app/funds/qsuper/questions/question4/question4.js +0 -10
  98. package/dist/lib/collection/components/super-selection-app/funds/qsuper/questions/question5/question5.js +0 -10
  99. package/dist/lib/collection/components/super-selection-app/funds/qsuper/questions/question6/question6.js +0 -10
  100. package/dist/lib/collection/components/super-selection-app/funds/qsuper/questions/question7/question7.js +0 -10
  101. package/dist/lib/collection/components/super-selection-app/funds/qsuper/questions/question8/question8.js +0 -10
  102. package/dist/lib/collection/components/super-selection-app/funds/qsuper/questions/yes-no-buttons/qsuper-question-yes-no-buttons.js +0 -66
  103. package/dist/lib/collection/components/super-selection-app/funds/qsuper/services/qsuper.store.js +0 -64
  104. package/dist/lib/collection/components/super-selection-app/funds/slate-super/api/slate-choice.api.dto.js +0 -1
  105. package/dist/lib/collection/components/super-selection-app/funds/slate-super/api/slate-choice.api.js +0 -13
  106. package/dist/lib/collection/components/super-selection-app/funds/slate-super/services/slate-iframe-builder.js +0 -127
  107. package/dist/lib/collection/components/super-selection-app/funds/slate-super/slate-fund.store.js +0 -9
  108. package/dist/lib/collection/components/super-selection-app/funds/slate-super/slate-join-page.js +0 -35
  109. package/dist/lib/collection/components/super-selection-app/funds/slate-super/slate-standard-choice-page.js +0 -67
  110. package/dist/lib/collection/components/super-selection-app/funds/slate-super/slatesuper-header.css +0 -0
  111. package/dist/lib/collection/components/super-selection-app/funds/slate-super/slatesuper-header.js +0 -19
  112. package/dist/lib/collection/components/super-selection-app/notifications-section/notifications-section.js +0 -25
  113. package/dist/lib/collection/components/super-selection-app/services/australian-fund-lookup.service.js +0 -22
  114. package/dist/lib/collection/components/super-selection-app/services/event-tracking.service.js +0 -71
  115. package/dist/lib/collection/components/super-selection-app/services/navigation.service.js +0 -22
  116. package/dist/lib/collection/components/super-selection-app/services/notifications.service.js +0 -37
  117. package/dist/lib/collection/components/super-selection-app/services/notifications.store.js +0 -3
  118. package/dist/lib/collection/components/super-selection-app/services/selected-super-choice-info.service.js +0 -53
  119. package/dist/lib/collection/components/super-selection-app/services/super-selection-app.routes.js +0 -42
  120. package/dist/lib/collection/components/super-selection-app/services/super-selection-app.service.js +0 -73
  121. package/dist/lib/collection/components/super-selection-app/services/super-selection.store.js +0 -11
  122. package/dist/lib/collection/components/super-selection-app/standard-choice/api/standard-choice.model.js +0 -1
  123. package/dist/lib/collection/components/super-selection-app/standard-choice/standard-choice-form.js +0 -49
  124. package/dist/lib/collection/components/super-selection-app/super-choice-page/selected-super-choice-section/selected-super-choice-section.css +0 -18
  125. package/dist/lib/collection/components/super-selection-app/super-choice-page/selected-super-choice-section/selected-super-choice-section.js +0 -53
  126. package/dist/lib/collection/components/super-selection-app/super-choice-page/super-choice-item.js +0 -216
  127. package/dist/lib/collection/components/super-selection-app/super-choice-page/super-choice-page.css +0 -53
  128. package/dist/lib/collection/components/super-selection-app/super-choice-page/super-choice-page.js +0 -152
  129. package/dist/lib/collection/components/super-selection-app/super-selection-app.css +0 -15
  130. package/dist/lib/collection/components/super-selection-app/super-selection-app.js +0 -229
  131. package/dist/lib/collection/global/init-host.js +0 -22
  132. package/dist/lib/collection/global/main.dev.js +0 -26
  133. package/dist/lib/collection/global/main.js +0 -11
  134. package/dist/lib/collection/global/stencil-router-workaround.js +0 -12
  135. package/dist/lib/collection/index.js +0 -2
  136. package/dist/lib/collection/utils/config.js +0 -2
  137. package/dist/lib/collection/utils/gtm.js +0 -5
  138. package/dist/lib/collection/utils/iframe.js +0 -33
  139. package/dist/lib/collection/utils/index.js +0 -8
  140. package/dist/lib/collection/utils/lazy.js +0 -29
  141. package/dist/lib/collection/utils/storage.js +0 -5
  142. package/dist/lib/esm/active-router-09eb3641.js +0 -73
  143. package/dist/lib/esm/apollo-super-selection.js +0 -21
  144. package/dist/lib/esm/app-globals-7ac1ffba.js +0 -23
  145. package/dist/lib/esm/context-consumer.entry.js +0 -25
  146. package/dist/lib/esm/datorama-akita-79ce4385.js +0 -2692
  147. package/dist/lib/esm/delay-c0555599.js +0 -935
  148. package/dist/lib/esm/fl-button_43.entry.js +0 -16923
  149. package/dist/lib/esm/fl-style-guide.entry.js +0 -86
  150. package/dist/lib/esm/index-227ab0f1.js +0 -1731
  151. package/dist/lib/esm/index.js +0 -1
  152. package/dist/lib/esm/loader.js +0 -21
  153. package/dist/lib/esm/polyfills/core-js.js +0 -11
  154. package/dist/lib/esm/polyfills/css-shim.js +0 -1
  155. package/dist/lib/esm/polyfills/dom.js +0 -79
  156. package/dist/lib/esm/polyfills/es5-html-element.js +0 -1
  157. package/dist/lib/esm/polyfills/index.js +0 -34
  158. package/dist/lib/esm/polyfills/system.js +0 -6
  159. package/dist/lib/esm/stencil-async-content.entry.js +0 -28
  160. package/dist/lib/esm/stencil-route-title.entry.js +0 -28
  161. package/dist/lib/esm/stencil-router-prompt.entry.js +0 -55
  162. package/dist/lib/esm/stencil-router-redirect.entry.js +0 -28
  163. package/dist/lib/esm-es5/active-router-09eb3641.js +0 -1
  164. package/dist/lib/esm-es5/apollo-super-selection.js +0 -1
  165. package/dist/lib/esm-es5/app-globals-7ac1ffba.js +0 -1
  166. package/dist/lib/esm-es5/context-consumer.entry.js +0 -1
  167. package/dist/lib/esm-es5/datorama-akita-79ce4385.js +0 -15
  168. package/dist/lib/esm-es5/delay-c0555599.js +0 -1
  169. package/dist/lib/esm-es5/fl-button_43.entry.js +0 -69
  170. package/dist/lib/esm-es5/fl-style-guide.entry.js +0 -1
  171. package/dist/lib/esm-es5/index-227ab0f1.js +0 -1
  172. package/dist/lib/esm-es5/index.js +0 -0
  173. package/dist/lib/esm-es5/loader.js +0 -1
  174. package/dist/lib/esm-es5/stencil-async-content.entry.js +0 -1
  175. package/dist/lib/esm-es5/stencil-route-title.entry.js +0 -1
  176. package/dist/lib/esm-es5/stencil-router-prompt.entry.js +0 -1
  177. package/dist/lib/esm-es5/stencil-router-redirect.entry.js +0 -1
  178. package/dist/lib/index.cjs.js +0 -1
  179. package/dist/lib/index.js +0 -1
  180. package/dist/lib/loader/cdn.js +0 -3
  181. package/dist/lib/loader/index.cjs.js +0 -3
  182. package/dist/lib/loader/index.d.ts +0 -13
  183. package/dist/lib/loader/index.es2017.js +0 -3
  184. package/dist/lib/loader/index.js +0 -4
  185. package/dist/lib/loader/package.json +0 -10
  186. package/dist/lib/node_modules/@flarehr/beacon/dist/collection/components/button/button.css +0 -45
  187. package/dist/lib/node_modules/@flarehr/beacon/dist/collection/components/dropdown/dropdown.css +0 -9
  188. package/dist/lib/node_modules/@flarehr/beacon/dist/collection/components/dropdown-async/dropdown-async.css +0 -9
  189. package/dist/lib/node_modules/@flarehr/beacon/dist/collection/components/loading-indicator/loading-indicator.css +0 -141
  190. package/dist/lib/node_modules/@flarehr/beacon/dist/collection/components/promise-button/promise-button.css +0 -5
  191. package/dist/lib/node_modules/@flarehr/beacon/dist/collection/components/style-guide/style-guide.css +0 -0
  192. package/dist/lib/node_modules/@stencil/router/dist/collection/components/route/route.css +0 -3
  193. package/dist/lib/types/components/app-host/loading-page.d.ts +0 -3
  194. package/dist/lib/types/components/app-host/services/app-configuration.query.d.ts +0 -11
  195. package/dist/lib/types/components/app-host/services/app-configuration.service.d.ts +0 -9
  196. package/dist/lib/types/components/app-host/services/appinsights.service.d.ts +0 -14
  197. package/dist/lib/types/components/app-host/services/authentication.query.d.ts +0 -13
  198. package/dist/lib/types/components/app-host/services/authentication.service.d.ts +0 -9
  199. package/dist/lib/types/components/app-host/services/interop/host-interop.service.d.ts +0 -7
  200. package/dist/lib/types/components/app-host/services/interop/iframe-interop.service.d.ts +0 -5
  201. package/dist/lib/types/components/app-host/services/interop/react-native-interop.service.d.ts +0 -7
  202. package/dist/lib/types/components/app-host/services/interop.query.d.ts +0 -11
  203. package/dist/lib/types/components/app-host/services/session.store.d.ts +0 -30
  204. package/dist/lib/types/components/app-host/super-selection-app-host.d.ts +0 -17
  205. package/dist/lib/types/components/super-selection-app/api/api-client.d.ts +0 -2
  206. package/dist/lib/types/components/super-selection-app/api/event-tracking.api.d.ts +0 -6
  207. package/dist/lib/types/components/super-selection-app/api/super-selection-events.model.d.ts +0 -73
  208. package/dist/lib/types/components/super-selection-app/api/super-selection.api.d.ts +0 -16
  209. package/dist/lib/types/components/super-selection-app/api/super-selection.api.dto.d.ts +0 -81
  210. package/dist/lib/types/components/super-selection-app/app-state-pages/success.d.ts +0 -4
  211. package/dist/lib/types/components/super-selection-app/footer-section/footer-section.d.ts +0 -4
  212. package/dist/lib/types/components/super-selection-app/funds/constants.d.ts +0 -13
  213. package/dist/lib/types/components/super-selection-app/funds/custom-fund/api/custom-fund-choice.api.d.ts +0 -8
  214. package/dist/lib/types/components/super-selection-app/funds/custom-fund/api/custom-fund-choice.api.dto.d.ts +0 -28
  215. package/dist/lib/types/components/super-selection-app/funds/custom-fund/custom-fund.d.ts +0 -9
  216. package/dist/lib/types/components/super-selection-app/funds/custom-fund/custom-fund.store.d.ts +0 -30
  217. package/dist/lib/types/components/super-selection-app/funds/custom-fund/default-fund/default-fund.d.ts +0 -15
  218. package/dist/lib/types/components/super-selection-app/funds/custom-fund/my-own-fund/my-own-fund-inputs.d.ts +0 -12
  219. package/dist/lib/types/components/super-selection-app/funds/custom-fund/my-own-fund/my-own-fund.d.ts +0 -12
  220. package/dist/lib/types/components/super-selection-app/funds/custom-fund/self-managed-fund/bankBsbNumbers.d.ts +0 -112
  221. package/dist/lib/types/components/super-selection-app/funds/custom-fund/self-managed-fund/self-managed-fund-inputs.d.ts +0 -15
  222. package/dist/lib/types/components/super-selection-app/funds/custom-fund/self-managed-fund/self-managed-fund.d.ts +0 -10
  223. package/dist/lib/types/components/super-selection-app/funds/custom-fund/self-managed-fund/self-managed-fund.form.d.ts +0 -14
  224. package/dist/lib/types/components/super-selection-app/funds/qsuper/api/qsuper-choice.api.d.ts +0 -6
  225. package/dist/lib/types/components/super-selection-app/funds/qsuper/api/qsuper-choice.api.dto.d.ts +0 -21
  226. package/dist/lib/types/components/super-selection-app/funds/qsuper/helpers/confirmCheck.d.ts +0 -1
  227. package/dist/lib/types/components/super-selection-app/funds/qsuper/helpers/continueCheck.d.ts +0 -1
  228. package/dist/lib/types/components/super-selection-app/funds/qsuper/helpers/getNextRoute.d.ts +0 -2
  229. package/dist/lib/types/components/super-selection-app/funds/qsuper/helpers/resetState.d.ts +0 -1
  230. package/dist/lib/types/components/super-selection-app/funds/qsuper/qsuper-confirm-header.d.ts +0 -5
  231. package/dist/lib/types/components/super-selection-app/funds/qsuper/qsuper-confirm-selection/qsuper-confirm-selection.d.ts +0 -6
  232. package/dist/lib/types/components/super-selection-app/funds/qsuper/qsuper-consent/qsuper-consent.d.ts +0 -7
  233. package/dist/lib/types/components/super-selection-app/funds/qsuper/qsuper-insurance-opt-in.d.ts +0 -12
  234. package/dist/lib/types/components/super-selection-app/funds/qsuper/qsuper-insurance-questions.d.ts +0 -3
  235. package/dist/lib/types/components/super-selection-app/funds/qsuper/qsuper-layout.d.ts +0 -11
  236. package/dist/lib/types/components/super-selection-app/funds/qsuper/questions/question1/question1.d.ts +0 -3
  237. package/dist/lib/types/components/super-selection-app/funds/qsuper/questions/question2/question2.d.ts +0 -3
  238. package/dist/lib/types/components/super-selection-app/funds/qsuper/questions/question3/question3.d.ts +0 -3
  239. package/dist/lib/types/components/super-selection-app/funds/qsuper/questions/question4/question4.d.ts +0 -3
  240. package/dist/lib/types/components/super-selection-app/funds/qsuper/questions/question5/question5.d.ts +0 -3
  241. package/dist/lib/types/components/super-selection-app/funds/qsuper/questions/question6/question6.d.ts +0 -3
  242. package/dist/lib/types/components/super-selection-app/funds/qsuper/questions/question7/question7.d.ts +0 -3
  243. package/dist/lib/types/components/super-selection-app/funds/qsuper/questions/question8/question8.d.ts +0 -3
  244. package/dist/lib/types/components/super-selection-app/funds/qsuper/questions/yes-no-buttons/qsuper-question-yes-no-buttons.d.ts +0 -6
  245. package/dist/lib/types/components/super-selection-app/funds/qsuper/services/qsuper.store.d.ts +0 -58
  246. package/dist/lib/types/components/super-selection-app/funds/slate-super/api/slate-choice.api.d.ts +0 -6
  247. package/dist/lib/types/components/super-selection-app/funds/slate-super/api/slate-choice.api.dto.d.ts +0 -4
  248. package/dist/lib/types/components/super-selection-app/funds/slate-super/services/slate-iframe-builder.d.ts +0 -13
  249. package/dist/lib/types/components/super-selection-app/funds/slate-super/slate-fund.store.d.ts +0 -7
  250. package/dist/lib/types/components/super-selection-app/funds/slate-super/slate-join-page.d.ts +0 -7
  251. package/dist/lib/types/components/super-selection-app/funds/slate-super/slate-standard-choice-page.d.ts +0 -8
  252. package/dist/lib/types/components/super-selection-app/funds/slate-super/slatesuper-header.d.ts +0 -3
  253. package/dist/lib/types/components/super-selection-app/notifications-section/notifications-section.d.ts +0 -5
  254. package/dist/lib/types/components/super-selection-app/services/australian-fund-lookup.service.d.ts +0 -8
  255. package/dist/lib/types/components/super-selection-app/services/event-tracking.service.d.ts +0 -17
  256. package/dist/lib/types/components/super-selection-app/services/navigation.service.d.ts +0 -9
  257. package/dist/lib/types/components/super-selection-app/services/notifications.service.d.ts +0 -15
  258. package/dist/lib/types/components/super-selection-app/services/notifications.store.d.ts +0 -14
  259. package/dist/lib/types/components/super-selection-app/services/selected-super-choice-info.service.d.ts +0 -18
  260. package/dist/lib/types/components/super-selection-app/services/super-selection-app.routes.d.ts +0 -21
  261. package/dist/lib/types/components/super-selection-app/services/super-selection-app.service.d.ts +0 -24
  262. package/dist/lib/types/components/super-selection-app/services/super-selection.store.d.ts +0 -13
  263. package/dist/lib/types/components/super-selection-app/standard-choice/api/standard-choice.model.d.ts +0 -3
  264. package/dist/lib/types/components/super-selection-app/standard-choice/standard-choice-form.d.ts +0 -7
  265. package/dist/lib/types/components/super-selection-app/super-choice-page/selected-super-choice-section/selected-super-choice-section.d.ts +0 -5
  266. package/dist/lib/types/components/super-selection-app/super-choice-page/super-choice-item.d.ts +0 -17
  267. package/dist/lib/types/components/super-selection-app/super-choice-page/super-choice-page.d.ts +0 -13
  268. package/dist/lib/types/components/super-selection-app/super-selection-app.d.ts +0 -26
  269. package/dist/lib/types/components.d.ts +0 -532
  270. package/dist/lib/types/global/init-host.d.ts +0 -1
  271. package/dist/lib/types/global/main.d.ts +0 -1
  272. package/dist/lib/types/global/main.dev.d.ts +0 -1
  273. package/dist/lib/types/global/stencil-router-workaround.d.ts +0 -1
  274. package/dist/lib/types/index.d.ts +0 -2
  275. package/dist/lib/types/stencil-public-runtime.d.ts +0 -1555
  276. package/dist/lib/types/utils/config.d.ts +0 -2
  277. package/dist/lib/types/utils/gtm.d.ts +0 -7
  278. package/dist/lib/types/utils/iframe.d.ts +0 -13
  279. package/dist/lib/types/utils/index.d.ts +0 -3
  280. package/dist/lib/types/utils/lazy.d.ts +0 -12
  281. package/dist/lib/types/utils/storage.d.ts +0 -4
@@ -1,2 +0,0 @@
1
- 'use strict';
2
-
@@ -1,25 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- const index = require('./index-b2214bec.js');
6
- require('./datorama-akita-7f4b082a.js');
7
- require('./delay-81aff2f1.js');
8
- const appGlobals = require('./app-globals-45007120.js');
9
-
10
- /*
11
- Stencil Client Patch Esm v2.3.0 | MIT Licensed | https://stenciljs.com
12
- */
13
- const patchEsm = () => {
14
- return index.promiseResolve();
15
- };
16
-
17
- const defineCustomElements = (win, options) => {
18
- if (typeof window === 'undefined') return Promise.resolve();
19
- return patchEsm().then(() => {
20
- appGlobals.globalScripts();
21
- return index.bootstrapLazy([["fl-style-guide.cjs",[[1,"fl-style-guide",{"themeCssUrl":[1,"theme-css-url"]}]]],["context-consumer.cjs",[[0,"context-consumer",{"context":[16],"renderer":[16],"subscribe":[16],"unsubscribe":[32]}]]],["stencil-async-content.cjs",[[0,"stencil-async-content",{"documentLocation":[1,"document-location"],"content":[32]}]]],["stencil-route-title.cjs",[[0,"stencil-route-title",{"titleSuffix":[1,"title-suffix"],"pageTitle":[1,"page-title"]}]]],["stencil-router-prompt.cjs",[[0,"stencil-router-prompt",{"when":[4],"message":[1],"history":[16],"unblock":[32]}]]],["stencil-router-redirect.cjs",[[0,"stencil-router-redirect",{"history":[16],"root":[1],"url":[1]}]]],["fl-button_43.cjs",[[0,"sss-my-own-fund",{"history":[16],"formState":[32],"isNotAllInformationProvidedMessageVisible":[32]}],[0,"sss-qsuper-question-1"],[0,"sss-qsuper-question-2"],[0,"sss-qsuper-question-3"],[0,"sss-qsuper-question-4"],[0,"sss-qsuper-question-5"],[0,"sss-qsuper-question-6"],[0,"sss-qsuper-question-7"],[0,"sss-qsuper-question-8"],[0,"sss-self-managed-fund",{"history":[16],"formState":[32]}],[0,"sss-default-fund",{"history":[16],"formState":[32],"defaultFundProductName":[32]}],[0,"sss-qsuper-insurance-opt-in",{"insuranceChosen":[32]}],[0,"sss-qsuper-join"],[0,"sss-slate-standard-choice-page",{"history":[16],"formState":[32]}],[1,"super-selection-app-host",{"sessionState":[32],"jwt":[32],"appConfiguration":[32],"areStylesLoaded":[32]}],[0,"sss-qsuper-consent"],[0,"sss-super-choice-page",{"history":[16],"promotedFunds":[32],"chosenFund":[32]}],[0,"sss-success"],[0,"sss-slate-join-page",{"history":[16]}],[0,"super-selection-app",{"accessToken":[1,"access-token"],"backendUrl":[1,"backend-url"],"appBaseUrl":[1,"app-base-url"],"history":[16],"location":[16],"isAppInitialised":[32]}],[0,"sss-my-own-fund-inputs",{"myOwnFundForm":[16],"selectedOption":[32]}],[0,"sss-self-managed-fund-inputs",{"fundForm":[16],"currentBank":[32]}],[0,"sss-loading-page"],[0,"sss-super-choice-item",{"heading":[1],"isSelected":[4,"is-selected"],"usi":[1],"name":[1],"logo":[1],"pdsLink":[1,"pds-link"],"callToAction":[1,"call-to-action"],"features":[1],"history":[16]}],[0,"sss-selected-super-choice-section",{"fundType":[1,"fund-type"],"fundName":[1,"fund-name"]}],[0,"sss-slatesuper-header"],[0,"sss-footer-section"],[4,"stencil-route-link",{"url":[1],"urlMatch":[1,"url-match"],"activeClass":[1,"active-class"],"exact":[4],"strict":[4],"custom":[1],"anchorClass":[1,"anchor-class"],"anchorRole":[1,"anchor-role"],"anchorTitle":[1,"anchor-title"],"anchorTabIndex":[1,"anchor-tab-index"],"anchorId":[1,"anchor-id"],"history":[16],"location":[16],"root":[1],"ariaHaspopup":[1,"aria-haspopup"],"ariaPosinset":[1,"aria-posinset"],"ariaSetsize":[2,"aria-setsize"],"ariaLabel":[1,"aria-label"],"match":[32]}],[4,"stencil-route-switch",{"group":[513],"scrollTopOffset":[2,"scroll-top-offset"],"location":[16],"routeViewsUpdated":[16]}],[4,"stencil-router",{"root":[1],"historyType":[1,"history-type"],"titleSuffix":[1,"title-suffix"],"scrollTopOffset":[2,"scroll-top-offset"],"location":[32],"history":[32]}],[4,"sss-custom-fund",{"history":[16],"currentCustomFund":[32],"fundOptionsList":[32]}],[0,"fl-dropdown-async",{"placeholder":[1],"searchFunction":[16],"value":[16],"required":[4],"requiredValidationMessage":[1,"required-validation-message"],"disabled":[4],"minSearchStringLength":[2,"min-search-string-length"],"searchState":[32],"inputValue":[32],"isDropdownVisible":[32],"filteredOptions":[32],"highlightedOptionIndex":[32],"selectedOption":[32]},[[2,"focus","handleFocus"],[2,"blur","handleBlur"],[2,"keydown","handleKeyDown"]]],[0,"sss-standard-choice-form",{"standardChoiceFormSignature":[32]}],[0,"fl-dropdown",{"placeholder":[1],"options":[16],"value":[16],"required":[4],"requiredValidationMessage":[1,"required-validation-message"],"disabled":[4],"inputValue":[32],"isDropdownVisible":[32],"filteredOptions":[32],"highlightedOptionIndex":[32],"selectedOption":[32]},[[2,"focus","handleFocus"],[2,"blur","handleBlur"],[2,"keydown","handleKeyDown"]]],[4,"sss-qsuper-insurance-questions"],[0,"sss-qsuper-question-yes-no-buttons",{"history":[16]}],[0,"sss-qsuper-confirm-header"],[4,"sss-qsuper-layout",{"history":[16]}],[0,"sss-notifications-section"],[4,"fl-promise-button",{"isBlockElement":[4,"is-block-element"],"isRounded":[4,"is-rounded"],"disabled":[4],"variant":[1],"promiseFn":[16],"state":[32]}],[4,"fl-button",{"isBlockElement":[4,"is-block-element"],"disabled":[4],"variant":[1]}],[0,"fl-loading-indicator",{"theme":[1]}],[0,"stencil-route",{"group":[513],"componentUpdated":[16],"match":[1040],"url":[1],"component":[1],"componentProps":[16],"exact":[4],"routeRender":[16],"scrollTopOffset":[2,"scroll-top-offset"],"routeViewsUpdated":[16],"location":[16],"history":[16],"historyType":[1,"history-type"]}]]]], options);
22
- });
23
- };
24
-
25
- exports.defineCustomElements = defineCustomElements;
@@ -1,32 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- const index = require('./index-b2214bec.js');
6
-
7
- const AsyncContent = class {
8
- constructor(hostRef) {
9
- index.registerInstance(this, hostRef);
10
- this.content = '';
11
- }
12
- componentWillLoad() {
13
- if (this.documentLocation != null) {
14
- return this.fetchNewContent(this.documentLocation);
15
- }
16
- }
17
- fetchNewContent(newDocumentLocation) {
18
- return fetch(newDocumentLocation)
19
- .then(response => response.text())
20
- .then(data => {
21
- this.content = data;
22
- });
23
- }
24
- render() {
25
- return (index.h("div", { innerHTML: this.content }));
26
- }
27
- static get watchers() { return {
28
- "documentLocation": ["fetchNewContent"]
29
- }; }
30
- };
31
-
32
- exports.stencil_async_content = AsyncContent;
@@ -1,32 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- const index = require('./index-b2214bec.js');
6
- const activeRouter = require('./active-router-08eabf9a.js');
7
-
8
- const RouteTitle = class {
9
- constructor(hostRef) {
10
- index.registerInstance(this, hostRef);
11
- this.titleSuffix = '';
12
- this.pageTitle = '';
13
- }
14
- updateDocumentTitle() {
15
- const el = this.el;
16
- if (el.ownerDocument) {
17
- el.ownerDocument.title = `${this.pageTitle}${this.titleSuffix || ''}`;
18
- }
19
- }
20
- componentWillLoad() {
21
- this.updateDocumentTitle();
22
- }
23
- get el() { return index.getElement(this); }
24
- static get watchers() { return {
25
- "pageTitle": ["updateDocumentTitle"]
26
- }; }
27
- };
28
- activeRouter.ActiveRouter.injectProps(RouteTitle, [
29
- 'titleSuffix',
30
- ]);
31
-
32
- exports.stencil_route_title = RouteTitle;
@@ -1,59 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- const index = require('./index-b2214bec.js');
6
- const activeRouter = require('./active-router-08eabf9a.js');
7
-
8
- const StencilRouterPrompt = class {
9
- constructor(hostRef) {
10
- index.registerInstance(this, hostRef);
11
- this.when = true;
12
- this.message = '';
13
- }
14
- enable(message) {
15
- if (this.unblock) {
16
- this.unblock();
17
- }
18
- if (this.history) {
19
- this.unblock = this.history.block(message);
20
- }
21
- }
22
- disable() {
23
- if (this.unblock) {
24
- this.unblock();
25
- this.unblock = undefined;
26
- }
27
- }
28
- componentWillLoad() {
29
- if (this.when) {
30
- this.enable(this.message);
31
- }
32
- }
33
- updateMessage(newMessage, prevMessage) {
34
- if (this.when) {
35
- if (!this.when || prevMessage !== newMessage) {
36
- this.enable(this.message);
37
- }
38
- }
39
- else {
40
- this.disable();
41
- }
42
- }
43
- componentDidUnload() {
44
- this.disable();
45
- }
46
- render() {
47
- return null;
48
- }
49
- get el() { return index.getElement(this); }
50
- static get watchers() { return {
51
- "message": ["updateMessage"],
52
- "when": ["updateMessage"]
53
- }; }
54
- };
55
- activeRouter.ActiveRouter.injectProps(StencilRouterPrompt, [
56
- 'history',
57
- ]);
58
-
59
- exports.stencil_router_prompt = StencilRouterPrompt;
@@ -1,32 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- const index = require('./index-b2214bec.js');
6
- const activeRouter = require('./active-router-08eabf9a.js');
7
-
8
- // Get the URL for this route link without the root from the router
9
- const getUrl = (url, root) => {
10
- // Don't allow double slashes
11
- if (url.charAt(0) == '/' && root.charAt(root.length - 1) == '/') {
12
- return root.slice(0, root.length - 1) + url;
13
- }
14
- return root + url;
15
- };
16
- const Redirect = class {
17
- constructor(hostRef) {
18
- index.registerInstance(this, hostRef);
19
- }
20
- componentWillLoad() {
21
- if (this.history && this.root && this.url) {
22
- return this.history.replace(getUrl(this.url, this.root));
23
- }
24
- }
25
- get el() { return index.getElement(this); }
26
- };
27
- activeRouter.ActiveRouter.injectProps(Redirect, [
28
- 'history',
29
- 'root'
30
- ]);
31
-
32
- exports.stencil_router_redirect = Redirect;
@@ -1,125 +0,0 @@
1
- {
2
- "entries": [
3
- "./components/super-selection-app/super-selection-app.js",
4
- "./components/app-host/loading-page.js",
5
- "./components/app-host/super-selection-app-host.js",
6
- "./components/super-selection-app/app-state-pages/success.js",
7
- "./components/super-selection-app/footer-section/footer-section.js",
8
- "./components/super-selection-app/funds/custom-fund/custom-fund.js",
9
- "./components/super-selection-app/funds/custom-fund/default-fund/default-fund.js",
10
- "./components/super-selection-app/funds/custom-fund/my-own-fund/my-own-fund-inputs.js",
11
- "./components/super-selection-app/funds/custom-fund/my-own-fund/my-own-fund.js",
12
- "./components/super-selection-app/funds/custom-fund/self-managed-fund/self-managed-fund-inputs.js",
13
- "./components/super-selection-app/funds/custom-fund/self-managed-fund/self-managed-fund.js",
14
- "./components/super-selection-app/funds/qsuper/qsuper-confirm-header.js",
15
- "./components/super-selection-app/funds/qsuper/qsuper-insurance-opt-in.js",
16
- "./components/super-selection-app/funds/qsuper/qsuper-insurance-questions.js",
17
- "./components/super-selection-app/funds/qsuper/qsuper-layout.js",
18
- "./components/super-selection-app/funds/qsuper/qsuper-confirm-selection/qsuper-confirm-selection.js",
19
- "./components/super-selection-app/funds/qsuper/qsuper-consent/qsuper-consent.js",
20
- "./components/super-selection-app/funds/qsuper/questions/question1/question1.js",
21
- "./components/super-selection-app/funds/qsuper/questions/question2/question2.js",
22
- "./components/super-selection-app/funds/qsuper/questions/question3/question3.js",
23
- "./components/super-selection-app/funds/qsuper/questions/question4/question4.js",
24
- "./components/super-selection-app/funds/qsuper/questions/question5/question5.js",
25
- "./components/super-selection-app/funds/qsuper/questions/question6/question6.js",
26
- "./components/super-selection-app/funds/qsuper/questions/question7/question7.js",
27
- "./components/super-selection-app/funds/qsuper/questions/question8/question8.js",
28
- "./components/super-selection-app/funds/qsuper/questions/yes-no-buttons/qsuper-question-yes-no-buttons.js",
29
- "./components/super-selection-app/funds/slate-super/slate-join-page.js",
30
- "./components/super-selection-app/funds/slate-super/slate-standard-choice-page.js",
31
- "./components/super-selection-app/funds/slate-super/slatesuper-header.js",
32
- "./components/super-selection-app/notifications-section/notifications-section.js",
33
- "./components/super-selection-app/standard-choice/standard-choice-form.js",
34
- "./components/super-selection-app/super-choice-page/super-choice-item.js",
35
- "./components/super-selection-app/super-choice-page/super-choice-page.js",
36
- "./components/super-selection-app/super-choice-page/selected-super-choice-section/selected-super-choice-section.js"
37
- ],
38
- "compiler": {
39
- "name": "@stencil/core",
40
- "version": "2.3.0",
41
- "typescriptVersion": "4.0.5"
42
- },
43
- "collections": [
44
- {
45
- "name": "@flarehr/beacon",
46
- "tags": [
47
- "fl-button",
48
- "fl-dropdown",
49
- "fl-dropdown-async",
50
- "fl-loading-indicator",
51
- "fl-promise-button",
52
- "fl-style-guide"
53
- ]
54
- },
55
- {
56
- "name": "@stencil/router",
57
- "tags": [
58
- "stencil-async-content",
59
- "stencil-route",
60
- "stencil-route-link",
61
- "stencil-route-switch",
62
- "stencil-route-title",
63
- "stencil-router",
64
- "stencil-router-prompt",
65
- "stencil-router-redirect"
66
- ]
67
- },
68
- {
69
- "name": "@stencil/state-tunnel",
70
- "tags": [
71
- "context-consumer"
72
- ]
73
- }
74
- ],
75
- "bundles": [
76
- {
77
- "components": [
78
- "fl-button",
79
- "fl-dropdown",
80
- "fl-dropdown-async",
81
- "fl-loading-indicator",
82
- "fl-promise-button",
83
- "sss-custom-fund",
84
- "sss-default-fund",
85
- "sss-footer-section",
86
- "sss-loading-page",
87
- "sss-my-own-fund",
88
- "sss-my-own-fund-inputs",
89
- "sss-notifications-section",
90
- "sss-qsuper-confirm-header",
91
- "sss-qsuper-consent",
92
- "sss-qsuper-insurance-opt-in",
93
- "sss-qsuper-insurance-questions",
94
- "sss-qsuper-join",
95
- "sss-qsuper-layout",
96
- "sss-qsuper-question-1",
97
- "sss-qsuper-question-2",
98
- "sss-qsuper-question-3",
99
- "sss-qsuper-question-4",
100
- "sss-qsuper-question-5",
101
- "sss-qsuper-question-6",
102
- "sss-qsuper-question-7",
103
- "sss-qsuper-question-8",
104
- "sss-qsuper-question-yes-no-buttons",
105
- "sss-selected-super-choice-section",
106
- "sss-self-managed-fund",
107
- "sss-self-managed-fund-inputs",
108
- "sss-slate-join-page",
109
- "sss-slate-standard-choice-page",
110
- "sss-slatesuper-header",
111
- "sss-standard-choice-form",
112
- "sss-success",
113
- "sss-super-choice-item",
114
- "sss-super-choice-page",
115
- "stencil-route",
116
- "stencil-route-link",
117
- "stencil-route-switch",
118
- "stencil-router",
119
- "super-selection-app",
120
- "super-selection-app-host"
121
- ]
122
- }
123
- ],
124
- "global": "./global/main.js"
125
- }
@@ -1,9 +0,0 @@
1
- import { Component, h, Host } from '@stencil/core';
2
- export class LoadingPage {
3
- render() {
4
- return (h(Host, { class: "d-flex flex-column justify-content-center align-items-center flex-grow-1" },
5
- h("h5", null, "Loading your superannuation step"),
6
- h("fl-loading-indicator", null)));
7
- }
8
- static get is() { return "sss-loading-page"; }
9
- }
@@ -1,18 +0,0 @@
1
- import { Query } from '@datorama/akita';
2
- import * as O from 'fp-ts/Option';
3
- import sessionStore from './session.store';
4
- export class AppConfigurationQuery extends Query {
5
- constructor(store) {
6
- super(store);
7
- this.store = store;
8
- this.appConfiguration$ = this.select((state) => state.appConfiguration);
9
- }
10
- get configuration() {
11
- const configuration = this.getValue().appConfiguration;
12
- if (O.isNone(configuration)) {
13
- throw Error('App configuration is not yet loaded');
14
- }
15
- return configuration.value;
16
- }
17
- }
18
- export default new AppConfigurationQuery(sessionStore);
@@ -1,25 +0,0 @@
1
- import * as O from 'fp-ts/lib/Option';
2
- import wretch from 'wretch';
3
- import { Lazy } from '../../../utils';
4
- import sessionStore from './session.store';
5
- class AppConfigurationService {
6
- constructor() {
7
- this._appRootUrl = new Lazy(() => this.resolveRootUrl());
8
- this.getAppRootUrl = () => this._appRootUrl.value;
9
- this.getAppHostUrl = () => `${window.location.origin}${this.getAppRootUrl()}`.replace(/\/$/, '');
10
- }
11
- async loadConfigurationAsync() {
12
- const configuration = await wretch(`${this.getAppRootUrl()}config.json`)
13
- .get()
14
- .json();
15
- sessionStore.update({ appConfiguration: O.fromNullable(configuration) });
16
- }
17
- resolveRootUrl() {
18
- const match = O.fromNullable(window.location.pathname.match(/^\/super-selection\/embed\/v1.0\/app/));
19
- if (O.isNone(match)) {
20
- throw Error('Unsupported host URL');
21
- }
22
- return match.value[0] + '/';
23
- }
24
- }
25
- export default new AppConfigurationService();
@@ -1,43 +0,0 @@
1
- import { ApplicationInsights } from '@microsoft/applicationinsights-web';
2
- import { SeverityLevel } from '@microsoft/applicationinsights-web';
3
- import { setErrorHandler } from '@stencil/core';
4
- import { Lazy } from '../../../utils';
5
- import appConfigurationQuery from './app-configuration.query';
6
- export class AppInsightsService {
7
- constructor() {
8
- this.appInsights = new Lazy(() => new ApplicationInsights({
9
- config: {
10
- instrumentationKey: appConfigurationQuery.configuration.AppInsightsKey,
11
- enableAutoRouteTracking: true,
12
- autoTrackPageVisitTime: true,
13
- maxBatchInterval: 1000,
14
- enableUnhandledPromiseRejectionTracking: true
15
- }
16
- }));
17
- }
18
- init() {
19
- this.appInsights.value.loadAppInsights();
20
- setErrorHandler((err) => this.appInsightsErrorHandler(err));
21
- }
22
- getAppInsights() {
23
- return this.appInsights.value;
24
- }
25
- addCustomProperties(properties) {
26
- this.appInsights.value.addTelemetryInitializer((envelope) => {
27
- envelope.data = envelope.data ? envelope.data : {};
28
- for (const [k, v] of Object.entries(properties)) {
29
- envelope.data[k] = v;
30
- }
31
- });
32
- }
33
- appInsightsErrorHandler(error) {
34
- this.appInsights.value.trackException({
35
- error: error,
36
- severityLevel: SeverityLevel.Error
37
- });
38
- // eslint-disable-next-line no-console
39
- const defaultStencilErrorHandler = (error) => console.error(error);
40
- defaultStencilErrorHandler(error);
41
- }
42
- }
43
- export default new AppInsightsService();
@@ -1,21 +0,0 @@
1
- import { Query } from '@datorama/akita';
2
- import sessionStore, { AuthenticationState } from './session.store';
3
- export class AuthenticationQuery extends Query {
4
- constructor(store) {
5
- super(store);
6
- this.store = store;
7
- this.sessionState$ = this.select((state) => state.authenticationState);
8
- this.jwt$ = this.select((state) => state.jwt);
9
- }
10
- get sessionState() {
11
- return this.getValue().authenticationState;
12
- }
13
- get isUnauthorized() {
14
- return (this.getValue().authenticationState === AuthenticationState.Unauthorized ||
15
- this.getValue().authenticationState === AuthenticationState.Error);
16
- }
17
- get isAuthorized() {
18
- return this.getValue().authenticationState === AuthenticationState.Authenticated;
19
- }
20
- }
21
- export default new AuthenticationQuery(sessionStore);
@@ -1,50 +0,0 @@
1
- import * as O from 'fp-ts/lib/Option';
2
- import wretch from 'wretch';
3
- import { sendAnalyticsEvent } from '../../../utils/gtm';
4
- import appConfigurationQuery from './app-configuration.query';
5
- import appConfigurationService from './app-configuration.service';
6
- import sessionStore, { AuthenticationState } from './session.store';
7
- export class AuthenticationService {
8
- constructor() {
9
- this.authCodeQueryParameter = 'code';
10
- }
11
- authorizationCodeIsPresent(query) {
12
- const authCode = this.getAuthorizationCodeFromRoute(query);
13
- return O.isSome(authCode);
14
- }
15
- initFromRoute(query) {
16
- const authorizationCode = this.getAuthorizationCodeFromRoute(query);
17
- if (O.isNone(authorizationCode)) {
18
- sessionStore.update({ authenticationState: AuthenticationState.Error });
19
- throw Error(`"${this.authCodeQueryParameter}" URL query parameter missing`);
20
- }
21
- this.authCodeExchangeAsync(authorizationCode.value);
22
- }
23
- async authCodeExchangeAsync(authorizationCode) {
24
- const formData = new URLSearchParams([
25
- ['grant_type', 'authorization_code'],
26
- ['client_id', 'apollo-super-selection-app'],
27
- ['code', authorizationCode],
28
- ['redirect_uri', `${appConfigurationService.getAppHostUrl()}`]
29
- ]);
30
- const tokenResponse = await wretch(appConfigurationQuery.configuration.OidcAuthority + "/connect/token")
31
- .headers({ 'Content-Type': 'application/x-www-form-urlencoded' })
32
- .post(formData.toString())
33
- .badRequest(() => {
34
- sessionStore.update({ authenticationState: AuthenticationState.Error });
35
- throw new Error('Failed to authenticate.');
36
- })
37
- .json();
38
- sessionStore.update({
39
- jwt: O.fromNullable(tokenResponse.access_token),
40
- authenticationState: AuthenticationState.Authenticated
41
- });
42
- sendAnalyticsEvent('oidc_sign_in', {});
43
- window.history.replaceState(null, '', appConfigurationService.getAppRootUrl());
44
- }
45
- getAuthorizationCodeFromRoute(query) {
46
- const urlParams = new URLSearchParams(query);
47
- return O.fromNullable(urlParams.get(this.authCodeQueryParameter));
48
- }
49
- }
50
- export default new AuthenticationService();
@@ -1,31 +0,0 @@
1
- import * as O from 'fp-ts/Option';
2
- import interopQuery from '../interop.query';
3
- import sessionStore from '../session.store';
4
- import { IFrameInteropService } from './iframe-interop.service';
5
- import { ReactNativeInteropService } from './react-native-interop.service';
6
- export class HostInteropService {
7
- constructor() {
8
- this.interopModeQueryParameter = 'interop-mode';
9
- }
10
- completeSuperSelectionStep() {
11
- if (interopQuery.isIframeInteropEnabled()) {
12
- IFrameInteropService.completeSuperSelectionStep();
13
- }
14
- else if (interopQuery.isReactNativeInteropEnabled()) {
15
- ReactNativeInteropService.completeSuperSelectionStep();
16
- }
17
- else {
18
- throw Error('Unknown interop mode');
19
- }
20
- }
21
- init(urlQuery) {
22
- const urlParams = new URLSearchParams(urlQuery);
23
- const interopMode = O.fromNullable(urlParams.get(this.interopModeQueryParameter));
24
- if (O.isSome(interopMode) && interopMode.value === "react-native") {
25
- sessionStore.update({ reactNativeInterop: O.some(ReactNativeInteropService.init()) });
26
- return;
27
- }
28
- sessionStore.update({ iframeInterop: O.some(IFrameInteropService.initFromRoute(urlQuery)) });
29
- }
30
- }
31
- export default new HostInteropService();
@@ -1,30 +0,0 @@
1
- import * as O from 'fp-ts/lib/Option';
2
- import iframe from '../../../../utils/iframe';
3
- import interopQuery from '../interop.query';
4
- export class IFrameInteropService {
5
- static completeSuperSelectionStep() {
6
- const { successRedirectionUrl } = interopQuery.getIframeInteropMode();
7
- if (O.isSome(successRedirectionUrl)) {
8
- window.top.location.href = successRedirectionUrl.value;
9
- }
10
- else {
11
- iframe.complete();
12
- }
13
- }
14
- static initFromRoute(route) {
15
- const redirectionUrlQueryParameter = 'success-redirection-url';
16
- const urlParams = new URLSearchParams(route);
17
- const redirectionUrl = O.fromNullable(urlParams.get(redirectionUrlQueryParameter));
18
- const iframeMode = { successRedirectionUrl: O.none };
19
- if (O.isSome(redirectionUrl)) {
20
- try {
21
- const validatedUrl = new URL(redirectionUrl.value);
22
- iframeMode.successRedirectionUrl = O.some(validatedUrl.toString());
23
- }
24
- catch (error) {
25
- throw Error(`"${redirectionUrl.value}" is not a valid URL`);
26
- }
27
- }
28
- return iframeMode;
29
- }
30
- }
@@ -1,20 +0,0 @@
1
- import { ReactNativeInteropMode } from '../session.store';
2
- export class ReactNativeInteropService {
3
- static init() {
4
- const isMessagingAvailable = window['ReactNativeWebView'] !== undefined;
5
- if (!isMessagingAvailable) {
6
- throw Error('React Native WebView messaging is not enabled. Please, refer to https://github.com/react-native-webview/react-native-webview/blob/master/docs/Guide.md#the-windowreactnativewebviewpostmessage-method-and-onmessage-prop');
7
- }
8
- return new ReactNativeInteropMode();
9
- }
10
- static completeSuperSelectionStep() {
11
- this.postRNMessage();
12
- }
13
- static postRNMessage() {
14
- const message = {
15
- stepStatus: 'completed'
16
- };
17
- ReactNativeInteropService.getRnInterop().postMessage(JSON.stringify(message));
18
- }
19
- }
20
- ReactNativeInteropService.getRnInterop = () => window['ReactNativeWebView'];
@@ -1,26 +0,0 @@
1
- import { Query } from '@datorama/akita';
2
- import * as O from 'fp-ts/Option';
3
- import sessionStore from './session.store';
4
- export class InteropQuery extends Query {
5
- constructor(store) {
6
- super(store);
7
- this.store = store;
8
- }
9
- isReactNativeInteropEnabled() {
10
- return O.isSome(this.getValue().reactNativeInterop);
11
- }
12
- isIframeInteropEnabled() {
13
- return O.isSome(this.getValue().iframeInterop);
14
- }
15
- getIframeInteropMode() {
16
- const iframeInterop = this.getValue().iframeInterop;
17
- if (O.isNone(iframeInterop)) {
18
- throw Error('Failed to get iframe interop information: no data in store');
19
- }
20
- if (!this.isIframeInteropEnabled()) {
21
- throw Error('Failed to get iframe interop information: iframe mode is disabled');
22
- }
23
- return iframeInterop.value;
24
- }
25
- }
26
- export default new InteropQuery(sessionStore);
@@ -1,37 +0,0 @@
1
- var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- };
7
- import { Store, StoreConfig } from '@datorama/akita';
8
- import * as O from 'fp-ts/Option';
9
- export var AuthenticationState;
10
- (function (AuthenticationState) {
11
- AuthenticationState[AuthenticationState["Unauthorized"] = 0] = "Unauthorized";
12
- AuthenticationState[AuthenticationState["Authenticated"] = 1] = "Authenticated";
13
- AuthenticationState[AuthenticationState["Error"] = 2] = "Error";
14
- })(AuthenticationState || (AuthenticationState = {}));
15
- export class ReactNativeInteropMode {
16
- }
17
- export class IframeInteropMode {
18
- }
19
- export function createInitialState() {
20
- return {
21
- authenticationState: AuthenticationState.Unauthorized,
22
- jwt: O.none,
23
- reactNativeInterop: O.none,
24
- iframeInterop: O.none,
25
- appConfiguration: O.none
26
- };
27
- }
28
- let SessionStore = class SessionStore extends Store {
29
- constructor() {
30
- super(createInitialState());
31
- }
32
- };
33
- SessionStore = __decorate([
34
- StoreConfig({ name: 'sss-session', resettable: true })
35
- ], SessionStore);
36
- export { SessionStore };
37
- export default new SessionStore();