diff --git a/assets/index-C6qE1llB.js b/assets/index-C6qE1llB.js new file mode 100644 index 0000000..d46baee --- /dev/null +++ b/assets/index-C6qE1llB.js @@ -0,0 +1,47 @@ +(function(){const a=document.createElement("link").relList;if(a&&a.supports&&a.supports("modulepreload"))return;for(const t of document.querySelectorAll('link[rel="modulepreload"]'))d(t);new MutationObserver(t=>{for(const e of t)if(e.type==="childList")for(const s of e.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&d(s)}).observe(document,{childList:!0,subtree:!0});function i(t){const e={};return t.integrity&&(e.integrity=t.integrity),t.referrerPolicy&&(e.referrerPolicy=t.referrerPolicy),t.crossOrigin==="use-credentials"?e.credentials="include":t.crossOrigin==="anonymous"?e.credentials="omit":e.credentials="same-origin",e}function d(t){if(t.ep)return;t.ep=!0;const e=i(t);fetch(t.href,e)}})();function M(){const u=document.getElementById("favicon"),a="619810098465734666",i=document.getElementById("avatar"),d=document.getElementById("username"),t=document.getElementById("status-icon"),e=document.getElementById("status-text"),s=document.getElementById("activity"),$=document.querySelector(".user-card"),y=document.getElementById("music-container");let n=null;const C={online:"status-online",idle:"status-idle",dnd:"status-dnd",offline:"status-offline"},m=new WebSocket("wss://api.lanyard.rest/socket");m.onopen=()=>{m.send(JSON.stringify({op:2,d:{subscribe_to_ids:[a]}}))},m.onmessage=w=>{const c=JSON.parse(w.data);if(!c.t||!c.d)return;if(c.t==="INIT_STATE")n=c.d[a];else if(c.t==="PRESENCE_UPDATE")n=c.d;else return;if(!n||!n.discord_user){d.textContent="User data not found",t.className="status-icon",e.textContent="",s.textContent="No activity data available",i.src="https://cdn.discordapp.com/avatars/619810098465734666/0481ff1a167a987fa41790d3079ed7d7.webp?size=80",b();return}const p=n.discord_user;i.src=`https://cdn.discordapp.com/avatars/${p.id}/${p.avatar}.png`,u.href=`https://cdn.discordapp.com/avatars/${p.id}/${p.avatar}.png`,d.textContent=p.username;let h=n.discord_status||"offline";if(t.className="status-icon",C[h]?t.classList.add(C[h]):t.style.backgroundColor="gray",e.textContent=h.charAt(0).toUpperCase()+h.slice(1),n.activities&&n.activities.length>0){const r=n.activities.find(o=>o.name&&o.name!=="Custom Status");s.textContent=r?`Activity: ${r.name}`:"No activity data available."}else s.textContent="No activity data available.";let L=!1;if(n.activities&&n.activities.length>0){const r=n.activities.find(o=>o.type===2&&o.name==="Apple Music");if(r){const o=r.details,I=r.state;let f=I,l="";const E=I.split(" — ");E.length>=2&&(f=E[0],l=E.slice(1).join(" — "));let v="";if(r.assets&&r.assets.large_image){let g=r.assets.large_image;const T="/https/",k=g.indexOf(T);k!==-1?v="https://"+g.substring(k+T.length):g.startsWith("https://")?v=g:(console.warn("Could not find a valid HTTP(S) URL in large_image:",g),v="")}o&&f&&v?(y.innerHTML=`
+ ${l|| +
${o}
+ ${l?`
${l}
`:""} +
${f}
+
`,L=!0):o&&f&&(y.innerHTML=`
+

Album art not available.

+
${o}
+ ${l?`
${l}
`:""} +
${f}
+
`,L=!0)}L||(y.innerHTML="

Not listening to music right now.

")}},setInterval(()=>{m.readyState===WebSocket.OPEN&&m.send(JSON.stringify({op:3}))},3e4);function b(){const w=$.offsetHeight,c=Math.max(w-42.5,100);y.style.height=`${c}px`}window.addEventListener("resize",b),window.addEventListener("DOMContentLoaded",b)}function x(){const u=document.getElementById("youtube"),a=document.getElementById("twitter"),i=document.getElementById("mega");u.addEventListener("click",()=>{window.open("https://www.youtube.com/@opiategalore?sub_confirmation=1","_blank")}),a.addEventListener("click",()=>{window.open("https://twitter.com/ctgadse","_blank")}),i.addEventListener("click",()=>{window.open("https://mega.nz/folder/XCx22aYZ#IZykt57yG1StXceL8XqlUQ","_blank")})}function A(){document.addEventListener("DOMContentLoaded",()=>{const u="UCLOxpFqdyAab5eCWtHWZ-Zg",a="AIzaSyBt_Yeacmt8K41HZMXGF6K_isMv_eM14mg",i=document.getElementById("youtube-embed-container");if(!i){console.error("Container element not found.");return}const d=`https://www.googleapis.com/youtube/v3/search?key=${a}&channelId=${u}&part=snippet,id&order=date&maxResults=1&type=video`;fetch(d).then(t=>t.ok?t.json():t.json().then(e=>{throw new Error(`HTTP error! Status: ${t.status}, Message: ${e.error.message}`)})).then(t=>{if(t.items&&t.items.length>0){const e=t.items[0].id.videoId;if(e){const s=document.createElement("iframe");s.width="640px",s.height="360px",s.src=`https://www.youtube.com/embed/${e}?autoplay=0&controls=1&rel=0`,s.title="YouTube Video Player",s.frameBorder="0",s.allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",s.allowFullscreen=!0,i.innerHTML="",i.appendChild(s)}else i.innerHTML="

No video ID found for the latest upload.

"}else i.innerHTML="

No videos found on this channel, or an issue occurred with the API response.

"}).catch(t=>{console.error("Error fetching YouTube video:",t),i.innerHTML=`

Failed to load the latest video. Error: ${t.message}

`})})}document.querySelector("#app").innerHTML=` +
+
+
+
+ Avatar +
+ +
+ + +
+

Activity: —

+
+
+ +
+
+
+
+

Loading music data...

+
+
+
+
+
+
+

Loading latest video...

+
+
+`;document.addEventListener("DOMContentLoaded",()=>{M(),x(),A()}); diff --git a/assets/index-DKqHGiwC.css b/assets/index-DKqHGiwC.css new file mode 100644 index 0000000..dc34358 --- /dev/null +++ b/assets/index-DKqHGiwC.css @@ -0,0 +1 @@ +@font-face{font-family:HelveticaNeueLight;src:url(../font/HelveticaNeueLight.otf)}@font-face{font-family:HelveticaNeueMedium;src:url(../font/HelveticaNeueMedium.otf)}@font-face{font-family:HelveticaNeueBold;src:url(../font/HelveticaNeueBold.otf)}body{font-family:HelveticaNeueLight,sans-serif;background-color:#9496a6;display:flex;justify-content:center;align-items:center;height:100vh;margin:0;flex-direction:column}.main-content-wrapper{display:flex;gap:20px;align-items:stretch}.user-card{display:flex;flex-direction:column;align-items:center;padding:20px;border-radius:15px;gap:20px;background-color:#f0f0f2;filter:drop-shadow(0 0 5px rgba(0,0,0,.2));width:fit-content}.user-main-info{display:flex;align-items:center;gap:20px}.avatar{width:80px;height:80px;border-radius:50%;object-fit:cover;border:2px solid #F0F0F2;filter:drop-shadow(0 0 5px rgba(0,0,0,.3))}.social-links{display:flex;justify-content:center;gap:20px;margin-top:10px}.link-logo{width:80px;height:80px;filter:drop-shadow(0 0 5px rgba(0,0,0,.4))}.user-details{flex:1;position:relative;top:+5px}.user-info{display:flex;align-items:center;margin-bottom:10px;width:fit-content}.user-info span{font-weight:400;font-size:18px}.status{display:flex;align-items:center;gap:10px;margin-bottom:10px;width:fit-content}.status-icon{width:10px;height:10px;border-radius:50%;display:inline-block;background-color:gray}.status-online{background-color:#43a25a}.status-idle{background-color:#ca9654}.status-dnd{background-color:#d83a42}.status-offline{background-color:#747f8d}#activity{width:fit-content}#youtube,#twitter,#mega{transition:transform .15s ease-in-out}#youtube:hover,#twitter:hover,#mega:hover{cursor:pointer;transform:scale(1.05)}.track-name{font-family:HelveticaNeueMedium,sans-serif;font-size:16px;text-align:center;margin-bottom:5px}.track-album{font-family:HelveticaNeueLight,sans-serif;font-size:16px;text-align:center;margin-bottom:5px}.track-artist{font-family:HelveticaNeueLight,sans-serif;font-size:16px;text-align:center}.album-art{width:100px;height:100px;border-radius:15px;filter:drop-shadow(0 0 5px rgba(0,0,0,.3));margin-bottom:15px;display:block;margin-left:auto;margin-right:auto}#music-container{display:flex;flex-direction:column;align-items:center;justify-content:center}.song-card-container{display:flex;flex-direction:column;align-items:center;gap:5px;width:inherit;overflow-y:scroll;overflow-x:hidden;max-height:40vh;scroll-behavior:smooth}.song-card{display:flex;padding:10px;background:#f0f0f2;border-radius:15px;filter:drop-shadow(0 0 5px rgba(0,0,0,.3));justify-content:space-evenly;width:600px}.song-cover{width:80px;height:80px;border-radius:10px;object-fit:cover;border:2px solid #F0F0F2;filter:drop-shadow(0 0 5px rgba(0,0,0,.3))}.song-title{font-weight:600}.file-size,.song-length{font-weight:300}.download-icon{width:80px;height:80px;filter:drop-shadow(0 0 5px rgba(0,0,0,.4));transition:transform .15s ease-in-out}.download-icon:hover{cursor:pointer;transform:scale(1.05)} diff --git a/assets/index-Dk1GJ3lp.js b/assets/index-Dk1GJ3lp.js new file mode 100644 index 0000000..f35ff52 --- /dev/null +++ b/assets/index-Dk1GJ3lp.js @@ -0,0 +1,47 @@ +(function(){const a=document.createElement("link").relList;if(a&&a.supports&&a.supports("modulepreload"))return;for(const t of document.querySelectorAll('link[rel="modulepreload"]'))d(t);new MutationObserver(t=>{for(const e of t)if(e.type==="childList")for(const s of e.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&d(s)}).observe(document,{childList:!0,subtree:!0});function i(t){const e={};return t.integrity&&(e.integrity=t.integrity),t.referrerPolicy&&(e.referrerPolicy=t.referrerPolicy),t.crossOrigin==="use-credentials"?e.credentials="include":t.crossOrigin==="anonymous"?e.credentials="omit":e.credentials="same-origin",e}function d(t){if(t.ep)return;t.ep=!0;const e=i(t);fetch(t.href,e)}})();function M(){const u=document.getElementById("favicon"),a="619810098465734666",i=document.getElementById("avatar"),d=document.getElementById("username"),t=document.getElementById("status-icon"),e=document.getElementById("status-text"),s=document.getElementById("activity"),$=document.querySelector(".user-card"),y=document.getElementById("music-container");let n=null;const I={online:"status-online",idle:"status-idle",dnd:"status-dnd",offline:"status-offline"},m=new WebSocket("wss://api.lanyard.rest/socket");m.onopen=()=>{m.send(JSON.stringify({op:2,d:{subscribe_to_ids:[a]}}))},m.onmessage=w=>{const c=JSON.parse(w.data);if(!c.t||!c.d)return;if(c.t==="INIT_STATE")n=c.d[a];else if(c.t==="PRESENCE_UPDATE")n=c.d;else return;if(!n||!n.discord_user){d.textContent="User data not found",t.className="status-icon",e.textContent="",s.textContent="No activity data available",i.src="https://cdn.discordapp.com/avatars/619810098465734666/0481ff1a167a987fa41790d3079ed7d7.webp?size=80",b();return}const p=n.discord_user;i.src=`https://cdn.discordapp.com/avatars/${p.id}/${p.avatar}.png`,u.href=`https://cdn.discordapp.com/avatars/${p.id}/${p.avatar}.png`,d.textContent=p.username;let h=n.discord_status||"offline";if(t.className="status-icon",I[h]?t.classList.add(I[h]):t.style.backgroundColor="gray",e.textContent=h.charAt(0).toUpperCase()+h.slice(1),n.activities&&n.activities.length>0){const r=n.activities.find(o=>o.name&&o.name!=="Custom Status");s.textContent=r?`Activity: ${r.name}`:"No activity data available."}else s.textContent="No activity data available.";let E=!1;if(n.activities&&n.activities.length>0){const r=n.activities.find(o=>o.type===2&&o.name==="Apple Music");if(r){const o=r.details,C=r.state;let f=C,l="";const L=C.split(" — ");L.length>=2&&(f=L[0],l=L.slice(1).join(" — "));let v="";if(r.assets&&r.assets.large_image){let g=r.assets.large_image;const T="/https/",k=g.indexOf(T);k!==-1?v="https://"+g.substring(k+T.length):g.startsWith("https://")?v=g:(console.warn("Could not find a valid HTTP(S) URL in large_image:",g),v="")}o&&f&&v?(y.innerHTML=`
+ ${l|| +
${o}
+ ${l?`
${l}
`:""} +
${f}
+
`,E=!0):o&&f&&(y.innerHTML=`
+

Album art not available.

+
${o}
+ ${l?`
${l}
`:""} +
${f}
+
`,E=!0)}E||(y.innerHTML="

Not listening to music right now.

")}},setInterval(()=>{m.readyState===WebSocket.OPEN&&m.send(JSON.stringify({op:3}))},3e4);function b(){const w=$.offsetHeight,c=Math.max(w-42.5,100);y.style.height=`${c}px`}window.addEventListener("resize",b),window.addEventListener("DOMContentLoaded",b)}function x(){const u=document.getElementById("youtube"),a=document.getElementById("twitter"),i=document.getElementById("mega");u.addEventListener("click",()=>{window.open("https://www.youtube.com/@opiategalore?sub_confirmation=1","_blank")}),a.addEventListener("click",()=>{window.open("https://twitter.com/ctgadse","_blank")}),i.addEventListener("click",()=>{window.open("https://mega.nz/folder/XCx22aYZ#IZykt57yG1StXceL8XqlUQ","_blank")})}function A(){const u="UCLOxpFqdyAab5eCWtHWZ-Zg",a="AIzaSyBt_Yeacmt8K41HZMXGF6K_isMv_eM14mg",i=document.getElementById("youtube-embed-container");if(!i){console.error("Container element not found.");return}const d=`https://www.googleapis.com/youtube/v3/search?key=${a}&channelId=${u}&part=snippet,id&order=date&maxResults=1&type=video`;fetch(d).then(t=>t.ok?t.json():t.json().then(e=>{throw new Error(`HTTP error! Status: ${t.status}, Message: ${e.error.message}`)})).then(t=>{if(t.items&&t.items.length>0){const e=t.items[0].id.videoId;if(e){const s=document.createElement("iframe");s.width="640px",s.height="360px",s.src=`https://www.youtube.com/embed/${e}?autoplay=0&controls=1&rel=0`,s.title="YouTube Video Player",s.frameBorder="0",s.allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",s.allowFullscreen=!0,i.innerHTML="",i.appendChild(s)}else i.innerHTML="

No video ID found for the latest upload.

"}else i.innerHTML="

No videos found on this channel, or an issue occurred with the API response.

"}).catch(t=>{console.error("Error fetching YouTube video:",t),i.innerHTML=`

Failed to load the latest video. Error: ${t.message}

`})}document.querySelector("#app").innerHTML=` +
+
+
+
+ Avatar +
+ +
+ + +
+

Activity: —

+
+
+ +
+
+
+
+

Loading music data...

+
+
+
+
+
+
+

Loading latest video...

+
+
+`;document.addEventListener("DOMContentLoaded",()=>{M(),x(),A()}); diff --git a/edits/img/download-button.png b/edits/img/download-button.png deleted file mode 100644 index eae7903..0000000 Binary files a/edits/img/download-button.png and /dev/null differ diff --git a/edits/img/stem_drfl.jpg b/edits/img/stem_drfl.jpg deleted file mode 100644 index a3df5c3..0000000 Binary files a/edits/img/stem_drfl.jpg and /dev/null differ diff --git a/edits/img/stem_gbgr.jpg b/edits/img/stem_gbgr.jpg deleted file mode 100644 index 299d810..0000000 Binary files a/edits/img/stem_gbgr.jpg and /dev/null differ diff --git a/edits/img/stem_wod.jpg b/edits/img/stem_wod.jpg deleted file mode 100644 index 48dcf8e..0000000 Binary files a/edits/img/stem_wod.jpg and /dev/null differ diff --git a/edits/index.html b/edits/index.html deleted file mode 100644 index 1648a23..0000000 --- a/edits/index.html +++ /dev/null @@ -1,79 +0,0 @@ - - - - - - - Edits | highimnoah - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NameCreation DateDownload
Down Bad16.06.2025Download
Don't Go There
(Full)
14.06.2025Download
Don't Go There
(YT)
14.06.2025Download
Wannabe07.06.2025Download
Reach05.06.2025Download
Tonight20.05.2025Download
For Real18.05.2025Download
Alone07.05.2025Download
Back In04.05.2025Download
All Of It04.05.2025Download
-
-
- - - \ No newline at end of file diff --git a/edits/styles/styles.css b/edits/styles/styles.css deleted file mode 100644 index f1a917e..0000000 --- a/edits/styles/styles.css +++ /dev/null @@ -1,71 +0,0 @@ -@font-face { - font-family: "HelveticaNeueLight"; - src: url(font/HelveticaNeueLight.otf); -} - -@font-face { - font-family: "HelveticaNeueMedium"; - src: url(font/HelveticaNeueMedium.otf); -} - -@font-face { - font-family: "HelveticaNeueBold"; - src: url(font/HelveticaNeueBold.otf); -} - -body { - font-family: "HelveticaNeueLight", sans-serif; - background-color: #9496A6; - display: flex; - justify-content: center; - align-items: center; - height: 100vh; - margin: 0; - flex-direction: column; -} - -.main-content-wrapper { - display: flex; - gap: 20px; - align-items: stretch; -} - -.card { - display: flex; - flex-direction: column; - align-items: center; - justify-content: center; - padding: 20px; - border-radius: 15px; - gap: 20px; - background-color: #F0F0F2; - filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.2)); - width: fit-content; -} - -.file-table { - width: 100%; - border-collapse: collapse; - max-height: 50vh; - overflow-y: scroll; - text-align: center; -} - -.file-table-header-row { - font-family: "HelveticaNeueLight", sans-serif; - font-weight: normal; -} - -.file-table-header-row th { - padding: 0px 4vw; - padding-bottom: 1vh; -} - -.file-table-body-row td { - padding-bottom: 1vh; -} - -.dl-button { - width: 32px; - height: 32px; -} \ No newline at end of file diff --git a/edits/styles/font/HelveticaNeueBold.otf b/font/HelveticaNeueBold.otf similarity index 100% rename from edits/styles/font/HelveticaNeueBold.otf rename to font/HelveticaNeueBold.otf diff --git a/edits/styles/font/HelveticaNeueLight.otf b/font/HelveticaNeueLight.otf similarity index 100% rename from edits/styles/font/HelveticaNeueLight.otf rename to font/HelveticaNeueLight.otf diff --git a/edits/styles/font/HelveticaNeueMedium.otf b/font/HelveticaNeueMedium.otf similarity index 100% rename from edits/styles/font/HelveticaNeueMedium.otf rename to font/HelveticaNeueMedium.otf diff --git a/img/favicon.ico b/img/favicon.ico deleted file mode 100644 index 07c2ceb..0000000 Binary files a/img/favicon.ico and /dev/null differ diff --git a/index.html b/index.html index 8f3ac34..16f97bd 100644 --- a/index.html +++ b/index.html @@ -1,342 +1,17 @@ - - - - - - - Links & Activity | highimnoah - - - - - -
-
-
-
- Avatar -
- -
- - -
-

Activity: —

-
-
- -
-
-
-
-

Loading music data...

-
-
-
-
-
-
-

Loading latest video...

-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + Links & Activity | highimnoah + + + + + + +
+ + \ No newline at end of file diff --git a/js/activity.js b/js/activity.js deleted file mode 100644 index e39b385..0000000 --- a/js/activity.js +++ /dev/null @@ -1,167 +0,0 @@ -const userId = "619810098465734666"; -const favicon = document.getElementById("favicon"); -const avatar = document.getElementById("avatar"); -const username = document.getElementById("username"); -const statusIcon = document.getElementById("status-icon"); -const statusText = document.getElementById("status-text"); -const activity = document.getElementById("activity"); -const mainUserCard = document.querySelector(".user-card"); // Select the first user-card -const musicContainer = document.getElementById("music-container"); - -let presence = null; - -const statusColors = { - online: "status-online", - idle: "status-idle", - dnd: "status-dnd", - offline: "status-offline" -}; - -const socket = new WebSocket("wss://api.lanyard.rest/socket"); - -socket.onopen = () => { - socket.send( - JSON.stringify({ - op: 2, - d: { - subscribe_to_ids: [userId] - } - }) - ); -}; - -socket.onmessage = (event) => { - const data = JSON.parse(event.data); - - if (!data.t || !data.d) return; - - if (data.t === "INIT_STATE") { - presence = data.d[userId]; - } - else if (data.t === "PRESENCE_UPDATE") { - presence = data.d; - } - else return; - - if (!presence || !presence.discord_user) { - username.textContent = "User data not found"; - statusIcon.className = "status-icon"; - statusText.textContent = ""; - activity.textContent = "No activity data available"; - avatar.src = "img/placeholder.png"; - adjustMusicContainerHeight(); // Call after content update - return; - } - - const user = presence.discord_user; - avatar.src = `https://cdn.discordapp.com/avatars/${user.id}/${user.avatar}.png`; - favicon.href = `https://cdn.discordapp.com/avatars/${user.id}/${user.avatar}.png`; - username.textContent = user.username; - - let discordStatus = presence.discord_status || "offline"; - - statusIcon.className = "status-icon"; - - if (statusColors[discordStatus]) { - statusIcon.classList.add(statusColors[discordStatus]); - } - else { - statusIcon.style.backgroundColor = "gray"; - } - - statusText.textContent = discordStatus.charAt(0).toUpperCase() + discordStatus.slice(1); - - if (presence.activities && presence.activities.length > 0) { - const currentActivity = presence.activities.find( - (act) => act.name && act.name !== "Custom Status" - ); - activity.textContent = currentActivity - ? `Activity: ${currentActivity.name}` - : "No activity data available."; - } - else { - activity.textContent = "No activity data available."; - } - - let musicDataFound = false; - if (presence.activities && presence.activities.length > 0) { - const applemusicActivity = presence.activities.find( - (act) => act.type === 2 && act.name === "Apple Music" - ); - - if (applemusicActivity) { - const song = applemusicActivity.details; - const artistFull = applemusicActivity.state; - - let artist = artistFull; - let album = ""; - const parts = artistFull.split(" — "); - if (parts.length >= 2) { - artist = parts[0]; - album = parts.slice(1).join(" — "); - } - - let albumArtUrl = ""; - - if (applemusicActivity.assets && applemusicActivity.assets.large_image) { - let rawImageUrl = applemusicActivity.assets.large_image; - console.log("Raw image URL from Lanyard:", rawImageUrl); - - const indicator = "/https/"; - const indicatorIndex = rawImageUrl.indexOf(indicator); - - if (indicatorIndex !== -1) { - const urlSegment = rawImageUrl.substring(indicatorIndex + indicator.length); - albumArtUrl = "https://" + urlSegment; - } - else if (rawImageUrl.startsWith("https://")) { - albumArtUrl = rawImageUrl; - } - else { - console.warn("Could not find a valid HTTP(S) URL in large_image:", rawImageUrl); - albumArtUrl = ""; - } - } - - if (song && artist && albumArtUrl) { - musicContainer.innerHTML = - `
- ${album ? album : 'Album Art'} -
${song}
- ${album ? `
${album}
` : ""} -
${artist}
-
`; - musicDataFound = true; - } - else if (song && artist) { - musicContainer.innerHTML = - `
-

Album art not available.

-
${song}
- ${album ? `
${album}
` : ""} -
${artist}
-
`; - musicDataFound = true; - } - } - - if (!musicDataFound) { - musicContainer.innerHTML = `

Not listening to music right now.

`; - } - } -}; - -setInterval(() => { - if (socket.readyState === WebSocket.OPEN) { - socket.send(JSON.stringify({ op: 3 })); - } -}, 30000); - -function adjustMusicContainerHeight() { - const userCardHeight = mainUserCard.offsetHeight; - const musicContainerHeight = Math.max(userCardHeight - 40, 100); // Ensure a minimum height of 100px - musicContainer.style.height = `${musicContainerHeight}px`; -} - -window.addEventListener("resize", adjustMusicContainerHeight); -window.addEventListener("DOMContentLoaded", adjustMusicContainerHeight); \ No newline at end of file diff --git a/js/links.js b/js/links.js deleted file mode 100644 index 81ef97f..0000000 --- a/js/links.js +++ /dev/null @@ -1,15 +0,0 @@ -const youtube = document.getElementById("youtube"); -const twitter = document.getElementById("twitter"); -const mega = document.getElementById("mega"); - -youtube.addEventListener("click", () => { - window.open("https://www.youtube.com/@opiategalore?sub_confirmation=1", "_blank"); -}); - -twitter.addEventListener("click", () => { - window.open("https://twitter.com/ctgadse", "_blank"); -}); - -mega.addEventListener("click", () => { - window.open("https://mega.nz/folder/XCx22aYZ#IZykt57yG1StXceL8XqlUQ", "_blank"); -}); \ No newline at end of file diff --git a/js/youtube-embed.js b/js/youtube-embed.js deleted file mode 100644 index 6690d9e..0000000 --- a/js/youtube-embed.js +++ /dev/null @@ -1,52 +0,0 @@ -document.addEventListener("DOMContentLoaded", () => { - const youtubeChannelId = "UCLOxpFqdyAab5eCWtHWZ-Zg"; - const youtubeApiKey = "AIzaSyBt_Yeacmt8K41HZMXGF6K_isMv_eM14mg"; - - const container = document.getElementById("youtube-embed-container"); - - if (!container) { - console.error("Container element not found."); - return; - } - - const apiUrl = `https://www.googleapis.com/youtube/v3/search?key=${youtubeApiKey}&channelId=${youtubeChannelId}&part=snippet,id&order=date&maxResults=1&type=video`; - - fetch(apiUrl) - .then (response => { - if (!response.ok) { - return response.json().then(err => { - throw new Error(`HTTP error! Status: ${response.status}, Message: ${err.error.message}`); - }); - } - return response.json(); - }) - .then (data => { - if (data.items && data.items.length > 0) { - const videoId = data.items[0].id.videoId; - if (videoId) { - const iframe = document.createElement("iframe"); - iframe.className = "youtube-embed"; - iframe.width = "640px"; - iframe.height = "360px"; - iframe.src = `https://www.youtube.com/embed/${videoId}?autoplay=0&controls=1&rel=0`; - iframe.title = "YouTube Video Player"; - iframe.frameBorder = "0"; - iframe.allow = "accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"; - iframe.allowFullscreen = true; - - container.innerHTML = ""; - container.appendChild(iframe); - } - else { - container.innerHTML = "

No video ID found for the latest upload.

"; - } - } - else { - container.innerHTML = "

No videos found on this channel, or an issue occurred with the API response.

"; - } - }) - .catch (error => { - console.error("Error fetching YouTube video:", error); - container.innerHTML = `

Failed to load the latest video. Error: ${error.message}

` - }); -}); \ No newline at end of file diff --git a/img/mega.png b/mega.png similarity index 100% rename from img/mega.png rename to mega.png diff --git a/img/placeholder.png b/placeholder.png similarity index 100% rename from img/placeholder.png rename to placeholder.png diff --git a/styles/font/HelveticaNeueBold.otf b/styles/font/HelveticaNeueBold.otf deleted file mode 100644 index f44af64..0000000 Binary files a/styles/font/HelveticaNeueBold.otf and /dev/null differ diff --git a/styles/font/HelveticaNeueLight.otf b/styles/font/HelveticaNeueLight.otf deleted file mode 100644 index de55b68..0000000 Binary files a/styles/font/HelveticaNeueLight.otf and /dev/null differ diff --git a/styles/font/HelveticaNeueMedium.otf b/styles/font/HelveticaNeueMedium.otf deleted file mode 100644 index 1a2a9df..0000000 Binary files a/styles/font/HelveticaNeueMedium.otf and /dev/null differ diff --git a/styles/styles.css b/styles/styles.css deleted file mode 100644 index ae775c6..0000000 --- a/styles/styles.css +++ /dev/null @@ -1,232 +0,0 @@ -@font-face { - font-family: "HelveticaNeueLight"; - src: url(font/HelveticaNeueLight.otf); -} - -@font-face { - font-family: "HelveticaNeueMedium"; - src: url(font/HelveticaNeueMedium.otf); -} - -@font-face { - font-family: "HelveticaNeueBold"; - src: url(font/HelveticaNeueBold.otf); -} - -body { - font-family: "HelveticaNeueLight", sans-serif; - background-color: #9496A6; - display: flex; - justify-content: center; - align-items: center; - height: 100vh; - margin: 0; - flex-direction: column; -} - -.main-content-wrapper { - display: flex; - gap: 20px; - align-items: stretch; -} - -.user-card { - display: flex; - flex-direction: column; - align-items: center; - padding: 20px; - border-radius: 15px; - gap: 20px; - background-color: #F0F0F2; - filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.2)); - width: fit-content; -} - -.user-main-info { - display: flex; - align-items: center; - gap: 20px; -} - -.avatar { - width: 80px; - height: 80px; - border-radius: 50%; - object-fit: cover; - border: 2px solid #F0F0F2; - filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.3)); -} - -.social-links { - display: flex; - justify-content: center; - gap: 20px; - margin-top: 10px; -} - -.link-logo { - width: 80px; - height: 80px; - filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.4)); -} - -.user-details { - flex: 1; - position: relative; - top: +5px; -} - -.user-info { - display: flex; - align-items: center; - margin-bottom: 10px; - width: fit-content; -} - -.user-info span { - font-weight: 400; - font-size: 18px; -} - -.status { - display: flex; - align-items: center; - gap: 10px; - margin-bottom: 10px; - width: fit-content; -} - -.status-icon { - width: 10px; - height: 10px; - border-radius: 50%; - display: inline-block; - background-color: gray; -} - -.status-online { - background-color: #43A25A; -} - -.status-idle { - background-color: #CA9654; -} - -.status-dnd { - background-color: #D83A42; -} - -.status-offline { - background-color: #747F8D; -} - -#activity { - width: fit-content; -} - -#youtube, -#twitter, -#mega { - transition: transform 0.15s ease-in-out; -} - -#youtube:hover, -#twitter:hover, -#mega:hover { - cursor: pointer; - transform: scale(1.05); -} - -.track-name { - font-family: "HelveticaNeueMedium", sans-serif; - font-size: 16px; - text-align: center; - margin-bottom: 5px; -} - -.track-album { - font-family: "HelveticaNeueLight", sans-serif; - font-size: 16px; - text-align: center; - margin-bottom: 5px; -} - -.track-artist { - font-family: "HelveticaNeueLight", sans-serif; - font-size: 16px; - text-align: center; -} - -.album-art { - width: 100px; - height: 100px; - border-radius: 15px; - filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.3)); - margin-bottom: 15px; - display: block; - margin-left: auto; - margin-right: auto; -} - -#music-container { - display: flex; - flex-direction: column; - align-items: center; - justify-content: center; -} - -.song-card-container { - display: flex; - flex-direction: column; - align-items: center; - gap: 5px; - width: inherit; - overflow-y: scroll; - overflow-x: hidden; - max-height: 40vh; - scroll-behavior: smooth; -} - -.song-card { - display: flex; - padding: 10px; - background: #F0F0F2; - border-radius: 15px; - filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.3)); - justify-content: space-evenly; - width: 600px; -} - -.song-cover { - width: 80px; - height: 80px; - border-radius: 10px; - object-fit: cover; - border: 2px solid #F0F0F2; - filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.3)); -} - -.song-title { - font-weight: 600; -} - -.file-size, -.song-length { - font-weight: 300; -} - -.download-icon { - width: 80px; - height: 80px; - filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.4)); - transition: transform 0.15s ease-in-out; -} - -.download-icon:hover { - cursor: pointer; - transform: scale(1.05); -} - -.youtube-embed { - border-radius: 15px; -} \ No newline at end of file diff --git a/img/twitter.png b/twitter.png similarity index 100% rename from img/twitter.png rename to twitter.png diff --git a/img/youtube.png b/youtube.png similarity index 100% rename from img/youtube.png rename to youtube.png