Skip to content

Fix on-call schedule timeline width calculation

Tristan Read requested to merge tr-oncall-schedule-fix-width-calc into master

What does this MR do?

Fixes an issue with the oncall width timeline.

The display of shifts is based on the width of the timeline. This data is being measured incorrectly, and this undermines the position and size of the displayed shifts.

Where we should be measuring the width of the displayed area, instead we are measuring the width of the whole timeline, including the rotation names to the left of the displayed area. This MR fixes that, ensuring the width calculation is correct.

This was introduced in the timeline refactor: !58204 (merged) / !58322 (merged) / #324608 (closed)

issue here: #327300 (closed)

Screenshots (strongly suggested)

before after
Screenshot_2021-04-09_at_16.06.09 Screenshot_2021-04-09_at_16.05.28
Screenshot_2021-04-09_at_16.06.02 Screenshot_2021-04-09_at_16.05.40
shift data for the rotation above
rotation_tooltip

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Security

If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:

  • [n/a] Label as security and @ mention @gitlab-com/gl-security/appsec
  • [n/a] The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • [n/a] Security reports checked/validated by a reviewer from the AppSec team
Edited by Tristan Read

Merge request reports

Loading