import type { ContextCallbackParams, DatumItemCallbackParams, HighlightState, SelectionState, SeriesCallbackParams, Styler } from '../../chart/callbackOptions'; import type { AgDropShadowOptions } from '../../chart/dropShadowOptions'; import type { AgChartLabelOptions } from '../../chart/labelOptions'; import type { AgSeriesTooltip } from '../../chart/tooltipOptions'; import type { ContextDefault, CssColor, DatumDefault, DatumKey, Opacity, PixelSize } from '../../chart/types'; import type { AgInterpolationType } from '../interpolationOptions'; import type { AgSeriesMarkerOptions, AgSeriesMarkerStyle } from '../markerOptions'; import type { AgBaseCartesianThemeableOptions, AgBaseSeriesOptions, AgHighlightStyleOptions, AgMultiSeriesHighlightOptions, AgSeriesSegmentation, AgSeriesShapeSegmentOptions } from '../seriesOptions'; import type { AgCartesianSeriesTooltipRendererParams } from './cartesianSeriesTooltipOptions'; import type { AgBaseCartesianSeriesAxisOptions, FillOptions, LineDashOptions, StrokeOptions } from './commonOptions'; export interface AgRangeAreaSeriesStylerParams extends SeriesCallbackParams, ContextCallbackParams, AgRangeAreaSeriesOptionsKeys, Required { } export interface AgRangeAreaSeriesLineStyle extends StrokeOptions, LineDashOptions { /** Styling for the markers used in the item. */ marker?: AgSeriesMarkerStyle; } export interface AgRangeAreaSeriesStyleItems { /** Configuration for the `yLowKey` line. */ low?: AgRangeAreaSeriesLineStyle; /** Configuration for the `yHighKey` line. */ high?: AgRangeAreaSeriesLineStyle; } export interface AgRangeAreaSeriesStyle extends FillOptions { /** Configuration used for the range area series low and high lines. */ item?: AgRangeAreaSeriesStyleItems; } export type AgRangeAreaSeriesItemType = 'low' | 'high'; export interface AgRangeAreaSeriesTooltipRendererParams extends Omit, 'xKey' | 'xName' | 'yKey' | 'yName'>, AgRangeAreaSeriesOptionsKeys, AgRangeAreaSeriesOptionsNames, Omit { /** The type of datum. This can be `high` or `low`. */ itemType: AgRangeAreaSeriesItemType; } export interface AgRangeAreaSeriesItemStylerParams extends AgRangeAreaSeriesOptionsKeys, DatumItemCallbackParams, ContextCallbackParams, Required { /** The type of datum. This can be `high` or `low`. */ itemType: AgRangeAreaSeriesItemType; } export interface AgRangeAreaSeriesLabelOptions extends AgChartLabelOptions { /** Where to render series labels relative to the area. */ placement?: AgRangeAreaSeriesLabelPlacement; /** Spacing in pixels between the label and the edge of the marker. */ spacing?: PixelSize; } export type AgRangeAreaSeriesLabelPlacement = 'inside' | 'outside'; export type AgRangeAreaSeriesLabelFormatterParams = AgRangeAreaSeriesOptionsKeys & AgRangeAreaSeriesOptionsNames; export interface AgRangeAreaMarker extends AgSeriesMarkerOptions, TContext> { /** Function used to return formatting for individual markers, based on the supplied information.*/ itemStyler?: Styler, AgSeriesMarkerStyle>; } export interface AgRangeAreaSeriesLineThemeableOptions extends StrokeOptions, LineDashOptions { /** Styling configuration for the markers used in the series. */ marker?: AgRangeAreaMarker; } export interface AgRangeAreaSeriesItemMarker extends Omit, 'itemStyler'> { } export interface AgRangeAreaSeriesItemLineThemeableOptions extends StrokeOptions, LineDashOptions { /** Styling configuration for the markers used in the series. */ marker?: AgRangeAreaSeriesItemMarker; } export interface AgRangeAreaSeriesItemThemeableOptions { /** Configuration for the `yLowKey` line. */ low?: AgRangeAreaSeriesItemLineThemeableOptions; /** Configuration for `yHighKey` line. */ high?: AgRangeAreaSeriesItemLineThemeableOptions; } export interface AgRangeAreaSeriesThemeableOptions extends FillOptions, AgBaseCartesianThemeableOptions { /** Configuration for the markers used in the series. */ marker?: AgRangeAreaMarker; /** The colour for the stroke. */ stroke?: CssColor; /** The width of the stroke in pixels. */ strokeWidth?: PixelSize; /** The opacity of the stroke colour. */ strokeOpacity?: Opacity; /** An array specifying the length in pixels of alternating dashes and gaps for the stroke. */ lineDash?: PixelSize[]; /** The initial offset of the dashed line in pixels. */ lineDashOffset?: PixelSize; /** Configuration used for distinct styling of the low and high lines. */ item?: AgRangeAreaSeriesItemThemeableOptions; /** Configuration for the line used in the series. */ interpolation?: AgInterpolationType; /** Configuration for the labels shown on top of data points. */ label?: AgRangeAreaSeriesLabelOptions, TContext>; /** Configuration for the shadow used behind the series items. */ shadow?: AgDropShadowOptions; /** Series-specific tooltip configuration. */ tooltip?: AgSeriesTooltip>; /** Set to `true` to connect across missing data points. */ connectMissingData?: boolean; /** Function used to return formatting for entire series, based on the given parameters.*/ styler?: Styler, AgRangeAreaSeriesStyle>; /** Configuration for highlighting when a series or legend item is hovered over. */ highlight?: AgMultiSeriesHighlightOptions; /** Configuration for styling series as separate segments. */ segmentation?: AgSeriesSegmentation; /** Style options for the fill of areas where the `yHigh` line is below the `yLow` line. */ invertedStyle?: AgRangeAreaSeriesInvertedStyle; } export type AgRangeAreaSeriesInvertedStyle = FillOptions & { enabled?: boolean; }; export interface AgRangeAreaSeriesOptionsKeys { /** The key to use to retrieve x-values from the data. */ xKey: DatumKey; /** The key to use to retrieve y-low-values from the data. */ yLowKey: DatumKey; /** The key to use to retrieve y-high-values from the data. */ yHighKey: DatumKey; } export interface AgRangeAreaSeriesOptionsNames { /** A human-readable description of the x-values. If supplied, this will be shown in the default tooltip and passed to the tooltip renderer as one of the parameters. */ xName?: string; /** A human-readable description of the y-low-values. If supplied, this will be shown in the default tooltip and passed to the tooltip renderer as one of the parameters. */ yLowName?: string; /** A human-readable description of the y-high-values. If supplied, this will be shown in the default tooltip and passed to the tooltip renderer as one of the parameters. */ yHighName?: string; /** A human-readable description of the y-values. If supplied, this will be shown in the default tooltip and passed to the tooltip renderer as one of the parameters. */ yName?: string; /** Human-readable description of the y-values. If supplied, matching items with the same value will be toggled together. */ legendItemName?: string; } export interface AgRangeAreaSeriesOptions extends Omit, 'highlight'>, AgBaseCartesianSeriesAxisOptions, AgRangeAreaSeriesOptionsKeys, AgRangeAreaSeriesOptionsNames, AgRangeAreaSeriesThemeableOptions { /** Configuration for the Range Area Series. */ type: 'range-area'; }