Remove Sidebar

How i can remove sidebar for user if don't have super_admin role?
6 Replies
m_israilov
m_israilov4w ago
For other roles i have just one resource and i think there is no point in putting sidebar
LeandroFerreira
I would keep the authorization as I mentioned and use top navigation to remove the sidebar
$panel
...
->topNavigation(fn () => !auth()->user()->hasRole('super_admin'))
$panel
...
->topNavigation(fn () => !auth()->user()->hasRole('super_admin'))
m_israilov
m_israilov4w ago
Thank you!
LeandroFerreira
Did it work? ahh ok, you marked as solved.. thanks
m_israilov
m_israilov4w ago
Yes bro
Want results from more Discord servers?
Add your server