1/*! Thrive Architect - 2021-12-06 2* http://www.thrivethemes.com/ 3* Copyright (c) 2021 Thrive Themes */ 4 5"use strict";function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _defineProperties(t,e){for(var o=0;o<e.length;o++){var n=e[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function _createClass(t,e,o){return e&&_defineProperties(t.prototype,e),o&&_defineProperties(t,o),t}function _typeof(t){return(_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}!function(c){var f,v,a,p,y,i={".js":[],".json":[],".css":[],".html":[]},l="function"==typeof require?require:null;return p=function(t){var e=new Error("Could not find module '"+t+"'");return e.code="MODULE_NOT_FOUND",e},y=function(t,e,o){var n,a;if("function"==typeof t[e+o])return e+o;for(n=0;a=i[o][n];++n)if("function"==typeof t[e+a])return e+a;return null},f=function(t,e,o,n,a,i){var r,s,c,l,d,u;for("."!==(r=(o=o.split("/")).pop())&&".."!==r||(o.push(r),r="");null!=(s=o.shift());)if(s&&"."!==s&&(".."===s?(t=e.pop(),i=i.slice(0,i.lastIndexOf("/"))):(e.push(t),t=t[s],i+="/"+s),!t))throw p(n);if(r&&"function"!=typeof t[r]&&((u=(u=(u=(u=y(t,r,".js"))||y(t,r,".json"))||y(t,r,".css"))||y(t,r,".html"))?r=u:2!==a&&"object"===_typeof(t[r])&&(e.push(t),t=t[r],i+="/"+r,r="")),!r)return 1!==a&&t[":mainpath:"]?f(t,e,t[":mainpath:"],n,1,i):f(t,e,"index",n,2,i);if(!(d=t[r]))throw p(n);return d.hasOwnProperty("module")?d.module.exports:(c={},d.module=l={exports:c,id:i+"/"+r},d.call(c,c,l,v(t,e,i)),l.exports)},a=function(t,e,o,n){var a,i=o,r=o.charAt(0),s=0;if("/"===r){if(i=i.slice(1),!(t=c["/"])){if(l)return l(o);throw p(o)}n="/",e=[]}else if("."!==r){if(a=i.split("/",1)[0],!(t=c[a])){if(l)return l(o);throw p(o)}n=a,e=[],(i=i.slice(a.length+1))||(s=(i=t[":mainpath:"])?1:(i="index",2))}return f(t,e,i,o,s,n)},(v=function(e,o,n){return function(t){return a(e,[].concat(o),t,n)}})(c,[],"")}({workspace:{editor:{js:{frontend:{modules:{video:{
5"floating.js":function(t,e,o){function y(t,e){var o=e?t.parents(".safari-ios-decoration-fix"):t.parents(".safari-ios-decoration-fix-none");t.toggleClass("tcb-no-perspective",e),o.toggleClass("safari-ios-decoration-fix",!e).toggleClass("safari-ios-decoration-fix-none",e)}var h,n,a,b;h=ThriveGlobal.$j,b=!(a={}),a.init=function(){var o=this;n=a.videoScrolled.bind(this),document.addEventListener("scroll",n),h(".tcb-float-close-button").each(function(t,e){e.addEventListener("click",a.closeFloatVideo.bind(o,e),!1)})},a.destroyFloating=function(){var o=this;document.removeEventListener("scroll",n),h(".tcb-float-close-button").each(function(t,e){e.removeEventListener("click",a.closeFloatVideo.bind(o,e))})},a.closeFloatVideo=function(t){h(t).parent(".tcb-video-float-container").addClass("tcb-float-closed"),a.videoScrolled()},a.videoScrolled=function(){h('.thrv_responsive_video[data-float="true"] .tcb-video-float-container iframe, .thrv_responsive_video[data-float="true"] .tcb-video-float-container video, .thrv_responsive_video[data-float="true"] .tcb-video-float-container .tve_responsive_video-no_video').each(function(t,e){var o=h(e),n=o.parents(".tcb-video-float-container"),a=o.parents(".thrv_responsive_video"),i=a.attr("data-float-position"),r=a.find(".video_overlay_image").attr("style")||"",s=TCB_Front.getDisplayType()[0],c=parseInt(h("#wpadminbar").height());if(n.hasClass("tcb-float-closed")||!function(t){var e="true"===t.attr("data-float"),o=t.attr("data-float-visibility"),n=TCB_Front.getDisplayType();return!t.parents(".tcb-post-list").length&&(e&&!o||-1===o.indexOf(n))}(a)||TCB_Front.isInViewport(o.parents(".thrv_responsive_video"),parseInt(o.width))){if(n.removeClass(i).css({width:"",height:"","margin-top":""}).parents(".tcb-col,.thrv-content-box,.thrv-page-section,#content,.theme-section").css("z-index",""),a.find(".video_overlay_image").removeClass(i).css({cssText:r,height:"",width:""}),!b){var l=a.position().left,d={left:l,right:l+a.width()};i.includes("top")||i.includes("keep")?(d.top=-parseInt(a.attr("data-float-width-".concat(s))),n.css(d)):i.includes("bottom")&&(d.bottom=parseInt(TCB_Front.Utils.windowWidth()),n.css(d)),a.find(".video_overlay_image").css({top:"",left:"",bottom:"",right:"","margin-top":""}),b=!0}y(a,!1)}else{void 0===a.attr("data-float-width-".concat(s))&&("m"===s&&(a.attr("data-float-width-m",TCB_Front.$window.width()+"px;"),a.attr("data-float-padding1-m",0),a.attr("data-float-padding2-m",0),c=0),"t"===s&&(s="d"));var u="height: "+function(t){var e=parseFloat(t.height()/t.width()).toFixed(2),o=TCB_Front.getDisplayType()[0],n=t.attr("data-float-width-".concat(o))||t.attr("data-float-width-d"),a=parseInt(n)*e;return n.includes("px")?a+"px":a*TCB_Front.$body.width()/100+"px"}(a)+" !important;",f="width: "+a.attr("data-float-width-".concat(s))+" !important;",v="";if(i.includes("keep-original")){var p=a.attr("data-float-padding1-".concat(s));TCB_Front.Utils.hasAdminBar()&&c&&(v+="margin-top: ".concat(c,"px;")),v+="top: ".concat(p," !important; ")}else i.split("-").forEach(function(t,e){var o=a.attr("data-float-padding".concat(e+1,"-").concat(s));TCB_Front.Utils.hasAdminBar()&&t.includes("top")&&c&&(v+="margin-top: ".concat(c,"px;")),v+="".concat(t,": ").concat(o," !important; ")});i&&(n.addClass(i).css({cssText:f+u+v}).parents(".tcb-col,.thrv-content-box,.thrv-page-section,#content,.theme-section").css("z-index",(TCB_Front.highestZIndex||0)+10),o.css("height",""),a.find("video").length&&function(t){t.find("video").css({"object-fit":"cover",height:"100%"})}(a),a.find(".video_overlay_image").addClass(i).css({cssText:r+f+u+"z-index:100000 !important; top:inherit; left:inherit; bottom:inherit; right: inherit; margin-top: inherit;"}),y(a,!0),b=!1)}})},a.restoreFloatingVideos=function(){h(".thrv_responsive_video").each(function(t,e){var o=h(e),n=o.find(".tcb-video-float-container"),a=o.attr("data-float-position"),i=o.find(".video_overlay_image").attr("style")||"";n.removeClass(a).css({width:"",height:""}),o.find(".video_overlay_image").removeClass(a).css({cssText:i,height:"",width:"",top:"",left:"",bottom:"",right:"","margin-top":""})})},e.exports=a},
5"lazy-load.js":function(t,e,o){var l,a,i,r,s;l=ThriveGlobal.$j,a='.tcb-video-cover:not([data-preload="1"]) .tcb-video-cover-image',i=o("./youtube"),r=o("./vooplayer"),s=[],e.exports=function(){function c(){_classCallCheck(this,c)}return _createClass(c,null,[{key:"initVideoLazyLoad",value:function(t){var e=t.find(".thrv_responsive_video.tcb-lazy-load");0!==e.length&&(TCB_Front.add_scroll_callback(function(t){0<t&&e.each(function(t,e){var o=l(e);if(c.hasVideoCover(o)){var n=o.find(a);0<n.length&&c.lazyLoadThumbnail(n)}else c.lazyLoadVideo(o,"external"===e.dataset.type)})}),e.each(function(t,e){var o=l(e);o.off("click.lazyLoad").on("pointerover",function(){return c.preconnectAssets(o)}).on("click.lazyLoad",function(){return c.lazyLoadVideo(o,"external"===e.dataset.type,!0)})}))}},{key:"preventIframeLoad",value:function(t,e,o){var n=l(e).closest(".thrv_responsive_video");return o&&!TCB_Front.Utils.isEditorPage()&&c.shouldLazyLoad(n)&&(t=!0),t}},{key:"shouldLazyLoad",value:function(t){return t.hasClass("tcb-lazy-load")&&(c.hasVideoCover(t)||!TCB_Front.isInViewport(t,-150)||c.isInsideScreenFiller(t))}},{key:"isInsideScreenFiller",value:function(t){return"hidden"===t.closest(".tve-leads-screen-filler").css("visibility")}},{key:"hasVideoCover",value:function(t){return 0<t.find(".video_overlay_image, .tcb-video-cover").length}},{key:"lazyLoadVideo",value:function(t,e,o){var n=1<arguments.length&&void 0!==e&&e,a=2<arguments.length&&void 0!==o&&o,i=t.find(n?"source":"iframe"),r=i.attr("src");if(!(i.hasClass("tcb-video-lazy-loaded")||r&&0<r.length||!t.is(":visible")||c.isInsideScreenFiller(i)||!TCB_Front.isInViewport(t,-150)&&!a)){i.hasClass("vooplayer")&&!TCB_Front.vooplayerScriptsLoaded&&(l.getScript("https://s3.spotlightr.com/assets/vooplayer.js"),TCB_Front.vooplayerScriptsLoaded=1);var s=i.attr("data-src");s&&"null"!==s&&(s=TCB_Front.Hooks.applyFilters("tcb.video.lazy_load.src",s,t),i.attr("src",s),n&&i.closest("video")[0].load()),i.removeAttr("data-src").addClass("tcb-dr-done tcb-video-lazy-loaded")}}},{key:"lazyLoadThumbnails",value:function(t){t.find(a).each(function(t,e){var o=l(e);0<o.closest(".tcb-lazy-load").length&&c.lazyLoadThumbnail(o)})}},{key:"lazyLoadThumbnail",value:function(t){if(TCB_Front.Utils.isEditorPage()||!t.hasClass("tcb-src-loaded")&&t.is(":visible")&&TCB_Front.isInViewport(t.closest(".thrv_responsive_video"),-250)){var e=t.attr("data-src");e&&"null"!==e&&t.attr("src",e),t.removeAttr("data-src"),TCB_Front.Utils.isEditorPage()||t.addClass("tcb-src-loaded")}}},{key:"preconnectAssets",value:function(t){var e=t.attr("data-type");if(!s.includes(e)){var o=[];switch(e){case"youtube":o=i.getAssetsToPreconnect();break;case"vimeo":o=c.getVimeoAssetsToPreconnect();break;case"wistia":o=c.getWistiaAssetsToPreconnect();break;case"external":var n=t.find("source").attr("data-src");void 0!==n&&(o=[new URL(n).origin]);break;case"vooplayer":o=r.getAssetsToPreconnect()}o.forEach(function(t){return c.addPreconnectLink(t)}),s.push(e)}}},{key:"addPreconnectLink",value:function(t){var e=document.createElement("link");e.rel="preconnect",e.href=t,document.head.append(e)}},{key:"getVimeoAssetsToPreconnect",value:function(){return["https://f.vimeocdn.com","https://player.vimeo.com","https://i.vimeocdn.com"]}},{key:"getWistiaAssetsToPreconnect",value:function(){return["https://fast.wistia.net"]}}]),c}()},
5"main.js":function(t,e,i){e.exports=function(s,t){var r=i("./utils"),e=i("./youtube"),o=i("./vooplayer"),n=i("./lazy-load"),a=function(){function c(){_classCallCheck(this,c)}return _createClass(c,null,[{key:"init",value:function(){c.initHooks()}},{key:"initHooks",value:function(){s(t).on("tcb_after_dom_ready",function(){return c.onDOMReady()}).on("tcb_after_lightbox_open",function(t,e){s(e).find("".concat(c.identifier,':not([data-type="dynamic"])')).each(function(t,e){return c.autoplayVideo(s(e))})}).on("tcb_before_lightbox_close",function(t,e){return c.pauseVideos(s(e))}).on("tcb_on_content_hide",function(t,e){return c.pauseVideos(s(e))}).on("tve-content-revealed",function(t,e){return c.maybeAutoplayVideo(s(e))}).on("tcb_toggle_open",function(t,e){return c.maybeAutoplayVideo(s(e))}).on("tcb_toggle_close",function(t,e){return c.pauseVideos(s(e))}).on("tcb_on_content_show",function(t,e){return c.maybeAutoplayVideo(s(e))}).on("tve_after_content_toggle",function(t,e,o){o&&n.lazyLoadThumbnails(e)}),TCB_Front.Hooks.addFilter("tcb.is_iframe_load_prevented",n.preventIframeLoad)}},{key:"onDOMReady",value:function(){var t=s("body");c.pauseVideos(s(".tve_p_lb_content")),c.pauseVideos(s("".concat(c.identifier,":hidden"))),TCB_Front.Utils.isEditorPage()||(e.initHooks(),c.maybeAutoplayVideo(t),n.initVideoLazyLoad(t),c.initOnClickEvent()),e.playBackgroundYoutube(s("div.tcb-yt-bg:visible")),o.onDOMReady(),s(".tcb-video-background-el").each(function(t,e){return e.parentNode.classList.add("tcb-video-background-parent")})}},{key:"initOnClickEvent",value:function(){s(c.identifier).off("click.thumbnail").on("click.thumbnail",function(t){return c.onClick(s(t.currentTarget),t)})}},{key:"onClick",value:function(t,e){var o=t.find(".video_overlay_image, .tcb-video-cover"),n=t.find(".tcb-video-float-container.tcb-float-closed"),a=t.find(".tcb-responsive-video").attr("data-provider"),i="";switch(a=a||t.attr("data-type")){case"youtube":case"vimeo":i="&autoplay=1";break;case"wistia":i="&autoPlay=true"}if("vooplayer"===a&&t.find(".video-skin-player").css("z-index",""),0===n.length&&["youtube","vimeo","wistia"].includes(a)){var r=t.find("iframe"),s=r.attr("src");0!==s.length&&(s.includes("?")||(i="?".concat(i.substring(1))),r.attr("src",s+i))}else c.maybePlayHtmlVideo(t,a,e);0<o.length&&o.fadeOut()}},{key:"maybePlayHtmlVideo",value:function(t,e,o){var n,a=t.attr("data-controls"),i=t.attr("data-overlay");if((!TCB_Front.browser.safari||0===parseInt(a)&&1===parseInt(i))&&(void 0===o||0===s(o.target).closest(".tcb-float-close-button").length)&&["custom","self","external"].includes(e)){var r=t.find("video").get(0);n=r.paused?"play":"pause",setTimeout(function(){r[n]()})}}},{key:"maybeAutoplayVideo",value:function(t){(void 0===t?s("".concat(c.identifier,':not([data-type="dynamic"])')):t.find("".concat(c.identifier,':not([data-type="dynamic"])'))).each(function(t,e){var o=s(e);0===o.parents(".tve_p_lb_content").length&&c.autoplayVideo(o)})}},{key:"autoplayVideo",value:function(t){if(1===parseInt(t.attr("data-autoplay"))){var e,o=t.attr("data-type"),n="";switch(o){case"youtube":n="&autoplay=1&mute=1";break;case"vimeo":n="&autoplay=1&muted=1";break;case"wistia":n="&autoPlay=true&muted=true"}if(r.isCustomProvider(o)){var a=t.find("iframe");(e=a.attr("src")||a.attr("data-src"))&&0!==e.length&&-1===e.indexOf(n)&&(e.includes("?")?"?"===e.slice(-1)&&(n=n.substring(1)):n="?".concat(n.substring(1)),e+=n,a.attr("src",e),a.attr("data-src",e))}else if(r.isSelfHosted(o)){var i=t.find("video").get(0);i&&(i.muted=!0,i.paused&&i.play())}}}},{key:"pauseVideos",value:function(t){t.find("video").each(function(t,e){return e.pause()})}},{key:"identifier",get:function(){return".thrv_responsive_video"}}]),c}();return window.TCB_Front.playBackgroundYoutube=e.playBackgroundYoutube,window.TCB_Front.refreshBackgroundYoutube=e.refreshBackgroundYoutube,window.TCB_Front.onVideoClick=a.onClick,window.TCB_Front.changeAutoplayVideo=a.maybeAutoplayVideo,window.TCB_Front.makeAutoplayVideo=a.autoplayVideo,window.TCB_Front.floating=i("./floating"),a}},
5"utils.js":function(t,e,o){var n=["youtube","vimeo","wistia"],a=["self","external","custom"];e.exports=function(){function t(){_classCallCheck(this,t)}return _createClass(t,null,[{key:"isCustomProvider",value:function(t){return n.includes(t)}},{key:"isSelfHosted",value:function(t){return a.includes(t)}}]),t}()},
5"vooplayer.js":function(t,e,o){var i,n;i=ThriveGlobal.$j,n=function(){function t(){_classCallCheck(this,t)}return _createClass(t,null,[{key:"onDOMReady",value:function(){document.addEventListener("vooPlayerReady",t.playBackgroundVoo,!1),document.addEventListener("vooPlayerReady",t.changeVooOnPlay,!1),TCB_Front.Utils.isEditorPage()?i(".tcb-video-background-el iframe.tcb-voo-bg").each(function(){var t=TVE.inner_$(this),e=t.attr("src");t.attr("src",e)}):(i('.thrv_responsive_video[data-type="vooplayer"]').each(function(t,e){var o=i(e),n=o.find(".tcb-video-cover,.video_overlay_image"),a=o.find("iframe");0<n.length&&0<a.length&&(o.find(".video-skin-player").css("z-index","-1"),a.before(n.css("height",a.height())))}),TCB_Front.floating.init())}},{key:"playBackgroundVoo",value:function(){i("iframe.tcb-voo-bg").each(function(t,e){!function t(){vooAPI(e.dataset.playerid,"onEnded",null,t),vooAPI(e.dataset.playerid,"play"),vooAPI(e.dataset.playerid,"volume",[0])}()})}},{key:"changeVooOnPlay",value:function(t){var e=0<arguments.length&&void 0!==t?t:TCB_Front.$body;e&&e.jquery||(e=TCB_Front.$body),e.find("iframe.video-player-container").each(function(t,e){function o(){i(e).css("pointer-events",""),i(e).parent().find("#theImg").remove()}e.src?o():vooAPI(e.dataset.playerid,"onPlay",null,function(){o()})})}},{key:"getAssetsToPreconnect",value:function(){return["https://s3.spotlightr.com"]}}]),t}(),e.exports=n,window.TCB_Front.changeVooOnPlay=n.changeVooOnPlay},
5"youtube.js":function(t,e,o){var a;a=ThriveGlobal.$j,e.exports=function(){function n(){_classCallCheck(this,n)}return _createClass(n,null,[{key:"initHooks",value:function(){TCB_Front.Hooks.addFilter("tcb.video.lazy_load.src",function(t,e){return t.includes("&enablejsapi=1")||"youtube"!==e.attr("data-type")||(t+="&enablejsapi=1"),t})}},{key:"playBackgroundYoutube",value:function(t){t.length&&(void 0!==window.YT&&window.YT.Player?n._playYTBackground(t):(window.onYouTubeIframeAPIReady=function(){n._playYTBackground(t)},n.fetchIframeAPI()))}},{key:"_playYTBackground",value:function(t){t.each(function(){var t,e=this.getAttribute("data-yt-id");t=34===e.length?new YT.Player(this.id,{playerVars:n.getDefaultPlayerParameters(e,!0),events:{onReady:function(t){t.target.mute()},onStateChange:function(t){t.target.mute()}}}):new YT.Player(this.id,{videoId:e,playerVars:n.getDefaultPlayerParameters(e),events:{onReady:function(t){t.target.mute(),t.target.playVideo()},onStateChange:function(t){t.target&&t.target.mute&&t.target.mute(),t.data===(YT.PlayerState.ENDED||0)&&t.target.playVideo()}}}),a(t.getIframe()).data("tcb-yt-player",t)})}},{key:"refreshBackgroundYoutube",value:function(){window.YT&&window.YT.Player&&a("iframe.tcb-yt-bg").each(function(t,e){var o=a(e);o.data("tcb-yt-player")||n._playYTBackground(o)})}},{key:"getAssetsToPreconnect",value:function(){return["https://www.youtube.com","https://www.google.com","https://googleads.g.doubleclick.net","https://static.doubleclick.net","https://www.gstatic.com"]}},{key:"fetchIframeAPI",value:function(){a.ajax({url:"https://www.youtube.com/iframe_api",type:"get",crossDomain:!0,cache:!0,dataType:"script"})}},{key:"getDefaultPlayerParameters",value:function(t,e){var o={autoplay:1,cc_load_policy:0,controls:0,disablekb:1,fs:0,iv_load_policy:0,modestbranding:1,playsinline:1,rel:0,showinfo:0,playlist:t};return 1<arguments.length&&void 0!==e&&e&&(o.loop=1,o.listType="playlist"),o}}]),n}()}},
5"video.js":function(t,e,o){void 0===TCB_Front.js_modules.video&&TCB_Front.setModuleLoadedStatus("video",!1),function(){if(!TCB_Front.isModuleLoaded("video")){var t=o("./video/main")(ThriveGlobal.$j,window);t.init(),window.TCB_Front.video=t,TCB_Front.setModuleLoadedStatus("video",!0)}}(ThriveGlobal.$j)}
5}}}}}})("workspace/editor/js/frontend/modules/video");
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.