import { FunctionComponent, AriaAttributes, MouseEvent } from 'react'; import { AnimatedProps } from '@react-spring/web'; import { Box, CssMixBlendMode, Dimensions, MotionProps, PropertyAccessor, ValueFormat, ClosedCurveFactoryId, DotsItemSymbolComponent, SvgDefsAndFill } from '@nivo/core'; import { PartialTheme } from '@nivo/theming'; import { InheritedColorConfig, OrdinalColorScaleConfig } from '@nivo/colors'; import { LegendProps } from '@nivo/legends'; import { ScaleLinear } from 'd3-scale'; export interface RadarDataProps> { data: readonly D[]; keys: readonly string[]; indexBy: PropertyAccessor; } export interface GridLabelProps { id: string; anchor: 'start' | 'middle' | 'end'; angle: number; x: number; y: number; animated: AnimatedProps<{ transform: string; }>; } export type GridLabelComponent = FunctionComponent; export type PointData = { index: string; key: string; value: number; formattedValue: string; color: string; }; export interface PointProps { key: string; label: string | number | undefined; data: PointData; style: { fill: string; stroke: string; x: number; y: number; }; } export interface RadarSliceTooltipDatum { color: string; id: string; value: number; formattedValue: string; } export interface RadarSliceTooltipProps { index: string | number; data: readonly RadarSliceTooltipDatum[]; } export type RadarSliceTooltipComponent = FunctionComponent; export interface RadarCustomLayerProps> { data: readonly D[]; keys: readonly string[]; indices: readonly string[] | readonly number[]; colorByKey: RadarColorMapping; centerX: number; centerY: number; radiusScale: ScaleLinear; angleStep: number; } export type RadarCustomLayer> = FunctionComponent>; export type RadarLayerId = 'grid' | 'layers' | 'slices' | 'dots' | 'legends'; export type RadarColorMapping = Record; export interface RadarCommonProps> { maxValue: number | 'auto'; valueFormat: ValueFormat; rotation: number; layers: readonly (RadarLayerId | RadarCustomLayer)[]; margin: Box; curve: ClosedCurveFactoryId; gridLevels: number; gridShape: 'circular' | 'linear'; gridLabel: GridLabelComponent; gridLabelOffset: number; enableDots: boolean; dotSymbol: DotsItemSymbolComponent; dotSize: number; dotColor: InheritedColorConfig; dotBorderWidth: number; dotBorderColor: InheritedColorConfig; enableDotLabel: boolean; dotLabel: PropertyAccessor; dotLabelFormat: ValueFormat; dotLabelYOffset: number; theme: PartialTheme; colors: OrdinalColorScaleConfig<{ key: string; index: number; }>; fillOpacity: number; blendMode: CssMixBlendMode; borderWidth: number; borderColor: InheritedColorConfig<{ key: string; color: string; }>; isInteractive: boolean; sliceTooltip: RadarSliceTooltipComponent; renderWrapper: boolean; legends: readonly LegendProps[]; role: string; ariaLabel: AriaAttributes['aria-label']; ariaLabelledBy: AriaAttributes['aria-labelledby']; ariaDescribedBy: AriaAttributes['aria-describedby']; } export interface RadarSvgFillMatcherDatum> { color: string; data: RadarDataProps['data']; key: string; } export type RadarSvgProps> = Partial> & RadarDataProps & Dimensions & MotionProps & SvgDefsAndFill> & RadarHandlers; export type BoundLegendProps = Required> & Omit; export type MouseEventHandler = (datum: RawDatum, event: MouseEvent) => void; export type RadarHandlers = { onClick?: MouseEventHandler; }; //# sourceMappingURL=types.d.ts.map