/**
 * Collection schema guard shared by the Page and Post editors.
 *
 * Both editors persist content as top-level keys on a collection document
 * (`sections`, `metaTitle`, …). The server's field-access layer only writes
 * keys that are *declared as fields* on the collection — any undeclared key is
 * silently dropped on save. A collection missing e.g. the `sections` field
 * would therefore discard all section content with no error, so the editors
 * use this check to refuse to operate (and explain why) instead.
 *
 * When `config` (or its collections) is not provided — some embedding/test
 * contexts don't pass it — we can't check, so we report nothing missing and
 * trust the consumer.
 */
interface CollectionLike {
    slug?: string;
    fields?: unknown;
}
/** Look up a collection by slug; `collections` may be a record or an array. */
export declare function findCollection(config: unknown, slug: string): CollectionLike | null;
/** Field definitions may be a record (keyed by name) or an array of `{ name }`. */
export declare function declaredFieldNames(fields: unknown): Set<string> | null;
/**
 * Returns the `required` field keys absent from the collection's declared
 * fields, or `[]` when the collection / its fields can't be inspected.
 */
export declare function missingCollectionFields(config: unknown, slug: string, required: readonly string[]): string[];
export {};
//# sourceMappingURL=collection-schema.d.ts.map