Skip to content

Commit

Permalink
fix: logic
Browse files Browse the repository at this point in the history
  • Loading branch information
Innocent-Akim committed Nov 11, 2024
1 parent b95a006 commit 0467309
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -322,7 +322,7 @@ export const FilterCalendar = memo(function FuturePlansCalendar<T extends { date
customInput={<DatePickerInput date={new Date()} label={''} />}
selected={selectedPlan || undefined}
onSelect={(date) => date && setSelectedPlan(moment(date).toDate())}
disabled={(date) => checkPastDate(date) && isDateAvailableForPlanning(date)}
disabled={(date) => checkPastDate(date) || !isDateAvailableForPlanning(date)}
modifiers={{
booked: sortedPlansByDateDesc.map(plan => moment.utc(plan.date.toString().split('T')[0]).toDate()),
pastDay: pastPlans.map(plan => moment.utc(plan.date.toString().split('T')[0]).toDate())
Expand Down

0 comments on commit 0467309

Please sign in to comment.