@pie-element/explicit-constructed-response 7.2.2-next.28 → 7.2.2-next.29
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/configure/package.json +1 -1
- package/controller/package.json +1 -1
- package/module/configure.js +2 -2
- package/module/element.js +35 -18
- package/module/manifest.json +2 -2
- package/module/print.js +35 -18
- package/package.json +3 -3
package/configure/package.json
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"@material-ui/core": "^3.9.2",
|
|
9
9
|
"@material-ui/icons": "^3.0.1",
|
|
10
10
|
"@pie-framework/pie-configure-events": "^1.3.0",
|
|
11
|
-
"@pie-lib/pie-toolbox": "2.
|
|
11
|
+
"@pie-lib/pie-toolbox": "2.2.0",
|
|
12
12
|
"classnames": "^2.2.6",
|
|
13
13
|
"debug": "^3.1.0",
|
|
14
14
|
"lodash": "^4.17.15",
|
package/controller/package.json
CHANGED
package/module/configure.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {_dll_react, _dll_prop_types, _dll_classnames, _dll_react_dom, _dll_lodash, _dll_debug} from "../../../@pie-lib/pie-toolbox-math-rendering-module@2.
|
|
2
|
-
import {_dll_pie_lib__pie_toolbox_editable_html, _dll_pie_lib__pie_toolbox_config_ui} from "../../../@pie-lib/pie-toolbox-module@5.
|
|
1
|
+
import {_dll_react, _dll_prop_types, _dll_classnames, _dll_react_dom, _dll_lodash, _dll_debug} from "../../../@pie-lib/pie-toolbox-math-rendering-module@2.2.0/module/index.js";
|
|
2
|
+
import {_dll_pie_lib__pie_toolbox_editable_html, _dll_pie_lib__pie_toolbox_config_ui} from "../../../@pie-lib/pie-toolbox-module@5.2.0/module/index.js";
|
|
3
3
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
4
4
|
function getDefaultExportFromCjs(x) {
|
|
5
5
|
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
package/module/element.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {_dll_react, _dll_prop_types, _dll_debug, _dll_lodash, _dll_react_dom_server, _dll_react_dom, _dll_classnames, _dll_pie_framework__mathquill, _dll_pie_lib__pie_toolbox_math_rendering_accessible} from "../../../@pie-lib/pie-toolbox-math-rendering-module@2.
|
|
2
|
-
import {_dll_pie_lib__pie_toolbox_correct_answer_toggle, _dll_pie_lib__pie_toolbox_render_ui} from "../../../@pie-lib/pie-toolbox-module@5.
|
|
1
|
+
import {_dll_react, _dll_prop_types, _dll_debug, _dll_lodash, _dll_react_dom_server, _dll_react_dom, _dll_classnames, _dll_pie_framework__mathquill, _dll_pie_lib__pie_toolbox_math_rendering_accessible} from "../../../@pie-lib/pie-toolbox-math-rendering-module@2.2.0/module/index.js";
|
|
2
|
+
import {_dll_pie_lib__pie_toolbox_correct_answer_toggle, _dll_pie_lib__pie_toolbox_render_ui} from "../../../@pie-lib/pie-toolbox-module@5.2.0/module/index.js";
|
|
3
3
|
function _mergeNamespaces(n, m) {
|
|
4
4
|
m.forEach(function (e) {
|
|
5
5
|
e && typeof e !== 'string' && !Array.isArray(e) && Object.keys(e).forEach(function (k) {
|
|
@@ -26740,7 +26740,7 @@ TexError$1.default = TexError;
|
|
|
26740
26740
|
}
|
|
26741
26741
|
},
|
|
26742
26742
|
loader: {
|
|
26743
|
-
load: ["input/mml"
|
|
26743
|
+
load: ["input/mml"],
|
|
26744
26744
|
preLoad: function preLoad() {},
|
|
26745
26745
|
failed: function failed(error) {
|
|
26746
26746
|
return console.log(("MathJax(").concat(error["package"] || '?', "): ").concat(error.message));
|
|
@@ -71248,7 +71248,7 @@ var _interopRequireDefault$3e = interopRequireDefault.exports;
|
|
|
71248
71248
|
Object.defineProperty(color$1, "__esModule", {
|
|
71249
71249
|
value: true
|
|
71250
71250
|
});
|
|
71251
|
-
color$1.white = color$1.v = color$1.transparent = color$1.text = color$1.secondaryText = color$1.secondaryLight = color$1.secondaryDark = color$1.secondaryBackground = color$1.secondary = color$1.primaryText = color$1.primaryLight = color$1.primaryDark = color$1.primary = color$1.missingWithIcon = color$1.missing = color$1.incorrectWithIcon = color$1.incorrectSecondary = color$1.incorrect = color$1.disabledSecondary = color$1.disabled = color$1.defaults = color$1.correctWithIcon = color$1.correctSecondary = color$1.correct = color$1.borderLight = color$1.borderDark = color$1.border = color$1.black = color$1.backgroundDark = color$1.background = void 0;
|
|
71251
|
+
color$1.white = color$1.v = color$1.transparent = color$1.text = color$1.tertiaryLight = color$1.tertiary = color$1.secondaryText = color$1.secondaryLight = color$1.secondaryDark = color$1.secondaryBackground = color$1.secondary = color$1.primaryText = color$1.primaryLight = color$1.primaryDark = color$1.primary = color$1.missingWithIcon = color$1.missing = color$1.incorrectWithIcon = color$1.incorrectSecondary = color$1.incorrect = color$1.disabledSecondary = color$1.disabled = color$1.defaults = color$1.correctWithIcon = color$1.correctSecondary = color$1.correct = color$1.borderLight = color$1.borderDark = color$1.border = color$1.black = color$1.backgroundDark = color$1.background = void 0;
|
|
71252
71252
|
var _green = _interopRequireDefault$3e(green$1);
|
|
71253
71253
|
var _orange = _interopRequireDefault$3e(orange$1);
|
|
71254
71254
|
var _pink = _interopRequireDefault$3e(pink$1);
|
|
@@ -71272,6 +71272,8 @@ var defaults = {
|
|
|
71272
71272
|
SECONDARY: _pink["default"].A400,
|
|
71273
71273
|
SECONDARY_LIGHT: _pink["default"][200],
|
|
71274
71274
|
SECONDARY_DARK: _pink["default"][900],
|
|
71275
|
+
TERTIARY: '#146EB3',
|
|
71276
|
+
TERTIARY_LIGHT: '#D0E2F0',
|
|
71275
71277
|
BACKGROUND: 'rgba(255,255,255,0)',
|
|
71276
71278
|
BACKGROUND_DARK: '#ECEDF1',
|
|
71277
71279
|
SECONDARY_BACKGROUND: 'rgba(241,241,241,1)',
|
|
@@ -71385,6 +71387,14 @@ var secondaryBackground = function secondaryBackground() {
|
|
|
71385
71387
|
return pv('secondary-background', defaults.SECONDARY_BACKGROUND);
|
|
71386
71388
|
};
|
|
71387
71389
|
color$1.secondaryBackground = secondaryBackground;
|
|
71390
|
+
var tertiary = function tertiary() {
|
|
71391
|
+
return pv('tertiary', defaults.TERTIARY);
|
|
71392
|
+
};
|
|
71393
|
+
color$1.tertiary = tertiary;
|
|
71394
|
+
var tertiaryLight = function tertiaryLight() {
|
|
71395
|
+
return pv('tertiary-light', defaults.TERTIARY_LIGHT);
|
|
71396
|
+
};
|
|
71397
|
+
color$1.tertiaryLight = tertiaryLight;
|
|
71388
71398
|
var border = function border() {
|
|
71389
71399
|
return pv('border', defaults.BORDER);
|
|
71390
71400
|
};
|
|
@@ -75051,9 +75061,9 @@ const require$$11$s = _dll_prop_types;
|
|
|
75051
75061
|
color: theme.palette.common.black
|
|
75052
75062
|
}
|
|
75053
75063
|
},
|
|
75054
|
-
'&:not(.MathJax)
|
|
75064
|
+
'&:not(.MathJax) table td, &:not(.MathJax) table th': {
|
|
75055
75065
|
padding: '.6em 1em',
|
|
75056
|
-
textAlign: '
|
|
75066
|
+
textAlign: 'left'
|
|
75057
75067
|
},
|
|
75058
75068
|
'&:not(.MathJax) > table td > p.kds-indent': {
|
|
75059
75069
|
textAlign: 'initial'
|
|
@@ -79289,18 +79299,23 @@ const require$$17$2 = _dll_classnames;
|
|
|
79289
79299
|
}, {
|
|
79290
79300
|
key: "updateDimensions",
|
|
79291
79301
|
value: function updateDimensions() {
|
|
79292
|
-
|
|
79293
|
-
|
|
79294
|
-
|
|
79295
|
-
|
|
79296
|
-
|
|
79297
|
-
|
|
79302
|
+
if (this.spanRef && this.rootRef) {
|
|
79303
|
+
this.rootRef.style.width = 'auto';
|
|
79304
|
+
var width = this.spanRef.offsetWidth || 0;
|
|
79305
|
+
var height = this.spanRef.offsetHeight || 0;
|
|
79306
|
+
var widthWithPadding = width + 24;
|
|
79307
|
+
var responseAreaWidth = parseFloat(this.props.emptyResponseAreaWidth) || 0;
|
|
79308
|
+
var responseAreaHeight = parseFloat(this.props.emptyResponseAreaHeight) || 0;
|
|
79309
|
+
var adjustedWidth = widthWithPadding <= responseAreaWidth ? responseAreaWidth : widthWithPadding;
|
|
79310
|
+
var adjustedHeight = height <= responseAreaHeight ? responseAreaHeight : height;
|
|
79298
79311
|
this.setState(function (prevState) {
|
|
79299
79312
|
return {
|
|
79300
|
-
width:
|
|
79301
|
-
height:
|
|
79313
|
+
width: adjustedWidth > responseAreaWidth ? adjustedWidth : prevState.width,
|
|
79314
|
+
height: adjustedHeight > responseAreaHeight ? adjustedHeight : prevState.height
|
|
79302
79315
|
};
|
|
79303
79316
|
});
|
|
79317
|
+
this.rootRef.style.width = ("").concat(adjustedWidth, "px");
|
|
79318
|
+
this.rootRef.style.height = ("").concat(adjustedHeight, "px");
|
|
79304
79319
|
}
|
|
79305
79320
|
}
|
|
79306
79321
|
}, {
|
|
@@ -79315,13 +79330,15 @@ const require$$17$2 = _dll_classnames;
|
|
|
79315
79330
|
}, {
|
|
79316
79331
|
key: "getRootDimensions",
|
|
79317
79332
|
value: function getRootDimensions() {
|
|
79333
|
+
var responseAreaWidth = !isNaN(parseFloat(this.props.emptyResponseAreaWidth)) ? parseFloat(this.props.emptyResponseAreaWidth) : 0;
|
|
79334
|
+
var responseAreaHeight = !isNaN(parseFloat(this.props.emptyResponseAreaHeight)) ? parseFloat(this.props.emptyResponseAreaHeight) : 0;
|
|
79318
79335
|
var rootStyle = {
|
|
79319
|
-
height: this.state.height ||
|
|
79320
|
-
width: this.state.width ||
|
|
79336
|
+
height: this.state.height || responseAreaHeight,
|
|
79337
|
+
width: this.state.width || responseAreaWidth
|
|
79321
79338
|
};
|
|
79322
|
-
return _objectSpread(_objectSpread(_objectSpread({}, rootStyle),
|
|
79339
|
+
return _objectSpread(_objectSpread(_objectSpread({}, rootStyle), responseAreaWidth ? {} : {
|
|
79323
79340
|
minWidth: 90
|
|
79324
|
-
}),
|
|
79341
|
+
}), responseAreaHeight ? {} : {
|
|
79325
79342
|
minHeight: 32
|
|
79326
79343
|
});
|
|
79327
79344
|
}
|
package/module/manifest.json
CHANGED
package/module/print.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {_dll_react, _dll_prop_types, _dll_debug, _dll_lodash, _dll_react_dom_server, _dll_react_dom, _dll_classnames, _dll_pie_framework__mathquill, _dll_pie_lib__pie_toolbox_math_rendering_accessible} from "../../../@pie-lib/pie-toolbox-math-rendering-module@2.
|
|
2
|
-
import {_dll_pie_lib__pie_toolbox_correct_answer_toggle, _dll_pie_lib__pie_toolbox_render_ui} from "../../../@pie-lib/pie-toolbox-module@5.
|
|
1
|
+
import {_dll_react, _dll_prop_types, _dll_debug, _dll_lodash, _dll_react_dom_server, _dll_react_dom, _dll_classnames, _dll_pie_framework__mathquill, _dll_pie_lib__pie_toolbox_math_rendering_accessible} from "../../../@pie-lib/pie-toolbox-math-rendering-module@2.2.0/module/index.js";
|
|
2
|
+
import {_dll_pie_lib__pie_toolbox_correct_answer_toggle, _dll_pie_lib__pie_toolbox_render_ui} from "../../../@pie-lib/pie-toolbox-module@5.2.0/module/index.js";
|
|
3
3
|
function _mergeNamespaces(n, m) {
|
|
4
4
|
m.forEach(function (e) {
|
|
5
5
|
e && typeof e !== 'string' && !Array.isArray(e) && Object.keys(e).forEach(function (k) {
|
|
@@ -26703,7 +26703,7 @@ TexError$1.default = TexError;
|
|
|
26703
26703
|
}
|
|
26704
26704
|
},
|
|
26705
26705
|
loader: {
|
|
26706
|
-
load: ["input/mml"
|
|
26706
|
+
load: ["input/mml"],
|
|
26707
26707
|
preLoad: function preLoad() {},
|
|
26708
26708
|
failed: function failed(error) {
|
|
26709
26709
|
return console.log(("MathJax(").concat(error["package"] || '?', "): ").concat(error.message));
|
|
@@ -71211,7 +71211,7 @@ var _interopRequireDefault$3e = interopRequireDefault.exports;
|
|
|
71211
71211
|
Object.defineProperty(color$1, "__esModule", {
|
|
71212
71212
|
value: true
|
|
71213
71213
|
});
|
|
71214
|
-
color$1.white = color$1.v = color$1.transparent = color$1.text = color$1.secondaryText = color$1.secondaryLight = color$1.secondaryDark = color$1.secondaryBackground = color$1.secondary = color$1.primaryText = color$1.primaryLight = color$1.primaryDark = color$1.primary = color$1.missingWithIcon = color$1.missing = color$1.incorrectWithIcon = color$1.incorrectSecondary = color$1.incorrect = color$1.disabledSecondary = color$1.disabled = color$1.defaults = color$1.correctWithIcon = color$1.correctSecondary = color$1.correct = color$1.borderLight = color$1.borderDark = color$1.border = color$1.black = color$1.backgroundDark = color$1.background = void 0;
|
|
71214
|
+
color$1.white = color$1.v = color$1.transparent = color$1.text = color$1.tertiaryLight = color$1.tertiary = color$1.secondaryText = color$1.secondaryLight = color$1.secondaryDark = color$1.secondaryBackground = color$1.secondary = color$1.primaryText = color$1.primaryLight = color$1.primaryDark = color$1.primary = color$1.missingWithIcon = color$1.missing = color$1.incorrectWithIcon = color$1.incorrectSecondary = color$1.incorrect = color$1.disabledSecondary = color$1.disabled = color$1.defaults = color$1.correctWithIcon = color$1.correctSecondary = color$1.correct = color$1.borderLight = color$1.borderDark = color$1.border = color$1.black = color$1.backgroundDark = color$1.background = void 0;
|
|
71215
71215
|
var _green = _interopRequireDefault$3e(green$1);
|
|
71216
71216
|
var _orange = _interopRequireDefault$3e(orange$1);
|
|
71217
71217
|
var _pink = _interopRequireDefault$3e(pink$1);
|
|
@@ -71235,6 +71235,8 @@ var defaults = {
|
|
|
71235
71235
|
SECONDARY: _pink["default"].A400,
|
|
71236
71236
|
SECONDARY_LIGHT: _pink["default"][200],
|
|
71237
71237
|
SECONDARY_DARK: _pink["default"][900],
|
|
71238
|
+
TERTIARY: '#146EB3',
|
|
71239
|
+
TERTIARY_LIGHT: '#D0E2F0',
|
|
71238
71240
|
BACKGROUND: 'rgba(255,255,255,0)',
|
|
71239
71241
|
BACKGROUND_DARK: '#ECEDF1',
|
|
71240
71242
|
SECONDARY_BACKGROUND: 'rgba(241,241,241,1)',
|
|
@@ -71348,6 +71350,14 @@ var secondaryBackground = function secondaryBackground() {
|
|
|
71348
71350
|
return pv('secondary-background', defaults.SECONDARY_BACKGROUND);
|
|
71349
71351
|
};
|
|
71350
71352
|
color$1.secondaryBackground = secondaryBackground;
|
|
71353
|
+
var tertiary = function tertiary() {
|
|
71354
|
+
return pv('tertiary', defaults.TERTIARY);
|
|
71355
|
+
};
|
|
71356
|
+
color$1.tertiary = tertiary;
|
|
71357
|
+
var tertiaryLight = function tertiaryLight() {
|
|
71358
|
+
return pv('tertiary-light', defaults.TERTIARY_LIGHT);
|
|
71359
|
+
};
|
|
71360
|
+
color$1.tertiaryLight = tertiaryLight;
|
|
71351
71361
|
var border = function border() {
|
|
71352
71362
|
return pv('border', defaults.BORDER);
|
|
71353
71363
|
};
|
|
@@ -75014,9 +75024,9 @@ const require$$11$s = _dll_prop_types;
|
|
|
75014
75024
|
color: theme.palette.common.black
|
|
75015
75025
|
}
|
|
75016
75026
|
},
|
|
75017
|
-
'&:not(.MathJax)
|
|
75027
|
+
'&:not(.MathJax) table td, &:not(.MathJax) table th': {
|
|
75018
75028
|
padding: '.6em 1em',
|
|
75019
|
-
textAlign: '
|
|
75029
|
+
textAlign: 'left'
|
|
75020
75030
|
},
|
|
75021
75031
|
'&:not(.MathJax) > table td > p.kds-indent': {
|
|
75022
75032
|
textAlign: 'initial'
|
|
@@ -79252,18 +79262,23 @@ const require$$17$2 = _dll_classnames;
|
|
|
79252
79262
|
}, {
|
|
79253
79263
|
key: "updateDimensions",
|
|
79254
79264
|
value: function updateDimensions() {
|
|
79255
|
-
|
|
79256
|
-
|
|
79257
|
-
|
|
79258
|
-
|
|
79259
|
-
|
|
79260
|
-
|
|
79265
|
+
if (this.spanRef && this.rootRef) {
|
|
79266
|
+
this.rootRef.style.width = 'auto';
|
|
79267
|
+
var width = this.spanRef.offsetWidth || 0;
|
|
79268
|
+
var height = this.spanRef.offsetHeight || 0;
|
|
79269
|
+
var widthWithPadding = width + 24;
|
|
79270
|
+
var responseAreaWidth = parseFloat(this.props.emptyResponseAreaWidth) || 0;
|
|
79271
|
+
var responseAreaHeight = parseFloat(this.props.emptyResponseAreaHeight) || 0;
|
|
79272
|
+
var adjustedWidth = widthWithPadding <= responseAreaWidth ? responseAreaWidth : widthWithPadding;
|
|
79273
|
+
var adjustedHeight = height <= responseAreaHeight ? responseAreaHeight : height;
|
|
79261
79274
|
this.setState(function (prevState) {
|
|
79262
79275
|
return {
|
|
79263
|
-
width:
|
|
79264
|
-
height:
|
|
79276
|
+
width: adjustedWidth > responseAreaWidth ? adjustedWidth : prevState.width,
|
|
79277
|
+
height: adjustedHeight > responseAreaHeight ? adjustedHeight : prevState.height
|
|
79265
79278
|
};
|
|
79266
79279
|
});
|
|
79280
|
+
this.rootRef.style.width = ("").concat(adjustedWidth, "px");
|
|
79281
|
+
this.rootRef.style.height = ("").concat(adjustedHeight, "px");
|
|
79267
79282
|
}
|
|
79268
79283
|
}
|
|
79269
79284
|
}, {
|
|
@@ -79278,13 +79293,15 @@ const require$$17$2 = _dll_classnames;
|
|
|
79278
79293
|
}, {
|
|
79279
79294
|
key: "getRootDimensions",
|
|
79280
79295
|
value: function getRootDimensions() {
|
|
79296
|
+
var responseAreaWidth = !isNaN(parseFloat(this.props.emptyResponseAreaWidth)) ? parseFloat(this.props.emptyResponseAreaWidth) : 0;
|
|
79297
|
+
var responseAreaHeight = !isNaN(parseFloat(this.props.emptyResponseAreaHeight)) ? parseFloat(this.props.emptyResponseAreaHeight) : 0;
|
|
79281
79298
|
var rootStyle = {
|
|
79282
|
-
height: this.state.height ||
|
|
79283
|
-
width: this.state.width ||
|
|
79299
|
+
height: this.state.height || responseAreaHeight,
|
|
79300
|
+
width: this.state.width || responseAreaWidth
|
|
79284
79301
|
};
|
|
79285
|
-
return _objectSpread(_objectSpread(_objectSpread({}, rootStyle),
|
|
79302
|
+
return _objectSpread(_objectSpread(_objectSpread({}, rootStyle), responseAreaWidth ? {} : {
|
|
79286
79303
|
minWidth: 90
|
|
79287
|
-
}),
|
|
79304
|
+
}), responseAreaHeight ? {} : {
|
|
79288
79305
|
minHeight: 32
|
|
79289
79306
|
});
|
|
79290
79307
|
}
|
package/package.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"access": "public"
|
|
5
5
|
},
|
|
6
6
|
"repository": "pie-framework/pie-elements",
|
|
7
|
-
"version": "7.2.2-next.
|
|
7
|
+
"version": "7.2.2-next.29+f1f0af31f",
|
|
8
8
|
"description": "",
|
|
9
9
|
"scripts": {
|
|
10
10
|
"postpublish": "../../scripts/postpublish"
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
"dependencies": {
|
|
13
13
|
"@material-ui/core": "^3.9.2",
|
|
14
14
|
"@pie-framework/pie-player-events": "^0.1.0",
|
|
15
|
-
"@pie-lib/pie-toolbox": "2.
|
|
15
|
+
"@pie-lib/pie-toolbox": "2.2.0",
|
|
16
16
|
"classnames": "^2.2.5",
|
|
17
17
|
"lodash": "^4.17.10",
|
|
18
18
|
"prop-types": "^15.6.1",
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
},
|
|
22
22
|
"author": "",
|
|
23
23
|
"license": "ISC",
|
|
24
|
-
"gitHead": "
|
|
24
|
+
"gitHead": "f1f0af31f3c6fba54ca3a378dea3b8b32d8ebb87",
|
|
25
25
|
"main": "lib/index.js",
|
|
26
26
|
"module": "src/index.js",
|
|
27
27
|
"exports": {
|