@clickview/library-editor 1.18.0 → 1.19.0-rc.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (171) hide show
  1. package/dist/bundles.json +3 -3
  2. package/dist/css/{2364-library-editor-094b0ebc35.chunk.css → 2364-library-editor-3bfaee83f0.chunk.css} +2 -2
  3. package/dist/css/{3249-library-editor-1e7765111b.chunk.css → 5220-library-editor-678186d63b.chunk.css} +2 -3
  4. package/dist/css/{library-editor-app-6a35dc46bc.css → library-editor-app-d6b9f1d79a.css} +1 -1
  5. package/dist/languages/en.json +1 -1
  6. package/dist/scripts/101-2c95759cb2.chunk.js +1 -0
  7. package/dist/scripts/1010-0d5a5b94a0.chunk.js +1 -0
  8. package/dist/scripts/1086-753763725a.chunk.js +1 -0
  9. package/dist/scripts/1203-d1f4613a9b.chunk.js +1 -0
  10. package/dist/scripts/1216-bf65bae6ca.chunk.js +1 -0
  11. package/dist/scripts/1269-6c2e9b6e3c.chunk.js +1 -0
  12. package/dist/scripts/1364-5fa9fad923.chunk.js +1 -0
  13. package/dist/scripts/1409-77d69bad41.chunk.js +1 -0
  14. package/dist/scripts/1492-3c3c0b9a5f.chunk.js +1 -0
  15. package/dist/scripts/1601-ace29fb597.chunk.js +2 -0
  16. package/dist/scripts/1832-85f1410a7f.chunk.js +1 -0
  17. package/dist/scripts/1887-af4ffa7492.chunk.js +1 -0
  18. package/dist/scripts/1911-ccbc3c9596.chunk.js +1 -0
  19. package/dist/scripts/1934-6ad36e29e8.chunk.js +2 -0
  20. package/dist/scripts/2227-c33c0a79de.chunk.js +2 -0
  21. package/dist/scripts/2364-63d685420e.chunk.js +1 -0
  22. package/dist/scripts/2417-7ef7481a24.chunk.js +1 -0
  23. package/dist/scripts/243-ca6521d881.chunk.js +1 -0
  24. package/dist/scripts/259-eab83bc2a0.chunk.js +1 -0
  25. package/dist/scripts/2692-39c5596fae.chunk.js +1 -0
  26. package/dist/scripts/2802-cd41bf6824.chunk.js +2 -0
  27. package/dist/scripts/2803-342b499819.chunk.js +1 -0
  28. package/dist/scripts/2888-e89aa6d2ec.chunk.js +1 -0
  29. package/dist/scripts/299-a2d3ca19b3.chunk.js +1 -0
  30. package/dist/scripts/3096-603d371dc4.chunk.js +1 -0
  31. package/dist/scripts/330-169096f3cb.chunk.js +1 -0
  32. package/dist/scripts/3400-490d569d7b.chunk.js +1 -0
  33. package/dist/scripts/3639-528131bdac.chunk.js +1 -0
  34. package/dist/scripts/3746-9ddd144888.chunk.js +1 -0
  35. package/dist/scripts/3763-484e998697.chunk.js +1 -0
  36. package/dist/scripts/3969-f8f224e4ea.chunk.js +1 -0
  37. package/dist/scripts/4177-8d301267bb.chunk.js +1 -0
  38. package/dist/scripts/4201-32f6ecdb73.chunk.js +1 -0
  39. package/dist/scripts/4245-902f6c67f5.chunk.js +1 -0
  40. package/dist/scripts/4591-c45a73bb85.chunk.js +1 -0
  41. package/dist/scripts/4830-e4e2e878ab.chunk.js +1 -0
  42. package/dist/scripts/4860-c11ea3fe12.chunk.js +1 -0
  43. package/dist/scripts/4885-fa71def184.chunk.js +1 -0
  44. package/dist/scripts/4993-9532e8d967.chunk.js +1 -0
  45. package/dist/scripts/514-6d760cc4ac.chunk.js +1 -0
  46. package/dist/scripts/5173-9036f3cf73.chunk.js +1 -0
  47. package/dist/scripts/5220-be91e186ce.chunk.js +1 -0
  48. package/dist/scripts/5235-930421e025.chunk.js +1 -0
  49. package/dist/scripts/5412-6a0a1510ab.chunk.js +1 -0
  50. package/dist/scripts/5418-ad39e605a0.chunk.js +1 -0
  51. package/dist/scripts/5424-8d9bd46dea.chunk.js +1 -0
  52. package/dist/scripts/546-f2da7e6a4d.chunk.js +1 -0
  53. package/dist/scripts/5745-674628d114.chunk.js +2 -0
  54. package/dist/scripts/5747-547605a472.chunk.js +1 -0
  55. package/dist/scripts/6093-4f3bdb8793.chunk.js +1 -0
  56. package/dist/scripts/6220-2ea178e5fb.chunk.js +1 -0
  57. package/dist/scripts/6357-4eb8e929ee.chunk.js +1 -0
  58. package/dist/scripts/6505-0ce2963447.chunk.js +1 -0
  59. package/dist/scripts/6732-051facb7f2.chunk.js +1 -0
  60. package/dist/scripts/6756-2bea2e87eb.chunk.js +1 -0
  61. package/dist/scripts/6774-10008c90af.chunk.js +1 -0
  62. package/dist/scripts/6788-f3afed33f5.chunk.js +1 -0
  63. package/dist/scripts/6995-79cb3a5899.chunk.js +1 -0
  64. package/dist/scripts/6999-a75a379a2a.chunk.js +1 -0
  65. package/dist/scripts/7002-0d1e397bfa.chunk.js +1 -0
  66. package/dist/scripts/7053-7fb54caa9c.chunk.js +1 -0
  67. package/dist/scripts/708-1940a739eb.chunk.js +1 -0
  68. package/dist/scripts/{7190-aa3f4b4ba1.chunk.js → 7190-84626d4165.chunk.js} +1 -1
  69. package/dist/scripts/7376-94aa49d108.chunk.js +1 -0
  70. package/dist/scripts/7634-08d0e9d834.chunk.js +1 -0
  71. package/dist/scripts/8153-b1e27ca0d6.chunk.js +1 -0
  72. package/dist/scripts/8362-b6fbc2d32c.chunk.js +1 -0
  73. package/dist/scripts/8495-617e725501.chunk.js +1 -0
  74. package/dist/scripts/8727-276d5560fe.chunk.js +1 -0
  75. package/dist/scripts/8762-652f4cafd5.chunk.js +1 -0
  76. package/dist/scripts/8906-fd50c53320.chunk.js +1 -0
  77. package/dist/scripts/8947-40a2c48b97.chunk.js +1 -0
  78. package/dist/scripts/9357-3bf3ca6c51.chunk.js +1 -0
  79. package/dist/scripts/9695-d74a71dffd.chunk.js +1 -0
  80. package/dist/scripts/{9770-d498ca5470.chunk.js → 9770-59c927b3ae.chunk.js} +1 -1
  81. package/dist/scripts/9927-47808e1cea.chunk.js +1 -0
  82. package/dist/scripts/9976-a5faadcce5.chunk.js +1 -0
  83. package/dist/scripts/bundle-4486724989.min.js +2 -0
  84. package/dist/scripts/polyfills-0e075c1575.min.js +1 -0
  85. package/package.json +4 -5
  86. package/typings/libs/cloneDeep.d.ts +5 -0
  87. package/dist/scripts/101-5264a1cde2.chunk.js +0 -1
  88. package/dist/scripts/1010-deb50c7ea4.chunk.js +0 -1
  89. package/dist/scripts/1086-c589e7a188.chunk.js +0 -1
  90. package/dist/scripts/1203-70df59b9a6.chunk.js +0 -1
  91. package/dist/scripts/1216-7f24ede8e0.chunk.js +0 -1
  92. package/dist/scripts/1269-0663125949.chunk.js +0 -1
  93. package/dist/scripts/1364-3cdf7e5e62.chunk.js +0 -1
  94. package/dist/scripts/1409-061e3f9029.chunk.js +0 -1
  95. package/dist/scripts/1492-2d03a594be.chunk.js +0 -1
  96. package/dist/scripts/1601-5e29bc01b5.chunk.js +0 -2
  97. package/dist/scripts/1832-4939bef81a.chunk.js +0 -1
  98. package/dist/scripts/1887-10d9bb03cb.chunk.js +0 -1
  99. package/dist/scripts/1911-23568f6138.chunk.js +0 -1
  100. package/dist/scripts/1934-2a68903c81.chunk.js +0 -2
  101. package/dist/scripts/2227-1156a0b6e8.chunk.js +0 -2
  102. package/dist/scripts/2364-34211eb55c.chunk.js +0 -1
  103. package/dist/scripts/2417-fed945706c.chunk.js +0 -1
  104. package/dist/scripts/243-7bb390ea4d.chunk.js +0 -1
  105. package/dist/scripts/259-fdac3828c2.chunk.js +0 -1
  106. package/dist/scripts/2692-a74b07a169.chunk.js +0 -1
  107. package/dist/scripts/2802-af98ef08cd.chunk.js +0 -2
  108. package/dist/scripts/2803-29511f028a.chunk.js +0 -1
  109. package/dist/scripts/2888-eec152c5f5.chunk.js +0 -1
  110. package/dist/scripts/299-e581e06f46.chunk.js +0 -1
  111. package/dist/scripts/3096-3b816591ce.chunk.js +0 -1
  112. package/dist/scripts/3249-5736ea51da.chunk.js +0 -1
  113. package/dist/scripts/330-449ecb52be.chunk.js +0 -1
  114. package/dist/scripts/3400-d4b59083ef.chunk.js +0 -1
  115. package/dist/scripts/3639-63ad27fb38.chunk.js +0 -1
  116. package/dist/scripts/3746-90b5368918.chunk.js +0 -1
  117. package/dist/scripts/3763-f486c7b891.chunk.js +0 -1
  118. package/dist/scripts/3969-5ca9cdf6b5.chunk.js +0 -1
  119. package/dist/scripts/4177-d135a23ab6.chunk.js +0 -1
  120. package/dist/scripts/4201-84129dfc88.chunk.js +0 -1
  121. package/dist/scripts/4245-a95daa8056.chunk.js +0 -1
  122. package/dist/scripts/4591-706f7173dd.chunk.js +0 -1
  123. package/dist/scripts/4830-1d03c69a1b.chunk.js +0 -1
  124. package/dist/scripts/4860-f9a7be96c8.chunk.js +0 -1
  125. package/dist/scripts/4885-7c1d78dd3d.chunk.js +0 -1
  126. package/dist/scripts/4993-0a9d31061a.chunk.js +0 -1
  127. package/dist/scripts/514-520d9e5687.chunk.js +0 -1
  128. package/dist/scripts/5173-02a0713c0b.chunk.js +0 -1
  129. package/dist/scripts/5235-d8a1857ab9.chunk.js +0 -1
  130. package/dist/scripts/5412-3b77eef79d.chunk.js +0 -1
  131. package/dist/scripts/5418-8318e5971b.chunk.js +0 -1
  132. package/dist/scripts/5424-164897f2cf.chunk.js +0 -1
  133. package/dist/scripts/546-7f77850497.chunk.js +0 -1
  134. package/dist/scripts/5745-3212b59a8b.chunk.js +0 -2
  135. package/dist/scripts/5747-c7570a4dee.chunk.js +0 -1
  136. package/dist/scripts/6093-e000b9f0a3.chunk.js +0 -1
  137. package/dist/scripts/6220-d350eee4ba.chunk.js +0 -1
  138. package/dist/scripts/6357-d37e948f5e.chunk.js +0 -1
  139. package/dist/scripts/6505-8ae1da1dfa.chunk.js +0 -1
  140. package/dist/scripts/6732-73f12b3316.chunk.js +0 -1
  141. package/dist/scripts/6756-73653a9e01.chunk.js +0 -1
  142. package/dist/scripts/6774-3b27ee5b7d.chunk.js +0 -1
  143. package/dist/scripts/6788-d25db35e6c.chunk.js +0 -1
  144. package/dist/scripts/6995-6be8d799d2.chunk.js +0 -1
  145. package/dist/scripts/6999-f4c8c5a8b5.chunk.js +0 -1
  146. package/dist/scripts/7002-baa9e9e285.chunk.js +0 -1
  147. package/dist/scripts/7053-cce5055ceb.chunk.js +0 -1
  148. package/dist/scripts/708-44fa959bcc.chunk.js +0 -1
  149. package/dist/scripts/7376-e3e7d54126.chunk.js +0 -1
  150. package/dist/scripts/7634-119e6c8a1f.chunk.js +0 -1
  151. package/dist/scripts/8153-c9479fbbd0.chunk.js +0 -1
  152. package/dist/scripts/8362-ccb5f61d03.chunk.js +0 -1
  153. package/dist/scripts/8495-80e0f9737d.chunk.js +0 -1
  154. package/dist/scripts/8727-86d52bc39b.chunk.js +0 -1
  155. package/dist/scripts/8762-ab438942a2.chunk.js +0 -1
  156. package/dist/scripts/8906-e6be28b199.chunk.js +0 -1
  157. package/dist/scripts/8947-50189acd36.chunk.js +0 -1
  158. package/dist/scripts/9357-cac07c3362.chunk.js +0 -1
  159. package/dist/scripts/9695-b789b2a9be.chunk.js +0 -1
  160. package/dist/scripts/9927-773e307959.chunk.js +0 -1
  161. package/dist/scripts/9976-aa31d18e61.chunk.js +0 -1
  162. package/dist/scripts/bundle-c86ee94c2f.min.js +0 -2
  163. package/dist/scripts/polyfills-8a6a6be34b.min.js +0 -1
  164. /package/dist/scripts/{1601-5e29bc01b5.chunk.js.LICENSE.txt → 1601-ace29fb597.chunk.js.LICENSE.txt} +0 -0
  165. /package/dist/scripts/{1934-2a68903c81.chunk.js.LICENSE.txt → 1934-6ad36e29e8.chunk.js.LICENSE.txt} +0 -0
  166. /package/dist/scripts/{2227-1156a0b6e8.chunk.js.LICENSE.txt → 2227-c33c0a79de.chunk.js.LICENSE.txt} +0 -0
  167. /package/dist/scripts/{2802-af98ef08cd.chunk.js.LICENSE.txt → 2802-cd41bf6824.chunk.js.LICENSE.txt} +0 -0
  168. /package/dist/scripts/{5745-3212b59a8b.chunk.js.LICENSE.txt → 5745-674628d114.chunk.js.LICENSE.txt} +0 -0
  169. /package/dist/scripts/{5891-7fd0ab26f9.chunk.js → 5891-697dbd4f64.chunk.js} +0 -0
  170. /package/dist/scripts/{6963-3785059ec0.chunk.js → 6963-d07567d0d3.chunk.js} +0 -0
  171. /package/dist/scripts/{bundle-c86ee94c2f.min.js.LICENSE.txt → bundle-4486724989.min.js.LICENSE.txt} +0 -0
