Closed
Bug 1419086
Opened 8 years ago
Closed 8 years ago
Render the ObjectInspector in the sidebar
Categories
(DevTools :: Console, enhancement, P2)
DevTools
Console
Tracking
(firefox59 fixed)
RESOLVED
FIXED
Firefox 59
| Tracking | Status | |
|---|---|---|
| firefox59 | --- | fixed |
People
(Reporter: nchevobbe, Assigned: mpark)
References
(Blocks 2 open bugs)
Details
Attachments
(1 file)
We should render a ObjectInspector component corresponding to the clicked object in the sidebar
| Reporter | ||
Updated•8 years ago
|
Severity: normal → enhancement
Priority: -- → P2
| Comment hidden (mozreview-request) |
| Reporter | ||
Comment 2•8 years ago
|
||
| mozreview-review | ||
Comment on attachment 8936906 [details]
Bug 1419086 - Render the ObjectInspector in the console sidebar.
https://reviewboard.mozilla.org/r/207628/#review213512
This looks good, thanks Mike !
Seeing the way we insantiate the ObjectInspector, I fear we missed something either in the sidebar, or in GripmessageBody when we need to add other props.
Do you think we could have a getObjectInspector(grip, serviceContainer, override) function ?
Overrides would let us specify different things in GripMessageBody and Sidebar (like autoExpand for example).
This would then be easier to use the new functionalities of ObjectInspector
::: devtools/client/webconsole/new-console-output/components/SideBar.js:50
(Diff revision 1)
> + ? (object) => serviceContainer.highlightDomElement(object)
> + : null;
this should be indented
::: devtools/client/webconsole/new-console-output/components/SideBar.js:54
(Diff revision 1)
> + ? (object, e) => {
> + // Stop the event propagation so we don't trigger ObjectInspector expand/collapse.
> + e.stopPropagation();
> + serviceContainer.openNodeInInspector(object);
> + }
> + : null;
this should be indented
Attachment #8936906 -
Flags: review?(nchevobbe) → review+
| Comment hidden (mozreview-request) |
| Reporter | ||
Comment 4•8 years ago
|
||
| mozreview-review | ||
Comment on attachment 8936906 [details]
Bug 1419086 - Render the ObjectInspector in the console sidebar.
https://reviewboard.mozilla.org/r/207628/#review213956
::: devtools/client/webconsole/new-console-output/components/SideBar.js:43
(Diff revisions 1 - 2)
> sidebarVisible,
> grip,
> serviceContainer,
> } = this.props;
>
> - let onDOMNodeMouseOver;
> + let override = {
i think i can inline this object directly in the getObjectInspector call
::: devtools/client/webconsole/new-console-output/components/GripMessageBody.js:65
(Diff revision 2)
> let styleObject;
> if (userProvidedStyle && userProvidedStyle !== "") {
> styleObject = cleanupStyle(userProvidedStyle, serviceContainer.createElement);
> }
>
> - let onDOMNodeMouseOver;
> + let override = {
we could name it objectInspectorProps I think, so it is more obious what it is.
::: devtools/client/webconsole/new-console-output/utils/object-inspector.js:1
(Diff revision 2)
> +/* -*- indent-tabs-mode: nil; js-indent-level: 2 -*- */
> +/* vim: set ft=javascript ts=2 et sw=2 tw=80: */
let's not add those
::: devtools/client/webconsole/new-console-output/utils/object-inspector.js:81
(Diff revision 2)
> + Object.assign(objectInspectorProps, override);
> +
> + return ObjectInspector(objectInspectorProps);
I think we can do
return ObjectInspector({...objectInspectorProps, override});
| Comment hidden (mozreview-request) |
Pushed by nchevobbe@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/c82766bc8524
Render the ObjectInspector in the console sidebar. r=nchevobbe
Comment 7•8 years ago
|
||
| bugherder | ||
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 59
Updated•8 years ago
|
Product: Firefox → DevTools
Updated•7 years ago
|
Assignee: nobody → mpark
You need to log in
before you can comment on or make changes to this bug.
Description
•