|
49 | 49 | // When true, subscribed users will also receive the same event as mentions |
50 | 50 | // (UserWasMentionedEvent). When false, a distinct |
51 | 51 | // UserIsSubscribedToCommentableEvent will be dispatched instead. |
52 | | - 'dispatch_as_mention' => false, |
| 52 | + 'dispatch_as_mention' => env('COMMENTIONS_SUBSCRIPTIONS_DISPATCH_AS_MENTION', false), |
53 | 53 | // Controls whether the subscribers list is shown in the sidebar UI |
54 | | - 'show_subscribers' => true, |
| 54 | + 'show_subscribers' => env('COMMENTIONS_SUBSCRIPTIONS_SHOW_SUBSCRIBERS', true), |
55 | 55 | // Automatically subscribe the author when they add a comment |
56 | | - 'auto_subscribe_on_comment' => true, |
| 56 | + 'auto_subscribe_on_comment' => env('COMMENTIONS_SUBSCRIPTIONS_AUTO_SUBSCRIBE_ON_COMMENT', true), |
57 | 57 | // Automatically subscribe a user when they are mentioned in a comment |
58 | | - 'auto_subscribe_on_mention' => true, |
| 58 | + 'auto_subscribe_on_mention' => env('COMMENTIONS_SUBSCRIPTIONS_AUTO_SUBSCRIBE_ON_MENTION', true), |
| 59 | + ], |
| 60 | + |
| 61 | + /* |
| 62 | + |-------------------------------------------------------------------------- |
| 63 | + | Notifications (opt-in) |
| 64 | + |-------------------------------------------------------------------------- |
| 65 | + | |
| 66 | + | Configure notification delivery when a user is mentioned in a comment. |
| 67 | + | Disabled by default; enable and choose the channels you want to use. |
| 68 | + | |
| 69 | + */ |
| 70 | + 'notifications' => [ |
| 71 | + 'mentions' => [ |
| 72 | + 'enabled' => env('COMMENTIONS_NOTIFICATIONS_MENTIONS_ENABLED', false), |
| 73 | + |
| 74 | + 'channels' => explode(',', env('COMMENTIONS_NOTIFICATIONS_MENTIONS_CHANNELS', 'mail')), |
| 75 | + |
| 76 | + 'listener' => \Kirschbaum\Commentions\Listeners\SendUserMentionedNotification::class, |
| 77 | + 'notification' => \Kirschbaum\Commentions\Notifications\UserMentionedInComment::class, |
| 78 | + |
| 79 | + 'mail' => [ |
| 80 | + 'subject' => env('COMMENTIONS_NOTIFICATIONS_MENTIONS_MAIL_SUBJECT', 'You were mentioned in a comment'), |
| 81 | + ], |
| 82 | + ], |
59 | 83 | ], |
60 | 84 | ]; |
0 commit comments