import { AreaProps } from 'recharts'; import { BoxProps, ElementProps, Factory, MantineColor, StylesApiProps } from '@mantine/core'; import { AreaChartCurveType } from '../AreaChart'; export interface SparklineTrendColors { positive: MantineColor; negative: MantineColor; neutral?: MantineColor; } export type SparklineStylesNames = 'root'; export type SparklineCssVariables = { root: '--chart-color'; }; export interface SparklineProps extends BoxProps, StylesApiProps, ElementProps<'div'> { /** Data used to render the chart */ data: (number | null)[]; /** Key of `theme.colors` or any valid CSS color @default theme.primaryColor */ color?: MantineColor; /** Determines whether the chart fill should be a gradient @default true */ withGradient?: boolean; /** Controls fill opacity of the area @default 0.6 */ fillOpacity?: number; /** Type of the curve @default 'linear' */ curveType?: AreaChartCurveType; /** Area stroke width @default 2 */ strokeWidth?: number; /** If set, `color` prop is ignored and chart color is determined by the difference between first and last value. */ trendColors?: SparklineTrendColors; /** Determines whether null values should be connected with other values @default true */ connectNulls?: boolean; /** Props passed down to the underlying recharts `Area` component */ areaProps?: Omit, 'data' | 'dataKey' | 'ref'>; } export type SparklineFactory = Factory<{ props: SparklineProps; ref: HTMLDivElement; stylesNames: SparklineStylesNames; vars: SparklineCssVariables; }>; export declare const Sparkline: import("@mantine/core").MantineComponent<{ props: SparklineProps; ref: HTMLDivElement; stylesNames: SparklineStylesNames; vars: SparklineCssVariables; }>; export declare namespace Sparkline { type Props = SparklineProps; type StylesNames = SparklineStylesNames; type CssVariables = SparklineCssVariables; type Factory = SparklineFactory; }