[oXygen-user] Support for CSS pseudo-class :has()
Michael Boudreau
mboudreau at uchicago.edu
Wed Nov 2 10:42:18 CDT 2022
Thanks, Radu! I was following the example at https://w3c.github.io/csswg-drafts/selectors/#relational and assumed the leading “>” was required. Without it, my CSS rule works as I’d hoped.
--
Michael R. Boudreau
Electronic Publishing Technology Manager
The University of Chicago Press
1427 E. 60th Street
Chicago, IL 60637
www.journals.uchicago.edu
From: oXygen-user <oxygen-user-bounces at oxygenxml.com> on behalf of Oxygen XML Editor Support (Radu Coravu) <support at oxygenxml.com>
Date: Wednesday, November 2, 2022 at 12:08 AM
To: oxygen-user at oxygenxml.com <oxygen-user at oxygenxml.com>
Subject: Re: [oXygen-user] Support for CSS pseudo-class :has()
Hi Michael,
Oxygen supports the has() pseudo class selector and this is documented:
https://www.oxygenxml.com/doc/ug-editor/topics/has-selector.html<https://urldefense.com/v3/__https:/www.oxygenxml.com/doc/ug-editor/topics/has-selector.html__;!!BpyFHLRN4TMTrA!-nWvGX_BF8uytD1leIWH_9T8cjz8EWGFQ6bS1Z5lKO1oVD0dztiLGllNULnO0Ah3Xhi060oh8bDzCgf0MBEiYETV$>
>From what I tested in your case a selector like this should work in Oxygen:
entry:has(styled-content)
but if an extra ">" is prepended inside the has() pseudo class it stops working with Oxygen.
>From what I tested a web browser supports both has() value styles (with or without the > prefix).
I also looked in the CSS specification and I added an internal issue to also support in Oxygen the selector if it has a leading ">".
Regards,
Radu
Radu Coravu
Oxygen XML Editor
On 11/1/22 23:09, Michael Boudreau wrote:
Hello,
Is there any chance that a future version of Oxygen will support the CSS pseudo-class :has() ? I tried the following rule in a stylesheet
entry:has(> styled-content) {
background-color: #DDEEFF;
}
but the table cell (<entry>) with a child <styled-content> element didn’t get the expected light blue background.
--
Michael R. Boudreau
Electronic Publishing Technology Manager
The University of Chicago Press
1427 E. 60th Street
Chicago, IL 60637
www.journals.uchicago.edu<http://www.journals.uchicago.edu>
_______________________________________________
oXygen-user mailing list
oXygen-user at oxygenxml.com<mailto:oXygen-user at oxygenxml.com>
https://www.oxygenxml.com/mailman/listinfo/oxygen-user<https://urldefense.com/v3/__https:/www.oxygenxml.com/mailman/listinfo/oxygen-user__;!!BpyFHLRN4TMTrA!-nWvGX_BF8uytD1leIWH_9T8cjz8EWGFQ6bS1Z5lKO1oVD0dztiLGllNULnO0Ah3Xhi060oh8bDzCgf0MOysz46Q$>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.oxygenxml.com/pipermail/oxygen-user/attachments/20221102/534183b7/attachment.htm>
More information about the oXygen-user
mailing list