Make horizontal padding relative to device width#20047
Merged
calixteman merged 1 commit intomozilla:masterfrom Jul 3, 2025
Merged
Make horizontal padding relative to device width#20047calixteman merged 1 commit intomozilla:masterfrom
calixteman merged 1 commit intomozilla:masterfrom
Conversation
6a6c68a to
d929aff
Compare
The fixed -400px horizontal offset used by scrollIntoView led to horizontal scroll only moving part-way right on narrow screens. The highlights near the right-edge remained party or completely off screen. This centres the highlighted match on any viewport width while clamping the left margin to 20-400px. On very narrow screens the scrollbar now moves all the way to the right instead of stopping midway.
d929aff to
c138887
Compare
nicolo-ribaudo
approved these changes
Jul 1, 2025
Contributor
|
/botio integrationtest |
Collaborator
From: Bot.io (Windows)ReceivedCommand cmd_integrationtest from @calixteman received. Current queue size: 1 Live output at: http://54.193.163.58:8877/c6c827a1914a3ce/output.txt |
Collaborator
From: Bot.io (Linux m4)ReceivedCommand cmd_integrationtest from @calixteman received. Current queue size: 0 Live output at: http://54.241.84.105:8877/b90a69d5b950b66/output.txt |
Collaborator
From: Bot.io (Linux m4)FailedFull output at http://54.241.84.105:8877/b90a69d5b950b66/output.txt Total script time: 13.86 mins
|
Collaborator
From: Bot.io (Windows)FailedFull output at http://54.193.163.58:8877/c6c827a1914a3ce/output.txt Total script time: 26.74 mins
|
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.
The fixed -400px horizontal offset used by
scrollIntoViewled to horizontal scroll only moving part-way right on narrow screens. The highlights near the right-edge remained partly or completely offscreen. This can be observed by searching for words on the far-right of the screen on devices with small screens on both Firefox and Chrome.This centres the highlighted match on any viewport width while clamping the left margin to 20-400px. On very narrow screens the scroll bar now moves all the way to the right instead of stopping midway
Note: Since the minimum width of mainContainer is set to 350px, the scrolling into view still doesn't work right for viewports less than 350px on desktop.