@pie-element/math-templated 3.3.8-next.5 → 3.3.8

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 CHANGED
@@ -3,6 +3,17 @@
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
+ ## [3.3.8](https://github.com/pie-framework/pie-elements/compare/@pie-element/math-templated@3.3.7...@pie-element/math-templated@3.3.8) (2025-01-27)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * update pie-lib/pie-toolbox PD-4688, PD-4589, PD-4616 ([754480c](https://github.com/pie-framework/pie-elements/commit/754480c6c747fa9123d374df0287a644c8376939))
12
+
13
+
14
+
15
+
16
+
6
17
  ## [3.3.7](https://github.com/pie-framework/pie-elements/compare/@pie-element/math-templated@3.3.6...@pie-element/math-templated@3.3.7) (2025-01-22)
7
18
 
8
19
 
@@ -3,6 +3,17 @@
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
+ ## [2.2.8](https://github.com/pie-framework/pie-elements/compare/@pie-element/math-templated-configure@2.2.7...@pie-element/math-templated-configure@2.2.8) (2025-01-27)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * update pie-lib/pie-toolbox PD-4688, PD-4589, PD-4616 ([754480c](https://github.com/pie-framework/pie-elements/commit/754480c6c747fa9123d374df0287a644c8376939))
12
+
13
+
14
+
15
+
16
+
6
17
  ## [2.2.7](https://github.com/pie-framework/pie-elements/compare/@pie-element/math-templated-configure@2.2.6...@pie-element/math-templated-configure@2.2.7) (2025-01-22)
7
18
 
8
19
 
