feat(SW-543): update contact config function

This commit is contained in:
Fredrik Thorsson
2025-01-02 11:29:09 +01:00
parent 584bcccb77
commit eab1386ee7
6 changed files with 16 additions and 15 deletions

View File

@@ -22,8 +22,7 @@ export const contactSchema = z.object({
contact: z.object({
contact_field: z.string(),
display_text: z.string().optional().nullable().default(null),
footnote: z.string().optional().nullable().default(null),
select_test: z.string(),
phone_footnote: z.string().optional().nullable(),
}),
})
.transform((data) => {
@@ -32,8 +31,7 @@ export const contactSchema = z.object({
typename: data.typename,
contact_field: data.contact.contact_field,
display_text: data.contact.display_text,
footnote: data.contact.footnote,
selectTest: data.contact.select_test,
phoneFootnote: data.contact.phone_footnote,
}
})
),