import { RankingOrder } from '../types'; /** One ranked category, or the "Other" row that adds up everything past the limit. */ export interface RankedRow { id: string; label: string; value: number | null; other?: boolean; } export declare const OTHER_ID = "\0other"; export declare const sharePercent: Intl.NumberFormat; /** Rank rows, then fold everything past `limit` into one "Other" row. */ export declare function rankRows(data: readonly Row[], category: string, value: string, sort: RankingOrder, limit: number | undefined, otherLabel: string): RankedRow[]; /** * The total of observed values and whether shares of it mean anything: they don't when values * mix gains and losses, or when nothing positive was observed. */ export declare function shareTotals(rows: readonly RankedRow[]): { observed: number; total: number; shareable: boolean; };