Merge branch 'main' of https://codeberg.org/MonkeyGG2/MonkeyGG2-v2
This commit is contained in:
+1
-1
@@ -813,7 +813,7 @@
|
||||
// coming soon
|
||||
},
|
||||
"config": {
|
||||
"proxy": true, // proxy only works when self-hosted
|
||||
"proxy": false, // proxy only works when self-hosted
|
||||
"proxyPath": "http://localhost:8080" // absolute or relative path to proxy; proxy must be set to true for this setting to have any effect
|
||||
}
|
||||
}
|
||||
@@ -191,6 +191,16 @@ body.noscript {
|
||||
background-color: var(--hover-color);
|
||||
}
|
||||
|
||||
.star {
|
||||
cursor: pointer;
|
||||
color: #ccc;
|
||||
float: right;
|
||||
}
|
||||
|
||||
.filled {
|
||||
color: gold;
|
||||
}
|
||||
|
||||
.searchbar {
|
||||
display: flex;
|
||||
width: 75%;
|
||||
|
||||
@@ -211,6 +211,12 @@ $("#sort").on("change", updateList);
|
||||
dragElement(document.getElementById("gameButton"));
|
||||
dragElement(document.getElementById("refresh"));
|
||||
|
||||
function toggleStar(event, star) {
|
||||
event.preventDefault();
|
||||
event.stopPropagation();
|
||||
star.classList.toggle('filled');
|
||||
}
|
||||
|
||||
/**
|
||||
* Adds drag functionality to an HTML element.
|
||||
*
|
||||
|
||||
+1
-1
@@ -25,7 +25,7 @@ fetch("./config.jsonc").then((e) => e.text()).then((jsonc) => {
|
||||
|
||||
let gamesList = $("#gamesList");
|
||||
for (game in games) {
|
||||
gamesList.append(`<li url="games/${games[game]["path"]}" ${games[game]["aliases"] ? "aliases=\"" + games[game]["aliases"].join(',') + "\"" : ''}>${game}</li>`);
|
||||
gamesList.append(`<li url="games/${games[game]["path"]}" ${games[game]["aliases"] ? "aliases=\"" + games[game]["aliases"].join(',') + "\"" : ''}>${game} <span class="star" onclick="toggleStar(event, this)">★</span> </li>`);
|
||||
}
|
||||
|
||||
$("#gamesList li").on("click", function() {
|
||||
|
||||
Reference in New Issue
Block a user