A reusable, extensible Filament Settings plugin with tabbed UI, Spatie Settings persistence, Artisan generators, automatic discovery, and optional Shield integration.
islamv/filament-settings-plugin is a Laravel package for a reusable, extensible filament settings plugin with tabbed ui, spatie settings persistence, artisan generators, automatic discovery, and optional shield integration..
It currently has 0 GitHub stars and 4 downloads on Packagist (latest version 1.0.5).
Install it with composer require islamv/filament-settings-plugin.
Discover more Laravel packages by islamv
or browse all Laravel packages to compare alternatives.
Last updated
A production-ready, highly architecture-focused reusable Filament Settings plugin powered by spatie/laravel-settings. Built specifically for modern Filament v5 and Laravel applications.
spatie/laravel-settings with type-safe setting classes and database migrations.bezhansalleh/filament-shield without hardcoding dependencies.php artisan make:settings-tab, make:settings-sub-tab, and make:settings-page.app/Filament/Settings/Tabs directory.You can install the package via composer (spatie/laravel-settings will be automatically installed as a dependency):
composer require islamv/filament-settings-plugin
Publish and run the Spatie Settings & Plugin migrations:
php artisan vendor:publish --provider="Spatie\LaravelSettings\LaravelSettingsServiceProvider"
php artisan vendor:publish --provider="Islamv\FilamentSettingsPlugin\FilamentSettingsServiceProvider"
php artisan migrate
Register FilamentSettingsPlugin in your Filament Panel Provider (e.g. AdminPanelProvider.php):
use Islamv\FilamentSettingsPlugin\FilamentSettingsPlugin;
public function panel(Panel $panel): Panel
{
return $panel
// ...
->plugins([
FilamentSettingsPlugin::make(),
]);
}
The plugin configuration file config/filament-settings.php allows you to customize navigation, locales, file upload disk, and discovery behavior:
return [
'navigation' => [
'label' => 'Settings',
'icon' => 'heroicon-o-cog-6-tooth',
'group' => null,
'sort' => 100,
],
'locales' => [
'en' => ['label' => 'English', 'direction' => 'ltr'],
'ar' => ['label' => 'Arabic', 'direction' => 'rtl'],
],
'uploads' => [
'disk' => env('FILAMENT_SETTINGS_DISK', 'public'),
'directory' => env('FILAMENT_SETTINGS_DIRECTORY', 'settings'),
],
'discovery' => [
'enabled' => true,
'path' => null, // defaults to app/Filament/Settings/Tabs
'namespace' => null, // defaults to App\Filament\Settings\Tabs
],
];
In your PanelProvider:
FilamentSettingsPlugin::make()
->useShield(true) // Enable Filament Shield permission checks
->withoutDefaultTabs() // Disable built-in General, Social, Static Pages tabs
->removeTab('social-links') // Remove a specific tab
->locales([
'en' => ['label' => 'English', 'direction' => 'ltr'],
'ar' => ['label' => 'Arabic', 'direction' => 'rtl'],
'fr' => ['label' => 'French', 'direction' => 'ltr'],
])
->tab(PaymentSettingsTab::make()) // Register custom tab manually
->subTab('static-pages', ContactUsSubTab::make()); // Register sub-tab under existing tab
Creates a main Settings Tab along with a Spatie Settings class and database migration.
php artisan make:settings-tab Payment --sort=40 --icon=heroicon-o-credit-card
Creates a sub-tab nested under a parent tab.
php artisan make:settings-sub-tab Stripe --parent=payment --sort=10
Creates a translatable static page sub-tab under the built-in static-pages main tab.
php artisan make:settings-page RefundPolicy --sort=40
When automatic discovery is enabled, tabs are automatically loaded based on folder structure:
app/Filament/Settings/Tabs/
├── PaymentSettingsTab.php <-- Main Tab
└── Payment/
├── StripeSettingsSubTab.php <-- Sub-Tab under 'payment'
└── PaypalSettingsSubTab.php <-- Sub-Tab under 'payment'
When Shield integration is enabled (->useShield(true)), permission keys follow this convention:
page_settingspage_settings_{tab_key} (e.g. page_settings_general, page_settings_payment)page_settings_{parent_key}_{subtab_key} (e.g. page_settings_static_pages_privacy_policy)External packages can register settings tabs in their ServiceProvider boot() method:
use Islamv\FilamentSettingsPlugin\Registry\SettingsRegistry;
public function boot(): void
{
$registry = app(SettingsRegistry::class);
$registry->register(MyPackageSettingsTab::make());
}
The MIT License (MIT). Please see License File for more information.