Skip to content

Commit

Permalink
fix: add describes for button
Browse files Browse the repository at this point in the history
  • Loading branch information
edmonday committed Feb 3, 2025
1 parent 5c39bff commit 9bd901d
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions apps/api-journeys-modern/src/schema/blocks/button/button.zod.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,15 @@ const ButtonColorSchema = z.enum(['primary', 'secondary', 'error', 'inherit'])
const ButtonSizeSchema = z.enum(['small', 'medium', 'large'])

const ButtonBlockSchema = BlockSchema.extend({
label: z.string(),
variant: ButtonVariantSchema.nullable(),
color: ButtonColorSchema.nullable(),
size: ButtonSizeSchema.nullable(),
startIconId: z.string().nullable(),
endIconId: z.string().nullable(),
action: ActionSchema.nullable()
label: z.string().describe('The label of the button'),
variant: ButtonVariantSchema.nullable().describe('The variant of the button'),
color: ButtonColorSchema.nullable().describe('The color of the button'),
size: ButtonSizeSchema.nullable().describe('The size of the button'),
startIconId: z.string().nullable().describe('The ID of the start icon'),
endIconId: z.string().nullable().describe('The ID of the end icon'),
action: ActionSchema.nullable().describe(
'The action associated with the button'
)
})

export {
Expand Down

0 comments on commit 9bd901d

Please sign in to comment.