@dmptool/types 1.0.0

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 (47) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +41 -0
  3. package/dist/answers.d.ts +558 -0
  4. package/dist/answers.js +87 -0
  5. package/dist/dateQuestions.d.ts +244 -0
  6. package/dist/dateQuestions.js +30 -0
  7. package/dist/graphQLQuestions.d.ts +288 -0
  8. package/dist/graphQLQuestions.js +41 -0
  9. package/dist/optionBasedQuestions.d.ts +236 -0
  10. package/dist/optionBasedQuestions.js +44 -0
  11. package/dist/primitiveQuestions.d.ts +367 -0
  12. package/dist/primitiveQuestions.js +96 -0
  13. package/dist/schemas/anyAnswer.schema.json +267 -0
  14. package/dist/schemas/anyQuestion.schema.json +726 -0
  15. package/dist/schemas/booleanAnswer.schema.json +23 -0
  16. package/dist/schemas/booleanQuestion.schema.json +46 -0
  17. package/dist/schemas/checkboxesAnswer.schema.json +26 -0
  18. package/dist/schemas/checkboxesQuestion.schema.json +73 -0
  19. package/dist/schemas/currencyAnswer.schema.json +23 -0
  20. package/dist/schemas/currencyQuestion.schema.json +45 -0
  21. package/dist/schemas/datePickerAnswer.schema.json +23 -0
  22. package/dist/schemas/datePickerQuestion.schema.json +52 -0
  23. package/dist/schemas/dateRangeAnswer.schema.json +36 -0
  24. package/dist/schemas/dateRangeQuestion.schema.json +106 -0
  25. package/dist/schemas/emailAnswer.schema.json +23 -0
  26. package/dist/schemas/emailQuestion.schema.json +55 -0
  27. package/dist/schemas/filteredSearchAnswer.schema.json +26 -0
  28. package/dist/schemas/filteredSearchQuestion.schema.json +120 -0
  29. package/dist/schemas/numberAnswer.schema.json +23 -0
  30. package/dist/schemas/numberQuestion.schema.json +52 -0
  31. package/dist/schemas/radioButtonsAnswer.schema.json +23 -0
  32. package/dist/schemas/radioButtonsQuestion.schema.json +73 -0
  33. package/dist/schemas/selectBoxAnswer.schema.json +23 -0
  34. package/dist/schemas/selectBoxQuestion.schema.json +83 -0
  35. package/dist/schemas/tableAnswer.schema.json +284 -0
  36. package/dist/schemas/tableQuestion.schema.json +680 -0
  37. package/dist/schemas/textAnswer.schema.json +23 -0
  38. package/dist/schemas/textAreaAnswer.schema.json +23 -0
  39. package/dist/schemas/textAreaQuestion.schema.json +48 -0
  40. package/dist/schemas/textQuestion.schema.json +52 -0
  41. package/dist/schemas/typeaheadSearchAnswer.schema.json +23 -0
  42. package/dist/schemas/typeaheadSearchQuestion.schema.json +110 -0
  43. package/dist/schemas/urlAnswer.schema.json +23 -0
  44. package/dist/schemas/urlQuestion.schema.json +52 -0
  45. package/dist/tableQuestions.d.ts +4195 -0
  46. package/dist/tableQuestions.js +55 -0
  47. package/package.json +41 -0
