@clickview/lite 0.34.4 → 0.35.0-rc.1

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 (163) hide show
  1. package/dist/bundles.json +2 -2
  2. package/dist/css/109-lite-e638e5617a.chunk.css +3 -0
  3. package/dist/css/1944-lite-6cd5066b84.chunk.css +8 -0
  4. package/dist/css/{1958-lite-590913882e.chunk.css → 1958-lite-f2a03898a1.chunk.css} +1 -1
  5. package/dist/css/{2318-lite-12e260481d.chunk.css → 2318-lite-7add8a5943.chunk.css} +1 -1
  6. package/dist/css/{3789-lite-25d999ba37.chunk.css → 3706-lite-8601f9a468.chunk.css} +1 -1
  7. package/dist/css/7701-lite-6d26cc737a.chunk.css +7 -0
  8. package/dist/css/{823-lite-2fcae6c9fe.chunk.css → 823-lite-08611664d8.chunk.css} +1 -1
  9. package/dist/css/8329-lite-1f86f27b10.chunk.css +3 -0
  10. package/dist/css/8978-lite-aa21368531.chunk.css +3 -0
  11. package/dist/css/{9242-lite-3fdb8a127b.chunk.css → 9242-lite-a7f4a0feb1.chunk.css} +1 -1
  12. package/dist/css/{9264-lite-405b41aa7a.chunk.css → 9264-lite-763498f278.chunk.css} +1 -1
  13. package/dist/css/{9273-lite-fb0a1c9807.chunk.css → 9273-lite-891bd09f86.chunk.css} +1 -1
  14. package/dist/css/{lite-app-04685f0964.css → lite-app-df99273901.css} +1 -1
  15. package/dist/languages/en.json +1 -1
  16. package/dist/scripts/109-c94f9ee532-lite.chunk.js +1 -0
  17. package/dist/scripts/{1366-9085be8f1d-lite.chunk.js → 1366-e5b46ac15b-lite.chunk.js} +1 -1
  18. package/dist/scripts/1517-9158f5a30a-lite.chunk.js +1 -0
  19. package/dist/scripts/{1672-18d6a86a04-lite.chunk.js → 1672-4ff30fe0d9-lite.chunk.js} +1 -1
  20. package/dist/scripts/1750-dd4c1bf3fc-lite.chunk.js +1 -0
  21. package/dist/scripts/{1830-c6de13dbbd-lite.chunk.js → 1830-8741ff0b49-lite.chunk.js} +1 -1
  22. package/dist/scripts/1944-8faad6e742-lite.chunk.js +1 -0
  23. package/dist/scripts/{1958-4137ef8be6-lite.chunk.js → 1958-682b6ca73a-lite.chunk.js} +1 -1
  24. package/dist/scripts/2279-02a72d36ec-lite.chunk.js +1 -0
  25. package/dist/scripts/{2318-106cc66f74-lite.chunk.js → 2318-a0fc0fe177-lite.chunk.js} +1 -1
  26. package/dist/scripts/3042-72050bd1b4-lite.chunk.js +1 -0
  27. package/dist/scripts/{3154-f88bbfdad6-lite.chunk.js → 3154-539a352006-lite.chunk.js} +1 -1
  28. package/dist/scripts/{3446-3ea1cdc255-lite.chunk.js → 3446-f4de03ea76-lite.chunk.js} +1 -1
  29. package/dist/scripts/3488-402969da0d-lite.chunk.js +2 -0
  30. package/dist/scripts/3667-289cb6db16-lite.chunk.js +2 -0
  31. package/dist/scripts/3706-e997fb8467-lite.chunk.js +2 -0
  32. package/dist/scripts/3937-1b5cc87640-lite.chunk.js +2 -0
  33. package/dist/scripts/3937-1b5cc87640-lite.chunk.js.LICENSE.txt +18 -0
  34. package/dist/scripts/{4343-730d74fb5b-lite.chunk.js → 4343-91c9cfcb4a-lite.chunk.js} +1 -1
  35. package/dist/scripts/{4441-ecfd561927-lite.chunk.js → 4441-e77b7104ee-lite.chunk.js} +2 -2
  36. package/dist/scripts/4537-6383a3ea11-lite.chunk.js +1 -0
  37. package/dist/scripts/{4617-80ac7fa8fc-lite.chunk.js → 4617-94a4942af7-lite.chunk.js} +1 -1
  38. package/dist/scripts/4705-93c1f3affb-lite.chunk.js +1 -0
  39. package/dist/scripts/5271-da40b4f079-lite.chunk.js +1 -1
  40. package/dist/scripts/{5986-23d0ce44b4-lite.chunk.js → 5986-999c9736f7-lite.chunk.js} +1 -1
  41. package/dist/scripts/6330-298b027309-lite.chunk.js +1 -0
  42. package/dist/scripts/{6433-1c5d1c7ee1-lite.chunk.js → 6433-7b2bd48f40-lite.chunk.js} +2 -2
  43. package/dist/scripts/6480-3e17c41241-lite.chunk.js +1 -0
  44. package/dist/scripts/6532-5bc872b460-lite.chunk.js +1 -0
  45. package/dist/scripts/6572-a77a3b657b-lite.chunk.js +1 -0
  46. package/dist/scripts/{6801-d3cf047fb8-lite.chunk.js → 6801-fb5064f563-lite.chunk.js} +1 -1
  47. package/dist/scripts/6823-b2eb2f9837-lite.chunk.js +2 -0
  48. package/dist/scripts/{6998-59f11dbe63-lite.chunk.js → 6998-90e59883b6-lite.chunk.js} +1 -1
  49. package/dist/scripts/{7052-9c71dbfe4b-lite.chunk.js → 7052-d9ae572322-lite.chunk.js} +1 -1
  50. package/dist/scripts/7112-25e9780c3f-lite.chunk.js +2 -0
  51. package/dist/scripts/7564-7404c7bbcd-lite.chunk.js +1 -0
  52. package/dist/scripts/7701-3eb0dab472-lite.chunk.js +1 -0
  53. package/dist/scripts/7708-966b540945-lite.chunk.js +1 -0
  54. package/dist/scripts/823-605b4e1a7a-lite.chunk.js +1 -0
  55. package/dist/scripts/{8323-ca8e0d6371-lite.chunk.js → 8323-e7e2a0a948-lite.chunk.js} +1 -1
  56. package/dist/scripts/8329-db3ca45cb6-lite.chunk.js +2 -0
  57. package/dist/scripts/8621-667296796a-lite.chunk.js +1 -0
  58. package/dist/scripts/{8873-99f49dc0d3-lite.chunk.js → 8873-b54b5ec956-lite.chunk.js} +1 -1
  59. package/dist/scripts/8935-6225840bc3-lite.chunk.js +2 -0
  60. package/dist/scripts/8935-6225840bc3-lite.chunk.js.LICENSE.txt +1 -0
  61. package/dist/scripts/8978-2cb6319c36-lite.chunk.js +2 -0
  62. package/dist/scripts/8978-2cb6319c36-lite.chunk.js.LICENSE.txt +1 -0
  63. package/dist/scripts/{9016-236a5997d4-lite.chunk.js → 9016-e97d214ce1-lite.chunk.js} +1 -1
  64. package/dist/scripts/{9151-7da7f5dff4-lite.chunk.js → 9151-a4b1b99c42-lite.chunk.js} +1 -1
  65. package/dist/scripts/9242-a9f54957c0-lite.chunk.js +1 -0
  66. package/dist/scripts/{9264-5901a0f52d-lite.chunk.js → 9264-5634e746a9-lite.chunk.js} +1 -1
  67. package/dist/scripts/9273-3a5bd8e56e-lite.chunk.js +1 -0
  68. package/dist/scripts/9581-41cb8eba5b-lite.chunk.js +1 -0
  69. package/dist/scripts/9843-d084ed32bf-lite.chunk.js +1 -0
  70. package/dist/scripts/bundle-16e47e8e8d.min.js +2 -0
  71. package/jest.config.js +11 -11
  72. package/package.json +61 -61
  73. package/typings/libs/CVEvents.d.ts +12 -12
  74. package/typings/libs/CVLanguages.d.ts +24 -24
  75. package/typings/libs/cloneDeep.d.ts +4 -4
  76. package/typings/libs/cookiesjs.d.ts +25 -25
  77. package/typings/libs/draft-convert.d.ts +3 -3
  78. package/typings/libs/google-api.d.ts +93 -93
  79. package/typings/libs/intersection-observer.d.ts +82 -82
  80. package/typings/libs/microsoft-teams.d.ts +2 -2
  81. package/typings/libs/react-table-config.d.ts +138 -138
  82. package/typings/libs/trackjs.d.ts +2 -2
  83. package/typings/libs/videojs-contrib-quality-levels.d.ts +28 -28
  84. package/typings/utils/imports.d.ts +13 -13
  85. package/dist/css/2095-lite-32dcae3b59.chunk.css +0 -6
  86. package/dist/css/7332-lite-abb86816df.chunk.css +0 -4
  87. package/dist/scripts/1517-fea7d3d8c1-lite.chunk.js +0 -1
  88. package/dist/scripts/1750-c17a99c57c-lite.chunk.js +0 -1
  89. package/dist/scripts/2095-eaf40acb79-lite.chunk.js +0 -1
  90. package/dist/scripts/2279-4180148403-lite.chunk.js +0 -1
  91. package/dist/scripts/2678-fee97a31e2-lite.chunk.js +0 -2
  92. package/dist/scripts/3042-3153eae063-lite.chunk.js +0 -1
  93. package/dist/scripts/3667-43e348aada-lite.chunk.js +0 -2
  94. package/dist/scripts/3754-09e32bdce9-lite.chunk.js +0 -1
  95. package/dist/scripts/3789-c93bdc1db3-lite.chunk.js +0 -2
  96. package/dist/scripts/4537-34d2a3e99f-lite.chunk.js +0 -1
  97. package/dist/scripts/4657-077acd4492-lite.chunk.js +0 -2
  98. package/dist/scripts/4705-4f3442b228-lite.chunk.js +0 -1
  99. package/dist/scripts/5765-435b534b54-lite.chunk.js +0 -1
  100. package/dist/scripts/6330-5e2af8dcf4-lite.chunk.js +0 -1
  101. package/dist/scripts/6480-7bb16386d4-lite.chunk.js +0 -1
  102. package/dist/scripts/6572-37b2e1d856-lite.chunk.js +0 -1
  103. package/dist/scripts/7112-4ac30d206c-lite.chunk.js +0 -2
  104. package/dist/scripts/7332-b33fb332d9-lite.chunk.js +0 -1
  105. package/dist/scripts/7564-47241b622f-lite.chunk.js +0 -1
  106. package/dist/scripts/7708-e5cc05531d-lite.chunk.js +0 -1
  107. package/dist/scripts/823-8c9802b94a-lite.chunk.js +0 -1
  108. package/dist/scripts/8621-8cabf96744-lite.chunk.js +0 -1
  109. package/dist/scripts/8935-80c206852a-lite.chunk.js +0 -2
  110. package/dist/scripts/9242-ca8229f486-lite.chunk.js +0 -1
  111. package/dist/scripts/9273-73add4829e-lite.chunk.js +0 -1
  112. package/dist/scripts/9843-deb50808e7-lite.chunk.js +0 -1
  113. package/dist/scripts/bundle-8eabc9f269.min.js +0 -2
  114. /package/dist/scripts/{1366-9085be8f1d-lite.chunk.js.LICENSE.txt → 1366-e5b46ac15b-lite.chunk.js.LICENSE.txt} +0 -0
  115. /package/dist/scripts/{1672-18d6a86a04-lite.chunk.js.LICENSE.txt → 1672-4ff30fe0d9-lite.chunk.js.LICENSE.txt} +0 -0
  116. /package/dist/scripts/{1725-2eb898f9e6-lite.chunk.js → 1725-082ef05b56-lite.chunk.js} +0 -0
  117. /package/dist/scripts/{1820-273a02b871-lite.chunk.js → 1820-d34eefdad4-lite.chunk.js} +0 -0
  118. /package/dist/scripts/{1891-c0e59b8132-lite.chunk.js → 1891-af9f943f4d-lite.chunk.js} +0 -0
  119. /package/dist/scripts/{1913-00de345658-lite.chunk.js → 1913-196e6dbf6e-lite.chunk.js} +0 -0
  120. /package/dist/scripts/{209-d5def5db16-lite.chunk.js → 209-03f1ffaa32-lite.chunk.js} +0 -0
  121. /package/dist/scripts/{2208-c345263710-lite.chunk.js → 2208-8e54f2060f-lite.chunk.js} +0 -0
  122. /package/dist/scripts/{2452-f96e548d17-lite.chunk.js → 2452-446607a894-lite.chunk.js} +0 -0
  123. /package/dist/scripts/{275-e6fd29e862-lite.chunk.js → 275-3f5dcc4c57-lite.chunk.js} +0 -0
  124. /package/dist/scripts/{3020-4b42980fff-lite.chunk.js → 3020-1f43870f76-lite.chunk.js} +0 -0
  125. /package/dist/scripts/{3667-43e348aada-lite.chunk.js.LICENSE.txt → 3488-402969da0d-lite.chunk.js.LICENSE.txt} +0 -0
  126. /package/dist/scripts/{3789-c93bdc1db3-lite.chunk.js.LICENSE.txt → 3667-289cb6db16-lite.chunk.js.LICENSE.txt} +0 -0
  127. /package/dist/scripts/{4441-ecfd561927-lite.chunk.js.LICENSE.txt → 3706-e997fb8467-lite.chunk.js.LICENSE.txt} +0 -0
  128. /package/dist/scripts/{3728-9a8b800e2e-lite.chunk.js → 3728-8f767eeedd-lite.chunk.js} +0 -0
  129. /package/dist/scripts/{4182-2de6622588-lite.chunk.js → 4182-e9700be806-lite.chunk.js} +0 -0
  130. /package/dist/scripts/{4373-4f5c0a2274-lite.chunk.js → 4373-cf0cc66781-lite.chunk.js} +0 -0
  131. /package/dist/scripts/{4657-077acd4492-lite.chunk.js.LICENSE.txt → 4441-e77b7104ee-lite.chunk.js.LICENSE.txt} +0 -0
  132. /package/dist/scripts/{4690-ff95c6ea7d-lite.chunk.js → 4690-b7b01cea5f-lite.chunk.js} +0 -0
  133. /package/dist/scripts/{5143-b8acf4a4b6-lite.chunk.js → 5143-56be0b0492-lite.chunk.js} +0 -0
  134. /package/dist/scripts/{5171-e7cc024460-lite.chunk.js → 5171-53fc8f18ba-lite.chunk.js} +0 -0
  135. /package/dist/scripts/{519-4140367219-lite.chunk.js → 519-30f9dc5f0c-lite.chunk.js} +0 -0
  136. /package/dist/scripts/{5555-f3b47d4b44-lite.chunk.js → 5555-71000b5eaa-lite.chunk.js} +0 -0
  137. /package/dist/scripts/{5606-2596d38d1b-lite.chunk.js → 5606-404debcda3-lite.chunk.js} +0 -0
  138. /package/dist/scripts/{5611-cc919759f4-lite.chunk.js → 5611-4c2f18c8be-lite.chunk.js} +0 -0
  139. /package/dist/scripts/{5877-0acd7d3124-lite.chunk.js → 5877-d728cd98a7-lite.chunk.js} +0 -0
  140. /package/dist/scripts/{6290-337e7cf0ba-lite.chunk.js → 6290-4f53628aac-lite.chunk.js} +0 -0
  141. /package/dist/scripts/{6433-1c5d1c7ee1-lite.chunk.js.LICENSE.txt → 6433-7b2bd48f40-lite.chunk.js.LICENSE.txt} +0 -0
  142. /package/dist/scripts/{6450-1b69ecb4d2-lite.chunk.js → 6450-87b22756f6-lite.chunk.js} +0 -0
  143. /package/dist/scripts/{6604-d331808398-lite.chunk.js → 6604-19f0427fcc-lite.chunk.js} +0 -0
  144. /package/dist/scripts/{6702-d96686b5d6-lite.chunk.js → 6702-7f040268d0-lite.chunk.js} +0 -0
  145. /package/dist/scripts/{6725-6a2185d8d3-lite.chunk.js → 6725-6fe76436f5-lite.chunk.js} +0 -0
  146. /package/dist/scripts/{2678-fee97a31e2-lite.chunk.js.LICENSE.txt → 6823-b2eb2f9837-lite.chunk.js.LICENSE.txt} +0 -0
  147. /package/dist/scripts/{6896-18b1d98e15-lite.chunk.js → 6896-8b4fc3fd6d-lite.chunk.js} +0 -0
  148. /package/dist/scripts/{7017-60fa1e1938-lite.chunk.js → 7017-dc16719bf3-lite.chunk.js} +0 -0
  149. /package/dist/scripts/{7052-9c71dbfe4b-lite.chunk.js.LICENSE.txt → 7052-d9ae572322-lite.chunk.js.LICENSE.txt} +0 -0
  150. /package/dist/scripts/{7112-4ac30d206c-lite.chunk.js.LICENSE.txt → 7112-25e9780c3f-lite.chunk.js.LICENSE.txt} +0 -0
  151. /package/dist/scripts/{714-02e02b6b62-lite.chunk.js → 714-676e0b469a-lite.chunk.js} +0 -0
  152. /package/dist/scripts/{7164-6489adf352-lite.chunk.js → 7164-9dec6a0e20-lite.chunk.js} +0 -0
  153. /package/dist/scripts/{7178-03fbf5c5ce-lite.chunk.js → 7178-a1115d825b-lite.chunk.js} +0 -0
  154. /package/dist/scripts/{7293-f8e0f7e712-lite.chunk.js → 7293-d0994effb4-lite.chunk.js} +0 -0
  155. /package/dist/scripts/{7432-ed0fdcb18c-lite.chunk.js → 7432-337ec5be0e-lite.chunk.js} +0 -0
  156. /package/dist/scripts/{7818-a9ab33bdd4-lite.chunk.js → 7818-c81c2d60b9-lite.chunk.js} +0 -0
  157. /package/dist/scripts/{8046-1b45fa8487-lite.chunk.js → 8046-1c2056961d-lite.chunk.js} +0 -0
  158. /package/dist/scripts/{8323-ca8e0d6371-lite.chunk.js.LICENSE.txt → 8323-e7e2a0a948-lite.chunk.js.LICENSE.txt} +0 -0
  159. /package/dist/scripts/{8935-80c206852a-lite.chunk.js.LICENSE.txt → 8329-db3ca45cb6-lite.chunk.js.LICENSE.txt} +0 -0
  160. /package/dist/scripts/{8772-b621c408fe-lite.chunk.js → 8772-0cae662668-lite.chunk.js} +0 -0
  161. /package/dist/scripts/{9016-236a5997d4-lite.chunk.js.LICENSE.txt → 9016-e97d214ce1-lite.chunk.js.LICENSE.txt} +0 -0
  162. /package/dist/scripts/{9226-55f3cf2252-lite.chunk.js → 9226-f59a8a5d53-lite.chunk.js} +0 -0
  163. /package/dist/scripts/{bundle-8eabc9f269.min.js.LICENSE.txt → bundle-16e47e8e8d.min.js.LICENSE.txt} +0 -0
