{"version":3,"file":"quizAnswers.schema.cjs","sources":["../../../../../../src/schema/public/components/quizAnswers/quizAnswers.schema.ts"],"sourcesContent":["import { z } from \"zod\";\nimport zodToCamelCase from \"zod-to-camel-case\";\n\nimport {\n  imageItemSchema,\n  textItemSchema,\n} from \"@/schema/public/components/imageTextItems/imageTextItems.schema\";\n\nexport const multipleChoiceSchema = z.object({\n  answer: z.array(z.union([textItemSchema, imageItemSchema]).optional()),\n  answer_is_active: z.boolean().optional(),\n  answer_is_correct: z.boolean().optional(),\n});\nexport type MultipleChoice = z.infer<typeof multipleChoiceSchema>;\n\nexport const shortAnswerSchema = z.object({\n  answer: z.array(textItemSchema.optional()),\n  answer_is_active: z.boolean().optional(),\n  answer_is_default: z.boolean().optional(),\n});\nexport type ShortAnswer = z.infer<typeof shortAnswerSchema>;\n\nexport const orderSchema = z.object({\n  answer: z.array(textItemSchema),\n  correct_order: z.number().optional(),\n  answer_is_active: z.boolean().optional(),\n});\nexport type Order = z.infer<typeof orderSchema>;\n\nexport const matchSchema = z.object({\n  answer_is_active: z.boolean().optional(),\n  correct_choice: z.array(textItemSchema),\n  match_option: z.array(textItemSchema).optional(),\n});\nexport type Match = z.infer<typeof matchSchema>;\n\nexport const shortAnswerSchemaCamel = zodToCamelCase(shortAnswerSchema);\nexport type ShortAnswerCamel = z.infer<typeof shortAnswerSchemaCamel>;\n\nexport const multipleChoiceSchemaCamel = zodToCamelCase(multipleChoiceSchema);\nexport type MultipleChoiceCamel = z.infer<typeof multipleChoiceSchemaCamel>;\n\nexport const orderSchemaCamel = zodToCamelCase(orderSchema);\nexport type OrderCamel = z.infer<typeof orderSchemaCamel>;\n\nexport const matchSchemaCamel = zodToCamelCase(matchSchema);\nexport type MatchCamel = z.infer<typeof matchSchemaCamel>;\n"],"names":["multipleChoiceSchema","z","object","answer","array","union","textItemSchema","imageItemSchema","optional","answer_is_active","boolean","answer_is_correct","shortAnswerSchema","answer_is_default","orderSchema","correct_order","number","matchSchema","correct_choice","match_option","shortAnswerSchemaCamel","zodToCamelCase","multipleChoiceSchemaCamel","orderSchemaCamel","matchSchemaCamel"],"mappings":"wLAQO,MAAMA,EAAuBC,EAAAA,EAAEC,OAAO,CAC3CC,OAAQF,EAAAA,EAAEG,MAAMH,IAAEI,MAAM,CAACC,EAAAA,eAAgBC,EAAAA,kBAAkBC,YAC3DC,iBAAkBR,EAAAA,EAAES,UAAUF,WAC9BG,kBAAmBV,EAAAA,EAAES,UAAUF,aAIpBI,EAAoBX,EAAAA,EAAEC,OAAO,CACxCC,OAAQF,EAAAA,EAAEG,MAAME,EAAAA,eAAeE,YAC/BC,iBAAkBR,EAAAA,EAAES,UAAUF,WAC9BK,kBAAmBZ,EAAAA,EAAES,UAAUF,aAIpBM,EAAcb,EAAAA,EAAEC,OAAO,CAClCC,OAAQF,EAAAA,EAAEG,MAAME,kBAChBS,cAAed,EAAAA,EAAEe,SAASR,WAC1BC,iBAAkBR,EAAAA,EAAES,UAAUF,aAInBS,EAAchB,EAAAA,EAAEC,OAAO,CAClCO,iBAAkBR,EAAAA,EAAES,UAAUF,WAC9BU,eAAgBjB,EAAAA,EAAEG,MAAME,kBACxBa,aAAclB,EAAAA,EAAEG,MAAME,EAAAA,gBAAgBE,aAI3BY,EAAyBC,EAAAA,QAAeT,GAGxCU,EAA4BD,EAAAA,QAAerB,GAG3CuB,EAAmBF,EAAAA,QAAeP,GAGlCU,EAAmBH,EAAAA,QAAeJ"}