import { ShapeRendering, TextAnchor } from "./utils_svg_types"; export type ChartGaugeSegment = { /** * @description the starting value of a gauge segment */ from: number; /** * @escription the ending value of a gauge segment */ to: number; color?: string; }; export type ChartGaugeDataset = { segments: ChartGaugeSegment[]; value: number; }; export type ChartGaugeOptions = { /** * @option the thickness of the gauge arcs * @default 58 */ arcThickness?: number; /** * @option the background color applied to the chart * @default "#FFFFFF" */ backgroundColor?: string; /** * @option pass any strings separated by a space to generate class names. Example: "my-class1 my-class2" */ className?: string; /** * @option the text color of data labels * @default "#000000" */ dataLabelsColor?: string; /** * @option the font size of data labels * @default 12 */ dataLabelsFontSize?: number; /** * @option the data labels offset from the arcs * @default 1.4 * @example 1.2 will push data labels closer to the arcs */ dataLabelsOffset?: number; /** * @option font family for all text elements * @default "inherit" */ fontFamily?: string; /** * @option the id of the svg. Defaults to a random uid */ id?: string; paddingBottom?: number; paddingLeft?: number; paddingRight?: number; paddingTop?: number; /** * @option the color of the pointer base circle * @default "#1A1A1A" */ pointerBaseColor?: string; /** * @option the radius of the pointer base circle * @default 5 */ pointerBaseRadius?: number; /** * @option the border color of the pointer base circle * @default "#FFFFFF" */ pointerBaseStroke?: string; /** * @option the stroke width of the pointer base circle border * @default 1 */ pointerBaseStrokeWidth?: number; /** * @option the color of the pointer * @default "#2A2A2A" */ pointerColor?: string; /** * @option the size of the pointer. 0.9 will make it bigger. Ok this is not logical but whatever * @default 1 */ pointerSize?: number; /** * @option the thickness of the pointer * @default 5 */ pointerWidth?: number; /** * @option standard svg rendering * @default "auto" */ "shape-rendering"?: ShapeRendering; /** * @option show or hide segment data labels * @default true */ showDataLabels?: boolean; /** * @option show or hide the gaueg value * @default true */ showValue?: boolean; /** * @option the text content of the title element * @default "" */ title?: string; /** * @option the text color of the title element * @default "#000000" */ titleColor?: string; /** * @option the font size of the title element * @default 18 */ titleFontSize?: number; /** * @option the font weight of the title element * @default "bold" */ titleFontWeight?: "bold" | "normal"; /** * @option the horizontal position (text-anchor) of the title element * @default "middle" */ titlePosition?: TextAnchor; /** * @option the color of the gauge value * @default "#000000" */ valueColor?: string; /** * @option the font size of the gauge value * @default 20 */ valueFontSize?: number; /** * @option the font weight of the gauge value * @default "normal" */ valueFontWeight?: "bold" | "normal"; /** * @option the rounding of the gauge value * @default 0 */ valueRounding?: number; /** * @option the viewBox dimensions of the chart's svg * @default "0 0 450 300" */ viewBox?: string; }; export declare function chartGauge({ dataset, options, parent }: { dataset: ChartGaugeDataset; options?: ChartGaugeOptions; parent?: HTMLElement; }): { chart: SVGElement; refresh: (rootNode: HTMLElement) => any | undefined; updateData: (ds: ChartGaugeDataset) => any | undefined; arcs: any; dimensions: { centerX: number; centerY: number; }; }; declare const utils_chart_gauge: { chartGauge: typeof chartGauge; }; export default utils_chart_gauge;