@@ -1,2 +0,0 @@
1
- /*! For license information please see 4657-077acd4492-lite.chunk.js.LICENSE.txt */
2
- "use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[4657],{42328:(t,e,r)=>{r.d(e,{w:()=>a});var n=r(32735);function o(){return n.createElement("svg",{viewBox:"0 0 24 24"},n.createElement("path",{d:"M11.959 10.641l4.402-4.296a.964.964 0 0 1 1.358 0 .951.951 0 0 1 0 1.35l-4.403 4.297 4.403 4.378a.951.951 0 0 1 0 1.35.964.964 0 0 1-1.358 0l-4.402-4.378-4.32 4.378a.964.964 0 0 1-1.358 0 .951.951 0 0 1 0-1.35l4.32-4.378-4.32-4.362a.951.951 0 0 1 0-1.35.964.964 0 0 1 1.358 0l4.32 4.361z"}))}var a=n.forwardRef((function(t,e){var r=t.onClickClear,a=t.showClearButton,i=function(t,e){var r={};for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&e.indexOf(n)<0&&(r[n]=t[n]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(t);o<n.length;o++)e.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(t,n[o])&&(r[n[o]]=t[n[o]])}return r}(t,["onClickClear","showClearButton"]);return n.createElement("div",{className:"position-relative"},n.createElement("input",Object.assign({},i,{ref:e,className:"".concat(t.className," ").concat("aYpO7")})),(!!t.value||a)&&n.createElement("span",{className:"".concat("ygMgF"," position-absolute cursor-pointer text-muted"),role:"button",onClick:r},n.createElement("div",{className:"d-inline-block svg-container md"},n.createElement(o,null))))}))},12594:(t,e,r)=>{r.d(e,{h:()=>Qr});var n=r(32735),o=r(57900),a=r(49985),i=r(74254),c=r(42328),l=["Teacher","Librarian","Curriculum Coordinator","Digital Technology Coordinator","IT","Head of Department","Head of Subject","Deputy Principal","Principal"],u=["Teacher","Librarian","Head of department","Subject lead","Curriculum coordinator","School leadership","District leadership","Academic coach","Instructional technology specialist","Consortium leadership","IT"],s={au:l,nz:l,uk:["Teacher","Librarian","IT/LRC","e-Learning/ICT Coordinator","Head of Key Stage","Head of Department","Subject Lead","Assistant Head Teacher","Deputy Head Teacher","Head Teacher"],us:u};function f(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return p(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?p(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function p(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}var h="OTHER";function d(t){var e=t.error,r=t.onChange,o=t.countryCode,a=f(n.useState(""),2),i=a[0],c=a[1],l=f(n.useState(""),2),p=l[0],d=l[1],y=function(t){return s[t]||u}(o),m=i===h;return n.createElement(n.Fragment,null,n.createElement("div",{className:"mb-2"},n.createElement("select",{id:t.id,name:t.id,className:"form-select form-select-lg ".concat(i.length?"text-dark":"text-secondary"," ").concat(!!e&&"is-invalid"),value:i,placeholder:"Role",onChange:function(t){c(t.target.value),d(""),r(t.target.value===h?"":t.target.value)}},n.createElement("option",{value:"",disabled:!0,className:"text-muted"},"What do you do?"),y.map((function(t,e){return n.createElement("option",{value:t,className:"text-dark",key:e},t)})),n.createElement("option",{value:h,className:"text-dark"},"Other")),!!e&&!m&&n.createElement("div",{className:"invalid-feedback"},e)),m&&n.createElement("div",{className:"mb-3"},n.createElement("input",{className:"form-control form-control-lg ".concat(!!e&&"is-invalid"),type:"text",value:p,placeholder:"What do you do?",autoFocus:!0,onChange:function(t){d(t.target.value),r(t.target.value)}}),!!e&&n.createElement("div",{className:"invalid-feedback"},e)))}var y,m,v,g=r(86664),b=r(2102);function w(t){return w="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},w(t)}function E(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function S(t){var e,r,o,a,i,l,u,s,f,p=(s=n.useState({fullname:"",jobTitle:"",phone:""}),f=2,function(t){if(Array.isArray(t))return t}(s)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(s,f)||function(t,e){if(t){if("string"==typeof t)return E(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?E(t,e):void 0}}(s,f)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),h=p[0],y=p[1];function m(t,e){y((function(r){return Object.assign(Object.assign({},r),function(t,e,r){return(e=function(t){var e=function(t,e){if("object"!==w(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,"string");if("object"!==w(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===w(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}({},t,e))}))}return n.createElement("div",{className:"text-center"},n.createElement("h1",{className:"text-center h4"},"A little more about you"),n.createElement("p",null,"Please enter your details."),n.createElement("form",{onSubmit:function(e){e.preventDefault(),t.handleSubmitForm(h)}},n.createElement("div",{className:"form-group text-start"},n.createElement("label",{className:"d-block fw-bold mb-1",htmlFor:"fullname-input"},"Full name"),n.createElement(c.w,{value:h.fullname,onChange:function(e){e.preventDefault(),m("fullname",e.target.value),t.removeErrorForKey("fullname"),t.removeErrorForKey("submission")},name:"fullname-input",id:"fullname-input",type:"text",className:"form-control form-control-lg ".concat((null===(e=t.errors.fullname)||void 0===e?void 0:e.length)?"is-invalid":""),placeholder:"Enter your name",onClickClear:function(){m("fullname",""),t.removeErrorForKey("fullname"),t.removeErrorForKey("submission")},autoFocus:!0}),t.errors.fullname&&n.createElement("div",{className:"invalid-feedback d-block"},t.errors.fullname)),n.createElement("div",{className:"form-group text-start"},n.createElement("label",{className:"d-block fw-bold mb-1",htmlFor:"phone-input"},"Contact number"),n.createElement(c.w,{value:h.phone,onChange:function(e){e.preventDefault(),m("phone",e.target.value.trim()),t.removeErrorForKey("phone"),t.removeErrorForKey("submission")},name:"phone-input",id:"phone-input",type:"tel",className:"form-control form-control-lg ".concat((null===(r=t.errors.phone)||void 0===r?void 0:r.length)?"is-invalid":""),placeholder:"Enter your phone number",onClickClear:function(){m("phone",""),t.removeErrorForKey("phone"),t.removeErrorForKey("submission")}}),t.errors.phone&&n.createElement("div",{className:"invalid-feedback d-block"},t.errors.phone)),n.createElement("div",{className:"form-group text-start"},n.createElement("label",{className:"d-block fw-bold mb-1",htmlFor:"jobTitle-select"},"Job title"),n.createElement(d,{id:"jobTitle-select",countryCode:g.I.getCountryCode(t.country),onChange:function(e){m("jobTitle",e),t.removeErrorForKey("jobTitle"),t.removeErrorForKey("submission")},error:null===(o=t.errors)||void 0===o?void 0:o.jobTitle})),!!(null===(a=t.errors)||void 0===a?void 0:a.submission)&&n.createElement("div",{className:"form-group invalid-feedback d-block"},t.errors.submission),n.createElement("div",{className:"form-group mb-1"},n.createElement(b.m,{className:"btn-lg w-100",variant:"dark",onClick:function(){return t.handleSubmitForm(h)},showSpinner:t.loading,disabled:t.loading||(i=h.fullname,l=h.jobTitle,u=h.phone,!(i.length&&l.length&&u.length&&!Object.keys(t.errors).length))},"Submit"))))}!function(t){t.Unavailable="unavailable",t.Expired="expired",t.Active="active",t.NotRequired="not-required",t.Available="available",t.Unsupported="unsupported",t.UserAutoJoinAllowed="user-auto-join-allowed",t.UserJoinApprovalRequired="user-join-approval-required"}(y||(y={})),function(t){t.InvalidEmail="invalid-email"}(m||(m={})),function(t){t.Staff="staff",t.Learner="learner"}(v||(v={}));var x=r(63093),L=r(33003),j=r.n(L),k=r(84789);function C(t){return C="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},C(t)}function O(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return N(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?N(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function N(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function A(){A=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var a=e&&e.prototype instanceof v?e:v,i=Object.create(a.prototype),c=new I(n||[]);return o(i,"_invoke",{value:k(t,r,c)}),i}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var p="suspendedStart",h="suspendedYield",d="executing",y="completed",m={};function v(){}function g(){}function b(){}var w={};u(w,i,(function(){return this}));var E=Object.getPrototypeOf,S=E&&E(E(T([])));S&&S!==r&&n.call(S,i)&&(w=S);var x=b.prototype=v.prototype=Object.create(w);function L(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function r(o,a,i,c){var l=f(t[o],t,a);if("throw"!==l.type){var u=l.arg,s=u.value;return s&&"object"==C(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,i,c)}),(function(t){r("throw",t,i,c)})):e.resolve(s).then((function(t){u.value=t,i(u)}),(function(t){return r("throw",t,i,c)}))}c(l.arg)}var a;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return a=a?a.then(o,o):o()}})}function k(e,r,n){var o=p;return function(a,i){if(o===d)throw new Error("Generator is already running");if(o===y){if("throw"===a)throw i;return{value:t,done:!0}}for(n.method=a,n.arg=i;;){var c=n.delegate;if(c){var l=O(c,n);if(l){if(l===m)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=y,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var u=f(e,r,n);if("normal"===u.type){if(o=n.done?y:h,u.arg===m)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(o=y,n.method="throw",n.arg=u.arg)}}}function O(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,O(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var a=f(o,e.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,m;var i=a.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function N(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function P(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function I(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(N,this),this.reset(!0)}function T(e){if(e||""===e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}throw new TypeError(C(e)+" is not iterable")}return g.prototype=b,o(x,"constructor",{value:b,configurable:!0}),o(b,"constructor",{value:g,configurable:!0}),g.displayName=u(b,l,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,b):(t.__proto__=b,u(t,l,"GeneratorFunction")),t.prototype=Object.create(x),t},e.awrap=function(t){return{__await:t}},L(j.prototype),u(j.prototype,c,(function(){return this})),e.AsyncIterator=j,e.async=function(t,r,n,o,a){void 0===a&&(a=Promise);var i=new j(s(t,r,n,o),a);return e.isGeneratorFunction(r)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},L(x),u(x,l,"Generator"),u(x,i,(function(){return this})),u(x,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=T,I.prototype={constructor:I,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(P),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(l&&u){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(l){if(this.prev<i.catchLoc)return o(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,m):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),P(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;P(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:T(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function P(t,e,r){return(e=function(t){var e=function(t,e){if("object"!==C(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,"string");if("object"!==C(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===C(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var I={k12:"Primary & Secondary"},T={england:"ENG",scotland:"SCT",wales:"WLS","northern ireland":"NIR"},_=P(P({},k.X.Auth,"auth.web"),k.X.Lite,"lite.web"),U={getClient:function(t){var e,r,n,o,a,i;return n=this,o=void 0,a=void 0,i=A().mark((function n(){var o,a,i,c,l,u;return A().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return o=t.brazeConfig,a=t.geoLocation,i=t.version,c=o[g.I.getInstanceRegion(null==a?void 0:a.countryCode)],l=_[t.productName],u=(0,x.getInstance)({baseUrl:c.url,apiKey:c.apiKey,productVersion:i,productName:l,enableLogging:!1,automaticallyShowInAppMessages:!1}),(null===(e=t.geoLocation)||void 0===e?void 0:e.countryCode)&&u.setUserCountry(null===(r=t.geoLocation)||void 0===r?void 0:r.countryCode),n.abrupt("return",u);case 6:case"end":return n.stop()}}),n)})),new(a||(a=Promise))((function(t,e){function r(t){try{l(i.next(t))}catch(t){e(t)}}function c(t){try{l(i.throw(t))}catch(t){e(t)}}function l(e){var n;e.done?t(e.value):(n=e.value,n instanceof a?n:new a((function(t){t(n)}))).then(r,c)}l((i=i.apply(n,o||[])).next())}))},hashedEmail:function(t){var e=t.trim().toLowerCase();return j().hash(e)},removeEmptyKeys:function(t){if(Array.isArray(t))return t;var e=Object.assign({},t);return Object.entries(e).filter((function(t){var e=O(t,2)[1];return null!=e&&!("string"==typeof e&&!e.length)})).reduce((function(t,e){var r=O(e,2),n=r[0],o=r[1];return Object.assign(Object.assign({},t),P({},n,o===Object(o)?U.removeEmptyKeys(o):o))}),{})},getEventTopic:function(){return"Free Trial Request"},getCustomEventType:function(){return x.ProductFormEvent.ProductTrailRequested},getProductFormEventType:function(){return"product_form_submission"},getSchoolType:function(t){if(t){var e=t.toLowerCase();if(!["unknown","other"].includes(e))return I[e]||t}},parseProvince:function(t){return t.length?T[t.toLowerCase()]||t:""}};function F(t){return F="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},F(t)}function G(){G=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var a=e&&e.prototype instanceof v?e:v,i=Object.create(a.prototype),c=new A(n||[]);return o(i,"_invoke",{value:k(t,r,c)}),i}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var p="suspendedStart",h="suspendedYield",d="executing",y="completed",m={};function v(){}function g(){}function b(){}var w={};u(w,i,(function(){return this}));var E=Object.getPrototypeOf,S=E&&E(E(P([])));S&&S!==r&&n.call(S,i)&&(w=S);var x=b.prototype=v.prototype=Object.create(w);function L(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function r(o,a,i,c){var l=f(t[o],t,a);if("throw"!==l.type){var u=l.arg,s=u.value;return s&&"object"==F(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,i,c)}),(function(t){r("throw",t,i,c)})):e.resolve(s).then((function(t){u.value=t,i(u)}),(function(t){return r("throw",t,i,c)}))}c(l.arg)}var a;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return a=a?a.then(o,o):o()}})}function k(e,r,n){var o=p;return function(a,i){if(o===d)throw new Error("Generator is already running");if(o===y){if("throw"===a)throw i;return{value:t,done:!0}}for(n.method=a,n.arg=i;;){var c=n.delegate;if(c){var l=C(c,n);if(l){if(l===m)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=y,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var u=f(e,r,n);if("normal"===u.type){if(o=n.done?y:h,u.arg===m)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(o=y,n.method="throw",n.arg=u.arg)}}}function C(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,C(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var a=f(o,e.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,m;var i=a.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function O(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function N(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function A(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(O,this),this.reset(!0)}function P(e){if(e||""===e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}throw new TypeError(F(e)+" is not iterable")}return g.prototype=b,o(x,"constructor",{value:b,configurable:!0}),o(b,"constructor",{value:g,configurable:!0}),g.displayName=u(b,l,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,b):(t.__proto__=b,u(t,l,"GeneratorFunction")),t.prototype=Object.create(x),t},e.awrap=function(t){return{__await:t}},L(j.prototype),u(j.prototype,c,(function(){return this})),e.AsyncIterator=j,e.async=function(t,r,n,o,a){void 0===a&&(a=Promise);var i=new j(s(t,r,n,o),a);return e.isGeneratorFunction(r)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},L(x),u(x,l,"Generator"),u(x,i,(function(){return this})),u(x,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=P,A.prototype={constructor:A,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(N),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(l&&u){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(l){if(this.prev<i.catchLoc)return o(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,m):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),N(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;N(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:P(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function D(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return R(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?R(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function R(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}var M=255,K=/\$+[\w\s]?/,Y=/^\+?\d{4,255}$/;function z(t){if(!t)return{firstName:"",surname:""};var e=t.split(" ").filter((function(t){return t.length}));return{firstName:e.shift(),surname:e.join(" ")}}var q=r(65858),V=r(45157),B=function t(e,r){if(e===r)return!0;if(e&&r&&"object"==typeof e&&"object"==typeof r){if(e.constructor!==r.constructor)return!1;var n,o,a;if(Array.isArray(e)){if((n=e.length)!=r.length)return!1;for(o=n;0!=o--;)if(!t(e[o],r[o]))return!1;return!0}if(e.constructor===RegExp)return e.source===r.source&&e.flags===r.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===r.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===r.toString();if((n=(a=Object.keys(e)).length)!==Object.keys(r).length)return!1;for(o=n;0!=o--;)if(!Object.prototype.hasOwnProperty.call(r,a[o]))return!1;for(o=n;0!=o--;){var i=a[o];if(!t(e[i],r[i]))return!1}return!0}return e!=e&&r!=r};const $="__googleMapsScriptId";var H;!function(t){t[t.INITIALIZED=0]="INITIALIZED",t[t.LOADING=1]="LOADING",t[t.SUCCESS=2]="SUCCESS",t[t.FAILURE=3]="FAILURE"}(H||(H={}));class Z{constructor({apiKey:t,authReferrerPolicy:e,channel:r,client:n,id:o=$,language:a,libraries:i=[],mapIds:c,nonce:l,region:u,retries:s=3,url:f="https://maps.googleapis.com/maps/api/js",version:p}){if(this.CALLBACK="__googleMapsCallback",this.callbacks=[],this.done=!1,this.loading=!1,this.errors=[],this.apiKey=t,this.authReferrerPolicy=e,this.channel=r,this.client=n,this.id=o||$,this.language=a,this.libraries=i,this.mapIds=c,this.nonce=l,this.region=u,this.retries=s,this.url=f,this.version=p,Z.instance){if(!B(this.options,Z.instance.options))throw new Error(`Loader must not be called again with different options. ${JSON.stringify(this.options)} !== ${JSON.stringify(Z.instance.options)}`);return Z.instance}Z.instance=this}get options(){return{version:this.version,apiKey:this.apiKey,channel:this.channel,client:this.client,id:this.id,libraries:this.libraries,language:this.language,region:this.region,mapIds:this.mapIds,nonce:this.nonce,url:this.url,authReferrerPolicy:this.authReferrerPolicy}}get status(){return this.errors.length?H.FAILURE:this.done?H.SUCCESS:this.loading?H.LOADING:H.INITIALIZED}get failed(){return this.done&&!this.loading&&this.errors.length>=this.retries+1}createUrl(){let t=this.url;return t+=`?callback=${this.CALLBACK}`,this.apiKey&&(t+=`&key=${this.apiKey}`),this.channel&&(t+=`&channel=${this.channel}`),this.client&&(t+=`&client=${this.client}`),this.libraries.length>0&&(t+=`&libraries=${this.libraries.join(",")}`),this.language&&(t+=`&language=${this.language}`),this.region&&(t+=`&region=${this.region}`),this.version&&(t+=`&v=${this.version}`),this.mapIds&&(t+=`&map_ids=${this.mapIds.join(",")}`),this.authReferrerPolicy&&(t+=`&auth_referrer_policy=${this.authReferrerPolicy}`),t}deleteScript(){const t=document.getElementById(this.id);t&&t.remove()}load(){return this.loadPromise()}loadPromise(){return new Promise(((t,e)=>{this.loadCallback((r=>{r?e(r.error):t(window.google)}))}))}loadCallback(t){this.callbacks.push(t),this.execute()}setScript(){if(document.getElementById(this.id))return void this.callback();const t=this.createUrl(),e=document.createElement("script");e.id=this.id,e.type="text/javascript",e.src=t,e.onerror=this.loadErrorCallback.bind(this),e.defer=!0,e.async=!0,this.nonce&&(e.nonce=this.nonce),document.head.appendChild(e)}reset(){this.deleteScript(),this.done=!1,this.loading=!1,this.errors=[],this.onerrorEvent=null}resetIfRetryingFailed(){this.failed&&this.reset()}loadErrorCallback(t){if(this.errors.push(t),this.errors.length<=this.retries){const t=this.errors.length*Math.pow(2,this.errors.length);console.log(`Failed to load Google Maps script, retrying in ${t} ms.`),setTimeout((()=>{this.deleteScript(),this.setScript()}),t)}else this.onerrorEvent=t,this.callback()}setCallback(){window.__googleMapsCallback=this.callback.bind(this)}callback(){this.done=!0,this.loading=!1,this.callbacks.forEach((t=>{t(this.onerrorEvent)})),this.callbacks=[]}execute(){if(this.resetIfRetryingFailed(),this.done)this.callback();else{if(window.google&&window.google.maps&&window.google.maps.version)return console.warn("Google Maps already loaded outside @googlemaps/js-api-loader.This may result in undesirable behavior as options and script parameters may not match."),void this.callback();this.loading||(this.loading=!0,this.setCallback(),this.setScript())}}}function J(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return W(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?W(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function W(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function X(t){return new Z({apiKey:t.apiKey,version:"weekly",libraries:t.libraries,retries:3})}function Q(t){var e={apiKey:t.apiKey,libraries:t.libraries||["places"]},r=J(n.useState(!1),2),o=r[0],a=r[1],i=J(n.useState(X(e)),2),c=i[0],l=i[1];function u(t,r){c?c.loadCallback((function(e){if(e)return a(!1),void(r&&r(e));a(!0),t&&t()})):l(X(e))}return n.useEffect((function(){u()}),[]),{loader:c,scriptLoaded:o,onGoogleApiReady:u}}function tt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function et(t){var e,r,o=Q({apiKey:t.googleApiKey}).scriptLoaded,a=(e=n.useState(),r=2,function(t){if(Array.isArray(t))return t}(e)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(e,r)||function(t,e){if(t){if("string"==typeof t)return tt(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?tt(t,e):void 0}}(e,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),i=a[0],c=a[1];return n.useEffect((function(){o&&c(new google.maps.places.AutocompleteService)}),[o]),i}function rt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}var nt="us",ot="country:placeholder:text";function at(t){var e,r,a=t.apiKey,i=t.geoLocation,c=t.makeRequest,l=void 0===c||c,u=t.template,s=void 0===u?"E.g. [placeholder]":u,f=t.templateKey,p=void 0===f?"[placeholder]":f,h=et({googleApiKey:a}),d=n.useState((function(){return function(t){var e=g.I.getLocalizedLocalityPlaceholderText(null==t?void 0:t.countryCode);return e||(o.SG.cacheGet("".concat(ot,":").concat(null==t?void 0:t.countryCode))||void 0)}(i)})),y=(r=2,function(t){if(Array.isArray(t))return t}(e=d)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(e,r)||function(t,e){if(t){if("string"==typeof t)return rt(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?rt(t,e):void 0}}(e,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),m=y[0],v=y[1];function b(t,e){o.SG.cacheSet("".concat(ot,":").concat(e),t,86400),v(t)}return n.useEffect((function(){if(!m&&h&&l){var t=(null==i?void 0:i.countryCode)||nt,e={input:String.fromCharCode(96+V.Y.getRandomInt(26)),types:["(cities)"],region:t,componentRestrictions:{country:t}};h.getPlacePredictions(e,(function(e,r){return function(t,e,r){if(e===google.maps.places.PlacesServiceStatus.OK&&t){var n=t[V.Y.getRandomInt(t.length)].description;b(s.replace(p,n),r)}else b(g.I.getLocalizedLocalityPlaceholderText(nt),r)}(e,r,t)}))}}),[m,h,i,l]),m}function it(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function ct(t){var e,r,o=(e=n.useState(0),r=2,function(t){if(Array.isArray(t))return t}(e)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(e,r)||function(t,e){if(t){if("string"==typeof t)return it(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?it(t,e):void 0}}(e,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),a=o[0],i=o[1],c=n.useRef();function l(){var t;c.current&&(null===(t=c.current.children[a-1])||void 0===t||t.scrollIntoView({block:"center"}))}return{selectedIndex:a,onKeyDown:function(e){if("ArrowDown"===e.code){e.stopPropagation(),e.preventDefault();var r=a+1;return r>t.itemCount&&(r=1),i(r),void l()}if("ArrowUp"===e.code){e.stopPropagation(),e.preventDefault();var n=a-1;return n<=0&&(n=t.itemCount),i(n),void l()}if("Enter"===e.code&&a>0)return e.stopPropagation(),e.preventDefault(),void t.onSelected(a-1);i(0)},containerRef:c}}function lt(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=function(t,e){if(t){if("string"==typeof t)return ut(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?ut(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,o=function(){};return{s:o,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,i=!0,c=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return i=t.done,t},e:function(t){c=!0,a=t},f:function(){try{i||null==r.return||r.return()}finally{if(c)throw a}}}}function ut(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}var st=function(t){var e,r,n,o,a,i=t.formatted_address,c=lt(t.address_components);try{for(c.s();!(a=c.n()).done;){var l,u=a.value,s=lt(u.types);try{for(s.s();!(l=s.n()).done;){var f=l.value;"locality"===f&&(e=u.short_name),"administrative_area_level_1"===f&&(r=u.short_name),"postal_code"===f&&(o=u.short_name),"country"===f&&(n=u.short_name)}}catch(t){s.e(t)}finally{s.f()}}}catch(t){c.e(t)}finally{c.f()}return{locality:i,country:n,postalCode:o,city:e,province:r}};function ft(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}var pt={1:"geocoderPermissionDenied",2:"geocoderUnavailable",3:"geocoderTimeout"},ht=r(28329);function dt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}var yt=r(11607);function mt(){return n.createElement("svg",{viewBox:"0 0 24 24"},n.createElement("path",{d:"m12.00559,20.40189c4.60881,0 8.37242,-3.78424 8.37242,-8.40189c0,-4.61764 -3.76361,-8.40187 -8.37242,-8.40187c-4.62002,0 -8.38365,3.78422 -8.38365,8.40187c0,4.61765 3.76364,8.40189 8.38365,8.40189zm0,-1.65557c-3.75235,0 -6.67085,-2.96208 -6.67085,-6.74632c0,-3.7842 2.91851,-6.74625 6.67085,-6.74625c3.74105,0 6.67084,2.96206 6.67084,6.74625c0,3.78424 -2.92978,6.74632 -6.67084,6.74632zm-10.14151,-6.02552l6.01731,0c0.40566,0 0.72118,-0.31536 0.72118,-0.7208c0,-0.40544 -0.31552,-0.7208 -0.72118,-0.7208l-6.01731,0c-0.40566,0 -0.72117,0.31536 -0.72117,0.7208c0,0.40544 0.31551,0.7208 0.72118,0.7208l-0.00001,0zm14.25442,0l6.0174,0c0.40565,0 0.72118,-0.31536 0.72118,-0.7208c0,-0.40544 -0.31553,-0.7208 -0.72118,-0.7208l-6.0174,0c-0.40565,0 -0.72118,0.31536 -0.72118,0.7208c0,0.40544 0.31553,0.7208 0.72118,0.7208zm-4.12417,-4.1221c0.40566,0 0.72118,-0.31534 0.72118,-0.70952l0,-6.02547c0,-0.40544 -0.31552,-0.7208 -0.72118,-0.7208c-0.3944,0 -0.7099,0.31536 -0.7099,0.7208l0,6.02547c0,0.39418 0.31551,0.70952 0.7099,0.70952zm0,14.25838c0.40566,0 0.72118,-0.3154 0.72118,-0.72077l0,-6.02541c0,-0.39425 -0.31552,-0.70965 -0.72118,-0.70965c-0.3944,0 -0.7099,0.3154 -0.7099,0.70965l0,6.02541c0,0.40538 0.31551,0.72077 0.7099,0.72077z"}))}const vt={baseText:"KL3Q_",inputFocused:"I6wQy",input:"ChY5L",suggestionContainer:"Y78ea",noBottomBorder:"IeYUw",localitySuggestion:"P3aHR",suggestionItem:"magL7",suggestionLoading:"W7rH_",noSuggestion:"XXSnS",selected:"snnHR"};function gt(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return bt(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?bt(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function bt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function wt(t){var e=t.predictions,r=t.getPlaceInfo,o=t.selectedIndex;return n.createElement(n.Fragment,null,e.map((function(t,e){return n.createElement(yt.L,{className:"".concat(vt.suggestionItem," ").concat(o-1===e?vt.selected:""),key:t.place_id,onClick:function(){return r(t)}},t.description)})))}function Et(t){var e,r,o,a,i,l,u=n.useRef(),s=gt(n.useState((null===(e=t.data)||void 0===e?void 0:e.schoolLocality)||""),2),f=s[0],p=s[1],h=gt(n.useState(!1),2),d=h[0],y=h[1],m=at({apiKey:t.googleMapsApiKey,geoLocation:t.geoLocation}),v=function(t){var e,r,o=t.search,a=t.makePredicition,i=t.geoLocation,c=et({googleApiKey:t.apiKey}),l=(0,ht.N)(o,300),u=(e=n.useState(),r=2,function(t){if(Array.isArray(t))return t}(e)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(e,r)||function(t,e){if(t){if("string"==typeof t)return dt(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?dt(t,e):void 0}}(e,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),s=u[0],f=u[1];function p(t,e){e===google.maps.places.PlacesServiceStatus.OK&&t?f(t):f(void 0)}return n.useEffect((function(){if(c)if(0!==(null==l?void 0:l.length)&&a){var t=(null==i?void 0:i.countryCode)||"us";c.getPlacePredictions({input:l,componentRestrictions:(null==i?void 0:i.isFallback)?void 0:{country:t},region:t,types:["locality","sublocality","postal_code"]},p)}else f(void 0)}),[l,a,c]),{localityPredicitions:s,getPlaceInfo:function(t,e,r){new google.maps.places.PlacesService(e.current).getDetails({placeId:t.place_id,fields:["geometry","address_components","formatted_address"],region:i.countryCode},(function(t,e){if(e===google.maps.places.PlacesServiceStatus.OK){var n=t.geometry.location.lng(),o=t.geometry.location.lat(),a=st(t),i=a.locality,c=a.country,l=a.postalCode,u=a.city,s=a.province;r({longitude:n,latitude:o,locality:i,country:c,city:u,postalCode:l,province:s})}}))}}}({search:f,makePredicition:d,geoLocation:t.geoLocation,apiKey:t.googleMapsApiKey}),g=v.localityPredicitions,b=v.getPlaceInfo,w=function(t){var e,r,o=(e=n.useState({}),r=2,function(t){if(Array.isArray(t))return t}(e)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(e,r)||function(t,e){if(t){if("string"==typeof t)return ft(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?ft(t,e):void 0}}(e,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),a=o[0],i=o[1],c=Q(t).onGoogleApiReady;function l(t){var e=t.coords,r=e.latitude,n=e.longitude,o=new google.maps.LatLng(r,n);(new google.maps.Geocoder).geocode({location:o},(function(t,e){if(e===google.maps.GeocoderStatus.OK){var o=t.find((function(t){return t.types.includes("locality")||t.types.includes("administrative_area_level_2")})),a=st(o);i(Object.assign(Object.assign({},a),{longitude:n,latitude:r}))}}))}function u(e){var r=pt[e.code];r||(r="geocoderUnknown"),t.onPositionError("We are unable to access your location. Please try again later.")}return{placeDetails:a,onClickGetCurrentLocation:function(){c((function(){window.navigator.geolocation.getCurrentPosition(l,u)}))}}}({apiKey:t.googleMapsApiKey,onPositionError:function(t){y(!0),A(t)}}),E=w.placeDetails,S=w.onClickGetCurrentLocation,x=window.navigator.geolocation?1:0,L=ct({onSelected:function(t){if(g)if(t!==g.length){var e=g[t];e&&T(e)}else _()},itemCount:null!==(r=(null==g?void 0:g.length)+x)&&void 0!==r?r:0}),j=L.selectedIndex,k=L.onKeyDown,C=L.containerRef,O=gt(n.useState(),2),N=O[0],A=O[1];function P(e){var r,n,o;N&&A(void 0),d||y(!0),((null===(r=t.data)||void 0===r?void 0:r.longitude)||(null===(n=t.data)||void 0===n?void 0:n.latitude)||(null===(o=t.data)||void 0===o?void 0:o.schoolLocality))&&t.clearStepGroupData(),p(e)}function I(e){var r=e.longitude,n=e.latitude,o=e.locality,a=e.country,i=e.city,c=e.province;r&&t.setDataProperty("longitude",r),n&&t.setDataProperty("latitude",n),a&&t.setDataProperty("country",a),i&&t.setDataProperty("city",i),c&&t.setDataProperty("province",c),o&&function(e){t.setDataProperty("schoolLocality",e),p(e)}(o)}function T(t){d&&y(!1),b(t,u,I)}function _(e){null==e||e.preventDefault(),y(!1),S(),t.logUserAction({},{actionType:q.Vw.Click,descriptor:q.Yu.UseMyLocation})}n.useEffect((function(){I(E)}),[E]);var U,F=(null==g?void 0:g.length)&&!(null===(a=null===(o=t.data)||void 0===o?void 0:o.schoolLocality)||void 0===a?void 0:a.length),G=window.navigator.geolocation&&!(null===(l=null===(i=t.data)||void 0===i?void 0:i.schoolLocality)||void 0===l?void 0:l.length),D=t.labelClassName||"d-block text-center mb-3 fw-normal ".concat(vt.baseText);return n.createElement("div",{className:"form-group position-relative"},n.createElement("label",{className:D,htmlFor:"locality-input"},"Postcode or suburb:"),n.createElement(c.w,{type:"text",value:f,onChange:function(t){return P(t.currentTarget.value)},id:"locality-input",className:(U="form-control form-control-lg",F?"".concat(U," ").concat(vt.inputFocused):"".concat(U," ").concat(vt.input)),ref:u,autoComplete:"off",placeholder:m||"Loading...",disabled:t.disabled||!m,autoFocus:null==t?void 0:t.autoFocus,onClickClear:function(){P(""),u.current.focus()},onKeyDown:k}),n.createElement("div",{className:"position-absolute w-100"},!!F&&n.createElement("div",{className:"".concat(vt.suggestionContainer," ").concat(vt.localitySuggestion),ref:C},n.createElement(wt,{predictions:g,getPlaceInfo:T,selectedIndex:j}),window.navigator.geolocation&&n.createElement(yt.L,{className:"".concat(vt.suggestionItem," px-1 ").concat(j-1===g.length?vt.selected:""),onClick:_},n.createElement("div",{className:"btn btn-link info-link btn-with-icon bg-transparent py-0 pe-1"},n.createElement(mt,null),"Use my current location"))),G&&!F&&n.createElement("div",{className:"d-flex"},n.createElement("button",{onClick:_,className:"btn btn-link info-link bg-white btn-with-icon"},n.createElement(mt,null),"Use my current location")),!!N&&n.createElement("div",{className:"text-danger p-2"},N)))}var St=r(99940);function xt(t){return xt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},xt(t)}function Lt(t){var e="function"==typeof Map?new Map:void 0;return Lt=function(t){if(null===t||!function(t){try{return-1!==Function.toString.call(t).indexOf("[native code]")}catch(e){return"function"==typeof t}}(t))return t;if("function"!=typeof t)throw new TypeError("Super expression must either be null or a function");if(void 0!==e){if(e.has(t))return e.get(t);e.set(t,r)}function r(){return jt(t,arguments,Ot(this).constructor)}return r.prototype=Object.create(t.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),Ct(r,t)},Lt(t)}function jt(t,e,r){return jt=kt()?Reflect.construct.bind():function(t,e,r){var n=[null];n.push.apply(n,e);var o=new(Function.bind.apply(t,n));return r&&Ct(o,r.prototype),o},jt.apply(null,arguments)}function kt(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function Ct(t,e){return Ct=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},Ct(t,e)}function Ot(t){return Ot=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},Ot(t)}var Nt=function(t){!function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ct(t,e)}(a,t);var e,r,n,o=(r=a,n=kt(),function(){var t,e=Ot(r);if(n){var o=Ot(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(t,e){if(e&&("object"===xt(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(this,t)});function a(t){var e,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"Error";return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,a),(e=o.call(this,r)).body=t,e}return e=a,Object.defineProperty(e,"prototype",{writable:!1}),e}(Lt(Error));function At(t){return At="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},At(t)}function Pt(){Pt=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var a=e&&e.prototype instanceof v?e:v,i=Object.create(a.prototype),c=new A(n||[]);return o(i,"_invoke",{value:k(t,r,c)}),i}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var p="suspendedStart",h="suspendedYield",d="executing",y="completed",m={};function v(){}function g(){}function b(){}var w={};u(w,i,(function(){return this}));var E=Object.getPrototypeOf,S=E&&E(E(P([])));S&&S!==r&&n.call(S,i)&&(w=S);var x=b.prototype=v.prototype=Object.create(w);function L(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function r(o,a,i,c){var l=f(t[o],t,a);if("throw"!==l.type){var u=l.arg,s=u.value;return s&&"object"==At(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,i,c)}),(function(t){r("throw",t,i,c)})):e.resolve(s).then((function(t){u.value=t,i(u)}),(function(t){return r("throw",t,i,c)}))}c(l.arg)}var a;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return a=a?a.then(o,o):o()}})}function k(e,r,n){var o=p;return function(a,i){if(o===d)throw new Error("Generator is already running");if(o===y){if("throw"===a)throw i;return{value:t,done:!0}}for(n.method=a,n.arg=i;;){var c=n.delegate;if(c){var l=C(c,n);if(l){if(l===m)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=y,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var u=f(e,r,n);if("normal"===u.type){if(o=n.done?y:h,u.arg===m)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(o=y,n.method="throw",n.arg=u.arg)}}}function C(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,C(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var a=f(o,e.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,m;var i=a.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function O(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function N(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function A(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(O,this),this.reset(!0)}function P(e){if(e||""===e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}throw new TypeError(At(e)+" is not iterable")}return g.prototype=b,o(x,"constructor",{value:b,configurable:!0}),o(b,"constructor",{value:g,configurable:!0}),g.displayName=u(b,l,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,b):(t.__proto__=b,u(t,l,"GeneratorFunction")),t.prototype=Object.create(x),t},e.awrap=function(t){return{__await:t}},L(j.prototype),u(j.prototype,c,(function(){return this})),e.AsyncIterator=j,e.async=function(t,r,n,o,a){void 0===a&&(a=Promise);var i=new j(s(t,r,n,o),a);return e.isGeneratorFunction(r)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},L(x),u(x,l,"Generator"),u(x,i,(function(){return this})),u(x,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=P,A.prototype={constructor:A,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(N),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(l&&u){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(l){if(this.prev<i.catchLoc)return o(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,m):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),N(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;N(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:P(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}var It=function(t,e,r,n){return new(r||(r=Promise))((function(o,a){function i(t){try{l(n.next(t))}catch(t){a(t)}}function c(t){try{l(n.throw(t))}catch(t){a(t)}}function l(t){var e;t.done?o(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(i,c)}l((n=n.apply(t,e||[])).next())}))};function Tt(t){var e={method:St.k.GET,headers:{"Content-type":"application/json"}};t.method&&(e=Object.assign(Object.assign({},e),{method:t.method})),t.init&&(e=Object.assign(Object.assign({},e),t.init));var r,n,o,a=t.url;return e.method===St.k.GET&&t.data?(r=a,n=t.data,o=r,Object.keys(n).forEach((function(t,e){n[t]&&(o+=0===e?"?":"&",o+="".concat(t,"=").concat(encodeURIComponent(n[t])))})),a=o):t.data&&(e=Object.assign(Object.assign({},e),{body:JSON.stringify(t.data)})),{init:e,url:a}}var _t={asyncFetch:function(t){return It(this,void 0,void 0,Pt().mark((function e(){var r,n,o;return Pt().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=Tt(t),e.next=3,fetch(r.url,r.init);case 3:if((n=e.sent).ok){e.next=9;break}return e.next=7,n.json();case 7:throw o=e.sent,new Nt(o);case 9:if(204!==n.status){e.next=11;break}return e.abrupt("return");case 11:return e.next=13,n.json();case 13:return e.abrupt("return",e.sent);case 14:case"end":return e.stop()}}),e)})))},asyncFetchPlain:function(t){return It(this,void 0,void 0,Pt().mark((function e(){var r,n;return Pt().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=Tt(t),e.next=3,fetch(r.url,r.init);case 3:if((n=e.sent).ok){e.next=6;break}return e.abrupt("return");case 6:return e.next=8,n.text();case 8:return e.abrupt("return",e.sent);case 9:case"end":return e.stop()}}),e)})))},fetch:function(t){function e(e){return t.apply(this,arguments)}return e.toString=function(){return t.toString()},e}((function(t){var e=Tt(t);return fetch(e.url,e.init).then((function(t){if(204!==t.status)return t.json()})).then((function(e){return t.success&&t.success(e),e})).catch((function(e){return t.error&&t.error(),e})).finally((function(){t.always&&t.always()}))}))};function Ut(t){return Ut="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ut(t)}function Ft(){Ft=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var a=e&&e.prototype instanceof v?e:v,i=Object.create(a.prototype),c=new A(n||[]);return o(i,"_invoke",{value:k(t,r,c)}),i}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var p="suspendedStart",h="suspendedYield",d="executing",y="completed",m={};function v(){}function g(){}function b(){}var w={};u(w,i,(function(){return this}));var E=Object.getPrototypeOf,S=E&&E(E(P([])));S&&S!==r&&n.call(S,i)&&(w=S);var x=b.prototype=v.prototype=Object.create(w);function L(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function r(o,a,i,c){var l=f(t[o],t,a);if("throw"!==l.type){var u=l.arg,s=u.value;return s&&"object"==Ut(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,i,c)}),(function(t){r("throw",t,i,c)})):e.resolve(s).then((function(t){u.value=t,i(u)}),(function(t){return r("throw",t,i,c)}))}c(l.arg)}var a;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return a=a?a.then(o,o):o()}})}function k(e,r,n){var o=p;return function(a,i){if(o===d)throw new Error("Generator is already running");if(o===y){if("throw"===a)throw i;return{value:t,done:!0}}for(n.method=a,n.arg=i;;){var c=n.delegate;if(c){var l=C(c,n);if(l){if(l===m)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=y,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var u=f(e,r,n);if("normal"===u.type){if(o=n.done?y:h,u.arg===m)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(o=y,n.method="throw",n.arg=u.arg)}}}function C(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,C(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var a=f(o,e.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,m;var i=a.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function O(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function N(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function A(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(O,this),this.reset(!0)}function P(e){if(e||""===e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}throw new TypeError(Ut(e)+" is not iterable")}return g.prototype=b,o(x,"constructor",{value:b,configurable:!0}),o(b,"constructor",{value:g,configurable:!0}),g.displayName=u(b,l,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,b):(t.__proto__=b,u(t,l,"GeneratorFunction")),t.prototype=Object.create(x),t},e.awrap=function(t){return{__await:t}},L(j.prototype),u(j.prototype,c,(function(){return this})),e.AsyncIterator=j,e.async=function(t,r,n,o,a){void 0===a&&(a=Promise);var i=new j(s(t,r,n,o),a);return e.isGeneratorFunction(r)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},L(x),u(x,l,"Generator"),u(x,i,(function(){return this})),u(x,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=P,A.prototype={constructor:A,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(N),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(l&&u){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(l){if(this.prev<i.catchLoc)return o(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,m):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),N(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;N(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:P(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}var Gt,Dt={search:function(t,e,r,n,o){var a={longitude:e.longitude,latitude:e.latitude};e.query&&(a.query=e.query),_t.fetch({url:t.searchProspect,data:a,success:r,error:n,always:o})},create:function(t,e){return r=this,n=void 0,o=void 0,a=Ft().mark((function r(){return Ft().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.abrupt("return",_t.asyncFetch({url:t.createProspect,method:St.k.POST,data:e}));case 1:case"end":return r.stop()}}),r)})),new(o||(o=Promise))((function(t,e){function i(t){try{l(a.next(t))}catch(t){e(t)}}function c(t){try{l(a.throw(t))}catch(t){e(t)}}function l(e){var r;e.done?t(e.value):(r=e.value,r instanceof o?r:new o((function(t){t(r)}))).then(i,c)}l((a=a.apply(r,n||[])).next())}));var r,n,o,a},getLookups:function(t,e){return _t.asyncFetch({url:t.prospectLookups(e)})}},Rt=r(97395),Mt=function(t,e){if(t.productName!==k.X.Lite)return Promise.reject();var r={email:e.email};return _t.asyncFetch({url:t.userStatus,data:r})},Kt=function(t,e,r,n,o){var a=t.prospectStatus(e.prospectId);a=Rt._.urlBuilder(a,{email:e.email}),_t.fetch({url:a,success:r,error:n,always:o})},Yt=function(t,e){var r={prospectId:e.prospectId,firstName:"Trial",surname:"User",email:e.email,userType:e.userType,accessPolicy:e.accessPolicy,appLink:null==e?void 0:e.appLink};return _t.asyncFetch({url:t.createTrial,method:St.k.POST,data:r})},zt=function(t,e,r){if(t.productName!==k.X.Lite)return Promise.reject();var n={email:r.email,appLink:null==r?void 0:r.appLink};return _t.asyncFetch({url:t.resendTrialEmail(e),method:St.k.POST,data:n})},qt=function(t,e){var r=t.productName===k.X.Auth?t.joinRequest:t.joinRequest(e.customerId),n=t.productName===k.X.Auth?e:{email:e.email};return _t.asyncFetch({url:r,method:St.k.POST,data:n})},Vt=function(t,e){return t.productName!==k.X.Lite?Promise.reject():_t.asyncFetch({url:t.autoJoin,method:St.k.POST,data:e})};!function(t){t.FourteenDays="trial_14_v1",t.Freemium="freemium_v1"}(Gt||(Gt={}));var Bt=function(t){return g.I.isCountryCodeUS(t)||g.I.isCountryCodeUK(t)?Gt.Freemium:Gt.FourteenDays},$t=r(99504);function Ht(t){return Ht="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ht(t)}function Zt(){Zt=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var a=e&&e.prototype instanceof v?e:v,i=Object.create(a.prototype),c=new A(n||[]);return o(i,"_invoke",{value:k(t,r,c)}),i}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var p="suspendedStart",h="suspendedYield",d="executing",y="completed",m={};function v(){}function g(){}function b(){}var w={};u(w,i,(function(){return this}));var E=Object.getPrototypeOf,S=E&&E(E(P([])));S&&S!==r&&n.call(S,i)&&(w=S);var x=b.prototype=v.prototype=Object.create(w);function L(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function r(o,a,i,c){var l=f(t[o],t,a);if("throw"!==l.type){var u=l.arg,s=u.value;return s&&"object"==Ht(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,i,c)}),(function(t){r("throw",t,i,c)})):e.resolve(s).then((function(t){u.value=t,i(u)}),(function(t){return r("throw",t,i,c)}))}c(l.arg)}var a;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return a=a?a.then(o,o):o()}})}function k(e,r,n){var o=p;return function(a,i){if(o===d)throw new Error("Generator is already running");if(o===y){if("throw"===a)throw i;return{value:t,done:!0}}for(n.method=a,n.arg=i;;){var c=n.delegate;if(c){var l=C(c,n);if(l){if(l===m)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=y,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var u=f(e,r,n);if("normal"===u.type){if(o=n.done?y:h,u.arg===m)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(o=y,n.method="throw",n.arg=u.arg)}}}function C(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,C(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var a=f(o,e.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,m;var i=a.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function O(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function N(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function A(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(O,this),this.reset(!0)}function P(e){if(e||""===e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}throw new TypeError(Ht(e)+" is not iterable")}return g.prototype=b,o(x,"constructor",{value:b,configurable:!0}),o(b,"constructor",{value:g,configurable:!0}),g.displayName=u(b,l,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,b):(t.__proto__=b,u(t,l,"GeneratorFunction")),t.prototype=Object.create(x),t},e.awrap=function(t){return{__await:t}},L(j.prototype),u(j.prototype,c,(function(){return this})),e.AsyncIterator=j,e.async=function(t,r,n,o,a){void 0===a&&(a=Promise);var i=new j(s(t,r,n,o),a);return e.isGeneratorFunction(r)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},L(x),u(x,l,"Generator"),u(x,i,(function(){return this})),u(x,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=P,A.prototype={constructor:A,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(N),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(l&&u){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(l){if(this.prev<i.catchLoc)return o(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,m):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),N(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;N(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:P(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function Jt(t){var e=$t.F.getUtmParameters(),r={prospect_id:null==t?void 0:t.prospectId,email:null==t?void 0:t.email,organisation_sub_type:U.getSchoolType(null==t?void 0:t.schoolType),account_name:null==t?void 0:t.schoolName,account_post_code:null==t?void 0:t.schoolPostCode,account_country:null==t?void 0:t.country,province:null==t?void 0:t.province,sync_to_crm:!0,form_type:null==t?void 0:t.form_type,utms:e};return U.removeEmptyKeys(r)}var Wt,Xt={submitFormEvent:function(t,e,r,n){return o=this,a=void 0,i=void 0,c=Zt().mark((function o(){var a,i;return Zt().wrap((function(o){for(;;)switch(o.prev=o.next){case 0:return o.next=2,U.getClient({brazeConfig:t.brazeConfig,productName:t.productName,geoLocation:t.geoLocation,version:t.version});case 2:a=o.sent,i=Jt(Object.assign(Object.assign({},r),{form_type:e})),a.openSession(),a.setUser(U.hashedEmail(null==r?void 0:r.email)),a.logEvent({type:U.getProductFormEventType(),data:i}),a.sendData(n);case 8:case"end":return o.stop()}}),o)})),new(i||(i=Promise))((function(t,e){function r(t){try{l(c.next(t))}catch(t){e(t)}}function n(t){try{l(c.throw(t))}catch(t){e(t)}}function l(e){var o;e.done?t(e.value):(o=e.value,o instanceof i?o:new i((function(t){t(o)}))).then(r,n)}l((c=c.apply(o,a||[])).next())}));var o,a,i,c}},Qt=["Primary","Secondary","K12","Special","TAFE","University"],te=["Elementary","Middle School","High School","College","Other"],ee={au:Qt,nz:Qt,uk:["Primary","Secondary","Primary & Secondary","Special","Sixth Form College","FE College","University","Other"],us:te};function re(t){return re="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},re(t)}function ne(){ne=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var a=e&&e.prototype instanceof v?e:v,i=Object.create(a.prototype),c=new A(n||[]);return o(i,"_invoke",{value:k(t,r,c)}),i}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var p="suspendedStart",h="suspendedYield",d="executing",y="completed",m={};function v(){}function g(){}function b(){}var w={};u(w,i,(function(){return this}));var E=Object.getPrototypeOf,S=E&&E(E(P([])));S&&S!==r&&n.call(S,i)&&(w=S);var x=b.prototype=v.prototype=Object.create(w);function L(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function r(o,a,i,c){var l=f(t[o],t,a);if("throw"!==l.type){var u=l.arg,s=u.value;return s&&"object"==re(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,i,c)}),(function(t){r("throw",t,i,c)})):e.resolve(s).then((function(t){u.value=t,i(u)}),(function(t){return r("throw",t,i,c)}))}c(l.arg)}var a;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return a=a?a.then(o,o):o()}})}function k(e,r,n){var o=p;return function(a,i){if(o===d)throw new Error("Generator is already running");if(o===y){if("throw"===a)throw i;return{value:t,done:!0}}for(n.method=a,n.arg=i;;){var c=n.delegate;if(c){var l=C(c,n);if(l){if(l===m)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=y,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var u=f(e,r,n);if("normal"===u.type){if(o=n.done?y:h,u.arg===m)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(o=y,n.method="throw",n.arg=u.arg)}}}function C(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,C(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var a=f(o,e.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,m;var i=a.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function O(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function N(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function A(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(O,this),this.reset(!0)}function P(e){if(e||""===e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}throw new TypeError(re(e)+" is not iterable")}return g.prototype=b,o(x,"constructor",{value:b,configurable:!0}),o(b,"constructor",{value:g,configurable:!0}),g.displayName=u(b,l,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,b):(t.__proto__=b,u(t,l,"GeneratorFunction")),t.prototype=Object.create(x),t},e.awrap=function(t){return{__await:t}},L(j.prototype),u(j.prototype,c,(function(){return this})),e.AsyncIterator=j,e.async=function(t,r,n,o,a){void 0===a&&(a=Promise);var i=new j(s(t,r,n,o),a);return e.isGeneratorFunction(r)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},L(x),u(x,l,"Generator"),u(x,i,(function(){return this})),u(x,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=P,A.prototype={constructor:A,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(N),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(l&&u){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(l){if(this.prev<i.catchLoc)return o(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,m):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),N(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;N(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:P(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function oe(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return ae(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?ae(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ae(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}!function(t){t.Published="Published",t.Draft="Draft"}(Wt||(Wt={}));var ie=function(t,e,r,n){return new(r||(r=Promise))((function(o,a){function i(t){try{l(n.next(t))}catch(t){a(t)}}function c(t){try{l(n.throw(t))}catch(t){a(t)}}function l(t){var e;t.done?o(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(i,c)}l((n=n.apply(t,e||[])).next())}))};function ce(t,e){return e?"".concat(t," ").concat(e):t}var le=function(t){return n.createElement("h1",{className:ce("text-center mb-2 h4",t.className)},t.children)},ue=function(t){return n.createElement("div",{className:ce("text-center text-sm px-2 px-lg-4",t.className)},t.children)},se=function(t){return n.createElement("p",{className:ce("",t.className)},t.children)};function fe(t){return fe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},fe(t)}function pe(t,e,r){return(e=function(t){var e=function(t,e){if("object"!==fe(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,"string");if("object"!==fe(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===fe(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function he(t){var e=pe(pe(pe(pe(pe(pe(pe(pe({},y.Available,t.imageUrls.statusImages.available),y.Active,t.imageUrls.statusImages.active),y.Expired,t.imageUrls.statusImages.expired),y.NotRequired,t.imageUrls.statusImages.notRequired),y.Unavailable,t.imageUrls.statusImages.unavailable),y.Unsupported,t.imageUrls.statusImages.unsupported),y.UserAutoJoinAllowed,t.imageUrls.statusImages.notRequired),y.UserJoinApprovalRequired,t.imageUrls.statusImages.notRequired);return n.createElement("div",{className:"d-flex justify-content-center my-4 px-2 px-lg-4"},n.createElement("img",{src:e[t.trialStatus],className:"w-100 h-auto"}))}var de=r(69624);function ye(t){var e=(null==t?void 0:t.previousStepIds)&&"find-school"===t.previousStepIds[t.previousStepIds.length-1],r=(null==t?void 0:t.schoolName)||"Your school";return n.createElement(ue,{className:"mb-3"},e?n.createElement(n.Fragment,null,n.createElement(le,null,r,n.createElement("br",null),"already has ClickView 🎉"),n.createElement(se,{className:"mt-3"},"If your school has SSO ",n.createElement("a",{href:de.F.getLoginLink({email:t.email,customerId:t.customerId}),className:"info-link"},"click here to sign in.")),n.createElement(se,null,"Otherwise please contact your school admin for access.")):n.createElement(n.Fragment,null,n.createElement(le,null,"Good News!"),n.createElement(se,null,"An account already exists for:",n.createElement("br",null)," ",n.createElement("strong",null,t.email)),n.createElement(se,null,n.createElement("a",{href:de.F.getLoginLink({email:t.email}),className:"btn btn-dark btn-lg w-100"},"Sign into ClickView"))),n.createElement(se,null,"Need Help? ",n.createElement("a",{href:de.F.getSupportUrlForGeoLocation(t.geoLocation),className:"info-link",target:"_blank"},"Contact our Help Centre.")))}function me(t){return me="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},me(t)}function ve(){ve=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var a=e&&e.prototype instanceof v?e:v,i=Object.create(a.prototype),c=new A(n||[]);return o(i,"_invoke",{value:k(t,r,c)}),i}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var p="suspendedStart",h="suspendedYield",d="executing",y="completed",m={};function v(){}function g(){}function b(){}var w={};u(w,i,(function(){return this}));var E=Object.getPrototypeOf,S=E&&E(E(P([])));S&&S!==r&&n.call(S,i)&&(w=S);var x=b.prototype=v.prototype=Object.create(w);function L(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function r(o,a,i,c){var l=f(t[o],t,a);if("throw"!==l.type){var u=l.arg,s=u.value;return s&&"object"==me(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,i,c)}),(function(t){r("throw",t,i,c)})):e.resolve(s).then((function(t){u.value=t,i(u)}),(function(t){return r("throw",t,i,c)}))}c(l.arg)}var a;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return a=a?a.then(o,o):o()}})}function k(e,r,n){var o=p;return function(a,i){if(o===d)throw new Error("Generator is already running");if(o===y){if("throw"===a)throw i;return{value:t,done:!0}}for(n.method=a,n.arg=i;;){var c=n.delegate;if(c){var l=C(c,n);if(l){if(l===m)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=y,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var u=f(e,r,n);if("normal"===u.type){if(o=n.done?y:h,u.arg===m)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(o=y,n.method="throw",n.arg=u.arg)}}}function C(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,C(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var a=f(o,e.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,m;var i=a.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function O(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function N(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function A(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(O,this),this.reset(!0)}function P(e){if(e||""===e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}throw new TypeError(me(e)+" is not iterable")}return g.prototype=b,o(x,"constructor",{value:b,configurable:!0}),o(b,"constructor",{value:g,configurable:!0}),g.displayName=u(b,l,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,b):(t.__proto__=b,u(t,l,"GeneratorFunction")),t.prototype=Object.create(x),t},e.awrap=function(t){return{__await:t}},L(j.prototype),u(j.prototype,c,(function(){return this})),e.AsyncIterator=j,e.async=function(t,r,n,o,a){void 0===a&&(a=Promise);var i=new j(s(t,r,n,o),a);return e.isGeneratorFunction(r)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},L(x),u(x,l,"Generator"),u(x,i,(function(){return this})),u(x,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=P,A.prototype={constructor:A,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(N),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(l&&u){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(l){if(this.prev<i.catchLoc)return o(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,m):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),N(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;N(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:P(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function ge(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return be(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?be(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function be(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function we(t){return we="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},we(t)}function Ee(t,e,r){return(e=function(t){var e=function(t,e){if("object"!==we(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,"string");if("object"!==we(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===we(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Se=Ee(Ee(Ee(Ee(Ee(Ee(Ee(Ee({},y.Available,(function(t){var e=ge(n.useState(0),2),r=e[0],o=e[1],a=ge(n.useState(!1),2),i=a[0],c=a[1];if(null==t?void 0:t.email)return n.createElement(ue,null,n.createElement(le,null,"Success!"),n.createElement(se,null,"An email has been sent to ",n.createElement("strong",null,t.email),". Please check your email for further instructions to complete the sign up process."),!!t.userId&&n.createElement(n.Fragment,null,r<1?n.createElement(se,null,"Didn't receive an email?  ",n.createElement("button",{onClick:function(e){return n=this,a=void 0,i=void 0,l=ve().mark((function n(){return ve().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return null==e||e.preventDefault(),n.prev=1,n.next=4,zt(t.ajaxUrls,t.userId,{email:t.email,appLink:t.pageAppLinkString});case 4:o(r+1),n.next=10;break;case 7:n.prev=7,n.t0=n.catch(1),c(!0);case 10:t.logUserAction({},{actionType:q.Vw.Click,descriptor:q.Yu.ResendEmail});case 11:case"end":return n.stop()}}),n,null,[[1,7]])})),new(i||(i=Promise))((function(t,e){function r(t){try{c(l.next(t))}catch(t){e(t)}}function o(t){try{c(l.throw(t))}catch(t){e(t)}}function c(e){var n;e.done?t(e.value):(n=e.value,n instanceof i?n:new i((function(t){t(n)}))).then(r,o)}c((l=l.apply(n,a||[])).next())}));var n,a,i,l},className:"btn info-link p-0"},"Resend verification email")):"✅ Email has been resent!",i&&n.createElement(se,{className:"mb-0 text-danger"},"❌ There was a problem resending the email. Please try again later or contact our  ",n.createElement("a",{href:de.F.getSupportUrlForGeoLocation(t.geoLocation),className:"info-link"},"support"))))})),y.Active,ye),y.Expired,(function(t){var e=de.F.getMarketingSalesContactForGeoLocation(t.geoLocation),r=(null==t?void 0:t.previousStepIds)&&"find-school"===t.previousStepIds[t.previousStepIds.length-1],o=(null==t?void 0:t.schoolName)||"Your school";return n.createElement(ue,null,n.createElement(le,null,r?"".concat(o," trial has expired"):"Your trial has expired"),n.createElement(se,null,"Please contact our ",n.createElement("a",{href:e,className:"info-link",target:"_blank"},"ClickView Sales Team")))})),y.NotRequired,ye),y.Unavailable,(function(t){var e=de.F.getMarketingSalesContactForGeoLocation(t.geoLocation);return n.createElement(ue,null,n.createElement(le,null,"Your school no longer",n.createElement("br",null)," has access to ClickView"),n.createElement(se,null,"Please contact our ",n.createElement("a",{href:e,className:"info-link"},"ClickView Sales Team")," for more information."))})),y.Unsupported,(function(){return n.createElement(ue,null,n.createElement(le,{className:"px-2 px-lg-4"},"ClickView isn't currently ",n.createElement("br",null)," available for your school"),n.createElement(se,null,"We're working hard to get ClickView ready for more people."))})),y.UserAutoJoinAllowed,ye),y.UserJoinApprovalRequired,ye);function xe(t){var e=Se[t.trialStatus];return n.createElement(e,Object.assign({},t))}var Le="young-student",je={"trial-status":function(t){return n.useEffect((function(){var e={actionType:q.Vw.Create,descriptor:q.Yu.DeadEnd,workflowPhase:q.eu.Discard};t.trialCreated&&(e.descriptor=q.Yu.TrialCreated,e.workflowPhase=q.eu.Complete),t.logUserAction({},e)}),[]),n.createElement(n.Fragment,null,n.createElement(he,{trialStatus:t.trialStatus,imageUrls:t.imageUrls}),n.createElement(xe,Object.assign({},t)))},"added-to-braze":function(t){return n.useEffect((function(){t.logUserAction({},{actionType:q.Vw.Create,descriptor:q.Yu.TrialRequested,workflowPhase:q.eu.Complete})}),[]),n.createElement(n.Fragment,null,n.createElement(he,{trialStatus:y.Available,imageUrls:t.imageUrls}),n.createElement(ue,{className:"mb-3"},n.createElement(le,null,"Submitted!"),n.createElement(se,null,"Thank you for your interest in trialing ClickView. We will be in touch with you as soon as possible.")))},"young-student":function(t){var e=de.F.getFreeResourcesForGeoLocation(t.geoLocation);return n.useEffect((function(){o.SG.set(Le,!0)}),[]),n.createElement(n.Fragment,null,n.createElement(he,{trialStatus:y.Active,imageUrls:t.imageUrls}),n.createElement(ue,{className:"mb-3"},n.createElement(le,null,"Discover our free content"),n.createElement(se,null,"Click the button below to explore our videos"),n.createElement("a",{href:e,className:"btn btn-lg btn-dark w-100",target:"_blank"},"Start watching now")))},"requested-access":function(t){return n.createElement(n.Fragment,null,n.createElement(he,{trialStatus:y.Available,imageUrls:t.imageUrls}),n.createElement(ue,{className:"mb-3"},n.createElement(le,null,"You've requested access!"),n.createElement(se,null,"We've sent a request to your ClickView admin. Once your account is ready, you'll receive an email notification with instructions on how to get started with ClickView.")))}};function ke(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return Ce(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Ce(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ce(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function Oe(t,e,r){return"".concat(t.padStart(4,"0"),"-").concat(e.padStart(2,"0"),"-").concat(r.padStart(2,"0"))}function Ne(t){return n.createElement(n.Fragment,null,"Have a ClickView account already?",n.createElement("a",{href:t.link,className:"info-link ms-1",target:"_blank",onClick:t.onClick},"Sign in"))}const Ae="gVdYS",Pe="Mlp3x";function Ie(t){var e=t.idp,r=t.onClick,o=t.last;return n.createElement("button",{className:"btn btn-lg btn-outline-dark w-100 ".concat(o?"":"mb-3"," ").concat(Ae),onClick:function(){return r(e)}},e.logoUrl&&n.createElement("img",{src:e.logoUrl,className:Pe}),"Continue with ",e.name)}var Te=[{name:"ClassLink",logoUrl:"https://img.clickviewapp.com/v2/logos/ZA2ew5",url:"/login?idp=classlink"},{name:"Clever",logoUrl:"https://img.clickviewapp.com/v2/logos/LqlKgd",url:"/login?idp=clever"},{name:"Google",logoUrl:"https://img.clickviewapp.com/v2/logos/l5x0jL",url:"/login?idp=google"},{name:"Microsoft",logoUrl:"https://img.clickviewapp.com/v2/logos/xAxGPP",url:"/login?idp=microsoft"}],_e=r(93824);function Ue(t){return Ue="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ue(t)}function Fe(){Fe=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var a=e&&e.prototype instanceof v?e:v,i=Object.create(a.prototype),c=new A(n||[]);return o(i,"_invoke",{value:k(t,r,c)}),i}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var p="suspendedStart",h="suspendedYield",d="executing",y="completed",m={};function v(){}function g(){}function b(){}var w={};u(w,i,(function(){return this}));var E=Object.getPrototypeOf,S=E&&E(E(P([])));S&&S!==r&&n.call(S,i)&&(w=S);var x=b.prototype=v.prototype=Object.create(w);function L(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function r(o,a,i,c){var l=f(t[o],t,a);if("throw"!==l.type){var u=l.arg,s=u.value;return s&&"object"==Ue(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,i,c)}),(function(t){r("throw",t,i,c)})):e.resolve(s).then((function(t){u.value=t,i(u)}),(function(t){return r("throw",t,i,c)}))}c(l.arg)}var a;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return a=a?a.then(o,o):o()}})}function k(e,r,n){var o=p;return function(a,i){if(o===d)throw new Error("Generator is already running");if(o===y){if("throw"===a)throw i;return{value:t,done:!0}}for(n.method=a,n.arg=i;;){var c=n.delegate;if(c){var l=C(c,n);if(l){if(l===m)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=y,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var u=f(e,r,n);if("normal"===u.type){if(o=n.done?y:h,u.arg===m)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(o=y,n.method="throw",n.arg=u.arg)}}}function C(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,C(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var a=f(o,e.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,m;var i=a.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function O(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function N(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function A(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(O,this),this.reset(!0)}function P(e){if(e||""===e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}throw new TypeError(Ue(e)+" is not iterable")}return g.prototype=b,o(x,"constructor",{value:b,configurable:!0}),o(b,"constructor",{value:g,configurable:!0}),g.displayName=u(b,l,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,b):(t.__proto__=b,u(t,l,"GeneratorFunction")),t.prototype=Object.create(x),t},e.awrap=function(t){return{__await:t}},L(j.prototype),u(j.prototype,c,(function(){return this})),e.AsyncIterator=j,e.async=function(t,r,n,o,a){void 0===a&&(a=Promise);var i=new j(s(t,r,n,o),a);return e.isGeneratorFunction(r)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},L(x),u(x,l,"Generator"),u(x,i,(function(){return this})),u(x,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=P,A.prototype={constructor:A,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(N),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(l&&u){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(l){if(this.prev<i.catchLoc)return o(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,m):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),N(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;N(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:P(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function Ge(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return De(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?De(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function De(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function Re(t,e,r){return(e=function(t){var e=function(t,e){if("object"!==Ue(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,"string");if("object"!==Ue(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===Ue(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Me=new RegExp(/^[^\s@]+@[^\s@]+\.[^\s@]+$/),Ke=Re(Re(Re(Re({},_e.C.AU,"valerie.frizzle@school.edu.au"),_e.C.UK,"valerie.frizzle@school.gov.uk"),_e.C.US,"valerie.frizzle@school.gov"),_e.C.NZ,"valerie.frizzle@school.nz");function Ye(t){return Ke[g.I.getCountryCode(t.countryCode)]||Ke.us}var ze=[y.Expired,y.NotRequired,y.Unavailable,y.Unsupported,y.Active];function qe(t){var e;switch(null===(e=null==t?void 0:t.body)||void 0===e?void 0:e.type){case"user-type-not-supported":return"Students may not request to join schools.";case"join-request-already-pending":return"Your request is awaiting administrator approval.";case"join-request-already-denied":return"Your request has been denied by an administrator.";default:return"Something went wrong."}}var Ve=r(12238);function Be(t){return Be="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Be(t)}function $e(){$e=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var a=e&&e.prototype instanceof v?e:v,i=Object.create(a.prototype),c=new A(n||[]);return o(i,"_invoke",{value:k(t,r,c)}),i}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var p="suspendedStart",h="suspendedYield",d="executing",y="completed",m={};function v(){}function g(){}function b(){}var w={};u(w,i,(function(){return this}));var E=Object.getPrototypeOf,S=E&&E(E(P([])));S&&S!==r&&n.call(S,i)&&(w=S);var x=b.prototype=v.prototype=Object.create(w);function L(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function r(o,a,i,c){var l=f(t[o],t,a);if("throw"!==l.type){var u=l.arg,s=u.value;return s&&"object"==Be(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,i,c)}),(function(t){r("throw",t,i,c)})):e.resolve(s).then((function(t){u.value=t,i(u)}),(function(t){return r("throw",t,i,c)}))}c(l.arg)}var a;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return a=a?a.then(o,o):o()}})}function k(e,r,n){var o=p;return function(a,i){if(o===d)throw new Error("Generator is already running");if(o===y){if("throw"===a)throw i;return{value:t,done:!0}}for(n.method=a,n.arg=i;;){var c=n.delegate;if(c){var l=C(c,n);if(l){if(l===m)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=y,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var u=f(e,r,n);if("normal"===u.type){if(o=n.done?y:h,u.arg===m)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(o=y,n.method="throw",n.arg=u.arg)}}}function C(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,C(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var a=f(o,e.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,m;var i=a.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function O(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function N(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function A(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(O,this),this.reset(!0)}function P(e){if(e||""===e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}throw new TypeError(Be(e)+" is not iterable")}return g.prototype=b,o(x,"constructor",{value:b,configurable:!0}),o(b,"constructor",{value:g,configurable:!0}),g.displayName=u(b,l,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,b):(t.__proto__=b,u(t,l,"GeneratorFunction")),t.prototype=Object.create(x),t},e.awrap=function(t){return{__await:t}},L(j.prototype),u(j.prototype,c,(function(){return this})),e.AsyncIterator=j,e.async=function(t,r,n,o,a){void 0===a&&(a=Promise);var i=new j(s(t,r,n,o),a);return e.isGeneratorFunction(r)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},L(x),u(x,l,"Generator"),u(x,i,(function(){return this})),u(x,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=P,A.prototype={constructor:A,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(N),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(l&&u){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(l){if(this.prev<i.catchLoc)return o(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,m):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),N(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;N(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:P(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function He(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function Ze(t){return Ze="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ze(t)}function Je(){Je=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var a=e&&e.prototype instanceof v?e:v,i=Object.create(a.prototype),c=new A(n||[]);return o(i,"_invoke",{value:k(t,r,c)}),i}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var p="suspendedStart",h="suspendedYield",d="executing",y="completed",m={};function v(){}function g(){}function b(){}var w={};u(w,i,(function(){return this}));var E=Object.getPrototypeOf,S=E&&E(E(P([])));S&&S!==r&&n.call(S,i)&&(w=S);var x=b.prototype=v.prototype=Object.create(w);function L(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function r(o,a,i,c){var l=f(t[o],t,a);if("throw"!==l.type){var u=l.arg,s=u.value;return s&&"object"==Ze(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,i,c)}),(function(t){r("throw",t,i,c)})):e.resolve(s).then((function(t){u.value=t,i(u)}),(function(t){return r("throw",t,i,c)}))}c(l.arg)}var a;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return a=a?a.then(o,o):o()}})}function k(e,r,n){var o=p;return function(a,i){if(o===d)throw new Error("Generator is already running");if(o===y){if("throw"===a)throw i;return{value:t,done:!0}}for(n.method=a,n.arg=i;;){var c=n.delegate;if(c){var l=C(c,n);if(l){if(l===m)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=y,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var u=f(e,r,n);if("normal"===u.type){if(o=n.done?y:h,u.arg===m)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(o=y,n.method="throw",n.arg=u.arg)}}}function C(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,C(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var a=f(o,e.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,m;var i=a.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function O(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function N(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function A(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(O,this),this.reset(!0)}function P(e){if(e||""===e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}throw new TypeError(Ze(e)+" is not iterable")}return g.prototype=b,o(x,"constructor",{value:b,configurable:!0}),o(b,"constructor",{value:g,configurable:!0}),g.displayName=u(b,l,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,b):(t.__proto__=b,u(t,l,"GeneratorFunction")),t.prototype=Object.create(x),t},e.awrap=function(t){return{__await:t}},L(j.prototype),u(j.prototype,c,(function(){return this})),e.AsyncIterator=j,e.async=function(t,r,n,o,a){void 0===a&&(a=Promise);var i=new j(s(t,r,n,o),a);return e.isGeneratorFunction(r)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},L(x),u(x,l,"Generator"),u(x,i,(function(){return this})),u(x,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=P,A.prototype={constructor:A,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(N),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(l&&u){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(l){if(this.prev<i.catchLoc)return o(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,m):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),N(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;N(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:P(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}var We=function(t,e,r,n){return new(r||(r=Promise))((function(o,a){function i(t){try{l(n.next(t))}catch(t){a(t)}}function c(t){try{l(n.throw(t))}catch(t){a(t)}}function l(t){var e;t.done?o(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(i,c)}l((n=n.apply(t,e||[])).next())}))},Xe=r(80247);function Qe(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return tr(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?tr(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function tr(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function er(t){var e=t.filteredSchoolsList,r=t.getSchoolName,o=t.onSchoolSuggestionClick,a=t.selectedIndex;return n.createElement(n.Fragment,null,e.map((function(t,e){return n.createElement(yt.L,{className:"".concat(vt.suggestionItem," ").concat(a-1===e?vt.selected:""),key:t.id,onClick:function(){return o(t)}},r(t)," ",n.createElement("br",null),n.createElement("small",{className:"text-muted"},function(t){var e=[];return t.city&&e.push(t.city.toLowerCase().split(" ").map((function(t){return t.charAt(0).toUpperCase()+t.slice(1)})).join(" ")),t.province&&e.push(t.province),t.postCode&&e.push(t.postCode),e.join(" ")}(t)))})))}function rr(t){return n.createElement("div",{className:"info-link ".concat(vt.suggestionItem," ").concat(vt.noSuggestion," ").concat(t.selected?vt.selected:""),onClick:t.handleNoSuggestion},"Can't find your school?")}function nr(t){var e,r,o=n.useRef(),a=Qe(n.useState(!0),2),i=a[0],l=a[1],u=Qe(n.useState(t.data.schoolName&&t.data.schoolPostCode?t.data.schoolName+", "+t.data.schoolPostCode:t.data.schoolName?t.data.schoolName:""),2),s=u[0],f=u[1],p=Qe(n.useState(),2),h=p[0],d=p[1],y=(0,ht.N)(s,250),m=ct({onSelected:function(t){if(h||t)if(t!==h.length){var e=h[t];e&&k(e)}else O()},itemCount:null!==(e=(null==h?void 0:h.length)+1)&&void 0!==e?e:0}),v=m.selectedIndex,g=m.onKeyDown,b=m.containerRef,w=!!(null===(r=t.data)||void 0===r?void 0:r.prospectId),E=i&&!w,S=!i&&!w&&!(null==h?void 0:h.length),x=(null==h?void 0:h.length)&&!w;function L(e){(t.data.schoolName||t.data.prospectId)&&t.clearStepItemData(),e!==s&&f(e)}function j(e){l(!0);var r={latitude:t.data.latitude,longitude:t.data.longitude};e&&e.length&&(r.query=e),Dt.search(t.ajaxUrls,r,(function(t){return d(t)}),null,(function(){return l(!1)}))}function k(e){f(C(e)),t.setDataProperty("prospectId",e.id),t.setDataProperty("schoolName",e.name),t.setDataProperty("schoolPostCode",e.postCode),t.setDataProperty("schoolType",e.prospectType),t.setDataProperty("province",e.province),t.setDataProperty("city",e.city),t.setDataProperty("country",e.countryCode)}function C(t){return t.name}function O(){t.nextStep({step:"cant-find-school",prospectId:t.data.prospectId,schoolName:s,schoolLocality:t.data.schoolLocality,longitude:t.data.longitude,latitude:t.data.latitude,country:t.data.country,city:t.data.city,province:t.data.province}),t.logUserAction({},{actionType:q.Vw.Click,descriptor:q.Yu.CantFindSchool,workflowPhase:q.eu.Next})}n.useEffect((function(){w||(y.length?!w&&y.length>1&&y===s&&j(y):j())}),[y,w]);var N=x||E||S;return n.createElement("div",{className:"form-group position-relative"},n.createElement(c.w,{value:s,onChange:function(t){return L(t.currentTarget.value)},ref:o,className:"form-control form-control-lg ".concat(N?vt.inputFocused:vt.input),type:"text",autoComplete:"off",placeholder:"Select your school below",disabled:t.disabled,autoFocus:!0,onClickClear:function(){L(""),o.current.focus()},onKeyDown:g}),n.createElement("div",{className:"position-absolute w-100"},n.createElement("div",{className:"".concat(vt.suggestionContainer," ").concat(N?"":"d-none"),ref:b},x?n.createElement(er,{filteredSchoolsList:h,onSchoolSuggestionClick:k,getSchoolName:C,selectedIndex:v}):E&&n.createElement("div",{className:"".concat(vt.suggestionLoading," py-4 d-flex justify-content-center")},n.createElement(Xe.Z,{animation:"border"})),!E&&(null==h?void 0:h.length)<5&&n.createElement(rr,{selected:v===h.length+1,handleNoSuggestion:O}))))}function or(t){return or="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},or(t)}function ar(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return ir(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?ir(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ir(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}const cr="R8ZPi",lr="SNEmW",ur="BSfO7";function sr(t){return n.createElement(n.Fragment,null,n.createElement(yt.L,{className:"\n d-flex\n flex-column\n justify-content-between\n h-100\n p-3\n border\n rounded\n rounded-3\n mx-auto\n d-sm-block\n d-none\n ".concat(cr," ").concat(t.selected?lr:""),onClick:function(){return t.onClick(t.type)}},n.createElement("img",{src:t.imageSrc,className:"rounded-top mx-auto pb-2"}),n.createElement("div",{className:"py-2"},n.createElement("span",{className:"h4"},t.buttonText))),n.createElement(yt.L,{className:"btn btn-lg btn-outline-dark w-100 d-sm-none d-block mx-auto ".concat(ur),onClick:function(){return t.onClick(t.type)}},t.buttonText))}var fr={"select-type":function(t){function e(e){t.logUserAction({userType:e},{actionType:q.Vw.Click,workflowPhase:q.eu.Next,descriptor:e===v.Staff?q.Yu.Educator:q.Yu.Student}),e!==v.Staff?t.nextStep({step:"enter-age",userType:e}):t.nextStep({step:"enter-email",userType:e})}return n.createElement("div",{className:"text-center"},n.createElement("h1",{className:"h4"},"Access educational videos at your fingertips"),n.createElement("p",{className:"mb-3"},"Let's get you set up so you can access ClickView."),n.createElement("div",{className:"row"},n.createElement("div",{className:"col-lg-6 mb-3"},n.createElement(sr,{type:v.Staff,buttonText:"I'm an educator",imageSrc:t.imageUrls.educator,onClick:e,selected:t.userType===v.Staff})),n.createElement("div",{className:"col-lg-6 mb-3"},n.createElement(sr,{type:v.Learner,buttonText:"I'm a student",imageSrc:t.imageUrls.student,onClick:e,selected:t.userType===v.Learner}))))},"enter-email":function(t){var e,r,o,a,i=Ge(n.useState(!1),2),l=i[0],u=i[1],s=Ge(n.useState((null==t?void 0:t.email)||""),2),f=s[0],p=s[1],h=Ge(n.useState(),2),d=h[0],y=h[1],w=(o=t.geoLocation,a=de.F.getMarketingUrlForGeoLocation(o),"nz"===(null==o?void 0:o.countryCode)?a+"/contact-us/":a+"/contact-us/technical/");function E(e){null==e||e.preventDefault(),function(){var e,r,n,o;e=this,r=void 0,n=void 0,o=Fe().mark((function e(){var r;return Fe().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(f.length?Me.test(f)||(y("Please use your school email address."),0):(y("Please enter your school email address."),0)){e.next=2;break}return e.abrupt("return");case 2:return u(!0),y(""),e.prev=4,e.next=7,Mt(t.ajaxUrls,{email:f});case 7:r=e.sent,e.next=14;break;case 10:return e.prev=10,e.t0=e.catch(4),y("Something went wrong! Please try again later."),e.abrupt("return");case 14:if(u(!1),r.status!==m.InvalidEmail){e.next=18;break}return y("Please use your school email address."),e.abrupt("return");case 18:if(t.logUserAction({},{actionType:q.Vw.Click,workflowPhase:q.eu.Next,descriptor:q.Yu.EnterEmail}),!ze.includes(r.status)){e.next=22;break}return t.complete({completionStep:"trial-status",email:f,trialStatus:r.status,trialCreated:!1}),e.abrupt("return");case 22:t.nextStep({step:"find-school",email:f});case 23:case"end":return e.stop()}}),e,null,[[4,10]])})),new(n||(n=Promise))((function(t,a){function i(t){try{l(o.next(t))}catch(t){a(t)}}function c(t){try{l(o.throw(t))}catch(t){a(t)}}function l(e){var r;e.done?t(e.value):(r=e.value,r instanceof n?r:new n((function(t){t(r)}))).then(i,c)}l((o=o.apply(e,r||[])).next())}))}()}function S(t){var e=window.location.pathname+window.location.search;window.location.href=t.url+"&redirectUrl="+encodeURIComponent(e)}var x=!1;return t.userType===v.Staff&&(g.I.isCountryCodeUS(null===(e=t.geoLocation)||void 0===e?void 0:e.countryCode)&&(x=!0),(null===(r=window.location.search)||void 0===r?void 0:r.indexOf("emulateUSA"))>-1&&(x=!0)),n.createElement(n.Fragment,null,n.createElement("div",{className:"text-center"},n.createElement("h1",{className:"h4"},"Let's set up your account"),n.createElement("p",null,"Enter your school email address")),n.createElement("form",{onSubmit:E,noValidate:!0},n.createElement("div",{className:"form-group mb-3"},n.createElement(c.w,{value:f,onChange:function(t){t.preventDefault(),p(t.target.value),y("")},name:"email-input",id:"email-input",type:"email",className:"form-control form-control-lg ".concat(d?"is-invalid":""),placeholder:Ye(t.geoLocation),autoComplete:"false",autoCorrect:"false",autoFocus:!0,onClickClear:function(){return p("")}}),d&&n.createElement(n.Fragment,null,n.createElement("div",{className:"invalid-feedback d-block"},d),n.createElement("small",null,"Having an issue with your email?",n.createElement("a",{href:w,className:"info-link ps-1",target:"_blank",onClick:function(){t.logUserAction({},{actionType:q.Vw.Click,descriptor:q.Yu.ContactUs})}},"Contact our team")))),n.createElement(b.m,{showSpinner:l,variant:"dark",className:"btn-lg mb-3 w-100",disabled:l,onClick:E},"Continue")),x&&n.createElement("div",{className:"mt-n3"},n.createElement("div",{className:"my-3 border-bottom position-relative ".concat("bGwO5")}),Te.map((function(t,e){return n.createElement(Ie,{onClick:S,idp:t,key:e})}))),n.createElement("div",{className:"text-center"},n.createElement(Ne,{link:de.F.getLoginLink(),onClick:function(){t.logUserAction({},{actionType:q.Vw.Click,descriptor:q.Yu.SignIn})}})))},"find-school":function(t){var e,r,o=t.email,a=t.userType,i=ar(n.useState({schoolLocality:t.schoolLocality,country:t.country,longitude:t.longitude,latitude:t.latitude,city:t.city,province:t.province}),2),c=i[0],l=i[1],u=ar(n.useState(),2),s=u[0],f=u[1],p=ar(n.useState(),2),h=p[0],d=p[1],m=ar(n.useState(!1),2),g=m[0],w=m[1],E=ar(n.useState(!1),2),S=E[0],x=E[1],L=ar(n.useState(!1),2),j=L[0],C=L[1],O=function(t){var e=t.loading,r=t.canSubmitForm,n=t.setSubmissionError,o=t.prospectStatus,a=t.userType,i=t.logStepEvent,c=t.logUserAction,l=t.nextStep,u=t.data,s=t.productName,f=t.ajaxUrls,p=t.complete,h=t.setLoadingState,d=t.email,m=t.pageAppLinkString,g=t.setProperty,b=t.brazeConfig,w=t.geoLocation,E=t.version;function S(){return We(this,void 0,void 0,Je().mark((function t(){return Je().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,Vt(f,{prospectId:u.prospectId,email:d});case 3:c({},{actionType:q.Vw.Click,descriptor:q.Yu.AutoJoin}),p(Object.assign({completionStep:"trial-status",trialCreated:!0,trialStatus:y.Available},u)),t.next=12;break;case 7:return t.prev=7,t.t0=t.catch(0),n("Something went wrong! Please try again later."),h(!1),t.abrupt("return");case 12:case"end":return t.stop()}}),t,null,[[0,7]])})))}function x(){var t;return We(this,void 0,void 0,Je().mark((function e(){var r,n;return Je().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(r=void 0,!(null==u?void 0:u.prospectId)||o!==y.NotRequired){e.next=6;break}return e.next=4,Dt.getLookups(f,u.prospectId);case 4:n=e.sent,r=null===(t=n.find((function(t){return t.type===Ve.C.MasterId})))||void 0===t?void 0:t.externalId;case 6:p(Object.assign({completionStep:"trial-status",trialStatus:o,trialCreated:!1,customerId:r},u)),i();case 8:case"end":return e.stop()}}),e)})))}function L(){return We(this,void 0,void 0,Je().mark((function t(){return Je().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,Xt.submitFormEvent({brazeConfig:b,productName:s,geoLocation:w,version:E},"trial-sign-up",Object.assign(Object.assign({},u),{email:d,province:U.parseProvince(u.province)}));case 2:case"end":return t.stop()}}),t)})))}function j(){var t;return We(this,void 0,void 0,Je().mark((function e(){var r;return Je().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return h(!0),e.prev=1,e.next=4,Yt(f,{userType:a,email:d,prospectId:null==u?void 0:u.prospectId,appLink:m,accessPolicy:Bt(u.country)});case 4:r=e.sent,e.next=12;break;case 7:return e.prev=7,e.t0=e.catch(1),n("Something went wrong! Please try again later."),h(!1),e.abrupt("return");case 12:o===y.UserAutoJoinAllowed&&c({},{actionType:q.Vw.Click,descriptor:q.Yu.AutoJoin}),g("userId",r.id),p(Object.assign({completionStep:"trial-status",userId:r.id,trialCreated:!0,trialStatus:y.Available,customerId:null===(t=r.data)||void 0===t?void 0:t.customerId},u)),L(),i();case 17:case"end":return e.stop()}}),e,null,[[1,7]])})))}return function(){return We(this,void 0,void 0,Je().mark((function t(){return Je().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!e){t.next=2;break}return t.abrupt("return");case 2:if(r()){t.next=5;break}return n("Something went wrong! Please try again later."),t.abrupt("return");case 5:if(a!==v.Staff){t.next=14;break}if(o!==y.Unsupported){t.next=8;break}return t.abrupt("return",(l(Object.assign({step:"add-to-braze",trialStatus:o},u)),void i()));case 8:if(o!==y.UserJoinApprovalRequired){t.next=10;break}return t.abrupt("return",(l(Object.assign({step:"request-access"},u)),void i()));case 10:if(o!==y.UserAutoJoinAllowed||s!==k.X.Lite){t.next=14;break}return t.next=13,S();case 13:case 17:case 20:return t.abrupt("return",t.sent);case 14:if(o===y.Active||o===y.Available||o===y.UserAutoJoinAllowed&&s===k.X.Auth){t.next=18;break}return t.next=17,x();case 18:return t.next=20,j();case 21:case"end":return t.stop()}}),t)})))}}(Object.assign(Object.assign({},t),{prospectStatus:s,loading:g,data:c,canSubmitForm:N,setSubmissionError:d,logStepEvent:function(){var e={actionType:q.Vw.Click,descriptor:q.Yu.FindSchool,workflowPhase:q.eu.Next};t.logUserAction(c||{},e)},setLoadingState:function(t){x(t),C(t),w(t)},setProperty:A}));function N(){if(!c||!o||!a)return!1;var t=c.prospectId;return!!(o&&a&&t)}function A(e,r){"prospectId"===e&&r&&(w(!0),Kt(t.ajaxUrls,{prospectId:r.toString(),email:t.email},(function(t){f(t.status)}),(function(){console.log("error")}),(function(){w(!1)}))),l((function(t){return Object.assign(Object.assign({},t),function(t,e,r){return(e=function(t){var e=function(t,e){if("object"!==or(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,"string");if("object"!==or(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===or(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}({},e,r))}))}function P(){A("prospectId",void 0),A("schoolName",""),A("schoolPostCode",void 0),d(void 0)}return n.createElement(n.Fragment,null,n.createElement("div",{className:"text-center"},n.createElement("h1",{className:"h4"},"Next, let's find your school"),n.createElement("p",null,"au"===(null==(r=null===(e=t.geoLocation)||void 0===e?void 0:e.countryCode)?void 0:r.toLowerCase())?"Enter your school postcode or suburb":"Enter your school postcode or city")),n.createElement(Et,{data:c,setDataProperty:A,clearStepGroupData:function(){A("schoolLocality",void 0),l((function(t){return Object.assign(Object.assign({},t),{longitude:undefined,latitude:undefined})})),A("city",void 0),A("province",void 0),A("country",void 0),P(),d(void 0)},disabled:S,geoLocation:t.geoLocation,labelClassName:"d-none",logUserAction:t.logUserAction,googleMapsApiKey:t.googleMapsApiKey,autoFocus:!0}),!!(c&&c.schoolLocality&&c.longitude&&c.latitude)&&n.createElement(nr,{data:c,setDataProperty:A,clearStepItemData:P,nextStep:t.nextStep,currentStepId:t.currentStepId,disabled:j,logUserAction:t.logUserAction,ajaxUrls:t.ajaxUrls}),h&&n.createElement("p",{className:"text-danger mb-2"},h),N()&&n.createElement(b.m,{className:"btn-lg w-100",variant:"dark",onClick:O,showSpinner:S||j||g,disabled:S||j||g},"Get started"))},"cant-find-school":function(t){var e,r,o,a=oe(n.useState({prospectId:t.prospectId,schoolName:t.schoolName,schoolType:t.schoolType,schoolLocality:t.schoolLocality,country:t.country,province:t.province,city:t.city,longitude:t.longitude,latitude:t.latitude}),2),i=a[0],c=a[1],l=oe(n.useState(),2),u=l[0],s=l[1],f=oe(n.useState(!1),2),p=f[0],h=f[1],d=(r=i.country||(null===(e=t.geoLocation)||void 0===e?void 0:e.countryCode),o=g.I.getCountryCode(r),ee[o]||te);function m(){var t=i.schoolName,e=i.schoolType,r=i.country;return!!(t&&e&&r)}function v(t,e){c((function(r){return Object.assign(Object.assign({},r),function(t,e,r){return(e=function(t){var e=function(t,e){if("object"!==re(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,"string");if("object"!==re(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===re(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}({},t,e))}))}function w(){return ie(this,void 0,void 0,ne().mark((function e(){var r,n,o,a,c;return ne().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=t.email,n=t.brazeConfig,o=t.productName,a=t.geoLocation,c=t.version,e.next=3,Xt.submitFormEvent({brazeConfig:n,productName:o,geoLocation:a,version:c},"trial-sign-up",Object.assign(Object.assign({},i),{email:r}));case 3:case"end":return e.stop()}}),e)})))}return n.createElement(n.Fragment,null,n.createElement("div",{className:"text-center"},n.createElement("h1",{className:"h4"},"Tell us more about yourself"),n.createElement("p",null,"Please enter your school details.")),n.createElement("div",{className:"form-group"},n.createElement("label",{className:"d-block",htmlFor:"school-name-input"},"Name of school"),n.createElement("input",{type:"text",value:(null==i?void 0:i.schoolName)||"",onChange:function(t){v("schoolName",t.target.value)},id:"school-name-input",className:"form-control form-control-lg",autoComplete:"off",placeholder:"Enter name of school",autoFocus:!0})),n.createElement("div",{className:"form-group"},n.createElement("label",{className:"d-block",htmlFor:"school-type-select"},"Type of school"),n.createElement("select",{id:"school-type-select",className:"form-control form-control-lg ".concat(i.schoolType?"":"text-muted"),autoComplete:"off",value:i.schoolType||"none",onChange:function(t){v("schoolType",t.target.value)}},n.createElement("option",{value:"none",className:"text-muted",disabled:!0},"Select type of school"),d.map((function(t){return n.createElement("option",{value:t,key:t,className:"text-dark"},t)})))),n.createElement(Et,{data:i,setDataProperty:v,clearStepGroupData:function(){v("schoolLocality",void 0),c((function(t){return Object.assign(Object.assign({},t),{longitude:undefined,latitude:undefined})})),v("city",void 0),v("province",void 0),v("country",void 0),s("")},disabled:!1,labelClassName:"d-block",geoLocation:t.geoLocation,logUserAction:t.logUserAction,googleMapsApiKey:t.googleMapsApiKey,autoFocus:!1}),u&&n.createElement("div",{className:"text-danger mb-3"},u),m()&&n.createElement(b.m,{className:"btn-lg w-100",variant:"dark",onClick:function(e){var r;return ie(this,void 0,void 0,ne().mark((function n(){var o,a,c;return ne().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(e.preventDefault(),m()){n.next=3;break}return n.abrupt("return");case 3:return t.logUserAction(i,{actionType:q.Vw.Click,workflowPhase:q.eu.Next,descriptor:q.Yu.CantFindSchool}),h(!0),n.prev=5,n.next=8,Dt.create(t.ajaxUrls,{name:i.schoolName,status:Wt.Draft,countryCode:i.country,prospectType:i.schoolType,city:i.city,postCode:i.schoolPostCode,province:U.parseProvince(i.province)});case 8:if((o=n.sent).id){n.next=13;break}return h(!1),s("Error. Something went wrong."),n.abrupt("return");case 13:n.next=20;break;case 15:return n.prev=15,n.t0=n.catch(5),h(!1),s("Error. Something went wrong."),n.abrupt("return");case 20:return n.prev=20,n.next=23,Yt(t.ajaxUrls,{userType:t.userType,email:t.email,prospectId:o.id,appLink:t.pageAppLinkString,accessPolicy:Bt(i.country)});case 23:a=n.sent,t.complete({completionStep:"trial-status",email:t.email,userId:a.id,prospectId:o.id,schoolName:i.schoolName,schoolLocality:i.schoolLocality,country:i.country,schoolType:i.schoolType,city:i.city,schoolPostCode:i.schoolPostCode,latitude:i.latitude,longitude:i.longitude,province:i.province,trialStatus:y.Available,trialCreated:!0,customerId:null===(r=a.data)||void 0===r?void 0:r.customerId}),w(),n.next=38;break;case 28:if(n.prev=28,n.t1=n.catch(20),n.t1.body){n.next=34;break}return h(!1),s("Error. Something went wrong."),n.abrupt("return");case 34:if(400!==(c=n.t1).body.status||"trial-not-available"!==c.body.type){n.next=38;break}return t.nextStep(Object.assign(Object.assign({step:"add-to-braze"},i),{prospectId:o.id,trialStatus:y.Unavailable})),n.abrupt("return");case 38:case"end":return n.stop()}}),n,null,[[5,15],[20,28]])})))},showSpinner:p,disabled:p},"Get started"))},completed:function(t){var e=je[t.completionStep];return n.createElement("div",{className:"d-flex justify-content-center flex-column mx-auto px-2"},n.createElement(e,Object.assign({},t)))},"add-to-braze":function(t){var e,r=D(n.useState(!1),2),o=r[0],a=r[1],c=D(n.useState({}),2),l=c[0],u=c[1];function s(e){var r=z(e.fullname),n=r.firstName,o=r.surname,a={prospect_id:null==t?void 0:t.prospectId,email:null==t?void 0:t.email,organisation_sub_type:U.getSchoolType(null==t?void 0:t.schoolType),account_name:null==t?void 0:t.schoolName,account_post_code:null==t?void 0:t.schoolPostCode,account_country:null==t?void 0:t.country,province:null==t?void 0:t.province,first_name:n,last_name:o,job_title:e.jobTitle,sync_to_crm:!0,event_topic:U.getEventTopic()};return U.removeEmptyKeys(a)}function f(){t.complete({completionStep:"added-to-braze",trialCreated:!1,trialStatus:null})}return n.useEffect((function(){t.userType===v.Learner&&t.complete({completionStep:"trial-status",trialCreated:!1,trialStatus:y.Unsupported})}),[]),n.createElement(S,{errors:l,loading:o,geoLocation:t.geoLocation,country:t.country||(null===(e=t.geoLocation)||void 0===e?void 0:e.countryCode),logUserAction:t.logUserAction,handleSubmitForm:function(e){var r,n;(function(t){var e=t.fullname,r=t.jobTitle,n=t.phone,o=z(e),a=o.firstName,i=o.surname,c={};return a&&i||(c.fullname="Please enter your full name."),(K.test(a)||K.test(i))&&(c.fullname="Please enter your full name."),e.length>M&&(c.fullname="Full name cannot exceed max length of ".concat(M," characters.")),(null==r?void 0:r.length)||(c.jobTitle="Please enter your job title."),K.test(r)&&(c.jobTitle="Please enter a valid job title."),r.length>M&&(c.jobTitle="Job Title cannot exceed max length of ".concat(M," characters.")),(null==n?void 0:n.length)||(c.phone="Please enter your phone number."),!K.test(n)&&Y.test(n)||(c.phone="Please enter a valid phone number."),u(c),!Object.keys(c).length})(e)&&((null===(r=e.jobTitle)||void 0===r?void 0:r.toLowerCase().includes("student"))||(null===(n=e.jobTitle)||void 0===n?void 0:n.toLowerCase().includes("parent"))?f():function(e){var r,n,c,p;r=this,n=void 0,c=void 0,p=G().mark((function r(){var n,c,p,h,d,y,m;return G().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(!o){r.next=2;break}return r.abrupt("return");case 2:if(t.userType!==v.Learner){r.next=5;break}return u(Object.assign(Object.assign({},l),{submission:"Something went wrong! Please try again later."})),r.abrupt("return");case 5:return t.logUserAction({},{actionType:i.Vw.Click,workflowPhase:i.eu.Next,descriptor:i.Yu.AddToBraze}),a(!0),n=s(e),c=t.geoLocation.isFallback?{countryCode:t.country||t.geoLocation.countryCode}:t.geoLocation,r.next=11,U.getClient({brazeConfig:t.brazeConfig,geoLocation:c,productName:t.productName,version:t.version});case 11:p=r.sent,h=z(e.fullname),d=h.firstName,y=h.surname,m={prospect_id:null==t?void 0:t.prospectId,organisation_sub_type:U.getSchoolType(null==t?void 0:t.schoolType),account_name:null==t?void 0:t.schoolName,account_address:{country_code:null==t?void 0:t.country,province:U.parseProvince((null==t?void 0:t.province)||"")},job_title:e.jobTitle,sync_to_crm:!0},m=U.removeEmptyKeys(m);try{p.setUser(U.hashedEmail(null==t?void 0:t.email)),p.setUserFirstName(d),p.setUserLastName(y),p.setUserPhone(e.phone),p.setUserEmail(null==t?void 0:t.email),p.openSession(),p.bulkSetCustomUserAttributes(m),p.logEvent({type:U.getCustomEventType(),data:n}),p.sendData((function(t){u(t?{}:Object.assign(Object.assign({},l),{submission:"Something went wrong! Please try again later."})),a(!1)}))}catch(t){u(Object.assign(Object.assign({},l),{submission:"Something went wrong! Please try again later."}))}Object.keys(l).length||f();case 17:case"end":return r.stop()}}),r)})),new(c||(c=Promise))((function(t,e){function o(t){try{i(p.next(t))}catch(t){e(t)}}function a(t){try{i(p.throw(t))}catch(t){e(t)}}function i(e){var r;e.done?t(e.value):(r=e.value,r instanceof c?r:new c((function(t){t(r)}))).then(o,a)}i((p=p.apply(r,n||[])).next())}))}(e))},removeErrorForKey:function(t){if(Object.keys(l).length&&l[t]){var e=Object.assign({},l);delete e[t],u(e)}}})},"enter-age":function(t){var e=ke(n.useState(""),2),r=e[0],o=e[1],a=ke(n.useState(""),2),i=a[0],c=a[1],l=ke(n.useState(""),2),u=l[0],s=l[1],f=ke(n.useState(null),2),p=f[0],h=f[1];var d=(new Date).getFullYear(),y="mx-2 d-inline-block text-start",m="form-control form-control-lg ".concat(p?"is-invalid":""),v="order-0",b="order-3",w=g.I.isCountryCodeUS(t.geoLocation.countryCode);return w&&(v="order-3",b="order-0"),n.createElement("form",{className:"text-center",onSubmit:function(e){if(e.preventDefault(),r&&i&&u?function(t,e,r){var n=new Date(Oe(t,e,r));return!isNaN(+n)}(u,i,r)?+u>d?(h("Please enter a date in the past"),0):!(+u<d-120&&(h("Please enter a realistic date of birth"),1)):(h("Please enter a valid date"),0):(h("Please enter your date of birth"),0)){var n=new Date(Oe(u,i,r)),o=d-13,a=new Date;a.setFullYear(o),n>a?t.complete({completionStep:"young-student",trialCreated:!1,trialStatus:null}):t.nextStep({step:"enter-email",userType:t.userType})}},noValidate:!0},n.createElement("h1",{className:"h4"},"Tell us a little about yourself"),n.createElement("p",null,"Please enter your date of birth"),n.createElement("div",{className:"my-4"},n.createElement("div",{className:"d-flex justify-content-center"},n.createElement("div",{className:"".concat(y," ").concat(v)},n.createElement("label",{className:"mb-0",htmlFor:"day"},"Day"),n.createElement("input",{id:"day",type:"number",className:"".concat(m," ").concat("e0Dbj"),min:"1",max:"31",placeholder:"DD",value:r,onChange:function(t){o(t.target.value),h(null)},autoFocus:!w,tabIndex:w?2:1})),n.createElement("span",{className:"h1 fw-normal mt-3 mb-0 order-1 ".concat(p?"text-danger":"")},"/"),n.createElement("div",{className:"".concat(y," ").concat(b)},n.createElement("label",{className:"mb-0",htmlFor:"month"},"Month"),n.createElement("input",{id:"month",type:"number",className:"".concat(m," ").concat("zLcQr"),min:"1",max:"12",placeholder:"MM",value:i,onChange:function(t){c(t.target.value),h(null)},autoFocus:w,tabIndex:w?1:2})),n.createElement("span",{className:"h1 fw-normal mt-3 mb-0 order-4 ".concat(p?"text-danger":"")},"/"),n.createElement("div",{className:"".concat(y," order-5")},n.createElement("label",{className:"mb-0",htmlFor:"year"},"Year"),n.createElement("input",{id:"year",type:"number",className:"".concat(m," ").concat("XiXPP"),min:d-120,max:d,placeholder:"YYYY",value:u,onChange:function(t){s(t.target.value),h(null)},tabIndex:3}))),!!p&&n.createElement("div",{className:"invalid-feedback d-block"},p)),n.createElement("button",{type:"submit",className:"btn btn-lg btn-dark w-100"},"Continue"))},"request-access":function(t){var e,r,o=(e=n.useState(null),r=2,function(t){if(Array.isArray(t))return t}(e)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(e,r)||function(t,e){if(t){if("string"==typeof t)return He(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?He(t,e):void 0}}(e,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),a=o[0],i=o[1];return n.createElement(n.Fragment,null,n.createElement(he,{trialStatus:y.UserJoinApprovalRequired,imageUrls:t.imageUrls}),n.createElement(ue,{className:"mb-3"},n.createElement(le,null,t.schoolName,n.createElement("br",null),"already has ClickView 🎉")),n.createElement("button",{className:"btn btn-lg btn-dark w-100 mb-3",onClick:function(){var e,r,n,o,a;return r=this,n=void 0,o=void 0,a=$e().mark((function r(){var n,o;return $e().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.prev=0,r.next=3,Dt.getLookups(t.ajaxUrls,t.prospectId);case 3:if(n=r.sent,o=null===(e=n.find((function(t){return t.type===Ve.C.MasterId})))||void 0===e?void 0:e.externalId){r.next=8;break}return i("Something went wrong."),r.abrupt("return");case 8:return r.next=10,qt(t.ajaxUrls,{customerId:o,email:t.email});case 10:t.logUserAction({},{actionType:q.Vw.Click,descriptor:q.Yu.RequestAccess}),t.complete({completionStep:"requested-access",trialCreated:!1,trialStatus:y.UserJoinApprovalRequired}),r.next=17;break;case 14:r.prev=14,r.t0=r.catch(0),i(qe(r.t0));case 17:case"end":return r.stop()}}),r,null,[[0,14]])})),new(o||(o=Promise))((function(t,e){function i(t){try{l(a.next(t))}catch(t){e(t)}}function c(t){try{l(a.throw(t))}catch(t){e(t)}}function l(e){var r;e.done?t(e.value):(r=e.value,r instanceof o?r:new o((function(t){t(r)}))).then(i,c)}l((a=a.apply(r,n||[])).next())}))}},"Request access"),a&&n.createElement("p",{className:"text-danger text-center mb-2"},a),n.createElement(se,{className:"text-center"},"Need Help? ",n.createElement("a",{href:de.F.getSupportUrlForGeoLocation(t.geoLocation),className:"info-link",target:"_blank"},"Contact our Help Centre.")))}};function pr(t){var e=t.state,r=t.geoLocation,o=t.layoutMapping,a=t.hasPreviousStep,i=t.googleMapsApiKey,c=t.pageAppLinkString,l=t.back,u=t.nextStep,s=t.complete,f=t.logUserAction,p=t.imageUrls,h=t.ajaxUrls,d=t.brazeConfig,y=t.version,m=t.productName,v=fr[e.currentStepId],g=Object.assign(Object.assign({},e),{geoLocation:r,googleMapsApiKey:i,pageAppLinkString:c,back:l,nextStep:u,complete:s,logUserAction:f,imageUrls:p,ajaxUrls:h,brazeConfig:d,version:y,productName:m}),b=null==o?void 0:o[e.currentStepId];return b?n.createElement(b,{geoLocation:t.geoLocation,currentStep:e.currentStepId,previousStep:l,closeApp:t.close,logUserAction:f,hasPreviousStep:a,imageUrls:t.imageUrls},n.createElement(v,Object.assign({},g))):n.createElement(v,Object.assign({},g))}var hr=r(1048);const dr={buttonContainer:"izZtA",dataContainer:"OgBv5"};function yr(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function mr(t){var e={};return Object.keys(t).forEach((function(r){var n=t[r];hr.t.isObject(n)&&null!==n&&!Array.isArray(n)?Object.assign(e,mr(n)):e[r]=n})),e}function vr(t){var e=t.label,r=t.item,o=r;return Array.isArray(r)&&(o=o.join(" -> ")),"boolean"==typeof o&&(o=o?"true":"false"),n.createElement("div",{className:"pb-1"},e,": ",n.createElement("b",{className:"text-white"},o))}function gr(t){var e,r,o=t.developmentEnv,a=t.objects,i=(e=n.useState(!0),r=2,function(t){if(Array.isArray(t))return t}(e)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(e,r)||function(t,e){if(t){if("string"==typeof t)return yr(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?yr(t,e):void 0}}(e,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),c=i[0],l=i[1],u=n.useMemo((function(){return mr(a)}),[a]);return o&&n.createElement(n.Fragment,null,n.createElement("div",{className:"position-fixed p-4 ".concat(dr.buttonContainer)},n.createElement("button",{onClick:function(){l(!c)},className:"btn btn-dark px-2 py-1"},c?"Hide":"Show"," debugger")),c&&n.createElement("div",{className:"fixed-bottom mb-4 ms-4 bg-dark rounded ".concat(dr.dataContainer)},n.createElement("code",{className:"d-block p-4"},n.createElement("div",{className:"fw-bold pb-2"},"{ Debug: Form Data }"),Object.keys(u).map((function(t){return n.createElement(vr,{key:t,label:t,item:u[t]})})))))}var br=r(83529);const wr={crumb:"Btmx2"};function Er(t,e){var r="rounded-circle mx-2 d-inline-block "+wr.crumb,n=t===e?"bg-info":"bg-light";return"".concat(r," ").concat(n)}function Sr(t){return n.createElement("div",{className:"text-center"},t.crumbs.map((function(e){return n.createElement("div",{className:Er(t.currentStep,e),key:e})})))}var xr=r(98461);function Lr(t){var e=de.F.getTermsAndConditionsLink(),r=de.F.getPrivacyPolicyLink();return n.createElement("span",{className:"text-center text-md mt-2 text-normal small"},"By signing up you agree to the",n.createElement("br",null),n.createElement(xr.d,{href:e,onClick:t.onClickTermsAndConditions,className:"info-link",newTab:!0},"Terms and Conditions"),"  and  ",n.createElement(xr.d,{href:r,onClick:t.onClickPrivacyPolicy,className:"info-link",newTab:!0},"Privacy Policy"))}var jr=r(83914),kr=r(35223);function Cr(t){return n.createElement("button",{onClick:t.onClick,className:"btn p-0 cursor-pointer d-inline-flex align-items-center"},n.createElement(jr.x,{svgName:kr.vn.ChevronLeft,size:jr.S.Medium}),t.children)}var Or=r(2786);Ar.defaultProps={showBackButton:!0};var Nr=["select-type","enter-email","find-school"];function Ar(t){var e=t.currentStep,r=t.previousStep,o=t.hasPreviousStep,a=t.showBackButton,i=t.children;return n.createElement("div",{className:"d-flex flex-column justify-content-between px-4 py-0 ".concat("jZ_Wp")},n.createElement("div",{className:"mt-3 mb-2"},Nr.includes(e)&&n.createElement(Sr,{crumbs:Nr,currentStep:e})),n.createElement("div",{className:"position-relative mx-auto w-100 ".concat("select-type"===e?"Ye154":["enter-email","find-school","cant-find-school","add-to-braze","enter-age"].includes(e)?"m2kAT":"ollkc")},n.createElement("div",{className:"d-flex flex-row justify-content-center align-items-center mt-2 mb-3"},o&&a&&["enter-email","find-school","cant-find-school","add-to-braze","enter-age","request-access"].includes(e)&&n.createElement(Cr,{onClick:function(){r(),t.logUserAction({step:e},{actionType:q.Vw.Click,descriptor:q.Yu.Back,workflowPhase:q.eu.Back})}}),n.createElement("div",{className:"d-flex justify-content-center align-items-center px-2 ".concat("J97w_")},n.createElement(Or.$S,null))),i),n.createElement("div",{className:"position-relative mb-4 mt-3 text-center"},"select-type"===e&&n.createElement(Ne,{link:de.F.getLoginLink(),onClick:function(){t.logUserAction({},{actionType:q.Vw.Click,descriptor:q.Yu.SignIn})}}),["enter-email","find-school","add-to-braze"].includes(e)&&n.createElement(Lr,{onClickTermsAndConditions:function(){t.logUserAction({},{actionType:q.Vw.Click,descriptor:q.Yu.TermsAndConditions})},onClickPrivacyPolicy:function(){t.logUserAction({},{actionType:q.Vw.Click,descriptor:q.Yu.PrivacyPolicy})}})))}var Pr=r(28366);_r.defaultProps={showBackButton:!0};var Ir=["enter-email","find-school"],Tr=["enter-email","find-school","cant-find-school","add-to-braze","enter-age","request-access"];function _r(t){var e=t.currentStep,r=t.previousStep,o=t.hasPreviousStep,a=t.showBackButton,i=t.closeApp,c=t.children;function l(){return["enter-email","find-school","cant-find-school","add-to-braze","enter-age"].includes(e)}function u(){r(),t.logUserAction({},{actionType:q.Vw.Click,descriptor:q.Yu.Back,workflowPhase:q.eu.Back})}var s=Tr.includes(t.currentStep),f=s?"".concat(Pr.Z.leftHalfLayout," ").concat(Pr.Z.withBg):Pr.Z.leftHalfLayout;return n.createElement("div",{className:f},n.createElement("div",{className:"row mx-0 p-3"},n.createElement("div",{className:"col px-0 d-lg-none ".concat(Pr.Z.popupButton)},o&&l()&&a&&n.createElement(Cr,{onClick:u})),n.createElement("div",{className:"col col-lg-6 px-0"},n.createElement("div",{className:Pr.Z.logo},n.createElement("div",{className:"d-none d-lg-block"},s?n.createElement(Or.Yo,null):n.createElement(Or.$S,null)),n.createElement("div",{className:"d-block d-lg-none mt-1"},n.createElement(Or.$S,null),Ir.includes(t.currentStep)&&n.createElement("div",{className:"mt-3"},n.createElement(Sr,{crumbs:Ir,currentStep:e}))))),n.createElement("div",{className:"col col-lg-6 d-flex flex-row justify-content-between px-0"},n.createElement("div",{className:"px-3"},n.createElement("div",{className:"d-none d-lg-block ".concat(Pr.Z.popupButton)},o&&l()&&a&&n.createElement(Cr,{onClick:u}))),Ir.includes(t.currentStep)&&n.createElement("div",{className:"d-none d-lg-block align-self-center"},n.createElement(Sr,{crumbs:Ir,currentStep:e})),n.createElement(yt.L,{onClick:i,className:Pr.Z.popupButton},n.createElement(jr.x,{svgName:kr.vn.Close,size:jr.S.Medium})))),n.createElement("div",{className:"row mx-0 flex-grow-1"},s&&n.createElement("div",{className:"col-6 px-0 d-none d-lg-block"},n.createElement("div",{className:"h-100 d-flex align-items-center justify-content-center"},n.createElement("img",{src:t.imageUrls.popupDashboard,className:"w-100 p-4 pb-5"}))),n.createElement("div",{className:"px-4 pt-0 pb-4 ".concat(s?"col-12 col-lg-6":"col-12")},n.createElement("div",{className:"d-flex flex-column h-100"},n.createElement("div",{className:"flex-grow-1"},c),n.createElement("div",{className:"text-center mt-3"},"select-type"===e&&n.createElement(Ne,{link:de.F.getLoginLink(),onClick:function(){t.logUserAction({},{actionType:q.Vw.Click,descriptor:q.Yu.SignIn})}}),["enter-email","add-to-braze"].includes(e)&&n.createElement(Lr,{onClickTermsAndConditions:function(){t.logUserAction({},{actionType:q.Vw.Click,descriptor:q.Yu.TermsAndConditions})},onClickPrivacyPolicy:function(){t.logUserAction({},{actionType:q.Vw.Click,descriptor:q.Yu.PrivacyPolicy})}}))))))}function Ur(t){return Ur="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ur(t)}function Fr(t,e,r){return(e=function(t){var e=function(t,e){if("object"!==Ur(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,"string");if("object"!==Ur(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===Ur(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Gr={"cant-find-school":_r,"enter-email":_r,"find-school":_r,"select-type":_r,completed:_r,"add-to-braze":_r,"enter-age":_r,"request-access":_r},Dr={"cant-find-school":Ar,"enter-email":Ar,"find-school":Ar,"select-type":Ar,completed:Ar,"add-to-braze":Ar,"enter-age":Ar,"request-access":Ar},Rr=Fr(Fr({},br.c.FullPage,Dr),br.c.Popup,Gr),Mr={getLayouts:function(t){return Rr[t]}},Kr=r(17331);function Yr(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function zr(t){return zr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},zr(t)}function qr(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(t,e)||Vr(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Vr(t,e){if(t){if("string"==typeof t)return Br(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Br(t,e):void 0}}function Br(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function $r(t,e){var r,n,o=Object.assign(Object.assign({},t),{previousStepIds:[].concat((n=t.previousStepIds,function(t){if(Array.isArray(t))return Br(t)}(n)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(n)||Vr(n)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),[t.currentStepId]),currentStepId:e.step});if("select-type"===e.step)return Object.assign({},o);if("enter-email"===e.step||"enter-age"===e.step)return Object.assign(Object.assign({},o),{userType:e.userType});if("find-school"===e.step)return Object.assign(Object.assign({},o),{email:e.email});if("cant-find-school"===e.step)return Object.assign(Object.assign({},o),{prospectId:e.prospectId,schoolName:e.schoolName,schoolLocality:e.schoolLocality,country:e.country,longitude:e.longitude,latitude:e.latitude,city:e.city,province:e.province});if("add-to-braze"===e.step||"completed"===e.step||"request-access"===e.step){var a=Object.assign({},e);return delete a.type,delete a.step,r=a,a=Object.entries(r).filter((function(t){return null!==qr(t,2)[1]})).reduce((function(t,e){var r=qr(e,2),n=r[0],o=r[1];return Object.assign(Object.assign({},t),function(t,e,r){return(e=function(t){var e=function(t,e){if("object"!==zr(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,"string");if("object"!==zr(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===zr(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}({},n,o))}),{}),Object.assign(Object.assign({},o),a)}}function Hr(t,e){switch(e.type){case"nextStep":return $r(t,e);case"back":return function(t){var e,r=function(t){if(Array.isArray(t))return Yr(t)}(e=t.previousStepIds)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(e)||function(t,e){if(t){if("string"==typeof t)return Yr(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Yr(t,e):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),n=r.pop();return Object.assign(Object.assign({},t),{previousStepIds:r,currentStepId:n})}(t)}}function Zr(t){return Zr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Zr(t)}function Jr(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);l=!0);}catch(t){u=!0,o=t}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return Wr(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Wr(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Wr(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}var Xr=function(t){var e=t.location,r=t.initialValues,o=t.onStepUpdate,a=t.externalLogUserAction,c=U.removeEmptyKeys(r),l=Object.assign({currentStepId:"select-type",previousStepIds:[]},c),u=Jr(n.useReducer(Hr,l),2),s=u[0],f=u[1];return n.useEffect((function(){null==o||o(s)}),[s.currentStepId]),{state:s,back:function(){f({type:"back"})},nextStep:function(t){f(Object.assign({type:"nextStep"},t))},complete:function(t){f(Object.assign({type:"nextStep",step:"completed"},t))},hasPreviousStep:!!s.previousStepIds.length,logUserAction:function(t,r){var n=Object.assign(Object.assign({},s),t),o=Kr.i.filterBlacklistedKeys(n),c=Object.assign({currentStepId:s.currentStepId},o),l=Object.entries(c).filter((function(t){return void 0!==Jr(t,2)[1]})).reduce((function(t,e){var r=Jr(e,2),n=r[0],o=r[1];return Object.assign(Object.assign({},t),function(t,e,r){return(e=function(t){var e=function(t,e){if("object"!==Zr(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,"string");if("object"!==Zr(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===Zr(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}({},n,o))}),{});a(l,Object.assign({entity:i.py.SignUp,location:e},r))}}};function Qr(t){var e=Mr.getLayouts(t.type),r=t.location,i=t.initialValues,c=t.geoLocation,l=t.googleMapsApiKey,u=t.pageAppLinkString,s=t.onStepUpdate,f=t.imageUrls,p=t.ajaxUrls,h=t.brazeConfig,d=t.version,y=t.productName,m=t.close,v=Xr({location:r,initialValues:i,onStepUpdate:s,externalLogUserAction:a.k.logUserAction}),g=v.back,b=v.nextStep,w=v.complete,E=v.hasPreviousStep,S=v.state,x=v.logUserAction,L={state:S,geoLocation:c,layoutMapping:e,hasPreviousStep:E,googleMapsApiKey:l,pageAppLinkString:u,back:g,close:m,nextStep:b,complete:w,logUserAction:x,imageUrls:f,ajaxUrls:p,brazeConfig:h,version:d,productName:y};return n.useEffect((function(){o.SG.get(Le)&&w({completionStep:"young-student",trialCreated:!1,trialStatus:null})}),[]),n.createElement(n.Fragment,null,n.createElement(pr,Object.assign({},L)),n.createElement(gr,{developmentEnv:!1,objects:Object.assign(Object.assign(Object.assign({},S),{pageAppLinkString:u}),c)}))}},83529:(t,e,r)=>{var n;r.d(e,{c:()=>n}),function(t){t.Popup="popup-form",t.FullPage="full-page-form"}(n||(n={}))},12238:(t,e,r)=>{var n;r.d(e,{C:()=>n}),function(t){t.MasterId="master_id",t.CrmId="crm_id",t.SalesforceId="salesforce_id"}(n||(n={}))},84789:(t,e,r)=>{var n;r.d(e,{X:()=>n}),function(t){t.Lite="lite",t.Auth="auth"}(n||(n={}))},17331:(t,e,r)=>{r.d(e,{i:()=>o});var n=["email","longitude","latitude","trialCreated"],o={filterBlacklistedKeys:function(t){var e=Object.assign({},t);return n.forEach((function(t){return delete e[t]})),e}}},69624:(t,e,r)=>{r.d(e,{F:()=>c});var n=r(97395),o=r(86664),a=r(93824),i={Marketing:{au:"https://www.clickview.com.au",uk:"https://www.clickview.co.uk",nz:"https://www.clickview.co.nz",us:"https://www.clickvieweducation.com"},Support:{au:"https://www.clickviewsupport.com/hc/en-au",uk:"https://www.clickviewsupport.com/hc/en-au#gb",nz:"https://www.clickviewsupport.com/hc/en-au#nz",us:"https://www.clickviewsupport.com/hc/en-au#us"}},c={getMarketingUrlForGeoLocation:function(t){var e=o.I.getCountryCode(null==t?void 0:t.countryCode);return i.Marketing[e]||i.Marketing.us},getMarketingSalesContactForGeoLocation:function(t){var e=o.I.getCountryCode(null==t?void 0:t.countryCode),r=this.getMarketingUrlForGeoLocation(t);return t&&e===a.C.NZ?r+"/contact-us/":r+"/contact-us/trial/"},getFreeResourcesForGeoLocation:function(t){var e=o.I.getCountryCode(null==t?void 0:t.countryCode);return e===a.C.NZ&&(e=a.C.AU),this.getMarketingUrlForGeoLocation({countryCode:e})+"/free-student-resources//"},getTermsAndConditionsLink:function(){return this.getMarketingUrlForGeoLocation(a.C.US)+"/terms-and-conditions/"},getPrivacyPolicyLink:function(){return this.getMarketingUrlForGeoLocation(a.C.US)+"/privacy-policy/"},getSupportUrlForGeoLocation:function(t){var e=o.I.getCountryCode(null==t?void 0:t.countryCode);return i.Support[e]||i.Support.us},getLoginLink:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=t.email,r=t.customerId,o={redirectUrl:window.location.pathname+window.location.search};return e&&(o.email=e),r&&(o.customerId=r),n._.urlBuilder("/login",o)}}},86664:(t,e,r)=>{r.d(e,{I:()=>l});var n=r(83765),o=r(93824),a=["uk","gb","gg","im","je","ie"],i={au:o.C.AU,nz:o.C.NZ,us:o.C.US,uk:o.C.UK,gb:o.C.UK,gg:o.C.UK,im:o.C.UK,je:o.C.UK,ie:o.C.UK},c={au:n.M.CvApSoutheast1,uk:n.M.CvEuWest1,us:n.M.CvNaWest1,nz:n.M.CvApSoutheast2},l={getInstanceRegion:function(t){var e=l.getCountryCode(t);return c[e]},getCountryCode:function(t){return i[null==t?void 0:t.toLowerCase()]||o.C.US},isCountryCodeUK:function(t){return a.includes(t.toLowerCase())},isCountryCodeAU:function(t){return(null==t?void 0:t.toLowerCase())===o.C.AU},isCountryCodeUS:function(t){return(null==t?void 0:t.toLowerCase())===o.C.US},isCountryCodeNZ:function(t){return(null==t?void 0:t.toLowerCase())===o.C.NZ},isSupportedCountryCode:function(t){return Object.keys(i).includes(null==t?void 0:t.toLowerCase())},getLocalizedLocalityPlaceholderPhrase:function(t){if(t)return l.isCountryCodeUK(t)?"E.g. CR0 3RL or 36 Factory Lane":l.isCountryCodeAU(t)||l.isCountryCodeNZ(t)?"E.g. 2212 or Revesby":l.isCountryCodeUS(t)?"E.g. 95826 or Sacramento":void 0},getLocalizedLocalityPlaceholderText:function(t){if(t){var e=l.getLocalizedLocalityPlaceholderPhrase(t);if(e)return e}}}},93824:(t,e,r)=>{var n;r.d(e,{C:()=>n}),function(t){t.AU="au",t.NZ="nz",t.UK="uk",t.US="us"}(n||(n={}))},48456:(t,e,r)=>{r.d(e,{v:()=>o});var n=r(99742),o={popupDashboard:n.W.SignUp.POPUP_DASHBOARD,educator:n.W.SignUp.EDUCATOR,student:n.W.SignUp.STUDENT,statusImages:{available:n.W.SignUp.VERIFY_ACCOUNT,active:n.W.SignUp.EXISTING_CUSTOMER,expired:n.W.SignUp.EXPIRED_TRIAL,notRequired:n.W.SignUp.EXISTING_CUSTOMER,unavailable:n.W.SignUp.NOT_AVAILABLE,unsupported:n.W.SignUp.NOT_AVAILABLE,autoJoin:n.W.SignUp.EXISTING_CUSTOMER,requestAccess:n.W.SignUp.EXISTING_CUSTOMER}}},17762:(t,e,r)=>{r.d(e,{M:()=>i});var n=r(20354),o=r(39151),a={countryCode:"us",isFallback:!0};function i(){var t=n.a.useBasicFetch(o.L.geoLocation());return t.hasCompleted&&!t.data?a:t.data}},63643:(t,e,r)=>{r.d(e,{c:()=>c});var n=r(97395),o=r(20354),a=r(84789),i=r(39151);function c(){var t=o.a.useBasicFetch(i.L.config());if(!t.hasCompleted)return null;var e=t.data.gatewayApiUrl;return{productName:a.X.Lite,userStatus:n._.safeUrlConcat(e,"/v1/users/trial-status"),prospectStatus:function(t){return n._.safeUrlConcat(e,"/v1/prospects/".concat(t,"/trial-status"))},createTrial:"/api/user/trials",resendTrialEmail:function(t){return"/api/user/trials/users/".concat(t,"/send-activation-email")},searchProspect:n._.safeUrlConcat(e,"/v1/search/prospects"),createProspect:"/api/prospects",prospectLookups:function(t){return n._.safeUrlConcat(e,"/v1/prospects/".concat(t,"/lookups"))},autoJoin:"/api/user/trials/auto-join",joinRequest:function(t){return"/api/user/customers/".concat(t,"/join-requests")}}}},28366:(t,e,r)=>{r.d(e,{Z:()=>n});const n={logo:"Kh4Dd",modalBody:"V9nIN",popupButton:"hS60U",leftHalfLayout:"aQ1K8",withBg:"zALxE"}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[4705],{7542:(e,t,r)=>{r.r(t),r.d(t,{BulkUserUploadReviewExistingAccountsView:()=>T});var n=r(32735),a=r(20354),i=r(56532),s=r(23481),o=r(2948),l=r(21818),u=r(83345),c=r(38143),d=r(76881),p=r(299);function f(e,t){if(e){if("string"==typeof e)return m(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?m(e,t):void 0}}function m(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function g(e){var t,r,a,i=(r=(0,o.D)(c.g.BULK_USER_UPLOAD),a=2,function(e){if(Array.isArray(e))return e}(r)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,a,i,s,o=[],l=!0,u=!1;try{if(i=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=i.call(r)).done)&&(o.push(n.value),o.length!==t);l=!0);}catch(e){u=!0,a=e}finally{try{if(!l&&null!=r.return&&(s=r.return(),Object(s)!==s))return}finally{if(u)throw a}}return o}}(r,a)||f(r,a)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),g=i[0],y=i[1];n.useEffect((function(){y("existingUserToAdd",e.existingUsers)}),[]);var h=e.existingUsers,k=(0,p.X)(h,{idField:"lookupId",preselectedIds:h.map((function(e){return e.lookupId}))}),b=e.userType===d.Y.Learner?"userManager.existingStudent":"userManager.existsingStaff",x=s.T.encloseNamespace(b),v={firstName:x("tooltip",{field:"first name"}),lastName:x("tooltip",{field:"last name"}),username:x("tooltip",{field:"username"})};return(null===(t=e.users)||void 0===t?void 0:t.length)&&e.users?n.createElement(n.Fragment,null,n.createElement("h2",{className:"h4"},n.createElement(u.x,{namespace:b,phrase:"heading"})),n.createElement("main",{className:"pb-3"},n.createElement("p",null,n.createElement(u.x,{namespace:b,phrase:"subheading"})),n.createElement("p",null,n.createElement(u.x,{namespace:b,phrase:"actions"})),n.createElement(l.M,{users:h,invalidUsers:{},userType:e.userType,appLinks:e.appLinks,isChecked:k.isChecked,tooltips:v,checkboxId:"bulk-upload-review-existing-accounts",onToggleCheckbox:function(t){g.existingUserToAdd.find((function(e){return e.lookupId===t}))?y("existingUserToAdd",g.existingUserToAdd.filter((function(e){return e.lookupId!==t}))):y("existingUserToAdd",[].concat(function(e){return function(e){if(Array.isArray(e))return m(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||f(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(g.existingUserToAdd),[e.users.find((function(e){return e.lookupId===t}))])),k.onToggleItem(t)},onToggleBulkCheckbox:function(t){k.onToggleBulk(),t.target.checked?y("existingUserToAdd",e.existingUsers):y("existingUserToAdd",[])},bulkCheckboxChecked:k.bulkChecked,bulkIndeterminate:k.hasSomeSelections()}))):n.createElement(n.Fragment,null)}var y=r(26055),h=r(43820),k=r(45541),b=r(31949),x=r(47288),v=r(18087);function T(e){var t=(0,k.V)(),r=t.users,s=t.existingUsersHash,o=a.a.useBasicFetch(b.N.currentUser()),l=a.a.useBasicFetch(o.data&&x.N.yearGroups(o.data.customerId)),u=(0,v.Y)(e.userType);return o.data&&l.data?n.createElement(y.A.Provider,{value:h.a.Primary},n.createElement(i.$,{appLinks:u,userType:e.userType,currentStep:"review-existing-accounts",canAddExistingUsers:!0},n.createElement("div",{className:"px-3"},n.createElement(g,{users:r,closePopup:e.closePopup,appLinks:u,userType:e.userType,yearGroups:l.data,existingUsers:null==r?void 0:r.filter((function(e){return!!s[e.lookupId]}))})))):n.createElement(n.Fragment,null)}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[5765],{56532:(e,t,n)=>{n.d(t,{A:()=>U,$:()=>L});var r=n(32735),a=n(23481),i=n(81886),s=n(36848),l=n(83345),c="userManager.userWizardBackButtons";function u(e){return"status"===e.currentStep?r.createElement(r.Fragment,null):r.createElement(s.F,{className:"btn btn-link me-2",appLink:e.appLinks.userManager},r.createElement(l.x,{namespace:c,phrase:"cancel"}))}var o=n(98269),d=n(24453),p=n(45541),m=n(96728),v="userManager.userWizardHeader";function b(e){var t=(0,p.V)(),n=t.duplicateSets,a=t.hasExistingUsers,i=r.useContext(m.e),c=i.disableNext,u=i.onClickConfirm,b=!!(null==n?void 0:n.length),f=d.O.getCurrentContext().appLink;return f.action===e.appLinks.userUploadStatus.complete.action?r.createElement(s.F,{className:"btn btn-dark ".concat(c?"disabled":""),appLink:e.appLinks.userManager,disabled:c},r.createElement(l.x,{namespace:v,phrase:"finish"})):f.action===e.appLinks.userUploadStatus.polling.action?r.createElement(r.Fragment,null):function(){switch(f.action){case e.appLinks.userUploadPopup.action:case e.appLinks.userUploadReviewAccounts.action:return!b&&!a;case e.appLinks.userUploadFixDuplicates.action:case e.appLinks.userUploadReviewExistingAccounts.action:return!a;default:return!0}}()?r.createElement(o.Z,{className:c?"disabled":"",variant:"dark",onClick:u,disabled:c},r.createElement(l.x,{namespace:v,phrase:"create"})):r.createElement(s.F,{className:"btn btn-dark ".concat(c?"disabled":""),appLink:function(){switch(f.action){case e.appLinks.userUploadReviewAccounts.action:if(b)return e.appLinks.userUploadFixDuplicates;if(a&&e.canAddExistingUsers)return e.appLinks.userUploadReviewExistingAccounts;case e.appLinks.userUploadFixDuplicates.action:if(a&&e.canAddExistingUsers)return e.appLinks.userUploadReviewExistingAccounts;case e.appLinks.userUploadReviewExistingAccounts.action:if(e.canAddExistingUsers)return e.appLinks.userUploadConfirmation;default:return null}}(),disabled:c},r.createElement(l.x,{namespace:v,phrase:"next"}))}var f=n(19717),g=n(17291),k=n(79352),h=n(76881),E=n(89476);const x={wizardContent:"hHr3C"};var y="userManager.bulkUserUploadWizardLayout",U="bulk:user:upload:nav:lock";function L(e){var t=(0,p.V)(),n=t.users,s=t.setUsers,l=(0,E.f)();return r.useEffect((function(){if(n)return l.lock({id:U,title:a.T.getPhrase(y,"navLockTitle"),text:a.T.getPhrase(y,"navLockBody"),appLinkWhitelist:f.b.getWizardAppLinks(e.appLinks),onConfirmUnlock:function(){s(null)}}),function(){l.unlock(U)};i.Q.C$.trigger(e.appLinks.userManager,{replace:!0})}),[]),r.useEffect((function(){(null==n?void 0:n.length)||(l.unlock(U),i.Q.C$.trigger(e.appLinks.userManager,{replace:!0}))}),[null==n?void 0:n.length]),n?r.createElement(m.D,null,r.createElement("div",{className:"px-3"},r.createElement(g.C,{title:a.T.getPhrase(y,"bulkUpload"),currentStep:e.currentStep,loaded:!0,continueButton:r.createElement(b,{currentStep:e.currentStep,appLinks:e.appLinks,canAddExistingUsers:e.canAddExistingUsers}),backButton:r.createElement(u,{currentStep:e.currentStep,appLinks:e.appLinks}),breadcrumbs:[{name:a.T.getPhrase(y,"settingsBreadcrumb"),appLink:e.appLinks.settings},{name:a.T.getPhrase(y,e.userType===h.Y.Learner?"studentManager":"staffManager"),appLink:e.appLinks.userManager},{name:a.T.getPhrase(y,"bulkUpload"),active:!0}]}),r.createElement("div",{className:"row g-0"},r.createElement("div",{className:"col-2"},r.createElement(k.a,{steps:f.b.getSteps(e.userType,e.canAddExistingUsers),currentStep:e.currentStep})),r.createElement("div",{className:"col-10 ".concat(x.wizardContent)},e.children)))):r.createElement(r.Fragment,null)}},26055:(e,t,n)=>{n.d(t,{A:()=>r});var r=n(32735).createContext(null)},45541:(e,t,n)=>{n.d(t,{V:()=>u});var r=n(2948),a=n(38143),i=n(39739);function s(e){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s(e)}function l(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function c(e,t){return Object.keys(e||{}).reduce((function(n,r){return t[r]||(n[r]=e[r]),n}),{})}var u=function(){var e,t,n,u=(t=(0,r.D)(a.g.BULK_USER_UPLOAD),n=2,function(e){if(Array.isArray(e))return e}(t)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,a,i,s,l=[],c=!0,u=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);c=!0);}catch(e){u=!0,a=e}finally{try{if(!c&&null!=n.return&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw a}}return l}}(t,n)||function(e,t){if(e){if("string"==typeof e)return l(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?l(e,t):void 0}}(t,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),o=u[0],d=u[1];function p(e){var t=i.P.getNewDuplicates(e);d("duplicateSets",t)}return{users:null==o?void 0:o.users,invalidUsers:null==o?void 0:o.invalidUsers,hasValidatedUsers:!!(null==o?void 0:o.invalidUsers),existingUsersHash:(null==o?void 0:o.existingUsersHash)||{},hasExistingUsers:!!Object.keys((null==o?void 0:o.existingUsersHash)||{}).length,existingUserToAdd:null==o?void 0:o.existingUserToAdd,duplicateSets:null==o?void 0:o.duplicateSets,newUsers:(null===(e=null==o?void 0:o.users)||void 0===e?void 0:e.filter((function(e){var t;return!(null===(t=null==o?void 0:o.existingUsersHash)||void 0===t?void 0:t[e.lookupId])})))||[],setUsers:function(e){d({users:e,invalidUsers:null,existingUsersHash:null}),p(e)},setInvalidUsers:function(e){return d("invalidUsers",e)},setExistingUsers:function(e){return d("existingUsersHash",e)},updateUser:function(e){var t,n,r,a=o.users.map((function(t){return t.lookupId!==e.lookupId?t:e}));d({users:a,invalidUsers:c(null==o?void 0:o.invalidUsers,(t={},n=e.lookupId,r=!0,(n=function(e){var t=function(e,t){if("object"!==s(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!==s(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===s(t)?t:String(t)}(n))in t?Object.defineProperty(t,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[n]=r,t)),existingUsersHash:null==o?void 0:o.existingUsersHash}),p(a)},deleteUsers:function(e){var t,n=e.reduce((function(e,t){return e[t]=!0,e}),{}),r=o.users.filter((function(e){return!n[e.lookupId]}));d({users:r,invalidUsers:c(null==o?void 0:o.invalidUsers,n),existingUsersHash:c(null==o?void 0:o.existingUsersHash,n),existingUserToAdd:null===(t=null==o?void 0:o.existingUserToAdd)||void 0===t?void 0:t.filter((function(e){return!!(null==o?void 0:o.existingUsersHash[e.lookupId])}))}),p(r)}}}},49935:(e,t,n)=>{n.d(t,{Oo:()=>d,b2:()=>p});var r=n(32735),a=n(36848),i=n(86764),s=n(3747),l=n(5859),c=n(35223),u=n(83914),o=function(e){var t=e.breadcrumb,n=t.name,i=t.appLink,s=t.active,l=e.withBackIcon;return r.createElement("li",{className:"breadcrumb-item".concat(s?" active":"")},s?r.createElement("strong",null,n):r.createElement(a.F,{appLink:i},l&&r.createElement(u.x,{svgName:c.vn.ChevronLeft,size:u.S.Small}),r.createElement("span",{className:l?"ms-2":""},n)))},d=function(e){var t=e.breadcrumbs,n=(0,s.a)(i.r.XS),a=null==t?void 0:t.length;return!a||n&&a<2?r.createElement(r.Fragment,null):n?r.createElement("nav",{"aria-label":"breadcrumb"},r.createElement("ol",{className:"breadcrumb m-0 p-0"},r.createElement(o,{breadcrumb:t[a-2],withBackIcon:!0}))):r.createElement("nav",{"aria-label":"breadcrumb"},r.createElement("ol",{className:"breadcrumb m-0 p-0"},t.map((function(e,t){return r.createElement(o,{key:t,breadcrumb:e})}))))},p=r.memo((function(e){var t=e.numItems,n=void 0===t?3:t;return(0,s.a)(i.r.XS)?r.createElement("div",{className:"partial-loading-background",style:{height:"1.3125rem",width:"6rem"}}):r.createElement("nav",{"aria-label":"breadcrumb"},r.createElement("ol",{className:"breadcrumb m-0 p-0"},l.u.getPartialLoadingItems({numItems:n}).map((function(e,t){var n=e.width;return r.createElement("li",{key:t,className:"breadcrumb-item"},r.createElement("span",{className:"d-inline-block partial-loading-background",style:{width:n},dangerouslySetInnerHTML:{__html:"&nbsp"}}))}))))}))},17291:(e,t,n)=>{n.d(t,{C:()=>s});var r=n(32735),a=n(49935),i=n(96728);function s(e){var t=r.useContext(i.e).showButtons;return r.createElement("div",{className:"d-flex justify-content-between"},e.hideHeader?r.createElement("div",null):r.createElement("div",null,r.createElement("h1",{className:"h2"},e.title),e.breadcrumbs&&r.createElement("div",{className:"pb-3"},r.createElement(a.Oo,{breadcrumbs:e.breadcrumbs}))),e.loaded&&t&&r.createElement("div",{className:"d-flex align-items-center"},e.backButton,e.continueButton))}},79352:(e,t,n)=>{n.d(t,{a:()=>c});var r=n(32735),a=n(23481),i=n(36848),s=a.T.encloseNamespace("shared.wizardStepList");function l(e){var t="",n="";e.isSelected&&(t+=" fw-semibold"),(!e.isSelected&&!e.isCompleted||e.disabled)&&(t+=" text-muted",n+=" text-muted");var a=r.createElement(r.Fragment,null,r.createElement("div",{className:"".concat(t," d-flex")},!e.hideStepNumber&&r.createElement("div",{className:"flex-shrink-0 flex-grow-0"},"".concat(e.index+1,".")," "),r.createElement("div",null,e.text)),e.subText&&r.createElement("div",{className:"ms-2 ps-1 pt-1 ".concat(n)},e.subText)),s="".concat(e.isSelected?"bg-light-blue":""," px-2 py-1 mb-1 rounded d-inline-block");return r.createElement("li",null,e.isCompleted&&e.appLink?r.createElement(i.F,{appLink:e.appLink,className:s},a):r.createElement("div",{className:s},a))}function c(e){var t=e.steps.reduce((function(t,n,r){return n.id===e.currentStep&&(t=r+1),t}),1);return r.createElement(r.Fragment,null,r.createElement("h2",{className:"h4"},s("stepNumber",{currentStep:t,totalSteps:e.steps.length})),r.createElement("ol",{className:"list-unstyled"},e.steps.map((function(n,a){var i=n.id===e.currentStep,s=t>a+1;return r.createElement(l,{index:a,key:n.id,text:n.text,subText:n.subText,isSelected:i,isCompleted:s,appLink:!e.disableAppLinks&&n.appLink,disabled:n.disabled})}))))}},5859:(e,t,n)=>{function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}n.d(t,{u:()=>i});var a={numItems:5,minWidth:50,maxWidth:100},i={getPartialLoadingItems:function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=Object.assign(Object.assign({},a),t);return(e=Array(n.numItems),function(e){if(Array.isArray(e))return r(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).map((function(){return{width:"".concat(Math.max(Math.floor(Math.random()*n.maxWidth),n.minWidth),"px")}}))}}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[6330],{21281:(e,r,a)=>{a.r(r),a.d(r,{AddToLibraryView:()=>B});var t,i=a(32735),n=a(60139),l=a(23481),o=a(20354),d=a(75896),s=a(28400),u=a(82644),c=a(9111);!function(e){e[e.MasterVideo=1]="MasterVideo",e[e.MasterClip=2]="MasterClip",e[e.MasterInteractive=3]="MasterInteractive"}(t||(t={}));var m=a(4594),b=a(98064),v=a(31949),f=a(69883),p=a(59934),y=a(31908),g=a(68140),h=a(14070),T=a(97291),E=a(98495),S=a(92802),L=a(38365),C=a(13876),P=a(83345),F=a(55367),I=a(11462),k="libraries.addToLibraryForm",M=l.T.encloseNamespace(k);function R(e){var r,a,t,n=(0,u.b)(),o=!n.values.library.canAddContent,d=e.video.libraries.data.find((function(e){return e.id===n.values.library.id})),s=i.useMemo((function(){return{children:e.getCategoryTree(n.values.library.id).map(I.d.convertNestedObjectToTree)}}),[n.values.library.id]);return i.createElement(i.Fragment,null,d&&i.createElement("div",{className:"alert alert-info"},i.createElement(P.x,{namespace:k,phrase:"alreadyInLibrary",options:{library:n.values.library.name}})),o&&i.createElement("p",null,i.createElement(P.x,{namespace:k,phrase:"sendLibraryRequest",options:{video:e.video.name}})),i.createElement(S.l0,null,e.libraries.length>1&&i.createElement(L.W,{as:"select",label:M("selectLibrary"),name:"library",value:null!==(a=null===(r=n.values.library)||void 0===r?void 0:r.id)&&void 0!==a?a:"",className:(null===(t=n.values.library)||void 0===t?void 0:t.id)?"":"text-secondary",showRequiredStar:!0,onChange:function(r){n.setFieldValue("folder",null);var a=r.target.value;n.setFieldValue("library",e.libraries.find((function(e){return e.id.toString()===a.toString()})))}},e.libraries.map((function(e){return i.createElement("option",{key:e.id,value:e.id,className:"text-dark"},e.name)}))),i.createElement(L.W,{label:M("selectFolder"),name:"folder",showRequiredStar:!0,disabled:!n.values.library},(function(){var r;return i.createElement(E.ZP,{autoHeight:!0,autoHeightMax:300,className:"border rounded-3"},i.createElement(F.m,{tree:s,onSelect:function(e){return n.setFieldValue("folder",e)},isDisabled:e.isFolderDisabled,disabledTooltip:l.T.getPhrase(k,"disabledFolder"),selectedIds:(null===(r=n.values.folder)||void 0===r?void 0:r.id)?[n.values.folder.id]:void 0,selectedLinkClassName:"bg-light"}))})),!!n.values.folder&&i.createElement("p",{className:"mt-n2"},i.createElement(P.x,{namespace:k,phrase:o?"requestTo":"addTo",options:{folder:n.values.folder.name}})),o&&i.createElement(L.W,{label:l.T.getPhrase(k,"comment"),as:"textarea",name:"comment",id:"comment",placeholder:l.T.getPhrase(k,"commentPlaceholder"),value:n.values.comment}),i.createElement(C.u,null,i.createElement(C.u.Cancel,{onClick:e.closePopup}),i.createElement(C.u.Submit,{variant:"dark",text:M("addToLibrary")}))))}var x=a(48688),N=a(5173),q="libraries.validation",w=(0,N.Ry)().shape({comment:(0,N.Z_)().nullable().max(512,(function(){return l.T.getPhrase(q,"commentExceeds")})),library:(0,N.Ry)().required((function(){return l.T.getPhrase(q,"libraryRequired")})).nullable(),folder:(0,N.Ry)().required((function(){return l.T.getPhrase(q,"folderRequired")})).nullable()});function V(e){return V="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},V(e)}function A(e,r,a){return(r=function(e){var r=function(e,r){if("object"!==V(e)||null===e)return e;var a=e[Symbol.toPrimitive];if(void 0!==a){var t=a.call(e,"string");if("object"!==V(t))return t;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===V(r)?r:String(r)}(r))in e?Object.defineProperty(e,r,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[r]=a,e}var D=A(A(A({},m.E.Video,t.MasterVideo),m.E.Clip,t.MasterClip),m.E.Interactive,t.MasterInteractive),j=l.T.encloseNamespace("libraries.addToLibrary");function B(e){var r=o.a.useBasicFetch(v.N.currentUser()),a=o.a.useBasicFetch(b.D.librariesWithCategories()),t=o.a.useBasicFetch(b.D.libraryRequestLibraries()),l=y.M.getVideoRequest(e.id,e.typeId),m=o.a.useBasicFetch(l),E=i.useMemo((function(){return x.g.sort(t.data)}),[t.data]),S=o.a.useGetFetchAsync(),L=(0,f.Z)(),C=!!r.data&&g.d.getOrSetSortType(r.data.id),P=t.hasCompleted&&m.hasCompleted&&a.hasCompleted;return i.createElement(c.G,{title:j("addToLibrary"),closePopup:e.closePopup,showLoadingSpinner:!P},P&&i.createElement(u.n,{initialValues:{library:d.m.first(E),folder:null,comment:""},validationSchema:w,onSubmit:function(r,a){var t,i={objectId:e.id.toString(),objectType:D[e.typeId],message:r.comment,sourceLibraryId:+d.m.first(m.data.libraries.data).id,destinationLibraryId:+r.library.id,metadata:{destinationCategoryId:+r.folder.id}};if(null===(t=m.data.categories.data)||void 0===t?void 0:t.length){var l=m.data.categories.data.find((function(e){var r,a;return null===(a=null===(r=e.libraries)||void 0===r?void 0:r.data)||void 0===a?void 0:a.find((function(e){return e.id.toString()===i.sourceLibraryId.toString()}))}));l&&(i.metadata.sourceCategoryId=+l.id)}S(b.D.addToLibrary(i,C)).then((function(){r.library.canAddContent?L.success({type:n.NK.Success,heading:"",message:j("addToLibrarySuccess",{folder:r.folder.name,video:m.data.name,escapeText:!0}),appLink:{application:T.O.LIBRARIES,action:h.e.Libraries.FOLDER,args:[r.library.id,r.folder.id,s.m.slugify(r.folder.name)]},appLinkText:j("goToFolder",{folder:r.folder.name}),appLinkClassName:"info-link"}):L.success({type:n.NK.Pending,heading:j("pendingApproval"),message:j("libraryRequestSent",{library:r.library.name,escapeText:!0})})})).catch((function(e){L.error(p.M.libraryApiError(e)),a()})).finally((function(){e.closePopup()}))}},i.createElement(R,{libraries:E,closePopup:e.closePopup,isFolderDisabled:function(e){var r,a;return!!(null===(a=null===(r=m.data.categories)||void 0===r?void 0:r.data)||void 0===a?void 0:a.find((function(r){return r.id===e.id})))},video:m.data,getCategoryTree:function(e){var r;return null===(r=a.data.find((function(r){return r.data.id.toString()===e.toString()})))||void 0===r?void 0:r.children}})))}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[6480],{9826:(e,t,n)=>{n.d(t,{e:()=>f});var r=n(32735),a=n(79014),c=n(86764),l=n(81514),i=n(10038);const o={stickyFooter:"rIUL4",nonStickyFooter:"PuC_F"};function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var u=50;function d(e){var t="justify-content-".concat(e.justify);return r.createElement("div",{className:"py-3 bg-white ".concat(o.stickyFooter)},r.createElement("div",{className:"w-75 mx-auto d-flex ".concat(t)},e.children))}function m(e){var t=(0,l.V)(),n=t===c.r.SM||t===c.r.XS?"w-100":"w-75",a="justify-content-".concat(e.justify);return r.createElement("div",{className:"".concat(n," ").concat(a," ").concat(o.nonStickyFooter," d-flex px-3")},e.children)}function f(e){var t,n,c=function(){return window.innerHeight+window.scrollY>=document.body.offsetHeight-u},l=(t=r.useState(!1),n=2,function(e){if(Array.isArray(e))return e}(t)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,a,c,l,i=[],o=!0,s=!1;try{if(c=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;o=!1}else for(;!(o=(r=c.call(n)).done)&&(i.push(r.value),i.length!==t);o=!0);}catch(e){s=!0,a=e}finally{try{if(!o&&null!=n.return&&(l=n.return(),Object(l)!==l))return}finally{if(s)throw a}}return i}}(t,n)||function(e,t){if(e){if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}(t,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),o=l[0],f=l[1];r.useEffect((function(){return f(!c())}),[]);var p=a.q.throttle((function(){var e=!c();!o||e?!o&&e&&f(!0):f(!1)}),100);return r.useEffect((function(){return window.addEventListener("scroll",p),function(){return window.removeEventListener("scroll",p)}}),[o,f]),(0,i.H)(p,p,[o,f]),o?r.createElement(d,Object.assign({},e),e.children):r.createElement(m,Object.assign({},e),e.children)}f.defaultProps={justify:"between"}},32697:(e,t,n)=>{n.d(t,{ed:()=>r.e,cQ:()=>f.c,i:()=>m,RP:()=>h});var r=n(9826),a=n(32735);n(36848);var c=n(75896),l=n(70154),i=n(86764),o=n(81514),s=n(92875),u=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var a=0;for(r=Object.getOwnPropertySymbols(e);a<r.length;a++)t.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(e,r[a])&&(n[r[a]]=e[r[a]])}return n};function d(e){var t=a.useContext(l.x),n=t.expandedSubject,r=t.selectedSubjects;return a.createElement(a.Fragment,null,e.subjects.map((function(t){var c=function(e,t){return!(!t||e.id===t.id||t.children.find((function(t){return t.id===e.id})))}(t,n),l=e.onSelect;return t.isExpandableOption&&(l=e.onExpand),c&&(l=e.onCollapse),e.hasSelectedBulk&&(l=function(){}),a.createElement(h,{key:t.id,subject:t,selected:!e.hasSelectedBulk&&r.includes(t.id),disabled:e.hasSelectedBulk||c,onClick:function(){return l(t)},hasSelectedBulk:e.hasSelectedBulk})})))}function m(e){var t=e.subjects,n=e.hasSelectedBulk,r=u(e,["subjects","hasSelectedBulk"]),f=a.useContext(l.x).expandedSubject,p=function(){switch((0,o.V)()){case i.r.LG:default:return 5;case i.r.MD:return 4;case i.r.SM:return 3;case i.r.XS:return 2}}(),b=t.reduce((function(e,t,n){return n%p==0?e.push([t]):c.m.last(e).push(t),e}),[]);return a.createElement("ul",{className:s.Z.grid},b.map((function(e,t){var c=f&&!!e.find((function(e){return f.id===e.id&&e.isExpandableOption}));return a.createElement(a.Fragment,{key:t},a.createElement(d,Object.assign({subjects:e,hasSelectedBulk:n},r)),c&&a.createElement("li",{className:"".concat(s.Z.subgrid," m-0")},a.createElement(m,Object.assign({subjects:f.children,hasSelectedBulk:n},r))))})))}var f=n(386),p=n(76177),b=n(54610),v=n(67453);function h(e){var t,n,r=a.useContext(l.x),c=e.subject.cover?v.j.createUrl(e.subject.cover.url,{size:b.h2.Small}):"",i=e.subject.isExpandableOption?e.subject.children.map((function(e){return e.id})):[],o=e.hasSelectedBulk?0:null===(t=null==r?void 0:r.selectedSubjects)||void 0===t?void 0:t.filter((function(e){return i.includes(e)})).length,s=a.createElement(f.c,{name:e.subject.name,imageUrl:c,onClick:e.onClick,isSelected:e.selected,isDisabled:e.disabled,isExpandable:e.subject.isExpandableOption,expand:(null===(n=null==r?void 0:r.expandedSubject)||void 0===n?void 0:n.id)===e.subject.id,selectedChildCount:o,extraClasses:e.extraClasses,hideStatus:e.hideStatus});return e.disabled?a.createElement("span",null,s):a.createElement(p.u,{title:e.subject.name},a.createElement("span",null,s))}},386:(e,t,n)=>{n.d(t,{c:()=>s});var r=n(32735),a=n(83914),c=n(35223);const l={preferenceItem:"PSWHa",expandCaret:"CCsqs",up:"w7N1R",down:"mO0Kn",disabled:"Oyw2x",selected:"Czk2N",noBorder:"_e7oe",textBox:"pfksF",itemStatus:"H4u81",unchecked:"iYkPv",green:"w5g0e"};var i=function(e){return e.selectedChildrenCount?r.createElement("div",{className:"".concat(l.itemStatus," ").concat(l.green)},e.selectedChildrenCount):r.createElement(r.Fragment,null)},o=function(e){var t;return t=e.selected?r.createElement(a.x,{svgName:c.vn.Check}):e.radioButton?r.createElement(r.Fragment,null," "):r.createElement(a.x,{svgName:c.vn.Plus}),r.createElement("div",{className:"".concat(l.itemStatus," ").concat(e.selected?l.green:l.unchecked)},t)};function s(e){var t,n="".concat(l.expandCaret," ").concat(e.expand?l.up:l.down);return r.createElement("li",{className:(t="rounded-3 ".concat(l.preferenceItem),e.extraClasses&&(t+=" "+e.extraClasses),e.isDisabled&&(t+=" "+l.disabled),e.isSelected&&!e.isExpandable&&(t+=" "+l.selected),e.hideStatus&&(t+=" "+l.noBorder),t),onClick:e.onClick,"aria-checked":e.isSelected,"aria-haspopup":e.isExpandable,role:e.isExpandable?"button":"checkbox",style:{backgroundImage:"url(".concat(e.imageUrl,")")},tabIndex:0,title:e.name},r.createElement("div",{className:"".concat(l.textBox," p-2")},r.createElement("p",{className:"text-truncate mb-0"},e.name,r.createElement("span",{className:e.isExpandable?n:""})),!e.hideStatus&&r.createElement(r.Fragment,null,e.isExpandable?r.createElement(i,{selectedChildrenCount:e.selectedChildCount}):r.createElement(o,{selected:e.isSelected,radioButton:e.radioButton}))))}},70154:(e,t,n)=>{n.d(t,{x:()=>r});var r=(0,n(32735).createContext)(void 0)},81514:(e,t,n)=>{n.d(t,{V:()=>c});var r=n(86764),a=n(3747);function c(){var e=(0,a.a)(r.r.XS),t=(0,a.a)(r.r.SM),n=(0,a.a)(r.r.MD),c=(0,a.a)(r.r.LG),l=(0,a.a)(r.r.XL),i=(0,a.a)(r.r.XXL),o=r.r.LG;return e&&(o=r.r.XS),t&&(o=r.r.SM),n&&(o=r.r.MD),c&&(o=r.r.LG),l&&(o=r.r.XL),i&&(o=r.r.XXL),o}},26480:(e,t,n)=>{n.r(t),n.d(t,{WelcomePopupView:()=>B});var r=n(32735),a=n(23481),c=n(81886),l=n(75896),i=n(49985),o=n(65858),s=n(32697),u=n(9111),d=n(13876),m=n(83345),f=n(71063),p=n(52641),b=n(54610),v=n(86764),h=n(25925),E=n(69883),y=n(3747),S=n(67453),x=n(99742),g=n(14070),k=n(97291),j=n(86698);const C={preferenceList:"oHNZN",preferenceItem:"olBqT",largePopup:"x3Oot",selectPresentation:"b2r5s",switchPresentation:"NIIWc"};function w(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,a,c,l,i=[],o=!0,s=!1;try{if(c=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;o=!1}else for(;!(o=(r=c.call(n)).done)&&(i.push(r.value),i.length!==t);o=!0);}catch(e){s=!0,a=e}finally{try{if(!o&&null!=n.return&&(l=n.return(),Object(l)!==l))return}finally{if(s)throw a}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return O(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?O(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function O(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var N="settings.welcomePopup",P=a.T.encloseNamespace(N);function B(e){var t=w(r.useState(!1),2),n=t[0],O=t[1],B=w(r.useState(),2),L=B[0],A=B[1],I=(0,y.a)(v.r.SMDown),_=(0,E.Z)(),M=(0,j.y)(),F=M.availablePresentations,U=M.setPresentation,T=M.hasPresentationsLoaded,D=(null==F?void 0:F.length)>=p._.MULTI_PRESENTATION_THRESHOLD;function X(){i.k.logUserAction({id:L.id},{actionType:o.Vw.Click,entity:o.py.Presentation,location:o.LZ.WelcomePopup,workflowPhase:o.eu.Complete,descriptor:o._S.Button,eventVersion:o.eq.V3}),c.Q.C$.trigger({application:k.O.DASHBOARD,action:g.e.Dashboard.HOME}),O(!1),e.closePopup()}function H(){O(!1),_.error(a.T.getPhrase(N,"error"))}function R(){return O(!0),U(L,"activeAndPreferred").then(X).catch(H)}r.useEffect((function(){T&&!D&&A(l.m.first(F))}),[D,T]);var V=function(){return r.createElement(d.u,null,r.createElement(d.u.Submit,{variant:"dark",onClick:R,text:P("cta"),showSpinner:n,disabled:!!D&&!L,className:"mx-auto"}))};return T?r.createElement(u.G,{title:P("title"),size:I?"sm":(null==F?void 0:F.length)>2?"lg":"md",closeButton:!D,closePopup:e.closePopup,backdrop:!D||"static",dialogClassName:f.M.WELCOME_POPUP_SELECTOR,centered:!0},D?r.createElement((function(){return r.createElement("div",{className:"".concat(C.selectPresentation)},r.createElement("h2",{className:"h4 text-center"},r.createElement(m.x,{namespace:N,phrase:"info_primary"})),r.createElement("p",{className:"text-center"},r.createElement(m.x,{namespace:N,phrase:"info_secondary_multi"})),r.createElement("div",{className:"position-relative"},r.createElement("ul",{className:"list-unstyled d-flex ".concat(C.preferenceList)},null==F?void 0:F.map((function(e){var t;return e.type!==h.R.Subject?r.createElement(r.Fragment,{key:e.id}):r.createElement(s.cQ,{key:e.id,name:e.name,imageUrl:S.j.createUrl(null===(t=e.cover)||void 0===t?void 0:t.url,{size:b.h2.Medium})||"",onClick:function(){return A(e)},isSelected:(null==L?void 0:L.id)===e.id,extraClasses:"".concat(C.preferenceItem," m-2"),radioButton:!0})})))),r.createElement(V,null))}),null):r.createElement((function(){return r.createElement("div",{className:"".concat(C.selectPresentation)},r.createElement("div",{className:"d-block mx-auto p-4"},r.createElement("img",{src:x.W.SignUp.UPGRADE,className:"img-fluid",alt:""})),r.createElement("h2",{className:"h4 text-center"},r.createElement(m.x,{namespace:N,phrase:"info_primary"})),r.createElement("p",{className:"text-center"},r.createElement(m.x,{namespace:N,phrase:"info_secondary"})),r.createElement("div",{className:"mt-3"},r.createElement(V,null)))}),null)):r.createElement(r.Fragment,null)}},92875:(e,t,n)=>{n.d(t,{Z:()=>r});const r={grid:"X9r1Y",subgrid:"TgYhp"}}}]);