icon icon indicating copy to clipboard operation
icon copied to clipboard

Icon is not animating correctly

Open lorenzofiamingo opened this issue 1 year ago • 2 comments

Environment

Version

v3.0.0-alpha.12

Reproduction

Jusy load the animated icon anywhere in a page.

For example:

<Icon name="line-md:loading-twotone-loop" />

Description

The issue occurs both when I run the app in development mode and when I build it for production. I tested it on Safari (Mac and iPhone) and Chrome (iPhone only). On the first page load, the animation works fine, but when I reload the page, the animation stops. However, when the component where it is used updates, the icon state changes (still without animation).

Here I placed some icons randomly in the pages to show the problem and when it occurs:

https://github.com/user-attachments/assets/ca9772d8-61bb-47da-9b9e-38cbb8d5796c

).

lorenzofiamingo avatar Feb 21 '25 13:02 lorenzofiamingo

Add mode="svg" to fix it.

When animated icon is rendered as background or mask image, animation timer starts the first time icon is rendered and is never reset. I've reported that as bug to Chromium devs a while ago, they closed issue as working as intended, so they aren't fixing it.

cyberalien avatar Feb 21 '25 14:02 cyberalien

@cyberalien Thank you very much for your response. This should be mentioned in the documentation if it isn’t already.

lorenzofiamingo avatar Feb 23 '25 14:02 lorenzofiamingo