rimworld-blax-laws/Source/Art/header.html

47 lines
4.0 KiB
HTML
Raw Permalink Normal View History

<!doctype html>
<html>
<head>
<meta charset="utf-8">
<!-- Section header for the Workshop page, 1270x150 (shown at half size). Parameters: ?t=Title&s=Subtitle&i=icon -->
<style>
@font-face { font-family: Geist; src: url(fonts/geist.woff2) format("woff2"); font-weight: 100 900; }
@font-face { font-family: Inter; src: url(fonts/inter.woff2) format("woff2"); font-weight: 100 900; }
:root {
--background: #050805;
--accent: #19C63C;
--heading: oklch(98% .008 145);
--muted-foreground: oklch(75% .015 145);
--border: oklch(30% .016 145);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { width: 1270px; height: 150px; background: var(--background); overflow: hidden; }
body { font-family: Inter, sans-serif; display: flex; align-items: center; gap: 32px; padding: 0 56px; border-bottom: 4px solid var(--accent); }
svg.icon { width: 64px; height: 64px; flex: none; color: var(--accent); }
h1 { font-family: Geist, sans-serif; font-weight: 600; font-size: 54px; line-height: 1; letter-spacing: -0.035em; color: var(--heading); }
p { margin-top: 10px; font-size: 25px; line-height: 1.2; color: var(--muted-foreground); }
.mark { margin-left: auto; width: 52px; height: 52px; opacity: .35; }
</style>
</head>
<body>
<svg class="icon" viewBox="0 0 24 24" id="icon"></svg>
<div><h1 id="t"></h1><p id="s"></p></div>
<img class="mark" src="blax-monogram.svg" alt="">
<script>
// lucide icons (ISC license), from api.iconify.design/lucide
const icons = {
'book-open-text': '<path fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 5v16m4-8h2m-2-4h2m2.001 10A2 2 0 0 0 22 17V5a2 2 0 0 0-1.999-2L16 3.002A5 5 0 0 0 12 5a5 5 0 0 0-4-2H4a2 2 0 0 0-2 2v12a2 2 0 0 0 1.999 2H8a5 5 0 0 1 4 2a5 5 0 0 1 4-2zM6 13h2M6 9h2"/>',
fingerprint: '<g fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"><path d="M12 10a2 2 0 0 0-2 2c0 1.02-.1 2.51-.26 4M14 13.12c0 2.38 0 6.38-1 8.88m4.29-.98c.12-.6.43-2.3.5-3.02M2 12a10 10 0 0 1 18-6M2 16h.01m19.79 0c.2-2 .131-5.354 0-6"/><path d="M5 19.5C5.5 18 6 15 6 12a6 6 0 0 1 .34-2m2.31 12c.21-.66.45-1.32.57-2M9 6.8a6 6 0 0 1 9 5.2v2"/></g>',
'lock-keyhole': '<g fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"><circle cx="12" cy="16" r="1"/><rect width="18" height="12" x="3" y="10" rx="2"/><path d="M7 10V7a5 5 0 0 1 10 0v3"/></g>',
scale: '<g fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"><path d="M12 3v18m7-13l3 8a5 5 0 0 1-6 0zV7"/><path d="M3 7h1a17 17 0 0 0 8-2a17 17 0 0 0 8 2h1M5 8l3 8a5 5 0 0 1-6 0zV7m2 14h10"/></g>',
gavel: '<path fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="m14 13l-8.381 8.38a1 1 0 0 1-3.001-3l8.384-8.381M16 16l6-6m-.5.5l-8-8M8 8l6-6M8.5 7.5l8 8"/>',
puzzle: '<path fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15.39 4.39a1 1 0 0 0 1.68-.474a2.5 2.5 0 1 1 3.014 3.015a1 1 0 0 0-.474 1.68l1.683 1.682a2.414 2.414 0 0 1 0 3.414L19.61 15.39a1 1 0 0 1-1.68-.474a2.5 2.5 0 1 0-3.014 3.015a1 1 0 0 1 .474 1.68l-1.683 1.682a2.414 2.414 0 0 1-3.414 0L8.61 19.61a1 1 0 0 0-1.68.474a2.5 2.5 0 1 1-3.014-3.015a1 1 0 0 0 .474-1.68l-1.683-1.682a2.414 2.414 0 0 1 0-3.414L4.39 8.61a1 1 0 0 1 1.68.474a2.5 2.5 0 1 0 3.014-3.015a1 1 0 0 1-.474-1.68l1.683-1.682a2.414 2.414 0 0 1 3.414 0z"/>',
milestone: '<path fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 13v8m0-18v3m6.172 0a2 2 0 0 1 1.414.586l2.06 2.06a1.207 1.207 0 0 1 0 1.708l-2.06 2.06a2 2 0 0 1-1.414.586H4a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1z"/>'
};
const q = new URLSearchParams(location.search);
document.getElementById('t').textContent = q.get('t') || 'Title';
document.getElementById('s').textContent = q.get('s') || '';
document.getElementById('icon').innerHTML = icons[q.get('i')] || '';
</script>
</body>
</html>