@encatch/schema 0.0.1

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.
Files changed (52) hide show
  1. package/README.md +7 -0
  2. package/dist/cjs/index.js +30 -0
  3. package/dist/cjs/index.js.map +1 -0
  4. package/dist/cjs/schemas/fields/answer-schema.js +103 -0
  5. package/dist/cjs/schemas/fields/answer-schema.js.map +1 -0
  6. package/dist/cjs/schemas/fields/auto-trigger-schema.js +49 -0
  7. package/dist/cjs/schemas/fields/auto-trigger-schema.js.map +1 -0
  8. package/dist/cjs/schemas/fields/field-schema.js +678 -0
  9. package/dist/cjs/schemas/fields/field-schema.js.map +1 -0
  10. package/dist/cjs/schemas/fields/form-properties-schema.js +136 -0
  11. package/dist/cjs/schemas/fields/form-properties-schema.js.map +1 -0
  12. package/dist/cjs/schemas/fields/form-schema.js +123 -0
  13. package/dist/cjs/schemas/fields/form-schema.js.map +1 -0
  14. package/dist/cjs/schemas/fields/other-screen-schema.js +169 -0
  15. package/dist/cjs/schemas/fields/other-screen-schema.js.map +1 -0
  16. package/dist/cjs/schemas/fields/theme-schema.js +85 -0
  17. package/dist/cjs/schemas/fields/theme-schema.js.map +1 -0
  18. package/dist/cjs/schemas/fields/translations-example.js +187 -0
  19. package/dist/cjs/schemas/fields/translations-example.js.map +1 -0
  20. package/dist/cjs/schemas/fields/translations-schema.js +198 -0
  21. package/dist/cjs/schemas/fields/translations-schema.js.map +1 -0
  22. package/dist/esm/index.js +12 -0
  23. package/dist/esm/index.js.map +1 -0
  24. package/dist/esm/schemas/fields/answer-schema.js +100 -0
  25. package/dist/esm/schemas/fields/answer-schema.js.map +1 -0
  26. package/dist/esm/schemas/fields/auto-trigger-schema.js +46 -0
  27. package/dist/esm/schemas/fields/auto-trigger-schema.js.map +1 -0
  28. package/dist/esm/schemas/fields/field-schema.js +675 -0
  29. package/dist/esm/schemas/fields/field-schema.js.map +1 -0
  30. package/dist/esm/schemas/fields/form-properties-schema.js +133 -0
  31. package/dist/esm/schemas/fields/form-properties-schema.js.map +1 -0
  32. package/dist/esm/schemas/fields/form-schema.js +120 -0
  33. package/dist/esm/schemas/fields/form-schema.js.map +1 -0
  34. package/dist/esm/schemas/fields/other-screen-schema.js +166 -0
  35. package/dist/esm/schemas/fields/other-screen-schema.js.map +1 -0
  36. package/dist/esm/schemas/fields/theme-schema.js +82 -0
  37. package/dist/esm/schemas/fields/theme-schema.js.map +1 -0
  38. package/dist/esm/schemas/fields/translations-example.js +181 -0
  39. package/dist/esm/schemas/fields/translations-example.js.map +1 -0
  40. package/dist/esm/schemas/fields/translations-schema.js +193 -0
  41. package/dist/esm/schemas/fields/translations-schema.js.map +1 -0
  42. package/dist/types/index.d.ts +9 -0
  43. package/dist/types/schemas/fields/answer-schema.d.ts +77 -0
  44. package/dist/types/schemas/fields/auto-trigger-schema.d.ts +21 -0
  45. package/dist/types/schemas/fields/field-schema.d.ts +1114 -0
  46. package/dist/types/schemas/fields/form-properties-schema.d.ts +1035 -0
  47. package/dist/types/schemas/fields/form-schema.d.ts +68 -0
  48. package/dist/types/schemas/fields/other-screen-schema.d.ts +58 -0
  49. package/dist/types/schemas/fields/theme-schema.d.ts +91 -0
  50. package/dist/types/schemas/fields/translations-example.d.ts +10 -0
  51. package/dist/types/schemas/fields/translations-schema.d.ts +863 -0
  52. package/package.json +33 -0
