@code-pushup/models
Version:
Model definitions and validators for the Code PushUp CLI
54 lines (53 loc) • 2.28 kB
TypeScript
import { z } from 'zod';
export declare const tableAlignmentSchema: z.ZodEnum<{
left: "left";
center: "center";
right: "right";
}>;
export type TableAlignment = z.infer<typeof tableAlignmentSchema>;
export declare const tableColumnPrimitiveSchema: z.ZodEnum<{
left: "left";
center: "center";
right: "right";
}>;
export type TableColumnPrimitive = z.infer<typeof tableColumnPrimitiveSchema>;
export declare const tableColumnObjectSchema: z.ZodObject<{
key: z.ZodString;
label: z.ZodOptional<z.ZodString>;
align: z.ZodOptional<z.ZodEnum<{
left: "left";
center: "center";
right: "right";
}>>;
}, z.core.$strip>;
export type TableColumnObject = z.infer<typeof tableColumnObjectSchema>;
export declare const tableRowObjectSchema: z.ZodRecord<z.ZodString, z.ZodDefault<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>>>;
export type TableRowObject = z.infer<typeof tableRowObjectSchema>;
export declare const tableRowPrimitiveSchema: z.ZodArray<z.ZodDefault<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>>>;
export type TableRowPrimitive = z.infer<typeof tableRowPrimitiveSchema>;
export declare const tableSchema: (description?: string) => z.ZodUnion<readonly [z.ZodObject<{
title: z.ZodOptional<z.ZodString>;
columns: z.ZodOptional<z.ZodArray<z.ZodEnum<{
left: "left";
center: "center";
right: "right";
}>>>;
rows: z.ZodArray<z.ZodArray<z.ZodDefault<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>>>>;
}, z.core.$strip>, z.ZodObject<{
title: z.ZodOptional<z.ZodString>;
columns: z.ZodOptional<z.ZodUnion<readonly [z.ZodArray<z.ZodEnum<{
left: "left";
center: "center";
right: "right";
}>>, z.ZodArray<z.ZodObject<{
key: z.ZodString;
label: z.ZodOptional<z.ZodString>;
align: z.ZodOptional<z.ZodEnum<{
left: "left";
center: "center";
right: "right";
}>>;
}, z.core.$strip>>]>>;
rows: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodDefault<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>>>>;
}, z.core.$strip>]>;
export type Table = z.infer<ReturnType<typeof tableSchema>>;