@pie-element/multi-trait-rubric 3.10.1-next.0 → 3.10.1-next.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/configure/package.json +1 -1
- package/controller/package.json +1 -1
- package/package.json +3 -3
- package/configure/lib/common.js +0 -584
- package/configure/lib/common.js.map +0 -1
- package/configure/lib/defaults.js +0 -143
- package/configure/lib/defaults.js.map +0 -1
- package/configure/lib/index.js +0 -204
- package/configure/lib/index.js.map +0 -1
- package/configure/lib/main.js +0 -602
- package/configure/lib/main.js.map +0 -1
- package/configure/lib/modals.js +0 -361
- package/configure/lib/modals.js.map +0 -1
- package/configure/lib/scale.js +0 -556
- package/configure/lib/scale.js.map +0 -1
- package/configure/lib/trait.js +0 -380
- package/configure/lib/trait.js.map +0 -1
- package/configure/lib/traitsHeader.js +0 -296
- package/configure/lib/traitsHeader.js.map +0 -1
- package/configure/lib/utils.js +0 -14
- package/configure/lib/utils.js.map +0 -1
- package/controller/lib/defaults.js +0 -94
- package/controller/lib/defaults.js.map +0 -1
- package/controller/lib/index.js +0 -215
- package/controller/lib/index.js.map +0 -1
- package/controller/lib/utils.js +0 -13
- package/controller/lib/utils.js.map +0 -1
- package/lib/index.js +0 -85
- package/lib/index.js.map +0 -1
- package/lib/main.js +0 -161
- package/lib/main.js.map +0 -1
- package/lib/scale.js +0 -330
- package/lib/scale.js.map +0 -1
- package/lib/trait.js +0 -103
- package/lib/trait.js.map +0 -1
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": "1.16.
|
|
11
|
+
"@pie-lib/pie-toolbox": "1.16.1-next.28",
|
|
12
12
|
"debug": "^3.1.0",
|
|
13
13
|
"lodash": "^4.17.15",
|
|
14
14
|
"prop-types": "^15.6.2",
|
package/controller/package.json
CHANGED
package/package.json
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pie-element/multi-trait-rubric",
|
|
3
3
|
"repository": "pie-framework/pie-elements",
|
|
4
|
-
"version": "3.10.1-next.
|
|
4
|
+
"version": "3.10.1-next.1+b15abe678",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
8
8
|
"dependencies": {
|
|
9
9
|
"@material-ui/core": "^3.9.2",
|
|
10
10
|
"@pie-framework/pie-player-events": "^0.1.0",
|
|
11
|
-
"@pie-lib/pie-toolbox": "1.16.
|
|
11
|
+
"@pie-lib/pie-toolbox": "1.16.1-next.28",
|
|
12
12
|
"clsx": "^1.1.1",
|
|
13
13
|
"enzyme-to-json": "^3.3.5",
|
|
14
14
|
"prop-types": "^15.6.1",
|
|
15
15
|
"react": "^16.8.1",
|
|
16
16
|
"react-dom": "^16.8.1"
|
|
17
17
|
},
|
|
18
|
-
"gitHead": "
|
|
18
|
+
"gitHead": "b15abe678bf81101440641728f578317e11a58c1",
|
|
19
19
|
"scripts": {
|
|
20
20
|
"postpublish": "../../scripts/postpublish"
|
|
21
21
|
},
|
package/configure/lib/common.js
DELETED
|
@@ -1,584 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
|
|
5
|
-
Object.defineProperty(exports, "__esModule", {
|
|
6
|
-
value: true
|
|
7
|
-
});
|
|
8
|
-
exports.UnderlinedInput = exports.SimpleInput = exports.SecondaryBlock = exports.ScorePoint = exports.ScaleSettings = exports.Row = exports.PrimaryBlockWidth = exports.PrimaryBlock = exports.MultiTraitButton = exports.MaxPointsPicker = exports.HeaderHeightLarge = exports.HeaderHeight = exports.ExpandedInput = exports.DragHandleSpace = exports.BlockWidth = exports.Block = exports.Arrow = void 0;
|
|
9
|
-
|
|
10
|
-
var _react = _interopRequireDefault(require("react"));
|
|
11
|
-
|
|
12
|
-
var _classnames = _interopRequireDefault(require("classnames"));
|
|
13
|
-
|
|
14
|
-
var _styles = require("@material-ui/core/styles");
|
|
15
|
-
|
|
16
|
-
var _editableHtml = require("@pie-lib/pie-toolbox/editable-html");
|
|
17
|
-
|
|
18
|
-
var _FormControl = _interopRequireDefault(require("@material-ui/core/FormControl"));
|
|
19
|
-
|
|
20
|
-
var _InputLabel = _interopRequireDefault(require("@material-ui/core/InputLabel"));
|
|
21
|
-
|
|
22
|
-
var _Select = _interopRequireDefault(require("@material-ui/core/Select"));
|
|
23
|
-
|
|
24
|
-
var _MenuItem = _interopRequireDefault(require("@material-ui/core/MenuItem"));
|
|
25
|
-
|
|
26
|
-
var _InputBase = _interopRequireDefault(require("@material-ui/core/InputBase"));
|
|
27
|
-
|
|
28
|
-
var _renderUi = require("@pie-lib/pie-toolbox/render-ui");
|
|
29
|
-
|
|
30
|
-
var _grey = _interopRequireDefault(require("@material-ui/core/colors/grey"));
|
|
31
|
-
|
|
32
|
-
var _utils = require("./utils");
|
|
33
|
-
|
|
34
|
-
var BlockWidth = 200;
|
|
35
|
-
exports.BlockWidth = BlockWidth;
|
|
36
|
-
var PrimaryBlockWidth = 200;
|
|
37
|
-
exports.PrimaryBlockWidth = PrimaryBlockWidth;
|
|
38
|
-
var DragHandleSpace = 32;
|
|
39
|
-
exports.DragHandleSpace = DragHandleSpace;
|
|
40
|
-
var HeaderHeight = '100px';
|
|
41
|
-
exports.HeaderHeight = HeaderHeight;
|
|
42
|
-
var HeaderHeightLarge = '160px';
|
|
43
|
-
exports.HeaderHeightLarge = HeaderHeightLarge;
|
|
44
|
-
var InputHeight = '120px';
|
|
45
|
-
var greyBorder = "solid 1px ".concat(_grey["default"][400]);
|
|
46
|
-
var Padding = '8px 4px';
|
|
47
|
-
var MultiTraitButton = (0, _styles.withStyles)(function (theme) {
|
|
48
|
-
return {
|
|
49
|
-
button: {
|
|
50
|
-
fontSize: theme.typography.fontSize + 2,
|
|
51
|
-
textAlign: 'right',
|
|
52
|
-
display: 'flex',
|
|
53
|
-
flexDirection: 'row',
|
|
54
|
-
alignItems: 'flex-start',
|
|
55
|
-
padding: "".concat(theme.spacing.unit * 1.5, "px ").concat(theme.spacing.unit * 2, "px"),
|
|
56
|
-
width: '114px',
|
|
57
|
-
background: _renderUi.color.secondaryBackground(),
|
|
58
|
-
borderRadius: '4px',
|
|
59
|
-
justifyContent: 'space-around',
|
|
60
|
-
color: _renderUi.color.text(),
|
|
61
|
-
cursor: 'pointer'
|
|
62
|
-
}
|
|
63
|
-
};
|
|
64
|
-
})(function (_ref) {
|
|
65
|
-
var classes = _ref.classes,
|
|
66
|
-
children = _ref.children,
|
|
67
|
-
onClick = _ref.onClick;
|
|
68
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
69
|
-
className: classes.button,
|
|
70
|
-
onClick: onClick
|
|
71
|
-
}, /*#__PURE__*/_react["default"].createElement("strong", null, "+"), /*#__PURE__*/_react["default"].createElement("div", null, children));
|
|
72
|
-
});
|
|
73
|
-
exports.MultiTraitButton = MultiTraitButton;
|
|
74
|
-
var PrimaryBlock = (0, _styles.withStyles)({
|
|
75
|
-
primaryBlock: {
|
|
76
|
-
width: "".concat(PrimaryBlockWidth, "px"),
|
|
77
|
-
minWidth: "".concat(PrimaryBlockWidth, "px"),
|
|
78
|
-
position: 'relative',
|
|
79
|
-
padding: '0 10px',
|
|
80
|
-
boxSizing: 'border-box'
|
|
81
|
-
}
|
|
82
|
-
})(function (_ref2) {
|
|
83
|
-
var classes = _ref2.classes,
|
|
84
|
-
children = _ref2.children,
|
|
85
|
-
className = _ref2.className;
|
|
86
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
87
|
-
className: (0, _classnames["default"])(classes.primaryBlock, className)
|
|
88
|
-
}, children);
|
|
89
|
-
});
|
|
90
|
-
exports.PrimaryBlock = PrimaryBlock;
|
|
91
|
-
var Block = (0, _styles.withStyles)(function (theme) {
|
|
92
|
-
return {
|
|
93
|
-
block: {
|
|
94
|
-
width: "".concat(BlockWidth, "px"),
|
|
95
|
-
minWidth: "".concat(BlockWidth, "px"),
|
|
96
|
-
'& ul, ol': {
|
|
97
|
-
marginBlockStart: 0,
|
|
98
|
-
paddingInlineStart: theme.spacing.unit * 2
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
};
|
|
102
|
-
})(function (_ref3) {
|
|
103
|
-
var classes = _ref3.classes,
|
|
104
|
-
children = _ref3.children;
|
|
105
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
106
|
-
className: classes.block
|
|
107
|
-
}, children);
|
|
108
|
-
});
|
|
109
|
-
exports.Block = Block;
|
|
110
|
-
var SecondaryBlock = (0, _styles.withStyles)({
|
|
111
|
-
secondaryBlock: {
|
|
112
|
-
display: 'flex',
|
|
113
|
-
overflowX: 'hidden',
|
|
114
|
-
alignItems: 'flex-end',
|
|
115
|
-
// this is needed to show the editor toolbar!!!
|
|
116
|
-
paddingBottom: '30px'
|
|
117
|
-
}
|
|
118
|
-
})(function (_ref4) {
|
|
119
|
-
var classes = _ref4.classes,
|
|
120
|
-
children = _ref4.children,
|
|
121
|
-
setRef = _ref4.setRef,
|
|
122
|
-
width = _ref4.width;
|
|
123
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
124
|
-
className: classes.secondaryBlock,
|
|
125
|
-
style: {
|
|
126
|
-
width: width
|
|
127
|
-
},
|
|
128
|
-
ref: setRef
|
|
129
|
-
}, children);
|
|
130
|
-
});
|
|
131
|
-
exports.SecondaryBlock = SecondaryBlock;
|
|
132
|
-
var Row = (0, _styles.withStyles)({
|
|
133
|
-
row: {
|
|
134
|
-
display: 'flex'
|
|
135
|
-
}
|
|
136
|
-
})(function (_ref5) {
|
|
137
|
-
var classes = _ref5.classes,
|
|
138
|
-
children = _ref5.children,
|
|
139
|
-
className = _ref5.className,
|
|
140
|
-
height = _ref5.height;
|
|
141
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
142
|
-
className: (0, _classnames["default"])(classes.row, className),
|
|
143
|
-
style: {
|
|
144
|
-
height: height
|
|
145
|
-
}
|
|
146
|
-
}, children);
|
|
147
|
-
});
|
|
148
|
-
exports.Row = Row;
|
|
149
|
-
|
|
150
|
-
var scorePointsStyles = function scorePointsStyles(theme) {
|
|
151
|
-
return {
|
|
152
|
-
scorePointBoxWrapper: {
|
|
153
|
-
padding: '0 10px'
|
|
154
|
-
},
|
|
155
|
-
scorePointBox: {
|
|
156
|
-
display: 'flex',
|
|
157
|
-
borderRadius: '4px',
|
|
158
|
-
background: 'white',
|
|
159
|
-
flexDirection: 'row',
|
|
160
|
-
alignItems: 'center',
|
|
161
|
-
justifyContent: 'space-between',
|
|
162
|
-
border: greyBorder
|
|
163
|
-
},
|
|
164
|
-
scorePointBoxDisabled: {
|
|
165
|
-
background: 'none',
|
|
166
|
-
justifyContent: 'center',
|
|
167
|
-
border: '0'
|
|
168
|
-
},
|
|
169
|
-
subLabel: {
|
|
170
|
-
width: '24px',
|
|
171
|
-
textAlign: 'center'
|
|
172
|
-
},
|
|
173
|
-
editableLabel: {
|
|
174
|
-
textAlign: 'left',
|
|
175
|
-
flex: 1,
|
|
176
|
-
border: 'none',
|
|
177
|
-
'& div': {
|
|
178
|
-
padding: 0
|
|
179
|
-
},
|
|
180
|
-
'& > div': {
|
|
181
|
-
border: 'none',
|
|
182
|
-
borderLeft: greyBorder,
|
|
183
|
-
borderRadius: 0,
|
|
184
|
-
padding: Padding
|
|
185
|
-
}
|
|
186
|
-
},
|
|
187
|
-
slateEditor: {
|
|
188
|
-
fontFamily: 'Cerebri'
|
|
189
|
-
},
|
|
190
|
-
errorText: {
|
|
191
|
-
fontSize: theme.typography.fontSize - 2,
|
|
192
|
-
color: theme.palette.error.main,
|
|
193
|
-
paddingBottom: theme.spacing.unit
|
|
194
|
-
}
|
|
195
|
-
};
|
|
196
|
-
};
|
|
197
|
-
|
|
198
|
-
var ScorePoint = (0, _styles.withStyles)(function (theme) {
|
|
199
|
-
return {
|
|
200
|
-
scorePointBoxWrapper: {
|
|
201
|
-
padding: '0 10px'
|
|
202
|
-
},
|
|
203
|
-
scorePointBox: {
|
|
204
|
-
display: 'flex',
|
|
205
|
-
borderRadius: '4px',
|
|
206
|
-
background: 'white',
|
|
207
|
-
flexDirection: 'row',
|
|
208
|
-
alignItems: 'center',
|
|
209
|
-
justifyContent: 'space-between',
|
|
210
|
-
border: greyBorder
|
|
211
|
-
},
|
|
212
|
-
scorePointBoxDisabled: {
|
|
213
|
-
background: 'none',
|
|
214
|
-
justifyContent: 'center',
|
|
215
|
-
border: '0'
|
|
216
|
-
},
|
|
217
|
-
subLabel: {
|
|
218
|
-
width: '24px',
|
|
219
|
-
textAlign: 'center'
|
|
220
|
-
},
|
|
221
|
-
editableLabel: {
|
|
222
|
-
textAlign: 'left',
|
|
223
|
-
flex: 1,
|
|
224
|
-
border: 'none',
|
|
225
|
-
'& div': {
|
|
226
|
-
padding: 0
|
|
227
|
-
},
|
|
228
|
-
'& > div': {
|
|
229
|
-
border: 'none',
|
|
230
|
-
borderLeft: greyBorder,
|
|
231
|
-
borderRadius: 0,
|
|
232
|
-
padding: Padding
|
|
233
|
-
}
|
|
234
|
-
},
|
|
235
|
-
slateEditor: {
|
|
236
|
-
fontFamily: 'Cerebri'
|
|
237
|
-
},
|
|
238
|
-
errorText: {
|
|
239
|
-
fontSize: theme.typography.fontSize - 2,
|
|
240
|
-
color: theme.palette.error.main,
|
|
241
|
-
paddingBottom: theme.spacing.unit
|
|
242
|
-
}
|
|
243
|
-
};
|
|
244
|
-
})(function (_ref6) {
|
|
245
|
-
var classes = _ref6.classes,
|
|
246
|
-
_ref6$error = _ref6.error,
|
|
247
|
-
error = _ref6$error === void 0 ? '' : _ref6$error,
|
|
248
|
-
scorePointsValue = _ref6.scorePointsValue,
|
|
249
|
-
scoreDescriptor = _ref6.scoreDescriptor,
|
|
250
|
-
pluginProps = _ref6.pluginProps,
|
|
251
|
-
onChange = _ref6.onChange,
|
|
252
|
-
showScorePointLabels = _ref6.showScorePointLabels,
|
|
253
|
-
alignToRight = _ref6.alignToRight,
|
|
254
|
-
spellCheck = _ref6.spellCheck,
|
|
255
|
-
uploadSoundSupport = _ref6.uploadSoundSupport,
|
|
256
|
-
_ref6$imageSupport = _ref6.imageSupport,
|
|
257
|
-
imageSupport = _ref6$imageSupport === void 0 ? {} : _ref6$imageSupport,
|
|
258
|
-
_ref6$mathMlOptions = _ref6.mathMlOptions,
|
|
259
|
-
mathMlOptions = _ref6$mathMlOptions === void 0 ? {} : _ref6$mathMlOptions;
|
|
260
|
-
var scoreBoxClasses = showScorePointLabels ? classes.scorePointBox : "".concat(classes.scorePointBox, " ").concat(classes.scorePointBoxDisabled);
|
|
261
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
262
|
-
className: classes.scorePointBoxWrapper
|
|
263
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
264
|
-
className: scoreBoxClasses
|
|
265
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
266
|
-
className: classes.subLabel
|
|
267
|
-
}, scorePointsValue), showScorePointLabels ? /*#__PURE__*/_react["default"].createElement(_editableHtml.EditableHtml, {
|
|
268
|
-
className: classes.editableLabel,
|
|
269
|
-
classes: {
|
|
270
|
-
slateEditor: classes.slateEditor
|
|
271
|
-
},
|
|
272
|
-
error: error,
|
|
273
|
-
markup: scoreDescriptor,
|
|
274
|
-
placeholder: " Enter Label",
|
|
275
|
-
onChange: onChange,
|
|
276
|
-
pluginProps: pluginProps,
|
|
277
|
-
activePlugins: _utils.filteredDefaultPlugins,
|
|
278
|
-
spellCheck: spellCheck,
|
|
279
|
-
toolbarOpts: alignToRight ? {
|
|
280
|
-
alignment: 'right'
|
|
281
|
-
} : {},
|
|
282
|
-
uploadSoundSupport: uploadSoundSupport,
|
|
283
|
-
languageCharactersProps: [{
|
|
284
|
-
language: 'spanish'
|
|
285
|
-
}, {
|
|
286
|
-
language: 'special'
|
|
287
|
-
}],
|
|
288
|
-
mathMlOptions: mathMlOptions,
|
|
289
|
-
imageSupport: imageSupport
|
|
290
|
-
}) : null));
|
|
291
|
-
});
|
|
292
|
-
exports.ScorePoint = ScorePoint;
|
|
293
|
-
|
|
294
|
-
var inputStyles = function inputStyles(theme) {
|
|
295
|
-
return {
|
|
296
|
-
root: {
|
|
297
|
-
background: theme.palette.common.white,
|
|
298
|
-
'label + &': {
|
|
299
|
-
marginTop: theme.spacing.unit * 2.5,
|
|
300
|
-
marginBottom: 0,
|
|
301
|
-
width: '80px'
|
|
302
|
-
}
|
|
303
|
-
},
|
|
304
|
-
input: {
|
|
305
|
-
borderRadius: '4px',
|
|
306
|
-
position: 'relative',
|
|
307
|
-
border: greyBorder,
|
|
308
|
-
fontSize: theme.typography.fontSize,
|
|
309
|
-
fontFamily: 'Cerebri Sans',
|
|
310
|
-
padding: "".concat(theme.spacing.unit, "px ").concat(theme.spacing.unit * 1.5, "px"),
|
|
311
|
-
'&:focus': {
|
|
312
|
-
borderRadius: '4px'
|
|
313
|
-
}
|
|
314
|
-
}
|
|
315
|
-
};
|
|
316
|
-
};
|
|
317
|
-
|
|
318
|
-
var BootstrapInput = (0, _styles.withStyles)(inputStyles)(_InputBase["default"]);
|
|
319
|
-
|
|
320
|
-
var createMaxScoreOptions = function createMaxScoreOptions(maxMaxPoints) {
|
|
321
|
-
return Array.from({
|
|
322
|
-
length: maxMaxPoints
|
|
323
|
-
}, function (_, i) {
|
|
324
|
-
return i + 1;
|
|
325
|
-
});
|
|
326
|
-
};
|
|
327
|
-
|
|
328
|
-
var MaxPointsPicker = (0, _styles.withStyles)({})(function (_ref7) {
|
|
329
|
-
var maxPoints = _ref7.maxPoints,
|
|
330
|
-
onChange = _ref7.onChange,
|
|
331
|
-
maxMaxPoints = _ref7.maxMaxPoints;
|
|
332
|
-
return /*#__PURE__*/_react["default"].createElement(_FormControl["default"], null, /*#__PURE__*/_react["default"].createElement(_InputLabel["default"], null, "Max Points"), /*#__PURE__*/_react["default"].createElement(_Select["default"], {
|
|
333
|
-
value: maxPoints,
|
|
334
|
-
onChange: onChange,
|
|
335
|
-
input: /*#__PURE__*/_react["default"].createElement(BootstrapInput, null)
|
|
336
|
-
}, createMaxScoreOptions(maxMaxPoints).map(function (maxScore) {
|
|
337
|
-
return /*#__PURE__*/_react["default"].createElement(_MenuItem["default"], {
|
|
338
|
-
key: "menu-item-".concat(maxScore),
|
|
339
|
-
value: maxScore
|
|
340
|
-
}, maxScore);
|
|
341
|
-
})));
|
|
342
|
-
});
|
|
343
|
-
exports.MaxPointsPicker = MaxPointsPicker;
|
|
344
|
-
var SimpleInput = (0, _styles.withStyles)(function (theme) {
|
|
345
|
-
return {
|
|
346
|
-
simpleInput: {
|
|
347
|
-
display: 'flex',
|
|
348
|
-
justifyContent: 'space-between',
|
|
349
|
-
alignItems: 'center',
|
|
350
|
-
margin: "".concat(theme.spacing.unit * 1.5, "px 0")
|
|
351
|
-
},
|
|
352
|
-
editableLevel: {
|
|
353
|
-
background: theme.palette.common.white,
|
|
354
|
-
width: '60%'
|
|
355
|
-
},
|
|
356
|
-
slateEditor: {
|
|
357
|
-
fontFamily: 'Cerebri'
|
|
358
|
-
}
|
|
359
|
-
};
|
|
360
|
-
})(function (_ref8) {
|
|
361
|
-
var classes = _ref8.classes,
|
|
362
|
-
markup = _ref8.markup,
|
|
363
|
-
onChange = _ref8.onChange,
|
|
364
|
-
pluginProps = _ref8.pluginProps,
|
|
365
|
-
label = _ref8.label,
|
|
366
|
-
spellCheck = _ref8.spellCheck,
|
|
367
|
-
uploadSoundSupport = _ref8.uploadSoundSupport,
|
|
368
|
-
_ref8$mathMlOptions = _ref8.mathMlOptions,
|
|
369
|
-
mathMlOptions = _ref8$mathMlOptions === void 0 ? {} : _ref8$mathMlOptions,
|
|
370
|
-
_ref8$imageSupport = _ref8.imageSupport,
|
|
371
|
-
imageSupport = _ref8$imageSupport === void 0 ? {} : _ref8$imageSupport;
|
|
372
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
373
|
-
className: classes.simpleInput
|
|
374
|
-
}, label && /*#__PURE__*/_react["default"].createElement("div", null, label), /*#__PURE__*/_react["default"].createElement(_editableHtml.EditableHtml, {
|
|
375
|
-
className: classes.editableLevel,
|
|
376
|
-
classes: {
|
|
377
|
-
slateEditor: classes.slateEditor
|
|
378
|
-
},
|
|
379
|
-
markup: markup,
|
|
380
|
-
onChange: onChange,
|
|
381
|
-
placeholder: "Trait Label",
|
|
382
|
-
pluginProps: pluginProps,
|
|
383
|
-
activePlugins: _utils.filteredDefaultPlugins,
|
|
384
|
-
spellCheck: spellCheck,
|
|
385
|
-
uploadSoundSupport: uploadSoundSupport,
|
|
386
|
-
languageCharactersProps: [{
|
|
387
|
-
language: 'spanish'
|
|
388
|
-
}, {
|
|
389
|
-
language: 'special'
|
|
390
|
-
}],
|
|
391
|
-
mathMlOptions: mathMlOptions,
|
|
392
|
-
imageSupport: imageSupport
|
|
393
|
-
}));
|
|
394
|
-
});
|
|
395
|
-
exports.SimpleInput = SimpleInput;
|
|
396
|
-
var UnderlinedInput = (0, _styles.withStyles)(function (theme) {
|
|
397
|
-
return {
|
|
398
|
-
underlinedInputWrapper: {
|
|
399
|
-
width: '100%',
|
|
400
|
-
display: 'flex',
|
|
401
|
-
justifyContent: 'center',
|
|
402
|
-
alignItems: 'center'
|
|
403
|
-
},
|
|
404
|
-
editableLevel: {
|
|
405
|
-
background: theme.palette.common.white,
|
|
406
|
-
width: '100%',
|
|
407
|
-
'& div': {
|
|
408
|
-
padding: 0
|
|
409
|
-
},
|
|
410
|
-
'& > div': {
|
|
411
|
-
border: 'none',
|
|
412
|
-
borderBottom: greyBorder,
|
|
413
|
-
borderRadius: 0,
|
|
414
|
-
padding: Padding
|
|
415
|
-
}
|
|
416
|
-
},
|
|
417
|
-
slateEditor: {
|
|
418
|
-
fontFamily: 'Cerebri'
|
|
419
|
-
}
|
|
420
|
-
};
|
|
421
|
-
})(function (_ref9) {
|
|
422
|
-
var classes = _ref9.classes,
|
|
423
|
-
error = _ref9.error,
|
|
424
|
-
markup = _ref9.markup,
|
|
425
|
-
onChange = _ref9.onChange,
|
|
426
|
-
pluginProps = _ref9.pluginProps,
|
|
427
|
-
label = _ref9.label,
|
|
428
|
-
placeholder = _ref9.placeholder,
|
|
429
|
-
spellCheck = _ref9.spellCheck,
|
|
430
|
-
uploadSoundSupport = _ref9.uploadSoundSupport,
|
|
431
|
-
_ref9$imageSupport = _ref9.imageSupport,
|
|
432
|
-
imageSupport = _ref9$imageSupport === void 0 ? {} : _ref9$imageSupport,
|
|
433
|
-
_ref9$mathMlOptions = _ref9.mathMlOptions,
|
|
434
|
-
mathMlOptions = _ref9$mathMlOptions === void 0 ? {} : _ref9$mathMlOptions;
|
|
435
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
436
|
-
className: classes.underlinedInputWrapper
|
|
437
|
-
}, label && /*#__PURE__*/_react["default"].createElement("div", null, label), /*#__PURE__*/_react["default"].createElement(_editableHtml.EditableHtml, {
|
|
438
|
-
className: classes.editableLevel,
|
|
439
|
-
classes: {
|
|
440
|
-
slateEditor: classes.slateEditor
|
|
441
|
-
},
|
|
442
|
-
error: error,
|
|
443
|
-
markup: markup,
|
|
444
|
-
onChange: onChange,
|
|
445
|
-
placeholder: placeholder,
|
|
446
|
-
pluginProps: pluginProps,
|
|
447
|
-
activePlugins: _utils.filteredDefaultPlugins,
|
|
448
|
-
spellCheck: spellCheck,
|
|
449
|
-
uploadSoundSupport: uploadSoundSupport,
|
|
450
|
-
languageCharactersProps: [{
|
|
451
|
-
language: 'spanish'
|
|
452
|
-
}, {
|
|
453
|
-
language: 'special'
|
|
454
|
-
}],
|
|
455
|
-
mathMlOptions: mathMlOptions,
|
|
456
|
-
imageSupport: imageSupport
|
|
457
|
-
}));
|
|
458
|
-
});
|
|
459
|
-
exports.UnderlinedInput = UnderlinedInput;
|
|
460
|
-
var ExpandedInput = (0, _styles.withStyles)({
|
|
461
|
-
slateEditor: {
|
|
462
|
-
fontFamily: 'Cerebri',
|
|
463
|
-
height: InputHeight,
|
|
464
|
-
padding: 0
|
|
465
|
-
},
|
|
466
|
-
prompt: {
|
|
467
|
-
border: 'none',
|
|
468
|
-
margin: '10px',
|
|
469
|
-
marginTop: 0
|
|
470
|
-
}
|
|
471
|
-
})(function (_ref10) {
|
|
472
|
-
var classes = _ref10.classes,
|
|
473
|
-
error = _ref10.error,
|
|
474
|
-
markup = _ref10.markup,
|
|
475
|
-
onChange = _ref10.onChange,
|
|
476
|
-
pluginProps = _ref10.pluginProps,
|
|
477
|
-
placeholder = _ref10.placeholder,
|
|
478
|
-
alignToRight = _ref10.alignToRight,
|
|
479
|
-
spellCheck = _ref10.spellCheck,
|
|
480
|
-
uploadSoundSupport = _ref10.uploadSoundSupport,
|
|
481
|
-
_ref10$mathMlOptions = _ref10.mathMlOptions,
|
|
482
|
-
mathMlOptions = _ref10$mathMlOptions === void 0 ? {} : _ref10$mathMlOptions,
|
|
483
|
-
_ref10$imageSupport = _ref10.imageSupport,
|
|
484
|
-
imageSupport = _ref10$imageSupport === void 0 ? {} : _ref10$imageSupport;
|
|
485
|
-
return /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement(_editableHtml.EditableHtml, {
|
|
486
|
-
className: classes.prompt,
|
|
487
|
-
classes: {
|
|
488
|
-
slateEditor: classes.slateEditor
|
|
489
|
-
},
|
|
490
|
-
error: error,
|
|
491
|
-
markup: markup,
|
|
492
|
-
onChange: onChange,
|
|
493
|
-
placeholder: placeholder,
|
|
494
|
-
pluginProps: pluginProps,
|
|
495
|
-
toolbarOpts: alignToRight ? {
|
|
496
|
-
alignment: 'right'
|
|
497
|
-
} : {},
|
|
498
|
-
spellCheck: spellCheck,
|
|
499
|
-
uploadSoundSupport: uploadSoundSupport,
|
|
500
|
-
languageCharactersProps: [{
|
|
501
|
-
language: 'spanish'
|
|
502
|
-
}, {
|
|
503
|
-
language: 'special'
|
|
504
|
-
}],
|
|
505
|
-
autoWidthToolbar: true,
|
|
506
|
-
mathMlOptions: mathMlOptions,
|
|
507
|
-
imageSupport: imageSupport
|
|
508
|
-
}));
|
|
509
|
-
});
|
|
510
|
-
exports.ExpandedInput = ExpandedInput;
|
|
511
|
-
var ScaleSettings = (0, _styles.withStyles)({
|
|
512
|
-
scaleSettings: {
|
|
513
|
-
display: 'flex',
|
|
514
|
-
justifyContent: 'space-between',
|
|
515
|
-
alignItems: 'flex-end'
|
|
516
|
-
}
|
|
517
|
-
})(function (_ref11) {
|
|
518
|
-
var classes = _ref11.classes,
|
|
519
|
-
children = _ref11.children;
|
|
520
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
521
|
-
className: classes.scaleSettings
|
|
522
|
-
}, children);
|
|
523
|
-
});
|
|
524
|
-
exports.ScaleSettings = ScaleSettings;
|
|
525
|
-
var Arrow = (0, _styles.withStyles)(function (theme) {
|
|
526
|
-
return {
|
|
527
|
-
arrow: {
|
|
528
|
-
position: 'absolute',
|
|
529
|
-
zIndex: 10,
|
|
530
|
-
cursor: 'pointer',
|
|
531
|
-
right: 0,
|
|
532
|
-
alignItems: 'flex-start',
|
|
533
|
-
justifyContent: 'center',
|
|
534
|
-
background: "linear-gradient(to left, ".concat(theme.palette.common.white, ", ").concat(_renderUi.color.background(), ")"),
|
|
535
|
-
boxSizing: 'border-box'
|
|
536
|
-
},
|
|
537
|
-
innerGrey: {
|
|
538
|
-
position: 'absolute',
|
|
539
|
-
zIndex: 11,
|
|
540
|
-
cursor: 'pointer',
|
|
541
|
-
right: 0,
|
|
542
|
-
alignItems: 'flex-start',
|
|
543
|
-
justifyContent: 'center',
|
|
544
|
-
background: "linear-gradient(to left, ".concat(theme.palette.common.white, ", ").concat(_renderUi.color.background(), ")"),
|
|
545
|
-
boxSizing: 'border-box',
|
|
546
|
-
'& svg': {
|
|
547
|
-
position: 'absolute',
|
|
548
|
-
bottom: '-24px'
|
|
549
|
-
}
|
|
550
|
-
}
|
|
551
|
-
};
|
|
552
|
-
})(function (_ref12) {
|
|
553
|
-
var classes = _ref12.classes,
|
|
554
|
-
children = _ref12.children,
|
|
555
|
-
className = _ref12.className,
|
|
556
|
-
show = _ref12.show,
|
|
557
|
-
width = _ref12.width,
|
|
558
|
-
onClick = _ref12.onClick,
|
|
559
|
-
left = _ref12.left,
|
|
560
|
-
showLevelTagInput = _ref12.showLevelTagInput;
|
|
561
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
562
|
-
className: (0, _classnames["default"])(classes.arrow, className),
|
|
563
|
-
style: {
|
|
564
|
-
height: '-webkit-fill-available',
|
|
565
|
-
display: show ? 'flex' : 'none',
|
|
566
|
-
width: width,
|
|
567
|
-
left: left,
|
|
568
|
-
background: left ? "linear-gradient(to right, white, ".concat(_renderUi.color.background(), ")") : undefined
|
|
569
|
-
},
|
|
570
|
-
onClick: onClick
|
|
571
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
572
|
-
className: (0, _classnames["default"])(classes.innerGrey, className),
|
|
573
|
-
style: {
|
|
574
|
-
display: show ? 'flex' : 'none',
|
|
575
|
-
width: width,
|
|
576
|
-
height: showLevelTagInput ? HeaderHeightLarge : HeaderHeight,
|
|
577
|
-
left: 0,
|
|
578
|
-
background: left ? "linear-gradient(to right, ".concat(_renderUi.color.secondaryBackground(), ", ").concat(_renderUi.color.background(), ")") : undefined
|
|
579
|
-
},
|
|
580
|
-
onClick: onClick
|
|
581
|
-
}, children));
|
|
582
|
-
});
|
|
583
|
-
exports.Arrow = Arrow;
|
|
584
|
-
//# sourceMappingURL=common.js.map
|