/** * Options for controlling GraphQL fragment generation behavior. */ type FragmentOptions = { /** * Enable Digital Asset Management (DAM) support for contentReference properties. * When true, includes specialized fragments for DAM assets (images, videos, files). * @default false */ damEnabled?: boolean; /** * Maximum number of fragments allowed before logging performance warnings. * Helps prevent excessive GraphQL query complexity from unrestricted content types. * @default 100 */ maxFragmentThreshold?: number; /** * Whether to include CMS base type fragments (e.g., _IContent, _IPage) in generated fragments. * Set to false for component property fragments that don't need base metadata. * @default true */ includeBaseFragments?: boolean; }; /** * Builds a GraphQL fragment for the requested content-type **and** returns every nested fragment it depends on. * @param contentTypeName Name/key of the content-type to expand. * @param visited Set of fragment names already on the stack. * @param suffix Optional suffix for the fragment name. * @param options Fragment generation options (damEnabled, maxFragmentThreshold, includeBaseFragments). * @returns Array of fragment strings. */ export declare function createFragment(contentTypeName: string, visited?: Set, // shared across recursion suffix?: string, options?: FragmentOptions): string[]; /** * Generates a complete GraphQL query for fetching one item. * * @param contentType - The key of the content type to query. * @returns A string representing the GraphQL query. */ export declare function createSingleContentQuery(contentType: string, damEnabled?: boolean, maxFragmentThreshold?: number): string; /** * Generates a complete GraphQL query for fetching multiple items. * All items must have the same content type * * @param contentType - The key of the content type to query. * @param damEnabled - Whether DAM assets are enabled. * @param maxFragmentThreshold - Maximum fragment threshold for warnings (default: 100). * @returns A string representing the GraphQL query. */ export declare function createMultipleContentQuery(contentType: string, damEnabled?: boolean, maxFragmentThreshold?: number): string; export type ItemsResponse = { _Content: { items: ({ __typename: string; _metadata: { variation: string; }; } & T)[]; }; }; export {};