@pie-element/drag-in-the-blank 3.9.0 → 3.9.1-beta.587
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/CHANGELOG.md +513 -0
- package/configure/CHANGELOG.md +421 -0
- package/configure/lib/choice.js +28 -21
- package/configure/lib/choice.js.map +1 -1
- package/configure/lib/choices.js +118 -65
- package/configure/lib/choices.js.map +1 -1
- package/configure/lib/defaults.js +24 -2
- package/configure/lib/defaults.js.map +1 -1
- package/configure/lib/index.js +20 -6
- package/configure/lib/index.js.map +1 -1
- package/configure/lib/main.js +150 -33
- package/configure/lib/main.js.map +1 -1
- package/configure/lib/markupUtils.js +9 -3
- package/configure/lib/markupUtils.js.map +1 -1
- package/configure/package.json +26 -8
- package/configure/utils.js +17 -0
- package/controller/CHANGELOG.md +91 -0
- package/controller/lib/index.js +45 -3
- package/controller/lib/index.js.map +1 -1
- package/controller/lib/utils.js +1 -1
- package/controller/lib/utils.js.map +1 -1
- package/controller/package.json +2 -2
- package/docs/config-schema.json +115 -0
- package/docs/config-schema.json.md +89 -1
- package/docs/demo/config.js +2 -2
- package/docs/demo/generate.js +30 -27
- package/docs/pie-schema.json +49 -0
- package/docs/pie-schema.json.md +39 -0
- package/lib/index.js +6 -2
- package/lib/index.js.map +1 -1
- package/lib/main.js +18 -31
- package/lib/main.js.map +1 -1
- package/package.json +9 -7
package/configure/lib/main.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard");
|
|
4
|
-
|
|
5
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
6
4
|
|
|
5
|
+
var _typeof = require("@babel/runtime/helpers/typeof");
|
|
6
|
+
|
|
7
7
|
Object.defineProperty(exports, "__esModule", {
|
|
8
8
|
value: true
|
|
9
9
|
});
|
|
@@ -41,17 +41,27 @@ var _styles = require("@material-ui/core/styles");
|
|
|
41
41
|
|
|
42
42
|
var _Typography = _interopRequireDefault(require("@material-ui/core/Typography"));
|
|
43
43
|
|
|
44
|
+
var _Info = _interopRequireDefault(require("@material-ui/icons/Info"));
|
|
45
|
+
|
|
46
|
+
var _Tooltip = _interopRequireDefault(require("@material-ui/core/Tooltip"));
|
|
47
|
+
|
|
44
48
|
var _choices = _interopRequireDefault(require("./choices"));
|
|
45
49
|
|
|
46
50
|
var _markupUtils = require("./markupUtils");
|
|
47
51
|
|
|
48
|
-
|
|
52
|
+
var _utils = require("../utils");
|
|
53
|
+
|
|
54
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
49
55
|
|
|
50
|
-
function
|
|
56
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
57
|
+
|
|
58
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
59
|
+
|
|
60
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2["default"])(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
51
61
|
|
|
52
62
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2["default"])(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2["default"])(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2["default"])(this, result); }; }
|
|
53
63
|
|
|
54
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try {
|
|
64
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
55
65
|
|
|
56
66
|
var dropdown = _configUi.settings.dropdown,
|
|
57
67
|
toggle = _configUi.settings.toggle,
|
|
@@ -92,9 +102,23 @@ var styles = function styles(theme) {
|
|
|
92
102
|
},
|
|
93
103
|
text: {
|
|
94
104
|
fontFamily: 'Cerebri Sans',
|
|
95
|
-
fontSize:
|
|
105
|
+
fontSize: theme.typography.fontSize + 2,
|
|
96
106
|
lineHeight: '19px',
|
|
97
107
|
color: '#495B8F'
|
|
108
|
+
},
|
|
109
|
+
tooltip: {
|
|
110
|
+
fontSize: theme.typography.fontSize - 2,
|
|
111
|
+
whiteSpace: 'pre',
|
|
112
|
+
maxWidth: '500px'
|
|
113
|
+
},
|
|
114
|
+
errorText: {
|
|
115
|
+
fontSize: theme.typography.fontSize - 2,
|
|
116
|
+
color: 'red',
|
|
117
|
+
paddingTop: theme.spacing.unit
|
|
118
|
+
},
|
|
119
|
+
flexContainer: {
|
|
120
|
+
display: 'flex',
|
|
121
|
+
alignItems: 'end'
|
|
98
122
|
}
|
|
99
123
|
};
|
|
100
124
|
};
|
|
@@ -170,7 +194,8 @@ var Main = /*#__PURE__*/function (_React$Component) {
|
|
|
170
194
|
model = _this$props.model,
|
|
171
195
|
configuration = _this$props.configuration,
|
|
172
196
|
onConfigurationChanged = _this$props.onConfigurationChanged,
|
|
173
|
-
imageSupport = _this$props.imageSupport
|
|
197
|
+
imageSupport = _this$props.imageSupport,
|
|
198
|
+
uploadSoundSupport = _this$props.uploadSoundSupport;
|
|
174
199
|
|
|
175
200
|
var _ref = configuration || {},
|
|
176
201
|
_ref$duplicates = _ref.duplicates,
|
|
@@ -186,16 +211,55 @@ var Main = /*#__PURE__*/function (_React$Component) {
|
|
|
186
211
|
_ref$teacherInstructi = _ref.teacherInstructions,
|
|
187
212
|
teacherInstructions = _ref$teacherInstructi === void 0 ? {} : _ref$teacherInstructi,
|
|
188
213
|
_ref$choicesPosition = _ref.choicesPosition,
|
|
189
|
-
choicesPosition = _ref$choicesPosition === void 0 ? {} : _ref$choicesPosition
|
|
214
|
+
choicesPosition = _ref$choicesPosition === void 0 ? {} : _ref$choicesPosition,
|
|
215
|
+
_ref$spellCheck = _ref.spellCheck,
|
|
216
|
+
spellCheck = _ref$spellCheck === void 0 ? {} : _ref$spellCheck,
|
|
217
|
+
settingsPanelDisabled = _ref.settingsPanelDisabled,
|
|
218
|
+
maxChoices = _ref.maxChoices,
|
|
219
|
+
maxResponseAreas = _ref.maxResponseAreas,
|
|
220
|
+
_ref$maxImageWidth = _ref.maxImageWidth,
|
|
221
|
+
maxImageWidth = _ref$maxImageWidth === void 0 ? {} : _ref$maxImageWidth,
|
|
222
|
+
_ref$maxImageHeight = _ref.maxImageHeight,
|
|
223
|
+
maxImageHeight = _ref$maxImageHeight === void 0 ? {} : _ref$maxImageHeight,
|
|
224
|
+
_ref$withRubric = _ref.withRubric,
|
|
225
|
+
withRubric = _ref$withRubric === void 0 ? {} : _ref$withRubric;
|
|
190
226
|
|
|
191
227
|
var _ref2 = model || {},
|
|
192
228
|
rationaleEnabled = _ref2.rationaleEnabled,
|
|
193
229
|
promptEnabled = _ref2.promptEnabled,
|
|
194
|
-
teacherInstructionsEnabled = _ref2.teacherInstructionsEnabled
|
|
195
|
-
|
|
230
|
+
teacherInstructionsEnabled = _ref2.teacherInstructionsEnabled,
|
|
231
|
+
spellCheckEnabled = _ref2.spellCheckEnabled,
|
|
232
|
+
toolbarEditorPosition = _ref2.toolbarEditorPosition,
|
|
233
|
+
errors = _ref2.errors;
|
|
234
|
+
|
|
235
|
+
var _ref3 = errors || {},
|
|
236
|
+
responseAreasError = _ref3.responseAreasError,
|
|
237
|
+
choicesError = _ref3.choicesError,
|
|
238
|
+
correctResponseError = _ref3.correctResponseError;
|
|
239
|
+
|
|
240
|
+
var validationMessage = (0, _utils.generateValidationMessage)(configuration);
|
|
241
|
+
var defaultImageMaxWidth = maxImageWidth && maxImageWidth.prompt;
|
|
242
|
+
var defaultImageMaxHeight = maxImageHeight && maxImageHeight.prompt;
|
|
243
|
+
var toolbarOpts = {
|
|
244
|
+
position: toolbarEditorPosition === 'top' ? 'top' : 'bottom'
|
|
245
|
+
};
|
|
246
|
+
var panelSettings = {
|
|
247
|
+
partialScoring: partialScoring.settings && toggle(partialScoring.label),
|
|
248
|
+
duplicates: duplicates.settings && toggle(duplicates.label),
|
|
249
|
+
lockChoiceOrder: lockChoiceOrder.settings && toggle(lockChoiceOrder.label),
|
|
250
|
+
choicesPosition: choicesPosition.settings && dropdown(choicesPosition.label, ['above', 'below', 'left', 'right'])
|
|
251
|
+
};
|
|
252
|
+
var panelProperties = {
|
|
253
|
+
teacherInstructionsEnabled: teacherInstructions.settings && toggle(teacherInstructions.label),
|
|
254
|
+
rationaleEnabled: rationale.settings && toggle(rationale.label),
|
|
255
|
+
spellCheckEnabled: spellCheck.settings && toggle(spellCheck.label),
|
|
256
|
+
promptEnabled: prompt.settings && toggle(prompt.label),
|
|
257
|
+
rubricEnabled: (withRubric === null || withRubric === void 0 ? void 0 : withRubric.settings) && toggle(withRubric === null || withRubric === void 0 ? void 0 : withRubric.label)
|
|
258
|
+
};
|
|
196
259
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
197
260
|
className: classes.design
|
|
198
261
|
}, /*#__PURE__*/_react["default"].createElement(_configUi.layout.ConfigLayout, {
|
|
262
|
+
hideSettings: settingsPanelDisabled,
|
|
199
263
|
settings: /*#__PURE__*/_react["default"].createElement(Panel, {
|
|
200
264
|
model: model,
|
|
201
265
|
configuration: configuration,
|
|
@@ -206,17 +270,8 @@ var Main = /*#__PURE__*/function (_React$Component) {
|
|
|
206
270
|
return onConfigurationChanged(configuration, true);
|
|
207
271
|
},
|
|
208
272
|
groups: {
|
|
209
|
-
Settings:
|
|
210
|
-
|
|
211
|
-
duplicates: duplicates.settings && toggle(duplicates.label),
|
|
212
|
-
lockChoiceOrder: lockChoiceOrder.settings && toggle(lockChoiceOrder.label),
|
|
213
|
-
choicesPosition: choicesPosition.settings && dropdown(choicesPosition.label, ['above', 'below', 'left', 'right'])
|
|
214
|
-
},
|
|
215
|
-
Properties: {
|
|
216
|
-
teacherInstructionsEnabled: teacherInstructions.settings && toggle(teacherInstructions.label),
|
|
217
|
-
rationaleEnabled: rationale.settings && toggle(rationale.label),
|
|
218
|
-
promptEnabled: prompt.settings && toggle(prompt.label)
|
|
219
|
-
}
|
|
273
|
+
Settings: panelSettings,
|
|
274
|
+
Properties: panelProperties
|
|
220
275
|
}
|
|
221
276
|
})
|
|
222
277
|
}, /*#__PURE__*/_react["default"].createElement("div", null, teacherInstructionsEnabled && /*#__PURE__*/_react["default"].createElement(_configUi.InputContainer, {
|
|
@@ -227,7 +282,17 @@ var Main = /*#__PURE__*/function (_React$Component) {
|
|
|
227
282
|
markup: model.teacherInstructions || '',
|
|
228
283
|
onChange: this.onTeacherInstructionsChanged,
|
|
229
284
|
imageSupport: imageSupport,
|
|
230
|
-
nonEmpty: false
|
|
285
|
+
nonEmpty: false,
|
|
286
|
+
toolbarOpts: toolbarOpts,
|
|
287
|
+
spellCheck: spellCheckEnabled,
|
|
288
|
+
maxImageWidth: maxImageWidth && maxImageWidth.teacherInstructions || defaultImageMaxWidth,
|
|
289
|
+
maxImageHeight: maxImageHeight && maxImageHeight.teacherInstructions || defaultImageMaxHeight,
|
|
290
|
+
uploadSoundSupport: uploadSoundSupport,
|
|
291
|
+
languageCharactersProps: [{
|
|
292
|
+
language: 'spanish'
|
|
293
|
+
}, {
|
|
294
|
+
language: 'special'
|
|
295
|
+
}]
|
|
231
296
|
})), promptEnabled && /*#__PURE__*/_react["default"].createElement(_configUi.InputContainer, {
|
|
232
297
|
label: prompt.label,
|
|
233
298
|
className: classes.promptHolder
|
|
@@ -237,30 +302,72 @@ var Main = /*#__PURE__*/function (_React$Component) {
|
|
|
237
302
|
onChange: this.onPromptChanged,
|
|
238
303
|
imageSupport: imageSupport,
|
|
239
304
|
nonEmpty: false,
|
|
240
|
-
disableUnderline: true
|
|
241
|
-
|
|
305
|
+
disableUnderline: true,
|
|
306
|
+
toolbarOpts: toolbarOpts,
|
|
307
|
+
spellCheck: spellCheckEnabled,
|
|
308
|
+
maxImageWidth: defaultImageMaxWidth,
|
|
309
|
+
maxImageHeight: defaultImageMaxHeight,
|
|
310
|
+
uploadSoundSupport: uploadSoundSupport,
|
|
311
|
+
languageCharactersProps: [{
|
|
312
|
+
language: 'spanish'
|
|
313
|
+
}, {
|
|
314
|
+
language: 'special'
|
|
315
|
+
}]
|
|
316
|
+
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
317
|
+
className: classes.flexContainer
|
|
318
|
+
}, /*#__PURE__*/_react["default"].createElement(_Typography["default"], {
|
|
242
319
|
className: classes.text
|
|
243
|
-
}, "Define Template, Choices, and Correct Responses"), /*#__PURE__*/_react["default"].createElement(
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
position: 'top'
|
|
320
|
+
}, "Define Template, Choices, and Correct Responses"), /*#__PURE__*/_react["default"].createElement(_Tooltip["default"], {
|
|
321
|
+
classes: {
|
|
322
|
+
tooltip: classes.tooltip
|
|
247
323
|
},
|
|
324
|
+
disableFocusListener: true,
|
|
325
|
+
disableTouchListener: true,
|
|
326
|
+
placement: 'right',
|
|
327
|
+
title: validationMessage
|
|
328
|
+
}, /*#__PURE__*/_react["default"].createElement(_Info["default"], {
|
|
329
|
+
fontSize: 'small',
|
|
330
|
+
color: 'primary',
|
|
331
|
+
style: {
|
|
332
|
+
marginLeft: '5px'
|
|
333
|
+
}
|
|
334
|
+
}))), /*#__PURE__*/_react["default"].createElement(_editableHtml["default"], {
|
|
335
|
+
activePlugins: _editableHtml.ALL_PLUGINS,
|
|
248
336
|
responseAreaProps: {
|
|
249
337
|
type: 'drag-in-the-blank',
|
|
250
338
|
options: {
|
|
251
339
|
duplicates: model.duplicates
|
|
252
|
-
}
|
|
340
|
+
},
|
|
341
|
+
maxResponseAreas: maxResponseAreas
|
|
253
342
|
},
|
|
254
343
|
className: classes.markup,
|
|
255
344
|
markup: model.slateMarkup,
|
|
256
345
|
onChange: this.onMarkupChanged,
|
|
257
346
|
imageSupport: imageSupport,
|
|
347
|
+
disableImageAlignmentButtons: true,
|
|
258
348
|
nonEmpty: false,
|
|
259
|
-
disableUnderline: true
|
|
260
|
-
|
|
349
|
+
disableUnderline: true,
|
|
350
|
+
error: responseAreasError || correctResponseError,
|
|
351
|
+
toolbarOpts: toolbarOpts,
|
|
352
|
+
spellCheck: spellCheckEnabled,
|
|
353
|
+
uploadSoundSupport: uploadSoundSupport,
|
|
354
|
+
languageCharactersProps: [{
|
|
355
|
+
language: 'spanish'
|
|
356
|
+
}, {
|
|
357
|
+
language: 'special'
|
|
358
|
+
}]
|
|
359
|
+
}), responseAreasError && /*#__PURE__*/_react["default"].createElement("div", {
|
|
360
|
+
className: classes.errorText
|
|
361
|
+
}, responseAreasError), correctResponseError && /*#__PURE__*/_react["default"].createElement("div", {
|
|
362
|
+
className: classes.errorText
|
|
363
|
+
}, correctResponseError), /*#__PURE__*/_react["default"].createElement(_choices["default"], {
|
|
261
364
|
model: model,
|
|
262
365
|
duplicates: model.duplicates,
|
|
263
|
-
|
|
366
|
+
error: choicesError,
|
|
367
|
+
onChange: this.onResponsesChanged,
|
|
368
|
+
toolbarOpts: toolbarOpts,
|
|
369
|
+
maxChoices: maxChoices,
|
|
370
|
+
uploadSoundSupport: uploadSoundSupport
|
|
264
371
|
}), rationaleEnabled && /*#__PURE__*/_react["default"].createElement(_configUi.InputContainer, {
|
|
265
372
|
label: rationale.label,
|
|
266
373
|
className: classes.promptHolder
|
|
@@ -268,7 +375,17 @@ var Main = /*#__PURE__*/function (_React$Component) {
|
|
|
268
375
|
className: classes.prompt,
|
|
269
376
|
markup: model.rationale || '',
|
|
270
377
|
onChange: this.onRationaleChanged,
|
|
271
|
-
imageSupport: imageSupport
|
|
378
|
+
imageSupport: imageSupport,
|
|
379
|
+
toolbarOpts: toolbarOpts,
|
|
380
|
+
spellCheck: spellCheckEnabled,
|
|
381
|
+
maxImageWidth: maxImageWidth && maxImageWidth.rationale || defaultImageMaxWidth,
|
|
382
|
+
maxImageHeight: maxImageHeight && maxImageHeight.rationale || defaultImageMaxHeight,
|
|
383
|
+
uploadSoundSupport: uploadSoundSupport,
|
|
384
|
+
languageCharactersProps: [{
|
|
385
|
+
language: 'spanish'
|
|
386
|
+
}, {
|
|
387
|
+
language: 'special'
|
|
388
|
+
}]
|
|
272
389
|
})))));
|
|
273
390
|
}
|
|
274
391
|
}]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/main.jsx"],"names":["dropdown","settings","toggle","Panel","styles","theme","promptHolder","width","paddingBottom","spacing","unit","marginBottom","prompt","paddingTop","markup","minHeight","design","choiceConfiguration","switchElement","justifyContent","margin","addButton","text","fontFamily","fontSize","lineHeight","color","Main","newVal","props","onModelChanged","model","rationale","teacherInstructions","slateMarkup","choices","correctResponse","domNode","ReactDOM","findDOMNode","classes","configuration","onConfigurationChanged","imageSupport","duplicates","partialScoring","lockChoiceOrder","choicesPosition","rationaleEnabled","promptEnabled","teacherInstructionsEnabled","onModelChange","Settings","label","Properties","onTeacherInstructionsChanged","onPromptChanged","ALL_PLUGINS","position","type","options","onMarkupChanged","onResponsesChanged","onRationaleChanged","React","Component","PropTypes","object","isRequired","disableSidePanel","bool","func","shape","add","Styled"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AAEA;;AACA;;;;;;;;;;IACQA,Q,GAA4BC,kB,CAA5BD,Q;IAAUE,M,GAAkBD,kB,CAAlBC,M;IAAQC,K,GAAUF,kB,CAAVE,K;;AAE1B,IAAMC,MAAM,GAAG,SAATA,MAAS,CAAAC,KAAK;AAAA,SAAK;AACvBC,IAAAA,YAAY,EAAE;AACZC,MAAAA,KAAK,EAAE,MADK;AAEZC,MAAAA,aAAa,EAAEH,KAAK,CAACI,OAAN,CAAcC,IAAd,GAAqB,CAFxB;AAGZC,MAAAA,YAAY,EAAEN,KAAK,CAACI,OAAN,CAAcC,IAAd,GAAqB;AAHvB,KADS;AAMvBE,IAAAA,MAAM,EAAE;AACNC,MAAAA,UAAU,EAAER,KAAK,CAACI,OAAN,CAAcC,IAAd,GAAqB,CAD3B;AAENH,MAAAA,KAAK,EAAE;AAFD,KANe;AAUvBO,IAAAA,MAAM,EAAE;AACNC,MAAAA,SAAS,EAAE,OADL;AAENF,MAAAA,UAAU,EAAER,KAAK,CAACI,OAAN,CAAcC,IAAd,GAAqB,CAF3B;AAGNH,MAAAA,KAAK,EAAE,MAHD;AAIN,sCAAgC;AAC9B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uB,sBAAUM,KAAV,CAAgB;AAC5BC,IAAAA,GAAG,EAAEP,sBAAUK,IAAV,CAAeH,UADQ;AAE5B,cAAQF,sBAAUK,IAAV,CAAeH;AAFK,GAAhB;AAPG,C;AA2MrB,IAAMM,MAAM,GAAG,wBAAWtE,MAAX,EAAmBuB,IAAnB,CAAf;;eAEe,2BAAgB+C,MAAhB,C","sourcesContent":["import React from 'react';\nimport ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport EditableHtml, { ALL_PLUGINS } from '@pie-lib/editable-html';\nimport { InputContainer, layout, settings } from '@pie-lib/config-ui';\nimport { withDragContext } from '@pie-lib/drag';\nimport { renderMath } from '@pie-lib/math-rendering';\nimport { withStyles } from '@material-ui/core/styles';\nimport Typography from '@material-ui/core/Typography';\n\nimport Choices from './choices';\nimport { createSlateMarkup } from './markupUtils';\nconst { dropdown, toggle, Panel } = settings;\n\nconst styles = theme => ({\n promptHolder: {\n width: '100%',\n paddingBottom: theme.spacing.unit * 2,\n marginBottom: theme.spacing.unit * 2\n },\n prompt: {\n paddingTop: theme.spacing.unit * 2,\n width: '100%'\n },\n markup: {\n minHeight: '235px',\n paddingTop: theme.spacing.unit * 2,\n width: '100%',\n '& [data-slate-editor=\"true\"]': {\n minHeight: '235px'\n }\n },\n design: {\n paddingTop: theme.spacing.unit * 3\n },\n choiceConfiguration: {\n paddingTop: theme.spacing.unit * 2,\n paddingBottom: theme.spacing.unit * 2\n },\n switchElement: {\n justifyContent: 'space-between',\n margin: 0\n },\n addButton: {\n float: 'right'\n },\n text: {\n fontFamily: 'Cerebri Sans',\n fontSize: '16px',\n lineHeight: '19px',\n color: '#495B8F'\n }\n});\n\nexport class Main extends React.Component {\n static propTypes = {\n configuration: PropTypes.object.isRequired,\n model: PropTypes.object.isRequired,\n disableSidePanel: PropTypes.bool,\n onModelChanged: PropTypes.func.isRequired,\n onConfigurationChanged: PropTypes.func.isRequired,\n classes: PropTypes.object.isRequired,\n imageSupport: PropTypes.shape({\n add: PropTypes.func.isRequired,\n delete: PropTypes.func.isRequired\n })\n };\n\n state = {};\n\n componentDidUpdate() {\n // eslint-disable-next-line\n const domNode = ReactDOM.findDOMNode(this);\n\n renderMath(domNode);\n }\n\n onModelChange = newVal => {\n this.props.onModelChanged({\n ...this.props.model,\n ...newVal\n });\n };\n\n onPromptChanged = prompt => {\n this.props.onModelChanged({\n ...this.props.model,\n prompt\n });\n };\n\n onRationaleChanged = rationale => {\n this.props.onModelChanged({\n ...this.props.model,\n rationale\n });\n };\n\n onTeacherInstructionsChanged = teacherInstructions => {\n this.props.onModelChanged({\n ...this.props.model,\n teacherInstructions\n });\n };\n\n onMarkupChanged = slateMarkup => {\n this.props.onModelChanged({\n ...this.props.model,\n slateMarkup\n });\n };\n\n onResponsesChanged = choices => {\n const {\n model: { correctResponse, markup }\n } = this.props;\n const slateMarkup = createSlateMarkup(markup, choices, correctResponse);\n\n this.props.onModelChanged({\n ...this.props.model,\n slateMarkup,\n choices\n });\n };\n\n render() {\n const {\n classes,\n model,\n configuration,\n onConfigurationChanged,\n imageSupport\n } = this.props;\n const {\n duplicates = {},\n prompt = {},\n partialScoring = {},\n lockChoiceOrder = {},\n rationale = {},\n teacherInstructions = {},\n choicesPosition = {}\n } = configuration || {};\n const { rationaleEnabled, promptEnabled, teacherInstructionsEnabled } =\n model || {};\n\n return (\n <div className={classes.design}>\n <layout.ConfigLayout\n settings={\n <Panel\n model={model}\n configuration={configuration}\n onChangeModel={model => this.onModelChange(model)}\n onChangeConfiguration={configuration =>\n onConfigurationChanged(configuration, true)\n }\n groups={{\n Settings: {\n partialScoring:\n partialScoring.settings && toggle(partialScoring.label),\n duplicates: duplicates.settings && toggle(duplicates.label),\n lockChoiceOrder:\n lockChoiceOrder.settings && toggle(lockChoiceOrder.label),\n choicesPosition:\n choicesPosition.settings &&\n dropdown(choicesPosition.label, [\n 'above',\n 'below',\n 'left',\n 'right'\n ])\n },\n Properties: {\n teacherInstructionsEnabled:\n teacherInstructions.settings &&\n toggle(teacherInstructions.label),\n rationaleEnabled:\n rationale.settings && toggle(rationale.label),\n promptEnabled: prompt.settings && toggle(prompt.label)\n }\n }}\n />\n }\n >\n <div>\n {teacherInstructionsEnabled && (\n <InputContainer\n label={teacherInstructions.label}\n className={classes.promptHolder}\n >\n <EditableHtml\n className={classes.prompt}\n markup={model.teacherInstructions || ''}\n onChange={this.onTeacherInstructionsChanged}\n imageSupport={imageSupport}\n nonEmpty={false}\n />\n </InputContainer>\n )}\n {promptEnabled && (\n <InputContainer\n label={prompt.label}\n className={classes.promptHolder}\n >\n <EditableHtml\n className={classes.prompt}\n markup={model.prompt}\n onChange={this.onPromptChanged}\n imageSupport={imageSupport}\n nonEmpty={false}\n disableUnderline\n />\n </InputContainer>\n )}\n <Typography className={classes.text}>\n Define Template, Choices, and Correct Responses\n </Typography>\n <EditableHtml\n activePlugins={ALL_PLUGINS}\n toolbarOpts={{ position: 'top' }}\n responseAreaProps={{\n type: 'drag-in-the-blank',\n options: {\n duplicates: model.duplicates\n }\n }}\n className={classes.markup}\n markup={model.slateMarkup}\n onChange={this.onMarkupChanged}\n imageSupport={imageSupport}\n nonEmpty={false}\n disableUnderline\n />\n <Choices\n model={model}\n duplicates={model.duplicates}\n onChange={this.onResponsesChanged}\n />\n {rationaleEnabled && (\n <InputContainer\n label={rationale.label}\n className={classes.promptHolder}\n >\n <EditableHtml\n className={classes.prompt}\n markup={model.rationale || ''}\n onChange={this.onRationaleChanged}\n imageSupport={imageSupport}\n />\n </InputContainer>\n )}\n </div>\n </layout.ConfigLayout>\n </div>\n );\n }\n}\n\nconst Styled = withStyles(styles)(Main);\n\nexport default withDragContext(Styled);\n"],"file":"main.js"}
|
|
1
|
+
{"version":3,"sources":["../src/main.jsx"],"names":["dropdown","settings","toggle","Panel","styles","theme","promptHolder","width","paddingBottom","spacing","unit","marginBottom","prompt","paddingTop","markup","minHeight","design","choiceConfiguration","switchElement","justifyContent","margin","addButton","text","fontFamily","fontSize","typography","lineHeight","color","tooltip","whiteSpace","maxWidth","errorText","flexContainer","display","alignItems","Main","newVal","props","onModelChanged","model","rationale","teacherInstructions","slateMarkup","choices","correctResponse","domNode","ReactDOM","findDOMNode","classes","configuration","onConfigurationChanged","imageSupport","uploadSoundSupport","duplicates","partialScoring","lockChoiceOrder","choicesPosition","spellCheck","settingsPanelDisabled","maxChoices","maxResponseAreas","maxImageWidth","maxImageHeight","withRubric","rationaleEnabled","promptEnabled","teacherInstructionsEnabled","spellCheckEnabled","toolbarEditorPosition","errors","responseAreasError","choicesError","correctResponseError","validationMessage","defaultImageMaxWidth","defaultImageMaxHeight","toolbarOpts","position","panelSettings","label","panelProperties","rubricEnabled","onModelChange","Settings","Properties","onTeacherInstructionsChanged","language","onPromptChanged","marginLeft","ALL_PLUGINS","type","options","onMarkupChanged","onResponsesChanged","onRationaleChanged","React","Component","PropTypes","object","isRequired","disableSidePanel","bool","func","shape","add","Styled"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AAEA;;AACA;;AACA;;;;;;;;;;;;;;AACA,IAAQA,QAAR,GAAoCC,kBAApC,CAAQD,QAAR;AAAA,IAAkBE,MAAlB,GAAoCD,kBAApC,CAAkBC,MAAlB;AAAA,IAA0BC,KAA1B,GAAoCF,kBAApC,CAA0BE,KAA1B;;AAEA,IAAMC,MAAM,GAAG,SAATA,MAAS,CAACC,KAAD;AAAA,SAAY;AACzBC,IAAAA,YAAY,EAAE;AACZC,MAAAA,KAAK,EAAE,MADK;AAEZC,MAAAA,aAAa,EAAEH,KAAK,CAACI,OAAN,CAAcC,IAAd,GAAqB,CAFxB;AAGZC,MAAAA,YAAY,EAAEN,KAAK,CAACI,OAAN,CAAcC,IAAd,GAAqB;AAHvB,KADW;AAMzBE,IAAAA,MAAM,EAAE;AACNC,MAAAA,UAAU,EAAER,KAAK,CAACI,OAAN,CAAcC,IAAd,GAAqB,CAD3B;AAENH,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HD;;;EAtPuBS,kBAAMC,S;;;iCAAnB7D,I,eACQ;AACjBc,EAAAA,aAAa,EAAEgD,sBAAUC,MAAV,CAAiBC,UADf;AAEjB5D,EAAAA,KAAK,EAAE0D,sBAAUC,MAAV,CAAiBC,UAFP;AAGjBC,EAAAA,gBAAgB,EAAEH,sBAAUI,IAHX;AAIjB/D,EAAAA,cAAc,EAAE2D,sBAAUK,IAAV,CAAeH,UAJd;AAKjBjD,EAAAA,sBAAsB,EAAE+C,sBAAUK,IAAV,CAAeH,UALtB;AAMjBnD,EAAAA,OAAO,EAAEiD,sBAAUC,MAAV,CAAiBC,UANT;AAOjBhD,EAAAA,YAAY,EAAE8C,sBAAUM,KAAV,CAAgB;AAC5BC,IAAAA,GAAG,EAAEP,sBAAUK,IAAV,CAAeH,UADQ;AAE5B,cAAQF,sBAAUK,IAAV,CAAeH;AAFK,GAAhB;AAPG,C;AAwPrB,IAAMM,MAAM,GAAG,wBAAWrG,MAAX,EAAmB+B,IAAnB,CAAf;;eAEe,2BAAgBsE,MAAhB,C","sourcesContent":["import React from 'react';\nimport ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport EditableHtml, { ALL_PLUGINS } from '@pie-lib/editable-html';\nimport { InputContainer, layout, settings } from '@pie-lib/config-ui';\nimport { withDragContext } from '@pie-lib/drag';\nimport { renderMath } from '@pie-lib/math-rendering';\nimport { withStyles } from '@material-ui/core/styles';\nimport Typography from '@material-ui/core/Typography';\nimport Info from '@material-ui/icons/Info';\nimport Tooltip from '@material-ui/core/Tooltip';\n\nimport Choices from './choices';\nimport { createSlateMarkup } from './markupUtils';\nimport { generateValidationMessage } from '../utils';\nconst { dropdown, toggle, Panel } = settings;\n\nconst styles = (theme) => ({\n promptHolder: {\n width: '100%',\n paddingBottom: theme.spacing.unit * 2,\n marginBottom: theme.spacing.unit * 2,\n },\n prompt: {\n paddingTop: theme.spacing.unit * 2,\n width: '100%',\n },\n markup: {\n minHeight: '235px',\n paddingTop: theme.spacing.unit * 2,\n width: '100%',\n '& [data-slate-editor=\"true\"]': {\n minHeight: '235px',\n },\n },\n design: {\n paddingTop: theme.spacing.unit * 3,\n },\n choiceConfiguration: {\n paddingTop: theme.spacing.unit * 2,\n paddingBottom: theme.spacing.unit * 2,\n },\n switchElement: {\n justifyContent: 'space-between',\n margin: 0,\n },\n addButton: {\n float: 'right',\n },\n text: {\n fontFamily: 'Cerebri Sans',\n fontSize: theme.typography.fontSize + 2,\n lineHeight: '19px',\n color: '#495B8F',\n },\n tooltip: {\n fontSize: theme.typography.fontSize - 2,\n whiteSpace: 'pre',\n maxWidth: '500px',\n },\n errorText: {\n fontSize: theme.typography.fontSize - 2,\n color: 'red',\n paddingTop: theme.spacing.unit,\n },\n flexContainer: {\n display: 'flex',\n alignItems: 'end',\n },\n});\n\nexport class Main extends React.Component {\n static propTypes = {\n configuration: PropTypes.object.isRequired,\n model: PropTypes.object.isRequired,\n disableSidePanel: PropTypes.bool,\n onModelChanged: PropTypes.func.isRequired,\n onConfigurationChanged: PropTypes.func.isRequired,\n classes: PropTypes.object.isRequired,\n imageSupport: PropTypes.shape({\n add: PropTypes.func.isRequired,\n delete: PropTypes.func.isRequired,\n }),\n };\n\n state = {};\n\n componentDidUpdate() {\n // eslint-disable-next-line\n const domNode = ReactDOM.findDOMNode(this);\n\n renderMath(domNode);\n }\n\n onModelChange = (newVal) => {\n this.props.onModelChanged({\n ...this.props.model,\n ...newVal,\n });\n };\n\n onPromptChanged = (prompt) => {\n this.props.onModelChanged({\n ...this.props.model,\n prompt,\n });\n };\n\n onRationaleChanged = (rationale) => {\n this.props.onModelChanged({\n ...this.props.model,\n rationale,\n });\n };\n\n onTeacherInstructionsChanged = (teacherInstructions) => {\n this.props.onModelChanged({\n ...this.props.model,\n teacherInstructions,\n });\n };\n\n onMarkupChanged = (slateMarkup) => {\n this.props.onModelChanged({\n ...this.props.model,\n slateMarkup,\n });\n };\n\n onResponsesChanged = (choices) => {\n const {\n model: { correctResponse, markup },\n } = this.props;\n const slateMarkup = createSlateMarkup(markup, choices, correctResponse);\n\n this.props.onModelChanged({\n ...this.props.model,\n slateMarkup,\n choices,\n });\n };\n\n render() {\n const { classes, model, configuration, onConfigurationChanged, imageSupport, uploadSoundSupport } = this.props;\n const {\n duplicates = {},\n prompt = {},\n partialScoring = {},\n lockChoiceOrder = {},\n rationale = {},\n teacherInstructions = {},\n choicesPosition = {},\n spellCheck = {},\n settingsPanelDisabled,\n maxChoices,\n maxResponseAreas,\n maxImageWidth = {},\n maxImageHeight = {},\n withRubric = {},\n } = configuration || {};\n const {\n rationaleEnabled,\n promptEnabled,\n teacherInstructionsEnabled,\n spellCheckEnabled,\n toolbarEditorPosition,\n errors,\n } = model || {};\n\n const { responseAreasError, choicesError, correctResponseError } = errors || {};\n const validationMessage = generateValidationMessage(configuration);\n\n const defaultImageMaxWidth = maxImageWidth && maxImageWidth.prompt;\n const defaultImageMaxHeight = maxImageHeight && maxImageHeight.prompt;\n\n const toolbarOpts = {\n position: toolbarEditorPosition === 'top' ? 'top' : 'bottom',\n };\n\n const panelSettings = {\n partialScoring: partialScoring.settings && toggle(partialScoring.label),\n duplicates: duplicates.settings && toggle(duplicates.label),\n lockChoiceOrder: lockChoiceOrder.settings && toggle(lockChoiceOrder.label),\n choicesPosition: choicesPosition.settings && dropdown(choicesPosition.label, ['above', 'below', 'left', 'right']),\n };\n\n const panelProperties = {\n teacherInstructionsEnabled: teacherInstructions.settings && toggle(teacherInstructions.label),\n rationaleEnabled: rationale.settings && toggle(rationale.label),\n spellCheckEnabled: spellCheck.settings && toggle(spellCheck.label),\n promptEnabled: prompt.settings && toggle(prompt.label),\n rubricEnabled: withRubric?.settings && toggle(withRubric?.label),\n };\n\n return (\n <div className={classes.design}>\n <layout.ConfigLayout\n hideSettings={settingsPanelDisabled}\n settings={\n <Panel\n model={model}\n configuration={configuration}\n onChangeModel={(model) => this.onModelChange(model)}\n onChangeConfiguration={(configuration) => onConfigurationChanged(configuration, true)}\n groups={{\n Settings: panelSettings,\n Properties: panelProperties,\n }}\n />\n }\n >\n <div>\n {teacherInstructionsEnabled && (\n <InputContainer label={teacherInstructions.label} className={classes.promptHolder}>\n <EditableHtml\n className={classes.prompt}\n markup={model.teacherInstructions || ''}\n onChange={this.onTeacherInstructionsChanged}\n imageSupport={imageSupport}\n nonEmpty={false}\n toolbarOpts={toolbarOpts}\n spellCheck={spellCheckEnabled}\n maxImageWidth={(maxImageWidth && maxImageWidth.teacherInstructions) || defaultImageMaxWidth}\n maxImageHeight={(maxImageHeight && maxImageHeight.teacherInstructions) || defaultImageMaxHeight}\n uploadSoundSupport={uploadSoundSupport}\n languageCharactersProps={[{ language: 'spanish' }, { language: 'special' }]}\n />\n </InputContainer>\n )}\n\n {promptEnabled && (\n <InputContainer label={prompt.label} className={classes.promptHolder}>\n <EditableHtml\n className={classes.prompt}\n markup={model.prompt}\n onChange={this.onPromptChanged}\n imageSupport={imageSupport}\n nonEmpty={false}\n disableUnderline\n toolbarOpts={toolbarOpts}\n spellCheck={spellCheckEnabled}\n maxImageWidth={defaultImageMaxWidth}\n maxImageHeight={defaultImageMaxHeight}\n uploadSoundSupport={uploadSoundSupport}\n languageCharactersProps={[{ language: 'spanish' }, { language: 'special' }]}\n />\n </InputContainer>\n )}\n\n <div className={classes.flexContainer}>\n <Typography className={classes.text}>Define Template, Choices, and Correct Responses</Typography>\n <Tooltip\n classes={{ tooltip: classes.tooltip }}\n disableFocusListener\n disableTouchListener\n placement={'right'}\n title={validationMessage}\n >\n <Info fontSize={'small'} color={'primary'} style={{ marginLeft: '5px' }} />\n </Tooltip>\n </div>\n\n <EditableHtml\n activePlugins={ALL_PLUGINS}\n responseAreaProps={{\n type: 'drag-in-the-blank',\n options: {\n duplicates: model.duplicates,\n },\n maxResponseAreas: maxResponseAreas,\n }}\n className={classes.markup}\n markup={model.slateMarkup}\n onChange={this.onMarkupChanged}\n imageSupport={imageSupport}\n disableImageAlignmentButtons={true}\n nonEmpty={false}\n disableUnderline\n error={responseAreasError || correctResponseError}\n toolbarOpts={toolbarOpts}\n spellCheck={spellCheckEnabled}\n uploadSoundSupport={uploadSoundSupport}\n languageCharactersProps={[{ language: 'spanish' }, { language: 'special' }]}\n />\n {responseAreasError && <div className={classes.errorText}>{responseAreasError}</div>}\n {correctResponseError && <div className={classes.errorText}>{correctResponseError}</div>}\n\n <Choices\n model={model}\n duplicates={model.duplicates}\n error={choicesError}\n onChange={this.onResponsesChanged}\n toolbarOpts={toolbarOpts}\n maxChoices={maxChoices}\n uploadSoundSupport={uploadSoundSupport}\n />\n\n {rationaleEnabled && (\n <InputContainer label={rationale.label} className={classes.promptHolder}>\n <EditableHtml\n className={classes.prompt}\n markup={model.rationale || ''}\n onChange={this.onRationaleChanged}\n imageSupport={imageSupport}\n toolbarOpts={toolbarOpts}\n spellCheck={spellCheckEnabled}\n maxImageWidth={(maxImageWidth && maxImageWidth.rationale) || defaultImageMaxWidth}\n maxImageHeight={(maxImageHeight && maxImageHeight.rationale) || defaultImageMaxHeight}\n uploadSoundSupport={uploadSoundSupport}\n languageCharactersProps={[{ language: 'spanish' }, { language: 'special' }]}\n />\n </InputContainer>\n )}\n </div>\n </layout.ConfigLayout>\n </div>\n );\n }\n}\n\nconst Styled = withStyles(styles)(Main);\n\nexport default withDragContext(Styled);\n"],"file":"main.js"}
|
|
@@ -5,7 +5,7 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
-
exports.
|
|
8
|
+
exports.removeUnwantedCharacters = exports.processMarkup = exports.createSlateMarkup = exports.createElementFromHTML = exports.choiceIsEmpty = void 0;
|
|
9
9
|
|
|
10
10
|
var _escape = _interopRequireDefault(require("lodash/escape"));
|
|
11
11
|
|
|
@@ -15,12 +15,18 @@ var createElementFromHTML = function createElementFromHTML(htmlString) {
|
|
|
15
15
|
var div = document.createElement('div');
|
|
16
16
|
div.innerHTML = htmlString.trim();
|
|
17
17
|
return div;
|
|
18
|
-
};
|
|
18
|
+
}; // do not remove \t from \times, \triangle, \tan, \theta or \therefore
|
|
19
|
+
|
|
19
20
|
|
|
20
21
|
exports.createElementFromHTML = createElementFromHTML;
|
|
22
|
+
var tSymbols = 'imes|riangle|an|heta|herefore'; // do not remove \n from \nthroot, \nparallel, \ncong, \napprox, \neq, \ne or \nsim
|
|
23
|
+
|
|
24
|
+
var nSymbols = 'throot|parallel|cong|approx|eq|e|sim'; // match all \t and \n that are not part of math symbols that starts with \t or \n
|
|
25
|
+
|
|
26
|
+
var matchTabAndNewLine = new RegExp("(\\t(?!".concat(tSymbols, "))|(\\n(?!").concat(nSymbols, "))|(\\\\t(?!").concat(tSymbols, "))|(\\\\n(?!").concat(nSymbols, "))"), 'g');
|
|
21
27
|
|
|
22
28
|
var removeUnwantedCharacters = function removeUnwantedCharacters(markup) {
|
|
23
|
-
return markup.replace(
|
|
29
|
+
return markup.replace(matchTabAndNewLine, '').replace(/\\"/g, '"').replace(/\\\//g, '/');
|
|
24
30
|
};
|
|
25
31
|
|
|
26
32
|
exports.removeUnwantedCharacters = removeUnwantedCharacters;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/markupUtils.js"],"names":["createElementFromHTML","htmlString","div","document","createElement","innerHTML","trim","removeUnwantedCharacters","markup","replace","processMarkup","newMarkup","slateMarkup","choices","index","querySelectorAll","forEach","s","value","dataset","push","id","replaceWith","correctResponse","reduce","obj","c","REGEX","createSlateMarkup","match","g","correctId","correctChoice","find","choiceIsEmpty","choice","domEl","Array","from","tagName","childNodes","length","remove","newString"],"mappings":";;;;;;;;;AAAA;;AACA;;AAEO,IAAMA,qBAAqB,GAAG,SAAxBA,qBAAwB,
|
|
1
|
+
{"version":3,"sources":["../src/markupUtils.js"],"names":["createElementFromHTML","htmlString","div","document","createElement","innerHTML","trim","tSymbols","nSymbols","matchTabAndNewLine","RegExp","removeUnwantedCharacters","markup","replace","processMarkup","newMarkup","slateMarkup","choices","index","querySelectorAll","forEach","s","value","dataset","push","id","replaceWith","correctResponse","reduce","obj","c","REGEX","createSlateMarkup","match","g","correctId","correctChoice","find","choiceIsEmpty","choice","domEl","Array","from","tagName","childNodes","length","remove","newString"],"mappings":";;;;;;;;;AAAA;;AACA;;AAEO,IAAMA,qBAAqB,GAAG,SAAxBA,qBAAwB,CAACC,UAAD,EAAgB;AACnD,MAAMC,GAAG,GAAGC,QAAQ,CAACC,aAAT,CAAuB,KAAvB,CAAZ;AAEAF,EAAAA,GAAG,CAACG,SAAJ,GAAgBJ,UAAU,CAACK,IAAX,EAAhB;AAEA,SAAOJ,GAAP;AACD,CANM,C,CAQP;;;;AACA,IAAMK,QAAQ,GAAG,+BAAjB,C,CACA;;AACA,IAAMC,QAAQ,GAAG,sCAAjB,C,CACA;;AACA,IAAMC,kBAAkB,GAAG,IAAIC,MAAJ,kBACfH,QADe,uBACMC,QADN,yBAC6BD,QAD7B,yBACoDC,QADpD,SAEzB,GAFyB,CAA3B;;AAKO,IAAMG,wBAAwB,GAAG,SAA3BA,wBAA2B,CAACC,MAAD;AAAA,SACtCA,MAAM,CAACC,OAAP,CAAeJ,kBAAf,EAAmC,EAAnC,EAAuCI,OAAvC,CAA+C,MAA/C,EAAuD,GAAvD,EAA4DA,OAA5D,CAAoE,OAApE,EAA6E,GAA7E,CADsC;AAAA,CAAjC;;;;AAGA,IAAMC,aAAa,GAAG,SAAhBA,aAAgB,CAACF,MAAD,EAAY;AACvC,MAAMG,SAAS,GAAGJ,wBAAwB,CAACC,MAAD,CAA1C;AACA,MAAMI,WAAW,GAAGhB,qBAAqB,CAACe,SAAD,CAAzC;AACA,MAAME,OAAO,GAAG,EAAhB;AACA,MAAIC,KAAK,GAAG,CAAZ;AAEAF,EAAAA,WAAW,CAACG,gBAAZ,CAA6B,iCAA7B,EAAgEC,OAAhE,CAAwE,UAACC,CAAD,EAAO;AAC7E,QAAIC,KAAK,GAAGD,CAAC,CAACE,OAAF,CAAUD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,KAAb,CAApB;;AAEA,QAAI,CAACC,aAAD,IAAkB,CAACA,aAAa,CAACd,KAArC,EAA4C;AAC1Cc,MAAAA,aAAa,GAAG;AACdX,QAAAA,EAAE,EAAE,EADU;AAEdH,QAAAA,KAAK,EAAE;AAFO,OAAhB;AAID;;AAED,wEAA0DJ,KAAK,EAA/D,0BACEkB,aAAa,CAACX,EADhB,6BAEiB,wBAAOW,aAAa,CAACd,KAArB,CAFjB;AAGD,GAdM,CAAP;AAeD,CAnBM;;;;AAqBA,IAAMgB,aAAa,GAAG,SAAhBA,aAAgB,CAACC,MAAD,EAAY;AACvC,MAAIA,MAAJ,EAAY;AACV,wBAAuBA,MAAvB,CAAQjB,KAAR;AAAA,QAAQA,KAAR,8BAAgB,EAAhB;AACA,QAAMkB,KAAK,GAAGxC,qBAAqB,CAACsB,KAAD,CAAnC;AAEAmB,IAAAA,KAAK,CAACC,IAAN,CAAWF,KAAK,CAACrB,gBAAN,CAAuB,GAAvB,CAAX,EAAwCC,OAAxC,CAAgD,UAACoB,KAAD,EAAW;AACzD,UAAIA,KAAK,CAACG,OAAN,KAAkB,KAAlB,IAA2BH,KAAK,CAACI,UAAN,CAAiBC,MAAjB,KAA4B,CAA3D,EAA8D;AAC5DL,QAAAA,KAAK,CAACM,MAAN;AACD;AACF,KAJD;AAMA,QAAMC,SAAS,GAAGP,KAAK,CAACnC,SAAN,CAAgBC,IAAhB,EAAlB;AAEA,WAAOyC,SAAS,KAAK,EAArB;AACD;;AAED,SAAO,KAAP;AACD,CAjBM","sourcesContent":["import escape from 'lodash/escape';\nimport isUndefined from 'lodash/isUndefined';\n\nexport const createElementFromHTML = (htmlString) => {\n const div = document.createElement('div');\n\n div.innerHTML = htmlString.trim();\n\n return div;\n};\n\n// do not remove \\t from \\times, \\triangle, \\tan, \\theta or \\therefore\nconst tSymbols = 'imes|riangle|an|heta|herefore';\n// do not remove \\n from \\nthroot, \\nparallel, \\ncong, \\napprox, \\neq, \\ne or \\nsim\nconst nSymbols = 'throot|parallel|cong|approx|eq|e|sim';\n// match all \\t and \\n that are not part of math symbols that starts with \\t or \\n\nconst matchTabAndNewLine = new RegExp(\n `(\\\\t(?!${tSymbols}))|(\\\\n(?!${nSymbols}))|(\\\\\\\\t(?!${tSymbols}))|(\\\\\\\\n(?!${nSymbols}))`,\n 'g',\n);\n\nexport const removeUnwantedCharacters = (markup) =>\n markup.replace(matchTabAndNewLine, '').replace(/\\\\\"/g, '\"').replace(/\\\\\\//g, '/');\n\nexport const processMarkup = (markup) => {\n const newMarkup = removeUnwantedCharacters(markup);\n const slateMarkup = createElementFromHTML(newMarkup);\n const choices = [];\n let index = 0;\n\n slateMarkup.querySelectorAll('[data-type=\"drag_in_the_blank\"]').forEach((s) => {\n let value = s.dataset.value && s.dataset.value.replace(/ /g, ' ').trim();\n\n if (!value) {\n value = '';\n }\n\n choices.push({\n value,\n id: s.dataset.id,\n });\n\n s.replaceWith(`{{${index++}}}`);\n });\n\n return {\n markup: slateMarkup.innerHTML,\n choices: choices,\n correctResponse: choices.reduce((obj, c, index) => {\n obj[index] = (!isUndefined(c.id) && c.id) || '';\n\n return obj;\n }, {}),\n };\n};\n\nconst REGEX = /\\{\\{(\\d+)\\}\\}/g;\n\nexport const createSlateMarkup = (markup, choices, correctResponse) => {\n const newMarkup = removeUnwantedCharacters(markup);\n let index = 0;\n\n return newMarkup.replace(REGEX, (match, g) => {\n const correctId = correctResponse[g];\n let correctChoice = choices.find((c) => c.id === correctId);\n\n if (!correctChoice || !correctChoice.value) {\n correctChoice = {\n id: '',\n value: '',\n };\n }\n\n return `<span data-type=\"drag_in_the_blank\" data-index=\"${index++}\" data-id=\"${\n correctChoice.id\n }\" data-value=\"${escape(correctChoice.value)}\"></span>`;\n });\n};\n\nexport const choiceIsEmpty = (choice) => {\n if (choice) {\n const { value = '' } = choice;\n const domEl = createElementFromHTML(value);\n\n Array.from(domEl.querySelectorAll('*')).forEach((domEl) => {\n if (domEl.tagName !== 'IMG' && domEl.childNodes.length === 0) {\n domEl.remove();\n }\n });\n\n const newString = domEl.innerHTML.trim();\n\n return newString === '';\n }\n\n return false;\n};\n"],"file":"markupUtils.js"}
|
package/configure/package.json
CHANGED
|
@@ -1,22 +1,40 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pie-element/drag-in-the-blank-configure",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "4.4.0",
|
|
4
4
|
"private": true,
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "src/index.js",
|
|
7
7
|
"dependencies": {
|
|
8
8
|
"@material-ui/core": "^3.9.2",
|
|
9
9
|
"@material-ui/icons": "^3.0.1",
|
|
10
|
-
"@pie-framework/pie-configure-events": "^1.
|
|
11
|
-
"@pie-lib/config-ui": "
|
|
12
|
-
"@pie-lib/drag": "^
|
|
13
|
-
"@pie-lib/editable-html": "
|
|
14
|
-
"@pie-lib/math-rendering": "^2.
|
|
10
|
+
"@pie-framework/pie-configure-events": "^1.3.0",
|
|
11
|
+
"@pie-lib/config-ui": "12.0.0-beta.3",
|
|
12
|
+
"@pie-lib/drag": "^2.1.12",
|
|
13
|
+
"@pie-lib/editable-html": "10.0.0-beta.4",
|
|
14
|
+
"@pie-lib/math-rendering": "^2.5.12",
|
|
15
15
|
"debug": "^3.1.0",
|
|
16
16
|
"lodash": "^4.17.15",
|
|
17
17
|
"prop-types": "^15.6.2",
|
|
18
18
|
"react": "^16.8.1",
|
|
19
|
-
"react-dnd": "^
|
|
20
|
-
"react-dom": "^16.8.1"
|
|
19
|
+
"react-dnd": "^14.0.5",
|
|
20
|
+
"react-dom": "^16.8.1",
|
|
21
|
+
"@types/is-hotkey": "^0.1.1",
|
|
22
|
+
"@types/lodash": "^4.14.149",
|
|
23
|
+
"direction": "^1.0.3",
|
|
24
|
+
"is-plain-object": "^5.0.0",
|
|
25
|
+
"scroll-into-view-if-needed": "^2.2.20",
|
|
26
|
+
"tiny-invariant": "1.0.6",
|
|
27
|
+
"@emotion/css": "^11.10.0",
|
|
28
|
+
"is-hotkey": "^0.2.0",
|
|
29
|
+
"slate": "^0.82.1",
|
|
30
|
+
"slate-dev-environment": "^0.2.5",
|
|
31
|
+
"slate-edit-list": "^0.12.1",
|
|
32
|
+
"slate-edit-table": "^0.18.0",
|
|
33
|
+
"slate-history": "^0.66.0",
|
|
34
|
+
"slate-html-serializer": "^0.8.13",
|
|
35
|
+
"slate-hyperscript": "^0.77.0",
|
|
36
|
+
"slate-plain-serializer": "^0.7.13",
|
|
37
|
+
"slate-prop-types": "^0.5.44",
|
|
38
|
+
"slate-react": "0.92.0"
|
|
21
39
|
}
|
|
22
40
|
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export const generateValidationMessage = (config) => {
|
|
2
|
+
let { maxResponseAreas, minChoices, maxChoices } = config;
|
|
3
|
+
minChoices = minChoices || 2;
|
|
4
|
+
|
|
5
|
+
const responseAreasMessage =
|
|
6
|
+
'\nThe tokens should ' +
|
|
7
|
+
'not be empty and should be unique.\nThere should be at least 1 ' +
|
|
8
|
+
(maxResponseAreas ? `and at most ${maxResponseAreas} ` : '') +
|
|
9
|
+
'response area' +
|
|
10
|
+
(maxResponseAreas ? 's' : '') +
|
|
11
|
+
' defined.' +
|
|
12
|
+
`\nThere should be at least ${minChoices} ` +
|
|
13
|
+
(maxChoices ? `and at most ${maxChoices} ` : '') +
|
|
14
|
+
'tokens defined.';
|
|
15
|
+
|
|
16
|
+
return 'Validation requirements:' + responseAreasMessage;
|
|
17
|
+
};
|
package/controller/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,97 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [4.0.3](https://github.com/pie-framework/pie-elements/compare/@pie-element/drag-in-the-blank-controller@4.0.2...@pie-element/drag-in-the-blank-controller@4.0.3) (2023-01-05)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Bug Fixes
|
|
10
|
+
|
|
11
|
+
* **drag-in-the-blank:** add validation for empty response areas + UI improvements PD-2160 ([1c24e8f](https://github.com/pie-framework/pie-elements/commit/1c24e8f3f5890f6c325035c9b20d20b4dbc7f5a6))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
## [4.0.2](https://github.com/pie-framework/pie-elements/compare/@pie-element/drag-in-the-blank-controller@4.0.1...@pie-element/drag-in-the-blank-controller@4.0.2) (2022-12-07)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
### Bug Fixes
|
|
21
|
+
|
|
22
|
+
* update libs ([441f403](https://github.com/pie-framework/pie-elements/commit/441f403870b7bec0d61fab58b8d93dbe0ead4c32))
|
|
23
|
+
* **drag-in-the-blank:** changed the validation error message PD-2054 ([e025c65](https://github.com/pie-framework/pie-elements/commit/e025c65cdf5b5d5234d0126622ff369cfe62de15))
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
## [4.0.1](https://github.com/pie-framework/pie-elements/compare/@pie-element/drag-in-the-blank-controller@4.0.0...@pie-element/drag-in-the-blank-controller@4.0.1) (2022-09-29)
|
|
30
|
+
|
|
31
|
+
**Note:** Version bump only for package @pie-element/drag-in-the-blank-controller
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
# [4.0.0](https://github.com/pie-framework/pie-elements/compare/@pie-element/drag-in-the-blank-controller@3.3.22...@pie-element/drag-in-the-blank-controller@4.0.0) (2022-06-28)
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
### chore
|
|
41
|
+
|
|
42
|
+
* Merge master with develop. ([cdca48a](https://github.com/pie-framework/pie-elements/commit/cdca48abaa1d4179e4a961e13d171e14b7ed2444))
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
### BREAKING CHANGES
|
|
46
|
+
|
|
47
|
+
* Image percent buttons were removed from toolbar.
|
|
48
|
+
New properties maxImageWidth and maxImageHeight were added.
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
## [3.3.22](https://github.com/pie-framework/pie-elements/compare/@pie-element/drag-in-the-blank-controller@3.3.21...@pie-element/drag-in-the-blank-controller@3.3.22) (2022-05-16)
|
|
55
|
+
|
|
56
|
+
**Note:** Version bump only for package @pie-element/drag-in-the-blank-controller
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
## [3.3.18](https://github.com/pie-framework/pie-elements/compare/@pie-element/drag-in-the-blank-controller@3.3.16...@pie-element/drag-in-the-blank-controller@3.3.18) (2021-11-11)
|
|
63
|
+
|
|
64
|
+
**Note:** Version bump only for package @pie-element/drag-in-the-blank-controller
|
|
65
|
+
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
## [3.3.17](https://github.com/pie-framework/pie-elements/compare/@pie-element/drag-in-the-blank-controller@3.3.16...@pie-element/drag-in-the-blank-controller@3.3.17) (2021-11-11)
|
|
71
|
+
|
|
72
|
+
**Note:** Version bump only for package @pie-element/drag-in-the-blank-controller
|
|
73
|
+
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
## [3.3.16](https://github.com/pie-framework/pie-elements/compare/@pie-element/drag-in-the-blank-controller@3.3.14...@pie-element/drag-in-the-blank-controller@3.3.16) (2021-08-05)
|
|
79
|
+
|
|
80
|
+
|
|
81
|
+
### Bug Fixes
|
|
82
|
+
|
|
83
|
+
* force bump ([5ea7295](https://github.com/pie-framework/pie-elements/commit/5ea7295e4755fbc492a76e7ec69e5fc35b196919))
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
## [3.3.14](https://github.com/pie-framework/pie-elements/compare/@pie-element/drag-in-the-blank-controller@3.3.13...@pie-element/drag-in-the-blank-controller@3.3.14) (2021-06-29)
|
|
90
|
+
|
|
91
|
+
**Note:** Version bump only for package @pie-element/drag-in-the-blank-controller
|
|
92
|
+
|
|
93
|
+
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
|
|
6
97
|
## [3.3.13](https://github.com/pie-framework/pie-elements/compare/@pie-element/drag-in-the-blank-controller@3.3.10...@pie-element/drag-in-the-blank-controller@3.3.13) (2021-03-03)
|
|
7
98
|
|
|
8
99
|
**Note:** Version bump only for package @pie-element/drag-in-the-blank-controller
|