/** * Resolver utilities for workflow modules * * Provides generic higher-order functions for resolving optional values * by prompting when missing or using fallback values. */ import { Effect } from "effect"; /** * Create a resolver that prompts when a value is missing. * * Returns a function that checks if a value is present: * - If present, wraps it in Effect.succeed * - If missing, calls the provided prompt function * * @example * ```ts * const resolveFormat = resolveWithPrompt(promptForOutputFormat) * const result = resolveFormat(undefined) // prompts user * const existing = resolveFormat("hex") // Effect.succeed("hex") * ``` */ export declare const resolveWithPrompt: (promptFn: () => Effect.Effect) => (value: T | undefined) => Effect.Effect; /** * Create a resolver that uses a fallback when a value is missing. * * Pure function (no prompting) - returns the value or fallback immediately. * * @example * ```ts * const resolvePattern = resolveWithFallback(defaultPattern) * const result = resolvePattern(undefined) // returns defaultPattern * const existing = resolvePattern("custom") // returns "custom" * ``` */ export declare const resolveWithFallback: (fallback: T) => (value: T | undefined) => T; //# sourceMappingURL=resolvers.d.ts.map