UNPKG

@tricoteuses/assemblee

Version:

Retrieve, clean up & handle French Assemblée nationale's open data

107 lines (106 loc) 2.92 kB
import { z } from 'zod'; import { ActeurClean as Acteur } from '../../schemas/clean/acteurs_et_organes.js'; export type PhotosOptions = ReturnType<typeof retrievePhotosParser.parse>; export declare const photosOptions: { clone: { alias: string; description: string; type: z.ZodOptional<z.ZodString>; }; pull: { alias: string; description: string; type: z.ZodDefault<z.ZodBoolean>; }; fetch: { alias: string; description: string; type: z.ZodDefault<z.ZodBoolean>; }; silent: { alias: string; description: string; type: z.ZodDefault<z.ZodBoolean>; }; commit: { alias: string; description: string; type: z.ZodDefault<z.ZodBoolean>; }; remote: { alias: string; description: string; type: z.ZodDefault<z.ZodArray<z.ZodString>>; }; width: { alias: string; description: string; type: z.ZodDefault<z.ZodNumber>; }; height: { alias: string; description: string; type: z.ZodDefault<z.ZodNumber>; }; square: { alias: string; description: string; type: z.ZodDefault<z.ZodBoolean>; }; }; export declare const retrievePhotosParser: import('zod-opts').Parser<{ clone: { alias: string; description: string; type: z.ZodOptional<z.ZodString>; }; pull: { alias: string; description: string; type: z.ZodDefault<z.ZodBoolean>; }; fetch: { alias: string; description: string; type: z.ZodDefault<z.ZodBoolean>; }; silent: { alias: string; description: string; type: z.ZodDefault<z.ZodBoolean>; }; commit: { alias: string; description: string; type: z.ZodDefault<z.ZodBoolean>; }; remote: { alias: string; description: string; type: z.ZodDefault<z.ZodArray<z.ZodString>>; }; width: { alias: string; description: string; type: z.ZodDefault<z.ZodNumber>; }; height: { alias: string; description: string; type: z.ZodDefault<z.ZodNumber>; }; square: { alias: string; description: string; type: z.ZodDefault<z.ZodBoolean>; }; }, [{ description: string; type: z.ZodString; name: "dataDir"; }]>; export declare function cloneAndUpdatePhotosGitRepository(photosDirName: string, { clone, dataDir, pull }: PhotosOptions): void; export declare function createMosaic(acteurUids: string[], photosDir: string, photosWidth: number, photosHeight: number, mosaicFilename: string): Promise<void>; export declare function resizePhoto(acteur: Acteur, width: number, height: number, photosDir: string, photoFilename: string, { silent }: { silent: boolean; }): Promise<void>;