Panel class is the core configuration class for Filament admin panels. It provides a fluent API for configuring all aspects of your admin panel including authentication, navigation, themes, and more.
Namespace
Inheritance
Extends:Filament\Support\Components\Component
Static Methods
make()
Create a new panel instance.Returns a new Panel instance resolved from the container.
Instance Methods
default()
Mark this panel as the default panel.Whether this panel should be the default. You can pass a closure that returns a boolean.
Returns the panel instance for method chaining.
isDefault()
Check if this panel is marked as the default panel.Returns
true if this is the default panel, false otherwise.register()
Register the panel with the application. This method is called automatically during the service provider registration phase.- Registers Livewire components
- Registers Livewire persistent middleware
- Sets up tenant domain routing patterns
- Registers assets when running in console
boot()
Boot the panel. This method is called automatically during the service provider boot phase.- Sets up tenancy model observers and global scopes
- Registers assets
- Registers colors and icons
- Configures SPA mode
- Registers render hooks
- Configures database transactions for actions
- Boots plugins
- Executes boot callbacks
bootUsing()
Register a callback to be executed when the panel boots.A closure that receives the panel instance as its parameter.
Returns the panel instance for method chaining.
Traits
The Panel class uses numerous traits for additional functionality:CanGenerateResourceUrls- URL generation for resourcesHasAssets- Asset registration and managementHasAuth- Authentication configurationHasAvatars- User avatar configurationHasBrandLogo- Brand logo customizationHasBrandName- Brand name configurationHasBreadcrumbs- Breadcrumb navigationHasBroadcasting- Broadcasting configurationHasColors- Color scheme customizationHasComponents- Component registrationHasDarkMode- Dark mode configurationHasDatabaseTransactions- Database transaction handlingHasErrorNotifications- Error notification configurationHasFavicon- Favicon customizationHasFont- Font configurationHasGlobalSearch- Global search functionalityHasIcons- Icon customizationHasId- Panel identifierHasMaxContentWidth- Content width constraintsHasMiddleware- Middleware configurationHasNavigation- Navigation configurationHasNotifications- Notification configurationHasPlugins- Plugin managementHasRenderHooks- Render hook registrationHasRoutes- Route configurationHasSidebar- Sidebar configurationHasSpaMode- SPA mode configurationHasSubNavigation- Sub-navigation configurationHasTenancy- Multi-tenancy supportHasTheme- Theme customizationHasTopbar- Top bar configurationHasTopNavigation- Top navigation configurationHasUnsavedChangesAlerts- Unsaved changes warningsHasUserMenu- User menu configuration