Clicking "Inspect element" in responsive mode doesn't select the inspected element
Categories
(DevTools :: Responsive Design Mode, defect, P1)
Tracking
(firefox-esr60 unaffected, firefox-esr68 unaffected, firefox68 unaffected, firefox69 verified, firefox70 verified)
Tracking | Status | |
---|---|---|
firefox-esr60 | --- | unaffected |
firefox-esr68 | --- | unaffected |
firefox68 | --- | unaffected |
firefox69 | --- | verified |
firefox70 | --- | verified |
People
(Reporter: bbouvier, Assigned: jdescottes)
References
(Regression)
Details
(Keywords: regression, Whiteboard: [dt-q])
Attachments
(2 files)
47 bytes,
text/x-phabricator-request
|
Details | Review | |
5.55 KB,
patch
|
jdescottes
:
review+
RyanVM
:
approval-mozilla-beta+
|
Details | Diff | Splinter Review |
Comment 1•7 years ago
|
||
Comment 2•7 years ago
|
||
Updated•7 years ago
|
Reporter | ||
Comment 4•6 years ago
|
||
Comment 5•6 years ago
|
||
Re-opening this since this issue has started happening again. Can replicate it using the steps described by the reporter.
Assignee | ||
Comment 7•6 years ago
•
|
||
There seems to be a race in nsContextMenu.js. When the context menu opens, we execute
this.targetSelectors = gContextMenuContentData
? gContextMenuContentData.popupNodeSelectors
: [];
nsContextMenu.js#303-305
targetSelectors
is what will be passed to DevTools to get the actual target for inspectElement. In most cases, when RDM is enabled gContextMenuContentData.popupNodeSelectors
will be ".browser" which won't resolve to anything in the markup view. But if you wait before, you will get the correct selector.
Edit: Actually I can also see that when using RDM, we call twice nsContextMenu's openContextMenu
. If you log the associated popupNodeSelectors, the first call will contain ".browser"
and the second call will contain the proper selector.
Assignee | ||
Comment 8•6 years ago
|
||
I suspect a regression from Bug 1505909
Assignee | ||
Updated•6 years ago
|
Assignee | ||
Comment 9•6 years ago
|
||
Updated•6 years ago
|
Comment 11•6 years ago
•
|
||
This has started consistently affecting users of Firefox 69 and 70. We should address this very soon. Thank you, Julian for investigating!
Comment 12•6 years ago
|
||
Gabriel, can you help find an owner for this bug? It would be good to fix this for 69 if possible.
Comment 13•6 years ago
|
||
(In reply to Liz Henry (:lizzard) (use needinfo) from comment #12)
Gabriel, can you help find an owner for this bug? It would be good to fix this for 69 if possible.
Looks like Julian is already investigating.
Updated•6 years ago
|
Assignee | ||
Comment 15•6 years ago
|
||
(In reply to Razvan Caliman [:rcaliman] from comment #11)
This has started consistently affecting users of Firefox 69 and 70. We should address this very soon. Thank you, Julian for investigating!
Sure thing! Good news is that the patch seems to apply cleanly on beta and also fixes the issue there, so uplifting should be easy once we get it in central
Assignee | ||
Updated•6 years ago
|
Comment 16•6 years ago
|
||
Comment 17•6 years ago
|
||
bugherder |
Comment 18•6 years ago
|
||
Please nominate this for Beta approval when you get a chance.
Assignee | ||
Comment 19•6 years ago
|
||
Beta/Release Uplift Approval Request
- User impact if declined: Right Click > Inspect Element no longer works when Responsive Design Mode is enabled
- Is this code covered by automated tests?: Yes
- Has the fix been verified in Nightly?: No
- Needs manual test from QE?: Yes
- If yes, steps to reproduce: - open any website (eg https://www.mozilla.org/en-US/)
- open DevTools
- enable Responsive Design mode
- right click on an element in the page, inside the RDM viewport
- select "Inspect Element"
Expected Result: In the DevTools inspector, the Rules panel should show the rules applying to the element
Actual Result: The Rules panel shows "No element selected."
- List of other uplifts needed: None
- Risk to taking this patch: Low
- Why is the change risky/not risky? (and alternatives if risky): Simple javascript fix, covered by automated tests.
- String changes made/needed:
Assignee | ||
Updated•6 years ago
|
Updated•6 years ago
|
Comment 20•6 years ago
|
||
Verified as fixed on latest Nightly 70.0a1(20190719094503)
Comment 21•6 years ago
|
||
Comment 22•6 years ago
|
||
bugherder uplift |
Comment 23•6 years ago
|
||
Reproduced the issue on Beta 69.0b6(20190718172058). Verified as fixed on Beta 69.0b7(20190722201635) on Win10 x64, Ubuntu 18.04 and MacOS 10.14
Comment 24•6 years ago
|
||
Thank you for fixing this! It was impeding my web development workflow. Cheers.
Updated•3 years ago
|
Description
•