Skip to content

Makes roadmap current day indicator & timeline bars locale aware

What does this MR do and why?

Timeline bars positioning and current day indicator now uses user locale setting "First day of the week" to ensure that positioning is accurate regardless of what day user has set in preferences. Earlier, indicator position and timeline bar alignment worked correctly only if first day of the week was set to Sunday

Screenshots or screen recordings

Each section represents a day selected as First day of the week in user preferences, while the current date being 2023-05-17.

Saturday

Before After
image image

Sunday ( there won't be any difference here as this wasn't broken)

Before After
image image

Monday

Before After
image image

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

  1. Go to a group and create an Epic containing start and due date which falls somewhere in the middle of the week (eg; between Tuesday and Friday).
  2. Go to Profile > Preferences > Localization, and change First day of the week to Saturday and save.
  3. Visit Roadmap for the group where you created an epic in step 1, and notice if timeline bar and current day indicator are reflecting accurate dates.
  4. Repease steps 2 & 3 for First day of the week set to Monday.

Basically no matter what day is set in localization, timeline bars and current day indicator should render with correct dates.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #383744 (closed)

Edited by Kushal Pandya

Merge request reports