Description
The HasAnimation
property of the BaseStyles
class indicates whether there is an active CSS animation applied to the UI element. This property returns a boolean value, where true
signifies that an animation is currently active, and false
indicates that there is no active animation.
Usage
Use the HasAnimation
property to check if a CSS animation is currently running on a UI element. This can be useful for conditionally executing logic based on the presence of animations, such as delaying certain actions until animations are complete.
Example
// Example of checking if an element has an active animation
BaseStyles styles = new BaseStyles();
if (styles.HasAnimation)
{
// Perform actions when an animation is active
// For example, log or trigger additional UI updates
}