Map-Bilder und Seitenwahl mit Emblemen
Map-Bilder aus ghostcap-gaming/cs2-map-images lokal als WebP gespeichert (npm run images lädt und verkleinert sie). Bilder in Veto-Kacheln, Pool-Vorschau, Serie und Seitenwahl; CT/T-Embleme aus client/public/sides mit Ersatzsymbol, falls die Dateien fehlen.
This commit is contained in:
1 parent
e304556346
commit
7be0d85ab5
21 files changed
+701
-27
No files matched your search
@@ -17,6 +17,9 @@ export function buildMapPools(raw) {
|
||||
for (const map of pool.maps ?? []) {
|
||||
if (!/^[a-z0-9_]+$/.test(map.id)) throw new Error(`Ungültige Map-ID "${map.id}" im Pool "${mode}"`);
|
||||
if (ids.has(map.id)) throw new Error(`Map "${map.id}" ist im Pool "${mode}" doppelt`);
|
||||
if (map.image !== undefined && !/^(https?:\/\/|\/)[^\s"'()<>]+$/.test(map.image)) {
|
||||
throw new Error(`Bild für "${map.id}" im Pool "${mode}" muss eine http(s)-URL oder ein Pfad mit / sein`);
|
||||
}
|
||||
ids.add(map.id);
|
||||
}
|
||||
const formats = {};
|
||||
|
||||
Reference in new issue
Block a user