updated projects-details

This commit is contained in:
Jonas_Jones 2023-09-01 20:44:12 +02:00
parent 16b30c2454
commit bcabf6f47b
41 changed files with 110 additions and 23 deletions

View file

@ -0,0 +1,87 @@
<script>
let images = [];
let selectedSquares = new Set();
let loading = false;
const fetchImages = () => {
loading = true;
// Load images from the /areyouarobot folder
// You can replace this with your image loading logic
setTimeout(() => {
// Simulate loading images with random properties (e.g., 'X', 'O', etc.)
for (let i = 0; i < 16; i++) {
const imageId = images.length + i;
const row = Math.floor(i / 4);
const col = i % 4;
const property = Math.random() > 0.5 ? 'X' : 'O'; // Simulate random properties
console.log("imageId: " + imageId + " row: " + row + " col: " + col + " property: " + property)
images.push({
id: imageId,
src: `/image_${row}_${col}.jpg`,
property: property
});
}
loading = false;
}, 1000);
};
const toggleSquareSelection = (image) => {
if (selectedSquares.has(image.id)) {
selectedSquares.delete(image.id);
} else {
selectedSquares.add(image.id);
}
};
window.addEventListener("scroll", () => {
if (
!loading &&
window.innerHeight + window.scrollY >= document.body.offsetHeight - 200
) {
fetchImages();
}
});
// Initial load
fetchImages();
</script>
<style>
.grid {
display: grid;
grid-template-columns: repeat(4, 1fr);
gap: 10px;
}
.image {
width: 150px;
height: 150px;
object-fit: cover;
border: 2px solid transparent;
cursor: pointer;
}
.selected {
border-color: blue;
}
</style>
<div class="grid">
{#each images as image}
<img
class="image {selectedSquares.has(image.id) ? 'selected' : ''}"
src={image.src}
alt={`Image ${image.id}`}
on:click={() => toggleSquareSelection(image)}
/>
{/each}
{#if loading}
<p>Loading...</p>
{/if}
</div>
<div>
<p>Selected squares: {Array.from(selectedSquares).join(', ')}</p>
</div>

View file

@ -45,7 +45,7 @@
"MR": ""
},
"visible": true,
"last_update": 1690149600
"last_update": 1693498044
},
{
"title": "Minecraft Server Status",
@ -67,7 +67,7 @@
"WB": "/projects/Minecraft-server-Status"
},
"visible": true,
"last_update": 1693493400
"last_update": 1693493323
},
{
"title": "Microcraft",
@ -91,7 +91,7 @@
"WB": "/projects/Microcraft"
},
"visible": true,
"last_update": 1687644000
"last_update": 1687716436
},
{
"title": "Not Enough Cursedness",
@ -116,7 +116,7 @@
"MR": "https://modrinth.com/mod/not-enough-cursedness"
},
"visible": true,
"last_update": 1684101600
"last_update": 1693578304
},
{
"title": "DayZ Linux GUI Launcher",
@ -139,7 +139,7 @@
"WB": "/projects/dayz-linux-gui-launcher"
},
"visible": true,
"last_update": 1682373600
"last_update": 1682450521
},
{
"title": "ConsoleMC",
@ -164,7 +164,7 @@
"MR": "https://modrinth.com/mod/consolemc"
},
"visible": true,
"last_update": 1682028000
"last_update": 1693577984
},
{
"title": "Better ConsoleMC",
@ -189,7 +189,7 @@
"MR": "https://modrinth.com/mod/betterconsolemc"
},
"visible": true,
"last_update": 1682028000
"last_update": 1682021696
},
{
"title": "MC Webserver",
@ -213,7 +213,7 @@
"WB": "/projects/McWebserver"
},
"visible": true,
"last_update": 1682028000
"last_update": 1682021172
},
{
"title": "MysteryMod",
@ -237,7 +237,7 @@
"WB": "/projects/MysteryMod"
},
"visible": true,
"last_update": 1682028000
"last_update": 1682021093
},
{
"title": "Jonas_Jones API",
@ -283,7 +283,7 @@
"WB": "https://old.jonasjones.dev"
},
"visible": true,
"last_update": 1675206000
"last_update": 1675278057
},
{
"title": "MC Webserver Forge",
@ -308,7 +308,7 @@
"CF": "https://www.curseforge.com/minecraft/mc-mods/mcwebserver"
},
"visible": true,
"last_update": 1674946800
"last_update": 1675010407
},
{
"title": "Windows Bloatware Remover",
@ -330,7 +330,7 @@
"WB": "/projects/WindowsBloatwareRemover"
},
"visible": true,
"last_update": 1661724000
"last_update": 1661781655
},
{
"title": "Windows Info Overlay",
@ -377,7 +377,7 @@
"WB": "/projects/BetterSimpleConfig"
},
"visible": true,
"last_update": 1670886000
"last_update": 1670967961
},
{
"title": "QR Generator",
@ -463,7 +463,7 @@
"WB": "/projects/moddah"
},
"visible": true,
"last_update": 1666044000
"last_update": 1666039028
},
{
"title": "Bash Command Alias Editor",
@ -484,7 +484,7 @@
"WB": "/projects/BashCommandAliasEditor"
},
"visible": true,
"last_update": 1663624800
"last_update": 1663678509
},
{
"title": "PI Server Rack",
@ -507,7 +507,7 @@
"WB": "/projects/PI-server-rack"
},
"visible": true,
"last_update": 1662242400
"last_update": 1662319681
},
{
"title": "PinBoardBot",
@ -529,7 +529,7 @@
"WB": "/projects/PinBoardBot"
},
"visible": true,
"last_update": 1662156000
"last_update": 1662197814
},
{
"title": "Winception",
@ -648,7 +648,7 @@
"WB": "/projects/SyncMod"
},
"visible": false,
"last_update": 1656194400
"last_update": 1658851640
},
{
"title": "SpotifyMC",
@ -672,7 +672,7 @@
"WB": "/projects/SpotifyMC"
},
"visible": false,
"last_update": 1651356000
"last_update": 1651432501
},
{
"title": "SiMP Resourcepack",
@ -693,7 +693,7 @@
"WB": "/projects/simp-resourcepack"
},
"visible": true,
"last_update": 1643410800
"last_update": 1643477940
},
{
"title": "Image Converter",
@ -715,7 +715,7 @@
"WB": "/projects/ImageConverter"
},
"visible": true,
"last_update": 1642719600
"last_update": 1642718415
},
{
"title": "J2 Technologies",
@ -737,7 +737,7 @@
"WB": "/projects/j2-technologies"
},
"visible": true,
"last_update": 1642201200
"last_update": 1642248415
},
{
"title": "Make ZIP less compact",
@ -808,4 +808,4 @@
"visible": false,
"updated": 1641337200
}
]
]