@encatch/schema 1.2.0-beta.6 → 1.2.0-beta.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/esm/index.js CHANGED
@@ -70,6 +70,14 @@ var longAnswerQuestionTranslationSchema = baseQuestionTranslationFieldsSchema.ex
70
70
  type: z.literal("long_text").describe("Question type identifier"),
71
71
  placeholder: translationEntrySchema.optional().describe("Textarea placeholder translation")
72
72
  }).describe("Translation schema for long answer questions");
73
+ var videoAudioQuestionTranslationSchema = baseQuestionTranslationFieldsSchema.extend({
74
+ type: z.literal("video_audio").describe("Question type identifier"),
75
+ placeholder: translationEntrySchema.optional().describe("Placeholder for text/photo hints"),
76
+ modeTabLabelVideo: z.string().max(80).optional().describe("Translated tab label for video mode"),
77
+ modeTabLabelAudio: z.string().max(80).optional().describe("Translated tab label for audio mode"),
78
+ modeTabLabelPhoto: z.string().max(80).optional().describe("Translated tab label for photo mode"),
79
+ modeTabLabelText: z.string().max(80).optional().describe("Translated tab label for text mode")
80
+ }).describe("Translation schema for video/audio/photo/text questions");
73
81
  var nestedSelectionQuestionTranslationSchema = baseQuestionTranslationFieldsSchema.extend({
74
82
  type: z.literal("nested_selection").describe("Question type identifier"),
75
83
  placeholder: translationEntrySchema.optional().describe("Dropdown placeholder translation")
@@ -164,6 +172,7 @@ var questionTranslationSchema = z.union([
164
172
  npsQuestionTranslationSchema,
165
173
  shortAnswerQuestionTranslationSchema,
166
174
  longAnswerQuestionTranslationSchema,
175
+ videoAudioQuestionTranslationSchema,
167
176
  nestedSelectionQuestionTranslationSchema,
168
177
  annotationQuestionTranslationSchema,
169
178
  welcomeQuestionTranslationSchema,
@@ -525,7 +534,9 @@ var questionSchema = z2.object({
525
534
  nextButtonLabel: z2.string().min(1).max(50).default("Next").describe(
526
535
  "Label for the next button when advancing past this question (overrides section or form defaults when set)"
527
536
  ),
528
- showQuestionTitle: z2.boolean().default(true).describe("Whether to display the question title; defaults to true")
537
+ showQuestionTitle: z2.boolean().default(true).describe("Whether to display the question title; defaults to true"),
538
+ questionMediaUrl: z2.string().url().optional().describe("Optional URL for media (image or video) displayed alongside the question"),
539
+ questionMediaType: z2.enum(["image", "video", "youtube", "vimeo"]).optional().describe("Type of media referenced by questionMediaUrl; one of 'image', 'video', 'youtube', or 'vimeo'")
529
540
  }).describe("Base schema for all question types with common properties");
530
541
  var ratingQuestionSchema = questionSchema.extend({
531
542
  type: z2.literal("rating").describe("Must be exactly 'rating'"),
@@ -1079,7 +1090,11 @@ var videoAudioQuestionSchema = questionSchema.extend({
1079
1090
  maxDurationSeconds: z2.number().int().min(5).max(600).optional().describe("Maximum recording length in seconds (5\u2013600); Typeform hardcodes 120s with no config, making this a differentiator; when absent the platform default applies"),
1080
1091
  maxFileSizeMb: z2.number().int().min(1).max(500).optional().describe("Maximum size in megabytes for uploaded pre-recorded files (1\u2013500); when absent the platform ceiling applies"),
1081
1092
  allowUpload: z2.boolean().optional().default(true).describe("Whether the respondent can upload a file in addition to recording or capturing live (video, audio, or photo)"),
1082
- placeholder: z2.string().max(200).optional().describe("Instructional text shown to the respondent before they begin recording or capturing")
1093
+ placeholder: z2.string().max(200).optional().describe("Instructional text shown to the respondent before they begin recording or capturing"),
1094
+ modeTabLabelVideo: z2.string().max(80).optional().describe("Custom tab label for video mode in the respondent UI; when absent defaults to 'Video'"),
1095
+ modeTabLabelAudio: z2.string().max(80).optional().describe("Custom tab label for audio mode; when absent defaults to 'Audio'"),
1096
+ modeTabLabelPhoto: z2.string().max(80).optional().describe("Custom tab label for photo mode; when absent defaults to 'Photo'"),
1097
+ modeTabLabelText: z2.string().max(80).optional().describe("Custom tab label for text mode; when absent defaults to 'Text'")
1083
1098
  }).describe("Schema for a video, audio, and photo question where respondents can record or upload media or enter a text answer");
1084
1099
  var schedulerProviderSchema = z2.enum(["google_calendar", "calendly"]);
1085
1100
  var SchedulerProviders = {
@@ -2190,6 +2205,7 @@ export {
2190
2205
  videoAttachmentSchema,
2191
2206
  videoAudioModeSchema,
2192
2207
  videoAudioQuestionSchema,
2208
+ videoAudioQuestionTranslationSchema,
2193
2209
  visibilityConditionSchema,
2194
2210
  wallpaperLayoutSchema,
2195
2211
  websiteQuestionSchema,