@dmptool/types 1.1.1 → 1.1.2

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 (54) hide show
  1. package/dist/answers/__tests__/answers.spec.js +11 -5
  2. package/dist/answers/answer.d.ts +3 -3
  3. package/dist/answers/graphQLAnswers.d.ts +2 -2
  4. package/dist/answers/graphQLAnswers.js +2 -2
  5. package/dist/answers/index.d.ts +92 -55
  6. package/dist/answers/index.js +2 -2
  7. package/dist/answers/optionBasedAnswers.d.ts +27 -2
  8. package/dist/answers/optionBasedAnswers.js +5 -1
  9. package/dist/answers/tableAnswers.d.ts +268 -104
  10. package/dist/answers/tableAnswers.js +2 -1
  11. package/dist/questions/__tests__/graphQLQuestions.spec.js +7 -7
  12. package/dist/questions/__tests__/optionBasedQuestions.spec.js +48 -1
  13. package/dist/questions/dateQuestions.d.ts +47 -16
  14. package/dist/questions/dateQuestions.js +25 -1
  15. package/dist/questions/graphQLQuestions.d.ts +59 -28
  16. package/dist/questions/graphQLQuestions.js +40 -3
  17. package/dist/questions/index.d.ts +1363 -646
  18. package/dist/questions/index.js +4 -2
  19. package/dist/questions/numberQuestions.d.ts +71 -25
  20. package/dist/questions/numberQuestions.js +36 -1
  21. package/dist/questions/optionBasedQuestions.d.ts +197 -44
  22. package/dist/questions/optionBasedQuestions.js +84 -6
  23. package/dist/questions/question.d.ts +51 -4
  24. package/dist/questions/question.js +14 -2
  25. package/dist/questions/tableQuestions.d.ts +1841 -932
  26. package/dist/questions/tableQuestions.js +13 -1
  27. package/dist/questions/textQuestions.d.ts +100 -40
  28. package/dist/questions/textQuestions.js +45 -7
  29. package/dist/schemas/affiliationSearchAnswer.schema.json +37 -0
  30. package/dist/schemas/affiliationSearchQuestion.schema.json +133 -0
  31. package/dist/schemas/anyAnswer.schema.json +41 -23
  32. package/dist/schemas/anyQuestion.schema.json +533 -149
  33. package/dist/schemas/anyTableColumnAnswer.schema.json +35 -14
  34. package/dist/schemas/anyTableColumnQuestion.schema.json +397 -119
  35. package/dist/schemas/booleanQuestion.schema.json +13 -2
  36. package/dist/schemas/checkboxesQuestion.schema.json +12 -0
  37. package/dist/schemas/currencyQuestion.schema.json +12 -0
  38. package/dist/schemas/dateQuestion.schema.json +12 -0
  39. package/dist/schemas/dateRangeQuestion.schema.json +12 -0
  40. package/dist/schemas/emailQuestion.schema.json +12 -0
  41. package/dist/schemas/filteredSearchQuestion.schema.json +10 -0
  42. package/dist/schemas/multiselectBoxAnswer.schema.json +40 -0
  43. package/dist/schemas/multiselectBoxQuestion.schema.json +90 -0
  44. package/dist/schemas/numberQuestion.schema.json +12 -0
  45. package/dist/schemas/numberRangeQuestion.schema.json +12 -0
  46. package/dist/schemas/radioButtonsQuestion.schema.json +12 -0
  47. package/dist/schemas/selectBoxAnswer.schema.json +1 -4
  48. package/dist/schemas/selectBoxQuestion.schema.json +18 -1
  49. package/dist/schemas/tableAnswer.schema.json +35 -14
  50. package/dist/schemas/tableQuestion.schema.json +419 -120
  51. package/dist/schemas/textAreaQuestion.schema.json +15 -4
  52. package/dist/schemas/textQuestion.schema.json +12 -0
  53. package/dist/schemas/urlQuestion.schema.json +12 -0
  54. package/package.json +1 -1
@@ -31,6 +31,7 @@ __exportStar(require("./optionBasedQuestions"), exports);
31
31
  __exportStar(require("./tableQuestions"), exports);
32
32
  __exportStar(require("./textQuestions"), exports);
