console.group - clicking to expand logged object also expands or collapses group
Reported by
axef...@gmail.com,
Aug 21
|
|||||
Issue descriptionUserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3526.0 Safari/537.36 Steps to reproduce the problem: https://jsfiddle.net/56ydqbvk/ 1. Use console.group with one or more object arguments 2. Group to more than one depth level so as to have something to show or hide 3. Click on a logged object to hide or show the object's details Code: const obj = { a: 1, b: { c: 2, d: 3 } }; console.group('FIRST', obj); console.group('SECOND', obj); console.group('THIRD', obj); console.log('abc'); console.log('123'); console.log('xyz'); console.groupEnd(); console.groupEnd(); console.groupEnd(); What is the expected behavior? Toggling the object's expanded/collapsed state should not bubble up to affect the console group's expanded/collapsed state. What went wrong? The console group's expanded/collapsed state changes, even though it was the logged object that was clicked. Did this work before? N/A Chrome version: 70.0.3526.0 Channel: n/a OS Version: 10.0 Flash Version: I'm guessing this is a simple case of not preventing the click event from bubbling up to the console group?
,
Aug 21
,
Aug 21
,
Aug 25
,
Aug 25
Thanks for the report.
,
Sep 19
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/b420ade8c887d6f9acd7be0d4f0b14c6553ac743 commit b420ade8c887d6f9acd7be0d4f0b14c6553ac743 Author: Erik Luo <luoe@chromium.org> Date: Wed Sep 19 22:21:48 2018 DevTools: Console click handler should not capture This CL - Changes _messagesClicked's useCapture: true > false. - Hides gutter on Elements rendered outside ElementsTreeOutline. This affects two cases: A) Group with expandable objects (e.g. `console.group({x: 1})`), user clicks on the object. Now, clicking an object only expands the object, not the group. B) Element logged in Console (e.g. `document.body`), user clicks on "expand triangle", which overlaps with its gutter. Now that _messagesClicked does not capture, context menu would show upon clicking the gutter. This CL hides the gutter to allow expanding Elements in Console. Bug: 876162 Change-Id: I259f7f305d5ab975a4e8313d9200ff81d13eb9ec Reviewed-on: https://chromium-review.googlesource.com/1198422 Reviewed-by: Joel Einbinder <einbinder@chromium.org> Commit-Queue: Erik Luo <luoe@chromium.org> Cr-Commit-Position: refs/heads/master@{#592574} [add] https://crrev.com/b420ade8c887d6f9acd7be0d4f0b14c6553ac743/third_party/WebKit/LayoutTests/http/tests/devtools/console/console-group-click-expected.txt [add] https://crrev.com/b420ade8c887d6f9acd7be0d4f0b14c6553ac743/third_party/WebKit/LayoutTests/http/tests/devtools/console/console-group-click.js [modify] https://crrev.com/b420ade8c887d6f9acd7be0d4f0b14c6553ac743/third_party/blink/renderer/devtools/front_end/console/ConsoleView.js [modify] https://crrev.com/b420ade8c887d6f9acd7be0d4f0b14c6553ac743/third_party/blink/renderer/devtools/front_end/elements/ElementsTreeOutline.js [modify] https://crrev.com/b420ade8c887d6f9acd7be0d4f0b14c6553ac743/third_party/blink/renderer/devtools/front_end/elements/elementsTreeOutline.css
,
Oct 3
|
|||||
►
Sign in to add a comment |
|||||
Comment 1 by axef...@gmail.com
, Aug 21