shayanys/iranian-date-picker
A Laravel package that adds an Iranian (Jalali/Persian) date picker to your forms. It offers a simple, ready-to-use picker for selecting Persian dates, making it easier to build localized apps and provide a natural date-selection experience for Persian-speaking users, with easy integration into Lara...
composer require shayanys/iranian-date-picker. Before committing, confirm the version you get is compatible with your Filament major — the last release (2023-04-26) predates Filament v3 stable, so budget time to test on v2 or an early v3.src/ is your only source of truth. Skim the service provider to see what it auto-registers and whether there are publishable config/assets.php artisan vendor:publish for the package tag and php artisan filament:assets. A calendar that refuses to open is almost always a missing asset, not a logic bug.birthday, due_date, delivery_at — where the operator picks in the Persian calendar but you persist a normal Gregorian DATE/DATETIME column so the rest of your app (Eloquent casts, Carbon, reports) keeps working.IranianDatePicker::make('due_date')->label('تاریخ سررسید'). Keep the underlying column a standard date cast.TextColumn::formatStateUsing() with verta()/Morilog\Jalali for display, and let the picker handle input.before() hook or a custom rule so "not before today" and min/max windows stay correct across leap months.->query(fn ($q, $data) => $q->whereBetween(...)).->key() if Livewire re-renders leave stale inputs or a picker attached to the wrong row.Field base classes changed between v2 and v3. A Class not found error usually means version mismatch, not a bug in your code.Y-m-d. Dump $livewire->data after submit; if it's Jalali, add ->dehydrateStateUsing(fn ($state) => Jalali::toGregorian($state)) before saving.Asia/Tehran. If your app runs UTC, selections near midnight shift by a day — normalize in a mutator or set the app timezone explicitly.vendor/.morilog/jalali plus Filament's stock DatePicker with a format()/dehydrateStateUsing conversion is a viable drop-in if you'd rather not depend on an unmaintained plugin.How can I help you explore Laravel packages today?