import { FieldState, Simplify } from "./types.js"; //#region src/types/value/image.d.ts /** * An individual image within an image field. The base image and each thumbnail uses this type. * * @typeParam State - State of the field which determines its shape. * @see {@link ImageField} for a full image field type. */ type ImageFieldImage = State extends "empty" ? EmptyImageFieldImage : FilledImageFieldImage; interface FilledImageFieldImage { id: string; url: string; dimensions: { width: number; height: number; }; edit: { x: number; y: number; zoom: number; background: string; }; alt: string | null; copyright: string | null; } interface EmptyImageFieldImage { id?: null; url?: null; dimensions?: null; edit?: null; alt?: null; copyright?: null; } /** * An image field. * * **Note**: Passing `null` to the `ThumbnailNames` parameter is deprecated and will be removed in a * future version. Use `never` instead. * * @typeParam ThumbnailNames - Names of thumbnails. If the field does not contain thumbnails, * `never` can be used to "disable" thumbnail fields. * @typeParam State - State of the field which determines its shape. * @see Image field documentation: {@link https://prismic.io/docs/image} */ type ImageField = Simplify & Record, ImageFieldImage> : ImageFieldImage & Record, ImageFieldImage>>; //#endregion export { EmptyImageFieldImage, FilledImageFieldImage, ImageField, ImageFieldImage }; //# sourceMappingURL=image.d.ts.map