tomatophp / filament-icons
Picker & Table Column & Icons Provider for FilamentPHP
Fund package maintenance!
fadymondy
Installs: 62 999
Dependents: 14
Suggesters: 0
Security: 0
Stars: 27
Watchers: 2
Forks: 4
Open Issues: 1
Requires
- php: ^8.2|^8.3|^8.4
- filament/filament: ^4.0.0
- tomatophp/console-helpers: ^1.1
Requires (Dev)
- larastan/larastan: ^2.9||^3.0
- laravel/pint: ^1.14
- nunomaduro/collision: ^8.1.1||^7.10.0
- orchestra/testbench: ^10.0.0||^9.0.0
- pestphp/pest: ^3.0
- pestphp/pest-plugin-arch: ^3.0
- pestphp/pest-plugin-laravel: ^3.0
- pestphp/pest-plugin-livewire: ^3.0
- pestphp/pest-plugin-type-coverage: ^3.5
- phpstan/extension-installer: ^1.3||^2.0
- phpstan/phpstan-deprecation-rules: ^1.1||^2.0
- phpstan/phpstan-phpunit: ^1.3||^2.0
README
Filament Icons Picker & Provider
Picker & Table Column & Icons Provider for FilamentPHP
Screenshots
Installation
composer require tomatophp/filament-icons
after install use this command to cache all icons
php artisan filament-icons:install
Usage
use TomatoPHP\FilamentIcons\Components\IconPicker; public static function form(Form $form): Form { return $form ->schema([ IconPicker::make('icon') ->default('heroicon-o-academic-cap') ->label('Icon'), ]); }
use TomatoPHP\FilamentIcons\Components\IconColumn; public static function table(Table $table): Table { return $table ->columns([ IconColumn::make('icon') ->label('Icon'), ]); }
Add Custom Icons
you can add a custom icon lib by use this Facade class inside your provider like this
use TomatoPHP\FilamentIcons\Facades\FilamentIcons; public function boot(): void { FilamentIcons::register('boxicons') ->asset('https://unpkg.com/boxicons@2.1.4/css/boxicons.min.css') ->template('<i class="{ ICON }"></i>', 'text-xl', 'text-sm') ->icons([ "bx bx-accessibility", "bx bx-add-to-queue", "bx bx-adjust" ]) ->replace(['bx ', 'bxs-', 'bxl-', 'bx-']) ->save(); }
than you need to clear cache by use this command
php artisan filament-icons:clear
to cache it again use this command
php artisan filament-icons:install
you can try add Box Icons using this snap Box Icon Snap
Publish Assets
you can publish views file by use this command
php artisan vendor:publish --tag="filament-icons-views"
Publish Config
you can publish config file by use this command
php artisan vendor:publish --tag="filament-icons-config"
Other Filament Packages
Checkout our Awesome TomatoPHP