PageSourceSearch

https://paxvoorvrede.nl/wp-content/plugins/podcast-player/frontend/js/public.build.js?ver=8.3.3

js paxvoorvrede.nl collected 2026-09-24 18:44:07 UTC 85,648 bytes, 1 lines download raw bytes

1(()=>{"use strict";function t(t,e){(null==e||e>t.length)&&(e=t.length);for(var i=0,s=Array(e);i<e;i++)s[i]=t[i];return s}var e=window.PP_Hooks||{hooks:{},actions:{},actionHistory:{},addFilter:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:10,s=this.hooks[t]=this.hooks[t]||[];s.push({callback:e,priority:i}),s.sort(function(t,e){return t.priority-e.priority})},applyFilters:function(t,e){for(var i=arguments.length,s=new Array(i>2?i-2:0),a=2;a<i;a++)s[a-2]=arguments[a];var n=this.hooks[t];return n?n.reduce(function(t,e){return e.callback.apply(void 0,[t].concat(s))},e):e},addAction:function(e,i){var s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:10,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},n=this.actions[e]=this.actions[e]||[];n.push({callback:i,priority:s}),n.sort(function(t,e){return t.priority-e.priority}),a.replay&&this.actionHistory[e]&&this.actionHistory[e].forEach(function(e){return i.apply(void 0,function(e){if(Array.isArray(e))return t(e)}(s=e)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(s)||function(e,i){if(e){if("string"==typeof e)return t(e,i);var s={}.toString.call(e).slice(8,-1);return"Object"===s&&e.constructor&&(s=e.constructor.name),"Map"===s||"Set"===s?Array.from(e):"Arguments"===s||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(s)?t(e,i):void 0}}(s)||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.")}());var s})},doAction:function(t){for(var e=arguments.length,i=new Array(e>1?e-1:0),s=1;s<e;s++)i[s-1]=arguments[s];if("podcast_player_transcripts_setup"===t){var a=this.actionHistory[t]=this.actionHistory[t]||[],n=i[0];n&&a.some(function(t){return t[0]===n})||a.push(i)}var o=this.actions[t];o&&o.forEach(function(t){return t.callback.apply(void 0,i)})}};window.PP_Hooks=e;var i=window.podcastPlayerData||{};const s={podcastPlayerData:jQuery.extend(!0,{},i),currentlyPlaying:!1,isStyleSupport:function(t,e){var i=window.ppmejsSettings.stSup||!1;return!(!i||!t)&&i[t].includes(e)},isInViewport:function(t){if(t&&t.length){var e=t.offset().top,i=t.offset().top+t.outerHeight(),s=jQuery(window).scrollTop()+jQuery(window).innerHeight(),a=jQuery(window).scrollTop();return s>e&&a<i}},stickyonScroll:function(){this.currentlyPlaying&&this.currentlyPlaying()},createCookie:function(t,e,i){var s;if(e=JSON.stringify(e),i){var a=new Date;a.setTime(a.getTime()+24*i*60*60*1e3),s="; expires="+a.toGMTString()}else s="";document.cookie=encodeURIComponent(t)+"="+encodeURIComponent(e)+s+"; path=/ ; SameSite=Lax"},readCookie:function(t){for(var e=encodeURIComponent(t)+"=",i=document.cookie.split(";"),s=0;s<i.length;s++){for(var a=i[s];" "===a.charAt(0);)a=a.substring(1,a.length);if(0===a.indexOf(e)){var n=decodeURIComponent(a.substring(e.length,a.length));return JSON.parse(n)}}return null},eraseCookie:function(t){this.createCookie(t,"",-1)}};function a(t){return a="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},a(t)}function n(t,e){for(var i=0;i<e.length;i++){var s=e[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(t,o(s.key),s)}}function o(t){var e=function(t){if("object"!=a(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,"string");if("object"!=a(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==a(e)?e:e+""}const r=function(){return t=function t(e){var i,a;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),i=this,(a=o(a="resizeTimeout"))in i?Object.defineProperty(i,a,{value:null,enumerable:!0,configurable:!0,writable:!0}):i[a]=null,this.id=e,this.podcast=s[e].podcast,this.instance=s[e].instance,this.mainMenuItems(),this.menuToggle=this.podcast.find(".pod-items__menu-open"),this.infoToggle=this.podcast.find(".pod-launch__info"),this.events()},(e=[{key:"mainMenuItems",value:function(){var t=this.podcast.attr("data-main-items"),e=this.podcast.find(".pod-content__launcher"),i=this.podcast.find(".pod-items__navi-menu");if(t){var s=i.find("#podcast-menu-"+this.instance);if(s.length){var a=s.find(".menu-item > a").slice(0,t),n=a.clone();a.closest(".menu-item").hide(),jQuery.each(n,function(t,e){var i=jQuery(e),s=i.find(".subscribe-item");i.addClass(s.attr("class")).addClass("pp-badge"),i.html(s.html())}),i.prepend(n),s.find(".menu-item").length<=t&&s.closest(".pod-items__menu").hide(),e.length&&e.prepend(i.clone())}}else e.length&&e.prepend(i.clone())}},{key:"events",value:function(){this.menuToggle.on("click",function(){this.menuToggle.closest(".pod-items__menu").toggleClass("toggled-window"),this.menuToggle.toggleClass("toggled-on").attr("aria-expanded",this.menuToggle.hasClass("toggled-on"))}.bind(this)),this.infoToggle.on("click",function(){this.podcast.toggleClass("header-toggle"),this.infoToggle.toggleClass("toggled-on").attr("aria-expanded",this.menuToggle.hasClass("toggled-on"))}.bind(this))}}])&&n(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();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},l(t)}function d(t,e){for(var i=0;i<e.length;i++){var s=e[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(t,p(s.key),s)}}function p(t){var e=function(t){if("object"!=l(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,"string");if("object"!=l(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==l(e)?e:e+""}const c=function(){return t=function t(e){var i=this;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.id=e,this.podcast=s[e].podcast,this.mediaObj=s[e].mediaObj,this.msgMediaObj=s[e].msgMediaObj,this.controls=jQuery(this.mediaObj.controls),this.msgControls=!!this.msgMediaObj&&jQuery(this.msgMediaObj.controls),this.layers=this.controls.prev(".ppjs__layers"),this.media=this.mediaObj.media,this.msgMedia=!!this.msgMediaObj&&this.msgMediaObj.media,this.modalObj=s[e].modal,this.settings=s[e].settings,this.transcript=s[e].episode,this.list=s[e].list,this.props=s[e],this.instance=s[e].instance,this.player=s[e].player,this.isPremium=this.settings.isPremium,this.isLargeScrn=s.isLrgScrn,this.data=s.podcastPlayerData,this.singleWrap=s[e].singleWrap,this.isInViewport=s.isInViewport,this.fetched=s[e].fetched,this.timeOut=!1,this.autostickytimer=!1,setTimeout(function(){i.timeOut=!0},3e3),this.modControlMarkup(),this.modLayersMarkup(),this.plBtn=this.controls.find(".ppjs__playpause-button > button"),this.forBtn=this.controls.find(".ppjs__jump-forward-button > button"),this.bckBtn=this.controls.find(".ppjs__skip-backward-button > button"),this.ttBtn=this.controls.find(".ppjs__episode-excerpt"),this.ssBtn=this.controls.find(".ppjs__share-button > button"),this.pbrBtn=this.controls.find(".ppjs__play-rate-button > button"),this.rateLink=this.controls.find(".prl-item"),this.copylink=this.podcast.find(".ppsocial__copylink"),this.copyField=this.podcast.find("input.pp-copylink"),this.rlbtn=this.podcast.find(".pp-list-btn"),this.msgControls&&(this.msgplBtn=this.msgControls.find(".ppjs__playpause-button > button"),this.msgforBtn=this.msgControls.find(".ppjs__jump-forward-button > button"),this.msgbckBtn=this.msgControls.find(".ppjs__skip-backward-button > button")),this.events()},e=[{key:"events",value:function(){var t=this,e=this;jQuery(document).on("click",function(e){var i=jQuery(e.target),s=i.closest(".toggled-window");jQuery(".toggled-window").removeClass("toggled-window"),s.length&&s.addClass("toggled-window"),i.closest(".ppshare__social").length||(t.copylink.removeClass("pp-link-copied"),t.copyField.hide())}),jQuery(document).on("keyup",function(t){"Escape"===t.key&&jQuery(".toggled-window").removeClass("toggled-window")}),this.media.addEventListener("loadedmetadata",this.condbtnPauseMedia.bind(this)),this.media.addEventListener("play",this.btnPlayMedia.bind(this)),this.media.addEventListener("playing",this.btnPlayMedia.bind(this)),this.media.addEventListener("pause",this.btnPauseMedia.bind(this)),this.forBtn.on("click",this.forwardMedia.bind(this)),this.bckBtn.on("click",this.skipbackMedia.bind(this)),this.ttBtn.on("click",this.showtranscript.bind(this)),this.ssBtn.on("click",this.showsocialshare.bind(this)),this.pbrBtn.on("click",this.mediaPlayToggle.bind(this)),this.rlbtn.on("click",this.revealList.bind(this)),this.rateLink.on("click",function(t){t.preventDefault(),e.mediaPlayRate.call(e,this)}),this.podcast.find(".episode-single__close").on("click",this.hidetranscript.bind(this)),this.msgMedia&&(this.msgMedia.addEventListener("loadedmetadata",this.msgcondbtnPauseMedia.bind(this)),this.msgMedia.addEventListener("play",this.msgbtnPlayMedia.bind(this)),this.msgMedia.addEventListener("playing",this.msgbtnPlayMedia.bind(this)),this.msgMedia.addEventListener("pause",this.msgbtnPauseMedia.bind(this))),this.msgControls&&(this.msgplBtn.on("click",this.msgPlayPause.bind(this)),this.msgforBtn.on("click",this.msgForwardMedia.bind(this)),this.msgbckBtn.on("click",this.msgSkipbackMedia.bind(this)))}},{key:"forwardMedia",value:function(){var t,e;e=isNaN(this.media.duration)?30:this.media.duration,t=this.media.currentTime===1/0?0:this.media.currentTime,this.media.currentTime=Math.min(t+30,e),this.forBtn.blur()}},{key:"skipbackMedia",value:function(){var t;t=this.media.currentTime===1/0?0:this.media.currentTime,this.media.currentTime=Math.max(t-10,0),this.bckBtn.blur()}},{key:"msgPlayPause",value:function(){this.msgMediaObj.media.paused?this.msgMediaObj.media.play():this.msgMediaObj.media.pause()}},{key:"msgForwardMedia",value:function(){var t,e;e=isNaN(this.msgMedia.duration)?15:this.msgMedia.duration,t=this.msgMedia.currentTime===1/0?0:this.msgMedia.currentTime,this.msgMedia.media.currentTime=Math.min(t+15,e),this.msgforBtn.blur()}},{key:"msgSkipbackMedia",value:function(){var t;t=this.msgMedia.currentTime===1/0?0:this.msgMedia.currentTime,this.msgMedia.media.currentTime=Math.max(t-15,0),this.msgbckBtn.blur()}},{key:"mediaPlayToggle",value:function(){this.pbrBtn.parent().toggleClass("toggled-window")}},{key:"revealList",value:function(){this.list.slideToggle(400),this.rlbtn.toggleClass("toggled-on"),this.rlbtn.hasClass("toggled-on")||jQuery("html, body").animate({scrollTop:this.player.offset().top},400),this.rlbtn.blur()}},{key:"mediaPlayRate",value:function(t){var e=jQuery(t),i=parseFloat(e.text()),a=e.closest(".ppjs__button");s[this.id].playRate=i,a.length&&a.hasClass("toggled-window")&&(a.find(".pp-rate").text(i),this.media.playbackRate=i,a.removeClass("toggled-window"))}},{key:"btnPlayMedia",value:function(){this.podcast.hasClass("postview")?s.currentlyPlaying=!1:s.currentlyPlaying=this.autoSticky.bind(this),this.plBtn.removeClass("playing pause"),this.bufferedPlay()}},{key:"bufferedPlay",value:function(){var t=this;this.plBtn.hasClass("pause")?this.plBtn.removeClass("buffering"):this.media.readyState>=0&&this.media.readyState<4?(this.plBtn.addClass("buffering"),setTimeout(function(){t.bufferedPlay()},250)):(this.plBtn.removeClass("buffering"),this.plBtn.addClass("playing"))}},{key:"btnPauseMedia",value:function(){this.plBtn.removeClass("playing"),this.plBtn.addClass("pause")}},{key:"showtranscript",value:function(t){t.preventDefault(),this.transcript.slideToggle("fast")}},{key:"hidetranscript",value:function(){this.transcript.slideUp("fast")}},{key:"showsocialshare",value:function(){this.ssBtn.parent().toggleClass("toggled-window"),this.podcast.find(".ppsocial__copylink").removeClass("pp-link-copied")}},{key:"condbtnPauseMedia",value:function(){this.plBtn.removeClass("playing")}},{key:"msgbtnPlayMedia",value:function(){this.msgplBtn.addClass("playing")}},{key:"msgbtnPauseMedia",value:function(){this.msgplBtn.removeClass("playing")}},{key:"msgcondbtnPauseMedia",value:function(){this.msgplBtn.removeClass("playing")}},{key:"modControlMarkup",value:function(){var t,e,i,s,a,n,o,r,l,d,p="pp-podcast-".concat(this.instance),c="ppe-".concat(this.instance,"-1"),h=!!this.data[p]&&this.data[p].rdata,u=!!this.data[p]&&this.data[p].load_info;if(this.data[p]&&(a=(s=this.data[p][c]?this.data[p][c]:{}).featured,d=s.duration||"00:00"),this.mediaObj.isVideo)this.controls.find(".ppjs__time, .ppjs__time-rail").wrapAll('<div class="ppjs__video-timer" />'),this.controls.prepend(this.settings.ppPlayPauseBtn),this.controls.find(".ppjs__fullscreen-button >
1 button").html(this.settings.ppMaxiScrnBtn+this.settings.ppMiniScrnBtn),this.controls.find(".ppjs__fullscreen-button").after(this.settings.ppVideoShare),this.transcript.find(".ppjs__img-wrapper").hide(),a&&("function"==typeof this.mediaObj.setPoster?this.mediaObj.setPoster(a):this.layers.find(".ppjs__poster").empty().append('<img src="'+a+'"/>').show());else{if(this.controls.find(".ppjs__time").wrapAll('<div class="ppjs__audio-timer" />'),this.controls.find(".ppjs__duration").text(d),this.controls.find(".ppjs__time-rail").wrap('<div class="ppjs__audio-time-rail" />'),t=jQuery("<div />",{class:"ppjs__audio-controls"}),n=this.transcript.find(".ppjs__img-wrapper").first(),t.html(this.settings.ppAudioControlBtns),this.controls.prepend(t),this.podcast.hasClass("modern")){var m=this.controls.find(".head-wrapper").wrap('<div class="ppjs__head-content" />'),y=this.controls.find(".ppjs__secondary-controls"),f=this.controls.find(".ppjs__time");m.after(y),this.controls.find(".ppjs__audio-timer").next(".ppjs__audio-time-rail").addBack().wrapAll('<div class="ppjs__atime-container" />'),this.controls.find(".ppjs__atime-container").append(f)}if(!this.podcast.is(".single-audio, .hide-content, .single-episode")&&this.isPremium&&this.controls.find(".ppjs__secondary-controls").append(this.settings.ppAdditionalControls),this.controls.find(".ppjs__head-container").prepend(n),(e=!!(e=this.transcript.find(".episode-single__title")).length&&e.html())&&this.controls.find(".ppjs__episode-title").html(e),this.podcast.hasClass("special-style"))this.controls.find(".ppjs__episode-excerpt").hide();else if(l=this.podcast.data("teaser"),o=(o=!!u&&u.args.elength)||this.podcast.data("elength"),r=this.podcast.data("eunit"),i=this.transcript.find(".episode-single__description"),"full"===l&&i.length){var v=jQuery("<div />",{class:"ppjs__episode-full-content"});this.controls.find(".ppjs__more").css("display","none"),this.controls.find(".ppjs__episode-excerpt").before(v),this.controls.find(".ppjs__head-container").css("align-items","flex-start"),this.controls.find(".ppjs__episode-full-content").html(i.html()),this.controls.find(".ppjs__episode-excerpt").hide()}else"none"===l?this.controls.find(".ppjs__episode-excerpt").hide():(i=!(!(i=!!i.length&&i.text().trim())||!i.length)&&i,o&&i?(r?i.length>o?(i=i.substr(0,o),this.controls.find(".ppjs__more").css("display","inline")):this.controls.find(".ppjs__more").css("display","none"):i.split(/\s+/).length>o?(i=i.split(/\s+/).splice(0,o).join(" "),this.controls.find(".ppjs__more").css("display","inline")):this.controls.find(".ppjs__more").css("display","none"),this.controls.find(".ppjs__excerpt-content").text(i),this.controls.find(".ppjs__episode-excerpt").show()):this.controls.find(".ppjs__episode-excerpt").hide());if(this.props.isWide)if(h&&void 0!==h.title&&h.title)this.controls.find(".ppjs__podcast-title").html(h.title);else{var g=this.podcast.find(".pod-items__title");(g=!!g.length&&g.html())&&this.controls.find(".ppjs__podcast-title").html(g)}else if(this.isLargeScrn&&(this.podcast.hasClass("narrow-player")||this.podcast.hasClass("wide-player"))){var _=n.find(".ppjs__img-btn");_.attr("sizes","(max-width: 640px) 100vw, 640px"),void 0!==_.attr("data-sizes")&&_.attr("data-sizes","(max-width: 640px) 100vw, 640px")}jQuery(this.media).find("audio.pp-podcast-episode.hide-audio").remove()}this.modMediaMarkup(),this.msgMediaObj&&(this.msgControls.find(".ppjs__time").wrapAll('<div class="ppjs__audio-timer" />'),this.msgControls.find(".ppjs__time-rail").wrap('<div class="ppjs__audio-time-rail" />'),(t=jQuery("<div />",{class:"ppjs__audio-controls"})).html(this.settings.ppAudioControlBtns),this.msgControls.prepend(t),h&&void 0!==h.msgtext&&this.msgControls.find(".ppjs__episode-title").text(h.msgtext))}},{key:"modMediaMarkup",value:function(){var t=this;if(!1!==s[this.id].fetched){var e,i="pp-podcast-".concat(this.instance),a="ppe-".concat(this.instance,"-1"),n=!!this.data[i]&&this.data[i].rdata;if(this.data[i]&&(e=this.data[i][a]?this.data[i][a]:{}).featured,e&&n){var o=encodeURIComponent(e.link),r=jQuery("<div>").html(e.src).html().replace(/&amp;/g,"&"),l=this.controls.find(".ppshare__social"),d=encodeURIComponent(e.title);
1if(this.isPremium&&!1!==n&&"feedurl"===n.from){if(void 0!==e.key){var p={ppplayer:n.fprint,ppepisode:e.key},c=jQuery.param(p),h=n.permalink;o=h?h+(h.indexOf("?")<0?"?":"&")+c:o,o=encodeURIComponent(o)}}else if(this.isPremium){var u=jQuery.param({sharedby:"pplayer"});o=o+(o.indexOf("?")<0?"?":"&")+encodeURIComponent(u)}var m="https://www.facebook.com/sharer.php?u="+o,y="https://twitter.com/intent/tweet?url="+o+"&text="+d,f="https://www.linkedin.com/shareArticle?mini=true&url="+o,v="mailto:?subject="+d+"&body=Link:"+o;l.find(".ppsocial__facebook").attr("href",m),l.find(".ppsocial__twitter").attr("href",y),l.find(".ppsocial__linkedin").attr("href",f),l.find(".ppsocial__email").attr("href",v),l.find("input.pp-copylink").val(decodeURIComponent(o)),this.controls.find(".ppshare__download").attr("href",r)}}else!1===this.timeOut&&setTimeout(function(){t.modMediaMarkup()},200)}},{key:"modLayersMarkup",value:function(){this.layers.find(".ppjs__overlay-play > .ppjs__overlay-button").html(this.settings.ppPlayCircle),this.layers.find(".ppjs__overlay > .ppjs__overlay-loading").html(this.settings.ppVidLoading)}},{key:"autoSticky",value:function(){var t=this;this.autostickytimer||this.modalObj&&(this.autostickytimer=!0,this.modalObj.modal&&this.modalObj.modal.hasClass("pp-modal-open")?this.isInViewport(this.podcast)&&this.modalObj.returnElem():this.plBtn.hasClass("playing")&&(this.isInViewport(this.podcast)||this.modalObj.create(this.singleWrap,this.mediaObj,this.msgMediaObj,!1,!1)),setTimeout(function(){t.autostickytimer=!1},66))}}],e&&d(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function h(t){return h="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},h(t)}function u(t,e){for(var i=0;i<e.length;i++){var s=e[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(t,y(s.key),s)}}function m(t,e,i){return(e=y(e))in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}function y(t){var e=function(t){if("object"!=h(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,"string");if("object"!=h(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==h(e)?e:e+""}var f=function(){return t=function t(e){var i=this;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),m(this,"listItem",void 0),m(this,"loadMore",void 0),m(this,"statTimeOut",null),this.id=e,this.podcast=s[e].podcast,this.list=s[e].list,this.episode=s[e].episode,this.player=s[e].player,this.mediaObj=s[e].mediaObj,this.media=this.mediaObj.media,this.instance=s[e].instance,this.modalObj=s[e].modal,this.modal=!!this.modalObj&&this.modalObj.modal,this.single=s[e].single,this.singleWrap=s[e].singleWrap,this.data=s.podcastPlayerData,this.msgMediaObj=s[e].msgMediaObj,this.msgControls=!!this.msgMediaObj&&jQuery(this.msgMediaObj.controls),this.msgMedia=!!this.msgMediaObj&&this.msgMediaObj.media,this.msgFreqCounter=0,this.controls=jQuery(this.mediaObj.controls),this.layers=this.controls.prev(".ppjs__layers"),this.plBtn=this.controls.find(".ppjs__playpause-button > button"),this.prevBtn=this.podcast.find(".pp-prev-btn").attr("disabled",!0),this.nxtBtn=this.podcast.find(".pp-next-btn"),this.copylink=this.podcast.find(".ppsocial__copylink"),this.copyField=this.podcast.find("input.pp-copylink"),this.playingAmsg=!1,this.playAmsg=!1,this.played=!1,this.settings=s[e].settings,this.isPremium=this.settings.isPremium,this.i18n=this.settings.i18n||{},this.timeOut=!1,this.playTime=!1,this.runCookieUpdate=!1,this.listItem=!1,this.audioFirstPlay=!0,setTimeout(function(){i.timeOut=!0},3e3),this.dispatchAnalyticsAction("podcast_player_analytics_ready"),this.events()},e=[{key:"events",value:function(){var t=this,e=!!t.modalObj&&t.modalObj.modal;if(t.podcast.hasClass("modern")?(t.list.on("click",".pod-entry__mplay, .pod-entry__title",function(e){e.preventDefault(),t.listItem=jQuery(this).closest(".episode-list__entry, .episode-list__search-entry"),t.modPrevBtn(),t.modNextBtn(),t.play(!0),t.podcast.hasClass("search-opened")&&(t.prevBtn.attr("disabled",!0),t.nxtBtn.attr("disabled",!0))}),t.list.on("click",".pod-entry__mscript",function(e){var i=jQuery(this);if(!i.hasClass("pp-entry__mpost")){var s=i.closest(".episode-list__entry, .episode-list__search-entry");e.preventDefault(),t.showModernEpisodeContent(s)}})):t.podcast.hasClass("postview")?(t.list.on("click",".pod-entry__title a, .pod-entry__featured",function(i){var s=jQuery(this);
1if(!s.hasClass("fetch-post-title")){var a="pp-podcast-".concat(t.instance),n=t.data[a].load_info,o=!!n&&!!n.args&&n.args.hddesc;o=o||!1;var r=!s.hasClass("pod-entry__featured")&&!o||t.mediaObj.isVideo;if(i.preventDefault(),t.listItem=s.closest(".pod-entry"),t.modPrevBtn(),t.modNextBtn(),t.playModal(r),r&&e&&setTimeout(function(){e.find(".ppjs__audio-controls button").first().focus()},200),!e.hasClass("modal-view")){var l=e.find(".pp-modal-close"),d=e.find(".pp-modal-wrapper");l.hasClass("modal-closed")&&(l.removeClass("modal-closed"),d.animate({height:"toggle"},400))}t.podcast.hasClass("search-opened")&&(t.prevBtn.attr("disabled",!0),t.nxtBtn.attr("disabled",!0))}}),t.list.on("click",".pod-entry__excerpt a",function(e){var i=jQuery(this);i.hasClass("fetch-feed-title")&&(e.preventDefault(),t.showEpisodeContent(i))})):t.list.on("click",".episode-list__entry, .episode-list__search-entry",function(e){e.preventDefault(),t.listItem=jQuery(this),t.modPrevBtn(),t.modNextBtn(),t.play(!0),t.podcast.hasClass("search-opened")&&(t.prevBtn.attr("disabled",!0),t.nxtBtn.attr("disabled",!0))}),e){var i=e.find(".pp-modal-tabs-list");i.length&&i.on("click",".pod-entry__mplay,.pod-entry__title a, .pod-entry__featured",function(i){var s=jQuery(this).closest(".pod-entry");e.find(".modal-"+t.instance).length&&(i.preventDefault(),t.listItem=s,t.modPrevBtn(),t.modNextBtn(),t.playModal(!1))})}this.prevBtn.on("click",this.playPreviousEpisode.bind(this)),this.nxtBtn.on("click",this.playNextEpisode.bind(this)),this.msgMedia&&this.msgMedia.addEventListener("ended",this.msgMediaEnded.bind(this)),this.plBtn.on("click",this.playPauseBtn.bind(this)),this.layers&&this.layers.find(".ppjs__overlay-play").on("click",this.playPauseBtn.bind(this)),this.copylink.on("click",function(e){e.preventDefault(),t.copyLink()}),jQuery(window).on("load",function(){t.podcast.parent().hasClass("pp-sticky-player")&&(t.listItem=t.podcast.find(".pod-entry").first(),t.modPrevBtn(),t.modNextBtn(),t.showStickyPlayer())});var s=this.settings.cookies||!1;this.isPremium&&s&&(this.mediaObj.media.addEventListener("playing",this.updateCookie.bind(this)),this.mediaObj.media.addEventListener("pause",this.stopCookieUpdate.bind(this)),this.mediaObj.media.addEventListener("ended",this.deleteCookie.bind(this))),this.mediaObj.media.addEventListener("ended",this.mediaEnded.bind(this)),this.settings.isPremium&&this.settings.analytics&&(this.media.addEventListener("play",this.playAnalytics.bind(this)),this.media.addEventListener("pause",this.pauseAnalytics.bind(this)),this.media.addEventListener("ended",this.endAnalytics.bind(this)),document.addEventListener("visibilitychange",this.visibilityAnalytics.bind(this)),window.addEventListener("beforeunload",this.beforeUnloadAnalytics.bind(this))),this.dispatchHook("podcast_player_transcripts_setup",this,{modal:e}),this.dispatchHook("podcast_player_feedback_setup",this,{modal:e})}},{key:"updateCookie",value:function(){if(this.listItem){var t,e="pp-podcast-".concat(this.instance),i=!!this.data[e]&&this.data[e].rdata,a=this.listItem.attr("id")||this.listItem.attr("data-pid");if(t=this.listItem.hasClass("episode-list__search-entry")?!!this.data.search&&this.data.search[a]:!!this.data[e]&&this.data[e][a],this.playTime&&(this.mediaObj.media.currentTime=this.playTime,this.playTime=!1),this.isPremium&&!1!==i&&void 0!==t&&t)if("feedurl"===i.from){var n={fmethod:"feed",ppplayer:i.fprint,ppepisode:t.key,time:0};s.createCookie("ppCookie",n,7);var o=this.mediaObj.getSrc();this.runCookieUpdate=!0,this.updateEpisodeCookie(o)}else if("posts"===i.from){var r={fmethod:"post",epid:t.id,time:0};s.createCookie("ppCookie",r,7);var l=this.mediaObj.getSrc();this.runCookieUpdate=!0,this.updateEpisodeCookie(l)}else if("link"===i.from){var d={fmethod:"link",audioSrc:t.src,audioTitle:t.title,time:0};s.createCookie("ppCookie",d,7);var p=this.mediaObj.getSrc();this.runCookieUpdate=!0,this.updateEpisodeCookie(p)}}}},{key:"updateEpisodeCookie",value:function(t){var e=this,i=this.mediaObj.getSrc();if(t===i&&this.runCookieUpdate){var a=s.readCookie("ppCookie");a.time=this.media.currentTime,s.createCookie("ppCookie",a,7),setTimeout(function(){e.updateEpisodeCookie(t)},4e3)}}},{key:"stopCookieUpdate",value:function(){this.runCookieUpdate=!1}},{key:"deleteCookie",value:function(){this.runCookieUpdate=!1,s.eraseCookie("ppCookie")}},{key:"playPreviousEpisode",value:function(){if(this.prevBtn.attr("disabled",!0),this.listItem&&!this.listItem.hasClass("episode-list__search-entry")){var t=this.listItem.prev(".episode-list__entry");if(t.length)return this.listItem=t,this.modNextBtn(),this.controls.parents("#pp-modal-window").length?this.playModal(this.modalObj.modal&&this.modalObj.modal.hasClass("modal-view")):this.play(),void(this.listItem.prev(".episode-list__entry").length&&this.prevBtn.attr("disabled",!1));this.listItem.removeClass("activeEpisode media-playing")}this.prevBtn.blur()}},{key:"modPrevBtn",value:function(){this.prevBtn.attr("disabled",!0),this.listItem&&!this.listItem.hasClass("episode-list__search-entry")&&this.listItem.prev(".episode-list__entry").length&&this.prevBtn.attr("disabled",!1)}},{key:"playNextEpisode",value:function(){if(this.listItem&&!this.listItem.hasClass("episode-list__search-entry")){var t=this.listItem.next(".episode-list__entry");t.length?(this.listItem=t,this.modPrevBtn(),this.controls.parents("#pp-modal-window").length?this.playModal(this.modalObj.modal&&this.modalObj.modal.hasClass("modal-view")):this.play(),this.listItem.next(".episode-list__entry").length||this.checkforNextEpisode(!1)):this.checkforNextEpisode(!0)}else{var e=this.list.find(".episode-list__entry").first();e.length&&(this.listItem=e,this.podcast.hasClass("postview")?this.playModal(this.modalObj.modal&&this.modalObj.modal.hasClass("modal-view")):this.play())}this.nxtBtn.blur()}},{key:"checkforNextEpisode",value:function(t){if(this.podcast.hasClass("single-audio")||this.podcast.hasClass("single-episode"))this.nxtBtn.attr("disabled",!0);else if(this.loadMore||(this.loadMore=s[this.id].loadMore),this.loadMore){var e=!!this.listItem.attr("data-pid");this.loadMore.loadEpisodes(e);var i=this.listItem.next(".episode-list__entry");i.length?t&&(this.listItem=i,this.modPrevBtn(),this.play()):this.nxtBtn.attr("disabled",!0)}}},{key:"modNextBtn",value:function(){this.nxtBtn.is(":disabled")&&this.listItem&&!this.listItem.hasClass("episode-list__search-entry")&&this.listItem.next(".episode-list__entry").length&&this.nxtBtn.attr("disabled",!1),this.listItem&&!this.listItem.hasClass("episode-list__search-entry")&&(this.listItem.next(".episode-list__entry").length||this.checkforNextEpisode())}},{key:"showEpisodeContent",value:function(t){var e,i=t.closest(".pod-entry"),s="pp-podcast-".concat(this.instance),a=i.attr("id"),n=i.find(".pod-entry__excerpt");e=i.hasClass("episode-list__search-entry")?this.data.search[a]:this.data[s][a],n.html(e.description).addClass("expanded")}},{key:"showModernEpisodeContent",value:function(t){var e,i="pp-podcast-".concat(this.instance),s=t.attr("id");e=t.hasClass("episode-list__search-entry")?this.data.search[s]:this.data[i][s],this.single.find(".episode-single__title").html(e.title),this.single.find(".episode-single__author").html(e.author),this.single.find(".episode-single__description").html(e.description),this.episode.slideDown("fast")}},{key:"common",value:function(){this.endAnalytics();var t,e,i,a,n,o,r,l,d,p="pp-podcast-".concat(this.instance),c=!!this.data[p]&&this.data[p].rdata,h=!!this.data[p]&&this.data[p].load_info,u=(!!h&&h.args,this.listItem.attr("id")||this.listItem.attr("data-pid")),m=!!this.modalObj&&this.modalObj.modal,y=s[this.id].playRate||1,f=this.controls.find(".ppshare__social");if(0<(t=this.list.find(".activeEpisode")).length&&t.removeClass("activeEpisode media-playing"),m){var v=m.find(".pp-modal-tabs-list");v.length&&v.find(".activeEpisode").removeClass("activeEpisode media-playing")}if(this.msgMediaObj&&(this.msgMediaObj.media.paused||this.msgMediaObj.media.pause(),this.msgMediaObj.media.currentTime=0),this.played=!0,this.playingAmsg=!1,this.player.removeClass("msg-playing"),e=this.listItem.hasClass("episode-list__search-entry")?this.data.search[u]:this.data[p][u],i=encodeURIComponent(e.link),a=encodeURIComponent(e.title),n=jQuery("<div>").html(e.src).html().replace(/&amp;/g,"&"),this.isPremium&&!1!==c&&"feedurl"===c.from){if(void 0!==e.ke
1y){var g={ppplayer:c.fprint,ppepisode:e.key},_=jQuery.param(g),b=c.permalink;i=b?b+(b.indexOf("?")<0?"?":"&")+_:i,i=encodeURIComponent(i)}}else if(this.isPremium){var j=jQuery.param({sharedby:"pplayer"});i=i+(i.indexOf("?")<0?"?":"&")+encodeURIComponent(j)}var w="https://www.facebook.com/sharer.php?u="+i,k="https://twitter.com/intent/tweet?url="+i+"&text="+a,C="https://www.linkedin.com/shareArticle?mini=true&url="+i,O="mailto:?subject="+a+"&body=Link:"+i;if(this.listItem.addClass("activeEpisode media-playing"),this.episode.find(".episode-single__title").html(e.title),this.episode.find(".episode-single__author > .single-author").html(e.author),this.controls.find(".ppjs__episode-title").html(e.title),this.episode.find(".episode-single__description").html(e.description),this.modalObj){var S=this.modalObj.modal.find(".pp-modal-aux-wrapper.aux-open");S.length&&(S.find(".episode-single__title").html(e.title),S.find(".episode-single__author > .single-author").html(e.author),S.find(".episode-single__description").html(e.description),S.find(".pp-modal-tabs-list").hide(),S.find(".lists-tab").removeClass("selected"),S.find(".content-tab").addClass("selected"),S.find(".pp-modal-tabs-content").fadeIn(),S.animate({scrollTop:0},400))}return f.find(".ppsocial__facebook").attr("href",w),f.find(".ppsocial__twitter").attr("href",k),f.find(".ppsocial__linkedin").attr("href",C),f.find(".ppsocial__email").attr("href",O),f.find("input.pp-copylink").val(decodeURIComponent(i)),this.controls.find(".ppshare__download").attr("href",n),d=this.podcast.data("teaser"),r=this.podcast.data("elength"),l=this.podcast.data("eunit"),this.podcast.hasClass("special-style")||(o=this.episode.find(".episode-single__description"),"full"===d&&o.length?(this.controls.find(".ppjs__more").css("display","none"),this.controls.find(".ppjs__episode-full-content").html(o.html())):"none"===d?this.controls.find(".ppjs__episode-excerpt").hide():""===d&&r&&((o=!!o.length&&o.text().trim())&&o.length?(l?o.length>r?(o=o.substr(0,r),this.controls.find(".ppjs__more").css("display","inline")):this.controls.find(".ppjs__more").css("display","none"):o.split(/\s+/).length>r?(o=o.split(/\s+/).splice(0,r).join(" "),this.controls.find(".ppjs__more").css("display","inline")):this.controls.find(".ppjs__more").css("display","none"),this.controls.find(".ppjs__excerpt-content").text(o),this.controls.find(".ppjs__episode-excerpt").show()):this.controls.find(".ppjs__episode-excerpt").hide())),this.mediaObj.isVideo&&"function"==typeof this.mediaObj.setPoster&&this.mediaObj.setPoster(e.featured||""),this.mediaObj.setSrc(n,{isHls:!!e.is_hls,mimeType:e.source_mime||""}),this.audioFirstPlay=!0,this.mediaObj.load(),this.mediaObj.media.playbackRate=y,this.playMessage(),!0}},{key:"decodeHtmlEntities",value:function(t){var e=document.createElement("textarea");return e.innerHTML=t,e.value}},{key:"btnImage",value:function(){var t,e="pp-podcast-".concat(this.instance),i=this.listItem.attr("id")||this.listItem.attr("data-pid"),s=this.player.find(".ppjs__img-btn").attr("data-src"),a=t=this.listItem.hasClass("episode-list__search-entry")?this.data.search[i]:this.data[e][i],n=a.title,o=a.featured,r=a.fset,l=t.fratio||1,d=this.decodeHtmlEntities(r);o?(this.player.find(".ppjs__img-btn").attr("srcset",d).attr("src",o).attr("alt",n).closest(".ppjs__img-wrapper").removeClass("noimg"),l*=100,l+="%",this.player.find(".ppjs__img-btn-style").css("padding-top",l),"undefined"!==h(s)&&!1!==s&&this.player.find(".ppjs__img-btn").attr("data-srcset",d).attr("data-src",o),this.modalObj&&this.modalObj.modal.find(".ppjs__img-btn").attr("scrset",d).attr("src",o).attr("alt",n).closest(".ppjs__img-wrapper").removeClass("noimg")):(this.player.find(".ppjs__img-wrapper").addClass("noimg"),this.modalObj&&this.modalObj.modal.find(".ppjs__img-wrapper").addClass("noimg"))}},{key:"playPauseBtn",value:function(){if(!1!==this.played)this.plBtn.parents("#pp-modal-window").length||this.modalObj.modal&&this.modalObj.modal.hasClass("pp-modal-open")&&this.modalObj.returnElem(),this.mediaObj.media.paused?(this.playMedia(),this.listItem&&this.listItem.addClass("activeEpisode media-playing")):(this.mediaObj.media.pause(),this.listItem&&this.listItem.removeClass("activeEpisode media-playing"));else{if(this.played=!0,this.listItem=this.list.find(".episode-list__entry").first(),!this.listItem.length){var t="ppe-".concat(this.instance,"-1");this.listItem=jQuery("<div />",{class:"episode-list__entry",id:t})}this.play()}}},{key:"playMedia",value:function(){"function"==typeof this.mediaObj.play?this.mediaObj.play():this.mediaObj.media.play()}},{key:"play",value:function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],e=this;if(this.listItem.hasClass("activeEpisode"))return this.listItem.removeClass("activeEpisode"),this.mediaObj.media.pause(),this.player.removeClass("msg-playing"),this.playingAmsg=!1,void(this.msgMediaObj&&(this.msgMediaObj.media.pause(),this.msgMediaObj.media.currentTime=0));this.modalObj.modal&&this.modalObj.modal.hasClass("pp-modal-open")&&this.modalObj.returnElem(),!1!==s[this.id].fetched?(this.common(),this.btnImage(),this.singleWrap.addClass("activePodcast"),this.playingAmsg||this.playMedia(),t&&!s.isLrgScrn&&jQuery("html, body").animate({scrollTop:this.player.offset().top},400)):!1===this.timeOut&&setTimeout(function(){e.play()},200)}},{key:"playModal",value:function(t){var e=this;
1this.modalObj&&(this.listItem.hasClass("activeEpisode")?t?(this.modalObj.modal.removeClass("inline-view").addClass("modal-view"),this.modalObj.scrollDisable(),this.playingAmsg||this.modalObj.modal.find(".episode-primary__title").find(".episode-single__title").html(this.episode.find(".episode-single__title").html())):this.msgMediaObj&&this.playingAmsg?this.msgMediaObj.media.paused?(this.msgMediaObj.media.play(),this.modalObj.modal.removeClass("media-paused"),this.listItem.addClass("media-playing")):(this.msgMediaObj.media.pause(),this.modalObj.modal.addClass("media-paused"),this.listItem.removeClass("media-playing")):this.mediaObj.media.paused?(this.playMedia(),this.modalObj.modal.removeClass("media-paused"),this.listItem.addClass("media-playing")):(this.mediaObj.media.pause(),this.modalObj.modal.addClass("media-paused"),this.listItem.removeClass("media-playing")):!1!==s[this.id].fetched?(this.common(),this.singleWrap.hasClass("activePodcast")?t&&(this.modalObj.modal.find(".episode-primary__title").find(".episode-single__title").html(this.episode.find(".episode-single__title").html()),this.modalObj.modal.removeClass("inline-view").addClass("modal-view"),this.modalObj.scrollDisable()):(this.modalObj.modal.hasClass("pp-modal-open")&&this.modalObj.returnElem(),this.modalObj.create(this.singleWrap,this.mediaObj,this.msgMediaObj,t),this.singleWrap.addClass("activePodcast")),t?this.listItem.removeClass("media-playing"):(this.playingAmsg||this.playMedia(),this.modalObj.modal.removeClass("media-paused")),this.btnImage()):!1===this.timeOut&&setTimeout(function(){e.playModal()},200))}},{key:"showStickyPlayer",value:function(){var t=this;if(this.modalObj)if(!1!==s[this.id].fetched){var e=s.readCookie("ppCookie")||{};this.playTime=e.time||!1,this.common(),this.singleWrap.hasClass("activePodcast")||(this.modalObj.modal.hasClass("pp-modal-open")&&this.modalObj.returnElem(),this.modalObj.create(this.singleWrap,this.mediaObj,this.msgMediaObj,!1),this.singleWrap.addClass("activePodcast"))}else!1===this.timeOut&&setTimeout(function(){t.showStickyPlayer()},200)}},{key:"playMessage",value:function(){var t="pp-podcast-".concat(this.instance),e=!!this.data[t]&&this.data[t].rdata;if(e&&void 0!==e.audiomsg)if(e.playfreq<=this.msgFreqCounter||!1===this.played){if(this.msgFreqCounter=0,"start"===e.msgstart)this.playingAmsg=!0,this.player.addClass("msg-playing"),this.msgMediaObj&&this.msgMediaObj.media.play();else if("end"===e.msgstart)this.playAmsg=!0;else if("custom"===e.msgstart){var i=60*e.msgtime[0]*60+60*e.msgtime[1]+e.msgtime[2];this.deferredPlay(i)}}else this.msgFreqCounter++,this.playingAmsg=!1}},{key:"deferredPlay",value:function(t){var e=this;if(t){var i=this.mediaObj.media.currentTime;i&&i>=t?(this.playingAmsg=!0,this.mediaObj.media.pause(),this.msgMediaObj&&this.msgMediaObj.media.play(),this.player.addClass("msg-playing")):setTimeout(function(){e.deferredPlay(t)},1e3)}}},{key:"mediaEnded",value:function(){if(!0===this.playAmsg)this.playingAmsg=!1,this.player.addClass("msg-playing"),this.msgMediaObj&&this.msgMediaObj.media.play();else if(this.listItem&&!this.listItem.hasClass("episode-list__search-entry")){var t="pp-podcast-".concat(this.instance),e=this.data[t]?this.data[t].rdata:{},i=e.autoplay?e.autoplay:"";"disable"===i?this.listItem.removeClass("activeEpisode media-playing"):"reverse"===i?this.playPreviousEpisode():this.playNextEpisode()}}},{key:"msgMediaEnded",value:function(){if(!0===this.playingAmsg)this.player.removeClass("msg-playing"),this.playingAmsg=!1,this.playMedia();else if(!0===this.playAmsg&&this.listItem&&!this.listItem.hasClass("episode-list__search-entry")){var t="pp-podcast-".concat(this.instance),e=this.data[t]?this.data[t].rdata:{},i=e.autoplay?e.autoplay:"";"disable"===i?this.listItem.removeClass("activeEpisode media-playing"):"reverse"===i?this.playPreviousEpisode():this.playNextEpisode()}}},{key:"copyLink",value:function(){this.copyField.length&&(this.copyField.show(),this.copyField[0].select(),this.copyField[0].setSelectionRange(0,99999),document.execCommand("copy"),this.copylink.addClass("pp-link-copied"))}},{key:"playAnalytics",value:function(){this.dispatchAnalyticsAction("podcast_player_analytics_play")}},{key:"pauseAnalytics",value:function(){this.dispatchAnalyticsAction("podcast_player_analytics_pause")}},{key:"endAnalytics",value:function(){this.dispatchAnalyticsAction("podcast_player_analytics_end")}},{key:"visibilityAnalytics",value:function(){document.hidden&&this.dispatchAnalyticsAction("podcast_player_analytics_hidden")}},{key:"beforeUnloadAnalytics",value:function(){this.dispatchAnalyticsAction("podcast_player_analytics_unload")}},{key:"dispatchHook",value:function(t){if(window.PP_Hooks&&"function"==typeof window.PP_Hooks.doAction){for(var e,i=arguments.length,s=new Array(i>1?i-1:0),a=1;a<i;a++)s[a-1]=arguments[a];(e=window.PP_Hooks).doAction.apply(e,[t].concat(s))}}},{key:"dispatchAnalyticsAction",value:function(t){this.dispatchHook(t,this)}}],e&&u(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();const v=f;function g(t){return g="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},g(t)}function _(t,e){for(var i=0;i<e.length;i++){var s=e[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(t,b(s.key),s)}}function b(t){var e=function(t){if("object"!=g(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,"string");if("object"!=g(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==g(e)?e:e+""}var j=function(){return t=function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.id=e,this.podcast=s[e].podcast,this.settings=s[e].settings,this.instance=s[e].instance,this.episodes=s[e].episodes,this.mediaObj=s[e].mediaObj,this.list=s[e].list,this.modalObj=s[e].modal,this.modal=!!this.modalObj&&this.modalObj.modal,this.fetched=s[e].fetched,this.isStyleSupport=s.isStyleSupport,this.data=s.podcastPlayerData,this.loadbtn=this.podcast.find(".episode-list__load-more"),this.auxList=!!this.modal&&this.modal.find(".pp-modal-tabs-list"),this.events()},e=[{key:"events",value:function(){var t=this;this.preLoadEpisodes(),this.loadbtn.on("click",function(){t.loadEpisodes(!1)}),this.auxList&&this.auxList.length&&this.auxList.on("click",".episode-list__load-more",function(){t.modal.find(".modal
1-"+t.instance).length&&t.loadEpisodes(!0)})}},{key:"preLoadEpisodes",value:function(){var t="pp-podcast-".concat(this.instance),e=!!this.data[t]&&this.data[t].rdata.from,i=!!this.data[t]&&this.data[t].load_info,a=!!i&&i.loaded;e&&"link"!==e?0!=a?s[this.id].fetched=!0:this.fetchEpisodes():e&&this.fetchMediaURL()}},{key:"loadEpisodes",value:function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],e="pp-podcast-".concat(this.instance);if(this.data[e]){var i,s=this.episodes.find(".episode-list__entry").first(),a=this.data[e].rdata.from,n=this.data[e].load_info,o=this.data[e].rdata.teaser,r=this.data[e].rdata.elen,l=this.data[e].rdata.eunit,d=jQuery("<div />"),p=s.find(".pod-entry__image"),c=p.length?p.attr("sizes"):"",h=!1;i=t?this.auxList.find(".pod-entry").length:this.list.find(".pod-entry").length;var u=Math.min(i+n.step,n.loaded),m=i+1,y="fetch-feed-title";for("posts"===a&&(y="fetch-post-title");m<=u;m++){var f="ppe-".concat(this.instance,"-").concat(m),v=t?'data-pid="'+f+'"':'id="'+f+'"',g=this.data[e][f];if(h=h||f,void 0!==g){var _=g.title,b=g.description,j=g.author,w=g.date,k=g.link,C=g.featured,O=g.fset,S=g.categories,E=g.tags,M=g.season,P=(S?Object.keys(S).join(" "):"")+" "+(E?Object.keys(E).join(" "):"")+" "+(M||""),x=jQuery("<a />",{href:k,class:y}).html(_),T=jQuery("<a />",{href:k,class:y}).html("[...]"),L=jQuery("<div />",{class:"pod-entry__title"}).html(x),I=jQuery("<div />",{class:"pod-entry__date"}).text(w),A=jQuery("<div />",{class:"pod-entry__author"}).html(j),Q="",B=void 0;if(this.podcast.hasClass("postview")){var H=n.args.display,R=0!=n.args.hdfeat,F=b?jQuery(b).text():"",U=jQuery("<div />",{class:"pod-entry__play"}).html(this.settings.ppPlayCircle+this.settings.ppPauseBtn),D=void 0,N="";if(D=H&&this.isStyleSupport(H,"playbtn")?"":(D=C?jQuery("<img />",{class:"pod-entry__image",src:C,srcset:O,sizes:c,alt:_}):"")?'<div class="pod-entry__thumb">'.concat(D[0].outerHTML,"</div>"):"",R&&!this.isStyleSupport(H,"playbtn")||(Q='<div class="pod-entry__featured">'.concat(U[0].outerHTML).concat(D,"</div>")),H&&this.isStyleSupport(H,"excerpt")){var V=void 0;if("none"===o)N="";else if("full"===o){var q=b?jQuery("<div />",{class:"pod-entry__excerpt"}).html(b):"";N=q?q[0].outerHTML:""}else{var W=(V=l?F?F.substr(0,r):"":F?F.split(/\s+/).splice(0,r).join(" "):"")?jQuery("<div />",{class:"pod-entry__excerpt"}).html(V+T[0].outerHTML):"";N=W?W[0].outerHTML:""}}B="\n\t\t\t\t\t<div ".concat(v,' class="episode-list__entry pod-entry" data-search-term="').concat(_.toLowerCase(),'" data-cats="').concat(P.trim(),'">\n\t\t\t\t\t\t<div class="pod-entry__wrapper">\n\t\t\t\t\t\t\t').concat(Q,'\n\t\t\t\t\t\t\t<div class="pod-entry__content">\n\t\t\t\t\t\t\t\t').concat(L[0].outerHTML).concat(N).concat(I[0].outerHTML).concat(A[0].outerHTML,"\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t\t")}else this.podcast.hasClass("modern")?((B=this.episodes.find(".episode-list__entry").first().clone()).removeClass("activeEpisode media-playing"),B.attr("id",f),B.attr("data-search-term",_.toLowerCase()),B.attr("data-cats",P.trim()),B.find(".pod-entry__title").replaceWith(L),B.find(".pp-entry__mpost").attr("href",k)):((B=this.episodes.find(".episode-list__entry").first().clone()).removeClass("activeEpisode media-playing"),B.attr("id",f),B.attr("data-search-term",_.toLowerCase()),B.attr("data-cats",P.trim()),B.find(".pod-entry__title").replaceWith(L),B.find(".pod-entry__date").replaceWith(I),B.find(".pod-entry__author").replaceWith(A));d.append(jQuery(B))}}if(t){var z=this.auxList.find(".episode-list__load-more");z.parent().before(d.html()),n.maxItems&&u>=n.maxItems&&z.hide(),n.ids&&u>=n.ids.length&&z.hide()}else this.loadbtn.parent().before(d.html()),n.maxItems&&u>=n.maxItems&&this.loadbtn.hide(),n.ids&&u>=n.ids.length&&this.loadbtn.hide();if(h){var J=this.podcast.find("#"+h);J.length&&(J.find("a").first().focus(),this.podcast.hasClass("postview")&&jQuery("html, body").animate({scrollTop:J.offset().top-150},400))}t||(n.displayed=u),n.loaded-u<=n.step&&this.fetchEpisodes()}}},{key:"fetchEpisodes",value:function(){var t="pp-podcast-".concat(this.instance),e=this.data[t].rdata;"feedurl"===e.from?this.fetchFromFeed():"posts"===e.from&&this.fetchFromPosts()}},{key:"fetchMediaURL",value:function(){var t=this,e="pp-podcast-".concat(this.instance),i="ppe-".concat(this.instance,"-1"),a=this.data[e][i],n=this.data.ajax_info,o=a.src;if(0!=o.indexOf("http://")&&0!=o.indexOf("https://")){var r={action:"pp_fetch_media_url",security:n.security,src:o};
1jQuery.ajax({url:n.ajaxurl,data:r,type:"POST",timeout:4e3,success:function(e){var i=JSON.parse(e);a.src===a.link&&(a.link=i),a.src=i,s[t.id].fetched=!0,t.mediaObj.setSrc(a.src)},error:function(){a.src="#",a.link="#"}})}else s[this.id].fetched=!0}},{key:"fetchFromFeed",value:function(){var t=this,e="pp-podcast-".concat(this.instance),i=this.data[e].load_info,a=this.data.ajax_info,n=i.step;s[this.id].fetched||(n*=2);var o={action:"pp_fetch_episodes",security:a.security,instance:this.instance,loaded:i.loaded,maxItems:i.maxItems,feedUrl:i.src,step:n,sortby:i.sortby,filterby:i.filterby,args:i.args,offset:i.offset};i.loaded>=i.maxItems?i.displayed>=i.loaded&&this.loadbtn.slideUp("slow"):jQuery.ajax({url:a.ajaxurl,data:o,type:"POST",timeout:4e3,success:function(a){var n=JSON.parse(a);i.loaded=n.loaded,jQuery.extend(!0,t.data[e],n.episodes),s[t.id].fetched=!0},error:function(){t.loadbtn.hide()}})}},{key:"fetchFromPosts",value:function(){var t=this,e="pp-podcast-".concat(this.instance),i=this.data[e].load_info,a=this.data.ajax_info,n=jQuery.extend(!0,{},i.args);s[this.id].fetched||(n.number=2*n.number);var o={action:"pp_fetch_posts",security:a.security,instance:this.instance,offset:i.offset,loaded:i.loaded,args:n,ids:i.ids};i.offset&&0===i.offset||i.ids&&Array.isArray(i.ids)&&i.loaded>=i.ids.length||jQuery.ajax({url:a.ajaxurl,data:o,type:"POST",timeout:4e3,success:function(a){var n=JSON.parse(a);jQuery.isEmptyObject(n)?(i.offset=0,t.loadbtn.slideUp("slow")):(i.loaded=n.loaded,i.ids=n.ids,jQuery.extend(!0,t.data[e],n.episodes),i.offset&&(i.offset+=i.step)),s[t.id].fetched=!0},error:function(){t.loadbtn.hide()}})}}],e&&_(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();const w=j;function k(t){return k="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},k(t)}function C(t,e){for(var i=0;i<e.length;i++){var s=e[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(t,S(s.key),s)}}function O(t,e,i){return(e=S(e))in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}function S(t){var e=function(t){if("object"!=k(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,"string");if("object"!=k(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==k(e)?e:e+""}var E=function(){return t=function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),O(this,"isSrchOpen",!1),O(this,"localTimeOut",null),O(this,"serverTimeOut",null),O(this,"hasLoading",!1),O(this,"prevSearchTerm",""),this.podcast=s[e].podcast,this.instance=s[e].instance,this.isStyleSupport=s.isStyleSupport,this.data=s.podcastPlayerData,this.list=s[e].list,this.episodes=s[e].episodes,this.settings=s[e].settings,this.loadbtn=this.podcast.find(".episode-list__load-more"),this.prevBtn=this.podcast.find(".pp-prev-btn"),this.nextBtn=this.podcast.find(".pp-next-btn"),this.term=!1,this.searchBox=this.list.find(".episode-list__search input"),this.searchResults=this.list.find(".episode-search"),this.searchClose=this.list.find(".episode-list__clear-search"),this.filterDropdown=this.list.find(".episode-list__filter-select"),this.events()},e=[{key:"events",value:function(){this.searchBox.on("keyup paste",this.initSearch.bind(this)),this.searchClose.on("click",this.clearSearch.bind(this)),this.filterDropdown.on("change",this.initFilter.bind(this))}},{key:"parseResponse",value:function(t){if(t&&"object"===k(t))return t;if("string"!=typeof t)return!1;try{return JSON.parse(t)}catch(t){return!1}}},{key:"initSearch",value:function(){var t=this.searchBox.val().trim().toLowerCase();this.term!==t&&(this.term=t,!1===this.isSrchOpen&&(this.podcast.addClass("search-opened"),this.searchResults.addClass("toggled-on"),this.loadbtn.hide(),this.searchClose.show(),this.isSrchOpen=!0),clearTimeout(this.localTimeOut),this.localTimeOut=setTimeout(function(){t&&this.filterItems()}.bind(this),100),clearTimeout(this.serverTimeOut),this.serverTimeOut=setTimeout(function(){this.prevSearchTerm!==t&&this.liveSearch()}.bind(this),500))}},{key:"initFilter",value:function(){this.filterItems(),this.liveSearch()}},{key:"filterItems",value:function(){var t=this.filterDropdown.val()||"",e=this.searchBox.val().trim().toLowerCase(),i=Boolean(e&&e.length>0);this.episodes.find(".episode-list__entry").each(function(){var s=jQuery(this),a=(s.data("cats")||"").toString().split(/\s+/),n=t.length<1||a.includes(t),o=!i||(s.data("search-term")||"").toString().includes(e);n&&o?s.show():s.hide()})}},{key:"filterEpisodes",value:function(t){this.episodes.find(".episode-list__entry").each(function(){jQuery(this).data("search-term").includes(t)||t.length<1?jQuery(this).show():jQuery(this).hide()})}},{key:"liveSearch",value:function(){!1===this.isSrchOpen&&(this.podcast.addClass("search-opened"),this.searchResults.addClass("toggled-on"),this.loadbtn.hide(),this.searchClose.show(),this.isSrchOpen=!0);var t=this.filterDropdown.val()||"",e=this.searchBox.val().trim().toLowerCase();if(this.prevSearchTerm=e,this.flushSearchResults(),e.length<1&&t.length<1)this.clearSearch();else{if(!1===this.hasLoading){var i=jQuery("<div />",{class:"episode-search__loading"}).html(this.settings.ppVidLoading);this.searchResults.html(i),this.hasLoading=!0}this.fetchResults()}}},{key:"fetchResults",value:function(){var t="pp-podcast-".concat(this.instance),e=this.data[t].rdata;"feedurl"===e.from?this.fetchFromFeed():"posts"===e.from&&this.fetchFromPosts()}},{key:"fetchFromFeed",value:function(){var t=this,e=this.filterDropdown.val()||"",i=this.searchBox.val().trim().toLowerCase(),s="pp-podcast-".concat(this.instance),a=this.data[s].load_info,n=a.displayed,o=this.data.ajax_info,r=jQuery.extend({}
1,a.args);e&&e.length>0&&(r.catfilter=e,n=this.episodes.find('.episode-list__entry[data-cats~="'+e+'"]').length);var l={action:"pp_search_episodes",security:o.security,instance:"s",loaded:a.displayed,displayed:n,maxItems:a.maxItems,feedUrl:a.src,sortby:a.sortby,filterby:a.filterby,offset:a.offset,search:i,args:r};jQuery.ajax({url:o.ajaxurl,data:l,type:"POST",timeout:4e3,success:function(e){var s=t.parseResponse(e);s?jQuery.isEmptyObject(s)?(t.flushSearchResults(),t.searchAnalytics(a.src,i,[])):(t.data.search=s.episodes,t.showSearchResults(s.episodes),t.searchAnalytics(a.src,i,s.episodes)):t.flushSearchResults()},error:function(e,i,s){t.flushSearchResults(),console.log(s)}})}},{key:"fetchFromPosts",value:function(){var t=this,e=this.filterDropdown.val()||"",i=this.searchBox.val().trim().toLowerCase(),s="pp-podcast-".concat(this.instance),a=this.data[s].load_info,n=this.data.ajax_info,o=jQuery.extend({},a.args);if(e&&e.length>0){o.catfilter=e;var r=this.filterDropdown.get(0),l=jQuery(r.options[r.selectedIndex]).parent().data("attr");"cats"===l?o.filterType="cats":"tags"===l&&(o.filterType="tags")}var d={action:"pp_search_posts",security:n.security,offset:a.displayed,displayed:a.displayed,args:o,instance:"s",search:i,ids:a.ids};jQuery.ajax({url:n.ajaxurl,data:d,type:"POST",timeout:4e3,success:function(e){var a=t.parseResponse(e);if(a){var n=t.data[s]?t.data[s].rdata:{},o=n.fprint||n.podcast||s;jQuery.isEmptyObject(a)?(t.flushSearchResults(),t.searchAnalytics(o,i,[])):(t.data.search=a.episodes,t.showSearchResults(a.episodes),t.searchAnalytics(o,i,a.episodes))}else t.flushSearchResults()},error:function(){t.flushSearchResults()}})}},{key:"clearSearch",value:function(){var t="pp-podcast-".concat(this.instance),e=this.data[t].load_info;this.searchBox.val(""),this.filterDropdown.val(""),this.prevSearchTerm="",this.isSrchOpen=!1,this.term=!1,this.podcast.removeClass("search-opened"),this.searchResults.removeClass("toggled-on"),this.searchClose.hide(),this.episodes.find(".episode-list__entry").show(),this.flushSearchResults(),e.displayed<e.loaded&&(this.loadbtn.show(),this.nextBtn.attr("disabled",!1))}},{key:"flushSearchResults",value:function(){this.searchResults.empty(),this.list.find(".episode-list__search-entry").remove(),this.hasLoading=!1}},{key:"showSearchResults",value:function(t){var e="pp-podcast-".concat(this.instance),i=this.data[e].rdata.from,s=this.data[e].load_info,a=Object.getOwnPropertyNames(t),n=a.length-1,o=this.data[e].rdata.teaser,r=this.data[e].rdata.elen,l=this.data[e].rdata.eunit,d=0,p=jQuery("<div />"),c="fetch-feed-title";for("posts"===i&&(c="fetch-post-title");d<=n;d++){var h=a[d],u=t[h],m=u.title,y=u.description,f=u.author,v=u.date,g=u.link,_=u.featured;_||(_=(_=s.args.imgurl)||"");var b=jQuery("<a />",{href:g,class:c}).html(m),j=jQuery("<a />",{href:g,class:c}).html("[...]"),w=jQuery("<div />",{class:"pod-entry__title"}).html(b),k=jQuery("<div />",{class:"pod-entry__date"}).text(v),C=jQuery("<div />",{class:"pod-entry__author"}).html(f),O=void 0;if(this.podcast.hasClass("postview")){var S=s.args.display,E=y?jQuery(y).text():"",M=jQuery("<div />",{class:"pod-entry__play"}).html(this.settings.ppPlayCircle+this.settings.ppPauseBtn),P=void 0,x="";if(P=S&&this.isStyleSupport(S,"playbtn")?"":(P=_?jQuery("<img />",{class:"pod-entry__image",src:_,alt:m}):"")?'<div class="pod-entry__thumb">'.concat(P[0].outerHTML,"</div>"):"",S&&this.isStyleSupport(S,"excerpt")){var T=void 0;if("none"===o)x="";else if("full"===o){var L=y?jQuery("<div />",{class:"pod-entry__excerpt"}).html(jQuery(y).html()):"";x=L?L[0].outerHTML:""}else{var I=(T=l?E?E.substr(0,r):"":E?E.split(/\s+/).splice(0,r).join(" "):"")?jQuery("<div />",{class:"pod-entry__excerpt"}).html(T+j[0].outerHTML):"";x=I?I[0].outerHTML:""}}O='\n\t\t\t\t<div id="'.concat(h,'" class="episode-list__search-entry pod-entry" data-search-term="').concat(m.toLowerCase(),'">\n\t\t\t\t\t<div class="pod-entry__wrapper">\n\t\t\t\t\t\t<div class="pod-entry__featured">\n\t\t\t\t\t\t\t').concat(M[0].outerHTML,"\n\t\t\t\t\t\t\t").concat(P,'\n\t\t\t\t\t\t</div>
1\n\t\t\t\t\t\t<div class="pod-entry__content">\n\t\t\t\t\t\t\t').concat(w[0].outerHTML).concat(x).concat(k[0].outerHTML).concat(C[0].outerHTML,"\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t\t")}else this.podcast.hasClass("modern")?((O=this.episodes.find(".episode-list__entry").first().clone()).removeClass("activeEpisode media-playing episode-list__entry"),O.addClass("episode-list__search-entry"),O.attr("id",h),O.attr("data-search-term",m.toLowerCase()),O.find(".pod-entry__title").replaceWith(w),O.find(".pp-entry__mpost").attr("href",g),O.css("display","block")):((O=this.episodes.find(".episode-list__entry").first().clone()).removeClass("activeEpisode media-playing episode-list__entry"),O.addClass("episode-list__search-entry"),O.attr("id",h),O.attr("data-search-term",m.toLowerCase()),O.find(".pod-entry__title").replaceWith(w),O.find(".pod-entry__date").replaceWith(k),O.find(".pod-entry__author").replaceWith(C),O.css("display","block"));p.append(jQuery(O))}var A=p.find(".episode-list__search-entry");A.length&&A.insertAfter(this.list.find(".pod-entry").last()),this.searchResults.empty(),this.hasLoading=!1}},{key:"searchAnalytics",value:function(t,e,i){window.PP_Hooks&&"function"==typeof window.PP_Hooks.doAction&&window.PP_Hooks.doAction("podcast_player_analytics_search",this,t,e,i)}}],e&&C(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();const M=E;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},P(t)}function x(t,e){for(var i=0;i<e.length;i++){var s=e[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(t,L(s.key),s)}}function T(t,e,i){return(e=L(e))in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}function L(t){var e=function(t){if("object"!=P(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,"string");if("object"!=P(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==P(e)?e:e+""}const I=function(){return t=function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),T(this,"width",void 0),T(this,"resizeTimeout",null),this.id=e,this.playerStyleUpdate(),this.managerHeader(),this.mediaElements(),this.entryEpisodes(),this.loadMore(),this.searchEpisodes(),this.events()},(e=[{key:"events",value:function(){var t=this;clearTimeout(this.resizeTimeout),jQuery(window).on("resize",function(){t.resizeTimeout=setTimeout(t.playerStyleUpdate.bind(t),100)})}},{key:"playerStyleUpdate",value:function(){var t=s[this.id].podcast,e=t.width(),i=this.getWidthClass(e);s.isLrgScrn=!window.matchMedia("(max-width: 640px)").matches,s[this.id].isWide=e>720,t.removeClass("wider-player wide-player narrow-player medium-player").addClass(i)}},{key:"getWidthClass",value:function(t){return t>720?"wider-player medium-player wide-player":t>640?"medium-player wide-player":t>450?"wide-player":t>280?"narrow-player":""}},{key:"managerHeader",value:function(){new r(this.id)}},{key:"mediaElements",value:function(){new c(this.id)}},{key:"entryEpisodes",value:function(){new v(this.id)}},{key:"loadMore",value:function(){s[this.id].loadMore=new w(this.id)}},{key:"searchEpisodes",value:function(){new M(this.id)}}])&&x(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function A(t){return A="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},A(t)}function Q(t,e){for(var i=0;i<e.length;i++){var s=e[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(t,B(s.key),s)}}function B(t){var e=function(t){if("object"!=A(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,"string");if("object"!=A(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==A(e)?e:e+""}const H=function(){return t=function t(){var e,i,s;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),e=this,s=void 0,(i=B(i="modal"))in e?Object.defineProperty(e,i,{value:s,enumerable:!0,configurable:!0,writable:!0}):e[i]=s,this.settings=window.ppmejsSettings||{},this.mediaObj=!1,this.msgMediaObj=!1,this.bodyScrollDisabled=!1,this.scrollPosition=0,this.scrollingElem=document.scrollingElement||document.documentElement||document.body,this.setup(),this.events(),this.pauseMedia=this.mediaPause.bind(this),this.playMedia=this.mediaPlay.bind(this)},e=[{key:"setup",value:function(){var t=this.settings,e=t.ppClose,i=t.ppArrowUp,s=t.ppCloseBtnText,a=t.ppAuxModal,n=t.ppThumbsUp,o=t.ppThumbsDown,r=jQuery("<button />",{class:"pp-modal-close"}).html(s+i+e),l=jQuery("<button />",{class:"pp-caption-close"}).html(e),d=jQuery("<button />",{class:"pp-thumbs-up"}).html(n),p=jQuery("<button />",{class:"pp-thumbs-down"}).html(o),c=jQuery("<button />",{class:"pp-fback-close"}
1).html(e),h='\n\t\t<div id="pp-modal-window" class="pp-modal-window">\n\t\t\t<div id="pp-closed-captions" class="pp-closed-captions">\n\t\t\t\t<div class="pp-caption-text"></div>\n\t\t\t\t'.concat(l[0].outerHTML,'\n\t\t\t</div>\n\t\t\t<div id="pp-user-feedback" class="pp-user-feedback">\n\t\t\t\t<div class="pp-user-feedback-initial">\n\t\t\t\t\t<div class="pp-user-feedback-message"></div>\n\t\t\t\t\t<div class="pp-user-feedback-buttons">').concat(d[0].outerHTML).concat(p[0].outerHTML,'</div>\n\t\t\t\t</div>\n\t\t\t\t<div class="pp-user-feedback-response"></div>\n\t\t\t\t').concat(c[0].outerHTML,'\n\t\t\t</div>\n\t\t\t<div class="pp-modal-container"><div class="pp-modal-wrapper"></div>').concat(r[0].outerHTML,"</div>\n\t\t\t").concat(a,"\n\t\t</div>");jQuery("body").append(h),this.modal=jQuery("#pp-modal-window")}},{key:"events",value:function(){var t=this,e=t.modal.find(".pp-modal-wrapper"),i=t.modal.find(".pp-modal-aux-wrapper"),s=i.find(".pp-modal-tabs-list"),a=i.find(".pp-modal-tabs-content");this.modal.on("click",".pp-modal-close",function(){var n=jQuery(this);t.modal.hasClass("modal-view")?t.mediaObj.isVideo?t.modalClose():(t.modal.removeClass("modal-view").addClass("inline-view"),t.scrollEnable()):(n.hasClass("modal-closed")?(n.removeClass("modal-closed"),e.animate({height:"toggle"},400)):(n.addClass("modal-closed"),e.animate({height:"toggle"},400)),i.hasClass("aux-open")&&(t.modal.find(".ppjs__secondary-controls").find(".toggled").removeClass("toggled"),i.find(".selected").removeClass("selected"),s.hide(),a.empty(),i.hide().removeClass("aux-open")))}),this.modal.on("click",".pp-text-aux-btn",function(){var t=jQuery(this);if(t.hasClass("toggled"))t.removeClass("toggled"),s.hide(),i.find(".selected").removeClass("selected"),a.empty(),i.animate({height:"toggle"},200).removeClass("aux-open");else{var n=e.find(".episode-single__wrapper").html();t.addClass("toggled"),s.hide(),i.find(".selected").removeClass("selected"),i.find(".content-tab").addClass("selected"),a.empty().html(n).show(),i.addClass("aux-open").animate({height:"toggle"},200)}}),this.modal.on("click",".pp-modal-tabs-item",function(){var t=jQuery(this);if(!t.hasClass("selected"))if(t.parent().find(".selected").removeClass("selected"),t.addClass("selected"),t.hasClass("lists-tab")){var e=s.find(".activeEpisode");a.hide(),s.fadeIn(),e.length&&i.animate({scrollTop:i.scrollTop()+e.position().top},400)}else t.hasClass("content-tab")&&(s.hide(),a.fadeIn())}),jQuery(document).on("keyup",function(e){"Escape"===e.key&&(t.modal.hasClass("media-paused")?t.modalClose():t.modal.hasClass("modal-view")&&!t.mediaObj.isVideo&&(t.modal.removeClass("modal-view").addClass("inline-view"),t.scrollEnable()))}),this.modal.on("click",function(e){var i=jQuery(e.target);t.modal.hasClass("modal-view")&&(i.closest(".pp-modal-wrapper").length||i.closest(".pp-modal-close").length||(t.modal.hasClass("media-paused")||t.mediaObj.isVideo?t.modalClose():(t.modal.removeClass("modal-view").addClass("inline-view"),t.scrollEnable())))})}},{key:"create",value:function(t,e,i,s,a){var n,o=jQuery("<div />",{id:"pp-modal-placeholder"}),r=this.modal.find(".pp-modal-wrapper"),l=t.closest(".pp-podcast"),d=l.attr("id").replace("pp-podcast-",""),p=this.modal.find(".pp-modal-aux-wrapper"),c=p.find(".pp-modal-tabs-list"),h=this;if(a=void 0===a||a,l.is(".single-audio, .hide-content")||((n=l.find(".pod-content__list").clone()).find(".pod-entry").each(function(){var t=jQuery(this);t.show().attr("data-pid",t.attr("id")).removeAttr("id").removeClass("media-playing activeEpisode")}),n.find(".episode-list__load-more").show(),n.find(".episode-list__search-results").hide(),c.empty().append(n).addClass("lv3 postview"),c.find(".episode-list__filters").hide()),l.hasClass("modern")){var u=l.find(".ppjs__time");l.find(".ppjs__audio-timer").append(u)}if(p.addClass("aux-modal-"+d),o.insertBefore(t),!l.hasClass("postview")){var m=jQuery("<div />",{class:"episode-search__loading"}).html(this.settings.ppVidLoading);o.height(t.height()).html(m)}r.empty().append(t),r.children().wrapAll('<div class="modal-'+d+'">'),s?(this.modal.addClass("modal-view pp-modal-open"),this.scrollDisable()):this.modal.addClass("inline-view pp-modal-open"),jQuery.each(["light-accent","light-color","hide-share","hide-download","hide-social","single-episode","single-audio","modern"],function(t,e){l.hasClass(e)&&h.modal.addClass(e)}),this.mediaObj&&a&&this.mediaObj.media.pause(),this.mediaObj=e,this.msgMediaObj=i,this.mediaObj.media.addEventListener("ended",this.pauseMedia),this.mediaObj.media.addEventListener("pause",this.pauseMedia),this.mediaObj.media.addEventListener("play",this.playMedia),this.mediaObj.media.addEventListener("playing",this.playMedia),this.msgMediaObj&&(this.msgMediaObj.media.addEventListener("ended",this.pauseMedia),this.msgMediaObj.media.addEventListener("pause",this.pauseMedia),this.msgMediaObj.media.addEventListener("play",this.playMedia),this.msgMediaObj.media.addEventListener("playing",this.playMedia))}},{key:"mediaPause",value:function(){this.modal.addClass("media-paused"),jQuery("#pp-modal-placeholder").parent().find(".activeEpisode").removeClass("media-playing")}},{key:"mediaPlay",value:function(){this.modal.removeClass("media-paused"),jQuery("#pp-modal-placeholder").parent().find(".activeEpisode").addClass("media-playing")}},{key:"modalClose",value:function(){this.returnElem(),this.modal.removeClass().addClass("pp-modal-window"),this.scrollEnable(),this.mediaObj&&(this.mediaObj.media.pause(),this.mediaObj=!1),this.msgMediaObj&&(this.msgMediaObj.media.pause(),this.msgMediaObj.media.currentTime=0,this.msgMediaObj=!1)}},{key:"returnElem",value:function(){var t=this.modal.find(".pp-modal-wrapper"),e=this.modal.find(".pp-modal-aux-wrapper"),i=t.find(".pp-podcast__single"),s=jQuery("#pp-modal-placeholder"),a=this.modal.find(".pp-modal-close");if(this.mediaObj.media.removeEventListener("ended",this.pauseMedia),this.mediaObj.media.removeEventListener("pause",this.pauseMedia),this.mediaObj.media.removeEventListener("play",this.pauseMedia),this.mediaObj.media.removeEventListener("playing",this.pauseMedia),this.msgMediaObj&&(this.msgMediaObj.media.removeEventListener("ended",this.pauseMedia),this.msgMediaObj.media.removeEventListener("pause",this.pauseMedia),this.msgMediaObj.media.removeEventListener("play",this.playMedia),this.msgMediaObj.media.removeEventListener("playing",this.playMedia)),e.length&&e.hasClass("aux-open")&&(e.removeClass("aux-open").hide(),this.modal.find(".ppjs__secondary-controls").find(".toggled").removeClass("toggled")),e.removeClass().addClass("pp-modal-aux-wrapper"),this.modal.hasClass("modern")){var n=this.modal.find(".ppjs__time");this.modal.find(".ppjs__atime-container").append(n)}i.length&&(i.removeClass("activePodcast"),s.length&&i.insertAfter(s)),s.length&&(s.parent().find(".activeEpisode").removeClass("activeEpisode media-playing"),s.remove()),a.removeClass("modal-closed"),this.modal.removeClass().addClass("pp-modal-window"),t.empty().removeAttr("style")}},{key:"scrollDisable",value:function(){var t=this;this.bodyScrollDisabled||(this.scrollPosition=this.scrollingElem.scrollTop,this.bodyScrollDisabled=!0,setTimeout(function(){t.scrollingElem.scrollTop=0,t.scrollingElem.classList.add("no-scroll")},250))}},{key:"scrollEnable",value:function(){this.bodyScrollDisabled&&(this.scrollingElem.classList.remove("no-scroll"),this.scrollingElem.scrollTop=this.scrollPosition,this.bodyScrollDisabled=!1)}}],e&&Q(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();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},R(t)}function F(t,e){for(var i=0;i<e.length;i++){var s=e[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(t,U(s.key),s)}}function U(t){var e=function(t){if("object"!=R(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,"string");if("object"!=R(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==R(e)?e:e+""}var D=function(){return t=function t(e){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.elements="string"==typeof e?this.get(e,i):[e]},e=[{key:"template",value:function(t,e){return t.replace(/\{\{(\w+)\}\}/g,function(t,i){return e[i]||""})}},{key:"strToHTML",value:function(t){var e=document.createElement("div");return e.innerHTML=t,e.firstElementChild}}],null&&F(t.prototype,null),e&&F(t,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}(),N=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;return new D(t,e)};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},V(t)}function q(t,e){for(var i=0;i<e.length;i++){var s=e[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(t,z(s.key),s)}}function W(t,e,i){return(e=z(e))in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}function z(t){var e=function(t){if("object"!=V(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,"string");if("object"!=V(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==V(e)?e:e+""}
1Object.getOwnPropertyNames(D).forEach(function(t){"function"==typeof D[t]&&"prototype"!==t&&(N[t]=D[t])});var J=function(){function t(e){if(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),W(this,"id",null),W(this,"wrapper",null),W(this,"media",null),W(this,"controls",null),W(this,"container",null),W(this,"layers",null),W(this,"hls",null),W(this,"sourceUrl",""),W(this,"sourceReady",Promise.resolve()),W(this,"isVideo",!1),this.id=e,this.media=document.querySelector("#".concat(e)),!this.media||!this.isValidMediaElement(this.media))return!1;this.wrapper=this.media.parentElement,this.isVideo="VIDEO"===this.media.tagName,this.createPlayerMarkup(),this.attachEvents()}return e=t,i=[{key:"isValidMediaElement",value:function(t){return"AUDIO"===t.tagName||"VIDEO"===t.tagName||"MEDIAELEMENTWRAPPER"===t.tagName&&(this.removeMeJs(),this.media=document.querySelector("#".concat(this.id)),!!this.media&&("AUDIO"===this.media.tagName||"VIDEO"===this.media.tagName))}},{key:"attachEvents",value:function(){var e=this,i=this.controls.querySelector(".ppjs__seek-slider"),s=this.controls.querySelector(".ppjs__currenttime"),a=this.controls.querySelector(".ppjs__fullscreen-button > button");if(i&&s){var n=function(){return e.toggleLoading(!1)};this.media.readyState>0?(this.displayDuration(),this.setSliderMax()):this.media.addEventListener("loadedmetadata",function(){e.displayDuration(),e.setSliderMax()}),i.addEventListener("input",function(){e.media.readyState>0&&(s.textContent=e.formatTime(i.value))}),i.addEventListener("change",function(){e.media.readyState>0&&(e.media.currentTime=i.value)}),this.media.addEventListener("play",function(){t.currentlyPlayingInstance&&t.currentlyPlayingInstance!==e&&t.currentlyPlayingInstance.media.pause(),t.currentlyPlayingInstance=e}),this.media.addEventListener("timeupdate",function(){var t=e.media,a=t.duration,n=t.currentTime,o=t.buffered;if(a&&!isNaN(a)){var r=n/a*100;if(i.value=Math.floor(n),s.textContent=e.formatTime(n),i.style.setProperty("--pp-progress-value","".concat(r,"%")),a>0&&o.length){var l=o.end(o.length-1)/a*100;i.style.setProperty("--buffered-width","".concat(l,"%"))}}}),this.media.addEventListener("loadedmetadata",n),this.media.addEventListener("canplay",n),this.media.addEventListener("waiting",function(){return e.toggleLoading(!0)}),this.isVideo&&(this.media.addEventListener("play",function(){return e.updateVideoLayers()}),this.media.addEventListener("pause",function(){return e.updateVideoLayers()}),this.media.addEventListener("ended",function(){return e.updateVideoLayers()}),this.media.addEventListener("timeupdate",function(){return e.updateVideoLayers()}),document.addEventListener("fullscreenchange",function(){return e.updateFullscreenState()}),document.addEventListener("webkitfullscreenchange",function(){return e.updateFullscreenState()}),a&&a.addEventListener("click",this.toggleFullscreen.bind(this)),this.updateVideoLayers())}}},{key:"createPlayerMarkup",value:function(){var t=N.template(this.isVideo?'\n    <div class="ppjs__offscreen">Video Player</div>\n    <div id="{{id}}-html5" class="ppjs__container pp-podcast-episode ppjs__video">\n        <div class="ppjs__inner">\n            <div class="ppjs__mediaelement"></div>\n            <div class="ppjs__layers">\n                <div class="ppjs__poster ppjs__layer"></div>\n                <div class="ppjs__overlay ppjs__layer ppjs__overlay-play">\n                    <div class="ppjs__overlay-button"></div>\n                </div>\n                <div class="ppjs__overlay ppjs__layer ppjs__overlay-loading-layer" style="display: none;">\n                    <div class="ppjs__overlay-loading"></div>\n                </div>\n            </div>\n            <div class="ppjs__controls">\n                <div class="ppjs__time ppjs__currenttime-container" role="timer" aria-live="off"><span class="ppjs__currenttime">00:00</span></div>\n                <div class="ppjs__time-rail"><input type="range" class="ppjs__seek-slider" max="100" value="0"></div>\n                <div class="ppjs__time ppjs__duration-container"><span class="ppjs__duration">00:00</span></div>\n                <div class="ppjs__button ppjs__fullscreen-button">\n                    <button type="button"><span class="ppjs__offscreen">Fullscreen</span></button>\n                </div>\n            </div>\n        </div>\n    </div>\n    ':'\n    <div class="ppjs__offscreen">Audio Player</div>\n    <div id="{{id}}-html5" class="ppjs__container pp-podcast-episode ppjs__audio">\n        <div class="ppjs__inner">\n            <div class="ppjs__mediaelement"></div>\n            <div class="ppjs__controls">\n                <div class="ppjs__time ppjs__currenttime-container" role="timer" aria-live="off"><span class="ppjs__currenttime">00:00</span></div>\n                <div class="ppjs__time ppjs__duration-container"><span class="ppjs__duration">00:00</span></div>\n                <div class="ppjs__audio-time-rail">
1<input type="range" class="ppjs__seek-slider" max="100" value="0"></div>\n            </div>\n        </div>\n    </div>\n    ',{id:this.id});this.wrapper.insertAdjacentHTML("beforeend",t),this.container=this.wrapper.querySelector("#".concat(this.id,"-html5")),this.layers=this.wrapper.querySelector(".ppjs__layers");var e=this.wrapper.querySelector(".ppjs__mediaelement");this.media.controls=!1,e.appendChild(this.media),this.controls=this.wrapper.querySelector(".ppjs__controls");var i=this.getSourceElementUrl(),s=this.getSourceElementType();i&&this.setSrc(i,{mimeType:s}),this.isVideo&&(this.setAspectRatio(),this.setPoster(this.media.getAttribute("poster")))}},{key:"setSrc",value:function(t){var e=this,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.destroyHls(),this.clearSourceElements(),this.sourceUrl=t;var s=i.mimeType||"";this.isHlsSource(t,s)&&!this.canPlayHlsNatively(s)?this.sourceReady=this.loadHlsLibrary().then(function(){t===e.sourceUrl&&(window.Hls&&window.Hls.isSupported()?e.attachHlsSource(t):(e.media.src=t,e.media.load()))}).catch(function(){t===e.sourceUrl&&(e.media.src=t,e.media.load())}):(this.media.src=t,this.sourceReady=Promise.resolve()),this.resetControls(),this.updateVideoLayers()}},{key:"getSrc",value:function(){return this.sourceUrl||this.media.src}},{key:"load",value:function(){var t=this;return this.hls?this.sourceReady:this.sourceReady.then(function(){t.hls||t.media.load()})}},{key:"play",value:function(){var t=this;return this.sourceReady.then(function(){return t.media.play()})}},{key:"attachHlsSource",value:function(t){this.hls=new window.Hls({capLevelToPlayerSize:this.isVideo,enableWorker:!0}),this.hls.attachMedia(this.media),this.hls.loadSource(t),this.attachHlsErrorHandler()}},{key:"loadHlsLibrary",value:function(){if(window.Hls)return Promise.resolve();if(t.hlsLoading)return t.hlsLoading;var e=(window.ppmejsSettings||{}).hlsSrc||"";return e?(t.hlsLoading=new Promise(function(t,i){var s=document.querySelector("script[data-podcast-player-hls]");if(s)return s.addEventListener("load",function(){return t()}),void s.addEventListener("error",i);var a=document.createElement("script");a.src=e,a.async=!0,a.dataset.podcastPlayerHls="1",a.onload=function(){return t()},a.onerror=i,document.head.appendChild(a)}),t.hlsLoading):Promise.reject(new Error("HLS script URL is not available."))}},{key:"getSourceElementUrl",value:function(){var t=this.media.querySelector("source");return t?t.getAttribute("src"):this.media.getAttribute("src")}},{key:"getSourceElementType",value:function(){var t=this.media.querySelector("source");return t?t.getAttribute("type"):""}},{key:"clearSourceElements",value:function(){this.media.querySelectorAll("source").forEach(function(t){return t.remove()}),this.media.removeAttribute("src"),this.media.load()}},{key:"isHlsSource",value:function(t){var e=String((arguments.length>1&&void 0!==arguments[1]?arguments[1]:"")||"").toLowerCase();return!!["application/x-mpegurl","application/vnd.apple.mpegurl","audio/x-mpegurl","audio/mpegurl","video/x-mpegurl","video/mpegurl"].includes(e)||String(t||"").split("?")[0].toLowerCase().endsWith(".m3u8")}},{key:"canPlayHlsNatively",value:function(){var t=this;return[arguments.length>0&&void 0!==arguments[0]?arguments[0]:"","application/vnd.apple.mpegurl","application/x-mpegurl"].filter(Boolean).some(function(e){return""!==t.media.canPlayType(e)})}},{key:"attachHlsErrorHandler",value:function(){var t=this;this.hls&&window.Hls&&window.Hls.Events&&this.hls.on(window.Hls.Events.ERROR,function(e,i){i&&i.fatal&&(i.type===window.Hls.ErrorTypes.MEDIA_ERROR?t.hls.recoverMediaError():t.destroyHls())})}},{key:"destroyHls",value:function(){this.hls&&"function"==typeof this.hls.destroy&&this.hls.destroy(),this.hls=null}},{key:"setPoster",value:function(t){if(this.isVideo){var e=t||"",i=!!this.layers&&this.layers.querySelector(".ppjs__poster");if(e){if(this.media.setAttribute("poster",e),i){i.innerHTML="";var s=document.createElement("img");s.src=e,s.alt="",i.appendChild(s)}}else this.media.removeAttribute("poster"),i&&(i.innerHTML="");this.updateVideoLayers()}}},{key:"formatTime",value:function(t){if(!t||isNaN(t))return"00:00";var e=Math.floor(t/3600),i=Math.floor(t%3600/60),s=Math.floor(t%60);return(e?"".concat(e,":"):"")+String(i).padStart(2,"0")+":"+String(s).padStart(2,"0")}},{key:"displayDuration",value:function(){var t=this.controls.querySelector(".ppjs__duration");t&&(t.textContent=this.formatTime(this.media.duration))}},{key:"setSliderMax",value:function(){var t=this.media.duration;isNaN(t)||(this.controls.querySelector(".ppjs__seek-slider").max=Math.floor(t))}},{key:"resetControls",value:function(){if(this.controls){var t=this.controls.querySelector(".ppjs__seek-slider"),e=this.controls.querySelector(".ppjs__currenttime"),i=this.controls.querySelector(".ppjs__duration");t&&(t.value=0,t.style.setProperty("--pp-progress-value","0%"),t.style.setProperty("--buffered-width","0%")),e&&(e.textContent="00:00"),i&&(i.textContent="00:00")}}},{key:"setAspectRatio",value:function(){if(this.container){var t=parseInt(this.media.getAttribute("width"),10),e=parseInt(this.media.getAttribute("height"),10);t>0&&e>0&&(this.container.style.aspectRatio="".concat(t," / ").concat(e))}}},{key:"toggleLoading",value:function(t){if(this.layers){var e=this.layers.querySelector(".ppjs__overlay-loading-layer");e&&(e.style.display=t?"":"none")}}},{key:"updateVideoLayers",value:function(){if(this.isVideo&&this.layers){var t=this.media.paused&&(0===this.media.currentTime||this.media.ended||0===this.media.readyState),e=this.layers.querySelector(".ppjs__poster"),i=this.layers.querySelector(".ppjs__overlay-play"),s=this.layers.querySelector(".ppjs__overlay-button");this.layers.style.display="",e&&(e.style.display=t&&e.children.length?"":"none"),i&&(i.style.backgroundColor=this.media.paused?"rgba(0, 0, 0, 0.2)":"transparent"),s&&(s.style.display=this.media.paused?"":"none")}}},{key:"toggleFullscreen",value:function(){this.container&&(this.isFullscreen()?this.exitFullscreen():this.enterFullscreen())}},{key:"enterFullscreen",value:function(){var t=this.container,e=t.requestFullscreen||t.webkitRequestFullscreen||t.mozRequestFullScreen||t.msRequestFullscreen;if(e){var i=e.call(t);i&&i.catch&&i.catch(function(){})}else this.media.webkitEnterFullscreen&&this.media.webkitEnterFullscreen()}},{key:"exitFullscreen",value:function(){var t=document.exitFullscreen||document.webkitExitFullscreen||document.mozCancelFullScreen||document.msExitFullscreen;if(t){var e=t.call(document);e&&e.catch&&e.catch(function(){})}}},{key:"isFullscreen",value:function(){return(document.fullscreenElement||document.webkitFullscreenElement||document.mozFullScreenElement||document.msFullscreenElement)===this.container}}
1,{key:"updateFullscreenState",value:function(){if(this.container&&this.controls){var t=this.isFullscreen(),e=this.controls.querySelector(".ppjs__fullscreen-button");this.container.classList.toggle("ppjs__container-fullscreen",t),e&&e.classList.toggle("ppjs__unfullscreen",t)}}},{key:"removeMeJs",value:function(){var t,e=this.media.closest(".mejs__container");e&&e.id&&null!==(t=window.mejs)&&void 0!==t&&null!==(t=t.players)&&void 0!==t&&null!==(t=t[e.id])&&void 0!==t&&t.remove&&window.mejs.players[e.id].remove()}}],i&&q(e.prototype,i),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,i}();W(J,"currentlyPlayingInstance",null),W(J,"hlsLoading",null);const G=J;!function(t){var e=t(".pp-podcast"),i=t(".pp-social-shared").first(),a=window.ppmejsSettings||{},n=a.isPremium?new H:"";function o(e){var i=t(e.target);i.hasClass("pp-podcast")&&!i.hasClass("pp-podcast-added")&&r(i)}function r(t){if(!t.hasClass("pp-podcast-added")){var e=t.attr("id");if(!t.parents(".pp-podcast").length){t.find(".pp-podcast").remove();var i=new G(e+"-player");if(i){var o=t.find(".pod-content__list"),r=t.find(".pod-content__episode"),l=o.find(".episode-list__wrapper"),d=r.find(".episode-single__wrapper"),p=t.find(".pp-podcast__single").first(),c=t.find(".pp-podcast__player"),h=t.find(".pp-player__amsg"),u=!!h.length&&new G(e+"-amsg-player");if(void 0===s.podcastPlayerData[e]){var m=t.data("ppsdata");if(!m)return;s.podcastPlayerData[e]=m}var y=e.replace("pp-podcast-","");s[e]={podcast:t,mediaObj:i,settings:a,list:o,episode:r,msgMediaObj:u,amsg:h,episodes:l,single:d,player:c,modal:n,singleWrap:p,fetched:!1,instance:y},t.addClass("pp-podcast-added"),new I(e)}}}}e.each(function(){r(t(this))}),document.addEventListener("animationstart",o,!1),document.addEventListener("MSAnimationStart",o,!1),document.addEventListener("webkitAnimationStart",o,!1),i.length&&t("html, body").animate({scrollTop:i.offset().top-200},400),a.isPremium&&a.isSticky&&t(window).on("scroll",s.stickyonScroll.bind(s)),window.podcastPlayerPlay=function(){G&&G.currentlyPlayingInstance&&G.currentlyPlayingInstance.media.play()},window.podcastPlayerPause=function(){G&&G.currentlyPlayingInstance&&G.currentlyPlayingInstance.media.pause()}}(jQuery)})();

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.