Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SVG animation support #247

Open
Heziode opened this issue Sep 29, 2020 · 5 comments
Open

SVG animation support #247

Heziode opened this issue Sep 29, 2020 · 5 comments
Assignees
Labels
blocked-upstream-dependency Upstream dependency needs to be updated enhancement New feature or request

Comments

@Heziode
Copy link

Heziode commented Sep 29, 2020

It seems that SVG that contains animation doesn't work.

Example: https://images.weserv.nl/?url=https://upload.wikimedia.org/wikipedia/commons/8/87/SVG_animation_using_CSS.svg

However, SVG without animation works.

@Heziode
Copy link
Author

Heziode commented Sep 29, 2020

@Heziode
Copy link
Author

Heziode commented Oct 5, 2020

@andrieslouw or @kleisauke any information about this issue ?

@kleisauke kleisauke self-assigned this Oct 5, 2020
@kleisauke kleisauke added the question Further information is requested label Oct 5, 2020
@kleisauke
Copy link
Member

kleisauke commented Oct 5, 2020

librsvg (the library we use to load SVG images) doesn't support CSS-based animations.

The second SVG image you posted does not contain a width and/or height attribute, nor does it define a viewBox attribute, so it will default to 1x1 pixel. You could explicitly set the &w= and/or &h= parameter to load these kind of images. For example:
https://images.weserv.nl/?url=https://upload.wikimedia.org/wikipedia/commons/3/31/Rainbow-gradient-fully-saturated.svg&w=250

@Heziode
Copy link
Author

Heziode commented Oct 5, 2020

Thank you for the quick answer.

So… for animation this can take years/decades/Inifinity to be supported 😂 because it seems that it is not planned by librsvg.

@kleisauke
Copy link
Member

This is being tracked upstream within issue https://gitlab.gnome.org/GNOME/librsvg/-/issues/307.

@kleisauke kleisauke added blocked-upstream-dependency Upstream dependency needs to be updated enhancement New feature or request and removed question Further information is requested labels Jan 10, 2021
@kleisauke kleisauke changed the title Animated SVG doensn't work SVG animation support Jan 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked-upstream-dependency Upstream dependency needs to be updated enhancement New feature or request
Development

No branches or pull requests

2 participants