Download the PHP package ranium/filament-flags-dropdown without Composer
On this page you can find all versions of the php package ranium/filament-flags-dropdown. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download ranium/filament-flags-dropdown
More information about ranium/filament-flags-dropdown
Files in ranium/filament-flags-dropdown
Package filament-flags-dropdown
Short Description Flag dropdown field for Filament forms
License MIT
Homepage https://github.com/ranium/filament-flags-dropdown
Informations about the package filament-flags-dropdown
Flags dropdown field for Filament forms
A dropdown field with flags and custom labels. The field can be used as a country or language selector in Filament forms.
This package utilizes flag-icons to display the country flags.
Installation
You can install the package via composer:
You can publish the config file with (optional):
Usage
You can now use the FlagsDropdown field in your form builder. You need to provide the options to display in the dropdown.
The options array keys should be the ISO 3166-1-alpha-2 code of the country and the value should be an array of value
and label
for the option. In the following example, IND
will be saved in the database when India
is chosen from the dropdown.
If you want the dropdown to have the same value
as the label
then your options can be built like this:
In this case the field's value will be "India" when that option is chosen.
Events
The field fires an event whenever its value is changed. You can listen to the event and bind it to a callable. The new and old values are passed as arguments to the callable.
Testing
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
Credits
- Abbas Ali
- All Contributors
License
The MIT License (MIT). Please see License File for more information.
All versions of filament-flags-dropdown with dependencies
spatie/laravel-package-tools Version ^1.14.0
illuminate/contracts Version ^10.0
filament/filament Version ^2.0