begin image sourcing for view page, remove useless comments
This commit is contained in:
@@ -115,11 +115,13 @@ const load = () => {
|
||||
if (isValidURL(game.target)) createViewPage({
|
||||
target: game.target,
|
||||
title: game.name,
|
||||
image: game.image,
|
||||
proxied: true
|
||||
});
|
||||
else createViewPage({
|
||||
target: game.target,
|
||||
title: game.name
|
||||
title: game.name,
|
||||
image: game.image
|
||||
});
|
||||
}, 500);
|
||||
});
|
||||
|
||||
@@ -132,7 +132,8 @@ export const createViewPage = (options) => location.href = `/view?load=${btoa(JS
|
||||
return: options.return || location.href,
|
||||
proxied: options.proxied,
|
||||
target: options.target,
|
||||
title: options.title
|
||||
title: options.title,
|
||||
image: options.image
|
||||
}))}`;
|
||||
|
||||
/**
|
||||
|
||||
@@ -54,40 +54,6 @@ if (params.get('load')) {
|
||||
else if (frame.msRequestFullscreen) frame.msRequestFullscreen();
|
||||
});
|
||||
|
||||
/*
|
||||
No
|
||||
|
||||
document.querySelector('#discord-join').addEventListener('click', () => {
|
||||
use the createViewPage function to load the page
|
||||
document.getElementById('loadframe').src = "/uv/service/hvtrs8%2F-dksaopd%2Ccmm-ilvktg%2Fqkmon-aoomwnkt%7B-%3B52427%3B3142839%3A737";
|
||||
swal("How would you like to open this?", {
|
||||
buttons: {
|
||||
cancel: "Cancel",
|
||||
proxy: {
|
||||
text: "Proxy",
|
||||
value: "proxy",
|
||||
},
|
||||
newtab: true,
|
||||
},
|
||||
})
|
||||
.then((value) => {
|
||||
switch (value) {
|
||||
|
||||
case "newtab":
|
||||
window.open("https://dsc.gg/skoolworld", '_blank').focus();
|
||||
break;
|
||||
|
||||
case "proxy":
|
||||
document.getElementById('loadframe').src = "/uv/service/hvtrs8%2F-dksaopd%2Ccmm-ilvktg%2Fqkmon-aoomwnkt%7B-%3B52427%3B3142839%3A737";
|
||||
break;
|
||||
|
||||
default:
|
||||
bruv what
|
||||
swal("you should have joined the server 🙄");
|
||||
}
|
||||
});
|
||||
});*/
|
||||
|
||||
window.addEventListener('fullscreenchange', () => {
|
||||
if (document.fullscreenElement) document.querySelector('#loadframe').style.borderRadius = '0px';
|
||||
else document.querySelector('#loadframe').style.borderRadius = '';
|
||||
|
||||
Reference in New Issue
Block a user