diff --git a/package.json b/package.json index 9b2f501..fdd57f1 100644 --- a/package.json +++ b/package.json @@ -65,8 +65,7 @@ "ts-jest": "^26.4.4", "ts-node": "^9.1.1", "typedoc": "^0.24.7", - "typescript": "^4.2.4", - "zod": "~3.25.76" + "typescript": "^4.2.4" }, "dependencies": { "@types/geojson": "^7946.0.16", diff --git a/src/index.ts b/src/index.ts index 30facbc..52f0d6a 100644 --- a/src/index.ts +++ b/src/index.ts @@ -11,4 +11,3 @@ export * from './enums/geo/epsg'; export * from './helpers/mime'; export * from './types/countryTranslation'; export * from './interfaces'; -export * from './schemas'; diff --git a/src/schemas/index.ts b/src/schemas/index.ts deleted file mode 100644 index 8d81526..0000000 --- a/src/schemas/index.ts +++ /dev/null @@ -1 +0,0 @@ -export * from './serving-proxy/capability.schema'; diff --git a/src/schemas/serving-proxy/capability.schema.ts b/src/schemas/serving-proxy/capability.schema.ts deleted file mode 100644 index 247d061..0000000 --- a/src/schemas/serving-proxy/capability.schema.ts +++ /dev/null @@ -1,32 +0,0 @@ -/* eslint-disable @typescript-eslint/naming-convention */ -import { z } from 'zod'; - -export const StyleSchema = z.object({ - value: z.string().min(1).describe('Style identifier value'), - isDefault: z.string().min(1).nullable().describe('Whether this style is the default style'), -}); - -export const TileMatrixSetSchema = z.object({ - tileMatrixSetID: z.string().min(1).describe('Identifier of the TileMatrixSet'), - tileMatrixLabels: z.array(z.string().min(1)).min(1).describe('TileMatrix identifier per level'), -}); - -export const ResourceURLSchema = z.object({ - format: z.string().min(1).describe('MIME type of the resource'), - resourceType: z.string().min(1).describe('Type of the resource, e.g. tile'), - template: z.string().min(1).describe('URL template for the resource'), -}); - -export const CapabilitySchema = z.object({ - id: z.string().min(1).describe('Layer identifier'), - style: z.array(StyleSchema).min(1).describe('Styles available for the layer'), - format: z.array(z.string().min(1)).min(1).describe('MIME types supported by the layer'), - tileMatrixSet: z.array(TileMatrixSetSchema).min(1).describe('TileMatrixSets available for the layer'), - url: z.array(ResourceURLSchema).min(1).describe('Resource URLs available for the layer'), -}); - -// Inferred TypeScript types -export type Style = z.infer; -export type TileMatrixSet = z.infer; -export type ResourceURL = z.infer; -export type Capability = z.infer;