import { type ConditionNode, type ComparisonOperandNode, type EqualityComparisonNode, type IfElseNode, type LiteralNode, type NumericComparisonNode, type NumericOperandNode, type RefNode, type RulePlaceholder, type Scalar } from "./types.js"; /** A non-recursive comparison operand: `value`, a literal node, or a scalar. */ export type Operand = ComparisonOperandNode | Scalar; export type NumericOperand = NumericOperandNode | number; /** True when a value is a `{$rule}` placeholder — the marker the builders emit. */ export declare function isRulePlaceholder(value: unknown): value is RulePlaceholder; /** Wrap a bare scalar as a literal node. */ export declare function literal(value: TValue): LiteralNode; /** * `value` — this data point's plotted numeric value: a bar's height, a point's * y, a slice's amount. It is what a colour rule compares against a constant. */ export declare const value: RefNode; export declare const equals: (left: Operand, right: Operand) => EqualityComparisonNode; export declare const isNot: (left: Operand, right: Operand) => EqualityComparisonNode; export declare const lessThan: (left: NumericOperand, right: NumericOperand) => NumericComparisonNode; export declare const greaterThan: (left: NumericOperand, right: NumericOperand) => NumericComparisonNode; export declare const lessOrEqual: (left: NumericOperand, right: NumericOperand) => NumericComparisonNode; export declare const greaterOrEqual: (left: NumericOperand, right: NumericOperand) => NumericComparisonNode; /** * A conditional colour: pick `ifTrue` when the condition holds, else `ifFalse`. * * when(lessThan(value, 100), '#E24B4A', '#378ADD') * // → '#E24B4A' when this point's value is under 100, '#378ADD' otherwise * * `ifFalse` is optional and defaults to `null` — for a colour, that means no * override (the chart's default is kept). Branches are colour literals only; * nested rules are intentionally unsupported in v1. */ export declare function when(condition: ConditionNode, ifTrue: string, ifFalse?: string | null): IfElseNode; /** * Target the colour channel — the v1 channel. Wrap a conditional value so the * renderer knows it resolves to a colour, and the panel knows what it edits. * * color(when(lessThan(value, 100), '#E24B4A', '#378ADD')) * // → red when this point's value is under 100, blue otherwise * * Takes the flat conditional value produced by `when(...)`. Returns a `{$rule}` * placeholder tagged `channel: 'color'`. */ export declare function color(rule: IfElseNode): RulePlaceholder; //# sourceMappingURL=builders.d.ts.map