@instructure/quiz-core 20.4.1 → 20.4.2-rc.1
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/es/reporting/components/Caption/index.js +13 -18
- package/es/reporting/components/Caption/styles.js +12 -0
- package/es/reporting/components/Caption/theme.js +4 -2
- package/es/reporting/components/charts/Legend/index.js +45 -33
- package/es/reporting/components/charts/Legend/styles.js +44 -0
- package/es/reporting/components/charts/Legend/theme.js +4 -2
- package/es/reporting/components/itemAnalysis/ItemAnalysisRow/presenter.js +61 -79
- package/es/reporting/components/itemAnalysis/ItemAnalysisRow/styles.js +100 -0
- package/es/reporting/components/itemAnalysis/ItemAnalysisRow/theme.js +4 -2
- package/es/reporting/components/resources/NewQuizAndItemAnalysis/NewQuizAnalysis/presenter.js +34 -44
- package/es/reporting/components/resources/NewQuizAndItemAnalysis/NewQuizAnalysis/styles.js +40 -0
- package/es/reporting/components/resources/NewQuizAndItemAnalysis/NewQuizAnalysis/theme.js +4 -2
- package/es/reporting/components/resources/NewQuizAndItemAnalysis/charts/ScoreDistribution/presenter.js +27 -26
- package/es/reporting/components/resources/NewQuizAndItemAnalysis/charts/ScoreDistribution/styles.js +20 -0
- package/es/reporting/components/resources/NewQuizAndItemAnalysis/charts/ScoreDistribution/theme.js +4 -2
- package/lib/reporting/components/Caption/index.js +12 -19
- package/lib/reporting/components/Caption/styles.js +20 -0
- package/lib/reporting/components/Caption/theme.js +6 -3
- package/lib/reporting/components/charts/Legend/index.js +44 -34
- package/lib/reporting/components/charts/Legend/styles.js +54 -0
- package/lib/reporting/components/charts/Legend/theme.js +6 -3
- package/lib/reporting/components/itemAnalysis/ItemAnalysisRow/presenter.js +61 -80
- package/lib/reporting/components/itemAnalysis/ItemAnalysisRow/styles.js +110 -0
- package/lib/reporting/components/itemAnalysis/ItemAnalysisRow/theme.js +6 -3
- package/lib/reporting/components/resources/NewQuizAndItemAnalysis/NewQuizAnalysis/presenter.js +33 -45
- package/lib/reporting/components/resources/NewQuizAndItemAnalysis/NewQuizAnalysis/styles.js +48 -0
- package/lib/reporting/components/resources/NewQuizAndItemAnalysis/NewQuizAnalysis/theme.js +6 -3
- package/lib/reporting/components/resources/NewQuizAndItemAnalysis/charts/ScoreDistribution/presenter.js +27 -26
- package/lib/reporting/components/resources/NewQuizAndItemAnalysis/charts/ScoreDistribution/styles.js +28 -0
- package/lib/reporting/components/resources/NewQuizAndItemAnalysis/charts/ScoreDistribution/theme.js +6 -3
- package/package.json +10 -11
|
@@ -19,12 +19,16 @@ var _createSuper2 = _interopRequireDefault(require("@babel/runtime/helpers/creat
|
|
|
19
19
|
|
|
20
20
|
var _react = _interopRequireWildcard(require("react"));
|
|
21
21
|
|
|
22
|
+
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
23
|
+
|
|
22
24
|
var _index = _interopRequireDefault(require("../../../../charts/QuintileDistribution/index.js"));
|
|
23
25
|
|
|
24
|
-
var
|
|
26
|
+
var _emotion = require("@instructure/emotion");
|
|
25
27
|
|
|
26
28
|
var _theme = _interopRequireDefault(require("./theme.js"));
|
|
27
29
|
|
|
30
|
+
var _styles = _interopRequireDefault(require("./styles.js"));
|
|
31
|
+
|
|
28
32
|
var _formatMessage = _interopRequireDefault(require("@instructure/quiz-i18n/es/format-message"));
|
|
29
33
|
|
|
30
34
|
var _uiText = require("@instructure/ui-text");
|
|
@@ -33,19 +37,11 @@ var _uiHeading = require("@instructure/ui-heading");
|
|
|
33
37
|
|
|
34
38
|
var _index2 = _interopRequireDefault(require("../../../../charts/Legend/index.js"));
|
|
35
39
|
|
|
36
|
-
var
|
|
37
|
-
|
|
38
|
-
var
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
return "\n\n.eRgoL_YBfL{background-color:".concat(theme.legendRectFillColor || 'inherit', "}\n\n.eRgoL_eDZF{column-gap:10px;display:inline-flex;padding:").concat(theme.legendPadding || 'inherit', " 0}\n\n.eRgoL_dVXF{margin:").concat(theme.legendMargin || 'inherit', " 0}\n\n.eRgoL_dxZa,[dir=ltr] .eRgoL_dxZa,[dir=rtl] .eRgoL_dxZa{text-align:center}");
|
|
42
|
-
},
|
|
43
|
-
'legendRect': 'eRgoL_YBfL',
|
|
44
|
-
'legendContainer': 'eRgoL_eDZF',
|
|
45
|
-
'headingContainer': 'eRgoL_dVXF',
|
|
46
|
-
'chartLabel': 'eRgoL_dxZa'
|
|
47
|
-
};
|
|
48
|
-
var ScoreDistribution = (_dec = (0, _uiThemeable.themeable)(_theme.default, styles), _dec(_class = (_temp = /*#__PURE__*/function (_Component) {
|
|
40
|
+
var _match = require("sinon/lib/sinon/match");
|
|
41
|
+
|
|
42
|
+
var _dec, _class, _class2, _temp;
|
|
43
|
+
|
|
44
|
+
var ScoreDistribution = (_dec = (0, _emotion.withStyle)(_styles.default, _theme.default), _dec(_class = (_temp = _class2 = /*#__PURE__*/function (_Component) {
|
|
49
45
|
(0, _inherits2.default)(ScoreDistribution, _Component);
|
|
50
46
|
|
|
51
47
|
var _super = (0, _createSuper2.default)(ScoreDistribution);
|
|
@@ -87,28 +83,28 @@ var ScoreDistribution = (_dec = (0, _uiThemeable.themeable)(_theme.default, styl
|
|
|
87
83
|
key: "render",
|
|
88
84
|
value: function render() {
|
|
89
85
|
var decileDistribution = this.props.decileDistribution;
|
|
90
|
-
return
|
|
91
|
-
|
|
92
|
-
},
|
|
86
|
+
return (0, _emotion.jsx)(_react.default.Fragment, null, (0, _emotion.jsx)("div", {
|
|
87
|
+
css: this.props.styles.headingContainer
|
|
88
|
+
}, (0, _emotion.jsx)(_uiHeading.Heading, {
|
|
93
89
|
level: "h3",
|
|
94
90
|
themeOverride: {
|
|
95
91
|
h3FontWeight: 700
|
|
96
92
|
}
|
|
97
|
-
}, (0, _formatMessage.default)('Score Distribution'))),
|
|
93
|
+
}, (0, _formatMessage.default)('Score Distribution'))), (0, _emotion.jsx)(_index.default, {
|
|
98
94
|
animateDelay: 1000,
|
|
99
95
|
animateDuration: 1000,
|
|
100
96
|
visualDistribution: decileDistribution || [],
|
|
101
97
|
calculateLabelForColumn: decileDistribution.length > 10 ? this.calculateLabelForColumnsWithExtremeValues : this.calculateLabelForColumns
|
|
102
|
-
}),
|
|
98
|
+
}), (0, _emotion.jsx)("div", {
|
|
103
99
|
"aria-hidden": "true",
|
|
104
|
-
|
|
105
|
-
},
|
|
100
|
+
css: this.props.styles.chartLabel
|
|
101
|
+
}, (0, _emotion.jsx)(_uiText.Text, {
|
|
106
102
|
size: "small"
|
|
107
|
-
}, (0, _formatMessage.default)('Score'))),
|
|
108
|
-
|
|
109
|
-
},
|
|
103
|
+
}, (0, _formatMessage.default)('Score'))), (0, _emotion.jsx)("div", {
|
|
104
|
+
css: this.props.styles.legendContainer
|
|
105
|
+
}, (0, _emotion.jsx)(_index2.default, {
|
|
110
106
|
series: [{
|
|
111
|
-
|
|
107
|
+
customStyles: this.props.styles.legendRect,
|
|
112
108
|
label: (0, _formatMessage.default)('Number of Students')
|
|
113
109
|
}]
|
|
114
110
|
})));
|
|
@@ -116,5 +112,10 @@ var ScoreDistribution = (_dec = (0, _uiThemeable.themeable)(_theme.default, styl
|
|
|
116
112
|
}]);
|
|
117
113
|
ScoreDistribution.displayName = "ScoreDistribution";
|
|
118
114
|
return ScoreDistribution;
|
|
119
|
-
}(_react.Component),
|
|
115
|
+
}(_react.Component), _class2.propTypes = {
|
|
116
|
+
decileDistribution: _propTypes.default.arrayOf(_propTypes.default.number),
|
|
117
|
+
styles: _propTypes.default.object
|
|
118
|
+
}, _class2.defaultProps = {
|
|
119
|
+
decileDistribution: []
|
|
120
|
+
}, _temp)) || _class);
|
|
120
121
|
exports.ScoreDistribution = ScoreDistribution;
|
package/lib/reporting/components/resources/NewQuizAndItemAnalysis/charts/ScoreDistribution/styles.js
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
|
|
8
|
+
var generateStyle = function generateStyle(componentTheme) {
|
|
9
|
+
return {
|
|
10
|
+
legendRect: {
|
|
11
|
+
backgroundColor: componentTheme.legendRectFillColor
|
|
12
|
+
},
|
|
13
|
+
legendContainer: {
|
|
14
|
+
display: 'inline-flex',
|
|
15
|
+
columnGap: '10px',
|
|
16
|
+
padding: "".concat(componentTheme.legendPadding, " 0")
|
|
17
|
+
},
|
|
18
|
+
headingContainer: {
|
|
19
|
+
margin: "".concat(componentTheme.legendMargin, " 0")
|
|
20
|
+
},
|
|
21
|
+
chartLabel: {
|
|
22
|
+
textAlign: 'center'
|
|
23
|
+
}
|
|
24
|
+
};
|
|
25
|
+
};
|
|
26
|
+
|
|
27
|
+
var _default = generateStyle;
|
|
28
|
+
exports.default = _default;
|
package/lib/reporting/components/resources/NewQuizAndItemAnalysis/charts/ScoreDistribution/theme.js
CHANGED
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.default =
|
|
6
|
+
exports.default = void 0;
|
|
7
7
|
|
|
8
|
-
function
|
|
8
|
+
var generateComponentTheme = function generateComponentTheme(_ref) {
|
|
9
9
|
var colors = _ref.colors,
|
|
10
10
|
spacing = _ref.spacing,
|
|
11
11
|
typography = _ref.typography;
|
|
@@ -16,4 +16,7 @@ function generator(_ref) {
|
|
|
16
16
|
legendFontSize: typography.fontSizeXSmall,
|
|
17
17
|
legendMargin: spacing.medium
|
|
18
18
|
};
|
|
19
|
-
}
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
var _default = generateComponentTheme;
|
|
22
|
+
exports.default = _default;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@instructure/quiz-core",
|
|
3
|
-
"version": "20.4.1",
|
|
3
|
+
"version": "20.4.2-rc.1+866bb7620",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "The Quiz React SDK by Instructure Inc.",
|
|
6
6
|
"author": "Instructure, Inc. Engineering and Product Design",
|
|
@@ -44,11 +44,11 @@
|
|
|
44
44
|
"@instructure/emotion": "^8.51.0",
|
|
45
45
|
"@instructure/grading-utils": "^1.0.0",
|
|
46
46
|
"@instructure/outcomes-ui": "^3.0.0",
|
|
47
|
-
"@instructure/quiz-common": "
|
|
48
|
-
"@instructure/quiz-i18n": "
|
|
49
|
-
"@instructure/quiz-interactions": "
|
|
50
|
-
"@instructure/quiz-number-input": "
|
|
51
|
-
"@instructure/quiz-rce": "
|
|
47
|
+
"@instructure/quiz-common": "20.4.2-rc.1+866bb7620",
|
|
48
|
+
"@instructure/quiz-i18n": "20.4.2-rc.1+866bb7620",
|
|
49
|
+
"@instructure/quiz-interactions": "20.4.2-rc.1+866bb7620",
|
|
50
|
+
"@instructure/quiz-number-input": "20.4.2-rc.1+866bb7620",
|
|
51
|
+
"@instructure/quiz-rce": "20.4.2-rc.1+866bb7620",
|
|
52
52
|
"@instructure/ui-a11y-content": "^8.51.0",
|
|
53
53
|
"@instructure/ui-alerts": "^8.51.0",
|
|
54
54
|
"@instructure/ui-avatar": "^8.51.0",
|
|
@@ -112,12 +112,11 @@
|
|
|
112
112
|
"file-saver": "~2.0.5",
|
|
113
113
|
"humps": "^2.0.0",
|
|
114
114
|
"immutable": "^3.8.1",
|
|
115
|
-
"instructure-validations": "
|
|
115
|
+
"instructure-validations": "20.4.2-rc.1+866bb7620",
|
|
116
116
|
"ipaddr.js": "^1.5.4",
|
|
117
117
|
"isomorphic-fetch": "^2.2.0",
|
|
118
118
|
"isuuid": "^0.1.0",
|
|
119
119
|
"jwt-simple": "^0.5.0",
|
|
120
|
-
"katex": "^0.10.2",
|
|
121
120
|
"lodash": "^4.0.0",
|
|
122
121
|
"luxon": "3.3.0",
|
|
123
122
|
"normalizr": "3.2.2",
|
|
@@ -144,7 +143,7 @@
|
|
|
144
143
|
"uuid": "^3.2.1"
|
|
145
144
|
},
|
|
146
145
|
"devDependencies": {
|
|
147
|
-
"@instructure/quiz-scripts": "
|
|
146
|
+
"@instructure/quiz-scripts": "20.4.1",
|
|
148
147
|
"@instructure/ui-axe-check": "^8.51.0",
|
|
149
148
|
"@instructure/ui-babel-preset": "^7.22.1",
|
|
150
149
|
"@instructure/ui-karma-config": "^7.22.1",
|
|
@@ -164,7 +163,7 @@
|
|
|
164
163
|
"intl": "^1.2.4",
|
|
165
164
|
"jquery": "^2.2.3",
|
|
166
165
|
"most-subject": "^5.3.0",
|
|
167
|
-
"quiz-presets": "
|
|
166
|
+
"quiz-presets": "20.4.2-rc.1+866bb7620",
|
|
168
167
|
"react": "^16.8.6",
|
|
169
168
|
"react-addons-test-utils": "^15.6.2",
|
|
170
169
|
"react-dom": "^16.8.6",
|
|
@@ -180,5 +179,5 @@
|
|
|
180
179
|
"publishConfig": {
|
|
181
180
|
"access": "public"
|
|
182
181
|
},
|
|
183
|
-
"gitHead": "
|
|
182
|
+
"gitHead": "866bb7620e430ba716d2c6ab9400751884366666"
|
|
184
183
|
}
|