feat(SW-391): Added sidepeek functionality to teasercard
This commit is contained in:
@@ -2,11 +2,12 @@ import { VariantProps } from "class-variance-authority"
|
||||
|
||||
import { teaserCardVariants } from "@/components/TempDesignSystem/TeaserCard/variants"
|
||||
|
||||
import { ImageVaultAsset } from "@/types/components/imageVault"
|
||||
import type { ImageVaultAsset } from "@/types/components/imageVault"
|
||||
import type { CardProps } from "@/components/TempDesignSystem/Card/card"
|
||||
import type { TeaserCard } from "../trpc/routers/contentstack/blocks"
|
||||
|
||||
interface SidePeekButton {
|
||||
title: string
|
||||
call_to_action_text: string
|
||||
}
|
||||
|
||||
export interface TeaserCardProps
|
||||
@@ -16,6 +17,12 @@ export interface TeaserCardProps
|
||||
primaryButton?: CardProps["primaryButton"]
|
||||
secondaryButton?: CardProps["secondaryButton"]
|
||||
sidePeekButton?: SidePeekButton
|
||||
sidePeekContent?: TeaserCard["sidepeek_content"]
|
||||
image?: ImageVaultAsset
|
||||
className?: string
|
||||
}
|
||||
|
||||
export interface TeaserCardSidepeekProps {
|
||||
button: SidePeekButton
|
||||
data: NonNullable<TeaserCard["sidepeek_content"]>
|
||||
}
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
import { z } from "zod"
|
||||
|
||||
import { cardsGridSchema } from "@/server/routers/contentstack/schemas/blocks/cardsGrid"
|
||||
import {
|
||||
cardsGridSchema,
|
||||
teaserCardBlockSchema,
|
||||
} from "@/server/routers/contentstack/schemas/blocks/cardsGrid"
|
||||
import { contentSchema } from "@/server/routers/contentstack/schemas/blocks/content"
|
||||
import { dynamicContentSchema } from "@/server/routers/contentstack/schemas/blocks/dynamicContent"
|
||||
import { shortcutsSchema } from "@/server/routers/contentstack/schemas/blocks/shortcuts"
|
||||
@@ -8,6 +11,13 @@ import { tableSchema } from "@/server/routers/contentstack/schemas/blocks/table"
|
||||
import { textColsSchema } from "@/server/routers/contentstack/schemas/blocks/textCols"
|
||||
import { uspGridSchema } from "@/server/routers/contentstack/schemas/blocks/uspGrid"
|
||||
|
||||
export enum CardsGridLayoutEnum {
|
||||
TWO_COLUMNS = "twoColumnGrid",
|
||||
THREE_COLUMNS = "threeColumnGrid",
|
||||
TWO_PLUS_ONE = "twoPlusOne",
|
||||
}
|
||||
|
||||
export interface TeaserCard extends z.output<typeof teaserCardBlockSchema> {}
|
||||
export interface CardsGrid extends z.output<typeof cardsGridSchema> {}
|
||||
export interface Content extends z.output<typeof contentSchema> {}
|
||||
export interface DynamicContent extends z.output<typeof dynamicContentSchema> {}
|
||||
|
||||
Reference in New Issue
Block a user