laravel-form-components
laravel-form-components copied to clipboard
Livewire Reset Form - Custom Select
Laravel Form Components Version
V8.1.4
Laravel Version
v10.21.0
Alpine Version
v3.13.0
Bug description
Hi,
I have a Livewire component which renders a view through a "Modal" where a "Custom Select" is located, this works correctly, but when I send the form, I execute the Livewire "Reset" method, which correctly cleans the form except the "Custom Select", this does not clean the select when the value is empy.
Component Livewire:
public string $name = "";
// ...
public function addNewElement() : void {
$this->reset('name');
// $this->show_modal = false;
}
View:
<x-form-group :label="__('Name')" name="name">
<x-custom-select name="name" wire:model="name" optional
:options="$elements" :placeholder="__('Select a element')" required/>
</x-form-group>
Steps to reproduce
No response
Relevant log output
No response
This issue is stale because it has been open 21 days with no activity. Remove stale label or comment or this will be closed in 7 days.