JTAppleCalendar
JTAppleCalendar copied to clipboard
Scrolling to today for vertical not page mode calendar
(Required) Version Number: 8.0.3
Description
Thank you for this great job.
Recently I am building a vertical scrolling calendar, not page mode. I want to scroll the calendar to today but failed in the end. I tried a lot of ways, including all the functions which name has "scrollTo" prefix.
I must miss something since this is a common feature, but I just can't find it.
Steps To Reproduce
Same as the description:
- Vertical calendar
- Scroll to today
Expected Behavior
There is a way to scroll to today. Even a tricky way is acceptable.
Additional Context
Did you put this in your viewDidLoad
function?
calendarView.scrollToDate(Date())
I tried, but it had a weird contentOffset.
Because Of recent events, I am now getting back to this.
So it looks like it correctly scrolls to March 3rd
.
But, it also looks like since March is the final month in the calendar, it has a visual bug which pulls the 3rd
to the top of the screen.
Can i confirm something? Can you make the last month not be March?
For example, if you want you range to be January to March, then make your date boundary to be January to April. I want to test to see if it correctly scrolls to the right offset if there is an extra month behind the final month.
Thank you for your reply. And sorry for my late reply. I tried if the boundary is not March, then everything is okay. Btw my app has already released. I used scrollToHeader or section something, instead of scrollToDate