@clickview/lite 0.42.1 → 0.43.0-rc.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (432) hide show
  1. package/dist/bundles.json +3 -3
  2. package/dist/css/{3514-lite-a288188c68.chunk.css → 1080-lite-de9ac6421b.chunk.css} +1 -0
  3. package/dist/css/1818-lite-028006a5ca.chunk.css +3 -0
  4. package/dist/css/{7115-lite-e1537f9cc8.chunk.css → 1820-lite-269c94b335.chunk.css} +1 -1
  5. package/dist/css/{2669-lite-78061ae375.chunk.css → 2669-lite-b583381d2f.chunk.css} +1 -1
  6. package/dist/css/{3067-lite-c7f65c4123.chunk.css → 2857-lite-177db71e12.chunk.css} +1 -1
  7. package/dist/css/{2925-lite-78061ae375.chunk.css → 2925-lite-b583381d2f.chunk.css} +1 -1
  8. package/dist/css/{2857-lite-c7f65c4123.chunk.css → 3067-lite-177db71e12.chunk.css} +1 -1
  9. package/dist/css/{3715-lite-2000d11798.chunk.css → 3715-lite-f49a034e00.chunk.css} +1 -1
  10. package/dist/css/{3866-lite-961b4c62eb.chunk.css → 3866-lite-1f433df969.chunk.css} +1 -1
  11. package/dist/css/{7381-lite-e234e21b02.chunk.css → 4462-lite-f6609309a8.chunk.css} +1 -8
  12. package/dist/css/{5582-lite-0dec158033.chunk.css → 5582-lite-3656fa2e2f.chunk.css} +1 -1
  13. package/dist/css/5595-lite-9980bec60d.chunk.css +7 -0
  14. package/dist/css/{4448-lite-fa392bb8b0.chunk.css → 6386-lite-8cd1408eac.chunk.css} +1 -8
  15. package/dist/css/{lite-app-cf486ee35c.css → lite-app-4b021f46fd.css} +2 -2
  16. package/dist/languages/en.json +1 -1
  17. package/dist/scripts/1080-200c49fe3b-lite.chunk.js +1 -0
  18. package/dist/scripts/121-2cf64e7e95-lite.chunk.js +1 -0
  19. package/dist/scripts/1276-c906943bd2-lite.chunk.js +2 -0
  20. package/dist/scripts/{1437-f01876ad76-lite.chunk.js → 1437-a6ab2e6a78-lite.chunk.js} +1 -1
  21. package/dist/scripts/1466-8c87c52bac-lite.chunk.js +2 -0
  22. package/dist/scripts/1518-77386b2d14-lite.chunk.js +1 -0
  23. package/dist/scripts/{1526-af2eac3dcb-lite.chunk.js → 1526-58fe2eda49-lite.chunk.js} +1 -1
  24. package/dist/scripts/1605-8220a13462-lite.chunk.js +1 -0
  25. package/dist/scripts/{1672-cef1d67820-lite.chunk.js → 1672-b02899f572-lite.chunk.js} +2 -2
  26. package/dist/scripts/1818-60b36a8821-lite.chunk.js +1 -0
  27. package/dist/scripts/1820-2c41ca7b8c-lite.chunk.js +1 -0
  28. package/dist/scripts/{1895-d44e4310b0-lite.chunk.js → 1895-e0ba3e67e2-lite.chunk.js} +2 -2
  29. package/dist/scripts/209-83a1263bec-lite.chunk.js +1 -0
  30. package/dist/scripts/2118-a1967105c4-lite.chunk.js +2 -0
  31. package/dist/scripts/2235-17d38cbc78-lite.chunk.js +1 -0
  32. package/dist/scripts/2261-a446eedd27-lite.chunk.js +1 -0
  33. package/dist/scripts/2857-1c22bb5b38-lite.chunk.js +1 -0
  34. package/dist/scripts/287-588a4d4455-lite.chunk.js +1 -0
  35. package/dist/scripts/{3020-de61723e0f-lite.chunk.js → 3020-c9116f3b1f-lite.chunk.js} +1 -1
  36. package/dist/scripts/3067-6aaff3789b-lite.chunk.js +1 -0
  37. package/dist/scripts/3081-108dff6034-lite.chunk.js +2 -0
  38. package/dist/scripts/{3095-d4e716b116-lite.chunk.js → 3095-61899f66b7-lite.chunk.js} +2 -2
  39. package/dist/scripts/3216-090d120af4-lite.chunk.js +1 -0
  40. package/dist/scripts/{3297-51a8e447dc-lite.chunk.js → 3297-aca14193d8-lite.chunk.js} +1 -1
  41. package/dist/scripts/3394-a2d59437da-lite.chunk.js +1 -0
  42. package/dist/scripts/355-d24f480469-lite.chunk.js +1 -0
  43. package/dist/scripts/359-2ac46a3f4f-lite.chunk.js +1 -0
  44. package/dist/scripts/360-7bbaad6cb0-lite.chunk.js +2 -0
  45. package/dist/scripts/3602-7fd870ae27-lite.chunk.js +2 -0
  46. package/dist/scripts/3645-a7755059e6-lite.chunk.js +1 -0
  47. package/dist/scripts/3654-e4ce211ef5-lite.chunk.js +1 -0
  48. package/dist/scripts/3667-ca54928839-lite.chunk.js +2 -0
  49. package/dist/scripts/3715-0264b176fc-lite.chunk.js +1 -0
  50. package/dist/scripts/3728-6dbaab9fa1-lite.chunk.js +1 -0
  51. package/dist/scripts/3836-4e2a1be85d-lite.chunk.js +1 -0
  52. package/dist/scripts/3848-3d23e7ebe9-lite.chunk.js +1 -0
  53. package/dist/scripts/3866-a9d231a938-lite.chunk.js +1 -0
  54. package/dist/scripts/3867-efa4874145-lite.chunk.js +2 -0
  55. package/dist/scripts/3966-c328446613-lite.chunk.js +1 -0
  56. package/dist/scripts/{4032-447a2a4182-lite.chunk.js → 4032-b03e3ab723-lite.chunk.js} +1 -1
  57. package/dist/scripts/4393-f5ca3cd7cc-lite.chunk.js +1 -0
  58. package/dist/scripts/4436-6c821a65e3-lite.chunk.js +1 -0
  59. package/dist/scripts/4456-6abffd33a5-lite.chunk.js +2 -0
  60. package/dist/scripts/4462-aac2062ec2-lite.chunk.js +1 -0
  61. package/dist/scripts/4586-e3af0426d2-lite.chunk.js +1 -0
  62. package/dist/scripts/4612-668b3947be-lite.chunk.js +1 -0
  63. package/dist/scripts/4676-3b968e527e-lite.chunk.js +2 -0
  64. package/dist/scripts/{4753-fa7c39e008-lite.chunk.js → 4753-c8a19a5c5f-lite.chunk.js} +1 -1
  65. package/dist/scripts/{7855-8d35ffa530-lite.chunk.js → 4760-bc90773a67-lite.chunk.js} +1 -1
  66. package/dist/scripts/4778-32af6422aa-lite.chunk.js +2 -0
  67. package/dist/scripts/4942-dddd88b8e9-lite.chunk.js +2 -0
  68. package/dist/scripts/4972-8ea21a8a1f-lite.chunk.js +1 -0
  69. package/dist/scripts/5009-534b4c54e3-lite.chunk.js +2 -0
  70. package/dist/scripts/{5143-4c2085254a-lite.chunk.js → 5143-abe1233e78-lite.chunk.js} +1 -1
  71. package/dist/scripts/5236-786a462dbe-lite.chunk.js +2 -0
  72. package/dist/scripts/5268-d329493d83-lite.chunk.js +2 -0
  73. package/dist/scripts/{537-358a685314-lite.chunk.js → 537-18519f7363-lite.chunk.js} +2 -2
  74. package/dist/scripts/5394-53302d6f25-lite.chunk.js +1 -0
  75. package/dist/scripts/5438-18ecfeb722-lite.chunk.js +1 -0
  76. package/dist/scripts/5512-ea13ed31e4-lite.chunk.js +2 -0
  77. package/dist/scripts/5582-5c01e60af2-lite.chunk.js +1 -0
  78. package/dist/scripts/5595-6f7bc52179-lite.chunk.js +1 -0
  79. package/dist/scripts/5622-70869028ab-lite.chunk.js +2 -0
  80. package/dist/scripts/{578-300ca2819c-lite.chunk.js → 578-e9be3767eb-lite.chunk.js} +1 -1
  81. package/dist/scripts/{5940-d505d42ab9-lite.chunk.js → 5940-100fef351b-lite.chunk.js} +1 -1
  82. package/dist/scripts/5956-bce43279f4-lite.chunk.js +1 -0
  83. package/dist/scripts/5986-15782fabc2-lite.chunk.js +1 -0
  84. package/dist/scripts/6014-83edee02fe-lite.chunk.js +1 -0
  85. package/dist/scripts/6086-119dd59a8c-lite.chunk.js +2 -0
  86. package/dist/scripts/6102-1315ec24d6-lite.chunk.js +2 -0
  87. package/dist/scripts/6117-23040c6d00-lite.chunk.js +1 -0
  88. package/dist/scripts/615-47359245c1-lite.chunk.js +1 -0
  89. package/dist/scripts/{6330-90534c8505-lite.chunk.js → 6330-748f77531b-lite.chunk.js} +1 -1
  90. package/dist/scripts/6368-6e977eeff0-lite.chunk.js +1 -0
  91. package/dist/scripts/6386-b4c1fd02ba-lite.chunk.js +1 -0
  92. package/dist/scripts/6433-a6037155b0-lite.chunk.js +2 -0
  93. package/dist/scripts/6450-5919288c31-lite.chunk.js +1 -0
  94. package/dist/scripts/{6489-9cb2e01be7-lite.chunk.js → 6489-b51bb4141e-lite.chunk.js} +2 -2
  95. package/dist/scripts/6532-990126a37a-lite.chunk.js +1 -0
  96. package/dist/scripts/6617-595d2a4b86-lite.chunk.js +2 -0
  97. package/dist/scripts/6741-f0173071d9-lite.chunk.js +2 -0
  98. package/dist/scripts/6801-74d210c2fa-lite.chunk.js +1 -0
  99. package/dist/scripts/6823-4d9cec7108-lite.chunk.js +2 -0
  100. package/dist/scripts/6896-07e4c9237f-lite.chunk.js +2 -0
  101. package/dist/scripts/691-df63bd9ee9-lite.chunk.js +2 -0
  102. package/dist/scripts/7017-68fd760191-lite.chunk.js +2 -0
  103. package/dist/scripts/7030-7143384a72-lite.chunk.js +2 -0
  104. package/dist/scripts/7052-3c5cf45f6a-lite.chunk.js +2 -0
  105. package/dist/scripts/7112-f242872b3d-lite.chunk.js +2 -0
  106. package/dist/scripts/{3879-701f10ad1b-lite.chunk.js → 7115-a83cf78a1b-lite.chunk.js} +1 -1
  107. package/dist/scripts/7117-59efcfef9b-lite.chunk.js +1 -0
  108. package/dist/scripts/7178-6230dff01f-lite.chunk.js +1 -0
  109. package/dist/scripts/{7205-0a33c1ff11-lite.chunk.js → 7205-05c2b05546-lite.chunk.js} +1 -1
  110. package/dist/scripts/7221-f88ee657b5-lite.chunk.js +2 -0
  111. package/dist/scripts/7288-1890d3d440-lite.chunk.js +1 -0
  112. package/dist/scripts/7351-14343c2f59-lite.chunk.js +1 -0
  113. package/dist/scripts/7385-376b941022-lite.chunk.js +2 -0
  114. package/dist/scripts/7402-e7acca8272-lite.chunk.js +2 -0
  115. package/dist/scripts/7432-2990590ca2-lite.chunk.js +1 -0
  116. package/dist/scripts/7506-728c338ce6-lite.chunk.js +1 -0
  117. package/dist/scripts/7511-d8481f06a7-lite.chunk.js +1 -0
  118. package/dist/scripts/{7540-207b54607d-lite.chunk.js → 7540-95cacaaf40-lite.chunk.js} +1 -1
  119. package/dist/scripts/{7555-5650392ae9-lite.chunk.js → 7555-181e877fce-lite.chunk.js} +1 -1
  120. package/dist/scripts/7670-bdff6c66e4-lite.chunk.js +2 -0
  121. package/dist/scripts/771-08f49f1b2b-lite.chunk.js +2 -0
  122. package/dist/scripts/7726-8428e7a16f-lite.chunk.js +1 -0
  123. package/dist/scripts/7855-c0e83040b7-lite.chunk.js +1 -0
  124. package/dist/scripts/7902-379a79adec-lite.chunk.js +2 -0
  125. package/dist/scripts/7934-ddfee57a55-lite.chunk.js +1 -0
  126. package/dist/scripts/8046-868da71a4d-lite.chunk.js +1 -0
  127. package/dist/scripts/8199-2bf086d802-lite.chunk.js +2 -0
  128. package/dist/scripts/{8323-83055d0a29-lite.chunk.js → 8323-68d1dad8bf-lite.chunk.js} +2 -2
  129. package/dist/scripts/{841-90d4aae429-lite.chunk.js → 841-b8378f2cee-lite.chunk.js} +2 -2
  130. package/dist/scripts/8581-ae4989b5ca-lite.chunk.js +1 -0
  131. package/dist/scripts/8681-44c94eded8-lite.chunk.js +2 -0
  132. package/dist/scripts/8759-38a1df6fa0-lite.chunk.js +1 -0
  133. package/dist/scripts/8935-eb635219f2-lite.chunk.js +2 -0
  134. package/dist/scripts/{9016-83362009ad-lite.chunk.js → 9016-4160740b82-lite.chunk.js} +1 -1
  135. package/dist/scripts/9173-571e4db9d3-lite.chunk.js +2 -0
  136. package/dist/scripts/9226-123bec9bf7-lite.chunk.js +1 -0
  137. package/dist/scripts/9230-20713898e5-lite.chunk.js +2 -0
  138. package/dist/scripts/9242-253c1fa28f-lite.chunk.js +1 -0
  139. package/dist/scripts/9371-31e855a07c-lite.chunk.js +2 -0
  140. package/dist/scripts/9428-1dcd12662a-lite.chunk.js +2 -0
  141. package/dist/scripts/9433-8465b40be6-lite.chunk.js +1 -0
  142. package/dist/scripts/9478-e3fe60ea47-lite.chunk.js +2 -0
  143. package/dist/scripts/9484-3e1eb0a7fb-lite.chunk.js +2 -0
  144. package/dist/scripts/9557-f647cfdb4c-lite.chunk.js +1 -0
  145. package/dist/scripts/9674-349baf5c58-lite.chunk.js +1 -0
  146. package/dist/scripts/{9719-adf7d8da55-lite.chunk.js → 9719-d2875a0969-lite.chunk.js} +2 -2
  147. package/dist/scripts/9894-04b7d1bf02-lite.chunk.js +2 -0
  148. package/dist/scripts/9918-dab2efae14-lite.chunk.js +2 -0
  149. package/dist/scripts/9931-d0df42247b-lite.chunk.js +2 -0
  150. package/dist/scripts/bundle-2c20d40f45.min.js +2 -0
  151. package/dist/scripts/polyfills-7bd16772e3.min.js +2 -0
  152. package/package.json +1 -1
  153. package/dist/css/1818-lite-85c08e0392.chunk.css +0 -3
  154. package/dist/css/5595-lite-888c19c68f.chunk.css +0 -7
  155. package/dist/scripts/121-479934c2c9-lite.chunk.js +0 -1
  156. package/dist/scripts/1276-3649cb6030-lite.chunk.js +0 -2
  157. package/dist/scripts/1466-1e609d0f2d-lite.chunk.js +0 -2
  158. package/dist/scripts/1518-16e55504cf-lite.chunk.js +0 -1
  159. package/dist/scripts/1605-225aa98ca6-lite.chunk.js +0 -1
  160. package/dist/scripts/1617-131576ed64-lite.chunk.js +0 -1
  161. package/dist/scripts/1818-7f85a781b4-lite.chunk.js +0 -1
  162. package/dist/scripts/1853-bab9a1eac4-lite.chunk.js +0 -1
  163. package/dist/scripts/2118-64b1ed0e87-lite.chunk.js +0 -2
  164. package/dist/scripts/2235-c26089dac6-lite.chunk.js +0 -1
  165. package/dist/scripts/2258-7c6d560f89-lite.chunk.js +0 -1
  166. package/dist/scripts/2261-4cd12ea734-lite.chunk.js +0 -1
  167. package/dist/scripts/2405-6d73e6034c-lite.chunk.js +0 -1
  168. package/dist/scripts/2857-b41a4bf624-lite.chunk.js +0 -1
  169. package/dist/scripts/287-e44c53bdc8-lite.chunk.js +0 -1
  170. package/dist/scripts/3067-f77631f0ba-lite.chunk.js +0 -1
  171. package/dist/scripts/3081-b55baaca7c-lite.chunk.js +0 -2
  172. package/dist/scripts/3170-b0396283ae-lite.chunk.js +0 -1
  173. package/dist/scripts/3216-97d52c0dd9-lite.chunk.js +0 -1
  174. package/dist/scripts/3514-fb291c0ee8-lite.chunk.js +0 -1
  175. package/dist/scripts/355-177625b4b7-lite.chunk.js +0 -1
  176. package/dist/scripts/3602-aadff36e30-lite.chunk.js +0 -2
  177. package/dist/scripts/3645-9d39bfad5b-lite.chunk.js +0 -2
  178. package/dist/scripts/3654-758c9e46e0-lite.chunk.js +0 -1
  179. package/dist/scripts/3667-972fbd5c5e-lite.chunk.js +0 -2
  180. package/dist/scripts/3715-885e00afcd-lite.chunk.js +0 -1
  181. package/dist/scripts/3728-c8c5291f62-lite.chunk.js +0 -1
  182. package/dist/scripts/3836-2c2f020103-lite.chunk.js +0 -1
  183. package/dist/scripts/3848-4eb815382b-lite.chunk.js +0 -1
  184. package/dist/scripts/3866-fc3290edd2-lite.chunk.js +0 -1
  185. package/dist/scripts/3867-9db0d2d72d-lite.chunk.js +0 -2
  186. package/dist/scripts/3966-f660e0a1fe-lite.chunk.js +0 -1
  187. package/dist/scripts/4393-48db651ab8-lite.chunk.js +0 -1
  188. package/dist/scripts/4436-7682d831f0-lite.chunk.js +0 -1
  189. package/dist/scripts/4448-d71d3c0598-lite.chunk.js +0 -1
  190. package/dist/scripts/4456-cfb9053629-lite.chunk.js +0 -2
  191. package/dist/scripts/4612-f6ba941518-lite.chunk.js +0 -1
  192. package/dist/scripts/4676-beb0d246a2-lite.chunk.js +0 -2
  193. package/dist/scripts/4778-9e056d0b13-lite.chunk.js +0 -2
  194. package/dist/scripts/4942-a645ec7a44-lite.chunk.js +0 -2
  195. package/dist/scripts/5009-a97da70c86-lite.chunk.js +0 -2
  196. package/dist/scripts/5236-2fffc01b66-lite.chunk.js +0 -2
  197. package/dist/scripts/5268-cd5f7a8b2b-lite.chunk.js +0 -2
  198. package/dist/scripts/5373-efa36674f8-lite.chunk.js +0 -1
  199. package/dist/scripts/5438-c59019bb11-lite.chunk.js +0 -1
  200. package/dist/scripts/5512-b6c3e65166-lite.chunk.js +0 -2
  201. package/dist/scripts/5582-776496057e-lite.chunk.js +0 -1
  202. package/dist/scripts/5595-c259bda4d0-lite.chunk.js +0 -1
  203. package/dist/scripts/5622-c5395232d1-lite.chunk.js +0 -2
  204. package/dist/scripts/5956-275f2cf0e4-lite.chunk.js +0 -1
  205. package/dist/scripts/5986-9bf3673f84-lite.chunk.js +0 -1
  206. package/dist/scripts/6014-c913e29f36-lite.chunk.js +0 -1
  207. package/dist/scripts/6086-6e1cd58ace-lite.chunk.js +0 -2
  208. package/dist/scripts/6102-2cad0d587a-lite.chunk.js +0 -2
  209. package/dist/scripts/615-92aa23faec-lite.chunk.js +0 -1
  210. package/dist/scripts/6368-c8e0371438-lite.chunk.js +0 -1
  211. package/dist/scripts/6433-0085aedf6b-lite.chunk.js +0 -2
  212. package/dist/scripts/6450-3d69f27d4a-lite.chunk.js +0 -1
  213. package/dist/scripts/6532-998af9d801-lite.chunk.js +0 -1
  214. package/dist/scripts/6617-7d7eb77bf1-lite.chunk.js +0 -2
  215. package/dist/scripts/6741-972d588c2d-lite.chunk.js +0 -2
  216. package/dist/scripts/6801-df7e6e8190-lite.chunk.js +0 -1
  217. package/dist/scripts/6823-0c0e463dc4-lite.chunk.js +0 -2
  218. package/dist/scripts/6896-a3d38ae7a4-lite.chunk.js +0 -2
  219. package/dist/scripts/691-c807735104-lite.chunk.js +0 -2
  220. package/dist/scripts/7017-1c686d77cb-lite.chunk.js +0 -2
  221. package/dist/scripts/7030-c786d4e8ec-lite.chunk.js +0 -2
  222. package/dist/scripts/7052-07571de19d-lite.chunk.js +0 -2
  223. package/dist/scripts/7112-fcfcfa7702-lite.chunk.js +0 -2
  224. package/dist/scripts/7115-cb79ea0c44-lite.chunk.js +0 -1
  225. package/dist/scripts/7117-91ae366d34-lite.chunk.js +0 -1
  226. package/dist/scripts/7178-deef1f18e6-lite.chunk.js +0 -1
  227. package/dist/scripts/7221-fc696d1984-lite.chunk.js +0 -2
  228. package/dist/scripts/7288-209544a83d-lite.chunk.js +0 -1
  229. package/dist/scripts/7351-5b1db26880-lite.chunk.js +0 -1
  230. package/dist/scripts/7381-2f30be20cc-lite.chunk.js +0 -1
  231. package/dist/scripts/7385-e1c0059aeb-lite.chunk.js +0 -2
  232. package/dist/scripts/7402-f5a2f601a4-lite.chunk.js +0 -2
  233. package/dist/scripts/7432-4b02802c11-lite.chunk.js +0 -1
  234. package/dist/scripts/7506-799a5aa8ba-lite.chunk.js +0 -1
  235. package/dist/scripts/7670-4ace052002-lite.chunk.js +0 -2
  236. package/dist/scripts/771-e03ca5243c-lite.chunk.js +0 -2
  237. package/dist/scripts/7726-94751e2a44-lite.chunk.js +0 -1
  238. package/dist/scripts/7902-fafd6851c3-lite.chunk.js +0 -2
  239. package/dist/scripts/7934-3f1383317c-lite.chunk.js +0 -1
  240. package/dist/scripts/8046-0eccefca74-lite.chunk.js +0 -1
  241. package/dist/scripts/8091-d5846a813d-lite.chunk.js +0 -1
  242. package/dist/scripts/8142-02e0759222-lite.chunk.js +0 -1
  243. package/dist/scripts/8199-a027a8a9a2-lite.chunk.js +0 -2
  244. package/dist/scripts/8581-a488d44d50-lite.chunk.js +0 -1
  245. package/dist/scripts/8681-0ab6b8b524-lite.chunk.js +0 -2
  246. package/dist/scripts/8759-e1bd74ab1c-lite.chunk.js +0 -1
  247. package/dist/scripts/8935-9cf0afbfd0-lite.chunk.js +0 -2
  248. package/dist/scripts/9173-220e638991-lite.chunk.js +0 -2
  249. package/dist/scripts/9226-21532c1a5d-lite.chunk.js +0 -1
  250. package/dist/scripts/9230-e242e60c85-lite.chunk.js +0 -2
  251. package/dist/scripts/9242-6064f14b8c-lite.chunk.js +0 -1
  252. package/dist/scripts/9254-84dcaf09b8-lite.chunk.js +0 -1
  253. package/dist/scripts/9371-b177ac9805-lite.chunk.js +0 -2
  254. package/dist/scripts/9428-8f8662cadc-lite.chunk.js +0 -2
  255. package/dist/scripts/9433-449feee3f7-lite.chunk.js +0 -1
  256. package/dist/scripts/9478-a8bf32cd2f-lite.chunk.js +0 -2
  257. package/dist/scripts/9484-59dae0b6e9-lite.chunk.js +0 -2
  258. package/dist/scripts/9537-346479566b-lite.chunk.js +0 -1
  259. package/dist/scripts/9674-b79b2faa3e-lite.chunk.js +0 -1
  260. package/dist/scripts/9708-6842c8c42e-lite.chunk.js +0 -1
  261. package/dist/scripts/9894-bac8528a7b-lite.chunk.js +0 -2
  262. package/dist/scripts/9918-cd8913f609-lite.chunk.js +0 -2
  263. package/dist/scripts/9931-abf79a99fb-lite.chunk.js +0 -2
  264. package/dist/scripts/bundle-c274042dd7.min.js +0 -2
  265. package/dist/scripts/polyfills-94a5047ebb.min.js +0 -2
  266. /package/dist/css/{9537-lite-6554428c5a.chunk.css → 209-lite-6554428c5a.chunk.css} +0 -0
  267. /package/dist/css/{5373-lite-6bc5010289.chunk.css → 3394-lite-6bc5010289.chunk.css} +0 -0
  268. /package/dist/css/{8091-lite-6f4357643d.chunk.css → 359-lite-6f4357643d.chunk.css} +0 -0
  269. /package/dist/css/{3645-lite-f1f1b748f7.chunk.css → 360-lite-f1f1b748f7.chunk.css} +0 -0
  270. /package/dist/css/{2258-lite-63013c63e9.chunk.css → 3645-lite-63013c63e9.chunk.css} +0 -0
  271. /package/dist/css/{1853-lite-57405d5422.chunk.css → 4586-lite-57405d5422.chunk.css} +0 -0
  272. /package/dist/css/{8142-lite-cec3e3ceee.chunk.css → 5394-lite-cec3e3ceee.chunk.css} +0 -0
  273. /package/dist/css/{2405-lite-9d203955c3.chunk.css → 6117-lite-9d203955c3.chunk.css} +0 -0
  274. /package/dist/scripts/{1106-74579075bb-lite.chunk.js → 1106-4ff63db7bd-lite.chunk.js} +0 -0
  275. /package/dist/scripts/{1204-77ff9b338e-lite.chunk.js → 1204-de13857bda-lite.chunk.js} +0 -0
  276. /package/dist/scripts/{1276-3649cb6030-lite.chunk.js.LICENSE.txt → 1276-c906943bd2-lite.chunk.js.LICENSE.txt} +0 -0
  277. /package/dist/scripts/{1285-e490441e6f-lite.chunk.js → 1285-1d4ab3a381-lite.chunk.js} +0 -0
  278. /package/dist/scripts/{1291-823e22d75c-lite.chunk.js → 1291-fc7adcdd5d-lite.chunk.js} +0 -0
  279. /package/dist/scripts/{140-4e826c6220-lite.chunk.js → 140-24539af746-lite.chunk.js} +0 -0
  280. /package/dist/scripts/{1466-1e609d0f2d-lite.chunk.js.LICENSE.txt → 1466-8c87c52bac-lite.chunk.js.LICENSE.txt} +0 -0
  281. /package/dist/scripts/{1544-bb997fec9d-lite.chunk.js → 1544-cdc531a16c-lite.chunk.js} +0 -0
  282. /package/dist/scripts/{1628-5f159e5623-lite.chunk.js → 1628-1fedd3c59d-lite.chunk.js} +0 -0
  283. /package/dist/scripts/{1672-cef1d67820-lite.chunk.js.LICENSE.txt → 1672-b02899f572-lite.chunk.js.LICENSE.txt} +0 -0
  284. /package/dist/scripts/{1725-b6c4f32c58-lite.chunk.js → 1725-676872d630-lite.chunk.js} +0 -0
  285. /package/dist/scripts/{1726-83ecf2e706-lite.chunk.js → 1726-8735f2cb04-lite.chunk.js} +0 -0
  286. /package/dist/scripts/{1750-1f8d21137d-lite.chunk.js → 1750-c288c192e5-lite.chunk.js} +0 -0
  287. /package/dist/scripts/{1798-96ef56e102-lite.chunk.js → 1798-7a61b3b3b4-lite.chunk.js} +0 -0
  288. /package/dist/scripts/{1799-36f9674130-lite.chunk.js → 1799-f64887c19e-lite.chunk.js} +0 -0
  289. /package/dist/scripts/{1863-78cfe4c840-lite.chunk.js → 1863-6f064e7049-lite.chunk.js} +0 -0
  290. /package/dist/scripts/{1891-5dcf62aecb-lite.chunk.js → 1891-0ce8049db4-lite.chunk.js} +0 -0
  291. /package/dist/scripts/{1895-d44e4310b0-lite.chunk.js.LICENSE.txt → 1895-e0ba3e67e2-lite.chunk.js.LICENSE.txt} +0 -0
  292. /package/dist/scripts/{2118-64b1ed0e87-lite.chunk.js.LICENSE.txt → 2118-a1967105c4-lite.chunk.js.LICENSE.txt} +0 -0
  293. /package/dist/scripts/{2137-d3ec723c07-lite.chunk.js → 2137-d2f172bbef-lite.chunk.js} +0 -0
  294. /package/dist/scripts/{2199-3bcf471e59-lite.chunk.js → 2199-8344764e62-lite.chunk.js} +0 -0
  295. /package/dist/scripts/{2229-c201253f9d-lite.chunk.js → 2229-53e852a6f3-lite.chunk.js} +0 -0
  296. /package/dist/scripts/{227-8deec4e8fb-lite.chunk.js → 227-df9c201a60-lite.chunk.js} +0 -0
  297. /package/dist/scripts/{2279-938506fb85-lite.chunk.js → 2279-345b62f556-lite.chunk.js} +0 -0
  298. /package/dist/scripts/{2318-e4529b7326-lite.chunk.js → 2318-36b9e5053c-lite.chunk.js} +0 -0
  299. /package/dist/scripts/{2561-ade199ee1e-lite.chunk.js → 2561-bf66d5f92e-lite.chunk.js} +0 -0
  300. /package/dist/scripts/{2665-e80f0a5c30-lite.chunk.js → 2665-f227326ae7-lite.chunk.js} +0 -0
  301. /package/dist/scripts/{2925-da3f2e9429-lite.chunk.js → 2925-3e6f144c5a-lite.chunk.js} +0 -0
  302. /package/dist/scripts/{298-4ec4d2fad7-lite.chunk.js → 298-9f5084a7fd-lite.chunk.js} +0 -0
  303. /package/dist/scripts/{3012-d34fee3745-lite.chunk.js → 3012-5027248e92-lite.chunk.js} +0 -0
  304. /package/dist/scripts/{3042-45f3cc0a02-lite.chunk.js → 3042-9f011c57d3-lite.chunk.js} +0 -0
  305. /package/dist/scripts/{3079-79e389b573-lite.chunk.js → 3079-5d8bd339fe-lite.chunk.js} +0 -0
  306. /package/dist/scripts/{3081-b55baaca7c-lite.chunk.js.LICENSE.txt → 3081-108dff6034-lite.chunk.js.LICENSE.txt} +0 -0
  307. /package/dist/scripts/{3095-d4e716b116-lite.chunk.js.LICENSE.txt → 3095-61899f66b7-lite.chunk.js.LICENSE.txt} +0 -0
  308. /package/dist/scripts/{3108-15ec707fa7-lite.chunk.js → 3108-0ca7ccf906-lite.chunk.js} +0 -0
  309. /package/dist/scripts/{3171-81d2900564-lite.chunk.js → 3171-a923ee5f8e-lite.chunk.js} +0 -0
  310. /package/dist/scripts/{3468-1262bc39ae-lite.chunk.js → 3468-81414e15e8-lite.chunk.js} +0 -0
  311. /package/dist/scripts/{3545-518ee52548-lite.chunk.js → 3545-5674a49eb7-lite.chunk.js} +0 -0
  312. /package/dist/scripts/{3602-aadff36e30-lite.chunk.js.LICENSE.txt → 360-7bbaad6cb0-lite.chunk.js.LICENSE.txt} +0 -0
  313. /package/dist/scripts/{3645-9d39bfad5b-lite.chunk.js.LICENSE.txt → 3602-7fd870ae27-lite.chunk.js.LICENSE.txt} +0 -0
  314. /package/dist/scripts/{3667-972fbd5c5e-lite.chunk.js.LICENSE.txt → 3667-ca54928839-lite.chunk.js.LICENSE.txt} +0 -0
  315. /package/dist/scripts/{3867-9db0d2d72d-lite.chunk.js.LICENSE.txt → 3867-efa4874145-lite.chunk.js.LICENSE.txt} +0 -0
  316. /package/dist/scripts/{389-7cd9797e99-lite.chunk.js → 389-2e6bcc3ee9-lite.chunk.js} +0 -0
  317. /package/dist/scripts/{3973-2a7342fd32-lite.chunk.js → 3973-3354aca0ad-lite.chunk.js} +0 -0
  318. /package/dist/scripts/{4182-031df6501a-lite.chunk.js → 4182-c1b7d78410-lite.chunk.js} +0 -0
  319. /package/dist/scripts/{4343-5be11a3650-lite.chunk.js → 4343-aca8b5c502-lite.chunk.js} +0 -0
  320. /package/dist/scripts/{4433-684da4ef45-lite.chunk.js → 4433-4193d27eb3-lite.chunk.js} +0 -0
  321. /package/dist/scripts/{4456-cfb9053629-lite.chunk.js.LICENSE.txt → 4456-6abffd33a5-lite.chunk.js.LICENSE.txt} +0 -0
  322. /package/dist/scripts/{4541-bc86a7626f-lite.chunk.js → 4541-b750910fb7-lite.chunk.js} +0 -0
  323. /package/dist/scripts/{4554-db382a141e-lite.chunk.js → 4554-1e7ebd6940-lite.chunk.js} +0 -0
  324. /package/dist/scripts/{4632-e42ff5baa2-lite.chunk.js → 4632-13020688a6-lite.chunk.js} +0 -0
  325. /package/dist/scripts/{4676-beb0d246a2-lite.chunk.js.LICENSE.txt → 4676-3b968e527e-lite.chunk.js.LICENSE.txt} +0 -0
  326. /package/dist/scripts/{4778-9e056d0b13-lite.chunk.js.LICENSE.txt → 4778-32af6422aa-lite.chunk.js.LICENSE.txt} +0 -0
  327. /package/dist/scripts/{482-aca85764e8-lite.chunk.js → 482-5fef71ddd5-lite.chunk.js} +0 -0
  328. /package/dist/scripts/{4858-b0238d4405-lite.chunk.js → 4858-85e14c4d51-lite.chunk.js} +0 -0
  329. /package/dist/scripts/{4893-323ae9a9c0-lite.chunk.js → 4893-43a90e8aeb-lite.chunk.js} +0 -0
  330. /package/dist/scripts/{4942-a645ec7a44-lite.chunk.js.LICENSE.txt → 4942-dddd88b8e9-lite.chunk.js.LICENSE.txt} +0 -0
  331. /package/dist/scripts/{5009-a97da70c86-lite.chunk.js.LICENSE.txt → 5009-534b4c54e3-lite.chunk.js.LICENSE.txt} +0 -0
  332. /package/dist/scripts/{5229-504bcc7747-lite.chunk.js → 5229-f3847ae602-lite.chunk.js} +0 -0
  333. /package/dist/scripts/{5236-2fffc01b66-lite.chunk.js.LICENSE.txt → 5236-786a462dbe-lite.chunk.js.LICENSE.txt} +0 -0
  334. /package/dist/scripts/{5268-cd5f7a8b2b-lite.chunk.js.LICENSE.txt → 5268-d329493d83-lite.chunk.js.LICENSE.txt} +0 -0
  335. /package/dist/scripts/{537-358a685314-lite.chunk.js.LICENSE.txt → 537-18519f7363-lite.chunk.js.LICENSE.txt} +0 -0
  336. /package/dist/scripts/{5385-f7e8700643-lite.chunk.js → 5385-adff8a1e15-lite.chunk.js} +0 -0
  337. /package/dist/scripts/{5446-243e51a26b-lite.chunk.js → 5446-f8ecdf1c2c-lite.chunk.js} +0 -0
  338. /package/dist/scripts/{5512-b6c3e65166-lite.chunk.js.LICENSE.txt → 5512-ea13ed31e4-lite.chunk.js.LICENSE.txt} +0 -0
  339. /package/dist/scripts/{5591-1542062e4c-lite.chunk.js → 5591-e3b6537ae4-lite.chunk.js} +0 -0
  340. /package/dist/scripts/{5606-5cccdb0326-lite.chunk.js → 5606-2a178ab4b4-lite.chunk.js} +0 -0
  341. /package/dist/scripts/{5622-c5395232d1-lite.chunk.js.LICENSE.txt → 5622-70869028ab-lite.chunk.js.LICENSE.txt} +0 -0
  342. /package/dist/scripts/{5870-fb27d82c66-lite.chunk.js → 5870-4921055fb3-lite.chunk.js} +0 -0
  343. /package/dist/scripts/{5877-79b358f14d-lite.chunk.js → 5877-dd62da67de-lite.chunk.js} +0 -0
  344. /package/dist/scripts/{5914-3819d300bf-lite.chunk.js → 5914-4d35afebcd-lite.chunk.js} +0 -0
  345. /package/dist/scripts/{5974-ad9644fec8-lite.chunk.js → 5974-5d0e9b5394-lite.chunk.js} +0 -0
  346. /package/dist/scripts/{6086-6e1cd58ace-lite.chunk.js.LICENSE.txt → 6086-119dd59a8c-lite.chunk.js.LICENSE.txt} +0 -0
  347. /package/dist/scripts/{6102-2cad0d587a-lite.chunk.js.LICENSE.txt → 6102-1315ec24d6-lite.chunk.js.LICENSE.txt} +0 -0
  348. /package/dist/scripts/{6158-2284b2b4a5-lite.chunk.js → 6158-e1745c2e69-lite.chunk.js} +0 -0
  349. /package/dist/scripts/{6274-565d64f00b-lite.chunk.js → 6274-a61f2fdeb8-lite.chunk.js} +0 -0
  350. /package/dist/scripts/{6290-579768d51c-lite.chunk.js → 6290-c34fa51eaf-lite.chunk.js} +0 -0
  351. /package/dist/scripts/{6370-4b53f3675e-lite.chunk.js → 6370-b1061ea20b-lite.chunk.js} +0 -0
  352. /package/dist/scripts/{6433-0085aedf6b-lite.chunk.js.LICENSE.txt → 6433-a6037155b0-lite.chunk.js.LICENSE.txt} +0 -0
  353. /package/dist/scripts/{6465-222d004761-lite.chunk.js → 6465-29bdb9761b-lite.chunk.js} +0 -0
  354. /package/dist/scripts/{6480-c1da9df604-lite.chunk.js → 6480-6de1b9fae4-lite.chunk.js} +0 -0
  355. /package/dist/scripts/{6489-9cb2e01be7-lite.chunk.js.LICENSE.txt → 6489-b51bb4141e-lite.chunk.js.LICENSE.txt} +0 -0
  356. /package/dist/scripts/{6493-fcc6595135-lite.chunk.js → 6493-254f2af0a3-lite.chunk.js} +0 -0
  357. /package/dist/scripts/{6604-fbd31a499b-lite.chunk.js → 6604-8fe05cd999-lite.chunk.js} +0 -0
  358. /package/dist/scripts/{6617-7d7eb77bf1-lite.chunk.js.LICENSE.txt → 6617-595d2a4b86-lite.chunk.js.LICENSE.txt} +0 -0
  359. /package/dist/scripts/{6689-41f2babb73-lite.chunk.js → 6689-57f59b3af4-lite.chunk.js} +0 -0
  360. /package/dist/scripts/{6741-972d588c2d-lite.chunk.js.LICENSE.txt → 6741-f0173071d9-lite.chunk.js.LICENSE.txt} +0 -0
  361. /package/dist/scripts/{6746-c58f10f6b1-lite.chunk.js → 6746-3c13fdeac5-lite.chunk.js} +0 -0
  362. /package/dist/scripts/{6817-ba51beb1a3-lite.chunk.js → 6817-607900c063-lite.chunk.js} +0 -0
  363. /package/dist/scripts/{6823-0c0e463dc4-lite.chunk.js.LICENSE.txt → 6823-4d9cec7108-lite.chunk.js.LICENSE.txt} +0 -0
  364. /package/dist/scripts/{6863-776600ada0-lite.chunk.js → 6863-861900cf40-lite.chunk.js} +0 -0
  365. /package/dist/scripts/{6873-01ab6146b0-lite.chunk.js → 6873-153b517330-lite.chunk.js} +0 -0
  366. /package/dist/scripts/{6896-a3d38ae7a4-lite.chunk.js.LICENSE.txt → 6896-07e4c9237f-lite.chunk.js.LICENSE.txt} +0 -0
  367. /package/dist/scripts/{691-c807735104-lite.chunk.js.LICENSE.txt → 691-df63bd9ee9-lite.chunk.js.LICENSE.txt} +0 -0
  368. /package/dist/scripts/{6930-a5abb7afe3-lite.chunk.js → 6930-edb18843bc-lite.chunk.js} +0 -0
  369. /package/dist/scripts/{6954-1310ddaf71-lite.chunk.js → 6954-4dc9cc5c09-lite.chunk.js} +0 -0
  370. /package/dist/scripts/{7017-1c686d77cb-lite.chunk.js.LICENSE.txt → 7017-68fd760191-lite.chunk.js.LICENSE.txt} +0 -0
  371. /package/dist/scripts/{7030-c786d4e8ec-lite.chunk.js.LICENSE.txt → 7030-7143384a72-lite.chunk.js.LICENSE.txt} +0 -0
  372. /package/dist/scripts/{7045-bb2ff919d3-lite.chunk.js → 7045-66499093d9-lite.chunk.js} +0 -0
  373. /package/dist/scripts/{7052-07571de19d-lite.chunk.js.LICENSE.txt → 7052-3c5cf45f6a-lite.chunk.js.LICENSE.txt} +0 -0
  374. /package/dist/scripts/{7112-fcfcfa7702-lite.chunk.js.LICENSE.txt → 7112-f242872b3d-lite.chunk.js.LICENSE.txt} +0 -0
  375. /package/dist/scripts/{7128-0fb3d40e9f-lite.chunk.js → 7128-a5539e9d1e-lite.chunk.js} +0 -0
  376. /package/dist/scripts/{714-fd0f681746-lite.chunk.js → 714-71a88e7bf4-lite.chunk.js} +0 -0
  377. /package/dist/scripts/{7167-c06f8a9da0-lite.chunk.js → 7167-acf0110c55-lite.chunk.js} +0 -0
  378. /package/dist/scripts/{7172-a74288ef51-lite.chunk.js → 7172-6d5c35d2bc-lite.chunk.js} +0 -0
  379. /package/dist/scripts/{7221-fc696d1984-lite.chunk.js.LICENSE.txt → 7221-f88ee657b5-lite.chunk.js.LICENSE.txt} +0 -0
  380. /package/dist/scripts/{7293-61cdb1f653-lite.chunk.js → 7293-a30f9a96bd-lite.chunk.js} +0 -0
  381. /package/dist/scripts/{7338-a9d72104b9-lite.chunk.js → 7338-5f6e7f9a2d-lite.chunk.js} +0 -0
  382. /package/dist/scripts/{7385-e1c0059aeb-lite.chunk.js.LICENSE.txt → 7385-376b941022-lite.chunk.js.LICENSE.txt} +0 -0
  383. /package/dist/scripts/{7402-f5a2f601a4-lite.chunk.js.LICENSE.txt → 7402-e7acca8272-lite.chunk.js.LICENSE.txt} +0 -0
  384. /package/dist/scripts/{766-60efa0f621-lite.chunk.js → 766-52bb6c37e5-lite.chunk.js} +0 -0
  385. /package/dist/scripts/{7670-4ace052002-lite.chunk.js.LICENSE.txt → 7670-bdff6c66e4-lite.chunk.js.LICENSE.txt} +0 -0
  386. /package/dist/scripts/{7706-f388445215-lite.chunk.js → 7706-cd525c7ab7-lite.chunk.js} +0 -0
  387. /package/dist/scripts/{7708-ef1267a3d9-lite.chunk.js → 7708-ccc85f9902-lite.chunk.js} +0 -0
  388. /package/dist/scripts/{771-e03ca5243c-lite.chunk.js.LICENSE.txt → 771-08f49f1b2b-lite.chunk.js.LICENSE.txt} +0 -0
  389. /package/dist/scripts/{7715-486cb2c98a-lite.chunk.js → 7715-6b46ec3296-lite.chunk.js} +0 -0
  390. /package/dist/scripts/{7734-c7865a5a1b-lite.chunk.js → 7734-10619ef5fd-lite.chunk.js} +0 -0
  391. /package/dist/scripts/{7818-90809174d8-lite.chunk.js → 7818-88d3db167c-lite.chunk.js} +0 -0
  392. /package/dist/scripts/{7902-fafd6851c3-lite.chunk.js.LICENSE.txt → 7902-379a79adec-lite.chunk.js.LICENSE.txt} +0 -0
  393. /package/dist/scripts/{7925-fbb2b17515-lite.chunk.js → 7925-467145a79b-lite.chunk.js} +0 -0
  394. /package/dist/scripts/{8025-96f1616dba-lite.chunk.js → 8025-6e3dbe1d1c-lite.chunk.js} +0 -0
  395. /package/dist/scripts/{8199-a027a8a9a2-lite.chunk.js.LICENSE.txt → 8199-2bf086d802-lite.chunk.js.LICENSE.txt} +0 -0
  396. /package/dist/scripts/{823-6b52a0fcb4-lite.chunk.js → 823-953f2c38a1-lite.chunk.js} +0 -0
  397. /package/dist/scripts/{8252-fcf29e698d-lite.chunk.js → 8252-88abf202db-lite.chunk.js} +0 -0
  398. /package/dist/scripts/{8323-83055d0a29-lite.chunk.js.LICENSE.txt → 8323-68d1dad8bf-lite.chunk.js.LICENSE.txt} +0 -0
  399. /package/dist/scripts/{8383-032604a407-lite.chunk.js → 8383-b471aca257-lite.chunk.js} +0 -0
  400. /package/dist/scripts/{841-90d4aae429-lite.chunk.js.LICENSE.txt → 841-b8378f2cee-lite.chunk.js.LICENSE.txt} +0 -0
  401. /package/dist/scripts/{8419-385d9ac486-lite.chunk.js → 8419-c8c743c676-lite.chunk.js} +0 -0
  402. /package/dist/scripts/{8466-43c04636f8-lite.chunk.js → 8466-c3b75c2f7d-lite.chunk.js} +0 -0
  403. /package/dist/scripts/{8591-64b682611e-lite.chunk.js → 8591-ed3a2e9e63-lite.chunk.js} +0 -0
  404. /package/dist/scripts/{8681-0ab6b8b524-lite.chunk.js.LICENSE.txt → 8681-44c94eded8-lite.chunk.js.LICENSE.txt} +0 -0
  405. /package/dist/scripts/{872-ee2de611ec-lite.chunk.js → 872-0a5929a4a9-lite.chunk.js} +0 -0
  406. /package/dist/scripts/{8830-30cd7cd68f-lite.chunk.js → 8830-71040cddfd-lite.chunk.js} +0 -0
  407. /package/dist/scripts/{8935-9cf0afbfd0-lite.chunk.js.LICENSE.txt → 8935-eb635219f2-lite.chunk.js.LICENSE.txt} +0 -0
  408. /package/dist/scripts/{8955-7a54437ac2-lite.chunk.js → 8955-1209da3e61-lite.chunk.js} +0 -0
  409. /package/dist/scripts/{8982-a09f97ed86-lite.chunk.js → 8982-21d06b9897-lite.chunk.js} +0 -0
  410. /package/dist/scripts/{9005-aa68735567-lite.chunk.js → 9005-4115806fb6-lite.chunk.js} +0 -0
  411. /package/dist/scripts/{9016-83362009ad-lite.chunk.js.LICENSE.txt → 9016-4160740b82-lite.chunk.js.LICENSE.txt} +0 -0
  412. /package/dist/scripts/{9038-25cce8bb4c-lite.chunk.js → 9038-18687af2ef-lite.chunk.js} +0 -0
  413. /package/dist/scripts/{9060-c1ca702772-lite.chunk.js → 9060-130c9abc2f-lite.chunk.js} +0 -0
  414. /package/dist/scripts/{9151-2fbfab2e35-lite.chunk.js → 9151-18d3b8560b-lite.chunk.js} +0 -0
  415. /package/dist/scripts/{9173-220e638991-lite.chunk.js.LICENSE.txt → 9173-571e4db9d3-lite.chunk.js.LICENSE.txt} +0 -0
  416. /package/dist/scripts/{9230-e242e60c85-lite.chunk.js.LICENSE.txt → 9230-20713898e5-lite.chunk.js.LICENSE.txt} +0 -0
  417. /package/dist/scripts/{9273-19a85ad489-lite.chunk.js → 9273-2721453abd-lite.chunk.js} +0 -0
  418. /package/dist/scripts/{9371-b177ac9805-lite.chunk.js.LICENSE.txt → 9371-31e855a07c-lite.chunk.js.LICENSE.txt} +0 -0
  419. /package/dist/scripts/{9428-8f8662cadc-lite.chunk.js.LICENSE.txt → 9428-1dcd12662a-lite.chunk.js.LICENSE.txt} +0 -0
  420. /package/dist/scripts/{9455-f87c0d3adb-lite.chunk.js → 9455-7edee57d7e-lite.chunk.js} +0 -0
  421. /package/dist/scripts/{9478-a8bf32cd2f-lite.chunk.js.LICENSE.txt → 9478-e3fe60ea47-lite.chunk.js.LICENSE.txt} +0 -0
  422. /package/dist/scripts/{9484-59dae0b6e9-lite.chunk.js.LICENSE.txt → 9484-3e1eb0a7fb-lite.chunk.js.LICENSE.txt} +0 -0
  423. /package/dist/scripts/{9614-5de08f30bb-lite.chunk.js → 9614-5fe32c272d-lite.chunk.js} +0 -0
  424. /package/dist/scripts/{9719-adf7d8da55-lite.chunk.js.LICENSE.txt → 9719-d2875a0969-lite.chunk.js.LICENSE.txt} +0 -0
  425. /package/dist/scripts/{9798-4f3b5220b9-lite.chunk.js → 9798-27af0f5408-lite.chunk.js} +0 -0
  426. /package/dist/scripts/{9843-f92794771a-lite.chunk.js → 9843-d56bb2296f-lite.chunk.js} +0 -0
  427. /package/dist/scripts/{9880-1ac1450343-lite.chunk.js → 9880-0ed3bdec03-lite.chunk.js} +0 -0
  428. /package/dist/scripts/{9894-bac8528a7b-lite.chunk.js.LICENSE.txt → 9894-04b7d1bf02-lite.chunk.js.LICENSE.txt} +0 -0
  429. /package/dist/scripts/{9918-cd8913f609-lite.chunk.js.LICENSE.txt → 9918-dab2efae14-lite.chunk.js.LICENSE.txt} +0 -0
  430. /package/dist/scripts/{9931-abf79a99fb-lite.chunk.js.LICENSE.txt → 9931-d0df42247b-lite.chunk.js.LICENSE.txt} +0 -0
  431. /package/dist/scripts/{bundle-c274042dd7.min.js.LICENSE.txt → bundle-2c20d40f45.min.js.LICENSE.txt} +0 -0
  432. /package/dist/scripts/{polyfills-94a5047ebb.min.js.LICENSE.txt → polyfills-7bd16772e3.min.js.LICENSE.txt} +0 -0
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[4448],{26512:(e,t,n)=>{n.r(t),n.d(t,{MyVideosView:()=>$});var a=n(32735),i=n(70680),r=n(23481),o=n(20354),l=n(28400),c=n(65858),s=n(73518),u=n(83834),d=n(65403),m=n(10874),v=n(37395),p=n(83345),g=n(74696),h=n(30254),f=n(4632),y=n(51365),E=n(16714),k=n(1666),b=n(31949),w=n(299),V=n(91286),A=n(22902),F=n(79612),O=n(35223),L=n(67753),M=n(31908),N=n(35949),D=n(73417),x=n(14070),C=n(97291),B=n(27638),I=n(44110),S=n(97816),T=n(98860),_=n(12617),j=n(45967),P=n(65202),Y=n(74796),H=n(14305),R=n(61970),U=n(82431),W=n(26859),G=n(18097);const X={uploadingList:"wg7hV"};var Z="default.myVideos";function $(e){var t,n,$,q,z,J,K,Q,ee,te;(0,F.M)({title:r.T.getPhrase(Z,"pageTitle")});var ne=(0,i.I0)(),ae=(0,B.u)(c.LZ.VideoThumbnail),ie=ae.setFavourite,re=ae.canFavourite,oe=(0,A.T)(),le=oe.hasPermissions,ce=oe.hasLocalPermissions,se=(0,j.q)().handleDragEnd,ue=o.a.useBasicFetch(b.N.currentUser()),de=o.a.useBasicFetch((null===(t=ue.data)||void 0===t?void 0:t.isAuthenticated)&&k.h.yearGroups(ue.data.customerId)),me=o.a.useBasicFetch((null===(n=ue.data)||void 0===n?void 0:n.isAuthenticated)&&b.N.workspace()),ve=null===(q=null===($=me.data)||void 0===$?void 0:$.categoryTree)||void 0===q?void 0:q.id,pe=(0,T.P)(ve),ge=(0,R.y)(),he=(0,R.W)(null===(z=me.data)||void 0===z?void 0:z.id,null===(J=me.data)||void 0===J?void 0:J.categoryTree.id),fe=(0,I.i)(),ye=(0,Y.f)(),Ee=function(e,t){return me.data?_.E.videos(ve,e,t):null},ke=!ce(E.E.ViewMyVideosLanding)&&ue.hasCompleted,be=o.a.useBasicFetch(ke&&Ee(e.cursor,e.typeFilter));(0,V.v)(be);var we=(0,P.J)({onRemove:function(e,t){return o.a.getFetch(ne)(Ee(e,t))}}),Ve=we.uploadingVideos,Ae=we.onClickAlternate,Fe=we.onClickDelete,Oe=we.processingIds,Le=null===(Q=null===(K=be.data)||void 0===K?void 0:K.data)||void 0===Q?void 0:Q.filter((function(e){return!Oe[e.id]}));(0,S.V)(null==Le?void 0:Le.filter(M.M.isVideo),{hasCurriculumLinks:!0});var Me=(0,w.X)(Le);return ce(E.E.ViewMyVideosLanding)?a.createElement(H.V,null):a.createElement(y.M.Provider,{value:ge},a.createElement("div",{className:"px-3"},a.createElement(D.T,null),a.createElement("div",{className:"d-flex justify-content-between"},a.createElement("h1",{className:"h2 mb-0"},a.createElement(p.x,{namespace:Z,phrase:"header"})),a.createElement("div",null,a.createElement("div",{className:"d-sm-none"},a.createElement(W.c,{canUpload:le(E.C.UploadVideo)})),a.createElement("div",{className:"ms-2 d-md-inline-block d-none"},a.createElement(m.h,{svgName:O.vn.Plus,appLink:{application:C.O.MY_VIDEOS,action:x.e.MyVideos.ADD_FOLDER,args:[null===(ee=me.data)||void 0===ee?void 0:ee.id]},className:"btn btn-outline-dark"},a.createElement(p.x,{namespace:Z,phrase:"addFolder"}))))),a.createElement("hr",null),a.createElement(s.p,{handleDragEnd:se,dragOverlayComponent:N.U,source:me.data},a.createElement("div",null,!(null==pe?void 0:pe.hasCompleted)&&a.createElement(d.i,null),!!(null===(te=null==pe?void 0:pe.items)||void 0===te?void 0:te.length)&&a.createElement("div",{className:"mx-n2"},a.createElement(u.$,{folders:pe.items,getAppLink:function(e){return{application:C.O.MY_VIDEOS,action:x.e.MyVideos.MY_VIDEOS_FOLDER,args:[e.id,l.m.slugify(e.name)]}},expandFolders:!1,getFolderActions:function(e){return ye("folder",e)},drag:!0,drop:!0})),a.createElement(h.X,{allowBulkAction:!0,allowFilter:!0,checkboxHelper:Me,getVideosBulkAction:he,locationContext:c.LZ.MyVideos,typeFilter:e.typeFilter,getAppLink:function(){return{application:C.O.MY_VIDEOS,action:x.e.MyVideos.MY_VIDEOS}}}),!!(null==Ve?void 0:Ve.length)&&a.createElement("div",{className:"position-relative ".concat(X.uploadingList)},Ve.map((function(e){return a.createElement(G.X,{item:e,onClickAlternate:Ae,onClickDelete:Fe,key:e.id,allowBulkAction:!0})}))),function(){var t,n;return ue.data&&be.data?Le.length||Ve.length?a.createElement(a.Fragment,null,a.createElement(f.E4,{videos:Le,yearGroups:de.data,getVideoAppLink:L.W.getAppLink,getSubTextAppLink:function(e){return U.j.getSeriesAppLink(e.series)},setFavourite:ie,canFavourite:re,presentationAudiences:fe.data,canRemovePrivateVideos:!0,allowBulkAction:!0,getVideosBulkAction:he,typeFilter:e.typeFilter,checkboxHelper:Me,drag:!0}),!!(null===(n=null===(t=be.data)||void 0===t?void 0:t.pagination)||void 0===n?void 0:n.cursors)&&a.createElement(v.t,{appLink:{action:x.e.MyVideos.MY_VIDEOS,application:C.O.MY_VIDEOS,params:{cursor:e.cursor,previous:e.previous,type:e.typeFilter}},cursors:{next:be.data.pagination.cursors.next,previous:e.cursor},buttonVariant:"outline-dark",className:"py-2 float-end",scrollTop:!0,prevHack:!0})):a.createElement(H.K,null):a.createElement("div",{className:"mx-n2"},a.createElement(g.S,{allowBulkActions:!0}))}()))))}},87821:(e,t,n)=>{n.d(t,{p:()=>i});var a=n(110),i={userVideoHistory:function(e,t,n,i){var r="video:history",o="{gateway}/v1/users/me/watch-history";return e&&(r+=":".concat(e),o+="?cursor=".concat(e)),{key:r,url:o,formatData:function(e){return{data:e.data.map((function(e){var t=a.O.format(e.lastTimeWatched),n=a.O.format(t,"YYYY-MM-DD");return Object.assign(Object.assign({},e),{lastTimeWatched:t,lastDateWatched:n})})),pagination:e.pagination}},success:t,error:n,always:i}},videoHistory:function(e,t,n,a,i){var r=e.sort().map((function(e){return"videoId=".concat(e)}));return{key:"video:history:videos:".concat(r.join("&")),url:"{gateway}/v1/videos/history?".concat(r.join("&")),normalizeOptions:{namespace:t},formatData:function(e){return(null==e?void 0:e.length)?e.map((function(e){return{id:e.videoId,lastProgressPoint:e.lastProgressPoint}})):e},success:n,error:a,always:i}}}},73417:(e,t,n)=>{n.d(t,{T:()=>u});var a=n(32735),i=n(11607),r=n(83914),o=n(83345),l=n(87348),c=n(35223),s="shared.upgradeFeedbackBanner";function u(){var e=(0,l.Q)(),t=e.showFeedbackBanner,n=e.dismissFeedbackBanner;return t?a.createElement("div",{className:"alert bg-light-blue p-2 rounded text-info fw-semibold d-flex justify-content-between align-items-center"},a.createElement(o.x,{namespace:s,phrase:"message",options:{url:"https://www.clickvieweducation.com/en-au/blog/product/exchange-tv-new-look"}}),a.createElement(i.L,{onClick:n},a.createElement(r.x,{svgName:c.vn.Close,className:"ms-2 svg-container"}))):a.createElement(a.Fragment,null)}},97816:(e,t,n)=>{n.d(t,{V:()=>v});var a=n(32735),i=n(20354),r=n(21750),o=n(63419),l=n(31949),c=n(1575),s=n(87821);function u(e){return function(e){if(Array.isArray(e))return d(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 d(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)?d(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.")}()}function d(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=new Array(t);n<t;n++)a[n]=e[n];return a}var m={ratings:!1,favourites:!1,watchHistory:!1,hasCurriculumLinks:!1};function v(e){var t,n,d,v=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},p=Object.assign(Object.assign({},m),v),g=p.ratings,h=p.favourites,f=p.watchHistory,y=p.hasCurriculumLinks,E=i.a.useBasicFetch(l.N.currentUser()),k=e&&(Array.isArray(e)?e.filter(Boolean).map((function(e){return e.id})):e.data.filter(Boolean).map((function(e){return e.id}))),b=E.data;t=a.useMemo((function(){if(!(null==b?void 0:b.isAuthenticated))return[];var e=[];return g&&(e=[].concat(u(e),[!!(null==k?void 0:k.length)&&c.R.videoRatings(k,v.flightNamespace)])),h&&(e=[].concat(u(e),[!!(null==k?void 0:k.length)&&b&&o.P.isFavourited(b.id,k,v.flightNamespace)])),f&&(e=[].concat(u(e),[!!(null==k?void 0:k.length)&&b&&s.p.videoHistory(k,v.flightNamespace)])),y&&(e=[].concat(u(e),[!!(null==k?void 0:k.length)&&r.x.hasCurriculumLinks(k,null,v.flightNamespace)])),e.filter(Boolean)}),[null==k?void 0:k.length]),n=!!e,d=i.a.useGetFetch(),a.useEffect((function(){n&&t.length&&t.forEach((function(e){d(e)}))}),[t.length])}}}]);
@@ -1,2 +0,0 @@
1
- /*! For license information please see 4456-cfb9053629-lite.chunk.js.LICENSE.txt */
2
- "use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[4456],{73758:(e,t,n)=>{function r(e){return r="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},r(e)}function i(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,o(r.key),r)}}function o(e){var t=function(e,t){if("object"!=r(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=r(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==r(t)?t:t+""}n.d(t,{n:()=>a});var a=new(function(){return e=function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.listeners={}},t=[{key:"subscribe",value:function(e,t){this.registerListener(e,t)}},{key:"subscribeOnce",value:function(e,t){this.registerListener(e,t,1)}},{key:"unsubscribe",value:function(e,t){this.deregisterListener(e,t)}},{key:"trigger",value:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];this.triggerCallbacks(e,n)}},{key:"registerListener",value:function(e,t,n){var r;if("string"!=typeof e)throw new Error("Event name must be a string");if("function"!=typeof t)throw new Error("Event callback must be a function");if(n&&"number"!=typeof n)throw new Error("Execution limit must be a number or undefined");this.listeners[e]=null!==(r=this.listeners[e])&&void 0!==r?r:[],this.listeners[e].push({callback:t,executionLimit:n})}},{key:"deregisterListener",value:function(e,t){var n;if("string"!=typeof e)throw new Error("Event name must be a string");if(t&&"function"!=typeof t)throw new Error("Event callback must be a function");if(t){var r=null===(n=this.listeners[e])||void 0===n?void 0:n.findIndex((function(e){return e.callback===t}));"number"==typeof r&&-1!==r&&(this.listeners[e].splice(r,1),0===this.listeners[e].length&&delete this.listeners[e])}else this.listeners[e]=[]}},{key:"triggerCallbacks",value:function(e){for(var t=this,n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];if(this.listeners[e]){var o=[];this.listeners[e].forEach((function(e){var t,n;"number"==typeof e.executionLimit&&(e.executionCount=null!==(n=e.executionCount)&&void 0!==n?n:0,e.executionCount++,e.executionCount===e.executionLimit&&o.push(e.callback)),(t=e.callback).apply.apply(t,[null].concat(r))})),o.length&&o.forEach((function(n){return t.deregisterListener(e,n)}))}}}],t&&i(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}())},26733:(e,t,n)=>{n.d(t,{s:()=>O,R:()=>P});var r=n(32735),i=n(39202),o=n(97395),a=n(49985),s=n(65858),u=n(36848),c=n(75163),l=n(76177),f=n(71063),p=n(54610),h=n(4594),y=n(1164),d=n(79967),v=n(67453);const b={imageStyle:"I9E5O",item:"tqUFn",background:"s1dNr",thumbnailContainer:"EDiGi",teacherPack:"_tdVE",text:"g5NWS",hoverState:"xRYhX",atomGuide:"X39wU",studentActivity:"X9pMl",additionalMaterials:"qRVUo",userUploaded:"_18JaV",imageTypeResource:"KYtZL"};var g={width:200,resizeType:p.Nq.Cover};function m(e,t){var n,r,i;if("thumbnail"in t&&(null===(n=t.thumbnail)||void 0===n?void 0:n.url))return v.j.createUrl(null===(r=t.thumbnail)||void 0===r?void 0:r.url,Object.assign({},g));var a=o._.safeUrlConcat(e,"/v1/previews");return"metadata"in t?t.metadata.type===y.L.Pdf?v.j.createResourceImage(a,t.url,g):t.metadata.type===y.L.Image?v.j.createUrl(t.url,{size:p.h2.Medium,resizeType:p.Nq.Cover}):(null===(i=t.pdf)||void 0===i?void 0:i.url)?v.j.createResourceImage(a,t.pdf.url,g):(t.metadata.type,y.L.Zip,"/images/zip-resource.png"):v.j.createResourceImage(a,t.url,Object.assign({},g))}function w(e){var t;return"metadata"in e?e.metadata.type===y.L.Pdf?p.__.Pdf:e.metadata.type===y.L.Image?p.__.Thumbnails:(null===(t=e.pdf)||void 0===t?void 0:t.url)?p.__.Pdf:(e.metadata.type,y.L.Zip,p.__.Thumbnails):p.__.Link}function O(e){var t,n,i,o,a,u,f,p=null,h=0;"metadata"in e.data&&(p=e.data.metadata,h=null!==(i=null===(n=null===(t=e.data.thumbnail)||void 0===t?void 0:t.metadata)||void 0===n?void 0:n.rotation)&&void 0!==i?i:0);var d="".concat(null!==(a=null===(o=e.theme)||void 0===o?void 0:o.containerClass)&&void 0!==a?a:""," pt-3 px-3 rounded-3 d-flex flex-column align-items-center")+" justify-content-end ".concat(function(e){switch(e){case"atom-guide":return b.atomGuide;case"student-activity":return b.studentActivity;case"teacher-pack":return b.teacherPack;case"additional-materials":return b.additionalMaterials;default:return b.userUploaded}}(null==p?void 0:p.resourceType)," ").concat(b.background," ").concat(e.applyHoverState?b.hoverState:""," ");return r.createElement("div",{className:d},!e.hideHeading&&r.createElement(l.u,{title:e.data.name},r.createElement("h3",{className:"text-center text-break h5 mb-3 ".concat(b.text)},r.createElement("span",{className:"clamp-1"},e.data.name))),r.createElement("div",{className:"".concat(null!==(f=null===(u=e.theme)||void 0===u?void 0:u.thumbnailContainerClass)&&void 0!==f?f:""," w-75 overflow-hidden ").concat(b.thumbnailContainer," ").concat(b.imageStyle)},r.createElement(c.Z,{data:m(e.imageCdnUrl,e.data),imageType:w(e.data),imageStyle:{transform:"rotate(".concat(h,"deg)")},alt:e.data.name,analyticsOptions:{location:s.LZ.SlidingListItem},errorFallbackImageSrc:e.imageErrorFallbackUrl,imageClassName:(null==p?void 0:p.type)===y.L.Image?"".concat(b.imageTypeResource," ").concat(b.imageStyle):"",preload:e.preloadImage,preventLoad:!e.preloadImage})))}O.defaultProps={preloadImage:!0,actionBehaviour:"normal"};var P=r.memo((function(e){var t,n,o,c,l=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 i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n}(e,[]),p=(t=e.data,n=e.actionBehaviour,c=(0,d.k)(),"public"===n||!c.xs&&!c.sm&&"resource"===t.type&&"metadata"in t&&(t.metadata.type===y.L.Image||(t.metadata.type===y.L.Pdf?!!t.url:!!(null===(o=t.pdf)||void 0===o?void 0:o.url)))),v=Object.assign(Object.assign({},e.analyticsData),e.data),g=Object.assign(Object.assign({},e.analyticsOptions),{actionType:s.Vw.Click,entity:e.data.typeId===h.E.Resource?s.py.Resource:s.py.Link});function m(){a.k.logUserAction(v,g)}var w,P=!!e.data.url;return l.applyHoverState=p||P,r.createElement("div",{className:"pt-1 px-1 flex-shrink-0 ".concat(b.item," ").concat(f.M.RESOURCE_ITEM_SELECTOR)},(w="d-block no-decoration","link"===e.data.type?r.createElement("a",{href:e.data.url,target:"_blank",className:w,onClick:m},r.createElement(O,Object.assign({},l))):p?"public"===e.actionBehaviour?r.createElement("div",{className:"".concat(w," cursor-pointer d-inline"),onClick:function(){m(),i.C$.trigger(e.getAppLink(e.data))}},r.createElement(O,Object.assign({},l))):r.createElement(u.F,{appLink:e.getAppLink(e.data),className:w,analyticsData:v,analyticsOptions:g},r.createElement(O,Object.assign({},l))):P?r.createElement("a",{href:e.data.url,className:w,onClick:m},r.createElement(O,Object.assign({},l))):r.createElement("div",{className:w},r.createElement(O,Object.assign({},l)))))}))},89819:(e,t,n)=>{n.r(t),n.d(t,{ClickViewPlayer:()=>ai});var r=n(32735),i=n(36527),o=(n(16852),n(93861));function a(e){return a="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},a(e)}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,u(r.key),r)}}function u(e){var t=function(e,t){if("object"!=a(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=a(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==a(t)?t:t+""}function c(e,t,n){return t=p(t),function(e,t){if(t&&("object"===a(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,l()?Reflect.construct(t,n||[],p(e).constructor):t.apply(e,n))}function l(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(l=function(){return!!e})()}function f(){return f="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=p(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},f.apply(this,arguments)}function p(e){return p=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},p(e)}function h(e,t){return h=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},h(e,t)}var y=function(e){function t(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(e=c(this,t,arguments)).alwaysCollapsed=!1,e.isCollapsed=!1,e.isCollabsible=!0,e}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&h(e,t)}(t,e),n=t,(r=[{key:"buildCSSClass",value:function(){return"cv-create-clip-button"}},{key:"getCollabsibleName",value:function(){return this.controlText_}},{key:"getCollabsibleValue",value:function(){return""}},{key:"showInCollabsibleMenu",value:function(){return!0}},{key:"showCollapsibleMenu",value:function(){f(p(t.prototype),"handleClick",this).call(this,null)}}])&&s(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getComponent("Button"));function d(e){return d="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},d(e)}function v(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,b(r.key),r)}}function b(e){var t=function(e,t){if("object"!=d(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=d(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==d(t)?t:t+""}function g(e,t,n){return t=w(t),function(e,t){if(t&&("object"===d(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,m()?Reflect.construct(t,n||[],w(e).constructor):t.apply(e,n))}function m(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(m=function(){return!!e})()}function w(e){return w=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},w(e)}function O(e,t){return O=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},O(e,t)}y.prototype.controlText_="Create Clip",o.Z.registerComponent("CreateClipButton",y);var P=function(e){function t(e,n){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=g(this,t,[e,n])).options=n,e.ready((function(){return r.onReady()})),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&O(e,t)}(t,e),n=t,(r=[{key:"onReady",value:function(){var e,t=this.player.getChild("collapserator"),n=null===(e=null==t?void 0:t.children())||void 0===e?void 0:e.findIndex((function(e){return"CustomControlSpacer"===e.name()}));n&&-1!==n&&t.addChild("CreateClipButton",{clickHandler:this.options.onClick},n+1)}}])&&v(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getPlugin("plugin"));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 k(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,j(r.key),r)}}function j(e){var t=function(e,t){if("object"!=S(e)||!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:t+""}function C(e,t,n){return t=E(t),function(e,t){if(t&&("object"===S(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,T()?Reflect.construct(t,n||[],E(e).constructor):t.apply(e,n))}function T(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(T=function(){return!!e})()}function E(e){return E=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},E(e)}function _(e,t){return _=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},_(e,t)}o.Z.registerPlugin("createClipButtonPlugin",P);var I=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),C(this,t,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&_(e,t)}(t,e),n=t,(r=[{key:"handlePictureInPictureEnabledChange",value:function(){this.enable()}}])&&k(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getComponent("PictureInPictureToggle"));function x(e){return x="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},x(e)}function R(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,M(r.key),r)}}function M(e){var t=function(e,t){if("object"!=x(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=x(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==x(t)?t:t+""}function L(e,t,n){return t=B(t),function(e,t){if(t&&("object"===x(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,D()?Reflect.construct(t,n||[],B(e).constructor):t.apply(e,n))}function D(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(D=function(){return!!e})()}function N(){return N="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=B(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},N.apply(this,arguments)}function B(e){return B=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},B(e)}function V(e,t){return V=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},V(e,t)}o.Z.registerComponent("PictureInPictureToggle",I);var A=o.Z.getComponent("PlayToggle"),F=function(e){function t(e,n){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=L(this,t,[e,n])).pictureInPictureEnabled=!1,r.options=n,r.bindFunctions(),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&V(e,t)}(t,e),n=t,(r=[{key:"bindFunctions",value:function(){this.requestPictureInPicture=this.requestPictureInPicture.bind(this),this.exitPictureInPicture=this.exitPictureInPicture.bind(this),this.onPlayerResize=this.onPlayerResize.bind(this),this.playerRequestPictureInPictureFn=this.player.requestPictureInPicture,this.playerExitPictureInPictureFn=this.player.exitPictureInPicture,this.player.requestPictureInPicture=this.requestPictureInPicture,this.player.exitPictureInPicture=this.exitPictureInPicture}},{key:"enablePictureInPicture",value:function(){var e=this;if(this.player.options_.fluid&&!this.pictureInPictureEnabled){var t=this.getToggleParentComponent();if(t){this.pictureInPictureEnabled=!0;var n=t.children().findIndex((function(e){var t;return"fullscreentoggle"===(null===(t=e.name())||void 0===t?void 0:t.toLowerCase())}));-1===n&&(n=t.children().length-1),t.addChild("pictureInPictureToggle",{},n);var r=t.getChild("pictureInPictureToggle");null==r||r.enable(),this.player.on("playerresize",this.onPlayerResize),this.player.on("dispose",(function(){var t;null===(t=e.player)||void 0===t||t.off("playerresize",e.onPlayerResize)}))}}}},{key:"disablePictureInPicture",value:function(){if(this.pictureInPictureEnabled){this.pictureInPictureEnabled=!1;var e=this.getToggleParentComponent(),t=null==e?void 0:e.getChild("pictureInPictureToggle");t&&e.removeChild(t),this.player.off("playerresize",this.onPlayerResize)}}},{key:"togglePictureInPicture",value:function(e){if(e!==this.player.isInPictureInPicture()){var t=e?"enterpictureinpicture":"leavepictureinpicture";this.player.isInPictureInPicture(e),this.player.trigger(t),e?this.addPipStyles():this.removePipStyles()}}},{key:"onPlayerResize",value:function(){if(!this.player.isInPictureInPicture()){var e=this.player.el().getBoundingClientRect();0!==e.width&&(e.width<800?this.disablePictureInPicture():this.enablePictureInPicture())}}},{key:"addPipStyles",value:function(){this.player.addClass("cv-picture-in-picture"),this.playToggle=new A(this.player),this.playToggle.addClass("cv-pip-play-toggle"),this.player.addChild(this.playToggle),this.player.paused()?this.playToggle.handlePause():this.playToggle.handlePlay()}},{key:"removePipStyles",value:function(){this.player.removeClass("cv-picture-in-picture"),this.player.removeChild(this.playToggle),delete this.playToggle}},{key:"requestPictureInPicture",value:function(){var e;this.pictureInPictureEnabled&&(this.togglePictureInPicture(!0),"function"==typeof(null===(e=this.options)||void 0===e?void 0:e.onRequestPictureInPicture)&&this.options.onRequestPictureInPicture(!0))}},{key:"exitPictureInPicture",value:function(){this.togglePictureInPicture(!1),this.options.onRequestPictureInPicture(!1),this.removePipStyles()}},{key:"getToggleParentComponent",value:function(){return this.player.getChild("collapserator")}},{key:"dispose",value:function(){this.player.requestPictureInPicture=this.playerRequestPictureInPictureFn,this.player.exitPictureInPicture=this.playerExitPictureInPictureFn,N(B(t.prototype),"dispose",this).call(this)}}])&&R(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getPlugin("plugin"));o.Z.registerPlugin("pictureInPicture",F);var U=n(23035),Z=n(42892),z=n(73758);function G(e){return G="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},G(e)}function q(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,H(r.key),r)}}function H(e){var t=function(e,t){if("object"!=G(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=G(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==G(t)?t:t+""}function Y(e,t,n){return t=Q(t),function(e,t){if(t&&("object"===G(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,W()?Reflect.construct(t,n||[],Q(e).constructor):t.apply(e,n))}function W(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(W=function(){return!!e})()}function $(){return $="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Q(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},$.apply(this,arguments)}function Q(e){return Q=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Q(e)}function X(e,t){return X=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},X(e,t)}var J=function(e){function t(e,n){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=Y(this,t,[e,n])).hasBuffered=!1,r.hasPlayed=!1,r.eventsService=z.n,r.pointOfInterest=n.pointOfInterest,r.onMouseOver=r.onMouseOver.bind(r),r.onMouseLeave=r.onMouseLeave.bind(r),r.onGlancePointOfInterestMouseEnter=r.onGlancePointOfInterestMouseEnter.bind(r),r.onGlancePointOfInterestMouseLeave=r.onGlancePointOfInterestMouseLeave.bind(r),r.initialize(),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&X(e,t)}(t,e),n=t,(r=[{key:"initialize",value:function(){this.setPosition(),this.bindListeners()}},{key:"buildCSSClass",value:function(){return"cv-point-of-interest-indicator ".concat($(Q(t.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,n,r){return $(Q(t.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},n),{className:this.buildCSSClass()}),r)}},{key:"bindListeners",value:function(){this.on("mouseover",this.onMouseOver),this.on("mouseleave",this.onMouseLeave),this.eventsService.subscribe("glance:poi:mouseover",this.onGlancePointOfInterestMouseEnter),this.eventsService.subscribe("glance:poi:mouseleave",this.onGlancePointOfInterestMouseLeave)}},{key:"dispose",value:function(){this.eventsService.unsubscribe("glance:poi:mouseover",this.onGlancePointOfInterestMouseEnter),this.eventsService.unsubscribe("glance:poi:mouseleave",this.onGlancePointOfInterestMouseLeave)}},{key:"getPointOfInterestTime",value:function(){return this.pointOfInterest.startTime}},{key:"setPosition",value:function(){var e=this.player().duration();this.el_.style.left=this.getPointOfInterestTime()/e*100+"%"}},{key:"updateBuffered",value:function(e){var t=this.getPointOfInterestTime()<=e;if(t!==this.hasBuffered){this.hasBuffered=t;var n="cv-point-of-interest-indicator-buffered";this.hasBuffered?this.addClass(n):this.removeClass(n)}}},{key:"updatePlaybackProgress",value:function(e){var t=this.getPointOfInterestTime()<=e;if(t!==this.hasPlayed){this.hasPlayed=t;var n="cv-point-of-interest-indicator-played";t?this.addClass(n):this.removeClass(n)}}},{key:"toggleVisibility",value:function(e){var t="cv-point-of-interest-indicator-hidden";e?this.removeClass(t):this.addClass(t)}},{key:"onMouseOver",value:function(){this.setTimeTooltipText(),this.eventsService.trigger("player:poi:mouseover",this.pointOfInterest)}},{key:"onMouseLeave",value:function(){this.clearTimeTooltipText(),this.eventsService.trigger("player:poi:mouseleave")}},{key:"onGlancePointOfInterestMouseEnter",value:function(e){e.id===this.pointOfInterest.id&&(this.addClass("cv-point-of-interest-indicator-highlight"),this.setTimeTooltipTime(),this.setTimeTooltipText(),this.positionMouseTimeDisplay(),this.showMouseTimeDisplay())}},{key:"onGlancePointOfInterestMouseLeave",value:function(){this.removeClass("cv-point-of-interest-indicator-highlight"),this.hideMouseTimeDisplay()}},{key:"setTimeTooltipText",value:function(){var e;null===(e=this.getTimeTooltip())||void 0===e||e.setCustomChapterText(this.pointOfInterest.description)}},{key:"clearTimeTooltipText",value:function(){var e;null===(e=this.getTimeTooltip())||void 0===e||e.setCustomChapterText()}},{key:"setTimeTooltipTime",value:function(){var e=this.getTimeTooltip();null==e||e.updateTime(this.getPointOfInterestTime())}},{key:"positionMouseTimeDisplay",value:function(){var e,t,n=null===(e=this.getSeekBar())||void 0===e?void 0:e.el();if(n){var r=o.Z.dom.findPosition(n),i=this.getPointOfInterestTime()/this.player().duration();null===(t=this.getMouseTimeDisplay())||void 0===t||t.update(r,i)}}},{key:"showMouseTimeDisplay",value:function(){var e;null===(e=this.getMouseTimeDisplay())||void 0===e||e.forceShow()}},{key:"hideMouseTimeDisplay",value:function(){var e;null===(e=this.getMouseTimeDisplay())||void 0===e||e.removeForceShow()}},{key:"getSeekBar",value:function(){var e;return null===(e=this.player().controlBar.getChild("ProgressControl"))||void 0===e?void 0:e.getChild("SeekBar")}},{key:"getMouseTimeDisplay",value:function(){var e;return null===(e=this.getSeekBar())||void 0===e?void 0:e.getChild("MouseTimeDisplay")}},{key:"getTimeTooltip",value:function(){var e;return null===(e=this.getMouseTimeDisplay())||void 0===e?void 0:e.getChild("TimeTooltip")}}])&&q(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getComponent("Component"));function K(e){return K="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},K(e)}function ee(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,te(r.key),r)}}function te(e){var t=function(e,t){if("object"!=K(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=K(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==K(t)?t:t+""}function ne(e,t,n){return t=oe(t),function(e,t){if(t&&("object"===K(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,re()?Reflect.construct(t,n||[],oe(e).constructor):t.apply(e,n))}function re(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(re=function(){return!!e})()}function ie(){return ie="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=oe(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},ie.apply(this,arguments)}function oe(e){return oe=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},oe(e)}function ae(e,t){return ae=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},ae(e,t)}var se=function(e){function t(e,n){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=ne(this,t,[e,n])).pointsOfInterestVisible=n.pointsOfInterestVisible,r.toggle(r.pointsOfInterestVisible),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ae(e,t)}(t,e),n=t,(r=[{key:"handleToggle",value:function(){this.toggle(!this.pointsOfInterestVisible)}},{key:"toggle",value:function(e){e?this.toggleOn():this.toggleOff()}},{key:"toggleOn",value:function(){o.Z.dom.addClass(this.toggleEl,"on"),this.pointsOfInterestVisible=!0,this.player().pointsOfInterestPlugin().togglePointsOfInterest(this.pointsOfInterestVisible)}},{key:"toggleOff",value:function(){o.Z.dom.removeClass(this.toggleEl,"on"),this.pointsOfInterestVisible=!1,this.player().pointsOfInterestPlugin().togglePointsOfInterest(this.pointsOfInterestVisible)}},{key:"handleClick",value:function(e){e.stopImmediatePropagation()}},{key:"createEl",value:function(e,n,r){this.handlerBound||(this.handleToggle=this.handleToggle.bind(this),this.handlerBound=!0),this.toggleEl&&this.toggleEl.removeEventListener("click",this.handleToggle),this.toggleEl=o.Z.dom.createEl("div",{className:"custom-toggle toggle-option float-end",innerHTML:'<span class="handle"></span></div>'}),this.toggleEl.addEventListener("click",this.handleToggle);var i=ie(oe(t.prototype),"createEl",this).call(this,e,{className:"vjs-menu-item cv-cog-menu-item",innerHTML:'\n <span class="vjs-menu-item-text">Points of Interest</span>\n <span class="cv-toggle-container"></span>'},r);return i.children[1].appendChild(this.toggleEl),i}}])&&ee(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getComponent("MenuItem"));function ue(e){return ue="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},ue(e)}function ce(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,le(r.key),r)}}function le(e){var t=function(e,t){if("object"!=ue(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=ue(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==ue(t)?t:t+""}function fe(e,t,n){return t=he(t),function(e,t){if(t&&("object"===ue(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,pe()?Reflect.construct(t,n||[],he(e).constructor):t.apply(e,n))}function pe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(pe=function(){return!!e})()}function he(e){return he=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},he(e)}function ye(e,t){return ye=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},ye(e,t)}o.Z.registerComponent("PointsOfInterestMenuItem",se);var de=o.Z.getPlugin("plugin"),ve="cvplayer-points-of-interest",be=function(e){function t(e,n){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=fe(this,t,[e])).pointOfInterestIndicators=[],r.enabled=!0,r.pointsOfInterest=null==n?void 0:n.pointsOfInterest,r.initialize=r.initialize.bind(r),r.updateBuffered=r.updateBuffered.bind(r),r.updatePlaybackProgress=r.updatePlaybackProgress.bind(r),r.player.one("loadedmetadata",(function(){return r.player.ready(r.initialize)})),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ye(e,t)}(t,e),n=t,(r=[{key:"initialize",value:function(){this.pointsOfInterest&&(Z.S.hasLocalStorage()&&"false"===Z.S.get(ve)&&(this.enabled=!1),this.setupTrack(),this.createPointOfInterestIndicators(),this.addMenuItem(),this.bindListeners())}},{key:"bindListeners",value:function(){var e=this;this.player.on("progress",this.updateBuffered),this.player.on("timeupdate",this.updatePlaybackProgress),this.player.on("dispose",(function(){var t,n;null===(t=e.player)||void 0===t||t.off("progress",e.updateBuffered),null===(n=e.player)||void 0===n||n.off("timeupdate",e.updatePlaybackProgress)}))}},{key:"togglePointsOfInterest",value:function(e){Z.S.set(ve,e.toString()),this.pointOfInterestIndicators.forEach((function(t){return t.toggleVisibility(e)}))}},{key:"setupTrack",value:function(){var e=this.player.addTextTrack("metadata","pointsofinterest");this.pointsOfInterest.forEach((function(t){e.addCue({startTime:t.startTime,endTime:t.endTime,text:t.description})})),e.trigger({type:"loadeddata",target:e})}},{key:"createPointOfInterestIndicators",value:function(){var e,t=this,n=null===(e=this.player.controlBar.getChild("ProgressControl"))||void 0===e?void 0:e.getChild("SeekBar");this.pointsOfInterest.forEach((function(e){var r=new J(t.player,{pointOfInterest:e});t.pointOfInterestIndicators.push(r),n.addChild(r)}))}},{key:"addMenuItem",value:function(){var e;(null===(e=this.player.getChild("collapserator"))||void 0===e?void 0:e.getChild("cogButton")).addItem({index:0,ctor:se,name:"PointsOfInterestMenuItem",options:{pointsOfInterestVisible:this.enabled}})}},{key:"updateBuffered",value:function(){var e=this;this.pointOfInterestIndicators.forEach((function(t){return t.updateBuffered((0,U.b)(e.player))}))}},{key:"updatePlaybackProgress",value:function(){var e=this;this.pointOfInterestIndicators.forEach((function(t){return t.updatePlaybackProgress(e.player.currentTime())}))}}])&&ce(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(de);function ge(e){return ge="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},ge(e)}function me(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,we(r.key),r)}}function we(e){var t=function(e,t){if("object"!=ge(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=ge(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==ge(t)?t:t+""}function Oe(e,t,n){return t=ke(t),function(e,t){if(t&&("object"===ge(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,Pe()?Reflect.construct(t,n||[],ke(e).constructor):t.apply(e,n))}function Pe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(Pe=function(){return!!e})()}function Se(){return Se="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=ke(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},Se.apply(this,arguments)}function ke(e){return ke=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},ke(e)}function je(e,t){return je=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},je(e,t)}o.Z.registerPlugin("pointsOfInterestPlugin",be),n(93262);var Ce=function(e){function t(e,n){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=Oe(this,t,[e,n])).initialize(),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&je(e,t)}(t,e),n=t,(r=[{key:"initialize",value:function(){this.setPosition()}},{key:"buildCSSClass",value:function(){return"cv-range-indicator ".concat(Se(ke(t.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,n,r){return Se(ke(t.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},n),{className:this.buildCSSClass()}),r)}},{key:"setPosition",value:function(){var e=this.player().duration();this.el_.style.left=this.options_.time/e*100+"%"}}])&&me(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getComponent("Component"));function Te(e){return Te="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},Te(e)}function Ee(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,_e(r.key),r)}}function _e(e){var t=function(e,t){if("object"!=Te(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=Te(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Te(t)?t:t+""}function Ie(e,t,n){return t=Me(t),function(e,t){if(t&&("object"===Te(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,xe()?Reflect.construct(t,n||[],Me(e).constructor):t.apply(e,n))}function xe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(xe=function(){return!!e})()}function Re(){return Re="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Me(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},Re.apply(this,arguments)}function Me(e){return Me=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Me(e)}function Le(e,t){return Le=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Le(e,t)}var De=function(e){function t(e,n){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),Ie(this,t,[e,n])}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Le(e,t)}(t,e),n=t,(r=[{key:"buildCSSClass",value:function(){return"cv-replay-view-button ".concat(Re(Me(t.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,n,r){return Re(Me(t.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},n),{innerHTML:'<span class="'.concat(this.options_.iconClassName,'"></span><span>').concat(this.options_.label,"</span>"),className:this.buildCSSClass()}),r)}},{key:"handleClick",value:function(){this.options_.onPress()}}])&&Ee(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getComponent("ClickableComponent"));function Ne(e){return Ne="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},Ne(e)}function Be(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Ve(r.key),r)}}function Ve(e){var t=function(e,t){if("object"!=Ne(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=Ne(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Ne(t)?t:t+""}function Ae(e,t,n){return t=Ze(t),function(e,t){if(t&&("object"===Ne(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,Fe()?Reflect.construct(t,n||[],Ze(e).constructor):t.apply(e,n))}function Fe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(Fe=function(){return!!e})()}function Ue(){return Ue="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Ze(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},Ue.apply(this,arguments)}function Ze(e){return Ze=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Ze(e)}function ze(e,t){return ze=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},ze(e,t)}var Ge=function(e){function t(e,n){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),Ae(this,t,[e,n])}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ze(e,t)}(t,e),n=t,(r=[{key:"buildCSSClass",value:function(){return"cv-replay-view ".concat(Ue(Ze(t.prototype),"buildCSSClass",this).call(this))}},{key:"createEl",value:function(e,n,r){var i=Ue(Ze(t.prototype),"createEl",this).call(this,e,Object.assign(Object.assign({},n),{className:this.buildCSSClass()}),r),a=o.Z.dom.createEl("h5",{innerHTML:this.localize("This clip has finished"),className:"cv-replay-heading"}),s=o.Z.dom.createEl("div",{className:"cv-button-container"}),u=new De(this.player_,{label:this.localize("Replay clip"),iconClassName:"cv-replay-icon",onPress:this.options_.onReplayPress}),c=new De(this.player_,{label:this.localize("Continue watching"),iconClassName:"cv-continue-icon",onPress:this.options_.onContinuePress});return i.appendChild(a),i.appendChild(s),s.appendChild(u.el()),s.appendChild(c.el()),i}}])&&Be(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getComponent("Component"));function qe(e){return qe="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},qe(e)}function He(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Ye(r.key),r)}}function Ye(e){var t=function(e,t){if("object"!=qe(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=qe(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==qe(t)?t:t+""}function We(e,t,n){return t=Xe(t),function(e,t){if(t&&("object"===qe(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,$e()?Reflect.construct(t,n||[],Xe(e).constructor):t.apply(e,n))}function $e(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return($e=function(){return!!e})()}function Qe(){return Qe="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Xe(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},Qe.apply(this,arguments)}function Xe(e){return Xe=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Xe(e)}function Je(e,t){return Je=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Je(e,t)}var Ke=function(e){function t(e,n){var r;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=We(this,t,[e,n])).startTime=parseFloat(n.startTime.toPrecision(4)),r.endTime=parseFloat(n.endTime.toPrecision(4)),r.dismissed=!1,r.startTime>r.endTime)throw Error("Range start cannot be greater than range end");return r.bindFunctions(),r.initialize(),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Je(e,t)}(t,e),n=t,(r=[{key:"bindFunctions",value:function(){this.onReady=this.onReady.bind(this),this.onTimeUpdateOrSeeked=this.onTimeUpdateOrSeeked.bind(this),this.onReplayPress=this.onReplayPress.bind(this),this.onContinuePress=this.onContinuePress.bind(this)}},{key:"initialize",value:function(){var e=this;this.player.one("loadedmetadata",(function(){return e.player.ready(e.onReady)})),this.player.on("timeupdate",this.onTimeUpdateOrSeeked),this.player.on("seeked",this.onTimeUpdateOrSeeked)}},{key:"onReady",value:function(){this.addCssClasses(),this.showRangeIndicators(),this.addMaskToProgressBar()}},{key:"onTimeUpdateOrSeeked",value:function(){if(!this.dismissed){var e=this.player.currentTime();if(!(e<this.startTime))return e>this.endTime?(this.showReplayView(),this.disablePlayToggle(),this.player.pause(),void this.player.currentTime(this.endTime)):void 0;this.player.currentTime(this.startTime)}}},{key:"onReplayPress",value:function(){this.player.currentTime(this.startTime),this.player.play(),this.hideReplayView(),this.enablePlayToggle()}},{key:"onContinuePress",value:function(){this.dismissed=!0,this.player.play(),this.hideRangeIndicators(),this.removeMaskFromProgressBar(),this.hideReplayView(),this.enablePlayToggle(),this.removeCssClasses()}},{key:"showRangeIndicators",value:function(){var e,t=null===(e=this.player.controlBar.getChild("ProgressControl"))||void 0===e?void 0:e.getChild("SeekBar");this.startTimeIndicator||(this.startTimeIndicator=new Ce(this.player,{time:this.startTime}),null==t||t.addChild(this.startTimeIndicator)),this.endTimeIndicator||(this.endTimeIndicator=new Ce(this.player,{time:this.endTime}),null==t||t.addChild(this.endTimeIndicator))}},{key:"hideRangeIndicators",value:function(){var e,t;null===(e=this.startTimeIndicator)||void 0===e||e.hide(),null===(t=this.endTimeIndicator)||void 0===t||t.hide()}},{key:"addMaskToProgressBar",value:function(){var e,t=null===(e=this.player.controlBar.getChild("ProgressControl"))||void 0===e?void 0:e.getChild("SeekBar"),n=null==t?void 0:t.el().getElementsByClassName("cv-chapter-bar-items");if(n&&n.length){var r=n[0],i=this.player.duration(),o=this.startTime/i*100,a=100-this.endTime/i*100;r.style.clipPath="inset(".concat(-5,"em ").concat(a,"% ").concat(-5,"em ").concat(o,"%)")}}},{key:"removeMaskFromProgressBar",value:function(){var e,t=null===(e=this.player.controlBar.getChild("ProgressControl"))||void 0===e?void 0:e.getChild("SeekBar"),n=null==t?void 0:t.el().getElementsByClassName("cv-chapter-bar-items");n&&n.length&&(n[0].style.clipPath="")}},{key:"showReplayView",value:function(){this.replayView||(this.replayView=new Ge(this.player,{onContinuePress:this.onContinuePress,onReplayPress:this.onReplayPress}),this.player.addChild(this.replayView)),this.replayView.show()}},{key:"hideReplayView",value:function(){var e;null===(e=this.replayView)||void 0===e||e.hide()}},{key:"getPlayToggle",value:function(){var e=this.player.getChild("collapserator");return null==e?void 0:e.getChild("PlayToggle")}},{key:"enablePlayToggle",value:function(){var e=this.getPlayToggle();e&&e.enable()}},{key:"disablePlayToggle",value:function(){var e=this.getPlayToggle();e&&e.disable()}},{key:"addCssClasses",value:function(){this.player.addClass("cv-range-indicator-plugin")}},{key:"removeCssClasses",value:function(){this.player.removeClass("cv-range-indicator-plugin")}},{key:"dispose",value:function(){var e,n,r;this.removeCssClasses(),this.player.off("timeupdate",this.onTimeUpdateOrSeeked),this.player.off("seeked",this.onTimeUpdateOrSeeked),null===(e=this.startTimeIndicator)||void 0===e||e.dispose(),null===(n=this.endTimeIndicator)||void 0===n||n.dispose(),null===(r=this.replayView)||void 0===r||r.dispose(),Qe(Xe(t.prototype),"dispose",this).call(this)}}])&&He(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getPlugin("plugin"));o.Z.registerPlugin("rangeIndicatorPlugin",Ke);var et=n(65858),tt=n(86086),nt=n(12399),rt=n(6156),it=n(11707);function ot(e){return ot="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},ot(e)}function at(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,st(r.key),r)}}function st(e){var t=function(e,t){if("object"!=ot(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=ot(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==ot(t)?t:t+""}var ut={reconnectIntervalInMilliseconds:3e3,heartbeatEnabled:!1,heartbeatIntervalInMillseconds:1e4,heartbeatMessage:""},ct=function(){return e=function e(t){var n=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:ut;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.bindFunctions(),this.url=t,this.options=Object.assign(Object.assign({},ut),r),this.webSocket=this.connect(),this.heartbeat=(new it.b).schedule((function(){return n.send(n.options.heartbeatMessage)})).every(this.options.heartbeatIntervalInMillseconds)},(t=[{key:"bindFunctions",value:function(){this.cleanup=this.cleanup.bind(this),this.handleOpen=this.handleOpen.bind(this),this.handleMessage=this.handleMessage.bind(this),this.handleClose=this.handleClose.bind(this),this.handleError=this.handleError.bind(this),this.connect=this.connect.bind(this),this.send=this.send.bind(this),this.dipose=this.dipose.bind(this)}},{key:"cleanup",value:function(){this.heartbeat.stop(),this.webSocket.removeEventListener("error",this.handleError),this.webSocket.removeEventListener("message",this.handleMessage),this.webSocket.removeEventListener("open",this.handleOpen),this.webSocket.removeEventListener("close",this.handleClose)}},{key:"handleOpen",value:function(e){var t;null===(t=this.onOpen)||void 0===t||t.call(this,e),this.options.heartbeatEnabled&&this.heartbeat.start()}},{key:"handleMessage",value:function(e){var t;null===(t=this.onMessage)||void 0===t||t.call(this,e)}},{key:"handleClose",value:function(e){var t,n=this;null===(t=this.onClose)||void 0===t||t.call(this,e),this.cleanup(),setTimeout((function(){n.webSocket=n.connect()}),this.options.reconnectIntervalInMilliseconds)}},{key:"handleError",value:function(e){var t;null===(t=this.onError)||void 0===t||t.call(this,e),this.handleClose()}},{key:"connect",value:function(){var e=new WebSocket(this.url);return e.addEventListener("open",this.handleOpen),e.addEventListener("message",this.handleMessage),e.addEventListener("close",this.handleClose),e.addEventListener("error",this.handleError),e}},{key:"send",value:function(e){this.webSocket.send(e)}},{key:"dipose",value:function(){this.cleanup(),this.webSocket.close()}}])&&at(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}(),lt=n(95569),ft=function(){var e,t;return null!==(t=null===(e=window.crypto)||void 0===e?void 0:e.randomUUID())&&void 0!==t?t:Math.random().toString()},pt=n(35884);function ht(e){return ht="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},ht(e)}function yt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,dt(r.key),r)}}function dt(e){var t=function(e,t){if("object"!=ht(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=ht(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==ht(t)?t:t+""}var vt,bt=function(){return e=function e(t,n){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._timerStartedAt=0,this.position=0,this.duration=void 0,this.playing=!1,this.mute=!1,this.videoSource="",this.subtitleSource="",this.subtitles=!1,this.volume=0,this.title=t,this.device=n,this.ready=!1,this.playbackFinished=!1,this.debounced=pt.l.withDebouncedSetters(this,2e3),pt.l.withTimestampedSetters(this)},(t=[{key:"position",get:function(){return this._position+this.getTimerDurationInSeconds()},set:function(e){this._position=e,this.restartTimer()}},{key:"playing",get:function(){return this._playing},set:function(e){this._playing=e,e?this.restartTimer():(this._position+=this.getTimerDurationInSeconds(),this.stopTimer())}},{key:"restartTimer",value:function(){this._timerStartedAt=Date.now()}},{key:"stopTimer",value:function(){this._timerStartedAt=0}},{key:"getTimerDurationInSeconds",value:function(){return this._timerStartedAt?(Date.now()-this._timerStartedAt)/1e3:0}}])&&yt(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function gt(e){return gt="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},gt(e)}function mt(){mt=function(){return t};var e,t={},n=Object.prototype,r=n.hasOwnProperty,i=Object.defineProperty||function(e,t,n){e[t]=n.value},o="function"==typeof Symbol?Symbol:{},a=o.iterator||"@@iterator",s=o.asyncIterator||"@@asyncIterator",u=o.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(e){c=function(e,t,n){return e[t]=n}}function l(e,t,n,r){var o=t&&t.prototype instanceof b?t:b,a=Object.create(o.prototype),s=new I(r||[]);return i(a,"_invoke",{value:C(e,n,s)}),a}function f(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}t.wrap=l;var p="suspendedStart",h="suspendedYield",y="executing",d="completed",v={};function b(){}function g(){}function m(){}var w={};c(w,a,(function(){return this}));var O=Object.getPrototypeOf,P=O&&O(O(x([])));P&&P!==n&&r.call(P,a)&&(w=P);var S=m.prototype=b.prototype=Object.create(w);function k(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function j(e,t){function n(i,o,a,s){var u=f(e[i],e,o);if("throw"!==u.type){var c=u.arg,l=c.value;return l&&"object"==gt(l)&&r.call(l,"__await")?t.resolve(l.__await).then((function(e){n("next",e,a,s)}),(function(e){n("throw",e,a,s)})):t.resolve(l).then((function(e){c.value=e,a(c)}),(function(e){return n("throw",e,a,s)}))}s(u.arg)}var o;i(this,"_invoke",{value:function(e,r){function i(){return new t((function(t,i){n(e,r,t,i)}))}return o=o?o.then(i,i):i()}})}function C(t,n,r){var i=p;return function(o,a){if(i===y)throw Error("Generator is already running");if(i===d){if("throw"===o)throw a;return{value:e,done:!0}}for(r.method=o,r.arg=a;;){var s=r.delegate;if(s){var u=T(s,r);if(u){if(u===v)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(i===p)throw i=d,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);i=y;var c=f(t,n,r);if("normal"===c.type){if(i=r.done?d:h,c.arg===v)continue;return{value:c.arg,done:r.done}}"throw"===c.type&&(i=d,r.method="throw",r.arg=c.arg)}}}function T(t,n){var r=n.method,i=t.iterator[r];if(i===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,T(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),v;var o=f(i,t.iterator,n.arg);if("throw"===o.type)return n.method="throw",n.arg=o.arg,n.delegate=null,v;var a=o.arg;return a?a.done?(n[t.resultName]=a.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,v):a:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,v)}function E(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function _(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function I(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(E,this),this.reset(!0)}function x(t){if(t||""===t){var n=t[a];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var i=-1,o=function n(){for(;++i<t.length;)if(r.call(t,i))return n.value=t[i],n.done=!1,n;return n.value=e,n.done=!0,n};return o.next=o}}throw new TypeError(gt(t)+" is not iterable")}return g.prototype=m,i(S,"constructor",{value:m,configurable:!0}),i(m,"constructor",{value:g,configurable:!0}),g.displayName=c(m,u,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===g||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,m):(e.__proto__=m,c(e,u,"GeneratorFunction")),e.prototype=Object.create(S),e},t.awrap=function(e){return{__await:e}},k(j.prototype),c(j.prototype,s,(function(){return this})),t.AsyncIterator=j,t.async=function(e,n,r,i,o){void 0===o&&(o=Promise);var a=new j(l(e,n,r,i),o);return t.isGeneratorFunction(n)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},k(S),c(S,u,"Generator"),c(S,a,(function(){return this})),c(S,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},t.values=x,I.prototype={constructor:I,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(_),!t)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function i(r,i){return s.type="throw",s.arg=t,n.next=r,i&&(n.method="next",n.arg=e),!!i}for(var o=this.tryEntries.length-1;o>=0;--o){var a=this.tryEntries[o],s=a.completion;if("root"===a.tryLoc)return i("end");if(a.tryLoc<=this.prev){var u=r.call(a,"catchLoc"),c=r.call(a,"finallyLoc");if(u&&c){if(this.prev<a.catchLoc)return i(a.catchLoc,!0);if(this.prev<a.finallyLoc)return i(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return i(a.catchLoc,!0)}else{if(!c)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return i(a.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(i.tryLoc<=this.prev&&r.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var o=i;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var a=o?o.completion:{};return a.type=e,a.arg=t,o?(this.method="next",this.next=o.finallyLoc,v):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),v},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),_(n),v}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;_(n)}return i}}throw Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:x(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),v}},t}function wt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Ot(r.key),r)}}function Ot(e){var t=function(e,t){if("object"!=gt(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=gt(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==gt(t)?t:t+""}function Pt(e,t,n){return t=jt(t),function(e,t){if(t&&("object"===gt(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,St()?Reflect.construct(t,n||[],jt(e).constructor):t.apply(e,n))}function St(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(St=function(){return!!e})()}function kt(){return kt="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=jt(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},kt.apply(this,arguments)}function jt(e){return jt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},jt(e)}function Ct(e,t){return Ct=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Ct(e,t)}!function(e){e.Update="update",e.Volume="volume",e.Playing="playing",e.Paused="paused",e.NewChapter="new_chapter",e.Stopped="stopped",e.Ready="ready",e.Mute="mute",e.Finished="finished",e.Subtitles="subtitles"}(vt||(vt={}));var Tt=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},Et=function(e){function t(e,n){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=Pt(this,t)).client=e,r.localState=new bt(n.title,n.device),r.bindFunctions(),r.initialize(),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Ct(e,t)}(t,e),n=t,(r=[{key:"bindFunctions",value:function(){this.initialize=this.initialize.bind(this),this.dispose=this.dispose.bind(this),this.handleClientConnected=this.handleClientConnected.bind(this),this.handleDisconnectMessage=this.handleDisconnectMessage.bind(this),this.handleAllVideoMessages=this.handleAllVideoMessages.bind(this),this.handleUpdateMessage=this.handleUpdateMessage.bind(this),this.handleVolumeMessage=this.handleVolumeMessage.bind(this),this.handlePlayingMessage=this.handlePlayingMessage.bind(this),this.handlePausedMessage=this.handlePausedMessage.bind(this),this.handleFinishedMessage=this.handleFinishedMessage.bind(this),this.handleNewChapterMessage=this.handleNewChapterMessage.bind(this),this.handleStoppedMessage=this.handleStoppedMessage.bind(this),this.loadSource=this.loadSource.bind(this),this.play=this.play.bind(this),this.pause=this.pause.bind(this),this.seek=this.seek.bind(this),this.setVolume=this.setVolume.bind(this),this.isPlaying=this.isPlaying.bind(this),this.getPosition=this.getPosition.bind(this),this.getDuration=this.getDuration.bind(this),this.getVolume=this.getVolume.bind(this)}},{key:"initialize",value:function(){var e=this;this.client.on("dispose",this.dispose),this.client.on("connected",this.handleClientConnected),this.client.on("message",this.handleDisconnectMessage).filter((function(t){return t.source===e.getDevice().id&&"disconnect"===t.message.type})),this.client.on("message",this.handleAllVideoMessages).filter((function(t){return t.source===e.getDevice().id&&"video_event"===t.message.type}))}},{key:"dispose",value:function(){this.client.off("dispose",this.dispose),this.client.off("connected",this.handleClientConnected),this.client.off("message",this.handleDisconnectMessage),this.client.off("message",this.handleAllVideoMessages),this.client.stop(this.getDevice().id).catch((function(e){return console.error(e)})),kt(jt(t.prototype),"dispose",this).call(this)}},{key:"handleClientConnected",value:function(){return Tt(this,void 0,void 0,mt().mark((function e(){return mt().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,this.client.joinRoom(this.getDevice().id);case 3:e.next=8;break;case 5:e.prev=5,e.t0=e.catch(0),this.trigger("error",e.t0);case 8:case"end":return e.stop()}}),e,this,[[0,5]])})))}},{key:"handleDisconnectMessage",value:function(){this.dispose()}},{key:"handleAllVideoMessages",value:function(e){var t=this.localState.debounced,n=e.message.payload.params||{};switch(e.message.payload.event){case vt.Update:this.handleUpdateMessage(t,n);break;case vt.NewChapter:this.handleNewChapterMessage(t,n);break;case vt.Volume:this.handleVolumeMessage(t,n);break;case vt.Playing:this.handlePlayingMessage(t);break;case vt.Paused:this.handlePausedMessage(t);break;case vt.Finished:this.handleFinishedMessage(t);break;case vt.Stopped:this.handleStoppedMessage()}}},{key:"handleUpdateMessage",value:function(e,t){e.duration!==t.duration&&(e.duration=t.duration,this.trigger("durationchange",rt.j.void)),e.position!==t.position&&(e.position=t.position,this.trigger("positionchange",rt.j.void)),e.subtitles!==t.subtitles&&(e.subtitles=t.subtitles,this.trigger("subtitleschange",rt.j.void))}},{key:"handleVolumeMessage",value:function(e,t){e.volume!==t.level&&(e.volume=t.level,e.mute=0===t.level,this.trigger("volumechange",rt.j.void))}},{key:"handlePlayingMessage",value:function(e){!0!==e.playing&&(e.playing=!0,e.playbackFinished=!1,this.trigger("playingchange",rt.j.void))}},{key:"handlePausedMessage",value:function(e){!1!==e.playing&&(e.playing=!1,this.trigger("playingchange",rt.j.void))}},{key:"handleFinishedMessage",value:function(e){!0!==e.playbackFinished&&(e.playing=!1,e.playbackFinished=!0,this.trigger("playingchange",rt.j.void))}},{key:"handleNewChapterMessage",value:function(e,t){var n,r=(null!==(n=t.queue)&&void 0!==n?n:[]).find((function(t){return t.url===e.videoSource}));if(!r)return console.info("The device is no longer playing the source we loaded - disposing the session"),void this.dispose();e.subtitleSource!==r.suburl&&(e.subtitleSource=r.suburl,this.trigger("subtitleschange",rt.j.void))}},{key:"handleStoppedMessage",value:function(){this.dispose()}},{key:"loadSource",value:function(e,t){return Tt(this,void 0,void 0,mt().mark((function n(){var r,i;return mt().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(this.localState.videoSource!==e||this.localState.subtitleSource!==t){n.next=2;break}return n.abrupt("return");case 2:return n.prev=2,r=this.getDevice().id,i=this.getPosition(),this.localState.videoSource=e,this.localState.subtitleSource=t,this.localState.ready=!1,n.next=10,this.client.joinRoom(r);case 10:return n.next=12,this.client.loadQueue({title:this.getTitle(),roomId:r,videoSource:e,subtitleSource:t});case 12:this.localState.ready=!0,this.trigger("sourceloaded",rt.j.void),i>0&&this.seek(i),t&&this.setSubtitles(t),n.next=22;break;case 18:n.prev=18,n.t0=n.catch(2),console.error(n.t0),this.trigger("error",new Error("Could not load video on Vivi device"));case 22:case"end":return n.stop()}}),n,this,[[2,18]])})))}},{key:"play",value:function(){this.localState.ready&&!0!==this.localState.playing&&(this.localState.playing=!0,this.client.play(this.getDevice().id),this.trigger("playingchange",rt.j.void))}},{key:"pause",value:function(){this.localState.ready&&!1!==this.localState.playing&&(this.localState.playing=!1,this.client.pause(this.getDevice().id),this.trigger("playingchange",rt.j.void))}},{key:"seek",value:function(e){this.localState.ready&&this.localState.position!==e&&(this.localState.position=e,this.client.seek(this.getDevice().id,e),this.trigger("positionchange",rt.j.void))}},{key:"setVolume",value:function(e){this.localState.ready&&this.localState.volume!==e&&(this.localState.volume=e,this.client.setVolume(this.getDevice().id,e),this.trigger("volumechange",rt.j.void))}},{key:"setMuted",value:function(e){this.localState.ready&&this.localState.mute!==e&&(this.localState.mute=e,this.client.setMuted(this.getDevice().id,e),this.trigger("volumechange",rt.j.void))}},{key:"setSubtitles",value:function(e){return Tt(this,void 0,void 0,mt().mark((function t(){var n;return mt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(this.localState.ready){t.next=2;break}return t.abrupt("return");case 2:if(!e){t.next=5;break}return t.next=5,this.loadSource(this.localState.videoSource,e);case 5:n=!!e,this.localState.subtitles!==n&&(this.localState.subtitles=n,this.client.setSubtitles(this.getDevice().id,n),this.trigger("subtitleschange",rt.j.void));case 7:case"end":return t.stop()}}),t,this)})))}},{key:"isPlaying",value:function(){return this.localState.playing}},{key:"isPlaybackFinished",value:function(){return this.localState.playbackFinished}},{key:"getPosition",value:function(){return this.localState.position}},{key:"getDuration",value:function(){return this.localState.duration}},{key:"getVolume",value:function(){return this.localState.volume}},{key:"getMuted",value:function(){return this.localState.mute}},{key:"getSubtitles",value:function(){if(this.localState.subtitles)return this.localState.subtitleSource}},{key:"getDevice",value:function(){return this.localState.device}},{key:"getTitle",value:function(){return this.localState.title}}])&&wt(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(rt.N);function _t(e){return _t="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},_t(e)}function It(){It=function(){return t};var e,t={},n=Object.prototype,r=n.hasOwnProperty,i=Object.defineProperty||function(e,t,n){e[t]=n.value},o="function"==typeof Symbol?Symbol:{},a=o.iterator||"@@iterator",s=o.asyncIterator||"@@asyncIterator",u=o.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(e){c=function(e,t,n){return e[t]=n}}function l(e,t,n,r){var o=t&&t.prototype instanceof b?t:b,a=Object.create(o.prototype),s=new I(r||[]);return i(a,"_invoke",{value:C(e,n,s)}),a}function f(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}t.wrap=l;var p="suspendedStart",h="suspendedYield",y="executing",d="completed",v={};function b(){}function g(){}function m(){}var w={};c(w,a,(function(){return this}));var O=Object.getPrototypeOf,P=O&&O(O(x([])));P&&P!==n&&r.call(P,a)&&(w=P);var S=m.prototype=b.prototype=Object.create(w);function k(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function j(e,t){function n(i,o,a,s){var u=f(e[i],e,o);if("throw"!==u.type){var c=u.arg,l=c.value;return l&&"object"==_t(l)&&r.call(l,"__await")?t.resolve(l.__await).then((function(e){n("next",e,a,s)}),(function(e){n("throw",e,a,s)})):t.resolve(l).then((function(e){c.value=e,a(c)}),(function(e){return n("throw",e,a,s)}))}s(u.arg)}var o;i(this,"_invoke",{value:function(e,r){function i(){return new t((function(t,i){n(e,r,t,i)}))}return o=o?o.then(i,i):i()}})}function C(t,n,r){var i=p;return function(o,a){if(i===y)throw Error("Generator is already running");if(i===d){if("throw"===o)throw a;return{value:e,done:!0}}for(r.method=o,r.arg=a;;){var s=r.delegate;if(s){var u=T(s,r);if(u){if(u===v)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(i===p)throw i=d,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);i=y;var c=f(t,n,r);if("normal"===c.type){if(i=r.done?d:h,c.arg===v)continue;return{value:c.arg,done:r.done}}"throw"===c.type&&(i=d,r.method="throw",r.arg=c.arg)}}}function T(t,n){var r=n.method,i=t.iterator[r];if(i===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,T(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),v;var o=f(i,t.iterator,n.arg);if("throw"===o.type)return n.method="throw",n.arg=o.arg,n.delegate=null,v;var a=o.arg;return a?a.done?(n[t.resultName]=a.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,v):a:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,v)}function E(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function _(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function I(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(E,this),this.reset(!0)}function x(t){if(t||""===t){var n=t[a];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var i=-1,o=function n(){for(;++i<t.length;)if(r.call(t,i))return n.value=t[i],n.done=!1,n;return n.value=e,n.done=!0,n};return o.next=o}}throw new TypeError(_t(t)+" is not iterable")}return g.prototype=m,i(S,"constructor",{value:m,configurable:!0}),i(m,"constructor",{value:g,configurable:!0}),g.displayName=c(m,u,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===g||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,m):(e.__proto__=m,c(e,u,"GeneratorFunction")),e.prototype=Object.create(S),e},t.awrap=function(e){return{__await:e}},k(j.prototype),c(j.prototype,s,(function(){return this})),t.AsyncIterator=j,t.async=function(e,n,r,i,o){void 0===o&&(o=Promise);var a=new j(l(e,n,r,i),o);return t.isGeneratorFunction(n)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},k(S),c(S,u,"Generator"),c(S,a,(function(){return this})),c(S,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},t.values=x,I.prototype={constructor:I,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(_),!t)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function i(r,i){return s.type="throw",s.arg=t,n.next=r,i&&(n.method="next",n.arg=e),!!i}for(var o=this.tryEntries.length-1;o>=0;--o){var a=this.tryEntries[o],s=a.completion;if("root"===a.tryLoc)return i("end");if(a.tryLoc<=this.prev){var u=r.call(a,"catchLoc"),c=r.call(a,"finallyLoc");if(u&&c){if(this.prev<a.catchLoc)return i(a.catchLoc,!0);if(this.prev<a.finallyLoc)return i(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return i(a.catchLoc,!0)}else{if(!c)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return i(a.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(i.tryLoc<=this.prev&&r.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var o=i;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var a=o?o.completion:{};return a.type=e,a.arg=t,o?(this.method="next",this.next=o.finallyLoc,v):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),v},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),_(n),v}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;_(n)}return i}}throw Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:x(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),v}},t}function xt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Rt(r.key),r)}}function Rt(e){var t=function(e,t){if("object"!=_t(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=_t(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==_t(t)?t:t+""}function Mt(e,t,n){return t=Nt(t),function(e,t){if(t&&("object"===_t(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,Lt()?Reflect.construct(t,n||[],Nt(e).constructor):t.apply(e,n))}function Lt(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(Lt=function(){return!!e})()}function Dt(){return Dt="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Nt(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},Dt.apply(this,arguments)}function Nt(e){return Nt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Nt(e)}function Bt(e,t){return Bt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Bt(e,t)}var Vt=function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function a(e){try{u(r.next(e))}catch(e){o(e)}}function s(e){try{u(r.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}u((r=r.apply(e,t||[])).next())}))},At=1e4,Ft=function(e){function t(e){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(n=Mt(this,t)).options=e,n.accessToken="",n.devices=[],n.devicesFingerprint="",n.deviceDiscovery=new it.b,n.bindFunctions(),n.initialize(),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Bt(e,t)}(t,e),n=t,i=[{key:"createAckId",value:function(){return ft()}},{key:"calculateFingerprint",value:function(e){return e.map((function(e){return e.id})).sort().join(",")}}],(r=[{key:"bindFunctions",value:function(){this.initialize=this.initialize.bind(this),this.sendMessage=this.sendMessage.bind(this),this.sendMessageDebounced=(0,lt.Ds)(this.sendMessage,500,!0),this.beginDeviceDiscovery=this.beginDeviceDiscovery.bind(this),this.dispose=this.dispose.bind(this),this.canCastToDevice=this.canCastToDevice.bind(this),this.getDevices=this.getDevices.bind(this),this.startCastSession=this.startCastSession.bind(this),this.authenticateWithVivi=this.authenticateWithVivi.bind(this),this.getRoomList=this.getRoomList.bind(this),this.joinRoom=this.joinRoom.bind(this),this.query=this.query.bind(this),this.loadQueue=this.loadQueue.bind(this),this.play=this.play.bind(this),this.pause=this.pause.bind(this),this.stop=this.stop.bind(this),this.seek=this.seek.bind(this),this.setVolume=this.setVolume.bind(this),this.setMuted=this.setMuted.bind(this),this.setSubtitles=this.setSubtitles.bind(this)}},{key:"initialize",value:function(){var e=this;this.webSocket=new ct(this.options.url.toString()),this.webSocket.onMessage=function(t){return e.trigger("message",JSON.parse(t.data))},this.webSocket.onOpen=function(){return Vt(e,void 0,void 0,It().mark((function e(){return It().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,this.options.fetchAccessToken();case 3:return this.accessToken=e.sent,e.next=6,this.authenticateWithVivi();case 6:this.beginDeviceDiscovery(),this.trigger("connected",rt.j.void),e.next=14;break;case 10:e.prev=10,e.t0=e.catch(0),console.error(e.t0),this.trigger("error",new Error("Could not connect to Vivi"));case 14:case"end":return e.stop()}}),e,this,[[0,10]])})))}}},{key:"sendMessage",value:function(e){var t;null===(t=this.webSocket)||void 0===t||t.send(JSON.stringify(e))}},{key:"beginDeviceDiscovery",value:function(){var e=this;this.deviceDiscovery.every(1e4).schedule((function(){return Vt(e,void 0,void 0,It().mark((function e(){var n,r;return It().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,this.getRoomList();case 3:if(n=e.sent,(r=t.calculateFingerprint(n))!==this.devicesFingerprint){e.next=7;break}return e.abrupt("return");case 7:this.devices=n.map((function(e){return{id:e.id,name:e.name,type:nt.Y.Vivi,status:nt.L.Available}})),this.devicesFingerprint=r,this.trigger("deviceschange",rt.j.void),e.next=15;break;case 12:e.prev=12,e.t0=e.catch(0),console.warn(e.t0);case 15:case"end":return e.stop()}}),e,this,[[0,12]])})))})).trigger().start()}},{key:"dispose",value:function(){var e;this.deviceDiscovery.stop(),null===(e=this.webSocket)||void 0===e||e.dipose(),Dt(Nt(t.prototype),"dispose",this).call(this)}},{key:"canCastToDevice",value:function(e){return e===nt.Y.Vivi}},{key:"getDevices",value:function(){return this.devices}},{key:"startCastSession",value:function(e){return new Et(this,e)}},{key:"authenticateWithVivi",value:function(){return Vt(this,void 0,void 0,It().mark((function e(){return It().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return this.sendMessage({destination:"relay",message:{token:this.accessToken,type:"identify_video_api"}}),e.next=3,this.one("message",(function(e){return"video_api_identified"===e.message.type})).timeout(At).catch((function(){throw new Error("Failed to authenticate with Vivi")}));case 3:case"end":return e.stop()}}),e,this)})))}},{key:"getRoomList",value:function(){return Vt(this,void 0,void 0,It().mark((function e(){var t;return It().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return this.sendMessage({destination:"relay",message:{type:"video_api_rooms"}}),e.next=3,this.one("message",(function(e){return"video_api_rooms"===e.message.type})).timeout(At).catch((function(){throw new Error("Failed to fetch rooms")}));case 3:return t=e.sent,e.abrupt("return",t.message.rooms||[]);case 5:case"end":return e.stop()}}),e,this)})))}},{key:"joinRoom",value:function(e){return Vt(this,void 0,void 0,It().mark((function t(){return It().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return this.sendMessage({destination:"relay",message:{destination_type:"box",new_destination:e,token:this.accessToken,type:"connect"}}),t.next=3,this.one("message",(function(t){return t.source===e&&"connect"===t.message.type||"error"===t.message.type&&"already_connected"===t.message.error_type||void 0})).timeout(At).catch((function(){throw new Error("Failed to join room")}));case 3:case"end":return t.stop()}}),t,this)})))}},{key:"query",value:function(e){return Vt(this,void 0,void 0,It().mark((function n(){var r;return It().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return r=t.createAckId(),this.sendMessage({destination:e,message:{type:"message_with_ack",ack_id:r,name:"query"}}),n.next=4,this.one("message",(function(e){return e.message.ack_id===r})).timeout(At).catch((function(){throw new Error("Failed to fetch query")}));case 4:return n.abrupt("return",n.sent);case 5:case"end":return n.stop()}}),n,this)})))}},{key:"loadQueue",value:function(e){var n=e.roomId,r=e.title,i=e.videoSource,o=e.subtitleSource;return Vt(this,void 0,void 0,It().mark((function e(){return It().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return this.sendMessage({destination:n,message:{type:"message_with_ack",ack_id:t.createAckId(),name:"queue_load",payload:{urls:[{title:r,url:i,suburl:o}]}}}),e.next=3,this.one("message",(function(e){var t;return e.source===n&&"ready"===(null===(t=e.message.payload)||void 0===t?void 0:t.event)})).timeout(At).catch((function(){throw new Error("Failed to load media")}));case 3:case"end":return e.stop()}}),e,this)})))}},{key:"play",value:function(e){return Vt(this,void 0,void 0,It().mark((function t(){return It().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return this.sendMessage({destination:e,message:{type:"message",name:"video_play",payload:{}}}),t.next=3,this.one("message",(function(t){var n;return t.source===e&&"playing"===(null===(n=t.message.payload)||void 0===n?void 0:n.event)})).timeout(At).catch((function(){throw new Error("Failed to play video")}));case 3:case"end":return t.stop()}}),t,this)})))}},{key:"pause",value:function(e){return Vt(this,void 0,void 0,It().mark((function t(){return It().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return this.sendMessage({destination:e,message:{type:"message",name:"video_pause"}}),t.next=3,this.one("message",(function(t){var n;return t.source===e&&"paused"===(null===(n=t.message.payload)||void 0===n?void 0:n.event)})).timeout(At).catch((function(){throw new Error("Failed to pause video")}));case 3:case"end":return t.stop()}}),t,this)})))}},{key:"stop",value:function(e){return Vt(this,void 0,void 0,It().mark((function t(){return It().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return this.sendMessage({destination:e,message:{type:"message",name:"video_stop"}}),t.next=3,this.one("message",(function(t){var n;return t.source===e&&"stopped"===(null===(n=t.message.payload)||void 0===n?void 0:n.event)})).timeout(At).catch((function(){throw new Error("Failed to stop video")}));case 3:case"end":return t.stop()}}),t,this)})))}},{key:"seek",value:function(e,t){return Vt(this,void 0,void 0,It().mark((function n(){return It().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(!this.sendMessageDebounced({destination:e,message:{type:"message",name:"video_seek",payload:{position:t}}})){n.next=4;break}return n.next=4,this.one("message",(function(t){var n;return t.source===e&&"playing"===(null===(n=t.message.payload)||void 0===n?void 0:n.event)})).timeout(At).catch((function(){throw new Error("Failed to seek video")}));case 4:case"end":return n.stop()}}),n,this)})))}},{key:"setVolume",value:function(e,t){return Vt(this,void 0,void 0,It().mark((function n(){return It().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(!this.sendMessageDebounced({destination:e,message:{type:"message",name:"set_volume",payload:{volume:t}}})){n.next=4;break}return n.next=4,this.one("message",(function(t){var n;return t.source===e&&"volume"===(null===(n=t.message.payload)||void 0===n?void 0:n.event)})).timeout(At).catch((function(){throw new Error("Failed to set volume")}));case 4:case"end":return n.stop()}}),n,this)})))}},{key:"setMuted",value:function(e,t){return Vt(this,void 0,void 0,It().mark((function n(){return It().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return this.sendMessage({destination:e,message:{type:"message",name:"set_mute",payload:{mute:t}}}),n.next=3,this.one("message",(function(t){var n;return t.source===e&&"mute"===(null===(n=t.message.payload)||void 0===n?void 0:n.event)})).timeout(At).catch((function(){throw new Error("Failed to set mute")}));case 3:case"end":return n.stop()}}),n,this)})))}},{key:"setSubtitles",value:function(e,n){return Vt(this,void 0,void 0,It().mark((function r(){var i;return It().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return i=t.createAckId(),this.sendMessage({destination:e,message:{type:"message_with_ack",ack_id:i,name:"set_subtitles",payload:{subtitles:n}}}),r.next=4,this.one("message",(function(t){var n;return t.source===e&&"subtitles"===(null===(n=t.message.payload)||void 0===n?void 0:n.event)})).timeout(At).catch((function(){throw new Error("Failed to set subtitles")}));case 4:case"end":return r.stop()}}),r,this)})))}}])&&xt(n.prototype,r),i&&xt(n,i),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r,i}(rt.N);function Ut(e){return Ut="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},Ut(e)}function Zt(e){return function(e){if(Array.isArray(e))return zt(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 zt(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)?zt(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.")}()}function zt(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 Gt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,qt(r.key),r)}}function qt(e){var t=function(e,t){if("object"!=Ut(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=Ut(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Ut(t)?t:t+""}function Ht(e,t,n){return t=$t(t),function(e,t){if(t&&("object"===Ut(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,Yt()?Reflect.construct(t,n||[],$t(e).constructor):t.apply(e,n))}function Yt(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(Yt=function(){return!!e})()}function Wt(){return Wt="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=$t(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},Wt.apply(this,arguments)}function $t(e){return $t=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},$t(e)}function Qt(e,t){return Qt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Qt(e,t)}var Xt=function(e){function t(e){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(n=Ht(this,t)).instanceId=e,n.clients=[],n.bindFunctions(),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Qt(e,t)}(t,e),n=t,i=[{key:"getOrCreateInstance",value:function(e){if(!e)throw new Error("instanceId is required");return this.instances[e]||(this.instances[e]=new t(e)),this.instances[e]}},{key:"disposeAndRemoveInstance",value:function(e){e.dispose(),delete this.instances[e.instanceId]}},{key:"isActive",value:function(){return Object.keys(this.instances).length>0}}],(r=[{key:"bindFunctions",value:function(){this.addClient=this.addClient.bind(this),this.hasInstanceOfClient=this.hasInstanceOfClient.bind(this),this.startCastSession=this.startCastSession.bind(this),this.gatherAndPublishDevices=this.gatherAndPublishDevices.bind(this),this.dispose=this.dispose.bind(this)}},{key:"addClient",value:function(e){var t=this;e.on("deviceschange",this.gatherAndPublishDevices),e.on("error",(function(e){return t.trigger("error",e)})),this.clients.push(e)}},{key:"hasInstanceOfClient",value:function(e){return this.clients.some((function(t){return t instanceof e}))}},{key:"startCastSession",value:function(e){var t=this;if(this.castSession){if(this.castSession.getDevice().id===e.device.id)return void console.info("A session with device ".concat(e.device.id," already exists - this is a no-op"));this.castSession.dispose()}var n=this.clients.find((function(t){return t.canCastToDevice(e.device.type)}));n&&(this.castSession=n.startCastSession(e),this.castSession.on("error",(function(e){t.castSession.dispose(),t.trigger("error",e)})),this.castSession.on("dispose",(function(){t.castSession=void 0,t.trigger("castsessionchange",void 0)})),this.trigger("castsessionchange",this.castSession))}},{key:"getCastSession",value:function(){return this.castSession}},{key:"gatherAndPublishDevices",value:function(){var e=this.clients.map((function(e){return e.getDevices()})).reduce((function(e,t){return[].concat(Zt(e),Zt(t))}),[]);this.trigger("deviceschange",e)}},{key:"dispose",value:function(){var e;null===(e=this.castSession)||void 0===e||e.dispose(),this.clients.forEach((function(e){return e.dispose()})),this.castSession=void 0,this.clients=[],Wt($t(t.prototype),"dispose",this).call(this)}}])&&Gt(n.prototype,r),i&&Gt(n,i),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r,i}(rt.N);Xt.instances={};var Jt=n(30050),Kt=n(98115);function en(e){return en="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},en(e)}function tn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,nn(r.key),r)}}function nn(e){var t=function(e,t){if("object"!=en(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=en(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==en(t)?t:t+""}function rn(e,t,n){return t=sn(t),function(e,t){if(t&&("object"===en(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,on()?Reflect.construct(t,n||[],sn(e).constructor):t.apply(e,n))}function on(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(on=function(){return!!e})()}function an(){return an="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=sn(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},an.apply(this,arguments)}function sn(e){return sn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},sn(e)}function un(e,t){return un=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},un(e,t)}var cn=function(e){function t(e,n){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=rn(this,t,[e,n])).isVisible=r.isVisible.bind(r),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&un(e,t)}(t,e),n=t,(r=[{key:"createEl",value:function(){return an(sn(t.prototype),"createEl",this).call(this,"li",{className:"vjs-menu-item cv-device-menu-item",innerHTML:'\n <span class="cv-device-icon '.concat({vivi:"cv-vivi-icon","apple-tv":"cv-apple-icon"}[this.options_.type],'"></span>\n <span class="vjs-menu-item-text">').concat(this.options_.label,"</span>\n ")})}},{key:"handleClick",value:function(){this.options_.onClick()}},{key:"show",value:function(){an(sn(t.prototype),"show",this).call(this)}},{key:"hide",value:function(){an(sn(t.prototype),"hide",this).call(this)}},{key:"isVisible",value:function(){return!an(sn(t.prototype),"hasClass",this).call(this,"vjs-hidden")}}])&&tn(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getComponent("MenuItem"));function ln(e){return ln="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},ln(e)}function fn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,pn(r.key),r)}}function pn(e){var t=function(e,t){if("object"!=ln(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=ln(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==ln(t)?t:t+""}function hn(e,t,n){return t=vn(t),function(e,t){if(t&&("object"===ln(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,yn()?Reflect.construct(t,n||[],vn(e).constructor):t.apply(e,n))}function yn(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(yn=function(){return!!e})()}function dn(){return dn="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=vn(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},dn.apply(this,arguments)}function vn(e){return vn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},vn(e)}function bn(e,t){return bn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},bn(e,t)}var gn=o.Z.getComponent("MenuButton"),mn=function(e){function t(e,n){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=hn(this,t,[e,n])).alwaysCollapsed=!1,r.isCollapsed=!1,r.isCollabsible=!0,r.className="cv-devices-menu-button",r.searchText="",r.devices=[],r.castSession=void 0,r.bindFunctions(),r.bindEventListeners(),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&bn(e,t)}(t,e),n=t,r=[{key:"bindFunctions",value:function(){this.bindEventListeners=this.bindEventListeners.bind(this),this.setDevices=this.setDevices.bind(this),this.setCastSession=this.setCastSession.bind(this),this.setSearchText=this.setSearchText.bind(this),this.getDeviceMenuItems=this.getDeviceMenuItems.bind(this),this.render=this.render.bind(this),this.removeMenuItems=this.removeMenuItems.bind(this),this.addMenuItemsForDevices=this.addMenuItemsForDevices.bind(this),this.shouldShowSearchInput=this.shouldShowSearchInput.bind(this),this.toggleSearchInput=this.toggleSearchInput.bind(this),this.toggleDeviceMenuItems=this.toggleDeviceMenuItems.bind(this),this.toggleEmptyStatePlaceholder=this.toggleEmptyStatePlaceholder.bind(this)}},{key:"bindEventListeners",value:function(){var e=this,t=this.$("button"),n=function(t){e.menu.handleBlur(t)};t.addEventListener("blur",n),this.one("dispose",(function(){t.removeEventListener("blur",n)}))}},{key:"createEl",value:function(){for(var e,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return(e=gn.prototype.createEl).apply.apply(e,[this].concat(n))}},{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small cv-devices-button ".concat(dn(vn(t.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"createItems",value:function(){var e=this,t=[];return this.headingItem=new Jt.Z(this.player_,{label:this.localize("Select a device"),selectable:!1}),this.searchInputItem=new Kt.Z(this.player_,{menuButton:this,search:function(t){return e.setSearchText(t)},className:"cv-devices-search-input"}),this.emptyPlaceholder=new Kt.C(this.player_,{label:"No devices found",selected:!1,selectable:!1,multiSelectable:!1}),this.headingItem.show(),this.searchInputItem.hide(),this.emptyPlaceholder.show(),t.push(this.headingItem,this.searchInputItem,this.emptyPlaceholder),t}},{key:"pressButton",value:function(){var e;dn(vn(t.prototype),"pressButton",this).call(this),this.shouldShowSearchInput()&&(null===(e=this.searchInputItem)||void 0===e||e.focus())}},{key:"setDevices",value:function(e){this.devices=e,this.render()}},{key:"setCastSession",value:function(e){this.castSession=e,this.render()}},{key:"setSearchText",value:function(e){this.searchText=e,this.render()}},{key:"getDeviceMenuItems",value:function(){return this.menu.children_.filter((function(e){return e instanceof cn}))}},{key:"render",value:function(){this.removeMenuItems(this.getDeviceMenuItems()),this.addMenuItemsForDevices(this.devices),this.toggleSearchInput(),this.toggleDeviceMenuItems(),this.toggleEmptyStatePlaceholder()}},{key:"removeMenuItems",value:function(e){var t=this;e.forEach((function(e){t.menu.removeChild(e),e.dispose()}))}},{key:"addMenuItemsForDevices",value:function(e){var t=this;e.sort((function(e,t){return"".concat(e.type,"-").concat(e.name).localeCompare("".concat(t.type,"-").concat(t.name))})).forEach((function(e){var n=new cn(t.player(),{id:e.id,label:e.name,selected:!1,multiSelectable:!1,selectable:!0,available:e.status===nt.L.Available,type:e.type,onClick:function(){t.options_.onDeviceMenuItemClick(n,e)}});t.menu.addItem(n)}))}},{key:"shouldShowSearchInput",value:function(){return this.getDeviceMenuItems().length>=20}},{key:"toggleSearchInput",value:function(){this.shouldShowSearchInput()?(this.searchInputItem.show(),this.menu.addClass("vertical-fill")):(this.searchInputItem.hide(),this.menu.removeClass("vertical-fill"))}},{key:"toggleDeviceMenuItems",value:function(){var e=this,t=this.getDeviceMenuItems(),n=this.shouldShowSearchInput(),r=this.searchText.toLowerCase();t.forEach((function(t){var i,o=e.devices.find((function(e){return e.id===t.options_.id}));if(o){var a=o.status===nt.L.Available,s=!n||-1!==o.name.toLowerCase().indexOf(r),u=o.id===(null===(i=e.castSession)||void 0===i?void 0:i.getDevice().id);a?t.enable():t.disable(),s?t.show():t.hide(),u?t.selected(!0):t.selected(!1)}}))}},{key:"toggleEmptyStatePlaceholder",value:function(){var e=this.getDeviceMenuItems();e.filter((function(e){return e.isVisible()})).length?this.emptyPlaceholder.hide():this.emptyPlaceholder.show(),e.length?this.emptyPlaceholder.setLabel(this.localize("No matching results")):this.emptyPlaceholder.setLabel(this.localize("No devices found"))}},{key:"getCollabsibleName",value:function(){return this.controlText_}},{key:"getCollabsibleValue",value:function(){var e,t;return null!==(t=null===(e=this.castSession)||void 0===e?void 0:e.getDevice().name)&&void 0!==t?t:" "}},{key:"showInCollabsibleMenu",value:function(){return!0}},{key:"showCollapsibleMenu",value:function(){this.handleClick()}},{key:"handleClick",value:function(){dn(vn(t.prototype),"handleClick",this).call(this,null),this.options_.onClick()}}],r&&fn(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(gn);mn.prototype.controlText_="Devices",o.Z.registerComponent("DevicesButton",mn);var wn=n(10463);function On(e){return On="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},On(e)}function Pn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Sn(r.key),r)}}function Sn(e){var t=function(e,t){if("object"!=On(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=On(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==On(t)?t:t+""}function kn(e,t,n){return t=Tn(t),function(e,t){if(t&&("object"===On(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,jn()?Reflect.construct(t,n||[],Tn(e).constructor):t.apply(e,n))}function jn(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(jn=function(){return!!e})()}function Cn(){return Cn="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Tn(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},Cn.apply(this,arguments)}function Tn(e){return Tn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Tn(e)}function En(e,t){return En=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},En(e,t)}var _n=function(e){function t(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),kn(this,t,[null,e])}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&En(e,t)}(t,e),n=t,(r=[{key:"createEl",value:function(){return Cn(Tn(t.prototype),"createEl",this).call(this,"div",{className:"cv-devices-tech"})}},{key:"setPoster",value:function(e){this.poster=e,this.update()}},{key:"setDevice",value:function(e){this.device=e,this.update()}},{key:"update",value:function(){var e,t,n,r,i=this;this.el_.innerHTML='\n <div class="cv-devices-content">\n <p>'.concat(this.localize("Currently playing on"),'</p>\n <h2><span class="cv-device-icon ').concat({vivi:"cv-vivi-icon","apple-tv":"cv-apple-icon"}[null!==(t=null===(e=this.device)||void 0===e?void 0:e.type)&&void 0!==t?t:nt.Y.Vivi],'"></span>').concat(null!==(r=null===(n=this.device)||void 0===n?void 0:n.name)&&void 0!==r?r:"",'</h2>\n </div>\n <div class="cv-devices-background" style="background-image: url(').concat(this.poster,')"></div>\n ');var o=document.createElement("button"),a=function(e){e.stopPropagation(),i.options_.onStopCasting()};o.onclick=a,o.ontouchstart=a,o.className="stop-casting-button",o.innerHTML=this.localize("Stop casting"),this.el_.querySelector(".cv-devices-content").appendChild(o)}},{key:"play",value:function(){}}])&&Pn(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getComponent("Component"));function In(e){return In="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},In(e)}function xn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Rn(r.key),r)}}function Rn(e){var t=function(e,t){if("object"!=In(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=In(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==In(t)?t:t+""}function Mn(e,t,n){return t=Nn(t),function(e,t){if(t&&("object"===In(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,Ln()?Reflect.construct(t,n||[],Nn(e).constructor):t.apply(e,n))}function Ln(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(Ln=function(){return!!e})()}function Dn(){return Dn="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Nn(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},Dn.apply(this,arguments)}function Nn(e){return Nn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Nn(e)}function Bn(e,t){return Bn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Bn(e,t)}var Vn=function(e){function t(e,n){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=Mn(this,t,[e,n])).featuresVolumeControl=!0,r.featuresPlaybackRate=!1,r.movingMediaElementInDOM=!1,r.featuresFullscreenResize=!0,r.featuresTimeupdateEvents=!0,r.featuresProgressEvents=!1,r.featuresNativeTextTracks=!1,r.featuresNativeAudioTracks=!1,r.featuresNativeVideoTracks=!1,r.featuresMuteControl=!0,r.featuresSourceset=!1,r.videojsPlayer=(0,o.Z)(r.options_.playerId),r.bindFunctions(),r.bindEventListeners(),r.ready((function(){r.setSource(r.options_.source)})),r.triggerReady(),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Bn(e,t)}(t,e),n=t,i=[{key:"canPlayType",value:function(){return""}},{key:"canPlaySource",value:function(e,t){var n;return!!Xt.getOrCreateInstance(null!==(n=null==t?void 0:t.instanceId)&&void 0!==n?n:"").getCastSession()}},{key:"isSupported",value:function(){return Xt.isActive()}}],(r=[{key:"bindFunctions",value:function(){this.bindEventListeners=this.bindEventListeners.bind(this),this.onTextTrackChanged=this.onTextTrackChanged.bind(this),this.getSelectedTextTrack=this.getSelectedTextTrack.bind(this),this.setSelectedTextTrack=this.setSelectedTextTrack.bind(this),this.showUI=this.showUI.bind(this),this.hideUI=this.hideUI.bind(this),this.dispose=this.dispose.bind(this),this.setSource=this.setSource.bind(this),this.getCastSession=this.getCastSession.bind(this)}},{key:"bindEventListeners",value:function(){var e=this,t=this.getCastSession();t&&(this.textTracks().on("change",this.onTextTrackChanged),this.videojsPlayer.one("ended",(function(){t.dispose()})),t.on("durationchange",(function(){e.trigger("durationchange")})),t.on("dispose",(function(){e.trigger("ended"),e.hideUI()})),t.on("playingchange",(function(){t.isPlaying()?(e.trigger("play"),e.trigger("playing")):e.trigger("pause")})),t.on("volumechange",(function(){e.trigger("volumechange")})),t.on("sourceloaded",(function(){e.trigger("loadeddata")})),t.on("subtitleschange",(function(){e.setSelectedTextTrack(t.getSubtitles())})))}},{key:"onTextTrackChanged",value:function(){var e,t=this.getSelectedTextTrack();null===(e=this.getCastSession())||void 0===e||e.setSubtitles(null==t?void 0:t.src)}},{key:"getSelectedTextTrack",value:function(){return wn.O.findTrackByPredicate(this.videojsPlayer.player_,(function(e){return"showing"===e.mode&&!!e.src}))}},{key:"setSelectedTextTrack",value:function(e){wn.O.forEachTrack(this.videojsPlayer.player_,(function(t){t.src===e?t.mode="showing":t.mode="hidden"}))}},{key:"showUI",value:function(e){this.ui&&(this.ui.setPoster(this.options_.poster),this.ui.setDevice(e),this.ui.show())}},{key:"hideUI",value:function(){var e;null===(e=this.ui)||void 0===e||e.hide()}},{key:"dispose",value:function(){this.textTracks().off("change",this.onTextTrackChanged);var e=this.getCastSession();e&&e.dispose(),Dn(Nn(t.prototype),"cleanupAutoTextTracks",this).call(this),Dn(Nn(t.prototype),"dispose",this).call(this)}},{key:"createEl",value:function(){var e=this;return this.ui=this.ui||new _n({onStopCasting:function(){var t;null===(t=e.getCastSession())||void 0===t||t.dispose()}}),this.ui.el()}},{key:"setSource",value:function(e){var t=this.getCastSession();if(t){this.showUI(t.getDevice()),this.trigger("loadstart");var n=this.getSelectedTextTrack();t.loadSource(e.src,null==n?void 0:n.src)}}},{key:"addRemoteTextTrack",value:function(e){return Dn(Nn(t.prototype),"addRemoteTextTrack",this).call(this,e,!0)}},{key:"getCastSession",value:function(){var e;return Xt.getOrCreateInstance(null!==(e=this.options_.instanceId)&&void 0!==e?e:"").getCastSession()}},{key:"play",value:function(){var e;null===(e=this.getCastSession())||void 0===e||e.play()}},{key:"pause",value:function(){var e;null===(e=this.getCastSession())||void 0===e||e.pause()}},{key:"paused",value:function(){var e;return!1===(null===(e=this.getCastSession())||void 0===e?void 0:e.isPlaying())}},{key:"ended",value:function(){var e,t;return null!==(t=null===(e=this.getCastSession())||void 0===e?void 0:e.isPlaybackFinished())&&void 0!==t&&t}},{key:"setCurrentTime",value:function(e){var t;null===(t=this.getCastSession())||void 0===t||t.seek(null!=e?e:0)}},{key:"currentTime",value:function(){var e,t;return null!==(t=null===(e=this.getCastSession())||void 0===e?void 0:e.getPosition())&&void 0!==t?t:0}},{key:"duration",value:function(){var e,t;return null!==(t=null===(e=this.getCastSession())||void 0===e?void 0:e.getDuration())&&void 0!==t?t:this.videojsPlayer.duration()}},{key:"volume",value:function(){var e,t;return null!==(t=null===(e=this.getCastSession())||void 0===e?void 0:e.getVolume())&&void 0!==t?t:1}},{key:"setVolume",value:function(e){var t;null===(t=this.getCastSession())||void 0===t||t.setVolume(e)}},{key:"muted",value:function(){var e,t;return null!==(t=null===(e=this.getCastSession())||void 0===e?void 0:e.getMuted())&&void 0!==t&&t}},{key:"setMuted",value:function(e){var t;null===(t=this.getCastSession())||void 0===t||t.setMuted(e)}},{key:"buffered",value:function(){}},{key:"seekable",value:function(){return o.Z.createTimeRanges(0,this.duration())}},{key:"playbackRate",value:function(){return 1}},{key:"readyState",value:function(){return 4}},{key:"controls",value:function(){return!1}},{key:"playsinline",value:function(){return!0}},{key:"supportsFullScreen",value:function(){return!0}},{key:"setAutoplay",value:function(){}},{key:"preload",value:function(){}},{key:"load",value:function(){}},{key:"setPlaybackRate",value:function(){}}])&&xn(n.prototype,r),i&&xn(n,i),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r,i}(o.Z.getComponent("Tech"));function An(e){return An="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},An(e)}function Fn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Un(r.key),r)}}function Un(e){var t=function(e,t){if("object"!=An(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=An(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==An(t)?t:t+""}function Zn(e,t,n){return t=qn(t),function(e,t){if(t&&("object"===An(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,zn()?Reflect.construct(t,n||[],qn(e).constructor):t.apply(e,n))}function zn(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(zn=function(){return!!e})()}function Gn(){return Gn="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=qn(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},Gn.apply(this,arguments)}function qn(e){return qn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},qn(e)}function Hn(e,t){return Hn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Hn(e,t)}o.Z.registerTech("devices",Vn);var Yn=function(e){function t(e,n){var r,i,o;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=Zn(this,t,[e,n])).options=n,r.instanceId=null!==(o=null===(i=r.player.options_.devices)||void 0===i?void 0:i.instanceId)&&void 0!==o?o:"",r.bindFunctions(),r.initialize(),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Hn(e,t)}(t,e),n=t,(r=[{key:"bindFunctions",value:function(){this.initialize=this.initialize.bind(this),this.onReady=this.onReady.bind(this),this.onDevicesChanged=this.onDevicesChanged.bind(this),this.onCastSessionChanged=this.onCastSessionChanged.bind(this),this.onDevicesError=this.onDevicesError.bind(this),this.addViviClient=this.addViviClient.bind(this),this.addAppleTvClient=this.addAppleTvClient.bind(this),this.reloadTech=this.reloadTech.bind(this),this.getSessionManager=this.getSessionManager.bind(this),this.dispose=this.dispose.bind(this)}},{key:"initialize",value:function(){this.player.ready(this.onReady)}},{key:"onReady",value:function(){var e=this,t=this.player.getChild("collapserator"),n=null==t?void 0:t.children().findIndex((function(e){return"CustomControlSpacer"===e.name()})),r=null==t?void 0:t.children().findIndex((function(e){return"OpenExternallyButton"===e.name()})),i=Math.max(n,r)+1,o=this.getSessionManager();if(t&&n&&-1!==n&&o){o.on("deviceschange",this.onDevicesChanged),o.on("castsessionchange",this.onCastSessionChanged),o.on("error",this.onDevicesError);var a={onClick:function(){e.addViviClient(o),e.addAppleTvClient(o)},onDeviceMenuItemClick:function(t,n){var r;o.startCastSession({device:n,title:e.options.title}),null===(r=e.options.analyticsService)||void 0===r||r.logUserAction(n,{actionType:et.Vw.Select,workflowPhase:et.eu.Complete,descriptor:et.UX.ChangeDevice,entity:et.py.Device,eventVersion:et.eq.V3})}};this.devicesButton=t.addChild("DevicesButton",a,i)}}},{key:"onDevicesChanged",value:function(e){var t;null===(t=this.devicesButton)||void 0===t||t.setDevices(e)}},{key:"onCastSessionChanged",value:function(e){var t;null===(t=this.devicesButton)||void 0===t||t.setCastSession(e),this.reloadTech(),e?(this.player.addClass("cv-device-casting"),this.player.addClass("cv-device-".concat(e.getDevice().type)),this.player.isFullscreen()&&this.player.exitFullscreen()):(this.player.removeClass("cv-device-casting"),this.player.removeClass("cv-device-".concat(nt.Y.AppleTv)),this.player.removeClass("cv-device-".concat(nt.Y.Vivi)))}},{key:"onDevicesError",value:function(e){this.player.error(e.message),this.player.pause()}},{key:"addViviClient",value:function(e){if(this.options.viviEnabled&&this.options.viviApi&&this.options.fetchViviAccessToken&&!e.hasInstanceOfClient(Ft)){var t=new Ft({url:this.options.viviApi,fetchAccessToken:this.options.fetchViviAccessToken});e.addClient(t)}}},{key:"addAppleTvClient",value:function(e){if(this.options.appleTvEnabled&&this.options.fetchOnlineApiAccessToken&&this.options.trackingCode&&this.options.userId&&!e.hasInstanceOfClient(tt.w)){var t=new tt.w({fetchAccessToken:this.options.fetchOnlineApiAccessToken,trackingCode:this.options.trackingCode,userId:this.options.userId});e.addClient(t)}}},{key:"reloadTech",value:function(){var e=this.player,t=e.currentSources(),n=e.volume(),r=e.muted(),i=e.currentTime(),o=e.paused();e.src(t),e.one("playing",(function(){e.volume(n),e.muted(r),e.currentTime(i),o?e.pause():e.play()}))}},{key:"getSessionManager",value:function(){if(this.instanceId)return Xt.getOrCreateInstance(this.instanceId)}},{key:"dispose",value:function(){var e=this.getSessionManager();e&&(e.off("deviceschange",this.onDevicesChanged),e.off("castsessionchange",this.onCastSessionChanged),e.off("error",this.onDevicesError),Xt.disposeAndRemoveInstance(e),Gn(qn(t.prototype),"dispose",this).call(this))}}])&&Fn(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getPlugin("plugin"));function Wn(e){return Wn="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},Wn(e)}function $n(){$n=function(){return t};var e,t={},n=Object.prototype,r=n.hasOwnProperty,i=Object.defineProperty||function(e,t,n){e[t]=n.value},o="function"==typeof Symbol?Symbol:{},a=o.iterator||"@@iterator",s=o.asyncIterator||"@@asyncIterator",u=o.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(e){c=function(e,t,n){return e[t]=n}}function l(e,t,n,r){var o=t&&t.prototype instanceof b?t:b,a=Object.create(o.prototype),s=new I(r||[]);return i(a,"_invoke",{value:C(e,n,s)}),a}function f(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}t.wrap=l;var p="suspendedStart",h="suspendedYield",y="executing",d="completed",v={};function b(){}function g(){}function m(){}var w={};c(w,a,(function(){return this}));var O=Object.getPrototypeOf,P=O&&O(O(x([])));P&&P!==n&&r.call(P,a)&&(w=P);var S=m.prototype=b.prototype=Object.create(w);function k(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function j(e,t){function n(i,o,a,s){var u=f(e[i],e,o);if("throw"!==u.type){var c=u.arg,l=c.value;return l&&"object"==Wn(l)&&r.call(l,"__await")?t.resolve(l.__await).then((function(e){n("next",e,a,s)}),(function(e){n("throw",e,a,s)})):t.resolve(l).then((function(e){c.value=e,a(c)}),(function(e){return n("throw",e,a,s)}))}s(u.arg)}var o;i(this,"_invoke",{value:function(e,r){function i(){return new t((function(t,i){n(e,r,t,i)}))}return o=o?o.then(i,i):i()}})}function C(t,n,r){var i=p;return function(o,a){if(i===y)throw Error("Generator is already running");if(i===d){if("throw"===o)throw a;return{value:e,done:!0}}for(r.method=o,r.arg=a;;){var s=r.delegate;if(s){var u=T(s,r);if(u){if(u===v)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(i===p)throw i=d,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);i=y;var c=f(t,n,r);if("normal"===c.type){if(i=r.done?d:h,c.arg===v)continue;return{value:c.arg,done:r.done}}"throw"===c.type&&(i=d,r.method="throw",r.arg=c.arg)}}}function T(t,n){var r=n.method,i=t.iterator[r];if(i===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,T(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),v;var o=f(i,t.iterator,n.arg);if("throw"===o.type)return n.method="throw",n.arg=o.arg,n.delegate=null,v;var a=o.arg;return a?a.done?(n[t.resultName]=a.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,v):a:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,v)}function E(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function _(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function I(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(E,this),this.reset(!0)}function x(t){if(t||""===t){var n=t[a];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var i=-1,o=function n(){for(;++i<t.length;)if(r.call(t,i))return n.value=t[i],n.done=!1,n;return n.value=e,n.done=!0,n};return o.next=o}}throw new TypeError(Wn(t)+" is not iterable")}return g.prototype=m,i(S,"constructor",{value:m,configurable:!0}),i(m,"constructor",{value:g,configurable:!0}),g.displayName=c(m,u,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===g||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,m):(e.__proto__=m,c(e,u,"GeneratorFunction")),e.prototype=Object.create(S),e},t.awrap=function(e){return{__await:e}},k(j.prototype),c(j.prototype,s,(function(){return this})),t.AsyncIterator=j,t.async=function(e,n,r,i,o){void 0===o&&(o=Promise);var a=new j(l(e,n,r,i),o);return t.isGeneratorFunction(n)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},k(S),c(S,u,"Generator"),c(S,a,(function(){return this})),c(S,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},t.values=x,I.prototype={constructor:I,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(_),!t)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function i(r,i){return s.type="throw",s.arg=t,n.next=r,i&&(n.method="next",n.arg=e),!!i}for(var o=this.tryEntries.length-1;o>=0;--o){var a=this.tryEntries[o],s=a.completion;if("root"===a.tryLoc)return i("end");if(a.tryLoc<=this.prev){var u=r.call(a,"catchLoc"),c=r.call(a,"finallyLoc");if(u&&c){if(this.prev<a.catchLoc)return i(a.catchLoc,!0);if(this.prev<a.finallyLoc)return i(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return i(a.catchLoc,!0)}else{if(!c)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return i(a.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(i.tryLoc<=this.prev&&r.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var o=i;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var a=o?o.completion:{};return a.type=e,a.arg=t,o?(this.method="next",this.next=o.finallyLoc,v):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),v},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),_(n),v}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;_(n)}return i}}throw Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:x(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),v}},t}function Qn(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 Xn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Jn(r.key),r)}}function Jn(e){var t=function(e,t){if("object"!=Wn(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=Wn(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Wn(t)?t:t+""}function Kn(e,t,n){return t=nr(t),function(e,t){if(t&&("object"===Wn(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,er()?Reflect.construct(t,n||[],nr(e).constructor):t.apply(e,n))}function er(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(er=function(){return!!e})()}function tr(){return tr="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=nr(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},tr.apply(this,arguments)}function nr(e){return nr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},nr(e)}function rr(e,t){return rr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},rr(e,t)}o.Z.registerPlugin("devicesPlugin",Yn);var ir=function(e){function t(e,n){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),Kn(this,t,[e,n])}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&rr(e,t)}(t,e),n=t,(r=[{key:"getPlayerOptions",value:function(){var e,n=tr(nr(t.prototype),"getPlayerOptions",this).call(this);return this.areDevicesEnabled()?Object.assign(Object.assign({},n),{techOrder:["devices"].concat((e=n.techOrder,function(e){if(Array.isArray(e))return Qn(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 Qn(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)?Qn(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.")}())),devices:{instanceId:ft()}}):n}},{key:"configurePlugins",value:function(){var e;try{this.options.onClickCreateClip&&this.player.createClipButtonPlugin({onClick:this.options.onClickCreateClip}),this.options.onRequestPictureInPicture&&this.player.pictureInPicture({onRequestPictureInPicture:this.options.onRequestPictureInPicture}),(null===(e=this.options.pointsOfInterest)||void 0===e?void 0:e.length)&&this.player.pointsOfInterestPlugin({pointsOfInterest:this.options.pointsOfInterest})}catch(e){console.log("failed to register plugins",e)}}},{key:"setNextVideo",value:function(e,t,n){this.player.nextVideoPlugin&&this.player.nextVideoPlugin().setNextVideo(e,t,n)}},{key:"enablePictureInPicture",value:function(){var e=this.player.pictureInPicture();e&&e.enablePictureInPicture()}},{key:"disablePictureInPicture",value:function(){var e=this.player.pictureInPicture();e&&e.disablePictureInPicture()}},{key:"togglePictureInPicture",value:function(e){var t=this.player.pictureInPicture();t&&t.togglePictureInPicture(e)}},{key:"additionalSetup",value:function(e){var n,r,i,o,a,s,u,c,l,f,p=this,h=Object.create(null,{additionalSetup:{get:function(){return tr(nr(t.prototype),"additionalSetup",p)}}});return u=this,c=void 0,l=void 0,f=$n().mark((function t(){var u;return $n().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(h.additionalSetup.call(this,e),this.options.showResources&&e.resources&&this.player.resourcesPlugin&&this.player.resourcesPlugin({resources:e.resources.list,imageCdnUrl:this.options.imageCdnUrl}),"MasterClip"!==e.mediaType){t.next=7;break}if(null!==(u=e.additionalData)){t.next=6;break}throw Error("Invalid clip data");case 6:this.player.clipPlugin({startTime:u.startTime,endTime:u.endTime});case 7:this.areDevicesEnabled()&&this.player.devicesPlugin({viviEnabled:null===(n=this.options.devicesConfig)||void 0===n?void 0:n.viviEnabled,viviApi:null===(r=this.options.devicesConfig)||void 0===r?void 0:r.viviApi,fetchViviAccessToken:null===(i=this.options.devicesConfig)||void 0===i?void 0:i.fetchViviAccessToken,appleTvEnabled:null===(o=this.options.devicesConfig)||void 0===o?void 0:o.appleTvEnabled,fetchOnlineApiAccessToken:null===(a=this.options.devicesConfig)||void 0===a?void 0:a.fetchOnlineApiAccessToken,trackingCode:null===(s=this.options.devicesConfig)||void 0===s?void 0:s.trackingCode,userId:parseInt(e.viewerId),title:e.title,analyticsService:this.analyticsService}),"MasterVideo"===e.mediaType&&this.options.startTime&&this.options.endTime&&this.player.rangeIndicatorPlugin({startTime:this.options.startTime,endTime:this.options.endTime});case 9:case"end":return t.stop()}}),t,this)})),new(l||(l=Promise))((function(e,t){function n(e){try{i(f.next(e))}catch(e){t(e)}}function r(e){try{i(f.throw(e))}catch(e){t(e)}}function i(t){var i;t.done?e(t.value):(i=t.value,i instanceof l?i:new l((function(e){e(i)}))).then(n,r)}i((f=f.apply(u,c||[])).next())}))}},{key:"setActivityStatus",value:function(e,t){this.player.activityStatusPlugin().setActivityStatus(e,t)}}])&&Xn(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(i.r),or=n(63816),ar=n(14735);function sr(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 ur(e){var t,n,i,o=r.useRef(e.player.duration()-e.player.currentTime()),a=(n=r.useState(o.current),i=2,function(e){if(Array.isArray(e))return e}(n)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o,a,s=[],u=!0,c=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=o.call(n)).done)&&(s.push(r.value),s.length!==t);u=!0);}catch(e){c=!0,i=e}finally{try{if(!u&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw i}}return s}}(n,i)||function(e,t){if(e){if("string"==typeof e)return sr(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)?sr(e,t):void 0}}(n,i)||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=a[0],u=a[1];function c(){var t=e.player.duration()-e.player.currentTime();u(t),t>o.current&&(o.current=t)}if(r.useEffect((function(){return e.player.on("timeupdate",c),function(){e.player.off("timeupdate",c)}}),[]),!e.nextVideo||!e.onPlayNext)return r.createElement(r.Fragment,null);var l=Math.ceil(s),f=1===l?"second":"seconds";return r.createElement(r.Fragment,null,r.createElement("div",{className:"cv-up-next-container"},r.createElement("div",{className:"cv-cancel-up-next cursor-pointer",role:"button",onClick:e.onCancel},"×"),r.createElement("div",{className:"cv-up-next-heading"},"Up next in ",l," ",f,":"),r.createElement("div",{className:"cv-up-next-image cursor-pointer",onClick:e.onPlayNext,style:{backgroundImage:"url(".concat(null===(t=e.nextVideo)||void 0===t?void 0:t.thumbnailUrl,")")}}),r.createElement("div",{className:"cv-up-next-title"},e.nextVideo.name)))}function cr(e){return cr="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},cr(e)}function lr(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,fr(r.key),r)}}function fr(e){var t=function(e,t){if("object"!=cr(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=cr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==cr(t)?t:t+""}function pr(e,t,n){return t=dr(t),function(e,t){if(t&&("object"===cr(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,hr()?Reflect.construct(t,n||[],dr(e).constructor):t.apply(e,n))}function hr(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(hr=function(){return!!e})()}function yr(){return yr="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=dr(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},yr.apply(this,arguments)}function dr(e){return dr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},dr(e)}function vr(e,t){return vr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},vr(e,t)}o.Z.registerComponent("UpNext",(0,ar.Z)((function(e,t){return r.createElement(ur,Object.assign({player:e},t))})));var br=function(e){function t(e,n){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=pr(this,t,[e,n])).playNext=e.nextVideoPlugin().getShouldPlayNext(),r.toggle(r.playNext),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&vr(e,t)}(t,e),n=t,(r=[{key:"handleToggle",value:function(){this.toggle(!this.playNext)}},{key:"toggle",value:function(e){e?this.toggleOn():this.toggleOff()}},{key:"toggleOn",value:function(){this.playNext=!0,o.Z.dom.addClass(this.toggleEl,"on"),this.player_.nextVideoPlugin().setShouldPlayNext(this.playNext,!0)}},{key:"toggleOff",value:function(){this.playNext=!1,o.Z.dom.removeClass(this.toggleEl,"on"),this.player_.nextVideoPlugin().setShouldPlayNext(this.playNext,!0)}},{key:"handleClick",value:function(e){e.stopImmediatePropagation()}},{key:"createEl",value:function(e,n,r){this.handlerBound||(this.handleToggle=this.handleToggle.bind(this),this.handlerBound=!0),this.toggleEl&&this.toggleEl.removeEventListener("click",this.handleToggle),this.toggleEl=o.Z.dom.createEl("div",{className:"custom-toggle toggle-option float-end",innerHTML:'<span class="handle"></span></div>'}),this.toggleEl.addEventListener("click",this.handleToggle);var i=yr(dr(t.prototype),"createEl",this).call(this,e,{className:"vjs-menu-item cv-cog-menu-item",innerHTML:'\n <span class="vjs-menu-item-text">Play next video</span>\n <span class="cv-toggle-container"></span>'},r);return i.children[1].appendChild(this.toggleEl),i}}])&&lr(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getComponent("MenuItem"));function gr(e){return gr="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},gr(e)}function mr(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,wr(r.key),r)}}function wr(e){var t=function(e,t){if("object"!=gr(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=gr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==gr(t)?t:t+""}function Or(e,t,n){return t=kr(t),function(e,t){if(t&&("object"===gr(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,Pr()?Reflect.construct(t,n||[],kr(e).constructor):t.apply(e,n))}function Pr(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(Pr=function(){return!!e})()}function Sr(){return Sr="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=kr(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},Sr.apply(this,arguments)}function kr(e){return kr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},kr(e)}function jr(e,t){return jr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},jr(e,t)}o.Z.registerComponent("NextVideoMenuItem",br);var Cr="cv-persisttest",Tr="cv-play-next-video",Er=o.Z.getPlugin("plugin"),_r=(o.Z.getComponent("MenuItem"),o.Z.getComponent("NextVideoMenuItem")),Ir=function(e){function t(e){var n;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(n=Or(this,t,[e])).setShouldPlayNext=n.setShouldPlayNext.bind(n),n.getShouldPlayNext=n.getShouldPlayNext.bind(n),n.getChapterTrack=n.getChapterTrack.bind(n),n.onTimeUpdate=n.onTimeUpdate.bind(n),n.hasLocalStorage=n.testHasLocalStorage(),n.shouldPlayNextVideo=!1,n.hasLocalStorage){var r=window.localStorage.getItem(Tr);n.shouldPlayNextVideo="true"===r}return e.ready((function(){n.initialize()})),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&jr(e,t)}(t,e),n=t,(r=[{key:"initialize",value:function(){this.player.isDisposed()||this.bindListeners()}},{key:"getChapterTrack",value:function(){return wn.O.getTrack(this.player,"chapters",null)}},{key:"setNextVideo",value:function(e,t,n){var r;this.nextVideo=e,this.callback=n,t&&this.setShouldPlayNext(!0),(null===(r=this.player.getChild("collapserator"))||void 0===r?void 0:r.getChild("cogButton")).addItem({index:0,ctor:_r,name:"NextVideoMenuItem"})}},{key:"getShouldPlayNext",value:function(){return this.shouldPlayNextVideo}},{key:"setShouldPlayNext",value:function(e,t){this.shouldPlayNextVideo=e,this.hasLocalStorage&&t&&window.localStorage.setItem(Tr,e.toString())}},{key:"bindListeners",value:function(){this.player.on("timeupdate",this.onTimeUpdate)}},{key:"dispose",value:function(){this.player.off("timeupdate",this.onTimeUpdate),this.hideUpNext(),Sr(kr(t.prototype),"dispose",this).call(this)}},{key:"onTimeUpdate",value:function(){var e,t;if(!this.player.pictureInPicture||!this.player.isInPictureInPicture())if(this.getShouldPlayNext()){if(this.player.ended())return this.callback(),void this.hideUpNext();if(!(this.player.duration()<=0||this.upNextRendered&&this.player.currentTime()>this.upNextTimepoint)){var n=this.getChapterTrack(),r=(null===(e=null==n?void 0:n.activeCues)||void 0===e?void 0:e.length)&&n.activeCues[0];"credits"===(null===(t=null==r?void 0:r.text)||void 0===t?void 0:t.toLowerCase())||this.player.currentTime()>=this.player.duration()-5?this.showUpNext():this.hideUpNext()}}else this.hideUpNext()}},{key:"showUpNext",value:function(){var e=this;this.upNextRendered||(this.upNextRendered=!0,this.upNextTimepoint=this.player.currentTime(),this.player.addChild("UpNext",{nextVideo:this.nextVideo,onPlayNext:this.callback,onCancel:function(){e.hideUpNext(),e.setShouldPlayNext(!1)}}))}},{key:"hideUpNext",value:function(){if(this.upNextRendered){this.upNextRendered=!1,this.upNextTimepoint=null;var e=this.player.getChild("UpNext");e&&(this.player.removeChild(e),e.dispose())}}},{key:"testHasLocalStorage",value:function(){try{return window.localStorage.setItem(Cr,"persistPlayNext"),window.localStorage.removeItem(Cr),!0}catch(e){return!1}}}])&&mr(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(Er);o.Z.registerPlugin("nextVideoPlugin",Ir);var xr=n(26733);function Rr(e){return Rr="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},Rr(e)}function Mr(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Lr(r.key),r)}}function Lr(e){var t=function(e,t){if("object"!=Rr(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=Rr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Rr(t)?t:t+""}function Dr(e,t,n){return t=Br(t),function(e,t){if(t&&("object"===Rr(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,Nr()?Reflect.construct(t,n||[],Br(e).constructor):t.apply(e,n))}function Nr(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(Nr=function(){return!!e})()}function Br(e){return Br=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Br(e)}function Vr(e,t){return Vr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Vr(e,t)}function Ar(e){return r.createElement("div",{className:"cv-resource-item"},r.createElement(xr.s,{data:e.resource,imageCdnUrl:e.imageCdnUrl}))}var Fr=(0,ar.Z)((function(e,t){return r.createElement(Ar,Object.assign({},t))})),Ur=function(e){function t(e,n){var r;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),r=Dr(this,t,[e,n]);var i=new Fr(e,{resource:n.resource,imageCdnUrl:n.imageCdnUrl});return r.addChild(i),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Vr(e,t)}(t,e),n=t,(r=[{key:"createEl",value:function(){return o.Z.dom.createEl("div")}},{key:"handleClick",value:function(e){e.stopImmediatePropagation(),this.options_.downloadResource(this.options_.resource)}}])&&Mr(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getComponent("ClickableComponent"));function Zr(e){return Zr="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},Zr(e)}function zr(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Gr(r.key),r)}}function Gr(e){var t=function(e,t){if("object"!=Zr(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=Zr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Zr(t)?t:t+""}function qr(e,t,n){return t=Wr(t),function(e,t){if(t&&("object"===Zr(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,Hr()?Reflect.construct(t,n||[],Wr(e).constructor):t.apply(e,n))}function Hr(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(Hr=function(){return!!e})()}function Yr(){return Yr="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Wr(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},Yr.apply(this,arguments)}function Wr(e){return Wr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Wr(e)}function $r(e,t){return $r=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},$r(e,t)}var Qr=function(e){function t(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(e=qr(this,t,arguments)).alwaysCollapsed=!1,e.isCollapsed=!1,e.isCollabsible=!0,e}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&$r(e,t)}(t,e),n=t,(r=[{key:"buildWrapperCSSClass",value:function(){return"cv-menu-small ".concat(Yr(Wr(t.prototype),"buildWrapperCSSClass",this).call(this))}},{key:"buildCSSClass",value:function(){return"cv-resources-button ".concat(Yr(Wr(t.prototype),"buildCSSClass",this).call(this))}},{key:"update",value:function(){Yr(Wr(t.prototype),"update",this).call(this)}},{key:"createMenu",value:function(){return this.options_.title="Resources",Yr(Wr(t.prototype),"createMenu",this).call(this)}},{key:"createItems",value:function(){var e=this,t=[];return this.options_.resources.forEach((function(n){var r=new Ur(e.player(),{resource:n,imageCdnUrl:e.options_.imageCdnUrl,downloadResource:function(t){return e.downloadResource(t)}});t.push(r)})),t}},{key:"downloadResource",value:function(e){this.getDownloadIframe().src=e.url}},{key:"getDownloadIframe",value:function(){return this.downloadIframe||(this.downloadIframe=o.Z.dom.createEl("iframe"),this.downloadIframe.style.display="none",o.Z.dom.appendContent(o.Z.dom.$("body"),this.downloadIframe)),this.downloadIframe}},{key:"getCollabsibleName",value:function(){return this.controlText_}},{key:"getCollabsibleValue",value:function(){return""}},{key:"showInCollabsibleMenu",value:function(){return!0}},{key:"showCollapsibleMenu",value:function(){Yr(Wr(t.prototype),"handleClick",this).call(this,null)}}])&&zr(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getComponent("MenuButton"));function Xr(e){return Xr="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},Xr(e)}function Jr(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Kr(r.key),r)}}function Kr(e){var t=function(e,t){if("object"!=Xr(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=Xr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Xr(t)?t:t+""}function ei(e,t,n){return t=ni(t),function(e,t){if(t&&("object"===Xr(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,ti()?Reflect.construct(t,n||[],ni(e).constructor):t.apply(e,n))}function ti(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(ti=function(){return!!e})()}function ni(e){return ni=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},ni(e)}function ri(e,t){return ri=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},ri(e,t)}Qr.prototype.controlText_="Resources",o.Z.registerComponent("ResourcesButton",Qr);var ii=function(e){function t(e,n){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=ei(this,t,[e,n])).options=n,e.ready((function(){return r.onReady()})),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ri(e,t)}(t,e),n=t,(r=[{key:"onReady",value:function(){if(this.options.resources.length){var e=this.player.getChild("collapserator");e.addChild("ResourcesButton",{resources:this.options.resources,imageCdnUrl:this.options.imageCdnUrl},e.children_.length-3)}}}])&&Jr(n.prototype,r),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,r}(o.Z.getPlugin("plugin"));o.Z.registerPlugin("resourcesPlugin",ii);var oi=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 i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n};function ai(e){var t=e.className,n=void 0===t?"":t,i=e.playerApi,o=e.onReady,a=e.onDispose,s=oi(e,["className","playerApi","onReady","onDispose"]),u=r.useRef();return r.useEffect((function(){if(u){var e=new ir(u.current,Object.assign(Object.assign({},s),{playerApi:i}));return o&&e.ready((function(){o((0,or.G)(e))})),a&&e.one("dispose",a),function(){null==e||e.dispose()}}}),[e.viewKey]),r.createElement("div",{ref:u,className:n})}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[4612],{11658:(e,r,t)=>{t.r(r),t.d(r,{BulkUserUploadReviewAccountsView:()=>X});var a=t(32735),n=t(70680),s=t(23481),i=t(81886),o=t(20354),l=t(79447),u=t(83345),c=t(76881),m="userManager.bulkUserUploadLoaderValidation";function d(e){var r,t,n=Math.floor(e.totalCompleted/e.totalUsers*100);return a.createElement("div",{className:"d-flex flex-column align-items-center py-5"},a.createElement("h1",{className:"h5"},a.createElement(u.x,{namespace:m,phrase:e.userType===c.Y.Learner?"headingStudents":"headingStaff"})),a.createElement("p",null,a.createElement(u.x,{namespace:m,phrase:e.userType===c.Y.Learner?"progressStudents":"progressStaff",options:{totalLoaded:null!==(r=e.totalCompleted)&&void 0!==r?r:0,totalUsers:null!==(t=e.totalUsers)&&void 0!==t?t:0}})),a.createElement(l.Z,{className:"w-50",variant:"info",now:n}))}var p=t(67370),f=t(63598),y=t(93898),b=t(21818),v=t(19717),g=t(96728),h=t(69883),k=t(299),E=t(45541),S=t(39739),w=t(10874),T=t(83523),U={downloadCsv:function(e,r){var t="data:text/csv;charset=utf-8,";t+=e.map((function(e){return e.join(",")})).join("\n");var a=document.createElement("a");a.href=encodeURI(t),a.download=r,a.click()}},C=t(35223);function x(e){return x="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},x(e)}function P(e,r,t){var a;return a=function(e,r){if("object"!=x(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var a=t.call(e,"string");if("object"!=x(a))return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(r),(r="symbol"==x(a)?a:a+"")in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}var I=P(P(P({},c.Y.Learner,"userManager.studentSpreadsheetHeading"),c.Y.Staff,"userManager.staffSpreadsheetHeading"),c.Y.Unknown,"");function N(e){var r=(0,E.V)().invalidUsers,t=v.b.getTotalInvalidListings(r);return a.createElement(a.Fragment,null,a.createElement("h2",{className:"h4"},a.createElement(u.x,{namespace:I[e.userType],phrase:"heading"})),t?a.createElement(a.Fragment,null,a.createElement("p",{className:"mb-3 fw-semibold"},a.createElement(u.x,{namespace:I[e.userType],phrase:"reviewInfo"})),a.createElement("div",{className:"pb-3"},a.createElement(w.h,{svgName:C.vn.Upload,appLink:e.appLinks.userUploadPopup,className:"btn btn-outline-dark me-2"},a.createElement(u.x,{namespace:I[e.userType],phrase:"reupload"})),a.createElement(w.h,{svgName:C.vn.Download,onClick:function(){var t=Object.keys(r).map((function(e){return r[e]})).map((function(r){var t,a,n=r.user,s=r.errorCodes,i=S.P.getMinimumPasswordLength(e.passwordPolicy,n.userType,n.masterRole),o=S.P.getErrorMessages(s,i,!0,e.localErrorMessage),l=function(e){var r,t=o[e]||null;return null===t?null!==(r=n[e])&&void 0!==r?r:"":n[e]?t+=": ".concat(n[e]):t};return e.userType===c.Y.Learner?[l("firstName"),l("surname"),null!==(t=o.masterYearGroup)&&void 0!==t?t:null===(a=n.masterYearGroup)||void 0===a?void 0:a.name,l("email"),l("username"),l("password")]:[l("firstName"),l("surname"),l("email"),l("username")]}));e.userType===c.Y.Learner?t.unshift(["First Name","Last Name","Year Group","Email","Username","Password"]):t.unshift(["First Name","Last Name","Email","Username"]),U.downloadCsv(t,s.T.getPhrase(I[e.userType],"errorFileName"))},className:"btn btn-outline-dark"},a.createElement(u.x,{namespace:I[e.userType],phrase:"exportErrors"})))):a.createElement("p",{className:"mb-2"},a.createElement(u.x,{namespace:I[e.userType],phrase:"reviewComplete"})),a.createElement("div",{className:"d-flex align-items-center flex-wrap"},a.createElement("p",{className:"pe-3 mb-0"},a.createElement(u.x,{namespace:I[e.userType],phrase:"switchLabel"})),a.createElement(T.Z,{onClick:e.onToggleValidListings,on:e.hideValidListings})),a.createElement("div",{className:"d-flex align-items-center ms-3 ps-1 mt-3"},a.createElement(w.h,{svgName:C.vn.Close,onClick:e.onClickRemove,className:"btn btn-outline-dark",disabled:!e.bulkIndeterminate&&!e.bulkChecked||e.disableBulkCheckbox},a.createElement(u.x,{namespace:I[e.userType],phrase:"removeFromSpreadsheet"}))))}function L(e){return L="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},L(e)}function j(e,r){return function(e){if(Array.isArray(e))return e}(e)||function(e,r){var t=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=t){var a,n,s,i,o=[],l=!0,u=!1;try{if(s=(t=t.call(e)).next,0===r){if(Object(t)!==t)return;l=!1}else for(;!(l=(a=s.call(t)).done)&&(o.push(a.value),o.length!==r);l=!0);}catch(e){u=!0,n=e}finally{try{if(!l&&null!=t.return&&(i=t.return(),Object(i)!==i))return}finally{if(u)throw n}}return o}}(e,r)||function(e,r){if(e){if("string"==typeof e)return M(e,r);var t=Object.prototype.toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(e):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?M(e,r):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.")}()}function M(e,r){(null==r||r>e.length)&&(r=e.length);for(var t=0,a=new Array(r);t<r;t++)a[t]=e[t];return a}function O(e,r,t){var a;return a=function(e,r){if("object"!=L(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var a=t.call(e,"string");if("object"!=L(a))return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(r),(r="symbol"==L(a)?a:a+"")in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}var V=O(O(O({},c.Y.Learner,"userManager.editStudentSpreadsheet"),c.Y.Staff,"userManager.editStaffSpreadsheet"),c.Y.Unknown,"");function A(e){var r=V[e.userType],t=j(a.useState(!0),2),n=t[0],o=t[1],l=j(a.useState(),2),u=l[0],c=l[1],m=j(a.useState([]),2),S=m[0],w=m[1],T=(0,E.V)(),U=T.users,C=T.invalidUsers,x=T.setInvalidUsers,P=T.hasValidatedUsers,I=T.setExistingUsers,L=P?n?Object.keys(C).map((function(e){return C[e].user})):U:[],M=(0,k.X)(L,{idField:"lookupId"}),O=a.useContext(g.e),A=O.setDisableNext,F=O.setShowButtons,Y=O.setOnClickConfirm,R=(0,h.Z)(),B=v.b.getTotalInvalidListings(C),$=(0,p.Ix)({hasValidatedUsers:P,setInvalidUsers:x,userType:e.userType,setHideValidListings:o,setExistingUsers:I});function G(){R.error(s.T.getPhrase(r,"error")),i.Q.C$.trigger(e.appLinks.userManager,{replace:!0})}return a.useEffect((function(){P||(e.setTotalValidatedUsers(0),e.validateSpreadsheet(U,$,G))}),[P]),a.useEffect((function(){F(P),A(!!Object.keys(null!=C?C:{}).length)}),[C,P]),a.useEffect((function(){Y((function(){return e.onClickConfirm}))}),[e.onClickConfirm]),P?a.createElement(a.Fragment,null,a.createElement(N,{appLinks:e.appLinks,userType:e.userType,hideValidListings:n,passwordPolicy:e.passwordPolicy,onToggleValidListings:function(){return(0,p.zV)({setHideValidListings:o,hideValidListings:n,userType:e.userType})},bulkChecked:M.bulkChecked,bulkIndeterminate:M.hasSomeSelections(),onClickRemove:function(){var e=M.getSelected();w(e)},disableBulkCheckbox:!L.length,localErrorMessage:e.localErrorMessage}),a.createElement("main",{className:"pt-2 pb-3 position-relative"},a.createElement(b.M,{users:L,invalidUsers:C,userType:e.userType,onClickEdit:c,onClickDelete:w,onClickCreate:e.onClickConfirm,appLinks:e.appLinks,showInvalidEmptyState:n&&!B,emptyStateImageUrl:e.emptyStateImageUrl,showPasswordField:e.showPasswordField,passwordPolicy:e.passwordPolicy,checkboxId:"bulk-upload-remove",isChecked:function(e){return M.isChecked(e)&&!!L.length},onToggleCheckbox:M.onToggleItem,localErrorMessage:e.localErrorMessage,bulkCheckboxChecked:M.bulkChecked,bulkIndeterminate:M.hasSomeSelections(),onToggleBulkCheckbox:M.onToggleBulk,disableBulkCheckbox:!L.length})),!!u&&a.createElement(y.n,{key:u.lookupId,user:u,setUser:c,closePopup:function(){return(0,p.UJ)(c,e.closePopup)},title:s.T.getPhrase(r,"editUser"),userType:e.userType,yearGroups:e.yearGroups,analyticsOptions:v.b.getAnalyticsOptions(e.userType),currentUser:e.currentUser,formSize:e.formSize,validateUser:e.validateUser,emailRequired:e.emailRequired,showPasswordField:e.showPasswordField,passwordPolicy:e.passwordPolicy,validateEmail:e.validateEmail,appLinks:e.appLinks,localErrorMessage:e.localErrorMessage}),!!S.length&&a.createElement(f.Q,{users:S,userType:e.userType,closePopup:function(){return(0,p.RF)(w,e.closePopup)},analyticsOptions:v.b.getAnalyticsOptions(e.userType)})):a.createElement(d,{userType:e.userType,totalCompleted:e.totalValidatedUsers,totalUsers:null==U?void 0:U.length})}var F=t(56532),Y=t(26055),R=t(43820),B=t(149),$=t(31949),G=t(79612),H=t(99742),q=t(29613),D=t(706),J=t(47288),Z=t(18087);function _(e){return _="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},_(e)}function z(e,r){(null==r||r>e.length)&&(r=e.length);for(var t=0,a=new Array(r);t<r;t++)a[t]=e[t];return a}function Q(e,r,t){var a;return a=function(e,r){if("object"!=_(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var a=t.call(e,"string");if("object"!=_(a))return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(r),(r="symbol"==_(a)?a:a+"")in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}var W=Q(Q(Q({},c.Y.Learner,"userManager.bulkStudentUploadReviewAccounts"),c.Y.Staff,"userManager.bulkStaffUploadReviewAccounts"),c.Y.Unknown,"");function X(e){var r,t,l=(0,E.V)().users,u=(r=a.useState(0),t=2,function(e){if(Array.isArray(e))return e}(r)||function(e,r){var t=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=t){var a,n,s,i,o=[],l=!0,u=!1;try{if(s=(t=t.call(e)).next,0===r){if(Object(t)!==t)return;l=!1}else for(;!(l=(a=s.call(t)).done)&&(o.push(a.value),o.length!==r);l=!0);}catch(e){u=!0,n=e}finally{try{if(!l&&null!=t.return&&(i=t.return(),Object(i)!==i))return}finally{if(u)throw n}}return o}}(r,t)||function(e,r){if(e){if("string"==typeof e)return z(e,r);var t=Object.prototype.toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(e):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?z(e,r):void 0}}(r,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.")}()),m=u[0],d=u[1],p=o.a.useBasicFetch($.N.currentUser()),f=o.a.useBasicFetch(p.data&&J.N.yearGroups(p.data.customerId)),y=o.a.useBasicFetch(p.data&&D.F.getCustomerSecuritySettings(p.data.customerId)),b=(0,n.I0)(),g=o.a.useGetFetchAsync();(0,G.M)({title:s.T.getPhrase(W[e.userType],"pageTitle")});var h=(0,Z.Y)(e.userType),k=B.b.useCreateJobErrorAlert();function w(r){i.Q.C$.trigger(Object.assign(Object.assign({},h.userUploadStatus.polling),{params:{userType:e.userType,jobId:r.id}}))}return a.createElement(Y.A.Provider,{value:R.a.Primary},a.createElement(F.$,{appLinks:h,userType:e.userType,currentStep:"review-accounts",canAddExistingUsers:!0},a.createElement("div",{className:"px-3"},a.createElement(A,{onClickConfirm:function(){var r=v.b.getJobData({users:l,customerId:p.data.customerId,userType:e.userType});o.a.fetch(b,q.q.createJob(r,w,k))},userType:e.userType,appLinks:h,currentUser:p.data,yearGroups:f.data,closePopup:e.closePopup,validateSpreadsheet:function(r,t,a){v.b.validateSpreadsheetRequest({users:r,userType:e.userType,customerId:p.data.customerId,dispatch:b,requestFn:J.N.bulkUsersValidate,setTotalCompletedUsers:d,canInviteExistingUsers:!0,onSuccess:t,onError:a})},validateUser:function(r){var t=S.P.formatCreateOrValidateUserRequest([r],e.userType,p.data.customerId);return g(J.N.bulkUsersValidate(t,!0))},totalValidatedUsers:m,setTotalValidatedUsers:d,emptyStateImageUrl:H.W.EmptyStates.UserManager.REVIEWS,showPasswordField:e.userType===c.Y.Learner,emailRequired:e.userType===c.Y.Staff,passwordPolicy:y.data,validateEmail:function(r){var t={userEmails:[{email:r,userType:e.userType}]};return g(J.N.bulkCheckEmail(t,p.data.customerId))},localErrorMessage:v.b.getErrorMessageOverride(e.userType)}))))}},79447:(e,r,t)=>{t.d(r,{Z:()=>p});var a=t(95685),n=t.n(a),s=t(32735),i=t(46304),o=t(58661),l=t(74512);const u=1e3;function c(e,r,t){const a=(e-r)/(t-r)*100;return Math.round(a*u)/u}function m({min:e,now:r,max:t,label:a,visuallyHidden:s,striped:i,animated:o,className:u,style:m,variant:d,bsPrefix:p,...f},y){return(0,l.jsx)("div",{ref:y,...f,role:"progressbar",className:n()(u,`${p}-bar`,{[`bg-${d}`]:d,[`${p}-bar-animated`]:o,[`${p}-bar-striped`]:o||i}),style:{width:`${c(r,e,t)}%`,...m},"aria-valuenow":r,"aria-valuemin":e,"aria-valuemax":t,children:s?(0,l.jsx)("span",{className:"visually-hidden",children:a}):a})}const d=s.forwardRef((({isChild:e=!1,...r},t)=>{const a={min:0,max:100,animated:!1,visuallyHidden:!1,striped:!1,...r};if(a.bsPrefix=(0,i.vE)(a.bsPrefix,"progress"),e)return m(a,t);const{min:u,now:c,max:d,label:p,visuallyHidden:f,striped:y,animated:b,bsPrefix:v,variant:g,className:h,children:k,...E}=a;return(0,l.jsx)("div",{ref:t,...E,className:n()(h,v),children:k?(0,o.UI)(k,(e=>(0,s.cloneElement)(e,{isChild:!0}))):m({min:u,now:c,max:d,label:p,visuallyHidden:f,striped:y,animated:b,bsPrefix:v,variant:g},t)})}));d.displayName="ProgressBar";const p=d}}]);
@@ -1,2 +0,0 @@
1
- /*! For license information please see 4676-beb0d246a2-lite.chunk.js.LICENSE.txt */
2
- "use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[4676],{14919:(t,e,r)=>{r.d(e,{w:()=>h});var n=r(32735),o=r(64249),i=r(11607),a=r(2786),c=r(7733),u=r(9085),s=r(98084),l=r(87984);const f={playButtonCircle:"zima4"};function h(t){var e,r,h,p,v=t.onClick,y=t.video,d="rating"in y&&(null===(e=y.rating)||void 0===e?void 0:e.code),m="rating"in y&&(null===(r=y.rating)||void 0===r?void 0:r.value),g=(0,l.C)(m),b="series"in y&&(null===(h=y.series)||void 0===h?void 0:h.name),w="episodeNumber"in y&&y.episodeNumber,E="season"in y&&(null===(p=y.season)||void 0===p?void 0:p.number),k=o.I.getImageUrl(y),x="";k||(x=(0,u.x)(y.name,c.b));var _={backgroundImage:k?"url('".concat(k,"')"):"",backgroundColor:x};return n.createElement(i.L,{className:"cv-embed-splash ".concat(x||"cv-embed-splash-black"),style:_,onClick:v},!!k&&n.createElement("div",{className:"cv-splash-mask"}),n.createElement("div",{className:"cv-splash-metadata"},n.createElement("h1",null,n.createElement("div",{className:"cv-splash-series"},function(t,e,r){if(!t)return"";if(!r||!e)return t;var n=s.I.padNumber(r,2),o=s.I.padNumber(e,2);return"".concat(t," S").concat(n," &bull; E").concat(o)}(b,w,E)),y.name),n.createElement("div",{className:"cv-splash-rating ".concat(g)},d)),n.createElement("div",{className:f.playButtonCircle},n.createElement("svg",{viewBox:"0 0 1800 1800"},n.createElement("path",{d:"M597.3333333333334 1418.6666666666665V373.3333333333333L1418.6666666666667 896z"}))),n.createElement("div",{className:"cv-splash-logo"},n.createElement(a.Yo,null)))}},6736:(t,e,r)=>{r.d(e,{b:()=>E});var n=r(39202),o=r(97395),i=r(81886),a=r(23481),c=r(47663);function u(t){return u="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},u(t)}function s(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,l(n.key),n)}}function l(t){var e=function(t,e){if("object"!=u(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,"string");if("object"!=u(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==u(e)?e:e+""}function f(t,e,r){return e=p(e),function(t,e){if(e&&("object"===u(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)}(t,h()?Reflect.construct(e,r||[],p(t).constructor):e.apply(t,r))}function h(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(h=function(){return!!t})()}function p(t){return p=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},p(t)}function v(t,e){return v=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},v(t,e)}var y="embed.protectiveBrowserSettingsError",d=function(t){function e(t){var r;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(r=f(this,e,[a.T.getPhrase(y,"title")])).url=t,r}return 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&&v(t,e)}(e,t),r=e,(n=[{key:"name",get:function(){return"ProtectiveBrowserSettingsError"}},{key:"dialogOptions",get:function(){return{title:a.T.getPhrase(y,"heading"),text:a.T.getPhrase(y,"description",{url:this.url}),buttons:[{text:a.T.getPhrase(y,"okay"),className:"btn btn-dark",success:!0}]}}}])&&s(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(c.S);function m(t){return m="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},m(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},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function s(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,r){return t[e]=r}}function l(t,e,r,n){var i=e&&e.prototype instanceof b?e:b,a=Object.create(i.prototype),c=new N(n||[]);return o(a,"_invoke",{value:P(t,r,c)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=l;var h="suspendedStart",p="suspendedYield",v="executing",y="completed",d={};function b(){}function w(){}function E(){}var k={};s(k,a,(function(){return this}));var x=Object.getPrototypeOf,_=x&&x(x(T([])));_&&_!==r&&n.call(_,a)&&(k=_);var L=E.prototype=b.prototype=Object.create(k);function O(t){["next","throw","return"].forEach((function(e){s(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var s=u.arg,l=s.value;return l&&"object"==m(l)&&n.call(l,"__await")?e.resolve(l.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(l).then((function(t){s.value=t,a(s)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function P(e,r,n){var o=h;return function(i,a){if(o===v)throw Error("Generator is already running");if(o===y){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=S(c,n);if(u){if(u===d)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=y,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=v;var s=f(e,r,n);if("normal"===s.type){if(o=n.done?y:p,s.arg===d)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(o=y,n.method="throw",n.arg=s.arg)}}}function S(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,S(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),d;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,d;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,d):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,d)}function C(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 I(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function N(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(C,this),this.reset(!0)}function T(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=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 i.next=i}}throw new TypeError(m(e)+" is not iterable")}return w.prototype=E,o(L,"constructor",{value:E,configurable:!0}),o(E,"constructor",{value:w,configurable:!0}),w.displayName=s(E,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===w||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,E):(t.__proto__=E,s(t,u,"GeneratorFunction")),t.prototype=Object.create(L),t},e.awrap=function(t){return{__await:t}},O(j.prototype),s(j.prototype,c,(function(){return this})),e.AsyncIterator=j,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new j(l(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},O(L),s(L,u,"Generator"),s(L,a,(function(){return this})),s(L,"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,N.prototype={constructor:N,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(I),!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 i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),s=n.call(a,"finallyLoc");if(u&&s){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.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 i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,d):this.complete(a)},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),d},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),I(r),d}},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;I(r)}return o}}throw 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),d}},e}var b="_cookieTest";function w(t,e,r,n){var o=window.open(t,"_blank",function(t){var e="sm"===t?550:screen.availWidth,r="sm"===t?750:screen.availWidth,n=parseInt(screen.availWidth/2-e/2+""),o=parseInt(screen.availHeight/2-r/2+"");return["width=".concat(e),"height=".concat(r),"status","resizable","left=".concat(n),"top=".concat(o),"screenX=".concat(n),"screenY=".concat(o),"scrollbars=yes"].join(",")}(n));if(o)return k(o,r),o;i.Q.Ry.throw(new d(e))}var E={renderSignInPopup:function(t){var e=t.primaryUrl,i=t.shareId,a=t.isMicrosoftTeams,c=t.customerId,u=t.onClose,s=t.redirectUrl,l=void 0===s?"/embed-login-success":s,f=t.size,h=void 0===f?"sm":f,p=o._.safeUrlConcat(e,"/login"),v={redirectUrl:l,showSignUp:!0};i&&(v.shareId=i),c&&(v.customerId=c);var y=o._.urlBuilder(p,v);if(!a)return w(y,e,u,h);!function(t){r.e(4777).then(r.t.bind(r,94777,23)).then((function(e){e.initialize(),window.setTimeout((function(){e.authentication.authenticate({url:t,successCallback:function(){n.Ab.Reload()},failureCallback:function(){n.Ab.Reload()},height:1e3,width:1e3})}),0)}))}(y)},renderSignUpPopup:function(t){var e=t.primaryUrl,r=t.onClose,n=t.size,i=void 0===n?"sm":n;return w(o._.safeUrlConcat(e,"/sign-up"),e,r,i)},setPreloadCookie:function(){docCookies.setItem(b,"1",3600,null,null,!0,"none")},canUseCookies:function(){return docCookies.setItem(b,"1",10,null,null,!0,"none"),!!docCookies.getItem("_cookieTest")||(docCookies.setItem(b,"1",10),!!docCookies.getItem(b))},closePopup:function(t){return e=this,n=void 0,o=void 0,i=g().mark((function e(){var n,o;return g().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return o=function(){try{n.initialize((function(){n.authentication.notifySuccess()}))}catch(t){}},e.next=3,r.e(4777).then(r.t.bind(r,94777,23));case 3:n=e.sent,t?(o(),window.close()):window.setTimeout((function(){o(),window.close()}),1e3),window.opener.postMessage({type:"authenticated"},"*");case 6:case"end":return e.stop()}}),e)})),new(o||(o=Promise))((function(t,r){function a(t){try{u(i.next(t))}catch(t){r(t)}}function c(t){try{u(i.throw(t))}catch(t){r(t)}}function u(e){var r;e.done?t(e.value):(r=e.value,r instanceof o?r:new o((function(t){t(r)}))).then(a,c)}u((i=i.apply(e,n||[])).next())}));var e,n,o,i}};function k(t,e){setTimeout((function(){t&&(!1===t.closed?k(t,e):e())}),500)}},87984:(t,e,r)=>{function n(t){return t?function(t){switch(!0){case t<32:return"cv-rating-purple";case t<48:return"cv-rating-green";case t<80:return"cv-rating-blue";case t<96:return"cv-rating-red";case t<128:return"cv-rating-pink";case t>=128:return"cv-rating-yellow";default:return""}}(t):""}r.d(e,{C:()=>n})}}]);
@@ -1,2 +0,0 @@
1
- /*! For license information please see 4778-9e056d0b13-lite.chunk.js.LICENSE.txt */
2
- "use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[4778],{34778:(t,e,r)=>{r.r(e),r.d(e,{AddVideoView:()=>T});var n=r(32735),o=r(60139),i=r(23481),a=r(81886),c=r(20354),u=r(49985),l=r(65858),s=r(9111),f=r(13876),h=r(83914),p=r(83345),d=r(4594),y=r(1575),v=r(69883),m=r(35223),g=r(65185),w=r(99742),b=r(14070),E=r(97291),x=r(99940),L={addVideo:function(t,e){return{key:"add:video:exchange",url:"{gateway}/v1/users/me/add-videos",data:{libraryId:t,objectId:e},type:x.k.POST,invalidationKeys:["videos:".concat(e,":"),"my:videos"]}}};function S(t){return S="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},S(t)}function k(){k=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var i=e&&e.prototype instanceof m?e:m,a=Object.create(i.prototype),c=new A(n||[]);return o(a,"_invoke",{value:j(t,r,c)}),a}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 h="suspendedStart",p="suspendedYield",d="executing",y="completed",v={};function m(){}function g(){}function w(){}var b={};l(b,a,(function(){return this}));var E=Object.getPrototypeOf,x=E&&E(E(I([])));x&&x!==r&&n.call(x,a)&&(b=x);var L=w.prototype=m.prototype=Object.create(b);function O(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function _(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var l=u.arg,s=l.value;return s&&"object"==S(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(s).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function j(e,r,n){var o=h;return function(i,a){if(o===d)throw Error("Generator is already running");if(o===y){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=N(c,n);if(u){if(u===v)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=y,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var l=f(e,r,n);if("normal"===l.type){if(o=n.done?y:p,l.arg===v)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=y,n.method="throw",n.arg=l.arg)}}}function N(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,N(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),v;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,v;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,v):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,v)}function P(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 T(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function A(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(P,this),this.reset(!0)}function I(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=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 i.next=i}}throw new TypeError(S(e)+" is not iterable")}return g.prototype=w,o(L,"constructor",{value:w,configurable:!0}),o(w,"constructor",{value:g,configurable:!0}),g.displayName=l(w,u,"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,w):(t.__proto__=w,l(t,u,"GeneratorFunction")),t.prototype=Object.create(L),t},e.awrap=function(t){return{__await:t}},O(_.prototype),l(_.prototype,c,(function(){return this})),e.AsyncIterator=_,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new _(s(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},O(L),l(L,u,"Generator"),l(L,a,(function(){return this})),l(L,"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=I,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(T),!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 i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),l=n.call(a,"finallyLoc");if(u&&l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!l)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.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 i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,v):this.complete(a)},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),v},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),T(r),v}},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;T(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:I(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),v}},e}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,i,a,c=[],u=!0,l=!1;try{if(i=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=i.call(r)).done)&&(c.push(n.value),c.length!==e);u=!0);}catch(t){l=!0,o=t}finally{try{if(!u&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(l)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return _(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)?_(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 _(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 j=function(t,e,r,n){return new(r||(r=Promise))((function(o,i){function a(t){try{u(n.next(t))}catch(t){i(t)}}function c(t){try{u(n.throw(t))}catch(t){i(t)}}function u(t){var e;t.done?o(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(a,c)}u((n=n.apply(t,e||[])).next())}))},N="shared.addVideo",P=i.T.encloseNamespace(N);function T(t){var e,r=(0,v.Z)(),i=c.a.useGetFetchAsync(),x=c.a.useBasicFetch(y.R.video(t.id)),S=O(n.useState(!1),2),_=S[0],T=S[1],A=O(n.useState(!1),2),I=A[0],V=A[1];return n.useEffect((function(){x.data&&!I&&function(){var e;j(this,void 0,void 0,k().mark((function n(){var a;return k().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return V(!0),n.prev=1,a=null===(e=x.data.libraries)||void 0===e?void 0:e.data.find((function(t){return t.typeId===d.E.ExchangeCollection})),n.next=5,i(L.addVideo(null==a?void 0:a.id,x.data.id));case 5:T(!0),r.success({heading:g.R.Success,message:P("success",{video:x.data.name}),type:o.NK.Success}),u.k.logUserAction({id:x.data.id,name:x.data.name},{actionType:l.Vw.Submit,descriptor:l.XX.AddToWorkspace,location:l.LZ.Popup,entity:l.py.Video}),n.next=14;break;case 10:n.prev=10,n.t0=n.catch(1),r.error(P("error")),t.closePopup();case 14:case"end":return n.stop()}}),n,null,[[1,10]])})))}()}),[null===(e=x.data)||void 0===e?void 0:e.id]),n.createElement(s.G,{title:P("title"),closePopup:t.closePopup,showLoadingSpinner:!_},_&&n.createElement(n.Fragment,null,n.createElement("div",{className:"mx-auto w-75 mt-1 mb-2"},n.createElement("img",{src:w.W.MyVideos.CONFETTI,className:"img-fluid",draggable:!1})),n.createElement("div",{className:"text-center pb-3"},n.createElement("h4",{className:"mb-2"},n.createElement(p.x,{namespace:N,phrase:"added"})))),n.createElement(f.u,null,n.createElement(f.u.Cancel,{text:P("close"),onClick:t.closePopup,variant:"link"}),n.createElement("button",{className:"btn btn-dark",onClick:function(){a.Q.C$.trigger({application:E.O.MY_VIDEOS,action:b.e.MyVideos.MY_VIDEOS}),t.closePopup()}},n.createElement("span",{className:"align-text-bottom me-1"},n.createElement(p.x,{namespace:N,phrase:"open"})),n.createElement(h.x,{svgName:m.vn.NewWindow}))))}}}]);
@@ -1,2 +0,0 @@
1
- /*! For license information please see 4942-a645ec7a44-lite.chunk.js.LICENSE.txt */
2
- "use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[4942],{23455:(e,t,r)=>{r.d(t,{h:()=>i});var n=r(32735),o=r(81886),a=r(20470);function i(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];n.useEffect((function(){t.length&&t.some(o.Q.Ry.isStatusCodeError)&&o.Q.Ry.throw(new a.x)}),t)}},12617:(e,t,r)=>{r.d(t,{E:()=>u});var n=r(99940),o=r(97395),a=r(62803),i=r(5960),c=r(4594),l=r(78417),u={videos:function(e,t,r){var n=a.v.VIDEO_COLLECTION,u=a.v.CLIP_COLLECTION,s=a.v.INTERACTIVE,d="videos[".concat(n,"]{libraries.typeid:").concat(c.E.WorkspaceCollection,"}"),f="clips[".concat(u,"]{status:").concat(i.X.Published,"}"),h="interactives[".concat(s,"]{status:[").concat(i.X.Published,",").concat(i.X.Draft,"]}"),p=[];r?(r.includes("video")&&p.push(d),r.includes("clip")&&p.push(f),r.includes("interactive")&&p.push(h)):p.push(d,f,h);var y={query:"(".concat(p.join("|"),"){orderbydesc:timestamp}"),permissionFilterOption:l.r.FilterOut};return t&&(y.cursor=t),{url:o._.urlBuilder("{gateway}/v1/objects/".concat(e,"/members"),y),key:"my:videos:".concat(e,":").concat(t).concat(r?":".concat(Array.isArray(r)?r.join(":"):r):"")}},workspaceWithCategories:function(){return{url:o._.urlBuilder("/api/domain/v2/me/libraries",{type:["workspace"],maxCategoryDepth:6}),key:"workspace:folders",normalize:!1}},exchangeWithCategories:function(){return{url:o._.urlBuilder("/api/domain/v2/me/libraries",{type:["exchange"],maxCategoryDepth:5}),key:"exchange:folders",normalize:!1}},addFolder:function(e){var t="/api/domain/v2/collections/".concat(e.collectionId,"/categories");return e.parentCategoryId&&(t=o._.urlBuilder(t,{parentCategoryId:e.parentCategoryId})),{url:t,key:"add:folder",type:n.k.POST,data:{name:e.name},invalidationKeys:["workspace","folder"]}},deleteFolder:function(e){return{url:"{gateway}/v1/objects/".concat(e),key:"delete:folder",type:n.k.DELETE,invalidationKeys:["workspace","folder"]}},moveFolder:function(e){return{url:"/api/domain/v2/objects/move",key:"move:folder",type:n.k.POST,data:{assocType:"has",newCollectionId:e.newFolderId,oldCollectionId:e.oldFolderId,objectIds:[e.moveFolderId]},invalidationKeys:["workspace","folder"]}},updateFolder:function(e,t){return{url:"{gateway}/v1/objects/".concat(e),key:"rename:folder",type:n.k.PUT,data:{name:t},invalidationKeys:["workspace","folder"]}},videoFolders:function(e,t){return{url:"/api/domain/v2/objects/".concat(e,"/categories?query=libraries{id:").concat(t,"}"),key:"video:folders:".concat(e)}},moveVideo:function(e){var t={newCollectionId:e.newFolderId,oldCollectionId:e.oldFolderId,objectIds:e.videoId};return{url:"/api/domain/v3/objects/move",key:"move:folder:".concat(t.objectIds.join(",")),type:n.k.POST,data:t,invalidationKeys:["video"]}},addToExchange:function(e){return{url:"{gateway}/v1/users/me/videos/exchange",key:"add:to:exchange",type:n.k.POST,data:e}}}},54485:(e,t,r)=>{r.d(t,{b:()=>c});var n=r(32735),o=r(23481),a=r(11462),i=o.T.encloseNamespace("myVideos.hooks");function c(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return n.useMemo((function(){return(null==e?void 0:e.length)?{children:e.map((function(e){return Object.assign(Object.assign({},e),{data:Object.assign(Object.assign({},e.data),{name:t?i("myVideos"):e.data.name})})})).map(a.d.convertNestedObjectToTree)}:null}),[e])}},43482:(e,t,r)=>{r.r(t),r.d(t,{MoveFolderView:()=>N});var n=r(32735),o=r(23481),a=r(81886),i=r(20354),c=r(49985),l=r(65858),u=r(82644),s=r(9111),d=r(20470),f=r(98064),h=r(69883),p=r(23455),y=r(11462),v=r(14070),m=r(97291),g=r(12617),w=r(54485),b=r(98495),k=r(92802),E=r(5173),x=r(38365),I=r(13876),L=r(55367),O=o.T.encloseNamespace("myVideos.moveFolder"),F=E.Ry().shape({folder:E.Ry().required()});function j(e){var t=(0,k.u6)(),r=n.useMemo((function(){return y.d.getParent(e.folders,e.folderId)}),[e.folders,e.folderId]);return n.createElement(k.l0,null,n.createElement(x.W,{label:O("parentFolder"),name:"folder"},(function(){var o;return n.createElement(b.ZP,{autoHeight:!0,autoHeightMax:300,className:"border rounded-3"},n.createElement(L.m,{tree:e.folders,onSelect:function(e){e&&t.setFieldValue("folder",e)},selectedIds:(null===(o=t.values.folder)||void 0===o?void 0:o.id)?[t.values.folder.id]:void 0,selectedLinkClassName:"bg-light",openDepth:1,isDisabled:function(e){return e.id===r.id},isClickDisabled:function(t){return t.id===e.folderId},disabledTooltip:function(t){return O(t.id===e.folderId?"sameFolder":"parentFolderWarning")},maxDisplayDepth:6}))})),n.createElement(I.u,null,n.createElement(I.u.Cancel,{onClick:e.onClickCancel}),n.createElement(I.u.Submit,{variant:"dark",showSpinner:e.showSpinner,text:O("moveFolder")})))}function C(e){return C="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},C(e)}function S(){S=function(){return t};var e,t={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(e,t,r){e[t]=r.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function u(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{u({},"")}catch(e){u=function(e,t,r){return e[t]=r}}function s(e,t,r,n){var a=t&&t.prototype instanceof m?t:m,i=Object.create(a.prototype),c=new _(n||[]);return o(i,"_invoke",{value:O(e,r,c)}),i}function d(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}t.wrap=s;var f="suspendedStart",h="suspendedYield",p="executing",y="completed",v={};function m(){}function g(){}function w(){}var b={};u(b,i,(function(){return this}));var k=Object.getPrototypeOf,E=k&&k(k(T([])));E&&E!==r&&n.call(E,i)&&(b=E);var x=w.prototype=m.prototype=Object.create(b);function I(e){["next","throw","return"].forEach((function(t){u(e,t,(function(e){return this._invoke(t,e)}))}))}function L(e,t){function r(o,a,i,c){var l=d(e[o],e,a);if("throw"!==l.type){var u=l.arg,s=u.value;return s&&"object"==C(s)&&n.call(s,"__await")?t.resolve(s.__await).then((function(e){r("next",e,i,c)}),(function(e){r("throw",e,i,c)})):t.resolve(s).then((function(e){u.value=e,i(u)}),(function(e){return r("throw",e,i,c)}))}c(l.arg)}var a;o(this,"_invoke",{value:function(e,n){function o(){return new t((function(t,o){r(e,n,t,o)}))}return a=a?a.then(o,o):o()}})}function O(t,r,n){var o=f;return function(a,i){if(o===p)throw Error("Generator is already running");if(o===y){if("throw"===a)throw i;return{value:e,done:!0}}for(n.method=a,n.arg=i;;){var c=n.delegate;if(c){var l=F(c,n);if(l){if(l===v)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===f)throw o=y,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=p;var u=d(t,r,n);if("normal"===u.type){if(o=n.done?y:h,u.arg===v)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(o=y,n.method="throw",n.arg=u.arg)}}}function F(t,r){var n=r.method,o=t.iterator[n];if(o===e)return r.delegate=null,"throw"===n&&t.iterator.return&&(r.method="return",r.arg=e,F(t,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),v;var a=d(o,t.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,v;var i=a.arg;return i?i.done?(r[t.resultName]=i.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,v):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,v)}function j(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function P(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function _(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(j,this),this.reset(!0)}function T(t){if(t||""===t){var r=t[i];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,a=function r(){for(;++o<t.length;)if(n.call(t,o))return r.value=t[o],r.done=!1,r;return r.value=e,r.done=!0,r};return a.next=a}}throw new TypeError(C(t)+" is not iterable")}return g.prototype=w,o(x,"constructor",{value:w,configurable:!0}),o(w,"constructor",{value:g,configurable:!0}),g.displayName=u(w,l,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===g||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,w):(e.__proto__=w,u(e,l,"GeneratorFunction")),e.prototype=Object.create(x),e},t.awrap=function(e){return{__await:e}},I(L.prototype),u(L.prototype,c,(function(){return this})),t.AsyncIterator=L,t.async=function(e,r,n,o,a){void 0===a&&(a=Promise);var i=new L(s(e,r,n,o),a);return t.isGeneratorFunction(r)?i:i.next().then((function(e){return e.done?e.value:i.next()}))},I(x),u(x,l,"Generator"),u(x,i,(function(){return this})),u(x,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),r=[];for(var n in t)r.push(n);return r.reverse(),function e(){for(;r.length;){var n=r.pop();if(n in t)return e.value=n,e.done=!1,e}return e.done=!0,e}},t.values=T,_.prototype={constructor:_,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(P),!t)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var r=this;function o(n,o){return c.type="throw",c.arg=t,r.next=n,o&&(r.method="next",r.arg=e),!!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 Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(e,t){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"===e||"continue"===e)&&a.tryLoc<=t&&t<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=e,i.arg=t,a?(this.method="next",this.next=a.finallyLoc,v):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),v},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),P(r),v}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var o=n.arg;P(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:T(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),v}},t}function P(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}var _=function(e,t,r,n){return new(r||(r=Promise))((function(o,a){function i(e){try{l(n.next(e))}catch(e){a(e)}}function c(e){try{l(n.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(i,c)}l((n=n.apply(e,t||[])).next())}))},T=o.T.encloseNamespace("myVideos.moveFolder");function N(e){var t,r,o=(t=n.useState(!1),r=2,function(e){if(Array.isArray(e))return e}(t)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,o,a,i,c=[],l=!0,u=!1;try{if(a=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(c.push(n.value),c.length!==t);l=!0);}catch(e){u=!0,o=e}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(u)throw o}}return c}}(t,r)||function(e,t){if(e){if("string"==typeof e)return P(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)?P(e,t):void 0}}(t,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.")}()),b=o[0],k=o[1],E=i.a.useGetFetchAsync(),x=(0,h.Z)(),I=i.a.useBasicFetch(f.D.folder(e.id)),L=i.a.useBasicFetch(g.E.workspaceWithCategories()),O=(0,w.b)(L.data);(0,p.h)(I.statusCode,L.statusCode);var C=!!I.data&&!!L.data;return n.createElement(s.G,{title:T("title"),closePopup:e.closePopup,showLoadingSpinner:!C},C&&n.createElement(u.n,{initialValues:{folder:null},validationSchema:F,onSubmit:function(t){return _(this,void 0,void 0,S().mark((function r(){var n;return S().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(!y.d.isMaxDepth(L.data,I.data.id,t.folder.id)){r.next=4;break}return a.Q.C$.trigger({application:m.O.MY_VIDEOS,action:v.e.MyVideos.MAX_FOLDER_DEPTH,args:[y.q]}),e.closePopup(),r.abrupt("return");case 4:if(k(!0),n=y.d.getParent(O,e.id)){r.next=9;break}return a.Q.Ry.throw(new d.x),r.abrupt("return");case 9:return r.prev=9,r.next=12,E(g.E.moveFolder({moveFolderId:I.data.id,newFolderId:t.folder.id,oldFolderId:n.id}));case 12:x.success(T("success")),e.closePopup(),c.k.logUserAction({id:I.data.id,name:I.data.name,newFolderId:t.folder.id,oldFolderId:n.id},{entity:l.py.Folder,actionType:l.Vw.Move,workflowPhase:l.eu.Complete,location:l.LZ.Popup}),r.next=21;break;case 17:r.prev=17,r.t0=r.catch(9),x.error(T("error")),e.closePopup();case 21:case"end":return r.stop()}}),r,null,[[9,17]])})))},validateOnMount:!0},n.createElement(j,{folderId:e.id,onClickCancel:e.closePopup,folders:O,showSpinner:b})))}}}]);