2
0

feat(bot): ️ Add required option on file upload input

This commit is contained in:
Baptiste Arnaud
2022-06-25 09:24:47 +02:00
parent a4aa2938b7
commit 55108c80e8
7 changed files with 67 additions and 22 deletions

View File

@ -3,6 +3,7 @@ import { InputBlockType, optionBaseSchema, blockBaseSchema } from '../shared'
export const fileInputOptionsSchema = optionBaseSchema.and(
z.object({
isRequired: z.boolean().optional(),
isMultipleAllowed: z.boolean(),
labels: z.object({
placeholder: z.string(),
@ -20,6 +21,7 @@ export const fileInputStepSchema = blockBaseSchema.and(
)
export const defaultFileInputOptions: FileInputOptions = {
isRequired: true,
isMultipleAllowed: false,
labels: {
placeholder: `<strong>