New Meta-Line

This commit is contained in:
2026-06-24 10:21:40 +02:00
parent 112e1f82ca
commit 32c70ad0f8
2 changed files with 10 additions and 7 deletions
+7
View File
@@ -211,8 +211,15 @@ img.avatar-lg { width: 72px; height: 72px; }
align-items: center; align-items: center;
gap: 0.5rem; gap: 0.5rem;
font-size: 1rem; font-size: 1rem;
/* Versuchsweise die Titel-Display-Schrift (wie h1/h2) in der Meta-Zeile. */
font-family: "Cheltenham Classic", serif;
} }
/* Die globale Regel `span, a { font-size: 1.2rem }` trifft das Datum/Cooldown-
span direkt und macht es größer als den Username-Link (der über `.muted a`
auf 1rem liegt). Hier explizit angleichen -> ganze Meta-Zeile gleich groß. */
.byline span { font-size: 1rem; }
/* Profilkopf: großer Avatar links neben Name und "Mitglied seit". */ /* Profilkopf: großer Avatar links neben Name und "Mitglied seit". */
.profile-head { .profile-head {
display: flex; display: flex;
+3 -7
View File
@@ -126,22 +126,18 @@ document.getElementById("entry-form").addEventListener("paste", (e) => {
// --- Statuszeile unter dem Titel --- // --- Statuszeile unter dem Titel ---
// Tage ohne Datenverlust (fester Startpunkt, Kontinuität seit der alten // Tage ohne Datenverlust (fester Startpunkt, Kontinuität seit der alten
// Version) plus aktuelle Kennzahlen aus /stats. // Version).
const dataLossStart = new Date("2025-12-13T12:44:00").getTime(); const dataLossStart = new Date("2025-12-13T12:44:00").getTime();
function plural(n, one, many) { function plural(n, one, many) {
return `${n} ${n === 1 ? one : many}`; return `${n} ${n === 1 ? one : many}`;
} }
async function renderStats() { function renderStats() {
const el = document.getElementById("stats"); const el = document.getElementById("stats");
if (!el) return; if (!el) return;
const days = Math.floor((Date.now() - dataLossStart) / 86400000); const days = Math.floor((Date.now() - dataLossStart) / 86400000);
const s = await api.get("/stats"); el.textContent = `Ohne Datenverlust seit ${plural(days, "Tag", "Tagen")}`;
el.textContent =
`Ohne Datenverlust seit ${plural(days, "Tag", "Tagen")} · ` +
`${plural(s.users ?? 0, "Profil", "Profile")} · ` +
`${plural(s.entries ?? 0, "Beitrag", "Beiträge")}`;
} }
// --- Start --- // --- Start ---