From 0897729bee2cd77f3417d510e15959782323a40d Mon Sep 17 00:00:00 2001 From: Kjell Kind Date: Sun, 15 Nov 2026 20:25:26 +0100 Subject: [PATCH] fix: open the commit graph on the latest weeks on phones, with the weekdays pinned The year grid scrolled to its right end from a ref, so phones first painted the oldest weeks until the page hydrated. The scroll container now runs right to left, which starts it at the latest weeks before any script runs, and the weekday labels stay put while the weeks scroll under them. Co-Authored-By: Claude Opus 5.5 --- resources/js/components/activity-graph.tsx | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) diff --git a/resources/js/components/activity-graph.tsx b/resources/js/components/activity-graph.tsx index 937f6792be..cdf3d7abe9 100644 --- a/resources/js/components/activity-graph.tsx +++ b/resources/js/components/activity-graph.tsx @@ -414,20 +414,15 @@ function YearGrid({ }; return ( -
{ - if (node) { - node.scrollLeft = node.scrollWidth; - } - }} - className="overflow-x-auto pb-1" - > + // Right to left, so a phone opens on the latest weeks before any script runs; the grid inside reads left to right. +
- +
{weekdayLabels.map((label, index) => (