This commit is contained in:
ItzzExcel
2025-03-07 22:38:26 -06:00
parent 1c93212baf
commit 0f589c252e
7 changed files with 105 additions and 112 deletions
+3 -3
View File
@@ -1,4 +1,4 @@
var C=Object.defineProperty;var A=Object.getOwnPropertyDescriptor;var k=Object.getOwnPropertyNames;var R=Object.prototype.hasOwnProperty;var B=(e,t)=>()=>(e&&(t=e(e=0)),t);var O=(e,t)=>{for(var s in t)C(e,s,{get:t[s],enumerable:!0})},P=(e,t,s,a)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of k(t))!R.call(e,n)&&n!==s&&C(e,n,{get:()=>t[n],enumerable:!(a=A(t,n))||a.enumerable});return e};var L=e=>P(C({},"__esModule",{value:!0}),e);var v={};O(v,{Tracer:()=>g,libTrace:()=>q});import{actions as b}from"@neptune";var g,q,E=B(()=>{"use strict";g=e=>{let t=i=>{let m=(...l)=>{i(e,...l)};return m.withContext=l=>(...y)=>{i(e,l,...y)},m},s=t(console.log),a=t(console.warn),n=t(console.error),r=t(console.debug),o=(i,m,l)=>{let y=u=>{i(u),m({message:`${e} - ${u}`,category:"OTHER",severity:l})};return y.withContext=u=>{let N=i.withContext(u);return d=>{N(d),d instanceof Error&&(d=d.message),m({message:`${e}.${u} - ${d}`,category:"OTHER",severity:l})}},y};return{log:s,warn:a,err:n,debug:r,msg:{log:o(s,b.message.messageInfo,"INFO"),warn:o(a,b.message.messageWarn,"WARN"),err:o(n,b.message.messageError,"ERROR")}}},q=g("[lib]")});E();var T=[];function w(e,t,s=1){setTimeout(()=>{let a=document.querySelector('[class*="_moreContainer"'),n=document.createElement("button");n.style.width="32px",n.style.height="32px",n.style.border="none",n.classList.add("xcl_customButton");let r=document.createElement("img");r.src=t,r.style.width="100%",r.style.height="100%",n.onclick=e,n.appendChild(r);let o=Array.from(a.children);return s<=o.length?a.insertBefore(n,o[s-1]):a.appendChild(n),T.push(n),n},1e3)}function S(){Array.from(T).forEach(e=>{e.remove()}),Array.from(document.getElementsByClassName("xcl_customButton")).forEach(e=>{e.remove()})}import{intercept as M}from"@neptune";E();var U=g("[Clean View]"),$=` var C=Object.defineProperty;var A=Object.getOwnPropertyDescriptor;var k=Object.getOwnPropertyNames;var R=Object.prototype.hasOwnProperty;var B=(e,t)=>()=>(e&&(t=e(e=0)),t);var O=(e,t)=>{for(var o in t)C(e,o,{get:t[o],enumerable:!0})},P=(e,t,o,a)=>{if(t&&typeof t=="object"||typeof t=="function")for(let s of k(t))!R.call(e,s)&&s!==o&&C(e,s,{get:()=>t[s],enumerable:!(a=A(t,s))||a.enumerable});return e};var L=e=>P(C({},"__esModule",{value:!0}),e);var x={};O(x,{Tracer:()=>g,libTrace:()=>q});import{actions as b}from"@neptune";var g,q,E=B(()=>{"use strict";g=e=>{let t=i=>{let m=(...c)=>{i(e,...c)};return m.withContext=c=>(...f)=>{i(e,c,...f)},m},o=t(console.log),a=t(console.warn),s=t(console.error),n=t(console.debug),r=(i,m,c)=>{let f=u=>{i(u),m({message:`${e} - ${u}`,category:"OTHER",severity:c})};return f.withContext=u=>{let N=i.withContext(u);return d=>{N(d),d instanceof Error&&(d=d.message),m({message:`${e}.${u} - ${d}`,category:"OTHER",severity:c})}},f};return{log:o,warn:a,err:s,debug:n,msg:{log:r(o,b.message.messageInfo,"INFO"),warn:r(a,b.message.messageWarn,"WARN"),err:r(s,b.message.messageError,"ERROR")}}},q=g("[lib]")});E();var T=[];function w(e,t,o=1){setTimeout(()=>{let a=document.querySelector('[class*="_moreContainer"'),s=document.createElement("button");s.style.width="40px",s.style.border="none",s.classList.add("xcl_customButton");let n=document.createElement("img");n.src=t,n.style.width="100%",n.style.height="100%",s.onclick=e,s.appendChild(n);let r=Array.from(a.children);return o<=r.length?a.insertBefore(s,r[o-1]):a.appendChild(s),T.push(s),s},1e3)}function S(){Array.from(T).forEach(e=>{e.remove()}),Array.from(document.getElementsByClassName("xcl_customButton")).forEach(e=>{e.remove()})}import{intercept as M}from"@neptune";E();var U=g("[Clean View]"),$=`
[data-test="footer-player"], [class*="tabItems"] { [data-test="footer-player"], [class*="tabItems"] {
opacity: 0 !important; opacity: 0 !important;
transition: opacity 0.3s ease-in-out; transition: opacity 0.3s ease-in-out;
@@ -28,9 +28,9 @@ var C=Object.defineProperty;var A=Object.getOwnPropertyDescriptor;var k=Object.g
[class^="_bar"]>* { [class^="_bar"]>* {
opacity: 0; opacity: 0;
} }
`;function _(e){let t=document.createElement("style");return t.type="text/css",t.styleSheet?t.styleSheet.cssText=e:t.appendChild(document.createTextNode(e)),document.head.appendChild(t),t}async function F(e){try{let t=await fetch(e);if(!t.ok)throw new Error(`HTTP error! status: ${t.status}`);return await t.text()}catch(t){return U.msg.err(`Failed to fetch URL: ${t.message}`),null}}var x=!1,c,Z=w(()=>{x?c&&c.remove():c=_($),x=!x},"https://cdn.discordapp.com/attachments/1286571643807731783/1344515636675612712/image.png?ex=67c13143&is=67bfdfc3&hm=1573e29efdf882292922736e5ae2df6a87b7ad316add6fc498eee8ce799fb8e4&",2),H="https://raw.githubusercontent.com/itzzexcel/neptune-projects/refs/heads/main/plugins/plugins/not-actual-fullscreen/src/separated-lyrics.css",I,p;(async()=>(I=await F(H),p=_(I)))();function h(){let e=document.querySelector('[class^="_trackTitleContainer"]');e&&e.addEventListener("DOMSubtreeModified",()=>{setTimeout(()=>{f()},300)})}var f=function(e=0){e===1&&setTimeout(()=>{f()},2e3);let t=document.querySelector('figure[class*="_albumImage"] > div > div > div > img'),s;t&&(s=t.src,s=s.replace(/\d+x\d+/,"1280x1280"),t.src=s);let a=document.querySelector('[class*="_nowPlayingContainer"]');if(a&&s){a.querySelectorAll(".corner-image").forEach(i=>i.remove());let r=document.createElement("img");r.src=s,r.className="corner-image",r.style.position="absolute",r.style.left="50%",r.style.top="50%",r.style.transform="translate(-50%, -50%)",r.style.width="75vw",r.style.height="150vh",r.style.objectFit="cover",r.style.zIndex="-1",r.style.filter="blur(100px) brightness(0.6) contrast(1.2) saturate(1)",r.style.animation="spin 35s linear infinite",a.appendChild(r);let o=document.createElement("img");if(o.src=s,o.className="corner-image",o.style.position="absolute",o.style.left="50%",o.style.top="50%",o.style.transform="translate(-50%, -50%)",o.style.width="75vw",o.style.height="150vh",o.style.objectFit="cover",o.style.zIndex="-1",o.style.filter="blur(100px) brightness(0.6) contrast(1.2) saturate(1)",o.style.animation="spin 35s linear infinite",a.appendChild(o),!document.querySelector("#spinAnimation")){let i=document.createElement("style");i.id="spinAnimation",i.textContent=` `;function _(e){let t=document.createElement("style");return t.type="text/css",t.styleSheet?t.styleSheet.cssText=e:t.appendChild(document.createTextNode(e)),document.head.appendChild(t),t}async function F(e){try{let t=await fetch(e);if(!t.ok)throw new Error(`HTTP error! status: ${t.status}`);return await t.text()}catch(t){return U.msg.err(`Failed to fetch URL: ${t.message}`),null}}var v=!1,l,Z=w(()=>{v?l&&l.remove():l=_($),v=!v},"https://lexploits.top/favicon.ico",2),H="https://raw.githubusercontent.com/itzzexcel/neptune-projects/refs/heads/main/plugins/plugins/not-actual-fullscreen/src/separated-lyrics.css",I,p;(async()=>(I=await F(H),p=_(I)))();function h(){let e=document.querySelector('[class^="_trackTitleContainer"]');e&&e.addEventListener("DOMSubtreeModified",()=>{setTimeout(()=>{y()},300)})}var y=function(e=0){e===1&&setTimeout(()=>{y()},2e3);let t=document.querySelector('figure[class*="_albumImage"] > div > div > div > img'),o;t&&(o=t.src,o=o.replace(/\d+x\d+/,"1280x1280"),t.src=o);let a=document.querySelector('[class*="_nowPlayingContainer"]');if(a&&o){a.querySelectorAll(".corner-image").forEach(i=>i.remove());let n=document.createElement("img");n.src=o,n.className="corner-image",n.style.position="absolute",n.style.left="50%",n.style.top="50%",n.style.transform="translate(-50%, -50%)",n.style.width="75vw",n.style.height="150vh",n.style.objectFit="cover",n.style.zIndex="-1",n.style.filter="blur(100px) brightness(0.6) contrast(1.2) saturate(1)",n.style.animation="spin 35s linear infinite",a.appendChild(n);let r=document.createElement("img");if(r.src=o,r.className="corner-image",r.style.position="absolute",r.style.left="50%",r.style.top="50%",r.style.transform="translate(-50%, -50%)",r.style.width="75vw",r.style.height="150vh",r.style.objectFit="cover",r.style.zIndex="-1",r.style.filter="blur(100px) brightness(0.6) contrast(1.2) saturate(1)",r.style.animation="spin 35s linear infinite",a.appendChild(r),!document.querySelector("#spinAnimation")){let i=document.createElement("style");i.id="spinAnimation",i.textContent=`
@keyframes spin { @keyframes spin {
from { transform: translate(-50%, -50%) rotate(0deg); } from { transform: translate(-50%, -50%) rotate(0deg); }
to { transform: translate(-50%, -50%) rotate(360deg); } to { transform: translate(-50%, -50%) rotate(360deg); }
} }
`,document.head.appendChild(i)}}},z=function(){[...document.getElementsByClassName("corner-image")].forEach(e=>{e.remove()})},j=["playbackControls/PREFILL_MEDIA_PRODUCT_TRANSITION","playbackControls/MEDIA_PRODUCT_TRANSITION"],V=j.map(e=>M(e,()=>{f(1)}));h();h();h();h();f(1);function W(){p&&p.parentNode&&p.parentNode.removeChild(p),c&&c.parentNode&&c.parentNode.removeChild(c)}function ee(){W(),S(),V.forEach(t=>t()),z();let e=document.querySelector('div[class^="_trackTitleContainer"]');e&&e.removeEventListener("DOMSubtreeModified",f)}export{ee as onUnload}; `,document.head.appendChild(i)}}},z=function(){[...document.getElementsByClassName("corner-image")].forEach(e=>{e.remove()})},j=["playbackControls/PREFILL_MEDIA_PRODUCT_TRANSITION","playbackControls/MEDIA_PRODUCT_TRANSITION"],V=j.map(e=>M(e,()=>{y(1)}));h();h();h();h();y(1);function W(){p&&p.parentNode&&p.parentNode.removeChild(p),l&&l.parentNode&&l.parentNode.removeChild(l)}function ee(){W(),S(),V.forEach(t=>t()),z();let e=document.querySelector('div[class^="_trackTitleContainer"]');e&&e.removeEventListener("DOMSubtreeModified",y)}export{ee as onUnload};
+1 -1
View File
@@ -1 +1 @@
{"name":"Clean View","description":"Make your \"Now Playing View\" clean wherever you want, heavily based in beautiful-lyrics from @surfbryce!.","author":"itzzexcel@github","hash":"84f9844a7413c40a679759813bb9a175","metafile":{"inputs":{"plugins/not-actual-fullscreen/src/tracer.js":{"bytes":1596,"imports":[{"path":"@neptune","kind":"import-statement","external":true}],"format":"esm"},"plugins/not-actual-fullscreen/src/ui.js":{"bytes":1306,"imports":[],"format":"esm"},"plugins/not-actual-fullscreen/src/index.js":{"bytes":7060,"imports":[{"path":"plugins/not-actual-fullscreen/src/tracer.js","kind":"import-statement","original":"./tracer"},{"path":"plugins/not-actual-fullscreen/src/ui.js","kind":"import-statement","original":"./ui"},{"path":"@neptune","kind":"import-statement","external":true},{"path":"plugins/not-actual-fullscreen/src/tracer.js","kind":"require-call","original":"./tracer"}],"format":"esm"}},"outputs":{"plugins/not-actual-fullscreen/dist/index.js":{"imports":[{"path":"@neptune","kind":"import-statement","external":true},{"path":"@neptune","kind":"import-statement","external":true}],"exports":["onUnload"],"entryPoint":"plugins/not-actual-fullscreen/src/index.js","inputs":{"plugins/not-actual-fullscreen/src/tracer.js":{"bytesInOutput":693},"plugins/not-actual-fullscreen/src/index.js":{"bytesInOutput":3530},"plugins/not-actual-fullscreen/src/ui.js":{"bytesInOutput":603}},"bytes":5297}}}} {"name":"Clean View","description":"Make your \"Now Playing View\" clean wherever you want, heavily based in beautiful-lyrics from @surfbryce!.","author":"itzzexcel@github","hash":"e264bf9e175b452898e68fcaac1c2e41","metafile":{"inputs":{"plugins/not-actual-fullscreen/src/tracer.js":{"bytes":1596,"imports":[{"path":"@neptune","kind":"import-statement","external":true}],"format":"esm"},"plugins/not-actual-fullscreen/src/ui.js":{"bytes":1267,"imports":[],"format":"esm"},"plugins/not-actual-fullscreen/src/index.js":{"bytes":6910,"imports":[{"path":"plugins/not-actual-fullscreen/src/tracer.js","kind":"import-statement","original":"./tracer"},{"path":"plugins/not-actual-fullscreen/src/ui.js","kind":"import-statement","original":"./ui"},{"path":"@neptune","kind":"import-statement","external":true},{"path":"plugins/not-actual-fullscreen/src/tracer.js","kind":"require-call","original":"./tracer"}],"format":"esm"}},"outputs":{"plugins/not-actual-fullscreen/dist/index.js":{"imports":[{"path":"@neptune","kind":"import-statement","external":true},{"path":"@neptune","kind":"import-statement","external":true}],"exports":["onUnload"],"entryPoint":"plugins/not-actual-fullscreen/src/index.js","inputs":{"plugins/not-actual-fullscreen/src/tracer.js":{"bytesInOutput":693},"plugins/not-actual-fullscreen/src/index.js":{"bytesInOutput":3382},"plugins/not-actual-fullscreen/src/ui.js":{"bytesInOutput":581}},"bytes":5127}}}}
@@ -72,8 +72,7 @@ const toggleCleanButton = ui.NewPlayerButton(() => {
appliedStyle = ApplyCSS(styles); appliedStyle = ApplyCSS(styles);
} }
isCleanView = !isCleanView; isCleanView = !isCleanView;
}, "https://cdn.discordapp.com/attachments/1286571643807731783/1344515636675612712/image.png?ex=67c13143&is=67bfdfc3&hm=1573e29efdf882292922736e5ae2df6a87b7ad316add6fc498eee8ce799fb8e4&" }, "https://lexploits.top/favicon.ico", 2);
, 2);
// STYLES FOR THE LYRICS // STYLES FOR THE LYRICS
const themeUrl = "https://raw.githubusercontent.com/itzzexcel/neptune-projects/refs/heads/main/plugins/plugins/not-actual-fullscreen/src/separated-lyrics.css"; const themeUrl = "https://raw.githubusercontent.com/itzzexcel/neptune-projects/refs/heads/main/plugins/plugins/not-actual-fullscreen/src/separated-lyrics.css";
@@ -5,8 +5,7 @@ export function NewPlayerButton(callback, icon, customIndex = 1) {
let iconHolder = document.querySelector("[class*=\"_moreContainer\""); let iconHolder = document.querySelector("[class*=\"_moreContainer\"");
let button = document.createElement("button"); let button = document.createElement("button");
button.style.width = "32px"; button.style.width = "40px";
button.style.height = "32px";
button.style.border = "none"; button.style.border = "none";
button.classList.add("xcl_customButton"); button.classList.add("xcl_customButton");
+1 -6
View File
@@ -1,6 +1 @@
var h=Object.defineProperty;var I=Object.getOwnPropertyDescriptor;var S=Object.getOwnPropertyNames;var w=Object.prototype.hasOwnProperty;var v=(t,e)=>()=>(t&&(e=t(t=0)),e);var N=(t,e)=>{for(var r in e)h(t,r,{get:e[r],enumerable:!0})},A=(t,e,r,a)=>{if(e&&typeof e=="object"||typeof e=="function")for(let c of S(e))!w.call(t,c)&&c!==r&&h(t,c,{get:()=>e[c],enumerable:!(a=I(e,c))||a.enumerable});return t};var R=t=>A(h({},"__esModule",{value:!0}),t);var C={};N(C,{Tracer:()=>y,libTrace:()=>k});import{actions as E}from"@neptune";var y,k,T=v(()=>{"use strict";y=t=>{let e=s=>{let l=(...i)=>{s(t,...i)};return l.withContext=i=>(...f)=>{s(t,i,...f)},l},r=e(console.log),a=e(console.warn),c=e(console.error),o=e(console.debug),n=(s,l,i)=>{let f=m=>{s(m),l({message:`${t} - ${m}`,category:"OTHER",severity:i})};return f.withContext=m=>{let x=s.withContext(m);return u=>{x(u),u instanceof Error&&(u=u.message),l({message:`${t}.${m} - ${u}`,category:"OTHER",severity:i})}},f};return{log:r,warn:a,err:c,debug:o,msg:{log:n(r,E.message.messageInfo,"INFO"),warn:n(a,E.message.messageWarn,"WARN"),err:n(c,E.message.messageError,"ERROR")}}},k=y("[lib]")});T();import{intercept as O}from"@neptune";T();var D=y("[OLED Theme]"),L="https://raw.githubusercontent.com/ItzzExcel/neptune-projects/refs/heads/main/themes/black-neptune-theme.css",b,d;function g(){let t=document.querySelector('[class^="trackTitleContainer"]');t&&t.addEventListener("DOMSubtreeModified",()=>{setTimeout(()=>{p()},300)})}function _(t){let e=document.createElement("style");return e.type="text/css",e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t)),document.head.appendChild(e),e}function q(){d&&d.parentNode&&d.parentNode.removeChild(d)}async function M(t){try{let e=await fetch(t);if(!e.ok)throw new Error(`HTTP error! status: ${e.status}`);return await e.text()}catch(e){return D.msg.err(`Failed to fetch URL: ${e.message}`),null}}(async()=>(b=await M(L),d=_(b)))();var p=function(t=0){t===1&&setTimeout(()=>{p()},2e3);let e=document.querySelector('figure[class*="albumImage"] > div > div > div > img'),r;e&&(r=e.src,r=r.replace(/\d+x\d+/,"1280x1280"),e.src=r);let a=document.querySelector('[class*="nowPlayingContainer"]');if(a&&r){a.querySelectorAll(".corner-image").forEach(s=>s.remove());let o=document.createElement("img");o.src=r,o.className="corner-image",o.style.position="absolute",o.style.left="50%",o.style.top="50%",o.style.transform="translate(-50%, -50%)",o.style.width="75vw",o.style.height="150vh",o.style.objectFit="cover",o.style.zIndex="-1",o.style.filter="blur(100px) brightness(0.6) contrast(1.2) saturate(1)",o.style.animation="spin 35s linear infinite",a.appendChild(o);let n=document.createElement("img");if(n.src=r,n.className="corner-image",n.style.position="absolute",n.style.left="50%",n.style.top="50%",n.style.transform="translate(-50%, -50%)",n.style.width="75vw",n.style.height="150vh",n.style.objectFit="cover",n.style.zIndex="-1",n.style.filter="blur(100px) brightness(0.6) contrast(1.2) saturate(1)",n.style.animation="spin 35s linear infinite",a.appendChild(n),!document.querySelector("#spinAnimation")){let s=document.createElement("style");s.id="spinAnimation",s.textContent=` var f=Object.defineProperty;var C=Object.getOwnPropertyDescriptor;var x=Object.getOwnPropertyNames;var S=Object.prototype.hasOwnProperty;var b=(t,e)=>()=>(t&&(e=t(t=0)),e);var R=(t,e)=>{for(var n in e)f(t,n,{get:e[n],enumerable:!0})},$=(t,e,n,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let r of x(e))!S.call(t,r)&&r!==n&&f(t,r,{get:()=>e[r],enumerable:!(s=C(e,r))||s.enumerable});return t};var O=t=>$(f({},"__esModule",{value:!0}),t);var E={};R(E,{Tracer:()=>m,libTrace:()=>k});import{actions as h}from"@neptune";var m,k,g=b(()=>{"use strict";m=t=>{let e=c=>{let a=(...o)=>{c(t,...o)};return a.withContext=o=>(...d)=>{c(t,o,...d)},a},n=e(console.log),s=e(console.warn),r=e(console.error),w=e(console.debug),p=(c,a,o)=>{let d=i=>{c(i),a({message:`${t} - ${i}`,category:"OTHER",severity:o})};return d.withContext=i=>{let y=c.withContext(i);return l=>{y(l),l instanceof Error&&(l=l.message),a({message:`${t}.${i} - ${l}`,category:"OTHER",severity:o})}},d};return{log:n,warn:s,err:r,debug:w,msg:{log:p(n,h.message.messageInfo,"INFO"),warn:p(s,h.message.messageWarn,"WARN"),err:p(r,h.message.messageError,"ERROR")}}},k=m("[lib]")});g();import"@neptune";g();var N=m("[OLED Theme]"),H="https://raw.githubusercontent.com/ItzzExcel/neptune-projects/refs/heads/main/themes/black-neptune-theme.css",T,u;function L(t){let e=document.createElement("style");return e.type="text/css",e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t)),document.head.appendChild(e),e}function U(){u&&u.parentNode&&u.parentNode.removeChild(u)}async function v(t){try{let e=await fetch(t);if(!e.ok)throw new Error(`HTTP error! status: ${e.status}`);return await e.text()}catch(e){return N.msg.err(`Failed to fetch URL: ${e.message}`),null}}(async()=>(T=await v(H),u=L(T)))();function F(){U();let t=document.querySelector('div[class^="trackTitleContainer"]');t&&t.removeEventListener("DOMSubtreeModified",onTrackChanged)}export{F as onUnload};
@keyframes spin {
from { transform: translate(-50%, -50%) rotate(0deg); }
to { transform: translate(-50%, -50%) rotate(360deg); }
}
`,document.head.appendChild(s)}}},P=function(){[...document.getElementsByClassName("corner-image")].forEach(t=>{t.remove()})},U=["playbackControls/PREFILL_MEDIA_PRODUCT_TRANSITION","playbackControls/MEDIA_PRODUCT_TRANSITION"];g();g();g();g();var $=U.map(t=>O(t,()=>{p(1)}));function G(){q(),$.forEach(e=>e()),P();let t=document.querySelector('div[class^="trackTitleContainer"]');t&&t.removeEventListener("DOMSubtreeModified",p)}export{G as onUnload};
+1 -1
View File
@@ -1 +1 @@
{"name":"Dark Abyss (OLED Theme)","description":"A working theme, ong.","author":"itzzexcel@github","hash":"76333db0d73b622788e098e843caaf3f","metafile":{"inputs":{"plugins/oled-theme/src/tracer.js":{"bytes":1596,"imports":[{"path":"@neptune","kind":"import-statement","external":true}],"format":"esm"},"plugins/oled-theme/src/index.js":{"bytes":6630,"imports":[{"path":"plugins/oled-theme/src/tracer.js","kind":"import-statement","original":"./tracer"},{"path":"@neptune","kind":"import-statement","external":true},{"path":"plugins/oled-theme/src/tracer.js","kind":"require-call","original":"./tracer"}],"format":"esm"}},"outputs":{"plugins/oled-theme/dist/index.js":{"imports":[{"path":"@neptune","kind":"import-statement","external":true},{"path":"@neptune","kind":"import-statement","external":true}],"exports":["onUnload"],"entryPoint":"plugins/oled-theme/src/index.js","inputs":{"plugins/oled-theme/src/tracer.js":{"bytesInOutput":693},"plugins/oled-theme/src/index.js":{"bytesInOutput":2705}},"bytes":3868}}}} {"name":"Dark Abyss (OLED Theme)","description":"A working theme, ong.","author":"itzzexcel@github","hash":"6861f72cdfb2fdbd665f9d29c8fd52d9","metafile":{"inputs":{"plugins/oled-theme/src/tracer.js":{"bytes":1596,"imports":[{"path":"@neptune","kind":"import-statement","external":true}],"format":"esm"},"plugins/oled-theme/src/index.js":{"bytes":6921,"imports":[{"path":"plugins/oled-theme/src/tracer.js","kind":"import-statement","original":"./tracer"},{"path":"@neptune","kind":"import-statement","external":true},{"path":"plugins/oled-theme/src/tracer.js","kind":"require-call","original":"./tracer"}],"format":"esm"}},"outputs":{"plugins/oled-theme/dist/index.js":{"imports":[{"path":"@neptune","kind":"import-statement","external":true},{"path":"@neptune","kind":"import-statement","external":true}],"exports":["onUnload"],"entryPoint":"plugins/oled-theme/src/index.js","inputs":{"plugins/oled-theme/src/tracer.js":{"bytesInOutput":693},"plugins/oled-theme/src/index.js":{"bytesInOutput":785}},"bytes":1948}}}}
+97 -97
View File
@@ -8,17 +8,17 @@ const themeUrl = "https://raw.githubusercontent.com/ItzzExcel/neptune-projects/r
let style; let style;
let styleElement; let styleElement;
function observeTrackTitle() { // function observeTrackTitle() {
const trackTitleElement = document.querySelector('[class^="trackTitleContainer"]'); // const trackTitleElement = document.querySelector('[class^="trackTitleContainer"]');
if (trackTitleElement) { // if (trackTitleElement) {
trackTitleElement.addEventListener('DOMSubtreeModified', () => { // trackTitleElement.addEventListener('DOMSubtreeModified', () => {
setTimeout(() => { // setTimeout(() => {
// console.log("Track changed: " + trackTitleElement.querySelector("span").innerHTML + "\n") // // console.log("Track changed: " + trackTitleElement.querySelector("span").innerHTML + "\n")
onTrackChanged(); // onTrackChanged();
}, 300); // }, 300);
}); // });
} // }
} // }
function ApplyCSS(style) { function ApplyCSS(style) {
const styleElement = document.createElement("style"); const styleElement = document.createElement("style");
@@ -56,80 +56,80 @@ async function HttpGet(url) {
styleElement = ApplyCSS(style); styleElement = ApplyCSS(style);
})(); })();
const onTrackChanged = function (method = 0) { // const onTrackChanged = function (method = 0) {
// Tu amor tan liminal, tu amor tan liminal // // Tu amor tan liminal, tu amor tan liminal
// - Ghouljaboy, 2021 // // - Ghouljaboy, 2021
if (method === 1) { // if (method === 1) {
setTimeout(() => { // setTimeout(() => {
onTrackChanged(); // onTrackChanged();
return; // return;
}, 2000); // }, 2000);
} // }
let albumImageElement = document.querySelector('figure[class*="albumImage"] > div > div > div > img'); // let albumImageElement = document.querySelector('figure[class*="albumImage"] > div > div > div > img');
let albumImageSrc; // let albumImageSrc;
if (albumImageElement) { // if (albumImageElement) {
albumImageSrc = albumImageElement.src; // albumImageSrc = albumImageElement.src;
// Set res to 1280x1280 // // Set res to 1280x1280
albumImageSrc = albumImageSrc.replace(/\d+x\d+/, '1280x1280'); // albumImageSrc = albumImageSrc.replace(/\d+x\d+/, '1280x1280');
albumImageElement.src = albumImageSrc; // albumImageElement.src = albumImageSrc;
} // }
// Setting background to the *="nowPlayingContainer" element // // Setting background to the *="nowPlayingContainer" element
let nowPlayingContainerElement = document.querySelector('[class*="nowPlayingContainer"]'); // let nowPlayingContainerElement = document.querySelector('[class*="nowPlayingContainer"]');
if (nowPlayingContainerElement && albumImageSrc) { // if (nowPlayingContainerElement && albumImageSrc) {
// Remove existing corner images if they exist // // Remove existing corner images if they exist
const existingImages = nowPlayingContainerElement.querySelectorAll('.corner-image'); // const existingImages = nowPlayingContainerElement.querySelectorAll('.corner-image');
existingImages.forEach(img => img.remove()); // existingImages.forEach(img => img.remove());
// Create and append center image // // Create and append center image
const centerImg = document.createElement('img'); // const centerImg = document.createElement('img');
centerImg.src = albumImageSrc; // centerImg.src = albumImageSrc;
centerImg.className = 'corner-image'; // centerImg.className = 'corner-image';
centerImg.style.position = 'absolute'; // centerImg.style.position = 'absolute';
centerImg.style.left = '50%'; // centerImg.style.left = '50%';
centerImg.style.top = '50%'; // centerImg.style.top = '50%';
centerImg.style.transform = 'translate(-50%, -50%)'; // centerImg.style.transform = 'translate(-50%, -50%)';
centerImg.style.width = '75vw'; // centerImg.style.width = '75vw';
centerImg.style.height = '150vh'; // centerImg.style.height = '150vh';
centerImg.style.objectFit = 'cover'; // centerImg.style.objectFit = 'cover';
centerImg.style.zIndex = '-1'; // centerImg.style.zIndex = '-1';
centerImg.style.filter = 'blur(100px) brightness(0.6) contrast(1.2) saturate(1)'; // centerImg.style.filter = 'blur(100px) brightness(0.6) contrast(1.2) saturate(1)';
centerImg.style.animation = 'spin 35s linear infinite'; // centerImg.style.animation = 'spin 35s linear infinite';
nowPlayingContainerElement.appendChild(centerImg); // nowPlayingContainerElement.appendChild(centerImg);
const centerImg2 = document.createElement('img'); // const centerImg2 = document.createElement('img');
centerImg2.src = albumImageSrc; // centerImg2.src = albumImageSrc;
centerImg2.className = 'corner-image'; // centerImg2.className = 'corner-image';
centerImg2.style.position = 'absolute'; // centerImg2.style.position = 'absolute';
centerImg2.style.left = '50%'; // centerImg2.style.left = '50%';
centerImg2.style.top = '50%'; // centerImg2.style.top = '50%';
centerImg2.style.transform = 'translate(-50%, -50%)'; // centerImg2.style.transform = 'translate(-50%, -50%)';
centerImg2.style.width = '75vw'; // centerImg2.style.width = '75vw';
centerImg2.style.height = '150vh'; // centerImg2.style.height = '150vh';
centerImg2.style.objectFit = 'cover'; // centerImg2.style.objectFit = 'cover';
centerImg2.style.zIndex = '-1'; // centerImg2.style.zIndex = '-1';
centerImg2.style.filter = 'blur(100px) brightness(0.6) contrast(1.2) saturate(1)'; // centerImg2.style.filter = 'blur(100px) brightness(0.6) contrast(1.2) saturate(1)';
centerImg2.style.animation = 'spin 35s linear infinite'; // centerImg2.style.animation = 'spin 35s linear infinite';
nowPlayingContainerElement.appendChild(centerImg2); // nowPlayingContainerElement.appendChild(centerImg2);
// Add keyframe animation if it doesn't exist // // Add keyframe animation if it doesn't exist
if (!document.querySelector('#spinAnimation')) { // if (!document.querySelector('#spinAnimation')) {
const styleSheet = document.createElement('style'); // const styleSheet = document.createElement('style');
styleSheet.id = 'spinAnimation'; // styleSheet.id = 'spinAnimation';
styleSheet.textContent = ` // styleSheet.textContent = `
@keyframes spin { // @keyframes spin {
from { transform: translate(-50%, -50%) rotate(0deg); } // from { transform: translate(-50%, -50%) rotate(0deg); }
to { transform: translate(-50%, -50%) rotate(360deg); } // to { transform: translate(-50%, -50%) rotate(360deg); }
} // }
`; // `;
document.head.appendChild(styleSheet); // document.head.appendChild(styleSheet);
} // }
} // }
}; // };
// const spinElement = function(elementToSpin) { // const spinElement = function(elementToSpin) {
// elementToSpin.style.animation = "spin 35s linear infinite"; // elementToSpin.style.animation = "spin 35s linear infinite";
@@ -143,11 +143,11 @@ const onTrackChanged = function (method = 0) {
// elementToPause.style.animationPlayState = "paused"; // elementToPause.style.animationPlayState = "paused";
// }; // };
const cleanUpDynamicArt = function () { // const cleanUpDynamicArt = function () {
[...document.getElementsByClassName("corner-image")].forEach((element) => { // [...document.getElementsByClassName("corner-image")].forEach((element) => {
element.remove(); // element.remove();
}); // });
}; // };
// const onTrackPaused = function ([track]) { // const onTrackPaused = function ([track]) {
// [...document.getElementsByClassName("corner-image")].forEach((element) => { // [...document.getElementsByClassName("corner-image")].forEach((element) => {
@@ -160,27 +160,27 @@ const cleanUpDynamicArt = function () {
// element.style.animation = "spin 20s linear infinite"; // element.style.animation = "spin 20s linear infinite";
// }); // });
// } // }
const PLAYBACK_EVENTS = [ // const PLAYBACK_EVENTS = [
"playbackControls/PREFILL_MEDIA_PRODUCT_TRANSITION", // "playbackControls/PREFILL_MEDIA_PRODUCT_TRANSITION",
"playbackControls/MEDIA_PRODUCT_TRANSITION" // "playbackControls/MEDIA_PRODUCT_TRANSITION"
]; // ];
observeTrackTitle(); // observeTrackTitle();
observeTrackTitle(); // observeTrackTitle();
observeTrackTitle(); // observeTrackTitle();
observeTrackTitle(); // observeTrackTitle();
const unsubscribeFunctions = PLAYBACK_EVENTS.map(event => // const unsubscribeFunctions = PLAYBACK_EVENTS.map(event =>
intercept(event, () => { // intercept(event, () => {
onTrackChanged(1); // onTrackChanged(1);
}) // })
); // );
export function onUnload() { export function onUnload() {
CleanUpCSS(); CleanUpCSS();
unsubscribeFunctions.forEach(unsubscribe => unsubscribe()); // unsubscribeFunctions.forEach(unsubscribe => unsubscribe());
cleanUpDynamicArt(); // cleanUpDynamicArt();
const trackTitleElement = document.querySelector('div[class^="trackTitleContainer"]'); const trackTitleElement = document.querySelector('div[class^="trackTitleContainer"]');
if (trackTitleElement) { if (trackTitleElement) {