import { ReactNode } from 'react'; export interface ISideLabel { text: string; href?: string; } export interface IChartDataPoint { metric: number | string | Date; title?: ReactNode | ((metric: number | string | Date) => ReactNode); value: number; originalPayload?: T; color?: string; emptyMetric?: boolean; active?: boolean; checked?: boolean; aggregatedRecords?: T[]; sideLabel?: ISideLabel; } export type IChartData = IChartDataPoint[]; export interface IStackedChartDataPoint { name: string; title?: ReactNode | ((metric: number | string | Date) => ReactNode); group?: string; data: IChartDataPoint[]; color?: string; opacity?: number; emptyName?: boolean; checked?: boolean; } export type IStackedChartData = IStackedChartDataPoint[]; export type IGroupedStackedChartData = [string, IStackedChartData][]; export interface ICounterChartData { metric: string; value: number; previousValue?: number; } export interface ISpeedometerChartData { metric: string; value: number; previousValue: number; } export type TTableChartData = Record[]; export type StackedChartTooltipPointsData = (Pick & IChartDataPoint & { childName?: string; })[];