@@ -1,14 +1,14 @@
1
1
  {
2
2
  "name": "@pie-element/math-templated-configure",
3
3
  "private": true,
4
- "version": "2.2.7",
4
+ "version": "2.2.8",
5
5
  "description": "",
6
6
  "main": "lib/index.js",
7
7
  "module": "src/index.js",
8
8
  "dependencies": {
9
9
  "@material-ui/core": "^3.9.2",
10
10
  "@pie-framework/pie-configure-events": "^1.3.0",
11
- "@pie-lib/pie-toolbox": "2.7.0",
11
+ "@pie-lib/pie-toolbox": "2.7.1",
12
12
  "debug": "^3.1.0",
13
13
  "lodash": "^4.17.15",
14
14
  "prop-types": "^15.6.2",
@@ -3,6 +3,17 @@
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
+ ## [3.1.10](https://github.com/pie-framework/pie-elements/compare/@pie-element/math-templated-controller@3.1.9...@pie-element/math-templated-controller@3.1.10) (2025-01-27)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * update pie-lib/pie-toolbox PD-4688, PD-4589, PD-4616 ([754480c](https://github.com/pie-framework/pie-elements/commit/754480c6c747fa9123d374df0287a644c8376939))
12
+
13
+
14
+
15
+
16
+
6
17
  ## [3.1.9](https://github.com/pie-framework/pie-elements/compare/@pie-element/math-templated-controller@3.1.8...@pie-element/math-templated-controller@3.1.9) (2025-01-22)
7
18
 
8
19
 
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "name": "@pie-element/math-templated-controller",
3
3
  "private": true,
4
- "version": "3.1.9",
4
+ "version": "3.1.10",
5
5
  "description": "",
6
6
  "main": "lib/index.js",
7
7
  "module": "src/index.js",
8
8
  "dependencies": {
9
9
  "@pie-framework/math-validation": "^1.2.3",
10
- "@pie-lib/pie-toolbox": "2.7.0",
10
+ "@pie-lib/pie-toolbox": "2.7.1",
11
11
  "debug": "^3.1.0",
12
12
  "lodash": "^4.17.15"
13
13
  },
@@ -1,5 +1,5 @@
1
1
  import {_dll_react, _dll_prop_types, _dll_classnames, _dll_react_dom, _dll_debug, _dll_lodash} from "../../../@pie-lib/pie-toolbox-math-rendering-module@3.1.0/module/index.js";
2
- import {_dll_pie_lib__pie_toolbox_config_ui, _dll_pie_lib__pie_toolbox_math_toolbar, _dll_pie_lib__pie_toolbox_render_ui, _dll_pie_lib__pie_toolbox_editable_html} from "../../../@pie-lib/pie-toolbox-module@5.7.2/module/index.js";
2
+ import {_dll_pie_lib__pie_toolbox_config_ui, _dll_pie_lib__pie_toolbox_math_toolbar, _dll_pie_lib__pie_toolbox_render_ui, _dll_pie_lib__pie_toolbox_editable_html} from "../../../@pie-lib/pie-toolbox-module@5.8.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;
@@ -115700,6 +115700,7 @@ const require$$15$1 = _dll_debug;
115700
115700
  mml.setMmlFactory(customMmlFactory);
115701
115701
  return html;
115702
115702
  };
115703
+ var enrichSpeechInitialized = false;
115703
115704
  var bootstrap = function bootstrap(opts) {
115704
115705
  if (typeof window === 'undefined') {
115705
115706
  return {
@@ -115717,10 +115718,19 @@ const require$$15$1 = _dll_debug;
115717
115718
  for (var _len = arguments.length, elements = new Array(_len), _key = 0; _key < _len; _key++) {
115718
115719
  elements[_key] = arguments[_key];
115719
115720
  }
115720
- _mathjax.mathjax.handleRetriesFor(function () {
115721
+ var attemptRender = function attemptRender() {
115722
+ var _updatedDocument$math, _updatedDocument$math2;
115723
+ var temporary = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
115721
115724
  var updatedDocument = _this.html.findMath(elements.length ? {
115722
115725
  elements: elements
115723
- } : {}).compile().enrich().getMetrics().typeset().assistiveMml().attachSpeech().addMenu().updateDocument();
115726
+ } : {}).compile();
115727
+ if (!temporary) {
115728
+ updatedDocument = updatedDocument.enrich();
115729
+ }
115730
+ updatedDocument = updatedDocument.getMetrics().typeset().assistiveMml().attachSpeech().addMenu().updateDocument();
115731
+ if (!enrichSpeechInitialized && (0, _typeof2["default"])((_updatedDocument$math = updatedDocument.math.list) === null || _updatedDocument$math === void 0 ? void 0 : (_updatedDocument$math2 = _updatedDocument$math.next) === null || _updatedDocument$math2 === void 0 ? void 0 : _updatedDocument$math2.data) === 'object') {
115732
+ enrichSpeechInitialized = true;
115733
+ }
115724
115734
  try {
115725
115735
  var list = updatedDocument.math.list;
115726
115736
  if (list) {
@@ -115734,6 +115744,12 @@ const require$$15$1 = _dll_debug;
115734
115744
  console.error(e.toString());
115735
115745
  }
115736
115746
  updatedDocument.clear();
115747
+ };
115748
+ if (!enrichSpeechInitialized) {
115749
+ attemptRender(true);
115750
+ }
115751
+ _mathjax.mathjax.handleRetriesFor(function () {
115752
+ attemptRender();
115737
115753
  });
115738
115754
  }
115739
115755
  };
package/module/element.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import {_dll_react, _dll_prop_types, _dll_classnames, _dll_react_dom, _dll_debug, _dll_lodash, _dll_react_dom_server, _dll_pie_framework__mathquill, _dll_pie_lib__pie_toolbox_math_rendering} from "../../../@pie-lib/pie-toolbox-math-rendering-module@3.1.0/module/index.js";
2
- import {_dll_pie_lib__pie_toolbox_math_input, _dll_pie_lib__pie_toolbox_render_ui, _dll_pie_lib__pie_toolbox_correct_answer_toggle} from "../../../@pie-lib/pie-toolbox-module@5.7.2/module/index.js";
2
+ import {_dll_pie_lib__pie_toolbox_math_input, _dll_pie_lib__pie_toolbox_render_ui, _dll_pie_lib__pie_toolbox_correct_answer_toggle} from "../../../@pie-lib/pie-toolbox-module@5.8.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) {
@@ -94948,6 +94948,7 @@ const require$$15$4 = _dll_debug;
94948
94948
  mml.setMmlFactory(customMmlFactory);
94949
94949
  return html;
94950
94950
  };
94951
+ var enrichSpeechInitialized = false;
94951
94952
  var bootstrap = function bootstrap(opts) {
94952
94953
  if (typeof window === 'undefined') {
94953
94954
  return {
@@ -94965,10 +94966,19 @@ const require$$15$4 = _dll_debug;
94965
94966
  for (var _len = arguments.length, elements = new Array(_len), _key = 0; _key < _len; _key++) {
94966
94967
  elements[_key] = arguments[_key];
94967
94968
  }
94968
- _mathjax.mathjax.handleRetriesFor(function () {
94969
+ var attemptRender = function attemptRender() {
94970
+ var _updatedDocument$math, _updatedDocument$math2;
94971
+ var temporary = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
94969
94972
  var updatedDocument = _this.html.findMath(elements.length ? {
94970
94973
  elements: elements
94971
- } : {}).compile().enrich().getMetrics().typeset().assistiveMml().attachSpeech().addMenu().updateDocument();
94974
+ } : {}).compile();
94975
+ if (!temporary) {
94976
+ updatedDocument = updatedDocument.enrich();
94977
+ }
94978
+ updatedDocument = updatedDocument.getMetrics().typeset().assistiveMml().attachSpeech().addMenu().updateDocument();
94979
+ if (!enrichSpeechInitialized && (0, _typeof2["default"])((_updatedDocument$math = updatedDocument.math.list) === null || _updatedDocument$math === void 0 ? void 0 : (_updatedDocument$math2 = _updatedDocument$math.next) === null || _updatedDocument$math2 === void 0 ? void 0 : _updatedDocument$math2.data) === 'object') {
94980
+ enrichSpeechInitialized = true;
94981
+ }
94972
94982
  try {
94973
94983
  var list = updatedDocument.math.list;
94974
94984
  if (list) {
@@ -94982,6 +94992,12 @@ const require$$15$4 = _dll_debug;
94982
94992
  console.error(e.toString());
94983
94993
  }
94984
94994
  updatedDocument.clear();
94995
+ };
94996
+ if (!enrichSpeechInitialized) {
94997
+ attemptRender(true);
94998
+ }
94999
+ _mathjax.mathjax.handleRetriesFor(function () {
95000
+ attemptRender();
94985
95001
  });
94986
95002
  }
94987
95003
  };
@@ -175290,7 +175306,7 @@ const require$$3$6 = _dll_prop_types;
175290
175306
  return _react["default"].createElement("span", (0, _extends2["default"])({}, attributes, {
175291
175307
  style: {
175292
175308
  display: 'inline-flex',
175293
- minHeight: '50px',
175309
+ minHeight: '55px',
175294
175310
  minWidth: '178px',
175295
175311
  position: 'relative',
175296
175312
  cursor: 'pointer'
@@ -175299,14 +175315,14 @@ const require$$3$6 = _dll_prop_types;
175299
175315
  style: {
175300
175316
  display: 'inline-flex',
175301
175317
  width: '100%',
175302
- minHeight: '42px',
175303
- height: '42px',
175318
+ minHeight: '46px',
175319
+ height: '46px',
175304
175320
  backgroundColor: '#FFF',
175305
175321
  border: ("1px solid ").concat(error ? 'red' : '#C0C3CF'),
175306
175322
  boxSizing: 'border-box',
175307
175323
  borderRadius: '4px',
175308
175324
  overflow: 'hidden',
175309
- padding: '10px 21px',
175325
+ padding: '12px 21px',
175310
175326
  marginLeft: '4px'
175311
175327
  },
175312
175328
  dangerouslySetInnerHTML: {
@@ -175389,7 +175405,52 @@ const require$$3$5 = _dll_prop_types;
175389
175405
  display: 'flex',
175390
175406
  alignItems: 'center',
175391
175407
  justifyContent: 'center',
175392
- backgroundColor: 'var(--pie-background, rgba(255, 255, 255, 0))'
175408
+ backgroundColor: 'var(--pie-background, rgba(255, 255, 255, 0))',
175409
+ '& > .mq-math-mode sup.mq-nthroot': {
175410
+ fontSize: '70% !important',
175411
+ verticalAlign: '1em !important'
175412
+ },
175413
+ '& > .mq-math-mode .mq-sqrt-stem': {
175414
+ borderTop: '0.07em solid',
175415
+ marginLeft: '-1.5px',
175416
+ marginTop: '-2px !important',
175417
+ paddingTop: '5px !important'
175418
+ },
175419
+ '& .mq-overarrow-inner': {
175420
+ paddingTop: '0 !important',
175421
+ border: 'none !important'
175422
+ },
175423
+ '& .mq-overarrow.mq-arrow-both': {
175424
+ marginTop: '0px',
175425
+ minWidth: '1.23em',
175426
+ '& *': {
175427
+ lineHeight: '1 !important'
175428
+ },
175429
+ '&:before': {
175430
+ top: '-0.4em',
175431
+ left: '-1px'
175432
+ },
175433
+ '&:after': {
175434
+ top: '0px !important',
175435
+ position: 'absolute !important',
175436
+ right: '-2px'
175437
+ },
175438
+ '&.mq-empty:after': {
175439
+ top: '-0.45em'
175440
+ }
175441
+ },
175442
+ '& .mq-overarrow.mq-arrow-right': {
175443
+ '&:before': {
175444
+ top: '-0.4em',
175445
+ right: '-1px'
175446
+ }
175447
+ },
175448
+ '& .mq-overarrow-inner-right': {
175449
+ display: 'none !important'
175450
+ },
175451
+ '& .mq-overarrow-inner-left': {
175452
+ display: 'none !important'
175453
+ }
175393
175454
  }
175394
175455
  };
175395
175456
  };
@@ -177277,7 +177338,7 @@ const {debounce: require$$16} = _dll_lodash;
177277
177338
  var customToolbarShowDone = node && plugin && plugin.toolbar && plugin.toolbar.showDone && !toolbarOpts.alwaysVisible;
177278
177339
  var defaultToolbarShowDone = !toolbarOpts || toolbarOpts.showDone !== false;
177279
177340
  var hasDoneButton = defaultToolbarShowDone || customToolbarShowDone;
177280
- var names = (0, _classnames["default"])(classes.toolbar, _constants.PIE_TOOLBAR__CLASS, (_classNames = {}, (0, _defineProperty2["default"])(_classNames, classes.toolbarWithNoDone, !hasDoneButton), (0, _defineProperty2["default"])(_classNames, classes.toolbarTop, toolbarOpts.position === 'top'), (0, _defineProperty2["default"])(_classNames, classes.toolbarRight, toolbarOpts.alignment === 'right'), (0, _defineProperty2["default"])(_classNames, classes.focused, toolbarOpts.alwaysVisible || isFocused), (0, _defineProperty2["default"])(_classNames, classes.autoWidth, autoWidth), (0, _defineProperty2["default"])(_classNames, classes.fullWidth, !autoWidth), _classNames));
177341
+ var names = (0, _classnames["default"])(classes.toolbar, _constants.PIE_TOOLBAR__CLASS, (_classNames = {}, (0, _defineProperty2["default"])(_classNames, classes.toolbarWithNoDone, !hasDoneButton), (0, _defineProperty2["default"])(_classNames, classes.toolbarTop, toolbarOpts.position === 'top'), (0, _defineProperty2["default"])(_classNames, classes.toolbarRight, toolbarOpts.alignment === 'right'), (0, _defineProperty2["default"])(_classNames, classes.focused, toolbarOpts.alwaysVisible || isFocused), (0, _defineProperty2["default"])(_classNames, classes.autoWidth, autoWidth), (0, _defineProperty2["default"])(_classNames, classes.fullWidth, !autoWidth), (0, _defineProperty2["default"])(_classNames, classes.hidden, toolbarOpts.isHidden === true), _classNames));
177281
177342
  var customStyles = toolbarOpts.minWidth !== undefined ? {
177282
177343
  minWidth: toolbarOpts.minWidth
177283
177344
  } : {};
@@ -177346,7 +177407,8 @@ const {debounce: require$$16} = _dll_lodash;
177346
177407
  alwaysVisible: _propTypes["default"].bool,
177347
177408
  ref: _propTypes["default"].func,
177348
177409
  showDone: _propTypes["default"].bool,
177349
- minWidth: _propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].number])
177410
+ minWidth: _propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].number]),
177411
+ isHidden: _propTypes["default"].bool
177350
177412
  }),
