feat(web): Sessions, Rate-Limiting, Security-Header, Templates und eingebettete Assets

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NBHF4R9EAejDJUMdwr6C68
This commit is contained in:
Carsten Abele 2026-08-14 09:20:38 +02:00
parent e49882b8a8
commit bb2bc223b9
16 changed files with 1292 additions and 0 deletions

View file

@ -0,0 +1,37 @@
{{define "layout"}}<!DOCTYPE html>
<html lang="de">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="robots" content="noindex, nofollow">
<title>{{.Brand.Title}}</title>
<link rel="stylesheet" href="/assets/style.css">
</head>
<body>
<header class="topbar">
<div class="brand">
{{if .Brand.HasLogo}}<img src="/assets/logo" alt="" class="logo">{{end}}
<span class="brand-title">{{.Brand.Title}}</span>
</div>
{{if .User}}
<nav class="topnav">
<a href="/anleitungen">{{t "guides_link"}}</a>
<span class="user">{{.User}}</span>
<form method="post" action="/logout" class="inline">
<input type="hidden" name="csrf_token" value="{{.CSRF}}">
<button type="submit" class="secondary">{{t "logout"}}</button>
</form>
</nav>
{{end}}
</header>
<main>
{{if .Flash}}<div class="flash flash-{{.FlashKind}}" role="status">{{.Flash}}</div>{{end}}
{{block "content" .}}{{end}}
</main>
<footer class="footer">
<span>{{t "footer_version"}} {{.Brand.Version}}</span>
</footer>
</body>
</html>{{end}}