Initial Commit
This commit is contained in:
@@ -0,0 +1,73 @@
|
||||
# Tasks: enterprise-email-templates
|
||||
|
||||
**Change ID**: enterprise-email-templates
|
||||
**Package**: `@suaveplan/email-templates`
|
||||
**Target path**: `packages/communication/emails/email-templates`
|
||||
|
||||
---
|
||||
|
||||
## 0. Pre-flight (non-negotiable)
|
||||
|
||||
- [x] 0.1 `pwd && git worktree list && git status` clean.
|
||||
- [x] 0.2 Sync to base SHA `cd3e462c436722e86c150dce144efffd91195495`.
|
||||
- [x] 0.3 Read enterprise spec + every upstream source file.
|
||||
|
||||
## 1. Scaffold
|
||||
|
||||
- [x] 1.1 Create `packages/communication/emails/email-templates/` with `src/` + feature subdirs.
|
||||
- [x] 1.2 `package.json` 0.1.0, `type: module`, `sideEffects: false`, exports map per feature.
|
||||
- [x] 1.3 `tsconfig.lib.json` extending `../../../../tsconfig.base.json`.
|
||||
- [x] 1.4 `vite.config.ts` (multi-entry build, externals).
|
||||
- [x] 1.5 `vitest.config.ts` (forks, istanbul, 100% thresholds).
|
||||
- [x] 1.6 `README.md`.
|
||||
|
||||
## 2. Foundation modules
|
||||
|
||||
- [x] 2.1 `src/error-codes/error-codes.{ts,test.ts,md,index.ts}` — six EMAIL_TEMPLATES codes + EmailTemplatesError.
|
||||
- [x] 2.2 `src/telemetry/telemetry.{ts,test.ts,md,index.ts}` — meter + four instruments.
|
||||
- [x] 2.3 `src/vnode/vnode.{ts,test.ts,md,types.ts,index.ts}` — `h()`, `renderVNode`, escape helpers.
|
||||
- [x] 2.4 `src/theme/theme.{ts,test.ts,md,types.ts,index.ts}` — defaultTheme, createTheme, mergeThemes.
|
||||
|
||||
## 3. Renderer + message + builder + registry
|
||||
|
||||
- [x] 3.1 `src/renderer/renderer.{ts,test.ts,md,types.ts,index.ts}` — `renderToHtml`, `wrapInDocument`, `resolveSubject`, `escapeHtml`, `stripHtml`.
|
||||
- [x] 3.2 `src/message/message.{ts,test.ts,md,types.ts,index.ts}` — `createEmailMessage`.
|
||||
- [x] 3.3 `src/template-builder/template-builder.{ts,test.ts,md,types.ts,index.ts}` — TemplateBuilder + createTemplateBuilder.
|
||||
- [x] 3.4 `src/template-registry/template-registry.{ts,test.ts,md,types.ts,index.ts}` — TemplateRegistry + createRegistry + search.
|
||||
|
||||
## 4. Components (nine)
|
||||
|
||||
- [x] 4.1 EmailLayout
|
||||
- [x] 4.2 EmailContainer
|
||||
- [x] 4.3 EmailHeading
|
||||
- [x] 4.4 EmailText
|
||||
- [x] 4.5 EmailLink
|
||||
- [x] 4.6 EmailImage
|
||||
- [x] 4.7 EmailDivider
|
||||
- [x] 4.8 EmailButton
|
||||
- [x] 4.9 EmailFooter (clock-injectable)
|
||||
|
||||
## 5. Templates (five)
|
||||
|
||||
- [x] 5.1 Welcome
|
||||
- [x] 5.2 Verification
|
||||
- [x] 5.3 PasswordReset
|
||||
- [x] 5.4 Notification
|
||||
- [x] 5.5 Invoice
|
||||
|
||||
## 6. Index barrel
|
||||
|
||||
- [x] 6.1 `src/index.ts` — named re-exports for full surface (no `export *`).
|
||||
|
||||
## 7. Gate
|
||||
|
||||
- [x] 7.1 `bunx turbo lint typecheck test build --filter=@suaveplan/email-templates` green.
|
||||
- [x] 7.2 `bunx turbo test:coverage --filter=@suaveplan/email-templates` ≥ 100/100/100/100.
|
||||
- [x] 7.3 `bun scripts/folder-reorg/generate-manifest.ts` refresh MANIFEST.
|
||||
- [x] 7.4 STATUS.md flip `–` → `✅` + counter.
|
||||
|
||||
## 8. OpenSpec finalisation
|
||||
|
||||
- [x] 8.1 Fold spec delta into `openspec/specs/email-templates/spec.md`.
|
||||
- [x] 8.2 Move folder to `openspec/archive/2026-05-25-enterprise-email-templates/`.
|
||||
- [x] 8.3 Conventional-commit on `feat/migrate-email-templates`.
|
||||
Reference in New Issue
Block a user