var hidePodcasts=(()=>{var T=(e=>"undefined"!=typeof require?require:"undefined"!=typeof Proxy?new Proxy(e,{get:(e,t)=>("undefined"!=typeof require?require:e)[t]}):e)(function(e){if("react"===e)return Spicetify.React;if("react-dom"===e)return Spicetify.ReactDOM;if("undefined"!=typeof require)return require.apply(this,arguments);throw new Error('Dynamic require of "'+e+'" is not supported')});function C(e){return(C="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})(e)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function U(e,t){for(var n=0;ne.length)&&(t=e.length);for(var n=0,o=new Array(t);n":">",'"':""","'":"'","/":"/"};function W(e){return"string"==typeof e?e.replace(/[&<>"'\/]/g,function(e){return $[e]}):e}var h="undefined"!=typeof window&&window.navigator&&void 0===window.navigator.userAgentData&&window.navigator.userAgent&&-1s+c;)c++,u=a[l=i.slice(s,s+c).join(r)];if(void 0===u)return;if(null===u)return null;if(n.endsWith(l)){if("string"==typeof u)return u;if(l&&"string"==typeof u[l])return u[l]}var p=i.slice(s+c).join(r);return p?e(u,p,r):void 0}a=a[i[s]]}return a}}(this.data&&this.data[e]&&this.data[e][t],n,r)}},{key:"addResource",value:function(e,t,n,o){var r=4=p.maxReplaces)break}var n,o}),r}},{key:"nest",value:function(e,t){var n,o=this,r=2=this.maxParallelReads?void this.waitingReads.push({lng:o,ns:r,fcName:i,tried:s,wait:c,callback:l}):(this.readingCalls++,this.backend[i](o,r,function(e,t){var n;a.readingCalls--,0",">":">","'":"'","'":"'",""":'"',""":'"'," ":" "," ":" ","©":"©","©":"©","®":"®","®":"®","…":"…","…":"…","/":"/","/":"/"};function Ne(t,e){var n,o=Object.keys(t);return Object.getOwnPropertySymbols&&(n=Object.getOwnPropertySymbols(t),e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),o.push.apply(o,n)),o}function Ce(t){for(var e=1;e{t=localStorage.getItem(t);if(!t)return e;try{return JSON.parse(t)}catch(e){return t}}),Ye=(je.use(T).use(I).init({resources:{en:{translation:{menuTitle:"Hide podcasts",enabled:"Enabled",aggressiveMode:"Aggressive mode",searchPageShelfAriaLabel:"Browse all"}},fr:{translation:{menuTitle:"Masquer les balados",enabled:"Activé",aggressiveMode:"Mode agressif",searchPageShelfAriaLabel:"Paarcourir tout"}},de:{translation:{menuTitle:"Podcasts verstecken",enabled:"Aktiviert",aggressiveMode:"Aggressiver Modus",searchPageShelfAriaLabel:"Alles durchsuchen"}},it:{translation:{menuTitle:"Nascondi podcast",enabled:"Attivato",aggressiveMode:"Modalità aggressiva",searchPageShelfAriaLabel:"Sfoglia tutto"}}},detection:{order:["navigator","htmlTag"]},fallbackLng:"en",interpolation:{escapeValue:!1}}),"HidePodcastsEnabled"),Ge="HidePodcastsAggressiveMode";var Qe=async function(){const o=je["t"];let{Player:e,Menu:t,Platform:n}=Spicetify,r=document.querySelector(".main-view-container__scroll-node-child");for(;!(e&&t&&n&&r);)await new Promise(e=>setTimeout(e,100)),e=Spicetify.Player,t=Spicetify.Menu,n=Spicetify.Platform,r=document.querySelector(".main-view-container__scroll-node-child");let a=We(Ye,!0),i=We(Ge,!1);function s(){var e;e=a,document.body.classList.toggle("hide-podcasts-enabled",e);{const t=document.body;if(!t.classList.contains("hide-podcasts--style-injected")){const n=document.createElement("style");n.innerHTML=`.hide-podcasts-enabled .podcast-item { display: none !important; }.hide-podcasts-enabled .queue-tabBar-header a[href="/collection/podcasts"] { display: none !important; }`,t.appendChild(n),t.classList.add("hide-podcasts--style-injected")}}{const o=null==(e=document.querySelector('a[href="/collection/episodes"]'))?void 0:e.parentElement,r=(o&&o.classList.add("podcast-item"),document.querySelectorAll(".main-shelf-shelf")),i=(r.forEach(e=>{var t;0<[...e.querySelectorAll('.main-cardHeader-link[href^="/episode"]'),...e.querySelectorAll('.main-cardHeader-link[href^="/show"]')].length&&(t=e.getAttribute("aria-label"),console.log("Tagging carousel: "+t),e.classList.add("podcast-item"))}),document.querySelector('.x-categoryCard-CategoryCard[href="/genre/podcasts-web"]'));i&&(console.log("Tagging browsePodcastsCard: "+i),i.classList.add("podcast-item"))}}function c(t){const n=new MutationObserver(function(){var e;!r||(e="/search"===t?r.querySelector(`#searchPage .main-shelf-shelf[aria-label="${o("searchPageShelfAriaLabel")}"]`):r.querySelector("section"))&&(console.log(t,e),s(),i||n.disconnect())});n.observe(r,{childList:!0,subtree:!0})}new t.SubMenu(o("menuTitle"),[new t.Item(o("enabled"),a,e=>{a=!a,localStorage.setItem(Ye,a),e.setState(a),s()}),new t.Item(o("aggressiveMode"),i,e=>{i=!i,localStorage.setItem(Ge,i),e.setState(i),location.reload()})]).register(),c(n.History.location.pathname),n.History.listen(({pathname:e})=>{c(e)})};(async()=>{await Qe()})()})();