3 namespace BookStack\Activity\Notifications\Messages;
5 use BookStack\Activity\Notifications\MessageParts\ListMessageLine;
6 use BookStack\Entities\Models\Page;
7 use Illuminate\Notifications\Messages\MailMessage;
9 class PageUpdateNotification extends BaseActivityNotification
11 public function toMail(mixed $notifiable): MailMessage
13 /** @var Page $page */
14 $page = $this->detail;
16 return (new MailMessage())
17 ->subject(trans('notifications.updated_page_subject', ['pageName' => $page->getShortName()]))
18 ->line(trans('notifications.updated_page_intro', ['appName' => setting('app-name')]))
19 ->line(new ListMessageLine([
20 trans('notifications.detail_page_name') => $page->name,
21 trans('notifications.detail_updated_by') => $this->user->name,
23 ->line(trans('notifications.updated_page_debounce'))
24 ->action(trans('notifications.action_view_page'), $page->getUrl())
25 ->line($this->buildReasonFooterLine());