epubcheck icon indicating copy to clipboard operation
epubcheck copied to clipboard

epubcheck does not accept a CSS `:is` pseudo-class

Open iherman opened this issue 3 years ago • 0 comments

Consider the following content file:

<html xmlns="http://www.w3.org/1999/xhtml" xmlns:epub="http://www.idpf.org/2007/ops" xml:lang="en">
  <head>
    <title>CSS test for :is</title>
    <style>
      :is(h1,h2,h3,h4,h5,h6,a) abbr{border:none}
    </style>
  </head>
  <body>
    <p>This is a possible epubcheck bug...</p>
  </body>
</html>

the epubcheck response is as follows:

Validating using EPUB version 3.3 rules. ERROR(CSS-008): css-bug.epub/OPS/content_001.xhtml(5,13): An error occurred while parsing the CSS: Token "," not allowed here.

I believe the CSS :is(...) syntax is correct and epubcheck should accept it.

I have also created a small epub file encapsulating this content file, see https://www.dropbox.com/s/d3gwhyg9agjtazx/css-bug.epub?dl=0

iherman avatar Dec 17 '21 05:12 iherman