[webkit-reviews] review requested: [Bug 38448] Web Inspector: Should Autocomplete Style Properties : [Attachment 54905] [PATCH] Proposed Fix
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Sun May 2 21:23:44 PDT 2010
Joseph Pecoraro <joepeck at webkit.org> has asked for review:
Bug 38448: Web Inspector: Should Autocomplete Style Properties
https://bugs.webkit.org/show_bug.cgi?id=38448
Attachment 54905: [PATCH] Proposed Fix
https://bugs.webkit.org/attachment.cgi?id=54905&action=review
------- Additional Comments from Joseph Pecoraro <joepeck at webkit.org>
The generated list in this example came from converting the properties list
from the CSS Tokenizer. However, the list can be automatically generated like
so:
> // This is the list of properties
> var properties = []
> var keywords = window.getComputedStyle(document.documentElement);
> for (var i = 0, len = keywords.length; i < len; ++i) {
>
> // Strip leading hyphen from -vendor properties
> var property = keywords[i];
> if (property.charAt(0) === "-")
> property = property.substring(1);
>
> // Turn hypens points into camel case points
> properties[i] = property.replace(/\-./g, function(c) {
> return c.charAt(1).toUpperCase();
> });
> }
>
> // `properties` contains the results
More information about the webkit-reviews
mailing list