@@ -1 +0,0 @@
1
- (self.webpackChunk_clickview_library_editor=self.webpackChunk_clickview_library_editor||[]).push([[1911],{59054:function(e,t,n){"use strict";var o;n.d(t,{f:function(){return o}}),function(e){e.Share="share",e.MasterObject="masterobject"}(o||(o={}))},47022:function(e,t,n){"use strict";n.d(t,{Q:function(){return y}});var o=n(39479),r=n(31647),i=n(70065),l=n(52076),c=n(99186),a=n.n(c);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 u(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,f(o.key),o)}}function f(e){var t=function(e,t){if("object"!==s(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t);if("object"!==s(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"===s(t)?t:String(t)}function p(e,t){return p=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},p(e,t)}function d(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)}function h(e){return h=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},h(e)}var y=function(e){!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&&p(e,t)}(y,e);var t,n,r,c,s=(r=y,c=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=h(r);if(c){var n=h(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return d(this,e)});function y(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,y),s.call(this,e)}return t=y,(n=[{key:"defaults",get:function(){return{cursors:{},cursorParamName:"cursor"}}},{key:"name",get:function(){return"PaginationComponent"}},{key:"template",get:function(){return a()}},{key:"lang",get:function(){return"shared._pagination"}},{key:"appLinks",get:function(){var e={};if(!this.options.cursors)return{};if(this.options.cursors.previous){var t=this.options.cursors.previous,n=this.buildCursor(this.options.cursors.previous);+t<=1&&!0!==this.options.allowFirstPageCursor&&delete n.params.cursor,e[".previous-applink"]=n}return this.options.cursors.next&&(e[".next-applink"]=this.buildCursor(this.options.cursors.next)),e}},{key:"events",value:function(){return{"click .previous-applink":"onClickPrevious","click .next-applink":"onClickNext"}}},{key:"buildCursor",value:function(e){return{application:this.options.appLink.application,action:this.options.appLink.action,args:this.options.appLink.args,params:o.extend({},this.options.appLink.params,(t={},n=this.options.cursorParamName,r=e,(n=f(n))in t?Object.defineProperty(t,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[n]=r,t))};var t,n,r}},{key:"onClickPrevious",value:function(){this.logAction("previous")}},{key:"onClickNext",value:function(){this.logAction("next")}},{key:"logAction",value:function(e){var t=l.k.mergeOptions(this.options.analyticsOptions,{location:i.LocationContext.Pagination,entity:i.EntityType.Pagination,actionType:i.UserAction.Navigate}),n={id:this.options.collectionId,page:e};l.k.logUserAction(n,t)}},{key:"viewOptions",value:function(){return{cursors:this.options.cursors}}},{key:"onBeforeRender",value:function(){return!!this.options.cursors}}])&&u(t.prototype,n),Object.defineProperty(t,"prototype",{writable:!1}),y}(r.Q.Component)},27719:function(e,t,n){"use strict";n.r(t),n.d(t,{FolderView:function(){return nt},SeriesView:function(){return ot}});var o=n(31647),r=n(21679),i=n(57857),l=n(99748),c=n(47022),a=n(77502),s=n(60602),u=n(71192),f=n(48090),p=n(70763),d=n(61843),h=n(29457),y=n(3059),b=n(23096),v=n(58688),m=n(48404),g=n(19226),k=n(26457),w=n(95061),O=n(51785),S=n(85552),E=n.n(S),C=n(21625),P=n(70065),j=n(22231),x=n(24828);function I(e){return I="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},I(e)}function R(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,(void 0,r=function(e,t){if("object"!==I(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t);if("object"!==I(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(o.key,"string"),"symbol"===I(r)?r:String(r)),o)}var r}function _(e,t){return _=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},_(e,t)}function T(e,t){if(t&&("object"===I(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)}function L(e){return L=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},L(e)}var V=function(e){!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)}(l,e);var t,n,o,r,i=(o=l,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=L(o);if(r){var n=L(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return T(this,e)});function l(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,l),i.call(this,e)}return t=l,(n=[{key:"name",get:function(){return"BannerComponent"}},{key:"className",get:function(){var e=(0,j.x)(this.model.get("name"),x.o);return"px-3 position-relative rounded-top ".concat(C.Z.banner," ").concat(e)}},{key:"regions",value:function(){return{options:{el:".options-region",replaceElement:!0}}}},{key:"attributes",get:function(){var e=d.jw.createBannerUrl(this.model.banner);return e?{style:"background-image: url('".concat(e,"')")}:null}},{key:"template",get:function(){return E()}},{key:"renderActions",value:function(){this.showChildView("options",new O.c({model:this.model,extraClasses:"".concat(C.Z.actions," rounded-circle mr-2 mt-2"),buttonClass:"text-light",analyticsOptions:{location:P.LocationContext.Banner}}))}},{key:"onRender",value:function(){this.renderActions()}}])&&R(t.prototype,n),Object.defineProperty(t,"prototype",{writable:!1}),l}(o.Q.Component),B=n(87002),D=n(73368),A=n.n(D),M=n(63791),N={svgContainer:"mMWNm",caretClosed:"Fe74o"},F=n(4705);function H(e){return H="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},H(e)}function U(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Q(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,(void 0,r=function(e,t){if("object"!==H(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t);if("object"!==H(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(o.key,"string"),"symbol"===H(r)?r:String(r)),o)}var r}function W(e,t,n){return t&&Q(e.prototype,t),n&&Q(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Y(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&&K(e,t)}function K(e,t){return K=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},K(e,t)}function z(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,o=G(e);if(t){var r=G(this).constructor;n=Reflect.construct(o,arguments,r)}else n=o.apply(this,arguments);return X(this,n)}}function X(e,t){if(t&&("object"===H(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)}function G(e){return G=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},G(e)}var Z="has:expanded:library:folders",J=function(e){Y(n,e);var t=z(n);function n(){return U(this,n),t.apply(this,arguments)}return W(n,[{key:"name",get:function(){return"SubFoldersCollectionView"}},{key:"className",get:function(){return"row px-2"}},{key:"childView",get:function(){return B.Y}},{key:"childViewOptions",get:function(){return{location:"subfolder"}}}]),n}(o.Q.ComponentCollection),$=function(e){Y(n,e);var t=z(n);function n(e){return U(this,n),t.call(this,e)}return W(n,[{key:"initialize",value:function(){this.forceExpanded=this.options.forceExpanded||this.collection.length<=6,this.forceExpanded?this.isExpanded=!0:this.isExpanded=F.SG.get(Z)||!1}},{key:"name",get:function(){return"SubFoldersView"}},{key:"className",get:function(){return"container-fluid pb-3"}},{key:"lang",get:function(){return"libraryEditor.subfolders"}},{key:"template",get:function(){return A()}},{key:"events",value:function(){return{"click .expand-toggle":"onClickExpandToggle"}}},{key:"regions",value:function(){return{subFolders:{replaceElement:!0,el:".subfolders-region"}}}},{key:"onClickExpandToggle",value:function(){this.options.forceExpanded||(this.isExpanded=!this.isExpanded,F.SG.set(Z,this.isExpanded),this.render())}},{key:"viewOptions",value:function(){return{styles:N,caretSvg:M.Nj.getSvg(M.vn.Caret),isExpanded:this.isExpanded,forceExpanded:this.forceExpanded,caretClass:this.isExpanded?"":N.caretClosed,count:this.collection.length}}},{key:"onRender",value:function(){this.showChildView("subFolders",new J({collection:this.isExpanded?this.collection:new o.Q.Collection(this.collection.first(6))}))}}]),n}(o.Q.Component),q=n(8420),ee=n.n(q),te=n(57085);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 oe(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,(void 0,r=function(e,t){if("object"!==ne(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t);if("object"!==ne(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(o.key,"string"),"symbol"===ne(r)?r:String(r)),o)}var r}function re(e,t){return re=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},re(e,t)}function ie(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)}function le(e){return le=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},le(e)}var ce=function(e){!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&&re(e,t)}(l,e);var t,n,o,r,i=(o=l,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=le(o);if(r){var n=le(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return ie(this,e)});function l(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,l),i.call(this,e)}return t=l,(n=[{key:"name",get:function(){return"VideoListHeaderComponent"}},{key:"template",get:function(){return ee()}},{key:"className",get:function(){return this.options.folder?"px-3 mb-3":"mb-3"}},{key:"props",get:function(){return["collectionIdentifier"]}},{key:"regions",value:function(){return{breadcrumbs:{el:".breadcrumbs-region",replaceElement:!1}}}},{key:"renderBreadcrumbs",value:function(){this.options.folder&&this.options.libraries&&this.showChildView("breadcrumbs",new te.n({folder:this.options.folder,libraries:this.options.libraries}))}},{key:"onBeforeRender",value:function(){return!!this.options.folder}},{key:"onRender",value:function(){this.renderBreadcrumbs()}}])&&oe(t.prototype,n),Object.defineProperty(t,"prototype",{writable:!1}),l}(o.Q.Component),ae=n(56906),se=n(93089),ue=n.n(se),fe=n(98985),pe=n(25692),de=n(59054),he=n(56846),ye=n.n(he),be=n(12542),ve=n(40622),me=n(50028),ge=n(52076),ke=n(71641),we=n(34670),Oe=n.n(we);function Se(e){return Se="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},Se(e)}function Ee(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,(void 0,r=function(e,t){if("object"!==Se(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t);if("object"!==Se(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(o.key,"string"),"symbol"===Se(r)?r:String(r)),o)}var r}function Ce(e,t){return Ce=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Ce(e,t)}function Pe(e,t){if(t&&("object"===Se(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)}function je(e){return je=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},je(e)}var xe=function(e){!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&&Ce(e,t)}(a,e);var t,n,r,l,c=(r=a,l=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=je(r);if(l){var n=je(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return Pe(this,e)});function a(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),c.call(this,e)}return t=a,(n=[{key:"initialize",value:function(){this.getViewModel(),this.bindListeners()}},{key:"getViewModel",value:function(){var e=this.options.collectionIdentifier.toString();this.model=d.S0.GetViewModel(e,ve.CheckboxTypes.VIDEO_LIST)}},{key:"bindListeners",value:function(){this.listenTo(this.model,"change",this.render),this.listenTo(this.collection,"remove",this.render)}},{key:"name",get:function(){return"BulkVideoActionsComponent"}},{key:"template",get:function(){return Oe()}},{key:"lang",get:function(){return"shared.bulkVideoActions"}},{key:"regions",value:function(){return{dropdownItems:{replaceElement:!0,el:".dropdown-menu-region"}}}},{key:"getSelectedIds",value:function(){return d.S0.GetSelectedIds({key:this.options.collectionIdentifier.toString(),type:ve.CheckboxTypes.VIDEO_LIST,collection:this.collection,excludePredicate:function(e){return e.get("status")===me.X.Processing}})}},{key:"getActions",value:function(){if(this.options.collectionIdentifier){var e=this.getSelectedIds();return new o.Q.Collection([{title:i.T.getPhrase(this.lang,"move",{smartCount:e.length}),appLink:{application:this.options.application,action:f.eX.Shared.MOVE_VIDEOS,args:[e.join(","),this.options.collectionIdentifier.id]},analyticsOptions:ge.k.mergeOptions(this.options.analyticsOptions,{actionType:P.UserAction.Move,workflowPhase:P.WorkflowPhase.Start})},{title:i.T.getPhrase(this.lang,"remove",{smartCount:e.length}),appLink:{application:f.OV.LIBRARY_EDITOR,action:f.eX.Shared.DELETE_VIDEOS,args:[this.options.collectionIdentifier.id,e.join(",")]},analyticsOptions:ge.k.mergeOptions(this.options.analyticsOptions,{actionType:P.UserAction.Delete,workflowPhase:P.WorkflowPhase.Start}),classes:"text-danger"}])}}},{key:"viewOptions",value:function(){return{enabled:this.getSelectedIds().length}}},{key:"onRender",value:function(){this.showChildView("dropdownItems",new ke.w({displayOptions:{alignment:"right"},channelName:"".concat(this.name).concat(this.cid),collection:this.getActions(),analyticsHelper:ge.k}))}}])&&Ee(t.prototype,n),Object.defineProperty(t,"prototype",{writable:!1}),a}(o.Q.Component),Ie=n(39479),Re=n(53370),_e=n.n(Re);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 Le(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,(void 0,r=function(e,t){if("object"!==Te(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t);if("object"!==Te(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(o.key,"string"),"symbol"===Te(r)?r:String(r)),o)}var r}function Ve(e,t){return Ve=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Ve(e,t)}function Be(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)}function De(e){return De=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},De(e)}var Ae=function(e){!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&&Ve(e,t)}(c,e);var t,n,r,i,l=(r=c,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=De(r);if(i){var n=De(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return Be(this,e)});function c(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,c),l.call(this,e)}return t=c,(n=[{key:"initialize",value:function(){this.getViewModel(),this.setSort(),this.bindListeners(),this.initializeCollection()}},{key:"getViewModel",value:function(){this.model=d.x$.GetSortViewModel()}},{key:"setSort",value:function(){var e=this.options.collectionIdentifier.sort;if(e!==this.model.get("sortType")){var t=d.x$.CreateSortObject(e);this.model.set(t)}}},{key:"bindListeners",value:function(){this.listenTo(this.channelName,"sort:selected",this.onSortSelected)}},{key:"initializeCollection",value:function(){this.collection||(this.collection=d.x$.CreateSortCollection())}},{key:"name",get:function(){return"SortSelectComponent"}},{key:"regions",value:function(){return{dropdown:{el:".dropdown-menu-region",replaceElement:!0}}}},{key:"template",get:function(){return _e()}},{key:"channelName",get:function(){return"".concat(this.name).concat(this.cid)}},{key:"className",get:function(){return"position-relative"}},{key:"events",value:function(){return{click:"onClick"}}},{key:"onClick",value:function(){this.logAction(P.WorkflowPhase.Start)}},{key:"onSortSelected",value:function(e){this.model.set(e.toJSON()),this.render(),this.logAction(P.WorkflowPhase.Complete)}},{key:"logAction",value:function(e){var t=ge.k.mergeOptions(this.options.analyticsOptions,{actionType:P.UserAction.Sort,workflowPhase:e}),n={id:this.options.collectionIdentifier.id,sort:this.model.get("name")};ge.k.logUserAction(n,t)}},{key:"onRender",value:function(){var e=this,t=this.collection.filter((function(t){return t.get("name")!==e.model.get("name")})),n=new o.Q.Collection(Ie.map(t,(function(t){var n=t.toJSON();return n.appLink={application:e.options.appLink.application,action:e.options.appLink.action,args:[e.options.collectionIdentifier.id],params:{sort:t.get("sortName")}},n})));this.showChildView("dropdown",new ke.w({collection:n,channelName:this.channelName,childOptions:{titleProperty:"name",eventName:"sort:selected"},displayOptions:{alignment:"right"},analyticsHelper:ge.k}))}}])&&Le(t.prototype,n),Object.defineProperty(t,"prototype",{writable:!1}),c}(o.Q.Component);function Me(e){return Me="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},Me(e)}function Ne(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,(void 0,r=function(e,t){if("object"!==Me(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t);if("object"!==Me(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(o.key,"string"),"symbol"===Me(r)?r:String(r)),o)}var r}function Fe(e,t){return Fe=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Fe(e,t)}function He(e,t){if(t&&("object"===Me(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)}function Ue(e){return Ue=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Ue(e)}var Qe=function(e){!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&&Fe(e,t)}(l,e);var t,n,o,r,i=(o=l,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Ue(o);if(r){var n=Ue(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return He(this,e)});function l(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,l),i.call(this,e)}return t=l,(n=[{key:"initialize",value:function(){this.analyticsOptions=ge.k.mergeOptions(this.options.analyticsOptions,{location:P.LocationContext.VideoListHeader})}},{key:"name",get:function(){return"VideoListSubheadingComponent"}},{key:"template",get:function(){return ye()}},{key:"className",get:function(){return"px-3"}},{key:"lang",get:function(){return"libraryEditor.videoListSubheading"}},{key:"props",get:function(){return["collectionIdentifier"]}},{key:"regions",value:function(){return{checkAll:{el:".check-all-region",replaceElement:!1},bulkActions:{el:".bulk-actions-region",replaceElement:!0},sorting:{el:".sorting-region",replaceElement:!0}}}},{key:"renderCheckAll",value:function(){this.options.allowBulk&&this.showChildView("checkAll",new be.Y({className:"float-left",key:this.collectionIdentifier.toString(),type:ve.CheckboxTypes.VIDEO_LIST,numberOfItems:this.collection.length}))}},{key:"renderBulkActions",value:function(){this.options.allowBulk&&this.showChildView("bulkActions",new xe({collection:this.collection,collectionIdentifier:this.collectionIdentifier,application:this.options.application,analyticsOptions:ge.k.mergeOptions(this.options.analyticsOptions,{descriptor:P.OperationDescriptor.Bulk,location:P.LocationContext.VideoListHeader,entity:P.EntityType.Video,workflowPhase:P.WorkflowPhase.Start})}))}},{key:"renderSorting",value:function(){this.showChildView("sorting",new Ae({collectionIdentifier:this.collectionIdentifier,analyticsOptions:this.analyticsOptions,appLink:{application:this.options.application,action:this.options.action}}))}},{key:"viewOptions",value:function(){return{showBulkActions:this.options.allowBulk&&this.collection.length>0,showHeading:this.options.showHeading}}},{key:"onBeforeRender",value:function(){return!(this.collection.length<=0)}},{key:"onRender",value:function(){this.renderCheckAll(),this.renderBulkActions(),this.renderSorting()}}])&&Ne(t.prototype,n),Object.defineProperty(t,"prototype",{writable:!1}),l}(o.Q.Component);function We(e){return We="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},We(e)}function Ye(){return Ye="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var o=Ke(e,t);if(o){var r=Object.getOwnPropertyDescriptor(o,t);return r.get?r.get.call(arguments.length<3?e:n):r.value}},Ye.apply(this,arguments)}function Ke(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=et(e)););return e}function ze(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Xe(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,(void 0,r=function(e,t){if("object"!==We(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t);if("object"!==We(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(o.key,"string"),"symbol"===We(r)?r:String(r)),o)}var r}function Ge(e,t,n){return t&&Xe(e.prototype,t),n&&Xe(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Ze(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)}function Je(e,t){return Je=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Je(e,t)}function $e(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,o=et(e);if(t){var r=et(this).constructor;n=Reflect.construct(o,arguments,r)}else n=o.apply(this,arguments);return qe(this,n)}}function qe(e,t){if(t&&("object"===We(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)}function et(e){return et=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},et(e)}var tt=function(e){Ze(n,e);var t=$e(n);function n(e){return ze(this,n),t.call(this,e)}return Ge(n,[{key:"initialize",value:function(){this.bindListeners(),this.getSortType(),this.videoDataService=r.u.getInstance(f.Or.Video,this),this.libraryDataService=r.u.getInstance(f.Or.Library,this),this.pendingItemsService=r.u.getInstance(f.K9.PendingItems,this),this.localCacheDataService=r.u.getInstance(f.Or.LocalCache,this),this.playerDataService=r.u.getInstance(f.Or.Player,this),this.videoMixinService=r.u.getInstance(f.K9.VideoMixin,this),this.createViewKey=this.createViewKey.bind(this)}},{key:"title",get:function(){return!!this.model&&this.model.get("name")}},{key:"template",get:function(){return ue()}},{key:"className",get:function(){return"bg-white rounded"}},{key:"channelName",get:function(){return"".concat(this.name,":").concat(this.cid)}},{key:"props",get:function(){return["collectionIdentifier"]}},{key:"regions",value:function(){return{banner:{el:".banner-region",replaceElement:!0,partialLoading:h.LP.Banner},header:{el:".header-region",replaceElement:!0,partialLoading:h.LP.VideoListHeader},videoList:{el:".video-list-region",replaceElement:!0,partialLoading:h.LP.VideoListWithBulkActions},childFolders:{el:".child-folders-region",replaceElement:!1,partialLoading:h.LP.SubFolder},pagination:{el:".pagination-region",replaceElement:!0},subheading:{el:".subheading-region",replaceElement:!0,partialLoading:h.LP.VideoListSubheading}}}},{key:"bindListeners",value:function(){var e=this.options.collectionIdentifier.toString();this.listenTo(f.Vk.VIDEO,"".concat(e,":sync"),this.render),this.listenTo(f.Vk.VIDEO,"".concat(f.M_.DELETE_VIDEO,":sync"),this.fetchData),this.listenTo(f.Vk.VIDEO,"cache:cleared",this.render),this.listenTo(f.Vk.RESTRICTED_VIDEO,"".concat(f.M_.RESTRICTED_OBJECTS,":").concat(e,":invalidate"),this.updateRestrictedVideos),this.listenTo(this.channelName,"cancel:pending:item",this.cancelPendingItem),this.listenTo(this.channelName,"retry:pending:item",this.retryPendingItem),this.listenTo(this.channelName,"fetch:video:with:metadata",this.fetchVideoWithMetadata),this.listenTo(f.Vk.LOCAL_CACHE,"".concat(f.M_.LOCAL_CACHE_DEVICES,":sync"),this.render),this.listenTo(f.Vk.LOCAL_CACHE,"".concat(f.M_.LOCAL_CACHE_DEVICES,":error"),this.onError)}},{key:"getSortType",value:function(){this.sortType||(this.sortType=this.options.collectionIdentifier.sort)}},{key:"updateRestrictedVideos",value:function(){var e=this;this.videoMixinService.getAndMixinVideoCollectionRestrictions(this.videoCollection,this.collectionIdentifier,(function(){return e.render()}))}},{key:"cancelPendingItem",value:function(e){this.pendingItemsService.clearPendingItem(e)}},{key:"retryPendingItem",value:function(e){this.pendingItemsService.retryPendingItem(e)}},{key:"createViewKey",value:function(e,t){this.playerDataService.createViewKey(e,de.f.MasterObject,t)}},{key:"setVideosWithMetadata",value:function(){this.videoCollection&&(this.videosWithMetadata=new p.t(this.videoCollection.map((function(e){return new u.n({id:e.get("id")})}))))}},{key:"renderBanner",value:function(){var e=new V({model:this.model,channelName:this.channelName,imageCdnUrl:this.config.get("imageCdnUrl")});this.showChildView("banner",e)}},{key:"renderChildFolders",value:function(){var e;if(null===(e=this.folders)||void 0===e?void 0:e.length){var t=new $({collection:this.folders,forceExpanded:0===this.videoCollection.length});this.showChildView("childFolders",t)}}},{key:"renderHeader",value:function(){this.showChildView("header",new ce({collection:this.videoCollection,libraries:this.libraryCollection,folder:this.model instanceof s.g&&this.model}))}},{key:"renderSubheading",value:function(){var e;this.showChildView("subheading",new Qe({collection:this.videoCollection,application:f.OV.LIBRARY_EDITOR,action:this.appLinkAction(),allowBulk:this.allowBulk(),collectionIdentifier:this.collectionIdentifier,analyticsOptions:this.options.analyticsOptions,showHeading:!!(null===(e=this.folders)||void 0===e?void 0:e.length)}))}},{key:"renderVideoList",value:function(){var e,t=this.videoDataService.getVideoCollectionCursors(this.collectionIdentifier),n=new b.Y({collection:this.videoCollection,videosWithMetadata:this.videosWithMetadata,application:f.OV.LIBRARY_EDITOR,allowBulk:this.allowBulk(),collectionIdentifier:this.collectionIdentifier,config:this.config,pendingItems:this.pendingItemsService.getPendingItems(),videoItemComponentType:this.componentType,emptyStateType:this.emptyStateType(),emptyStateOptions:this.emptyStateOptions(),supportSiteUrl:this.config.get("supportSiteUrl"),collectionViewChannel:this.channelName,customerHasLocalCache:d.o8.customerHasLocalCache(this.devices,this.currentUser.get("customerId")),customerHasExchange:this.exchanges.any(),analyticsOptions:this.options.analyticsOptions,sourceMetadataOptions:{showFolder:this.showFolderSource(),libraries:this.libraryCollection},videoCollectionSource:this.getVideoCollectionSource(),currentUser:this.currentUser,playerApiUrl:this.config.get("playerApiUrl"),createViewKey:this.createViewKey,hasCursors:!!t,showEmptyState:!(null===(e=this.folders)||void 0===e?void 0:e.length),libraries:this.libraryCollection});this.showChildView("videoList",n)}},{key:"renderPagination",value:function(){var e=this.videoDataService.getVideoCollectionCursors(this.collectionIdentifier),t=new c.Q({cursors:e,collectionId:this.options.collectionIdentifier.id,appLink:{application:f.OV.LIBRARY_EDITOR,action:this.appLinkAction(),args:[this.collectionIdentifier.id],params:this.collectionIdentifier.toParams()},analyticsOptions:this.options.analyticsOptions});this.showChildView("pagination",t)}},{key:"fetchData",value:function(){this.fetchModel(),this.devices=this.localCacheDataService.getDevices(this.currentUser.get("customerId")),this.fetchVideoCollection()}},{key:"fetchVideoWithMetadata",value:function(e){var t=this;this.videoDataService.getVideo(e,(function(n){var o=t.videosWithMetadata.get(e);o&&(o.set(n.toJSON()),o.set({dataFetched:!0}))}))}},{key:"requiredResources",get:function(){return{config:m.p.config,currentUser:g.K.currentUser,libraryCollection:w.T.libraries,exchanges:w.T.exchanges}}},{key:"onBeforeRender",value:function(){return this.fetchData(),!!this.videoCollection&&(this.setVideosWithMetadata(),!!this.model)}},{key:"onRender",value:function(){this.renderBanner(),this.renderHeader(),this.renderChildFolders(),this.renderSubheading(),this.renderVideoList(),this.renderPagination()}}]),n}(o.Q.View),nt=function(e){Ze(n,e);var t=$e(n);function n(){return ze(this,n),t.apply(this,arguments)}return Ge(n,[{key:"name",get:function(){return"FolderView"}},{key:"lang",get:function(){return"libraryEditor.folderView"}},{key:"componentType",get:function(){return v.U.Draggable}},{key:"bindListeners",value:function(){this.listenTo(f.Vk.LIBRARY,"".concat(f.M_.FOLDER,":").concat(this.options.collectionIdentifier.id,":sync libraries:sync"),this.render),this.listenTo(f.Vk.LIBRARY,"".concat(f.M_.FOLDER,":").concat(this.options.collectionIdentifier.id,":error"),this.onError),this.listenTo(f.Vk.LIBRARY,"".concat(f.M_.UPDATE_FOLDER_BANNER,":").concat(this.options.collectionIdentifier.id,":sync"),this.fetchModel),this.listenTo(f.Vk.LIBRARY,"".concat(new y.KX(this.options.collectionIdentifier.id,a.E.AtoZ),":invalidate"),this.onFoldersInvalidate),Ye(et(n.prototype),"bindListeners",this).call(this)}},{key:"onError",value:function(e){switch(e.type){case l.h.Forbidden:o.Q.ErrorHelper.throw(new ae.gO);break;case l.h.NotFound:o.Q.ErrorHelper.throw(new ae.Zv)}}},{key:"appLinkAction",value:function(){return f.eX.LibraryEditor.FOLDER}},{key:"allowBulk",value:function(){return!0}},{key:"emptyStateType",value:function(){return h.ub.Folder}},{key:"emptyStateOptions",value:function(){return{heading:i.T.getPhrase(this.lang,"emptyStateHeading"),description:i.T.getPhrase(this.lang,"emptyStateInfo",{url:fe.o.getHybridArticle(pe.s.AddFromOnline,pe.b.AddFromLite),classNames:"info-link"})}}},{key:"showFolderSource",value:function(){return!1}},{key:"getVideoCollectionSource",value:function(){return k.x_.Folder}},{key:"fetchModel",value:function(){this.model=this.libraryDataService.getFolder(this.collectionIdentifier.id)}},{key:"fetchVideoCollection",value:function(){this.videoCollection=this.videoDataService.getCollectionVideos(this.collectionIdentifier)}},{key:"onFoldersInvalidate",value:function(){this.fetchFolders(null,!0)}},{key:"fetchFolders",value:function(e,t){var n=this,o=new y.KX(this.collectionIdentifier.id,a.E.AtoZ,e);this.libraryDataService.getFolders(o,(function(e){t||!n.folders?n.folders=e:n.folders.add(e.models);var r=n.libraryDataService.getFoldersCursors(o);(null==r?void 0:r.next)?n.fetchFolders(r.next):n.render()}))}},{key:"onBeforeRender",value:function(){return this.folders||this.fetchFolders(),Ye(et(n.prototype),"onBeforeRender",this).call(this)&&!!this.folders}}]),n}(tt),ot=function(e){Ze(n,e);var t=$e(n);function n(){return ze(this,n),t.apply(this,arguments)}return Ge(n,[{key:"initialize",value:function(){this.seriesDataService=r.u.getInstance(f.Or.Series,this),Ye(et(n.prototype),"initialize",this).call(this)}},{key:"name",get:function(){return"SeriesView"}},{key:"lang",get:function(){return"libraryEditor.seriesView"}},{key:"componentType",get:function(){return v.U.Base}},{key:"regions",value:function(){var e=Ye(et(n.prototype),"regions",this).call(this);return e.subheading.partialLoading=h.LP.SeriesVideoListSubheading,delete e.header.partialLoading,delete e.childFolders.partialLoading,e}},{key:"bindListeners",value:function(){this.listenTo(f.Vk.SERIES,"".concat(f.M_.SERIES,":").concat(this.options.collectionIdentifier.id,":sync"),this.render),this.listenTo(f.Vk.SERIES,"".concat(f.M_.SERIES,":").concat(this.options.collectionIdentifier.id,":error"),this.onError),Ye(et(n.prototype),"bindListeners",this).call(this)}},{key:"onError",value:function(e){e.type===l.h.NotFound&&o.Q.ErrorHelper.throw(new ae.Ag)}},{key:"appLinkAction",value:function(){return f.eX.LibraryEditor.SERIES}},{key:"allowBulk",value:function(){return!1}},{key:"emptyStateType",value:function(){return h.ub.Series}},{key:"emptyStateOptions",value:function(){return{heading:i.T.getPhrase(this.lang,"emptyStateHeading"),description:i.T.getPhrase(this.lang,"emptyStateInfo",{url:fe.o.getHybridArticle(pe.s.AddFromOnline,pe.b.AddFromLite),classNames:"info-link"})}}},{key:"showFolderSource",value:function(){return!0}},{key:"getVideoCollectionSource",value:function(){return k.x_.Series}},{key:"fetchModel",value:function(){this.model=this.seriesDataService.getSeries(this.collectionIdentifier.id)}},{key:"fetchVideoCollection",value:function(){this.videoCollection=this.videoDataService.getSeriesVideos(this.collectionIdentifier,this.libraryCollection.pluck("id"))}}]),n}(tt)},57085:function(e,t,n){"use strict";n.d(t,{n:function(){return P}});var o=n(31647),r=n(93933),i=n.n(r),l=n(86363),c=n.n(l);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){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,(void 0,r=function(e,t){if("object"!==a(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t);if("object"!==a(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(o.key,"string"),"symbol"===a(r)?r:String(r)),o)}var r}function f(e,t,n){return t&&u(e.prototype,t),n&&u(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function p(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&&d(e,t)}function d(e,t){return d=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},d(e,t)}function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,o=b(e);if(t){var r=b(this).constructor;n=Reflect.construct(o,arguments,r)}else n=o.apply(this,arguments);return y(this,n)}}function y(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)}function b(e){return b=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},b(e)}var v=function(e){p(n,e);var t=h(n);function n(){return s(this,n),t.apply(this,arguments)}return f(n,[{key:"name",get:function(){return"BreadcrumbItemComponent"}},{key:"template",get:function(){return c()}},{key:"tagName",get:function(){return"li"}},{key:"className",get:function(){var e="breadcrumb-item";return this.model.get("active")&&(e+=" active"),e}},{key:"attributes",get:function(){return this.model.get("active")?{"aria-current":"page"}:{}}},{key:"appLinks",get:function(){return this.model.get("active")?{}:{a:this.model.get("appLink")}}},{key:"viewOptions",value:function(){return{isActive:this.model.get("active")}}}]),n}(o.Q.Component),m=function(e){p(n,e);var t=h(n);function n(){return s(this,n),t.apply(this,arguments)}return f(n,[{key:"name",get:function(){return"BreadcrumbComponentCollection"}},{key:"tagName",get:function(){return"ol"}},{key:"className",get:function(){return"breadcrumb m-0 p-0"}},{key:"childView",get:function(){return v}}]),n}(o.Q.ComponentCollection),g=n(22557),k=n(48090);function w(e){return w="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},w(e)}function O(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,(void 0,r=function(e,t){if("object"!==w(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t);if("object"!==w(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(o.key,"string"),"symbol"===w(r)?r:String(r)),o)}var r}function S(e,t){return S=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},S(e,t)}function E(e,t){if(t&&("object"===w(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)}function C(e){return C=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},C(e)}var P=function(e){!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&&S(e,t)}(a,e);var t,n,r,l,c=(r=a,l=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=C(r);if(l){var n=C(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return E(this,e)});function a(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),c.call(this,e)}return t=a,(n=[{key:"initialize",value:function(){this.getBreadcrumbs()}},{key:"name",get:function(){return"BreadcrumbsComponent"}},{key:"template",get:function(){return i()}},{key:"className",get:function(){return"d-inline-block"}},{key:"regions",value:function(){return{breadcrumbs:".breadcrumbs-region"}}},{key:"defaults",get:function(){return{customBreadcrumbs:[]}}},{key:"getBreadcrumbs",value:function(){var e=this;this.breadcrumbCollection=new o.Q.Collection([]);var t,n=this.options.folder;do{if(!n)break;if(t=g.P.getParent(n.id,this.options.libraries),this.breadcrumbCollection.add(this.getBreadcrumb(n,!!t),{at:0}),!t)break;n=t}while(t);this.options.video&&this.breadcrumbCollection.add({name:this.options.video.get("name"),appLink:{application:k.OV.LIBRARY_EDITOR,action:k.eX.LibraryEditor.VIDEO_DETAILS,args:[this.options.video.id]}}),this.options.customBreadcrumbs&&this.options.customBreadcrumbs.forEach((function(t){return e.breadcrumbCollection.add(t)})),this.breadcrumbCollection.length&&this.breadcrumbCollection.last().set("active",!this.options.enableLastItemAppLink)}},{key:"getBreadcrumb",value:function(e,t){var n=t?k.eX.LibraryEditor.FOLDER:k.eX.LibraryEditor.LIBRARY;return{name:e.get("name"),appLink:{application:k.OV.LIBRARY_EDITOR,action:n,args:[e.id]}}}},{key:"onRender",value:function(){var e=new m({collection:this.breadcrumbCollection});this.showChildView("breadcrumbs",e)}}])&&O(t.prototype,n),Object.defineProperty(t,"prototype",{writable:!1}),a}(o.Q.Component)},99186:function(e,t,n){var o=n(32227);e.exports=(o.default||o).template({1:function(e,t,n,o,r){return"disabled"},compiler:[8,">= 4.3.0"],main:function(e,t,n,o,r){e.propertyIsEnumerable;var i,l=null!=t?t:e.nullContext||{},c=e.hooks.helperMissing,a=e.escapeExpression;return'<div class="p-3">\n <a class="btn previous-applink btn-outline-dark '+(null!=(i=n.unless.call(l,null!=(i=null!=(i=null!=t?t.options:t)?i.cursors:i)?i.previous:i,{name:"unless",hash:{},fn:e.program(1,r,0),inverse:e.noop,data:r}))?i:"")+'">'+a((n.lang||t&&t.lang||c).call(l,"previous",{name:"lang",hash:{},data:r}))+'</a>\n <a class="btn next-applink btn-outline-dark '+(null!=(i=n.unless.call(l,null!=(i=null!=(i=null!=t?t.options:t)?i.cursors:i)?i.next:i,{name:"unless",hash:{},fn:e.program(1,r,0),inverse:e.noop,data:r}))?i:"")+'">'+a((n.lang||t&&t.lang||c).call(l,"next",{name:"lang",hash:{},data:r}))+"</a>\n</div>"},useData:!0})},85552:function(e,t,n){var o=n(32227);e.exports=(o.default||o).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,o,r){var i;return e.propertyIsEnumerable,'<h1 class="text-white position-absolute m-0">\n '+e.escapeExpression("function"==typeof(i=null!=(i=n.name||(null!=t?t.name:t))?i:e.hooks.helperMissing)?i.call(null!=t?t:e.nullContext||{},{name:"name",hash:{},data:r}):i)+'\n</h1>\n<div class="options-region"></div>'},useData:!0})},53370:function(e,t,n){var o=n(32227);e.exports=(o.default||o).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,o,r){var i;return e.propertyIsEnumerable,'<button class="btn btn-outline-dark dropdown-toggle" type="button" id="sortSelectButton" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">\n '+e.escapeExpression("function"==typeof(i=null!=(i=n.name||(null!=t?t.name:t))?i:e.hooks.helperMissing)?i.call(null!=t?t:e.nullContext||{},{name:"name",hash:{},data:r}):i)+'\n</button>\n<div class="dropdown-menu-region"></div>'},useData:!0})},73368:function(e,t,n){var o=n(32227);e.exports=(o.default||o).template({1:function(e,t,n,o,r){return"pl-2"},3:function(e,t,n,o,r){return"cursor-pointer"},5:function(e,t,n,o,r){e.propertyIsEnumerable;var i,l=e.lambda,c=e.escapeExpression;return' <div class="'+c(l(null!=(i=null!=(i=null!=t?t.options:t)?i.styles:i)?i.svgContainer:i,t))+" "+c(l(null!=(i=null!=t?t.options:t)?i.caretClass:i,t))+'">\n '+(null!=(i=l(null!=(i=null!=t?t.options:t)?i.caretSvg:i,t))?i:"")+"\n </div>\n"},7:function(e,t,n,o,r){var i;return e.propertyIsEnumerable,' <div class="d-flex justify-content-end justify-self-end px-2 expand-toggle">\n <span class="info-link d-inline-block">\n'+(null!=(i=n.if.call(null!=t?t:e.nullContext||{},null!=(i=null!=t?t.options:t)?i.isExpanded:i,{name:"if",hash:{},fn:e.program(8,r,0),inverse:e.program(10,r,0),data:r}))?i:"")+" </span>\n </div>\n"},8:function(e,t,n,o,r){return e.propertyIsEnumerable," "+e.escapeExpression((n.lang||t&&t.lang||e.hooks.helperMissing).call(null!=t?t:e.nullContext||{},"seeLess",{name:"lang",hash:{},data:r}))+"\n"},10:function(e,t,n,o,r){var i;return e.propertyIsEnumerable," "+e.escapeExpression((n.lang||t&&t.lang||e.hooks.helperMissing).call(null!=t?t:e.nullContext||{},"seeAll",{name:"lang",hash:{smartCount:null!=(i=null!=t?t.options:t)?i.count:i},data:r}))+"\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,o,r){e.propertyIsEnumerable;var i,l=null!=t?t:e.nullContext||{},c=e.escapeExpression;return'<div class="d-flex justify-content-between align-items-center">\n <div class="d-inline-flex align-items-center mb-2 expand-toggle '+(null!=(i=n.if.call(l,null!=(i=null!=t?t.options:t)?i.forceExpanded:i,{name:"if",hash:{},fn:e.program(1,r,0),inverse:e.program(3,r,0),data:r}))?i:"")+'">\n'+(null!=(i=n.unless.call(l,null!=(i=null!=t?t.options:t)?i.forceExpanded:i,{name:"unless",hash:{},fn:e.program(5,r,0),inverse:e.noop,data:r}))?i:"")+' <h2 class="h4 mb-0">'+c((n.lang||t&&t.lang||e.hooks.helperMissing).call(l,"folders",{name:"lang",hash:{},data:r}))+" ("+c(e.lambda(null!=(i=null!=t?t.options:t)?i.count:i,t))+")</h2>\n </div>\n"+(null!=(i=n.unless.call(l,null!=(i=null!=t?t.options:t)?i.forceExpanded:i,{name:"unless",hash:{},fn:e.program(7,r,0),inverse:e.noop,data:r}))?i:"")+'</div>\n<div class="subfolders-region"></div>'},useData:!0})},8420:function(e,t,n){var o=n(32227);e.exports=(o.default||o).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,o,r){return'<div class="py-3 border-bottom">\n <div class="breadcrumbs-region d-inline-flex align-items-center"></div>\n</div>'},useData:!0})},56846:function(e,t,n){var o=n(32227);e.exports=(o.default||o).template({1:function(e,t,n,o,r){return e.propertyIsEnumerable,'<h2 class="h4">'+e.escapeExpression((n.lang||t&&t.lang||e.hooks.helperMissing).call(null!=t?t:e.nullContext||{},"videos",{name:"lang",hash:{},data:r}))+"</h2>"},3:function(e,t,n,o,r){return"pt-2"},compiler:[8,">= 4.3.0"],main:function(e,t,n,o,r){e.propertyIsEnumerable;var i,l=null!=t?t:e.nullContext||{};return(null!=(i=n.if.call(l,null!=(i=null!=t?t.options:t)?i.showHeading:i,{name:"if",hash:{},fn:e.program(1,r,0),inverse:e.noop,data:r}))?i:"")+'\n<div class="d-flex justify-content-between align-items-center pb-2 '+(null!=(i=n.if.call(l,null!=(i=null!=t?t.options:t)?i.showHeading:i,{name:"if",hash:{},fn:e.program(3,r,0),inverse:e.noop,data:r}))?i:"")+'">\n <div class="d-inline-flex justify-content-start">\n <div class="check-all-region d-inline-flex align-items-center"></div>\n <div class="bulk-actions-region"></div>\n </div>\n <div class="sorting-region"></div>\n</div>'},useData:!0})},93089:function(e,t,n){var o=n(32227);e.exports=(o.default||o).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,o,r){return'<div class="banner-region"></div>\n<div class="header-region"></div>\n<div class="child-folders-region"></div>\n<div class="subheading-region"></div>\n<div class="video-list-region"></div>\n<div class="pagination-region"></div>'},useData:!0})},86363:function(e,t,n){var o=n(32227);e.exports=(o.default||o).template({1:function(e,t,n,o,r){var i;return e.propertyIsEnumerable,'<span class="font-weight-bolder">'+e.escapeExpression("function"==typeof(i=null!=(i=n.name||(null!=t?t.name:t))?i:e.hooks.helperMissing)?i.call(null!=t?t:e.nullContext||{},{name:"name",hash:{},data:r}):i)+"</span>\n"},3:function(e,t,n,o,r){var i;return e.propertyIsEnumerable,"<a>"+e.escapeExpression("function"==typeof(i=null!=(i=n.name||(null!=t?t.name:t))?i:e.hooks.helperMissing)?i.call(null!=t?t:e.nullContext||{},{name:"name",hash:{},data:r}):i)+"</a>\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,o,r){var i;return e.propertyIsEnumerable,null!=(i=n.if.call(null!=t?t:e.nullContext||{},null!=(i=null!=t?t.options:t)?i.isActive:i,{name:"if",hash:{},fn:e.program(1,r,0),inverse:e.program(3,r,0),data:r}))?i:""},useData:!0})},93933:function(e,t,n){var o=n(32227);e.exports=(o.default||o).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,o,r){return'<nav class="breadcrumbs-region" aria-label="breadcrumb"></nav>'},useData:!0})},34670:function(e,t,n){var o=n(32227);e.exports=(o.default||o).template({1:function(e,t,n,o,r){return"disabled"},compiler:[8,">= 4.3.0"],main:function(e,t,n,o,r){e.propertyIsEnumerable;var i,l=null!=t?t:e.nullContext||{};return'<button\n class="dropdown-toggle btn btn-outline-dark ml-2 '+(null!=(i=n.unless.call(l,null!=(i=null!=t?t.options:t)?i.enabled:i,{name:"unless",hash:{},fn:e.program(1,r,0),inverse:e.noop,data:r}))?i:"")+'"\n type="button"\n id="bulkActions"\n data-toggle="dropdown"\n aria-haspopup="true"\n aria-expanded="false"\n '+(null!=(i=n.unless.call(l,null!=(i=null!=t?t.options:t)?i.enabled:i,{name:"unless",hash:{},fn:e.program(1,r,0),inverse:e.noop,data:r}))?i:"")+"\n>\n "+e.escapeExpression((n.lang||t&&t.lang||e.hooks.helperMissing).call(l,"options",{name:"lang",hash:{},data:r}))+'\n</button>\n<div class="dropdown-menu-region"></div>'},useData:!0})}}]);
@@ -1,2 +0,0 @@
1
- /*! For license information please see 1934-2a68903c81.chunk.js.LICENSE.txt */
2
- (self.webpackChunk_clickview_library_editor=self.webpackChunk_clickview_library_editor||[]).push([[1934],{51934:function(t){t.exports=function(){"use strict";function t(e){return t="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},t(e)}function e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){for(var i=0;i<e.length;i++){var a=e[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,a.key,a)}}function a(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}function n(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,a)}return i}function o(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?n(i,!0).forEach((function(e){a(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):n(i).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}function r(t){return function(t){if(Array.isArray(t)){for(var e=0,i=new Array(t.length);e<t.length;e++)i[e]=t[e];return i}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}var h="undefined"!=typeof window&&void 0!==window.document,s=h?window:{},c=!!h&&"ontouchstart"in s.document.documentElement,l=!!h&&"PointerEvent"in s,d="cropper",p="all",u="crop",m="move",g="zoom",f="e",v="w",w="s",b="n",x="ne",y="nw",M="se",C="sw",D="".concat(d,"-crop"),k="".concat(d,"-disabled"),B="".concat(d,"-hidden"),O="".concat(d,"-hide"),T="".concat(d,"-invisible"),E="".concat(d,"-modal"),W="".concat(d,"-move"),N="".concat(d,"Action"),H="".concat(d,"Preview"),L="crop",z="move",Y="none",X="crop",R="cropend",S="cropmove",A="cropstart",j="dblclick",P=l?"pointerdown":c?"touchstart":"mousedown",I=l?"pointermove":c?"touchmove":"mousemove",U=l?"pointerup pointercancel":c?"touchend touchcancel":"mouseup",q="ready",$="resize",_="wheel",Q="zoom",K="image/jpeg",Z=/^e|w|s|n|se|sw|ne|nw|all|crop|move|zoom$/,G=/^data:/,V=/^data:image\/jpeg;base64,/,F=/^img|canvas$/i,J={viewMode:0,dragMode:L,initialAspectRatio:NaN,aspectRatio:NaN,data:null,preview:"",responsive:!0,restore:!0,checkCrossOrigin:!0,checkOrientation:!0,modal:!0,guides:!0,center:!0,highlight:!0,background:!0,autoCrop:!0,autoCropArea:.8,movable:!0,rotatable:!0,scalable:!0,zoomable:!0,zoomOnTouch:!0,zoomOnWheel:!0,wheelZoomRatio:.1,cropBoxMovable:!0,cropBoxResizable:!0,toggleDragModeOnDblclick:!0,minCanvasWidth:0,minCanvasHeight:0,minCropBoxWidth:0,minCropBoxHeight:0,minContainerWidth:200,minContainerHeight:100,ready:null,cropstart:null,cropmove:null,cropend:null,crop:null,zoom:null},tt=Number.isNaN||s.isNaN;function et(t){return"number"==typeof t&&!tt(t)}var it=function(t){return t>0&&t<1/0};function at(t){return void 0===t}function nt(e){return"object"===t(e)&&null!==e}var ot=Object.prototype.hasOwnProperty;function rt(t){if(!nt(t))return!1;try{var e=t.constructor,i=e.prototype;return e&&i&&ot.call(i,"isPrototypeOf")}catch(t){return!1}}function ht(t){return"function"==typeof t}var st=Array.prototype.slice;function ct(t){return Array.from?Array.from(t):st.call(t)}function lt(t,e){return t&&ht(e)&&(Array.isArray(t)||et(t.length)?ct(t).forEach((function(i,a){e.call(t,i,a,t)})):nt(t)&&Object.keys(t).forEach((function(i){e.call(t,t[i],i,t)}))),t}var dt=Object.assign||function(t){for(var e=arguments.length,i=new Array(e>1?e-1:0),a=1;a<e;a++)i[a-1]=arguments[a];return nt(t)&&i.length>0&&i.forEach((function(e){nt(e)&&Object.keys(e).forEach((function(i){t[i]=e[i]}))})),t},pt=/\.\d*(?:0|9){12}\d*$/;function ut(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1e11;return pt.test(t)?Math.round(t*e)/e:t}var mt=/^width|height|left|top|marginLeft|marginTop$/;function gt(t,e){var i=t.style;lt(e,(function(t,e){mt.test(e)&&et(t)&&(t="".concat(t,"px")),i[e]=t}))}function ft(t,e){if(e)if(et(t.length))lt(t,(function(t){ft(t,e)}));else if(t.classList)t.classList.add(e);else{var i=t.className.trim();i?i.indexOf(e)<0&&(t.className="".concat(i," ").concat(e)):t.className=e}}function vt(t,e){e&&(et(t.length)?lt(t,(function(t){vt(t,e)})):t.classList?t.classList.remove(e):t.className.indexOf(e)>=0&&(t.className=t.className.replace(e,"")))}function wt(t,e,i){e&&(et(t.length)?lt(t,(function(t){wt(t,e,i)})):i?ft(t,e):vt(t,e))}var bt=/([a-z\d])([A-Z])/g;function xt(t){return t.replace(bt,"$1-$2").toLowerCase()}function yt(t,e){return nt(t[e])?t[e]:t.dataset?t.dataset[e]:t.getAttribute("data-".concat(xt(e)))}function Mt(t,e,i){nt(i)?t[e]=i:t.dataset?t.dataset[e]=i:t.setAttribute("data-".concat(xt(e)),i)}var Ct=/\s\s*/,Dt=function(){var t=!1;if(h){var e=!1,i=function(){},a=Object.defineProperty({},"once",{get:function(){return t=!0,e},set:function(t){e=t}});s.addEventListener("test",i,a),s.removeEventListener("test",i,a)}return t}();function kt(t,e,i){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},n=i;e.trim().split(Ct).forEach((function(e){if(!Dt){var o=t.listeners;o&&o[e]&&o[e][i]&&(n=o[e][i],delete o[e][i],0===Object.keys(o[e]).length&&delete o[e],0===Object.keys(o).length&&delete t.listeners)}t.removeEventListener(e,n,a)}))}function Bt(t,e,i){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},n=i;e.trim().split(Ct).forEach((function(e){if(a.once&&!Dt){var o=t.listeners,r=void 0===o?{}:o;n=function(){delete r[e][i],t.removeEventListener(e,n,a);for(var o=arguments.length,h=new Array(o),s=0;s<o;s++)h[s]=arguments[s];i.apply(t,h)},r[e]||(r[e]={}),r[e][i]&&t.removeEventListener(e,r[e][i],a),r[e][i]=n,t.listeners=r}t.addEventListener(e,n,a)}))}function Ot(t,e,i){var a;return ht(Event)&&ht(CustomEvent)?a=new CustomEvent(e,{detail:i,bubbles:!0,cancelable:!0}):(a=document.createEvent("CustomEvent")).initCustomEvent(e,!0,!0,i),t.dispatchEvent(a)}function Tt(t){var e=t.getBoundingClientRect();return{left:e.left+(window.pageXOffset-document.documentElement.clientLeft),top:e.top+(window.pageYOffset-document.documentElement.clientTop)}}var Et=s.location,Wt=/^(\w+:)\/\/([^:/?#]*):?(\d*)/i;function Nt(t){var e=t.match(Wt);return null!==e&&(e[1]!==Et.protocol||e[2]!==Et.hostname||e[3]!==Et.port)}function Ht(t){var e="timestamp=".concat((new Date).getTime());return t+(-1===t.indexOf("?")?"?":"&")+e}function Lt(t){var e=t.rotate,i=t.scaleX,a=t.scaleY,n=t.translateX,o=t.translateY,r=[];et(n)&&0!==n&&r.push("translateX(".concat(n,"px)")),et(o)&&0!==o&&r.push("translateY(".concat(o,"px)")),et(e)&&0!==e&&r.push("rotate(".concat(e,"deg)")),et(i)&&1!==i&&r.push("scaleX(".concat(i,")")),et(a)&&1!==a&&r.push("scaleY(".concat(a,")"));var h=r.length?r.join(" "):"none";return{WebkitTransform:h,msTransform:h,transform:h}}function zt(t,e){var i=t.pageX,a=t.pageY,n={endX:i,endY:a};return e?n:o({startX:i,startY:a},n)}function Yt(t){var e=t.aspectRatio,i=t.height,a=t.width,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"contain",o=it(a),r=it(i);if(o&&r){var h=i*e;"contain"===n&&h>a||"cover"===n&&h<a?i=a/e:a=i*e}else o?i=a/e:r&&(a=i*e);return{width:a,height:i}}function Xt(t,e,i,a){var n=e.aspectRatio,o=e.naturalWidth,h=e.naturalHeight,s=e.rotate,c=void 0===s?0:s,l=e.scaleX,d=void 0===l?1:l,p=e.scaleY,u=void 0===p?1:p,m=i.aspectRatio,g=i.naturalWidth,f=i.naturalHeight,v=a.fillColor,w=void 0===v?"transparent":v,b=a.imageSmoothingEnabled,x=void 0===b||b,y=a.imageSmoothingQuality,M=void 0===y?"low":y,C=a.maxWidth,D=void 0===C?1/0:C,k=a.maxHeight,B=void 0===k?1/0:k,O=a.minWidth,T=void 0===O?0:O,E=a.minHeight,W=void 0===E?0:E,N=document.createElement("canvas"),H=N.getContext("2d"),L=Yt({aspectRatio:m,width:D,height:B}),z=Yt({aspectRatio:m,width:T,height:W},"cover"),Y=Math.min(L.width,Math.max(z.width,g)),X=Math.min(L.height,Math.max(z.height,f)),R=Yt({aspectRatio:n,width:D,height:B}),S=Yt({aspectRatio:n,width:T,height:W},"cover"),A=Math.min(R.width,Math.max(S.width,o)),j=Math.min(R.height,Math.max(S.height,h)),P=[-A/2,-j/2,A,j];return N.width=ut(Y),N.height=ut(X),H.fillStyle=w,H.fillRect(0,0,Y,X),H.save(),H.translate(Y/2,X/2),H.rotate(c*Math.PI/180),H.scale(d,u),H.imageSmoothingEnabled=x,H.imageSmoothingQuality=M,H.drawImage.apply(H,[t].concat(r(P.map((function(t){return Math.floor(ut(t))}))))),H.restore(),N}var Rt=String.fromCharCode;var St=/^data:.*,/;function At(t){var e,i=new DataView(t);try{var a,n,o;if(255===i.getUint8(0)&&216===i.getUint8(1))for(var r=i.byteLength,h=2;h+1<r;){if(255===i.getUint8(h)&&225===i.getUint8(h+1)){n=h;break}h+=1}if(n){var s=n+10;if("Exif"===function(t,e,i){var a="";i+=e;for(var n=e;n<i;n+=1)a+=Rt(t.getUint8(n));return a}(i,n+4,4)){var c=i.getUint16(s);if(((a=18761===c)||19789===c)&&42===i.getUint16(s+2,a)){var l=i.getUint32(s+4,a);l>=8&&(o=s+l)}}}if(o){var d,p,u=i.getUint16(o,a);for(p=0;p<u;p+=1)if(d=o+12*p+2,274===i.getUint16(d,a)){d+=8,e=i.getUint16(d,a),i.setUint16(d,1,a);break}}}catch(t){e=1}return e}var jt={render:function(){this.initContainer(),this.initCanvas(),this.initCropBox(),this.renderCanvas(),this.cropped&&this.renderCropBox()},initContainer:function(){var t=this.element,e=this.options,i=this.container,a=this.cropper;ft(a,B),vt(t,B);var n={width:Math.max(i.offsetWidth,Number(e.minContainerWidth)||200),height:Math.max(i.offsetHeight,Number(e.minContainerHeight)||100)};this.containerData=n,gt(a,{width:n.width,height:n.height}),ft(t,B),vt(a,B)},initCanvas:function(){var t=this.containerData,e=this.imageData,i=this.options.viewMode,a=Math.abs(e.rotate)%180==90,n=a?e.naturalHeight:e.naturalWidth,o=a?e.naturalWidth:e.naturalHeight,r=n/o,h=t.width,s=t.height;t.height*r>t.width?3===i?h=t.height*r:s=t.width/r:3===i?s=t.width/r:h=t.height*r;var c={aspectRatio:r,naturalWidth:n,naturalHeight:o,width:h,height:s};c.left=(t.width-h)/2,c.top=(t.height-s)/2,c.oldLeft=c.left,c.oldTop=c.top,this.canvasData=c,this.limited=1===i||2===i,this.limitCanvas(!0,!0),this.initialImageData=dt({},e),this.initialCanvasData=dt({},c)},limitCanvas:function(t,e){var i=this.options,a=this.containerData,n=this.canvasData,o=this.cropBoxData,r=i.viewMode,h=n.aspectRatio,s=this.cropped&&o;if(t){var c=Number(i.minCanvasWidth)||0,l=Number(i.minCanvasHeight)||0;r>1?(c=Math.max(c,a.width),l=Math.max(l,a.height),3===r&&(l*h>c?c=l*h:l=c/h)):r>0&&(c?c=Math.max(c,s?o.width:0):l?l=Math.max(l,s?o.height:0):s&&(c=o.width,(l=o.height)*h>c?c=l*h:l=c/h));var d=Yt({aspectRatio:h,width:c,height:l});c=d.width,l=d.height,n.minWidth=c,n.minHeight=l,n.maxWidth=1/0,n.maxHeight=1/0}if(e)if(r>(s?0:1)){var p=a.width-n.width,u=a.height-n.height;n.minLeft=Math.min(0,p),n.minTop=Math.min(0,u),n.maxLeft=Math.max(0,p),n.maxTop=Math.max(0,u),s&&this.limited&&(n.minLeft=Math.min(o.left,o.left+(o.width-n.width)),n.minTop=Math.min(o.top,o.top+(o.height-n.height)),n.maxLeft=o.left,n.maxTop=o.top,2===r&&(n.width>=a.width&&(n.minLeft=Math.min(0,p),n.maxLeft=Math.max(0,p)),n.height>=a.height&&(n.minTop=Math.min(0,u),n.maxTop=Math.max(0,u))))}else n.minLeft=-n.width,n.minTop=-n.height,n.maxLeft=a.width,n.maxTop=a.height},renderCanvas:function(t,e){var i=this.canvasData,a=this.imageData;if(e){var n=function(t){var e=t.width,i=t.height,a=t.degree;if(90==(a=Math.abs(a)%180))return{width:i,height:e};var n=a%90*Math.PI/180,o=Math.sin(n),r=Math.cos(n),h=e*r+i*o,s=e*o+i*r;return a>90?{width:s,height:h}:{width:h,height:s}}({width:a.naturalWidth*Math.abs(a.scaleX||1),height:a.naturalHeight*Math.abs(a.scaleY||1),degree:a.rotate||0}),o=n.width,r=n.height,h=i.width*(o/i.naturalWidth),s=i.height*(r/i.naturalHeight);i.left-=(h-i.width)/2,i.top-=(s-i.height)/2,i.width=h,i.height=s,i.aspectRatio=o/r,i.naturalWidth=o,i.naturalHeight=r,this.limitCanvas(!0,!1)}(i.width>i.maxWidth||i.width<i.minWidth)&&(i.left=i.oldLeft),(i.height>i.maxHeight||i.height<i.minHeight)&&(i.top=i.oldTop),i.width=Math.min(Math.max(i.width,i.minWidth),i.maxWidth),i.height=Math.min(Math.max(i.height,i.minHeight),i.maxHeight),this.limitCanvas(!1,!0),i.left=Math.min(Math.max(i.left,i.minLeft),i.maxLeft),i.top=Math.min(Math.max(i.top,i.minTop),i.maxTop),i.oldLeft=i.left,i.oldTop=i.top,gt(this.canvas,dt({width:i.width,height:i.height},Lt({translateX:i.left,translateY:i.top}))),this.renderImage(t),this.cropped&&this.limited&&this.limitCropBox(!0,!0)},renderImage:function(t){var e=this.canvasData,i=this.imageData,a=i.naturalWidth*(e.width/e.naturalWidth),n=i.naturalHeight*(e.height/e.naturalHeight);dt(i,{width:a,height:n,left:(e.width-a)/2,top:(e.height-n)/2}),gt(this.image,dt({width:i.width,height:i.height},Lt(dt({translateX:i.left,translateY:i.top},i)))),t&&this.output()},initCropBox:function(){var t=this.options,e=this.canvasData,i=t.aspectRatio||t.initialAspectRatio,a=Number(t.autoCropArea)||.8,n={width:e.width,height:e.height};i&&(e.height*i>e.width?n.height=n.width/i:n.width=n.height*i),this.cropBoxData=n,this.limitCropBox(!0,!0),n.width=Math.min(Math.max(n.width,n.minWidth),n.maxWidth),n.height=Math.min(Math.max(n.height,n.minHeight),n.maxHeight),n.width=Math.max(n.minWidth,n.width*a),n.height=Math.max(n.minHeight,n.height*a),n.left=e.left+(e.width-n.width)/2,n.top=e.top+(e.height-n.height)/2,n.oldLeft=n.left,n.oldTop=n.top,this.initialCropBoxData=dt({},n)},limitCropBox:function(t,e){var i=this.options,a=this.containerData,n=this.canvasData,o=this.cropBoxData,r=this.limited,h=i.aspectRatio;if(t){var s=Number(i.minCropBoxWidth)||0,c=Number(i.minCropBoxHeight)||0,l=r?Math.min(a.width,n.width,n.width+n.left,a.width-n.left):a.width,d=r?Math.min(a.height,n.height,n.height+n.top,a.height-n.top):a.height;s=Math.min(s,a.width),c=Math.min(c,a.height),h&&(s&&c?c*h>s?c=s/h:s=c*h:s?c=s/h:c&&(s=c*h),d*h>l?d=l/h:l=d*h),o.minWidth=Math.min(s,l),o.minHeight=Math.min(c,d),o.maxWidth=l,o.maxHeight=d}e&&(r?(o.minLeft=Math.max(0,n.left),o.minTop=Math.max(0,n.top),o.maxLeft=Math.min(a.width,n.left+n.width)-o.width,o.maxTop=Math.min(a.height,n.top+n.height)-o.height):(o.minLeft=0,o.minTop=0,o.maxLeft=a.width-o.width,o.maxTop=a.height-o.height))},renderCropBox:function(){var t=this.options,e=this.containerData,i=this.cropBoxData;(i.width>i.maxWidth||i.width<i.minWidth)&&(i.left=i.oldLeft),(i.height>i.maxHeight||i.height<i.minHeight)&&(i.top=i.oldTop),i.width=Math.min(Math.max(i.width,i.minWidth),i.maxWidth),i.height=Math.min(Math.max(i.height,i.minHeight),i.maxHeight),this.limitCropBox(!1,!0),i.left=Math.min(Math.max(i.left,i.minLeft),i.maxLeft),i.top=Math.min(Math.max(i.top,i.minTop),i.maxTop),i.oldLeft=i.left,i.oldTop=i.top,t.movable&&t.cropBoxMovable&&Mt(this.face,N,i.width>=e.width&&i.height>=e.height?m:p),gt(this.cropBox,dt({width:i.width,height:i.height},Lt({translateX:i.left,translateY:i.top}))),this.cropped&&this.limited&&this.limitCanvas(!0,!0),this.disabled||this.output()},output:function(){this.preview(),Ot(this.element,X,this.getData())}},Pt={initPreview:function(){var t=this.element,e=this.crossOrigin,i=this.options.preview,a=e?this.crossOriginUrl:this.url,n=t.alt||"The image to preview",o=document.createElement("img");if(e&&(o.crossOrigin=e),o.src=a,o.alt=n,this.viewBox.appendChild(o),this.viewBoxImage=o,i){var r=i;"string"==typeof i?r=t.ownerDocument.querySelectorAll(i):i.querySelector&&(r=[i]),this.previews=r,lt(r,(function(t){var i=document.createElement("img");Mt(t,H,{width:t.offsetWidth,height:t.offsetHeight,html:t.innerHTML}),e&&(i.crossOrigin=e),i.src=a,i.alt=n,i.style.cssText='display:block;width:100%;height:auto;min-width:0!important;min-height:0!important;max-width:none!important;max-height:none!important;image-orientation:0deg!important;"',t.innerHTML="",t.appendChild(i)}))}},resetPreview:function(){lt(this.previews,(function(t){var e=yt(t,H);gt(t,{width:e.width,height:e.height}),t.innerHTML=e.html,function(t,e){if(nt(t[e]))try{delete t[e]}catch(i){t[e]=void 0}else if(t.dataset)try{delete t.dataset[e]}catch(i){t.dataset[e]=void 0}else t.removeAttribute("data-".concat(xt(e)))}(t,H)}))},preview:function(){var t=this.imageData,e=this.canvasData,i=this.cropBoxData,a=i.width,n=i.height,o=t.width,r=t.height,h=i.left-e.left-t.left,s=i.top-e.top-t.top;this.cropped&&!this.disabled&&(gt(this.viewBoxImage,dt({width:o,height:r},Lt(dt({translateX:-h,translateY:-s},t)))),lt(this.previews,(function(e){var i=yt(e,H),c=i.width,l=i.height,d=c,p=l,u=1;a&&(p=n*(u=c/a)),n&&p>l&&(d=a*(u=l/n),p=l),gt(e,{width:d,height:p}),gt(e.getElementsByTagName("img")[0],dt({width:o*u,height:r*u},Lt(dt({translateX:-h*u,translateY:-s*u},t))))})))}},It={bind:function(){var t=this.element,e=this.options,i=this.cropper;ht(e.cropstart)&&Bt(t,A,e.cropstart),ht(e.cropmove)&&Bt(t,S,e.cropmove),ht(e.cropend)&&Bt(t,R,e.cropend),ht(e.crop)&&Bt(t,X,e.crop),ht(e.zoom)&&Bt(t,Q,e.zoom),Bt(i,P,this.onCropStart=this.cropStart.bind(this)),e.zoomable&&e.zoomOnWheel&&Bt(i,_,this.onWheel=this.wheel.bind(this),{passive:!1,capture:!0}),e.toggleDragModeOnDblclick&&Bt(i,j,this.onDblclick=this.dblclick.bind(this)),Bt(t.ownerDocument,I,this.onCropMove=this.cropMove.bind(this)),Bt(t.ownerDocument,U,this.onCropEnd=this.cropEnd.bind(this)),e.responsive&&Bt(window,$,this.onResize=this.resize.bind(this))},unbind:function(){var t=this.element,e=this.options,i=this.cropper;ht(e.cropstart)&&kt(t,A,e.cropstart),ht(e.cropmove)&&kt(t,S,e.cropmove),ht(e.cropend)&&kt(t,R,e.cropend),ht(e.crop)&&kt(t,X,e.crop),ht(e.zoom)&&kt(t,Q,e.zoom),kt(i,P,this.onCropStart),e.zoomable&&e.zoomOnWheel&&kt(i,_,this.onWheel,{passive:!1,capture:!0}),e.toggleDragModeOnDblclick&&kt(i,j,this.onDblclick),kt(t.ownerDocument,I,this.onCropMove),kt(t.ownerDocument,U,this.onCropEnd),e.responsive&&kt(window,$,this.onResize)}},Ut={resize:function(){var t=this.options,e=this.container,i=this.containerData,a=Number(t.minContainerWidth)||200,n=Number(t.minContainerHeight)||100;if(!(this.disabled||i.width<=a||i.height<=n)){var o,r,h=e.offsetWidth/i.width;1===h&&e.offsetHeight===i.height||(t.restore&&(o=this.getCanvasData(),r=this.getCropBoxData()),this.render(),t.restore&&(this.setCanvasData(lt(o,(function(t,e){o[e]=t*h}))),this.setCropBoxData(lt(r,(function(t,e){r[e]=t*h})))))}},dblclick:function(){var t,e;this.disabled||this.options.dragMode===Y||this.setDragMode((t=this.dragBox,e=D,(t.classList?t.classList.contains(e):t.className.indexOf(e)>-1)?z:L))},wheel:function(t){var e=this,i=Number(this.options.wheelZoomRatio)||.1,a=1;this.disabled||(t.preventDefault(),this.wheeling||(this.wheeling=!0,setTimeout((function(){e.wheeling=!1}),50),t.deltaY?a=t.deltaY>0?1:-1:t.wheelDelta?a=-t.wheelDelta/120:t.detail&&(a=t.detail>0?1:-1),this.zoom(-a*i,t)))},cropStart:function(t){var e=t.buttons,i=t.button;if(!(this.disabled||("mousedown"===t.type||"pointerdown"===t.type&&"mouse"===t.pointerType)&&(et(e)&&1!==e||et(i)&&0!==i||t.ctrlKey))){var a,n=this.options,o=this.pointers;t.changedTouches?lt(t.changedTouches,(function(t){o[t.identifier]=zt(t)})):o[t.pointerId||0]=zt(t),a=Object.keys(o).length>1&&n.zoomable&&n.zoomOnTouch?g:yt(t.target,N),Z.test(a)&&!1!==Ot(this.element,A,{originalEvent:t,action:a})&&(t.preventDefault(),this.action=a,this.cropping=!1,a===u&&(this.cropping=!0,ft(this.dragBox,E)))}},cropMove:function(t){var e=this.action;if(!this.disabled&&e){var i=this.pointers;t.preventDefault(),!1!==Ot(this.element,S,{originalEvent:t,action:e})&&(t.changedTouches?lt(t.changedTouches,(function(t){dt(i[t.identifier]||{},zt(t,!0))})):dt(i[t.pointerId||0]||{},zt(t,!0)),this.change(t))}},cropEnd:function(t){if(!this.disabled){var e=this.action,i=this.pointers;t.changedTouches?lt(t.changedTouches,(function(t){delete i[t.identifier]})):delete i[t.pointerId||0],e&&(t.preventDefault(),Object.keys(i).length||(this.action=""),this.cropping&&(this.cropping=!1,wt(this.dragBox,E,this.cropped&&this.options.modal)),Ot(this.element,R,{originalEvent:t,action:e}))}}},qt={change:function(t){var e,i=this.options,a=this.canvasData,n=this.containerData,r=this.cropBoxData,h=this.pointers,s=this.action,c=i.aspectRatio,l=r.left,d=r.top,D=r.width,k=r.height,O=l+D,T=d+k,E=0,W=0,N=n.width,H=n.height,L=!0;!c&&t.shiftKey&&(c=D&&k?D/k:1),this.limited&&(E=r.minLeft,W=r.minTop,N=E+Math.min(n.width,a.width,a.left+a.width),H=W+Math.min(n.height,a.height,a.top+a.height));var z=h[Object.keys(h)[0]],Y={x:z.endX-z.startX,y:z.endY-z.startY},X=function(t){switch(t){case f:O+Y.x>N&&(Y.x=N-O);break;case v:l+Y.x<E&&(Y.x=E-l);break;case b:d+Y.y<W&&(Y.y=W-d);break;case w:T+Y.y>H&&(Y.y=H-T)}};switch(s){case p:l+=Y.x,d+=Y.y;break;case f:if(Y.x>=0&&(O>=N||c&&(d<=W||T>=H))){L=!1;break}X(f),(D+=Y.x)<0&&(s=v,l-=D=-D),c&&(k=D/c,d+=(r.height-k)/2);break;case b:if(Y.y<=0&&(d<=W||c&&(l<=E||O>=N))){L=!1;break}X(b),k-=Y.y,d+=Y.y,k<0&&(s=w,d-=k=-k),c&&(D=k*c,l+=(r.width-D)/2);break;case v:if(Y.x<=0&&(l<=E||c&&(d<=W||T>=H))){L=!1;break}X(v),D-=Y.x,l+=Y.x,D<0&&(s=f,l-=D=-D),c&&(k=D/c,d+=(r.height-k)/2);break;case w:if(Y.y>=0&&(T>=H||c&&(l<=E||O>=N))){L=!1;break}X(w),(k+=Y.y)<0&&(s=b,d-=k=-k),c&&(D=k*c,l+=(r.width-D)/2);break;case x:if(c){if(Y.y<=0&&(d<=W||O>=N)){L=!1;break}X(b),k-=Y.y,d+=Y.y,D=k*c}else X(b),X(f),Y.x>=0?O<N?D+=Y.x:Y.y<=0&&d<=W&&(L=!1):D+=Y.x,Y.y<=0?d>W&&(k-=Y.y,d+=Y.y):(k-=Y.y,d+=Y.y);D<0&&k<0?(s=C,d-=k=-k,l-=D=-D):D<0?(s=y,l-=D=-D):k<0&&(s=M,d-=k=-k);break;case y:if(c){if(Y.y<=0&&(d<=W||l<=E)){L=!1;break}X(b),k-=Y.y,d+=Y.y,D=k*c,l+=r.width-D}else X(b),X(v),Y.x<=0?l>E?(D-=Y.x,l+=Y.x):Y.y<=0&&d<=W&&(L=!1):(D-=Y.x,l+=Y.x),Y.y<=0?d>W&&(k-=Y.y,d+=Y.y):(k-=Y.y,d+=Y.y);D<0&&k<0?(s=M,d-=k=-k,l-=D=-D):D<0?(s=x,l-=D=-D):k<0&&(s=C,d-=k=-k);break;case C:if(c){if(Y.x<=0&&(l<=E||T>=H)){L=!1;break}X(v),D-=Y.x,l+=Y.x,k=D/c}else X(w),X(v),Y.x<=0?l>E?(D-=Y.x,l+=Y.x):Y.y>=0&&T>=H&&(L=!1):(D-=Y.x,l+=Y.x),Y.y>=0?T<H&&(k+=Y.y):k+=Y.y;D<0&&k<0?(s=x,d-=k=-k,l-=D=-D):D<0?(s=M,l-=D=-D):k<0&&(s=y,d-=k=-k);break;case M:if(c){if(Y.x>=0&&(O>=N||T>=H)){L=!1;break}X(f),k=(D+=Y.x)/c}else X(w),X(f),Y.x>=0?O<N?D+=Y.x:Y.y>=0&&T>=H&&(L=!1):D+=Y.x,Y.y>=0?T<H&&(k+=Y.y):k+=Y.y;D<0&&k<0?(s=y,d-=k=-k,l-=D=-D):D<0?(s=C,l-=D=-D):k<0&&(s=x,d-=k=-k);break;case m:this.move(Y.x,Y.y),L=!1;break;case g:this.zoom(function(t){var e=o({},t),i=[];return lt(t,(function(t,a){delete e[a],lt(e,(function(e){var a=Math.abs(t.startX-e.startX),n=Math.abs(t.startY-e.startY),o=Math.abs(t.endX-e.endX),r=Math.abs(t.endY-e.endY),h=Math.sqrt(a*a+n*n),s=(Math.sqrt(o*o+r*r)-h)/h;i.push(s)}))})),i.sort((function(t,e){return Math.abs(t)<Math.abs(e)})),i[0]}(h),t),L=!1;break;case u:if(!Y.x||!Y.y){L=!1;break}e=Tt(this.cropper),l=z.startX-e.left,d=z.startY-e.top,D=r.minWidth,k=r.minHeight,Y.x>0?s=Y.y>0?M:x:Y.x<0&&(l-=D,s=Y.y>0?C:y),Y.y<0&&(d-=k),this.cropped||(vt(this.cropBox,B),this.cropped=!0,this.limited&&this.limitCropBox(!0,!0))}L&&(r.width=D,r.height=k,r.left=l,r.top=d,this.action=s,this.renderCropBox()),lt(h,(function(t){t.startX=t.endX,t.startY=t.endY}))}},$t={crop:function(){return!this.ready||this.cropped||this.disabled||(this.cropped=!0,this.limitCropBox(!0,!0),this.options.modal&&ft(this.dragBox,E),vt(this.cropBox,B),this.setCropBoxData(this.initialCropBoxData)),this},reset:function(){return this.ready&&!this.disabled&&(this.imageData=dt({},this.initialImageData),this.canvasData=dt({},this.initialCanvasData),this.cropBoxData=dt({},this.initialCropBoxData),this.renderCanvas(),this.cropped&&this.renderCropBox()),this},clear:function(){return this.cropped&&!this.disabled&&(dt(this.cropBoxData,{left:0,top:0,width:0,height:0}),this.cropped=!1,this.renderCropBox(),this.limitCanvas(!0,!0),this.renderCanvas(),vt(this.dragBox,E),ft(this.cropBox,B)),this},replace:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return!this.disabled&&t&&(this.isImg&&(this.element.src=t),e?(this.url=t,this.image.src=t,this.ready&&(this.viewBoxImage.src=t,lt(this.previews,(function(e){e.getElementsByTagName("img")[0].src=t})))):(this.isImg&&(this.replaced=!0),this.options.data=null,this.uncreate(),this.load(t))),this},enable:function(){return this.ready&&this.disabled&&(this.disabled=!1,vt(this.cropper,k)),this},disable:function(){return this.ready&&!this.disabled&&(this.disabled=!0,ft(this.cropper,k)),this},destroy:function(){var t=this.element;return t.cropper?(t.cropper=void 0,this.isImg&&this.replaced&&(t.src=this.originalUrl),this.uncreate(),this):this},move:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t,i=this.canvasData,a=i.left,n=i.top;return this.moveTo(at(t)?t:a+Number(t),at(e)?e:n+Number(e))},moveTo:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t,i=this.canvasData,a=!1;return t=Number(t),e=Number(e),this.ready&&!this.disabled&&this.options.movable&&(et(t)&&(i.left=t,a=!0),et(e)&&(i.top=e,a=!0),a&&this.renderCanvas(!0)),this},zoom:function(t,e){var i=this.canvasData;return t=(t=Number(t))<0?1/(1-t):1+t,this.zoomTo(i.width*t/i.naturalWidth,null,e)},zoomTo:function(t,e,i){var a=this.options,n=this.canvasData,o=n.width,r=n.height,h=n.naturalWidth,s=n.naturalHeight;if((t=Number(t))>=0&&this.ready&&!this.disabled&&a.zoomable){var c=h*t,l=s*t;if(!1===Ot(this.element,Q,{ratio:t,oldRatio:o/h,originalEvent:i}))return this;if(i){var d=this.pointers,p=Tt(this.cropper),u=d&&Object.keys(d).length?function(t){var e=0,i=0,a=0;return lt(t,(function(t){var n=t.startX,o=t.startY;e+=n,i+=o,a+=1})),{pageX:e/=a,pageY:i/=a}}(d):{pageX:i.pageX,pageY:i.pageY};n.left-=(c-o)*((u.pageX-p.left-n.left)/o),n.top-=(l-r)*((u.pageY-p.top-n.top)/r)}else rt(e)&&et(e.x)&&et(e.y)?(n.left-=(c-o)*((e.x-n.left)/o),n.top-=(l-r)*((e.y-n.top)/r)):(n.left-=(c-o)/2,n.top-=(l-r)/2);n.width=c,n.height=l,this.renderCanvas(!0)}return this},rotate:function(t){return this.rotateTo((this.imageData.rotate||0)+Number(t))},rotateTo:function(t){return et(t=Number(t))&&this.ready&&!this.disabled&&this.options.rotatable&&(this.imageData.rotate=t%360,this.renderCanvas(!0,!0)),this},scaleX:function(t){var e=this.imageData.scaleY;return this.scale(t,et(e)?e:1)},scaleY:function(t){var e=this.imageData.scaleX;return this.scale(et(e)?e:1,t)},scale:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t,i=this.imageData,a=!1;return t=Number(t),e=Number(e),this.ready&&!this.disabled&&this.options.scalable&&(et(t)&&(i.scaleX=t,a=!0),et(e)&&(i.scaleY=e,a=!0),a&&this.renderCanvas(!0,!0)),this},getData:function(){var t,e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],i=this.options,a=this.imageData,n=this.canvasData,o=this.cropBoxData;if(this.ready&&this.cropped){t={x:o.left-n.left,y:o.top-n.top,width:o.width,height:o.height};var r=a.width/a.naturalWidth;if(lt(t,(function(e,i){t[i]=e/r})),e){var h=Math.round(t.y+t.height),s=Math.round(t.x+t.width);t.x=Math.round(t.x),t.y=Math.round(t.y),t.width=s-t.x,t.height=h-t.y}}else t={x:0,y:0,width:0,height:0};return i.rotatable&&(t.rotate=a.rotate||0),i.scalable&&(t.scaleX=a.scaleX||1,t.scaleY=a.scaleY||1),t},setData:function(t){var e=this.options,i=this.imageData,a=this.canvasData,n={};if(this.ready&&!this.disabled&&rt(t)){var o=!1;e.rotatable&&et(t.rotate)&&t.rotate!==i.rotate&&(i.rotate=t.rotate,o=!0),e.scalable&&(et(t.scaleX)&&t.scaleX!==i.scaleX&&(i.scaleX=t.scaleX,o=!0),et(t.scaleY)&&t.scaleY!==i.scaleY&&(i.scaleY=t.scaleY,o=!0)),o&&this.renderCanvas(!0,!0);var r=i.width/i.naturalWidth;et(t.x)&&(n.left=t.x*r+a.left),et(t.y)&&(n.top=t.y*r+a.top),et(t.width)&&(n.width=t.width*r),et(t.height)&&(n.height=t.height*r),this.setCropBoxData(n)}return this},getContainerData:function(){return this.ready?dt({},this.containerData):{}},getImageData:function(){return this.sized?dt({},this.imageData):{}},getCanvasData:function(){var t=this.canvasData,e={};return this.ready&&lt(["left","top","width","height","naturalWidth","naturalHeight"],(function(i){e[i]=t[i]})),e},setCanvasData:function(t){var e=this.canvasData,i=e.aspectRatio;return this.ready&&!this.disabled&&rt(t)&&(et(t.left)&&(e.left=t.left),et(t.top)&&(e.top=t.top),et(t.width)?(e.width=t.width,e.height=t.width/i):et(t.height)&&(e.height=t.height,e.width=t.height*i),this.renderCanvas(!0)),this},getCropBoxData:function(){var t,e=this.cropBoxData;return this.ready&&this.cropped&&(t={left:e.left,top:e.top,width:e.width,height:e.height}),t||{}},setCropBoxData:function(t){var e,i,a=this.cropBoxData,n=this.options.aspectRatio;return this.ready&&this.cropped&&!this.disabled&&rt(t)&&(et(t.left)&&(a.left=t.left),et(t.top)&&(a.top=t.top),et(t.width)&&t.width!==a.width&&(e=!0,a.width=t.width),et(t.height)&&t.height!==a.height&&(i=!0,a.height=t.height),n&&(e?a.height=a.width/n:i&&(a.width=a.height*n)),this.renderCropBox()),this},getCroppedCanvas:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(!this.ready||!window.HTMLCanvasElement)return null;var e=this.canvasData,i=Xt(this.image,this.imageData,e,t);if(!this.cropped)return i;var a=this.getData(),n=a.x,o=a.y,h=a.width,s=a.height,c=i.width/Math.floor(e.naturalWidth);1!==c&&(n*=c,o*=c,h*=c,s*=c);var l=h/s,d=Yt({aspectRatio:l,width:t.maxWidth||1/0,height:t.maxHeight||1/0}),p=Yt({aspectRatio:l,width:t.minWidth||0,height:t.minHeight||0},"cover"),u=Yt({aspectRatio:l,width:t.width||(1!==c?i.width:h),height:t.height||(1!==c?i.height:s)}),m=u.width,g=u.height;m=Math.min(d.width,Math.max(p.width,m)),g=Math.min(d.height,Math.max(p.height,g));var f=document.createElement("canvas"),v=f.getContext("2d");f.width=ut(m),f.height=ut(g),v.fillStyle=t.fillColor||"transparent",v.fillRect(0,0,m,g);var w=t.imageSmoothingEnabled,b=void 0===w||w,x=t.imageSmoothingQuality;v.imageSmoothingEnabled=b,x&&(v.imageSmoothingQuality=x);var y,M,C,D,k,B,O=i.width,T=i.height,E=n,W=o;E<=-h||E>O?(E=0,y=0,C=0,k=0):E<=0?(C=-E,E=0,k=y=Math.min(O,h+E)):E<=O&&(C=0,k=y=Math.min(h,O-E)),y<=0||W<=-s||W>T?(W=0,M=0,D=0,B=0):W<=0?(D=-W,W=0,B=M=Math.min(T,s+W)):W<=T&&(D=0,B=M=Math.min(s,T-W));var N=[E,W,y,M];if(k>0&&B>0){var H=m/h;N.push(C*H,D*H,k*H,B*H)}return v.drawImage.apply(v,[i].concat(r(N.map((function(t){return Math.floor(ut(t))}))))),f},setAspectRatio:function(t){var e=this.options;return this.disabled||at(t)||(e.aspectRatio=Math.max(0,t)||NaN,this.ready&&(this.initCropBox(),this.cropped&&this.renderCropBox())),this},setDragMode:function(t){var e=this.options,i=this.dragBox,a=this.face;if(this.ready&&!this.disabled){var n=t===L,o=e.movable&&t===z;t=n||o?t:Y,e.dragMode=t,Mt(i,N,t),wt(i,D,n),wt(i,W,o),e.cropBoxMovable||(Mt(a,N,t),wt(a,D,n),wt(a,W,o))}return this}},_t=s.Cropper,Qt=function(){function t(i){var a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(e(this,t),!i||!F.test(i.tagName))throw new Error("The first argument is required and must be an <img> or <canvas> element.");this.element=i,this.options=dt({},J,rt(a)&&a),this.cropped=!1,this.disabled=!1,this.pointers={},this.ready=!1,this.reloading=!1,this.replaced=!1,this.sized=!1,this.sizing=!1,this.init()}return a=t,o=[{key:"noConflict",value:function(){return window.Cropper=_t,t}},{key:"setDefaults",value:function(t){dt(J,rt(t)&&t)}}],(n=[{key:"init",value:function(){var t,e=this.element,i=e.tagName.toLowerCase();if(!e.cropper){if(e.cropper=this,"img"===i){if(this.isImg=!0,t=e.getAttribute("src")||"",this.originalUrl=t,!t)return;t=e.src}else"canvas"===i&&window.HTMLCanvasElement&&(t=e.toDataURL());this.load(t)}}},{key:"load",value:function(t){var e,i,a,n,o=this;if(t){this.url=t,this.imageData={};var r=this.element,h=this.options;if(h.rotatable||h.scalable||(h.checkOrientation=!1),h.checkOrientation&&window.ArrayBuffer)if(G.test(t))V.test(t)?this.read((e=t.replace(St,""),i=atob(e),a=new ArrayBuffer(i.length),lt(n=new Uint8Array(a),(function(t,e){n[e]=i.charCodeAt(e)})),a)):this.clone();else{var s=new XMLHttpRequest,c=this.clone.bind(this);this.reloading=!0,this.xhr=s,s.onabort=c,s.onerror=c,s.ontimeout=c,s.onprogress=function(){s.getResponseHeader("content-type")!==K&&s.abort()},s.onload=function(){o.read(s.response)},s.onloadend=function(){o.reloading=!1,o.xhr=null},h.checkCrossOrigin&&Nt(t)&&r.crossOrigin&&(t=Ht(t)),s.open("GET",t),s.responseType="arraybuffer",s.withCredentials="use-credentials"===r.crossOrigin,s.send()}else this.clone()}}},{key:"read",value:function(t){var e=this.options,i=this.imageData,a=At(t),n=0,o=1,r=1;if(a>1){this.url=function(t,e){for(var i=[],a=new Uint8Array(t);a.length>0;)i.push(Rt.apply(null,ct(a.subarray(0,8192)))),a=a.subarray(8192);return"data:".concat(e,";base64,").concat(btoa(i.join("")))}(t,K);var h=function(t){var e=0,i=1,a=1;switch(t){case 2:i=-1;break;case 3:e=-180;break;case 4:a=-1;break;case 5:e=90,a=-1;break;case 6:e=90;break;case 7:e=90,i=-1;break;case 8:e=-90}return{rotate:e,scaleX:i,scaleY:a}}(a);n=h.rotate,o=h.scaleX,r=h.scaleY}e.rotatable&&(i.rotate=n),e.scalable&&(i.scaleX=o,i.scaleY=r),this.clone()}},{key:"clone",value:function(){var t=this.element,e=this.url,i=t.crossOrigin,a=e;this.options.checkCrossOrigin&&Nt(e)&&(i||(i="anonymous"),a=Ht(e)),this.crossOrigin=i,this.crossOriginUrl=a;var n=document.createElement("img");i&&(n.crossOrigin=i),n.src=a||e,n.alt=t.alt||"The image to crop",this.image=n,n.onload=this.start.bind(this),n.onerror=this.stop.bind(this),ft(n,O),t.parentNode.insertBefore(n,t.nextSibling)}},{key:"start",value:function(){var t=this,e=this.image;e.onload=null,e.onerror=null,this.sizing=!0;var i=s.navigator&&/(?:iPad|iPhone|iPod).*?AppleWebKit/i.test(s.navigator.userAgent),a=function(e,i){dt(t.imageData,{naturalWidth:e,naturalHeight:i,aspectRatio:e/i}),t.sizing=!1,t.sized=!0,t.build()};if(!e.naturalWidth||i){var n=document.createElement("img"),o=document.body||document.documentElement;this.sizingImage=n,n.onload=function(){a(n.width,n.height),i||o.removeChild(n)},n.src=e.src,i||(n.style.cssText="left:0;max-height:none!important;max-width:none!important;min-height:0!important;min-width:0!important;opacity:0;position:absolute;top:0;z-index:-1;",o.appendChild(n))}else a(e.naturalWidth,e.naturalHeight)}},{key:"stop",value:function(){var t=this.image;t.onload=null,t.onerror=null,t.parentNode.removeChild(t),this.image=null}},{key:"build",value:function(){if(this.sized&&!this.ready){var t=this.element,e=this.options,i=this.image,a=t.parentNode,n=document.createElement("div");n.innerHTML='<div class="cropper-container" touch-action="none"><div class="cropper-wrap-box"><div class="cropper-canvas"></div></div><div class="cropper-drag-box"></div><div class="cropper-crop-box"><span class="cropper-view-box"></span><span class="cropper-dashed dashed-h"></span><span class="cropper-dashed dashed-v"></span><span class="cropper-center"></span><span class="cropper-face"></span><span class="cropper-line line-e" data-cropper-action="e"></span><span class="cropper-line line-n" data-cropper-action="n"></span><span class="cropper-line line-w" data-cropper-action="w"></span><span class="cropper-line line-s" data-cropper-action="s"></span><span class="cropper-point point-e" data-cropper-action="e"></span><span class="cropper-point point-n" data-cropper-action="n"></span><span class="cropper-point point-w" data-cropper-action="w"></span><span class="cropper-point point-s" data-cropper-action="s"></span><span class="cropper-point point-ne" data-cropper-action="ne"></span><span class="cropper-point point-nw" data-cropper-action="nw"></span><span class="cropper-point point-sw" data-cropper-action="sw"></span><span class="cropper-point point-se" data-cropper-action="se"></span></div></div>';var o=n.querySelector(".".concat(d,"-container")),r=o.querySelector(".".concat(d,"-canvas")),h=o.querySelector(".".concat(d,"-drag-box")),s=o.querySelector(".".concat(d,"-crop-box")),c=s.querySelector(".".concat(d,"-face"));this.container=a,this.cropper=o,this.canvas=r,this.dragBox=h,this.cropBox=s,this.viewBox=o.querySelector(".".concat(d,"-view-box")),this.face=c,r.appendChild(i),ft(t,B),a.insertBefore(o,t.nextSibling),this.isImg||vt(i,O),this.initPreview(),this.bind(),e.initialAspectRatio=Math.max(0,e.initialAspectRatio)||NaN,e.aspectRatio=Math.max(0,e.aspectRatio)||NaN,e.viewMode=Math.max(0,Math.min(3,Math.round(e.viewMode)))||0,ft(s,B),e.guides||ft(s.getElementsByClassName("".concat(d,"-dashed")),B),e.center||ft(s.getElementsByClassName("".concat(d,"-center")),B),e.background&&ft(o,"".concat(d,"-bg")),e.highlight||ft(c,T),e.cropBoxMovable&&(ft(c,W),Mt(c,N,p)),e.cropBoxResizable||(ft(s.getElementsByClassName("".concat(d,"-line")),B),ft(s.getElementsByClassName("".concat(d,"-point")),B)),this.render(),this.ready=!0,this.setDragMode(e.dragMode),e.autoCrop&&this.crop(),this.setData(e.data),ht(e.ready)&&Bt(t,q,e.ready,{once:!0}),Ot(t,q)}}},{key:"unbuild",value:function(){this.ready&&(this.ready=!1,this.unbind(),this.resetPreview(),this.cropper.parentNode.removeChild(this.cropper),vt(this.element,B))}},{key:"uncreate",value:function(){this.ready?(this.unbuild(),this.ready=!1,this.cropped=!1):this.sizing?(this.sizingImage.onload=null,this.sizing=!1,this.sized=!1):this.reloading?(this.xhr.onabort=null,this.xhr.abort()):this.image&&this.stop()}}])&&i(a.prototype,n),o&&i(a,o),t;var a,n,o}();return dt(Qt.prototype,jt,Pt,It,Ut,qt,$t),Qt}()}}]);