sphinx-comments
sphinx-comments copied to clipboard
[FIX] Support section elements as well as div.section
Investigating https://github.com/executablebooks/jupyter-book/issues/1762#issuecomment-1532896199 it seems that this module needs to be updated to support the use of <section> elements (which have superseded <div class="section"> elements).
This PR updates sphinx-comments to support both ways of working. I also noticed that (on Chrome at least) querySelectorAll returns [] when there are not matches, not null, so I've modified the script to cope there and exit cleanly rather than throw an error.
(Sorry, didn't see https://github.com/executablebooks/.github/blob/d375020a952a579cca1c1e642b248a36da606b8b/CONTRIBUTING.md#commit-messages until opening this PR so the commit message is not properly formatted.)
Thanks for submitting your first pull request! You are awesome! :hugs:
If you haven't done so already, check out EBP's Code of Conduct and our Contributing Guide, as this will greatly help the review process.
Welcome to the EBP community! :tada:
Just noticed this largely duplicates #18 (except this supports both old and new forms).
The CI fails but it appears to be a problem with the Actions:
Error: Version 3.6 with arch x64 not found