Components Interactions Examples Tutorials API FAQ
Options
Menu

Hierarchy

Index

Constructors

constructor

Properties

Protected _componentAttachedTo

_componentAttachedTo: Component

Private _dragInteraction

_dragInteraction: any

Private _maxDomainExtents

_maxDomainExtents: any

Private _maxDomainValues

_maxDomainValues: any

Private _minDomainExtents

_minDomainExtents: any

Private _minDomainValues

_minDomainValues: any

Private _mouseDispatcher

_mouseDispatcher: any

Private _panEndCallbacks

_panEndCallbacks: any

Private _touchCancelCallback

_touchCancelCallback: any

Private _touchDispatcher

_touchDispatcher: any

Private _touchEndCallback

_touchEndCallback: any

Private _touchIds

_touchIds: any

Private _touchMoveCallback

_touchMoveCallback: any

Private _touchStartCallback

_touchStartCallback: any

Private _wheelCallback

_wheelCallback: any

Private _xScales

_xScales: any

Private _yScales

_yScales: any

Private _zoomEndCallbacks

_zoomEndCallbacks: any

Static Private _PIXELS_PER_LINE

_PIXELS_PER_LINE: any

The number of pixels occupied in a line.

Methods

Protected _anchor

Private _constrainZoomExtents

  • _constrainZoomExtents(scale: any, zoomAmount: any): any

Private _constrainZoomValues

  • _constrainZoomValues(scale: any, zoomAmount: any, centerPoint: any): any
  • Parameters

    • scale: any
    • zoomAmount: any
    • centerPoint: any

    Returns any

Private _constrainedTranslation

  • _constrainedTranslation(scale: any, translation: any): any
  • Returns a new translation value that respects domain min/max value constraints.

    Parameters

    • scale: any
    • translation: any

    Returns any

Private _constrainedZoom

  • _constrainedZoom(scale: any, zoomAmount: any, centerPoint: any): any
  • Parameters

    • scale: any
    • zoomAmount: any
    • centerPoint: any

    Returns any

Private _getZoomCenterForTarget

  • _getZoomCenterForTarget(value: any, zoom: any, target: any): any
  • Returns the center value to be used with zoomAt that will produce the target value given the same value and zoom arguments. Algebra brought to you by Wolfram Alpha.

    Parameters

    • value: any
    • zoom: any
    • target: any

    Returns any

Private _handlePinch

  • _handlePinch(ids: any, idToPoint: any, e: any): any

Private _handleTouchEnd

  • _handleTouchEnd(ids: any, idToPoint: any, e: any): any

Private _handleTouchStart

  • _handleTouchStart(ids: any, idToPoint: any, e: any): any

Private _handleWheelEvent

  • _handleWheelEvent(p: any, e: any): any

Protected _isInsideComponent

  • _isInsideComponent(p: Point): boolean
  • Checks whether a Component-coordinate-space Point is inside the Component.

    Parameters

    • p: Point

      A Point in Compoennt-space coordinates.

    Returns boolean

    Whether or not the point is inside the Component.

Private _nonLinearScaleWithExtents

  • _nonLinearScaleWithExtents(scale: any): any

Private _setupDragInteraction

  • _setupDragInteraction(): any

Protected _translateToComponentSpace

Protected _unanchor

  • _unanchor(): void

addXScale

addYScale

attachTo

  • Attaches this Interaction to a Component. If the Interaction was already attached to a Component, it first detaches itself from the old Component.

    Parameters

detachFrom

enabled

  • enabled(): boolean
  • enabled(enabled: boolean)

maxDomainExtent

  • Gets the maximum domain extent for the scale, specifying the maximum allowable amount between the ends of the domain.

    Note that extents will mainly work on scales that work linearly like Linear Scale and Time Scale

    Parameters

    Returns number

    The maximum numerical domain extent for the scale.

  • Sets the maximum domain extent for the scale, specifying the maximum allowable amount between the ends of the domain.

    For example, if the scale's transformation domain is [500, 600] and the maxDomainExtent is set to 50, then the user will only be able to zoom out to see an interval like [500, 550] or [520, 570].

    Note that extents will mainly work on scales that work linearly like Linear Scale and Time Scale

    Parameters

maxDomainValue

  • Gets the maximum domain value for the scale, constraining the pan/zoom interaction to a maximum value in the domain.

    Note that this differs from minDomainExtent/maxDomainExtent, in that those methods provide constraints such as showing at least 2 but no more than 5 values at a time.

    By contrast, minDomainValue/maxDomainValue set a boundary beyond which the user cannot pan/zoom.

    Parameters

    Returns number

    The maximum domain value for the scale.

  • Sets the maximum domain value for the scale, constraining the pan/zoom interaction to a maximum value in the domain.

    Note that this differs from minDomainExtent/maxDomainExtent, in that those methods provide constraints such as showing at least 2 but no more than 5 values at a time.

    By contrast, minDomainValue/maxDomainValue set a boundary beyond which the user cannot pan/zoom.

    Parameters

minDomainExtent

  • Gets the minimum domain extent for the scale, specifying the minimum allowable amount between the ends of the domain.

    Note that extents will mainly work on scales that work linearly like Linear Scale and Time Scale

    Parameters

    Returns number

    The minimum numerical domain extent for the scale.

  • Sets the minimum domain extent for the scale, specifying the minimum allowable amount between the ends of the domain.

    Note that extents will mainly work on scales that work linearly like Linear Scale and Time Scale

    Parameters

    • scale: TransformableScale

      The scale to query

    • minDomainExtent: number

      The minimum numerical domain extent for the scale.

minDomainValue

  • Gets the minimum domain value for the scale, constraining the pan/zoom interaction to a minimum value in the domain.

    Note that this differs from minDomainExtent/maxDomainExtent, in that those methods provide constraints such as showing at least 2 but no more than 5 values at a time.

    By contrast, minDomainValue/maxDomainValue set a boundary beyond which the user cannot pan/zoom.

    Parameters

    Returns number

    The minimum domain value for the scale.

  • Sets the minimum domain value for the scale, constraining the pan/zoom interaction to a minimum value in the domain.

    Note that this differs from minDomainExtent/maxDomainExtent, in that those methods provide constraints such as showing at least 2 but no more than 5 values at a time.

    By contrast, minDomainValue/maxDomainValue set a boundary beyond which the user cannot pan/zoom.

    Parameters

offPanEnd

offZoomEnd

onPanEnd

onZoomEnd

pan

  • pan(translateAmount: Point): void

removeXScale

removeYScale

setMinMaxDomainValuesTo

  • Uses the current domain of the scale to apply a minimum and maximum domain value for that scale.

    This constrains the pan/zoom interaction to show no more than the domain of the scale.

    Parameters

    Returns void

xScales

yScales

zoom

  • zoom(zoomAmount: number, centerValue?: Point): void
  • Zooms the chart by a specified amount around a specific point

    Parameters

    • zoomAmount: number
    • Optional centerValue: Point

    Returns void

Static Private _pointDistance

  • _pointDistance(point1: any, point2: any): any

Static centerPoint

  • centerPoint(point1: Point, point2: Point): object

Generated using TypeDoc