|
|
@ -19,22 +19,6 @@ import persian_fa from "react-date-object/locales/persian_fa"; |
|
|
|
// "جمعه",
|
|
|
|
// "جمعه",
|
|
|
|
// ];
|
|
|
|
// ];
|
|
|
|
|
|
|
|
|
|
|
|
function DisablePassedDaies({ direction, handleClick, disabled }) { |
|
|
|
|
|
|
|
return ( |
|
|
|
|
|
|
|
<i |
|
|
|
|
|
|
|
onClick={handleClick} |
|
|
|
|
|
|
|
style={{ |
|
|
|
|
|
|
|
padding: "0 10px", |
|
|
|
|
|
|
|
fontWeight: "bold", |
|
|
|
|
|
|
|
color: disabled ? "gray" : "blue", |
|
|
|
|
|
|
|
}} |
|
|
|
|
|
|
|
className={disabled ? "cursor-default" : "cursor-pointer"} |
|
|
|
|
|
|
|
> |
|
|
|
|
|
|
|
{direction === "right" ? ">" : "<"} |
|
|
|
|
|
|
|
</i> |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function CustomRangeInput({ openCalendar, value }) { |
|
|
|
function CustomRangeInput({ openCalendar, value }) { |
|
|
|
useEffect(() => { |
|
|
|
useEffect(() => { |
|
|
|
openCalendar(); |
|
|
|
openCalendar(); |
|
|
@ -77,10 +61,8 @@ const TestComponentNew = () => { |
|
|
|
onClose={() => false} |
|
|
|
onClose={() => false} |
|
|
|
arrow={false} |
|
|
|
arrow={false} |
|
|
|
minDate={new Date()} |
|
|
|
minDate={new Date()} |
|
|
|
renderButton={<DisablePassedDaies />} |
|
|
|
|
|
|
|
render={<CustomRangeInput />} |
|
|
|
render={<CustomRangeInput />} |
|
|
|
// weekDays={weekDays}
|
|
|
|
// weekDays={weekDays}
|
|
|
|
inputClass="custom-input" |
|
|
|
|
|
|
|
className="custom-calendar" |
|
|
|
className="custom-calendar" |
|
|
|
style={{ |
|
|
|
style={{ |
|
|
|
width: "100%", |
|
|
|
width: "100%", |
|
|
|