axotube 1.46.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 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,o){"function"==typeof o&&(e[t]||(e[t]=[]),-1===e[t].indexOf(o)&&e[t].push(o))},removeEventListener:function(t,o){var n=e[t];if(n){var r=n.indexOf(o);-1!==r&&n.splice(r,1)}},dispatchEvent:function(t){var o=e[t&&t.type];if(o)for(var n=o.slice(),r=0;r<n.length;r++)try{n[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 o=this._cbs.indexOf(t);-1!==o&&this._cbs.splice(o,1)}},e.prototype.dispatchEvent=function(e){if(e&&"abort"===e.type)for(var t=this._cbs.slice(),o=0;o<t.length;o++)t[o](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 o,n=!!(t=t||{}).bubbles,r=!!t.cancelable,i=void 0!==t.detail?t.detail:null;try{(o=document.createEvent("CustomEvent")).initCustomEvent(e,n,r,i)}catch(t){(o=document.createEvent("Event")).initEvent(e,n,r),o.detail=i}return o}"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(o){return t.resolve(e()).then(function(){return o})},function(o){return t.resolve(e()).then(function(){throw o})})}),"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,o,n){for(var r=0;r<t.length;r++)o>0&&Array.isArray(t[r])?e(t[r],o-1,n):n.push(t[r]);return n}"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),o=[],n=0;n<t.length;n++)o.push(e[t[n]]);return o},Object.entries=Object.entries||function(e){for(var t=Object.keys(e),o=[],n=0;n<t.length;n++)o.push([t[n],e[t[n]]]);return o}),"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 o=Array.isArray(e)?e:Array.prototype.slice.call(e),n=0;n<o.length;n++)t[o[n][0]]=o[n][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),o=t.length;--o>=0&&t.item(o)!==this;);return o>-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,o){o=o||{},this.language=e[o.region]||"en"}}());var o;function n(e){return n="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},n(e)}o||(o=1,function(){var e=!1;try{var t=0,o=[];e="xbx"!=="aba".replaceAll("a",function(e,n){return t+=1,o.push(n),"x"})||2!==t||0!==o[0]||2!==o[1]}catch(t){e=!0}e&&(String.prototype.replaceAll=function(e,t){var o=String(this);if(e instanceof RegExp){if(!e.global)throw new TypeError("replaceAll requires a global RegExp");return o.replace(e,t)}var n=new RegExp(String(e).replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),"g");return o.replace(n,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 o(e){if(e)try{Object.defineProperty(t,e[0],{value:e[1],enumerable:!0,configurable:!0,writable:!0})}catch(o){t[e[0]]=e[1]}}if(e&&"function"==typeof e.forEach)e.forEach(o);else for(var n=Array.isArray(e)?e:Array.prototype.slice.call(e||[]),r=0;r<n.length;r++)o(n[r]);return t})}());var r,i,a={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 c=function(){if(i)return r;i=1;var e=a;return r={validateConfigValue:function(t,o){var r=e.defaults;if(!Object.prototype.hasOwnProperty.call(r,t))return!1;var i=r[t];if(null===i)return null===o||"string"==typeof o;if(Array.isArray(i))return Array.isArray(o)&&o.every(function(e){return"string"==typeof e});if("number"==typeof i){if("number"!=typeof o||!isFinite(o))return!1;var a=e.ranges[t];return!a||o>=a[0]&&o<=a[1]}if(n(o)!==n(i))return!1;var c=e.enums[t];return(!c||-1!==c.indexOf(o))&&(!("routeColor"===t&&!/^#[0-9a-f]{6}$/i.test(o))&&!("routeBackgroundUrl"===t&&o&&!/^https?:\/\/\S+$/i.test(o)))}},r}(),l=e(c),u="ytaf-configuration",s=JSON.parse,f=JSON.stringify,p=function(e){return s(f(e))},d=p(a.defaults);d.enableFixedUI="undefined"==typeof window||!window.h5vcc||!window.h5vcc.tizentube||a.defaults.enableFixedUI;var h,y=l.validateConfigValue;function b(e){if(Object.prototype.hasOwnProperty.call(d,e))return void 0===h[e]&&(h[e]=p(d[e])),h[e];console.warn("[AxoTube:config] Unknown config key",e)}!function(){h=p(d);try{if(!window.localStorage||!window.localStorage[u])return;var e=s(window.localStorage[u]);if(!e||"object"!==n(e)||Array.isArray(e))return;Object.keys(e).forEach(function(t){y(t,e[t])&&(h[t]=p(e[t]))})}catch(e){console.warn("[AxoTube:config] Config read failed; using defaults:",e)}}();var v=new EventTarget,m={"1440p":"2560x1440","2160p":"3840x2160"},g={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)&&w()},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 w(){return!(!window.matchMedia||!window.matchMedia("(dynamic-range: high)").matches)}function S(e){var t=e.split("."),o="vp09"===t[0]?t[6]:"av01"===t[0]?t[7]:void 0;return"16"===o||"18"===o}var E="__axotubeResolutionOwner";if(!window[E]){if(window[E]=!0,b("enableExperimentalResolution"))try{window.h5vcc=window.h5vcc||{},window.h5vcc.system=window.h5vcc.system||{},window.h5vcc.system.getVideoContainerSizeOverride=function(){var e=b("experimentalMaxResolution");return m[e]||m["1440p"]},function(){if(window.MediaSource&&"function"==typeof MediaSource.isTypeSupported){var e=MediaSource.isTypeSupported.bind(MediaSource);MediaSource.isTypeSupported=function(t){for(var o=String(t).split(";"),n=[o[0].trim()],r=1;r<o.length;r++){var i=o[r].trim(),a=i.indexOf("="),c=(-1===a?i:i.slice(0,a)).trim().toLowerCase(),l=(-1===a?"":i.slice(a+1)).trim().replace(/^"|"$/g,"");if("codecs"===c){for(var u=l.split(","),s=0;s<u.length;s++)if(S(u[s].trim())&&!w())return!1;n.push(i)}else if(g[c]){if(!g[c](l))return!1}else n.push(i)}return e(n.join("; "))}}}()}catch(e){console.warn("[AxoTube:experimentalResolution] Could not install overrides:",e)}v.addEventListener("configChange",function(e){var t,o=(null===(t=e.detail)||void 0===t?void 0:t.key)||"";("enableExperimentalResolution"===o||"experimentalMaxResolution"===o&&b("enableExperimentalResolution"))&&setTimeout(function(){return location.reload()},300)})}var k={avc1:["avc1"],vp9:["vp09","vp9"],av01:["av01"]};var P="__axotubeCodecOwner";if(!window[P]){window[P]=!0;try{!function(e){if(window.MediaSource&&"function"==typeof MediaSource.isTypeSupported){var t=function(e){if(!k[e])return[];var t=[];return Object.keys(k).forEach(function(o){o!==e&&(t=t.concat(k[o]))}),t}(e);if(0!==t.length){var o=MediaSource.isTypeSupported.bind(MediaSource);MediaSource.isTypeSupported=function(e){var n=String(e).toLowerCase();if(-1!==n.indexOf("codecs"))for(var r=0;r<t.length;r++)if(-1!==n.indexOf(t[r]))return!1;return o(e)}}}}(b("videoPreferredCodec"))}catch(e){console.warn("[AxoTube:codecPreference] Could not install codec preference:",e)}v.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 A={"www.gstatic.com":!0,"yt3.ggpht.com":!0,"clients1.google.com":!0,"s.youtube.com":!0,"jnn-pa.googleapis.com":!0,"yt3.googleusercontent.com":!0,"redirector.googlevideo.com":!0,"www.youtube.com":!0,"youtube.com":!0};function O(e,t){var o=e.location;if(!o||"localhost"!==o.hostname&&"127.0.0.1"!==o.hostname)return null;var n=e.document.createElement("a");n.href=String(t);var r,i,a=String(n.href||""),c=/^https?:\/\/([^\/?#:]+)/i.exec(a);return c&&(r=c[1],i=String(r||"").toLowerCase(),A[i]||"googlevideo.com"===i||".googlevideo.com"===i.slice(-16))?(/^http:\/\//i.test(a)&&(a="https://"+a.slice(7).replace(/^([^\/?#]*?):80(?=[\/?#]|$)/,"$1")),o.origin+"/cors-bypass/"+a):null}!function(e){if(e&&!e.__axotubeCorsShim){e.__axotubeCorsShim=!0;var t=e.Request;if("function"==typeof t){var o=function(o,n){var r=o;if("string"==typeof o)try{var i=O(e,o);i&&(r=i)}catch(e){}return new t(r,n)};o.prototype=t.prototype,e.Request=o}if("function"==typeof e.fetch){var r=e.fetch;e.fetch=function(t,o){try{var i=!!t&&"object"===n(t)&&"string"==typeof t.url,a=O(e,i?t.url:t);a&&(i?"GET"!==t.method&&"HEAD"!==t.method||(t=new e.Request(a,{method:t.method,headers:t.headers,credentials:"omit",mode:"cors"})):t=a)}catch(e){}return r.call(e,t,o)}}var i=e.XMLHttpRequest;if(i&&i.prototype&&"function"==typeof i.prototype.open){var a=i.prototype.open;i.prototype.open=function(t,o){var n=Array.prototype.slice.call(arguments);try{var r=O(e,o);r&&(n[1]=r)}catch(e){}return a.apply(this,n)}}}}(window)}();
1
+ !function(){"use strict";function e(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}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)}var r,n={};!function(){if(r)return n;function e(e,t,r){Object.defineProperty(e,t,{value:r,writable:!0,configurable:!0,enumerable:!1})}r=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,r){"function"==typeof r&&(e[t]||(e[t]=[]),-1===e[t].indexOf(r)&&e[t].push(r))},removeEventListener:function(t,r){var n=e[t];if(n){var o=n.indexOf(r);-1!==o&&n.splice(o,1)}},dispatchEvent:function(t){var r=e[t&&t.type];if(r)for(var n=r.slice(),o=0;o<n.length;o++)try{n[o].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 r=this._cbs.indexOf(t);-1!==r&&this._cbs.splice(r,1)}},e.prototype.dispatchEvent=function(e){if(e&&"abort"===e.type)for(var t=this._cbs.slice(),r=0;r<t.length;r++)t[r](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 r,n=!!(t=t||{}).bubbles,o=!!t.cancelable,i=void 0!==t.detail?t.detail:null;try{(r=document.createEvent("CustomEvent")).initCustomEvent(e,n,o,i)}catch(t){(r=document.createEvent("Event")).initEvent(e,n,o),r.detail=i}return r}"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(r){return t.resolve(e()).then(function(){return r})},function(r){return t.resolve(e()).then(function(){throw r})})}),"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,r,n){for(var o=0;o<e.length;o++)r>0&&Array.isArray(e[o])?t(e[o],r-1,n):n.push(e[o]);return n}"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 r=String(e).replace(/[.*+?^${}()|[\]\\]/g,"\\$&");return String(this).replace(new RegExp(r,"g"),t)}),"function"!=typeof Object.values&&e(Object,"values",function(e){for(var t=Object.keys(e),r=[],n=0;n<t.length;n++)r.push(e[t[n]]);return r}),"function"!=typeof Object.entries&&e(Object,"entries",function(e){for(var t=Object.keys(e),r=[],n=0;n<t.length;n++)r.push([t[n],e[t[n]]]);return r}),"function"!=typeof Object.fromEntries&&e(Object,"fromEntries",function(e){if(null==e)throw new TypeError("Object.fromEntries requires an iterable");for(var r={},n=e[Symbol.iterator](),o=n.next();!o.done;){var i=o.value;if(null===i||"object"!==t(i)&&"function"!=typeof i)throw new TypeError("Iterator value is not an entry object");r[i[0]]=i[1],o=n.next()}return r}),"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),r=t.length;--r>=0&&t.item(r)!==this;);return r>-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,r){r=r||{},this.language=e[r.region]||"en"}}(),function(){var t=9007199254740991;function r(t,r,n){void 0===t[r]&&e(t,r,n)}function n(e,t){return e===t||e!=e&&t!=t}function o(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 i(e,t){if(null==e)throw new TypeError("String.prototype."+t+" called on null or undefined")}r(Array.prototype,"includes",function(e,t){for(var r=Object(this),o=r.length>>>0,i=Number(t)||0,a=i>=0?Math.floor(i):Math.max(o+Math.ceil(i),0);a<o;a++)if(n(r[a],e))return!0;return!1}),r(Array.prototype,"findIndex",function(e,t){if("function"!=typeof e)throw new TypeError("predicate must be a function");for(var r=Object(this),n=r.length>>>0,o=0;o<n;o++)if(e.call(t,r[o],o,r))return o;return-1}),r(Array.prototype,"find",function(e,t){if("function"!=typeof e)throw new TypeError("predicate must be a function");for(var r=Object(this),n=r.length>>>0,o=0;o<n;o++)if(e.call(t,r[o],o,r))return r[o]}),r(Array,"from",function(e,t,r){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 n=[],o=e[Symbol.iterator];if("function"==typeof o)for(var i=o.call(e),a=i.next();!a.done;)n.push(a.value),a=i.next();else for(var l=Object(e).length>>>0,c=0;c<l;c++)n.push(e[c]);if(t)for(var u=0;u<n.length;u++)n[u]=t.call(r,n[u],u);return n}),r(Object,"assign",function(e){if(null==e)throw new TypeError("Cannot convert undefined or null to object");for(var t=Object(e),r=1;r<arguments.length;r++){var n=arguments[r];if(null!=n)for(var o=Object(n),i=Object.keys(o),a=0;a<i.length;a++)t[i[a]]=o[i[a]]}return t}),r(String.prototype,"includes",function(e,t){i(this,"includes"),o(e,"includes");var r=String(this),n=Number(t)||0;return n<0&&(n=0),-1!==r.indexOf(String(e),n)}),r(String.prototype,"startsWith",function(e,t){i(this,"startsWith"),o(e,"startsWith");var r=String(this),n=String(e),a=Number(t)||0;return a<0&&(a=0),a>r.length&&(a=r.length),r.substring(a,a+n.length)===n}),r(Number,"isFinite",function(e){return"number"==typeof e&&isFinite(e)}),r(Number,"isSafeInteger",function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e&&Math.abs(e)<=t}),r(Number,"MAX_SAFE_INTEGER",t),r(Number,"MIN_SAFE_INTEGER",-t)}()}();var o;o||(o=1,function(){var e=!1;try{var t=0,r=[];e="xbx"!=="aba".replaceAll("a",function(e,n){return t+=1,r.push(n),"x"})||2!==t||0!==r[0]||2!==r[1]}catch(t){e=!0}e&&(String.prototype.replaceAll=function(e,t){var r=String(this);if(e instanceof RegExp){if(!e.global)throw new TypeError("replaceAll requires a global RegExp");return r.replace(e,t)}var n=new RegExp(String(e).replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),"g");return r.replace(n,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 r(e){if(e)try{Object.defineProperty(t,e[0],{value:e[1],enumerable:!0,configurable:!0,writable:!0})}catch(r){t[e[0]]=e[1]}}if(e&&"function"==typeof e.forEach)e.forEach(r);else for(var n=Array.isArray(e)?e:Array.prototype.slice.call(e||[]),o=0;o<n.length;o++)r(n[o]);return t})}());var i,a,l={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 c=function(){if(a)return i;a=1;var e=l;return i={validateConfigValue:function(r,n){var o=e.defaults;if(!Object.prototype.hasOwnProperty.call(o,r))return!1;var i=o[r];if(null===i)return null===n||"string"==typeof n;if(Array.isArray(i))return Array.isArray(n)&&n.every(function(e){return"string"==typeof e});if("number"==typeof i){if("number"!=typeof n||!isFinite(n))return!1;var a=e.ranges[r];return!a||n>=a[0]&&n<=a[1]}if(t(n)!==t(i))return!1;var l=e.enums[r];return(!l||-1!==l.indexOf(n))&&(!("routeColor"===r&&!/^#[0-9a-f]{6}$/i.test(n))&&!("routeBackgroundUrl"===r&&n&&!/^https?:\/\/\S+$/i.test(n)))}},i}(),u=e(c),f="ytaf-configuration",s=JSON.parse,p=JSON.stringify,d=function(e){return s(p(e))},h=d(l.defaults);h.enableFixedUI="undefined"==typeof window||!window.h5vcc||!window.h5vcc.tizentube||l.defaults.enableFixedUI;var b,y=u.validateConfigValue;function m(e){if(Object.prototype.hasOwnProperty.call(h,e))return void 0===b[e]&&(b[e]=d(h[e])),b[e];console.warn("[AxoTube:config] Unknown config key",e)}!function(){b=d(h);try{if(!window.localStorage||!window.localStorage[f])return;var e=s(window.localStorage[f]);if(!e||"object"!==t(e)||Array.isArray(e))return;Object.keys(e).forEach(function(t){y(t,e[t])&&(b[t]=d(e[t]))})}catch(e){console.warn("[AxoTube:config] Config read failed; using defaults:",e)}}();var v=new EventTarget,g={"1440p":"2560x1440","2160p":"3840x2160"},w={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)&&S()},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 S(){return!(!window.matchMedia||!window.matchMedia("(dynamic-range: high)").matches)}function E(e){var t=e.split("."),r="vp09"===t[0]?t[6]:"av01"===t[0]?t[7]:void 0;return"16"===r||"18"===r}var O="__axotubeResolutionOwner";if(!window[O]){if(window[O]=!0,m("enableExperimentalResolution"))try{window.h5vcc=window.h5vcc||{},window.h5vcc.system=window.h5vcc.system||{},window.h5vcc.system.getVideoContainerSizeOverride=function(){var e=m("experimentalMaxResolution");return g[e]||g["1440p"]},function(){if(window.MediaSource&&"function"==typeof MediaSource.isTypeSupported){var e=MediaSource.isTypeSupported.bind(MediaSource);MediaSource.isTypeSupported=function(t){for(var r=String(t).split(";"),n=[r[0].trim()],o=1;o<r.length;o++){var i=r[o].trim(),a=i.indexOf("="),l=(-1===a?i:i.slice(0,a)).trim().toLowerCase(),c=(-1===a?"":i.slice(a+1)).trim().replace(/^"|"$/g,"");if("codecs"===l){for(var u=c.split(","),f=0;f<u.length;f++)if(E(u[f].trim())&&!S())return!1;n.push(i)}else if(w[l]){if(!w[l](c))return!1}else n.push(i)}return e(n.join("; "))}}}()}catch(e){console.warn("[AxoTube:experimentalResolution] Could not install overrides:",e)}v.addEventListener("configChange",function(e){var t,r=(null===(t=e.detail)||void 0===t?void 0:t.key)||"";("enableExperimentalResolution"===r||"experimentalMaxResolution"===r&&m("enableExperimentalResolution"))&&setTimeout(function(){return location.reload()},300)})}var T={avc1:["avc1"],vp9:["vp09","vp9"],av01:["av01"]};var k="__axotubeCodecOwner";if(!window[k]){window[k]=!0;try{!function(e){if(window.MediaSource&&"function"==typeof MediaSource.isTypeSupported){var t=function(e){if(!T[e])return[];var t=[];return Object.keys(T).forEach(function(r){r!==e&&(t=t.concat(T[r]))}),t}(e);if(0!==t.length){var r=MediaSource.isTypeSupported.bind(MediaSource);MediaSource.isTypeSupported=function(e){var n=String(e).toLowerCase();if(-1!==n.indexOf("codecs"))for(var o=0;o<t.length;o++)if(-1!==n.indexOf(t[o]))return!1;return r(e)}}}}(m("videoPreferredCodec"))}catch(e){console.warn("[AxoTube:codecPreference] Could not install codec preference:",e)}v.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 A={"www.gstatic.com":!0,"yt3.ggpht.com":!0,"clients1.google.com":!0,"s.youtube.com":!0,"jnn-pa.googleapis.com":!0,"yt3.googleusercontent.com":!0,"redirector.googlevideo.com":!0,"www.youtube.com":!0,"youtube.com":!0};function P(e,t){var r=e.location;if(!r||"localhost"!==r.hostname&&"127.0.0.1"!==r.hostname)return null;var n=e.document.createElement("a");n.href=String(t);var o,i,a=String(n.href||""),l=/^https?:\/\/([^\/?#:]+)/i.exec(a);return l&&(o=l[1],i=String(o||"").toLowerCase(),A[i]||"googlevideo.com"===i||".googlevideo.com"===i.slice(-16))?(/^http:\/\//i.test(a)&&(a="https://"+a.slice(7).replace(/^([^\/?#]*?):80(?=[\/?#]|$)/,"$1")),r.origin+"/cors-bypass/"+a):null}!function(e){if(e&&!e.__axotubeCorsShim){e.__axotubeCorsShim=!0;var r=e.Request;if("function"==typeof r){var n=function(t,n){var o=t;if("string"==typeof t)try{var i=P(e,t);i&&(o=i)}catch(e){}return new r(o,n)};n.prototype=r.prototype,e.Request=n}if("function"==typeof e.fetch){var o=e.fetch;e.fetch=function(r,n){try{var i=!!r&&"object"===t(r)&&"string"==typeof r.url,a=P(e,i?r.url:r);a&&(i?"GET"!==r.method&&"HEAD"!==r.method||(r=new e.Request(a,{method:r.method,headers:r.headers,credentials:"omit",mode:"cors"})):r=a)}catch(e){}return o.call(e,r,n)}}var i=e.XMLHttpRequest;if(i&&i.prototype&&"function"==typeof i.prototype.open){var a=i.prototype.open;i.prototype.open=function(t,r){var n=Array.prototype.slice.call(arguments);try{var o=P(e,r);o&&(n[1]=o)}catch(e){}return a.apply(this,n)}}}}(window)}();