igniteui-react-charts
Version:
Ignite UI React charting components for building rich data visualizations using TypeScript APIs.
568 lines (562 loc) • 24.8 kB
TypeScript
import { IgrSeries } from "./igr-series";
import { IgrCalloutPlacementPositionsCollection } from "./igr-callout-placement-positions-collection";
import { HighlightedValueLabelMode } from "igniteui-react-core";
import { AutoCalloutVisibilityMode } from "./AutoCalloutVisibilityMode";
import { CalloutCollisionMode } from "igniteui-react-core";
import { IgrCalloutStyleUpdatingEventArgs } from "./igr-callout-style-updating-event-args";
import { IgrCalloutRenderStyleUpdatingEventArgs } from "./igr-callout-render-style-updating-event-args";
import { IgrCalloutContentUpdatingEventArgs } from "./igr-callout-content-updating-event-args";
import { IgrCalloutLabelUpdatingEventArgs } from "./igr-callout-label-updating-event-args";
import { IgrCalloutSeriesSelectingEventArgs } from "./igr-callout-series-selecting-event-args";
import { IgrAnnotationLayer, IIgrAnnotationLayerProps } from "./igr-annotation-layer";
import { CalloutLayer } from "./CalloutLayer";
/**
* Represents an annotation layer that displays crosshair lines that cross through the closest value of the target series under the cursor.
*/
export declare class IgrCalloutLayer extends IgrAnnotationLayer<IIgrCalloutLayerProps> {
protected createImplementation(): CalloutLayer;
/**
* @hidden
*/
get i(): CalloutLayer;
constructor(props: IIgrCalloutLayerProps);
/**
* Gets whether the series is an callout annotation layer.
*/
get isAnnotationCalloutLayer(): boolean;
/**
* Gets or sets whether or not callouts expand axis buffer for extra space for their render around data points.
*/
get calloutExpandsAxisBufferEnabled(): boolean;
set calloutExpandsAxisBufferEnabled(v: boolean);
/**
* Gets or sets whether or not callouts expand axis buffer only when callouts are visible in the chart.
* This property is not used when the CalloutExpandsAxisBufferEnabled property is false or AutoCalloutVisibilityMode is not Dedicated.
*/
get calloutExpandsAxisBufferOnlyWhenVisible(): boolean;
set calloutExpandsAxisBufferOnlyWhenVisible(v: boolean);
/**
* Gets or sets whether or not recalculate callouts expand axis buffer on rendering frame.
* This property is not used when the CalloutExpandsAxisBufferEnabled property is false or AutoCalloutVisibilityMode is not Dedicated.
*/
get calloutExpandsAxisBufferOnInitialVisibility(): boolean;
set calloutExpandsAxisBufferOnInitialVisibility(v: boolean);
/**
* Gets or sets whether or not suspend refresh of callouts while they shift from hidden to visible
*/
get calloutSuspendedWhenShiftingToVisible(): boolean;
set calloutSuspendedWhenShiftingToVisible(v: boolean);
/**
* Gets or sets the minimum vertical axis buffer for positioning callouts.
* This property does not take precedence over the CalloutExpandsAxisBufferMaxHeight property.
*/
get calloutExpandsAxisBufferMinHeight(): number;
set calloutExpandsAxisBufferMinHeight(v: number);
/**
* Gets or sets the maximum vertical axis buffer for positioning callouts.
* This property takes precedence over the CalloutExpandsAxisBufferMinHeight property.
*/
get calloutExpandsAxisBufferMaxHeight(): number;
set calloutExpandsAxisBufferMaxHeight(v: number);
/**
* Gets or sets the minimum horizontal axis buffer for positioning callouts.
* This property does not take precedence over the CalloutExpandsAxisBufferMaxWidth property.
*/
get calloutExpandsAxisBufferMinWidth(): number;
set calloutExpandsAxisBufferMinWidth(v: number);
/**
* Gets or sets the maximum horizontal axis buffer for positioning callouts.
* This property takes precedence over the CalloutExpandsAxisBufferMinWidth property.
*/
get calloutExpandsAxisBufferMaxWidth(): number;
set calloutExpandsAxisBufferMaxWidth(v: number);
/**
* Gets or sets the label mapping property for the callouts.
*/
get labelMemberPath(): string;
set labelMemberPath(v: string);
/**
* Gets or sets the label mapping property for the callouts.
*/
get xMemberPath(): string;
set xMemberPath(v: string);
/**
* Gets or sets the label mapping property for the callouts.
*/
get yMemberPath(): string;
set yMemberPath(v: string);
/**
* Gets or sets the key mapping property for the callouts.
*/
get keyMemberPath(): string;
set keyMemberPath(v: string);
/**
* Gets or sets whether to allow the callouts to be variable distances from the target points, for supporting collision modes.
*/
get isCalloutOffsettingEnabled(): boolean;
set isCalloutOffsettingEnabled(v: boolean);
/**
* Gets or sets the label format string to use for the label.
*/
get labelFormat(): string;
set labelFormat(v: string);
/**
* Gets or sets the format specifiers to use with the LabelFormat string.
*/
get labelFormatSpecifiers(): any[];
set labelFormatSpecifiers(v: any[]);
/**
* Gets or sets the content mapping property for the callouts.
*/
get contentMemberPath(): string;
set contentMemberPath(v: string);
/**
* Gets or sets the name of the series series to target this annotation to. If null, this annotation targets all series simultaneously.
*/
get targetSeriesName(): string;
set targetSeriesName(v: string);
/**
* Gets or sets the series to target this annotation to. If null, this annotation targets all series simultaneously.
*/
get targetSeries(): IgrSeries;
set targetSeries(v: IgrSeries);
/**
* Gets or sets a channel name to identify other callout layers within the chart to share collision information with.
*/
get collisionChannel(): string;
set collisionChannel(v: string);
private _allowedPositions;
/**
* Gets or sets the allowed positions that the callout layer is allowed to use.
*/
get allowedPositions(): IgrCalloutPlacementPositionsCollection;
set allowedPositions(v: IgrCalloutPlacementPositionsCollection);
/**
* Gets or sets how to select the final value to annotate.
*/
get isAutoCalloutBehaviorEnabled(): boolean;
set isAutoCalloutBehaviorEnabled(v: boolean);
/**
* Gets or sets whether to use values, rather than labels for auto callout labels.
*/
get useInterpolatedValueForAutoCalloutLabels(): boolean;
set useInterpolatedValueForAutoCalloutLabels(v: boolean);
/**
* Gets or sets whether to the series color as the outline of the callout.
*/
get useSeriesColorForOutline(): boolean;
set useSeriesColorForOutline(v: boolean);
/**
* Gets or sets whether to the label color is automatically decided between a light and dark option for contrast.
*/
get useAutoContrastingLabelColors(): boolean;
set useAutoContrastingLabelColors(v: boolean);
/**
* Gets or sets whether to the series color as the outline of the callout.
*/
get useItemColorForFill(): boolean;
set useItemColorForFill(v: boolean);
/**
* Gets or sets whether to the series item color as the outline of the callout.
*/
get useItemColorForOutline(): boolean;
set useItemColorForOutline(v: boolean);
/**
* Gets or sets whether to use values, rather than labels for auto callout labels.
*/
get useValueForAutoCalloutLabels(): boolean;
set useValueForAutoCalloutLabels(v: boolean);
/**
* Gets or sets whether to use values, rather than labels for auto callout labels.
*/
get highlightedValueLabelMode(): HighlightedValueLabelMode;
set highlightedValueLabelMode(v: HighlightedValueLabelMode);
/**
* Gets or sets the rules for when the callouts should be visible.
*/
get autoCalloutVisibilityMode(): AutoCalloutVisibilityMode;
set autoCalloutVisibilityMode(v: AutoCalloutVisibilityMode);
/**
* Gets or sets the corner radius to use for the callout borders.
*/
get calloutCornerRadius(): number;
set calloutCornerRadius(v: number);
/**
* Gets or sets whether to allow for custom callout styles.
*/
get isCustomCalloutStyleEnabled(): boolean;
set isCustomCalloutStyleEnabled(v: boolean);
/**
* Gets or sets whether to allow for custom callout styles.
*/
get isCustomCalloutRenderStyleEnabled(): boolean;
set isCustomCalloutRenderStyleEnabled(v: boolean);
/**
* Gets or sets the precision to use when values are used for the auto callout labels.
*/
get autoCalloutLabelPrecision(): number;
set autoCalloutLabelPrecision(v: number);
/**
* Gets or sets the color to use for the callout text. Leave unset for an automatic value.
*/
get calloutTextColor(): string;
set calloutTextColor(v: string);
/**
* Gets or sets the light color to use for the callout text. Leave unset for an automatic value.
*/
get calloutLightTextColor(): string;
set calloutLightTextColor(v: string);
/**
* Gets or sets the dark color to use for the callout text. Leave unset for an automatic value.
*/
get calloutDarkTextColor(): string;
set calloutDarkTextColor(v: string);
/**
* Gets or sets the brush that specifies how the backgrounds for the callouts of the layer are painted. Leave unset for an automatic value.
*/
get calloutBackground(): string;
set calloutBackground(v: string);
/**
* Gets or sets whether the callouts that collide with the boundary should be truncated.
*/
get shouldTruncateOnBoundaryCollisions(): boolean;
set shouldTruncateOnBoundaryCollisions(v: boolean);
/**
* Gets or sets the precision to use displaying values for interpolated crosshair positions.
*/
get calloutInterpolatedValuePrecision(): number;
set calloutInterpolatedValuePrecision(v: number);
/**
* Gets or sets the brush that specifies how the outlines for the callouts of the layer are painted.
*/
get calloutOutline(): string;
set calloutOutline(v: string);
/**
* Gets or sets the brush that specifies how the leader lines for the callouts of the layer are painted.
*/
get calloutLeaderBrush(): string;
set calloutLeaderBrush(v: string);
/**
* Gets or sets the left padding to use withing the callout. Leaving this NaN will use an automatic value related to the axis label margins.
*/
get calloutPaddingLeft(): number;
set calloutPaddingLeft(v: number);
/**
* Gets or sets the top padding to use within the callout. Leaving this NaN will use an automatic value related to the axis label margins.
*/
get calloutPaddingTop(): number;
set calloutPaddingTop(v: number);
/**
* Gets or sets the right padding to use within the callout. Leaving this NaN will use an automatic value related to the axis label margins.
*/
get calloutPaddingRight(): number;
set calloutPaddingRight(v: number);
/**
* Gets or sets the bottom padding to use within the callout. Leaving this NaN will use an automatic value related to the axis label margins.
*/
get calloutPaddingBottom(): number;
set calloutPaddingBottom(v: number);
/**
* Gets or sets the strategy to use for avoiding collisions between the callouts in this layer. Leave unset for an automatic value.
*/
get calloutCollisionMode(): CalloutCollisionMode;
set calloutCollisionMode(v: CalloutCollisionMode);
/**
* Gets or sets the padding to add to the callout positioning. Leave unset for an automatic value.
*/
get calloutPositionPadding(): number;
set calloutPositionPadding(v: number);
/**
* Gets or sets the stroke thickness for the callout backing. Leave unset for an automatic value.
*/
get calloutStrokeThickness(): number;
set calloutStrokeThickness(v: number);
/**
* Gets or sets the stroke thickness for the axis annotation backing. Leave unset for an automatic value.
*/
get textStyle(): string;
set textStyle(v: string);
findByName(name: string): any;
protected _styling(container: any, component: any, parent?: any): void;
getItemValue(item: any, memberPathName: string): any;
/**
* Gets the value of a requested member path from the series.
* @param memberPathName * The property name of a valid member path for the series
*/
getMemberPathValue(memberPathName: string): string;
/**
* Invalidates content of callout layer
*/
invalidateCalloutContent(): void;
/**
* Resets actual visiable range margin
*/
recalculateAxisRangeBuffer(): void;
/**
* Refresh axis buffer and callouts rendering
*/
refreshAxisBufferAndCalloutPositions(): void;
/**
* Force the callout labels to reevaluate their positions.
*/
refreshLabelPositions(): void;
private _calloutStyleUpdating;
private _calloutStyleUpdating_wrapped;
/**
* Event raised when updating style of callout layer
*/
get calloutStyleUpdating(): (s: IgrCalloutLayer, e: IgrCalloutStyleUpdatingEventArgs) => void;
set calloutStyleUpdating(ev: (s: IgrCalloutLayer, e: IgrCalloutStyleUpdatingEventArgs) => void);
private _calloutRenderStyleUpdating;
private _calloutRenderStyleUpdating_wrapped;
/**
* Event raised when updating style of callout layer
*/
get calloutRenderStyleUpdating(): (s: IgrCalloutLayer, e: IgrCalloutRenderStyleUpdatingEventArgs) => void;
set calloutRenderStyleUpdating(ev: (s: IgrCalloutLayer, e: IgrCalloutRenderStyleUpdatingEventArgs) => void);
private _calloutContentUpdating;
private _calloutContentUpdating_wrapped;
/**
* Raised to allow you to decide on the content for an automatically created callout.
*/
get calloutContentUpdating(): (s: IgrCalloutLayer, e: IgrCalloutContentUpdatingEventArgs) => void;
set calloutContentUpdating(ev: (s: IgrCalloutLayer, e: IgrCalloutContentUpdatingEventArgs) => void);
private _calloutLabelUpdating;
private _calloutLabelUpdating_wrapped;
/**
* Raised to allow you to decide on the label for an automatically created callout.
*/
get calloutLabelUpdating(): (s: IgrCalloutLayer, e: IgrCalloutLabelUpdatingEventArgs) => void;
set calloutLabelUpdating(ev: (s: IgrCalloutLayer, e: IgrCalloutLabelUpdatingEventArgs) => void);
private _calloutSeriesSelecting;
private _calloutSeriesSelecting_wrapped;
/**
* Raised to allow you to select a target series for a data bound callout.
*/
get calloutSeriesSelecting(): (s: IgrCalloutLayer, e: IgrCalloutSeriesSelectingEventArgs) => void;
set calloutSeriesSelecting(ev: (s: IgrCalloutLayer, e: IgrCalloutSeriesSelectingEventArgs) => void);
}
export interface IIgrCalloutLayerProps extends IIgrAnnotationLayerProps {
/**
* Gets or sets whether or not callouts expand axis buffer for extra space for their render around data points.
*/
calloutExpandsAxisBufferEnabled?: boolean | string;
/**
* Gets or sets whether or not callouts expand axis buffer only when callouts are visible in the chart.
* This property is not used when the CalloutExpandsAxisBufferEnabled property is false or AutoCalloutVisibilityMode is not Dedicated.
*/
calloutExpandsAxisBufferOnlyWhenVisible?: boolean | string;
/**
* Gets or sets whether or not recalculate callouts expand axis buffer on rendering frame.
* This property is not used when the CalloutExpandsAxisBufferEnabled property is false or AutoCalloutVisibilityMode is not Dedicated.
*/
calloutExpandsAxisBufferOnInitialVisibility?: boolean | string;
/**
* Gets or sets whether or not suspend refresh of callouts while they shift from hidden to visible
*/
calloutSuspendedWhenShiftingToVisible?: boolean | string;
/**
* Gets or sets the minimum vertical axis buffer for positioning callouts.
* This property does not take precedence over the CalloutExpandsAxisBufferMaxHeight property.
*/
calloutExpandsAxisBufferMinHeight?: number | string;
/**
* Gets or sets the maximum vertical axis buffer for positioning callouts.
* This property takes precedence over the CalloutExpandsAxisBufferMinHeight property.
*/
calloutExpandsAxisBufferMaxHeight?: number | string;
/**
* Gets or sets the minimum horizontal axis buffer for positioning callouts.
* This property does not take precedence over the CalloutExpandsAxisBufferMaxWidth property.
*/
calloutExpandsAxisBufferMinWidth?: number | string;
/**
* Gets or sets the maximum horizontal axis buffer for positioning callouts.
* This property takes precedence over the CalloutExpandsAxisBufferMinWidth property.
*/
calloutExpandsAxisBufferMaxWidth?: number | string;
/**
* Gets or sets the label mapping property for the callouts.
*/
labelMemberPath?: string;
/**
* Gets or sets the label mapping property for the callouts.
*/
xMemberPath?: string;
/**
* Gets or sets the label mapping property for the callouts.
*/
yMemberPath?: string;
/**
* Gets or sets the key mapping property for the callouts.
*/
keyMemberPath?: string;
/**
* Gets or sets whether to allow the callouts to be variable distances from the target points, for supporting collision modes.
*/
isCalloutOffsettingEnabled?: boolean | string;
/**
* Gets or sets the label format string to use for the label.
*/
labelFormat?: string;
/**
* Gets or sets the format specifiers to use with the LabelFormat string.
*/
labelFormatSpecifiers?: any[];
/**
* Gets or sets the content mapping property for the callouts.
*/
contentMemberPath?: string;
/**
* Gets or sets the name of the series series to target this annotation to. If null, this annotation targets all series simultaneously.
*/
targetSeriesName?: string;
/**
* Gets or sets the series to target this annotation to. If null, this annotation targets all series simultaneously.
*/
targetSeries?: IgrSeries;
/**
* Gets or sets a channel name to identify other callout layers within the chart to share collision information with.
*/
collisionChannel?: string;
/**
* Gets or sets the allowed positions that the callout layer is allowed to use.
*/
allowedPositions?: IgrCalloutPlacementPositionsCollection | string;
/**
* Gets or sets how to select the final value to annotate.
*/
isAutoCalloutBehaviorEnabled?: boolean | string;
/**
* Gets or sets whether to use values, rather than labels for auto callout labels.
*/
useInterpolatedValueForAutoCalloutLabels?: boolean | string;
/**
* Gets or sets whether to the series color as the outline of the callout.
*/
useSeriesColorForOutline?: boolean | string;
/**
* Gets or sets whether to the label color is automatically decided between a light and dark option for contrast.
*/
useAutoContrastingLabelColors?: boolean | string;
/**
* Gets or sets whether to the series color as the outline of the callout.
*/
useItemColorForFill?: boolean | string;
/**
* Gets or sets whether to the series item color as the outline of the callout.
*/
useItemColorForOutline?: boolean | string;
/**
* Gets or sets whether to use values, rather than labels for auto callout labels.
*/
useValueForAutoCalloutLabels?: boolean | string;
/**
* Gets or sets whether to use values, rather than labels for auto callout labels.
*/
highlightedValueLabelMode?: HighlightedValueLabelMode | string;
/**
* Gets or sets the rules for when the callouts should be visible.
*/
autoCalloutVisibilityMode?: AutoCalloutVisibilityMode | string;
/**
* Gets or sets the corner radius to use for the callout borders.
*/
calloutCornerRadius?: number | string;
/**
* Gets or sets whether to allow for custom callout styles.
*/
isCustomCalloutStyleEnabled?: boolean | string;
/**
* Gets or sets whether to allow for custom callout styles.
*/
isCustomCalloutRenderStyleEnabled?: boolean | string;
/**
* Gets or sets the precision to use when values are used for the auto callout labels.
*/
autoCalloutLabelPrecision?: number | string;
/**
* Gets or sets the color to use for the callout text. Leave unset for an automatic value.
*/
calloutTextColor?: string;
/**
* Gets or sets the light color to use for the callout text. Leave unset for an automatic value.
*/
calloutLightTextColor?: string;
/**
* Gets or sets the dark color to use for the callout text. Leave unset for an automatic value.
*/
calloutDarkTextColor?: string;
/**
* Gets or sets the brush that specifies how the backgrounds for the callouts of the layer are painted. Leave unset for an automatic value.
*/
calloutBackground?: string;
/**
* Gets or sets whether the callouts that collide with the boundary should be truncated.
*/
shouldTruncateOnBoundaryCollisions?: boolean | string;
/**
* Gets or sets the precision to use displaying values for interpolated crosshair positions.
*/
calloutInterpolatedValuePrecision?: number | string;
/**
* Gets or sets the brush that specifies how the outlines for the callouts of the layer are painted.
*/
calloutOutline?: string;
/**
* Gets or sets the brush that specifies how the leader lines for the callouts of the layer are painted.
*/
calloutLeaderBrush?: string;
/**
* Gets or sets the left padding to use withing the callout. Leaving this NaN will use an automatic value related to the axis label margins.
*/
calloutPaddingLeft?: number | string;
/**
* Gets or sets the top padding to use within the callout. Leaving this NaN will use an automatic value related to the axis label margins.
*/
calloutPaddingTop?: number | string;
/**
* Gets or sets the right padding to use within the callout. Leaving this NaN will use an automatic value related to the axis label margins.
*/
calloutPaddingRight?: number | string;
/**
* Gets or sets the bottom padding to use within the callout. Leaving this NaN will use an automatic value related to the axis label margins.
*/
calloutPaddingBottom?: number | string;
/**
* Gets or sets the strategy to use for avoiding collisions between the callouts in this layer. Leave unset for an automatic value.
*/
calloutCollisionMode?: CalloutCollisionMode | string;
/**
* Gets or sets the padding to add to the callout positioning. Leave unset for an automatic value.
*/
calloutPositionPadding?: number | string;
/**
* Gets or sets the stroke thickness for the callout backing. Leave unset for an automatic value.
*/
calloutStrokeThickness?: number | string;
/**
* Gets or sets the stroke thickness for the axis annotation backing. Leave unset for an automatic value.
*/
textStyle?: string;
/**
* Event raised when updating style of callout layer
*/
calloutStyleUpdating?: (s: IgrCalloutLayer, e: IgrCalloutStyleUpdatingEventArgs) => void;
/**
* Event raised when updating style of callout layer
*/
calloutRenderStyleUpdating?: (s: IgrCalloutLayer, e: IgrCalloutRenderStyleUpdatingEventArgs) => void;
/**
* Raised to allow you to decide on the content for an automatically created callout.
*/
calloutContentUpdating?: (s: IgrCalloutLayer, e: IgrCalloutContentUpdatingEventArgs) => void;
/**
* Raised to allow you to decide on the label for an automatically created callout.
*/
calloutLabelUpdating?: (s: IgrCalloutLayer, e: IgrCalloutLabelUpdatingEventArgs) => void;
/**
* Raised to allow you to select a target series for a data bound callout.
*/
calloutSeriesSelecting?: (s: IgrCalloutLayer, e: IgrCalloutSeriesSelectingEventArgs) => void;
}