@@ -0,0 +1,863 @@
1
+ import { z } from "zod";
2
+ export declare const translationEntrySchema: z.ZodObject<{
3
+ text: z.ZodString;
4
+ context: z.ZodOptional<z.ZodString>;
5
+ }, z.core.$strip>;
6
+ export declare const ratingTranslationsSchema: z.ZodObject<{
7
+ title: z.ZodObject<{
8
+ text: z.ZodString;
9
+ context: z.ZodOptional<z.ZodString>;
10
+ }, z.core.$strip>;
11
+ description: z.ZodOptional<z.ZodObject<{
12
+ text: z.ZodString;
13
+ context: z.ZodOptional<z.ZodString>;
14
+ }, z.core.$strip>>;
15
+ errorMessage: z.ZodOptional<z.ZodObject<{
16
+ text: z.ZodString;
17
+ context: z.ZodOptional<z.ZodString>;
18
+ }, z.core.$strip>>;
19
+ minLabel: z.ZodOptional<z.ZodObject<{
20
+ text: z.ZodString;
21
+ context: z.ZodOptional<z.ZodString>;
22
+ }, z.core.$strip>>;
23
+ maxLabel: z.ZodOptional<z.ZodObject<{
24
+ text: z.ZodString;
25
+ context: z.ZodOptional<z.ZodString>;
26
+ }, z.core.$strip>>;
27
+ }, z.core.$strip>;
28
+ export declare const singleChoiceTranslationsSchema: z.ZodObject<{
29
+ title: z.ZodObject<{
30
+ text: z.ZodString;
31
+ context: z.ZodOptional<z.ZodString>;
32
+ }, z.core.$strip>;
33
+ description: z.ZodOptional<z.ZodObject<{
34
+ text: z.ZodString;
35
+ context: z.ZodOptional<z.ZodString>;
36
+ }, z.core.$strip>>;
37
+ errorMessage: z.ZodOptional<z.ZodObject<{
38
+ text: z.ZodString;
39
+ context: z.ZodOptional<z.ZodString>;
40
+ }, z.core.$strip>>;
41
+ placeholder: z.ZodOptional<z.ZodObject<{
42
+ text: z.ZodString;
43
+ context: z.ZodOptional<z.ZodString>;
44
+ }, z.core.$strip>>;
45
+ options: z.ZodRecord<z.ZodString, z.ZodObject<{
46
+ label: z.ZodObject<{
47
+ text: z.ZodString;
48
+ context: z.ZodOptional<z.ZodString>;
49
+ }, z.core.$strip>;
50
+ hint: z.ZodOptional<z.ZodObject<{
51
+ text: z.ZodString;
52
+ context: z.ZodOptional<z.ZodString>;
53
+ }, z.core.$strip>>;
54
+ }, z.core.$strip>>;
55
+ }, z.core.$strip>;
56
+ export declare const multipleChoiceTranslationsSchema: z.ZodObject<{
57
+ title: z.ZodObject<{
58
+ text: z.ZodString;
59
+ context: z.ZodOptional<z.ZodString>;
60
+ }, z.core.$strip>;
61
+ description: z.ZodOptional<z.ZodObject<{
62
+ text: z.ZodString;
63
+ context: z.ZodOptional<z.ZodString>;
64
+ }, z.core.$strip>>;
65
+ errorMessage: z.ZodOptional<z.ZodObject<{
66
+ text: z.ZodString;
67
+ context: z.ZodOptional<z.ZodString>;
68
+ }, z.core.$strip>>;
69
+ placeholder: z.ZodOptional<z.ZodObject<{
70
+ text: z.ZodString;
71
+ context: z.ZodOptional<z.ZodString>;
72
+ }, z.core.$strip>>;
73
+ options: z.ZodRecord<z.ZodString, z.ZodObject<{
74
+ label: z.ZodObject<{
75
+ text: z.ZodString;
76
+ context: z.ZodOptional<z.ZodString>;
77
+ }, z.core.$strip>;
78
+ hint: z.ZodOptional<z.ZodObject<{
79
+ text: z.ZodString;
80
+ context: z.ZodOptional<z.ZodString>;
81
+ }, z.core.$strip>>;
82
+ }, z.core.$strip>>;
83
+ }, z.core.$strip>;
84
+ export declare const npsTranslationsSchema: z.ZodObject<{
85
+ title: z.ZodObject<{
86
+ text: z.ZodString;
87
+ context: z.ZodOptional<z.ZodString>;
88
+ }, z.core.$strip>;
89
+ description: z.ZodOptional<z.ZodObject<{
90
+ text: z.ZodString;
91
+ context: z.ZodOptional<z.ZodString>;
92
+ }, z.core.$strip>>;
93
+ errorMessage: z.ZodOptional<z.ZodObject<{
94
+ text: z.ZodString;
95
+ context: z.ZodOptional<z.ZodString>;
96
+ }, z.core.$strip>>;
97
+ minLabel: z.ZodOptional<z.ZodObject<{
98
+ text: z.ZodString;
99
+ context: z.ZodOptional<z.ZodString>;
100
+ }, z.core.$strip>>;
101
+ maxLabel: z.ZodOptional<z.ZodObject<{
102
+ text: z.ZodString;
103
+ context: z.ZodOptional<z.ZodString>;
104
+ }, z.core.$strip>>;
105
+ scaleLabels: z.ZodOptional<z.ZodRecord<z.ZodNumber, z.ZodObject<{
106
+ text: z.ZodString;
107
+ context: z.ZodOptional<z.ZodString>;
108
+ }, z.core.$strip>>>;
109
+ }, z.core.$strip>;
110
+ export declare const shortAnswerTranslationsSchema: z.ZodObject<{
111
+ title: z.ZodObject<{
112
+ text: z.ZodString;
113
+ context: z.ZodOptional<z.ZodString>;
114
+ }, z.core.$strip>;
115
+ description: z.ZodOptional<z.ZodObject<{
116
+ text: z.ZodString;
117
+ context: z.ZodOptional<z.ZodString>;
118
+ }, z.core.$strip>>;
119
+ errorMessage: z.ZodOptional<z.ZodObject<{
120
+ text: z.ZodString;
121
+ context: z.ZodOptional<z.ZodString>;
122
+ }, z.core.$strip>>;
123
+ placeholder: z.ZodOptional<z.ZodObject<{
124
+ text: z.ZodString;
125
+ context: z.ZodOptional<z.ZodString>;
126
+ }, z.core.$strip>>;
127
+ }, z.core.$strip>;
128
+ export declare const longAnswerTranslationsSchema: z.ZodObject<{
129
+ title: z.ZodObject<{
130
+ text: z.ZodString;
131
+ context: z.ZodOptional<z.ZodString>;
132
+ }, z.core.$strip>;
133
+ description: z.ZodOptional<z.ZodObject<{
134
+ text: z.ZodString;
135
+ context: z.ZodOptional<z.ZodString>;
136
+ }, z.core.$strip>>;
137
+ errorMessage: z.ZodOptional<z.ZodObject<{
138
+ text: z.ZodString;
139
+ context: z.ZodOptional<z.ZodString>;
140
+ }, z.core.$strip>>;
141
+ placeholder: z.ZodOptional<z.ZodObject<{
142
+ text: z.ZodString;
143
+ context: z.ZodOptional<z.ZodString>;
144
+ }, z.core.$strip>>;
145
+ }, z.core.$strip>;
146
+ export declare const nestedSelectionTranslationsSchema: z.ZodObject<{
147
+ title: z.ZodObject<{
148
+ text: z.ZodString;
149
+ context: z.ZodOptional<z.ZodString>;
150
+ }, z.core.$strip>;
151
+ description: z.ZodOptional<z.ZodObject<{
152
+ text: z.ZodString;
153
+ context: z.ZodOptional<z.ZodString>;
154
+ }, z.core.$strip>>;
155
+ errorMessage: z.ZodOptional<z.ZodObject<{
156
+ text: z.ZodString;
157
+ context: z.ZodOptional<z.ZodString>;
158
+ }, z.core.$strip>>;
159
+ placeholder: z.ZodOptional<z.ZodObject<{
160
+ text: z.ZodString;
161
+ context: z.ZodOptional<z.ZodString>;
162
+ }, z.core.$strip>>;
163
+ nestedOptions: z.ZodRecord<z.ZodString, z.ZodObject<{
164
+ label: z.ZodObject<{
165
+ text: z.ZodString;
166
+ context: z.ZodOptional<z.ZodString>;
167
+ }, z.core.$strip>;
168
+ hint: z.ZodOptional<z.ZodObject<{
169
+ text: z.ZodString;
170
+ context: z.ZodOptional<z.ZodString>;
171
+ }, z.core.$strip>>;
172
+ }, z.core.$strip>>;
173
+ }, z.core.$strip>;
174
+ export declare const annotationTranslationsSchema: z.ZodObject<{
175
+ title: z.ZodObject<{
176
+ text: z.ZodString;
177
+ context: z.ZodOptional<z.ZodString>;
178
+ }, z.core.$strip>;
179
+ description: z.ZodOptional<z.ZodObject<{
180
+ text: z.ZodString;
181
+ context: z.ZodOptional<z.ZodString>;
182
+ }, z.core.$strip>>;
183
+ errorMessage: z.ZodOptional<z.ZodObject<{
184
+ text: z.ZodString;
185
+ context: z.ZodOptional<z.ZodString>;
186
+ }, z.core.$strip>>;
187
+ annotationText: z.ZodOptional<z.ZodObject<{
188
+ text: z.ZodString;
189
+ context: z.ZodOptional<z.ZodString>;
190
+ }, z.core.$strip>>;
191
+ noAnnotationText: z.ZodOptional<z.ZodObject<{
192
+ text: z.ZodString;
193
+ context: z.ZodOptional<z.ZodString>;
194
+ }, z.core.$strip>>;
195
+ }, z.core.$strip>;
196
+ export declare const questionTranslationsSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
197
+ type: z.ZodLiteral<"rating">;
198
+ translations: z.ZodObject<{
199
+ title: z.ZodObject<{
200
+ text: z.ZodString;
201
+ context: z.ZodOptional<z.ZodString>;
202
+ }, z.core.$strip>;
203
+ description: z.ZodOptional<z.ZodObject<{
204
+ text: z.ZodString;
205
+ context: z.ZodOptional<z.ZodString>;
206
+ }, z.core.$strip>>;
207
+ errorMessage: z.ZodOptional<z.ZodObject<{
208
+ text: z.ZodString;
209
+ context: z.ZodOptional<z.ZodString>;
210
+ }, z.core.$strip>>;
211
+ minLabel: z.ZodOptional<z.ZodObject<{
212
+ text: z.ZodString;
213
+ context: z.ZodOptional<z.ZodString>;
214
+ }, z.core.$strip>>;
215
+ maxLabel: z.ZodOptional<z.ZodObject<{
216
+ text: z.ZodString;
217
+ context: z.ZodOptional<z.ZodString>;
218
+ }, z.core.$strip>>;
219
+ }, z.core.$strip>;
220
+ }, z.core.$strip>, z.ZodObject<{
221
+ type: z.ZodLiteral<"single_choice">;
222
+ translations: z.ZodObject<{
223
+ title: z.ZodObject<{
224
+ text: z.ZodString;
225
+ context: z.ZodOptional<z.ZodString>;
226
+ }, z.core.$strip>;
227
+ description: z.ZodOptional<z.ZodObject<{
228
+ text: z.ZodString;
229
+ context: z.ZodOptional<z.ZodString>;
230
+ }, z.core.$strip>>;
231
+ errorMessage: z.ZodOptional<z.ZodObject<{
232
+ text: z.ZodString;
233
+ context: z.ZodOptional<z.ZodString>;
234
+ }, z.core.$strip>>;
235
+ placeholder: z.ZodOptional<z.ZodObject<{
236
+ text: z.ZodString;
237
+ context: z.ZodOptional<z.ZodString>;
238
+ }, z.core.$strip>>;
239
+ options: z.ZodRecord<z.ZodString, z.ZodObject<{
240
+ label: z.ZodObject<{
241
+ text: z.ZodString;
242
+ context: z.ZodOptional<z.ZodString>;
243
+ }, z.core.$strip>;
244
+ hint: z.ZodOptional<z.ZodObject<{
245
+ text: z.ZodString;
246
+ context: z.ZodOptional<z.ZodString>;
247
+ }, z.core.$strip>>;
248
+ }, z.core.$strip>>;
249
+ }, z.core.$strip>;
250
+ }, z.core.$strip>, z.ZodObject<{
251
+ type: z.ZodLiteral<"multiple_choice_multiple">;
252
+ translations: z.ZodObject<{
253
+ title: z.ZodObject<{
254
+ text: z.ZodString;
255
+ context: z.ZodOptional<z.ZodString>;
256
+ }, z.core.$strip>;
257
+ description: z.ZodOptional<z.ZodObject<{
258
+ text: z.ZodString;
259
+ context: z.ZodOptional<z.ZodString>;
260
+ }, z.core.$strip>>;
261
+ errorMessage: z.ZodOptional<z.ZodObject<{
262
+ text: z.ZodString;
263
+ context: z.ZodOptional<z.ZodString>;
264
+ }, z.core.$strip>>;
265
+ placeholder: z.ZodOptional<z.ZodObject<{
266
+ text: z.ZodString;
267
+ context: z.ZodOptional<z.ZodString>;
268
+ }, z.core.$strip>>;
269
+ options: z.ZodRecord<z.ZodString, z.ZodObject<{
270
+ label: z.ZodObject<{
271
+ text: z.ZodString;
272
+ context: z.ZodOptional<z.ZodString>;
273
+ }, z.core.$strip>;
274
+ hint: z.ZodOptional<z.ZodObject<{
275
+ text: z.ZodString;
276
+ context: z.ZodOptional<z.ZodString>;
277
+ }, z.core.$strip>>;
278
+ }, z.core.$strip>>;
279
+ }, z.core.$strip>;
280
+ }, z.core.$strip>, z.ZodObject<{
281
+ type: z.ZodLiteral<"nps">;
282
+ translations: z.ZodObject<{
283
+ title: z.ZodObject<{
284
+ text: z.ZodString;
285
+ context: z.ZodOptional<z.ZodString>;
286
+ }, z.core.$strip>;
287
+ description: z.ZodOptional<z.ZodObject<{
288
+ text: z.ZodString;
289
+ context: z.ZodOptional<z.ZodString>;
290
+ }, z.core.$strip>>;
291
+ errorMessage: z.ZodOptional<z.ZodObject<{
292
+ text: z.ZodString;
293
+ context: z.ZodOptional<z.ZodString>;
294
+ }, z.core.$strip>>;
295
+ minLabel: z.ZodOptional<z.ZodObject<{
296
+ text: z.ZodString;
297
+ context: z.ZodOptional<z.ZodString>;
298
+ }, z.core.$strip>>;
299
+ maxLabel: z.ZodOptional<z.ZodObject<{
300
+ text: z.ZodString;
301
+ context: z.ZodOptional<z.ZodString>;
302
+ }, z.core.$strip>>;
303
+ scaleLabels: z.ZodOptional<z.ZodRecord<z.ZodNumber, z.ZodObject<{
304
+ text: z.ZodString;
305
+ context: z.ZodOptional<z.ZodString>;
306
+ }, z.core.$strip>>>;
307
+ }, z.core.$strip>;
308
+ }, z.core.$strip>, z.ZodObject<{
309
+ type: z.ZodLiteral<"short_answer">;
310
+ translations: z.ZodObject<{
311
+ title: z.ZodObject<{
312
+ text: z.ZodString;
313
+ context: z.ZodOptional<z.ZodString>;
314
+ }, z.core.$strip>;
315
+ description: z.ZodOptional<z.ZodObject<{
316
+ text: z.ZodString;
317
+ context: z.ZodOptional<z.ZodString>;
318
+ }, z.core.$strip>>;
319
+ errorMessage: z.ZodOptional<z.ZodObject<{
320
+ text: z.ZodString;
321
+ context: z.ZodOptional<z.ZodString>;
322
+ }, z.core.$strip>>;
323
+ placeholder: z.ZodOptional<z.ZodObject<{
324
+ text: z.ZodString;
325
+ context: z.ZodOptional<z.ZodString>;
326
+ }, z.core.$strip>>;
327
+ }, z.core.$strip>;
328
+ }, z.core.$strip>, z.ZodObject<{
329
+ type: z.ZodLiteral<"long_text">;
330
+ translations: z.ZodObject<{
331
+ title: z.ZodObject<{
332
+ text: z.ZodString;
333
+ context: z.ZodOptional<z.ZodString>;
334
+ }, z.core.$strip>;
335
+ description: z.ZodOptional<z.ZodObject<{
336
+ text: z.ZodString;
337
+ context: z.ZodOptional<z.ZodString>;
338
+ }, z.core.$strip>>;
339
+ errorMessage: z.ZodOptional<z.ZodObject<{
340
+ text: z.ZodString;
341
+ context: z.ZodOptional<z.ZodString>;
342
+ }, z.core.$strip>>;
343
+ placeholder: z.ZodOptional<z.ZodObject<{
344
+ text: z.ZodString;
345
+ context: z.ZodOptional<z.ZodString>;
346
+ }, z.core.$strip>>;
347
+ }, z.core.$strip>;
348
+ }, z.core.$strip>, z.ZodObject<{
349
+ type: z.ZodLiteral<"nested_selection">;
350
+ translations: z.ZodObject<{
351
+ title: z.ZodObject<{
352
+ text: z.ZodString;
353
+ context: z.ZodOptional<z.ZodString>;
354
+ }, z.core.$strip>;
355
+ description: z.ZodOptional<z.ZodObject<{
356
+ text: z.ZodString;
357
+ context: z.ZodOptional<z.ZodString>;
358
+ }, z.core.$strip>>;
359
+ errorMessage: z.ZodOptional<z.ZodObject<{
360
+ text: z.ZodString;
361
+ context: z.ZodOptional<z.ZodString>;
362
+ }, z.core.$strip>>;
363
+ placeholder: z.ZodOptional<z.ZodObject<{
364
+ text: z.ZodString;
365
+ context: z.ZodOptional<z.ZodString>;
366
+ }, z.core.$strip>>;
367
+ nestedOptions: z.ZodRecord<z.ZodString, z.ZodObject<{
368
+ label: z.ZodObject<{
369
+ text: z.ZodString;
370
+ context: z.ZodOptional<z.ZodString>;
371
+ }, z.core.$strip>;
372
+ hint: z.ZodOptional<z.ZodObject<{
373
+ text: z.ZodString;
374
+ context: z.ZodOptional<z.ZodString>;
375
+ }, z.core.$strip>>;
376
+ }, z.core.$strip>>;
377
+ }, z.core.$strip>;
378
+ }, z.core.$strip>, z.ZodObject<{
379
+ type: z.ZodLiteral<"annotation">;
380
+ translations: z.ZodObject<{
381
+ title: z.ZodObject<{
382
+ text: z.ZodString;
383
+ context: z.ZodOptional<z.ZodString>;
384
+ }, z.core.$strip>;
385
+ description: z.ZodOptional<z.ZodObject<{
386
+ text: z.ZodString;
387
+ context: z.ZodOptional<z.ZodString>;
388
+ }, z.core.$strip>>;
389
+ errorMessage: z.ZodOptional<z.ZodObject<{
390
+ text: z.ZodString;
391
+ context: z.ZodOptional<z.ZodString>;
392
+ }, z.core.$strip>>;
393
+ annotationText: z.ZodOptional<z.ZodObject<{
394
+ text: z.ZodString;
395
+ context: z.ZodOptional<z.ZodString>;
396
+ }, z.core.$strip>>;
397
+ noAnnotationText: z.ZodOptional<z.ZodObject<{
398
+ text: z.ZodString;
399
+ context: z.ZodOptional<z.ZodString>;
400
+ }, z.core.$strip>>;
401
+ }, z.core.$strip>;
402
+ }, z.core.$strip>], "type">;
403
+ export declare const languageTranslationsSchema: z.ZodObject<{
404
+ languageCode: z.ZodString;
405
+ questions: z.ZodRecord<z.ZodString, z.ZodDiscriminatedUnion<[z.ZodObject<{
406
+ type: z.ZodLiteral<"rating">;
407
+ translations: z.ZodObject<{
408
+ title: z.ZodObject<{
409
+ text: z.ZodString;
410
+ context: z.ZodOptional<z.ZodString>;
411
+ }, z.core.$strip>;
412
+ description: z.ZodOptional<z.ZodObject<{
413
+ text: z.ZodString;
414
+ context: z.ZodOptional<z.ZodString>;
415
+ }, z.core.$strip>>;
416
+ errorMessage: z.ZodOptional<z.ZodObject<{
417
+ text: z.ZodString;
418
+ context: z.ZodOptional<z.ZodString>;
419
+ }, z.core.$strip>>;
420
+ minLabel: z.ZodOptional<z.ZodObject<{
421
+ text: z.ZodString;
422
+ context: z.ZodOptional<z.ZodString>;
423
+ }, z.core.$strip>>;
424
+ maxLabel: z.ZodOptional<z.ZodObject<{
425
+ text: z.ZodString;
426
+ context: z.ZodOptional<z.ZodString>;
427
+ }, z.core.$strip>>;
428
+ }, z.core.$strip>;
429
+ }, z.core.$strip>, z.ZodObject<{
430
+ type: z.ZodLiteral<"single_choice">;
431
+ translations: z.ZodObject<{
432
+ title: z.ZodObject<{
433
+ text: z.ZodString;
434
+ context: z.ZodOptional<z.ZodString>;
435
+ }, z.core.$strip>;
436
+ description: z.ZodOptional<z.ZodObject<{
437
+ text: z.ZodString;
438
+ context: z.ZodOptional<z.ZodString>;
439
+ }, z.core.$strip>>;
440
+ errorMessage: z.ZodOptional<z.ZodObject<{
441
+ text: z.ZodString;
442
+ context: z.ZodOptional<z.ZodString>;
443
+ }, z.core.$strip>>;
444
+ placeholder: z.ZodOptional<z.ZodObject<{
445
+ text: z.ZodString;
446
+ context: z.ZodOptional<z.ZodString>;
447
+ }, z.core.$strip>>;
448
+ options: z.ZodRecord<z.ZodString, z.ZodObject<{
449
+ label: z.ZodObject<{
450
+ text: z.ZodString;
451
+ context: z.ZodOptional<z.ZodString>;
452
+ }, z.core.$strip>;
453
+ hint: z.ZodOptional<z.ZodObject<{
454
+ text: z.ZodString;
455
+ context: z.ZodOptional<z.ZodString>;
456
+ }, z.core.$strip>>;
457
+ }, z.core.$strip>>;
458
+ }, z.core.$strip>;
459
+ }, z.core.$strip>, z.ZodObject<{
460
+ type: z.ZodLiteral<"multiple_choice_multiple">;
461
+ translations: z.ZodObject<{
462
+ title: z.ZodObject<{
463
+ text: z.ZodString;
464
+ context: z.ZodOptional<z.ZodString>;
465
+ }, z.core.$strip>;
466
+ description: z.ZodOptional<z.ZodObject<{
467
+ text: z.ZodString;
468
+ context: z.ZodOptional<z.ZodString>;
469
+ }, z.core.$strip>>;
470
+ errorMessage: z.ZodOptional<z.ZodObject<{
471
+ text: z.ZodString;
472
+ context: z.ZodOptional<z.ZodString>;
473
+ }, z.core.$strip>>;
474
+ placeholder: z.ZodOptional<z.ZodObject<{
475
+ text: z.ZodString;
476
+ context: z.ZodOptional<z.ZodString>;
477
+ }, z.core.$strip>>;
478
+ options: z.ZodRecord<z.ZodString, z.ZodObject<{
479
+ label: z.ZodObject<{
480
+ text: z.ZodString;
481
+ context: z.ZodOptional<z.ZodString>;
482
+ }, z.core.$strip>;
483
+ hint: z.ZodOptional<z.ZodObject<{
484
+ text: z.ZodString;
485
+ context: z.ZodOptional<z.ZodString>;
486
+ }, z.core.$strip>>;
487
+ }, z.core.$strip>>;
488
+ }, z.core.$strip>;
489
+ }, z.core.$strip>, z.ZodObject<{
490
+ type: z.ZodLiteral<"nps">;
491
+ translations: z.ZodObject<{
492
+ title: z.ZodObject<{
493
+ text: z.ZodString;
494
+ context: z.ZodOptional<z.ZodString>;
495
+ }, z.core.$strip>;
496
+ description: z.ZodOptional<z.ZodObject<{
497
+ text: z.ZodString;
498
+ context: z.ZodOptional<z.ZodString>;
499
+ }, z.core.$strip>>;
500
+ errorMessage: z.ZodOptional<z.ZodObject<{
501
+ text: z.ZodString;
502
+ context: z.ZodOptional<z.ZodString>;
503
+ }, z.core.$strip>>;
504
+ minLabel: z.ZodOptional<z.ZodObject<{
505
+ text: z.ZodString;
506
+ context: z.ZodOptional<z.ZodString>;
507
+ }, z.core.$strip>>;
508
+ maxLabel: z.ZodOptional<z.ZodObject<{
509
+ text: z.ZodString;
510
+ context: z.ZodOptional<z.ZodString>;
511
+ }, z.core.$strip>>;
512
+ scaleLabels: z.ZodOptional<z.ZodRecord<z.ZodNumber, z.ZodObject<{
513
+ text: z.ZodString;
514
+ context: z.ZodOptional<z.ZodString>;
515
+ }, z.core.$strip>>>;
516
+ }, z.core.$strip>;
517
+ }, z.core.$strip>, z.ZodObject<{
518
+ type: z.ZodLiteral<"short_answer">;
519
+ translations: z.ZodObject<{
520
+ title: z.ZodObject<{
521
+ text: z.ZodString;
522
+ context: z.ZodOptional<z.ZodString>;
523
+ }, z.core.$strip>;
524
+ description: z.ZodOptional<z.ZodObject<{
525
+ text: z.ZodString;
526
+ context: z.ZodOptional<z.ZodString>;
527
+ }, z.core.$strip>>;
528
+ errorMessage: z.ZodOptional<z.ZodObject<{
529
+ text: z.ZodString;
530
+ context: z.ZodOptional<z.ZodString>;
531
+ }, z.core.$strip>>;
532
+ placeholder: z.ZodOptional<z.ZodObject<{
533
+ text: z.ZodString;
534
+ context: z.ZodOptional<z.ZodString>;
535
+ }, z.core.$strip>>;
536
+ }, z.core.$strip>;
537
+ }, z.core.$strip>, z.ZodObject<{
538
+ type: z.ZodLiteral<"long_text">;
539
+ translations: z.ZodObject<{
540
+ title: z.ZodObject<{
541
+ text: z.ZodString;
542
+ context: z.ZodOptional<z.ZodString>;
543
+ }, z.core.$strip>;
544
+ description: z.ZodOptional<z.ZodObject<{
545
+ text: z.ZodString;
546
+ context: z.ZodOptional<z.ZodString>;
547
+ }, z.core.$strip>>;
548
+ errorMessage: z.ZodOptional<z.ZodObject<{
549
+ text: z.ZodString;
550
+ context: z.ZodOptional<z.ZodString>;
551
+ }, z.core.$strip>>;
552
+ placeholder: z.ZodOptional<z.ZodObject<{
553
+ text: z.ZodString;
554
+ context: z.ZodOptional<z.ZodString>;
555
+ }, z.core.$strip>>;
556
+ }, z.core.$strip>;
557
+ }, z.core.$strip>, z.ZodObject<{
558
+ type: z.ZodLiteral<"nested_selection">;
559
+ translations: z.ZodObject<{
560
+ title: z.ZodObject<{
561
+ text: z.ZodString;
562
+ context: z.ZodOptional<z.ZodString>;
563
+ }, z.core.$strip>;
564
+ description: z.ZodOptional<z.ZodObject<{
565
+ text: z.ZodString;
566
+ context: z.ZodOptional<z.ZodString>;
567
+ }, z.core.$strip>>;
568
+ errorMessage: z.ZodOptional<z.ZodObject<{
569
+ text: z.ZodString;
570
+ context: z.ZodOptional<z.ZodString>;
571
+ }, z.core.$strip>>;
572
+ placeholder: z.ZodOptional<z.ZodObject<{
573
+ text: z.ZodString;
574
+ context: z.ZodOptional<z.ZodString>;
575
+ }, z.core.$strip>>;
576
+ nestedOptions: z.ZodRecord<z.ZodString, z.ZodObject<{
577
+ label: z.ZodObject<{
578
+ text: z.ZodString;
579
+ context: z.ZodOptional<z.ZodString>;
580
+ }, z.core.$strip>;
581
+ hint: z.ZodOptional<z.ZodObject<{
582
+ text: z.ZodString;
583
+ context: z.ZodOptional<z.ZodString>;
584
+ }, z.core.$strip>>;
585
+ }, z.core.$strip>>;
586
+ }, z.core.$strip>;
587
+ }, z.core.$strip>, z.ZodObject<{
588
+ type: z.ZodLiteral<"annotation">;
589
+ translations: z.ZodObject<{
590
+ title: z.ZodObject<{
591
+ text: z.ZodString;
592
+ context: z.ZodOptional<z.ZodString>;
593
+ }, z.core.$strip>;
594
+ description: z.ZodOptional<z.ZodObject<{
595
+ text: z.ZodString;
596
+ context: z.ZodOptional<z.ZodString>;
597
+ }, z.core.$strip>>;
598
+ errorMessage: z.ZodOptional<z.ZodObject<{
599
+ text: z.ZodString;
600
+ context: z.ZodOptional<z.ZodString>;
601
+ }, z.core.$strip>>;
602
+ annotationText: z.ZodOptional<z.ZodObject<{
603
+ text: z.ZodString;
604
+ context: z.ZodOptional<z.ZodString>;
605
+ }, z.core.$strip>>;
606
+ noAnnotationText: z.ZodOptional<z.ZodObject<{
607
+ text: z.ZodString;
608
+ context: z.ZodOptional<z.ZodString>;
609
+ }, z.core.$strip>>;
610
+ }, z.core.$strip>;
611
+ }, z.core.$strip>], "type">>;
612
+ }, z.core.$strip>;
613
+ export declare const translationsSchema: z.ZodObject<{
614
+ defaultLanguage: z.ZodString;
615
+ languages: z.ZodArray<z.ZodObject<{
616
+ languageCode: z.ZodString;
617
+ questions: z.ZodRecord<z.ZodString, z.ZodDiscriminatedUnion<[z.ZodObject<{
618
+ type: z.ZodLiteral<"rating">;
619
+ translations: z.ZodObject<{
620
+ title: z.ZodObject<{
621
+ text: z.ZodString;
622
+ context: z.ZodOptional<z.ZodString>;
623
+ }, z.core.$strip>;
624
+ description: z.ZodOptional<z.ZodObject<{
625
+ text: z.ZodString;
626
+ context: z.ZodOptional<z.ZodString>;
627
+ }, z.core.$strip>>;
628
+ errorMessage: z.ZodOptional<z.ZodObject<{
629
+ text: z.ZodString;
630
+ context: z.ZodOptional<z.ZodString>;
631
+ }, z.core.$strip>>;
632
+ minLabel: z.ZodOptional<z.ZodObject<{
633
+ text: z.ZodString;
634
+ context: z.ZodOptional<z.ZodString>;
635
+ }, z.core.$strip>>;
636
+ maxLabel: z.ZodOptional<z.ZodObject<{
637
+ text: z.ZodString;
638
+ context: z.ZodOptional<z.ZodString>;
639
+ }, z.core.$strip>>;
640
+ }, z.core.$strip>;
641
+ }, z.core.$strip>, z.ZodObject<{
642
+ type: z.ZodLiteral<"single_choice">;
643
+ translations: z.ZodObject<{
644
+ title: z.ZodObject<{
645
+ text: z.ZodString;
646
+ context: z.ZodOptional<z.ZodString>;
647
+ }, z.core.$strip>;
648
+ description: z.ZodOptional<z.ZodObject<{
649
+ text: z.ZodString;
650
+ context: z.ZodOptional<z.ZodString>;
651
+ }, z.core.$strip>>;
652
+ errorMessage: z.ZodOptional<z.ZodObject<{
653
+ text: z.ZodString;
654
+ context: z.ZodOptional<z.ZodString>;
655
+ }, z.core.$strip>>;
656
+ placeholder: z.ZodOptional<z.ZodObject<{
657
+ text: z.ZodString;
658
+ context: z.ZodOptional<z.ZodString>;
659
+ }, z.core.$strip>>;
660
+ options: z.ZodRecord<z.ZodString, z.ZodObject<{
661
+ label: z.ZodObject<{
662
+ text: z.ZodString;
663
+ context: z.ZodOptional<z.ZodString>;
664
+ }, z.core.$strip>;
665
+ hint: z.ZodOptional<z.ZodObject<{
666
+ text: z.ZodString;
667
+ context: z.ZodOptional<z.ZodString>;
668
+ }, z.core.$strip>>;
669
+ }, z.core.$strip>>;
670
+ }, z.core.$strip>;
671
+ }, z.core.$strip>, z.ZodObject<{
672
+ type: z.ZodLiteral<"multiple_choice_multiple">;
673
+ translations: z.ZodObject<{
674
+ title: z.ZodObject<{
675
+ text: z.ZodString;
676
+ context: z.ZodOptional<z.ZodString>;
677
+ }, z.core.$strip>;
678
+ description: z.ZodOptional<z.ZodObject<{
679
+ text: z.ZodString;
680
+ context: z.ZodOptional<z.ZodString>;
681
+ }, z.core.$strip>>;
682
+ errorMessage: z.ZodOptional<z.ZodObject<{
683
+ text: z.ZodString;
684
+ context: z.ZodOptional<z.ZodString>;
685
+ }, z.core.$strip>>;
686
+ placeholder: z.ZodOptional<z.ZodObject<{
687
+ text: z.ZodString;
688
+ context: z.ZodOptional<z.ZodString>;
689
+ }, z.core.$strip>>;
690
+ options: z.ZodRecord<z.ZodString, z.ZodObject<{
691
+ label: z.ZodObject<{
692
+ text: z.ZodString;
693
+ context: z.ZodOptional<z.ZodString>;
694
+ }, z.core.$strip>;
695
+ hint: z.ZodOptional<z.ZodObject<{
696
+ text: z.ZodString;
697
+ context: z.ZodOptional<z.ZodString>;
698
+ }, z.core.$strip>>;
699
+ }, z.core.$strip>>;
700
+ }, z.core.$strip>;
701
+ }, z.core.$strip>, z.ZodObject<{
702
+ type: z.ZodLiteral<"nps">;
703
+ translations: z.ZodObject<{
704
+ title: z.ZodObject<{
705
+ text: z.ZodString;
706
+ context: z.ZodOptional<z.ZodString>;
707
+ }, z.core.$strip>;
708
+ description: z.ZodOptional<z.ZodObject<{
709
+ text: z.ZodString;
710
+ context: z.ZodOptional<z.ZodString>;
711
+ }, z.core.$strip>>;
712
+ errorMessage: z.ZodOptional<z.ZodObject<{
713
+ text: z.ZodString;
714
+ context: z.ZodOptional<z.ZodString>;
715
+ }, z.core.$strip>>;
716
+ minLabel: z.ZodOptional<z.ZodObject<{
717
+ text: z.ZodString;
718
+ context: z.ZodOptional<z.ZodString>;
719
+ }, z.core.$strip>>;
720
+ maxLabel: z.ZodOptional<z.ZodObject<{
721
+ text: z.ZodString;
722
+ context: z.ZodOptional<z.ZodString>;
723
+ }, z.core.$strip>>;
724
+ scaleLabels: z.ZodOptional<z.ZodRecord<z.ZodNumber, z.ZodObject<{
725
+ text: z.ZodString;
726
+ context: z.ZodOptional<z.ZodString>;
727
+ }, z.core.$strip>>>;
728
+ }, z.core.$strip>;
729
+ }, z.core.$strip>, z.ZodObject<{
730
+ type: z.ZodLiteral<"short_answer">;
731
+ translations: z.ZodObject<{
732
+ title: z.ZodObject<{
733
+ text: z.ZodString;
734
+ context: z.ZodOptional<z.ZodString>;
735
+ }, z.core.$strip>;
736
+ description: z.ZodOptional<z.ZodObject<{
737
+ text: z.ZodString;
738
+ context: z.ZodOptional<z.ZodString>;
739
+ }, z.core.$strip>>;
740
+ errorMessage: z.ZodOptional<z.ZodObject<{
741
+ text: z.ZodString;
742
+ context: z.ZodOptional<z.ZodString>;
743
+ }, z.core.$strip>>;
744
+ placeholder: z.ZodOptional<z.ZodObject<{
745
+ text: z.ZodString;
746
+ context: z.ZodOptional<z.ZodString>;
747
+ }, z.core.$strip>>;
748
+ }, z.core.$strip>;
749
+ }, z.core.$strip>, z.ZodObject<{
750
+ type: z.ZodLiteral<"long_text">;
751
+ translations: z.ZodObject<{
752
+ title: z.ZodObject<{
753
+ text: z.ZodString;
754
+ context: z.ZodOptional<z.ZodString>;
755
+ }, z.core.$strip>;
756
+ description: z.ZodOptional<z.ZodObject<{
757
+ text: z.ZodString;
758
+ context: z.ZodOptional<z.ZodString>;
759
+ }, z.core.$strip>>;
760
+ errorMessage: z.ZodOptional<z.ZodObject<{
761
+ text: z.ZodString;
762
+ context: z.ZodOptional<z.ZodString>;
763
+ }, z.core.$strip>>;
764
+ placeholder: z.ZodOptional<z.ZodObject<{
765
+ text: z.ZodString;
766
+ context: z.ZodOptional<z.ZodString>;
767
+ }, z.core.$strip>>;
768
+ }, z.core.$strip>;
769
+ }, z.core.$strip>, z.ZodObject<{
770
+ type: z.ZodLiteral<"nested_selection">;
771
+ translations: z.ZodObject<{
772
+ title: z.ZodObject<{
773
+ text: z.ZodString;
774
+ context: z.ZodOptional<z.ZodString>;
775
+ }, z.core.$strip>;
776
+ description: z.ZodOptional<z.ZodObject<{
777
+ text: z.ZodString;
778
+ context: z.ZodOptional<z.ZodString>;
779
+ }, z.core.$strip>>;
780
+ errorMessage: z.ZodOptional<z.ZodObject<{
781
+ text: z.ZodString;
782
+ context: z.ZodOptional<z.ZodString>;
783
+ }, z.core.$strip>>;
784
+ placeholder: z.ZodOptional<z.ZodObject<{
785
+ text: z.ZodString;
786
+ context: z.ZodOptional<z.ZodString>;
787
+ }, z.core.$strip>>;
788
+ nestedOptions: z.ZodRecord<z.ZodString, z.ZodObject<{
789
+ label: z.ZodObject<{
790
+ text: z.ZodString;
791
+ context: z.ZodOptional<z.ZodString>;
792
+ }, z.core.$strip>;
793
+ hint: z.ZodOptional<z.ZodObject<{
794
+ text: z.ZodString;
795
+ context: z.ZodOptional<z.ZodString>;
796
+ }, z.core.$strip>>;
797
+ }, z.core.$strip>>;
798
+ }, z.core.$strip>;
799
+ }, z.core.$strip>, z.ZodObject<{
800
+ type: z.ZodLiteral<"annotation">;
801
+ translations: z.ZodObject<{
802
+ title: z.ZodObject<{
803
+ text: z.ZodString;
804
+ context: z.ZodOptional<z.ZodString>;
805
+ }, z.core.$strip>;
806
+ description: z.ZodOptional<z.ZodObject<{
807
+ text: z.ZodString;
808
+ context: z.ZodOptional<z.ZodString>;
809
+ }, z.core.$strip>>;
810
+ errorMessage: z.ZodOptional<z.ZodObject<{
811
+ text: z.ZodString;
812
+ context: z.ZodOptional<z.ZodString>;
813
+ }, z.core.$strip>>;
814
+ annotationText: z.ZodOptional<z.ZodObject<{
815
+ text: z.ZodString;
816
+ context: z.ZodOptional<z.ZodString>;
817
+ }, z.core.$strip>>;
818
+ noAnnotationText: z.ZodOptional<z.ZodObject<{
819
+ text: z.ZodString;
820
+ context: z.ZodOptional<z.ZodString>;
821
+ }, z.core.$strip>>;
822
+ }, z.core.$strip>;
823
+ }, z.core.$strip>], "type">>;
824
+ }, z.core.$strip>>;
825
+ version: z.ZodOptional<z.ZodString>;
826
+ }, z.core.$strip>;
827
+ export type TranslationEntry = z.infer<typeof translationEntrySchema>;
828
+ export type RatingTranslations = z.infer<typeof ratingTranslationsSchema>;
829
+ export type SingleChoiceTranslations = z.infer<typeof singleChoiceTranslationsSchema>;
830
+ export type MultipleChoiceTranslations = z.infer<typeof multipleChoiceTranslationsSchema>;
831
+ export type NpsTranslations = z.infer<typeof npsTranslationsSchema>;
832
+ export type ShortAnswerTranslations = z.infer<typeof shortAnswerTranslationsSchema>;
833
+ export type LongAnswerTranslations = z.infer<typeof longAnswerTranslationsSchema>;
834
+ export type NestedSelectionTranslations = z.infer<typeof nestedSelectionTranslationsSchema>;
835
+ export type AnnotationTranslations = z.infer<typeof annotationTranslationsSchema>;
836
+ export type QuestionTranslations = z.infer<typeof questionTranslationsSchema>;
837
+ export type LanguageTranslations = z.infer<typeof languageTranslationsSchema>;
838
+ export type Translations = z.infer<typeof translationsSchema>;
839
+ export declare class TranslationProvider {
840
+ private translations;
841
+ constructor(translations: Translations);
842
+ /**
843
+ * Get translations for a specific question in a specific language
844
+ */
845
+ getQuestionTranslations(questionId: string, languageCode: string): QuestionTranslations | null;
846
+ /**
847
+ * Get a specific translation text
848
+ */
849
+ getTranslationText(questionId: string, languageCode: string, path: string[]): string | null;
850
+ /**
851
+ * Get all available languages
852
+ */
853
+ getAvailableLanguages(): string[];
854
+ /**
855
+ * Check if a language is supported
856
+ */
857
+ isLanguageSupported(languageCode: string): boolean;
858
+ /**
859
+ * Get the default language
860
+ */
861
+ getDefaultLanguage(): string;
862
+ }
863
+ export declare function createTranslationProvider(translations: Translations): TranslationProvider;