@ansible/react-json-chart-builder
Version:
A chart builder component in react, which uses JSON for schema.
12 lines (11 loc) • 705 B
TypeScript
import { ChartAxisFormatFunction, ChartDataSerie, PaddingProps, PaddingPropsOptional } from '../types';
export declare const snakeToSentence: (str: string) => string;
export declare const turncateAt: (str: string, length: number) => string;
export declare const wrapAt: (str: string, length: number) => string;
export declare const axisFormatPreprocess: ({ wrapText, turncateAtNumber, fnc }: {
wrapText: boolean;
turncateAtNumber: number;
fnc: ChartAxisFormatFunction;
}) => (n: string | number) => string;
export declare const getBarWidthFromData: (data: ChartDataSerie[], width: number) => number;
export declare const paddingNumberToObject: (padding: PaddingPropsOptional) => PaddingProps;