mirror of
https://github.com/pacnpal/thrilltrack-explorer.git
synced 2025-12-22 02:51:12 -05:00
Refactor: Implement app-wide DatePicker enhancements
This commit is contained in:
@@ -291,11 +291,13 @@ export function RideForm({ onSubmit, onCancel, initialData, isEditing = false }:
|
||||
</div>
|
||||
|
||||
<div className="space-y-2">
|
||||
<Label htmlFor="closing_date">Closing Date (if applicable)</Label>
|
||||
<Input
|
||||
id="closing_date"
|
||||
type="date"
|
||||
{...register('closing_date')}
|
||||
<Label>Closing Date (if applicable)</Label>
|
||||
<DatePicker
|
||||
date={watch('closing_date') ? new Date(watch('closing_date')) : undefined}
|
||||
onSelect={(date) => setValue('closing_date', date ? date.toISOString().split('T')[0] : '')}
|
||||
placeholder="Select closing date"
|
||||
disablePast={false}
|
||||
fromYear={1800}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user