[2.x] fix: align the post scrubber track with its chevrons - #5059
Merged
Merged
Conversation
The scrubber's track sat about five pixels left of the two chevron buttons that cap it, so the line and the bar did not line up with the icons pointing at them. The buttons are flush with the container and their icons are wider than the 1px track, so the track needs a larger left margin to centre under them. Measured on a discussion: the icons centre 8.75px from the container edge, the track centred at 3.5px. Moving the scrollbar's left margin from 3px to 8px carries the track, the bar, the unread marker and the info block with it in one declaration, since all four are positioned inside it. Reported by Tutrix on the Flarum forum, who found the same offset by eye: https://discuss.flarum.org/d/39746/25
imorland
force-pushed
the
fix/scrubber-track-alignment
branch
from
September 15, 2026 14:47
5a8f201 to
43513a3
Compare
imorland
approved these changes
Sep 15, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Spotted by Tutrix on the Flarum forum, in the rc.8 release thread. The offset below is theirs, found by eye; this PR moves the same distance in one declaration rather than three overrides.
The problem
The scrubber track sits noticeably left of the two chevron buttons that cap it, so neither the line nor the bar lines up with the icons pointing at them.
Measured on a discussion, relative to the scrubber container:
.Scrubber-first/.Scrubber-last)The buttons are
width: auto; padding: 0, so they sit flush with the container, and their icons are considerably wider than the 1px track..Scrubber-scrollbaronly offsets itself 3px, which leaves the whole column about five pixels left of the icons.The bar and the track line are correctly centred on each other (both at 0.5px within the scrollbar), so this is not a centring bug inside the scrubber. The assembly as a whole is in the wrong place.
The change
One value: the left margin on
.Scrubber-scrollbar, from3pxto8px.Everything else in the scrubber is positioned inside that element, so the track line, the bar, the unread marker and the absolutely positioned
.Scrubber-infoall move with it. That is why this does not need the separate nudges to.Scrubber-bar,.Scrubber-before,.Scrubber-afterand.Scrubber-infothat the forum post suggested: those were written as overrides from a custom stylesheet, where moving the container was not available.The resulting track centre is 8.5px, which is where the forum post's values land it as well.
Notes
Scrubber.lesshas not changed since 2024, so this is long-standing rather than an rc.8 regression. It is simply being looked at now.@phoneblock overrides onlyheightandmax-height, so nothing there is affected.Scrubber.less.