v2.2.0
What's New
This release adds automatic default state support to all StateFusion form components! 🎉
Features
- Automatic Default States: Form components now automatically initialize with the model's default state when creating new records
- Components updated:
StateFusionRadioStateFusionSelectStateFusionToggleButtons
How It Works
When you use StateFusion form components, they now automatically call getDefaultStateFor() to set the initial state for new records. This ensures consistent state initialization across your application.
// Example: Order form will automatically start in "Pending" state
StateFusionSelect::make('status')
->label('Order Status')
// No need to manually set default() anymore!Requirements
- Filament v4.x
- PHP 8.1+
- Laravel 10.x or 11.x
Installation
composer require a909m/filament-statefusion:^2.2Full Changelog: v2.1.0...v2.2.0