import { type ReactNode } from 'react'; import type { ConvertibleUnit, FormatOptions, Unit } from '@dynatrace-sdk/units'; import { MeterBarChartData, type MeterBarChartThresholdIndicatorProps, type MeterBarChartTooltipPayload } from './meter-bar-chart.js'; import { LegendItem } from '../../../core/components/legend/categorical/types/legend.js'; import type { ColorRuleProps } from '../../../core/types/color-rule.js'; import type { Formatter } from '../../../core/types/formatter.js'; import type { MeterBarToolbarInternalProps } from '../../shared/types/meter-bar-toolbar.js'; import type { MeterBarSize, SlotWithAutoDefault } from '../../shared/types/meter-bars.js'; export type MeterBarChartThresholdIndicatorPropsInternal = Required> & Pick; export interface ThresholdMetadata { data: MeterBarChartThresholdIndicatorPropsInternal[]; legend?: boolean; } export interface MeterBarChartDataProviderData { value: number | MeterBarChartData; valueAccessor: string; color: string; name?: string; thresholdIndicators?: number[]; legendItems: LegendItem[]; } export interface TooltipConfigData { hidden?: boolean; name?: string; template?: (payload: MeterBarChartTooltipPayload) => ReactNode; } export interface MeterBarChartInternalConfig { thresholds: ThresholdMetadata; thresholdsIndicators: ThresholdMetadata; size: MeterBarSize; min: number; max: number; tooltip: TooltipConfigData; loading: boolean; labelSlot: ReactNode; valueSlot?: SlotWithAutoDefault; minSlot?: SlotWithAutoDefault; maxSlot?: SlotWithAutoDefault; formatter: Formatter | FormatOptions; unit?: string | Unit; colorRules: ColorRuleProps[]; toolbar: MeterBarToolbarInternalProps; }