actions modal already showing backdrop

Hi I have just been using FilamentPHP's table, form and actions without the admin panel. When I create an action and add <x-filament-actions::modals /> to my blade to render the modals, the page goes dark as if the modal has been triggered with a backdrop. This goes away when I remove the '<x-filament-actions::modals />' but the button do not perform any action although the event are being sent.
7 Replies
beks_sudo72
beks_sudo72OP11mo ago
Hi can anyone help me with this? Happy holidays
awcodes
awcodes11mo ago
Where are you adding the blade component?
beks_sudo72
beks_sudo72OP11mo ago
Right at the end of the component's view file making sure i have the one root element. Component blade <div> <div> {{ $this->deleteAction }} </div> <x-filament-actions::modals /> </div> Component delete method php public function deleteAction(): Action { return Action::make('delete') ->requiresConfirmation() ->action(fn () => dump('action delete')); } php Thank you for the help
LeandroFerreira
LeandroFerreira11mo ago
You don't need to add <x-filament-actions::modals />, you should use a deleteAction in the actions([]) table
return $table
->actions([
DeleteAction::make()
])
return $table
->actions([
DeleteAction::make()
])
https://filamentphp.com/docs/3.x/tables/actions#prebuilt-table-actions
beks_sudo72
beks_sudo72OP11mo ago
Thank for the quick response, unfortunately I am only trying to use the Actions module for the filament so i am following this from the documentation https://filamentphp.com/docs/3.x/actions/adding-an-action-to-a-livewire-component. The button renders okay and from the network, an event is fired off, everytime you click, however the when I add
<x-filament-actions::modals />
<x-filament-actions::modals />
I get the backdrop making it imposible to click anything on the page. Thanks again
awcodes
awcodes11mo ago
Any console errors.?
beks_sudo72
beks_sudo72OP11mo ago
No it's actually clean - I will install a fresh app and move things over in bits, see if i can find the cause
Want results from more Discord servers?
Add your server