Closed Bug 814923 Opened 12 years ago Closed 12 years ago

implement CSS.supports

Categories

(Core :: DOM: CSS Object Model, defect)

defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 779917

People

(Reporter: heycam, Assigned: heycam)

References

()

Details

Attachments

(1 file)

      No description provided.
Depends on: 814566
Attached patch patchSplinter Review
I wasn't totally sure what to do if a premature end of the string was reached within a condition or property value.  The behaviour that fell out was the same as EOF handling in style sheets.  For example these return true:

  CSS.supports("(color: green) /*")
  CSS.supports("(color: green")
  CSS.supports("(font-family: 'Helvetica")
  CSS.supports("color", "green /*")
  CSS.supports("font-family", "'Helvetica")

and these false:

  CSS.supports("(font-family: 'Helvetica\n")
  CSS.supports("font-family", "'Helvetica\n")

Another I was unsure about was:

  CSS.supports("Color", "green")

That is currently returning true, but the spec says it should return true only if it is "a literal match for the name of a CSS property that the UA supports".
Assignee: nobody → cam
Status: NEW → ASSIGNED
Attachment #684914 - Flags: review?(dbaron)
This really should have been on bug 779917; moving the patch there now.
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → DUPLICATE
Attachment #684914 - Flags: review?(dbaron)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: