Layout Types
AppLayout
AppLayout extends CoreAppLayout and is the full application shell with a sidebar, settings navigation, and secondary footer links. Override navigation() to define the sidebar structure.
app/Layouts/AppLayout.php
PortalLayout
PortalLayout extends CorePortalLayout, a simplified layout for customer-facing portal pages. It only supports navMain().
app/Layouts/PortalLayout.php
GuestLayout
Used for unauthenticated pages (login, password reset, etc.). It has no navigation and requires no configuration — useCoreGuestLayout directly without extending it.
Registration
Register your layout classes inconfig/core.php:
config/core.php
AppPage uses core.layouts.app, PortalPage uses core.layouts.portal, and GuestPage uses core.layouts.guest.
Overriding the Layout Per Page
To use a different layout on a specific page, call->layout() on the page object:
Navigation Areas
Define navigation insidenavigation() using the methods below. For the full NavigationItem, NavigationSection, and NavigationSecondaryItem API — icons, badges, conditional visibility, sub-items — see Navigation.
navMain()
Populates the primary sidebar. AcceptsNavigationItem and NavigationSection objects.
navSettings()
Injects items into the built-in Settings accordion at the bottom of the main navigation. Core automatically adds system items (users, workflows, developer) alongside yours.navSecondary()
Adds external links to the sidebar footer.setInlyLinks()
Adds links to the Inly customer portal in the sidebar footer. Links are gated behindCorePermission::VIEW_INLY_USER_GUIDE and CorePermission::VIEW_INLY_PROJECT_OVERVIEW.
setInlyLinks() and navSecondary() are only available on CoreAppLayout. CorePortalLayout only supports navMain().Active State Matching
Navigation items use group-based active matching. An item is highlighted when the current route name starts with the same prefix as the item’s route.customers.indexis active oncustomers.index,customers.show,customers.create, etc.- Parent items are highlighted when any child route is active.
- When a sub-item is active, only the sub-item is highlighted — not the parent.
| Current route | Highlighted item |
|---|---|
customers.show | ”Customers” |
customers.show.invoices | ”Invoices” sub-item only |