@clickview/library-editor 1.1.52-rc.0 → 1.1.53-dev.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundles.json +3 -3
- package/dist/css/15-library-editor-6fd06eea2a.chunk.css +4 -0
- package/dist/css/{26-library-editor-f0118cbca0.chunk.css → 32-library-editor-9dfe56513f.chunk.css} +0 -4
- package/dist/css/{31-library-editor-4d763bac2b.chunk.css → 41-library-editor-234f39ca94.chunk.css} +0 -4
- package/dist/css/43-library-editor-ca20e9d127.chunk.css +2 -0
- package/dist/css/{library-editor-app-e3fef1181d.css → library-editor-app-24fbc5672c.css} +1 -1
- package/dist/en.json +1 -1
- package/dist/scripts/0-bba0145c77.chunk.js +1 -0
- package/dist/scripts/1-5577f6a3f7.chunk.js +1 -0
- package/dist/scripts/10-395e6f0d3f.chunk.js +1 -0
- package/dist/scripts/12-9ed28b9350.chunk.js +1 -0
- package/dist/scripts/13-50189e51fb.chunk.js +1 -0
- package/dist/scripts/14-748901431d.chunk.js +1 -0
- package/dist/scripts/15-d04c2395cb.chunk.js +1 -0
- package/dist/scripts/16-720a6228d9.chunk.js +1 -0
- package/dist/scripts/17-d885d92c20.chunk.js +1 -0
- package/dist/scripts/18-5977623df8.chunk.js +1 -0
- package/dist/scripts/19-5bdab3ec81.chunk.js +1 -0
- package/dist/scripts/{2-0c5fba8b60.chunk.js → 2-b4df362f89.chunk.js} +1 -1
- package/dist/scripts/22-ae40bff289.chunk.js +1 -0
- package/dist/scripts/23-ec60db0a2f.chunk.js +1 -0
- package/dist/scripts/24-c9ead3a5f0.chunk.js +1 -0
- package/dist/scripts/25-c316ef959e.chunk.js +1 -0
- package/dist/scripts/26-a45dd4bd85.chunk.js +1 -0
- package/dist/scripts/27-f60580ec4c.chunk.js +1 -0
- package/dist/scripts/28-7f81db6a72.chunk.js +1 -0
- package/dist/scripts/29-1719c127c2.chunk.js +1 -0
- package/dist/scripts/3-93f8c8b29c.chunk.js +1 -0
- package/dist/scripts/30-78f9ae88f8.chunk.js +1 -0
- package/dist/scripts/31-3eb784eddf.chunk.js +1 -0
- package/dist/scripts/32-e8241989c0.chunk.js +1 -0
- package/dist/scripts/33-1070fd472f.chunk.js +1 -0
- package/dist/scripts/34-f87b33c7e9.chunk.js +1 -0
- package/dist/scripts/35-e9d6a8b62f.chunk.js +1 -0
- package/dist/scripts/36-723d306d4b.chunk.js +1 -0
- package/dist/scripts/37-79e61046ac.chunk.js +1 -0
- package/dist/scripts/38-212e31c46a.chunk.js +1 -0
- package/dist/scripts/39-f1a08c3c13.chunk.js +1 -0
- package/dist/scripts/4-25b1d9b931.chunk.js +1 -0
- package/dist/scripts/40-a23493aa65.chunk.js +1 -0
- package/dist/scripts/41-e85021f013.chunk.js +1 -0
- package/dist/scripts/42-3df7979970.chunk.js +1 -0
- package/dist/scripts/43-60ab02c464.chunk.js +1 -0
- package/dist/scripts/44-d5bb0ed64a.chunk.js +1 -0
- package/dist/scripts/45-f1b7a85e1f.chunk.js +1 -0
- package/dist/scripts/46-a9758e6ae3.chunk.js +1 -0
- package/dist/scripts/47-9438225608.chunk.js +1 -0
- package/dist/scripts/48-c2442aeabc.chunk.js +1 -0
- package/dist/scripts/49-aeef82658f.chunk.js +1 -0
- package/dist/scripts/5-8cc15ac513.chunk.js +1 -0
- package/dist/scripts/50-10cb81acb2.chunk.js +1 -0
- package/dist/scripts/51-27b1c14df0.chunk.js +1 -0
- package/dist/scripts/52-95c57ffde9.chunk.js +1 -0
- package/dist/scripts/53-5be97c8405.chunk.js +1 -0
- package/dist/scripts/54-c375c80f2f.chunk.js +1 -0
- package/dist/scripts/55-f1f6c64710.chunk.js +1 -0
- package/dist/scripts/56-e81e20968e.chunk.js +1 -0
- package/dist/scripts/57-0abfa42a18.chunk.js +1 -0
- package/dist/scripts/58-596eaa36e1.chunk.js +1 -0
- package/dist/scripts/59-4a6dc51102.chunk.js +1 -0
- package/dist/scripts/6-3cfc29cd25.chunk.js +1 -0
- package/dist/scripts/{58-c0d48a915f.chunk.js → 60-ec99d4c0ec.chunk.js} +1 -1
- package/dist/scripts/61-94aba0214c.chunk.js +1 -0
- package/dist/scripts/62-078a1c7a79.chunk.js +1 -0
- package/dist/scripts/63-4d411f9dbc.chunk.js +1 -0
- package/dist/scripts/64-7cb7526007.chunk.js +1 -0
- package/dist/scripts/65-115a7df284.chunk.js +1 -0
- package/dist/scripts/66-f293f5aaf9.chunk.js +1 -0
- package/dist/scripts/67-4779bb083c.chunk.js +1 -0
- package/dist/scripts/68-ff8fdd5b00.chunk.js +1 -0
- package/dist/scripts/69-ae2fee4118.chunk.js +1 -0
- package/dist/scripts/7-0b561c5906.chunk.js +1 -0
- package/dist/scripts/70-1301052ad4.chunk.js +1 -0
- package/dist/scripts/71-37410a7494.chunk.js +1 -0
- package/dist/scripts/{70-d2472d2122.chunk.js → 72-04f3d7e7da.chunk.js} +1 -1
- package/dist/scripts/73-c2d2ad43c2.chunk.js +1 -0
- package/dist/scripts/74-f030ed93a4.chunk.js +1 -0
- package/dist/scripts/8-df0693826e.chunk.js +1 -0
- package/dist/scripts/9-d87db5e300.chunk.js +1 -0
- package/dist/scripts/bundle-7de62968ab.min.js +10 -0
- package/dist/scripts/polyfills-383fa05a74.min.js +1 -0
- package/package.json +100 -100
- package/dist/css/32-library-editor-d962911bc5.chunk.css +0 -6
- package/dist/scripts/0-5f0c2cd8fe.chunk.js +0 -1
- package/dist/scripts/1-7a35a849f0.chunk.js +0 -1
- package/dist/scripts/10-d534563266.chunk.js +0 -1
- package/dist/scripts/12-f0c771aad1.chunk.js +0 -1
- package/dist/scripts/13-d70fedb2e0.chunk.js +0 -1
- package/dist/scripts/14-fafea6f32c.chunk.js +0 -1
- package/dist/scripts/15-7aa65c016d.chunk.js +0 -1
- package/dist/scripts/16-56c022c016.chunk.js +0 -1
- package/dist/scripts/17-14a7b2aed1.chunk.js +0 -1
- package/dist/scripts/20-48346c1412.chunk.js +0 -1
- package/dist/scripts/21-f9ff3e0692.chunk.js +0 -1
- package/dist/scripts/22-82ad962fa7.chunk.js +0 -1
- package/dist/scripts/23-d534e3d903.chunk.js +0 -1
- package/dist/scripts/24-264b454456.chunk.js +0 -1
- package/dist/scripts/25-e1743bb45d.chunk.js +0 -1
- package/dist/scripts/26-0d7e56893b.chunk.js +0 -1
- package/dist/scripts/27-4ddeaff155.chunk.js +0 -1
- package/dist/scripts/28-96aef6893a.chunk.js +0 -1
- package/dist/scripts/29-554f426b85.chunk.js +0 -1
- package/dist/scripts/3-75a0223960.chunk.js +0 -1
- package/dist/scripts/30-9bdc787ec5.chunk.js +0 -1
- package/dist/scripts/31-67f46f7d90.chunk.js +0 -1
- package/dist/scripts/32-afdbc7da12.chunk.js +0 -1
- package/dist/scripts/33-6c83870de4.chunk.js +0 -1
- package/dist/scripts/34-486d783b77.chunk.js +0 -1
- package/dist/scripts/35-44dfa1d229.chunk.js +0 -1
- package/dist/scripts/36-6e22a76e9d.chunk.js +0 -1
- package/dist/scripts/37-247574943e.chunk.js +0 -1
- package/dist/scripts/38-c053771304.chunk.js +0 -1
- package/dist/scripts/39-0034f40388.chunk.js +0 -1
- package/dist/scripts/4-bbf9a27d2b.chunk.js +0 -1
- package/dist/scripts/40-4c9075f25f.chunk.js +0 -1
- package/dist/scripts/41-9ef30d9bce.chunk.js +0 -1
- package/dist/scripts/42-d5ebd7e173.chunk.js +0 -1
- package/dist/scripts/43-18cb4a605c.chunk.js +0 -1
- package/dist/scripts/44-c501392a17.chunk.js +0 -1
- package/dist/scripts/45-6f27b84b9a.chunk.js +0 -1
- package/dist/scripts/46-26943c79e1.chunk.js +0 -1
- package/dist/scripts/47-58f15ff5f7.chunk.js +0 -1
- package/dist/scripts/48-59c60086c6.chunk.js +0 -1
- package/dist/scripts/49-c7095beb6f.chunk.js +0 -1
- package/dist/scripts/5-a06b2153c3.chunk.js +0 -1
- package/dist/scripts/50-015c9c420c.chunk.js +0 -1
- package/dist/scripts/51-0cca989dae.chunk.js +0 -1
- package/dist/scripts/52-3cc8a4a0c6.chunk.js +0 -1
- package/dist/scripts/53-b0a20bc5a0.chunk.js +0 -1
- package/dist/scripts/54-79dca3d489.chunk.js +0 -1
- package/dist/scripts/55-8c5eba8730.chunk.js +0 -1
- package/dist/scripts/56-4d5b5fecd6.chunk.js +0 -1
- package/dist/scripts/57-84eff54b39.chunk.js +0 -1
- package/dist/scripts/59-53d002a1db.chunk.js +0 -1
- package/dist/scripts/6-6c8dac1a42.chunk.js +0 -1
- package/dist/scripts/60-9ba5670a0b.chunk.js +0 -1
- package/dist/scripts/61-7189b10e86.chunk.js +0 -1
- package/dist/scripts/62-6c382c4af3.chunk.js +0 -1
- package/dist/scripts/63-d55def5355.chunk.js +0 -1
- package/dist/scripts/64-4925cb46d4.chunk.js +0 -1
- package/dist/scripts/65-28d1f3d305.chunk.js +0 -1
- package/dist/scripts/66-dd4f73d58f.chunk.js +0 -1
- package/dist/scripts/67-25c6582829.chunk.js +0 -1
- package/dist/scripts/68-4962d3fcfc.chunk.js +0 -1
- package/dist/scripts/69-2067a2189e.chunk.js +0 -1
- package/dist/scripts/7-881a9b64de.chunk.js +0 -1
- package/dist/scripts/71-3f1e0d4f31.chunk.js +0 -1
- package/dist/scripts/72-d5c52637ca.chunk.js +0 -1
- package/dist/scripts/8-ef172e304b.chunk.js +0 -1
- package/dist/scripts/9-d5b2cc8210.chunk.js +0 -1
- package/dist/scripts/bundle-c6afc7b324.min.js +0 -10
- package/dist/scripts/polyfills-35ff77d456.min.js +0 -1
- /package/dist/css/{33-library-editor-630c133693.chunk.css → 16-library-editor-6b9ba08288.chunk.css} +0 -0
- /package/dist/css/{15-library-editor-b08725a10e.chunk.css → 17-library-editor-b08725a10e.chunk.css} +0 -0
- /package/dist/css/{16-library-editor-89ad109c63.chunk.css → 18-library-editor-89ad109c63.chunk.css} +0 -0
- /package/dist/css/{20-library-editor-2bd52b5a32.chunk.css → 22-library-editor-2bd52b5a32.chunk.css} +0 -0
- /package/dist/css/{21-library-editor-a7633bece5.chunk.css → 23-library-editor-a7633bece5.chunk.css} +0 -0
- /package/dist/css/{22-library-editor-459b106aec.chunk.css → 24-library-editor-459b106aec.chunk.css} +0 -0
- /package/dist/css/{23-library-editor-33acb75c24.chunk.css → 25-library-editor-33acb75c24.chunk.css} +0 -0
- /package/dist/css/{24-library-editor-b180014922.chunk.css → 26-library-editor-b180014922.chunk.css} +0 -0
- /package/dist/css/{25-library-editor-4c64aed388.chunk.css → 27-library-editor-4c64aed388.chunk.css} +0 -0
- /package/dist/css/{27-library-editor-b72d0e2d36.chunk.css → 28-library-editor-b72d0e2d36.chunk.css} +0 -0
- /package/dist/css/{28-library-editor-de55d150ef.chunk.css → 29-library-editor-de55d150ef.chunk.css} +0 -0
- /package/dist/css/{29-library-editor-b0e16f882d.chunk.css → 30-library-editor-b0e16f882d.chunk.css} +0 -0
- /package/dist/css/{30-library-editor-10f54d8a75.chunk.css → 31-library-editor-10f54d8a75.chunk.css} +0 -0
- /package/dist/css/{37-library-editor-d18b8a3619.chunk.css → 36-library-editor-d18b8a3619.chunk.css} +0 -0
- /package/dist/css/{38-library-editor-8b225d15f4.chunk.css → 37-library-editor-8b225d15f4.chunk.css} +0 -0
- /package/dist/css/{40-library-editor-b08725a10e.chunk.css → 38-library-editor-b08725a10e.chunk.css} +0 -0
- /package/dist/css/{41-library-editor-9a2d011500.chunk.css → 40-library-editor-9a2d011500.chunk.css} +0 -0
- /package/dist/css/{43-library-editor-aa3e9bea9a.chunk.css → 44-library-editor-aa3e9bea9a.chunk.css} +0 -0
- /package/dist/css/{44-library-editor-7b1cd4a5cc.chunk.css → 45-library-editor-7b1cd4a5cc.chunk.css} +0 -0
- /package/dist/css/{45-library-editor-f1820aeeff.chunk.css → 46-library-editor-f1820aeeff.chunk.css} +0 -0
- /package/dist/css/{46-library-editor-547abc7492.chunk.css → 47-library-editor-547abc7492.chunk.css} +0 -0
- /package/dist/css/{47-library-editor-3f6fb7f3ab.chunk.css → 48-library-editor-3f6fb7f3ab.chunk.css} +0 -0
- /package/dist/css/{48-library-editor-467e156ba3.chunk.css → 49-library-editor-467e156ba3.chunk.css} +0 -0
- /package/dist/css/{50-library-editor-7aca18778d.chunk.css → 51-library-editor-7aca18778d.chunk.css} +0 -0
- /package/dist/css/{51-library-editor-81c5aced1f.chunk.css → 52-library-editor-81c5aced1f.chunk.css} +0 -0
- /package/dist/css/{54-library-editor-d3b8bb68f9.chunk.css → 56-library-editor-d3b8bb68f9.chunk.css} +0 -0
- /package/dist/css/{55-library-editor-94a8c4e7fa.chunk.css → 57-library-editor-94a8c4e7fa.chunk.css} +0 -0
- /package/dist/css/{56-library-editor-61808b02a0.chunk.css → 58-library-editor-61808b02a0.chunk.css} +0 -0
- /package/dist/css/{57-library-editor-c49b3847df.chunk.css → 59-library-editor-c49b3847df.chunk.css} +0 -0
- /package/dist/css/{58-library-editor-8f5e04b64a.chunk.css → 60-library-editor-8f5e04b64a.chunk.css} +0 -0
- /package/dist/css/{59-library-editor-b64f6f3e74.chunk.css → 61-library-editor-b64f6f3e74.chunk.css} +0 -0
- /package/dist/css/{61-library-editor-7f123672b2.chunk.css → 63-library-editor-7f123672b2.chunk.css} +0 -0
- /package/dist/css/{62-library-editor-61e4c24a7b.chunk.css → 64-library-editor-61e4c24a7b.chunk.css} +0 -0
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp_clickview_library_editor=window.webpackJsonp_clickview_library_editor||[]).push([[62],{1355:function(t,e,n){var o=n(10);t.exports=(o.default||o).template({compiler:[8,">= 4.3.0"],main:function(t,e,n,o,r){t.propertyIsEnumerable;var i,a=null!=e?e:t.nullContext||{},l=t.hooks.helperMissing,u=t.escapeExpression;return"<h1>"+u((n.lang||e&&e.lang||l).call(a,"inLibrary",{name:"lang",hash:{smartCount:null!=(i=null!=e?e.options:e)?i.count:i},data:r}))+'</h1>\r\n<div class="my-3">\r\n <img src="/images/upload/upload-completed@2x.png" class="'+u(t.lambda(null!=(i=null!=(i=null!=e?e.options:e)?i.styles:i)?i.completeImage:i,e))+'"/>\r\n</div>\r\n<p>'+u((n.lang||e&&e.lang||l).call(a,"isProcessing",{name:"lang",hash:{smartCount:null!=(i=null!=e?e.options:e)?i.count:i},data:r}))+'</p>\r\n<a class="back-to-library-applink btn btn-primary">'+u((n.lang||e&&e.lang||l).call(a,"back",{name:"lang",hash:{},data:r}))+"</a>"},useData:!0})},1356:function(t,e,n){t.exports={completeImage:"_1LiuD"}},1445:function(t,e,n){"use strict";n.r(e),n.d(e,"UploadCompleteView",(function(){return h}));var o=n(2),r=n(5),i=n(1355),a=n.n(i),l=n(0),u=n(3),c=n(1356),p=n.n(c);function s(t){return(s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function f(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function y(t,e){for(var n=0;n<e.length;n++){var o=e[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,o.key,o)}}function b(t,e){return(b=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function m(t){var e=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(t){return!1}}();return function(){var n,o=d(t);if(e){var r=d(this).constructor;n=Reflect.construct(o,arguments,r)}else n=o.apply(this,arguments);return g(this,n)}}function g(t,e){return!e||"object"!==s(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function d(t){return(d=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}var h=function(t){!function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&b(t,e)}(c,t);var e,n,o,i=m(c);function c(){return f(this,c),i.apply(this,arguments)}return e=c,(n=[{key:"initialize",value:function(){this.videoUploadService=r.a.getInstance(l.x.VideoUpload,this)}},{key:"name",get:function(){return"UploadCompleteView"}},{key:"title",get:function(){return u.a.getPhrase(this.lang,"title")}},{key:"lang",get:function(){return"upload.uploadComplete"}},{key:"template",get:function(){return a.a}},{key:"className",get:function(){return"p-3 my-3 bg-white text-center"}},{key:"appLinks",get:function(){return{".back-to-library-applink":{application:l.b.LIBRARY_EDITOR,action:l.a.LibraryEditor.HOME}}}},{key:"viewOptions",value:function(){return{styles:p.a,count:this.videoUploadService.getCollection().length}}},{key:"onBeforeDestroy",value:function(){this.videoUploadService.getCollection().reset()}}])&&y(e.prototype,n),o&&y(e,o),c}(o.a.View)}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp_clickview_library_editor=window.webpackJsonp_clickview_library_editor||[]).push([[63],{1030:function(e,t,n){"use strict";n.d(t,"a",(function(){return p}));var r=n(2),o=n(264);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})(e)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function l(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(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,r=f(e);if(t){var o=f(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return s(this,n)}}function s(e,t){return!t||"object"!==i(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function f(e){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(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}}),t&&u(e,t)}(s,e);var t,n,r,i=c(s);function s(){return a(this,s),i.apply(this,arguments)}return t=s,(n=[{key:"defaults",value:function(){return e={},t=o.c.Disabled,n=!0,t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e;var e,t,n}}])&&l(t.prototype,n),r&&l(t,r),s}(r.a.Model)},1338:function(e,t,n){var r=n(10);e.exports=(r.default||r).template({1:function(e,t,n,r,o){var i;e.propertyIsEnumerable;return(null!=(i=e.lambda(null!=(i=null!=t?t.options:t)?i.spinnerEl:i,t))?i:"")+"\r\n"},3:function(e,t,n,r,o){e.propertyIsEnumerable;var i,a=null!=t?t:e.nullContext||{},l=e.hooks.helperMissing,u=e.escapeExpression;return'<p class="m-0 pb-2">'+u((n.lang||t&&t.lang||l).call(a,"noReview",{name:"lang",hash:{},data:o}))+"</p>\r\n"+(null!=(i=n.if.call(a,null!=(i=null!=t?t.options:t)?i.videosToReview:i,{name:"if",hash:{},fn:e.program(4,o,0),inverse:e.noop,data:o}))?i:"")+'<p class="m-0">'+u((n.lang||t&&t.lang||l).call(a,"undoInstructions",{name:"lang",hash:{},data:o}))+"</p>\r\n"},4:function(e,t,n,r,o){e.propertyIsEnumerable;return'<p class="m-0 pb-2">'+e.escapeExpression((n.lang||t&&t.lang||e.hooks.helperMissing).call(null!=t?t:e.nullContext||{},"automaticApproval",{name:"lang",hash:{},data:o}))+"</p>\r\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,o){var i;e.propertyIsEnumerable;return null!=(i=n.unless.call(null!=t?t:e.nullContext||{},null!=(i=null!=t?t.options:t)?i.dataFetched:i,{name:"unless",hash:{},fn:e.program(1,o,0),inverse:e.program(3,o,0),data:o}))?i:""},useData:!0})},1441:function(e,t,n){"use strict";n.r(t),n.d(t,"DisableReviewView",(function(){return O}));var r=n(5),o=n(3),i=n(2),a=n(4),l=n(42),u=n(264),c=n(303),s=n(13),f=n(144),p=n(0),h=n(1030),y=n(1338),v=n.n(y);function b(e){return(b="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function d(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function g(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function m(e,t){return(m=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function w(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,r=k(e);if(t){var o=k(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return R(this,n)}}function R(e,t){return!t||"object"!==b(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function k(e){return(k=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var O=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}}),t&&m(e,t)}(R,e);var t,n,y,b=w(R);function R(){return d(this,R),b.apply(this,arguments)}return t=R,(n=[{key:"initialize",value:function(){this.bindListeners(),this.settingsDataService=r.a.getInstance(p.g.Settings,this),this.contentUpdatesDataService=r.a.getInstance(p.g.ContentUpdates,this)}},{key:"name",get:function(){return"DisableReviewView"}},{key:"title",get:function(){return o.a.getPhrase(this.lang,"title")}},{key:"template",get:function(){return v.a}},{key:"lang",get:function(){return"contentUpdates.disableReview"}},{key:"channelName",get:function(){return s.k.generateUniqueChannelName(this)}},{key:"behaviors",get:function(){var e=this;return[{title:o.a.getPhrase(this.lang,"heading"),behaviorClass:c.e,spinnerButtonOptions:{model:this.spinnerModel=new h.a,channelName:this.channelName,buttonText:o.a.getPhrase(this.lang,"offBtn"),onClick:function(){return e.onClickDisable()}}}]}},{key:"bindListeners",value:function(){this.listenTo(p.e.VIDEO,"".concat(p.f.VIDEOS_TO_REVIEW,":sync"),this.render)}},{key:"videosToReview",value:function(){return!!this.videoCollection&&!!this.videoCollection.length}},{key:"onClickDisable",value:function(){this.videosToReview()?this.approveAllThenDisableReview():this.disableReview(),this.triggerMethod("hide")}},{key:"approveAllThenDisableReview",value:function(){var e=this;this.contentUpdatesDataService.approveAllVideos((function(){return e.disableReview()}))}},{key:"disableReview",value:function(){var e=s.p.getLibraryReviewOptions(!1);this.settingsDataService.updateSetting(this.currentUser.get("customerId"),e,o.a.getPhrase(this.lang,"disableSuccess"),this.redirectToPastReleases),this.logAction()}},{key:"redirectToPastReleases",value:function(){i.a.AppLinkHelper.trigger({application:p.b.CONTENT_UPDATES,action:p.a.ContentUpdates.PAST_RELEASES})}},{key:"logAction",value:function(){var e={location:a.LocationContext.Popup,actionType:a.UserAction.Disable,entity:a.EntityType.CustomerSetting,descriptor:a.CustomerSettingDescriptor.LibraryReview,workflowPhase:a.WorkflowPhase.Complete},t={approvedCount:this.videoCollection.length};l.a.logUserAction(t,e)}},{key:"requiredResources",get:function(){return{currentUser:f.b.currentUser}}},{key:"onBeforeRender",value:function(){this.videoCollection=this.contentUpdatesDataService.getVideosToReview(),this.videoCollection&&this.spinnerModel.set(u.c.Disabled,!1)}},{key:"viewOptions",value:function(){return{videosToReview:this.videosToReview(),dataFetched:!!this.videoCollection,spinnerEl:s.r.getSpinner({size:s.s.Large,extraClasses:"mx-auto"})}}}])&&g(t.prototype,n),y&&g(t,y),R}(i.a.View)}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp_clickview_library_editor=window.webpackJsonp_clickview_library_editor||[]).push([[64],{1042:function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(3),i="libraryEditor.utils",o={name:[{required:!0,msg:function(){return r.a.getPhrase(i,"libraryNameRequired")}},{maxLength:255,msg:function(){return r.a.getPhrase(i,"libraryNameExceeds")}}]}},1292:function(e,t,n){var r=n(10);e.exports=(r.default||r).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){e.propertyIsEnumerable;var o=null!=t?t:e.nullContext||{},a=e.hooks.helperMissing,l=e.escapeExpression;return'<form>\r\n <div class="form-group">\r\n <label for="name" class="control-label">'+l((n.lang||t&&t.lang||a).call(o,"libraryName",{name:"lang",hash:{},data:i}))+'</label>\r\n <input name="name" id="name" type="text" class="form-control" placeholder="'+l((n.lang||t&&t.lang||a).call(o,"secondaryLibrary",{name:"lang",hash:{},data:i}))+'" autocomplete="off" autofocus/>\r\n <div class="form-feedback"></div>\r\n </div>\r\n</form>'},useData:!0})},1426:function(e,t,n){"use strict";n.r(t),n.d(t,"RenameLibraryView",(function(){return S}));var r=n(6),i=n(2),o=n(5),a=n(30),l=n(3),u=n(42),c=n(303),s=n(137),f=n(264),y=n(0),b=n(13),h=n(1042),p=n(1292),m=n.n(p);function d(e){return(d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function v(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function g(e,t){return(g=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function k(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,r=O(e);if(t){var i=O(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return w(this,n)}}function w(e,t){return!t||"object"!==d(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function O(e){return(O=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var S=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}}),t&&g(e,t)}(d,e);var t,n,i,p=k(d);function d(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,d),p.call(this,e)}return t=d,(n=[{key:"initialize",value:function(){this.bindListeners(),this.libraryDataService=o.a.getInstance(y.g.Library,this)}},{key:"bindListeners",value:function(){this.listenTo(y.e.LIBRARY,"libraries:sync",this.render)}},{key:"name",get:function(){return"RenameLibraryView"}},{key:"lang",get:function(){return"libraryEditor.renameLibrary"}},{key:"title",get:function(){return l.a.getPhrase(this.lang,"title")}},{key:"template",get:function(){return m.a}},{key:"channelName",get:function(){return b.k.generateUniqueChannelName(this)}},{key:"behaviors",get:function(){var e=this;return[{behaviorClass:c.a,modelValidation:h.a},{behaviorClass:c.f},{behaviorClass:c.e,title:l.a.getPhrase(this.lang,"edit"),spinnerButtonOptions:{channelName:this.channelName,buttonText:l.a.getPhrase(this.lang,"save"),onClick:function(t){return e.onSubmit(t)}}}]}},{key:"bindings",get:function(){return{"[name=name]":{observe:"name",setOptions:{validate:!0}}}}},{key:"events",value:function(){return{submit:"onSubmit"}}},{key:"onSubmit",value:function(e){e&&e.preventDefault(),this.model.validate(),this.model.isValid()&&(r.Radio.channel(this.channelName).trigger(f.b.ShowSpinner),this.saveLibrary(),this.logAction())}},{key:"logAction",value:function(){var e={id:this.options.libraryId,name:this.model.get("name")};u.a.logUserAction(e,this.options.analyticsOptions)}},{key:"saveLibrary",value:function(){var e=this;this.libraryDataService.updateLibrary(this.model,(function(){e.triggerMethod("hide")}))}},{key:"onBeforeRender",value:function(){var e=this;return this.libraryDataService.getFolderFromLibraries(this.options.libraryId,(function(t){e.model||(e.model=a.a.get("library:".concat(e.options.libraryId),t.toJSON(),{ctor:s.a}))})),!!this.model}}])&&v(t.prototype,n),i&&v(t,i),d}(i.a.View)}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp_clickview_library_editor=window.webpackJsonp_clickview_library_editor||[]).push([[65],{1090:function(t,e,n){"use strict";var r=n(203),o=n(1),i=n(201),c=n(0),u=n(145),a=n(305);function l(t){return(l="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)}function s(t){return function(t){if(Array.isArray(t))return f(t)}(t)||function(t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(t))return Array.from(t)}(t)||function(t,e){if(!t)return;if("string"==typeof t)return f(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);"Object"===n&&t.constructor&&(n=t.constructor.name);if("Map"===n||"Set"===n)return Array.from(t);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return f(t,e)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function f(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function y(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function p(t,e){return(p=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function h(t){var e=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(t){return!1}}();return function(){var n,r=b(t);if(e){var o=b(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return d(this,n)}}function d(t,e){return!e||"object"!==l(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function b(t){return(b=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}var m=function(t){!function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&p(t,e)}(l,t);var e,n,r,i=h(l);function l(t){var e;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),(e=i.call(this,{collectionPrefix:"".concat(c.f.RECENT_VIDEOS,":collection"),cursor:t.cursor,sort:t.sort})).setAdditionalData(t),e}return e=l,(n=[{key:"setAdditionalData",value:function(t){var e=t.libraryIds,n=t.dateQueryString,r=t.subjects;e&&(this.libraryIds=e),r&&(o.isArray(r)&&r.length&&(this.subjects=r),o.isArray(r)||(this.subjects=[r]));var i=o.findWhere(a.g,{queryString:n})||a.e;this.dateOption=new u.b(i)}},{key:"toString",value:function(){var t=this.subjects&&this.subjects.length&&this.subjects.map((function(t){return escape(t.get("name"))}))||[];return[this.collectionPrefix,this.libraryIds,this.dateOption.get("from"),this.dateOption.get("to")].concat(s(t),[this.cursor]).filter(Boolean).join(":")}},{key:"toParams",value:function(){var t={};return this.libraryIds&&(t.libraryIds=this.libraryIds),this.dateOption&&(t.from=this.dateOption.get("from"),t.to=this.dateOption.get("to")),this.subjects&&(t.subjectIds=o.flatten(this.subjects.map((function(t){return t.get("subjectIds")})))),this.cursor&&(t.cursor=this.cursor),t}}])&&y(e.prototype,n),r&&y(e,r),l}(i.a);function v(t){return(v="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)}function g(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function O(t,e){return(O=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function w(t){var e=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(t){return!1}}();return function(){var n,r=_(t);if(e){var o=_(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return S(this,n)}}function S(t,e){return!e||"object"!==v(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function _(t){return(_=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}var j=function(t){!function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&O(t,e)}(l,t);var e,n,r,i=w(l);function l(t){var e;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),(e=i.call(this,{collectionPrefix:"".concat(c.f.RECENT_SUBJECTS,":collection"),sort:t.sort})).setAdditionalData(t),e}return e=l,(n=[{key:"setAdditionalData",value:function(t){var e=t.libraryIds,n=t.dateQueryString;e&&(this.libraryIds=e);var r=o.findWhere(a.g,{queryString:n})||a.e;this.dateOption=new u.b(r)}},{key:"toString",value:function(){return[this.collectionPrefix,this.libraryIds,this.dateOption.get("from"),this.dateOption.get("to")].filter(Boolean).join(":")}},{key:"toParams",value:function(){var t={};return this.libraryIds&&(t.libraryIds=this.libraryIds),this.dateOption&&(t.from=this.dateOption.get("from"),t.to=this.dateOption.get("to")),t}}])&&g(e.prototype,n),r&&g(e,r),l}(i.a);function R(t){return(R="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)}function P(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function I(t,e){return(I=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function k(t){var e=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(t){return!1}}();return function(){var n,r=D(t);if(e){var o=D(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return E(this,n)}}function E(t,e){return!e||"object"!==R(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function D(t){return(D=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}var A=function(t){!function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&I(t,e)}(n,t);var e=k(n);function n(t,r){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";return P(this,n),e.call(this,{collectionPrefix:c.f.LIBRARY_FOLDERS,id:t,sort:r,cursor:o})}return n}(i.a);n.d(e,"d",(function(){return r.a})),n.d(e,"b",(function(){return m})),n.d(e,"c",(function(){return j})),n.d(e,"a",(function(){return A}))},1230:function(t,e,n){var r=n(10);t.exports=(r.default||r).template({compiler:[8,">= 4.3.0"],main:function(t,e,n,r,o){var i;t.propertyIsEnumerable;return null!=(i=(n.lang||e&&e.lang||t.hooks.helperMissing).call(null!=e?e:t.nullContext||{},"check",{name:"lang",hash:{name:null!=e?e.name:e},data:o}))?i:""},useData:!0})},1420:function(t,e,n){"use strict";n.r(e),n.d(e,"DeleteFolderView",(function(){return S}));var r=n(6),o=n(5),i=n(2),c=n(42),u=n(0),a=n(303),l=n(13),s=n(264),f=n(1090),y=n(3),p=n(205),h=n(1230),d=n.n(h);function b(t){return(b="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)}function m(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function v(t,e){return(v=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function g(t){var e=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(t){return!1}}();return function(){var n,r=w(t);if(e){var o=w(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return O(this,n)}}function O(t,e){return!e||"object"!==b(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function w(t){return(w=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}var S=function(t){!function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&v(t,e)}(O,t);var e,n,h,b=g(O);function O(t){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,O),b.call(this,t)}return e=O,(n=[{key:"initialize",value:function(){this.listenTo(u.e.LIBRARY,"libraries:sync",this.render),this.collectionIdentifier=new f.d(this.options.folderId,l.q.GetCurrentSortType()),this.listenTo(u.e.VIDEO,"".concat(this.collectionIdentifier,":sync"),this.render),this.libraryDataService=o.a.getInstance(u.g.Library,this),this.videoDataService=o.a.getInstance(u.g.Video,this)}},{key:"name",get:function(){return"DeleteFolderView"}},{key:"title",get:function(){return!!this.model&&y.a.getPhrase(this.lang,"title",{folderName:this.model.get("name")})}},{key:"lang",get:function(){return"libraryEditor.deleteFolder"}},{key:"template",get:function(){return d.a}},{key:"channelName",get:function(){return l.k.generateUniqueChannelName(this)}},{key:"behaviors",get:function(){var t=this;return[{behaviorClass:a.e,title:y.a.getPhrase(this.lang,"removeFolder"),spinnerButtonOptions:{channelName:this.channelName,buttonText:y.a.getPhrase(this.lang,"remove"),extraButtonClass:"btn-danger",onClick:function(e){return t.onClickDelete(e)}}}]}},{key:"getParentId",value:function(){if(l.f.isSubFolder(this.model)&&this.model&&this.model.collection&&this.model.collection.parent&&this.model.collection.parent instanceof i.a.Model)return this.model.collection.parent.get("id");var t=l.f.getLibrary(this.model.get("id"),this.model.collection);return t&&t.id||null}},{key:"onClickDelete",value:function(t){t&&t.preventDefault(),r.Radio.channel(this.channelName).trigger(s.b.ShowSpinner);var e=this.getParentId(),n=l.f.isSubFolder(this.model)?u.a.LibraryEditor.FOLDER:u.a.LibraryEditor.LIBRARY;this.libraryDataService.deleteFolder(this.options.folderId,(function(){i.a.AppLinkHelper.trigger({application:u.b.LIBRARY_EDITOR,action:n,args:[e]},{replace:!0})})),this.logAction()}},{key:"logAction",value:function(){var t={id:this.options.folderId,name:this.model.get("name")};c.a.logUserAction(t,this.options.analyticsOptions)}},{key:"canDelete",value:function(){return!(this.model.children&&this.model.children.length||this.videos&&this.videos.length)}},{key:"onBeforeRender",value:function(){var t=this;return this.libraryDataService.getFolderFromLibraries(this.options.folderId,(function(e){t.model=e})),this.videos=this.videoDataService.getCollectionVideos(this.collectionIdentifier),!(!this.model||!this.videos||!this.canDelete()&&(window.setTimeout((function(){t.triggerMethod("hide"),i.a.ErrorHelper.throw(new p.c)}),u.s.POPUP_FADE_TIMEOUT),1))}}])&&m(e.prototype,n),h&&m(e,h),O}(i.a.View)}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp_clickview_library_editor=window.webpackJsonp_clickview_library_editor||[]).push([[66],{1030:function(t,e,n){"use strict";n.d(e,"a",(function(){return p}));var r=n(2),o=n(264);function i(t){return(i="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)}function a(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function u(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function l(t,e){return(l=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function c(t){var e=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(t){return!1}}();return function(){var n,r=f(t);if(e){var o=f(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return s(this,n)}}function s(t,e){return!e||"object"!==i(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function f(t){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}var p=function(t){!function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&l(t,e)}(s,t);var e,n,r,i=c(s);function s(){return a(this,s),i.apply(this,arguments)}return e=s,(n=[{key:"defaults",value:function(){return t={},e=o.c.Disabled,n=!0,e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t;var t,e,n}}])&&u(e.prototype,n),r&&u(e,r),s}(r.a.Model)},1232:function(t,e,n){var r=n(10);t.exports=(r.default||r).template({1:function(t,e,n,r,o){var i;t.propertyIsEnumerable;return(null!=(i=t.lambda(null!=(i=null!=e?e.options:e)?i.spinnerEl:i,e))?i:"")+"\r\n"},3:function(t,e,n,r,o){var i;t.propertyIsEnumerable;return(null!=(i=(n.lang||e&&e.lang||t.hooks.helperMissing).call(null!=e?e:t.nullContext||{},"check",{name:"lang",hash:{smartCount:null!=(i=null!=e?e.options:e)?i.videoCount:i},data:o}))?i:"")+"\r\n"},compiler:[8,">= 4.3.0"],main:function(t,e,n,r,o){var i;t.propertyIsEnumerable;return null!=(i=n.unless.call(null!=e?e:t.nullContext||{},null!=(i=null!=e?e.options:e)?i.libraryFetched:i,{name:"unless",hash:{},fn:t.program(1,o,0),inverse:t.program(3,o,0),data:o}))?i:""},useData:!0})},1422:function(t,e,n){"use strict";n.r(e),n.d(e,"DeleteVideosView",(function(){return k}));var r=n(1),o=n(6),i=n(2),a=n(5),u=n(42),l=n(303),c=n(1030),s=n(13),f=n(264),p=n(0),y=n(3),h=n(1232),b=n.n(h);function d(t){return(d="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)}function v(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function g(t,e){return(g=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function m(t){var e=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(t){return!1}}();return function(){var n,r=O(t);if(e){var o=O(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return w(this,n)}}function w(t,e){return!e||"object"!==d(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function O(t){return(O=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}var k=function(t){!function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&g(t,e)}(w,t);var e,n,h,d=m(w);function w(t){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,w),d.call(this,t)}return e=w,(n=[{key:"initialize",value:function(){this.libraryDataService=a.a.getInstance(p.g.Library,this),this.videoDataService=a.a.getInstance(p.g.Video,this)}},{key:"name",get:function(){return"DeleteVideoView"}},{key:"lang",get:function(){return"libraryEditor.deleteVideos"}},{key:"title",get:function(){return this.options.videoIds&&y.a.getPhrase(this.lang,"title",{smartCount:this.options.videoIds.length})}},{key:"template",get:function(){return b.a}},{key:"channelName",get:function(){return s.k.generateUniqueChannelName(this)}},{key:"behaviors",get:function(){var t=this;return[{title:y.a.getPhrase(this.lang,"removeVideos"),behaviorClass:l.e,spinnerButtonOptions:{channelName:this.channelName,model:this.spinnerModel=new c.a,buttonText:y.a.getPhrase(this.lang,"remove"),extraButtonClass:"btn-danger",onClick:function(){return t.onClickDelete()}}}]}},{key:"onClickDelete",value:function(){var t=this;this.library&&(o.Radio.channel(this.channelName).trigger(f.b.ShowSpinner),this.videoDataService.deleteVideosFromLibrary(this.library.id,this.options.folderId,this.options.videoIds,(function(){t.options.routeToFolderOnDelete?i.a.AppLinkHelper.trigger({application:p.b.LIBRARY_EDITOR,action:p.a.LibraryEditor.FOLDER,args:[t.options.folderId]}):t.triggerMethod("hide")})),this.logAction())}},{key:"logAction",value:function(){var t=this.options.videoIds,e={libraryId:this.library.id,folderId:this.options.folderId,count:t.length};1===t.length&&(e.id=r.first(t)),u.a.logUserAction(e,this.options.analyticsOptions)}},{key:"onBeforeRender",value:function(){var t=this;this.library?this.spinnerModel.set(f.c.Disabled,!1):this.libraryDataService.getLibraries((function(e){t.library=s.f.getLibrary(t.options.folderId,e),t.render()}))}},{key:"viewOptions",value:function(){return{count:this.options.videoIds.length,libraryFetched:!!this.library,spinnerEl:s.r.getSpinner({size:s.s.Large,extraClasses:"mx-auto"}),videoCount:this.options.videoIds.length}}}])&&v(e.prototype,n),h&&v(e,h),w}(i.a.View)}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp_clickview_library_editor=window.webpackJsonp_clickview_library_editor||[]).push([[67],{1030:function(e,t,n){"use strict";n.d(t,"a",(function(){return p}));var r=n(2),o=n(264);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})(e)}function a(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 r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function l(e,t){return(l=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(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,r=f(e);if(t){var o=f(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return s(this,n)}}function s(e,t){return!t||"object"!==i(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function f(e){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(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}}),t&&l(e,t)}(s,e);var t,n,r,i=c(s);function s(){return a(this,s),i.apply(this,arguments)}return t=s,(n=[{key:"defaults",value:function(){return e={},t=o.c.Disabled,n=!0,t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e;var e,t,n}}])&&u(t.prototype,n),r&&u(t,r),s}(r.a.Model)},1390:function(e,t,n){var r=n(10);e.exports=(r.default||r).template({1:function(e,t,n,r,o){var i;e.propertyIsEnumerable;return(null!=(i=e.lambda(null!=(i=null!=t?t.options:t)?i.spinnerEl:i,t))?i:"")+"\r\n"},3:function(e,t,n,r,o){var i;e.propertyIsEnumerable;return null!=(i=n.if.call(null!=t?t:e.nullContext||{},null!=(i=null!=t?t.options:t)?i.videoDeleted:i,{name:"if",hash:{},fn:e.program(4,o,0),inverse:e.program(6,o,0),data:o}))?i:""},4:function(e,t,n,r,o){e.propertyIsEnumerable;return e.escapeExpression((n.lang||t&&t.lang||e.hooks.helperMissing).call(null!=t?t:e.nullContext||{},"deleted",{name:"lang",hash:{},data:o}))+"\r\n"},6:function(e,t,n,r,o){e.propertyIsEnumerable;var i=null!=t?t:e.nullContext||{},a=e.hooks.helperMissing,u=e.escapeExpression;return u((n.lang||t&&t.lang||a).call(i,"exists",{name:"lang",hash:{},data:o}))+' <a class="view-video info-link">'+u((n.lang||t&&t.lang||a).call(i,"clickHere",{name:"lang",hash:{},data:o}))+"</a>\r\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,o){var i;e.propertyIsEnumerable;return null!=(i=n.unless.call(null!=t?t:e.nullContext||{},null!=(i=null!=t?t.options:t)?i.dataFetched:i,{name:"unless",hash:{},fn:e.program(1,o,0),inverse:e.program(3,o,0),data:o}))?i:""},useData:!0})},1454:function(e,t,n){"use strict";n.r(t),n.d(t,"RemigrateVideoView",(function(){return w}));var r=n(2),o=n(5),i=n(1390),a=n.n(i),u=n(303),l=n(264),c=n(1030),s=n(0),f=n(13),p=n(3),h=n(62);function d(e){return(d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function y(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function b(e,t){return(b=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function g(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,r=v(e);if(t){var o=v(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return m(this,n)}}function m(e,t){return!t||"object"!==d(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function v(e){return(v=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var w=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}}),t&&b(e,t)}(m,e);var t,n,i,d=g(m);function m(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,m),d.call(this,e)}return t=m,(n=[{key:"initialize",value:function(){this.spinnerModel=new c.a,this.videoDataService=o.a.getInstance(s.g.Video,this),this.migrationVideoDataService=o.a.getInstance(s.g.MigrationVideo,this),this.options.masterId&&this.listenTo(s.e.VIDEO,"".concat(s.f.VIDEOS,":").concat(this.options.masterId,":error"),this.onError)}},{key:"name",get:function(){return"RemigrateVideoView"}},{key:"title",get:function(){return p.a.getPhrase(this.lang,"title")}},{key:"lang",get:function(){return"migrationWizard.remigrateVideo"}},{key:"template",get:function(){return a.a}},{key:"channelName",get:function(){return f.k.generateUniqueChannelName(this)}},{key:"behaviors",get:function(){return[{behaviorClass:u.e,title:p.a.getPhrase(this.lang,"heading"),spinnerButtonOptions:this.getSpinnerButtonOptions,closeOnRoute:!0}]}},{key:"appLinks",get:function(){return{".view-video":{application:s.b.LIBRARY_EDITOR,action:s.a.LibraryEditor.VIDEO_DETAILS,args:[this.options.masterId]}}}},{key:"getSpinnerButtonOptions",value:function(){var e=this;if(!this.model)return{model:this.spinnerModel,channelName:this.channelName,buttonText:function(){return e.getButtonText()},onClick:function(){return e.migrateVideo()}}}},{key:"getButtonText",value:function(){return this.model?p.a.getPhrase(this.lang,"viewVideo"):p.a.getPhrase(this.lang,"addToLibrary")}},{key:"onVideoSync",value:function(e){e.libraries&&e.libraries.any((function(e){return e.get("type")===h.a.CustomLibrary}))?(this.model=e,this.spinnerModel.set(l.c.Disabled,!1),this.render()):this.onError()}},{key:"onError",value:function(){this.spinnerModel.set(l.c.Disabled,!1),this.render()}},{key:"migrateVideo",value:function(){var e=this;this.spinnerModel.set(l.c.ShowSpinner,!0);var t=new r.a.Collection([{folderChord:this.options.folderChord,videoIds:[this.options.videoId]}]);this.migrationVideoDataService.finaliseCustomerVideos(t,!1,(function(t){e.migrationVideoDataService.clearVideoCache(),e.videoDataService.clearVideoCache(),r.a.AppLinkHelper.trigger({application:s.b.MIGRATION_WIZARD,action:s.a.MigrationWizard.PROGRESS,args:[t.id]})}))}},{key:"dataFetched",value:function(){return!this.spinnerModel.get(l.c.Disabled)}},{key:"onBeforeRender",value:function(){var e=this;!this.model&&this.options.masterId?this.dataFetched()||this.videoDataService.clearCacheAndGetVideo(this.options.masterId,(function(t){return e.onVideoSync(t)}),!1):this.spinnerModel.set(l.c.Disabled,!1)}},{key:"viewOptions",value:function(){return{dataFetched:this.dataFetched(),videoDeleted:!this.model,spinnerEl:f.r.getSpinner({size:f.s.Large,extraClasses:"mx-auto"})}}}])&&y(t.prototype,n),i&&y(t,i),m}(r.a.View)}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp_clickview_library_editor=window.webpackJsonp_clickview_library_editor||[]).push([[68],{1030:function(e,t,n){"use strict";n.d(t,"a",(function(){return p}));var r=n(2),o=n(264);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})(e)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function l(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,r=f(e);if(t){var o=f(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return c(this,n)}}function c(e,t){return!t||"object"!==i(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function f(e){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(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}}),t&&u(e,t)}(c,e);var t,n,r,i=l(c);function c(){return a(this,c),i.apply(this,arguments)}return t=c,(n=[{key:"defaults",value:function(){return e={},t=o.c.Disabled,n=!0,t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e;var e,t,n}}])&&s(t.prototype,n),r&&s(t,r),c}(r.a.Model)},1330:function(e,t,n){var r=n(10);e.exports=(r.default||r).template({1:function(e,t,n,r,o){var i;e.propertyIsEnumerable;return(null!=(i=e.lambda(null!=(i=null!=t?t.options:t)?i.spinnerEl:i,t))?i:"")+"\r\n"},3:function(e,t,n,r,o){var i;e.propertyIsEnumerable;return"<p>"+(null!=(i=(n.lang||t&&t.lang||e.hooks.helperMissing).call(null!=t?t:e.nullContext||{},"approveDescription",{name:"lang",hash:{videoName:null!=(i=null!=t?t.options:t)?i.videoName:i,folderName:null!=(i=null!=t?t.options:t)?i.folderName:i,libraryName:null!=(i=null!=t?t.options:t)?i.libraryName:i},data:o}))?i:"")+"</p>\r\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,o){var i;e.propertyIsEnumerable;return null!=(i=n.unless.call(null!=t?t:e.nullContext||{},null!=(i=null!=t?t.options:t)?i.dataFetched:i,{name:"unless",hash:{},fn:e.program(1,o,0),inverse:e.program(3,o,0),data:o}))?i:""},useData:!0})},1437:function(e,t,n){"use strict";n.r(t),n.d(t,"ApproveStaffRequestView",(function(){return R}));var r=n(6),o=n(2),i=n(5),a=n(4),s=n(42),u=n(303),l=n(264),c=n(0),f=n(1030),p=n(13),h=n(3),y=n(1330),d=n.n(y);function b(e){return(b="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function m(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function v(e,t){return(v=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function g(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,r=w(e);if(t){var o=w(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return S(this,n)}}function S(e,t){return!t||"object"!==b(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function w(e){return(w=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var R=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}}),t&&v(e,t)}(S,e);var t,n,y,b=g(S);function S(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,S),b.call(this,e)}return t=S,(n=[{key:"initialize",value:function(){this.staffRequestDataService=i.a.getInstance(c.g.StaffRequests,this),this.libraryDataService=i.a.getInstance(c.g.Library,this),this.bindListeners()}},{key:"name",get:function(){return"ApproveStaffRequestView"}},{key:"title",get:function(){return h.a.getPhrase(this.lang,"title")}},{key:"lang",get:function(){return"staffRequests.approveStaffRequest"}},{key:"template",get:function(){return d.a}},{key:"tagName",get:function(){return"form"}},{key:"channelName",get:function(){return p.k.generateUniqueChannelName(this)}},{key:"behaviors",get:function(){var e=this;return[{behaviorClass:u.e,title:h.a.getPhrase(this.lang,"approveCheck"),size:"modal-md",spinnerButtonOptions:{model:this.spinnerModel=new f.a,channelName:this.channelName,buttonText:h.a.getPhrase(this.lang,"approve"),onClick:function(t){return e.onSubmit(t)}}}]}},{key:"events",value:function(){return{submit:"onSubmit"}}},{key:"bindListeners",value:function(){var e="".concat(c.f.STAFF_REQUEST_BY_ID,":").concat(this.options.requestId);this.listenTo(c.e.STAFF_REQUEST,"".concat(e,":sync"),this.render),this.listenTo(c.e.STAFF_REQUEST,"".concat(e,":error"),this.redirectToHome);var t="".concat(c.f.STAFF_REQUESTS,":").concat(this.options.requestId,":update");this.listenTo(c.e.STAFF_REQUEST,"".concat(t,":sync"),this.redirectToHome),this.listenTo(c.e.STAFF_REQUEST,"".concat(t,":error"),this.redirectToHome),this.listenTo(c.e.LIBRARY,"folder:".concat(this.options.folderId,":sync"),this.render)}},{key:"fetchData",value:function(){var e=this;this.model=this.staffRequestDataService.getStaffRequest(this.options.requestId),this.library||this.libraryDataService.getLibraries((function(t){e.library=p.f.getLibrary(e.options.libraryId,t),e.render()})),this.folder=this.libraryDataService.getFolder(this.options.folderId)}},{key:"onSubmit",value:function(e){e&&e.preventDefault(),r.Radio.channel(this.channelName).trigger(l.b.ShowSpinner),this.staffRequestDataService.approveStaffRequest(this.options.requestId,this.options.libraryId,this.options.folderId),this.logAction()}},{key:"logAction",value:function(){var e={location:a.LocationContext.Popup,actionType:a.UserAction.Approve,entity:a.EntityType.StaffRequest,workflowPhase:a.WorkflowPhase.Complete},t={id:this.options.requestId,videoId:this.model.get("video")&&this.model.get("video").id,requestingUserId:this.model.get("user")&&this.model.get("user").id,sourceLibraryId:this.model.get("sourceLibrary")&&this.model.get("sourceLibrary").id,sourceFolderId:this.model.get("sourceFolder")&&this.model.get("sourceFolder").id,destinationLibraryId:this.options.libraryId,destinationFolderId:this.options.folderId};s.a.logUserAction(t,e)}},{key:"redirectToHome",value:function(){o.a.AppLinkHelper.trigger({application:c.b.STAFF_REQUESTS,action:c.a.StaffRequests.HOME})}},{key:"viewOptions",value:function(){return{dataFetched:!!this.model&&!!this.library&&!!this.folder,library:this.library&&this.library.get("name"),folder:this.folder&&this.folder.get("name"),spinnerEl:p.r.getSpinner({size:p.s.Large,extraClasses:"mx-auto"}),libraryName:this.library&&p.w.escapeExpression(this.library.get("name")),folderName:this.folder&&p.w.escapeExpression(this.folder.get("name")),videoName:this.model&&this.model.get("video")&&p.w.escapeExpression(this.model.get("video").get("name"))}}},{key:"onBeforeRender",value:function(){this.fetchData(),this.model&&this.library&&this.folder&&this.spinnerModel.set(l.c.Disabled,!1)}}])&&m(t.prototype,n),y&&m(t,y),S}(o.a.View)}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp_clickview_library_editor=window.webpackJsonp_clickview_library_editor||[]).push([[69],{1030:function(e,t,n){"use strict";n.d(t,"a",(function(){return h}));var r=n(2),o=n(264);function c(e){return(c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function l(e,t){return(l=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function s(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,r=f(e);if(t){var o=f(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return u(this,n)}}function u(e,t){return!t||"object"!==c(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function f(e){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var h=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}}),t&&l(e,t)}(u,e);var t,n,r,c=s(u);function u(){return i(this,u),c.apply(this,arguments)}return t=u,(n=[{key:"defaults",value:function(){return e={},t=o.c.Disabled,n=!0,t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e;var e,t,n}}])&&a(t.prototype,n),r&&a(t,r),u}(r.a.Model)},1299:function(e,t,n){var r=n(10);e.exports=(r.default||r).template({1:function(e,t,n,r,o){var c;e.propertyIsEnumerable;return(null!=(c=e.lambda(null!=(c=null!=t?t.options:t)?c.spinnerEl:c,t))?c:"")+"\r\n"},3:function(e,t,n,r,o){var c;e.propertyIsEnumerable;return null!=(c=n.unless.call(null!=t?t:e.nullContext||{},null!=(c=null!=t?t.options:t)?c.alreadyDownloaded:c,{name:"unless",hash:{},fn:e.program(4,o,0),inverse:e.program(6,o,0),data:o}))?c:""},4:function(e,t,n,r,o){e.propertyIsEnumerable;var c=null!=t?t:e.nullContext||{},i=e.hooks.helperMissing,a=e.escapeExpression;return"<p><strong>"+a((n.lang||t&&t.lang||i).call(c,"description",{name:"lang",hash:{},data:o}))+'</strong></p>\r\n<svg height="100" viewBox="0 0 427 100" width="427" xmlns="http://www.w3.org/2000/svg">\r\n <g fill="none" fill-rule="evenodd">\r\n <g fill-rule="nonzero">\r\n <path d="m94.5 55.5c-.5522847 0-1-.4477153-1-1s.4477153-1 1-1h2c.5522847 0 1 .4477153 1 1s-.4477153 1-1 1zm14 0c-.552285 0-1-.4477153-1-1s.447715-1 1-1h2c.552285 0 1 .4477153 1 1s-.447715 1-1 1zm14 0c-.552285 0-1-.4477153-1-1s.447715-1 1-1h2c.552285 0 1 .4477153 1 1s-.447715 1-1 1zm14 0c-.552285 0-1-.4477153-1-1s.447715-1 1-1h2c.552285 0 1 .4477153 1 1s-.447715 1-1 1zm14 0c-.552285 0-1-.4477153-1-1s.447715-1 1-1h2c.552285 0 1 .4477153 1 1s-.447715 1-1 1zm112 0c-.552285 0-1-.4477153-1-1s.447715-1 1-1h2c.552285 0 1 .4477153 1 1s-.447715 1-1 1zm14 0c-.552285 0-1-.4477153-1-1s.447715-1 1-1h2c.552285 0 1 .4477153 1 1s-.447715 1-1 1zm14 0c-.552285 0-1-.4477153-1-1s.447715-1 1-1h2c.552285 0 1 .4477153 1 1s-.447715 1-1 1zm14 0c-.552285 0-1-.4477153-1-1s.447715-1 1-1h2c.552285 0 1 .4477153 1 1s-.447715 1-1 1zm14 0c-.552285 0-1-.4477153-1-1s.447715-1 1-1h2c.552285 0 1 .4477153 1 1s-.447715 1-1 1z" fill="#f8981d"/><path d="m75.3660384 82.489591c-.0757675.0069357-.1518122.010409-.2278965.010409h-54.6179583c-11.70030947 0-19.2714702-8.1915084-19.97109491-19.1076542-.62065424-9.6839806 4.42338321-18.3273466 12.94458521-20.6053076-.4297787-11.9466685 6.5982062-21.1867066 17.1901489-24.2852299 10.2989712-3.0128186 20.88668.7410547 26.0606491 10.0502544 12.8217558-3.457481 26.1104718 8.263297 24.2211271 21.1832845 16.58825 6.4833251 12.6943926 31.07962-5.5995606 32.7542438zm-.3464266-4.989591c13.592216-1.3432135 15.9498811-20.1088375 2.3914689-23.6692862-1.3614422-.3575157-2.1594623-1.7680385-1.7646963-3.11915 3.0734097-10.5189376-8.8471782-21.078668-19.2165057-16.7806108-1.2612369.5227791-2.7086325-.0629726-3.2513006-1.3157806-3.6287978-8.3774717-12.3662807-11.8667544-21.0909115-9.3144869-8.9863414 2.6288273-14.6536056 10.6534543-13.4524943 21.2329216.1549662 1.3649525-.8204237 2.5992336-2.1842308 2.7639765-7.0138244.8472442-11.43239953 7.6566537-10.91209037 15.7749642.54005245 8.4263623 6.08667627 14.4274522 14.98133247 14.4274522z" fill="#e2e2e2"/><path d="m411.5 76h12.5c1.656854 0 3 1.3431458 3 3s-1.343146 3-3 3h-90c-1.656854 0-3-1.3431458-3-3s1.343146-3 3-3h11.5c-4.142136 0-7.5-3.3578644-7.5-7.5v-40c0-4.1421356 3.357864-7.5 7.5-7.5h66c4.142136 0 7.5 3.3578644 7.5 7.5v40c0 4.1421356-3.357864 7.5-7.5 7.5zm-17.5 0h-31c0 1.1045695.895431 2 2 2h27c1.10457 0 2-.8954305 2-2zm-48.5-50c-1.380712 0-2.5 1.1192881-2.5 2.5v40c0 1.3807119 1.119288 2.5 2.5 2.5h66c1.380712 0 2.5-1.1192881 2.5-2.5v-40c0-1.3807119-1.119288-2.5-2.5-2.5z" fill="#e2e2e2"/><path d="m194.688889 46.6708215v4.0154896c-21.037954-1.3356058-31.688889-5.9896514-31.688889-14.6862716 0-1.1045913.891623-2.0000395 1.991496-2.0000395s1.991496.8954482 1.991496 2.0000395c0 5.6687396 9.152444 9.4529958 27.70589 10.6707816zm25.906865.1564809c20.376102-1.018022 30.421254-4.8884966 30.421254-10.8272629 0-1.1045913.891623-2.0000395 1.991496-2.0000395s1.991496.8954482 1.991496 2.0000395c0 8.4131404-9.967884 13.0429588-29.664711 14.5450572zm-25.906865 22.7606388v4.0154864c-21.037953-1.3356021-31.688889-5.9896477-31.688889-14.6862684 0-1.1045913.891623-2.0000395 1.991496-2.0000395s1.991496.8954482 1.991496 2.0000395c0 5.6687397 9.152444 9.4529958 27.70589 10.6707815zm25.879593.1578414c20.394411-1.0159301 30.448526-4.8872081 30.448526-10.8286234 0-1.1045913.891623-2.0000395 1.991496-2.0000395s1.991496.8954482 1.991496 2.0000395c0 9.9178906-13.85241 14.5780829-41.165781 15.0546252zm-55.568482-53.0262704s0 9.9603659 40 9.9603659c11.131238 0 10-6.640244 10-23.24085371 26.666667-3.32012195 40 13.28048781 40 13.28048781s-10 13.2804878-50 13.2804878-40-13.2804878-40-13.2804878z" fill="#f8f8f8"/></g><path d="m199.011905 38.4086355v36.4615785c0 1.1045695.89543 2 2 2 .384934 0 .76169-.1110843 1.085049-.3199204l25.091884-16.205146c.927883-.5992563 1.194287-1.8372468.59503-2.7651291-.115325-.1785696-.258382-.3376117-.423784-.4711387l-25.091884-20.2564325c-.859459-.6938329-2.118651-.5595663-2.812483.2998927-.287178.3557307-.443812.7991133-.443812 1.2562955z" fill="#f8981d"/><path d="m163 16.7249015.011729-.216286.025974-.2387743c1.009035-9.27583682 21.668177-16.2698412 45.79563-16.2698412s44.786596 6.99400437 45.79563 16.2698412l.025974.2387743.01173.216286v65.814781c0 9.5919064-21.048324 16.9642858-45.833334 16.9642858s-45.833333-7.3723794-45.833333-16.9642858zm4 .1084611v65.7063199c0 6.2420953 19.192018 12.9642858 41.833333 12.9642858s41.833334-6.7221905 41.833334-12.9642858v-65.7063199l-.014245-.1309494c-.68278-6.276646-19.663443-12.7024132-41.819089-12.7024132s-41.136309 6.4257672-41.819088 12.7024132z" fill="#e2e2e2" fill-rule="nonzero"/>\r\n </g>\r\n</svg>\r\n<p>'+a((n.lang||t&&t.lang||i).call(c,"nextStep",{name:"lang",hash:{},data:o}))+"</p>\r\n"},6:function(e,t,n,r,o){e.propertyIsEnumerable;return'<p class="m-0">'+e.escapeExpression((n.lang||t&&t.lang||e.hooks.helperMissing).call(null!=t?t:e.nullContext||{},"alreadyAdded",{name:"lang",hash:{},data:o}))+"</p>\r\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,o){var c;e.propertyIsEnumerable;return null!=(c=n.unless.call(null!=t?t:e.nullContext||{},null!=(c=null!=t?t.options:t)?c.dataFetched:c,{name:"unless",hash:{},fn:e.program(1,o,0),inverse:e.program(3,o,0),data:o}))?c:""},useData:!0})},1432:function(e,t,n){"use strict";n.r(t),n.d(t,"DownloadToLocalCacheView",(function(){return w}));var r=n(5),o=n(3),c=n(2),i=n(303),a=n(264),l=n(144),s=n(0),u=n(1030),f=n(13),h=n(100),p=n(1299),d=n.n(p);function y(e){return(y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function m(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function v(e,t){return(v=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function g(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,r=C(e);if(t){var o=C(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return b(this,n)}}function b(e,t){return!t||"object"!==y(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function C(e){return(C=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var w=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}}),t&&v(e,t)}(b,e);var t,n,p,y=g(b);function b(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,b),y.call(this,e)}return t=b,(n=[{key:"initialize",value:function(){this.localCacheDataService=r.a.getInstance(s.g.LocalCache,this),this.bindListeners()}},{key:"name",get:function(){return"DownloadToLocalCacheView"}},{key:"title",get:function(){return o.a.getPhrase(this.lang,"title")}},{key:"lang",get:function(){return"shared.downloadToLocalCache"}},{key:"template",get:function(){return d.a}},{key:"channelName",get:function(){return f.k.generateUniqueChannelName(this)}},{key:"behaviors",get:function(){return this.spinnerModel=new u.a,[{behaviorClass:i.e,title:o.a.getPhrase(this.lang,"popupHeading"),spinnerButtonOptions:this.getSpinnerButtonOptions}]}},{key:"bindListeners",value:function(){var e=this;this.listenTo(s.e.USER,"".concat(s.f.CURRENT_USER,":sync"),this.render),this.listenTo(s.e.LOCAL_CACHE,"".concat(s.f.LOCAL_CACHE_DEVICES,":sync"),this.render),this.listenTo(s.e.LOCAL_CACHE,"".concat(s.f.LOCAL_CACHE_DOWNLOADS,":").concat(this.options.videoId,":sync"),this.render),this.listenTo(s.e.LOCAL_CACHE,"".concat(s.f.ADD_VIDEO_TO_LOCAL_CACHE,":sync"),(function(){return e.triggerMethod("hide")})),this.listenTo(s.e.LOCAL_CACHE,"".concat(s.f.ADD_VIDEO_TO_LOCAL_CACHE,":error"),(function(){return e.triggerMethod("hide")}))}},{key:"getSpinnerButtonOptions",value:function(){var e=this;if(!this.localCacheDownloads||!this.localCacheDownloads.length)return{model:this.spinnerModel,channelName:this.channelName,buttonText:o.a.getPhrase(this.lang,"buttonText"),onClick:function(){return e.onClickAddToLocalCache()}}}},{key:"onClickAddToLocalCache",value:function(){this.spinnerModel.set(a.c.ShowSpinner,!0),this.localCacheDataService.downloadVideoToLocalCache(this.model.get("deviceId"),this.options.videoId)}},{key:"requiredResources",get:function(){return{currentUser:l.b.currentUser}}},{key:"onBeforeRender",value:function(){var e=this.localCacheDataService.getDevices(this.currentUser.get("customerId"));return this.localCacheDownloads=this.localCacheDataService.getDownloadsForVideos([this.options.videoId]),!(e&&this.localCacheDownloads&&(this.model=f.i.getNewestDeviceUserCanManage(e,this.currentUser.get("customerId")),this.model?(this.spinnerModel.set(a.c.Disabled,!1),0):(setTimeout((function(){return c.a.ErrorHelper.throw(new h.c)}),0),1)))}},{key:"viewOptions",value:function(){return{dataFetched:!!this.model&&!!this.localCacheDownloads,spinnerEl:f.r.getSpinner({size:f.s.Large,extraClasses:"mx-auto"}),alreadyDownloaded:this.localCacheDownloads&&this.localCacheDownloads.length}}}])&&m(t.prototype,n),p&&m(t,p),b}(c.a.View)}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp_clickview_library_editor=window.webpackJsonp_clickview_library_editor||[]).push([[7],{1030:function(e,t,n){"use strict";n.d(t,"a",(function(){return d}));var r=n(2),o=n(264);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})(e)}function l(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function s(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,r=f(e);if(t){var o=f(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return c(this,n)}}function c(e,t){return!t||"object"!==i(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function f(e){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var d=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}}),t&&u(e,t)}(c,e);var t,n,r,i=s(c);function c(){return l(this,c),i.apply(this,arguments)}return t=c,(n=[{key:"defaults",value:function(){return e={},t=o.c.Disabled,n=!0,t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e;var e,t,n}}])&&a(t.prototype,n),r&&a(t,r),c}(r.a.Model)},1038:function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n(1),o=n(48),i=n(168),l=n(3),a="libraryEditor.utils",u={name:[{required:!0,msg:function(){return l.a.getPhrase(a,"folderNameRequired")}},{maxLength:255,msg:function(){return l.a.getPhrase(a,"folderNameExceeds")}}]},s=function(e,t){return{parentId:function(n){return n?o.a.calculateDestinationFolderDepth(e,n,t)>i.a.MAX_FOLDER_DEPTH?l.a.getPhrase(a,"maxFolderDepth",{maxDepth:i.a.MAX_FOLDER_DEPTH}):"":l.a.getPhrase(a,"selectParentFolder")}}},c=function(e){var t=e.validateName,n=e.validateParent,o=e.folder,i=e.collection;return t&&n?r.extend({},u,s(o,i)):t?u:n?s(o,i):void 0}},1047:function(e,t,n){"use strict";n.d(t,"a",(function(){return v}));var r=n(6),o=n(2),i=n(3),l=n(1061),a=n(13),u=n(1048),s=n.n(u),c=n(1049),f=n.n(c);function d(e){return(d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function p(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function h(e,t){return(h=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function y(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,r=m(e);if(t){var o=m(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return b(this,n)}}function b(e,t){return!t||"object"!==d(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function m(e){return(m=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(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}}),t&&h(e,t)}(c,e);var t,n,o,u=y(c);function c(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,c),u.call(this,e)}return t=c,(n=[{key:"initialize",value:function(){this.listenTo(this.options.channelName,"folder:selected new:folder:selected",this.setButtonText),this.listenTo(this.options.channelName,"re:render:selector",this.renderSelector),this.disabledIds=this.options.disabledIds&&this.options.disabledIds.reduce((function(e,t){return Object.assign(Object.assign({},e),function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}({},t,!0))}),{})}},{key:"name",get:function(){return"TreeDropdownComponent"}},{key:"template",get:function(){return s.a}},{key:"className",get:function(){return"position-relative"}},{key:"lang",get:function(){return"libraryEditor.treeDropdown"}},{key:"regions",value:function(){return{selector:{el:".selector-region",replaceElement:!1}}}},{key:"events",value:function(){return{"click .create-new":"onClickCreateNew"}}},{key:"defaults",get:function(){return{disabledIds:[]}}},{key:"elements",get:function(){return{button:".custom-select"}}},{key:"onClickCreateNew",value:function(e){e.preventDefault(),r.Radio.channel(this.options.channelName).trigger("create:folder:clicked")}},{key:"setButtonText",value:function(e,t){if(e&&!t){var n=e.get("name");this.getUI("button").text(n)}else{var r=a.f.getSelected(this.options.folderTreeKey,this.collection),o=r?r.get("name"):i.a.getPhrase(this.lang,"button");this.getUI("button").text(o)}}},{key:"renderSelector",value:function(){this.showChildView("selector",new l.a({styles:f.a,collection:this.collection,channelName:this.options.channelName,childrenProperty:"children",folderTreeId:this.options.folderTreeKey,extraClass:f.a.list,extraClasses:f.a.list,isSelector:!0,disabledIds:this.disabledIds||{}}))}},{key:"viewOptions",value:function(){return{styles:f.a,name:this.options.name||this.options.channelName,buttonText:this.buttonText,canCreateNew:this.options.canCreateNew}}},{key:"onRender",value:function(){this.setButtonText(),this.renderSelector()}}])&&p(t.prototype,n),o&&p(t,o),c}(o.a.Component)},1048:function(e,t,n){var r=n(10);e.exports=(r.default||r).template({1:function(e,t,n,r,o){e.propertyIsEnumerable;var i,l=e.escapeExpression;return' <button class="create-new btn font-weight-bold rounded-0 w-100 text-left '+l(e.lambda(null!=(i=null!=(i=null!=t?t.options:t)?i.styles:i)?i.customItem:i,t))+'">'+l((n.lang||t&&t.lang||e.hooks.helperMissing).call(null!=t?t:e.nullContext||{},"createNew",{name:"lang",hash:{},data:o}))+"</button>\r\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,o){e.propertyIsEnumerable;var i,l=e.lambda,a=e.escapeExpression;return'<button\r\n class="'+a(l(null!=(i=null!=(i=null!=t?t.options:t)?i.styles:i)?i.selectBtn:i,t))+' custom-select form-control"\r\n data-toggle="dropdown"\r\n aria-haspopup="true"\r\n aria-expanded="false"\r\n name='+a(l(null!=(i=null!=t?t.options:t)?i.name:i,t))+"\r\n>"+a(l(null!=(i=null!=t?t.options:t)?i.buttonText:i,t))+'</button>\r\n<div class="dropdown-menu '+a(l(null!=(i=null!=(i=null!=t?t.options:t)?i.styles:i)?i.selector:i,t))+'">\r\n <div class="selector-region"></div>\r\n'+(null!=(i=n.if.call(null!=t?t:e.nullContext||{},null!=(i=null!=t?t.options:t)?i.canCreateNew:i,{name:"if",hash:{},fn:e.program(1,o,0),inverse:e.noop,data:o}))?i:"")+'</div>\r\n<div class="form-feedback"></div>'},useData:!0})},1049:function(e,t,n){e.exports={selectBtn:"_2TTgs",list:"_3wN7o",selector:"_3Xf1P",customItem:"_199PI"}},1105:function(e,t,n){"use strict";n.d(t,"a",(function(){return b}));var r=n(2),o=n(303),i=n(13),l=n(1047),a=n(1038),u=n(1106),s=n.n(u);function c(e){return(c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function f(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function d(e,t){return(d=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function p(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,r=y(e);if(t){var o=y(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return h(this,n)}}function h(e,t){return!t||"object"!==c(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function y(e){return(y=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var b=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}}),t&&d(e,t)}(c,e);var t,n,r,u=p(c);function c(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,c),u.call(this,e)}return t=c,(n=[{key:"initialize",value:function(){this.bindListeners()}},{key:"bindListeners",value:function(){this.listenTo(this.options.channelName,"folder:selected",this.onFolderSelected)}},{key:"name",get:function(){return"FolderDetailsComponent"}},{key:"template",get:function(){return s.a}},{key:"lang",get:function(){return"libraryEditor.folderDetails"}},{key:"folderTreeKey",get:function(){return this.options.folderTreeKey||"folderselect:".concat(this.cid)}},{key:"regions",value:function(){return{parentFolder:".parent-folder-region"}}},{key:"behaviors",get:function(){return[{behaviorClass:o.a,modelValidation:Object(a.a)({validateName:this.options.editName,validateParent:this.options.editParent,folder:this.options.model,collection:this.options.collection})},{behaviorClass:o.f}]}},{key:"bindings",get:function(){return{"[name=name]":{observe:"name",setOptions:{validate:!0}}}}},{key:"onFolderSelected",value:function(e,t){e&&(i.f.setSelected(this.folderTreeKey,e,this.collection,t),t||this.model.set("parentId",e.get("id"),{validate:!0}))}},{key:"renderSubFolders",value:function(){this.options.editParent&&this.showChildView("parentFolder",new l.a({collection:this.collection,channelName:this.options.channelName,folderTreeKey:this.folderTreeKey,disabledIds:this.options.disabledParentFolderIds}))}},{key:"viewOptions",value:function(){return{editName:this.options.editName,editParent:this.options.editParent}}},{key:"onRender",value:function(){this.renderSubFolders()}}])&&f(t.prototype,n),r&&f(t,r),c}(r.a.Component)},1106:function(e,t,n){var r=n(10);e.exports=(r.default||r).template({1:function(e,t,n,r,o){e.propertyIsEnumerable;var i=null!=t?t:e.nullContext||{},l=e.hooks.helperMissing,a=e.escapeExpression;return' <div class="form-group">\r\n <label for="name" class="control-label">'+a((n.lang||t&&t.lang||l).call(i,"name",{name:"lang",hash:{},data:o}))+'</label>\r\n <input name="name" id="name" type="text" class="form-control" placeholder="'+a((n.lang||t&&t.lang||l).call(i,"namePlaceholder",{name:"lang",hash:{},data:o}))+'" autocomplete="off" autofocus/>\r\n <div class="form-feedback"></div>\r\n </div>\r\n'},3:function(e,t,n,r,o){e.propertyIsEnumerable;return' <div class="form-group pt-2">\r\n <label for="parentId" class="control-label">'+e.escapeExpression((n.lang||t&&t.lang||e.hooks.helperMissing).call(null!=t?t:e.nullContext||{},"parent",{name:"lang",hash:{},data:o}))+'</label>\r\n <div class="parent-folder-region"></div>\r\n </div>\r\n'},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,o){e.propertyIsEnumerable;var i,l=null!=t?t:e.nullContext||{};return"<form>\r\n"+(null!=(i=n.if.call(l,null!=(i=null!=t?t.options:t)?i.editName:i,{name:"if",hash:{},fn:e.program(1,o,0),inverse:e.noop,data:o}))?i:"")+(null!=(i=n.if.call(l,null!=(i=null!=t?t.options:t)?i.editParent:i,{name:"if",hash:{},fn:e.program(3,o,0),inverse:e.noop,data:o}))?i:"")+"</form>"},useData:!0})},1229:function(e,t,n){var r=n(10);e.exports=(r.default||r).template({1:function(e,t,n,r,o){var i;e.propertyIsEnumerable;return(null!=(i=e.lambda(null!=(i=null!=t?t.options:t)?i.spinnerEl:i,t))?i:"")+"\r\n"},3:function(e,t,n,r,o){return'<div class="folder-details-region"></div>\r\n'},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,o){var i;e.propertyIsEnumerable;return null!=(i=n.unless.call(null!=t?t:e.nullContext||{},null!=(i=null!=t?t.options:t)?i.dataFetched:i,{name:"unless",hash:{},fn:e.program(1,o,0),inverse:e.program(3,o,0),data:o}))?i:""},useData:!0})},1419:function(e,t,n){"use strict";n.r(t),n.d(t,"NewFolderView",(function(){return E}));var r=n(6),o=n(19),i=n(2),l=n(5),a=n(30),u=n(42),s=n(303),c=n(0),f=n(84),d=n(1030),p=n(87),h=n(13),y=n(264),b=n(3),m=n(1105),v=n(1229),g=n.n(v),w=n(205);function k(e){return(k="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function O(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function P(e,t){return(P=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function S(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,r=I(e);if(t){var o=I(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return _(this,n)}}function _(e,t){return!t||"object"!==k(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function I(e){return(I=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var E=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}}),t&&P(e,t)}(_,e);var t,n,v,k=S(_);function _(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,_),k.call(this,e)}return t=_,(n=[{key:"initialize",value:function(e){var t=e.parentId,n=e.libraryId;(t?!n:n)||i.a.ErrorHelper.throw(new o.a("Must provide either a libraryId or a parentId to ".concat(this.name))),this.bindListeners(),this.libraryDataService=l.a.getInstance(c.g.Library,this)}},{key:"bindListeners",value:function(){this.listenTo(c.e.LIBRARY,"libraries:sync",this.render)}},{key:"name",get:function(){return"NewFolderView"}},{key:"lang",get:function(){return"libraryEditor.newFolder"}},{key:"title",get:function(){return b.a.getPhrase(this.lang,"title")}},{key:"folderTreeKey",get:function(){return"folderselect:".concat(this.cid)}},{key:"template",get:function(){return g.a}},{key:"channelName",get:function(){return h.k.generateUniqueChannelName(this)}},{key:"behaviors",get:function(){var e=this;return[{behaviorClass:s.e,title:b.a.getPhrase(this.lang,"heading"),appLink:this.options.returnAppLink,spinnerButtonOptions:{model:this.spinnerModel=new d.a,channelName:this.channelName,buttonText:b.a.getPhrase(this.lang,"create"),onClick:function(t){return e.onSubmit(t)}}}]}},{key:"regions",value:function(){return{folderDetails:".folder-details-region"}}},{key:"events",value:function(){return{submit:"onSubmit"}}},{key:"onSubmit",value:function(e){e&&e.preventDefault(),this.viewModel.validate(),!1!==this.viewModel.isValid()&&(r.Radio.channel(this.channelName).trigger(y.b.ShowSpinner),this.trimFolderName(),this.addFolder(),this.logAction())}},{key:"addFolder",value:function(){var e=this,t=this.viewModel.get("parentId").toString()===this.library.get("id").toString()?null:this.viewModel.get("parentId").toString();this.libraryDataService.addFolder(this.viewModel,this.library.get("id").toString(),t,(function(t){a.a.clear(e.getViewModelKey()),e.options.routeToFolderOnCreate?i.a.AppLinkHelper.trigger({application:c.b.LIBRARY_EDITOR,action:c.a.LibraryEditor.FOLDER,args:[t.get("id")]}):e.triggerMethod("hide")}))}},{key:"trimFolderName",value:function(){var e=this.viewModel.get("name");this.viewModel.set("name",e.trim())}},{key:"logAction",value:function(){var e={id:this.options.libraryId,name:this.viewModel.get("name"),isSubfolder:this.viewModel.get("parentId").toString()!==this.library.get("id").toString()};u.a.logUserAction(e,this.options.analyticsOptions)}},{key:"setUpViewModel",value:function(){if(!this.viewModel){var e=this.getViewModelKey();this.viewModel=a.a.get(e,null,{ctor:p.a}),this.viewModel.set({parentId:this.options.parentId||this.options.libraryId})}}},{key:"getViewModelKey",value:function(){return"folder:new:".concat(this.options.libraryId,":").concat(this.options.parentId)}},{key:"renderFolderDetails",value:function(){if(this.collection){var e=new m.a({model:this.viewModel,collection:this.collection,library:this.library,channelName:this.channelName,editName:!0,editParent:!0,folderTreeKey:this.folderTreeKey});this.showChildView("folderDetails",e)}}},{key:"onBeforeRender",value:function(){var e=this;if(this.libraryDataService.getLibraries((function(t){if(!e.collection){var n=e.options.libraryId||e.options.parentId;e.library=h.f.getLibrary(n,t),e.setUpViewModel(),e.collection=new f.a([e.library]),h.f.setSelected(e.folderTreeKey,e.viewModel.get("parentId"),e.collection)}})),this.collection&&this.spinnerModel.set(y.c.Disabled,!1),h.f.getFolderDepth(this.options.parentId,this.collection)>=c.s.MAX_FOLDER_DEPTH)return window.setTimeout((function(){e.triggerMethod("hide"),i.a.ErrorHelper.throw(new w.b)}),c.s.POPUP_FADE_TIMEOUT),!1}},{key:"viewOptions",value:function(){return{dataFetched:!!this.collection,spinnerEl:h.r.getSpinner({size:h.s.Large,extraClasses:"mx-auto"})}}},{key:"onRender",value:function(){this.renderFolderDetails()}}])&&O(t.prototype,n),v&&O(t,v),_}(i.a.View)}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp_clickview_library_editor=window.webpackJsonp_clickview_library_editor||[]).push([[71],{1293:function(e,t,n){var r=n(10);e.exports=(r.default||r).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){var o;e.propertyIsEnumerable;return null!=(o=(n.lang||t&&t.lang||e.hooks.helperMissing).call(null!=t?t:e.nullContext||{},"check",{name:"lang",hash:{name:null!=t?t.name:t},data:i}))?o:""},useData:!0})},1427:function(e,t,n){"use strict";n.r(t),n.d(t,"DeleteLibraryView",(function(){return k}));var r=n(6),i=n(5),o=n(2),a=n(42),l=n(0),c=n(303),u=n(13),s=n(264),f=n(3),h=n(205),y=n(1293),p=n.n(y);function b(e){return(b="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function g(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function m(e,t){return(m=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function d(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,r=w(e);if(t){var i=w(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return v(this,n)}}function v(e,t){return!t||"object"!==b(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function w(e){return(w=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var k=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}}),t&&m(e,t)}(v,e);var t,n,y,b=d(v);function v(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,v),b.call(this,e)}return t=v,(n=[{key:"initialize",value:function(){this.listenTo(l.e.LIBRARY,"libraries:sync",this.render),this.libraryDataService=i.a.getInstance(l.g.Library,this)}},{key:"name",get:function(){return"DeleteLibraryView"}},{key:"title",get:function(){return!!this.model&&f.a.getPhrase(this.lang,"title",{libraryName:this.model.get("name")})}},{key:"lang",get:function(){return"libraryEditor.deleteLibrary"}},{key:"template",get:function(){return p.a}},{key:"channelName",get:function(){return u.k.generateUniqueChannelName(this)}},{key:"behaviors",get:function(){var e=this;return[{title:f.a.getPhrase(this.lang,"removeLibrary"),behaviorClass:c.e,spinnerButtonOptions:{channelName:this.channelName,buttonText:f.a.getPhrase(this.lang,"remove"),extraButtonClass:"btn-danger",onClick:function(){return e.onClickDelete()}}}]}},{key:"onClickDelete",value:function(){r.Radio.channel(this.channelName).trigger(s.b.ShowSpinner),this.libraryDataService.deleteLibrary(this.options.libraryId,(function(){o.a.AppLinkHelper.trigger({application:l.b.LIBRARY_EDITOR,action:l.a.LibraryEditor.HOME})})),this.logAction()}},{key:"logAction",value:function(){var e={id:this.options.libraryId};a.a.logUserAction(e,this.options.analyticsOptions)}},{key:"onBeforeRender",value:function(){var e=this;if(this.libraryDataService.getFolderFromLibraries(this.options.libraryId,(function(t){e.model=t})),!this.model)return!1;var t=null;return this.model.get("hasSubscribers")?t=new h.h:this.model.children.length&&(t=new h.i),t?(window.setTimeout((function(){e.triggerMethod("hide"),o.a.ErrorHelper.throw(t)}),l.s.POPUP_FADE_TIMEOUT),!1):!!this.model}}])&&g(t.prototype,n),y&&g(t,y),v}(o.a.View)}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp_clickview_library_editor=window.webpackJsonp_clickview_library_editor||[]).push([[72],{1203:function(t,e,n){var r=n(10);t.exports=(r.default||r).template({compiler:[8,">= 4.3.0"],main:function(t,e,n,r,o){return'<div class="no-library-region"></div>'},useData:!0})},1416:function(t,e,n){"use strict";n.r(e),n.d(e,"NoLibraryView",(function(){return v}));var r=n(2),o=n(3),i=n(16),u=n(307),c=n(9),a=n(0),f=n(1203),l=n.n(f);function p(t){return(p="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)}function s(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function y(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function b(t,e){return(b=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function h(t){var e=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(t){return!1}}();return function(){var n,r=m(t);if(e){var o=m(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return g(this,n)}}function g(t,e){return!e||"object"!==p(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function m(t){return(m=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}var v=function(t){!function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&b(t,e)}(p,t);var e,n,r,f=h(p);function p(){return s(this,p),f.apply(this,arguments)}return e=p,(n=[{key:"name",get:function(){return"NoLibraryView"}},{key:"title",get:function(){return o.a.getPhrase(this.lang,"title")}},{key:"lang",get:function(){return"libraryEditor.noLibrary"}},{key:"template",get:function(){return l.a}},{key:"regions",value:function(){return{emptyState:{el:".no-library-region",replaceElement:!0}}}},{key:"behaviors",get:function(){return[{behaviorClass:u.a,region:"emptyState",type:c.c.LibraryEditor,shouldRender:function(){return!0},componentOptions:{plusSvg:i.a.getSvg(i.b.Plus),heading:o.a.getPhrase(this.lang,"emptyStateHeading"),btnText:o.a.getPhrase(this.lang,"emptyStateDescription")},emptyStateComponents:a.h}]}}])&&y(e.prototype,n),r&&y(e,r),p}(r.a.View)}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp_clickview_library_editor=window.webpackJsonp_clickview_library_editor||[]).push([[8],{1030:function(e,t,n){"use strict";n.d(t,"a",(function(){return p}));var o=n(2),r=n(264);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})(e)}function c(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(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,o.key,o)}}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function l(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=f(e);if(t){var r=f(this).constructor;n=Reflect.construct(o,arguments,r)}else n=o.apply(this,arguments);return a(this,n)}}function a(e,t){return!t||"object"!==i(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function f(e){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(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}}),t&&u(e,t)}(a,e);var t,n,o,i=l(a);function a(){return c(this,a),i.apply(this,arguments)}return t=a,(n=[{key:"defaults",value:function(){return e={},t=r.c.Disabled,n=!0,t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e;var e,t,n}}])&&s(t.prototype,n),o&&s(t,o),a}(o.a.Model)},1039:function(e,t,n){"use strict";n.d(t,"a",(function(){return p}));var o=n(1),r=n(2),i=n(310);function c(e){return(c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function s(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,o.key,o)}}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function l(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=f(e);if(t){var r=f(this).constructor;n=Reflect.construct(o,arguments,r)}else n=o.apply(this,arguments);return a(this,n)}}function a(e,t){return!t||"object"!==c(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function f(e){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(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}}),t&&u(e,t)}(a,e);var t,n,r,c=l(a);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:"name",get:function(){return"DropdownCollectionComponent"}},{key:"className",get:function(){return"dropdown-menu items-viewpart ".concat(this.getExtraClasses(this.options.displayOptions))}},{key:"attributes",get:function(){return{"aria-labelledby":"dropdownSelector"}}},{key:"initialize",value:function(){this.listenTo(this.options.channelName,"center:dropdown",this.centerSelectedItem)}},{key:"childView",get:function(){return i.a}},{key:"childViewOptions",get:function(){var e={channelName:this.options.channelName,analyticsHelper:this.options.analyticsHelper};return o.extend(e,this.options.childOptions)}},{key:"getExtraClasses",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.alignment,n=void 0===t?"left":t,o=e.extraClasses,r="dropdown-menu-".concat(n);return o&&(r="".concat(r," ").concat(o)),r}},{key:"centerSelectedItem",value:function(){var e=this.$el.find(".active");if(e.length){var t=this.$el.scrollTop()+e.position().top,n=.5*this.$el.height()+.5*e.height();this.$el.scrollTop(t-n)}}}])&&s(t.prototype,n),r&&s(t,r),a}(r.a.ComponentCollection)},1191:function(e,t,n){e.exports={select:"_1rbBR",selectButton:"htYy7",svgContainer:"_1sQ7D",groupButton:"_2CM1D",groupButtons:"_3uv-z",groupButtonSelected:"uC5RG",buttonDisabled:"_3-I1L",mediumWeight:"_10amI"}},1247:function(e,t,n){var o=n(10);e.exports=(o.default||o).template({1:function(e,t,n,o,r){e.propertyIsEnumerable;var i,c=e.lambda,s=e.escapeExpression;return'<label for="'+s(c(null!=(i=null!=t?t.options:t)?i.buttonId:i,t))+'" class="control-label">'+s(c(null!=(i=null!=t?t.options:t)?i.labelText:i,t))+"</label>\r\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,o,r){e.propertyIsEnumerable;var i,c=e.lambda,s=e.escapeExpression;return(null!=(i=n.if.call(null!=t?t:e.nullContext||{},null!=(i=null!=t?t.options:t)?i.labelText:i,{name:"if",hash:{},fn:e.program(1,r,0),inverse:e.noop,data:r}))?i:"")+'<button class="dropdown-toggle form-control btn-block text-left '+s(c(null!=(i=null!=t?t.options:t)?i.buttonClass:i,t))+'" type="button" id="'+s(c(null!=(i=null!=t?t.options:t)?i.buttonId:i,t))+'" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">\r\n '+s(c(null!=(i=null!=t?t.options:t)?i.selected:i,t))+'\r\n</button>\r\n<div class="dropdown-menu-region"></div>'},useData:!0})},1248:function(e,t,n){var o=n(10);e.exports=(o.default||o).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,o,r){return'<div class="year-group-region"></div>\r\n<div name="year" class="mt-3"></div>'},useData:!0})},1249:function(e,t,n){var o=n(10);e.exports=(o.default||o).template({1:function(e,t,n,o,r){var i;e.propertyIsEnumerable;return(null!=(i=e.lambda(null!=(i=null!=t?t.options:t)?i.spinnerEl:i,t))?i:"")+"\r\n"},3:function(e,t,n,o,r){e.propertyIsEnumerable;var i,c=e.lambda,s=e.escapeExpression;return'<div class="d-flex align-items-center">\r\n<label class="control-label m-0 pb-2">'+s(c(null!=(i=null!=t?t.options:t)?i.restrictFromLabel:i,t))+"</label>\r\n"+(null!=(i=n.if.call(null!=t?t:e.nullContext||{},null!=(i=null!=t?t.options:t)?i.supportUrl:i,{name:"if",hash:{},fn:e.program(4,r,0),inverse:e.noop,data:r}))?i:"")+'</div>\r\n<div class="dropdown-region '+s(c(null!=(i=null!=(i=null!=t?t.options:t)?i.styles:i)?i.select:i,t))+' mb-3"></div>\r\n<div class="access-view-region"></div>\r\n'},4:function(e,t,n,o,r){e.propertyIsEnumerable;var i,c=e.lambda,s=e.escapeExpression;return'<a \r\n class="d-inline-block ml-1 mb-3 '+s(c(null!=(i=null!=(i=null!=t?t.options:t)?i.styles:i)?i.svgContainer:i,t))+'"\r\n title="'+s((n.lang||t&&t.lang||e.hooks.helperMissing).call(null!=t?t:e.nullContext||{},"findOutMore",{name:"lang",hash:{},data:r}))+'"\r\n href="'+s(c(null!=(i=null!=t?t.options:t)?i.supportUrl:i,t))+'" \r\n target="_blank"\r\n>\r\n '+(null!=(i=c(null!=(i=null!=t?t.options:t)?i.svg:i,t))?i:"")+"\r\n</a>\r\n"},compiler:[8,">= 4.3.0"],main:function(e,t,n,o,r){var i;e.propertyIsEnumerable;return null!=(i=n.unless.call(null!=t?t:e.nullContext||{},null!=(i=null!=t?t.options:t)?i.dataFetched:i,{name:"unless",hash:{},fn:e.program(1,r,0),inverse:e.program(3,r,0),data:r}))?i:""},useData:!0})},1464:function(e,t,n){"use strict";n.r(t);var o=n(1),r=n(6),i=n(2),c=n(5),s=n(3),u=n(16),l=n(143),a=n(308),f=n(306),p=n(1030),h=n(303),d=n(4),y=n(42),g=n(13),m=n(369),b=n(0),v=n(144),w=n(200),k=n(9),O=n(264),S=n(1039),C=n(1247),R=n.n(C);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})(e)}function _(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,o.key,o)}}function P(e,t){return(P=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(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=x(e);if(t){var r=x(this).constructor;n=Reflect.construct(o,arguments,r)}else n=o.apply(this,arguments);return j(this,n)}}function j(e,t){return!t||"object"!==I(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function x(e){return(x=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var N=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}}),t&&P(e,t)}(i,e);var t,n,o,r=E(i);function i(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),r.call(this,e)}return t=i,(n=[{key:"initialize",value:function(){var e=this.model?this.model.get("id"):"";g.c.setSelected(e,this.collection),this.listenTo(this.options.channelName,this.options.eventName,this.onSelect)}},{key:"name",get:function(){return"DropdownComponent"}},{key:"template",get:function(){return R.a}},{key:"className",get:function(){return this.options.buttonClass?"select-channel ".concat(this.options.buttonClass):"select-channel"}},{key:"regions",value:function(){return{dropdown:{el:".dropdown-menu-region",replaceElement:!0}}}},{key:"onSelect",value:function(e){g.c.setSelected(e.get("id"),this.collection),this.render()}},{key:"viewOptions",value:function(){var e=g.c.getSelected(this.collection);return Object.assign({selected:e&&e.get("name")},this.options)}},{key:"getIsOptionDisabledFn",value:function(){var e=g.c.getSelected(this.collection),t=e&&e.id;return function(){return!!t&&(t=t.toString(),this.model.get("id").toString()===t)}}},{key:"renderChannelDropdown",value:function(){this.showChildView("dropdown",new S.a({collection:this.collection,channelName:this.options.channelName,childOptions:{titleProperty:this.options.titleProperty,isDisabled:this.getIsOptionDisabledFn(),eventName:this.options.eventName},displayOptions:this.options.displayOptions,analyticsHelper:this.options.analyticsHelper}))}},{key:"onRender",value:function(){this.renderChannelDropdown()}}])&&_(t.prototype,n),o&&_(t,o),i}(i.a.Component),T=n(1191),D=n.n(T),A=n(1248),V=n.n(A);function B(e){return(B="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function G(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function M(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,o.key,o)}}function U(e,t,n){return t&&M(e.prototype,t),n&&M(e,n),e}function F(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}}),t&&Y(e,t)}function Y(e,t){return(Y=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function L(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=H(e);if(t){var r=H(this).constructor;n=Reflect.construct(o,arguments,r)}else n=o.apply(this,arguments);return z(this,n)}}function z(e,t){return!t||"object"!==B(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function H(e){return(H=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var $=function(e){F(n,e);var t=L(n);function n(){return G(this,n),t.apply(this,arguments)}return U(n,[{key:"name",get:function(){return"RestrictAccessYearGroupItemView"}},{key:"className",get:function(){var e="btn text-center p-0 pb-1 pt-1 ".concat(D.a.groupButton);return this.model.get("selected")&&(e+=" ".concat(D.a.groupButtonSelected)),e}},{key:"tagName",get:function(){return"button"}},{key:"attributes",get:function(){var e=100/this.model.collection.length;return{type:"button",style:"width: ".concat(e,"%")}}},{key:"template",get:function(){var e=this.model.get("year");return"<span>".concat(e,"</span>")}},{key:"events",value:function(){return{click:"onClick"}}},{key:"onClick",value:function(){r.Radio.channel(this.options.channelName).trigger("group:selected",this.model)}}]),n}(i.a.Component),q=function(e){F(n,e);var t=L(n);function n(){return G(this,n),t.apply(this,arguments)}return U(n,[{key:"initialize",value:function(){this.bindListeners()}},{key:"name",get:function(){return"RestrictAccessYearGroupComponentCollection"}},{key:"className",get:function(){return"btn-group w-100 ".concat(D.a.groupButtons)}},{key:"channelName",get:function(){return"".concat(this.name).concat(this.cid)}},{key:"childView",get:function(){return $}},{key:"childViewOptions",get:function(){return{channelName:this.channelName}}},{key:"bindListeners",value:function(){this.listenTo(this.channelName,"group:selected",this.onYearGroupSelected)}},{key:"onYearGroupSelected",value:function(e){this.collection.each((function(t){return t.set("selected",t.get("groupId")<=e.get("groupId"))})),this.model.set("groupId",e.get("groupId")),this.model.set("yearGroup",e.get("groupId")),this.render()}},{key:"onBeforeRender",value:function(){var e=this.model.get("yearGroup")||this.model.get("groupId");e&&(this.collection.each((function(t){return t.set("selected",t.get("groupId")<=e)})),this.model.set("groupId",e))}}]),n}(i.a.CollectionView),J=function(e){F(n,e);var t=L(n);function n(){return G(this,n),t.apply(this,arguments)}return U(n,[{key:"initialize",value:function(){this.configDataService=c.a.getInstance(b.g.Config,this)}},{key:"name",get:function(){return"RestrictAccessGroupComponent"}},{key:"lang",get:function(){return"shared.restrictAccess"}},{key:"props",get:function(){return["configDataService","currentUser"]}},{key:"template",get:function(){return V.a}},{key:"bindings",get:function(){var e=this;return{"[name=year]":{observe:"groupId",onGet:function(t){return e.buildGroupMessage(t)},updateMethod:"html",escape:!1}}}},{key:"regions",value:function(){return{yearGroupList:{replaceElement:!0,el:".year-group-region"}}}},{key:"requiredResources",get:function(){return{currentUser:v.b.currentUser}}},{key:"viewOptions",value:function(){return{styles:D.a}}},{key:"onBeforeRender",value:function(){var e=this;this.yearGroups||this.getYearGroups(),o.some(this.yearGroups,(function(t){return t.groupId===e.model.get("groupId")}))||this.model.set("groupId",void 0)}},{key:"onRender",value:function(){this.stickit(),this.showChildView("yearGroupList",new q({model:this.model,collection:new i.a.Collection(this.yearGroups)}))}},{key:"onBeforeDestroy",value:function(){this.unstickit()}},{key:"getYearGroups",value:function(){var e=this,t=this.configDataService.getCustomerYearGroups(this.currentUser.get("countryCode"));this.yearGroups=[],o.keys(k.n).forEach((function(n){var r=parseInt(n,10);if(!o.isNaN(r)&&o.contains(t,r)){var i=r===k.n.Kindergarten?"K":k.n[r].replace("Year","Y");e.yearGroups.push({year:i,groupId:r})}}))}},{key:"buildGroupMessage",value:function(e){if(e){var t=g.o.mapYearGroupToName(e);return s.a.getPhrase(this.lang,"selectedYearGroups",{classNames:D.a.mediumWeight,groupName:t})}return s.a.getPhrase(this.lang,"selectYearGroups")}}]),n}(i.a.Component);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})(e)}function K(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,o.key,o)}}function X(e,t){return(X=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(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=te(e);if(t){var r=te(this).constructor;n=Reflect.construct(o,arguments,r)}else n=o.apply(this,arguments);return ee(this,n)}}function ee(e,t){return!t||"object"!==W(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function te(e){return(te=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var ne,oe=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}}),t&&X(e,t)}(i,e);var t,n,o,r=Z(i);function i(){return K(this,i),r.apply(this,arguments)}return t=i,(n=[{key:"name",get:function(){return"RestrictAccessComponent"}},{key:"template",get:function(){return"<p>".concat(this.getTemplateText(),"</p>")}},{key:"lang",get:function(){return"shared.restrictAccess"}},{key:"getTemplateText",value:function(){return s.a.getPhrase(this.lang,"groupNoAccess",{groupName:g.o.mapYearGroupToName(this.model.get("groupId"))})}}])&&Q(t.prototype,n),o&&Q(t,o),i}(i.a.Component),re=n(1249),ie=n.n(re);function ce(e){return(ce="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function se(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,o.key,o)}}function ue(e,t){return(ue=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function le(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=fe(e);if(t){var r=fe(this).constructor;n=Reflect.construct(o,arguments,r)}else n=o.apply(this,arguments);return ae(this,n)}}function ae(e,t){return!t||"object"!==ce(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function fe(e){return(fe=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}n.d(t,"RestrictAccessView",(function(){return pe})),function(e){e.Students="Students",e.Groups="Certain year groups",e.All="Students and staff"}(ne||(ne={}));var pe=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}}),t&&ue(e,t)}(R,e);var t,n,S,C=le(R);function R(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,R),C.call(this,e)}return t=R,(n=[{key:"initialize",value:function(){this.restriction=new m.a({groupId:k.n.Students}),this.selected=ne.Students,this.bindListeners(),this.videoDataService=c.a.getInstance(b.g.Video,this),this.restrictedVideoDataService=c.a.getInstance(b.g.RestrictedVideo,this),this.videoMixinService=c.a.getInstance(b.x.VideoMixin,this)}},{key:"bindListeners",value:function(){this.listenTo(this.channelName,"dropdown:selected",this.onOptionSelected),this.listenTo(this.restriction,"change:groupId",this.onGroupChanged),this.listenTo(b.e.VIDEO,"".concat(b.f.VIDEOS,":").concat(this.options.videoId,":sync"),this.render),this.listenTo(b.e.RESTRICTED_VIDEO,"".concat(b.f.RESTRICTED_OBJECTS,":").concat(this.options.videoId,":sync"),this.render)}},{key:"name",get:function(){return"RestrictAccessView"}},{key:"title",get:function(){return s.a.getPhrase(this.lang,"title")}},{key:"lang",get:function(){return"shared.restrictAccess"}},{key:"tagName",get:function(){return"form"}},{key:"className",get:function(){return"form-group"}},{key:"channelName",get:function(){return g.k.generateUniqueChannelName(this)}},{key:"template",get:function(){return ie.a}},{key:"behaviors",get:function(){var e=this;return[{behaviorClass:h.e,title:s.a.getPhrase(this.lang,"popupHeading"),modalClasses:D.a.modal,hideCloseButton:!0,size:"modal-md",spinnerButtonOptions:{channelName:this.channelName,model:this.spinnerModel=new p.a,buttonText:s.a.getPhrase(this.lang,"updateAccess"),tooltip:function(){return e.getSubmitBtnTooltipOptions()},onClick:function(t){return e.onSubmit(t)}},buttons:[{text:s.a.getPhrase(this.lang,"allowFullAccess"),getClassName:function(){return e.getAllowFullAccessBtnClassName()}}]},{behaviorClass:l.a,selector:".".concat(D.a.svgContainer),title:s.a.getPhrase(this.lang,"findOutMore")}]}},{key:"elements",get:function(){return{submit:"submit"}}},{key:"events",value:function(){return{submit:"onSubmit","click .allow-full-access":"onAllowFullAccess"}}},{key:"regions",value:function(){return{dropdown:".dropdown-region",accessView:{replaceElement:!0,el:".access-view-region"}}}},{key:"getAllowFullAccessBtnClassName",value:function(){var e="btn btn-link cursor-pointer mr-2 allow-full-access";return this.dataFetched()&&!this.spinnerModel.get(O.c.ShowSpinner)||(e+=" disabled"),e}},{key:"getSubmitBtnTooltipOptions",value:function(){if(this.dataFetched()&&this.spinnerModel.get(O.c.Disabled))return{title:s.a.getPhrase(this.lang,"selectYear")}}},{key:"onOptionSelected",value:function(e){this.refreshRestriction();var t=this.getAccessView(e.get("name"));this.showChildView("accessView",new t({model:this.restriction,currentUser:this.currentUser})),this.renderDropdown()}},{key:"onGroupChanged",value:function(e){this.isRendered()&&this.spinnerModel.set(O.c.Disabled,o.isUndefined(e.get("groupId")))}},{key:"getAccessView",value:function(e){switch(this.selected=e,e){case ne.Students:return this.restriction.set("groupId",k.n.Students),oe;case ne.Groups:return J;case ne.All:return this.restriction.set("groupId",k.n.All),oe}}},{key:"getSelection",value:function(e){switch(e){case k.n.All:case k.n.Staff:return ne.All;case k.n.Students:return ne.Students;default:return ne.Groups}}},{key:"refreshRestriction",value:function(){if(this.restrictedObjectCollection&&this.restrictedObjectCollection.length&&this.model){this.videoMixinService.mixinVideoRestriction(this.model,this.restrictedObjectCollection);var e=this.model.restrictions.last();e&&o.isNumber(e.get("groupId"))&&(this.restriction.set("groupId",e.get("groupId")),this.selected=this.getSelection(e.get("groupId")))}}},{key:"onSubmit",value:function(e){var t=this;if(e&&e.preventDefault(),o.isUndefined(this.restriction.get("groupId")))return!1;r.Radio.channel(this.channelName).trigger(O.b.ShowSpinner),this.restrictedVideoDataService.updateVideoRestriction(this.options.videoId,this.restriction.get("groupId"),this.currentUser.get("customerId"),this.currentUser.get("id"),(function(){t.triggerMethod("hide"),r.Radio.channel(b.e.RESTRICTED_VIDEO).trigger("cache:cleared")})),this.logAction(this.restriction.get("groupId"))}},{key:"onAllowFullAccess",value:function(){this.dataFetched()&&!this.spinnerModel.get(O.c.ShowSpinner)&&(this.spinnerModel.set(O.c.Disabled,!0),this.restriction.set("groupId",k.n.All),this.restrictedVideoDataService.deleteVideoRestriction(this.options.videoId,(function(){r.Radio.channel(b.e.RESTRICTED_VIDEO).trigger("cache:cleared")})),this.triggerMethod("hide"),this.logAction())}},{key:"logAction",value:function(e){var t={location:d.LocationContext.Popup,actionType:d.UserAction.SetAccess,entity:d.EntityType.Video,workflowPhase:d.WorkflowPhase.Complete},n={id:this.model.get("id"),restriction:!!o.isNumber(e)&&k.n[e]};y.a.logUserAction(n,t)}},{key:"dataFetched",value:function(){return!!this.model&&!!this.restrictedObjectCollection}},{key:"renderDropdown",value:function(){var e=this;this.collection=new i.a.Collection([{name:ne.Students},{name:ne.Groups},{name:ne.All}]),this.collection.each((function(t){return t.set("selected",t.get("name")===e.selected)})),this.showChildView("dropdown",new N({titleProperty:"name",eventName:"dropdown:selected",buttonId:"select-btn",collection:this.collection,channelName:this.channelName,buttonClass:D.a.selectButton,displayOptions:{extraClasses:"w-100"},analyticsHelper:y.a}))}},{key:"requiredResources",get:function(){return{config:w.b.config,currentUser:v.b.currentUser}}},{key:"onBeforeRender",value:function(){this.model=this.videoDataService.getVideo(this.options.videoId),this.restrictedObjectCollection=this.restrictedVideoDataService.getVideoRestrictions([this.options.videoId]),this.model&&this.restrictedObjectCollection&&this.refreshRestriction(),this.dataFetched()&&this.spinnerModel.set(O.c.Disabled,!1)}},{key:"viewOptions",value:function(){var e,t;return{styles:D.a,supportUrl:a.a.getArticle(null===(e=this.config)||void 0===e?void 0:e.get("supportSiteUrl"),f.a.VideoAccess,null===(t=this.currentUser)||void 0===t?void 0:t.get("countryCode")),svg:u.a.getSvg(u.b.Info),dataFetched:this.dataFetched(),spinnerEl:g.r.getSpinner({size:g.s.Large,extraClasses:"mx-auto"}),restrictFromLabel:s.a.getPhrase(this.lang,"popupSubheading")}}},{key:"onRender",value:function(){this.dataFetched()&&(this.renderDropdown(),this.onOptionSelected(new i.a.Model({name:this.selected})))}}])&&se(t.prototype,n),S&&se(t,S),R}(i.a.View)}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp_clickview_library_editor=window.webpackJsonp_clickview_library_editor||[]).push([[9],{1036:function(e,t,n){"use strict";var r=n(1041),i=n(1037),a=(n(1038),n(3),n(1042)),o=(n(1044),n(1040));n.d(t,"a",(function(){return r.a})),n.d(t,"d",(function(){return i.g})),n.d(t,"g",(function(){return i.j})),n.d(t,"f",(function(){return i.i})),n.d(t,"c",(function(){return i.f})),n.d(t,"e",(function(){return i.h})),n.d(t,"b",(function(){return a.a})),n.d(t,"h",(function(){return o.a}))},1037:function(e,t,n){"use strict";n.d(t,"a",(function(){return d})),n.d(t,"k",(function(){return p})),n.d(t,"g",(function(){return h})),n.d(t,"e",(function(){return m})),n.d(t,"j",(function(){return b})),n.d(t,"i",(function(){return v})),n.d(t,"c",(function(){return E})),n.d(t,"b",(function(){return R})),n.d(t,"d",(function(){return x})),n.d(t,"f",(function(){return P})),n.d(t,"h",(function(){return y}));var r=n(2),i=n(1),a=n(19),o=n(29),u=n(3),s="libraryEditor.utils",c=["tags","thumbnail","chapters","resources","subtitles","disabled","links","restrictions","categories"];function l(e,t){if(e){var n=i.reduce(e,(function(e,n,r){var a=t[r];return n||a?i.isObject(n)&&i.isObject(a)&&!i.isUndefined(n.id)&&n.id===a.id?e:i.isArray(n)?f(n,a).length?e.concat(r):e:i.isEqual(n,a)?e:e.concat(r):e}),[]);if(n.length)return i.object(i.map(n,(function(n){return i.isArray(t[n])?[n,f(e[n],t[n])]:[n,t[n]]})))}}function f(e,t){var n=[];return i.each(t,(function(t){var r=i.findWhere(e,{id:t.id});if(!i.isUndefined(r)||0!==Object.keys(t).length){var a=i.isUndefined(r)?t:l(r,t);a&&(t.id<0&&!t.value||(!r||t.id<0?n.push(t):(a.id=t.id,n.push(a))))}})),n}var d={getChanges:function(e,t){var n=l(i.omit(e.toJSON(),c),i.omit(t.toJSON(),c));if(n)return i.object(i.map(i.keys(n),(function(e){return[e,d.formatChanges(e,n[e])]})))},formatChanges:function(e,t){if(!t)return null;if(i.isObject(t)&&i.isEmpty(t))return null;switch(e){case"name":case"description":case"productionYear":case"dateBroadcast":case"fields":case"episodeNumber":return t;case"channel":case"series":case"rating":case"season":return{id:t.id};case"distributors":case"producers":case"directors":case"productionCompanies":return i.map(t,(function(e){return e.id}));case"dateModified":case"hasBroadcast":return;default:r.a.ErrorHelper.throw(new a.a("There are no formatting settings for ".concat(e)))}},updateModelState:function(e,t,n){var a=["distributors","producers","directors","productionCompanies"];for(var o in i.each(i.keys(n),(function(e){a.includes(e)&&(n[e]=t.get(e).toJSON())})),t.set(i.clone(n),{silent:!0}),e.set(t.toJSON(),{silent:!0}),n){if(!n[o]&&e.associations[o]){var u=e.get(o);(u instanceof r.a.Model||u instanceof r.a.NestedModel)&&u.clear()}}},getRemovedObjectIds:function(e,t){var n=["distributors","productionCompanies","producers","directors"],r={};return i.each(i.keys(e.toJSON()),(function(a){if(i.contains(n,a)){var o=e.get(a).map((function(e){return e.id})),u=t.get(a).map((function(e){return e.id})),s=i.filter(o,(function(e){return e&&!i.contains(u,e)}));s.length&&(r[a]=s)}})),r}},p={name:[{required:!0,msg:function(){return u.a.getPhrase(s,"videoTitleRequired")}},{maxLength:255,msg:function(){return u.a.getPhrase(s,"videoTitleExceeds")}}],description:[{required:!1},{maxLength:16e3,msg:function(){return u.a.getPhrase(s,"videoDescriptionExceeds")}}],episodeNumber:function(e,t,n){return e&&e<1?u.a.getPhrase(s,"episodeNumberLessThanOne"):e&&e>2147483647?u.a.getPhrase(s,"episodeNumberExceeds"):e%1!=0?u.a.getPhrase(s,"episodeNumberNotWhole"):n.season&&n.season.get("number")>=0&&null===e?u.a.getPhrase(s,"episodeNumberNoSeason"):""},season:function(e,t,n){return n.season&&n.season.get("number")||e&&e.number||!n.episodeNumber?"":u.a.getPhrase(s,"seasonNoEpisodeNumber")}},g=o().year(),m={productionYear:function(e){return e||0===e?(e=+e,isNaN(e)?"Production year must be a number.":e<1900||e>g?u.a.getPhrase(s,"validProductionYears",{currentYear:g}):void 0):""}},h={name:[{required:!0,msg:function(){return u.a.getPhrase(s,"resourceNameRequired")}}]},b={suggestion:[{required:!0,msg:function(){return u.a.getPhrase(s,"suggestEditRequired")}},{maxLength:16e3,msg:function(){return u.a.getPhrase(s,"suggestEditExceeds")}}],reason:[{required:!0,msg:function(){return u.a.getPhrase(s,"suggestEditReasonRequired")}},{maxLength:16e3,msg:function(){return u.a.getPhrase(s,"suggestEditReasonExceeds")}}]},y={number:function(e){return e?+e<1?u.a.getPhrase(s,"seasonLessThanOne"):+e>3e3?u.a.getPhrase(s,"seasonExceeds"):+e%1!=0?u.a.getPhrase(s,"seasonNotWhole"):"":u.a.getPhrase(s,"seasonRequired")}},v={empty:function(){return u.a.getPhrase(s,"suggestEditRatingRequired")},original:function(){return u.a.getPhrase(s,"suggestEditRatingInvalid")}},P={url:[{required:!0,pattern:"url",msg:function(){return u.a.getPhrase(s,"linkUrlRequired")}},{maxLength:16e3,msg:function(){return u.a.getPhrase(s,"linkUrlExceeds")}}],name:[{required:!0,msg:function(){return u.a.getPhrase(s,"linkNameRequired")}},{maxLength:255,msg:function(){return u.a.getPhrase(s,"linkNameExceeds")}}]},E={name:[{maxLength:128,msg:function(){return u.a.getPhrase(s,"fieldNameExceeds")}}],value:[{maxLength:16e3,msg:function(){return u.a.getPhrase(s,"fieldValueExceeds")}}]},R={fields:function(e){return e&&e.length?e.all((function(e){return!1!==e.isValid()}))?"":u.a.getPhrase(s,"fieldsInvalid"):""}};function x(){return[{id:-1,name:"Admin Notes",value:"",placeholder:"Notes that only admins will see"}]}},1038:function(e,t,n){"use strict";n.d(t,"a",(function(){return l}));var r=n(1),i=n(48),a=n(168),o=n(3),u="libraryEditor.utils",s={name:[{required:!0,msg:function(){return o.a.getPhrase(u,"folderNameRequired")}},{maxLength:255,msg:function(){return o.a.getPhrase(u,"folderNameExceeds")}}]},c=function(e,t){return{parentId:function(n){return n?i.a.calculateDestinationFolderDepth(e,n,t)>a.a.MAX_FOLDER_DEPTH?o.a.getPhrase(u,"maxFolderDepth",{maxDepth:a.a.MAX_FOLDER_DEPTH}):"":o.a.getPhrase(u,"selectParentFolder")}}},l=function(e){var t=e.validateName,n=e.validateParent,i=e.folder,a=e.collection;return t&&n?r.extend({},s,c(i,a)):t?s:n?c(i,a):void 0}},1040:function(e,t,n){"use strict";n.d(t,"a",(function(){return f}));var r=n(16),i=n(3),a=n(199),o=n(1056),u=n(62);function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var c,l="libraryEditor.utils";!function(e){e.Pdf="pdf",e.Image="image",e.PowerPoint="powerpoint",e.Document="document",e.Excel="excel",e.Zip="archive",e.File="text"}(c||(c={}));var f={mapRatingToClass:function(e){if(!e)return"";return function(e){switch(!0){case e<32:return"bg-purple";case e<48:return"bg-green";case e<80:return"bg-info";case e<96:return"bg-red";case e<128:return"bg-pink";case e>=128:return"bg-yellow";default:return""}}(e)},mapSourceToDisplayName:function(e){switch(e.get("type")){case u.a.HostedLibrary:case u.a.CustomLibrary:return e.get("name");case u.a.Exchange:return i.a.getPhrase(l,"exchange");case u.a.Workspace:return i.a.getPhrase(l,"workspace");default:return""}},mapSourceToClass:function(e){switch(e){case u.a.HostedLibrary:case u.a.CustomLibrary:return"bg-info";case u.a.Exchange:return"bg-green";case u.a.Workspace:default:return"bg-red"}},isInteractive:function(e){return!(!e||!e.interactives)&&!!e.interactives.length},mapTypeToSvg:function(e){var t,n=(s(t={},c.Pdf,r.b.FilePDF),s(t,c.Image,r.b.FileImg),s(t,c.PowerPoint,r.b.FilePowerpoint),s(t,c.Document,r.b.FileWord),s(t,c.Excel,r.b.FileExcel),s(t,c.Zip,r.b.FileZip),s(t,c.File,r.b.File),t)[e];return n||(n=r.b.Folder),r.a.getSvg(n)},mapTypeToClass:function(e){switch(e){case c.Pdf:return"icon-red";case c.Image:return"icon-purple";case c.Document:return"icon-blue";case c.Excel:return"icon-green";case c.PowerPoint:return"icon-orange";case c.Zip:return"icon-teal";case c.File:return"icon-gray";default:return""}},mapTypeToExtension:function(e){if(!e)return"";return{pdf:"pdf",image:"png",powerpoint:"pptx"}[e.toLowerCase()]},mapTypeToName:function(e){if(!e)return"";switch(e){case c.Pdf:return i.a.getPhrase(l,"pdf");case c.Image:return i.a.getPhrase(l,"image");case c.Document:return i.a.getPhrase(l,"document");case c.Excel:return i.a.getPhrase(l,"spreadsheet");case c.PowerPoint:return i.a.getPhrase(l,"presentation");case c.Zip:return i.a.getPhrase(l,"zipArchive");case c.File:return i.a.getPhrase(l,"file");default:return""}},translateMetadataCollectionNames:function(e){return new o.a(e.map((function(e){return Object.assign(Object.assign({},e.toJSON()),{name:f.translateMetadataName(e.get("name"))})})))},translateMetadataName:function(e){var t="suggestEdit";switch(e){case a.MetadataType.VideoTitle:t+="VideoTitle";break;case a.MetadataType.Description:t+="Description";break;case a.MetadataType.Rating:t+="Rating";break;case a.MetadataType.SeriesTitle:t+="SeriesTitle";break;case a.MetadataType.Season:t+="SeasonNumber";break;case a.MetadataType.EpisodeNumber:t+="EpisodeNumber";break;case a.MetadataType.BroadcastDate:t+="BroadcastDate";break;case a.MetadataType.Channel:t+="Channel";break;case a.MetadataType.ProductionYear:t+="ProductionYear";break;case a.MetadataType.Distributors:t+="Distributors";break;case a.MetadataType.ProductionCompanies:t+="ProductionCompanies";break;case a.MetadataType.Directors:t+="Directors";break;case a.MetadataType.Producers:t+="Producers";break;case a.MetadataType.Other:t+="Other"}return i.a.getPhrase(l,t)}}},1041:function(e,t,n){"use strict";n.d(t,"a",(function(){return u}));var r=n(1),i=n(13),a=n(3),o="libraryEditor.utils",u={isValidChapterTime:function(e,t,n,a){if(a){if(!r.isNumber(t))return s.StartTime.Invalid();if(t<0)return s.StartTime.Invalid();if(t>i.x.millisecondsToSeconds(n))return s.StartTime.Exceeds();if(a.some((function(n){return!(n.id&&n.id===e.id||n.cid===e.cid)&&n.get("startTime")===t})))return s.StartTime.Exists()}},isValidChapterName:function(e,t,n){return t?t.length>255?s.Name.MaxLength():n.some((function(n){return!(n.id&&n.id===e.id||n.cid===e.cid)&&n.get("name").trim()===t.trim()}))?s.Name.Exists():r.isEmpty(t.trim())?s.Name.Invalid():void 0:s.Name.Invalid()},mapPhysicalChapters:function(e){var t=0;return r.map(e,(function(e,n){var r={name:e.title,startTime:t,index:n,isPhysicalChapter:!0};return t+=e.duration,r}))}},s={Name:{Invalid:function(){return a.a.getPhrase(o,"chapterNameInvalid")},Exists:function(){return a.a.getPhrase(o,"chapterNameExists")},MaxLength:function(){return a.a.getPhrase(o,"chapterNameExceeds")}},StartTime:{Invalid:function(){return a.a.getPhrase(o,"chapterStartTimeInvalid")},Exists:function(){return a.a.getPhrase(o,"chapterStartTimeExists")},Exceeds:function(){return a.a.getPhrase(o,"chapterStartTimeExceeds")}}}},1042:function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var r=n(3),i="libraryEditor.utils",a={name:[{required:!0,msg:function(){return r.a.getPhrase(i,"libraryNameRequired")}},{maxLength:255,msg:function(){return r.a.getPhrase(i,"libraryNameExceeds")}}]}},1044:function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(3),i=n(1037),a=r.a.encloseNamespace("libraryEditor.utils"),o={name:[{required:!0,msg:function(){return a("videoTitleRequired")}}],folderId:[{required:!0,msg:function(){return a("uploadFolderRequired")}}],libraryId:[{required:!0,msg:function(){return a("uploadLibraryRequired")}}],episodeNumber:function(e,t,n){return e&&e<1?a("episodeNumberLessThanOne"):e&&e>255?a("episodeNumberExceeds"):e&&e%1!=0?a("episodeNumberNotWhole"):n.season&&n.season.get("number")>=0&&null===e?a("episodeNumberNoSeason"):""},season:function(e,t,n){return n.season&&n.season.get("number")||e&&e.number||!n.episodeNumber?"":a("seasonNoEpisodeNumber")},productionYear:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return i.e.productionYear.apply(null,t)}}},1056:function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){return(a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function o(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,r=s(e);if(t){var i=s(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u(this,n)}}function u(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function s(e){return(s=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}n.d(t,"a",(function(){return c}));var c=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}}),t&&a(e,t)}(n,e);var t=o(n);function n(){return i(this,n),t.apply(this,arguments)}return n}(n(2).a.Collection)},1096:function(e,t,n){e.exports={requiredStar:"_3S5iJ",disabled:"_3iZQ5",formGroup:"B4xS9",suggestEdit:"_3n3sM",programTitle:"_3bWJB",description:"_3qayV",seriesTitle:"_3ojjo",broadcastDate:"_2hA-0",channel:"_1SMGG",rating:"_3AkUv",productionYear:"_1DYCl",distributors:"_2CbiR",productionCompanies:"_3hB5o",directors:"ksEaA",producers:"h7P2B",episodeNumber:"_3fMUg",seasonNumber:"GwqaB",icon:"quxL2",infoSvgContainer:"_18UDY"}},1193:function(e,t,n){e.exports={selectRating:"_1I6jj",removeRating:"_1ze5G",disabled:"_2hO8J",disabledSelected:"mnQ5O"}},1196:function(e,t,n){"use strict";var r=n(1),i=n(6),a=n(2),o=n(143),u=n(487),s=n(1250),c=n.n(s),l=n(1193),f=n.n(l);function d(e){return(d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function p(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function g(e,t){return(g=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function m(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,r=b(e);if(t){var i=b(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return h(this,n)}}function h(e,t){return!t||"object"!==d(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function b(e){return(b=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(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}}),t&&g(e,t)}(u,e);var t,n,r,a=m(u);function u(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,u),a.call(this,e)}return t=u,(n=[{key:"name",get:function(){return"SelectRatingItemComponent"}},{key:"template",get:function(){return c.a}},{key:"tagName",get:function(){return"li"}},{key:"attributes",get:function(){return{title:this.options.editable?this.model.get("name"):""}}},{key:"className",get:function(){var e="";return e+="btn ".concat(this.options.editable?"btn-light":"".concat(f.a.disabled)),this.model.get("selected")&&(e+=this.options.editable?" active":" ".concat(f.a.disabledSelected)),e}},{key:"events",value:function(){return{click:"onClick"}}},{key:"behaviors",get:function(){var e=this.options.editable?this.options.model.get("name"):"";return[{behaviorClass:o.a,title:e}]}},{key:"onClick",value:function(){this.options.editable&&i.Radio.channel(this.options.channelName).trigger("select:rating",this.model)}},{key:"onRender",value:function(){this.resetClassName()}}])&&p(t.prototype,n),r&&p(t,r),u}(a.a.Component);function v(e){return(v="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function P(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function E(e,t){return(E=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function R(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,r=k(e);if(t){var i=k(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return x(this,n)}}function x(e,t){return!t||"object"!==v(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function k(e){return(k=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var w=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}}),t&&E(e,t)}(a,e);var t,n,r,i=R(a);function a(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),i.call(this,e)}return t=a,(n=[{key:"name",get:function(){return"SelectRatingCollectionComponent"}},{key:"tagName",get:function(){return"ul"}},{key:"className",get:function(){return"rating-group btn-group p-0 m-0"}},{key:"childView",get:function(){return y}},{key:"childViewOptions",get:function(){return{channelName:this.options.channelName,currentRatingId:this.options.currentRatingId,editable:this.options.editable}}}])&&P(t.prototype,n),r&&P(t,r),a}(a.a.ComponentCollection),N=n(13),O=n(3),T=n(0),S=n(199),C=n(1251),_=n.n(C),j=n(1096),I=n.n(j);function M(e){return(M="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function D(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function q(e,t){return(q=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function L(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,r=B(e);if(t){var i=B(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return F(this,n)}}function F(e,t){return!t||"object"!==M(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function B(e){return(B=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}n.d(t,"a",(function(){return A}));var A=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}}),t&&q(e,t)}(c,e);var t,n,a,s=L(c);function c(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,c),s.call(this,e)}return t=c,(n=[{key:"name",get:function(){return"SelectRatingComponent"}},{key:"channelName",get:function(){return"".concat(this.name).concat(this.cid)}},{key:"lang",get:function(){return"shared.selectRating"}},{key:"events",value:function(){return{"click .remove-rating":"onRemoveRating"}}},{key:"regions",value:function(){return{ratings:{el:".ratings-region",replaceElement:!0}}}},{key:"template",get:function(){return _.a}},{key:"behaviors",get:function(){return[{behaviorClass:o.a,selector:".remove-rating",title:O.a.getPhrase(this.lang,"removeTooltip")}]}},{key:"appLinks",get:function(){return{".suggest-rating":{application:T.b.LIBRARY_EDITOR,action:T.a.LibraryEditor.SUGGEST_AN_EDIT,args:[this.options.videoId],params:{metadata:S.MetadataType.Rating}}}}},{key:"defaults",get:function(){return{editable:!0}}},{key:"initialize",value:function(){this.setViewCollection(),this.setCurrentRating(this.model),this.bindListeners()}},{key:"bindListeners",value:function(){this.listenTo(this.channelName,"select:rating",this.onRatingSelected)}},{key:"setCurrentRating",value:function(e){N.l.setRating(e,this.viewCollection)}},{key:"onRatingSelected",value:function(e){this.setCurrentRating(e);var t=N.c.getSelected(this.viewCollection);this.updateRating(t)}},{key:"onRemoveRating",value:function(e){e.preventDefault(),this.$(".remove-rating").tooltip("dispose"),this.setCurrentRating(null);var t=this.collection.findWhere({value:0});return this.updateRating(t),!1}},{key:"updateRating",value:function(e){i.Radio.channel(this.options.parentChannelName).trigger("select:rating",e),this.render()}},{key:"setViewCollection",value:function(){var e=r.filter(this.collection.toJSON(),(function(e){return 0!==e.value}));return this.viewCollection=new u.a(e)}},{key:"viewOptions",value:function(){var e=N.c.getSelected(this.viewCollection);return{styles:r.extend(I.a,f.a),showRemove:!this.options.hideRemove&&e&&this.options.editable,editable:this.options.editable,hideHeaderText:this.options.hideHeaderText}}},{key:"renderRatingCollectionComponent",value:function(){this.showChildView("ratings",new w({collection:this.viewCollection,channelName:this.channelName,editable:this.options.editable}))}},{key:"onRender",value:function(){this.renderRatingCollectionComponent()}}])&&D(t.prototype,n),a&&D(t,a),c}(a.a.Component)},1250:function(e,t,n){var r=n(10);e.exports=(r.default||r).template({compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){var a;e.propertyIsEnumerable;return"\r\n"+e.escapeExpression("function"==typeof(a=null!=(a=n.code||(null!=t?t.code:t))?a:e.hooks.helperMissing)?a.call(null!=t?t:e.nullContext||{},{name:"code",hash:{},data:i}):a)},useData:!0})},1251:function(e,t,n){var r=n(10);e.exports=(r.default||r).template({1:function(e,t,n,r,i){e.propertyIsEnumerable;var a,o=null!=t?t:e.nullContext||{};return' <label class="'+(null!=(a=n.unless.call(o,null!=(a=null!=t?t.options:t)?a.editable:a,{name:"unless",hash:{},fn:e.program(2,i,0),inverse:e.noop,data:i}))?a:"")+'">'+e.escapeExpression((n.lang||t&&t.lang||e.hooks.helperMissing).call(o,"rating",{name:"lang",hash:{},data:i}))+"</label>\r\n "+(null!=(a=n.unless.call(o,null!=(a=null!=t?t.options:t)?a.editable:a,{name:"unless",hash:{},fn:e.program(4,i,0),inverse:e.noop,data:i}))?a:"")+"\r\n"},2:function(e,t,n,r,i){return"d-inline-block"},4:function(e,t,n,r,i){e.propertyIsEnumerable;var a,o=e.escapeExpression;return'<span class="'+o(e.lambda(null!=(a=null!=(a=null!=t?t.options:t)?a.styles:a)?a.suggestEdit:a,t))+'">- <a class="suggest-rating">'+o((n.lang||t&&t.lang||e.hooks.helperMissing).call(null!=t?t:e.nullContext||{},"suggestEdit",{name:"lang",hash:{},data:i}))+"</a></span><br>"},6:function(e,t,n,r,i){e.propertyIsEnumerable;var a,o=e.escapeExpression;return'<span class="text-muted mx-2 remove-rating '+o(e.lambda(null!=(a=null!=(a=null!=t?t.options:t)?a.styles:a)?a.removeRating:a,t))+'">'+o((n.lang||t&&t.lang||e.hooks.helperMissing).call(null!=t?t:e.nullContext||{},"remove",{name:"lang",hash:{},data:i}))+"</span>"},compiler:[8,">= 4.3.0"],main:function(e,t,n,r,i){e.propertyIsEnumerable;var a,o=e.lambda,u=e.escapeExpression,s=null!=t?t:e.nullContext||{};return'<div class="edit-rating form-group '+u(o(null!=(a=null!=(a=null!=t?t.options:t)?a.styles:a)?a.selectRating:a,t))+" "+u(o(null!=(a=null!=(a=null!=t?t.options:t)?a.styles:a)?a.rating:a,t))+'">\r\n'+(null!=(a=n.unless.call(s,null!=(a=null!=t?t.options:t)?a.hideHeaderText:a,{name:"unless",hash:{},fn:e.program(1,i,0),inverse:e.noop,data:i}))?a:"")+' <div>\r\n <div class="ratings-region" name="rating"></div>\r\n '+(null!=(a=n.if.call(s,null!=(a=null!=t?t.options:t)?a.showRemove:a,{name:"if",hash:{},fn:e.program(6,i,0),inverse:e.noop,data:i}))?a:"")+'\r\n <div class="form-feedback"></div>\r\n </div>\r\n</div>'},useData:!0})}}]);
|