feat(cabana): mail preview and test send to yourself

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-11-13 13:02:49 +01:00
parent 4fd2ed07eb
commit 0c73c8d4f1
22 changed files with 1233 additions and 16 deletions

View File

@@ -186,6 +186,8 @@ On a customized template, file layout or partial, **Reset to file version** retu
When a plugin update changes a file you customized, your version is still sent, but the list marks the row Customized and File changed, the status filter's File changed choice finds it, and the form shows a notice. The File version tab shows the lines your version changed against the current file (lines starting with + are only in your version, lines starting with − only in the file) and the file itself. Saving your version again marks the change as reviewed; resetting takes the new file.
Each mail form has a live preview (`POST /mail/preview`) that renders the unsaved draft through `postcard.Editor` with the template's sample values (or sample content for layouts, partials and branding). **Send test to me** (`POST /mail/test-send`) delivers that draft only to the signed-in administrator's own email: the body never carries a recipient, personal API tokens are refused, and each administrator may send at most five tests per ten minutes (429 with `Retry-After` when the limit is hit).
## Drivers
`mail.driver` selects the driver: