mirror of
https://github.com/tomru/pfadi-bussle.git
synced 2026-03-03 06:27:11 +01:00
improve date select
This commit is contained in:
@@ -16,36 +16,38 @@ export default function DateSelect() {
|
||||
start={startDate}
|
||||
end={endDate}
|
||||
onChange={onChange}
|
||||
className="m-6"
|
||||
className="my-6 max-w-lg"
|
||||
/>
|
||||
<div className="inline-block mr-6">
|
||||
<label className="flabel inline-block w-6 mr-3" htmlFor="startDate">
|
||||
Von
|
||||
</label>
|
||||
<input
|
||||
required
|
||||
type="date"
|
||||
className="input-text"
|
||||
name="startDate"
|
||||
value={startDate || ''}
|
||||
onChange={onChangeEvent}
|
||||
min={today}
|
||||
/>
|
||||
</div>
|
||||
<div className="inline-block">
|
||||
<label className="flabel inline-block w-6 mr-3" htmlFor="endDate">
|
||||
Bis
|
||||
</label>
|
||||
<input
|
||||
required
|
||||
type="date"
|
||||
className="input-text"
|
||||
name="endDate"
|
||||
value={endDate || ''}
|
||||
placeholder="Von"
|
||||
onChange={onChangeEvent}
|
||||
min={startDate || today}
|
||||
/>
|
||||
<div className="grid grid-cols-1 sm:grid-cols-2 gap-4">
|
||||
<div className="">
|
||||
<label className="flabel inline-block mr-3" htmlFor="startDate">
|
||||
Von
|
||||
</label>
|
||||
<input
|
||||
required
|
||||
type="date"
|
||||
className="input-text"
|
||||
name="startDate"
|
||||
value={startDate || ''}
|
||||
onChange={onChangeEvent}
|
||||
min={today}
|
||||
/>
|
||||
</div>
|
||||
<div className="">
|
||||
<label className="flabel inline-block mr-3" htmlFor="endDate">
|
||||
Bis
|
||||
</label>
|
||||
<input
|
||||
required
|
||||
type="date"
|
||||
className="input-text"
|
||||
name="endDate"
|
||||
value={endDate || ''}
|
||||
placeholder="Von"
|
||||
onChange={onChangeEvent}
|
||||
min={startDate || today}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</InputWrapper>
|
||||
</>
|
||||
|
||||
Reference in New Issue
Block a user