This property allows you to discover customizable colors or update them within a processed icon.
Example (list all supported colors by the icon):
{ ...iconElement.playerInstance.colors }
Example (update a single color):
iconElement.playerInstance.colors.primary = '#ff0000';
Example (update multiple colors at once):
iconElement.playerInstance.colors = { primary: 'red', secondary: 'blue' };
Example (reset all colors to default):
iconElement.playerInstance.colors = null;
The 'direction' property lets you influence the direction of the animation playback, whether it plays forward (1) or in reverse (-1).
Readonly durationThe 'duration' property provides the value of the animation length in seconds.
Access the player frame. You can manually control the animation playback by changing this frame.
Readonly framesThe 'frames' property provides the value of the animation length in terms of the number of frames.
Readonly isThe player is currently playing the animation.
Readonly isThe player is ready.
This property allows you to control whether the player should loop the animation.
Access to read or modify multiple properties at once. Resets to default any properties that are not provided.
Properties to assign.
This property allows you to control the speed of the icon animation.
This property allows you to control the state (motion type) of the icon. States enable switching between multiple animations built into a single icon file.
Readonly statesThe 'states' property provides a list of supported states by a processed icon.
The 'stroke' property gives you the value of the icon's stroke width.
Start listening for an event.
Event name.
Event callback.
Start listening for an event.
Stop listening for an event.
Event name.
Optional callback: PlayerEventCallbackEvent callback.
Interface for an animation player. Provides a simple API to control animations and customize icon properties dynamically.