Trait

io.scalajs.npm.angularjs.animate

Animate

Related Doc: package animate

Permalink

trait Animate extends Object

Animate Service - The $animate service exposes a series of DOM utility methods that provide support for animation hooks.

Annotations
@RawJSType() @native()
See also

https://docs.angularjs.org/api/ng/service/$animate

Linear Supertypes
Object, Any, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Animate
  2. Object
  3. Any
  4. AnyRef
  5. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. def addClass(element: Element, className: String, options: Object = js.native): Promise[Any]

    Permalink

    Triggers an addClass animation surrounding the addition of the provided CSS class(es).

    Triggers an addClass animation surrounding the addition of the provided CSS class(es). Upon execution, the addClass operation will only be handled after the next digest and it will not trigger an animation if element already contains the CSS class or if the class is removed at a later step. Note that class-based animations are treated differently compared to structural animations (like enter, move and leave) since the CSS classes may be added/removed at different points depending if CSS or JavaScript animations are used.

    element

    the element which the CSS classes will be applied to

    className

    the CSS class(es) that will be added (multiple classes are separated via spaces)

    options

    an optional collection of options/styles that will be applied to the element

    returns

    the animation callback promise

  5. def animate(element: Element, from: Object, to: Object, className: String, options: Object = js.native): Promise[Any]

    Permalink

    Performs an inline animation on the element which applies the provided to and from CSS styles to the element.

    Performs an inline animation on the element which applies the provided to and from CSS styles to the element. If any detected CSS transition, keyframe or JavaScript matches the provided className value then the animation will take on the provided styles. For example, if a transition animation is set for the given className then the provided from and to styles will be applied alongside the given transition. If a JavaScript animation is detected then the provided styles will be given in as function paramters into the animate method (or as apart of the options parameter).

    element

    the element which the CSS styles will be applied to

    from

    the from (starting) CSS styles that will be applied to the element and across the animation.

    to

    the to (destination) CSS styles that will be applied to the element and across the animation.

    className

    an optional CSS class that will be applied to the element for the duration of the animation. If this value is left as empty then a CSS class of ng-inline-animate will be applied to the element. (Note that if no animation is detected then this value will not be appplied to the element.)

    options

    an optional collection of options/styles that will be applied to the element

    returns

    the animation callback promise

  6. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  7. def cancel(animationPromise: Promise[Any]): Unit

    Permalink

    Cancels the provided animation.

    Cancels the provided animation.

    animationPromise

    The animation promise that is returned when an animation is started.

  8. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  9. def enabled(element: Element = js.native, enabled: Boolean = js.native): Boolean

    Permalink

    Used to get and set whether animations are enabled or not on the entire application or on an element and its children.

    Used to get and set whether animations are enabled or not on the entire application or on an element and its children.

    element

    the element that will be considered for checking/setting the enabled state

    enabled

    whether or not the animations will be enabled for the element

    returns

    whether or not animations are enabled

  10. def enter(element: Element, parent: Element, after: Element = js.native, options: Object = js.native): Promise[Any]

    Permalink

    Inserts the element into the DOM either after the after element (if provided) or as the first child within the parent element and then triggers an animation.

    Inserts the element into the DOM either after the after element (if provided) or as the first child within the parent element and then triggers an animation. A promise is returned that will be resolved during the next digest once the animation has completed.

    element

    the element which will be inserted into the DOM

    parent

    the parent element which will append the element as a child (so long as the after element is not present)

    after

    the sibling element after which the element will be appended

    options

    an optional collection of options/styles that will be applied to the element

    returns

    the animation callback promise

  11. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  12. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  13. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  14. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  15. def hasOwnProperty(v: String): Boolean

    Permalink
    Definition Classes
    Object
  16. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  17. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  18. def isPrototypeOf(v: Object): Boolean

    Permalink
    Definition Classes
    Object
  19. def leave(element: Element, options: Object = js.native): Promise[Any]

    Permalink

    Triggers an animation and then removes the element from the DOM.

    Triggers an animation and then removes the element from the DOM. When the function is called a promise is returned that will be resolved during the next digest once the animation has completed.

    element

    the element which will be removed from the DOM

    options

    an optional collection of options/styles that will be applied to the element

    returns

    the animation callback promise

  20. def move(element: Element, parent: Element, after: Element, options: Object = js.native): Promise[Any]

    Permalink

    Inserts (moves) the element into its new position in the DOM either after the after element (if provided) or as the first child within the parent element and then triggers an animation.

    Inserts (moves) the element into its new position in the DOM either after the after element (if provided) or as the first child within the parent element and then triggers an animation. A promise is returned that will be resolved during the next digest once the animation has completed.

    element

    the element which will be moved into the new DOM position

    parent

    the parent element which will append the element as a child (so long as the after element is not present)

    after

    the sibling element after which the element will be appended

    options

    an optional collection of options/styles that will be applied to the element

    returns

    the animation callback promise

  21. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  22. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  23. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  24. def off(event: Event, container: Any = js.native, callback: Function = js.native): Unit

    Permalink

    Deregisters an event listener based on the event which has been associated with the provided element.

    Deregisters an event listener based on the event which has been associated with the provided element. This method can be used in three different ways depending on the arguments:

    event

    the animation event (e.g. enter, leave, move, addClass, removeClass, etc...)

    container

    the container element the event listener was placed on

    callback

    the container element the event listener was placed on

  25. def on(event: Event, container: Any, callback: Function): Unit

    Permalink

    Sets up an event listener to fire whenever the animation event (enter, leave, move, etc...) has fired on the given element or among any of its children.

    Sets up an event listener to fire whenever the animation event (enter, leave, move, etc...) has fired on the given element or among any of its children. Once the listener is fired, the provided callback is fired with the following params:

    event

    the animation event that will be captured (e.g. enter, leave, move, addClass, removeClass, etc...)

    container

    the container element that will capture each of the animation events that are fired on itself as well as among its children

    callback

    the callback function that will be fired when the listener is triggered The arguments present in the callback function are:

    • element - The captured DOM element that the animation was fired on.
    • phase - The phase of the animation. The two possible phases are start (when the animation starts) and close (when it ends).
  26. def pin(element: Element, parentElement: Element): Unit

    Permalink

    Associates the provided element with a host parent element to allow the element to be animated even if it exists outside of the DOM structure of the Angular application.

    Associates the provided element with a host parent element to allow the element to be animated even if it exists outside of the DOM structure of the Angular application. By doing so, any animation triggered via $animate can be issued on the element despite being outside the realm of the application or within another application. Say for example if the application was bootstrapped on an element that is somewhere inside of the <body> tag, but we wanted to allow for an element to be situated as a direct child of document.body, then this can be achieved by pinning the element via $animate.pin(element). Keep in mind that calling $animate.pin(element, parentElement) will not actually insert into the DOM anywhere; it will just create the association.

    element

    the external element that will be pinned

    parentElement

    the host parent element that will be associated with the external element

  27. def propertyIsEnumerable(v: String): Boolean

    Permalink
    Definition Classes
    Object
  28. def removeClass(element: Element, className: String, options: Object = js.native): Promise[Any]

    Permalink

    Triggers a removeClass animation surrounding the removal of the provided CSS class(es).

    Triggers a removeClass animation surrounding the removal of the provided CSS class(es). Upon execution, the removeClass operation will only be handled after the next digest and it will not trigger an animation if element does not contain the CSS class or if the class is added at a later step. Note that class-based animations are treated differently compared to structural animations (like enter, move and leave) since the CSS classes may be added/removed at different points depending if CSS or JavaScript animations are used.

    element

    the element which the CSS classes will be applied to

    className

    the CSS class(es) that will be removed (multiple classes are separated via spaces)

    options

    an optional collection of options/styles that will be applied to the element

    returns

    the animation callback promise

  29. def setClass(element: Element, add: String, remove: String, options: Object = js.native): Promise[Any]

    Permalink

    Performs both the addition and removal of a CSS classes on an element and (during the process) triggers an animation surrounding the class addition/removal.

    Performs both the addition and removal of a CSS classes on an element and (during the process) triggers an animation surrounding the class addition/removal. Much like $animate.addClass and $animate.removeClass, setClass will only evaluate the classes being added/removed once a digest has passed. Note that class-based animations are treated differently compared to structural animations (like enter, move and leave) since the CSS classes may be added/removed at different points depending if CSS or JavaScript animations are used.

    element

    the element which the CSS classes will be applied to

    add

    the CSS class(es) that will be added (multiple classes are separated via spaces)

    remove

    the CSS class(es) that will be removed (multiple classes are separated via spaces)

    options

    an optional collection of options/styles that will be applied to the element

    returns

    the animation callback promise

  30. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  31. def toLocaleString(): String

    Permalink
    Definition Classes
    Object
  32. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  33. def valueOf(): Any

    Permalink
    Definition Classes
    Object
  34. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  35. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  36. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Object

Inherited from Any

Inherited from AnyRef

Inherited from Any

Ungrouped