Menu presets and options
Publish the config:
php artisan vendor:publish --tag=filament-relation-navigator-config'menu' => [
'preset' => 'github', // 'simple', a preset of yours, or a view name
'presets' => [
'simple' => 'filament-relation-navigator::menu.simple',
'github' => 'filament-relation-navigator::menu.github',
],
'searchable' => true, // a search field on top of the list, whatever the preset
'search_from' => 0, // ...from this many items
'badges' => true, // the relation managers' badges; 'lazy' loads them when the menu opens
'max_height' => '24rem',
'separator' => true, // record pages and relation pages in two blocks
'mobile' => true, // the menu above the heading on small screens
'shortcut' => 'alt+shift+r', // opens the menu; null turns it off
],github (the default): the last breadcrumb stays text and a caret next to it opens a panel with a heading, a search field and a check on the current page, like GitHub's repository switcher. The field gets the focus when the menu opens and Enter opens the first match.
simple: the last breadcrumb itself opens the list. For the menu of 1.2 and earlier, set 'preset' => 'simple' and 'searchable' => false.

Deferred badges
Badges run the same queries as the tab badges. With 'badges' => 'lazy' the page renders without them, and the menu loads them in one request when it opens.
A relation manager whose tab badge is lazy in Filament (protected static ?bool $isBadgeLazyLoaded = true;, or $isBadgeDeferred on Filament 4.13) gets the same treatment in the menu, whatever the config: its badge is loaded when the menu opens, the others with the page.
If you published the package views, update menu/partials/list.blade.php before relying on either.
Keyboard: from the search field, Down moves into the list; Up and Down move between the pages, Enter opens one, Escape closes the menu.
Shortcut and tooltip

The button that opens the menu has a tooltip with the shortcut, shown with Mac or Windows/Linux keys. The shortcut opens the menu from anywhere on the page, with the search field ready, like GitHub's repository switcher: ⌥ ⇧ R on a Mac, Alt Shift R elsewhere. Change it in the config or per page:
'shortcut' => 'mod+shift+p', // mod is ⌘ on a Mac and Ctrl elsewherepublic function getRelationNavigatorShortcut(): ?string
{
return null; // no shortcut on this page
}It is built not to get in the way:
- it matches the physical key, so it works with any keyboard layout and with Option on a Mac (where ⌥⇧R types ‰);
- it does nothing while you type in a field;
- a shortcut of the panel's global search (
globalSearchKeyBindings()) is never taken: the menu then has no shortcut; - only the visible menu opens (breadcrumbs or small screens).
Supported keys: alt, shift, ctrl, meta, mod plus a letter, a digit or / . , ;.

Page, resource or config
Every option has three levels. The page wins, then the resource, then the config:
| Page method (static on the resource) | Config key |
|---|---|
getRelationNavigatorPreset(): string | menu.preset |
isRelationNavigatorSearchable(): bool | menu.searchable |
hasRelationNavigatorBadges(): bool | menu.badges |
hasDeferredRelationNavigatorBadges(): bool | menu.badges = 'lazy' |
getRelationNavigatorShortcut(): ?string | menu.shortcut |
hasRelationNavigatorMobileMenu(): bool | menu.mobile |
hasRelationNavigatorRecordNavigation(): bool | record_navigation |
shouldRelationNavigatorRecordNavigationFollowList(): bool | record_navigation_follows_list |
shouldRedirectRelationNavigatorTabs(): bool | redirect_relation_tabs |
// On one page
public function isRelationNavigatorSearchable(): bool
{
return false;
}// On a resource: the same method, static, for all its pages
public static function hasRelationNavigatorRecordNavigation(): bool
{
return true;
}Small screens
Filament hides the breadcrumbs below 40rem. There the menu shows above the page heading instead, on every page that uses HasRelationNavigator, with the same preset options. Turn it off with 'mobile' => false, or per page:
public function hasRelationNavigatorMobileMenu(): bool
{
return false;
}
Translations
English, Italian, Spanish, German, French, Brazilian Portuguese and Dutch. Publish the translations to change them or add a language:
php artisan vendor:publish --tag=filament-relation-navigator-translationsA preset of your own
Start from one of the package presets:
php artisan make:filament-relation-navigator-preset compact --from=githubIt copies the preset to resources/views/filament/relation-navigator/compact.blade.php. Register it and change it as you like:
'preset' => 'compact',
'presets' => [
// ...
'compact' => 'filament.relation-navigator.compact',
],Any view name works as preset too. To change the package presets themselves, publish their views:
php artisan vendor:publish --tag=filament-relation-navigator-viewsA preset view receives:
| Variable | Content |
|---|---|
$label | The last breadcrumb |
$items | The menu items: key, label, url, icon, badge, badgeColor, isActive |
$heading | "Switch page", translated |
$isSearchable | Whether to show the search field |
$hasSeparator | Whether to split record pages and relation pages in two blocks |
$shortcut | The shortcut, or null |
$shortcutKeys | The shortcut keys to show: ['mac' => [...], 'other' => [...]] |
$searchPlaceholder | "Find a page…", translated |
$emptyLabel | "No pages found.", translated |
$maxHeight | menu.max_height |
To give your button the tooltip and the shortcut, include filament-relation-navigator::menu.partials.trigger-attributes inside its tag. Each item also has isRelationPage(). To reuse the search field, the list (with the separator and the keyboard navigation) and the "no results" line, include filament-relation-navigator::menu.partials.list with showCheck.