Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Profile Filament Plugin Laravel Package

rawilk/profile-filament-plugin

Filament plugin that jumpstarts a user profile area with multi-factor authentication, password and session management, migrations, and sensible defaults—opinionated but customizable. Designed to remove boilerplate and integrate cleanly into your panel.

View on GitHub
Deep Wiki
Context7

title: Notifications sort: 2

Introduction

There are a few notifications that get sent out by the package for certain actions, such as when a user changes their email address. Most of them have a $toMailCallback static property that you can set in a service provider to customize the notification's email content.

Customizing notification content

The following notifications sent out by this package can have their email message configured with a callback function:

  • Rawilk\ProfileFilament\Notifications\Emails\NoticeOfEmailChangeRequest - sends to the user's current email address with a block verification url if the plugin and panel have email change verification enabled
  • Rawilk\ProfileFilament\Notifications\Emails\VerifyEmailChange - sends to the email address a user is attempting to change their email address to if the plugin and panel have email change verification enabled

With these notifications, you can change the entire message returned from the notification's toMail method in a service provider:

use Illuminate\Support\ServiceProvider;
use Rawilk\ProfileFilament\Notifications\Emails\VerifyEmailChange;
use Illuminate\Notifications\Messages\MailMessage;

class AppServiceProvider extends ServiceProvider
{
    public function boot(): void
    {
        VerifyEmailChange::$toMailCallback = function ($notifiable, $verificationUrl, $newEmail) {
            return (new MailMessage)
                ->line('Your content here');
        };
    }
}

If you just want to change the verbiage a little bit, you could modify the language lines for each of the notifications instead.

Customizing notifications with a custom class instead

If you'd rather define your own notification class, you can do that as well and just re-bind the notification you're replacing to the container in a service provider.

First, create your custom notification:

namespace App\Notifications;

use Rawilk\ProfileFilament\Notifications\Emails\VerifyEmailChange;

class CustomVerifyEmailChange extends VerifyEmailChange
{
    // ...
}

Now you can re-bind the notification class in the service provider:

use App\Notifications\CustomVerifyEmailChange;
use Rawilk\ProfileFilament\Notifications\Emails\VerifyEmailChange;
use Illuminate\Support\ServiceProvider;

class AppServiceProvider extends ServiceProvider
{
    public function boot(): void
    {
        $this->app->bind(
            VerifyEmailChange::class,
            fn ($app) => $app->make(CustomVerifyEmailChange::class),
        );
    }
}

Other notifications

The following notifications are sent out by the package, but can be configured in other ways:

  • Rawilk\ProfileFilament\Auth\Multifactor\Email\Notifications\VerifyEmailAuthenticationNotification - sends to the user when they need to verify their identity for MFA or sudo with the email authentication provider
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
daikazu/eloquent-salesforce-objects
unseen-codes/chat
romalytar/yammi-jobs-monitoring-laravel
kisame76/filament-db-table-state
nqxcode/laravel-lucene-search
dpfx/laravel-livewire-wizards
workos/workos-php-laravel
sofa/laravel-global-scope
nawasara/auth-primitives
adhocrat-io/arkhe-main
make-dev/orca-harpoon
itsemon245/lamet
baks-dev/dashboard
amoifr/pickle-panther-bundle
make-dev/orca
dmstr/symfony-system-resources-bundle
dmstr/symfony-job-queue-bundle
dmstr/openapi-json-schema-bundle
dmstr/keycloak-security-bundle
dmstr/doctrine-audit-log-bundle