wexample / symfony-mail-ds
Design-system screens for symfony-mail: the development mailbox
Package info
github.com/wexample/symfony-mail-ds
Language:Twig
pkg:composer/wexample/symfony-mail-ds
Requires
- php: >=8.5
- symfony/security-http: ^7.4 || ^8.0
- symfony/uid: ^7.4 || ^8.0
- wexample/symfony-design-system: >=39.0.3
- wexample/symfony-helpers: >=18.0.2
- wexample/symfony-loader: >=25.0.1
- wexample/symfony-mail: >=3.0.4
Requires (Dev)
None
Suggests
None
Provides
None
Conflicts
None
Replaces
None
README
Version: 2.2.3
Design-system screens for symfony-mail: the development mailbox
Table of Contents
Installation
// config/bundles.php Wexample\SymfonyMailDs\WexampleSymfonyMailDsBundle::class => ['all' => true],
With MAILER_DSN=mailbox://default (see symfony-mail), the page /mailbox/ lists the mails the application sent, newest first. It is routed in dev and test only, and asks for no role: a sign-in link or code is read there before signing in. An application that guards every path opens this one in its access_control:
when@dev: security: access_control: - { path: ^/([a-z]{2}(_[A-Z]{2})?/)?mailbox/, roles: PUBLIC_ACCESS }
A mail's HTML is served by its own route under a Content-Security-Policy: sandbox header and shown in an iframe: it neither wears the application's styles nor runs in its origin.
In a menu: menu_item_collapsible_from_controller(render_pass, 'Wexample\\SymfonyMailDs\\Controller\\Pages'). Outside dev and test, the route does not exist and the entry is not drawn.