@@ -0,0 +1,23 @@
1
+ {
2
+ "$ref": "#/definitions/NumberAnswer",
3
+ "definitions": {
4
+ "NumberAnswer": {
5
+ "type": "object",
6
+ "properties": {
7
+ "type": {
8
+ "type": "string",
9
+ "const": "number"
10
+ },
11
+ "answer": {
12
+ "type": "number"
13
+ }
14
+ },
15
+ "required": [
16
+ "type",
17
+ "answer"
18
+ ],
19
+ "additionalProperties": false
20
+ }
21
+ },
22
+ "$schema": "http://json-schema.org/draft-07/schema#"
23
+ }
@@ -0,0 +1,52 @@
1
+ {
2
+ "$ref": "#/definitions/NumberQuestion",
3
+ "definitions": {
4
+ "NumberQuestion": {
5
+ "type": "object",
6
+ "properties": {
7
+ "type": {
8
+ "type": "string",
9
+ "const": "number"
10
+ },
11
+ "meta": {
12
+ "type": "object",
13
+ "properties": {
14
+ "schemaVersion": {
15
+ "type": "string",
16
+ "const": "1.0"
17
+ },
18
+ "labelTranslationKey": {
19
+ "type": "string"
20
+ }
21
+ },
22
+ "required": [
23
+ "schemaVersion"
24
+ ],
25
+ "additionalProperties": false
26
+ },
27
+ "attributes": {
28
+ "type": "object",
29
+ "properties": {
30
+ "max": {
31
+ "type": "number"
32
+ },
33
+ "min": {
34
+ "type": "number"
35
+ },
36
+ "step": {
37
+ "type": "number"
38
+ }
39
+ },
40
+ "additionalProperties": false
41
+ }
42
+ },
43
+ "required": [
44
+ "type",
45
+ "meta",
46
+ "attributes"
47
+ ],
48
+ "additionalProperties": false
49
+ }
50
+ },
51
+ "$schema": "http://json-schema.org/draft-07/schema#"
52
+ }
@@ -0,0 +1,23 @@
1
+ {
2
+ "$ref": "#/definitions/RadioButtonsAnswer",
3
+ "definitions": {
4
+ "RadioButtonsAnswer": {
5
+ "type": "object",
6
+ "properties": {
7
+ "type": {
8
+ "type": "string",
9
+ "const": "radioButtons"
10
+ },
11
+ "answer": {
12
+ "type": "string"
13
+ }
14
+ },
15
+ "required": [
16
+ "type",
17
+ "answer"
18
+ ],
19
+ "additionalProperties": false
20
+ }
21
+ },
22
+ "$schema": "http://json-schema.org/draft-07/schema#"
23
+ }
@@ -0,0 +1,73 @@
1
+ {
2
+ "$ref": "#/definitions/RadioButtonsQuestion",
3
+ "definitions": {
4
+ "RadioButtonsQuestion": {
5
+ "type": "object",
6
+ "properties": {
7
+ "type": {
8
+ "type": "string",
9
+ "const": "radioButtons"
10
+ },
11
+ "meta": {
12
+ "type": "object",
13
+ "properties": {
14
+ "schemaVersion": {
15
+ "type": "string",
16
+ "const": "1.0"
17
+ },
18
+ "labelTranslationKey": {
19
+ "type": "string"
20
+ }
21
+ },
22
+ "required": [
23
+ "schemaVersion"
24
+ ],
25
+ "additionalProperties": false
26
+ },
27
+ "options": {
28
+ "type": "array",
29
+ "items": {
30
+ "type": "object",
31
+ "properties": {
32
+ "type": {
33
+ "type": "string",
34
+ "const": "option"
35
+ },
36
+ "attributes": {
37
+ "type": "object",
38
+ "properties": {
39
+ "label": {
40
+ "type": "string"
41
+ },
42
+ "value": {
43
+ "type": "string"
44
+ },
45
+ "selected": {
46
+ "type": "boolean"
47
+ }
48
+ },
49
+ "required": [
50
+ "label",
51
+ "value"
52
+ ],
53
+ "additionalProperties": false
54
+ }
55
+ },
56
+ "required": [
57
+ "type",
58
+ "attributes"
59
+ ],
60
+ "additionalProperties": false
61
+ }
62
+ }
63
+ },
64
+ "required": [
65
+ "type",
66
+ "meta",
67
+ "options"
68
+ ],
69
+ "additionalProperties": false
70
+ }
71
+ },
72
+ "$schema": "http://json-schema.org/draft-07/schema#"
73
+ }
@@ -0,0 +1,23 @@
1
+ {
2
+ "$ref": "#/definitions/SelectBoxAnswer",
3
+ "definitions": {
4
+ "SelectBoxAnswer": {
5
+ "type": "object",
6
+ "properties": {
7
+ "type": {
8
+ "type": "string",
9
+ "const": "selectBox"
10
+ },
11
+ "answer": {
12
+ "type": "string"
13
+ }
14
+ },
15
+ "required": [
16
+ "type",
17
+ "answer"
18
+ ],
19
+ "additionalProperties": false
20
+ }
21
+ },
22
+ "$schema": "http://json-schema.org/draft-07/schema#"
23
+ }
@@ -0,0 +1,83 @@
1
+ {
2
+ "$ref": "#/definitions/SelectBoxQuestion",
3
+ "definitions": {
4
+ "SelectBoxQuestion": {
5
+ "type": "object",
6
+ "properties": {
7
+ "type": {
8
+ "type": "string",
9
+ "const": "selectBox"
10
+ },
11
+ "meta": {
12
+ "type": "object",
13
+ "properties": {
14
+ "schemaVersion": {
15
+ "type": "string",
16
+ "const": "1.0"
17
+ },
18
+ "labelTranslationKey": {
19
+ "type": "string"
20
+ }
21
+ },
22
+ "required": [
23
+ "schemaVersion"
24
+ ],
25
+ "additionalProperties": false
26
+ },
27
+ "options": {
28
+ "type": "array",
29
+ "items": {
30
+ "type": "object",
31
+ "properties": {
32
+ "type": {
33
+ "type": "string",
34
+ "const": "option"
35
+ },
36
+ "attributes": {
37
+ "type": "object",
38
+ "properties": {
39
+ "label": {
40
+ "type": "string"
41
+ },
42
+ "value": {
43
+ "type": "string"
44
+ },
45
+ "selected": {
46
+ "type": "boolean"
47
+ }
48
+ },
49
+ "required": [
50
+ "label",
51
+ "value"
52
+ ],
53
+ "additionalProperties": false
54
+ }
55
+ },
56
+ "required": [
57
+ "type",
58
+ "attributes"
59
+ ],
60
+ "additionalProperties": false
61
+ }
62
+ },
63
+ "attributes": {
64
+ "type": "object",
65
+ "properties": {
66
+ "multiple": {
67
+ "type": "boolean"
68
+ }
69
+ },
70
+ "additionalProperties": false
71
+ }
72
+ },
73
+ "required": [
74
+ "type",
75
+ "meta",
76
+ "options",
77
+ "attributes"
78
+ ],
79
+ "additionalProperties": false
80
+ }
81
+ },
82
+ "$schema": "http://json-schema.org/draft-07/schema#"
83
+ }
@@ -0,0 +1,284 @@
1
+ {
2
+ "$ref": "#/definitions/TableAnswer",
3
+ "definitions": {
4
+ "TableAnswer": {
5
+ "type": "object",
6
+ "properties": {
7
+ "type": {
8
+ "type": "string",
9
+ "const": "table"
10
+ },
11
+ "answer": {
12
+ "type": "array",
13
+ "items": {
14
+ "anyOf": [
15
+ {
16
+ "type": "object",
17
+ "properties": {
18
+ "type": {
19
+ "type": "string",
20
+ "const": "boolean"
21
+ },
22
+ "answer": {
23
+ "type": "boolean"
24
+ }
25
+ },
26
+ "required": [
27
+ "type",
28
+ "answer"
29
+ ],
30
+ "additionalProperties": false
31
+ },
32
+ {
33
+ "type": "object",
34
+ "properties": {
35
+ "type": {
36
+ "type": "string",
37
+ "const": "checkBoxes"
38
+ },
39
+ "answer": {
40
+ "type": "array",
41
+ "items": {
42
+ "type": "string"
43
+ }
44
+ }
45
+ },
46
+ "required": [
47
+ "type",
48
+ "answer"
49
+ ],
50
+ "additionalProperties": false
51
+ },
52
+ {
53
+ "type": "object",
54
+ "properties": {
55
+ "type": {
56
+ "type": "string",
57
+ "const": "currency"
58
+ },
59
+ "answer": {
60
+ "type": "number"
61
+ }
62
+ },
63
+ "required": [
64
+ "type",
65
+ "answer"
66
+ ],
67
+ "additionalProperties": false
68
+ },
69
+ {
70
+ "type": "object",
71
+ "properties": {
72
+ "type": {
73
+ "type": "string",
74
+ "const": "datePicker"
75
+ },
76
+ "answer": {
77
+ "type": "string"
78
+ }
79
+ },
80
+ "required": [
81
+ "type",
82
+ "answer"
83
+ ],
84
+ "additionalProperties": false
85
+ },
86
+ {
87
+ "type": "object",
88
+ "properties": {
89
+ "type": {
90
+ "type": "string",
91
+ "const": "dateRange"
92
+ },
93
+ "answer": {
94
+ "type": "object",
95
+ "properties": {
96
+ "start": {
97
+ "type": "string"
98
+ },
99
+ "end": {
100
+ "type": "string"
101
+ }
102
+ },
103
+ "required": [
104
+ "start",
105
+ "end"
106
+ ],
107
+ "additionalProperties": false
108
+ }
109
+ },
110
+ "required": [
111
+ "type",
112
+ "answer"
113
+ ],
114
+ "additionalProperties": false
115
+ },
116
+ {
117
+ "type": "object",
118
+ "properties": {
119
+ "type": {
120
+ "type": "string",
121
+ "const": "email"
122
+ },
123
+ "answer": {
124
+ "type": "string"
125
+ }
126
+ },
127
+ "required": [
128
+ "type",
129
+ "answer"
130
+ ],
131
+ "additionalProperties": false
132
+ },
133
+ {
134
+ "type": "object",
135
+ "properties": {
136
+ "type": {
137
+ "type": "string",
138
+ "const": "filteredSearch"
139
+ },
140
+ "answer": {
141
+ "type": "array",
142
+ "items": {
143
+ "type": "string"
144
+ }
145
+ }
146
+ },
147
+ "required": [
148
+ "type",
149
+ "answer"
150
+ ],
151
+ "additionalProperties": false
152
+ },
153
+ {
154
+ "type": "object",
155
+ "properties": {
156
+ "type": {
157
+ "type": "string",
158
+ "const": "number"
159
+ },
160
+ "answer": {
161
+ "type": "number"
162
+ }
163
+ },
164
+ "required": [
165
+ "type",
166
+ "answer"
167
+ ],
168
+ "additionalProperties": false
169
+ },
170
+ {
171
+ "type": "object",
172
+ "properties": {
173
+ "type": {
174
+ "type": "string",
175
+ "const": "radioButtons"
176
+ },
177
+ "answer": {
178
+ "type": "string"
179
+ }
180
+ },
181
+ "required": [
182
+ "type",
183
+ "answer"
184
+ ],
185
+ "additionalProperties": false
186
+ },
187
+ {
188
+ "type": "object",
189
+ "properties": {
190
+ "type": {
191
+ "type": "string",
192
+ "const": "selectBox"
193
+ },
194
+ "answer": {
195
+ "type": "string"
196
+ }
197
+ },
198
+ "required": [
199
+ "type",
200
+ "answer"
201
+ ],
202
+ "additionalProperties": false
203
+ },
204
+ {
205
+ "type": "object",
206
+ "properties": {
207
+ "type": {
208
+ "type": "string",
209
+ "const": "textArea"
210
+ },
211
+ "answer": {
212
+ "type": "string"
213
+ }
214
+ },
215
+ "required": [
216
+ "type",
217
+ "answer"
218
+ ],
219
+ "additionalProperties": false
220
+ },
221
+ {
222
+ "type": "object",
223
+ "properties": {
224
+ "type": {
225
+ "type": "string",
226
+ "const": "text"
227
+ },
228
+ "answer": {
229
+ "type": "string"
230
+ }
231
+ },
232
+ "required": [
233
+ "type",
234
+ "answer"
235
+ ],
236
+ "additionalProperties": false
237
+ },
238
+ {
239
+ "type": "object",
240
+ "properties": {
241
+ "type": {
242
+ "type": "string",
243
+ "const": "typeaheadSearch"
244
+ },
245
+ "answer": {
246
+ "type": "string"
247
+ }
248
+ },
249
+ "required": [
250
+ "type",
251
+ "answer"
252
+ ],
253
+ "additionalProperties": false
254
+ },
255
+ {
256
+ "type": "object",
257
+ "properties": {
258
+ "type": {
259
+ "type": "string",
260
+ "const": "url"
261
+ },
262
+ "answer": {
263
+ "type": "string"
264
+ }
265
+ },
266
+ "required": [
267
+ "type",
268
+ "answer"
269
+ ],
270
+ "additionalProperties": false
271
+ }
272
+ ]
273
+ }
274
+ }
275
+ },
276
+ "required": [
277
+ "type",
278
+ "answer"
279
+ ],
280
+ "additionalProperties": false
281
+ }
282
+ },
283
+ "$schema": "http://json-schema.org/draft-07/schema#"
284
+ }