Skip to content

Conversation

@evanpurkhiser
Copy link
Member

The mock timeline was calculating positions incorrectly, causing misalignment
with the grid lines. This fix makes it match how the real CheckInTimeline
positions ticks.

Key changes:

  1. Use periodStart instead of start (which is underscanStart) as the base
    for timestamp calculations
  2. Add startOffset (underscanWidth) to all positions to account for the
    underscan area on the left
  3. Use elapsedMinutes from the config for consistency with grid calculations
  4. Use timelineWidth which excludes the underscan width

This matches the positioning logic in mergeBuckets where ticks are positioned
relative to the usable timeline area, not the full container width.

…e behavior

The mock timeline was calculating positions incorrectly, causing misalignment
with the grid lines. This fix makes it match how the real CheckInTimeline
positions ticks.

Key changes:
1. Use `periodStart` instead of `start` (which is underscanStart) as the base
   for timestamp calculations
2. Add `startOffset` (underscanWidth) to all positions to account for the
   underscan area on the left
3. Use `elapsedMinutes` from the config for consistency with grid calculations
4. Use `timelineWidth` which excludes the underscan width

This matches the positioning logic in mergeBuckets where ticks are positioned
relative to the usable timeline area, not the full container width.
@evanpurkhiser evanpurkhiser requested a review from a team November 12, 2025 21:24
@github-actions github-actions bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Nov 12, 2025
@evanpurkhiser evanpurkhiser merged commit 59fae0b into master Nov 12, 2025
49 checks passed
@evanpurkhiser evanpurkhiser deleted the evanpurkhiser/fix-crons-fix-mockcheckintimeline-positioning-to-match-real-timeline-behavior branch November 12, 2025 21:58
andrewshie-sentry pushed a commit that referenced this pull request Nov 13, 2025
…e behavior (#103264)

The mock timeline was calculating positions incorrectly, causing
misalignment with the grid lines. This fix makes it match how the real
CheckInTimeline positions ticks.

Key changes:
1. Use `periodStart` instead of `start` (which is underscanStart) as the
   base  timestamp calculations
2. Add `startOffset` (underscanWidth) to all positions to account for
   the underscan area on the left
3. Use `elapsedMinutes` from the config for consistency with grid
   calculations
4. Use `timelineWidth` which excludes the underscan width

This matches the positioning logic in mergeBuckets where ticks are
positioned relative to the usable timeline area, not the full container width.
@github-actions github-actions bot locked and limited conversation to collaborators Nov 28, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Scope: Frontend Automatically applied to PRs that change frontend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants