ggrossetie / asciidoctor-web-pdf

Convert AsciiDoc documents to PDF using web technologies
https://asciidoctor.org
MIT License
455 stars 92 forks source link

Does not support certain CSS pseudo-classes and selectors (:nth() and :first) #707

Open blueray453 opened 1 month ago

blueray453 commented 1 month ago

The following code does not work.

@page clean {
    @bottom-right {
        content: none;
    }

    @bottom-left {
        content: none;
    }
}

@page :nth(1) {
    page: clean;
}

@page :first {
    page: clean;
}

Giving error.

An uncaught exception happened within the HTML page: Error: DOMException: Failed to execute 'querySelectorAll' on 'DocumentFragment': ':first' is not a valid selector.

An uncaught exception happened within the HTML page: Error: DOMException: Failed to execute 'querySelectorAll' on 'DocumentFragment': ':nth(1)' is not a valid selector.