(window.webpackJsonp=window.webpackJsonp||[]).push([[4],{325:function(e,t,n){}}]),function(e){function t(t){for(var r,a,c=t[0],u=t[1],l=t[2],f=0,d=[];f=0&&(e._idleTimeoutId=setTimeout((function(){e._onTimeout&&e._onTimeout()}),t))},n(118),t.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==e&&e.setImmediate||this&&this.setImmediate,t.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==e&&e.clearImmediate||this&&this.clearImmediate}).call(this,n(25))},118:function(e,t,n){(function(e,t){!function(e,n){"use strict";if(!e.setImmediate){var r,o,i,a,c,u=1,l={},s=!1,f=e.document,d=Object.getPrototypeOf&&Object.getPrototypeOf(e);d=d&&d.setTimeout?d:e,"[object process]"==={}.toString.call(e.process)?r=function(e){t.nextTick((function(){p(e)}))}:function(){if(e.postMessage&&!e.importScripts){var t=!0,n=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=n,t}}()?(a="setImmediate$"+Math.random()+"$",c=function(t){t.source===e&&"string"==typeof t.data&&0===t.data.indexOf(a)&&p(+t.data.slice(a.length))},e.addEventListener?e.addEventListener("message",c,!1):e.attachEvent("onmessage",c),r=function(t){e.postMessage(a+t,"*")}):e.MessageChannel?((i=new MessageChannel).port1.onmessage=function(e){p(e.data)},r=function(e){i.port2.postMessage(e)}):f&&"onreadystatechange"in f.createElement("script")?(o=f.documentElement,r=function(e){var t=f.createElement("script");t.onreadystatechange=function(){p(e),t.onreadystatechange=null,o.removeChild(t),t=null},o.appendChild(t)}):r=function(e){setTimeout(p,0,e)},d.setImmediate=function(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),n=0;n{Array.from(e.getElementsByClassName("vimeo-core-video")).forEach((e,t)=>{const n=new r.a(e);n.on("play",()=>(e=>{o.videoPlayers.forEach((t,n)=>{var r;n!==e&&(r=t.element.src,"true"===new URL(r).searchParams.get("autopause"))&&t.pause()})})(t)),o.videoPlayers.push(n)})};try{"undefined"!=typeof wp&&void 0!==wp.data&&"function"==typeof wp.data.subscribe&&wp.data.subscribe(()=>{wp.data.select("core/editor").getBlocks().filter(e=>"vimeo/create"===e.name).length!==o.videoPlayers.length&&(o.videoPlayers.forEach(e=>e.off("play")),o.videoPlayers=[],i(document.getElementById("editor")))}),window.jQuery(()=>i())}catch(e){console.error(e)}},25:function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},330:function(e,t,n){"use strict";n.r(t);var r=n(47),o=(n(325),n(73));Object(o.b)(),window.jQuery((function(){document.querySelectorAll('[data-js="vimeo-wc-video"]').forEach((function(e){e.classList.add("vimeo-wc-video");const t=JSON.parse(e.dataset.atts),n=new r.a(e.id,t);n.ready().then(()=>{const t=e.querySelector("iframe");if(!t)return;t.classList.add("vimeo-core-video");const r=Number.parseInt(t.width),o=Number.parseInt(t.height);if(r&&o&&(t.style.aspectRatio=`${r}/${o}`),"ontouchstart"in window||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0){const r=function(){t.classList.add("playing")},o=function(){t.classList.add("paused"),t.classList.remove("playing")};n.on("play",r),n.on("pause",o),e.addEventListener("click",()=>{n.play()})}})}))}));function i(e=".vimeo-wc__big-video iframe"){document.querySelectorAll(e).forEach(e=>{const t=new r.a(e);null==t||t.pause()})}function a(){document.querySelectorAll(".woocommerce-product-gallery .woocommerce-product-gallery__image").forEach(e=>{!function(e,t=(()=>{}),n=(()=>{})){new window.MutationObserver((function(e){for(const r of e)"attributes"===r.type&&(n(),"class"===r.attributeName&&t())})).observe(e,{attributes:!0})}(e,()=>{e.classList.contains("flex-active-slide")&&i(".vimeo-wc-video iframe")})})}const c=["autopause","autoplay","background","byline","color","controls","dnt","loop","maxheight","maxwidth","muted","pip","playsinline","portrait","quality","responsive","speed","texttrack","title","transparent"];try{window.jQuery((function(e){var t;if(e(".woocommerce-product-gallery"))if(window.PhotoSwipeUI_Default){function n(e){var t;const n=null===(t=e.src)||void 0===t?void 0:t.match(/#vimeo-wc/),r=document.querySelector(`[data-js="${e.src}"] iframe`);if(n&&r){const t=r.cloneNode(!0);Object(o.a)()&&(t.height=t.width="100%"),t.height=t.width="100%",e.html=`\n\t\t\t
\n\t\t\t\t${t.outerHTML}\n\t\t\t
`,delete e.src}}e(".woocommerce-product-gallery").on("wc-product-gallery-before-init",(function(t,r){e(r).on("mousedown",".flex-control-nav img",e=>{e.target.classList.contains("flex-active")||i(".vimeo-wc-video iframe")});const o=window.PhotoSwipeUI_Default;window.PhotoSwipeUI_Default=function(e,t){return e.items.forEach(n),e.listen("close",()=>{i(".vimeo-wc__big-video iframe")}),e.listen("beforeChange",()=>{i(".vimeo-wc__big-video iframe")}),e.listen("initialZoomIn",()=>{i(".vimeo-wc-video iframe")}),new o(e,t)}})),a()}else null!==(t=window.avadaLightBox)&&void 0!==t&&t.refresh_lightbox?(document.querySelectorAll(".vimeo-wc__gallery-video").forEach(e=>{e.style.position="relative";const t=JSON.parse(e.querySelector('[data-js="vimeo-wc-video"]').dataset.atts),n=document.createElement("a");n.href=function(e,t){const n=new URL(e);for(const e of Object.keys(t).sort()){const r=t[e];c.includes(e)&&null!=r&&n.searchParams.set(e,r)}return n}(t.url,t),n.dataset.rel="iLightbox[product-gallery]",n.dataset.title="",n.dataset.caption="",n.style.padding="5px",n.style.width="auto",n.style.position="absolute",n.style.top="1rem",n.style.right="1rem",n.style.zIndex="99",n.style.left="unset",n.style.fontSize="26px",n.style.height="52px",n.innerText="πŸ”",n.classList.add("avada-product-gallery-lightbox-trigger"),n.title="Open Vimeo Video in Lightbox",e.append(n)}),a()):a()}))}catch(e){console.error(e)}n(173)},47:function(e,t,n){"use strict";(function(e,n){function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function o(e){for(var t=1;t=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(c&&u){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),P(n),d}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;P(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:_(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),d}},e}function a(e,t,n,r,o,i,a){try{var c=e[i](a),u=c.value}catch(e){return void n(e)}c.done?t(u):Promise.resolve(u).then(r,o)}function c(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function c(e){a(i,r,o,c,u,"next",e)}function u(e){a(i,r,o,c,u,"throw",e)}c(void 0)}))}}function u(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function l(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{},t=e.id,n=e.url,r=t||n;if(!r)throw new Error("An id or url must be passed, either in an options object or as a data-vimeo-id or data-vimeo-url attribute.");if(x(r))return"https://vimeo.com/".concat(r);if(T(r))return r.replace("http:","https:");if(t)throw new TypeError("β€œ".concat(t,"” is not a valid video id."));throw new TypeError("β€œ".concat(r,"” is not a vimeo.com url."))}var _=function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"addEventListener",o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"removeEventListener",i="string"==typeof t?[t]:t;return i.forEach((function(t){e[r](t,n)})),{cancel:function(){return i.forEach((function(t){return e[o](t,n)}))}}},O=void 0!==Array.prototype.indexOf,S="undefined"!=typeof window&&void 0!==window.postMessage;if(!(b||O&&S))throw new Error("Sorry, the Vimeo Player API is not available in this browser.");var L="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{};!function(e){if(!e.WeakMap){var t=Object.prototype.hasOwnProperty,n=Object.defineProperty&&function(){try{return 1===Object.defineProperty({},"x",{value:1}).x}catch(e){}}(),r=function(e,t,r){n?Object.defineProperty(e,t,{configurable:!0,writable:!0,value:r}):e[t]=r};e.WeakMap=function(){function e(){if(void 0===this)throw new TypeError("Constructor WeakMap requires 'new'");if(r(this,"_id",i("_WeakMap")),arguments.length>0)throw new TypeError("WeakMap iterable is not supported")}function n(e,n){if(!o(e)||!t.call(e,"_id"))throw new TypeError(n+" method called on incompatible receiver "+typeof e)}function i(e){return e+"_"+a()+"."+a()}function a(){return Math.random().toString().substring(2)}return r(e.prototype,"delete",(function(e){if(n(this,"delete"),!o(e))return!1;var t=e[this._id];return!(!t||t[0]!==e||(delete e[this._id],0))})),r(e.prototype,"get",(function(e){if(n(this,"get"),o(e)){var t=e[this._id];return t&&t[0]===e?t[1]:void 0}})),r(e.prototype,"has",(function(e){if(n(this,"has"),!o(e))return!1;var t=e[this._id];return!(!t||t[0]!==e)})),r(e.prototype,"set",(function(e,t){if(n(this,"set"),!o(e))throw new TypeError("Invalid value used as weak map key");var i=e[this._id];return i&&i[0]===e?(i[1]=t,this):(r(e,this._id,[e,t]),this)})),r(e,"_polyfill",!0),e}()}function o(e){return Object(e)===e}}("undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:L);var M=function(e,t){return function(e){var t,r;r=function(){var e,t,r,o=Object.prototype.toString,i=void 0!==n?function(e){return n(e)}:setTimeout;try{Object.defineProperty({},"x",{}),e=function(e,t,n,r){return Object.defineProperty(e,t,{value:n,writable:!0,configurable:!1!==r})}}catch(t){e=function(e,t,n){return e[t]=n,e}}function a(e,n){r.add(e,n),t||(t=i(r.drain))}function c(e){var t,n=typeof e;return null==e||"object"!=n&&"function"!=n||(t=e.then),"function"==typeof t&&t}function u(){for(var e=0;e0&&a(u,n))}catch(e){f.call(new h(n),e)}}}function f(e){var t=this;t.triggered||(t.triggered=!0,t.def&&(t=t.def),t.msg=e,t.state=2,t.chain.length>0&&a(u,t))}function d(e,t,n,r){for(var o=0;o=8&&o<10&&(r=JSON.stringify(r)),e.element.contentWindow.postMessage(r,e.origin)}}function V(e,t){var n,r=[];if((t=R(t)).event)"error"===t.event&&N(e,t.data.method).forEach((function(n){var r=new Error(t.data.message);r.name=t.data.name,n.reject(r),F(e,t.data.method,n)})),r=N(e,"event:".concat(t.event)),n=t.data;else if(t.method){var o=function(e,t){var n=N(e,t);if(n.length<1)return!1;var r=n.shift();return F(e,t,r),r}(e,t.method);o&&(r.push(o),n=t.value)}r.forEach((function(t){try{if("function"==typeof t)return void t.call(e,n);t.resolve(n)}catch(e){}}))}var D=["autopause","autoplay","background","byline","color","colors","controls","dnt","height","id","interactive_params","keyboard","loop","maxheight","maxwidth","muted","playsinline","portrait","responsive","speed","texttrack","title","transparent","url","width"];function W(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return D.reduce((function(t,n){var r=e.getAttribute("data-vimeo-".concat(n));return(r||""===r)&&(t[n]=""===r?1:r),t}),t)}function U(e,t){var n=e.html;if(!t)throw new TypeError("An element must be provided");if(null!==t.getAttribute("data-vimeo-initialized"))return t.querySelector("iframe");var r=document.createElement("div");return r.innerHTML=n,t.appendChild(r.firstChild),t.setAttribute("data-vimeo-initialized","true"),t.querySelector("iframe")}function z(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;return new Promise((function(r,o){if(!T(e))throw new TypeError("β€œ".concat(e,"” is not a vimeo.com url."));var i="https://vimeo.com/api/oembed.json?url=".concat(encodeURIComponent(e));for(var a in t)t.hasOwnProperty(a)&&(i+="&".concat(a,"=").concat(encodeURIComponent(t[a])));var c="XDomainRequest"in window?new XDomainRequest:new XMLHttpRequest;c.open("GET",i,!0),c.onload=function(){if(404!==c.status)if(403!==c.status)try{var t=JSON.parse(c.responseText);if(403===t.domain_status_code)return U(t,n),void o(new Error("β€œ".concat(e,"” is not embeddable.")));r(t)}catch(e){o(e)}else o(new Error("β€œ".concat(e,"” is not embeddable.")));else o(new Error("β€œ".concat(e,"” was not found.")))},c.onerror=function(){var e=c.status?" (".concat(c.status,")"):"";o(new Error("There was an error fetching the embed code from Vimeo".concat(e,".")))},c.send()}))}var B={role:"viewer",autoPlayMuted:!0,allowedDrift:.3,maxAllowedDrift:1,minCheckInterval:.1,maxRateAdjustment:.2,maxTimeToCatchUp:1},G=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&h(e,t)}(m,e);var t,n,r,a,l,v=(t=m,n=p(),function(){var e,r=d(t);if(n){var o=d(this).constructor;e=Reflect.construct(r,arguments,o)}else e=r.apply(this,arguments);return g(this,e)});function m(e,t){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=arguments.length>3?arguments[3]:void 0;return u(this,m),f(y(n=v.call(this)),"logger",void 0),f(y(n),"speedAdjustment",0),f(y(n),"adjustSpeed",function(){var e=c(i().mark((function e(t,r){var o;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n.speedAdjustment!==r){e.next=2;break}return e.abrupt("return");case 2:return e.next=4,t.getPlaybackRate();case 4:return e.t0=e.sent,e.t1=n.speedAdjustment,e.t2=e.t0-e.t1,e.t3=r,o=e.t2+e.t3,n.log("New playbackRate: ".concat(o)),e.next=12,t.setPlaybackRate(o);case 12:n.speedAdjustment=r;case 13:case"end":return e.stop()}}),e)})));return function(_x,t){return e.apply(this,arguments)}}()),n.logger=a,n.init(t,e,o(o({},B),r)),n}return s(m,[{key:"disconnect",value:function(){this.dispatchEvent(new Event("disconnect"))}},{key:"init",value:(l=c(i().mark((function e(t,n,r){var o,a,c,u=this;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.waitForTOReadyState(t,"open");case 2:if("viewer"!==r.role){e.next=10;break}return e.next=5,this.updatePlayer(t,n,r);case 5:o=_(t,"change",(function(){return u.updatePlayer(t,n,r)})),a=this.maintainPlaybackPosition(t,n,r),this.addEventListener("disconnect",(function(){a.cancel(),o.cancel()})),e.next=14;break;case 10:return e.next=12,this.updateTimingObject(t,n);case 12:c=_(n,["seeked","play","pause","ratechange"],(function(){return u.updateTimingObject(t,n)}),"on","off"),this.addEventListener("disconnect",(function(){return c.cancel()}));case 14:case"end":return e.stop()}}),e,this)}))),function(e,t,n){return l.apply(this,arguments)})},{key:"updateTimingObject",value:(a=c(i().mark((function e(t,n){return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.t0=t,e.next=3,n.getCurrentTime();case 3:return e.t1=e.sent,e.next=6,n.getPaused();case 6:if(!e.sent){e.next=10;break}e.t2=0,e.next=13;break;case 10:return e.next=12,n.getPlaybackRate();case 12:e.t2=e.sent;case 13:e.t3=e.t2,e.t4={position:e.t1,velocity:e.t3},e.t0.update.call(e.t0,e.t4);case 16:case"end":return e.stop()}}),e)}))),function(e,t){return a.apply(this,arguments)})},{key:"updatePlayer",value:(r=c(i().mark((function e(t,n,r){var o,a,u;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(o=t.query(),a=o.position,u=o.velocity,"number"==typeof a&&n.setCurrentTime(a),"number"!=typeof u){e.next=25;break}if(0!==u){e.next=11;break}return e.next=6,n.getPaused();case 6:if(e.t0=e.sent,!1!==e.t0){e.next=9;break}n.pause();case 9:e.next=25;break;case 11:if(!(u>0)){e.next=25;break}return e.next=14,n.getPaused();case 14:if(e.t1=e.sent,!0!==e.t1){e.next=19;break}return e.next=18,n.play().catch(function(){var e=c(i().mark((function e(t){return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if("NotAllowedError"!==t.name||!r.autoPlayMuted){e.next=5;break}return e.next=3,n.setMuted(!0);case 3:return e.next=5,n.play().catch((function(e){return console.error("Couldn't play the video from TimingSrcConnector. Error:",e)}));case 5:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}());case 18:this.updatePlayer(t,n,r);case 19:return e.next=21,n.getPlaybackRate();case 21:if(e.t2=e.sent,e.t3=u,e.t2===e.t3){e.next=25;break}n.setPlaybackRate(u);case 25:case"end":return e.stop()}}),e,this)}))),function(e,t,n){return r.apply(this,arguments)})},{key:"maintainPlaybackPosition",value:function(e,t,n){var r=this,o=n.allowedDrift,a=n.maxAllowedDrift,u=n.minCheckInterval,l=n.maxRateAdjustment,s=n.maxTimeToCatchUp,f=1e3*Math.min(s,Math.max(u,a)),d=function(){var n=c(i().mark((function n(){var c,u,f,d,h;return i().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(n.t0=0===e.query().velocity,n.t0){n.next=6;break}return n.next=4,t.getPaused();case 4:n.t1=n.sent,n.t0=!0===n.t1;case 6:if(!n.t0){n.next=8;break}return n.abrupt("return");case 8:return n.t2=e.query().position,n.next=11,t.getCurrentTime();case 11:if(n.t3=n.sent,c=n.t2-n.t3,u=Math.abs(c),r.log("Drift: ".concat(c)),!(u>a)){n.next=22;break}return n.next=18,r.adjustSpeed(t,0);case 18:t.setCurrentTime(e.query().position),r.log("Resync by currentTime"),n.next=29;break;case 22:if(!(u>o)){n.next=29;break}return h=(f=u/s)<(d=l)?(d-f)/2:d,n.next=28,r.adjustSpeed(t,h*Math.sign(c));case 28:r.log("Resync by playbackRate");case 29:case"end":return n.stop()}}),n)})));return function(){return n.apply(this,arguments)}}(),h=setInterval((function(){return d()}),f);return{cancel:function(){return clearInterval(h)}}}},{key:"log",value:function(e){var t;null===(t=this.logger)||void 0===t||t.call(this,"TimingSrcConnector: ".concat(e))}},{key:"waitForTOReadyState",value:function(e,t){return new Promise((function(n){!function r(){e.readyState===t?n():e.addEventListener("readystatechange",r,{once:!0})}()}))}}]),m}(m(EventTarget)),J=new WeakMap,Q=new WeakMap,$={},H=function(){function e(t){var n=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(u(this,e),window.jQuery&&t instanceof jQuery&&(t.length>1&&window.console&&console.warn&&console.warn("A jQuery object with multiple elements was passed, using the first element."),t=t[0]),"undefined"!=typeof document&&"string"==typeof t&&(t=document.getElementById(t)),!E(t))throw new TypeError("You must pass either a valid element or a valid id.");if("IFRAME"!==t.nodeName){var o=t.querySelector("iframe");o&&(t=o)}if("IFRAME"===t.nodeName&&!T(t.getAttribute("src")||""))throw new Error("The player element passed isn’t a Vimeo embed.");if(J.has(t))return J.get(t);this._window=t.ownerDocument.defaultView,this.element=t,this.origin="*";var i=new M((function(e,o){if(n._onMessage=function(t){if(T(t.origin)&&n.element.contentWindow===t.source){"*"===n.origin&&(n.origin=t.origin);var r=R(t.data);if(r&&"error"===r.event&&r.data&&"ready"===r.data.method){var i=new Error(r.data.message);return i.name=r.data.name,void o(i)}var a=r&&"ready"===r.event,c=r&&"ping"===r.method;if(a||c)return n.element.setAttribute("data-ready","true"),void e();V(n,r)}},n._window.addEventListener("message",n._onMessage),"IFRAME"!==n.element.nodeName){var i=W(t,r);z(j(i),i,t).then((function(e){var r=U(e,t);return n.element=r,n._originalElement=t,A(t,r),J.set(n.element,n),e})).catch(o)}}));if(Q.set(this,i),J.set(this.element,this),"IFRAME"===this.element.nodeName&&q(this,"ping"),$.isEnabled){var a=function(){return $.exit()};this.fullscreenchangeHandler=function(){$.isFullscreen?C(n,"event:exitFullscreen",a):F(n,"event:exitFullscreen",a),n.ready().then((function(){q(n,"fullscreenchange",$.isFullscreen)}))},$.on("fullscreenchange",this.fullscreenchangeHandler)}return this}var t;return s(e,[{key:"callMethod",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return new M((function(r,o){return t.ready().then((function(){C(t,e,{resolve:r,reject:o}),q(t,e,n)})).catch(o)}))}},{key:"get",value:function(e){var t=this;return new M((function(n,r){return e=k(e,"get"),t.ready().then((function(){C(t,e,{resolve:n,reject:r}),q(t,e)})).catch(r)}))}},{key:"set",value:function(e,t){var n=this;return new M((function(r,o){if(e=k(e,"set"),null==t)throw new TypeError("There must be a value to set.");return n.ready().then((function(){C(n,e,{resolve:r,reject:o}),q(n,e,t)})).catch(o)}))}},{key:"on",value:function(e,t){if(!e)throw new TypeError("You must pass an event name.");if(!t)throw new TypeError("You must pass a callback function.");if("function"!=typeof t)throw new TypeError("The callback must be a function.");0===N(this,"event:".concat(e)).length&&this.callMethod("addEventListener",e).catch((function(){})),C(this,"event:".concat(e),t)}},{key:"off",value:function(e,t){if(!e)throw new TypeError("You must pass an event name.");if(t&&"function"!=typeof t)throw new TypeError("The callback must be a function.");F(this,"event:".concat(e),t)&&this.callMethod("removeEventListener",e).catch((function(e){}))}},{key:"loadVideo",value:function(e){return this.callMethod("loadVideo",e)}},{key:"ready",value:function(){var e=Q.get(this)||new M((function(e,t){t(new Error("Unknown player. Probably unloaded."))}));return M.resolve(e)}},{key:"addCuePoint",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.callMethod("addCuePoint",{time:e,data:t})}},{key:"removeCuePoint",value:function(e){return this.callMethod("removeCuePoint",e)}},{key:"enableTextTrack",value:function(e,t){if(!e)throw new TypeError("You must pass a language.");return this.callMethod("enableTextTrack",{language:e,kind:t})}},{key:"disableTextTrack",value:function(){return this.callMethod("disableTextTrack")}},{key:"pause",value:function(){return this.callMethod("pause")}},{key:"play",value:function(){return this.callMethod("play")}},{key:"requestFullscreen",value:function(){return $.isEnabled?$.request(this.element):this.callMethod("requestFullscreen")}},{key:"exitFullscreen",value:function(){return $.isEnabled?$.exit():this.callMethod("exitFullscreen")}},{key:"getFullscreen",value:function(){return $.isEnabled?M.resolve($.isFullscreen):this.get("fullscreen")}},{key:"requestPictureInPicture",value:function(){return this.callMethod("requestPictureInPicture")}},{key:"exitPictureInPicture",value:function(){return this.callMethod("exitPictureInPicture")}},{key:"getPictureInPicture",value:function(){return this.get("pictureInPicture")}},{key:"remotePlaybackPrompt",value:function(){return this.callMethod("remotePlaybackPrompt")}},{key:"unload",value:function(){return this.callMethod("unload")}},{key:"destroy",value:function(){var e=this;return new M((function(t){if(Q.delete(e),J.delete(e.element),e._originalElement&&(J.delete(e._originalElement),e._originalElement.removeAttribute("data-vimeo-initialized")),e.element&&"IFRAME"===e.element.nodeName&&e.element.parentNode&&(e.element.parentNode.parentNode&&e._originalElement&&e._originalElement!==e.element.parentNode?e.element.parentNode.parentNode.removeChild(e.element.parentNode):e.element.parentNode.removeChild(e.element)),e.element&&"DIV"===e.element.nodeName&&e.element.parentNode){e.element.removeAttribute("data-vimeo-initialized");var n=e.element.querySelector("iframe");n&&n.parentNode&&(n.parentNode.parentNode&&e._originalElement&&e._originalElement!==n.parentNode?n.parentNode.parentNode.removeChild(n.parentNode):n.parentNode.removeChild(n))}e._window.removeEventListener("message",e._onMessage),$.isEnabled&&$.off("fullscreenchange",e.fullscreenchangeHandler),t()}))}},{key:"getAutopause",value:function(){return this.get("autopause")}},{key:"setAutopause",value:function(e){return this.set("autopause",e)}},{key:"getBuffered",value:function(){return this.get("buffered")}},{key:"getCameraProps",value:function(){return this.get("cameraProps")}},{key:"setCameraProps",value:function(e){return this.set("cameraProps",e)}},{key:"getChapters",value:function(){return this.get("chapters")}},{key:"getCurrentChapter",value:function(){return this.get("currentChapter")}},{key:"getColor",value:function(){return this.get("color")}},{key:"getColors",value:function(){return M.all([this.get("colorOne"),this.get("colorTwo"),this.get("colorThree"),this.get("colorFour")])}},{key:"setColor",value:function(e){return this.set("color",e)}},{key:"setColors",value:function(e){if(!Array.isArray(e))return new M((function(e,t){return t(new TypeError("Argument must be an array."))}));var t=new M((function(e){return e(null)})),n=[e[0]?this.set("colorOne",e[0]):t,e[1]?this.set("colorTwo",e[1]):t,e[2]?this.set("colorThree",e[2]):t,e[3]?this.set("colorFour",e[3]):t];return M.all(n)}},{key:"getCuePoints",value:function(){return this.get("cuePoints")}},{key:"getCurrentTime",value:function(){return this.get("currentTime")}},{key:"setCurrentTime",value:function(e){return this.set("currentTime",e)}},{key:"getDuration",value:function(){return this.get("duration")}},{key:"getEnded",value:function(){return this.get("ended")}},{key:"getLoop",value:function(){return this.get("loop")}},{key:"setLoop",value:function(e){return this.set("loop",e)}},{key:"setMuted",value:function(e){return this.set("muted",e)}},{key:"getMuted",value:function(){return this.get("muted")}},{key:"getPaused",value:function(){return this.get("paused")}},{key:"getPlaybackRate",value:function(){return this.get("playbackRate")}},{key:"setPlaybackRate",value:function(e){return this.set("playbackRate",e)}},{key:"getPlayed",value:function(){return this.get("played")}},{key:"getQualities",value:function(){return this.get("qualities")}},{key:"getQuality",value:function(){return this.get("quality")}},{key:"setQuality",value:function(e){return this.set("quality",e)}},{key:"getRemotePlaybackAvailability",value:function(){return this.get("remotePlaybackAvailability")}},{key:"getRemotePlaybackState",value:function(){return this.get("remotePlaybackState")}},{key:"getSeekable",value:function(){return this.get("seekable")}},{key:"getSeeking",value:function(){return this.get("seeking")}},{key:"getTextTracks",value:function(){return this.get("textTracks")}},{key:"getVideoEmbedCode",value:function(){return this.get("videoEmbedCode")}},{key:"getVideoId",value:function(){return this.get("videoId")}},{key:"getVideoTitle",value:function(){return this.get("videoTitle")}},{key:"getVideoWidth",value:function(){return this.get("videoWidth")}},{key:"getVideoHeight",value:function(){return this.get("videoHeight")}},{key:"getVideoUrl",value:function(){return this.get("videoUrl")}},{key:"getVolume",value:function(){return this.get("volume")}},{key:"setVolume",value:function(e){return this.set("volume",e)}},{key:"setTimingSrc",value:(t=c(i().mark((function e(t,n){var r,o=this;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t){e.next=2;break}throw new TypeError("A Timing Object must be provided.");case 2:return e.next=4,this.ready();case 4:return r=new G(this,t,n),q(this,"notifyTimingObjectConnect"),r.addEventListener("disconnect",(function(){return q(o,"notifyTimingObjectDisconnect")})),e.abrupt("return",r);case 8:case"end":return e.stop()}}),e,this)}))),function(_x,e){return t.apply(this,arguments)})}]),e}();b||($=function(){var e=function(){for(var e,t=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]],n=0,r=t.length,o={};n0&&void 0!==arguments[0]?arguments[0]:document,t=[].slice.call(e.querySelectorAll("[data-vimeo-id], [data-vimeo-url]")),n=function(e){"console"in window&&console.error&&console.error("There was an error creating an embed: ".concat(e))};t.forEach((function(e){try{if(null!==e.getAttribute("data-vimeo-defer"))return;var t=W(e);z(j(t),t,e).then((function(t){return U(t,e)})).catch(n)}catch(e){n(e)}}))}(),function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document;if(!window.VimeoPlayerResizeEmbeds_){window.VimeoPlayerResizeEmbeds_=!0;var t=function(t){if(T(t.origin)&&t.data&&"spacechange"===t.data.event)for(var n=e.querySelectorAll("iframe"),r=0;r0&&void 0!==arguments[0]?arguments[0]:document;if(!window.VimeoSeoMetadataAppended){window.VimeoSeoMetadataAppended=!0;var t=function(t){if(T(t.origin)){var n=R(t.data);if(n&&"ready"===n.event)for(var r=e.querySelectorAll("iframe"),o=0;o0&&void 0!==arguments[0]?arguments[0]:document;if(!window.VimeoCheckedUrlTimeParam){window.VimeoCheckedUrlTimeParam=!0;var t=function(e){"console"in window&&console.error&&console.error("There was an error getting video Id: ".concat(e))},n=function(n){if(T(n.origin)){var r=R(n.data);if(r&&"ready"===r.event)for(var o=e.querySelectorAll("iframe"),i=function(){var e=o[a],r=e.contentWindow===n.source;if(P(e.src)&&r){var i=new H(e);i.getVideoId().then((function(e){var t=new RegExp("[?&]vimeo_t_".concat(e,"=([^&#]*)")).exec(window.location.href);if(t&&t[1]){var n=decodeURI(t[1]);i.setCurrentTime(n)}})).catch(t)}},a=0;a1)for(var n=1;n{document.querySelectorAll("iframe.vimeo-core-video").forEach(e=>{var t,n;const r=null!==(t=e.height)&&void 0!==t&&t.endsWith("%")?9:parseInt(e.height),o=null!==(n=e.width)&&void 0!==n&&n.endsWith("%")?16:parseInt(e.width),i=e.offsetWidth*r/o+"px";r&&o&&e.style.height!==i&&(e.style.height=i)})},1500)),r}}});