-
-
Notifications
You must be signed in to change notification settings - Fork 152
Description
I’m seeing a problem when trying to use a "Livewire 4 Multi-File Component (MFC)" as a modal target with wire-elements/modal.
When I dispatch openModal with the component alias (for example front.home.modal), the package throws:
TypeError: LivewireUI\Modal\Modal::resolveComponentClass(): Return value must be of type string, null returned
From debugging, it looks like the modal package tries to resolve the component alias to a PHP class via resolveComponentClass(), but for a Livewire 4 MFC (view-based/anonymous component), the resolver returns null, which causes the TypeError.
My MFC component is created using the Livewire 4 MFC structure (folder-based component with modal.php + modal.blade.php), and the alias is dispatched correctly. This works like a normal Livewire component setup, but fails specifically when used through wire-elements/modal.