import { Simplify } from "../types/utils"; import { RequireAFakeParameterIfThereAreTypeMismatchErrors } from "../types/type-mismatch-error"; import { ResultItem } from "../types/result-types"; import { ExtractProjectionResult, ProjectionMap } from "../types/projection-types"; import { ConfigCreateNestedScope } from "../types/query-config"; declare module "../groq-builder" { interface GroqBuilderRoot extends Pick, "project"> { } interface GroqBuilderSubquery extends Pick, "project"> { } interface GroqBuilder { /** * Performs an "object projection", returning an object with the fields specified. * * @param projectionMap - The projection map is an object, mapping field names to projection values * @param __projectionMapTypeMismatchErrors - (internal; this is only used for reporting errors from the projection) */ project, ConfigCreateNestedScope>>, _TProjectionResult = ExtractProjectionResult, ConfigCreateNestedScope>, TProjectionMap>>(projectionMap: TProjectionMap | ((sub: GroqBuilderSubquery, ConfigCreateNestedScope>>) => TProjectionMap), ...__projectionMapTypeMismatchErrors: RequireAFakeParameterIfThereAreTypeMismatchErrors<_TProjectionResult>): GroqBuilder>, TQueryConfig>; } }