Sidebar splitter stops working when dragging
Categories
(DevTools :: Debugger, defect, P3)
Tracking
(firefox79 verified)
Tracking | Status | |
---|---|---|
firefox79 | --- | verified |
People
(Reporter: karlcow, Assigned: alexand.dominguez)
References
(Blocks 1 open bug)
Details
Attachments
(4 files)
- Open https://maps.google.com/
- Open the debugger
Actual:
The left column with the name of resources is maximized to the point where the script central column is not usable. Not possible to manually resize
Expected:
- Columns being adjusted at a reasonable size by default.
- It can be resized manually.
This is high priority it's a major hurdle for using the tool. It has appeared recently maybe a couple of weeks ago. I was waiting to see if it would be fixed, but it's not yet.
Firefox Nightly 72.0a1 (2019-11-26) (64-bit)
Comment 1•4 years ago
|
||
I know we've changed some things around the sidebar, so possibly related to:
Reporter | ||
Comment 2•4 years ago
|
||
Not related, but the flex: 1
here has no effect and can be removed.
.split-box {
display: flex;
flex: 1;
min-width: 0;
height: 100%;
width: 100%;
}
For the issue at stake
html.theme-light body div#mount div.launchpad-root.theme-body div.debugger div.A11y-mouse div.split-box.vert div.uncontrolled div.split-box.vert div.controlled
This is the max-width
here which seems to set a size on the element and forbids it to be smaller.
element {
max-width: 85%;
min-width: 30px;
}
resource://devtools/client/debugger/src/components/App.js
startPanel: _react.default.createElement(_devtoolsSplitter.default, {
style: {
width: "100vw"
},
initialSize: _prefs.prefs.startPanelSize,
minSize: 30,
maxSize: "85%",
splitterSize: 1,
onResizeEnd: num => {
_prefs.prefs.startPanelSize = num;
},
startPanelCollapsed: startPanelCollapsed,
startPanel: _react.default.createElement(_PrimaryPanes.default, {
horizontal: horizontal
}),
endPanel: this.renderEditorPane()
}),
- 85% doesn't seem to be reasonable as a start value.
- The value is not adjusted when dragging the vertical separator. (onResize)
Reporter | ||
Comment 3•4 years ago
|
||
It's like the maxSize is interpreted as a minSize.
Reporter | ||
Comment 4•4 years ago
|
||
it doesn't fix things, but it improves a bit
/* Element | chrome://devtools/content/debugger/index.html */
div.controlled:nth-child(1) {
/* max-width: 85%; */
/* min-width: 30px; */
flex: 1 1 30px;
}
/* vendors.css | resource://devtools/client/debugger/dist/vendors.css */
.split-box > .uncontrolled {
/* flex: 1; */
/* min-width: 0; */
flex: 1 1 30px;
}
Comment 5•4 years ago
|
||
I can't reproduce the problem on my machine (Win10, Firefox Nightly)
Size of the left side bar (with Sources) can be manually changed in my case.
Karl, is there anything specific I should do?
Honza
Reporter | ||
Comment 6•4 years ago
|
||
Oh that's weird!
Honza, here a video of what I see.
macOS 10.15.1 (19B88) Firefox Nightly 72.0a1 (2019-11-28) (64-bit)
https://imgur.com/a/fM1woB2
Comment 7•4 years ago
|
||
I tried both Win and Mac and I still can't see the issue.
Logan, can you repro this?
Honza
Reporter | ||
Comment 8•4 years ago
|
||
Let me try to create a completely new profile.
…
…
ok this doesn't reproduce for me in a completely new profile. What could create this issue?
I have a couple of addons related to devtools.
Let's remove them one by one.
…
…
It doesn't reproduce.
Would it be a specific config?
…
…
devtools.aboutdebugging.collapsibilities.processes: true
which doesn't exist in the new profile. I removed it.devtools.chrome.enabled: true
set it to false againdevtools.command-button-screenshot.enabled: true
to falsedevtools.debugger.dom-mutation-breakpoints-visible: true
to falsedevtools.debugger.end-panel-size: 297
back to 300.devtools.debugger.start-panel-size: -8770
back to 300
ah this one seems related, after setting back to 300. and trying to grab the vertical sep to move it goes back to a very large negative value.
wow… and I repaired it. Changing the value to 300 didn't solve anything but dragging and drop toward the right side until the value becomes positive again made it working again.
Restarting and this is working too.
So I have no idea… how it became this, but probably there should be a way to detect that the value is not making sense.
Hope it helps. Feel free to close if you think it's a too peculiar issue.
Comment 9•4 years ago
|
||
Thanks for the analysis Karl, that's super helpful!
I think there is a bug related to how the pref value is stored. I was able to quickly break the separator by moving the mouse far from it when dragging.
Here is my STR:
- Load
about:config
and search fordevtools.debugger.start-panel-size
(so, we can see how value of the pref is changing) - Open DevTools and select the Debugger panel
- Chang size of the left side bar (Sources, Outline). While dragging the vertical splitter move mouse to far right (and perhaps across multitple monitors if you have) - do not stop even if the size of the bar isn't changing anymore.
- Release the mouse and check the value (I was able to get > 1000)
- Repeat the same multiple times and also with the right side bar.
- Observe the behavior - it breaks quickly -> BUG
It looks like we shouldn't store the position of the mouse, but rather actual size of the bar.
@Jason, perhaps we could provide some instructions how to fix it and make it good first bug?
Honza
Assignee | ||
Comment 10•4 years ago
|
||
For the start-panel
, clientWidth + movementX can be stored as state.width. This ensures that the panel does not grow more than its allowed limit. end-panel
is not as straightforward, but I would like to continue working towards a solution. May I be assigned this bug?
Comment 11•4 years ago
|
||
You are now assigned, thanks for the help!
Honza
Assignee | ||
Comment 12•4 years ago
|
||
I have made my changes in vendors.js
, you can find my revision here: https://phabricator.services.mozilla.com/D69708
Assignee | ||
Comment 13•4 years ago
|
||
Bug 1599978 - Used correct variable.
Updated•4 years ago
|
Assignee | ||
Comment 14•4 years ago
|
||
Comment 15•4 years ago
|
||
Pushed by hmanilla@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/e6d1fb1401f0 Stores clientX as state.width for start-panel and the difference between clientWidth and clientX for end-panel. r=bomsy,davidwalsh
Comment 16•4 years ago
|
||
bugherder |
Updated•4 years ago
|
Comment 17•4 years ago
|
||
Verified with 79.0b2 and 80.a1(2020-07-01) on Windows 10/macOS 10.15.5
Updated•2 years ago
|
Description
•