177351
177413
  onDataChange: _propTypes["default"].func,
177352
177414
  doneButtonRef: _propTypes["default"].func,
@@ -177381,6 +177443,9 @@ const {debounce: require$$16} = _dll_lodash;
177381
177443
  fullWidth: {
177382
177444
  width: '100%'
177383
177445
  },
177446
+ hidden: {
177447
+ visibility: 'hidden'
177448
+ },
177384
177449
  autoWidth: {
177385
177450
  width: 'auto'
177386
177451
  },
@@ -180159,7 +180224,7 @@ const require$$6 = _dll_classnames;
180159
180224
  var adjustedLimit = props.adjustedLimit, disabled = props.disabled, feedback = props.feedback, showCorrectAnswer = props.showCorrectAnswer, maxLength = props.maxLength, spellCheck = props.spellCheck, classes = props.classes, pluginProps = props.pluginProps, onChange = props.onChange;
180160
180225
  var dataset = ((_node$data = node.data) === null || _node$data === void 0 ? void 0 : _node$data.dataset) || ({});
180161
180226
  if (dataset.component === 'input') {
180162
- var _classnames;
180227
+ var _pluginProps$characte, _classnames;
180163
180228
  var correctAnswer = (props.choices && dataset && props.choices[dataset.id] || [])[0];
180164
180229
  var finalValue = showCorrectAnswer ? correctAnswer && correctAnswer.label : data[dataset.id] || '';
180165
180230
  var width = maxLength && maxLength[dataset.id];
@@ -180190,9 +180255,11 @@ const require$$6 = _dll_classnames;
180190
180255
  spellCheck: spellCheck,
180191
180256
  width: ("calc(").concat(width, "ch + 42px)"),
180192
180257
  onKeyDown: handleKeyDown,
180258
+ autoWidthToolbar: true,
180193
180259
  toolbarOpts: {
180194
180260
  minWidth: 'auto',
180195
- noBorder: true
180261
+ noBorder: true,
180262
+ isHidden: !!(pluginProps !== null && pluginProps !== void 0 && (_pluginProps$characte = pluginProps.characters) !== null && _pluginProps$characte !== void 0 && _pluginProps$characte.disabled)
180196
180263
  },
180197
180264
  className: (0, _classnames2["default"])(classes.editableHtmlCustom, (_classnames = {}, (0, _defineProperty2["default"])(_classnames, classes.correct, isCorrect), (0, _defineProperty2["default"])(_classnames, classes.incorrect, isIncorrect), _classnames))
180198
180265
  });
