JSON viewer should not scroll to the top of the row if it's too tall

RESOLVED FIXED in Firefox 58

Status

defect
RESOLVED FIXED
2 years ago
Last year

People

(Reporter: Oriol, Assigned: Oriol)

Tracking

({regression})

58 Branch
Firefox 58
Dependency tree / graph

Firefox Tracking Flags

(firefox-esr52 unaffected, firefox56 unaffected, firefox57 unaffected, firefox58 fixed)

Details

Attachments

(1 attachment)

1. Open the console and enter

    location.href = encodeURI("data:application/json," + JSON.stringify(["Lorem ipsum. ".repeat(1500)]))

2. There should be a vertical scrollbar (otherwise shrink the Firefox window)

3. Scroll down

4. Select some text contents

Result: JSON Viewer scrolls to the top of the cell when you release the mouse. The text you selected may no longer be visible.
With this the behavior seems more reasonable, scrollIntoView should have some option to do this.
Comment on attachment 8926950 [details]
Bug 1415919 - Improve how JSON Viewer scrolls selected row into view.

https://reviewboard.mozilla.org/r/198202/#review203722

Looks reasonable, good work as usual Oriol!
R+ assuming Try is green

Honza
Attachment #8926950 - Flags: review?(odvarko) → review+
The Try failures were due to bug 1416070.
Keywords: checkin-needed
I did a trivial simplification of scrollContainer.
Pushed by ryanvm@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/efbc0ed871b5
Improve how JSON Viewer scrolls selected row into view. r=Honza
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/efbc0ed871b5
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 58
Depends on: 1416394
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.