Files
calendar/packages/app-store/routing-forms/trpc/response.schema.ts
T
484f603c9e fix: Routing Forms, Number operators were using string operands (#9182)
* Fix operators for number

* Add number operator unit tests

* Fixes and remove between operators

---------

Co-authored-by: Omar López <zomars@me.com>
2023-06-01 20:29:13 +00:00

15 lines
344 B
TypeScript

import { z } from "zod";
export const ZResponseInputSchema = z.object({
formId: z.string(),
formFillerId: z.string(),
response: z.record(
z.object({
label: z.string(),
value: z.union([z.string(), z.number(), z.array(z.string())]),
})
),
});
export type TResponseInputSchema = z.infer<typeof ZResponseInputSchema>;