UNPKG

@accounter/server

Version:

136 lines (135 loc) • 5.45 kB
import { z } from 'zod'; declare const dynamicReportNodeData: z.ZodObject<{ descendantSortCodes: z.ZodOptional<z.ZodUnion<[z.ZodArray<z.ZodNumber, "many">, z.ZodNull]>>; descendantFinancialEntities: z.ZodOptional<z.ZodUnion<[z.ZodArray<z.ZodString, "many">, z.ZodNull]>>; mergedSortCodes: z.ZodOptional<z.ZodUnion<[z.ZodArray<z.ZodNumber, "many">, z.ZodNull]>>; isOpen: z.ZodBoolean; hebrewText: z.ZodOptional<z.ZodString>; }, "strict", z.ZodTypeAny, { isOpen: boolean; descendantSortCodes?: number[] | null | undefined; descendantFinancialEntities?: string[] | null | undefined; mergedSortCodes?: number[] | null | undefined; hebrewText?: string | undefined; }, { isOpen: boolean; descendantSortCodes?: number[] | null | undefined; descendantFinancialEntities?: string[] | null | undefined; mergedSortCodes?: number[] | null | undefined; hebrewText?: string | undefined; }>; declare const dynamicReportNode: z.ZodObject<{ id: z.ZodUnion<[z.ZodString, z.ZodNumber]>; parent: z.ZodUnion<[z.ZodString, z.ZodNumber]>; text: z.ZodString; droppable: z.ZodBoolean; data: z.ZodObject<{ descendantSortCodes: z.ZodOptional<z.ZodUnion<[z.ZodArray<z.ZodNumber, "many">, z.ZodNull]>>; descendantFinancialEntities: z.ZodOptional<z.ZodUnion<[z.ZodArray<z.ZodString, "many">, z.ZodNull]>>; mergedSortCodes: z.ZodOptional<z.ZodUnion<[z.ZodArray<z.ZodNumber, "many">, z.ZodNull]>>; isOpen: z.ZodBoolean; hebrewText: z.ZodOptional<z.ZodString>; }, "strict", z.ZodTypeAny, { isOpen: boolean; descendantSortCodes?: number[] | null | undefined; descendantFinancialEntities?: string[] | null | undefined; mergedSortCodes?: number[] | null | undefined; hebrewText?: string | undefined; }, { isOpen: boolean; descendantSortCodes?: number[] | null | undefined; descendantFinancialEntities?: string[] | null | undefined; mergedSortCodes?: number[] | null | undefined; hebrewText?: string | undefined; }>; }, "strict", z.ZodTypeAny, { id: string | number; parent: string | number; text: string; droppable: boolean; data: { isOpen: boolean; descendantSortCodes?: number[] | null | undefined; descendantFinancialEntities?: string[] | null | undefined; mergedSortCodes?: number[] | null | undefined; hebrewText?: string | undefined; }; }, { id: string | number; parent: string | number; text: string; droppable: boolean; data: { isOpen: boolean; descendantSortCodes?: number[] | null | undefined; descendantFinancialEntities?: string[] | null | undefined; mergedSortCodes?: number[] | null | undefined; hebrewText?: string | undefined; }; }>; export declare const dynamicReportTemplate: z.ZodArray<z.ZodObject<{ id: z.ZodUnion<[z.ZodString, z.ZodNumber]>; parent: z.ZodUnion<[z.ZodString, z.ZodNumber]>; text: z.ZodString; droppable: z.ZodBoolean; data: z.ZodObject<{ descendantSortCodes: z.ZodOptional<z.ZodUnion<[z.ZodArray<z.ZodNumber, "many">, z.ZodNull]>>; descendantFinancialEntities: z.ZodOptional<z.ZodUnion<[z.ZodArray<z.ZodString, "many">, z.ZodNull]>>; mergedSortCodes: z.ZodOptional<z.ZodUnion<[z.ZodArray<z.ZodNumber, "many">, z.ZodNull]>>; isOpen: z.ZodBoolean; hebrewText: z.ZodOptional<z.ZodString>; }, "strict", z.ZodTypeAny, { isOpen: boolean; descendantSortCodes?: number[] | null | undefined; descendantFinancialEntities?: string[] | null | undefined; mergedSortCodes?: number[] | null | undefined; hebrewText?: string | undefined; }, { isOpen: boolean; descendantSortCodes?: number[] | null | undefined; descendantFinancialEntities?: string[] | null | undefined; mergedSortCodes?: number[] | null | undefined; hebrewText?: string | undefined; }>; }, "strict", z.ZodTypeAny, { id: string | number; parent: string | number; text: string; droppable: boolean; data: { isOpen: boolean; descendantSortCodes?: number[] | null | undefined; descendantFinancialEntities?: string[] | null | undefined; mergedSortCodes?: number[] | null | undefined; hebrewText?: string | undefined; }; }, { id: string | number; parent: string | number; text: string; droppable: boolean; data: { isOpen: boolean; descendantSortCodes?: number[] | null | undefined; descendantFinancialEntities?: string[] | null | undefined; mergedSortCodes?: number[] | null | undefined; hebrewText?: string | undefined; }; }>, "many">; export type DynamicReportNodeType = z.infer<typeof dynamicReportNode>; export type DynamicReportNodeDataType = z.infer<typeof dynamicReportNodeData>; export declare function parseTemplate(raw: string): { id: string | number; parent: string | number; text: string; droppable: boolean; data: { isOpen: boolean; descendantSortCodes?: number[] | null | undefined; descendantFinancialEntities?: string[] | null | undefined; mergedSortCodes?: number[] | null | undefined; hebrewText?: string | undefined; }; }[]; export declare function validateTemplate(raw: string): boolean; export {};