@khanacademy/perseus-editor 14.10.2 → 14.11.0
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/dist/es/index.js +52 -37
- package/dist/es/index.js.map +1 -1
- package/dist/index.js +52 -37
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -98,7 +98,7 @@ var arrowCounterClockwise__default = /*#__PURE__*/_interopDefaultLegacy(arrowCou
|
|
|
98
98
|
|
|
99
99
|
// This file is processed by a Rollup plugin (replace) to inject the production
|
|
100
100
|
const libName = "@khanacademy/perseus-editor";
|
|
101
|
-
const libVersion = "14.
|
|
101
|
+
const libVersion = "14.11.0";
|
|
102
102
|
perseusCore.addLibraryVersionToPerseusDebug(libName, libVersion);
|
|
103
103
|
|
|
104
104
|
function _extends() {
|
|
@@ -23657,7 +23657,7 @@ class StructuredItemDiff extends React__namespace.Component {
|
|
|
23657
23657
|
|
|
23658
23658
|
/* eslint-disable @khanacademy/ts-no-error-suppressions */
|
|
23659
23659
|
const {
|
|
23660
|
-
InfoTip: InfoTip$
|
|
23660
|
+
InfoTip: InfoTip$o,
|
|
23661
23661
|
InlineIcon: InlineIcon$7
|
|
23662
23662
|
} = perseus.components;
|
|
23663
23663
|
/* Renders a hint editor box
|
|
@@ -23725,7 +23725,7 @@ class HintEditor extends React__namespace.Component {
|
|
|
23725
23725
|
type: "button",
|
|
23726
23726
|
className: this.props.isFirst ? "hidden" : "",
|
|
23727
23727
|
onClick: ___default["default"].partial(this.props.onMove, -1)
|
|
23728
|
-
}, /*#__PURE__*/React__namespace.createElement(InlineIcon$7, iconCircleArrowUp)), " ", this.props.isLast && /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
23728
|
+
}, /*#__PURE__*/React__namespace.createElement(InlineIcon$7, iconCircleArrowUp)), " ", this.props.isLast && /*#__PURE__*/React__namespace.createElement(InfoTip$o, null, /*#__PURE__*/React__namespace.createElement("p", null, "The last hint is automatically bolded."))), /*#__PURE__*/React__namespace.createElement("input", {
|
|
23729
23729
|
type: "checkbox"
|
|
23730
23730
|
// @ts-expect-error - TS2322 - Type 'boolean | null | undefined' is not assignable to type 'boolean | undefined'.
|
|
23731
23731
|
,
|
|
@@ -23953,7 +23953,7 @@ class CombinedHintsEditor extends React__namespace.Component {
|
|
|
23953
23953
|
}
|
|
23954
23954
|
|
|
23955
23955
|
const {
|
|
23956
|
-
InfoTip: InfoTip$
|
|
23956
|
+
InfoTip: InfoTip$n
|
|
23957
23957
|
} = perseus.components;
|
|
23958
23958
|
class ItemExtrasEditor extends React__namespace.Component {
|
|
23959
23959
|
static defaultProps = {
|
|
@@ -24097,7 +24097,7 @@ const ItemExtraCheckbox = props => /*#__PURE__*/React__namespace.createElement(w
|
|
|
24097
24097
|
style: {
|
|
24098
24098
|
flexDirection: "row"
|
|
24099
24099
|
}
|
|
24100
|
-
}, props.label, " ", /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
24100
|
+
}, props.label, " ", /*#__PURE__*/React__namespace.createElement(InfoTip$n, null, props.infoTip)),
|
|
24101
24101
|
checked: props.checked,
|
|
24102
24102
|
onChange: newCheckedState => props.onChange(newCheckedState)
|
|
24103
24103
|
}));
|
|
@@ -25780,7 +25780,7 @@ class BlurInput extends React__namespace.Component {
|
|
|
25780
25780
|
|
|
25781
25781
|
/* eslint-disable no-useless-escape */
|
|
25782
25782
|
const {
|
|
25783
|
-
InfoTip: InfoTip$
|
|
25783
|
+
InfoTip: InfoTip$m
|
|
25784
25784
|
} = perseus.components;
|
|
25785
25785
|
const DEFAULT_WIDTH = 400;
|
|
25786
25786
|
const DEFAULT_HEIGHT = 400;
|
|
@@ -25971,7 +25971,7 @@ class CSProgramEditor extends React__namespace.Component {
|
|
|
25971
25971
|
showEditor: value
|
|
25972
25972
|
});
|
|
25973
25973
|
}
|
|
25974
|
-
}), /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
25974
|
+
}), /*#__PURE__*/React__namespace.createElement(InfoTip$m, null, "If you show the editor, you should use the \"full-width\" alignment to make room for the width of the editor."), /*#__PURE__*/React__namespace.createElement("br", null), /*#__PURE__*/React__namespace.createElement(wonderBlocksForm.Checkbox, {
|
|
25975
25975
|
label: "Show Buttons",
|
|
25976
25976
|
checked: this.props.showButtons,
|
|
25977
25977
|
onChange: value => {
|
|
@@ -25983,7 +25983,7 @@ class CSProgramEditor extends React__namespace.Component {
|
|
|
25983
25983
|
name: "settings",
|
|
25984
25984
|
pairs: this.props.settings,
|
|
25985
25985
|
onChange: this._handleSettingsChange
|
|
25986
|
-
}), /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
25986
|
+
}), /*#__PURE__*/React__namespace.createElement(InfoTip$m, null, "Settings that you add here are available to the program as an object returned by ", /*#__PURE__*/React__namespace.createElement("code", null, "Program.settings()"))));
|
|
25987
25987
|
}
|
|
25988
25988
|
}
|
|
25989
25989
|
|
|
@@ -26060,7 +26060,7 @@ class DeprecatedStandinEditor extends React__namespace.Component {
|
|
|
26060
26060
|
|
|
26061
26061
|
/* eslint-disable @khanacademy/ts-no-error-suppressions */
|
|
26062
26062
|
const {
|
|
26063
|
-
InfoTip: InfoTip$
|
|
26063
|
+
InfoTip: InfoTip$l,
|
|
26064
26064
|
InlineIcon: InlineIcon$5
|
|
26065
26065
|
} = perseus.components;
|
|
26066
26066
|
class DropdownEditor extends React__namespace.Component {
|
|
@@ -26137,14 +26137,14 @@ class DropdownEditor extends React__namespace.Component {
|
|
|
26137
26137
|
className: "perseus-widget-dropdown"
|
|
26138
26138
|
}, /*#__PURE__*/React__namespace.createElement("div", {
|
|
26139
26139
|
className: "dropdown-info"
|
|
26140
|
-
}, "Dropdown", /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
26140
|
+
}, "Dropdown", /*#__PURE__*/React__namespace.createElement(InfoTip$l, null, /*#__PURE__*/React__namespace.createElement("p", null, "The drop down is useful for making inequalities in a custom format. We normally use the symbols ", "<", ",", " ", ">", ", \u2264, \u2265 (in that order) which you can copy into the choices. When possible, use the \"multiple choice\" answer type instead."))), /*#__PURE__*/React__namespace.createElement("div", {
|
|
26141
26141
|
className: "dropdown-placeholder"
|
|
26142
26142
|
}, /*#__PURE__*/React__namespace.createElement("input", {
|
|
26143
26143
|
type: "text",
|
|
26144
26144
|
placeholder: "Placeholder value",
|
|
26145
26145
|
value: this.props.placeholder,
|
|
26146
26146
|
onChange: this.onPlaceholderChange
|
|
26147
|
-
}), /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
26147
|
+
}), /*#__PURE__*/React__namespace.createElement(InfoTip$l, null, /*#__PURE__*/React__namespace.createElement("p", null, "This value will appear as the drop down default. It should give the user some indication of the values available in the drop down itself, e.g., Yes/No/Maybe."))), /*#__PURE__*/React__namespace.createElement("div", {
|
|
26148
26148
|
className: "clearfix"
|
|
26149
26149
|
}), /*#__PURE__*/React__namespace.createElement("ul", {
|
|
26150
26150
|
className: "dropdown-choices"
|
|
@@ -26462,7 +26462,7 @@ const styles$N = aphrodite.StyleSheet.create({
|
|
|
26462
26462
|
});
|
|
26463
26463
|
|
|
26464
26464
|
const {
|
|
26465
|
-
InfoTip: InfoTip$
|
|
26465
|
+
InfoTip: InfoTip$k
|
|
26466
26466
|
} = perseus.components;
|
|
26467
26467
|
|
|
26468
26468
|
// types for iterables
|
|
@@ -26720,13 +26720,13 @@ class ExpressionEditor extends React__namespace.Component {
|
|
|
26720
26720
|
label: "Visible label",
|
|
26721
26721
|
value: this.props.visibleLabel || "",
|
|
26722
26722
|
onChange: this.change("visibleLabel")
|
|
26723
|
-
}), /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
26723
|
+
}), /*#__PURE__*/React__namespace.createElement(InfoTip$k, null, /*#__PURE__*/React__namespace.createElement("p", null, "Optional visible text; strongly encouraged to help learners using dictation software, but can be omitted if the surrounding content provides enough context."))), /*#__PURE__*/React__namespace.createElement("div", {
|
|
26724
26724
|
className: aphrodite.css(styles$M.paddedY)
|
|
26725
26725
|
}, /*#__PURE__*/React__namespace.createElement(wonderBlocksForm.LabeledTextField, {
|
|
26726
26726
|
label: "Aria label",
|
|
26727
26727
|
value: this.props.ariaLabel || "",
|
|
26728
26728
|
onChange: this.change("ariaLabel")
|
|
26729
|
-
}), /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
26729
|
+
}), /*#__PURE__*/React__namespace.createElement(InfoTip$k, null, /*#__PURE__*/React__namespace.createElement("p", null, "Label text that's read by screen readers. Highly recommend adding a label here to ensure your exercise is accessible. For more information on writting accessible labels, please see", " ", /*#__PURE__*/React__namespace.createElement("a", {
|
|
26730
26730
|
href: "https://www.w3.org/WAI/tips/designing/#ensure-that-form-elements-include-clearly-associated-labels",
|
|
26731
26731
|
target: "_blank"
|
|
26732
26732
|
}, "this article.")))), /*#__PURE__*/React__namespace.createElement("div", {
|
|
@@ -26735,7 +26735,7 @@ class ExpressionEditor extends React__namespace.Component {
|
|
|
26735
26735
|
label: "Function variables",
|
|
26736
26736
|
value: this.state.functionsInternal,
|
|
26737
26737
|
onChange: this.handleFunctions
|
|
26738
|
-
}), /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
26738
|
+
}), /*#__PURE__*/React__namespace.createElement(InfoTip$k, null, /*#__PURE__*/React__namespace.createElement("p", null, "Single-letter variables listed here will be interpreted as functions. This let us know that f(x) means \"f of x\" and not \"f times x\"."))), /*#__PURE__*/React__namespace.createElement("div", {
|
|
26739
26739
|
className: aphrodite.css(styles$M.paddedY)
|
|
26740
26740
|
}, /*#__PURE__*/React__namespace.createElement(wonderBlocksForm.Checkbox, {
|
|
26741
26741
|
label: "Use \xD7 instead of \u22C5 for multiplication",
|
|
@@ -26745,7 +26745,7 @@ class ExpressionEditor extends React__namespace.Component {
|
|
|
26745
26745
|
times: value
|
|
26746
26746
|
});
|
|
26747
26747
|
}
|
|
26748
|
-
}), /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
26748
|
+
}), /*#__PURE__*/React__namespace.createElement(InfoTip$k, null, /*#__PURE__*/React__namespace.createElement("p", null, "For pre-algebra problems this option displays multiplication as \\times instead of \\cdot in both the rendered output and the acceptable formats examples."))), /*#__PURE__*/React__namespace.createElement("div", {
|
|
26749
26749
|
className: aphrodite.css(styles$M.paddedY)
|
|
26750
26750
|
}, /*#__PURE__*/React__namespace.createElement(wonderBlocksTypography.HeadingXSmall, null, "Button Sets"), buttonSetChoices), /*#__PURE__*/React__namespace.createElement(wonderBlocksTypography.HeadingSmall, null, "Answers"), /*#__PURE__*/React__namespace.createElement("p", {
|
|
26751
26751
|
style: {
|
|
@@ -26833,7 +26833,7 @@ class AnswerOption extends React__namespace.Component {
|
|
|
26833
26833
|
form: value
|
|
26834
26834
|
});
|
|
26835
26835
|
}
|
|
26836
|
-
}), /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
26836
|
+
}), /*#__PURE__*/React__namespace.createElement(InfoTip$k, null, /*#__PURE__*/React__namespace.createElement("p", null, "The student's answer must be in the same form. Commutativity and excess negative signs are ignored."))), /*#__PURE__*/React__namespace.createElement("div", {
|
|
26837
26837
|
className: aphrodite.css(styles$M.paddedY, styles$M.paddedX)
|
|
26838
26838
|
}, /*#__PURE__*/React__namespace.createElement(wonderBlocksForm.Checkbox, {
|
|
26839
26839
|
label: "Answer expression must be fully expanded and simplified.",
|
|
@@ -26843,7 +26843,7 @@ class AnswerOption extends React__namespace.Component {
|
|
|
26843
26843
|
simplify: value
|
|
26844
26844
|
});
|
|
26845
26845
|
}
|
|
26846
|
-
}), /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
26846
|
+
}), /*#__PURE__*/React__namespace.createElement(InfoTip$k, null, /*#__PURE__*/React__namespace.createElement("p", null, "The student's answer must be fully expanded and simplified. Answering this equation (x^2+2x+1) with this factored equation (x+1)^2 will render this response \"Your answer is not fully expanded and simplified.\""))), /*#__PURE__*/React__namespace.createElement("div", {
|
|
26847
26847
|
className: aphrodite.css(styles$M.buttonRow, styles$M.paddedY)
|
|
26848
26848
|
}, removeButton)));
|
|
26849
26849
|
}
|
|
@@ -27093,7 +27093,7 @@ const setArrayItem = (list, i, value) => [...list.slice(0, i), value, ...list.sl
|
|
|
27093
27093
|
/* eslint-disable react/forbid-prop-types, react/no-unsafe */
|
|
27094
27094
|
const {
|
|
27095
27095
|
ButtonGroup: ButtonGroup$7,
|
|
27096
|
-
InfoTip: InfoTip$
|
|
27096
|
+
InfoTip: InfoTip$j,
|
|
27097
27097
|
RangeInput: RangeInput$6
|
|
27098
27098
|
} = perseus.components;
|
|
27099
27099
|
const defaultBackgroundImage$3 = {
|
|
@@ -27557,7 +27557,7 @@ const GraphSettings = createReactClass__default["default"]({
|
|
|
27557
27557
|
},
|
|
27558
27558
|
onKeyPress: this.changeBackgroundUrl,
|
|
27559
27559
|
onBlur: this.changeBackgroundUrl
|
|
27560
|
-
}), /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
27560
|
+
}), /*#__PURE__*/React__namespace.createElement(InfoTip$j, null, /*#__PURE__*/React__namespace.createElement("p", null, "Create an image in graphie, or use the \"Add image\" function to create a background.")))), ___default["default"].contains(this.props.editableSettings, "measure") && /*#__PURE__*/React__namespace.createElement("div", {
|
|
27561
27561
|
className: "misc-settings"
|
|
27562
27562
|
}, /*#__PURE__*/React__namespace.createElement("div", {
|
|
27563
27563
|
className: "perseus-widget-row"
|
|
@@ -27603,7 +27603,7 @@ const GraphSettings = createReactClass__default["default"]({
|
|
|
27603
27603
|
});
|
|
27604
27604
|
|
|
27605
27605
|
const {
|
|
27606
|
-
InfoTip: InfoTip$
|
|
27606
|
+
InfoTip: InfoTip$i,
|
|
27607
27607
|
MultiButtonGroup: MultiButtonGroup$1
|
|
27608
27608
|
} = perseus.components;
|
|
27609
27609
|
const Grapher = perseus.GrapherWidget.widget;
|
|
@@ -27693,7 +27693,7 @@ class GrapherEditor extends React__namespace.Component {
|
|
|
27693
27693
|
className: "perseus-error"
|
|
27694
27694
|
}, this.props.graph.valid);
|
|
27695
27695
|
}
|
|
27696
|
-
return /*#__PURE__*/React__namespace.createElement("div", null, /*#__PURE__*/React__namespace.createElement("div", null, "Correct answer", " ", /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
27696
|
+
return /*#__PURE__*/React__namespace.createElement("div", null, /*#__PURE__*/React__namespace.createElement("div", null, "Correct answer", " ", /*#__PURE__*/React__namespace.createElement(InfoTip$i, null, /*#__PURE__*/React__namespace.createElement("p", null, "Graph the correct answer in the graph below and ensure the equation or point coordinates displayed represent the correct answer.")), " ", ": ", equationString), /*#__PURE__*/React__namespace.createElement(GraphSettings, {
|
|
27697
27697
|
editableSettings: ["graph", "snap", "image"],
|
|
27698
27698
|
box: perseus.getInteractiveBoxFromSizeClass(sizeClass),
|
|
27699
27699
|
range: this.props.graph.range,
|
|
@@ -27953,7 +27953,7 @@ class IframeEditor extends React__namespace.Component {
|
|
|
27953
27953
|
|
|
27954
27954
|
/* eslint-disable jsx-a11y/anchor-is-valid */
|
|
27955
27955
|
const {
|
|
27956
|
-
InfoTip: InfoTip$
|
|
27956
|
+
InfoTip: InfoTip$h,
|
|
27957
27957
|
InlineIcon: InlineIcon$3,
|
|
27958
27958
|
RangeInput: RangeInput$5
|
|
27959
27959
|
} = perseus.components;
|
|
@@ -28154,7 +28154,7 @@ class ImageEditor extends React__namespace.Component {
|
|
|
28154
28154
|
style: {
|
|
28155
28155
|
width: "100%"
|
|
28156
28156
|
}
|
|
28157
|
-
}))), /*#__PURE__*/React__namespace.createElement("div", null, /*#__PURE__*/React__namespace.createElement("label", null, /*#__PURE__*/React__namespace.createElement("div", null, "Dimensions:"), /*#__PURE__*/React__namespace.createElement("p", null, backgroundImage.width, "x", backgroundImage.height))), /*#__PURE__*/React__namespace.createElement("div", null, /*#__PURE__*/React__namespace.createElement("label", null, /*#__PURE__*/React__namespace.createElement("div", null, "Alt text:", /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
28157
|
+
}))), /*#__PURE__*/React__namespace.createElement("div", null, /*#__PURE__*/React__namespace.createElement("label", null, /*#__PURE__*/React__namespace.createElement("div", null, "Dimensions:"), /*#__PURE__*/React__namespace.createElement("p", null, backgroundImage.width, "x", backgroundImage.height))), /*#__PURE__*/React__namespace.createElement("div", null, /*#__PURE__*/React__namespace.createElement("label", null, /*#__PURE__*/React__namespace.createElement("div", null, "Alt text:", /*#__PURE__*/React__namespace.createElement(InfoTip$h, null, "This is important for screenreaders. The content of this alt text will be formatted as markdown (tables, emphasis, etc. are supported).")), /*#__PURE__*/React__namespace.createElement(Editor, {
|
|
28158
28158
|
apiOptions: this.props.apiOptions,
|
|
28159
28159
|
content: this.props.alt,
|
|
28160
28160
|
onChange: props => {
|
|
@@ -28178,7 +28178,7 @@ class ImageEditor extends React__namespace.Component {
|
|
|
28178
28178
|
}, this.state.backgroundImageError);
|
|
28179
28179
|
return /*#__PURE__*/React__namespace.createElement("div", {
|
|
28180
28180
|
className: "perseus-image-editor"
|
|
28181
|
-
}, /*#__PURE__*/React__namespace.createElement("label", null, "Image url:", /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
28181
|
+
}, /*#__PURE__*/React__namespace.createElement("label", null, "Image url:", /*#__PURE__*/React__namespace.createElement(InfoTip$h, null, "Paste an image or graphie image URL."), this.state.backgroundImageError && backgroundImageErrorText, /*#__PURE__*/React__namespace.createElement(BlurInput, {
|
|
28182
28182
|
value: backgroundImage.url || "",
|
|
28183
28183
|
style: {
|
|
28184
28184
|
width: 332
|
|
@@ -28189,7 +28189,7 @@ class ImageEditor extends React__namespace.Component {
|
|
|
28189
28189
|
}
|
|
28190
28190
|
|
|
28191
28191
|
const {
|
|
28192
|
-
InfoTip: InfoTip$
|
|
28192
|
+
InfoTip: InfoTip$g
|
|
28193
28193
|
} = perseus.components;
|
|
28194
28194
|
const answerTypes = {
|
|
28195
28195
|
number: {
|
|
@@ -28282,7 +28282,7 @@ class InputNumberEditor extends React__namespace.Component {
|
|
|
28282
28282
|
value: "optional"
|
|
28283
28283
|
}, "will be accepted"), /*#__PURE__*/React__namespace.createElement("option", {
|
|
28284
28284
|
value: "enforced"
|
|
28285
|
-
}, "will be marked wrong"))), /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
28285
|
+
}, "will be marked wrong"))), /*#__PURE__*/React__namespace.createElement(InfoTip$g, null, /*#__PURE__*/React__namespace.createElement("p", null, "Normally select \"will not be graded\". This will give the user a message saying the answer is correct but not simplified. The user will then have to simplify it and re-enter, but will not be penalized. (5th grade and anything after)"), /*#__PURE__*/React__namespace.createElement("p", null, "Select \"will be accepted\" only if the user is not expected to know how to simplify fractions yet. (Anything prior to 5th grade)"), /*#__PURE__*/React__namespace.createElement("p", null, "Select \"will be marked wrong\" only if we are specifically assessing the ability to simplify."))), /*#__PURE__*/React__namespace.createElement("div", null, /*#__PURE__*/React__namespace.createElement("label", null, /*#__PURE__*/React__namespace.createElement("input", {
|
|
28286
28286
|
type: "checkbox",
|
|
28287
28287
|
checked: this.props.inexact,
|
|
28288
28288
|
onChange: e => {
|
|
@@ -28318,7 +28318,7 @@ class InputNumberEditor extends React__namespace.Component {
|
|
|
28318
28318
|
});
|
|
28319
28319
|
},
|
|
28320
28320
|
"aria-label": "Answer type"
|
|
28321
|
-
}, answerTypeOptions), /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
28321
|
+
}, answerTypeOptions), /*#__PURE__*/React__namespace.createElement(InfoTip$g, null, /*#__PURE__*/React__namespace.createElement("p", null, "Use the default \"Numbers\" unless the answer must be in a specific form (e.g., question is about converting decimals to fractions)."))), /*#__PURE__*/React__namespace.createElement("div", null, /*#__PURE__*/React__namespace.createElement("label", null, "Width", " ", /*#__PURE__*/React__namespace.createElement("select", {
|
|
28322
28322
|
value: this.props.size,
|
|
28323
28323
|
onChange: e => {
|
|
28324
28324
|
// @ts-expect-error - TS2322 - Type 'string' is not assignable to type '"small" | "normal" | undefined'.
|
|
@@ -28330,7 +28330,7 @@ class InputNumberEditor extends React__namespace.Component {
|
|
|
28330
28330
|
value: "normal"
|
|
28331
28331
|
}, "Normal (80px)"), /*#__PURE__*/React__namespace.createElement("option", {
|
|
28332
28332
|
value: "small"
|
|
28333
|
-
}, "Small (40px)"))), /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
28333
|
+
}, "Small (40px)"))), /*#__PURE__*/React__namespace.createElement(InfoTip$g, null, /*#__PURE__*/React__namespace.createElement("p", null, "Use size \"Normal\" for all text boxes, unless there are multiple text boxes in one line and the answer area is too narrow to fit them."))), /*#__PURE__*/React__namespace.createElement("div", null, /*#__PURE__*/React__namespace.createElement("label", null, /*#__PURE__*/React__namespace.createElement("input", {
|
|
28334
28334
|
type: "checkbox",
|
|
28335
28335
|
checked: this.props.rightAlign,
|
|
28336
28336
|
onChange: e => {
|
|
@@ -29857,7 +29857,7 @@ const styles$F = aphrodite.StyleSheet.create({
|
|
|
29857
29857
|
/* eslint-disable react/forbid-prop-types, react/no-unsafe */
|
|
29858
29858
|
const {
|
|
29859
29859
|
ButtonGroup: ButtonGroup$2,
|
|
29860
|
-
InfoTip: InfoTip$
|
|
29860
|
+
InfoTip: InfoTip$f,
|
|
29861
29861
|
RangeInput: RangeInput$4
|
|
29862
29862
|
} = perseus.components;
|
|
29863
29863
|
const defaultBackgroundImage$1 = {
|
|
@@ -30273,7 +30273,7 @@ class InteractiveGraphSettings extends React__namespace.Component {
|
|
|
30273
30273
|
},
|
|
30274
30274
|
onKeyPress: this.changeBackgroundUrl,
|
|
30275
30275
|
onBlur: this.changeBackgroundUrl
|
|
30276
|
-
}), /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
30276
|
+
}), /*#__PURE__*/React__namespace.createElement(InfoTip$f, null, /*#__PURE__*/React__namespace.createElement("p", null, "Create an image in graphie, or use the \"Add image\" function to create a background."))), /*#__PURE__*/React__namespace.createElement(wonderBlocksCore.View, {
|
|
30277
30277
|
style: styles$E.protractorSection
|
|
30278
30278
|
}, /*#__PURE__*/React__namespace.createElement(wonderBlocksCore.View, {
|
|
30279
30279
|
style: styles$E.checkboxRow
|
|
@@ -30775,7 +30775,7 @@ const styles$v = aphrodite.StyleSheet.create({
|
|
|
30775
30775
|
});
|
|
30776
30776
|
|
|
30777
30777
|
const {
|
|
30778
|
-
InfoTip: InfoTip$
|
|
30778
|
+
InfoTip: InfoTip$e
|
|
30779
30779
|
} = perseus.components;
|
|
30780
30780
|
function LockedFigureAria(props) {
|
|
30781
30781
|
const {
|
|
@@ -30792,7 +30792,7 @@ function LockedFigureAria(props) {
|
|
|
30792
30792
|
}, /*#__PURE__*/React__namespace.createElement(wonderBlocksTypography.LabelMedium, {
|
|
30793
30793
|
tag: "label",
|
|
30794
30794
|
htmlFor: ariaLabelId
|
|
30795
|
-
}, "Aria label"), /*#__PURE__*/React__namespace.createElement(Spring, null), /*#__PURE__*/React__namespace.createElement(InfoTip$
|
|
30795
|
+
}, "Aria label"), /*#__PURE__*/React__namespace.createElement(Spring, null), /*#__PURE__*/React__namespace.createElement(InfoTip$e, null, "Aria label is used by screen readers to describe content to users who may be visually impaired. ", /*#__PURE__*/React__namespace.createElement("br", null), /*#__PURE__*/React__namespace.createElement("br", null), "Populating this field will make it so that users can use a screen reader to navigate to this point and hear the description.", /*#__PURE__*/React__namespace.createElement("br", null), /*#__PURE__*/React__namespace.createElement("br", null), "If you leave this field blank, the point will be hidden from screen readers. Users will not be able to navigate to this point using a screen reader.")), /*#__PURE__*/React__namespace.createElement(Strut, {
|
|
30796
30796
|
size: wonderBlocksTokens.spacing.xxSmall_6
|
|
30797
30797
|
}), /*#__PURE__*/React__namespace.createElement(wonderBlocksTypography.LabelXSmall, {
|
|
30798
30798
|
style: styles$u.caption
|
|
@@ -30904,6 +30904,9 @@ const styles$t = aphrodite.StyleSheet.create({
|
|
|
30904
30904
|
*
|
|
30905
30905
|
* Used in the interactive graph editor's locked figures section.
|
|
30906
30906
|
*/
|
|
30907
|
+
const {
|
|
30908
|
+
InfoTip: InfoTip$d
|
|
30909
|
+
} = perseus.components;
|
|
30907
30910
|
function LockedLabelSettings(props) {
|
|
30908
30911
|
const {
|
|
30909
30912
|
type,
|
|
@@ -30940,10 +30943,14 @@ function LockedLabelSettings(props) {
|
|
|
30940
30943
|
});
|
|
30941
30944
|
},
|
|
30942
30945
|
style: styles$s.spaceUnder
|
|
30943
|
-
}), /*#__PURE__*/React__namespace.createElement(
|
|
30946
|
+
}), /*#__PURE__*/React__namespace.createElement(wonderBlocksCore.View, {
|
|
30947
|
+
style: styles$s.row
|
|
30948
|
+
}, /*#__PURE__*/React__namespace.createElement(wonderBlocksTypography.LabelMedium, {
|
|
30944
30949
|
tag: "label",
|
|
30945
|
-
style: [styles$s.row, styles$s.spaceUnder
|
|
30946
|
-
|
|
30950
|
+
style: [styles$s.row, styles$s.spaceUnder, {
|
|
30951
|
+
flexGrow: 1
|
|
30952
|
+
}]
|
|
30953
|
+
}, "text", /*#__PURE__*/React__namespace.createElement(Strut, {
|
|
30947
30954
|
size: wonderBlocksTokens.spacing.xSmall_8
|
|
30948
30955
|
}), /*#__PURE__*/React__namespace.createElement(wonderBlocksForm.TextField, {
|
|
30949
30956
|
value: text,
|
|
@@ -30951,7 +30958,7 @@ function LockedLabelSettings(props) {
|
|
|
30951
30958
|
onChange: newValue => onChangeProps({
|
|
30952
30959
|
text: newValue
|
|
30953
30960
|
})
|
|
30954
|
-
})), /*#__PURE__*/React__namespace.createElement(wonderBlocksCore.View, {
|
|
30961
|
+
})), /*#__PURE__*/React__namespace.createElement(InfoTip$d, null, "Surround your text with $ for TeX.", /*#__PURE__*/React__namespace.createElement("br", null), "Example: ", `This circle has radius $\\frac{1}{2}$ units.`, /*#__PURE__*/React__namespace.createElement("br", null), /*#__PURE__*/React__namespace.createElement("br", null), "It is important to use TeX when appropriate for accessibility. The above example would be read as \"This circle has radius one-half units\" by screen readers.")), /*#__PURE__*/React__namespace.createElement(wonderBlocksCore.View, {
|
|
30955
30962
|
style: styles$s.row
|
|
30956
30963
|
}, /*#__PURE__*/React__namespace.createElement(ColorSelect, {
|
|
30957
30964
|
selectedValue: color,
|
|
@@ -35573,6 +35580,14 @@ class LabelImageEditor extends React__namespace.Component {
|
|
|
35573
35580
|
if (url) {
|
|
35574
35581
|
perseus.Util.getImageSize(url, (width, height) => {
|
|
35575
35582
|
this.props.onChange({
|
|
35583
|
+
/**
|
|
35584
|
+
* Sending `imageUrl` up again
|
|
35585
|
+
* (even though we did so at the beginning of handleImageChange)
|
|
35586
|
+
* because we ran into a race condition (LEMS-2583) where
|
|
35587
|
+
* `imageUrl` was getting set to an empty string if measuring
|
|
35588
|
+
* happened too fast.
|
|
35589
|
+
*/
|
|
35590
|
+
imageUrl: url,
|
|
35576
35591
|
imageWidth: width,
|
|
35577
35592
|
imageHeight: height
|
|
35578
35593
|
});
|