Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
"require": {
"php": "^8.3",
"bezhansalleh/filament-language-switch": "^3.1",
"bezhansalleh/filament-panel-switch": "^1.1",
"bezhansalleh/filament-shield": "^3.3",
"datalinx/php-utils": "^2.5",
"dutchcodingcompany/filament-developer-logins": "^1.6",
Expand Down
16 changes: 16 additions & 0 deletions src/Providers/AdminPanelProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
use BezhanSalleh\FilamentShield\Facades\FilamentShield;
use BezhanSalleh\FilamentShield\FilamentShieldPlugin;
use BezhanSalleh\FilamentShield\Middleware\SyncShieldTenant;
use BezhanSalleh\PanelSwitch\PanelSwitch;
use DutchCodingCompany\FilamentDeveloperLogins\FilamentDeveloperLoginsPlugin;
use Eclipse\Common\Providers\GlobalSearchProvider;
use Eclipse\Core\Filament\Pages\Dashboard;
Expand Down Expand Up @@ -229,5 +230,20 @@ public function boot(): void

// Load customized translations for Filament Shield
$this->loadTranslationsFrom(__DIR__.'/../../resources/lang/vendor/filament-shield', 'filament-shield');

// Configure Panel Switch
PanelSwitch::configureUsing(function (PanelSwitch $panelSwitch) {
$panelSwitch
->simple()
->icons([
'admin' => 'heroicon-s-cog-6-tooth',
'frontend' => 'heroicon-s-globe-alt',
])
->labels([
'admin' => 'Admin Panel',
'frontend' => 'Frontend',
])
->visible(fn (): bool => auth()->check());
});
}
}