shift-org / shift-docs

Website + calendar for the shift organization
https://shift2bikes.org
Other
22 stars 14 forks source link

fix pedalp inclusive/exclusive date differences #740

Closed ionous closed 2 weeks ago

ionous commented 2 weeks ago

first pass of turning inclusive dates in to exclusive dates for fullcal, re: https://github.com/shift-org/shift-docs/issues/739

setting this as draft until i ( and we all ) have more time to think about whether this might affect anything else. ( ex. FullCalendar is used in 4 partials )

/layouts/partials/cal/events.html /layouts/partials/cal/fullcal.html /layouts/partials/cal/pp-2020-cal.html /layouts/partials/cal/up-next.html

and, it'd be good to verify the behavior of some of the archive pages in years before 2021

ionous commented 2 weeks ago

found two issues:

  1. the pedalp 2020 page has its own FullCal code, and that needed to be adjusted to handle the new inclusive values;
  2. the default date handed to fullcal was a dayjs object; it worked, but elsewhere handing dayjs to FullCal causes errors. to be safe: made it native ( via toDate() ) matching the other parameters.