Skip to main content
You are currently viewing the documentation for Filament 4.x, which is a previous version of Filament.Looking for the current stable version? Visit the 5.x documentation.

Introduction

You may group actions together into a dropdown menu by using an ActionGroup object. Groups may contain many actions, or other groups:
This page is about customizing the look of the group’s trigger button and dropdown.

Using the keyboard

Dropdown action groups use menu keyboard navigation. You can open a group with Enter, Space or Arrow Down to focus its first action, or Arrow Up to focus its last action. Arrow Up and Arrow Down move between actions, including disabled actions, which cannot be activated. Escape closes the menu and returns focus to its trigger; Tab closes it and moves to the next focusable control. For nested groups, Arrow Right, Enter or Space opens the submenu. Arrow Left or Escape closes it and returns focus to its parent item.

Customizing the group trigger style

The button which opens the dropdown may be customized in the same way as a normal action. All the methods available for trigger buttons may be used to customize the group trigger button:
When you render multiple groups together, use distinct label() values so users can distinguish their triggers, including when only icons are visible.

Adding a tooltip to the group trigger button

You may add a tooltip to the group trigger button using the tooltip() method:

Using a grouped button design

Instead of a dropdown, an action group can render itself as a group of buttons. This design works with and without button labels. To use this feature, use the buttonGroup() method:

Setting the placement of the dropdown

The dropdown may be positioned relative to the trigger button by using the dropdownPlacement() method:
Alternatively, you may let the dropdown position be automatically determined based on the available space using the dropdownAutoPlacement() method:

Adding dividers between actions

You may add dividers between groups of actions by using nested ActionGroup objects:
The dropdown(false) method puts the actions inside the parent dropdown, instead of a new nested dropdown.

Setting the width of the dropdown

The dropdown may be set to a width by using the dropdownWidth() method. Options correspond to Tailwind’s max-width scale. The options are ExtraSmall, Small, Medium, Large, ExtraLarge, TwoExtraLarge, ThreeExtraLarge, FourExtraLarge, FiveExtraLarge, SixExtraLarge and SevenExtraLarge:

Controlling the dropdown offset

You may control the offset of the dropdown using the dropdownOffset() method, by default the offset is set to 8.

Controlling the maximum height of the dropdown

The dropdown content can have a maximum height using the maxHeight() method, so that it scrolls. You can pass a CSS length: