Convenient Font Awesome icons selection field for MoonShine
composer require bugo/moonshine-fontawesome-field
You can use Icon
field in your resources:
<?php
declare(strict_types=1);
namespace App\MoonShine\Resources;
use Bugo\MoonShine\FontAwesome\Fields\Icon;
use MoonShine\Resources\ModelResource;
/**
* @extends ModelResource<Custom>
*/
class CustomResource extends ModelResource
{
public function fields(): array
{
return [
Icon::make('Icon')
->searchable(),
];
}
}
All use cases of Blade Font Awesome are also available for you.
When using icons in Blade templates, be sure to enable Caching.
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Please make sure to update tests as appropriate.