@inseefr/lunatic 2.5.1-testRoundaboutFix → 2.5.2-rc1-beta
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/lib/components/commons/components/combo-box/combo-box-container.js +16 -7
- package/lib/components/commons/components/combo-box/combo-box-container.spec.js +5 -5
- package/lib/components/commons/components/combo-box/combo-box-content-box.js +25 -0
- package/lib/components/commons/components/combo-box/combo-box-content.js +11 -11
- package/lib/components/commons/components/combo-box/combo-box.js +26 -11
- package/lib/components/commons/components/combo-box/panel/panel-container.js +5 -2
- package/lib/components/commons/components/combo-box/panel/panel-container.spec.js +7 -6
- package/lib/components/commons/components/combo-box/panel/panel.js +2 -2
- package/lib/components/commons/components/combo-box/selection/selection-container.js +3 -2
- package/lib/components/commons/components/combo-box/selection/selection.js +3 -1
- package/lib/components/component-set/html/component-set-components.js +5 -23
- package/lib/components/dropdown/lunatic-dropdown.js +3 -1
- package/lib/components/index.js +7 -0
- package/lib/components/loop/block-for-loop/row.js +6 -16
- package/lib/components/modal/html/modal.js +88 -0
- package/lib/components/modal/html/modal.scss +43 -0
- package/lib/components/modal/index.js +13 -0
- package/lib/components/modal/lunatic-modal.js +38 -0
- package/lib/components/pairwise-links/orchestrator.js +2 -0
- package/lib/components/pairwise-links/pairwise-links.js +1 -1
- package/lib/components/pairwise-links/row.js +2 -0
- package/lib/components/suggester/html/suggester.js +10 -6
- package/lib/components/suggester/lunatic-suggester.js +3 -1
- package/lib/src/components/commons/components/combo-box/combo-box-container.d.ts +5 -2
- package/lib/src/components/commons/components/combo-box/combo-box-content-box.d.ts +8 -0
- package/lib/src/components/commons/components/combo-box/combo-box-content.d.ts +2 -1
- package/lib/src/components/commons/components/combo-box/combo-box.d.ts +1 -0
- package/lib/src/components/commons/components/combo-box/combo-box.stories.d.ts +2 -0
- package/lib/src/components/commons/components/combo-box/panel/panel-container.d.ts +2 -2
- package/lib/src/components/commons/components/combo-box/selection/selection-container.d.ts +2 -1
- package/lib/src/components/commons/components/combo-box/selection/selection.d.ts +2 -1
- package/lib/src/components/component-set/html/component-set-components.d.ts +1 -1
- package/lib/src/components/dropdown/lunatic-dropdown.d.ts +1 -1
- package/lib/src/components/index.d.ts +1 -0
- package/lib/src/components/modal/html/modal.d.ts +14 -0
- package/lib/src/components/modal/index.d.ts +1 -0
- package/lib/src/components/modal/lunatic-modal.d.ts +3 -0
- package/lib/src/components/pairwise-links/row.d.ts +1 -1
- package/lib/src/components/suggester/html/suggester.d.ts +1 -0
- package/lib/src/components/suggester/lunatic-suggester.d.ts +1 -1
- package/lib/src/components/type.d.ts +8 -0
- package/lib/src/use-lunatic/actions.d.ts +4 -0
- package/lib/src/use-lunatic/commons/fill-components/fill-from-state.d.ts +40 -0
- package/lib/src/use-lunatic/reducer/overview/overview-on-init.d.ts +2 -0
- package/lib/src/use-lunatic/type.d.ts +2 -0
- package/lib/src/use-lunatic/use-lunatic.d.ts +22 -0
- package/lib/src/utils/get-component-value.d.ts +5 -0
- package/lib/stories/checkboxGroup/checkboxGroup.stories.js +17 -1
- package/lib/stories/checkboxGroup/sourceComponentset.json +424 -0
- package/lib/stories/checkboxGroup/sourceLoop.json +83 -0
- package/lib/stories/modal/modal.stories.js +34 -0
- package/lib/stories/modal/source.json +97 -0
- package/lib/stories/questionnaires/simpsons/simpsons.stories.js +33 -36
- package/lib/stories/suggester/simple.json +15 -0
- package/lib/use-lunatic/commons/fill-components/fill-from-state.js +6 -2
- package/lib/use-lunatic/commons/page-navigation.js +2 -2
- package/lib/use-lunatic/commons/page.js +0 -6
- package/lib/use-lunatic/initial-state.js +2 -0
- package/lib/use-lunatic/reducer/commons/auto-explore-loop.js +9 -3
- package/lib/use-lunatic/reducer/reduce-go-next-page.js +11 -4
- package/lib/use-lunatic/reducer/reduce-go-previous-page.js +13 -5
- package/lib/use-lunatic/reducer/reduce-go-to-page.js +7 -6
- package/lib/use-lunatic/reducer/reduce-handle-change/reduce-resizing.js +0 -3
- package/lib/use-lunatic/reducer/reduce-on-init.js +11 -7
- package/lib/use-lunatic/use-lunatic.js +3 -1
- package/lib/utils/get-component-value.js +38 -0
- package/package.json +1 -1
|
@@ -3,10 +3,12 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports["default"] = exports.Default = void 0;
|
|
6
|
+
exports["default"] = exports.Loop = exports.Default = exports.ComponentSet = void 0;
|
|
7
7
|
var _react = _interopRequireDefault(require("react"));
|
|
8
8
|
var _orchestrator = _interopRequireDefault(require("../utils/orchestrator"));
|
|
9
9
|
var _source = _interopRequireDefault(require("./source"));
|
|
10
|
+
var _sourceComponentset = _interopRequireDefault(require("./sourceComponentset"));
|
|
11
|
+
var _sourceLoop = _interopRequireDefault(require("./sourceLoop"));
|
|
10
12
|
var _defaultArgTypes = _interopRequireDefault(require("../utils/default-arg-types"));
|
|
11
13
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
12
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
@@ -40,4 +42,18 @@ Default.args = {
|
|
|
40
42
|
id: 'checkboxGroup',
|
|
41
43
|
source: _source["default"],
|
|
42
44
|
shortcut: true
|
|
45
|
+
};
|
|
46
|
+
var ComponentSet = Template.bind({});
|
|
47
|
+
exports.ComponentSet = ComponentSet;
|
|
48
|
+
ComponentSet.args = {
|
|
49
|
+
id: 'checkboxGroup',
|
|
50
|
+
source: _sourceComponentset["default"],
|
|
51
|
+
shortcut: true
|
|
52
|
+
};
|
|
53
|
+
var Loop = Template.bind({});
|
|
54
|
+
exports.Loop = Loop;
|
|
55
|
+
Loop.args = {
|
|
56
|
+
id: 'checkboxGroup',
|
|
57
|
+
source: _sourceLoop["default"],
|
|
58
|
+
shortcut: true
|
|
43
59
|
};
|
|
@@ -0,0 +1,424 @@
|
|
|
1
|
+
{
|
|
2
|
+
"maxPage": "5",
|
|
3
|
+
"components": [
|
|
4
|
+
{
|
|
5
|
+
"id": "component-set",
|
|
6
|
+
"componentType": "ComponentSet",
|
|
7
|
+
"page": "1",
|
|
8
|
+
"conditionFilter": { "value": "true", "type": "VTL" },
|
|
9
|
+
"label": {
|
|
10
|
+
"value": "\"## Who are you?\"",
|
|
11
|
+
"type": "VTL|MD"
|
|
12
|
+
},
|
|
13
|
+
"description": {
|
|
14
|
+
"value": "\"This is your opportunity to tell me about yourself!\"",
|
|
15
|
+
"type": "VTL|MD"
|
|
16
|
+
},
|
|
17
|
+
"components": [
|
|
18
|
+
{
|
|
19
|
+
"id": "checkboxbooleanGroupNumeric",
|
|
20
|
+
"componentType": "CheckboxGroup",
|
|
21
|
+
"label": {
|
|
22
|
+
"value": "Situation matrimoniale",
|
|
23
|
+
"type": "VTL|MD"
|
|
24
|
+
},
|
|
25
|
+
"hierarchy": {
|
|
26
|
+
"sequence": {
|
|
27
|
+
"id": "kmnnjaf1",
|
|
28
|
+
"label": {
|
|
29
|
+
"value": "Situation matrimoniale",
|
|
30
|
+
"type": "VTL|MD"
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
"subSequence": {
|
|
34
|
+
"id": "kmw3dz2a",
|
|
35
|
+
"page": "2",
|
|
36
|
+
"label": {
|
|
37
|
+
"value": "Mois préférés de l'année",
|
|
38
|
+
"type": "VTL|MD"
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
"missingResponse": { "name": "SITUMATRI_MISSING" },
|
|
43
|
+
"responses": [
|
|
44
|
+
{
|
|
45
|
+
"id": "kmort6x9-QOP-kmosa98y",
|
|
46
|
+
"label": {
|
|
47
|
+
"value": "Française de naissance ou par réintégration",
|
|
48
|
+
"type": "VTL"
|
|
49
|
+
},
|
|
50
|
+
"response": { "name": "NATIO1N1" }
|
|
51
|
+
},
|
|
52
|
+
|
|
53
|
+
{
|
|
54
|
+
"id": "kmort6x9-QOP-kmos360k",
|
|
55
|
+
"label": {
|
|
56
|
+
"value": "\"Française par déclaration, naturalisation, option à la majorité\"",
|
|
57
|
+
"type": "VTL"
|
|
58
|
+
},
|
|
59
|
+
"response": { "name": "NATIO1N2" }
|
|
60
|
+
},
|
|
61
|
+
|
|
62
|
+
{
|
|
63
|
+
"id": "kmort6x9-QOP-kmos37e1",
|
|
64
|
+
"label": { "value": "Étrangère", "type": "VTL" },
|
|
65
|
+
"response": { "name": "NATIO1N3" }
|
|
66
|
+
},
|
|
67
|
+
|
|
68
|
+
{
|
|
69
|
+
"id": "kmort6x9-QOP-kmorue9c",
|
|
70
|
+
"label": {
|
|
71
|
+
"value": "Apatride (pas de nationalité)",
|
|
72
|
+
"type": "VTL"
|
|
73
|
+
},
|
|
74
|
+
"response": { "name": "NATIO1N4" }
|
|
75
|
+
}
|
|
76
|
+
]
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
"id": "checkboxbooleanGroupAlpha",
|
|
80
|
+
"componentType": "CheckboxGroup",
|
|
81
|
+
"label": {
|
|
82
|
+
"value": "Mois préférés de l'année",
|
|
83
|
+
"type": "VTL|MD"
|
|
84
|
+
},
|
|
85
|
+
|
|
86
|
+
"hierarchy": {
|
|
87
|
+
"sequence": {
|
|
88
|
+
"id": "kmnnjaf1",
|
|
89
|
+
"page": "1",
|
|
90
|
+
"label": {
|
|
91
|
+
"value": "Situation matrimoniale",
|
|
92
|
+
"type": "VTL|MD"
|
|
93
|
+
}
|
|
94
|
+
},
|
|
95
|
+
"subSequence": {
|
|
96
|
+
"id": "kmw3dz2a",
|
|
97
|
+
"label": {
|
|
98
|
+
"value": "Mois préférés de l'année",
|
|
99
|
+
"type": "VTL|MD"
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
},
|
|
103
|
+
"missingResponse": { "name": "SITUMATRI_MISSING" },
|
|
104
|
+
"bindingDependencies": [
|
|
105
|
+
"MOIS1",
|
|
106
|
+
"MOIS2",
|
|
107
|
+
"MOIS3",
|
|
108
|
+
"MOIS4",
|
|
109
|
+
"MOIS5",
|
|
110
|
+
"MOIS6",
|
|
111
|
+
"MOIS7",
|
|
112
|
+
"MOIS8",
|
|
113
|
+
"MOIS9",
|
|
114
|
+
"MOIS10",
|
|
115
|
+
"MOIS11",
|
|
116
|
+
"MOIS12"
|
|
117
|
+
],
|
|
118
|
+
"responses": [
|
|
119
|
+
{
|
|
120
|
+
"id": "mois1",
|
|
121
|
+
"label": {
|
|
122
|
+
"value": "Janvier",
|
|
123
|
+
"type": "VTL|MD"
|
|
124
|
+
},
|
|
125
|
+
"response": { "name": "MOIS1" }
|
|
126
|
+
},
|
|
127
|
+
|
|
128
|
+
{
|
|
129
|
+
"id": "mois2",
|
|
130
|
+
"label": {
|
|
131
|
+
"value": "Février",
|
|
132
|
+
"type": "VTL|MD"
|
|
133
|
+
},
|
|
134
|
+
"response": { "name": "MOIS2" }
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
"id": "mois3",
|
|
138
|
+
"label": {
|
|
139
|
+
"value": "Mars",
|
|
140
|
+
"type": "VTL|MD"
|
|
141
|
+
},
|
|
142
|
+
"response": { "name": "MOIS3" }
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
"id": "mois4",
|
|
146
|
+
"label": {
|
|
147
|
+
"value": "Avril",
|
|
148
|
+
"type": "VTL|MD"
|
|
149
|
+
},
|
|
150
|
+
"response": { "name": "MOIS4" }
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
"id": "mois5",
|
|
154
|
+
"label": {
|
|
155
|
+
"value": "Mai",
|
|
156
|
+
"type": "VTL|MD"
|
|
157
|
+
},
|
|
158
|
+
"response": { "name": "MOIS5" }
|
|
159
|
+
},
|
|
160
|
+
{
|
|
161
|
+
"id": "mois6",
|
|
162
|
+
"label": {
|
|
163
|
+
"value": "Juin",
|
|
164
|
+
"type": "VTL|MD"
|
|
165
|
+
},
|
|
166
|
+
"response": { "name": "MOIS6" }
|
|
167
|
+
},
|
|
168
|
+
{
|
|
169
|
+
"id": "mois7",
|
|
170
|
+
"label": {
|
|
171
|
+
"value": "Juillet",
|
|
172
|
+
"type": "VTL|MD"
|
|
173
|
+
},
|
|
174
|
+
"response": { "name": "MOIS7" }
|
|
175
|
+
},
|
|
176
|
+
{
|
|
177
|
+
"id": "mois8",
|
|
178
|
+
"label": {
|
|
179
|
+
"value": "Août",
|
|
180
|
+
"type": "VTL|MD"
|
|
181
|
+
},
|
|
182
|
+
"response": { "name": "MOIS8" }
|
|
183
|
+
},
|
|
184
|
+
{
|
|
185
|
+
"id": "mois9",
|
|
186
|
+
"label": {
|
|
187
|
+
"value": "Septembre",
|
|
188
|
+
"type": "VTL|MD"
|
|
189
|
+
},
|
|
190
|
+
"response": { "name": "MOIS9" }
|
|
191
|
+
},
|
|
192
|
+
{
|
|
193
|
+
"id": "mois10",
|
|
194
|
+
"label": {
|
|
195
|
+
"value": "Octobre",
|
|
196
|
+
"type": "VTL|MD"
|
|
197
|
+
},
|
|
198
|
+
"response": { "name": "MOIS10" }
|
|
199
|
+
},
|
|
200
|
+
{
|
|
201
|
+
"id": "mois11",
|
|
202
|
+
"label": {
|
|
203
|
+
"value": "Novembre",
|
|
204
|
+
"type": "VTL|MD"
|
|
205
|
+
},
|
|
206
|
+
"response": { "name": "MOIS11" }
|
|
207
|
+
},
|
|
208
|
+
{
|
|
209
|
+
"id": "mois12",
|
|
210
|
+
"label": {
|
|
211
|
+
"value": "Décembre",
|
|
212
|
+
"type": "VTL|MD"
|
|
213
|
+
},
|
|
214
|
+
"response": { "name": "MOIS12" }
|
|
215
|
+
}
|
|
216
|
+
]
|
|
217
|
+
}
|
|
218
|
+
]
|
|
219
|
+
},
|
|
220
|
+
{
|
|
221
|
+
"id": "seq",
|
|
222
|
+
"componentType": "Sequence",
|
|
223
|
+
"label": {
|
|
224
|
+
"value": "\"Merci !\"",
|
|
225
|
+
"type": "VTL|MD"
|
|
226
|
+
},
|
|
227
|
+
"conditionFilter": { "value": "true", "type": "VTL" },
|
|
228
|
+
"page": "2"
|
|
229
|
+
}
|
|
230
|
+
],
|
|
231
|
+
"variables": [
|
|
232
|
+
{
|
|
233
|
+
"variableType": "COLLECTED",
|
|
234
|
+
"name": "NATIO1N1",
|
|
235
|
+
"values": {
|
|
236
|
+
"PREVIOUS": null,
|
|
237
|
+
"COLLECTED": null,
|
|
238
|
+
"FORCED": null,
|
|
239
|
+
"EDITED": null,
|
|
240
|
+
"INPUTED": null
|
|
241
|
+
}
|
|
242
|
+
},
|
|
243
|
+
|
|
244
|
+
{
|
|
245
|
+
"variableType": "COLLECTED",
|
|
246
|
+
"name": "NATIO1N2",
|
|
247
|
+
"values": {
|
|
248
|
+
"PREVIOUS": null,
|
|
249
|
+
"COLLECTED": null,
|
|
250
|
+
"FORCED": null,
|
|
251
|
+
"EDITED": null,
|
|
252
|
+
"INPUTED": null
|
|
253
|
+
}
|
|
254
|
+
},
|
|
255
|
+
|
|
256
|
+
{
|
|
257
|
+
"variableType": "COLLECTED",
|
|
258
|
+
"name": "NATIO1N3",
|
|
259
|
+
"values": {
|
|
260
|
+
"PREVIOUS": null,
|
|
261
|
+
"COLLECTED": null,
|
|
262
|
+
"FORCED": null,
|
|
263
|
+
"EDITED": null,
|
|
264
|
+
"INPUTED": null
|
|
265
|
+
}
|
|
266
|
+
},
|
|
267
|
+
|
|
268
|
+
{
|
|
269
|
+
"variableType": "COLLECTED",
|
|
270
|
+
"name": "NATIO1N4",
|
|
271
|
+
"values": {
|
|
272
|
+
"PREVIOUS": null,
|
|
273
|
+
"COLLECTED": null,
|
|
274
|
+
"FORCED": null,
|
|
275
|
+
"EDITED": null,
|
|
276
|
+
"INPUTED": null
|
|
277
|
+
}
|
|
278
|
+
},
|
|
279
|
+
|
|
280
|
+
{
|
|
281
|
+
"variableType": "COLLECTED",
|
|
282
|
+
"name": "MOIS1",
|
|
283
|
+
"values": {
|
|
284
|
+
"PREVIOUS": null,
|
|
285
|
+
"COLLECTED": null,
|
|
286
|
+
"FORCED": null,
|
|
287
|
+
"EDITED": null,
|
|
288
|
+
"INPUTED": null
|
|
289
|
+
}
|
|
290
|
+
},
|
|
291
|
+
|
|
292
|
+
{
|
|
293
|
+
"variableType": "COLLECTED",
|
|
294
|
+
"name": "MOIS2",
|
|
295
|
+
"values": {
|
|
296
|
+
"PREVIOUS": null,
|
|
297
|
+
"COLLECTED": null,
|
|
298
|
+
"FORCED": null,
|
|
299
|
+
"EDITED": null,
|
|
300
|
+
"INPUTED": null
|
|
301
|
+
}
|
|
302
|
+
},
|
|
303
|
+
|
|
304
|
+
{
|
|
305
|
+
"variableType": "COLLECTED",
|
|
306
|
+
"name": "MOIS3",
|
|
307
|
+
"values": {
|
|
308
|
+
"PREVIOUS": null,
|
|
309
|
+
"COLLECTED": null,
|
|
310
|
+
"FORCED": null,
|
|
311
|
+
"EDITED": null,
|
|
312
|
+
"INPUTED": null
|
|
313
|
+
}
|
|
314
|
+
},
|
|
315
|
+
|
|
316
|
+
{
|
|
317
|
+
"variableType": "COLLECTED",
|
|
318
|
+
"name": "MOIS4",
|
|
319
|
+
"values": {
|
|
320
|
+
"PREVIOUS": null,
|
|
321
|
+
"COLLECTED": null,
|
|
322
|
+
"FORCED": null,
|
|
323
|
+
"EDITED": null,
|
|
324
|
+
"INPUTED": null
|
|
325
|
+
}
|
|
326
|
+
},
|
|
327
|
+
|
|
328
|
+
{
|
|
329
|
+
"variableType": "COLLECTED",
|
|
330
|
+
"name": "MOIS5",
|
|
331
|
+
"values": {
|
|
332
|
+
"PREVIOUS": null,
|
|
333
|
+
"COLLECTED": null,
|
|
334
|
+
"FORCED": null,
|
|
335
|
+
"EDITED": null,
|
|
336
|
+
"INPUTED": null
|
|
337
|
+
}
|
|
338
|
+
},
|
|
339
|
+
|
|
340
|
+
{
|
|
341
|
+
"variableType": "COLLECTED",
|
|
342
|
+
"name": "MOIS6",
|
|
343
|
+
"values": {
|
|
344
|
+
"PREVIOUS": null,
|
|
345
|
+
"COLLECTED": null,
|
|
346
|
+
"FORCED": null,
|
|
347
|
+
"EDITED": null,
|
|
348
|
+
"INPUTED": null
|
|
349
|
+
}
|
|
350
|
+
},
|
|
351
|
+
|
|
352
|
+
{
|
|
353
|
+
"variableType": "COLLECTED",
|
|
354
|
+
"name": "MOIS7",
|
|
355
|
+
"values": {
|
|
356
|
+
"PREVIOUS": null,
|
|
357
|
+
"COLLECTED": null,
|
|
358
|
+
"FORCED": null,
|
|
359
|
+
"EDITED": null,
|
|
360
|
+
"INPUTED": null
|
|
361
|
+
}
|
|
362
|
+
},
|
|
363
|
+
|
|
364
|
+
{
|
|
365
|
+
"variableType": "COLLECTED",
|
|
366
|
+
"name": "MOIS8",
|
|
367
|
+
"values": {
|
|
368
|
+
"PREVIOUS": null,
|
|
369
|
+
"COLLECTED": null,
|
|
370
|
+
"FORCED": null,
|
|
371
|
+
"EDITED": null,
|
|
372
|
+
"INPUTED": null
|
|
373
|
+
}
|
|
374
|
+
},
|
|
375
|
+
|
|
376
|
+
{
|
|
377
|
+
"variableType": "COLLECTED",
|
|
378
|
+
"name": "MOIS9",
|
|
379
|
+
"values": {
|
|
380
|
+
"PREVIOUS": null,
|
|
381
|
+
"COLLECTED": null,
|
|
382
|
+
"FORCED": null,
|
|
383
|
+
"EDITED": null,
|
|
384
|
+
"INPUTED": null
|
|
385
|
+
}
|
|
386
|
+
},
|
|
387
|
+
|
|
388
|
+
{
|
|
389
|
+
"variableType": "COLLECTED",
|
|
390
|
+
"name": "MOIS10",
|
|
391
|
+
"values": {
|
|
392
|
+
"PREVIOUS": null,
|
|
393
|
+
"COLLECTED": null,
|
|
394
|
+
"FORCED": null,
|
|
395
|
+
"EDITED": null,
|
|
396
|
+
"INPUTED": null
|
|
397
|
+
}
|
|
398
|
+
},
|
|
399
|
+
|
|
400
|
+
{
|
|
401
|
+
"variableType": "COLLECTED",
|
|
402
|
+
"name": "MOIS11",
|
|
403
|
+
"values": {
|
|
404
|
+
"PREVIOUS": null,
|
|
405
|
+
"COLLECTED": null,
|
|
406
|
+
"FORCED": null,
|
|
407
|
+
"EDITED": null,
|
|
408
|
+
"INPUTED": null
|
|
409
|
+
}
|
|
410
|
+
},
|
|
411
|
+
|
|
412
|
+
{
|
|
413
|
+
"variableType": "COLLECTED",
|
|
414
|
+
"name": "MOIS12",
|
|
415
|
+
"values": {
|
|
416
|
+
"PREVIOUS": null,
|
|
417
|
+
"COLLECTED": null,
|
|
418
|
+
"FORCED": null,
|
|
419
|
+
"EDITED": null,
|
|
420
|
+
"INPUTED": null
|
|
421
|
+
}
|
|
422
|
+
}
|
|
423
|
+
]
|
|
424
|
+
}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
{
|
|
2
|
+
"maxPage": "5",
|
|
3
|
+
"components": [
|
|
4
|
+
{
|
|
5
|
+
"id": "component-set",
|
|
6
|
+
"componentType": "Loop",
|
|
7
|
+
"page": "1",
|
|
8
|
+
"conditionFilter": { "value": "true", "type": "VTL" },
|
|
9
|
+
"iterations": { "value": 2, "type": "VTL" },
|
|
10
|
+
"label": {
|
|
11
|
+
"value": "\"## Who are you?\"",
|
|
12
|
+
"type": "VTL|MD"
|
|
13
|
+
},
|
|
14
|
+
"description": {
|
|
15
|
+
"value": "\"This is your opportunity to tell me about yourself!\"",
|
|
16
|
+
"type": "VTL|MD"
|
|
17
|
+
},
|
|
18
|
+
"components": [
|
|
19
|
+
{
|
|
20
|
+
"id": "checkboxbooleanGroupNumeric",
|
|
21
|
+
"componentType": "CheckboxGroup",
|
|
22
|
+
"label": {
|
|
23
|
+
"value": "Est-ce que vous travaillez à l'Insee ?",
|
|
24
|
+
"type": "VTL|MD"
|
|
25
|
+
},
|
|
26
|
+
"missingResponse": { "name": "SITUMATRI_MISSING" },
|
|
27
|
+
"responses": [
|
|
28
|
+
{
|
|
29
|
+
"id": "kmort6x9-QOP-kmosa98y",
|
|
30
|
+
"label": {
|
|
31
|
+
"value": "non",
|
|
32
|
+
"type": "VTL"
|
|
33
|
+
},
|
|
34
|
+
"response": { "name": "NON" }
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
"id": "kmort6x9-QOP-kmos360k",
|
|
38
|
+
"label": {
|
|
39
|
+
"value": "\"oui\"",
|
|
40
|
+
"type": "VTL"
|
|
41
|
+
},
|
|
42
|
+
"response": { "name": "OUI" }
|
|
43
|
+
}
|
|
44
|
+
]
|
|
45
|
+
}
|
|
46
|
+
]
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
"id": "seq",
|
|
50
|
+
"componentType": "Sequence",
|
|
51
|
+
"label": {
|
|
52
|
+
"value": "\"Merci !\"",
|
|
53
|
+
"type": "VTL|MD"
|
|
54
|
+
},
|
|
55
|
+
"conditionFilter": { "value": "true", "type": "VTL" },
|
|
56
|
+
"page": "2"
|
|
57
|
+
}
|
|
58
|
+
],
|
|
59
|
+
"variables": [
|
|
60
|
+
{
|
|
61
|
+
"variableType": "COLLECTED",
|
|
62
|
+
"name": "OUI",
|
|
63
|
+
"values": {
|
|
64
|
+
"PREVIOUS": [null],
|
|
65
|
+
"COLLECTED": [null],
|
|
66
|
+
"FORCED": [null],
|
|
67
|
+
"EDITED": [null],
|
|
68
|
+
"INPUTED": [null]
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
"variableType": "COLLECTED",
|
|
73
|
+
"name": "NON",
|
|
74
|
+
"values": {
|
|
75
|
+
"PREVIOUS": [null],
|
|
76
|
+
"COLLECTED": [null],
|
|
77
|
+
"FORCED": [null],
|
|
78
|
+
"EDITED": [null],
|
|
79
|
+
"INPUTED": [null]
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
]
|
|
83
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = exports.Default = void 0;
|
|
7
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
|
+
var _defaultArgTypes = _interopRequireDefault(require("../utils/default-arg-types"));
|
|
9
|
+
var _orchestrator = _interopRequireDefault(require("../utils/orchestrator"));
|
|
10
|
+
var _source = _interopRequireDefault(require("./source"));
|
|
11
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
12
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
13
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
14
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
15
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
16
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
17
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
18
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
19
|
+
var stories = {
|
|
20
|
+
title: 'Components/Modal',
|
|
21
|
+
component: _orchestrator["default"],
|
|
22
|
+
argTypes: _defaultArgTypes["default"]
|
|
23
|
+
};
|
|
24
|
+
var _default = stories;
|
|
25
|
+
exports["default"] = _default;
|
|
26
|
+
var Template = function Template(args) {
|
|
27
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_orchestrator["default"], _objectSpread({}, args));
|
|
28
|
+
};
|
|
29
|
+
var Default = Template.bind({});
|
|
30
|
+
exports.Default = Default;
|
|
31
|
+
Default.args = {
|
|
32
|
+
id: 'modal',
|
|
33
|
+
source: _source["default"]
|
|
34
|
+
};
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
{
|
|
2
|
+
"maxPage": "4",
|
|
3
|
+
"components": [
|
|
4
|
+
{
|
|
5
|
+
"id": "kze792d8",
|
|
6
|
+
"componentType": "InputNumber",
|
|
7
|
+
"mandatory": false,
|
|
8
|
+
"page": "1",
|
|
9
|
+
"min": 0,
|
|
10
|
+
"max": 10,
|
|
11
|
+
"decimals": 0,
|
|
12
|
+
"label": {
|
|
13
|
+
"value": "\"➡ 1. \" || \"In put for Number \"",
|
|
14
|
+
"type": "VTL|MD"
|
|
15
|
+
},
|
|
16
|
+
"description": { "value": "\"Description\"", "type": "VTL|MD" },
|
|
17
|
+
"conditionFilter": { "value": "true", "type": "VTL" },
|
|
18
|
+
"response": { "name": "NB" }
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"id": "modaltoto",
|
|
22
|
+
"componentType": "ConfirmationModal",
|
|
23
|
+
"conditionFilter": { "value": "true", "type": "VTL" },
|
|
24
|
+
"page": "2",
|
|
25
|
+
"label": {
|
|
26
|
+
"value": "\"### Est-ce correcte ? \"",
|
|
27
|
+
"type": "VTL|MD"
|
|
28
|
+
},
|
|
29
|
+
"description": {
|
|
30
|
+
"value": "\"Vous avez renseigné : \" || cast(NB, string) || \".\"",
|
|
31
|
+
"type": "VTL|MD"
|
|
32
|
+
},
|
|
33
|
+
"declarations": [
|
|
34
|
+
{
|
|
35
|
+
"id": "kb9hi4j0-krnoclfe",
|
|
36
|
+
"declarationType": "INSTRUCTION",
|
|
37
|
+
"position": "BEFORE_QUESTION_TEXT",
|
|
38
|
+
"label": {
|
|
39
|
+
"value": "\"Déclaration Before\"",
|
|
40
|
+
"type": "VTL|MD"
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
"id": "kb9hi4j0-krnoclfe",
|
|
45
|
+
"declarationType": "INSTRUCTION",
|
|
46
|
+
"position": "AFTER_QUESTION_TEXT",
|
|
47
|
+
"label": {
|
|
48
|
+
"value": "\"Déclaration AFTER\"",
|
|
49
|
+
"type": "VTL|MD"
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
"id": "kb9hi4j0-krnoclfe",
|
|
54
|
+
"declarationType": "HELP",
|
|
55
|
+
"position": "DETACHABLE",
|
|
56
|
+
"label": {
|
|
57
|
+
"value": "\"Declaration Detachable\"",
|
|
58
|
+
"type": "VTL|MD"
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
]
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
"id": "modaltoto",
|
|
65
|
+
"componentType": "Sequence",
|
|
66
|
+
"conditionFilter": { "value": "false", "type": "VTL" },
|
|
67
|
+
"page": "3",
|
|
68
|
+
"label": {
|
|
69
|
+
"value": "toto to skip",
|
|
70
|
+
"type": "VTL"
|
|
71
|
+
}
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
"id": "modaltoto",
|
|
75
|
+
"componentType": "Sequence",
|
|
76
|
+
"conditionFilter": { "value": "true", "type": "VTL" },
|
|
77
|
+
"page": "4",
|
|
78
|
+
"label": {
|
|
79
|
+
"value": "toto to not skip",
|
|
80
|
+
"type": "VTL"
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
],
|
|
84
|
+
"variables": [
|
|
85
|
+
{
|
|
86
|
+
"variableType": "COLLECTED",
|
|
87
|
+
"name": "NB",
|
|
88
|
+
"values": {
|
|
89
|
+
"PREVIOUS": null,
|
|
90
|
+
"COLLECTED": null,
|
|
91
|
+
"FORCED": null,
|
|
92
|
+
"EDITED": null,
|
|
93
|
+
"INPUTED": null
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
]
|
|
97
|
+
}
|