Fix content jumping on Opera mobile browsers (#7777) #8241
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.
Summary
Fixes content jumping issue when scrolling on Opera browser on iPhone (reported in #7777).
Problem
Opera on iPhone has similar scroll behavior to Safari, but wasn't being detected in the scroll restoration logic. This caused content to jump up and down when scrolling.
Before fix:

Solution
Added Opera browser detection to the scroll restoration logic in
_app.tsx. Opera now gets the same treatment as Safari - settinghistory.scrollRestoration = 'auto'to prevent the scroll jumping issue.Changes
/OPR|Opera/iregex pattern (line 39)Testing
✅ Verified Opera detection:

✅ Tested scrolling behavior:
http://localhost:3000/blog/2025/04/23/react-labs-view-transitions-activity-and-more✅ Follows the same pattern as the existing Safari fix, which has been working well
After fix:
Screen.Recording.2026-01-16.at.7.50.58.PM.mov
Fixes #7777