':root' selector is not supported
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 4.1k
- Forks
- 348
- Avg merge
- 1d 14h
- Merged PRs (30d)
- 3
Description
resvg doesn't support the ':root' selector, so some images do not render properly. For example, ChatGPT icon (https://github.com/user-attachments/assets/46acf9a9-5c14-4457-a9eb-394c49ac385b / https://cdn.oaistatic.com/assets/favicon-l4nq08hd.svg) renders as a transparent image.
```svg
```
```
Warning (in simplecss::selector:318): ':root' is not supported. Selector skipped.
Warning (in simplecss:298): The @media rule is not supported. Skipped.
```
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the reported ChatGPT SVG and inspect the selector handling associated with the simplecss::selector warning. Check how :root rules are parsed and applied, then verify that the example renders with its root fill instead of becoming transparent and that the unsupported-selector warning is resolved.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- computer-graphics
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100