@pie-element/extended-text-entry 6.8.4 → 6.8.7
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 +24 -0
- package/configure/CHANGELOG.md +24 -0
- package/configure/lib/defaults.js +12 -0
- package/configure/lib/defaults.js.map +1 -1
- package/configure/lib/index.js +2 -2
- package/configure/lib/main.js +16 -7
- package/configure/lib/main.js.map +1 -1
- package/configure/package.json +3 -3
- package/controller/CHANGELOG.md +16 -0
- package/controller/lib/index.js +9 -5
- package/controller/lib/index.js.map +1 -1
- package/controller/package.json +1 -1
- package/docs/config-schema.json +32 -0
- package/docs/config-schema.json.md +24 -0
- package/docs/demo/generate.js +2 -1
- package/docs/pie-schema.json +12 -0
- package/docs/pie-schema.json.md +8 -0
- package/lib/index.js +5 -2
- package/lib/index.js.map +1 -1
- package/lib/main.js +4 -1
- package/lib/main.js.map +1 -1
- package/lib/print.js +2 -2
- package/module/configure.js +33 -17
- package/module/controller.js +2 -0
- package/module/demo.js +2 -1
- package/module/element.js +21657 -25492
- package/module/index.html +1 -1
- package/module/manifest.json +5 -5
- package/module/print-demo.js +2 -1
- package/module/print.html +1 -1
- package/module/print.js +21546 -25384
- package/package.json +5 -5
package/lib/main.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/main.jsx"],"names":["log","style","theme","main","backgroundColor","color","background","text","prompt","width","marginBottom","spacing","unit","fontSize","Main","props","onChange","containerRef","model","classes","session","dimensions","disabled","feedback","teacherInstructions","mathInput","animationsDisabled","playersToolbarPosition","value","height","maxHeight","toolbarOpts","teacherInstructionsDiv","position","ref","hidden","visible","collapsible","changeSession","toString","math","customKeys","keypadMode","equationEditor","controlledKeypadMode","video","audio","React","Component","PropTypes","func","isRequired","object","shape","string"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;AAEA,IAAMA,GAAG,GAAG,uBAAM,6BAAN,CAAZ;;AAEA,IAAMC,KAAK,GAAG,SAARA,KAAQ,CAAAC,KAAK;AAAA,SAAK;AACtBC,IAAAA,IAAI,EAAE;AACJC,MAAAA,eAAe,EAAEC,gBAAMC,UAAN,EADb;AAEJD,MAAAA,KAAK,EAAEA,gBAAME,IAAN;AAFH,KADgB;AAKtBC,IAAAA,MAAM,EAAE;AACNC,MAAAA,KAAK,EAAE,MADD;AAENJ,MAAAA,KAAK,EAAEA,gBAAME,IAAN,EAFD;AAGNG,MAAAA,YAAY,EAAER,KAAK,CAACS,OAAN,CAAcC,IAAd,GAAqB,CAH7B;AAINC,MAAAA,QAAQ,EAAE;AAJJ;AALc,GAAL;AAAA,CAAnB;;IAaaC,I;;;;;;;;;;;;;;;sGAgBK,0BAAS,MAAKC,KAAL,CAAWC,QAApB,EAA8B,IAA9B,C;;;;;;WANhB,8BAAqB;AACnB,UAAI,KAAKC,YAAT,EAAuB;AACrB,uCAAW,KAAKA,YAAhB;AACD;AACF;;;WAID,kBAAS;AAAA;;AACP,wBAAoC,KAAKF,KAAzC;AAAA,UAAQG,KAAR,eAAQA,KAAR;AAAA,UAAeC,OAAf,eAAeA,OAAf;AAAA,UAAwBC,OAAxB,eAAwBA,OAAxB;AACA,UAAQC,UAAR,
|
|
1
|
+
{"version":3,"sources":["../src/main.jsx"],"names":["log","style","theme","main","backgroundColor","color","background","text","prompt","width","marginBottom","spacing","unit","fontSize","Main","props","onChange","containerRef","model","classes","session","dimensions","disabled","feedback","teacherInstructions","mathInput","animationsDisabled","playersToolbarPosition","spellCheckEnabled","value","height","maxHeight","toolbarOpts","teacherInstructionsDiv","position","ref","hidden","visible","collapsible","changeSession","toString","math","customKeys","keypadMode","equationEditor","controlledKeypadMode","video","audio","React","Component","PropTypes","func","isRequired","object","shape","string"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;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ADM,GAAhB,EAENH;AANc,C;;eAyGN,wBAAWnD,KAAX,EAAkBa,IAAlB,C","sourcesContent":["import React from 'react';\nimport EditableHTML from '@pie-lib/editable-html';\nimport PropTypes from 'prop-types';\nimport Typography from '@material-ui/core/Typography';\nimport { withStyles } from '@material-ui/core/styles';\nimport debug from 'debug';\nimport debounce from 'lodash/debounce';\nimport {color, Feedback, Collapsible, PreviewPrompt} from '@pie-lib/render-ui';\nimport { renderMath } from '@pie-lib/math-rendering';\n\nconst log = debug('@pie-ui:extended-text-entry');\n\nconst style = theme => ({\n main: {\n backgroundColor: color.background(),\n color: color.text()\n },\n prompt: {\n width: '100%',\n color: color.text(),\n marginBottom: theme.spacing.unit * 2,\n fontSize: 'inherit'\n }\n});\n\nexport class Main extends React.Component {\n static propTypes = {\n onChange: PropTypes.func.isRequired,\n model: PropTypes.object,\n classes: PropTypes.object.isRequired,\n session: PropTypes.shape({\n value: PropTypes.string\n }).isRequired\n };\n\n componentDidUpdate() {\n if (this.containerRef) {\n renderMath(this.containerRef);\n }\n }\n\n changeSession = debounce(this.props.onChange, 1500);\n\n render() {\n const { model, classes, session } = this.props;\n const { dimensions, disabled, feedback, teacherInstructions, mathInput, animationsDisabled, playersToolbarPosition, spellCheckEnabled } = model;\n const { value } = session;\n const { width, height } = dimensions || {};\n const maxHeight = '40vh';\n const toolbarOpts = {};\n\n log('[render] disabled? ', disabled);\n\n const teacherInstructionsDiv = <PreviewPrompt defaultClassName=\"teacher-instructions\" prompt={teacherInstructions} />;\n\n switch (playersToolbarPosition) {\n case 'top':\n toolbarOpts.position = 'top';\n break;\n default:\n toolbarOpts.position = 'bottom';\n break;\n }\n\n return (\n <div\n className={classes.main}\n ref={ref => {\n this.containerRef = ref;\n }}\n >\n {\n teacherInstructions && (\n <div>\n {!animationsDisabled ? (\n <Collapsible\n labels={{hidden: 'Show Teacher Instructions', visible: 'Hide Teacher Instructions'}}\n className={classes.collapsible}\n >\n {teacherInstructionsDiv}\n </Collapsible>\n ) : teacherInstructionsDiv }\n <br/>\n </div>\n )\n }\n {model.prompt && (\n <Typography\n component={'span'}\n className={classes.prompt}\n >\n <PreviewPrompt defaultClassName=\"prompt\" prompt={model.prompt} />\n </Typography>\n )}\n <EditableHTML\n className=\"response-area-editor\"\n onChange={this.changeSession}\n markup={value || ''}\n width={width && width.toString()}\n minHeight={height && height.toString()}\n maxHeight={maxHeight}\n disabled={disabled}\n highlightShape={true}\n toolbarOpts={toolbarOpts}\n spellCheck={spellCheckEnabled}\n pluginProps={{\n math: {\n disabled: !mathInput,\n customKeys: this.props.model.customKeys,\n keypadMode: this.props.model.equationEditor,\n controlledKeypadMode: false\n },\n video: {\n disabled: true\n },\n audio: {\n disabled: true\n }\n }}\n />\n {feedback && (\n <div>\n <br />\n <Feedback correctness=\"correct\" feedback={feedback}/>\n </div>\n )}\n </div>\n );\n }\n}\n\nexport default withStyles(style)(Main);\n"],"file":"main.js"}
|
package/lib/print.js
CHANGED
|
@@ -39,9 +39,9 @@ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflec
|
|
|
39
39
|
|
|
40
40
|
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; } }
|
|
41
41
|
|
|
42
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
42
|
+
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; }
|
|
43
43
|
|
|
44
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
44
|
+
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; }
|
|
45
45
|
|
|
46
46
|
var log = (0, _debug["default"])('pie-element:extended-text-entry:print');
|
|
47
47
|
|
package/module/configure.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {_dll_react, _dll_prop_types, _dll_material_ui__core, _dll_material_ui__core_styles, _dll_react_dom} from "../../../@pie-lib/shared-module@^1.4.
|
|
2
|
-
import {_dll_pie_lib__config_ui} from "../../../@pie-lib/config-module@^1.0.
|
|
3
|
-
import {_dll_pie_lib__editable_html} from "../../../@pie-lib/editable-html-module@^1.2.
|
|
1
|
+
import {_dll_react, _dll_prop_types, _dll_material_ui__core, _dll_material_ui__core_styles, _dll_react_dom} from "../../../@pie-lib/shared-module@^1.4.10/module/index.js";
|
|
2
|
+
import {_dll_pie_lib__config_ui} from "../../../@pie-lib/config-module@^1.0.33/module/index.js";
|
|
3
|
+
import {_dll_pie_lib__editable_html} from "../../../@pie-lib/editable-html-module@^1.2.9/module/index.js";
|
|
4
4
|
var lib = {};
|
|
5
5
|
Object.defineProperty(lib, "__esModule", {
|
|
6
6
|
value: true
|
|
@@ -113,8 +113,8 @@ class Main extends React$1.Component {
|
|
|
113
113
|
}
|
|
114
114
|
render() {
|
|
115
115
|
const {model, classes, onModelChanged, configuration, onConfigurationChanged, imageSupport} = this.props;
|
|
116
|
-
const {multiple = {}, feedback = {}, teacherInstructions = {}, prompt = {}, studentInstructions = {}, mathInput = {}, dimensions = {}, equationEditor = {}} = configuration || ({});
|
|
117
|
-
const {teacherInstructionsEnabled, promptEnabled, feedbackEnabled} = model || ({});
|
|
116
|
+
const {multiple = {}, feedback = {}, teacherInstructions = {}, prompt = {}, studentInstructions = {}, mathInput = {}, dimensions = {}, equationEditor = {}, spellCheck = {}, playerSpellCheck = {}} = configuration || ({});
|
|
117
|
+
const {teacherInstructionsEnabled, promptEnabled, feedbackEnabled, spellCheckEnabled} = model || ({});
|
|
118
118
|
const toolbarOpts = {};
|
|
119
119
|
switch (model.toolbarEditorPosition) {
|
|
120
120
|
case 'top':
|
|
@@ -150,7 +150,9 @@ class Main extends React$1.Component {
|
|
|
150
150
|
}),
|
|
151
151
|
'multiple.enabled': multiple.settings && toggle(multiple.label, true),
|
|
152
152
|
promptEnabled: prompt.settings && toggle(prompt.label),
|
|
153
|
-
feedbackEnabled: feedback.settings && toggle(feedback.label)
|
|
153
|
+
feedbackEnabled: feedback.settings && toggle(feedback.label),
|
|
154
|
+
spellCheckEnabled: spellCheck.settings && toggle(spellCheck.label),
|
|
155
|
+
playerSpellCheckEnabled: playerSpellCheck.settings && toggle(playerSpellCheck.label)
|
|
154
156
|
},
|
|
155
157
|
Properties: {
|
|
156
158
|
teacherInstructionsEnabled: teacherInstructions.settings && toggle(teacherInstructions.label),
|
|
@@ -160,19 +162,19 @@ class Main extends React$1.Component {
|
|
|
160
162
|
__self: this,
|
|
161
163
|
__source: {
|
|
162
164
|
fileName: _jsxFileName,
|
|
163
|
-
lineNumber:
|
|
165
|
+
lineNumber: 94
|
|
164
166
|
}
|
|
165
167
|
}),
|
|
166
168
|
__self: this,
|
|
167
169
|
__source: {
|
|
168
170
|
fileName: _jsxFileName,
|
|
169
|
-
lineNumber:
|
|
171
|
+
lineNumber: 92
|
|
170
172
|
}
|
|
171
173
|
}, React$1.createElement('div', {
|
|
172
174
|
__self: this,
|
|
173
175
|
__source: {
|
|
174
176
|
fileName: _jsxFileName,
|
|
175
|
-
lineNumber:
|
|
177
|
+
lineNumber: 154
|
|
176
178
|
}
|
|
177
179
|
}, teacherInstructionsEnabled && React$1.createElement(InputContainer, {
|
|
178
180
|
label: teacherInstructions.label,
|
|
@@ -180,7 +182,7 @@ class Main extends React$1.Component {
|
|
|
180
182
|
__self: this,
|
|
181
183
|
__source: {
|
|
182
184
|
fileName: _jsxFileName,
|
|
183
|
-
lineNumber:
|
|
185
|
+
lineNumber: 156
|
|
184
186
|
}
|
|
185
187
|
}, React$1.createElement(EditableHtml, {
|
|
186
188
|
className: classes.prompt,
|
|
@@ -189,16 +191,17 @@ class Main extends React$1.Component {
|
|
|
189
191
|
imageSupport: imageSupport,
|
|
190
192
|
nonEmpty: false,
|
|
191
193
|
toolbarOpts: toolbarOpts,
|
|
194
|
+
spellCheck: spellCheckEnabled,
|
|
192
195
|
__self: this,
|
|
193
196
|
__source: {
|
|
194
197
|
fileName: _jsxFileName,
|
|
195
|
-
lineNumber:
|
|
198
|
+
lineNumber: 160
|
|
196
199
|
}
|
|
197
200
|
})), React$1.createElement('br', {
|
|
198
201
|
__self: this,
|
|
199
202
|
__source: {
|
|
200
203
|
fileName: _jsxFileName,
|
|
201
|
-
lineNumber:
|
|
204
|
+
lineNumber: 172
|
|
202
205
|
}
|
|
203
206
|
}), promptEnabled && React$1.createElement(InputContainer, {
|
|
204
207
|
label: prompt.label,
|
|
@@ -206,7 +209,7 @@ class Main extends React$1.Component {
|
|
|
206
209
|
__self: this,
|
|
207
210
|
__source: {
|
|
208
211
|
fileName: _jsxFileName,
|
|
209
|
-
lineNumber:
|
|
212
|
+
lineNumber: 175
|
|
210
213
|
}
|
|
211
214
|
}, React$1.createElement(EditableHtml, {
|
|
212
215
|
activePlugins: ALL_PLUGINS,
|
|
@@ -216,16 +219,17 @@ class Main extends React$1.Component {
|
|
|
216
219
|
imageSupport: imageSupport,
|
|
217
220
|
nonEmpty: false,
|
|
218
221
|
toolbarOpts: toolbarOpts,
|
|
222
|
+
spellCheck: spellCheckEnabled,
|
|
219
223
|
__self: this,
|
|
220
224
|
__source: {
|
|
221
225
|
fileName: _jsxFileName,
|
|
222
|
-
lineNumber:
|
|
226
|
+
lineNumber: 179
|
|
223
227
|
}
|
|
224
228
|
})), feedbackEnabled && React$1.createElement(React$1.Fragment, {
|
|
225
229
|
__self: this,
|
|
226
230
|
__source: {
|
|
227
231
|
fileName: _jsxFileName,
|
|
228
|
-
lineNumber:
|
|
232
|
+
lineNumber: 193
|
|
229
233
|
}
|
|
230
234
|
}, React$1.createElement(Typography, {
|
|
231
235
|
className: classes.header,
|
|
@@ -233,7 +237,7 @@ class Main extends React$1.Component {
|
|
|
233
237
|
__self: this,
|
|
234
238
|
__source: {
|
|
235
239
|
fileName: _jsxFileName,
|
|
236
|
-
lineNumber:
|
|
240
|
+
lineNumber: 194
|
|
237
241
|
}
|
|
238
242
|
}, "Feedback"), React$1.createElement(FeedbackSelector, {
|
|
239
243
|
label: "When submitted, show",
|
|
@@ -243,7 +247,7 @@ class Main extends React$1.Component {
|
|
|
243
247
|
__self: this,
|
|
244
248
|
__source: {
|
|
245
249
|
fileName: _jsxFileName,
|
|
246
|
-
lineNumber:
|
|
250
|
+
lineNumber: 198
|
|
247
251
|
}
|
|
248
252
|
}))));
|
|
249
253
|
}
|
|
@@ -280,6 +284,8 @@ var defaults = {
|
|
|
280
284
|
promptEnabled: true,
|
|
281
285
|
teacherInstructionsEnabled: true,
|
|
282
286
|
studentInstructionsEnabled: true,
|
|
287
|
+
spellCheckEnabled: true,
|
|
288
|
+
playerSpellCheckEnabled: true,
|
|
283
289
|
toolbarEditorPosition: 'bottom'
|
|
284
290
|
},
|
|
285
291
|
configuration: {
|
|
@@ -287,6 +293,16 @@ var defaults = {
|
|
|
287
293
|
settings: true,
|
|
288
294
|
label: 'Text-Entry Display Size'
|
|
289
295
|
},
|
|
296
|
+
spellCheck: {
|
|
297
|
+
label: 'Spellcheck',
|
|
298
|
+
settings: false,
|
|
299
|
+
enabled: true
|
|
300
|
+
},
|
|
301
|
+
playerSpellCheck: {
|
|
302
|
+
label: 'Student Spellcheck',
|
|
303
|
+
settings: true,
|
|
304
|
+
enabled: true
|
|
305
|
+
},
|
|
290
306
|
equationEditor: {
|
|
291
307
|
settings: false,
|
|
292
308
|
label: 'Equation Editor',
|
package/module/controller.js
CHANGED
|
@@ -37,6 +37,7 @@ const normalize = question => ({
|
|
|
37
37
|
promptEnabled: true,
|
|
38
38
|
teacherInstructionsEnabled: true,
|
|
39
39
|
studentInstructionsEnabled: true,
|
|
40
|
+
playerSpellCheckEnabled: true,
|
|
40
41
|
...question,
|
|
41
42
|
});
|
|
42
43
|
|
|
@@ -82,6 +83,7 @@ async function model(question, session, env) {
|
|
|
82
83
|
teacherInstructions,
|
|
83
84
|
mathInput: normalizedQuestion.mathInput,
|
|
84
85
|
equationEditor,
|
|
86
|
+
spellCheckEnabled: normalizedQuestion.playerSpellCheckEnabled,
|
|
85
87
|
playersToolbarPosition: normalizedQuestion.playersToolbarPosition || 'bottom'
|
|
86
88
|
}));
|
|
87
89
|
}
|
package/module/demo.js
CHANGED