/** * Population Helper Functions * * Extracted from the monolithic populate() function to improve * maintainability, testability, and clarity. * * Pure types and utilities live in populate-core.ts (no afterRead imports). * This module re-exports them and adds helpers that depend on afterRead. */ import type { RevealRequest, TypedFallbackLocale } from '../types/index.js'; export type { PopulateRelationshipField, RelationInfo, UpdateLocation } from './populate-core.js'; export { extractRelationInfo, shouldPopulateRelationship, updateDocumentWithPopulatedValue, } from './populate-core.js'; /** * Load a related document using the dataLoader * * Returns the populated document or undefined if not found. */ export declare function loadRelatedDocument(args: { id: unknown; relationName: string; relatedCollection: unknown; currentDepth: number; depth: number; draft: boolean; fallbackLocale: TypedFallbackLocale; locale: string | null; overrideAccess: boolean; populateArg: unknown; showHiddenFields: boolean; req: { dataLoader?: { load?: (key: string) => Promise; }; }; }): Promise; /** * Recursively populate nested relationships on a document * * Applies afterRead hook to populate relationships within the document. */ export declare function applyNestedPopulation(args: { doc: unknown; collectionConfig: { slug?: string; fields?: unknown[]; defaultPopulate?: unknown; }; currentDepth: number; depth: number; draft: boolean; fallbackLocale: TypedFallbackLocale; locale: string | null; overrideAccess: boolean; populateArg: unknown; showHiddenFields: boolean; req: RevealRequest; }): Promise; //# sourceMappingURL=populate-helpers.d.ts.map