feat(email): convert digest.html to shared partials + brand, loops intact
This commit is contained in:
@@ -584,11 +584,11 @@ The largest template — keeps `{{{ each notifications }}}`, `publicRooms`, `top
|
||||
**Files:**
|
||||
- Modify: `email/digest.html`
|
||||
|
||||
- [ ] **Step 1: Replace the head/header (lines ~1–160) with IMPORT header + preheader**
|
||||
- [x] **Step 1: Replace the head/header (lines ~1–160) with IMPORT header + preheader**
|
||||
|
||||
Prepend `<!-- IMPORT emails/partials/header.html -->` + the two-line preheader block using `[[email:digest.preheader]]`, deleting everything through `<!-- Email Header : END -->`.
|
||||
|
||||
- [ ] **Step 2: Apply the palette/font find/replace across the body and every loop row**
|
||||
- [x] **Step 2: Apply the palette/font find/replace across the body and every loop row**
|
||||
|
||||
Same find/replace as Task 6, applied to all loop iterations. Specifically:
|
||||
- card `bgcolor="#ffffff"` → `#fbf7ef`
|
||||
@@ -601,11 +601,11 @@ Same find/replace as Task 6, applied to all loop iterations. Specifically:
|
||||
|
||||
Leave every `{{{ each }}}`, `{{{ if }}}`, `{var}`, `[[email:digest.*]]`, and `{renderDigestAvatar(@value)}` untouched.
|
||||
|
||||
- [ ] **Step 3: Replace the original footer with IMPORT footer**
|
||||
- [x] **Step 3: Replace the original footer with IMPORT footer**
|
||||
|
||||
Delete the digest's own footer table + trailing `</div></center></body></html>`/MSO close; replace with `<!-- IMPORT emails/partials/footer.html -->`.
|
||||
|
||||
- [ ] **Step 4: Guard passes for all templates**
|
||||
- [x] **Step 4: Guard passes for all templates**
|
||||
|
||||
Run: `node scripts/check-emails.js`
|
||||
Expected: PASS (`Email template check passed (10 templates).`).
|
||||
@@ -614,7 +614,9 @@ Expected: PASS (`Email template check passed (10 templates).`).
|
||||
|
||||
Run: `./nodebb build`. Trigger a digest (ACP → manually run digest, or test account). Confirm loops render, headings are serif/gold-muted, separators visible, button-free.
|
||||
|
||||
- [ ] **Step 6: Commit**
|
||||
Task 9 note: `node scripts/check-emails.js` passed with `Email template check passed (10 templates).` Lightweight marker checks confirmed the digest loops and `{renderDigestAvatar(@value)}` remain present. `./nodebb build` and digest test-send were not run because no executable `./nodebb` / NodeBB root is available in this standalone theme repo.
|
||||
|
||||
- [x] **Step 6: Commit**
|
||||
|
||||
```bash
|
||||
git add email/digest.html
|
||||
|
||||
Reference in New Issue
Block a user