/** * Utility functions for handling optional props and conditional spreading */ /** * Creates an object with only the defined (non-undefined) properties * @param props - Object with potentially undefined values * @returns Object with only defined values */ export declare function filterDefinedProps>(props: T): Partial; /** * Creates an object with only the truthy properties * @param props - Object with potentially falsy values * @returns Object with only truthy values */ export declare function filterTruthyProps>(props: T): Partial; /** * Conditionally includes props based on conditions * @param conditions - Object mapping prop names to their conditions and values * @returns Object with conditionally included props */ export declare function conditionalProps>(conditions: Record): Partial; /** * More specific utility for the most common pattern in this codebase: * Include prop only if value is defined and not null */ export declare function includeIfDefined(key: string, value: T): Record | {}; /** * Include prop only if value is truthy */ export declare function includeIfTruthy(key: string, value: T): Record | {}; /** * Batch version for multiple props - most efficient for the timeline use case */ export interface PropCondition { key: string; value: T; condition?: 'defined' | 'truthy' | boolean; } export declare function buildProps(conditions: PropCondition[]): Record; /** * Simple object-based approach - most readable and maintainable */ export declare function pickDefined>(obj: T): Partial; export declare function pickTruthy>(obj: T): Partial; //# sourceMappingURL=propUtils.d.ts.map