parent
a7a5616438
commit
bbbc005465
2 changed files with 33 additions and 0 deletions
@ -0,0 +1,21 @@ |
||||
import React, { useState } from "react"; |
||||
import "../Calendar/index.css"; |
||||
import DatePicker from "react-modern-calendar-datepicker"; |
||||
|
||||
const RangeDatePicker = () => { |
||||
const [selectedDayRange, setSelectedDayRange] = useState({ |
||||
from: null, |
||||
to: null |
||||
}); |
||||
return ( |
||||
<DatePicker |
||||
value={selectedDayRange} |
||||
onChange={setSelectedDayRange} |
||||
inputPlaceholder="یک بازه زمانی انتخاب کنید" |
||||
shouldHighlightWeekends |
||||
locale='fa' |
||||
/> |
||||
); |
||||
}; |
||||
|
||||
export default RangeDatePicker; |
Loading…
Reference in new issue