@encatch/schema 1.1.0-beta.12 → 1.1.0-beta.14

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
@@ -488,7 +488,7 @@ var questionSchema = z2.object({
488
488
  textAlign: z2.enum(["left", "center", "justify"]).optional().default("left").describe(
489
489
  "Text alignment for the question title and description; `justify` is intended for consent questions (full-width justified consent body markdown)"
490
490
  ),
491
- nextButtonLabel: z2.string().min(1).max(50).optional().describe(
491
+ nextButtonLabel: z2.string().min(1).max(50).default("Next").describe(
492
492
  "Label for the next button when advancing past this question (overrides section or form defaults when set)"
493
493
  )
494
494
  }).describe("Base schema for all question types with common properties");
@@ -929,7 +929,7 @@ var feedbackConfigurationSchema = z4.object({
929
929
  }).describe("Schema defining feedback configuration properties");
930
930
 
931
931
  // src/schemas/fields/form-properties-schema.ts
932
- import { z as z8 } from "zod";
932
+ import { z as z9 } from "zod";
933
933
 
934
934
  // src/schemas/fields/other-screen-schema.ts
935
935
  import { z as z5 } from "zod";
@@ -1113,30 +1113,154 @@ var audienceTriggerPropertiesSchema = z7.object({
1113
1113
  }
1114
1114
  ).describe("Schema defining audience trigger properties for form targeting");
1115
1115
 
1116
+ // src/schemas/fields/layout-schema.ts
1117
+ import { z as z8 } from "zod";
1118
+ var focalPointSchema = z8.object({
1119
+ x: z8.number().min(-1).max(1).describe("Horizontal focal point from -1 (far left) to 1 (far right)"),
1120
+ y: z8.number().min(-1).max(1).describe("Vertical focal point from -1 (top) to 1 (bottom)")
1121
+ }).describe("Focal point for image cropping and positioning within its container");
1122
+ var imageAttachmentSchema = z8.object({
1123
+ type: z8.literal("image"),
1124
+ href: z8.string().url().describe("URL of the image asset"),
1125
+ properties: z8.object({
1126
+ description: z8.string().optional().describe("Accessible description of the image (used as alt text when decorative is false)"),
1127
+ decorative: z8.boolean().default(false).describe(
1128
+ "When true the image is purely visual; screen readers skip it and description is not surfaced as alt text"
1129
+ ),
1130
+ brightness: z8.number().min(-1).max(1).optional().describe("Brightness adjustment: -1 darkest, 0 unchanged, 1 brightest"),
1131
+ focalPoint: focalPointSchema.optional()
1132
+ }).optional().describe("Optional display properties for the image")
1133
+ }).describe("Image attachment for section layouts");
1134
+ var videoAttachmentSchema = z8.object({
1135
+ type: z8.literal("video"),
1136
+ href: z8.string().url().describe(
1137
+ "URL of the video \u2014 YouTube, Vimeo, Pexels, or self-hosted CDN"
1138
+ ),
1139
+ scale: z8.enum(["0.4", "0.6", "0.8", "1"]).default("0.6").optional().describe("Responsive scale for the video within its container"),
1140
+ properties: z8.object({
1141
+ description: z8.string().optional().describe("Accessible description of the video"),
1142
+ decorative: z8.boolean().default(false).describe("When true the video is purely decorative and screen readers skip it")
1143
+ }).optional().describe("Optional display properties for the video")
1144
+ }).describe("Video attachment for section layouts (external embed or self-hosted CDN)");
1145
+ var colorAttachmentSchema = z8.object({
1146
+ type: z8.literal("color"),
1147
+ value: z8.string().regex(
1148
+ /^#([0-9A-Fa-f]{3}|[0-9A-Fa-f]{6}|[0-9A-Fa-f]{8})$/,
1149
+ "Must be a valid hex color: #RGB, #RRGGBB, or #RRGGBBAA"
1150
+ ).describe("Hex color value e.g. #FF5733 (opaque) or #FF5733CC (with alpha)")
1151
+ }).describe("Solid color background attachment for section layouts");
1152
+ var gradientAttachmentSchema = z8.object({
1153
+ type: z8.literal("gradient"),
1154
+ value: z8.string().min(1).describe(
1155
+ "CSS gradient string e.g. linear-gradient(135deg, #FF5733, #3498db) or radial-gradient(circle, #FF5733, #3498db)"
1156
+ )
1157
+ }).describe("CSS gradient background attachment for section layouts");
1158
+ var layoutAttachmentSchema = z8.discriminatedUnion("type", [
1159
+ imageAttachmentSchema,
1160
+ videoAttachmentSchema,
1161
+ colorAttachmentSchema,
1162
+ gradientAttachmentSchema
1163
+ ]).describe(
1164
+ "Attachment used in a section layout \u2014 image, video, solid color, or gradient"
1165
+ );
1166
+ var LayoutAttachmentTypes = {
1167
+ IMAGE: "image",
1168
+ VIDEO: "video",
1169
+ COLOR: "color",
1170
+ GRADIENT: "gradient"
1171
+ };
1172
+ var stackLayoutSchema = z8.object({
1173
+ type: z8.literal("stack"),
1174
+ attachment: layoutAttachmentSchema.optional().describe("Background media rendered behind the question content")
1175
+ }).describe(
1176
+ "Stack layout: attachment renders as a full-bleed background behind the question"
1177
+ );
1178
+ var floatLayoutSchema = z8.object({
1179
+ type: z8.literal("float"),
1180
+ placement: z8.enum(["left", "right"]).describe("Side the media floats on"),
1181
+ attachment: layoutAttachmentSchema.optional().describe("Media that floats beside the question content")
1182
+ }).describe(
1183
+ "Float layout: attachment floats to the left or right of the question content"
1184
+ );
1185
+ var splitLayoutSchema = z8.object({
1186
+ type: z8.literal("split"),
1187
+ placement: z8.enum(["left", "right"]).describe("Side the media occupies in the split"),
1188
+ attachment: layoutAttachmentSchema.optional().describe("Media that occupies its half of the split viewport")
1189
+ }).describe(
1190
+ "Split layout: viewport is divided equally between media and question content"
1191
+ );
1192
+ var wallpaperLayoutSchema = z8.object({
1193
+ type: z8.literal("wallpaper"),
1194
+ attachment: layoutAttachmentSchema.optional().describe("Full-page background media")
1195
+ }).describe(
1196
+ "Wallpaper layout: attachment stretches or tiles across the entire viewport"
1197
+ );
1198
+ var sectionLayoutVariantSchema = z8.discriminatedUnion("type", [
1199
+ stackLayoutSchema,
1200
+ floatLayoutSchema,
1201
+ splitLayoutSchema,
1202
+ wallpaperLayoutSchema
1203
+ ]).describe(
1204
+ "Layout variant controlling how attachment is rendered relative to the question"
1205
+ );
1206
+ var LayoutTypes = {
1207
+ STACK: "stack",
1208
+ FLOAT: "float",
1209
+ SPLIT: "split",
1210
+ WALLPAPER: "wallpaper"
1211
+ };
1212
+ var layoutSurfaceSchema = z8.object({
1213
+ attachment: layoutAttachmentSchema.optional().describe(
1214
+ "Top-level media displayed inline with the question (separate from the layout's own attachment)"
1215
+ ),
1216
+ layout: sectionLayoutVariantSchema.describe(
1217
+ "How the attachment is positioned relative to the question content"
1218
+ )
1219
+ }).describe("Layout configuration for a single rendering surface");
1220
+ var sectionLayoutSchema = z8.object({
1221
+ inApp: layoutSurfaceSchema.optional().describe("Layout for in-app (native/webview) surfaces"),
1222
+ link: z8.object({
1223
+ mobile: layoutSurfaceSchema.optional().describe("Layout for link-based forms on mobile viewports (phones)"),
1224
+ others: layoutSurfaceSchema.optional().describe(
1225
+ "Layout for link-based forms on tablet and desktop viewports"
1226
+ )
1227
+ }).optional().describe(
1228
+ "Layout overrides for link/shareable surfaces, split by mobile and others (tablet + desktop)"
1229
+ )
1230
+ }).describe(
1231
+ "Per-section layout configuration scoped to in-app and link surfaces"
1232
+ );
1233
+
1116
1234
  // src/schemas/fields/form-properties-schema.ts
1117
- var otherConfigurationPropertiesSchema = z8.discriminatedUnion("isEnabled", [
1235
+ var otherConfigurationPropertiesSchema = z9.discriminatedUnion("isEnabled", [
1118
1236
  // When other configuration is disabled
1119
- z8.object({
1120
- isEnabled: z8.literal(false).describe("Whether other configuration properties are enabled"),
1237
+ z9.object({
1238
+ isEnabled: z9.literal(false).describe("Whether other configuration properties are enabled"),
1121
1239
  otherFields: OtherFieldsSchema.describe("Other form configuration fields including buttons and display options"),
1122
- translations: z8.record(z8.string(), OtherFieldsTranslationSchema).optional().describe("Translations for other configuration field labels and buttons keyed by language code")
1240
+ translations: z9.record(z9.string(), OtherFieldsTranslationSchema).optional().describe("Translations for other configuration field labels and buttons keyed by language code")
1123
1241
  }),
1124
1242
  // When other configuration is enabled
1125
- z8.object({
1126
- isEnabled: z8.literal(true).describe("Whether other configuration properties are enabled"),
1243
+ z9.object({
1244
+ isEnabled: z9.literal(true).describe("Whether other configuration properties are enabled"),
1127
1245
  otherFields: OtherFieldsSchema.describe("Other form configuration fields including buttons and display options"),
1128
- translations: z8.record(z8.string(), OtherFieldsTranslationSchema).describe("Translations for other configuration field labels and buttons keyed by language code")
1246
+ translations: z9.record(z9.string(), OtherFieldsTranslationSchema).describe("Translations for other configuration field labels and buttons keyed by language code")
1129
1247
  })
1130
1248
  ]).describe("Schema for other configuration properties including fields and translations");
1131
- var appearancePropertiesSchema = z8.object({
1132
- themeConfiguration: themeConfigurationSchema.describe("Theme configuration including colors, features, and positioning")
1133
- }).describe("Schema for appearance properties including theme configuration");
1134
- var formPropertiesSchema = z8.object({
1135
- feedbackConfigurationId: z8.uuid().describe("Unique identifier for the feedback configuration"),
1249
+ var appearancePropertiesSchema = z9.object({
1250
+ themeConfiguration: themeConfigurationSchema.describe("Theme configuration including colors, features, and positioning"),
1251
+ sectionLayoutDefaults: sectionLayoutSchema.optional().describe(
1252
+ "Default layout applied to sections that have no explicit entry in sectionLayouts. Resolved independently per surface (inApp, link.mobile, link.others)"
1253
+ ),
1254
+ sectionLayouts: z9.record(z9.string(), sectionLayoutSchema).optional().describe(
1255
+ "Per-section layout overrides keyed by section id. Takes precedence over sectionLayoutDefaults. Omit a section to fall back to sectionLayoutDefaults or engine default"
1256
+ )
1257
+ }).describe("Schema for appearance properties including theme configuration and per-section layouts");
1258
+ var formPropertiesSchema = z9.object({
1259
+ feedbackConfigurationId: z9.uuid().describe("Unique identifier for the feedback configuration"),
1136
1260
  feedbackConfiguration: feedbackConfigurationSchema.describe("Configuration properties for the feedback form"),
1137
- questionnaireFields: z8.object({
1138
- questions: z8.record(z8.string(), combinedQuestionSchema).describe("Collection of questions keyed by their string identifiers"),
1139
- sections: z8.array(sectionSchema).describe("Array of sections that organize questions into logical groups"),
1261
+ questionnaireFields: z9.object({
1262
+ questions: z9.record(z9.string(), combinedQuestionSchema).describe("Collection of questions keyed by their string identifiers"),
1263
+ sections: z9.array(sectionSchema).describe("Array of sections that organize questions into logical groups"),
1140
1264
  selectedLanguages: LanguagesSchema.describe("Array of languages selected for this questionnaire"),
1141
1265
  translations: translationsSchema.describe("Multi-language translations for questions and form content")
1142
1266
  }).describe("Fields defining the questionnaire structure, questions, sections, selected languages, and translations"),
@@ -1147,91 +1271,91 @@ var formPropertiesSchema = z8.object({
1147
1271
  }).describe("Complete schema for all feedback-level properties including publishing, audience targeting, configuration, and appearance");
1148
1272
 
1149
1273
  // src/schemas/fields/other-properties-schema.ts
1150
- import { z as z9 } from "zod";
1151
- var masterPropertiesSchema = z9.object({
1152
- mandatoryFetchConfigAtPaths: z9.array(z9.string()).describe("Array of paths where configuration must be fetched from server when navigated by user"),
1153
- configSyncIntervalSeconds: z9.number().int().positive().describe("Interval in seconds for configuration synchronization between client and server"),
1154
- disableAllSurvey: z9.boolean().describe("Flag to disable all surveys globally"),
1155
- feedbackIntervalDuration: z9.number().int().positive().describe("Duration in seconds for feedback interval between two auto triggered feedbacks")
1274
+ import { z as z10 } from "zod";
1275
+ var masterPropertiesSchema = z10.object({
1276
+ mandatoryFetchConfigAtPaths: z10.array(z10.string()).describe("Array of paths where configuration must be fetched from server when navigated by user"),
1277
+ configSyncIntervalSeconds: z10.number().int().positive().describe("Interval in seconds for configuration synchronization between client and server"),
1278
+ disableAllSurvey: z10.boolean().describe("Flag to disable all surveys globally"),
1279
+ feedbackIntervalDuration: z10.number().int().positive().describe("Duration in seconds for feedback interval between two auto triggered feedbacks")
1156
1280
  }).describe("Master properties configuration for global survey settings");
1157
1281
 
1158
1282
  // src/schemas/api/other-schema.ts
1159
- import { z as z10 } from "zod";
1160
- var deviceThemeSchema = z10.enum(["light", "dark", "system"]).describe("Enumeration of supported theme modes");
1283
+ import { z as z11 } from "zod";
1284
+ var deviceThemeSchema = z11.enum(["light", "dark", "system"]).describe("Enumeration of supported theme modes");
1161
1285
  var DeviceThemes = {
1162
1286
  LIGHT: "light",
1163
1287
  DARK: "dark",
1164
1288
  SYSTEM: "system"
1165
1289
  };
1166
- var deviceInfoSchema = z10.object({
1167
- $deviceType: z10.string().describe("Type of device being used"),
1168
- $timezone: z10.string().describe("Device timezone (e.g., 'Asia/Calcutta')"),
1290
+ var deviceInfoSchema = z11.object({
1291
+ $deviceType: z11.string().describe("Type of device being used"),
1292
+ $timezone: z11.string().describe("Device timezone (e.g., 'Asia/Calcutta')"),
1169
1293
  $theme: deviceThemeSchema.describe("Current theme mode preference"),
1170
- $os: z10.string().describe("Operating system running on the device"),
1171
- $osVersion: z10.string().describe("Version of the operating system"),
1172
- $appVersion: z10.string().describe("Version of the application"),
1173
- $app: z10.string().describe("Browser or application being used"),
1174
- $language: z10.string().describe("Language preference (e.g., 'en-GB')"),
1175
- $deviceId: z10.string().describe("Unique device identifier")
1294
+ $os: z11.string().describe("Operating system running on the device"),
1295
+ $osVersion: z11.string().describe("Version of the operating system"),
1296
+ $appVersion: z11.string().describe("Version of the application"),
1297
+ $app: z11.string().describe("Browser or application being used"),
1298
+ $language: z11.string().describe("Language preference (e.g., 'en-GB')"),
1299
+ $deviceId: z11.string().describe("Unique device identifier")
1176
1300
  }).describe("Device information collected from the client");
1177
- var sessionInfoSchema = z10.object({
1178
- $sessionId: z10.string().uuid().describe("Unique session identifier"),
1179
- $timestamp: z10.string().optional().describe("ISO timestamp of the session")
1301
+ var sessionInfoSchema = z11.object({
1302
+ $sessionId: z11.string().uuid().describe("Unique session identifier"),
1303
+ $timestamp: z11.string().optional().describe("ISO timestamp of the session")
1180
1304
  }).describe("Session information for tracking user sessions");
1181
- var deviceSessionInfoSchema = z10.object({
1305
+ var deviceSessionInfoSchema = z11.object({
1182
1306
  deviceInfo: deviceInfoSchema.describe("Device information"),
1183
1307
  sessionInfo: sessionInfoSchema.describe("Session information")
1184
1308
  }).describe("Combined device and session information");
1185
- var userPropertiesSchema = z10.object({
1186
- $counter: z10.record(z10.string(), z10.number().int()).describe(
1309
+ var userPropertiesSchema = z11.object({
1310
+ $counter: z11.record(z11.string(), z11.number().int()).describe(
1187
1311
  "Counter properties for user tracking (can be positive or negative)"
1188
1312
  ).optional(),
1189
- $set: z10.record(z10.string(), z10.any()).describe("Properties to set for the user").optional(),
1190
- $setOnce: z10.record(z10.string(), z10.any()).describe(
1313
+ $set: z11.record(z11.string(), z11.any()).describe("Properties to set for the user").optional(),
1314
+ $setOnce: z11.record(z11.string(), z11.any()).describe(
1191
1315
  "Properties to set once for the user (won't overwrite existing values)"
1192
1316
  ).optional(),
1193
- $unset: z10.array(z10.string()).describe("Array of property names to unset/remove from the user").optional()
1317
+ $unset: z11.array(z11.string()).describe("Array of property names to unset/remove from the user").optional()
1194
1318
  }).loose().describe(
1195
1319
  "User properties including counters, set operations, and other dynamic data"
1196
1320
  );
1197
- var userInfoSchema = z10.object({
1198
- userName: z10.string().email().describe("User's email address as username"),
1321
+ var userInfoSchema = z11.object({
1322
+ userName: z11.string().email().describe("User's email address as username"),
1199
1323
  properties: userPropertiesSchema.describe("User properties and counters")
1200
1324
  }).describe("User information including identification and properties");
1201
1325
 
1202
1326
  // src/schemas/api/submit-feedback-schema.ts
1203
- import { z as z11 } from "zod";
1204
- var formConfigSchema = z11.object({
1205
- feedbackIdentifier: z11.string().uuid().describe("Unique identifier for the feedback instance"),
1206
- feedbackConfigurationId: z11.string().uuid().describe("Unique identifier for the feedback configuration"),
1207
- completionTimeInSeconds: z11.number().int().min(0).describe("Time taken to complete the feedback in seconds"),
1208
- isPartialSubmit: z11.boolean().describe("Whether this is a partial submission (true) or full submission (false)"),
1209
- responseLanguageCode: z11.string().length(2).describe("Language code for the response (e.g., 'en', 'es')")
1327
+ import { z as z12 } from "zod";
1328
+ var formConfigSchema = z12.object({
1329
+ feedbackIdentifier: z12.string().uuid().describe("Unique identifier for the feedback instance"),
1330
+ feedbackConfigurationId: z12.string().uuid().describe("Unique identifier for the feedback configuration"),
1331
+ completionTimeInSeconds: z12.number().int().min(0).describe("Time taken to complete the feedback in seconds"),
1332
+ isPartialSubmit: z12.boolean().describe("Whether this is a partial submission (true) or full submission (false)"),
1333
+ responseLanguageCode: z12.string().length(2).describe("Language code for the response (e.g., 'en', 'es')")
1210
1334
  }).describe("Configuration information for the feedback form");
1211
- var questionResponseSchema = z11.object({
1212
- questionId: z11.string().uuid().describe("Unique identifier for the question"),
1335
+ var questionResponseSchema = z12.object({
1336
+ questionId: z12.string().uuid().describe("Unique identifier for the question"),
1213
1337
  answer: AnswerSchema.describe("The answer provided for this question"),
1214
- type: z11.string().describe("Type of the question (e.g., 'rating', 'single_choice')"),
1215
- error: z11.string().optional().describe("Error message if any validation failed"),
1216
- isOnPath: z11.boolean().optional().describe(
1338
+ type: z12.string().describe("Type of the question (e.g., 'rating', 'single_choice')"),
1339
+ error: z12.string().optional().describe("Error message if any validation failed"),
1340
+ isOnPath: z12.boolean().optional().describe(
1217
1341
  "When present, whether this question was on the respondent's navigation path (e.g. logic jumps); false for questions not reached"
1218
1342
  ),
1219
- timeSpentMs: z11.number().int().min(0).optional().describe(
1343
+ timeSpentMs: z12.number().int().min(0).optional().describe(
1220
1344
  "Milliseconds the respondent spent on this question (even split across all visible questions in the section)"
1221
1345
  ),
1222
- isPathTraversed: z11.boolean().optional().describe(
1346
+ isPathTraversed: z12.boolean().optional().describe(
1223
1347
  "Whether this question was on the logical traversal path \u2014 true for visible questions and hidden questions whose rules were evaluated, false for questions never reached"
1224
1348
  )
1225
1349
  }).describe("Response to a specific question in the feedback form");
1226
- var responseSchema = z11.object({
1227
- questions: z11.array(questionResponseSchema).min(1).describe("Array of question responses")
1350
+ var responseSchema = z12.object({
1351
+ questions: z12.array(questionResponseSchema).min(1).describe("Array of question responses")
1228
1352
  }).describe("User responses to feedback questions");
1229
- var matchedTriggerPropertiesSchema = z11.object({
1230
- customEventName: z11.string().nullable().describe("Custom event name that triggered the feedback"),
1231
- currentPath: z11.string().describe("Current page path where feedback was triggered"),
1232
- eventType: z11.string().describe("Type of event that triggered the feedback")
1353
+ var matchedTriggerPropertiesSchema = z12.object({
1354
+ customEventName: z12.string().nullable().describe("Custom event name that triggered the feedback"),
1355
+ currentPath: z12.string().describe("Current page path where feedback was triggered"),
1356
+ eventType: z12.string().describe("Type of event that triggered the feedback")
1233
1357
  }).passthrough().describe("Properties of the trigger that matched for this feedback");
1234
- var baseSubmitFeedbackSchema = z11.object({
1358
+ var baseSubmitFeedbackSchema = z12.object({
1235
1359
  formConfig: formConfigSchema.describe("Form configuration information"),
1236
1360
  deviceInfo: deviceInfoSchema.describe("Device information"),
1237
1361
  sessionInfo: sessionInfoSchema.optional().describe("Session information"),
@@ -1239,70 +1363,70 @@ var baseSubmitFeedbackSchema = z11.object({
1239
1363
  matchedTriggerProperties: matchedTriggerPropertiesSchema.optional().describe(
1240
1364
  "Properties of the matched trigger"
1241
1365
  ),
1242
- customProperties: z11.record(z11.string(), z11.unknown()).optional().describe("Custom properties for advanced use cases")
1366
+ customProperties: z12.record(z12.string(), z12.unknown()).optional().describe("Custom properties for advanced use cases")
1243
1367
  }).describe("Base submit feedback request schema");
1244
1368
  var partialFeedbackSchema = baseSubmitFeedbackSchema.extend({
1245
1369
  formConfig: formConfigSchema.extend({
1246
- isPartialSubmit: z11.literal(true).describe("Indicates this is a partial submission")
1370
+ isPartialSubmit: z12.literal(true).describe("Indicates this is a partial submission")
1247
1371
  }),
1248
1372
  response: responseSchema.optional().describe("User responses (optional for partial submit)")
1249
1373
  }).describe("Partial feedback request schema (response optional)");
1250
1374
  var submitFeedbackSchema = baseSubmitFeedbackSchema.extend({
1251
1375
  formConfig: formConfigSchema.extend({
1252
- isPartialSubmit: z11.literal(false).describe("Indicates this is a full submission")
1376
+ isPartialSubmit: z12.literal(false).describe("Indicates this is a full submission")
1253
1377
  }),
1254
1378
  response: responseSchema.describe("User responses (required for full submit)")
1255
1379
  }).describe("Full submit feedback request schema (response required)");
1256
- var feedbackRequestSchema = z11.union([partialFeedbackSchema, submitFeedbackSchema]).describe("Union schema for both partial and full feedback submissions");
1380
+ var feedbackRequestSchema = z12.union([partialFeedbackSchema, submitFeedbackSchema]).describe("Union schema for both partial and full feedback submissions");
1257
1381
 
1258
1382
  // src/schemas/api/fetch-feedback-schema.ts
1259
- import { z as z12 } from "zod";
1260
- var feedbackConfigurationItemSchema = z12.object({
1261
- feedbackConfigurationId: z12.string().uuid().describe("Unique identifier for the feedback configuration"),
1262
- feedbackTitle: z12.string().describe("Title of the feedback configuration"),
1383
+ import { z as z13 } from "zod";
1384
+ var feedbackConfigurationItemSchema = z13.object({
1385
+ feedbackConfigurationId: z13.string().uuid().describe("Unique identifier for the feedback configuration"),
1386
+ feedbackTitle: z13.string().describe("Title of the feedback configuration"),
1263
1387
  // duration: durationSchema
1264
1388
  // .describe("Active duration for this feedback configuration"),
1265
1389
  triggerProperties: audienceTriggerPropertiesSchema.describe(
1266
1390
  "Trigger properties including auto/manual settings and audience segments"
1267
1391
  ),
1268
- appearanceProperties: z12.object({
1269
- themes: z12.object({
1270
- light: z12.object({
1271
- theme: z12.string().optional().describe("Theme for light mode (shadcn variables JSON)")
1392
+ appearanceProperties: z13.object({
1393
+ themes: z13.object({
1394
+ light: z13.object({
1395
+ theme: z13.string().optional().describe("Theme for light mode (shadcn variables JSON)")
1272
1396
  }).describe("Light theme"),
1273
- dark: z12.object({
1274
- theme: z12.string().optional().describe("Theme for dark mode (shadcn variables JSON)")
1397
+ dark: z13.object({
1398
+ theme: z13.string().optional().describe("Theme for dark mode (shadcn variables JSON)")
1275
1399
  }).describe("Dark theme")
1276
1400
  }).nullable().optional().describe("Theme configuration (optional)"),
1277
- featureSettings: z12.object({
1278
- darkOverlay: z12.boolean().describe("Whether to show dark overlay"),
1279
- closeButton: z12.boolean().describe("Whether to show close button"),
1280
- progressBar: z12.boolean().describe("Whether to show progress bar"),
1281
- showBranding: z12.boolean().describe("Whether to show branding"),
1282
- customPosition: z12.boolean().describe("Whether custom position is enabled"),
1283
- customIconPosition: z12.boolean().describe("Whether custom icon position is enabled"),
1284
- customCss: z12.string().nullable().optional().describe("Custom CSS link (optional)"),
1285
- enableShareableKeyboardNavigation: z12.boolean().default(false).describe(
1401
+ featureSettings: z13.object({
1402
+ darkOverlay: z13.boolean().describe("Whether to show dark overlay"),
1403
+ closeButton: z13.boolean().describe("Whether to show close button"),
1404
+ progressBar: z13.boolean().describe("Whether to show progress bar"),
1405
+ showBranding: z13.boolean().describe("Whether to show branding"),
1406
+ customPosition: z13.boolean().describe("Whether custom position is enabled"),
1407
+ customIconPosition: z13.boolean().describe("Whether custom icon position is enabled"),
1408
+ customCss: z13.string().nullable().optional().describe("Custom CSS link (optional)"),
1409
+ enableShareableKeyboardNavigation: z13.boolean().default(false).describe(
1286
1410
  "Whether keyboard navigation is enabled for the shareable widget experience"
1287
1411
  ),
1288
- rtl: z12.boolean().describe("Whether right-to-left text direction is enabled"),
1289
- previousButton: z12.enum(["never", "always"]).describe("Previous button: never (hidden) or always (shown)")
1412
+ rtl: z13.boolean().describe("Whether right-to-left text direction is enabled"),
1413
+ previousButton: z13.enum(["never", "always"]).describe("Previous button: never (hidden) or always (shown)")
1290
1414
  }).describe("Feature settings for the feedback form"),
1291
- selectedIconPosition: z12.string().describe("Selected position for the feedback icon"),
1292
- selectedPosition: z12.string().describe("Selected position for the feedback form")
1415
+ selectedIconPosition: z13.string().describe("Selected position for the feedback icon"),
1416
+ selectedPosition: z13.string().describe("Selected position for the feedback form")
1293
1417
  }).describe("Appearance properties for the feedback form")
1294
1418
  }).describe("Individual feedback configuration item in the list");
1295
- var fetchFormConfigSchema = z12.object({
1296
- feedbackConfigurationId: z12.string().uuid().describe("Unique identifier for the feedback configuration"),
1297
- responseLanguageCode: z12.string().length(2).describe("Language code for the response (e.g., 'en', 'es')")
1419
+ var fetchFormConfigSchema = z13.object({
1420
+ feedbackConfigurationId: z13.string().uuid().describe("Unique identifier for the feedback configuration"),
1421
+ responseLanguageCode: z13.string().length(2).describe("Language code for the response (e.g., 'en', 'es')")
1298
1422
  }).describe("Form configuration for fetching feedback details");
1299
- var fetchConfigurationListSchema = z12.object({
1423
+ var fetchConfigurationListSchema = z13.object({
1300
1424
  deviceInfo: deviceInfoSchema.describe("Device information"),
1301
1425
  sessionInfo: sessionInfoSchema.describe("Session information"),
1302
1426
  userInfo: userInfoSchema.optional().describe("User information (optional)"),
1303
- force: z12.boolean().optional().describe("Forcefully fetch eligible feedback list (optional)")
1427
+ force: z13.boolean().optional().describe("Forcefully fetch eligible feedback list (optional)")
1304
1428
  }).strict().describe("Request schema for fetching available feedback configurations");
1305
- var fetchFeedbackDetailsSchema = z12.object({
1429
+ var fetchFeedbackDetailsSchema = z13.object({
1306
1430
  formConfig: fetchFormConfigSchema.describe(
1307
1431
  "Form configuration for the specific feedback"
1308
1432
  ),
@@ -1310,40 +1434,40 @@ var fetchFeedbackDetailsSchema = z12.object({
1310
1434
  sessionInfo: sessionInfoSchema.describe("Session information"),
1311
1435
  userInfo: userInfoSchema.optional().describe("User information (optional)")
1312
1436
  }).strict().describe("Request schema for fetching specific feedback form details");
1313
- var formConfigurationResponseSchema = z12.object({
1314
- formTitle: z12.string().describe("Title of the feedback form"),
1315
- formDescription: z12.string().describe("Description of the feedback form")
1437
+ var formConfigurationResponseSchema = z13.object({
1438
+ formTitle: z13.string().describe("Title of the feedback form"),
1439
+ formDescription: z13.string().describe("Description of the feedback form")
1316
1440
  }).describe("Form configuration response with title and description");
1317
- var logicJumpRuleSchema = z12.object({
1318
- jsonLogic: z12.record(z12.string(), z12.unknown()).describe("JSON Logic expression to evaluate"),
1319
- targetQuestionId: z12.string().describe("Question ID to navigate to when this rule matches")
1441
+ var logicJumpRuleSchema = z13.object({
1442
+ jsonLogic: z13.record(z13.string(), z13.unknown()).describe("JSON Logic expression to evaluate"),
1443
+ targetQuestionId: z13.string().describe("Question ID to navigate to when this rule matches")
1320
1444
  }).describe("A single logic jump rule mapping a condition to a target question");
1321
- var logicJumpRulesSchema = z12.record(
1322
- z12.string(),
1323
- z12.array(logicJumpRuleSchema)
1445
+ var logicJumpRulesSchema = z13.record(
1446
+ z13.string(),
1447
+ z13.array(logicJumpRuleSchema)
1324
1448
  ).describe(
1325
1449
  "Logic jump rules keyed by question ID (or '__workflow_start__'). Each entry is an ordered array of rules evaluated top-down; the first matching rule wins."
1326
1450
  );
1327
- var questionnaireFieldsResponseSchema = z12.object({
1328
- questions: z12.record(z12.string(), combinedQuestionSchema).describe("Collection of questions keyed by their string identifiers"),
1329
- sections: z12.array(sectionSchema).describe(
1451
+ var questionnaireFieldsResponseSchema = z13.object({
1452
+ questions: z13.record(z13.string(), combinedQuestionSchema).describe("Collection of questions keyed by their string identifiers"),
1453
+ sections: z13.array(sectionSchema).describe(
1330
1454
  "Array of sections that organize questions into logical groups"
1331
1455
  ),
1332
- translations: z12.record(z12.string(), z12.any()).describe(
1456
+ translations: z13.record(z13.string(), z13.any()).describe(
1333
1457
  "Translations object (can be empty or contain language-specific translations)"
1334
1458
  ),
1335
1459
  selectedLanguages: LanguagesSchema.describe(
1336
1460
  "Array of languages selected for this questionnaire"
1337
1461
  ),
1338
- isLogicJumpsEnabled: z12.boolean().optional().default(false).describe("When true, form navigation follows logicJumpRules instead of linear section order"),
1462
+ isLogicJumpsEnabled: z13.boolean().optional().default(false).describe("When true, form navigation follows logicJumpRules instead of linear section order"),
1339
1463
  logicJumpRules: logicJumpRulesSchema.optional().describe("Conditional navigation rules evaluated per question to determine the next question to show"),
1340
- contextVariables: z12.array(z12.string()).optional().describe("List of context variable keys expected by the form (informational)")
1464
+ contextVariables: z13.array(z13.string()).optional().describe("List of context variable keys expected by the form (informational)")
1341
1465
  }).describe(
1342
1466
  "Questionnaire fields response including questions, sections, translations, selected languages, and optional logic jump configuration"
1343
1467
  );
1344
- var fetchFeedbackDetailsResponseSchema = z12.object({
1345
- feedbackConfigurationId: z12.string().uuid().describe("Unique identifier for the feedback configuration"),
1346
- feedbackIdentifier: z12.string().uuid().describe("Unique identifier for this specific feedback instance"),
1468
+ var fetchFeedbackDetailsResponseSchema = z13.object({
1469
+ feedbackConfigurationId: z13.string().uuid().describe("Unique identifier for the feedback configuration"),
1470
+ feedbackIdentifier: z13.string().uuid().describe("Unique identifier for this specific feedback instance"),
1347
1471
  formConfiguration: formConfigurationResponseSchema.describe(
1348
1472
  "Form configuration with title and description"
1349
1473
  ),
@@ -1359,30 +1483,30 @@ var fetchFeedbackDetailsResponseSchema = z12.object({
1359
1483
  }).strict().describe(
1360
1484
  "Complete response schema for fetchFeedbackDetails API using existing field schemas"
1361
1485
  );
1362
- var fetchConfigurationListResponseSchema = z12.object({
1486
+ var fetchConfigurationListResponseSchema = z13.object({
1363
1487
  masterProperties: masterPropertiesSchema.describe(
1364
1488
  "Master properties for global survey settings"
1365
1489
  ),
1366
- feedbackConfiguration: z12.array(feedbackConfigurationItemSchema).describe("Array of available feedback configurations")
1490
+ feedbackConfiguration: z13.array(feedbackConfigurationItemSchema).describe("Array of available feedback configurations")
1367
1491
  }).strict().describe("Response schema for fetchConfigurationList API");
1368
1492
 
1369
1493
  // src/schemas/api/refine-text-schema.ts
1370
- import { z as z13 } from "zod";
1371
- var refineTextParamsSchema = z13.object({
1372
- questionId: z13.string().describe("Unique identifier for the question"),
1373
- feedbackConfigurationId: z13.string().uuid().describe("Unique identifier for the feedback configuration"),
1374
- userText: z13.string().describe("Original text input from the user")
1494
+ import { z as z14 } from "zod";
1495
+ var refineTextParamsSchema = z14.object({
1496
+ questionId: z14.string().describe("Unique identifier for the question"),
1497
+ feedbackConfigurationId: z14.string().uuid().describe("Unique identifier for the feedback configuration"),
1498
+ userText: z14.string().describe("Original text input from the user")
1375
1499
  }).strict().describe("Request schema for refining user text input");
1376
- var refineTextResponseSchema = z13.object({
1377
- message: z13.string().optional().describe("Human-readable message"),
1378
- refinedText: z13.string().optional().describe("Refined/improved version of the user text (success only)"),
1379
- status: z13.number().optional().describe("HTTP status code (error responses)"),
1380
- error: z13.string().optional().describe("Error type (error responses)"),
1381
- code: z13.string().optional().describe("Error code for display mapping")
1500
+ var refineTextResponseSchema = z14.object({
1501
+ message: z14.string().optional().describe("Human-readable message"),
1502
+ refinedText: z14.string().optional().describe("Refined/improved version of the user text (success only)"),
1503
+ status: z14.number().optional().describe("HTTP status code (error responses)"),
1504
+ error: z14.string().optional().describe("Error type (error responses)"),
1505
+ code: z14.string().optional().describe("Error code for display mapping")
1382
1506
  }).describe("Response schema for refine text API operation");
1383
- var refineTextDataSchema = z13.object({
1384
- userText: z13.string().describe("Original text input from the user"),
1385
- refinedText: z13.string().describe("Refined/improved version of the user text")
1507
+ var refineTextDataSchema = z14.object({
1508
+ userText: z14.string().describe("Original text input from the user"),
1509
+ refinedText: z14.string().describe("Refined/improved version of the user text")
1386
1510
  }).describe("Data containing original and refined text (legacy nested format)");
1387
1511
 
1388
1512
  // src/helpers/case-convert-helper.ts
@@ -1448,13 +1572,13 @@ function objectToPascal(obj) {
1448
1572
  __name(objectToPascal, "objectToPascal");
1449
1573
 
1450
1574
  // src/schemas/fields/app-props-schema.ts
1451
- import { z as z14 } from "zod";
1452
- var currentModeSchema = z14.enum(["light", "dark"]).describe("Current theme mode of the application");
1575
+ import { z as z15 } from "zod";
1576
+ var currentModeSchema = z15.enum(["light", "dark"]).describe("Current theme mode of the application");
1453
1577
  var CurrentModes = {
1454
1578
  LIGHT: "light",
1455
1579
  DARK: "dark"
1456
1580
  };
1457
- var appPropsSchema = z14.object({
1581
+ var appPropsSchema = z15.object({
1458
1582
  theme: themesSchema.describe(
1459
1583
  "Theme configuration including light and dark theme colors"
1460
1584
  ),
@@ -1464,7 +1588,7 @@ var appPropsSchema = z14.object({
1464
1588
  currentLanguage: LanguageFieldSchema.describe(
1465
1589
  "Currently selected language configuration"
1466
1590
  ),
1467
- questions: z14.record(z14.string(), combinedQuestionSchema).describe("Collection of questions keyed by their string identifiers"),
1591
+ questions: z15.record(z15.string(), combinedQuestionSchema).describe("Collection of questions keyed by their string identifiers"),
1468
1592
  questionLanguages: LanguagesSchema.describe(
1469
1593
  "Available languages for questions"
1470
1594
  ),
@@ -1474,15 +1598,15 @@ var appPropsSchema = z14.object({
1474
1598
  translations: translationsSchema.optional().describe(
1475
1599
  "Multi-language translations for questions and form content (optional)"
1476
1600
  ),
1477
- onSectionChange: z14.function({
1478
- input: [z14.number()],
1479
- output: z14.void()
1601
+ onSectionChange: z15.function({
1602
+ input: [z15.number()],
1603
+ output: z15.void()
1480
1604
  }).optional().describe("Optional callback function triggered when section changes"),
1481
- onClose: z14.function({
1605
+ onClose: z15.function({
1482
1606
  input: [],
1483
- output: z14.void()
1607
+ output: z15.void()
1484
1608
  }).optional().describe("Optional callback function triggered when the form is closed"),
1485
- sections: z14.array(sectionSchema).describe(
1609
+ sections: z15.array(sectionSchema).describe(
1486
1610
  "Array of sections that organize questions into logical groups"
1487
1611
  ),
1488
1612
  themeSettings: themeConfigurationSchema.describe(
@@ -1493,7 +1617,7 @@ var appPropsSchema = z14.object({
1493
1617
  );
1494
1618
 
1495
1619
  // src/index.ts
1496
- import { z as z15 } from "zod";
1620
+ import { z as z16 } from "zod";
1497
1621
  export {
1498
1622
  AnnotationMarkerSchema,
1499
1623
  AnnotationSchema,
@@ -1504,6 +1628,8 @@ export {
1504
1628
  DeviceThemes,
1505
1629
  LanguageFieldSchema,
1506
1630
  LanguagesSchema,
1631
+ LayoutAttachmentTypes,
1632
+ LayoutTypes,
1507
1633
  MultipleChoiceDisplayStyles,
1508
1634
  MultipleChoiceMultipleDisplayStyles,
1509
1635
  OtherFieldsSchema,
@@ -1531,6 +1657,7 @@ export {
1531
1657
  baseSubmitFeedbackSchema,
1532
1658
  categorySpecificFiltersSchema,
1533
1659
  choiceOrderOptionSchema,
1660
+ colorAttachmentSchema,
1534
1661
  combinedQuestionSchema,
1535
1662
  conditionalIfMetadataSchema,
1536
1663
  conditionalIfSchema,
@@ -1556,9 +1683,15 @@ export {
1556
1683
  fetchFeedbackDetailsSchema,
1557
1684
  fetchFormConfigSchema,
1558
1685
  filterConditionSchema,
1686
+ floatLayoutSchema,
1687
+ focalPointSchema,
1559
1688
  formConfigSchema,
1560
1689
  formConfigurationResponseSchema,
1561
1690
  formPropertiesSchema,
1691
+ gradientAttachmentSchema,
1692
+ imageAttachmentSchema,
1693
+ layoutAttachmentSchema,
1694
+ layoutSurfaceSchema,
1562
1695
  logicJumpRuleSchema,
1563
1696
  logicJumpRulesSchema,
1564
1697
  longAnswerQuestionSchema,
@@ -1614,6 +1747,8 @@ export {
1614
1747
  refineTextParamsSchema,
1615
1748
  refineTextResponseSchema,
1616
1749
  responseSchema,
1750
+ sectionLayoutSchema,
1751
+ sectionLayoutVariantSchema,
1617
1752
  sectionSchema,
1618
1753
  sectionTranslationSchema,
1619
1754
  sectionTranslationsByLanguageSchema,
@@ -1622,6 +1757,8 @@ export {
1622
1757
  shortAnswerQuestionSchema,
1623
1758
  shortAnswerQuestionTranslationSchema,
1624
1759
  singleChoiceQuestionTranslationSchema,
1760
+ splitLayoutSchema,
1761
+ stackLayoutSchema,
1625
1762
  submitFeedbackSchema,
1626
1763
  thankYouQuestionSchema,
1627
1764
  thankYouQuestionTranslationSchema,
@@ -1639,13 +1776,15 @@ export {
1639
1776
  userPropertiesSchema,
1640
1777
  validationRuleSchema,
1641
1778
  validationRuleTypeSchema,
1779
+ videoAttachmentSchema,
1642
1780
  visibilityConditionSchema,
1781
+ wallpaperLayoutSchema,
1643
1782
  welcomeQuestionSchema,
1644
1783
  welcomeQuestionTranslationSchema,
1645
1784
  whoSchema,
1646
1785
  yesNoDisplayStyleSchema,
1647
1786
  yesNoQuestionSchema,
1648
1787
  yesNoQuestionTranslationSchema,
1649
- z15 as z
1788
+ z16 as z
1650
1789
  };
1651
1790
  //# sourceMappingURL=index.js.map