/** @jsxImportSource react */ import { BoundedObject, BoundedObjectConfig, BoundedObjectInstance } from "../svg/BoundedObject"; import { RenderingContext } from "../ui/RenderingContext"; import { Rect } from "../svg/util/Rect"; import { NumberProp, BooleanProp, StringProp } from "../ui/Prop"; import { Instance } from "../ui/Instance"; export interface RangeConfig extends BoundedObjectConfig { /** The `x1` value binding or expression. */ x1?: NumberProp; /** The `y1` value binding or expression. */ y1?: NumberProp; /** The `x2` value binding or expression. */ x2?: NumberProp; /** The `y2` value binding or expression. */ y2?: NumberProp; /** Index of a color from the standard palette of colors. 0-15. */ colorIndex?: NumberProp; /** Used to indicate if an item is active or not. Inactive items are shown only in the legend. */ active?: BooleanProp; /** Name of the item as it will appear in the legend. */ name?: StringProp; /** Name of the legend to be used. Default is `legend`. */ legend?: StringProp; /** Set to `true` to hide the range rectangle. */ invisible?: boolean; /** * Name of the horizontal axis. The value should match one of the horizontal axes set * in the `axes` configuration of the parent `Chart` component. Default value is `x`. */ xAxis?: string; /** * Name of the vertical axis. The value should match one of the vertical axes set * in the `axes` configuration if the parent `Chart` component. Default value is `y`. */ yAxis?: string; /** X size. */ xSize?: number; /** Y size. */ ySize?: number; /** X offset. */ xOffset?: number; /** Y offset. */ yOffset?: number; /** Set to `true` to make the range draggable along the X axis. */ draggableX?: boolean; /** Set to `true` to make the range draggable along the Y axis. */ draggableY?: boolean; /** Set to `true` to make the range draggable along the X and Y axis. */ draggable?: boolean; /** Constrain the range position to min/max values of the X axis during drag operations. */ constrainX?: boolean; /** Constrain the range position to min/max values of the Y axis during drag operations. */ constrainY?: boolean; /** When set to `true`, it is equivalent to setting `constrainX` and `constrainY` to true. */ constrain?: boolean; /** Action to perform on legend item click. Default is `auto`. */ legendAction?: string; /** Set to `true` to hide the range. */ hidden?: boolean; /** Click event handler. */ onClick?: (e: React.MouseEvent, instance: Instance) => void; } export interface RangeInstance extends BoundedObjectInstance { xAxis: any; yAxis: any; } export declare class Range extends BoundedObject { baseClass: string; xAxis: string; yAxis: string; xSize: number; ySize: number; xOffset: number; yOffset: number; legend: string; legendAction: string; invisible: boolean; hidden: boolean; draggableX: boolean; draggableY: boolean; constrainX: boolean; constrainY: boolean; onClick: RangeConfig["onClick"]; constructor(config: RangeConfig); declareData(...args: any[]): void; explore(context: RenderingContext, instance: RangeInstance): void; prepare(context: RenderingContext, instance: RangeInstance): void; onLegendClick(e: MouseEvent, instance: RangeInstance): void; calculateBounds(context: RenderingContext, instance: RangeInstance): Rect; render(context: RenderingContext, instance: RangeInstance, key: string): React.ReactNode; handleClick(e: React.MouseEvent, instance: RangeInstance): void; handleMouseDown(e: React.MouseEvent | React.TouchEvent, instance: RangeInstance): void; handleDragMove(e: MouseEvent | TouchEvent, instance: RangeInstance, captureData: any): void; } //# sourceMappingURL=Range.d.ts.map