@@ -8,7 +8,7 @@
8
8
  },
9
9
  {
10
10
  "name": "@pie-lib/pie-toolbox-module",
11
- "version": "5.7.2"
11
+ "version": "5.8.0"
12
12
  }
13
13
  ]
14
14
  }
package/module/print.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import {_dll_react, _dll_prop_types, _dll_classnames, _dll_react_dom, _dll_debug, _dll_lodash, _dll_react_dom_server, _dll_pie_framework__mathquill, _dll_pie_lib__pie_toolbox_math_rendering} from "../../../@pie-lib/pie-toolbox-math-rendering-module@3.1.0/module/index.js";
2
- import {_dll_pie_lib__pie_toolbox_math_input, _dll_pie_lib__pie_toolbox_render_ui, _dll_pie_lib__pie_toolbox_correct_answer_toggle} from "../../../@pie-lib/pie-toolbox-module@5.7.2/module/index.js";
2
+ import {_dll_pie_lib__pie_toolbox_math_input, _dll_pie_lib__pie_toolbox_render_ui, _dll_pie_lib__pie_toolbox_correct_answer_toggle} from "../../../@pie-lib/pie-toolbox-module@5.8.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) {
@@ -94911,6 +94911,7 @@ const require$$15$4 = _dll_debug;
94911
94911
  mml.setMmlFactory(customMmlFactory);
