High performance self-hosted photo and video management solution.
TypeScript backup-toolfluttergoogle-photosgoogle-photos-alternativejavascriptmobile-appnestjsnodejsphoto-galleryphotosphotos-managementself-hostedsveltesveltekittypescriptvideos
import z from 'zod';
import { latitudeSchema, longitudeSchema } from 'src/validation.js';
export const BBoxSchema = z
.object({
west: longitudeSchema.describe('West longitude (-180 to 180)'),
south: latitudeSchema.describe('South latitude (-90 to 90)'),
east: longitudeSchema.describe(
'East longitude (-180 to 180). May be less than west when crossing the antimeridian.',
),
north: latitudeSchema.describe('North latitude (-90 to 90). Must be >= south.'),
})
.refine(({ north, south }) => north >= south, {
path: ['north'],
error: 'North latitude must be greater than or equal to south latitude',
})
.meta({ id: 'BBoxDto' });