Closed
Bug 986201
Opened 10 years ago
Closed 10 years ago
Computed style trace can't be shown for properties when they have multiple inherited inline styles
Categories
(DevTools :: Inspector, defect)
DevTools
Inspector
Tracking
(Not tracked)
RESOLVED
FIXED
Firefox 34
People
(Reporter: sebo, Assigned: sjakthol)
References
()
Details
Attachments
(1 file, 1 obsolete file)
2.66 KB,
patch
|
jwalker
:
review+
|
Details | Diff | Splinter Review |
Steps to reproduce the problem: 1. Inspect the "List item" at https://getfirebug.com/tests/manual/issues/7269/issue7269.html 2. Switch to the Computed side panel 3. Click the arrow besides the 'color' property => Nothing happens. You would expect to see the two values 'blue' and 'green' defined by its <ul> and <div> ancestor. See the related Firebug issue http://code.google.com/p/fbug/issues/detail?id=7269. There this error was thrown: Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [inIDOMUtils.getSpecificity] resource://gre/modules/commonjs/toolkit/loader.js -> resource://gre/modules/devtools/styleinspector/css-logic.js:1443 Sebastian
Comment 1•10 years ago
|
||
Confirmed 31.0a1 (2014-03-21), win 7 x64
Status: UNCONFIRMED → NEW
Ever confirmed: true
Reporter | ||
Comment 2•10 years ago
|
||
That's still happening on 33.0a1 (2014-07-15), just the line has changed to resource://gre/modules/devtools/styleinspector/css-logic.js:1486:24. Sebastian
Assignee | ||
Comment 3•10 years ago
|
||
DOMUtils.getSpecificity expects an object with CSSStyleRule interface which element.style doesn't implement. As specificity of element style is constant[1], this patch just returns the specificity right away without calling DOMUtils.getSpecificity. The patch also includes an unit test to ensure specificity is correctly handled for element styles. Try run: https://tbpl.mozilla.org/?tree=Try&rev=2170adb746f6 [1] http://www.w3.org/TR/CSS2/cascade.html#specificity
Attachment #8459129 -
Flags: review?(jwalker)
Comment 4•10 years ago
|
||
Comment on attachment 8459129 [details] [diff] [review] fix-bug-986201.patch Review of attachment 8459129 [details] [diff] [review]: ----------------------------------------------------------------- Thanks for the patch! There is an existing test for css-logic specificity: http://dxr.mozilla.org/mozilla-central/source/browser/devtools/styleinspector/test/browser_styleinspector_csslogic-specificity.js. I think it would make sense to add the test into that file instead of adding a new one.
Comment 5•10 years ago
|
||
Comment on attachment 8459129 [details] [diff] [review] fix-bug-986201.patch Review of attachment 8459129 [details] [diff] [review]: ----------------------------------------------------------------- I wish we'd called this.elementStyle, this._isElementStyle to make it clearer that it's a boolean. Nit: In addition to Brian's comments, this patch adds some trailing whitespace that we should remove before we commit it. Thanks, and sorry for the slow review.
Attachment #8459129 -
Flags: review?(jwalker) → review+
Assignee | ||
Comment 6•10 years ago
|
||
Thanks for the review. Here's a patch without the trailing whitespace and the test is merged into browser_styleinspector_csslogic-specificity.js. Will push to try once it stops timing out.
Assignee: nobody → sjakthol
Attachment #8459129 -
Attachment is obsolete: true
Status: NEW → ASSIGNED
Attachment #8463424 -
Flags: review?(jwalker)
Assignee | ||
Comment 7•10 years ago
|
||
Try: https://tbpl.mozilla.org/?tree=Try&rev=3becf6642262
Updated•10 years ago
|
Attachment #8463424 -
Flags: review?(jwalker) → review+
Assignee | ||
Updated•10 years ago
|
Keywords: checkin-needed
Comment 8•10 years ago
|
||
https://hg.mozilla.org/integration/fx-team/rev/a9c0471594e5
Keywords: checkin-needed
Whiteboard: [fixed-in-fx-team]
https://hg.mozilla.org/mozilla-central/rev/a9c0471594e5
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Whiteboard: [fixed-in-fx-team]
Target Milestone: --- → Firefox 34
Reporter | ||
Comment 10•10 years ago
|
||
I can confirm that it's working now. Thanks! Sebastian
Updated•6 years ago
|
Product: Firefox → DevTools
You need to log in
before you can comment on or make changes to this bug.
Description
•