feat: legal notice and privacy policy as Markdown or link
Admins set the platform's documents, linked in the footer of the console and sign-in pages and served at /legal/<kind>. Organizations set their own for their status pages, falling back to the platform's. Documents travel in the status page snapshot, so status page servers serve them at /<slug>/imprint and /imprint on custom domains during API outages too. Markdown is rendered with goldmark, which drops raw HTML and unsafe links; stored links must be http or https. Closes #67 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017GpWAskjmYtZpuQ5JwYTX3
This commit is contained in:
1 parent
4134af4aef
commit
73eb0f8bcd
26 files changed
+1278
-64
No files matched your search
@@ -11,6 +11,8 @@ type Page struct {
|
||||
// typically after a redirect back from an SSO flow.
|
||||
ErrorID string
|
||||
NoticeID string
|
||||
// Legal links the platform's legal notice and privacy policy.
|
||||
Legal []LegalLink
|
||||
}
|
||||
|
||||
templ Layout(p Page) {
|
||||
@@ -27,8 +29,11 @@ templ Layout(p Page) {
|
||||
<script src="/static/dist/axios.min.js" defer></script>
|
||||
<script src="/static/dist/app.js" defer></script>
|
||||
</head>
|
||||
<body class="min-h-screen" data-msg-network={ i18n.T(ctx, "app.network_error") }>
|
||||
{ children... }
|
||||
<body class="flex min-h-screen flex-col" data-msg-network={ i18n.T(ctx, "app.network_error") }>
|
||||
<div class="flex-1">
|
||||
{ children... }
|
||||
</div>
|
||||
@legalFooter(p.Legal)
|
||||
</body>
|
||||
</html>
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user