For AI agents: the complete documentation index is available at /next/llms.txt, the full documentation bundle is available at /next/llms-full.txt, and this page is available as Markdown at /next/api/lynx-api/event/animation-event.md.
Lynx
  • English
  • AnimationEvent

    Represents the animation event object, inherited from CustomEvent, used to describe the state changes of the animation in its life cycle, such as start, end, etc.

    The event object contains information such as the type and name of the animation.

    Instance property

    detail

    detail: {
      animation_type: string,
      animation_name: string,
      new_animator: boolean,
    }

    Represents some basic information of the animation to which the event belongs.

    • animation-type: The type of the animation. If it is a keyframe animation, this value is keyframe-animation; if it is a transition animation, this value is transition-animation.
    • animation-name: The name of the animation. If it is a keyframe animation, it is the name of @keyframes in CSS; if it is a transition animation, it is the name of transition-property in CSS.
    • new_animator: The default value is true.

    AnimationEvent type

    Info

    During the animation execution process, if the animation node is uninstalled and destroyed, the animationcancel and transitioncancel events on the node will not be triggered.

    animationstart

    Indicates the start of keyframe animation playback.

    animationend

    Indicates the end of keyframe animation playback.

    animationcancel

    Indicates that the keyframe animation playback is canceled.

    animationiteration

    Indicates the number of keyframe animation playback iterations.

    transitionstart

    Indicates the start of the transition animation playback.

    transitionend

    Indicates the end of the transition animation playback.

    transitioncancel

    Indicates that the transition animation playback is canceled.

    Compatibility

    LCD tables only load in the browser

    Except as otherwise noted, this work is licensed under a Creative Commons Attribution 4.0 International License, and code samples are licensed under the Apache License 2.0.