Closed Bug 201830 Opened 23 years ago Closed 7 years ago

Use shorthand for matching left/right/top/bottom properties in Computed Style and CSS Style Rules panels

Categories

(Other Applications :: DOM Inspector, enhancement)

x86
Windows XP
enhancement
Not set
normal

Tracking

(Not tracked)

RESOLVED INCOMPLETE

People

(Reporter: jruderman, Unassigned)

References

Details

DOM Inspector should use shorthand properties when left/right/top/bottom all match. For example, show border-color instead of the four border-color-[side] properties when all four match. (I'm not asking to collapse border-width, border-style, and border-color to border, because that would require the value column to be wider.) This might depend on bug 137688, "getPropertyValue on computed style does not do shorthand properties".
"might" as in "does". And on some mechanism for deciding that the shorthands are showable....
bz: I don't think there's anything we can do about whether short-hand properties are showable or not. I glanced at the code; it appears to just iterate through all the items computedStyle(element, "") returns. The only way we could do that would be if these particular properties computedStyle returns had some JS property to tell us what others it is bound to and vice versa.
Depends on: 137688
This could be fixed without fixing bug 137688. Just look for "-bottom" in each property name, and if you find "-bottom", check whether properties exist and have the same value when you replace "-bottom" with "-top", "-left", and "-right". If they exist and match, remove "-bottom" to get the shorthand property name. If you used a general mechanism from bug 137688, you might not be able to avoid also collapsing border-color, etc. into border.
Mass re-assigning bugs to dom.inspector@extensions.bugs
Assignee: caillon → dom.inspector
Product: Core → Other Applications
Assignee: dom-inspector → nobody
QA Contact: timeless → dom-inspector
Bulk close. This component is no longer supported or maintained. https://bugzilla.mozilla.org/show_bug.cgi?id=1499023
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → INCOMPLETE
Bulk close. This component is no longer supported or maintained. https://bugzilla.mozilla.org/show_bug.cgi?id=1499023
You need to log in before you can comment on or make changes to this bug.