lemonlabs / nova-selectable-key-value
Laravel Nova KeyValue field with definable selectable keys.
Installs: 511
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 0
Forks: 1
pkg:composer/lemonlabs/nova-selectable-key-value
Requires
- php: ^8.1
- illuminate/support: ^10.0|^11.0|^12.0
Requires (Dev)
- laravel/nova: ^5.0
- laravel/nova-devtool: ^1.7
README
A Laravel Nova custom field for key-value pairs where the key is a dropdown (select) with options set via ->keyOptions().
Usage
use LemonLabs\SelectableKeyValue\SelectableKeyValue; SelectableKeyValue::make('Settings') ->keyOptions([ 'option1' => 'Option 1', 'option2' => 'Option 2', ])
Installation
- Install the package in your Nova project:
composer require lemonlabs/nova-selectable-key-value
- Use the field in your Nova resource as shown above.