33
33
  exports.AnyQuestionSchema = zod_1.z.discriminatedUnion('type', [
34
+ graphQLQuestions_1.AffiliationSearchQuestionSchema,
34
35
  optionBasedQuestions_1.BooleanQuestionSchema,
35
36
  optionBasedQuestions_1.CheckboxesQuestionSchema,
36
37
  numberQuestions_1.CurrencyQuestionSchema,
@@ -38,6 +39,7 @@ exports.AnyQuestionSchema = zod_1.z.discriminatedUnion('type', [
38
39
  dateQuestions_1.DateRangeQuestionSchema,
39
40
  textQuestions_1.EmailQuestionSchema,
40
41
  graphQLQuestions_1.FilteredSearchQuestionSchema,
42
+ optionBasedQuestions_1.MultiselectBoxQuestionSchema,
41
43
  numberQuestions_1.NumberQuestionSchema,
42
44
  numberQuestions_1.NumberRangeQuestionSchema,
43
45
  optionBasedQuestions_1.RadioButtonsQuestionSchema,
@@ -45,11 +47,11 @@ exports.AnyQuestionSchema = zod_1.z.discriminatedUnion('type', [
45
47
  tableQuestions_1.TableQuestionSchema,
46
48
  textQuestions_1.TextAreaQuestionSchema,
47
49
  textQuestions_1.TextQuestionSchema,
48
- graphQLQuestions_1.TypeaheadSearchQuestionSchema,
49
50
  textQuestions_1.URLQuestionSchema
50
51
  ]);
51
52
  // Export a mapping between Zod Schemas and their corresponding question type label
52
53
  exports.QuestionSchemaMap = {
54
+ affiliationSearch: graphQLQuestions_1.AffiliationSearchQuestionSchema,
53
55
  boolean: optionBasedQuestions_1.BooleanQuestionSchema,
54
56
  checkBoxes: optionBasedQuestions_1.CheckboxesQuestionSchema,
55
57
  currency: numberQuestions_1.CurrencyQuestionSchema,
@@ -57,6 +59,7 @@ exports.QuestionSchemaMap = {
57
59
  dateRange: dateQuestions_1.DateRangeQuestionSchema,
58
60
  email: textQuestions_1.EmailQuestionSchema,
59
61
  filteredSearch: graphQLQuestions_1.FilteredSearchQuestionSchema,
62
+ multiselectBox: optionBasedQuestions_1.MultiselectBoxQuestionSchema,
60
63
  number: numberQuestions_1.NumberQuestionSchema,
61
64
  numberRange: numberQuestions_1.NumberRangeQuestionSchema,
62
65
  radioButtons: optionBasedQuestions_1.RadioButtonsQuestionSchema,
@@ -64,7 +67,6 @@ exports.QuestionSchemaMap = {
64
67
  table: tableQuestions_1.TableQuestionSchema,
65
68
  text: textQuestions_1.TextQuestionSchema,
66
69
  textArea: textQuestions_1.TextAreaQuestionSchema,
67
- typeaheadSearch: graphQLQuestions_1.TypeaheadSearchQuestionSchema,
68
70
  url: textQuestions_1.URLQuestionSchema
69
71
  };
70
72
  ;
@@ -1,13 +1,5 @@
1
1
  import { z } from "zod";
2
- export declare const CurrencyQuestionSchema: z.ZodObject<{
3
- meta: z.ZodOptional<z.ZodObject<{
4
- schemaVersion: z.ZodLiteral<"1.0">;
5
- }, "strip", z.ZodTypeAny, {
6
- schemaVersion: "1.0";
7
- }, {
8
- schemaVersion: "1.0";
9
- }>>;
10
- } & {
2
+ export declare const CurrencyQuestionSchema: z.ZodObject<{} & {
11
3
  type: z.ZodLiteral<"currency">;
12
4
  attributes: z.ZodOptional<z.ZodObject<{
13
5
  label: z.ZodOptional<z.ZodString>;
@@ -36,6 +28,23 @@ export declare const CurrencyQuestionSchema: z.ZodObject<{
36
28
  step?: number | undefined;
37
29
  denomination?: string | undefined;
38
30
  }>>;
31
+ meta: z.ZodOptional<z.ZodObject<{
32
+ schemaVersion: z.ZodLiteral<"1.0">;
33
+ } & {
34
+ title: z.ZodOptional<z.ZodLiteral<"Currency Field">>;
35
+ usageDescription: z.ZodOptional<z.ZodLiteral<"For questions that require a monetary amount (e.g. Cost or Budget).">>;
36
+ defaultJSON: z.ZodOptional<z.ZodLiteral<string>>;
37
+ }, "strip", z.ZodTypeAny, {
38
+ schemaVersion: "1.0";
39
+ title?: "Currency Field" | undefined;
40
+ usageDescription?: "For questions that require a monetary amount (e.g. Cost or Budget)." | undefined;
41
+ defaultJSON?: string | undefined;
42
+ }, {
43
+ schemaVersion: "1.0";
44
+ title?: "Currency Field" | undefined;
45
+ usageDescription?: "For questions that require a monetary amount (e.g. Cost or Budget)." | undefined;
46
+ defaultJSON?: string | undefined;
47
+ }>>;
39
48
  }, "strip", z.ZodTypeAny, {
40
49
  type: "currency";
41
50
  attributes?: {
@@ -49,6 +58,9 @@ export declare const CurrencyQuestionSchema: z.ZodObject<{
49
58
  } | undefined;
50
59
  meta?: {
51
60
  schemaVersion: "1.0";
61
+ title?: "Currency Field" | undefined;
62
+ usageDescription?: "For questions that require a monetary amount (e.g. Cost or Budget)." | undefined;
63
+ defaultJSON?: string | undefined;
52
64
  } | undefined;
53
65
  }, {
54
66
  type: "currency";
@@ -63,17 +75,12 @@ export declare const CurrencyQuestionSchema: z.ZodObject<{
63
75
  } | undefined;
64
76
  meta?: {
65
77
  schemaVersion: "1.0";
78
+ title?: "Currency Field" | undefined;
79
+ usageDescription?: "For questions that require a monetary amount (e.g. Cost or Budget)." | undefined;
80
+ defaultJSON?: string | undefined;
66
81
  } | undefined;
67
82
  }>;
68
- export declare const NumberQuestionSchema: z.ZodObject<{
69
- meta: z.ZodOptional<z.ZodObject<{
70
- schemaVersion: z.ZodLiteral<"1.0">;
71
- }, "strip", z.ZodTypeAny, {
72
- schemaVersion: "1.0";
73
- }, {
74
- schemaVersion: "1.0";
75
- }>>;
76
- } & {
83
+ export declare const NumberQuestionSchema: z.ZodObject<{} & {
77
84
  type: z.ZodLiteral<"number">;
78
85
  attributes: z.ZodOptional<z.ZodObject<{
79
86
  label: z.ZodOptional<z.ZodString>;
@@ -98,6 +105,23 @@ export declare const NumberQuestionSchema: z.ZodObject<{
98
105
  min?: number | undefined;
99
106
  step?: number | undefined;
100
107
  }>>;
108
+ meta: z.ZodOptional<z.ZodObject<{
109
+ schemaVersion: z.ZodLiteral<"1.0">;
110
+ } & {
111
+ title: z.ZodOptional<z.ZodLiteral<"Number Field">>;
112
+ usageDescription: z.ZodOptional<z.ZodLiteral<"For questions that require a single numeric value.">>;
113
+ defaultJSON: z.ZodOptional<z.ZodLiteral<string>>;
114
+ }, "strip", z.ZodTypeAny, {
115
+ schemaVersion: "1.0";
116
+ title?: "Number Field" | undefined;
117
+ usageDescription?: "For questions that require a single numeric value." | undefined;
118
+ defaultJSON?: string | undefined;
119
+ }, {
120
+ schemaVersion: "1.0";
121
+ title?: "Number Field" | undefined;
122
+ usageDescription?: "For questions that require a single numeric value." | undefined;
123
+ defaultJSON?: string | undefined;
124
+ }>>;
101
125
  }, "strip", z.ZodTypeAny, {
102
126
  type: "number";
103
127
  attributes?: {
@@ -110,6 +134,9 @@ export declare const NumberQuestionSchema: z.ZodObject<{
110
134
  } | undefined;
111
135
  meta?: {
112
136
  schemaVersion: "1.0";
137
+ title?: "Number Field" | undefined;
138
+ usageDescription?: "For questions that require a single numeric value." | undefined;
139
+ defaultJSON?: string | undefined;
113
140
  } | undefined;
114
141
  }, {
115
142
  type: "number";
@@ -123,6 +150,9 @@ export declare const NumberQuestionSchema: z.ZodObject<{
123
150
  } | undefined;
124
151
  meta?: {
125
152
  schemaVersion: "1.0";
153
+ title?: "Number Field" | undefined;
154
+ usageDescription?: "For questions that require a single numeric value." | undefined;
155
+ defaultJSON?: string | undefined;
126
156
  } | undefined;
127
157
  }>;
128
158
  export declare const NumberRangeQuestionSchema: z.ZodObject<{
@@ -139,13 +169,6 @@ export declare const NumberRangeQuestionSchema: z.ZodObject<{
139
169
  help?: string | undefined;
140
170
  labelTranslationKey?: string | undefined;
141
171
  }>>;
142
- meta: z.ZodOptional<z.ZodObject<{
143
- schemaVersion: z.ZodLiteral<"1.0">;
144
- }, "strip", z.ZodTypeAny, {
145
- schemaVersion: "1.0";
146
- }, {
147
- schemaVersion: "1.0";
148
- }>>;
149
172
  } & {
150
173
  type: z.ZodLiteral<"numberRange">;
151
174
  columns: z.ZodObject<{
@@ -230,6 +253,23 @@ export declare const NumberRangeQuestionSchema: z.ZodObject<{
230
253
  step?: number | undefined;
231
254
  } | undefined;
232
255
  }>;
256
+ meta: z.ZodOptional<z.ZodObject<{
257
+ schemaVersion: z.ZodLiteral<"1.0">;
258
+ } & {
259
+ title: z.ZodOptional<z.ZodLiteral<"Number Range">>;
260
+ usageDescription: z.ZodOptional<z.ZodLiteral<"For questions that require a numerical range (e.g. From/To, Min/Max).">>;
261
+ defaultJSON: z.ZodOptional<z.ZodLiteral<string>>;
262
+ }, "strip", z.ZodTypeAny, {
263
+ schemaVersion: "1.0";
264
+ title?: "Number Range" | undefined;
265
+ usageDescription?: "For questions that require a numerical range (e.g. From/To, Min/Max)." | undefined;
266
+ defaultJSON?: string | undefined;
267
+ }, {
268
+ schemaVersion: "1.0";
269
+ title?: "Number Range" | undefined;
270
+ usageDescription?: "For questions that require a numerical range (e.g. From/To, Min/Max)." | undefined;
271
+ defaultJSON?: string | undefined;
272
+ }>>;
233
273
  }, "strip", z.ZodTypeAny, {
234
274
  type: "numberRange";
235
275
  columns: {
@@ -257,6 +297,9 @@ export declare const NumberRangeQuestionSchema: z.ZodObject<{
257
297
  } | undefined;
258
298
  meta?: {
259
299
  schemaVersion: "1.0";
300
+ title?: "Number Range" | undefined;
301
+ usageDescription?: "For questions that require a numerical range (e.g. From/To, Min/Max)." | undefined;
302
+ defaultJSON?: string | undefined;
260
303
  } | undefined;
261
304
  }, {
262
305
  type: "numberRange";
@@ -285,6 +328,9 @@ export declare const NumberRangeQuestionSchema: z.ZodObject<{
285
328
  } | undefined;
286
329
  meta?: {
287
330
  schemaVersion: "1.0";
331
+ title?: "Number Range" | undefined;
332
+ usageDescription?: "For questions that require a numerical range (e.g. From/To, Min/Max)." | undefined;
333
+ defaultJSON?: string | undefined;
288
334
  } | undefined;
289
335
  }>;
290
336
  export type CurrencyQuestionType = z.infer<typeof CurrencyQuestionSchema>;
@@ -4,25 +4,60 @@ exports.NumberRangeQuestionSchema = exports.NumberQuestionSchema = exports.Curre
4
4
  const zod_1 = require("zod");
5
5
  const question_1 = require("./question");
6
6
  const BaseAttributes = question_1.QuestionSchema.shape.attributes;
7
+ const BaseMeta = question_1.QuestionSchema.shape.meta;
7
8
  const NumberAttributesSchema = BaseAttributes.unwrap().merge(zod_1.z.object({
8
9
  max: zod_1.z.number().optional(), // The highest value allowed (default no max)
9
10
  min: zod_1.z.number().optional(), // The lowest amount allowed (default 0)
10
11
  step: zod_1.z.number().optional() // The amount to increment. To allow decimals, use 0.01 (default 1)
11
12
  }));
13
+ const defaultCurrencyJSON = {
14
+ type: 'currency',
15
+ attributes: Object.assign(Object.assign({}, question_1.defaultAttributes), { denomination: 'USD', max: undefined, min: 0, step: 1 }),
16
+ meta: Object.assign({}, question_1.defaultMeta)
17
+ };
12
18
  exports.CurrencyQuestionSchema = question_1.QuestionSchema.merge(zod_1.z.object({
13
19
  type: zod_1.z.literal('currency'),
14
20
  attributes: NumberAttributesSchema.merge(zod_1.z.object({
15
21
  denomination: zod_1.z.string().optional(), // The currency type (default is "USD")
16
22
  })).optional(),
23
+ meta: BaseMeta.unwrap().merge(zod_1.z.object({
24
+ title: zod_1.z.literal('Currency Field').optional(),
25
+ usageDescription: zod_1.z.literal('For questions that require a monetary amount (e.g. Cost or Budget).').optional(),
26
+ defaultJSON: zod_1.z.literal(JSON.stringify(defaultCurrencyJSON, null, 2)).optional(),
27
+ })).optional()
17
28
  }));
29
+ const defaultNumberJSON = {
30
+ type: 'number',
31
+ attributes: Object.assign(Object.assign({}, question_1.defaultAttributes), { max: undefined, min: 0, step: 1 }),
32
+ meta: Object.assign({}, question_1.defaultMeta)
33
+ };
18
34
  exports.NumberQuestionSchema = question_1.QuestionSchema.merge(zod_1.z.object({
19
35
  type: zod_1.z.literal('number'),
20
36
  attributes: NumberAttributesSchema.optional(),
37
+ meta: BaseMeta.unwrap().merge(zod_1.z.object({
38
+ title: zod_1.z.literal('Number Field').optional(),
39
+ usageDescription: zod_1.z.literal('For questions that require a single numeric value.').optional(),
40
+ defaultJSON: zod_1.z.literal(JSON.stringify(defaultNumberJSON, null, 2)).optional(),
41
+ })).optional()
21
42
  }));
43
+ const defaultNumberRangeJSON = {
44
+ type: 'numberRange',
45
+ attributes: Object.assign({}, question_1.defaultAttributes),
46
+ columns: {
47
+ start: Object.assign(Object.assign({}, question_1.defaultAttributes), { label: 'From', max: undefined, min: 0, step: 1 }),
48
+ end: Object.assign(Object.assign({}, question_1.defaultAttributes), { label: 'To', max: undefined, min: 0, step: 1 })
49
+ },
50
+ meta: Object.assign({}, question_1.defaultMeta)
51
+ };
22
52
  exports.NumberRangeQuestionSchema = question_1.QuestionSchema.merge(zod_1.z.object({
23
53
  type: zod_1.z.literal('numberRange'),
24
54
  columns: zod_1.z.object({
25
55
  start: NumberAttributesSchema.optional(),
26
56
  end: NumberAttributesSchema.optional()
27
- })
57
+ }),
58
+ meta: BaseMeta.unwrap().merge(zod_1.z.object({
59
+ title: zod_1.z.literal('Number Range').optional(),
60
+ usageDescription: zod_1.z.literal('For questions that require a numerical range (e.g. From/To, Min/Max).').optional(),
61
+ defaultJSON: zod_1.z.literal(JSON.stringify(defaultNumberRangeJSON, null, 2)).optional(),
62
+ })).optional()
28
63
  }));
@@ -1,15 +1,7 @@
1
1
  import { z } from "zod";
2
- export declare const BooleanQuestionSchema: z.ZodObject<{
3
- meta: z.ZodOptional<z.ZodObject<{
4
- schemaVersion: z.ZodLiteral<"1.0">;
5
- }, "strip", z.ZodTypeAny, {
6
- schemaVersion: "1.0";
7
- }, {
8
- schemaVersion: "1.0";
9
- }>>;
10
- } & {
2
+ export declare const BooleanQuestionSchema: z.ZodObject<{} & {
11
3
  type: z.ZodLiteral<"boolean">;
12
- attributes: z.ZodObject<{
4
+ attributes: z.ZodOptional<z.ZodObject<{
13
5
  label: z.ZodOptional<z.ZodString>;
14
6
  help: z.ZodOptional<z.ZodString>;
15
7
  labelTranslationKey: z.ZodOptional<z.ZodString>;
@@ -25,28 +17,51 @@ export declare const BooleanQuestionSchema: z.ZodObject<{
25
17
  help?: string | undefined;
26
18
  labelTranslationKey?: string | undefined;
27
19
  checked?: boolean | undefined;
28
- }>;
20
+ }>>;
21
+ meta: z.ZodOptional<z.ZodObject<{
22
+ schemaVersion: z.ZodLiteral<"1.0">;
23
+ } & {
24
+ title: z.ZodOptional<z.ZodLiteral<"Yes/No Field">>;
25
+ usageDescription: z.ZodOptional<z.ZodLiteral<"For questions that require a simple Yes/No response.">>;
26
+ defaultJSON: z.ZodOptional<z.ZodLiteral<string>>;
27
+ }, "strip", z.ZodTypeAny, {
28
+ schemaVersion: "1.0";
29
+ title?: "Yes/No Field" | undefined;
30
+ usageDescription?: "For questions that require a simple Yes/No response." | undefined;
31
+ defaultJSON?: string | undefined;
32
+ }, {
33
+ schemaVersion: "1.0";
34
+ title?: "Yes/No Field" | undefined;
35
+ usageDescription?: "For questions that require a simple Yes/No response." | undefined;
36
+ defaultJSON?: string | undefined;
37
+ }>>;
29
38
  }, "strip", z.ZodTypeAny, {
30
39
  type: "boolean";
31
- attributes: {
40
+ attributes?: {
32
41
  label?: string | undefined;
33
42
  help?: string | undefined;
34
43
  labelTranslationKey?: string | undefined;
35
44
  checked?: boolean | undefined;
36
- };
45
+ } | undefined;
37
46
  meta?: {
38
47
  schemaVersion: "1.0";
48
+ title?: "Yes/No Field" | undefined;
49
+ usageDescription?: "For questions that require a simple Yes/No response." | undefined;
50
+ defaultJSON?: string | undefined;
39
51
  } | undefined;
40
52
  }, {
41
53
  type: "boolean";
42
- attributes: {
54
+ attributes?: {
43
55
  label?: string | undefined;
44
56
  help?: string | undefined;
45
57
  labelTranslationKey?: string | undefined;
46
58
  checked?: boolean | undefined;
47
- };
59
+ } | undefined;
48
60
  meta?: {
49
61
  schemaVersion: "1.0";
62
+ title?: "Yes/No Field" | undefined;
63
+ usageDescription?: "For questions that require a simple Yes/No response." | undefined;
64
+ defaultJSON?: string | undefined;
50
65
  } | undefined;
51
66
  }>;
52
67
  export declare const CheckboxesQuestionSchema: z.ZodObject<{
@@ -63,13 +78,6 @@ export declare const CheckboxesQuestionSchema: z.ZodObject<{
63
78
  help?: string | undefined;
64
79
  labelTranslationKey?: string | undefined;
65
80
  }>>;
66
- meta: z.ZodOptional<z.ZodObject<{
67
- schemaVersion: z.ZodLiteral<"1.0">;
68
- }, "strip", z.ZodTypeAny, {
69
- schemaVersion: "1.0";
70
- }, {
71
- schemaVersion: "1.0";
72
- }>>;
73
81
  } & {
74
82
  type: z.ZodLiteral<"checkBoxes">;
75
83
  options: z.ZodArray<z.ZodObject<{
@@ -86,6 +94,23 @@ export declare const CheckboxesQuestionSchema: z.ZodObject<{
86
94
  label: string;
87
95
  checked?: boolean | undefined;
88
96
  }>, "many">;
97
+ meta: z.ZodOptional<z.ZodObject<{
98
+ schemaVersion: z.ZodLiteral<"1.0">;
99
+ } & {
100
+ title: z.ZodOptional<z.ZodLiteral<"Check Boxes">>;
101
+ usageDescription: z.ZodOptional<z.ZodLiteral<"For multiple choice questions where users can select multiple options.">>;
102
+ defaultJSON: z.ZodOptional<z.ZodLiteral<string>>;
103
+ }, "strip", z.ZodTypeAny, {
104
+ schemaVersion: "1.0";
105
+ title?: "Check Boxes" | undefined;
106
+ usageDescription?: "For multiple choice questions where users can select multiple options." | undefined;
107
+ defaultJSON?: string | undefined;
108
+ }, {
109
+ schemaVersion: "1.0";
110
+ title?: "Check Boxes" | undefined;
111
+ usageDescription?: "For multiple choice questions where users can select multiple options." | undefined;
112
+ defaultJSON?: string | undefined;
113
+ }>>;
89
114
  }, "strip", z.ZodTypeAny, {
90
115
  options: {
91
116
  value: string;
@@ -100,6 +125,9 @@ export declare const CheckboxesQuestionSchema: z.ZodObject<{
100
125
  } | undefined;
101
126
  meta?: {
102
127
  schemaVersion: "1.0";
128
+ title?: "Check Boxes" | undefined;
129
+ usageDescription?: "For multiple choice questions where users can select multiple options." | undefined;
130
+ defaultJSON?: string | undefined;
103
131
  } | undefined;
104
132
  }, {
105
133
  options: {
@@ -115,6 +143,9 @@ export declare const CheckboxesQuestionSchema: z.ZodObject<{
115
143
  } | undefined;
116
144
  meta?: {
117
145
  schemaVersion: "1.0";
146
+ title?: "Check Boxes" | undefined;
147
+ usageDescription?: "For multiple choice questions where users can select multiple options." | undefined;
148
+ defaultJSON?: string | undefined;
118
149
  } | undefined;
119
150
  }>;
120
151
  export declare const RadioButtonsQuestionSchema: z.ZodObject<{
@@ -131,13 +162,6 @@ export declare const RadioButtonsQuestionSchema: z.ZodObject<{
131
162
  help?: string | undefined;
132
163
  labelTranslationKey?: string | undefined;
133
164
  }>>;
134
- meta: z.ZodOptional<z.ZodObject<{
135
- schemaVersion: z.ZodLiteral<"1.0">;
136
- }, "strip", z.ZodTypeAny, {
137
- schemaVersion: "1.0";
138
- }, {
139
- schemaVersion: "1.0";
140
- }>>;
141
165
  } & {
142
166
  type: z.ZodLiteral<"radioButtons">;
143
167
  options: z.ZodArray<z.ZodObject<{
@@ -154,6 +178,23 @@ export declare const RadioButtonsQuestionSchema: z.ZodObject<{
154
178
  label: string;
155
179
  selected?: boolean | undefined;
156
180
  }>, "many">;
181
+ meta: z.ZodOptional<z.ZodObject<{
182
+ schemaVersion: z.ZodLiteral<"1.0">;
183
+ } & {
184
+ title: z.ZodOptional<z.ZodLiteral<"Radio Buttons">>;
185
+ usageDescription: z.ZodOptional<z.ZodLiteral<"For multiple choice questions where users select just one option.">>;
186
+ defaultJSON: z.ZodOptional<z.ZodLiteral<string>>;
187
+ }, "strip", z.ZodTypeAny, {
188
+ schemaVersion: "1.0";
189
+ title?: "Radio Buttons" | undefined;
190
+ usageDescription?: "For multiple choice questions where users select just one option." | undefined;
191
+ defaultJSON?: string | undefined;
192
+ }, {
193
+ schemaVersion: "1.0";
194
+ title?: "Radio Buttons" | undefined;
195
+ usageDescription?: "For multiple choice questions where users select just one option." | undefined;
196
+ defaultJSON?: string | undefined;
197
+ }>>;
157
198
  }, "strip", z.ZodTypeAny, {
158
199
  options: {
159
200
  value: string;
@@ -168,6 +209,9 @@ export declare const RadioButtonsQuestionSchema: z.ZodObject<{
168
209
  } | undefined;
169
210
  meta?: {
170
211
  schemaVersion: "1.0";
212
+ title?: "Radio Buttons" | undefined;
213
+ usageDescription?: "For multiple choice questions where users select just one option." | undefined;
214
+ defaultJSON?: string | undefined;
171
215
  } | undefined;
172
216
  }, {
173
217
  options: {
@@ -183,18 +227,101 @@ export declare const RadioButtonsQuestionSchema: z.ZodObject<{
183
227
  } | undefined;
184
228
  meta?: {
185
229
  schemaVersion: "1.0";
230
+ title?: "Radio Buttons" | undefined;
231
+ usageDescription?: "For multiple choice questions where users select just one option." | undefined;
232
+ defaultJSON?: string | undefined;
186
233
  } | undefined;
187
234
  }>;
188
- export declare const SelectBoxQuestionSchema: z.ZodObject<{
235
+ export declare const SelectBoxQuestionSchema: z.ZodObject<{} & {
236
+ type: z.ZodLiteral<"selectBox">;
237
+ options: z.ZodArray<z.ZodObject<{
238
+ label: z.ZodString;
239
+ value: z.ZodString;
240
+ } & {
241
+ selected: z.ZodOptional<z.ZodBoolean>;
242
+ }, "strip", z.ZodTypeAny, {
243
+ value: string;
244
+ label: string;
245
+ selected?: boolean | undefined;
246
+ }, {
247
+ value: string;
248
+ label: string;
249
+ selected?: boolean | undefined;
250
+ }>, "many">;
251
+ attributes: z.ZodObject<{
252
+ label: z.ZodOptional<z.ZodString>;
253
+ help: z.ZodOptional<z.ZodString>;
254
+ labelTranslationKey: z.ZodOptional<z.ZodString>;
255
+ } & {
256
+ multiple: z.ZodLiteral<false>;
257
+ }, "strip", z.ZodTypeAny, {
258
+ multiple: false;
259
+ label?: string | undefined;
260
+ help?: string | undefined;
261
+ labelTranslationKey?: string | undefined;
262
+ }, {
263
+ multiple: false;
264
+ label?: string | undefined;
265
+ help?: string | undefined;
266
+ labelTranslationKey?: string | undefined;
267
+ }>;
189
268
  meta: z.ZodOptional<z.ZodObject<{
190
269
  schemaVersion: z.ZodLiteral<"1.0">;
270
+ } & {
271
+ title: z.ZodOptional<z.ZodLiteral<"Select Box">>;
272
+ usageDescription: z.ZodOptional<z.ZodLiteral<"For questions where users select one option from a list.">>;
273
+ defaultJSON: z.ZodOptional<z.ZodLiteral<string>>;
191
274
  }, "strip", z.ZodTypeAny, {
192
275
  schemaVersion: "1.0";
276
+ title?: "Select Box" | undefined;
277
+ usageDescription?: "For questions where users select one option from a list." | undefined;
278
+ defaultJSON?: string | undefined;
193
279
  }, {
194
280
  schemaVersion: "1.0";
281
+ title?: "Select Box" | undefined;
282
+ usageDescription?: "For questions where users select one option from a list." | undefined;
283
+ defaultJSON?: string | undefined;
195
284
  }>>;
196
- } & {
197
- type: z.ZodLiteral<"selectBox">;
285
+ }, "strip", z.ZodTypeAny, {
286
+ options: {
287
+ value: string;
288
+ label: string;
289
+ selected?: boolean | undefined;
290
+ }[];
291
+ type: "selectBox";
292
+ attributes: {
293
+ multiple: false;
294
+ label?: string | undefined;
295
+ help?: string | undefined;
296
+ labelTranslationKey?: string | undefined;
297
+ };
298
+ meta?: {
299
+ schemaVersion: "1.0";
300
+ title?: "Select Box" | undefined;
301
+ usageDescription?: "For questions where users select one option from a list." | undefined;
302
+ defaultJSON?: string | undefined;
303
+ } | undefined;
304
+ }, {
305
+ options: {
306
+ value: string;
307
+ label: string;
308
+ selected?: boolean | undefined;
309
+ }[];
310
+ type: "selectBox";
311
+ attributes: {
312
+ multiple: false;
313
+ label?: string | undefined;
314
+ help?: string | undefined;
315
+ labelTranslationKey?: string | undefined;
316
+ };
317
+ meta?: {
318
+ schemaVersion: "1.0";
319
+ title?: "Select Box" | undefined;
320
+ usageDescription?: "For questions where users select one option from a list." | undefined;
321
+ defaultJSON?: string | undefined;
322
+ } | undefined;
323
+ }>;
324
+ export declare const MultiselectBoxQuestionSchema: z.ZodObject<{
198
325
  options: z.ZodArray<z.ZodObject<{
199
326
  label: z.ZodString;
200
327
  value: z.ZodString;
@@ -209,22 +336,41 @@ export declare const SelectBoxQuestionSchema: z.ZodObject<{
209
336
  label: string;
210
337
  selected?: boolean | undefined;
211
338
  }>, "many">;
212
- attributes: z.ZodOptional<z.ZodObject<{
339
+ } & {
340
+ type: z.ZodLiteral<"multiselectBox">;
341
+ attributes: z.ZodObject<{
213
342
  label: z.ZodOptional<z.ZodString>;
214
343
  help: z.ZodOptional<z.ZodString>;
215
344
  labelTranslationKey: z.ZodOptional<z.ZodString>;
216
345
  } & {
217
- multiple: z.ZodOptional<z.ZodBoolean>;
346
+ multiple: z.ZodLiteral<true>;
218
347
  }, "strip", z.ZodTypeAny, {
348
+ multiple: true;
219
349
  label?: string | undefined;
220
350
  help?: string | undefined;
221
351
  labelTranslationKey?: string | undefined;
222
- multiple?: boolean | undefined;
223
352
  }, {
353
+ multiple: true;
224
354
  label?: string | undefined;
225
355
  help?: string | undefined;
226
356
  labelTranslationKey?: string | undefined;
227
- multiple?: boolean | undefined;
357
+ }>;
358
+ meta: z.ZodOptional<z.ZodObject<{
359
+ schemaVersion: z.ZodLiteral<"1.0">;
360
+ } & {
361
+ title: z.ZodOptional<z.ZodLiteral<"Multi-select Box">>;
362
+ usageDescription: z.ZodOptional<z.ZodLiteral<"For questions where multiple answers are valid. Allows users to select several options from a predefined list, providing flexibility in responses.">>;
363
+ defaultJSON: z.ZodOptional<z.ZodLiteral<string>>;
364
+ }, "strip", z.ZodTypeAny, {
365
+ schemaVersion: "1.0";
366
+ title?: "Multi-select Box" | undefined;
367
+ usageDescription?: "For questions where multiple answers are valid. Allows users to select several options from a predefined list, providing flexibility in responses." | undefined;
368
+ defaultJSON?: string | undefined;
369
+ }, {
370
+ schemaVersion: "1.0";
371
+ title?: "Multi-select Box" | undefined;
372
+ usageDescription?: "For questions where multiple answers are valid. Allows users to select several options from a predefined list, providing flexibility in responses." | undefined;
373
+ defaultJSON?: string | undefined;
228
374
  }>>;
229
375
  }, "strip", z.ZodTypeAny, {
230
376
  options: {
@@ -232,15 +378,18 @@ export declare const SelectBoxQuestionSchema: z.ZodObject<{
232
378
  label: string;
233
379
  selected?: boolean | undefined;
234
380
  }[];
235
- type: "selectBox";
236
- attributes?: {
381
+ type: "multiselectBox";
382
+ attributes: {
383
+ multiple: true;
237
384
  label?: string | undefined;
238
385
  help?: string | undefined;
239
386
  labelTranslationKey?: string | undefined;
240
- multiple?: boolean | undefined;
241
- } | undefined;
387
+ };
242
388
  meta?: {
243
389
  schemaVersion: "1.0";
390
+ title?: "Multi-select Box" | undefined;
391
+ usageDescription?: "For questions where multiple answers are valid. Allows users to select several options from a predefined list, providing flexibility in responses." | undefined;
392
+ defaultJSON?: string | undefined;
244
393
  } | undefined;
245
394
  }, {
246
395
  options: {
@@ -248,18 +397,22 @@ export declare const SelectBoxQuestionSchema: z.ZodObject<{
248
397
  label: string;
249
398
  selected?: boolean | undefined;
250
399
  }[];
251
- type: "selectBox";
252
- attributes?: {
400
+ type: "multiselectBox";
401
+ attributes: {
402
+ multiple: true;
253
403
  label?: string | undefined;
254
404
  help?: string | undefined;
255
405
  labelTranslationKey?: string | undefined;
256
- multiple?: boolean | undefined;
257
- } | undefined;
406
+ };
258
407
  meta?: {
259
408
  schemaVersion: "1.0";
409
+ title?: "Multi-select Box" | undefined;
410
+ usageDescription?: "For questions where multiple answers are valid. Allows users to select several options from a predefined list, providing flexibility in responses." | undefined;
411
+ defaultJSON?: string | undefined;
260
412
  } | undefined;
261
413
  }>;
262
414
  export type BooleanQuestionType = z.infer<typeof BooleanQuestionSchema>;
263
415
  export type CheckboxesQuestionType = z.infer<typeof CheckboxesQuestionSchema>;
264
416
  export type RadioButtonsQuestionType = z.infer<typeof RadioButtonsQuestionSchema>;
265
417
  export type SelectBoxQuestionType = z.infer<typeof SelectBoxQuestionSchema>;
418
+ export type MultiselectBoxQuestionType = z.infer<typeof MultiselectBoxQuestionSchema>;