mediacms/static/js/playlist.js

1 line
23 KiB
JavaScript

!function(){"use strict";var e={4311:function(e,t,n){var i=n(2667),a=(n(2004),n(8407),n(4458),n(5101),n(9808),n(5466)),o=(n(6116),n(2880)),r=n(1346),l=n(8204),s=(n(4426),n(8349)),u=n(5971),c=n(7801),p=n(2431),m=n(3074),f=n.n(m),d=n(1345);function y(e){return a.createElement(d.C,{items:e.media,playlistId:e.playlistId,hidePlaylistOptions:e.hidePlaylistOptions,singleLinkContent:!0,hideDate:!0,hideViews:!0,hidePlaylistOrderNumber:!1,horizontalItemsOrientation:!0,itemsCountCallback:e.itemsCountCallback,pageItems:99999,inPlaylistPage:!0})}y.propTypes={media:f().array.isRequired,playlistId:f().string.isRequired,itemsCountCallback:f().func,hidePlaylistOptions:f().bool},y.defaultProps={hidePlaylistOptions:!0};var h=n(7207),v=n(2836),g=n(8420),P=n(2331),b=n(8534),E=n(7823),C=n(3562),k=n(8852);function O(e){return(O="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){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function w(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function R(e,t,n){return t&&w(e.prototype,t),n&&w(e,n),e}function Z(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)}function x(e,t){return(x=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 Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,i=I(e);if(t){var a=I(this).constructor;n=Reflect.construct(i,arguments,a)}else n=i.apply(this,arguments);return N(this,n)}}function N(e,t){return!t||"object"!==O(t)&&"function"!=typeof t?D(e):t}function D(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function I(e){return(I=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var L=function(e){Z(n,e);var t=S(n);function n(e){var i;return _(this,n),(i=t.call(this,e)).state={isOpenMoreOptionsMenu:!1,optionsCurrentPage:"main"},i.onPopupsDisplayChange=i.onPopupsDisplayChange.bind(D(i)),i.onOptionsPageChangeCallback=i.onOptionsPageChangeCallback.bind(D(i)),i.proceedPlaylistRemoval=i.proceedPlaylistRemoval.bind(D(i)),i.cancelPlaylistRemoval=i.cancelPlaylistRemoval.bind(D(i)),i.settingOptionsList={deleteMedia:{itemType:"open-subpage",text:"Delete",icon:"delete",buttonAttr:{className:"change-page","data-page-id":"proceedPlaylistRemovalPopup"}}},i.moreOptionsPages={main:a.createElement(v.W8,null,a.createElement(b.S,{items:[i.settingOptionsList.deleteMedia]})),proceedPlaylistRemovalPopup:a.createElement(v.W8,null,a.createElement("div",{className:"popup-message"},a.createElement("span",{className:"popup-message-title"},"Playlist removal"),a.createElement("span",{className:"popup-message-main"},"You're willing to remove playlist permanently?")),a.createElement("hr",null),a.createElement("span",{className:"popup-message-bottom"},a.createElement("button",{className:"button-link cancel-playlist-removal",onClick:i.cancelPlaylistRemoval},"CANCEL"),a.createElement("button",{className:"button-link proceed-playlist-removal",onClick:i.proceedPlaylistRemoval},"PROCEED")))},i.initMoreOptionsPopup(),i}return R(n,[{key:"initMoreOptionsPopup",value:function(){this.optionsPopup=new h.Z(a.createElement(p.M,null,a.createElement(P.O,{type:"more_horiz"})),a.createElement(C.o,{pageChangeCallback:this.onOptionsPageChangeCallback,initPage:"main",focusFirstItemOnPageChange:!1,pages:this.moreOptionsPages,pageChangeSelector:".change-page",pageIdSelectorAttr:"data-page-id"}),this.onPopupsDisplayChange)}},{key:"proceedPlaylistRemoval",value:function(){this.optionsPopup.setOpenPopupState(!1),u.vg()}},{key:"cancelPlaylistRemoval",value:function(){this.optionsPopup.setOpenPopupState(!1)}},{key:"onOptionsPageChangeCallback",value:function(e){this.setState({optionsCurrentPage:e})}},{key:"onPopupsDisplayChange",value:function(){this.setState({isOpenMoreOptionsMenu:this.optionsPopup.isPopupOpen(),optionsCurrentPage:this.optionsPopup.isPopupOpen()?this.state.optionsCurrentPage:"main"})}},{key:"render",value:function(){return a.createElement("div",{className:"playlist-options-wrap"+("main"===this.state.optionsCurrentPage?" playlist-options-main":"")},this.optionsPopup.triggerComponent(),this.state.isOpenMoreOptionsMenu?this.optionsPopup.contentComponent():null)}}]),n}(a.PureComponent),F=function(e){Z(n,e);var t=S(n);function n(e){var i;return _(this,n),(i=t.call(this,e)).state={isOpenForm:!1,title:c.Z.get("title"),description:c.Z.get("description")},i.onPopupsDisplayChange=i.onPopupsDisplayChange.bind(D(i)),i.onFormSave=i.onFormSave.bind(D(i)),i.onClickExit=i.onClickExit.bind(D(i)),i.playlistUpdateCompleted=i.playlistUpdateCompleted.bind(D(i)),i.playlistUpdateFailed=i.playlistUpdateFailed.bind(D(i)),c.Z.on("playlist_update_completed",i.playlistUpdateCompleted),c.Z.on("playlist_update_failed",i.playlistUpdateFailed),i.playlistRemovalCompleted=i.playlistRemovalCompleted.bind(D(i)),i.playlistRemovalFailed=i.playlistRemovalFailed.bind(D(i)),c.Z.on("playlist_removal_completed",i.playlistRemovalCompleted),c.Z.on("playlist_removal_failed",i.playlistRemovalFailed),i.initFormPopup(),i}return R(n,[{key:"onClickExit",value:function(){this.optionsPopup.setOpenPopupState(!1),this.setState({isOpenForm:this.optionsPopup.isPopupOpen()})}},{key:"initFormPopup",value:function(){this.optionsPopup=new h.Z(a.createElement(p.M,null,a.createElement(P.O,{type:"edit"}),a.createElement("span",null,"EDIT")),a.createElement("div",{className:"popup-fullscreen"},a.createElement(v.W8,null,a.createElement("span",{className:"popup-fullscreen-overlay"}),a.createElement("div",{className:"edit-playlist-form-wrap"},a.createElement("div",{className:"edit-playlist-popup-title"},"Edit playlist",a.createElement(p.M,{type:"button",onClick:this.onClickExit},a.createElement(P.O,{type:"close"}))),a.createElement(E.A,{date:(new Date).getTime(),id:c.Z.get("playlistId"),onCancel:this.onClickExit,onPlaylistSave:this.onFormSave})))),this.onPopupsDisplayChange)}},{key:"onPopupsDisplayChange",value:function(){this.setState({isOpenForm:this.optionsPopup.isPopupOpen()})}},{key:"onFormSave",value:function(){}},{key:"playlistUpdateCompleted",value:function(e){setTimeout(function(){s.wN("Playlist updated","playlistUpdateCompleted"),this.onClickExit()}.bind(this),100)}},{key:"playlistUpdateFailed",value:function(){setTimeout(function(){s.wN("Playlist update failed","playlistUpdateFailed"),this.onClickExit()}.bind(this),100)}},{key:"playlistRemovalCompleted",value:function(e){setTimeout((function(){s.wN("Playlist removed. Redirecting...","playlistDelete"),setTimeout((function(){window.location.href=o.Z._currentValue.pages.playlists}),2e3)}),100)}},{key:"playlistRemovalFailed",value:function(e){setTimeout((function(){s.wN("Playlist removal failed","playlistDeleteFail")}),100)}},{key:"render",value:function(){return a.createElement("div",{className:"edit-playlist"},this.optionsPopup.triggerComponent(),this.state.isOpenForm?this.optionsPopup.contentComponent():null)}}]),n}(a.PureComponent),M=function(e){Z(n,e);var t=S(n);function n(){return _(this,n),t.apply(this,arguments)}return R(n,[{key:"render",value:function(){if(!this.props.thumb)return null;var e;return e=this.props.media&&this.props.media.length?a.createElement("a",{href:this.props.media[0].url+"&pl="+this.props.id,title:""},a.createElement("span",null,a.createElement("img",{src:this.props.thumb,alt:""}),a.createElement("span",{className:"play-all"},a.createElement("span",null,a.createElement("span",null,a.createElement("i",{className:"material-icons"},"play_arrow"),a.createElement("span",{className:"play-all-label"},"PLAY ALL")))))):a.createElement("span",null,a.createElement("span",null,a.createElement("img",{src:this.props.thumb,alt:""}),a.createElement("span",{className:"play-all"},a.createElement("span",null,a.createElement("span",null,a.createElement("i",{className:"material-icons"},"play_arrow"),a.createElement("span",{className:"play-all-label"},"PLAY ALL")))))),a.createElement("div",{className:"playlist-thumb"+(this.props.thumb?"":" no-thumb"),style:{backgroundImage:'url("'+this.props.thumb+'")'}},e)}}]),n}(a.PureComponent),T=function(e){Z(n,e);var t=S(n);function n(){return _(this,n),t.apply(this,arguments)}return R(n,[{key:"render",value:function(){return a.createElement("div",{className:"playlist-title"},a.createElement("h1",null,this.props.title))}}]),n}(a.PureComponent),U=function(e){Z(n,e);var t=S(n);function n(){return _(this,n),t.apply(this,arguments)}return R(n,[{key:"render",value:function(){return a.createElement("div",{className:"playlist-meta"},a.createElement("div",{className:"playlist-videos-number"},this.props.totalItems," media"),this.props.dateLabel?a.createElement("div",{className:"playlist-last-update"},this.props.dateLabel):null)}}]),n}(a.PureComponent),A=function(e){Z(n,e);var t=S(n);function n(e){return _(this,n),t.call(this,e)}return R(n,[{key:"render",value:function(){return this.props.loggedinUserPlaylist?a.createElement("div",{className:"playlist-actions"},this.props.loggedinUserPlaylist?a.createElement(L,null):null):null}}]),n}(a.PureComponent),j=function(e){Z(n,e);var t=S(n);function n(){return _(this,n),t.apply(this,arguments)}return R(n,[{key:"render",value:function(){return a.createElement("div",{className:"playlist-author"},a.createElement("div",null,a.createElement("div",{className:"playlist-author-thumb"},a.createElement("a",{href:this.props.link,title:this.props.name},this.props.thumb?a.createElement("span",{style:{backgroundImage:"url("+this.props.thumb+")"}},a.createElement("img",{src:this.props.thumb,alt:""})):a.createElement("span",null,a.createElement(P.O,{type:"person"})))),a.createElement("div",{className:"playlist-author-name"},a.createElement("a",{href:this.props.link,title:this.props.name},this.props.name)),this.props.loggedinUserPlaylist?a.createElement(F,null):null))}}]),n}(a.PureComponent),Y=function(e){Z(n,e);var t=S(n);function n(e){var i;return _(this,n),(i=t.call(this,e)).state={mediaData:e.media},i.onItemsCount=i.onItemsCount.bind(D(i)),i}return R(n,[{key:"onItemsCount",value:function(){if(this.props.loggedinUserPlaylist){var e=this.props.id,t=this.state.mediaData;o=o.bind(this);var n=this.refs.playlistMediaList.querySelector(".items-list");k.Z.create(n,{onStart:function(e){n.classList.add("on-dragging")},onEnd:function(l){for(var s,u,c,p=[],m=n.querySelectorAll(".item-order-number div div"),f=0;f<m.length;)(u=f+1)!==(s=parseInt(m[f].innerHTML,10))&&(c=t[s-1].friendly_token,(0,g.GH)(r.Z._currentValue.playlists+"/"+e,{type:"ordering",ordering:u,media_friendly_token:c},{headers:{"X-CSRFToken":(0,g.m5)()}},!1,i,a)),p.push(s-1),m[f].innerHTML=u,f+=1;n.classList.remove("on-dragging"),o(p)}})}function i(e){}function a(e){}function o(e){for(var n=[],i=0;i<e.length;)n.push(t[e[i]]),i+=1;t=n,this.setState({mediaData:n}),u.wg(n)}}},{key:"render",value:function(){return a.createElement("div",{key:"playlistMediaList",ref:"playlistMediaList",className:"playlist-videos-list"+(this.props.loggedinUserPlaylist?" draggable":"")},this.state.mediaData.length?a.createElement(y,{itemsCountCallback:this.onItemsCount,playlistId:this.props.id,media:this.state.mediaData,hidePlaylistOptions:!this.props.loggedinUserPlaylist}):null)}}]),n}(a.PureComponent),V=function(e){Z(n,e);var t=S(n);function n(e){var i;return _(this,n),(i=t.call(this,e,"playlist-page")).state={thumb:c.Z.get("thumb"),media:c.Z.get("playlist-media"),savedPlaylist:c.Z.get("saved-playlist"),loggedinUserPlaylist:c.Z.get("logged-in-user-playlist"),title:c.Z.get("title"),description:c.Z.get("description")},i.onLoadPlaylistData=i.onLoadPlaylistData.bind(D(i)),c.Z.on("loaded_playlist_data",i.onLoadPlaylistData),i.onMediaRemovedFromPlaylist=i.onMediaRemovedFromPlaylist.bind(D(i)),c.Z.on("removed_media_from_playlist",i.onMediaRemovedFromPlaylist),i.onMediaReorderedInPlaylist=i.onMediaReorderedInPlaylist.bind(D(i)),c.Z.on("reordered_media_in_playlist",i.onMediaReorderedInPlaylist),i.onCompletePlaylistUpdate=i.onCompletePlaylistUpdate.bind(D(i)),c.Z.on("playlist_update_completed",i.onCompletePlaylistUpdate),i}return R(n,[{key:"onCompletePlaylistUpdate",value:function(){this.setState({thumb:c.Z.get("thumb"),title:c.Z.get("title"),description:c.Z.get("description")})}},{key:"onLoadPlaylistData",value:function(){this.setState({thumb:c.Z.get("thumb"),title:c.Z.get("title"),description:c.Z.get("description"),media:c.Z.get("playlist-media"),savedPlaylist:c.Z.get("saved-playlist"),loggedinUserPlaylist:c.Z.get("logged-in-user-playlist")})}},{key:"componentDidMount",value:function(){u.AJ()}},{key:"onMediaRemovedFromPlaylist",value:function(){this.setState({media:c.Z.get("playlist-media"),thumb:c.Z.get("thumb")})}},{key:"onMediaReorderedInPlaylist",value:function(){this.setState({media:c.Z.get("playlist-media"),thumb:c.Z.get("thumb")})}},{key:"pageContent",value:function(){var e=c.Z.get("playlistId");return e?[a.createElement("div",{key:"playlistDetails",className:"playlist-details"},a.createElement(M,{id:e,thumb:this.state.thumb,media:this.state.media}),a.createElement(T,{title:this.state.title}),a.createElement(U,{totalItems:c.Z.get("total-items"),dateLabel:c.Z.get("date-label"),viewsCount:c.Z.get("views-count")}),a.createElement(A,{loggedinUserPlaylist:this.state.loggedinUserPlaylist,savedPlaylist:this.state.savedPlaylist}),this.state.description?a.createElement("div",{className:"playlist-description"},this.state.description):null,a.createElement(j,{name:c.Z.get("author-name"),link:c.Z.get("author-link"),thumb:c.Z.get("author-thumb"),loggedinUserPlaylist:this.state.loggedinUserPlaylist})),a.createElement(Y,{key:"playlistMediaList_"+this.state.media.length,id:e,media:this.state.media,loggedinUserPlaylist:this.state.loggedinUserPlaylist})]:null}}]),n}(l.T);(0,i.X)("page-playlist",V)},9009:function(e,t,n){n(6394),n(5334),n(7588);var i=n(4559);function a(e,t,n,i,a,o,r){try{var l=e[o](r),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(i,a)}function o(e){return function(){var t=this,n=arguments;return new Promise((function(i,o){var r=e.apply(t,n);function l(e){a(r,i,o,l,s,"next",e)}function s(e){a(r,i,o,l,s,"throw",e)}l(void 0)}))}}function r(){return(r=o(regeneratorRuntime.mark((function e(t,n,a,o,r){var l,s;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(s=function(e){r instanceof Function&&r(e)},l=function(e){o instanceof Function&&o(e)},n=n||{},!a){e.next=8;break}return e.next=6,i.delete(t,n||null).then(l).catch(s||null);case 6:e.next=9;break;case 8:i.delete(t,n||null).then(l).catch(s||null);case 9:case"end":return e.stop()}}),e)})))).apply(this,arguments)}n(6028),t.Z=function(e,t,n,i,a){return r.apply(this,arguments)}},6203:function(e,t,n){n(2322),n(9268),n(3233),t.Z=function(){var e,t,n,i=null;if(document.cookie&&""!==document.cookie)for(t=document.cookie.split(";"),e=0;e<t.length;){if("csrftoken="===(n=t[e].trim()).substring(0,10)){i=decodeURIComponent(n.substring(10));break}e+=1}return i}},1712:function(e,t,n){n(6394),n(5334),n(7588);var i=n(4559);function a(e,t,n,i,a,o,r){try{var l=e[o](r),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(i,a)}function o(e){return function(){var t=this,n=arguments;return new Promise((function(i,o){var r=e.apply(t,n);function l(e){a(r,i,o,l,s,"next",e)}function s(e){a(r,i,o,l,s,"throw",e)}l(void 0)}))}}function r(){return(r=o(regeneratorRuntime.mark((function e(t,n,a,o){var r,l,s;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(s=function(e){if(o instanceof Function){var t=e;if(void 0===e.response)t={type:"network",error:e};else if(void 0!==e.response.status)switch(e.response.status){case 401:t={type:"private",error:e,message:"Media is private"};break;case 400:t={type:"unavailable",error:e,message:"Media is unavailable"}}o(t)}},l=function(e){a instanceof Function&&a(e)},r={timeout:null,maxContentLength:null},!n){e.next=8;break}return e.next=6,(0,i.get)(t,r).then(l).catch(s||null);case 6:e.next=9;break;case 8:(0,i.get)(t,r).then(l).catch(s||null);case 9:case"end":return e.stop()}}),e)})))).apply(this,arguments)}n(6028),t.Z=function(e,t,n,i){return r.apply(this,arguments)}},8420:function(e,t,n){n.d(t,{A_:function(){return i.Z},j0:function(){return a.Z},GH:function(){return o.Z},Jl:function(){return r.Z},v$:function(){return l.Z},uf:function(){return s.Z},$4:function(){return u.Z},hm:function(){return c.Z},m5:function(){return p.Z}});var i=n(1712),a=n(9752),o=n(84),r=n(9009),l=n(1438),s=n(4135),u=n(3140),c=(n(1752),n(7514),n(7634)),p=(n(1569),n(6203));n(7188)},9752:function(e,t,n){n(6394),n(5334),n(7588);var i=n(4559);function a(e,t,n,i,a,o,r){try{var l=e[o](r),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(i,a)}function o(e){return function(){var t=this,n=arguments;return new Promise((function(i,o){var r=e.apply(t,n);function l(e){a(r,i,o,l,s,"next",e)}function s(e){a(r,i,o,l,s,"throw",e)}l(void 0)}))}}function r(){return(r=o(regeneratorRuntime.mark((function e(t,n,a,o,r,l){var s,u;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(u=function(e){l instanceof Function&&l(e)},s=function(e){r instanceof Function&&r(e)},n=n||{},!o){e.next=8;break}return e.next=6,(0,i.post)(t,n,a||null).then(s).catch(u||null);case 6:e.next=9;break;case 8:(0,i.post)(t,n,a||null).then(s).catch(u||null);case 9:case"end":return e.stop()}}),e)})))).apply(this,arguments)}n(6028),t.Z=function(e,t,n,i,a,o){return r.apply(this,arguments)}},84:function(e,t,n){n(6394),n(5334),n(7588);var i=n(4559);function a(e,t,n,i,a,o,r){try{var l=e[o](r),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(i,a)}function o(e){return function(){var t=this,n=arguments;return new Promise((function(i,o){var r=e.apply(t,n);function l(e){a(r,i,o,l,s,"next",e)}function s(e){a(r,i,o,l,s,"throw",e)}l(void 0)}))}}function r(){return(r=o(regeneratorRuntime.mark((function e(t,n,a,o,r,l){var s,u;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(u=function(e){l instanceof Function&&l(e)},s=function(e){r instanceof Function&&r(e)},n=n||{},!o){e.next=8;break}return e.next=6,(0,i.put)(t,n,a||null).then(s).catch(u||null);case 6:e.next=9;break;case 8:(0,i.put)(t,n,a||null).then(s).catch(u||null);case 9:case"end":return e.stop()}}),e)})))).apply(this,arguments)}n(6028),t.Z=function(e,t,n,i,a,o){return r.apply(this,arguments)}},3699:function(e,t,n){n.d(t,{createPlaylist:function(){return o}}),n(2322),n(3296);var i=n(8416),a=n.n(i);function o(e){a().dispatch({type:"CREATE_PLAYLIST",playlist_data:e})}},5971:function(e,t,n){n.d(t,{AJ:function(){return o},CE:function(){return r},vg:function(){return l},X1:function(){return s},wg:function(){return u}});var i=n(8416),a=n.n(i);function o(){a().dispatch({type:"LOAD_PLAYLIST_DATA"})}function r(e){a().dispatch({type:"UPDATE_PLAYLIST",playlist_data:e})}function l(){a().dispatch({type:"REMOVE_PLAYLIST"})}function s(e,t){a().dispatch({type:"MEDIA_REMOVED_FROM_PLAYLIST",media_id:e,playlist_id:t})}function u(e){a().dispatch({type:"PLAYLIST_MEDIA_REORDERED",playlist_media:e})}},8204:function(e,t,n){n.d(t,{T:function(){return m}}),n(5101);var i=n(5466),a=(n(6116),n(8349)),o=n(9690),r=n(7370);function l(e){return(l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function s(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e,t){return!t||"object"!==l(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 p(e){return(p=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var m=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)}(d,e);var t,n,l,m,f=(l=d,m=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=p(l);if(m){var n=p(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return c(this,e)});function d(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,d),n=f.call(this,e),void 0!==t&&a.df(t),n}return t=d,(n=[{key:"render",value:function(){return[i.createElement(o.Z,{key:"page-main"},this.pageContent()),i.createElement(r.T,{key:"notifications"})]}}])&&s(t.prototype,n),d}(i.PureComponent)},8349:function(e,t,n){n.d(t,{df:function(){return o},wN:function(){return r}});var i=n(8416),a=n.n(i);function o(e){a().dispatch({type:"INIT_PAGE",page:e})}function r(e,t){a().dispatch({type:"ADD_NOTIFICATION",notification:e,notificationId:t})}}},t={};function n(i){if(t[i])return t[i].exports;var a=t[i]={exports:{}};return e[i].call(a.exports,a,a.exports,n),a.exports}n.m=e,n.x=function(){},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,{a:t}),t},n.d=function(e,t){for(var i in t)n.o(t,i)&&!n.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.j=449,function(){var e={449:0},t=[[4311,431]],i=function(){},a=function(a,o){for(var r,l,s=o[0],u=o[1],c=o[2],p=o[3],m=0,f=[];m<s.length;m++)l=s[m],n.o(e,l)&&e[l]&&f.push(e[l][0]),e[l]=0;for(r in u)n.o(u,r)&&(n.m[r]=u[r]);for(c&&c(n),a&&a(o);f.length;)f.shift()();return p&&t.push.apply(t,p),i()},o=self.webpackChunk_mediacms_frontend=self.webpackChunk_mediacms_frontend||[];function r(){for(var i,a=0;a<t.length;a++){for(var o=t[a],r=!0,l=1;l<o.length;l++){var s=o[l];0!==e[s]&&(r=!1)}r&&(t.splice(a--,1),i=n(n.s=o[0]))}return 0===t.length&&(n.x(),n.x=function(){}),i}o.forEach(a.bind(null,0)),o.push=a.bind(null,o.push.bind(o));var l=n.x;n.x=function(){return n.x=l||function(){},(i=r)()}}(),n.x()}();