UNPKG

@allmaps/annotation

Version:

Functions for generating and parsing IIIF georeference annotations

146 lines (145 loc) 6.18 kB
import { z } from 'zod'; export declare const SvgSelectorSchema: z.ZodObject<{ type: z.ZodLiteral<"SvgSelector">; value: z.ZodString; }, z.core.$strip>; export declare const TargetSchema: z.ZodObject<{ source: z.ZodString; service: z.ZodArray<z.ZodObject<{ '@id': z.ZodString; type: z.ZodEnum<{ ImageService1: "ImageService1"; ImageService2: "ImageService2"; ImageService3: "ImageService3"; Canvas: "Canvas"; }>; }, z.core.$strip>>; selector: z.ZodObject<{ type: z.ZodLiteral<"SvgSelector">; value: z.ZodString; }, z.core.$strip>; }, z.core.$strip>; export declare const FeaturePropertiesSchema: z.ZodObject<{ pixelCoords: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>; }, z.core.$strip>; export declare const BodySchema: z.ZodObject<{ type: z.ZodLiteral<"FeatureCollection">; transformation: z.ZodOptional<z.ZodUnion<[z.ZodPipe<z.ZodUnknown, z.ZodTransform<{ type: "helmert" | "polynomial" | "thinPlateSpline" | "projective" | "straight" | "linear"; options?: { [x: string]: unknown; } | undefined; } | undefined, unknown>>, z.ZodPipe<z.ZodUnknown, z.ZodTransform<{ type: "helmert" | "polynomial" | "thinPlateSpline" | "projective" | "straight" | "linear"; options?: { [x: string]: unknown; } | undefined; } | undefined, unknown>>]>>; features: z.ZodArray<z.ZodObject<{ type: z.ZodLiteral<"Feature">; properties: z.ZodObject<{ pixelCoords: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>; }, z.core.$strip>; geometry: z.ZodObject<{ type: z.ZodLiteral<"Point">; coordinates: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>; }, z.core.$strip>; }, z.core.$strip>>; }, z.core.$strip>; export declare const AnnotationSchema: z.ZodObject<{ id: z.ZodOptional<z.ZodString>; type: z.ZodLiteral<"Annotation">; '@context': z.ZodOptional<z.ZodUnion<readonly [z.ZodArray<z.ZodString>, z.ZodString]>>; motivation: z.ZodOptional<z.ZodString>; target: z.ZodObject<{ source: z.ZodString; service: z.ZodArray<z.ZodObject<{ '@id': z.ZodString; type: z.ZodEnum<{ ImageService1: "ImageService1"; ImageService2: "ImageService2"; ImageService3: "ImageService3"; Canvas: "Canvas"; }>; }, z.core.$strip>>; selector: z.ZodObject<{ type: z.ZodLiteral<"SvgSelector">; value: z.ZodString; }, z.core.$strip>; }, z.core.$strip>; body: z.ZodObject<{ type: z.ZodLiteral<"FeatureCollection">; transformation: z.ZodOptional<z.ZodUnion<[z.ZodPipe<z.ZodUnknown, z.ZodTransform<{ type: "helmert" | "polynomial" | "thinPlateSpline" | "projective" | "straight" | "linear"; options?: { [x: string]: unknown; } | undefined; } | undefined, unknown>>, z.ZodPipe<z.ZodUnknown, z.ZodTransform<{ type: "helmert" | "polynomial" | "thinPlateSpline" | "projective" | "straight" | "linear"; options?: { [x: string]: unknown; } | undefined; } | undefined, unknown>>]>>; features: z.ZodArray<z.ZodObject<{ type: z.ZodLiteral<"Feature">; properties: z.ZodObject<{ pixelCoords: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>; }, z.core.$strip>; geometry: z.ZodObject<{ type: z.ZodLiteral<"Point">; coordinates: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>; }, z.core.$strip>; }, z.core.$strip>>; }, z.core.$strip>; }, z.core.$strip>; export declare const AnnotationPageSchema: z.ZodObject<{ id: z.ZodOptional<z.ZodString>; type: z.ZodLiteral<"AnnotationPage">; '@context': z.ZodOptional<z.ZodUnion<readonly [z.ZodArray<z.ZodString>, z.ZodString]>>; items: z.ZodArray<z.ZodObject<{ id: z.ZodOptional<z.ZodString>; type: z.ZodLiteral<"Annotation">; '@context': z.ZodOptional<z.ZodUnion<readonly [z.ZodArray<z.ZodString>, z.ZodString]>>; motivation: z.ZodOptional<z.ZodString>; target: z.ZodObject<{ source: z.ZodString; service: z.ZodArray<z.ZodObject<{ '@id': z.ZodString; type: z.ZodEnum<{ ImageService1: "ImageService1"; ImageService2: "ImageService2"; ImageService3: "ImageService3"; Canvas: "Canvas"; }>; }, z.core.$strip>>; selector: z.ZodObject<{ type: z.ZodLiteral<"SvgSelector">; value: z.ZodString; }, z.core.$strip>; }, z.core.$strip>; body: z.ZodObject<{ type: z.ZodLiteral<"FeatureCollection">; transformation: z.ZodOptional<z.ZodUnion<[z.ZodPipe<z.ZodUnknown, z.ZodTransform<{ type: "helmert" | "polynomial" | "thinPlateSpline" | "projective" | "straight" | "linear"; options?: { [x: string]: unknown; } | undefined; } | undefined, unknown>>, z.ZodPipe<z.ZodUnknown, z.ZodTransform<{ type: "helmert" | "polynomial" | "thinPlateSpline" | "projective" | "straight" | "linear"; options?: { [x: string]: unknown; } | undefined; } | undefined, unknown>>]>>; features: z.ZodArray<z.ZodObject<{ type: z.ZodLiteral<"Feature">; properties: z.ZodObject<{ pixelCoords: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>; }, z.core.$strip>; geometry: z.ZodObject<{ type: z.ZodLiteral<"Point">; coordinates: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>; }, z.core.$strip>; }, z.core.$strip>>; }, z.core.$strip>; }, z.core.$strip>>; }, z.core.$strip>;