axotube 1.47.0 → 1.48.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/early.js +1 -1
- package/dist/service-core.js +2 -2
- package/dist/service-core.json +3 -3
- package/dist/userScript.js +1 -1
- package/package.json +1 -1
package/dist/userScript.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(){"use strict";function e(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var t;t||(t=1,function(){if("undefined"==typeof globalThis)try{Object.defineProperty(Object.prototype,"__globalThis__",{get:function(){return this},configurable:!0}),__globalThis__.globalThis=__globalThis__,delete Object.prototype.__globalThis__}catch(e){"undefined"!=typeof window?window.globalThis=window:"undefined"!=typeof self&&(self.globalThis=self)}}(),window.NodeList&&!NodeList.prototype.forEach&&(NodeList.prototype.forEach=Array.prototype.forEach),window.HTMLCollection&&!HTMLCollection.prototype.forEach&&(HTMLCollection.prototype.forEach=Array.prototype.forEach),function(){var e=window.EventTarget;if(void 0!==e)try{return void new e}catch(e){}window.EventTarget=function(){var e={};return{addEventListener:function(t,n){"function"==typeof n&&(e[t]||(e[t]=[]),-1===e[t].indexOf(n)&&e[t].push(n))},removeEventListener:function(t,n){var i=e[t];if(i){var r=i.indexOf(n);-1!==r&&i.splice(r,1)}},dispatchEvent:function(t){var n=e[t&&t.type];if(n)for(var i=n.slice(),r=0;r<i.length;r++)try{i[r].call(this,t)}catch(e){console.error(e)}return!(t&&t.defaultPrevented)}}},e&&(window.EventTarget.prototype=e.prototype)}(),function(){function e(){this.aborted=!1,this._cbs=[]}function t(){this.signal=new e}"undefined"==typeof AbortController&&(e.prototype.addEventListener=function(e,t){"abort"===e&&"function"==typeof t&&this._cbs.push(t)},e.prototype.removeEventListener=function(e,t){if("abort"===e){var n=this._cbs.indexOf(t);-1!==n&&this._cbs.splice(n,1)}},e.prototype.dispatchEvent=function(e){if(e&&"abort"===e.type)for(var t=this._cbs.slice(),n=0;n<t.length;n++)t[n](e)},t.prototype.abort=function(){this.signal.aborted||(this.signal.aborted=!0,this.signal.dispatchEvent({type:"abort",bubbles:!1,cancelable:!1}))},window.AbortSignal=e,window.AbortController=t)}(),function(){function e(e,t){var n,i=!!(t=t||{}).bubbles,r=!!t.cancelable,a=void 0!==t.detail?t.detail:null;try{(n=document.createEvent("CustomEvent")).initCustomEvent(e,i,r,a)}catch(t){(n=document.createEvent("Event")).initEvent(e,i,r),n.detail=a}return n}"function"!=typeof CustomEvent&&(window.Event&&window.Event.prototype&&(e.prototype=window.Event.prototype),window.CustomEvent=e)}(),"undefined"!=typeof Promise&&"function"!=typeof Promise.prototype.finally&&(Promise.prototype.finally=function(e){var t=this.constructor||Promise;return this.then(function(n){return t.resolve(e()).then(function(){return n})},function(n){return t.resolve(e()).then(function(){throw n})})}),"undefined"!=typeof Promise&&"function"!=typeof Promise.allSettled&&(Promise.allSettled=function(e){return Promise.all(Array.prototype.map.call(e,function(e){return Promise.resolve(e).then(function(e){return{status:"fulfilled",value:e}},function(e){return{status:"rejected",reason:e}})}))}),function(){function e(t,n,i){for(var r=0;r<t.length;r++)n>0&&Array.isArray(t[r])?e(t[r],n-1,i):i.push(t[r]);return i}"function"!=typeof Array.prototype.flat&&(Array.prototype.flat=function(t){return e(this,(t=void 0===t?1:Math.floor(t))<0?0:t,[])})}(),"function"!=typeof Array.prototype.flatMap&&(Array.prototype.flatMap=function(e,t){return Array.prototype.map.call(this,e,t).flat(1)}),"function"!=typeof String.prototype.replaceAll&&(String.prototype.replaceAll=function(e,t){return"string"!=typeof e?this.replace(e,t):this.split(e).join("function"==typeof t?t(e,0,String(this)):String(t))}),"function"==typeof Object.values&&"function"==typeof Object.entries||(Object.values=Object.values||function(e){for(var t=Object.keys(e),n=[],i=0;i<t.length;i++)n.push(e[t[i]]);return n},Object.entries=Object.entries||function(e){for(var t=Object.keys(e),n=[],i=0;i<t.length;i++)n.push([t[i],e[t[i]]]);return n}),"function"!=typeof Object.fromEntries&&(Object.fromEntries=function(e){var t=Object.create(null);if("function"==typeof e.forEach)e.forEach(function(e){t[e[0]]=e[1]});else for(var n=Array.isArray(e)?e:Array.prototype.slice.call(e),i=0;i<n.length;i++)t[n[i][0]]=n[i][1];return t}),"function"!=typeof queueMicrotask&&(window.queueMicrotask=function(e){Promise.resolve().then(e).catch(function(e){setTimeout(function(){throw e},0)})}),window.Element&&"function"!=typeof Element.prototype.closest&&(Element.prototype.closest=function(e){for(var t=this;t&&1===t.nodeType;){if(t.matches?t.matches(e):t.msMatchesSelector?t.msMatchesSelector(e):t.webkitMatchesSelector&&t.webkitMatchesSelector(e))return t;t=t.parentElement||t.parentNode}return null}),function(){if(window.Element){var e=Element.prototype;"function"!=typeof e.matches&&(e.matches=e.msMatchesSelector||e.webkitMatchesSelector||function(e){for(var t=(this.document||this.ownerDocument).querySelectorAll(e),n=t.length;--n>=0&&t.item(n)!==this;);return n>-1})}}(),function(){if("undefined"!=typeof Intl&&"function"!=typeof Intl.Locale){var e={US:"en",GB:"en",AU:"en",CA:"en",IN:"hi",IE:"en",NZ:"en",FR:"fr",DE:"de",ES:"es",IT:"it",PT:"pt",BR:"pt",MX:"es",AR:"es",CO:"es",CL:"es",RU:"ru",UA:"uk",PL:"pl",NL:"nl",BE:"nl",SE:"sv",NO:"no",DK:"da",FI:"fi",TR:"tr",GR:"el",CZ:"cs",SK:"sk",HU:"hu",RO:"ro",BG:"bg",HR:"hr",RS:"sr",JP:"ja",KR:"ko",VN:"vi",TH:"th",ID:"id",MY:"ms",PH:"tl",SA:"ar",AE:"ar",EG:"ar",IL:"he",IR:"fa",PK:"ur",BD:"bn",LK:"si"};t.prototype.maximize=function(){return this},Intl.Locale=t}function t(t,n){n=n||{},this.language=e[n.region]||"en"}}());var n;function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=Array(t);n<t;n++)i[n]=e[n];return i}function r(e){if(Array.isArray(e))return e}function a(e,t,n){if("function"==typeof e?e===t:e.has(t))return arguments.length<3?t:n;throw new TypeError("Private element is not present on this object")}function o(e,t,n){return t=g(t),w(e,y()?Reflect.construct(t,n||[],g(e).constructor):t.apply(e,n))}function s(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function u(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function l(e,t){return e.get(a(e,t))}function c(e,t,n){s(e,t),t.set(e,n)}function h(e,t,n){return e.set(a(e,t),n),n}function d(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,C(i.key),i)}}function p(e,t,n){return t&&d(e.prototype,t),n&&d(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function f(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=P(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var i=0,r=function(){};return{s:r,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,o=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return o=e.done,e},e:function(e){s=!0,a=e},f:function(){try{o||null==n.return||n.return()}finally{if(s)throw a}}}}function m(e,t,n){return(t=C(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function g(e){return g=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},g(e)}function v(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&k(e,t)}function y(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(y=function(){return!!e})()}function b(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function x(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function S(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,i)}return n}function E(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?S(Object(n),!0).forEach(function(t){m(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):S(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function w(e,t){if(t&&("object"==typeof t||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}function k(e,t){return k=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},k(e,t)}function D(e,t){return r(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i,r,a,o,s=[],u=!0,l=!1;try{if(a=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;u=!1}else for(;!(u=(i=a.call(n)).done)&&(s.push(i.value),s.length!==t);u=!0);}catch(e){l=!0,r=e}finally{try{if(!u&&null!=n.return&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw r}}return s}}(e,t)||P(e,t)||x()}function A(e){return function(e){if(Array.isArray(e))return i(e)}(e)||b(e)||P(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function C(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,t||"default");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}function T(e){return T="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},T(e)}function P(e,t){if(e){if("string"==typeof e)return i(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(e,t):void 0}}n||(n=1,function(){var e=!1;try{var t=0,n=[];e="xbx"!=="aba".replaceAll("a",function(e,i){return t+=1,n.push(i),"x"})||2!==t||0!==n[0]||2!==n[1]}catch(t){e=!0}e&&(String.prototype.replaceAll=function(e,t){var n=String(this);if(e instanceof RegExp){if(!e.global)throw new TypeError("replaceAll requires a global RegExp");return n.replace(e,t)}var i=new RegExp(String(e).replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),"g");return n.replace(i,t)})}(),function(){var e=!1;try{var t=Object.fromEntries([["a",1]]);e=Object.getPrototypeOf(t)!==Object.prototype}catch(t){e=!0}e&&(Object.fromEntries=function(e){var t={};function n(e){if(e)try{Object.defineProperty(t,e[0],{value:e[1],enumerable:!0,configurable:!0,writable:!0})}catch(n){t[e[0]]=e[1]}}if(e&&"function"==typeof e.forEach)e.forEach(n);else for(var i=Array.isArray(e)?e:Array.prototype.slice.call(e||[]),r=0;r<i.length;r++)n(i[r]);return t})}());var F="undefined"!=typeof globalThis&&globalThis||"undefined"!=typeof self&&self||"undefined"!=typeof global&&global||{},B="URLSearchParams"in F,I="Symbol"in F&&"iterator"in Symbol,L="FileReader"in F&&"Blob"in F&&function(){try{return new Blob,!0}catch(e){return!1}}(),O="FormData"in F,N="ArrayBuffer"in F;if(N)var R=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],M=ArrayBuffer.isView||function(e){return e&&R.indexOf(Object.prototype.toString.call(e))>-1};function _(e){if("string"!=typeof e&&(e=String(e)),/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(e)||""===e)throw new TypeError('Invalid character in header field name: "'+e+'"');return e.toLowerCase()}function U(e){return"string"!=typeof e&&(e=String(e)),e}function j(e){var t={next:function(){var t=e.shift();return{done:void 0===t,value:t}}};return I&&(t[Symbol.iterator]=function(){return t}),t}function H(e){this.map={},e instanceof H?e.forEach(function(e,t){this.append(t,e)},this):Array.isArray(e)?e.forEach(function(e){if(2!=e.length)throw new TypeError("Headers constructor: expected name/value pair to be length 2, found"+e.length);this.append(e[0],e[1])},this):e&&Object.getOwnPropertyNames(e).forEach(function(t){this.append(t,e[t])},this)}function z(e){if(!e._noBody)return e.bodyUsed?Promise.reject(new TypeError("Already read")):void(e.bodyUsed=!0)}function V(e){return new Promise(function(t,n){e.onload=function(){t(e.result)},e.onerror=function(){n(e.error)}})}function K(e){var t=new FileReader,n=V(t);return t.readAsArrayBuffer(e),n}function G(e){if(e.slice)return e.slice(0);var t=new Uint8Array(e.byteLength);return t.set(new Uint8Array(e)),t.buffer}function J(){return this.bodyUsed=!1,this._initBody=function(e){var t;this.bodyUsed=this.bodyUsed,this._bodyInit=e,e?"string"==typeof e?this._bodyText=e:L&&Blob.prototype.isPrototypeOf(e)?this._bodyBlob=e:O&&FormData.prototype.isPrototypeOf(e)?this._bodyFormData=e:B&&URLSearchParams.prototype.isPrototypeOf(e)?this._bodyText=e.toString():N&&L&&((t=e)&&DataView.prototype.isPrototypeOf(t))?(this._bodyArrayBuffer=G(e.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):N&&(ArrayBuffer.prototype.isPrototypeOf(e)||M(e))?this._bodyArrayBuffer=G(e):this._bodyText=e=Object.prototype.toString.call(e):(this._noBody=!0,this._bodyText=""),this.headers.get("content-type")||("string"==typeof e?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):B&&URLSearchParams.prototype.isPrototypeOf(e)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},L&&(this.blob=function(){var e=z(this);if(e)return e;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))}),this.arrayBuffer=function(){if(this._bodyArrayBuffer){var e=z(this);return e||(ArrayBuffer.isView(this._bodyArrayBuffer)?Promise.resolve(this._bodyArrayBuffer.buffer.slice(this._bodyArrayBuffer.byteOffset,this._bodyArrayBuffer.byteOffset+this._bodyArrayBuffer.byteLength)):Promise.resolve(this._bodyArrayBuffer))}if(L)return this.blob().then(K);throw new Error("could not read as ArrayBuffer")},this.text=function(){var e,t,n,i,r,a=z(this);if(a)return a;if(this._bodyBlob)return e=this._bodyBlob,t=new FileReader,n=V(t),i=/charset=([A-Za-z0-9_-]+)/.exec(e.type),r=i?i[1]:"utf-8",t.readAsText(e,r),n;if(this._bodyArrayBuffer)return Promise.resolve(function(e){for(var t=new Uint8Array(e),n=new Array(t.length),i=0;i<t.length;i++)n[i]=String.fromCharCode(t[i]);return n.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},O&&(this.formData=function(){return this.text().then(q)}),this.json=function(){return this.text().then(JSON.parse)},this}H.prototype.append=function(e,t){e=_(e),t=U(t);var n=this.map[e];this.map[e]=n?n+", "+t:t},H.prototype.delete=function(e){delete this.map[_(e)]},H.prototype.get=function(e){return e=_(e),this.has(e)?this.map[e]:null},H.prototype.has=function(e){return this.map.hasOwnProperty(_(e))},H.prototype.set=function(e,t){this.map[_(e)]=U(t)},H.prototype.forEach=function(e,t){for(var n in this.map)this.map.hasOwnProperty(n)&&e.call(t,this.map[n],n,this)},H.prototype.keys=function(){var e=[];return this.forEach(function(t,n){e.push(n)}),j(e)},H.prototype.values=function(){var e=[];return this.forEach(function(t){e.push(t)}),j(e)},H.prototype.entries=function(){var e=[];return this.forEach(function(t,n){e.push([n,t])}),j(e)},I&&(H.prototype[Symbol.iterator]=H.prototype.entries);var X=["CONNECT","DELETE","GET","HEAD","OPTIONS","PATCH","POST","PUT","TRACE"];function W(e,t){if(!(this instanceof W))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');var n,i,r=(t=t||{}).body;if(e instanceof W){if(e.bodyUsed)throw new TypeError("Already read");this.url=e.url,this.credentials=e.credentials,t.headers||(this.headers=new H(e.headers)),this.method=e.method,this.mode=e.mode,this.signal=e.signal,r||null==e._bodyInit||(r=e._bodyInit,e.bodyUsed=!0)}else this.url=String(e);if(this.credentials=t.credentials||this.credentials||"same-origin",!t.headers&&this.headers||(this.headers=new H(t.headers)),this.method=(n=t.method||this.method||"GET",i=n.toUpperCase(),X.indexOf(i)>-1?i:n),this.mode=t.mode||this.mode||null,this.signal=t.signal||this.signal||function(){if("AbortController"in F)return(new AbortController).signal}(),this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&r)throw new TypeError("Body not allowed for GET or HEAD requests");if(this._initBody(r),!("GET"!==this.method&&"HEAD"!==this.method||"no-store"!==t.cache&&"no-cache"!==t.cache)){var a=/([?&])_=[^&]*/;if(a.test(this.url))this.url=this.url.replace(a,"$1_="+(new Date).getTime());else{this.url+=(/\?/.test(this.url)?"&":"?")+"_="+(new Date).getTime()}}}function q(e){var t=new FormData;return e.trim().split("&").forEach(function(e){if(e){var n=e.split("="),i=n.shift().replace(/\+/g," "),r=n.join("=").replace(/\+/g," ");t.append(decodeURIComponent(i),decodeURIComponent(r))}}),t}function Y(e,t){if(!(this instanceof Y))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');if(t||(t={}),this.type="default",this.status=void 0===t.status?200:t.status,this.status<200||this.status>599)throw new RangeError("Failed to construct 'Response': The status provided (0) is outside the range [200, 599].");this.ok=this.status>=200&&this.status<300,this.statusText=void 0===t.statusText?"":""+t.statusText,this.headers=new H(t.headers),this.url=t.url||"",this._initBody(e)}W.prototype.clone=function(){return new W(this,{body:this._bodyInit})},J.call(W.prototype),J.call(Y.prototype),Y.prototype.clone=function(){return new Y(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new H(this.headers),url:this.url})},Y.error=function(){var e=new Y(null,{status:200,statusText:""});return e.ok=!1,e.status=0,e.type="error",e};var Q=[301,302,303,307,308];Y.redirect=function(e,t){if(-1===Q.indexOf(t))throw new RangeError("Invalid status code");return new Y(null,{status:t,headers:{location:e}})};var Z=F.DOMException;try{new Z}catch(e){(Z=function(e,t){this.message=e,this.name=t;var n=Error(e);this.stack=n.stack}).prototype=Object.create(Error.prototype),Z.prototype.constructor=Z}function $(e,t){return new Promise(function(n,i){var r=new W(e,t);if(r.signal&&r.signal.aborted)return i(new Z("Aborted","AbortError"));var a=new XMLHttpRequest;function o(){a.abort()}if(a.onload=function(){var e,t,i={statusText:a.statusText,headers:(e=a.getAllResponseHeaders()||"",t=new H,e.replace(/\r?\n[\t ]+/g," ").split("\r").map(function(e){return 0===e.indexOf("\n")?e.substr(1,e.length):e}).forEach(function(e){var n=e.split(":"),i=n.shift().trim();if(i){var r=n.join(":").trim();try{t.append(i,r)}catch(e){console.warn("Response "+e.message)}}}),t)};0===r.url.indexOf("file://")&&(a.status<200||a.status>599)?i.status=200:i.status=a.status,i.url="responseURL"in a?a.responseURL:i.headers.get("X-Request-URL");var o="response"in a?a.response:a.responseText;setTimeout(function(){n(new Y(o,i))},0)},a.onerror=function(){setTimeout(function(){i(new TypeError("Network request failed"))},0)},a.ontimeout=function(){setTimeout(function(){i(new TypeError("Network request timed out"))},0)},a.onabort=function(){setTimeout(function(){i(new Z("Aborted","AbortError"))},0)},a.open(r.method,function(e){try{return""===e&&F.location.href?F.location.href:e}catch(t){return e}}(r.url),!0),"include"===r.credentials?a.withCredentials=!0:"omit"===r.credentials&&(a.withCredentials=!1),"responseType"in a&&(L?a.responseType="blob":N&&(a.responseType="arraybuffer")),t&&"object"===T(t.headers)&&!(t.headers instanceof H||F.Headers&&t.headers instanceof F.Headers)){var s=[];Object.getOwnPropertyNames(t.headers).forEach(function(e){s.push(_(e)),a.setRequestHeader(e,U(t.headers[e]))}),r.headers.forEach(function(e,t){-1===s.indexOf(t)&&a.setRequestHeader(t,e)})}else r.headers.forEach(function(e,t){a.setRequestHeader(t,e)});r.signal&&(r.signal.addEventListener("abort",o),a.onreadystatechange=function(){4===a.readyState&&r.signal.removeEventListener("abort",o)}),a.send(void 0===r._bodyInit?null:r._bodyInit)})}$.polyfill=!0,F.fetch||(F.fetch=$,F.Headers=H,F.Request=W,F.Response=Y);var ee=!1,te=null,ne=!1,ie=null;function re(){if(ee){if(ee=!1,ie){try{ie.disconnect()}catch(e){}ie=null}te&&te.parentNode&&te.parentNode.removeChild(te),te=null}}function ae(){if(!ee&&!ne&&document.getElementById){var e=document.getElementById("loader");if(e){var t;try{t=window.getComputedStyle(e)}catch(e){t=null}(te=document.createElement("div")).id="ytaf-boot-overlay";var n=t&&t.backgroundColor||"rgb(40, 40, 40)",i=t&&t.backgroundImage||"none";te.style.cssText="position:fixed;top:0;left:0;width:100%;height:100%;z-index:2147483647;background-color:"+n+";background-image:"+i+";background-position:"+(t&&t.backgroundPosition||"center center")+";background-repeat:"+(t&&t.backgroundRepeat||"no-repeat")+";background-size:"+(t&&t.backgroundSize||"60%")+";",(document.body||document.documentElement).appendChild(te),ee=!0,ne=!0}}}function oe(){if(!ne&&document.documentElement){try{(ie=new MutationObserver(function(){ae(),ne&&ie&&ie.disconnect()})).observe(document.documentElement,{childList:!0,subtree:!0})}catch(e){}ae(),setTimeout(ae,50),setTimeout(ae,200),setTimeout(ae,800),setTimeout(ae,2e3)}}function se(){return"undefined"!=typeof window&&window.h5vcc&&window.h5vcc.tizentube||null}window.__releaseBootLoader=re,setTimeout(function(){if(ie){try{ie.disconnect()}catch(e){}ie=null}re()},1e4),document.documentElement?oe():document.addEventListener("DOMContentLoaded",oe);var ue,le,ce={defaults:{enableAdBlock:!0,blockPlayerAdTracking:!0,blockAdTelemetry:!0,blockViewStatsTelemetry:!1,removeLiveVideos:!1,removeTopLiveGames:!1,removeMostRelevant:!1,enableSponsorBlock:!0,enableSponsorBlockToasts:!0,sponsorBlockManualSkips:["intro","outro","filler"],enableSponsorBlockSponsor:!0,enableSponsorBlockIntro:!0,enableSponsorBlockOutro:!0,enableSponsorBlockInteraction:!0,enableSponsorBlockSelfPromo:!0,enableSponsorBlockPreview:!0,enableSponsorBlockMusicOfftopic:!0,enableSponsorBlockFiller:!1,enableSponsorBlockHighlight:!0,videoSpeed:1,preferredVideoQuality:"auto",enableDeArrowTitles:!0,enableDeArrowThumbnails:!0,routeColor:"#0f0f0f",routeBackgroundUrl:"",themePreset:"default",textTheme:"default",userAgentProfile:"auto",enableFixedUI:!1,enableHqThumbnails:!0,enableLongPress:!0,enableShorts:!0,dontCheckUpdateUntil:0,enableWhoIsWatchingMenu:!1,permanentlyEnableWhoIsWatchingMenu:!1,enableWhosWatchingMenuOnAppExit:!1,enableShowUserLanguage:!0,enableShowOtherLanguages:!1,showWelcomeToast:!0,enablePreviousNextButtons:!0,enableSuperThanksButton:!1,enableSpeedControlsButton:!0,enablePatchingVideoPlayer:!0,enableMPButton:!0,enableSwapMPWithPIP:!1,enablePreviews:!0,previewLengthSeconds:40,enableRemainingTime:!1,enablePauseOnBlur:!1,enableLowMemoryMode:!1,enableHideWatchedVideos:!1,hideWatchedVideosThreshold:80,hideWatchedVideosPages:[],enableHideEndScreenCards:!1,enableYouThereRenderer:!0,enableScreenDimming:!1,dimmingTimeout:60,dimmingOpacity:.5,enablePaidPromotionOverlay:!0,speedSettingsIncrement:.25,videoPreferredCodec:"any",enableAutoSubtitles:!0,autoSubtitleLanguage:"en",autoSubtitleAllowAuto:!0,launchToOnStartup:null,reloadHomeOnStartup:!0,disabledSidebarContents:[],disableChannelsOnSidebar:!1,enableUpdater:!0,autoFrameRate:!1,autoFrameRatePauseVideoFor:0,enableSigninReminder:!1,sortSubscriptionsByAlphabet:!1,enableReducedMotion:!1,enablePerformanceMode:!1,enablePanelShrink:!0,enableDeArrowPeek:!0,panelShrinkPercent:"60",clockMode:"off",clockFormat:"24h",clockPosition:"topRight",clockShowSeconds:!1,enableOnePressMode:!1,enableExperimentalResolution:!1,experimentalMaxResolution:"1440p"},ranges:{videoSpeed:[.05,5],hideWatchedVideosThreshold:[0,100],dimmingTimeout:[1,3600],dimmingOpacity:[0,1],speedSettingsIncrement:[.01,1],autoFrameRatePauseVideoFor:[0,1e4],previewLengthSeconds:[5,120],dontCheckUpdateUntil:[0,9007199254740991]},enums:{preferredVideoQuality:["auto","2160p","1440p","1080p","720p","480p","360p","240p","144p"],videoPreferredCodec:["any","vp9","av01","avc1"],themePreset:["default","black","darkGray","charcoal","navy","darkRed","darkGreen","darkPurple"],textTheme:["default","white","gray","red","blue","green","purple","yellow"],userAgentProfile:["auto","samsung","android"],experimentalMaxResolution:["1440p","2160p"],autoSubtitleLanguage:["en","hi","es","fr","de","pt","ja","ko","ru"],panelShrinkPercent:["50","60","70"],clockMode:["off","always","notPlaying"],clockFormat:["24h","12h","12hNoAmPm"],clockPosition:["topLeft","topRight","bottomLeft","bottomRight"]},themePresetColors:{default:"#0f0f0f",black:"#000000",darkGray:"#1c1a1a",charcoal:"#121212",navy:"#0d1b2a",darkRed:"#3b0505",darkGreen:"#052e1b",darkPurple:"#1a1025"}};var he=function(){if(le)return ue;le=1;var e=ce;return ue={validateConfigValue:function(t,n){var i=e.defaults;if(!Object.prototype.hasOwnProperty.call(i,t))return!1;var r=i[t];if(null===r)return null===n||"string"==typeof n;if(Array.isArray(r))return Array.isArray(n)&&n.every(function(e){return"string"==typeof e});if("number"==typeof r){if("number"!=typeof n||!isFinite(n))return!1;var a=e.ranges[t];return!a||n>=a[0]&&n<=a[1]}if(T(n)!==T(r))return!1;var o=e.enums[t];return(!o||-1!==o.indexOf(n))&&(!("routeColor"===t&&!/^#[0-9a-f]{6}$/i.test(n))&&!("routeBackgroundUrl"===t&&n&&!/^https?:\/\/\S+$/i.test(n)))}},ue}(),de=e(he),pe="ytaf-configuration",fe=JSON.parse,me=JSON.stringify,ge=function(e){return fe(me(e))},ve=ge,ye=ge(ce.defaults);ye.enableFixedUI=!se()||ce.defaults.enableFixedUI;var be,xe=de.validateConfigValue;function Se(e){if(Object.prototype.hasOwnProperty.call(ye,e))return void 0===be[e]&&(be[e]=ge(ye[e])),be[e];console.warn("[AxoTube:config] Unknown config key",e)}function Ee(e,t){if(!xe(e,t))return console.warn("[AxoTube:config] Rejected invalid config value",e,t),!1;be[e]=ge(t);var n=function(){try{return!!window.localStorage&&(window.localStorage[pe]=me(be),!0)}catch(e){if("QuotaExceededError"===e.name){console.warn("[AxoTube:config] localStorage quota exceeded; replacing axotube config only");try{return"function"==typeof window.localStorage.removeItem?window.localStorage.removeItem(pe):delete window.localStorage[pe],window.localStorage[pe]=me(be),!0}catch(e){return console.error("[AxoTube:config] Failed to persist axotube config:",e),!1}}return console.error("[AxoTube:config] Failed to persist config:",e),!1}}();return we.dispatchEvent(new CustomEvent("configChange",{detail:{key:e,value:ge(t)}})),n}!function(){be=ge(ye);try{if(!window.localStorage||!window.localStorage[pe])return;var e=fe(window.localStorage[pe]);if(!e||"object"!==T(e)||Array.isArray(e))return;Object.keys(e).forEach(function(t){xe(t,e[t])&&(be[t]=ge(e[t]))})}catch(e){console.warn("[AxoTube:config] Config read failed; using defaults:",e)}}();var we=new EventTarget;function ke(){return ge(be)}var De,Ae,Ce="axotube-user-agent-tried";function Te(e,t){try{window.__axotubeUserAgent={wanted:e,actual:navigator.userAgent,status:t}}catch(e){}console.log("[AxoTube:userAgentSpoofing] "+t+": "+navigator.userAgent)}function Pe(){return!!Se("enablePerformanceMode")}function Fe(){return Pe()||!!Se("enableReducedMotion")}function Be(){return Pe()||!!Se("enableLowMemoryMode")}function Ie(){return!!Se("enablePreviews")&&!Pe()}function Le(){return Se("enableHqThumbnails")?Fe()||Be()?"hover":"eager":"off"}function Oe(e){e&&"object"===T(e)&&Be()&&(e.feature_switches&&"object"===T(e.feature_switches)||(e.feature_switches={}),e.feature_switches.enable_memory_saving_mode=!0)}De="android"===Se("userAgentProfile")?"Mozilla/5.0 (Linux; Android 13; Pixel 7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Mobile Safari/537.36":"Mozilla/5.0 (SMART-TV; LINUX; Tizen 4.0) AppleWebKit/537.3 (KHTML, like Gecko) SamsungBrowser/2.1 TV Safari/537.3",navigator.userAgent!==De?function(e){try{if(window.tizen&&window.tizen.websetting&&"function"==typeof window.tizen.websetting.setUserAgentString)return window.tizen.websetting.setUserAgentString(e),!0}catch(e){console.warn("[AxoTube:userAgentSpoofing] setUserAgentString failed:",e)}return!1}(De)?function(e){try{return sessionStorage.getItem(Ce)===e}catch(e){return!1}}(De)?Te(De,"not-applied"):(function(e){try{sessionStorage.setItem(Ce,e)}catch(e){}}(De),Te(De,"set"),location.reload()):Te(De,"unavailable"):Te(De,"applied"),we.addEventListener("configChange",function(e){var t;"enablePerformanceMode"===(null===(t=e.detail)||void 0===t?void 0:t.key)&&(Se("enablePerformanceMode")||(Ee("enableReducedMotion",!1),Ee("enableLowMemoryMode",!1)))});try{var Ne=window.environment;Object.defineProperty(window,"environment",{configurable:!0,get:function(){return Ae},set:function(e){Oe(e),Ae=e}}),Ae=Ne,Oe(Ne)}catch(e){console.warn("[AxoTube:lowMemoryMode] low memory mode unavailable:",e)}var Re={"1440p":"2560x1440","2160p":"3840x2160"},Me={width:function(e){return Number(e)>0&&Number(e)<=7680},height:function(e){return Number(e)>0&&Number(e)<=4320},framerate:function(e){return Number(e)>0&&Number(e)<=60},bitrate:function(e){return Number(e)>0&&Number(e)<=2e8},eotf:function(e){return"bt709"===e||("smpte2084"===e||"arib-std-b67"===e)&&_e()},channels:function(e){return Number(e)>0&&Number(e)<=8},cryptoblockformat:function(e){return"subsample"===e},"decode-to-texture":function(e){return"true"===e||"false"===e}};function _e(){return!(!window.matchMedia||!window.matchMedia("(dynamic-range: high)").matches)}function Ue(e){var t=e.split("."),n="vp09"===t[0]?t[6]:"av01"===t[0]?t[7]:void 0;return"16"===n||"18"===n}var je="__axotubeResolutionOwner";if(!window[je]){if(window[je]=!0,Se("enableExperimentalResolution"))try{window.h5vcc=window.h5vcc||{},window.h5vcc.system=window.h5vcc.system||{},window.h5vcc.system.getVideoContainerSizeOverride=function(){var e=Se("experimentalMaxResolution");return Re[e]||Re["1440p"]},function(){if(window.MediaSource&&"function"==typeof MediaSource.isTypeSupported){var e=MediaSource.isTypeSupported.bind(MediaSource);MediaSource.isTypeSupported=function(t){for(var n=String(t).split(";"),i=[n[0].trim()],r=1;r<n.length;r++){var a=n[r].trim(),o=a.indexOf("="),s=(-1===o?a:a.slice(0,o)).trim().toLowerCase(),u=(-1===o?"":a.slice(o+1)).trim().replace(/^"|"$/g,"");if("codecs"===s){for(var l=u.split(","),c=0;c<l.length;c++)if(Ue(l[c].trim())&&!_e())return!1;i.push(a)}else if(Me[s]){if(!Me[s](u))return!1}else i.push(a)}return e(i.join("; "))}}}()}catch(e){console.warn("[AxoTube:experimentalResolution] Could not install overrides:",e)}we.addEventListener("configChange",function(e){var t,n=(null===(t=e.detail)||void 0===t?void 0:t.key)||"";("enableExperimentalResolution"===n||"experimentalMaxResolution"===n&&Se("enableExperimentalResolution"))&&setTimeout(function(){return location.reload()},300)})}var He={avc1:["avc1"],vp9:["vp09","vp9"],av01:["av01"]};var ze="__axotubeCodecOwner";if(!window[ze]){window[ze]=!0;try{!function(e){if(window.MediaSource&&"function"==typeof MediaSource.isTypeSupported){var t=function(e){if(!He[e])return[];var t=[];return Object.keys(He).forEach(function(n){n!==e&&(t=t.concat(He[n]))}),t}(e);if(0!==t.length){var n=MediaSource.isTypeSupported.bind(MediaSource);MediaSource.isTypeSupported=function(e){var i=String(e).toLowerCase();if(-1!==i.indexOf("codecs"))for(var r=0;r<t.length;r++)if(-1!==i.indexOf(t[r]))return!1;return n(e)}}}}(Se("videoPreferredCodec"))}catch(e){console.warn("[AxoTube:codecPreference] Could not install codec preference:",e)}we.addEventListener("configChange",function(e){var t;"videoPreferredCodec"===((null===(t=e.detail)||void 0===t?void 0:t.key)||"")&&setTimeout(function(){return location.reload()},300)})}var Ve=function(e){return"string"==typeof e},Ke=function(){var e,t,n=new Promise(function(n,i){e=n,t=i});return n.resolve=e,n.reject=t,n},Ge=function(e){return null==e?"":""+e},Je=/###/g,Xe=function(e){return e&&e.indexOf("###")>-1?e.replace(Je,"."):e},We=function(e){return!e||Ve(e)},qe=function(e,t,n){for(var i=Ve(t)?t.split("."):t,r=0;r<i.length-1;){if(We(e))return{};var a=Xe(i[r]);!e[a]&&n&&(e[a]=new n),e=Object.prototype.hasOwnProperty.call(e,a)?e[a]:{},++r}return We(e)?{}:{obj:e,k:Xe(i[r])}},Ye=function(e,t,n){var i=qe(e,t,Object),r=i.obj,a=i.k;if(void 0===r&&1!==t.length){for(var o=t[t.length-1],s=t.slice(0,t.length-1),u=qe(e,s,Object);void 0===u.obj&&s.length;){var l;o="".concat(s[s.length-1],".").concat(o),s=s.slice(0,s.length-1),null!==(l=u=qe(e,s,Object))&&void 0!==l&&l.obj&&void 0!==u.obj["".concat(u.k,".").concat(o)]&&(u.obj=void 0)}u.obj["".concat(u.k,".").concat(o)]=n}else r[a]=n},Qe=function(e,t){var n=qe(e,t),i=n.obj,r=n.k;if(i&&Object.prototype.hasOwnProperty.call(i,r))return i[r]},Ze=function(e,t,n){for(var i in t)"__proto__"!==i&&"constructor"!==i&&(i in e?Ve(e[i])||e[i]instanceof String||Ve(t[i])||t[i]instanceof String?n&&(e[i]=t[i]):Ze(e[i],t[i],n):e[i]=t[i]);return e},$e=function(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")},et={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"},tt=function(e){return Ve(e)?e.replace(/[&<>"'\/]/g,function(e){return et[e]}):e},nt=[" ",",","?","!",";"],it=new(function(){return p(function e(t){u(this,e),this.capacity=t,this.regExpMap=new Map,this.regExpQueue=[]},[{key:"getRegExp",value:function(e){var t=this.regExpMap.get(e);if(void 0!==t)return t;var n=new RegExp(e);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(e,n),this.regExpQueue.push(e),n}}])}())(20),rt=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:".";if(e){if(e[t]){if(!Object.prototype.hasOwnProperty.call(e,t))return;return e[t]}for(var i=t.split(n),r=e,a=0;a<i.length;){if(!r||"object"!==T(r))return;for(var o=void 0,s="",u=a;u<i.length;++u)if(u!==a&&(s+=n),void 0!==(o=r[s+=i[u]])){if(["string","number","boolean"].indexOf(T(o))>-1&&u<i.length-1)continue;a+=u-a+1;break}r=o}return r}},at=function(e){return null==e?void 0:e.replace(/_/g,"-")},ot={type:"logger",log:function(e){this.output("log",e)},warn:function(e){this.output("warn",e)},error:function(e){this.output("error",e)},output:function(e,t){var n,i;null===(n=console)||void 0===n||null===(n=n[e])||void 0===n||null===(i=n.apply)||void 0===i||i.call(n,console,t)}},st=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};u(this,e),this.init(t,n)}return p(e,[{key:"init",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.prefix=t.prefix||"i18next:",this.logger=e||ot,this.options=t,this.debug=t.debug}},{key:"log",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"log","",!0)}},{key:"warn",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","",!0)}},{key:"error",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"error","")}},{key:"deprecate",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","WARNING DEPRECATED: ",!0)}},{key:"forward",value:function(e,t,n,i){return i&&!this.debug?null:(Ve(e[0])&&(e[0]="".concat(n).concat(this.prefix," ").concat(e[0])),this.logger[t](e))}},{key:"create",value:function(t){return new e(this.logger,E(E({},{prefix:"".concat(this.prefix,":").concat(t,":")}),this.options))}},{key:"clone",value:function(t){return(t=t||this.options).prefix=t.prefix||this.prefix,new e(this.logger,t)}}])}(),ut=new st,lt=function(){return p(function e(){u(this,e),this.observers={}},[{key:"on",value:function(e,t){var n=this;return e.split(" ").forEach(function(e){n.observers[e]||(n.observers[e]=new Map);var i=n.observers[e].get(t)||0;n.observers[e].set(t,i+1)}),this}},{key:"off",value:function(e,t){this.observers[e]&&(t?this.observers[e].delete(t):delete this.observers[e])}},{key:"emit",value:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];this.observers[e]&&Array.from(this.observers[e].entries()).forEach(function(e){for(var t=D(e,2),i=t[0],r=t[1],a=0;a<r;a++)i.apply(void 0,n)});this.observers["*"]&&Array.from(this.observers["*"].entries()).forEach(function(t){for(var i=D(t,2),r=i[0],a=i[1],o=0;o<a;o++)r.apply(r,[e].concat(n))})}}])}(),ct=function(e){function t(e){var n,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{ns:["translation"],defaultNS:"translation"};return u(this,t),(n=o(this,t)).data=e||{},n.options=i,void 0===n.options.keySeparator&&(n.options.keySeparator="."),void 0===n.options.ignoreJSONStructure&&(n.options.ignoreJSONStructure=!0),n}return v(t,e),p(t,[{key:"addNamespaces",value:function(e){this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}},{key:"removeNamespaces",value:function(e){var t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}},{key:"getResource",value:function(e,t,n){var i,r,a,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},s=void 0!==o.keySeparator?o.keySeparator:this.options.keySeparator,u=void 0!==o.ignoreJSONStructure?o.ignoreJSONStructure:this.options.ignoreJSONStructure;if(e.indexOf(".")>-1)r=e.split(".");else if(r=[e,t],n)if(Array.isArray(n))(a=r).push.apply(a,A(n));else if(Ve(n)&&s){var l;(l=r).push.apply(l,A(n.split(s)))}else r.push(n);var c=Qe(this.data,r);return!c&&!t&&!n&&e.indexOf(".")>-1&&(e=r[0],t=r[1],n=r.slice(2).join(".")),!c&&u&&Ve(n)?rt(null===(i=this.data)||void 0===i||null===(i=i[e])||void 0===i?void 0:i[t],n,s):c}},{key:"addResource",value:function(e,t,n,i){var r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{silent:!1},a=void 0!==r.keySeparator?r.keySeparator:this.options.keySeparator,o=[e,t];n&&(o=o.concat(a?n.split(a):n)),e.indexOf(".")>-1&&(i=t,t=(o=e.split("."))[1]),this.addNamespaces(t),Ye(this.data,o,i),r.silent||this.emit("added",e,t,n,i)}},{key:"addResources",value:function(e,t,n){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{silent:!1};for(var r in n)(Ve(n[r])||Array.isArray(n[r]))&&this.addResource(e,t,r,n[r],{silent:!0});i.silent||this.emit("added",e,t,n)}},{key:"addResourceBundle",value:function(e,t,n,i,r){var a=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{silent:!1,skipCopy:!1},o=[e,t];e.indexOf(".")>-1&&(i=n,n=t,t=(o=e.split("."))[1]),this.addNamespaces(t);var s=Qe(this.data,o)||{};a.skipCopy||(n=JSON.parse(JSON.stringify(n))),i?Ze(s,n,r):s=E(E({},s),n),Ye(this.data,o,s),a.silent||this.emit("added",e,t,n)}},{key:"removeResourceBundle",value:function(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit("removed",e,t)}},{key:"hasResourceBundle",value:function(e,t){return void 0!==this.getResource(e,t)}},{key:"getResourceBundle",value:function(e,t){return t||(t=this.options.defaultNS),this.getResource(e,t)}},{key:"getDataByLanguage",value:function(e){return this.data[e]}},{key:"hasLanguageSomeTranslations",value:function(e){var t=this.getDataByLanguage(e);return!!(t&&Object.keys(t)||[]).find(function(e){return t[e]&&Object.keys(t[e]).length>0})}},{key:"toJSON",value:function(){return this.data}}])}(lt),ht={processors:{},addPostProcessor:function(e){this.processors[e.name]=e},handle:function(e,t,n,i,r){var a=this;return e.forEach(function(e){var o,s;t=null!==(o=null===(s=a.processors[e])||void 0===s?void 0:s.process(t,n,i,r))&&void 0!==o?o:t}),t}},dt=Symbol("i18next/PATH_KEY");function pt(e,t){var n,i,r=e(function(){var e,t=[],n=Object.create(null);return n.get=function(i,r){var a,o;return null===(a=e)||void 0===a||null===(o=a.revoke)||void 0===o||o.call(a),r===dt?t:(t.push(r),(e=Proxy.revocable(i,n)).proxy)},Proxy.revocable(Object.create(null),n).proxy}()),a=r[dt],o=null!==(n=null==t?void 0:t.keySeparator)&&void 0!==n?n:".",s=null!==(i=null==t?void 0:t.nsSeparator)&&void 0!==i?i:":";if(a.length>1&&s){var u=null==t?void 0:t.ns;if((u?Array.isArray(u)?u:[u]:[]).includes(a[0]))return"".concat(a[0]).concat(s).concat(a.slice(1).join(o))}return a.join(o)}var ft={},mt=function(e){return!Ve(e)&&"boolean"!=typeof e&&"number"!=typeof e},gt=function(e){function t(e){var n,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return u(this,t),function(e,t,n){e.forEach(function(e){t[e]&&(n[e]=t[e])})}(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],e,n=o(this,t)),n.options=i,void 0===n.options.keySeparator&&(n.options.keySeparator="."),n.logger=ut.create("translator"),n}return v(t,e),p(t,[{key:"changeLanguage",value:function(e){e&&(this.language=e)}},{key:"exists",value:function(e){var t=E({},arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}});if(null==e)return!1;var n=this.resolve(e,t);if(void 0===(null==n?void 0:n.res))return!1;var i=mt(n.res);return!1!==t.returnObjects||!i}},{key:"extractFromKey",value:function(e,t){var n=void 0!==t.nsSeparator?t.nsSeparator:this.options.nsSeparator;void 0===n&&(n=":");var i=void 0!==t.keySeparator?t.keySeparator:this.options.keySeparator,r=t.ns||this.options.defaultNS||[],a=n&&e.indexOf(n)>-1,o=!(this.options.userDefinedKeySeparator||t.keySeparator||this.options.userDefinedNsSeparator||t.nsSeparator||function(e,t,n){t=t||"",n=n||"";var i=nt.filter(function(e){return t.indexOf(e)<0&&n.indexOf(e)<0});if(0===i.length)return!0;var r=it.getRegExp("(".concat(i.map(function(e){return"?"===e?"\\?":e}).join("|"),")")),a=!r.test(e);if(!a){var o=e.indexOf(n);o>0&&!r.test(e.substring(0,o))&&(a=!0)}return a}(e,n,i));if(a&&!o){var s=e.match(this.interpolator.nestingRegexp);if(s&&s.length>0)return{key:e,namespaces:Ve(r)?[r]:r};var u=e.split(n);(n!==i||n===i&&this.options.ns.indexOf(u[0])>-1)&&(r=u.shift()),e=u.join(i)}return{key:e,namespaces:Ve(r)?[r]:r}}},{key:"translate",value:function(e,n,i){var r=this,a="object"===T(n)?E({},n):n;if("object"!==T(a)&&this.options.overloadTranslationOptionHandler&&(a=this.options.overloadTranslationOptionHandler(arguments)),"object"===T(a)&&(a=E({},a)),a||(a={}),null==e)return"";"function"==typeof e&&(e=pt(e,E(E({},this.options),a))),Array.isArray(e)||(e=[String(e)]),e=e.map(function(e){return"function"==typeof e?pt(e,E(E({},r.options),a)):String(e)});var o=void 0!==a.returnDetails?a.returnDetails:this.options.returnDetails,s=void 0!==a.keySeparator?a.keySeparator:this.options.keySeparator,u=this.extractFromKey(e[e.length-1],a),l=u.key,c=u.namespaces,h=c[c.length-1],d=void 0!==a.nsSeparator?a.nsSeparator:this.options.nsSeparator;void 0===d&&(d=":");var p=a.lng||this.language,f=a.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if("cimode"===(null==p?void 0:p.toLowerCase()))return f?o?{res:"".concat(h).concat(d).concat(l),usedKey:l,exactUsedKey:l,usedLng:p,usedNS:h,usedParams:this.getUsedParamsDetails(a)}:"".concat(h).concat(d).concat(l):o?{res:l,usedKey:l,exactUsedKey:l,usedLng:p,usedNS:h,usedParams:this.getUsedParamsDetails(a)}:l;var m=this.resolve(e,a),g=null==m?void 0:m.res,v=(null==m?void 0:m.usedKey)||l,y=(null==m?void 0:m.exactUsedKey)||l,b=void 0!==a.joinArrays?a.joinArrays:this.options.joinArrays,x=!this.i18nFormat||this.i18nFormat.handleAsObject,S=void 0!==a.count&&!Ve(a.count),w=t.hasDefaultValue(a),k=S?this.pluralResolver.getSuffix(p,a.count,a):"",D=a.ordinal&&S?this.pluralResolver.getSuffix(p,a.count,{ordinal:!1}):"",A=S&&!a.ordinal&&0===a.count,C=A&&a["defaultValue".concat(this.options.pluralSeparator,"zero")]||a["defaultValue".concat(k)]||a["defaultValue".concat(D)]||a.defaultValue,P=g;x&&!g&&w&&(P=C);var F=mt(P),B=Object.prototype.toString.apply(P);if(!(x&&P&&F&&["[object Number]","[object Function]","[object RegExp]"].indexOf(B)<0)||Ve(b)&&Array.isArray(P))if(x&&Ve(b)&&Array.isArray(g))(g=g.join(b))&&(g=this.extendTranslation(g,e,a,i));else{var I=!1,L=!1;!this.isValidLookup(g)&&w&&(I=!0,g=C),this.isValidLookup(g)||(L=!0,g=l);var O=(a.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&L?void 0:g,N=w&&C!==g&&this.options.updateMissing;if(L||I||N){if(this.logger.log(N?"updateKey":"missingKey",p,h,l,N?C:g),s){var R=this.resolve(l,E(E({},a),{},{keySeparator:!1}));R&&R.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}var M=[],_=this.languageUtils.getFallbackCodes(this.options.fallbackLng,a.lng||this.language);if("fallback"===this.options.saveMissingTo&&_&&_[0])for(var U=0;U<_.length;U++)M.push(_[U]);else"all"===this.options.saveMissingTo?M=this.languageUtils.toResolveHierarchy(a.lng||this.language):M.push(a.lng||this.language);var j=function(e,t,n){var i,o=w&&n!==g?n:O;r.options.missingKeyHandler?r.options.missingKeyHandler(e,h,t,o,N,a):null!==(i=r.backendConnector)&&void 0!==i&&i.saveMissing&&r.backendConnector.saveMissing(e,h,t,o,N,a),r.emit("missingKey",e,h,t,g)};this.options.saveMissing&&(this.options.saveMissingPlurals&&S?M.forEach(function(e){var t=r.pluralResolver.getSuffixes(e,a);A&&a["defaultValue".concat(r.options.pluralSeparator,"zero")]&&t.indexOf("".concat(r.options.pluralSeparator,"zero"))<0&&t.push("".concat(r.options.pluralSeparator,"zero")),t.forEach(function(t){j([e],l+t,a["defaultValue".concat(t)]||C)})}):j(M,l,C))}g=this.extendTranslation(g,e,a,m,i),L&&g===l&&this.options.appendNamespaceToMissingKey&&(g="".concat(h).concat(d).concat(l)),(L||I)&&this.options.parseMissingKeyHandler&&(g=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?"".concat(h).concat(d).concat(l):l,I?g:void 0,a))}else{if(!a.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");var H=this.options.returnedObjectHandler?this.options.returnedObjectHandler(v,P,E(E({},a),{},{ns:c})):"key '".concat(l," (").concat(this.language,")' returned an object instead of string.");return o?(m.res=H,m.usedParams=this.getUsedParamsDetails(a),m):H}if(s){var z=Array.isArray(P),V=z?[]:{},K=z?y:v;for(var G in P)if(Object.prototype.hasOwnProperty.call(P,G)){var J="".concat(K).concat(s).concat(G);V[G]=w&&!g?this.translate(J,E(E({},a),{},{defaultValue:mt(C)?C[G]:void 0},{joinArrays:!1,ns:c})):this.translate(J,E(E({},a),{joinArrays:!1,ns:c})),V[G]===J&&(V[G]=P[G])}g=V}}return o?(m.res=g,m.usedParams=this.getUsedParamsDetails(a),m):g}},{key:"extendTranslation",value:function(e,t,n,i,r){var a,o=this;if(null!==(a=this.i18nFormat)&&void 0!==a&&a.parse)e=this.i18nFormat.parse(e,E(E({},this.options.interpolation.defaultVariables),n),n.lng||this.language||i.usedLng,i.usedNS,i.usedKey,{resolved:i});else if(!n.skipInterpolation){var s;n.interpolation&&this.interpolator.init(E(E({},n),{interpolation:E(E({},this.options.interpolation),n.interpolation)}));var u,l=Ve(e)&&(void 0!==(null==n||null===(s=n.interpolation)||void 0===s?void 0:s.skipOnVariables)?n.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);if(l){var c=e.match(this.interpolator.nestingRegexp);u=c&&c.length}var h=n.replace&&!Ve(n.replace)?n.replace:n;if(this.options.interpolation.defaultVariables&&(h=E(E({},this.options.interpolation.defaultVariables),h)),e=this.interpolator.interpolate(e,h,n.lng||this.language||i.usedLng,n),l){var d=e.match(this.interpolator.nestingRegexp);u<(d&&d.length)&&(n.nest=!1)}!n.lng&&i&&i.res&&(n.lng=this.language||i.usedLng),!1!==n.nest&&(e=this.interpolator.nest(e,function(){for(var e=arguments.length,i=new Array(e),a=0;a<e;a++)i[a]=arguments[a];return(null==r?void 0:r[0])!==i[0]||n.context?o.translate.apply(o,i.concat([t])):(o.logger.warn("It seems you are nesting recursively key: ".concat(i[0]," in key: ").concat(t[0])),null)},n)),n.interpolation&&this.interpolator.reset()}var p=n.postProcess||this.options.postProcess,f=Ve(p)?[p]:p;return null!=e&&null!=f&&f.length&&!1!==n.applyPostProcessor&&(e=ht.handle(f,e,t,this.options&&this.options.postProcessPassResolved?E({i18nResolved:E(E({},i),{},{usedParams:this.getUsedParamsDetails(n)})},n):n,this)),e}},{key:"resolve",value:function(e){var t,n,i,r,a,o=this,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return Ve(e)&&(e=[e]),Array.isArray(e)&&(e=e.map(function(e){return"function"==typeof e?pt(e,E(E({},o.options),s)):e})),e.forEach(function(e){if(!o.isValidLookup(t)){var u=o.extractFromKey(e,s),l=u.key;n=l;var c=u.namespaces;o.options.fallbackNS&&(c=c.concat(o.options.fallbackNS));var h=void 0!==s.count&&!Ve(s.count),d=h&&!s.ordinal&&0===s.count,p=void 0!==s.context&&(Ve(s.context)||"number"==typeof s.context)&&""!==s.context,f=s.lngs?s.lngs:o.languageUtils.toResolveHierarchy(s.lng||o.language,s.fallbackLng);c.forEach(function(e){var u,c;o.isValidLookup(t)||(a=e,ft["".concat(f[0],"-").concat(e)]||null===(u=o.utils)||void 0===u||!u.hasLoadedNamespace||null!==(c=o.utils)&&void 0!==c&&c.hasLoadedNamespace(a)||(ft["".concat(f[0],"-").concat(e)]=!0,o.logger.warn('key "'.concat(n,'" for languages "').concat(f.join(", "),'" won\'t get resolved as namespace "').concat(a,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),f.forEach(function(n){var a;if(!o.isValidLookup(t)){r=n;var u,c=[l];if(null!==(a=o.i18nFormat)&&void 0!==a&&a.addLookupKeys)o.i18nFormat.addLookupKeys(c,l,n,e,s);else{var f;h&&(f=o.pluralResolver.getSuffix(n,s.count,s));var m="".concat(o.options.pluralSeparator,"zero"),g="".concat(o.options.pluralSeparator,"ordinal").concat(o.options.pluralSeparator);if(h&&(s.ordinal&&0===f.indexOf(g)&&c.push(l+f.replace(g,o.options.pluralSeparator)),c.push(l+f),d&&c.push(l+m)),p){var v="".concat(l).concat(o.options.contextSeparator||"_").concat(s.context);c.push(v),h&&(s.ordinal&&0===f.indexOf(g)&&c.push(v+f.replace(g,o.options.pluralSeparator)),c.push(v+f),d&&c.push(v+m))}}for(;u=c.pop();)o.isValidLookup(t)||(i=u,t=o.getResource(n,e,u,s))}}))})}}),{res:t,usedKey:n,exactUsedKey:i,usedLng:r,usedNS:a}}},{key:"isValidLookup",value:function(e){return!(void 0===e||!this.options.returnNull&&null===e||!this.options.returnEmptyString&&""===e)}},{key:"getResource",value:function(e,t,n){var i,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return null!==(i=this.i18nFormat)&&void 0!==i&&i.getResource?this.i18nFormat.getResource(e,t,n,r):this.resourceStore.getResource(e,t,n,r)}},{key:"getUsedParamsDetails",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.replace&&!Ve(e.replace),n=t?e.replace:e;if(t&&void 0!==e.count&&(n.count=e.count),this.options.interpolation.defaultVariables&&(n=E(E({},this.options.interpolation.defaultVariables),n)),!t){n=E({},n);var i,r=f(["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"]);try{for(r.s();!(i=r.n()).done;){delete n[i.value]}}catch(e){r.e(e)}finally{r.f()}}return n}}],[{key:"hasDefaultValue",value:function(e){var t="defaultValue";for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t===n.substring(0,12)&&void 0!==e[n])return!0;return!1}}])}(lt),vt=function(){return p(function e(t){u(this,e),this.options=t,this.supportedLngs=this.options.supportedLngs||!1,this.logger=ut.create("languageUtils")},[{key:"getScriptPartFromCode",value:function(e){if(!(e=at(e))||e.indexOf("-")<0)return null;var t=e.split("-");return 2===t.length?null:(t.pop(),"x"===t[t.length-1].toLowerCase()?null:this.formatLanguageCode(t.join("-")))}},{key:"getLanguagePartFromCode",value:function(e){if(!(e=at(e))||e.indexOf("-")<0)return e;var t=e.split("-");return this.formatLanguageCode(t[0])}},{key:"formatLanguageCode",value:function(e){if(Ve(e)&&e.indexOf("-")>-1){var t;try{t=Intl.getCanonicalLocales(e)[0]}catch(e){}return t&&this.options.lowerCaseLng&&(t=t.toLowerCase()),t||(this.options.lowerCaseLng?e.toLowerCase():e)}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}},{key:"isSupportedCode",value:function(e){return("languageOnly"===this.options.load||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(e)>-1}},{key:"getBestMatchFromCodes",value:function(e){var t,n=this;return e?(e.forEach(function(e){if(!t){var i=n.formatLanguageCode(e);n.options.supportedLngs&&!n.isSupportedCode(i)||(t=i)}}),!t&&this.options.supportedLngs&&e.forEach(function(e){if(!t){var i=n.getScriptPartFromCode(e);if(n.isSupportedCode(i))return t=i;var r=n.getLanguagePartFromCode(e);if(n.isSupportedCode(r))return t=r;t=n.options.supportedLngs.find(function(e){return e===r?e:e.indexOf("-")<0&&r.indexOf("-")<0?void 0:e.indexOf("-")>0&&r.indexOf("-")<0&&e.substring(0,e.indexOf("-"))===r||0===e.indexOf(r)&&r.length>1?e:void 0})}}),t||(t=this.getFallbackCodes(this.options.fallbackLng)[0]),t):null}},{key:"getFallbackCodes",value:function(e,t){if(!e)return[];if("function"==typeof e&&(e=e(t)),Ve(e)&&(e=[e]),Array.isArray(e))return e;if(!t)return e.default||[];var n=e[t];return n||(n=e[this.getScriptPartFromCode(t)]),n||(n=e[this.formatLanguageCode(t)]),n||(n=e[this.getLanguagePartFromCode(t)]),n||(n=e.default),n||[]}},{key:"toResolveHierarchy",value:function(e,t){var n=this,i=this.getFallbackCodes((!1===t?[]:t)||this.options.fallbackLng||[],e),r=[],a=function(e){e&&(n.isSupportedCode(e)?r.push(e):n.logger.warn("rejecting language code not found in supportedLngs: ".concat(e)))};return Ve(e)&&(e.indexOf("-")>-1||e.indexOf("_")>-1)?("languageOnly"!==this.options.load&&a(this.formatLanguageCode(e)),"languageOnly"!==this.options.load&&"currentOnly"!==this.options.load&&a(this.getScriptPartFromCode(e)),"currentOnly"!==this.options.load&&a(this.getLanguagePartFromCode(e))):Ve(e)&&a(this.formatLanguageCode(e)),i.forEach(function(e){r.indexOf(e)<0&&a(n.formatLanguageCode(e))}),r}}])}(),yt={zero:0,one:1,two:2,few:3,many:4,other:5},bt={select:function(e){return 1===e?"one":"other"},resolvedOptions:function(){return{pluralCategories:["one","other"]}}},xt=function(){return p(function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};u(this,e),this.languageUtils=t,this.options=n,this.logger=ut.create("pluralResolver"),this.pluralRulesCache={}},[{key:"clearCache",value:function(){this.pluralRulesCache={}}},{key:"getRule",value:function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=at("dev"===e?"en":e),r=n.ordinal?"ordinal":"cardinal",a=JSON.stringify({cleanedCode:i,type:r});if(a in this.pluralRulesCache)return this.pluralRulesCache[a];try{t=new Intl.PluralRules(i,{type:r})}catch(i){if("undefined"==typeof Intl)return this.logger.error("No Intl support, please use an Intl polyfill!"),bt;if(!e.match(/-|_/))return bt;var o=this.languageUtils.getLanguagePartFromCode(e);t=this.getRule(o,n)}return this.pluralRulesCache[a]=t,t}},{key:"needsPlural",value:function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=this.getRule(e,n);return i||(i=this.getRule("dev",n)),(null===(t=i)||void 0===t?void 0:t.resolvedOptions().pluralCategories.length)>1}},{key:"getPluralFormsOfKey",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.getSuffixes(e,n).map(function(e){return"".concat(t).concat(e)})}},{key:"getSuffixes",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=this.getRule(e,n);return i||(i=this.getRule("dev",n)),i?i.resolvedOptions().pluralCategories.sort(function(e,t){return yt[e]-yt[t]}).map(function(e){return"".concat(t.options.prepend).concat(n.ordinal?"ordinal".concat(t.options.prepend):"").concat(e)}):[]}},{key:"getSuffix",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=this.getRule(e,n);return i?"".concat(this.options.prepend).concat(n.ordinal?"ordinal".concat(this.options.prepend):"").concat(i.select(t)):(this.logger.warn("no plural rule found for: ".concat(e)),this.getSuffix("dev",t,n))}}])}(),St=function(e,t,n){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:".",r=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],a=function(e,t,n){var i=Qe(e,n);return void 0!==i?i:Qe(t,n)}(e,t,n);return!a&&r&&Ve(n)&&void 0===(a=rt(e,n,i))&&(a=rt(t,n,i)),a},Et=function(e){return e.replace(/\$/g,"$$$$")},wt=function(){return p(function e(){var t,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};u(this,e),this.logger=ut.create("interpolator"),this.options=n,this.format=(null==n||null===(t=n.interpolation)||void 0===t?void 0:t.format)||function(e){return e},this.init(n)},[{key:"init",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e.interpolation||(e.interpolation={escapeValue:!0});var t=e.interpolation,n=t.escape,i=t.escapeValue,r=t.useRawValueToEscape,a=t.prefix,o=t.prefixEscaped,s=t.suffix,u=t.suffixEscaped,l=t.formatSeparator,c=t.unescapeSuffix,h=t.unescapePrefix,d=t.nestingPrefix,p=t.nestingPrefixEscaped,f=t.nestingSuffix,m=t.nestingSuffixEscaped,g=t.nestingOptionsSeparator,v=t.maxReplaces,y=t.alwaysFormat;this.escape=void 0!==n?n:tt,this.escapeValue=void 0===i||i,this.useRawValueToEscape=void 0!==r&&r,this.prefix=a?$e(a):o||"{{",this.suffix=s?$e(s):u||"}}",this.formatSeparator=l||",",this.unescapePrefix=c?"":h||"-",this.unescapeSuffix=this.unescapePrefix?"":c||"",this.nestingPrefix=d?$e(d):p||$e("$t("),this.nestingSuffix=f?$e(f):m||$e(")"),this.nestingOptionsSeparator=g||",",this.maxReplaces=v||1e3,this.alwaysFormat=void 0!==y&&y,this.resetRegExp()}},{key:"reset",value:function(){this.options&&this.init(this.options)}},{key:"resetRegExp",value:function(){var e=function(e,t){return(null==e?void 0:e.source)===t?(e.lastIndex=0,e):new RegExp(t,"g")};this.regexp=e(this.regexp,"".concat(this.prefix,"(.+?)").concat(this.suffix)),this.regexpUnescape=e(this.regexpUnescape,"".concat(this.prefix).concat(this.unescapePrefix,"(.+?)").concat(this.unescapeSuffix).concat(this.suffix)),this.nestingRegexp=e(this.nestingRegexp,"".concat(this.nestingPrefix,"((?:[^()\"']+|\"[^\"]*\"|'[^']*'|\\((?:[^()]|\"[^\"]*\"|'[^']*')*\\))*?)").concat(this.nestingSuffix))}},{key:"interpolate",value:function(e,t,n,i){var r,a,o,s,u=this,l=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},c=function(e){if(e.indexOf(u.formatSeparator)<0){var r=St(t,l,e,u.options.keySeparator,u.options.ignoreJSONStructure);return u.alwaysFormat?u.format(r,void 0,n,E(E(E({},i),t),{},{interpolationkey:e})):r}var a=e.split(u.formatSeparator),o=a.shift().trim(),s=a.join(u.formatSeparator).trim();return u.format(St(t,l,o,u.options.keySeparator,u.options.ignoreJSONStructure),s,n,E(E(E({},i),t),{},{interpolationkey:o}))};this.resetRegExp();var h=(null==i?void 0:i.missingInterpolationHandler)||this.options.missingInterpolationHandler,d=void 0!==(null==i||null===(r=i.interpolation)||void 0===r?void 0:r.skipOnVariables)?i.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:function(e){return Et(e)}},{regex:this.regexp,safeValue:function(e){return u.escapeValue?Et(u.escape(e)):Et(e)}}].forEach(function(t){for(s=0;a=t.regex.exec(e);){var n=a[1].trim();if(void 0===(o=c(n)))if("function"==typeof h){var r=h(e,a,i);o=Ve(r)?r:""}else if(i&&Object.prototype.hasOwnProperty.call(i,n))o="";else{if(d){o=a[0];continue}u.logger.warn("missed to pass in variable ".concat(n," for interpolating ").concat(e)),o=""}else Ve(o)||u.useRawValueToEscape||(o=Ge(o));var l=t.safeValue(o);if(e=e.replace(a[0],l),d?(t.regex.lastIndex+=o.length,t.regex.lastIndex-=a[0].length):t.regex.lastIndex=0,++s>=u.maxReplaces)break}}),e}},{key:"nest",value:function(e,t){for(var n,i,r,a=this,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},s=function(e,t){var n,i,o=a.nestingOptionsSeparator;if(e.indexOf(o)<0)return e;var s=e.split(new RegExp("".concat($e(o),"[ ]*{"))),u="{".concat(s[1]);e=s[0];var l=(u=a.interpolate(u,r)).match(/'/g),c=u.match(/"/g);((null!==(n=null==l?void 0:l.length)&&void 0!==n?n:0)%2==0&&!c||(null!==(i=null==c?void 0:c.length)&&void 0!==i?i:0)%2!=0)&&(u=u.replace(/'/g,'"'));try{r=JSON.parse(u),t&&(r=E(E({},t),r))}catch(t){return a.logger.warn("failed parsing options string in nesting for key ".concat(e),t),"".concat(e).concat(o).concat(u)}return r.defaultValue&&r.defaultValue.indexOf(a.prefix)>-1&&delete r.defaultValue,e};n=this.nestingRegexp.exec(e);){var u=[];(r=(r=E({},o)).replace&&!Ve(r.replace)?r.replace:r).applyPostProcessor=!1,delete r.defaultValue;var l=/{.*}/.test(n[1])?n[1].lastIndexOf("}")+1:n[1].indexOf(this.formatSeparator);if(-1!==l&&(u=n[1].slice(l).split(this.formatSeparator).map(function(e){return e.trim()}).filter(Boolean),n[1]=n[1].slice(0,l)),(i=t(s.call(this,n[1].trim(),r),r))&&n[0]===e&&!Ve(i))return i;Ve(i)||(i=Ge(i)),i||(this.logger.warn("missed to resolve ".concat(n[1]," for nesting ").concat(e)),i=""),u.length&&(i=u.reduce(function(e,t){return a.format(e,t,o.lng,E(E({},o),{},{interpolationkey:n[1].trim()}))},i.trim())),e=e.replace(n[0],i),this.regexp.lastIndex=0}return e}}])}(),kt=function(e){var t=e.toLowerCase().trim(),n={};if(e.indexOf("(")>-1){var i=e.split("(");t=i[0].toLowerCase().trim();var a=i[1].substring(0,i[1].length-1);if("currency"===t&&a.indexOf(":")<0)n.currency||(n.currency=a.trim());else if("relativetime"===t&&a.indexOf(":")<0)n.range||(n.range=a.trim());else{a.split(";").forEach(function(e){if(e){var t=e.split(":"),i=r(u=t)||b(u)||P(u)||x(),a=i[0],o=i.slice(1).join(":").trim().replace(/^'+|'+$/g,""),s=a.trim();n[s]||(n[s]=o),"false"===o&&(n[s]=!1),"true"===o&&(n[s]=!0),isNaN(o)||(n[s]=parseInt(o,10))}var u})}}return{formatName:t,formatOptions:n}},Dt=function(e){var t={};return function(n,i,r){var a=r;r&&r.interpolationkey&&r.formatParams&&r.formatParams[r.interpolationkey]&&r[r.interpolationkey]&&(a=E(E({},a),{},m({},r.interpolationkey,void 0)));var o=i+JSON.stringify(a),s=t[o];return s||(s=e(at(i),r),t[o]=s),s(n)}},At=function(e){return function(t,n,i){return e(at(n),i)(t)}},Ct=function(){return p(function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};u(this,e),this.logger=ut.create("formatter"),this.options=t,this.init(t)},[{key:"init",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}};this.formatSeparator=t.interpolation.formatSeparator||",";var n=t.cacheInBuiltFormats?Dt:At;this.formats={number:n(function(e,t){var n=new Intl.NumberFormat(e,E({},t));return function(e){return n.format(e)}}),currency:n(function(e,t){var n=new Intl.NumberFormat(e,E(E({},t),{},{style:"currency"}));return function(e){return n.format(e)}}),datetime:n(function(e,t){var n=new Intl.DateTimeFormat(e,E({},t));return function(e){return n.format(e)}}),relativetime:n(function(e,t){var n=new Intl.RelativeTimeFormat(e,E({},t));return function(e){return n.format(e,t.range||"day")}}),list:n(function(e,t){var n=new Intl.ListFormat(e,E({},t));return function(e){return n.format(e)}})}}},{key:"add",value:function(e,t){this.formats[e.toLowerCase().trim()]=t}},{key:"addCached",value:function(e,t){this.formats[e.toLowerCase().trim()]=Dt(t)}},{key:"format",value:function(e,t,n){var i=this,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},a=t.split(this.formatSeparator);if(a.length>1&&a[0].indexOf("(")>1&&a[0].indexOf(")")<0&&a.find(function(e){return e.indexOf(")")>-1})){var o=a.findIndex(function(e){return e.indexOf(")")>-1});a[0]=[a[0]].concat(A(a.splice(1,o))).join(this.formatSeparator)}return a.reduce(function(e,t){var a=kt(t),o=a.formatName,s=a.formatOptions;if(i.formats[o]){var u=e;try{var l,c=(null==r||null===(l=r.formatParams)||void 0===l?void 0:l[r.interpolationkey])||{},h=c.locale||c.lng||r.locale||r.lng||n;u=i.formats[o](e,h,E(E(E({},s),r),c))}catch(e){i.logger.warn(e)}return u}return i.logger.warn("there was no format function for ".concat(o)),e},e)}}])}(),Tt=function(e){function t(e,n,i){var r,a,s,l=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return u(this,t),(s=o(this,t)).backend=e,s.store=n,s.services=i,s.languageUtils=i.languageUtils,s.options=l,s.logger=ut.create("backendConnector"),s.waitingReads=[],s.maxParallelReads=l.maxParallelReads||10,s.readingCalls=0,s.maxRetries=l.maxRetries>=0?l.maxRetries:5,s.retryTimeout=l.retryTimeout>=1?l.retryTimeout:350,s.state={},s.queue=[],null===(r=s.backend)||void 0===r||null===(a=r.init)||void 0===a||a.call(r,i,l.backend,l),s}return v(t,e),p(t,[{key:"queueLoad",value:function(e,t,n,i){var r=this,a={},o={},s={},u={};return e.forEach(function(e){var i=!0;t.forEach(function(t){var s="".concat(e,"|").concat(t);!n.reload&&r.store.hasResourceBundle(e,t)?r.state[s]=2:r.state[s]<0||(1===r.state[s]?void 0===o[s]&&(o[s]=!0):(r.state[s]=1,i=!1,void 0===o[s]&&(o[s]=!0),void 0===a[s]&&(a[s]=!0),void 0===u[t]&&(u[t]=!0)))}),i||(s[e]=!0)}),(Object.keys(a).length||Object.keys(o).length)&&this.queue.push({pending:o,pendingCount:Object.keys(o).length,loaded:{},errors:[],callback:i}),{toLoad:Object.keys(a),pending:Object.keys(o),toLoadLanguages:Object.keys(s),toLoadNamespaces:Object.keys(u)}}},{key:"loaded",value:function(e,t,n){var i=e.split("|"),r=i[0],a=i[1];t&&this.emit("failedLoading",r,a,t),!t&&n&&this.store.addResourceBundle(r,a,n,void 0,void 0,{skipCopy:!0}),this.state[e]=t?-1:2,t&&n&&(this.state[e]=0);var o={};this.queue.forEach(function(n){var i,s,u,l,c;i=n.loaded,s=a,u=qe(i,[r],Object),l=u.obj,c=u.k,l[c]=l[c]||[],l[c].push(s),function(e,t){void 0!==e.pending[t]&&(delete e.pending[t],e.pendingCount--)}(n,e),t&&n.errors.push(t),0!==n.pendingCount||n.done||(Object.keys(n.loaded).forEach(function(e){o[e]||(o[e]={});var t=n.loaded[e];t.length&&t.forEach(function(t){void 0===o[e][t]&&(o[e][t]=!0)})}),n.done=!0,n.errors.length?n.callback(n.errors):n.callback())}),this.emit("loaded",o),this.queue=this.queue.filter(function(e){return!e.done})}},{key:"read",value:function(e,t,n){var i=this,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:this.retryTimeout,o=arguments.length>5?arguments[5]:void 0;if(!e.length)return o(null,{});if(this.readingCalls>=this.maxParallelReads)this.waitingReads.push({lng:e,ns:t,fcName:n,tried:r,wait:a,callback:o});else{this.readingCalls++;var s=function(s,u){if(i.readingCalls--,i.waitingReads.length>0){var l=i.waitingReads.shift();i.read(l.lng,l.ns,l.fcName,l.tried,l.wait,l.callback)}s&&u&&r<i.maxRetries?setTimeout(function(){i.read.call(i,e,t,n,r+1,2*a,o)},a):o(s,u)},u=this.backend[n].bind(this.backend);if(2!==u.length)return u(e,t,s);try{var l=u(e,t);l&&"function"==typeof l.then?l.then(function(e){return s(null,e)}).catch(s):s(null,l)}catch(e){s(e)}}}},{key:"prepareLoading",value:function(e,t){var n=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),r&&r();Ve(e)&&(e=this.languageUtils.toResolveHierarchy(e)),Ve(t)&&(t=[t]);var a=this.queueLoad(e,t,i,r);if(!a.toLoad.length)return a.pending.length||r(),null;a.toLoad.forEach(function(e){n.loadOne(e)})}},{key:"load",value:function(e,t,n){this.prepareLoading(e,t,{},n)}},{key:"reload",value:function(e,t,n){this.prepareLoading(e,t,{reload:!0},n)}},{key:"loadOne",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",i=e.split("|"),r=i[0],a=i[1];this.read(r,a,"read",void 0,void 0,function(i,o){i&&t.logger.warn("".concat(n,"loading namespace ").concat(a," for language ").concat(r," failed"),i),!i&&o&&t.logger.log("".concat(n,"loaded namespace ").concat(a," for language ").concat(r),o),t.loaded(e,i,o)})}},{key:"saveMissing",value:function(e,t,n,i,r){var a,o,s,u=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{},l=arguments.length>6&&void 0!==arguments[6]?arguments[6]:function(){};if(null===(a=this.services)||void 0===a||null===(a=a.utils)||void 0===a||!a.hasLoadedNamespace||null!==(o=this.services)&&void 0!==o&&null!==(o=o.utils)&&void 0!==o&&o.hasLoadedNamespace(t)){if(null!=n&&""!==n){if(null!==(s=this.backend)&&void 0!==s&&s.create){var c=E(E({},u),{},{isUpdate:r}),h=this.backend.create.bind(this.backend);if(h.length<6)try{var d;(d=5===h.length?h(e,t,n,i,c):h(e,t,n,i))&&"function"==typeof d.then?d.then(function(e){return l(null,e)}).catch(l):l(null,d)}catch(e){l(e)}else h(e,t,n,i,l,c)}e&&e[0]&&this.store.addResource(e[0],t,n,i)}}else this.logger.warn('did not save key "'.concat(n,'" as the namespace "').concat(t,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")}}])}(lt),Pt=function(){return{debug:!1,initAsync:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:function(e){var t={};if("object"===T(e[1])&&(t=e[1]),Ve(e[1])&&(t.defaultValue=e[1]),Ve(e[2])&&(t.tDescription=e[2]),"object"===T(e[2])||"object"===T(e[3])){var n=e[3]||e[2];Object.keys(n).forEach(function(e){t[e]=n[e]})}return t},interpolation:{escapeValue:!0,format:function(e){return e},prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0},cacheInBuiltFormats:!0}},Ft=function(e){var t,n;return Ve(e.ns)&&(e.ns=[e.ns]),Ve(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),Ve(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),(null===(t=e.supportedLngs)||void 0===t||null===(n=t.indexOf)||void 0===n?void 0:n.call(t,"cimode"))<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),"boolean"==typeof e.initImmediate&&(e.initAsync=e.initImmediate),e},Bt=function(){},It="__i18next_supportNoticeShown",Lt=function(e){function t(){var e,n,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;if(u(this,t),(e=o(this,t)).options=Ft(i),e.services={},e.logger=ut,e.modules={external:[]},n=e,Object.getOwnPropertyNames(Object.getPrototypeOf(n)).forEach(function(e){"function"==typeof n[e]&&(n[e]=n[e].bind(n))}),r&&!e.isInitialized&&!i.isClone){if(!e.options.initAsync)return e.init(i,r),w(e,e);setTimeout(function(){e.init(i,r)},0)}return e}return v(t,e),p(t,[{key:"init",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0;this.isInitializing=!0,"function"==typeof t&&(n=t,t={}),null==t.defaultNS&&t.ns&&(Ve(t.ns)?t.defaultNS=t.ns:t.ns.indexOf("translation")<0&&(t.defaultNS=t.ns[0]));var i,r,a,o,s,u,l=Pt();this.options=E(E(E({},l),this.options),Ft(t)),this.options.interpolation=E(E({},l.interpolation),this.options.interpolation),void 0!==t.keySeparator&&(this.options.userDefinedKeySeparator=t.keySeparator),void 0!==t.nsSeparator&&(this.options.userDefinedNsSeparator=t.nsSeparator),"function"!=typeof this.options.overloadTranslationOptionHandler&&(this.options.overloadTranslationOptionHandler=l.overloadTranslationOptionHandler),!1===this.options.showSupportNotice||((null==(i=this)||null===(r=i.modules)||void 0===r||null===(r=r.backend)||void 0===r||null===(r=r.name)||void 0===r?void 0:r.indexOf("Locize"))>0||(null==i||null===(a=i.modules)||void 0===a||null===(a=a.backend)||void 0===a||null===(a=a.constructor)||void 0===a||null===(a=a.name)||void 0===a?void 0:a.indexOf("Locize"))>0||null!=i&&null!==(o=i.options)&&void 0!==o&&null!==(o=o.backend)&&void 0!==o&&o.backends&&i.options.backend.backends.some(function(e){var t,n;return(null==e||null===(t=e.name)||void 0===t?void 0:t.indexOf("Locize"))>0||(null==e||null===(n=e.constructor)||void 0===n||null===(n=n.name)||void 0===n?void 0:n.indexOf("Locize"))>0})||null!=i&&null!==(s=i.options)&&void 0!==s&&null!==(s=s.backend)&&void 0!==s&&s.projectId||null!=i&&null!==(u=i.options)&&void 0!==u&&null!==(u=u.backend)&&void 0!==u&&u.backendOptions&&i.options.backend.backendOptions.some(function(e){return null==e?void 0:e.projectId}))||"undefined"!=typeof globalThis&&globalThis[It]||("undefined"!=typeof console&&void 0!==console.info&&console.info("🌐 i18next is made possible by our own product, Locize — consider powering your project with managed localization (AI, CDN, integrations): https://locize.com 💙"),"undefined"!=typeof globalThis&&(globalThis[It]=!0));var c=function(e){return e?"function"==typeof e?new e:e:null};if(!this.options.isClone){var h;this.modules.logger?ut.init(c(this.modules.logger),this.options):ut.init(null,this.options),h=this.modules.formatter?this.modules.formatter:Ct;var d=new vt(this.options);this.store=new ct(this.options.resources,this.options);var p=this.services;p.logger=ut,p.resourceStore=this.store,p.languageUtils=d,p.pluralResolver=new xt(d,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),this.options.interpolation.format&&this.options.interpolation.format!==l.interpolation.format&&this.logger.deprecate("init: you are still using the legacy format function, please use the new approach: https://www.i18next.com/translation-function/formatting"),!h||this.options.interpolation.format&&this.options.interpolation.format!==l.interpolation.format||(p.formatter=c(h),p.formatter.init&&p.formatter.init(p,this.options),this.options.interpolation.format=p.formatter.format.bind(p.formatter)),p.interpolator=new wt(this.options),p.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},p.backendConnector=new Tt(c(this.modules.backend),p.resourceStore,p,this.options),p.backendConnector.on("*",function(t){for(var n=arguments.length,i=new Array(n>1?n-1:0),r=1;r<n;r++)i[r-1]=arguments[r];e.emit.apply(e,[t].concat(i))}),this.modules.languageDetector&&(p.languageDetector=c(this.modules.languageDetector),p.languageDetector.init&&p.languageDetector.init(p,this.options.detection,this.options)),this.modules.i18nFormat&&(p.i18nFormat=c(this.modules.i18nFormat),p.i18nFormat.init&&p.i18nFormat.init(this)),this.translator=new gt(this.services,this.options),this.translator.on("*",function(t){for(var n=arguments.length,i=new Array(n>1?n-1:0),r=1;r<n;r++)i[r-1]=arguments[r];e.emit.apply(e,[t].concat(i))}),this.modules.external.forEach(function(t){t.init&&t.init(e)})}if(this.format=this.options.interpolation.format,n||(n=Bt),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){var f=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);f.length>0&&"dev"!==f[0]&&(this.options.lng=f[0])}this.services.languageDetector||this.options.lng||this.logger.warn("init: no languageDetector is used and no lng is defined");["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(function(t){e[t]=function(){var n;return(n=e.store)[t].apply(n,arguments)}});["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(function(t){e[t]=function(){var n;return(n=e.store)[t].apply(n,arguments),e}});var m=Ke(),g=function(){var t=function(t,i){e.isInitializing=!1,e.isInitialized&&!e.initializedStoreOnce&&e.logger.warn("init: i18next is already initialized. You should call init just once!"),e.isInitialized=!0,e.options.isClone||e.logger.log("initialized",e.options),e.emit("initialized",e.options),m.resolve(i),n(t,i)};if(e.languages&&!e.isInitialized)return t(null,e.t.bind(e));e.changeLanguage(e.options.lng,t)};return this.options.resources||!this.options.initAsync?g():setTimeout(g,0),m}},{key:"loadResources",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Bt,i=Ve(e)?e:this.language;if("function"==typeof e&&(n=e),!this.options.resources||this.options.partialBundledLanguages){var r,a;if("cimode"===(null==i?void 0:i.toLowerCase())&&(!this.options.preload||0===this.options.preload.length))return n();var o=[],s=function(e){e&&("cimode"!==e&&t.services.languageUtils.toResolveHierarchy(e).forEach(function(e){"cimode"!==e&&o.indexOf(e)<0&&o.push(e)}))};if(i)s(i);else this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(function(e){return s(e)});null===(r=this.options.preload)||void 0===r||null===(a=r.forEach)||void 0===a||a.call(r,function(e){return s(e)}),this.services.backendConnector.load(o,this.options.ns,function(e){e||t.resolvedLanguage||!t.language||t.setResolvedLanguage(t.language),n(e)})}else n(null)}},{key:"reloadResources",value:function(e,t,n){var i=Ke();return"function"==typeof e&&(n=e,e=void 0),"function"==typeof t&&(n=t,t=void 0),e||(e=this.languages),t||(t=this.options.ns),n||(n=Bt),this.services.backendConnector.reload(e,t,function(e){i.resolve(),n(e)}),i}},{key:"use",value:function(e){if(!e)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!e.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return"backend"===e.type&&(this.modules.backend=e),("logger"===e.type||e.log&&e.warn&&e.error)&&(this.modules.logger=e),"languageDetector"===e.type&&(this.modules.languageDetector=e),"i18nFormat"===e.type&&(this.modules.i18nFormat=e),"postProcessor"===e.type&&ht.addPostProcessor(e),"formatter"===e.type&&(this.modules.formatter=e),"3rdParty"===e.type&&this.modules.external.push(e),this}},{key:"setResolvedLanguage",value:function(e){if(e&&this.languages&&!(["cimode","dev"].indexOf(e)>-1)){for(var t=0;t<this.languages.length;t++){var n=this.languages[t];if(!(["cimode","dev"].indexOf(n)>-1)&&this.store.hasLanguageSomeTranslations(n)){this.resolvedLanguage=n;break}}!this.resolvedLanguage&&this.languages.indexOf(e)<0&&this.store.hasLanguageSomeTranslations(e)&&(this.resolvedLanguage=e,this.languages.unshift(e))}}},{key:"changeLanguage",value:function(e,t){var n=this;this.isLanguageChangingTo=e;var i=Ke();this.emit("languageChanging",e);var r=function(e){n.language=e,n.languages=n.services.languageUtils.toResolveHierarchy(e),n.resolvedLanguage=void 0,n.setResolvedLanguage(e)},a=function(a){e||a||!n.services.languageDetector||(a=[]);var o,s,u=Ve(a)?a:a&&a[0],l=n.store.hasLanguageSomeTranslations(u)?u:n.services.languageUtils.getBestMatchFromCodes(Ve(a)?[a]:a);l&&(n.language||r(l),n.translator.language||n.translator.changeLanguage(l),null===(o=n.services.languageDetector)||void 0===o||null===(s=o.cacheUserLanguage)||void 0===s||s.call(o,l));n.loadResources(l,function(a){!function(a,o){o?n.isLanguageChangingTo===e&&(r(o),n.translator.changeLanguage(o),n.isLanguageChangingTo=void 0,n.emit("languageChanged",o),n.logger.log("languageChanged",o)):n.isLanguageChangingTo=void 0,i.resolve(function(){return n.t.apply(n,arguments)}),t&&t(a,function(){return n.t.apply(n,arguments)})}(a,l)})};return e||!this.services.languageDetector||this.services.languageDetector.async?!e&&this.services.languageDetector&&this.services.languageDetector.async?0===this.services.languageDetector.detect.length?this.services.languageDetector.detect().then(a):this.services.languageDetector.detect(a):a(e):a(this.services.languageDetector.detect()),i}},{key:"getFixedT",value:function(e,t,n){var i=this,r=function(e,t){var a;if("object"!==T(t)){for(var o=arguments.length,s=new Array(o>2?o-2:0),u=2;u<o;u++)s[u-2]=arguments[u];a=i.options.overloadTranslationOptionHandler([e,t].concat(s))}else a=E({},t);a.lng=a.lng||r.lng,a.lngs=a.lngs||r.lngs,a.ns=a.ns||r.ns,""!==a.keyPrefix&&(a.keyPrefix=a.keyPrefix||n||r.keyPrefix);var l,c=i.options.keySeparator||".";return a.keyPrefix&&Array.isArray(e)?l=e.map(function(e){return"function"==typeof e&&(e=pt(e,E(E({},i.options),t))),"".concat(a.keyPrefix).concat(c).concat(e)}):("function"==typeof e&&(e=pt(e,E(E({},i.options),t))),l=a.keyPrefix?"".concat(a.keyPrefix).concat(c).concat(e):e),i.t(l,a)};return Ve(e)?r.lng=e:r.lngs=e,r.ns=t,r.keyPrefix=n,r}},{key:"t",value:function(){for(var e,t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];return null===(e=this.translator)||void 0===e?void 0:e.translate.apply(e,n)}},{key:"exists",value:function(){for(var e,t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];return null===(e=this.translator)||void 0===e?void 0:e.exists.apply(e,n)}},{key:"setDefaultNamespace",value:function(e){this.options.defaultNS=e}},{key:"hasLoadedNamespace",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;var i=n.lng||this.resolvedLanguage||this.languages[0],r=!!this.options&&this.options.fallbackLng,a=this.languages[this.languages.length-1];if("cimode"===i.toLowerCase())return!0;var o=function(e,n){var i=t.services.backendConnector.state["".concat(e,"|").concat(n)];return-1===i||0===i||2===i};if(n.precheck){var s=n.precheck(this,o);if(void 0!==s)return s}return!!this.hasResourceBundle(i,e)||(!(this.services.backendConnector.backend&&(!this.options.resources||this.options.partialBundledLanguages))||!(!o(i,e)||r&&!o(a,e)))}},{key:"loadNamespaces",value:function(e,t){var n=this,i=Ke();return this.options.ns?(Ve(e)&&(e=[e]),e.forEach(function(e){n.options.ns.indexOf(e)<0&&n.options.ns.push(e)}),this.loadResources(function(e){i.resolve(),t&&t(e)}),i):(t&&t(),Promise.resolve())}},{key:"loadLanguages",value:function(e,t){var n=this,i=Ke();Ve(e)&&(e=[e]);var r=this.options.preload||[],a=e.filter(function(e){return r.indexOf(e)<0&&n.services.languageUtils.isSupportedCode(e)});return a.length?(this.options.preload=r.concat(a),this.loadResources(function(e){i.resolve(),t&&t(e)}),i):(t&&t(),Promise.resolve())}},{key:"dir",value:function(e){var t,n;if(e||(e=this.resolvedLanguage||((null===(t=this.languages)||void 0===t?void 0:t.length)>0?this.languages[0]:this.language)),!e)return"rtl";try{var i=new Intl.Locale(e);if(i&&i.getTextInfo){var r=i.getTextInfo();if(r&&r.direction)return r.direction}}catch(e){}var a=(null===(n=this.services)||void 0===n?void 0:n.languageUtils)||new vt(Pt());return e.toLowerCase().indexOf("-latn")>1?"ltr":["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"].indexOf(a.getLanguagePartFromCode(e))>-1||e.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}},{key:"cloneInstance",value:function(){var e=this,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Bt,r=n.forkResourceStore;r&&delete n.forkResourceStore;var a=E(E(E({},this.options),n),{isClone:!0}),o=new t(a);void 0===n.debug&&void 0===n.prefix||(o.logger=o.logger.clone(n));if(["store","services","language"].forEach(function(t){o[t]=e[t]}),o.services=E({},this.services),o.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},r){var s=Object.keys(this.store.data).reduce(function(t,n){return t[n]=E({},e.store.data[n]),t[n]=Object.keys(t[n]).reduce(function(e,i){return e[i]=E({},t[n][i]),e},t[n]),t},{});o.store=new ct(s,a),o.services.resourceStore=o.store}if(n.interpolation){var u=E(E(E({},Pt().interpolation),this.options.interpolation),n.interpolation),l=E(E({},a),{},{interpolation:u});o.services.interpolator=new wt(l)}return o.translator=new gt(o.services,a),o.translator.on("*",function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];o.emit.apply(o,[e].concat(n))}),o.init(a,i),o.translator.options=a,o.translator.backendConnector.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},o}},{key:"toJSON",value:function(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}],[{key:"createInstance",value:function(){var e=new t(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},arguments.length>1?arguments[1]:void 0);return e.createInstance=t.createInstance,e}}])}(lt),Ot=Lt.createInstance();Ot.createInstance,Ot.dir,Ot.init,Ot.loadResources,Ot.reloadResources,Ot.use,Ot.changeLanguage,Ot.getFixedT;var Nt=Ot.t;Ot.exists,Ot.setDefaultNamespace,Ot.hasLoadedNamespace,Ot.loadNamespaces,Ot.loadLanguages;var Rt={en:{translation:{settings:{phoneSync:{title:"Phone sync",subtitle:"Pair a phone to change settings from it",intro:"Scan the code with your phone's camera to pair it. No typing needed.",address:"Or open {{url}} on your phone and enter the code.",code:"Pairing code: {{code}}",waiting:"Phone sync needs AxoTube's TV service. On a Samsung TV, open this panel again in a few seconds. On other devices, phone sync is not available.",qrHint:"Scan this with your phone's camera. The code is in the QR, so there is nothing to type.",noQr:"No phone address found. Check that the TV is on the same Wi-Fi as your phone, then open this again."},ttSettings:{title:"AxoTube Settings",summary:"Open AxoTube Settings",madeByText:"Made by Aayush with ❤️"},seconds:"{{count}} s",minutes:"{{count}} min",hintBack:"◀ Back",hintClose:"◀ Close",common:{auto:"Auto",any:"Any"},segmentModes:{skip:"Skip automatically",show:"Show skip button",off:"Off"},ads:{title:"Ads & sponsors",subtitle:"Ad blocking and SponsorBlock",blockAds:"Block ads",paidPromotion:"Show paid promotion notices",sponsorBlock:"Enable SponsorBlock",playerTracking:"Block player ad tracking",adTelemetry:"Block ad telemetry",viewStats:"Block view statistics",liveVideos:"Hide Live shelf",topLiveGames:"Hide Top Live Games shelf",mostRelevant:"Hide Most Relevant shelf",segmentTypes:{title:"Segment types",subtitle:"Press OK to change a type. It cycles through: skip automatically, show a skip button, off."},segments:{sponsor:"Sponsors",intro:"Intros",outro:"Outros",interaction:"Interaction reminders",selfpromo:"Self-promotion",preview:"Previews and recaps",filler:"Tangents and jokes",music_offtopic:"Off-topic music"},highlightButton:"Show highlight button",notices:"Show SponsorBlock notices"},playback:{title:"Playback",subtitle:"Quality, speed and captions",quality:{title:"Video quality",subtitle:"Quality used when a video starts. The closest available one is used if needed."},codec:{title:"Video codec",subtitle:"Preferred codec. Any lets YouTube choose."},speedStep:{title:"Speed step",subtitle:"How much each speed button press changes the playback speed."},frameRate:{title:"Frame rate",subtitle:"Switch the TV's refresh rate to match the video.",match:"Match video frame rate",pause:{title:"Pause during switch",subtitle:"Playback pauses for this long while the TV changes its refresh rate."}},pauseInBackground:"Out-of-focus pause (also when menus or panels open)",remainingTime:"Show time remaining",captions:{title:"Captions",subtitle:"Turn captions on by default, and choose the language they use.",onByDefault:"Subtitles on by default",language:{title:"Subtitle language",subtitle:"Preferred language for automatic captions."},allowAuto:"Allow auto-generated captions",myLanguage:"Show captions in my language",otherLanguages:"Show other languages"},languages:{en:"English",hi:"Hindi",es:"Spanish",fr:"French",de:"German",pt:"Portuguese",ja:"Japanese",ko:"Korean",ru:"Russian"},experimental:{title:"Higher resolutions (experimental)",subtitle:"Lets YouTube offer resolutions above the TV screen size. Can stutter on limited TVs. Restarts the app when changed.",unlock:"Unlock 1440p and 4K",max:{title:"Maximum resolution",subtitle:"Highest resolution YouTube may offer while the unlock is on."}},panelShrink:{title:"Video size while reading",subtitle:"Shrinks the video when the description or comments are open.",on:"Shrink video for description and comments",size:{title:"Video size",subtitle:"How large the video stays while a panel is open."}}},playerControls:{title:"Player controls",subtitle:"Extra buttons in the player. Turn on the first option to use the others.",customize:"Extra player buttons",previousNext:"Previous and next",speed:"Speed button",superThanks:"Super Thanks button",miniPlayer:"Mini player button",pipInsteadOfMini:"Use picture-in-picture instead of mini player",onePress:"One-press remote mode (OK plays or pauses, left and right skip 10 s)",hints:{customize:"Master switch for the extra buttons below. Off shows YouTube's own player buttons only.",previousNext:"Adds previous and next buttons to the player. Needs the switch above.",speed:"Shows a button that changes the playback speed.",superThanks:"Shows or hides the Super Thanks button.",miniPlayer:"Adds a button that shrinks the video into a mini player.",pipInsteadOfMini:"That button opens picture-in-picture instead of the mini player.",paidPromotion:"Shows a notice on videos with paid promotion.",onePress:"Remote-friendly controls: OK plays or pauses, left and right skip 10 seconds."}},browsing:{title:"Browsing",subtitle:"Thumbnails, previews and what appears on screen",thumbnails:{title:"Thumbnails and titles",subtitle:"DeArrow shows community titles and thumbnails in place of clickbait. Service: dearrow.ajay.app"},hqThumbnails:"High-quality thumbnails",deArrowTitles:"DeArrow titles",deArrowThumbnails:"DeArrow thumbnails",previews:{title:"Video previews",subtitle:"Plays a short preview when a video is focused.",on:"Show video previews",length:"Preview length"},hideWatched:{title:"Hide watched videos",subtitle:"Hides videos you have mostly watched.",on:"Hide watched videos",threshold:{title:"Watched threshold",subtitle:"Videos watched past this percentage are hidden."},pages:{title:"Hide on these pages",subtitle:"Pages where watched videos are hidden."}},shorts:"Show Shorts",endScreens:"Hide end screen cards",longPress:"Long press OK to add to queue",stillWatching:'Show "Are you still watching?" prompts',deArrowPeek:"Long press shows the other title and thumbnail"},home:{title:"Home & sidebar",subtitle:"Startup page and sidebar items",startup:{title:"Startup page",subtitle:"The page AxoTube opens at launch."},reloadHome:"Reload home on startup",sidebarItems:{title:"Hide sidebar items",subtitle:"Selected items are hidden from the sidebar."},hideChannels:"Hide channels from the sidebar",sortSubscriptions:"Sort subscriptions A to Z"},appearance:{title:"Appearance",subtitle:"Colours, clock, dimming and performance",theme:{title:"Theme",subtitle:"Colours used across the interface.",presets:{title:"Preset",subtitle:"A ready-made colour set."},background:{title:"Background colour",subtitle:"Colour behind the main content."},text:{title:"Text colour",subtitle:"Colour of the text in the interface."}},colors:{default:"Default (dark)",black:"Black",darkGray:"Dark gray",charcoal:"Charcoal",navy:"Navy blue",darkRed:"Dark red",darkGreen:"Dark green",darkPurple:"Dark purple"},textColors:{default:"Default",white:"White",gray:"Gray",red:"Red",blue:"Blue",green:"Green",purple:"Purple",yellow:"Yellow"},dimming:{title:"Screen dimming",subtitle:"Dims the screen when you stop interacting.",on:"Dim the screen when idle",timeout:{title:"Dim after",subtitle:"How long to wait before the screen dims."},opacity:{title:"Dimming strength",subtitle:"How dark the screen gets."}},fullAnimations:"Full-quality animations",performance:"Performance mode (memory part applies after reload)",clock:{title:"Clock",subtitle:"Show the time on screen.",show:{title:"When to show",subtitle:"Always, or only while no video is playing.",off:"Off",always:"Always",notPlaying:"When no video is playing"},format:{title:"Time format",subtitle:"24-hour, or 12-hour with or without AM and PM.",h24:"24-hour (14:05)",h12:"12-hour with AM/PM (2:05 PM)",h12NoAmPm:"12-hour, no AM/PM (2:05)"},position:{title:"Position",subtitle:"Corner of the screen for the clock.",topLeft:"Top left",topRight:"Top right",bottomLeft:"Bottom left",bottomRight:"Bottom right"},seconds:"Show seconds"}},system:{title:"System",subtitle:"Memory, accounts and updates",whosWatching:{title:"Who's watching menu",subtitle:"Choose a profile when the app starts.",on:"Show who's watching menu",always:"Always show it",onExit:"Show when leaving the app"},signInReminder:"Sign-in reminder for guests",welcome:"Welcome message",updates:{title:"Updates",subtitle:"Version {{version}}. Checks for new releases.",checkNow:"Check for updates now",onStartup:"Check for updates on startup"},reload:"Reload AxoTube",restartCast:"Restart cast receiver"},about:{title:"About AxoTube",version:"Version {{version}}",scanMessage:"Scan the QR code to open {{name}}.",subtitle:"Versions and status",userscript:"✅ Userscript {{version}}, running",serviceOnline:"✅ Service {{version}}, online on port 8090",serviceOffline:"⚠️ Service not reachable on port 8090",proxyOnline:"✅ Proxy {{version}}, online on port 8081",proxyOffline:"⚠️ Proxy not reachable on port 8081",bundleCurrent:"📦 App bundle {{version}}",bundleUpdate:"📦 App bundle {{current}}, update {{latest}} ready",bundleUnknown:"📦 App bundle not checked yet",launchMode:"🚀 Launch mode: {{mode}}",launchUnknown:"🚀 Launch mode unknown while the service is not running",socials:{title:"🔗 Socials",subtitle:"Pick one to show its QR code.",githubHint:"Source code, releases and issues",discordHint:"Community chat"}},webConfig:{title:"Web config",subtitle:"Pairing code, phone address and service status",online:"AxoTube service: online",offline:"AxoTube service is not running, so the web config page is not available.",qrTitle:"📱 Pair with your phone",qrSubtitle:"Show a code for your phone to scan",rowHint:"Also on your phone: background image and more"},status:{checking:"Checking the services…"},advanced:{title:"Advanced",subtitle:"Diagnostics, user agent and launch mode",diagnostics:{title:"Diagnostics page",subtitle:"Launch log, versions and what the app last did"},userAgent:{title:"User agent",subtitle:"The browser identity YouTube sees. Takes effect after AxoTube reloads. The phone agent is experimental on TV.",samsung:"Samsung TV (default)",android:"Android phone (experimental)"},launch:{title:"Launch mode",subtitle:"Applies the next time AxoTube starts. SDB needs developer mode on the TV.",proxy:"Proxy (recommended)",debugger:"SDB debugger launch",proxyShort:"proxy",debuggerShort:"SDB debugger",saved:"Launch mode saved. It applies the next time AxoTube starts.",failed:"Could not save the launch mode. Is AxoTube running?"}},moreOnWeb:{text:"More settings, like a background image, are on the web config page."},axotube:{title:"AxoTube",subtitle:"Web config, updates, who’s watching and startup behaviour of AxoTube"}},welcomeMsg:{title:"Welcome to AxoTube",subtitle:"Go to settings and click on AxoTube Settings for settings."},sponsorblock:{segments:{sponsor:"sponsored segment",intro:"intro",outro:"outro",interaction:"interaction reminder",selfpromo:"self-promotion",preview:"recap or preview",filler:"tangents",music_offtopic:"non-music part",poi_highlight:"highlight"},toasts:{skipping:"Skipping {{segment}}",notSkipping:"Not skipping {{segment}} (was skipped {{count}} times)",skip:"Skip {{segment}}",skipToHighlight:"Skip to highlight",undone:"Skip undone: {{segment}}"}},app:{name:"axotube"},menu:{play:"Play",saveWatchLater:"Save to Watch Later",saveToPlaylist:"Save to Playlist",addToQueue:"Add to Queue"},player:{miniPlayer:"Mini Player",pictureInPicture:"Picture in Picture",speedControls:"Speed Controls",previous:"Previous",next:"Next",withAxotube:"with axotube"},toasts:{queueAdded:"Video added to queue.",queueAddFailed:"Nothing to add to the queue.",queueCleared:"Video queue cleared.",updateDownloading:"Downloading update, please wait...",upToDate:"You are on the latest version ({{version}}).",updateNoApk:"Version {{version}} is available, but no compatible APK was found in the release.",updateCheckFailed:"Could not check for updates.",serviceConnected:"Service connected",commandReceived:"Command received",pairingWithUrl:"Open {{url}} on your phone · code {{code}}",pairingCodeOnly:"Phone pairing code: {{code}}",updateApplyFailed:"The update could not be applied. Try again later.",castRestarted:"Cast receiver restarted. Phones should see the TV again shortly.",castRestarting:"Restarting cast receiver…",castRestartWait:"Cast receiver was just restarted. Try again in a few seconds.",castRestartFailed:"Could not restart the cast receiver.",castRestartNotRunning:"Cast discovery is not running. Restart the app to bring it back.",castRestartUnsupported:"Restarting cast is not available on this device."},playback:{retryPrompt:"Playback stopped at {{time}}. Press blue to retry from there."},updater:{reloadWhenPaused:"Update installed. It takes effect when playback pauses or the video ends.",modalTitle:"Update Available",modalBody:"A new version of axotube is available: {{latest}}\nCurrent version: {{current}}\nRelease date: {{date}}\nRelease notes:",unknownDate:"Unknown",updateNow:"Update Now",updateNowSubtitle:"Click to download the latest version.",remindLater:"Remind Me Later",remindLaterSubtitle:"Check for updates later.",modalBodyNew:"Version {{latest}} is available. You are on {{current}}. Update now and the page will reload.",applying:"Updating…"}}}};Ot.init({lng:"en",fallbackLng:"en",resources:Rt,debug:!1,interpolation:{escapeValue:!1}});var Mt;Mt||(Mt=1,function(){function e(e){return void 0===e?0:Number(e)}function t(e,t){return e!==t&&!(isNaN(e)&&isNaN(t))}self.DOMRect=function(n,i,r,a){var o,s,u,l,c,h,d,p;o=e(n),s=e(i),u=e(r),l=e(a),Object.defineProperties(this,{x:{get:function(){return o},set:function(e){t(o,e)&&(o=e,c=h=void 0)},enumerable:!0},y:{get:function(){return s},set:function(e){t(s,e)&&(s=e,d=p=void 0)},enumerable:!0},width:{get:function(){return u},set:function(e){t(u,e)&&(u=e,c=h=void 0)},enumerable:!0},height:{get:function(){return l},set:function(e){t(l,e)&&(l=e,d=p=void 0)},enumerable:!0},left:{get:function(){return void 0===c&&(c=o+Math.min(0,u)),c},enumerable:!0},right:{get:function(){return void 0===h&&(h=o+Math.max(0,u)),h},enumerable:!0},top:{get:function(){return void 0===d&&(d=s+Math.min(0,l)),d},enumerable:!0},bottom:{get:function(){return void 0===p&&(p=s+Math.max(0,l)),p},enumerable:!0}})}}());var _t=null,Ut=null,jt=null,Ht=null,zt=null,Vt=!1,Kt=[];function Gt(){try{return"undefined"==typeof window?null:window._yttv||null}catch(e){return null}}function Jt(e,t){try{var n=e[t],i=n&&n.instance;if(i&&"function"==typeof i.resolveCommand)return{root:n,instance:i}}catch(e){}return null}function Xt(e){if(zt)try{zt(e)}catch(e){}}function Wt(){var e=Gt();if(e){if(e===_t&&null!==jt){var t=Jt(e,Ut);if(t&&t.root===jt&&t.instance===Ht)return Xt(t.instance),t.instance}_t=e,jt=null,Ht=null,Ut=null;try{for(var n in e){var i=Jt(e,n);if(i)return Ut=n,jt=i.root,Ht=i.instance,Xt(i.instance),i.instance}}catch(e){}}try{if("undefined"!=typeof window&&"function"==typeof window._yttv_resolveCommand)return{resolveCommand:function(e,t){return window._yttv_resolveCommand(e,t)}}}catch(e){}return null}function qt(){return!!Wt()}function Yt(e,t){var n=Wt();return n?{dispatched:!0,result:n.resolveCommand(e,t)}:{dispatched:!1}}function Qt(e,t){return Yt(e,t).result}function Zt(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!e)return Promise.resolve(!1);var n=void 0===t.maxAttempts?50:t.maxAttempts,i=void 0===t.retryDelayMs?200:t.retryDelayMs;return new Promise(function(t){var r=0;!function a(){var o=Wt();if(o)try{o.resolveCommand(e),t(!0)}catch(e){try{console.warn("[AxoTube:nativeCommand] native command threw after dispatch attempt; not retrying",e)}catch(e){}t(!0)}else r>=n?t(!1):(r+=1,setTimeout(a,i))}()})}function $t(){var e=Gt();if(!e)return!1;var t=!1;try{for(var n in e){var i=Jt(e,n);i&&(t=!0,Xt(i.instance))}}catch(e){}return t}var en=[250,1e3,3e3];function tn(){$t();var e,t=f(Kt);try{for(t.s();!(e=t.n()).done;){var n=e.value;clearTimeout(n)}}catch(e){t.e(e)}finally{t.f()}Kt=en.map(function(e){return setTimeout($t,e)})}function nn(e){return hn(Nt("menu.addToQueue"),{clickTrackingParams:null,playlistEditEndpoint:{customAction:{action:"ADD_TO_QUEUE",parameters:e}}})}function rn(e,t){return Qt(e,t)}function an(e,t,n){var i={title:{simpleText:e},subtitle:{simpleText:t},accessibilityData:{accessibilityData:{label:t?"".concat(e," - ").concat(t):e}},trackingParams:"CAEQlYkGGhMI"};n&&n.length>0&&(i.image={thumbnails:n}),rn({openPopupAction:{popupType:"TOAST",popup:{overlayToastRenderer:i}}})}function on(e,t,n,i){var r=function(e,t,n,i){var r="string"==typeof e?{title:e,subtitle:""}:e||{title:"",subtitle:""},a={openPopupAction:{popupType:"MODAL",popup:{overlaySectionRenderer:{overlay:{overlayTwoPanelRenderer:{actionPanel:{overlayPanelRenderer:{header:{overlayPanelHeaderRenderer:r.overlayPanelHeaderRenderer||{title:{simpleText:r.title}}},content:t}},backButton:{buttonRenderer:{accessibilityData:{accessibilityData:{label:"Back"}},command:{signalAction:{signal:"POPUP_BACK"}}}}}},dismissalCommand:{signalAction:{signal:"POPUP_BACK"}}}},uniqueId:n}};return r.subtitle&&(a.openPopupAction.popup.overlaySectionRenderer.overlay.overlayTwoPanelRenderer.actionPanel.overlayPanelRenderer.header.overlayPanelHeaderRenderer.subtitle={simpleText:r.subtitle}),i&&(a.openPopupAction.shouldMatchUniqueId=!0,a.openPopupAction.updateAction=!0),a}(e,t,n,i);rn(r)}function sn(e,t){return{overlayPanelItemListRenderer:{items:e,selectedIndex:t}}}function un(e,t,n){var i={compactLinkRenderer:{serviceEndpoint:{commandExecutorCommand:{commands:n}}}};return e&&(i.compactLinkRenderer.title={simpleText:e.title}),e&&e.subtitle&&(i.compactLinkRenderer.subtitle={simpleText:e.subtitle}),t&&(i.compactLinkRenderer.icon={iconType:t.icon}),t&&t.secondaryIcon&&(i.compactLinkRenderer.secondaryIcon={iconType:t.secondaryIcon}),i}function ln(e,t,n,i,r){return{timelyActionRenderer:{actionButtons:[{buttonRenderer:{isDisabled:!1,text:{runs:[{text:e}]},icon:{iconType:t},trackingParams:null,command:n}}],triggerTimeMs:i,timeoutMs:r,type:""}}}function cn(e){return{clickTrackingParams:null,showMenuCommand:{contentId:e.videoId,thumbnail:{thumbnails:e.thumbnails},title:{simpleText:e.title},subtitle:{simpleText:e.subtitle},menu:{menuRenderer:{items:[dn(Nt("menu.play"),{clickTrackingParams:null,watchEndpoint:e.watchEndpointData}),hn(Nt("menu.saveWatchLater"),{clickTrackingParams:null,playlistEditEndpoint:{playlistId:"WL",actions:[{addedVideoId:e.videoId,action:"ACTION_ADD_VIDEO"}]}}),dn(Nt("menu.saveToPlaylist"),{clickTrackingParams:null,addToPlaylistEndpoint:{videoId:e.videoId}}),nn(e.item)],trackingParams:null,accessibility:{accessibilityData:{label:"Video options"}}}}}}}function hn(e,t){return{menuServiceItemRenderer:{text:{runs:[{text:e}]},serviceEndpoint:t,trackingParams:null}}}function dn(e,t){return{menuNavigationItemRenderer:{text:{runs:[{text:e}]},navigationEndpoint:t,trackingParams:null}}}function pn(e){return{overlayMessageRenderer:{title:{simpleText:e}}}}function fn(e){return{qrCodeRenderer:{qrCodeImage:{thumbnails:[{url:e}]},style:"QR_CODE_RENDERER_STYLE_ATA_SIDESHEET",trackingParams:null}}}function mn(e,t,n,i){return{isDisabled:e,text:{runs:[{text:t}]},icon:{iconType:n},command:i,trackingParams:null}}function gn(e){try{return e&&"function"==typeof e.getInstance&&e.getInstance()||null}catch(e){return null}}function vn(e){if(!e)return null;try{var t=Object.getPrototypeOf(e);if(!t)return null;var n,i=f(Object.getOwnPropertyNames(t));try{for(i.s();!(n=i.n()).done;){var r=n.value,a=void 0;try{a=e[r]}catch(e){continue}if("function"==typeof a)try{if(a.toString().includes("ytlrActionRouter"))return a}catch(e){}}}catch(e){i.e(e)}finally{i.f()}}catch(e){}return null}function yn(){if(window._yttv){var e=null,t=null;try{for(var n in window._yttv){var i=void 0;try{i=window._yttv[n]}catch(e){continue}if(i&&"function"==typeof i.getInstance){var r=gn(i);if(r){try{if(i.toString().includes("ytlrActionRouter")){t=vn(e=r);break}}catch(e){}var a=vn(r);if(a){e=r,t=a;break}}}}}catch(e){return}if(e&&t){var o=null;try{for(var s in window._yttv){var u=void 0;try{u=window._yttv[s]}catch(e){continue}if("function"==typeof u)try{if(u.toString().includes("this.actionName")){o=u;break}}catch(e){}}}catch(e){}if(o)return{executeFunction:t.bind(e),commandFunction:o}}}}we.addEventListener("configChange",function(e){if("disabledSidebarContents"===e.detail.key||"disableChannelsOnSidebar"===e.detail.key)try{var t=yn();t&&t.executeFunction(new t.commandFunction("reloadGuideAction"))}catch(e){console.warn("[AxoTube:customGuideAction] Guide reload failed:",e)}});var bn=null;var xn=["adSlot","adPlacements","playerAds","promo","Promo","hideLogo","tvMasthead","attestation","adBreak","adClientParams"],Sn=["adPlacements","playerAds","adSlots","paidContentOverlay","streamingData","contents","endscreen","messages","entries","title","continuationContents","playerOverlays","transportControls","attestation","adBreakHeartbeatParams","playerResponse"];function En(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function wn(e){return!(!e||!e.adSlotRenderer)}function kn(e){return!!(e&&e.tileRenderer&&("TVHTML5_TILE_RENDERER_TYPE_SHORTS"===e.tileRenderer.tvhtml5ShelfRendererType||e.tileRenderer.onSelectCommand&&e.tileRenderer.onSelectCommand.reelWatchEndpoint))}function Dn(e){if(!e||"object"!==T(e))return!1;for(var t=Object.keys(e),n=0;n<t.length;n++)if(-1!==t[n].toLowerCase().indexOf("promo"))return!0;return!!(e.shelfRenderer&&e.shelfRenderer.tvhtml5Metadata&&e.shelfRenderer.tvhtml5Metadata.hideLogo)}function An(e){return!(!e||"object"!==T(e)||!e.tvMastheadRenderer)}function Cn(e){if(!e)return"";var t=e.title||e.headerRenderer&&e.headerRenderer.tvHeaderRenderer&&e.headerRenderer.tvHeaderRenderer.title;return t?"string"==typeof t.simpleText?t.simpleText:t.runs&&t.runs[0]&&"string"==typeof t.runs[0].text?t.runs[0].text:"":""}function Tn(e){return e?/recommend/i.test(e)?null:/top\s+live\s+games?/i.test(e)?"topLiveGames":/most\s+relevant/i.test(e)?"mostRelevant":/^live(\s+now)?$/i.test(e.trim())?"live":null:null}function Pn(e,t){try{if("undefined"==typeof window)return;var n=window.__axotubeAdblockStats||(window.__axotubeAdblockStats={});n[e]=(n[e]||0)+(void 0===t?1:t)}catch(e){}}function Fn(){try{if("undefined"==typeof window||!0!==window.__axotubeAdblockDebug)return;if("undefined"==typeof console)return;var e=["[AxoTube:adblock]"].concat(Array.prototype.slice.call(arguments));console.log.apply(console,e)}catch(e){}}var Bn={};function In(e,t){var n=Bn[e];if(n||(n=Bn[e]={errors:0,open:!1}),!n.open)try{return t()}catch(t){return n.errors++,Pn("error:"+e),Fn("filter error",e,t),void(n.errors>=5&&(n.open=!0,"undefined"!=typeof console&&console.warn&&console.warn("[AxoTube:adblock] '"+e+"' disabled after 5 errors this session")))}}var Ln=["attestation","adBreakHeartbeatParams"];function On(e){for(var t=0,n=0;n<Ln.length;n++)En(e,Ln[n])&&(delete e[Ln[n]],t++);return t}function Nn(e){var t=new Map;return{get:function(e){return t.get(e)},has:function(e){return t.has(e)},set:function(n,i){for(t.set(n,i);t.size>e;)t.delete(t.keys().next().value);return i},delete:function(e){return t.delete(e)},clear:function(){t.clear()}}}var Rn=["maxresdefault.jpg","sddefault.jpg","hqdefault.jpg","mqdefault.jpg","default.jpg"],Mn={"maxresdefault.jpg":{width:1280,height:720},"sddefault.jpg":{width:640,height:480},"hqdefault.jpg":{width:480,height:360},"mqdefault.jpg":{width:320,height:180},"default.jpg":{width:120,height:90}},_n=Nn(256),Un=new Map;function jn(e){if(!e||!e.includes("i.ytimg.com/vi/"))return null;var t=e.match(/\/vi\/([a-zA-Z0-9_-]+)\//);return t?t[1]:null}function Hn(e){return Array.isArray(e)&&e.length>0&&e[0].width&&e[0].width>100}var zn=Nn(256);function Vn(e){var t,n=[],i=f(Rn);try{for(i.s();!(t=i.n()).done;){var r=t.value,a=Mn[r];n.push({url:"https://i.ytimg.com/vi/".concat(e,"/").concat(r),width:a.width,height:a.height})}}catch(e){i.e(e)}finally{i.f()}return n}function Kn(e,t){if(e&&"object"===T(e))for(var n in e)"thumbnails"===n&&Hn(e[n])?e[n]=t:"object"===T(e[n])&&Kn(e[n],t)}var Gn,Jn=(Gn=5e3,function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=null;try{"function"==typeof AbortController&&(n=new AbortController)}catch(e){}var i=n?E(E({},t),{},{signal:n.signal}):t,r=null,a=new Promise(function(e,t){r=setTimeout(function(){try{n&&n.abort()}catch(e){}t(new Error("Fetch timed out after ".concat(Gn,"ms")))},Gn)});return Promise.race([fetch(e,i),a]).finally(function(){null!==r&&clearTimeout(r)})}),Xn=Nn(256),Wn=Nn(256);function qn(e){return e&&e.titles&&0!==e.titles.length?e.titles.reduce(function(e,t){return e.votes>t.votes?e:t}).title:null}function Yn(e,t){if(!t||!t.thumbnails||0===t.thumbnails.length)return null;var n=t.thumbnails.reduce(function(e,t){return e.votes>t.votes?e:t});return void 0===n.timestamp||null===n.timestamp?null:Number.isFinite(Number(n.timestamp))?[{url:"https://dearrow-thumb.ajay.app/api/v1/getThumbnail?videoID=".concat(e,"&time=").concat(n.timestamp),width:1280,height:640}]:null}function Qn(e,t,n,i,r){try{if(i&&n.titles&&n.titles.length>0){var a,o=qn(n);null!==(a=e.tileRenderer)&&void 0!==a&&null!==(a=a.metadata)&&void 0!==a&&null!==(a=a.tileMetadataRenderer)&&void 0!==a&&a.title&&(e.tileRenderer.metadata.tileMetadataRenderer.title.simpleText=o)}if(r){var s,u=Yn(t,n);u&&null!==(s=e.tileRenderer)&&void 0!==s&&null!==(s=s.header)&&void 0!==s&&null!==(s=s.tileHeaderRenderer)&&void 0!==s&&s.thumbnail&&(e.tileRenderer.header.tileHeaderRenderer.thumbnail.thumbnails=u)}}catch(e){console.warn("[AxoTube:deArrow] Error processing DeArrow data:",e)}}function Zn(e){var t=Se("enableDeArrowTitles"),n=Se("enableDeArrowThumbnails"),i=Se("enableDeArrowPeek");if(t||n||i)for(var r=function(){var i=e[a];if(i.adSlotRenderer)return e.splice(a,1),0;if(!i.tileRenderer)return 0;var r=i.tileRenderer.contentId;if(!r)return 0;!function(e,t){var n,i,r,a;if(!Wn.get(t)){var o=e.tileRenderer;Wn.set(t,{title:null!==(n=null==o||null===(i=o.metadata)||void 0===i||null===(i=i.tileMetadataRenderer)||void 0===i||null===(i=i.title)||void 0===i?void 0:i.simpleText)&&void 0!==n?n:null,thumbnails:null!==(r=null==o||null===(a=o.header)||void 0===a||null===(a=a.tileHeaderRenderer)||void 0===a||null===(a=a.thumbnail)||void 0===a?void 0:a.thumbnails)&&void 0!==r?r:null})}}(i,r);var o={item:i,titlesEnabled:t,thumbnailsEnabled:n},s=Xn.get(r);if(s)return s.data?Qn(i,r,s.data,t,n):Array.isArray(s.waiters)&&s.waiters.push(o),0;var u={data:null,waiters:[o]};Xn.set(r,u),Jn("https://sponsor.ajay.app/api/branding?videoID=".concat(r)).then(function(e){if(!e.ok)throw new Error("DeArrow HTTP ".concat(e.status));return e.json()}).then(function(e){u.data=e;var t=u.waiters.slice();u.waiters.length=0;var n,i=f(t);try{for(i.s();!(n=i.n()).done;){var a=n.value;Qn(a.item,r,e,a.titlesEnabled,a.thumbnailsEnabled)}}catch(e){i.e(e)}finally{i.f()}}).catch(function(){Xn.get(r)===u&&Xn.delete(r)})},a=e.length-1;a>=0;a--)r()}function $n(e){var t=e.tileRenderer,n={};return void 0!==t.contentType&&(n.contentType=t.contentType),void 0!==t.style&&(n.style=t.style),void 0!==t.contentId&&(n.contentId=t.contentId),void 0!==t.trackingParams&&(n.trackingParams=t.trackingParams),void 0!==t.metadata&&(n.metadata=ve(t.metadata)),void 0!==t.header&&(n.header=ve(t.header)),void 0!==t.onSelectCommand&&(n.onSelectCommand=ve(t.onSelectCommand)),{tileRenderer:n}}function ei(e){return e.some(function(e){var t;return"ADD_TO_QUEUE"===(null==e||null===(t=e.menuServiceItemRenderer)||void 0===t||null===(t=t.serviceEndpoint)||void 0===t||null===(t=t.playlistEditEndpoint)||void 0===t||null===(t=t.customAction)||void 0===t?void 0:t.action)})}function ti(e){if(Ie()&&!/#\/watch/.test(location.hash||"")){var t,n=1e3*Se("previewLengthSeconds"),i=f(e);try{for(i.s();!(t=i.n()).done;){var r,a,o,s=t.value;if(s.tileRenderer){var u=null===(r=s.tileRenderer.onSelectCommand)||void 0===r?void 0:r.watchEndpoint;if(u&&!(null!==(a=s.tileRenderer)&&void 0!==a&&null!==(a=a.onFocusCommand)&&void 0!==a&&a.playbackEndpoint||null!==(o=s.tileRenderer)&&void 0!==o&&null!==(o=o.onFocusCommand)&&void 0!==o&&o.commandExecutorCommand)){var l=ve({watchEndpoint:u});s.tileRenderer.onFocusCommand={startInlinePlaybackCommand:{blockAdoption:!0,caption:!1,delayMs:3e3,durationMs:n,muted:!1,restartPlaybackBeforeSeconds:10,resumeVideo:!0,playbackEndpoint:l}}}}}}catch(e){i.e(e)}finally{i.f()}}}function ni(e){if(!Se("enableHideWatchedVideos"))return e;var t=Se("hideWatchedVideosPages");if(!t||!t.length)return e;var n=Se("hideWatchedVideosThreshold"),i=location.hash.substring(1),r=function(e){var t={},n=e.indexOf("?");if(-1===n)return t;for(var i=e.slice(n+1).split("&"),r=0;r<i.length;r++)if(i[r]){var a=i[r].indexOf("="),o=-1===a?i[r]:i[r].slice(0,a),s=-1===a?"":i[r].slice(a+1);try{t[decodeURIComponent(o)]=decodeURIComponent(s)}catch(e){t[o]=s}}return t}(i),a=r.browseId||r.browse_id||"",o="/"===i?"home":i.startsWith("/search")?"search":a.replace("FE","").replace("topics_","");return t.includes(o)?e.filter(function(e){var t;if(!e.tileRenderer)return!0;var i=null===(t=e.tileRenderer.header)||void 0===t||null===(t=t.tileHeaderRenderer)||void 0===t||null===(t=t.thumbnailOverlays)||void 0===t||null===(t=t.find(function(e){return e.thumbnailOverlayResumePlaybackRenderer}))||void 0===t?void 0:t.thumbnailOverlayResumePlaybackRenderer;return!i||(i.percentDurationWatched||0)<=n}):e}function ii(e,t){return function(e){if("eager"===Le()){var t,n=f(e);try{for(n.s();!(t=n.n()).done;){var i=t.value;if(i.tileRenderer)try{var r,a,o,s,u=null===(r=i.tileRenderer.onSelectCommand)||void 0===r||null===(r=r.watchEndpoint)||void 0===r?void 0:r.videoId;if(!u)continue;if((null===(a=i.tileRenderer.header)||void 0===a||null===(a=a.tileHeaderRenderer)||void 0===a||null===(a=a.thumbnail)||void 0===a?void 0:a.thumbnails)===zn.get(u))continue;var l=zn.get(u);l||(l=zn.set(u,Vn(u))),null!==(o=i.tileRenderer.header)&&void 0!==o&&null!==(o=o.tileHeaderRenderer)&&void 0!==o&&null!==(o=o.thumbnail)&&void 0!==o&&o.thumbnails&&(i.tileRenderer.header.tileHeaderRenderer.thumbnail.thumbnails=l),null!==(s=i.tileRenderer.onFocusCommand)&&void 0!==s&&null!==(s=s.startInlinePlaybackCommand)&&void 0!==s&&null!==(s=s.playbackEndpoint)&&void 0!==s&&null!==(s=s.startPlaylistItemEndpoint)&&void 0!==s&&null!==(s=s.playlistItemData)&&void 0!==s&&null!==(s=s.thumbnail)&&void 0!==s&&s.thumbnails&&(i.tileRenderer.onFocusCommand.startInlinePlaybackCommand.playbackEndpoint.startPlaylistItemEndpoint.playlistItemData.thumbnail.thumbnails=l),i.tileRenderer.onFocusCommand&&Kn(i.tileRenderer.onFocusCommand,l)}catch(e){console.warn("[AxoTube:hqThumbnails] Error processing thumbnail:",e)}}}catch(e){n.e(e)}finally{n.f()}}}(e),Zn(e),function(e){if(Se("enableLongPress")){var t,n=f(e);try{for(n.s();!(t=n.n()).done;){var i,r,a,o,s,u,l=t.value;if(l.tileRenderer&&"TILE_STYLE_YTLR_DEFAULT"===l.tileRenderer.style&&l.tileRenderer.contentId&&null!==(i=l.tileRenderer.onSelectCommand)&&void 0!==i&&i.watchEndpoint)if(l.tileRenderer.onLongPressCommand){var c,h=null===(c=l.tileRenderer.onLongPressCommand)||void 0===c||null===(c=c.showMenuCommand)||void 0===c||null===(c=c.menu)||void 0===c||null===(c=c.menuRenderer)||void 0===c?void 0:c.items;Array.isArray(h)&&!ei(h)&&h.push(nn($n(l)))}else{var d=null===(r=l.tileRenderer.metadata)||void 0===r?void 0:r.tileMetadataRenderer;if(d&&null!==(a=l.tileRenderer.header)&&void 0!==a&&null!==(a=a.tileHeaderRenderer)&&void 0!==a&&null!==(a=a.thumbnail)&&void 0!==a&&a.thumbnails){var p=null===(o=d.lines)||void 0===o||null===(o=o[0])||void 0===o||null===(o=o.lineRenderer)||void 0===o||null===(o=o.items)||void 0===o||null===(o=o[0])||void 0===o||null===(o=o.lineItemRenderer)||void 0===o?void 0:o.text;if(p){var m=(null===(s=p.runs)||void 0===s||null===(s=s[0])||void 0===s?void 0:s.text)||p.simpleText||"",g=$n(l),v=cn({videoId:g.tileRenderer.contentId,thumbnails:g.tileRenderer.header.tileHeaderRenderer.thumbnail.thumbnails,title:(null===(u=d.title)||void 0===u?void 0:u.simpleText)||"",subtitle:m,watchEndpointData:g.tileRenderer.onSelectCommand.watchEndpoint,item:g});l.tileRenderer.onLongPressCommand=v}}}}}catch(e){n.e(e)}finally{n.f()}}}(e),t&&ti(e),ni(e)}function ri(e,t){for(var n=t||{},i=n.optional||{},r=e.length-1;r>=0;r--){var a=e[r];if(a&&"object"===T(a))if(n.removeAds&&(Dn(a)||An(a)))Pn(An(a)?"bannerRemoved":"shelfRemoved"),e.splice(r,1);else if(a.shelfRenderer){var o=a.shelfRenderer,s=Tn(Cn(o));if(s&&i[s])Pn("optionalShelfRemoved"),e.splice(r,1);else{var u=o.content&&o.content.horizontalListRenderer;if(u&&u.items)if(n.removeShorts&&"TVHTML5_SHELF_RENDERER_TYPE_SHORTS"===o.tvhtml5ShelfRendererType)e.splice(r,1);else{var l=u.items,c=0;if(n.removeAds||n.removeShorts)(c=l.length-(l=l.filter(function(e){return!(n.removeAds&&wn(e)||n.removeShorts&&kn(e))})).length)&&(u.items=l,Pn("itemRemoved",c));c>0&&0===l.length?(Pn("emptyShelfRemoved"),e.splice(r,1)):u.items=ii(l,!1!==n.addPreviews)}}}}}var ai=["adSlotRenderer","promoShelfRenderer","tvMastheadRenderer"],oi=["adPlacements","adSlots"],si=["playerAds"],ui=["attestation","adBreakHeartbeatParams"];function li(e){for(var t=0;t<ai.length;t++)if(En(e,ai[t]))return!0;return!1}function ci(e,t,n){return n.signin?e:function(e,t){return e.filter(function(e){return!(e&&e[t])})}(e,t)}function hi(e,t){var n=(Array.isArray(e.timelyActionRenderers)?e.timelyActionRenderers:[]).filter(function(e){return!function(e){var t=e&&e.timelyActionRenderer&&e.timelyActionRenderer.actionButtons;return!!Array.isArray(t)&&t.some(function(e){return e&&e.buttonRenderer&&e.buttonRenderer.command&&e.buttonRenderer.command.showEngagementPanelEndpoint&&e.buttonRenderer.command.showEngagementPanelEndpoint.customAction&&"SKIP"===e.buttonRenderer.command.showEngagementPanelEndpoint.customAction.action})}(e)});e.timelyActionRenderers=n.concat(t)}function di(e,t){var n,i,r,a=null==e||null===(n=e.playerOverlays)||void 0===n?void 0:n.playerOverlayRenderer;a&&hi(a,function(e){var t,n=[],i=e.sponsorManualSkips;if(!Array.isArray(i)||0===i.length||null===(t=window)||void 0===t||null===(t=t.sponsorblock)||void 0===t||!t.segments)return n;var r,a=f(window.sponsorblock.segments);try{for(a.s();!(r=a.n()).done;){var o=r.value;i.includes(o.category)&&n.push(ln(Nt("sponsorblock.toasts.skip",{segment:Nt("sponsorblock.segments.".concat(o.category))}),"SKIP_NEXT",{clickTrackingParams:null,showEngagementPanelEndpoint:{customAction:{action:"SKIP",parameters:{time:o.segment[1]}}}},1e3*o.segment[0],1e3*o.segment[1]-1e3*o.segment[0]))}}catch(e){a.e(e)}finally{a.f()}return n}(t));var o=null==e||null===(i=e.transportControls)||void 0===i||null===(i=i.transportControlsRenderer)||void 0===i?void 0:i.promotedActions;if(o&&t.sponsorHighlight&&null!==(r=window)&&void 0!==r&&null!==(r=r.sponsorblock)&&void 0!==r&&r.segments){var s=window.sponsorblock.segments.find(function(e){return"poi_highlight"===e.category});s&&o.push({type:"TRANSPORT_CONTROLS_BUTTON_TYPE_SPONSORBLOCK_HIGHLIGHT",button:{buttonRenderer:mn(!1,Nt("sponsorblock.toasts.skipToHighlight"),"SKIP_NEXT",{clickTrackingParams:null,customAction:{action:"SKIP",parameters:{time:s.segment[0]}}})}})}}var pi=["/pagead/","/ptracking","/eligibility_check"],fi=["/api/stats/watchtime","/api/stats/playback","/api/stats/qoe","/api/stats/atr"];function mi(e,t){for(var n=0;n<t.length;n++)if(-1!==e.indexOf(t[n]))return!0;return!1}var gi,vi="data:application/json,{}";function yi(e){return function(e,t){return!!("string"==typeof e&&e&&(t.ads&&mi(e,pi)||t.viewStats&&mi(e,fi)))}(e,{ads:!1!==Se("blockAdTelemetry"),viewStats:!!Se("blockViewStatsTelemetry")})}function bi(e,t,n){return{removeAds:t,removeShorts:!e.shorts,addPreviews:n,optional:{live:e.removeLiveVideos,topLiveGames:e.removeTopLiveGames,mostRelevant:e.removeMostRelevant}}}function xi(e){e.sort(function(e,t){var n,i,r,a,o,s,u=null==e||null===(n=e.tabRenderer)||void 0===n?void 0:n.title,l=null==t||null===(i=t.tabRenderer)||void 0===i?void 0:i.title;return null===(r=e.tabRenderer)||void 0===r||!r.selected||null!==(a=t.tabRenderer)&&void 0!==a&&a.selected?null!==(o=e.tabRenderer)&&void 0!==o&&o.selected||null===(s=t.tabRenderer)||void 0===s||!s.selected?u&&l?u.localeCompare(l):0:1:-1})}!function(e){if(e&&!e.__axotubeTelemetryHooks){e.__axotubeTelemetryHooks=!0;var t=e.XMLHttpRequest;if(t&&t.prototype&&"function"==typeof t.prototype.open){var n=t.prototype.open;t.prototype.open=function(e,t){var i=Array.prototype.slice.call(arguments);try{yi(t)&&(Pn("telemetryBlocked"),Fn("blocked XHR",t),i[0]="GET",i[1]=vi)}catch(e){Fn("telemetry XHR hook error",e)}return n.apply(this,i)}}if("function"==typeof e.fetch){var i=e.fetch;e.fetch=function(t){try{var n="string"==typeof t?t:t&&t.url;if(yi(n))return Pn("telemetryBlocked"),Fn("blocked fetch",n),"function"==typeof e.Response&&"function"==typeof Promise?Promise.resolve(new e.Response("{}",{status:200,headers:{"Content-Type":"application/json"}})):i.call(this,vi)}catch(e){Fn("telemetry fetch hook error",e)}return i.apply(this,arguments)}}var r=e.navigator;if(r&&"function"==typeof r.sendBeacon){var a=r.sendBeacon;r.sendBeacon=function(e){try{if(yi(e))return Pn("telemetryBlocked"),Fn("blocked beacon",e),!0}catch(e){Fn("telemetry beacon hook error",e)}return a.apply(this,arguments)}}}}("undefined"!=typeof window?window:null),function(e){if(bn)return bn;var t=JSON.parse,n=[];function i(i,r){var a=t.apply(this,arguments);if(!a||"object"!==T(a)||Array.isArray(a))return a;for(var o=0;o<e.length;o++)try{e[o](a,i)}catch(e){n[o]||(n[o]=!0,console.error("[AxoTube:responsePipeline] AxoTube JSON response filter failed:",e))}return a}function r(){var e=!1;try{if("undefined"==typeof window||!window._yttv)return!1;var t=window._yttv;for(var n in t)try{var r=t[n]&&t[n].JSON;r&&"function"==typeof r.parse&&(e=!0,r.parse!==i&&(r.parse=i))}catch(e){}}catch(e){}return e}JSON.parse=i,bn=i;var a=r();if("undefined"!=typeof window&&"function"==typeof setTimeout){var o=function(){a=r()||a,++s>=32||setTimeout(o,!a&&s<20?250:5e3)},s=0;setTimeout(o,a?5e3:250)}}([function(e,t){var n,i,r,a,o,s,u;if(function(e){for(var t=0;t<Sn.length;t++)if(e[Sn[t]])return!0;return!1}(e)){var l={adBlock:!!Se("enableAdBlock"),signin:!!Se("enableSigninReminder"),paidPromo:!!Se("enablePaidPromotionOverlay"),hideEndScreens:!!Se("enableHideEndScreenCards"),youThere:!!Se("enableYouThereRenderer"),shorts:!!Se("enableShorts"),sortSubscriptions:!!Se("sortSubscriptionsByAlphabet"),preferredCodec:Se("videoPreferredCodec"),blockPlayerTracking:!1!==Se("blockPlayerAdTracking"),removeLiveVideos:!!Se("removeLiveVideos"),removeTopLiveGames:!!Se("removeTopLiveGames"),removeMostRelevant:!!Se("removeMostRelevant"),sponsorManualSkips:Se("sponsorBlockManualSkips"),sponsorHighlight:!!Se("enableSponsorBlockHighlight")},c=function(e){if("string"!=typeof e)return!0;for(var t=0;t<xn.length;t++)if(-1!==e.indexOf(xn[t]))return!0;return!1}(t),h=l.adBlock&&c;h&&In("topLevelAds",function(){return function(e){e.adPlacements&&(e.adPlacements=[]),e.playerAds&&(e.playerAds=!1),e.adSlots&&(e.adSlots=[]),!Array.isArray(e)&&e.entries&&(e.entries=e.entries.filter(function(e){return!(e&&e.command&&e.command.reelWatchEndpoint&&e.command.reelWatchEndpoint.adClientParams&&e.command.reelWatchEndpoint.adClientParams.isAd)}))}(e)}),c&&l.blockPlayerTracking&&In("playerTracking",function(){return function(e){var t=On(e);return e.playerResponse&&"object"===T(e.playerResponse)&&(t+=On(e.playerResponse)),t&&Pn("playerTrackingRemoved",t),t}(e)}),In("streamFormats",function(){return function(e,t){if(e&&e.streamingData&&e.streamingData.adaptiveFormats&&t&&"any"!==t){var n=e.streamingData.adaptiveFormats;n.find(function(e){return e.mimeType&&e.mimeType.includes(t)})&&(e.streamingData.adaptiveFormats=n.filter(function(e){return!(!e.mimeType||!e.mimeType.startsWith("audio/"))||e.mimeType&&e.mimeType.includes(t)}))}}(e,l.preferredCodec)}),In("playerNotices",function(){return function(e,t){e.paidContentOverlay&&!t.paidPromo&&(e.paidContentOverlay=null),e.endscreen&&t.hideEndScreens&&(e.endscreen=null),e.messages&&Array.isArray(e.messages)&&!t.youThere&&(e.messages=e.messages.filter(function(e){return!(e&&e.youThereRenderer)}))}(e,l)});var d,p,f,m,g,v,y=null==e||null===(n=e.contents)||void 0===n||null===(n=n.tvBrowseRenderer)||void 0===n||null===(n=n.content)||void 0===n||null===(n=n.tvSurfaceContentRenderer)||void 0===n||null===(n=n.content)||void 0===n?void 0:n.sectionListRenderer;null!=y&&y.contents&&In("browse",function(){y.contents=ci(y.contents,"feedNudgeRenderer",l),h&&(y.contents=y.contents.filter(function(e){return!wn(e)})),ri(y.contents,bi(l,h,!0))}),null!=e&&null!==(i=e.title)&&void 0!==i&&i.runs&&(d=e,v=function(e,t,n){var i={settingCategoryCollectionRenderer:{items:t,categoryId:e,focused:!1,trackingParams:"null"}};return n&&(i.settingCategoryCollectionRenderer.title={runs:[{text:n}]}),i}("axotube_category",[(p=Nt("settings.ttSettings.title"),f="axotube_open_action",m={customAction:{action:"AXO_SETTINGS_SHOW",parameters:[]}},g=Nt("settings.ttSettings.summary"),{settingActionRenderer:{title:{runs:[{text:p}]},serviceEndpoint:m,summary:{runs:[{text:g}]},trackingParams:"null",actionLabel:{runs:[{text:p}]},itemId:f,thumbnail:{thumbnails:[{url:"https://www.gstatic.com/ytlr/img/parent_code.png"}]}}})]),d.items&&Array.isArray(d.items)||(d.items=[]),d.items.unshift(v)),null!=e&&null!==(r=e.contents)&&void 0!==r&&null!==(r=r.sectionListRenderer)&&void 0!==r&&r.contents&&In("sectionList",function(){return ri(e.contents.sectionListRenderer.contents,bi(l,h,!0))}),null!=e&&null!==(a=e.continuationContents)&&void 0!==a&&null!==(a=a.sectionListContinuation)&&void 0!==a&&a.contents&&In("sectionContinuation",function(){return ri(e.continuationContents.sectionListContinuation.contents,bi(l,h,!0))}),null!=e&&null!==(o=e.continuationContents)&&void 0!==o&&null!==(o=o.horizontalListContinuation)&&void 0!==o&&o.items&&In("horizontalContinuation",function(){var t=e.continuationContents.horizontalListContinuation;t.items=ii(t.items,!1)});var b=null==e||null===(s=e.contents)||void 0===s||null===(s=s.tvBrowseRenderer)||void 0===s||null===(s=s.content)||void 0===s||null===(s=s.tvSecondaryNavRenderer)||void 0===s?void 0:s.sections;b&&In("secondaryNav",function(){for(var e=0;e<b.length;e++){var t=b[e].tvSecondaryNavSectionRenderer;if(t&&t.tabs){l.sortSubscriptions&&xi(t.tabs);for(var n=0;n<t.tabs.length;n++){var i,r,a=null===(i=t.tabs[n].tabRenderer.content)||void 0===i||null===(i=i.tvSurfaceContentRenderer)||void 0===i?void 0:i.content;null!=a&&null!==(r=a.sectionListRenderer)&&void 0!==r&&r.contents&&ri(a.sectionListRenderer.contents,bi(l,h,!0))}}}});var x=null==e||null===(u=e.contents)||void 0===u||null===(u=u.singleColumnWatchNextResults)||void 0===u||null===(u=u.pivot)||void 0===u?void 0:u.sectionListRenderer;x&&In("watchNext",function(){x.contents=ci(x.contents,"alertWithActionsRenderer",l),ri(x.contents,bi(l,h,!1)),function(e){if(window.queuedVideos.videos.length){var t=window.queuedVideos.videos.slice();t.unshift({tileRenderer:{contentType:"TILE_CONTENT_TYPE_VIDEO",metadata:{tileMetadataRenderer:{title:{simpleText:"Clear Queue"}}},onSelectCommand:{customAction:{action:"CLEAR_QUEUE"}},style:"TILE_STYLE_YTLR_DEFAULT"}});var n=t.findIndex(function(e){return e.contentId===window.queuedVideos.lastVideoId});e.unshift(function(e,t){return{shelfRenderer:{shelfHeaderRenderer:{title:{simpleText:e}},tvhtml5ShelfRendererType:"TVHTML5_SHELF_RENDERER_TYPE_GRID",content:{horizontalListRenderer:{items:t,selectedIndex:arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,visibleItemCount:3}}}}}("Queued Videos",t,-1!==n?n:0))}}(x.contents)}),In("sponsorBlock",function(){return di(e,l)}),h&&"string"==typeof t&&t.length>=1e4&&In("fallback",function(){var t=function(e,t){for(var n=!(!t||!t.player),i=0,r=0,a=!1,o=[{node:e,depth:0}],s=0;s<o.length;){var u=o[s++],l=u.node;if(l&&"object"===T(l)){if(++r>2e3){a=!0;break}if(Array.isArray(l)){for(var c=l.length-1;c>=0;c--){var h=l[c];h&&"object"===T(h)&&li(h)&&(l.splice(c,1),i++)}if(u.depth<8)for(var d=0;d<l.length;d++)o.push({node:l[d],depth:u.depth+1})}else{for(var p=0;p<oi.length;p++){var f=oi[p];Array.isArray(l[f])&&l[f].length&&(l[f]=[],i++)}for(var m=0;m<si.length;m++){var g=si[m];l[g]&&(l[g]=!1,i++)}if(n)for(var v=0;v<ui.length;v++)En(l,ui[v])&&(delete l[ui[v]],i++);if(u.depth<8)for(var y in l)En(l,y)&&l[y]&&"object"===T(l[y])&&o.push({node:l[y],depth:u.depth+1})}}}return a&&Fn("fallback search hit node cap",2e3),{removed:i,nodes:r,truncated:a}}(e,{player:l.blockPlayerTracking});t.removed&&(Pn("knownPathMiss",t.removed),Pn("fallbackRemoved",t.removed),Fn("fallback removed",t.removed,"entries from",t.nodes,"nodes"))})}},function(e){if(Array.isArray(e.items)){var t=Se("disabledSidebarContents"),n=Se("disableChannelsOnSidebar");if(null!=t&&t.length||n)for(var i=0;i<e.items.length;i++){var r=e.items[i]&&e.items[i].guideSectionRenderer;if(r&&Array.isArray(r.items))for(var a=0;a<r.items.length;a++){var o,s=r.items[a]&&r.items[a].guideEntryRenderer;s&&((null!=t&&t.length&&t.includes(null===(o=s.icon)||void 0===o?void 0:o.iconType)||n&&null!=s&&s.thumbnail)&&(r.items.splice(a,1),a--))}}}}]),gi=JSON.stringify,JSON.stringify=function(e,t,n){var i,r=null==e||null===(i=e.playbackContext)||void 0===i?void 0:i.contentPlaybackContext;if(r&&!r.isInlinePlaybackNoAd){var a=Object.prototype.hasOwnProperty.call(r,"isInlinePlaybackNoAd"),o=r.isInlinePlaybackNoAd;try{return r.isInlinePlaybackNoAd=!0,gi.apply(this,arguments)}finally{a?r.isInlinePlaybackNoAd=o:delete r.isInlinePlaybackNoAd}}return gi.apply(this,arguments)},window.JSON.stringify=JSON.stringify;var Si={enablePremiumHbrSupport:!0,abortPendingPageRequests:!0,enableWebGlobalConfigHotConfig:!1,enablePremiumLiteUpsellLr:!1,enablePremiumPageDeeplink:!1,premiumLiteUpsellMaxTimesSeen:Number.MAX_SAFE_INTEGER,premiumLiteUpsellSeenRecentlyDays:9999,premiumLiteUpsellSerializedParams:"",enableIfaReporting:!1,enableIfaEncryption:!1,enableAdsClientLogging:!1,enableNetworkMonitoringUnified:!1,enableHiddenVisibilityLogging:!1,enableCobaltMetrics:!1,enableCobaltRequestHistograms:!1,enableCobaltHttpCache:!1,enableCobaltHttpCacheLogging:!1,reportAuthCredentialIntervalSeconds:0,oneClickSeek:"on",enableSkipPreviousButton5sThreshold:!0,enableCaptionsPersistence:!0,enableKabukiCaptionPersistence:!0,enableGridWatchNext:!0,enableNavLoadOnRightArrow:!0,enableRenderSingleSearchBar:!0,lazyLoadingAlgorithm:0,enableNewAudioSettingsMenu:!0,enableDirectEntryToShortsClient:!0,enableYtlrKeyboardForSearch:!0,enablePostPlayMode:!0,enablePaidTosViewer:!0,useReduxForPlayerStyles:!0};function Ei(){try{return!("undefined"==typeof window||!window.tectonicConfig||"object"!==T(window.tectonicConfig.featureSwitches))&&(window.tectonicConfig.disallowUnifiedFlagAccess=!1,Object.assign(window.tectonicConfig.featureSwitches,Si),!0)}catch(e){return!1}}var wi=0;function ki(e){if("off"!==Le()&&e&&!1!==e.isConnected){var t="",n=!1;if("IMG"===e.tagName&&e.src)t=e.src;else if(e.style&&e.style.backgroundImage){var i=e.style.backgroundImage.match(/url\(['"]?(.*?)['"]?\)/);i&&i[1]&&(t=i[1],n=!0)}if(t&&t.includes("i.ytimg.com/vi/")){var r=jn(t);if(r&&e.getAttribute("data-hq-upgraded")!==r){var a=t.match(/\/(maxresdefault|sddefault|hqdefault|mqdefault|default)\.jpg/),o=a?a[1]:"default",s=_n.get(r);if(s&&o+".jpg"===s)e.setAttribute("data-hq-upgraded",r);else{e.setAttribute("data-hq-upgraded",r);var u=function(t){if(e&&!1!==e.isConnected){var i="https://i.ytimg.com/vi/"+r+"/"+t;n?e.style.backgroundImage='url("'+i+'")':(e.removeAttribute("srcset"),e.src=i)}};s?u(s):function(e,t){if(e&&"function"==typeof t){var n=_n.get(e);if(n)t(n);else if(Un.has(e))Un.get(e).push(t);else{Un.set(e,[t]);var i=function(t){var n=Un.get(e)||[];Un.delete(e),_n.set(e,t),n.forEach(function(e){try{e(t)}catch(e){}})},r=function(t,n){var r=new Image;r.onload=function(){120===this.naturalWidth&&90===this.naturalHeight?n():i(t)},r.onerror=n,r.src="https://i.ytimg.com/vi/".concat(e,"/").concat(t)};r("maxresdefault.jpg",function(){r("sddefault.jpg",function(){return i("hqdefault.jpg")})})}}}(r,function(e){u(e)})}}}}}function Di(){var e={subtree:!0,childList:!0,attributes:!0,attributeFilter:["class","src","srcset","style"]},t=function(e){if(e){var t=e.shadowRoot||e,n=t.querySelector?t.querySelector("img"):null;!n&&t!==e&&e.querySelector&&(n=e.querySelector("img")),n&&ki(n);var i=[];t.querySelectorAll?i=t.querySelectorAll('[style*="background-image"]'):e.querySelectorAll&&(i=e.querySelectorAll('[style*="background-image"]'));for(var r=0;r<i.length;r++)ki(i[r]);e.style&&e.style.backgroundImage&&ki(e)}},n=function(e){for(var t=e;t;){if(t.classList&&t.classList.contains("zylon-focus"))return t;if(t.closest){var n=t.closest(".zylon-focus");if(n)return n}var i=t.parentElement;if(!i&&t.getRootNode){var r=t.getRootNode();i=r&&r.host||null}t=i}return null},i=null,r=null,a=null,o=function(){if(!i){var o=document.getElementById("container")||document.body;o&&(i=new MutationObserver(function(e){r=r?r.concat(e):e,a||(a=requestAnimationFrame(function(){a=null;var e=r||[];r=null,function(e){try{for(var i=null,r=0;r<e.length;r++){var a=e[r],o=a.target;if("attributes"!==a.type||"class"!==a.attributeName)if("attributes"!==a.type){if("childList"===a.type){i||(i=document.querySelector(".zylon-focus"));for(var s=!1,u=0;u<a.addedNodes.length;u++){var l=a.addedNodes[u];if(1===l.nodeType)if(i&&(i===l||i.contains(l)||l.contains(i)))s||(t(i),s=!0);else if(!i&&l.querySelectorAll)for(var c=l.querySelectorAll(".zylon-focus"),h=0;h<c.length;h++)t(c[h])}}}else{if("src"===a.attributeName||"srcset"===a.attributeName){if("IMG"!==o.tagName)continue;var d="src"===a.attributeName?o.getAttribute("src"):o.getAttribute("srcset");if(!d||-1===d.indexOf("i.ytimg.com/vi/"))continue}else{if("style"!==a.attributeName)continue;var p=o.style&&o.style.backgroundImage;if(!p||-1===p.indexOf("i.ytimg.com/vi/"))continue}if(n(o)){var f=o.getAttribute("data-hq-upgraded"),m="";if("IMG"===o.tagName)m=o.src;else if(o.style&&o.style.backgroundImage){var g=o.style.backgroundImage.match(/url\(['"]?(.*?)['"]?\)/);m=g?g[1]:""}var v=m?jn(m):null;if(f&&f===v)continue;o.removeAttribute("data-hq-upgraded"),ki(o)}}else o.classList&&o.classList.contains("zylon-focus")&&t(o)}}catch(e){console.error("[AxoTube:hqThumbnailsFocusObserver] Focus handling failed:",e)}}(e)}))}),i.observe(o,e))}},s=function(){"off"!==Le()?o():(i&&(i.disconnect(),i=null),a&&(cancelAnimationFrame(a),a=null),r=null)},u=["enableHqThumbnails","enablePerformanceMode","enableReducedMotion","enableLowMemoryMode"];we.addEventListener("configChange",function(e){e.detail&&-1!==u.indexOf(e.detail.key)&&s()}),s()}!function e(){Ei()||(wi+=1)>=50||setTimeout(e,200)}(),we.addEventListener("configChange",function(){Ei()}),"loading"===document.readyState?document.addEventListener("DOMContentLoaded",function(){setTimeout(Di,1e3)}):setTimeout(Di,1e3);var Ai={player:[],video:[],videoId:[]},Ci=null,Ti=null,Pi=null,Fi=null,Bi=!1;function Ii(){return document.querySelector(".html5-video-player")}function Li(){return document.querySelector("video")}function Oi(e){try{var t=e&&"function"==typeof e.getVideoData&&e.getVideoData();if(t&&t.video_id)return t.video_id}catch(e){}var n=/[?&]v=([^&]+)/.exec(window.location.hash||"");return n?n[1]:null}function Ni(e,t,n){Ai[e].slice().forEach(function(e){try{e(t,n)}catch(e){console.warn("[AxoTube:playerLifecycle] Listener failed:",e)}})}function Ri(){var e=Ii(),t=Li(),n=Oi(e),i=Ci,r=Ti,a=Pi;Ci=e,Ti=t,Pi=n,e!==i&&Ni("player",e,i),t!==r&&Ni("video",t,r),n!==a&&Ni("videoId",n,a)}function Mi(e,t){if("function"!=typeof t)throw new TypeError("A lifecycle listener must be a function");Bi||(Bi=!0,window.addEventListener("hashchange",Ri),document.addEventListener("DOMContentLoaded",Ri),Fi=setInterval(Ri,2e3),Ri()),Ri(),Ai[e].push(t);var n="player"===e?Ci:"video"===e?Ti:Pi;try{t(n,null)}catch(e){console.warn("[AxoTube:playerLifecycle] Listener failed:",e)}return function(){var n=Ai[e].indexOf(t);-1!==n&&Ai[e].splice(n,1),Ai.player.length||Ai.video.length||Ai.videoId.length||Bi&&(Bi=!1,clearInterval(Fi),Fi=null,window.removeEventListener("hashchange",Ri),document.removeEventListener("DOMContentLoaded",Ri),Ci=null,Ti=null,Pi=null)}}function _i(e){return Mi("player",e)}function Ui(e){return Mi("video",e)}function ji(e){return Mi("videoId",e)}function Hi(e,t){var n=null;return{promise:new Promise(function(i,r){(n=new XMLHttpRequest).open("GET",e,!0),n.timeout=t,n.onload=function(){if(404===n.status)return i(null);if(n.status<200||n.status>=300)return r(new Error("HTTP ".concat(n.status," for ").concat(e)));try{i(JSON.parse(n.responseText))}catch(e){r(e)}},n.onerror=function(){r(new Error("network error for ".concat(e)))},n.ontimeout=function(){r(new Error("timed out after ".concat(t,"ms for ").concat(e)))},n.onabort=function(){r(new Error("aborted"))},n.send()}),abort:function(){n&&4!==n.readyState&&n.abort()}}}var zi=["https://sponsor.ajay.app/api","https://sponsorblock.inf.re/api"],Vi=["sponsor","intro","outro","interaction","selfpromo","preview","filler","music_offtopic","poi_highlight"],Ki={sponsor:"enableSponsorBlockSponsor",intro:"enableSponsorBlockIntro",outro:"enableSponsorBlockOutro",interaction:"enableSponsorBlockInteraction",selfpromo:"enableSponsorBlockSelfPromo",preview:"enableSponsorBlockPreview",filler:"enableSponsorBlockFiller",music_offtopic:"enableSponsorBlockMusicOfftopic"},Gi={sponsor:"#00d400",intro:"#00ffff",outro:"#0202ed",interaction:"#cc00ff",selfpromo:"#ffff00",preview:"#008fd6",filler:"#7300FF",music_offtopic:"#ff9900",poi_highlight:"#9b044c"},Ji=Nn(20),Xi="axotube-sponsorblock-segments",Wi='ytlr-progress-bar [idomkey="slider"]',qi="".concat(Wi,"::after, ").concat('ytlr-multi-markers-player-bar-renderer [idomkey^="chapter-"]',"::after { content: ''; position: absolute; inset: 0; pointer-events: none; opacity: 0.7; }");function Yi(e){return Gi[e]||"blue"}function Qi(e){return Nt("sponsorblock.segments.".concat(e))||e}function Zi(e){for(var t=[],n=0;n<e.length;n++)-1===t.indexOf(e[n])&&t.push(e[n]);return t.join(", ")}function $i(e,t){if("poi_highlight"===e)return Se("enableSponsorBlockHighlight")?"highlight":"off";var n=Ki[e];return n&&Se(n)?-1!==t.indexOf(e)?"show":"skip":"off"}function er(e){var t=document.getElementById(Xi);e?(t||((t=document.createElement("style")).id=Xi,(document.head||document.documentElement).appendChild(t)),t.textContent!==e&&(t.textContent=e)):t&&(t.textContent="")}function tr(e,t,n){for(var i=[],r=0;r<e.length;r++){var a=e[r];if(!(a.end<=t||a.start>=n)){var o=Math.max(0,(a.start-t)/(n-t)*100),s=Math.min(100,(a.end-t)/(n-t)*100);i.push("linear-gradient(to right, transparent ".concat(o,"%, ").concat(a.color," ").concat(o,"%, ").concat(a.color," ").concat(s,"%, transparent ").concat(s,"%)"))}}return i.length?i.join(", "):"none"}var nr=function(){return p(function e(t){var n=this;u(this,e),this.videoID=t,this.destroyed=!1,this.segments=[],this.active=[],this.drawn=[],this.done={},this.lastSkip=null,this.landing=null,this.settle=null,this.suppressRearm=!1,this.lastT=0,this.videoDuration=0,this.video=null,this.listeners=null,this.request=null,this.frameId=null,this.seekIssuedAt=0,this.barAt=0,this.onTick=function(){return n.tick()},this.onSeeked=function(){return n.handleSeeked()},this.onDuration=function(){n.redrawBar(),n.tick()},this.frame=function(){n.frameId=null,n.tick()},this.refresh()},[{key:"load",value:function(){var e=this,t=Ji.get(this.videoID);if(t)this.apply(t);else{var n,i,r,a,o,s=(n=this.videoID,i=[],r=!1,a=function(){for(var e=0;e<i.length;e++)i[e].abort()},o="videoID=".concat(encodeURIComponent(n),"&service=YouTube&categories=").concat(encodeURIComponent(JSON.stringify(Vi))),{promise:new Promise(function(e){for(var t=0,n=function(t){r||(r=!0,a(),e(t))},s=function(){(t+=1)===zi.length&&n(null)},u=0;u<zi.length;u++){var l=Hi("".concat(zi[u],"/skipSegments?").concat(o),4e3);i.push(l),l.promise.then(function(e){null===e?n([]):Array.isArray(e)?n(e):s()},s)}}),abort:function(){r=!0,a()}});this.request=s,s.promise.then(function(t){if(e.request===s&&(e.request=null,!e.destroyed&&t)){var n=function(e){for(var t=[],n=0,i=0;i<e.length;i++){var r=e[i];if(r&&"string"==typeof r.category&&Array.isArray(r.segment)){var a=r.segment[0],o=r.segment[1];"number"==typeof a&&"number"==typeof o&&a>=0&&o>a&&(r.actionType&&"skip"!==r.actionType||"number"==typeof r.votes&&r.votes<0||("number"==typeof r.videoDuration&&r.videoDuration>n&&(n=r.videoDuration),t.push({key:String(r.UUID||"".concat(r.category,":").concat(a,":").concat(o)),category:r.category,segment:[a,o],start:a,end:o,mode:"off"})))}}return t.sort(function(e,t){return e.start-t.start||t.end-e.end}),t.videoDuration=n,t}(t);Ji.set(e.videoID,n),e.apply(n)}},function(){e.request===s&&(e.request=null)})}}},{key:"apply",value:function(e){this.destroyed||(this.segments=e,this.videoDuration=e.videoDuration||0,this.refresh(),this.tick())}},{key:"refresh",value:function(){for(var e=Se("sponsorBlockManualSkips"),t=Array.isArray(e)?e:[],n=[],i=[],r=0;r<this.segments.length;r++){var a=this.segments[r];a.mode=$i(a.category,t),"skip"!==a.mode&&"show"!==a.mode||n.push(a),"off"!==a.mode&&i.push(a)}this.active=n,this.drawn=i,this.redrawBar()}},{key:"attach",value:function(e){if(!this.destroyed&&e!==this.video&&(this.detach(),e)){this.video=e,this.lastT=e.currentTime||0,this.listeners=[["timeupdate",this.onTick],["play",this.onTick],["playing",this.onTick],["ratechange",this.onTick],["seeked",this.onSeeked],["durationchange",this.onDuration],["loadedmetadata",this.onDuration]];for(var t=0;t<this.listeners.length;t++)e.addEventListener(this.listeners[t][0],this.listeners[t][1]);this.redrawBar(),this.tick()}}},{key:"detach",value:function(){if(this.video&&this.listeners)for(var e=0;e<this.listeners.length;e++)this.video.removeEventListener(this.listeners[e][0],this.listeners[e][1]);this.listeners=null,this.video=null,null!==this.frameId&&(cancelAnimationFrame(this.frameId),this.frameId=null)}},{key:"tick",value:function(){var e=this.video;if(!this.destroyed&&e&&(this.refreshBar(),!(e.paused||e.seeking&&Date.now()-this.seekIssuedAt<2e3))){var t=e.currentTime;if(t>=0&&!(this.videoDuration>0&&isFinite(e.duration)&&Math.abs(e.duration-this.videoDuration)>3)){t<this.lastT-1&&!this.settling(t)&&this.rearm(t),this.lastT=t;var n=this.dueIndex(t);-1!==n&&this.skipAt(n,t),this.video&&null===this.frameId&&this.nearNext(this.video.currentTime)&&(this.frameId=requestAnimationFrame(this.frame))}}}},{key:"dueIndex",value:function(e){if(this.inManual(e))return-1;for(var t=0;t<this.active.length;t++){var n=this.active[t];if(n.start-.1>e)break;if(!("skip"!==n.mode||n.end<=e||this.done[n.key]))return t}return-1}},{key:"inManual",value:function(e){for(var t=0;t<this.active.length;t++){var n=this.active[t];if(n.start>e)break;if("show"===n.mode&&n.end>e)return!0}return!1}},{key:"jumpTarget",value:function(e,t){for(var n=this.active[e],i=n.end,r=!1,a=[n],o=e+1;o<this.active.length;o++){var s=this.active[o];if(s.start>i+.25)break;if("show"===s.mode){s.start>t&&s.start<i&&s.start>n.start&&(i=s.start,r=!0);break}a.push(s),s.end>i&&(i=s.end)}var u=this.video?this.video.duration:NaN;u>0&&i>=u-.5&&(i=Math.max(0,u-.5));for(var l=[],c=[],h=0;h<a.length;h++){var d=a[h];d.start>=i||(c.push(Qi(d.category)),(!r||d.end<=i)&&l.push(d.key))}return{to:i,keys:l,names:c}}},{key:"skipAt",value:function(e,t){for(var n=this.active[e],i=this.jumpTarget(e,t),r=0;r<i.keys.length;r++)this.done[i.keys[r]]=!0;i.to<=t+.25||(this.lastSkip={from:n.start,to:i.to,names:i.names},this.landing={to:i.to,retries:0,at:Date.now()},this.settle={from:n.start,to:i.to,until:Date.now()+3e3,retries:0},this.seekTo(i.to),Se("enableSponsorBlockToasts")&&an(Nt("app.name"),Nt("sponsorblock.toasts.skipping",{segment:Zi(i.names)})))}},{key:"seekTo",value:function(e){this.seekIssuedAt=Date.now(),this.video.currentTime=e}},{key:"handleSeeked",value:function(){var e=this.video;if(!this.destroyed&&e){var t=e.currentTime,n=this.landing;if(this.landing=null,n&&Date.now()-n.at<2e3&&t<n.to-1.5&&n.retries<2)return this.landing={to:n.to,retries:n.retries+1,at:Date.now()},void this.seekTo(n.to);if(!n)if(this.suppressRearm)this.suppressRearm=!1;else if(this.settling(t)){var i=this.settle;if(t<i.to-1.5&&i.retries<2)return i.retries+=1,void this.seekTo(i.to)}else this.rearm(t),this.lastSkip=null;this.lastT=t,this.redrawBar(),this.tick()}}},{key:"settling",value:function(e){var t=this.settle;return!(!t||Date.now()>t.until)&&(e>=t.from-10&&e<=t.to)}},{key:"rearm",value:function(e){for(var t=0;t<this.active.length;t++){var n=this.active[t];n.start>e+1&&delete this.done[n.key]}}},{key:"nearNext",value:function(e){for(var t=0;t<this.active.length;t++){var n=this.active[t];if(!("skip"!==n.mode||n.end<=e||this.done[n.key]))return n.start-e<1.5}return!1}},{key:"tryUndoLastSkip",value:function(){var e=this.lastSkip;if(this.destroyed||!this.video||!e)return!1;var t=this.video.currentTime-e.to;return!(t<0||t>10)&&(this.lastSkip=null,this.landing=null,this.settle=null,this.suppressRearm=!0,this.seekTo(e.from),Se("enableSponsorBlockToasts")&&an(Nt("app.name"),Nt("sponsorblock.toasts.undone",{segment:Zi(e.names)})),!0)}},{key:"refreshBar",value:function(){var e=Date.now();e-this.barAt<1e3||(this.barAt=e,this.redrawBar())}},{key:"redrawBar",value:function(){if(!this.destroyed){for(var e=this.video||Li(),t=e?e.duration:0,n=[],i=0;i<this.drawn.length;i++){var r=this.drawn[i];n.push({start:r.start,end:r.end,color:Yi(r.category)})}er(function(e,t,n){if(!(e&&0!==e.length&&t>0))return"";var i=e.slice().sort(function(e,t){return e.end-e.start-(t.end-t.start)}),r="".concat(qi," ").concat(Wi,"::after { background: ").concat(tr(i,0,t),"; }");if(n)for(var a=0;a<n.length;a++){var o=String(n[a].key).replace(/["\\]/g,"\\$&");r+=' ytlr-multi-markers-player-bar-renderer [idomkey="'.concat(o,'"]::after { background: ').concat(tr(i,n[a].from,n[a].to),"; }")}return r}(n,t,function(e){var t=document.querySelectorAll('ytlr-multi-markers-player-bar-renderer [idomkey="progress-bar"] > [idomkey^="chapter-"]');if(!(t&&0!==t.length&&e>0))return null;for(var n=0,i=0;i<t.length;i++)n+=parseFloat(t[i].style.width);if(!(n>0))return null;for(var r=[],a=0,o=0;o<t.length;o++){var s=parseFloat(t[o].style.width);r.push({key:t[o].getAttribute("idomkey"),from:a/n*e,to:(a+s)/n*e}),a+=s}return r}(t)))}}},{key:"destroy",value:function(){if(!this.destroyed){this.destroyed=!0;var e=this.request;this.request=null,e&&e.abort(),this.detach(),er(""),this.done={},this.lastSkip=null,this.landing=null}}}])}();window.sponsorblock=null;var ir=!1;function rr(){var e=window.sponsorblock;if(e){window.sponsorblock=null;try{e.destroy()}catch(e){}}}function ar(){var e,t=(e=/[?&]v=([^&]+)/.exec(location.hash))?e[1]:null;if(t&&Se("enableSponsorBlock")){if(!window.sponsorblock||window.sponsorblock.videoID!==t){rr();var n=new nr(t);window.sponsorblock=n,n.load(),n.attach(Li())}}else rr()}window.addEventListener("keydown",function(e){if(10009===e.keyCode){var t=window.sponsorblock;t&&t.tryUndoLastSkip()&&(ir=!0,e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation())}},!0),window.addEventListener("keyup",function(e){10009===e.keyCode&&ir&&(ir=!1,e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation())},!0),window.addEventListener("hashchange",ar,!1),Ui(function(e){var t=window.sponsorblock;t&&t.attach(e)}),we.addEventListener("configChange",function(e){var t=e.detail&&e.detail.key||"";if(0===t.indexOf("enableSponsorBlock")||"sponsorBlockManualSkips"===t){var n=window.sponsorblock;n&&"enableSponsorBlock"!==t?(n.refresh(),n.tick()):ar()}}),"loading"===document.readyState?document.addEventListener("DOMContentLoaded",ar):ar();var or=["timeupdate","durationchange","ratechange","seeked","play","pause"],sr=null,ur=null,lr=null,cr=!1;function hr(e){return e<10?"0".concat(e):String(e)}function dr(e){var t=Math.floor(e/3600),n=Math.floor(e%3600/60),i=e%60;return t>0?"".concat(t,":").concat(hr(n),":").concat(hr(i)):"".concat(n,":").concat(hr(i))}function pr(e,t,n){try{var i=e&&"function"==typeof e[t]?e[t]():n;return void 0===i?n:i}catch(e){return n}}function fr(){var e=!!Se("enableRemainingTime");if(e||cr){var t;ur&&ur.parentNode||(t=function(){var e=document.querySelector('[idomkey="time-label"] > [idomkey="elapsedTime"]');return e?e.parentElement:null}(),t!==ur&&(lr&&lr.disconnect(),lr=null,cr=!1,(ur=t)&&(lr=new MutationObserver(function(){return fr()})).observe(ur,{characterData:!0,childList:!0,subtree:!0})));var n=function(){var e=ur?ur.querySelector('[idomkey="elapsedTime"]'):null,t=e?e.firstChild:null;return t&&t.nodeType===Node.TEXT_NODE?t:null}();if(n){var i=Ii(),r=e&&!!i&&/#\/watch/.test(location.hash||"")&&!function(e){var t=pr(e,"getVideoData",null);return!(!t||!t.isLive)}(i);if(r){var a=Math.floor(pr(i,"getDuration",0)),o=Math.floor(pr(i,"getCurrentTime",0)),s=pr(i,"getPlaybackRate",1)||1,u=Math.round(Math.max(0,(a-o)/s)),l="-".concat(dr(u));cr=!0,n.data!==l&&(n.data=l)}else{if(cr){var c=Math.floor(pr(i,"getCurrentTime",0));n.data=dr(c)}cr=!1}}}}Ui(function(e){return function(e){e!==sr&&(sr&&or.forEach(function(e){return sr.removeEventListener(e,fr)}),(sr=e)&&or.forEach(function(e){return sr.addEventListener(e,fr)}),fr())}(e)}),we.addEventListener("configChange",function(e){var t;"enableRemainingTime"===(null===(t=e.detail)||void 0===t?void 0:t.key)&&fr()});var mr=["AXO_SETTINGS_SHOW","AXO_SPEED_SETTINGS_SHOW","SETTINGS_OPEN"];function gr(e){return null!==function(e){if(!e||"object"!==T(e))return null;var t=e.openPopupAction;if(t)return"TOAST"===t.popupType?null:"popup";var n=e.showEngagementPanelEndpoint;return n?n.customAction?null:"reading":e.customAction&&-1!==mr.indexOf(e.customAction.action)?"popup":null}(e)}function vr(){var e=Ii();if(e&&"function"==typeof e.pauseVideo)try{return void e.pauseVideo()}catch(e){}var t=Li();t&&!t.paused&&t.pause()}window.addEventListener("visibilitychange",function(e){Se("enablePauseOnBlur")&&document.hidden&&(e.stopImmediatePropagation(),vr())},!0);var yr=["ytlr-player-page","ytlr-player-actions-container","ytlr-progress-bar"],br=[10,30,60],xr={},Sr={},Er={},wr=0,kr=0,Dr=-1/0,Ar=null;function Cr(e){for(var t=e;t&&t!==document;t=t.parentNode){if(t.getAttribute&&"true"===t.getAttribute("aria-hidden"))return!0;if(t.classList&&t.classList.contains("zylon-hidden"))return!0;var n=window.getComputedStyle(t);if("none"===n.display||"hidden"===n.visibility)return!0}return!1}function Tr(e,t){var n=Ii();try{if(n&&"function"==typeof n.setPlaybackRate)return void n.setPlaybackRate(t)}catch(e){}e.playbackRate=t}function Pr(e,t){var n=e.duration;return n>0?Math.max(0,Math.min(n,t)):null}function Fr(e){e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation()}function Br(e,t){var n=Sr[e];if(n)if(n.timer=null,39===e){if(t.paused)return;n.rateBefore=t.playbackRate||1,Tr(t,2)}else 37===e&&(n.ticker=setInterval(function(){var e=Li();e&&(Ar=null,function(e,t){var n=Pr(e,t);null!==n&&(e.currentTime=n)}(e,e.currentTime-10))},300))}window.addEventListener("keydown",function(e){var t=e.keyCode;if((13===t||37===t||39===t)&&Se("enableOnePressMode")&&function(){if(!/[?&]v=[^&]+/.test(window.location.hash||""))return!1;var e=document.querySelector("ytlr-shorts-page");return!(e&&e.classList&&e.classList.contains("zylon-focus"))}()&&!(function(e){var t=e&&e.closest?e.closest("ytlr-tile-renderer"):null;return!!t&&!Cr(t)}(e.target)||function(){for(var e=document.querySelectorAll(".zylon-focus"),t=0;t<e.length;t++){var n=e[t];if(!(Cr(n)||n.closest&&n.closest("ytlr-player-page, ytlr-player-actions-container, ytlr-progress-bar")))return!0}return!1}()||function(){for(var e=0;e<yr.length;e++){var t=document.querySelector(yr[e]);if(t&&!Cr(t)){var n=window.getComputedStyle(t);if("hidden"!==n.visibility&&parseFloat(n.opacity)>0&&t.getClientRects().length>0)return!0}}return!1}())){var n=Li();if(n)if(Sr[t])Fr(e);else{var i=Date.now();if(void 0!==Er[t]&&i-Er[t]<100)Fr(e);else{if(Er[t]=i,13===t)!function(e){var t=Ii(),n=!e.paused;try{var i=t&&t.getPlayerStateObject&&t.getPlayerStateObject();i&&"boolean"==typeof i.isPlaying&&(n=i.isPlaying)}catch(e){}try{if(t&&"function"==typeof(n?t.pauseVideo:t.playVideo))return void(n?t.pauseVideo():t.playVideo())}catch(e){}n?e.pause():e.play()}(n),Sr[t]={timer:null};else{var r=37===t?-1:1,a=function(e,t){var n=e===wr&&t-Dr<=1e3;return kr=n?kr+1:0,wr=e,n||(Ar=null),br[Math.min(kr,br.length-1)]}(r,i)*r,o=Pr(n,(kr>0&&null!==Ar?Ar:n.currentTime)+a);null!==o&&(Ar=o,n.currentTime=o),Sr[t]={timer:setTimeout(function(){return Br(t,Li())},1e3)}}xr[t]=!0,Fr(e)}}}},!0),window.addEventListener("keyup",function(e){var t=e.keyCode;if(xr[t]){delete xr[t],Fr(e);var n=Sr[t];if(delete Sr[t],n){if(n.timer&&clearTimeout(n.timer),n.ticker&&clearInterval(n.ticker),void 0!==n.rateBefore){var i=Li();i&&Tr(i,n.rateBefore)}13!==t&&(Dr=Date.now())}}},!0);var Ir=0;function Lr(e,t,n){var i=e.filter(function(e){return e&&(n=e.languageCode,String(n||"").toLowerCase().split("-")[0]===t);var n}),r=i.find(function(e){return"asr"!==e.kind});return r||(n&&i.find(function(e){return"asr"===e.kind})||null)}function Or(){var e=++Ir,t=0,n=function(){if(e===Ir&&Se("enableAutoSubtitles")){var i=function(e,t,n){if(!e||"function"!=typeof e.getOptions||"function"!=typeof e.getOption)return"retry";if(-1===(e.getOptions()||[]).indexOf("captions"))return"retry";if("function"==typeof e.loadModule)try{e.loadModule("captions")}catch(e){}var i=e.getOption("captions","track");if(i&&i.languageCode)return"done";var r=e.getOption("captions","tracklist")||[];if(!r.length)return"retry";var a=Lr(r,t,n);return a&&"function"==typeof e.setOption&&e.setOption("captions","track",a),"done"}(Ii(),Se("autoSubtitleLanguage")||"en",!!Se("autoSubtitleAllowAuto"));t+=1,"retry"===i&&t<8&&setTimeout(n,1e3)}};n()}ji(function(e){e&&Or()});var Nr='/* Fixes transparency effect for the video player */\n\n.ytLrWatchDefaultShadow,\ndiv[idomkey="shadow"] {\n background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0) 0, rgba(0, 0, 0, 0.8) 90%) !important;\n background-color: rgba(0, 0, 0, 0.3) !important;\n display: block !important;\n height: 100% !important;\n pointer-events: none !important;\n position: absolute !important;\n width: 100% !important;\n}\n\n/* https://github.com/webosbrew/youtube-webos/commit/4fbe38a18df31ddd62b6cf15f141dd58e1d1a71d */\n.ytLrWatchDefault2025Shadow {\n background-color: rgba(11, 11, 11, 0.5) !important;\n}\n\n/* Fixes shorts having a black background */\n\n.ytLrTileHeaderRendererShorts {\n background-image: none !important;\n}\n\n/* Multiline support for strings in the UI */\n\n.ytLrOverlayPanelHeaderRendererSubtitle {\n white-space: pre-wrap !important;\n}\n\n/* Fixes SponsorBlock segments overlapping with the playhead */\n\n.ytLrProgressBarPlayhead {\n z-index: 1 !important;\n}\n\n.ytLrProgressBarPlayed {\n z-index: 1 !important;\n}\n\n.ytLrSearchBarSearchVoice {\n display: block;\n position: absolute;\n left: 0;\n top: 0;\n pointer-events: auto\n}\n\n.ytLrSearchVoiceHost {\n font-size: 3rem;\n}\n\n.ytLrSearchVoiceMicButtonHost {\n color: rgba(255, 255, 255, 0.7);\n}\n\n.ytLrSearchVoiceMicButtonHost {\n background-color: rgba(255, 255, 255, 0.1);\n border-radius: 50%;\n color: #f1f1f1;\n display: block;\n text-align: center;\n width: 1em;\n height: 1em;\n}\n\n.ytLrSearchVoiceMicButtonIcon {\n display: inline-block;\n font-size: .5em;\n height: .5em;\n width: .5em;\n height: 1em;\n width: 1em;\n margin-top: .5em;\n vertical-align: top !important;\n}\n\n.ytContribIconHost {\n display: inline-block;\n vertical-align: middle;\n}\n\n.ytContribIconTvArrowLeft::before {\n content: "\\e822";\n}\n\n.ytContribIconHost::before {\n font-family: "YouTube Icons Outlined";\n}\n\n/* Make toasts match the YouTube TV look and font */\n\nytlr-toast,\npaper-toast {\n font-family: "YouTube Sans", Roboto, "Noto Sans", Arial, sans-serif !important;\n font-size: 1.4rem !important;\n line-height: 1.4 !important;\n border-radius: 4px !important;\n background-color: rgba(0, 0, 0, 0.85) !important;\n color: rgba(255, 255, 255, 0.95) !important;\n}\n\nytlr-toast .title,\nytlr-toast .subtitle,\nytlr-toast #text,\nytlr-toast iron-p {\n font-family: "YouTube Sans", Roboto, "Noto Sans", Arial, sans-serif !important;\n}\n\nytlr-toast .subtitle,\nytlr-toast iron-p {\n color: rgba(255, 255, 255, 0.75) !important;\n}\n\nytlr-toast img,\nytlr-toast iron-image,\nytlr-toast .thumbnail {\n border-radius: 4px !important;\n}\n\n/* Hide promo shelves (also stripped at the response level in adblock.js) */\n\nytlr-promo-shelf-renderer {\n display: none !important;\n}\n\n/* Reduced motion mode: disable all animations/transitions for performance */\n\nbody.axotube-reduced-motion,\nbody.axotube-reduced-motion *,\nbody.axotube-reduced-motion *::before,\nbody.axotube-reduced-motion *::after {\n animation: none !important;\n animation-delay: 0s !important;\n animation-duration: 0s !important;\n transition: none !important;\n transition-delay: 0s !important;\n transition-duration: 0s !important;\n scroll-behavior: auto !important;\n will-change: auto !important;\n backdrop-filter: none !important;\n}\n\nbody.axotube-reduced-motion ytlr-swipeable-overlay,\nbody.axotube-reduced-motion .ytLrWatchDefaultShadow,\nbody.axotube-reduced-motion div[idomkey="shadow"] {\n opacity: 1 !important;\n}\n\nbody.axotube-reduced-motion ytlr-player,\nbody.axotube-reduced-motion .html5-video-player {\n will-change: auto !important;\n}\n',Rr="/* ytaf-theme-start */",Mr="/* ytaf-theme-end */",_r=document.createElement("style"),Ur="",jr={default:null,white:["#ffffff","#e0e0e0","#c0c0c0"],gray:["#d0d0d0","#9a9a9a","#7f7f7f"],red:["#ff7a7a","#e06a6a","#c25b5b"],blue:["#8ab4ff","#6f96e8","#5a79c9"],green:["#81c995","#68a87a","#538c64"],purple:["#d7aefb","#b28fd8","#8f70b5"],yellow:["#fdd663","#d9b34d","#b5913c"]};function Hr(e){var t=/rgba?\(\s*(\d+),\s*(\d+),\s*(\d+)/.exec(e);return t?(.2126*Number(t[1])+.7152*Number(t[2])+.0722*Number(t[3]))/255:null}function zr(e){var t=String(e.className||"").split(/\s+/).filter(function(e){return e&&/^[A-Za-z0-9_-]+$/.test(e)});return t.length&&e.tagName?e.tagName.toLowerCase()+t.map(function(e){return"."+e}).join(""):""}function Vr(){var e,t=function(e){var t=String(e||"").trim();if(!t)return"";try{var n=new URL(t);return"http:"!==n.protocol&&"https:"!==n.protocol?"":t.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/[\r\n]/g,"")}catch(e){return""}}(Se("routeBackgroundUrl")),n=t?'\n background-image: url("'.concat(t,'") !important;\n background-size: cover !important;\n background-position: center !important;\n background-repeat: no-repeat !important;'):"\n background-color: ".concat((e=Se("routeColor"),/^#[0-9a-f]{6}$/i.test(String(e||""))?e:"#0f0f0f")," !important;"),i=t?"\n ytlr-guide-response {\n background-image: none !important;\n background-color: rgba(15, 15, 15, 0.35) !important;\n }\n ytlr-guide-response > div {\n background-image: none !important;\n background-color: transparent !important;\n }\n ytlr-guide-response .zylon-ve {\n background-image: none !important;\n background-color: transparent !important;\n }":"",r=function(e){var t=jr[e],n=document.getElementById("container");if(!t||!n)return"";for(var i=[[],[],[]],r={},a=n.querySelectorAll("*"),o=0;o<a.length;o++){var s=Hr(getComputedStyle(a[o]).color);if(!(null===s||s<.3)){var u=s>.8?0:s>.55?1:2,l=zr(a[o]);l&&!r[l]&&(r[l]=!0,i[u].push(l))}}for(var c="",h=0;h<3;h++)i[h].length&&(c+=i[h].join(",\n")+" {\n color: "+t[h]+" !important;\n }\n");return c}(Se("textTheme"));Ur="\n ".concat(Rr,"\n #container {\n ").concat(n,"\n }\n ").concat(i,"\n ").concat(r,"\n ").concat(Mr,"\n");var a=document.querySelector("style[nonce]");if(a){var o=a.textContent||"",s=o.indexOf(Rr),u=o.indexOf(Mr);-1!==s&&-1!==u&&(o=o.slice(0,s)+o.slice(u+20)),a.textContent=o+Ur}else _r.textContent=Ur,!_r.parentNode&&document.head&&document.head.appendChild(_r)}document.head&&document.head.appendChild(_r),Vr(),setTimeout(Vr,1500);var Kr=null;window.addEventListener&&window.addEventListener("hashchange",function(){Kr&&clearTimeout(Kr),Kr=setTimeout(Vr,150)});var Gr="1.47.0";function Jr(e,t,n){if("arrayValue"===t){var i=Se(e),r=Array.isArray(i)?i.slice():[];return r.includes(n)?r.splice(r.indexOf(n),1):r.push(n),Ee(e,r)}if("themePreset"===e){var a="string"==typeof n&&Object.prototype.hasOwnProperty.call(ce.themePresetColors,n)?ce.themePresetColors[n]:null;return!("string"!=typeof a||!/^#[0-9a-f]{6}$/i.test(a))&&(Ee("routeColor",a),Ee("themePreset",n))}return Ee(e,n)}var Xr,Wr={};var qr=(Xr||(Xr=1,Wr.qrcode=function(){var e=function(e,t){var n=e,i=c[t],r=null,a=0,o=null,s=new Array,u={},l=function(e,t){r=function(e){for(var t=new Array(e),n=0;n<e;n+=1){t[n]=new Array(e);for(var i=0;i<e;i+=1)t[n][i]=null}return t}(a=4*n+17),h(0,0),h(a-7,0),h(0,a-7),p(),d(),m(e,t),n>=7&&f(e),null==o&&(o=v(n,i,s)),g(o,t)},h=function(e,t){for(var n=-1;n<=7;n+=1)if(!(e+n<=-1||a<=e+n))for(var i=-1;i<=7;i+=1)t+i<=-1||a<=t+i||(r[e+n][t+i]=0<=n&&n<=6&&(0==i||6==i)||0<=i&&i<=6&&(0==n||6==n)||2<=n&&n<=4&&2<=i&&i<=4)},d=function(){for(var e=8;e<a-8;e+=1)null==r[e][6]&&(r[e][6]=e%2==0);for(var t=8;t<a-8;t+=1)null==r[6][t]&&(r[6][t]=t%2==0)},p=function(){for(var e=b.getPatternPosition(n),t=0;t<e.length;t+=1)for(var i=0;i<e.length;i+=1){var a=e[t],o=e[i];if(null==r[a][o])for(var s=-2;s<=2;s+=1)for(var u=-2;u<=2;u+=1)r[a+s][o+u]=-2==s||2==s||-2==u||2==u||0==s&&0==u}},f=function(e){for(var t=b.getBCHTypeNumber(n),i=0;i<18;i+=1){var o=!e&&1==(t>>i&1);r[Math.floor(i/3)][i%3+a-8-3]=o}for(i=0;i<18;i+=1)o=!e&&1==(t>>i&1),r[i%3+a-8-3][Math.floor(i/3)]=o},m=function(e,t){for(var n=i<<3|t,o=b.getBCHTypeInfo(n),s=0;s<15;s+=1){var u=!e&&1==(o>>s&1);s<6?r[s][8]=u:s<8?r[s+1][8]=u:r[a-15+s][8]=u}for(s=0;s<15;s+=1)u=!e&&1==(o>>s&1),s<8?r[8][a-s-1]=u:s<9?r[8][15-s-1+1]=u:r[8][15-s-1]=u;r[a-8][8]=!e},g=function(e,t){for(var n=-1,i=a-1,o=7,s=0,u=b.getMaskFunction(t),l=a-1;l>0;l-=2)for(6==l&&(l-=1);;){for(var c=0;c<2;c+=1)if(null==r[i][l-c]){var h=!1;s<e.length&&(h=1==(e[s]>>>o&1)),u(i,l-c)&&(h=!h),r[i][l-c]=h,-1==(o-=1)&&(s+=1,o=7)}if((i+=n)<0||a<=i){i-=n,n=-n;break}}},v=function(e,t,n){for(var i=E.getRSBlocks(e,t),r=w(),a=0;a<n.length;a+=1){var o=n[a];r.put(o.getMode(),4),r.put(o.getLength(),b.getLengthInBits(o.getMode(),e)),o.write(r)}var s=0;for(a=0;a<i.length;a+=1)s+=i[a].dataCount;if(r.getLengthInBits()>8*s)throw new Error("code length overflow. ("+r.getLengthInBits()+">"+8*s+")");for(r.getLengthInBits()+4<=8*s&&r.put(0,4);r.getLengthInBits()%8!=0;)r.putBit(!1);for(;!(r.getLengthInBits()>=8*s||(r.put(236,8),r.getLengthInBits()>=8*s));)r.put(17,8);return function(e,t){for(var n=0,i=0,r=0,a=new Array(t.length),o=new Array(t.length),s=0;s<t.length;s+=1){var u=t[s].dataCount,l=t[s].totalCount-u;i=Math.max(i,u),r=Math.max(r,l),a[s]=new Array(u);for(var c=0;c<a[s].length;c+=1)a[s][c]=255&e.getBuffer()[c+n];n+=u;var h=b.getErrorCorrectPolynomial(l),d=S(a[s],h.getLength()-1).mod(h);for(o[s]=new Array(h.getLength()-1),c=0;c<o[s].length;c+=1){var p=c+d.getLength()-o[s].length;o[s][c]=p>=0?d.get(p):0}}var f=0;for(c=0;c<t.length;c+=1)f+=t[c].totalCount;var m=new Array(f),g=0;for(c=0;c<i;c+=1)for(s=0;s<t.length;s+=1)c<a[s].length&&(m[g]=a[s][c],g+=1);for(c=0;c<r;c+=1)for(s=0;s<t.length;s+=1)c<o[s].length&&(m[g]=o[s][c],g+=1);return m}(r,i)};return u.addData=function(e){var t=k(e);s.push(t),o=null},u.isDark=function(e,t){if(e<0||a<=e||t<0||a<=t)throw new Error(e+","+t);return r[e][t]},u.getModuleCount=function(){return a},u.make=function(){l(!1,function(){for(var e=0,t=0,n=0;n<8;n+=1){l(!0,n);var i=b.getLostPoint(u);(0==n||e>i)&&(e=i,t=n)}return t}())},u.createTableTag=function(e,t){e=e||2;var n="";n+='<table style="',n+=" border-width: 0px; border-style: none;",n+=" border-collapse: collapse;",n+=" padding: 0px; margin: "+(t=void 0===t?4*e:t)+"px;",n+='">',n+="<tbody>";for(var i=0;i<u.getModuleCount();i+=1){n+="<tr>";for(var r=0;r<u.getModuleCount();r+=1)n+='<td style="',n+=" border-width: 0px; border-style: none;",n+=" border-collapse: collapse;",n+=" padding: 0px; margin: 0px;",n+=" width: "+e+"px;",n+=" height: "+e+"px;",n+=" background-color: ",n+=u.isDark(i,r)?"#000000":"#ffffff",n+=";",n+='"/>';n+="</tr>"}return n+="</tbody>",n+="</table>"},u.createImgTag=function(e,t){e=e||2,t=void 0===t?4*e:t;var n=u.getModuleCount()*e+2*t,i=t,r=n-t;return T(n,n,function(t,n){if(i<=t&&t<r&&i<=n&&n<r){var a=Math.floor((t-i)/e),o=Math.floor((n-i)/e);return u.isDark(o,a)?0:1}return 1})},u};e.stringToBytes=function(e){for(var t=new Array,n=0;n<e.length;n+=1){var i=e.charCodeAt(n);t.push(255&i)}return t},e.createStringToBytes=function(e,t){var n=function(){for(var n=A(e),i=function(){var e=n.read();if(-1==e)throw new Error;return e},r=0,a={};;){var o=n.read();if(-1==o)break;var s=i(),u=i()<<8|i();a[String.fromCharCode(o<<8|s)]=u,r+=1}if(r!=t)throw new Error(r+" != "+t);return a}(),i="?".charCodeAt(0);return function(e){for(var t=new Array,r=0;r<e.length;r+=1){var a=e.charCodeAt(r);if(a<128)t.push(a);else{var o=n[e.charAt(r)];"number"==typeof o?(255&o)==o?t.push(o):(t.push(o>>>8),t.push(255&o)):t.push(i)}}return t}};var t,n,i,r,a,o=1,s=2,u=4,l=8,c={L:1,M:0,Q:3,H:2},h=0,d=1,p=2,f=3,m=4,g=5,v=6,y=7,b=(t=[[],[6,18],[6,22],[6,26],[6,30],[6,34],[6,22,38],[6,24,42],[6,26,46],[6,28,50],[6,30,54],[6,32,58],[6,34,62],[6,26,46,66],[6,26,48,70],[6,26,50,74],[6,30,54,78],[6,30,56,82],[6,30,58,86],[6,34,62,90],[6,28,50,72,94],[6,26,50,74,98],[6,30,54,78,102],[6,28,54,80,106],[6,32,58,84,110],[6,30,58,86,114],[6,34,62,90,118],[6,26,50,74,98,122],[6,30,54,78,102,126],[6,26,52,78,104,130],[6,30,56,82,108,134],[6,34,60,86,112,138],[6,30,58,86,114,142],[6,34,62,90,118,146],[6,30,54,78,102,126,150],[6,24,50,76,102,128,154],[6,28,54,80,106,132,158],[6,32,58,84,110,136,162],[6,26,54,82,110,138,166],[6,30,58,86,114,142,170]],n=1335,i=7973,a=function(e){for(var t=0;0!=e;)t+=1,e>>>=1;return t},(r={}).getBCHTypeInfo=function(e){for(var t=e<<10;a(t)-a(n)>=0;)t^=n<<a(t)-a(n);return 21522^(e<<10|t)},r.getBCHTypeNumber=function(e){for(var t=e<<12;a(t)-a(i)>=0;)t^=i<<a(t)-a(i);return e<<12|t},r.getPatternPosition=function(e){return t[e-1]},r.getMaskFunction=function(e){switch(e){case h:return function(e,t){return(e+t)%2==0};case d:return function(e,t){return e%2==0};case p:return function(e,t){return t%3==0};case f:return function(e,t){return(e+t)%3==0};case m:return function(e,t){return(Math.floor(e/2)+Math.floor(t/3))%2==0};case g:return function(e,t){return e*t%2+e*t%3==0};case v:return function(e,t){return(e*t%2+e*t%3)%2==0};case y:return function(e,t){return(e*t%3+(e+t)%2)%2==0};default:throw new Error("bad maskPattern:"+e)}},r.getErrorCorrectPolynomial=function(e){for(var t=S([1],0),n=0;n<e;n+=1)t=t.multiply(S([1,x.gexp(n)],0));return t},r.getLengthInBits=function(e,t){if(1<=t&&t<10)switch(e){case o:return 10;case s:return 9;case u:case l:return 8;default:throw new Error("mode:"+e)}else if(t<27)switch(e){case o:return 12;case s:return 11;case u:return 16;case l:return 10;default:throw new Error("mode:"+e)}else{if(!(t<41))throw new Error("type:"+t);switch(e){case o:return 14;case s:return 13;case u:return 16;case l:return 12;default:throw new Error("mode:"+e)}}},r.getLostPoint=function(e){for(var t=e.getModuleCount(),n=0,i=0;i<t;i+=1)for(var r=0;r<t;r+=1){for(var a=0,o=e.isDark(i,r),s=-1;s<=1;s+=1)if(!(i+s<0||t<=i+s))for(var u=-1;u<=1;u+=1)r+u<0||t<=r+u||0==s&&0==u||o==e.isDark(i+s,r+u)&&(a+=1);a>5&&(n+=3+a-5)}for(i=0;i<t-1;i+=1)for(r=0;r<t-1;r+=1){var l=0;e.isDark(i,r)&&(l+=1),e.isDark(i+1,r)&&(l+=1),e.isDark(i,r+1)&&(l+=1),e.isDark(i+1,r+1)&&(l+=1),0!=l&&4!=l||(n+=3)}for(i=0;i<t;i+=1)for(r=0;r<t-6;r+=1)e.isDark(i,r)&&!e.isDark(i,r+1)&&e.isDark(i,r+2)&&e.isDark(i,r+3)&&e.isDark(i,r+4)&&!e.isDark(i,r+5)&&e.isDark(i,r+6)&&(n+=40);for(r=0;r<t;r+=1)for(i=0;i<t-6;i+=1)e.isDark(i,r)&&!e.isDark(i+1,r)&&e.isDark(i+2,r)&&e.isDark(i+3,r)&&e.isDark(i+4,r)&&!e.isDark(i+5,r)&&e.isDark(i+6,r)&&(n+=40);var c=0;for(r=0;r<t;r+=1)for(i=0;i<t;i+=1)e.isDark(i,r)&&(c+=1);return n+=Math.abs(100*c/t/t-50)/5*10},r),x=function(){for(var e=new Array(256),t=new Array(256),n=0;n<8;n+=1)e[n]=1<<n;for(n=8;n<256;n+=1)e[n]=e[n-4]^e[n-5]^e[n-6]^e[n-8];for(n=0;n<255;n+=1)t[e[n]]=n;var i={glog:function(e){if(e<1)throw new Error("glog("+e+")");return t[e]},gexp:function(t){for(;t<0;)t+=255;for(;t>=256;)t-=255;return e[t]}};return i}();function S(e,t){if(void 0===e.length)throw new Error(e.length+"/"+t);var n=function(){for(var n=0;n<e.length&&0==e[n];)n+=1;for(var i=new Array(e.length-n+t),r=0;r<e.length-n;r+=1)i[r]=e[r+n];return i}(),i={get:function(e){return n[e]},getLength:function(){return n.length},multiply:function(e){for(var t=new Array(i.getLength()+e.getLength()-1),n=0;n<i.getLength();n+=1)for(var r=0;r<e.getLength();r+=1)t[n+r]^=x.gexp(x.glog(i.get(n))+x.glog(e.get(r)));return S(t,0)},mod:function(e){if(i.getLength()-e.getLength()<0)return i;for(var t=x.glog(i.get(0))-x.glog(e.get(0)),n=new Array(i.getLength()),r=0;r<i.getLength();r+=1)n[r]=i.get(r);for(r=0;r<e.getLength();r+=1)n[r]^=x.gexp(x.glog(e.get(r))+t);return S(n,0).mod(e)}};return i}var E=function(){var e=[[1,26,19],[1,26,16],[1,26,13],[1,26,9],[1,44,34],[1,44,28],[1,44,22],[1,44,16],[1,70,55],[1,70,44],[2,35,17],[2,35,13],[1,100,80],[2,50,32],[2,50,24],[4,25,9],[1,134,108],[2,67,43],[2,33,15,2,34,16],[2,33,11,2,34,12],[2,86,68],[4,43,27],[4,43,19],[4,43,15],[2,98,78],[4,49,31],[2,32,14,4,33,15],[4,39,13,1,40,14],[2,121,97],[2,60,38,2,61,39],[4,40,18,2,41,19],[4,40,14,2,41,15],[2,146,116],[3,58,36,2,59,37],[4,36,16,4,37,17],[4,36,12,4,37,13],[2,86,68,2,87,69],[4,69,43,1,70,44],[6,43,19,2,44,20],[6,43,15,2,44,16]],t=function(e,t){var n={};return n.totalCount=e,n.dataCount=t,n},n={getRSBlocks:function(n,i){var r=function(t,n){switch(n){case c.L:return e[4*(t-1)+0];case c.M:return e[4*(t-1)+1];case c.Q:return e[4*(t-1)+2];case c.H:return e[4*(t-1)+3];default:return}}(n,i);if(void 0===r)throw new Error("bad rs block @ typeNumber:"+n+"/errorCorrectLevel:"+i);for(var a=r.length/3,o=new Array,s=0;s<a;s+=1)for(var u=r[3*s+0],l=r[3*s+1],h=r[3*s+2],d=0;d<u;d+=1)o.push(t(l,h));return o}};return n}(),w=function(){var e=new Array,t=0,n={getBuffer:function(){return e},get:function(t){var n=Math.floor(t/8);return 1==(e[n]>>>7-t%8&1)},put:function(e,t){for(var i=0;i<t;i+=1)n.putBit(1==(e>>>t-i-1&1))},getLengthInBits:function(){return t},putBit:function(n){var i=Math.floor(t/8);e.length<=i&&e.push(0),n&&(e[i]|=128>>>t%8),t+=1}};return n},k=function(t){var n=u,i=e.stringToBytes(t),r={getMode:function(){return n},getLength:function(e){return i.length},write:function(e){for(var t=0;t<i.length;t+=1)e.put(i[t],8)}};return r},D=function(){var e=new Array,t={writeByte:function(t){e.push(255&t)},writeShort:function(e){t.writeByte(e),t.writeByte(e>>>8)},writeBytes:function(e,n,i){n=n||0,i=i||e.length;for(var r=0;r<i;r+=1)t.writeByte(e[r+n])},writeString:function(e){for(var n=0;n<e.length;n+=1)t.writeByte(e.charCodeAt(n))},toByteArray:function(){return e},toString:function(){var t="";t+="[";for(var n=0;n<e.length;n+=1)n>0&&(t+=","),t+=e[n];return t+="]"}};return t},A=function(e){var t=e,n=0,i=0,r=0,a={read:function(){for(;r<8;){if(n>=t.length){if(0==r)return-1;throw new Error("unexpected end of file./"+r)}var e=t.charAt(n);if(n+=1,"="==e)return r=0,-1;e.match(/^\s$/)||(i=i<<6|o(e.charCodeAt(0)),r+=6)}var a=i>>>r-8&255;return r-=8,a}},o=function(e){if(65<=e&&e<=90)return e-65;if(97<=e&&e<=122)return e-97+26;if(48<=e&&e<=57)return e-48+52;if(43==e)return 62;if(47==e)return 63;throw new Error("c:"+e)};return a},C=function(e,t){var n=e,i=t,r=new Array(e*t),a={setPixel:function(e,t,i){r[t*n+e]=i},write:function(e){e.writeString("GIF87a"),e.writeShort(n),e.writeShort(i),e.writeByte(128),e.writeByte(0),e.writeByte(0),e.writeByte(0),e.writeByte(0),e.writeByte(0),e.writeByte(255),e.writeByte(255),e.writeByte(255),e.writeString(","),e.writeShort(0),e.writeShort(0),e.writeShort(n),e.writeShort(i),e.writeByte(0);var t=o(2);e.writeByte(2);for(var r=0;t.length-r>255;)e.writeByte(255),e.writeBytes(t,r,255),r+=255;e.writeByte(t.length-r),e.writeBytes(t,r,t.length-r),e.writeByte(0),e.writeString(";")}},o=function(e){for(var t=1<<e,n=1+(1<<e),i=e+1,a=s(),o=0;o<t;o+=1)a.add(String.fromCharCode(o));a.add(String.fromCharCode(t)),a.add(String.fromCharCode(n));var u=D(),l=function(e){var t=e,n=0,i=0,r={write:function(e,r){if(e>>>r!=0)throw new Error("length over");for(;n+r>=8;)t.writeByte(255&(e<<n|i)),r-=8-n,e>>>=8-n,i=0,n=0;i|=e<<n,n+=r},flush:function(){n>0&&t.writeByte(i)}};return r}(u);l.write(t,i);var c=0,h=String.fromCharCode(r[c]);for(c+=1;c<r.length;){var d=String.fromCharCode(r[c]);c+=1,a.contains(h+d)?h+=d:(l.write(a.indexOf(h),i),a.size()<4095&&(a.size()==1<<i&&(i+=1),a.add(h+d)),h=d)}return l.write(a.indexOf(h),i),l.write(n,i),l.flush(),u.toByteArray()},s=function(){var e={},t=0,n={add:function(i){if(n.contains(i))throw new Error("dup key:"+i);e[i]=t,t+=1},size:function(){return t},indexOf:function(t){return e[t]},contains:function(t){return void 0!==e[t]}};return n};return a},T=function(e,t,n,i){for(var r=C(e,t),a=0;a<t;a+=1)for(var o=0;o<e;o+=1)r.setPixel(o,a,n(o,a));var s=D();r.write(s);for(var u=function(){var e=0,t=0,n=0,i="",r={},a=function(e){i+=String.fromCharCode(o(63&e))},o=function(e){if(e<0);else{if(e<26)return 65+e;if(e<52)return e-26+97;if(e<62)return e-52+48;if(62==e)return 43;if(63==e)return 47}throw new Error("n:"+e)};return r.writeByte=function(i){for(e=e<<8|255&i,t+=8,n+=1;t>=6;)a(e>>>t-6),t-=6},r.flush=function(){if(t>0&&(a(e<<6-t),e=0,t=0),n%3!=0)for(var r=3-n%3,o=0;o<r;o+=1)i+="="},r.toString=function(){return i},r}(),l=s.toByteArray(),c=0;c<l.length;c+=1)u.writeByte(l[c]);u.flush();var h="";return h+="<img",h+=' src="',h+="data:image/gif;base64,",h+=u,h+='"',h+=' width="',h+=e,h+='"',h+=' height="',h+=t,h+='"',i&&(h+=' alt="',h+=i,h+='"'),h+="/>"};return e}()),Wr),Yr=e(qr),Qr=Nn(50);function Zr(e){if(Qr.has(e))return Qr.get(e);try{var t,n=Yr.qrcode(6,"H");n.addData(e),n.make();var i=null===(t=n.createImgTag(8,8).match(/src="([^"]+)"/))||void 0===t?void 0:t[1];if(i)return Qr.set(e,i),i}catch(e){console.error("[AxoTube:qrCode] QR code generation failed:",e)}return null}var $r=/^\d{6}$/,ea=/^https?:\/\/[^\s/?#]+$/,ta=null,na=0;function ia(e){if(na=Date.now(),e&&"string"==typeof e.code&&$r.test(e.code)){var t=Array.isArray(e.urls)?e.urls.filter(function(e){return"string"==typeof e&&ea.test(e)}).slice(0,4):[];ta={code:e.code,urls:t}}else ta=null}function ra(){return ta}var aa="http://127.0.0.1:8090",oa={checked:!1,service:null,proxy:null};function sa(e,t){return Jn(e,t).then(function(e){return e&&e.ok?e.json():null}).catch(function(){return null})}function ua(e){Promise.all([sa("".concat(aa,"/api/diagnostics")),sa("".concat("http://127.0.0.1:8081","/axotube/health")),sa("".concat(aa,"/api/pairing-code"))]).then(function(t){var n,i=(n=t[0])&&n.service?{version:n.service.version,launchDebugger:!(!n.launch||!n.launch.debugger),bundle:n.bundle||null}:null,r=t[1]&&t[1].ok?{version:t[1].version}:null;oa={checked:!0,service:i,proxy:r},ia(i?t[2]:null),e&&e()})}function la(){return oa}var ca=[{type:"sponsor",key:"enableSponsorBlockSponsor",icon:"MONEY_HEART"},{type:"intro",key:"enableSponsorBlockIntro",icon:"PLAY_CIRCLE"},{type:"outro",key:"enableSponsorBlockOutro",icon:"PAUSE"},{type:"interaction",key:"enableSponsorBlockInteraction",icon:"SUBSCRIBE"},{type:"selfpromo",key:"enableSponsorBlockSelfPromo",icon:"BROADCAST"},{type:"preview",key:"enableSponsorBlockPreview",icon:"PLAY_ARROW_CIRCLE"},{type:"filler",key:"enableSponsorBlockFiller",icon:"TIMER"},{type:"music_offtopic",key:"enableSponsorBlockMusicOfftopic",icon:"MUSIC"}],ha={skip:"show",show:"off",off:"skip"},da=["default","black","darkGray","charcoal","navy","darkRed","darkGreen","darkPurple"],pa=["default","white","gray","red","blue","green","purple","yellow"],fa=["auto","2160p","1440p","1080p","720p","480p","360p","240p","144p"],ma=["any","vp9","av01","avc1"],ga=["en","hi","es","fr","de","pt","ja","ko","ru"],va=["1440p","2160p"],ya=[.05,.1,.15,.2,.25,.3,.35,.4,.45,.5],ba=[0,.5,1,1.5,2,2.5,3,3.5,4,4.5,5],xa=[0,10,20,30,40,50,60,70,80,90,100],Sa=[10,20,30,60,120,180,240,300],Ea=[.1,.2,.3,.4,.5,.6,.7,.8,.9,1],wa=[{name:"Search",icon:"SEARCH"},{name:"Home",icon:"WHAT_TO_WATCH"},{name:"Sports",icon:"TROPHY"},{name:"News",icon:"NEWS"},{name:"Music",icon:"YOUTUBE_MUSIC"},{name:"Podcasts",icon:"BROADCAST"},{name:"Movies & TV",icon:"CLAPPERBOARD"},{name:"Live",icon:"LIVE"},{name:"Gaming",icon:"GAMING"},{name:"Subscriptions",icon:"SUBSCRIPTIONS"},{name:"Library",icon:"TAB_LIBRARY"},{name:"More",icon:"TAB_MORE"}];function ka(e){return JSON.stringify({browseEndpoint:{browseId:e}})}var Da=[{name:"Search",icon:"SEARCH",value:JSON.stringify({searchEndpoint:{query:""}})},{name:"Home",icon:"WHAT_TO_WATCH",value:ka("FEtopics")},{name:"Sports",icon:"TROPHY",value:ka("FEtopics_sports")},{name:"News",icon:"NEWS",value:ka("FEtopics_news")},{name:"Music",icon:"YOUTUBE_MUSIC",value:ka("FEtopics_music")},{name:"Podcasts",icon:"BROADCAST",value:ka("FEtopics_podcasts")},{name:"Movies & TV",icon:"CLAPPERBOARD",value:ka("FEtopics_movies")},{name:"Gaming",icon:"GAMING",value:ka("FEtopics_gaming")},{name:"Live",icon:"LIVE",value:ka("FEtopics_live")},{name:"Subscriptions",icon:"SUBSCRIPTIONS",value:ka("FEsubscriptions")},{name:"Library",icon:"TAB_LIBRARY",value:ka("FElibrary")},{name:"More",icon:"TAB_MORE",value:ka("FEtopics_more")}];function Aa(e){var t=Ca(e);return t&&Se(t.key)?-1!==(Se("sponsorBlockManualSkips")||[]).indexOf(e)?"show":"skip":"off"}function Ca(e){for(var t=0;t<ca.length;t++)if(ca[t].type===e)return ca[t];return null}function Ta(e,t,n,i){return{name:e,icon:n,value:t,hint:i}}function Pa(e,t,n,i){return{name:e,key:t,value:n,also:i}}function Fa(e,t,n,i,r){return{name:e,icon:t,value:null,menuHeader:i,options:n,refresh:r}}function Ba(e,t){return{title:e,subtitle:t}}function Ia(e,t,n,i,r,a,o){return{name:e,icon:t,value:null,options:{title:n,subtitle:i,content:r,links:o},refresh:a}}function La(e,t){return e.hint=t,e}function Oa(e,t,n){return{name:e,icon:t,launchDebugger:n}}function Na(){var e=ra(),t=e&&e.urls.filter(function(e){return!!e})[0];return e&&t?[Nt("settings.phoneSync.qrHint"),{qrLink:"".concat(t,"/?code=").concat(e.code)}]:[Nt("settings.phoneSync.noQr")]}function Ra(){var e=la();return e.checked?e.service?[Nt("settings.webConfig.online")].concat(function(){var e=ra();if(!e)return[Nt("settings.phoneSync.waiting")];var t=[Nt("settings.phoneSync.intro")],n=e.urls.filter(function(e){return!!e})[0];return n&&t.push(Nt("settings.phoneSync.address",{url:n})),t.push(Nt("settings.phoneSync.code",{code:e.code})),t}()):[Nt("settings.webConfig.offline")]:[Nt("settings.status.checking")]}function Ma(){var e=la(),t=[Nt("settings.about.userscript",{version:Gr})];return e.checked?(t.push(e.service?Nt("settings.about.serviceOnline",{version:e.service.version}):Nt("settings.about.serviceOffline")),t.push(e.proxy?Nt("settings.about.proxyOnline",{version:e.proxy.version}):Nt("settings.about.proxyOffline")),t.push(function(e){var t=e.service&&e.service.bundle;return t&&t.current?t.available&&t.latest?Nt("settings.about.bundleUpdate",{current:t.current,latest:t.latest}):Nt("settings.about.bundleCurrent",{version:t.current}):Nt("settings.about.bundleUnknown")}(e)),t.push(function(e){if(!e.service)return Nt("settings.about.launchUnknown");var t=e.service.launchDebugger?Nt("settings.advanced.launch.debuggerShort"):Nt("settings.advanced.launch.proxyShort");return Nt("settings.about.launchMode",{mode:t})}(e)),t):(t.push(Nt("settings.status.checking")),t)}function _a(){var e,t,n;return[Fa(Nt("settings.playback.title"),"PLAY_CIRCLE",[Fa(Nt("settings.playback.quality.title"),"VIDEO_QUALITY",fa.map(function(e){return Pa("auto"===e?Nt("settings.common.auto"):e,"preferredVideoQuality",e)}),Ba(Nt("settings.playback.quality.title"),Nt("settings.playback.quality.subtitle"))),Fa(Nt("settings.playback.codec.title"),"VIDEO_QUALITY",ma.map(function(e){return Pa("any"===e?Nt("settings.common.any"):e.toUpperCase(),"videoPreferredCodec",e)}),Ba(Nt("settings.playback.codec.title"),Nt("settings.playback.codec.subtitle"))),Fa(Nt("settings.playback.speedStep.title"),"SLOW_MOTION_VIDEO",ya.map(function(e){return Pa("".concat(e,"x"),"speedSettingsIncrement",e)}),Ba(Nt("settings.playback.speedStep.title"),Nt("settings.playback.speedStep.subtitle"))),(n=se(),n&&n.SetFrameRate?Fa(Nt("settings.playback.frameRate.title"),"SYNC",[Ta(Nt("settings.playback.frameRate.match"),"autoFrameRate","SCREEN_SWITCH"),Fa(Nt("settings.playback.frameRate.pause.title"),"TIMER",ba.map(function(e){return Pa(Ga(e),"autoFrameRatePauseVideoFor",1e3*e)}),Ba(Nt("settings.playback.frameRate.pause.title"),Nt("settings.playback.frameRate.pause.subtitle")))],Ba(Nt("settings.playback.frameRate.title"),Nt("settings.playback.frameRate.subtitle"))):null),Fa(Nt("settings.playback.captions.title"),"CAPTIONS",[Ta(Nt("settings.playback.captions.onByDefault"),"enableAutoSubtitles","CLOSED_CAPTION_SELECTED"),Fa(Nt("settings.playback.captions.language.title"),"TRANSLATE",ga.map(function(e){return Pa(Nt("settings.playback.languages.".concat(e)),"autoSubtitleLanguage",e)}),Ba(Nt("settings.playback.captions.language.title"),Nt("settings.playback.captions.language.subtitle"))),Ta(Nt("settings.playback.captions.allowAuto"),"autoSubtitleAllowAuto","SPARKLE"),Ta(Nt("settings.playback.captions.myLanguage"),"enableShowUserLanguage","LANGUAGE"),Ta(Nt("settings.playback.captions.otherLanguages"),"enableShowOtherLanguages","TRANSLATE")],Ba(Nt("settings.playback.captions.title"),Nt("settings.playback.captions.subtitle"))),Fa(Nt("settings.playback.panelShrink.title"),"COMMENT",[Ta(Nt("settings.playback.panelShrink.on"),"enablePanelShrink","COMMENT"),Fa(Nt("settings.playback.panelShrink.size.title"),"VIDEO_QUALITY",[Pa("50%","panelShrinkPercent","50"),Pa("60%","panelShrinkPercent","60"),Pa("70%","panelShrinkPercent","70")],Ba(Nt("settings.playback.panelShrink.size.title"),Nt("settings.playback.panelShrink.size.subtitle")))],Ba(Nt("settings.playback.panelShrink.title"),Nt("settings.playback.panelShrink.subtitle"))),Ta(Nt("settings.playback.pauseInBackground"),"enablePauseOnBlur","PAUSE"),Ta(Nt("settings.playback.remainingTime"),"enableRemainingTime","TIMER")],Ba(Nt("settings.playback.title"),Nt("settings.playback.subtitle"))),Fa(Nt("settings.playerControls.title"),"SETTINGS_REMOTE",[Ta(Nt("settings.playerControls.customize"),"enablePatchingVideoPlayer","EDIT",Nt("settings.playerControls.hints.customize")),Ta(Nt("settings.playerControls.previousNext"),"enablePreviousNextButtons","SKIP_NEXT",Nt("settings.playerControls.hints.previousNext")),Ta(Nt("settings.playerControls.speed"),"enableSpeedControlsButton","SLOW_MOTION_VIDEO",Nt("settings.playerControls.hints.speed")),Ta(Nt("settings.playerControls.superThanks"),"enableSuperThanksButton","HANDS_HEART",Nt("settings.playerControls.hints.superThanks")),Ta(Nt("settings.playerControls.miniPlayer"),"enableMPButton","MULTIVIEW",Nt("settings.playerControls.hints.miniPlayer")),Ta(Nt("settings.playerControls.pipInsteadOfMini"),"enableSwapMPWithPIP","SCREEN_SWITCH",Nt("settings.playerControls.hints.pipInsteadOfMini")),Ta(Nt("settings.ads.paidPromotion"),"enablePaidPromotionOverlay","PAID",Nt("settings.playerControls.hints.paidPromotion")),Ta(Nt("settings.playerControls.onePress"),"enableOnePressMode","SPACE_BAR",Nt("settings.playerControls.hints.onePress"))],Ba(Nt("settings.playerControls.title"),Nt("settings.playerControls.subtitle"))),Fa(Nt("settings.ads.title"),"SLASH_CIRCLE_LEFT",[Ta(Nt("settings.ads.blockAds"),"enableAdBlock","HEALTH_AND_SAFETY"),Ta(Nt("settings.ads.playerTracking"),"blockPlayerAdTracking","HEALTH_AND_SAFETY"),Ta(Nt("settings.ads.adTelemetry"),"blockAdTelemetry","HEALTH_AND_SAFETY"),Ta(Nt("settings.ads.viewStats"),"blockViewStatsTelemetry","HEALTH_AND_SAFETY"),Ta(Nt("settings.ads.liveVideos"),"removeLiveVideos","VISIBILITY_OFF"),Ta(Nt("settings.ads.topLiveGames"),"removeTopLiveGames","VISIBILITY_OFF"),Ta(Nt("settings.ads.mostRelevant"),"removeMostRelevant","VISIBILITY_OFF"),Ta(Nt("settings.ads.sponsorBlock"),"enableSponsorBlock","SPONSORSHIP_STAR"),Fa(Nt("settings.ads.segmentTypes.title"),"SETTINGS",ca.map(function(e){return{name:Nt("settings.ads.segments.".concat(e.type)),icon:e.icon,segment:e.type}}),Ba(Nt("settings.ads.segmentTypes.title"),Nt("settings.ads.segmentTypes.subtitle"))),Ta(Nt("settings.ads.highlightButton"),"enableSponsorBlockHighlight","STAR"),Ta(Nt("settings.ads.notices"),"enableSponsorBlockToasts","INFO")],Ba(Nt("settings.ads.title"),Nt("settings.ads.subtitle"))),Fa(Nt("settings.browsing.title"),"EXPLORE",[Fa(Nt("settings.browsing.thumbnails.title"),"EYE",[Ta(Nt("settings.browsing.hqThumbnails"),"enableHqThumbnails","VIDEO_QUALITY"),Ta(Nt("settings.browsing.deArrowTitles"),"enableDeArrowTitles","TEXT_BOX"),Ta(Nt("settings.browsing.deArrowThumbnails"),"enableDeArrowThumbnails","EYE"),Ta(Nt("settings.browsing.deArrowPeek"),"enableDeArrowPeek","VISIBILITY")],Ba(Nt("settings.browsing.thumbnails.title"),Nt("settings.browsing.thumbnails.subtitle"))),Fa(Nt("settings.browsing.previews.title"),"PLAY_CIRCLE",[Ta(Nt("settings.browsing.previews.on"),"enablePreviews","PLAY_ARROW_CIRCLE"),{name:Nt("settings.browsing.previews.length"),icon:"TIMER",value:"previewLengthSeconds",stepper:5}],Ba(Nt("settings.browsing.previews.title"),Nt("settings.browsing.previews.subtitle"))),Fa(Nt("settings.browsing.hideWatched.title"),"VISIBILITY_OFF",[Ta(Nt("settings.browsing.hideWatched.on"),"enableHideWatchedVideos","VISIBILITY_OFF"),Fa(Nt("settings.browsing.hideWatched.threshold.title"),"TIMER",xa.map(function(e){return Pa("".concat(e,"%"),"hideWatchedVideosThreshold",e)}),Ba(Nt("settings.browsing.hideWatched.threshold.title"),Nt("settings.browsing.hideWatched.threshold.subtitle"))),{name:Nt("settings.browsing.hideWatched.pages.title"),value:null,arrayToEdit:"hideWatchedVideosPages",menuHeader:Ba(Nt("settings.browsing.hideWatched.pages.title"),Nt("settings.browsing.hideWatched.pages.subtitle")),options:[{name:"Search Results",icon:"SEARCH",value:"search"},{name:"Home",icon:"WHAT_TO_WATCH",value:"home"},{name:"Music",icon:"YOUTUBE_MUSIC",value:"music"},{name:"Gaming",icon:"GAMING",value:"gaming"},{name:"Subscriptions",icon:"SUBSCRIPTIONS",value:"subscriptions"},{name:"Library",icon:"TAB_LIBRARY",value:"library"},{name:"More",icon:"TAB_MORE",value:"more"}]}],Ba(Nt("settings.browsing.hideWatched.title"),Nt("settings.browsing.hideWatched.subtitle"))),Ta(Nt("settings.browsing.shorts"),"enableShorts","YOUTUBE_SHORTS_FILL_24"),Ta(Nt("settings.browsing.endScreens"),"enableHideEndScreenCards","VISIBILITY_OFF"),Ta(Nt("settings.browsing.longPress"),"enableLongPress","ADD_TO_PLAYLIST"),Ta(Nt("settings.browsing.stillWatching"),"enableYouThereRenderer","PERSON")],Ba(Nt("settings.browsing.title"),Nt("settings.browsing.subtitle"))),Fa(Nt("settings.home.title"),"HOME",[Fa(Nt("settings.home.startup.title"),"TV",Da.map(function(e){return{name:e.name,icon:e.icon,key:"launchToOnStartup",value:e.value}}),Ba(Nt("settings.home.startup.title"),Nt("settings.home.startup.subtitle"))),Ta(Nt("settings.home.reloadHome"),"reloadHomeOnStartup","ARROW_CIRCLE"),{name:Nt("settings.home.sidebarItems.title"),icon:"LIST",value:null,arrayToEdit:"disabledSidebarContents",menuHeader:Ba(Nt("settings.home.sidebarItems.title"),Nt("settings.home.sidebarItems.subtitle")),options:wa.map(function(e){return{name:e.name,icon:e.icon,value:e.icon}})},Ta(Nt("settings.home.hideChannels"),"disableChannelsOnSidebar","PERSON_MINUS"),Ta(Nt("settings.home.sortSubscriptions"),"sortSubscriptionsByAlphabet","SORT")],Ba(Nt("settings.home.title"),Nt("settings.home.subtitle"))),Fa(Nt("settings.appearance.title"),"AUTO_AWESOME",[Fa(Nt("settings.appearance.theme.title"),"LENS_BLUE",[Fa(Nt("settings.appearance.theme.presets.title"),"LENS_MAGENTA",da.map(function(e){return Pa(Nt("settings.appearance.colors.".concat(e)),"themePreset",e)}),Ba(Nt("settings.appearance.theme.presets.title"),Nt("settings.appearance.theme.presets.subtitle"))),Fa(Nt("settings.appearance.theme.background.title"),"LENS_BLACK",da.map(function(e){return Pa(Nt("settings.appearance.colors.".concat(e)),"routeColor",ce.themePresetColors[e])}),Ba(Nt("settings.appearance.theme.background.title"),Nt("settings.appearance.theme.background.subtitle"))),Fa(Nt("settings.appearance.theme.text.title"),"TEXT_BOX",pa.map(function(e){return Pa(Nt("settings.appearance.textColors.".concat(e)),"textTheme",e)}),Ba(Nt("settings.appearance.theme.text.title"),Nt("settings.appearance.theme.text.subtitle")))],Ba(Nt("settings.appearance.theme.title"),Nt("settings.appearance.theme.subtitle"))),Fa(Nt("settings.appearance.dimming.title"),"EYE_OFF",[Ta(Nt("settings.appearance.dimming.on"),"enableScreenDimming","EYE_OFF"),Fa(Nt("settings.appearance.dimming.timeout.title"),"TIMER",Sa.map(function(e){return Pa(function(e){return e>=60?Nt("settings.minutes",{count:e/60}):Ga(e)}(e),"dimmingTimeout",e)}),Ba(Nt("settings.appearance.dimming.timeout.title"),Nt("settings.appearance.dimming.timeout.subtitle"))),Fa(Nt("settings.appearance.dimming.opacity.title"),"LENS_BLUE",Ea.map(function(e){return Pa("".concat(Math.round(100*e),"%"),"dimmingOpacity",e)}),Ba(Nt("settings.appearance.dimming.opacity.title"),Nt("settings.appearance.dimming.opacity.subtitle")))],Ba(Nt("settings.appearance.dimming.title"),Nt("settings.appearance.dimming.subtitle"))),Ta(Nt("settings.appearance.performance"),"enablePerformanceMode","SPEED_RUN"),Fa(Nt("settings.appearance.clock.title"),"SCHEDULE",[Fa(Nt("settings.appearance.clock.show.title"),"VISIBILITY",[Pa(Nt("settings.appearance.clock.show.off"),"clockMode","off"),Pa(Nt("settings.appearance.clock.show.always"),"clockMode","always"),Pa(Nt("settings.appearance.clock.show.notPlaying"),"clockMode","notPlaying")],Ba(Nt("settings.appearance.clock.show.title"),Nt("settings.appearance.clock.show.subtitle"))),Fa(Nt("settings.appearance.clock.format.title"),"TEXT_BOX",[Pa(Nt("settings.appearance.clock.format.h24"),"clockFormat","24h"),Pa(Nt("settings.appearance.clock.format.h12"),"clockFormat","12h"),Pa(Nt("settings.appearance.clock.format.h12NoAmPm"),"clockFormat","12hNoAmPm")],Ba(Nt("settings.appearance.clock.format.title"),Nt("settings.appearance.clock.format.subtitle"))),Fa(Nt("settings.appearance.clock.position.title"),"LOCATION_POINT",[Pa(Nt("settings.appearance.clock.position.topLeft"),"clockPosition","topLeft"),Pa(Nt("settings.appearance.clock.position.topRight"),"clockPosition","topRight"),Pa(Nt("settings.appearance.clock.position.bottomLeft"),"clockPosition","bottomLeft"),Pa(Nt("settings.appearance.clock.position.bottomRight"),"clockPosition","bottomRight")],Ba(Nt("settings.appearance.clock.position.title"),Nt("settings.appearance.clock.position.subtitle"))),Ta(Nt("settings.appearance.clock.seconds"),"clockShowSeconds","TIMER")],Ba(Nt("settings.appearance.clock.title"),Nt("settings.appearance.clock.subtitle"))),Ta(Nt("settings.appearance.fullAnimations"),"enableFixedUI","PROGRESS_ACTIVITY")],Ba(Nt("settings.appearance.title"),Nt("settings.appearance.subtitle"))),Fa(Nt("settings.axotube.title"),"SPARK",[La(Ia(Nt("settings.webConfig.title"),"PHONELINK",Nt("settings.webConfig.title"),Nt("settings.webConfig.subtitle"),Ra,ua,[{name:Nt("settings.webConfig.qrTitle"),icon:"SMARTPHONE",value:null,options:{title:Nt("settings.webConfig.qrTitle"),subtitle:Nt("settings.webConfig.qrSubtitle"),content:Na}}]),Nt("settings.webConfig.rowHint")),Fa(Nt("settings.system.whosWatching.title"),"ACCOUNT_CIRCLE",[Ta(Nt("settings.system.whosWatching.on"),"enableWhoIsWatchingMenu","PEOPLE"),Ta(Nt("settings.system.whosWatching.always"),"permanentlyEnableWhoIsWatchingMenu","PERSON"),Ta(Nt("settings.system.whosWatching.onExit"),"enableWhosWatchingMenuOnAppExit","EXIT_APP")],Ba(Nt("settings.system.whosWatching.title"),Nt("settings.system.whosWatching.subtitle"))),Ta(Nt("settings.system.signInReminder"),"enableSigninReminder","SIGN_IN"),Ta(Nt("settings.system.welcome"),"showWelcomeToast","SPARKLE"),Fa(Nt("settings.system.updates.title"),"SYSTEM_UPDATE",[{name:Nt("settings.system.updates.checkNow"),icon:"SYSTEM_UPDATE",action:"CHECK_FOR_UPDATES"},Ta(Nt("settings.system.updates.onStartup"),"enableUpdater","SYSTEM_UPDATE")],Ba(Nt("settings.system.updates.title"),Nt("settings.system.updates.subtitle",{version:Gr}))),{name:Nt("settings.system.restartCast"),icon:"CAST_ICON",action:"AXO_CAST_RESTART"},{name:Nt("settings.system.reload"),icon:"REPLAY",action:"AXO_RELOAD_PAGE"}],Ba(Nt("settings.axotube.title"),Nt("settings.axotube.subtitle"))),Fa(Nt("settings.advanced.title"),"SETTINGS",[{name:Nt("settings.advanced.diagnostics.title"),icon:"BUG_REPORT",action:"SETTINGS_OPEN_DIAGNOSTICS"},Fa(Nt("settings.advanced.userAgent.title"),"LANGUAGE",[Pa(Nt("settings.advanced.userAgent.samsung"),"userAgentProfile","samsung",["auto"]),Pa(Nt("settings.advanced.userAgent.android"),"userAgentProfile","android")],Ba(Nt("settings.advanced.userAgent.title"),Nt("settings.advanced.userAgent.subtitle"))),Fa(Nt("settings.advanced.launch.title"),"CAST_MOBILE",[Oa(Nt("settings.advanced.launch.proxy"),"TV",!1),Oa(Nt("settings.advanced.launch.debugger"),"SETTINGS_REMOTE",!0)],Ba(Nt("settings.advanced.launch.title"),Nt("settings.advanced.launch.subtitle")),ua),Fa(Nt("settings.playback.experimental.title"),"VIDEO_QUALITY_4K",[Ta(Nt("settings.playback.experimental.unlock"),"enableExperimentalResolution","VIDEO_QUALITY_8K"),Fa(Nt("settings.playback.experimental.max.title"),"VIDEO_QUALITY",va.map(function(e){return Pa(e,"experimentalMaxResolution",e)}),Ba(Nt("settings.playback.experimental.max.title"),Nt("settings.playback.experimental.max.subtitle")))],Ba(Nt("settings.playback.experimental.title"),Nt("settings.playback.experimental.subtitle")))],Ba(Nt("settings.advanced.title"),Nt("settings.advanced.subtitle"))),Ia(Nt("settings.about.title"),"INFO",Nt("settings.about.title"),Nt("settings.about.subtitle"),Ma,ua,[(e={name:"GitHub",icon:"PRIVACY_PUBLIC",value:null,options:{title:"GitHub",subtitle:Nt("settings.about.socials.githubHint"),content:[Nt("settings.about.scanMessage",{name:"GitHub"}),{qrLink:"https://github.com/TizenDroid/axotube"}]}},t={name:"Discord",icon:"COMMENT",value:null,options:{title:"Discord",subtitle:Nt("settings.about.socials.discordHint"),content:[Nt("settings.about.scanMessage",{name:"Discord"}),{qrLink:"https://discord.gg/UDb8nak5YD"}]}},Fa(Nt("settings.about.socials.title"),"PEOPLE",[e,t],Ba(Nt("settings.about.socials.title"),Nt("settings.about.socials.subtitle"))))]),{text:Nt("settings.moreOnWeb.text")}]}var Ua="root",ja="axo-settings",Ha=new Map,za=null;function Va(e,t){for(var n=0;n<e.length;n++){var i=e[n];if(i){var r="".concat(t,".").concat(n);Ha.set(r,i),Array.isArray(i.options)&&Va(i.options,r),i.options&&Array.isArray(i.options.links)&&Va(i.options.links,"".concat(r,".links"))}}}function Ka(e,t){return[{customAction:{action:e,parameters:t}}]}function Ga(e){return Nt("settings.seconds",{count:e})}function Ja(e,t,n,i){if(void 0!==e.text)return pn(e.text);if(e.action)return un({title:e.name},{icon:e.icon},[{customAction:{action:e.action}}]);if(void 0!==e.segment){var r=Aa(e.segment);return un({title:e.name,subtitle:Nt("settings.segmentModes.".concat(r))},{icon:e.icon},Ka("SETTINGS_SEGMENT",{category:e.segment,panel:i,index:Xa(t)}))}if(void 0!==n){var a=-1!==(Se(n)||[]).indexOf(e.value);return un({title:e.name},{icon:e.icon,secondaryIcon:a?"CHECK_BOX":"CHECK_BOX_OUTLINE_BLANK"},Ka("SETTINGS_SET",{key:n,valName:"arrayValue",value:e.value,panel:i,index:Xa(t)}))}if(void 0!==e.launchDebugger){var o=la(),s=o.service?o.service.launchDebugger:null;return un({title:e.name},{icon:e.icon,secondaryIcon:s===e.launchDebugger?"RADIO_BUTTON_CHECKED":"RADIO_BUTTON_UNCHECKED"},Ka("SETTINGS_LAUNCH",{debugger:e.launchDebugger,panel:i,index:Xa(t)}))}if(void 0!==e.key){var u=Se(e.key),l=u===e.value||!!e.also&&-1!==e.also.indexOf(u);return un({title:e.name},{icon:e.icon,secondaryIcon:l?"RADIO_BUTTON_CHECKED":"RADIO_BUTTON_UNCHECKED"},Ka("SETTINGS_SET",{key:e.key,valName:"stringValue",value:e.value,panel:i,index:Xa(t)}))}return void 0!==e.stepper?un({title:e.name,subtitle:Ga(Se(e.value))},{icon:e.icon},Ka("SETTINGS_OPEN",{id:t})):void 0!==e.arrayToEdit||e.options&&"object"===T(e.options)?un({title:e.name,subtitle:e.hint},{icon:e.icon},Ka("SETTINGS_OPEN",{id:t})):"string"==typeof e.value?un({title:e.name,subtitle:e.hint},{icon:e.icon,secondaryIcon:Se(e.value)?"CHECK_BOX":"CHECK_BOX_OUTLINE_BLANK"},Ka("SETTINGS_TOGGLE",{key:e.value,panel:i,index:Xa(t)})):null}function Xa(e){var t=e.lastIndexOf(".");return Number(e.slice(t+1))}function Wa(e,t,n){for(var i=[],r=0;r<e.length;r++){var a=e[r];if(a){var o=Ja(a,"".concat(t,".").concat(r),n,t);o&&i.push(o)}}return i}function qa(e){var t,n=[],i=f(e);try{for(i.s();!(t=i.n()).done;){var r=t.value;if("string"==typeof r)n.push(pn(r));else if(r&&r.qrLink){var a=Zr(r.qrLink);a&&n.push(fn(a))}}}catch(e){i.e(e)}finally{i.f()}return n}function Ya(e,t){for(var n=[],i=e.options&&e.options.links||[],r=0;r<i.length;r++)if(i[r]){var a=Ja(i[r],"".concat(t,".links.").concat(r),void 0,t);a&&n.push(a)}return n}function Qa(e,t,n){var i,r=function(e){if(e===Ua||!Ha.has(e))return{header:{title:Nt("settings.ttSettings.title"),subtitle:Nt("settings.ttSettings.madeByText")},rows:Wa(za,Ua)};var t=Ha.get(e);if(void 0!==t.stepper){var n=Se(t.value),i=t.stepper;return{header:{title:t.name},rows:[un({title:"−".concat(Ga(i))},null,Ka("SETTINGS_STEP",{key:t.value,step:-i,panel:e})),pn(Ga(n)),un({title:"+".concat(Ga(i))},null,Ka("SETTINGS_STEP",{key:t.value,step:i,panel:e}))]}}if(void 0!==t.arrayToEdit)return{header:t.menuHeader||{title:t.name},rows:Wa(t.options,e,t.arrayToEdit)};if(t.options&&"object"===T(t.options)&&!Array.isArray(t.options)){var r="function"==typeof t.options.content?t.options.content():t.options.content||[];if(r.some(function(e){return e&&e.qrLink})){var a=r.filter(function(e){return"string"==typeof e});return{header:{title:t.options.title,subtitle:a.length?a.join(" "):t.options.subtitle},rows:qa(r.filter(function(e){return e&&e.qrLink}))}}return{header:{title:t.options.title,subtitle:t.options.subtitle},rows:qa(r).concat(Ya(t,e))}}return{header:t.menuHeader||{title:t.name},rows:Wa(t.options||[],e)}}(e);on(r.header,sn(r.rows,n||0),e===Ua?ja:(i=e,"".concat(ja,":").concat(i)),t)}function Za(e,t,n){e(),t&&Qa(t,!0,n)}function $a(e,t){var n,i,r=t||{};switch(e){case"SETTINGS_OPEN":var a=Ha.get(r.id);return Qa(r.id,!1),void(a&&a.refresh&&a.refresh(function(){return Qa(r.id,!0)}));case"SETTINGS_OPEN_DIAGNOSTICS":return void(location.href="http://127.0.0.1:8081/axotube/diagnostics");case"SETTINGS_LAUNCH":return n=r.debugger,i=function(e){an(Nt("app.name"),Nt(e?"settings.advanced.launch.saved":"settings.advanced.launch.failed")),Qa(r.panel,!0,r.index)},void Jn("".concat(aa,"/api/launch"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({debugger:!!n})}).then(function(e){return!(!e||!e.ok)}).catch(function(){return!1}).then(function(e){ua(function(){i&&i(e)})});case"SETTINGS_TOGGLE":return void Za(function(){return Jr(r.key,"boolValue",!Se(r.key))},r.panel,r.index);case"SETTINGS_SET":return void Za(function(){return Jr(r.key,r.valName,r.value)},r.panel,r.index);case"SETTINGS_SEGMENT":return void Za(function(){return function(e,t){var n=Ca(e);if(n){var i="off"!==t;!!Se(n.key)!==i&&Jr(n.key,"boolValue",i),-1!==(Se("sponsorBlockManualSkips")||[]).indexOf(e)!=("show"===t)&&Jr("sponsorBlockManualSkips","arrayValue",e)}}(r.category,ha[Aa(r.category)])},r.panel,r.index);case"SETTINGS_STEP":var o=ce.ranges&&ce.ranges[r.key],s=(Number(Se(r.key))||0)+r.step;return o&&(s=Math.min(o[1],Math.max(o[0],s))),void Za(function(){return Jr(r.key,"intValue",s)},r.panel,1);default:return}}function eo(){za=_a(),Ha=new Map,Va(za,Ua),Qa(Ua,!1)}window.isPipPlaying=!1;var to=null,no=null,io=0,ro=null,ao=null,oo=[],so={length:0,classes:[]},uo={length:0,classes:[]};function lo(){no||io>=120||(no=setTimeout(function(){no=null,co()},250))}function co(){io+=1;try{var e=window._yttv?Object.values(window._yttv).find(function(e){return e&&e.mappings instanceof Map}):null;if(!e)return lo(),!1;var t=e.get("PlayerService"),n=e.get("PlaybackPreviewService");if(!t||!n)return lo(),!1;if(to=t,!n.__axotubePipPatched){var i=n.start,r=n.stop;"function"==typeof i&&(n.start=function(){if(!window.isPipPlaying){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return i.apply(this,t)}}),"function"==typeof r&&(n.stop=function(){if(!window.isPipPlaying){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return r.apply(this,t)}}),n.__axotubePipPatched=!0}return!0}catch(e){return console.warn("[AxoTube:pictureInPicture] PiP service loading failed:",e),lo(),!1}}function ho(e,t){var n=setTimeout(function(){var t=oo.indexOf(n);-1!==t&&oo.splice(t,1),e()},t);return oo.push(n),n}function po(e,t,n){if(e&&e.classList&&t)if(0===n.length&&(n.length=e.classList.length),n.length!==e.classList.length&&n.classes.length){var i,r=f(n.classes);try{for(r.s();!(i=r.n()).done;){var a=i.value;t.classList.add(a)}}catch(e){r.e(e)}finally{r.f()}}else for(var o=0;o<e.classList.length;o++){var s=e.classList[o];n.classes.includes(s)||n.classes.push(s),t.classList.add(s)}}function fo(){if(window.isPipPlaying)try{var e=document.querySelector("ytlr-search-bar");if(!e||document.querySelector("#axo-pip-button"))return;var t=e.querySelector("ytlr-search-voice");if(!t||!t.children[0]||!t.children[0].children[0])return;var n=window._yttv?Object.values(window._yttv).find(function(e){return e instanceof Map&&e.has("CLEAR_COOKIES")}):null;if(!n)return;var i=n.get("MICROPHONE_ON"),r=n.get("CLEAR_COOKIES"),a=document.createElement("ytlr-search-voice");po(t,a,so),a.style.left="10.25em",a.id="axo-pip-button";var o=document.createElement("ytlr-search-voice-mic-button");po(t.children[0],o,uo);for(var s=document.createElement("yt-icon"),u=0;u<t.children[0].children[0].classList.length;u++)s.classList.add(t.children[0].children[0].classList[u]);i&&s.classList.remove(i),r&&s.classList.add(r),o.appendChild(s),a.appendChild(o),e.appendChild(a)}catch(e){console.warn("[AxoTube:pictureInPicture] PiP button creation failed:",e)}}"complete"===document.readyState?co():window.addEventListener("load",co);var mo=null;function go(){ro&&(ro.disconnect(),ro=null),null!==mo&&(cancelAnimationFrame(mo),mo=null);var e=document.querySelector("#axo-pip-button");e&&e.parentNode&&e.parentNode.removeChild(e)}function vo(){!function(){for(;oo.length;)clearTimeout(oo.pop())}(),ao&&(ao.disconnect(),ao=null),go();var e=document.querySelector("video");e&&["width","height","top","left","inset"].forEach(function(t){return e.style.removeProperty(t)});var t=document.querySelector("ytlr-player");t&&(t.style.removeProperty("display"),t.style.removeProperty("background-color"));var n=document.querySelector("ytlr-player-container");n&&n.style.removeProperty("z-index")}function yo(){if(to||co())try{if(!qt())return;var e=document.querySelector("video"),t=document.querySelector("ytlr-player"),n=document.querySelector("ytlr-player-container");if(!e||!t||!n)return;vo();var i=Math.floor(e.currentTime);ao=new MutationObserver(function(r){var a,o=f(r);try{var s,u=function(){if("class"!==a.value.attributeName)return 0;if(t.classList.contains("ytLrPlayerEnabled"))return 0;function r(){t.isConnected&&n.isConnected&&(n.style.zIndex="10",t.style.display="block",t.style.backgroundColor="rgba(0,0,0,0)")}return r(),ho(r,500),e.addEventListener("play",function e(){var t=document.querySelector("video");t&&(t.style.removeProperty("inset"),t.style.width="".concat(window.innerWidth/3.5,"px"),t.style.height="".concat(window.innerHeight/3.5,"px"),t.style.top="68vh",t.style.left="68vw",window.isPipPlaying=!0,!ro&&window.isPipPlaying&&document.body&&((ro=new MutationObserver(function(){null===mo&&(mo=requestAnimationFrame(function(){mo=null,window.isPipPlaying?fo():go()}))})).observe(document.body,{childList:!0,subtree:!0}),fo()),t.removeEventListener("play",e))}),ao&&(ao.disconnect(),ao=null),ho(function(){try{if(to&&to.loadedPlaybackConfig){var e=to.loadedPlaybackConfig,t=Object.assign({},e);e.watchEndpoint&&(t.watchEndpoint=Object.assign({},e.watchEndpoint,{startTimeSeconds:i})),to.loadVideo(t)}}catch(e){console.warn("[AxoTube:pictureInPicture] PiP video load failed:",e)}},1e3),1};for(o.s();!(a=o.n()).done&&(0===(s=u())||1!==s););}catch(e){o.e(e)}finally{o.f()}}),ao.observe(t,{attributes:!0,attributeFilter:["class"]});try{Yt({signalAction:{signal:"HISTORY_BACK"}}).dispatched||vo()}catch(e){throw vo(),e}}catch(e){console.error("[AxoTube:pictureInPicture] Enable PiP failed:",e)}else{var r=0,a=function(){r+=1,to||co()?yo():r<20&&ho(a,200)};ho(a,200)}}function bo(e){if(Se("enableDeArrowPeek")){var t=e&&e.showMenuCommand;if(t&&t.contentId){var n,i=(n=t.contentId,Wn.get(n)||null),r=function(e){var t=Xn.get(e);return t&&t.data?t.data:null}(t.contentId);if(i&&r){if(t.title){var a=!!Se("enableDeArrowTitles")?i.title:qn(r);a&&(t.title={simpleText:a})}if(t.thumbnail){var o=!!Se("enableDeArrowThumbnails")?i.thumbnails:Yn(t.contentId,r);o&&(t.thumbnail={thumbnails:o})}}}}}function xo(e,t){Jn("".concat("http://127.0.0.1:8090","/api/cast/restart"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({reason:e})}).then(function(e){return e.ok?e.json():Promise.reject(new Error("HTTP ".concat(e.status)))}).then(function(e){t&&t(null,e)}).catch(function(e){t&&t(e,null)})}document.addEventListener("visibilitychange",function(){document.hidden||xo("focus")});var So=null,Eo=!1;function wo(e){if(e)try{e.playbackRate=Se("videoSpeed")}catch(e){console.warn("[AxoTube:speedUI] Speed apply failed:",e)}}function ko(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Li();if(e&&e!==So){if(So)try{So.removeEventListener("canplay",Do)}catch(e){}So=e;try{So.addEventListener("canplay",Do)}catch(e){console.warn("[AxoTube:speedUI] Speed initialization failed:",e)}wo(So)}}function Do(){Li()!==So&&ko(),wo(So)}function Ao(){!function(){if(!Eo){Eo=!0;var e=function(e){if(406==e.keyCode||191==e.keyCode)return e.preventDefault(),e.stopPropagation(),"keydown"!==e.type||(Co(),!1)};document.addEventListener("keydown",e,!0),document.addEventListener("keypress",e,!0),document.addEventListener("keyup",e,!0)}}(),Ui(ko)}function Co(){for(var e=Se("videoSpeed"),t=0,n=Number(Se("speedSettingsIncrement")),i=Number.isFinite(n)&&n>0?n:.25,r=Math.max(i,.05),a=[],o=r;o<=5&&a.length<100;o+=r){var s=Math.round(100*o)/100;a.push(un({title:"".concat(s,"x")},null,[{signalAction:{signal:"POPUP_BACK"}},{setClientSettingEndpoint:{settingDatas:[{clientSettingEnum:{item:"videoSpeed"},intValue:s.toString()}]}},{customAction:{action:"SET_PLAYER_SPEED",parameters:s.toString()}}])),e===s&&(t=a.length-1)}1.0001===e&&(t=a.length),a.push(un({title:"Fix stuttering (1.0001x)"},null,[{signalAction:{signal:"POPUP_BACK"}},{setClientSettingEndpoint:{settingDatas:[{clientSettingEnum:{item:"videoSpeed"},intValue:"1.0001"}]}},{customAction:{action:"SET_PLAYER_SPEED",parameters:"1.0001"}}]));try{on("Playback Speed",sn(a,t),"axo-speed")}catch(e){console.error("[AxoTube:speedUI] Speed settings modal failed:",e)}}"loading"===document.readyState?document.addEventListener("DOMContentLoaded",Ao):Ao(),we.addEventListener("configChange",function(e){var t;"videoSpeed"===(null===(t=e.detail)||void 0===t?void 0:t.key)&&(ko(),wo(So))});function To(e){return"string"==typeof window.__axotubeProxyUrl?window.__axotubeProxyUrl+e:(window.location&&window.location.origin?window.location.origin:"http://localhost:8081")+e}function Po(e){fetch(To("/axotube/update/check"),{method:"POST",cache:"no-store"}).then(function(e){if(!e.ok)throw new Error("update check HTTP "+e.status);return e.json()}).then(function(t){if(t.error)throw new Error(t.error);t.available?function(e){var t=Math.floor(Date.now()/1e3);on({title:Nt("updater.modalTitle"),subtitle:Nt("updater.modalBodyNew",{latest:e.latest,current:e.current})},sn([un({title:Nt("updater.updateNow"),subtitle:Nt("updater.updateNowSubtitle")},{icon:"DOWN_ARROW"},[{customAction:{action:"AXO_UPDATE_APPLY",parameters:e.latest}},{signalAction:{signal:"POPUP_BACK"}}]),un({title:Nt("updater.remindLater"),subtitle:Nt("updater.remindLaterSubtitle")},{icon:"SEARCH_HISTORY"},[{customAction:{action:"UPDATE_REMIND_LATER",parameters:t+86400}},{signalAction:{signal:"POPUP_BACK"}}])]),"axo-update-modal",!1)}(t):e&&an(Nt("app.name"),Nt("toasts.upToDate",{version:t.current}),null)}).catch(function(t){console.info("[AxoTube:updater] update check skipped:",t&&t.message),e&&an(Nt("app.name"),Nt("toasts.updateCheckFailed"),null)})}function Fo(){an(Nt("app.name"),Nt("updater.applying"),null),fetch(To("/axotube/update/apply"),{method:"POST"}).then(function(e){if(!e.ok)throw new Error("apply HTTP "+e.status);return e.json()}).then(function(e){if(e.error)throw new Error(e.error);!function(){var e=document.querySelector("video");if(!e||e.paused||e.ended)window.location.reload();else{an(Nt("app.name"),Nt("updater.reloadWhenPaused"),null);var t=function(){e.removeEventListener("pause",t),e.removeEventListener("ended",t),window.location.reload()};e.addEventListener("pause",t),e.addEventListener("ended",t)}}()}).catch(function(e){console.error("[AxoTube:updater] apply failed:",e&&e.message),an(Nt("app.name"),Nt("toasts.updateApplyFailed"),null)})}try{Se("enableUpdater")&&Se("dontCheckUpdateUntil")<=Math.floor(Date.now()/1e3)&&setTimeout(function(){return Po(!1)},3e3)}catch(e){console.error("[AxoTube:updater] init failed, continuing without it",e)}function Bo(e,t){return Qt(e,t)}function Io(){return zt=Lo,$t()}function Lo(e){var t=e.resolveCommand;if(t.__axotubePatched)return!0;var n=function(e,n){var i,r,a,o,s,u;if(!e||"object"!==T(e))return t.call(this,e,n);if(bo(e),function(e){Se("enablePauseOnBlur")&&gr(e)&&vr()}(e),e.setClientSettingEndpoint){if(!Array.isArray(e.setClientSettingEndpoint.settingDatas))return t.call(this,e,n);var l,c=f(e.setClientSettingEndpoint.settingDatas);try{for(c.s();!(l=c.n()).done;){var h,d=l.value,p=null==d||null===(h=d.clientSettingEnum)||void 0===h?void 0:h.item;if("string"==typeof p)if(p.includes("_")){if("I18N_LANGUAGE"===p){var m=d.stringValue;if("string"!=typeof m||!m)continue;var g=new Date;return g.setFullYear(g.getFullYear()+10),document.cookie="PREF=hl=".concat(m,"; expires=").concat(g.toUTCString(),";"),Bo({signalAction:{signal:"RELOAD_PAGE"}}),!0}}else{var v=Object.keys(d).find(function(e){return e.includes("Value")});if(!v)continue;Jr(p,v,"intValue"===v?Number(d[v]):d[v])}}}catch(e){c.e(e)}finally{c.f()}}else{if(e.customAction)return Oo(e.customAction.action,e.customAction.parameters),!0;if(null!=e&&null!==(i=e.signalAction)&&void 0!==i&&i.customAction)return Oo(e.signalAction.customAction.action,e.signalAction.customAction.parameters),!0;if(null!=e&&null!==(r=e.showEngagementPanelEndpoint)&&void 0!==r&&r.customAction)return Oo(e.showEngagementPanelEndpoint.customAction.action,e.showEngagementPanelEndpoint.customAction.parameters),!0;if(null!=e&&null!==(a=e.playlistEditEndpoint)&&void 0!==a&&a.customAction)return Oo(e.playlistEditEndpoint.customAction.action,e.playlistEditEndpoint.customAction.parameters),!0;if("playback-settings"===(null==e||null===(o=e.openPopupAction)||void 0===o?void 0:o.uniqueId))try{var y,b=e.openPopupAction.popup.overlaySectionRenderer.overlay.overlayTwoPanelRenderer.actionPanel.overlayPanelRenderer.content.overlayPanelItemListRenderer.items;if(!Array.isArray(b))return t.call(this,e,n);var x,S=f(b);try{for(S.s();!(x=S.n()).done;){var E,w=x.value;"SLOW_MOTION_VIDEO"===(null==w||null===(E=w.compactLinkRenderer)||void 0===E||null===(E=E.icon)||void 0===E?void 0:E.iconType)&&(w.compactLinkRenderer.subtitle&&(w.compactLinkRenderer.subtitle.simpleText=Nt("player.withAxotube")),w.compactLinkRenderer.serviceEndpoint={clickTrackingParams:"null",signalAction:{customAction:{action:"AXO_SPEED_SETTINGS_SHOW",parameters:[]}}})}}catch(e){S.e(e)}finally{S.f()}b.splice(2,0,un({title:Nt("player.miniPlayer")},{icon:"CLEAR_COOKIES"},[{customAction:{action:"ENTER_MP"}}])),se()&&null!==(y=se())&&void 0!==y&&y.HasSystemFeature("android.software.picture_in_picture")&&b.splice(3,0,un({title:Nt("player.pictureInPicture")},{icon:"PIP"},[{customAction:{action:"ENTER_PIP"}},{signalAction:{signal:"POPUP_BACK"}}]))}catch(e){console.warn("[AxoTube:resolveCommand] Playback settings patch failed:",e)}else null!=e&&null!==(s=e.watchEndpoint)&&void 0!==s&&s.videoId&&(window.isPipPlaying=!1,vo())}if(e.commandExecutorCommand&&Array.isArray(e.commandExecutorCommand.commands)){var k,D=f(e.commandExecutorCommand.commands);try{for(D.s();!(k=D.n()).done;){var A,C,P,F=k.value;F&&"object"===T(F)&&(F.customAction?Oo(F.customAction.action,F.customAction.parameters):null!==(A=F.signalAction)&&void 0!==A&&A.customAction?Oo(F.signalAction.customAction.action,F.signalAction.customAction.parameters):null!==(C=F.showEngagementPanelEndpoint)&&void 0!==C&&C.customAction?Oo(F.showEngagementPanelEndpoint.customAction.action,F.showEngagementPanelEndpoint.customAction.parameters):null!==(P=F.playlistEditEndpoint)&&void 0!==P&&P.customAction?Oo(F.playlistEditEndpoint.customAction.action,F.playlistEditEndpoint.customAction.parameters):t.call(this,F,n))}}catch(e){D.e(e)}finally{D.f()}return!0}return null!=e&&e.requestAccountSelectorCommand&&"ACCOUNT_EVENT_TRIGGER_ON_EXIT"===(null===(u=e.requestAccountSelectorCommand)||void 0===u||null===(u=u.identityActionContext)||void 0===u?void 0:u.eventTrigger)&&!Se("enableWhosWatchingMenuOnAppExit")?(t.call(this,{signalAction:{signal:"EXIT_APP"}}),!1):t.call(this,e,n)};n.__axotubePatched=!0;try{return e.resolveCommand=n,e.resolveCommand===n}catch(e){return!1}}function Oo(e,t){switch(e){case"SKIP":var n=document.createEvent("Event");n.initEvent("keydown",!0,!0),n.keyCode=27,n.which=27,document.dispatchEvent(n);var i=document.querySelector("video"),r=Number(null==t?void 0:t.time);i&&Number.isFinite(r)&&(i.currentTime=r);break;case"AXO_SETTINGS_SHOW":eo();break;case"SETTINGS_OPEN":case"SETTINGS_SET":case"SETTINGS_TOGGLE":case"SETTINGS_STEP":case"SETTINGS_SEGMENT":case"SETTINGS_OPEN_DIAGNOSTICS":case"SETTINGS_LAUNCH":$a(e,t);break;case"AXO_SPEED_SETTINGS_SHOW":Co();break;case"UPDATE_REMIND_LATER":Ee("dontCheckUpdateUntil",t);break;case"AXO_UPDATE_APPLY":Fo();break;case"SET_PLAYER_SPEED":var a=Number(t),o=document.querySelector("video");o&&Number.isFinite(a)&&a>0&&(o.playbackRate=a);break;case"ENTER_MP":yo();break;case"ENTER_PIP":se()&&se().EnterPIP&&se().EnterPIP();break;case"SHOW_TOAST":an(Nt("app.name"),t);break;case"ADD_TO_QUEUE":t?(window.queuedVideos.videos.push(t),an(Nt("app.name"),Nt("toasts.queueAdded"))):an(Nt("app.name"),Nt("toasts.queueAddFailed"));break;case"CLEAR_QUEUE":window.queuedVideos.videos=[],window.queuedVideos.currentIndex=-1,window.queuedVideos.lastVideoId=null,an(Nt("app.name"),Nt("toasts.queueCleared"));break;case"CHECK_FOR_UPDATES":Po(!0);break;case"AXO_CAST_RESTART":xo("manual",function(e,t){!e&&t&&t.ok?t.restarted?an(Nt("app.name"),Nt("toasts.castRestarted")):"too-soon"===t.reason?an(Nt("app.name"),Nt("toasts.castRestartWait")):"discovery-not-running"===t.reason?an(Nt("app.name"),Nt("toasts.castRestartNotRunning")):"in-progress"===t.reason?an(Nt("app.name"),Nt("toasts.castRestarting")):an(Nt("app.name"),Nt("toasts.castRestartFailed")):an(Nt("app.name"),Nt("toasts.castRestartFailed"))});break;case"AXO_RELOAD_PAGE":window.location.reload()}}var No=!1,Ro=null,Mo=!1;function _o(){try{var e;if(null===(e=window.tectonicConfig)||void 0===e||!e.featureSwitches)return;var t=window.tectonicConfig.featureSwitches,n=Fe();t.enableAnimations=!n,t.enableOnScrollLinearAnimation=!n,t.enableListAnimations=!n,t.horizontalListDurationMs=n?0:200,t.verticalListDurationMs=n?0:300,t.listAnimationCurve=n?"linear":"",t.enableSkipButtonSlideInAnimation=!n,t.enableLikeButtonAnimation=!n}catch(e){console.warn("[AxoTube:ui] Reduced motion flags apply failed:",e)}}function Uo(){try{if(!document.body)return;document.body.classList.toggle("axotube-reduced-motion",Fe())}catch(e){console.warn("[AxoTube:ui] Reduced motion apply failed:",e)}}function jo(){if(Mo){var e=document.getElementById("container");e&&e.style.setProperty("opacity","1","important"),Mo=!1}}function Ho(){Ro&&(clearTimeout(Ro),Ro=null),jo()}function zo(){Ho(),Se("enableScreenDimming")&&(Ro=setTimeout(function(){var e;if(Ro=null,Se("enableScreenDimming")){var t=document.querySelector(".html5-video-player");if(t){var n=null===(e=t.getPlayerStateObject)||void 0===e?void 0:e.call(t);if(null==n||!n.isPlaying){var i=document.getElementById("container");i&&(i.style.setProperty("opacity",(1-Se("dimmingOpacity")).toString(),"important"),Mo=!0)}}}else jo()},1e3*Se("dimmingTimeout")))}function Vo(){if(!No&&document.body&&window._yttv){No=!0,Uo();var e=document.querySelector("style[nonce]");if(e)e.textContent+=Nr;else if(document.head){var t=document.createElement("style");t.textContent=Nr,document.head.appendChild(t)}if("function"==typeof window.__releaseBootLoader&&window.__releaseBootLoader(),Se("enableFixedUI")&&!Be()&&!Fe())try{window.tectonicConfig&&(window.tectonicConfig.clientData.legacyApplicationQuality="full-animation",window.tectonicConfig.featureSwitches.enableAnimations=!0,window.tectonicConfig.featureSwitches.enableOnScrollLinearAnimation=!0,window.tectonicConfig.featureSwitches.enableListAnimations=!0)}catch(e){console.warn("[AxoTube:ui] Could not apply UI fixes:",e)}_o();var n=function(e){if(Se("enableScreenDimming")&&zo(),404==e.keyCode&&"keydown"===e.type){try{Io()}catch(e){console.warn("[AxoTube:ui] Settings command patch refresh failed:",e)}try{eo()}catch(e){console.error("[AxoTube:ui] Settings open failed:",e)}}else if(39==e.keyCode&&"keydown"===e.type&&document.querySelector("ytlr-search-text-box > .zylon-focus")&&window.isPipPlaying)try{var t=document.querySelector("ytlr-player");t&&t.style.setProperty("background-color","rgb(0, 0, 0)"),function(){try{if(!to||!to.loadedPlaybackConfig)return;var e=document.querySelector("video"),t=to.loadedPlaybackConfig,n=t.clickTrackingParams,i=t.commandMetadata,r=t.watchEndpoint;if(!Yt({clickTrackingParams:n,commandMetadata:i,watchEndpoint:e&&r?Object.assign({},r,{startTimeSeconds:Math.floor(e.currentTime)}):r}).dispatched)return;window.isPipPlaying=!1,vo()}catch(e){console.error("[AxoTube:pictureInPicture] PiP to fullscreen failed:",e)}}()}catch(e){console.warn("[AxoTube:ui] PiP exit failed:",e)}return!0};document.addEventListener("keydown",n,!0),document.addEventListener("keypress",n,!0),document.addEventListener("keyup",n,!0),setTimeout(function(){Se("showWelcomeToast")&&an(Nt("welcomeMsg.title"),"".concat(Nt("welcomeMsg.subtitle")," · v").concat(Gr))},1e3);var i=Se("launchToOnStartup");if(i)try{Bo(JSON.parse(i))}catch(e){console.warn("[AxoTube:ui] Launch command failed:",e)}else if(Se("reloadHomeOnStartup"))try{location.hash&&"/"!==location.hash.substring(1)&&(location.hash="/")}catch(e){console.warn("[AxoTube:ui] Reload home on startup failed:",e)}try{var r=yn();r&&r.executeFunction(new r.commandFunction("reloadGuideAction"))}catch(e){console.warn("[AxoTube:ui] Guide reload failed:",e)}if(Se("enableFixedUI")&&!Be()&&!Fe())try{new MutationObserver(function(){var e=document.body;null!=e&&e.classList.contains("app-quality-root")&&e.classList.remove("app-quality-root")}).observe(document.body,{attributes:!0,attributeFilter:["class"]})}catch(e){console.warn("[AxoTube:ui] UI quality observer failed:",e)}!function(){try{Io(),Vt||(Vt=!0,window.addEventListener("hashchange",tn,!1))}catch(e){console.warn("[AxoTube:ui] unable to install native command patch:",e)}}()}}function Ko(){No||"complete"!==document.readyState&&"interactive"!==document.readyState||window._yttv&&Vo()}"loading"===document.readyState&&document.addEventListener("DOMContentLoaded",Ko);var Go=0,Jo=setInterval(function(){Go+=1,Ko(),(No||Go>=100)&&clearInterval(Jo)},100),Xo={routeColor:!0,routeBackgroundUrl:!0,themePreset:!0,textTheme:!0};we.addEventListener("configChange",function(e){var t,n=null===(t=e.detail)||void 0===t?void 0:t.key;Xo[n]&&Vr(),"enableReducedMotion"!==n&&"enablePerformanceMode"!==n&&"enableLowMemoryMode"!==n||(Uo(),_o()),"enableScreenDimming"===n&&(Se("enableScreenDimming")?zo():Ho())});var Wo=null;function qo(){Wo&&(clearInterval(Wo),Wo=null)}function Yo(e){e||qo();var t=localStorage["yt.leanback.default::recurring_actions"];if(t){var n;try{n=JSON.parse(t)}catch(e){return}var i=Se("permanentlyEnableWhoIsWatchingMenu"),r=n.data&&n.data.data;if(r){var a=r["startup-screen-account-selector-with-guest"],o=r.whos_watching_fullscreen_zero_accounts,s=r["startup-screen-signed-out-welcome-back"];if(!e){qo();var u=new Date;return u.setDate(u.getDate()+7),void d(u.getTime())}var l=Date.now(),c=a&&a.lastFired;if(!(c&&l-c>0&&l-c<72e5)||i)if(qo(),i){var h=function(){var e=new Date;e.setDate(e.getDate()-7),d(e.getTime())};h(),Wo=setInterval(h,6e4)}else d(Date.now())}}function d(e){a&&(a.lastFired=e),o&&(o.lastFired=e),s&&(s.lastFired=e),localStorage["yt.leanback.default::recurring_actions"]=JSON.stringify(n)}}we.addEventListener("configChange",function(e){var t=e.detail,n=t.key,i=t.value;"enableWhoIsWatchingMenu"===n?Yo(i):"permanentlyEnableWhoIsWatchingMenu"===n&&Yo(Se("enableWhoIsWatchingMenu"))}),Yo(Se("enableWhoIsWatchingMenu"));var Qo={language:{standard:{long:{aa:"Afar",ab:"Abkhazian",ace:"Acehnese",ach:"Acoli",ada:"Adangme",ady:"Adyghe",ae:"Avestan",aeb:"Tunisian Arabic",af:"Afrikaans",afh:"Afrihili",agq:"Aghem",ain:"Ainu",ak:"Akan",akk:"Akkadian",akz:"Alabama",ale:"Aleut",aln:"Gheg Albanian",alt:"Southern Altai",am:"Amharic",an:"Aragonese",ang:"Old English",ann:"Obolo",anp:"Angika",ar:"Arabic","ar-001":"Arabic (world)",arc:"Aramaic",arn:"Mapuche",aro:"Araona",arp:"Arapaho",arq:"Algerian Arabic",ars:"Najdi Arabic",arw:"Arawak",ary:"Moroccan Arabic",arz:"Egyptian Arabic",as:"Assamese",asa:"Asu",ase:"American Sign Language",ast:"Asturian",atj:"Atikamekw",av:"Avaric",avk:"Kotava",awa:"Awadhi",ay:"Aymara",az:"Azerbaijani",ba:"Bashkir",bal:"Baluchi",ban:"Balinese",bar:"Bavarian",bas:"Basaa",bax:"Bamun",bbc:"Batak Toba",bbj:"Ghomala",be:"Belarusian",bej:"Beja",bem:"Bemba",bew:"Betawi",bez:"Bena",bfd:"Bafut",bfq:"Badaga",bg:"Bulgarian",bgc:"Haryanvi",bgn:"Western Balochi",bho:"Bhojpuri",bi:"Bislama",bik:"Bikol",bin:"Bini",bjn:"Banjar",bkm:"Kom",bla:"Siksiká",blo:"Anii",blt:"Tai Dam",bm:"Bambara",bn:"Bangla",bo:"Tibetan",bpy:"Bishnupriya",bqi:"Bakhtiari",br:"Breton",bra:"Braj",brh:"Brahui",brx:"Bodo",bs:"Bosnian",bss:"Akoose",bua:"Buriat",bug:"Buginese",bum:"Bulu",byn:"Blin",byv:"Medumba",ca:"Catalan",cad:"Caddo",car:"Carib",cay:"Cayuga",cch:"Atsam",ccp:"Chakma",ce:"Chechen",ceb:"Cebuano",cgg:"Chiga",ch:"Chamorro",chb:"Chibcha",chg:"Chagatai",chk:"Chuukese",chm:"Mari",chn:"Chinook Jargon",cho:"Choctaw",chp:"Chipewyan",chr:"Cherokee",chy:"Cheyenne",cic:"Chickasaw",ckb:"Central Kurdish",clc:"Chilcotin",co:"Corsican",cop:"Coptic",cps:"Capiznon",cr:"Cree",crg:"Michif",crh:"Crimean Tatar",crj:"Southern East Cree",crk:"Plains Cree",crl:"Northern East Cree",crm:"Moose Cree",crr:"Carolina Algonquian",crs:"Seselwa Creole French",cs:"Czech",csb:"Kashubian",csw:"Swampy Cree",cu:"Church Slavic",cv:"Chuvash",cwd:"Woods Cree",cy:"Welsh",da:"Danish",dak:"Dakota",dar:"Dargwa",dav:"Taita",de:"German","de-AT":"German (Austria)","de-CH":"German (Switzerland)",del:"Delaware",den:"Slave",dgr:"Dogrib",din:"Dinka",dje:"Zarma",doi:"Dogri",dsb:"Lower Sorbian",dtp:"Central Dusun",dua:"Duala",dum:"Middle Dutch",dv:"Divehi",dyo:"Jola-Fonyi",dyu:"Dyula",dz:"Dzongkha",dzg:"Dazaga",ebu:"Embu",ee:"Ewe",efi:"Efik",egl:"Emilian",egy:"Ancient Egyptian",eka:"Ekajuk",el:"Greek",elx:"Elamite",en:"English","en-AU":"English (Australia)","en-CA":"English (Canada)","en-GB":"English (United Kingdom)","en-US":"English (United States)",enm:"Middle English",eo:"Esperanto",es:"Spanish","es-419":"Spanish (Latin America)","es-ES":"Spanish (Spain)","es-MX":"Spanish (Mexico)",esu:"Central Yupik",et:"Estonian",eu:"Basque",ewo:"Ewondo",ext:"Extremaduran",fa:"Persian","fa-AF":"Persian (Afghanistan)",fan:"Fang",fat:"Fanti",ff:"Fula",fi:"Finnish",fil:"Filipino",fit:"Tornedalen Finnish",fj:"Fijian",fo:"Faroese",fon:"Fon",fr:"French","fr-CA":"French (Canada)","fr-CH":"French (Switzerland)",frc:"Cajun French",frm:"Middle French",fro:"Old French",frp:"Arpitan",frr:"Northern Frisian",frs:"Eastern Frisian",fur:"Friulian",fy:"Western Frisian",ga:"Irish",gaa:"Ga",gag:"Gagauz",gan:"Gan Chinese",gay:"Gayo",gba:"Gbaya",gbz:"Zoroastrian Dari",gd:"Scottish Gaelic",gez:"Geez",gil:"Gilbertese",gl:"Galician",glk:"Gilaki",gmh:"Middle High German",gn:"Guarani",goh:"Old High German",gon:"Gondi",gor:"Gorontalo",got:"Gothic",grb:"Grebo",grc:"Ancient Greek",gsw:"Swiss German",gu:"Gujarati",guc:"Wayuu",gur:"Frafra",guz:"Gusii",gv:"Manx",gwi:"Gwichʼin",ha:"Hausa",hai:"Haida",hak:"Hakka Chinese",haw:"Hawaiian",hax:"Southern Haida",hdn:"Northern Haida",he:"Hebrew",hi:"Hindi","hi-Latn":"Hindi (Latin)",hif:"Fiji Hindi",hil:"Hiligaynon",hit:"Hittite",hmn:"Hmong",hnj:"Hmong Njua",ho:"Hiri Motu",hr:"Croatian",hsb:"Upper Sorbian",hsn:"Xiang Chinese",ht:"Haitian Creole",hu:"Hungarian",hup:"Hupa",hur:"Halkomelem",hy:"Armenian",hz:"Herero",ia:"Interlingua",iba:"Iban",ibb:"Ibibio",id:"Indonesian",ie:"Interlingue",ig:"Igbo",ii:"Sichuan Yi",ik:"Inupiaq",ike:"Eastern Canadian Inuktitut",ikt:"Western Canadian Inuktitut",ilo:"Iloko",inh:"Ingush",io:"Ido",is:"Icelandic",it:"Italian",iu:"Inuktitut",izh:"Ingrian",ja:"Japanese",jam:"Jamaican Creole English",jbo:"Lojban",jgo:"Ngomba",jmc:"Machame",jpr:"Judeo-Persian",jrb:"Judeo-Arabic",jut:"Jutish",jv:"Javanese",ka:"Georgian",kaa:"Kara-Kalpak",kab:"Kabyle",kac:"Kachin",kaj:"Jju",kam:"Kamba",kaw:"Kawi",kbd:"Kabardian",kbl:"Kanembu",kcg:"Tyap",kde:"Makonde",kea:"Kabuverdianu",ken:"Kenyang",kfo:"Koro",kg:"Kongo",kgp:"Kaingang",kha:"Khasi",kho:"Khotanese",khq:"Koyra Chiini",khw:"Khowar",ki:"Kikuyu",kiu:"Kirmanjki",kj:"Kuanyama",kk:"Kazakh",kkj:"Kako",kl:"Kalaallisut",kln:"Kalenjin",km:"Khmer",kmb:"Kimbundu",kn:"Kannada",ko:"Korean",koi:"Komi-Permyak",kok:"Konkani",kos:"Kosraean",kpe:"Kpelle",kr:"Kanuri",krc:"Karachay-Balkar",kri:"Krio",krj:"Kinaray-a",krl:"Karelian",kru:"Kurukh",ks:"Kashmiri",ksb:"Shambala",ksf:"Bafia",ksh:"Colognian",ku:"Kurdish",kum:"Kumyk",kut:"Kutenai",kv:"Komi",kw:"Cornish",kwk:"Kwakʼwala",kxv:"Kuvi",ky:"Kyrgyz",la:"Latin",lad:"Ladino",lag:"Langi",lah:"Western Panjabi",lam:"Lamba",lb:"Luxembourgish",lez:"Lezghian",lfn:"Lingua Franca Nova",lg:"Ganda",li:"Limburgish",lij:"Ligurian",lil:"Lillooet",liv:"Livonian",lkt:"Lakota",lmo:"Lombard",ln:"Lingala",lo:"Lao",lol:"Mongo",lou:"Louisiana Creole",loz:"Lozi",lrc:"Northern Luri",lsm:"Saamia",lt:"Lithuanian",ltg:"Latgalian",lu:"Luba-Katanga",lua:"Luba-Lulua",lui:"Luiseno",lun:"Lunda",luo:"Luo",lus:"Mizo",luy:"Luyia",lv:"Latvian",lzh:"Literary Chinese",lzz:"Laz",mad:"Madurese",maf:"Mafa",mag:"Magahi",mai:"Maithili",mak:"Makasar",man:"Mandingo",mas:"Masai",mde:"Maba",mdf:"Moksha",mdr:"Mandar",men:"Mende",mer:"Meru",mfe:"Morisyen",mg:"Malagasy",mga:"Middle Irish",mgh:"Makhuwa-Meetto",mgo:"Metaʼ",mh:"Marshallese",mi:"Māori",mic:"Mi'kmaw",min:"Minangkabau",mk:"Macedonian",ml:"Malayalam",mn:"Mongolian",mnc:"Manchu",mni:"Manipuri",moe:"Innu-aimun",moh:"Mohawk",mos:"Mossi",mr:"Marathi",mrj:"Western Mari",ms:"Malay",mt:"Maltese",mua:"Mundang",mul:"Multiple languages",mus:"Muscogee",mwl:"Mirandese",mwr:"Marwari",mwv:"Mentawai",my:"Burmese",mye:"Myene",myv:"Erzya",mzn:"Mazanderani",na:"Nauru",nan:"Min Nan Chinese",nap:"Neapolitan",naq:"Nama",nb:"Norwegian Bokmål",nd:"North Ndebele",nds:"Low German","nds-NL":"Low German (Netherlands)",ne:"Nepali",new:"Newari",ng:"Ndonga",nia:"Nias",niu:"Niuean",njo:"Ao Naga",nl:"Dutch","nl-BE":"Dutch (Belgium)",nmg:"Kwasio",nn:"Norwegian Nynorsk",nnh:"Ngiemboon",no:"Norwegian",nog:"Nogai",non:"Old Norse",nov:"Novial",nqo:"N’Ko",nr:"South Ndebele",nso:"Northern Sotho",nus:"Nuer",nv:"Navajo",nwc:"Classical Newari",ny:"Nyanja",nym:"Nyamwezi",nyn:"Nyankole",nyo:"Nyoro",nzi:"Nzima",oc:"Occitan",oj:"Ojibwa",ojb:"Northwestern Ojibwa",ojc:"Central Ojibwa",ojg:"Eastern Ojibwa",ojs:"Oji-Cree",ojw:"Western Ojibwa",oka:"Okanagan",om:"Oromo",or:"Odia",os:"Ossetic",osa:"Osage",ota:"Ottoman Turkish",pa:"Punjabi",pag:"Pangasinan",pal:"Pahlavi",pam:"Pampanga",pap:"Papiamento",pau:"Palauan",pcd:"Picard",pcm:"Nigerian Pidgin",pdc:"Pennsylvania German",pdt:"Plautdietsch",peo:"Old Persian",pfl:"Palatine German",phn:"Phoenician",pi:"Pali",pis:"Pijin",pl:"Polish",pms:"Piedmontese",pnt:"Pontic",pon:"Pohnpeian",pqm:"Maliseet-Passamaquoddy",prg:"Prussian",pro:"Old Provençal",ps:"Pashto",pt:"Portuguese","pt-BR":"Portuguese (Brazil)","pt-PT":"Portuguese (Portugal)",qu:"Quechua",quc:"Kʼicheʼ",qug:"Chimborazo Highland Quichua",raj:"Rajasthani",rap:"Rapanui",rar:"Rarotongan",rgn:"Romagnol",rhg:"Rohingya",rif:"Riffian",rm:"Romansh",rn:"Rundi",ro:"Romanian","ro-MD":"Romanian (Moldova)",rof:"Rombo",rom:"Romany",rtm:"Rotuman",ru:"Russian",rue:"Rusyn",rug:"Roviana",rup:"Aromanian",rw:"Kinyarwanda",rwk:"Rwa",sa:"Sanskrit",sad:"Sandawe",sah:"Yakut",sam:"Samaritan Aramaic",saq:"Samburu",sas:"Sasak",sat:"Santali",saz:"Saurashtra",sba:"Ngambay",sbp:"Sangu",sc:"Sardinian",scn:"Sicilian",sco:"Scots",sd:"Sindhi",sdc:"Sassarese Sardinian",sdh:"Southern Kurdish",se:"Northern Sami",see:"Seneca",seh:"Sena",sei:"Seri",sel:"Selkup",ses:"Koyraboro Senni",sg:"Sango",sga:"Old Irish",sgs:"Samogitian",sh:"Serbo-Croatian",shi:"Tachelhit",shn:"Shan",shu:"Chadian Arabic",si:"Sinhala",sid:"Sidamo",sk:"Slovak",sl:"Slovenian",slh:"Southern Lushootseed",sli:"Lower Silesian",sly:"Selayar",sm:"Samoan",sma:"Southern Sami",smj:"Lule Sami",smn:"Inari Sami",sms:"Skolt Sami",sn:"Shona",snk:"Soninke",so:"Somali",sog:"Sogdien",sq:"Albanian",sr:"Serbian","sr-ME":"Serbian (Montenegro)",srn:"Sranan Tongo",srr:"Serer",ss:"Swati",ssy:"Saho",st:"Southern Sotho",stq:"Saterland Frisian",str:"Straits Salish",su:"Sundanese",suk:"Sukuma",sus:"Susu",sux:"Sumerian",sv:"Swedish",sw:"Swahili","sw-CD":"Swahili (Congo - Kinshasa)",swb:"Comorian",syc:"Classical Syriac",syr:"Syriac",szl:"Silesian",ta:"Tamil",tce:"Southern Tutchone",tcy:"Tulu",te:"Telugu",tem:"Timne",teo:"Teso",ter:"Tereno",tet:"Tetum",tg:"Tajik",tgx:"Tagish",th:"Thai",tht:"Tahltan",ti:"Tigrinya",tig:"Tigre",tiv:"Tiv",tk:"Turkmen",tkl:"Tokelau",tkr:"Tsakhur",tl:"Tagalog",tlh:"Klingon",tli:"Tlingit",tly:"Talysh",tmh:"Tamashek",tn:"Tswana",to:"Tongan",tog:"Nyasa Tonga",tok:"Toki Pona",tpi:"Tok Pisin",tr:"Turkish",tru:"Turoyo",trv:"Taroko",trw:"Torwali",ts:"Tsonga",tsd:"Tsakonian",tsi:"Tsimshian",tt:"Tatar",ttm:"Northern Tutchone",ttt:"Muslim Tat",tum:"Tumbuka",tvl:"Tuvalu",tw:"Twi",twq:"Tasawaq",ty:"Tahitian",tyv:"Tuvinian",tzm:"Central Atlas Tamazight",udm:"Udmurt",ug:"Uyghur",uga:"Ugaritic",uk:"Ukrainian",umb:"Umbundu",und:"Unknown language",ur:"Urdu",uz:"Uzbek",vai:"Vai",ve:"Venda",vec:"Venetian",vep:"Veps",vi:"Vietnamese",vls:"West Flemish",vmf:"Main-Franconian",vmw:"Makhuwa",vo:"Volapük",vot:"Votic",vro:"Võro",vun:"Vunjo",wa:"Walloon",wae:"Walser",wal:"Wolaytta",war:"Waray",was:"Washo",wbp:"Warlpiri",wo:"Wolof",wuu:"Wu Chinese",xal:"Kalmyk",xh:"Xhosa",xmf:"Mingrelian",xnr:"Kangri",xog:"Soga",yao:"Yao",yap:"Yapese",yav:"Yangben",ybb:"Yemba",yi:"Yiddish",yo:"Yoruba",yrl:"Nheengatu",yue:"Cantonese",za:"Zhuang",zap:"Zapotec",zbl:"Blissymbols",zea:"Zeelandic",zen:"Zenaga",zgh:"Standard Moroccan Tamazight",zh:"Chinese","zh-Hans":"Simplified Chinese","zh-Hant":"Traditional Chinese",zu:"Zulu",zun:"Zuni",zxx:"No linguistic content",zza:"Zaza"}}},region:{long:m(m(m(m(m(m(m(m({"001":"world","002":"Africa","003":"North America","005":"South America","009":"Oceania","011":"Western Africa","013":"Central America","014":"Eastern Africa","015":"Northern Africa","017":"Middle Africa","018":"Southern Africa","019":"Americas","021":"Northern America","029":"Caribbean","030":"Eastern Asia","034":"Southern Asia","035":"Southeast Asia","039":"Southern Europe","053":"Australasia","054":"Melanesia","057":"Micronesian Region","061":"Polynesia",142:"Asia",143:"Central Asia",145:"Western Asia",150:"Europe",151:"Eastern Europe",154:"Northern Europe",155:"Western Europe",202:"Sub-Saharan Africa",419:"Latin America",AC:"Ascension Island",AD:"Andorra",AE:"United Arab Emirates",AF:"Afghanistan",AG:"Antigua & Barbuda",AI:"Anguilla",AL:"Albania",AM:"Armenia",AO:"Angola",AQ:"Antarctica",AR:"Argentina",AS:"American Samoa",AT:"Austria",AU:"Australia",AW:"Aruba",AX:"Åland Islands",AZ:"Azerbaijan",BA:"Bosnia & Herzegovina",BB:"Barbados",BD:"Bangladesh",BE:"Belgium",BF:"Burkina Faso",BG:"Bulgaria",BH:"Bahrain",BI:"Burundi",BJ:"Benin",BL:"St. Barthélemy",BM:"Bermuda",BN:"Brunei",BO:"Bolivia",BQ:"Caribbean Netherlands",BR:"Brazil",BS:"Bahamas",BT:"Bhutan",BV:"Bouvet Island",BW:"Botswana",BY:"Belarus",BZ:"Belize",CA:"Canada",CC:"Cocos (Keeling) Islands",CD:"Congo - Kinshasa",CF:"Central African Republic",CG:"Congo - Brazzaville",CH:"Switzerland",CI:"Côte d’Ivoire",CK:"Cook Islands",CL:"Chile",CM:"Cameroon",CN:"China",CO:"Colombia",CP:"Clipperton Island",CQ:"Sark",CR:"Costa Rica",CU:"Cuba",CV:"Cape Verde",CW:"Curaçao",CX:"Christmas Island",CY:"Cyprus",CZ:"Czechia",DE:"Germany",DG:"Diego Garcia",DJ:"Djibouti",DK:"Denmark",DM:"Dominica",DO:"Dominican Republic",DZ:"Algeria",EA:"Ceuta & Melilla",EC:"Ecuador",EE:"Estonia",EG:"Egypt",EH:"Western Sahara",ER:"Eritrea",ES:"Spain",ET:"Ethiopia",EU:"European Union",EZ:"Eurozone",FI:"Finland",FJ:"Fiji",FK:"Falkland Islands",FM:"Micronesia",FO:"Faroe Islands",FR:"France",GA:"Gabon",GB:"United Kingdom",GD:"Grenada",GE:"Georgia",GF:"French Guiana",GG:"Guernsey",GH:"Ghana",GI:"Gibraltar",GL:"Greenland",GM:"Gambia",GN:"Guinea",GP:"Guadeloupe",GQ:"Equatorial Guinea",GR:"Greece",GS:"South Georgia & South Sandwich Islands",GT:"Guatemala",GU:"Guam",GW:"Guinea-Bissau",GY:"Guyana",HK:"Hong Kong SAR China",HM:"Heard & McDonald Islands",HN:"Honduras",HR:"Croatia",HT:"Haiti",HU:"Hungary",IC:"Canary Islands",ID:"Indonesia",IE:"Ireland",IL:"Israel",IM:"Isle of Man",IN:"India",IO:"British Indian Ocean Territory",IQ:"Iraq",IR:"Iran",IS:"Iceland",IT:"Italy",JE:"Jersey",JM:"Jamaica",JO:"Jordan",JP:"Japan",KE:"Kenya",KG:"Kyrgyzstan",KH:"Cambodia",KI:"Kiribati",KM:"Comoros",KN:"St. Kitts & Nevis",KP:"North Korea",KR:"South Korea",KW:"Kuwait",KY:"Cayman Islands",KZ:"Kazakhstan",LA:"Laos",LB:"Lebanon",LC:"St. Lucia",LI:"Liechtenstein",LK:"Sri Lanka",LR:"Liberia",LS:"Lesotho",LT:"Lithuania",LU:"Luxembourg",LV:"Latvia",LY:"Libya",MA:"Morocco",MC:"Monaco",MD:"Moldova",ME:"Montenegro",MF:"St. Martin",MG:"Madagascar",MH:"Marshall Islands",MK:"North Macedonia",ML:"Mali",MM:"Myanmar (Burma)",MN:"Mongolia",MO:"Macao SAR China",MP:"Northern Mariana Islands",MQ:"Martinique",MR:"Mauritania",MS:"Montserrat",MT:"Malta",MU:"Mauritius",MV:"Maldives",MW:"Malawi",MX:"Mexico",MY:"Malaysia",MZ:"Mozambique",NA:"Namibia",NC:"New Caledonia",NE:"Niger",NF:"Norfolk Island",NG:"Nigeria",NI:"Nicaragua",NL:"Netherlands",NO:"Norway",NP:"Nepal",NR:"Nauru",NU:"Niue",NZ:"New Zealand",OM:"Oman",PA:"Panama",PE:"Peru",PF:"French Polynesia",PG:"Papua New Guinea",PH:"Philippines",PK:"Pakistan",PL:"Poland",PM:"St. Pierre & Miquelon",PN:"Pitcairn Islands",PR:"Puerto Rico",PS:"Palestinian Territories",PT:"Portugal",PW:"Palau",PY:"Paraguay",QA:"Qatar",QO:"Outlying Oceania",RE:"Réunion",RO:"Romania",RS:"Serbia",RU:"Russia",RW:"Rwanda",SA:"Saudi Arabia",SB:"Solomon Islands",SC:"Seychelles",SD:"Sudan",SE:"Sweden",SG:"Singapore",SH:"St. Helena",SI:"Slovenia",SJ:"Svalbard & Jan Mayen",SK:"Slovakia",SL:"Sierra Leone",SM:"San Marino",SN:"Senegal",SO:"Somalia",SR:"Suriname",SS:"South Sudan",ST:"São Tomé & Príncipe",SV:"El Salvador",SX:"Sint Maarten",SY:"Syria",SZ:"Eswatini",TA:"Tristan da Cunha",TC:"Turks & Caicos Islands",TD:"Chad",TF:"French Southern Territories",TG:"Togo",TH:"Thailand",TJ:"Tajikistan",TK:"Tokelau",TL:"Timor-Leste",TM:"Turkmenistan",TN:"Tunisia",TO:"Tonga",TR:"Türkiye",TT:"Trinidad & Tobago",TV:"Tuvalu",TW:"Taiwan",TZ:"Tanzania",UA:"Ukraine",UG:"Uganda",UM:"U.S. Outlying Islands",UN:"United Nations",US:"United States",UY:"Uruguay",UZ:"Uzbekistan",VA:"Vatican City",VC:"St. Vincent & Grenadines",VE:"Venezuela",VG:"British Virgin Islands",VI:"U.S. Virgin Islands",VN:"Vietnam",VU:"Vanuatu",WF:"Wallis & Futuna",WS:"Samoa",XA:"Pseudo-Accents",XB:"Pseudo-Bidi",XK:"Kosovo",YE:"Yemen",YT:"Mayotte",ZA:"South Africa",ZM:"Zambia",ZW:"Zimbabwe",ZZ:"Unknown Region"},"BA","Bosnia"),"GB","UK"),"HK","Hong Kong"),"MM","Myanmar"),"MO","Macao"),"PS","Palestine"),"UN","UN"),"US","US")}},Zo=["af","sq","am","ar","hy","as","az","eu","be","bn","bs","bg","my","ca","zh-CN","zh-TW","zh-HK","hr","cs","da","nl","en","et","fil","fi","fr","gl","ka","de","el","gu","he","hi","hu","is","id","ga","it","ja","kn","kk","km","ko","ky","lo","lv","lt","mk","ms","ml","mt","mr","mn","ne","no","or","fa","pl","pt","pa","ro","ru","sr","si","sk","sl","es","sw","sv","ta","te","th","tr","uk","ur","uz","vi","cy","yi","yo","zu"];var $o=!1;function es(e,t){return{compactLinkRenderer:{title:{simpleText:t},serviceEndpoint:{commandExecutorCommand:{commands:[{selectSubtitlesTrackCommand:{translationLanguage:{languageCode:e,languageName:t}}},{openClientOverlayAction:{type:"CLIENT_OVERLAY_TYPE_CAPTIONS_LANGUAGE",updateAction:!0}},{signalAction:{signal:"POPUP_BACK"}}]}},secondaryIcon:{iconType:"RADIO_BUTTON_UNCHECKED"}}}}function ts(){if($o)return!0;if(!document.querySelector(".html5-video-player")||!window._yttv)return!1;var e=Object.values(window._yttv).find(function(e){return e&&e.instance&&"function"==typeof e.instance.resolveCommand});if(!e)return!1;if(e.instance.resolveCommand.isPatchedBySubtitleLocalization)return $o=!0,!0;var t=e.instance.resolveCommand;return e.instance.resolveCommand=function(e,n){var i;if("CLIENT_OVERLAY_TYPE_CAPTIONS_AUTO_TRANSLATE"===(null==e||null===(i=e.openPopupAction)||void 0===i?void 0:i.uniqueId)){var r,a=Se("enableShowUserLanguage"),o=Se("enableShowOtherLanguages");if(!a&&!o)return t.apply(this,arguments);var s=null===(r=e.openPopupAction)||void 0===r||null===(r=r.popup)||void 0===r||null===(r=r.overlaySectionRenderer)||void 0===r||null===(r=r.overlay)||void 0===r||null===(r=r.overlayTwoPanelRenderer)||void 0===r||null===(r=r.actionPanel)||void 0===r||null===(r=r.overlayPanelRenderer)||void 0===r||null===(r=r.content)||void 0===r||null===(r=r.overlayPanelItemListRenderer)||void 0===r?void 0:r.items;if(!Array.isArray(s))return t.apply(this,arguments);var u=function(e){var t=new Set;return e.forEach(function(e){var n,i,r=null===(n=e.compactLinkRenderer)||void 0===n||null===(n=n.serviceEndpoint)||void 0===n||null===(n=n.commandExecutorCommand)||void 0===n?void 0:n.commands,a=null==r||null===(i=r[0])||void 0===i||null===(i=i.selectSubtitlesTrackCommand)||void 0===i?void 0:i.translationLanguage;a&&(t.add(a.languageCode),t.add(a.languageName))}),t}(s);if(a){var l=function(e){if(!e)return null;try{var t=String(e).toUpperCase(),n={CN:"zh-CN",TW:"zh-TW",HK:"zh-HK",SG:"zh-CN"};if(n[t]){var i=n[t];return{code:i,name:Qo.language.standard.long[i]||i}}var r=new Intl.Locale("und",{region:t}),a=(r.maximize?r.maximize():r).language||"en";return{code:a,name:Qo.language.standard.long[a]||a}}catch(t){return console.warn("[AxoTube:moreSubtitles] Could not infer language for country",e,t),null}}(function(){try{return window.yt&&window.yt.config_&&window.yt.config_.GL?window.yt.config_.GL:(console.warn("[AxoTube:moreSubtitles] Could not determine user country code"),null)}catch(e){return console.error("[AxoTube:moreSubtitles] Error getting country code:",e),null}}());if(l&&!function(e,t,n){return e.some(function(e){var i,r,a=null===(i=e.compactLinkRenderer)||void 0===i||null===(i=i.serviceEndpoint)||void 0===i||null===(i=i.commandExecutorCommand)||void 0===i?void 0:i.commands,o=null==a||null===(r=a[0])||void 0===r||null===(r=r.selectSubtitlesTrackCommand)||void 0===r?void 0:r.translationLanguage;return!(!o||o.languageCode!==t&&o.languageName!==n)})}(s,l.code,l.name)){var c=es(l.code,l.name),h=s.findIndex(function(e){var t;return"Recommended languages"===(null===(t=e.overlayMessageRenderer)||void 0===t||null===(t=t.subtitle)||void 0===t?void 0:t.simpleText)});if(h>-1)s.splice(h+1,0,c);else{var d=s.findIndex(function(e){var t;return"Other languages"===(null===(t=e.overlayMessageRenderer)||void 0===t||null===(t=t.subtitle)||void 0===t?void 0:t.simpleText)});d>-1?s.splice(d,0,c):s.unshift(c)}u.add(l.code),u.add(l.name)}}if(o){var p=Object.entries(function(){try{var e={};return Zo.forEach(function(t){if(t.includes("-")){var n=D(t.split("-"),2),i=n[0],r=n[1],a=Qo.language.standard.long[i]||t,o=Qo.region.long[r]||r;e[t]="".concat(a," (").concat(o,")")}else e[t]=Qo.language.standard.long[t]||t}),e}catch(e){var t={};return Zo.forEach(function(e){return t[e]=e}),t}}()).filter(function(e){var t=D(e,2),n=t[0],i=t[1];return!u.has(n)&&!u.has(i)}).sort(function(e,t){var n=D(e,2)[1],i=D(t,2)[1];return n.localeCompare(i)});p.length>0&&(s.push({overlayMessageRenderer:{title:{simpleText:""},subtitle:{simpleText:"Other Languages"},style:"OVERLAY_MESSAGE_STYLE_SUBSECTION_TITLE"}}),p.forEach(function(e){var t=D(e,2),n=t[0],i=t[1];return s.push(es(n,i))}))}}return t.apply(this,arguments)},e.instance.resolveCommand.isPatchedBySubtitleLocalization=!0,$o=!0,!0}var ns=0;function is(){$o||(ns+=1,ts()||(ns>=30?console.warn("[AxoTube:moreSubtitles] resolveCommand did not become ready in time."):setTimeout(is,500)))}"loading"===document.readyState?document.addEventListener("DOMContentLoaded",is):is();var rs=!1,as=null;function os(){var e=document.querySelector("video");return e&&isFinite(e.currentTime)?Math.max(0,Math.floor(e.currentTime)):0}function ss(){var e,t;rs||(rs=!0,an(Nt("app.name"),Nt("playback.retryPrompt",{time:(e=os(),t=e%60,Math.floor(e/60)+":"+(t<10?"0"+t:String(t)))}),null))}function us(){var e;as=null,(e=document.querySelector(".ytp-error"))&&e.offsetWidth>0&&e.offsetHeight>0?ss():rs=!1}function ls(){null===as&&(as=setTimeout(us,500))}document.addEventListener("error",function(e){e.target&&"VIDEO"===e.target.tagName&&ss()},!0),window.addEventListener("keydown",function(e){406===e.keyCode&&rs&&(e.stopPropagation(),function(){rs=!1;var e=function(e,t){var n=e.indexOf("?");if(-1===n||!/\/watch$/.test(e.slice(0,n)))return null;var i=e.slice(n+1).split("&").filter(function(e){return e&&"t"!==e.split("=")[0]});return i.push("t="+t),e.slice(0,n+1)+i.join("&")}(location.hash,os());e&&(location.hash=e),window.location.reload()}())},!0),function e(){document.body?new MutationObserver(ls).observe(document.body,{childList:!0,subtree:!0}):setTimeout(e,200)}();var cs;cs||(cs=1,window.addEventListener("keydown",function(e){if(403===e.keyCode){var t=window.__axotubeProxyUrl?window.__axotubeProxyUrl:"8081"===location.port?location.protocol+"//"+location.hostname+":8081":null;t&&(e.stopPropagation(),location.href=t+"/axotube/diagnostics")}},!0));var hs="onStateChange",ds="configChange",ps="preferredVideoQuality",fs=new WeakMap,ms=new WeakMap,gs=new WeakMap,vs=new WeakMap,ys=new WeakMap,bs=new WeakSet,xs=new WeakMap,Ss=p(function e(){var t,n,i=this;u(this,e),s(t=this,n=bs),n.add(t),c(this,fs,null),c(this,ms,null),c(this,gs,0),c(this,vs,null),c(this,ys,!1),c(this,xs,function(){try{var e,t,n,r,o,s,u=null===(e=l(fs,i))||void 0===e||null===(t=e.getPlayerStateObject)||void 0===t?void 0:t.call(e),c=null===(n=l(fs,i))||void 0===n||null===(r=n.getVideoData)||void 0===r?void 0:r.call(n),d=null==c?void 0:c.video_id;d!==l(vs,i)&&(h(vs,i,d),a(bs,i,ws).call(i));var p=Object.values((null===(o=l(fs,i))||void 0===o||null===(s=o.getVideoStats)||void 0===s?void 0:s.call(o))||{}).find(function(e){return e&&"shortspage"===e});null==u||!u.isPlaying||l(ys,i)||p||(h(ys,i,a(bs,i,Cs).call(i)),l(ys,i)||a(bs,i,As).call(i))}catch(e){console.warn("[AxoTube:preferredVideoQuality] State change handler failed:",e)}}),a(bs,this,Ds).call(this),_i(function(e){return a(bs,i,ks).call(i,e)}),ji(function(e){e!==l(vs,i)&&(h(vs,i,e),a(bs,i,ws).call(i),l(xs,i).call(i))})});function Es(){l(ms,this)&&(clearTimeout(l(ms,this)),h(ms,this,null))}function ws(){a(bs,this,Es).call(this),h(gs,this,0),h(ys,this,!1)}function ks(e){if(!e){if(l(fs,this))try{l(fs,this).removeEventListener(hs,l(xs,this))}catch(e){}return h(fs,this,null),h(vs,this,null),void a(bs,this,ws).call(this)}if(e!==l(fs,this)){if(l(fs,this))try{l(fs,this).removeEventListener(hs,l(xs,this))}catch(e){}h(fs,this,e),h(vs,this,null),a(bs,this,ws).call(this);try{l(fs,this).addEventListener(hs,l(xs,this))}catch(e){console.warn("[AxoTube:preferredVideoQuality] Could not attach state change listener:",e)}l(xs,this).call(this)}}function Ds(){var e=this;we.addEventListener(ds,function(t){var n;(null===(n=t.detail)||void 0===n?void 0:n.key)===ps&&(a(bs,e,ws).call(e),h(ys,e,a(bs,e,Cs).call(e)),l(ys,e)||a(bs,e,As).call(e))})}function As(){var e=this;l(ms,this)||l(ys,this)||l(gs,this)>=10||(h(gs,this,l(gs,this)+1),h(ms,this,setTimeout(function(){h(ms,e,null);try{var t,n,i=null===(t=l(fs,e))||void 0===t||null===(n=t.getPlayerStateObject)||void 0===n?void 0:n.call(t);if(null==i||!i.isPlaying||l(fs,e)!==Ii())return;h(ys,e,a(bs,e,Cs).call(e)),l(ys,e)||a(bs,e,As).call(e)}catch(e){console.warn("[AxoTube:preferredVideoQuality] Retry failed:",e)}},500)))}function Cs(){if(!l(fs,this)||"function"!=typeof l(fs,this).setPlaybackQualityRange)return!1;var e=Se(ps);try{if(!e||"auto"===e)return l(fs,this).setPlaybackQualityRange("auto","auto"),!0;var t=a(bs,this,Ts).call(this,e);return!!t&&(l(fs,this).setPlaybackQualityRange(t,t),!0)}catch(e){return console.warn("[AxoTube:preferredVideoQuality] Failed to apply quality:",e),!1}}function Ts(e){try{var t,n,i,r=null===(t=(n=l(fs,this)).getAvailableQualityData)||void 0===t?void 0:t.call(n);if(!Array.isArray(r)||0===r.length)return null;var a=function(e){return parseInt(e,10)||0},o=a(e),s=r.find(function(e){return a(e.qualityLabel)===o});return s?s.quality:(null===(i=r.slice().sort(function(e,t){var n=a(e.qualityLabel),i=a(t.qualityLabel),r=n>o?1:0,s=i>o?1:0;return r!==s?r-s:Math.abs(n-o)-Math.abs(i-o)})[0])||void 0===i?void 0:i.quality)||null}catch(e){return console.warn("[AxoTube:preferredVideoQuality] Quality determination failed:",e),null}}try{window.preferredVideoQualityHandler=new Ss}catch(e){console.error("[AxoTube:preferredVideoQuality] PreferredQualityHandler initialization failed:",e)}function Ps(e){return e&&e.tileRenderer&&e.tileRenderer.contentId}function Fs(e){var t=window.queuedVideos.videos[e],n=t&&t.tileRenderer&&t.tileRenderer.onSelectCommand;return!!n&&(window.queuedVideos.currentIndex=e,window.queuedVideos.lastVideoId=Ps(t)||null,setTimeout(function(){return Bo(n)},500),!0)}function Bs(){window.queuedVideos.currentIndex=-1,window.queuedVideos.lastVideoId=null,Bo({customAction:{action:"CLEAR_QUEUE"}})}window.queuedVideos={videos:[],lastVideoId:null,currentIndex:-1};var Is=null;_i(function(e){if(Is&&(Is.player.removeEventListener("onStateChange",Is.listener),Is=null),e&&"function"==typeof e.addEventListener){var t=function(){return function(e){var t=e.getPlayerStateObject(),n=e.getVideoData(),i=window.queuedVideos;if(0===i.videos.length)return i.currentIndex=-1,void(i.lastVideoId=null);if(t.isEnded){var r=i.currentIndex;if((r<0||r>=i.videos.length)&&(r=i.videos.findIndex(function(e){return Ps(e)===n.video_id})),-1!==r){var a=r+1;if(a<i.videos.length&&Fs(a))return;return void Bs()}if(i.currentIndex+1<i.videos.length&&Fs(i.currentIndex+1))return;if(Fs(0))return;Bs()}else if(t.isPlaying){var o=document.getElementById("container");if(o&&o.style.setProperty("opacity","1","important"),Ps(i.videos[i.currentIndex])===n.video_id)return void(i.lastVideoId=n.video_id);var s=i.videos.findIndex(function(e){return Ps(e)===n.video_id});-1!==s&&(i.currentIndex=s,i.lastVideoId=n.video_id)}}(e)};e.addEventListener("onStateChange",t),Is={player:e,listener:t}}});var Ls=null,Os=0;function Ns(){Os>=20||(Os+=1,Ls=setTimeout(function(){return Rs(!1)},500))}function Rs(){if(arguments.length>0&&void 0!==arguments[0]&&arguments[0]&&(Os=0),Ls&&(clearTimeout(Ls),Ls=null),window._yttv){var e=null;try{e=Object.values(window._yttv).find(function(e){return e instanceof Map&&e.has("ENABLE_PREVIEWS_WITH_SOUND")})}catch(t){e=null}e?(Os=0,e.set("ENABLE_PREVIEWS_WITH_SOUND",Ie())):Ns()}else Ns()}we.addEventListener("configChange",function(){Rs(!0)}),"complete"===document.readyState?Rs(!0):window.addEventListener("load",function(){return Rs(!0)});var Ms="http://127.0.0.1:8090",_s=-1,Us=!1,js=!1,Hs=!1,zs=null,Vs=new Set,Ks=!1,Gs="",Js=null,Xs=!1,Ws=!1,qs=null,Ys=!1;function Qs(){return"undefined"!=typeof window&&("string"==typeof window.__axotubeServiceUrl||!!se()||void 0!==window.tizen)}var Zs=qt,$s=Zt;function eu(){return Jn("".concat(Ms,"/api/pairing-code")).then(function(e){if(!e.ok)throw new Error("pairing code HTTP ".concat(e.status));return e.json()}).then(function(e){return ia(e),e}).catch(function(){return ia(null),null})}function tu(){!Ws&&Zs()&&eu().then(function(e){if(e&&e.code&&!Ws){Ws=!0;try{var t=Array.isArray(e.urls)&&e.urls.length?e.urls[0]:null;an(Nt("app.name"),t?Nt("toasts.pairingWithUrl",{url:t,code:e.code}):Nt("toasts.pairingCodeOnly",{code:e.code}))}catch(e){}}})}function nu(e,t){if(e===t)return!0;try{return me(e)===me(t)}catch(e){return!1}}function iu(e){if(!zs)return!1;var t=Object.keys(e),n=Object.keys(zs);return t.length!==n.length||t.some(function(t){return!Object.prototype.hasOwnProperty.call(zs,t)||!nu(e[t],zs[t])})}function ru(){if(!(!Qs()||Us||_s<0)&&zs){var e=ke();iu(e)?(Us=!0,Jn("".concat(Ms,"/api/config/push"),{method:"POST",headers:{"Content-Type":"application/json"},body:me({revision:_s,config:e})}).then(function(e){if(409===e.status)return{conflict:!0};if(!e.ok)throw new Error("config push HTTP ".concat(e.status));return e.json()}).then(function(t){if(null!=t&&t.conflict)return"conflict";if(!t||!t.applied||!Number.isSafeInteger(t.revision))throw new Error("Config push was not acknowledged");_s=t.revision,zs=e;var n,i=ke(),r=f(Vs);try{for(r.s();!(n=r.n()).done;){var a=n.value;nu(i[a],e[a])&&Vs.delete(a)}}catch(e){r.e(e)}finally{r.f()}return"accepted"}).catch(function(){return"failed"}).then(function(e){Us=!1,"conflict"===e?ou():"accepted"===e&&iu(ke())&&au()})):Vs.clear()}}function au(){Qs()&&(clearTimeout(Js),Js=setTimeout(ru,250))}function ou(){Qs()&&!Us&&(Us=!0,Jn("".concat(Ms,"/api/config")).then(function(e){if(!e.ok)throw new Error("config pull HTTP ".concat(e.status));return e.json()}).then(function(e){if(e&&Number.isSafeInteger(e.revision)&&!(e.revision<0)&&e.config&&"object"===T(e.config)&&!Array.isArray(e.config)){!function(){if(!Xs&&Qs()&&Zs())try{an(Nt("app.name"),Nt("toasts.serviceConnected")),Xs=!0,setTimeout(tu,1200)}catch(e){}}(),lu=0;var t=e.config;Ks=!0;var n=!0;try{Object.keys(t).forEach(function(e){if(!Vs.has(e)&&void 0!==t[e])try{nu(Se(e),t[e])||Ee(e,t[e])||(n=!1)}catch(e){n=!1}})}finally{Ks=!1}var i=ke();Object.keys(i).forEach(function(e){Object.prototype.hasOwnProperty.call(t,e)?nu(i[e],t[e])&&Vs.delete(e):Vs.add(e)}),zs=t,n&&(_s=e.revision)}}).catch(function(){lu+=1}).then(function(){Us=!1,ru()}))}function su(e){return function(e){return e?Jn("".concat(Ms,"/api/command/ack"),{method:"POST",headers:{"Content-Type":"application/json"},body:me({id:e})}).then(function(e){if(!e.ok)throw new Error("command ACK HTTP ".concat(e.status));return!0}).catch(function(){return!1}):Promise.resolve(!1)}(e).then(function(t){if(!t||qs!==e)return t;var n=Ys;if(qs=null,Ys=!1,n)try{window.location.reload()}catch(e){}return!0})}function uu(){Qs()&&!js&&(js=!0,Jn("".concat(Ms,"/api/command")).then(function(e){if(!e.ok)throw new Error("command poll HTTP ".concat(e.status));return e.json()}).then(function(e){if(e&&e.command&&e.id){var t=e.id;if(e.id===qs)return su(t);if("toast"===e.command.action){qs=t,Ys=!1;try{an(Nt("app.name"),String(e.command.text||"").slice(0,200))}catch(e){}return su(t)}if("reload"===e.command.action)return qs=t,Ys=!0,su(t);var n=function(e){if(!e||"object"!==T(e))return null;if("play"===e.action&&e.videoId){var t={videoId:e.videoId};return e.playlistId&&(t.playlistId=e.playlistId),{watchEndpoint:t}}return"search"===e.action&&e.query?{searchEndpoint:{query:e.query}}:"browse"===e.action&&e.browseId?{browseEndpoint:{browseId:e.browseId}}:null}(e.command);if(n)return $s(n).then(function(e){if(e){qs=t,Ys=!1;try{an(Nt("app.name"),Nt("toasts.commandReceived"))}catch(e){}return su(t)}})}}).catch(function(){}).then(function(){js=!1}))}we.addEventListener("configChange",function(e){var t;Ks||("string"==typeof(null==e||null===(t=e.detail)||void 0===t?void 0:t.key)&&Vs.add(e.detail.key),au())});var lu=0;setTimeout(function e(){ou(),uu(),function(){if(Qs()&&!Hs){var e=null;try{var t=document.querySelector("video");if(t&&t.currentSrc){var n,i=location.hash.match(/[?&]v=([^&]+)/);e={videoId:i?i[1]:null,title:(null===(n=document.querySelector("ytlr-player-header-title"))||void 0===n?void 0:n.textContent)||document.title,state:t.paused?"paused":"playing",progress:t.currentTime,duration:t.duration}}}catch(e){return}var r=e?me(e):"none";r!==Gs&&(Gs=r,Hs=!0,Jn("".concat(Ms,"/api/nowplaying"),{method:"POST",headers:{"Content-Type":"application/json"},body:"none"===r?"{}":r}).then(function(e){if(!e.ok)throw new Error("now playing HTTP ".concat(e.status))}).catch(function(){Gs=""}).then(function(){Hs=!1}))}}(),Qs()&&(na?Date.now()-na:1/0)>6e4&&eu(),setTimeout(e,function(){if(0===lu)return 5e3;var e=5e3*Math.pow(2,Math.min(lu,3));return Math.min(e,3e4)}())},3e3);try{Zt(function(e){if(!e||"object"!==T(e))return null;if(e.v){var t={videoId:e.v};return e.list&&(t.playlistId=e.list),{watchEndpoint:t}}if(e.list)return{playlistEndpoint:{playlistId:e.list}};var n=e.search_query||e.q;return n?{searchEndpoint:{query:n}}:e.browseId?{browseEndpoint:{browseId:e.browseId}}:null}(function(e){if(!e||e.length<=1)return{};for(var t={},n=e.substring(1).split("&"),i=0;i<n.length;i+=1){var r=n[i];if(r){var a=r.indexOf("=");if(-1!==a){var o=decodeURIComponent(r.substring(0,a).replace(/\+/g," ")),s=decodeURIComponent(r.substring(a+1).replace(/\+/g," "));t[o]=s}else t[decodeURIComponent(r.replace(/\+/g," "))]=""}}return t}(location.search)))}catch(e){}function cu(e){return e<10?"0"+e:String(e)}var hu="axo-clock",du="axo-clock-style",pu={topLeft:"axo-clock-top-left",topRight:"axo-clock-top-right",bottomLeft:"axo-clock-bottom-left",bottomRight:"axo-clock-bottom-right"},fu="\n#".concat(hu,' {\n position: fixed;\n z-index: 9000;\n pointer-events: none;\n padding: 3vh 3vw;\n font-family: "YouTube Sans", Roboto, "Noto Sans", Arial, sans-serif;\n font-size: 4vh;\n line-height: 1;\n font-variant-numeric: tabular-nums;\n color: rgba(255, 255, 255, 0.92);\n text-shadow: 0 1px 4px rgba(0, 0, 0, 0.85);\n}\n#').concat(hu,".axo-clock-top-left { top: 0; left: 0; }\n#").concat(hu,".axo-clock-top-right { top: 0; right: 0; }\n#").concat(hu,".axo-clock-bottom-left { bottom: 0; left: 0; }\n#").concat(hu,".axo-clock-bottom-right { bottom: 0; right: 0; }\n"),mu=null,gu=null;function vu(){var e=Se("clockMode");return"always"===e||"notPlaying"===e&&!function(){var e=Li();return!(!e||e.paused||e.ended)}()}function yu(){null!==gu&&clearInterval(gu),gu=null,mu&&mu.parentNode&&mu.parentNode.removeChild(mu),mu=null}function bu(){mu||((mu=document.createElement("div")).id=hu,document.body.appendChild(mu));var e=pu[Se("clockPosition")]||pu.topRight;mu.className!==e&&(mu.className=e);var t=function(e,t,n){var i=cu(e.getMinutes()),r=n?":"+cu(e.getSeconds()):"",a=e.getHours();if("24h"===t)return cu(a)+":"+i+r;var o=String(a%12==0?12:a%12)+":"+i+r;return"12hNoAmPm"===t?o:o+(a<12?" AM":" PM")}(new Date,Se("clockFormat"),!!Se("clockShowSeconds"));mu.textContent!==t&&(mu.textContent=t)}function xu(){document.body&&(vu()?(!function(){if(!document.getElementById(du)){var e=document.createElement("style");e.id=du,e.textContent=fu,(document.head||document.documentElement).appendChild(e)}}(),bu(),null===gu&&(gu=setInterval(bu,1e3))):yu())}["play","playing","pause","ended","emptied"].forEach(function(e){document.addEventListener(e,xu,!0)}),we.addEventListener("configChange",function(e){var t=e.detail&&e.detail.key;"clockMode"!==t&&"clockFormat"!==t&&"clockPosition"!==t&&"clockShowSeconds"!==t||xu()}),function e(){document.body?xu():setTimeout(e,250)}();var Su="axo-panel-shrink",Eu="axo-panel-shrink-style",wu="\nbody.".concat(Su," ytlr-player-container {\n transform: scale(var(--axo-panel-scale, 0.6));\n transform-origin: 0 0;\n transition: transform 0.25s ease;\n}\n");var ku=null,Du=null,Au=null,Cu=null;function Tu(){if(Cu=null,document.body){var e=document.querySelector("ytlr-engagement-panel-section-list-renderer");!function(e){if(e===Au)return;Du&&Du.disconnect();if(Du=null,Au=e,!e||"undefined"==typeof MutationObserver)return;(Du=new MutationObserver(Pu)).observe(e,{subtree:!0,attributes:!0,attributeFilter:["class"]})}(e),function(){if(!document.getElementById(Eu)){var e=document.createElement("style");e.id=Eu,e.textContent=wu,(document.head||document.documentElement).appendChild(e)}}();var t=!!Se("enablePanelShrink")&&/#\/watch/.test(location.hash||"")&&function(e){if(!e)return!1;var t=e.querySelector("ytlr-animated-overlay");return!t||!t.classList.contains("frHKed")}(e);document.body.classList.contains(Su)!==t&&document.body.classList.toggle(Su,t);var n=String(Number(Se("panelShrinkPercent"))/100);n!==ku&&(ku=n,document.documentElement.style.setProperty("--axo-panel-scale",n))}}function Pu(){null===Cu&&(Cu=requestAnimationFrame(Tu))}!function e(){if(document.body){var t=document.getElementById("container")||document.body;"undefined"!=typeof MutationObserver&&new MutationObserver(Pu).observe(t,{childList:!0,subtree:!0}),window.addEventListener("hashchange",Pu),we.addEventListener("configChange",function(e){var t=e.detail&&e.detail.key;"enablePanelShrink"!==t&&"panelShrinkPercent"!==t||Pu()}),Tu()}else setTimeout(e,250)}();var Fu,Bu={exports:{}};var Iu,Lu,Ou=(Fu||(Fu=1,Iu=function(){return function(e){var t={};function n(i){if(t[i])return t[i].exports;var r=t[i]={exports:{},id:i,loaded:!1};return e[i].call(r.exports,r,r.exports,n),r.loaded=!0,r.exports}return n.m=e,n.c=t,n.p="",n(0)}([function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var i=n(1),r=n(3),a=n(8),o=n(15);function s(e,t,n){var o=null,s=function(e,t){n&&n(e,t),o&&o.visit(e,t)},u="function"==typeof n?s:null,l=!1;if(t){l="boolean"==typeof t.comment&&t.comment;var c="boolean"==typeof t.attachComment&&t.attachComment;(l||c)&&((o=new i.CommentHandler).attach=c,t.comment=!0,u=s)}var h,d=!1;t&&"string"==typeof t.sourceType&&(d="module"===t.sourceType),h=t&&"boolean"==typeof t.jsx&&t.jsx?new r.JSXParser(e,t,u):new a.Parser(e,t,u);var p=d?h.parseModule():h.parseScript();return l&&o&&(p.comments=o.comments),h.config.tokens&&(p.tokens=h.tokens),h.config.tolerant&&(p.errors=h.errorHandler.errors),p}t.parse=s,t.parseModule=function(e,t,n){var i=t||{};return i.sourceType="module",s(e,i,n)},t.parseScript=function(e,t,n){var i=t||{};return i.sourceType="script",s(e,i,n)},t.tokenize=function(e,t,n){var i,r=new o.Tokenizer(e,t);i=[];try{for(;;){var a=r.getNextToken();if(!a)break;n&&(a=n(a)),i.push(a)}}catch(e){r.errorHandler.tolerate(e)}return r.errorHandler.tolerant&&(i.errors=r.errors()),i};var u=n(2);t.Syntax=u.Syntax,t.version="4.0.1"},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var i=n(2),r=function(){function e(){this.attach=!1,this.comments=[],this.stack=[],this.leading=[],this.trailing=[]}return e.prototype.insertInnerComments=function(e,t){if(e.type===i.Syntax.BlockStatement&&0===e.body.length){for(var n=[],r=this.leading.length-1;r>=0;--r){var a=this.leading[r];t.end.offset>=a.start&&(n.unshift(a.comment),this.leading.splice(r,1),this.trailing.splice(r,1))}n.length&&(e.innerComments=n)}},e.prototype.findTrailingComments=function(e){var t=[];if(this.trailing.length>0){for(var n=this.trailing.length-1;n>=0;--n){var i=this.trailing[n];i.start>=e.end.offset&&t.unshift(i.comment)}return this.trailing.length=0,t}var r=this.stack[this.stack.length-1];if(r&&r.node.trailingComments){var a=r.node.trailingComments[0];a&&a.range[0]>=e.end.offset&&(t=r.node.trailingComments,delete r.node.trailingComments)}return t},e.prototype.findLeadingComments=function(e){for(var t,n=[];this.stack.length>0&&(a=this.stack[this.stack.length-1])&&a.start>=e.start.offset;)t=a.node,this.stack.pop();if(t){for(var i=(t.leadingComments?t.leadingComments.length:0)-1;i>=0;--i){var r=t.leadingComments[i];r.range[1]<=e.start.offset&&(n.unshift(r),t.leadingComments.splice(i,1))}return t.leadingComments&&0===t.leadingComments.length&&delete t.leadingComments,n}for(i=this.leading.length-1;i>=0;--i){var a;(a=this.leading[i]).start<=e.start.offset&&(n.unshift(a.comment),this.leading.splice(i,1))}return n},e.prototype.visitNode=function(e,t){if(!(e.type===i.Syntax.Program&&e.body.length>0)){this.insertInnerComments(e,t);var n=this.findTrailingComments(t),r=this.findLeadingComments(t);r.length>0&&(e.leadingComments=r),n.length>0&&(e.trailingComments=n),this.stack.push({node:e,start:t.start.offset})}},e.prototype.visitComment=function(e,t){var n="L"===e.type[0]?"Line":"Block",i={type:n,value:e.value};if(e.range&&(i.range=e.range),e.loc&&(i.loc=e.loc),this.comments.push(i),this.attach){var r={comment:{type:n,value:e.value,range:[t.start.offset,t.end.offset]},start:t.start.offset};e.loc&&(r.comment.loc=e.loc),e.type=n,this.leading.push(r),this.trailing.push(r)}},e.prototype.visit=function(e,t){"LineComment"===e.type||"BlockComment"===e.type?this.visitComment(e,t):this.attach&&this.visitNode(e,t)},e}();t.CommentHandler=r},function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.Syntax={AssignmentExpression:"AssignmentExpression",AssignmentPattern:"AssignmentPattern",ArrayExpression:"ArrayExpression",ArrayPattern:"ArrayPattern",ArrowFunctionExpression:"ArrowFunctionExpression",AwaitExpression:"AwaitExpression",BlockStatement:"BlockStatement",BinaryExpression:"BinaryExpression",BreakStatement:"BreakStatement",CallExpression:"CallExpression",CatchClause:"CatchClause",ClassBody:"ClassBody",ClassDeclaration:"ClassDeclaration",ClassExpression:"ClassExpression",ConditionalExpression:"ConditionalExpression",ContinueStatement:"ContinueStatement",DoWhileStatement:"DoWhileStatement",DebuggerStatement:"DebuggerStatement",EmptyStatement:"EmptyStatement",ExportAllDeclaration:"ExportAllDeclaration",ExportDefaultDeclaration:"ExportDefaultDeclaration",ExportNamedDeclaration:"ExportNamedDeclaration",ExportSpecifier:"ExportSpecifier",ExpressionStatement:"ExpressionStatement",ForStatement:"ForStatement",ForOfStatement:"ForOfStatement",ForInStatement:"ForInStatement",FunctionDeclaration:"FunctionDeclaration",FunctionExpression:"FunctionExpression",Identifier:"Identifier",IfStatement:"IfStatement",ImportDeclaration:"ImportDeclaration",ImportDefaultSpecifier:"ImportDefaultSpecifier",ImportNamespaceSpecifier:"ImportNamespaceSpecifier",ImportSpecifier:"ImportSpecifier",Literal:"Literal",LabeledStatement:"LabeledStatement",LogicalExpression:"LogicalExpression",MemberExpression:"MemberExpression",MetaProperty:"MetaProperty",MethodDefinition:"MethodDefinition",NewExpression:"NewExpression",ObjectExpression:"ObjectExpression",ObjectPattern:"ObjectPattern",Program:"Program",Property:"Property",RestElement:"RestElement",ReturnStatement:"ReturnStatement",SequenceExpression:"SequenceExpression",SpreadElement:"SpreadElement",Super:"Super",SwitchCase:"SwitchCase",SwitchStatement:"SwitchStatement",TaggedTemplateExpression:"TaggedTemplateExpression",TemplateElement:"TemplateElement",TemplateLiteral:"TemplateLiteral",ThisExpression:"ThisExpression",ThrowStatement:"ThrowStatement",TryStatement:"TryStatement",UnaryExpression:"UnaryExpression",UpdateExpression:"UpdateExpression",VariableDeclaration:"VariableDeclaration",VariableDeclarator:"VariableDeclarator",WhileStatement:"WhileStatement",WithStatement:"WithStatement",YieldExpression:"YieldExpression"}},function(e,t,n){var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var a=n(4),o=n(5),s=n(6),u=n(7),l=n(8),c=n(13),h=n(14);function d(e){var t;switch(e.type){case s.JSXSyntax.JSXIdentifier:t=e.name;break;case s.JSXSyntax.JSXNamespacedName:var n=e;t=d(n.namespace)+":"+d(n.name);break;case s.JSXSyntax.JSXMemberExpression:var i=e;t=d(i.object)+"."+d(i.property)}return t}c.TokenName[100]="JSXIdentifier",c.TokenName[101]="JSXText";var p=function(e){function t(t,n,i){return e.call(this,t,n,i)||this}return r(t,e),t.prototype.parsePrimaryExpression=function(){return this.match("<")?this.parseJSXRoot():e.prototype.parsePrimaryExpression.call(this)},t.prototype.startJSX=function(){this.scanner.index=this.startMarker.index,this.scanner.lineNumber=this.startMarker.line,this.scanner.lineStart=this.startMarker.index-this.startMarker.column},t.prototype.finishJSX=function(){this.nextToken()},t.prototype.reenterJSX=function(){this.startJSX(),this.expectJSX("}"),this.config.tokens&&this.tokens.pop()},t.prototype.createJSXNode=function(){return this.collectComments(),{index:this.scanner.index,line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}},t.prototype.createJSXChildNode=function(){return{index:this.scanner.index,line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}},t.prototype.scanXHTMLEntity=function(e){for(var t="&",n=!0,i=!1,r=!1,o=!1;!this.scanner.eof()&&n&&!i;){var s=this.scanner.source[this.scanner.index];if(s===e)break;if(i=";"===s,t+=s,++this.scanner.index,!i)switch(t.length){case 2:r="#"===s;break;case 3:r&&(n=(o="x"===s)||a.Character.isDecimalDigit(s.charCodeAt(0)),r=r&&!o);break;default:n=(n=n&&!(r&&!a.Character.isDecimalDigit(s.charCodeAt(0))))&&!(o&&!a.Character.isHexDigit(s.charCodeAt(0)))}}if(n&&i&&t.length>2){var u=t.substr(1,t.length-2);r&&u.length>1?t=String.fromCharCode(parseInt(u.substr(1),10)):o&&u.length>2?t=String.fromCharCode(parseInt("0"+u.substr(1),16)):r||o||!h.XHTMLEntities[u]||(t=h.XHTMLEntities[u])}return t},t.prototype.lexJSX=function(){var e=this.scanner.source.charCodeAt(this.scanner.index);if(60===e||62===e||47===e||58===e||61===e||123===e||125===e)return{type:7,value:s=this.scanner.source[this.scanner.index++],lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:this.scanner.index-1,end:this.scanner.index};if(34===e||39===e){for(var t=this.scanner.index,n=this.scanner.source[this.scanner.index++],i="";!this.scanner.eof()&&(u=this.scanner.source[this.scanner.index++])!==n;)i+="&"===u?this.scanXHTMLEntity(n):u;return{type:8,value:i,lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:t,end:this.scanner.index}}if(46===e){var r=this.scanner.source.charCodeAt(this.scanner.index+1),o=this.scanner.source.charCodeAt(this.scanner.index+2),s=46===r&&46===o?"...":".";return t=this.scanner.index,this.scanner.index+=s.length,{type:7,value:s,lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:t,end:this.scanner.index}}if(96===e)return{type:10,value:"",lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:this.scanner.index,end:this.scanner.index};if(a.Character.isIdentifierStart(e)&&92!==e){for(t=this.scanner.index,++this.scanner.index;!this.scanner.eof();){var u=this.scanner.source.charCodeAt(this.scanner.index);if(a.Character.isIdentifierPart(u)&&92!==u)++this.scanner.index;else{if(45!==u)break;++this.scanner.index}}return{type:100,value:this.scanner.source.slice(t,this.scanner.index),lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:t,end:this.scanner.index}}return this.scanner.lex()},t.prototype.nextJSXToken=function(){this.collectComments(),this.startMarker.index=this.scanner.index,this.startMarker.line=this.scanner.lineNumber,this.startMarker.column=this.scanner.index-this.scanner.lineStart;var e=this.lexJSX();return this.lastMarker.index=this.scanner.index,this.lastMarker.line=this.scanner.lineNumber,this.lastMarker.column=this.scanner.index-this.scanner.lineStart,this.config.tokens&&this.tokens.push(this.convertToken(e)),e},t.prototype.nextJSXText=function(){this.startMarker.index=this.scanner.index,this.startMarker.line=this.scanner.lineNumber,this.startMarker.column=this.scanner.index-this.scanner.lineStart;for(var e=this.scanner.index,t="";!this.scanner.eof();){var n=this.scanner.source[this.scanner.index];if("{"===n||"<"===n)break;++this.scanner.index,t+=n,a.Character.isLineTerminator(n.charCodeAt(0))&&(++this.scanner.lineNumber,"\r"===n&&"\n"===this.scanner.source[this.scanner.index]&&++this.scanner.index,this.scanner.lineStart=this.scanner.index)}this.lastMarker.index=this.scanner.index,this.lastMarker.line=this.scanner.lineNumber,this.lastMarker.column=this.scanner.index-this.scanner.lineStart;var i={type:101,value:t,lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:e,end:this.scanner.index};return t.length>0&&this.config.tokens&&this.tokens.push(this.convertToken(i)),i},t.prototype.peekJSXToken=function(){var e=this.scanner.saveState();this.scanner.scanComments();var t=this.lexJSX();return this.scanner.restoreState(e),t},t.prototype.expectJSX=function(e){var t=this.nextJSXToken();7===t.type&&t.value===e||this.throwUnexpectedToken(t)},t.prototype.matchJSX=function(e){var t=this.peekJSXToken();return 7===t.type&&t.value===e},t.prototype.parseJSXIdentifier=function(){var e=this.createJSXNode(),t=this.nextJSXToken();return 100!==t.type&&this.throwUnexpectedToken(t),this.finalize(e,new o.JSXIdentifier(t.value))},t.prototype.parseJSXElementName=function(){var e=this.createJSXNode(),t=this.parseJSXIdentifier();if(this.matchJSX(":")){var n=t;this.expectJSX(":");var i=this.parseJSXIdentifier();t=this.finalize(e,new o.JSXNamespacedName(n,i))}else if(this.matchJSX("."))for(;this.matchJSX(".");){var r=t;this.expectJSX(".");var a=this.parseJSXIdentifier();t=this.finalize(e,new o.JSXMemberExpression(r,a))}return t},t.prototype.parseJSXAttributeName=function(){var e,t=this.createJSXNode(),n=this.parseJSXIdentifier();if(this.matchJSX(":")){var i=n;this.expectJSX(":");var r=this.parseJSXIdentifier();e=this.finalize(t,new o.JSXNamespacedName(i,r))}else e=n;return e},t.prototype.parseJSXStringLiteralAttribute=function(){var e=this.createJSXNode(),t=this.nextJSXToken();8!==t.type&&this.throwUnexpectedToken(t);var n=this.getTokenRaw(t);return this.finalize(e,new u.Literal(t.value,n))},t.prototype.parseJSXExpressionAttribute=function(){var e=this.createJSXNode();this.expectJSX("{"),this.finishJSX(),this.match("}")&&this.tolerateError("JSX attributes must only be assigned a non-empty expression");var t=this.parseAssignmentExpression();return this.reenterJSX(),this.finalize(e,new o.JSXExpressionContainer(t))},t.prototype.parseJSXAttributeValue=function(){return this.matchJSX("{")?this.parseJSXExpressionAttribute():this.matchJSX("<")?this.parseJSXElement():this.parseJSXStringLiteralAttribute()},t.prototype.parseJSXNameValueAttribute=function(){var e=this.createJSXNode(),t=this.parseJSXAttributeName(),n=null;return this.matchJSX("=")&&(this.expectJSX("="),n=this.parseJSXAttributeValue()),this.finalize(e,new o.JSXAttribute(t,n))},t.prototype.parseJSXSpreadAttribute=function(){var e=this.createJSXNode();this.expectJSX("{"),this.expectJSX("..."),this.finishJSX();var t=this.parseAssignmentExpression();return this.reenterJSX(),this.finalize(e,new o.JSXSpreadAttribute(t))},t.prototype.parseJSXAttributes=function(){for(var e=[];!this.matchJSX("/")&&!this.matchJSX(">");){var t=this.matchJSX("{")?this.parseJSXSpreadAttribute():this.parseJSXNameValueAttribute();e.push(t)}return e},t.prototype.parseJSXOpeningElement=function(){var e=this.createJSXNode();this.expectJSX("<");var t=this.parseJSXElementName(),n=this.parseJSXAttributes(),i=this.matchJSX("/");return i&&this.expectJSX("/"),this.expectJSX(">"),this.finalize(e,new o.JSXOpeningElement(t,i,n))},t.prototype.parseJSXBoundaryElement=function(){var e=this.createJSXNode();if(this.expectJSX("<"),this.matchJSX("/")){this.expectJSX("/");var t=this.parseJSXElementName();return this.expectJSX(">"),this.finalize(e,new o.JSXClosingElement(t))}var n=this.parseJSXElementName(),i=this.parseJSXAttributes(),r=this.matchJSX("/");return r&&this.expectJSX("/"),this.expectJSX(">"),this.finalize(e,new o.JSXOpeningElement(n,r,i))},t.prototype.parseJSXEmptyExpression=function(){var e=this.createJSXChildNode();return this.collectComments(),this.lastMarker.index=this.scanner.index,this.lastMarker.line=this.scanner.lineNumber,this.lastMarker.column=this.scanner.index-this.scanner.lineStart,this.finalize(e,new o.JSXEmptyExpression)},t.prototype.parseJSXExpressionContainer=function(){var e,t=this.createJSXNode();return this.expectJSX("{"),this.matchJSX("}")?(e=this.parseJSXEmptyExpression(),this.expectJSX("}")):(this.finishJSX(),e=this.parseAssignmentExpression(),this.reenterJSX()),this.finalize(t,new o.JSXExpressionContainer(e))},t.prototype.parseJSXChildren=function(){for(var e=[];!this.scanner.eof();){var t=this.createJSXChildNode(),n=this.nextJSXText();if(n.start<n.end){var i=this.getTokenRaw(n),r=this.finalize(t,new o.JSXText(n.value,i));e.push(r)}if("{"!==this.scanner.source[this.scanner.index])break;var a=this.parseJSXExpressionContainer();e.push(a)}return e},t.prototype.parseComplexJSXElement=function(e){for(var t=[];!this.scanner.eof();){e.children=e.children.concat(this.parseJSXChildren());var n=this.createJSXChildNode(),i=this.parseJSXBoundaryElement();if(i.type===s.JSXSyntax.JSXOpeningElement){var r=i;if(r.selfClosing){var a=this.finalize(n,new o.JSXElement(r,[],null));e.children.push(a)}else t.push(e),e={node:n,opening:r,closing:null,children:[]}}if(i.type===s.JSXSyntax.JSXClosingElement){e.closing=i;var u=d(e.opening.name);if(u!==d(e.closing.name)&&this.tolerateError("Expected corresponding JSX closing tag for %0",u),!(t.length>0))break;a=this.finalize(e.node,new o.JSXElement(e.opening,e.children,e.closing)),(e=t[t.length-1]).children.push(a),t.pop()}}return e},t.prototype.parseJSXElement=function(){var e=this.createJSXNode(),t=this.parseJSXOpeningElement(),n=[],i=null;if(!t.selfClosing){var r=this.parseComplexJSXElement({node:e,opening:t,closing:i,children:n});n=r.children,i=r.closing}return this.finalize(e,new o.JSXElement(t,n,i))},t.prototype.parseJSXRoot=function(){this.config.tokens&&this.tokens.pop(),this.startJSX();var e=this.parseJSXElement();return this.finishJSX(),e},t.prototype.isStartOfExpression=function(){return e.prototype.isStartOfExpression.call(this)||this.match("<")},t}(l.Parser);t.JSXParser=p},function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n={NonAsciiIdentifierStart:/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0-\u08B4\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF30-\uDF4A\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC03-\uDC37\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDEC0-\uDEF8]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F]|\uD82C[\uDC00\uDC01]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1]|\uD87E[\uDC00-\uDE1D]/,NonAsciiIdentifierPart:/[\xAA\xB5\xB7\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u08A0-\u08B4\u08E3-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0AF9\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C60-\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D01-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D57\u0D5F-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1369-\u1371\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19DA\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1CD0-\u1CD2\u1CD4-\u1CF6\u1CF8\u1CF9\u1D00-\u1DF5\u1DFC-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u200C\u200D\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C4\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA8FD\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDDFD\uDE80-\uDE9C\uDEA0-\uDED0\uDEE0\uDF00-\uDF1F\uDF30-\uDF4A\uDF50-\uDF7A\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCA0-\uDCA9\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00-\uDE03\uDE05\uDE06\uDE0C-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE38-\uDE3A\uDE3F\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE6\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC00-\uDC46\uDC66-\uDC6F\uDC7F-\uDCBA\uDCD0-\uDCE8\uDCF0-\uDCF9\uDD00-\uDD34\uDD36-\uDD3F\uDD50-\uDD73\uDD76\uDD80-\uDDC4\uDDCA-\uDDCC\uDDD0-\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE37\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEEA\uDEF0-\uDEF9\uDF00-\uDF03\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3C-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF50\uDF57\uDF5D-\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC80-\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDB5\uDDB8-\uDDC0\uDDD8-\uDDDD\uDE00-\uDE40\uDE44\uDE50-\uDE59\uDE80-\uDEB7\uDEC0-\uDEC9\uDF00-\uDF19\uDF1D-\uDF2B\uDF30-\uDF39]|\uD806[\uDCA0-\uDCE9\uDCFF\uDEC0-\uDEF8]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDED0-\uDEED\uDEF0-\uDEF4\uDF00-\uDF36\uDF40-\uDF43\uDF50-\uDF59\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50-\uDF7E\uDF8F-\uDF9F]|\uD82C[\uDC00\uDC01]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99\uDC9D\uDC9E]|\uD834[\uDD65-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB\uDFCE-\uDFFF]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD83A[\uDC00-\uDCC4\uDCD0-\uDCD6]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1]|\uD87E[\uDC00-\uDE1D]|\uDB40[\uDD00-\uDDEF]/};t.Character={fromCodePoint:function(e){return e<65536?String.fromCharCode(e):String.fromCharCode(55296+(e-65536>>10))+String.fromCharCode(56320+(e-65536&1023))},isWhiteSpace:function(e){return 32===e||9===e||11===e||12===e||160===e||e>=5760&&[5760,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8239,8287,12288,65279].indexOf(e)>=0},isLineTerminator:function(e){return 10===e||13===e||8232===e||8233===e},isIdentifierStart:function(e){return 36===e||95===e||e>=65&&e<=90||e>=97&&e<=122||92===e||e>=128&&n.NonAsciiIdentifierStart.test(t.Character.fromCodePoint(e))},isIdentifierPart:function(e){return 36===e||95===e||e>=65&&e<=90||e>=97&&e<=122||e>=48&&e<=57||92===e||e>=128&&n.NonAsciiIdentifierPart.test(t.Character.fromCodePoint(e))},isDecimalDigit:function(e){return e>=48&&e<=57},isHexDigit:function(e){return e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102},isOctalDigit:function(e){return e>=48&&e<=55}}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var i=n(6),r=function(e){this.type=i.JSXSyntax.JSXClosingElement,this.name=e};t.JSXClosingElement=r;var a=function(e,t,n){this.type=i.JSXSyntax.JSXElement,this.openingElement=e,this.children=t,this.closingElement=n};t.JSXElement=a;var o=function(){this.type=i.JSXSyntax.JSXEmptyExpression};t.JSXEmptyExpression=o;var s=function(e){this.type=i.JSXSyntax.JSXExpressionContainer,this.expression=e};t.JSXExpressionContainer=s;var u=function(e){this.type=i.JSXSyntax.JSXIdentifier,this.name=e};t.JSXIdentifier=u;var l=function(e,t){this.type=i.JSXSyntax.JSXMemberExpression,this.object=e,this.property=t};t.JSXMemberExpression=l;var c=function(e,t){this.type=i.JSXSyntax.JSXAttribute,this.name=e,this.value=t};t.JSXAttribute=c;var h=function(e,t){this.type=i.JSXSyntax.JSXNamespacedName,this.namespace=e,this.name=t};t.JSXNamespacedName=h;var d=function(e,t,n){this.type=i.JSXSyntax.JSXOpeningElement,this.name=e,this.selfClosing=t,this.attributes=n};t.JSXOpeningElement=d;var p=function(e){this.type=i.JSXSyntax.JSXSpreadAttribute,this.argument=e};t.JSXSpreadAttribute=p;var f=function(e,t){this.type=i.JSXSyntax.JSXText,this.value=e,this.raw=t};t.JSXText=f},function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.JSXSyntax={JSXAttribute:"JSXAttribute",JSXClosingElement:"JSXClosingElement",JSXElement:"JSXElement",JSXEmptyExpression:"JSXEmptyExpression",JSXExpressionContainer:"JSXExpressionContainer",JSXIdentifier:"JSXIdentifier",JSXMemberExpression:"JSXMemberExpression",JSXNamespacedName:"JSXNamespacedName",JSXOpeningElement:"JSXOpeningElement",JSXSpreadAttribute:"JSXSpreadAttribute",JSXText:"JSXText"}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var i=n(2),r=function(e){this.type=i.Syntax.ArrayExpression,this.elements=e};t.ArrayExpression=r;var a=function(e){this.type=i.Syntax.ArrayPattern,this.elements=e};t.ArrayPattern=a;var o=function(e,t,n){this.type=i.Syntax.ArrowFunctionExpression,this.id=null,this.params=e,this.body=t,this.generator=!1,this.expression=n,this.async=!1};t.ArrowFunctionExpression=o;var s=function(e,t,n){this.type=i.Syntax.AssignmentExpression,this.operator=e,this.left=t,this.right=n};t.AssignmentExpression=s;var u=function(e,t){this.type=i.Syntax.AssignmentPattern,this.left=e,this.right=t};t.AssignmentPattern=u;var l=function(e,t,n){this.type=i.Syntax.ArrowFunctionExpression,this.id=null,this.params=e,this.body=t,this.generator=!1,this.expression=n,this.async=!0};t.AsyncArrowFunctionExpression=l;var c=function(e,t,n){this.type=i.Syntax.FunctionDeclaration,this.id=e,this.params=t,this.body=n,this.generator=!1,this.expression=!1,this.async=!0};t.AsyncFunctionDeclaration=c;var h=function(e,t,n){this.type=i.Syntax.FunctionExpression,this.id=e,this.params=t,this.body=n,this.generator=!1,this.expression=!1,this.async=!0};t.AsyncFunctionExpression=h;var d=function(e){this.type=i.Syntax.AwaitExpression,this.argument=e};t.AwaitExpression=d;var p=function(e,t,n){var r="||"===e||"&&"===e;this.type=r?i.Syntax.LogicalExpression:i.Syntax.BinaryExpression,this.operator=e,this.left=t,this.right=n};t.BinaryExpression=p;var f=function(e){this.type=i.Syntax.BlockStatement,this.body=e};t.BlockStatement=f;var m=function(e){this.type=i.Syntax.BreakStatement,this.label=e};t.BreakStatement=m;var g=function(e,t){this.type=i.Syntax.CallExpression,this.callee=e,this.arguments=t};t.CallExpression=g;var v=function(e,t){this.type=i.Syntax.CatchClause,this.param=e,this.body=t};t.CatchClause=v;var y=function(e){this.type=i.Syntax.ClassBody,this.body=e};t.ClassBody=y;var b=function(e,t,n){this.type=i.Syntax.ClassDeclaration,this.id=e,this.superClass=t,this.body=n};t.ClassDeclaration=b;var x=function(e,t,n){this.type=i.Syntax.ClassExpression,this.id=e,this.superClass=t,this.body=n};t.ClassExpression=x;var S=function(e,t){this.type=i.Syntax.MemberExpression,this.computed=!0,this.object=e,this.property=t};t.ComputedMemberExpression=S;var E=function(e,t,n){this.type=i.Syntax.ConditionalExpression,this.test=e,this.consequent=t,this.alternate=n};t.ConditionalExpression=E;var w=function(e){this.type=i.Syntax.ContinueStatement,this.label=e};t.ContinueStatement=w;var k=function(){this.type=i.Syntax.DebuggerStatement};t.DebuggerStatement=k;var D=function(e,t){this.type=i.Syntax.ExpressionStatement,this.expression=e,this.directive=t};t.Directive=D;var A=function(e,t){this.type=i.Syntax.DoWhileStatement,this.body=e,this.test=t};t.DoWhileStatement=A;var C=function(){this.type=i.Syntax.EmptyStatement};t.EmptyStatement=C;var T=function(e){this.type=i.Syntax.ExportAllDeclaration,this.source=e};t.ExportAllDeclaration=T;var P=function(e){this.type=i.Syntax.ExportDefaultDeclaration,this.declaration=e};t.ExportDefaultDeclaration=P;var F=function(e,t,n){this.type=i.Syntax.ExportNamedDeclaration,this.declaration=e,this.specifiers=t,this.source=n};t.ExportNamedDeclaration=F;var B=function(e,t){this.type=i.Syntax.ExportSpecifier,this.exported=t,this.local=e};t.ExportSpecifier=B;var I=function(e){this.type=i.Syntax.ExpressionStatement,this.expression=e};t.ExpressionStatement=I;var L=function(e,t,n){this.type=i.Syntax.ForInStatement,this.left=e,this.right=t,this.body=n,this.each=!1};t.ForInStatement=L;var O=function(e,t,n){this.type=i.Syntax.ForOfStatement,this.left=e,this.right=t,this.body=n};t.ForOfStatement=O;var N=function(e,t,n,r){this.type=i.Syntax.ForStatement,this.init=e,this.test=t,this.update=n,this.body=r};t.ForStatement=N;var R=function(e,t,n,r){this.type=i.Syntax.FunctionDeclaration,this.id=e,this.params=t,this.body=n,this.generator=r,this.expression=!1,this.async=!1};t.FunctionDeclaration=R;var M=function(e,t,n,r){this.type=i.Syntax.FunctionExpression,this.id=e,this.params=t,this.body=n,this.generator=r,this.expression=!1,this.async=!1};t.FunctionExpression=M;var _=function(e){this.type=i.Syntax.Identifier,this.name=e};t.Identifier=_;var U=function(e,t,n){this.type=i.Syntax.IfStatement,this.test=e,this.consequent=t,this.alternate=n};t.IfStatement=U;var j=function(e,t){this.type=i.Syntax.ImportDeclaration,this.specifiers=e,this.source=t};t.ImportDeclaration=j;var H=function(e){this.type=i.Syntax.ImportDefaultSpecifier,this.local=e};t.ImportDefaultSpecifier=H;var z=function(e){this.type=i.Syntax.ImportNamespaceSpecifier,this.local=e};t.ImportNamespaceSpecifier=z;var V=function(e,t){this.type=i.Syntax.ImportSpecifier,this.local=e,this.imported=t};t.ImportSpecifier=V;var K=function(e,t){this.type=i.Syntax.LabeledStatement,this.label=e,this.body=t};t.LabeledStatement=K;var G=function(e,t){this.type=i.Syntax.Literal,this.value=e,this.raw=t};t.Literal=G;var J=function(e,t){this.type=i.Syntax.MetaProperty,this.meta=e,this.property=t};t.MetaProperty=J;var X=function(e,t,n,r,a){this.type=i.Syntax.MethodDefinition,this.key=e,this.computed=t,this.value=n,this.kind=r,this.static=a};t.MethodDefinition=X;var W=function(e){this.type=i.Syntax.Program,this.body=e,this.sourceType="module"};t.Module=W;var q=function(e,t){this.type=i.Syntax.NewExpression,this.callee=e,this.arguments=t};t.NewExpression=q;var Y=function(e){this.type=i.Syntax.ObjectExpression,this.properties=e};t.ObjectExpression=Y;var Q=function(e){this.type=i.Syntax.ObjectPattern,this.properties=e};t.ObjectPattern=Q;var Z=function(e,t,n,r,a,o){this.type=i.Syntax.Property,this.key=t,this.computed=n,this.value=r,this.kind=e,this.method=a,this.shorthand=o};t.Property=Z;var $=function(e,t,n,r){this.type=i.Syntax.Literal,this.value=e,this.raw=t,this.regex={pattern:n,flags:r}};t.RegexLiteral=$;var ee=function(e){this.type=i.Syntax.RestElement,this.argument=e};t.RestElement=ee;var te=function(e){this.type=i.Syntax.ReturnStatement,this.argument=e};t.ReturnStatement=te;var ne=function(e){this.type=i.Syntax.Program,this.body=e,this.sourceType="script"};t.Script=ne;var ie=function(e){this.type=i.Syntax.SequenceExpression,this.expressions=e};t.SequenceExpression=ie;var re=function(e){this.type=i.Syntax.SpreadElement,this.argument=e};t.SpreadElement=re;var ae=function(e,t){this.type=i.Syntax.MemberExpression,this.computed=!1,this.object=e,this.property=t};t.StaticMemberExpression=ae;var oe=function(){this.type=i.Syntax.Super};t.Super=oe;var se=function(e,t){this.type=i.Syntax.SwitchCase,this.test=e,this.consequent=t};t.SwitchCase=se;var ue=function(e,t){this.type=i.Syntax.SwitchStatement,this.discriminant=e,this.cases=t};t.SwitchStatement=ue;var le=function(e,t){this.type=i.Syntax.TaggedTemplateExpression,this.tag=e,this.quasi=t};t.TaggedTemplateExpression=le;var ce=function(e,t){this.type=i.Syntax.TemplateElement,this.value=e,this.tail=t};t.TemplateElement=ce;var he=function(e,t){this.type=i.Syntax.TemplateLiteral,this.quasis=e,this.expressions=t};t.TemplateLiteral=he;var de=function(){this.type=i.Syntax.ThisExpression};t.ThisExpression=de;var pe=function(e){this.type=i.Syntax.ThrowStatement,this.argument=e};t.ThrowStatement=pe;var fe=function(e,t,n){this.type=i.Syntax.TryStatement,this.block=e,this.handler=t,this.finalizer=n};t.TryStatement=fe;var me=function(e,t){this.type=i.Syntax.UnaryExpression,this.operator=e,this.argument=t,this.prefix=!0};t.UnaryExpression=me;var ge=function(e,t,n){this.type=i.Syntax.UpdateExpression,this.operator=e,this.argument=t,this.prefix=n};t.UpdateExpression=ge;var ve=function(e,t){this.type=i.Syntax.VariableDeclaration,this.declarations=e,this.kind=t};t.VariableDeclaration=ve;var ye=function(e,t){this.type=i.Syntax.VariableDeclarator,this.id=e,this.init=t};t.VariableDeclarator=ye;var be=function(e,t){this.type=i.Syntax.WhileStatement,this.test=e,this.body=t};t.WhileStatement=be;var xe=function(e,t){this.type=i.Syntax.WithStatement,this.object=e,this.body=t};t.WithStatement=xe;var Se=function(e,t){this.type=i.Syntax.YieldExpression,this.argument=e,this.delegate=t};t.YieldExpression=Se},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var i=n(9),r=n(10),a=n(11),o=n(7),s=n(12),u=n(2),l=n(13),c="ArrowParameterPlaceHolder",h=function(){function e(e,t,n){void 0===t&&(t={}),this.config={range:"boolean"==typeof t.range&&t.range,loc:"boolean"==typeof t.loc&&t.loc,source:null,tokens:"boolean"==typeof t.tokens&&t.tokens,comment:"boolean"==typeof t.comment&&t.comment,tolerant:"boolean"==typeof t.tolerant&&t.tolerant},this.config.loc&&t.source&&null!==t.source&&(this.config.source=String(t.source)),this.delegate=n,this.errorHandler=new r.ErrorHandler,this.errorHandler.tolerant=this.config.tolerant,this.scanner=new s.Scanner(e,this.errorHandler),this.scanner.trackComment=this.config.comment,this.operatorPrecedence={")":0,";":0,",":0,"=":0,"]":0,"||":1,"&&":2,"|":3,"^":4,"&":5,"==":6,"!=":6,"===":6,"!==":6,"<":7,">":7,"<=":7,">=":7,"<<":8,">>":8,">>>":8,"+":9,"-":9,"*":11,"/":11,"%":11},this.lookahead={type:2,value:"",lineNumber:this.scanner.lineNumber,lineStart:0,start:0,end:0},this.hasLineTerminator=!1,this.context={isModule:!1,await:!1,allowIn:!0,allowStrictDirective:!0,allowYield:!0,firstCoverInitializedNameError:null,isAssignmentTarget:!1,isBindingElement:!1,inFunctionBody:!1,inIteration:!1,inSwitch:!1,labelSet:{},strict:!1},this.tokens=[],this.startMarker={index:0,line:this.scanner.lineNumber,column:0},this.lastMarker={index:0,line:this.scanner.lineNumber,column:0},this.nextToken(),this.lastMarker={index:this.scanner.index,line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}}return e.prototype.throwError=function(e){var t=Array.prototype.slice.call(arguments,1),n=e.replace(/%(\d)/g,function(e,n){return i.assert(n<t.length,"Message reference must be in range"),t[n]}),r=this.lastMarker.index,a=this.lastMarker.line,o=this.lastMarker.column+1;throw this.errorHandler.createError(r,a,o,n)},e.prototype.tolerateError=function(e){var t=Array.prototype.slice.call(arguments,1),n=e.replace(/%(\d)/g,function(e,n){return i.assert(n<t.length,"Message reference must be in range"),t[n]}),r=this.lastMarker.index,a=this.scanner.lineNumber,o=this.lastMarker.column+1;this.errorHandler.tolerateError(r,a,o,n)},e.prototype.unexpectedTokenError=function(e,t){var n,i=t||a.Messages.UnexpectedToken;if(e?(t||(i=2===e.type?a.Messages.UnexpectedEOS:3===e.type?a.Messages.UnexpectedIdentifier:6===e.type?a.Messages.UnexpectedNumber:8===e.type?a.Messages.UnexpectedString:10===e.type?a.Messages.UnexpectedTemplate:a.Messages.UnexpectedToken,4===e.type&&(this.scanner.isFutureReservedWord(e.value)?i=a.Messages.UnexpectedReserved:this.context.strict&&this.scanner.isStrictModeReservedWord(e.value)&&(i=a.Messages.StrictReservedWord))),n=e.value):n="ILLEGAL",i=i.replace("%0",n),e&&"number"==typeof e.lineNumber){var r=e.start,o=e.lineNumber,s=this.lastMarker.index-this.lastMarker.column,u=e.start-s+1;return this.errorHandler.createError(r,o,u,i)}return r=this.lastMarker.index,o=this.lastMarker.line,u=this.lastMarker.column+1,this.errorHandler.createError(r,o,u,i)},e.prototype.throwUnexpectedToken=function(e,t){throw this.unexpectedTokenError(e,t)},e.prototype.tolerateUnexpectedToken=function(e,t){this.errorHandler.tolerate(this.unexpectedTokenError(e,t))},e.prototype.collectComments=function(){if(this.config.comment){var e=this.scanner.scanComments();if(e.length>0&&this.delegate)for(var t=0;t<e.length;++t){var n=e[t],i=void 0;i={type:n.multiLine?"BlockComment":"LineComment",value:this.scanner.source.slice(n.slice[0],n.slice[1])},this.config.range&&(i.range=n.range),this.config.loc&&(i.loc=n.loc);var r={start:{line:n.loc.start.line,column:n.loc.start.column,offset:n.range[0]},end:{line:n.loc.end.line,column:n.loc.end.column,offset:n.range[1]}};this.delegate(i,r)}}else this.scanner.scanComments()},e.prototype.getTokenRaw=function(e){return this.scanner.source.slice(e.start,e.end)},e.prototype.convertToken=function(e){var t={type:l.TokenName[e.type],value:this.getTokenRaw(e)};if(this.config.range&&(t.range=[e.start,e.end]),this.config.loc&&(t.loc={start:{line:this.startMarker.line,column:this.startMarker.column},end:{line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}}),9===e.type){var n=e.pattern,i=e.flags;t.regex={pattern:n,flags:i}}return t},e.prototype.nextToken=function(){var e=this.lookahead;this.lastMarker.index=this.scanner.index,this.lastMarker.line=this.scanner.lineNumber,this.lastMarker.column=this.scanner.index-this.scanner.lineStart,this.collectComments(),this.scanner.index!==this.startMarker.index&&(this.startMarker.index=this.scanner.index,this.startMarker.line=this.scanner.lineNumber,this.startMarker.column=this.scanner.index-this.scanner.lineStart);var t=this.scanner.lex();return this.hasLineTerminator=e.lineNumber!==t.lineNumber,t&&this.context.strict&&3===t.type&&this.scanner.isStrictModeReservedWord(t.value)&&(t.type=4),this.lookahead=t,this.config.tokens&&2!==t.type&&this.tokens.push(this.convertToken(t)),e},e.prototype.nextRegexToken=function(){this.collectComments();var e=this.scanner.scanRegExp();return this.config.tokens&&(this.tokens.pop(),this.tokens.push(this.convertToken(e))),this.lookahead=e,this.nextToken(),e},e.prototype.createNode=function(){return{index:this.startMarker.index,line:this.startMarker.line,column:this.startMarker.column}},e.prototype.startNode=function(e,t){void 0===t&&(t=0);var n=e.start-e.lineStart,i=e.lineNumber;return n<0&&(n+=t,i--),{index:e.start,line:i,column:n}},e.prototype.finalize=function(e,t){if(this.config.range&&(t.range=[e.index,this.lastMarker.index]),this.config.loc&&(t.loc={start:{line:e.line,column:e.column},end:{line:this.lastMarker.line,column:this.lastMarker.column}},this.config.source&&(t.loc.source=this.config.source)),this.delegate){var n={start:{line:e.line,column:e.column,offset:e.index},end:{line:this.lastMarker.line,column:this.lastMarker.column,offset:this.lastMarker.index}};this.delegate(t,n)}return t},e.prototype.expect=function(e){var t=this.nextToken();7===t.type&&t.value===e||this.throwUnexpectedToken(t)},e.prototype.expectCommaSeparator=function(){if(this.config.tolerant){var e=this.lookahead;7===e.type&&","===e.value?this.nextToken():7===e.type&&";"===e.value?(this.nextToken(),this.tolerateUnexpectedToken(e)):this.tolerateUnexpectedToken(e,a.Messages.UnexpectedToken)}else this.expect(",")},e.prototype.expectKeyword=function(e){var t=this.nextToken();4===t.type&&t.value===e||this.throwUnexpectedToken(t)},e.prototype.match=function(e){return 7===this.lookahead.type&&this.lookahead.value===e},e.prototype.matchKeyword=function(e){return 4===this.lookahead.type&&this.lookahead.value===e},e.prototype.matchContextualKeyword=function(e){return 3===this.lookahead.type&&this.lookahead.value===e},e.prototype.matchAssign=function(){if(7!==this.lookahead.type)return!1;var e=this.lookahead.value;return"="===e||"*="===e||"**="===e||"/="===e||"%="===e||"+="===e||"-="===e||"<<="===e||">>="===e||">>>="===e||"&="===e||"^="===e||"|="===e},e.prototype.isolateCoverGrammar=function(e){var t=this.context.isBindingElement,n=this.context.isAssignmentTarget,i=this.context.firstCoverInitializedNameError;this.context.isBindingElement=!0,this.context.isAssignmentTarget=!0,this.context.firstCoverInitializedNameError=null;var r=e.call(this);return null!==this.context.firstCoverInitializedNameError&&this.throwUnexpectedToken(this.context.firstCoverInitializedNameError),this.context.isBindingElement=t,this.context.isAssignmentTarget=n,this.context.firstCoverInitializedNameError=i,r},e.prototype.inheritCoverGrammar=function(e){var t=this.context.isBindingElement,n=this.context.isAssignmentTarget,i=this.context.firstCoverInitializedNameError;this.context.isBindingElement=!0,this.context.isAssignmentTarget=!0,this.context.firstCoverInitializedNameError=null;var r=e.call(this);return this.context.isBindingElement=this.context.isBindingElement&&t,this.context.isAssignmentTarget=this.context.isAssignmentTarget&&n,this.context.firstCoverInitializedNameError=i||this.context.firstCoverInitializedNameError,r},e.prototype.consumeSemicolon=function(){this.match(";")?this.nextToken():this.hasLineTerminator||(2===this.lookahead.type||this.match("}")||this.throwUnexpectedToken(this.lookahead),this.lastMarker.index=this.startMarker.index,this.lastMarker.line=this.startMarker.line,this.lastMarker.column=this.startMarker.column)},e.prototype.parsePrimaryExpression=function(){var e,t,n,i=this.createNode();switch(this.lookahead.type){case 3:(this.context.isModule||this.context.await)&&"await"===this.lookahead.value&&this.tolerateUnexpectedToken(this.lookahead),e=this.matchAsyncFunction()?this.parseFunctionExpression():this.finalize(i,new o.Identifier(this.nextToken().value));break;case 6:case 8:this.context.strict&&this.lookahead.octal&&this.tolerateUnexpectedToken(this.lookahead,a.Messages.StrictOctalLiteral),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,t=this.nextToken(),n=this.getTokenRaw(t),e=this.finalize(i,new o.Literal(t.value,n));break;case 1:this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,t=this.nextToken(),n=this.getTokenRaw(t),e=this.finalize(i,new o.Literal("true"===t.value,n));break;case 5:this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,t=this.nextToken(),n=this.getTokenRaw(t),e=this.finalize(i,new o.Literal(null,n));break;case 10:e=this.parseTemplateLiteral();break;case 7:switch(this.lookahead.value){case"(":this.context.isBindingElement=!1,e=this.inheritCoverGrammar(this.parseGroupExpression);break;case"[":e=this.inheritCoverGrammar(this.parseArrayInitializer);break;case"{":e=this.inheritCoverGrammar(this.parseObjectInitializer);break;case"/":case"/=":this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,this.scanner.index=this.startMarker.index,t=this.nextRegexToken(),n=this.getTokenRaw(t),e=this.finalize(i,new o.RegexLiteral(t.regex,n,t.pattern,t.flags));break;default:e=this.throwUnexpectedToken(this.nextToken())}break;case 4:!this.context.strict&&this.context.allowYield&&this.matchKeyword("yield")?e=this.parseIdentifierName():!this.context.strict&&this.matchKeyword("let")?e=this.finalize(i,new o.Identifier(this.nextToken().value)):(this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,this.matchKeyword("function")?e=this.parseFunctionExpression():this.matchKeyword("this")?(this.nextToken(),e=this.finalize(i,new o.ThisExpression)):e=this.matchKeyword("class")?this.parseClassExpression():this.throwUnexpectedToken(this.nextToken()));break;default:e=this.throwUnexpectedToken(this.nextToken())}return e},e.prototype.parseSpreadElement=function(){var e=this.createNode();this.expect("...");var t=this.inheritCoverGrammar(this.parseAssignmentExpression);return this.finalize(e,new o.SpreadElement(t))},e.prototype.parseArrayInitializer=function(){var e=this.createNode(),t=[];for(this.expect("[");!this.match("]");)if(this.match(","))this.nextToken(),t.push(null);else if(this.match("...")){var n=this.parseSpreadElement();this.match("]")||(this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,this.expect(",")),t.push(n)}else t.push(this.inheritCoverGrammar(this.parseAssignmentExpression)),this.match("]")||this.expect(",");return this.expect("]"),this.finalize(e,new o.ArrayExpression(t))},e.prototype.parsePropertyMethod=function(e){this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;var t=this.context.strict,n=this.context.allowStrictDirective;this.context.allowStrictDirective=e.simple;var i=this.isolateCoverGrammar(this.parseFunctionSourceElements);return this.context.strict&&e.firstRestricted&&this.tolerateUnexpectedToken(e.firstRestricted,e.message),this.context.strict&&e.stricted&&this.tolerateUnexpectedToken(e.stricted,e.message),this.context.strict=t,this.context.allowStrictDirective=n,i},e.prototype.parsePropertyMethodFunction=function(){var e=this.createNode(),t=this.context.allowYield;this.context.allowYield=!0;var n=this.parseFormalParameters(),i=this.parsePropertyMethod(n);return this.context.allowYield=t,this.finalize(e,new o.FunctionExpression(null,n.params,i,!1))},e.prototype.parsePropertyMethodAsyncFunction=function(){var e=this.createNode(),t=this.context.allowYield,n=this.context.await;this.context.allowYield=!1,this.context.await=!0;var i=this.parseFormalParameters(),r=this.parsePropertyMethod(i);return this.context.allowYield=t,this.context.await=n,this.finalize(e,new o.AsyncFunctionExpression(null,i.params,r))},e.prototype.parseObjectPropertyKey=function(){var e,t=this.createNode(),n=this.nextToken();switch(n.type){case 8:case 6:this.context.strict&&n.octal&&this.tolerateUnexpectedToken(n,a.Messages.StrictOctalLiteral);var i=this.getTokenRaw(n);e=this.finalize(t,new o.Literal(n.value,i));break;case 3:case 1:case 5:case 4:e=this.finalize(t,new o.Identifier(n.value));break;case 7:"["===n.value?(e=this.isolateCoverGrammar(this.parseAssignmentExpression),this.expect("]")):e=this.throwUnexpectedToken(n);break;default:e=this.throwUnexpectedToken(n)}return e},e.prototype.isPropertyKey=function(e,t){return e.type===u.Syntax.Identifier&&e.name===t||e.type===u.Syntax.Literal&&e.value===t},e.prototype.parseObjectProperty=function(e){var t,n=this.createNode(),i=this.lookahead,r=null,s=null,u=!1,l=!1,c=!1,h=!1;if(3===i.type){var d=i.value;this.nextToken(),u=this.match("["),r=(h=!(this.hasLineTerminator||"async"!==d||this.match(":")||this.match("(")||this.match("*")||this.match(",")))?this.parseObjectPropertyKey():this.finalize(n,new o.Identifier(d))}else this.match("*")?this.nextToken():(u=this.match("["),r=this.parseObjectPropertyKey());var p=this.qualifiedPropertyName(this.lookahead);if(3===i.type&&!h&&"get"===i.value&&p)t="get",u=this.match("["),r=this.parseObjectPropertyKey(),this.context.allowYield=!1,s=this.parseGetterMethod();else if(3===i.type&&!h&&"set"===i.value&&p)t="set",u=this.match("["),r=this.parseObjectPropertyKey(),s=this.parseSetterMethod();else if(7===i.type&&"*"===i.value&&p)t="init",u=this.match("["),r=this.parseObjectPropertyKey(),s=this.parseGeneratorMethod(),l=!0;else if(r||this.throwUnexpectedToken(this.lookahead),t="init",this.match(":")&&!h)!u&&this.isPropertyKey(r,"__proto__")&&(e.value&&this.tolerateError(a.Messages.DuplicateProtoProperty),e.value=!0),this.nextToken(),s=this.inheritCoverGrammar(this.parseAssignmentExpression);else if(this.match("("))s=h?this.parsePropertyMethodAsyncFunction():this.parsePropertyMethodFunction(),l=!0;else if(3===i.type)if(d=this.finalize(n,new o.Identifier(i.value)),this.match("=")){this.context.firstCoverInitializedNameError=this.lookahead,this.nextToken(),c=!0;var f=this.isolateCoverGrammar(this.parseAssignmentExpression);s=this.finalize(n,new o.AssignmentPattern(d,f))}else c=!0,s=d;else this.throwUnexpectedToken(this.nextToken());return this.finalize(n,new o.Property(t,r,u,s,l,c))},e.prototype.parseObjectInitializer=function(){var e=this.createNode();this.expect("{");for(var t=[],n={value:!1};!this.match("}");)t.push(this.parseObjectProperty(n)),this.match("}")||this.expectCommaSeparator();return this.expect("}"),this.finalize(e,new o.ObjectExpression(t))},e.prototype.parseTemplateHead=function(){i.assert(this.lookahead.head,"Template literal must start with a template head");var e=this.createNode(),t=this.nextToken(),n=t.value,r=t.cooked;return this.finalize(e,new o.TemplateElement({raw:n,cooked:r},t.tail))},e.prototype.parseTemplateElement=function(){10!==this.lookahead.type&&this.throwUnexpectedToken();var e=this.createNode(),t=this.nextToken(),n=t.value,i=t.cooked;return this.finalize(e,new o.TemplateElement({raw:n,cooked:i},t.tail))},e.prototype.parseTemplateLiteral=function(){var e=this.createNode(),t=[],n=[],i=this.parseTemplateHead();for(n.push(i);!i.tail;)t.push(this.parseExpression()),i=this.parseTemplateElement(),n.push(i);return this.finalize(e,new o.TemplateLiteral(n,t))},e.prototype.reinterpretExpressionAsPattern=function(e){switch(e.type){case u.Syntax.Identifier:case u.Syntax.MemberExpression:case u.Syntax.RestElement:case u.Syntax.AssignmentPattern:break;case u.Syntax.SpreadElement:e.type=u.Syntax.RestElement,this.reinterpretExpressionAsPattern(e.argument);break;case u.Syntax.ArrayExpression:e.type=u.Syntax.ArrayPattern;for(var t=0;t<e.elements.length;t++)null!==e.elements[t]&&this.reinterpretExpressionAsPattern(e.elements[t]);break;case u.Syntax.ObjectExpression:for(e.type=u.Syntax.ObjectPattern,t=0;t<e.properties.length;t++)this.reinterpretExpressionAsPattern(e.properties[t].value);break;case u.Syntax.AssignmentExpression:e.type=u.Syntax.AssignmentPattern,delete e.operator,this.reinterpretExpressionAsPattern(e.left)}},e.prototype.parseGroupExpression=function(){var e;if(this.expect("("),this.match(")"))this.nextToken(),this.match("=>")||this.expect("=>"),e={type:c,params:[],async:!1};else{var t=this.lookahead,n=[];if(this.match("..."))e=this.parseRestElement(n),this.expect(")"),this.match("=>")||this.expect("=>"),e={type:c,params:[e],async:!1};else{var i=!1;if(this.context.isBindingElement=!0,e=this.inheritCoverGrammar(this.parseAssignmentExpression),this.match(",")){var r=[];for(this.context.isAssignmentTarget=!1,r.push(e);2!==this.lookahead.type&&this.match(",");){if(this.nextToken(),this.match(")")){this.nextToken();for(var a=0;a<r.length;a++)this.reinterpretExpressionAsPattern(r[a]);i=!0,e={type:c,params:r,async:!1}}else if(this.match("...")){for(this.context.isBindingElement||this.throwUnexpectedToken(this.lookahead),r.push(this.parseRestElement(n)),this.expect(")"),this.match("=>")||this.expect("=>"),this.context.isBindingElement=!1,a=0;a<r.length;a++)this.reinterpretExpressionAsPattern(r[a]);i=!0,e={type:c,params:r,async:!1}}else r.push(this.inheritCoverGrammar(this.parseAssignmentExpression));if(i)break}i||(e=this.finalize(this.startNode(t),new o.SequenceExpression(r)))}if(!i){if(this.expect(")"),this.match("=>")&&(e.type===u.Syntax.Identifier&&"yield"===e.name&&(i=!0,e={type:c,params:[e],async:!1}),!i)){if(this.context.isBindingElement||this.throwUnexpectedToken(this.lookahead),e.type===u.Syntax.SequenceExpression)for(a=0;a<e.expressions.length;a++)this.reinterpretExpressionAsPattern(e.expressions[a]);else this.reinterpretExpressionAsPattern(e);var s=e.type===u.Syntax.SequenceExpression?e.expressions:[e];e={type:c,params:s,async:!1}}this.context.isBindingElement=!1}}}return e},e.prototype.parseArguments=function(){this.expect("(");var e=[];if(!this.match(")"))for(;;){var t=this.match("...")?this.parseSpreadElement():this.isolateCoverGrammar(this.parseAssignmentExpression);if(e.push(t),this.match(")"))break;if(this.expectCommaSeparator(),this.match(")"))break}return this.expect(")"),e},e.prototype.isIdentifierName=function(e){return 3===e.type||4===e.type||1===e.type||5===e.type},e.prototype.parseIdentifierName=function(){var e=this.createNode(),t=this.nextToken();return this.isIdentifierName(t)||this.throwUnexpectedToken(t),this.finalize(e,new o.Identifier(t.value))},e.prototype.parseNewExpression=function(){var e,t=this.createNode(),n=this.parseIdentifierName();if(i.assert("new"===n.name,"New expression must start with `new`"),this.match("."))if(this.nextToken(),3===this.lookahead.type&&this.context.inFunctionBody&&"target"===this.lookahead.value){var r=this.parseIdentifierName();e=new o.MetaProperty(n,r)}else this.throwUnexpectedToken(this.lookahead);else{var a=this.isolateCoverGrammar(this.parseLeftHandSideExpression),s=this.match("(")?this.parseArguments():[];e=new o.NewExpression(a,s),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1}return this.finalize(t,e)},e.prototype.parseAsyncArgument=function(){var e=this.parseAssignmentExpression();return this.context.firstCoverInitializedNameError=null,e},e.prototype.parseAsyncArguments=function(){this.expect("(");var e=[];if(!this.match(")"))for(;;){var t=this.match("...")?this.parseSpreadElement():this.isolateCoverGrammar(this.parseAsyncArgument);if(e.push(t),this.match(")"))break;if(this.expectCommaSeparator(),this.match(")"))break}return this.expect(")"),e},e.prototype.parseLeftHandSideExpressionAllowCall=function(){var e,t=this.lookahead,n=this.matchContextualKeyword("async"),i=this.context.allowIn;for(this.context.allowIn=!0,this.matchKeyword("super")&&this.context.inFunctionBody?(e=this.createNode(),this.nextToken(),e=this.finalize(e,new o.Super),this.match("(")||this.match(".")||this.match("[")||this.throwUnexpectedToken(this.lookahead)):e=this.inheritCoverGrammar(this.matchKeyword("new")?this.parseNewExpression:this.parsePrimaryExpression);;)if(this.match(".")){this.context.isBindingElement=!1,this.context.isAssignmentTarget=!0,this.expect(".");var r=this.parseIdentifierName();e=this.finalize(this.startNode(t),new o.StaticMemberExpression(e,r))}else if(this.match("(")){var a=n&&t.lineNumber===this.lookahead.lineNumber;this.context.isBindingElement=!1,this.context.isAssignmentTarget=!1;var s=a?this.parseAsyncArguments():this.parseArguments();if(e=this.finalize(this.startNode(t),new o.CallExpression(e,s)),a&&this.match("=>")){for(var u=0;u<s.length;++u)this.reinterpretExpressionAsPattern(s[u]);e={type:c,params:s,async:!0}}}else if(this.match("["))this.context.isBindingElement=!1,this.context.isAssignmentTarget=!0,this.expect("["),r=this.isolateCoverGrammar(this.parseExpression),this.expect("]"),e=this.finalize(this.startNode(t),new o.ComputedMemberExpression(e,r));else{if(10!==this.lookahead.type||!this.lookahead.head)break;var l=this.parseTemplateLiteral();e=this.finalize(this.startNode(t),new o.TaggedTemplateExpression(e,l))}return this.context.allowIn=i,e},e.prototype.parseSuper=function(){var e=this.createNode();return this.expectKeyword("super"),this.match("[")||this.match(".")||this.throwUnexpectedToken(this.lookahead),this.finalize(e,new o.Super)},e.prototype.parseLeftHandSideExpression=function(){i.assert(this.context.allowIn,"callee of new expression always allow in keyword.");for(var e=this.startNode(this.lookahead),t=this.matchKeyword("super")&&this.context.inFunctionBody?this.parseSuper():this.inheritCoverGrammar(this.matchKeyword("new")?this.parseNewExpression:this.parsePrimaryExpression);;)if(this.match("[")){this.context.isBindingElement=!1,this.context.isAssignmentTarget=!0,this.expect("[");var n=this.isolateCoverGrammar(this.parseExpression);this.expect("]"),t=this.finalize(e,new o.ComputedMemberExpression(t,n))}else if(this.match("."))this.context.isBindingElement=!1,this.context.isAssignmentTarget=!0,this.expect("."),n=this.parseIdentifierName(),t=this.finalize(e,new o.StaticMemberExpression(t,n));else{if(10!==this.lookahead.type||!this.lookahead.head)break;var r=this.parseTemplateLiteral();t=this.finalize(e,new o.TaggedTemplateExpression(t,r))}return t},e.prototype.parseUpdateExpression=function(){var e,t=this.lookahead;if(this.match("++")||this.match("--")){var n=this.startNode(t),i=this.nextToken();e=this.inheritCoverGrammar(this.parseUnaryExpression),this.context.strict&&e.type===u.Syntax.Identifier&&this.scanner.isRestrictedWord(e.name)&&this.tolerateError(a.Messages.StrictLHSPrefix),this.context.isAssignmentTarget||this.tolerateError(a.Messages.InvalidLHSInAssignment);var r=!0;e=this.finalize(n,new o.UpdateExpression(i.value,e,r)),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1}else if(e=this.inheritCoverGrammar(this.parseLeftHandSideExpressionAllowCall),!this.hasLineTerminator&&7===this.lookahead.type&&(this.match("++")||this.match("--"))){this.context.strict&&e.type===u.Syntax.Identifier&&this.scanner.isRestrictedWord(e.name)&&this.tolerateError(a.Messages.StrictLHSPostfix),this.context.isAssignmentTarget||this.tolerateError(a.Messages.InvalidLHSInAssignment),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;var s=this.nextToken().value;r=!1,e=this.finalize(this.startNode(t),new o.UpdateExpression(s,e,r))}return e},e.prototype.parseAwaitExpression=function(){var e=this.createNode();this.nextToken();var t=this.parseUnaryExpression();return this.finalize(e,new o.AwaitExpression(t))},e.prototype.parseUnaryExpression=function(){var e;if(this.match("+")||this.match("-")||this.match("~")||this.match("!")||this.matchKeyword("delete")||this.matchKeyword("void")||this.matchKeyword("typeof")){var t=this.startNode(this.lookahead),n=this.nextToken();e=this.inheritCoverGrammar(this.parseUnaryExpression),e=this.finalize(t,new o.UnaryExpression(n.value,e)),this.context.strict&&"delete"===e.operator&&e.argument.type===u.Syntax.Identifier&&this.tolerateError(a.Messages.StrictDelete),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1}else e=this.context.await&&this.matchContextualKeyword("await")?this.parseAwaitExpression():this.parseUpdateExpression();return e},e.prototype.parseExponentiationExpression=function(){var e=this.lookahead,t=this.inheritCoverGrammar(this.parseUnaryExpression);if(t.type!==u.Syntax.UnaryExpression&&this.match("**")){this.nextToken(),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;var n=t,i=this.isolateCoverGrammar(this.parseExponentiationExpression);t=this.finalize(this.startNode(e),new o.BinaryExpression("**",n,i))}return t},e.prototype.binaryPrecedence=function(e){var t=e.value;return 7===e.type?this.operatorPrecedence[t]||0:4===e.type&&("instanceof"===t||this.context.allowIn&&"in"===t)?7:0},e.prototype.parseBinaryExpression=function(){var e=this.lookahead,t=this.inheritCoverGrammar(this.parseExponentiationExpression),n=this.lookahead,i=this.binaryPrecedence(n);if(i>0){this.nextToken(),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;for(var r=[e,this.lookahead],a=t,s=this.isolateCoverGrammar(this.parseExponentiationExpression),u=[a,n.value,s],l=[i];!((i=this.binaryPrecedence(this.lookahead))<=0);){for(;u.length>2&&i<=l[l.length-1];){s=u.pop();var c=u.pop();l.pop(),a=u.pop(),r.pop();var h=this.startNode(r[r.length-1]);u.push(this.finalize(h,new o.BinaryExpression(c,a,s)))}u.push(this.nextToken().value),l.push(i),r.push(this.lookahead),u.push(this.isolateCoverGrammar(this.parseExponentiationExpression))}var d=u.length-1;t=u[d];for(var p=r.pop();d>1;){var f=r.pop(),m=p&&p.lineStart;h=this.startNode(f,m),c=u[d-1],t=this.finalize(h,new o.BinaryExpression(c,u[d-2],t)),d-=2,p=f}}return t},e.prototype.parseConditionalExpression=function(){var e=this.lookahead,t=this.inheritCoverGrammar(this.parseBinaryExpression);if(this.match("?")){this.nextToken();var n=this.context.allowIn;this.context.allowIn=!0;var i=this.isolateCoverGrammar(this.parseAssignmentExpression);this.context.allowIn=n,this.expect(":");var r=this.isolateCoverGrammar(this.parseAssignmentExpression);t=this.finalize(this.startNode(e),new o.ConditionalExpression(t,i,r)),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1}return t},e.prototype.checkPatternParam=function(e,t){switch(t.type){case u.Syntax.Identifier:this.validateParam(e,t,t.name);break;case u.Syntax.RestElement:this.checkPatternParam(e,t.argument);break;case u.Syntax.AssignmentPattern:this.checkPatternParam(e,t.left);break;case u.Syntax.ArrayPattern:for(var n=0;n<t.elements.length;n++)null!==t.elements[n]&&this.checkPatternParam(e,t.elements[n]);break;case u.Syntax.ObjectPattern:for(n=0;n<t.properties.length;n++)this.checkPatternParam(e,t.properties[n].value)}e.simple=e.simple&&t instanceof o.Identifier},e.prototype.reinterpretAsCoverFormalsList=function(e){var t,n=[e],i=!1;switch(e.type){case u.Syntax.Identifier:break;case c:n=e.params,i=e.async;break;default:return null}t={simple:!0,paramSet:{}};for(var r=0;r<n.length;++r)(o=n[r]).type===u.Syntax.AssignmentPattern?o.right.type===u.Syntax.YieldExpression&&(o.right.argument&&this.throwUnexpectedToken(this.lookahead),o.right.type=u.Syntax.Identifier,o.right.name="yield",delete o.right.argument,delete o.right.delegate):i&&o.type===u.Syntax.Identifier&&"await"===o.name&&this.throwUnexpectedToken(this.lookahead),this.checkPatternParam(t,o),n[r]=o;if(this.context.strict||!this.context.allowYield)for(r=0;r<n.length;++r){var o;(o=n[r]).type===u.Syntax.YieldExpression&&this.throwUnexpectedToken(this.lookahead)}if(t.message===a.Messages.StrictParamDupe){var s=this.context.strict?t.stricted:t.firstRestricted;this.throwUnexpectedToken(s,t.message)}return{simple:t.simple,params:n,stricted:t.stricted,firstRestricted:t.firstRestricted,message:t.message}},e.prototype.parseAssignmentExpression=function(){var e;if(!this.context.allowYield&&this.matchKeyword("yield"))e=this.parseYieldExpression();else{var t=this.lookahead,n=t;if(e=this.parseConditionalExpression(),3===n.type&&n.lineNumber===this.lookahead.lineNumber&&"async"===n.value&&(3===this.lookahead.type||this.matchKeyword("yield"))){var i=this.parsePrimaryExpression();this.reinterpretExpressionAsPattern(i),e={type:c,params:[i],async:!0}}if(e.type===c||this.match("=>")){this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;var r=e.async,s=this.reinterpretAsCoverFormalsList(e);if(s){this.hasLineTerminator&&this.tolerateUnexpectedToken(this.lookahead),this.context.firstCoverInitializedNameError=null;var l=this.context.strict,h=this.context.allowStrictDirective;this.context.allowStrictDirective=s.simple;var d=this.context.allowYield,p=this.context.await;this.context.allowYield=!0,this.context.await=r;var f=this.startNode(t);this.expect("=>");var m=void 0;if(this.match("{")){var g=this.context.allowIn;this.context.allowIn=!0,m=this.parseFunctionSourceElements(),this.context.allowIn=g}else m=this.isolateCoverGrammar(this.parseAssignmentExpression);var v=m.type!==u.Syntax.BlockStatement;this.context.strict&&s.firstRestricted&&this.throwUnexpectedToken(s.firstRestricted,s.message),this.context.strict&&s.stricted&&this.tolerateUnexpectedToken(s.stricted,s.message),e=r?this.finalize(f,new o.AsyncArrowFunctionExpression(s.params,m,v)):this.finalize(f,new o.ArrowFunctionExpression(s.params,m,v)),this.context.strict=l,this.context.allowStrictDirective=h,this.context.allowYield=d,this.context.await=p}}else if(this.matchAssign()){if(this.context.isAssignmentTarget||this.tolerateError(a.Messages.InvalidLHSInAssignment),this.context.strict&&e.type===u.Syntax.Identifier){var y=e;this.scanner.isRestrictedWord(y.name)&&this.tolerateUnexpectedToken(n,a.Messages.StrictLHSAssignment),this.scanner.isStrictModeReservedWord(y.name)&&this.tolerateUnexpectedToken(n,a.Messages.StrictReservedWord)}this.match("=")?this.reinterpretExpressionAsPattern(e):(this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1);var b=(n=this.nextToken()).value,x=this.isolateCoverGrammar(this.parseAssignmentExpression);e=this.finalize(this.startNode(t),new o.AssignmentExpression(b,e,x)),this.context.firstCoverInitializedNameError=null}}return e},e.prototype.parseExpression=function(){var e=this.lookahead,t=this.isolateCoverGrammar(this.parseAssignmentExpression);if(this.match(",")){var n=[];for(n.push(t);2!==this.lookahead.type&&this.match(",");)this.nextToken(),n.push(this.isolateCoverGrammar(this.parseAssignmentExpression));t=this.finalize(this.startNode(e),new o.SequenceExpression(n))}return t},e.prototype.parseStatementListItem=function(){var e;if(this.context.isAssignmentTarget=!0,this.context.isBindingElement=!0,4===this.lookahead.type)switch(this.lookahead.value){case"export":this.context.isModule||this.tolerateUnexpectedToken(this.lookahead,a.Messages.IllegalExportDeclaration),e=this.parseExportDeclaration();break;case"import":this.context.isModule||this.tolerateUnexpectedToken(this.lookahead,a.Messages.IllegalImportDeclaration),e=this.parseImportDeclaration();break;case"const":e=this.parseLexicalDeclaration({inFor:!1});break;case"function":e=this.parseFunctionDeclaration();break;case"class":e=this.parseClassDeclaration();break;case"let":e=this.isLexicalDeclaration()?this.parseLexicalDeclaration({inFor:!1}):this.parseStatement();break;default:e=this.parseStatement()}else e=this.parseStatement();return e},e.prototype.parseBlock=function(){var e=this.createNode();this.expect("{");for(var t=[];!this.match("}");)t.push(this.parseStatementListItem());return this.expect("}"),this.finalize(e,new o.BlockStatement(t))},e.prototype.parseLexicalBinding=function(e,t){var n=this.createNode(),i=this.parsePattern([],e);this.context.strict&&i.type===u.Syntax.Identifier&&this.scanner.isRestrictedWord(i.name)&&this.tolerateError(a.Messages.StrictVarName);var r=null;return"const"===e?this.matchKeyword("in")||this.matchContextualKeyword("of")||(this.match("=")?(this.nextToken(),r=this.isolateCoverGrammar(this.parseAssignmentExpression)):this.throwError(a.Messages.DeclarationMissingInitializer,"const")):(!t.inFor&&i.type!==u.Syntax.Identifier||this.match("="))&&(this.expect("="),r=this.isolateCoverGrammar(this.parseAssignmentExpression)),this.finalize(n,new o.VariableDeclarator(i,r))},e.prototype.parseBindingList=function(e,t){for(var n=[this.parseLexicalBinding(e,t)];this.match(",");)this.nextToken(),n.push(this.parseLexicalBinding(e,t));return n},e.prototype.isLexicalDeclaration=function(){var e=this.scanner.saveState();this.scanner.scanComments();var t=this.scanner.lex();return this.scanner.restoreState(e),3===t.type||7===t.type&&"["===t.value||7===t.type&&"{"===t.value||4===t.type&&"let"===t.value||4===t.type&&"yield"===t.value},e.prototype.parseLexicalDeclaration=function(e){var t=this.createNode(),n=this.nextToken().value;i.assert("let"===n||"const"===n,"Lexical declaration must be either let or const");var r=this.parseBindingList(n,e);return this.consumeSemicolon(),this.finalize(t,new o.VariableDeclaration(r,n))},e.prototype.parseBindingRestElement=function(e,t){var n=this.createNode();this.expect("...");var i=this.parsePattern(e,t);return this.finalize(n,new o.RestElement(i))},e.prototype.parseArrayPattern=function(e,t){var n=this.createNode();this.expect("[");for(var i=[];!this.match("]");)if(this.match(","))this.nextToken(),i.push(null);else{if(this.match("...")){i.push(this.parseBindingRestElement(e,t));break}i.push(this.parsePatternWithDefault(e,t)),this.match("]")||this.expect(",")}return this.expect("]"),this.finalize(n,new o.ArrayPattern(i))},e.prototype.parsePropertyPattern=function(e,t){var n,i,r=this.createNode(),a=!1,s=!1;if(3===this.lookahead.type){var u=this.lookahead;n=this.parseVariableIdentifier();var l=this.finalize(r,new o.Identifier(u.value));if(this.match("=")){e.push(u),s=!0,this.nextToken();var c=this.parseAssignmentExpression();i=this.finalize(this.startNode(u),new o.AssignmentPattern(l,c))}else this.match(":")?(this.expect(":"),i=this.parsePatternWithDefault(e,t)):(e.push(u),s=!0,i=l)}else a=this.match("["),n=this.parseObjectPropertyKey(),this.expect(":"),i=this.parsePatternWithDefault(e,t);return this.finalize(r,new o.Property("init",n,a,i,!1,s))},e.prototype.parseObjectPattern=function(e,t){var n=this.createNode(),i=[];for(this.expect("{");!this.match("}");)i.push(this.parsePropertyPattern(e,t)),this.match("}")||this.expect(",");return this.expect("}"),this.finalize(n,new o.ObjectPattern(i))},e.prototype.parsePattern=function(e,t){var n;return this.match("[")?n=this.parseArrayPattern(e,t):this.match("{")?n=this.parseObjectPattern(e,t):(!this.matchKeyword("let")||"const"!==t&&"let"!==t||this.tolerateUnexpectedToken(this.lookahead,a.Messages.LetInLexicalBinding),e.push(this.lookahead),n=this.parseVariableIdentifier(t)),n},e.prototype.parsePatternWithDefault=function(e,t){var n=this.lookahead,i=this.parsePattern(e,t);if(this.match("=")){this.nextToken();var r=this.context.allowYield;this.context.allowYield=!0;var a=this.isolateCoverGrammar(this.parseAssignmentExpression);this.context.allowYield=r,i=this.finalize(this.startNode(n),new o.AssignmentPattern(i,a))}return i},e.prototype.parseVariableIdentifier=function(e){var t=this.createNode(),n=this.nextToken();return 4===n.type&&"yield"===n.value?this.context.strict?this.tolerateUnexpectedToken(n,a.Messages.StrictReservedWord):this.context.allowYield||this.throwUnexpectedToken(n):3!==n.type?this.context.strict&&4===n.type&&this.scanner.isStrictModeReservedWord(n.value)?this.tolerateUnexpectedToken(n,a.Messages.StrictReservedWord):(this.context.strict||"let"!==n.value||"var"!==e)&&this.throwUnexpectedToken(n):(this.context.isModule||this.context.await)&&3===n.type&&"await"===n.value&&this.tolerateUnexpectedToken(n),this.finalize(t,new o.Identifier(n.value))},e.prototype.parseVariableDeclaration=function(e){var t=this.createNode(),n=this.parsePattern([],"var");this.context.strict&&n.type===u.Syntax.Identifier&&this.scanner.isRestrictedWord(n.name)&&this.tolerateError(a.Messages.StrictVarName);var i=null;return this.match("=")?(this.nextToken(),i=this.isolateCoverGrammar(this.parseAssignmentExpression)):n.type===u.Syntax.Identifier||e.inFor||this.expect("="),this.finalize(t,new o.VariableDeclarator(n,i))},e.prototype.parseVariableDeclarationList=function(e){var t={inFor:e.inFor},n=[];for(n.push(this.parseVariableDeclaration(t));this.match(",");)this.nextToken(),n.push(this.parseVariableDeclaration(t));return n},e.prototype.parseVariableStatement=function(){var e=this.createNode();this.expectKeyword("var");var t=this.parseVariableDeclarationList({inFor:!1});return this.consumeSemicolon(),this.finalize(e,new o.VariableDeclaration(t,"var"))},e.prototype.parseEmptyStatement=function(){var e=this.createNode();return this.expect(";"),this.finalize(e,new o.EmptyStatement)},e.prototype.parseExpressionStatement=function(){var e=this.createNode(),t=this.parseExpression();return this.consumeSemicolon(),this.finalize(e,new o.ExpressionStatement(t))},e.prototype.parseIfClause=function(){return this.context.strict&&this.matchKeyword("function")&&this.tolerateError(a.Messages.StrictFunction),this.parseStatement()},e.prototype.parseIfStatement=function(){var e,t=this.createNode(),n=null;this.expectKeyword("if"),this.expect("(");var i=this.parseExpression();return!this.match(")")&&this.config.tolerant?(this.tolerateUnexpectedToken(this.nextToken()),e=this.finalize(this.createNode(),new o.EmptyStatement)):(this.expect(")"),e=this.parseIfClause(),this.matchKeyword("else")&&(this.nextToken(),n=this.parseIfClause())),this.finalize(t,new o.IfStatement(i,e,n))},e.prototype.parseDoWhileStatement=function(){var e=this.createNode();this.expectKeyword("do");var t=this.context.inIteration;this.context.inIteration=!0;var n=this.parseStatement();this.context.inIteration=t,this.expectKeyword("while"),this.expect("(");var i=this.parseExpression();return!this.match(")")&&this.config.tolerant?this.tolerateUnexpectedToken(this.nextToken()):(this.expect(")"),this.match(";")&&this.nextToken()),this.finalize(e,new o.DoWhileStatement(n,i))},e.prototype.parseWhileStatement=function(){var e,t=this.createNode();this.expectKeyword("while"),this.expect("(");var n=this.parseExpression();if(!this.match(")")&&this.config.tolerant)this.tolerateUnexpectedToken(this.nextToken()),e=this.finalize(this.createNode(),new o.EmptyStatement);else{this.expect(")");var i=this.context.inIteration;this.context.inIteration=!0,e=this.parseStatement(),this.context.inIteration=i}return this.finalize(t,new o.WhileStatement(n,e))},e.prototype.parseForStatement=function(){var e,t,n,i=null,r=null,s=null,l=!0,c=this.createNode();if(this.expectKeyword("for"),this.expect("("),this.match(";"))this.nextToken();else if(this.matchKeyword("var")){i=this.createNode(),this.nextToken();var h=this.context.allowIn;this.context.allowIn=!1;var d=this.parseVariableDeclarationList({inFor:!0});if(this.context.allowIn=h,1===d.length&&this.matchKeyword("in")){var p=d[0];p.init&&(p.id.type===u.Syntax.ArrayPattern||p.id.type===u.Syntax.ObjectPattern||this.context.strict)&&this.tolerateError(a.Messages.ForInOfLoopInitializer,"for-in"),i=this.finalize(i,new o.VariableDeclaration(d,"var")),this.nextToken(),e=i,t=this.parseExpression(),i=null}else 1===d.length&&null===d[0].init&&this.matchContextualKeyword("of")?(i=this.finalize(i,new o.VariableDeclaration(d,"var")),this.nextToken(),e=i,t=this.parseAssignmentExpression(),i=null,l=!1):(i=this.finalize(i,new o.VariableDeclaration(d,"var")),this.expect(";"))}else if(this.matchKeyword("const")||this.matchKeyword("let")){i=this.createNode();var f=this.nextToken().value;this.context.strict||"in"!==this.lookahead.value?(h=this.context.allowIn,this.context.allowIn=!1,d=this.parseBindingList(f,{inFor:!0}),this.context.allowIn=h,1===d.length&&null===d[0].init&&this.matchKeyword("in")?(i=this.finalize(i,new o.VariableDeclaration(d,f)),this.nextToken(),e=i,t=this.parseExpression(),i=null):1===d.length&&null===d[0].init&&this.matchContextualKeyword("of")?(i=this.finalize(i,new o.VariableDeclaration(d,f)),this.nextToken(),e=i,t=this.parseAssignmentExpression(),i=null,l=!1):(this.consumeSemicolon(),i=this.finalize(i,new o.VariableDeclaration(d,f)))):(i=this.finalize(i,new o.Identifier(f)),this.nextToken(),e=i,t=this.parseExpression(),i=null)}else{var m=this.lookahead;if(h=this.context.allowIn,this.context.allowIn=!1,i=this.inheritCoverGrammar(this.parseAssignmentExpression),this.context.allowIn=h,this.matchKeyword("in"))this.context.isAssignmentTarget&&i.type!==u.Syntax.AssignmentExpression||this.tolerateError(a.Messages.InvalidLHSInForIn),this.nextToken(),this.reinterpretExpressionAsPattern(i),e=i,t=this.parseExpression(),i=null;else if(this.matchContextualKeyword("of"))this.context.isAssignmentTarget&&i.type!==u.Syntax.AssignmentExpression||this.tolerateError(a.Messages.InvalidLHSInForLoop),this.nextToken(),this.reinterpretExpressionAsPattern(i),e=i,t=this.parseAssignmentExpression(),i=null,l=!1;else{if(this.match(",")){for(var g=[i];this.match(",");)this.nextToken(),g.push(this.isolateCoverGrammar(this.parseAssignmentExpression));i=this.finalize(this.startNode(m),new o.SequenceExpression(g))}this.expect(";")}}if(void 0===e&&(this.match(";")||(r=this.parseExpression()),this.expect(";"),this.match(")")||(s=this.parseExpression())),!this.match(")")&&this.config.tolerant)this.tolerateUnexpectedToken(this.nextToken()),n=this.finalize(this.createNode(),new o.EmptyStatement);else{this.expect(")");var v=this.context.inIteration;this.context.inIteration=!0,n=this.isolateCoverGrammar(this.parseStatement),this.context.inIteration=v}return void 0===e?this.finalize(c,new o.ForStatement(i,r,s,n)):l?this.finalize(c,new o.ForInStatement(e,t,n)):this.finalize(c,new o.ForOfStatement(e,t,n))},e.prototype.parseContinueStatement=function(){var e=this.createNode();this.expectKeyword("continue");var t=null;if(3===this.lookahead.type&&!this.hasLineTerminator){var n=this.parseVariableIdentifier();t=n;var i="$"+n.name;Object.prototype.hasOwnProperty.call(this.context.labelSet,i)||this.throwError(a.Messages.UnknownLabel,n.name)}return this.consumeSemicolon(),null!==t||this.context.inIteration||this.throwError(a.Messages.IllegalContinue),this.finalize(e,new o.ContinueStatement(t))},e.prototype.parseBreakStatement=function(){var e=this.createNode();this.expectKeyword("break");var t=null;if(3===this.lookahead.type&&!this.hasLineTerminator){var n=this.parseVariableIdentifier(),i="$"+n.name;Object.prototype.hasOwnProperty.call(this.context.labelSet,i)||this.throwError(a.Messages.UnknownLabel,n.name),t=n}return this.consumeSemicolon(),null!==t||this.context.inIteration||this.context.inSwitch||this.throwError(a.Messages.IllegalBreak),this.finalize(e,new o.BreakStatement(t))},e.prototype.parseReturnStatement=function(){this.context.inFunctionBody||this.tolerateError(a.Messages.IllegalReturn);var e=this.createNode();this.expectKeyword("return");var t=(this.match(";")||this.match("}")||this.hasLineTerminator||2===this.lookahead.type)&&8!==this.lookahead.type&&10!==this.lookahead.type?null:this.parseExpression();return this.consumeSemicolon(),this.finalize(e,new o.ReturnStatement(t))},e.prototype.parseWithStatement=function(){this.context.strict&&this.tolerateError(a.Messages.StrictModeWith);var e,t=this.createNode();this.expectKeyword("with"),this.expect("(");var n=this.parseExpression();return!this.match(")")&&this.config.tolerant?(this.tolerateUnexpectedToken(this.nextToken()),e=this.finalize(this.createNode(),new o.EmptyStatement)):(this.expect(")"),e=this.parseStatement()),this.finalize(t,new o.WithStatement(n,e))},e.prototype.parseSwitchCase=function(){var e,t=this.createNode();this.matchKeyword("default")?(this.nextToken(),e=null):(this.expectKeyword("case"),e=this.parseExpression()),this.expect(":");for(var n=[];!(this.match("}")||this.matchKeyword("default")||this.matchKeyword("case"));)n.push(this.parseStatementListItem());return this.finalize(t,new o.SwitchCase(e,n))},e.prototype.parseSwitchStatement=function(){var e=this.createNode();this.expectKeyword("switch"),this.expect("(");var t=this.parseExpression();this.expect(")");var n=this.context.inSwitch;this.context.inSwitch=!0;var i=[],r=!1;for(this.expect("{");!this.match("}");){var s=this.parseSwitchCase();null===s.test&&(r&&this.throwError(a.Messages.MultipleDefaultsInSwitch),r=!0),i.push(s)}return this.expect("}"),this.context.inSwitch=n,this.finalize(e,new o.SwitchStatement(t,i))},e.prototype.parseLabelledStatement=function(){var e,t=this.createNode(),n=this.parseExpression();if(n.type===u.Syntax.Identifier&&this.match(":")){this.nextToken();var i=n,r="$"+i.name;Object.prototype.hasOwnProperty.call(this.context.labelSet,r)&&this.throwError(a.Messages.Redeclaration,"Label",i.name),this.context.labelSet[r]=!0;var s=void 0;if(this.matchKeyword("class"))this.tolerateUnexpectedToken(this.lookahead),s=this.parseClassDeclaration();else if(this.matchKeyword("function")){var l=this.lookahead,c=this.parseFunctionDeclaration();this.context.strict?this.tolerateUnexpectedToken(l,a.Messages.StrictFunction):c.generator&&this.tolerateUnexpectedToken(l,a.Messages.GeneratorInLegacyContext),s=c}else s=this.parseStatement();delete this.context.labelSet[r],e=new o.LabeledStatement(i,s)}else this.consumeSemicolon(),e=new o.ExpressionStatement(n);return this.finalize(t,e)},e.prototype.parseThrowStatement=function(){var e=this.createNode();this.expectKeyword("throw"),this.hasLineTerminator&&this.throwError(a.Messages.NewlineAfterThrow);var t=this.parseExpression();return this.consumeSemicolon(),this.finalize(e,new o.ThrowStatement(t))},e.prototype.parseCatchClause=function(){var e=this.createNode();this.expectKeyword("catch"),this.expect("("),this.match(")")&&this.throwUnexpectedToken(this.lookahead);for(var t=[],n=this.parsePattern(t),i={},r=0;r<t.length;r++){var s="$"+t[r].value;Object.prototype.hasOwnProperty.call(i,s)&&this.tolerateError(a.Messages.DuplicateBinding,t[r].value),i[s]=!0}this.context.strict&&n.type===u.Syntax.Identifier&&this.scanner.isRestrictedWord(n.name)&&this.tolerateError(a.Messages.StrictCatchVariable),this.expect(")");var l=this.parseBlock();return this.finalize(e,new o.CatchClause(n,l))},e.prototype.parseFinallyClause=function(){return this.expectKeyword("finally"),this.parseBlock()},e.prototype.parseTryStatement=function(){var e=this.createNode();this.expectKeyword("try");var t=this.parseBlock(),n=this.matchKeyword("catch")?this.parseCatchClause():null,i=this.matchKeyword("finally")?this.parseFinallyClause():null;return n||i||this.throwError(a.Messages.NoCatchOrFinally),this.finalize(e,new o.TryStatement(t,n,i))},e.prototype.parseDebuggerStatement=function(){var e=this.createNode();return this.expectKeyword("debugger"),this.consumeSemicolon(),this.finalize(e,new o.DebuggerStatement)},e.prototype.parseStatement=function(){var e;switch(this.lookahead.type){case 1:case 5:case 6:case 8:case 10:case 9:e=this.parseExpressionStatement();break;case 7:var t=this.lookahead.value;e="{"===t?this.parseBlock():"("===t?this.parseExpressionStatement():";"===t?this.parseEmptyStatement():this.parseExpressionStatement();break;case 3:e=this.matchAsyncFunction()?this.parseFunctionDeclaration():this.parseLabelledStatement();break;case 4:switch(this.lookahead.value){case"break":e=this.parseBreakStatement();break;case"continue":e=this.parseContinueStatement();break;case"debugger":e=this.parseDebuggerStatement();break;case"do":e=this.parseDoWhileStatement();break;case"for":e=this.parseForStatement();break;case"function":e=this.parseFunctionDeclaration();break;case"if":e=this.parseIfStatement();break;case"return":e=this.parseReturnStatement();break;case"switch":e=this.parseSwitchStatement();break;case"throw":e=this.parseThrowStatement();break;case"try":e=this.parseTryStatement();break;case"var":e=this.parseVariableStatement();break;case"while":e=this.parseWhileStatement();break;case"with":e=this.parseWithStatement();break;default:e=this.parseExpressionStatement()}break;default:e=this.throwUnexpectedToken(this.lookahead)}return e},e.prototype.parseFunctionSourceElements=function(){var e=this.createNode();this.expect("{");var t=this.parseDirectivePrologues(),n=this.context.labelSet,i=this.context.inIteration,r=this.context.inSwitch,a=this.context.inFunctionBody;for(this.context.labelSet={},this.context.inIteration=!1,this.context.inSwitch=!1,this.context.inFunctionBody=!0;2!==this.lookahead.type&&!this.match("}");)t.push(this.parseStatementListItem());return this.expect("}"),this.context.labelSet=n,this.context.inIteration=i,this.context.inSwitch=r,this.context.inFunctionBody=a,this.finalize(e,new o.BlockStatement(t))},e.prototype.validateParam=function(e,t,n){var i="$"+n;this.context.strict?(this.scanner.isRestrictedWord(n)&&(e.stricted=t,e.message=a.Messages.StrictParamName),Object.prototype.hasOwnProperty.call(e.paramSet,i)&&(e.stricted=t,e.message=a.Messages.StrictParamDupe)):e.firstRestricted||(this.scanner.isRestrictedWord(n)?(e.firstRestricted=t,e.message=a.Messages.StrictParamName):this.scanner.isStrictModeReservedWord(n)?(e.firstRestricted=t,e.message=a.Messages.StrictReservedWord):Object.prototype.hasOwnProperty.call(e.paramSet,i)&&(e.stricted=t,e.message=a.Messages.StrictParamDupe)),"function"==typeof Object.defineProperty?Object.defineProperty(e.paramSet,i,{value:!0,enumerable:!0,writable:!0,configurable:!0}):e.paramSet[i]=!0},e.prototype.parseRestElement=function(e){var t=this.createNode();this.expect("...");var n=this.parsePattern(e);return this.match("=")&&this.throwError(a.Messages.DefaultRestParameter),this.match(")")||this.throwError(a.Messages.ParameterAfterRestParameter),this.finalize(t,new o.RestElement(n))},e.prototype.parseFormalParameter=function(e){for(var t=[],n=this.match("...")?this.parseRestElement(t):this.parsePatternWithDefault(t),i=0;i<t.length;i++)this.validateParam(e,t[i],t[i].value);e.simple=e.simple&&n instanceof o.Identifier,e.params.push(n)},e.prototype.parseFormalParameters=function(e){var t;if(t={simple:!0,params:[],firstRestricted:e},this.expect("("),!this.match(")"))for(t.paramSet={};2!==this.lookahead.type&&(this.parseFormalParameter(t),!this.match(")"))&&(this.expect(","),!this.match(")")););return this.expect(")"),{simple:t.simple,params:t.params,stricted:t.stricted,firstRestricted:t.firstRestricted,message:t.message}},e.prototype.matchAsyncFunction=function(){var e=this.matchContextualKeyword("async");if(e){var t=this.scanner.saveState();this.scanner.scanComments();var n=this.scanner.lex();this.scanner.restoreState(t),e=t.lineNumber===n.lineNumber&&4===n.type&&"function"===n.value}return e},e.prototype.parseFunctionDeclaration=function(e){var t=this.createNode(),n=this.matchContextualKeyword("async");n&&this.nextToken(),this.expectKeyword("function");var i,r=!n&&this.match("*");r&&this.nextToken();var s=null,u=null;if(!e||!this.match("(")){var l=this.lookahead;s=this.parseVariableIdentifier(),this.context.strict?this.scanner.isRestrictedWord(l.value)&&this.tolerateUnexpectedToken(l,a.Messages.StrictFunctionName):this.scanner.isRestrictedWord(l.value)?(u=l,i=a.Messages.StrictFunctionName):this.scanner.isStrictModeReservedWord(l.value)&&(u=l,i=a.Messages.StrictReservedWord)}var c=this.context.await,h=this.context.allowYield;this.context.await=n,this.context.allowYield=!r;var d=this.parseFormalParameters(u),p=d.params,f=d.stricted;u=d.firstRestricted,d.message&&(i=d.message);var m=this.context.strict,g=this.context.allowStrictDirective;this.context.allowStrictDirective=d.simple;var v=this.parseFunctionSourceElements();return this.context.strict&&u&&this.throwUnexpectedToken(u,i),this.context.strict&&f&&this.tolerateUnexpectedToken(f,i),this.context.strict=m,this.context.allowStrictDirective=g,this.context.await=c,this.context.allowYield=h,n?this.finalize(t,new o.AsyncFunctionDeclaration(s,p,v)):this.finalize(t,new o.FunctionDeclaration(s,p,v,r))},e.prototype.parseFunctionExpression=function(){var e=this.createNode(),t=this.matchContextualKeyword("async");t&&this.nextToken(),this.expectKeyword("function");var n,i=!t&&this.match("*");i&&this.nextToken();var r,s=null,u=this.context.await,l=this.context.allowYield;if(this.context.await=t,this.context.allowYield=!i,!this.match("(")){var c=this.lookahead;s=this.context.strict||i||!this.matchKeyword("yield")?this.parseVariableIdentifier():this.parseIdentifierName(),this.context.strict?this.scanner.isRestrictedWord(c.value)&&this.tolerateUnexpectedToken(c,a.Messages.StrictFunctionName):this.scanner.isRestrictedWord(c.value)?(r=c,n=a.Messages.StrictFunctionName):this.scanner.isStrictModeReservedWord(c.value)&&(r=c,n=a.Messages.StrictReservedWord)}var h=this.parseFormalParameters(r),d=h.params,p=h.stricted;r=h.firstRestricted,h.message&&(n=h.message);var f=this.context.strict,m=this.context.allowStrictDirective;this.context.allowStrictDirective=h.simple;var g=this.parseFunctionSourceElements();return this.context.strict&&r&&this.throwUnexpectedToken(r,n),this.context.strict&&p&&this.tolerateUnexpectedToken(p,n),this.context.strict=f,this.context.allowStrictDirective=m,this.context.await=u,this.context.allowYield=l,t?this.finalize(e,new o.AsyncFunctionExpression(s,d,g)):this.finalize(e,new o.FunctionExpression(s,d,g,i))},e.prototype.parseDirective=function(){var e=this.lookahead,t=this.createNode(),n=this.parseExpression(),i=n.type===u.Syntax.Literal?this.getTokenRaw(e).slice(1,-1):null;return this.consumeSemicolon(),this.finalize(t,i?new o.Directive(n,i):new o.ExpressionStatement(n))},e.prototype.parseDirectivePrologues=function(){for(var e=null,t=[];;){var n=this.lookahead;if(8!==n.type)break;var i=this.parseDirective();t.push(i);var r=i.directive;if("string"!=typeof r)break;"use strict"===r?(this.context.strict=!0,e&&this.tolerateUnexpectedToken(e,a.Messages.StrictOctalLiteral),this.context.allowStrictDirective||this.tolerateUnexpectedToken(n,a.Messages.IllegalLanguageModeDirective)):!e&&n.octal&&(e=n)}return t},e.prototype.qualifiedPropertyName=function(e){switch(e.type){case 3:case 8:case 1:case 5:case 6:case 4:return!0;case 7:return"["===e.value}return!1},e.prototype.parseGetterMethod=function(){var e=this.createNode(),t=!1,n=this.context.allowYield;this.context.allowYield=!0;var i=this.parseFormalParameters();i.params.length>0&&this.tolerateError(a.Messages.BadGetterArity);var r=this.parsePropertyMethod(i);return this.context.allowYield=n,this.finalize(e,new o.FunctionExpression(null,i.params,r,t))},e.prototype.parseSetterMethod=function(){var e=this.createNode(),t=!1,n=this.context.allowYield;this.context.allowYield=!0;var i=this.parseFormalParameters();1!==i.params.length?this.tolerateError(a.Messages.BadSetterArity):i.params[0]instanceof o.RestElement&&this.tolerateError(a.Messages.BadSetterRestParameter);var r=this.parsePropertyMethod(i);return this.context.allowYield=n,this.finalize(e,new o.FunctionExpression(null,i.params,r,t))},e.prototype.parseGeneratorMethod=function(){var e=this.createNode(),t=this.context.allowYield;this.context.allowYield=!0;var n=this.parseFormalParameters();this.context.allowYield=!1;var i=this.parsePropertyMethod(n);return this.context.allowYield=t,this.finalize(e,new o.FunctionExpression(null,n.params,i,!0))},e.prototype.isStartOfExpression=function(){var e=!0,t=this.lookahead.value;switch(this.lookahead.type){case 7:e="["===t||"("===t||"{"===t||"+"===t||"-"===t||"!"===t||"~"===t||"++"===t||"--"===t||"/"===t||"/="===t;break;case 4:e="class"===t||"delete"===t||"function"===t||"let"===t||"new"===t||"super"===t||"this"===t||"typeof"===t||"void"===t||"yield"===t}return e},e.prototype.parseYieldExpression=function(){var e=this.createNode();this.expectKeyword("yield");var t=null,n=!1;if(!this.hasLineTerminator){var i=this.context.allowYield;this.context.allowYield=!1,(n=this.match("*"))?(this.nextToken(),t=this.parseAssignmentExpression()):this.isStartOfExpression()&&(t=this.parseAssignmentExpression()),this.context.allowYield=i}return this.finalize(e,new o.YieldExpression(t,n))},e.prototype.parseClassElement=function(e){var t=this.lookahead,n=this.createNode(),i="",r=null,s=null,u=!1,l=!1,c=!1,h=!1;if(this.match("*"))this.nextToken();else if(u=this.match("["),"static"===(r=this.parseObjectPropertyKey()).name&&(this.qualifiedPropertyName(this.lookahead)||this.match("*"))&&(t=this.lookahead,c=!0,u=this.match("["),this.match("*")?this.nextToken():r=this.parseObjectPropertyKey()),3===t.type&&!this.hasLineTerminator&&"async"===t.value){var d=this.lookahead.value;":"!==d&&"("!==d&&"*"!==d&&(h=!0,t=this.lookahead,r=this.parseObjectPropertyKey(),3===t.type&&"constructor"===t.value&&this.tolerateUnexpectedToken(t,a.Messages.ConstructorIsAsync))}var p=this.qualifiedPropertyName(this.lookahead);return 3===t.type?"get"===t.value&&p?(i="get",u=this.match("["),r=this.parseObjectPropertyKey(),this.context.allowYield=!1,s=this.parseGetterMethod()):"set"===t.value&&p&&(i="set",u=this.match("["),r=this.parseObjectPropertyKey(),s=this.parseSetterMethod()):7===t.type&&"*"===t.value&&p&&(i="init",u=this.match("["),r=this.parseObjectPropertyKey(),s=this.parseGeneratorMethod(),l=!0),!i&&r&&this.match("(")&&(i="init",s=h?this.parsePropertyMethodAsyncFunction():this.parsePropertyMethodFunction(),l=!0),i||this.throwUnexpectedToken(this.lookahead),"init"===i&&(i="method"),u||(c&&this.isPropertyKey(r,"prototype")&&this.throwUnexpectedToken(t,a.Messages.StaticPrototype),!c&&this.isPropertyKey(r,"constructor")&&(("method"!==i||!l||s&&s.generator)&&this.throwUnexpectedToken(t,a.Messages.ConstructorSpecialMethod),e.value?this.throwUnexpectedToken(t,a.Messages.DuplicateConstructor):e.value=!0,i="constructor")),this.finalize(n,new o.MethodDefinition(r,u,s,i,c))},e.prototype.parseClassElementList=function(){var e=[],t={value:!1};for(this.expect("{");!this.match("}");)this.match(";")?this.nextToken():e.push(this.parseClassElement(t));return this.expect("}"),e},e.prototype.parseClassBody=function(){var e=this.createNode(),t=this.parseClassElementList();return this.finalize(e,new o.ClassBody(t))},e.prototype.parseClassDeclaration=function(e){var t=this.createNode(),n=this.context.strict;this.context.strict=!0,this.expectKeyword("class");var i=e&&3!==this.lookahead.type?null:this.parseVariableIdentifier(),r=null;this.matchKeyword("extends")&&(this.nextToken(),r=this.isolateCoverGrammar(this.parseLeftHandSideExpressionAllowCall));var a=this.parseClassBody();return this.context.strict=n,this.finalize(t,new o.ClassDeclaration(i,r,a))},e.prototype.parseClassExpression=function(){var e=this.createNode(),t=this.context.strict;this.context.strict=!0,this.expectKeyword("class");var n=3===this.lookahead.type?this.parseVariableIdentifier():null,i=null;this.matchKeyword("extends")&&(this.nextToken(),i=this.isolateCoverGrammar(this.parseLeftHandSideExpressionAllowCall));var r=this.parseClassBody();return this.context.strict=t,this.finalize(e,new o.ClassExpression(n,i,r))},e.prototype.parseModule=function(){this.context.strict=!0,this.context.isModule=!0,this.scanner.isModule=!0;for(var e=this.createNode(),t=this.parseDirectivePrologues();2!==this.lookahead.type;)t.push(this.parseStatementListItem());return this.finalize(e,new o.Module(t))},e.prototype.parseScript=function(){for(var e=this.createNode(),t=this.parseDirectivePrologues();2!==this.lookahead.type;)t.push(this.parseStatementListItem());return this.finalize(e,new o.Script(t))},e.prototype.parseModuleSpecifier=function(){var e=this.createNode();8!==this.lookahead.type&&this.throwError(a.Messages.InvalidModuleSpecifier);var t=this.nextToken(),n=this.getTokenRaw(t);return this.finalize(e,new o.Literal(t.value,n))},e.prototype.parseImportSpecifier=function(){var e,t,n=this.createNode();return 3===this.lookahead.type?(t=e=this.parseVariableIdentifier(),this.matchContextualKeyword("as")&&(this.nextToken(),t=this.parseVariableIdentifier())):(t=e=this.parseIdentifierName(),this.matchContextualKeyword("as")?(this.nextToken(),t=this.parseVariableIdentifier()):this.throwUnexpectedToken(this.nextToken())),this.finalize(n,new o.ImportSpecifier(t,e))},e.prototype.parseNamedImports=function(){this.expect("{");for(var e=[];!this.match("}");)e.push(this.parseImportSpecifier()),this.match("}")||this.expect(",");return this.expect("}"),e},e.prototype.parseImportDefaultSpecifier=function(){var e=this.createNode(),t=this.parseIdentifierName();return this.finalize(e,new o.ImportDefaultSpecifier(t))},e.prototype.parseImportNamespaceSpecifier=function(){var e=this.createNode();this.expect("*"),this.matchContextualKeyword("as")||this.throwError(a.Messages.NoAsAfterImportNamespace),this.nextToken();var t=this.parseIdentifierName();return this.finalize(e,new o.ImportNamespaceSpecifier(t))},e.prototype.parseImportDeclaration=function(){this.context.inFunctionBody&&this.throwError(a.Messages.IllegalImportDeclaration);var e,t=this.createNode();this.expectKeyword("import");var n=[];if(8===this.lookahead.type)e=this.parseModuleSpecifier();else{if(this.match("{")?n=n.concat(this.parseNamedImports()):this.match("*")?n.push(this.parseImportNamespaceSpecifier()):this.isIdentifierName(this.lookahead)&&!this.matchKeyword("default")?(n.push(this.parseImportDefaultSpecifier()),this.match(",")&&(this.nextToken(),this.match("*")?n.push(this.parseImportNamespaceSpecifier()):this.match("{")?n=n.concat(this.parseNamedImports()):this.throwUnexpectedToken(this.lookahead))):this.throwUnexpectedToken(this.nextToken()),!this.matchContextualKeyword("from")){var i=this.lookahead.value?a.Messages.UnexpectedToken:a.Messages.MissingFromClause;this.throwError(i,this.lookahead.value)}this.nextToken(),e=this.parseModuleSpecifier()}return this.consumeSemicolon(),this.finalize(t,new o.ImportDeclaration(n,e))},e.prototype.parseExportSpecifier=function(){var e=this.createNode(),t=this.parseIdentifierName(),n=t;return this.matchContextualKeyword("as")&&(this.nextToken(),n=this.parseIdentifierName()),this.finalize(e,new o.ExportSpecifier(t,n))},e.prototype.parseExportDeclaration=function(){this.context.inFunctionBody&&this.throwError(a.Messages.IllegalExportDeclaration);var e,t=this.createNode();if(this.expectKeyword("export"),this.matchKeyword("default"))if(this.nextToken(),this.matchKeyword("function")){var n=this.parseFunctionDeclaration(!0);e=this.finalize(t,new o.ExportDefaultDeclaration(n))}else this.matchKeyword("class")?(n=this.parseClassDeclaration(!0),e=this.finalize(t,new o.ExportDefaultDeclaration(n))):this.matchContextualKeyword("async")?(n=this.matchAsyncFunction()?this.parseFunctionDeclaration(!0):this.parseAssignmentExpression(),e=this.finalize(t,new o.ExportDefaultDeclaration(n))):(this.matchContextualKeyword("from")&&this.throwError(a.Messages.UnexpectedToken,this.lookahead.value),n=this.match("{")?this.parseObjectInitializer():this.match("[")?this.parseArrayInitializer():this.parseAssignmentExpression(),this.consumeSemicolon(),e=this.finalize(t,new o.ExportDefaultDeclaration(n)));else if(this.match("*")){if(this.nextToken(),!this.matchContextualKeyword("from")){var i=this.lookahead.value?a.Messages.UnexpectedToken:a.Messages.MissingFromClause;this.throwError(i,this.lookahead.value)}this.nextToken();var r=this.parseModuleSpecifier();this.consumeSemicolon(),e=this.finalize(t,new o.ExportAllDeclaration(r))}else if(4===this.lookahead.type){switch(n=void 0,this.lookahead.value){case"let":case"const":n=this.parseLexicalDeclaration({inFor:!1});break;case"var":case"class":case"function":n=this.parseStatementListItem();break;default:this.throwUnexpectedToken(this.lookahead)}e=this.finalize(t,new o.ExportNamedDeclaration(n,[],null))}else if(this.matchAsyncFunction())n=this.parseFunctionDeclaration(),e=this.finalize(t,new o.ExportNamedDeclaration(n,[],null));else{var s=[],u=null,l=!1;for(this.expect("{");!this.match("}");)l=l||this.matchKeyword("default"),s.push(this.parseExportSpecifier()),this.match("}")||this.expect(",");this.expect("}"),this.matchContextualKeyword("from")?(this.nextToken(),u=this.parseModuleSpecifier(),this.consumeSemicolon()):l?(i=this.lookahead.value?a.Messages.UnexpectedToken:a.Messages.MissingFromClause,this.throwError(i,this.lookahead.value)):this.consumeSemicolon(),e=this.finalize(t,new o.ExportNamedDeclaration(null,s,u))}return e},e}();t.Parser=h},function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.assert=function(e,t){if(!e)throw new Error("ASSERT: "+t)}},function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(){this.errors=[],this.tolerant=!1}return e.prototype.recordError=function(e){this.errors.push(e)},e.prototype.tolerate=function(e){if(!this.tolerant)throw e;this.recordError(e)},e.prototype.constructError=function(e,t){var n=new Error(e);try{throw n}catch(e){Object.create&&Object.defineProperty&&(n=Object.create(e),Object.defineProperty(n,"column",{value:t}))}return n},e.prototype.createError=function(e,t,n,i){var r="Line "+t+": "+i,a=this.constructError(r,n);return a.index=e,a.lineNumber=t,a.description=i,a},e.prototype.throwError=function(e,t,n,i){throw this.createError(e,t,n,i)},e.prototype.tolerateError=function(e,t,n,i){var r=this.createError(e,t,n,i);if(!this.tolerant)throw r;this.recordError(r)},e}();t.ErrorHandler=n},function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.Messages={BadGetterArity:"Getter must not have any formal parameters",BadSetterArity:"Setter must have exactly one formal parameter",BadSetterRestParameter:"Setter function argument must not be a rest parameter",ConstructorIsAsync:"Class constructor may not be an async method",ConstructorSpecialMethod:"Class constructor may not be an accessor",DeclarationMissingInitializer:"Missing initializer in %0 declaration",DefaultRestParameter:"Unexpected token =",DuplicateBinding:"Duplicate binding %0",DuplicateConstructor:"A class may only have one constructor",DuplicateProtoProperty:"Duplicate __proto__ fields are not allowed in object literals",ForInOfLoopInitializer:"%0 loop variable declaration may not have an initializer",GeneratorInLegacyContext:"Generator declarations are not allowed in legacy contexts",IllegalBreak:"Illegal break statement",IllegalContinue:"Illegal continue statement",IllegalExportDeclaration:"Unexpected token",IllegalImportDeclaration:"Unexpected token",IllegalLanguageModeDirective:"Illegal 'use strict' directive in function with non-simple parameter list",IllegalReturn:"Illegal return statement",InvalidEscapedReservedWord:"Keyword must not contain escaped characters",InvalidHexEscapeSequence:"Invalid hexadecimal escape sequence",InvalidLHSInAssignment:"Invalid left-hand side in assignment",InvalidLHSInForIn:"Invalid left-hand side in for-in",InvalidLHSInForLoop:"Invalid left-hand side in for-loop",InvalidModuleSpecifier:"Unexpected token",InvalidRegExp:"Invalid regular expression",LetInLexicalBinding:"let is disallowed as a lexically bound name",MissingFromClause:"Unexpected token",MultipleDefaultsInSwitch:"More than one default clause in switch statement",NewlineAfterThrow:"Illegal newline after throw",NoAsAfterImportNamespace:"Unexpected token",NoCatchOrFinally:"Missing catch or finally after try",ParameterAfterRestParameter:"Rest parameter must be last formal parameter",Redeclaration:"%0 '%1' has already been declared",StaticPrototype:"Classes may not have static property named prototype",StrictCatchVariable:"Catch variable may not be eval or arguments in strict mode",StrictDelete:"Delete of an unqualified identifier in strict mode.",StrictFunction:"In strict mode code, functions can only be declared at top level or inside a block",StrictFunctionName:"Function name may not be eval or arguments in strict mode",StrictLHSAssignment:"Assignment to eval or arguments is not allowed in strict mode",StrictLHSPostfix:"Postfix increment/decrement may not have eval or arguments operand in strict mode",StrictLHSPrefix:"Prefix increment/decrement may not have eval or arguments operand in strict mode",StrictModeWith:"Strict mode code may not include a with statement",StrictOctalLiteral:"Octal literals are not allowed in strict mode.",StrictParamDupe:"Strict mode function may not have duplicate parameter names",StrictParamName:"Parameter name eval or arguments is not allowed in strict mode",StrictReservedWord:"Use of future reserved word in strict mode",StrictVarName:"Variable name may not be eval or arguments in strict mode",TemplateOctalLiteral:"Octal literals are not allowed in template strings.",UnexpectedEOS:"Unexpected end of input",UnexpectedIdentifier:"Unexpected identifier",UnexpectedNumber:"Unexpected number",UnexpectedReserved:"Unexpected reserved word",UnexpectedString:"Unexpected string",UnexpectedTemplate:"Unexpected quasi %0",UnexpectedToken:"Unexpected token %0",UnexpectedTokenIllegal:"Unexpected token ILLEGAL",UnknownLabel:"Undefined label '%0'",UnterminatedRegExp:"Invalid regular expression: missing /"}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var i=n(9),r=n(4),a=n(11);function o(e){return"0123456789abcdef".indexOf(e.toLowerCase())}function s(e){return"01234567".indexOf(e)}var u=function(){function e(e,t){this.source=e,this.errorHandler=t,this.trackComment=!1,this.isModule=!1,this.length=e.length,this.index=0,this.lineNumber=e.length>0?1:0,this.lineStart=0,this.curlyStack=[]}return e.prototype.saveState=function(){return{index:this.index,lineNumber:this.lineNumber,lineStart:this.lineStart}},e.prototype.restoreState=function(e){this.index=e.index,this.lineNumber=e.lineNumber,this.lineStart=e.lineStart},e.prototype.eof=function(){return this.index>=this.length},e.prototype.throwUnexpectedToken=function(e){return void 0===e&&(e=a.Messages.UnexpectedTokenIllegal),this.errorHandler.throwError(this.index,this.lineNumber,this.index-this.lineStart+1,e)},e.prototype.tolerateUnexpectedToken=function(e){void 0===e&&(e=a.Messages.UnexpectedTokenIllegal),this.errorHandler.tolerateError(this.index,this.lineNumber,this.index-this.lineStart+1,e)},e.prototype.skipSingleLineComment=function(e){var t,n,i=[];for(this.trackComment&&(i=[],t=this.index-e,n={start:{line:this.lineNumber,column:this.index-this.lineStart-e},end:{}});!this.eof();){var a=this.source.charCodeAt(this.index);if(++this.index,r.Character.isLineTerminator(a)){if(this.trackComment){n.end={line:this.lineNumber,column:this.index-this.lineStart-1};var o={multiLine:!1,slice:[t+e,this.index-1],range:[t,this.index-1],loc:n};i.push(o)}return 13===a&&10===this.source.charCodeAt(this.index)&&++this.index,++this.lineNumber,this.lineStart=this.index,i}}return this.trackComment&&(n.end={line:this.lineNumber,column:this.index-this.lineStart},o={multiLine:!1,slice:[t+e,this.index],range:[t,this.index],loc:n},i.push(o)),i},e.prototype.skipMultiLineComment=function(){var e,t,n=[];for(this.trackComment&&(n=[],e=this.index-2,t={start:{line:this.lineNumber,column:this.index-this.lineStart-2},end:{}});!this.eof();){var i=this.source.charCodeAt(this.index);if(r.Character.isLineTerminator(i))13===i&&10===this.source.charCodeAt(this.index+1)&&++this.index,++this.lineNumber,++this.index,this.lineStart=this.index;else if(42===i){if(47===this.source.charCodeAt(this.index+1)){if(this.index+=2,this.trackComment){t.end={line:this.lineNumber,column:this.index-this.lineStart};var a={multiLine:!0,slice:[e+2,this.index-2],range:[e,this.index],loc:t};n.push(a)}return n}++this.index}else++this.index}return this.trackComment&&(t.end={line:this.lineNumber,column:this.index-this.lineStart},a={multiLine:!0,slice:[e+2,this.index],range:[e,this.index],loc:t},n.push(a)),this.tolerateUnexpectedToken(),n},e.prototype.scanComments=function(){var e;this.trackComment&&(e=[]);for(var t=0===this.index;!this.eof();){var n=this.source.charCodeAt(this.index);if(r.Character.isWhiteSpace(n))++this.index;else if(r.Character.isLineTerminator(n))++this.index,13===n&&10===this.source.charCodeAt(this.index)&&++this.index,++this.lineNumber,this.lineStart=this.index,t=!0;else if(47===n)if(47===(n=this.source.charCodeAt(this.index+1))){this.index+=2;var i=this.skipSingleLineComment(2);this.trackComment&&(e=e.concat(i)),t=!0}else{if(42!==n)break;this.index+=2,i=this.skipMultiLineComment(),this.trackComment&&(e=e.concat(i))}else if(t&&45===n){if(45!==this.source.charCodeAt(this.index+1)||62!==this.source.charCodeAt(this.index+2))break;this.index+=3,i=this.skipSingleLineComment(3),this.trackComment&&(e=e.concat(i))}else{if(60!==n||this.isModule)break;if("!--"!==this.source.slice(this.index+1,this.index+4))break;this.index+=4,i=this.skipSingleLineComment(4),this.trackComment&&(e=e.concat(i))}}return e},e.prototype.isFutureReservedWord=function(e){switch(e){case"enum":case"export":case"import":case"super":return!0;default:return!1}},e.prototype.isStrictModeReservedWord=function(e){switch(e){case"implements":case"interface":case"package":case"private":case"protected":case"public":case"static":case"yield":case"let":return!0;default:return!1}},e.prototype.isRestrictedWord=function(e){return"eval"===e||"arguments"===e},e.prototype.isKeyword=function(e){switch(e.length){case 2:return"if"===e||"in"===e||"do"===e;case 3:return"var"===e||"for"===e||"new"===e||"try"===e||"let"===e;case 4:return"this"===e||"else"===e||"case"===e||"void"===e||"with"===e||"enum"===e;case 5:return"while"===e||"break"===e||"catch"===e||"throw"===e||"const"===e||"yield"===e||"class"===e||"super"===e;case 6:return"return"===e||"typeof"===e||"delete"===e||"switch"===e||"export"===e||"import"===e;case 7:return"default"===e||"finally"===e||"extends"===e;case 8:return"function"===e||"continue"===e||"debugger"===e;case 10:return"instanceof"===e;default:return!1}},e.prototype.codePointAt=function(e){var t=this.source.charCodeAt(e);if(t>=55296&&t<=56319){var n=this.source.charCodeAt(e+1);n>=56320&&n<=57343&&(t=1024*(t-55296)+n-56320+65536)}return t},e.prototype.scanHexEscape=function(e){for(var t="u"===e?4:2,n=0,i=0;i<t;++i){if(this.eof()||!r.Character.isHexDigit(this.source.charCodeAt(this.index)))return null;n=16*n+o(this.source[this.index++])}return String.fromCharCode(n)},e.prototype.scanUnicodeCodePointEscape=function(){var e=this.source[this.index],t=0;for("}"===e&&this.throwUnexpectedToken();!this.eof()&&(e=this.source[this.index++],r.Character.isHexDigit(e.charCodeAt(0)));)t=16*t+o(e);return(t>1114111||"}"!==e)&&this.throwUnexpectedToken(),r.Character.fromCodePoint(t)},e.prototype.getIdentifier=function(){for(var e=this.index++;!this.eof();){var t=this.source.charCodeAt(this.index);if(92===t)return this.index=e,this.getComplexIdentifier();if(t>=55296&&t<57343)return this.index=e,this.getComplexIdentifier();if(!r.Character.isIdentifierPart(t))break;++this.index}return this.source.slice(e,this.index)},e.prototype.getComplexIdentifier=function(){var e,t=this.codePointAt(this.index),n=r.Character.fromCodePoint(t);for(this.index+=n.length,92===t&&(117!==this.source.charCodeAt(this.index)&&this.throwUnexpectedToken(),++this.index,"{"===this.source[this.index]?(++this.index,e=this.scanUnicodeCodePointEscape()):null!==(e=this.scanHexEscape("u"))&&"\\"!==e&&r.Character.isIdentifierStart(e.charCodeAt(0))||this.throwUnexpectedToken(),n=e);!this.eof()&&(t=this.codePointAt(this.index),r.Character.isIdentifierPart(t));)n+=e=r.Character.fromCodePoint(t),this.index+=e.length,92===t&&(n=n.substr(0,n.length-1),117!==this.source.charCodeAt(this.index)&&this.throwUnexpectedToken(),++this.index,"{"===this.source[this.index]?(++this.index,e=this.scanUnicodeCodePointEscape()):null!==(e=this.scanHexEscape("u"))&&"\\"!==e&&r.Character.isIdentifierPart(e.charCodeAt(0))||this.throwUnexpectedToken(),n+=e);return n},e.prototype.octalToDecimal=function(e){var t="0"!==e,n=s(e);return!this.eof()&&r.Character.isOctalDigit(this.source.charCodeAt(this.index))&&(t=!0,n=8*n+s(this.source[this.index++]),"0123".indexOf(e)>=0&&!this.eof()&&r.Character.isOctalDigit(this.source.charCodeAt(this.index))&&(n=8*n+s(this.source[this.index++]))),{code:n,octal:t}},e.prototype.scanIdentifier=function(){var e,t=this.index,n=92===this.source.charCodeAt(t)?this.getComplexIdentifier():this.getIdentifier();if(3!=(e=1===n.length?3:this.isKeyword(n)?4:"null"===n?5:"true"===n||"false"===n?1:3)&&t+n.length!==this.index){var i=this.index;this.index=t,this.tolerateUnexpectedToken(a.Messages.InvalidEscapedReservedWord),this.index=i}return{type:e,value:n,lineNumber:this.lineNumber,lineStart:this.lineStart,start:t,end:this.index}},e.prototype.scanPunctuator=function(){var e=this.index,t=this.source[this.index];switch(t){case"(":case"{":"{"===t&&this.curlyStack.push("{"),++this.index;break;case".":++this.index,"."===this.source[this.index]&&"."===this.source[this.index+1]&&(this.index+=2,t="...");break;case"}":++this.index,this.curlyStack.pop();break;case")":case";":case",":case"[":case"]":case":":case"?":case"~":++this.index;break;default:">>>="===(t=this.source.substr(this.index,4))?this.index+=4:"==="===(t=t.substr(0,3))||"!=="===t||">>>"===t||"<<="===t||">>="===t||"**="===t?this.index+=3:"&&"===(t=t.substr(0,2))||"||"===t||"=="===t||"!="===t||"+="===t||"-="===t||"*="===t||"/="===t||"++"===t||"--"===t||"<<"===t||">>"===t||"&="===t||"|="===t||"^="===t||"%="===t||"<="===t||">="===t||"=>"===t||"**"===t?this.index+=2:(t=this.source[this.index],"<>=!+-*%&|^/".indexOf(t)>=0&&++this.index)}return this.index===e&&this.throwUnexpectedToken(),{type:7,value:t,lineNumber:this.lineNumber,lineStart:this.lineStart,start:e,end:this.index}},e.prototype.scanHexLiteral=function(e){for(var t="";!this.eof()&&r.Character.isHexDigit(this.source.charCodeAt(this.index));)t+=this.source[this.index++];return 0===t.length&&this.throwUnexpectedToken(),r.Character.isIdentifierStart(this.source.charCodeAt(this.index))&&this.throwUnexpectedToken(),{type:6,value:parseInt("0x"+t,16),lineNumber:this.lineNumber,lineStart:this.lineStart,start:e,end:this.index}},e.prototype.scanBinaryLiteral=function(e){for(var t,n="";!this.eof()&&("0"===(t=this.source[this.index])||"1"===t);)n+=this.source[this.index++];return 0===n.length&&this.throwUnexpectedToken(),this.eof()||(t=this.source.charCodeAt(this.index),(r.Character.isIdentifierStart(t)||r.Character.isDecimalDigit(t))&&this.throwUnexpectedToken()),{type:6,value:parseInt(n,2),lineNumber:this.lineNumber,lineStart:this.lineStart,start:e,end:this.index}},e.prototype.scanOctalLiteral=function(e,t){var n="",i=!1;for(r.Character.isOctalDigit(e.charCodeAt(0))?(i=!0,n="0"+this.source[this.index++]):++this.index;!this.eof()&&r.Character.isOctalDigit(this.source.charCodeAt(this.index));)n+=this.source[this.index++];return i||0!==n.length||this.throwUnexpectedToken(),(r.Character.isIdentifierStart(this.source.charCodeAt(this.index))||r.Character.isDecimalDigit(this.source.charCodeAt(this.index)))&&this.throwUnexpectedToken(),{type:6,value:parseInt(n,8),octal:i,lineNumber:this.lineNumber,lineStart:this.lineStart,start:t,end:this.index}},e.prototype.isImplicitOctalLiteral=function(){for(var e=this.index+1;e<this.length;++e){var t=this.source[e];if("8"===t||"9"===t)return!1;if(!r.Character.isOctalDigit(t.charCodeAt(0)))return!0}return!0},e.prototype.scanNumericLiteral=function(){var e=this.index,t=this.source[e];i.assert(r.Character.isDecimalDigit(t.charCodeAt(0))||"."===t,"Numeric literal must start with a decimal digit or a decimal point");var n="";if("."!==t){if(n=this.source[this.index++],t=this.source[this.index],"0"===n){if("x"===t||"X"===t)return++this.index,this.scanHexLiteral(e);if("b"===t||"B"===t)return++this.index,this.scanBinaryLiteral(e);if("o"===t||"O"===t)return this.scanOctalLiteral(t,e);if(t&&r.Character.isOctalDigit(t.charCodeAt(0))&&this.isImplicitOctalLiteral())return this.scanOctalLiteral(t,e)}for(;r.Character.isDecimalDigit(this.source.charCodeAt(this.index));)n+=this.source[this.index++];t=this.source[this.index]}if("."===t){for(n+=this.source[this.index++];r.Character.isDecimalDigit(this.source.charCodeAt(this.index));)n+=this.source[this.index++];t=this.source[this.index]}if("e"===t||"E"===t)if(n+=this.source[this.index++],"+"!==(t=this.source[this.index])&&"-"!==t||(n+=this.source[this.index++]),r.Character.isDecimalDigit(this.source.charCodeAt(this.index)))for(;r.Character.isDecimalDigit(this.source.charCodeAt(this.index));)n+=this.source[this.index++];else this.throwUnexpectedToken();return r.Character.isIdentifierStart(this.source.charCodeAt(this.index))&&this.throwUnexpectedToken(),{type:6,value:parseFloat(n),lineNumber:this.lineNumber,lineStart:this.lineStart,start:e,end:this.index}},e.prototype.scanStringLiteral=function(){var e=this.index,t=this.source[e];i.assert("'"===t||'"'===t,"String literal must starts with a quote"),++this.index;for(var n=!1,o="";!this.eof();){var s=this.source[this.index++];if(s===t){t="";break}if("\\"===s)if((s=this.source[this.index++])&&r.Character.isLineTerminator(s.charCodeAt(0)))++this.lineNumber,"\r"===s&&"\n"===this.source[this.index]&&++this.index,this.lineStart=this.index;else switch(s){case"u":if("{"===this.source[this.index])++this.index,o+=this.scanUnicodeCodePointEscape();else{var u=this.scanHexEscape(s);null===u&&this.throwUnexpectedToken(),o+=u}break;case"x":var l=this.scanHexEscape(s);null===l&&this.throwUnexpectedToken(a.Messages.InvalidHexEscapeSequence),o+=l;break;case"n":o+="\n";break;case"r":o+="\r";break;case"t":o+="\t";break;case"b":o+="\b";break;case"f":o+="\f";break;case"v":o+="\v";break;case"8":case"9":o+=s,this.tolerateUnexpectedToken();break;default:if(s&&r.Character.isOctalDigit(s.charCodeAt(0))){var c=this.octalToDecimal(s);n=c.octal||n,o+=String.fromCharCode(c.code)}else o+=s}else{if(r.Character.isLineTerminator(s.charCodeAt(0)))break;o+=s}}return""!==t&&(this.index=e,this.throwUnexpectedToken()),{type:8,value:o,octal:n,lineNumber:this.lineNumber,lineStart:this.lineStart,start:e,end:this.index}},e.prototype.scanTemplate=function(){var e="",t=!1,n=this.index,i="`"===this.source[n],o=!1,s=2;for(++this.index;!this.eof();){var u=this.source[this.index++];if("`"===u){s=1,o=!0,t=!0;break}if("$"===u){if("{"===this.source[this.index]){this.curlyStack.push("${"),++this.index,t=!0;break}e+=u}else if("\\"===u)if(u=this.source[this.index++],r.Character.isLineTerminator(u.charCodeAt(0)))++this.lineNumber,"\r"===u&&"\n"===this.source[this.index]&&++this.index,this.lineStart=this.index;else switch(u){case"n":e+="\n";break;case"r":e+="\r";break;case"t":e+="\t";break;case"u":if("{"===this.source[this.index])++this.index,e+=this.scanUnicodeCodePointEscape();else{var l=this.index,c=this.scanHexEscape(u);null!==c?e+=c:(this.index=l,e+=u)}break;case"x":var h=this.scanHexEscape(u);null===h&&this.throwUnexpectedToken(a.Messages.InvalidHexEscapeSequence),e+=h;break;case"b":e+="\b";break;case"f":e+="\f";break;case"v":e+="\v";break;default:"0"===u?(r.Character.isDecimalDigit(this.source.charCodeAt(this.index))&&this.throwUnexpectedToken(a.Messages.TemplateOctalLiteral),e+="\0"):r.Character.isOctalDigit(u.charCodeAt(0))?this.throwUnexpectedToken(a.Messages.TemplateOctalLiteral):e+=u}else r.Character.isLineTerminator(u.charCodeAt(0))?(++this.lineNumber,"\r"===u&&"\n"===this.source[this.index]&&++this.index,this.lineStart=this.index,e+="\n"):e+=u}return t||this.throwUnexpectedToken(),i||this.curlyStack.pop(),{type:10,value:this.source.slice(n+1,this.index-s),cooked:e,head:i,tail:o,lineNumber:this.lineNumber,lineStart:this.lineStart,start:n,end:this.index}},e.prototype.testRegExp=function(e,t){var n=e,i=this;t.indexOf("u")>=0&&(n=n.replace(/\\u\{([0-9a-fA-F]+)\}|\\u([a-fA-F0-9]{4})/g,function(e,t,n){var r=parseInt(t||n,16);return r>1114111&&i.throwUnexpectedToken(a.Messages.InvalidRegExp),r<=65535?String.fromCharCode(r):"\ufffd"}).replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,"\ufffd"));try{RegExp(n)}catch(e){this.throwUnexpectedToken(a.Messages.InvalidRegExp)}try{return new RegExp(e,t)}catch(e){return null}},e.prototype.scanRegExpBody=function(){var e=this.source[this.index];i.assert("/"===e,"Regular expression literal must start with a slash");for(var t=this.source[this.index++],n=!1,o=!1;!this.eof();)if(t+=e=this.source[this.index++],"\\"===e)e=this.source[this.index++],r.Character.isLineTerminator(e.charCodeAt(0))&&this.throwUnexpectedToken(a.Messages.UnterminatedRegExp),t+=e;else if(r.Character.isLineTerminator(e.charCodeAt(0)))this.throwUnexpectedToken(a.Messages.UnterminatedRegExp);else if(n)"]"===e&&(n=!1);else{if("/"===e){o=!0;break}"["===e&&(n=!0)}return o||this.throwUnexpectedToken(a.Messages.UnterminatedRegExp),t.substr(1,t.length-2)},e.prototype.scanRegExpFlags=function(){for(var e="";!this.eof();){var t=this.source[this.index];if(!r.Character.isIdentifierPart(t.charCodeAt(0)))break;if(++this.index,"\\"!==t||this.eof())e+=t;else if("u"===(t=this.source[this.index])){++this.index;var n=this.index,i=this.scanHexEscape("u");if(null!==i)for(e+=i;n<this.index;++n)this.source[n];else this.index=n,e+="u";this.tolerateUnexpectedToken()}else this.tolerateUnexpectedToken()}return e},e.prototype.scanRegExp=function(){var e=this.index,t=this.scanRegExpBody(),n=this.scanRegExpFlags();return{type:9,value:"",pattern:t,flags:n,regex:this.testRegExp(t,n),lineNumber:this.lineNumber,lineStart:this.lineStart,start:e,end:this.index}},e.prototype.lex=function(){if(this.eof())return{type:2,value:"",lineNumber:this.lineNumber,lineStart:this.lineStart,start:this.index,end:this.index};var e=this.source.charCodeAt(this.index);return r.Character.isIdentifierStart(e)?this.scanIdentifier():40===e||41===e||59===e?this.scanPunctuator():39===e||34===e?this.scanStringLiteral():46===e?r.Character.isDecimalDigit(this.source.charCodeAt(this.index+1))?this.scanNumericLiteral():this.scanPunctuator():r.Character.isDecimalDigit(e)?this.scanNumericLiteral():96===e||125===e&&"${"===this.curlyStack[this.curlyStack.length-1]?this.scanTemplate():e>=55296&&e<57343&&r.Character.isIdentifierStart(this.codePointAt(this.index))?this.scanIdentifier():this.scanPunctuator()},e}();t.Scanner=u},function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.TokenName={},t.TokenName[1]="Boolean",t.TokenName[2]="<end>",t.TokenName[3]="Identifier",t.TokenName[4]="Keyword",t.TokenName[5]="Null",t.TokenName[6]="Numeric",t.TokenName[7]="Punctuator",t.TokenName[8]="String",t.TokenName[9]="RegularExpression",t.TokenName[10]="Template"},function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.XHTMLEntities={quot:'"',amp:"&",apos:"'",gt:">",nbsp:" ",iexcl:"¡",cent:"¢",pound:"£",curren:"¤",yen:"¥",brvbar:"¦",sect:"§",uml:"¨",copy:"©",ordf:"ª",laquo:"«",not:"¬",shy:"",reg:"®",macr:"¯",deg:"°",plusmn:"±",sup2:"²",sup3:"³",acute:"´",micro:"µ",para:"¶",middot:"·",cedil:"¸",sup1:"¹",ordm:"º",raquo:"»",frac14:"¼",frac12:"½",frac34:"¾",iquest:"¿",Agrave:"À",Aacute:"Á",Acirc:"Â",Atilde:"Ã",Auml:"Ä",Aring:"Å",AElig:"Æ",Ccedil:"Ç",Egrave:"È",Eacute:"É",Ecirc:"Ê",Euml:"Ë",Igrave:"Ì",Iacute:"Í",Icirc:"Î",Iuml:"Ï",ETH:"Ð",Ntilde:"Ñ",Ograve:"Ò",Oacute:"Ó",Ocirc:"Ô",Otilde:"Õ",Ouml:"Ö",times:"×",Oslash:"Ø",Ugrave:"Ù",Uacute:"Ú",Ucirc:"Û",Uuml:"Ü",Yacute:"Ý",THORN:"Þ",szlig:"ß",agrave:"à",aacute:"á",acirc:"â",atilde:"ã",auml:"ä",aring:"å",aelig:"æ",ccedil:"ç",egrave:"è",eacute:"é",ecirc:"ê",euml:"ë",igrave:"ì",iacute:"í",icirc:"î",iuml:"ï",eth:"ð",ntilde:"ñ",ograve:"ò",oacute:"ó",ocirc:"ô",otilde:"õ",ouml:"ö",divide:"÷",oslash:"ø",ugrave:"ù",uacute:"ú",ucirc:"û",uuml:"ü",yacute:"ý",thorn:"þ",yuml:"ÿ",OElig:"Œ",oelig:"œ",Scaron:"Š",scaron:"š",Yuml:"Ÿ",fnof:"ƒ",circ:"ˆ",tilde:"˜",Alpha:"Α",Beta:"Β",Gamma:"Γ",Delta:"Δ",Epsilon:"Ε",Zeta:"Ζ",Eta:"Η",Theta:"Θ",Iota:"Ι",Kappa:"Κ",Lambda:"Λ",Mu:"Μ",Nu:"Ν",Xi:"Ξ",Omicron:"Ο",Pi:"Π",Rho:"Ρ",Sigma:"Σ",Tau:"Τ",Upsilon:"Υ",Phi:"Φ",Chi:"Χ",Psi:"Ψ",Omega:"Ω",alpha:"α",beta:"β",gamma:"γ",delta:"δ",epsilon:"ε",zeta:"ζ",eta:"η",theta:"θ",iota:"ι",kappa:"κ",lambda:"λ",mu:"μ",nu:"ν",xi:"ξ",omicron:"ο",pi:"π",rho:"ρ",sigmaf:"ς",sigma:"σ",tau:"τ",upsilon:"υ",phi:"φ",chi:"χ",psi:"ψ",omega:"ω",thetasym:"ϑ",upsih:"ϒ",piv:"ϖ",ensp:" ",emsp:" ",thinsp:" ",zwnj:"",zwj:"",lrm:"",rlm:"",ndash:"–",mdash:"—",lsquo:"‘",rsquo:"’",sbquo:"‚",ldquo:"“",rdquo:"”",bdquo:"„",dagger:"†",Dagger:"‡",bull:"•",hellip:"…",permil:"‰",prime:"′",Prime:"″",lsaquo:"‹",rsaquo:"›",oline:"‾",frasl:"⁄",euro:"€",image:"ℑ",weierp:"℘",real:"ℜ",trade:"™",alefsym:"ℵ",larr:"←",uarr:"↑",rarr:"→",darr:"↓",harr:"↔",crarr:"↵",lArr:"⇐",uArr:"⇑",rArr:"⇒",dArr:"⇓",hArr:"⇔",forall:"∀",part:"∂",exist:"∃",empty:"∅",nabla:"∇",isin:"∈",notin:"∉",ni:"∋",prod:"∏",sum:"∑",minus:"−",lowast:"∗",radic:"√",prop:"∝",infin:"∞",ang:"∠",and:"∧",or:"∨",cap:"∩",cup:"∪",int:"∫",there4:"∴",sim:"∼",cong:"≅",asymp:"≈",ne:"≠",equiv:"≡",le:"≤",ge:"≥",sub:"⊂",sup:"⊃",nsub:"⊄",sube:"⊆",supe:"⊇",oplus:"⊕",otimes:"⊗",perp:"⊥",sdot:"⋅",lceil:"⌈",rceil:"⌉",lfloor:"⌊",rfloor:"⌋",loz:"◊",spades:"♠",clubs:"♣",hearts:"♥",diams:"♦",lang:"⟨",rang:"⟩"}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var i=n(10),r=n(12),a=n(13),o=function(){function e(){this.values=[],this.curly=this.paren=-1}return e.prototype.beforeFunctionExpression=function(e){return["(","{","[","in","typeof","instanceof","new","return","case","delete","throw","void","=","+=","-=","*=","**=","/=","%=","<<=",">>=",">>>=","&=","|=","^=",",","+","-","*","**","/","%","++","--","<<",">>",">>>","&","|","^","!","~","&&","||","?",":","===","==",">=","<=","<",">","!=","!=="].indexOf(e)>=0},e.prototype.isRegexStart=function(){var e=this.values[this.values.length-1],t=null!==e;switch(e){case"this":case"]":t=!1;break;case")":var n=this.values[this.paren-1];t="if"===n||"while"===n||"for"===n||"with"===n;break;case"}":if(t=!1,"function"===this.values[this.curly-3])t=!!(i=this.values[this.curly-4])&&!this.beforeFunctionExpression(i);else if("function"===this.values[this.curly-4]){var i;t=!(i=this.values[this.curly-5])||!this.beforeFunctionExpression(i)}}return t},e.prototype.push=function(e){7===e.type||4===e.type?("{"===e.value?this.curly=this.values.length:"("===e.value&&(this.paren=this.values.length),this.values.push(e.value)):this.values.push(null)},e}(),s=function(){function e(e,t){this.errorHandler=new i.ErrorHandler,this.errorHandler.tolerant=!!t&&"boolean"==typeof t.tolerant&&t.tolerant,this.scanner=new r.Scanner(e,this.errorHandler),this.scanner.trackComment=!!t&&"boolean"==typeof t.comment&&t.comment,this.trackRange=!!t&&"boolean"==typeof t.range&&t.range,this.trackLoc=!!t&&"boolean"==typeof t.loc&&t.loc,this.buffer=[],this.reader=new o}return e.prototype.errors=function(){return this.errorHandler.errors},e.prototype.getNextToken=function(){if(0===this.buffer.length){var e=this.scanner.scanComments();if(this.scanner.trackComment)for(var t=0;t<e.length;++t){var n=e[t],i=this.scanner.source.slice(n.slice[0],n.slice[1]),r={type:n.multiLine?"BlockComment":"LineComment",value:i};this.trackRange&&(r.range=n.range),this.trackLoc&&(r.loc=n.loc),this.buffer.push(r)}if(!this.scanner.eof()){var o=void 0;this.trackLoc&&(o={start:{line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart},end:{}});var s="/"===this.scanner.source[this.scanner.index]&&this.reader.isRegexStart()?this.scanner.scanRegExp():this.scanner.lex();this.reader.push(s);var u={type:a.TokenName[s.type],value:this.scanner.source.slice(s.start,s.end)};if(this.trackRange&&(u.range=[s.start,s.end]),this.trackLoc&&(o.end={line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart},u.loc=o),9===s.type){var l=s.pattern,c=s.flags;u.regex={pattern:l,flags:c}}this.buffer.push(u)}}return this.buffer.shift()},e}();t.Tokenizer=s}])},Bu.exports=Iu()),Bu.exports),Nu=e(Ou),Ru={};var Mu=(Lu||(Lu=1,function e(t){var n,i,r,a,o,s;function u(e){var t,n,i={};for(t in e)e.hasOwnProperty(t)&&("object"===T(n=e[t])&&null!==n?i[t]=u(n):i[t]=n);return i}function l(e,t){this.parent=e,this.key=t}function c(e,t,n,i){this.node=e,this.path=t,this.wrap=n,this.ref=i}function h(){}function d(e){return null!=e&&"object"===T(e)&&"string"==typeof e.type}function p(e,t){return(e===n.ObjectExpression||e===n.ObjectPattern)&&"properties"===t}function f(e,t){for(var n=e.length-1;n>=0;--n)if(e[n].node===t)return!0;return!1}function m(e,t){return(new h).traverse(e,t)}function g(e,t){var n;return n=function(e,t){var n,i,r,a;for(i=e.length,r=0;i;)t(e[a=r+(n=i>>>1)])?i=n:(r=a+1,i-=n+1);return r}(t,function(t){return t.range[0]>e.range[0]}),e.extendedRange=[e.range[0],e.range[1]],n!==t.length&&(e.extendedRange[1]=t[n].range[0]),(n-=1)>=0&&(e.extendedRange[0]=t[n].range[1]),e}return n={AssignmentExpression:"AssignmentExpression",AssignmentPattern:"AssignmentPattern",ArrayExpression:"ArrayExpression",ArrayPattern:"ArrayPattern",ArrowFunctionExpression:"ArrowFunctionExpression",AwaitExpression:"AwaitExpression",BlockStatement:"BlockStatement",BinaryExpression:"BinaryExpression",BreakStatement:"BreakStatement",CallExpression:"CallExpression",CatchClause:"CatchClause",ChainExpression:"ChainExpression",ClassBody:"ClassBody",ClassDeclaration:"ClassDeclaration",ClassExpression:"ClassExpression",ComprehensionBlock:"ComprehensionBlock",ComprehensionExpression:"ComprehensionExpression",ConditionalExpression:"ConditionalExpression",ContinueStatement:"ContinueStatement",DebuggerStatement:"DebuggerStatement",DirectiveStatement:"DirectiveStatement",DoWhileStatement:"DoWhileStatement",EmptyStatement:"EmptyStatement",ExportAllDeclaration:"ExportAllDeclaration",ExportDefaultDeclaration:"ExportDefaultDeclaration",ExportNamedDeclaration:"ExportNamedDeclaration",ExportSpecifier:"ExportSpecifier",ExpressionStatement:"ExpressionStatement",ForStatement:"ForStatement",ForInStatement:"ForInStatement",ForOfStatement:"ForOfStatement",FunctionDeclaration:"FunctionDeclaration",FunctionExpression:"FunctionExpression",GeneratorExpression:"GeneratorExpression",Identifier:"Identifier",IfStatement:"IfStatement",ImportExpression:"ImportExpression",ImportDeclaration:"ImportDeclaration",ImportDefaultSpecifier:"ImportDefaultSpecifier",ImportNamespaceSpecifier:"ImportNamespaceSpecifier",ImportSpecifier:"ImportSpecifier",Literal:"Literal",LabeledStatement:"LabeledStatement",LogicalExpression:"LogicalExpression",MemberExpression:"MemberExpression",MetaProperty:"MetaProperty",MethodDefinition:"MethodDefinition",ModuleSpecifier:"ModuleSpecifier",NewExpression:"NewExpression",ObjectExpression:"ObjectExpression",ObjectPattern:"ObjectPattern",PrivateIdentifier:"PrivateIdentifier",Program:"Program",Property:"Property",PropertyDefinition:"PropertyDefinition",RestElement:"RestElement",ReturnStatement:"ReturnStatement",SequenceExpression:"SequenceExpression",SpreadElement:"SpreadElement",Super:"Super",SwitchStatement:"SwitchStatement",SwitchCase:"SwitchCase",TaggedTemplateExpression:"TaggedTemplateExpression",TemplateElement:"TemplateElement",TemplateLiteral:"TemplateLiteral",ThisExpression:"ThisExpression",ThrowStatement:"ThrowStatement",TryStatement:"TryStatement",UnaryExpression:"UnaryExpression",UpdateExpression:"UpdateExpression",VariableDeclaration:"VariableDeclaration",VariableDeclarator:"VariableDeclarator",WhileStatement:"WhileStatement",WithStatement:"WithStatement",YieldExpression:"YieldExpression"},r={AssignmentExpression:["left","right"],AssignmentPattern:["left","right"],ArrayExpression:["elements"],ArrayPattern:["elements"],ArrowFunctionExpression:["params","body"],AwaitExpression:["argument"],BlockStatement:["body"],BinaryExpression:["left","right"],BreakStatement:["label"],CallExpression:["callee","arguments"],CatchClause:["param","body"],ChainExpression:["expression"],ClassBody:["body"],ClassDeclaration:["id","superClass","body"],ClassExpression:["id","superClass","body"],ComprehensionBlock:["left","right"],ComprehensionExpression:["blocks","filter","body"],ConditionalExpression:["test","consequent","alternate"],ContinueStatement:["label"],DebuggerStatement:[],DirectiveStatement:[],DoWhileStatement:["body","test"],EmptyStatement:[],ExportAllDeclaration:["source"],ExportDefaultDeclaration:["declaration"],ExportNamedDeclaration:["declaration","specifiers","source"],ExportSpecifier:["exported","local"],ExpressionStatement:["expression"],ForStatement:["init","test","update","body"],ForInStatement:["left","right","body"],ForOfStatement:["left","right","body"],FunctionDeclaration:["id","params","body"],FunctionExpression:["id","params","body"],GeneratorExpression:["blocks","filter","body"],Identifier:[],IfStatement:["test","consequent","alternate"],ImportExpression:["source"],ImportDeclaration:["specifiers","source"],ImportDefaultSpecifier:["local"],ImportNamespaceSpecifier:["local"],ImportSpecifier:["imported","local"],Literal:[],LabeledStatement:["label","body"],LogicalExpression:["left","right"],MemberExpression:["object","property"],MetaProperty:["meta","property"],MethodDefinition:["key","value"],ModuleSpecifier:[],NewExpression:["callee","arguments"],ObjectExpression:["properties"],ObjectPattern:["properties"],PrivateIdentifier:[],Program:["body"],Property:["key","value"],PropertyDefinition:["key","value"],RestElement:["argument"],ReturnStatement:["argument"],SequenceExpression:["expressions"],SpreadElement:["argument"],Super:[],SwitchStatement:["discriminant","cases"],SwitchCase:["test","consequent"],TaggedTemplateExpression:["tag","quasi"],TemplateElement:[],TemplateLiteral:["quasis","expressions"],ThisExpression:[],ThrowStatement:["argument"],TryStatement:["block","handler","finalizer"],UnaryExpression:["argument"],UpdateExpression:["argument"],VariableDeclaration:["declarations"],VariableDeclarator:["id","init"],WhileStatement:["test","body"],WithStatement:["object","body"],YieldExpression:["argument"]},i={Break:a={},Skip:o={},Remove:s={}},l.prototype.replace=function(e){this.parent[this.key]=e},l.prototype.remove=function(){return Array.isArray(this.parent)?(this.parent.splice(this.key,1),!0):(this.replace(null),!1)},h.prototype.path=function(){var e,t,n,i,r;function a(e,t){if(Array.isArray(t))for(n=0,i=t.length;n<i;++n)e.push(t[n]);else e.push(t)}if(!this.__current.path)return null;for(r=[],e=2,t=this.__leavelist.length;e<t;++e)a(r,this.__leavelist[e].path);return a(r,this.__current.path),r},h.prototype.type=function(){return this.current().type||this.__current.wrap},h.prototype.parents=function(){var e,t,n;for(n=[],e=1,t=this.__leavelist.length;e<t;++e)n.push(this.__leavelist[e].node);return n},h.prototype.current=function(){return this.__current.node},h.prototype.__execute=function(e,t){var n,i;return i=void 0,n=this.__current,this.__current=t,this.__state=null,e&&(i=e.call(this,t.node,this.__leavelist[this.__leavelist.length-1].node)),this.__current=n,i},h.prototype.notify=function(e){this.__state=e},h.prototype.skip=function(){this.notify(o)},h.prototype.break=function(){this.notify(a)},h.prototype.remove=function(){this.notify(s)},h.prototype.__initialize=function(e,t){this.visitor=t,this.root=e,this.__worklist=[],this.__leavelist=[],this.__current=null,this.__state=null,this.__fallback=null,"iteration"===t.fallback?this.__fallback=Object.keys:"function"==typeof t.fallback&&(this.__fallback=t.fallback),this.__keys=r,t.keys&&(this.__keys=Object.assign(Object.create(this.__keys),t.keys))},h.prototype.traverse=function(e,t){var n,i,r,s,u,l,h,m,g,v,y,b;for(this.__initialize(e,t),b={},n=this.__worklist,i=this.__leavelist,n.push(new c(e,null,null,null)),i.push(new c(null,null,null,null));n.length;)if((r=n.pop())!==b){if(r.node){if(l=this.__execute(t.enter,r),this.__state===a||l===a)return;if(n.push(b),i.push(r),this.__state===o||l===o)continue;if(u=(s=r.node).type||r.wrap,!(v=this.__keys[u])){if(!this.__fallback)throw new Error("Unknown node type "+u+".");v=this.__fallback(s)}for(m=v.length;(m-=1)>=0;)if(y=s[h=v[m]])if(Array.isArray(y)){for(g=y.length;(g-=1)>=0;)if(y[g]&&!f(i,y[g])){if(p(u,v[m]))r=new c(y[g],[h,g],"Property",null);else{if(!d(y[g]))continue;r=new c(y[g],[h,g],null,null)}n.push(r)}}else if(d(y)){if(f(i,y))continue;n.push(new c(y,h,null,null))}}}else if(r=i.pop(),l=this.__execute(t.leave,r),this.__state===a||l===a)return},h.prototype.replace=function(e,t){var n,i,r,u,h,f,m,g,v,y,b,x,S;function E(e){var t,i,r,a;if(e.ref.remove())for(i=e.ref.key,a=e.ref.parent,t=n.length;t--;)if((r=n[t]).ref&&r.ref.parent===a){if(r.ref.key<i)break;--r.ref.key}}for(this.__initialize(e,t),b={},n=this.__worklist,i=this.__leavelist,f=new c(e,null,null,new l(x={root:e},"root")),n.push(f),i.push(f);n.length;)if((f=n.pop())!==b){if(void 0!==(h=this.__execute(t.enter,f))&&h!==a&&h!==o&&h!==s&&(f.ref.replace(h),f.node=h),this.__state!==s&&h!==s||(E(f),f.node=null),this.__state===a||h===a)return x.root;if((r=f.node)&&(n.push(b),i.push(f),this.__state!==o&&h!==o)){if(u=r.type||f.wrap,!(v=this.__keys[u])){if(!this.__fallback)throw new Error("Unknown node type "+u+".");v=this.__fallback(r)}for(m=v.length;(m-=1)>=0;)if(y=r[S=v[m]])if(Array.isArray(y)){for(g=y.length;(g-=1)>=0;)if(y[g]){if(p(u,v[m]))f=new c(y[g],[S,g],"Property",new l(y,g));else{if(!d(y[g]))continue;f=new c(y[g],[S,g],null,new l(y,g))}n.push(f)}}else d(y)&&n.push(new c(y,S,null,new l(r,S)))}}else if(f=i.pop(),void 0!==(h=this.__execute(t.leave,f))&&h!==a&&h!==o&&h!==s&&f.ref.replace(h),this.__state!==s&&h!==s||E(f),this.__state===a||h===a)return x.root;return x.root},t.Syntax=n,t.traverse=m,t.replace=function(e,t){return(new h).replace(e,t)},t.attachComments=function(e,t,n){var r,a,o,s,l=[];if(!e.range)throw new Error("attachComments needs range information");if(!n.length){if(t.length){for(o=0,a=t.length;o<a;o+=1)(r=u(t[o])).extendedRange=[0,e.range[0]],l.push(r);e.leadingComments=l}return e}for(o=0,a=t.length;o<a;o+=1)l.push(g(u(t[o]),n));return s=0,m(e,{enter:function(e){for(var t;s<l.length&&!((t=l[s]).extendedRange[1]>e.range[0]);)t.extendedRange[1]===e.range[0]?(e.leadingComments||(e.leadingComments=[]),e.leadingComments.push(t),l.splice(s,1)):s+=1;return s===l.length?i.Break:l[s].extendedRange[0]>e.range[1]?i.Skip:void 0}}),s=0,m(e,{leave:function(e){for(var t;s<l.length&&(t=l[s],!(e.range[1]<t.extendedRange[0]));)e.range[1]===t.extendedRange[0]?(e.trailingComments||(e.trailingComments=[]),e.trailingComments.push(t),l.splice(s,1)):s+=1;return s===l.length?i.Break:l[s].extendedRange[0]>e.range[1]?i.Skip:void 0}}),e},t.VisitorKeys=r,t.VisitorOption=i,t.Controller=h,t.cloneEnvironment=function(){return e({})},t}(Ru)),Ru),_u=e(Mu);var Uu=new WeakMap,ju=!1,Hu=null,zu=null,Vu=0;function Ku(e,t){try{return{ok:!0,value:e[t]}}catch(e){return{ok:!1,value:void 0}}}function Gu(e,t){try{return e[t]()}catch(e){return null}}function Ju(e,t){var n="YtlrPlayerActionsContainer",i=0,r=new WeakSet;return function a(o,s,u,l,c){if(!o||s>8||i>e)return null;if("object"===T(o)||"function"==typeof o){if(r.has(o))return null;r.add(o)}if("function"==typeof o){if(function(r){if(i>e||"function"!=typeof r)return!1;i+=1;var a=Uu.get(r);if(void 0===a){a=0;try{var o=r.toString();o.includes("TRANSPORT_CONTROLS_BUTTON_TYPE_FEATURED_ACTION")&&(a|=1),o.includes(n)&&(a|=2)}catch(e){}Uu.set(r,a)}return!(!(1&a)||t&&!(2&a))}(o)){var h=(m=l,g=o,v=c,(p=u)&&void 0!==m&&"function"==typeof g?{host:p,key:m,fn:g,write:function(e){try{return v?(p.set(m,e),p.get(m)===e):(p[m]=e,p[m]===e)}catch(e){return!1}}}:null);if(h)return h}var d=o.prototype;return d&&"object"===T(d)?a(d,s+1,null,void 0,!1):null}var p,m,g,v;if("object"!==T(o))return null;if(o instanceof Map){var y=Gu(o,"entries");if(y){var b,x=f(y);try{for(x.s();!(b=x.n()).done;){var S=D(b.value,2),E=S[0],w=S[1];if(i>e)return null;var k=a(w,s+1,o,E,!0);if(k)return k}}catch(e){x.e(e)}finally{x.f()}}return null}if(o instanceof Set){var A=Gu(o,"values");if(A){var C,P=f(A);try{for(P.s();!(C=P.n()).done;){var F=C.value;if(i>e)return null;var B=a(F,s+1,null,void 0,!1);if(B)return B}}catch(e){P.e(e)}finally{P.f()}}return null}var I=Ku(o,n);if(I.ok&&void 0!==I.value){var L=a(I.value,s+1,o,n,!1);if(L)return L}for(var O=0,N=Object.keys(o);O<N.length;O++){var R=N[O];if(i>e)return null;if(R!==n){var M=Ku(o,R);if(M.ok){var _=a(M.value,s+1,o,R,!1);if(_)return _}}}return null}(window._yttv,0,null,void 0,!1)}function Xu(){if(ju||!Se("enablePatchingVideoPlayer"))return!1;if(!window._yttv||!document.querySelector(".html5-video-player")&&!document.querySelector("ytlr-player"))return!1;var e=Hu&&"function"==typeof Hu.fn?Hu:Hu=Ju(2e4,!0)||Ju(2e4,!1);if(!e||"function"!=typeof e.write)return!1;try{var t=function(){var e=Array.prototype.slice.call(arguments);null===i&&(i=n.toString(),r=/^class\s/.test(i));var o,s=r;function u(e,i){return"undefined"!=typeof Reflect&&"function"==typeof Reflect.construct?Reflect.construct(e,i,t):function(e,t,n){if(y())return Reflect.construct.apply(null,arguments);var i=[null];i.push.apply(i,t);var r=new(e.bind.apply(e,i));return n&&k(r,n.prototype),r}(n,A(i))}if(!(this instanceof t))return s?u(n,e):n.apply(this,e);s?o=u(n,e):(n.apply(this,e),o=this);try{var l,c,h,d,p=a||(a=function(e){var t,n=e,i=0;try{t=Nu.parse(e,{range:!0,tolerant:!0,sourceType:"script"})}catch(n){try{var r="("+e+")";t=Nu.parse(r,{range:!0,tolerant:!0,sourceType:"script"}),i=1}catch(r){try{t=Nu.parse(e,{range:!0,tolerant:!0,sourceType:"module"})}catch(r){try{var a="("+e+")";t=Nu.parse(a,{range:!0,tolerant:!0,sourceType:"module"}),i=1}catch(e){throw n}}}}var o=[];return _u.traverse(t,{enter:function(e){if("AssignmentExpression"===e.type){var t=e.right;if(t&&t.range){var r=n.slice(t.range[0]-i,t.range[1]-i),a=null;if("CallExpression"===t.type&&t.callee&&"FunctionExpression"===t.callee.type&&t.callee.body)for(var s=t.callee.body.body||[],u=0;u<s.length;u++){var l=s[u];if("ReturnStatement"===l.type&&l.argument&&l.argument.range){a=n.slice(l.argument.range[0]-i,l.argument.range[1]-i);break}}else"FunctionExpression"!==t.type&&"ArrowFunctionExpression"!==t.type||(a=r);o.push({left:e.left&&e.left.range?n.slice(e.left.range[0]-i,e.left.range[1]-i):null,rhs:r,returned:a})}}}}),o}(i)),f={type:"TRANSPORT_CONTROLS_BUTTON_TYPE_PIP",button:{buttonRenderer:mn(!1,Se("enableSwapMPWithPIP")?Nt("player.pictureInPicture"):Nt("player.miniPlayer"),"CLEAR_COOKIES",{customAction:{action:Se("enableSwapMPWithPIP")?"ENTER_PIP":"ENTER_MP"}})}},m=null===(l=p.find(function(e){return e.rhs.includes("TRANSPORT_CONTROLS_BUTTON_TYPE_PLAYBACK_SETTINGS")}))||void 0===l||null===(l=l.left)||void 0===l?void 0:l.split(".")[1];if(m&&Se("enableMPButton")){var g=o[m];"function"==typeof g&&(o[m]=function(){var e=g.apply(this,arguments);if(Array.isArray(e)&&!e.find(function(e){return"TRANSPORT_CONTROLS_BUTTON_TYPE_PIP"===e.type})){var t=e.findIndex(function(e){return"TRANSPORT_CONTROLS_BUTTON_TYPE_PLAYBACK_SETTINGS"===e.type});-1!==t&&e.splice(t,0,f)}return e})}var v=null===(c=p.find(function(e){return!!e.rhs.includes("skipNextButton")&&e.rhs.indexOf("skipPreviousButton")>e.rhs.indexOf("skipNextButton")}))||void 0===c||null===(c=c.left)||void 0===c?void 0:c.split(".")[1],b=null===(h=p.find(function(e){return!!e.rhs.includes("skipPreviousButton")&&e.rhs.indexOf("skipNextButton")>e.rhs.indexOf("skipPreviousButton")}))||void 0===h||null===(h=h.left)||void 0===h?void 0:h.split(".")[1],x=null===(d=p.find(function(e){return e.rhs.includes("props.data.engagementActions")}))||void 0===d||null===(d=d.left)||void 0===d?void 0:d.split(".")[1];if(x&&Se("enableSpeedControlsButton")){var S=o[x];"function"==typeof S&&(o[x]=function(){var e=S.apply(this,arguments);return Array.isArray(e)&&!e.find(function(e){return"TRANSPORT_CONTROLS_BUTTON_TYPE_SPEED"===e.type})&&e.push({type:"TRANSPORT_CONTROLS_BUTTON_TYPE_SPEED",button:{buttonRenderer:mn(!1,Nt("player.speedControls"),"SLOW_MOTION_VIDEO",{customAction:{action:"AXO_SPEED_SETTINGS_SHOW"}})}}),e})}if(!Se("enableSuperThanksButton")&&x){var E=o[x];"function"==typeof E&&(o[x]=function(){var e=E.apply(this,arguments);return Array.isArray(e)?e.filter(function(e){return"TRANSPORT_CONTROLS_BUTTON_TYPE_SUPER_THANKS"!==e.type&&"TRANSPORT_CONTROLS_BUTTON_TYPE_SHOPPING"!==e.type}):e})}Se("enablePreviousNextButtons")&&v&&b&&(o[v]=function(){return mn(!1,Nt("player.previous"),"SKIP_PREVIOUS",{signalAction:{signal:"PLAYER_PLAY_PREVIOUS"}})},o[b]=function(){return mn(!1,Nt("player.next"),"SKIP_NEXT",{signalAction:{signal:"PLAYER_PLAY_NEXT"}})})}catch(e){console.warn("[AxoTube:customUI] Custom UI patching failed:",e)}return o},n=e.fn,i=null,r=!1,a=null;return t.prototype=n.prototype,e.write(t)?(e.fn=t,ju=!0,!0):(Hu=null,!1)}catch(e){return console.error("[AxoTube:customUI] Custom UI apply failed:",e),Hu=null,!1}}function Wu(e){!ju&&Se("enablePatchingVideoPlayer")&&(e&&(Vu=0),zu||(zu=setTimeout(function(){zu=null,Vu+=1,Xu()||Vu<10&&Wu(!1)},500)))}function qu(){Xu()||Wu(!0)}"complete"===document.readyState||"interactive"===document.readyState?qu():window.addEventListener("DOMContentLoaded",qu),we.addEventListener("configChange",function(e){var t;"enablePatchingVideoPlayer"===(null===(t=e.detail)||void 0===t?void 0:t.key)&&e.detail.value&&(Hu=null,Wu(!0))});var Yu=null,Qu=null,Zu=!1,$u=null,el=null;function tl(){return-1!==window.location.href.indexOf("watch")}function nl(){return se()&&se().SetFrameRate}function il(){if(Zu){var e=nl();if(e)try{e.call(se(),0),Zu=!1}catch(e){console.warn("[AxoTube:autoFrameRate] Failed to reset auto frame rate:",e)}}}function rl(){null!==$u&&clearTimeout($u),$u=null,el&&(el.video.removeEventListener("play",rl),el=null)}function al(){if(rl(),Qu&&(clearTimeout(Qu),Qu=null),Yu){try{Yu.removeEventListener("onPlaybackStartExternal",ol)}catch(e){}Yu=null}}function ol(){try{if(!tl()||!Yu||Yu!==Ii()||!Se("autoFrameRate"))return;var e=Yu.getStatsForNerds(),t=e&&e.resolution?e.resolution.match(/(\d+)x(\d+)@([\d.]+)/):null,n=nl();if(!t||!n)return;var i=Li(),r=Se("autoFrameRatePauseVideoFor"),a=r>0&&i&&!i.paused&&!el;a&&i.pause();try{n.call(se(),parseFloat(t[3])),Zu=!0}finally{a&&i.paused&&function(e,t,n){var i=window.location.hash,r=Oi(t),a=e.currentSrc||e.src;el={video:e,player:t,hash:i,videoId:r,source:a},e.addEventListener("play",rl),$u=setTimeout(function(){var n=el,o=n&&n.video===e&&n.player===Yu&&Ii()===t&&Li()===e&&tl()&&Se("autoFrameRate")&&window.location.hash===i&&Oi(t)===r&&(e.currentSrc||e.src)===a&&e.paused&&!e.ended&&!e.seeking;if(rl(),o)try{var s=e.play();s&&"function"==typeof s.catch&&s.catch(function(){})}catch(e){console.warn("[AxoTube:autoFrameRate] Failed to resume after frame rate switch:",e)}},n)}(i,Yu,r)}}catch(e){console.error("[AxoTube:autoFrameRate] Error in auto frame rate handling:",e)}}function sl(){if(Qu&&(clearTimeout(Qu),Qu=null),!Se("autoFrameRate"))return al(),void il();var e=Ii();if(e){if(e!==Yu){if(rl(),Yu)try{Yu.removeEventListener("onPlaybackStartExternal",ol)}catch(e){}(Yu=e).addEventListener("onPlaybackStartExternal",ol)}}else Qu=setTimeout(sl,500)}window.addEventListener("hashchange",function(){rl(),tl()||il(),setTimeout(sl,0)}),_i(function(e){e!==Yu&&sl()}),Ui(function(e,t){t&&e!==t&&rl()}),ji(function(e,t){t&&e!==t&&rl()}),document.addEventListener("keydown",rl,!0),document.addEventListener("mousedown",rl,!0),document.addEventListener("touchstart",rl,!0),we.addEventListener("configChange",function(e){var t,n;"autoFrameRate"===(null===(t=e.detail)||void 0===t?void 0:t.key)?e.detail.value?sl():(al(),il()):"autoFrameRatePauseVideoFor"===(null===(n=e.detail)||void 0===n?void 0:n.key)&&rl()}),sl()}();
|
|
1
|
+
!function(){"use strict";function e(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function t(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=Array(t);n<t;n++)i[n]=e[n];return i}function n(e,t,n){if("function"==typeof e?e===t:e.has(t))return arguments.length<3?t:n;throw new TypeError("Private element is not present on this object")}function i(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){return e.get(n(e,t))}function o(e,t,n){i(e,t),t.set(e,n)}function s(e,t,i){return e.set(n(e,t),i),i}function u(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,v(i.key),i)}}function l(e,t,n){return t&&u(e.prototype,t),n&&u(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function c(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=x(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var i=0,r=function(){};return{s:r,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,o=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return o=e.done,e},e:function(e){s=!0,a=e},f:function(){try{o||null==n.return||n.return()}finally{if(s)throw a}}}}function h(e,t,n){return(t=v(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function d(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(d=function(){return!!e})()}function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,i)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?p(Object(n),!0).forEach(function(t){h(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function m(e,t){return m=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},m(e,t)}function y(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i,r,a,o,s=[],u=!0,l=!1;try{if(a=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;u=!1}else for(;!(u=(i=a.call(n)).done)&&(s.push(i.value),s.length!==t);u=!0);}catch(e){l=!0,r=e}finally{try{if(!u&&null!=n.return&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw r}}return s}}(e,t)||x(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function g(e){return function(e){if(Array.isArray(e))return t(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||x(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function v(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,t||"default");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}function b(e){return b="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},b(e)}function x(e,n){if(e){if("string"==typeof e)return t(e,n);var i={}.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?t(e,n):void 0}}var E,S={};!function(){if(E)return S;function e(e,t,n){Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0,enumerable:!1})}E=1,function(){if("undefined"==typeof globalThis)try{Object.defineProperty(Object.prototype,"__globalThis__",{get:function(){return this},configurable:!0}),__globalThis__.globalThis=__globalThis__,delete Object.prototype.__globalThis__}catch(e){window.globalThis=window}}(),window.NodeList&&!NodeList.prototype.forEach&&e(NodeList.prototype,"forEach",Array.prototype.forEach),window.HTMLCollection&&!HTMLCollection.prototype.forEach&&e(HTMLCollection.prototype,"forEach",Array.prototype.forEach),function(){var e=window.EventTarget;if(void 0!==e)try{return void new e}catch(e){}window.EventTarget=function(){var e={};return{addEventListener:function(t,n){"function"==typeof n&&(e[t]||(e[t]=[]),-1===e[t].indexOf(n)&&e[t].push(n))},removeEventListener:function(t,n){var i=e[t];if(i){var r=i.indexOf(n);-1!==r&&i.splice(r,1)}},dispatchEvent:function(t){var n=e[t&&t.type];if(n)for(var i=n.slice(),r=0;r<i.length;r++)try{i[r].call(this,t)}catch(e){console.error(e)}return!(t&&t.defaultPrevented)}}},e&&(window.EventTarget.prototype=e.prototype)}(),function(){function e(){this.aborted=!1,this._cbs=[]}function t(){this.signal=new e}"undefined"==typeof AbortController&&(e.prototype.addEventListener=function(e,t){"abort"===e&&"function"==typeof t&&this._cbs.push(t)},e.prototype.removeEventListener=function(e,t){if("abort"===e){var n=this._cbs.indexOf(t);-1!==n&&this._cbs.splice(n,1)}},e.prototype.dispatchEvent=function(e){if(e&&"abort"===e.type)for(var t=this._cbs.slice(),n=0;n<t.length;n++)t[n](e)},t.prototype.abort=function(){this.signal.aborted||(this.signal.aborted=!0,this.signal.dispatchEvent({type:"abort",bubbles:!1,cancelable:!1}))},window.AbortSignal=e,window.AbortController=t)}(),function(){function e(e,t){var n,i=!!(t=t||{}).bubbles,r=!!t.cancelable,a=void 0!==t.detail?t.detail:null;try{(n=document.createEvent("CustomEvent")).initCustomEvent(e,i,r,a)}catch(t){(n=document.createEvent("Event")).initEvent(e,i,r),n.detail=a}return n}"function"!=typeof CustomEvent&&(window.Event&&window.Event.prototype&&(e.prototype=window.Event.prototype),window.CustomEvent=e)}(),"function"!=typeof Promise.prototype.finally&&e(Promise.prototype,"finally",function(e){var t=this.constructor;return this.then(function(n){return t.resolve(e()).then(function(){return n})},function(n){return t.resolve(e()).then(function(){throw n})})}),"function"!=typeof Promise.allSettled&&e(Promise,"allSettled",function(e){return Promise.all(Array.prototype.map.call(e,function(e){return Promise.resolve(e).then(function(e){return{status:"fulfilled",value:e}},function(e){return{status:"rejected",reason:e}})}))}),function(){function t(e,n,i){for(var r=0;r<e.length;r++)n>0&&Array.isArray(e[r])?t(e[r],n-1,i):i.push(e[r]);return i}"function"!=typeof Array.prototype.flat&&e(Array.prototype,"flat",function(e){return t(this,(e=void 0===e?1:Math.floor(e))<0?0:e,[])})}(),"function"!=typeof Array.prototype.flatMap&&e(Array.prototype,"flatMap",function(e,t){return Array.prototype.map.call(this,e,t).flat(1)}),"function"!=typeof String.prototype.replaceAll&&e(String.prototype,"replaceAll",function(e,t){if("[object RegExp]"===Object.prototype.toString.call(e)){if(!e.global)throw new TypeError("replaceAll must be called with a global RegExp");return this.replace(e,t)}var n=String(e).replace(/[.*+?^${}()|[\]\\]/g,"\\$&");return String(this).replace(new RegExp(n,"g"),t)}),"function"!=typeof Object.values&&e(Object,"values",function(e){for(var t=Object.keys(e),n=[],i=0;i<t.length;i++)n.push(e[t[i]]);return n}),"function"!=typeof Object.entries&&e(Object,"entries",function(e){for(var t=Object.keys(e),n=[],i=0;i<t.length;i++)n.push([t[i],e[t[i]]]);return n}),"function"!=typeof Object.fromEntries&&e(Object,"fromEntries",function(e){if(null==e)throw new TypeError("Object.fromEntries requires an iterable");for(var t={},n=e[Symbol.iterator](),i=n.next();!i.done;){var r=i.value;if(null===r||"object"!==b(r)&&"function"!=typeof r)throw new TypeError("Iterator value is not an entry object");t[r[0]]=r[1],i=n.next()}return t}),"function"!=typeof queueMicrotask&&(window.queueMicrotask=function(e){Promise.resolve().then(e).catch(function(e){setTimeout(function(){throw e},0)})}),window.Element&&"function"!=typeof Element.prototype.closest&&e(Element.prototype,"closest",function(e){for(var t=this;t&&1===t.nodeType;){if(t.matches?t.matches(e):t.msMatchesSelector?t.msMatchesSelector(e):t.webkitMatchesSelector&&t.webkitMatchesSelector(e))return t;t=t.parentElement||t.parentNode}return null}),function(){if(window.Element){var t=Element.prototype;"function"!=typeof t.matches&&e(t,"matches",t.msMatchesSelector||t.webkitMatchesSelector||function(e){for(var t=(this.document||this.ownerDocument).querySelectorAll(e),n=t.length;--n>=0&&t.item(n)!==this;);return n>-1})}}(),function(){if("undefined"!=typeof Intl&&"function"!=typeof Intl.Locale){var e={US:"en",GB:"en",AU:"en",CA:"en",IN:"hi",IE:"en",NZ:"en",FR:"fr",DE:"de",ES:"es",IT:"it",PT:"pt",BR:"pt",MX:"es",AR:"es",CO:"es",CL:"es",RU:"ru",UA:"uk",PL:"pl",NL:"nl",BE:"nl",SE:"sv",NO:"no",DK:"da",FI:"fi",TR:"tr",GR:"el",CZ:"cs",SK:"sk",HU:"hu",RO:"ro",BG:"bg",HR:"hr",RS:"sr",JP:"ja",KR:"ko",VN:"vi",TH:"th",ID:"id",MY:"ms",PH:"tl",SA:"ar",AE:"ar",EG:"ar",IL:"he",IR:"fa",PK:"ur",BD:"bn",LK:"si"};t.prototype.maximize=function(){return this},Intl.Locale=t}function t(t,n){n=n||{},this.language=e[n.region]||"en"}}(),function(){var t=9007199254740991;function n(t,n,i){void 0===t[n]&&e(t,n,i)}function i(e,t){return e===t||e!=e&&t!=t}function r(e,t){if("[object RegExp]"===Object.prototype.toString.call(e))throw new TypeError("First argument to String.prototype."+t+" must not be a regular expression")}function a(e,t){if(null==e)throw new TypeError("String.prototype."+t+" called on null or undefined")}n(Array.prototype,"includes",function(e,t){for(var n=Object(this),r=n.length>>>0,a=Number(t)||0,o=a>=0?Math.floor(a):Math.max(r+Math.ceil(a),0);o<r;o++)if(i(n[o],e))return!0;return!1}),n(Array.prototype,"findIndex",function(e,t){if("function"!=typeof e)throw new TypeError("predicate must be a function");for(var n=Object(this),i=n.length>>>0,r=0;r<i;r++)if(e.call(t,n[r],r,n))return r;return-1}),n(Array.prototype,"find",function(e,t){if("function"!=typeof e)throw new TypeError("predicate must be a function");for(var n=Object(this),i=n.length>>>0,r=0;r<i;r++)if(e.call(t,n[r],r,n))return n[r]}),n(Array,"from",function(e,t,n){if(null==e)throw new TypeError("Array.from requires an array-like or iterable object");if(void 0!==t&&"function"!=typeof t)throw new TypeError("Array.from: mapFn must be a function");var i=[],r=e[Symbol.iterator];if("function"==typeof r)for(var a=r.call(e),o=a.next();!o.done;)i.push(o.value),o=a.next();else for(var s=Object(e).length>>>0,u=0;u<s;u++)i.push(e[u]);if(t)for(var l=0;l<i.length;l++)i[l]=t.call(n,i[l],l);return i}),n(Object,"assign",function(e){if(null==e)throw new TypeError("Cannot convert undefined or null to object");for(var t=Object(e),n=1;n<arguments.length;n++){var i=arguments[n];if(null!=i)for(var r=Object(i),a=Object.keys(r),o=0;o<a.length;o++)t[a[o]]=r[a[o]]}return t}),n(String.prototype,"includes",function(e,t){a(this,"includes"),r(e,"includes");var n=String(this),i=Number(t)||0;return i<0&&(i=0),-1!==n.indexOf(String(e),i)}),n(String.prototype,"startsWith",function(e,t){a(this,"startsWith"),r(e,"startsWith");var n=String(this),i=String(e),o=Number(t)||0;return o<0&&(o=0),o>n.length&&(o=n.length),n.substring(o,o+i.length)===i}),n(Number,"isFinite",function(e){return"number"==typeof e&&isFinite(e)}),n(Number,"isSafeInteger",function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e&&Math.abs(e)<=t}),n(Number,"MAX_SAFE_INTEGER",t),n(Number,"MIN_SAFE_INTEGER",-t)}()}();var w;w||(w=1,function(){var e=!1;try{var t=0,n=[];e="xbx"!=="aba".replaceAll("a",function(e,i){return t+=1,n.push(i),"x"})||2!==t||0!==n[0]||2!==n[1]}catch(t){e=!0}e&&(String.prototype.replaceAll=function(e,t){var n=String(this);if(e instanceof RegExp){if(!e.global)throw new TypeError("replaceAll requires a global RegExp");return n.replace(e,t)}var i=new RegExp(String(e).replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),"g");return n.replace(i,t)})}(),function(){var e=!1;try{var t=Object.fromEntries([["a",1]]);e=Object.getPrototypeOf(t)!==Object.prototype}catch(t){e=!0}e&&(Object.fromEntries=function(e){var t={};function n(e){if(e)try{Object.defineProperty(t,e[0],{value:e[1],enumerable:!0,configurable:!0,writable:!0})}catch(n){t[e[0]]=e[1]}}if(e&&"function"==typeof e.forEach)e.forEach(n);else for(var i=Array.isArray(e)?e:Array.prototype.slice.call(e||[]),r=0;r<i.length;r++)n(i[r]);return t})}());var D="undefined"!=typeof globalThis&&globalThis||"undefined"!=typeof self&&self||"undefined"!=typeof global&&global||{},A="URLSearchParams"in D,k="Symbol"in D&&"iterator"in Symbol,C="FileReader"in D&&"Blob"in D&&function(){try{return new Blob,!0}catch(e){return!1}}(),T="FormData"in D,F="ArrayBuffer"in D;if(F)var P=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],B=ArrayBuffer.isView||function(e){return e&&P.indexOf(Object.prototype.toString.call(e))>-1};function I(e){if("string"!=typeof e&&(e=String(e)),/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(e)||""===e)throw new TypeError('Invalid character in header field name: "'+e+'"');return e.toLowerCase()}function N(e){return"string"!=typeof e&&(e=String(e)),e}function M(e){var t={next:function(){var t=e.shift();return{done:void 0===t,value:t}}};return k&&(t[Symbol.iterator]=function(){return t}),t}function R(e){this.map={},e instanceof R?e.forEach(function(e,t){this.append(t,e)},this):Array.isArray(e)?e.forEach(function(e){if(2!=e.length)throw new TypeError("Headers constructor: expected name/value pair to be length 2, found"+e.length);this.append(e[0],e[1])},this):e&&Object.getOwnPropertyNames(e).forEach(function(t){this.append(t,e[t])},this)}function L(e){if(!e._noBody)return e.bodyUsed?Promise.reject(new TypeError("Already read")):void(e.bodyUsed=!0)}function O(e){return new Promise(function(t,n){e.onload=function(){t(e.result)},e.onerror=function(){n(e.error)}})}function _(e){var t=new FileReader,n=O(t);return t.readAsArrayBuffer(e),n}function U(e){if(e.slice)return e.slice(0);var t=new Uint8Array(e.byteLength);return t.set(new Uint8Array(e)),t.buffer}function j(){return this.bodyUsed=!1,this._initBody=function(e){var t;this.bodyUsed=this.bodyUsed,this._bodyInit=e,e?"string"==typeof e?this._bodyText=e:C&&Blob.prototype.isPrototypeOf(e)?this._bodyBlob=e:T&&FormData.prototype.isPrototypeOf(e)?this._bodyFormData=e:A&&URLSearchParams.prototype.isPrototypeOf(e)?this._bodyText=e.toString():F&&C&&((t=e)&&DataView.prototype.isPrototypeOf(t))?(this._bodyArrayBuffer=U(e.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):F&&(ArrayBuffer.prototype.isPrototypeOf(e)||B(e))?this._bodyArrayBuffer=U(e):this._bodyText=e=Object.prototype.toString.call(e):(this._noBody=!0,this._bodyText=""),this.headers.get("content-type")||("string"==typeof e?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):A&&URLSearchParams.prototype.isPrototypeOf(e)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},C&&(this.blob=function(){var e=L(this);if(e)return e;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))}),this.arrayBuffer=function(){if(this._bodyArrayBuffer){var e=L(this);return e||(ArrayBuffer.isView(this._bodyArrayBuffer)?Promise.resolve(this._bodyArrayBuffer.buffer.slice(this._bodyArrayBuffer.byteOffset,this._bodyArrayBuffer.byteOffset+this._bodyArrayBuffer.byteLength)):Promise.resolve(this._bodyArrayBuffer))}if(C)return this.blob().then(_);throw new Error("could not read as ArrayBuffer")},this.text=function(){var e,t,n,i,r,a=L(this);if(a)return a;if(this._bodyBlob)return e=this._bodyBlob,t=new FileReader,n=O(t),i=/charset=([A-Za-z0-9_-]+)/.exec(e.type),r=i?i[1]:"utf-8",t.readAsText(e,r),n;if(this._bodyArrayBuffer)return Promise.resolve(function(e){for(var t=new Uint8Array(e),n=new Array(t.length),i=0;i<t.length;i++)n[i]=String.fromCharCode(t[i]);return n.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},T&&(this.formData=function(){return this.text().then(G)}),this.json=function(){return this.text().then(JSON.parse)},this}R.prototype.append=function(e,t){e=I(e),t=N(t);var n=this.map[e];this.map[e]=n?n+", "+t:t},R.prototype.delete=function(e){delete this.map[I(e)]},R.prototype.get=function(e){return e=I(e),this.has(e)?this.map[e]:null},R.prototype.has=function(e){return this.map.hasOwnProperty(I(e))},R.prototype.set=function(e,t){this.map[I(e)]=N(t)},R.prototype.forEach=function(e,t){for(var n in this.map)this.map.hasOwnProperty(n)&&e.call(t,this.map[n],n,this)},R.prototype.keys=function(){var e=[];return this.forEach(function(t,n){e.push(n)}),M(e)},R.prototype.values=function(){var e=[];return this.forEach(function(t){e.push(t)}),M(e)},R.prototype.entries=function(){var e=[];return this.forEach(function(t,n){e.push([n,t])}),M(e)},k&&(R.prototype[Symbol.iterator]=R.prototype.entries);var H=["CONNECT","DELETE","GET","HEAD","OPTIONS","PATCH","POST","PUT","TRACE"];function z(e,t){if(!(this instanceof z))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');var n,i,r=(t=t||{}).body;if(e instanceof z){if(e.bodyUsed)throw new TypeError("Already read");this.url=e.url,this.credentials=e.credentials,t.headers||(this.headers=new R(e.headers)),this.method=e.method,this.mode=e.mode,this.signal=e.signal,r||null==e._bodyInit||(r=e._bodyInit,e.bodyUsed=!0)}else this.url=String(e);if(this.credentials=t.credentials||this.credentials||"same-origin",!t.headers&&this.headers||(this.headers=new R(t.headers)),this.method=(n=t.method||this.method||"GET",i=n.toUpperCase(),H.indexOf(i)>-1?i:n),this.mode=t.mode||this.mode||null,this.signal=t.signal||this.signal||function(){if("AbortController"in D)return(new AbortController).signal}(),this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&r)throw new TypeError("Body not allowed for GET or HEAD requests");if(this._initBody(r),!("GET"!==this.method&&"HEAD"!==this.method||"no-store"!==t.cache&&"no-cache"!==t.cache)){var a=/([?&])_=[^&]*/;if(a.test(this.url))this.url=this.url.replace(a,"$1_="+(new Date).getTime());else{this.url+=(/\?/.test(this.url)?"&":"?")+"_="+(new Date).getTime()}}}function G(e){var t=new FormData;return e.trim().split("&").forEach(function(e){if(e){var n=e.split("="),i=n.shift().replace(/\+/g," "),r=n.join("=").replace(/\+/g," ");t.append(decodeURIComponent(i),decodeURIComponent(r))}}),t}function K(e,t){if(!(this instanceof K))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');if(t||(t={}),this.type="default",this.status=void 0===t.status?200:t.status,this.status<200||this.status>599)throw new RangeError("Failed to construct 'Response': The status provided (0) is outside the range [200, 599].");this.ok=this.status>=200&&this.status<300,this.statusText=void 0===t.statusText?"":""+t.statusText,this.headers=new R(t.headers),this.url=t.url||"",this._initBody(e)}z.prototype.clone=function(){return new z(this,{body:this._bodyInit})},j.call(z.prototype),j.call(K.prototype),K.prototype.clone=function(){return new K(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new R(this.headers),url:this.url})},K.error=function(){var e=new K(null,{status:200,statusText:""});return e.ok=!1,e.status=0,e.type="error",e};var X=[301,302,303,307,308];K.redirect=function(e,t){if(-1===X.indexOf(t))throw new RangeError("Invalid status code");return new K(null,{status:t,headers:{location:e}})};var V=D.DOMException;try{new V}catch(e){(V=function(e,t){this.message=e,this.name=t;var n=Error(e);this.stack=n.stack}).prototype=Object.create(Error.prototype),V.prototype.constructor=V}function W(e,t){return new Promise(function(n,i){var r=new z(e,t);if(r.signal&&r.signal.aborted)return i(new V("Aborted","AbortError"));var a=new XMLHttpRequest;function o(){a.abort()}if(a.onload=function(){var e,t,i={statusText:a.statusText,headers:(e=a.getAllResponseHeaders()||"",t=new R,e.replace(/\r?\n[\t ]+/g," ").split("\r").map(function(e){return 0===e.indexOf("\n")?e.substr(1,e.length):e}).forEach(function(e){var n=e.split(":"),i=n.shift().trim();if(i){var r=n.join(":").trim();try{t.append(i,r)}catch(e){console.warn("Response "+e.message)}}}),t)};0===r.url.indexOf("file://")&&(a.status<200||a.status>599)?i.status=200:i.status=a.status,i.url="responseURL"in a?a.responseURL:i.headers.get("X-Request-URL");var o="response"in a?a.response:a.responseText;setTimeout(function(){n(new K(o,i))},0)},a.onerror=function(){setTimeout(function(){i(new TypeError("Network request failed"))},0)},a.ontimeout=function(){setTimeout(function(){i(new TypeError("Network request timed out"))},0)},a.onabort=function(){setTimeout(function(){i(new V("Aborted","AbortError"))},0)},a.open(r.method,function(e){try{return""===e&&D.location.href?D.location.href:e}catch(t){return e}}(r.url),!0),"include"===r.credentials?a.withCredentials=!0:"omit"===r.credentials&&(a.withCredentials=!1),"responseType"in a&&(C?a.responseType="blob":F&&(a.responseType="arraybuffer")),t&&"object"===b(t.headers)&&!(t.headers instanceof R||D.Headers&&t.headers instanceof D.Headers)){var s=[];Object.getOwnPropertyNames(t.headers).forEach(function(e){s.push(I(e)),a.setRequestHeader(e,N(t.headers[e]))}),r.headers.forEach(function(e,t){-1===s.indexOf(t)&&a.setRequestHeader(t,e)})}else r.headers.forEach(function(e,t){a.setRequestHeader(t,e)});r.signal&&(r.signal.addEventListener("abort",o),a.onreadystatechange=function(){4===a.readyState&&r.signal.removeEventListener("abort",o)}),a.send(void 0===r._bodyInit?null:r._bodyInit)})}W.polyfill=!0,D.fetch||(D.fetch=W,D.Headers=R,D.Request=z,D.Response=K);var J=!1,q=null,Y=!1,Q=null;function Z(){if(J){if(J=!1,Q){try{Q.disconnect()}catch(e){}Q=null}q&&q.parentNode&&q.parentNode.removeChild(q),q=null}}function $(){if(!J&&!Y&&document.getElementById){var e=document.getElementById("loader");if(e){var t;try{t=window.getComputedStyle(e)}catch(e){t=null}(q=document.createElement("div")).id="ytaf-boot-overlay";var n=t&&t.backgroundColor||"rgb(40, 40, 40)",i=t&&t.backgroundImage||"none";q.style.cssText="position:fixed;top:0;left:0;width:100%;height:100%;z-index:2147483647;background-color:"+n+";background-image:"+i+";background-position:"+(t&&t.backgroundPosition||"center center")+";background-repeat:"+(t&&t.backgroundRepeat||"no-repeat")+";background-size:"+(t&&t.backgroundSize||"60%")+";",(document.body||document.documentElement).appendChild(q),J=!0,Y=!0}}}function ee(){if(!Y&&document.documentElement){try{(Q=new MutationObserver(function(){$(),Y&&Q&&Q.disconnect()})).observe(document.documentElement,{childList:!0,subtree:!0})}catch(e){}$(),setTimeout($,50),setTimeout($,200),setTimeout($,800),setTimeout($,2e3)}}function te(){return"undefined"!=typeof window&&window.h5vcc&&window.h5vcc.tizentube||null}window.__releaseBootLoader=Z,setTimeout(function(){if(Q){try{Q.disconnect()}catch(e){}Q=null}Z()},1e4),document.documentElement?ee():document.addEventListener("DOMContentLoaded",ee);var ne,ie,re={defaults:{enableAdBlock:!0,blockPlayerAdTracking:!0,blockAdTelemetry:!0,blockViewStatsTelemetry:!1,removeLiveVideos:!1,removeTopLiveGames:!1,removeMostRelevant:!1,enableSponsorBlock:!0,enableSponsorBlockToasts:!0,sponsorBlockManualSkips:["intro","outro","filler"],enableSponsorBlockSponsor:!0,enableSponsorBlockIntro:!0,enableSponsorBlockOutro:!0,enableSponsorBlockInteraction:!0,enableSponsorBlockSelfPromo:!0,enableSponsorBlockPreview:!0,enableSponsorBlockMusicOfftopic:!0,enableSponsorBlockFiller:!1,enableSponsorBlockHighlight:!0,videoSpeed:1,preferredVideoQuality:"auto",enableDeArrowTitles:!0,enableDeArrowThumbnails:!0,routeColor:"#0f0f0f",routeBackgroundUrl:"",themePreset:"default",textTheme:"default",userAgentProfile:"auto",enableFixedUI:!1,enableHqThumbnails:!0,enableLongPress:!0,enableShorts:!0,dontCheckUpdateUntil:0,enableWhoIsWatchingMenu:!1,permanentlyEnableWhoIsWatchingMenu:!1,enableWhosWatchingMenuOnAppExit:!1,enableShowUserLanguage:!0,enableShowOtherLanguages:!1,showWelcomeToast:!0,enablePreviousNextButtons:!0,enableSuperThanksButton:!1,enableSpeedControlsButton:!0,enablePatchingVideoPlayer:!0,enableMPButton:!0,enableSwapMPWithPIP:!1,enablePreviews:!0,previewLengthSeconds:40,enableRemainingTime:!1,enablePauseOnBlur:!1,enableLowMemoryMode:!1,enableHideWatchedVideos:!1,hideWatchedVideosThreshold:80,hideWatchedVideosPages:[],enableHideEndScreenCards:!1,enableYouThereRenderer:!0,enableScreenDimming:!1,dimmingTimeout:60,dimmingOpacity:.5,enablePaidPromotionOverlay:!0,speedSettingsIncrement:.25,videoPreferredCodec:"any",enableAutoSubtitles:!0,autoSubtitleLanguage:"en",autoSubtitleAllowAuto:!0,launchToOnStartup:null,reloadHomeOnStartup:!0,disabledSidebarContents:[],disableChannelsOnSidebar:!1,enableUpdater:!0,autoFrameRate:!1,autoFrameRatePauseVideoFor:0,enableSigninReminder:!1,sortSubscriptionsByAlphabet:!1,enableReducedMotion:!1,enablePerformanceMode:!1,enablePanelShrink:!0,enableDeArrowPeek:!0,panelShrinkPercent:"60",clockMode:"off",clockFormat:"24h",clockPosition:"topRight",clockShowSeconds:!1,enableOnePressMode:!1,enableExperimentalResolution:!1,experimentalMaxResolution:"1440p"},ranges:{videoSpeed:[.05,5],hideWatchedVideosThreshold:[0,100],dimmingTimeout:[1,3600],dimmingOpacity:[0,1],speedSettingsIncrement:[.01,1],autoFrameRatePauseVideoFor:[0,1e4],previewLengthSeconds:[5,120],dontCheckUpdateUntil:[0,9007199254740991]},enums:{preferredVideoQuality:["auto","2160p","1440p","1080p","720p","480p","360p","240p","144p"],videoPreferredCodec:["any","vp9","av01","avc1"],themePreset:["default","black","darkGray","charcoal","navy","darkRed","darkGreen","darkPurple"],textTheme:["default","white","gray","red","blue","green","purple","yellow"],userAgentProfile:["auto","samsung","android"],experimentalMaxResolution:["1440p","2160p"],autoSubtitleLanguage:["en","hi","es","fr","de","pt","ja","ko","ru"],panelShrinkPercent:["50","60","70"],clockMode:["off","always","notPlaying"],clockFormat:["24h","12h","12hNoAmPm"],clockPosition:["topLeft","topRight","bottomLeft","bottomRight"]},themePresetColors:{default:"#0f0f0f",black:"#000000",darkGray:"#1c1a1a",charcoal:"#121212",navy:"#0d1b2a",darkRed:"#3b0505",darkGreen:"#052e1b",darkPurple:"#1a1025"}};var ae=function(){if(ie)return ne;ie=1;var e=re;return ne={validateConfigValue:function(t,n){var i=e.defaults;if(!Object.prototype.hasOwnProperty.call(i,t))return!1;var r=i[t];if(null===r)return null===n||"string"==typeof n;if(Array.isArray(r))return Array.isArray(n)&&n.every(function(e){return"string"==typeof e});if("number"==typeof r){if("number"!=typeof n||!isFinite(n))return!1;var a=e.ranges[t];return!a||n>=a[0]&&n<=a[1]}if(b(n)!==b(r))return!1;var o=e.enums[t];return(!o||-1!==o.indexOf(n))&&(!("routeColor"===t&&!/^#[0-9a-f]{6}$/i.test(n))&&!("routeBackgroundUrl"===t&&n&&!/^https?:\/\/\S+$/i.test(n)))}},ne}(),oe=e(ae),se="ytaf-configuration",ue=JSON.parse,le=JSON.stringify,ce=function(e){return ue(le(e))},he=ce,de=ce(re.defaults);de.enableFixedUI=!te()||re.defaults.enableFixedUI;var pe,fe=oe.validateConfigValue;function me(e){if(Object.prototype.hasOwnProperty.call(de,e))return void 0===pe[e]&&(pe[e]=ce(de[e])),pe[e];console.warn("[AxoTube:config] Unknown config key",e)}function ye(e,t){if(!fe(e,t))return console.warn("[AxoTube:config] Rejected invalid config value",e,t),!1;pe[e]=ce(t);var n=function(){try{return!!window.localStorage&&(window.localStorage[se]=le(pe),!0)}catch(e){if("QuotaExceededError"===e.name){console.warn("[AxoTube:config] localStorage quota exceeded; replacing axotube config only");try{return"function"==typeof window.localStorage.removeItem?window.localStorage.removeItem(se):delete window.localStorage[se],window.localStorage[se]=le(pe),!0}catch(e){return console.error("[AxoTube:config] Failed to persist axotube config:",e),!1}}return console.error("[AxoTube:config] Failed to persist config:",e),!1}}();return ge.dispatchEvent(new CustomEvent("configChange",{detail:{key:e,value:ce(t)}})),n}!function(){pe=ce(de);try{if(!window.localStorage||!window.localStorage[se])return;var e=ue(window.localStorage[se]);if(!e||"object"!==b(e)||Array.isArray(e))return;Object.keys(e).forEach(function(t){fe(t,e[t])&&(pe[t]=ce(e[t]))})}catch(e){console.warn("[AxoTube:config] Config read failed; using defaults:",e)}}();var ge=new EventTarget;function ve(){return ce(pe)}var be,xe,Ee="axotube-user-agent-tried";function Se(e,t){try{window.__axotubeUserAgent={wanted:e,actual:navigator.userAgent,status:t}}catch(e){}console.log("[AxoTube:userAgentSpoofing] "+t+": "+navigator.userAgent)}function we(){return!!me("enablePerformanceMode")}function De(){return we()||!!me("enableReducedMotion")}function Ae(){return we()||!!me("enableLowMemoryMode")}function ke(){return!!me("enablePreviews")&&!we()}function Ce(){return me("enableHqThumbnails")?De()||Ae()?"hover":"eager":"off"}function Te(e){e&&"object"===b(e)&&Ae()&&(e.feature_switches&&"object"===b(e.feature_switches)||(e.feature_switches={}),e.feature_switches.enable_memory_saving_mode=!0)}be="android"===me("userAgentProfile")?"Mozilla/5.0 (Linux; Android 13; Pixel 7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Mobile Safari/537.36":"Mozilla/5.0 (SMART-TV; LINUX; Tizen 4.0) AppleWebKit/537.3 (KHTML, like Gecko) SamsungBrowser/2.1 TV Safari/537.3",navigator.userAgent!==be?function(e){try{if(window.tizen&&window.tizen.websetting&&"function"==typeof window.tizen.websetting.setUserAgentString)return window.tizen.websetting.setUserAgentString(e),!0}catch(e){console.warn("[AxoTube:userAgentSpoofing] setUserAgentString failed:",e)}return!1}(be)?function(e){try{return sessionStorage.getItem(Ee)===e}catch(e){return!1}}(be)?Se(be,"not-applied"):(function(e){try{sessionStorage.setItem(Ee,e)}catch(e){}}(be),Se(be,"set"),location.reload()):Se(be,"unavailable"):Se(be,"applied"),ge.addEventListener("configChange",function(e){var t;"enablePerformanceMode"===(null===(t=e.detail)||void 0===t?void 0:t.key)&&(me("enablePerformanceMode")||(ye("enableReducedMotion",!1),ye("enableLowMemoryMode",!1)))});try{var Fe=window.environment;Object.defineProperty(window,"environment",{configurable:!0,get:function(){return xe},set:function(e){Te(e),xe=e}}),xe=Fe,Te(Fe)}catch(e){console.warn("[AxoTube:lowMemoryMode] low memory mode unavailable:",e)}var Pe={"1440p":"2560x1440","2160p":"3840x2160"},Be={width:function(e){return Number(e)>0&&Number(e)<=7680},height:function(e){return Number(e)>0&&Number(e)<=4320},framerate:function(e){return Number(e)>0&&Number(e)<=60},bitrate:function(e){return Number(e)>0&&Number(e)<=2e8},eotf:function(e){return"bt709"===e||("smpte2084"===e||"arib-std-b67"===e)&&Ie()},channels:function(e){return Number(e)>0&&Number(e)<=8},cryptoblockformat:function(e){return"subsample"===e},"decode-to-texture":function(e){return"true"===e||"false"===e}};function Ie(){return!(!window.matchMedia||!window.matchMedia("(dynamic-range: high)").matches)}function Ne(e){var t=e.split("."),n="vp09"===t[0]?t[6]:"av01"===t[0]?t[7]:void 0;return"16"===n||"18"===n}var Me="__axotubeResolutionOwner";if(!window[Me]){if(window[Me]=!0,me("enableExperimentalResolution"))try{window.h5vcc=window.h5vcc||{},window.h5vcc.system=window.h5vcc.system||{},window.h5vcc.system.getVideoContainerSizeOverride=function(){var e=me("experimentalMaxResolution");return Pe[e]||Pe["1440p"]},function(){if(window.MediaSource&&"function"==typeof MediaSource.isTypeSupported){var e=MediaSource.isTypeSupported.bind(MediaSource);MediaSource.isTypeSupported=function(t){for(var n=String(t).split(";"),i=[n[0].trim()],r=1;r<n.length;r++){var a=n[r].trim(),o=a.indexOf("="),s=(-1===o?a:a.slice(0,o)).trim().toLowerCase(),u=(-1===o?"":a.slice(o+1)).trim().replace(/^"|"$/g,"");if("codecs"===s){for(var l=u.split(","),c=0;c<l.length;c++)if(Ne(l[c].trim())&&!Ie())return!1;i.push(a)}else if(Be[s]){if(!Be[s](u))return!1}else i.push(a)}return e(i.join("; "))}}}()}catch(e){console.warn("[AxoTube:experimentalResolution] Could not install overrides:",e)}ge.addEventListener("configChange",function(e){var t,n=(null===(t=e.detail)||void 0===t?void 0:t.key)||"";("enableExperimentalResolution"===n||"experimentalMaxResolution"===n&&me("enableExperimentalResolution"))&&setTimeout(function(){return location.reload()},300)})}var Re={avc1:["avc1"],vp9:["vp09","vp9"],av01:["av01"]};var Le="__axotubeCodecOwner";if(!window[Le]){window[Le]=!0;try{!function(e){if(window.MediaSource&&"function"==typeof MediaSource.isTypeSupported){var t=function(e){if(!Re[e])return[];var t=[];return Object.keys(Re).forEach(function(n){n!==e&&(t=t.concat(Re[n]))}),t}(e);if(0!==t.length){var n=MediaSource.isTypeSupported.bind(MediaSource);MediaSource.isTypeSupported=function(e){var i=String(e).toLowerCase();if(-1!==i.indexOf("codecs"))for(var r=0;r<t.length;r++)if(-1!==i.indexOf(t[r]))return!1;return n(e)}}}}(me("videoPreferredCodec"))}catch(e){console.warn("[AxoTube:codecPreference] Could not install codec preference:",e)}ge.addEventListener("configChange",function(e){var t;"videoPreferredCodec"===((null===(t=e.detail)||void 0===t?void 0:t.key)||"")&&setTimeout(function(){return location.reload()},300)})}var Oe;Oe||(Oe=1,function(){function e(e){return void 0===e?0:Number(e)}function t(e,t){return e!==t&&!(isNaN(e)&&isNaN(t))}self.DOMRect=function(n,i,r,a){var o,s,u,l,c,h,d,p;o=e(n),s=e(i),u=e(r),l=e(a),Object.defineProperties(this,{x:{get:function(){return o},set:function(e){t(o,e)&&(o=e,c=h=void 0)},enumerable:!0},y:{get:function(){return s},set:function(e){t(s,e)&&(s=e,d=p=void 0)},enumerable:!0},width:{get:function(){return u},set:function(e){t(u,e)&&(u=e,c=h=void 0)},enumerable:!0},height:{get:function(){return l},set:function(e){t(l,e)&&(l=e,d=p=void 0)},enumerable:!0},left:{get:function(){return void 0===c&&(c=o+Math.min(0,u)),c},enumerable:!0},right:{get:function(){return void 0===h&&(h=o+Math.max(0,u)),h},enumerable:!0},top:{get:function(){return void 0===d&&(d=s+Math.min(0,l)),d},enumerable:!0},bottom:{get:function(){return void 0===p&&(p=s+Math.max(0,l)),p},enumerable:!0}})}}());var _e={settings:{phoneSync:{title:"Phone sync",subtitle:"Pair a phone to change settings from it",intro:"Scan the code with your phone's camera to pair it. No typing needed.",address:"Or open {{url}} on your phone and enter the code.",code:"Pairing code: {{code}}",waiting:"Phone sync needs AxoTube's TV service. On a Samsung TV, open this panel again in a few seconds. On other devices, phone sync is not available.",qrHint:"Scan this with your phone's camera. The code is in the QR, so there is nothing to type.",noQr:"No phone address found. Check that the TV is on the same Wi-Fi as your phone, then open this again."},ttSettings:{title:"AxoTube Settings",summary:"Open AxoTube Settings",madeByText:"Made by Aayush with ❤️"},seconds:"{{count}} s",minutes:"{{count}} min",hintBack:"◀ Back",hintClose:"◀ Close",common:{auto:"Auto",any:"Any"},segmentModes:{skip:"Skip automatically",show:"Show skip button",off:"Off"},ads:{title:"Ads & sponsors",subtitle:"Ad blocking and SponsorBlock",blockAds:"Block ads",paidPromotion:"Show paid promotion notices",sponsorBlock:"Enable SponsorBlock",playerTracking:"Block player ad tracking",adTelemetry:"Block ad telemetry",viewStats:"Block view statistics",liveVideos:"Hide Live shelf",topLiveGames:"Hide Top Live Games shelf",mostRelevant:"Hide Most Relevant shelf",segmentTypes:{title:"Segment types",subtitle:"Press OK to change a type. It cycles through: skip automatically, show a skip button, off."},segments:{sponsor:"Sponsors",intro:"Intros",outro:"Outros",interaction:"Interaction reminders",selfpromo:"Self-promotion",preview:"Previews and recaps",filler:"Tangents and jokes",music_offtopic:"Off-topic music"},highlightButton:"Show highlight button",notices:"Show SponsorBlock notices"},playback:{title:"Playback",subtitle:"Quality, speed and captions",quality:{title:"Video quality",subtitle:"Quality used when a video starts. The closest available one is used if needed."},codec:{title:"Video codec",subtitle:"Preferred codec. Any lets YouTube choose."},speedStep:{title:"Speed step",subtitle:"How much each speed button press changes the playback speed."},frameRate:{title:"Frame rate",subtitle:"Switch the TV's refresh rate to match the video.",match:"Match video frame rate",pause:{title:"Pause during switch",subtitle:"Playback pauses for this long while the TV changes its refresh rate."}},pauseInBackground:"Out-of-focus pause (also when menus or panels open)",remainingTime:"Show time remaining",captions:{title:"Captions",subtitle:"Turn captions on by default, and choose the language they use.",onByDefault:"Subtitles on by default",language:{title:"Subtitle language",subtitle:"Preferred language for automatic captions."},allowAuto:"Allow auto-generated captions",myLanguage:"Show captions in my language",otherLanguages:"Show other languages"},languages:{en:"English",hi:"Hindi",es:"Spanish",fr:"French",de:"German",pt:"Portuguese",ja:"Japanese",ko:"Korean",ru:"Russian"},experimental:{title:"Higher resolutions (experimental)",subtitle:"Lets YouTube offer resolutions above the TV screen size. Can stutter on limited TVs. Restarts the app when changed.",unlock:"Unlock 1440p and 4K",max:{title:"Maximum resolution",subtitle:"Highest resolution YouTube may offer while the unlock is on."}},panelShrink:{title:"Video size while reading",subtitle:"Shrinks the video when the description or comments are open.",on:"Shrink video for description and comments",size:{title:"Video size",subtitle:"How large the video stays while a panel is open."}}},playerControls:{title:"Player controls",subtitle:"Extra buttons in the player. Turn on the first option to use the others.",customize:"Extra player buttons",previousNext:"Previous and next",speed:"Speed button",superThanks:"Super Thanks button",miniPlayer:"Mini player button",pipInsteadOfMini:"Use picture-in-picture instead of mini player",onePress:"One-press remote mode (OK plays or pauses, left and right skip 10 s)",hints:{customize:"Master switch for the extra buttons below. Off shows YouTube's own player buttons only.",previousNext:"Adds previous and next buttons to the player. Needs the switch above.",speed:"Shows a button that changes the playback speed.",superThanks:"Shows or hides the Super Thanks button.",miniPlayer:"Adds a button that shrinks the video into a mini player.",pipInsteadOfMini:"That button opens picture-in-picture instead of the mini player.",paidPromotion:"Shows a notice on videos with paid promotion.",onePress:"Remote-friendly controls: OK plays or pauses, left and right skip 10 seconds."}},browsing:{title:"Browsing",subtitle:"Thumbnails, previews and what appears on screen",thumbnails:{title:"Thumbnails and titles",subtitle:"DeArrow shows community titles and thumbnails in place of clickbait. Service: dearrow.ajay.app"},hqThumbnails:"High-quality thumbnails",deArrowTitles:"DeArrow titles",deArrowThumbnails:"DeArrow thumbnails",previews:{title:"Video previews",subtitle:"Plays a short preview when a video is focused.",on:"Show video previews",length:"Preview length"},hideWatched:{title:"Hide watched videos",subtitle:"Hides videos you have mostly watched.",on:"Hide watched videos",threshold:{title:"Watched threshold",subtitle:"Videos watched past this percentage are hidden."},pages:{title:"Hide on these pages",subtitle:"Pages where watched videos are hidden."}},shorts:"Show Shorts",endScreens:"Hide end screen cards",longPress:"Long press OK to add to queue",stillWatching:'Show "Are you still watching?" prompts',deArrowPeek:"Long press shows the other title and thumbnail"},home:{title:"Home & sidebar",subtitle:"Startup page and sidebar items",startup:{title:"Startup page",subtitle:"The page AxoTube opens at launch."},reloadHome:"Reload home on startup",sidebarItems:{title:"Hide sidebar items",subtitle:"Selected items are hidden from the sidebar."},hideChannels:"Hide channels from the sidebar",sortSubscriptions:"Sort subscriptions A to Z"},appearance:{title:"Appearance",subtitle:"Colours, clock, dimming and performance",theme:{title:"Theme",subtitle:"Colours used across the interface.",presets:{title:"Preset",subtitle:"A ready-made colour set."},background:{title:"Background colour",subtitle:"Colour behind the main content."},text:{title:"Text colour",subtitle:"Colour of the text in the interface."}},colors:{default:"Default (dark)",black:"Black",darkGray:"Dark gray",charcoal:"Charcoal",navy:"Navy blue",darkRed:"Dark red",darkGreen:"Dark green",darkPurple:"Dark purple"},textColors:{default:"Default",white:"White",gray:"Gray",red:"Red",blue:"Blue",green:"Green",purple:"Purple",yellow:"Yellow"},dimming:{title:"Screen dimming",subtitle:"Dims the screen when you stop interacting.",on:"Dim the screen when idle",timeout:{title:"Dim after",subtitle:"How long to wait before the screen dims."},opacity:{title:"Dimming strength",subtitle:"How dark the screen gets."}},fullAnimations:"Full-quality animations",performance:"Performance mode (memory part applies after reload)",clock:{title:"Clock",subtitle:"Show the time on screen.",show:{title:"When to show",subtitle:"Always, or only while no video is playing.",off:"Off",always:"Always",notPlaying:"When no video is playing"},format:{title:"Time format",subtitle:"24-hour, or 12-hour with or without AM and PM.",h24:"24-hour (14:05)",h12:"12-hour with AM/PM (2:05 PM)",h12NoAmPm:"12-hour, no AM/PM (2:05)"},position:{title:"Position",subtitle:"Corner of the screen for the clock.",topLeft:"Top left",topRight:"Top right",bottomLeft:"Bottom left",bottomRight:"Bottom right"},seconds:"Show seconds"}},system:{title:"System",subtitle:"Memory, accounts and updates",whosWatching:{title:"Who's watching menu",subtitle:"Choose a profile when the app starts.",on:"Show who's watching menu",always:"Always show it",onExit:"Show when leaving the app"},signInReminder:"Sign-in reminder for guests",welcome:"Welcome message",updates:{title:"Updates",subtitle:"Version {{version}}. Checks for new releases.",checkNow:"Check for updates now",onStartup:"Check for updates on startup"},reload:"Reload AxoTube",restartCast:"Restart cast receiver"},about:{title:"About AxoTube",version:"Version {{version}}",scanMessage:"Scan the QR code to open {{name}}.",subtitle:"Versions and status",userscript:"✅ Userscript {{version}}, running",serviceOnline:"✅ Service {{version}}, online on port 8090",serviceOffline:"⚠️ Service not reachable on port 8090",proxyOnline:"✅ Proxy {{version}}, online on port 8081",proxyOffline:"⚠️ Proxy not reachable on port 8081",bundleCurrent:"📦 App bundle {{version}}",bundleUpdate:"📦 App bundle {{current}}, update {{latest}} ready",bundleUnknown:"📦 App bundle not checked yet",launchMode:"🚀 Launch mode: {{mode}}",launchUnknown:"🚀 Launch mode unknown while the service is not running",socials:{title:"🔗 Socials",subtitle:"Pick one to show its QR code.",githubHint:"Source code, releases and issues",discordHint:"Community chat"}},webConfig:{title:"Web config",subtitle:"Pairing code, phone address and service status",online:"AxoTube service: online",offline:"AxoTube service is not running, so the web config page is not available.",qrTitle:"📱 Pair with your phone",qrSubtitle:"Show a code for your phone to scan",rowHint:"Also on your phone: background image and more"},status:{checking:"Checking the services…"},advanced:{title:"Advanced",subtitle:"Diagnostics, user agent and launch mode",diagnostics:{title:"Diagnostics page",subtitle:"Launch log, versions and what the app last did"},userAgent:{title:"User agent",subtitle:"The browser identity YouTube sees. Takes effect after AxoTube reloads. The phone agent is experimental on TV.",samsung:"Samsung TV (default)",android:"Android phone (experimental)"},launch:{title:"Launch mode",subtitle:"Applies the next time AxoTube starts. SDB needs developer mode on the TV.",proxy:"Proxy (recommended)",debugger:"SDB debugger launch",proxyShort:"proxy",debuggerShort:"SDB debugger",saved:"Launch mode saved. It applies the next time AxoTube starts.",failed:"Could not save the launch mode. Is AxoTube running?"}},moreOnWeb:{text:"More settings, like a background image, are on the web config page."},axotube:{title:"AxoTube",subtitle:"Web config, updates, who’s watching and startup behaviour of AxoTube"}},welcomeMsg:{title:"Welcome to AxoTube",subtitle:"Go to settings and click on AxoTube Settings for settings."},sponsorblock:{segments:{sponsor:"sponsored segment",intro:"intro",outro:"outro",interaction:"interaction reminder",selfpromo:"self-promotion",preview:"recap or preview",filler:"tangents",music_offtopic:"non-music part",poi_highlight:"highlight"},toasts:{skipping:"Skipping {{segment}}",notSkipping:"Not skipping {{segment}} (was skipped {{count}} times)",skip:"Skip {{segment}}",skipToHighlight:"Skip to highlight",undone:"Skip undone: {{segment}}"}},app:{name:"axotube"},menu:{play:"Play",saveWatchLater:"Save to Watch Later",saveToPlaylist:"Save to Playlist",addToQueue:"Add to Queue"},player:{miniPlayer:"Mini Player",pictureInPicture:"Picture in Picture",speedControls:"Speed Controls",previous:"Previous",next:"Next",withAxotube:"with axotube"},toasts:{queueAdded:"Video added to queue.",queueAddFailed:"Nothing to add to the queue.",queueCleared:"Video queue cleared.",updateDownloading:"Downloading update, please wait...",upToDate:"You are on the latest version ({{version}}).",updateNoApk:"Version {{version}} is available, but no compatible APK was found in the release.",updateCheckFailed:"Could not check for updates.",serviceConnected:"Service connected",commandReceived:"Command received",pairingWithUrl:"Open {{url}} on your phone · code {{code}}",pairingCodeOnly:"Phone pairing code: {{code}}",updateApplyFailed:"The update could not be applied. Try again later.",castRestarted:"Cast receiver restarted. Phones should see the TV again shortly.",castRestarting:"Restarting cast receiver…",castRestartWait:"Cast receiver was just restarted. Try again in a few seconds.",castRestartFailed:"Could not restart the cast receiver.",castRestartNotRunning:"Cast discovery is not running. Restart the app to bring it back.",castRestartUnsupported:"Restarting cast is not available on this device."},playback:{retryPrompt:"Playback stopped at {{time}}. Press blue to retry from there."},updater:{reloadWhenPaused:"Update installed. It takes effect when playback pauses or the video ends.",modalTitle:"Update Available",modalBody:"A new version of axotube is available: {{latest}}\nCurrent version: {{current}}\nRelease date: {{date}}\nRelease notes:",unknownDate:"Unknown",updateNow:"Update Now",updateNowSubtitle:"Click to download the latest version.",remindLater:"Remind Me Later",remindLaterSubtitle:"Check for updates later.",modalBodyNew:"Version {{latest}} is available. You are on {{current}}. Update now and the page will reload.",applying:"Updating…"}},Ue=/\{\{\s*([\w.]+)\s*\}\}/g;function je(e,t){var n=function(e){for(var t=_e,n=e.split("."),i=0;i<n.length;i++){if(null===t||"object"!==b(t)||!Object.prototype.hasOwnProperty.call(t,n[i]))return;t=t[n[i]]}return"string"==typeof t?t:void 0}(e);return void 0===n?e:t?n.replace(Ue,function(e,n){return Object.prototype.hasOwnProperty.call(t,n)?String(t[n]):e}):n}var He=null,ze=null,Ge=null,Ke=null,Xe=null,Ve=!1,We=[];function Je(){try{return"undefined"==typeof window?null:window._yttv||null}catch(e){return null}}function qe(e,t){try{var n=e[t],i=n&&n.instance;if(i&&"function"==typeof i.resolveCommand)return{root:n,instance:i}}catch(e){}return null}function Ye(e){if(Xe)try{Xe(e)}catch(e){}}function Qe(){var e=Je();if(e){if(e===He&&null!==Ge){var t=qe(e,ze);if(t&&t.root===Ge&&t.instance===Ke)return Ye(t.instance),t.instance}He=e,Ge=null,Ke=null,ze=null;try{for(var n in e){var i=qe(e,n);if(i)return ze=n,Ge=i.root,Ke=i.instance,Ye(i.instance),i.instance}}catch(e){}}try{if("undefined"!=typeof window&&"function"==typeof window._yttv_resolveCommand)return{resolveCommand:function(e,t){return window._yttv_resolveCommand(e,t)}}}catch(e){}return null}function Ze(){return!!Qe()}function $e(e,t){var n=Qe();return n?{dispatched:!0,result:n.resolveCommand(e,t)}:{dispatched:!1}}function et(e,t){return $e(e,t).result}function tt(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!e)return Promise.resolve(!1);var n=void 0===t.maxAttempts?50:t.maxAttempts,i=void 0===t.retryDelayMs?200:t.retryDelayMs;return new Promise(function(t){var r=0;!function a(){var o=Qe();if(o)try{o.resolveCommand(e),t(!0)}catch(e){try{console.warn("[AxoTube:nativeCommand] native command threw after dispatch attempt; not retrying",e)}catch(e){}t(!0)}else r>=n?t(!1):(r+=1,setTimeout(a,i))}()})}function nt(){var e=Je();if(!e)return!1;var t=!1;try{for(var n in e){var i=qe(e,n);i&&(t=!0,Ye(i.instance))}}catch(e){}return t}var it=[250,1e3,3e3];function rt(){nt();var e,t=c(We);try{for(t.s();!(e=t.n()).done;){var n=e.value;clearTimeout(n)}}catch(e){t.e(e)}finally{t.f()}We=it.map(function(e){return setTimeout(nt,e)})}function at(e){return pt(je("menu.addToQueue"),{clickTrackingParams:null,playlistEditEndpoint:{customAction:{action:"ADD_TO_QUEUE",parameters:e}}})}function ot(e,t){return et(e,t)}function st(e,t,n){var i={title:{simpleText:e},subtitle:{simpleText:t},accessibilityData:{accessibilityData:{label:t?"".concat(e," - ").concat(t):e}},trackingParams:"CAEQlYkGGhMI"};n&&n.length>0&&(i.image={thumbnails:n}),ot({openPopupAction:{popupType:"TOAST",popup:{overlayToastRenderer:i}}})}function ut(e,t,n,i){var r=function(e,t,n,i){var r="string"==typeof e?{title:e,subtitle:""}:e||{title:"",subtitle:""},a={openPopupAction:{popupType:"MODAL",popup:{overlaySectionRenderer:{overlay:{overlayTwoPanelRenderer:{actionPanel:{overlayPanelRenderer:{header:{overlayPanelHeaderRenderer:r.overlayPanelHeaderRenderer||{title:{simpleText:r.title}}},content:t}},backButton:{buttonRenderer:{accessibilityData:{accessibilityData:{label:"Back"}},command:{signalAction:{signal:"POPUP_BACK"}}}}}},dismissalCommand:{signalAction:{signal:"POPUP_BACK"}}}},uniqueId:n}};return r.subtitle&&(a.openPopupAction.popup.overlaySectionRenderer.overlay.overlayTwoPanelRenderer.actionPanel.overlayPanelRenderer.header.overlayPanelHeaderRenderer.subtitle={simpleText:r.subtitle}),i&&(a.openPopupAction.shouldMatchUniqueId=!0,a.openPopupAction.updateAction=!0),a}(e,t,n,i);ot(r)}function lt(e,t){return{overlayPanelItemListRenderer:{items:e,selectedIndex:t}}}function ct(e,t,n){var i={compactLinkRenderer:{serviceEndpoint:{commandExecutorCommand:{commands:n}}}};return e&&(i.compactLinkRenderer.title={simpleText:e.title}),e&&e.subtitle&&(i.compactLinkRenderer.subtitle={simpleText:e.subtitle}),t&&(i.compactLinkRenderer.icon={iconType:t.icon}),t&&t.secondaryIcon&&(i.compactLinkRenderer.secondaryIcon={iconType:t.secondaryIcon}),i}function ht(e,t,n,i,r){return{timelyActionRenderer:{actionButtons:[{buttonRenderer:{isDisabled:!1,text:{runs:[{text:e}]},icon:{iconType:t},trackingParams:null,command:n}}],triggerTimeMs:i,timeoutMs:r,type:""}}}function dt(e){return{clickTrackingParams:null,showMenuCommand:{contentId:e.videoId,thumbnail:{thumbnails:e.thumbnails},title:{simpleText:e.title},subtitle:{simpleText:e.subtitle},menu:{menuRenderer:{items:[ft(je("menu.play"),{clickTrackingParams:null,watchEndpoint:e.watchEndpointData}),pt(je("menu.saveWatchLater"),{clickTrackingParams:null,playlistEditEndpoint:{playlistId:"WL",actions:[{addedVideoId:e.videoId,action:"ACTION_ADD_VIDEO"}]}}),ft(je("menu.saveToPlaylist"),{clickTrackingParams:null,addToPlaylistEndpoint:{videoId:e.videoId}}),at(e.item)],trackingParams:null,accessibility:{accessibilityData:{label:"Video options"}}}}}}}function pt(e,t){return{menuServiceItemRenderer:{text:{runs:[{text:e}]},serviceEndpoint:t,trackingParams:null}}}function ft(e,t){return{menuNavigationItemRenderer:{text:{runs:[{text:e}]},navigationEndpoint:t,trackingParams:null}}}function mt(e){return{overlayMessageRenderer:{title:{simpleText:e}}}}function yt(e){return{qrCodeRenderer:{qrCodeImage:{thumbnails:[{url:e}]},style:"QR_CODE_RENDERER_STYLE_ATA_SIDESHEET",trackingParams:null}}}function gt(e,t,n,i){return{isDisabled:e,text:{runs:[{text:t}]},icon:{iconType:n},command:i,trackingParams:null}}function vt(e){try{return e&&"function"==typeof e.getInstance&&e.getInstance()||null}catch(e){return null}}function bt(e){if(!e)return null;try{var t=Object.getPrototypeOf(e);if(!t)return null;var n,i=c(Object.getOwnPropertyNames(t));try{for(i.s();!(n=i.n()).done;){var r=n.value,a=void 0;try{a=e[r]}catch(e){continue}if("function"==typeof a)try{if(a.toString().includes("ytlrActionRouter"))return a}catch(e){}}}catch(e){i.e(e)}finally{i.f()}}catch(e){}return null}function xt(){if(window._yttv){var e=null,t=null;try{for(var n in window._yttv){var i=void 0;try{i=window._yttv[n]}catch(e){continue}if(i&&"function"==typeof i.getInstance){var r=vt(i);if(r){try{if(i.toString().includes("ytlrActionRouter")){t=bt(e=r);break}}catch(e){}var a=bt(r);if(a){e=r,t=a;break}}}}}catch(e){return}if(e&&t){var o=null;try{for(var s in window._yttv){var u=void 0;try{u=window._yttv[s]}catch(e){continue}if("function"==typeof u)try{if(u.toString().includes("this.actionName")){o=u;break}}catch(e){}}}catch(e){}if(o)return{executeFunction:t.bind(e),commandFunction:o}}}}ge.addEventListener("configChange",function(e){if("disabledSidebarContents"===e.detail.key||"disableChannelsOnSidebar"===e.detail.key)try{var t=xt();t&&t.executeFunction(new t.commandFunction("reloadGuideAction"))}catch(e){console.warn("[AxoTube:customGuideAction] Guide reload failed:",e)}});var Et=null;var St=["adSlot","adPlacements","playerAds","promo","Promo","hideLogo","tvMasthead","attestation","adBreak","adClientParams"],wt=["adPlacements","playerAds","adSlots","paidContentOverlay","streamingData","contents","endscreen","messages","entries","title","continuationContents","playerOverlays","transportControls","attestation","adBreakHeartbeatParams","playerResponse"];function Dt(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function At(e){return!(!e||!e.adSlotRenderer)}function kt(e){return!!(e&&e.tileRenderer&&("TVHTML5_TILE_RENDERER_TYPE_SHORTS"===e.tileRenderer.tvhtml5ShelfRendererType||e.tileRenderer.onSelectCommand&&e.tileRenderer.onSelectCommand.reelWatchEndpoint))}function Ct(e){if(!e||"object"!==b(e))return!1;for(var t=Object.keys(e),n=0;n<t.length;n++)if(-1!==t[n].toLowerCase().indexOf("promo"))return!0;return!!(e.shelfRenderer&&e.shelfRenderer.tvhtml5Metadata&&e.shelfRenderer.tvhtml5Metadata.hideLogo)}function Tt(e){return!(!e||"object"!==b(e)||!e.tvMastheadRenderer)}function Ft(e){if(!e)return"";var t=e.title||e.headerRenderer&&e.headerRenderer.tvHeaderRenderer&&e.headerRenderer.tvHeaderRenderer.title;return t?"string"==typeof t.simpleText?t.simpleText:t.runs&&t.runs[0]&&"string"==typeof t.runs[0].text?t.runs[0].text:"":""}function Pt(e){return e?/recommend/i.test(e)?null:/top\s+live\s+games?/i.test(e)?"topLiveGames":/most\s+relevant/i.test(e)?"mostRelevant":/^live(\s+now)?$/i.test(e.trim())?"live":null:null}function Bt(e,t){try{if("undefined"==typeof window)return;var n=window.__axotubeAdblockStats||(window.__axotubeAdblockStats={});n[e]=(n[e]||0)+(void 0===t?1:t)}catch(e){}}function It(){try{if("undefined"==typeof window||!0!==window.__axotubeAdblockDebug)return;if("undefined"==typeof console)return;var e=["[AxoTube:adblock]"].concat(Array.prototype.slice.call(arguments));console.log.apply(console,e)}catch(e){}}var Nt={};function Mt(e,t){var n=Nt[e];if(n||(n=Nt[e]={errors:0,open:!1}),!n.open)try{return t()}catch(t){return n.errors++,Bt("error:"+e),It("filter error",e,t),void(n.errors>=5&&(n.open=!0,"undefined"!=typeof console&&console.warn&&console.warn("[AxoTube:adblock] '"+e+"' disabled after 5 errors this session")))}}var Rt=["attestation","adBreakHeartbeatParams"];function Lt(e){for(var t=0,n=0;n<Rt.length;n++)Dt(e,Rt[n])&&(delete e[Rt[n]],t++);return t}function Ot(e){var t=new Map;return{get:function(e){return t.get(e)},has:function(e){return t.has(e)},set:function(n,i){for(t.set(n,i);t.size>e;)t.delete(t.keys().next().value);return i},delete:function(e){return t.delete(e)},clear:function(){t.clear()}}}var _t=["maxresdefault.jpg","sddefault.jpg","hqdefault.jpg","mqdefault.jpg","default.jpg"],Ut={"maxresdefault.jpg":{width:1280,height:720},"sddefault.jpg":{width:640,height:480},"hqdefault.jpg":{width:480,height:360},"mqdefault.jpg":{width:320,height:180},"default.jpg":{width:120,height:90}},jt=Ot(256),Ht=new Map;function zt(e){if(!e||!e.includes("i.ytimg.com/vi/"))return null;var t=e.match(/\/vi\/([a-zA-Z0-9_-]+)\//);return t?t[1]:null}function Gt(e){return Array.isArray(e)&&e.length>0&&e[0].width&&e[0].width>100}var Kt=Ot(256);function Xt(e){var t,n=[],i=c(_t);try{for(i.s();!(t=i.n()).done;){var r=t.value,a=Ut[r];n.push({url:"https://i.ytimg.com/vi/".concat(e,"/").concat(r),width:a.width,height:a.height})}}catch(e){i.e(e)}finally{i.f()}return n}function Vt(e,t){if(e&&"object"===b(e))for(var n in e)"thumbnails"===n&&Gt(e[n])?e[n]=t:"object"===b(e[n])&&Vt(e[n],t)}var Wt,Jt=(Wt=5e3,function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=null;try{"function"==typeof AbortController&&(n=new AbortController)}catch(e){}var i=n?f(f({},t),{},{signal:n.signal}):t,r=null,a=new Promise(function(e,t){r=setTimeout(function(){try{n&&n.abort()}catch(e){}t(new Error("Fetch timed out after ".concat(Wt,"ms")))},Wt)});return Promise.race([fetch(e,i),a]).finally(function(){null!==r&&clearTimeout(r)})}),qt=Ot(256),Yt=Ot(256);function Qt(e){return e&&e.titles&&0!==e.titles.length?e.titles.reduce(function(e,t){return e.votes>t.votes?e:t}).title:null}function Zt(e,t){if(!t||!t.thumbnails||0===t.thumbnails.length)return null;var n=t.thumbnails.reduce(function(e,t){return e.votes>t.votes?e:t});return void 0===n.timestamp||null===n.timestamp?null:Number.isFinite(Number(n.timestamp))?[{url:"https://dearrow-thumb.ajay.app/api/v1/getThumbnail?videoID=".concat(e,"&time=").concat(n.timestamp),width:1280,height:640}]:null}function $t(e,t,n,i,r){try{if(i&&n.titles&&n.titles.length>0){var a,o=Qt(n);null!==(a=e.tileRenderer)&&void 0!==a&&null!==(a=a.metadata)&&void 0!==a&&null!==(a=a.tileMetadataRenderer)&&void 0!==a&&a.title&&(e.tileRenderer.metadata.tileMetadataRenderer.title.simpleText=o)}if(r){var s,u=Zt(t,n);u&&null!==(s=e.tileRenderer)&&void 0!==s&&null!==(s=s.header)&&void 0!==s&&null!==(s=s.tileHeaderRenderer)&&void 0!==s&&s.thumbnail&&(e.tileRenderer.header.tileHeaderRenderer.thumbnail.thumbnails=u)}}catch(e){console.warn("[AxoTube:deArrow] Error processing DeArrow data:",e)}}function en(e){var t=me("enableDeArrowTitles"),n=me("enableDeArrowThumbnails"),i=me("enableDeArrowPeek");if(t||n||i)for(var r=function(){var i=e[a];if(i.adSlotRenderer)return e.splice(a,1),0;if(!i.tileRenderer)return 0;var r=i.tileRenderer.contentId;if(!r)return 0;!function(e,t){var n,i,r,a;if(!Yt.get(t)){var o=e.tileRenderer;Yt.set(t,{title:null!==(n=null==o||null===(i=o.metadata)||void 0===i||null===(i=i.tileMetadataRenderer)||void 0===i||null===(i=i.title)||void 0===i?void 0:i.simpleText)&&void 0!==n?n:null,thumbnails:null!==(r=null==o||null===(a=o.header)||void 0===a||null===(a=a.tileHeaderRenderer)||void 0===a||null===(a=a.thumbnail)||void 0===a?void 0:a.thumbnails)&&void 0!==r?r:null})}}(i,r);var o={item:i,titlesEnabled:t,thumbnailsEnabled:n},s=qt.get(r);if(s)return s.data?$t(i,r,s.data,t,n):Array.isArray(s.waiters)&&s.waiters.push(o),0;var u={data:null,waiters:[o]};qt.set(r,u),Jt("https://sponsor.ajay.app/api/branding?videoID=".concat(r)).then(function(e){if(!e.ok)throw new Error("DeArrow HTTP ".concat(e.status));return e.json()}).then(function(e){u.data=e;var t=u.waiters.slice();u.waiters.length=0;var n,i=c(t);try{for(i.s();!(n=i.n()).done;){var a=n.value;$t(a.item,r,e,a.titlesEnabled,a.thumbnailsEnabled)}}catch(e){i.e(e)}finally{i.f()}}).catch(function(){qt.get(r)===u&&qt.delete(r)})},a=e.length-1;a>=0;a--)r()}function tn(e){var t=e.tileRenderer,n={};return void 0!==t.contentType&&(n.contentType=t.contentType),void 0!==t.style&&(n.style=t.style),void 0!==t.contentId&&(n.contentId=t.contentId),void 0!==t.trackingParams&&(n.trackingParams=t.trackingParams),void 0!==t.metadata&&(n.metadata=he(t.metadata)),void 0!==t.header&&(n.header=he(t.header)),void 0!==t.onSelectCommand&&(n.onSelectCommand=he(t.onSelectCommand)),{tileRenderer:n}}function nn(e){return e.some(function(e){var t;return"ADD_TO_QUEUE"===(null==e||null===(t=e.menuServiceItemRenderer)||void 0===t||null===(t=t.serviceEndpoint)||void 0===t||null===(t=t.playlistEditEndpoint)||void 0===t||null===(t=t.customAction)||void 0===t?void 0:t.action)})}function rn(e){if(ke()&&!/#\/watch/.test(location.hash||"")){var t,n=1e3*me("previewLengthSeconds"),i=c(e);try{for(i.s();!(t=i.n()).done;){var r,a,o,s=t.value;if(s.tileRenderer){var u=null===(r=s.tileRenderer.onSelectCommand)||void 0===r?void 0:r.watchEndpoint;if(u&&!(null!==(a=s.tileRenderer)&&void 0!==a&&null!==(a=a.onFocusCommand)&&void 0!==a&&a.playbackEndpoint||null!==(o=s.tileRenderer)&&void 0!==o&&null!==(o=o.onFocusCommand)&&void 0!==o&&o.commandExecutorCommand)){var l=he({watchEndpoint:u});s.tileRenderer.onFocusCommand={startInlinePlaybackCommand:{blockAdoption:!0,caption:!1,delayMs:3e3,durationMs:n,muted:!1,restartPlaybackBeforeSeconds:10,resumeVideo:!0,playbackEndpoint:l}}}}}}catch(e){i.e(e)}finally{i.f()}}}function an(e){if(!me("enableHideWatchedVideos"))return e;var t=me("hideWatchedVideosPages");if(!t||!t.length)return e;var n=me("hideWatchedVideosThreshold"),i=location.hash.substring(1),r=function(e){var t={},n=e.indexOf("?");if(-1===n)return t;for(var i=e.slice(n+1).split("&"),r=0;r<i.length;r++)if(i[r]){var a=i[r].indexOf("="),o=-1===a?i[r]:i[r].slice(0,a),s=-1===a?"":i[r].slice(a+1);try{t[decodeURIComponent(o)]=decodeURIComponent(s)}catch(e){t[o]=s}}return t}(i),a=r.browseId||r.browse_id||"",o="/"===i?"home":i.startsWith("/search")?"search":a.replace("FE","").replace("topics_","");return t.includes(o)?e.filter(function(e){var t;if(!e.tileRenderer)return!0;var i=null===(t=e.tileRenderer.header)||void 0===t||null===(t=t.tileHeaderRenderer)||void 0===t||null===(t=t.thumbnailOverlays)||void 0===t||null===(t=t.find(function(e){return e.thumbnailOverlayResumePlaybackRenderer}))||void 0===t?void 0:t.thumbnailOverlayResumePlaybackRenderer;return!i||(i.percentDurationWatched||0)<=n}):e}function on(e,t){return function(e){if("eager"===Ce()){var t,n=c(e);try{for(n.s();!(t=n.n()).done;){var i=t.value;if(i.tileRenderer)try{var r,a,o,s,u=null===(r=i.tileRenderer.onSelectCommand)||void 0===r||null===(r=r.watchEndpoint)||void 0===r?void 0:r.videoId;if(!u)continue;if((null===(a=i.tileRenderer.header)||void 0===a||null===(a=a.tileHeaderRenderer)||void 0===a||null===(a=a.thumbnail)||void 0===a?void 0:a.thumbnails)===Kt.get(u))continue;var l=Kt.get(u);l||(l=Kt.set(u,Xt(u))),null!==(o=i.tileRenderer.header)&&void 0!==o&&null!==(o=o.tileHeaderRenderer)&&void 0!==o&&null!==(o=o.thumbnail)&&void 0!==o&&o.thumbnails&&(i.tileRenderer.header.tileHeaderRenderer.thumbnail.thumbnails=l),null!==(s=i.tileRenderer.onFocusCommand)&&void 0!==s&&null!==(s=s.startInlinePlaybackCommand)&&void 0!==s&&null!==(s=s.playbackEndpoint)&&void 0!==s&&null!==(s=s.startPlaylistItemEndpoint)&&void 0!==s&&null!==(s=s.playlistItemData)&&void 0!==s&&null!==(s=s.thumbnail)&&void 0!==s&&s.thumbnails&&(i.tileRenderer.onFocusCommand.startInlinePlaybackCommand.playbackEndpoint.startPlaylistItemEndpoint.playlistItemData.thumbnail.thumbnails=l),i.tileRenderer.onFocusCommand&&Vt(i.tileRenderer.onFocusCommand,l)}catch(e){console.warn("[AxoTube:hqThumbnails] Error processing thumbnail:",e)}}}catch(e){n.e(e)}finally{n.f()}}}(e),en(e),function(e){if(me("enableLongPress")){var t,n=c(e);try{for(n.s();!(t=n.n()).done;){var i,r,a,o,s,u,l=t.value;if(l.tileRenderer&&"TILE_STYLE_YTLR_DEFAULT"===l.tileRenderer.style&&l.tileRenderer.contentId&&null!==(i=l.tileRenderer.onSelectCommand)&&void 0!==i&&i.watchEndpoint)if(l.tileRenderer.onLongPressCommand){var h,d=null===(h=l.tileRenderer.onLongPressCommand)||void 0===h||null===(h=h.showMenuCommand)||void 0===h||null===(h=h.menu)||void 0===h||null===(h=h.menuRenderer)||void 0===h?void 0:h.items;Array.isArray(d)&&!nn(d)&&d.push(at(tn(l)))}else{var p=null===(r=l.tileRenderer.metadata)||void 0===r?void 0:r.tileMetadataRenderer;if(p&&null!==(a=l.tileRenderer.header)&&void 0!==a&&null!==(a=a.tileHeaderRenderer)&&void 0!==a&&null!==(a=a.thumbnail)&&void 0!==a&&a.thumbnails){var f=null===(o=p.lines)||void 0===o||null===(o=o[0])||void 0===o||null===(o=o.lineRenderer)||void 0===o||null===(o=o.items)||void 0===o||null===(o=o[0])||void 0===o||null===(o=o.lineItemRenderer)||void 0===o?void 0:o.text;if(f){var m=(null===(s=f.runs)||void 0===s||null===(s=s[0])||void 0===s?void 0:s.text)||f.simpleText||"",y=tn(l),g=dt({videoId:y.tileRenderer.contentId,thumbnails:y.tileRenderer.header.tileHeaderRenderer.thumbnail.thumbnails,title:(null===(u=p.title)||void 0===u?void 0:u.simpleText)||"",subtitle:m,watchEndpointData:y.tileRenderer.onSelectCommand.watchEndpoint,item:y});l.tileRenderer.onLongPressCommand=g}}}}}catch(e){n.e(e)}finally{n.f()}}}(e),t&&rn(e),an(e)}function sn(e,t){for(var n=t||{},i=n.optional||{},r=e.length-1;r>=0;r--){var a=e[r];if(a&&"object"===b(a))if(n.removeAds&&(Ct(a)||Tt(a)))Bt(Tt(a)?"bannerRemoved":"shelfRemoved"),e.splice(r,1);else if(a.shelfRenderer){var o=a.shelfRenderer,s=Pt(Ft(o));if(s&&i[s])Bt("optionalShelfRemoved"),e.splice(r,1);else{var u=o.content&&o.content.horizontalListRenderer;if(u&&u.items)if(n.removeShorts&&"TVHTML5_SHELF_RENDERER_TYPE_SHORTS"===o.tvhtml5ShelfRendererType)e.splice(r,1);else{var l=u.items,c=0;if(n.removeAds||n.removeShorts)(c=l.length-(l=l.filter(function(e){return!(n.removeAds&&At(e)||n.removeShorts&&kt(e))})).length)&&(u.items=l,Bt("itemRemoved",c));c>0&&0===l.length?(Bt("emptyShelfRemoved"),e.splice(r,1)):u.items=on(l,!1!==n.addPreviews)}}}}}var un=["adSlotRenderer","promoShelfRenderer","tvMastheadRenderer"],ln=["adPlacements","adSlots"],cn=["playerAds"],hn=["attestation","adBreakHeartbeatParams"];function dn(e){for(var t=0;t<un.length;t++)if(Dt(e,un[t]))return!0;return!1}function pn(e,t,n){return n.signin?e:function(e,t){return e.filter(function(e){return!(e&&e[t])})}(e,t)}function fn(e,t){var n=(Array.isArray(e.timelyActionRenderers)?e.timelyActionRenderers:[]).filter(function(e){return!function(e){var t=e&&e.timelyActionRenderer&&e.timelyActionRenderer.actionButtons;return!!Array.isArray(t)&&t.some(function(e){return e&&e.buttonRenderer&&e.buttonRenderer.command&&e.buttonRenderer.command.showEngagementPanelEndpoint&&e.buttonRenderer.command.showEngagementPanelEndpoint.customAction&&"SKIP"===e.buttonRenderer.command.showEngagementPanelEndpoint.customAction.action})}(e)});e.timelyActionRenderers=n.concat(t)}function mn(e,t){var n,i,r,a=null==e||null===(n=e.playerOverlays)||void 0===n?void 0:n.playerOverlayRenderer;a&&fn(a,function(e){var t,n=[],i=e.sponsorManualSkips;if(!Array.isArray(i)||0===i.length||null===(t=window)||void 0===t||null===(t=t.sponsorblock)||void 0===t||!t.segments)return n;var r,a=c(window.sponsorblock.segments);try{for(a.s();!(r=a.n()).done;){var o=r.value;i.includes(o.category)&&n.push(ht(je("sponsorblock.toasts.skip",{segment:je("sponsorblock.segments.".concat(o.category))}),"SKIP_NEXT",{clickTrackingParams:null,showEngagementPanelEndpoint:{customAction:{action:"SKIP",parameters:{time:o.segment[1]}}}},1e3*o.segment[0],1e3*o.segment[1]-1e3*o.segment[0]))}}catch(e){a.e(e)}finally{a.f()}return n}(t));var o=null==e||null===(i=e.transportControls)||void 0===i||null===(i=i.transportControlsRenderer)||void 0===i?void 0:i.promotedActions;if(o&&t.sponsorHighlight&&null!==(r=window)&&void 0!==r&&null!==(r=r.sponsorblock)&&void 0!==r&&r.segments){var s=window.sponsorblock.segments.find(function(e){return"poi_highlight"===e.category});s&&o.push({type:"TRANSPORT_CONTROLS_BUTTON_TYPE_SPONSORBLOCK_HIGHLIGHT",button:{buttonRenderer:gt(!1,je("sponsorblock.toasts.skipToHighlight"),"SKIP_NEXT",{clickTrackingParams:null,customAction:{action:"SKIP",parameters:{time:s.segment[0]}}})}})}}var yn=["/pagead/","/ptracking","/eligibility_check"],gn=["/api/stats/watchtime","/api/stats/playback","/api/stats/qoe","/api/stats/atr"];function vn(e,t){for(var n=0;n<t.length;n++)if(-1!==e.indexOf(t[n]))return!0;return!1}var bn,xn="data:application/json,{}";function En(e){return function(e,t){return!!("string"==typeof e&&e&&(t.ads&&vn(e,yn)||t.viewStats&&vn(e,gn)))}(e,{ads:!1!==me("blockAdTelemetry"),viewStats:!!me("blockViewStatsTelemetry")})}function Sn(e,t,n){return{removeAds:t,removeShorts:!e.shorts,addPreviews:n,optional:{live:e.removeLiveVideos,topLiveGames:e.removeTopLiveGames,mostRelevant:e.removeMostRelevant}}}function wn(e){e.sort(function(e,t){var n,i,r,a,o,s,u=null==e||null===(n=e.tabRenderer)||void 0===n?void 0:n.title,l=null==t||null===(i=t.tabRenderer)||void 0===i?void 0:i.title;return null===(r=e.tabRenderer)||void 0===r||!r.selected||null!==(a=t.tabRenderer)&&void 0!==a&&a.selected?null!==(o=e.tabRenderer)&&void 0!==o&&o.selected||null===(s=t.tabRenderer)||void 0===s||!s.selected?u&&l?u.localeCompare(l):0:1:-1})}!function(e){if(e&&!e.__axotubeTelemetryHooks){e.__axotubeTelemetryHooks=!0;var t=e.XMLHttpRequest;if(t&&t.prototype&&"function"==typeof t.prototype.open){var n=t.prototype.open;t.prototype.open=function(e,t){var i=Array.prototype.slice.call(arguments);try{En(t)&&(Bt("telemetryBlocked"),It("blocked XHR",t),i[0]="GET",i[1]=xn)}catch(e){It("telemetry XHR hook error",e)}return n.apply(this,i)}}if("function"==typeof e.fetch){var i=e.fetch;e.fetch=function(t){try{var n="string"==typeof t?t:t&&t.url;if(En(n))return Bt("telemetryBlocked"),It("blocked fetch",n),"function"==typeof e.Response&&"function"==typeof Promise?Promise.resolve(new e.Response("{}",{status:200,headers:{"Content-Type":"application/json"}})):i.call(this,xn)}catch(e){It("telemetry fetch hook error",e)}return i.apply(this,arguments)}}var r=e.navigator;if(r&&"function"==typeof r.sendBeacon){var a=r.sendBeacon;r.sendBeacon=function(e){try{if(En(e))return Bt("telemetryBlocked"),It("blocked beacon",e),!0}catch(e){It("telemetry beacon hook error",e)}return a.apply(this,arguments)}}}}("undefined"!=typeof window?window:null),function(e){if(Et)return Et;var t=JSON.parse,n=[];function i(i,r){var a=t.apply(this,arguments);if(!a||"object"!==b(a)||Array.isArray(a))return a;for(var o=0;o<e.length;o++)try{e[o](a,i)}catch(e){n[o]||(n[o]=!0,console.error("[AxoTube:responsePipeline] AxoTube JSON response filter failed:",e))}return a}function r(){var e=!1;try{if("undefined"==typeof window||!window._yttv)return!1;var t=window._yttv;for(var n in t)try{var r=t[n]&&t[n].JSON;r&&"function"==typeof r.parse&&(e=!0,r.parse!==i&&(r.parse=i))}catch(e){}}catch(e){}return e}JSON.parse=i,Et=i;var a=r();if("undefined"!=typeof window&&"function"==typeof setTimeout){var o=function(){a=r()||a,++s>=32||setTimeout(o,!a&&s<20?250:5e3)},s=0;setTimeout(o,a?5e3:250)}}([function(e,t){var n,i,r,a,o,s,u;if(function(e){for(var t=0;t<wt.length;t++)if(e[wt[t]])return!0;return!1}(e)){var l={adBlock:!!me("enableAdBlock"),signin:!!me("enableSigninReminder"),paidPromo:!!me("enablePaidPromotionOverlay"),hideEndScreens:!!me("enableHideEndScreenCards"),youThere:!!me("enableYouThereRenderer"),shorts:!!me("enableShorts"),sortSubscriptions:!!me("sortSubscriptionsByAlphabet"),preferredCodec:me("videoPreferredCodec"),blockPlayerTracking:!1!==me("blockPlayerAdTracking"),removeLiveVideos:!!me("removeLiveVideos"),removeTopLiveGames:!!me("removeTopLiveGames"),removeMostRelevant:!!me("removeMostRelevant"),sponsorManualSkips:me("sponsorBlockManualSkips"),sponsorHighlight:!!me("enableSponsorBlockHighlight")},c=function(e){if("string"!=typeof e)return!0;for(var t=0;t<St.length;t++)if(-1!==e.indexOf(St[t]))return!0;return!1}(t),h=l.adBlock&&c;h&&Mt("topLevelAds",function(){return function(e){e.adPlacements&&(e.adPlacements=[]),e.playerAds&&(e.playerAds=!1),e.adSlots&&(e.adSlots=[]),!Array.isArray(e)&&e.entries&&(e.entries=e.entries.filter(function(e){return!(e&&e.command&&e.command.reelWatchEndpoint&&e.command.reelWatchEndpoint.adClientParams&&e.command.reelWatchEndpoint.adClientParams.isAd)}))}(e)}),c&&l.blockPlayerTracking&&Mt("playerTracking",function(){return function(e){var t=Lt(e);return e.playerResponse&&"object"===b(e.playerResponse)&&(t+=Lt(e.playerResponse)),t&&Bt("playerTrackingRemoved",t),t}(e)}),Mt("streamFormats",function(){return function(e,t){if(e&&e.streamingData&&e.streamingData.adaptiveFormats&&t&&"any"!==t){var n=e.streamingData.adaptiveFormats;n.find(function(e){return e.mimeType&&e.mimeType.includes(t)})&&(e.streamingData.adaptiveFormats=n.filter(function(e){return!(!e.mimeType||!e.mimeType.startsWith("audio/"))||e.mimeType&&e.mimeType.includes(t)}))}}(e,l.preferredCodec)}),Mt("playerNotices",function(){return function(e,t){e.paidContentOverlay&&!t.paidPromo&&(e.paidContentOverlay=null),e.endscreen&&t.hideEndScreens&&(e.endscreen=null),e.messages&&Array.isArray(e.messages)&&!t.youThere&&(e.messages=e.messages.filter(function(e){return!(e&&e.youThereRenderer)}))}(e,l)});var d,p,f,m,y,g,v=null==e||null===(n=e.contents)||void 0===n||null===(n=n.tvBrowseRenderer)||void 0===n||null===(n=n.content)||void 0===n||null===(n=n.tvSurfaceContentRenderer)||void 0===n||null===(n=n.content)||void 0===n?void 0:n.sectionListRenderer;null!=v&&v.contents&&Mt("browse",function(){v.contents=pn(v.contents,"feedNudgeRenderer",l),h&&(v.contents=v.contents.filter(function(e){return!At(e)})),sn(v.contents,Sn(l,h,!0))}),null!=e&&null!==(i=e.title)&&void 0!==i&&i.runs&&(d=e,g=function(e,t,n){var i={settingCategoryCollectionRenderer:{items:t,categoryId:e,focused:!1,trackingParams:"null"}};return n&&(i.settingCategoryCollectionRenderer.title={runs:[{text:n}]}),i}("axotube_category",[(p=je("settings.ttSettings.title"),f="axotube_open_action",m={customAction:{action:"AXO_SETTINGS_SHOW",parameters:[]}},y=je("settings.ttSettings.summary"),{settingActionRenderer:{title:{runs:[{text:p}]},serviceEndpoint:m,summary:{runs:[{text:y}]},trackingParams:"null",actionLabel:{runs:[{text:p}]},itemId:f,thumbnail:{thumbnails:[{url:"https://www.gstatic.com/ytlr/img/parent_code.png"}]}}})]),d.items&&Array.isArray(d.items)||(d.items=[]),d.items.unshift(g)),null!=e&&null!==(r=e.contents)&&void 0!==r&&null!==(r=r.sectionListRenderer)&&void 0!==r&&r.contents&&Mt("sectionList",function(){return sn(e.contents.sectionListRenderer.contents,Sn(l,h,!0))}),null!=e&&null!==(a=e.continuationContents)&&void 0!==a&&null!==(a=a.sectionListContinuation)&&void 0!==a&&a.contents&&Mt("sectionContinuation",function(){return sn(e.continuationContents.sectionListContinuation.contents,Sn(l,h,!0))}),null!=e&&null!==(o=e.continuationContents)&&void 0!==o&&null!==(o=o.horizontalListContinuation)&&void 0!==o&&o.items&&Mt("horizontalContinuation",function(){var t=e.continuationContents.horizontalListContinuation;t.items=on(t.items,!1)});var x=null==e||null===(s=e.contents)||void 0===s||null===(s=s.tvBrowseRenderer)||void 0===s||null===(s=s.content)||void 0===s||null===(s=s.tvSecondaryNavRenderer)||void 0===s?void 0:s.sections;x&&Mt("secondaryNav",function(){for(var e=0;e<x.length;e++){var t=x[e].tvSecondaryNavSectionRenderer;if(t&&t.tabs){l.sortSubscriptions&&wn(t.tabs);for(var n=0;n<t.tabs.length;n++){var i,r,a=null===(i=t.tabs[n].tabRenderer.content)||void 0===i||null===(i=i.tvSurfaceContentRenderer)||void 0===i?void 0:i.content;null!=a&&null!==(r=a.sectionListRenderer)&&void 0!==r&&r.contents&&sn(a.sectionListRenderer.contents,Sn(l,h,!0))}}}});var E=null==e||null===(u=e.contents)||void 0===u||null===(u=u.singleColumnWatchNextResults)||void 0===u||null===(u=u.pivot)||void 0===u?void 0:u.sectionListRenderer;E&&Mt("watchNext",function(){E.contents=pn(E.contents,"alertWithActionsRenderer",l),sn(E.contents,Sn(l,h,!1)),function(e){if(window.queuedVideos.videos.length){var t=window.queuedVideos.videos.slice();t.unshift({tileRenderer:{contentType:"TILE_CONTENT_TYPE_VIDEO",metadata:{tileMetadataRenderer:{title:{simpleText:"Clear Queue"}}},onSelectCommand:{customAction:{action:"CLEAR_QUEUE"}},style:"TILE_STYLE_YTLR_DEFAULT"}});var n=t.findIndex(function(e){return e.contentId===window.queuedVideos.lastVideoId});e.unshift(function(e,t){return{shelfRenderer:{shelfHeaderRenderer:{title:{simpleText:e}},tvhtml5ShelfRendererType:"TVHTML5_SHELF_RENDERER_TYPE_GRID",content:{horizontalListRenderer:{items:t,selectedIndex:arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,visibleItemCount:3}}}}}("Queued Videos",t,-1!==n?n:0))}}(E.contents)}),Mt("sponsorBlock",function(){return mn(e,l)}),h&&"string"==typeof t&&t.length>=1e4&&Mt("fallback",function(){var t=function(e,t){for(var n=!(!t||!t.player),i=0,r=0,a=!1,o=[{node:e,depth:0}],s=0;s<o.length;){var u=o[s++],l=u.node;if(l&&"object"===b(l)){if(++r>2e3){a=!0;break}if(Array.isArray(l)){for(var c=l.length-1;c>=0;c--){var h=l[c];h&&"object"===b(h)&&dn(h)&&(l.splice(c,1),i++)}if(u.depth<8)for(var d=0;d<l.length;d++)o.push({node:l[d],depth:u.depth+1})}else{for(var p=0;p<ln.length;p++){var f=ln[p];Array.isArray(l[f])&&l[f].length&&(l[f]=[],i++)}for(var m=0;m<cn.length;m++){var y=cn[m];l[y]&&(l[y]=!1,i++)}if(n)for(var g=0;g<hn.length;g++)Dt(l,hn[g])&&(delete l[hn[g]],i++);if(u.depth<8)for(var v in l)Dt(l,v)&&l[v]&&"object"===b(l[v])&&o.push({node:l[v],depth:u.depth+1})}}}return a&&It("fallback search hit node cap",2e3),{removed:i,nodes:r,truncated:a}}(e,{player:l.blockPlayerTracking});t.removed&&(Bt("knownPathMiss",t.removed),Bt("fallbackRemoved",t.removed),It("fallback removed",t.removed,"entries from",t.nodes,"nodes"))})}},function(e){if(Array.isArray(e.items)){var t=me("disabledSidebarContents"),n=me("disableChannelsOnSidebar");if(null!=t&&t.length||n)for(var i=0;i<e.items.length;i++){var r=e.items[i]&&e.items[i].guideSectionRenderer;if(r&&Array.isArray(r.items))for(var a=0;a<r.items.length;a++){var o,s=r.items[a]&&r.items[a].guideEntryRenderer;s&&((null!=t&&t.length&&t.includes(null===(o=s.icon)||void 0===o?void 0:o.iconType)||n&&null!=s&&s.thumbnail)&&(r.items.splice(a,1),a--))}}}}]),bn=JSON.stringify,JSON.stringify=function(e,t,n){var i,r=null==e||null===(i=e.playbackContext)||void 0===i?void 0:i.contentPlaybackContext;if(r&&!r.isInlinePlaybackNoAd){var a=Object.prototype.hasOwnProperty.call(r,"isInlinePlaybackNoAd"),o=r.isInlinePlaybackNoAd;try{return r.isInlinePlaybackNoAd=!0,bn.apply(this,arguments)}finally{a?r.isInlinePlaybackNoAd=o:delete r.isInlinePlaybackNoAd}}return bn.apply(this,arguments)},window.JSON.stringify=JSON.stringify;var Dn={enablePremiumHbrSupport:!0,abortPendingPageRequests:!0,enableWebGlobalConfigHotConfig:!1,enablePremiumLiteUpsellLr:!1,enablePremiumPageDeeplink:!1,premiumLiteUpsellMaxTimesSeen:Number.MAX_SAFE_INTEGER,premiumLiteUpsellSeenRecentlyDays:9999,premiumLiteUpsellSerializedParams:"",enableIfaReporting:!1,enableIfaEncryption:!1,enableAdsClientLogging:!1,enableNetworkMonitoringUnified:!1,enableHiddenVisibilityLogging:!1,enableCobaltMetrics:!1,enableCobaltRequestHistograms:!1,enableCobaltHttpCache:!1,enableCobaltHttpCacheLogging:!1,reportAuthCredentialIntervalSeconds:0,oneClickSeek:"on",enableSkipPreviousButton5sThreshold:!0,enableCaptionsPersistence:!0,enableKabukiCaptionPersistence:!0,enableGridWatchNext:!0,enableNavLoadOnRightArrow:!0,enableRenderSingleSearchBar:!0,lazyLoadingAlgorithm:0,enableNewAudioSettingsMenu:!0,enableDirectEntryToShortsClient:!0,enableYtlrKeyboardForSearch:!0,enablePostPlayMode:!0,enablePaidTosViewer:!0,useReduxForPlayerStyles:!0};function An(){try{return!("undefined"==typeof window||!window.tectonicConfig||"object"!==b(window.tectonicConfig.featureSwitches))&&(window.tectonicConfig.disallowUnifiedFlagAccess=!1,Object.assign(window.tectonicConfig.featureSwitches,Dn),!0)}catch(e){return!1}}var kn=0;function Cn(e){if("off"!==Ce()&&e&&!1!==e.isConnected){var t="",n=!1;if("IMG"===e.tagName&&e.src)t=e.src;else if(e.style&&e.style.backgroundImage){var i=e.style.backgroundImage.match(/url\(['"]?(.*?)['"]?\)/);i&&i[1]&&(t=i[1],n=!0)}if(t&&t.includes("i.ytimg.com/vi/")){var r=zt(t);if(r&&e.getAttribute("data-hq-upgraded")!==r){var a=t.match(/\/(maxresdefault|sddefault|hqdefault|mqdefault|default)\.jpg/),o=a?a[1]:"default",s=jt.get(r);if(s&&o+".jpg"===s)e.setAttribute("data-hq-upgraded",r);else{e.setAttribute("data-hq-upgraded",r);var u=function(t){if(e&&!1!==e.isConnected){var i="https://i.ytimg.com/vi/"+r+"/"+t;n?e.style.backgroundImage='url("'+i+'")':(e.removeAttribute("srcset"),e.src=i)}};s?u(s):function(e,t){if(e&&"function"==typeof t){var n=jt.get(e);if(n)t(n);else if(Ht.has(e))Ht.get(e).push(t);else{Ht.set(e,[t]);var i=function(t){var n=Ht.get(e)||[];Ht.delete(e),jt.set(e,t),n.forEach(function(e){try{e(t)}catch(e){}})},r=function(t,n){var r=new Image;r.onload=function(){120===this.naturalWidth&&90===this.naturalHeight?n():i(t)},r.onerror=n,r.src="https://i.ytimg.com/vi/".concat(e,"/").concat(t)};r("maxresdefault.jpg",function(){r("sddefault.jpg",function(){return i("hqdefault.jpg")})})}}}(r,function(e){u(e)})}}}}}function Tn(){var e={subtree:!0,childList:!0,attributes:!0,attributeFilter:["class","src","srcset","style"]},t=function(e){if(e){var t=e.shadowRoot||e,n=t.querySelector?t.querySelector("img"):null;!n&&t!==e&&e.querySelector&&(n=e.querySelector("img")),n&&Cn(n);var i=[];t.querySelectorAll?i=t.querySelectorAll('[style*="background-image"]'):e.querySelectorAll&&(i=e.querySelectorAll('[style*="background-image"]'));for(var r=0;r<i.length;r++)Cn(i[r]);e.style&&e.style.backgroundImage&&Cn(e)}},n=function(e){for(var t=e;t;){if(t.classList&&t.classList.contains("zylon-focus"))return t;if(t.closest){var n=t.closest(".zylon-focus");if(n)return n}var i=t.parentElement;if(!i&&t.getRootNode){var r=t.getRootNode();i=r&&r.host||null}t=i}return null},i=null,r=null,a=null,o=function(){if(!i){var o=document.getElementById("container")||document.body;o&&(i=new MutationObserver(function(e){r=r?r.concat(e):e,a||(a=requestAnimationFrame(function(){a=null;var e=r||[];r=null,function(e){try{for(var i=null,r=0;r<e.length;r++){var a=e[r],o=a.target;if("attributes"!==a.type||"class"!==a.attributeName)if("attributes"!==a.type){if("childList"===a.type){i||(i=document.querySelector(".zylon-focus"));for(var s=!1,u=0;u<a.addedNodes.length;u++){var l=a.addedNodes[u];if(1===l.nodeType)if(i&&(i===l||i.contains(l)||l.contains(i)))s||(t(i),s=!0);else if(!i&&l.querySelectorAll)for(var c=l.querySelectorAll(".zylon-focus"),h=0;h<c.length;h++)t(c[h])}}}else{if("src"===a.attributeName||"srcset"===a.attributeName){if("IMG"!==o.tagName)continue;var d="src"===a.attributeName?o.getAttribute("src"):o.getAttribute("srcset");if(!d||-1===d.indexOf("i.ytimg.com/vi/"))continue}else{if("style"!==a.attributeName)continue;var p=o.style&&o.style.backgroundImage;if(!p||-1===p.indexOf("i.ytimg.com/vi/"))continue}if(n(o)){var f=o.getAttribute("data-hq-upgraded"),m="";if("IMG"===o.tagName)m=o.src;else if(o.style&&o.style.backgroundImage){var y=o.style.backgroundImage.match(/url\(['"]?(.*?)['"]?\)/);m=y?y[1]:""}var g=m?zt(m):null;if(f&&f===g)continue;o.removeAttribute("data-hq-upgraded"),Cn(o)}}else o.classList&&o.classList.contains("zylon-focus")&&t(o)}}catch(e){console.error("[AxoTube:hqThumbnailsFocusObserver] Focus handling failed:",e)}}(e)}))}),i.observe(o,e))}},s=function(){"off"!==Ce()?o():(i&&(i.disconnect(),i=null),a&&(cancelAnimationFrame(a),a=null),r=null)},u=["enableHqThumbnails","enablePerformanceMode","enableReducedMotion","enableLowMemoryMode"];ge.addEventListener("configChange",function(e){e.detail&&-1!==u.indexOf(e.detail.key)&&s()}),s()}!function e(){An()||(kn+=1)>=50||setTimeout(e,200)}(),ge.addEventListener("configChange",function(){An()}),"loading"===document.readyState?document.addEventListener("DOMContentLoaded",function(){setTimeout(Tn,1e3)}):setTimeout(Tn,1e3);var Fn={player:[],video:[],videoId:[]},Pn=null,Bn=null,In=null,Nn=null,Mn=!1;function Rn(){return document.querySelector(".html5-video-player")}function Ln(){return document.querySelector("video")}function On(e){try{var t=e&&"function"==typeof e.getVideoData&&e.getVideoData();if(t&&t.video_id)return t.video_id}catch(e){}var n=/[?&]v=([^&]+)/.exec(window.location.hash||"");return n?n[1]:null}function _n(e,t,n){Fn[e].slice().forEach(function(e){try{e(t,n)}catch(e){console.warn("[AxoTube:playerLifecycle] Listener failed:",e)}})}function Un(){var e=Rn(),t=Ln(),n=On(e),i=Pn,r=Bn,a=In;Pn=e,Bn=t,In=n,e!==i&&_n("player",e,i),t!==r&&_n("video",t,r),n!==a&&_n("videoId",n,a)}function jn(e,t){if("function"!=typeof t)throw new TypeError("A lifecycle listener must be a function");Mn||(Mn=!0,window.addEventListener("hashchange",Un),document.addEventListener("DOMContentLoaded",Un),Nn=setInterval(Un,2e3),Un()),Un(),Fn[e].push(t);var n="player"===e?Pn:"video"===e?Bn:In;try{t(n,null)}catch(e){console.warn("[AxoTube:playerLifecycle] Listener failed:",e)}return function(){var n=Fn[e].indexOf(t);-1!==n&&Fn[e].splice(n,1),Fn.player.length||Fn.video.length||Fn.videoId.length||Mn&&(Mn=!1,clearInterval(Nn),Nn=null,window.removeEventListener("hashchange",Un),document.removeEventListener("DOMContentLoaded",Un),Pn=null,Bn=null,In=null)}}function Hn(e){return jn("player",e)}function zn(e){return jn("video",e)}function Gn(e){return jn("videoId",e)}function Kn(e,t){var n=null;return{promise:new Promise(function(i,r){(n=new XMLHttpRequest).open("GET",e,!0),n.timeout=t,n.onload=function(){if(404===n.status)return i(null);if(n.status<200||n.status>=300)return r(new Error("HTTP ".concat(n.status," for ").concat(e)));try{i(JSON.parse(n.responseText))}catch(e){r(e)}},n.onerror=function(){r(new Error("network error for ".concat(e)))},n.ontimeout=function(){r(new Error("timed out after ".concat(t,"ms for ").concat(e)))},n.onabort=function(){r(new Error("aborted"))},n.send()}),abort:function(){n&&4!==n.readyState&&n.abort()}}}var Xn=["https://sponsor.ajay.app/api","https://sponsorblock.inf.re/api"],Vn=["sponsor","intro","outro","interaction","selfpromo","preview","filler","music_offtopic","poi_highlight"],Wn={sponsor:"enableSponsorBlockSponsor",intro:"enableSponsorBlockIntro",outro:"enableSponsorBlockOutro",interaction:"enableSponsorBlockInteraction",selfpromo:"enableSponsorBlockSelfPromo",preview:"enableSponsorBlockPreview",filler:"enableSponsorBlockFiller",music_offtopic:"enableSponsorBlockMusicOfftopic"},Jn={sponsor:"#00d400",intro:"#00ffff",outro:"#0202ed",interaction:"#cc00ff",selfpromo:"#ffff00",preview:"#008fd6",filler:"#7300FF",music_offtopic:"#ff9900",poi_highlight:"#9b044c"},qn=Ot(20),Yn="axotube-sponsorblock-segments",Qn='ytlr-progress-bar [idomkey="slider"]',Zn="".concat(Qn,"::after, ").concat('ytlr-multi-markers-player-bar-renderer [idomkey^="chapter-"]',"::after { content: ''; position: absolute; inset: 0; pointer-events: none; opacity: 0.7; }");function $n(e){return Jn[e]||"blue"}function ei(e){return je("sponsorblock.segments.".concat(e))||e}function ti(e){for(var t=[],n=0;n<e.length;n++)-1===t.indexOf(e[n])&&t.push(e[n]);return t.join(", ")}function ni(e,t){if("poi_highlight"===e)return me("enableSponsorBlockHighlight")?"highlight":"off";var n=Wn[e];return n&&me(n)?-1!==t.indexOf(e)?"show":"skip":"off"}function ii(e){var t=document.getElementById(Yn);e?(t||((t=document.createElement("style")).id=Yn,(document.head||document.documentElement).appendChild(t)),t.textContent!==e&&(t.textContent=e)):t&&(t.textContent="")}function ri(e,t,n){for(var i=[],r=0;r<e.length;r++){var a=e[r];if(!(a.end<=t||a.start>=n)){var o=Math.max(0,(a.start-t)/(n-t)*100),s=Math.min(100,(a.end-t)/(n-t)*100);i.push("linear-gradient(to right, transparent ".concat(o,"%, ").concat(a.color," ").concat(o,"%, ").concat(a.color," ").concat(s,"%, transparent ").concat(s,"%)"))}}return i.length?i.join(", "):"none"}var ai=function(){return l(function e(t){var n=this;r(this,e),this.videoID=t,this.destroyed=!1,this.segments=[],this.active=[],this.drawn=[],this.done={},this.lastSkip=null,this.landing=null,this.settle=null,this.suppressRearm=!1,this.lastT=0,this.videoDuration=0,this.video=null,this.listeners=null,this.request=null,this.frameId=null,this.seekIssuedAt=0,this.barAt=0,this.onTick=function(){return n.tick()},this.onSeeked=function(){return n.handleSeeked()},this.onDuration=function(){n.redrawBar(),n.tick()},this.frame=function(){n.frameId=null,n.tick()},this.refresh()},[{key:"load",value:function(){var e=this,t=qn.get(this.videoID);if(t)this.apply(t);else{var n,i,r,a,o,s=(n=this.videoID,i=[],r=!1,a=function(){for(var e=0;e<i.length;e++)i[e].abort()},o="videoID=".concat(encodeURIComponent(n),"&service=YouTube&categories=").concat(encodeURIComponent(JSON.stringify(Vn))),{promise:new Promise(function(e){for(var t=0,n=function(t){r||(r=!0,a(),e(t))},s=function(){(t+=1)===Xn.length&&n(null)},u=0;u<Xn.length;u++){var l=Kn("".concat(Xn[u],"/skipSegments?").concat(o),4e3);i.push(l),l.promise.then(function(e){null===e?n([]):Array.isArray(e)?n(e):s()},s)}}),abort:function(){r=!0,a()}});this.request=s,s.promise.then(function(t){if(e.request===s&&(e.request=null,!e.destroyed&&t)){var n=function(e){for(var t=[],n=0,i=0;i<e.length;i++){var r=e[i];if(r&&"string"==typeof r.category&&Array.isArray(r.segment)){var a=r.segment[0],o=r.segment[1];"number"==typeof a&&"number"==typeof o&&a>=0&&o>a&&(r.actionType&&"skip"!==r.actionType||"number"==typeof r.votes&&r.votes<0||("number"==typeof r.videoDuration&&r.videoDuration>n&&(n=r.videoDuration),t.push({key:String(r.UUID||"".concat(r.category,":").concat(a,":").concat(o)),category:r.category,segment:[a,o],start:a,end:o,mode:"off"})))}}return t.sort(function(e,t){return e.start-t.start||t.end-e.end}),t.videoDuration=n,t}(t);qn.set(e.videoID,n),e.apply(n)}},function(){e.request===s&&(e.request=null)})}}},{key:"apply",value:function(e){this.destroyed||(this.segments=e,this.videoDuration=e.videoDuration||0,this.refresh(),this.tick())}},{key:"refresh",value:function(){for(var e=me("sponsorBlockManualSkips"),t=Array.isArray(e)?e:[],n=[],i=[],r=0;r<this.segments.length;r++){var a=this.segments[r];a.mode=ni(a.category,t),"skip"!==a.mode&&"show"!==a.mode||n.push(a),"off"!==a.mode&&i.push(a)}this.active=n,this.drawn=i,this.redrawBar()}},{key:"attach",value:function(e){if(!this.destroyed&&e!==this.video&&(this.detach(),e)){this.video=e,this.lastT=e.currentTime||0,this.listeners=[["timeupdate",this.onTick],["play",this.onTick],["playing",this.onTick],["ratechange",this.onTick],["seeked",this.onSeeked],["durationchange",this.onDuration],["loadedmetadata",this.onDuration]];for(var t=0;t<this.listeners.length;t++)e.addEventListener(this.listeners[t][0],this.listeners[t][1]);this.redrawBar(),this.tick()}}},{key:"detach",value:function(){if(this.video&&this.listeners)for(var e=0;e<this.listeners.length;e++)this.video.removeEventListener(this.listeners[e][0],this.listeners[e][1]);this.listeners=null,this.video=null,null!==this.frameId&&(cancelAnimationFrame(this.frameId),this.frameId=null)}},{key:"tick",value:function(){var e=this.video;if(!this.destroyed&&e&&(this.refreshBar(),!(e.paused||e.seeking&&Date.now()-this.seekIssuedAt<2e3))){var t=e.currentTime;if(t>=0&&!(this.videoDuration>0&&isFinite(e.duration)&&Math.abs(e.duration-this.videoDuration)>3)){t<this.lastT-1&&!this.settling(t)&&this.rearm(t),this.lastT=t;var n=this.dueIndex(t);-1!==n&&this.skipAt(n,t),this.video&&null===this.frameId&&this.nearNext(this.video.currentTime)&&(this.frameId=requestAnimationFrame(this.frame))}}}},{key:"dueIndex",value:function(e){if(this.inManual(e))return-1;for(var t=0;t<this.active.length;t++){var n=this.active[t];if(n.start-.1>e)break;if(!("skip"!==n.mode||n.end<=e||this.done[n.key]))return t}return-1}},{key:"inManual",value:function(e){for(var t=0;t<this.active.length;t++){var n=this.active[t];if(n.start>e)break;if("show"===n.mode&&n.end>e)return!0}return!1}},{key:"jumpTarget",value:function(e,t){for(var n=this.active[e],i=n.end,r=!1,a=[n],o=e+1;o<this.active.length;o++){var s=this.active[o];if(s.start>i+.25)break;if("show"===s.mode){s.start>t&&s.start<i&&s.start>n.start&&(i=s.start,r=!0);break}a.push(s),s.end>i&&(i=s.end)}var u=this.video?this.video.duration:NaN;u>0&&i>=u-.5&&(i=Math.max(0,u-.5));for(var l=[],c=[],h=0;h<a.length;h++){var d=a[h];d.start>=i||(c.push(ei(d.category)),(!r||d.end<=i)&&l.push(d.key))}return{to:i,keys:l,names:c}}},{key:"skipAt",value:function(e,t){for(var n=this.active[e],i=this.jumpTarget(e,t),r=0;r<i.keys.length;r++)this.done[i.keys[r]]=!0;i.to<=t+.25||(this.lastSkip={from:n.start,to:i.to,names:i.names},this.landing={to:i.to,retries:0,at:Date.now()},this.settle={from:n.start,to:i.to,until:Date.now()+3e3,retries:0},this.seekTo(i.to),me("enableSponsorBlockToasts")&&st(je("app.name"),je("sponsorblock.toasts.skipping",{segment:ti(i.names)})))}},{key:"seekTo",value:function(e){this.seekIssuedAt=Date.now(),this.video.currentTime=e}},{key:"handleSeeked",value:function(){var e=this.video;if(!this.destroyed&&e){var t=e.currentTime,n=this.landing;if(this.landing=null,n&&Date.now()-n.at<2e3&&t<n.to-1.5&&n.retries<2)return this.landing={to:n.to,retries:n.retries+1,at:Date.now()},void this.seekTo(n.to);if(!n)if(this.suppressRearm)this.suppressRearm=!1;else if(this.settling(t)){var i=this.settle;if(t<i.to-1.5&&i.retries<2)return i.retries+=1,void this.seekTo(i.to)}else this.rearm(t),this.lastSkip=null;this.lastT=t,this.redrawBar(),this.tick()}}},{key:"settling",value:function(e){var t=this.settle;return!(!t||Date.now()>t.until)&&(e>=t.from-10&&e<=t.to)}},{key:"rearm",value:function(e){for(var t=0;t<this.active.length;t++){var n=this.active[t];n.start>e+1&&delete this.done[n.key]}}},{key:"nearNext",value:function(e){for(var t=0;t<this.active.length;t++){var n=this.active[t];if(!("skip"!==n.mode||n.end<=e||this.done[n.key]))return n.start-e<1.5}return!1}},{key:"tryUndoLastSkip",value:function(){var e=this.lastSkip;if(this.destroyed||!this.video||!e)return!1;var t=this.video.currentTime-e.to;return!(t<0||t>10)&&(this.lastSkip=null,this.landing=null,this.settle=null,this.suppressRearm=!0,this.seekTo(e.from),me("enableSponsorBlockToasts")&&st(je("app.name"),je("sponsorblock.toasts.undone",{segment:ti(e.names)})),!0)}},{key:"refreshBar",value:function(){var e=Date.now();e-this.barAt<1e3||(this.barAt=e,this.redrawBar())}},{key:"redrawBar",value:function(){if(!this.destroyed){for(var e=this.video||Ln(),t=e?e.duration:0,n=[],i=0;i<this.drawn.length;i++){var r=this.drawn[i];n.push({start:r.start,end:r.end,color:$n(r.category)})}ii(function(e,t,n){if(!(e&&0!==e.length&&t>0))return"";var i=e.slice().sort(function(e,t){return e.end-e.start-(t.end-t.start)}),r="".concat(Zn," ").concat(Qn,"::after { background: ").concat(ri(i,0,t),"; }");if(n)for(var a=0;a<n.length;a++){var o=String(n[a].key).replace(/["\\]/g,"\\$&");r+=' ytlr-multi-markers-player-bar-renderer [idomkey="'.concat(o,'"]::after { background: ').concat(ri(i,n[a].from,n[a].to),"; }")}return r}(n,t,function(e){var t=document.querySelectorAll('ytlr-multi-markers-player-bar-renderer [idomkey="progress-bar"] > [idomkey^="chapter-"]');if(!(t&&0!==t.length&&e>0))return null;for(var n=0,i=0;i<t.length;i++)n+=parseFloat(t[i].style.width);if(!(n>0))return null;for(var r=[],a=0,o=0;o<t.length;o++){var s=parseFloat(t[o].style.width);r.push({key:t[o].getAttribute("idomkey"),from:a/n*e,to:(a+s)/n*e}),a+=s}return r}(t)))}}},{key:"destroy",value:function(){if(!this.destroyed){this.destroyed=!0;var e=this.request;this.request=null,e&&e.abort(),this.detach(),ii(""),this.done={},this.lastSkip=null,this.landing=null}}}])}();window.sponsorblock=null;var oi=!1;function si(){var e=window.sponsorblock;if(e){window.sponsorblock=null;try{e.destroy()}catch(e){}}}function ui(){var e,t=(e=/[?&]v=([^&]+)/.exec(location.hash))?e[1]:null;if(t&&me("enableSponsorBlock")){if(!window.sponsorblock||window.sponsorblock.videoID!==t){si();var n=new ai(t);window.sponsorblock=n,n.load(),n.attach(Ln())}}else si()}window.addEventListener("keydown",function(e){if(10009===e.keyCode){var t=window.sponsorblock;t&&t.tryUndoLastSkip()&&(oi=!0,e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation())}},!0),window.addEventListener("keyup",function(e){10009===e.keyCode&&oi&&(oi=!1,e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation())},!0),window.addEventListener("hashchange",ui,!1),zn(function(e){var t=window.sponsorblock;t&&t.attach(e)}),ge.addEventListener("configChange",function(e){var t=e.detail&&e.detail.key||"";if(0===t.indexOf("enableSponsorBlock")||"sponsorBlockManualSkips"===t){var n=window.sponsorblock;n&&"enableSponsorBlock"!==t?(n.refresh(),n.tick()):ui()}}),"loading"===document.readyState?document.addEventListener("DOMContentLoaded",ui):ui();var li=["timeupdate","durationchange","ratechange","seeked","play","pause"],ci=null,hi=null,di=null,pi=!1;function fi(e){return e<10?"0".concat(e):String(e)}function mi(e){var t=Math.floor(e/3600),n=Math.floor(e%3600/60),i=e%60;return t>0?"".concat(t,":").concat(fi(n),":").concat(fi(i)):"".concat(n,":").concat(fi(i))}function yi(e,t,n){try{var i=e&&"function"==typeof e[t]?e[t]():n;return void 0===i?n:i}catch(e){return n}}function gi(){var e=!!me("enableRemainingTime");if(e||pi){var t;hi&&hi.parentNode||(t=function(){var e=document.querySelector('[idomkey="time-label"] > [idomkey="elapsedTime"]');return e?e.parentElement:null}(),t!==hi&&(di&&di.disconnect(),di=null,pi=!1,(hi=t)&&(di=new MutationObserver(function(){return gi()})).observe(hi,{characterData:!0,childList:!0,subtree:!0})));var n=function(){var e=hi?hi.querySelector('[idomkey="elapsedTime"]'):null,t=e?e.firstChild:null;return t&&t.nodeType===Node.TEXT_NODE?t:null}();if(n){var i=Rn(),r=e&&!!i&&/#\/watch/.test(location.hash||"")&&!function(e){var t=yi(e,"getVideoData",null);return!(!t||!t.isLive)}(i);if(r){var a=Math.floor(yi(i,"getDuration",0)),o=Math.floor(yi(i,"getCurrentTime",0)),s=yi(i,"getPlaybackRate",1)||1,u=Math.round(Math.max(0,(a-o)/s)),l="-".concat(mi(u));pi=!0,n.data!==l&&(n.data=l)}else{if(pi){var c=Math.floor(yi(i,"getCurrentTime",0));n.data=mi(c)}pi=!1}}}}zn(function(e){return function(e){e!==ci&&(ci&&li.forEach(function(e){return ci.removeEventListener(e,gi)}),(ci=e)&&li.forEach(function(e){return ci.addEventListener(e,gi)}),gi())}(e)}),ge.addEventListener("configChange",function(e){var t;"enableRemainingTime"===(null===(t=e.detail)||void 0===t?void 0:t.key)&&gi()});var vi=["AXO_SETTINGS_SHOW","AXO_SPEED_SETTINGS_SHOW","SETTINGS_OPEN"];function bi(e){return null!==function(e){if(!e||"object"!==b(e))return null;var t=e.openPopupAction;if(t)return"TOAST"===t.popupType?null:"popup";var n=e.showEngagementPanelEndpoint;return n?n.customAction?null:"reading":e.customAction&&-1!==vi.indexOf(e.customAction.action)?"popup":null}(e)}function xi(){var e=Rn();if(e&&"function"==typeof e.pauseVideo)try{return void e.pauseVideo()}catch(e){}var t=Ln();t&&!t.paused&&t.pause()}window.addEventListener("visibilitychange",function(e){me("enablePauseOnBlur")&&document.hidden&&(e.stopImmediatePropagation(),xi())},!0);var Ei=["ytlr-player-page","ytlr-player-actions-container","ytlr-progress-bar"],Si=[10,30,60],wi={},Di={},Ai={},ki=0,Ci=0,Ti=-1/0,Fi=null;function Pi(e){for(var t=e;t&&t!==document;t=t.parentNode){if(t.getAttribute&&"true"===t.getAttribute("aria-hidden"))return!0;if(t.classList&&t.classList.contains("zylon-hidden"))return!0;var n=window.getComputedStyle(t);if("none"===n.display||"hidden"===n.visibility)return!0}return!1}function Bi(e,t){var n=Rn();try{if(n&&"function"==typeof n.setPlaybackRate)return void n.setPlaybackRate(t)}catch(e){}e.playbackRate=t}function Ii(e,t){var n=e.duration;return n>0?Math.max(0,Math.min(n,t)):null}function Ni(e){e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation()}function Mi(e,t){var n=Di[e];if(n)if(n.timer=null,39===e){if(t.paused)return;n.rateBefore=t.playbackRate||1,Bi(t,2)}else 37===e&&(n.ticker=setInterval(function(){var e=Ln();e&&(Fi=null,function(e,t){var n=Ii(e,t);null!==n&&(e.currentTime=n)}(e,e.currentTime-10))},300))}window.addEventListener("keydown",function(e){var t=e.keyCode;if((13===t||37===t||39===t)&&me("enableOnePressMode")&&function(){if(!/[?&]v=[^&]+/.test(window.location.hash||""))return!1;var e=document.querySelector("ytlr-shorts-page");return!(e&&e.classList&&e.classList.contains("zylon-focus"))}()&&!(function(e){var t=e&&e.closest?e.closest("ytlr-tile-renderer"):null;return!!t&&!Pi(t)}(e.target)||function(){for(var e=document.querySelectorAll(".zylon-focus"),t=0;t<e.length;t++){var n=e[t];if(!(Pi(n)||n.closest&&n.closest("ytlr-player-page, ytlr-player-actions-container, ytlr-progress-bar")))return!0}return!1}()||function(){for(var e=0;e<Ei.length;e++){var t=document.querySelector(Ei[e]);if(t&&!Pi(t)){var n=window.getComputedStyle(t);if("hidden"!==n.visibility&&parseFloat(n.opacity)>0&&t.getClientRects().length>0)return!0}}return!1}())){var n=Ln();if(n)if(Di[t])Ni(e);else{var i=Date.now();if(void 0!==Ai[t]&&i-Ai[t]<100)Ni(e);else{if(Ai[t]=i,13===t)!function(e){var t=Rn(),n=!e.paused;try{var i=t&&t.getPlayerStateObject&&t.getPlayerStateObject();i&&"boolean"==typeof i.isPlaying&&(n=i.isPlaying)}catch(e){}try{if(t&&"function"==typeof(n?t.pauseVideo:t.playVideo))return void(n?t.pauseVideo():t.playVideo())}catch(e){}n?e.pause():e.play()}(n),Di[t]={timer:null};else{var r=37===t?-1:1,a=function(e,t){var n=e===ki&&t-Ti<=1e3;return Ci=n?Ci+1:0,ki=e,n||(Fi=null),Si[Math.min(Ci,Si.length-1)]}(r,i)*r,o=Ii(n,(Ci>0&&null!==Fi?Fi:n.currentTime)+a);null!==o&&(Fi=o,n.currentTime=o),Di[t]={timer:setTimeout(function(){return Mi(t,Ln())},1e3)}}wi[t]=!0,Ni(e)}}}},!0),window.addEventListener("keyup",function(e){var t=e.keyCode;if(wi[t]){delete wi[t],Ni(e);var n=Di[t];if(delete Di[t],n){if(n.timer&&clearTimeout(n.timer),n.ticker&&clearInterval(n.ticker),void 0!==n.rateBefore){var i=Ln();i&&Bi(i,n.rateBefore)}13!==t&&(Ti=Date.now())}}},!0);var Ri=0;function Li(e,t,n){var i=e.filter(function(e){return e&&(n=e.languageCode,String(n||"").toLowerCase().split("-")[0]===t);var n}),r=i.find(function(e){return"asr"!==e.kind});return r||(n&&i.find(function(e){return"asr"===e.kind})||null)}function Oi(){var e=++Ri,t=0,n=function(){if(e===Ri&&me("enableAutoSubtitles")){var i=function(e,t,n){if(!e||"function"!=typeof e.getOptions||"function"!=typeof e.getOption)return"retry";if(-1===(e.getOptions()||[]).indexOf("captions"))return"retry";if("function"==typeof e.loadModule)try{e.loadModule("captions")}catch(e){}var i=e.getOption("captions","track");if(i&&i.languageCode)return"done";var r=e.getOption("captions","tracklist")||[];if(!r.length)return"retry";var a=Li(r,t,n);return a&&"function"==typeof e.setOption&&e.setOption("captions","track",a),"done"}(Rn(),me("autoSubtitleLanguage")||"en",!!me("autoSubtitleAllowAuto"));t+=1,"retry"===i&&t<8&&setTimeout(n,1e3)}};n()}Gn(function(e){e&&Oi()});var _i='/* Fixes transparency effect for the video player */\n\n.ytLrWatchDefaultShadow,\ndiv[idomkey="shadow"] {\n background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0) 0, rgba(0, 0, 0, 0.8) 90%) !important;\n background-color: rgba(0, 0, 0, 0.3) !important;\n display: block !important;\n height: 100% !important;\n pointer-events: none !important;\n position: absolute !important;\n width: 100% !important;\n}\n\n/* https://github.com/webosbrew/youtube-webos/commit/4fbe38a18df31ddd62b6cf15f141dd58e1d1a71d */\n.ytLrWatchDefault2025Shadow {\n background-color: rgba(11, 11, 11, 0.5) !important;\n}\n\n/* Fixes shorts having a black background */\n\n.ytLrTileHeaderRendererShorts {\n background-image: none !important;\n}\n\n/* Multiline support for strings in the UI */\n\n.ytLrOverlayPanelHeaderRendererSubtitle {\n white-space: pre-wrap !important;\n}\n\n/* Fixes SponsorBlock segments overlapping with the playhead */\n\n.ytLrProgressBarPlayhead {\n z-index: 1 !important;\n}\n\n.ytLrProgressBarPlayed {\n z-index: 1 !important;\n}\n\n.ytLrSearchBarSearchVoice {\n display: block;\n position: absolute;\n left: 0;\n top: 0;\n pointer-events: auto\n}\n\n.ytLrSearchVoiceHost {\n font-size: 3rem;\n}\n\n.ytLrSearchVoiceMicButtonHost {\n color: rgba(255, 255, 255, 0.7);\n}\n\n.ytLrSearchVoiceMicButtonHost {\n background-color: rgba(255, 255, 255, 0.1);\n border-radius: 50%;\n color: #f1f1f1;\n display: block;\n text-align: center;\n width: 1em;\n height: 1em;\n}\n\n.ytLrSearchVoiceMicButtonIcon {\n display: inline-block;\n font-size: .5em;\n height: .5em;\n width: .5em;\n height: 1em;\n width: 1em;\n margin-top: .5em;\n vertical-align: top !important;\n}\n\n.ytContribIconHost {\n display: inline-block;\n vertical-align: middle;\n}\n\n.ytContribIconTvArrowLeft::before {\n content: "\\e822";\n}\n\n.ytContribIconHost::before {\n font-family: "YouTube Icons Outlined";\n}\n\n/* Make toasts match the YouTube TV look and font */\n\nytlr-toast,\npaper-toast {\n font-family: "YouTube Sans", Roboto, "Noto Sans", Arial, sans-serif !important;\n font-size: 1.4rem !important;\n line-height: 1.4 !important;\n border-radius: 4px !important;\n background-color: rgba(0, 0, 0, 0.85) !important;\n color: rgba(255, 255, 255, 0.95) !important;\n}\n\nytlr-toast .title,\nytlr-toast .subtitle,\nytlr-toast #text,\nytlr-toast iron-p {\n font-family: "YouTube Sans", Roboto, "Noto Sans", Arial, sans-serif !important;\n}\n\nytlr-toast .subtitle,\nytlr-toast iron-p {\n color: rgba(255, 255, 255, 0.75) !important;\n}\n\nytlr-toast img,\nytlr-toast iron-image,\nytlr-toast .thumbnail {\n border-radius: 4px !important;\n}\n\n/* Hide promo shelves (also stripped at the response level in adblock.js) */\n\nytlr-promo-shelf-renderer {\n display: none !important;\n}\n\n/* Reduced motion mode: disable all animations/transitions for performance */\n\nbody.axotube-reduced-motion,\nbody.axotube-reduced-motion *,\nbody.axotube-reduced-motion *::before,\nbody.axotube-reduced-motion *::after {\n animation: none !important;\n animation-delay: 0s !important;\n animation-duration: 0s !important;\n transition: none !important;\n transition-delay: 0s !important;\n transition-duration: 0s !important;\n scroll-behavior: auto !important;\n will-change: auto !important;\n backdrop-filter: none !important;\n}\n\nbody.axotube-reduced-motion ytlr-swipeable-overlay,\nbody.axotube-reduced-motion .ytLrWatchDefaultShadow,\nbody.axotube-reduced-motion div[idomkey="shadow"] {\n opacity: 1 !important;\n}\n\nbody.axotube-reduced-motion ytlr-player,\nbody.axotube-reduced-motion .html5-video-player {\n will-change: auto !important;\n}\n',Ui="/* ytaf-theme-start */",ji="/* ytaf-theme-end */",Hi=document.createElement("style"),zi="",Gi={default:null,white:["#ffffff","#e0e0e0","#c0c0c0"],gray:["#d0d0d0","#9a9a9a","#7f7f7f"],red:["#ff7a7a","#e06a6a","#c25b5b"],blue:["#8ab4ff","#6f96e8","#5a79c9"],green:["#81c995","#68a87a","#538c64"],purple:["#d7aefb","#b28fd8","#8f70b5"],yellow:["#fdd663","#d9b34d","#b5913c"]};function Ki(e){var t=/rgba?\(\s*(\d+),\s*(\d+),\s*(\d+)/.exec(e);return t?(.2126*Number(t[1])+.7152*Number(t[2])+.0722*Number(t[3]))/255:null}function Xi(e){var t=String(e.className||"").split(/\s+/).filter(function(e){return e&&/^[A-Za-z0-9_-]+$/.test(e)});return t.length&&e.tagName?e.tagName.toLowerCase()+t.map(function(e){return"."+e}).join(""):""}function Vi(){var e,t=function(e){var t=String(e||"").trim();if(!t)return"";try{var n=new URL(t);return"http:"!==n.protocol&&"https:"!==n.protocol?"":t.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/[\r\n]/g,"")}catch(e){return""}}(me("routeBackgroundUrl")),n=t?'\n background-image: url("'.concat(t,'") !important;\n background-size: cover !important;\n background-position: center !important;\n background-repeat: no-repeat !important;'):"\n background-color: ".concat((e=me("routeColor"),/^#[0-9a-f]{6}$/i.test(String(e||""))?e:"#0f0f0f")," !important;"),i=t?"\n ytlr-guide-response {\n background-image: none !important;\n background-color: rgba(15, 15, 15, 0.35) !important;\n }\n ytlr-guide-response > div {\n background-image: none !important;\n background-color: transparent !important;\n }\n ytlr-guide-response .zylon-ve {\n background-image: none !important;\n background-color: transparent !important;\n }":"",r=function(e){var t=Gi[e],n=document.getElementById("container");if(!t||!n)return"";for(var i=[[],[],[]],r={},a=n.querySelectorAll("*"),o=0;o<a.length;o++){var s=Ki(getComputedStyle(a[o]).color);if(!(null===s||s<.3)){var u=s>.8?0:s>.55?1:2,l=Xi(a[o]);l&&!r[l]&&(r[l]=!0,i[u].push(l))}}for(var c="",h=0;h<3;h++)i[h].length&&(c+=i[h].join(",\n")+" {\n color: "+t[h]+" !important;\n }\n");return c}(me("textTheme"));zi="\n ".concat(Ui,"\n #container {\n ").concat(n,"\n }\n ").concat(i,"\n ").concat(r,"\n ").concat(ji,"\n");var a=document.querySelector("style[nonce]");if(a){var o=a.textContent||"",s=o.indexOf(Ui),u=o.indexOf(ji);-1!==s&&-1!==u&&(o=o.slice(0,s)+o.slice(u+20)),a.textContent=o+zi}else Hi.textContent=zi,!Hi.parentNode&&document.head&&document.head.appendChild(Hi)}document.head&&document.head.appendChild(Hi),Vi(),setTimeout(Vi,1500);var Wi=null;window.addEventListener&&window.addEventListener("hashchange",function(){Wi&&clearTimeout(Wi),Wi=setTimeout(Vi,150)});var Ji="1.48.0";function qi(e,t,n){if("arrayValue"===t){var i=me(e),r=Array.isArray(i)?i.slice():[];return r.includes(n)?r.splice(r.indexOf(n),1):r.push(n),ye(e,r)}if("themePreset"===e){var a="string"==typeof n&&Object.prototype.hasOwnProperty.call(re.themePresetColors,n)?re.themePresetColors[n]:null;return!("string"!=typeof a||!/^#[0-9a-f]{6}$/i.test(a))&&(ye("routeColor",a),ye("themePreset",n))}return ye(e,n)}var Yi,Qi={};var Zi=(Yi||(Yi=1,Qi.qrcode=function(){var e=function(e,t){var n=e,i=c[t],r=null,a=0,o=null,s=new Array,u={},l=function(e,t){r=function(e){for(var t=new Array(e),n=0;n<e;n+=1){t[n]=new Array(e);for(var i=0;i<e;i+=1)t[n][i]=null}return t}(a=4*n+17),h(0,0),h(a-7,0),h(0,a-7),p(),d(),m(e,t),n>=7&&f(e),null==o&&(o=g(n,i,s)),y(o,t)},h=function(e,t){for(var n=-1;n<=7;n+=1)if(!(e+n<=-1||a<=e+n))for(var i=-1;i<=7;i+=1)t+i<=-1||a<=t+i||(r[e+n][t+i]=0<=n&&n<=6&&(0==i||6==i)||0<=i&&i<=6&&(0==n||6==n)||2<=n&&n<=4&&2<=i&&i<=4)},d=function(){for(var e=8;e<a-8;e+=1)null==r[e][6]&&(r[e][6]=e%2==0);for(var t=8;t<a-8;t+=1)null==r[6][t]&&(r[6][t]=t%2==0)},p=function(){for(var e=b.getPatternPosition(n),t=0;t<e.length;t+=1)for(var i=0;i<e.length;i+=1){var a=e[t],o=e[i];if(null==r[a][o])for(var s=-2;s<=2;s+=1)for(var u=-2;u<=2;u+=1)r[a+s][o+u]=-2==s||2==s||-2==u||2==u||0==s&&0==u}},f=function(e){for(var t=b.getBCHTypeNumber(n),i=0;i<18;i+=1){var o=!e&&1==(t>>i&1);r[Math.floor(i/3)][i%3+a-8-3]=o}for(i=0;i<18;i+=1)o=!e&&1==(t>>i&1),r[i%3+a-8-3][Math.floor(i/3)]=o},m=function(e,t){for(var n=i<<3|t,o=b.getBCHTypeInfo(n),s=0;s<15;s+=1){var u=!e&&1==(o>>s&1);s<6?r[s][8]=u:s<8?r[s+1][8]=u:r[a-15+s][8]=u}for(s=0;s<15;s+=1)u=!e&&1==(o>>s&1),s<8?r[8][a-s-1]=u:s<9?r[8][15-s-1+1]=u:r[8][15-s-1]=u;r[a-8][8]=!e},y=function(e,t){for(var n=-1,i=a-1,o=7,s=0,u=b.getMaskFunction(t),l=a-1;l>0;l-=2)for(6==l&&(l-=1);;){for(var c=0;c<2;c+=1)if(null==r[i][l-c]){var h=!1;s<e.length&&(h=1==(e[s]>>>o&1)),u(i,l-c)&&(h=!h),r[i][l-c]=h,-1==(o-=1)&&(s+=1,o=7)}if((i+=n)<0||a<=i){i-=n,n=-n;break}}},g=function(e,t,n){for(var i=S.getRSBlocks(e,t),r=w(),a=0;a<n.length;a+=1){var o=n[a];r.put(o.getMode(),4),r.put(o.getLength(),b.getLengthInBits(o.getMode(),e)),o.write(r)}var s=0;for(a=0;a<i.length;a+=1)s+=i[a].dataCount;if(r.getLengthInBits()>8*s)throw new Error("code length overflow. ("+r.getLengthInBits()+">"+8*s+")");for(r.getLengthInBits()+4<=8*s&&r.put(0,4);r.getLengthInBits()%8!=0;)r.putBit(!1);for(;!(r.getLengthInBits()>=8*s||(r.put(236,8),r.getLengthInBits()>=8*s));)r.put(17,8);return function(e,t){for(var n=0,i=0,r=0,a=new Array(t.length),o=new Array(t.length),s=0;s<t.length;s+=1){var u=t[s].dataCount,l=t[s].totalCount-u;i=Math.max(i,u),r=Math.max(r,l),a[s]=new Array(u);for(var c=0;c<a[s].length;c+=1)a[s][c]=255&e.getBuffer()[c+n];n+=u;var h=b.getErrorCorrectPolynomial(l),d=E(a[s],h.getLength()-1).mod(h);for(o[s]=new Array(h.getLength()-1),c=0;c<o[s].length;c+=1){var p=c+d.getLength()-o[s].length;o[s][c]=p>=0?d.get(p):0}}var f=0;for(c=0;c<t.length;c+=1)f+=t[c].totalCount;var m=new Array(f),y=0;for(c=0;c<i;c+=1)for(s=0;s<t.length;s+=1)c<a[s].length&&(m[y]=a[s][c],y+=1);for(c=0;c<r;c+=1)for(s=0;s<t.length;s+=1)c<o[s].length&&(m[y]=o[s][c],y+=1);return m}(r,i)};return u.addData=function(e){var t=D(e);s.push(t),o=null},u.isDark=function(e,t){if(e<0||a<=e||t<0||a<=t)throw new Error(e+","+t);return r[e][t]},u.getModuleCount=function(){return a},u.make=function(){l(!1,function(){for(var e=0,t=0,n=0;n<8;n+=1){l(!0,n);var i=b.getLostPoint(u);(0==n||e>i)&&(e=i,t=n)}return t}())},u.createTableTag=function(e,t){e=e||2;var n="";n+='<table style="',n+=" border-width: 0px; border-style: none;",n+=" border-collapse: collapse;",n+=" padding: 0px; margin: "+(t=void 0===t?4*e:t)+"px;",n+='">',n+="<tbody>";for(var i=0;i<u.getModuleCount();i+=1){n+="<tr>";for(var r=0;r<u.getModuleCount();r+=1)n+='<td style="',n+=" border-width: 0px; border-style: none;",n+=" border-collapse: collapse;",n+=" padding: 0px; margin: 0px;",n+=" width: "+e+"px;",n+=" height: "+e+"px;",n+=" background-color: ",n+=u.isDark(i,r)?"#000000":"#ffffff",n+=";",n+='"/>';n+="</tr>"}return n+="</tbody>",n+="</table>"},u.createImgTag=function(e,t){e=e||2,t=void 0===t?4*e:t;var n=u.getModuleCount()*e+2*t,i=t,r=n-t;return T(n,n,function(t,n){if(i<=t&&t<r&&i<=n&&n<r){var a=Math.floor((t-i)/e),o=Math.floor((n-i)/e);return u.isDark(o,a)?0:1}return 1})},u};e.stringToBytes=function(e){for(var t=new Array,n=0;n<e.length;n+=1){var i=e.charCodeAt(n);t.push(255&i)}return t},e.createStringToBytes=function(e,t){var n=function(){for(var n=k(e),i=function(){var e=n.read();if(-1==e)throw new Error;return e},r=0,a={};;){var o=n.read();if(-1==o)break;var s=i(),u=i()<<8|i();a[String.fromCharCode(o<<8|s)]=u,r+=1}if(r!=t)throw new Error(r+" != "+t);return a}(),i="?".charCodeAt(0);return function(e){for(var t=new Array,r=0;r<e.length;r+=1){var a=e.charCodeAt(r);if(a<128)t.push(a);else{var o=n[e.charAt(r)];"number"==typeof o?(255&o)==o?t.push(o):(t.push(o>>>8),t.push(255&o)):t.push(i)}}return t}};var t,n,i,r,a,o=1,s=2,u=4,l=8,c={L:1,M:0,Q:3,H:2},h=0,d=1,p=2,f=3,m=4,y=5,g=6,v=7,b=(t=[[],[6,18],[6,22],[6,26],[6,30],[6,34],[6,22,38],[6,24,42],[6,26,46],[6,28,50],[6,30,54],[6,32,58],[6,34,62],[6,26,46,66],[6,26,48,70],[6,26,50,74],[6,30,54,78],[6,30,56,82],[6,30,58,86],[6,34,62,90],[6,28,50,72,94],[6,26,50,74,98],[6,30,54,78,102],[6,28,54,80,106],[6,32,58,84,110],[6,30,58,86,114],[6,34,62,90,118],[6,26,50,74,98,122],[6,30,54,78,102,126],[6,26,52,78,104,130],[6,30,56,82,108,134],[6,34,60,86,112,138],[6,30,58,86,114,142],[6,34,62,90,118,146],[6,30,54,78,102,126,150],[6,24,50,76,102,128,154],[6,28,54,80,106,132,158],[6,32,58,84,110,136,162],[6,26,54,82,110,138,166],[6,30,58,86,114,142,170]],n=1335,i=7973,a=function(e){for(var t=0;0!=e;)t+=1,e>>>=1;return t},(r={}).getBCHTypeInfo=function(e){for(var t=e<<10;a(t)-a(n)>=0;)t^=n<<a(t)-a(n);return 21522^(e<<10|t)},r.getBCHTypeNumber=function(e){for(var t=e<<12;a(t)-a(i)>=0;)t^=i<<a(t)-a(i);return e<<12|t},r.getPatternPosition=function(e){return t[e-1]},r.getMaskFunction=function(e){switch(e){case h:return function(e,t){return(e+t)%2==0};case d:return function(e,t){return e%2==0};case p:return function(e,t){return t%3==0};case f:return function(e,t){return(e+t)%3==0};case m:return function(e,t){return(Math.floor(e/2)+Math.floor(t/3))%2==0};case y:return function(e,t){return e*t%2+e*t%3==0};case g:return function(e,t){return(e*t%2+e*t%3)%2==0};case v:return function(e,t){return(e*t%3+(e+t)%2)%2==0};default:throw new Error("bad maskPattern:"+e)}},r.getErrorCorrectPolynomial=function(e){for(var t=E([1],0),n=0;n<e;n+=1)t=t.multiply(E([1,x.gexp(n)],0));return t},r.getLengthInBits=function(e,t){if(1<=t&&t<10)switch(e){case o:return 10;case s:return 9;case u:case l:return 8;default:throw new Error("mode:"+e)}else if(t<27)switch(e){case o:return 12;case s:return 11;case u:return 16;case l:return 10;default:throw new Error("mode:"+e)}else{if(!(t<41))throw new Error("type:"+t);switch(e){case o:return 14;case s:return 13;case u:return 16;case l:return 12;default:throw new Error("mode:"+e)}}},r.getLostPoint=function(e){for(var t=e.getModuleCount(),n=0,i=0;i<t;i+=1)for(var r=0;r<t;r+=1){for(var a=0,o=e.isDark(i,r),s=-1;s<=1;s+=1)if(!(i+s<0||t<=i+s))for(var u=-1;u<=1;u+=1)r+u<0||t<=r+u||0==s&&0==u||o==e.isDark(i+s,r+u)&&(a+=1);a>5&&(n+=3+a-5)}for(i=0;i<t-1;i+=1)for(r=0;r<t-1;r+=1){var l=0;e.isDark(i,r)&&(l+=1),e.isDark(i+1,r)&&(l+=1),e.isDark(i,r+1)&&(l+=1),e.isDark(i+1,r+1)&&(l+=1),0!=l&&4!=l||(n+=3)}for(i=0;i<t;i+=1)for(r=0;r<t-6;r+=1)e.isDark(i,r)&&!e.isDark(i,r+1)&&e.isDark(i,r+2)&&e.isDark(i,r+3)&&e.isDark(i,r+4)&&!e.isDark(i,r+5)&&e.isDark(i,r+6)&&(n+=40);for(r=0;r<t;r+=1)for(i=0;i<t-6;i+=1)e.isDark(i,r)&&!e.isDark(i+1,r)&&e.isDark(i+2,r)&&e.isDark(i+3,r)&&e.isDark(i+4,r)&&!e.isDark(i+5,r)&&e.isDark(i+6,r)&&(n+=40);var c=0;for(r=0;r<t;r+=1)for(i=0;i<t;i+=1)e.isDark(i,r)&&(c+=1);return n+=Math.abs(100*c/t/t-50)/5*10},r),x=function(){for(var e=new Array(256),t=new Array(256),n=0;n<8;n+=1)e[n]=1<<n;for(n=8;n<256;n+=1)e[n]=e[n-4]^e[n-5]^e[n-6]^e[n-8];for(n=0;n<255;n+=1)t[e[n]]=n;var i={glog:function(e){if(e<1)throw new Error("glog("+e+")");return t[e]},gexp:function(t){for(;t<0;)t+=255;for(;t>=256;)t-=255;return e[t]}};return i}();function E(e,t){if(void 0===e.length)throw new Error(e.length+"/"+t);var n=function(){for(var n=0;n<e.length&&0==e[n];)n+=1;for(var i=new Array(e.length-n+t),r=0;r<e.length-n;r+=1)i[r]=e[r+n];return i}(),i={get:function(e){return n[e]},getLength:function(){return n.length},multiply:function(e){for(var t=new Array(i.getLength()+e.getLength()-1),n=0;n<i.getLength();n+=1)for(var r=0;r<e.getLength();r+=1)t[n+r]^=x.gexp(x.glog(i.get(n))+x.glog(e.get(r)));return E(t,0)},mod:function(e){if(i.getLength()-e.getLength()<0)return i;for(var t=x.glog(i.get(0))-x.glog(e.get(0)),n=new Array(i.getLength()),r=0;r<i.getLength();r+=1)n[r]=i.get(r);for(r=0;r<e.getLength();r+=1)n[r]^=x.gexp(x.glog(e.get(r))+t);return E(n,0).mod(e)}};return i}var S=function(){var e=[[1,26,19],[1,26,16],[1,26,13],[1,26,9],[1,44,34],[1,44,28],[1,44,22],[1,44,16],[1,70,55],[1,70,44],[2,35,17],[2,35,13],[1,100,80],[2,50,32],[2,50,24],[4,25,9],[1,134,108],[2,67,43],[2,33,15,2,34,16],[2,33,11,2,34,12],[2,86,68],[4,43,27],[4,43,19],[4,43,15],[2,98,78],[4,49,31],[2,32,14,4,33,15],[4,39,13,1,40,14],[2,121,97],[2,60,38,2,61,39],[4,40,18,2,41,19],[4,40,14,2,41,15],[2,146,116],[3,58,36,2,59,37],[4,36,16,4,37,17],[4,36,12,4,37,13],[2,86,68,2,87,69],[4,69,43,1,70,44],[6,43,19,2,44,20],[6,43,15,2,44,16]],t=function(e,t){var n={};return n.totalCount=e,n.dataCount=t,n},n={getRSBlocks:function(n,i){var r=function(t,n){switch(n){case c.L:return e[4*(t-1)+0];case c.M:return e[4*(t-1)+1];case c.Q:return e[4*(t-1)+2];case c.H:return e[4*(t-1)+3];default:return}}(n,i);if(void 0===r)throw new Error("bad rs block @ typeNumber:"+n+"/errorCorrectLevel:"+i);for(var a=r.length/3,o=new Array,s=0;s<a;s+=1)for(var u=r[3*s+0],l=r[3*s+1],h=r[3*s+2],d=0;d<u;d+=1)o.push(t(l,h));return o}};return n}(),w=function(){var e=new Array,t=0,n={getBuffer:function(){return e},get:function(t){var n=Math.floor(t/8);return 1==(e[n]>>>7-t%8&1)},put:function(e,t){for(var i=0;i<t;i+=1)n.putBit(1==(e>>>t-i-1&1))},getLengthInBits:function(){return t},putBit:function(n){var i=Math.floor(t/8);e.length<=i&&e.push(0),n&&(e[i]|=128>>>t%8),t+=1}};return n},D=function(t){var n=u,i=e.stringToBytes(t),r={getMode:function(){return n},getLength:function(e){return i.length},write:function(e){for(var t=0;t<i.length;t+=1)e.put(i[t],8)}};return r},A=function(){var e=new Array,t={writeByte:function(t){e.push(255&t)},writeShort:function(e){t.writeByte(e),t.writeByte(e>>>8)},writeBytes:function(e,n,i){n=n||0,i=i||e.length;for(var r=0;r<i;r+=1)t.writeByte(e[r+n])},writeString:function(e){for(var n=0;n<e.length;n+=1)t.writeByte(e.charCodeAt(n))},toByteArray:function(){return e},toString:function(){var t="";t+="[";for(var n=0;n<e.length;n+=1)n>0&&(t+=","),t+=e[n];return t+="]"}};return t},k=function(e){var t=e,n=0,i=0,r=0,a={read:function(){for(;r<8;){if(n>=t.length){if(0==r)return-1;throw new Error("unexpected end of file./"+r)}var e=t.charAt(n);if(n+=1,"="==e)return r=0,-1;e.match(/^\s$/)||(i=i<<6|o(e.charCodeAt(0)),r+=6)}var a=i>>>r-8&255;return r-=8,a}},o=function(e){if(65<=e&&e<=90)return e-65;if(97<=e&&e<=122)return e-97+26;if(48<=e&&e<=57)return e-48+52;if(43==e)return 62;if(47==e)return 63;throw new Error("c:"+e)};return a},C=function(e,t){var n=e,i=t,r=new Array(e*t),a={setPixel:function(e,t,i){r[t*n+e]=i},write:function(e){e.writeString("GIF87a"),e.writeShort(n),e.writeShort(i),e.writeByte(128),e.writeByte(0),e.writeByte(0),e.writeByte(0),e.writeByte(0),e.writeByte(0),e.writeByte(255),e.writeByte(255),e.writeByte(255),e.writeString(","),e.writeShort(0),e.writeShort(0),e.writeShort(n),e.writeShort(i),e.writeByte(0);var t=o(2);e.writeByte(2);for(var r=0;t.length-r>255;)e.writeByte(255),e.writeBytes(t,r,255),r+=255;e.writeByte(t.length-r),e.writeBytes(t,r,t.length-r),e.writeByte(0),e.writeString(";")}},o=function(e){for(var t=1<<e,n=1+(1<<e),i=e+1,a=s(),o=0;o<t;o+=1)a.add(String.fromCharCode(o));a.add(String.fromCharCode(t)),a.add(String.fromCharCode(n));var u=A(),l=function(e){var t=e,n=0,i=0,r={write:function(e,r){if(e>>>r!=0)throw new Error("length over");for(;n+r>=8;)t.writeByte(255&(e<<n|i)),r-=8-n,e>>>=8-n,i=0,n=0;i|=e<<n,n+=r},flush:function(){n>0&&t.writeByte(i)}};return r}(u);l.write(t,i);var c=0,h=String.fromCharCode(r[c]);for(c+=1;c<r.length;){var d=String.fromCharCode(r[c]);c+=1,a.contains(h+d)?h+=d:(l.write(a.indexOf(h),i),a.size()<4095&&(a.size()==1<<i&&(i+=1),a.add(h+d)),h=d)}return l.write(a.indexOf(h),i),l.write(n,i),l.flush(),u.toByteArray()},s=function(){var e={},t=0,n={add:function(i){if(n.contains(i))throw new Error("dup key:"+i);e[i]=t,t+=1},size:function(){return t},indexOf:function(t){return e[t]},contains:function(t){return void 0!==e[t]}};return n};return a},T=function(e,t,n,i){for(var r=C(e,t),a=0;a<t;a+=1)for(var o=0;o<e;o+=1)r.setPixel(o,a,n(o,a));var s=A();r.write(s);for(var u=function(){var e=0,t=0,n=0,i="",r={},a=function(e){i+=String.fromCharCode(o(63&e))},o=function(e){if(e<0);else{if(e<26)return 65+e;if(e<52)return e-26+97;if(e<62)return e-52+48;if(62==e)return 43;if(63==e)return 47}throw new Error("n:"+e)};return r.writeByte=function(i){for(e=e<<8|255&i,t+=8,n+=1;t>=6;)a(e>>>t-6),t-=6},r.flush=function(){if(t>0&&(a(e<<6-t),e=0,t=0),n%3!=0)for(var r=3-n%3,o=0;o<r;o+=1)i+="="},r.toString=function(){return i},r}(),l=s.toByteArray(),c=0;c<l.length;c+=1)u.writeByte(l[c]);u.flush();var h="";return h+="<img",h+=' src="',h+="data:image/gif;base64,",h+=u,h+='"',h+=' width="',h+=e,h+='"',h+=' height="',h+=t,h+='"',i&&(h+=' alt="',h+=i,h+='"'),h+="/>"};return e}()),Qi),$i=e(Zi),er=Ot(50);function tr(e){if(er.has(e))return er.get(e);try{var t,n=$i.qrcode(6,"H");n.addData(e),n.make();var i=null===(t=n.createImgTag(8,8).match(/src="([^"]+)"/))||void 0===t?void 0:t[1];if(i)return er.set(e,i),i}catch(e){console.error("[AxoTube:qrCode] QR code generation failed:",e)}return null}var nr=/^\d{6}$/,ir=/^https?:\/\/[^\s/?#]+$/,rr=null,ar=0;function or(e){if(ar=Date.now(),e&&"string"==typeof e.code&&nr.test(e.code)){var t=Array.isArray(e.urls)?e.urls.filter(function(e){return"string"==typeof e&&ir.test(e)}).slice(0,4):[];rr={code:e.code,urls:t}}else rr=null}function sr(){return rr}var ur="http://127.0.0.1:8090",lr={checked:!1,service:null,proxy:null};function cr(e,t){return Jt(e,t).then(function(e){return e&&e.ok?e.json():null}).catch(function(){return null})}function hr(e){Promise.all([cr("".concat(ur,"/api/diagnostics")),cr("".concat("http://127.0.0.1:8081","/axotube/health")),cr("".concat(ur,"/api/pairing-code"))]).then(function(t){var n,i=(n=t[0])&&n.service?{version:n.service.version,launchDebugger:!(!n.launch||!n.launch.debugger),bundle:n.bundle||null}:null,r=t[1]&&t[1].ok?{version:t[1].version}:null;lr={checked:!0,service:i,proxy:r},or(i?t[2]:null),e&&e()})}function dr(){return lr}var pr=[{type:"sponsor",key:"enableSponsorBlockSponsor",icon:"MONEY_HEART"},{type:"intro",key:"enableSponsorBlockIntro",icon:"PLAY_CIRCLE"},{type:"outro",key:"enableSponsorBlockOutro",icon:"PAUSE"},{type:"interaction",key:"enableSponsorBlockInteraction",icon:"SUBSCRIBE"},{type:"selfpromo",key:"enableSponsorBlockSelfPromo",icon:"BROADCAST"},{type:"preview",key:"enableSponsorBlockPreview",icon:"PLAY_ARROW_CIRCLE"},{type:"filler",key:"enableSponsorBlockFiller",icon:"TIMER"},{type:"music_offtopic",key:"enableSponsorBlockMusicOfftopic",icon:"MUSIC"}],fr={skip:"show",show:"off",off:"skip"},mr=["default","black","darkGray","charcoal","navy","darkRed","darkGreen","darkPurple"],yr=["default","white","gray","red","blue","green","purple","yellow"],gr=["auto","2160p","1440p","1080p","720p","480p","360p","240p","144p"],vr=["any","vp9","av01","avc1"],br=["en","hi","es","fr","de","pt","ja","ko","ru"],xr=["1440p","2160p"],Er=[.05,.1,.15,.2,.25,.3,.35,.4,.45,.5],Sr=[0,.5,1,1.5,2,2.5,3,3.5,4,4.5,5],wr=[0,10,20,30,40,50,60,70,80,90,100],Dr=[10,20,30,60,120,180,240,300],Ar=[.1,.2,.3,.4,.5,.6,.7,.8,.9,1],kr=[{name:"Search",icon:"SEARCH"},{name:"Home",icon:"WHAT_TO_WATCH"},{name:"Sports",icon:"TROPHY"},{name:"News",icon:"NEWS"},{name:"Music",icon:"YOUTUBE_MUSIC"},{name:"Podcasts",icon:"BROADCAST"},{name:"Movies & TV",icon:"CLAPPERBOARD"},{name:"Live",icon:"LIVE"},{name:"Gaming",icon:"GAMING"},{name:"Subscriptions",icon:"SUBSCRIPTIONS"},{name:"Library",icon:"TAB_LIBRARY"},{name:"More",icon:"TAB_MORE"}];function Cr(e){return JSON.stringify({browseEndpoint:{browseId:e}})}var Tr=[{name:"Search",icon:"SEARCH",value:JSON.stringify({searchEndpoint:{query:""}})},{name:"Home",icon:"WHAT_TO_WATCH",value:Cr("FEtopics")},{name:"Sports",icon:"TROPHY",value:Cr("FEtopics_sports")},{name:"News",icon:"NEWS",value:Cr("FEtopics_news")},{name:"Music",icon:"YOUTUBE_MUSIC",value:Cr("FEtopics_music")},{name:"Podcasts",icon:"BROADCAST",value:Cr("FEtopics_podcasts")},{name:"Movies & TV",icon:"CLAPPERBOARD",value:Cr("FEtopics_movies")},{name:"Gaming",icon:"GAMING",value:Cr("FEtopics_gaming")},{name:"Live",icon:"LIVE",value:Cr("FEtopics_live")},{name:"Subscriptions",icon:"SUBSCRIPTIONS",value:Cr("FEsubscriptions")},{name:"Library",icon:"TAB_LIBRARY",value:Cr("FElibrary")},{name:"More",icon:"TAB_MORE",value:Cr("FEtopics_more")}];function Fr(e){var t=Pr(e);return t&&me(t.key)?-1!==(me("sponsorBlockManualSkips")||[]).indexOf(e)?"show":"skip":"off"}function Pr(e){for(var t=0;t<pr.length;t++)if(pr[t].type===e)return pr[t];return null}function Br(e,t,n,i){return{name:e,icon:n,value:t,hint:i}}function Ir(e,t,n,i){return{name:e,key:t,value:n,also:i}}function Nr(e,t,n,i,r){return{name:e,icon:t,value:null,menuHeader:i,options:n,refresh:r}}function Mr(e,t){return{title:e,subtitle:t}}function Rr(e,t,n,i,r,a,o){return{name:e,icon:t,value:null,options:{title:n,subtitle:i,content:r,links:o},refresh:a}}function Lr(e,t){return e.hint=t,e}function Or(e,t,n){return{name:e,icon:t,launchDebugger:n}}function _r(){var e=sr(),t=e&&e.urls.filter(function(e){return!!e})[0];return e&&t?[je("settings.phoneSync.qrHint"),{qrLink:"".concat(t,"/?code=").concat(e.code)}]:[je("settings.phoneSync.noQr")]}function Ur(){var e=dr();return e.checked?e.service?[je("settings.webConfig.online")].concat(function(){var e=sr();if(!e)return[je("settings.phoneSync.waiting")];var t=[je("settings.phoneSync.intro")],n=e.urls.filter(function(e){return!!e})[0];return n&&t.push(je("settings.phoneSync.address",{url:n})),t.push(je("settings.phoneSync.code",{code:e.code})),t}()):[je("settings.webConfig.offline")]:[je("settings.status.checking")]}function jr(){var e=dr(),t=[je("settings.about.userscript",{version:Ji})];return e.checked?(t.push(e.service?je("settings.about.serviceOnline",{version:e.service.version}):je("settings.about.serviceOffline")),t.push(e.proxy?je("settings.about.proxyOnline",{version:e.proxy.version}):je("settings.about.proxyOffline")),t.push(function(e){var t=e.service&&e.service.bundle;return t&&t.current?t.available&&t.latest?je("settings.about.bundleUpdate",{current:t.current,latest:t.latest}):je("settings.about.bundleCurrent",{version:t.current}):je("settings.about.bundleUnknown")}(e)),t.push(function(e){if(!e.service)return je("settings.about.launchUnknown");var t=e.service.launchDebugger?je("settings.advanced.launch.debuggerShort"):je("settings.advanced.launch.proxyShort");return je("settings.about.launchMode",{mode:t})}(e)),t):(t.push(je("settings.status.checking")),t)}function Hr(){var e,t,n;return[Nr(je("settings.playback.title"),"PLAY_CIRCLE",[Nr(je("settings.playback.quality.title"),"VIDEO_QUALITY",gr.map(function(e){return Ir("auto"===e?je("settings.common.auto"):e,"preferredVideoQuality",e)}),Mr(je("settings.playback.quality.title"),je("settings.playback.quality.subtitle"))),Nr(je("settings.playback.codec.title"),"VIDEO_QUALITY",vr.map(function(e){return Ir("any"===e?je("settings.common.any"):e.toUpperCase(),"videoPreferredCodec",e)}),Mr(je("settings.playback.codec.title"),je("settings.playback.codec.subtitle"))),Nr(je("settings.playback.speedStep.title"),"SLOW_MOTION_VIDEO",Er.map(function(e){return Ir("".concat(e,"x"),"speedSettingsIncrement",e)}),Mr(je("settings.playback.speedStep.title"),je("settings.playback.speedStep.subtitle"))),(n=te(),n&&n.SetFrameRate?Nr(je("settings.playback.frameRate.title"),"SYNC",[Br(je("settings.playback.frameRate.match"),"autoFrameRate","SCREEN_SWITCH"),Nr(je("settings.playback.frameRate.pause.title"),"TIMER",Sr.map(function(e){return Ir(Jr(e),"autoFrameRatePauseVideoFor",1e3*e)}),Mr(je("settings.playback.frameRate.pause.title"),je("settings.playback.frameRate.pause.subtitle")))],Mr(je("settings.playback.frameRate.title"),je("settings.playback.frameRate.subtitle"))):null),Nr(je("settings.playback.captions.title"),"CAPTIONS",[Br(je("settings.playback.captions.onByDefault"),"enableAutoSubtitles","CLOSED_CAPTION_SELECTED"),Nr(je("settings.playback.captions.language.title"),"TRANSLATE",br.map(function(e){return Ir(je("settings.playback.languages.".concat(e)),"autoSubtitleLanguage",e)}),Mr(je("settings.playback.captions.language.title"),je("settings.playback.captions.language.subtitle"))),Br(je("settings.playback.captions.allowAuto"),"autoSubtitleAllowAuto","SPARKLE"),Br(je("settings.playback.captions.myLanguage"),"enableShowUserLanguage","LANGUAGE"),Br(je("settings.playback.captions.otherLanguages"),"enableShowOtherLanguages","TRANSLATE")],Mr(je("settings.playback.captions.title"),je("settings.playback.captions.subtitle"))),Nr(je("settings.playback.panelShrink.title"),"COMMENT",[Br(je("settings.playback.panelShrink.on"),"enablePanelShrink","COMMENT"),Nr(je("settings.playback.panelShrink.size.title"),"VIDEO_QUALITY",[Ir("50%","panelShrinkPercent","50"),Ir("60%","panelShrinkPercent","60"),Ir("70%","panelShrinkPercent","70")],Mr(je("settings.playback.panelShrink.size.title"),je("settings.playback.panelShrink.size.subtitle")))],Mr(je("settings.playback.panelShrink.title"),je("settings.playback.panelShrink.subtitle"))),Br(je("settings.playback.pauseInBackground"),"enablePauseOnBlur","PAUSE"),Br(je("settings.playback.remainingTime"),"enableRemainingTime","TIMER")],Mr(je("settings.playback.title"),je("settings.playback.subtitle"))),Nr(je("settings.playerControls.title"),"SETTINGS_REMOTE",[Br(je("settings.playerControls.customize"),"enablePatchingVideoPlayer","EDIT",je("settings.playerControls.hints.customize")),Br(je("settings.playerControls.previousNext"),"enablePreviousNextButtons","SKIP_NEXT",je("settings.playerControls.hints.previousNext")),Br(je("settings.playerControls.speed"),"enableSpeedControlsButton","SLOW_MOTION_VIDEO",je("settings.playerControls.hints.speed")),Br(je("settings.playerControls.superThanks"),"enableSuperThanksButton","HANDS_HEART",je("settings.playerControls.hints.superThanks")),Br(je("settings.playerControls.miniPlayer"),"enableMPButton","MULTIVIEW",je("settings.playerControls.hints.miniPlayer")),Br(je("settings.playerControls.pipInsteadOfMini"),"enableSwapMPWithPIP","SCREEN_SWITCH",je("settings.playerControls.hints.pipInsteadOfMini")),Br(je("settings.ads.paidPromotion"),"enablePaidPromotionOverlay","PAID",je("settings.playerControls.hints.paidPromotion")),Br(je("settings.playerControls.onePress"),"enableOnePressMode","SPACE_BAR",je("settings.playerControls.hints.onePress"))],Mr(je("settings.playerControls.title"),je("settings.playerControls.subtitle"))),Nr(je("settings.ads.title"),"SLASH_CIRCLE_LEFT",[Br(je("settings.ads.blockAds"),"enableAdBlock","HEALTH_AND_SAFETY"),Br(je("settings.ads.playerTracking"),"blockPlayerAdTracking","HEALTH_AND_SAFETY"),Br(je("settings.ads.adTelemetry"),"blockAdTelemetry","HEALTH_AND_SAFETY"),Br(je("settings.ads.viewStats"),"blockViewStatsTelemetry","HEALTH_AND_SAFETY"),Br(je("settings.ads.liveVideos"),"removeLiveVideos","VISIBILITY_OFF"),Br(je("settings.ads.topLiveGames"),"removeTopLiveGames","VISIBILITY_OFF"),Br(je("settings.ads.mostRelevant"),"removeMostRelevant","VISIBILITY_OFF"),Br(je("settings.ads.sponsorBlock"),"enableSponsorBlock","SPONSORSHIP_STAR"),Nr(je("settings.ads.segmentTypes.title"),"SETTINGS",pr.map(function(e){return{name:je("settings.ads.segments.".concat(e.type)),icon:e.icon,segment:e.type}}),Mr(je("settings.ads.segmentTypes.title"),je("settings.ads.segmentTypes.subtitle"))),Br(je("settings.ads.highlightButton"),"enableSponsorBlockHighlight","STAR"),Br(je("settings.ads.notices"),"enableSponsorBlockToasts","INFO")],Mr(je("settings.ads.title"),je("settings.ads.subtitle"))),Nr(je("settings.browsing.title"),"EXPLORE",[Nr(je("settings.browsing.thumbnails.title"),"EYE",[Br(je("settings.browsing.hqThumbnails"),"enableHqThumbnails","VIDEO_QUALITY"),Br(je("settings.browsing.deArrowTitles"),"enableDeArrowTitles","TEXT_BOX"),Br(je("settings.browsing.deArrowThumbnails"),"enableDeArrowThumbnails","EYE"),Br(je("settings.browsing.deArrowPeek"),"enableDeArrowPeek","VISIBILITY")],Mr(je("settings.browsing.thumbnails.title"),je("settings.browsing.thumbnails.subtitle"))),Nr(je("settings.browsing.previews.title"),"PLAY_CIRCLE",[Br(je("settings.browsing.previews.on"),"enablePreviews","PLAY_ARROW_CIRCLE"),{name:je("settings.browsing.previews.length"),icon:"TIMER",value:"previewLengthSeconds",stepper:5}],Mr(je("settings.browsing.previews.title"),je("settings.browsing.previews.subtitle"))),Nr(je("settings.browsing.hideWatched.title"),"VISIBILITY_OFF",[Br(je("settings.browsing.hideWatched.on"),"enableHideWatchedVideos","VISIBILITY_OFF"),Nr(je("settings.browsing.hideWatched.threshold.title"),"TIMER",wr.map(function(e){return Ir("".concat(e,"%"),"hideWatchedVideosThreshold",e)}),Mr(je("settings.browsing.hideWatched.threshold.title"),je("settings.browsing.hideWatched.threshold.subtitle"))),{name:je("settings.browsing.hideWatched.pages.title"),value:null,arrayToEdit:"hideWatchedVideosPages",menuHeader:Mr(je("settings.browsing.hideWatched.pages.title"),je("settings.browsing.hideWatched.pages.subtitle")),options:[{name:"Search Results",icon:"SEARCH",value:"search"},{name:"Home",icon:"WHAT_TO_WATCH",value:"home"},{name:"Music",icon:"YOUTUBE_MUSIC",value:"music"},{name:"Gaming",icon:"GAMING",value:"gaming"},{name:"Subscriptions",icon:"SUBSCRIPTIONS",value:"subscriptions"},{name:"Library",icon:"TAB_LIBRARY",value:"library"},{name:"More",icon:"TAB_MORE",value:"more"}]}],Mr(je("settings.browsing.hideWatched.title"),je("settings.browsing.hideWatched.subtitle"))),Br(je("settings.browsing.shorts"),"enableShorts","YOUTUBE_SHORTS_FILL_24"),Br(je("settings.browsing.endScreens"),"enableHideEndScreenCards","VISIBILITY_OFF"),Br(je("settings.browsing.longPress"),"enableLongPress","ADD_TO_PLAYLIST"),Br(je("settings.browsing.stillWatching"),"enableYouThereRenderer","PERSON")],Mr(je("settings.browsing.title"),je("settings.browsing.subtitle"))),Nr(je("settings.home.title"),"HOME",[Nr(je("settings.home.startup.title"),"TV",Tr.map(function(e){return{name:e.name,icon:e.icon,key:"launchToOnStartup",value:e.value}}),Mr(je("settings.home.startup.title"),je("settings.home.startup.subtitle"))),Br(je("settings.home.reloadHome"),"reloadHomeOnStartup","ARROW_CIRCLE"),{name:je("settings.home.sidebarItems.title"),icon:"LIST",value:null,arrayToEdit:"disabledSidebarContents",menuHeader:Mr(je("settings.home.sidebarItems.title"),je("settings.home.sidebarItems.subtitle")),options:kr.map(function(e){return{name:e.name,icon:e.icon,value:e.icon}})},Br(je("settings.home.hideChannels"),"disableChannelsOnSidebar","PERSON_MINUS"),Br(je("settings.home.sortSubscriptions"),"sortSubscriptionsByAlphabet","SORT")],Mr(je("settings.home.title"),je("settings.home.subtitle"))),Nr(je("settings.appearance.title"),"AUTO_AWESOME",[Nr(je("settings.appearance.theme.title"),"LENS_BLUE",[Nr(je("settings.appearance.theme.presets.title"),"LENS_MAGENTA",mr.map(function(e){return Ir(je("settings.appearance.colors.".concat(e)),"themePreset",e)}),Mr(je("settings.appearance.theme.presets.title"),je("settings.appearance.theme.presets.subtitle"))),Nr(je("settings.appearance.theme.background.title"),"LENS_BLACK",mr.map(function(e){return Ir(je("settings.appearance.colors.".concat(e)),"routeColor",re.themePresetColors[e])}),Mr(je("settings.appearance.theme.background.title"),je("settings.appearance.theme.background.subtitle"))),Nr(je("settings.appearance.theme.text.title"),"TEXT_BOX",yr.map(function(e){return Ir(je("settings.appearance.textColors.".concat(e)),"textTheme",e)}),Mr(je("settings.appearance.theme.text.title"),je("settings.appearance.theme.text.subtitle")))],Mr(je("settings.appearance.theme.title"),je("settings.appearance.theme.subtitle"))),Nr(je("settings.appearance.dimming.title"),"EYE_OFF",[Br(je("settings.appearance.dimming.on"),"enableScreenDimming","EYE_OFF"),Nr(je("settings.appearance.dimming.timeout.title"),"TIMER",Dr.map(function(e){return Ir(function(e){return e>=60?je("settings.minutes",{count:e/60}):Jr(e)}(e),"dimmingTimeout",e)}),Mr(je("settings.appearance.dimming.timeout.title"),je("settings.appearance.dimming.timeout.subtitle"))),Nr(je("settings.appearance.dimming.opacity.title"),"LENS_BLUE",Ar.map(function(e){return Ir("".concat(Math.round(100*e),"%"),"dimmingOpacity",e)}),Mr(je("settings.appearance.dimming.opacity.title"),je("settings.appearance.dimming.opacity.subtitle")))],Mr(je("settings.appearance.dimming.title"),je("settings.appearance.dimming.subtitle"))),Br(je("settings.appearance.performance"),"enablePerformanceMode","SPEED_RUN"),Nr(je("settings.appearance.clock.title"),"SCHEDULE",[Nr(je("settings.appearance.clock.show.title"),"VISIBILITY",[Ir(je("settings.appearance.clock.show.off"),"clockMode","off"),Ir(je("settings.appearance.clock.show.always"),"clockMode","always"),Ir(je("settings.appearance.clock.show.notPlaying"),"clockMode","notPlaying")],Mr(je("settings.appearance.clock.show.title"),je("settings.appearance.clock.show.subtitle"))),Nr(je("settings.appearance.clock.format.title"),"TEXT_BOX",[Ir(je("settings.appearance.clock.format.h24"),"clockFormat","24h"),Ir(je("settings.appearance.clock.format.h12"),"clockFormat","12h"),Ir(je("settings.appearance.clock.format.h12NoAmPm"),"clockFormat","12hNoAmPm")],Mr(je("settings.appearance.clock.format.title"),je("settings.appearance.clock.format.subtitle"))),Nr(je("settings.appearance.clock.position.title"),"LOCATION_POINT",[Ir(je("settings.appearance.clock.position.topLeft"),"clockPosition","topLeft"),Ir(je("settings.appearance.clock.position.topRight"),"clockPosition","topRight"),Ir(je("settings.appearance.clock.position.bottomLeft"),"clockPosition","bottomLeft"),Ir(je("settings.appearance.clock.position.bottomRight"),"clockPosition","bottomRight")],Mr(je("settings.appearance.clock.position.title"),je("settings.appearance.clock.position.subtitle"))),Br(je("settings.appearance.clock.seconds"),"clockShowSeconds","TIMER")],Mr(je("settings.appearance.clock.title"),je("settings.appearance.clock.subtitle"))),Br(je("settings.appearance.fullAnimations"),"enableFixedUI","PROGRESS_ACTIVITY")],Mr(je("settings.appearance.title"),je("settings.appearance.subtitle"))),Nr(je("settings.axotube.title"),"SPARK",[Lr(Rr(je("settings.webConfig.title"),"PHONELINK",je("settings.webConfig.title"),je("settings.webConfig.subtitle"),Ur,hr,[{name:je("settings.webConfig.qrTitle"),icon:"SMARTPHONE",value:null,options:{title:je("settings.webConfig.qrTitle"),subtitle:je("settings.webConfig.qrSubtitle"),content:_r}}]),je("settings.webConfig.rowHint")),Nr(je("settings.system.whosWatching.title"),"ACCOUNT_CIRCLE",[Br(je("settings.system.whosWatching.on"),"enableWhoIsWatchingMenu","PEOPLE"),Br(je("settings.system.whosWatching.always"),"permanentlyEnableWhoIsWatchingMenu","PERSON"),Br(je("settings.system.whosWatching.onExit"),"enableWhosWatchingMenuOnAppExit","EXIT_APP")],Mr(je("settings.system.whosWatching.title"),je("settings.system.whosWatching.subtitle"))),Br(je("settings.system.signInReminder"),"enableSigninReminder","SIGN_IN"),Br(je("settings.system.welcome"),"showWelcomeToast","SPARKLE"),Nr(je("settings.system.updates.title"),"SYSTEM_UPDATE",[{name:je("settings.system.updates.checkNow"),icon:"SYSTEM_UPDATE",action:"CHECK_FOR_UPDATES"},Br(je("settings.system.updates.onStartup"),"enableUpdater","SYSTEM_UPDATE")],Mr(je("settings.system.updates.title"),je("settings.system.updates.subtitle",{version:Ji}))),{name:je("settings.system.restartCast"),icon:"CAST_ICON",action:"AXO_CAST_RESTART"},{name:je("settings.system.reload"),icon:"REPLAY",action:"AXO_RELOAD_PAGE"}],Mr(je("settings.axotube.title"),je("settings.axotube.subtitle"))),Nr(je("settings.advanced.title"),"SETTINGS",[{name:je("settings.advanced.diagnostics.title"),icon:"BUG_REPORT",action:"SETTINGS_OPEN_DIAGNOSTICS"},Nr(je("settings.advanced.userAgent.title"),"LANGUAGE",[Ir(je("settings.advanced.userAgent.samsung"),"userAgentProfile","samsung",["auto"]),Ir(je("settings.advanced.userAgent.android"),"userAgentProfile","android")],Mr(je("settings.advanced.userAgent.title"),je("settings.advanced.userAgent.subtitle"))),Nr(je("settings.advanced.launch.title"),"CAST_MOBILE",[Or(je("settings.advanced.launch.proxy"),"TV",!1),Or(je("settings.advanced.launch.debugger"),"SETTINGS_REMOTE",!0)],Mr(je("settings.advanced.launch.title"),je("settings.advanced.launch.subtitle")),hr),Nr(je("settings.playback.experimental.title"),"VIDEO_QUALITY_4K",[Br(je("settings.playback.experimental.unlock"),"enableExperimentalResolution","VIDEO_QUALITY_8K"),Nr(je("settings.playback.experimental.max.title"),"VIDEO_QUALITY",xr.map(function(e){return Ir(e,"experimentalMaxResolution",e)}),Mr(je("settings.playback.experimental.max.title"),je("settings.playback.experimental.max.subtitle")))],Mr(je("settings.playback.experimental.title"),je("settings.playback.experimental.subtitle")))],Mr(je("settings.advanced.title"),je("settings.advanced.subtitle"))),Rr(je("settings.about.title"),"INFO",je("settings.about.title"),je("settings.about.subtitle"),jr,hr,[(e={name:"GitHub",icon:"PRIVACY_PUBLIC",value:null,options:{title:"GitHub",subtitle:je("settings.about.socials.githubHint"),content:[je("settings.about.scanMessage",{name:"GitHub"}),{qrLink:"https://github.com/TizenDroid/axotube"}]}},t={name:"Discord",icon:"COMMENT",value:null,options:{title:"Discord",subtitle:je("settings.about.socials.discordHint"),content:[je("settings.about.scanMessage",{name:"Discord"}),{qrLink:"https://discord.gg/UDb8nak5YD"}]}},Nr(je("settings.about.socials.title"),"PEOPLE",[e,t],Mr(je("settings.about.socials.title"),je("settings.about.socials.subtitle"))))]),{text:je("settings.moreOnWeb.text")}]}var zr="root",Gr="axo-settings",Kr=new Map,Xr=null;function Vr(e,t){for(var n=0;n<e.length;n++){var i=e[n];if(i){var r="".concat(t,".").concat(n);Kr.set(r,i),Array.isArray(i.options)&&Vr(i.options,r),i.options&&Array.isArray(i.options.links)&&Vr(i.options.links,"".concat(r,".links"))}}}function Wr(e,t){return[{customAction:{action:e,parameters:t}}]}function Jr(e){return je("settings.seconds",{count:e})}function qr(e,t,n,i){if(void 0!==e.text)return mt(e.text);if(e.action)return ct({title:e.name},{icon:e.icon},[{customAction:{action:e.action}}]);if(void 0!==e.segment){var r=Fr(e.segment);return ct({title:e.name,subtitle:je("settings.segmentModes.".concat(r))},{icon:e.icon},Wr("SETTINGS_SEGMENT",{category:e.segment,panel:i,index:Yr(t)}))}if(void 0!==n){var a=-1!==(me(n)||[]).indexOf(e.value);return ct({title:e.name},{icon:e.icon,secondaryIcon:a?"CHECK_BOX":"CHECK_BOX_OUTLINE_BLANK"},Wr("SETTINGS_SET",{key:n,valName:"arrayValue",value:e.value,panel:i,index:Yr(t)}))}if(void 0!==e.launchDebugger){var o=dr(),s=o.service?o.service.launchDebugger:null;return ct({title:e.name},{icon:e.icon,secondaryIcon:s===e.launchDebugger?"RADIO_BUTTON_CHECKED":"RADIO_BUTTON_UNCHECKED"},Wr("SETTINGS_LAUNCH",{debugger:e.launchDebugger,panel:i,index:Yr(t)}))}if(void 0!==e.key){var u=me(e.key),l=u===e.value||!!e.also&&-1!==e.also.indexOf(u);return ct({title:e.name},{icon:e.icon,secondaryIcon:l?"RADIO_BUTTON_CHECKED":"RADIO_BUTTON_UNCHECKED"},Wr("SETTINGS_SET",{key:e.key,valName:"stringValue",value:e.value,panel:i,index:Yr(t)}))}return void 0!==e.stepper?ct({title:e.name,subtitle:Jr(me(e.value))},{icon:e.icon},Wr("SETTINGS_OPEN",{id:t})):void 0!==e.arrayToEdit||e.options&&"object"===b(e.options)?ct({title:e.name,subtitle:e.hint},{icon:e.icon},Wr("SETTINGS_OPEN",{id:t})):"string"==typeof e.value?ct({title:e.name,subtitle:e.hint},{icon:e.icon,secondaryIcon:me(e.value)?"CHECK_BOX":"CHECK_BOX_OUTLINE_BLANK"},Wr("SETTINGS_TOGGLE",{key:e.value,panel:i,index:Yr(t)})):null}function Yr(e){var t=e.lastIndexOf(".");return Number(e.slice(t+1))}function Qr(e,t,n){for(var i=[],r=0;r<e.length;r++){var a=e[r];if(a){var o=qr(a,"".concat(t,".").concat(r),n,t);o&&i.push(o)}}return i}function Zr(e){var t,n=[],i=c(e);try{for(i.s();!(t=i.n()).done;){var r=t.value;if("string"==typeof r)n.push(mt(r));else if(r&&r.qrLink){var a=tr(r.qrLink);a&&n.push(yt(a))}}}catch(e){i.e(e)}finally{i.f()}return n}function $r(e,t){for(var n=[],i=e.options&&e.options.links||[],r=0;r<i.length;r++)if(i[r]){var a=qr(i[r],"".concat(t,".links.").concat(r),void 0,t);a&&n.push(a)}return n}function ea(e,t,n){var i,r=function(e){if(e===zr||!Kr.has(e))return{header:{title:je("settings.ttSettings.title"),subtitle:je("settings.ttSettings.madeByText")},rows:Qr(Xr,zr)};var t=Kr.get(e);if(void 0!==t.stepper){var n=me(t.value),i=t.stepper;return{header:{title:t.name},rows:[ct({title:"−".concat(Jr(i))},null,Wr("SETTINGS_STEP",{key:t.value,step:-i,panel:e})),mt(Jr(n)),ct({title:"+".concat(Jr(i))},null,Wr("SETTINGS_STEP",{key:t.value,step:i,panel:e}))]}}if(void 0!==t.arrayToEdit)return{header:t.menuHeader||{title:t.name},rows:Qr(t.options,e,t.arrayToEdit)};if(t.options&&"object"===b(t.options)&&!Array.isArray(t.options)){var r="function"==typeof t.options.content?t.options.content():t.options.content||[];if(r.some(function(e){return e&&e.qrLink})){var a=r.filter(function(e){return"string"==typeof e});return{header:{title:t.options.title,subtitle:a.length?a.join(" "):t.options.subtitle},rows:Zr(r.filter(function(e){return e&&e.qrLink}))}}return{header:{title:t.options.title,subtitle:t.options.subtitle},rows:Zr(r).concat($r(t,e))}}return{header:t.menuHeader||{title:t.name},rows:Qr(t.options||[],e)}}(e);ut(r.header,lt(r.rows,n||0),e===zr?Gr:(i=e,"".concat(Gr,":").concat(i)),t)}function ta(e,t,n){e(),t&&ea(t,!0,n)}function na(e,t){var n,i,r=t||{};switch(e){case"SETTINGS_OPEN":var a=Kr.get(r.id);return ea(r.id,!1),void(a&&a.refresh&&a.refresh(function(){return ea(r.id,!0)}));case"SETTINGS_OPEN_DIAGNOSTICS":return void(location.href="http://127.0.0.1:8081/axotube/diagnostics");case"SETTINGS_LAUNCH":return n=r.debugger,i=function(e){st(je("app.name"),je(e?"settings.advanced.launch.saved":"settings.advanced.launch.failed")),ea(r.panel,!0,r.index)},void Jt("".concat(ur,"/api/launch"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({debugger:!!n})}).then(function(e){return!(!e||!e.ok)}).catch(function(){return!1}).then(function(e){hr(function(){i&&i(e)})});case"SETTINGS_TOGGLE":return void ta(function(){return qi(r.key,"boolValue",!me(r.key))},r.panel,r.index);case"SETTINGS_SET":return void ta(function(){return qi(r.key,r.valName,r.value)},r.panel,r.index);case"SETTINGS_SEGMENT":return void ta(function(){return function(e,t){var n=Pr(e);if(n){var i="off"!==t;!!me(n.key)!==i&&qi(n.key,"boolValue",i),-1!==(me("sponsorBlockManualSkips")||[]).indexOf(e)!=("show"===t)&&qi("sponsorBlockManualSkips","arrayValue",e)}}(r.category,fr[Fr(r.category)])},r.panel,r.index);case"SETTINGS_STEP":var o=re.ranges&&re.ranges[r.key],s=(Number(me(r.key))||0)+r.step;return o&&(s=Math.min(o[1],Math.max(o[0],s))),void ta(function(){return qi(r.key,"intValue",s)},r.panel,1);default:return}}function ia(){Xr=Hr(),Kr=new Map,Vr(Xr,zr),ea(zr,!1)}window.isPipPlaying=!1;var ra=null,aa=null,oa=0,sa=null,ua=null,la=[],ca={length:0,classes:[]},ha={length:0,classes:[]};function da(){aa||oa>=120||(aa=setTimeout(function(){aa=null,pa()},250))}function pa(){oa+=1;try{var e=window._yttv?Object.values(window._yttv).find(function(e){return e&&e.mappings instanceof Map}):null;if(!e)return da(),!1;var t=e.get("PlayerService"),n=e.get("PlaybackPreviewService");if(!t||!n)return da(),!1;if(ra=t,!n.__axotubePipPatched){var i=n.start,r=n.stop;"function"==typeof i&&(n.start=function(){if(!window.isPipPlaying){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return i.apply(this,t)}}),"function"==typeof r&&(n.stop=function(){if(!window.isPipPlaying){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return r.apply(this,t)}}),n.__axotubePipPatched=!0}return!0}catch(e){return console.warn("[AxoTube:pictureInPicture] PiP service loading failed:",e),da(),!1}}function fa(e,t){var n=setTimeout(function(){var t=la.indexOf(n);-1!==t&&la.splice(t,1),e()},t);return la.push(n),n}function ma(e,t,n){if(e&&e.classList&&t)if(0===n.length&&(n.length=e.classList.length),n.length!==e.classList.length&&n.classes.length){var i,r=c(n.classes);try{for(r.s();!(i=r.n()).done;){var a=i.value;t.classList.add(a)}}catch(e){r.e(e)}finally{r.f()}}else for(var o=0;o<e.classList.length;o++){var s=e.classList[o];n.classes.includes(s)||n.classes.push(s),t.classList.add(s)}}function ya(){if(window.isPipPlaying)try{var e=document.querySelector("ytlr-search-bar");if(!e||document.querySelector("#axo-pip-button"))return;var t=e.querySelector("ytlr-search-voice");if(!t||!t.children[0]||!t.children[0].children[0])return;var n=window._yttv?Object.values(window._yttv).find(function(e){return e instanceof Map&&e.has("CLEAR_COOKIES")}):null;if(!n)return;var i=n.get("MICROPHONE_ON"),r=n.get("CLEAR_COOKIES"),a=document.createElement("ytlr-search-voice");ma(t,a,ca),a.style.left="10.25em",a.id="axo-pip-button";var o=document.createElement("ytlr-search-voice-mic-button");ma(t.children[0],o,ha);for(var s=document.createElement("yt-icon"),u=0;u<t.children[0].children[0].classList.length;u++)s.classList.add(t.children[0].children[0].classList[u]);i&&s.classList.remove(i),r&&s.classList.add(r),o.appendChild(s),a.appendChild(o),e.appendChild(a)}catch(e){console.warn("[AxoTube:pictureInPicture] PiP button creation failed:",e)}}"complete"===document.readyState?pa():window.addEventListener("load",pa);var ga=null;function va(){sa&&(sa.disconnect(),sa=null),null!==ga&&(cancelAnimationFrame(ga),ga=null);var e=document.querySelector("#axo-pip-button");e&&e.parentNode&&e.parentNode.removeChild(e)}function ba(){!function(){for(;la.length;)clearTimeout(la.pop())}(),ua&&(ua.disconnect(),ua=null),va();var e=document.querySelector("video");e&&["width","height","top","left","inset"].forEach(function(t){return e.style.removeProperty(t)});var t=document.querySelector("ytlr-player");t&&(t.style.removeProperty("display"),t.style.removeProperty("background-color"));var n=document.querySelector("ytlr-player-container");n&&n.style.removeProperty("z-index")}function xa(){if(ra||pa())try{if(!Ze())return;var e=document.querySelector("video"),t=document.querySelector("ytlr-player"),n=document.querySelector("ytlr-player-container");if(!e||!t||!n)return;ba();var i=Math.floor(e.currentTime);ua=new MutationObserver(function(r){var a,o=c(r);try{var s,u=function(){if("class"!==a.value.attributeName)return 0;if(t.classList.contains("ytLrPlayerEnabled"))return 0;function r(){t.isConnected&&n.isConnected&&(n.style.zIndex="10",t.style.display="block",t.style.backgroundColor="rgba(0,0,0,0)")}return r(),fa(r,500),e.addEventListener("play",function e(){var t=document.querySelector("video");t&&(t.style.removeProperty("inset"),t.style.width="".concat(window.innerWidth/3.5,"px"),t.style.height="".concat(window.innerHeight/3.5,"px"),t.style.top="68vh",t.style.left="68vw",window.isPipPlaying=!0,!sa&&window.isPipPlaying&&document.body&&((sa=new MutationObserver(function(){null===ga&&(ga=requestAnimationFrame(function(){ga=null,window.isPipPlaying?ya():va()}))})).observe(document.body,{childList:!0,subtree:!0}),ya()),t.removeEventListener("play",e))}),ua&&(ua.disconnect(),ua=null),fa(function(){try{if(ra&&ra.loadedPlaybackConfig){var e=ra.loadedPlaybackConfig,t=Object.assign({},e);e.watchEndpoint&&(t.watchEndpoint=Object.assign({},e.watchEndpoint,{startTimeSeconds:i})),ra.loadVideo(t)}}catch(e){console.warn("[AxoTube:pictureInPicture] PiP video load failed:",e)}},1e3),1};for(o.s();!(a=o.n()).done&&(0===(s=u())||1!==s););}catch(e){o.e(e)}finally{o.f()}}),ua.observe(t,{attributes:!0,attributeFilter:["class"]});try{$e({signalAction:{signal:"HISTORY_BACK"}}).dispatched||ba()}catch(e){throw ba(),e}}catch(e){console.error("[AxoTube:pictureInPicture] Enable PiP failed:",e)}else{var r=0,a=function(){r+=1,ra||pa()?xa():r<20&&fa(a,200)};fa(a,200)}}function Ea(e){if(me("enableDeArrowPeek")){var t=e&&e.showMenuCommand;if(t&&t.contentId){var n,i=(n=t.contentId,Yt.get(n)||null),r=function(e){var t=qt.get(e);return t&&t.data?t.data:null}(t.contentId);if(i&&r){if(t.title){var a=!!me("enableDeArrowTitles")?i.title:Qt(r);a&&(t.title={simpleText:a})}if(t.thumbnail){var o=!!me("enableDeArrowThumbnails")?i.thumbnails:Zt(t.contentId,r);o&&(t.thumbnail={thumbnails:o})}}}}}function Sa(e,t){Jt("".concat("http://127.0.0.1:8090","/api/cast/restart"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({reason:e})}).then(function(e){return e.ok?e.json():Promise.reject(new Error("HTTP ".concat(e.status)))}).then(function(e){t&&t(null,e)}).catch(function(e){t&&t(e,null)})}document.addEventListener("visibilitychange",function(){document.hidden||Sa("focus")});var wa=null,Da=!1;function Aa(e){if(e)try{e.playbackRate=me("videoSpeed")}catch(e){console.warn("[AxoTube:speedUI] Speed apply failed:",e)}}function ka(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Ln();if(e&&e!==wa){if(wa)try{wa.removeEventListener("canplay",Ca)}catch(e){}wa=e;try{wa.addEventListener("canplay",Ca)}catch(e){console.warn("[AxoTube:speedUI] Speed initialization failed:",e)}Aa(wa)}}function Ca(){Ln()!==wa&&ka(),Aa(wa)}function Ta(){!function(){if(!Da){Da=!0;var e=function(e){if(406==e.keyCode||191==e.keyCode)return e.preventDefault(),e.stopPropagation(),"keydown"!==e.type||(Fa(),!1)};document.addEventListener("keydown",e,!0),document.addEventListener("keypress",e,!0),document.addEventListener("keyup",e,!0)}}(),zn(ka)}function Fa(){for(var e=me("videoSpeed"),t=0,n=Number(me("speedSettingsIncrement")),i=Number.isFinite(n)&&n>0?n:.25,r=Math.max(i,.05),a=[],o=r;o<=5&&a.length<100;o+=r){var s=Math.round(100*o)/100;a.push(ct({title:"".concat(s,"x")},null,[{signalAction:{signal:"POPUP_BACK"}},{setClientSettingEndpoint:{settingDatas:[{clientSettingEnum:{item:"videoSpeed"},intValue:s.toString()}]}},{customAction:{action:"SET_PLAYER_SPEED",parameters:s.toString()}}])),e===s&&(t=a.length-1)}1.0001===e&&(t=a.length),a.push(ct({title:"Fix stuttering (1.0001x)"},null,[{signalAction:{signal:"POPUP_BACK"}},{setClientSettingEndpoint:{settingDatas:[{clientSettingEnum:{item:"videoSpeed"},intValue:"1.0001"}]}},{customAction:{action:"SET_PLAYER_SPEED",parameters:"1.0001"}}]));try{ut("Playback Speed",lt(a,t),"axo-speed")}catch(e){console.error("[AxoTube:speedUI] Speed settings modal failed:",e)}}"loading"===document.readyState?document.addEventListener("DOMContentLoaded",Ta):Ta(),ge.addEventListener("configChange",function(e){var t;"videoSpeed"===(null===(t=e.detail)||void 0===t?void 0:t.key)&&(ka(),Aa(wa))});function Pa(e){return"string"==typeof window.__axotubeProxyUrl?window.__axotubeProxyUrl+e:(window.location&&window.location.origin?window.location.origin:"http://localhost:8081")+e}function Ba(e){fetch(Pa("/axotube/update/check"),{method:"POST",cache:"no-store"}).then(function(e){if(!e.ok)throw new Error("update check HTTP "+e.status);return e.json()}).then(function(t){if(t.error)throw new Error(t.error);t.available?function(e){var t=Math.floor(Date.now()/1e3);ut({title:je("updater.modalTitle"),subtitle:je("updater.modalBodyNew",{latest:e.latest,current:e.current})},lt([ct({title:je("updater.updateNow"),subtitle:je("updater.updateNowSubtitle")},{icon:"DOWN_ARROW"},[{customAction:{action:"AXO_UPDATE_APPLY",parameters:e.latest}},{signalAction:{signal:"POPUP_BACK"}}]),ct({title:je("updater.remindLater"),subtitle:je("updater.remindLaterSubtitle")},{icon:"SEARCH_HISTORY"},[{customAction:{action:"UPDATE_REMIND_LATER",parameters:t+86400}},{signalAction:{signal:"POPUP_BACK"}}])]),"axo-update-modal",!1)}(t):e&&st(je("app.name"),je("toasts.upToDate",{version:t.current}),null)}).catch(function(t){console.info("[AxoTube:updater] update check skipped:",t&&t.message),e&&st(je("app.name"),je("toasts.updateCheckFailed"),null)})}function Ia(){st(je("app.name"),je("updater.applying"),null),fetch(Pa("/axotube/update/apply"),{method:"POST"}).then(function(e){if(!e.ok)throw new Error("apply HTTP "+e.status);return e.json()}).then(function(e){if(e.error)throw new Error(e.error);!function(){var e=document.querySelector("video");if(!e||e.paused||e.ended)window.location.reload();else{st(je("app.name"),je("updater.reloadWhenPaused"),null);var t=function(){e.removeEventListener("pause",t),e.removeEventListener("ended",t),window.location.reload()};e.addEventListener("pause",t),e.addEventListener("ended",t)}}()}).catch(function(e){console.error("[AxoTube:updater] apply failed:",e&&e.message),st(je("app.name"),je("toasts.updateApplyFailed"),null)})}try{me("enableUpdater")&&me("dontCheckUpdateUntil")<=Math.floor(Date.now()/1e3)&&setTimeout(function(){return Ba(!1)},3e3)}catch(e){console.error("[AxoTube:updater] init failed, continuing without it",e)}function Na(e,t){return et(e,t)}function Ma(){return Xe=Ra,nt()}function Ra(e){var t=e.resolveCommand;if(t.__axotubePatched)return!0;var n=function(e,n){var i,r,a,o,s,u;if(!e||"object"!==b(e))return t.call(this,e,n);if(Ea(e),function(e){me("enablePauseOnBlur")&&bi(e)&&xi()}(e),e.setClientSettingEndpoint){if(!Array.isArray(e.setClientSettingEndpoint.settingDatas))return t.call(this,e,n);var l,h=c(e.setClientSettingEndpoint.settingDatas);try{for(h.s();!(l=h.n()).done;){var d,p=l.value,f=null==p||null===(d=p.clientSettingEnum)||void 0===d?void 0:d.item;if("string"==typeof f)if(f.includes("_")){if("I18N_LANGUAGE"===f){var m=p.stringValue;if("string"!=typeof m||!m)continue;var y=new Date;return y.setFullYear(y.getFullYear()+10),document.cookie="PREF=hl=".concat(m,"; expires=").concat(y.toUTCString(),";"),Na({signalAction:{signal:"RELOAD_PAGE"}}),!0}}else{var g=Object.keys(p).find(function(e){return e.includes("Value")});if(!g)continue;qi(f,g,"intValue"===g?Number(p[g]):p[g])}}}catch(e){h.e(e)}finally{h.f()}}else{if(e.customAction)return La(e.customAction.action,e.customAction.parameters),!0;if(null!=e&&null!==(i=e.signalAction)&&void 0!==i&&i.customAction)return La(e.signalAction.customAction.action,e.signalAction.customAction.parameters),!0;if(null!=e&&null!==(r=e.showEngagementPanelEndpoint)&&void 0!==r&&r.customAction)return La(e.showEngagementPanelEndpoint.customAction.action,e.showEngagementPanelEndpoint.customAction.parameters),!0;if(null!=e&&null!==(a=e.playlistEditEndpoint)&&void 0!==a&&a.customAction)return La(e.playlistEditEndpoint.customAction.action,e.playlistEditEndpoint.customAction.parameters),!0;if("playback-settings"===(null==e||null===(o=e.openPopupAction)||void 0===o?void 0:o.uniqueId))try{var v,x=e.openPopupAction.popup.overlaySectionRenderer.overlay.overlayTwoPanelRenderer.actionPanel.overlayPanelRenderer.content.overlayPanelItemListRenderer.items;if(!Array.isArray(x))return t.call(this,e,n);var E,S=c(x);try{for(S.s();!(E=S.n()).done;){var w,D=E.value;"SLOW_MOTION_VIDEO"===(null==D||null===(w=D.compactLinkRenderer)||void 0===w||null===(w=w.icon)||void 0===w?void 0:w.iconType)&&(D.compactLinkRenderer.subtitle&&(D.compactLinkRenderer.subtitle.simpleText=je("player.withAxotube")),D.compactLinkRenderer.serviceEndpoint={clickTrackingParams:"null",signalAction:{customAction:{action:"AXO_SPEED_SETTINGS_SHOW",parameters:[]}}})}}catch(e){S.e(e)}finally{S.f()}x.splice(2,0,ct({title:je("player.miniPlayer")},{icon:"CLEAR_COOKIES"},[{customAction:{action:"ENTER_MP"}}])),te()&&null!==(v=te())&&void 0!==v&&v.HasSystemFeature("android.software.picture_in_picture")&&x.splice(3,0,ct({title:je("player.pictureInPicture")},{icon:"PIP"},[{customAction:{action:"ENTER_PIP"}},{signalAction:{signal:"POPUP_BACK"}}]))}catch(e){console.warn("[AxoTube:resolveCommand] Playback settings patch failed:",e)}else null!=e&&null!==(s=e.watchEndpoint)&&void 0!==s&&s.videoId&&(window.isPipPlaying=!1,ba())}if(e.commandExecutorCommand&&Array.isArray(e.commandExecutorCommand.commands)){var A,k=c(e.commandExecutorCommand.commands);try{for(k.s();!(A=k.n()).done;){var C,T,F,P=A.value;P&&"object"===b(P)&&(P.customAction?La(P.customAction.action,P.customAction.parameters):null!==(C=P.signalAction)&&void 0!==C&&C.customAction?La(P.signalAction.customAction.action,P.signalAction.customAction.parameters):null!==(T=P.showEngagementPanelEndpoint)&&void 0!==T&&T.customAction?La(P.showEngagementPanelEndpoint.customAction.action,P.showEngagementPanelEndpoint.customAction.parameters):null!==(F=P.playlistEditEndpoint)&&void 0!==F&&F.customAction?La(P.playlistEditEndpoint.customAction.action,P.playlistEditEndpoint.customAction.parameters):t.call(this,P,n))}}catch(e){k.e(e)}finally{k.f()}return!0}return null!=e&&e.requestAccountSelectorCommand&&"ACCOUNT_EVENT_TRIGGER_ON_EXIT"===(null===(u=e.requestAccountSelectorCommand)||void 0===u||null===(u=u.identityActionContext)||void 0===u?void 0:u.eventTrigger)&&!me("enableWhosWatchingMenuOnAppExit")?(t.call(this,{signalAction:{signal:"EXIT_APP"}}),!1):t.call(this,e,n)};n.__axotubePatched=!0;try{return e.resolveCommand=n,e.resolveCommand===n}catch(e){return!1}}function La(e,t){switch(e){case"SKIP":var n=document.createEvent("Event");n.initEvent("keydown",!0,!0),n.keyCode=27,n.which=27,document.dispatchEvent(n);var i=document.querySelector("video"),r=Number(null==t?void 0:t.time);i&&Number.isFinite(r)&&(i.currentTime=r);break;case"AXO_SETTINGS_SHOW":ia();break;case"SETTINGS_OPEN":case"SETTINGS_SET":case"SETTINGS_TOGGLE":case"SETTINGS_STEP":case"SETTINGS_SEGMENT":case"SETTINGS_OPEN_DIAGNOSTICS":case"SETTINGS_LAUNCH":na(e,t);break;case"AXO_SPEED_SETTINGS_SHOW":Fa();break;case"UPDATE_REMIND_LATER":ye("dontCheckUpdateUntil",t);break;case"AXO_UPDATE_APPLY":Ia();break;case"SET_PLAYER_SPEED":var a=Number(t),o=document.querySelector("video");o&&Number.isFinite(a)&&a>0&&(o.playbackRate=a);break;case"ENTER_MP":xa();break;case"ENTER_PIP":te()&&te().EnterPIP&&te().EnterPIP();break;case"SHOW_TOAST":st(je("app.name"),t);break;case"ADD_TO_QUEUE":t?(window.queuedVideos.videos.push(t),st(je("app.name"),je("toasts.queueAdded"))):st(je("app.name"),je("toasts.queueAddFailed"));break;case"CLEAR_QUEUE":window.queuedVideos.videos=[],window.queuedVideos.currentIndex=-1,window.queuedVideos.lastVideoId=null,st(je("app.name"),je("toasts.queueCleared"));break;case"CHECK_FOR_UPDATES":Ba(!0);break;case"AXO_CAST_RESTART":Sa("manual",function(e,t){!e&&t&&t.ok?t.restarted?st(je("app.name"),je("toasts.castRestarted")):"too-soon"===t.reason?st(je("app.name"),je("toasts.castRestartWait")):"discovery-not-running"===t.reason?st(je("app.name"),je("toasts.castRestartNotRunning")):"in-progress"===t.reason?st(je("app.name"),je("toasts.castRestarting")):st(je("app.name"),je("toasts.castRestartFailed")):st(je("app.name"),je("toasts.castRestartFailed"))});break;case"AXO_RELOAD_PAGE":window.location.reload()}}var Oa=!1,_a=null,Ua=!1;function ja(){try{var e;if(null===(e=window.tectonicConfig)||void 0===e||!e.featureSwitches)return;var t=window.tectonicConfig.featureSwitches,n=De();t.enableAnimations=!n,t.enableOnScrollLinearAnimation=!n,t.enableListAnimations=!n,t.horizontalListDurationMs=n?0:200,t.verticalListDurationMs=n?0:300,t.listAnimationCurve=n?"linear":"",t.enableSkipButtonSlideInAnimation=!n,t.enableLikeButtonAnimation=!n}catch(e){console.warn("[AxoTube:ui] Reduced motion flags apply failed:",e)}}function Ha(){try{if(!document.body)return;document.body.classList.toggle("axotube-reduced-motion",De())}catch(e){console.warn("[AxoTube:ui] Reduced motion apply failed:",e)}}function za(){if(Ua){var e=document.getElementById("container");e&&e.style.setProperty("opacity","1","important"),Ua=!1}}function Ga(){_a&&(clearTimeout(_a),_a=null),za()}function Ka(){Ga(),me("enableScreenDimming")&&(_a=setTimeout(function(){var e;if(_a=null,me("enableScreenDimming")){var t=document.querySelector(".html5-video-player");if(t){var n=null===(e=t.getPlayerStateObject)||void 0===e?void 0:e.call(t);if(null==n||!n.isPlaying){var i=document.getElementById("container");i&&(i.style.setProperty("opacity",(1-me("dimmingOpacity")).toString(),"important"),Ua=!0)}}}else za()},1e3*me("dimmingTimeout")))}function Xa(){if(!Oa&&document.body&&window._yttv){Oa=!0,Ha();var e=document.querySelector("style[nonce]");if(e)e.textContent+=_i;else if(document.head){var t=document.createElement("style");t.textContent=_i,document.head.appendChild(t)}if("function"==typeof window.__releaseBootLoader&&window.__releaseBootLoader(),me("enableFixedUI")&&!Ae()&&!De())try{window.tectonicConfig&&(window.tectonicConfig.clientData.legacyApplicationQuality="full-animation",window.tectonicConfig.featureSwitches.enableAnimations=!0,window.tectonicConfig.featureSwitches.enableOnScrollLinearAnimation=!0,window.tectonicConfig.featureSwitches.enableListAnimations=!0)}catch(e){console.warn("[AxoTube:ui] Could not apply UI fixes:",e)}ja();var n=function(e){if(me("enableScreenDimming")&&Ka(),404==e.keyCode&&"keydown"===e.type){try{Ma()}catch(e){console.warn("[AxoTube:ui] Settings command patch refresh failed:",e)}try{ia()}catch(e){console.error("[AxoTube:ui] Settings open failed:",e)}}else if(39==e.keyCode&&"keydown"===e.type&&document.querySelector("ytlr-search-text-box > .zylon-focus")&&window.isPipPlaying)try{var t=document.querySelector("ytlr-player");t&&t.style.setProperty("background-color","rgb(0, 0, 0)"),function(){try{if(!ra||!ra.loadedPlaybackConfig)return;var e=document.querySelector("video"),t=ra.loadedPlaybackConfig,n=t.clickTrackingParams,i=t.commandMetadata,r=t.watchEndpoint;if(!$e({clickTrackingParams:n,commandMetadata:i,watchEndpoint:e&&r?Object.assign({},r,{startTimeSeconds:Math.floor(e.currentTime)}):r}).dispatched)return;window.isPipPlaying=!1,ba()}catch(e){console.error("[AxoTube:pictureInPicture] PiP to fullscreen failed:",e)}}()}catch(e){console.warn("[AxoTube:ui] PiP exit failed:",e)}return!0};document.addEventListener("keydown",n,!0),document.addEventListener("keypress",n,!0),document.addEventListener("keyup",n,!0),setTimeout(function(){me("showWelcomeToast")&&st(je("welcomeMsg.title"),"".concat(je("welcomeMsg.subtitle")," · v").concat(Ji))},1e3);var i=me("launchToOnStartup");if(i)try{Na(JSON.parse(i))}catch(e){console.warn("[AxoTube:ui] Launch command failed:",e)}else if(me("reloadHomeOnStartup"))try{location.hash&&"/"!==location.hash.substring(1)&&(location.hash="/")}catch(e){console.warn("[AxoTube:ui] Reload home on startup failed:",e)}try{var r=xt();r&&r.executeFunction(new r.commandFunction("reloadGuideAction"))}catch(e){console.warn("[AxoTube:ui] Guide reload failed:",e)}if(me("enableFixedUI")&&!Ae()&&!De())try{new MutationObserver(function(){var e=document.body;null!=e&&e.classList.contains("app-quality-root")&&e.classList.remove("app-quality-root")}).observe(document.body,{attributes:!0,attributeFilter:["class"]})}catch(e){console.warn("[AxoTube:ui] UI quality observer failed:",e)}!function(){try{Ma(),Ve||(Ve=!0,window.addEventListener("hashchange",rt,!1))}catch(e){console.warn("[AxoTube:ui] unable to install native command patch:",e)}}()}}function Va(){Oa||"complete"!==document.readyState&&"interactive"!==document.readyState||window._yttv&&Xa()}"loading"===document.readyState&&document.addEventListener("DOMContentLoaded",Va);var Wa=0,Ja=setInterval(function(){Wa+=1,Va(),(Oa||Wa>=100)&&clearInterval(Ja)},100),qa={routeColor:!0,routeBackgroundUrl:!0,themePreset:!0,textTheme:!0};ge.addEventListener("configChange",function(e){var t,n=null===(t=e.detail)||void 0===t?void 0:t.key;qa[n]&&Vi(),"enableReducedMotion"!==n&&"enablePerformanceMode"!==n&&"enableLowMemoryMode"!==n||(Ha(),ja()),"enableScreenDimming"===n&&(me("enableScreenDimming")?Ka():Ga())});var Ya=null;function Qa(){Ya&&(clearInterval(Ya),Ya=null)}function Za(e){e||Qa();var t=localStorage["yt.leanback.default::recurring_actions"];if(t){var n;try{n=JSON.parse(t)}catch(e){return}var i=me("permanentlyEnableWhoIsWatchingMenu"),r=n.data&&n.data.data;if(r){var a=r["startup-screen-account-selector-with-guest"],o=r.whos_watching_fullscreen_zero_accounts,s=r["startup-screen-signed-out-welcome-back"];if(!e){Qa();var u=new Date;return u.setDate(u.getDate()+7),void d(u.getTime())}var l=Date.now(),c=a&&a.lastFired;if(!(c&&l-c>0&&l-c<72e5)||i)if(Qa(),i){var h=function(){var e=new Date;e.setDate(e.getDate()-7),d(e.getTime())};h(),Ya=setInterval(h,6e4)}else d(Date.now())}}function d(e){a&&(a.lastFired=e),o&&(o.lastFired=e),s&&(s.lastFired=e),localStorage["yt.leanback.default::recurring_actions"]=JSON.stringify(n)}}ge.addEventListener("configChange",function(e){var t=e.detail,n=t.key,i=t.value;"enableWhoIsWatchingMenu"===n?Za(i):"permanentlyEnableWhoIsWatchingMenu"===n&&Za(me("enableWhoIsWatchingMenu"))}),Za(me("enableWhoIsWatchingMenu"));var $a={language:{standard:{long:{aa:"Afar",ab:"Abkhazian",ace:"Acehnese",ach:"Acoli",ada:"Adangme",ady:"Adyghe",ae:"Avestan",aeb:"Tunisian Arabic",af:"Afrikaans",afh:"Afrihili",agq:"Aghem",ain:"Ainu",ak:"Akan",akk:"Akkadian",akz:"Alabama",ale:"Aleut",aln:"Gheg Albanian",alt:"Southern Altai",am:"Amharic",an:"Aragonese",ang:"Old English",ann:"Obolo",anp:"Angika",ar:"Arabic","ar-001":"Arabic (world)",arc:"Aramaic",arn:"Mapuche",aro:"Araona",arp:"Arapaho",arq:"Algerian Arabic",ars:"Najdi Arabic",arw:"Arawak",ary:"Moroccan Arabic",arz:"Egyptian Arabic",as:"Assamese",asa:"Asu",ase:"American Sign Language",ast:"Asturian",atj:"Atikamekw",av:"Avaric",avk:"Kotava",awa:"Awadhi",ay:"Aymara",az:"Azerbaijani",ba:"Bashkir",bal:"Baluchi",ban:"Balinese",bar:"Bavarian",bas:"Basaa",bax:"Bamun",bbc:"Batak Toba",bbj:"Ghomala",be:"Belarusian",bej:"Beja",bem:"Bemba",bew:"Betawi",bez:"Bena",bfd:"Bafut",bfq:"Badaga",bg:"Bulgarian",bgc:"Haryanvi",bgn:"Western Balochi",bho:"Bhojpuri",bi:"Bislama",bik:"Bikol",bin:"Bini",bjn:"Banjar",bkm:"Kom",bla:"Siksiká",blo:"Anii",blt:"Tai Dam",bm:"Bambara",bn:"Bangla",bo:"Tibetan",bpy:"Bishnupriya",bqi:"Bakhtiari",br:"Breton",bra:"Braj",brh:"Brahui",brx:"Bodo",bs:"Bosnian",bss:"Akoose",bua:"Buriat",bug:"Buginese",bum:"Bulu",byn:"Blin",byv:"Medumba",ca:"Catalan",cad:"Caddo",car:"Carib",cay:"Cayuga",cch:"Atsam",ccp:"Chakma",ce:"Chechen",ceb:"Cebuano",cgg:"Chiga",ch:"Chamorro",chb:"Chibcha",chg:"Chagatai",chk:"Chuukese",chm:"Mari",chn:"Chinook Jargon",cho:"Choctaw",chp:"Chipewyan",chr:"Cherokee",chy:"Cheyenne",cic:"Chickasaw",ckb:"Central Kurdish",clc:"Chilcotin",co:"Corsican",cop:"Coptic",cps:"Capiznon",cr:"Cree",crg:"Michif",crh:"Crimean Tatar",crj:"Southern East Cree",crk:"Plains Cree",crl:"Northern East Cree",crm:"Moose Cree",crr:"Carolina Algonquian",crs:"Seselwa Creole French",cs:"Czech",csb:"Kashubian",csw:"Swampy Cree",cu:"Church Slavic",cv:"Chuvash",cwd:"Woods Cree",cy:"Welsh",da:"Danish",dak:"Dakota",dar:"Dargwa",dav:"Taita",de:"German","de-AT":"German (Austria)","de-CH":"German (Switzerland)",del:"Delaware",den:"Slave",dgr:"Dogrib",din:"Dinka",dje:"Zarma",doi:"Dogri",dsb:"Lower Sorbian",dtp:"Central Dusun",dua:"Duala",dum:"Middle Dutch",dv:"Divehi",dyo:"Jola-Fonyi",dyu:"Dyula",dz:"Dzongkha",dzg:"Dazaga",ebu:"Embu",ee:"Ewe",efi:"Efik",egl:"Emilian",egy:"Ancient Egyptian",eka:"Ekajuk",el:"Greek",elx:"Elamite",en:"English","en-AU":"English (Australia)","en-CA":"English (Canada)","en-GB":"English (United Kingdom)","en-US":"English (United States)",enm:"Middle English",eo:"Esperanto",es:"Spanish","es-419":"Spanish (Latin America)","es-ES":"Spanish (Spain)","es-MX":"Spanish (Mexico)",esu:"Central Yupik",et:"Estonian",eu:"Basque",ewo:"Ewondo",ext:"Extremaduran",fa:"Persian","fa-AF":"Persian (Afghanistan)",fan:"Fang",fat:"Fanti",ff:"Fula",fi:"Finnish",fil:"Filipino",fit:"Tornedalen Finnish",fj:"Fijian",fo:"Faroese",fon:"Fon",fr:"French","fr-CA":"French (Canada)","fr-CH":"French (Switzerland)",frc:"Cajun French",frm:"Middle French",fro:"Old French",frp:"Arpitan",frr:"Northern Frisian",frs:"Eastern Frisian",fur:"Friulian",fy:"Western Frisian",ga:"Irish",gaa:"Ga",gag:"Gagauz",gan:"Gan Chinese",gay:"Gayo",gba:"Gbaya",gbz:"Zoroastrian Dari",gd:"Scottish Gaelic",gez:"Geez",gil:"Gilbertese",gl:"Galician",glk:"Gilaki",gmh:"Middle High German",gn:"Guarani",goh:"Old High German",gon:"Gondi",gor:"Gorontalo",got:"Gothic",grb:"Grebo",grc:"Ancient Greek",gsw:"Swiss German",gu:"Gujarati",guc:"Wayuu",gur:"Frafra",guz:"Gusii",gv:"Manx",gwi:"Gwichʼin",ha:"Hausa",hai:"Haida",hak:"Hakka Chinese",haw:"Hawaiian",hax:"Southern Haida",hdn:"Northern Haida",he:"Hebrew",hi:"Hindi","hi-Latn":"Hindi (Latin)",hif:"Fiji Hindi",hil:"Hiligaynon",hit:"Hittite",hmn:"Hmong",hnj:"Hmong Njua",ho:"Hiri Motu",hr:"Croatian",hsb:"Upper Sorbian",hsn:"Xiang Chinese",ht:"Haitian Creole",hu:"Hungarian",hup:"Hupa",hur:"Halkomelem",hy:"Armenian",hz:"Herero",ia:"Interlingua",iba:"Iban",ibb:"Ibibio",id:"Indonesian",ie:"Interlingue",ig:"Igbo",ii:"Sichuan Yi",ik:"Inupiaq",ike:"Eastern Canadian Inuktitut",ikt:"Western Canadian Inuktitut",ilo:"Iloko",inh:"Ingush",io:"Ido",is:"Icelandic",it:"Italian",iu:"Inuktitut",izh:"Ingrian",ja:"Japanese",jam:"Jamaican Creole English",jbo:"Lojban",jgo:"Ngomba",jmc:"Machame",jpr:"Judeo-Persian",jrb:"Judeo-Arabic",jut:"Jutish",jv:"Javanese",ka:"Georgian",kaa:"Kara-Kalpak",kab:"Kabyle",kac:"Kachin",kaj:"Jju",kam:"Kamba",kaw:"Kawi",kbd:"Kabardian",kbl:"Kanembu",kcg:"Tyap",kde:"Makonde",kea:"Kabuverdianu",ken:"Kenyang",kfo:"Koro",kg:"Kongo",kgp:"Kaingang",kha:"Khasi",kho:"Khotanese",khq:"Koyra Chiini",khw:"Khowar",ki:"Kikuyu",kiu:"Kirmanjki",kj:"Kuanyama",kk:"Kazakh",kkj:"Kako",kl:"Kalaallisut",kln:"Kalenjin",km:"Khmer",kmb:"Kimbundu",kn:"Kannada",ko:"Korean",koi:"Komi-Permyak",kok:"Konkani",kos:"Kosraean",kpe:"Kpelle",kr:"Kanuri",krc:"Karachay-Balkar",kri:"Krio",krj:"Kinaray-a",krl:"Karelian",kru:"Kurukh",ks:"Kashmiri",ksb:"Shambala",ksf:"Bafia",ksh:"Colognian",ku:"Kurdish",kum:"Kumyk",kut:"Kutenai",kv:"Komi",kw:"Cornish",kwk:"Kwakʼwala",kxv:"Kuvi",ky:"Kyrgyz",la:"Latin",lad:"Ladino",lag:"Langi",lah:"Western Panjabi",lam:"Lamba",lb:"Luxembourgish",lez:"Lezghian",lfn:"Lingua Franca Nova",lg:"Ganda",li:"Limburgish",lij:"Ligurian",lil:"Lillooet",liv:"Livonian",lkt:"Lakota",lmo:"Lombard",ln:"Lingala",lo:"Lao",lol:"Mongo",lou:"Louisiana Creole",loz:"Lozi",lrc:"Northern Luri",lsm:"Saamia",lt:"Lithuanian",ltg:"Latgalian",lu:"Luba-Katanga",lua:"Luba-Lulua",lui:"Luiseno",lun:"Lunda",luo:"Luo",lus:"Mizo",luy:"Luyia",lv:"Latvian",lzh:"Literary Chinese",lzz:"Laz",mad:"Madurese",maf:"Mafa",mag:"Magahi",mai:"Maithili",mak:"Makasar",man:"Mandingo",mas:"Masai",mde:"Maba",mdf:"Moksha",mdr:"Mandar",men:"Mende",mer:"Meru",mfe:"Morisyen",mg:"Malagasy",mga:"Middle Irish",mgh:"Makhuwa-Meetto",mgo:"Metaʼ",mh:"Marshallese",mi:"Māori",mic:"Mi'kmaw",min:"Minangkabau",mk:"Macedonian",ml:"Malayalam",mn:"Mongolian",mnc:"Manchu",mni:"Manipuri",moe:"Innu-aimun",moh:"Mohawk",mos:"Mossi",mr:"Marathi",mrj:"Western Mari",ms:"Malay",mt:"Maltese",mua:"Mundang",mul:"Multiple languages",mus:"Muscogee",mwl:"Mirandese",mwr:"Marwari",mwv:"Mentawai",my:"Burmese",mye:"Myene",myv:"Erzya",mzn:"Mazanderani",na:"Nauru",nan:"Min Nan Chinese",nap:"Neapolitan",naq:"Nama",nb:"Norwegian Bokmål",nd:"North Ndebele",nds:"Low German","nds-NL":"Low German (Netherlands)",ne:"Nepali",new:"Newari",ng:"Ndonga",nia:"Nias",niu:"Niuean",njo:"Ao Naga",nl:"Dutch","nl-BE":"Dutch (Belgium)",nmg:"Kwasio",nn:"Norwegian Nynorsk",nnh:"Ngiemboon",no:"Norwegian",nog:"Nogai",non:"Old Norse",nov:"Novial",nqo:"N’Ko",nr:"South Ndebele",nso:"Northern Sotho",nus:"Nuer",nv:"Navajo",nwc:"Classical Newari",ny:"Nyanja",nym:"Nyamwezi",nyn:"Nyankole",nyo:"Nyoro",nzi:"Nzima",oc:"Occitan",oj:"Ojibwa",ojb:"Northwestern Ojibwa",ojc:"Central Ojibwa",ojg:"Eastern Ojibwa",ojs:"Oji-Cree",ojw:"Western Ojibwa",oka:"Okanagan",om:"Oromo",or:"Odia",os:"Ossetic",osa:"Osage",ota:"Ottoman Turkish",pa:"Punjabi",pag:"Pangasinan",pal:"Pahlavi",pam:"Pampanga",pap:"Papiamento",pau:"Palauan",pcd:"Picard",pcm:"Nigerian Pidgin",pdc:"Pennsylvania German",pdt:"Plautdietsch",peo:"Old Persian",pfl:"Palatine German",phn:"Phoenician",pi:"Pali",pis:"Pijin",pl:"Polish",pms:"Piedmontese",pnt:"Pontic",pon:"Pohnpeian",pqm:"Maliseet-Passamaquoddy",prg:"Prussian",pro:"Old Provençal",ps:"Pashto",pt:"Portuguese","pt-BR":"Portuguese (Brazil)","pt-PT":"Portuguese (Portugal)",qu:"Quechua",quc:"Kʼicheʼ",qug:"Chimborazo Highland Quichua",raj:"Rajasthani",rap:"Rapanui",rar:"Rarotongan",rgn:"Romagnol",rhg:"Rohingya",rif:"Riffian",rm:"Romansh",rn:"Rundi",ro:"Romanian","ro-MD":"Romanian (Moldova)",rof:"Rombo",rom:"Romany",rtm:"Rotuman",ru:"Russian",rue:"Rusyn",rug:"Roviana",rup:"Aromanian",rw:"Kinyarwanda",rwk:"Rwa",sa:"Sanskrit",sad:"Sandawe",sah:"Yakut",sam:"Samaritan Aramaic",saq:"Samburu",sas:"Sasak",sat:"Santali",saz:"Saurashtra",sba:"Ngambay",sbp:"Sangu",sc:"Sardinian",scn:"Sicilian",sco:"Scots",sd:"Sindhi",sdc:"Sassarese Sardinian",sdh:"Southern Kurdish",se:"Northern Sami",see:"Seneca",seh:"Sena",sei:"Seri",sel:"Selkup",ses:"Koyraboro Senni",sg:"Sango",sga:"Old Irish",sgs:"Samogitian",sh:"Serbo-Croatian",shi:"Tachelhit",shn:"Shan",shu:"Chadian Arabic",si:"Sinhala",sid:"Sidamo",sk:"Slovak",sl:"Slovenian",slh:"Southern Lushootseed",sli:"Lower Silesian",sly:"Selayar",sm:"Samoan",sma:"Southern Sami",smj:"Lule Sami",smn:"Inari Sami",sms:"Skolt Sami",sn:"Shona",snk:"Soninke",so:"Somali",sog:"Sogdien",sq:"Albanian",sr:"Serbian","sr-ME":"Serbian (Montenegro)",srn:"Sranan Tongo",srr:"Serer",ss:"Swati",ssy:"Saho",st:"Southern Sotho",stq:"Saterland Frisian",str:"Straits Salish",su:"Sundanese",suk:"Sukuma",sus:"Susu",sux:"Sumerian",sv:"Swedish",sw:"Swahili","sw-CD":"Swahili (Congo - Kinshasa)",swb:"Comorian",syc:"Classical Syriac",syr:"Syriac",szl:"Silesian",ta:"Tamil",tce:"Southern Tutchone",tcy:"Tulu",te:"Telugu",tem:"Timne",teo:"Teso",ter:"Tereno",tet:"Tetum",tg:"Tajik",tgx:"Tagish",th:"Thai",tht:"Tahltan",ti:"Tigrinya",tig:"Tigre",tiv:"Tiv",tk:"Turkmen",tkl:"Tokelau",tkr:"Tsakhur",tl:"Tagalog",tlh:"Klingon",tli:"Tlingit",tly:"Talysh",tmh:"Tamashek",tn:"Tswana",to:"Tongan",tog:"Nyasa Tonga",tok:"Toki Pona",tpi:"Tok Pisin",tr:"Turkish",tru:"Turoyo",trv:"Taroko",trw:"Torwali",ts:"Tsonga",tsd:"Tsakonian",tsi:"Tsimshian",tt:"Tatar",ttm:"Northern Tutchone",ttt:"Muslim Tat",tum:"Tumbuka",tvl:"Tuvalu",tw:"Twi",twq:"Tasawaq",ty:"Tahitian",tyv:"Tuvinian",tzm:"Central Atlas Tamazight",udm:"Udmurt",ug:"Uyghur",uga:"Ugaritic",uk:"Ukrainian",umb:"Umbundu",und:"Unknown language",ur:"Urdu",uz:"Uzbek",vai:"Vai",ve:"Venda",vec:"Venetian",vep:"Veps",vi:"Vietnamese",vls:"West Flemish",vmf:"Main-Franconian",vmw:"Makhuwa",vo:"Volapük",vot:"Votic",vro:"Võro",vun:"Vunjo",wa:"Walloon",wae:"Walser",wal:"Wolaytta",war:"Waray",was:"Washo",wbp:"Warlpiri",wo:"Wolof",wuu:"Wu Chinese",xal:"Kalmyk",xh:"Xhosa",xmf:"Mingrelian",xnr:"Kangri",xog:"Soga",yao:"Yao",yap:"Yapese",yav:"Yangben",ybb:"Yemba",yi:"Yiddish",yo:"Yoruba",yrl:"Nheengatu",yue:"Cantonese",za:"Zhuang",zap:"Zapotec",zbl:"Blissymbols",zea:"Zeelandic",zen:"Zenaga",zgh:"Standard Moroccan Tamazight",zh:"Chinese","zh-Hans":"Simplified Chinese","zh-Hant":"Traditional Chinese",zu:"Zulu",zun:"Zuni",zxx:"No linguistic content",zza:"Zaza"}}},region:{long:h(h(h(h(h(h(h(h({"001":"world","002":"Africa","003":"North America","005":"South America","009":"Oceania","011":"Western Africa","013":"Central America","014":"Eastern Africa","015":"Northern Africa","017":"Middle Africa","018":"Southern Africa","019":"Americas","021":"Northern America","029":"Caribbean","030":"Eastern Asia","034":"Southern Asia","035":"Southeast Asia","039":"Southern Europe","053":"Australasia","054":"Melanesia","057":"Micronesian Region","061":"Polynesia",142:"Asia",143:"Central Asia",145:"Western Asia",150:"Europe",151:"Eastern Europe",154:"Northern Europe",155:"Western Europe",202:"Sub-Saharan Africa",419:"Latin America",AC:"Ascension Island",AD:"Andorra",AE:"United Arab Emirates",AF:"Afghanistan",AG:"Antigua & Barbuda",AI:"Anguilla",AL:"Albania",AM:"Armenia",AO:"Angola",AQ:"Antarctica",AR:"Argentina",AS:"American Samoa",AT:"Austria",AU:"Australia",AW:"Aruba",AX:"Åland Islands",AZ:"Azerbaijan",BA:"Bosnia & Herzegovina",BB:"Barbados",BD:"Bangladesh",BE:"Belgium",BF:"Burkina Faso",BG:"Bulgaria",BH:"Bahrain",BI:"Burundi",BJ:"Benin",BL:"St. Barthélemy",BM:"Bermuda",BN:"Brunei",BO:"Bolivia",BQ:"Caribbean Netherlands",BR:"Brazil",BS:"Bahamas",BT:"Bhutan",BV:"Bouvet Island",BW:"Botswana",BY:"Belarus",BZ:"Belize",CA:"Canada",CC:"Cocos (Keeling) Islands",CD:"Congo - Kinshasa",CF:"Central African Republic",CG:"Congo - Brazzaville",CH:"Switzerland",CI:"Côte d’Ivoire",CK:"Cook Islands",CL:"Chile",CM:"Cameroon",CN:"China",CO:"Colombia",CP:"Clipperton Island",CQ:"Sark",CR:"Costa Rica",CU:"Cuba",CV:"Cape Verde",CW:"Curaçao",CX:"Christmas Island",CY:"Cyprus",CZ:"Czechia",DE:"Germany",DG:"Diego Garcia",DJ:"Djibouti",DK:"Denmark",DM:"Dominica",DO:"Dominican Republic",DZ:"Algeria",EA:"Ceuta & Melilla",EC:"Ecuador",EE:"Estonia",EG:"Egypt",EH:"Western Sahara",ER:"Eritrea",ES:"Spain",ET:"Ethiopia",EU:"European Union",EZ:"Eurozone",FI:"Finland",FJ:"Fiji",FK:"Falkland Islands",FM:"Micronesia",FO:"Faroe Islands",FR:"France",GA:"Gabon",GB:"United Kingdom",GD:"Grenada",GE:"Georgia",GF:"French Guiana",GG:"Guernsey",GH:"Ghana",GI:"Gibraltar",GL:"Greenland",GM:"Gambia",GN:"Guinea",GP:"Guadeloupe",GQ:"Equatorial Guinea",GR:"Greece",GS:"South Georgia & South Sandwich Islands",GT:"Guatemala",GU:"Guam",GW:"Guinea-Bissau",GY:"Guyana",HK:"Hong Kong SAR China",HM:"Heard & McDonald Islands",HN:"Honduras",HR:"Croatia",HT:"Haiti",HU:"Hungary",IC:"Canary Islands",ID:"Indonesia",IE:"Ireland",IL:"Israel",IM:"Isle of Man",IN:"India",IO:"British Indian Ocean Territory",IQ:"Iraq",IR:"Iran",IS:"Iceland",IT:"Italy",JE:"Jersey",JM:"Jamaica",JO:"Jordan",JP:"Japan",KE:"Kenya",KG:"Kyrgyzstan",KH:"Cambodia",KI:"Kiribati",KM:"Comoros",KN:"St. Kitts & Nevis",KP:"North Korea",KR:"South Korea",KW:"Kuwait",KY:"Cayman Islands",KZ:"Kazakhstan",LA:"Laos",LB:"Lebanon",LC:"St. Lucia",LI:"Liechtenstein",LK:"Sri Lanka",LR:"Liberia",LS:"Lesotho",LT:"Lithuania",LU:"Luxembourg",LV:"Latvia",LY:"Libya",MA:"Morocco",MC:"Monaco",MD:"Moldova",ME:"Montenegro",MF:"St. Martin",MG:"Madagascar",MH:"Marshall Islands",MK:"North Macedonia",ML:"Mali",MM:"Myanmar (Burma)",MN:"Mongolia",MO:"Macao SAR China",MP:"Northern Mariana Islands",MQ:"Martinique",MR:"Mauritania",MS:"Montserrat",MT:"Malta",MU:"Mauritius",MV:"Maldives",MW:"Malawi",MX:"Mexico",MY:"Malaysia",MZ:"Mozambique",NA:"Namibia",NC:"New Caledonia",NE:"Niger",NF:"Norfolk Island",NG:"Nigeria",NI:"Nicaragua",NL:"Netherlands",NO:"Norway",NP:"Nepal",NR:"Nauru",NU:"Niue",NZ:"New Zealand",OM:"Oman",PA:"Panama",PE:"Peru",PF:"French Polynesia",PG:"Papua New Guinea",PH:"Philippines",PK:"Pakistan",PL:"Poland",PM:"St. Pierre & Miquelon",PN:"Pitcairn Islands",PR:"Puerto Rico",PS:"Palestinian Territories",PT:"Portugal",PW:"Palau",PY:"Paraguay",QA:"Qatar",QO:"Outlying Oceania",RE:"Réunion",RO:"Romania",RS:"Serbia",RU:"Russia",RW:"Rwanda",SA:"Saudi Arabia",SB:"Solomon Islands",SC:"Seychelles",SD:"Sudan",SE:"Sweden",SG:"Singapore",SH:"St. Helena",SI:"Slovenia",SJ:"Svalbard & Jan Mayen",SK:"Slovakia",SL:"Sierra Leone",SM:"San Marino",SN:"Senegal",SO:"Somalia",SR:"Suriname",SS:"South Sudan",ST:"São Tomé & Príncipe",SV:"El Salvador",SX:"Sint Maarten",SY:"Syria",SZ:"Eswatini",TA:"Tristan da Cunha",TC:"Turks & Caicos Islands",TD:"Chad",TF:"French Southern Territories",TG:"Togo",TH:"Thailand",TJ:"Tajikistan",TK:"Tokelau",TL:"Timor-Leste",TM:"Turkmenistan",TN:"Tunisia",TO:"Tonga",TR:"Türkiye",TT:"Trinidad & Tobago",TV:"Tuvalu",TW:"Taiwan",TZ:"Tanzania",UA:"Ukraine",UG:"Uganda",UM:"U.S. Outlying Islands",UN:"United Nations",US:"United States",UY:"Uruguay",UZ:"Uzbekistan",VA:"Vatican City",VC:"St. Vincent & Grenadines",VE:"Venezuela",VG:"British Virgin Islands",VI:"U.S. Virgin Islands",VN:"Vietnam",VU:"Vanuatu",WF:"Wallis & Futuna",WS:"Samoa",XA:"Pseudo-Accents",XB:"Pseudo-Bidi",XK:"Kosovo",YE:"Yemen",YT:"Mayotte",ZA:"South Africa",ZM:"Zambia",ZW:"Zimbabwe",ZZ:"Unknown Region"},"BA","Bosnia"),"GB","UK"),"HK","Hong Kong"),"MM","Myanmar"),"MO","Macao"),"PS","Palestine"),"UN","UN"),"US","US")}},eo=["af","sq","am","ar","hy","as","az","eu","be","bn","bs","bg","my","ca","zh-CN","zh-TW","zh-HK","hr","cs","da","nl","en","et","fil","fi","fr","gl","ka","de","el","gu","he","hi","hu","is","id","ga","it","ja","kn","kk","km","ko","ky","lo","lv","lt","mk","ms","ml","mt","mr","mn","ne","no","or","fa","pl","pt","pa","ro","ru","sr","si","sk","sl","es","sw","sv","ta","te","th","tr","uk","ur","uz","vi","cy","yi","yo","zu"];var to=!1;function no(e,t){return{compactLinkRenderer:{title:{simpleText:t},serviceEndpoint:{commandExecutorCommand:{commands:[{selectSubtitlesTrackCommand:{translationLanguage:{languageCode:e,languageName:t}}},{openClientOverlayAction:{type:"CLIENT_OVERLAY_TYPE_CAPTIONS_LANGUAGE",updateAction:!0}},{signalAction:{signal:"POPUP_BACK"}}]}},secondaryIcon:{iconType:"RADIO_BUTTON_UNCHECKED"}}}}function io(){if(to)return!0;if(!document.querySelector(".html5-video-player")||!window._yttv)return!1;var e=Object.values(window._yttv).find(function(e){return e&&e.instance&&"function"==typeof e.instance.resolveCommand});if(!e)return!1;if(e.instance.resolveCommand.isPatchedBySubtitleLocalization)return to=!0,!0;var t=e.instance.resolveCommand;return e.instance.resolveCommand=function(e,n){var i;if("CLIENT_OVERLAY_TYPE_CAPTIONS_AUTO_TRANSLATE"===(null==e||null===(i=e.openPopupAction)||void 0===i?void 0:i.uniqueId)){var r,a=me("enableShowUserLanguage"),o=me("enableShowOtherLanguages");if(!a&&!o)return t.apply(this,arguments);var s=null===(r=e.openPopupAction)||void 0===r||null===(r=r.popup)||void 0===r||null===(r=r.overlaySectionRenderer)||void 0===r||null===(r=r.overlay)||void 0===r||null===(r=r.overlayTwoPanelRenderer)||void 0===r||null===(r=r.actionPanel)||void 0===r||null===(r=r.overlayPanelRenderer)||void 0===r||null===(r=r.content)||void 0===r||null===(r=r.overlayPanelItemListRenderer)||void 0===r?void 0:r.items;if(!Array.isArray(s))return t.apply(this,arguments);var u=function(e){var t=new Set;return e.forEach(function(e){var n,i,r=null===(n=e.compactLinkRenderer)||void 0===n||null===(n=n.serviceEndpoint)||void 0===n||null===(n=n.commandExecutorCommand)||void 0===n?void 0:n.commands,a=null==r||null===(i=r[0])||void 0===i||null===(i=i.selectSubtitlesTrackCommand)||void 0===i?void 0:i.translationLanguage;a&&(t.add(a.languageCode),t.add(a.languageName))}),t}(s);if(a){var l=function(e){if(!e)return null;try{var t=String(e).toUpperCase(),n={CN:"zh-CN",TW:"zh-TW",HK:"zh-HK",SG:"zh-CN"};if(n[t]){var i=n[t];return{code:i,name:$a.language.standard.long[i]||i}}var r=new Intl.Locale("und",{region:t}),a=(r.maximize?r.maximize():r).language||"en";return{code:a,name:$a.language.standard.long[a]||a}}catch(t){return console.warn("[AxoTube:moreSubtitles] Could not infer language for country",e,t),null}}(function(){try{return window.yt&&window.yt.config_&&window.yt.config_.GL?window.yt.config_.GL:(console.warn("[AxoTube:moreSubtitles] Could not determine user country code"),null)}catch(e){return console.error("[AxoTube:moreSubtitles] Error getting country code:",e),null}}());if(l&&!function(e,t,n){return e.some(function(e){var i,r,a=null===(i=e.compactLinkRenderer)||void 0===i||null===(i=i.serviceEndpoint)||void 0===i||null===(i=i.commandExecutorCommand)||void 0===i?void 0:i.commands,o=null==a||null===(r=a[0])||void 0===r||null===(r=r.selectSubtitlesTrackCommand)||void 0===r?void 0:r.translationLanguage;return!(!o||o.languageCode!==t&&o.languageName!==n)})}(s,l.code,l.name)){var c=no(l.code,l.name),h=s.findIndex(function(e){var t;return"Recommended languages"===(null===(t=e.overlayMessageRenderer)||void 0===t||null===(t=t.subtitle)||void 0===t?void 0:t.simpleText)});if(h>-1)s.splice(h+1,0,c);else{var d=s.findIndex(function(e){var t;return"Other languages"===(null===(t=e.overlayMessageRenderer)||void 0===t||null===(t=t.subtitle)||void 0===t?void 0:t.simpleText)});d>-1?s.splice(d,0,c):s.unshift(c)}u.add(l.code),u.add(l.name)}}if(o){var p=Object.entries(function(){try{var e={};return eo.forEach(function(t){if(t.includes("-")){var n=y(t.split("-"),2),i=n[0],r=n[1],a=$a.language.standard.long[i]||t,o=$a.region.long[r]||r;e[t]="".concat(a," (").concat(o,")")}else e[t]=$a.language.standard.long[t]||t}),e}catch(e){var t={};return eo.forEach(function(e){return t[e]=e}),t}}()).filter(function(e){var t=y(e,2),n=t[0],i=t[1];return!u.has(n)&&!u.has(i)}).sort(function(e,t){var n=y(e,2)[1],i=y(t,2)[1];return n.localeCompare(i)});p.length>0&&(s.push({overlayMessageRenderer:{title:{simpleText:""},subtitle:{simpleText:"Other Languages"},style:"OVERLAY_MESSAGE_STYLE_SUBSECTION_TITLE"}}),p.forEach(function(e){var t=y(e,2),n=t[0],i=t[1];return s.push(no(n,i))}))}}return t.apply(this,arguments)},e.instance.resolveCommand.isPatchedBySubtitleLocalization=!0,to=!0,!0}var ro=0;function ao(){to||(ro+=1,io()||(ro>=30?console.warn("[AxoTube:moreSubtitles] resolveCommand did not become ready in time."):setTimeout(ao,500)))}"loading"===document.readyState?document.addEventListener("DOMContentLoaded",ao):ao();var oo=!1,so=null;function uo(){var e=document.querySelector("video");return e&&isFinite(e.currentTime)?Math.max(0,Math.floor(e.currentTime)):0}function lo(){var e,t;oo||(oo=!0,st(je("app.name"),je("playback.retryPrompt",{time:(e=uo(),t=e%60,Math.floor(e/60)+":"+(t<10?"0"+t:String(t)))}),null))}function co(){var e;so=null,(e=document.querySelector(".ytp-error"))&&e.offsetWidth>0&&e.offsetHeight>0?lo():oo=!1}function ho(){null===so&&(so=setTimeout(co,500))}document.addEventListener("error",function(e){e.target&&"VIDEO"===e.target.tagName&&lo()},!0),window.addEventListener("keydown",function(e){406===e.keyCode&&oo&&(e.stopPropagation(),function(){oo=!1;var e=function(e,t){var n=e.indexOf("?");if(-1===n||!/\/watch$/.test(e.slice(0,n)))return null;var i=e.slice(n+1).split("&").filter(function(e){return e&&"t"!==e.split("=")[0]});return i.push("t="+t),e.slice(0,n+1)+i.join("&")}(location.hash,uo());e&&(location.hash=e),window.location.reload()}())},!0),function e(){document.body?new MutationObserver(ho).observe(document.body,{childList:!0,subtree:!0}):setTimeout(e,200)}();var po;po||(po=1,window.addEventListener("keydown",function(e){if(403===e.keyCode){var t=window.__axotubeProxyUrl?window.__axotubeProxyUrl:"8081"===location.port?location.protocol+"//"+location.hostname+":8081":null;t&&(e.stopPropagation(),location.href=t+"/axotube/diagnostics")}},!0));var fo="onStateChange",mo="configChange",yo="preferredVideoQuality",go=new WeakMap,vo=new WeakMap,bo=new WeakMap,xo=new WeakMap,Eo=new WeakMap,So=new WeakSet,wo=new WeakMap,Do=l(function e(){var t,u,l=this;r(this,e),i(t=this,u=So),u.add(t),o(this,go,null),o(this,vo,null),o(this,bo,0),o(this,xo,null),o(this,Eo,!1),o(this,wo,function(){try{var e,t,i,r,o,u,c=null===(e=a(go,l))||void 0===e||null===(t=e.getPlayerStateObject)||void 0===t?void 0:t.call(e),h=null===(i=a(go,l))||void 0===i||null===(r=i.getVideoData)||void 0===r?void 0:r.call(i),d=null==h?void 0:h.video_id;d!==a(xo,l)&&(s(xo,l,d),n(So,l,ko).call(l));var p=Object.values((null===(o=a(go,l))||void 0===o||null===(u=o.getVideoStats)||void 0===u?void 0:u.call(o))||{}).find(function(e){return e&&"shortspage"===e});null==c||!c.isPlaying||a(Eo,l)||p||(s(Eo,l,n(So,l,Po).call(l)),a(Eo,l)||n(So,l,Fo).call(l))}catch(e){console.warn("[AxoTube:preferredVideoQuality] State change handler failed:",e)}}),n(So,this,To).call(this),Hn(function(e){return n(So,l,Co).call(l,e)}),Gn(function(e){e!==a(xo,l)&&(s(xo,l,e),n(So,l,ko).call(l),a(wo,l).call(l))})});function Ao(){a(vo,this)&&(clearTimeout(a(vo,this)),s(vo,this,null))}function ko(){n(So,this,Ao).call(this),s(bo,this,0),s(Eo,this,!1)}function Co(e){if(!e){if(a(go,this))try{a(go,this).removeEventListener(fo,a(wo,this))}catch(e){}return s(go,this,null),s(xo,this,null),void n(So,this,ko).call(this)}if(e!==a(go,this)){if(a(go,this))try{a(go,this).removeEventListener(fo,a(wo,this))}catch(e){}s(go,this,e),s(xo,this,null),n(So,this,ko).call(this);try{a(go,this).addEventListener(fo,a(wo,this))}catch(e){console.warn("[AxoTube:preferredVideoQuality] Could not attach state change listener:",e)}a(wo,this).call(this)}}function To(){var e=this;ge.addEventListener(mo,function(t){var i;(null===(i=t.detail)||void 0===i?void 0:i.key)===yo&&(n(So,e,ko).call(e),s(Eo,e,n(So,e,Po).call(e)),a(Eo,e)||n(So,e,Fo).call(e))})}function Fo(){var e=this;a(vo,this)||a(Eo,this)||a(bo,this)>=10||(s(bo,this,a(bo,this)+1),s(vo,this,setTimeout(function(){s(vo,e,null);try{var t,i,r=null===(t=a(go,e))||void 0===t||null===(i=t.getPlayerStateObject)||void 0===i?void 0:i.call(t);if(null==r||!r.isPlaying||a(go,e)!==Rn())return;s(Eo,e,n(So,e,Po).call(e)),a(Eo,e)||n(So,e,Fo).call(e)}catch(e){console.warn("[AxoTube:preferredVideoQuality] Retry failed:",e)}},500)))}function Po(){if(!a(go,this)||"function"!=typeof a(go,this).setPlaybackQualityRange)return!1;var e=me(yo);try{if(!e||"auto"===e)return a(go,this).setPlaybackQualityRange("auto","auto"),!0;var t=n(So,this,Bo).call(this,e);return!!t&&(a(go,this).setPlaybackQualityRange(t,t),!0)}catch(e){return console.warn("[AxoTube:preferredVideoQuality] Failed to apply quality:",e),!1}}function Bo(e){try{var t,n,i,r=null===(t=(n=a(go,this)).getAvailableQualityData)||void 0===t?void 0:t.call(n);if(!Array.isArray(r)||0===r.length)return null;var o=function(e){return parseInt(e,10)||0},s=o(e),u=r.find(function(e){return o(e.qualityLabel)===s});return u?u.quality:(null===(i=r.slice().sort(function(e,t){var n=o(e.qualityLabel),i=o(t.qualityLabel),r=n>s?1:0,a=i>s?1:0;return r!==a?r-a:Math.abs(n-s)-Math.abs(i-s)})[0])||void 0===i?void 0:i.quality)||null}catch(e){return console.warn("[AxoTube:preferredVideoQuality] Quality determination failed:",e),null}}try{window.preferredVideoQualityHandler=new Do}catch(e){console.error("[AxoTube:preferredVideoQuality] PreferredQualityHandler initialization failed:",e)}function Io(e){return e&&e.tileRenderer&&e.tileRenderer.contentId}function No(e){var t=window.queuedVideos.videos[e],n=t&&t.tileRenderer&&t.tileRenderer.onSelectCommand;return!!n&&(window.queuedVideos.currentIndex=e,window.queuedVideos.lastVideoId=Io(t)||null,setTimeout(function(){return Na(n)},500),!0)}function Mo(){window.queuedVideos.currentIndex=-1,window.queuedVideos.lastVideoId=null,Na({customAction:{action:"CLEAR_QUEUE"}})}window.queuedVideos={videos:[],lastVideoId:null,currentIndex:-1};var Ro=null;Hn(function(e){if(Ro&&(Ro.player.removeEventListener("onStateChange",Ro.listener),Ro=null),e&&"function"==typeof e.addEventListener){var t=function(){return function(e){var t=e.getPlayerStateObject(),n=e.getVideoData(),i=window.queuedVideos;if(0===i.videos.length)return i.currentIndex=-1,void(i.lastVideoId=null);if(t.isEnded){var r=i.currentIndex;if((r<0||r>=i.videos.length)&&(r=i.videos.findIndex(function(e){return Io(e)===n.video_id})),-1!==r){var a=r+1;if(a<i.videos.length&&No(a))return;return void Mo()}if(i.currentIndex+1<i.videos.length&&No(i.currentIndex+1))return;if(No(0))return;Mo()}else if(t.isPlaying){var o=document.getElementById("container");if(o&&o.style.setProperty("opacity","1","important"),Io(i.videos[i.currentIndex])===n.video_id)return void(i.lastVideoId=n.video_id);var s=i.videos.findIndex(function(e){return Io(e)===n.video_id});-1!==s&&(i.currentIndex=s,i.lastVideoId=n.video_id)}}(e)};e.addEventListener("onStateChange",t),Ro={player:e,listener:t}}});var Lo=null,Oo=0;function _o(){Oo>=20||(Oo+=1,Lo=setTimeout(function(){return Uo(!1)},500))}function Uo(){if(arguments.length>0&&void 0!==arguments[0]&&arguments[0]&&(Oo=0),Lo&&(clearTimeout(Lo),Lo=null),window._yttv){var e=null;try{e=Object.values(window._yttv).find(function(e){return e instanceof Map&&e.has("ENABLE_PREVIEWS_WITH_SOUND")})}catch(t){e=null}e?(Oo=0,e.set("ENABLE_PREVIEWS_WITH_SOUND",ke())):_o()}else _o()}ge.addEventListener("configChange",function(){Uo(!0)}),"complete"===document.readyState?Uo(!0):window.addEventListener("load",function(){return Uo(!0)});var jo="http://127.0.0.1:8090",Ho=-1,zo=!1,Go=!1,Ko=!1,Xo=null,Vo=new Set,Wo=!1,Jo="",qo=null,Yo=!1,Qo=!1,Zo=null,$o=!1;function es(){return"undefined"!=typeof window&&("string"==typeof window.__axotubeServiceUrl||!!te()||void 0!==window.tizen)}var ts=Ze,ns=tt;function is(){return Jt("".concat(jo,"/api/pairing-code")).then(function(e){if(!e.ok)throw new Error("pairing code HTTP ".concat(e.status));return e.json()}).then(function(e){return or(e),e}).catch(function(){return or(null),null})}function rs(){!Qo&&ts()&&is().then(function(e){if(e&&e.code&&!Qo){Qo=!0;try{var t=Array.isArray(e.urls)&&e.urls.length?e.urls[0]:null;st(je("app.name"),t?je("toasts.pairingWithUrl",{url:t,code:e.code}):je("toasts.pairingCodeOnly",{code:e.code}))}catch(e){}}})}function as(e,t){if(e===t)return!0;try{return le(e)===le(t)}catch(e){return!1}}function os(e){if(!Xo)return!1;var t=Object.keys(e),n=Object.keys(Xo);return t.length!==n.length||t.some(function(t){return!Object.prototype.hasOwnProperty.call(Xo,t)||!as(e[t],Xo[t])})}function ss(){if(!(!es()||zo||Ho<0)&&Xo){var e=ve();os(e)?(zo=!0,Jt("".concat(jo,"/api/config/push"),{method:"POST",headers:{"Content-Type":"application/json"},body:le({revision:Ho,config:e})}).then(function(e){if(409===e.status)return{conflict:!0};if(!e.ok)throw new Error("config push HTTP ".concat(e.status));return e.json()}).then(function(t){if(null!=t&&t.conflict)return"conflict";if(!t||!t.applied||!Number.isSafeInteger(t.revision))throw new Error("Config push was not acknowledged");Ho=t.revision,Xo=e;var n,i=ve(),r=c(Vo);try{for(r.s();!(n=r.n()).done;){var a=n.value;as(i[a],e[a])&&Vo.delete(a)}}catch(e){r.e(e)}finally{r.f()}return"accepted"}).catch(function(){return"failed"}).then(function(e){zo=!1,"conflict"===e?ls():"accepted"===e&&os(ve())&&us()})):Vo.clear()}}function us(){es()&&(clearTimeout(qo),qo=setTimeout(ss,250))}function ls(){es()&&!zo&&(zo=!0,Jt("".concat(jo,"/api/config")).then(function(e){if(!e.ok)throw new Error("config pull HTTP ".concat(e.status));return e.json()}).then(function(e){if(e&&Number.isSafeInteger(e.revision)&&!(e.revision<0)&&e.config&&"object"===b(e.config)&&!Array.isArray(e.config)){!function(){if(!Yo&&es()&&ts())try{st(je("app.name"),je("toasts.serviceConnected")),Yo=!0,setTimeout(rs,1200)}catch(e){}}(),ds=0;var t=e.config;Wo=!0;var n=!0;try{Object.keys(t).forEach(function(e){if(!Vo.has(e)&&void 0!==t[e])try{as(me(e),t[e])||ye(e,t[e])||(n=!1)}catch(e){n=!1}})}finally{Wo=!1}var i=ve();Object.keys(i).forEach(function(e){Object.prototype.hasOwnProperty.call(t,e)?as(i[e],t[e])&&Vo.delete(e):Vo.add(e)}),Xo=t,n&&(Ho=e.revision)}}).catch(function(){ds+=1}).then(function(){zo=!1,ss()}))}function cs(e){return function(e){return e?Jt("".concat(jo,"/api/command/ack"),{method:"POST",headers:{"Content-Type":"application/json"},body:le({id:e})}).then(function(e){if(!e.ok)throw new Error("command ACK HTTP ".concat(e.status));return!0}).catch(function(){return!1}):Promise.resolve(!1)}(e).then(function(t){if(!t||Zo!==e)return t;var n=$o;if(Zo=null,$o=!1,n)try{window.location.reload()}catch(e){}return!0})}function hs(){es()&&!Go&&(Go=!0,Jt("".concat(jo,"/api/command")).then(function(e){if(!e.ok)throw new Error("command poll HTTP ".concat(e.status));return e.json()}).then(function(e){if(e&&e.command&&e.id){var t=e.id;if(e.id===Zo)return cs(t);if("toast"===e.command.action){Zo=t,$o=!1;try{st(je("app.name"),String(e.command.text||"").slice(0,200))}catch(e){}return cs(t)}if("reload"===e.command.action)return Zo=t,$o=!0,cs(t);var n=function(e){if(!e||"object"!==b(e))return null;if("play"===e.action&&e.videoId){var t={videoId:e.videoId};return e.playlistId&&(t.playlistId=e.playlistId),{watchEndpoint:t}}return"search"===e.action&&e.query?{searchEndpoint:{query:e.query}}:"browse"===e.action&&e.browseId?{browseEndpoint:{browseId:e.browseId}}:null}(e.command);if(n)return ns(n).then(function(e){if(e){Zo=t,$o=!1;try{st(je("app.name"),je("toasts.commandReceived"))}catch(e){}return cs(t)}})}}).catch(function(){}).then(function(){Go=!1}))}ge.addEventListener("configChange",function(e){var t;Wo||("string"==typeof(null==e||null===(t=e.detail)||void 0===t?void 0:t.key)&&Vo.add(e.detail.key),us())});var ds=0;setTimeout(function e(){ls(),hs(),function(){if(es()&&!Ko){var e=null;try{var t=document.querySelector("video");if(t&&t.currentSrc){var n,i=location.hash.match(/[?&]v=([^&]+)/);e={videoId:i?i[1]:null,title:(null===(n=document.querySelector("ytlr-player-header-title"))||void 0===n?void 0:n.textContent)||document.title,state:t.paused?"paused":"playing",progress:t.currentTime,duration:t.duration}}}catch(e){return}var r=e?le(e):"none";r!==Jo&&(Jo=r,Ko=!0,Jt("".concat(jo,"/api/nowplaying"),{method:"POST",headers:{"Content-Type":"application/json"},body:"none"===r?"{}":r}).then(function(e){if(!e.ok)throw new Error("now playing HTTP ".concat(e.status))}).catch(function(){Jo=""}).then(function(){Ko=!1}))}}(),es()&&(ar?Date.now()-ar:1/0)>6e4&&is(),setTimeout(e,function(){if(0===ds)return 5e3;var e=5e3*Math.pow(2,Math.min(ds,3));return Math.min(e,3e4)}())},3e3);try{tt(function(e){if(!e||"object"!==b(e))return null;if(e.v){var t={videoId:e.v};return e.list&&(t.playlistId=e.list),{watchEndpoint:t}}if(e.list)return{playlistEndpoint:{playlistId:e.list}};var n=e.search_query||e.q;return n?{searchEndpoint:{query:n}}:e.browseId?{browseEndpoint:{browseId:e.browseId}}:null}(function(e){if(!e||e.length<=1)return{};for(var t={},n=e.substring(1).split("&"),i=0;i<n.length;i+=1){var r=n[i];if(r){var a=r.indexOf("=");if(-1!==a){var o=decodeURIComponent(r.substring(0,a).replace(/\+/g," ")),s=decodeURIComponent(r.substring(a+1).replace(/\+/g," "));t[o]=s}else t[decodeURIComponent(r.replace(/\+/g," "))]=""}}return t}(location.search)))}catch(e){}function ps(e){return e<10?"0"+e:String(e)}var fs="axo-clock",ms="axo-clock-style",ys={topLeft:"axo-clock-top-left",topRight:"axo-clock-top-right",bottomLeft:"axo-clock-bottom-left",bottomRight:"axo-clock-bottom-right"},gs="\n#".concat(fs,' {\n position: fixed;\n z-index: 9000;\n pointer-events: none;\n padding: 3vh 3vw;\n font-family: "YouTube Sans", Roboto, "Noto Sans", Arial, sans-serif;\n font-size: 4vh;\n line-height: 1;\n font-variant-numeric: tabular-nums;\n color: rgba(255, 255, 255, 0.92);\n text-shadow: 0 1px 4px rgba(0, 0, 0, 0.85);\n}\n#').concat(fs,".axo-clock-top-left { top: 0; left: 0; }\n#").concat(fs,".axo-clock-top-right { top: 0; right: 0; }\n#").concat(fs,".axo-clock-bottom-left { bottom: 0; left: 0; }\n#").concat(fs,".axo-clock-bottom-right { bottom: 0; right: 0; }\n"),vs=null,bs=null;function xs(){var e=me("clockMode");return"always"===e||"notPlaying"===e&&!function(){var e=Ln();return!(!e||e.paused||e.ended)}()}function Es(){null!==bs&&clearInterval(bs),bs=null,vs&&vs.parentNode&&vs.parentNode.removeChild(vs),vs=null}function Ss(){vs||((vs=document.createElement("div")).id=fs,document.body.appendChild(vs));var e=ys[me("clockPosition")]||ys.topRight;vs.className!==e&&(vs.className=e);var t=function(e,t,n){var i=ps(e.getMinutes()),r=n?":"+ps(e.getSeconds()):"",a=e.getHours();if("24h"===t)return ps(a)+":"+i+r;var o=String(a%12==0?12:a%12)+":"+i+r;return"12hNoAmPm"===t?o:o+(a<12?" AM":" PM")}(new Date,me("clockFormat"),!!me("clockShowSeconds"));vs.textContent!==t&&(vs.textContent=t)}function ws(){document.body&&(xs()?(!function(){if(!document.getElementById(ms)){var e=document.createElement("style");e.id=ms,e.textContent=gs,(document.head||document.documentElement).appendChild(e)}}(),Ss(),null===bs&&(bs=setInterval(Ss,1e3))):Es())}["play","playing","pause","ended","emptied"].forEach(function(e){document.addEventListener(e,ws,!0)}),ge.addEventListener("configChange",function(e){var t=e.detail&&e.detail.key;"clockMode"!==t&&"clockFormat"!==t&&"clockPosition"!==t&&"clockShowSeconds"!==t||ws()}),function e(){document.body?ws():setTimeout(e,250)}();var Ds="axo-panel-shrink",As="axo-panel-shrink-style",ks="\nbody.".concat(Ds," ytlr-player-container {\n transform: scale(var(--axo-panel-scale, 0.6));\n transform-origin: 0 0;\n transition: transform 0.25s ease;\n}\n");var Cs=null,Ts=null,Fs=null,Ps=null;function Bs(){if(Ps=null,document.body){var e=document.querySelector("ytlr-engagement-panel-section-list-renderer");!function(e){if(e===Fs)return;Ts&&Ts.disconnect();if(Ts=null,Fs=e,!e||"undefined"==typeof MutationObserver)return;(Ts=new MutationObserver(Is)).observe(e,{subtree:!0,attributes:!0,attributeFilter:["class"]})}(e),function(){if(!document.getElementById(As)){var e=document.createElement("style");e.id=As,e.textContent=ks,(document.head||document.documentElement).appendChild(e)}}();var t=!!me("enablePanelShrink")&&/#\/watch/.test(location.hash||"")&&function(e){if(!e)return!1;var t=e.querySelector("ytlr-animated-overlay");return!t||!t.classList.contains("frHKed")}(e);document.body.classList.contains(Ds)!==t&&document.body.classList.toggle(Ds,t);var n=String(Number(me("panelShrinkPercent"))/100);n!==Cs&&(Cs=n,document.documentElement.style.setProperty("--axo-panel-scale",n))}}function Is(){null===Ps&&(Ps=requestAnimationFrame(Bs))}!function e(){if(document.body){var t=document.getElementById("container")||document.body;"undefined"!=typeof MutationObserver&&new MutationObserver(Is).observe(t,{childList:!0,subtree:!0}),window.addEventListener("hashchange",Is),ge.addEventListener("configChange",function(e){var t=e.detail&&e.detail.key;"enablePanelShrink"!==t&&"panelShrinkPercent"!==t||Is()}),Bs()}else setTimeout(e,250)}();var Ns,Ms={exports:{}};var Rs,Ls,Os=(Ns||(Ns=1,Rs=function(){return function(e){var t={};function n(i){if(t[i])return t[i].exports;var r=t[i]={exports:{},id:i,loaded:!1};return e[i].call(r.exports,r,r.exports,n),r.loaded=!0,r.exports}return n.m=e,n.c=t,n.p="",n(0)}([function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var i=n(1),r=n(3),a=n(8),o=n(15);function s(e,t,n){var o=null,s=function(e,t){n&&n(e,t),o&&o.visit(e,t)},u="function"==typeof n?s:null,l=!1;if(t){l="boolean"==typeof t.comment&&t.comment;var c="boolean"==typeof t.attachComment&&t.attachComment;(l||c)&&((o=new i.CommentHandler).attach=c,t.comment=!0,u=s)}var h,d=!1;t&&"string"==typeof t.sourceType&&(d="module"===t.sourceType),h=t&&"boolean"==typeof t.jsx&&t.jsx?new r.JSXParser(e,t,u):new a.Parser(e,t,u);var p=d?h.parseModule():h.parseScript();return l&&o&&(p.comments=o.comments),h.config.tokens&&(p.tokens=h.tokens),h.config.tolerant&&(p.errors=h.errorHandler.errors),p}t.parse=s,t.parseModule=function(e,t,n){var i=t||{};return i.sourceType="module",s(e,i,n)},t.parseScript=function(e,t,n){var i=t||{};return i.sourceType="script",s(e,i,n)},t.tokenize=function(e,t,n){var i,r=new o.Tokenizer(e,t);i=[];try{for(;;){var a=r.getNextToken();if(!a)break;n&&(a=n(a)),i.push(a)}}catch(e){r.errorHandler.tolerate(e)}return r.errorHandler.tolerant&&(i.errors=r.errors()),i};var u=n(2);t.Syntax=u.Syntax,t.version="4.0.1"},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var i=n(2),r=function(){function e(){this.attach=!1,this.comments=[],this.stack=[],this.leading=[],this.trailing=[]}return e.prototype.insertInnerComments=function(e,t){if(e.type===i.Syntax.BlockStatement&&0===e.body.length){for(var n=[],r=this.leading.length-1;r>=0;--r){var a=this.leading[r];t.end.offset>=a.start&&(n.unshift(a.comment),this.leading.splice(r,1),this.trailing.splice(r,1))}n.length&&(e.innerComments=n)}},e.prototype.findTrailingComments=function(e){var t=[];if(this.trailing.length>0){for(var n=this.trailing.length-1;n>=0;--n){var i=this.trailing[n];i.start>=e.end.offset&&t.unshift(i.comment)}return this.trailing.length=0,t}var r=this.stack[this.stack.length-1];if(r&&r.node.trailingComments){var a=r.node.trailingComments[0];a&&a.range[0]>=e.end.offset&&(t=r.node.trailingComments,delete r.node.trailingComments)}return t},e.prototype.findLeadingComments=function(e){for(var t,n=[];this.stack.length>0&&(a=this.stack[this.stack.length-1])&&a.start>=e.start.offset;)t=a.node,this.stack.pop();if(t){for(var i=(t.leadingComments?t.leadingComments.length:0)-1;i>=0;--i){var r=t.leadingComments[i];r.range[1]<=e.start.offset&&(n.unshift(r),t.leadingComments.splice(i,1))}return t.leadingComments&&0===t.leadingComments.length&&delete t.leadingComments,n}for(i=this.leading.length-1;i>=0;--i){var a;(a=this.leading[i]).start<=e.start.offset&&(n.unshift(a.comment),this.leading.splice(i,1))}return n},e.prototype.visitNode=function(e,t){if(!(e.type===i.Syntax.Program&&e.body.length>0)){this.insertInnerComments(e,t);var n=this.findTrailingComments(t),r=this.findLeadingComments(t);r.length>0&&(e.leadingComments=r),n.length>0&&(e.trailingComments=n),this.stack.push({node:e,start:t.start.offset})}},e.prototype.visitComment=function(e,t){var n="L"===e.type[0]?"Line":"Block",i={type:n,value:e.value};if(e.range&&(i.range=e.range),e.loc&&(i.loc=e.loc),this.comments.push(i),this.attach){var r={comment:{type:n,value:e.value,range:[t.start.offset,t.end.offset]},start:t.start.offset};e.loc&&(r.comment.loc=e.loc),e.type=n,this.leading.push(r),this.trailing.push(r)}},e.prototype.visit=function(e,t){"LineComment"===e.type||"BlockComment"===e.type?this.visitComment(e,t):this.attach&&this.visitNode(e,t)},e}();t.CommentHandler=r},function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.Syntax={AssignmentExpression:"AssignmentExpression",AssignmentPattern:"AssignmentPattern",ArrayExpression:"ArrayExpression",ArrayPattern:"ArrayPattern",ArrowFunctionExpression:"ArrowFunctionExpression",AwaitExpression:"AwaitExpression",BlockStatement:"BlockStatement",BinaryExpression:"BinaryExpression",BreakStatement:"BreakStatement",CallExpression:"CallExpression",CatchClause:"CatchClause",ClassBody:"ClassBody",ClassDeclaration:"ClassDeclaration",ClassExpression:"ClassExpression",ConditionalExpression:"ConditionalExpression",ContinueStatement:"ContinueStatement",DoWhileStatement:"DoWhileStatement",DebuggerStatement:"DebuggerStatement",EmptyStatement:"EmptyStatement",ExportAllDeclaration:"ExportAllDeclaration",ExportDefaultDeclaration:"ExportDefaultDeclaration",ExportNamedDeclaration:"ExportNamedDeclaration",ExportSpecifier:"ExportSpecifier",ExpressionStatement:"ExpressionStatement",ForStatement:"ForStatement",ForOfStatement:"ForOfStatement",ForInStatement:"ForInStatement",FunctionDeclaration:"FunctionDeclaration",FunctionExpression:"FunctionExpression",Identifier:"Identifier",IfStatement:"IfStatement",ImportDeclaration:"ImportDeclaration",ImportDefaultSpecifier:"ImportDefaultSpecifier",ImportNamespaceSpecifier:"ImportNamespaceSpecifier",ImportSpecifier:"ImportSpecifier",Literal:"Literal",LabeledStatement:"LabeledStatement",LogicalExpression:"LogicalExpression",MemberExpression:"MemberExpression",MetaProperty:"MetaProperty",MethodDefinition:"MethodDefinition",NewExpression:"NewExpression",ObjectExpression:"ObjectExpression",ObjectPattern:"ObjectPattern",Program:"Program",Property:"Property",RestElement:"RestElement",ReturnStatement:"ReturnStatement",SequenceExpression:"SequenceExpression",SpreadElement:"SpreadElement",Super:"Super",SwitchCase:"SwitchCase",SwitchStatement:"SwitchStatement",TaggedTemplateExpression:"TaggedTemplateExpression",TemplateElement:"TemplateElement",TemplateLiteral:"TemplateLiteral",ThisExpression:"ThisExpression",ThrowStatement:"ThrowStatement",TryStatement:"TryStatement",UnaryExpression:"UnaryExpression",UpdateExpression:"UpdateExpression",VariableDeclaration:"VariableDeclaration",VariableDeclarator:"VariableDeclarator",WhileStatement:"WhileStatement",WithStatement:"WithStatement",YieldExpression:"YieldExpression"}},function(e,t,n){var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var a=n(4),o=n(5),s=n(6),u=n(7),l=n(8),c=n(13),h=n(14);function d(e){var t;switch(e.type){case s.JSXSyntax.JSXIdentifier:t=e.name;break;case s.JSXSyntax.JSXNamespacedName:var n=e;t=d(n.namespace)+":"+d(n.name);break;case s.JSXSyntax.JSXMemberExpression:var i=e;t=d(i.object)+"."+d(i.property)}return t}c.TokenName[100]="JSXIdentifier",c.TokenName[101]="JSXText";var p=function(e){function t(t,n,i){return e.call(this,t,n,i)||this}return r(t,e),t.prototype.parsePrimaryExpression=function(){return this.match("<")?this.parseJSXRoot():e.prototype.parsePrimaryExpression.call(this)},t.prototype.startJSX=function(){this.scanner.index=this.startMarker.index,this.scanner.lineNumber=this.startMarker.line,this.scanner.lineStart=this.startMarker.index-this.startMarker.column},t.prototype.finishJSX=function(){this.nextToken()},t.prototype.reenterJSX=function(){this.startJSX(),this.expectJSX("}"),this.config.tokens&&this.tokens.pop()},t.prototype.createJSXNode=function(){return this.collectComments(),{index:this.scanner.index,line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}},t.prototype.createJSXChildNode=function(){return{index:this.scanner.index,line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}},t.prototype.scanXHTMLEntity=function(e){for(var t="&",n=!0,i=!1,r=!1,o=!1;!this.scanner.eof()&&n&&!i;){var s=this.scanner.source[this.scanner.index];if(s===e)break;if(i=";"===s,t+=s,++this.scanner.index,!i)switch(t.length){case 2:r="#"===s;break;case 3:r&&(n=(o="x"===s)||a.Character.isDecimalDigit(s.charCodeAt(0)),r=r&&!o);break;default:n=(n=n&&!(r&&!a.Character.isDecimalDigit(s.charCodeAt(0))))&&!(o&&!a.Character.isHexDigit(s.charCodeAt(0)))}}if(n&&i&&t.length>2){var u=t.substr(1,t.length-2);r&&u.length>1?t=String.fromCharCode(parseInt(u.substr(1),10)):o&&u.length>2?t=String.fromCharCode(parseInt("0"+u.substr(1),16)):r||o||!h.XHTMLEntities[u]||(t=h.XHTMLEntities[u])}return t},t.prototype.lexJSX=function(){var e=this.scanner.source.charCodeAt(this.scanner.index);if(60===e||62===e||47===e||58===e||61===e||123===e||125===e)return{type:7,value:s=this.scanner.source[this.scanner.index++],lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:this.scanner.index-1,end:this.scanner.index};if(34===e||39===e){for(var t=this.scanner.index,n=this.scanner.source[this.scanner.index++],i="";!this.scanner.eof()&&(u=this.scanner.source[this.scanner.index++])!==n;)i+="&"===u?this.scanXHTMLEntity(n):u;return{type:8,value:i,lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:t,end:this.scanner.index}}if(46===e){var r=this.scanner.source.charCodeAt(this.scanner.index+1),o=this.scanner.source.charCodeAt(this.scanner.index+2),s=46===r&&46===o?"...":".";return t=this.scanner.index,this.scanner.index+=s.length,{type:7,value:s,lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:t,end:this.scanner.index}}if(96===e)return{type:10,value:"",lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:this.scanner.index,end:this.scanner.index};if(a.Character.isIdentifierStart(e)&&92!==e){for(t=this.scanner.index,++this.scanner.index;!this.scanner.eof();){var u=this.scanner.source.charCodeAt(this.scanner.index);if(a.Character.isIdentifierPart(u)&&92!==u)++this.scanner.index;else{if(45!==u)break;++this.scanner.index}}return{type:100,value:this.scanner.source.slice(t,this.scanner.index),lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:t,end:this.scanner.index}}return this.scanner.lex()},t.prototype.nextJSXToken=function(){this.collectComments(),this.startMarker.index=this.scanner.index,this.startMarker.line=this.scanner.lineNumber,this.startMarker.column=this.scanner.index-this.scanner.lineStart;var e=this.lexJSX();return this.lastMarker.index=this.scanner.index,this.lastMarker.line=this.scanner.lineNumber,this.lastMarker.column=this.scanner.index-this.scanner.lineStart,this.config.tokens&&this.tokens.push(this.convertToken(e)),e},t.prototype.nextJSXText=function(){this.startMarker.index=this.scanner.index,this.startMarker.line=this.scanner.lineNumber,this.startMarker.column=this.scanner.index-this.scanner.lineStart;for(var e=this.scanner.index,t="";!this.scanner.eof();){var n=this.scanner.source[this.scanner.index];if("{"===n||"<"===n)break;++this.scanner.index,t+=n,a.Character.isLineTerminator(n.charCodeAt(0))&&(++this.scanner.lineNumber,"\r"===n&&"\n"===this.scanner.source[this.scanner.index]&&++this.scanner.index,this.scanner.lineStart=this.scanner.index)}this.lastMarker.index=this.scanner.index,this.lastMarker.line=this.scanner.lineNumber,this.lastMarker.column=this.scanner.index-this.scanner.lineStart;var i={type:101,value:t,lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:e,end:this.scanner.index};return t.length>0&&this.config.tokens&&this.tokens.push(this.convertToken(i)),i},t.prototype.peekJSXToken=function(){var e=this.scanner.saveState();this.scanner.scanComments();var t=this.lexJSX();return this.scanner.restoreState(e),t},t.prototype.expectJSX=function(e){var t=this.nextJSXToken();7===t.type&&t.value===e||this.throwUnexpectedToken(t)},t.prototype.matchJSX=function(e){var t=this.peekJSXToken();return 7===t.type&&t.value===e},t.prototype.parseJSXIdentifier=function(){var e=this.createJSXNode(),t=this.nextJSXToken();return 100!==t.type&&this.throwUnexpectedToken(t),this.finalize(e,new o.JSXIdentifier(t.value))},t.prototype.parseJSXElementName=function(){var e=this.createJSXNode(),t=this.parseJSXIdentifier();if(this.matchJSX(":")){var n=t;this.expectJSX(":");var i=this.parseJSXIdentifier();t=this.finalize(e,new o.JSXNamespacedName(n,i))}else if(this.matchJSX("."))for(;this.matchJSX(".");){var r=t;this.expectJSX(".");var a=this.parseJSXIdentifier();t=this.finalize(e,new o.JSXMemberExpression(r,a))}return t},t.prototype.parseJSXAttributeName=function(){var e,t=this.createJSXNode(),n=this.parseJSXIdentifier();if(this.matchJSX(":")){var i=n;this.expectJSX(":");var r=this.parseJSXIdentifier();e=this.finalize(t,new o.JSXNamespacedName(i,r))}else e=n;return e},t.prototype.parseJSXStringLiteralAttribute=function(){var e=this.createJSXNode(),t=this.nextJSXToken();8!==t.type&&this.throwUnexpectedToken(t);var n=this.getTokenRaw(t);return this.finalize(e,new u.Literal(t.value,n))},t.prototype.parseJSXExpressionAttribute=function(){var e=this.createJSXNode();this.expectJSX("{"),this.finishJSX(),this.match("}")&&this.tolerateError("JSX attributes must only be assigned a non-empty expression");var t=this.parseAssignmentExpression();return this.reenterJSX(),this.finalize(e,new o.JSXExpressionContainer(t))},t.prototype.parseJSXAttributeValue=function(){return this.matchJSX("{")?this.parseJSXExpressionAttribute():this.matchJSX("<")?this.parseJSXElement():this.parseJSXStringLiteralAttribute()},t.prototype.parseJSXNameValueAttribute=function(){var e=this.createJSXNode(),t=this.parseJSXAttributeName(),n=null;return this.matchJSX("=")&&(this.expectJSX("="),n=this.parseJSXAttributeValue()),this.finalize(e,new o.JSXAttribute(t,n))},t.prototype.parseJSXSpreadAttribute=function(){var e=this.createJSXNode();this.expectJSX("{"),this.expectJSX("..."),this.finishJSX();var t=this.parseAssignmentExpression();return this.reenterJSX(),this.finalize(e,new o.JSXSpreadAttribute(t))},t.prototype.parseJSXAttributes=function(){for(var e=[];!this.matchJSX("/")&&!this.matchJSX(">");){var t=this.matchJSX("{")?this.parseJSXSpreadAttribute():this.parseJSXNameValueAttribute();e.push(t)}return e},t.prototype.parseJSXOpeningElement=function(){var e=this.createJSXNode();this.expectJSX("<");var t=this.parseJSXElementName(),n=this.parseJSXAttributes(),i=this.matchJSX("/");return i&&this.expectJSX("/"),this.expectJSX(">"),this.finalize(e,new o.JSXOpeningElement(t,i,n))},t.prototype.parseJSXBoundaryElement=function(){var e=this.createJSXNode();if(this.expectJSX("<"),this.matchJSX("/")){this.expectJSX("/");var t=this.parseJSXElementName();return this.expectJSX(">"),this.finalize(e,new o.JSXClosingElement(t))}var n=this.parseJSXElementName(),i=this.parseJSXAttributes(),r=this.matchJSX("/");return r&&this.expectJSX("/"),this.expectJSX(">"),this.finalize(e,new o.JSXOpeningElement(n,r,i))},t.prototype.parseJSXEmptyExpression=function(){var e=this.createJSXChildNode();return this.collectComments(),this.lastMarker.index=this.scanner.index,this.lastMarker.line=this.scanner.lineNumber,this.lastMarker.column=this.scanner.index-this.scanner.lineStart,this.finalize(e,new o.JSXEmptyExpression)},t.prototype.parseJSXExpressionContainer=function(){var e,t=this.createJSXNode();return this.expectJSX("{"),this.matchJSX("}")?(e=this.parseJSXEmptyExpression(),this.expectJSX("}")):(this.finishJSX(),e=this.parseAssignmentExpression(),this.reenterJSX()),this.finalize(t,new o.JSXExpressionContainer(e))},t.prototype.parseJSXChildren=function(){for(var e=[];!this.scanner.eof();){var t=this.createJSXChildNode(),n=this.nextJSXText();if(n.start<n.end){var i=this.getTokenRaw(n),r=this.finalize(t,new o.JSXText(n.value,i));e.push(r)}if("{"!==this.scanner.source[this.scanner.index])break;var a=this.parseJSXExpressionContainer();e.push(a)}return e},t.prototype.parseComplexJSXElement=function(e){for(var t=[];!this.scanner.eof();){e.children=e.children.concat(this.parseJSXChildren());var n=this.createJSXChildNode(),i=this.parseJSXBoundaryElement();if(i.type===s.JSXSyntax.JSXOpeningElement){var r=i;if(r.selfClosing){var a=this.finalize(n,new o.JSXElement(r,[],null));e.children.push(a)}else t.push(e),e={node:n,opening:r,closing:null,children:[]}}if(i.type===s.JSXSyntax.JSXClosingElement){e.closing=i;var u=d(e.opening.name);if(u!==d(e.closing.name)&&this.tolerateError("Expected corresponding JSX closing tag for %0",u),!(t.length>0))break;a=this.finalize(e.node,new o.JSXElement(e.opening,e.children,e.closing)),(e=t[t.length-1]).children.push(a),t.pop()}}return e},t.prototype.parseJSXElement=function(){var e=this.createJSXNode(),t=this.parseJSXOpeningElement(),n=[],i=null;if(!t.selfClosing){var r=this.parseComplexJSXElement({node:e,opening:t,closing:i,children:n});n=r.children,i=r.closing}return this.finalize(e,new o.JSXElement(t,n,i))},t.prototype.parseJSXRoot=function(){this.config.tokens&&this.tokens.pop(),this.startJSX();var e=this.parseJSXElement();return this.finishJSX(),e},t.prototype.isStartOfExpression=function(){return e.prototype.isStartOfExpression.call(this)||this.match("<")},t}(l.Parser);t.JSXParser=p},function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n={NonAsciiIdentifierStart:/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0-\u08B4\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF30-\uDF4A\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC03-\uDC37\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDEC0-\uDEF8]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F]|\uD82C[\uDC00\uDC01]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1]|\uD87E[\uDC00-\uDE1D]/,NonAsciiIdentifierPart:/[\xAA\xB5\xB7\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u08A0-\u08B4\u08E3-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0AF9\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C60-\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D01-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D57\u0D5F-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1369-\u1371\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19DA\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1CD0-\u1CD2\u1CD4-\u1CF6\u1CF8\u1CF9\u1D00-\u1DF5\u1DFC-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u200C\u200D\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C4\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA8FD\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDDFD\uDE80-\uDE9C\uDEA0-\uDED0\uDEE0\uDF00-\uDF1F\uDF30-\uDF4A\uDF50-\uDF7A\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCA0-\uDCA9\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00-\uDE03\uDE05\uDE06\uDE0C-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE38-\uDE3A\uDE3F\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE6\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC00-\uDC46\uDC66-\uDC6F\uDC7F-\uDCBA\uDCD0-\uDCE8\uDCF0-\uDCF9\uDD00-\uDD34\uDD36-\uDD3F\uDD50-\uDD73\uDD76\uDD80-\uDDC4\uDDCA-\uDDCC\uDDD0-\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE37\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEEA\uDEF0-\uDEF9\uDF00-\uDF03\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3C-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF50\uDF57\uDF5D-\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC80-\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDB5\uDDB8-\uDDC0\uDDD8-\uDDDD\uDE00-\uDE40\uDE44\uDE50-\uDE59\uDE80-\uDEB7\uDEC0-\uDEC9\uDF00-\uDF19\uDF1D-\uDF2B\uDF30-\uDF39]|\uD806[\uDCA0-\uDCE9\uDCFF\uDEC0-\uDEF8]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDED0-\uDEED\uDEF0-\uDEF4\uDF00-\uDF36\uDF40-\uDF43\uDF50-\uDF59\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50-\uDF7E\uDF8F-\uDF9F]|\uD82C[\uDC00\uDC01]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99\uDC9D\uDC9E]|\uD834[\uDD65-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB\uDFCE-\uDFFF]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD83A[\uDC00-\uDCC4\uDCD0-\uDCD6]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1]|\uD87E[\uDC00-\uDE1D]|\uDB40[\uDD00-\uDDEF]/};t.Character={fromCodePoint:function(e){return e<65536?String.fromCharCode(e):String.fromCharCode(55296+(e-65536>>10))+String.fromCharCode(56320+(e-65536&1023))},isWhiteSpace:function(e){return 32===e||9===e||11===e||12===e||160===e||e>=5760&&[5760,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8239,8287,12288,65279].indexOf(e)>=0},isLineTerminator:function(e){return 10===e||13===e||8232===e||8233===e},isIdentifierStart:function(e){return 36===e||95===e||e>=65&&e<=90||e>=97&&e<=122||92===e||e>=128&&n.NonAsciiIdentifierStart.test(t.Character.fromCodePoint(e))},isIdentifierPart:function(e){return 36===e||95===e||e>=65&&e<=90||e>=97&&e<=122||e>=48&&e<=57||92===e||e>=128&&n.NonAsciiIdentifierPart.test(t.Character.fromCodePoint(e))},isDecimalDigit:function(e){return e>=48&&e<=57},isHexDigit:function(e){return e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102},isOctalDigit:function(e){return e>=48&&e<=55}}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var i=n(6),r=function(e){this.type=i.JSXSyntax.JSXClosingElement,this.name=e};t.JSXClosingElement=r;var a=function(e,t,n){this.type=i.JSXSyntax.JSXElement,this.openingElement=e,this.children=t,this.closingElement=n};t.JSXElement=a;var o=function(){this.type=i.JSXSyntax.JSXEmptyExpression};t.JSXEmptyExpression=o;var s=function(e){this.type=i.JSXSyntax.JSXExpressionContainer,this.expression=e};t.JSXExpressionContainer=s;var u=function(e){this.type=i.JSXSyntax.JSXIdentifier,this.name=e};t.JSXIdentifier=u;var l=function(e,t){this.type=i.JSXSyntax.JSXMemberExpression,this.object=e,this.property=t};t.JSXMemberExpression=l;var c=function(e,t){this.type=i.JSXSyntax.JSXAttribute,this.name=e,this.value=t};t.JSXAttribute=c;var h=function(e,t){this.type=i.JSXSyntax.JSXNamespacedName,this.namespace=e,this.name=t};t.JSXNamespacedName=h;var d=function(e,t,n){this.type=i.JSXSyntax.JSXOpeningElement,this.name=e,this.selfClosing=t,this.attributes=n};t.JSXOpeningElement=d;var p=function(e){this.type=i.JSXSyntax.JSXSpreadAttribute,this.argument=e};t.JSXSpreadAttribute=p;var f=function(e,t){this.type=i.JSXSyntax.JSXText,this.value=e,this.raw=t};t.JSXText=f},function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.JSXSyntax={JSXAttribute:"JSXAttribute",JSXClosingElement:"JSXClosingElement",JSXElement:"JSXElement",JSXEmptyExpression:"JSXEmptyExpression",JSXExpressionContainer:"JSXExpressionContainer",JSXIdentifier:"JSXIdentifier",JSXMemberExpression:"JSXMemberExpression",JSXNamespacedName:"JSXNamespacedName",JSXOpeningElement:"JSXOpeningElement",JSXSpreadAttribute:"JSXSpreadAttribute",JSXText:"JSXText"}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var i=n(2),r=function(e){this.type=i.Syntax.ArrayExpression,this.elements=e};t.ArrayExpression=r;var a=function(e){this.type=i.Syntax.ArrayPattern,this.elements=e};t.ArrayPattern=a;var o=function(e,t,n){this.type=i.Syntax.ArrowFunctionExpression,this.id=null,this.params=e,this.body=t,this.generator=!1,this.expression=n,this.async=!1};t.ArrowFunctionExpression=o;var s=function(e,t,n){this.type=i.Syntax.AssignmentExpression,this.operator=e,this.left=t,this.right=n};t.AssignmentExpression=s;var u=function(e,t){this.type=i.Syntax.AssignmentPattern,this.left=e,this.right=t};t.AssignmentPattern=u;var l=function(e,t,n){this.type=i.Syntax.ArrowFunctionExpression,this.id=null,this.params=e,this.body=t,this.generator=!1,this.expression=n,this.async=!0};t.AsyncArrowFunctionExpression=l;var c=function(e,t,n){this.type=i.Syntax.FunctionDeclaration,this.id=e,this.params=t,this.body=n,this.generator=!1,this.expression=!1,this.async=!0};t.AsyncFunctionDeclaration=c;var h=function(e,t,n){this.type=i.Syntax.FunctionExpression,this.id=e,this.params=t,this.body=n,this.generator=!1,this.expression=!1,this.async=!0};t.AsyncFunctionExpression=h;var d=function(e){this.type=i.Syntax.AwaitExpression,this.argument=e};t.AwaitExpression=d;var p=function(e,t,n){var r="||"===e||"&&"===e;this.type=r?i.Syntax.LogicalExpression:i.Syntax.BinaryExpression,this.operator=e,this.left=t,this.right=n};t.BinaryExpression=p;var f=function(e){this.type=i.Syntax.BlockStatement,this.body=e};t.BlockStatement=f;var m=function(e){this.type=i.Syntax.BreakStatement,this.label=e};t.BreakStatement=m;var y=function(e,t){this.type=i.Syntax.CallExpression,this.callee=e,this.arguments=t};t.CallExpression=y;var g=function(e,t){this.type=i.Syntax.CatchClause,this.param=e,this.body=t};t.CatchClause=g;var v=function(e){this.type=i.Syntax.ClassBody,this.body=e};t.ClassBody=v;var b=function(e,t,n){this.type=i.Syntax.ClassDeclaration,this.id=e,this.superClass=t,this.body=n};t.ClassDeclaration=b;var x=function(e,t,n){this.type=i.Syntax.ClassExpression,this.id=e,this.superClass=t,this.body=n};t.ClassExpression=x;var E=function(e,t){this.type=i.Syntax.MemberExpression,this.computed=!0,this.object=e,this.property=t};t.ComputedMemberExpression=E;var S=function(e,t,n){this.type=i.Syntax.ConditionalExpression,this.test=e,this.consequent=t,this.alternate=n};t.ConditionalExpression=S;var w=function(e){this.type=i.Syntax.ContinueStatement,this.label=e};t.ContinueStatement=w;var D=function(){this.type=i.Syntax.DebuggerStatement};t.DebuggerStatement=D;var A=function(e,t){this.type=i.Syntax.ExpressionStatement,this.expression=e,this.directive=t};t.Directive=A;var k=function(e,t){this.type=i.Syntax.DoWhileStatement,this.body=e,this.test=t};t.DoWhileStatement=k;var C=function(){this.type=i.Syntax.EmptyStatement};t.EmptyStatement=C;var T=function(e){this.type=i.Syntax.ExportAllDeclaration,this.source=e};t.ExportAllDeclaration=T;var F=function(e){this.type=i.Syntax.ExportDefaultDeclaration,this.declaration=e};t.ExportDefaultDeclaration=F;var P=function(e,t,n){this.type=i.Syntax.ExportNamedDeclaration,this.declaration=e,this.specifiers=t,this.source=n};t.ExportNamedDeclaration=P;var B=function(e,t){this.type=i.Syntax.ExportSpecifier,this.exported=t,this.local=e};t.ExportSpecifier=B;var I=function(e){this.type=i.Syntax.ExpressionStatement,this.expression=e};t.ExpressionStatement=I;var N=function(e,t,n){this.type=i.Syntax.ForInStatement,this.left=e,this.right=t,this.body=n,this.each=!1};t.ForInStatement=N;var M=function(e,t,n){this.type=i.Syntax.ForOfStatement,this.left=e,this.right=t,this.body=n};t.ForOfStatement=M;var R=function(e,t,n,r){this.type=i.Syntax.ForStatement,this.init=e,this.test=t,this.update=n,this.body=r};t.ForStatement=R;var L=function(e,t,n,r){this.type=i.Syntax.FunctionDeclaration,this.id=e,this.params=t,this.body=n,this.generator=r,this.expression=!1,this.async=!1};t.FunctionDeclaration=L;var O=function(e,t,n,r){this.type=i.Syntax.FunctionExpression,this.id=e,this.params=t,this.body=n,this.generator=r,this.expression=!1,this.async=!1};t.FunctionExpression=O;var _=function(e){this.type=i.Syntax.Identifier,this.name=e};t.Identifier=_;var U=function(e,t,n){this.type=i.Syntax.IfStatement,this.test=e,this.consequent=t,this.alternate=n};t.IfStatement=U;var j=function(e,t){this.type=i.Syntax.ImportDeclaration,this.specifiers=e,this.source=t};t.ImportDeclaration=j;var H=function(e){this.type=i.Syntax.ImportDefaultSpecifier,this.local=e};t.ImportDefaultSpecifier=H;var z=function(e){this.type=i.Syntax.ImportNamespaceSpecifier,this.local=e};t.ImportNamespaceSpecifier=z;var G=function(e,t){this.type=i.Syntax.ImportSpecifier,this.local=e,this.imported=t};t.ImportSpecifier=G;var K=function(e,t){this.type=i.Syntax.LabeledStatement,this.label=e,this.body=t};t.LabeledStatement=K;var X=function(e,t){this.type=i.Syntax.Literal,this.value=e,this.raw=t};t.Literal=X;var V=function(e,t){this.type=i.Syntax.MetaProperty,this.meta=e,this.property=t};t.MetaProperty=V;var W=function(e,t,n,r,a){this.type=i.Syntax.MethodDefinition,this.key=e,this.computed=t,this.value=n,this.kind=r,this.static=a};t.MethodDefinition=W;var J=function(e){this.type=i.Syntax.Program,this.body=e,this.sourceType="module"};t.Module=J;var q=function(e,t){this.type=i.Syntax.NewExpression,this.callee=e,this.arguments=t};t.NewExpression=q;var Y=function(e){this.type=i.Syntax.ObjectExpression,this.properties=e};t.ObjectExpression=Y;var Q=function(e){this.type=i.Syntax.ObjectPattern,this.properties=e};t.ObjectPattern=Q;var Z=function(e,t,n,r,a,o){this.type=i.Syntax.Property,this.key=t,this.computed=n,this.value=r,this.kind=e,this.method=a,this.shorthand=o};t.Property=Z;var $=function(e,t,n,r){this.type=i.Syntax.Literal,this.value=e,this.raw=t,this.regex={pattern:n,flags:r}};t.RegexLiteral=$;var ee=function(e){this.type=i.Syntax.RestElement,this.argument=e};t.RestElement=ee;var te=function(e){this.type=i.Syntax.ReturnStatement,this.argument=e};t.ReturnStatement=te;var ne=function(e){this.type=i.Syntax.Program,this.body=e,this.sourceType="script"};t.Script=ne;var ie=function(e){this.type=i.Syntax.SequenceExpression,this.expressions=e};t.SequenceExpression=ie;var re=function(e){this.type=i.Syntax.SpreadElement,this.argument=e};t.SpreadElement=re;var ae=function(e,t){this.type=i.Syntax.MemberExpression,this.computed=!1,this.object=e,this.property=t};t.StaticMemberExpression=ae;var oe=function(){this.type=i.Syntax.Super};t.Super=oe;var se=function(e,t){this.type=i.Syntax.SwitchCase,this.test=e,this.consequent=t};t.SwitchCase=se;var ue=function(e,t){this.type=i.Syntax.SwitchStatement,this.discriminant=e,this.cases=t};t.SwitchStatement=ue;var le=function(e,t){this.type=i.Syntax.TaggedTemplateExpression,this.tag=e,this.quasi=t};t.TaggedTemplateExpression=le;var ce=function(e,t){this.type=i.Syntax.TemplateElement,this.value=e,this.tail=t};t.TemplateElement=ce;var he=function(e,t){this.type=i.Syntax.TemplateLiteral,this.quasis=e,this.expressions=t};t.TemplateLiteral=he;var de=function(){this.type=i.Syntax.ThisExpression};t.ThisExpression=de;var pe=function(e){this.type=i.Syntax.ThrowStatement,this.argument=e};t.ThrowStatement=pe;var fe=function(e,t,n){this.type=i.Syntax.TryStatement,this.block=e,this.handler=t,this.finalizer=n};t.TryStatement=fe;var me=function(e,t){this.type=i.Syntax.UnaryExpression,this.operator=e,this.argument=t,this.prefix=!0};t.UnaryExpression=me;var ye=function(e,t,n){this.type=i.Syntax.UpdateExpression,this.operator=e,this.argument=t,this.prefix=n};t.UpdateExpression=ye;var ge=function(e,t){this.type=i.Syntax.VariableDeclaration,this.declarations=e,this.kind=t};t.VariableDeclaration=ge;var ve=function(e,t){this.type=i.Syntax.VariableDeclarator,this.id=e,this.init=t};t.VariableDeclarator=ve;var be=function(e,t){this.type=i.Syntax.WhileStatement,this.test=e,this.body=t};t.WhileStatement=be;var xe=function(e,t){this.type=i.Syntax.WithStatement,this.object=e,this.body=t};t.WithStatement=xe;var Ee=function(e,t){this.type=i.Syntax.YieldExpression,this.argument=e,this.delegate=t};t.YieldExpression=Ee},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var i=n(9),r=n(10),a=n(11),o=n(7),s=n(12),u=n(2),l=n(13),c="ArrowParameterPlaceHolder",h=function(){function e(e,t,n){void 0===t&&(t={}),this.config={range:"boolean"==typeof t.range&&t.range,loc:"boolean"==typeof t.loc&&t.loc,source:null,tokens:"boolean"==typeof t.tokens&&t.tokens,comment:"boolean"==typeof t.comment&&t.comment,tolerant:"boolean"==typeof t.tolerant&&t.tolerant},this.config.loc&&t.source&&null!==t.source&&(this.config.source=String(t.source)),this.delegate=n,this.errorHandler=new r.ErrorHandler,this.errorHandler.tolerant=this.config.tolerant,this.scanner=new s.Scanner(e,this.errorHandler),this.scanner.trackComment=this.config.comment,this.operatorPrecedence={")":0,";":0,",":0,"=":0,"]":0,"||":1,"&&":2,"|":3,"^":4,"&":5,"==":6,"!=":6,"===":6,"!==":6,"<":7,">":7,"<=":7,">=":7,"<<":8,">>":8,">>>":8,"+":9,"-":9,"*":11,"/":11,"%":11},this.lookahead={type:2,value:"",lineNumber:this.scanner.lineNumber,lineStart:0,start:0,end:0},this.hasLineTerminator=!1,this.context={isModule:!1,await:!1,allowIn:!0,allowStrictDirective:!0,allowYield:!0,firstCoverInitializedNameError:null,isAssignmentTarget:!1,isBindingElement:!1,inFunctionBody:!1,inIteration:!1,inSwitch:!1,labelSet:{},strict:!1},this.tokens=[],this.startMarker={index:0,line:this.scanner.lineNumber,column:0},this.lastMarker={index:0,line:this.scanner.lineNumber,column:0},this.nextToken(),this.lastMarker={index:this.scanner.index,line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}}return e.prototype.throwError=function(e){var t=Array.prototype.slice.call(arguments,1),n=e.replace(/%(\d)/g,function(e,n){return i.assert(n<t.length,"Message reference must be in range"),t[n]}),r=this.lastMarker.index,a=this.lastMarker.line,o=this.lastMarker.column+1;throw this.errorHandler.createError(r,a,o,n)},e.prototype.tolerateError=function(e){var t=Array.prototype.slice.call(arguments,1),n=e.replace(/%(\d)/g,function(e,n){return i.assert(n<t.length,"Message reference must be in range"),t[n]}),r=this.lastMarker.index,a=this.scanner.lineNumber,o=this.lastMarker.column+1;this.errorHandler.tolerateError(r,a,o,n)},e.prototype.unexpectedTokenError=function(e,t){var n,i=t||a.Messages.UnexpectedToken;if(e?(t||(i=2===e.type?a.Messages.UnexpectedEOS:3===e.type?a.Messages.UnexpectedIdentifier:6===e.type?a.Messages.UnexpectedNumber:8===e.type?a.Messages.UnexpectedString:10===e.type?a.Messages.UnexpectedTemplate:a.Messages.UnexpectedToken,4===e.type&&(this.scanner.isFutureReservedWord(e.value)?i=a.Messages.UnexpectedReserved:this.context.strict&&this.scanner.isStrictModeReservedWord(e.value)&&(i=a.Messages.StrictReservedWord))),n=e.value):n="ILLEGAL",i=i.replace("%0",n),e&&"number"==typeof e.lineNumber){var r=e.start,o=e.lineNumber,s=this.lastMarker.index-this.lastMarker.column,u=e.start-s+1;return this.errorHandler.createError(r,o,u,i)}return r=this.lastMarker.index,o=this.lastMarker.line,u=this.lastMarker.column+1,this.errorHandler.createError(r,o,u,i)},e.prototype.throwUnexpectedToken=function(e,t){throw this.unexpectedTokenError(e,t)},e.prototype.tolerateUnexpectedToken=function(e,t){this.errorHandler.tolerate(this.unexpectedTokenError(e,t))},e.prototype.collectComments=function(){if(this.config.comment){var e=this.scanner.scanComments();if(e.length>0&&this.delegate)for(var t=0;t<e.length;++t){var n=e[t],i=void 0;i={type:n.multiLine?"BlockComment":"LineComment",value:this.scanner.source.slice(n.slice[0],n.slice[1])},this.config.range&&(i.range=n.range),this.config.loc&&(i.loc=n.loc);var r={start:{line:n.loc.start.line,column:n.loc.start.column,offset:n.range[0]},end:{line:n.loc.end.line,column:n.loc.end.column,offset:n.range[1]}};this.delegate(i,r)}}else this.scanner.scanComments()},e.prototype.getTokenRaw=function(e){return this.scanner.source.slice(e.start,e.end)},e.prototype.convertToken=function(e){var t={type:l.TokenName[e.type],value:this.getTokenRaw(e)};if(this.config.range&&(t.range=[e.start,e.end]),this.config.loc&&(t.loc={start:{line:this.startMarker.line,column:this.startMarker.column},end:{line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}}),9===e.type){var n=e.pattern,i=e.flags;t.regex={pattern:n,flags:i}}return t},e.prototype.nextToken=function(){var e=this.lookahead;this.lastMarker.index=this.scanner.index,this.lastMarker.line=this.scanner.lineNumber,this.lastMarker.column=this.scanner.index-this.scanner.lineStart,this.collectComments(),this.scanner.index!==this.startMarker.index&&(this.startMarker.index=this.scanner.index,this.startMarker.line=this.scanner.lineNumber,this.startMarker.column=this.scanner.index-this.scanner.lineStart);var t=this.scanner.lex();return this.hasLineTerminator=e.lineNumber!==t.lineNumber,t&&this.context.strict&&3===t.type&&this.scanner.isStrictModeReservedWord(t.value)&&(t.type=4),this.lookahead=t,this.config.tokens&&2!==t.type&&this.tokens.push(this.convertToken(t)),e},e.prototype.nextRegexToken=function(){this.collectComments();var e=this.scanner.scanRegExp();return this.config.tokens&&(this.tokens.pop(),this.tokens.push(this.convertToken(e))),this.lookahead=e,this.nextToken(),e},e.prototype.createNode=function(){return{index:this.startMarker.index,line:this.startMarker.line,column:this.startMarker.column}},e.prototype.startNode=function(e,t){void 0===t&&(t=0);var n=e.start-e.lineStart,i=e.lineNumber;return n<0&&(n+=t,i--),{index:e.start,line:i,column:n}},e.prototype.finalize=function(e,t){if(this.config.range&&(t.range=[e.index,this.lastMarker.index]),this.config.loc&&(t.loc={start:{line:e.line,column:e.column},end:{line:this.lastMarker.line,column:this.lastMarker.column}},this.config.source&&(t.loc.source=this.config.source)),this.delegate){var n={start:{line:e.line,column:e.column,offset:e.index},end:{line:this.lastMarker.line,column:this.lastMarker.column,offset:this.lastMarker.index}};this.delegate(t,n)}return t},e.prototype.expect=function(e){var t=this.nextToken();7===t.type&&t.value===e||this.throwUnexpectedToken(t)},e.prototype.expectCommaSeparator=function(){if(this.config.tolerant){var e=this.lookahead;7===e.type&&","===e.value?this.nextToken():7===e.type&&";"===e.value?(this.nextToken(),this.tolerateUnexpectedToken(e)):this.tolerateUnexpectedToken(e,a.Messages.UnexpectedToken)}else this.expect(",")},e.prototype.expectKeyword=function(e){var t=this.nextToken();4===t.type&&t.value===e||this.throwUnexpectedToken(t)},e.prototype.match=function(e){return 7===this.lookahead.type&&this.lookahead.value===e},e.prototype.matchKeyword=function(e){return 4===this.lookahead.type&&this.lookahead.value===e},e.prototype.matchContextualKeyword=function(e){return 3===this.lookahead.type&&this.lookahead.value===e},e.prototype.matchAssign=function(){if(7!==this.lookahead.type)return!1;var e=this.lookahead.value;return"="===e||"*="===e||"**="===e||"/="===e||"%="===e||"+="===e||"-="===e||"<<="===e||">>="===e||">>>="===e||"&="===e||"^="===e||"|="===e},e.prototype.isolateCoverGrammar=function(e){var t=this.context.isBindingElement,n=this.context.isAssignmentTarget,i=this.context.firstCoverInitializedNameError;this.context.isBindingElement=!0,this.context.isAssignmentTarget=!0,this.context.firstCoverInitializedNameError=null;var r=e.call(this);return null!==this.context.firstCoverInitializedNameError&&this.throwUnexpectedToken(this.context.firstCoverInitializedNameError),this.context.isBindingElement=t,this.context.isAssignmentTarget=n,this.context.firstCoverInitializedNameError=i,r},e.prototype.inheritCoverGrammar=function(e){var t=this.context.isBindingElement,n=this.context.isAssignmentTarget,i=this.context.firstCoverInitializedNameError;this.context.isBindingElement=!0,this.context.isAssignmentTarget=!0,this.context.firstCoverInitializedNameError=null;var r=e.call(this);return this.context.isBindingElement=this.context.isBindingElement&&t,this.context.isAssignmentTarget=this.context.isAssignmentTarget&&n,this.context.firstCoverInitializedNameError=i||this.context.firstCoverInitializedNameError,r},e.prototype.consumeSemicolon=function(){this.match(";")?this.nextToken():this.hasLineTerminator||(2===this.lookahead.type||this.match("}")||this.throwUnexpectedToken(this.lookahead),this.lastMarker.index=this.startMarker.index,this.lastMarker.line=this.startMarker.line,this.lastMarker.column=this.startMarker.column)},e.prototype.parsePrimaryExpression=function(){var e,t,n,i=this.createNode();switch(this.lookahead.type){case 3:(this.context.isModule||this.context.await)&&"await"===this.lookahead.value&&this.tolerateUnexpectedToken(this.lookahead),e=this.matchAsyncFunction()?this.parseFunctionExpression():this.finalize(i,new o.Identifier(this.nextToken().value));break;case 6:case 8:this.context.strict&&this.lookahead.octal&&this.tolerateUnexpectedToken(this.lookahead,a.Messages.StrictOctalLiteral),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,t=this.nextToken(),n=this.getTokenRaw(t),e=this.finalize(i,new o.Literal(t.value,n));break;case 1:this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,t=this.nextToken(),n=this.getTokenRaw(t),e=this.finalize(i,new o.Literal("true"===t.value,n));break;case 5:this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,t=this.nextToken(),n=this.getTokenRaw(t),e=this.finalize(i,new o.Literal(null,n));break;case 10:e=this.parseTemplateLiteral();break;case 7:switch(this.lookahead.value){case"(":this.context.isBindingElement=!1,e=this.inheritCoverGrammar(this.parseGroupExpression);break;case"[":e=this.inheritCoverGrammar(this.parseArrayInitializer);break;case"{":e=this.inheritCoverGrammar(this.parseObjectInitializer);break;case"/":case"/=":this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,this.scanner.index=this.startMarker.index,t=this.nextRegexToken(),n=this.getTokenRaw(t),e=this.finalize(i,new o.RegexLiteral(t.regex,n,t.pattern,t.flags));break;default:e=this.throwUnexpectedToken(this.nextToken())}break;case 4:!this.context.strict&&this.context.allowYield&&this.matchKeyword("yield")?e=this.parseIdentifierName():!this.context.strict&&this.matchKeyword("let")?e=this.finalize(i,new o.Identifier(this.nextToken().value)):(this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,this.matchKeyword("function")?e=this.parseFunctionExpression():this.matchKeyword("this")?(this.nextToken(),e=this.finalize(i,new o.ThisExpression)):e=this.matchKeyword("class")?this.parseClassExpression():this.throwUnexpectedToken(this.nextToken()));break;default:e=this.throwUnexpectedToken(this.nextToken())}return e},e.prototype.parseSpreadElement=function(){var e=this.createNode();this.expect("...");var t=this.inheritCoverGrammar(this.parseAssignmentExpression);return this.finalize(e,new o.SpreadElement(t))},e.prototype.parseArrayInitializer=function(){var e=this.createNode(),t=[];for(this.expect("[");!this.match("]");)if(this.match(","))this.nextToken(),t.push(null);else if(this.match("...")){var n=this.parseSpreadElement();this.match("]")||(this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,this.expect(",")),t.push(n)}else t.push(this.inheritCoverGrammar(this.parseAssignmentExpression)),this.match("]")||this.expect(",");return this.expect("]"),this.finalize(e,new o.ArrayExpression(t))},e.prototype.parsePropertyMethod=function(e){this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;var t=this.context.strict,n=this.context.allowStrictDirective;this.context.allowStrictDirective=e.simple;var i=this.isolateCoverGrammar(this.parseFunctionSourceElements);return this.context.strict&&e.firstRestricted&&this.tolerateUnexpectedToken(e.firstRestricted,e.message),this.context.strict&&e.stricted&&this.tolerateUnexpectedToken(e.stricted,e.message),this.context.strict=t,this.context.allowStrictDirective=n,i},e.prototype.parsePropertyMethodFunction=function(){var e=this.createNode(),t=this.context.allowYield;this.context.allowYield=!0;var n=this.parseFormalParameters(),i=this.parsePropertyMethod(n);return this.context.allowYield=t,this.finalize(e,new o.FunctionExpression(null,n.params,i,!1))},e.prototype.parsePropertyMethodAsyncFunction=function(){var e=this.createNode(),t=this.context.allowYield,n=this.context.await;this.context.allowYield=!1,this.context.await=!0;var i=this.parseFormalParameters(),r=this.parsePropertyMethod(i);return this.context.allowYield=t,this.context.await=n,this.finalize(e,new o.AsyncFunctionExpression(null,i.params,r))},e.prototype.parseObjectPropertyKey=function(){var e,t=this.createNode(),n=this.nextToken();switch(n.type){case 8:case 6:this.context.strict&&n.octal&&this.tolerateUnexpectedToken(n,a.Messages.StrictOctalLiteral);var i=this.getTokenRaw(n);e=this.finalize(t,new o.Literal(n.value,i));break;case 3:case 1:case 5:case 4:e=this.finalize(t,new o.Identifier(n.value));break;case 7:"["===n.value?(e=this.isolateCoverGrammar(this.parseAssignmentExpression),this.expect("]")):e=this.throwUnexpectedToken(n);break;default:e=this.throwUnexpectedToken(n)}return e},e.prototype.isPropertyKey=function(e,t){return e.type===u.Syntax.Identifier&&e.name===t||e.type===u.Syntax.Literal&&e.value===t},e.prototype.parseObjectProperty=function(e){var t,n=this.createNode(),i=this.lookahead,r=null,s=null,u=!1,l=!1,c=!1,h=!1;if(3===i.type){var d=i.value;this.nextToken(),u=this.match("["),r=(h=!(this.hasLineTerminator||"async"!==d||this.match(":")||this.match("(")||this.match("*")||this.match(",")))?this.parseObjectPropertyKey():this.finalize(n,new o.Identifier(d))}else this.match("*")?this.nextToken():(u=this.match("["),r=this.parseObjectPropertyKey());var p=this.qualifiedPropertyName(this.lookahead);if(3===i.type&&!h&&"get"===i.value&&p)t="get",u=this.match("["),r=this.parseObjectPropertyKey(),this.context.allowYield=!1,s=this.parseGetterMethod();else if(3===i.type&&!h&&"set"===i.value&&p)t="set",u=this.match("["),r=this.parseObjectPropertyKey(),s=this.parseSetterMethod();else if(7===i.type&&"*"===i.value&&p)t="init",u=this.match("["),r=this.parseObjectPropertyKey(),s=this.parseGeneratorMethod(),l=!0;else if(r||this.throwUnexpectedToken(this.lookahead),t="init",this.match(":")&&!h)!u&&this.isPropertyKey(r,"__proto__")&&(e.value&&this.tolerateError(a.Messages.DuplicateProtoProperty),e.value=!0),this.nextToken(),s=this.inheritCoverGrammar(this.parseAssignmentExpression);else if(this.match("("))s=h?this.parsePropertyMethodAsyncFunction():this.parsePropertyMethodFunction(),l=!0;else if(3===i.type)if(d=this.finalize(n,new o.Identifier(i.value)),this.match("=")){this.context.firstCoverInitializedNameError=this.lookahead,this.nextToken(),c=!0;var f=this.isolateCoverGrammar(this.parseAssignmentExpression);s=this.finalize(n,new o.AssignmentPattern(d,f))}else c=!0,s=d;else this.throwUnexpectedToken(this.nextToken());return this.finalize(n,new o.Property(t,r,u,s,l,c))},e.prototype.parseObjectInitializer=function(){var e=this.createNode();this.expect("{");for(var t=[],n={value:!1};!this.match("}");)t.push(this.parseObjectProperty(n)),this.match("}")||this.expectCommaSeparator();return this.expect("}"),this.finalize(e,new o.ObjectExpression(t))},e.prototype.parseTemplateHead=function(){i.assert(this.lookahead.head,"Template literal must start with a template head");var e=this.createNode(),t=this.nextToken(),n=t.value,r=t.cooked;return this.finalize(e,new o.TemplateElement({raw:n,cooked:r},t.tail))},e.prototype.parseTemplateElement=function(){10!==this.lookahead.type&&this.throwUnexpectedToken();var e=this.createNode(),t=this.nextToken(),n=t.value,i=t.cooked;return this.finalize(e,new o.TemplateElement({raw:n,cooked:i},t.tail))},e.prototype.parseTemplateLiteral=function(){var e=this.createNode(),t=[],n=[],i=this.parseTemplateHead();for(n.push(i);!i.tail;)t.push(this.parseExpression()),i=this.parseTemplateElement(),n.push(i);return this.finalize(e,new o.TemplateLiteral(n,t))},e.prototype.reinterpretExpressionAsPattern=function(e){switch(e.type){case u.Syntax.Identifier:case u.Syntax.MemberExpression:case u.Syntax.RestElement:case u.Syntax.AssignmentPattern:break;case u.Syntax.SpreadElement:e.type=u.Syntax.RestElement,this.reinterpretExpressionAsPattern(e.argument);break;case u.Syntax.ArrayExpression:e.type=u.Syntax.ArrayPattern;for(var t=0;t<e.elements.length;t++)null!==e.elements[t]&&this.reinterpretExpressionAsPattern(e.elements[t]);break;case u.Syntax.ObjectExpression:for(e.type=u.Syntax.ObjectPattern,t=0;t<e.properties.length;t++)this.reinterpretExpressionAsPattern(e.properties[t].value);break;case u.Syntax.AssignmentExpression:e.type=u.Syntax.AssignmentPattern,delete e.operator,this.reinterpretExpressionAsPattern(e.left)}},e.prototype.parseGroupExpression=function(){var e;if(this.expect("("),this.match(")"))this.nextToken(),this.match("=>")||this.expect("=>"),e={type:c,params:[],async:!1};else{var t=this.lookahead,n=[];if(this.match("..."))e=this.parseRestElement(n),this.expect(")"),this.match("=>")||this.expect("=>"),e={type:c,params:[e],async:!1};else{var i=!1;if(this.context.isBindingElement=!0,e=this.inheritCoverGrammar(this.parseAssignmentExpression),this.match(",")){var r=[];for(this.context.isAssignmentTarget=!1,r.push(e);2!==this.lookahead.type&&this.match(",");){if(this.nextToken(),this.match(")")){this.nextToken();for(var a=0;a<r.length;a++)this.reinterpretExpressionAsPattern(r[a]);i=!0,e={type:c,params:r,async:!1}}else if(this.match("...")){for(this.context.isBindingElement||this.throwUnexpectedToken(this.lookahead),r.push(this.parseRestElement(n)),this.expect(")"),this.match("=>")||this.expect("=>"),this.context.isBindingElement=!1,a=0;a<r.length;a++)this.reinterpretExpressionAsPattern(r[a]);i=!0,e={type:c,params:r,async:!1}}else r.push(this.inheritCoverGrammar(this.parseAssignmentExpression));if(i)break}i||(e=this.finalize(this.startNode(t),new o.SequenceExpression(r)))}if(!i){if(this.expect(")"),this.match("=>")&&(e.type===u.Syntax.Identifier&&"yield"===e.name&&(i=!0,e={type:c,params:[e],async:!1}),!i)){if(this.context.isBindingElement||this.throwUnexpectedToken(this.lookahead),e.type===u.Syntax.SequenceExpression)for(a=0;a<e.expressions.length;a++)this.reinterpretExpressionAsPattern(e.expressions[a]);else this.reinterpretExpressionAsPattern(e);var s=e.type===u.Syntax.SequenceExpression?e.expressions:[e];e={type:c,params:s,async:!1}}this.context.isBindingElement=!1}}}return e},e.prototype.parseArguments=function(){this.expect("(");var e=[];if(!this.match(")"))for(;;){var t=this.match("...")?this.parseSpreadElement():this.isolateCoverGrammar(this.parseAssignmentExpression);if(e.push(t),this.match(")"))break;if(this.expectCommaSeparator(),this.match(")"))break}return this.expect(")"),e},e.prototype.isIdentifierName=function(e){return 3===e.type||4===e.type||1===e.type||5===e.type},e.prototype.parseIdentifierName=function(){var e=this.createNode(),t=this.nextToken();return this.isIdentifierName(t)||this.throwUnexpectedToken(t),this.finalize(e,new o.Identifier(t.value))},e.prototype.parseNewExpression=function(){var e,t=this.createNode(),n=this.parseIdentifierName();if(i.assert("new"===n.name,"New expression must start with `new`"),this.match("."))if(this.nextToken(),3===this.lookahead.type&&this.context.inFunctionBody&&"target"===this.lookahead.value){var r=this.parseIdentifierName();e=new o.MetaProperty(n,r)}else this.throwUnexpectedToken(this.lookahead);else{var a=this.isolateCoverGrammar(this.parseLeftHandSideExpression),s=this.match("(")?this.parseArguments():[];e=new o.NewExpression(a,s),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1}return this.finalize(t,e)},e.prototype.parseAsyncArgument=function(){var e=this.parseAssignmentExpression();return this.context.firstCoverInitializedNameError=null,e},e.prototype.parseAsyncArguments=function(){this.expect("(");var e=[];if(!this.match(")"))for(;;){var t=this.match("...")?this.parseSpreadElement():this.isolateCoverGrammar(this.parseAsyncArgument);if(e.push(t),this.match(")"))break;if(this.expectCommaSeparator(),this.match(")"))break}return this.expect(")"),e},e.prototype.parseLeftHandSideExpressionAllowCall=function(){var e,t=this.lookahead,n=this.matchContextualKeyword("async"),i=this.context.allowIn;for(this.context.allowIn=!0,this.matchKeyword("super")&&this.context.inFunctionBody?(e=this.createNode(),this.nextToken(),e=this.finalize(e,new o.Super),this.match("(")||this.match(".")||this.match("[")||this.throwUnexpectedToken(this.lookahead)):e=this.inheritCoverGrammar(this.matchKeyword("new")?this.parseNewExpression:this.parsePrimaryExpression);;)if(this.match(".")){this.context.isBindingElement=!1,this.context.isAssignmentTarget=!0,this.expect(".");var r=this.parseIdentifierName();e=this.finalize(this.startNode(t),new o.StaticMemberExpression(e,r))}else if(this.match("(")){var a=n&&t.lineNumber===this.lookahead.lineNumber;this.context.isBindingElement=!1,this.context.isAssignmentTarget=!1;var s=a?this.parseAsyncArguments():this.parseArguments();if(e=this.finalize(this.startNode(t),new o.CallExpression(e,s)),a&&this.match("=>")){for(var u=0;u<s.length;++u)this.reinterpretExpressionAsPattern(s[u]);e={type:c,params:s,async:!0}}}else if(this.match("["))this.context.isBindingElement=!1,this.context.isAssignmentTarget=!0,this.expect("["),r=this.isolateCoverGrammar(this.parseExpression),this.expect("]"),e=this.finalize(this.startNode(t),new o.ComputedMemberExpression(e,r));else{if(10!==this.lookahead.type||!this.lookahead.head)break;var l=this.parseTemplateLiteral();e=this.finalize(this.startNode(t),new o.TaggedTemplateExpression(e,l))}return this.context.allowIn=i,e},e.prototype.parseSuper=function(){var e=this.createNode();return this.expectKeyword("super"),this.match("[")||this.match(".")||this.throwUnexpectedToken(this.lookahead),this.finalize(e,new o.Super)},e.prototype.parseLeftHandSideExpression=function(){i.assert(this.context.allowIn,"callee of new expression always allow in keyword.");for(var e=this.startNode(this.lookahead),t=this.matchKeyword("super")&&this.context.inFunctionBody?this.parseSuper():this.inheritCoverGrammar(this.matchKeyword("new")?this.parseNewExpression:this.parsePrimaryExpression);;)if(this.match("[")){this.context.isBindingElement=!1,this.context.isAssignmentTarget=!0,this.expect("[");var n=this.isolateCoverGrammar(this.parseExpression);this.expect("]"),t=this.finalize(e,new o.ComputedMemberExpression(t,n))}else if(this.match("."))this.context.isBindingElement=!1,this.context.isAssignmentTarget=!0,this.expect("."),n=this.parseIdentifierName(),t=this.finalize(e,new o.StaticMemberExpression(t,n));else{if(10!==this.lookahead.type||!this.lookahead.head)break;var r=this.parseTemplateLiteral();t=this.finalize(e,new o.TaggedTemplateExpression(t,r))}return t},e.prototype.parseUpdateExpression=function(){var e,t=this.lookahead;if(this.match("++")||this.match("--")){var n=this.startNode(t),i=this.nextToken();e=this.inheritCoverGrammar(this.parseUnaryExpression),this.context.strict&&e.type===u.Syntax.Identifier&&this.scanner.isRestrictedWord(e.name)&&this.tolerateError(a.Messages.StrictLHSPrefix),this.context.isAssignmentTarget||this.tolerateError(a.Messages.InvalidLHSInAssignment);var r=!0;e=this.finalize(n,new o.UpdateExpression(i.value,e,r)),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1}else if(e=this.inheritCoverGrammar(this.parseLeftHandSideExpressionAllowCall),!this.hasLineTerminator&&7===this.lookahead.type&&(this.match("++")||this.match("--"))){this.context.strict&&e.type===u.Syntax.Identifier&&this.scanner.isRestrictedWord(e.name)&&this.tolerateError(a.Messages.StrictLHSPostfix),this.context.isAssignmentTarget||this.tolerateError(a.Messages.InvalidLHSInAssignment),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;var s=this.nextToken().value;r=!1,e=this.finalize(this.startNode(t),new o.UpdateExpression(s,e,r))}return e},e.prototype.parseAwaitExpression=function(){var e=this.createNode();this.nextToken();var t=this.parseUnaryExpression();return this.finalize(e,new o.AwaitExpression(t))},e.prototype.parseUnaryExpression=function(){var e;if(this.match("+")||this.match("-")||this.match("~")||this.match("!")||this.matchKeyword("delete")||this.matchKeyword("void")||this.matchKeyword("typeof")){var t=this.startNode(this.lookahead),n=this.nextToken();e=this.inheritCoverGrammar(this.parseUnaryExpression),e=this.finalize(t,new o.UnaryExpression(n.value,e)),this.context.strict&&"delete"===e.operator&&e.argument.type===u.Syntax.Identifier&&this.tolerateError(a.Messages.StrictDelete),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1}else e=this.context.await&&this.matchContextualKeyword("await")?this.parseAwaitExpression():this.parseUpdateExpression();return e},e.prototype.parseExponentiationExpression=function(){var e=this.lookahead,t=this.inheritCoverGrammar(this.parseUnaryExpression);if(t.type!==u.Syntax.UnaryExpression&&this.match("**")){this.nextToken(),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;var n=t,i=this.isolateCoverGrammar(this.parseExponentiationExpression);t=this.finalize(this.startNode(e),new o.BinaryExpression("**",n,i))}return t},e.prototype.binaryPrecedence=function(e){var t=e.value;return 7===e.type?this.operatorPrecedence[t]||0:4===e.type&&("instanceof"===t||this.context.allowIn&&"in"===t)?7:0},e.prototype.parseBinaryExpression=function(){var e=this.lookahead,t=this.inheritCoverGrammar(this.parseExponentiationExpression),n=this.lookahead,i=this.binaryPrecedence(n);if(i>0){this.nextToken(),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;for(var r=[e,this.lookahead],a=t,s=this.isolateCoverGrammar(this.parseExponentiationExpression),u=[a,n.value,s],l=[i];!((i=this.binaryPrecedence(this.lookahead))<=0);){for(;u.length>2&&i<=l[l.length-1];){s=u.pop();var c=u.pop();l.pop(),a=u.pop(),r.pop();var h=this.startNode(r[r.length-1]);u.push(this.finalize(h,new o.BinaryExpression(c,a,s)))}u.push(this.nextToken().value),l.push(i),r.push(this.lookahead),u.push(this.isolateCoverGrammar(this.parseExponentiationExpression))}var d=u.length-1;t=u[d];for(var p=r.pop();d>1;){var f=r.pop(),m=p&&p.lineStart;h=this.startNode(f,m),c=u[d-1],t=this.finalize(h,new o.BinaryExpression(c,u[d-2],t)),d-=2,p=f}}return t},e.prototype.parseConditionalExpression=function(){var e=this.lookahead,t=this.inheritCoverGrammar(this.parseBinaryExpression);if(this.match("?")){this.nextToken();var n=this.context.allowIn;this.context.allowIn=!0;var i=this.isolateCoverGrammar(this.parseAssignmentExpression);this.context.allowIn=n,this.expect(":");var r=this.isolateCoverGrammar(this.parseAssignmentExpression);t=this.finalize(this.startNode(e),new o.ConditionalExpression(t,i,r)),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1}return t},e.prototype.checkPatternParam=function(e,t){switch(t.type){case u.Syntax.Identifier:this.validateParam(e,t,t.name);break;case u.Syntax.RestElement:this.checkPatternParam(e,t.argument);break;case u.Syntax.AssignmentPattern:this.checkPatternParam(e,t.left);break;case u.Syntax.ArrayPattern:for(var n=0;n<t.elements.length;n++)null!==t.elements[n]&&this.checkPatternParam(e,t.elements[n]);break;case u.Syntax.ObjectPattern:for(n=0;n<t.properties.length;n++)this.checkPatternParam(e,t.properties[n].value)}e.simple=e.simple&&t instanceof o.Identifier},e.prototype.reinterpretAsCoverFormalsList=function(e){var t,n=[e],i=!1;switch(e.type){case u.Syntax.Identifier:break;case c:n=e.params,i=e.async;break;default:return null}t={simple:!0,paramSet:{}};for(var r=0;r<n.length;++r)(o=n[r]).type===u.Syntax.AssignmentPattern?o.right.type===u.Syntax.YieldExpression&&(o.right.argument&&this.throwUnexpectedToken(this.lookahead),o.right.type=u.Syntax.Identifier,o.right.name="yield",delete o.right.argument,delete o.right.delegate):i&&o.type===u.Syntax.Identifier&&"await"===o.name&&this.throwUnexpectedToken(this.lookahead),this.checkPatternParam(t,o),n[r]=o;if(this.context.strict||!this.context.allowYield)for(r=0;r<n.length;++r){var o;(o=n[r]).type===u.Syntax.YieldExpression&&this.throwUnexpectedToken(this.lookahead)}if(t.message===a.Messages.StrictParamDupe){var s=this.context.strict?t.stricted:t.firstRestricted;this.throwUnexpectedToken(s,t.message)}return{simple:t.simple,params:n,stricted:t.stricted,firstRestricted:t.firstRestricted,message:t.message}},e.prototype.parseAssignmentExpression=function(){var e;if(!this.context.allowYield&&this.matchKeyword("yield"))e=this.parseYieldExpression();else{var t=this.lookahead,n=t;if(e=this.parseConditionalExpression(),3===n.type&&n.lineNumber===this.lookahead.lineNumber&&"async"===n.value&&(3===this.lookahead.type||this.matchKeyword("yield"))){var i=this.parsePrimaryExpression();this.reinterpretExpressionAsPattern(i),e={type:c,params:[i],async:!0}}if(e.type===c||this.match("=>")){this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;var r=e.async,s=this.reinterpretAsCoverFormalsList(e);if(s){this.hasLineTerminator&&this.tolerateUnexpectedToken(this.lookahead),this.context.firstCoverInitializedNameError=null;var l=this.context.strict,h=this.context.allowStrictDirective;this.context.allowStrictDirective=s.simple;var d=this.context.allowYield,p=this.context.await;this.context.allowYield=!0,this.context.await=r;var f=this.startNode(t);this.expect("=>");var m=void 0;if(this.match("{")){var y=this.context.allowIn;this.context.allowIn=!0,m=this.parseFunctionSourceElements(),this.context.allowIn=y}else m=this.isolateCoverGrammar(this.parseAssignmentExpression);var g=m.type!==u.Syntax.BlockStatement;this.context.strict&&s.firstRestricted&&this.throwUnexpectedToken(s.firstRestricted,s.message),this.context.strict&&s.stricted&&this.tolerateUnexpectedToken(s.stricted,s.message),e=r?this.finalize(f,new o.AsyncArrowFunctionExpression(s.params,m,g)):this.finalize(f,new o.ArrowFunctionExpression(s.params,m,g)),this.context.strict=l,this.context.allowStrictDirective=h,this.context.allowYield=d,this.context.await=p}}else if(this.matchAssign()){if(this.context.isAssignmentTarget||this.tolerateError(a.Messages.InvalidLHSInAssignment),this.context.strict&&e.type===u.Syntax.Identifier){var v=e;this.scanner.isRestrictedWord(v.name)&&this.tolerateUnexpectedToken(n,a.Messages.StrictLHSAssignment),this.scanner.isStrictModeReservedWord(v.name)&&this.tolerateUnexpectedToken(n,a.Messages.StrictReservedWord)}this.match("=")?this.reinterpretExpressionAsPattern(e):(this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1);var b=(n=this.nextToken()).value,x=this.isolateCoverGrammar(this.parseAssignmentExpression);e=this.finalize(this.startNode(t),new o.AssignmentExpression(b,e,x)),this.context.firstCoverInitializedNameError=null}}return e},e.prototype.parseExpression=function(){var e=this.lookahead,t=this.isolateCoverGrammar(this.parseAssignmentExpression);if(this.match(",")){var n=[];for(n.push(t);2!==this.lookahead.type&&this.match(",");)this.nextToken(),n.push(this.isolateCoverGrammar(this.parseAssignmentExpression));t=this.finalize(this.startNode(e),new o.SequenceExpression(n))}return t},e.prototype.parseStatementListItem=function(){var e;if(this.context.isAssignmentTarget=!0,this.context.isBindingElement=!0,4===this.lookahead.type)switch(this.lookahead.value){case"export":this.context.isModule||this.tolerateUnexpectedToken(this.lookahead,a.Messages.IllegalExportDeclaration),e=this.parseExportDeclaration();break;case"import":this.context.isModule||this.tolerateUnexpectedToken(this.lookahead,a.Messages.IllegalImportDeclaration),e=this.parseImportDeclaration();break;case"const":e=this.parseLexicalDeclaration({inFor:!1});break;case"function":e=this.parseFunctionDeclaration();break;case"class":e=this.parseClassDeclaration();break;case"let":e=this.isLexicalDeclaration()?this.parseLexicalDeclaration({inFor:!1}):this.parseStatement();break;default:e=this.parseStatement()}else e=this.parseStatement();return e},e.prototype.parseBlock=function(){var e=this.createNode();this.expect("{");for(var t=[];!this.match("}");)t.push(this.parseStatementListItem());return this.expect("}"),this.finalize(e,new o.BlockStatement(t))},e.prototype.parseLexicalBinding=function(e,t){var n=this.createNode(),i=this.parsePattern([],e);this.context.strict&&i.type===u.Syntax.Identifier&&this.scanner.isRestrictedWord(i.name)&&this.tolerateError(a.Messages.StrictVarName);var r=null;return"const"===e?this.matchKeyword("in")||this.matchContextualKeyword("of")||(this.match("=")?(this.nextToken(),r=this.isolateCoverGrammar(this.parseAssignmentExpression)):this.throwError(a.Messages.DeclarationMissingInitializer,"const")):(!t.inFor&&i.type!==u.Syntax.Identifier||this.match("="))&&(this.expect("="),r=this.isolateCoverGrammar(this.parseAssignmentExpression)),this.finalize(n,new o.VariableDeclarator(i,r))},e.prototype.parseBindingList=function(e,t){for(var n=[this.parseLexicalBinding(e,t)];this.match(",");)this.nextToken(),n.push(this.parseLexicalBinding(e,t));return n},e.prototype.isLexicalDeclaration=function(){var e=this.scanner.saveState();this.scanner.scanComments();var t=this.scanner.lex();return this.scanner.restoreState(e),3===t.type||7===t.type&&"["===t.value||7===t.type&&"{"===t.value||4===t.type&&"let"===t.value||4===t.type&&"yield"===t.value},e.prototype.parseLexicalDeclaration=function(e){var t=this.createNode(),n=this.nextToken().value;i.assert("let"===n||"const"===n,"Lexical declaration must be either let or const");var r=this.parseBindingList(n,e);return this.consumeSemicolon(),this.finalize(t,new o.VariableDeclaration(r,n))},e.prototype.parseBindingRestElement=function(e,t){var n=this.createNode();this.expect("...");var i=this.parsePattern(e,t);return this.finalize(n,new o.RestElement(i))},e.prototype.parseArrayPattern=function(e,t){var n=this.createNode();this.expect("[");for(var i=[];!this.match("]");)if(this.match(","))this.nextToken(),i.push(null);else{if(this.match("...")){i.push(this.parseBindingRestElement(e,t));break}i.push(this.parsePatternWithDefault(e,t)),this.match("]")||this.expect(",")}return this.expect("]"),this.finalize(n,new o.ArrayPattern(i))},e.prototype.parsePropertyPattern=function(e,t){var n,i,r=this.createNode(),a=!1,s=!1;if(3===this.lookahead.type){var u=this.lookahead;n=this.parseVariableIdentifier();var l=this.finalize(r,new o.Identifier(u.value));if(this.match("=")){e.push(u),s=!0,this.nextToken();var c=this.parseAssignmentExpression();i=this.finalize(this.startNode(u),new o.AssignmentPattern(l,c))}else this.match(":")?(this.expect(":"),i=this.parsePatternWithDefault(e,t)):(e.push(u),s=!0,i=l)}else a=this.match("["),n=this.parseObjectPropertyKey(),this.expect(":"),i=this.parsePatternWithDefault(e,t);return this.finalize(r,new o.Property("init",n,a,i,!1,s))},e.prototype.parseObjectPattern=function(e,t){var n=this.createNode(),i=[];for(this.expect("{");!this.match("}");)i.push(this.parsePropertyPattern(e,t)),this.match("}")||this.expect(",");return this.expect("}"),this.finalize(n,new o.ObjectPattern(i))},e.prototype.parsePattern=function(e,t){var n;return this.match("[")?n=this.parseArrayPattern(e,t):this.match("{")?n=this.parseObjectPattern(e,t):(!this.matchKeyword("let")||"const"!==t&&"let"!==t||this.tolerateUnexpectedToken(this.lookahead,a.Messages.LetInLexicalBinding),e.push(this.lookahead),n=this.parseVariableIdentifier(t)),n},e.prototype.parsePatternWithDefault=function(e,t){var n=this.lookahead,i=this.parsePattern(e,t);if(this.match("=")){this.nextToken();var r=this.context.allowYield;this.context.allowYield=!0;var a=this.isolateCoverGrammar(this.parseAssignmentExpression);this.context.allowYield=r,i=this.finalize(this.startNode(n),new o.AssignmentPattern(i,a))}return i},e.prototype.parseVariableIdentifier=function(e){var t=this.createNode(),n=this.nextToken();return 4===n.type&&"yield"===n.value?this.context.strict?this.tolerateUnexpectedToken(n,a.Messages.StrictReservedWord):this.context.allowYield||this.throwUnexpectedToken(n):3!==n.type?this.context.strict&&4===n.type&&this.scanner.isStrictModeReservedWord(n.value)?this.tolerateUnexpectedToken(n,a.Messages.StrictReservedWord):(this.context.strict||"let"!==n.value||"var"!==e)&&this.throwUnexpectedToken(n):(this.context.isModule||this.context.await)&&3===n.type&&"await"===n.value&&this.tolerateUnexpectedToken(n),this.finalize(t,new o.Identifier(n.value))},e.prototype.parseVariableDeclaration=function(e){var t=this.createNode(),n=this.parsePattern([],"var");this.context.strict&&n.type===u.Syntax.Identifier&&this.scanner.isRestrictedWord(n.name)&&this.tolerateError(a.Messages.StrictVarName);var i=null;return this.match("=")?(this.nextToken(),i=this.isolateCoverGrammar(this.parseAssignmentExpression)):n.type===u.Syntax.Identifier||e.inFor||this.expect("="),this.finalize(t,new o.VariableDeclarator(n,i))},e.prototype.parseVariableDeclarationList=function(e){var t={inFor:e.inFor},n=[];for(n.push(this.parseVariableDeclaration(t));this.match(",");)this.nextToken(),n.push(this.parseVariableDeclaration(t));return n},e.prototype.parseVariableStatement=function(){var e=this.createNode();this.expectKeyword("var");var t=this.parseVariableDeclarationList({inFor:!1});return this.consumeSemicolon(),this.finalize(e,new o.VariableDeclaration(t,"var"))},e.prototype.parseEmptyStatement=function(){var e=this.createNode();return this.expect(";"),this.finalize(e,new o.EmptyStatement)},e.prototype.parseExpressionStatement=function(){var e=this.createNode(),t=this.parseExpression();return this.consumeSemicolon(),this.finalize(e,new o.ExpressionStatement(t))},e.prototype.parseIfClause=function(){return this.context.strict&&this.matchKeyword("function")&&this.tolerateError(a.Messages.StrictFunction),this.parseStatement()},e.prototype.parseIfStatement=function(){var e,t=this.createNode(),n=null;this.expectKeyword("if"),this.expect("(");var i=this.parseExpression();return!this.match(")")&&this.config.tolerant?(this.tolerateUnexpectedToken(this.nextToken()),e=this.finalize(this.createNode(),new o.EmptyStatement)):(this.expect(")"),e=this.parseIfClause(),this.matchKeyword("else")&&(this.nextToken(),n=this.parseIfClause())),this.finalize(t,new o.IfStatement(i,e,n))},e.prototype.parseDoWhileStatement=function(){var e=this.createNode();this.expectKeyword("do");var t=this.context.inIteration;this.context.inIteration=!0;var n=this.parseStatement();this.context.inIteration=t,this.expectKeyword("while"),this.expect("(");var i=this.parseExpression();return!this.match(")")&&this.config.tolerant?this.tolerateUnexpectedToken(this.nextToken()):(this.expect(")"),this.match(";")&&this.nextToken()),this.finalize(e,new o.DoWhileStatement(n,i))},e.prototype.parseWhileStatement=function(){var e,t=this.createNode();this.expectKeyword("while"),this.expect("(");var n=this.parseExpression();if(!this.match(")")&&this.config.tolerant)this.tolerateUnexpectedToken(this.nextToken()),e=this.finalize(this.createNode(),new o.EmptyStatement);else{this.expect(")");var i=this.context.inIteration;this.context.inIteration=!0,e=this.parseStatement(),this.context.inIteration=i}return this.finalize(t,new o.WhileStatement(n,e))},e.prototype.parseForStatement=function(){var e,t,n,i=null,r=null,s=null,l=!0,c=this.createNode();if(this.expectKeyword("for"),this.expect("("),this.match(";"))this.nextToken();else if(this.matchKeyword("var")){i=this.createNode(),this.nextToken();var h=this.context.allowIn;this.context.allowIn=!1;var d=this.parseVariableDeclarationList({inFor:!0});if(this.context.allowIn=h,1===d.length&&this.matchKeyword("in")){var p=d[0];p.init&&(p.id.type===u.Syntax.ArrayPattern||p.id.type===u.Syntax.ObjectPattern||this.context.strict)&&this.tolerateError(a.Messages.ForInOfLoopInitializer,"for-in"),i=this.finalize(i,new o.VariableDeclaration(d,"var")),this.nextToken(),e=i,t=this.parseExpression(),i=null}else 1===d.length&&null===d[0].init&&this.matchContextualKeyword("of")?(i=this.finalize(i,new o.VariableDeclaration(d,"var")),this.nextToken(),e=i,t=this.parseAssignmentExpression(),i=null,l=!1):(i=this.finalize(i,new o.VariableDeclaration(d,"var")),this.expect(";"))}else if(this.matchKeyword("const")||this.matchKeyword("let")){i=this.createNode();var f=this.nextToken().value;this.context.strict||"in"!==this.lookahead.value?(h=this.context.allowIn,this.context.allowIn=!1,d=this.parseBindingList(f,{inFor:!0}),this.context.allowIn=h,1===d.length&&null===d[0].init&&this.matchKeyword("in")?(i=this.finalize(i,new o.VariableDeclaration(d,f)),this.nextToken(),e=i,t=this.parseExpression(),i=null):1===d.length&&null===d[0].init&&this.matchContextualKeyword("of")?(i=this.finalize(i,new o.VariableDeclaration(d,f)),this.nextToken(),e=i,t=this.parseAssignmentExpression(),i=null,l=!1):(this.consumeSemicolon(),i=this.finalize(i,new o.VariableDeclaration(d,f)))):(i=this.finalize(i,new o.Identifier(f)),this.nextToken(),e=i,t=this.parseExpression(),i=null)}else{var m=this.lookahead;if(h=this.context.allowIn,this.context.allowIn=!1,i=this.inheritCoverGrammar(this.parseAssignmentExpression),this.context.allowIn=h,this.matchKeyword("in"))this.context.isAssignmentTarget&&i.type!==u.Syntax.AssignmentExpression||this.tolerateError(a.Messages.InvalidLHSInForIn),this.nextToken(),this.reinterpretExpressionAsPattern(i),e=i,t=this.parseExpression(),i=null;else if(this.matchContextualKeyword("of"))this.context.isAssignmentTarget&&i.type!==u.Syntax.AssignmentExpression||this.tolerateError(a.Messages.InvalidLHSInForLoop),this.nextToken(),this.reinterpretExpressionAsPattern(i),e=i,t=this.parseAssignmentExpression(),i=null,l=!1;else{if(this.match(",")){for(var y=[i];this.match(",");)this.nextToken(),y.push(this.isolateCoverGrammar(this.parseAssignmentExpression));i=this.finalize(this.startNode(m),new o.SequenceExpression(y))}this.expect(";")}}if(void 0===e&&(this.match(";")||(r=this.parseExpression()),this.expect(";"),this.match(")")||(s=this.parseExpression())),!this.match(")")&&this.config.tolerant)this.tolerateUnexpectedToken(this.nextToken()),n=this.finalize(this.createNode(),new o.EmptyStatement);else{this.expect(")");var g=this.context.inIteration;this.context.inIteration=!0,n=this.isolateCoverGrammar(this.parseStatement),this.context.inIteration=g}return void 0===e?this.finalize(c,new o.ForStatement(i,r,s,n)):l?this.finalize(c,new o.ForInStatement(e,t,n)):this.finalize(c,new o.ForOfStatement(e,t,n))},e.prototype.parseContinueStatement=function(){var e=this.createNode();this.expectKeyword("continue");var t=null;if(3===this.lookahead.type&&!this.hasLineTerminator){var n=this.parseVariableIdentifier();t=n;var i="$"+n.name;Object.prototype.hasOwnProperty.call(this.context.labelSet,i)||this.throwError(a.Messages.UnknownLabel,n.name)}return this.consumeSemicolon(),null!==t||this.context.inIteration||this.throwError(a.Messages.IllegalContinue),this.finalize(e,new o.ContinueStatement(t))},e.prototype.parseBreakStatement=function(){var e=this.createNode();this.expectKeyword("break");var t=null;if(3===this.lookahead.type&&!this.hasLineTerminator){var n=this.parseVariableIdentifier(),i="$"+n.name;Object.prototype.hasOwnProperty.call(this.context.labelSet,i)||this.throwError(a.Messages.UnknownLabel,n.name),t=n}return this.consumeSemicolon(),null!==t||this.context.inIteration||this.context.inSwitch||this.throwError(a.Messages.IllegalBreak),this.finalize(e,new o.BreakStatement(t))},e.prototype.parseReturnStatement=function(){this.context.inFunctionBody||this.tolerateError(a.Messages.IllegalReturn);var e=this.createNode();this.expectKeyword("return");var t=(this.match(";")||this.match("}")||this.hasLineTerminator||2===this.lookahead.type)&&8!==this.lookahead.type&&10!==this.lookahead.type?null:this.parseExpression();return this.consumeSemicolon(),this.finalize(e,new o.ReturnStatement(t))},e.prototype.parseWithStatement=function(){this.context.strict&&this.tolerateError(a.Messages.StrictModeWith);var e,t=this.createNode();this.expectKeyword("with"),this.expect("(");var n=this.parseExpression();return!this.match(")")&&this.config.tolerant?(this.tolerateUnexpectedToken(this.nextToken()),e=this.finalize(this.createNode(),new o.EmptyStatement)):(this.expect(")"),e=this.parseStatement()),this.finalize(t,new o.WithStatement(n,e))},e.prototype.parseSwitchCase=function(){var e,t=this.createNode();this.matchKeyword("default")?(this.nextToken(),e=null):(this.expectKeyword("case"),e=this.parseExpression()),this.expect(":");for(var n=[];!(this.match("}")||this.matchKeyword("default")||this.matchKeyword("case"));)n.push(this.parseStatementListItem());return this.finalize(t,new o.SwitchCase(e,n))},e.prototype.parseSwitchStatement=function(){var e=this.createNode();this.expectKeyword("switch"),this.expect("(");var t=this.parseExpression();this.expect(")");var n=this.context.inSwitch;this.context.inSwitch=!0;var i=[],r=!1;for(this.expect("{");!this.match("}");){var s=this.parseSwitchCase();null===s.test&&(r&&this.throwError(a.Messages.MultipleDefaultsInSwitch),r=!0),i.push(s)}return this.expect("}"),this.context.inSwitch=n,this.finalize(e,new o.SwitchStatement(t,i))},e.prototype.parseLabelledStatement=function(){var e,t=this.createNode(),n=this.parseExpression();if(n.type===u.Syntax.Identifier&&this.match(":")){this.nextToken();var i=n,r="$"+i.name;Object.prototype.hasOwnProperty.call(this.context.labelSet,r)&&this.throwError(a.Messages.Redeclaration,"Label",i.name),this.context.labelSet[r]=!0;var s=void 0;if(this.matchKeyword("class"))this.tolerateUnexpectedToken(this.lookahead),s=this.parseClassDeclaration();else if(this.matchKeyword("function")){var l=this.lookahead,c=this.parseFunctionDeclaration();this.context.strict?this.tolerateUnexpectedToken(l,a.Messages.StrictFunction):c.generator&&this.tolerateUnexpectedToken(l,a.Messages.GeneratorInLegacyContext),s=c}else s=this.parseStatement();delete this.context.labelSet[r],e=new o.LabeledStatement(i,s)}else this.consumeSemicolon(),e=new o.ExpressionStatement(n);return this.finalize(t,e)},e.prototype.parseThrowStatement=function(){var e=this.createNode();this.expectKeyword("throw"),this.hasLineTerminator&&this.throwError(a.Messages.NewlineAfterThrow);var t=this.parseExpression();return this.consumeSemicolon(),this.finalize(e,new o.ThrowStatement(t))},e.prototype.parseCatchClause=function(){var e=this.createNode();this.expectKeyword("catch"),this.expect("("),this.match(")")&&this.throwUnexpectedToken(this.lookahead);for(var t=[],n=this.parsePattern(t),i={},r=0;r<t.length;r++){var s="$"+t[r].value;Object.prototype.hasOwnProperty.call(i,s)&&this.tolerateError(a.Messages.DuplicateBinding,t[r].value),i[s]=!0}this.context.strict&&n.type===u.Syntax.Identifier&&this.scanner.isRestrictedWord(n.name)&&this.tolerateError(a.Messages.StrictCatchVariable),this.expect(")");var l=this.parseBlock();return this.finalize(e,new o.CatchClause(n,l))},e.prototype.parseFinallyClause=function(){return this.expectKeyword("finally"),this.parseBlock()},e.prototype.parseTryStatement=function(){var e=this.createNode();this.expectKeyword("try");var t=this.parseBlock(),n=this.matchKeyword("catch")?this.parseCatchClause():null,i=this.matchKeyword("finally")?this.parseFinallyClause():null;return n||i||this.throwError(a.Messages.NoCatchOrFinally),this.finalize(e,new o.TryStatement(t,n,i))},e.prototype.parseDebuggerStatement=function(){var e=this.createNode();return this.expectKeyword("debugger"),this.consumeSemicolon(),this.finalize(e,new o.DebuggerStatement)},e.prototype.parseStatement=function(){var e;switch(this.lookahead.type){case 1:case 5:case 6:case 8:case 10:case 9:e=this.parseExpressionStatement();break;case 7:var t=this.lookahead.value;e="{"===t?this.parseBlock():"("===t?this.parseExpressionStatement():";"===t?this.parseEmptyStatement():this.parseExpressionStatement();break;case 3:e=this.matchAsyncFunction()?this.parseFunctionDeclaration():this.parseLabelledStatement();break;case 4:switch(this.lookahead.value){case"break":e=this.parseBreakStatement();break;case"continue":e=this.parseContinueStatement();break;case"debugger":e=this.parseDebuggerStatement();break;case"do":e=this.parseDoWhileStatement();break;case"for":e=this.parseForStatement();break;case"function":e=this.parseFunctionDeclaration();break;case"if":e=this.parseIfStatement();break;case"return":e=this.parseReturnStatement();break;case"switch":e=this.parseSwitchStatement();break;case"throw":e=this.parseThrowStatement();break;case"try":e=this.parseTryStatement();break;case"var":e=this.parseVariableStatement();break;case"while":e=this.parseWhileStatement();break;case"with":e=this.parseWithStatement();break;default:e=this.parseExpressionStatement()}break;default:e=this.throwUnexpectedToken(this.lookahead)}return e},e.prototype.parseFunctionSourceElements=function(){var e=this.createNode();this.expect("{");var t=this.parseDirectivePrologues(),n=this.context.labelSet,i=this.context.inIteration,r=this.context.inSwitch,a=this.context.inFunctionBody;for(this.context.labelSet={},this.context.inIteration=!1,this.context.inSwitch=!1,this.context.inFunctionBody=!0;2!==this.lookahead.type&&!this.match("}");)t.push(this.parseStatementListItem());return this.expect("}"),this.context.labelSet=n,this.context.inIteration=i,this.context.inSwitch=r,this.context.inFunctionBody=a,this.finalize(e,new o.BlockStatement(t))},e.prototype.validateParam=function(e,t,n){var i="$"+n;this.context.strict?(this.scanner.isRestrictedWord(n)&&(e.stricted=t,e.message=a.Messages.StrictParamName),Object.prototype.hasOwnProperty.call(e.paramSet,i)&&(e.stricted=t,e.message=a.Messages.StrictParamDupe)):e.firstRestricted||(this.scanner.isRestrictedWord(n)?(e.firstRestricted=t,e.message=a.Messages.StrictParamName):this.scanner.isStrictModeReservedWord(n)?(e.firstRestricted=t,e.message=a.Messages.StrictReservedWord):Object.prototype.hasOwnProperty.call(e.paramSet,i)&&(e.stricted=t,e.message=a.Messages.StrictParamDupe)),"function"==typeof Object.defineProperty?Object.defineProperty(e.paramSet,i,{value:!0,enumerable:!0,writable:!0,configurable:!0}):e.paramSet[i]=!0},e.prototype.parseRestElement=function(e){var t=this.createNode();this.expect("...");var n=this.parsePattern(e);return this.match("=")&&this.throwError(a.Messages.DefaultRestParameter),this.match(")")||this.throwError(a.Messages.ParameterAfterRestParameter),this.finalize(t,new o.RestElement(n))},e.prototype.parseFormalParameter=function(e){for(var t=[],n=this.match("...")?this.parseRestElement(t):this.parsePatternWithDefault(t),i=0;i<t.length;i++)this.validateParam(e,t[i],t[i].value);e.simple=e.simple&&n instanceof o.Identifier,e.params.push(n)},e.prototype.parseFormalParameters=function(e){var t;if(t={simple:!0,params:[],firstRestricted:e},this.expect("("),!this.match(")"))for(t.paramSet={};2!==this.lookahead.type&&(this.parseFormalParameter(t),!this.match(")"))&&(this.expect(","),!this.match(")")););return this.expect(")"),{simple:t.simple,params:t.params,stricted:t.stricted,firstRestricted:t.firstRestricted,message:t.message}},e.prototype.matchAsyncFunction=function(){var e=this.matchContextualKeyword("async");if(e){var t=this.scanner.saveState();this.scanner.scanComments();var n=this.scanner.lex();this.scanner.restoreState(t),e=t.lineNumber===n.lineNumber&&4===n.type&&"function"===n.value}return e},e.prototype.parseFunctionDeclaration=function(e){var t=this.createNode(),n=this.matchContextualKeyword("async");n&&this.nextToken(),this.expectKeyword("function");var i,r=!n&&this.match("*");r&&this.nextToken();var s=null,u=null;if(!e||!this.match("(")){var l=this.lookahead;s=this.parseVariableIdentifier(),this.context.strict?this.scanner.isRestrictedWord(l.value)&&this.tolerateUnexpectedToken(l,a.Messages.StrictFunctionName):this.scanner.isRestrictedWord(l.value)?(u=l,i=a.Messages.StrictFunctionName):this.scanner.isStrictModeReservedWord(l.value)&&(u=l,i=a.Messages.StrictReservedWord)}var c=this.context.await,h=this.context.allowYield;this.context.await=n,this.context.allowYield=!r;var d=this.parseFormalParameters(u),p=d.params,f=d.stricted;u=d.firstRestricted,d.message&&(i=d.message);var m=this.context.strict,y=this.context.allowStrictDirective;this.context.allowStrictDirective=d.simple;var g=this.parseFunctionSourceElements();return this.context.strict&&u&&this.throwUnexpectedToken(u,i),this.context.strict&&f&&this.tolerateUnexpectedToken(f,i),this.context.strict=m,this.context.allowStrictDirective=y,this.context.await=c,this.context.allowYield=h,n?this.finalize(t,new o.AsyncFunctionDeclaration(s,p,g)):this.finalize(t,new o.FunctionDeclaration(s,p,g,r))},e.prototype.parseFunctionExpression=function(){var e=this.createNode(),t=this.matchContextualKeyword("async");t&&this.nextToken(),this.expectKeyword("function");var n,i=!t&&this.match("*");i&&this.nextToken();var r,s=null,u=this.context.await,l=this.context.allowYield;if(this.context.await=t,this.context.allowYield=!i,!this.match("(")){var c=this.lookahead;s=this.context.strict||i||!this.matchKeyword("yield")?this.parseVariableIdentifier():this.parseIdentifierName(),this.context.strict?this.scanner.isRestrictedWord(c.value)&&this.tolerateUnexpectedToken(c,a.Messages.StrictFunctionName):this.scanner.isRestrictedWord(c.value)?(r=c,n=a.Messages.StrictFunctionName):this.scanner.isStrictModeReservedWord(c.value)&&(r=c,n=a.Messages.StrictReservedWord)}var h=this.parseFormalParameters(r),d=h.params,p=h.stricted;r=h.firstRestricted,h.message&&(n=h.message);var f=this.context.strict,m=this.context.allowStrictDirective;this.context.allowStrictDirective=h.simple;var y=this.parseFunctionSourceElements();return this.context.strict&&r&&this.throwUnexpectedToken(r,n),this.context.strict&&p&&this.tolerateUnexpectedToken(p,n),this.context.strict=f,this.context.allowStrictDirective=m,this.context.await=u,this.context.allowYield=l,t?this.finalize(e,new o.AsyncFunctionExpression(s,d,y)):this.finalize(e,new o.FunctionExpression(s,d,y,i))},e.prototype.parseDirective=function(){var e=this.lookahead,t=this.createNode(),n=this.parseExpression(),i=n.type===u.Syntax.Literal?this.getTokenRaw(e).slice(1,-1):null;return this.consumeSemicolon(),this.finalize(t,i?new o.Directive(n,i):new o.ExpressionStatement(n))},e.prototype.parseDirectivePrologues=function(){for(var e=null,t=[];;){var n=this.lookahead;if(8!==n.type)break;var i=this.parseDirective();t.push(i);var r=i.directive;if("string"!=typeof r)break;"use strict"===r?(this.context.strict=!0,e&&this.tolerateUnexpectedToken(e,a.Messages.StrictOctalLiteral),this.context.allowStrictDirective||this.tolerateUnexpectedToken(n,a.Messages.IllegalLanguageModeDirective)):!e&&n.octal&&(e=n)}return t},e.prototype.qualifiedPropertyName=function(e){switch(e.type){case 3:case 8:case 1:case 5:case 6:case 4:return!0;case 7:return"["===e.value}return!1},e.prototype.parseGetterMethod=function(){var e=this.createNode(),t=!1,n=this.context.allowYield;this.context.allowYield=!0;var i=this.parseFormalParameters();i.params.length>0&&this.tolerateError(a.Messages.BadGetterArity);var r=this.parsePropertyMethod(i);return this.context.allowYield=n,this.finalize(e,new o.FunctionExpression(null,i.params,r,t))},e.prototype.parseSetterMethod=function(){var e=this.createNode(),t=!1,n=this.context.allowYield;this.context.allowYield=!0;var i=this.parseFormalParameters();1!==i.params.length?this.tolerateError(a.Messages.BadSetterArity):i.params[0]instanceof o.RestElement&&this.tolerateError(a.Messages.BadSetterRestParameter);var r=this.parsePropertyMethod(i);return this.context.allowYield=n,this.finalize(e,new o.FunctionExpression(null,i.params,r,t))},e.prototype.parseGeneratorMethod=function(){var e=this.createNode(),t=this.context.allowYield;this.context.allowYield=!0;var n=this.parseFormalParameters();this.context.allowYield=!1;var i=this.parsePropertyMethod(n);return this.context.allowYield=t,this.finalize(e,new o.FunctionExpression(null,n.params,i,!0))},e.prototype.isStartOfExpression=function(){var e=!0,t=this.lookahead.value;switch(this.lookahead.type){case 7:e="["===t||"("===t||"{"===t||"+"===t||"-"===t||"!"===t||"~"===t||"++"===t||"--"===t||"/"===t||"/="===t;break;case 4:e="class"===t||"delete"===t||"function"===t||"let"===t||"new"===t||"super"===t||"this"===t||"typeof"===t||"void"===t||"yield"===t}return e},e.prototype.parseYieldExpression=function(){var e=this.createNode();this.expectKeyword("yield");var t=null,n=!1;if(!this.hasLineTerminator){var i=this.context.allowYield;this.context.allowYield=!1,(n=this.match("*"))?(this.nextToken(),t=this.parseAssignmentExpression()):this.isStartOfExpression()&&(t=this.parseAssignmentExpression()),this.context.allowYield=i}return this.finalize(e,new o.YieldExpression(t,n))},e.prototype.parseClassElement=function(e){var t=this.lookahead,n=this.createNode(),i="",r=null,s=null,u=!1,l=!1,c=!1,h=!1;if(this.match("*"))this.nextToken();else if(u=this.match("["),"static"===(r=this.parseObjectPropertyKey()).name&&(this.qualifiedPropertyName(this.lookahead)||this.match("*"))&&(t=this.lookahead,c=!0,u=this.match("["),this.match("*")?this.nextToken():r=this.parseObjectPropertyKey()),3===t.type&&!this.hasLineTerminator&&"async"===t.value){var d=this.lookahead.value;":"!==d&&"("!==d&&"*"!==d&&(h=!0,t=this.lookahead,r=this.parseObjectPropertyKey(),3===t.type&&"constructor"===t.value&&this.tolerateUnexpectedToken(t,a.Messages.ConstructorIsAsync))}var p=this.qualifiedPropertyName(this.lookahead);return 3===t.type?"get"===t.value&&p?(i="get",u=this.match("["),r=this.parseObjectPropertyKey(),this.context.allowYield=!1,s=this.parseGetterMethod()):"set"===t.value&&p&&(i="set",u=this.match("["),r=this.parseObjectPropertyKey(),s=this.parseSetterMethod()):7===t.type&&"*"===t.value&&p&&(i="init",u=this.match("["),r=this.parseObjectPropertyKey(),s=this.parseGeneratorMethod(),l=!0),!i&&r&&this.match("(")&&(i="init",s=h?this.parsePropertyMethodAsyncFunction():this.parsePropertyMethodFunction(),l=!0),i||this.throwUnexpectedToken(this.lookahead),"init"===i&&(i="method"),u||(c&&this.isPropertyKey(r,"prototype")&&this.throwUnexpectedToken(t,a.Messages.StaticPrototype),!c&&this.isPropertyKey(r,"constructor")&&(("method"!==i||!l||s&&s.generator)&&this.throwUnexpectedToken(t,a.Messages.ConstructorSpecialMethod),e.value?this.throwUnexpectedToken(t,a.Messages.DuplicateConstructor):e.value=!0,i="constructor")),this.finalize(n,new o.MethodDefinition(r,u,s,i,c))},e.prototype.parseClassElementList=function(){var e=[],t={value:!1};for(this.expect("{");!this.match("}");)this.match(";")?this.nextToken():e.push(this.parseClassElement(t));return this.expect("}"),e},e.prototype.parseClassBody=function(){var e=this.createNode(),t=this.parseClassElementList();return this.finalize(e,new o.ClassBody(t))},e.prototype.parseClassDeclaration=function(e){var t=this.createNode(),n=this.context.strict;this.context.strict=!0,this.expectKeyword("class");var i=e&&3!==this.lookahead.type?null:this.parseVariableIdentifier(),r=null;this.matchKeyword("extends")&&(this.nextToken(),r=this.isolateCoverGrammar(this.parseLeftHandSideExpressionAllowCall));var a=this.parseClassBody();return this.context.strict=n,this.finalize(t,new o.ClassDeclaration(i,r,a))},e.prototype.parseClassExpression=function(){var e=this.createNode(),t=this.context.strict;this.context.strict=!0,this.expectKeyword("class");var n=3===this.lookahead.type?this.parseVariableIdentifier():null,i=null;this.matchKeyword("extends")&&(this.nextToken(),i=this.isolateCoverGrammar(this.parseLeftHandSideExpressionAllowCall));var r=this.parseClassBody();return this.context.strict=t,this.finalize(e,new o.ClassExpression(n,i,r))},e.prototype.parseModule=function(){this.context.strict=!0,this.context.isModule=!0,this.scanner.isModule=!0;for(var e=this.createNode(),t=this.parseDirectivePrologues();2!==this.lookahead.type;)t.push(this.parseStatementListItem());return this.finalize(e,new o.Module(t))},e.prototype.parseScript=function(){for(var e=this.createNode(),t=this.parseDirectivePrologues();2!==this.lookahead.type;)t.push(this.parseStatementListItem());return this.finalize(e,new o.Script(t))},e.prototype.parseModuleSpecifier=function(){var e=this.createNode();8!==this.lookahead.type&&this.throwError(a.Messages.InvalidModuleSpecifier);var t=this.nextToken(),n=this.getTokenRaw(t);return this.finalize(e,new o.Literal(t.value,n))},e.prototype.parseImportSpecifier=function(){var e,t,n=this.createNode();return 3===this.lookahead.type?(t=e=this.parseVariableIdentifier(),this.matchContextualKeyword("as")&&(this.nextToken(),t=this.parseVariableIdentifier())):(t=e=this.parseIdentifierName(),this.matchContextualKeyword("as")?(this.nextToken(),t=this.parseVariableIdentifier()):this.throwUnexpectedToken(this.nextToken())),this.finalize(n,new o.ImportSpecifier(t,e))},e.prototype.parseNamedImports=function(){this.expect("{");for(var e=[];!this.match("}");)e.push(this.parseImportSpecifier()),this.match("}")||this.expect(",");return this.expect("}"),e},e.prototype.parseImportDefaultSpecifier=function(){var e=this.createNode(),t=this.parseIdentifierName();return this.finalize(e,new o.ImportDefaultSpecifier(t))},e.prototype.parseImportNamespaceSpecifier=function(){var e=this.createNode();this.expect("*"),this.matchContextualKeyword("as")||this.throwError(a.Messages.NoAsAfterImportNamespace),this.nextToken();var t=this.parseIdentifierName();return this.finalize(e,new o.ImportNamespaceSpecifier(t))},e.prototype.parseImportDeclaration=function(){this.context.inFunctionBody&&this.throwError(a.Messages.IllegalImportDeclaration);var e,t=this.createNode();this.expectKeyword("import");var n=[];if(8===this.lookahead.type)e=this.parseModuleSpecifier();else{if(this.match("{")?n=n.concat(this.parseNamedImports()):this.match("*")?n.push(this.parseImportNamespaceSpecifier()):this.isIdentifierName(this.lookahead)&&!this.matchKeyword("default")?(n.push(this.parseImportDefaultSpecifier()),this.match(",")&&(this.nextToken(),this.match("*")?n.push(this.parseImportNamespaceSpecifier()):this.match("{")?n=n.concat(this.parseNamedImports()):this.throwUnexpectedToken(this.lookahead))):this.throwUnexpectedToken(this.nextToken()),!this.matchContextualKeyword("from")){var i=this.lookahead.value?a.Messages.UnexpectedToken:a.Messages.MissingFromClause;this.throwError(i,this.lookahead.value)}this.nextToken(),e=this.parseModuleSpecifier()}return this.consumeSemicolon(),this.finalize(t,new o.ImportDeclaration(n,e))},e.prototype.parseExportSpecifier=function(){var e=this.createNode(),t=this.parseIdentifierName(),n=t;return this.matchContextualKeyword("as")&&(this.nextToken(),n=this.parseIdentifierName()),this.finalize(e,new o.ExportSpecifier(t,n))},e.prototype.parseExportDeclaration=function(){this.context.inFunctionBody&&this.throwError(a.Messages.IllegalExportDeclaration);var e,t=this.createNode();if(this.expectKeyword("export"),this.matchKeyword("default"))if(this.nextToken(),this.matchKeyword("function")){var n=this.parseFunctionDeclaration(!0);e=this.finalize(t,new o.ExportDefaultDeclaration(n))}else this.matchKeyword("class")?(n=this.parseClassDeclaration(!0),e=this.finalize(t,new o.ExportDefaultDeclaration(n))):this.matchContextualKeyword("async")?(n=this.matchAsyncFunction()?this.parseFunctionDeclaration(!0):this.parseAssignmentExpression(),e=this.finalize(t,new o.ExportDefaultDeclaration(n))):(this.matchContextualKeyword("from")&&this.throwError(a.Messages.UnexpectedToken,this.lookahead.value),n=this.match("{")?this.parseObjectInitializer():this.match("[")?this.parseArrayInitializer():this.parseAssignmentExpression(),this.consumeSemicolon(),e=this.finalize(t,new o.ExportDefaultDeclaration(n)));else if(this.match("*")){if(this.nextToken(),!this.matchContextualKeyword("from")){var i=this.lookahead.value?a.Messages.UnexpectedToken:a.Messages.MissingFromClause;this.throwError(i,this.lookahead.value)}this.nextToken();var r=this.parseModuleSpecifier();this.consumeSemicolon(),e=this.finalize(t,new o.ExportAllDeclaration(r))}else if(4===this.lookahead.type){switch(n=void 0,this.lookahead.value){case"let":case"const":n=this.parseLexicalDeclaration({inFor:!1});break;case"var":case"class":case"function":n=this.parseStatementListItem();break;default:this.throwUnexpectedToken(this.lookahead)}e=this.finalize(t,new o.ExportNamedDeclaration(n,[],null))}else if(this.matchAsyncFunction())n=this.parseFunctionDeclaration(),e=this.finalize(t,new o.ExportNamedDeclaration(n,[],null));else{var s=[],u=null,l=!1;for(this.expect("{");!this.match("}");)l=l||this.matchKeyword("default"),s.push(this.parseExportSpecifier()),this.match("}")||this.expect(",");this.expect("}"),this.matchContextualKeyword("from")?(this.nextToken(),u=this.parseModuleSpecifier(),this.consumeSemicolon()):l?(i=this.lookahead.value?a.Messages.UnexpectedToken:a.Messages.MissingFromClause,this.throwError(i,this.lookahead.value)):this.consumeSemicolon(),e=this.finalize(t,new o.ExportNamedDeclaration(null,s,u))}return e},e}();t.Parser=h},function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.assert=function(e,t){if(!e)throw new Error("ASSERT: "+t)}},function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(){this.errors=[],this.tolerant=!1}return e.prototype.recordError=function(e){this.errors.push(e)},e.prototype.tolerate=function(e){if(!this.tolerant)throw e;this.recordError(e)},e.prototype.constructError=function(e,t){var n=new Error(e);try{throw n}catch(e){Object.create&&Object.defineProperty&&(n=Object.create(e),Object.defineProperty(n,"column",{value:t}))}return n},e.prototype.createError=function(e,t,n,i){var r="Line "+t+": "+i,a=this.constructError(r,n);return a.index=e,a.lineNumber=t,a.description=i,a},e.prototype.throwError=function(e,t,n,i){throw this.createError(e,t,n,i)},e.prototype.tolerateError=function(e,t,n,i){var r=this.createError(e,t,n,i);if(!this.tolerant)throw r;this.recordError(r)},e}();t.ErrorHandler=n},function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.Messages={BadGetterArity:"Getter must not have any formal parameters",BadSetterArity:"Setter must have exactly one formal parameter",BadSetterRestParameter:"Setter function argument must not be a rest parameter",ConstructorIsAsync:"Class constructor may not be an async method",ConstructorSpecialMethod:"Class constructor may not be an accessor",DeclarationMissingInitializer:"Missing initializer in %0 declaration",DefaultRestParameter:"Unexpected token =",DuplicateBinding:"Duplicate binding %0",DuplicateConstructor:"A class may only have one constructor",DuplicateProtoProperty:"Duplicate __proto__ fields are not allowed in object literals",ForInOfLoopInitializer:"%0 loop variable declaration may not have an initializer",GeneratorInLegacyContext:"Generator declarations are not allowed in legacy contexts",IllegalBreak:"Illegal break statement",IllegalContinue:"Illegal continue statement",IllegalExportDeclaration:"Unexpected token",IllegalImportDeclaration:"Unexpected token",IllegalLanguageModeDirective:"Illegal 'use strict' directive in function with non-simple parameter list",IllegalReturn:"Illegal return statement",InvalidEscapedReservedWord:"Keyword must not contain escaped characters",InvalidHexEscapeSequence:"Invalid hexadecimal escape sequence",InvalidLHSInAssignment:"Invalid left-hand side in assignment",InvalidLHSInForIn:"Invalid left-hand side in for-in",InvalidLHSInForLoop:"Invalid left-hand side in for-loop",InvalidModuleSpecifier:"Unexpected token",InvalidRegExp:"Invalid regular expression",LetInLexicalBinding:"let is disallowed as a lexically bound name",MissingFromClause:"Unexpected token",MultipleDefaultsInSwitch:"More than one default clause in switch statement",NewlineAfterThrow:"Illegal newline after throw",NoAsAfterImportNamespace:"Unexpected token",NoCatchOrFinally:"Missing catch or finally after try",ParameterAfterRestParameter:"Rest parameter must be last formal parameter",Redeclaration:"%0 '%1' has already been declared",StaticPrototype:"Classes may not have static property named prototype",StrictCatchVariable:"Catch variable may not be eval or arguments in strict mode",StrictDelete:"Delete of an unqualified identifier in strict mode.",StrictFunction:"In strict mode code, functions can only be declared at top level or inside a block",StrictFunctionName:"Function name may not be eval or arguments in strict mode",StrictLHSAssignment:"Assignment to eval or arguments is not allowed in strict mode",StrictLHSPostfix:"Postfix increment/decrement may not have eval or arguments operand in strict mode",StrictLHSPrefix:"Prefix increment/decrement may not have eval or arguments operand in strict mode",StrictModeWith:"Strict mode code may not include a with statement",StrictOctalLiteral:"Octal literals are not allowed in strict mode.",StrictParamDupe:"Strict mode function may not have duplicate parameter names",StrictParamName:"Parameter name eval or arguments is not allowed in strict mode",StrictReservedWord:"Use of future reserved word in strict mode",StrictVarName:"Variable name may not be eval or arguments in strict mode",TemplateOctalLiteral:"Octal literals are not allowed in template strings.",UnexpectedEOS:"Unexpected end of input",UnexpectedIdentifier:"Unexpected identifier",UnexpectedNumber:"Unexpected number",UnexpectedReserved:"Unexpected reserved word",UnexpectedString:"Unexpected string",UnexpectedTemplate:"Unexpected quasi %0",UnexpectedToken:"Unexpected token %0",UnexpectedTokenIllegal:"Unexpected token ILLEGAL",UnknownLabel:"Undefined label '%0'",UnterminatedRegExp:"Invalid regular expression: missing /"}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var i=n(9),r=n(4),a=n(11);function o(e){return"0123456789abcdef".indexOf(e.toLowerCase())}function s(e){return"01234567".indexOf(e)}var u=function(){function e(e,t){this.source=e,this.errorHandler=t,this.trackComment=!1,this.isModule=!1,this.length=e.length,this.index=0,this.lineNumber=e.length>0?1:0,this.lineStart=0,this.curlyStack=[]}return e.prototype.saveState=function(){return{index:this.index,lineNumber:this.lineNumber,lineStart:this.lineStart}},e.prototype.restoreState=function(e){this.index=e.index,this.lineNumber=e.lineNumber,this.lineStart=e.lineStart},e.prototype.eof=function(){return this.index>=this.length},e.prototype.throwUnexpectedToken=function(e){return void 0===e&&(e=a.Messages.UnexpectedTokenIllegal),this.errorHandler.throwError(this.index,this.lineNumber,this.index-this.lineStart+1,e)},e.prototype.tolerateUnexpectedToken=function(e){void 0===e&&(e=a.Messages.UnexpectedTokenIllegal),this.errorHandler.tolerateError(this.index,this.lineNumber,this.index-this.lineStart+1,e)},e.prototype.skipSingleLineComment=function(e){var t,n,i=[];for(this.trackComment&&(i=[],t=this.index-e,n={start:{line:this.lineNumber,column:this.index-this.lineStart-e},end:{}});!this.eof();){var a=this.source.charCodeAt(this.index);if(++this.index,r.Character.isLineTerminator(a)){if(this.trackComment){n.end={line:this.lineNumber,column:this.index-this.lineStart-1};var o={multiLine:!1,slice:[t+e,this.index-1],range:[t,this.index-1],loc:n};i.push(o)}return 13===a&&10===this.source.charCodeAt(this.index)&&++this.index,++this.lineNumber,this.lineStart=this.index,i}}return this.trackComment&&(n.end={line:this.lineNumber,column:this.index-this.lineStart},o={multiLine:!1,slice:[t+e,this.index],range:[t,this.index],loc:n},i.push(o)),i},e.prototype.skipMultiLineComment=function(){var e,t,n=[];for(this.trackComment&&(n=[],e=this.index-2,t={start:{line:this.lineNumber,column:this.index-this.lineStart-2},end:{}});!this.eof();){var i=this.source.charCodeAt(this.index);if(r.Character.isLineTerminator(i))13===i&&10===this.source.charCodeAt(this.index+1)&&++this.index,++this.lineNumber,++this.index,this.lineStart=this.index;else if(42===i){if(47===this.source.charCodeAt(this.index+1)){if(this.index+=2,this.trackComment){t.end={line:this.lineNumber,column:this.index-this.lineStart};var a={multiLine:!0,slice:[e+2,this.index-2],range:[e,this.index],loc:t};n.push(a)}return n}++this.index}else++this.index}return this.trackComment&&(t.end={line:this.lineNumber,column:this.index-this.lineStart},a={multiLine:!0,slice:[e+2,this.index],range:[e,this.index],loc:t},n.push(a)),this.tolerateUnexpectedToken(),n},e.prototype.scanComments=function(){var e;this.trackComment&&(e=[]);for(var t=0===this.index;!this.eof();){var n=this.source.charCodeAt(this.index);if(r.Character.isWhiteSpace(n))++this.index;else if(r.Character.isLineTerminator(n))++this.index,13===n&&10===this.source.charCodeAt(this.index)&&++this.index,++this.lineNumber,this.lineStart=this.index,t=!0;else if(47===n)if(47===(n=this.source.charCodeAt(this.index+1))){this.index+=2;var i=this.skipSingleLineComment(2);this.trackComment&&(e=e.concat(i)),t=!0}else{if(42!==n)break;this.index+=2,i=this.skipMultiLineComment(),this.trackComment&&(e=e.concat(i))}else if(t&&45===n){if(45!==this.source.charCodeAt(this.index+1)||62!==this.source.charCodeAt(this.index+2))break;this.index+=3,i=this.skipSingleLineComment(3),this.trackComment&&(e=e.concat(i))}else{if(60!==n||this.isModule)break;if("!--"!==this.source.slice(this.index+1,this.index+4))break;this.index+=4,i=this.skipSingleLineComment(4),this.trackComment&&(e=e.concat(i))}}return e},e.prototype.isFutureReservedWord=function(e){switch(e){case"enum":case"export":case"import":case"super":return!0;default:return!1}},e.prototype.isStrictModeReservedWord=function(e){switch(e){case"implements":case"interface":case"package":case"private":case"protected":case"public":case"static":case"yield":case"let":return!0;default:return!1}},e.prototype.isRestrictedWord=function(e){return"eval"===e||"arguments"===e},e.prototype.isKeyword=function(e){switch(e.length){case 2:return"if"===e||"in"===e||"do"===e;case 3:return"var"===e||"for"===e||"new"===e||"try"===e||"let"===e;case 4:return"this"===e||"else"===e||"case"===e||"void"===e||"with"===e||"enum"===e;case 5:return"while"===e||"break"===e||"catch"===e||"throw"===e||"const"===e||"yield"===e||"class"===e||"super"===e;case 6:return"return"===e||"typeof"===e||"delete"===e||"switch"===e||"export"===e||"import"===e;case 7:return"default"===e||"finally"===e||"extends"===e;case 8:return"function"===e||"continue"===e||"debugger"===e;case 10:return"instanceof"===e;default:return!1}},e.prototype.codePointAt=function(e){var t=this.source.charCodeAt(e);if(t>=55296&&t<=56319){var n=this.source.charCodeAt(e+1);n>=56320&&n<=57343&&(t=1024*(t-55296)+n-56320+65536)}return t},e.prototype.scanHexEscape=function(e){for(var t="u"===e?4:2,n=0,i=0;i<t;++i){if(this.eof()||!r.Character.isHexDigit(this.source.charCodeAt(this.index)))return null;n=16*n+o(this.source[this.index++])}return String.fromCharCode(n)},e.prototype.scanUnicodeCodePointEscape=function(){var e=this.source[this.index],t=0;for("}"===e&&this.throwUnexpectedToken();!this.eof()&&(e=this.source[this.index++],r.Character.isHexDigit(e.charCodeAt(0)));)t=16*t+o(e);return(t>1114111||"}"!==e)&&this.throwUnexpectedToken(),r.Character.fromCodePoint(t)},e.prototype.getIdentifier=function(){for(var e=this.index++;!this.eof();){var t=this.source.charCodeAt(this.index);if(92===t)return this.index=e,this.getComplexIdentifier();if(t>=55296&&t<57343)return this.index=e,this.getComplexIdentifier();if(!r.Character.isIdentifierPart(t))break;++this.index}return this.source.slice(e,this.index)},e.prototype.getComplexIdentifier=function(){var e,t=this.codePointAt(this.index),n=r.Character.fromCodePoint(t);for(this.index+=n.length,92===t&&(117!==this.source.charCodeAt(this.index)&&this.throwUnexpectedToken(),++this.index,"{"===this.source[this.index]?(++this.index,e=this.scanUnicodeCodePointEscape()):null!==(e=this.scanHexEscape("u"))&&"\\"!==e&&r.Character.isIdentifierStart(e.charCodeAt(0))||this.throwUnexpectedToken(),n=e);!this.eof()&&(t=this.codePointAt(this.index),r.Character.isIdentifierPart(t));)n+=e=r.Character.fromCodePoint(t),this.index+=e.length,92===t&&(n=n.substr(0,n.length-1),117!==this.source.charCodeAt(this.index)&&this.throwUnexpectedToken(),++this.index,"{"===this.source[this.index]?(++this.index,e=this.scanUnicodeCodePointEscape()):null!==(e=this.scanHexEscape("u"))&&"\\"!==e&&r.Character.isIdentifierPart(e.charCodeAt(0))||this.throwUnexpectedToken(),n+=e);return n},e.prototype.octalToDecimal=function(e){var t="0"!==e,n=s(e);return!this.eof()&&r.Character.isOctalDigit(this.source.charCodeAt(this.index))&&(t=!0,n=8*n+s(this.source[this.index++]),"0123".indexOf(e)>=0&&!this.eof()&&r.Character.isOctalDigit(this.source.charCodeAt(this.index))&&(n=8*n+s(this.source[this.index++]))),{code:n,octal:t}},e.prototype.scanIdentifier=function(){var e,t=this.index,n=92===this.source.charCodeAt(t)?this.getComplexIdentifier():this.getIdentifier();if(3!=(e=1===n.length?3:this.isKeyword(n)?4:"null"===n?5:"true"===n||"false"===n?1:3)&&t+n.length!==this.index){var i=this.index;this.index=t,this.tolerateUnexpectedToken(a.Messages.InvalidEscapedReservedWord),this.index=i}return{type:e,value:n,lineNumber:this.lineNumber,lineStart:this.lineStart,start:t,end:this.index}},e.prototype.scanPunctuator=function(){var e=this.index,t=this.source[this.index];switch(t){case"(":case"{":"{"===t&&this.curlyStack.push("{"),++this.index;break;case".":++this.index,"."===this.source[this.index]&&"."===this.source[this.index+1]&&(this.index+=2,t="...");break;case"}":++this.index,this.curlyStack.pop();break;case")":case";":case",":case"[":case"]":case":":case"?":case"~":++this.index;break;default:">>>="===(t=this.source.substr(this.index,4))?this.index+=4:"==="===(t=t.substr(0,3))||"!=="===t||">>>"===t||"<<="===t||">>="===t||"**="===t?this.index+=3:"&&"===(t=t.substr(0,2))||"||"===t||"=="===t||"!="===t||"+="===t||"-="===t||"*="===t||"/="===t||"++"===t||"--"===t||"<<"===t||">>"===t||"&="===t||"|="===t||"^="===t||"%="===t||"<="===t||">="===t||"=>"===t||"**"===t?this.index+=2:(t=this.source[this.index],"<>=!+-*%&|^/".indexOf(t)>=0&&++this.index)}return this.index===e&&this.throwUnexpectedToken(),{type:7,value:t,lineNumber:this.lineNumber,lineStart:this.lineStart,start:e,end:this.index}},e.prototype.scanHexLiteral=function(e){for(var t="";!this.eof()&&r.Character.isHexDigit(this.source.charCodeAt(this.index));)t+=this.source[this.index++];return 0===t.length&&this.throwUnexpectedToken(),r.Character.isIdentifierStart(this.source.charCodeAt(this.index))&&this.throwUnexpectedToken(),{type:6,value:parseInt("0x"+t,16),lineNumber:this.lineNumber,lineStart:this.lineStart,start:e,end:this.index}},e.prototype.scanBinaryLiteral=function(e){for(var t,n="";!this.eof()&&("0"===(t=this.source[this.index])||"1"===t);)n+=this.source[this.index++];return 0===n.length&&this.throwUnexpectedToken(),this.eof()||(t=this.source.charCodeAt(this.index),(r.Character.isIdentifierStart(t)||r.Character.isDecimalDigit(t))&&this.throwUnexpectedToken()),{type:6,value:parseInt(n,2),lineNumber:this.lineNumber,lineStart:this.lineStart,start:e,end:this.index}},e.prototype.scanOctalLiteral=function(e,t){var n="",i=!1;for(r.Character.isOctalDigit(e.charCodeAt(0))?(i=!0,n="0"+this.source[this.index++]):++this.index;!this.eof()&&r.Character.isOctalDigit(this.source.charCodeAt(this.index));)n+=this.source[this.index++];return i||0!==n.length||this.throwUnexpectedToken(),(r.Character.isIdentifierStart(this.source.charCodeAt(this.index))||r.Character.isDecimalDigit(this.source.charCodeAt(this.index)))&&this.throwUnexpectedToken(),{type:6,value:parseInt(n,8),octal:i,lineNumber:this.lineNumber,lineStart:this.lineStart,start:t,end:this.index}},e.prototype.isImplicitOctalLiteral=function(){for(var e=this.index+1;e<this.length;++e){var t=this.source[e];if("8"===t||"9"===t)return!1;if(!r.Character.isOctalDigit(t.charCodeAt(0)))return!0}return!0},e.prototype.scanNumericLiteral=function(){var e=this.index,t=this.source[e];i.assert(r.Character.isDecimalDigit(t.charCodeAt(0))||"."===t,"Numeric literal must start with a decimal digit or a decimal point");var n="";if("."!==t){if(n=this.source[this.index++],t=this.source[this.index],"0"===n){if("x"===t||"X"===t)return++this.index,this.scanHexLiteral(e);if("b"===t||"B"===t)return++this.index,this.scanBinaryLiteral(e);if("o"===t||"O"===t)return this.scanOctalLiteral(t,e);if(t&&r.Character.isOctalDigit(t.charCodeAt(0))&&this.isImplicitOctalLiteral())return this.scanOctalLiteral(t,e)}for(;r.Character.isDecimalDigit(this.source.charCodeAt(this.index));)n+=this.source[this.index++];t=this.source[this.index]}if("."===t){for(n+=this.source[this.index++];r.Character.isDecimalDigit(this.source.charCodeAt(this.index));)n+=this.source[this.index++];t=this.source[this.index]}if("e"===t||"E"===t)if(n+=this.source[this.index++],"+"!==(t=this.source[this.index])&&"-"!==t||(n+=this.source[this.index++]),r.Character.isDecimalDigit(this.source.charCodeAt(this.index)))for(;r.Character.isDecimalDigit(this.source.charCodeAt(this.index));)n+=this.source[this.index++];else this.throwUnexpectedToken();return r.Character.isIdentifierStart(this.source.charCodeAt(this.index))&&this.throwUnexpectedToken(),{type:6,value:parseFloat(n),lineNumber:this.lineNumber,lineStart:this.lineStart,start:e,end:this.index}},e.prototype.scanStringLiteral=function(){var e=this.index,t=this.source[e];i.assert("'"===t||'"'===t,"String literal must starts with a quote"),++this.index;for(var n=!1,o="";!this.eof();){var s=this.source[this.index++];if(s===t){t="";break}if("\\"===s)if((s=this.source[this.index++])&&r.Character.isLineTerminator(s.charCodeAt(0)))++this.lineNumber,"\r"===s&&"\n"===this.source[this.index]&&++this.index,this.lineStart=this.index;else switch(s){case"u":if("{"===this.source[this.index])++this.index,o+=this.scanUnicodeCodePointEscape();else{var u=this.scanHexEscape(s);null===u&&this.throwUnexpectedToken(),o+=u}break;case"x":var l=this.scanHexEscape(s);null===l&&this.throwUnexpectedToken(a.Messages.InvalidHexEscapeSequence),o+=l;break;case"n":o+="\n";break;case"r":o+="\r";break;case"t":o+="\t";break;case"b":o+="\b";break;case"f":o+="\f";break;case"v":o+="\v";break;case"8":case"9":o+=s,this.tolerateUnexpectedToken();break;default:if(s&&r.Character.isOctalDigit(s.charCodeAt(0))){var c=this.octalToDecimal(s);n=c.octal||n,o+=String.fromCharCode(c.code)}else o+=s}else{if(r.Character.isLineTerminator(s.charCodeAt(0)))break;o+=s}}return""!==t&&(this.index=e,this.throwUnexpectedToken()),{type:8,value:o,octal:n,lineNumber:this.lineNumber,lineStart:this.lineStart,start:e,end:this.index}},e.prototype.scanTemplate=function(){var e="",t=!1,n=this.index,i="`"===this.source[n],o=!1,s=2;for(++this.index;!this.eof();){var u=this.source[this.index++];if("`"===u){s=1,o=!0,t=!0;break}if("$"===u){if("{"===this.source[this.index]){this.curlyStack.push("${"),++this.index,t=!0;break}e+=u}else if("\\"===u)if(u=this.source[this.index++],r.Character.isLineTerminator(u.charCodeAt(0)))++this.lineNumber,"\r"===u&&"\n"===this.source[this.index]&&++this.index,this.lineStart=this.index;else switch(u){case"n":e+="\n";break;case"r":e+="\r";break;case"t":e+="\t";break;case"u":if("{"===this.source[this.index])++this.index,e+=this.scanUnicodeCodePointEscape();else{var l=this.index,c=this.scanHexEscape(u);null!==c?e+=c:(this.index=l,e+=u)}break;case"x":var h=this.scanHexEscape(u);null===h&&this.throwUnexpectedToken(a.Messages.InvalidHexEscapeSequence),e+=h;break;case"b":e+="\b";break;case"f":e+="\f";break;case"v":e+="\v";break;default:"0"===u?(r.Character.isDecimalDigit(this.source.charCodeAt(this.index))&&this.throwUnexpectedToken(a.Messages.TemplateOctalLiteral),e+="\0"):r.Character.isOctalDigit(u.charCodeAt(0))?this.throwUnexpectedToken(a.Messages.TemplateOctalLiteral):e+=u}else r.Character.isLineTerminator(u.charCodeAt(0))?(++this.lineNumber,"\r"===u&&"\n"===this.source[this.index]&&++this.index,this.lineStart=this.index,e+="\n"):e+=u}return t||this.throwUnexpectedToken(),i||this.curlyStack.pop(),{type:10,value:this.source.slice(n+1,this.index-s),cooked:e,head:i,tail:o,lineNumber:this.lineNumber,lineStart:this.lineStart,start:n,end:this.index}},e.prototype.testRegExp=function(e,t){var n=e,i=this;t.indexOf("u")>=0&&(n=n.replace(/\\u\{([0-9a-fA-F]+)\}|\\u([a-fA-F0-9]{4})/g,function(e,t,n){var r=parseInt(t||n,16);return r>1114111&&i.throwUnexpectedToken(a.Messages.InvalidRegExp),r<=65535?String.fromCharCode(r):"\ufffd"}).replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,"\ufffd"));try{RegExp(n)}catch(e){this.throwUnexpectedToken(a.Messages.InvalidRegExp)}try{return new RegExp(e,t)}catch(e){return null}},e.prototype.scanRegExpBody=function(){var e=this.source[this.index];i.assert("/"===e,"Regular expression literal must start with a slash");for(var t=this.source[this.index++],n=!1,o=!1;!this.eof();)if(t+=e=this.source[this.index++],"\\"===e)e=this.source[this.index++],r.Character.isLineTerminator(e.charCodeAt(0))&&this.throwUnexpectedToken(a.Messages.UnterminatedRegExp),t+=e;else if(r.Character.isLineTerminator(e.charCodeAt(0)))this.throwUnexpectedToken(a.Messages.UnterminatedRegExp);else if(n)"]"===e&&(n=!1);else{if("/"===e){o=!0;break}"["===e&&(n=!0)}return o||this.throwUnexpectedToken(a.Messages.UnterminatedRegExp),t.substr(1,t.length-2)},e.prototype.scanRegExpFlags=function(){for(var e="";!this.eof();){var t=this.source[this.index];if(!r.Character.isIdentifierPart(t.charCodeAt(0)))break;if(++this.index,"\\"!==t||this.eof())e+=t;else if("u"===(t=this.source[this.index])){++this.index;var n=this.index,i=this.scanHexEscape("u");if(null!==i)for(e+=i;n<this.index;++n)this.source[n];else this.index=n,e+="u";this.tolerateUnexpectedToken()}else this.tolerateUnexpectedToken()}return e},e.prototype.scanRegExp=function(){var e=this.index,t=this.scanRegExpBody(),n=this.scanRegExpFlags();return{type:9,value:"",pattern:t,flags:n,regex:this.testRegExp(t,n),lineNumber:this.lineNumber,lineStart:this.lineStart,start:e,end:this.index}},e.prototype.lex=function(){if(this.eof())return{type:2,value:"",lineNumber:this.lineNumber,lineStart:this.lineStart,start:this.index,end:this.index};var e=this.source.charCodeAt(this.index);return r.Character.isIdentifierStart(e)?this.scanIdentifier():40===e||41===e||59===e?this.scanPunctuator():39===e||34===e?this.scanStringLiteral():46===e?r.Character.isDecimalDigit(this.source.charCodeAt(this.index+1))?this.scanNumericLiteral():this.scanPunctuator():r.Character.isDecimalDigit(e)?this.scanNumericLiteral():96===e||125===e&&"${"===this.curlyStack[this.curlyStack.length-1]?this.scanTemplate():e>=55296&&e<57343&&r.Character.isIdentifierStart(this.codePointAt(this.index))?this.scanIdentifier():this.scanPunctuator()},e}();t.Scanner=u},function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.TokenName={},t.TokenName[1]="Boolean",t.TokenName[2]="<end>",t.TokenName[3]="Identifier",t.TokenName[4]="Keyword",t.TokenName[5]="Null",t.TokenName[6]="Numeric",t.TokenName[7]="Punctuator",t.TokenName[8]="String",t.TokenName[9]="RegularExpression",t.TokenName[10]="Template"},function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.XHTMLEntities={quot:'"',amp:"&",apos:"'",gt:">",nbsp:" ",iexcl:"¡",cent:"¢",pound:"£",curren:"¤",yen:"¥",brvbar:"¦",sect:"§",uml:"¨",copy:"©",ordf:"ª",laquo:"«",not:"¬",shy:"",reg:"®",macr:"¯",deg:"°",plusmn:"±",sup2:"²",sup3:"³",acute:"´",micro:"µ",para:"¶",middot:"·",cedil:"¸",sup1:"¹",ordm:"º",raquo:"»",frac14:"¼",frac12:"½",frac34:"¾",iquest:"¿",Agrave:"À",Aacute:"Á",Acirc:"Â",Atilde:"Ã",Auml:"Ä",Aring:"Å",AElig:"Æ",Ccedil:"Ç",Egrave:"È",Eacute:"É",Ecirc:"Ê",Euml:"Ë",Igrave:"Ì",Iacute:"Í",Icirc:"Î",Iuml:"Ï",ETH:"Ð",Ntilde:"Ñ",Ograve:"Ò",Oacute:"Ó",Ocirc:"Ô",Otilde:"Õ",Ouml:"Ö",times:"×",Oslash:"Ø",Ugrave:"Ù",Uacute:"Ú",Ucirc:"Û",Uuml:"Ü",Yacute:"Ý",THORN:"Þ",szlig:"ß",agrave:"à",aacute:"á",acirc:"â",atilde:"ã",auml:"ä",aring:"å",aelig:"æ",ccedil:"ç",egrave:"è",eacute:"é",ecirc:"ê",euml:"ë",igrave:"ì",iacute:"í",icirc:"î",iuml:"ï",eth:"ð",ntilde:"ñ",ograve:"ò",oacute:"ó",ocirc:"ô",otilde:"õ",ouml:"ö",divide:"÷",oslash:"ø",ugrave:"ù",uacute:"ú",ucirc:"û",uuml:"ü",yacute:"ý",thorn:"þ",yuml:"ÿ",OElig:"Œ",oelig:"œ",Scaron:"Š",scaron:"š",Yuml:"Ÿ",fnof:"ƒ",circ:"ˆ",tilde:"˜",Alpha:"Α",Beta:"Β",Gamma:"Γ",Delta:"Δ",Epsilon:"Ε",Zeta:"Ζ",Eta:"Η",Theta:"Θ",Iota:"Ι",Kappa:"Κ",Lambda:"Λ",Mu:"Μ",Nu:"Ν",Xi:"Ξ",Omicron:"Ο",Pi:"Π",Rho:"Ρ",Sigma:"Σ",Tau:"Τ",Upsilon:"Υ",Phi:"Φ",Chi:"Χ",Psi:"Ψ",Omega:"Ω",alpha:"α",beta:"β",gamma:"γ",delta:"δ",epsilon:"ε",zeta:"ζ",eta:"η",theta:"θ",iota:"ι",kappa:"κ",lambda:"λ",mu:"μ",nu:"ν",xi:"ξ",omicron:"ο",pi:"π",rho:"ρ",sigmaf:"ς",sigma:"σ",tau:"τ",upsilon:"υ",phi:"φ",chi:"χ",psi:"ψ",omega:"ω",thetasym:"ϑ",upsih:"ϒ",piv:"ϖ",ensp:" ",emsp:" ",thinsp:" ",zwnj:"",zwj:"",lrm:"",rlm:"",ndash:"–",mdash:"—",lsquo:"‘",rsquo:"’",sbquo:"‚",ldquo:"“",rdquo:"”",bdquo:"„",dagger:"†",Dagger:"‡",bull:"•",hellip:"…",permil:"‰",prime:"′",Prime:"″",lsaquo:"‹",rsaquo:"›",oline:"‾",frasl:"⁄",euro:"€",image:"ℑ",weierp:"℘",real:"ℜ",trade:"™",alefsym:"ℵ",larr:"←",uarr:"↑",rarr:"→",darr:"↓",harr:"↔",crarr:"↵",lArr:"⇐",uArr:"⇑",rArr:"⇒",dArr:"⇓",hArr:"⇔",forall:"∀",part:"∂",exist:"∃",empty:"∅",nabla:"∇",isin:"∈",notin:"∉",ni:"∋",prod:"∏",sum:"∑",minus:"−",lowast:"∗",radic:"√",prop:"∝",infin:"∞",ang:"∠",and:"∧",or:"∨",cap:"∩",cup:"∪",int:"∫",there4:"∴",sim:"∼",cong:"≅",asymp:"≈",ne:"≠",equiv:"≡",le:"≤",ge:"≥",sub:"⊂",sup:"⊃",nsub:"⊄",sube:"⊆",supe:"⊇",oplus:"⊕",otimes:"⊗",perp:"⊥",sdot:"⋅",lceil:"⌈",rceil:"⌉",lfloor:"⌊",rfloor:"⌋",loz:"◊",spades:"♠",clubs:"♣",hearts:"♥",diams:"♦",lang:"⟨",rang:"⟩"}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var i=n(10),r=n(12),a=n(13),o=function(){function e(){this.values=[],this.curly=this.paren=-1}return e.prototype.beforeFunctionExpression=function(e){return["(","{","[","in","typeof","instanceof","new","return","case","delete","throw","void","=","+=","-=","*=","**=","/=","%=","<<=",">>=",">>>=","&=","|=","^=",",","+","-","*","**","/","%","++","--","<<",">>",">>>","&","|","^","!","~","&&","||","?",":","===","==",">=","<=","<",">","!=","!=="].indexOf(e)>=0},e.prototype.isRegexStart=function(){var e=this.values[this.values.length-1],t=null!==e;switch(e){case"this":case"]":t=!1;break;case")":var n=this.values[this.paren-1];t="if"===n||"while"===n||"for"===n||"with"===n;break;case"}":if(t=!1,"function"===this.values[this.curly-3])t=!!(i=this.values[this.curly-4])&&!this.beforeFunctionExpression(i);else if("function"===this.values[this.curly-4]){var i;t=!(i=this.values[this.curly-5])||!this.beforeFunctionExpression(i)}}return t},e.prototype.push=function(e){7===e.type||4===e.type?("{"===e.value?this.curly=this.values.length:"("===e.value&&(this.paren=this.values.length),this.values.push(e.value)):this.values.push(null)},e}(),s=function(){function e(e,t){this.errorHandler=new i.ErrorHandler,this.errorHandler.tolerant=!!t&&"boolean"==typeof t.tolerant&&t.tolerant,this.scanner=new r.Scanner(e,this.errorHandler),this.scanner.trackComment=!!t&&"boolean"==typeof t.comment&&t.comment,this.trackRange=!!t&&"boolean"==typeof t.range&&t.range,this.trackLoc=!!t&&"boolean"==typeof t.loc&&t.loc,this.buffer=[],this.reader=new o}return e.prototype.errors=function(){return this.errorHandler.errors},e.prototype.getNextToken=function(){if(0===this.buffer.length){var e=this.scanner.scanComments();if(this.scanner.trackComment)for(var t=0;t<e.length;++t){var n=e[t],i=this.scanner.source.slice(n.slice[0],n.slice[1]),r={type:n.multiLine?"BlockComment":"LineComment",value:i};this.trackRange&&(r.range=n.range),this.trackLoc&&(r.loc=n.loc),this.buffer.push(r)}if(!this.scanner.eof()){var o=void 0;this.trackLoc&&(o={start:{line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart},end:{}});var s="/"===this.scanner.source[this.scanner.index]&&this.reader.isRegexStart()?this.scanner.scanRegExp():this.scanner.lex();this.reader.push(s);var u={type:a.TokenName[s.type],value:this.scanner.source.slice(s.start,s.end)};if(this.trackRange&&(u.range=[s.start,s.end]),this.trackLoc&&(o.end={line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart},u.loc=o),9===s.type){var l=s.pattern,c=s.flags;u.regex={pattern:l,flags:c}}this.buffer.push(u)}}return this.buffer.shift()},e}();t.Tokenizer=s}])},Ms.exports=Rs()),Ms.exports),_s=e(Os),Us={};var js=(Ls||(Ls=1,function e(t){var n,i,r,a,o,s;function u(e){var t,n,i={};for(t in e)e.hasOwnProperty(t)&&("object"===b(n=e[t])&&null!==n?i[t]=u(n):i[t]=n);return i}function l(e,t){this.parent=e,this.key=t}function c(e,t,n,i){this.node=e,this.path=t,this.wrap=n,this.ref=i}function h(){}function d(e){return null!=e&&"object"===b(e)&&"string"==typeof e.type}function p(e,t){return(e===n.ObjectExpression||e===n.ObjectPattern)&&"properties"===t}function f(e,t){for(var n=e.length-1;n>=0;--n)if(e[n].node===t)return!0;return!1}function m(e,t){return(new h).traverse(e,t)}function y(e,t){var n;return n=function(e,t){var n,i,r,a;for(i=e.length,r=0;i;)t(e[a=r+(n=i>>>1)])?i=n:(r=a+1,i-=n+1);return r}(t,function(t){return t.range[0]>e.range[0]}),e.extendedRange=[e.range[0],e.range[1]],n!==t.length&&(e.extendedRange[1]=t[n].range[0]),(n-=1)>=0&&(e.extendedRange[0]=t[n].range[1]),e}return n={AssignmentExpression:"AssignmentExpression",AssignmentPattern:"AssignmentPattern",ArrayExpression:"ArrayExpression",ArrayPattern:"ArrayPattern",ArrowFunctionExpression:"ArrowFunctionExpression",AwaitExpression:"AwaitExpression",BlockStatement:"BlockStatement",BinaryExpression:"BinaryExpression",BreakStatement:"BreakStatement",CallExpression:"CallExpression",CatchClause:"CatchClause",ChainExpression:"ChainExpression",ClassBody:"ClassBody",ClassDeclaration:"ClassDeclaration",ClassExpression:"ClassExpression",ComprehensionBlock:"ComprehensionBlock",ComprehensionExpression:"ComprehensionExpression",ConditionalExpression:"ConditionalExpression",ContinueStatement:"ContinueStatement",DebuggerStatement:"DebuggerStatement",DirectiveStatement:"DirectiveStatement",DoWhileStatement:"DoWhileStatement",EmptyStatement:"EmptyStatement",ExportAllDeclaration:"ExportAllDeclaration",ExportDefaultDeclaration:"ExportDefaultDeclaration",ExportNamedDeclaration:"ExportNamedDeclaration",ExportSpecifier:"ExportSpecifier",ExpressionStatement:"ExpressionStatement",ForStatement:"ForStatement",ForInStatement:"ForInStatement",ForOfStatement:"ForOfStatement",FunctionDeclaration:"FunctionDeclaration",FunctionExpression:"FunctionExpression",GeneratorExpression:"GeneratorExpression",Identifier:"Identifier",IfStatement:"IfStatement",ImportExpression:"ImportExpression",ImportDeclaration:"ImportDeclaration",ImportDefaultSpecifier:"ImportDefaultSpecifier",ImportNamespaceSpecifier:"ImportNamespaceSpecifier",ImportSpecifier:"ImportSpecifier",Literal:"Literal",LabeledStatement:"LabeledStatement",LogicalExpression:"LogicalExpression",MemberExpression:"MemberExpression",MetaProperty:"MetaProperty",MethodDefinition:"MethodDefinition",ModuleSpecifier:"ModuleSpecifier",NewExpression:"NewExpression",ObjectExpression:"ObjectExpression",ObjectPattern:"ObjectPattern",PrivateIdentifier:"PrivateIdentifier",Program:"Program",Property:"Property",PropertyDefinition:"PropertyDefinition",RestElement:"RestElement",ReturnStatement:"ReturnStatement",SequenceExpression:"SequenceExpression",SpreadElement:"SpreadElement",Super:"Super",SwitchStatement:"SwitchStatement",SwitchCase:"SwitchCase",TaggedTemplateExpression:"TaggedTemplateExpression",TemplateElement:"TemplateElement",TemplateLiteral:"TemplateLiteral",ThisExpression:"ThisExpression",ThrowStatement:"ThrowStatement",TryStatement:"TryStatement",UnaryExpression:"UnaryExpression",UpdateExpression:"UpdateExpression",VariableDeclaration:"VariableDeclaration",VariableDeclarator:"VariableDeclarator",WhileStatement:"WhileStatement",WithStatement:"WithStatement",YieldExpression:"YieldExpression"},r={AssignmentExpression:["left","right"],AssignmentPattern:["left","right"],ArrayExpression:["elements"],ArrayPattern:["elements"],ArrowFunctionExpression:["params","body"],AwaitExpression:["argument"],BlockStatement:["body"],BinaryExpression:["left","right"],BreakStatement:["label"],CallExpression:["callee","arguments"],CatchClause:["param","body"],ChainExpression:["expression"],ClassBody:["body"],ClassDeclaration:["id","superClass","body"],ClassExpression:["id","superClass","body"],ComprehensionBlock:["left","right"],ComprehensionExpression:["blocks","filter","body"],ConditionalExpression:["test","consequent","alternate"],ContinueStatement:["label"],DebuggerStatement:[],DirectiveStatement:[],DoWhileStatement:["body","test"],EmptyStatement:[],ExportAllDeclaration:["source"],ExportDefaultDeclaration:["declaration"],ExportNamedDeclaration:["declaration","specifiers","source"],ExportSpecifier:["exported","local"],ExpressionStatement:["expression"],ForStatement:["init","test","update","body"],ForInStatement:["left","right","body"],ForOfStatement:["left","right","body"],FunctionDeclaration:["id","params","body"],FunctionExpression:["id","params","body"],GeneratorExpression:["blocks","filter","body"],Identifier:[],IfStatement:["test","consequent","alternate"],ImportExpression:["source"],ImportDeclaration:["specifiers","source"],ImportDefaultSpecifier:["local"],ImportNamespaceSpecifier:["local"],ImportSpecifier:["imported","local"],Literal:[],LabeledStatement:["label","body"],LogicalExpression:["left","right"],MemberExpression:["object","property"],MetaProperty:["meta","property"],MethodDefinition:["key","value"],ModuleSpecifier:[],NewExpression:["callee","arguments"],ObjectExpression:["properties"],ObjectPattern:["properties"],PrivateIdentifier:[],Program:["body"],Property:["key","value"],PropertyDefinition:["key","value"],RestElement:["argument"],ReturnStatement:["argument"],SequenceExpression:["expressions"],SpreadElement:["argument"],Super:[],SwitchStatement:["discriminant","cases"],SwitchCase:["test","consequent"],TaggedTemplateExpression:["tag","quasi"],TemplateElement:[],TemplateLiteral:["quasis","expressions"],ThisExpression:[],ThrowStatement:["argument"],TryStatement:["block","handler","finalizer"],UnaryExpression:["argument"],UpdateExpression:["argument"],VariableDeclaration:["declarations"],VariableDeclarator:["id","init"],WhileStatement:["test","body"],WithStatement:["object","body"],YieldExpression:["argument"]},i={Break:a={},Skip:o={},Remove:s={}},l.prototype.replace=function(e){this.parent[this.key]=e},l.prototype.remove=function(){return Array.isArray(this.parent)?(this.parent.splice(this.key,1),!0):(this.replace(null),!1)},h.prototype.path=function(){var e,t,n,i,r;function a(e,t){if(Array.isArray(t))for(n=0,i=t.length;n<i;++n)e.push(t[n]);else e.push(t)}if(!this.__current.path)return null;for(r=[],e=2,t=this.__leavelist.length;e<t;++e)a(r,this.__leavelist[e].path);return a(r,this.__current.path),r},h.prototype.type=function(){return this.current().type||this.__current.wrap},h.prototype.parents=function(){var e,t,n;for(n=[],e=1,t=this.__leavelist.length;e<t;++e)n.push(this.__leavelist[e].node);return n},h.prototype.current=function(){return this.__current.node},h.prototype.__execute=function(e,t){var n,i;return i=void 0,n=this.__current,this.__current=t,this.__state=null,e&&(i=e.call(this,t.node,this.__leavelist[this.__leavelist.length-1].node)),this.__current=n,i},h.prototype.notify=function(e){this.__state=e},h.prototype.skip=function(){this.notify(o)},h.prototype.break=function(){this.notify(a)},h.prototype.remove=function(){this.notify(s)},h.prototype.__initialize=function(e,t){this.visitor=t,this.root=e,this.__worklist=[],this.__leavelist=[],this.__current=null,this.__state=null,this.__fallback=null,"iteration"===t.fallback?this.__fallback=Object.keys:"function"==typeof t.fallback&&(this.__fallback=t.fallback),this.__keys=r,t.keys&&(this.__keys=Object.assign(Object.create(this.__keys),t.keys))},h.prototype.traverse=function(e,t){var n,i,r,s,u,l,h,m,y,g,v,b;for(this.__initialize(e,t),b={},n=this.__worklist,i=this.__leavelist,n.push(new c(e,null,null,null)),i.push(new c(null,null,null,null));n.length;)if((r=n.pop())!==b){if(r.node){if(l=this.__execute(t.enter,r),this.__state===a||l===a)return;if(n.push(b),i.push(r),this.__state===o||l===o)continue;if(u=(s=r.node).type||r.wrap,!(g=this.__keys[u])){if(!this.__fallback)throw new Error("Unknown node type "+u+".");g=this.__fallback(s)}for(m=g.length;(m-=1)>=0;)if(v=s[h=g[m]])if(Array.isArray(v)){for(y=v.length;(y-=1)>=0;)if(v[y]&&!f(i,v[y])){if(p(u,g[m]))r=new c(v[y],[h,y],"Property",null);else{if(!d(v[y]))continue;r=new c(v[y],[h,y],null,null)}n.push(r)}}else if(d(v)){if(f(i,v))continue;n.push(new c(v,h,null,null))}}}else if(r=i.pop(),l=this.__execute(t.leave,r),this.__state===a||l===a)return},h.prototype.replace=function(e,t){var n,i,r,u,h,f,m,y,g,v,b,x,E;function S(e){var t,i,r,a;if(e.ref.remove())for(i=e.ref.key,a=e.ref.parent,t=n.length;t--;)if((r=n[t]).ref&&r.ref.parent===a){if(r.ref.key<i)break;--r.ref.key}}for(this.__initialize(e,t),b={},n=this.__worklist,i=this.__leavelist,f=new c(e,null,null,new l(x={root:e},"root")),n.push(f),i.push(f);n.length;)if((f=n.pop())!==b){if(void 0!==(h=this.__execute(t.enter,f))&&h!==a&&h!==o&&h!==s&&(f.ref.replace(h),f.node=h),this.__state!==s&&h!==s||(S(f),f.node=null),this.__state===a||h===a)return x.root;if((r=f.node)&&(n.push(b),i.push(f),this.__state!==o&&h!==o)){if(u=r.type||f.wrap,!(g=this.__keys[u])){if(!this.__fallback)throw new Error("Unknown node type "+u+".");g=this.__fallback(r)}for(m=g.length;(m-=1)>=0;)if(v=r[E=g[m]])if(Array.isArray(v)){for(y=v.length;(y-=1)>=0;)if(v[y]){if(p(u,g[m]))f=new c(v[y],[E,y],"Property",new l(v,y));else{if(!d(v[y]))continue;f=new c(v[y],[E,y],null,new l(v,y))}n.push(f)}}else d(v)&&n.push(new c(v,E,null,new l(r,E)))}}else if(f=i.pop(),void 0!==(h=this.__execute(t.leave,f))&&h!==a&&h!==o&&h!==s&&f.ref.replace(h),this.__state!==s&&h!==s||S(f),this.__state===a||h===a)return x.root;return x.root},t.Syntax=n,t.traverse=m,t.replace=function(e,t){return(new h).replace(e,t)},t.attachComments=function(e,t,n){var r,a,o,s,l=[];if(!e.range)throw new Error("attachComments needs range information");if(!n.length){if(t.length){for(o=0,a=t.length;o<a;o+=1)(r=u(t[o])).extendedRange=[0,e.range[0]],l.push(r);e.leadingComments=l}return e}for(o=0,a=t.length;o<a;o+=1)l.push(y(u(t[o]),n));return s=0,m(e,{enter:function(e){for(var t;s<l.length&&!((t=l[s]).extendedRange[1]>e.range[0]);)t.extendedRange[1]===e.range[0]?(e.leadingComments||(e.leadingComments=[]),e.leadingComments.push(t),l.splice(s,1)):s+=1;return s===l.length?i.Break:l[s].extendedRange[0]>e.range[1]?i.Skip:void 0}}),s=0,m(e,{leave:function(e){for(var t;s<l.length&&(t=l[s],!(e.range[1]<t.extendedRange[0]));)e.range[1]===t.extendedRange[0]?(e.trailingComments||(e.trailingComments=[]),e.trailingComments.push(t),l.splice(s,1)):s+=1;return s===l.length?i.Break:l[s].extendedRange[0]>e.range[1]?i.Skip:void 0}}),e},t.VisitorKeys=r,t.VisitorOption=i,t.Controller=h,t.cloneEnvironment=function(){return e({})},t}(Us)),Us),Hs=e(js);var zs=new WeakMap,Gs=!1,Ks=null,Xs=null,Vs=0;function Ws(e,t){try{return{ok:!0,value:e[t]}}catch(e){return{ok:!1,value:void 0}}}function Js(e,t){try{return e[t]()}catch(e){return null}}function qs(e,t){var n="YtlrPlayerActionsContainer",i=0,r=new WeakSet;return function a(o,s,u,l,h){if(!o||s>8||i>e)return null;if("object"===b(o)||"function"==typeof o){if(r.has(o))return null;r.add(o)}if("function"==typeof o){if(function(r){if(i>e||"function"!=typeof r)return!1;i+=1;var a=zs.get(r);if(void 0===a){a=0;try{var o=r.toString();o.includes("TRANSPORT_CONTROLS_BUTTON_TYPE_FEATURED_ACTION")&&(a|=1),o.includes(n)&&(a|=2)}catch(e){}zs.set(r,a)}return!(!(1&a)||t&&!(2&a))}(o)){var d=(m=l,g=o,v=h,(f=u)&&void 0!==m&&"function"==typeof g?{host:f,key:m,fn:g,write:function(e){try{return v?(f.set(m,e),f.get(m)===e):(f[m]=e,f[m]===e)}catch(e){return!1}}}:null);if(d)return d}var p=o.prototype;return p&&"object"===b(p)?a(p,s+1,null,void 0,!1):null}var f,m,g,v;if("object"!==b(o))return null;if(o instanceof Map){var x=Js(o,"entries");if(x){var E,S=c(x);try{for(S.s();!(E=S.n()).done;){var w=y(E.value,2),D=w[0],A=w[1];if(i>e)return null;var k=a(A,s+1,o,D,!0);if(k)return k}}catch(e){S.e(e)}finally{S.f()}}return null}if(o instanceof Set){var C=Js(o,"values");if(C){var T,F=c(C);try{for(F.s();!(T=F.n()).done;){var P=T.value;if(i>e)return null;var B=a(P,s+1,null,void 0,!1);if(B)return B}}catch(e){F.e(e)}finally{F.f()}}return null}var I=Ws(o,n);if(I.ok&&void 0!==I.value){var N=a(I.value,s+1,o,n,!1);if(N)return N}for(var M=0,R=Object.keys(o);M<R.length;M++){var L=R[M];if(i>e)return null;if(L!==n){var O=Ws(o,L);if(O.ok){var _=a(O.value,s+1,o,L,!1);if(_)return _}}}return null}(window._yttv,0,null,void 0,!1)}function Ys(){if(Gs||!me("enablePatchingVideoPlayer"))return!1;if(!window._yttv||!document.querySelector(".html5-video-player")&&!document.querySelector("ytlr-player"))return!1;var e=Ks&&"function"==typeof Ks.fn?Ks:Ks=qs(2e4,!0)||qs(2e4,!1);if(!e||"function"!=typeof e.write)return!1;try{var t=function(){var e=Array.prototype.slice.call(arguments);null===i&&(i=n.toString(),r=/^class\s/.test(i));var o,s=r;function u(e,i){return"undefined"!=typeof Reflect&&"function"==typeof Reflect.construct?Reflect.construct(e,i,t):function(e,t,n){if(d())return Reflect.construct.apply(null,arguments);var i=[null];i.push.apply(i,t);var r=new(e.bind.apply(e,i));return n&&m(r,n.prototype),r}(n,g(i))}if(!(this instanceof t))return s?u(n,e):n.apply(this,e);s?o=u(n,e):(n.apply(this,e),o=this);try{var l,c,h,p,f=a||(a=function(e){var t,n=e,i=0;try{t=_s.parse(e,{range:!0,tolerant:!0,sourceType:"script"})}catch(n){try{var r="("+e+")";t=_s.parse(r,{range:!0,tolerant:!0,sourceType:"script"}),i=1}catch(r){try{t=_s.parse(e,{range:!0,tolerant:!0,sourceType:"module"})}catch(r){try{var a="("+e+")";t=_s.parse(a,{range:!0,tolerant:!0,sourceType:"module"}),i=1}catch(e){throw n}}}}var o=[];return Hs.traverse(t,{enter:function(e){if("AssignmentExpression"===e.type){var t=e.right;if(t&&t.range){var r=n.slice(t.range[0]-i,t.range[1]-i),a=null;if("CallExpression"===t.type&&t.callee&&"FunctionExpression"===t.callee.type&&t.callee.body)for(var s=t.callee.body.body||[],u=0;u<s.length;u++){var l=s[u];if("ReturnStatement"===l.type&&l.argument&&l.argument.range){a=n.slice(l.argument.range[0]-i,l.argument.range[1]-i);break}}else"FunctionExpression"!==t.type&&"ArrowFunctionExpression"!==t.type||(a=r);o.push({left:e.left&&e.left.range?n.slice(e.left.range[0]-i,e.left.range[1]-i):null,rhs:r,returned:a})}}}}),o}(i)),y={type:"TRANSPORT_CONTROLS_BUTTON_TYPE_PIP",button:{buttonRenderer:gt(!1,me("enableSwapMPWithPIP")?je("player.pictureInPicture"):je("player.miniPlayer"),"CLEAR_COOKIES",{customAction:{action:me("enableSwapMPWithPIP")?"ENTER_PIP":"ENTER_MP"}})}},v=null===(l=f.find(function(e){return e.rhs.includes("TRANSPORT_CONTROLS_BUTTON_TYPE_PLAYBACK_SETTINGS")}))||void 0===l||null===(l=l.left)||void 0===l?void 0:l.split(".")[1];if(v&&me("enableMPButton")){var b=o[v];"function"==typeof b&&(o[v]=function(){var e=b.apply(this,arguments);if(Array.isArray(e)&&!e.find(function(e){return"TRANSPORT_CONTROLS_BUTTON_TYPE_PIP"===e.type})){var t=e.findIndex(function(e){return"TRANSPORT_CONTROLS_BUTTON_TYPE_PLAYBACK_SETTINGS"===e.type});-1!==t&&e.splice(t,0,y)}return e})}var x=null===(c=f.find(function(e){return!!e.rhs.includes("skipNextButton")&&e.rhs.indexOf("skipPreviousButton")>e.rhs.indexOf("skipNextButton")}))||void 0===c||null===(c=c.left)||void 0===c?void 0:c.split(".")[1],E=null===(h=f.find(function(e){return!!e.rhs.includes("skipPreviousButton")&&e.rhs.indexOf("skipNextButton")>e.rhs.indexOf("skipPreviousButton")}))||void 0===h||null===(h=h.left)||void 0===h?void 0:h.split(".")[1],S=null===(p=f.find(function(e){return e.rhs.includes("props.data.engagementActions")}))||void 0===p||null===(p=p.left)||void 0===p?void 0:p.split(".")[1];if(S&&me("enableSpeedControlsButton")){var w=o[S];"function"==typeof w&&(o[S]=function(){var e=w.apply(this,arguments);return Array.isArray(e)&&!e.find(function(e){return"TRANSPORT_CONTROLS_BUTTON_TYPE_SPEED"===e.type})&&e.push({type:"TRANSPORT_CONTROLS_BUTTON_TYPE_SPEED",button:{buttonRenderer:gt(!1,je("player.speedControls"),"SLOW_MOTION_VIDEO",{customAction:{action:"AXO_SPEED_SETTINGS_SHOW"}})}}),e})}if(!me("enableSuperThanksButton")&&S){var D=o[S];"function"==typeof D&&(o[S]=function(){var e=D.apply(this,arguments);return Array.isArray(e)?e.filter(function(e){return"TRANSPORT_CONTROLS_BUTTON_TYPE_SUPER_THANKS"!==e.type&&"TRANSPORT_CONTROLS_BUTTON_TYPE_SHOPPING"!==e.type}):e})}me("enablePreviousNextButtons")&&x&&E&&(o[x]=function(){return gt(!1,je("player.previous"),"SKIP_PREVIOUS",{signalAction:{signal:"PLAYER_PLAY_PREVIOUS"}})},o[E]=function(){return gt(!1,je("player.next"),"SKIP_NEXT",{signalAction:{signal:"PLAYER_PLAY_NEXT"}})})}catch(e){console.warn("[AxoTube:customUI] Custom UI patching failed:",e)}return o},n=e.fn,i=null,r=!1,a=null;return t.prototype=n.prototype,e.write(t)?(e.fn=t,Gs=!0,!0):(Ks=null,!1)}catch(e){return console.error("[AxoTube:customUI] Custom UI apply failed:",e),Ks=null,!1}}function Qs(e){!Gs&&me("enablePatchingVideoPlayer")&&(e&&(Vs=0),Xs||(Xs=setTimeout(function(){Xs=null,Vs+=1,Ys()||Vs<10&&Qs(!1)},500)))}function Zs(){Ys()||Qs(!0)}"complete"===document.readyState||"interactive"===document.readyState?Zs():window.addEventListener("DOMContentLoaded",Zs),ge.addEventListener("configChange",function(e){var t;"enablePatchingVideoPlayer"===(null===(t=e.detail)||void 0===t?void 0:t.key)&&e.detail.value&&(Ks=null,Qs(!0))});var $s=null,eu=null,tu=!1,nu=null,iu=null;function ru(){return-1!==window.location.href.indexOf("watch")}function au(){return te()&&te().SetFrameRate}function ou(){if(tu){var e=au();if(e)try{e.call(te(),0),tu=!1}catch(e){console.warn("[AxoTube:autoFrameRate] Failed to reset auto frame rate:",e)}}}function su(){null!==nu&&clearTimeout(nu),nu=null,iu&&(iu.video.removeEventListener("play",su),iu=null)}function uu(){if(su(),eu&&(clearTimeout(eu),eu=null),$s){try{$s.removeEventListener("onPlaybackStartExternal",lu)}catch(e){}$s=null}}function lu(){try{if(!ru()||!$s||$s!==Rn()||!me("autoFrameRate"))return;var e=$s.getStatsForNerds(),t=e&&e.resolution?e.resolution.match(/(\d+)x(\d+)@([\d.]+)/):null,n=au();if(!t||!n)return;var i=Ln(),r=me("autoFrameRatePauseVideoFor"),a=r>0&&i&&!i.paused&&!iu;a&&i.pause();try{n.call(te(),parseFloat(t[3])),tu=!0}finally{a&&i.paused&&function(e,t,n){var i=window.location.hash,r=On(t),a=e.currentSrc||e.src;iu={video:e,player:t,hash:i,videoId:r,source:a},e.addEventListener("play",su),nu=setTimeout(function(){var n=iu,o=n&&n.video===e&&n.player===$s&&Rn()===t&&Ln()===e&&ru()&&me("autoFrameRate")&&window.location.hash===i&&On(t)===r&&(e.currentSrc||e.src)===a&&e.paused&&!e.ended&&!e.seeking;if(su(),o)try{var s=e.play();s&&"function"==typeof s.catch&&s.catch(function(){})}catch(e){console.warn("[AxoTube:autoFrameRate] Failed to resume after frame rate switch:",e)}},n)}(i,$s,r)}}catch(e){console.error("[AxoTube:autoFrameRate] Error in auto frame rate handling:",e)}}function cu(){if(eu&&(clearTimeout(eu),eu=null),!me("autoFrameRate"))return uu(),void ou();var e=Rn();if(e){if(e!==$s){if(su(),$s)try{$s.removeEventListener("onPlaybackStartExternal",lu)}catch(e){}($s=e).addEventListener("onPlaybackStartExternal",lu)}}else eu=setTimeout(cu,500)}window.addEventListener("hashchange",function(){su(),ru()||ou(),setTimeout(cu,0)}),Hn(function(e){e!==$s&&cu()}),zn(function(e,t){t&&e!==t&&su()}),Gn(function(e,t){t&&e!==t&&su()}),document.addEventListener("keydown",su,!0),document.addEventListener("mousedown",su,!0),document.addEventListener("touchstart",su,!0),ge.addEventListener("configChange",function(e){var t,n;"autoFrameRate"===(null===(t=e.detail)||void 0===t?void 0:t.key)?e.detail.value?cu():(uu(),ou()):"autoFrameRatePauseVideoFor"===(null===(n=e.detail)||void 0===n?void 0:n.key)&&su()}),cu()}();
|