Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(163)

Issue 12504: Fix bug 973: getComputedStyle does not accept empty string as 2nd arg (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
17 years, 4 months ago by MikeSamuel
Modified:
16 years, 10 months ago
Reviewers:
metaweta
CC:
google-caja-discuss_googlegroups.com
Base URL:
http://google-caja.googlecode.com/svn/trunk/
Visibility:
Public.

Description

I just updated the domita taming to recognize the empty string as legit. From the bug: window.getComputedStyle(document.body, null).width; // works window.getComputedStyle(document.body, '').width; // fails as "Bad pseudo class" Technically caja is right per the spec: "pseudoElt of type DOMString The pseudo-element or null if none." http://www.w3.org/TR/DOM-Level-2-Style/css.html#CSS-OverrideAndComputed But Mozilla docs contradict this: "pseudoElt is a string specifying the pseudo-element to match. Should be an empty string for regular elements." https://developer.mozilla.org/En/DOM:window.getComputedStyle However, all browsers that implement computedStyle accept either form (and possibly other falsey values).

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+9 lines, -1 line) Patch
M src/com/google/caja/plugin/domita.js View 1 chunk +9 lines, -1 line 0 comments Download

Messages

Total messages: 2
MikeSamuel
17 years, 4 months ago (2009-01-26 02:07:43 UTC) #1
metaweta
17 years, 4 months ago (2009-01-27 20:29:15 UTC) #2
LGTM
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b