export type SunburstValueMode = `leaf-sum` | `total` | `remainder`; export type SunburstLabelRotation = `auto` | `radial` | `tangential` | `horizontal`; export type SunburstSort = `descending` | `ascending` | `none`; export type SunburstLabelText = `label` | `value` | `percent` | `label+value` | `label+percent`; export type SunburstShape = `sunburst` | `icicle`; export interface SunburstNode> { id?: string | number; label?: string; value?: number; color?: string; children?: SunburstNode[]; metadata?: Metadata; } export interface SunburstNodeHandlerProps> extends Omit, `x0` | `x1` | `y0` | `y1` | `subtree_end` | `parent_idx`> { type: `node`; parent_id: string | number | null; } export interface PositionedArc> { node_idx: number; subtree_end: number; parent_idx: number | null; id: string | number; label?: string; value: number; color: string; depth: number; is_leaf: boolean; path: (string | number)[]; label_path: string[]; fraction: number; parent_fraction: number; is_other?: boolean; x0: number; x1: number; y0: number; y1: number; metadata?: Metadata; } export interface SunburstLayoutOptions { value_mode?: SunburstValueMode; sort?: SunburstSort; level_lighten?: number; min_fraction?: number; other_label?: string; } export interface SunburstLayoutResult> { arcs: PositionedArc[]; root: PositionedArc | null; max_depth: number; } export declare function compute_sunburst_layout>(data: SunburstNode | SunburstNode[], opts?: SunburstLayoutOptions): SunburstLayoutResult; export declare function sunburst_from_paths>(rows: readonly { path: readonly (string | number)[]; value: number; color?: string; metadata?: Metadata; }[]): SunburstNode[]; export declare function sunburst_from_labels_parents>(labels: readonly string[], parents: readonly (string | null | undefined)[], values?: readonly number[], opts?: { ids?: readonly (string | number)[]; colors?: readonly (string | undefined)[]; metadata?: readonly (Metadata | undefined)[]; }): SunburstNode[];