94912
94912
  return html;
94913
94913
  };
94914
+ var enrichSpeechInitialized = false;
94914
94915
  var bootstrap = function bootstrap(opts) {
94915
94916
  if (typeof window === 'undefined') {
94916
94917
  return {
@@ -94928,10 +94929,19 @@ const require$$15$4 = _dll_debug;
94928
94929
  for (var _len = arguments.length, elements = new Array(_len), _key = 0; _key < _len; _key++) {
94929
94930
  elements[_key] = arguments[_key];
94930
94931
  }
94931
- _mathjax.mathjax.handleRetriesFor(function () {
94932
+ var attemptRender = function attemptRender() {
94933
+ var _updatedDocument$math, _updatedDocument$math2;
94934
+ var temporary = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
94932
94935
  var updatedDocument = _this.html.findMath(elements.length ? {
94933
94936
  elements: elements
94934
- } : {}).compile().enrich().getMetrics().typeset().assistiveMml().attachSpeech().addMenu().updateDocument();
94937
+ } : {}).compile();
94938
+ if (!temporary) {
94939
+ updatedDocument = updatedDocument.enrich();
94940
+ }
94941
+ updatedDocument = updatedDocument.getMetrics().typeset().assistiveMml().attachSpeech().addMenu().updateDocument();
94942
+ if (!enrichSpeechInitialized && (0, _typeof2["default"])((_updatedDocument$math = updatedDocument.math.list) === null || _updatedDocument$math === void 0 ? void 0 : (_updatedDocument$math2 = _updatedDocument$math.next) === null || _updatedDocument$math2 === void 0 ? void 0 : _updatedDocument$math2.data) === 'object') {
94943
+ enrichSpeechInitialized = true;
94944
+ }
94935
94945
  try {
94936
94946
  var list = updatedDocument.math.list;
94937
94947
  if (list) {
@@ -94945,6 +94955,12 @@ const require$$15$4 = _dll_debug;
94945
94955
  console.error(e.toString());
94946
94956
  }
94947
94957
  updatedDocument.clear();
94958
+ };
94959
+ if (!enrichSpeechInitialized) {
94960
+ attemptRender(true);
94961
+ }
94962
+ _mathjax.mathjax.handleRetriesFor(function () {
94963
+ attemptRender();
94948
94964
  });
94949
94965
  }
94950
94966
  };
@@ -175253,7 +175269,7 @@ const require$$3$6 = _dll_prop_types;
175253
175269
  return _react["default"].createElement("span", (0, _extends2["default"])({}, attributes, {
175254
175270
  style: {
175255
175271
  display: 'inline-flex',
175256
- minHeight: '50px',
175272
+ minHeight: '55px',
175257
175273
  minWidth: '178px',
175258
175274
  position: 'relative',
175259
175275
  cursor: 'pointer'
@@ -175262,14 +175278,14 @@ const require$$3$6 = _dll_prop_types;
175262
175278
  style: {
175263
175279
  display: 'inline-flex',
175264
175280
  width: '100%',
175265
- minHeight: '42px',
175266
- height: '42px',
175281
+ minHeight: '46px',
175282
+ height: '46px',
175267
175283
  backgroundColor: '#FFF',
175268
175284
  border: ("1px solid ").concat(error ? 'red' : '#C0C3CF'),
175269
175285
  boxSizing: 'border-box',
175270
175286
  borderRadius: '4px',
175271
175287
  overflow: 'hidden',
175272
- padding: '10px 21px',
175288
+ padding: '12px 21px',
175273
175289
  marginLeft: '4px'
175274
175290
  },
175275
175291
  dangerouslySetInnerHTML: {
@@ -175352,7 +175368,52 @@ const require$$3$5 = _dll_prop_types;
175352
175368
  display: 'flex',
175353
175369
  alignItems: 'center',
175354
175370
  justifyContent: 'center',
175355
- backgroundColor: 'var(--pie-background, rgba(255, 255, 255, 0))'
175371
+ backgroundColor: 'var(--pie-background, rgba(255, 255, 255, 0))',
175372
+ '& > .mq-math-mode sup.mq-nthroot': {
175373
+ fontSize: '70% !important',
175374
+ verticalAlign: '1em !important'
175375
+ },
175376
+ '& > .mq-math-mode .mq-sqrt-stem': {
175377
+ borderTop: '0.07em solid',
175378
+ marginLeft: '-1.5px',
175379
+ marginTop: '-2px !important',
175380
+ paddingTop: '5px !important'
175381
+ },
175382
+ '& .mq-overarrow-inner': {
175383
+ paddingTop: '0 !important',
175384
+ border: 'none !important'
175385
+ },
175386
+ '& .mq-overarrow.mq-arrow-both': {
175387
+ marginTop: '0px',
175388
+ minWidth: '1.23em',
175389
+ '& *': {
175390
+ lineHeight: '1 !important'
175391
+ },
175392
+ '&:before': {
175393
+ top: '-0.4em',
175394
+ left: '-1px'
175395
+ },
175396
+ '&:after': {
175397
+ top: '0px !important',
175398
+ position: 'absolute !important',
175399
+ right: '-2px'
175400
+ },
175401
+ '&.mq-empty:after': {
175402
+ top: '-0.45em'
175403
+ }
175404
+ },
175405
+ '& .mq-overarrow.mq-arrow-right': {
175406
+ '&:before': {
175407
+ top: '-0.4em',
175408
+ right: '-1px'
175409
+ }
175410
+ },
175411
+ '& .mq-overarrow-inner-right': {
175412
+ display: 'none !important'
175413
+ },
175414
+ '& .mq-overarrow-inner-left': {
175415
+ display: 'none !important'
175416
+ }
175356
175417
  }
175357
175418
  };
175358
175419
  };
@@ -177240,7 +177301,7 @@ const {debounce: require$$16} = _dll_lodash;
177240
177301
  var customToolbarShowDone = node && plugin && plugin.toolbar && plugin.toolbar.showDone && !toolbarOpts.alwaysVisible;
177241
177302
  var defaultToolbarShowDone = !toolbarOpts || toolbarOpts.showDone !== false;
177242
177303
  var hasDoneButton = defaultToolbarShowDone || customToolbarShowDone;
177243
- var names = (0, _classnames["default"])(classes.toolbar, _constants.PIE_TOOLBAR__CLASS, (_classNames = {}, (0, _defineProperty2["default"])(_classNames, classes.toolbarWithNoDone, !hasDoneButton), (0, _defineProperty2["default"])(_classNames, classes.toolbarTop, toolbarOpts.position === 'top'), (0, _defineProperty2["default"])(_classNames, classes.toolbarRight, toolbarOpts.alignment === 'right'), (0, _defineProperty2["default"])(_classNames, classes.focused, toolbarOpts.alwaysVisible || isFocused), (0, _defineProperty2["default"])(_classNames, classes.autoWidth, autoWidth), (0, _defineProperty2["default"])(_classNames, classes.fullWidth, !autoWidth), _classNames));
177304
+ var names = (0, _classnames["default"])(classes.toolbar, _constants.PIE_TOOLBAR__CLASS, (_classNames = {}, (0, _defineProperty2["default"])(_classNames, classes.toolbarWithNoDone, !hasDoneButton), (0, _defineProperty2["default"])(_classNames, classes.toolbarTop, toolbarOpts.position === 'top'), (0, _defineProperty2["default"])(_classNames, classes.toolbarRight, toolbarOpts.alignment === 'right'), (0, _defineProperty2["default"])(_classNames, classes.focused, toolbarOpts.alwaysVisible || isFocused), (0, _defineProperty2["default"])(_classNames, classes.autoWidth, autoWidth), (0, _defineProperty2["default"])(_classNames, classes.fullWidth, !autoWidth), (0, _defineProperty2["default"])(_classNames, classes.hidden, toolbarOpts.isHidden === true), _classNames));
177244
177305
  var customStyles = toolbarOpts.minWidth !== undefined ? {
177245
177306
  minWidth: toolbarOpts.minWidth
177246
177307
  } : {};
@@ -177309,7 +177370,8 @@ const {debounce: require$$16} = _dll_lodash;
177309
177370
  alwaysVisible: _propTypes["default"].bool,
177310
177371
  ref: _propTypes["default"].func,
177311
177372
  showDone: _propTypes["default"].bool,
177312
- minWidth: _propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].number])
177373
+ minWidth: _propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].number]),
177374
+ isHidden: _propTypes["default"].bool
177313
177375
  }),
