How to: Action group dropdown grid layout

I would like to have a grid layout in action group dropdown in table action group. I have large number of actions in a table row. How to do that.
No description
4 Replies
Dhru
Dhru2d ago
the easiest way would be to use a nested dropdown but it wouldn't give you that exact layout. https://filamentphp.com/docs/3.x/actions/grouping-actions not sure if extraattributes works with actiongruops but that would the next step I would try (see if i can achive that with a tailwind class) if not possible with either of those two can extend the actiongroup class and create your own blade view with the layout you want and use an instance of that extenededclass in your project
Pritbor
PritborOP2d ago
Hi @Dhru , what you see is basically grouped actions already. Instead of stacked layout grid is flexible if possible. though from browser inspection i know i can achieve this by simply overriding the CSS in global filament theme file but i wanted. Screenshot shared actually is same overidden version but in browser inspection. I tried extaAttributes but it dint work.
Dhru
Dhru2d ago
Ah okay just publish the theme and override the relevant .css A “theme” in filament is just the .css file Since all you are doing is updating the css will not break anything with updates (beyond maybe the styling) https://filamentphp.com/docs/3.x/panels/themes#creating-a-custom-theme
Pritbor
PritborOP8h ago
Hi @Dhru thanks I am aware using theme way. I was looking if anything possible within Filament field specifiacally in an action group or if any render hook which is dint find. Any way thanks for this. I wanted use theme customisation as last option because that's not dynamic and i wanted a way if in the action i want in some 2 grid and in some 3 grid. Or if it allows to create separate view file like it does for field views or custom fields or table layouts.

Did you find this page helpful?