This commit is contained in:
19
js/all.min.js
vendored
19
js/all.min.js
vendored
@ -17,6 +17,23 @@ loadAnalytics.cloudflare = function() {
|
||||
script.setAttribute("data-cf-beacon", '{"token": "e5b0ef8807e74cef81287ac77bd18938"}');
|
||||
document.head.appendChild(script);
|
||||
};
|
||||
loadAnalytics.google = function() {
|
||||
// <script async src="https://www.googletagmanager.com/gtag/js?id=G-63PV9BWZK5"></script>
|
||||
let script = document.createElement("script");
|
||||
script.setAttribute("async", "");
|
||||
script.setAttribute("src", "https://www.googletagmanager.com/gtag/js?id=G-63PV9BWZK5");
|
||||
document.head.appendChild(script);
|
||||
/* <script>
|
||||
window.dataLayer = window.dataLayer || [];
|
||||
function gtag(){dataLayer.push(arguments);}
|
||||
gtag('js', new Date());
|
||||
|
||||
gtag('config', 'G-63PV9BWZK5');
|
||||
</script> */
|
||||
let script2 = document.createElement("script");
|
||||
script2.innerText = "window.dataLayer = window.dataLayer || [];function gtag(){dataLayer.push(arguments);}gtag('js', new Date());gtag('config', 'G-63PV9BWZK5');";
|
||||
|
||||
}
|
||||
|
||||
function antiSkid() {
|
||||
if(window != window.parent && location.hostname != new URL(document.referrer).hostname) {
|
||||
@ -49,5 +66,7 @@ document.addEventListener("DOMContentLoaded", () => {
|
||||
// yo why are all analytic providers mid
|
||||
// loadAnalytics.unami();
|
||||
// loadAnalytics.cloudflare();
|
||||
// bag under eyes emoji
|
||||
loadAnalytics.google();
|
||||
antiSkid();
|
||||
})
|
||||
@ -60,7 +60,7 @@ async function loadGames() {
|
||||
gore.classList = "gore";
|
||||
warnings.appendChild(gore);
|
||||
}
|
||||
if(element.tags.includes("top")) {
|
||||
if(element.tags.includes("top") && localStorage.getItem("selenite.disableTopGames") != "false") {
|
||||
topGElement.appendChild(newElement);
|
||||
} else {
|
||||
gamesElement.appendChild(newElement);
|
||||
@ -84,7 +84,9 @@ async function loadGames() {
|
||||
document.getElementById("gameCount").innerText = `${data.length} games loaded!`;
|
||||
document.getElementById("loadingMsg").style.display = "none";
|
||||
document.getElementById("allHeader").style.display = "block";
|
||||
document.getElementById("topHeader").style.display = "block";
|
||||
if(localStorage.getItem("selenite.disableTopGames") != "false") {
|
||||
document.getElementById("topHeader").style.display = "block";
|
||||
}
|
||||
if(isDev.length > 0) {sAlert("wip games", "dev message, shouldnt be seen");console.log(isDev.join(","))};
|
||||
starredGames = JSON.parse(localStorage.getItem("selenite.starred") || '[]');
|
||||
if(starredGames.length > 0) {
|
||||
|
||||
@ -13,7 +13,7 @@ function loadPJS() {
|
||||
script.src = "https://cdn.jsdelivr.net/particles.js/2.0.0/particles.min.js";
|
||||
document.head.appendChild(script);
|
||||
script.addEventListener("load", ()=>{
|
||||
particlesJS.load('pjs', "/js/christmas-particlesjs-config.json", ()=>{});
|
||||
particlesJS.load('pjs', "/js/main-particlesjs-config.json", ()=>{});
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user