177314
177376
  onDataChange: _propTypes["default"].func,
177315
177377
  doneButtonRef: _propTypes["default"].func,
@@ -177344,6 +177406,9 @@ const {debounce: require$$16} = _dll_lodash;
177344
177406
  fullWidth: {
177345
177407
  width: '100%'
177346
177408
  },
177409
+ hidden: {
177410
+ visibility: 'hidden'
177411
+ },
177347
177412
  autoWidth: {
177348
177413
  width: 'auto'
177349
177414
  },
@@ -180122,7 +180187,7 @@ const require$$6 = _dll_classnames;
180122
180187
  var adjustedLimit = props.adjustedLimit, disabled = props.disabled, feedback = props.feedback, showCorrectAnswer = props.showCorrectAnswer, maxLength = props.maxLength, spellCheck = props.spellCheck, classes = props.classes, pluginProps = props.pluginProps, onChange = props.onChange;
180123
180188
  var dataset = ((_node$data = node.data) === null || _node$data === void 0 ? void 0 : _node$data.dataset) || ({});
180124
180189
  if (dataset.component === 'input') {
180125
- var _classnames;
180190
+ var _pluginProps$characte, _classnames;
180126
180191
  var correctAnswer = (props.choices && dataset && props.choices[dataset.id] || [])[0];
180127
180192
  var finalValue = showCorrectAnswer ? correctAnswer && correctAnswer.label : data[dataset.id] || '';
180128
180193
  var width = maxLength && maxLength[dataset.id];
@@ -180153,9 +180218,11 @@ const require$$6 = _dll_classnames;
180153
180218
  spellCheck: spellCheck,
180154
180219
  width: ("calc(").concat(width, "ch + 42px)"),
180155
180220
  onKeyDown: handleKeyDown,
180221
+ autoWidthToolbar: true,
180156
180222
  toolbarOpts: {
180157
180223
  minWidth: 'auto',
180158
- noBorder: true
180224
+ noBorder: true,
180225
+ isHidden: !!(pluginProps !== null && pluginProps !== void 0 && (_pluginProps$characte = pluginProps.characters) !== null && _pluginProps$characte !== void 0 && _pluginProps$characte.disabled)
180159
180226
  },
180160
180227
  className: (0, _classnames2["default"])(classes.editableHtmlCustom, (_classnames = {}, (0, _defineProperty2["default"])(_classnames, classes.correct, isCorrect), (0, _defineProperty2["default"])(_classnames, classes.incorrect, isIncorrect), _classnames))
180161
180228
  });
package/package.json CHANGED
@@ -4,19 +4,19 @@
4
4
  "access": "public"
5
5
  },
6
6
  "repository": "pie-framework/pie-elements",
7
- "version": "3.3.8-next.5+75922d067",
7
+ "version": "3.3.8",
8
8
  "description": "",
9
9
  "dependencies": {
10
10
  "@material-ui/core": "^3.9.2",
11
11
  "@pie-framework/pie-player-events": "^0.1.0",
12
- "@pie-lib/pie-toolbox": "2.7.0",
12
+ "@pie-lib/pie-toolbox": "2.7.1",
13
13
  "prop-types": "^15.6.1",
14
14
  "react": "^16.8.1",
15
15
  "react-dom": "^16.8.1"
16
16
  },
17
17
  "author": "",
18
18
  "license": "ISC",
19
- "gitHead": "75922d0676250f6d5714747c7191cef245bbb1ff",
19
+ "gitHead": "2c0186825adb965893eadb3fc6b7c71389caa6bf",
20
20
  "scripts": {
21
21
  "postpublish": "../../scripts/postpublish"
22
22
  },