From f070ea33c03505acb7bae248d65ca5fe3a861941 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Lohrer?= Date: Wed, 15 Apr 2026 14:21:34 +0200 Subject: [PATCH] spike(spa-mini): url-routing, post-liste mit thumbnails, streaming-load MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Liest dtag aus URL-Pfad (SPA-Navigation via History-API) und zeigt Liste auf /, Einzelpost auf //. Interne Links ohne Reload, Browser-Back funktioniert. Streaming-Load via pool.subscribeMany: Events werden angezeigt, sobald das erste Relay antwortet, statt auf alle 5 zu warten. Deutlich bessere Reaktionszeit. Liste mit Cover-Thumbnail links, Titel+Summary+Datum rechts. Responsive: unter 480px stapelt sich Bild über Text. Co-Authored-By: Claude Opus 4.6 (1M context) --- preview/spa-mini/index.html | 283 ++++++++++++++++++++++++++++++------ 1 file changed, 240 insertions(+), 43 deletions(-) diff --git a/preview/spa-mini/index.html b/preview/spa-mini/index.html index 4bbb3ab..a338aa0 100644 --- a/preview/spa-mini/index.html +++ b/preview/spa-mini/index.html @@ -39,20 +39,63 @@ max-width: 720px; margin: 0 auto; } - header.banner, - .intro { + header.banner { border: 1px solid var(--border); border-radius: 6px; padding: 0.7rem 1rem; - margin-bottom: 1rem; + margin-bottom: 1.5rem; background: var(--code-bg); font-size: 0.85rem; color: var(--muted); } - .intro { - margin-bottom: 2rem; - } header.banner strong { color: var(--fg); } + nav#breadcrumb { + font-size: 0.9rem; + margin-bottom: 1rem; + } + nav#breadcrumb a { color: var(--accent); text-decoration: none; } + nav#breadcrumb a:hover { text-decoration: underline; } + .post-list-item { + display: flex; + gap: 1rem; + padding: 1rem 0; + border-bottom: 1px solid var(--border); + color: inherit; + text-decoration: none; + align-items: flex-start; + } + .post-list-item:hover { background: var(--code-bg); } + .post-list-item .thumb { + flex: 0 0 120px; + aspect-ratio: 1 / 1; + border-radius: 4px; + background: var(--code-bg) center/cover no-repeat; + } + .post-list-item .text { flex: 1; min-width: 0; } + .post-list-item h2 { + margin: 0 0 0.3rem; + font-size: 1.2rem; + color: var(--fg); + word-wrap: break-word; + } + .post-list-item .excerpt { + color: var(--muted); + font-size: 0.95rem; + margin: 0; + } + .post-list-item .list-meta { + font-size: 0.85rem; + color: var(--muted); + margin-bottom: 0.2rem; + } + @media (max-width: 479px) { + .post-list-item { flex-direction: column; gap: 0.5rem; } + .post-list-item .thumb { flex: 0 0 auto; width: 100%; aspect-ratio: 2 / 1; } + } + .list-title { + margin: 0 0 1rem; + font-size: 1.4rem; + } h1.post-title { font-size: 1.5rem; line-height: 1.25; @@ -156,20 +199,19 @@
-
- Eigenständig signiertes kind:30023-Event (NIP-23), - geladen über nostr-tools via WebSocket aus mehreren Relays. - Markdown-Rendering: marked + DOMPurify. - Bild via Blossom-Server. Kein Server-Backend, nur statisches HTML - plus JavaScript im Browser. -
+
-

Lade Post von Nostr-Relays …

+

Lade von Nostr-Relays …