Created calender examples that use the current week.

This commit is contained in:
Lucid Kobold
2022-06-22 13:03:10 -05:00
parent 1d8144cbc4
commit dbd2140b5e
5 changed files with 259 additions and 14 deletions

View File

@@ -10,6 +10,9 @@ const Calender = ({
date: newDate,
isLoading
}: UpdateCalendarProps): JSX.Element => {
const dispatch = useAppDispatch();
// * Month * //
const currDate: string = useAppSelector((state) => state.calender.currDate);
const selectedDate: SelectedDateInfo = useAppSelector(
@@ -25,8 +28,6 @@ const Calender = ({
(state) => state.stickers.stickersMonth
);
const dispatch = useAppDispatch();
useEffect(() => {
if (newDate && newDate.year && newDate.month && newDate.day) {
const { year, month, day } = newDate;
@@ -143,7 +144,7 @@ const Calender = ({
id.length
? id
: format(toDateObj, "yyyyddLL") +
`/${sticker === null ? 0 : sticker}`
`/${sticker === null ? 0 : sticker}`
}
/>
);