@@ -180,7 +180,7 @@ Creating Preview Classes
180180------------------------
181181
182182In order to preview emails before sending them, you need to create a preview
183- class that defines the receipient and required template variables for your
183+ class that defines the recipient and required template variables for your
184184mailer methods::
185185
186186 // in src/Mailer/Preview/WelcomePreview.php
@@ -190,10 +190,10 @@ mailer methods::
190190
191191 class WelcomePreview extends MailPreview
192192 {
193- public function welcome()
193+ public function welcome(): \Cake\Mailer\Mailer
194194 {
195195 $mailer = $this->getMailer('Welcome');
196- // set any template variables receipients for the mailer.
196+ // set any template variables and recipients for the mailer.
197197
198198 return $mailer;
199199 }
@@ -246,9 +246,9 @@ Panel Elements
246246
247247Each Panel is expected to have a view element that renders the content from the
248248panel. The element name must be the underscored inflection of the class name.
249- For example ``SessionPanel `` has an element named **session_panel.ctp **, and
250- SqllogPanel has an element named **sqllog_panel.ctp **. These elements should be
251- located in the root of your **src/Template/Element ** directory.
249+ For example ``SessionPanel `` has an element named **session_panel.php **, and
250+ SqllogPanel has an element named **sqllog_panel.php **. These elements should be
251+ located in the root of your **templates/element ** directory.
252252
253253Custom Titles and Elements
254254--------------------------
@@ -278,7 +278,7 @@ behaves and appears:
278278Panels in Other Plugins
279279-----------------------
280280
281- Panels provided by `plugins <https://book.cakephp.org/3.0 /en/plugins.html >`_ work
281+ Panels provided by `plugins <https://book.cakephp.org/5 /en/plugins.html >`_ work
282282almost entirely the same as other plugins, with one minor difference: You must
283283set ``public $plugin `` to be the name of the plugin directory, so that the
284284panel's Elements can be located at render time::
@@ -289,7 +289,7 @@ panel's Elements can be located at render time::
289289
290290 class MyCustomPanel extends DebugPanel
291291 {
292- public $plugin = 'MyPlugin';
292+ public string $plugin = 'MyPlugin';
293293 ...
294294 }
295295
0 commit comments