add legal page generator for privacy, delivery, and terms
All checks were successful
deploy / deploy (push) Successful in 1m23s

Replaces hardcoded PreviewData placeholders with generated content
derived from real shop state: connected providers (production lead
times), shipping countries (grouped by region), shop country
(jurisdiction language and governing law), and feature flags
(abandoned cart recovery section, newsletter, VAT clause).

Returns policy correctly cites Consumer Contracts Regulations Reg
28(1)(b) for POD exemption and Consumer Rights Act for defective goods.
Cart recovery section uses jurisdiction-specific wording: PECR Reg 22
for UK, GDPR Art 6(1)(f) for EU, generic otherwise.

About page unchanged — shop owner's story to tell.

26 new tests.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
jamey
2026-02-24 13:48:49 +00:00
parent fd355c3397
commit 933f685b63
5 changed files with 665 additions and 13 deletions

View File

@@ -130,12 +130,12 @@ Plans: [admin-redesign.md](docs/plans/admin-redesign.md) | [admin-font-loading.m
| | **Other features** | | | |
| ~~72~~ | ~~Order status lookup — wire up existing stub on contact page (UI already exists, backend unbuilt)~~ | — | 1.5h | done |
| | **Abandoned cart recovery** ([plan](docs/plans/abandoned-cart.md)) | | | |
| 75 | Handle `checkout.session.expired` webhook, store abandoned cart record | — | 1h | planned |
| 76 | Send single recovery email (plain text, no tracking, clear opt-out) | 75 | 1h | planned |
| 77 | Suppression list (unsubscribe), 30-day data pruning Oban job, Stripe footer notice | 76 | 1h | planned |
| ~~75~~ | ~~Handle `checkout.session.expired` webhook, store abandoned cart record~~ | — | 1h | done |
| ~~76~~ | ~~Send single recovery email (plain text, no tracking, clear opt-out)~~ | 75 | 1h | done |
| ~~77~~ | ~~Suppression list (unsubscribe), 30-day data pruning Oban job, Stripe footer notice~~ | 76 | 1h | done |
| | **Legal page generator** ([plan](docs/plans/legal-page-generator.md)) | | | |
| 83 | `LegalPages` module — generate accurate privacy, delivery, and terms content from settings + provider + shipping data | — | 2.5h | planned |
| 84 | Wire `LegalPages` into `Content` LiveView — replace `PreviewData` calls, add tests | 83 | 45m | planned |
| ~~83~~ | ~~`LegalPages` module — generate accurate privacy, delivery, and terms content from settings + provider + shipping data~~ | — | 2.5h | done |
| ~~84~~ | ~~Wire `LegalPages` into `Content` LiveView — replace `PreviewData` calls, add tests~~ | 83 | 45m | done |
| 85 | Page editor integration — "Regenerate" button, auto-regenerate on settings change, customised vs auto label | 83, 19 | 1.5h | planned |
| | **Platform site** | | | |
| 73 | Platform/marketing site — brochure, pricing, sign-up | — | TBD | planned |