FilamentF
Filament14mo ago
Ibiza

Hide Navigation on specific pages

I cannot seem to find a functioning method of hiding the navigation bar on specific pages. In this cause I am wanting the user to create a business and if they don't have one created they will be redirected to the business creation page. Which just contains a form and extends Page.
Solution
So I had been trying that and it was throwing a variety of different errors at me. Funny enough I figured it out a few minutes after reading your message.

Easiest solution is going into the pages class and adding this into the mount:

public function mount()
{
        Filament::getCurrentPanel()->navigation(false)
            ->topNavigation(false)
            ->sidebarWidth('0px');
}
Was this page helpful?