Free
Newsletter
Sabela Rooke Newsletter
A newsletter block extracted from the Sabela Rooke template, available in Tailwind CSS.
0
0
A newsletter block extracted from the Sabela Rooke template, available in Tailwind CSS.
<!DOCTYPE html>
<html lang="en">
<head>
<script>
window.FontAwesomeConfig = { autoReplaceSvg: 'nest' };
</script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/js/all.min.js" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Sabela Rooke Newsletter | Tailwind CSS UI Block</title>
<meta name="description" content="A newsletter block extracted from the Sabela Rooke template, available in Tailwind CSS.">
<meta name="keywords" content="Sabela Rooke, Tailwind CSS template, HTML website template, writer website template, author blog template, personal blog, essay blog, newsletter signup, book page, blog template">
<meta name="author" content="Let's templates">
<link rel="canonical" href="">
<meta property="og:type" content="product">
<meta property="og:site_name" content="Let's templates">
<meta property="og:locale" content="en_US">
<meta property="og:url" content="">
<meta property="og:title" content="Sabela Rooke | Tailwind CSS Blog Template">
<meta property="og:description" content="A quiet Tailwind CSS template for writers and personal blogs: each entry has its own pastel page, a stacked date, a huge black title and one red serif word, with an archive, articles, an about page and a monthly letter.">
<meta property="og:image" content="">
<meta property="og:image:alt" content="Sabela Rooke template preview">
<meta name="twitter:card" content="summary_large_image">
<meta name="twitter:url" content="">
<meta name="twitter:title" content="Sabela Rooke | Tailwind CSS Blog Template">
<meta name="twitter:description" content="A quiet Tailwind CSS template for writers and personal blogs: each entry has its own pastel page, a stacked date, a huge black title and one red serif word, with an archive, articles, an about page and a monthly letter.">
<meta name="twitter:image" content="">
<meta name="twitter:image:alt" content="Sabela Rooke template preview">
<script src="https://cdn.tailwindcss.com/3.4.17"></script>
<link rel="preconnect" href="https://fonts.googleapis.com">
<link href="https://fonts.googleapis.com/css2?family=Bricolage+Grotesque:opsz,wght@12..96,800&family=Newsreader:ital,opsz,wght@0,6..72,400;0,6..72,500;1,6..72,400&family=Playfair+Display:ital,wght@0,400;0,500;1,400&display=swap" rel="stylesheet">
<script>
tailwind.config = {
theme: {
extend: {
colors: {
ink: { DEFAULT: '#1b2220', soft: '#414a47' },
paper: '#f6f1e7',
rose: '#d83a56',
sage: '#b9cbb7',
salmon: '#f5b39c',
butter: '#f0dca2',
lilac: '#cec5de'
},
fontFamily: {
heavy: ['"Bricolage Grotesque"', 'sans-serif'],
display: ['"Playfair Display"', 'serif'],
serif: ['Newsreader', 'serif']
}
}
}
}
</script>
<style>
@view-transition { navigation: auto; }
html { scroll-behavior: smooth; }
[hidden] { display: none !important; }
.heavy { font-family: "Bricolage Grotesque", sans-serif; font-weight: 800; letter-spacing: -.045em; line-height: .86; }
.red-word { font-family: "Playfair Display", serif; font-weight: 500; color: #d83a56; line-height: 1; letter-spacing: -.01em; }
.small-caps { font-family: "Playfair Display", serif; font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; }
/* The cover takes the colour of the entry it shows. */
.cover { background: var(--ground, #b9cbb7); transition: background-color .7s ease; }
.slides { display: grid; }
.slides > * { grid-area: 1 / 1; transition: opacity .6s ease, visibility .6s; }
.slides > [aria-hidden="true"] { opacity: 0; visibility: hidden; }
.entry-row { transition: background-color .35s ease; }
.entry-row:hover, .entry-row:focus-within { background: var(--tint); }
.reveal-ready [data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; transition-delay: var(--reveal-delay, 0ms); }
.reveal-ready [data-reveal].is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .cover, .slides > *, .entry-row { transition: none; } }
</style>
</head>
<body class="bg-paper font-serif text-ink antialiased">
<!-- block:start newsletter -->
<section id="letters" class="bg-lilac px-5 py-20 md:px-10 md:py-28">
<div class="grid gap-10 md:grid-cols-2 md:items-end md:gap-20">
<div>
<p class="font-display leading-none">
<span class="block text-6xl font-medium md:text-7xl">01</span>
<span class="mt-2 block pl-7 text-lg italic md:pl-9">of every</span>
<span class="block pl-7 text-lg font-medium md:pl-9">month</span>
</p>
<h2 class="heavy mt-8 text-[clamp(4.5rem,13vw,12rem)]">Letters</h2>
</div>
<div>
<p class="max-w-md text-xl leading-snug">One letter on the first of the month: the new essay, a page from the notebook and one book I pressed on somebody. Nothing else, ever.</p>
<form class="mt-8 max-w-md" data-letter novalidate>
<label for="letter-email" class="small-caps">Your email</label>
<div class="mt-2 flex border-b-2 border-ink">
<input id="letter-email" type="email" required autocomplete="email" placeholder="you@example.com" class="min-w-0 flex-1 bg-transparent py-3 text-xl outline-none placeholder:text-ink/40">
<button type="submit" class="small-caps shrink-0 px-2 hover:text-rose">Send me letters</button>
</div>
<p class="mt-3 text-rose" data-letter-error hidden>That email does not look right.</p>
<p class="mt-3 font-display text-xl italic" data-letter-done hidden role="status">Thank you. The next letter leaves on the first.</p>
</form>
</div>
</div>
</section>
<!-- block:end newsletter -->
<script>
document.querySelectorAll("[data-menu-toggle]").forEach((button) => {
const menu = document.getElementById(button.getAttribute("aria-controls"));
if (!menu) return;
button.addEventListener("click", () => {
const open = button.getAttribute("aria-expanded") === "true";
button.setAttribute("aria-expanded", String(!open));
menu.classList.toggle("hidden", open);
});
});
// Cover: one entry at a time, and the page takes that entry's colour.
document.querySelectorAll("[data-cover]").forEach((root) => {
const slides = [...root.querySelectorAll("[data-slide]")];
if (slides.length < 2) return;
let current = 0;
const show = (index) => {
current = (index + slides.length) % slides.length;
slides.forEach((slide, i) => {
if (i === current) slide.removeAttribute("aria-hidden"); else slide.setAttribute("aria-hidden", "true");
});
root.style.setProperty("--ground", slides[current].dataset.ground);
root.querySelector("[data-cover-count]").textContent = current + 1;
};
root.querySelector("[data-cover-prev]")?.addEventListener("click", () => show(current - 1));
root.querySelector("[data-cover-next]")?.addEventListener("click", () => show(current + 1));
root.addEventListener("keydown", (event) => {
if (event.key === "ArrowLeft") show(current - 1);
if (event.key === "ArrowRight") show(current + 1);
});
});
// Entry filter.
document.querySelectorAll("[data-entries]").forEach((root) => {
const buttons = [...root.querySelectorAll("[data-entries-filter]")];
buttons.forEach((button) => button.addEventListener("click", () => {
const kind = button.dataset.entriesFilter;
buttons.forEach((other) => other.setAttribute("aria-pressed", String(other === button)));
root.querySelectorAll("[data-kind]").forEach((row) => { row.hidden = kind !== "All" && row.dataset.kind !== kind; });
}));
});
// First lines: step through the opening sentence of each entry.
document.querySelectorAll("[data-lines]").forEach((root) => {
const lines = JSON.parse(root.querySelector("[data-lines-data]").textContent);
const text = root.querySelector("[data-lines-text]");
const link = root.querySelector("[data-lines-link]");
let current = 0;
root.querySelector("[data-lines-next]").addEventListener("click", () => {
current = (current + 1) % lines.length;
const line = lines[current];
text.textContent = `“${line.first}”`;
link.textContent = line.title;
link.href = `${line.slug}.html`;
root.style.setProperty("--ground", line.ground);
});
});
// Monthly letter sign-up.
document.querySelectorAll("[data-letter]").forEach((form) => {
form.addEventListener("submit", (event) => {
event.preventDefault();
const input = form.querySelector('input[type="email"]');
const ok = input.value.trim() !== "" && input.checkValidity();
form.querySelector("[data-letter-error]").hidden = ok;
form.querySelector("[data-letter-done]").hidden = !ok;
if (ok) input.value = "";
});
});
(() => {
const items = document.querySelectorAll("[data-reveal]");
const skip = navigator.webdriver || !("IntersectionObserver" in window) || matchMedia("(prefers-reduced-motion: reduce)").matches;
if (!items.length || skip) return;
document.documentElement.classList.add("reveal-ready");
const observer = new IntersectionObserver((entries) => {
entries.forEach((entry) => {
if (!entry.isIntersecting) return;
entry.target.classList.add("is-visible");
observer.unobserve(entry.target);
});
}, { rootMargin: "0px 0px -10% 0px" });
items.forEach((item) => observer.observe(item));
})();
</script>
<p class="lt-built-with" style="margin:0;padding:12px 16px;text-align:center;font:500 11px/1.4 system-ui,-apple-system,sans-serif;color:#9ca3af;">Built with <a href="https://letstemplates.com" style="color:#059669;text-decoration:none;">Let's templates</a></p>
</body>
</html>
Blog
Unlock the entire library of premium templates and blocks. Renews automatically, cancel anytime.