import { Moment } from 'moment-timezone'; import { ChartDataset } from 'chart.js'; export interface TimedFormattedDatapoint { x: Moment; y: number | Object | null; } export interface TimedRawData { [key: string]: string | number; } export interface TimeRangedLineGraphProps { label?: string; rawData: TimedRawData[]; rawDataKey?: string; // should be present if rawData value type is Object; startDate: string; endDate: string; title: string; yAxisPropertyKey: string; xAxisPropertyKey: string; defaultLineChartDataset?: ChartDataset<'line'>; legend?: string; defaultLineChartPlugins?: ChartDataset<'line'>; // eslint-disable-next-line @typescript-eslint/no-explicit-any renderTooltipHeader?: (tooltipEl: any, title: string) => void; renderTooltipBody?: ( // eslint-disable-next-line @typescript-eslint/no-explicit-any tooltipEl: any, data: Array<{ [key: string]: string | number }> ) => void; renderEmptyState?: () => void; tooltipTitlePropertyKey?: string; tooltipMinWidth?: string; chartName: string; timezone?: string; }