valentin-morice / currency-input
A Filament port Of MaryUI's Currency Input
Fund package maintenance!
valentin-morice
Installs: 8
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Language:JavaScript
Requires
- php: ^8.1
- filament/forms: ^3.2
- spatie/laravel-package-tools: ^1.15.0
Requires (Dev)
- laravel/pint: ^1.0
- nunomaduro/collision: ^7.9
- nunomaduro/larastan: ^2.0.1
- orchestra/testbench: ^8.0
- pestphp/pest: ^2.1
- pestphp/pest-plugin-arch: ^2.0
- pestphp/pest-plugin-laravel: ^2.0
- phpstan/extension-installer: ^1.1
- phpstan/phpstan-deprecation-rules: ^1.0
- phpstan/phpstan-phpunit: ^1.0
README
A Filament port of MaryUI's Currency Input.
Installation
You can install the package via composer:
composer require valentin-morice/currency-input
Usage
The CurrencyInput
class provides all the methods you would expect from a standard Filament component, with the addition of a locale
function, which formats the input properly. Once the input is blurred, the unmasked value is passed on to Livewire. The default formatting is en-US
.
public static function form(Form $form): Form { return $form ->schema([ CurrencyInput::make('amount') ->locale('fr-FR'), ]); }
Changelog
Please see CHANGELOG for more information on what has changed recently.
License
The MIT License (MIT). Please see License File for more information.