stream-charts
    Preparing search index...

    Function calculateOrdinalConstrainedZoomFor

    • Calculates the zoom for an ordinal axis.

      Parameters

      • transform: ZoomTransform

        The d3 zoom transformation information

      • x: number

        The x-position of the mouse when the scroll wheel or gesture is used

      • range: OrdinalAxisRange

        The current range for the axis being zoomed

      • constraint: [min: number, max: number]

        The minimum and maximum value the scaled range can have

      Returns ZoomResult<OrdinalAxisRange>

      A ZoomResult holding the updated range and the new zoom factor