@yungu-fed/question-editor 0.3.0 → 0.3.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.
- package/dist/index.css +1 -1
- package/dist/index.js +940 -891
- package/dist/index.mjs +1715 -1681
- package/dist/question/content-editor/QuestionContentOptionGroupEditor.d.ts.map +1 -1
- package/dist/question/player/QuestionOptionGroupPlayer.d.ts.map +1 -1
- package/dist/question/renderers/QuestionAdaptiveOptionList.d.ts +6 -0
- package/dist/question/renderers/QuestionAdaptiveOptionList.d.ts.map +1 -0
- package/dist/question/renderers/QuestionOptionGroupView.d.ts.map +1 -1
- package/dist/question/renderers/question-option-grid.d.ts +8 -0
- package/dist/question/renderers/question-option-grid.d.ts.map +1 -0
- package/package.json +15 -15
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
require('./index.css');function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var
|
|
1
|
+
require('./index.css');function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n6 = 0, F = function F() {}; return { s: F, n: function n() { return _n6 >= r.length ? { done: !0 } : { done: !1, value: r[_n6++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t.return || t.return(); } finally { if (u) throw o; } } }; }
|
|
2
2
|
function _toArray(r) { return _arrayWithHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableRest(); }
|
|
3
3
|
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
4
4
|
function _toConsumableArray(r) { return _arrayWithoutHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableSpread(); }
|
|
@@ -155,8 +155,8 @@ function C(e) {
|
|
|
155
155
|
return e;
|
|
156
156
|
}
|
|
157
157
|
var ee = ["richText", "inlineFill", "wordBuilder", "fill", "choice", "judgement", "classification", "lineConnect", "matching", "ordering", "textMarker", "textResponse"],
|
|
158
|
-
|
|
159
|
-
|
|
158
|
+
w = ["solvingProcess", "solvingStrategy", "keyInformation", "commonMistake", "solvingHint", "scoringRule", "sampleAnswer", "extensionExplanation"],
|
|
159
|
+
T = {
|
|
160
160
|
commonMistake: "\u6613\u9519\u63D0\u9192",
|
|
161
161
|
extensionExplanation: "\u62D3\u5C55\u8BB2\u89E3",
|
|
162
162
|
keyInformation: "\u5173\u952E\u4FE1\u606F",
|
|
@@ -166,7 +166,7 @@ var ee = ["richText", "inlineFill", "wordBuilder", "fill", "choice", "judgement"
|
|
|
166
166
|
solvingProcess: "\u89E3\u9898\u8FC7\u7A0B",
|
|
167
167
|
solvingStrategy: "\u89E3\u9898\u7B56\u7565"
|
|
168
168
|
},
|
|
169
|
-
|
|
169
|
+
te = {
|
|
170
170
|
commonMistake: "Common mistake reminder",
|
|
171
171
|
extensionExplanation: "Extension explanation",
|
|
172
172
|
keyInformation: "Key information",
|
|
@@ -176,7 +176,7 @@ var ee = ["richText", "inlineFill", "wordBuilder", "fill", "choice", "judgement"
|
|
|
176
176
|
solvingProcess: "Solving process",
|
|
177
177
|
solvingStrategy: "Solving strategy"
|
|
178
178
|
},
|
|
179
|
-
|
|
179
|
+
ne = {
|
|
180
180
|
choice: "\u9009\u62E9",
|
|
181
181
|
classification: "\u5206\u7C7B",
|
|
182
182
|
fill: "\u586B\u7A7A",
|
|
@@ -190,7 +190,7 @@ var ee = ["richText", "inlineFill", "wordBuilder", "fill", "choice", "judgement"
|
|
|
190
190
|
textResponse: "\u6587\u672C\u4F5C\u7B54",
|
|
191
191
|
wordBuilder: "\u7EC4\u8BCD\u62FC\u5199"
|
|
192
192
|
},
|
|
193
|
-
|
|
193
|
+
re = {
|
|
194
194
|
choice: "Choice",
|
|
195
195
|
classification: "Classification",
|
|
196
196
|
fill: "Blank group",
|
|
@@ -204,7 +204,7 @@ var ee = ["richText", "inlineFill", "wordBuilder", "fill", "choice", "judgement"
|
|
|
204
204
|
textResponse: "Text response",
|
|
205
205
|
wordBuilder: "Word builder"
|
|
206
206
|
};
|
|
207
|
-
function
|
|
207
|
+
function ie() {
|
|
208
208
|
return {
|
|
209
209
|
description: "",
|
|
210
210
|
elements: [],
|
|
@@ -220,21 +220,21 @@ function ae() {
|
|
|
220
220
|
version: ""
|
|
221
221
|
};
|
|
222
222
|
}
|
|
223
|
-
function
|
|
223
|
+
function ae(e) {
|
|
224
224
|
var t = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
|
|
225
225
|
return {
|
|
226
|
-
clientId:
|
|
227
|
-
enName:
|
|
228
|
-
name:
|
|
226
|
+
clientId: ye(),
|
|
227
|
+
enName: _e(e),
|
|
228
|
+
name: ge(e),
|
|
229
229
|
type: e
|
|
230
230
|
};
|
|
231
231
|
}
|
|
232
|
-
function
|
|
232
|
+
function oe(e) {
|
|
233
233
|
var t = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
|
|
234
|
-
var n =
|
|
235
|
-
return e === "classification" || e === "fill" || e === "richText" || e === "textMarker" || e === "textResponse" || e === "ordering" ?
|
|
234
|
+
var n = ye();
|
|
235
|
+
return e === "classification" || e === "fill" || e === "richText" || e === "textMarker" || e === "textResponse" || e === "ordering" ? be(e, n) : se(e, n);
|
|
236
236
|
}
|
|
237
|
-
function
|
|
237
|
+
function se(e, t) {
|
|
238
238
|
switch (e) {
|
|
239
239
|
case "inlineFill":
|
|
240
240
|
return {
|
|
@@ -243,8 +243,8 @@ function ce(e, t) {
|
|
|
243
243
|
allowCandidateReuse: !1,
|
|
244
244
|
candidateMode: "none"
|
|
245
245
|
},
|
|
246
|
-
enName:
|
|
247
|
-
name:
|
|
246
|
+
enName: D(e),
|
|
247
|
+
name: E(e),
|
|
248
248
|
type: e
|
|
249
249
|
};
|
|
250
250
|
case "wordBuilder":
|
|
@@ -253,8 +253,8 @@ function ce(e, t) {
|
|
|
253
253
|
config: {
|
|
254
254
|
builderMode: "spelling"
|
|
255
255
|
},
|
|
256
|
-
enName:
|
|
257
|
-
name:
|
|
256
|
+
enName: D(e),
|
|
257
|
+
name: E(e),
|
|
258
258
|
type: e
|
|
259
259
|
};
|
|
260
260
|
case "judgement":
|
|
@@ -263,8 +263,8 @@ function ce(e, t) {
|
|
|
263
263
|
config: {
|
|
264
264
|
judgeAnswerMode: "correctWrong"
|
|
265
265
|
},
|
|
266
|
-
enName:
|
|
267
|
-
name:
|
|
266
|
+
enName: D(e),
|
|
267
|
+
name: E(e),
|
|
268
268
|
type: e
|
|
269
269
|
};
|
|
270
270
|
case "choice":
|
|
@@ -275,17 +275,17 @@ function ce(e, t) {
|
|
|
275
275
|
renderer: "standard",
|
|
276
276
|
selectionType: "single"
|
|
277
277
|
},
|
|
278
|
-
enName:
|
|
279
|
-
name:
|
|
278
|
+
enName: D(e),
|
|
279
|
+
name: E(e),
|
|
280
280
|
type: e
|
|
281
281
|
};
|
|
282
282
|
case "lineConnect":
|
|
283
|
-
return
|
|
283
|
+
return ce(e, t);
|
|
284
284
|
case "matching":
|
|
285
|
-
return
|
|
285
|
+
return ce(e, t);
|
|
286
286
|
}
|
|
287
287
|
}
|
|
288
|
-
function
|
|
288
|
+
function ce(e, t) {
|
|
289
289
|
return {
|
|
290
290
|
clientId: t,
|
|
291
291
|
config: {
|
|
@@ -295,74 +295,74 @@ function le(e, t) {
|
|
|
295
295
|
labelStyle: "upperAlpha"
|
|
296
296
|
}]
|
|
297
297
|
},
|
|
298
|
-
enName:
|
|
299
|
-
name:
|
|
298
|
+
enName: D(e),
|
|
299
|
+
name: E(e),
|
|
300
300
|
type: e
|
|
301
301
|
};
|
|
302
302
|
}
|
|
303
|
-
function
|
|
303
|
+
function le(e, t) {
|
|
304
304
|
return C(C({}, e), {}, {
|
|
305
305
|
extras: e.extras.filter(function (e) {
|
|
306
306
|
return e.clientId !== t;
|
|
307
307
|
})
|
|
308
308
|
});
|
|
309
309
|
}
|
|
310
|
-
function
|
|
310
|
+
function ue(e, t) {
|
|
311
311
|
return C(C({}, e), {}, {
|
|
312
312
|
elements: e.elements.filter(function (e) {
|
|
313
313
|
return e.clientId !== t;
|
|
314
314
|
})
|
|
315
315
|
});
|
|
316
316
|
}
|
|
317
|
-
function
|
|
317
|
+
function de(e, t, n) {
|
|
318
318
|
var r = e.elements.findIndex(function (e) {
|
|
319
319
|
return e.clientId === t;
|
|
320
320
|
}),
|
|
321
321
|
i = r + n;
|
|
322
322
|
if (r < 0 || i < 0 || i >= e.elements.length) return e;
|
|
323
|
-
var a =
|
|
324
|
-
o =
|
|
323
|
+
var a = xe(e.elements, r),
|
|
324
|
+
o = xe(e.elements, i);
|
|
325
325
|
return !a || !o ? e : C(C({}, e), {}, {
|
|
326
326
|
elements: e.elements.map(function (e, t) {
|
|
327
327
|
return t === r ? o : t === i ? a : e;
|
|
328
328
|
})
|
|
329
329
|
});
|
|
330
330
|
}
|
|
331
|
-
function
|
|
331
|
+
function fe(e, t, n) {
|
|
332
332
|
return C(C({}, e), {}, {
|
|
333
333
|
extras: e.extras.map(function (e) {
|
|
334
334
|
return e.clientId === t ? n : e;
|
|
335
335
|
})
|
|
336
336
|
});
|
|
337
337
|
}
|
|
338
|
-
function
|
|
338
|
+
function pe(e, t, n) {
|
|
339
339
|
return C(C({}, e), {}, {
|
|
340
340
|
elements: e.elements.map(function (e) {
|
|
341
341
|
return e.clientId === t ? n : e;
|
|
342
342
|
})
|
|
343
343
|
});
|
|
344
344
|
}
|
|
345
|
-
function
|
|
345
|
+
function me(e, t) {
|
|
346
346
|
return C(C({}, e), {}, {
|
|
347
347
|
globalConfig: C(C({}, e.globalConfig), t)
|
|
348
348
|
});
|
|
349
349
|
}
|
|
350
|
-
function
|
|
350
|
+
function he(e, t) {
|
|
351
351
|
return C(C({}, e), t);
|
|
352
352
|
}
|
|
353
|
-
function
|
|
353
|
+
function E(e) {
|
|
354
|
+
return ne[e];
|
|
355
|
+
}
|
|
356
|
+
function D(e) {
|
|
354
357
|
return re[e];
|
|
355
358
|
}
|
|
356
|
-
function
|
|
357
|
-
return
|
|
359
|
+
function ge(e) {
|
|
360
|
+
return ve(T, e);
|
|
358
361
|
}
|
|
359
362
|
function _e(e) {
|
|
360
|
-
return
|
|
361
|
-
}
|
|
362
|
-
function ve(e) {
|
|
363
|
-
return ye(ne, e);
|
|
363
|
+
return ve(te, e);
|
|
364
364
|
}
|
|
365
|
-
function
|
|
365
|
+
function ve(e, t) {
|
|
366
366
|
var n, r;
|
|
367
367
|
return (n = (r = Object.entries(e).find(function (_ref) {
|
|
368
368
|
var _ref2 = _slicedToArray(_ref, 1),
|
|
@@ -370,24 +370,24 @@ function ye(e, t) {
|
|
|
370
370
|
return e === t;
|
|
371
371
|
})) == null ? void 0 : r[1]) == null ? "" : n;
|
|
372
372
|
}
|
|
373
|
-
function
|
|
373
|
+
function ye() {
|
|
374
374
|
return h();
|
|
375
375
|
}
|
|
376
|
-
function
|
|
376
|
+
function be(e, t) {
|
|
377
377
|
return {
|
|
378
378
|
clientId: t,
|
|
379
379
|
config: {},
|
|
380
|
-
enName:
|
|
381
|
-
name:
|
|
380
|
+
enName: D(e),
|
|
381
|
+
name: E(e),
|
|
382
382
|
type: e
|
|
383
383
|
};
|
|
384
384
|
}
|
|
385
|
-
function
|
|
385
|
+
function xe(e, t) {
|
|
386
386
|
return e.find(function (e, n) {
|
|
387
387
|
return n === t;
|
|
388
388
|
});
|
|
389
389
|
}
|
|
390
|
-
var
|
|
390
|
+
var Se = {
|
|
391
391
|
nodes: [{
|
|
392
392
|
codecs: {
|
|
393
393
|
html: {
|
|
@@ -405,15 +405,15 @@ var Ce = {
|
|
|
405
405
|
},
|
|
406
406
|
serialize: function serialize(_ref4) {
|
|
407
407
|
var e = _ref4.node;
|
|
408
|
-
return e.type === "blank" ? "<span data-rte-node=\"blank\" data-blank-id=\"".concat(
|
|
408
|
+
return e.type === "blank" ? "<span data-rte-node=\"blank\" data-blank-id=\"".concat(we(e.blankId), "\" data-label=\"").concat(we(e.label), "\"></span>") : null;
|
|
409
409
|
}
|
|
410
410
|
},
|
|
411
411
|
json: {
|
|
412
412
|
deserialize: function deserialize(_ref5) {
|
|
413
413
|
var e = _ref5.input;
|
|
414
|
-
return
|
|
415
|
-
blankId:
|
|
416
|
-
label:
|
|
414
|
+
return Ce(e) ? {
|
|
415
|
+
blankId: we(e.blankId),
|
|
416
|
+
label: we(e.label),
|
|
417
417
|
children: [{
|
|
418
418
|
text: ""
|
|
419
419
|
}],
|
|
@@ -423,8 +423,8 @@ var Ce = {
|
|
|
423
423
|
serialize: function serialize(_ref6) {
|
|
424
424
|
var e = _ref6.node;
|
|
425
425
|
return e.type === "blank" ? {
|
|
426
|
-
blankId:
|
|
427
|
-
label:
|
|
426
|
+
blankId: we(e.blankId),
|
|
427
|
+
label: we(e.label),
|
|
428
428
|
type: "blank"
|
|
429
429
|
} : null;
|
|
430
430
|
}
|
|
@@ -438,35 +438,35 @@ var Ce = {
|
|
|
438
438
|
type: "blank"
|
|
439
439
|
}]
|
|
440
440
|
};
|
|
441
|
-
function
|
|
441
|
+
function Ce(e) {
|
|
442
442
|
return !!(e && _typeof(e) == "object" && "type" in e && e.type === "blank");
|
|
443
443
|
}
|
|
444
|
-
function
|
|
444
|
+
function we(e) {
|
|
445
445
|
return _typeof(e) == "string" ? e : "";
|
|
446
446
|
}
|
|
447
|
-
function
|
|
447
|
+
function Te() {
|
|
448
448
|
var e = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : "";
|
|
449
|
-
return
|
|
450
|
-
json:
|
|
449
|
+
return Ee({
|
|
450
|
+
json: Oe(e)
|
|
451
451
|
});
|
|
452
452
|
}
|
|
453
|
-
function
|
|
454
|
-
var t =
|
|
453
|
+
function Ee(e) {
|
|
454
|
+
var t = De(e);
|
|
455
455
|
return {
|
|
456
|
-
html:
|
|
456
|
+
html: je(t),
|
|
457
457
|
json: t,
|
|
458
|
-
text:
|
|
458
|
+
text: ke(t)
|
|
459
459
|
};
|
|
460
460
|
}
|
|
461
|
-
function
|
|
461
|
+
function De(t) {
|
|
462
462
|
var n;
|
|
463
463
|
return t != null && t.json ? (0, e.deserializeRichTextEditorJson)(t.json, {
|
|
464
|
-
plugins: [
|
|
464
|
+
plugins: [Se]
|
|
465
465
|
}) : t != null && t.html ? (0, e.deserializeRichTextEditorHtml)(t.html, {
|
|
466
|
-
plugins: [
|
|
467
|
-
}) :
|
|
466
|
+
plugins: [Se]
|
|
467
|
+
}) : Oe((n = t == null ? void 0 : t.text) == null ? "" : n);
|
|
468
468
|
}
|
|
469
|
-
function
|
|
469
|
+
function Oe(e) {
|
|
470
470
|
return [{
|
|
471
471
|
children: [{
|
|
472
472
|
text: e
|
|
@@ -474,22 +474,22 @@ function ke(e) {
|
|
|
474
474
|
type: "paragraph"
|
|
475
475
|
}];
|
|
476
476
|
}
|
|
477
|
-
function
|
|
478
|
-
return e.map(
|
|
477
|
+
function ke(e) {
|
|
478
|
+
return e.map(Ae).join("\n");
|
|
479
479
|
}
|
|
480
|
-
function
|
|
481
|
-
return "text" in e && _typeof(e.text) == "string" ? e.text :
|
|
480
|
+
function Ae(e) {
|
|
481
|
+
return "text" in e && _typeof(e.text) == "string" ? e.text : Me(e) ? e.type === "blank" ? "____" : e.children.map(Ae).join("") : "";
|
|
482
482
|
}
|
|
483
|
-
function
|
|
483
|
+
function je(t) {
|
|
484
484
|
return (0, e.serializeRichTextEditorHtml)(t, {
|
|
485
|
-
plugins: [
|
|
485
|
+
plugins: [Se]
|
|
486
486
|
});
|
|
487
487
|
}
|
|
488
|
-
function
|
|
488
|
+
function Me(e) {
|
|
489
489
|
return !!(e && _typeof(e) == "object" && "children" in e && Array.isArray(e.children));
|
|
490
490
|
}
|
|
491
|
-
var
|
|
492
|
-
function
|
|
491
|
+
var Ne = ["A", "B", "C", "D"];
|
|
492
|
+
function Pe(e, t) {
|
|
493
493
|
return e.columns.length <= 1 || t < 0 ? e : C(C({}, e), {}, {
|
|
494
494
|
columns: e.columns.filter(function (e, n) {
|
|
495
495
|
return n !== t;
|
|
@@ -503,67 +503,67 @@ function Fe(e, t) {
|
|
|
503
503
|
})
|
|
504
504
|
});
|
|
505
505
|
}
|
|
506
|
-
function
|
|
506
|
+
function Fe(e, t, n) {
|
|
507
507
|
return n === "single" ? e.includes(t) ? [] : [t] : e.includes(t) ? e.filter(function (e) {
|
|
508
508
|
return e !== t;
|
|
509
509
|
}) : [].concat(_toConsumableArray(e), [t]);
|
|
510
510
|
}
|
|
511
|
-
function
|
|
512
|
-
return e === "table" ? [
|
|
513
|
-
content:
|
|
511
|
+
function Ie(e) {
|
|
512
|
+
return e === "table" ? [Ue(1), Ue(2)] : [{
|
|
513
|
+
content: Te("\u9009\u9879"),
|
|
514
514
|
id: g()
|
|
515
515
|
}];
|
|
516
516
|
}
|
|
517
|
-
function
|
|
518
|
-
var n =
|
|
517
|
+
function Le(e, t) {
|
|
518
|
+
var n = We(e.map(function (e) {
|
|
519
519
|
return e.id;
|
|
520
520
|
})),
|
|
521
521
|
r = e.map(function (e, t) {
|
|
522
522
|
var r;
|
|
523
523
|
return {
|
|
524
|
-
content:
|
|
524
|
+
content: Ee(e.content),
|
|
525
525
|
id: (r = n[t]) == null ? g() : r
|
|
526
526
|
};
|
|
527
527
|
});
|
|
528
|
-
return r.length > 0 ? r :
|
|
528
|
+
return r.length > 0 ? r : Ie(t);
|
|
529
529
|
}
|
|
530
|
-
function
|
|
531
|
-
return
|
|
530
|
+
function Re(e) {
|
|
531
|
+
return Ne.map(function (t) {
|
|
532
532
|
return {
|
|
533
533
|
cells: e.map(function (e, n) {
|
|
534
|
-
return
|
|
534
|
+
return Te(n === 0 ? "\u9009\u9879 ".concat(t) : "");
|
|
535
535
|
}),
|
|
536
536
|
id: g()
|
|
537
537
|
};
|
|
538
538
|
});
|
|
539
539
|
}
|
|
540
|
-
function
|
|
540
|
+
function ze(e, t) {
|
|
541
541
|
var n = e.length;
|
|
542
542
|
return {
|
|
543
543
|
cells: t.map(function (e, t) {
|
|
544
|
-
return
|
|
544
|
+
return Te(t === 0 ? "\u9009\u9879 ".concat(n + 1) : "");
|
|
545
545
|
}),
|
|
546
546
|
id: g()
|
|
547
547
|
};
|
|
548
548
|
}
|
|
549
|
-
function
|
|
550
|
-
var n =
|
|
549
|
+
function Be(e, t) {
|
|
550
|
+
var n = We(e.map(function (e) {
|
|
551
551
|
return e.id;
|
|
552
552
|
})),
|
|
553
553
|
r = e.map(function (e, r) {
|
|
554
554
|
var i;
|
|
555
555
|
return {
|
|
556
556
|
cells: t.map(function (t, n) {
|
|
557
|
-
return
|
|
557
|
+
return Ee(e.cells.find(function (e, t) {
|
|
558
558
|
return t === n;
|
|
559
559
|
}));
|
|
560
560
|
}),
|
|
561
561
|
id: (i = n[r]) == null ? g() : i
|
|
562
562
|
};
|
|
563
563
|
});
|
|
564
|
-
return r.length > 0 ? r :
|
|
564
|
+
return r.length > 0 ? r : Re(t);
|
|
565
565
|
}
|
|
566
|
-
function
|
|
566
|
+
function Ve(e, t, n) {
|
|
567
567
|
var r;
|
|
568
568
|
var i = new Set(t.map(function (e) {
|
|
569
569
|
return e.id;
|
|
@@ -575,22 +575,22 @@ function He(e, t, n) {
|
|
|
575
575
|
optionIds: n === "single" ? a.slice(0, 1) : a
|
|
576
576
|
};
|
|
577
577
|
}
|
|
578
|
-
function
|
|
579
|
-
return
|
|
578
|
+
function He(e) {
|
|
579
|
+
return Ue(e.length + 1);
|
|
580
580
|
}
|
|
581
|
-
function
|
|
581
|
+
function Ue(e) {
|
|
582
582
|
return {
|
|
583
|
-
content:
|
|
583
|
+
content: Te("\u5217 ".concat(e)),
|
|
584
584
|
id: g()
|
|
585
585
|
};
|
|
586
586
|
}
|
|
587
|
-
function
|
|
587
|
+
function We(e) {
|
|
588
588
|
var t = new Set();
|
|
589
589
|
return e.map(function (e) {
|
|
590
590
|
return _(String(e || ""), t);
|
|
591
591
|
});
|
|
592
592
|
}
|
|
593
|
-
function
|
|
593
|
+
function Ge(e, t, n) {
|
|
594
594
|
var r = new Set(t.map(function (e) {
|
|
595
595
|
return e.id;
|
|
596
596
|
})),
|
|
@@ -604,22 +604,22 @@ function Ke(e, t, n) {
|
|
|
604
604
|
return i.has(t) && r.has(n) ? C(C({}, e), {}, _defineProperty({}, t, n)) : e;
|
|
605
605
|
}, {});
|
|
606
606
|
}
|
|
607
|
-
function
|
|
607
|
+
function Ke(e, t, n) {
|
|
608
608
|
if (!n) {
|
|
609
609
|
var _n2 = C({}, e);
|
|
610
610
|
return delete _n2[t], _n2;
|
|
611
611
|
}
|
|
612
612
|
return C(C({}, e), {}, _defineProperty({}, t, n));
|
|
613
613
|
}
|
|
614
|
-
var
|
|
615
|
-
|
|
614
|
+
var qe = ["number", "upperAlpha", "lowerAlpha", "lowerRoman", "chineseNumber", "none"],
|
|
615
|
+
Je = {
|
|
616
616
|
max: 5,
|
|
617
617
|
min: 2
|
|
618
618
|
};
|
|
619
|
-
function
|
|
619
|
+
function Ye(e, t) {
|
|
620
620
|
return t > e;
|
|
621
621
|
}
|
|
622
|
-
function
|
|
622
|
+
function Xe(e, t) {
|
|
623
623
|
return e.columnIndex === t.columnIndex ? null : e.columnIndex < t.columnIndex ? {
|
|
624
624
|
fromItemId: e.itemId,
|
|
625
625
|
toItemId: t.itemId
|
|
@@ -628,20 +628,20 @@ function Ze(e, t) {
|
|
|
628
628
|
toItemId: e.itemId
|
|
629
629
|
};
|
|
630
630
|
}
|
|
631
|
-
var
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
631
|
+
var Ze = ["number", "upperAlpha"],
|
|
632
|
+
Qe = ["\u4E00", "\u4E8C", "\u4E09", "\u56DB", "\u4E94"],
|
|
633
|
+
$e = ["i", "ii", "iii", "iv", "v"],
|
|
634
|
+
et = {
|
|
635
635
|
chineseNumber: function chineseNumber(e) {
|
|
636
636
|
var t;
|
|
637
|
-
return (t =
|
|
637
|
+
return (t = Qe[e]) == null ? String(e + 1) : t;
|
|
638
638
|
},
|
|
639
639
|
lowerAlpha: function lowerAlpha(e) {
|
|
640
640
|
return String.fromCharCode(97 + e);
|
|
641
641
|
},
|
|
642
642
|
lowerRoman: function lowerRoman(e) {
|
|
643
643
|
var t;
|
|
644
|
-
return (t =
|
|
644
|
+
return (t = $e[e]) == null ? String(e + 1) : t;
|
|
645
645
|
},
|
|
646
646
|
none: function none() {
|
|
647
647
|
return "";
|
|
@@ -653,7 +653,7 @@ var Qe = ["number", "upperAlpha"],
|
|
|
653
653
|
return String.fromCharCode(65 + e);
|
|
654
654
|
}
|
|
655
655
|
};
|
|
656
|
-
function
|
|
656
|
+
function tt(e, t) {
|
|
657
657
|
return Object.entries(e == null ? {} : e).reduce(function (e, _ref9) {
|
|
658
658
|
var _ref0 = _slicedToArray(_ref9, 2),
|
|
659
659
|
n = _ref0[0],
|
|
@@ -662,12 +662,12 @@ function nt(e, t) {
|
|
|
662
662
|
if (i === void 0) return e;
|
|
663
663
|
var a = r.filter(function (e, n, r) {
|
|
664
664
|
var a = t.get(e);
|
|
665
|
-
return a !== void 0 &&
|
|
665
|
+
return a !== void 0 && Ye(i, a) && r.indexOf(e) === n;
|
|
666
666
|
});
|
|
667
667
|
return a.length > 0 ? C(C({}, e), {}, _defineProperty({}, n, a)) : e;
|
|
668
668
|
}, {});
|
|
669
669
|
}
|
|
670
|
-
function
|
|
670
|
+
function nt(e, t, n) {
|
|
671
671
|
var r;
|
|
672
672
|
var i = (r = e[t]) == null ? [] : r,
|
|
673
673
|
a = i.includes(n) ? i.filter(function (e) {
|
|
@@ -681,34 +681,34 @@ function rt(e, t, n) {
|
|
|
681
681
|
}, {});
|
|
682
682
|
return a.length > 0 ? C(C({}, o), {}, _defineProperty({}, t, a)) : o;
|
|
683
683
|
}
|
|
684
|
-
function
|
|
684
|
+
function rt(e) {
|
|
685
685
|
var t;
|
|
686
|
-
var n = (t = e == null ? void 0 : e.slice(0,
|
|
686
|
+
var n = (t = e == null ? void 0 : e.slice(0, Je.max).map(function (e, t) {
|
|
687
687
|
var n;
|
|
688
688
|
return {
|
|
689
|
-
labelStyle:
|
|
689
|
+
labelStyle: at(e.labelStyle, (n = Ze[t]) == null ? "number" : n)
|
|
690
690
|
};
|
|
691
691
|
})) == null ? [] : t;
|
|
692
|
-
return n.length >=
|
|
692
|
+
return n.length >= Je.min ? n : [].concat(_toConsumableArray(n), _toConsumableArray(Ze.slice(n.length, Je.min).map(function (e) {
|
|
693
693
|
return {
|
|
694
694
|
labelStyle: e
|
|
695
695
|
};
|
|
696
696
|
})));
|
|
697
697
|
}
|
|
698
|
-
function
|
|
699
|
-
return
|
|
698
|
+
function it(e, t) {
|
|
699
|
+
return et[e](t);
|
|
700
700
|
}
|
|
701
|
-
function
|
|
702
|
-
return
|
|
701
|
+
function at(e, t) {
|
|
702
|
+
return qe.includes(e) ? e : t;
|
|
703
703
|
}
|
|
704
|
-
var
|
|
704
|
+
var ot = {
|
|
705
705
|
max: 2,
|
|
706
706
|
min: 2
|
|
707
707
|
};
|
|
708
|
-
function
|
|
708
|
+
function st(e, t) {
|
|
709
709
|
return e === 0 && t === 1;
|
|
710
710
|
}
|
|
711
|
-
function
|
|
711
|
+
function ct(e, t) {
|
|
712
712
|
if (e.columnIndex === t.columnIndex) return null;
|
|
713
713
|
var n = e.columnIndex < t.columnIndex ? {
|
|
714
714
|
fromItemId: e.itemId,
|
|
@@ -717,10 +717,10 @@ function lt(e, t) {
|
|
|
717
717
|
fromItemId: t.itemId,
|
|
718
718
|
toItemId: e.itemId
|
|
719
719
|
};
|
|
720
|
-
return
|
|
720
|
+
return st(Math.min(e.columnIndex, t.columnIndex), Math.max(e.columnIndex, t.columnIndex)) ? n : null;
|
|
721
721
|
}
|
|
722
|
-
var
|
|
723
|
-
function
|
|
722
|
+
var lt = ["number", "upperAlpha"];
|
|
723
|
+
function ut(e, t) {
|
|
724
724
|
var n = new Set();
|
|
725
725
|
return Object.entries(e == null ? {} : e).reduce(function (e, _ref11) {
|
|
726
726
|
var _ref12 = _slicedToArray(_ref11, 2),
|
|
@@ -733,7 +733,7 @@ function dt(e, t) {
|
|
|
733
733
|
return a ? (n.add(a), C(C({}, e), {}, _defineProperty({}, r, [a]))) : e;
|
|
734
734
|
}, {});
|
|
735
735
|
}
|
|
736
|
-
function
|
|
736
|
+
function dt(e, t, n) {
|
|
737
737
|
var r, i;
|
|
738
738
|
return (r = (i = e[t]) == null ? void 0 : i.includes(n)) != null && r ? Object.entries(e).reduce(function (e, _ref13) {
|
|
739
739
|
var _ref14 = _slicedToArray(_ref13, 2),
|
|
@@ -751,29 +751,29 @@ function ft(e, t, n) {
|
|
|
751
751
|
return a.length > 0 ? C(C({}, e), {}, _defineProperty({}, r, a)) : e;
|
|
752
752
|
}, {})), {}, _defineProperty({}, t, [n]));
|
|
753
753
|
}
|
|
754
|
-
function
|
|
754
|
+
function ft(e) {
|
|
755
755
|
var t;
|
|
756
|
-
var n = (t = e == null ? void 0 : e.slice(0,
|
|
756
|
+
var n = (t = e == null ? void 0 : e.slice(0, ot.max).map(function (e, t) {
|
|
757
757
|
var n;
|
|
758
758
|
return {
|
|
759
|
-
labelStyle:
|
|
759
|
+
labelStyle: at(e.labelStyle, (n = lt[t]) == null ? "number" : n)
|
|
760
760
|
};
|
|
761
761
|
})) == null ? [] : t;
|
|
762
|
-
return n.length >=
|
|
762
|
+
return n.length >= ot.min ? n : [].concat(_toConsumableArray(n), _toConsumableArray(lt.slice(n.length, ot.min).map(function (e) {
|
|
763
763
|
return {
|
|
764
764
|
labelStyle: e
|
|
765
765
|
};
|
|
766
766
|
})));
|
|
767
767
|
}
|
|
768
|
-
function
|
|
769
|
-
return
|
|
768
|
+
function pt(e, t) {
|
|
769
|
+
return it(e, t);
|
|
770
770
|
}
|
|
771
|
-
var
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
marks: [
|
|
771
|
+
var mt = "mark.textMarker",
|
|
772
|
+
ht = "markerId",
|
|
773
|
+
gt = {
|
|
774
|
+
marks: [_t()]
|
|
775
775
|
};
|
|
776
|
-
function
|
|
776
|
+
function _t(e) {
|
|
777
777
|
return {
|
|
778
778
|
behavior: {
|
|
779
779
|
clearOnSelectionDelete: !0
|
|
@@ -782,36 +782,36 @@ function vt(e) {
|
|
|
782
782
|
html: {
|
|
783
783
|
deserialize: function deserialize(_ref17) {
|
|
784
784
|
var e = _ref17.element;
|
|
785
|
-
var t =
|
|
786
|
-
return t ? _defineProperty({},
|
|
785
|
+
var t = Ct(e.dataset.markerId);
|
|
786
|
+
return t ? _defineProperty({}, ht, t) : null;
|
|
787
787
|
},
|
|
788
788
|
serialize: function serialize(_ref19) {
|
|
789
789
|
var e = _ref19.leaf,
|
|
790
790
|
t = _ref19.text;
|
|
791
|
-
var n =
|
|
792
|
-
return n ? "<span data-marker-id=\"".concat(
|
|
791
|
+
var n = xt(e);
|
|
792
|
+
return n ? "<span data-marker-id=\"".concat(wt(n), "\">").concat(t, "</span>") : null;
|
|
793
793
|
}
|
|
794
794
|
}
|
|
795
795
|
},
|
|
796
796
|
commands: [{
|
|
797
|
-
command:
|
|
798
|
-
markKey:
|
|
797
|
+
command: mt,
|
|
798
|
+
markKey: ht
|
|
799
799
|
}],
|
|
800
800
|
render: e
|
|
801
801
|
};
|
|
802
802
|
}
|
|
803
|
-
function
|
|
803
|
+
function vt(e) {
|
|
804
804
|
var t = [];
|
|
805
|
-
return
|
|
806
|
-
var n =
|
|
805
|
+
return St(e == null ? [] : e, function (e) {
|
|
806
|
+
var n = xt(e);
|
|
807
807
|
n && !t.includes(n) && t.push(n);
|
|
808
808
|
}), t;
|
|
809
809
|
}
|
|
810
|
-
function
|
|
810
|
+
function yt(e) {
|
|
811
811
|
var t = [];
|
|
812
|
-
return
|
|
813
|
-
var n =
|
|
814
|
-
r =
|
|
812
|
+
return St(e == null ? [] : e, function (e) {
|
|
813
|
+
var n = xt(e),
|
|
814
|
+
r = Tt(e) && _typeof(e.text) == "string" ? e.text : "";
|
|
815
815
|
if (!n || !r) return;
|
|
816
816
|
var i = t.slice(t.length - 1)[0];
|
|
817
817
|
if ((i == null ? void 0 : i.markerId) === n) {
|
|
@@ -827,30 +827,30 @@ function bt(e) {
|
|
|
827
827
|
});
|
|
828
828
|
}), t;
|
|
829
829
|
}
|
|
830
|
-
function
|
|
830
|
+
function bt() {
|
|
831
831
|
return g();
|
|
832
832
|
}
|
|
833
|
-
function
|
|
834
|
-
return
|
|
833
|
+
function xt(e) {
|
|
834
|
+
return Tt(e) ? Ct(e[ht]) : "";
|
|
835
835
|
}
|
|
836
|
-
function
|
|
836
|
+
function St(e, t) {
|
|
837
837
|
e.forEach(function (e) {
|
|
838
|
-
t(e),
|
|
838
|
+
t(e), Tt(e) && Array.isArray(e.children) && St(e.children, t);
|
|
839
839
|
});
|
|
840
840
|
}
|
|
841
|
-
function
|
|
841
|
+
function Ct(e) {
|
|
842
842
|
return _typeof(e) == "string" ? e.trim() : "";
|
|
843
843
|
}
|
|
844
|
-
function
|
|
844
|
+
function wt(e) {
|
|
845
845
|
return e.replace(/&/g, "&").replace(/"/g, """).replace(/</g, "<").replace(/>/g, ">");
|
|
846
846
|
}
|
|
847
|
-
function
|
|
847
|
+
function Tt(e) {
|
|
848
848
|
return _typeof(e) == "object" && !!e;
|
|
849
849
|
}
|
|
850
|
-
var
|
|
850
|
+
var Et = {
|
|
851
851
|
"blank-underline": "_blank-underline_1wnlx_1"
|
|
852
852
|
},
|
|
853
|
-
|
|
853
|
+
Dt = {
|
|
854
854
|
nodes: [{
|
|
855
855
|
codecs: {
|
|
856
856
|
html: {
|
|
@@ -868,15 +868,15 @@ var Dt = {
|
|
|
868
868
|
},
|
|
869
869
|
serialize: function serialize(_ref21) {
|
|
870
870
|
var e = _ref21.node;
|
|
871
|
-
return e.type === "blank" ? "<span data-rte-node=\"blank\" data-blank-id=\"".concat(
|
|
871
|
+
return e.type === "blank" ? "<span data-rte-node=\"blank\" data-blank-id=\"".concat(jt(e.blankId), "\" data-label=\"").concat(jt(e.label), "\"></span>") : null;
|
|
872
872
|
}
|
|
873
873
|
},
|
|
874
874
|
json: {
|
|
875
875
|
deserialize: function deserialize(_ref22) {
|
|
876
876
|
var e = _ref22.input;
|
|
877
|
-
return
|
|
878
|
-
blankId:
|
|
879
|
-
label:
|
|
877
|
+
return Ot(e) ? {
|
|
878
|
+
blankId: jt(e.blankId),
|
|
879
|
+
label: jt(e.label),
|
|
880
880
|
children: [{
|
|
881
881
|
text: ""
|
|
882
882
|
}],
|
|
@@ -886,8 +886,8 @@ var Dt = {
|
|
|
886
886
|
serialize: function serialize(_ref23) {
|
|
887
887
|
var e = _ref23.node;
|
|
888
888
|
return e.type === "blank" ? {
|
|
889
|
-
blankId:
|
|
890
|
-
label:
|
|
889
|
+
blankId: jt(e.blankId),
|
|
890
|
+
label: jt(e.label),
|
|
891
891
|
type: "blank"
|
|
892
892
|
} : null;
|
|
893
893
|
}
|
|
@@ -897,8 +897,8 @@ var Dt = {
|
|
|
897
897
|
insert: function insert(_ref24) {
|
|
898
898
|
var e = _ref24.payload;
|
|
899
899
|
return {
|
|
900
|
-
blankId:
|
|
901
|
-
label:
|
|
900
|
+
blankId: kt(e),
|
|
901
|
+
label: At(e),
|
|
902
902
|
type: "blank"
|
|
903
903
|
};
|
|
904
904
|
}
|
|
@@ -910,25 +910,25 @@ var Dt = {
|
|
|
910
910
|
var e = _ref25.element,
|
|
911
911
|
n = _ref25.selected;
|
|
912
912
|
return (0, t.jsx)("span", {
|
|
913
|
-
className:
|
|
913
|
+
className: Et["blank-underline"],
|
|
914
914
|
"data-selected": n ? "true" : void 0,
|
|
915
|
-
children:
|
|
915
|
+
children: jt(e.label) || jt(e.blankId) || "Blank"
|
|
916
916
|
});
|
|
917
917
|
}
|
|
918
918
|
},
|
|
919
919
|
type: "blank"
|
|
920
920
|
}]
|
|
921
921
|
};
|
|
922
|
-
function
|
|
922
|
+
function Ot(e) {
|
|
923
923
|
return !!(e && _typeof(e) == "object" && "type" in e && e.type === "blank");
|
|
924
924
|
}
|
|
925
|
+
function kt(e) {
|
|
926
|
+
return e && _typeof(e) == "object" && "blankId" in e ? jt(e.blankId) : "";
|
|
927
|
+
}
|
|
925
928
|
function At(e) {
|
|
926
|
-
return e && _typeof(e) == "object" && "
|
|
929
|
+
return e && _typeof(e) == "object" && "label" in e ? jt(e.label) : "";
|
|
927
930
|
}
|
|
928
931
|
function jt(e) {
|
|
929
|
-
return e && _typeof(e) == "object" && "label" in e ? D(e.label) : "";
|
|
930
|
-
}
|
|
931
|
-
function D(e) {
|
|
932
932
|
return _typeof(e) == "string" ? e : "";
|
|
933
933
|
}
|
|
934
934
|
var Mt = 1,
|
|
@@ -1030,7 +1030,7 @@ function O() {
|
|
|
1030
1030
|
return Wt(t == null ? gi(e) : t);
|
|
1031
1031
|
}
|
|
1032
1032
|
function Wt(t) {
|
|
1033
|
-
var n = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [
|
|
1033
|
+
var n = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [Dt];
|
|
1034
1034
|
var r = wi(t, n);
|
|
1035
1035
|
return {
|
|
1036
1036
|
html: (0, e.serializeRichTextEditorHtml)(r, {
|
|
@@ -1044,15 +1044,15 @@ function Gt() {
|
|
|
1044
1044
|
var e = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : "";
|
|
1045
1045
|
var t = arguments.length > 1 ? arguments[1] : undefined;
|
|
1046
1046
|
var n = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : "";
|
|
1047
|
-
return Wt(Kt(e, t, n), [
|
|
1047
|
+
return Wt(Kt(e, t, n), [gt]);
|
|
1048
1048
|
}
|
|
1049
1049
|
function Kt(t, n, r) {
|
|
1050
1050
|
return n && Ci(n) ? n : r ? (0, e.deserializeRichTextEditorHtml)(r, {
|
|
1051
|
-
plugins: [
|
|
1051
|
+
plugins: [gt]
|
|
1052
1052
|
}) : gi(t);
|
|
1053
1053
|
}
|
|
1054
1054
|
function qt(e) {
|
|
1055
|
-
return
|
|
1055
|
+
return yt(e.content.json).filter(function (t) {
|
|
1056
1056
|
return e.answers.includes(t.markerId);
|
|
1057
1057
|
}).map(function (e) {
|
|
1058
1058
|
return e.text.trim();
|
|
@@ -1081,10 +1081,10 @@ function Zt(e, t) {
|
|
|
1081
1081
|
return Lt[e](t);
|
|
1082
1082
|
}
|
|
1083
1083
|
function Qt(e, t) {
|
|
1084
|
-
return
|
|
1084
|
+
return it(e, t);
|
|
1085
1085
|
}
|
|
1086
1086
|
function $t(e, t) {
|
|
1087
|
-
return
|
|
1087
|
+
return pt(e, t);
|
|
1088
1088
|
}
|
|
1089
1089
|
function en(e) {
|
|
1090
1090
|
switch (e) {
|
|
@@ -1214,7 +1214,7 @@ function hn(e, t, n, r) {
|
|
|
1214
1214
|
}
|
|
1215
1215
|
function gn(e, t, n) {
|
|
1216
1216
|
var r = Gt(t.text, t.json, t.html),
|
|
1217
|
-
i =
|
|
1217
|
+
i = vt(r.json);
|
|
1218
1218
|
return C(C({}, e), {}, {
|
|
1219
1219
|
answers: n ? li(e.answers, i) : [],
|
|
1220
1220
|
content: r,
|
|
@@ -1578,15 +1578,15 @@ function Wn(e, t) {
|
|
|
1578
1578
|
return n !== t;
|
|
1579
1579
|
});
|
|
1580
1580
|
return C(C({}, e), {}, {
|
|
1581
|
-
answers:
|
|
1581
|
+
answers: Ve(e.answers, n, "multiple"),
|
|
1582
1582
|
options: n
|
|
1583
1583
|
});
|
|
1584
1584
|
}
|
|
1585
1585
|
function Gn(e, t, n) {
|
|
1586
|
-
return
|
|
1586
|
+
return Fe(e, t, n);
|
|
1587
1587
|
}
|
|
1588
1588
|
function Kn(e) {
|
|
1589
|
-
var t = [].concat(_toConsumableArray(e.columns), [
|
|
1589
|
+
var t = [].concat(_toConsumableArray(e.columns), [He(e.columns)]);
|
|
1590
1590
|
return C(C({}, e), {}, {
|
|
1591
1591
|
columns: t,
|
|
1592
1592
|
options: e.options.map(function (e) {
|
|
@@ -1597,7 +1597,7 @@ function Kn(e) {
|
|
|
1597
1597
|
});
|
|
1598
1598
|
}
|
|
1599
1599
|
function qn(e, t) {
|
|
1600
|
-
return
|
|
1600
|
+
return Pe(e, t);
|
|
1601
1601
|
}
|
|
1602
1602
|
function Jn(e) {
|
|
1603
1603
|
return tr(e);
|
|
@@ -1608,7 +1608,7 @@ function Yn(e, t) {
|
|
|
1608
1608
|
return n !== t;
|
|
1609
1609
|
});
|
|
1610
1610
|
return C(C({}, e), {}, {
|
|
1611
|
-
answers:
|
|
1611
|
+
answers: Ve(e.answers, n, "multiple"),
|
|
1612
1612
|
options: n
|
|
1613
1613
|
});
|
|
1614
1614
|
}
|
|
@@ -1634,10 +1634,10 @@ function Zn(e, t, n) {
|
|
|
1634
1634
|
}
|
|
1635
1635
|
function Qn(e, t, n) {
|
|
1636
1636
|
er(e);
|
|
1637
|
-
var r =
|
|
1638
|
-
i =
|
|
1637
|
+
var r = Le(e.columns, t.config.renderer),
|
|
1638
|
+
i = Be(e.options, r);
|
|
1639
1639
|
return C(C({}, e), {}, {
|
|
1640
|
-
answers: n ?
|
|
1640
|
+
answers: n ? Ve(e.answers, i, t.config.selectionType) : {
|
|
1641
1641
|
optionIds: []
|
|
1642
1642
|
},
|
|
1643
1643
|
columns: r,
|
|
@@ -1662,7 +1662,7 @@ function er(e) {
|
|
|
1662
1662
|
}
|
|
1663
1663
|
function tr(e) {
|
|
1664
1664
|
return C(C({}, e), {}, {
|
|
1665
|
-
options: [].concat(_toConsumableArray(e.options), [
|
|
1665
|
+
options: [].concat(_toConsumableArray(e.options), [ze(e.options, e.columns)])
|
|
1666
1666
|
});
|
|
1667
1667
|
}
|
|
1668
1668
|
function nr(e, t, n) {
|
|
@@ -1673,14 +1673,14 @@ function nr(e, t, n) {
|
|
|
1673
1673
|
});
|
|
1674
1674
|
}
|
|
1675
1675
|
function rr(e) {
|
|
1676
|
-
if (e.columns.length >=
|
|
1676
|
+
if (e.columns.length >= Je.max) return e;
|
|
1677
1677
|
var t = e.columns.length;
|
|
1678
1678
|
return C(C({}, e), {}, {
|
|
1679
1679
|
columns: [].concat(_toConsumableArray(e.columns), [ni(ei(t))])
|
|
1680
1680
|
});
|
|
1681
1681
|
}
|
|
1682
1682
|
function ir(e, t) {
|
|
1683
|
-
if (e.columns.length <=
|
|
1683
|
+
if (e.columns.length <= Je.min) return e;
|
|
1684
1684
|
var n = e.columns.filter(function (e) {
|
|
1685
1685
|
return e.columnId !== t;
|
|
1686
1686
|
});
|
|
@@ -1712,7 +1712,7 @@ function cr(e, t, n) {
|
|
|
1712
1712
|
return vr(e, t, n);
|
|
1713
1713
|
}
|
|
1714
1714
|
function lr(e, t, n) {
|
|
1715
|
-
return
|
|
1715
|
+
return nt(e, t, n);
|
|
1716
1716
|
}
|
|
1717
1717
|
function ur(e, t, n) {
|
|
1718
1718
|
var r = ai(e.columns, t);
|
|
@@ -1756,7 +1756,7 @@ function hr(e, t, n) {
|
|
|
1756
1756
|
return vr(e, t, n);
|
|
1757
1757
|
}
|
|
1758
1758
|
function gr(e, t, n) {
|
|
1759
|
-
return
|
|
1759
|
+
return dt(e, t, n);
|
|
1760
1760
|
}
|
|
1761
1761
|
function _r(e, t, n) {
|
|
1762
1762
|
return C(C({}, e), {}, {
|
|
@@ -1784,7 +1784,7 @@ function yr(e, t) {
|
|
|
1784
1784
|
var n = qr(e.categories),
|
|
1785
1785
|
r = Jr(e.items);
|
|
1786
1786
|
return C(C({}, e), {}, {
|
|
1787
|
-
answers: t ?
|
|
1787
|
+
answers: t ? Ge(e.answers, n, r) : {},
|
|
1788
1788
|
categories: n,
|
|
1789
1789
|
items: r
|
|
1790
1790
|
});
|
|
@@ -1802,7 +1802,7 @@ function xr(e, t) {
|
|
|
1802
1802
|
return e.id !== t;
|
|
1803
1803
|
});
|
|
1804
1804
|
return C(C({}, e), {}, {
|
|
1805
|
-
answers:
|
|
1805
|
+
answers: Ge(e.answers, n, e.items),
|
|
1806
1806
|
categories: n
|
|
1807
1807
|
});
|
|
1808
1808
|
}
|
|
@@ -1828,7 +1828,7 @@ function wr(e, t) {
|
|
|
1828
1828
|
return e.id !== t;
|
|
1829
1829
|
});
|
|
1830
1830
|
return C(C({}, e), {}, {
|
|
1831
|
-
answers:
|
|
1831
|
+
answers: Ge(e.answers, e.categories, n),
|
|
1832
1832
|
items: n
|
|
1833
1833
|
});
|
|
1834
1834
|
}
|
|
@@ -1842,7 +1842,7 @@ function Tr(e, t, n) {
|
|
|
1842
1842
|
});
|
|
1843
1843
|
}
|
|
1844
1844
|
function Er(e, t, n) {
|
|
1845
|
-
return
|
|
1845
|
+
return Ke(e, t, n);
|
|
1846
1846
|
}
|
|
1847
1847
|
function Dr(e, t) {
|
|
1848
1848
|
var n = ui(e.sortOptions);
|
|
@@ -2039,13 +2039,13 @@ function Gr(e) {
|
|
|
2039
2039
|
};
|
|
2040
2040
|
}
|
|
2041
2041
|
function Kr(e) {
|
|
2042
|
-
var t =
|
|
2042
|
+
var t = Ie(e.config.renderer);
|
|
2043
2043
|
return {
|
|
2044
2044
|
answers: {
|
|
2045
2045
|
optionIds: []
|
|
2046
2046
|
},
|
|
2047
2047
|
columns: t,
|
|
2048
|
-
options:
|
|
2048
|
+
options: Re(t),
|
|
2049
2049
|
type: "choice"
|
|
2050
2050
|
};
|
|
2051
2051
|
}
|
|
@@ -2094,12 +2094,12 @@ function Zr(e, t) {
|
|
|
2094
2094
|
r = new Set(),
|
|
2095
2095
|
i = new Set(),
|
|
2096
2096
|
a = $r(t);
|
|
2097
|
-
return n.slice(0,
|
|
2097
|
+
return n.slice(0, Je.max).map(function (e, t) {
|
|
2098
2098
|
var n, o;
|
|
2099
2099
|
return {
|
|
2100
2100
|
columnId: _(e.columnId, r),
|
|
2101
2101
|
items: ti(e.items, i),
|
|
2102
|
-
labelStyle:
|
|
2102
|
+
labelStyle: at(e.labelStyle, (n = (o = a[t]) == null ? void 0 : o.labelStyle) == null ? "number" : n)
|
|
2103
2103
|
};
|
|
2104
2104
|
});
|
|
2105
2105
|
}
|
|
@@ -2109,11 +2109,11 @@ function Qr(e) {
|
|
|
2109
2109
|
});
|
|
2110
2110
|
}
|
|
2111
2111
|
function $r(e) {
|
|
2112
|
-
return
|
|
2112
|
+
return rt(e.config.columns);
|
|
2113
2113
|
}
|
|
2114
2114
|
function ei(e) {
|
|
2115
2115
|
var t, n;
|
|
2116
|
-
return (t = (n =
|
|
2116
|
+
return (t = (n = rt([])[e]) == null ? void 0 : n.labelStyle) == null ? "number" : t;
|
|
2117
2117
|
}
|
|
2118
2118
|
function ti(e, t) {
|
|
2119
2119
|
var n = e.map(function (e) {
|
|
@@ -2143,24 +2143,24 @@ function ri(e) {
|
|
|
2143
2143
|
});
|
|
2144
2144
|
}
|
|
2145
2145
|
function ii(e, t) {
|
|
2146
|
-
return
|
|
2146
|
+
return tt(e, mi(t));
|
|
2147
2147
|
}
|
|
2148
2148
|
function ai(e, t) {
|
|
2149
2149
|
var n = e.length > 0 ? e : oi(t),
|
|
2150
2150
|
r = new Set(),
|
|
2151
2151
|
i = new Set(),
|
|
2152
|
-
a =
|
|
2153
|
-
return n.slice(0,
|
|
2152
|
+
a = ft(t.config.columns);
|
|
2153
|
+
return n.slice(0, ot.max).map(function (e, t) {
|
|
2154
2154
|
var n, o;
|
|
2155
2155
|
return {
|
|
2156
2156
|
columnId: _(e.columnId, r),
|
|
2157
2157
|
items: ti(e.items, i),
|
|
2158
|
-
labelStyle:
|
|
2158
|
+
labelStyle: at(e.labelStyle, (n = (o = a[t]) == null ? void 0 : o.labelStyle) == null ? "number" : n)
|
|
2159
2159
|
};
|
|
2160
2160
|
});
|
|
2161
2161
|
}
|
|
2162
2162
|
function oi(e) {
|
|
2163
|
-
return
|
|
2163
|
+
return ft(e.config.columns).map(function (e) {
|
|
2164
2164
|
return si(e.labelStyle);
|
|
2165
2165
|
});
|
|
2166
2166
|
}
|
|
@@ -2180,7 +2180,7 @@ function si(e) {
|
|
|
2180
2180
|
};
|
|
2181
2181
|
}
|
|
2182
2182
|
function ci(e, t) {
|
|
2183
|
-
return
|
|
2183
|
+
return ut(e, mi(t));
|
|
2184
2184
|
}
|
|
2185
2185
|
function li(e, t) {
|
|
2186
2186
|
var n = new Set(t);
|
|
@@ -2277,7 +2277,7 @@ function Ci(e) {
|
|
|
2277
2277
|
return Array.isArray(e) && e.length > 0;
|
|
2278
2278
|
}
|
|
2279
2279
|
function wi(t) {
|
|
2280
|
-
var n = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [
|
|
2280
|
+
var n = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [Dt];
|
|
2281
2281
|
return Ci(t) ? (0, e.deserializeRichTextEditorJson)(t, {
|
|
2282
2282
|
plugins: n
|
|
2283
2283
|
}) : gi("");
|
|
@@ -2521,10 +2521,10 @@ var na = {
|
|
|
2521
2521
|
marker: "_marker_rlnj7_1"
|
|
2522
2522
|
},
|
|
2523
2523
|
ra = {
|
|
2524
|
-
marks: [
|
|
2524
|
+
marks: [_t(function (_ref35) {
|
|
2525
2525
|
var e = _ref35.children,
|
|
2526
2526
|
t = _ref35.leaf;
|
|
2527
|
-
return
|
|
2527
|
+
return xt(t) ? ia(e) : e;
|
|
2528
2528
|
})]
|
|
2529
2529
|
};
|
|
2530
2530
|
function ia(e) {
|
|
@@ -3263,7 +3263,7 @@ function Da(_ref50) {
|
|
|
3263
3263
|
"aria-label": r,
|
|
3264
3264
|
className: "".concat(P.textarea, " rich-content-editor-surface"),
|
|
3265
3265
|
onChange: function onChange(e) {
|
|
3266
|
-
return a(
|
|
3266
|
+
return a(Te(e.target.value));
|
|
3267
3267
|
},
|
|
3268
3268
|
placeholder: s,
|
|
3269
3269
|
value: f.text
|
|
@@ -3316,7 +3316,7 @@ function Da(_ref50) {
|
|
|
3316
3316
|
className: ja(i),
|
|
3317
3317
|
initialValue: f.json,
|
|
3318
3318
|
onChange: function onChange(e) {
|
|
3319
|
-
return a(
|
|
3319
|
+
return a(Ee({
|
|
3320
3320
|
json: e
|
|
3321
3321
|
}));
|
|
3322
3322
|
},
|
|
@@ -3353,7 +3353,7 @@ function Ma(_ref52) {
|
|
|
3353
3353
|
className: ja(i),
|
|
3354
3354
|
initialValue: s.json,
|
|
3355
3355
|
onChange: function onChange(e) {
|
|
3356
|
-
return a(
|
|
3356
|
+
return a(Ee({
|
|
3357
3357
|
json: e
|
|
3358
3358
|
}));
|
|
3359
3359
|
},
|
|
@@ -3469,7 +3469,7 @@ function Na(_ref54) {
|
|
|
3469
3469
|
answers: p
|
|
3470
3470
|
}), l, d)), S());
|
|
3471
3471
|
}
|
|
3472
|
-
function
|
|
3472
|
+
function w(n, r) {
|
|
3473
3473
|
return (0, t.jsxs)("div", {
|
|
3474
3474
|
className: "flex min-w-0 flex-wrap items-start gap-3",
|
|
3475
3475
|
children: [r.answerPools.map(function (i, a) {
|
|
@@ -3513,7 +3513,7 @@ function Na(_ref54) {
|
|
|
3513
3513
|
})]
|
|
3514
3514
|
});
|
|
3515
3515
|
}
|
|
3516
|
-
function
|
|
3516
|
+
function T(n, r, a, o) {
|
|
3517
3517
|
var s = b(n);
|
|
3518
3518
|
return (0, t.jsxs)("section", {
|
|
3519
3519
|
className: "flex min-w-0 flex-wrap items-center gap-4 rounded-md border border-slate-200 bg-white px-4 py-3",
|
|
@@ -3555,7 +3555,7 @@ function Na(_ref54) {
|
|
|
3555
3555
|
})]
|
|
3556
3556
|
}), (0, t.jsx)("div", {
|
|
3557
3557
|
className: "min-w-72 flex-1",
|
|
3558
|
-
children:
|
|
3558
|
+
children: w(a, o)
|
|
3559
3559
|
}), (0, t.jsx)(M, {
|
|
3560
3560
|
"aria-label": c("questionContentEditor.actions.deleteBlank", {
|
|
3561
3561
|
index: r + 1
|
|
@@ -3573,7 +3573,7 @@ function Na(_ref54) {
|
|
|
3573
3573
|
})]
|
|
3574
3574
|
}, n);
|
|
3575
3575
|
}
|
|
3576
|
-
function
|
|
3576
|
+
function te(n, r, a) {
|
|
3577
3577
|
return (0, t.jsxs)("section", {
|
|
3578
3578
|
className: "flex min-w-0 flex-col gap-3 rounded-md border border-blue-200 bg-blue-50/40 px-4 py-3",
|
|
3579
3579
|
children: [(0, t.jsxs)("div", {
|
|
@@ -3603,10 +3603,10 @@ function Na(_ref54) {
|
|
|
3603
3603
|
strong: !0,
|
|
3604
3604
|
children: c("questionContentEditor.blank.sharedAnswer")
|
|
3605
3605
|
})]
|
|
3606
|
-
}),
|
|
3606
|
+
}), w(r, n)]
|
|
3607
3607
|
}, "shared-group-".concat(r));
|
|
3608
3608
|
}
|
|
3609
|
-
function
|
|
3609
|
+
function ne() {
|
|
3610
3610
|
var e = new Set();
|
|
3611
3611
|
return i.blanks.reduce(function (t, n, r) {
|
|
3612
3612
|
var i = p.findIndex(function (e) {
|
|
@@ -3619,9 +3619,9 @@ function Na(_ref54) {
|
|
|
3619
3619
|
var _n4 = m.findIndex(function (e) {
|
|
3620
3620
|
return e.groupIndex === i;
|
|
3621
3621
|
});
|
|
3622
|
-
return e.add(i), t.push(
|
|
3622
|
+
return e.add(i), t.push(te(a, i, _n4)), t;
|
|
3623
3623
|
}
|
|
3624
|
-
return t.push(
|
|
3624
|
+
return t.push(T(n, r, i, a)), t;
|
|
3625
3625
|
}, []);
|
|
3626
3626
|
}
|
|
3627
3627
|
return r ? (0, t.jsxs)(t.Fragment, {
|
|
@@ -3629,7 +3629,7 @@ function Na(_ref54) {
|
|
|
3629
3629
|
className: "flex min-w-0 flex-col gap-4",
|
|
3630
3630
|
children: (0, t.jsx)("div", {
|
|
3631
3631
|
className: "flex min-w-0 flex-col gap-3",
|
|
3632
|
-
children:
|
|
3632
|
+
children: ne()
|
|
3633
3633
|
})
|
|
3634
3634
|
}), (0, t.jsx)(_a, {
|
|
3635
3635
|
cancelText: c("questionContentEditor.actions.cancel"),
|
|
@@ -3938,7 +3938,7 @@ function La(_ref62) {
|
|
|
3938
3938
|
candidateOptions: bn(e)
|
|
3939
3939
|
}));
|
|
3940
3940
|
}
|
|
3941
|
-
function
|
|
3941
|
+
function w(e, t) {
|
|
3942
3942
|
var n = jn(v.blankOptionGroups, v.blanks).map(function (n) {
|
|
3943
3943
|
return n.blankId === e ? C(C({}, t), {}, {
|
|
3944
3944
|
blankId: e
|
|
@@ -3948,24 +3948,24 @@ function La(_ref62) {
|
|
|
3948
3948
|
blankOptionGroups: n
|
|
3949
3949
|
}));
|
|
3950
3950
|
}
|
|
3951
|
-
function
|
|
3951
|
+
function T() {
|
|
3952
3952
|
return v.answers.filter(function (e) {
|
|
3953
3953
|
return "answerOptionIds" in e;
|
|
3954
3954
|
});
|
|
3955
3955
|
}
|
|
3956
|
-
function
|
|
3956
|
+
function te(e) {
|
|
3957
3957
|
return e.blankIds.join("__");
|
|
3958
3958
|
}
|
|
3959
|
-
function
|
|
3959
|
+
function ne(e) {
|
|
3960
3960
|
x(C(C({}, v), {}, {
|
|
3961
3961
|
answers: e
|
|
3962
3962
|
}));
|
|
3963
3963
|
}
|
|
3964
|
-
function
|
|
3965
|
-
var r =
|
|
3964
|
+
function re(e, t, n) {
|
|
3965
|
+
var r = T(),
|
|
3966
3966
|
i = r.slice(e, e + 1)[0];
|
|
3967
3967
|
if (!i) return;
|
|
3968
|
-
var a =
|
|
3968
|
+
var a = te(i),
|
|
3969
3969
|
o = (t < i.answerOptionIds.length ? i.answerOptionIds.map(function (e, r) {
|
|
3970
3970
|
return r === t ? n : e;
|
|
3971
3971
|
}) : [].concat(_toConsumableArray(i.answerOptionIds), [n])).filter(function (e, t, n) {
|
|
@@ -3973,41 +3973,41 @@ function La(_ref62) {
|
|
|
3973
3973
|
});
|
|
3974
3974
|
t >= i.answerOptionIds.length && n && p(function (e) {
|
|
3975
3975
|
return C(C({}, e), {}, _defineProperty({}, a, Math.max(0, Ra(e, a) - 1)));
|
|
3976
|
-
}),
|
|
3976
|
+
}), ne(r.map(function (t, n) {
|
|
3977
3977
|
return n === e ? C(C({}, t), {}, {
|
|
3978
3978
|
answerOptionIds: o
|
|
3979
3979
|
}) : t;
|
|
3980
3980
|
}));
|
|
3981
3981
|
}
|
|
3982
|
-
function
|
|
3982
|
+
function ie(e) {
|
|
3983
3983
|
var t = jn(v.blankOptionGroups, v.blanks).find(function (t) {
|
|
3984
3984
|
return t.blankId === e;
|
|
3985
3985
|
});
|
|
3986
3986
|
if (!t) throw Error("Missing option group for blank ".concat(e, "."));
|
|
3987
3987
|
return t;
|
|
3988
3988
|
}
|
|
3989
|
-
function
|
|
3989
|
+
function ae(e, t, n, r) {
|
|
3990
3990
|
t(e.map(function (e) {
|
|
3991
3991
|
return e.optionId === n ? C(C({}, e), {}, {
|
|
3992
3992
|
content: r
|
|
3993
3993
|
}) : e;
|
|
3994
3994
|
}));
|
|
3995
3995
|
}
|
|
3996
|
-
function
|
|
3996
|
+
function oe(e, t, n) {
|
|
3997
3997
|
t(e.filter(function (e) {
|
|
3998
3998
|
return e.optionId !== n;
|
|
3999
3999
|
}));
|
|
4000
4000
|
}
|
|
4001
|
-
function
|
|
4002
|
-
return
|
|
4001
|
+
function se() {
|
|
4002
|
+
return T().reduce(function (e, t, n) {
|
|
4003
4003
|
return t.blankIds.length >= 2 && e.push({
|
|
4004
4004
|
group: t,
|
|
4005
4005
|
groupIndex: n
|
|
4006
4006
|
}), e;
|
|
4007
4007
|
}, []);
|
|
4008
4008
|
}
|
|
4009
|
-
function
|
|
4010
|
-
return
|
|
4009
|
+
function ce(e) {
|
|
4010
|
+
return T().filter(function (e) {
|
|
4011
4011
|
return e.blankIds.length === 1;
|
|
4012
4012
|
}).map(function (e) {
|
|
4013
4013
|
return e.blankIds[0];
|
|
@@ -4015,22 +4015,22 @@ function La(_ref62) {
|
|
|
4015
4015
|
return !!t && t !== e;
|
|
4016
4016
|
});
|
|
4017
4017
|
}
|
|
4018
|
-
function
|
|
4018
|
+
function le(e, t) {
|
|
4019
4019
|
if (t === "__single__") {
|
|
4020
|
-
|
|
4020
|
+
he(e);
|
|
4021
4021
|
return;
|
|
4022
4022
|
}
|
|
4023
4023
|
if (t === "__new__") {
|
|
4024
|
-
|
|
4024
|
+
de(e);
|
|
4025
4025
|
return;
|
|
4026
4026
|
}
|
|
4027
4027
|
var n = Number(t.replace("group:", ""));
|
|
4028
|
-
Number.isNaN(n) ||
|
|
4028
|
+
Number.isNaN(n) || ue(e, n);
|
|
4029
4029
|
}
|
|
4030
|
-
function
|
|
4031
|
-
var n =
|
|
4030
|
+
function ue(e, t) {
|
|
4031
|
+
var n = T(),
|
|
4032
4032
|
r = n.slice(t, t + 1)[0];
|
|
4033
|
-
!r || r.blankIds.length < 2 || r.blankIds.includes(e) ||
|
|
4033
|
+
!r || r.blankIds.length < 2 || r.blankIds.includes(e) || ne(n.map(function (n, r) {
|
|
4034
4034
|
return r === t ? C(C({}, n), {}, {
|
|
4035
4035
|
blankIds: [].concat(_toConsumableArray(n.blankIds), [e])
|
|
4036
4036
|
}) : C(C({}, n), {}, {
|
|
@@ -4042,24 +4042,24 @@ function La(_ref62) {
|
|
|
4042
4042
|
return e.blankIds.length > 0;
|
|
4043
4043
|
}));
|
|
4044
4044
|
}
|
|
4045
|
-
function
|
|
4046
|
-
var t =
|
|
4045
|
+
function de(e) {
|
|
4046
|
+
var t = ce(e)[0];
|
|
4047
4047
|
t && (h(e), _(t));
|
|
4048
4048
|
}
|
|
4049
|
-
function
|
|
4049
|
+
function fe() {
|
|
4050
4050
|
h(null), _(null);
|
|
4051
4051
|
}
|
|
4052
|
-
function
|
|
4053
|
-
!m || !g || (
|
|
4052
|
+
function pe() {
|
|
4053
|
+
!m || !g || (me(m, g), fe());
|
|
4054
4054
|
}
|
|
4055
|
-
function
|
|
4055
|
+
function me(e, t) {
|
|
4056
4056
|
var n;
|
|
4057
4057
|
if (e === t) return;
|
|
4058
|
-
var r =
|
|
4058
|
+
var r = T(),
|
|
4059
4059
|
i = r.find(function (t) {
|
|
4060
4060
|
return t.blankIds.includes(e);
|
|
4061
4061
|
});
|
|
4062
|
-
|
|
4062
|
+
ne([].concat(_toConsumableArray(r.map(function (n) {
|
|
4063
4063
|
return C(C({}, n), {}, {
|
|
4064
4064
|
blankIds: n.blankIds.filter(function (n) {
|
|
4065
4065
|
return n !== e && n !== t;
|
|
@@ -4072,13 +4072,13 @@ function La(_ref62) {
|
|
|
4072
4072
|
return e.blankIds.length > 0;
|
|
4073
4073
|
}));
|
|
4074
4074
|
}
|
|
4075
|
-
function
|
|
4075
|
+
function he(e) {
|
|
4076
4076
|
var t;
|
|
4077
|
-
var n =
|
|
4077
|
+
var n = T(),
|
|
4078
4078
|
r = n.find(function (t) {
|
|
4079
4079
|
return t.blankIds.includes(e);
|
|
4080
4080
|
});
|
|
4081
|
-
|
|
4081
|
+
ne([].concat(_toConsumableArray(n.map(function (t) {
|
|
4082
4082
|
return C(C({}, t), {}, {
|
|
4083
4083
|
blankIds: t.blankIds.filter(function (t) {
|
|
4084
4084
|
return t !== e;
|
|
@@ -4091,13 +4091,13 @@ function La(_ref62) {
|
|
|
4091
4091
|
return e.blankIds.length > 0;
|
|
4092
4092
|
}));
|
|
4093
4093
|
}
|
|
4094
|
-
function
|
|
4095
|
-
var t =
|
|
4094
|
+
function E(e) {
|
|
4095
|
+
var t = te(e);
|
|
4096
4096
|
p(function (e) {
|
|
4097
4097
|
return C(C({}, e), {}, _defineProperty({}, t, Ra(e, t) + 1));
|
|
4098
4098
|
});
|
|
4099
4099
|
}
|
|
4100
|
-
function
|
|
4100
|
+
function D(e, t) {
|
|
4101
4101
|
return [{
|
|
4102
4102
|
label: u("questionContentEditor.blank.singleAnswer"),
|
|
4103
4103
|
value: "__single__"
|
|
@@ -4109,13 +4109,13 @@ function La(_ref62) {
|
|
|
4109
4109
|
}),
|
|
4110
4110
|
value: "group:".concat(e)
|
|
4111
4111
|
};
|
|
4112
|
-
})), _toConsumableArray(
|
|
4112
|
+
})), _toConsumableArray(ce(e).length > 0 ? [{
|
|
4113
4113
|
label: u("questionContentEditor.blank.newAnswerGroup"),
|
|
4114
4114
|
value: "__new__"
|
|
4115
4115
|
}] : []));
|
|
4116
4116
|
}
|
|
4117
|
-
function
|
|
4118
|
-
return
|
|
4117
|
+
function ge() {
|
|
4118
|
+
return ce(m == null ? "" : m).map(function (e) {
|
|
4119
4119
|
return {
|
|
4120
4120
|
label: u("questionContentEditor.blank.shortLabel", {
|
|
4121
4121
|
index: v.blanks.indexOf(e) + 1
|
|
@@ -4124,7 +4124,7 @@ function La(_ref62) {
|
|
|
4124
4124
|
};
|
|
4125
4125
|
});
|
|
4126
4126
|
}
|
|
4127
|
-
function
|
|
4127
|
+
function _e(e, t) {
|
|
4128
4128
|
var n = new Set(e.map(function (e) {
|
|
4129
4129
|
return e.optionId;
|
|
4130
4130
|
})),
|
|
@@ -4133,7 +4133,7 @@ function La(_ref62) {
|
|
|
4133
4133
|
for (; n.has(i);) r += 1, i = "".concat(t).concat(r);
|
|
4134
4134
|
return i;
|
|
4135
4135
|
}
|
|
4136
|
-
function
|
|
4136
|
+
function ve(n, r) {
|
|
4137
4137
|
return (0, t.jsx)("div", {
|
|
4138
4138
|
className: "flex min-w-0 flex-col gap-2",
|
|
4139
4139
|
children: n.map(function (i, a) {
|
|
@@ -4151,7 +4151,7 @@ function La(_ref62) {
|
|
|
4151
4151
|
index: a + 1
|
|
4152
4152
|
}),
|
|
4153
4153
|
onChange: function onChange(e) {
|
|
4154
|
-
return
|
|
4154
|
+
return ae(n, r, i.optionId, e);
|
|
4155
4155
|
},
|
|
4156
4156
|
placeholder: u("questionContentEditor.placeholders.candidateOption"),
|
|
4157
4157
|
value: i.content,
|
|
@@ -4164,7 +4164,7 @@ function La(_ref62) {
|
|
|
4164
4164
|
disabled: e || n.length <= 1,
|
|
4165
4165
|
icon: "\xD7",
|
|
4166
4166
|
onClick: function onClick() {
|
|
4167
|
-
return
|
|
4167
|
+
return oe(n, r, i.optionId);
|
|
4168
4168
|
},
|
|
4169
4169
|
size: "small"
|
|
4170
4170
|
})]
|
|
@@ -4172,7 +4172,7 @@ function La(_ref62) {
|
|
|
4172
4172
|
})
|
|
4173
4173
|
});
|
|
4174
4174
|
}
|
|
4175
|
-
function
|
|
4175
|
+
function ye(n, r, i, a) {
|
|
4176
4176
|
return (0, t.jsxs)("section", {
|
|
4177
4177
|
className: "flex min-w-0 flex-col gap-3 rounded-md border border-slate-200 bg-white px-4 py-3",
|
|
4178
4178
|
children: [(0, t.jsxs)("div", {
|
|
@@ -4184,22 +4184,22 @@ function La(_ref62) {
|
|
|
4184
4184
|
disabled: e,
|
|
4185
4185
|
icon: "+",
|
|
4186
4186
|
onClick: function onClick() {
|
|
4187
|
-
return r([].concat(_toConsumableArray(n), [yn(
|
|
4187
|
+
return r([].concat(_toConsumableArray(n), [yn(_e(n, a))]));
|
|
4188
4188
|
},
|
|
4189
4189
|
size: "small",
|
|
4190
4190
|
children: u("questionContentEditor.actions.addCandidateOption")
|
|
4191
4191
|
})]
|
|
4192
|
-
}),
|
|
4192
|
+
}), ve(n, r)]
|
|
4193
4193
|
});
|
|
4194
4194
|
}
|
|
4195
|
-
function
|
|
4195
|
+
function be() {
|
|
4196
4196
|
var e;
|
|
4197
4197
|
return (e = v.candidateOptions) == null ? [] : e;
|
|
4198
4198
|
}
|
|
4199
|
-
function
|
|
4199
|
+
function xe(e) {
|
|
4200
4200
|
if (r.config.candidateMode !== "sharedPool" || r.config.allowCandidateReuse) return new Set();
|
|
4201
4201
|
var t = new Set(e.blankIds);
|
|
4202
|
-
return new Set(
|
|
4202
|
+
return new Set(T().filter(function (e) {
|
|
4203
4203
|
return e.blankIds.every(function (e) {
|
|
4204
4204
|
return !t.has(e);
|
|
4205
4205
|
});
|
|
@@ -4207,8 +4207,8 @@ function La(_ref62) {
|
|
|
4207
4207
|
return [].concat(_toConsumableArray(e), _toConsumableArray(t.answerOptionIds));
|
|
4208
4208
|
}, []));
|
|
4209
4209
|
}
|
|
4210
|
-
function
|
|
4211
|
-
var i =
|
|
4210
|
+
function Se(n, r) {
|
|
4211
|
+
var i = te(n),
|
|
4212
4212
|
a = Mn(n),
|
|
4213
4213
|
o = a.length ? [].concat(_toConsumableArray(a), _toConsumableArray(Array.from({
|
|
4214
4214
|
length: Ra(f, i)
|
|
@@ -4219,8 +4219,8 @@ function La(_ref62) {
|
|
|
4219
4219
|
}, function () {
|
|
4220
4220
|
return "";
|
|
4221
4221
|
}),
|
|
4222
|
-
s =
|
|
4223
|
-
c =
|
|
4222
|
+
s = xe(n),
|
|
4223
|
+
c = be().map(function (e, t) {
|
|
4224
4224
|
var n = Zt("upperAlpha", t),
|
|
4225
4225
|
r = a.includes(e.optionId);
|
|
4226
4226
|
return {
|
|
@@ -4243,7 +4243,7 @@ function La(_ref62) {
|
|
|
4243
4243
|
className: "min-w-60",
|
|
4244
4244
|
disabled: e,
|
|
4245
4245
|
onChange: function onChange(e) {
|
|
4246
|
-
return
|
|
4246
|
+
return re(r, a, e);
|
|
4247
4247
|
},
|
|
4248
4248
|
options: c,
|
|
4249
4249
|
placeholder: u("questionContentEditor.placeholders.blankAnswer"),
|
|
@@ -4254,18 +4254,18 @@ function La(_ref62) {
|
|
|
4254
4254
|
disabled: e,
|
|
4255
4255
|
icon: "+",
|
|
4256
4256
|
onClick: function onClick() {
|
|
4257
|
-
return
|
|
4257
|
+
return E(n);
|
|
4258
4258
|
},
|
|
4259
4259
|
type: "dashed",
|
|
4260
4260
|
children: u("questionContentEditor.actions.addAnswerPool")
|
|
4261
4261
|
})]
|
|
4262
4262
|
});
|
|
4263
4263
|
}
|
|
4264
|
-
function
|
|
4264
|
+
function Ce(n) {
|
|
4265
4265
|
return (0, t.jsx)(M, {
|
|
4266
4266
|
disabled: e,
|
|
4267
4267
|
onClick: function onClick() {
|
|
4268
|
-
return
|
|
4268
|
+
return he(n);
|
|
4269
4269
|
},
|
|
4270
4270
|
size: "small",
|
|
4271
4271
|
children: u("questionContentEditor.blank.memberDetach", {
|
|
@@ -4273,7 +4273,7 @@ function La(_ref62) {
|
|
|
4273
4273
|
})
|
|
4274
4274
|
}, n);
|
|
4275
4275
|
}
|
|
4276
|
-
function
|
|
4276
|
+
function we(e, n, r) {
|
|
4277
4277
|
return (0, t.jsxs)("section", {
|
|
4278
4278
|
className: "flex min-w-0 flex-col gap-3 rounded-md border border-blue-200 bg-blue-50/40 px-4 py-3",
|
|
4279
4279
|
children: [(0, t.jsxs)("div", {
|
|
@@ -4285,15 +4285,15 @@ function La(_ref62) {
|
|
|
4285
4285
|
children: u("questionContentEditor.blank.answerGroup", {
|
|
4286
4286
|
index: r + 1
|
|
4287
4287
|
})
|
|
4288
|
-
}), e.blankIds.map(
|
|
4288
|
+
}), e.blankIds.map(Ce)]
|
|
4289
4289
|
}), (0, t.jsx)(N.Text, {
|
|
4290
4290
|
strong: !0,
|
|
4291
4291
|
children: u("questionContentEditor.blank.sharedAnswer")
|
|
4292
4292
|
})]
|
|
4293
|
-
}),
|
|
4293
|
+
}), Se(e, n)]
|
|
4294
4294
|
}, "candidate-shared-group-".concat(n));
|
|
4295
4295
|
}
|
|
4296
|
-
function
|
|
4296
|
+
function Te(n, r, i, a, o) {
|
|
4297
4297
|
return (0, t.jsxs)("section", {
|
|
4298
4298
|
className: "flex min-w-0 flex-wrap items-center gap-4 rounded-md border border-slate-200 bg-white px-4 py-3",
|
|
4299
4299
|
children: [(0, t.jsx)(N.Text, {
|
|
@@ -4309,18 +4309,18 @@ function La(_ref62) {
|
|
|
4309
4309
|
className: "w-48",
|
|
4310
4310
|
disabled: e,
|
|
4311
4311
|
onChange: function onChange(e) {
|
|
4312
|
-
return
|
|
4312
|
+
return le(n, e == null ? "__single__" : e);
|
|
4313
4313
|
},
|
|
4314
|
-
options:
|
|
4314
|
+
options: D(n, o),
|
|
4315
4315
|
value: "__single__"
|
|
4316
4316
|
}), (0, t.jsx)("div", {
|
|
4317
4317
|
className: "min-w-72 flex-1",
|
|
4318
|
-
children:
|
|
4318
|
+
children: Se(i, a)
|
|
4319
4319
|
})]
|
|
4320
4320
|
}, n);
|
|
4321
4321
|
}
|
|
4322
|
-
function
|
|
4323
|
-
return
|
|
4322
|
+
function Ee() {
|
|
4323
|
+
return T().map(function (e, t) {
|
|
4324
4324
|
return {
|
|
4325
4325
|
firstBlankIndex: Math.min.apply(Math, _toConsumableArray(e.blankIds.map(function (e) {
|
|
4326
4326
|
return v.blanks.indexOf(e);
|
|
@@ -4332,36 +4332,36 @@ function La(_ref62) {
|
|
|
4332
4332
|
return e.firstBlankIndex - t.firstBlankIndex;
|
|
4333
4333
|
});
|
|
4334
4334
|
}
|
|
4335
|
-
function
|
|
4336
|
-
var e =
|
|
4335
|
+
function De() {
|
|
4336
|
+
var e = se();
|
|
4337
4337
|
return (0, t.jsxs)("div", {
|
|
4338
4338
|
className: "flex min-w-0 flex-col gap-3",
|
|
4339
4339
|
children: [(0, t.jsx)(N.Text, {
|
|
4340
4340
|
strong: !0,
|
|
4341
4341
|
children: u("questionContentEditor.blank.groupsTitle")
|
|
4342
|
-
}),
|
|
4342
|
+
}), Ee().map(function (_ref70) {
|
|
4343
4343
|
var t = _ref70.group,
|
|
4344
4344
|
n = _ref70.groupIndex;
|
|
4345
|
-
if (t.blankIds.length > 1) return
|
|
4345
|
+
if (t.blankIds.length > 1) return we(t, n, e.findIndex(function (e) {
|
|
4346
4346
|
return e.groupIndex === n;
|
|
4347
4347
|
}));
|
|
4348
4348
|
var r = t.blankIds[0];
|
|
4349
|
-
return r ?
|
|
4349
|
+
return r ? Te(r, v.blanks.indexOf(r), t, n, e) : null;
|
|
4350
4350
|
})]
|
|
4351
4351
|
});
|
|
4352
4352
|
}
|
|
4353
|
-
function
|
|
4353
|
+
function Oe(e) {
|
|
4354
4354
|
var t, n;
|
|
4355
4355
|
var r = v.answers.find(function (t) {
|
|
4356
4356
|
return "answerOptionId" in t && t.blankId === e;
|
|
4357
4357
|
}),
|
|
4358
|
-
i = (t = (n =
|
|
4358
|
+
i = (t = (n = ie(e).options[0]) == null ? void 0 : n.optionId) == null ? "" : t;
|
|
4359
4359
|
return {
|
|
4360
4360
|
answerOptionId: (r == null ? void 0 : r.answerOptionId) || i,
|
|
4361
4361
|
blankId: e
|
|
4362
4362
|
};
|
|
4363
4363
|
}
|
|
4364
|
-
function
|
|
4364
|
+
function ke(e, t) {
|
|
4365
4365
|
x(C(C({}, v), {}, {
|
|
4366
4366
|
answers: v.answers.map(function (n) {
|
|
4367
4367
|
return "answerOptionId" in n && n.blankId === e ? C(C({}, n), {}, {
|
|
@@ -4370,14 +4370,14 @@ function La(_ref62) {
|
|
|
4370
4370
|
})
|
|
4371
4371
|
}));
|
|
4372
4372
|
}
|
|
4373
|
-
function
|
|
4374
|
-
|
|
4373
|
+
function Ae(e, t) {
|
|
4374
|
+
w(e, {
|
|
4375
4375
|
blankId: e,
|
|
4376
4376
|
options: t
|
|
4377
4377
|
});
|
|
4378
4378
|
}
|
|
4379
|
-
function
|
|
4380
|
-
var a =
|
|
4379
|
+
function je(n, r) {
|
|
4380
|
+
var a = Oe(n.blankId),
|
|
4381
4381
|
o = n.options.map(function (e, t) {
|
|
4382
4382
|
return {
|
|
4383
4383
|
label: "".concat(Zt("upperAlpha", t), ". ").concat(e.content.text || u("questionContentEditor.fields.candidateOption", {
|
|
@@ -4409,7 +4409,7 @@ function La(_ref62) {
|
|
|
4409
4409
|
className: "min-w-48",
|
|
4410
4410
|
disabled: e,
|
|
4411
4411
|
onChange: function onChange(e) {
|
|
4412
|
-
return e ?
|
|
4412
|
+
return e ? ke(n.blankId, e) : void 0;
|
|
4413
4413
|
},
|
|
4414
4414
|
options: o,
|
|
4415
4415
|
value: a.answerOptionId
|
|
@@ -4417,22 +4417,22 @@ function La(_ref62) {
|
|
|
4417
4417
|
}) : null, (0, t.jsx)(M, {
|
|
4418
4418
|
disabled: e,
|
|
4419
4419
|
onClick: function onClick() {
|
|
4420
|
-
return
|
|
4420
|
+
return Ae(n.blankId, [].concat(_toConsumableArray(n.options), [yn(_e(n.options, "".concat(n.blankId, "_option_")))]));
|
|
4421
4421
|
},
|
|
4422
4422
|
size: "small",
|
|
4423
4423
|
children: u("questionContentEditor.actions.addBlankOption")
|
|
4424
4424
|
})]
|
|
4425
4425
|
})]
|
|
4426
|
-
}),
|
|
4427
|
-
return
|
|
4426
|
+
}), ve(n.options, function (e) {
|
|
4427
|
+
return Ae(n.blankId, e);
|
|
4428
4428
|
})]
|
|
4429
4429
|
}, n.blankId);
|
|
4430
4430
|
}
|
|
4431
|
-
function
|
|
4431
|
+
function Me() {
|
|
4432
4432
|
if (r.config.candidateMode === "sharedPool") {
|
|
4433
4433
|
var e;
|
|
4434
4434
|
return (0, t.jsxs)(t.Fragment, {
|
|
4435
|
-
children: [
|
|
4435
|
+
children: [ye((e = v.candidateOptions) == null ? [] : e, ee, u("questionContentEditor.fields.candidateOptions"), "option_"), i ? De() : null]
|
|
4436
4436
|
});
|
|
4437
4437
|
}
|
|
4438
4438
|
var n = jn(v.blankOptionGroups, v.blanks);
|
|
@@ -4441,7 +4441,7 @@ function La(_ref62) {
|
|
|
4441
4441
|
children: [(0, t.jsx)(N.Text, {
|
|
4442
4442
|
strong: !0,
|
|
4443
4443
|
children: u("questionContentEditor.blank.perBlankOptionsTitle")
|
|
4444
|
-
}), n.map(
|
|
4444
|
+
}), n.map(je)]
|
|
4445
4445
|
});
|
|
4446
4446
|
}
|
|
4447
4447
|
return (0, t.jsxs)("div", {
|
|
@@ -4476,15 +4476,15 @@ function La(_ref62) {
|
|
|
4476
4476
|
onChange: S,
|
|
4477
4477
|
richTextControls: s,
|
|
4478
4478
|
translator: l
|
|
4479
|
-
}) :
|
|
4479
|
+
}) : Me(), (0, t.jsx)(_a, {
|
|
4480
4480
|
cancelText: u("questionContentEditor.actions.cancel"),
|
|
4481
4481
|
closeLabel: u("questionContentEditor.actions.close"),
|
|
4482
4482
|
okButtonProps: {
|
|
4483
4483
|
disabled: !g
|
|
4484
4484
|
},
|
|
4485
4485
|
okText: u("questionContentEditor.actions.confirmCreateAnswerGroup"),
|
|
4486
|
-
onCancel:
|
|
4487
|
-
onOk:
|
|
4486
|
+
onCancel: fe,
|
|
4487
|
+
onOk: pe,
|
|
4488
4488
|
open: !!m,
|
|
4489
4489
|
title: u("questionContentEditor.blank.createGroupTitle"),
|
|
4490
4490
|
children: (0, t.jsxs)("div", {
|
|
@@ -4496,7 +4496,7 @@ function La(_ref62) {
|
|
|
4496
4496
|
onChange: function onChange(e) {
|
|
4497
4497
|
return _(String(e.target.value));
|
|
4498
4498
|
},
|
|
4499
|
-
options:
|
|
4499
|
+
options: ge(),
|
|
4500
4500
|
value: g
|
|
4501
4501
|
})]
|
|
4502
4502
|
})
|
|
@@ -4570,7 +4570,7 @@ function Ha(e) {
|
|
|
4570
4570
|
return Array.isArray(e);
|
|
4571
4571
|
}
|
|
4572
4572
|
function Ua(e, t) {
|
|
4573
|
-
var n = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] :
|
|
4573
|
+
var n = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : Ye;
|
|
4574
4574
|
var r = e.columns.reduce(function (e, t, n) {
|
|
4575
4575
|
return t.items.forEach(function (t, r) {
|
|
4576
4576
|
return e.set(t.itemId, {
|
|
@@ -4740,26 +4740,26 @@ function Qa(_ref77) {
|
|
|
4740
4740
|
function ee(e, t) {
|
|
4741
4741
|
S(cr(g, e, t));
|
|
4742
4742
|
}
|
|
4743
|
-
function
|
|
4743
|
+
function w(e, t) {
|
|
4744
4744
|
S(C(C({}, g), {}, {
|
|
4745
4745
|
answers: lr(g.answers, e, t)
|
|
4746
4746
|
}));
|
|
4747
4747
|
}
|
|
4748
|
-
function
|
|
4748
|
+
function T(t, n, r) {
|
|
4749
4749
|
if (e || !i) return;
|
|
4750
4750
|
var a = {
|
|
4751
4751
|
columnIndex: t,
|
|
4752
4752
|
itemId: n,
|
|
4753
4753
|
label: r
|
|
4754
4754
|
},
|
|
4755
|
-
o = u ?
|
|
4755
|
+
o = u ? Xe(u, a) : null;
|
|
4756
4756
|
if (o) {
|
|
4757
|
-
|
|
4757
|
+
w(o.fromItemId, o.toItemId), d(null);
|
|
4758
4758
|
return;
|
|
4759
4759
|
}
|
|
4760
4760
|
d(a);
|
|
4761
4761
|
}
|
|
4762
|
-
function
|
|
4762
|
+
function te() {
|
|
4763
4763
|
return i ? (0, t.jsx)("div", {
|
|
4764
4764
|
"aria-live": "polite",
|
|
4765
4765
|
className: "rounded-md border border-blue-100 bg-blue-50 px-3 py-2 text-sm text-blue-700",
|
|
@@ -4768,7 +4768,7 @@ function Qa(_ref77) {
|
|
|
4768
4768
|
}) : l("questionContentEditor.lineConnect.connectHintIdle")
|
|
4769
4769
|
}) : null;
|
|
4770
4770
|
}
|
|
4771
|
-
function
|
|
4771
|
+
function ne(n, r) {
|
|
4772
4772
|
return (0, t.jsxs)("section", {
|
|
4773
4773
|
className: L.column,
|
|
4774
4774
|
children: [(0, t.jsxs)("div", {
|
|
@@ -4811,7 +4811,7 @@ function Qa(_ref77) {
|
|
|
4811
4811
|
}), (0, t.jsx)("div", {
|
|
4812
4812
|
className: "flex min-w-0 flex-col gap-2",
|
|
4813
4813
|
children: n.items.map(function (e, t) {
|
|
4814
|
-
return
|
|
4814
|
+
return re(n, r, e, t);
|
|
4815
4815
|
})
|
|
4816
4816
|
}), (0, t.jsx)(M, {
|
|
4817
4817
|
"aria-label": l("questionContentEditor.lineConnect.addItem", {
|
|
@@ -4829,7 +4829,7 @@ function Qa(_ref77) {
|
|
|
4829
4829
|
})]
|
|
4830
4830
|
}, n.columnId);
|
|
4831
4831
|
}
|
|
4832
|
-
function
|
|
4832
|
+
function re(n, r, a, o) {
|
|
4833
4833
|
var c = Qt(n.labelStyle, o),
|
|
4834
4834
|
d = c ? "".concat(c, ". ").concat(a.content.text) : a.content.text,
|
|
4835
4835
|
f = (u == null ? void 0 : u.itemId) === a.itemId,
|
|
@@ -4841,7 +4841,7 @@ function Qa(_ref77) {
|
|
|
4841
4841
|
className: ro(f, h),
|
|
4842
4842
|
"data-testid": "line-connect-item-".concat(a.itemId),
|
|
4843
4843
|
style: _,
|
|
4844
|
-
children: [
|
|
4844
|
+
children: [ie(r, a, o, c, d, p), (0, t.jsx)(F, {
|
|
4845
4845
|
controls: s,
|
|
4846
4846
|
disabled: e,
|
|
4847
4847
|
label: l("questionContentEditor.lineConnect.itemAria", {
|
|
@@ -4868,17 +4868,17 @@ function Qa(_ref77) {
|
|
|
4868
4868
|
return S(sr(g, a.itemId));
|
|
4869
4869
|
},
|
|
4870
4870
|
size: "small"
|
|
4871
|
-
}),
|
|
4871
|
+
}), ae(r, a, o, d, f, m)]
|
|
4872
4872
|
}, a.itemId);
|
|
4873
4873
|
}
|
|
4874
|
-
function
|
|
4874
|
+
function ie(n, r, a, o, s, c) {
|
|
4875
4875
|
return i ? (0, t.jsx)("button", {
|
|
4876
|
-
"aria-label":
|
|
4876
|
+
"aria-label": oe("incoming", n, a, r.content.text),
|
|
4877
4877
|
"aria-pressed": c,
|
|
4878
4878
|
className: Ba(R.marker, R["incoming-marker"], c && R["connect-button-connected"]),
|
|
4879
4879
|
disabled: e,
|
|
4880
4880
|
onClick: function onClick() {
|
|
4881
|
-
return
|
|
4881
|
+
return T(n, r.itemId, s);
|
|
4882
4882
|
},
|
|
4883
4883
|
ref: x(r.itemId, "incoming"),
|
|
4884
4884
|
title: u ? l("questionContentEditor.lineConnect.connectHintActive", {
|
|
@@ -4895,15 +4895,15 @@ function Qa(_ref77) {
|
|
|
4895
4895
|
children: o
|
|
4896
4896
|
});
|
|
4897
4897
|
}
|
|
4898
|
-
function
|
|
4898
|
+
function ae(n, r, a, o, s, c) {
|
|
4899
4899
|
return i ? (0, t.jsx)("button", {
|
|
4900
|
-
"aria-label":
|
|
4900
|
+
"aria-label": oe("outgoing", n, a, r.content.text),
|
|
4901
4901
|
"aria-pressed": s,
|
|
4902
4902
|
className: Ba(R["connect-handle"], R["connect-handle-outgoing"], s && R["connect-button-selected"], c && R["connect-button-connected"]),
|
|
4903
4903
|
disabled: e,
|
|
4904
4904
|
ref: x(r.itemId, "outgoing"),
|
|
4905
4905
|
onClick: function onClick() {
|
|
4906
|
-
return
|
|
4906
|
+
return T(n, r.itemId, o);
|
|
4907
4907
|
},
|
|
4908
4908
|
title: u ? l("questionContentEditor.lineConnect.connectHintActive", {
|
|
4909
4909
|
label: u.label
|
|
@@ -4915,7 +4915,7 @@ function Qa(_ref77) {
|
|
|
4915
4915
|
})
|
|
4916
4916
|
}) : null;
|
|
4917
4917
|
}
|
|
4918
|
-
function
|
|
4918
|
+
function oe(e, t, n, r) {
|
|
4919
4919
|
return l("questionContentEditor.lineConnect.".concat(e === "incoming" ? "connectToAria" : "connectFromAria"), {
|
|
4920
4920
|
column: t + 1,
|
|
4921
4921
|
content: r,
|
|
@@ -4924,7 +4924,7 @@ function Qa(_ref77) {
|
|
|
4924
4924
|
}
|
|
4925
4925
|
return (0, t.jsxs)("div", {
|
|
4926
4926
|
className: "flex min-w-0 flex-col gap-4",
|
|
4927
|
-
children: [
|
|
4927
|
+
children: [te(), (0, t.jsxs)("div", {
|
|
4928
4928
|
className: L.board,
|
|
4929
4929
|
"data-testid": "line-connect-editor-board",
|
|
4930
4930
|
ref: m,
|
|
@@ -4950,7 +4950,7 @@ function Qa(_ref77) {
|
|
|
4950
4950
|
}) : null, (0, t.jsx)("div", {
|
|
4951
4951
|
className: L.columns,
|
|
4952
4952
|
style: _,
|
|
4953
|
-
children: g.columns.map(
|
|
4953
|
+
children: g.columns.map(ne)
|
|
4954
4954
|
})]
|
|
4955
4955
|
}), (0, t.jsx)(M, {
|
|
4956
4956
|
"aria-label": l("questionContentEditor.lineConnect.addColumn"),
|
|
@@ -5022,7 +5022,7 @@ function oo(_ref82) {
|
|
|
5022
5022
|
gridTemplateColumns: "repeat(".concat(g.columns.length, ", minmax(16rem, 1fr))")
|
|
5023
5023
|
},
|
|
5024
5024
|
v = (0, n.useMemo)(function () {
|
|
5025
|
-
return i ? Ua(g, g.answers,
|
|
5025
|
+
return i ? Ua(g, g.answers, st) : [];
|
|
5026
5026
|
}, [i, g]),
|
|
5027
5027
|
y = (0, n.useMemo)(function () {
|
|
5028
5028
|
return JSON.stringify({
|
|
@@ -5093,14 +5093,14 @@ function oo(_ref82) {
|
|
|
5093
5093
|
function ee(e, t) {
|
|
5094
5094
|
S(hr(g, e, t));
|
|
5095
5095
|
}
|
|
5096
|
-
function
|
|
5096
|
+
function w(t, n, r) {
|
|
5097
5097
|
if (e || !i) return;
|
|
5098
5098
|
var a = {
|
|
5099
5099
|
columnIndex: t,
|
|
5100
5100
|
itemId: n,
|
|
5101
5101
|
label: r
|
|
5102
5102
|
},
|
|
5103
|
-
o = u ?
|
|
5103
|
+
o = u ? ct(u, a) : null;
|
|
5104
5104
|
if (o) {
|
|
5105
5105
|
S(C(C({}, g), {}, {
|
|
5106
5106
|
answers: gr(g.answers, o.fromItemId, o.toItemId)
|
|
@@ -5109,7 +5109,7 @@ function oo(_ref82) {
|
|
|
5109
5109
|
}
|
|
5110
5110
|
d(a);
|
|
5111
5111
|
}
|
|
5112
|
-
function
|
|
5112
|
+
function T(n, r) {
|
|
5113
5113
|
return (0, t.jsxs)("section", {
|
|
5114
5114
|
className: z.column,
|
|
5115
5115
|
children: [(0, t.jsx)("div", {
|
|
@@ -5133,7 +5133,7 @@ function oo(_ref82) {
|
|
|
5133
5133
|
}), (0, t.jsx)("div", {
|
|
5134
5134
|
className: z.items,
|
|
5135
5135
|
children: n.items.map(function (e, t) {
|
|
5136
|
-
return
|
|
5136
|
+
return te(n, r, e, t);
|
|
5137
5137
|
})
|
|
5138
5138
|
}), (0, t.jsx)(M, {
|
|
5139
5139
|
"aria-label": l("questionContentEditor.matching.addItem", {
|
|
@@ -5149,7 +5149,7 @@ function oo(_ref82) {
|
|
|
5149
5149
|
})]
|
|
5150
5150
|
}, n.columnId);
|
|
5151
5151
|
}
|
|
5152
|
-
function
|
|
5152
|
+
function te(n, r, a, o) {
|
|
5153
5153
|
var c = $t(n.labelStyle, o),
|
|
5154
5154
|
d = (u == null ? void 0 : u.itemId) === a.itemId,
|
|
5155
5155
|
f = so(g, a.itemId),
|
|
@@ -5161,7 +5161,7 @@ function oo(_ref82) {
|
|
|
5161
5161
|
className: Ba(z.item, d ? z.selected : "", m ? z.matched : ""),
|
|
5162
5162
|
"data-testid": "matching-editor-item-".concat(a.itemId),
|
|
5163
5163
|
style: _,
|
|
5164
|
-
children: [
|
|
5164
|
+
children: [ne(r, a, o, c, h, f), (0, t.jsx)(F, {
|
|
5165
5165
|
controls: s,
|
|
5166
5166
|
disabled: e,
|
|
5167
5167
|
label: l("questionContentEditor.matching.itemAria", {
|
|
@@ -5188,17 +5188,17 @@ function oo(_ref82) {
|
|
|
5188
5188
|
return S(mr(g, a.itemId));
|
|
5189
5189
|
},
|
|
5190
5190
|
size: "small"
|
|
5191
|
-
}),
|
|
5191
|
+
}), re(r, a, o, h, d, p)]
|
|
5192
5192
|
}, a.itemId);
|
|
5193
5193
|
}
|
|
5194
|
-
function
|
|
5194
|
+
function ne(n, r, a, o, s, c) {
|
|
5195
5195
|
return i ? (0, t.jsx)("button", {
|
|
5196
|
-
"aria-label":
|
|
5196
|
+
"aria-label": ie("incoming", n, a, r.content.text),
|
|
5197
5197
|
"aria-pressed": c,
|
|
5198
5198
|
className: Ba(z.marker, R["incoming-marker"], c && R["connect-button-connected"]),
|
|
5199
5199
|
disabled: e,
|
|
5200
5200
|
onClick: function onClick() {
|
|
5201
|
-
return
|
|
5201
|
+
return w(n, r.itemId, s);
|
|
5202
5202
|
},
|
|
5203
5203
|
ref: x(r.itemId, "incoming"),
|
|
5204
5204
|
title: u ? l("questionContentEditor.matching.connectHintActive", {
|
|
@@ -5214,14 +5214,14 @@ function oo(_ref82) {
|
|
|
5214
5214
|
children: o
|
|
5215
5215
|
}) : (0, t.jsx)("span", {});
|
|
5216
5216
|
}
|
|
5217
|
-
function
|
|
5217
|
+
function re(n, r, a, o, s, c) {
|
|
5218
5218
|
return i ? (0, t.jsx)("button", {
|
|
5219
|
-
"aria-label":
|
|
5219
|
+
"aria-label": ie("outgoing", n, a, r.content.text),
|
|
5220
5220
|
"aria-pressed": s,
|
|
5221
5221
|
className: Ba(R["connect-handle"], R["connect-handle-outgoing"], s && R["connect-button-selected"], c && R["connect-button-connected"]),
|
|
5222
5222
|
disabled: e,
|
|
5223
5223
|
onClick: function onClick() {
|
|
5224
|
-
return
|
|
5224
|
+
return w(n, r.itemId, o);
|
|
5225
5225
|
},
|
|
5226
5226
|
ref: x(r.itemId, "outgoing"),
|
|
5227
5227
|
title: u ? l("questionContentEditor.matching.connectHintActive", {
|
|
@@ -5234,7 +5234,7 @@ function oo(_ref82) {
|
|
|
5234
5234
|
})
|
|
5235
5235
|
}) : null;
|
|
5236
5236
|
}
|
|
5237
|
-
function
|
|
5237
|
+
function ie(e, t, n, r) {
|
|
5238
5238
|
return l("questionContentEditor.matching.".concat(e === "incoming" ? "connectToAria" : "connectFromAria"), {
|
|
5239
5239
|
column: t + 1,
|
|
5240
5240
|
content: r,
|
|
@@ -5276,7 +5276,7 @@ function oo(_ref82) {
|
|
|
5276
5276
|
className: z.columns,
|
|
5277
5277
|
style: _,
|
|
5278
5278
|
children: g.columns.map(function (e, t) {
|
|
5279
|
-
return
|
|
5279
|
+
return T(e, t);
|
|
5280
5280
|
})
|
|
5281
5281
|
})]
|
|
5282
5282
|
})]
|
|
@@ -5334,20 +5334,20 @@ function fo(_ref87) {
|
|
|
5334
5334
|
}
|
|
5335
5335
|
}));
|
|
5336
5336
|
}
|
|
5337
|
-
function _(n, r, i
|
|
5338
|
-
var
|
|
5339
|
-
return (0, t.
|
|
5337
|
+
function _(n, r, i) {
|
|
5338
|
+
var a = l.includes(n);
|
|
5339
|
+
return (0, t.jsx)("button", {
|
|
5340
5340
|
"aria-label": c("questionContentEditor.option.answerAria", {
|
|
5341
5341
|
index: r + 1
|
|
5342
5342
|
}),
|
|
5343
|
-
"aria-pressed":
|
|
5344
|
-
className: "min-h-12 rounded-md border px-3 py-2 text-left text-sm font-medium transition ".concat(
|
|
5343
|
+
"aria-pressed": a,
|
|
5344
|
+
className: "min-h-12 rounded-md border px-3 py-2 text-left text-sm font-medium transition ".concat(a ? "border-blue-600 bg-blue-50 text-blue-700" : "border-slate-200 bg-white text-slate-900 hover:border-blue-300"),
|
|
5345
5345
|
disabled: e,
|
|
5346
5346
|
onClick: function onClick() {
|
|
5347
5347
|
return g(n);
|
|
5348
5348
|
},
|
|
5349
5349
|
type: "button",
|
|
5350
|
-
children:
|
|
5350
|
+
children: i
|
|
5351
5351
|
}, "answer-option-".concat(n));
|
|
5352
5352
|
}
|
|
5353
5353
|
function v() {
|
|
@@ -5533,34 +5533,7 @@ function fo(_ref87) {
|
|
|
5533
5533
|
});
|
|
5534
5534
|
}
|
|
5535
5535
|
function x() {
|
|
5536
|
-
return
|
|
5537
|
-
return {
|
|
5538
|
-
marker: e.marker,
|
|
5539
|
-
optionId: e.optionId,
|
|
5540
|
-
text: e.standardContent.text || c("questionContentEditor.placeholders.option", {
|
|
5541
|
-
marker: e.marker
|
|
5542
|
-
})
|
|
5543
|
-
};
|
|
5544
|
-
});
|
|
5545
|
-
}
|
|
5546
|
-
function S() {
|
|
5547
|
-
return d.map(function (e) {
|
|
5548
|
-
var t = e.cells.map(function (e) {
|
|
5549
|
-
return e.text.trim();
|
|
5550
|
-
}).filter(Boolean).join(" / ") || c("questionContentEditor.placeholders.option", {
|
|
5551
|
-
marker: e.marker
|
|
5552
|
-
});
|
|
5553
|
-
return {
|
|
5554
|
-
marker: e.marker,
|
|
5555
|
-
optionId: e.optionId,
|
|
5556
|
-
text: t
|
|
5557
|
-
};
|
|
5558
|
-
});
|
|
5559
|
-
}
|
|
5560
|
-
function ee() {
|
|
5561
|
-
if (!r) return null;
|
|
5562
|
-
var e = u ? S() : x();
|
|
5563
|
-
return (0, t.jsxs)("div", {
|
|
5536
|
+
return r ? (0, t.jsxs)("div", {
|
|
5564
5537
|
className: "mt-2 border-t border-slate-200 pt-4",
|
|
5565
5538
|
children: [(0, t.jsx)(N.Text, {
|
|
5566
5539
|
className: "mb-3 block text-base",
|
|
@@ -5568,18 +5541,17 @@ function fo(_ref87) {
|
|
|
5568
5541
|
children: c("questionContentEditor.option.answerSettings")
|
|
5569
5542
|
}), (0, t.jsx)("div", {
|
|
5570
5543
|
className: "grid min-w-0 grid-cols-1 gap-2 md:grid-cols-2 xl:grid-cols-4",
|
|
5571
|
-
children:
|
|
5544
|
+
children: d.map(function (_ref88, n) {
|
|
5572
5545
|
var e = _ref88.marker,
|
|
5573
|
-
t = _ref88.optionId
|
|
5574
|
-
|
|
5575
|
-
return _(t, r, e, n);
|
|
5546
|
+
t = _ref88.optionId;
|
|
5547
|
+
return _(t, n, e);
|
|
5576
5548
|
})
|
|
5577
5549
|
})]
|
|
5578
|
-
});
|
|
5550
|
+
}) : null;
|
|
5579
5551
|
}
|
|
5580
5552
|
return (0, t.jsxs)("div", {
|
|
5581
5553
|
className: "flex min-w-0 flex-col gap-3",
|
|
5582
|
-
children: [u ? b() : v(),
|
|
5554
|
+
children: [u ? b() : v(), x()]
|
|
5583
5555
|
});
|
|
5584
5556
|
}
|
|
5585
5557
|
function po(_ref89) {
|
|
@@ -5730,13 +5702,13 @@ function go(_ref91) {
|
|
|
5730
5702
|
c = _ref91.translator;
|
|
5731
5703
|
var l = (0, n.useRef)(null),
|
|
5732
5704
|
u = c.t,
|
|
5733
|
-
d =
|
|
5705
|
+
d = yt(i.content.json);
|
|
5734
5706
|
function f(e) {
|
|
5735
5707
|
a(gn(e, e.content, r));
|
|
5736
5708
|
}
|
|
5737
5709
|
function p() {
|
|
5738
5710
|
var e;
|
|
5739
|
-
var t =
|
|
5711
|
+
var t = bt();
|
|
5740
5712
|
(e = l.current) == null || e.runCommand({
|
|
5741
5713
|
command: "mark.textMarker",
|
|
5742
5714
|
payload: t
|
|
@@ -6362,7 +6334,7 @@ function Bo(_ref100) {
|
|
|
6362
6334
|
y = Io(_ ? v.children : []);
|
|
6363
6335
|
if (!_) return (0, t.jsxs)("section", {
|
|
6364
6336
|
className: "flex min-w-0 flex-col gap-3 border-b border-l-2 border-slate-200 border-l-blue-600 bg-white py-4 pr-0 pl-3 last:border-b-0 sm:pl-4",
|
|
6365
|
-
children: [
|
|
6337
|
+
children: [w(null), T((0, t.jsx)(ba, {
|
|
6366
6338
|
description: p("questionContentEditor.subquestion.missingTemplate")
|
|
6367
6339
|
}))]
|
|
6368
6340
|
});
|
|
@@ -6395,7 +6367,7 @@ function Bo(_ref100) {
|
|
|
6395
6367
|
}
|
|
6396
6368
|
return (0, t.jsxs)("section", {
|
|
6397
6369
|
className: "flex min-w-0 flex-col gap-3 border-b border-l-2 border-slate-200 border-l-blue-600 bg-white py-4 pr-0 pl-3 last:border-b-0 sm:pl-4",
|
|
6398
|
-
children: [
|
|
6370
|
+
children: [w(b), T(Uo(i, v, o, l, _, f)), v.children.length === 0 ? null : (0, t.jsx)("div", {
|
|
6399
6371
|
className: "ml-3 flex min-w-0 flex-col pl-3 sm:ml-4 sm:pl-4",
|
|
6400
6372
|
children: y.map(function (e, n) {
|
|
6401
6373
|
return (0, t.jsx)(Bo, {
|
|
@@ -6421,7 +6393,7 @@ function Bo(_ref100) {
|
|
|
6421
6393
|
})
|
|
6422
6394
|
})]
|
|
6423
6395
|
});
|
|
6424
|
-
function
|
|
6396
|
+
function w(r) {
|
|
6425
6397
|
return (0, t.jsxs)("div", {
|
|
6426
6398
|
className: "flex min-w-0 flex-wrap items-start justify-between gap-3",
|
|
6427
6399
|
children: [(0, t.jsx)("span", {
|
|
@@ -6472,7 +6444,7 @@ function Bo(_ref100) {
|
|
|
6472
6444
|
})]
|
|
6473
6445
|
});
|
|
6474
6446
|
}
|
|
6475
|
-
function
|
|
6447
|
+
function T(e) {
|
|
6476
6448
|
return (0, t.jsx)(Ao, {
|
|
6477
6449
|
number: Do(m, u) ? h : null,
|
|
6478
6450
|
children: e
|
|
@@ -6612,7 +6584,7 @@ function qo(_ref102) {
|
|
|
6612
6584
|
f = Zi(o, l),
|
|
6613
6585
|
p = (0, n.useMemo)(function () {
|
|
6614
6586
|
return {
|
|
6615
|
-
plugins: [
|
|
6587
|
+
plugins: [Dt, ra],
|
|
6616
6588
|
uploadImage: s
|
|
6617
6589
|
};
|
|
6618
6590
|
}, [s]);
|
|
@@ -6711,7 +6683,7 @@ function Xo(e, t) {
|
|
|
6711
6683
|
}),
|
|
6712
6684
|
extras: e.extras.map(function (e) {
|
|
6713
6685
|
return {
|
|
6714
|
-
name: ls(e,
|
|
6686
|
+
name: ls(e, ge(e.type), _e(e.type), t),
|
|
6715
6687
|
type: e.type
|
|
6716
6688
|
};
|
|
6717
6689
|
}),
|
|
@@ -6832,7 +6804,7 @@ function os(e) {
|
|
|
6832
6804
|
function ss(e, t) {
|
|
6833
6805
|
return e.type === "fill" || e.type === "classification" || e.type === "ordering" || e.type === "richText" || e.type === "textMarker" || e.type === "textResponse" ? {
|
|
6834
6806
|
config: {},
|
|
6835
|
-
name: ls(e,
|
|
6807
|
+
name: ls(e, E(e.type), D(e.type), t),
|
|
6836
6808
|
type: e.type
|
|
6837
6809
|
} : cs(e, t);
|
|
6838
6810
|
}
|
|
@@ -6844,7 +6816,7 @@ function cs(e, t) {
|
|
|
6844
6816
|
allowCandidateReuse: !!e.config.allowCandidateReuse,
|
|
6845
6817
|
candidateMode: e.config.candidateMode
|
|
6846
6818
|
},
|
|
6847
|
-
name: ls(e,
|
|
6819
|
+
name: ls(e, E("inlineFill"), D("inlineFill"), t),
|
|
6848
6820
|
type: "inlineFill"
|
|
6849
6821
|
};
|
|
6850
6822
|
case "wordBuilder":
|
|
@@ -6852,7 +6824,7 @@ function cs(e, t) {
|
|
|
6852
6824
|
config: {
|
|
6853
6825
|
builderMode: e.config.builderMode
|
|
6854
6826
|
},
|
|
6855
|
-
name: ls(e,
|
|
6827
|
+
name: ls(e, E("wordBuilder"), D("wordBuilder"), t),
|
|
6856
6828
|
type: "wordBuilder"
|
|
6857
6829
|
};
|
|
6858
6830
|
case "judgement":
|
|
@@ -6860,7 +6832,7 @@ function cs(e, t) {
|
|
|
6860
6832
|
config: {
|
|
6861
6833
|
judgeAnswerMode: e.config.judgeAnswerMode
|
|
6862
6834
|
},
|
|
6863
|
-
name: ls(e,
|
|
6835
|
+
name: ls(e, E("judgement"), D("judgement"), t),
|
|
6864
6836
|
type: "judgement"
|
|
6865
6837
|
};
|
|
6866
6838
|
case "choice":
|
|
@@ -6870,7 +6842,7 @@ function cs(e, t) {
|
|
|
6870
6842
|
renderer: e.config.renderer,
|
|
6871
6843
|
selectionType: e.config.selectionType
|
|
6872
6844
|
},
|
|
6873
|
-
name: ls(e,
|
|
6845
|
+
name: ls(e, E("choice"), D("choice"), t),
|
|
6874
6846
|
type: "choice"
|
|
6875
6847
|
};
|
|
6876
6848
|
case "lineConnect":
|
|
@@ -6880,7 +6852,7 @@ function cs(e, t) {
|
|
|
6880
6852
|
return C({}, e);
|
|
6881
6853
|
})
|
|
6882
6854
|
},
|
|
6883
|
-
name: ls(e,
|
|
6855
|
+
name: ls(e, E("lineConnect"), D("lineConnect"), t),
|
|
6884
6856
|
type: "lineConnect"
|
|
6885
6857
|
};
|
|
6886
6858
|
case "matching":
|
|
@@ -6890,7 +6862,7 @@ function cs(e, t) {
|
|
|
6890
6862
|
return C({}, e);
|
|
6891
6863
|
})
|
|
6892
6864
|
},
|
|
6893
|
-
name: ls(e,
|
|
6865
|
+
name: ls(e, E("matching"), D("matching"), t),
|
|
6894
6866
|
type: "matching"
|
|
6895
6867
|
};
|
|
6896
6868
|
}
|
|
@@ -7301,23 +7273,23 @@ function Js(e, t, n) {
|
|
|
7301
7273
|
});
|
|
7302
7274
|
}
|
|
7303
7275
|
function Ys(e, t, n) {
|
|
7304
|
-
return
|
|
7276
|
+
return Fe(e, t, n);
|
|
7305
7277
|
}
|
|
7306
7278
|
function Xs(e, t) {
|
|
7307
7279
|
var n = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : "single";
|
|
7308
7280
|
return {
|
|
7309
7281
|
kind: "option",
|
|
7310
|
-
optionIds:
|
|
7282
|
+
optionIds: Fe((e == null ? void 0 : e.kind) === "option" ? e.optionIds : [], t, n)
|
|
7311
7283
|
};
|
|
7312
7284
|
}
|
|
7313
7285
|
function Zs(e, t, n) {
|
|
7314
|
-
return
|
|
7286
|
+
return nt(e, t, n);
|
|
7315
7287
|
}
|
|
7316
7288
|
function Qs(e, t, n) {
|
|
7317
|
-
return
|
|
7289
|
+
return dt(e, t, n);
|
|
7318
7290
|
}
|
|
7319
7291
|
function $s(e, t, n) {
|
|
7320
|
-
return
|
|
7292
|
+
return Ke(e, t, n);
|
|
7321
7293
|
}
|
|
7322
7294
|
function ec(e, t, n, r) {
|
|
7323
7295
|
return Mr(e, t.sortOptions, n, r);
|
|
@@ -7400,7 +7372,7 @@ function dc() {
|
|
|
7400
7372
|
};
|
|
7401
7373
|
}
|
|
7402
7374
|
function fc(e, t) {
|
|
7403
|
-
return
|
|
7375
|
+
return Ge(e, t.categories, t.items);
|
|
7404
7376
|
}
|
|
7405
7377
|
function pc(e) {
|
|
7406
7378
|
return e.type === "ordering" ? {
|
|
@@ -7729,7 +7701,7 @@ function G(_ref107) {
|
|
|
7729
7701
|
var n = _ref107.className,
|
|
7730
7702
|
r = _ref107.content;
|
|
7731
7703
|
var i = r.html || (0, e.serializeRichTextEditorHtml)(Jt(r), {
|
|
7732
|
-
plugins: [
|
|
7704
|
+
plugins: [Dt]
|
|
7733
7705
|
});
|
|
7734
7706
|
return (0, t.jsx)("div", {
|
|
7735
7707
|
className: n ? "".concat(W["rich-content"], " ").concat(n) : W["rich-content"],
|
|
@@ -7982,7 +7954,7 @@ function Lc(e, t, n, r) {
|
|
|
7982
7954
|
if (!(!r || !s)) return o ? s === o ? "correct" : "incorrect" : "unanswered";
|
|
7983
7955
|
}
|
|
7984
7956
|
function Rc(e, t) {
|
|
7985
|
-
return
|
|
7957
|
+
return Ge(e, t.categories, t.items);
|
|
7986
7958
|
}
|
|
7987
7959
|
function zc(_ref115) {
|
|
7988
7960
|
var e = _ref115.className,
|
|
@@ -8370,17 +8342,17 @@ function il(_ref123) {
|
|
|
8370
8342
|
}, a.optionId);
|
|
8371
8343
|
}
|
|
8372
8344
|
var Y = {
|
|
8373
|
-
"choice-button": "_choice-
|
|
8374
|
-
"table-row-button": "_table-row-
|
|
8375
|
-
"judgement-button": "_judgement-
|
|
8376
|
-
"ordering-controls": "_ordering-
|
|
8377
|
-
"ordering-button": "_ordering-
|
|
8378
|
-
"choice-option": "_choice-
|
|
8379
|
-
"table-choice-row": "_table-choice-
|
|
8380
|
-
"judgement-option": "_judgement-
|
|
8381
|
-
selected: "
|
|
8382
|
-
"option-marker": "_option-
|
|
8383
|
-
"table-option-marker": "_table-option-
|
|
8345
|
+
"choice-button": "_choice-button_3nny2_1",
|
|
8346
|
+
"table-row-button": "_table-row-button_3nny2_2",
|
|
8347
|
+
"judgement-button": "_judgement-button_3nny2_28",
|
|
8348
|
+
"ordering-controls": "_ordering-controls_3nny2_43",
|
|
8349
|
+
"ordering-button": "_ordering-button_3nny2_51",
|
|
8350
|
+
"choice-option": "_choice-option_3nny2_68",
|
|
8351
|
+
"table-choice-row": "_table-choice-row_3nny2_73",
|
|
8352
|
+
"judgement-option": "_judgement-option_3nny2_77",
|
|
8353
|
+
selected: "_selected_3nny2_81",
|
|
8354
|
+
"option-marker": "_option-marker_3nny2_86",
|
|
8355
|
+
"table-option-marker": "_table-option-marker_3nny2_87"
|
|
8384
8356
|
};
|
|
8385
8357
|
function al(_ref124) {
|
|
8386
8358
|
var e = _ref124.disabled,
|
|
@@ -8441,7 +8413,7 @@ function ol(e) {
|
|
|
8441
8413
|
kind: "detailed",
|
|
8442
8414
|
contents: ((s = e.answers[r.itemId]) == null ? [] : s).map(function (e) {
|
|
8443
8415
|
var t = n.get(e);
|
|
8444
|
-
return t &&
|
|
8416
|
+
return t && Ye(a, t.columnIndex) ? t.item : void 0;
|
|
8445
8417
|
}).filter(function (e) {
|
|
8446
8418
|
return !!e;
|
|
8447
8419
|
}).map(function (e, n) {
|
|
@@ -8554,7 +8526,7 @@ function cl(_ref126) {
|
|
|
8554
8526
|
}
|
|
8555
8527
|
function x(t, n) {
|
|
8556
8528
|
if (e) return;
|
|
8557
|
-
var r = l ?
|
|
8529
|
+
var r = l ? Xe(l, {
|
|
8558
8530
|
columnIndex: t,
|
|
8559
8531
|
itemId: n
|
|
8560
8532
|
}) : null;
|
|
@@ -8686,7 +8658,7 @@ function dl(_ref131) {
|
|
|
8686
8658
|
f = fl(r, d.connections);
|
|
8687
8659
|
function p(t, n) {
|
|
8688
8660
|
if (e) return;
|
|
8689
|
-
var r = l ?
|
|
8661
|
+
var r = l ? ct(l, {
|
|
8690
8662
|
columnIndex: t,
|
|
8691
8663
|
itemId: n
|
|
8692
8664
|
}) : null;
|
|
@@ -8799,21 +8771,100 @@ function pl(e, t) {
|
|
|
8799
8771
|
};
|
|
8800
8772
|
});
|
|
8801
8773
|
}
|
|
8802
|
-
|
|
8774
|
+
function ml(_ref134) {
|
|
8775
|
+
var e = _ref134.availableWidth,
|
|
8776
|
+
t = _ref134.columnGap,
|
|
8777
|
+
n = _ref134.optionCount,
|
|
8778
|
+
r = _ref134.widestOptionWidth;
|
|
8779
|
+
var i = Math.max(1, Math.trunc(n));
|
|
8780
|
+
if (e <= 0 || r <= 0) return 1;
|
|
8781
|
+
for (var _n5 = i; _n5 >= 2; --_n5) if (i % _n5 === 0 && (e - Math.max(0, t) * (_n5 - 1)) / _n5 >= r) return _n5;
|
|
8782
|
+
return 1;
|
|
8783
|
+
}
|
|
8784
|
+
var hl = {
|
|
8785
|
+
list: "_list_1xo1n_1"
|
|
8786
|
+
};
|
|
8787
|
+
function gl(_ref135) {
|
|
8788
|
+
var e = _ref135.children;
|
|
8789
|
+
var r = (0, n.useRef)(null),
|
|
8790
|
+
_ref136 = (0, n.useState)(1),
|
|
8791
|
+
_ref137 = _slicedToArray(_ref136, 2),
|
|
8792
|
+
i = _ref137[0],
|
|
8793
|
+
a = _ref137[1],
|
|
8794
|
+
o = {
|
|
8795
|
+
gridTemplateColumns: "repeat(".concat(i, ", minmax(0, 1fr))")
|
|
8796
|
+
};
|
|
8797
|
+
return (0, n.useLayoutEffect)(function () {
|
|
8798
|
+
if (!r.current) return;
|
|
8799
|
+
var t = r.current,
|
|
8800
|
+
i = null;
|
|
8801
|
+
function o() {
|
|
8802
|
+
var r = t.getBoundingClientRect().width,
|
|
8803
|
+
i = Number.parseFloat(getComputedStyle(t).columnGap) || 0,
|
|
8804
|
+
o = _l(t),
|
|
8805
|
+
s = ml({
|
|
8806
|
+
availableWidth: r,
|
|
8807
|
+
columnGap: i,
|
|
8808
|
+
optionCount: n.Children.count(e),
|
|
8809
|
+
widestOptionWidth: o
|
|
8810
|
+
});
|
|
8811
|
+
a(function (e) {
|
|
8812
|
+
return e === s ? e : s;
|
|
8813
|
+
});
|
|
8814
|
+
}
|
|
8815
|
+
function s() {
|
|
8816
|
+
i !== null && cancelAnimationFrame(i), i = requestAnimationFrame(o);
|
|
8817
|
+
}
|
|
8818
|
+
if (o(), t.addEventListener("load", s, !0), (typeof ResizeObserver === "undefined" ? "undefined" : _typeof(ResizeObserver)) > "u") return window.addEventListener("resize", s), function () {
|
|
8819
|
+
i !== null && cancelAnimationFrame(i), t.removeEventListener("load", s, !0), window.removeEventListener("resize", s);
|
|
8820
|
+
};
|
|
8821
|
+
var c = new ResizeObserver(s);
|
|
8822
|
+
return c.observe(t), function () {
|
|
8823
|
+
i !== null && cancelAnimationFrame(i), t.removeEventListener("load", s, !0), c.disconnect();
|
|
8824
|
+
};
|
|
8825
|
+
}), (0, t.jsx)("ol", {
|
|
8826
|
+
className: "".concat(W["option-list"], " ").concat(hl.list),
|
|
8827
|
+
"data-column-count": i,
|
|
8828
|
+
"data-question-option-grid": "true",
|
|
8829
|
+
ref: r,
|
|
8830
|
+
style: o,
|
|
8831
|
+
children: e
|
|
8832
|
+
});
|
|
8833
|
+
}
|
|
8834
|
+
function _l(e) {
|
|
8835
|
+
var t = e.parentElement;
|
|
8836
|
+
if (!t || e.children.length === 0) return 0;
|
|
8837
|
+
var n = e.cloneNode(!1);
|
|
8838
|
+
n.removeAttribute("style"), n.setAttribute("aria-hidden", "true"), n.setAttribute("data-question-option-measurement", "true"), Object.assign(n.style, {
|
|
8839
|
+
display: "grid",
|
|
8840
|
+
gridTemplateColumns: "max-content",
|
|
8841
|
+
left: "-100000px",
|
|
8842
|
+
maxWidth: "none",
|
|
8843
|
+
pointerEvents: "none",
|
|
8844
|
+
position: "fixed",
|
|
8845
|
+
visibility: "hidden",
|
|
8846
|
+
width: "max-content"
|
|
8847
|
+
}), Array.from(e.children).forEach(function (e) {
|
|
8848
|
+
n.append(e.cloneNode(!0));
|
|
8849
|
+
}), t.append(n);
|
|
8850
|
+
var r = n.getBoundingClientRect().width;
|
|
8851
|
+
return n.remove(), r;
|
|
8852
|
+
}
|
|
8853
|
+
var vl = {
|
|
8803
8854
|
"table-wrap": "_table-wrap_n67ah_1",
|
|
8804
8855
|
table: "_table_n67ah_1",
|
|
8805
8856
|
"table-option-column": "_table-option-column_n67ah_17",
|
|
8806
8857
|
"table-option-marker": "_table-option-marker_n67ah_45"
|
|
8807
8858
|
};
|
|
8808
|
-
function
|
|
8809
|
-
var e =
|
|
8810
|
-
n =
|
|
8811
|
-
r =
|
|
8812
|
-
i =
|
|
8813
|
-
a =
|
|
8814
|
-
o =
|
|
8815
|
-
s =
|
|
8816
|
-
c =
|
|
8859
|
+
function yl(_ref138) {
|
|
8860
|
+
var e = _ref138.disabled,
|
|
8861
|
+
n = _ref138.element,
|
|
8862
|
+
r = _ref138.item,
|
|
8863
|
+
i = _ref138.messages,
|
|
8864
|
+
a = _ref138.onChange,
|
|
8865
|
+
o = _ref138.response,
|
|
8866
|
+
s = _ref138.responseIndex,
|
|
8867
|
+
c = _ref138.showAnswer;
|
|
8817
8868
|
var l = Is(o, s),
|
|
8818
8869
|
u = rn(r, n.config.optionLabelStyle);
|
|
8819
8870
|
function d(e) {
|
|
@@ -8826,12 +8877,12 @@ function hl(_ref134) {
|
|
|
8826
8877
|
return (0, t.jsxs)("div", {
|
|
8827
8878
|
className: W.element,
|
|
8828
8879
|
children: [(0, t.jsx)("div", {
|
|
8829
|
-
className:
|
|
8880
|
+
className: vl["table-wrap"],
|
|
8830
8881
|
children: (0, t.jsxs)("table", {
|
|
8831
|
-
className:
|
|
8882
|
+
className: vl.table,
|
|
8832
8883
|
children: [(0, t.jsxs)("colgroup", {
|
|
8833
8884
|
children: [(0, t.jsx)("col", {
|
|
8834
|
-
className:
|
|
8885
|
+
className: vl["table-option-column"]
|
|
8835
8886
|
}), r.columns.map(function (e) {
|
|
8836
8887
|
return (0, t.jsx)("col", {}, e.id);
|
|
8837
8888
|
})]
|
|
@@ -8897,8 +8948,7 @@ function hl(_ref134) {
|
|
|
8897
8948
|
var f = pl(n, r);
|
|
8898
8949
|
return (0, t.jsxs)("div", {
|
|
8899
8950
|
className: W.element,
|
|
8900
|
-
children: [(0, t.jsx)(
|
|
8901
|
-
className: W["option-list"],
|
|
8951
|
+
children: [(0, t.jsx)(gl, {
|
|
8902
8952
|
children: u.map(function (n) {
|
|
8903
8953
|
var r = l.selectedOptionIds.includes(n.optionId);
|
|
8904
8954
|
return (0, t.jsx)("li", {
|
|
@@ -8928,7 +8978,7 @@ function hl(_ref134) {
|
|
|
8928
8978
|
}) : null]
|
|
8929
8979
|
});
|
|
8930
8980
|
}
|
|
8931
|
-
function
|
|
8981
|
+
function bl(e) {
|
|
8932
8982
|
var n = new Map(e.sortOptions.map(function (e) {
|
|
8933
8983
|
return [e.id, e];
|
|
8934
8984
|
}));
|
|
@@ -8943,14 +8993,14 @@ function gl(e) {
|
|
|
8943
8993
|
};
|
|
8944
8994
|
});
|
|
8945
8995
|
}
|
|
8946
|
-
function
|
|
8947
|
-
var e =
|
|
8948
|
-
n =
|
|
8949
|
-
r =
|
|
8950
|
-
i =
|
|
8951
|
-
a =
|
|
8952
|
-
o =
|
|
8953
|
-
s =
|
|
8996
|
+
function xl(_ref139) {
|
|
8997
|
+
var e = _ref139.disabled,
|
|
8998
|
+
n = _ref139.item,
|
|
8999
|
+
r = _ref139.messages,
|
|
9000
|
+
i = _ref139.onChange,
|
|
9001
|
+
a = _ref139.response,
|
|
9002
|
+
o = _ref139.responseIndex,
|
|
9003
|
+
s = _ref139.showAnswer;
|
|
8954
9004
|
var c = Ws(a, o, n),
|
|
8955
9005
|
l = new Map(n.sortOptions.map(function (e) {
|
|
8956
9006
|
return [e.id, e];
|
|
@@ -9002,12 +9052,12 @@ function _l(_ref135) {
|
|
|
9002
9052
|
}, n.id);
|
|
9003
9053
|
})
|
|
9004
9054
|
}), s ? (0, t.jsx)(K, {
|
|
9005
|
-
groups:
|
|
9055
|
+
groups: bl(n),
|
|
9006
9056
|
title: r.standardAnswer
|
|
9007
9057
|
}) : null]
|
|
9008
9058
|
});
|
|
9009
9059
|
}
|
|
9010
|
-
var
|
|
9060
|
+
var Sl = {
|
|
9011
9061
|
content: "_content_63948_1",
|
|
9012
9062
|
paragraph: "_paragraph_63948_10",
|
|
9013
9063
|
marker: "_marker_63948_14",
|
|
@@ -9015,17 +9065,17 @@ var vl = {
|
|
|
9015
9065
|
"marker-selected": "_marker-selected_63948_31",
|
|
9016
9066
|
"marker-answer": "_marker-answer_63948_37"
|
|
9017
9067
|
};
|
|
9018
|
-
function
|
|
9019
|
-
var
|
|
9020
|
-
e =
|
|
9021
|
-
r =
|
|
9022
|
-
|
|
9023
|
-
i =
|
|
9024
|
-
a =
|
|
9025
|
-
|
|
9026
|
-
o =
|
|
9027
|
-
|
|
9028
|
-
s =
|
|
9068
|
+
function Cl(_ref140) {
|
|
9069
|
+
var _ref140$answerMarkers = _ref140.answerMarkers,
|
|
9070
|
+
e = _ref140$answerMarkers === void 0 ? [] : _ref140$answerMarkers,
|
|
9071
|
+
r = _ref140.content,
|
|
9072
|
+
_ref140$disabled = _ref140.disabled,
|
|
9073
|
+
i = _ref140$disabled === void 0 ? !1 : _ref140$disabled,
|
|
9074
|
+
a = _ref140.onMarkerClick,
|
|
9075
|
+
_ref140$selectedMarke = _ref140.selectedMarkers,
|
|
9076
|
+
o = _ref140$selectedMarke === void 0 ? [] : _ref140$selectedMarke,
|
|
9077
|
+
_ref140$showAnswer = _ref140.showAnswer,
|
|
9078
|
+
s = _ref140$showAnswer === void 0 ? !1 : _ref140$showAnswer;
|
|
9029
9079
|
var c = r.json.length ? r.json : [{
|
|
9030
9080
|
children: [{
|
|
9031
9081
|
text: r.text
|
|
@@ -9033,26 +9083,26 @@ function yl(_ref136) {
|
|
|
9033
9083
|
type: "paragraph"
|
|
9034
9084
|
}];
|
|
9035
9085
|
return (0, t.jsx)("div", {
|
|
9036
|
-
className:
|
|
9086
|
+
className: Sl.content,
|
|
9037
9087
|
children: c.map(function (e, t) {
|
|
9038
9088
|
return l(e, "node-".concat(t));
|
|
9039
9089
|
})
|
|
9040
9090
|
});
|
|
9041
9091
|
function l(e, n) {
|
|
9042
|
-
if (
|
|
9043
|
-
if (!
|
|
9092
|
+
if (Tl(e)) return u(e, n);
|
|
9093
|
+
if (!wl(e)) return null;
|
|
9044
9094
|
var r = e.children.map(function (e, t) {
|
|
9045
9095
|
return l(e, "".concat(n, "-").concat(t));
|
|
9046
9096
|
});
|
|
9047
9097
|
return e.type === "paragraph" ? (0, t.jsx)("p", {
|
|
9048
|
-
className:
|
|
9098
|
+
className: Sl.paragraph,
|
|
9049
9099
|
children: r
|
|
9050
9100
|
}, n) : (0, t.jsx)("span", {
|
|
9051
9101
|
children: r
|
|
9052
9102
|
}, n);
|
|
9053
9103
|
}
|
|
9054
9104
|
function u(e, r) {
|
|
9055
|
-
var i =
|
|
9105
|
+
var i = xt(e);
|
|
9056
9106
|
if (!i) return (0, t.jsx)(n.Fragment, {
|
|
9057
9107
|
children: e.text
|
|
9058
9108
|
}, r);
|
|
@@ -9064,7 +9114,7 @@ function yl(_ref136) {
|
|
|
9064
9114
|
r = s && e.includes(t);
|
|
9065
9115
|
return {
|
|
9066
9116
|
answer: r,
|
|
9067
|
-
className: Ba(
|
|
9117
|
+
className: Ba(Sl.marker, a ? Sl["marker-button"] : "", n ? Sl["marker-selected"] : "", r ? Sl["marker-answer"] : ""),
|
|
9068
9118
|
selected: n
|
|
9069
9119
|
};
|
|
9070
9120
|
}
|
|
@@ -9092,23 +9142,23 @@ function yl(_ref136) {
|
|
|
9092
9142
|
}, r);
|
|
9093
9143
|
}
|
|
9094
9144
|
}
|
|
9095
|
-
function
|
|
9145
|
+
function wl(e) {
|
|
9096
9146
|
return !!(e && _typeof(e) == "object" && "children" in e && Array.isArray(e.children));
|
|
9097
9147
|
}
|
|
9098
|
-
function
|
|
9148
|
+
function Tl(e) {
|
|
9099
9149
|
return !!(e && _typeof(e) == "object" && "text" in e && _typeof(e.text) == "string");
|
|
9100
9150
|
}
|
|
9101
|
-
function
|
|
9102
|
-
var e =
|
|
9103
|
-
n =
|
|
9104
|
-
r =
|
|
9105
|
-
var i =
|
|
9151
|
+
function El(_ref141) {
|
|
9152
|
+
var e = _ref141.item,
|
|
9153
|
+
n = _ref141.messages,
|
|
9154
|
+
r = _ref141.showAnswer;
|
|
9155
|
+
var i = yt(e.content.json).filter(function (t) {
|
|
9106
9156
|
return e.answers.includes(t.markerId);
|
|
9107
9157
|
}).map(function (e) {
|
|
9108
9158
|
return e.text;
|
|
9109
9159
|
});
|
|
9110
9160
|
return (0, t.jsxs)(t.Fragment, {
|
|
9111
|
-
children: [(0, t.jsx)(
|
|
9161
|
+
children: [(0, t.jsx)(Cl, {
|
|
9112
9162
|
answerMarkers: e.answers,
|
|
9113
9163
|
content: e.content,
|
|
9114
9164
|
showAnswer: r
|
|
@@ -9122,20 +9172,20 @@ function Sl(_ref137) {
|
|
|
9122
9172
|
}) : null]
|
|
9123
9173
|
});
|
|
9124
9174
|
}
|
|
9125
|
-
function
|
|
9126
|
-
var e =
|
|
9127
|
-
n =
|
|
9128
|
-
r =
|
|
9129
|
-
i =
|
|
9130
|
-
a =
|
|
9131
|
-
o =
|
|
9132
|
-
s =
|
|
9175
|
+
function Dl(_ref142) {
|
|
9176
|
+
var e = _ref142.disabled,
|
|
9177
|
+
n = _ref142.item,
|
|
9178
|
+
r = _ref142.messages,
|
|
9179
|
+
i = _ref142.onChange,
|
|
9180
|
+
a = _ref142.response,
|
|
9181
|
+
o = _ref142.responseIndex,
|
|
9182
|
+
s = _ref142.showAnswer;
|
|
9133
9183
|
var c = Gs(a, o);
|
|
9134
|
-
return s ? (0, t.jsx)(
|
|
9184
|
+
return s ? (0, t.jsx)(El, {
|
|
9135
9185
|
item: n,
|
|
9136
9186
|
messages: r,
|
|
9137
9187
|
showAnswer: s
|
|
9138
|
-
}) : (0, t.jsx)(
|
|
9188
|
+
}) : (0, t.jsx)(Cl, {
|
|
9139
9189
|
answerMarkers: n.answers,
|
|
9140
9190
|
content: n.content,
|
|
9141
9191
|
disabled: e,
|
|
@@ -9147,28 +9197,28 @@ function Cl(_ref138) {
|
|
|
9147
9197
|
selectedMarkers: c.selectedMarkers
|
|
9148
9198
|
});
|
|
9149
9199
|
}
|
|
9150
|
-
var
|
|
9200
|
+
var Ol = {
|
|
9151
9201
|
placeholder: "_placeholder_xde95_1"
|
|
9152
9202
|
};
|
|
9153
|
-
function
|
|
9154
|
-
var e =
|
|
9203
|
+
function kl(_ref143) {
|
|
9204
|
+
var e = _ref143.label;
|
|
9155
9205
|
return (0, t.jsx)("div", {
|
|
9156
9206
|
"aria-label": e,
|
|
9157
|
-
className:
|
|
9207
|
+
className: Ol.placeholder,
|
|
9158
9208
|
children: e
|
|
9159
9209
|
});
|
|
9160
9210
|
}
|
|
9161
|
-
function
|
|
9162
|
-
var e =
|
|
9163
|
-
n =
|
|
9164
|
-
r =
|
|
9165
|
-
i =
|
|
9166
|
-
a =
|
|
9167
|
-
o =
|
|
9168
|
-
s =
|
|
9169
|
-
c =
|
|
9211
|
+
function Al(_ref144) {
|
|
9212
|
+
var e = _ref144.disabled,
|
|
9213
|
+
n = _ref144.locale,
|
|
9214
|
+
r = _ref144.label,
|
|
9215
|
+
i = _ref144.messages,
|
|
9216
|
+
a = _ref144.onChange,
|
|
9217
|
+
o = _ref144.response,
|
|
9218
|
+
s = _ref144.responseIndex,
|
|
9219
|
+
c = _ref144.uploadImage;
|
|
9170
9220
|
var l = Ks(o, s);
|
|
9171
|
-
return e ? A(l.content) ? (0, t.jsx)(
|
|
9221
|
+
return e ? A(l.content) ? (0, t.jsx)(kl, {
|
|
9172
9222
|
label: i.textResponsePlaceholder
|
|
9173
9223
|
}) : (0, t.jsx)(G, {
|
|
9174
9224
|
content: l.content
|
|
@@ -9187,7 +9237,7 @@ function El(_ref140) {
|
|
|
9187
9237
|
value: l.content
|
|
9188
9238
|
});
|
|
9189
9239
|
}
|
|
9190
|
-
function
|
|
9240
|
+
function jl(e, n) {
|
|
9191
9241
|
return e.blanks.reduce(function (r, i) {
|
|
9192
9242
|
var a;
|
|
9193
9243
|
var o = (a = e.answers[i]) == null ? void 0 : a.trim();
|
|
@@ -9200,22 +9250,22 @@ function Dl(e, n) {
|
|
|
9200
9250
|
}]) : r;
|
|
9201
9251
|
}, []);
|
|
9202
9252
|
}
|
|
9203
|
-
var
|
|
9253
|
+
var Ml = {
|
|
9204
9254
|
"word-builder-blank": "_word-builder-blank_ftw6q_1",
|
|
9205
9255
|
"word-builder-candidate-list": "_word-builder-candidate-list_ftw6q_30"
|
|
9206
9256
|
};
|
|
9207
|
-
function
|
|
9208
|
-
var e =
|
|
9209
|
-
n =
|
|
9210
|
-
r =
|
|
9211
|
-
i =
|
|
9212
|
-
a =
|
|
9213
|
-
o =
|
|
9214
|
-
s =
|
|
9215
|
-
c =
|
|
9257
|
+
function Nl(_ref145) {
|
|
9258
|
+
var e = _ref145.disabled,
|
|
9259
|
+
n = _ref145.element,
|
|
9260
|
+
r = _ref145.item,
|
|
9261
|
+
i = _ref145.messages,
|
|
9262
|
+
a = _ref145.onChange,
|
|
9263
|
+
o = _ref145.response,
|
|
9264
|
+
s = _ref145.responseIndex,
|
|
9265
|
+
c = _ref145.showAnswer;
|
|
9216
9266
|
var l = _n(r, !0, n),
|
|
9217
9267
|
u = zs(o, s, l.blanks),
|
|
9218
|
-
d =
|
|
9268
|
+
d = jl(l, i.blankLabel);
|
|
9219
9269
|
function f(e, t) {
|
|
9220
9270
|
a(C(C({}, u), {}, {
|
|
9221
9271
|
answers: C(C({}, u.answers), {}, _defineProperty({}, e, t))
|
|
@@ -9246,13 +9296,13 @@ function kl(_ref141) {
|
|
|
9246
9296
|
className: U["fill-text"],
|
|
9247
9297
|
children: [(0, t.jsx)(zc, {
|
|
9248
9298
|
content: l.content,
|
|
9249
|
-
renderBlank: function renderBlank(
|
|
9250
|
-
var n =
|
|
9251
|
-
r =
|
|
9252
|
-
a =
|
|
9299
|
+
renderBlank: function renderBlank(_ref146) {
|
|
9300
|
+
var n = _ref146.blankId,
|
|
9301
|
+
r = _ref146.index,
|
|
9302
|
+
a = _ref146.label;
|
|
9253
9303
|
var o, s;
|
|
9254
9304
|
var c = (o = u.answers[n]) == null ? "" : o,
|
|
9255
|
-
l =
|
|
9305
|
+
l = Pl({
|
|
9256
9306
|
answers: c,
|
|
9257
9307
|
blankLabel: i.blankLabel,
|
|
9258
9308
|
canClear: !e && !!c.trim(),
|
|
@@ -9261,7 +9311,7 @@ function kl(_ref141) {
|
|
|
9261
9311
|
});
|
|
9262
9312
|
return (0, t.jsx)("button", {
|
|
9263
9313
|
"aria-label": l,
|
|
9264
|
-
className:
|
|
9314
|
+
className: Ml["word-builder-blank"],
|
|
9265
9315
|
disabled: e,
|
|
9266
9316
|
onClick: function onClick() {
|
|
9267
9317
|
return p(n);
|
|
@@ -9278,7 +9328,7 @@ function kl(_ref141) {
|
|
|
9278
9328
|
});
|
|
9279
9329
|
}
|
|
9280
9330
|
}), (0, t.jsx)("div", {
|
|
9281
|
-
className:
|
|
9331
|
+
className: Ml["word-builder-candidate-list"],
|
|
9282
9332
|
children: l.candidateOptions.map(function (n, r) {
|
|
9283
9333
|
return (0, t.jsx)("button", {
|
|
9284
9334
|
disabled: e,
|
|
@@ -9299,30 +9349,30 @@ function kl(_ref141) {
|
|
|
9299
9349
|
}) : null]
|
|
9300
9350
|
});
|
|
9301
9351
|
}
|
|
9302
|
-
function
|
|
9303
|
-
var e =
|
|
9304
|
-
t =
|
|
9305
|
-
n =
|
|
9306
|
-
r =
|
|
9307
|
-
i =
|
|
9352
|
+
function Pl(_ref147) {
|
|
9353
|
+
var e = _ref147.answers,
|
|
9354
|
+
t = _ref147.blankLabel,
|
|
9355
|
+
n = _ref147.canClear,
|
|
9356
|
+
r = _ref147.index,
|
|
9357
|
+
i = _ref147.label;
|
|
9308
9358
|
var a = i || "".concat(t).concat(r + 1);
|
|
9309
9359
|
return !n || !e.trim() ? a : t === "\u7A7A" ? "".concat(a, "\uFF0C\u70B9\u51FB\u6E05\u7A7A") : "".concat(a, ", click to clear");
|
|
9310
9360
|
}
|
|
9311
|
-
function
|
|
9312
|
-
var e =
|
|
9313
|
-
n =
|
|
9314
|
-
r =
|
|
9315
|
-
i =
|
|
9316
|
-
a =
|
|
9317
|
-
o =
|
|
9318
|
-
s =
|
|
9319
|
-
c =
|
|
9320
|
-
l =
|
|
9321
|
-
u =
|
|
9361
|
+
function Fl(_ref148) {
|
|
9362
|
+
var e = _ref148.disabled,
|
|
9363
|
+
n = _ref148.element,
|
|
9364
|
+
r = _ref148.item,
|
|
9365
|
+
i = _ref148.locale,
|
|
9366
|
+
a = _ref148.messages,
|
|
9367
|
+
o = _ref148.onResponseItemChange,
|
|
9368
|
+
s = _ref148.response,
|
|
9369
|
+
c = _ref148.responseIndex,
|
|
9370
|
+
l = _ref148.showAnswer,
|
|
9371
|
+
u = _ref148.uploadImage;
|
|
9322
9372
|
if (n.type !== r.type) throw Error("\u9898\u76EE\u5143\u7D20\u7ED3\u6784\u4E0D\u5339\u914D\uFF0Cexpected=".concat(n.type, "\uFF0Cactual=").concat(r.type));
|
|
9323
9373
|
return n.type === "richText" ? (0, t.jsx)(G, {
|
|
9324
9374
|
content: r.content
|
|
9325
|
-
}) : n.type === "textResponse" ? (0, t.jsx)(
|
|
9375
|
+
}) : n.type === "textResponse" ? (0, t.jsx)(Al, {
|
|
9326
9376
|
disabled: e,
|
|
9327
9377
|
label: n.name,
|
|
9328
9378
|
locale: i,
|
|
@@ -9331,7 +9381,7 @@ function jl(_ref144) {
|
|
|
9331
9381
|
response: s,
|
|
9332
9382
|
responseIndex: c,
|
|
9333
9383
|
uploadImage: u
|
|
9334
|
-
}) : n.type === "ordering" ? (0, t.jsx)(
|
|
9384
|
+
}) : n.type === "ordering" ? (0, t.jsx)(xl, {
|
|
9335
9385
|
disabled: e,
|
|
9336
9386
|
item: r,
|
|
9337
9387
|
messages: a,
|
|
@@ -9347,7 +9397,7 @@ function jl(_ref144) {
|
|
|
9347
9397
|
response: s,
|
|
9348
9398
|
responseIndex: c,
|
|
9349
9399
|
showAnswer: l
|
|
9350
|
-
}) : n.type === "textMarker" ? (0, t.jsx)(
|
|
9400
|
+
}) : n.type === "textMarker" ? (0, t.jsx)(Dl, {
|
|
9351
9401
|
disabled: e,
|
|
9352
9402
|
item: r,
|
|
9353
9403
|
messages: a,
|
|
@@ -9355,7 +9405,7 @@ function jl(_ref144) {
|
|
|
9355
9405
|
response: s,
|
|
9356
9406
|
responseIndex: c,
|
|
9357
9407
|
showAnswer: l
|
|
9358
|
-
}) :
|
|
9408
|
+
}) : Il({
|
|
9359
9409
|
disabled: e,
|
|
9360
9410
|
element: n,
|
|
9361
9411
|
item: r,
|
|
@@ -9368,18 +9418,18 @@ function jl(_ref144) {
|
|
|
9368
9418
|
uploadImage: u
|
|
9369
9419
|
});
|
|
9370
9420
|
}
|
|
9371
|
-
function
|
|
9372
|
-
var e =
|
|
9373
|
-
n =
|
|
9374
|
-
r =
|
|
9375
|
-
i =
|
|
9376
|
-
a =
|
|
9377
|
-
o =
|
|
9378
|
-
s =
|
|
9379
|
-
c =
|
|
9421
|
+
function Il(_ref149) {
|
|
9422
|
+
var e = _ref149.disabled,
|
|
9423
|
+
n = _ref149.element,
|
|
9424
|
+
r = _ref149.item,
|
|
9425
|
+
i = _ref149.messages,
|
|
9426
|
+
a = _ref149.onResponseItemChange,
|
|
9427
|
+
o = _ref149.response,
|
|
9428
|
+
s = _ref149.responseIndex,
|
|
9429
|
+
c = _ref149.showAnswer;
|
|
9380
9430
|
switch (n.type) {
|
|
9381
9431
|
case "choice":
|
|
9382
|
-
return (0, t.jsx)(
|
|
9432
|
+
return (0, t.jsx)(yl, {
|
|
9383
9433
|
disabled: e,
|
|
9384
9434
|
element: n,
|
|
9385
9435
|
item: r,
|
|
@@ -9411,7 +9461,7 @@ function Ml(_ref145) {
|
|
|
9411
9461
|
showAnswer: c
|
|
9412
9462
|
});
|
|
9413
9463
|
case "wordBuilder":
|
|
9414
|
-
return (0, t.jsx)(
|
|
9464
|
+
return (0, t.jsx)(Nl, {
|
|
9415
9465
|
disabled: e,
|
|
9416
9466
|
element: n,
|
|
9417
9467
|
item: r,
|
|
@@ -9454,14 +9504,14 @@ function Ml(_ref145) {
|
|
|
9454
9504
|
});
|
|
9455
9505
|
}
|
|
9456
9506
|
}
|
|
9457
|
-
var
|
|
9458
|
-
function
|
|
9507
|
+
var Ll = ["locale"];
|
|
9508
|
+
function Rl(e) {
|
|
9459
9509
|
var _e$locale = e.locale,
|
|
9460
9510
|
n = _e$locale === void 0 ? "zh-CN" : _e$locale,
|
|
9461
|
-
r = ma(e,
|
|
9511
|
+
r = ma(e, Ll),
|
|
9462
9512
|
i = us(r.value, r.questionTypeTemplates),
|
|
9463
9513
|
a = hs(r.response, i);
|
|
9464
|
-
return (0, t.jsx)(
|
|
9514
|
+
return (0, t.jsx)(zl, C(C({}, r), {}, {
|
|
9465
9515
|
childIndexPath: [],
|
|
9466
9516
|
locale: n,
|
|
9467
9517
|
messages: yc(n),
|
|
@@ -9472,24 +9522,24 @@ function Pl(e) {
|
|
|
9472
9522
|
value: i
|
|
9473
9523
|
}));
|
|
9474
9524
|
}
|
|
9475
|
-
function
|
|
9476
|
-
var e =
|
|
9477
|
-
n =
|
|
9478
|
-
|
|
9479
|
-
r =
|
|
9480
|
-
|
|
9481
|
-
i =
|
|
9482
|
-
a =
|
|
9483
|
-
o =
|
|
9484
|
-
s =
|
|
9485
|
-
c =
|
|
9486
|
-
|
|
9487
|
-
l =
|
|
9488
|
-
|
|
9489
|
-
u =
|
|
9490
|
-
d =
|
|
9491
|
-
f =
|
|
9492
|
-
p =
|
|
9525
|
+
function zl(_ref150) {
|
|
9526
|
+
var e = _ref150.childIndexPath,
|
|
9527
|
+
n = _ref150.className,
|
|
9528
|
+
_ref150$disabled = _ref150.disabled,
|
|
9529
|
+
r = _ref150$disabled === void 0 ? !1 : _ref150$disabled,
|
|
9530
|
+
_ref150$locale = _ref150.locale,
|
|
9531
|
+
i = _ref150$locale === void 0 ? "zh-CN" : _ref150$locale,
|
|
9532
|
+
a = _ref150.messages,
|
|
9533
|
+
o = _ref150.onResponseChange,
|
|
9534
|
+
s = _ref150.response,
|
|
9535
|
+
c = _ref150.rootQuestionNumber,
|
|
9536
|
+
_ref150$showAnswer = _ref150.showAnswer,
|
|
9537
|
+
l = _ref150$showAnswer === void 0 ? !1 : _ref150$showAnswer,
|
|
9538
|
+
_ref150$showExtraAttr = _ref150.showExtraAttributes,
|
|
9539
|
+
u = _ref150$showExtraAttr === void 0 ? !1 : _ref150$showExtraAttr,
|
|
9540
|
+
d = _ref150.questionTypeTemplates,
|
|
9541
|
+
f = _ref150.uploadImage,
|
|
9542
|
+
p = _ref150.value;
|
|
9493
9543
|
var m = Zi(d, p);
|
|
9494
9544
|
if (!m) return (0, t.jsx)("div", {
|
|
9495
9545
|
className: H(U.root, n),
|
|
@@ -9498,7 +9548,7 @@ function Fl(_ref146) {
|
|
|
9498
9548
|
children: a.missingQuestionTypeTemplate
|
|
9499
9549
|
})
|
|
9500
9550
|
});
|
|
9501
|
-
var h =
|
|
9551
|
+
var h = Bl({
|
|
9502
9552
|
childIndexPath: e,
|
|
9503
9553
|
disabled: r,
|
|
9504
9554
|
locale: i,
|
|
@@ -9515,27 +9565,27 @@ function Fl(_ref146) {
|
|
|
9515
9565
|
});
|
|
9516
9566
|
return (0, t.jsx)("div", {
|
|
9517
9567
|
className: H(U.root, n),
|
|
9518
|
-
children:
|
|
9568
|
+
children: Wl(m, p) ? (0, t.jsx)("div", {
|
|
9519
9569
|
className: U.empty,
|
|
9520
9570
|
children: a.previewEmpty
|
|
9521
9571
|
}) : h
|
|
9522
9572
|
});
|
|
9523
9573
|
}
|
|
9524
|
-
function
|
|
9574
|
+
function Bl(e) {
|
|
9525
9575
|
return (0, t.jsxs)(t.Fragment, {
|
|
9526
|
-
children: [
|
|
9527
|
-
});
|
|
9528
|
-
}
|
|
9529
|
-
function
|
|
9530
|
-
var e =
|
|
9531
|
-
n =
|
|
9532
|
-
r =
|
|
9533
|
-
i =
|
|
9534
|
-
a =
|
|
9535
|
-
o =
|
|
9536
|
-
s =
|
|
9537
|
-
c =
|
|
9538
|
-
l =
|
|
9576
|
+
children: [Vl(e), Ul(e), Hl(e)]
|
|
9577
|
+
});
|
|
9578
|
+
}
|
|
9579
|
+
function Vl(_ref151) {
|
|
9580
|
+
var e = _ref151.disabled,
|
|
9581
|
+
n = _ref151.locale,
|
|
9582
|
+
r = _ref151.messages,
|
|
9583
|
+
i = _ref151.onResponseChange,
|
|
9584
|
+
a = _ref151.response,
|
|
9585
|
+
o = _ref151.showAnswer,
|
|
9586
|
+
s = _ref151.structure,
|
|
9587
|
+
c = _ref151.uploadImage,
|
|
9588
|
+
l = _ref151.value;
|
|
9539
9589
|
return s.elements.length === 0 ? null : (0, t.jsx)("div", {
|
|
9540
9590
|
className: U["element-list"],
|
|
9541
9591
|
children: s.elements.map(function (u, d) {
|
|
@@ -9545,7 +9595,7 @@ function Ll(_ref147) {
|
|
|
9545
9595
|
}).length;
|
|
9546
9596
|
return (0, t.jsx)("section", {
|
|
9547
9597
|
className: U.element,
|
|
9548
|
-
children: (0, t.jsx)(
|
|
9598
|
+
children: (0, t.jsx)(Fl, {
|
|
9549
9599
|
disabled: e,
|
|
9550
9600
|
element: u,
|
|
9551
9601
|
item: f,
|
|
@@ -9563,15 +9613,15 @@ function Ll(_ref147) {
|
|
|
9563
9613
|
})
|
|
9564
9614
|
});
|
|
9565
9615
|
}
|
|
9566
|
-
function
|
|
9567
|
-
var e =
|
|
9568
|
-
n =
|
|
9569
|
-
r =
|
|
9570
|
-
i =
|
|
9571
|
-
a =
|
|
9572
|
-
o =
|
|
9573
|
-
s =
|
|
9574
|
-
c =
|
|
9616
|
+
function Hl(_ref152) {
|
|
9617
|
+
var e = _ref152.disabled,
|
|
9618
|
+
n = _ref152.locale,
|
|
9619
|
+
r = _ref152.messages,
|
|
9620
|
+
i = _ref152.response,
|
|
9621
|
+
a = _ref152.showExtraAttributes,
|
|
9622
|
+
o = _ref152.structure,
|
|
9623
|
+
s = _ref152.uploadImage,
|
|
9624
|
+
c = _ref152.value;
|
|
9575
9625
|
return a ? (0, t.jsx)("div", {
|
|
9576
9626
|
className: U["element-list"],
|
|
9577
9627
|
children: o.extras.map(function (a, o) {
|
|
@@ -9580,10 +9630,10 @@ function Rl(_ref148) {
|
|
|
9580
9630
|
className: U.extra,
|
|
9581
9631
|
children: [(0, t.jsx)(kc, {
|
|
9582
9632
|
children: a.name
|
|
9583
|
-
}), (0, t.jsx)(
|
|
9633
|
+
}), (0, t.jsx)(Fl, {
|
|
9584
9634
|
disabled: e,
|
|
9585
|
-
element:
|
|
9586
|
-
item:
|
|
9635
|
+
element: Gl(a),
|
|
9636
|
+
item: Kl(l),
|
|
9587
9637
|
locale: n,
|
|
9588
9638
|
messages: r,
|
|
9589
9639
|
onResponseItemChange: function onResponseItemChange() {
|
|
@@ -9598,19 +9648,19 @@ function Rl(_ref148) {
|
|
|
9598
9648
|
})
|
|
9599
9649
|
}) : null;
|
|
9600
9650
|
}
|
|
9601
|
-
function
|
|
9602
|
-
var e =
|
|
9603
|
-
n =
|
|
9604
|
-
r =
|
|
9605
|
-
i =
|
|
9606
|
-
a =
|
|
9607
|
-
o =
|
|
9608
|
-
s =
|
|
9609
|
-
c =
|
|
9610
|
-
l =
|
|
9611
|
-
u =
|
|
9612
|
-
d =
|
|
9613
|
-
f =
|
|
9651
|
+
function Ul(_ref153) {
|
|
9652
|
+
var e = _ref153.childIndexPath,
|
|
9653
|
+
n = _ref153.disabled,
|
|
9654
|
+
r = _ref153.locale,
|
|
9655
|
+
i = _ref153.messages,
|
|
9656
|
+
a = _ref153.onResponseChange,
|
|
9657
|
+
o = _ref153.response,
|
|
9658
|
+
s = _ref153.rootQuestionNumber,
|
|
9659
|
+
c = _ref153.showAnswer,
|
|
9660
|
+
l = _ref153.showExtraAttributes,
|
|
9661
|
+
u = _ref153.questionTypeTemplates,
|
|
9662
|
+
d = _ref153.uploadImage,
|
|
9663
|
+
f = _ref153.value;
|
|
9614
9664
|
return f.children.length === 0 ? null : (0, t.jsx)(Ac, {
|
|
9615
9665
|
childIndexPath: e,
|
|
9616
9666
|
disabled: n,
|
|
@@ -9620,7 +9670,7 @@ function zl(_ref149) {
|
|
|
9620
9670
|
},
|
|
9621
9671
|
response: o,
|
|
9622
9672
|
renderChild: function renderChild(e, a, o, f) {
|
|
9623
|
-
return (0, t.jsx)(
|
|
9673
|
+
return (0, t.jsx)(zl, {
|
|
9624
9674
|
childIndexPath: f,
|
|
9625
9675
|
disabled: n,
|
|
9626
9676
|
locale: r,
|
|
@@ -9639,31 +9689,31 @@ function zl(_ref149) {
|
|
|
9639
9689
|
value: f
|
|
9640
9690
|
});
|
|
9641
9691
|
}
|
|
9642
|
-
function
|
|
9692
|
+
function Wl(e, t) {
|
|
9643
9693
|
return t.elements.length === 0 && t.extras.length === 0 && t.children.length === 0;
|
|
9644
9694
|
}
|
|
9645
|
-
function
|
|
9695
|
+
function Gl(e) {
|
|
9646
9696
|
return {
|
|
9647
9697
|
config: {},
|
|
9648
9698
|
name: e.name,
|
|
9649
9699
|
type: "richText"
|
|
9650
9700
|
};
|
|
9651
9701
|
}
|
|
9652
|
-
function
|
|
9702
|
+
function Kl(e) {
|
|
9653
9703
|
return {
|
|
9654
9704
|
content: e.content,
|
|
9655
9705
|
type: "richText"
|
|
9656
9706
|
};
|
|
9657
9707
|
}
|
|
9658
|
-
var
|
|
9708
|
+
var ql = {
|
|
9659
9709
|
"blank-list": "_blank-list_12ccp_1",
|
|
9660
9710
|
"blank-item": "_blank-item_12ccp_11",
|
|
9661
9711
|
"blank-field": "_blank-field_12ccp_17"
|
|
9662
9712
|
};
|
|
9663
|
-
function
|
|
9664
|
-
var e =
|
|
9665
|
-
n =
|
|
9666
|
-
r =
|
|
9713
|
+
function Jl(_ref154) {
|
|
9714
|
+
var e = _ref154.item,
|
|
9715
|
+
n = _ref154.messages,
|
|
9716
|
+
r = _ref154.showAnswer;
|
|
9667
9717
|
var i = k(e.answers, e.blanks).map(function (r, i) {
|
|
9668
9718
|
return {
|
|
9669
9719
|
kind: "detailed",
|
|
@@ -9678,15 +9728,15 @@ function Wl(_ref150) {
|
|
|
9678
9728
|
return (0, t.jsxs)("div", {
|
|
9679
9729
|
className: W.element,
|
|
9680
9730
|
children: [(0, t.jsx)("ol", {
|
|
9681
|
-
className:
|
|
9731
|
+
className: ql["blank-list"],
|
|
9682
9732
|
children: e.blanks.map(function (e, r) {
|
|
9683
9733
|
return (0, t.jsx)("li", {
|
|
9684
|
-
className:
|
|
9734
|
+
className: ql["blank-item"],
|
|
9685
9735
|
children: (0, t.jsxs)("span", {
|
|
9686
|
-
className:
|
|
9736
|
+
className: ql["blank-field"],
|
|
9687
9737
|
children: [n.blankLabel, " ", r + 1]
|
|
9688
9738
|
})
|
|
9689
|
-
},
|
|
9739
|
+
}, Yl(e, r));
|
|
9690
9740
|
})
|
|
9691
9741
|
}), r ? (0, t.jsx)(K, {
|
|
9692
9742
|
groups: i,
|
|
@@ -9694,13 +9744,13 @@ function Wl(_ref150) {
|
|
|
9694
9744
|
}) : null]
|
|
9695
9745
|
});
|
|
9696
9746
|
}
|
|
9697
|
-
function
|
|
9747
|
+
function Yl(e, t) {
|
|
9698
9748
|
return e || "blank-".concat(t + 1);
|
|
9699
9749
|
}
|
|
9700
|
-
function
|
|
9701
|
-
var e =
|
|
9702
|
-
n =
|
|
9703
|
-
r =
|
|
9750
|
+
function Xl(_ref155) {
|
|
9751
|
+
var e = _ref155.item,
|
|
9752
|
+
n = _ref155.messages,
|
|
9753
|
+
r = _ref155.showAnswer;
|
|
9704
9754
|
return (0, t.jsxs)("div", {
|
|
9705
9755
|
className: W.element,
|
|
9706
9756
|
children: [(0, t.jsxs)("div", {
|
|
@@ -9738,11 +9788,11 @@ function Kl(_ref151) {
|
|
|
9738
9788
|
}) : null]
|
|
9739
9789
|
});
|
|
9740
9790
|
}
|
|
9741
|
-
function
|
|
9742
|
-
var e =
|
|
9743
|
-
n =
|
|
9744
|
-
r =
|
|
9745
|
-
i =
|
|
9791
|
+
function Zl(_ref156) {
|
|
9792
|
+
var e = _ref156.element,
|
|
9793
|
+
n = _ref156.item,
|
|
9794
|
+
r = _ref156.messages,
|
|
9795
|
+
i = _ref156.showAnswer;
|
|
9746
9796
|
var a = vn(n, e, !0),
|
|
9747
9797
|
o = Ec(a).map(function (e, n) {
|
|
9748
9798
|
return {
|
|
@@ -9759,13 +9809,13 @@ function ql(_ref152) {
|
|
|
9759
9809
|
className: W.element,
|
|
9760
9810
|
children: [(0, t.jsx)(G, {
|
|
9761
9811
|
content: a.content
|
|
9762
|
-
}),
|
|
9812
|
+
}), Ql(a, r.candidateOptions), i ? (0, t.jsx)(K, {
|
|
9763
9813
|
groups: o,
|
|
9764
9814
|
title: r.standardAnswer
|
|
9765
9815
|
}) : null]
|
|
9766
9816
|
});
|
|
9767
9817
|
}
|
|
9768
|
-
function
|
|
9818
|
+
function Ql(e, n) {
|
|
9769
9819
|
var r, i;
|
|
9770
9820
|
var a = (r = e.candidateOptions) == null ? [] : r,
|
|
9771
9821
|
o = (i = e.blankOptionGroups) == null ? [] : i;
|
|
@@ -9796,11 +9846,11 @@ function Jl(e, n) {
|
|
|
9796
9846
|
})]
|
|
9797
9847
|
});
|
|
9798
9848
|
}
|
|
9799
|
-
function
|
|
9800
|
-
var e =
|
|
9801
|
-
n =
|
|
9802
|
-
r =
|
|
9803
|
-
i =
|
|
9849
|
+
function $l(_ref157) {
|
|
9850
|
+
var e = _ref157.element,
|
|
9851
|
+
n = _ref157.item,
|
|
9852
|
+
r = _ref157.messages,
|
|
9853
|
+
i = _ref157.showAnswer;
|
|
9804
9854
|
var a = tn(e.config.judgeAnswerMode),
|
|
9805
9855
|
o = [{
|
|
9806
9856
|
kind: "detailed",
|
|
@@ -9811,9 +9861,9 @@ function Yl(_ref153) {
|
|
|
9811
9861
|
className: W.element,
|
|
9812
9862
|
children: [(0, t.jsx)("ol", {
|
|
9813
9863
|
className: W["judgement-list"],
|
|
9814
|
-
children: a.map(function (
|
|
9815
|
-
var e =
|
|
9816
|
-
n =
|
|
9864
|
+
children: a.map(function (_ref158) {
|
|
9865
|
+
var e = _ref158.label,
|
|
9866
|
+
n = _ref158.value;
|
|
9817
9867
|
return (0, t.jsx)("li", {
|
|
9818
9868
|
className: W["judgement-item"],
|
|
9819
9869
|
children: e
|
|
@@ -9825,10 +9875,10 @@ function Yl(_ref153) {
|
|
|
9825
9875
|
}) : null]
|
|
9826
9876
|
});
|
|
9827
9877
|
}
|
|
9828
|
-
function
|
|
9829
|
-
var e =
|
|
9830
|
-
n =
|
|
9831
|
-
r =
|
|
9878
|
+
function eu(_ref159) {
|
|
9879
|
+
var e = _ref159.item,
|
|
9880
|
+
n = _ref159.messages,
|
|
9881
|
+
r = _ref159.showAnswer;
|
|
9832
9882
|
var i = {
|
|
9833
9883
|
gridTemplateColumns: "repeat(".concat(e.columns.length, ", minmax(12rem, 1fr))")
|
|
9834
9884
|
};
|
|
@@ -9866,32 +9916,32 @@ function Xl(_ref155) {
|
|
|
9866
9916
|
}) : null]
|
|
9867
9917
|
});
|
|
9868
9918
|
}
|
|
9869
|
-
var
|
|
9919
|
+
var tu = {
|
|
9870
9920
|
board: "_board_5xarh_1",
|
|
9871
9921
|
columns: "_columns_5xarh_6",
|
|
9872
9922
|
column: "_column_5xarh_6",
|
|
9873
9923
|
item: "_item_5xarh_18",
|
|
9874
9924
|
marker: "_marker_5xarh_42"
|
|
9875
9925
|
};
|
|
9876
|
-
function
|
|
9877
|
-
var e =
|
|
9878
|
-
n =
|
|
9879
|
-
r =
|
|
9926
|
+
function nu(_ref160) {
|
|
9927
|
+
var e = _ref160.item,
|
|
9928
|
+
n = _ref160.messages,
|
|
9929
|
+
r = _ref160.showAnswer;
|
|
9880
9930
|
return (0, t.jsxs)("div", {
|
|
9881
9931
|
className: W.element,
|
|
9882
9932
|
children: [(0, t.jsx)("div", {
|
|
9883
|
-
className:
|
|
9933
|
+
className: tu.board,
|
|
9884
9934
|
children: (0, t.jsx)("div", {
|
|
9885
|
-
className:
|
|
9935
|
+
className: tu.columns,
|
|
9886
9936
|
children: e.columns.map(function (e) {
|
|
9887
9937
|
return (0, t.jsx)("section", {
|
|
9888
|
-
className:
|
|
9938
|
+
className: tu.column,
|
|
9889
9939
|
children: e.items.map(function (n, r) {
|
|
9890
9940
|
var i = $t(e.labelStyle, r);
|
|
9891
9941
|
return (0, t.jsxs)("div", {
|
|
9892
|
-
className:
|
|
9942
|
+
className: tu.item,
|
|
9893
9943
|
children: [i ? (0, t.jsx)("span", {
|
|
9894
|
-
className:
|
|
9944
|
+
className: tu.marker,
|
|
9895
9945
|
children: i
|
|
9896
9946
|
}) : null, (0, t.jsx)(G, {
|
|
9897
9947
|
content: n.content
|
|
@@ -9907,23 +9957,23 @@ function Ql(_ref156) {
|
|
|
9907
9957
|
}) : null]
|
|
9908
9958
|
});
|
|
9909
9959
|
}
|
|
9910
|
-
function
|
|
9911
|
-
var e =
|
|
9912
|
-
n =
|
|
9913
|
-
r =
|
|
9914
|
-
i =
|
|
9960
|
+
function ru(_ref161) {
|
|
9961
|
+
var e = _ref161.element,
|
|
9962
|
+
n = _ref161.item,
|
|
9963
|
+
r = _ref161.messages,
|
|
9964
|
+
i = _ref161.showAnswer;
|
|
9915
9965
|
var a = rn(n, e.config.optionLabelStyle);
|
|
9916
9966
|
if (e.config.renderer === "table") {
|
|
9917
9967
|
var _o3 = pl(e, n);
|
|
9918
9968
|
return (0, t.jsxs)("div", {
|
|
9919
9969
|
className: W.element,
|
|
9920
9970
|
children: [(0, t.jsx)("div", {
|
|
9921
|
-
className:
|
|
9971
|
+
className: vl["table-wrap"],
|
|
9922
9972
|
children: (0, t.jsxs)("table", {
|
|
9923
|
-
className:
|
|
9973
|
+
className: vl.table,
|
|
9924
9974
|
children: [(0, t.jsxs)("colgroup", {
|
|
9925
9975
|
children: [(0, t.jsx)("col", {
|
|
9926
|
-
className:
|
|
9976
|
+
className: vl["table-option-column"]
|
|
9927
9977
|
}), n.columns.map(function (e) {
|
|
9928
9978
|
return (0, t.jsx)("col", {}, e.id);
|
|
9929
9979
|
})]
|
|
@@ -9944,7 +9994,7 @@ function $l(_ref157) {
|
|
|
9944
9994
|
return (0, t.jsxs)("tr", {
|
|
9945
9995
|
children: [(0, t.jsx)("td", {
|
|
9946
9996
|
children: (0, t.jsx)("span", {
|
|
9947
|
-
className:
|
|
9997
|
+
className: vl["table-option-marker"],
|
|
9948
9998
|
children: e.marker
|
|
9949
9999
|
})
|
|
9950
10000
|
}), e.cells.map(function (n, r) {
|
|
@@ -9967,8 +10017,7 @@ function $l(_ref157) {
|
|
|
9967
10017
|
var o = pl(e, n);
|
|
9968
10018
|
return (0, t.jsxs)("div", {
|
|
9969
10019
|
className: W.element,
|
|
9970
|
-
children: [(0, t.jsx)(
|
|
9971
|
-
className: W["option-list"],
|
|
10020
|
+
children: [(0, t.jsx)(gl, {
|
|
9972
10021
|
children: a.map(function (e) {
|
|
9973
10022
|
return (0, t.jsxs)("li", {
|
|
9974
10023
|
className: W["option-item"],
|
|
@@ -9986,10 +10035,10 @@ function $l(_ref157) {
|
|
|
9986
10035
|
}) : null]
|
|
9987
10036
|
});
|
|
9988
10037
|
}
|
|
9989
|
-
function
|
|
9990
|
-
var e =
|
|
9991
|
-
n =
|
|
9992
|
-
r =
|
|
10038
|
+
function iu(_ref162) {
|
|
10039
|
+
var e = _ref162.item,
|
|
10040
|
+
n = _ref162.messages,
|
|
10041
|
+
r = _ref162.showAnswer;
|
|
9993
10042
|
return (0, t.jsxs)("div", {
|
|
9994
10043
|
className: W.element,
|
|
9995
10044
|
children: [(0, t.jsx)("ol", {
|
|
@@ -10006,26 +10055,26 @@ function eu(_ref158) {
|
|
|
10006
10055
|
}, e.id);
|
|
10007
10056
|
})
|
|
10008
10057
|
}), r ? (0, t.jsx)(K, {
|
|
10009
|
-
groups:
|
|
10058
|
+
groups: bl(e),
|
|
10010
10059
|
title: n.standardAnswer
|
|
10011
10060
|
}) : null]
|
|
10012
10061
|
});
|
|
10013
10062
|
}
|
|
10014
|
-
function
|
|
10015
|
-
var e =
|
|
10016
|
-
n =
|
|
10017
|
-
r =
|
|
10018
|
-
i =
|
|
10063
|
+
function au(_ref163) {
|
|
10064
|
+
var e = _ref163.element,
|
|
10065
|
+
n = _ref163.item,
|
|
10066
|
+
r = _ref163.messages,
|
|
10067
|
+
i = _ref163.showAnswer;
|
|
10019
10068
|
var a = _n(n, !0, e),
|
|
10020
|
-
o =
|
|
10069
|
+
o = jl(a, r.blankLabel);
|
|
10021
10070
|
return (0, t.jsxs)("div", {
|
|
10022
10071
|
className: W.element,
|
|
10023
10072
|
children: [(0, t.jsx)(zc, {
|
|
10024
10073
|
content: a.content,
|
|
10025
|
-
renderBlank: function renderBlank(
|
|
10026
|
-
var e =
|
|
10027
|
-
n =
|
|
10028
|
-
i =
|
|
10074
|
+
renderBlank: function renderBlank(_ref164) {
|
|
10075
|
+
var e = _ref164.blankId,
|
|
10076
|
+
n = _ref164.index,
|
|
10077
|
+
i = _ref164.label;
|
|
10029
10078
|
return (0, t.jsx)("span", {
|
|
10030
10079
|
"aria-label": i || "".concat(r.blankLabel).concat(n + 1),
|
|
10031
10080
|
className: W["word-builder-blank"],
|
|
@@ -10052,81 +10101,81 @@ function tu(_ref159) {
|
|
|
10052
10101
|
}) : null]
|
|
10053
10102
|
});
|
|
10054
10103
|
}
|
|
10055
|
-
function
|
|
10056
|
-
var e =
|
|
10057
|
-
n =
|
|
10058
|
-
r =
|
|
10059
|
-
i =
|
|
10104
|
+
function ou(_ref165) {
|
|
10105
|
+
var e = _ref165.element,
|
|
10106
|
+
n = _ref165.item,
|
|
10107
|
+
r = _ref165.messages,
|
|
10108
|
+
i = _ref165.showAnswer;
|
|
10060
10109
|
if (e.type !== n.type) throw Error("\u9898\u76EE\u5143\u7D20\u7ED3\u6784\u4E0D\u5339\u914D\uFF0Cexpected=".concat(e.type, "\uFF0Cactual=").concat(n.type));
|
|
10061
10110
|
return e.type === "richText" ? (0, t.jsx)(G, {
|
|
10062
10111
|
content: n.content
|
|
10063
|
-
}) : e.type === "textResponse" ? null : e.type === "ordering" ? (0, t.jsx)(
|
|
10112
|
+
}) : e.type === "textResponse" ? null : e.type === "ordering" ? (0, t.jsx)(iu, {
|
|
10064
10113
|
item: n,
|
|
10065
10114
|
messages: r,
|
|
10066
10115
|
showAnswer: i
|
|
10067
|
-
}) : e.type === "classification" ? (0, t.jsx)(
|
|
10116
|
+
}) : e.type === "classification" ? (0, t.jsx)(Xl, {
|
|
10068
10117
|
item: n,
|
|
10069
10118
|
messages: r,
|
|
10070
10119
|
showAnswer: i
|
|
10071
|
-
}) : e.type === "textMarker" ? (0, t.jsx)(
|
|
10120
|
+
}) : e.type === "textMarker" ? (0, t.jsx)(El, {
|
|
10072
10121
|
item: n,
|
|
10073
10122
|
messages: r,
|
|
10074
10123
|
showAnswer: i
|
|
10075
|
-
}) :
|
|
10124
|
+
}) : su({
|
|
10076
10125
|
element: e,
|
|
10077
10126
|
item: n,
|
|
10078
10127
|
messages: r,
|
|
10079
10128
|
showAnswer: i
|
|
10080
10129
|
});
|
|
10081
10130
|
}
|
|
10082
|
-
function
|
|
10083
|
-
var e =
|
|
10084
|
-
n =
|
|
10085
|
-
r =
|
|
10086
|
-
i =
|
|
10131
|
+
function su(_ref166) {
|
|
10132
|
+
var e = _ref166.element,
|
|
10133
|
+
n = _ref166.item,
|
|
10134
|
+
r = _ref166.messages,
|
|
10135
|
+
i = _ref166.showAnswer;
|
|
10087
10136
|
switch (e.type) {
|
|
10088
10137
|
case "choice":
|
|
10089
|
-
return (0, t.jsx)(
|
|
10138
|
+
return (0, t.jsx)(ru, {
|
|
10090
10139
|
element: e,
|
|
10091
10140
|
item: n,
|
|
10092
10141
|
messages: r,
|
|
10093
10142
|
showAnswer: i
|
|
10094
10143
|
});
|
|
10095
10144
|
case "fill":
|
|
10096
|
-
return (0, t.jsx)(
|
|
10145
|
+
return (0, t.jsx)(Jl, {
|
|
10097
10146
|
item: n,
|
|
10098
10147
|
messages: r,
|
|
10099
10148
|
showAnswer: i
|
|
10100
10149
|
});
|
|
10101
10150
|
case "inlineFill":
|
|
10102
|
-
return (0, t.jsx)(
|
|
10151
|
+
return (0, t.jsx)(Zl, {
|
|
10103
10152
|
element: e,
|
|
10104
10153
|
item: n,
|
|
10105
10154
|
messages: r,
|
|
10106
10155
|
showAnswer: i
|
|
10107
10156
|
});
|
|
10108
10157
|
case "wordBuilder":
|
|
10109
|
-
return (0, t.jsx)(
|
|
10158
|
+
return (0, t.jsx)(au, {
|
|
10110
10159
|
element: e,
|
|
10111
10160
|
item: n,
|
|
10112
10161
|
messages: r,
|
|
10113
10162
|
showAnswer: i
|
|
10114
10163
|
});
|
|
10115
10164
|
case "judgement":
|
|
10116
|
-
return (0, t.jsx)(
|
|
10165
|
+
return (0, t.jsx)($l, {
|
|
10117
10166
|
element: e,
|
|
10118
10167
|
item: n,
|
|
10119
10168
|
messages: r,
|
|
10120
10169
|
showAnswer: i
|
|
10121
10170
|
});
|
|
10122
10171
|
case "lineConnect":
|
|
10123
|
-
return (0, t.jsx)(
|
|
10172
|
+
return (0, t.jsx)(eu, {
|
|
10124
10173
|
item: n,
|
|
10125
10174
|
messages: r,
|
|
10126
10175
|
showAnswer: i
|
|
10127
10176
|
});
|
|
10128
10177
|
case "matching":
|
|
10129
|
-
return (0, t.jsx)(
|
|
10178
|
+
return (0, t.jsx)(nu, {
|
|
10130
10179
|
item: n,
|
|
10131
10180
|
messages: r,
|
|
10132
10181
|
showAnswer: i
|
|
@@ -10142,13 +10191,13 @@ var X = {
|
|
|
10142
10191
|
extra: "_extra_1jseb_41",
|
|
10143
10192
|
child: "_child_1jseb_31"
|
|
10144
10193
|
};
|
|
10145
|
-
function
|
|
10146
|
-
var
|
|
10147
|
-
e =
|
|
10148
|
-
n =
|
|
10149
|
-
r =
|
|
10150
|
-
i =
|
|
10151
|
-
a =
|
|
10194
|
+
function cu(_ref167) {
|
|
10195
|
+
var _ref167$childIndexPat = _ref167.childIndexPath,
|
|
10196
|
+
e = _ref167$childIndexPat === void 0 ? [] : _ref167$childIndexPat,
|
|
10197
|
+
n = _ref167.messages,
|
|
10198
|
+
r = _ref167.renderChild,
|
|
10199
|
+
i = _ref167.rootQuestionNumber,
|
|
10200
|
+
a = _ref167.value;
|
|
10152
10201
|
return a.children.length === 0 ? (0, t.jsx)("div", {
|
|
10153
10202
|
className: X.empty,
|
|
10154
10203
|
children: n.previewEmpty
|
|
@@ -10168,29 +10217,29 @@ function iu(_ref163) {
|
|
|
10168
10217
|
})
|
|
10169
10218
|
});
|
|
10170
10219
|
}
|
|
10171
|
-
var
|
|
10172
|
-
function
|
|
10220
|
+
var lu = ["locale"];
|
|
10221
|
+
function uu(e) {
|
|
10173
10222
|
var _e$locale2 = e.locale,
|
|
10174
10223
|
n = _e$locale2 === void 0 ? "zh-CN" : _e$locale2,
|
|
10175
|
-
r = ma(e,
|
|
10224
|
+
r = ma(e, lu),
|
|
10176
10225
|
i = us(r.value, r.questionTypeTemplates);
|
|
10177
|
-
return (0, t.jsx)(
|
|
10226
|
+
return (0, t.jsx)(du, C(C({}, r), {}, {
|
|
10178
10227
|
childIndexPath: [],
|
|
10179
10228
|
messages: yc(n),
|
|
10180
10229
|
value: i
|
|
10181
10230
|
}));
|
|
10182
10231
|
}
|
|
10183
|
-
function
|
|
10184
|
-
var e =
|
|
10185
|
-
n =
|
|
10186
|
-
r =
|
|
10187
|
-
i =
|
|
10188
|
-
|
|
10189
|
-
a =
|
|
10190
|
-
|
|
10191
|
-
o =
|
|
10192
|
-
s =
|
|
10193
|
-
c =
|
|
10232
|
+
function du(_ref168) {
|
|
10233
|
+
var e = _ref168.childIndexPath,
|
|
10234
|
+
n = _ref168.className,
|
|
10235
|
+
r = _ref168.messages,
|
|
10236
|
+
i = _ref168.rootQuestionNumber,
|
|
10237
|
+
_ref168$showAnswer = _ref168.showAnswer,
|
|
10238
|
+
a = _ref168$showAnswer === void 0 ? !1 : _ref168$showAnswer,
|
|
10239
|
+
_ref168$showExtraAttr = _ref168.showExtraAttributes,
|
|
10240
|
+
o = _ref168$showExtraAttr === void 0 ? !1 : _ref168$showExtraAttr,
|
|
10241
|
+
s = _ref168.questionTypeTemplates,
|
|
10242
|
+
c = _ref168.value;
|
|
10194
10243
|
var l = Zi(s, c);
|
|
10195
10244
|
if (!l) return (0, t.jsx)("div", {
|
|
10196
10245
|
className: H(X.root, n),
|
|
@@ -10205,7 +10254,7 @@ function su(_ref164) {
|
|
|
10205
10254
|
var i = Yt(c, n, e);
|
|
10206
10255
|
return (0, t.jsx)("section", {
|
|
10207
10256
|
className: X.element,
|
|
10208
|
-
children: (0, t.jsx)(
|
|
10257
|
+
children: (0, t.jsx)(ou, {
|
|
10209
10258
|
element: e,
|
|
10210
10259
|
item: i,
|
|
10211
10260
|
messages: r,
|
|
@@ -10222,9 +10271,9 @@ function su(_ref164) {
|
|
|
10222
10271
|
className: X.extra,
|
|
10223
10272
|
children: [(0, t.jsx)(kc, {
|
|
10224
10273
|
children: e.name
|
|
10225
|
-
}), (0, t.jsx)(
|
|
10226
|
-
element:
|
|
10227
|
-
item:
|
|
10274
|
+
}), (0, t.jsx)(ou, {
|
|
10275
|
+
element: pu(e),
|
|
10276
|
+
item: mu(i),
|
|
10228
10277
|
messages: r,
|
|
10229
10278
|
showAnswer: !1
|
|
10230
10279
|
})]
|
|
@@ -10232,11 +10281,11 @@ function su(_ref164) {
|
|
|
10232
10281
|
})
|
|
10233
10282
|
}) : null,
|
|
10234
10283
|
f = (0, t.jsxs)(t.Fragment, {
|
|
10235
|
-
children: [u, c.children.length === 0 ? null : (0, t.jsx)(
|
|
10284
|
+
children: [u, c.children.length === 0 ? null : (0, t.jsx)(cu, {
|
|
10236
10285
|
childIndexPath: e,
|
|
10237
10286
|
messages: r,
|
|
10238
10287
|
renderChild: function renderChild(e, n) {
|
|
10239
|
-
return (0, t.jsx)(
|
|
10288
|
+
return (0, t.jsx)(du, {
|
|
10240
10289
|
childIndexPath: n,
|
|
10241
10290
|
messages: r,
|
|
10242
10291
|
rootQuestionNumber: i,
|
|
@@ -10252,29 +10301,29 @@ function su(_ref164) {
|
|
|
10252
10301
|
});
|
|
10253
10302
|
return (0, t.jsx)("div", {
|
|
10254
10303
|
className: H(X.root, n),
|
|
10255
|
-
children:
|
|
10304
|
+
children: fu(l, c) ? (0, t.jsx)("div", {
|
|
10256
10305
|
className: X.empty,
|
|
10257
10306
|
children: r.previewEmpty
|
|
10258
10307
|
}) : f
|
|
10259
10308
|
});
|
|
10260
10309
|
}
|
|
10261
|
-
function
|
|
10310
|
+
function fu(e, t) {
|
|
10262
10311
|
return t.elements.length === 0 && t.extras.length === 0 && t.children.length === 0;
|
|
10263
10312
|
}
|
|
10264
|
-
function
|
|
10313
|
+
function pu(e) {
|
|
10265
10314
|
return {
|
|
10266
10315
|
config: {},
|
|
10267
10316
|
name: e.name,
|
|
10268
10317
|
type: "richText"
|
|
10269
10318
|
};
|
|
10270
10319
|
}
|
|
10271
|
-
function
|
|
10320
|
+
function mu(e) {
|
|
10272
10321
|
return {
|
|
10273
10322
|
content: e.content,
|
|
10274
10323
|
type: "richText"
|
|
10275
10324
|
};
|
|
10276
10325
|
}
|
|
10277
|
-
var
|
|
10326
|
+
var hu = {
|
|
10278
10327
|
root: "_root_17bqr_1",
|
|
10279
10328
|
toolbar: "_toolbar_17bqr_26",
|
|
10280
10329
|
"toolbar-title": "_toolbar-title_17bqr_36",
|
|
@@ -10329,7 +10378,7 @@ var du = {
|
|
|
10329
10378
|
"palette-section-title": "_palette-section-title_vhj2r_62",
|
|
10330
10379
|
"palette-button": "_palette-button_vhj2r_70"
|
|
10331
10380
|
},
|
|
10332
|
-
|
|
10381
|
+
gu = {
|
|
10333
10382
|
"en-US": {
|
|
10334
10383
|
addElement: "Add element",
|
|
10335
10384
|
addExtra: "Add extra attribute",
|
|
@@ -10463,26 +10512,26 @@ var du = {
|
|
|
10463
10512
|
wordBuilderLabel: "\u7EC4\u8BCD\u62FC\u5199"
|
|
10464
10513
|
}
|
|
10465
10514
|
};
|
|
10466
|
-
function
|
|
10515
|
+
function _u(e, t) {
|
|
10467
10516
|
var n;
|
|
10468
10517
|
return (n = e.extraDescriptions.get(t)) == null ? t : n;
|
|
10469
10518
|
}
|
|
10470
|
-
function
|
|
10519
|
+
function vu(e, t) {
|
|
10471
10520
|
var n;
|
|
10472
10521
|
return (n = e.extraLabels.get(t)) == null ? t : n;
|
|
10473
10522
|
}
|
|
10474
|
-
function
|
|
10523
|
+
function yu(e) {
|
|
10475
10524
|
switch (e) {
|
|
10476
10525
|
case "en-US":
|
|
10477
|
-
return
|
|
10526
|
+
return gu["en-US"];
|
|
10478
10527
|
case "zh-CN":
|
|
10479
|
-
return
|
|
10528
|
+
return gu["zh-CN"];
|
|
10480
10529
|
}
|
|
10481
10530
|
}
|
|
10482
|
-
function
|
|
10483
|
-
return t === "richText" ? e.richTextDescription : t === "ordering" ? e.orderingDescription :
|
|
10531
|
+
function bu(e, t) {
|
|
10532
|
+
return t === "richText" ? e.richTextDescription : t === "ordering" ? e.orderingDescription : Cu(e, t);
|
|
10484
10533
|
}
|
|
10485
|
-
var
|
|
10534
|
+
var xu = {
|
|
10486
10535
|
choice: function choice(e) {
|
|
10487
10536
|
return e.optionGroupDescription;
|
|
10488
10537
|
},
|
|
@@ -10514,7 +10563,7 @@ var _u = {
|
|
|
10514
10563
|
return e.wordBuilderDescription;
|
|
10515
10564
|
}
|
|
10516
10565
|
},
|
|
10517
|
-
|
|
10566
|
+
Su = {
|
|
10518
10567
|
choice: function choice(e) {
|
|
10519
10568
|
return e.optionGroupLabel;
|
|
10520
10569
|
},
|
|
@@ -10546,40 +10595,40 @@ var _u = {
|
|
|
10546
10595
|
return e.wordBuilderLabel;
|
|
10547
10596
|
}
|
|
10548
10597
|
};
|
|
10549
|
-
function
|
|
10550
|
-
return
|
|
10598
|
+
function Cu(e, t) {
|
|
10599
|
+
return xu[t](e);
|
|
10551
10600
|
}
|
|
10552
|
-
function
|
|
10553
|
-
return t === "richText" ? e.richTextLabel : t === "ordering" ? e.orderingLabel :
|
|
10601
|
+
function wu(e, t) {
|
|
10602
|
+
return t === "richText" ? e.richTextLabel : t === "ordering" ? e.orderingLabel : Tu(e, t);
|
|
10554
10603
|
}
|
|
10555
|
-
function
|
|
10556
|
-
return
|
|
10604
|
+
function Tu(e, t) {
|
|
10605
|
+
return Su[t](e);
|
|
10557
10606
|
}
|
|
10558
|
-
function
|
|
10607
|
+
function Eu(e, t) {
|
|
10559
10608
|
var n;
|
|
10560
10609
|
return (n = e.optionValueLabels.get(t)) == null ? t : n;
|
|
10561
10610
|
}
|
|
10562
|
-
function
|
|
10611
|
+
function Du(e, t) {
|
|
10563
10612
|
var n;
|
|
10564
10613
|
return (n = e.candidateModeValueLabels.get(t)) == null ? t : n;
|
|
10565
10614
|
}
|
|
10566
|
-
function
|
|
10615
|
+
function Ou(e, t) {
|
|
10567
10616
|
var n;
|
|
10568
10617
|
return (n = e.lineConnectLabelStyleLabels.get(t)) == null ? t : n;
|
|
10569
10618
|
}
|
|
10570
|
-
function
|
|
10571
|
-
var e =
|
|
10572
|
-
r =
|
|
10573
|
-
i =
|
|
10574
|
-
a =
|
|
10575
|
-
o =
|
|
10576
|
-
s =
|
|
10577
|
-
c =
|
|
10578
|
-
l =
|
|
10579
|
-
var
|
|
10580
|
-
|
|
10581
|
-
u =
|
|
10582
|
-
d =
|
|
10619
|
+
function ku(_ref169) {
|
|
10620
|
+
var e = _ref169.elements,
|
|
10621
|
+
r = _ref169.extras,
|
|
10622
|
+
i = _ref169.labels,
|
|
10623
|
+
a = _ref169.onDeleteElement,
|
|
10624
|
+
o = _ref169.onDeleteExtra,
|
|
10625
|
+
s = _ref169.onMoveElement,
|
|
10626
|
+
c = _ref169.onSelectElement,
|
|
10627
|
+
l = _ref169.selectedElementClientId;
|
|
10628
|
+
var _ref170 = (0, n.useState)(null),
|
|
10629
|
+
_ref171 = _slicedToArray(_ref170, 2),
|
|
10630
|
+
u = _ref171[0],
|
|
10631
|
+
d = _ref171[1];
|
|
10583
10632
|
return (0, t.jsxs)("section", {
|
|
10584
10633
|
className: Q.panel,
|
|
10585
10634
|
children: [(0, t.jsxs)("div", {
|
|
@@ -10598,7 +10647,7 @@ function Tu(_ref165) {
|
|
|
10598
10647
|
className: Z["element-list"],
|
|
10599
10648
|
children: [e.map(function (n, r) {
|
|
10600
10649
|
var o = n.clientId === l,
|
|
10601
|
-
f =
|
|
10650
|
+
f = wu(i, n.type);
|
|
10602
10651
|
return (0, t.jsxs)("div", {
|
|
10603
10652
|
className: "".concat(Z["element-card"], " ").concat(o ? Z.active : ""),
|
|
10604
10653
|
onClick: function onClick() {
|
|
@@ -10667,7 +10716,7 @@ function Tu(_ref165) {
|
|
|
10667
10716
|
children: i.extraTitle
|
|
10668
10717
|
}) : null, r.map(function (n, r) {
|
|
10669
10718
|
var a = n.clientId === l,
|
|
10670
|
-
s =
|
|
10719
|
+
s = vu(i, n.type);
|
|
10671
10720
|
return (0, t.jsxs)("div", {
|
|
10672
10721
|
className: "".concat(Z["element-card"], " ").concat(a ? Z.active : ""),
|
|
10673
10722
|
onClick: function onClick() {
|
|
@@ -10719,11 +10768,11 @@ function Tu(_ref165) {
|
|
|
10719
10768
|
})]
|
|
10720
10769
|
});
|
|
10721
10770
|
}
|
|
10722
|
-
function
|
|
10723
|
-
var e =
|
|
10724
|
-
n =
|
|
10725
|
-
r =
|
|
10726
|
-
i =
|
|
10771
|
+
function Au(_ref172) {
|
|
10772
|
+
var e = _ref172.addedExtraTypes,
|
|
10773
|
+
n = _ref172.labels,
|
|
10774
|
+
r = _ref172.onAddElement,
|
|
10775
|
+
i = _ref172.onAddExtra;
|
|
10727
10776
|
var a = new Set(e);
|
|
10728
10777
|
return (0, t.jsxs)("aside", {
|
|
10729
10778
|
className: Q.panel,
|
|
@@ -10737,16 +10786,16 @@ function Eu(_ref168) {
|
|
|
10737
10786
|
className: Q.palette,
|
|
10738
10787
|
children: ee.map(function (e) {
|
|
10739
10788
|
return (0, t.jsxs)("button", {
|
|
10740
|
-
"aria-label": "".concat(n.addElement, ": ").concat(
|
|
10789
|
+
"aria-label": "".concat(n.addElement, ": ").concat(wu(n, e)),
|
|
10741
10790
|
className: Q["palette-button"],
|
|
10742
10791
|
onClick: function onClick() {
|
|
10743
10792
|
return r(e);
|
|
10744
10793
|
},
|
|
10745
10794
|
type: "button",
|
|
10746
10795
|
children: [(0, t.jsx)("strong", {
|
|
10747
|
-
children:
|
|
10796
|
+
children: wu(n, e)
|
|
10748
10797
|
}), (0, t.jsx)("small", {
|
|
10749
|
-
children:
|
|
10798
|
+
children: bu(n, e)
|
|
10750
10799
|
})]
|
|
10751
10800
|
}, e);
|
|
10752
10801
|
})
|
|
@@ -10757,10 +10806,10 @@ function Eu(_ref168) {
|
|
|
10757
10806
|
children: n.extraTitle
|
|
10758
10807
|
}), (0, t.jsx)("div", {
|
|
10759
10808
|
className: Q.palette,
|
|
10760
|
-
children:
|
|
10809
|
+
children: w.map(function (e) {
|
|
10761
10810
|
var r = a.has(e);
|
|
10762
10811
|
return (0, t.jsxs)("button", {
|
|
10763
|
-
"aria-label": "".concat(n.addExtra, ": ").concat(
|
|
10812
|
+
"aria-label": "".concat(n.addExtra, ": ").concat(vu(n, e)),
|
|
10764
10813
|
className: Q["palette-button"],
|
|
10765
10814
|
disabled: r,
|
|
10766
10815
|
onClick: function onClick() {
|
|
@@ -10768,9 +10817,9 @@ function Eu(_ref168) {
|
|
|
10768
10817
|
},
|
|
10769
10818
|
type: "button",
|
|
10770
10819
|
children: [(0, t.jsx)("strong", {
|
|
10771
|
-
children:
|
|
10820
|
+
children: vu(n, e)
|
|
10772
10821
|
}), (0, t.jsx)("small", {
|
|
10773
|
-
children:
|
|
10822
|
+
children: _u(n, e)
|
|
10774
10823
|
})]
|
|
10775
10824
|
}, e);
|
|
10776
10825
|
})
|
|
@@ -10788,26 +10837,26 @@ var $ = {
|
|
|
10788
10837
|
textarea: "_textarea_tgswd_28",
|
|
10789
10838
|
empty: "_empty_tgswd_61"
|
|
10790
10839
|
},
|
|
10791
|
-
|
|
10792
|
-
|
|
10793
|
-
|
|
10794
|
-
|
|
10795
|
-
|
|
10796
|
-
|
|
10797
|
-
|
|
10798
|
-
|
|
10799
|
-
function
|
|
10800
|
-
var e =
|
|
10801
|
-
n =
|
|
10802
|
-
r =
|
|
10803
|
-
i =
|
|
10804
|
-
a =
|
|
10805
|
-
o =
|
|
10806
|
-
s =
|
|
10807
|
-
c =
|
|
10808
|
-
l =
|
|
10809
|
-
u =
|
|
10810
|
-
var d =
|
|
10840
|
+
ju = ["none", "sharedPool", "perBlankOptions"],
|
|
10841
|
+
Mu = ["upperAlpha", "lowerAlpha", "number"],
|
|
10842
|
+
Nu = ["number", "upperAlpha", "lowerAlpha", "lowerRoman", "chineseNumber", "none"],
|
|
10843
|
+
Pu = [2, 3, 4, 5],
|
|
10844
|
+
Fu = ["standard", "table"],
|
|
10845
|
+
Iu = ["single", "multiple"],
|
|
10846
|
+
Lu = ["spelling", "sentence"],
|
|
10847
|
+
Ru = ["correctWrong", "yesNo", "validInvalid", "tf", "rightWrong", "checkCross"];
|
|
10848
|
+
function zu(_ref173) {
|
|
10849
|
+
var e = _ref173.description,
|
|
10850
|
+
n = _ref173.globalConfig,
|
|
10851
|
+
r = _ref173.isSubjective,
|
|
10852
|
+
i = _ref173.labels,
|
|
10853
|
+
a = _ref173.onElementChange,
|
|
10854
|
+
o = _ref173.onExtraChange,
|
|
10855
|
+
s = _ref173.onGlobalConfigChange,
|
|
10856
|
+
c = _ref173.onMetadataChange,
|
|
10857
|
+
l = _ref173.selectedExtra,
|
|
10858
|
+
u = _ref173.selectedElement;
|
|
10859
|
+
var d = Bu({
|
|
10811
10860
|
labels: i,
|
|
10812
10861
|
onElementChange: a,
|
|
10813
10862
|
onExtraChange: o,
|
|
@@ -10918,12 +10967,12 @@ function Fu(_ref169) {
|
|
|
10918
10967
|
})]
|
|
10919
10968
|
});
|
|
10920
10969
|
}
|
|
10921
|
-
function
|
|
10922
|
-
var e =
|
|
10923
|
-
n =
|
|
10924
|
-
r =
|
|
10925
|
-
i =
|
|
10926
|
-
a =
|
|
10970
|
+
function Bu(_ref174) {
|
|
10971
|
+
var e = _ref174.labels,
|
|
10972
|
+
n = _ref174.onElementChange,
|
|
10973
|
+
r = _ref174.onExtraChange,
|
|
10974
|
+
i = _ref174.selectedElement,
|
|
10975
|
+
a = _ref174.selectedExtra;
|
|
10927
10976
|
return i ? (0, t.jsxs)("div", {
|
|
10928
10977
|
className: $["form-stack"],
|
|
10929
10978
|
children: [(0, t.jsxs)("label", {
|
|
@@ -10952,7 +11001,7 @@ function Iu(_ref170) {
|
|
|
10952
11001
|
},
|
|
10953
11002
|
value: i.enName
|
|
10954
11003
|
})]
|
|
10955
|
-
}),
|
|
11004
|
+
}), Vu(i, e, n)]
|
|
10956
11005
|
}) : a ? (0, t.jsxs)("div", {
|
|
10957
11006
|
className: $["form-stack"],
|
|
10958
11007
|
children: [(0, t.jsxs)("label", {
|
|
@@ -10987,10 +11036,10 @@ function Iu(_ref170) {
|
|
|
10987
11036
|
children: e.noElement
|
|
10988
11037
|
});
|
|
10989
11038
|
}
|
|
10990
|
-
function
|
|
10991
|
-
return e.type === "fill" || e.type === "classification" || e.type === "ordering" || e.type === "richText" || e.type === "textMarker" || e.type === "textResponse" ? null :
|
|
11039
|
+
function Vu(e, t, n) {
|
|
11040
|
+
return e.type === "fill" || e.type === "classification" || e.type === "ordering" || e.type === "richText" || e.type === "textMarker" || e.type === "textResponse" ? null : Hu(e, t, n);
|
|
10992
11041
|
}
|
|
10993
|
-
function
|
|
11042
|
+
function Hu(e, n, r) {
|
|
10994
11043
|
switch (e.type) {
|
|
10995
11044
|
case "inlineFill":
|
|
10996
11045
|
return (0, t.jsxs)(t.Fragment, {
|
|
@@ -11008,10 +11057,10 @@ function Ru(e, n, r) {
|
|
|
11008
11057
|
}));
|
|
11009
11058
|
},
|
|
11010
11059
|
value: e.config.candidateMode,
|
|
11011
|
-
children:
|
|
11060
|
+
children: ju.map(function (e) {
|
|
11012
11061
|
return (0, t.jsx)("option", {
|
|
11013
11062
|
value: e,
|
|
11014
|
-
children:
|
|
11063
|
+
children: Du(n, e)
|
|
11015
11064
|
}, e);
|
|
11016
11065
|
})
|
|
11017
11066
|
})]
|
|
@@ -11047,10 +11096,10 @@ function Ru(e, n, r) {
|
|
|
11047
11096
|
}));
|
|
11048
11097
|
},
|
|
11049
11098
|
value: e.config.builderMode,
|
|
11050
|
-
children:
|
|
11099
|
+
children: Lu.map(function (e) {
|
|
11051
11100
|
return (0, t.jsx)("option", {
|
|
11052
11101
|
value: e,
|
|
11053
|
-
children:
|
|
11102
|
+
children: Eu(n, e)
|
|
11054
11103
|
}, e);
|
|
11055
11104
|
})
|
|
11056
11105
|
})]
|
|
@@ -11070,23 +11119,23 @@ function Ru(e, n, r) {
|
|
|
11070
11119
|
}));
|
|
11071
11120
|
},
|
|
11072
11121
|
value: e.config.judgeAnswerMode,
|
|
11073
|
-
children:
|
|
11122
|
+
children: Ru.map(function (e) {
|
|
11074
11123
|
return (0, t.jsx)("option", {
|
|
11075
11124
|
value: e,
|
|
11076
|
-
children:
|
|
11125
|
+
children: Eu(n, e)
|
|
11077
11126
|
}, e);
|
|
11078
11127
|
})
|
|
11079
11128
|
})]
|
|
11080
11129
|
});
|
|
11081
11130
|
case "choice":
|
|
11082
|
-
return
|
|
11131
|
+
return Uu(e, n, r);
|
|
11083
11132
|
case "lineConnect":
|
|
11084
|
-
return
|
|
11133
|
+
return Wu(e, n, r);
|
|
11085
11134
|
case "matching":
|
|
11086
|
-
return
|
|
11135
|
+
return Gu(e, n, r);
|
|
11087
11136
|
}
|
|
11088
11137
|
}
|
|
11089
|
-
function
|
|
11138
|
+
function Uu(e, n, r) {
|
|
11090
11139
|
return (0, t.jsxs)(t.Fragment, {
|
|
11091
11140
|
children: [(0, t.jsxs)("label", {
|
|
11092
11141
|
className: $["form-row"],
|
|
@@ -11102,10 +11151,10 @@ function zu(e, n, r) {
|
|
|
11102
11151
|
}));
|
|
11103
11152
|
},
|
|
11104
11153
|
value: e.config.selectionType,
|
|
11105
|
-
children:
|
|
11154
|
+
children: Iu.map(function (e) {
|
|
11106
11155
|
return (0, t.jsx)("option", {
|
|
11107
11156
|
value: e,
|
|
11108
|
-
children:
|
|
11157
|
+
children: Eu(n, e)
|
|
11109
11158
|
}, e);
|
|
11110
11159
|
})
|
|
11111
11160
|
})]
|
|
@@ -11123,10 +11172,10 @@ function zu(e, n, r) {
|
|
|
11123
11172
|
}));
|
|
11124
11173
|
},
|
|
11125
11174
|
value: e.config.optionLabelStyle,
|
|
11126
|
-
children:
|
|
11175
|
+
children: Mu.map(function (e) {
|
|
11127
11176
|
return (0, t.jsx)("option", {
|
|
11128
11177
|
value: e,
|
|
11129
|
-
children:
|
|
11178
|
+
children: Eu(n, e)
|
|
11130
11179
|
}, e);
|
|
11131
11180
|
})
|
|
11132
11181
|
})]
|
|
@@ -11144,18 +11193,18 @@ function zu(e, n, r) {
|
|
|
11144
11193
|
}));
|
|
11145
11194
|
},
|
|
11146
11195
|
value: e.config.renderer,
|
|
11147
|
-
children:
|
|
11196
|
+
children: Fu.map(function (e) {
|
|
11148
11197
|
return (0, t.jsx)("option", {
|
|
11149
11198
|
value: e,
|
|
11150
|
-
children:
|
|
11199
|
+
children: Eu(n, e)
|
|
11151
11200
|
}, e);
|
|
11152
11201
|
})
|
|
11153
11202
|
})]
|
|
11154
11203
|
})]
|
|
11155
11204
|
});
|
|
11156
11205
|
}
|
|
11157
|
-
function
|
|
11158
|
-
var i =
|
|
11206
|
+
function Wu(e, n, r) {
|
|
11207
|
+
var i = Ku(e.config.columns);
|
|
11159
11208
|
return (0, t.jsxs)(t.Fragment, {
|
|
11160
11209
|
children: [(0, t.jsxs)("label", {
|
|
11161
11210
|
className: $["form-row"],
|
|
@@ -11166,12 +11215,12 @@ function Bu(e, n, r) {
|
|
|
11166
11215
|
onChange: function onChange(t) {
|
|
11167
11216
|
return r(C(C({}, e), {}, {
|
|
11168
11217
|
config: {
|
|
11169
|
-
columns:
|
|
11218
|
+
columns: Ju(i, Number(t.target.value))
|
|
11170
11219
|
}
|
|
11171
11220
|
}));
|
|
11172
11221
|
},
|
|
11173
11222
|
value: i.length,
|
|
11174
|
-
children:
|
|
11223
|
+
children: Pu.map(function (e) {
|
|
11175
11224
|
return (0, t.jsx)("option", {
|
|
11176
11225
|
value: e,
|
|
11177
11226
|
children: e
|
|
@@ -11197,10 +11246,10 @@ function Bu(e, n, r) {
|
|
|
11197
11246
|
}));
|
|
11198
11247
|
},
|
|
11199
11248
|
value: a.labelStyle,
|
|
11200
|
-
children:
|
|
11249
|
+
children: Nu.map(function (e) {
|
|
11201
11250
|
return (0, t.jsx)("option", {
|
|
11202
11251
|
value: e,
|
|
11203
|
-
children:
|
|
11252
|
+
children: Ou(n, e)
|
|
11204
11253
|
}, e);
|
|
11205
11254
|
})
|
|
11206
11255
|
})]
|
|
@@ -11208,8 +11257,8 @@ function Bu(e, n, r) {
|
|
|
11208
11257
|
})]
|
|
11209
11258
|
});
|
|
11210
11259
|
}
|
|
11211
|
-
function
|
|
11212
|
-
var i =
|
|
11260
|
+
function Gu(e, n, r) {
|
|
11261
|
+
var i = qu(e.config.columns);
|
|
11213
11262
|
return (0, t.jsx)(t.Fragment, {
|
|
11214
11263
|
children: i.map(function (a, o) {
|
|
11215
11264
|
return (0, t.jsxs)("label", {
|
|
@@ -11230,10 +11279,10 @@ function Vu(e, n, r) {
|
|
|
11230
11279
|
}));
|
|
11231
11280
|
},
|
|
11232
11281
|
value: a.labelStyle,
|
|
11233
|
-
children:
|
|
11282
|
+
children: Nu.map(function (e) {
|
|
11234
11283
|
return (0, t.jsx)("option", {
|
|
11235
11284
|
value: e,
|
|
11236
|
-
children:
|
|
11285
|
+
children: Ou(n, e)
|
|
11237
11286
|
}, e);
|
|
11238
11287
|
})
|
|
11239
11288
|
})]
|
|
@@ -11241,48 +11290,48 @@ function Vu(e, n, r) {
|
|
|
11241
11290
|
})
|
|
11242
11291
|
});
|
|
11243
11292
|
}
|
|
11244
|
-
function
|
|
11293
|
+
function Ku(e) {
|
|
11245
11294
|
var t = e.slice(0, 5);
|
|
11246
|
-
return t.length >= 2 ? t : [].concat(_toConsumableArray(t), _toConsumableArray(
|
|
11295
|
+
return t.length >= 2 ? t : [].concat(_toConsumableArray(t), _toConsumableArray(Nu.slice(t.length, 2).map(function (e) {
|
|
11247
11296
|
return {
|
|
11248
11297
|
labelStyle: e
|
|
11249
11298
|
};
|
|
11250
11299
|
})));
|
|
11251
11300
|
}
|
|
11252
|
-
function
|
|
11301
|
+
function qu(e) {
|
|
11253
11302
|
var t = e.slice(0, 2);
|
|
11254
|
-
return t.length >= 2 ? t : [].concat(_toConsumableArray(t), _toConsumableArray(
|
|
11303
|
+
return t.length >= 2 ? t : [].concat(_toConsumableArray(t), _toConsumableArray(Nu.slice(t.length, 2).map(function (e) {
|
|
11255
11304
|
return {
|
|
11256
11305
|
labelStyle: e
|
|
11257
11306
|
};
|
|
11258
11307
|
})));
|
|
11259
11308
|
}
|
|
11260
|
-
function
|
|
11309
|
+
function Ju(e, t) {
|
|
11261
11310
|
return Array.from({
|
|
11262
11311
|
length: Math.min(5, Math.max(2, t))
|
|
11263
11312
|
}, function (t, n) {
|
|
11264
11313
|
var r, i;
|
|
11265
11314
|
return (r = e.slice(n, n + 1)[0]) == null ? {
|
|
11266
|
-
labelStyle: (i =
|
|
11315
|
+
labelStyle: (i = Nu[n]) == null ? "number" : i
|
|
11267
11316
|
} : r;
|
|
11268
11317
|
});
|
|
11269
11318
|
}
|
|
11270
|
-
function
|
|
11271
|
-
var
|
|
11272
|
-
e =
|
|
11273
|
-
r =
|
|
11274
|
-
i =
|
|
11319
|
+
function Yu(_ref175) {
|
|
11320
|
+
var _ref175$locale = _ref175.locale,
|
|
11321
|
+
e = _ref175$locale === void 0 ? "zh-CN" : _ref175$locale,
|
|
11322
|
+
r = _ref175.onChange,
|
|
11323
|
+
i = _ref175.value;
|
|
11275
11324
|
var a, o, s, c;
|
|
11276
|
-
var l =
|
|
11277
|
-
|
|
11278
|
-
|
|
11279
|
-
u =
|
|
11280
|
-
d =
|
|
11281
|
-
|
|
11282
|
-
f =
|
|
11283
|
-
p =
|
|
11325
|
+
var l = yu(e),
|
|
11326
|
+
_ref176 = (0, n.useState)((a = (o = i.elements[0]) == null ? void 0 : o.clientId) == null ? null : a),
|
|
11327
|
+
_ref177 = _slicedToArray(_ref176, 2),
|
|
11328
|
+
u = _ref177[0],
|
|
11329
|
+
d = _ref177[1],
|
|
11330
|
+
_Xu = Xu(i, u),
|
|
11331
|
+
f = _Xu.selectedElement,
|
|
11332
|
+
p = _Xu.selectedExtra;
|
|
11284
11333
|
function m(e) {
|
|
11285
|
-
var t =
|
|
11334
|
+
var t = oe(e, i.elements);
|
|
11286
11335
|
r(C(C({}, i), {}, {
|
|
11287
11336
|
elements: [].concat(_toConsumableArray(i.elements), [t])
|
|
11288
11337
|
})), d(t.clientId);
|
|
@@ -11291,56 +11340,56 @@ function Gu(_ref171) {
|
|
|
11291
11340
|
if (i.extras.some(function (t) {
|
|
11292
11341
|
return t.type === e;
|
|
11293
11342
|
})) return;
|
|
11294
|
-
var t =
|
|
11343
|
+
var t = ae(e, i.extras);
|
|
11295
11344
|
r(C(C({}, i), {}, {
|
|
11296
11345
|
extras: [].concat(_toConsumableArray(i.extras), [t])
|
|
11297
11346
|
})), d(t.clientId);
|
|
11298
11347
|
}
|
|
11299
11348
|
function g(e) {
|
|
11300
|
-
var t =
|
|
11301
|
-
r(t), d(
|
|
11349
|
+
var t = ue(i, e);
|
|
11350
|
+
r(t), d(Zu(t));
|
|
11302
11351
|
}
|
|
11303
11352
|
function _(e) {
|
|
11304
|
-
var t =
|
|
11305
|
-
r(t), d(
|
|
11353
|
+
var t = le(i, e);
|
|
11354
|
+
r(t), d(Zu(t));
|
|
11306
11355
|
}
|
|
11307
11356
|
function v(e) {
|
|
11308
|
-
r(
|
|
11357
|
+
r(pe(i, e.clientId, e));
|
|
11309
11358
|
}
|
|
11310
11359
|
function y(e) {
|
|
11311
|
-
r(
|
|
11360
|
+
r(fe(i, e.clientId, e));
|
|
11312
11361
|
}
|
|
11313
11362
|
function b(e) {
|
|
11314
|
-
r(
|
|
11363
|
+
r(me(i, e));
|
|
11315
11364
|
}
|
|
11316
11365
|
function x(e) {
|
|
11317
|
-
r(
|
|
11366
|
+
r(he(i, e));
|
|
11318
11367
|
}
|
|
11319
11368
|
return (0, t.jsx)("section", {
|
|
11320
|
-
className:
|
|
11369
|
+
className: hu.root,
|
|
11321
11370
|
children: (0, t.jsx)("div", {
|
|
11322
11371
|
className: Q.shell,
|
|
11323
11372
|
children: (0, t.jsxs)("div", {
|
|
11324
11373
|
className: Q.grid,
|
|
11325
|
-
children: [(0, t.jsx)(
|
|
11374
|
+
children: [(0, t.jsx)(Au, {
|
|
11326
11375
|
addedExtraTypes: i.extras.map(function (e) {
|
|
11327
11376
|
return e.type;
|
|
11328
11377
|
}),
|
|
11329
11378
|
labels: l,
|
|
11330
11379
|
onAddElement: m,
|
|
11331
11380
|
onAddExtra: h
|
|
11332
|
-
}), (0, t.jsx)(
|
|
11381
|
+
}), (0, t.jsx)(ku, {
|
|
11333
11382
|
elements: i.elements,
|
|
11334
11383
|
extras: i.extras,
|
|
11335
11384
|
labels: l,
|
|
11336
11385
|
onDeleteElement: g,
|
|
11337
11386
|
onDeleteExtra: _,
|
|
11338
11387
|
onMoveElement: function onMoveElement(e, t) {
|
|
11339
|
-
return r(
|
|
11388
|
+
return r(de(i, e, t));
|
|
11340
11389
|
},
|
|
11341
11390
|
onSelectElement: d,
|
|
11342
11391
|
selectedElementClientId: (s = (c = f == null ? void 0 : f.clientId) == null ? p == null ? void 0 : p.clientId : c) == null ? null : s
|
|
11343
|
-
}), (0, t.jsx)(
|
|
11392
|
+
}), (0, t.jsx)(zu, {
|
|
11344
11393
|
description: i.description,
|
|
11345
11394
|
globalConfig: i.globalConfig,
|
|
11346
11395
|
isSubjective: i.isSubjective,
|
|
@@ -11356,7 +11405,7 @@ function Gu(_ref171) {
|
|
|
11356
11405
|
})
|
|
11357
11406
|
});
|
|
11358
11407
|
}
|
|
11359
|
-
function
|
|
11408
|
+
function Xu(e, t) {
|
|
11360
11409
|
var n, r, i, a;
|
|
11361
11410
|
var o = (n = e.elements.find(function (e) {
|
|
11362
11411
|
return e.clientId === t;
|
|
@@ -11372,8 +11421,8 @@ function Ku(e, t) {
|
|
|
11372
11421
|
selectedExtra: e.elements[0] || (a = e.extras[0]) == null ? null : a
|
|
11373
11422
|
};
|
|
11374
11423
|
}
|
|
11375
|
-
function
|
|
11424
|
+
function Zu(e) {
|
|
11376
11425
|
var t, n, r, i;
|
|
11377
11426
|
return (t = (n = (r = e.elements[0]) == null ? void 0 : r.clientId) == null ? (i = e.extras[0]) == null ? void 0 : i.clientId : n) == null ? null : t;
|
|
11378
11427
|
}
|
|
11379
|
-
exports.QuestionContentEditor = qo, exports.QuestionPlayer =
|
|
11428
|
+
exports.QuestionContentEditor = qo, exports.QuestionPlayer = Rl, exports.QuestionPreview = uu, exports.QuestionRichContentView = G, exports.QuestionStructureEditor = Yu, exports.addBlankToGroup = Fn, exports.alignQuestionContentDraftWithStructure = ln, exports.assignBlankToAnswerGroup = Rn, exports.cn = Ba, exports.createBlankAnswerGroupWithBlank = zn, exports.createEmptyQuestionContentDraft = zt, exports.createEmptyQuestionPlayerResponse = Ps, exports.createEmptyQuestionStructureDraft = ie, exports.createQuestionContentDraftFromSerialized = cn, exports.createQuestionContentId = g, exports.createQuestionContentStructureFromDraft = Xo, exports.createQuestionPreviewDraft = Zo, exports.createQuestionStructureElement = oe, exports.createQuestionStructureExtra = ae, exports.createRichContentValue = O, exports.createRichContentValueFromDocument = Wt, exports.createRichTextContent = Te, exports.deleteBlankFromGroup = In, exports.deleteQuestionStructureElement = ue, exports.deleteQuestionStructureExtra = le, exports.detachBlankFromAnswerGroup = Bn, exports.findQuestionContentQuestionTypeStructure = Yi, exports.findQuestionContentQuestionTypeTemplate = $i, exports.getQuestionContentJudgementOptions = en, exports.getQuestionContentOptionMarker = Zt, exports.getQuestionContentTextMarkerAnswerText = qt, exports.getQuestionStructureDraftChangeKind = $o, exports.getQuestionStructureElementDefaultEnName = D, exports.getQuestionStructureElementDefaultName = E, exports.getQuestionStructureExtraDefaultEnName = _e, exports.getQuestionStructureExtraDefaultName = ge, exports.getRichContentDocument = Jt, exports.getSharedBlankAnswerGroups = Ln, exports.isCompositeQuestionContentStructure = Rt, exports.isQuestionContentDraftEmpty = on, exports.moveQuestionStructureElement = de, exports.normalizeFillTextCandidateState = vn, exports.normalizeRichTextContent = Ee, exports.questionStructureElementTypes = ee, exports.questionStructureExtraTypes = w, exports.reconcileQuestionContentDraftWithTemplates = ea, exports.serializeQuestionContentDraft = sn, exports.serializeQuestionStructureDraft = Qo, exports.updateQuestionStructureElement = pe, exports.updateQuestionStructureExtra = fe, exports.updateQuestionStructureGlobalConfig = me, exports.updateQuestionStructureMetadata = he;
|