Skip to content

Instantly share code, notes, and snippets.

@stuntbaboon
Created August 31, 2020 20:44
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save stuntbaboon/abb0ce284241d51901676942d4d12a45 to your computer and use it in GitHub Desktop.
Save stuntbaboon/abb0ce284241d51901676942d4d12a45 to your computer and use it in GitHub Desktop.
Patched YouTube Iframe API
if(!window.YT)var YT={loading:0,loaded:0};if(!window.YTConfig)var YTConfig={host:"https://www.youtube.com"};YT.loading||(YT.loading=1,function(){var t=[];YT.ready=function(e){YT.loaded?e():t.push(e)},window.onYTReady=function(){YT.loaded=1;for(var e=0;e<t.length;e++)try{t[e]()}catch(t){}},YT.setConfig=function(t){for(var e in t)t.hasOwnProperty(e)&&(YTConfig[e]=t[e])}}()),function(){var t;function e(t){var e=0;return function(){return e<t.length?{done:!1,value:t[e++]}:{done:!0}}}var n="function"==typeof Object.defineProperties?Object.defineProperty:function(t,e,n){return t==Array.prototype||t==Object.prototype?t:(t[e]=n.value,t)};var r=function(t){t=["object"==typeof globalThis&&globalThis,t,"object"==typeof window&&window,"object"==typeof self&&self,"object"==typeof global&&global];for(var e=0;e<t.length;++e){var n=t[e];if(n&&n.Math==Math)return n}throw Error("Cannot find global object")}(this);function i(t,e){if(e)t:{for(var i=r,o=t.split("."),a=0;a<o.length-1;a++){var s=o[a];if(!(s in i))break t;i=i[s]}(s=e(a=i[o=o[o.length-1]]))!=a&&null!=s&&n(i,o,{configurable:!0,writable:!0,value:s})}}function o(t){return(t={next:t})[Symbol.iterator]=function(){return this},t}function a(t){var n="undefined"!=typeof Symbol&&Symbol.iterator&&t[Symbol.iterator];return n?n.call(t):{next:e(t)}}i("Symbol",function(t){function e(t,e){this.f=t,n(this,"description",{configurable:!0,writable:!0,value:e})}if(t)return t;e.prototype.toString=function(){return this.f};var r=0;return function t(n){if(this instanceof t)throw new TypeError("Symbol is not a constructor");return new e("jscomp_symbol_"+(n||"")+"_"+r++,n)}}),i("Symbol.iterator",function(t){if(t)return t;t=Symbol("Symbol.iterator");for(var i="Array Int8Array Uint8Array Uint8ClampedArray Int16Array Uint16Array Int32Array Uint32Array Float32Array Float64Array".split(" "),a=0;a<i.length;a++){var s=r[i[a]];"function"==typeof s&&"function"!=typeof s.prototype[t]&&n(s.prototype,t,{configurable:!0,writable:!0,value:function(){return o(e(this))}})}return t});var s,u="function"==typeof Object.create?Object.create:function(t){function e(){}return e.prototype=t,new e};if("function"==typeof Object.setPrototypeOf)s=Object.setPrototypeOf;else{var c;t:{var f={};try{f.__proto__={a:!0},c=f.a;break t}catch(vt){}c=!1}s=c?function(t,e){if(t.__proto__=e,t.__proto__!==e)throw new TypeError(t+" is not extensible");return t}:null}var l=s;function h(t,e){if(t.prototype=u(e.prototype),t.prototype.constructor=t,l)l(t,e);else for(var n in e)if("prototype"!=n)if(Object.defineProperties){var r=Object.getOwnPropertyDescriptor(e,n);r&&Object.defineProperty(t,n,r)}else t[n]=e[n];t.F=e.prototype}function d(){this.m=!1,this.i=null,this.g=void 0,this.f=1,this.j=this.l=0,this.A=this.h=null}function p(t){if(t.m)throw new TypeError("Generator is already running");t.m=!0}function v(t,e){t.h={fa:e,U:!0},t.f=t.l||t.j}function g(t,e,n){return t.f=n,{value:e}}function y(t){this.f=new d,this.g=t}function m(t,e,n,r){try{var i=e.call(t.f.i,n);if(!(i instanceof Object))throw new TypeError("Iterator result "+i+" is not an object");if(!i.done)return t.f.m=!1,i;var o=i.value}catch(e){return t.f.i=null,v(t.f,e),w(t)}return t.f.i=null,r.call(t.f,o),w(t)}function w(t){for(;t.f.f;)try{var e=t.g(t.f);if(e)return t.f.m=!1,{value:e.value,done:!1}}catch(e){t.f.g=void 0,v(t.f,e)}if(t.f.m=!1,t.f.h){if(e=t.f.h,t.f.h=null,e.U)throw e.fa;return{value:e.return,done:!0}}return{value:void 0,done:!0}}function b(t){this.next=function(e){return p(t.f),t.f.i?e=m(t,t.f.i.next,e,t.f.s):(t.f.s(e),e=w(t)),e},this.throw=function(e){return p(t.f),t.f.i?e=m(t,t.f.i.throw,e,t.f.s):(v(t.f,e),e=w(t)),e},this.return=function(e){return function(t,e){p(t.f);var n=t.f.i;return n?m(t,"return"in n?n.return:function(t){return{value:t,done:!0}},e,t.f.return):(t.f.return(e),w(t))}(t,e)},this[Symbol.iterator]=function(){return this}}function E(t,e){var n=new b(new y(e));return l&&t.prototype&&l(n,t.prototype),n}function _(t,e){return Object.prototype.hasOwnProperty.call(t,e)}d.prototype.s=function(t){this.g=t},d.prototype.return=function(t){this.h={return:t},this.f=this.j},d.prototype.v=function(t){this.f=t},i("Reflect.setPrototypeOf",function(t){return t||(l?function(t,e){try{return l(t,e),!0}catch(t){return!1}}:null)}),i("Object.setPrototypeOf",function(t){return t||l});var S="function"==typeof Object.assign?Object.assign:function(t,e){for(var n=1;n<arguments.length;n++){var r=arguments[n];if(r)for(var i in r)_(r,i)&&(t[i]=r[i])}return t};function I(t,e,n){if(null==t)throw new TypeError("The 'this' value for String.prototype."+n+" must not be null or undefined");if(e instanceof RegExp)throw new TypeError("First argument to String.prototype."+n+" must not be a regular expression");return t+""}function T(t,e){t instanceof String&&(t+="");var n=0,r=!1,i={next:function(){if(!r&&n<t.length){var i=n++;return{value:e(i,t[i]),done:!1}}return r=!0,{done:!0,value:void 0}}};return i[Symbol.iterator]=function(){return i},i}i("Object.assign",function(t){return t||S}),i("Promise",function(t){function e(t){this.g=0,this.h=void 0,this.f=[];var e=this.i();try{t(e.resolve,e.reject)}catch(t){e.reject(t)}}function n(){this.f=null}function i(t){return t instanceof e?t:new e(function(e){e(t)})}if(t)return t;n.prototype.g=function(t){if(null==this.f){this.f=[];var e=this;this.h(function(){e.j()})}this.f.push(t)};var o=r.setTimeout;n.prototype.h=function(t){o(t,0)},n.prototype.j=function(){for(;this.f&&this.f.length;){var t=this.f;this.f=[];for(var e=0;e<t.length;++e){var n=t[e];t[e]=null;try{n()}catch(t){this.i(t)}}}this.f=null},n.prototype.i=function(t){this.h(function(){throw t})},e.prototype.i=function(){function t(t){return function(r){n||(n=!0,t.call(e,r))}}var e=this,n=!1;return{resolve:t(this.G),reject:t(this.j)}},e.prototype.G=function(t){if(t===this)this.j(new TypeError("A Promise cannot resolve to itself"));else if(t instanceof e)this.pa(t);else{t:switch(typeof t){case"object":var n=null!=t;break t;case"function":n=!0;break t;default:n=!1}n?this.A(t):this.l(t)}},e.prototype.A=function(t){var e=void 0;try{e=t.then}catch(t){return void this.j(t)}"function"==typeof e?this.da(e,t):this.l(t)},e.prototype.j=function(t){this.m(2,t)},e.prototype.l=function(t){this.m(1,t)},e.prototype.m=function(t,e){if(0!=this.g)throw Error("Cannot settle("+t+", "+e+"): Promise already settled in state"+this.g);this.g=t,this.h=e,this.s()},e.prototype.s=function(){if(null!=this.f){for(var t=0;t<this.f.length;++t)s.g(this.f[t]);this.f=null}};var s=new n;return e.prototype.pa=function(t){var e=this.i();t.H(e.resolve,e.reject)},e.prototype.da=function(t,e){var n=this.i();try{t.call(e,n.resolve,n.reject)}catch(t){n.reject(t)}},e.prototype.then=function(t,n){function r(t,e){return"function"==typeof t?function(e){try{i(t(e))}catch(t){o(t)}}:e}var i,o,a=new e(function(t,e){i=t,o=e});return this.H(r(t,i),r(n,o)),a},e.prototype.catch=function(t){return this.then(void 0,t)},e.prototype.H=function(t,e){function n(){switch(r.g){case 1:t(r.h);break;case 2:e(r.h);break;default:throw Error("Unexpected state: "+r.g)}}var r=this;null==this.f?s.g(n):this.f.push(n)},e.resolve=i,e.reject=function(t){return new e(function(e,n){n(t)})},e.race=function(t){return new e(function(e,n){for(var r=a(t),o=r.next();!o.done;o=r.next())i(o.value).H(e,n)})},e.all=function(t){var n=a(t),r=n.next();return r.done?i([]):new e(function(t,e){function o(e){return function(n){a[e]=n,0==--s&&t(a)}}var a=[],s=0;do{a.push(void 0),s++,i(r.value).H(o(a.length-1),e),r=n.next()}while(!r.done)})},e}),i("String.prototype.endsWith",function(t){return t||function(t,e){var n=I(this,t,"endsWith");t+="",void 0===e&&(e=n.length);for(var r=Math.max(0,Math.min(0|e,n.length)),i=t.length;0<i&&0<r;)if(n[--r]!=t[--i])return!1;return 0>=i}}),i("String.prototype.startsWith",function(t){return t||function(t,e){var n=I(this,t,"startsWith");t+="";for(var r=n.length,i=t.length,o=Math.max(0,Math.min(0|e,n.length)),a=0;a<i&&o<r;)if(n[o++]!=t[a++])return!1;return a>=i}}),i("Array.prototype.keys",function(t){return t||function(){return T(this,function(t){return t})}}),i("Array.prototype.values",function(t){return t||function(){return T(this,function(t,e){return e})}}),i("Object.is",function(t){return t||function(t,e){return t===e?0!==t||1/t==1/e:t!=t&&e!=e}}),i("Array.prototype.includes",function(t){return t||function(t,e){var n=this;n instanceof String&&(n=String(n));var r=n.length,i=e||0;for(0>i&&(i=Math.max(i+r,0));i<r;i++){var o=n[i];if(o===t||Object.is(o,t))return!0}return!1}}),i("String.prototype.includes",function(t){return t||function(t,e){return-1!==I(this,t,"includes").indexOf(t,e||0)}}),i("Array.prototype.entries",function(t){return t||function(){return T(this,function(t,e){return[t,e]})}}),i("WeakMap",function(t){function e(t){if(this.f=(c+=Math.random()+1).toString(),t){t=a(t);for(var e;!(e=t.next()).done;)e=e.value,this.set(e[0],e[1])}}function r(){}function i(t){var e=typeof t;return"object"===e&&null!==t||"function"===e}function o(t){if(!_(t,u)){var e=new r;n(t,u,{value:e})}}function s(t){var e=Object[t];e&&(Object[t]=function(t){return t instanceof r?t:(Object.isExtensible(t)&&o(t),e(t))})}if(function(){if(!t||!Object.seal)return!1;try{var e=Object.seal({}),n=Object.seal({}),r=new t([[e,2],[n,3]]);return 2==r.get(e)&&3==r.get(n)&&(r.delete(e),r.set(n,4),!r.has(e)&&4==r.get(n))}catch(t){return!1}}())return t;var u="$jscomp_hidden_"+Math.random();s("freeze"),s("preventExtensions"),s("seal");var c=0;return e.prototype.set=function(t,e){if(!i(t))throw Error("Invalid WeakMap key");if(o(t),!_(t,u))throw Error("WeakMap key fail: "+t);return t[u][this.f]=e,this},e.prototype.get=function(t){return i(t)&&_(t,u)?t[u][this.f]:void 0},e.prototype.has=function(t){return i(t)&&_(t,u)&&_(t[u],this.f)},e.prototype.delete=function(t){return!!(i(t)&&_(t,u)&&_(t[u],this.f))&&delete t[u][this.f]},e}),i("Map",function(t){function e(){var t={};return t.previous=t.next=t.head=t}function n(t,e){var n=t.f;return o(function(){if(n){for(;n.head!=t.f;)n=n.previous;for(;n.next!=n.head;)return n=n.next,{done:!1,value:e(n)};n=null}return{done:!0,value:void 0}})}function r(t,e){var n=e&&typeof e;"object"==n||"function"==n?s.has(e)?n=s.get(e):(n=""+ ++u,s.set(e,n)):n="p_"+e;var r=t.g[n];if(r&&_(t.g,n))for(var i=0;i<r.length;i++){var o=r[i];if(e!=e&&o.key!=o.key||e===o.key)return{id:n,list:r,index:i,o:o}}return{id:n,list:r,index:-1,o:void 0}}function i(t){if(this.g={},this.f=e(),this.size=0,t){t=a(t);for(var n;!(n=t.next()).done;)n=n.value,this.set(n[0],n[1])}}if(function(){if(!t||"function"!=typeof t||!t.prototype.entries||"function"!=typeof Object.seal)return!1;try{var e=Object.seal({x:4}),n=new t(a([[e,"s"]]));if("s"!=n.get(e)||1!=n.size||n.get({x:4})||n.set({x:4},"t")!=n||2!=n.size)return!1;var r=n.entries(),i=r.next();return!i.done&&i.value[0]==e&&"s"==i.value[1]&&!((i=r.next()).done||4!=i.value[0].x||"t"!=i.value[1]||!r.next().done)}catch(t){return!1}}())return t;var s=new WeakMap;i.prototype.set=function(t,e){var n=r(this,t=0===t?0:t);return n.list||(n.list=this.g[n.id]=[]),n.o?n.o.value=e:(n.o={next:this.f,previous:this.f.previous,head:this.f,key:t,value:e},n.list.push(n.o),this.f.previous.next=n.o,this.f.previous=n.o,this.size++),this},i.prototype.delete=function(t){return!(!(t=r(this,t)).o||!t.list)&&(t.list.splice(t.index,1),t.list.length||delete this.g[t.id],t.o.previous.next=t.o.next,t.o.next.previous=t.o.previous,t.o.head=null,this.size--,!0)},i.prototype.clear=function(){this.g={},this.f=this.f.previous=e(),this.size=0},i.prototype.has=function(t){return!!r(this,t).o},i.prototype.get=function(t){return(t=r(this,t).o)&&t.value},i.prototype.entries=function(){return n(this,function(t){return[t.key,t.value]})},i.prototype.keys=function(){return n(this,function(t){return t.key})},i.prototype.values=function(){return n(this,function(t){return t.value})},i.prototype.forEach=function(t,e){for(var n,r=this.entries();!(n=r.next()).done;)n=n.value,t.call(e,n[1],n[0],this)},i.prototype[Symbol.iterator]=i.prototype.entries;var u=0;return i}),i("Object.entries",function(t){return t||function(t){var e,n=[];for(e in t)_(t,e)&&n.push([e,t[e]]);return n}}),i("Set",function(t){function e(t){if(this.f=new Map,t){t=a(t);for(var e;!(e=t.next()).done;)this.add(e.value)}this.size=this.f.size}return function(){if(!t||"function"!=typeof t||!t.prototype.entries||"function"!=typeof Object.seal)return!1;try{var e=Object.seal({x:4}),n=new t(a([e]));if(!n.has(e)||1!=n.size||n.add(e)!=n||1!=n.size||n.add({x:4})!=n||2!=n.size)return!1;var r=n.entries(),i=r.next();return!i.done&&i.value[0]==e&&i.value[1]==e&&(!(i=r.next()).done&&i.value[0]!=e&&4==i.value[0].x&&i.value[1]==i.value[0]&&r.next().done)}catch(t){return!1}}()?t:(e.prototype.add=function(t){return t=0===t?0:t,this.f.set(t,t),this.size=this.f.size,this},e.prototype.delete=function(t){return t=this.f.delete(t),this.size=this.f.size,t},e.prototype.clear=function(){this.f.clear(),this.size=0},e.prototype.has=function(t){return this.f.has(t)},e.prototype.entries=function(){return this.f.entries()},e.prototype.values=function(){return this.f.values()},e.prototype.keys=e.prototype.values,e.prototype[Symbol.iterator]=e.prototype.values,e.prototype.forEach=function(t,e){var n=this;this.f.forEach(function(r){return t.call(e,r,r,n)})},e)});var N=this||self;function x(t,e){for(var n=t.split("."),r=e||N,i=0;i<n.length;i++)if(null==(r=r[n[i]]))return null;return r}function O(){}function A(t){var e=typeof t;return"object"!=e?e:t?Array.isArray(t)?"array":e:"null"}function k(t){var e=A(t);return"array"==e||"object"==e&&"number"==typeof t.length}function R(t){return"function"==A(t)}function j(t){var e=typeof t;return"object"==e&&null!=t||"function"==e}function C(t){return Object.prototype.hasOwnProperty.call(t,L)&&t[L]||(t[L]=++P)}var L="closure_uid_"+(1e9*Math.random()>>>0),P=0;function D(t,e,n){return t.call.apply(t.bind,arguments)}function M(t,e,n){if(!t)throw Error();if(2<arguments.length){var r=Array.prototype.slice.call(arguments,2);return function(){var n=Array.prototype.slice.call(arguments);return Array.prototype.unshift.apply(n,r),t.apply(e,n)}}return function(){return t.apply(e,arguments)}}function U(t,e,n){return(U=Function.prototype.bind&&-1!=Function.prototype.bind.toString().indexOf("native code")?D:M).apply(null,arguments)}var B=Date.now;function Y(t,e){var n,r=t.split("."),i=N;r[0]in i||void 0===i.execScript||i.execScript("var "+r[0]);for(;r.length&&(n=r.shift());)r.length||void 0===e?i=i[n]&&i[n]!==Object.prototype[n]?i[n]:i[n]={}:i[n]=e}function X(t,e){function n(){}n.prototype=e.prototype,t.F=e.prototype,t.prototype=new n,t.prototype.constructor=t}function q(t){return t}function V(t,e){var n=void 0;return new(n||(n=Promise))(function(r,i){function o(t){try{s(e.next(t))}catch(t){i(t)}}function a(t){try{s(e.throw(t))}catch(t){i(t)}}function s(t){t.done?r(t.value):new n(function(e){e(t.value)}).then(o,a)}s((e=e.apply(t,void 0)).next())})}function G(t){if(Error.captureStackTrace)Error.captureStackTrace(this,G);else{var e=Error().stack;e&&(this.stack=e)}t&&(this.message=String(t))}X(G,Error),G.prototype.name="CustomError";var F=Array.prototype.indexOf?function(t,e){return Array.prototype.indexOf.call(t,e,void 0)}:function(t,e){if("string"==typeof t)return"string"!=typeof e||1!=e.length?-1:t.indexOf(e,0);for(var n=0;n<t.length;n++)if(n in t&&t[n]===e)return n;return-1},W=Array.prototype.forEach?function(t,e,n){Array.prototype.forEach.call(t,e,n)}:function(t,e,n){for(var r=t.length,i="string"==typeof t?t.split(""):t,o=0;o<r;o++)o in i&&e.call(n,i[o],o,t)},K=Array.prototype.reduce?function(t,e,n){return Array.prototype.reduce.call(t,e,n)}:function(t,e,n){var r=n;return W(t,function(n,i){r=e.call(void 0,r,n,i,t)}),r};function z(t){var e=t.length;if(0<e){for(var n=Array(e),r=0;r<e;r++)n[r]=t[r];return n}return[]}function H(t,e){for(var n=1;n<arguments.length;n++){var r=arguments[n];if(k(r)){var i=t.length||0,o=r.length||0;t.length=i+o;for(var a=0;a<o;a++)t[i+a]=r[a]}else t.push(r)}}function J(t){var e,n=!1;return function(){return n||(e=t(),n=!0),e}}function Q(t,e){for(var n in t)if(!(n in e)||t[n]!==e[n])return!1;for(var r in e)if(!(r in t))return!1;return!0}function Z(t){var e=A(t);if("object"==e||"array"==e){if(R(t.clone))return t.clone();for(var n in e="array"==e?[]:{},t)e[n]=Z(t[n]);return e}return t}var $,tt="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" ");var et,nt=String.prototype.trim?function(t){return t.trim()}:function(t){return/^[\s\xa0]*([\s\S]*?)[\s\xa0]*$/.exec(t)[1]},rt=/&/g,it=/</g,ot=/>/g,at=/"/g,st=/'/g,ut=/\x00/g,ct=/[\x00&<>"']/;t:{var ft=N.navigator;if(ft){var lt=ft.userAgent;if(lt){et=lt;break t}}et=""}function ht(t){return-1!=et.indexOf(t)}function dt(){}var pt,vt,gt=ht("Opera"),yt=ht("Trident")||ht("MSIE"),mt=ht("Edge"),wt=ht("Gecko")&&!(-1!=et.toLowerCase().indexOf("webkit")&&!ht("Edge"))&&!(ht("Trident")||ht("MSIE"))&&!ht("Edge"),bt=-1!=et.toLowerCase().indexOf("webkit")&&!ht("Edge");function Et(){var t=N.document;return t?t.documentMode:void 0}t:{var _t="",St=(vt=et,wt?/rv:([^\);]+)(\)|;)/.exec(vt):mt?/Edge\/([\d\.]+)/.exec(vt):yt?/\b(?:MSIE|rv)[: ]([^\);]+)(\)|;)/.exec(vt):bt?/WebKit\/(\S+)/.exec(vt):gt?/(?:Version)[ \/]?(\S+)/.exec(vt):void 0);if(St&&(_t=St?St[1]:""),yt){var It=Et();if(null!=It&&It>parseFloat(_t)){pt=String(It);break t}}pt=_t}var Tt,Nt=pt;if(N.document&&yt){var xt=Et();Tt=xt||(parseInt(Nt,10)||void 0)}else Tt=void 0;var Ot=Tt,At=ht("iPhone")&&!ht("iPod")&&!ht("iPad")||ht("iPod"),kt=ht("iPad"),Rt={},jt=null,Ct=window;function Lt(t){var e=x("window.location.href");if(null==t&&(t='Unknown Error of type "null/undefined"'),"string"==typeof t)return{message:t,name:"Unknown error",lineNumber:"Not available",fileName:e,stack:"Not available"};var n=!1;try{var r=t.lineNumber||t.line||"Not available"}catch(t){r="Not available",n=!0}try{var i=t.fileName||t.filename||t.sourceURL||N.$googDebugFname||e}catch(t){i="Not available",n=!0}if(e=function t(e,n){n||(n={});n[Pt(e)]=!0;var r=e.stack||"",i=e.Da;i&&!n[Pt(i)]&&(r+="\nCaused by: ",i.stack&&0==i.stack.indexOf(i.toString())||(r+="string"==typeof i?i:i.message+"\n"),r+=t(i,n));return r}(t),!(!n&&t.lineNumber&&t.fileName&&t.stack&&t.message&&t.name)){if(null==(n=t.message)){if(t.constructor&&t.constructor instanceof Function){if(t.constructor.name)n=t.constructor.name;else if(n=t.constructor,Dt[n])n=Dt[n];else{if(n=String(n),!Dt[n]){var o=/function\s+([^\(]+)/m.exec(n);Dt[n]=o?o[1]:"[Anonymous]"}n=Dt[n]}n='Unknown Error of type "'+n+'"'}else n="Unknown Error of unknown type";"function"==typeof t.toString&&Object.prototype.toString!==t.toString&&(n+=": "+t.toString())}return{message:n,name:t.name||"UnknownError",lineNumber:r,fileName:i,stack:e||"Not available"}}return t.stack=e,t}function Pt(t){var e="";return"function"==typeof t.toString&&(e=""+t),e+t.stack}var Dt={};function Mt(t){this.f=t||{cookie:""}}(t=Mt.prototype).isEnabled=function(){return navigator.cookieEnabled},t.set=function(t,e,n){var r=!1;if("object"==typeof n){var i=n.Ka;r=n.secure||!1;var o=n.domain||void 0,a=n.path||void 0,s=n.V}if(/[;=\s]/.test(t))throw Error('Invalid cookie name "'+t+'"');if(/[;\r\n]/.test(e))throw Error('Invalid cookie value "'+e+'"');void 0===s&&(s=-1),n=o?";domain="+o:"",a=a?";path="+a:"",r=r?";secure":"",s=0>s?"":0==s?";expires="+new Date(1970,1,1).toUTCString():";expires="+new Date(B()+1e3*s).toUTCString(),this.f.cookie=t+"="+e+n+a+s+r+(null!=i?";samesite="+i:"")},t.get=function(t,e){for(var n,r=t+"=",i=(this.f.cookie||"").split(";"),o=0;o<i.length;o++){if(0==(n=nt(i[o])).lastIndexOf(r,0))return n.substr(r.length);if(n==t)return""}return e},t.remove=function(t,e,n){var r=void 0!==this.get(t);return this.set(t,"",{V:0,path:e,domain:n}),r},t.isEmpty=function(){return!this.f.cookie},t.clear=function(){for(var t,e,n=(this.f.cookie||"").split(";"),r=[],i=[],o=0;o<n.length;o++)-1==(t=(e=nt(n[o])).indexOf("="))?(r.push(""),i.push(e)):(r.push(e.substring(0,t)),i.push(e.substring(t+1)));for(n=r.length-1;0<=n;n--)this.remove(r[n])};var Ut=new Mt("undefined"==typeof document?null:document);function Bt(t,e){this.width=t,this.height=e}function Yt(){var t=document,e="IFRAME";return"application/xhtml+xml"===t.contentType&&(e=e.toLowerCase()),t.createElement(e)}(t=Bt.prototype).clone=function(){return new Bt(this.width,this.height)},t.aspectRatio=function(){return this.width/this.height},t.isEmpty=function(){return!(this.width*this.height)},t.ceil=function(){return this.width=Math.ceil(this.width),this.height=Math.ceil(this.height),this},t.floor=function(){return this.width=Math.floor(this.width),this.height=Math.floor(this.height),this},t.round=function(){return this.width=Math.round(this.width),this.height=Math.round(this.height),this};var Xt=/^(?:([^:\/?#.]+):)?(?:\/\/(?:([^\\\/?#]*)@)?([^\\\/?#]*?)(?::([0-9]+))?(?=[\\\/?#]|$))?([^?#]+)?(?:\?([^#]*))?(?:#([\s\S]*))?$/;function qt(t){return t?decodeURI(t):t}function Vt(t){return qt(t.match(Xt)[3]||null)}function Gt(t){var e=t.match(Xt);t=e[1];var n=e[2],r=e[3];e=e[4];var i="";return t&&(i+=t+":"),r&&(i+="//",n&&(i+=n+"@"),i+=r,e&&(i+=":"+e)),i}function Ft(t,e,n){if(Array.isArray(e))for(var r=0;r<e.length;r++)Ft(t,String(e[r]),n);else null!=e&&n.push(t+(""===e?"":"="+encodeURIComponent(String(e))))}function Wt(t){var e,n=[];for(e in t)Ft(e,t[e],n);return n.join("&")}var Kt=/#|$/;function zt(){var t=[];return function(t){var e=Ht;if(e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.call(void 0,e[n],n,e)}(function(e){t.push(e)}),t}var Ht={qa:"allow-forms",ra:"allow-modals",sa:"allow-orientation-lock",ta:"allow-pointer-lock",ua:"allow-popups",va:"allow-popups-to-escape-sandbox",wa:"allow-presentation",xa:"allow-same-origin",ya:"allow-scripts",za:"allow-top-navigation",Aa:"allow-top-navigation-by-user-activation"},Jt=J(function(){return zt()});function Qt(){this.h=this.h,this.i=this.i}Qt.prototype.h=!1,Qt.prototype.dispose=function(){this.h||(this.h=!0,this.O())},Qt.prototype.O=function(){if(this.i)for(;this.i.length;)this.i.shift()()};var Zt={};function $t(t,e){if(e!==Zt)throw Error("Bad secret");this.f=t}h($t,function(){}),$t.prototype.toString=function(){return this.f},new $t("about:blank",Zt),new $t("about:invalid#zTSz",Zt);var te,ee=(new Date).getTime();function ne(t){if(!t)return"";0==(t=(t=t.split("#")[0].split("?")[0]).toLowerCase()).indexOf("//")&&(t=window.location.protocol+t),/^[\w\-]*:\/\//.test(t)||(t=window.location.href);var e=t.substring(t.indexOf("://")+3),n=e.indexOf("/");if(-1!=n&&(e=e.substring(0,n)),"http"!==(t=t.substring(0,t.indexOf("://")))&&"https"!==t&&"chrome-extension"!==t&&"moz-extension"!==t&&"file"!==t&&"android-app"!==t&&"chrome-search"!==t&&"chrome-untrusted"!==t&&"chrome"!==t&&"app"!==t&&"devtools"!==t)throw Error("Invalid URI scheme in origin: "+t);n="";var r=e.indexOf(":");if(-1!=r){var i=e.substring(r+1);e=e.substring(0,r),("http"===t&&"80"!==i||"https"===t&&"443"!==i)&&(n=":"+i)}return t+"://"+e+n}function re(t,e,n){var r=[],i=[];if(1==(Array.isArray(n)?2:1))return i=[e,t],W(r,function(t){i.push(t)}),ie(i.join(" "));var o=[],a=[];return W(n,function(t){a.push(t.key),o.push(t.value)}),n=Math.floor((new Date).getTime()/1e3),i=0==o.length?[n,e,t]:[o.join(":"),n,e,t],W(r,function(t){i.push(t)}),t=[n,t=ie(i.join(" "))],0==a.length||t.push(a.join("")),t.join("_")}function ie(t){var e=function(){function t(){i[0]=1732584193,i[1]=4023233417,i[2]=2562383102,i[3]=271733878,i[4]=3285377520,f=c=0}function e(t){for(var e=a,n=0;64>n;n+=4)e[n/4]=t[n]<<24|t[n+1]<<16|t[n+2]<<8|t[n+3];for(n=16;80>n;n++)t=e[n-3]^e[n-8]^e[n-14]^e[n-16],e[n]=4294967295&(t<<1|t>>>31);t=i[0];var r=i[1],o=i[2],s=i[3],u=i[4];for(n=0;80>n;n++){if(40>n)if(20>n)var c=s^r&(o^s),f=1518500249;else c=r^o^s,f=1859775393;else 60>n?(c=r&o|s&(r|o),f=2400959708):(c=r^o^s,f=3395469782);c=(4294967295&(t<<5|t>>>27))+c+u+f+e[n]&4294967295,u=s,s=o,o=4294967295&(r<<30|r>>>2),r=t,t=c}i[0]=i[0]+t&4294967295,i[1]=i[1]+r&4294967295,i[2]=i[2]+o&4294967295,i[3]=i[3]+s&4294967295,i[4]=i[4]+u&4294967295}function n(t,n){if("string"==typeof t){for(var r=[],i=0,a=(t=unescape(encodeURIComponent(t))).length;i<a;++i)r.push(t.charCodeAt(i));t=r}if(n||(n=t.length),r=0,0==c)for(;r+64<n;)e(t.slice(r,r+64)),r+=64,f+=64;for(;r<n;)if(o[c++]=t[r++],f++,64==c)for(c=0,e(o);r+64<n;)e(t.slice(r,r+64)),r+=64,f+=64}function r(){var t=[],r=8*f;n(s,56>c?56-c:64-(c-56));for(var a=63;56<=a;a--)o[a]=255&r,r>>>=8;for(e(o),a=r=0;5>a;a++)for(var u=24;0<=u;u-=8)t[r++]=i[a]>>u&255;return t}for(var i=[],o=[],a=[],s=[128],u=1;64>u;++u)s[u]=0;var c,f;return t(),{reset:t,update:n,digest:r,ea:function(){for(var t=r(),e="",n=0;n<t.length;n++)e+="0123456789ABCDEF".charAt(Math.floor(t[n]/16))+"0123456789ABCDEF".charAt(t[n]%16);return e}}}();return e.update(t),e.ea().toLowerCase()}function oe(t){var e,n=ne(String(N.location.href));if((e=N.__SAPISID||N.__APISID||N.__OVERRIDE_SID)?e=!0:e=!!(e=(e=new Mt(document)).get("SAPISID")||e.get("APISID")||e.get("__Secure-3PAPISID")||e.get("SID")),e&&((e=(n=0==n.indexOf("https:")||0==n.indexOf("chrome-extension:")||0==n.indexOf("moz-extension:"))?N.__SAPISID:N.__APISID)||(e=(e=new Mt(document)).get(n?"SAPISID":"APISID")||e.get("__Secure-3PAPISID")),e)){n=n?"SAPISIDHASH":"APISIDHASH";var r=String(N.location.href);return r&&e&&n?[n,re(ne(r),e,t||null)].join(" "):null}return null}function ae(){this.g=[],this.f=-1}function se(t,e){this.h=t,this.i=e,this.g=0,this.f=null}function ue(t,e){t.i(e),100>t.g&&(t.g++,e.next=t.f,t.f=e)}function ce(t){N.setTimeout(function(){throw t},0)}function fe(){this.g=this.f=null}ae.prototype.set=function(t,e){e=void 0===e||e,0<=t&&52>t&&0==t%1&&this.g[t]!=e&&(this.g[t]=e,this.f=-1)},ae.prototype.get=function(t){return!!this.g[t]},se.prototype.get=function(){if(0<this.g){this.g--;var t=this.f;this.f=t.next,t.next=null}else t=this.h();return t};var le,he=new se(function(){return new de},function(t){t.reset()});function de(){this.next=this.scope=this.f=null}function pe(t,e){le||function(){if(N.Promise&&N.Promise.resolve){var t=N.Promise.resolve(void 0);le=function(){t.then(ye)}}else le=function(){var t=ye;!R(N.setImmediate)||N.Window&&N.Window.prototype&&!ht("Edge")&&N.Window.prototype.setImmediate==N.setImmediate?(te||(te=function(){var t=N.MessageChannel;if(void 0===t&&"undefined"!=typeof window&&window.postMessage&&window.addEventListener&&!ht("Presto")&&(t=function(){var t=Yt();t.style.display="none",document.documentElement.appendChild(t);var e=t.contentWindow;(t=e.document).open(),t.close();var n="callImmediate"+Math.random(),r="file:"==e.location.protocol?"*":e.location.protocol+"//"+e.location.host;t=U(function(t){"*"!=r&&t.origin!=r||t.data!=n||this.port1.onmessage()},this),e.addEventListener("message",t,!1),this.port1={},this.port2={postMessage:function(){e.postMessage(n,r)}}}),void 0!==t&&!ht("Trident")&&!ht("MSIE")){var e=new t,n={},r=n;return e.port1.onmessage=function(){if(void 0!==n.next){var t=(n=n.next).T;n.T=null,t()}},function(t){r.next={T:t},r=r.next,e.port2.postMessage(0)}}return function(t){N.setTimeout(t,0)}}()),te(t)):N.setImmediate(t)}}(),ve||(le(),ve=!0),ge.add(t,e)}fe.prototype.add=function(t,e){var n=he.get();n.set(t,e),this.g?this.g.next=n:this.f=n,this.g=n},fe.prototype.remove=function(){var t=null;return this.f&&(t=this.f,this.f=this.f.next,this.f||(this.g=null),t.next=null),t},de.prototype.set=function(t,e){this.f=t,this.scope=e,this.next=null},de.prototype.reset=function(){this.next=this.scope=this.f=null};var ve=!1,ge=new fe;function ye(){for(var t;t=ge.remove();){try{t.f.call(t.scope)}catch(t){ce(t)}ue(he,t)}ve=!1}function me(){this.g=64,this.f=[],this.l=[],this.m=[],this.i=[],this.i[0]=128;for(var t=1;t<this.g;++t)this.i[t]=0;this.j=this.h=0,this.reset()}function we(t,e,n){n||(n=0);var r=t.m;if("string"==typeof e)for(var i=0;16>i;i++)r[i]=e.charCodeAt(n)<<24|e.charCodeAt(n+1)<<16|e.charCodeAt(n+2)<<8|e.charCodeAt(n+3),n+=4;else for(i=0;16>i;i++)r[i]=e[n]<<24|e[n+1]<<16|e[n+2]<<8|e[n+3],n+=4;for(i=16;80>i;i++){var o=r[i-3]^r[i-8]^r[i-14]^r[i-16];r[i]=4294967295&(o<<1|o>>>31)}e=t.f[0],n=t.f[1];var a=t.f[2],s=t.f[3],u=t.f[4];for(i=0;80>i;i++){if(40>i)if(20>i){o=s^n&(a^s);var c=1518500249}else o=n^a^s,c=1859775393;else 60>i?(o=n&a|s&(n|a),c=2400959708):(o=n^a^s,c=3395469782);o=(e<<5|e>>>27)+o+u+c+r[i]&4294967295,u=s,s=a,a=4294967295&(n<<30|n>>>2),n=e,e=o}t.f[0]=t.f[0]+e&4294967295,t.f[1]=t.f[1]+n&4294967295,t.f[2]=t.f[2]+a&4294967295,t.f[3]=t.f[3]+s&4294967295,t.f[4]=t.f[4]+u&4294967295}X(me,function(){this.g=-1}),me.prototype.reset=function(){this.f[0]=1732584193,this.f[1]=4023233417,this.f[2]=2562383102,this.f[3]=271733878,this.f[4]=3285377520,this.j=this.h=0},me.prototype.update=function(t,e){if(null!=t){void 0===e&&(e=t.length);for(var n=e-this.g,r=0,i=this.l,o=this.h;r<e;){if(0==o)for(;r<=n;)we(this,t,r),r+=this.g;if("string"==typeof t){for(;r<e;)if(i[o]=t.charCodeAt(r),++r,++o==this.g){we(this,i),o=0;break}}else for(;r<e;)if(i[o]=t[r],++r,++o==this.g){we(this,i),o=0;break}}this.h=o,this.j+=e}},me.prototype.digest=function(){var t=[],e=8*this.j;56>this.h?this.update(this.i,56-this.h):this.update(this.i,this.g-(this.h-56));for(var n=this.g-1;56<=n;n--)this.l[n]=255&e,e/=256;for(we(this,this.l),n=e=0;5>n;n++)for(var r=24;0<=r;r-=8)t[e]=this.f[n]>>r&255,++e;return t};var be="StopIteration"in N?N.StopIteration:{message:"StopIteration",stack:""};function Ee(){}function _e(t){if(t instanceof Ee)return t;if("function"==typeof t.B)return t.B(!1);if(k(t)){var e=0,n=new Ee;return n.next=function(){for(;;){if(e>=t.length)throw be;if(e in t)return t[e++];e++}},n}throw Error("Not implemented")}function Se(t){if(k(t))return z(t);t=_e(t);var e=[];return function(t,e){if(k(t))try{W(t,e,void 0)}catch(t){if(t!==be)throw t}else{t=_e(t);try{for(;;)e.call(void 0,t.next(),void 0,t)}catch(t){if(t!==be)throw t}}}(t,function(t){e.push(t)}),e}function Ie(t,e){this.h={},this.f=[],this.i=this.g=0;var n=arguments.length;if(1<n){if(n%2)throw Error("Uneven number of arguments");for(var r=0;r<n;r+=2)this.set(arguments[r],arguments[r+1])}else if(t)if(t instanceof Ie)for(n=Te(t),r=0;r<n.length;r++)this.set(n[r],t.get(n[r]));else for(r in t)this.set(r,t[r])}function Te(t){return xe(t),t.f.concat()}function Ne(t,e){return t===e}function xe(t){if(t.g!=t.f.length){for(var e=0,n=0;e<t.f.length;){var r=t.f[e];Object.prototype.hasOwnProperty.call(t.h,r)&&(t.f[n++]=r),e++}t.f.length=n}if(t.g!=t.f.length){var i={};for(n=e=0;e<t.f.length;)r=t.f[e],Object.prototype.hasOwnProperty.call(i,r)||(t.f[n++]=r,i[r]=1),e++;t.f.length=n}}Ee.prototype.next=function(){throw be},Ee.prototype.B=function(){return this},(t=Ie.prototype).equals=function(t,e){if(this===t)return!0;if(this.g!=t.g)return!1;var n=e||Ne;xe(this);for(var r,i=0;r=this.f[i];i++)if(!n(this.get(r),t.get(r)))return!1;return!0},t.isEmpty=function(){return 0==this.g},t.clear=function(){this.h={},this.i=this.g=this.f.length=0},t.remove=function(t){return!!Object.prototype.hasOwnProperty.call(this.h,t)&&(delete this.h[t],this.g--,this.i++,this.f.length>2*this.g&&xe(this),!0)},t.get=function(t,e){return Object.prototype.hasOwnProperty.call(this.h,t)?this.h[t]:e},t.set=function(t,e){Object.prototype.hasOwnProperty.call(this.h,t)||(this.g++,this.f.push(t),this.i++),this.h[t]=e},t.forEach=function(t,e){for(var n=Te(this),r=0;r<n.length;r++){var i=n[r],o=this.get(i);t.call(e,o,i,this)}},t.clone=function(){return new Ie(this)},t.B=function(t){xe(this);var e=0,n=this.i,r=this,i=new Ee;return i.next=function(){if(n!=r.i)throw Error("The map has changed since the iterator was created");if(e>=r.f.length)throw be;var i=r.f[e++];return t?i:r.h[i]},i};var Oe=N.JSON.stringify;function Ae(t){if(this.f=0,this.m=void 0,this.i=this.g=this.h=null,this.j=this.l=!1,t!=O)try{var e=this;t.call(void 0,function(t){Ue(e,2,t)},function(t){Ue(e,3,t)})}catch(t){Ue(this,3,t)}}function ke(){this.next=this.context=this.onRejected=this.g=this.f=null,this.h=!1}ke.prototype.reset=function(){this.context=this.onRejected=this.g=this.f=null,this.h=!1};var Re=new se(function(){return new ke},function(t){t.reset()});function je(t,e,n){var r=Re.get();return r.g=t,r.onRejected=e,r.context=n,r}function Ce(t){if(t instanceof Ae)return t;var e=new Ae(O);return Ue(e,2,t),e}function Le(t){return new Ae(function(e,n){n(t)})}function Pe(t,e){return Me(t,null,e,void 0)}function De(t,e){t.g||2!=t.f&&3!=t.f||Be(t),t.i?t.i.next=e:t.g=e,t.i=e}function Me(t,e,n,r){var i=je(null,null,null);return i.f=new Ae(function(t,o){i.g=e?function(n){try{var i=e.call(r,n);t(i)}catch(t){o(t)}}:t,i.onRejected=n?function(e){try{var i=n.call(r,e);void 0===i&&e instanceof Ge?o(e):t(i)}catch(t){o(t)}}:o}),i.f.h=t,De(t,i),i.f}function Ue(t,e,n){if(0==t.f){t===n&&(e=3,n=new TypeError("Promise cannot resolve to itself")),t.f=1;t:{var r=n,i=t.A,o=t.G;if(r instanceof Ae){De(r,je(i||O,o||null,t));var a=!0}else{if(r)try{var s=!!r.$goog_Thenable}catch(t){s=!1}else s=!1;if(s)r.then(i,o,t),a=!0;else{if(j(r))try{var u=r.then;if(R(u)){!function(t,e,n,r,i){function o(t){a||(a=!0,r.call(i,t))}var a=!1;try{e.call(t,function(t){a||(a=!0,n.call(i,t))},o)}catch(t){o(t)}}(r,u,i,o,t),a=!0;break t}}catch(e){o.call(t,e),a=!0;break t}a=!1}}}a||(t.m=n,t.f=e,t.h=null,Be(t),3!=e||n instanceof Ge||function(t,e){t.j=!0,pe(function(){t.j&&Ve.call(null,e)})}(t,n))}}function Be(t){t.l||(t.l=!0,pe(t.s,t))}function Ye(t){var e=null;return t.g&&(e=t.g,t.g=e.next,e.next=null),t.g||(t.i=null),e}function Xe(t,e,n,r){if(3==n&&e.onRejected&&!e.h)for(;t&&t.j;t=t.h)t.j=!1;if(e.f)e.f.h=null,qe(e,n,r);else try{e.h?e.g.call(e.context):qe(e,n,r)}catch(t){Ve.call(null,t)}ue(Re,e)}function qe(t,e,n){2==e?t.g.call(t.context,n):t.onRejected&&t.onRejected.call(t.context,n)}Ae.prototype.then=function(t,e,n){return Me(this,R(t)?t:null,R(e)?e:null,n)},Ae.prototype.$goog_Thenable=!0,Ae.prototype.cancel=function(t){if(0==this.f){var e=new Ge(t);pe(function(){!function t(e,n){if(0==e.f)if(e.h){var r=e.h;if(r.g){for(var i=0,o=null,a=null,s=r.g;s&&(s.h||(i++,s.f==e&&(o=s),!(o&&1<i)));s=s.next)o||(a=s);o&&(0==r.f&&1==i?t(r,n):(a?((i=a).next==r.i&&(r.i=i),i.next=i.next.next):Ye(r),Xe(r,o,3,n)))}e.h=null}else Ue(e,3,n)}(this,e)},this)}},Ae.prototype.A=function(t){this.f=0,Ue(this,2,t)},Ae.prototype.G=function(t){this.f=0,Ue(this,3,t)},Ae.prototype.s=function(){for(var t;t=Ye(this);)Xe(this,t,this.f,this.m);this.l=!1};var Ve=ce;function Ge(t){G.call(this,t)}function Fe(t){Qt.call(this),this.m=1,this.j=[],this.l=0,this.f=[],this.g={},this.s=!!t}function We(t,e,n){pe(function(){t.apply(e,n)})}function Ke(t){this.f=t}function ze(t){this.f=t}function He(t){this.data=t}function Je(t){return void 0===t||t instanceof He?t:new He(t)}function Qe(t){this.f=t}function Ze(){}function $e(t){this.f=t}function tn(){var t=null;try{t=window.localStorage||null}catch(t){}this.f=t}function en(t,e){if(this.g=t,this.f=null,yt&&!(9<=Number(Ot))){rn||(rn=new Ie),this.f=rn.get(t),this.f||(e?this.f=document.getElementById(e):(this.f=document.createElement("userdata"),this.f.addBehavior("#default#userData"),document.body.appendChild(this.f)),rn.set(t,this.f));try{this.f.load(this.g)}catch(t){this.f=null}}}X(Ge,G),Ge.prototype.name="cancel",X(Fe,Qt),(t=Fe.prototype).subscribe=function(t,e,n){var r=this.g[t];r||(r=this.g[t]=[]);var i=this.m;return this.f[i]=t,this.f[i+1]=e,this.f[i+2]=n,this.m=i+3,r.push(i),i},t.L=function(t){var e=this.f[t];if(e){var n=this.g[e];if(0!=this.l)this.j.push(t),this.f[t+1]=O;else{if(n){var r=F(n,t);0<=r&&Array.prototype.splice.call(n,r,1)}delete this.f[t],delete this.f[t+1],delete this.f[t+2]}}return!!e},t.J=function(t,e){var n=this.g[t];if(n){for(var r=Array(arguments.length-1),i=1,o=arguments.length;i<o;i++)r[i-1]=arguments[i];if(this.s)for(i=0;i<n.length;i++){var a=n[i];We(this.f[a+1],this.f[a+2],r)}else{this.l++;try{for(i=0,o=n.length;i<o;i++)a=n[i],this.f[a+1].apply(this.f[a+2],r)}finally{if(this.l--,0<this.j.length&&0==this.l)for(;n=this.j.pop();)this.L(n)}}return 0!=i}return!1},t.clear=function(t){if(t){var e=this.g[t];e&&(W(e,this.L,this),delete this.g[t])}else this.f.length=0,this.g={}},t.O=function(){Fe.F.O.call(this),this.clear(),this.j.length=0},Ke.prototype.set=function(t,e){void 0===e?this.f.remove(t):this.f.set(t,Oe(e))},Ke.prototype.get=function(t){try{var e=this.f.get(t)}catch(t){return}if(null!==e)try{return JSON.parse(e)}catch(t){throw"Storage: Invalid value was encountered"}},Ke.prototype.remove=function(t){this.f.remove(t)},X(ze,Ke),ze.prototype.set=function(t,e){ze.F.set.call(this,t,Je(e))},ze.prototype.g=function(t){if(void 0===(t=ze.F.get.call(this,t))||t instanceof Object)return t;throw"Storage: Invalid value was encountered"},ze.prototype.get=function(t){if(t=this.g(t)){if(void 0===(t=t.data))throw"Storage: Invalid value was encountered"}else t=void 0;return t},X(Qe,ze),Qe.prototype.set=function(t,e,n){if(e=Je(e)){if(n){if(n<B())return void Qe.prototype.remove.call(this,t);e.expiration=n}e.creation=B()}Qe.F.set.call(this,t,e)},Qe.prototype.g=function(t){var e=Qe.F.g.call(this,t);if(e){var n=e.creation,r=e.expiration;if(!(r&&r<B()||n&&n>B()))return e;Qe.prototype.remove.call(this,t)}},X(Ze,function(){}),Ze.prototype.clear=function(){var t=Se(this.B(!0)),e=this;W(t,function(t){e.remove(t)})},X($e,Ze),(t=$e.prototype).isAvailable=function(){if(!this.f)return!1;try{return this.f.setItem("__sak","1"),this.f.removeItem("__sak"),!0}catch(t){return!1}},t.set=function(t,e){try{this.f.setItem(t,e)}catch(t){if(0==this.f.length)throw"Storage mechanism: Storage disabled";throw"Storage mechanism: Quota exceeded"}},t.get=function(t){if("string"!=typeof(t=this.f.getItem(t))&&null!==t)throw"Storage mechanism: Invalid value was encountered";return t},t.remove=function(t){this.f.removeItem(t)},t.B=function(t){var e=0,n=this.f,r=new Ee;return r.next=function(){if(e>=n.length)throw be;var r=n.key(e++);if(t)return r;if("string"!=typeof(r=n.getItem(r)))throw"Storage mechanism: Invalid value was encountered";return r},r},t.clear=function(){this.f.clear()},t.key=function(t){return this.f.key(t)},X(tn,$e),X(en,Ze);var nn={".":".2E","!":".21","~":".7E","*":".2A","'":".27","(":".28",")":".29","%":"."},rn=null;function on(t){return"_"+encodeURIComponent(t).replace(/[.!~*'()%]/g,function(t){return nn[t]})}function an(t){try{t.f.save(t.g)}catch(t){throw"Storage mechanism: Quota exceeded"}}function sn(t,e){this.g=t,this.f=e+"::"}(t=en.prototype).isAvailable=function(){return!!this.f},t.set=function(t,e){this.f.setAttribute(on(t),e),an(this)},t.get=function(t){if("string"!=typeof(t=this.f.getAttribute(on(t)))&&null!==t)throw"Storage mechanism: Invalid value was encountered";return t},t.remove=function(t){this.f.removeAttribute(on(t)),an(this)},t.B=function(t){var e=0,n=this.f.XMLDocument.documentElement.attributes,r=new Ee;return r.next=function(){if(e>=n.length)throw be;var r=n[e++];if(t)return decodeURIComponent(r.nodeName.replace(/\./g,"%")).substr(1);if("string"!=typeof(r=r.nodeValue))throw"Storage mechanism: Invalid value was encountered";return r},r},t.clear=function(){for(var t=this.f.XMLDocument.documentElement,e=t.attributes.length;0<e;e--)t.removeAttribute(t.attributes[e-1].nodeName);an(this)},X(sn,Ze),sn.prototype.set=function(t,e){this.g.set(this.f+t,e)},sn.prototype.get=function(t){return this.g.get(this.f+t)},sn.prototype.remove=function(t){this.g.remove(this.f+t)},sn.prototype.B=function(t){var e=this.g.B(!0),n=this,r=new Ee;return r.next=function(){for(var r=e.next();r.substr(0,n.f.length)!=n.f;)r=e.next();return t?r.substr(n.f.length):n.g.get(r)},r};var un=window.yt&&window.yt.config_||window.ytcfg&&window.ytcfg.data_||{};function cn(t){var e=arguments;1<e.length?un[e[0]]=e[1]:1===e.length&&Object.assign(un,e[0])}function fn(t,e){return t in un?un[t]:e}Y("yt.config_",un);var ln=[];function hn(t){return t&&window.yterr?function(){try{return t.apply(this,arguments)}catch(t){dn(t),function(t){ln.forEach(function(e){return e(t)})}(t)}}:t}function dn(t){var e=x("yt.logging.errors.log");e?e(t,"ERROR",void 0,void 0,void 0):((e=fn("ERRORS",[])).push([t,"ERROR",void 0,void 0,void 0]),cn("ERRORS",e))}function pn(t){var e=x("yt.logging.errors.log");e?e(t,"WARNING",void 0,void 0,void 0):((e=fn("ERRORS",[])).push([t,"WARNING",void 0,void 0,void 0]),cn("ERRORS",e))}var vn=0;Y("ytDomDomGetNextId",x("ytDomDomGetNextId")||function(){return++vn});var gn={stopImmediatePropagation:1,stopPropagation:1,preventMouseEvent:1,preventManipulation:1,preventDefault:1,layerX:1,layerY:1,screenX:1,screenY:1,scale:1,rotation:1,webkitMovementX:1,webkitMovementY:1};function yn(t){this.type="",this.state=this.source=this.data=this.currentTarget=this.relatedTarget=this.target=null,this.charCode=this.keyCode=0,this.metaKey=this.shiftKey=this.ctrlKey=this.altKey=!1,this.clientY=this.clientX=0,this.changedTouches=this.touches=null;try{if(t=t||window.event){for(var e in this.event=t,t)e in gn||(this[e]=t[e]);var n=t.target||t.srcElement;n&&3==n.nodeType&&(n=n.parentNode),this.target=n;var r=t.relatedTarget;if(r)try{r=r.nodeName?r:null}catch(t){r=null}else"mouseover"==this.type?r=t.fromElement:"mouseout"==this.type&&(r=t.toElement);this.relatedTarget=r,this.clientX=null!=t.clientX?t.clientX:t.pageX,this.clientY=null!=t.clientY?t.clientY:t.pageY,this.keyCode=t.keyCode?t.keyCode:t.which,this.charCode=t.charCode||("keypress"==this.type?this.keyCode:0),this.altKey=t.altKey,this.ctrlKey=t.ctrlKey,this.shiftKey=t.shiftKey,this.metaKey=t.metaKey}}catch(t){}}yn.prototype.preventDefault=function(){this.event&&(this.event.returnValue=!1,this.event.preventDefault&&this.event.preventDefault())},yn.prototype.stopPropagation=function(){this.event&&(this.event.cancelBubble=!0,this.event.stopPropagation&&this.event.stopPropagation())},yn.prototype.stopImmediatePropagation=function(){this.event&&(this.event.cancelBubble=!0,this.event.stopImmediatePropagation&&this.event.stopImmediatePropagation())};var mn=N.ytEventsEventsListeners||{};Y("ytEventsEventsListeners",mn);var wn=N.ytEventsEventsCounter||{count:0};function bn(t,e,n,r){return r=void 0===r?{}:r,t.addEventListener&&("mouseenter"!=e||"onmouseenter"in document?"mouseleave"!=e||"onmouseenter"in document?"mousewheel"==e&&"MozBoxSizing"in document.documentElement.style&&(e="MozMousePixelScroll"):e="mouseout":e="mouseover"),function(t){var e,n=mn;for(e in n)if(t.call(void 0,n[e],e,n))return e}(function(i){var o="boolean"==typeof i[4]&&i[4]==!!r,a=j(i[4])&&j(r)&&Q(i[4],r);return!!i.length&&i[0]==t&&i[1]==e&&i[2]==n&&(o||a)})}function En(t){t&&("string"==typeof t&&(t=[t]),W(t,function(t){if(t in mn){var e=mn[t],n=e[0],r=e[1],i=e[3];e=e[4],n.removeEventListener?_n()||"boolean"==typeof e?n.removeEventListener(r,i,e):n.removeEventListener(r,i,!!e.capture):n.detachEvent&&n.detachEvent("on"+r,i),delete mn[t]}}))}Y("ytEventsEventsCounter",wn);var _n=J(function(){var t=!1;try{var e=Object.defineProperty({},"capture",{get:function(){t=!0}});window.addEventListener("test",null,e)}catch(t){}return t});function Sn(t,e,n){var r=void 0===r?{}:r;if(t&&(t.addEventListener||t.attachEvent)){var i=bn(t,e,n,r);if(!i){i=++wn.count+"";var o=!("mouseenter"!=e&&"mouseleave"!=e||!t.addEventListener||"onmouseenter"in document),a=o?function(r){if(!function(t,e){for(;t;){if(e(t))return t;t=t.parentNode}return null}((r=new yn(r)).relatedTarget,function(e){return e==t}))return r.currentTarget=t,r.type=e,n.call(t,r)}:function(e){return(e=new yn(e)).currentTarget=t,n.call(t,e)};a=hn(a),t.addEventListener?("mouseenter"==e&&o?e="mouseover":"mouseleave"==e&&o?e="mouseout":"mousewheel"==e&&"MozBoxSizing"in document.documentElement.style&&(e="MozMousePixelScroll"),_n()||"boolean"==typeof r?t.addEventListener(e,a,r):t.addEventListener(e,a,!!r.capture)):t.attachEvent("on"+e,a),mn[i]=[t,e,n,a,r]}}}function In(t,e){return"function"==typeof t&&(t=hn(t)),window.setTimeout(t,e)}function Tn(t){return"function"==typeof t&&(t=hn(t)),window.setInterval(t,250)}function Nn(t){var e=[];return function(t,e){for(var n in t)e.call(void 0,t[n],n,t)}(t,function(t,n){var r,i=encodeURIComponent(String(n));r=Array.isArray(t)?t:[t],W(r,function(t){""==t?e.push(i):e.push(i+"="+encodeURIComponent(String(t)))})}),e.join("&")}function xn(t){"?"==t.charAt(0)&&(t=t.substr(1));for(var e={},n=0,r=(t=t.split("&")).length;n<r;n++){var i=t[n].split("=");if(1==i.length&&i[0]||2==i.length)try{var o=decodeURIComponent((i[0]||"").replace(/\+/g," ")),a=decodeURIComponent((i[1]||"").replace(/\+/g," "));o in e?Array.isArray(e[o])?H(e[o],a):e[o]=[e[o],a]:e[o]=a}catch(t){if("q"!=i[0]){var s=Error("Error decoding URL component");s.params={key:i[0],value:i[1]},dn(s)}}}return e}function On(t,e,n){var r=t.split("#",2);t=r[0],r=1<r.length?"#"+r[1]:"";var i=t.split("?",2);for(var o in t=i[0],i=xn(i[1]||""),e)!n&&null!==i&&o in i||(i[o]=e[o]);return e=t,(t=Wt(i))?(0>(n=e.indexOf("#"))&&(n=e.length),0>(o=e.indexOf("?"))||o>n?(o=n,i=""):i=e.substring(o+1,n),n=(e=[e.substr(0,o),i,e.substr(n)])[1],e[1]=t?n?n+"&"+t:t:n,t=e[0]+(e[1]?"?"+e[1]:"")+e[2]):t=e,t+r}var An={};var kn={},Rn=[],jn=new Fe,Cn={};function Ln(){for(var t=a(Rn),e=t.next();!e.done;e=t.next())(e=e.value)()}function Pn(t,e){e||(e=document);var n=z(e.getElementsByTagName("yt:"+t)),r="yt-"+t,i=e||document;return r=i.querySelectorAll&&i.querySelector?i.querySelectorAll("."+r):function(t,e){var n,r,i=document;if((i=e||i).querySelectorAll&&i.querySelector&&t)return i.querySelectorAll(t?"."+t:"");if(t&&i.getElementsByClassName){var o=i.getElementsByClassName(t);return o}if(o=i.getElementsByTagName("*"),t){var a={};for(n=r=0;i=o[n];n++){var s,u=i.className;(s="function"==typeof u.split)&&(s=0<=F(u.split(/\s+/),t)),s&&(a[r++]=i)}return a.length=r,a}return o}(r,e),function(t){return Array.prototype.concat.apply([],arguments)}(n,r=z(r))}function Dn(t,e){return"yt:"==t.tagName.toLowerCase().substr(0,3)?t.getAttribute(e):t?t.dataset?t.dataset[function(t){return An[t]||(An[t]=String(t).replace(/\-([a-z])/g,function(t,e){return e.toUpperCase()}))}(e)]:t.getAttribute("data-"+e):null}function Mn(t){if(this.g=t||{},this.h=this.f=!1,t=document.getElementById("www-widgetapi-script"),this.f=!!("https:"==document.location.protocol||t&&0==t.src.indexOf("https:"))){t=[this.g,window.YTConfig||{}];for(var e=0;e<t.length;e++)t[e].host&&(t[e].host=t[e].host.replace("http://","https://"))}}function Un(t,e){for(var n=[t.g,window.YTConfig||{}],r=0;r<n.length;r++){var i=n[r][e];if(null!=i)return i}return null}Mn.prototype.i=function(t){if(t.origin==Un(this,"host")||t.origin==Un(this,"host").replace(/^http:/,"https:")){try{var e=JSON.parse(t.data)}catch(t){return}this.h=!0,this.f||0!=t.origin.indexOf("https:")||(this.f=!0),(t=Bn[e.id])&&(t.s=!0,t.s&&(W(t.m,t.S,t),t.m.length=0),t.ba(e))}};var Bn=null;function Yn(t){return("string"!=typeof(t=qn(t))||"false"!==t)&&!!t}function Xn(t,e){var n=qn(t);return void 0===n&&void 0!==e?e:Number(n||0)}function qn(t){var e=fn("EXPERIMENTS_FORCED_FLAGS",{});return void 0!==e[t]?e[t]:fn("EXPERIMENT_FLAGS",{})[t]}function Vn(t,e){return Fn(t,0,e)}function Gn(){}function Fn(t,e,n){isNaN(n)&&(n=void 0);var r=x("yt.scheduler.instance.addJob");return r?r(t,e,n):void 0===n?(t(),NaN):In(t,n||0)}h(Gn,function(){}),Gn.prototype.start=function(){var t=x("yt.scheduler.instance.start");t&&t()},Gn.f=void 0,Gn.g=function(){Gn.f||(Gn.f=new Gn)},Gn.g();var Wn=N.ytPubsubPubsubInstance||new Fe,Kn=N.ytPubsubPubsubSubscribedKeys||{},zn=N.ytPubsubPubsubTopicToKeys||{},Hn=N.ytPubsubPubsubIsSynchronous||{};Fe.prototype.subscribe=Fe.prototype.subscribe,Fe.prototype.unsubscribeByKey=Fe.prototype.L,Fe.prototype.publish=Fe.prototype.J,Fe.prototype.clear=Fe.prototype.clear,Y("ytPubsubPubsubInstance",Wn),Y("ytPubsubPubsubTopicToKeys",zn),Y("ytPubsubPubsubIsSynchronous",Hn),Y("ytPubsubPubsubSubscribedKeys",Kn);var Jn=window,Qn=Jn.ytcsi&&Jn.ytcsi.now?Jn.ytcsi.now:Jn.performance&&Jn.performance.timing&&Jn.performance.now&&Jn.performance.timing.navigationStart?function(){return Jn.performance.timing.navigationStart+Jn.performance.now()}:function(){return(new Date).getTime()},Zn=Xn("initial_gel_batch_timeout",1e3),$n=Math.pow(2,16)-1,tr=null,er=0,nr=void 0,rr=0,ir=0,or=0,ar=!0,sr=N.ytLoggingTransportLogPayloadsQueue_||{};Y("ytLoggingTransportLogPayloadsQueue_",sr);var ur=N.ytLoggingTransportGELQueue_||new Map;Y("ytLoggingTransportGELQueue_",ur);var cr=N.ytLoggingTransportTokensToCttTargetIds_||{};function fr(){window.clearTimeout(rr),window.clearTimeout(ir),ir=0,nr&&nr.isReady()?(hr(ur),"log_event"in sr&&hr(Object.entries(sr.log_event)),ur.clear(),delete sr.log_event):lr()}function lr(){Yn("web_gel_timeout_cap")&&!ir&&(ir=In(fr,6e4)),window.clearTimeout(rr);var t=fn("LOGGING_BATCH_TIMEOUT",Xn("web_gel_debounce_ms",1e4));Yn("shorten_initial_gel_batch_timeout")&&ar&&(t=Zn),rr=In(fr,t)}function hr(t){for(var e=nr,n=Math.round(Qn()),r=(t=a(t)).next();!r.done;r=t.next()){var i=a(r.value);r=i.next().value;var o=i.next().value;(i=Z({context:Or(e.f||xr())})).events=o,(o=cr[r])&&pr(i,r,o),delete cr[r],dr(i,n),Pi(e,"log_event",i,{retry:!0,onSuccess:function(){er=Math.round(Qn()-n)}}),ar=!1}}function dr(t,e){t.requestTimeMs=String(e),Yn("unsplit_gel_payloads_in_logs")&&(t.unsplitGelPayloadsInLogs=!0);var n=fn("EVENT_ID",void 0);if(n){var r=fn("BATCH_CLIENT_COUNTER",void 0)||0;!r&&Yn("web_client_counter_random_seed")&&(r=Math.floor(Math.random()*$n/2)),++r>$n&&(r=1),cn("BATCH_CLIENT_COUNTER",r),n={serializedEventId:n,clientCounter:String(r)},t.serializedClientEventId=n,tr&&er&&Yn("log_gel_rtt_web")&&(t.previousBatchInfo={serializedClientEventId:tr,roundtripMs:String(er)}),tr=n,er=0}}function pr(t,e,n){if(n.videoId)var r="VIDEO";else{if(!n.playlistId)return;r="PLAYLIST"}t.credentialTransferTokenTargetId=n,t.context=t.context||{},t.context.user=t.context.user||{},t.context.user.credentialTransferTokens=[{token:e,scope:r}]}Y("ytLoggingTransportTokensToCttTargetIds_",cr);var vr=N.ytLoggingGelSequenceIdObj_||{};function gr(t){var e=yr;return t=void 0===t?x("yt.ads.biscotti.lastId_")||"":t,(e=Object.assign(function(t){var e={};e.dt=ee,e.flash="0";t:{try{var n=t.f.top.location.href}catch(e){t=2;break t}t=n?n===t.g.location.href?0:1:2}(e.frm=t,e=e).u_tz=-(new Date).getTimezoneOffset();var r=void 0===r?Ct:r;try{var i=r.history.length}catch(t){i=0}return e.u_his=i,e.u_java=!!Ct.navigator&&"unknown"!=typeof Ct.navigator.javaEnabled&&!!Ct.navigator.javaEnabled&&Ct.navigator.javaEnabled(),Ct.screen&&(e.u_h=Ct.screen.height,e.u_w=Ct.screen.width,e.u_ah=Ct.screen.availHeight,e.u_aw=Ct.screen.availWidth,e.u_cd=Ct.screen.colorDepth),Ct.navigator&&Ct.navigator.plugins&&(e.u_nplug=Ct.navigator.plugins.length),Ct.navigator&&Ct.navigator.mimeTypes&&(e.u_nmime=Ct.navigator.mimeTypes.length),e}(e),function(t){var e=t.f;try{var n=e.screenX,r=e.screenY}catch(t){}try{var i=e.outerWidth,o=e.outerHeight}catch(t){}try{var a=e.innerWidth,s=e.innerHeight}catch(t){}e=[e.screenLeft,e.screenTop,n,r,e.screen?e.screen.availWidth:void 0,e.screen?e.screen.availTop:void 0,i,o,a,s],n=t.f.top;try{var u=(n||window).document,c="CSS1Compat"==u.compatMode?u.documentElement:u.body,f=new Bt(c.clientWidth,c.clientHeight).round()}catch(t){f=new Bt(-12245933,-12245933)}return u=f,f={},c=new ae,N.SVGElement&&N.document.createElementNS&&c.set(0),(n=function(){var t=Yt(),e={};return W(Jt(),function(n){t.sandbox&&t.sandbox.supports&&t.sandbox.supports(n)&&(e[n]=!0)}),e}())["allow-top-navigation-by-user-activation"]&&c.set(1),n["allow-popups-to-escape-sandbox"]&&c.set(2),N.crypto&&N.crypto.subtle&&c.set(3),N.TextDecoder&&N.TextEncoder&&c.set(4),c=function(t){return-1==t.f&&(t.f=K(t.g,function(t,e,n){return e?t+Math.pow(2,n):t},0)),t.f}(c),f.bc=c,f.bih=u.height,f.biw=u.width,f.brdim=e.join(),t=t.g,f.vis={visible:1,hidden:2,prerender:3,preview:4,unloaded:5}[t.visibilityState||t.webkitVisibilityState||t.mozVisibilityState||""]||0,f.wgl=!!Ct.WebGLRenderingContext,f}(e))).ca_type="image",t&&(e.bid=t),e}Y("ytLoggingGelSequenceIdObj_",vr);var yr=new function(){var t=window.document;this.f=window,this.g=t};Y("yt.ads_.signals_.getAdSignalsString",function(t){return Nn(gr(t))}),B();var mr="XMLHttpRequest"in N?function(){return new XMLHttpRequest}:null;var wr,br={Authorization:"AUTHORIZATION","X-Goog-Visitor-Id":"SANDBOXED_VISITOR_ID","X-YouTube-Client-Name":"INNERTUBE_CONTEXT_CLIENT_NAME","X-YouTube-Client-Version":"INNERTUBE_CONTEXT_CLIENT_VERSION","X-YouTube-Device":"DEVICE","X-Youtube-Identity-Token":"ID_TOKEN","X-YouTube-Page-CL":"PAGE_CL","X-YouTube-Page-Label":"PAGE_BUILD_LABEL","X-YouTube-Variants-Checksum":"VARIANTS_CHECKSUM"},Er="app debugcss debugjs expflag force_ad_params force_viral_ad_response_params forced_experiments innertube_snapshots innertube_goldens internalcountrycode internalipoverride absolute_experiments conditional_experiments sbb sr_bns_address".split(" "),_r=!1;function Sr(t,e){var n=e.format||"JSON",r=Tr(t=Ir(t,e),e),i=!1,o=function(t,e,n,r,i,o,a){function s(){4==(u&&"readyState"in u?u.readyState:0)&&e&&hn(e)(u)}n=void 0===n?"GET":n,r=void 0===r?"":r;var u=function(){if(!mr)return null;var t=mr();return"open"in t?t:null}();if(!u)return null;if("onloadend"in u?u.addEventListener("loadend",s,!1):u.onreadystatechange=s,Yn("debug_forward_web_query_parameters")&&(t=function(t){var e=window.location.search,n=Vt(t),r=qt(t.match(Xt)[5]||null);if(r=(n=n&&(n.endsWith("youtube.com")||n.endsWith("youtube-nocookie.com")))&&r&&r.startsWith("/api/"),!n||r)return t;var i=xn(e),o={};return W(Er,function(t){i[t]&&(o[t]=i[t])}),On(t,o||{},!1)}(t)),u.open(n,t,!0),o&&(u.responseType=o),a&&(u.withCredentials=!0),n=!("POST"!=n||void 0!==window.FormData&&r instanceof FormData),i=function(t,e){if(e=void 0===e?{}:e,!n)var n=window.location.href;var r=t.match(Xt)[1]||null,i=Vt(t);for(var o in r&&i?(r=n,n=t.match(Xt),r=r.match(Xt),n=n[3]==r[3]&&n[1]==r[1]&&n[4]==r[4]):n=!i||Vt(n)==i&&(Number(n.match(Xt)[4]||null)||null)==(Number(t.match(Xt)[4]||null)||null),r=Yn("web_ajax_ignore_global_headers_if_set"),br)!(i=fn(br[o]))||!n&&Vt(t)||r&&void 0!==e[o]||(e[o]=i);return!n&&Vt(t)||(e["X-YouTube-Utc-Offset"]=String(-(new Date).getTimezoneOffset())),(n||!Vt(t))&&(o="undefined"!=typeof Intl?(new Intl.DateTimeFormat).resolvedOptions().timeZone:null)&&(e["X-YouTube-Time-Zone"]=o),!n&&Vt(t)||(e["X-YouTube-Ad-Signals"]=Nn(gr(void 0))),e}(t,i))for(var c in i)u.setRequestHeader(c,i[c]),"content-type"==c.toLowerCase()&&(n=!1);return n&&u.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),u.send(r),u}(t,function(r){if(!i){i=!0,s&&window.clearTimeout(s);t:switch(r&&"status"in r?r.status:-1){case 200:case 201:case 202:case 203:case 204:case 205:case 206:case 304:var o=!0;break t;default:o=!1}var a=null,u=400<=r.status&&500>r.status,c=500<=r.status&&600>r.status;if((o||u||c)&&(a=function(t,e,n,r){var i=null;switch(e){case"JSON":try{var o=n.responseText}catch(e){throw(r=Error("Error reading responseText")).params=t,pn(r),e}t=n.getResponseHeader("Content-Type")||"",o&&0<=t.indexOf("json")&&(i=JSON.parse(o));break;case"XML":(t=(t=n.responseXML)?function(t){return t&&(t=("responseXML"in t?t.responseXML:t).getElementsByTagName("root"))&&0<t.length?t[0]:null}(t):null)&&(i={},W(t.getElementsByTagName("*"),function(t){var e;i[t.tagName]=(e="",W(t.childNodes,function(t){e+=t.nodeValue}),e)}))}return r&&function t(e){if(j(e))for(var n in e){var r;if((r="html_content"==n)||(r=0<=(r=n.length-5)&&n.indexOf("_html",r)==r),r){r=n;var i=e[n];if(void 0===$){var o=null,a=N.trustedTypes;if(a&&a.createPolicy){try{o=a.createPolicy("goog#html",{createHTML:q,createScript:q,createScriptURL:q})}catch(t){N.console&&N.console.error(t.message)}$=o}else $=o}(o=$)&&o.createHTML(i),e[r]=new dt}else t(e[n])}}(i),i}(t,n,r,e.Ea)),o)t:if(r&&204==r.status)o=!0;else{switch(n){case"XML":o=0==parseInt(a&&a.return_code,10);break t;case"RAW":o=!0;break t}o=!!a}a=a||{},u=e.context||N,o?e.onSuccess&&e.onSuccess.call(u,r,a):e.onError&&e.onError.call(u,r,a),e.P&&e.P.call(u,r,a)}},e.method,r,e.headers,e.responseType,e.withCredentials);if(e.I&&0<e.timeout)var a=e.I,s=In(function(){i||(i=!0,o.abort(),window.clearTimeout(s),a.call(e.context||N,o))},e.timeout)}function Ir(t,e){e.Ia&&(t=document.location.protocol+"//"+document.location.hostname+(document.location.port?":"+document.location.port:"")+t);var n=fn("XSRF_FIELD_NAME",void 0),r=e.oa;return r&&(r[n]&&delete r[n],t=On(t,r||{},!0)),t}function Tr(t,e){var n,r=fn("XSRF_FIELD_NAME",void 0),i=fn("XSRF_TOKEN",void 0),o=e.postBody||"",a=e.u,s=fn("XSRF_FIELD_NAME",void 0);if(e.headers&&(n=e.headers["Content-Type"]),e.Ha||Vt(t)&&!e.withCredentials&&Vt(t)!=document.location.hostname||"POST"!=e.method||n&&"application/x-www-form-urlencoded"!=n||e.u&&e.u[s]||(a||(a={}),a[r]=i),a&&"string"==typeof o&&(function(t,e){for(var n,r,i=1;i<arguments.length;i++){for(n in r=arguments[i])t[n]=r[n];for(var o=0;o<tt.length;o++)n=tt[o],Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}}(o=xn(o),a),o=e.aa&&"JSON"==e.aa?JSON.stringify(o):Wt(o)),!(r=o)&&(r=a)){t:{for(var u in a){a=!1;break t}a=!0}r=!a}return!_r&&r&&"POST"!=e.method&&(_r=!0,dn(Error("AJAX request with postData should use POST"))),o}function Nr(){return"INNERTUBE_API_KEY"in un&&"INNERTUBE_API_VERSION"in un}function xr(){return{innertubeApiKey:fn("INNERTUBE_API_KEY",void 0),innertubeApiVersion:fn("INNERTUBE_API_VERSION",void 0),ga:fn("INNERTUBE_CONTEXT_CLIENT_CONFIG_INFO"),ha:fn("INNERTUBE_CONTEXT_CLIENT_NAME","WEB"),innertubeContextClientVersion:fn("INNERTUBE_CONTEXT_CLIENT_VERSION",void 0),ja:fn("INNERTUBE_CONTEXT_HL",void 0),ia:fn("INNERTUBE_CONTEXT_GL",void 0),ka:fn("INNERTUBE_HOST_OVERRIDE",void 0)||"",ma:!!fn("INNERTUBE_USE_THIRD_PARTY_AUTH",!1),la:!!fn("INNERTUBE_OMIT_API_KEY_WHEN_AUTH_HEADER_IS_PRESENT",!1)}}function Or(t){t={client:{hl:t.ja,gl:t.ia,clientName:t.ha,clientVersion:t.innertubeContextClientVersion,configInfo:t.ga}};var e=window.devicePixelRatio;e&&1!=e&&(t.client.screenDensityFloat=String(e)),""!==(e=fn("EXPERIMENTS_TOKEN",""))&&(t.client.experimentsToken=e),e=[];var n=fn("EXPERIMENTS_FORCED_FLAGS",{});for(r in n)e.push({key:r,value:String(n[r])});var r=fn("EXPERIMENT_FLAGS",{});for(var i in r)i.startsWith("force_")&&void 0===n[i]&&e.push({key:i,value:String(r[i])});return 0<e.length&&(t.request={internalExperimentFlags:e}),fn("DELEGATED_SESSION_ID")&&!Yn("pageid_as_header_web")&&(t.user={onBehalfOfUser:fn("DELEGATED_SESSION_ID")}),t.client=Object.assign(t.client,function(){for(var t={},e=a(Object.entries(xn(fn("DEVICE","")))),n=e.next();!n.done;n=e.next()){var r=a(n.value);n=r.next().value,r=r.next().value,"cbrand"===n?t.deviceMake=r:"cmodel"===n?t.deviceModel=r:"cbr"===n?t.browserName=r:"cbrver"===n?t.browserVersion=r:"cos"===n?t.osName=r:"cosver"===n?t.osVersion=r:"cplatform"===n&&(t.platform=r)}return t}()),t}function Ar(t,e,n){var r={"X-Goog-Visitor-Id":(n=void 0===n?{}:n).visitorData||fn("VISITOR_DATA","")};return e&&e.includes("www.youtube-nocookie.com")?r:((e=n.Ca||fn("AUTHORIZATION"))||(e=t?"Bearer "+x("gapi.auth.getToken")().Ba:oe([])),e&&(r.Authorization=e,r["X-Goog-AuthUser"]=fn("SESSION_INDEX",0),Yn("pageid_as_header_web")&&(r["X-Goog-PageId"]=fn("DELEGATED_SESSION_ID"))),r)}function kr(t){delete(t=Object.assign({},t)).Authorization;var e=oe();if(e){var n=new me;if(n.update(fn("INNERTUBE_API_KEY",void 0)),n.update(e),e=n.digest(),n=3,k(e),void 0===n&&(n=0),!jt){jt={};for(var r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789".split(""),i=["+/=","+/","-_=","-_.","-_"],o=0;5>o;o++){var a=r.concat(i[o].split(""));Rt[o]=a;for(var s=0;s<a.length;s++){var u=a[s];void 0===jt[u]&&(jt[u]=s)}}}for(n=Rt[n],r=[],i=0;i<e.length;i+=3){var c=e[i],f=(o=i+1<e.length)?e[i+1]:0;s=c>>2,c=(3&c)<<4|f>>4,f=(15&f)<<2|(u=(a=i+2<e.length)?e[i+2]:0)>>6,u&=63,a||(u=64,o||(f=64)),r.push(n[s],n[c],n[f]||"",n[u]||"")}t.hash=r.join("")}return t}function Rr(){var t=new tn;(t=t.isAvailable()?new sn(t,"yt.innertube"):null)||(t=(t=new en("yt.innertube")).isAvailable()?t:null),this.f=t?new Qe(t):null,this.g=document.domain||window.location.hostname}function jr(){return wr||(wr=new Rr),wr}function Cr(t){var e=jr().get("requests",!0)||{};delete e[t],jr().set("requests",e,86400,!0)}function Lr(t){var e=jr().get("requests",!0);if(e){for(var n in e){var r=e[n];if(!(6e4>Math.round(Qn())-r.requestTime)){var i=r.authState;Q(i,kr(Ar(!1)))&&("requestTimeMs"in(i=r.request)&&(i.requestTimeMs=Math.round(Qn())),Pi(t,r.method,i,{})),delete e[n]}}jr().set("requests",e,86400,!0)}}function Pr(){}Rr.prototype.set=function(t,e,n,r){if(n=n||31104e3,this.remove(t),this.f)try{return void this.f.set(t,e,B()+1e3*n)}catch(t){}var i="";if(r)try{i=escape(Oe(e))}catch(t){return}else i=escape(e);e=this.g,Ut.set(""+t,i,{V:n,path:"/",domain:void 0===e?"youtube.com":e,secure:!1})},Rr.prototype.get=function(t,e){var n=void 0,r=!this.f;if(!r)try{n=this.f.get(t)}catch(t){r=!0}if(r&&(n=Ut.get(""+t,void 0))&&(n=unescape(n),e))try{n=JSON.parse(n)}catch(e){this.remove(t),n=void 0}return n},Rr.prototype.remove=function(t){this.f&&this.f.remove(t);var e=this.g;Ut.remove(""+t,"/",void 0===e?"youtube.com":e)};var Dr=At||kt;function Mr(t){if(!t)throw Error();throw t}function Ur(t){return t}function Br(t){var e=this;this.g=t,this.state={status:"PENDING"},this.f=[],this.onRejected=[],this.g(function(t){if("PENDING"===e.state.status){e.state={status:"FULFILLED",value:t};for(var n=(t=a(e.f)).next();!n.done;n=t.next())(n=n.value)()}},function(t){if("PENDING"===e.state.status){e.state={status:"REJECTED",reason:t};for(var n=(t=a(e.onRejected)).next();!n.done;n=t.next())(n=n.value)()}})}function Yr(t,e){t.then(void 0,e)}function Xr(t,e,n,r,i){try{if("FULFILLED"!==t.state.status)throw Error("calling handleResolve before the promise is fulfilled.");var o=n(t.state.value);o instanceof Br?Vr(t,e,o,r,i):r(o)}catch(t){i(t)}}function qr(t,e,n,r,i){try{if("REJECTED"!==t.state.status)throw Error("calling handleReject before the promise is rejected.");var o=n(t.state.reason);o instanceof Br?Vr(t,e,o,r,i):r(o)}catch(t){i(t)}}function Vr(t,e,n,r,i){e===n?i(new TypeError("Circular promise chain detected.")):n.then(function(n){n instanceof Br?Vr(t,e,n,r,i):r(n)},function(t){i(t)})}function Gr(){var t=Error.call(this,"Transaction was aborted");this.message=t.message,"stack"in t&&(this.stack=t.stack),Object.setPrototypeOf(this,Gr.prototype)}function Fr(t){return t instanceof DOMException?"VersionError"===t.name:"DOMError"in self&&t instanceof DOMError?"VersionError"===t.name:t instanceof Object&&"message"in t&&"An attempt was made to open a database using a lower version than the existing version."===t.message}function Wr(t){return new Br(function(e,n){function r(){n(t.error),o()}function i(){e(t.result),o()}function o(){t.removeEventListener("success",i),t.removeEventListener("error",r)}t.addEventListener("success",i),t.addEventListener("error",r)})}function Kr(t){this.f=t}function zr(t,e,n){return new Jr(t=t.f.createObjectStore(e,n))}function Hr(t,e,n,r){return n=void 0===n?"readonly":n,new Ae(function(i,o){var a=new Zr(t.f.transaction(e,n),e);Yr(r(a).then(function(t){var e,n;Pe((e=a,n=e.f,n.commit&&!e.aborted&&n.commit(),e.done).then(function(){i(t)}),function(t){o(t)})}),function(t){o(t)})})}function Jr(t){this.f=t}function Qr(t,e,n){return Wr(t=n?t.f.put(e,n):t.f.put(e))}function Zr(t){var e=this;this.f=t,this.g=new Map,this.aborted=!1,this.done=new Ae(function(t,n){e.f.addEventListener("complete",function(){t()}),e.f.addEventListener("error",function(t){t.currentTarget===t.target&&n(e.f.error)}),e.f.addEventListener("abort",function(){var t=e.f.error;t?("QuotaExceededError"===t.name?pn(Error("The current transaction exceeded its quota limitations.")):"UnknownError"===t.name&&pn(Error("The current transaction may have failed because of exceeding quota limitations.")),n(t)):n(new Gr)})})}function $r(t,e){var n=t.f.objectStore(e),r=t.g.get(n);return r||(r=new Jr(n),t.g.set(n,r)),r}function ti(t){this.f=t}function ei(t,e,n){return function(t){return Wr(t).then(function(e){return null===e?null:new ni(t,e)})}(t=t.f.openCursor(void 0===e.query?null:e.query,void 0===e.direction?"next":e.direction)).then(function(t){return e=t,r=n,new Br(function(t,n){!function i(){var o=e?r(e):null;o?o.then(function(t){e=t,i()},n):t()}()});var e,r})}function ni(t,e){this.request=t,this.f=e}function ri(t,e,n){function r(){return i||(i=new Kr(a.result)),i}var i,o=Zr,a=void 0!==e?self.indexedDB.open(t,e):self.indexedDB.open(t),s=n.blocked,u=n.blocking,c=n.f,f=n.upgrade;return f&&a.addEventListener("upgradeneeded",function(t){if(null===t.newVersion)throw Error("Invariant: newVersion on IDbVersionChangeEvent is null");if(null===a.transaction)throw Error("Invariant: transaction on IDbOpenDbRequest is null");var e=r(),n=new o(a.transaction);f(e,t.oldVersion,t.newVersion,n)}),s&&a.addEventListener("blocked",function(){s()}),function(t){return new Ae(function(e,n){function r(){n(t.error),o()}function i(){e(t.result),o()}function o(){t.removeEventListener("success",i),t.removeEventListener("error",r)}t.addEventListener("success",i),t.addEventListener("error",r)})}(a).then(function(t){return u&&t.addEventListener("versionchange",function(){u(r())}),c&&t.addEventListener("close",function(){c()}),r()})}function ii(t,e,n){return ri(t,e,n=void 0===n?{}:n)}Br.all=function(t){return new Br(function(e,n){var r=[],i=t.length;0===i&&e(r);for(var o={D:0};o.D<t.length;++(o={D:o.D}).D)Yr(Br.resolve(t[o.D]).then(function(t){return function(n){r[t.D]=n,0===--i&&e(r)}}(o)),function(t){n(t)})})},Br.resolve=function(t){return new Br(function(e,n){t instanceof Br?t.then(e,n):e(t)})},Br.reject=function(t){return new Br(function(e,n){n(t)})},Br.prototype.then=function(t,e){var n=this,r=null!=t?t:Ur,i=null!=e?e:Mr;return new Br(function(t,e){"PENDING"===n.state.status?(n.f.push(function(){Xr(n,n,r,t,e)}),n.onRejected.push(function(){qr(n,n,i,t,e)})):"FULFILLED"===n.state.status?Xr(n,n,r,t,e):"REJECTED"===n.state.status&&qr(n,n,i,t,e)})},h(Gr,Error),(t=Kr.prototype).add=function(t,e,n){return Hr(this,[t],"readwrite",function(r){return $r(r,t).add(e,n)})},t.clear=function(t){return Hr(this,[t],"readwrite",function(e){return $r(e,t).clear()})},t.close=function(){this.f.close()},t.count=function(t,e){return Hr(this,[t],"readonly",function(n){return $r(n,t).count(e)})},t.delete=function(t,e){return Hr(this,[t],"readwrite",function(n){return $r(n,t).delete(e)})},t.get=function(t,e){return Hr(this,[t],"readwrite",function(n){return $r(n,t).get(e)})},(t=Jr.prototype).add=function(t,e){return Wr(e?this.f.add(t,e):this.f.add(t))},t.clear=function(){return Wr(this.f.clear()).then(function(){})},t.count=function(t){return Wr(t=t?this.f.count(t):this.f.count())},t.delete=function(t){return Wr(this.f.delete(t))},t.get=function(t){return Wr(this.f.get(t))},t.index=function(t){return new ti(this.f.index(t))},t.getName=function(){return this.f.name},Zr.prototype.abort=function(){this.f.abort(),this.aborted=!0},ti.prototype.count=function(t){return Wr(t=t?this.f.count(t):this.f.count())},ti.prototype.get=function(t){return Wr(this.f.get(t))},ni.prototype.delete=function(){return Wr(this.f.delete()).then(function(){})},ni.prototype.update=function(t){return Wr(this.f.update(t))};var oi,ai,si,ui,ci=["getAll","getAllKeys","getKey","openKeyCursor"],fi=["getAll","getAllKeys","getKey","openKeyCursor"];function li(){var t;return(t=Dr)&&(t=!!((t=/WebKit\/([0-9]+)/.exec(et))&&600<=parseInt(t[1],10))),t&&(t=!((t=/WebKit\/([0-9]+)/.exec(et))&&602<=parseInt(t[1],10))),!(t&&!Yn("ytidb_allow_on_ios_safari_v8_and_v9"))&&!!self.indexedDB}function hi(){return void 0!==oi?Ce(oi):new Ae(function(t){(function(){return V(this,function t(){var e,n,r;return E(t,function(t){switch(t.f){case 1:return li()?((i=t).l=2,i.j=3,n=!1,g(t,ii("yt-idb-test-do-not-use",void 0,{blocking:function(){n=!0,e&&(e.close(),e=void 0)}}),5)):t.return(!1);case 5:return e=t.g,r=ii("yt-idb-test-do-not-use",e.f.version+1).then(function(t){try{t.close()}catch(t){}}),g(t,Promise.race([r,new Promise(function(t){setTimeout(t,50)})]),6);case 6:return t.return(n);case 3:if(function(t){t.A=[t.h],t.l=0,t.j=0}(t),e)try{e.close()}catch(t){}!function(t){var e=t.A.splice(0)[0];(e=t.h=t.h||e)?e.U?t.f=t.l||t.j:null!=e.v&&t.j<e.v?(t.f=e.v,t.h=null):t.f=t.j:t.f=0}(t);break;case 2:return function(t){t.l=0,t.h=null}(t),t.return(!1)}var i})})})().then(function(e){oi=e,t(e)})})}function di(){function t(t){t.close(),si=void 0}return si||(si=Pe(ii("YtIdbMeta",1,{blocking:t,upgrade:function(t,e){1>e&&zr(t,"databases",{keyPath:"actualName"})}}),function(e){return Fr(e)?ii("YtIdbMeta",void 0,{blocking:t}):Le(e)})),si}function pi(t){return di().then(function(e){return e.get("databases",t.actualName).then(function(n){if(!n||(t.actualName!==n.actualName||t.publicName!==n.publicName||t.userIdentifier!==n.userIdentifier||t.signedIn!==n.signedIn))return function(t,e){return Hr(t,["databases"],"readwrite",function(t){return Qr($r(t,"databases"),e,void 0)})}(e,t)})})}function vi(t){try{var e={actualName:"LogsDataBase",publicName:"LogsDataBase",userIdentifier:void 0,signedIn:!1}}catch(t){return Le(t)}return Pe(pi(e).then(function(){return t(e)}),function(t){return Pe((n=e.actualName,di().then(function(t){return t.delete("databases",n)})),function(){}).then(function(){return Le(t)});var n})}function gi(t,e){return e=void 0===e?{}:e,vi(function(n){return ii(n.actualName,t,e)})}function yi(){throw Br.call(this,function(){}),Error("Not allowed to instantiate the thennable outside of the core library.")}function mi(){return V(this,function t(){return E(t,function(t){if(!ui)try{ui=gi(1,{upgrade:function(t,e){1>e&&(zr(t,"LogsRequestsStore",{keyPath:"id",autoIncrement:!0}).f.createIndex("newRequest",["status","authHash","timestamp"],{unique:!1}),zr(t,"sapisid"))}})}catch(e){if(!Fr(e))return dn(e),t.return(Promise.reject(e));ui=gi()}return t.return(ui)})})}function wi(t){return V(this,function e(){var n;return E(e,function(e){return 1==e.f?g(e,mi(),2):(n=e.g,e.return(n.delete("LogsRequestsStore",t)))})})}function bi(){return V(this,function t(){var e;return E(t,function(t){if(1==t.f){Pr.f||(Pr.f=new Pr);var n={},r=oe([]);return r&&(n.Authorization=r,n["X-Goog-AuthUser"]=fn("SESSION_INDEX",0),"INNERTUBE_HOST_OVERRIDE"in un||(n["X-Origin"]=window.location.origin),Yn("pageid_as_header_web")&&"DELEGATED_SESSION_ID"in un&&(n["X-Goog-PageId"]=fn("DELEGATED_SESSION_ID"))),g(t,n=Ce(n),2)}return e=t.g,t.return(function(t){t=kr(t);var e=new me;e.update(JSON.stringify(t,Object.keys(t).sort())),t=e.digest(),e="";for(var n=0;n<t.length;n++)e+="0123456789ABCDEF".charAt(Math.floor(t[n]/16))+"0123456789ABCDEF".charAt(t[n]%16);return e}(e))})})}h(yi,Br),yi.reject=Br.reject,yi.resolve=Br.resolve,yi.all=Br.all;var Ei=Xn("network_polling_interval",3e4);function _i(){var t;this.i=0,this.f=window.navigator.onLine,t=this,window.addEventListener("offline",function(){t.f=!1,t.h&&t.h()}),function(t){window.addEventListener("online",function(){t.f=!0,t.g&&t.g()})}(this)}function Si(){return _i.f||(_i.f=new _i),_i.f}function Ii(t){var e=Ai,n=ki;new Ae(function(e){t.g=e}).then(function(){e(),n&&(t.h=n)}),function(t){t.i||(function t(e){e.i=Vn(function(){window.navigator.onLine?(!1===e.f&&dn(Error("NetworkStatusManager missed online event.")),e.f=!0,e.g&&e.g()):(!0===e.f&&dn(Error("NetworkStatusManager missed offline event.")),e.f=!1,e.h&&e.h()),t(e)},Ei)}(t),window.navigator.onLine&&t.g&&t.g())}(t)}var Ti=Xn("networkless_throttle_timeout")||100,Ni=Xn("networkless_retry_attempts")||1,xi=0;function Oi(t,e){e=void 0===e?{}:e,ji().then(function(n){if(n&&!Yn("networkless_bypass_write")){var r={url:t,options:e,timestamp:Qn(),status:"NEW",sendCount:0};(function(t){return V(this,function e(){var n,r,i;return E(e,function(e){return 1==e.f?g(e,bi(),2):3!=e.f?(n=e.g,g(e,mi(),3)):(r=e.g,i=Object.assign(Object.assign({},t),{options:JSON.parse(JSON.stringify(t.options)),authHash:n}),e.return(r.add("LogsRequestsStore",i)))})})})(r).then(function(t){r.id=t,(t=Si()).f&&!Yn("networkless_always_offline")?Ri(r):Ii(t)}).catch(function(t){Ri(r),dn(t)})}else Sr(t,e)})}function Ai(){xi||(xi=Fn(function(){Ri(),xi=0,Ai()},1,Ti))}function ki(){var t=xi;if(!isNaN(t)){var e=x("yt.scheduler.instance.cancelJob");e?e(t):window.clearTimeout(t)}xi=0}function Ri(t){V(this,function e(){var n,r,i,o,a=this;return E(e,function(e){switch(e.f){case 1:if(n=a,!t)return g(e,function(){return V(this,function t(){var e,n,r,i,o,a;return E(t,function(t){switch(t.f){case 1:return g(t,bi(),2);case 2:return e=t.g,n=["NEW",e,0],r=["NEW",e,Qn()],i=IDBKeyRange.bound(n,r),g(t,mi(),3);case 3:return o=t.g,a=void 0,g(t,Hr(o,["LogsRequestsStore"],"readwrite",function(t){return ei($r(t,"LogsRequestsStore").index("newRequest"),{query:i,direction:"prev"},function(t){t.f.value&&((a=t.f.value).status="QUEUED",t.update(a))})}),4);case 4:return t.return(a)}})})}(),6);if(!t.id){e.v(3);break}return g(e,function(t){return V(this,function e(){var n;return E(e,function(e){return 1==e.f?g(e,mi(),2):(n=e.g,e.return(Hr(n,["LogsRequestsStore"],"readwrite",function(e){var n=$r(e,"LogsRequestsStore");return n.get(t).then(function(t){if(t)return t.status="QUEUED",Qr(n,t).then(function(){return t})})})))})})}(t.id),5);case 5:(r=e.g)?t=r:pn(Error("The request cannot be found in the database.")),e.v(3);break;case 6:if(t=e.g){e.v(3);break}return g(e,function(){return V(this,function t(){var e;return E(t,function(t){return 1==t.f?g(t,mi(),2):3!=t.f?g(t,t.g.count("LogsRequestsStore"),3):(e=t.g,t.return(!e))})})}(),8);case 8:return e.g&&ki(),e.return();case 3:if(function(t){return t=t.timestamp,!(2592e6<=Qn()-t)}(t))i=t.options.onError?t.options.onError:function(){},o=t.options.onSuccess?t.options.onSuccess:function(){},t.options.onError=function(e,r){return V(n,function n(){return E(n,function(n){if(1==n.f)return t&&t.id?t.sendCount<Ni?g(n,function(t){return V(this,function e(){var n;return E(e,function(e){return 1==e.f?g(e,mi(),2):(n=e.g,e.return(Hr(n,["LogsRequestsStore"],"readwrite",function(e){var n=$r(e,"LogsRequestsStore");return n.get(t).then(function(t){return t?(t.status="NEW",t.sendCount+=1,Qr(n,t).then(function(){return t})):yi.resolve(void 0)})})))})})}(t.id),6):g(n,wi(t.id),2):n.v(2);2!=n.f&&(xi||Ii(Si()),i(e,r)),i(e,r),n.f=0})})},t.options.onSuccess=function(e,r){return V(n,function n(){return E(n,function(n){if(1==n.f)return t&&t.id?g(n,wi(t.id),2):n.v(2);o(e,r),n.f=0})})},Sr(t.url,t.options);else if(pn(Error("Networkless Logging: Stored logs request expired age limit")),t.id)return g(e,wi(t.id),0);e.v(0)}})})}function ji(){return V(this,function t(){return E(t,function(t){return Yn("networkless_logging")?(2===Xn("networkless_ytidb_version")&&(void 0!==ai?Ce(ai):hi().then(function(t){if(!t)return!1;var e=a(ci);for(t=e.next();!t.done;t=e.next())if(!IDBObjectStore.prototype[t.value])return!1;for(t=(e=a(fi)).next();!t.done;t=e.next())if(!IDBIndex.prototype[t.value])return!1;return!!IDBObjectStore.prototype.getKey}).then(function(t){return ai=t})).then(function(t){return t}),t.return(li())):t.return(!1)})})}function Ci(t,e){for(var n=[],r=1;r<arguments.length;++r)n[r-1]=arguments[r];r=Error.call(this,t),this.message=r.message,"stack"in r&&(this.stack=r.stack),this.args=[].concat(n instanceof Array?n:function(t){for(var e,n=[];!(e=t.next()).done;)n.push(e.value);return n}(a(n)))}function Li(t){var e=this;this.f=null,t?this.f=t:Nr()&&(this.f=xr()),Vn(function(){Lr(e)},5e3)}function Pi(t,e,n,r){if(!fn("VISITOR_DATA")&&"visitor_id"!==e&&.01>Math.random()&&pn(new Ci("Missing VISITOR_DATA when sending innertube request.",e,n,r)),!t.isReady()){var i=new Ci("innertube xhrclient not ready",e,n,r);throw dn(i),i.sampleWeight=0,i}var o={headers:{"Content-Type":"application/json"},method:"POST",u:n,aa:"JSON",I:function(){r.I()},Y:r.I,onSuccess:function(t,e){r.onSuccess&&r.onSuccess(e)},X:function(t){r.onSuccess&&r.onSuccess(t)},onError:function(t,e){r.onError&&r.onError(e)},Ja:function(t){r.onError&&r.onError(t)},timeout:r.timeout,withCredentials:!0},a="";(i=t.f.ka)&&(a=i);var s=t.f.ma||!1,u=Ar(s,a,r);Object.assign(o.headers,u),o.headers.Authorization&&!a&&(o.headers["x-origin"]=window.location.origin),i="/youtubei/"+t.f.innertubeApiVersion+"/"+e;var c={alt:"json"};t.f.la&&o.headers.Authorization||(c.key=t.f.innertubeApiKey);var f=On(""+a+i,c||{},!0);ji().then(function(i){if(r.retry&&Yn("retry_web_logging_batches")&&"www.youtube-nocookie.com"!=a){if(Yn("networkless_gel")&&!i||!Yn("networkless_gel"))var c=function(t,e,n,r){if(r)return null;r=jr().get("nextId",!0)||1;var i=jr().get("requests",!0)||{};return i[r]={method:t,request:e,authState:kr(n),requestTime:Math.round(Qn())},jr().set("nextId",r+1,86400,!0),jr().set("requests",i,86400,!0),r}(e,n,u,s);if(c){var l=o.onSuccess,h=o.X;o.onSuccess=function(t,e){Cr(c),l(t,e)},n.X=function(t,e){Cr(c),h(t,e)}}}try{Yn("use_fetch_for_op_xhr")?function(t,e){if(window.fetch&&"XML"!=e.format){var n={method:e.method||"GET",credentials:"same-origin"};e.headers&&(n.headers=e.headers);var r=Tr(t=Ir(t,e),e);r&&(n.body=r),e.withCredentials&&(n.credentials="include");var i,o=!1;fetch(t,n).then(function(t){if(!o){o=!0,i&&window.clearTimeout(i);var n=t.ok,r=function(r){r=r||{};var i=e.context||N;n?e.onSuccess&&e.onSuccess.call(i,r,t):e.onError&&e.onError.call(i,r,t),e.P&&e.P.call(i,r,t)};"JSON"==(e.format||"JSON")&&(n||400<=t.status&&500>t.status)?t.json().then(r,function(){r(null)}):r(null)}}),e.Y&&0<e.timeout&&(i=In(function(){o||(o=!0,window.clearTimeout(i),e.Y.call(e.context||N))},e.timeout))}else Sr(t,e)}(f,o):Yn("networkless_gel")&&r.retry?(o.method="POST",Oi(f,o)):(o.method="POST",o.u||(o.u={}),Sr(f,o))}catch(t){if("InvalidAccessError"!=t.name)throw t;c&&(Cr(c),c=0),pn(Error("An extension is blocking network request."))}c&&Vn(function(){Lr(t)},5e3)})}h(Ci,Error),Li.prototype.isReady=function(){return!this.f&&Nr()&&(this.f=xr()),!!this.f};var Di,Mi=[{W:function(t){return"Cannot read property '"+t.key+"'"},R:{TypeError:[{regexp:/Cannot read property '([^']+)' of (null|undefined)/,groups:["key","value"]},{regexp:/\u65e0\u6cd5\u83b7\u53d6\u672a\u5b9a\u4e49\u6216 (null|undefined) \u5f15\u7528\u7684\u5c5e\u6027\u201c([^\u201d]+)\u201d/,groups:["value","key"]},{regexp:/\uc815\uc758\ub418\uc9c0 \uc54a\uc74c \ub610\ub294 (null|undefined) \ucc38\uc870\uc778 '([^']+)' \uc18d\uc131\uc744 \uac00\uc838\uc62c \uc218 \uc5c6\uc2b5\ub2c8\ub2e4./,groups:["value","key"]},{regexp:/No se puede obtener la propiedad '([^']+)' de referencia nula o sin definir/,groups:["key"]},{regexp:/Unable to get property '([^']+)' of (undefined or null) reference/,groups:["key","value"]}],Error:[{regexp:/(Permission denied) to access property "([^']+)"/,groups:["reason","key"]}]}},{W:function(t){return"Cannot call '"+t.key+"'"},R:{TypeError:[{regexp:/(?:([^ ]+)?\.)?([^ ]+) is not a function/,groups:["base","key"]},{regexp:/Object (.*) has no method '([^ ]+)'/,groups:["base","key"]},{regexp:/Object doesn't support property or method '([^ ]+)'/,groups:["key"]},{regexp:/\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306f '([^']+)' \u30d7\u30ed\u30d1\u30c6\u30a3\u307e\u305f\u306f\u30e1\u30bd\u30c3\u30c9\u3092\u30b5\u30dd\u30fc\u30c8\u3057\u3066\u3044\u307e\u305b\u3093/,groups:["key"]},{regexp:/\uac1c\uccb4\uac00 '([^']+)' \uc18d\uc131\uc774\ub098 \uba54\uc11c\ub4dc\ub97c \uc9c0\uc6d0\ud558\uc9c0 \uc54a\uc2b5\ub2c8\ub2e4./,groups:["key"]}]}}];function Ui(){this.f=[],this.g=[]}var Bi=new Fe,Yi=new Set,Xi=0,qi=["PhantomJS","Googlebot","TO STOP THIS SECURITY SCAN go/scan"];function Vi(t,e,n,r){return n+="."+t,t=String(JSON.stringify(e)).substr(0,500),r[n]=t,n.length+t.length}function Gi(t,e,n){if(this.l=this.f=this.g=null,this.j=C(this),this.h=0,this.s=!1,this.m=[],this.i=null,this.A=n,this.G={},n=document,(t="string"==typeof t?n.getElementById(t):t)&&(n="iframe"==t.tagName.toLowerCase(),e.host||(e.host=n?Gt(t.src):"https://www.youtube.com"),this.g=new Mn(e),n||(e=function(t,e){for(var n=document.createElement("iframe"),r=e.attributes,i=0,o=r.length;i<o;i++){var a=r[i].value;null!=a&&""!=a&&"null"!=a&&n.setAttribute(r[i].name,a)}n.setAttribute("frameBorder",0),n.setAttribute("allowfullscreen",1),n.setAttribute("allow","accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture"),n.setAttribute("title","YouTube "+Un(t.g,"title")),(r=Un(t.g,"width"))&&n.setAttribute("width",r),(r=Un(t.g,"height"))&&n.setAttribute("height",r);var s=t.M();return s.enablejsapi=window.postMessage?1:0,window.location.host&&(s.origin=window.location.protocol+"//"+window.location.host),s.widgetid=t.j,window.location.href&&W(["debugjs","debugcss"],function(t){var e=window.location.href,n=e.search(Kt);t:{for(var r=0,i=t.length;0<=(r=e.indexOf(t,r))&&r<n;){var o=e.charCodeAt(r-1);if(!(38!=o&&63!=o||(o=e.charCodeAt(r+i))&&61!=o&&38!=o&&35!=o))break t;r+=i+1}r=-1}0>r?e=null:((0>(i=e.indexOf("&",r))||i>n)&&(i=n),r+=t.length+1,e=decodeURIComponent(e.substr(r,i-r).replace(/\+/g," "))),null!==e&&(s[t]=e)}),n.src=Un(t.g,"host")+t.N()+"?"+Wt(s),n}(this,t),this.l=t,(n=t.parentNode)&&n.replaceChild(e,t),t=e),this.f=t,this.f.id||(this.f.id="widget"+C(this.f)),kn[this.f.id]=this,window.postMessage)){for(var r in this.i=new Fe,function(t){(function(t,e,n){Bn||(Bn={},Sn(window,"message",U(t.i,t))),Bn[n]=e})(t.g,t,t.j),t.h=Tn(U(t.Z,t)),Sn(t.f,"load",U(function(){window.clearInterval(this.h),this.h=Tn(U(this.Z,this))},t))}(this),e=Un(this.g,"events"))e.hasOwnProperty(r)&&this.addEventListener(r,e[r]);for(var i in Cn)Fi(this,i)}}function Fi(t,e){var n=e.split(".");if(2==n.length){var r=n[1];t.A==n[0]&&Ki(t,r)}}function Wi(t,e,n){n=n||[],e={event:"command",func:e,args:n=Array.prototype.slice.call(n)},t.s?t.S(e):t.m.push(e)}function Ki(t,e){t.G[e]||(t.G[e]=!0,Wi(t,"addEventListener",[e]))}function zi(t,e){if(!t)throw Error("YouTube player element ID required.");var n={title:"video player",videoId:"",width:640,height:360};if(e)for(var r in e)n[r]=e[r];Gi.call(this,t,n,"player"),this.C={},this.playerInfo={}}function Hi(t,e){if(j(e))for(var n in e)t.playerInfo[n]=e[n]}function Ji(t){if("iframe"!=t.tagName.toLowerCase()){var e=Dn(t,"videoid");e&&new zi(t,e={videoId:e,width:Dn(t,"width"),height:Dn(t,"height")})}}function Qi(t,e){var n={title:"Thumbnail",videoId:"",width:120,height:68};if(e)for(var r in e)n[r]=e[r];Gi.call(this,t,n,"thumbnail")}function Zi(t){if("iframe"!=t.tagName.toLowerCase()){var e=Dn(t,"videoid");if(e){e={videoId:e,events:{},width:Dn(t,"width"),height:Dn(t,"height"),thumbWidth:Dn(t,"thumb-width"),thumbHeight:Dn(t,"thumb-height"),thumbAlign:Dn(t,"thumb-align")};var n=Dn(t,"onclick");n&&(e.events.onClick=n),new Qi(t,e)}}}(t=Gi.prototype).setSize=function(t,e){return this.f.width=t,this.f.height=e,this},t.na=function(){return this.f},t.ba=function(t){this.K(t.event,t)},t.addEventListener=function(t,e){var n=e;return"string"==typeof e&&(n=function(){window[e].apply(window,arguments)}),n?(this.i.subscribe(t,n),Ki(this,t),this):this},t.destroy=function(){this.f.id&&(kn[this.f.id]=null);var t=this.i;if(t&&"function"==typeof t.dispose&&t.dispose(),this.l){var e=(t=this.f).parentNode;e&&e.replaceChild(this.l,t)}else(t=this.f)&&t.parentNode&&t.parentNode.removeChild(t);for(var n in Bn&&(Bn[this.j]=null),this.g=null,t=this.f,mn)mn[n][0]==t&&En(n);this.l=this.f=null},t.M=function(){return{}},t.K=function(t,e){if(!this.i.h){var n={target:this,data:e};this.i.J(t,n),function(t,e){jn.J.apply(jn,arguments)}(this.A+"."+t,n)}},t.Z=function(){this.f&&this.f.contentWindow?this.S({event:"listening"}):window.clearInterval(this.h)},t.S=function(t){t.id=this.j,t.channel="widget";var e=Oe(t),n=this.g,r=Gt(this.f.src||""),i=0==r.indexOf("https:")?[r]:n.f?[r.replace("http:","https:")]:n.h?[r]:[r,r.replace("http:","https:")];if(this.f.contentWindow)for(var o=0;o<i.length;o++)try{this.f.contentWindow.postMessage(e,"*")}catch(t){if(!t.name||"SyntaxError"!=t.name)throw t;if(!(t.message&&0<t.message.indexOf("target origin ''"))){var s=void 0,u=void 0,c=t;(u=void 0===u?{}:u).name=fn("INNERTUBE_CONTEXT_CLIENT_NAME",1),u.version=fn("INNERTUBE_CONTEXT_CLIENT_VERSION",void 0);var f=u||{},l="WARNING";if(l=void 0===l?"ERROR":l,s=void 0!==s&&s,c){if(Yn("console_log_js_exceptions")){var h=c,d=[];d.push("Name: "+h.name),d.push("Message: "+h.message),h.hasOwnProperty("params")&&d.push("Error Params: "+JSON.stringify(h.params)),d.push("File name: "+h.fileName),d.push("Stacktrace: "+h.stack),window.console.log(d.join("\n"),h)}if((window&&window.yterr||s)&&!(5<=Xi)&&0!==c.sampleWeight){var p=void 0,v=c,g=f,y=Lt(v),m=y.message||"Unknown Error",w=y.name||"UnknownError",b=y.lineNumber||"Not available",E=y.fileName||"Not available",_=y.stack||v.f||"Not available";if(v.hasOwnProperty("args")&&v.args&&v.args.length)for(var S=0,I=0;I<v.args.length;I++){var T=v.args[I],N="params."+I;if(S+=N.length,T)if(Array.isArray(T)){for(var O=g,A=S,k=0;k<T.length&&!(T[k]&&(A+=Vi(k,T[k],N,O),500<A));k++);S=A}else if("object"==typeof T){var R=void 0,j=g,C=S;for(R in T)if(T[R]&&500<(C+=Vi(R,T[R],N,j)))break;S=C}else g[N]=String(JSON.stringify(T)).substring(0,500),S+=g[N].length;else g[N]=String(JSON.stringify(T)).substring(0,500),S+=g[N].length;if(500<=S)break}else if(v.hasOwnProperty("params")&&v.params){var L=v.params;if("object"==typeof v.params){var P=0;for(p in L)if(L[p]){var D="params."+p,M=String(JSON.stringify(L[p])).substr(0,500);if(g[D]=M,500<(P+=D.length+M.length))break}}else g.params=String(JSON.stringify(L)).substr(0,500)}navigator.vendor&&!g.hasOwnProperty("vendor")&&(g.vendor=navigator.vendor);var U={message:m,name:w,lineNumber:b,fileName:E,stack:_,params:g},Y=Number(v.columnNumber);isNaN(Y)||(U.lineNumber=U.lineNumber+":"+Y);for(var X,q=U,V=a(Mi),G=V.next();!G.done;G=V.next()){var F=G.value;if(F.R[q.name])for(var W=a(F.R[q.name]),K=W.next();!K.done;K=W.next()){var z=K.value,H=q.message.match(z.regexp);if(H){q.params["error.original"]=H[0];for(var J=z.groups,Q={},Z=0;Z<J.length;Z++)Q[J[Z]]=H[Z+1],q.params["error."+J[Z]]=H[Z+1];q.message=F.W(Q);break}}}if(X=q,window.yterr&&"function"==typeof window.yterr&&window.yterr(X),!(Yi.has(X.message)||0<=X.stack.indexOf("/YouTubeCenter.js")||0<=X.stack.indexOf("/mytube.js"))){if(Bi.J("handleError",X),Yn("kevlar_gel_error_routing")){var $=void 0,tt=l,nt=X;t:{for(var rt=a(qi),it=rt.next();!it.done;it=rt.next()){if(et&&0<=et.toLowerCase().indexOf(it.value.toLowerCase())){var ot=!0;break t}}ot=!1}if(!ot){var at={stackTrace:nt.stack};nt.fileName&&(at.filename=nt.fileName);var st=nt.lineNumber&&nt.lineNumber.split?nt.lineNumber.split(":"):[];0!==st.length&&(1!==st.length||isNaN(Number(st[0]))?2!==st.length||isNaN(Number(st[0]))||isNaN(Number(st[1]))||(at.lineNumber=Number(st[0]),at.columnNumber=Number(st[1])):at.lineNumber=Number(st[0]));var ut=nt.message,ct=nt.name;Di||(Di=new Ui);var ft=Di;t:{for(var lt=a(ft.g),ht=lt.next();!ht.done;ht=lt.next()){var dt=ht.value;if(nt.message&&nt.message.match(dt.f)){var pt=dt.weight;break t}}for(var vt=a(ft.f),gt=vt.next();!gt.done;gt=vt.next()){var yt=gt.value;if(yt.f(nt)){pt=yt.weight;break t}}pt=1}var mt={level:"ERROR_LEVEL_UNKNOWN",message:ut,errorClassName:ct,sampleWeight:pt};"ERROR"===tt?mt.level="ERROR_LEVEL_ERROR":"WARNING"===tt&&(mt.level="ERROR_LEVEL_WARNNING");var wt={isObfuscated:!0,browserStackInfo:at},bt={pageUrl:window.location.href,kvPairs:[]},Et=nt.params;if(Et)for(var _t=a(Object.keys(Et)),St=_t.next();!St.done;St=_t.next()){var It=St.value;bt.kvPairs.push({key:"client."+It,value:String(Et[It])})}var Tt=fn("SERVER_NAME",void 0),Nt=fn("SERVER_VERSION",void 0);Tt&&Nt&&(bt.kvPairs.push({key:"server.name",value:Tt}),bt.kvPairs.push({key:"server.version",value:Nt}));var xt={errorMetadata:bt,stackTrace:wt,logMessage:mt};$=void 0===$?{}:$;var Ot=Li;fn("ytLoggingEventsDefaultDisabled",!1)&&(Ot=null);var At=Ot,kt=$;kt=void 0===kt?{}:kt;var Rt={};Rt.eventTimeMs=Math.round(kt.timestamp||Qn()),Rt.clientError=xt;var jt=String;if(kt.timestamp)var Ct=-1;else{var Pt=x("_lact",window);if(null==Pt)var Dt=-1;else{var Mt=Pt;Dt=Math.max(B()-Mt,0)}Ct=Dt}if(Rt.context={lastActivityMs:jt(Ct)},Yn("log_sequence_info_on_gel_web")&&kt.ca){var Ut=Rt.context,Bt=kt.ca;vr[Bt]=Bt in vr?vr[Bt]+1:0,Ut.sequence={index:vr[Bt],groupKey:Bt},kt.Ga&&delete vr[kt.ca]}var Yt=Rt,Xt=kt.Fa,qt=At,Vt="";if(Xt){var Ft=Xt,Wt={};Ft.videoId?Wt.videoId=Ft.videoId:Ft.playlistId&&(Wt.playlistId=Ft.playlistId),cr[Xt.token]=Wt,Vt=Xt.token}var Kt=ur.get(Vt)||[];ur.set(Vt,Kt),Kt.push(Yt),qt&&(nr=new qt);var zt=Xn("web_logging_max_batch")||100,Ht=Qn();Kt.length>=zt?fr():10<=Ht-or&&(lr(),or=Ht),fr()}}var Jt,Qt=X,Zt=Qt.params||{},$t={oa:{a:"logerror",t:"jserror",type:Qt.name,msg:Qt.message.substr(0,250),line:Qt.lineNumber,level:l,"client.name":Zt.name},u:{url:fn("PAGE_NAME",window.location.href),file:Qt.fileName},method:"POST"};if(Zt.version&&($t["client.version"]=Zt.version),$t.u){Qt.stack&&($t.u.stack=Qt.stack);for(var te=a(Object.keys(Zt)),ee=te.next();!ee.done;ee=te.next()){var ne=ee.value;$t.u["client."+ne]=Zt[ne]}if(Jt=fn("LATEST_ECATCHER_SERVICE_TRACKING_PARAMS",void 0))for(var re=a(Object.keys(Jt)),ie=re.next();!ie.done;ie=re.next()){var oe=ie.value;$t.u[oe]=Jt[oe]}var ae=fn("SERVER_NAME",void 0),se=fn("SERVER_VERSION",void 0);ae&&se&&($t.u["server.name"]=ae,$t.u["server.version"]=se)}Sr(fn("ECATCHER_REPORT_HOST","")+"/error_204",$t),Yi.add(X.message),Xi++}}}}}else console&&console.warn&&console.warn("The YouTube player is not attached to the DOM. API calls should be made after the onReady event. See more: https://developers.google.com/youtube/iframe_api_reference#Events")},h(zi,Gi),(t=zi.prototype).N=function(){return"/embed/"+Un(this.g,"videoId")},t.M=function(){var t=Un(this.g,"playerVars");if(t){var e,n={};for(e in t)n[e]=t[e];t=n}else t={};if(window!=window.top&&document.referrer&&(t.widget_referrer=document.referrer.substring(0,256)),e=Un(this.g,"embedConfig")){if(j(e))try{e=JSON.stringify(e)}catch(t){console.error("Invalid embed config JSON",t)}t.embed_config=e}return t},t.ba=function(t){var e=t.event;switch(t=t.info,e){case"apiInfoDelivery":if(j(t))for(var n in t)this.C[n]=t[n];break;case"infoDelivery":Hi(this,t);break;case"initialDelivery":window.clearInterval(this.h),this.playerInfo={},this.C={},function(t,e){W(e,function(t){var e;this[t]||("getCurrentTime"==t?this[t]=function(){var t=this.playerInfo.currentTime;if(1==this.playerInfo.playerState){var e=(B()/1e3-this.playerInfo.currentTimeLastUpdated_)*this.playerInfo.playbackRate;0<e&&(t+=Math.min(e,1))}return t}:0!==(e=t).search("cue")&&0!==e.search("load")||"loadModule"===e?function(t){return 0===t.search("get")||0===t.search("is")}(t)?this[t]=function(){var e=0;return 0===t.search("get")?e=3:0===t.search("is")&&(e=2),this.playerInfo[t.charAt(e).toLowerCase()+t.substr(e+1)]}:this[t]=function(){return Wi(this,t,arguments),this}:this[t]=function(){return this.playerInfo={},this.C={},Wi(this,t,arguments),this})},t)}(this,t.apiInterface),Hi(this,t);break;default:this.K(e,t)}},t.getVideoEmbedCode=function(){var t=parseInt(Un(this.g,"width"),10),e=parseInt(Un(this.g,"height"),10),n=Un(this.g,"host")+this.N();return ct.test(n)&&(-1!=n.indexOf("&")&&(n=n.replace(rt,"&amp;")),-1!=n.indexOf("<")&&(n=n.replace(it,"&lt;")),-1!=n.indexOf(">")&&(n=n.replace(ot,"&gt;")),-1!=n.indexOf('"')&&(n=n.replace(at,"&quot;")),-1!=n.indexOf("'")&&(n=n.replace(st,"&#39;")),-1!=n.indexOf("\0")&&(n=n.replace(ut,"&#0;"))),'<iframe width="'+t+'" height="'+e+'" src="'+n+'" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>'},t.getOptions=function(t){return this.C.namespaces?t?this.C[t].options||[]:this.C.namespaces||[]:[]},t.getOption=function(t,e){if(this.C.namespaces&&t&&e)return this.C[t][e]},h(Qi,Gi),Qi.prototype.N=function(){return"/embed/"+Un(this.g,"videoId")},Qi.prototype.M=function(){return{player:0,thumb_width:Un(this.g,"thumbWidth"),thumb_height:Un(this.g,"thumbHeight"),thumb_align:Un(this.g,"thumbAlign")}},Qi.prototype.K=function(t,e){Gi.prototype.K.call(this,t,e?e.info:void 0)},Y("YT.PlayerState.UNSTARTED",-1),Y("YT.PlayerState.ENDED",0),Y("YT.PlayerState.PLAYING",1),Y("YT.PlayerState.PAUSED",2),Y("YT.PlayerState.BUFFERING",3),Y("YT.PlayerState.CUED",5),Y("YT.get",function(t){return kn[t]}),Y("YT.scan",Ln),Y("YT.subscribe",function(t,e,n){for(var r in jn.subscribe(t,e,n),Cn[t]=!0,kn)Fi(kn[r],t)}),Y("YT.unsubscribe",function(t,e,n){!function(t,e,n){var r=jn;if(t=r.g[t]){var i=r.f;(t=function(t,e){t:{for(var n=t.length,r="string"==typeof t?t.split(""):t,i=0;i<n;i++)if(i in r&&e.call(void 0,r[i],i,t)){n=i;break t}n=-1}return 0>n?null:"string"==typeof t?t.charAt(n):t[n]}(t,function(t){return i[t+1]==e&&i[t+2]==n}))&&r.L(t)}}(t,e,n)}),Y("YT.Player",zi),Y("YT.Thumbnail",Qi),Gi.prototype.destroy=Gi.prototype.destroy,Gi.prototype.setSize=Gi.prototype.setSize,Gi.prototype.getIframe=Gi.prototype.na,Gi.prototype.addEventListener=Gi.prototype.addEventListener,zi.prototype.getVideoEmbedCode=zi.prototype.getVideoEmbedCode,zi.prototype.getOptions=zi.prototype.getOptions,zi.prototype.getOption=zi.prototype.getOption,Rn.push(function(t){t=Pn("player",t),W(t,Ji)}),Rn.push(function(){var t=Pn("thumbnail");W(t,Zi)}),void 0!==YTConfig&&YTConfig.parsetags&&"onload"!=YTConfig.parsetags||Ln();var $i=N.onYTReady;$i&&$i();var to=N.onYouTubeIframeAPIReady;to&&to();var eo=N.onYouTubePlayerAPIReady;eo&&eo()}.call(this);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment