Packages

c

org.scalajs.dom

IntersectionObserver

class IntersectionObserver extends Object

The IntersectionObserver interface of the Intersection Observer API provides a way to asynchronously observe changes in the intersection of a target element with an ancestor element or with a top-level document's viewport.

Annotations
@JSType() @native() @JSGlobal()
Linear Supertypes
Object, Any, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. IntersectionObserver
  2. Object
  3. Any
  4. AnyRef
  5. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new IntersectionObserver(callback: Function2[Array[IntersectionObserverEntry], IntersectionObserver, Unit], options: IntersectionObserverInit = js.native)

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  6. def disconnect(): Unit

    Stops the IntersectionObserver object from observing any target.

  7. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  8. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  9. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  10. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  11. def hasOwnProperty(v: String): Boolean
    Definition Classes
    Object
  12. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  13. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  14. def isPrototypeOf(v: Object): Boolean
    Definition Classes
    Object
  15. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  16. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  17. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  18. def observe(target: Element): Unit

    Tells the IntersectionObserver a target element to observe.

  19. def propertyIsEnumerable(v: String): Boolean
    Definition Classes
    Object
  20. def root: |[Document, Element]

    The Element or Document whose bounds are used as the bounding box when testing for intersection.

    The Element or Document whose bounds are used as the bounding box when testing for intersection. If no root value was passed to the constructor or its value is null, the top-level document's viewport is used.

  21. def rootMargin: String

    An offset rectangle applied to the root's bounding box when calculating intersections, effectively shrinking or growing the root for calculation purposes.

    An offset rectangle applied to the root's bounding box when calculating intersections, effectively shrinking or growing the root for calculation purposes. The value returned by this property may not be the same as the one specified when calling the constructor as it may be changed to match internal requirements. Each offset can be expressed in pixels (px) or as a percentage (%). The default is "0px 0px 0px 0px".

  22. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  23. def takeRecords(): Array[IntersectionObserverEntry]

    Returns an array of IntersectionObserverEntry objects for all observed targets.

  24. def thresholds: FrozenArray[Double]

    A list of thresholds, sorted in increasing numeric order, where each threshold is a ratio of intersection area to bounding box area of an observed target.

    A list of thresholds, sorted in increasing numeric order, where each threshold is a ratio of intersection area to bounding box area of an observed target. Notifications for a target are generated when any of the thresholds are crossed for that target. If no value was passed to the constructor, 0 is used.

  25. def toLocaleString(): String
    Definition Classes
    Object
  26. def toString(): String
    Definition Classes
    AnyRef → Any
  27. def unobserve(target: Element): Unit

    Tells the IntersectionObserver to stop observing a particular target element.

  28. def valueOf(): Any
    Definition Classes
    Object
  29. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  30. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  31. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()

Inherited from Object

Inherited from Any

Inherited from AnyRef

Inherited from Any

Ungrouped