@lunit/oui
Version:
Lunit Oncology UI components
17 lines (16 loc) • 664 B
TypeScript
export declare function parseStringValToNumber(val: string): number;
export declare function clampNumericalPercentage(value: number): number;
export declare function clampBarLabelPosition(value: number): number;
/**
* @description normalizeSegmentWidths is a function that normalizes the width of the segments in the analysis bar.
* @param segments - The segments to normalize.
* @param isCutoff - Whether the analysis bar is a cutoff.
* @returns The normalized segments.
*/
export declare function normalizeSegmentWidths(segments: {
color: 'jet' | string;
width: number;
}[], isCutoff?: boolean): {
color: 'jet' | string;
width: number;
}[];