nova-settings
nova-settings copied to clipboard
Nova 5 Repeater Image field support
I'm using Laravel 12.0 and Nova 5.0. The Image field via a Nova Repeater doesn't work with the outl1ne/nova-settings package.
I did find a workaround. Please see my fork https://github.com/Inigo-van-Dijk/nova-settings/commit/c397bed416c2ea5ebce73cc2a1f2601309e45457.
To make this work, two things must be added:
- To your Repeater field, add ->asJson()->uniqueField('uuid'), for example
Repeater::make('Clients', 'clients')
->repeatables([
Client::make(),
])
->asJson()
->uniqueField('uuid')
And in your Repeater, in this example Client.php
public function fields(NovaRequest $request): array
{
return [
Hidden::make('uuid'),
Image::make('Image', 'image'),
// Any other fields you want
];
}
Now Images, and any Nova Repeater field works with this package.
Just commenting to say I have run into the same issue and would appreciate a resolution