import type { PropertyConfig, AdminCollection } from "@rebasepro/cms-types"; import { AuthController } from "@rebasepro/cms-types"; /** * The properties a preview surface should render for a record, best first. * * Three things decide the answer, in this order: * * 1. `previewProperties` — passed in, or declared on the collection. A stated * list is returned verbatim, ranking and limit included: a developer who * asks for the Markdown biography gets the Markdown biography. * 2. Whether the value has a one-line form at all. A map renders as a * key/value table and a Markdown field as a document; neither fits a card * line, so they never take a slot from a value that does. See * {@link rankSummaryProperty}. * 3. `propertiesOrder`, which breaks ties. * * The middle step is the one that is easy to get wrong by leaving out. * `propertiesOrder` states the *column* order of a collection table — it is * not a statement that the first three columns summarise a record, and reading * it as one is how a card ends up rendering somebody's entire biography. */ export declare function getEntityPreviewKeys(authController: AuthController, targetCollection: AdminCollection, fields: Record, previewProperties?: string[], limit?: number): string[]; /** * The `include` params that eager-load a collection's relations in the same * request as its rows, so previews never fetch once per relation cell. * * Only the REST transport reads `include`; the realtime transport embeds * relation data unconditionally and ignores it. Passing it either way keeps a * realtime-less deployment rendering the same cells as a realtime one. */ export declare function getRelationIncludeParams(collection: AdminCollection): string[] | undefined; /** * The property that fills the title slot for a collection. Ranking lives in * `@rebasepro/common`, shared with the admin package so both agree on what an * entity is called. */ export declare function getEntityTitlePropertyKey>(collection: AdminCollection, propertyConfigs: Record): string | undefined;