feat: add serverless newsletter signup page

Adds newsletter.html with an email signup form that POSTs to a configured
serverless endpoint. The endpoint and API token live in
js/newsletter-config.js (token defaults to an empty deploy-time placeholder,
never hardcoded in page logic). Missing/invalid tokens and network failures
surface a fixed user-safe error; successful signups show a confirmation.
Links the page from the site navigation on all pages.
This commit is contained in:
bot-implementer
2026-08-25 19:15:56 +00:00
parent e24ba8916d
commit 24db5b8a50
7 changed files with 215 additions and 0 deletions
+24
View File
@@ -120,6 +120,30 @@ button[type="submit"]:hover {
filter: brightness(1.1);
}
/* --- Newsletter signup --- */
.newsletter-form {
max-width: 36rem;
display: grid;
gap: 1rem;
}
.newsletter-form .form-field input {
max-width: 24rem;
}
.newsletter-status {
margin: 0;
font-weight: 600;
}
.newsletter-status[data-kind="success"] {
color: #1e7e34;
}
.newsletter-status[data-kind="error"] {
color: #b3261e;
}
/* --- Reading list --- */
.reading-category {
margin-bottom: 2rem;