Using Custom Layout blade for each panel provider
I want to be able to use a custom app.blade.php layout for different panel types. Customers get a more website-styled one and admin panels get a more admin-style panel.
I would expect to be able to do something like
return $panel->layout('layouts.customer')
in the panel provider.
Is there a way of doing this?4 Replies
Maybe a theme for each panel?
https://filamentphp.com/docs/3.x/panels/themes/#creating-a-custom-theme
If you want to inject something in the layout, you could use render hooks
https://filamentphp.com/docs/3.x/support/render-hooks/
Thanks. Yeah the BODY_START and BODY_END hooks are good for including the header and footer. I just need the panel to not show its own header if I'm using that.
I'm wondering if I could use a render hook to inject display:none styles for the topbar And sidebar-header?
Solution
you mean this?
Fantastic! Amazing!
Thank you