fix: refactor tracking requests
This commit is contained in:
@@ -193,7 +193,12 @@ export const validateLoyaltyPageSchema = z.object({
|
||||
heading: z.string().nullable(),
|
||||
blocks: z.array(loyaltyPageBlockItem).nullable(),
|
||||
sidebar: z.array(loyaltyPageSidebarItem).nullable(),
|
||||
system: z.object({ uid: z.string() }),
|
||||
system: z.object({
|
||||
uid: z.string(),
|
||||
locale: z.nativeEnum(Lang),
|
||||
created_at: z.string(),
|
||||
updated_at: z.string(),
|
||||
}),
|
||||
})
|
||||
|
||||
// Block types
|
||||
@@ -417,17 +422,3 @@ export const validateLoyaltyPageRefsSchema = z.object({
|
||||
export type LoyaltyPageRefsDataRaw = z.infer<
|
||||
typeof validateLoyaltyPageRefsSchema
|
||||
>
|
||||
|
||||
//Tracking
|
||||
const validateLoyaltyTrackingData = z.object({
|
||||
loyalty_page: z.object({
|
||||
system: z.object({
|
||||
uid: z.string(),
|
||||
locale: z.string(),
|
||||
updated_at: z.string(),
|
||||
created_at: z.string(),
|
||||
}),
|
||||
}),
|
||||
})
|
||||
|
||||
export type LoyaltyPageTackingData = z.infer<typeof validateLoyaltyTrackingData>
|
||||
|
||||
Reference in New Issue
Block a user