fix: get joinloyalty button from contentstack
This commit is contained in:
@@ -152,6 +152,14 @@ const loyaltyPageJoinLoyaltyContact = z.object({
|
||||
join_loyalty_contact: z.object({
|
||||
title: z.string().nullable(),
|
||||
preamble: z.string().nullable(),
|
||||
button: z
|
||||
.object({
|
||||
openInNewTab: z.boolean(),
|
||||
title: z.string(),
|
||||
href: z.string(),
|
||||
isExternal: z.boolean(),
|
||||
})
|
||||
.nullable(),
|
||||
contact: z.array(
|
||||
z.object({
|
||||
__typename: z.literal(
|
||||
@@ -362,8 +370,22 @@ const loyaltyPageSidebarTextContentRef = z.object({
|
||||
}),
|
||||
})
|
||||
|
||||
const loyaltyPageSidebarJoinLoyaltyContactRef = z.object({
|
||||
__typename: z.literal(
|
||||
SidebarTypenameEnum.LoyaltyPageSidebarJoinLoyaltyContact
|
||||
),
|
||||
join_loyalty_contact: z.object({
|
||||
button: z
|
||||
.object({
|
||||
linkConnection: pageConnectionRefs,
|
||||
})
|
||||
.nullable(),
|
||||
}),
|
||||
})
|
||||
|
||||
const loyaltyPageSidebarRefsItem = z.discriminatedUnion("__typename", [
|
||||
loyaltyPageSidebarTextContentRef,
|
||||
loyaltyPageSidebarJoinLoyaltyContactRef,
|
||||
])
|
||||
|
||||
export const validateLoyaltyPageRefsSchema = z.object({
|
||||
|
||||
Reference in New Issue
Block a user