I'm working on a site that has a large number of color styles, around 250 lines of CSS to define one of 7 color schemes, so it's important that I keep the various color rules grouped as best I can.
The newest RC of Firefox 4 is behaving badly when I try and stack selectors relating to the deprecated CSS3 ::selection
pseudo element.
This works:
.green ::-moz-selection {
/* 'Pure Hue' Color */
background-color: #62BA21;
color: white;
}
But once I try and share the rule with the selector for webkit it breaks.
Does not work for FireFox:
.green ::selection, .green ::-moz-selection {
/* 'Pure Hue' Color */
background-color: #62BA21;
color: white;
}
I understand they might not be addressing the bug since ::selection
is no longer present in the working draft, but I'd prefer if I didn't have to bloat my CSS any more than it already is for this quirk.
::selection
wasn't deprecated, per se. It was just removed from the selectors spec. Not sure if it's been dropped altogether or something, but it is very well-implemented across modern versions of browsers nevertheless. I'll have to check with the CSS WG on this.::selection
anymore at this point pending a redefinition in a future spec (UI level 4?).