@pie-element/complex-rubric 3.4.7-next.20 → 3.4.7-next.27
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/controller/package.json +1 -1
- package/module/configure.js +24 -10
- package/module/element.js +24 -10
- package/module/manifest.json +2 -2
- package/module/print.js +24 -10
- package/package.json +4 -4
package/controller/package.json
CHANGED
package/module/configure.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {_dll_react, _dll_prop_types, _dll_classnames, _dll_react_dom, _dll_debug, _dll_lodash, _dll_react_dom_server, _dll_pie_framework__mathquill} from "../../../@pie-lib/pie-toolbox-math-rendering-module@3.
|
|
1
|
+
import {_dll_react, _dll_prop_types, _dll_classnames, _dll_react_dom, _dll_debug, _dll_lodash, _dll_react_dom_server, _dll_pie_framework__mathquill} from "../../../@pie-lib/pie-toolbox-math-rendering-module@3.4.0/module/index.js";
|
|
2
2
|
import RubricConfigure from '@pie-element/rubric/configure/lib';
|
|
3
|
-
import {_dll_pie_lib__pie_toolbox_editable_html, _dll_pie_lib__pie_toolbox_render_ui, _dll_pie_lib__pie_toolbox_config_ui} from "../../../@pie-lib/pie-toolbox-module@5.
|
|
3
|
+
import {_dll_pie_lib__pie_toolbox_editable_html, _dll_pie_lib__pie_toolbox_render_ui, _dll_pie_lib__pie_toolbox_config_ui} from "../../../@pie-lib/pie-toolbox-module@5.11.0/module/index.js";
|
|
4
4
|
function _mergeNamespaces(n, m) {
|
|
5
5
|
m.forEach(function (e) {
|
|
6
6
|
e && typeof e !== 'string' && !Array.isArray(e) && Object.keys(e).forEach(function (k) {
|
|
@@ -125763,10 +125763,15 @@ const {omit: require$$13$d} = _dll_lodash;
|
|
|
125763
125763
|
(0, _createClass2["default"])(UiLayout, [{
|
|
125764
125764
|
key: "computeStyle",
|
|
125765
125765
|
value: function computeStyle(fontSizeFactor) {
|
|
125766
|
-
var
|
|
125767
|
-
|
|
125768
|
-
fontSize: ("").concat(rootFontSize * fontSizeFactor, "px")
|
|
125766
|
+
var getFontSize = function getFontSize(element) {
|
|
125767
|
+
return parseFloat(getComputedStyle(element).fontSize);
|
|
125769
125768
|
};
|
|
125769
|
+
var rootFontSize = getFontSize(document.documentElement);
|
|
125770
|
+
var bodyFontSize = getFontSize(document.body);
|
|
125771
|
+
var effectiveFontSize = Math.max(rootFontSize, bodyFontSize);
|
|
125772
|
+
return fontSizeFactor !== 1 ? {
|
|
125773
|
+
fontSize: ("").concat(effectiveFontSize * fontSizeFactor, "px")
|
|
125774
|
+
} : null;
|
|
125770
125775
|
}
|
|
125771
125776
|
}, {
|
|
125772
125777
|
key: "render",
|
|
@@ -125774,11 +125779,12 @@ const {omit: require$$13$d} = _dll_lodash;
|
|
|
125774
125779
|
var _this$props = this.props, children = _this$props.children, className = _this$props.className, classes = _this$props.classes, fontSizeFactor = _this$props.fontSizeFactor, rest = (0, _objectWithoutProperties2["default"])(_this$props, _excluded);
|
|
125775
125780
|
var finalClass = (0, _classnames["default"])(className, classes.extraCSSRules, classes.uiLayoutContainer);
|
|
125776
125781
|
var restProps = (0, _omit["default"])(rest, 'extraCSSRules');
|
|
125782
|
+
var style = this.computeStyle(fontSizeFactor);
|
|
125777
125783
|
return _react["default"].createElement("div", (0, _extends2["default"])({
|
|
125778
125784
|
className: finalClass
|
|
125779
|
-
}, restProps, {
|
|
125780
|
-
style:
|
|
125781
|
-
}), children);
|
|
125785
|
+
}, restProps, style && ({
|
|
125786
|
+
style: style
|
|
125787
|
+
})), children);
|
|
125782
125788
|
}
|
|
125783
125789
|
}]);
|
|
125784
125790
|
return UiLayout;
|
|
@@ -177001,6 +177007,7 @@ const require$$3$d = _dll_prop_types;
|
|
|
177001
177007
|
return _react["default"].createElement("span", (0, _extends2["default"])({}, attributes, {
|
|
177002
177008
|
style: {
|
|
177003
177009
|
display: 'inline-flex',
|
|
177010
|
+
visibility: props.isFocused ? 'hidden' : 'visible',
|
|
177004
177011
|
minHeight: '55px',
|
|
177005
177012
|
minWidth: '178px',
|
|
177006
177013
|
position: 'relative',
|
|
@@ -177028,7 +177035,8 @@ const require$$3$d = _dll_prop_types;
|
|
|
177028
177035
|
ExplicitConstructedResponse.propTypes = {
|
|
177029
177036
|
attributes: _propTypes["default"].object,
|
|
177030
177037
|
error: _propTypes["default"].any,
|
|
177031
|
-
value: _propTypes["default"].string
|
|
177038
|
+
value: _propTypes["default"].string,
|
|
177039
|
+
isFocused: _propTypes["default"].bool
|
|
177032
177040
|
};
|
|
177033
177041
|
var _default = ExplicitConstructedResponse;
|
|
177034
177042
|
exports["default"] = _default;
|
|
@@ -177354,7 +177362,7 @@ const {isUndefined: require$$3$b} = _dll_lodash;
|
|
|
177354
177362
|
onChange(change);
|
|
177355
177363
|
},
|
|
177356
177364
|
renderNode: function renderNode(props) {
|
|
177357
|
-
var attributes = props.attributes, n = props.node;
|
|
177365
|
+
var attributes = props.attributes, n = props.node, isFocused = props.isFocused;
|
|
177358
177366
|
if (n.type === 'explicit_constructed_response') {
|
|
177359
177367
|
var data = n.data.toJSON();
|
|
177360
177368
|
var error;
|
|
@@ -177363,6 +177371,7 @@ const {isUndefined: require$$3$b} = _dll_lodash;
|
|
|
177363
177371
|
}
|
|
177364
177372
|
return _react["default"].createElement(_explicitConstructedResponse["default"], {
|
|
177365
177373
|
attributes: attributes,
|
|
177374
|
+
isFocused: isFocused,
|
|
177366
177375
|
value: data.value,
|
|
177367
177376
|
error: error && error[data.index] && error[data.index][0]
|
|
177368
177377
|
});
|
|
@@ -181784,6 +181793,11 @@ const require$$21 = _dll_debug;
|
|
|
181784
181793
|
},
|
|
181785
181794
|
'& table:not([border="1"]) td, th': {
|
|
181786
181795
|
border: '1px solid #dfe2e5'
|
|
181796
|
+
},
|
|
181797
|
+
'& > div::after': {
|
|
181798
|
+
display: 'block',
|
|
181799
|
+
content: '"¶"',
|
|
181800
|
+
color: '#146EB3'
|
|
181787
181801
|
}
|
|
181788
181802
|
},
|
|
181789
181803
|
toolbarOnTop: {
|
package/module/element.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {_dll_react, _dll_prop_types, _dll_react_dom, _dll_classnames, _dll_debug, _dll_pie_lib__pie_toolbox_math_rendering, _dll_lodash, _dll_react_dom_server, _dll_pie_framework__mathquill} from "../../../@pie-lib/pie-toolbox-math-rendering-module@3.
|
|
2
|
-
import {_dll_pie_lib__pie_toolbox_render_ui} from "../../../@pie-lib/pie-toolbox-module@5.
|
|
1
|
+
import {_dll_react, _dll_prop_types, _dll_react_dom, _dll_classnames, _dll_debug, _dll_pie_lib__pie_toolbox_math_rendering, _dll_lodash, _dll_react_dom_server, _dll_pie_framework__mathquill} from "../../../@pie-lib/pie-toolbox-math-rendering-module@3.4.0/module/index.js";
|
|
2
|
+
import {_dll_pie_lib__pie_toolbox_render_ui} from "../../../@pie-lib/pie-toolbox-module@5.11.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) {
|
|
@@ -142228,10 +142228,15 @@ const {omit: require$$13$b} = _dll_lodash;
|
|
|
142228
142228
|
(0, _createClass2["default"])(UiLayout, [{
|
|
142229
142229
|
key: "computeStyle",
|
|
142230
142230
|
value: function computeStyle(fontSizeFactor) {
|
|
142231
|
-
var
|
|
142232
|
-
|
|
142233
|
-
fontSize: ("").concat(rootFontSize * fontSizeFactor, "px")
|
|
142231
|
+
var getFontSize = function getFontSize(element) {
|
|
142232
|
+
return parseFloat(getComputedStyle(element).fontSize);
|
|
142234
142233
|
};
|
|
142234
|
+
var rootFontSize = getFontSize(document.documentElement);
|
|
142235
|
+
var bodyFontSize = getFontSize(document.body);
|
|
142236
|
+
var effectiveFontSize = Math.max(rootFontSize, bodyFontSize);
|
|
142237
|
+
return fontSizeFactor !== 1 ? {
|
|
142238
|
+
fontSize: ("").concat(effectiveFontSize * fontSizeFactor, "px")
|
|
142239
|
+
} : null;
|
|
142235
142240
|
}
|
|
142236
142241
|
}, {
|
|
142237
142242
|
key: "render",
|
|
@@ -142239,11 +142244,12 @@ const {omit: require$$13$b} = _dll_lodash;
|
|
|
142239
142244
|
var _this$props = this.props, children = _this$props.children, className = _this$props.className, classes = _this$props.classes, fontSizeFactor = _this$props.fontSizeFactor, rest = (0, _objectWithoutProperties2["default"])(_this$props, _excluded);
|
|
142240
142245
|
var finalClass = (0, _classnames["default"])(className, classes.extraCSSRules, classes.uiLayoutContainer);
|
|
142241
142246
|
var restProps = (0, _omit["default"])(rest, 'extraCSSRules');
|
|
142247
|
+
var style = this.computeStyle(fontSizeFactor);
|
|
142242
142248
|
return _react["default"].createElement("div", (0, _extends2["default"])({
|
|
142243
142249
|
className: finalClass
|
|
142244
|
-
}, restProps, {
|
|
142245
|
-
style:
|
|
142246
|
-
}), children);
|
|
142250
|
+
}, restProps, style && ({
|
|
142251
|
+
style: style
|
|
142252
|
+
})), children);
|
|
142247
142253
|
}
|
|
142248
142254
|
}]);
|
|
142249
142255
|
return UiLayout;
|
|
@@ -175075,6 +175081,7 @@ const require$$3$d = _dll_prop_types;
|
|
|
175075
175081
|
return _react["default"].createElement("span", (0, _extends2["default"])({}, attributes, {
|
|
175076
175082
|
style: {
|
|
175077
175083
|
display: 'inline-flex',
|
|
175084
|
+
visibility: props.isFocused ? 'hidden' : 'visible',
|
|
175078
175085
|
minHeight: '55px',
|
|
175079
175086
|
minWidth: '178px',
|
|
175080
175087
|
position: 'relative',
|
|
@@ -175102,7 +175109,8 @@ const require$$3$d = _dll_prop_types;
|
|
|
175102
175109
|
ExplicitConstructedResponse.propTypes = {
|
|
175103
175110
|
attributes: _propTypes["default"].object,
|
|
175104
175111
|
error: _propTypes["default"].any,
|
|
175105
|
-
value: _propTypes["default"].string
|
|
175112
|
+
value: _propTypes["default"].string,
|
|
175113
|
+
isFocused: _propTypes["default"].bool
|
|
175106
175114
|
};
|
|
175107
175115
|
var _default = ExplicitConstructedResponse;
|
|
175108
175116
|
exports["default"] = _default;
|
|
@@ -175428,7 +175436,7 @@ const {isUndefined: require$$3$b} = _dll_lodash;
|
|
|
175428
175436
|
onChange(change);
|
|
175429
175437
|
},
|
|
175430
175438
|
renderNode: function renderNode(props) {
|
|
175431
|
-
var attributes = props.attributes, n = props.node;
|
|
175439
|
+
var attributes = props.attributes, n = props.node, isFocused = props.isFocused;
|
|
175432
175440
|
if (n.type === 'explicit_constructed_response') {
|
|
175433
175441
|
var data = n.data.toJSON();
|
|
175434
175442
|
var error;
|
|
@@ -175437,6 +175445,7 @@ const {isUndefined: require$$3$b} = _dll_lodash;
|
|
|
175437
175445
|
}
|
|
175438
175446
|
return _react["default"].createElement(_explicitConstructedResponse["default"], {
|
|
175439
175447
|
attributes: attributes,
|
|
175448
|
+
isFocused: isFocused,
|
|
175440
175449
|
value: data.value,
|
|
175441
175450
|
error: error && error[data.index] && error[data.index][0]
|
|
175442
175451
|
});
|
|
@@ -179858,6 +179867,11 @@ const require$$21 = _dll_debug;
|
|
|
179858
179867
|
},
|
|
179859
179868
|
'& table:not([border="1"]) td, th': {
|
|
179860
179869
|
border: '1px solid #dfe2e5'
|
|
179870
|
+
},
|
|
179871
|
+
'& > div::after': {
|
|
179872
|
+
display: 'block',
|
|
179873
|
+
content: '"¶"',
|
|
179874
|
+
color: '#146EB3'
|
|
179861
179875
|
}
|
|
179862
179876
|
},
|
|
179863
179877
|
toolbarOnTop: {
|
package/module/manifest.json
CHANGED
package/module/print.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {_dll_react, _dll_prop_types, _dll_react_dom, _dll_classnames, _dll_debug, _dll_pie_lib__pie_toolbox_math_rendering, _dll_lodash, _dll_react_dom_server, _dll_pie_framework__mathquill} from "../../../@pie-lib/pie-toolbox-math-rendering-module@3.
|
|
2
|
-
import {_dll_pie_lib__pie_toolbox_render_ui} from "../../../@pie-lib/pie-toolbox-module@5.
|
|
1
|
+
import {_dll_react, _dll_prop_types, _dll_react_dom, _dll_classnames, _dll_debug, _dll_pie_lib__pie_toolbox_math_rendering, _dll_lodash, _dll_react_dom_server, _dll_pie_framework__mathquill} from "../../../@pie-lib/pie-toolbox-math-rendering-module@3.4.0/module/index.js";
|
|
2
|
+
import {_dll_pie_lib__pie_toolbox_render_ui} from "../../../@pie-lib/pie-toolbox-module@5.11.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) {
|
|
@@ -142228,10 +142228,15 @@ const {omit: require$$13$b} = _dll_lodash;
|
|
|
142228
142228
|
(0, _createClass2["default"])(UiLayout, [{
|
|
142229
142229
|
key: "computeStyle",
|
|
142230
142230
|
value: function computeStyle(fontSizeFactor) {
|
|
142231
|
-
var
|
|
142232
|
-
|
|
142233
|
-
fontSize: ("").concat(rootFontSize * fontSizeFactor, "px")
|
|
142231
|
+
var getFontSize = function getFontSize(element) {
|
|
142232
|
+
return parseFloat(getComputedStyle(element).fontSize);
|
|
142234
142233
|
};
|
|
142234
|
+
var rootFontSize = getFontSize(document.documentElement);
|
|
142235
|
+
var bodyFontSize = getFontSize(document.body);
|
|
142236
|
+
var effectiveFontSize = Math.max(rootFontSize, bodyFontSize);
|
|
142237
|
+
return fontSizeFactor !== 1 ? {
|
|
142238
|
+
fontSize: ("").concat(effectiveFontSize * fontSizeFactor, "px")
|
|
142239
|
+
} : null;
|
|
142235
142240
|
}
|
|
142236
142241
|
}, {
|
|
142237
142242
|
key: "render",
|
|
@@ -142239,11 +142244,12 @@ const {omit: require$$13$b} = _dll_lodash;
|
|
|
142239
142244
|
var _this$props = this.props, children = _this$props.children, className = _this$props.className, classes = _this$props.classes, fontSizeFactor = _this$props.fontSizeFactor, rest = (0, _objectWithoutProperties2["default"])(_this$props, _excluded);
|
|
142240
142245
|
var finalClass = (0, _classnames["default"])(className, classes.extraCSSRules, classes.uiLayoutContainer);
|
|
142241
142246
|
var restProps = (0, _omit["default"])(rest, 'extraCSSRules');
|
|
142247
|
+
var style = this.computeStyle(fontSizeFactor);
|
|
142242
142248
|
return _react["default"].createElement("div", (0, _extends2["default"])({
|
|
142243
142249
|
className: finalClass
|
|
142244
|
-
}, restProps, {
|
|
142245
|
-
style:
|
|
142246
|
-
}), children);
|
|
142250
|
+
}, restProps, style && ({
|
|
142251
|
+
style: style
|
|
142252
|
+
})), children);
|
|
142247
142253
|
}
|
|
142248
142254
|
}]);
|
|
142249
142255
|
return UiLayout;
|
|
@@ -175075,6 +175081,7 @@ const require$$3$d = _dll_prop_types;
|
|
|
175075
175081
|
return _react["default"].createElement("span", (0, _extends2["default"])({}, attributes, {
|
|
175076
175082
|
style: {
|
|
175077
175083
|
display: 'inline-flex',
|
|
175084
|
+
visibility: props.isFocused ? 'hidden' : 'visible',
|
|
175078
175085
|
minHeight: '55px',
|
|
175079
175086
|
minWidth: '178px',
|
|
175080
175087
|
position: 'relative',
|
|
@@ -175102,7 +175109,8 @@ const require$$3$d = _dll_prop_types;
|
|
|
175102
175109
|
ExplicitConstructedResponse.propTypes = {
|
|
175103
175110
|
attributes: _propTypes["default"].object,
|
|
175104
175111
|
error: _propTypes["default"].any,
|
|
175105
|
-
value: _propTypes["default"].string
|
|
175112
|
+
value: _propTypes["default"].string,
|
|
175113
|
+
isFocused: _propTypes["default"].bool
|
|
175106
175114
|
};
|
|
175107
175115
|
var _default = ExplicitConstructedResponse;
|
|
175108
175116
|
exports["default"] = _default;
|
|
@@ -175428,7 +175436,7 @@ const {isUndefined: require$$3$b} = _dll_lodash;
|
|
|
175428
175436
|
onChange(change);
|
|
175429
175437
|
},
|
|
175430
175438
|
renderNode: function renderNode(props) {
|
|
175431
|
-
var attributes = props.attributes, n = props.node;
|
|
175439
|
+
var attributes = props.attributes, n = props.node, isFocused = props.isFocused;
|
|
175432
175440
|
if (n.type === 'explicit_constructed_response') {
|
|
175433
175441
|
var data = n.data.toJSON();
|
|
175434
175442
|
var error;
|
|
@@ -175437,6 +175445,7 @@ const {isUndefined: require$$3$b} = _dll_lodash;
|
|
|
175437
175445
|
}
|
|
175438
175446
|
return _react["default"].createElement(_explicitConstructedResponse["default"], {
|
|
175439
175447
|
attributes: attributes,
|
|
175448
|
+
isFocused: isFocused,
|
|
175440
175449
|
value: data.value,
|
|
175441
175450
|
error: error && error[data.index] && error[data.index][0]
|
|
175442
175451
|
});
|
|
@@ -179858,6 +179867,11 @@ const require$$21 = _dll_debug;
|
|
|
179858
179867
|
},
|
|
179859
179868
|
'& table:not([border="1"]) td, th': {
|
|
179860
179869
|
border: '1px solid #dfe2e5'
|
|
179870
|
+
},
|
|
179871
|
+
'& > div::after': {
|
|
179872
|
+
display: 'block',
|
|
179873
|
+
content: '"¶"',
|
|
179874
|
+
color: '#146EB3'
|
|
179861
179875
|
}
|
|
179862
179876
|
},
|
|
179863
179877
|
toolbarOnTop: {
|
package/package.json
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pie-element/complex-rubric",
|
|
3
3
|
"repository": "pie-framework/pie-elements",
|
|
4
|
-
"version": "3.4.7-next.
|
|
4
|
+
"version": "3.4.7-next.27+622eab7fb",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
8
8
|
"dependencies": {
|
|
9
9
|
"@material-ui/core": "^3.9.2",
|
|
10
|
-
"@pie-element/multi-trait-rubric": "^4.3.7-next.
|
|
11
|
-
"@pie-element/rubric": "^4.4.7-next.
|
|
10
|
+
"@pie-element/multi-trait-rubric": "^4.3.7-next.27+622eab7fb",
|
|
11
|
+
"@pie-element/rubric": "^4.4.7-next.27+622eab7fb",
|
|
12
12
|
"@pie-framework/pie-player-events": "^0.1.0",
|
|
13
13
|
"classnames": "^2.2.5",
|
|
14
14
|
"debug": "^4.1.1",
|
|
15
15
|
"lodash": "^4.17.11",
|
|
16
16
|
"prop-types": "^15.7.2"
|
|
17
17
|
},
|
|
18
|
-
"gitHead": "
|
|
18
|
+
"gitHead": "622eab7fb4903086040bebc83387e8628da1846e",
|
|
19
19
|
"scripts": {
|
|
20
20
|
"postpublish": "../../scripts/postpublish"
|
|
21
21
|
},
|