The second argument to getComputedStyle() is defined as:
pseudoElt of type DOMString
The pseudo-element or null if none.
This seems to me to be very much under-specified.
For example, is "first-letter" an acceptable value of "pseudoElt"? What
about ":first-letter"? What about "::first-letter"?
Presumably ":selection" would be invalid, but what about "selection" or
"::selection"?
It seems to me that in this context the string is unambiguously a
pseudo-element, so "first-letter", ":first-letter", "::first-letter",
"selection", "::selection" should all be allowed and do the right thing,
while ":selection" should not have any effect (be treated as "" or null).
Comments?
Boris
-----------------
617-864-9910
-----------------
We are all agreed that your theory is crazy. The
question which divides us is whether it is crazy enough
to have a chance of being correct. My own feeling is
that it is not crazy enough.
-- Niels Bohr