UNPKG

@mui/x-charts

Version:

The community edition of MUI X Charts components.

25 lines 901 B
import type * as React from 'react'; export interface SVGCSSProperties extends Omit<React.CSSProperties, 'dominantBaseline'> { dominantBaseline?: React.SVGAttributes<SVGTextElement>['dominantBaseline']; } export declare function clearStringMeasurementCache(): void; /** * Converts a style object into a string to be used as a cache key * @param style React style object * @returns CSS styling string */ export declare function getStyleString(style: SVGCSSProperties): string; /** * * @param text The string to estimate * @param style The style applied * @returns width and height of the text */ export declare const getStringSize: (text: string | number, style?: SVGCSSProperties) => { width: number; height: number; }; export declare function batchMeasureStrings(texts: Iterable<string | number>, style?: SVGCSSProperties): Map<string | number, { width: number; height: number; }>;