import { r as SummaryStrings } from "./summary-D8UEQXYr.js"; import { n as Format } from "./format-Dq02z5ZL.js"; import { CSSProperties, ReactNode } from "react"; //#region src/core/strings-net-flow.d.ts type NetFlowStrings = Pick; //#endregion //#region src/charts/net-flow/geometry.d.ts interface NetFlowPeriod { in: number; out: number; } type NetFlowMode = "area" | "bars"; interface FlowBar { x: number; y: number; width: number; height: number; } interface FlowPoint { x: number; in: number; out: number; net: number; /** viewBox y of the inflow top, the net line, and the outflow bottom. */ inTopY: number; netY: number; outBotY: number; } interface NetFlowGeometry { zeroY: number; /** Plot box top/bottom in viewBox units — the padded frame the inflow and * outflow surfaces are clamped into. Prop-derived, never data-derived. */ y0: number; y1: number; inArea: { d: string; }; outArea: { d: string; }; netLine: { d: string; }; /** Per-period positions (x in the active mode) — overlays + nearest-x. */ points: FlowPoint[]; /** mode="bars" (also forced for a single period). */ inBars: FlowBar[]; outBars: FlowBar[]; mode: NetFlowMode; last: { x: number; y: number; net: number; in: number; out: number; } | null; /** in > out count (for the summary). */ netPositive: number; n: number; /** All periods zero → baseline only. */ degenerate: boolean; labelX: number; labelY: number; totalWidth: number; /** Signed value domain `[-maxMag, maxMag]` — annotations frame (Threshold/ * TargetZone y), not the plotted magnitude range. */ domain: readonly [number, number]; /** Data value → viewBox y for annotations. */ yFor: (v: number) => number; } //#endregion //#region src/charts/net-flow/index.d.ts /** Signed value string — direction lives in the text, not the color. */ declare function signedNet(net: number, fmt: (n: number) => string): string; /** * The `label="last"` net readout, or `null` when the box cannot seat it. * * Exported because the interactive entry reserves the SAME right gutter in its * own geometry pass. It used to decide that on `label` alone, so in a box too * short to seat the text the static dropped the label (viewBox = `width`) while * the client still reserved the gutter (`totalWidth = width + gutter`) — the * pointer map ran over a wider box than the one on screen and the crosshair and * readout chip drifted off the cursor. */ declare function netFlowLabel(geo: NetFlowGeometry, height: number, label: "last" | "none", fmt: (n: number) => string, min?: number | undefined): { font: number; text: string; } | null; declare function netFlowSummary(geo: NetFlowGeometry, fmt: (n: number) => string, strings: NetFlowStrings): string; interface NetFlowProps { /** One period: inflow + outflow magnitudes (both ≥ 0). */ data: readonly NetFlowPeriod[]; /** Mirrored areas (default) or discrete mirrored columns for few periods. */ mode?: NetFlowMode | undefined; /** The net line (in − out). Default `true` — areas alone answer "how much". */ net?: boolean | undefined; /** Which direction is the good polarity — `"down"` for debt-paydown contexts. */ positive?: "up" | "down" | undefined; /** `"last"` states the signed net in a right gutter. */ label?: "last" | "none" | undefined; /** Symmetric magnitude bound (domain[1]); defaults to the data max. */ domain?: readonly [number, number] | undefined; width?: number | undefined; height?: number | undefined; format?: Format | undefined; locale?: string | string[] | undefined; strings?: NetFlowStrings | undefined; /** Minimum in-chart label size, in viewBox units. Geometry sizes labels from * the mark and floors them at 7; this raises that floor and moves the * reserved gutter with it. A label the box cannot seat at the raised floor * drops rather than shrinking back under it. */ labelSize?: number | undefined; title?: string | undefined; summary?: string | false | undefined; id?: string | undefined; className?: string | undefined; style?: CSSProperties | undefined; children?: ReactNode | undefined; } declare function NetFlow(props: NetFlowProps): ReactNode; //#endregion export { signedNet as a, netFlowSummary as i, NetFlowProps as n, NetFlowStrings as o, netFlowLabel as r, NetFlow as t };