schmeits/filament-4-tabler-icons
Tabler icons for Filament
All Tabler icons as a typed enum for Filament, so you get autocompletion instead of icon name strings. The SVGs come from blade-tabler-icons.
Compatibility
| Package | Filament | Laravel | PHP |
|---|---|---|---|
| 1.1 | 4.x and 5.x | 12 and 13 | 8.2 or higher (Laravel 13: 8.3 or higher) |
| 1.0 | 4.x | 11 and 12 | 8.2 or higher |
The package name still says "filament-4" for backwards compatibility; it works on Filament 5 as well.
Installation
composer require schmeits/filament-4-tabler-icons
Usage
use Filament\Forms\Components\TextInput;
use Schmeits\FilamentTablerIcons\Support\Icons\Tabler;
TextInput::make('name')
->required()
->prefixIcon(Tabler::MoodSmile);
The enum covers the outline set. Look up icons on tabler.io/icons: the icon mood-smile becomes Tabler::MoodSmile.
Unknown icons
blade-tabler-icons has section configured as its fallback icon. A name that does not exist therefore shows the section icon instead of throwing an error. With the enum you cannot pick a name that does not exist, but if you also use plain strings and prefer an error, publish the config of blade-tabler-icons and set the fallback to an empty string:
php artisan vendor:publish --tag=blade-tabler-icons-config
// config/blade-tabler-icons.php
'fallback' => '',
Updating the icons
The enum is generated from the installed version of blade-tabler-icons. After updating that package, regenerate it:
composer update secondnetwork/blade-tabler-icons
composer generate
The test suite fails when the enum is missing icons that the installed version ships.
Testing
composer test
composer analyse
Changelog
Please see CHANGELOG for more information on what has changed recently.
Security
Please see our security policy on how to report security vulnerabilities.
Credits
License
The MIT License (MIT). Please see License File for more information.
Related Packages
A Laravel Pulse card displaying the table info of the current database.
A widget for pan (lightweight and privacy-focused PHP product analytics library)
A character counter for the TextInput, Textarea and RichEditor fields of Filamen...
Phosphor icons for Filament 4 and 5 as a backed enum that scales with Filament's...
Version History
| Version | Released | PHP | License |
|---|---|---|---|
| 1.0.0 | ^8.2 | MIT |