import { FrameAnimationPropertiesType } from '../types/AnimationTypes'; import { EditorAPI, Id } from '../types/CommonTypes'; /** * The AnimationController is responsible for all communication regarding Animations. * Methods inside this controller can be called by `window.SDK.animation.{method-name}` */ export declare class AnimationController { #private; /** * @ignore */ constructor(children: EditorAPI); /** * This method returns all animations on current layout * @returns list of all animation on current layout */ getAllOnSelectedLayout: () => Promise>; /** * This method returns an animation for a given frame and layout IDs * @param id the id of a specific frame * @param layoutId the id of a specific layout * @returns animation properties for a given frame and layout */ getByFrameId: (id: Id, layoutId?: Id) => Promise>; /** * This method returns the animations for a given layout id * @param id the id of a specific layout * @returns animation properties for a given layout */ getByLayoutId: (id: Id) => Promise>; /** * This method sets the animation state for a certain Frame * @param animation animation properties * @returns updated animation properties */ setFrameAnimation: (animation: FrameAnimationPropertiesType) => Promise>; /** * This method triggers the animation to play * @returns */ play: () => Promise>; /** * This method triggers the animation to pause * @returns */ pause: () => Promise>; /** * This method sets the animation time to a certain time, expressed in milliseconds * @param timeInMS the time expressed in milliseconds * @returns */ setScrubberPosition: (timeInMS: number) => Promise>; /** * This method sets the total and maximum duration of the animation, expressed in milliseconds * @param timeInMS the time expressed in milliseconds * @returns */ setDuration: (timeInMS: number) => Promise>; /** * This method resets the animation to its initial state * @param id the id of a certain frame * @returns */ resetFrameAnimation: (id: Id) => Promise>; /** * This method resets the layout's animations and animation duration to its initial state * @returns */ reset: () => Promise>; }