@khanacademy/perseus 39.0.1 → 40.0.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/index.js CHANGED
@@ -9,7 +9,7 @@ var wonderBlocksCore = require('@khanacademy/wonder-blocks-core');
9
9
  var Tooltip$1 = require('@khanacademy/wonder-blocks-tooltip');
10
10
  var wonderBlocksTypography = require('@khanacademy/wonder-blocks-typography');
11
11
  var aphrodite = require('aphrodite');
12
- var classNames = require('classnames');
12
+ var classNames$1 = require('classnames');
13
13
  var React = require('react');
14
14
  var ReactDOM = require('react-dom');
15
15
  var _ = require('underscore');
@@ -67,7 +67,7 @@ function _interopNamespace(e) {
67
67
  var KAS__namespace = /*#__PURE__*/_interopNamespace(KAS);
68
68
  var PerseusLinter__namespace = /*#__PURE__*/_interopNamespace(PerseusLinter);
69
69
  var Tooltip__default = /*#__PURE__*/_interopDefaultLegacy(Tooltip$1);
70
- var classNames__default = /*#__PURE__*/_interopDefaultLegacy(classNames);
70
+ var classNames__default = /*#__PURE__*/_interopDefaultLegacy(classNames$1);
71
71
  var React__namespace = /*#__PURE__*/_interopNamespace(React);
72
72
  var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
73
73
  var ReactDOM__default = /*#__PURE__*/_interopDefaultLegacy(ReactDOM);
@@ -3999,12 +3999,12 @@ Zoom.prototype.dispose = function () {
3999
3999
  const ZoomService = new ZoomServiceClass();
4000
4000
 
4001
4001
  // @baseFontFamily: "Lato", sans-serif;
4002
- const baseFontFamily$1 = "'Lato', sans-serif";
4002
+ const baseFontFamily = "'Lato', sans-serif";
4003
4003
  // @boldFontFamily: "Lato-Bold", "Lato", sans-serif;
4004
4004
  const boldFontFamily = "'Lato-Bold', 'Lato', sans-serif";
4005
4005
  // @kaGreen: #71b307;
4006
- const kaGreen$1 = "#71B307";
4007
- const white$1 = "#FFFFFF";
4006
+ const kaGreen = "#71B307";
4007
+ const white = "#FFFFFF";
4008
4008
  const gray97 = "#F6F7F7";
4009
4009
  const gray85 = "#D6D8DA";
4010
4010
  const gray76 = "#BABEC2";
@@ -4012,23 +4012,23 @@ const gray68 = "#888D93";
4012
4012
  const gray17 = "#21242c";
4013
4013
 
4014
4014
  // @pure-sm-min: 568px;
4015
- const pureSmMin$2 = "568px";
4015
+ const pureSmMin$1 = "568px";
4016
4016
  // @pure-md-min: 768px;
4017
- const pureMdMin$2 = "768px";
4017
+ const pureMdMin$1 = "768px";
4018
4018
  // @pure-lg-min: 1024px;
4019
- const pureLgMin$2 = "1024px";
4019
+ const pureLgMin$1 = "1024px";
4020
4020
  // @pure-xl-min: 1280px;
4021
- const pureXlMin$2 = "1280px";
4021
+ const pureXlMin$1 = "1280px";
4022
4022
  // @pure-xs-max: (@pure-sm-min - 1);
4023
- const pureXsMax$2 = "567px";
4023
+ const pureXsMax$1 = "567px";
4024
4024
  // @pure-sm-max: (@pure-md-min - 1);
4025
- const pureSmMax$2 = "767px";
4025
+ const pureSmMax$1 = "767px";
4026
4026
  // @pure-md-max: (@pure-lg-min - 1);
4027
- const pureMdMax$2 = "1023px";
4027
+ const pureMdMax$1 = "1023px";
4028
4028
  // @pure-lg-max: (@pure-xl-min - 1);
4029
- const pureLgMax$2 = "1279px";
4029
+ const pureLgMax$1 = "1279px";
4030
4030
  // @tableBackgroundAccent: #f9f9f9; // for striping
4031
- const tableBackgroundAccent$1 = "#F9F9F9";
4031
+ const tableBackgroundAccent = "#F9F9F9";
4032
4032
  // @zIndexAboveScratchpad: @zIndexScratchPad + 1;
4033
4033
  const zIndexAboveScratchpad$1 = 2;
4034
4034
  // @zIndexInteractiveComponent: @zIndexAboveScratchpad + 1;
@@ -4056,26 +4056,26 @@ const checkedColor$1 = "#71B307";
4056
4056
  const articleMaxWidthInPx = 688;
4057
4057
  const articleMaxWidthTableInPx = 512;
4058
4058
 
4059
- var constants$1 = /*#__PURE__*/Object.freeze({
4059
+ var constants = /*#__PURE__*/Object.freeze({
4060
4060
  __proto__: null,
4061
- baseFontFamily: baseFontFamily$1,
4061
+ baseFontFamily: baseFontFamily,
4062
4062
  boldFontFamily: boldFontFamily,
4063
- kaGreen: kaGreen$1,
4064
- white: white$1,
4063
+ kaGreen: kaGreen,
4064
+ white: white,
4065
4065
  gray97: gray97,
4066
4066
  gray85: gray85,
4067
4067
  gray76: gray76,
4068
4068
  gray68: gray68,
4069
4069
  gray17: gray17,
4070
- pureSmMin: pureSmMin$2,
4071
- pureMdMin: pureMdMin$2,
4072
- pureLgMin: pureLgMin$2,
4073
- pureXlMin: pureXlMin$2,
4074
- pureXsMax: pureXsMax$2,
4075
- pureSmMax: pureSmMax$2,
4076
- pureMdMax: pureMdMax$2,
4077
- pureLgMax: pureLgMax$2,
4078
- tableBackgroundAccent: tableBackgroundAccent$1,
4070
+ pureSmMin: pureSmMin$1,
4071
+ pureMdMin: pureMdMin$1,
4072
+ pureLgMin: pureLgMin$1,
4073
+ pureXlMin: pureXlMin$1,
4074
+ pureXsMax: pureXsMax$1,
4075
+ pureSmMax: pureSmMax$1,
4076
+ pureMdMax: pureMdMax$1,
4077
+ pureLgMax: pureLgMax$1,
4078
+ tableBackgroundAccent: tableBackgroundAccent,
4079
4079
  zIndexAboveScratchpad: zIndexAboveScratchpad$1,
4080
4080
  zIndexInteractiveComponent: zIndexInteractiveComponent$1,
4081
4081
  phoneMargin: phoneMargin,
@@ -14999,77 +14999,26 @@ const iconCheck = {
14999
14999
  width: 24,
15000
15000
  height: 24
15001
15001
  };
15002
- const iconCheckMedium = {
15003
- path: "M6.072 10.4l6.175-7.058a1 1 0 1 1 1.506 1.317L6.769 12.64a1 1 0 0 1-1.55-.054L2.203 8.604a1 1 0 1 1 1.594-1.208L6.072 10.4z",
15004
- width: 16,
15005
- height: 16
15006
- };
15007
15002
  const iconChevronDown = {
15008
15003
  path: "M99.669 13.048q0 3.36-2.352 5.712l-41.664 41.664q-2.408 2.408-5.88 2.408t-5.712-2.408l-41.664-41.664q-2.408-2.24-2.408-5.712t2.408-5.88l4.76-4.816q2.52-2.352 5.88-2.352t5.656 2.352l31.136 31.136 31.08-31.136q2.352-2.352 5.712-2.352t5.88 2.352l4.816 4.816q2.352 2.52 2.352 5.88z",
15009
15004
  width: 100,
15010
15005
  height: 63.034
15011
15006
  };
15012
- const iconChevronRight = {
15013
- path: "M62.808 49.728q0 3.36-2.352 5.88l-41.72 41.664q-2.352 2.408-5.768 2.408t-5.768-2.408l-4.872-4.76q-2.352-2.52-2.352-5.88t2.352-5.712l31.08-31.136-31.08-31.024q-2.352-2.52-2.352-5.88t2.352-5.712l4.872-4.76q2.296-2.408 5.768-2.408t5.768 2.408l41.72 41.664q2.352 2.296 2.352 5.656z",
15014
- width: 63.034,
15015
- height: 100
15016
- };
15017
15007
  const iconCircle = {
15018
15008
  path: "M100.035 50.046q.057 13.623-6.669 25.137t-18.24 18.183-25.08 6.669-25.137-6.726q-11.514-6.726-18.183-18.183-6.726-11.571-6.726-25.137t6.726-25.08 18.24-18.24 25.08-6.669q13.566 0 25.08 6.726 11.514 6.669 18.24 18.183t6.669 25.137z",
15019
15009
  width: 100,
15020
15010
  height: 100
15021
15011
  };
15022
- const iconCircleArrowDown = {
15023
- path: "M50.046 83.676q1.767 0 2.907-1.14l29.526-29.526q1.197-1.197 1.197-2.907t-1.197-2.964l-5.928-5.928q-1.197-1.14-2.964-1.14t-2.907 1.14l-12.312 12.312l0-32.661q0-1.71-1.254-2.964t-2.907-1.254l-8.322 0q-1.71 0-2.964 1.254t-1.254 2.964l0 32.661l-12.312-12.312q-1.197-1.254-2.907-1.254t-2.907 1.254l-5.928 5.928q-1.197 1.197-1.197 2.964t1.197 2.907l29.469 29.526q1.197 1.14 2.964 1.14zm49.989-33.63q.057 13.623-6.669 25.137t-18.24 18.183-25.08 6.669-25.137-6.726q-11.514-6.726-18.183-18.183-6.726-11.571-6.726-25.137t6.726-25.08 18.24-18.24 25.08-6.669q13.566 0 25.08 6.726 11.514 6.669 18.24 18.183t6.669 25.137z",
15024
- width: 100,
15025
- height: 100
15026
- };
15027
- const iconCircleArrowUp = {
15028
- path: "M54.207 83.391q1.653 0 2.907-1.254t1.254-2.907l0-32.718l12.312 12.312q1.254 1.254 2.964 1.254t2.907-1.254l5.928-5.928q1.197-1.197 1.14-2.964 0-1.767-1.14-2.907l-29.526-29.526q-1.197-1.14-2.907-1.14t-2.964 1.14l-29.469 29.526q-1.197 1.254-1.197 2.964t1.197 2.907l5.928 5.928q1.197 1.197 2.907 1.197t2.907-1.197l12.312-12.312l0 32.718q0 1.653 1.254 2.907t2.964 1.254l8.322 0zm45.828-33.345q.057 13.623-6.669 25.137t-18.24 18.183-25.08 6.669-25.137-6.726q-11.514-6.726-18.183-18.183-6.726-11.571-6.726-25.137t6.726-25.08 18.24-18.24 25.08-6.669q13.566 0 25.08 6.726 11.514 6.669 18.24 18.183t6.669 25.137z",
15029
- width: 100,
15030
- height: 100
15031
- };
15032
15012
  const iconCircleThin = {
15033
15013
  path: "M50.046 8.322q-8.493 0-16.188 3.306-15.561 6.669-22.173 22.23-3.363 7.695-3.363 16.188t3.306 16.188 8.949 13.281q5.586 5.586 13.281 8.892t16.188 3.306 16.188-3.306 13.281-8.892 8.892-13.281 3.306-16.188-3.306-16.188-8.892-13.281-13.281-8.949q-7.695-3.306-16.188-3.306zm0 91.713q-13.623 0-25.137-6.726t-18.183-18.183q-6.726-11.571-6.726-25.137t6.726-25.08 18.24-18.24 25.08-6.669q13.566 0 25.08 6.726 11.514 6.669 18.24 18.183t6.726 25.137-6.726 25.137-18.24 18.126q-11.514 6.726-25.08 6.726z",
15034
15014
  width: 100,
15035
15015
  height: 99.944
15036
15016
  };
15037
- const iconDesktop = {
15038
- path: "M94.208 52.119l0-43.746q0-.69-.506-1.15t-1.196-.506l-84.088 0q-.69 0-1.196.506t-.506 1.15l0 43.746q0 .69.506 1.196t1.196.506l84.088 0q.69 0 1.196-.506t.506-1.196zm6.716-43.746l0 57.224q0 3.45-2.484 5.934t-5.934 2.484l-28.566 0q0 3.128 2.53 7.774.828 1.61.828 2.622t-1.012 2.07q-1.012 1.012-2.346.966l-26.91 0q-1.38 0-2.392-1.012t-1.012-2.024q0-1.058 1.656-4.14t1.748-6.256l-28.612 0q-3.45 0-5.934-2.484t-2.484-5.934l0-57.224q0-3.45 2.484-5.934t5.934-2.438l84.088 0q3.45 0 5.98 2.438 2.438 2.484 2.438 5.934z",
15039
- width: 100,
15040
- height: 86.648
15041
- };
15042
- const iconDropdownArrow = {
15043
- path: "M9 9.8c0 .5.7 1.7 1.5 2.8 1.5 1.9 1.5 1.9 3 0C15.7 9.7 15.4 9 12 9c-1.6 0-3 .4-3 .8z",
15044
- width: 24,
15045
- height: 24
15046
- };
15047
- const iconExclamationSign = {
15048
- path: "M58.368 81.225l0-12.369q0-.912-.57-1.539t-1.425-.627l-12.54 0q-.855-.057-1.482.627t-.684 1.539l0 12.369q-.057.855.627 1.482t1.539.684l12.54 0q.855 0 1.425-.627t.57-1.539zm1.026-62.871q0-1.596-2.223-1.71l-14.307 0q-2.109 0-2.223 1.71l1.14 40.47q0 .627.627 1.14t1.539.456l12.084 0q.912-.057 1.539-.513t.684-1.083zm-9.348-18.354q13.566 0 25.08 6.726 11.514 6.669 18.24 18.183t6.726 25.137-6.726 25.137-18.24 18.183-25.08 6.669-25.137-6.726q-11.514-6.726-18.183-18.183-6.726-11.571-6.726-25.137t6.726-25.08 18.24-18.24 25.08-6.669z",
15049
- width: 100,
15050
- height: 99.944
15051
- };
15052
- // Grabbed from https://github.com/encharm/Font-Awesome-SVG-PNG
15053
- const iconGear = {
15054
- path: "M1152 896q0-106-75-181t-181-75-181 75-75 181 75 181 181 75 181-75 75-181zm512-109v222q0 12-8 23t-20 13l-185 28q-19 54-39 91 35 50 107 138 10 12 10 25t-9 23q-27 37-99 108t-94 71q-12 0-26-9l-138-108q-44 23-91 38-16 136-29 186-7 28-36 28h-222q-14 0-24.5-8.5t-11.5-21.5l-28-184q-49-16-90-37l-141 107q-10 9-25 9-14 0-25-11-126-114-165-168-7-10-7-23 0-12 8-23 15-21 51-66.5t54-70.5q-27-50-41-99l-183-27q-13-2-21-12.5t-8-23.5v-222q0-12 8-23t19-13l186-28q14-46 39-92-40-57-107-138-10-12-10-24 0-10 9-23 26-36 98.5-107.5t94.5-71.5q13 0 26 10l138 107q44-23 91-38 16-136 29-186 7-28 36-28h222q14 0 24.5 8.5t11.5 21.5l28 184q49 16 90 37l142-107q9-9 24-9 13 0 25 10 129 119 165 170 7 8 7 22 0 12-8 23-15 21-51 66.5t-54 70.5q26 50 41 98l183 28q13 2 21 12.5t8 23.5z",
15055
- width: 1792,
15056
- height: 1792
15057
- };
15058
- const iconMobilePhone = {
15059
- path: "M36.04 89.557q0-2.584-1.836-4.42t-4.42-1.836-4.352 1.836q-1.836 1.836-1.836 4.42t1.836 4.352 4.42 1.836q2.652-.068 4.42-1.836t1.768-4.352zm16.184-12.444l0-54.74q0-1.088-.748-1.768t-1.768-.68l-39.78 0q-1.088 0-1.768.748t-.68 1.7l0 54.74q0 1.02.748 1.768t1.7.68l39.78 0q1.02-.068 1.768-.748t.748-1.7zm-14.892-65.892q0-1.224-1.292-1.292l-12.444 0q-1.224.068-1.224 1.292t1.224 1.224l12.444 0q1.292 0 1.292-1.224zm22.372-1.292l0 79.628q0 3.944-2.992 6.936t-7.004 2.992l-39.78 0q-4.012 0-7.004-2.924-2.924-2.924-2.924-7.004l0-79.628q0-4.012 2.924-6.936t7.004-2.992l39.78 0q4.012-.068 7.004 2.924t2.992 7.004z",
15060
- width: 60.013,
15061
- height: 100
15062
- };
15063
15017
  const iconOk = {
15064
15018
  path: "M37.964 76.048q-2.576 0-4.368-1.792l-31.864-31.864q-1.792-1.792-1.792-4.368t1.792-4.368l8.736-8.68q1.792-1.792 4.368-1.792t4.312 1.792l18.816 18.872 42-42.056q1.792-1.792 4.368-1.792t4.312 1.792l8.736 8.736q1.792 1.792 1.792 4.368t-1.792 4.312l-55.048 55.048q-1.792 1.792-4.368 1.792z",
15065
15019
  width: 100,
15066
15020
  height: 76.637
15067
15021
  };
15068
- const iconPlus = {
15069
- path: "M99.758 43.09l0 13.578q0 2.852-1.984 4.836t-4.836 1.984l-29.45 0l0 29.45q0 2.852-1.984 4.836t-4.836 1.984l-13.578 0q-2.852 0-4.836-1.984t-1.984-4.836l0-29.45l-29.45 0q-2.852 0-4.836-1.984t-1.984-4.836l0-13.578q0-2.852 1.984-4.836t4.836-1.984l29.45 0l0-29.45q0-2.852 1.984-4.836t4.836-1.984l13.578 0q2.852 0 4.836 1.984t1.984 4.836l0 29.45l29.45 0q2.852 0 4.836 1.984t1.984 4.836z",
15070
- width: 100,
15071
- height: 100
15072
- };
15073
15022
  const iconRemove = {
15074
15023
  path: "M100.464 80.808q0 3.404-2.368 5.772l-11.47 11.544q-2.368 2.368-5.772 2.368t-5.698-2.368l-24.864-24.864-24.864 24.864q-2.368 2.368-5.772 2.368t-5.772-2.368l-11.47-11.544q-2.368-2.368-2.368-5.772t2.368-5.698l24.864-24.864-24.864-24.864q-2.368-2.368-2.368-5.772t2.368-5.772l11.47-11.47q2.368-2.368 5.772-2.368t5.772 2.368l24.864 24.864 24.864-24.864q2.294-2.368 5.698-2.368t5.772 2.368l11.47 11.47q2.368 2.368 2.368 5.772t-2.368 5.772l-24.864 24.864 24.864 24.864q2.368 2.294 2.368 5.698z",
15075
15024
  width: 100,
@@ -15085,53 +15034,17 @@ const iconTryAgain = {
15085
15034
  width: 23,
15086
15035
  height: 23
15087
15036
  };
15088
- const iconTablet = {
15089
- path: "M45.322 90.706q0-1.86-1.302-3.224-1.364-1.364-3.224-1.364t-3.224 1.364-1.302 3.224q0 1.86 1.364 3.224 1.302 1.364 3.162 1.302 1.86.062 3.224-1.302t1.302-3.224zm27.218-11.346l0-68.014q0-.93-.682-1.612t-1.55-.682l-58.962 0q-.93 0-1.612.682t-.682 1.612l0 68.014q0 .93.682 1.612t1.612.62l58.962 0q.992-.062 1.612-.682t.62-1.55zm9.114-68.014l0 77.066q0 4.65-3.348 7.998t-7.998 3.348l-58.962 0q-4.65 0-7.998-3.348t-3.348-7.998l0-77.066q0-4.65 3.348-7.998t7.998-3.348l58.962 0q4.65 0 7.998 3.348t3.348 7.998z",
15090
- width: 81.852,
15091
- height: 100
15092
- };
15093
15037
  const iconTrash = {
15094
15038
  path: "M31.293 37.506q2.052 0 2.052 2.109l0 37.506q0 1.995-2.052 2.109l-4.218 0q-.912-.057-1.482-.627t-.57-1.482l0-37.506q0-2.109 2.052-2.109l4.218 0zm18.753 2.109l0 37.506q0 .912-.57 1.482t-1.539.627l-4.161 0q-1.995 0-2.109-2.109l0-37.506q.057-.912.627-1.482t1.482-.627l4.161 0q.969.057 1.539.627t.57 1.482zm14.592-2.109q2.052 0 2.052 2.109l0 37.506q0 1.995-2.052 2.109l-4.161 0q-.969-.057-1.539-.627t-.57-1.482l0-37.506q0-2.109 2.109-2.109l4.161 0zm10.431 49.248l0-61.731l-58.368 0l0 61.731q.057 2.679.969 3.819t1.083 1.14l54.207 0q.171 0 1.14-1.083t.969-3.876zm-43.776-70.11l29.184 0l-3.135-7.581q-.456-.57-1.14-.741l-20.634 0q-.627.114-1.083.741zm-31.293 2.109q0-1.995 2.109-2.109l20.121 0l4.56-10.83q.969-2.394 3.477-4.104 2.565-1.71 5.187-1.71l20.805 0q2.622 0 5.187 1.71t3.477 4.104l4.56 10.83l20.178 0q.912.057 1.482.627t.57 1.482l0 4.161q0 1.995-2.052 2.109l-6.27 0l0 61.731q0 5.415-3.078 9.348t-7.353 3.933l-54.207 0q-4.275 0-7.353-3.819t-3.078-9.177l0-62.016l-6.213 0q-.969 0-1.539-.57t-.57-1.539l0-4.161z",
15095
15039
  width: 91.681,
15096
15040
  height: 100
15097
15041
  };
15098
- const iconUndo = {
15099
- path: "M10,6.6C10,7.2,9.8,8,9.3,9.1c0,0,0,0.1-0.1,0.1S9.2,9.3,9.2,9.4c0,0,0,0.1-0.1,0.1C9,9.6,9,9.6,8.9,9.6 c-0.1,0-0.1,0-0.1-0.1c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1s0-0.1,0-0.1c0-0.3,0-0.5,0-0.7c0-0.4,0-0.7-0.1-1C8.6,7.1,8.5,6.9,8.4,6.7S8.2,6.3,8,6.1C7.8,5.9,7.6,5.8,7.4,5.7S6.9,5.5,6.7,5.5S6.1,5.4,5.8,5.4c-0.3,0-0.6,0-1,0H3.6v1.4c0,0.1,0,0.2-0.1,0.3C3.4,7.1,3.3,7.1,3.2,7.1C3.1,7.1,3,7.1,3,7L0.1,4.1C0,4.1,0,4,0,3.9s0-0.2,0.1-0.3L3,0.8C3,0.7,3.1,0.7,3.2,0.7c0.1,0,0.2,0,0.3,0.1C3.5,0.9,3.6,0.9,3.6,1v1.4h1.2c2.6,0,4.3,0.7,4.9,2.2C9.9,5.2,10,5.8,10,6.6z",
15100
- width: 10,
15101
- height: 10
15102
- };
15103
15042
  const iconMinus = {
15104
15043
  path: `M8,13 L16,13 C16.5522847,13 17,12.5522847 17,12 C17,11.4477153 16.5522847,11 16,11 L8,11 C7.44771525,11 7,11.4477153 7,12 C7,12.5522847 7.44771525,13 8,13 Z`,
15105
15044
  width: 24,
15106
15045
  height: 24
15107
15046
  };
15108
15047
 
15109
- var iconPaths = /*#__PURE__*/Object.freeze({
15110
- __proto__: null,
15111
- iconCheck: iconCheck,
15112
- iconCheckMedium: iconCheckMedium,
15113
- iconChevronDown: iconChevronDown,
15114
- iconChevronRight: iconChevronRight,
15115
- iconCircle: iconCircle,
15116
- iconCircleArrowDown: iconCircleArrowDown,
15117
- iconCircleArrowUp: iconCircleArrowUp,
15118
- iconCircleThin: iconCircleThin,
15119
- iconDesktop: iconDesktop,
15120
- iconDropdownArrow: iconDropdownArrow,
15121
- iconExclamationSign: iconExclamationSign,
15122
- iconGear: iconGear,
15123
- iconMobilePhone: iconMobilePhone,
15124
- iconOk: iconOk,
15125
- iconPlus: iconPlus,
15126
- iconRemove: iconRemove,
15127
- iconStar: iconStar,
15128
- iconTryAgain: iconTryAgain,
15129
- iconTablet: iconTablet,
15130
- iconTrash: iconTrash,
15131
- iconUndo: iconUndo,
15132
- iconMinus: iconMinus
15133
- });
15134
-
15135
15048
  /* eslint-disable @babel/no-invalid-this */
15136
15049
  const add$1 = {
15137
15050
  constrain: function () {
@@ -18400,7 +18313,7 @@ const styles$C = aphrodite.StyleSheet.create({
18400
18313
  },
18401
18314
  ":hover ~ div span[data-lint-inside-table]": {
18402
18315
  backgroundColor: warningColor,
18403
- color: white$1
18316
+ color: white
18404
18317
  }
18405
18318
  },
18406
18319
  // This is how we position the hover target for inline lint.
@@ -18436,7 +18349,7 @@ const styles$C = aphrodite.StyleSheet.create({
18436
18349
  // draw attention to the linty content.
18437
18350
  ":hover ~ span": {
18438
18351
  backgroundColor: warningColor,
18439
- color: white$1
18352
+ color: white
18440
18353
  }
18441
18354
  },
18442
18355
  radioWidgetHoverTarget: {
@@ -18478,7 +18391,7 @@ const styles$C = aphrodite.StyleSheet.create({
18478
18391
  // draw attention to the linty content.
18479
18392
  ":hover ~ span": {
18480
18393
  backgroundColor: warningColor,
18481
- color: white$1
18394
+ color: white
18482
18395
  }
18483
18396
  },
18484
18397
  // This is the class for the lint indicator in the margin.
@@ -18515,10 +18428,10 @@ const styles$C = aphrodite.StyleSheet.create({
18515
18428
  // When it is displayed, it goes on top!
18516
18429
  zIndex: 1000,
18517
18430
  // These styles control what the tooltip looks like
18518
- color: white$1,
18431
+ color: white,
18519
18432
  backgroundColor: gray17,
18520
18433
  opacity: 0.9,
18521
- fontFamily: baseFontFamily$1,
18434
+ fontFamily: baseFontFamily,
18522
18435
  fontSize: "12px",
18523
18436
  lineHeight: "15px",
18524
18437
  width: "320px",
@@ -19536,7 +19449,7 @@ var preprocessTex = (texCode => texCode
19536
19449
 
19537
19450
  const {
19538
19451
  interactiveSizes
19539
- } = constants$1;
19452
+ } = constants;
19540
19453
 
19541
19454
  // Note: these size cutoffs represent content-width cutoffs as specified in
19542
19455
  // http://zpl.io/1mVmvU (broken link - we no longer use Zeplin)
@@ -19569,13 +19482,6 @@ const getInteractiveBoxFromSizeClass = sizeClass => {
19569
19482
  return [interactiveSizes.defaultBoxSize, interactiveSizes.defaultBoxSize];
19570
19483
  };
19571
19484
 
19572
- var sizingUtils = /*#__PURE__*/Object.freeze({
19573
- __proto__: null,
19574
- containerSizeClass: containerSizeClass,
19575
- getClassFromWidth: getClassFromWidth,
19576
- getInteractiveBoxFromSizeClass: getInteractiveBoxFromSizeClass
19577
- });
19578
-
19579
19485
  class WidgetContainer extends React__namespace.Component {
19580
19486
  widgetRef = /*#__PURE__*/React__namespace.createRef();
19581
19487
  static defaultProps = {
@@ -24794,29 +24700,29 @@ var PassageRef$1 = {
24794
24700
  * });
24795
24701
  */
24796
24702
  const {
24797
- pureXsMax: pureXsMax$1,
24798
- pureSmMin: pureSmMin$1,
24799
- pureSmMax: pureSmMax$1,
24800
- pureMdMin: pureMdMin$1,
24801
- pureMdMax: pureMdMax$1,
24802
- pureLgMin: pureLgMin$1,
24803
- pureLgMax: pureLgMax$1,
24804
- pureXlMin: pureXlMin$1
24805
- } = constants$1;
24703
+ pureXsMax,
24704
+ pureSmMin,
24705
+ pureSmMax,
24706
+ pureMdMin,
24707
+ pureMdMax,
24708
+ pureLgMin,
24709
+ pureLgMax,
24710
+ pureXlMin
24711
+ } = constants;
24806
24712
  var mediaQueries = {
24807
- xs: `@media screen and (max-width: ${pureXsMax$1})`,
24808
- sm: `@media screen and (min-width: ${pureSmMin$1}) and ` + `(max-width: ${pureSmMax$1})`,
24809
- md: `@media screen and (min-width: ${pureMdMin$1}) and ` + `(max-width: ${pureMdMax$1})`,
24810
- lg: `@media screen and (min-width: ${pureLgMin$1}) and ` + `(max-width: ${pureLgMax$1})`,
24811
- xl: `@media screen and (min-width: ${pureXlMin$1})`,
24812
- xsOrSmaller: `@media screen and (max-width: ${pureXsMax$1})`,
24813
- smOrSmaller: `@media screen and (max-width: ${pureSmMax$1})`,
24814
- mdOrSmaller: `@media screen and (max-width: ${pureMdMax$1})`,
24815
- lgOrSmaller: `@media screen and (max-width: ${pureLgMax$1})`,
24816
- smOrLarger: `@media screen and (min-width: ${pureSmMin$1})`,
24817
- mdOrLarger: `@media screen and (min-width: ${pureMdMin$1})`,
24818
- lgOrLarger: `@media screen and (min-width: ${pureLgMin$1})`,
24819
- xlOrLarger: `@media screen and (min-width: ${pureXlMin$1})`
24713
+ xs: `@media screen and (max-width: ${pureXsMax})`,
24714
+ sm: `@media screen and (min-width: ${pureSmMin}) and ` + `(max-width: ${pureSmMax})`,
24715
+ md: `@media screen and (min-width: ${pureMdMin}) and ` + `(max-width: ${pureMdMax})`,
24716
+ lg: `@media screen and (min-width: ${pureLgMin}) and ` + `(max-width: ${pureLgMax})`,
24717
+ xl: `@media screen and (min-width: ${pureXlMin})`,
24718
+ xsOrSmaller: `@media screen and (max-width: ${pureXsMax})`,
24719
+ smOrSmaller: `@media screen and (max-width: ${pureSmMax})`,
24720
+ mdOrSmaller: `@media screen and (max-width: ${pureMdMax})`,
24721
+ lgOrSmaller: `@media screen and (max-width: ${pureLgMax})`,
24722
+ smOrLarger: `@media screen and (min-width: ${pureSmMin})`,
24723
+ mdOrLarger: `@media screen and (min-width: ${pureMdMin})`,
24724
+ lgOrLarger: `@media screen and (min-width: ${pureLgMin})`,
24725
+ xlOrLarger: `@media screen and (min-width: ${pureXlMin})`
24820
24726
  };
24821
24727
 
24822
24728
  const {
@@ -24826,7 +24732,7 @@ const {
24826
24732
  checkedColor,
24827
24733
  circleSize,
24828
24734
  radioMarginWidth
24829
- } = constants$1;
24735
+ } = constants;
24830
24736
  var sharedStyles = aphrodite.StyleSheet.create({
24831
24737
  perseusInteractive: {
24832
24738
  zIndex: zIndexInteractiveComponent,
@@ -25182,7 +25088,7 @@ function getA11yText(letter, checked, correct, crossedOut, showCorrectness, stri
25182
25088
  const FocusRing = function (_ref) {
25183
25089
  let {
25184
25090
  visible = true,
25185
- color = kaGreen$1,
25091
+ color = kaGreen,
25186
25092
  multipleSelect = false,
25187
25093
  children
25188
25094
  } = _ref;
@@ -25310,7 +25216,7 @@ function getDynamicStyles(checked, showCorrectness, pressed, multipleSelect, cor
25310
25216
  backgroundColor = "transparent";
25311
25217
  } else if (checked) {
25312
25218
  const bg = showCorrectness && correct ? wonderBlocksTokens.color.green : wonderBlocksTokens.color.blue;
25313
- color = white$1;
25219
+ color = white;
25314
25220
  backgroundColor = bg;
25315
25221
  borderColor = bg;
25316
25222
  } else {
@@ -25388,7 +25294,7 @@ const styles$s = aphrodite.StyleSheet.create({
25388
25294
  borderStyle: "solid",
25389
25295
  borderWidth: 2,
25390
25296
  // The default icons have letters in them. Style those letters.
25391
- fontFamily: baseFontFamily$1,
25297
+ fontFamily: baseFontFamily,
25392
25298
  // NOTE(emily): We explicitly set the font weight instead of using the
25393
25299
  // "bold font family" so that characters which fall back to the default
25394
25300
  // font get bolded too.
@@ -27804,7 +27710,7 @@ const styles$j = aphrodite.StyleSheet.create({
27804
27710
  gradedGroup: {
27805
27711
  borderTop: `1px solid ${gray76}`,
27806
27712
  borderBottom: `1px solid ${gray76}`,
27807
- backgroundColor: tableBackgroundAccent$1,
27713
+ backgroundColor: tableBackgroundAccent,
27808
27714
  marginLeft: negativePhoneMargin,
27809
27715
  marginRight: negativePhoneMargin,
27810
27716
  paddingBottom: phoneMargin,
@@ -28093,7 +27999,7 @@ const styles$i = aphrodite.StyleSheet.create({
28093
27999
  container: {
28094
28000
  borderTop: `1px solid ${gray76}`,
28095
28001
  borderBottom: `1px solid ${gray76}`,
28096
- backgroundColor: tableBackgroundAccent$1,
28002
+ backgroundColor: tableBackgroundAccent,
28097
28003
  marginLeft: negativePhoneMargin,
28098
28004
  marginRight: negativePhoneMargin,
28099
28005
  paddingBottom: phoneMargin,
@@ -28698,21 +28604,6 @@ const typeToButton = type => {
28698
28604
  };
28699
28605
  };
28700
28606
 
28701
- var util = /*#__PURE__*/Object.freeze({
28702
- __proto__: null,
28703
- DEFAULT_BACKGROUND_IMAGE: DEFAULT_BACKGROUND_IMAGE,
28704
- allTypes: allTypes,
28705
- functionForType: functionForType,
28706
- getEquationString: getEquationString,
28707
- pointsFromNormalized: pointsFromNormalized,
28708
- maybePointsFromNormalized: maybePointsFromNormalized,
28709
- defaultPlotProps: defaultPlotProps,
28710
- chooseType: chooseType,
28711
- getGridAndSnapSteps: getGridAndSnapSteps,
28712
- DEFAULT_GRAPHER_PROPS: DEFAULT_GRAPHER_PROPS,
28713
- typeToButton: typeToButton
28714
- });
28715
-
28716
28607
  function getCoefficientsByType(data) {
28717
28608
  if (data.type === "exponential" || data.type === "logarithm") {
28718
28609
  const grader = functionForType(data.type);
@@ -31314,7 +31205,7 @@ const styles$g = aphrodite.StyleSheet.create({
31314
31205
  fontFamily: boldFontFamily,
31315
31206
  fontSize: "15px",
31316
31207
  lineHeight: "18px",
31317
- color: white$1,
31208
+ color: white,
31318
31209
  userSelect: "none",
31319
31210
  borderWidth: 0 // <button> gives us a border by default
31320
31211
  },
@@ -32388,7 +32279,12 @@ const actions = {
32388
32279
  },
32389
32280
  polygon: {
32390
32281
  movePoint,
32391
- moveAll
32282
+ moveAll,
32283
+ addPoint,
32284
+ removePoint,
32285
+ focusPoint,
32286
+ blurPoint,
32287
+ clickPoint
32392
32288
  },
32393
32289
  quadratic: {
32394
32290
  movePoint
@@ -32532,6 +32428,7 @@ function reinitialize(params) {
32532
32428
  * https://www.w3.org/WAI/WCAG21/Understanding/target-size.html
32533
32429
  */
32534
32430
  const TARGET_SIZE = 44;
32431
+ const REMOVE_BUTTON_ID = "perseus_mafs_remove_button";
32535
32432
 
32536
32433
  // same as pointsFromNormalized in interactive-graph.tsx
32537
32434
  const normalizePoints = (range, step, coordsList, noSnap) => coordsList.map(coords =>
@@ -32563,6 +32460,9 @@ function bound$1(_ref) {
32563
32460
  const boundingBox = inset(snapStep, range);
32564
32461
  return clampToBox(boundingBox, point);
32565
32462
  }
32463
+ function isUnlimitedGraphState(state) {
32464
+ return state.type === "point" && state.numPoints === "unlimited" || state.type === "polygon" && state.numSides === "unlimited";
32465
+ }
32566
32466
 
32567
32467
  var isProduction = process.env.NODE_ENV === 'production';
32568
32468
  var prefix = 'Invariant failed';
@@ -32737,25 +32637,18 @@ const hitboxSizePx = 48;
32737
32637
  // MovablePointView is a purely presentational component (i.e. it is a pure
32738
32638
  // function with no state or effects) that renders the SVG for a movable point
32739
32639
  // on an interactive graph.
32740
- //
32741
- // It has two modes for managing tabbing / focus: "controlled" (where the caller
32742
- // manages the display of the focus ring, and the point itself cannot be
32743
- // focused) and "uncontrolled" (where the point is focusable, and the browser
32744
- // manages the focus state and styling). For context on why we did this, see
32745
- // the description of https://github.com/Khan/perseus/pull/1240
32746
32640
  const MovablePointView = /*#__PURE__*/React.forwardRef((props, hitboxRef) => {
32747
32641
  const {
32748
32642
  range,
32749
32643
  markings,
32750
- showTooltips,
32751
- disableKeyboardInteraction
32644
+ showTooltips
32752
32645
  } = useGraphConfig();
32753
32646
  const {
32754
32647
  point,
32755
32648
  color = wonderBlocksTokens.color.blue,
32756
32649
  dragging,
32757
- focusBehavior,
32758
32650
  cursor,
32651
+ showFocusRing,
32759
32652
  onClick = () => {}
32760
32653
  } = props;
32761
32654
 
@@ -32765,7 +32658,7 @@ const MovablePointView = /*#__PURE__*/React.forwardRef((props, hitboxRef) => {
32765
32658
  let [_, value] = _ref;
32766
32659
  return value === color;
32767
32660
  })?.[0] ?? "blue";
32768
- const pointClasses = `movable-point ${dragging ? "movable-point--dragging" : ""} ${focusClass(focusBehavior)}`;
32661
+ const pointClasses = classNames("movable-point", dragging && "movable-point--dragging", showFocusRing && "movable-point--focus");
32769
32662
  const [[x, y]] = useTransformVectorsToPixels(point);
32770
32663
  const [[xMin, xMax], [yMin, yMax]] = range;
32771
32664
  const [[verticalStartX]] = useTransformVectorsToPixels([xMin, 0]);
@@ -32794,15 +32687,6 @@ const MovablePointView = /*#__PURE__*/React.forwardRef((props, hitboxRef) => {
32794
32687
  cursor
32795
32688
  },
32796
32689
  "data-testid": "movable-point",
32797
- tabIndex: disableKeyboardInteraction ? -1 : tabIndex(focusBehavior),
32798
- onFocus: event => {
32799
- const callback = getOnFocusChangeCallback(focusBehavior);
32800
- callback && callback(event, true);
32801
- },
32802
- onBlur: event => {
32803
- const callback = getOnFocusChangeCallback(focusBehavior);
32804
- callback && callback(event, false);
32805
- },
32806
32690
  onClick: onClick
32807
32691
  }, /*#__PURE__*/React__namespace.createElement("circle", {
32808
32692
  className: "movable-point-hitbox",
@@ -32839,25 +32723,102 @@ const MovablePointView = /*#__PURE__*/React.forwardRef((props, hitboxRef) => {
32839
32723
  }
32840
32724
  }, svgForPoint) : svgForPoint);
32841
32725
  });
32842
- function focusClass(config) {
32843
- if (config.type === "controlled" && config.showFocusRing) {
32844
- return "movable-point--focus";
32726
+
32727
+ // TODO(benchristel): Move this to a more central location if it's reused.
32728
+ // Or install the library.
32729
+ function classNames() {
32730
+ for (var _len = arguments.length, names = new Array(_len), _key = 0; _key < _len; _key++) {
32731
+ names[_key] = arguments[_key];
32845
32732
  }
32846
- return "";
32733
+ return names.filter(Boolean).join(" ");
32847
32734
  }
32848
- function tabIndex(config) {
32849
- if (config.type === "uncontrolled") {
32850
- return config.tabIndex;
32851
- }
32852
- return undefined;
32735
+
32736
+ function useControlPoint(params) {
32737
+ const {
32738
+ snapStep,
32739
+ disableKeyboardInteraction
32740
+ } = useGraphConfig();
32741
+ const {
32742
+ point,
32743
+ color,
32744
+ cursor,
32745
+ constrain = p => snap(snapStep, p),
32746
+ onMove = noop$1,
32747
+ onClick = noop$1,
32748
+ onFocus = noop$1,
32749
+ onBlur = noop$1,
32750
+ forwardedRef = noop$1
32751
+ } = params;
32752
+ const [focused, setFocused] = React.useState(false);
32753
+ const focusableHandleRef = React.useRef(null);
32754
+ useDraggable({
32755
+ gestureTarget: focusableHandleRef,
32756
+ point,
32757
+ onMove,
32758
+ constrainKeyboardMovement: constrain
32759
+ });
32760
+ const visiblePointRef = React.useRef(null);
32761
+ const {
32762
+ dragging
32763
+ } = useDraggable({
32764
+ gestureTarget: visiblePointRef,
32765
+ point,
32766
+ onMove,
32767
+ constrainKeyboardMovement: constrain
32768
+ });
32769
+ React.useLayoutEffect(() => {
32770
+ setForwardedRef(forwardedRef, focusableHandleRef.current);
32771
+ }, [forwardedRef]);
32772
+ const focusableHandle = /*#__PURE__*/React__namespace.createElement("g", {
32773
+ "data-testid": "movable-point__focusable-handle",
32774
+ className: "movable-point__focusable-handle",
32775
+ tabIndex: disableKeyboardInteraction ? -1 : 0,
32776
+ ref: focusableHandleRef,
32777
+ onFocus: event => {
32778
+ onFocus(event);
32779
+ setFocused(true);
32780
+ },
32781
+ onBlur: event => {
32782
+ onBlur(event);
32783
+ setFocused(false);
32784
+ }
32785
+ });
32786
+ const visiblePoint = /*#__PURE__*/React__namespace.createElement(MovablePointView, {
32787
+ cursor: cursor,
32788
+ onClick: () => {
32789
+ onClick();
32790
+ focusableHandleRef.current?.focus();
32791
+ },
32792
+ point: point,
32793
+ dragging: dragging,
32794
+ color: color,
32795
+ ref: visiblePointRef,
32796
+ showFocusRing: focused
32797
+ });
32798
+ return {
32799
+ focusableHandle,
32800
+ visiblePoint,
32801
+ focusableHandleRef,
32802
+ visiblePointRef
32803
+ };
32853
32804
  }
32854
- function getOnFocusChangeCallback(config) {
32855
- if (config.type === "uncontrolled") {
32856
- return config.onFocusChange;
32805
+
32806
+ // TODO(benchristel): move this to a more central place if we want to reuse it.
32807
+ function setForwardedRef(ref, value) {
32808
+ if (typeof ref === "function") {
32809
+ ref(value);
32810
+ } else if (ref !== null) {
32811
+ ref.current = value;
32857
32812
  }
32858
- return () => {};
32859
32813
  }
32860
32814
 
32815
+ // This `noop` const is an optimization. Above, we use the forwardedRef
32816
+ // variable, which defaults to `noop`, in a useEffect deps array. Using `noop`
32817
+ // as the default value instead of `() => {}` ensures that the forwardedRef
32818
+ // variable will have the same value on repeated renders, preventing the
32819
+ // useEffect callback from re-running needlessly.
32820
+ const noop$1 = () => {};
32821
+
32861
32822
  const MovableLine = props => {
32862
32823
  const {
32863
32824
  onMoveLine = () => {},
@@ -32881,11 +32842,19 @@ const MovableLine = props => {
32881
32842
  const {
32882
32843
  visiblePoint: visiblePoint1,
32883
32844
  focusableHandle: focusableHandle1
32884
- } = useControlPoint(start, color, p => onMovePoint(0, p));
32845
+ } = useControlPoint({
32846
+ point: start,
32847
+ color,
32848
+ onMove: p => onMovePoint(0, p)
32849
+ });
32885
32850
  const {
32886
32851
  visiblePoint: visiblePoint2,
32887
32852
  focusableHandle: focusableHandle2
32888
- } = useControlPoint(end, color, p => onMovePoint(1, p));
32853
+ } = useControlPoint({
32854
+ point: end,
32855
+ color,
32856
+ onMove: p => onMovePoint(1, p)
32857
+ });
32889
32858
  const line = /*#__PURE__*/React__namespace.createElement(Line$1, {
32890
32859
  start: start,
32891
32860
  end: end,
@@ -32895,51 +32864,6 @@ const MovableLine = props => {
32895
32864
  });
32896
32865
  return /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, focusableHandle1, line, focusableHandle2, visiblePoint1, visiblePoint2);
32897
32866
  };
32898
- function useControlPoint(point, color, onMovePoint) {
32899
- const {
32900
- snapStep,
32901
- disableKeyboardInteraction
32902
- } = useGraphConfig();
32903
- const [focused, setFocused] = React.useState(false);
32904
- const keyboardHandleRef = React.useRef(null);
32905
- useDraggable({
32906
- gestureTarget: keyboardHandleRef,
32907
- point,
32908
- onMove: onMovePoint,
32909
- constrainKeyboardMovement: p => snap(snapStep, p)
32910
- });
32911
- const visiblePointRef = React.useRef(null);
32912
- const {
32913
- dragging
32914
- } = useDraggable({
32915
- gestureTarget: visiblePointRef,
32916
- point,
32917
- onMove: onMovePoint,
32918
- constrainKeyboardMovement: p => snap(snapStep, p)
32919
- });
32920
- const focusableHandle = /*#__PURE__*/React__namespace.createElement("g", {
32921
- "data-testid": "movable-point__focusable-handle",
32922
- className: "movable-point__focusable-handle",
32923
- tabIndex: disableKeyboardInteraction ? -1 : 0,
32924
- ref: keyboardHandleRef,
32925
- onFocus: () => setFocused(true),
32926
- onBlur: () => setFocused(false)
32927
- });
32928
- const visiblePoint = /*#__PURE__*/React__namespace.createElement(MovablePointView, {
32929
- point: point,
32930
- dragging: dragging,
32931
- color: color,
32932
- ref: visiblePointRef,
32933
- focusBehavior: {
32934
- type: "controlled",
32935
- showFocusRing: focused
32936
- }
32937
- });
32938
- return {
32939
- focusableHandle,
32940
- visiblePoint
32941
- };
32942
- }
32943
32867
  const defaultStroke = "var(--movable-line-stroke-color)";
32944
32868
  const Line$1 = props => {
32945
32869
  const {
@@ -33449,59 +33373,16 @@ function calculateBisectorPoint(point1, point2, vertex, isReflex, allowReflex, a
33449
33373
 
33450
33374
  const MovablePoint$1 = /*#__PURE__*/React__namespace.forwardRef((props, pointRef) => {
33451
33375
  const {
33452
- snapStep
33453
- } = useGraphConfig();
33454
- const elementRef = React.useRef(null);
33455
- const {
33456
- point,
33457
- onMove = () => {},
33458
- onFocusChange = () => {},
33459
- onClick = () => {},
33460
- cursor,
33461
- color = wonderBlocksTokens.color.blue,
33462
- constrain = p => snap(snapStep, p)
33463
- } = props;
33464
- const {
33465
- dragging
33466
- } = useDraggable({
33467
- gestureTarget: elementRef,
33468
- point,
33469
- onMove,
33470
- constrainKeyboardMovement: constrain
33471
- });
33472
- return /*#__PURE__*/React__namespace.createElement(MovablePointView, {
33473
- ref: ref => {
33474
- // Note: This handles the case where pointRef is either a
33475
- // function or a MutableRefObject. Mostly this is to satisfy
33476
- // the type system, the function branch seems to be the only
33477
- // one that occurs
33478
- if (typeof pointRef === "function") {
33479
- pointRef(ref);
33480
- } else if (pointRef !== null) {
33481
- pointRef.current = ref;
33482
- }
33483
-
33484
- // This ref is for the useDraggable and is not passed up the
33485
- // chain
33486
- elementRef.current = ref;
33487
- },
33488
- point: point,
33489
- color: color,
33490
- dragging: dragging,
33491
- focusBehavior: {
33492
- type: "uncontrolled",
33493
- tabIndex: 0,
33494
- onFocusChange
33495
- },
33496
- onClick: () => {
33497
- onClick && onClick();
33498
- elementRef.current?.focus();
33499
- },
33500
- cursor: cursor
33376
+ visiblePoint,
33377
+ focusableHandle
33378
+ } = useControlPoint({
33379
+ ...props,
33380
+ forwardedRef: pointRef
33501
33381
  });
33382
+ return /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, focusableHandle, visiblePoint);
33502
33383
  });
33503
33384
 
33504
- const PolygonGraph = props => {
33385
+ const LimitedPolygonGraph = props => {
33505
33386
  const [hovered, setHovered] = React__namespace.useState(false);
33506
33387
  // This is more so required for the re-rendering that occurs when state
33507
33388
  // updates; specifically with regard to line weighting and polygon focus.
@@ -33613,6 +33494,153 @@ const PolygonGraph = props => {
33613
33494
  }
33614
33495
  })));
33615
33496
  };
33497
+
33498
+ // TODO(catjohnson): reduce redundancy between LimitedPolygonGraph and UnlimitedPolygonGraph
33499
+ // both components are vary similar, however more implementation is needed to be added before
33500
+ // it is clear what can and can't be shared between components.
33501
+ const UnlimitedPolygonGraph = props => {
33502
+ const [hovered, setHovered] = React__namespace.useState(false);
33503
+ // This is more so required for the re-rendering that occurs when state
33504
+ // updates; specifically with regard to line weighting and polygon focus.
33505
+ const [focusVisible, setFocusVisible] = React__namespace.useState(false);
33506
+ const {
33507
+ dispatch
33508
+ } = props;
33509
+ const {
33510
+ coords,
33511
+ showAngles,
33512
+ showSides,
33513
+ range,
33514
+ snapStep,
33515
+ snapTo = "grid"
33516
+ } = props.graphState;
33517
+ const graphConfig = useGraphConfig();
33518
+
33519
+ // TODO(catjohnson): Explore abstracting this code as it is similar to point.tsx
33520
+ // and hopefully we can cut down ont the unlimited graph redundancy.
33521
+ const {
33522
+ range: [x, y],
33523
+ disableKeyboardInteraction,
33524
+ graphDimensionsInPixels
33525
+ } = graphConfig;
33526
+ const widthPx = graphDimensionsInPixels[0];
33527
+ const heightPx = graphDimensionsInPixels[1];
33528
+ const [[left, top]] = useTransformVectorsToPixels([x[0], y[1]]);
33529
+ const pointRef = React__namespace.useRef([]);
33530
+
33531
+ // TODO(benchristel): can the default set of points be removed here? I don't
33532
+ // think coords can be null.
33533
+ const points = coords ?? [[0, 0]];
33534
+ const polygonRef = React__namespace.useRef(null);
33535
+ const dragReferencePoint = points[0];
33536
+ const constrain = ["angles", "sides"].includes(snapTo) ? p => p : p => snap(snapStep, p);
33537
+ const {
33538
+ dragging
33539
+ } = useDraggable({
33540
+ gestureTarget: polygonRef,
33541
+ point: dragReferencePoint,
33542
+ onMove: newPoint => {
33543
+ const delta = mafs.vec.sub(newPoint, dragReferencePoint);
33544
+ dispatch(actions.polygon.moveAll(delta));
33545
+ },
33546
+ constrainKeyboardMovement: constrain
33547
+ });
33548
+ const lines = getLines(points);
33549
+ React__namespace.useEffect(() => {
33550
+ const focusedIndex = props.graphState.focusedPointIndex;
33551
+ if (focusedIndex != null) {
33552
+ pointRef.current[focusedIndex]?.focus();
33553
+ }
33554
+ }, [props.graphState.focusedPointIndex, pointRef]);
33555
+ return /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, /*#__PURE__*/React__namespace.createElement("rect", {
33556
+ style: {
33557
+ fill: "rgba(0,0,0,0)",
33558
+ cursor: "crosshair"
33559
+ },
33560
+ width: widthPx,
33561
+ height: heightPx,
33562
+ x: left,
33563
+ y: top,
33564
+ onClick: event => {
33565
+ const elementRect = event.currentTarget.getBoundingClientRect();
33566
+ const x = event.clientX - elementRect.x;
33567
+ const y = event.clientY - elementRect.y;
33568
+ const graphCoordinates = pixelsToVectors([[x, y]], graphConfig);
33569
+ dispatch(actions.polygon.addPoint(graphCoordinates[0]));
33570
+ }
33571
+ }), /*#__PURE__*/React__namespace.createElement(mafs.Polygon, {
33572
+ points: [...points],
33573
+ color: "var(--movable-line-stroke-color)",
33574
+ svgPolygonProps: {
33575
+ strokeWidth: focusVisible ? "var(--movable-line-stroke-weight-active)" : "var(--movable-line-stroke-weight)",
33576
+ style: {
33577
+ fill: "transparent"
33578
+ }
33579
+ }
33580
+ }), props.graphState.coords.map((point, i) => {
33581
+ const pt1 = points.at(i - 1);
33582
+ const pt2 = points[(i + 1) % points.length];
33583
+ if (!pt1 || !pt2) {
33584
+ return null;
33585
+ }
33586
+ return /*#__PURE__*/React__namespace.createElement(PolygonAngle, {
33587
+ key: "angle-" + i,
33588
+ centerPoint: point,
33589
+ endPoints: [pt1, pt2],
33590
+ range: range,
33591
+ polygonLines: lines,
33592
+ showAngles: !!showAngles,
33593
+ snapTo: snapTo
33594
+ });
33595
+ }), showSides && lines.map((_ref2, i) => {
33596
+ let [start, end] = _ref2;
33597
+ const [x, y] = mafs.vec.midpoint(start, end);
33598
+ const length = parseFloat(mafs.vec.dist(start, end).toFixed(snapTo === "sides" ? 0 : 1));
33599
+ return /*#__PURE__*/React__namespace.createElement(TextLabel, {
33600
+ key: "side-" + i,
33601
+ x: x,
33602
+ y: y
33603
+ }, !Number.isInteger(length) && "≈ ", length);
33604
+ }), /*#__PURE__*/React__namespace.createElement(mafs.Polygon, {
33605
+ points: [...points],
33606
+ color: "transparent",
33607
+ svgPolygonProps: {
33608
+ ref: polygonRef,
33609
+ tabIndex: disableKeyboardInteraction ? -1 : 0,
33610
+ strokeWidth: TARGET_SIZE,
33611
+ style: {
33612
+ cursor: dragging ? "grabbing" : "grab",
33613
+ fill: hovered ? "var(--mafs-blue)" : "transparent"
33614
+ },
33615
+ onMouseEnter: () => setHovered(true),
33616
+ onMouseLeave: () => setHovered(false),
33617
+ // Required to remove line weighting when user clicks away
33618
+ // from the focused polygon
33619
+ onKeyDownCapture: () => {
33620
+ setFocusVisible(hasFocusVisible(polygonRef.current));
33621
+ },
33622
+ // Required for lines to darken on focus
33623
+ onFocus: () => setFocusVisible(hasFocusVisible(polygonRef.current)),
33624
+ // Required for line weighting to update on blur. Without this,
33625
+ // the user has to hover over the shape for it to update
33626
+ onBlur: () => setFocusVisible(hasFocusVisible(polygonRef.current)),
33627
+ className: "movable-polygon"
33628
+ }
33629
+ }), props.graphState.coords.map((point, i) => /*#__PURE__*/React__namespace.createElement(MovablePoint$1, {
33630
+ key: i,
33631
+ point: point,
33632
+ onMove: destination => dispatch(actions.pointGraph.movePoint(i, destination)),
33633
+ ref: ref => {
33634
+ pointRef.current[i] = ref;
33635
+ },
33636
+ onFocus: () => {
33637
+ dispatch(actions.pointGraph.focusPoint(i));
33638
+ },
33639
+ onClick: () => {
33640
+ dispatch(actions.pointGraph.clickPoint(i));
33641
+ }
33642
+ })));
33643
+ };
33616
33644
  function getLines(points) {
33617
33645
  return points.map((point, i) => {
33618
33646
  const next = points[(i + 1) % points.length];
@@ -33630,6 +33658,10 @@ const hasFocusVisible = element => {
33630
33658
  return matches(":focus");
33631
33659
  }
33632
33660
  };
33661
+ const PolygonGraph = props => {
33662
+ const numSides = props.graphState.numSides;
33663
+ return numSides === "unlimited" ? UnlimitedPolygonGraph(props) : LimitedPolygonGraph(props);
33664
+ };
33633
33665
 
33634
33666
  function getGradableGraph(state, initialGraph) {
33635
33667
  if (!state.hasBeenInteractedWith) {
@@ -34081,10 +34113,10 @@ function UnlimitedPointGraph(props) {
34081
34113
  const {
34082
34114
  dispatch
34083
34115
  } = props;
34084
- const graphState = useGraphConfig();
34116
+ const graphConfig = useGraphConfig();
34085
34117
  const {
34086
34118
  range: [[minX, maxX], [minY, maxY]]
34087
- } = graphState;
34119
+ } = graphConfig;
34088
34120
  const width = maxX - minX;
34089
34121
  const height = maxY - minY;
34090
34122
  const [[widthPx, heightPx]] = useTransformDimensionsToPixels([width, height]);
@@ -34109,7 +34141,7 @@ function UnlimitedPointGraph(props) {
34109
34141
  const elementRect = event.currentTarget.getBoundingClientRect();
34110
34142
  const x = event.clientX - elementRect.x;
34111
34143
  const y = event.clientY - elementRect.y;
34112
- const graphCoordinates = pixelsToVectors([[x, y]], graphState);
34144
+ const graphCoordinates = pixelsToVectors([[x, y]], graphConfig);
34113
34145
  dispatch(actions.pointGraph.addPoint(graphCoordinates[0]));
34114
34146
  }
34115
34147
  }), props.graphState.coords.map((point, i) => /*#__PURE__*/React__namespace.createElement(MovablePoint$1, {
@@ -34119,23 +34151,8 @@ function UnlimitedPointGraph(props) {
34119
34151
  ref: ref => {
34120
34152
  itemsRef.current[i] = ref;
34121
34153
  },
34122
- onFocusChange: (event, isFocused) => {
34123
- if (isFocused) {
34124
- dispatch(actions.pointGraph.focusPoint(i));
34125
- } else {
34126
- if (event.relatedTarget?.id === REMOVE_BUTTON_ID) {
34127
- return;
34128
- // This is an optimization: If the next target
34129
- // is a point then don't blur because it casues
34130
- // the remove button to get taken off the page
34131
- // and then put back on The new point will
34132
- // receive focus and set the correct state in
34133
- // the reducer
34134
- } else if (event.relatedTarget?.classList.contains("movable-point")) {
34135
- return;
34136
- }
34137
- dispatch(actions.pointGraph.blurPoint());
34138
- }
34154
+ onFocus: () => {
34155
+ dispatch(actions.pointGraph.focusPoint(i));
34139
34156
  },
34140
34157
  onClick: () => {
34141
34158
  dispatch(actions.pointGraph.clickPoint(i));
@@ -34297,7 +34314,6 @@ function useDraggablePx(args) {
34297
34314
  * - Protractor
34298
34315
  * - Interactive Graph Elements
34299
34316
  */
34300
- const REMOVE_BUTTON_ID = "perseus_mafs_remove_button";
34301
34317
  const MafsGraph = props => {
34302
34318
  const {
34303
34319
  state,
@@ -34337,6 +34353,7 @@ const MafsGraph = props => {
34337
34353
  const {
34338
34354
  strings
34339
34355
  } = usePerseusI18n();
34356
+ const interactionPrompt = isUnlimitedGraphState(state) && state.showKeyboardInteractionInvitation;
34340
34357
  wonderBlocksCore.useOnMountEffect(() => {
34341
34358
  analytics.onAnalyticsEvent({
34342
34359
  type: "perseus:interactive-graph-widget:rendered",
@@ -34449,7 +34466,7 @@ const MafsGraph = props => {
34449
34466
  }, /*#__PURE__*/React__namespace.createElement("svg", nestedSVGAttributes, props.showProtractor && /*#__PURE__*/React__namespace.createElement(Protractor, null), renderGraph({
34450
34467
  state,
34451
34468
  dispatch
34452
- }))))), state.type === "point" && state.showKeyboardInteractionInvitation && /*#__PURE__*/React__namespace.createElement(wonderBlocksCore.View, {
34469
+ }))))), interactionPrompt && /*#__PURE__*/React__namespace.createElement(wonderBlocksCore.View, {
34453
34470
  style: {
34454
34471
  textAlign: "center",
34455
34472
  backgroundColor: "white",
@@ -34466,7 +34483,7 @@ const MafsGraph = props => {
34466
34483
  state,
34467
34484
  dispatch,
34468
34485
  width,
34469
- strings
34486
+ perseusStrings: strings
34470
34487
  })));
34471
34488
  };
34472
34489
  const renderPointGraphControls = props => {
@@ -34476,7 +34493,7 @@ const renderPointGraphControls = props => {
34476
34493
  focusedPointIndex
34477
34494
  } = props.state;
34478
34495
  const {
34479
- strings
34496
+ perseusStrings
34480
34497
  } = props;
34481
34498
  const shouldShowRemoveButton = showRemovePointButton && focusedPointIndex !== null;
34482
34499
  return /*#__PURE__*/React__namespace.createElement(wonderBlocksCore.View, {
@@ -34494,7 +34511,7 @@ const renderPointGraphControls = props => {
34494
34511
  onClick: () => {
34495
34512
  props.dispatch(actions.pointGraph.addPoint([0, 0]));
34496
34513
  }
34497
- }, strings.addPoint), interactionMode === "mouse" && /*#__PURE__*/React__namespace.createElement(Button__default["default"], {
34514
+ }, perseusStrings.addPoint), interactionMode === "mouse" && /*#__PURE__*/React__namespace.createElement(Button__default["default"], {
34498
34515
  id: REMOVE_BUTTON_ID,
34499
34516
  kind: "secondary",
34500
34517
  color: "destructive"
@@ -34507,17 +34524,66 @@ const renderPointGraphControls = props => {
34507
34524
  marginLeft: "20px",
34508
34525
  visibility: shouldShowRemoveButton ? "visible" : "hidden"
34509
34526
  },
34510
- onClick: event => {
34527
+ onClick: _event => {
34511
34528
  props.dispatch(actions.pointGraph.removePoint(props.state.focusedPointIndex));
34512
34529
  }
34513
- }, strings.removePoint));
34530
+ }, perseusStrings.removePoint));
34531
+ };
34532
+
34533
+ /**
34534
+ * TODO(catjohnson): The polygon controls will be vastly different from the point controls.
34535
+ * Will be keeping this function as is for the time being, even if it's a copy of the point graph
34536
+ * controls.
34537
+ */
34538
+ const renderPolygonGraphControls = props => {
34539
+ const {
34540
+ interactionMode,
34541
+ showRemovePointButton,
34542
+ focusedPointIndex
34543
+ } = props.state;
34544
+ const {
34545
+ perseusStrings
34546
+ } = props;
34547
+ const shouldShowRemoveButton = showRemovePointButton && focusedPointIndex !== null;
34548
+ return /*#__PURE__*/React__namespace.createElement(wonderBlocksCore.View, {
34549
+ style: {
34550
+ flexDirection: "row",
34551
+ width: props.width
34552
+ }
34553
+ }, interactionMode === "keyboard" && /*#__PURE__*/React__namespace.createElement(Button__default["default"], {
34554
+ kind: "secondary",
34555
+ style: {
34556
+ width: "100%",
34557
+ marginLeft: "20px"
34558
+ },
34559
+ tabIndex: 0,
34560
+ onClick: () => {
34561
+ props.dispatch(actions.polygon.addPoint([0, 0]));
34562
+ }
34563
+ }, perseusStrings.addPoint), interactionMode === "mouse" && /*#__PURE__*/React__namespace.createElement(Button__default["default"], {
34564
+ id: REMOVE_BUTTON_ID,
34565
+ kind: "secondary",
34566
+ color: "destructive"
34567
+ // This button is meant to be interacted with by the mouse only
34568
+ // Never allow learners to tab to this button
34569
+ ,
34570
+ tabIndex: -1,
34571
+ style: {
34572
+ width: "100%",
34573
+ marginLeft: "20px",
34574
+ visibility: shouldShowRemoveButton ? "visible" : "hidden"
34575
+ },
34576
+ onClick: _event => {
34577
+ props.dispatch(actions.polygon.removePoint(props.state.focusedPointIndex));
34578
+ }
34579
+ }, perseusStrings.removePoint));
34514
34580
  };
34515
34581
  const renderGraphControls = props => {
34516
34582
  const {
34517
34583
  state,
34518
34584
  dispatch,
34519
34585
  width,
34520
- strings
34586
+ perseusStrings
34521
34587
  } = props;
34522
34588
  const {
34523
34589
  type
@@ -34529,7 +34595,17 @@ const renderGraphControls = props => {
34529
34595
  state,
34530
34596
  dispatch,
34531
34597
  width,
34532
- strings
34598
+ perseusStrings
34599
+ });
34600
+ }
34601
+ return null;
34602
+ case "polygon":
34603
+ if (state.numSides === "unlimited") {
34604
+ return renderPolygonGraphControls({
34605
+ state,
34606
+ dispatch,
34607
+ width,
34608
+ perseusStrings
34533
34609
  });
34534
34610
  }
34535
34611
  return null;
@@ -34538,21 +34614,28 @@ const renderGraphControls = props => {
34538
34614
  }
34539
34615
  };
34540
34616
  function handleFocusEvent(event, state, dispatch) {
34541
- if (state.type === "point" && state.numPoints === "unlimited") {
34617
+ if (isUnlimitedGraphState(state)) {
34542
34618
  if (event.target.classList.contains("mafs-graph") && state.interactionMode === "mouse") {
34543
34619
  dispatch(actions.global.changeKeyboardInvitationVisibility(true));
34544
34620
  }
34545
34621
  }
34546
34622
  }
34547
- function handleBlurEvent(event, state, dispatch) {
34548
- if (state.type === "point" && state.numPoints === "unlimited") {
34623
+ function handleBlurEvent(_event, state, dispatch) {
34624
+ if (isUnlimitedGraphState(state)) {
34549
34625
  dispatch(actions.global.changeKeyboardInvitationVisibility(false));
34550
34626
  }
34551
34627
  }
34552
34628
  function handleKeyboardEvent(event, state, dispatch) {
34553
- if (state.type === "point" && state.numPoints === "unlimited") {
34629
+ if (isUnlimitedGraphState(state)) {
34554
34630
  if (event.key === "Backspace") {
34555
- dispatch(actions.global.deleteIntent());
34631
+ // TODO(benchristel): Checking classList here is a hack to prevent
34632
+ // points from being deleted if the user presses the backspace key
34633
+ // while the whole graph is focused. Instead of doing this, we
34634
+ // should move the keyboard event handler to the movable point
34635
+ // handle element.
34636
+ if (document.activeElement?.classList.contains("movable-point__focusable-handle")) {
34637
+ dispatch(actions.global.deleteIntent());
34638
+ }
34556
34639
 
34557
34640
  // After removing a point blur
34558
34641
  // It would be nice if this could focus on the graph but doing so
@@ -34811,10 +34894,15 @@ function initializeGraphState(params) {
34811
34894
  return {
34812
34895
  ...shared,
34813
34896
  type: "polygon",
34897
+ numSides: graph.numSides || 0,
34814
34898
  showAngles: Boolean(graph.showAngles),
34815
34899
  showSides: Boolean(graph.showSides),
34816
34900
  coords: getPolygonCoords(graph, range, step),
34817
- snapTo: graph.snapTo ?? "grid"
34901
+ snapTo: graph.snapTo ?? "grid",
34902
+ focusedPointIndex: null,
34903
+ showRemovePointButton: false,
34904
+ interactionMode: "mouse",
34905
+ showKeyboardInteractionInvitation: false
34818
34906
  };
34819
34907
  case "point":
34820
34908
  return {
@@ -35108,10 +35196,9 @@ function interactiveGraphReducer(state, action) {
35108
35196
  }
35109
35197
  function doDeleteIntent(state, action) {
35110
35198
  // For unlimited point graphs
35111
- if (state.type === "point" && state.numPoints === "unlimited") {
35112
- // if there's a focused point
35199
+ if (isUnlimitedGraphState(state)) {
35200
+ // Remove the last point that was focused, if any
35113
35201
  if (state.focusedPointIndex !== null) {
35114
- // Remove the focused focus
35115
35202
  return doRemovePoint(state, actions.pointGraph.removePoint(state.focusedPointIndex));
35116
35203
  }
35117
35204
  }
@@ -35119,6 +35206,7 @@ function doDeleteIntent(state, action) {
35119
35206
  }
35120
35207
  function doFocusPoint(state, action) {
35121
35208
  switch (state.type) {
35209
+ case "polygon":
35122
35210
  case "point":
35123
35211
  return {
35124
35212
  ...state,
@@ -35130,6 +35218,7 @@ function doFocusPoint(state, action) {
35130
35218
  }
35131
35219
  function doBlurPoint(state, action) {
35132
35220
  switch (state.type) {
35221
+ case "polygon":
35133
35222
  case "point":
35134
35223
  const nextState = {
35135
35224
  ...state,
@@ -35144,10 +35233,7 @@ function doBlurPoint(state, action) {
35144
35233
  }
35145
35234
  }
35146
35235
  function doClickPoint(state, action) {
35147
- if (state.type !== "point") {
35148
- return state;
35149
- }
35150
- if (state.numPoints === "unlimited") {
35236
+ if (isUnlimitedGraphState(state)) {
35151
35237
  return {
35152
35238
  ...state,
35153
35239
  focusedPointIndex: action.index,
@@ -35157,10 +35243,7 @@ function doClickPoint(state, action) {
35157
35243
  return state;
35158
35244
  }
35159
35245
  function doChangeInteractionMode(state, action) {
35160
- if (state.type !== "point") {
35161
- return state;
35162
- }
35163
- if (state.numPoints === "unlimited") {
35246
+ if (isUnlimitedGraphState(state)) {
35164
35247
  const nextKeyboardInvitation = action.mode === "keyboard" ? false : state.showKeyboardInteractionInvitation;
35165
35248
  return {
35166
35249
  ...state,
@@ -35171,10 +35254,7 @@ function doChangeInteractionMode(state, action) {
35171
35254
  return state;
35172
35255
  }
35173
35256
  function doChangeKeyboardInvitationVisibility(state, action) {
35174
- if (state.type !== "point") {
35175
- return state;
35176
- }
35177
- if (state.numPoints === "unlimited") {
35257
+ if (isUnlimitedGraphState(state)) {
35178
35258
  return {
35179
35259
  ...state,
35180
35260
  showKeyboardInteractionInvitation: action.shouldShow,
@@ -35521,7 +35601,7 @@ function doChangeRange(state, action) {
35521
35601
  };
35522
35602
  }
35523
35603
  function doAddPoint(state, action) {
35524
- if (state.type !== "point") {
35604
+ if (!isUnlimitedGraphState(state)) {
35525
35605
  return state;
35526
35606
  }
35527
35607
  const {
@@ -35546,7 +35626,7 @@ function doAddPoint(state, action) {
35546
35626
  };
35547
35627
  }
35548
35628
  function doRemovePoint(state, action) {
35549
- if (state.type !== "point") {
35629
+ if (!isUnlimitedGraphState(state)) {
35550
35630
  return state;
35551
35631
  }
35552
35632
  let nextFocusedPointIndex;
@@ -37835,9 +37915,6 @@ function shouldUseMafs(mafsFlags, graph) {
37835
37915
  return Boolean(mafsFlags["point"]);
37836
37916
  case "polygon":
37837
37917
  if (graph.numSides === UNLIMITED) {
37838
- // TODO(benchristel): add a feature flag for the "unlimited"
37839
- // case once we've implemented polygon graphs with unlimited
37840
- // sides
37841
37918
  return Boolean(mafsFlags["unlimited-polygon"]);
37842
37919
  }
37843
37920
  return Boolean(mafsFlags["polygon"]);
@@ -37855,976 +37932,15 @@ var InteractiveGraph$1 = {
37855
37932
  validator: interactiveGraphValidator
37856
37933
  };
37857
37934
 
37858
- const black = "#000000";
37859
- const grayDarker = "#333333";
37860
- const grayDark = "#555555";
37861
- const gray = "#999999";
37862
- const grayLight = "#AAAAAA";
37863
- const grayLighter = "#DDDDDD";
37864
- const white = "#FFFFFF";
37865
- const blue = "#005A88";
37866
- const blueDark = "#2C3747";
37867
- const green = "#76A005";
37868
- const red = "#CF5044";
37869
- const yellow = "#FFC40D";
37870
- const orange = "#BF4F04";
37871
- const pink = "#C3325F";
37872
- const purple = "#7A43B6";
37873
- const bodyBackground = "#FFFFFF";
37874
- const textColor = "#444444";
37875
- const linkColor = "#005987";
37876
- const linkColorHover = "#678D00";
37877
- const sansFontFamily = "'Helvetica Neue',Helvetica,Arial,sans-serif";
37878
- const serifFontFamily = "Georgia,'Times New Roman',Times,serif";
37879
- const monoFontFamily = "Monaco,Menlo,Consolas,'Courier New',monospace";
37880
- const baseFontSize = "14px";
37881
- const baseFontFamily = "inherit";
37882
- const baseLineHeight = "20px";
37883
- const altFontFamily = "Georgia,'Times New Roman',Times,serif";
37884
- const headingsFontFamily = "inherit";
37885
- const headingsFontWeight = "bold";
37886
- const headingsColor = "inherit";
37887
- const fontSizeLarge = "18px";
37888
- const fontSizeSmall = "12px";
37889
- const fontSizeMini = "10.5px";
37890
- const paddingLarge = "11px 19px";
37891
- const paddingSmall = "2px 10px";
37892
- const paddingMini = "0 6px";
37893
- const baseBorderRadius = "4px";
37894
- const borderRadiusLarge = "6px";
37895
- const borderRadiusSmall = "3px";
37896
- const tableBackground = "#000000";
37897
- const tableBackgroundAccent = "#F9F9F9";
37898
- const tableBackgroundHover = "#F5F5F5";
37899
- const tableBorder = "#DDDDDD";
37900
- const btnBackground = "#FFFFFF";
37901
- const btnBackgroundHighlight = "rgb(230, 230, 230)";
37902
- const btnBorder = "#CCCCCC";
37903
- const btnPrimaryBackground = "#0088CC";
37904
- const btnPrimaryBackgroundHighlight = "rgb(0, 68, 204)";
37905
- const btnInfoBackground = "#5BC0DE";
37906
- const btnInfoBackgroundHighlight = "#2F96B4";
37907
- const btnSuccessBackground = "#62C462";
37908
- const btnSuccessBackgroundHighlight = "#51A351";
37909
- const btnWarningBackground = "rgb(251, 180, 81)";
37910
- const btnWarningBackgroundHighlight = "#F89406";
37911
- const btnDangerBackground = "#EE5F5B";
37912
- const btnDangerBackgroundHighlight = "#BD362F";
37913
- const btnInverseBackground = "#444444";
37914
- const btnInverseBackgroundHighlight = "#222222";
37915
- const inputBackground = "#FFFFFF";
37916
- const inputBorder = "#CCCCCC";
37917
- const inputBorderRadius = "4px";
37918
- const inputDisabledBackground = "#EEEEEE";
37919
- const formActionsBackground = "#F5F5F5";
37920
- const inputHeight = "30px";
37921
- const dropdownBackground = "#FFFFFF";
37922
- const dropdownBorder = "rgba(0, 0, 0, 0.2)";
37923
- const dropdownDividerTop = "#E5E5E5";
37924
- const dropdownDividerBottom = "#FFFFFF";
37925
- const dropdownLinkColor = "#333333";
37926
- const dropdownLinkColorHover = "#FFFFFF";
37927
- const dropdownLinkColorActive = "#FFFFFF";
37928
- const dropdownLinkBackgroundActive = "#0088CC";
37929
- const dropdownLinkBackgroundHover = "#0088CC";
37930
- const zindexDropdown = 1000;
37931
- const zindexPopover = 1010;
37932
- const zindexTooltip = 1030;
37933
- const zindexFixedNavbar = 1030;
37934
- const zindexHeader = 1060;
37935
- const zindexModalBackdrop = 1070;
37936
- const zindexModal = 1080;
37937
- const zindexAboveModal = 1090;
37938
- const iconSpritePath = "../img/glyphicons-halflings.png";
37939
- const iconWhiteSpritePath = "../img/glyphicons-halflings-white.png";
37940
- const placeholderText = "#999999";
37941
- const hrBorder = "#EEEEEE";
37942
- const horizontalComponentOffset = "180px";
37943
- const wellBackground = "#F5F5F5";
37944
- const navbarCollapseWidth = "979px";
37945
- const navbarCollapseDesktopWidth = "980px";
37946
- const navbarHeight = "40px";
37947
- const navbarBackgroundHighlight = "#FFFFFF";
37948
- const navbarBackground = "rgb(242, 242, 242)";
37949
- const navbarBorder = "rgb(212, 212, 212)";
37950
- const navbarText = "#777777";
37951
- const navbarLinkColor = "#777777";
37952
- const navbarLinkColorHover = "#333333";
37953
- const navbarLinkColorActive = "#555555";
37954
- const navbarLinkBackgroundHover = "#000000";
37955
- const navbarLinkBackgroundActive = "rgb(230, 230, 230)";
37956
- const navbarBrandColor = "#777777";
37957
- const navbarInverseBackground = "#111111";
37958
- const navbarInverseBackgroundHighlight = "#222222";
37959
- const navbarInverseBorder = "#252525";
37960
- const navbarInverseText = "#999999";
37961
- const navbarInverseLinkColor = "#999999";
37962
- const navbarInverseLinkColorHover = "#FFFFFF";
37963
- const navbarInverseLinkColorActive = "#FFFFFF";
37964
- const navbarInverseLinkBackgroundHover = "#000000";
37965
- const navbarInverseLinkBackgroundActive = "#111111";
37966
- const navbarInverseSearchBackground = "rgb(82, 82, 82)";
37967
- const navbarInverseSearchBackgroundFocus = "#FFFFFF";
37968
- const navbarInverseSearchBorder = "#111111";
37969
- const navbarInverseSearchPlaceholderColor = "#CCCCCC";
37970
- const navbarInverseBrandColor = "#999999";
37971
- const paginationBackground = "#FFFFFF";
37972
- const paginationBorder = "#DDDDDD";
37973
- const paginationActiveBackground = "#F5F5F5";
37974
- const heroUnitBackground = "#EEEEEE";
37975
- const heroUnitHeadingColor = "inherit";
37976
- const heroUnitLeadColor = "inherit";
37977
- const warningText = "#C09853";
37978
- const warningBackground = "#FCF8E3";
37979
- const warningBorder = "rgb(251, 239, 213)";
37980
- const errorText = "#B94A48";
37981
- const errorBackground = "#F2DEDE";
37982
- const errorBorder = "rgb(238, 211, 215)";
37983
- const successText = "#468847";
37984
- const successBackground = "#DFF0D8";
37985
- const successBorder = "rgb(212, 232, 197)";
37986
- const infoText = "#4A7C17";
37987
- const infoBackground = "#EDF2DF";
37988
- const infoBorder = "rgb(228, 232, 197)";
37989
- const tooltipColor = "#FFFFFF";
37990
- const tooltipBackground = "#000000";
37991
- const tooltipArrowWidth = "5px";
37992
- const tooltipArrowColor = "#000000";
37993
- const popoverBackground = "#FFFFFF";
37994
- const popoverArrowWidth = "10px";
37995
- const popoverArrowColor = "#FFFFFF";
37996
- const popoverTitleBackground = "rgb(247, 247, 247)";
37997
- const popoverArrowOuterWidth = "11px";
37998
- const popoverArrowOuterColor = "rgba(0, 0, 0, 0.25)";
37999
- const gridColumns = "12";
38000
- const gridColumnWidth = "60px";
38001
- const gridGutterWidth = "20px";
38002
- const gridRowWidth = "940px";
38003
- const gridColumnWidth1200 = "70px";
38004
- const gridGutterWidth1200 = "30px";
38005
- const gridRowWidth1200 = "1170px";
38006
- const gridColumnWidth768 = "42px";
38007
- const gridGutterWidth768 = "20px";
38008
- const gridRowWidth768 = "724px";
38009
- const fluidGridColumnWidth = "6.382978723404255%";
38010
- const fluidGridGutterWidth = "2.127659574468085%";
38011
- const fluidGridColumnWidth1200 = "5.982905982905983%";
38012
- const fluidGridGutterWidth1200 = "2.564102564102564%";
38013
- const fluidGridColumnWidth768 = "5.801104972375691%";
38014
- const fluidGridGutterWidth768 = "2.7624309392265194%";
38015
- const kaGreen = "#71B307";
38016
- const kaGreenLight = "#BED47A";
38017
- const kaBlue = "#314453";
38018
- const kaBlueLight = "#4D6779";
38019
- const grayExtraDark = "#111111";
38020
- const grayExtraLight = "#EEEEEE";
38021
- const graySuperLight = "#F7F7F7";
38022
- const whiteDark = "#FDFDFD";
38023
- const dark = "#21242C";
38024
- const blueDarkUnsaturated = "#3B414E";
38025
- const blueDarkSaturated = "#1F3043";
38026
- const blueLight = "#A9C0D1";
38027
- const greenLight = "#C6D1AD";
38028
- const greenDark = "#356700";
38029
- const yellowGreen = "#9DB63B";
38030
- const okGreen = "#A7CF5B";
38031
- const alertRed = "#C42420";
38032
- const coral = "#EE6666";
38033
- const grayBlue = "#9AB3B9";
38034
- const lightPageBackground = "#FDFDFD";
38035
- const yclaBlue = "#49BAD5";
38036
- const yclaTeal = "#56D0B3";
38037
- const yclaTealDark = "#50C1A7";
38038
- const yclaGreenDark = "#3D9A82";
38039
- const yclaGreen = "#81C262";
38040
- const learnstormBlue = "#4898FC";
38041
- const homepageBlue = "#46A8BF";
38042
- const backgroundBlue = "#00294A";
38043
- const teacherSignupBlue = "#335d7d";
38044
- const homepageGreen = "#2B8E7B";
38045
- const streakColor = "#F79734";
38046
- const facebookColor = "#1A60A2";
38047
- const blueGoogleColor = "#2CAFE2";
38048
- const redGoogleColor = "#BF4434";
38049
- const homepageColor = "#2D585E";
38050
- const lightTextColor = "#898989";
38051
- const fontSizeTiny = "11px";
38052
- const fontSizeNormal = "14px";
38053
- const fontSizeMedium = "16px";
38054
- const fontSizeExtraLarge = "24px";
38055
- const fontSizeHuge = "36px";
38056
- const fontSizeBakana = "48px";
38057
- const fontSizeBananas = "60px";
38058
- const fixedWidthFontFamily = "'Helvetica Neue',Helvetica,Arial,sans-serif";
38059
- const contentPadding = "20px";
38060
- const primaryButtonBackground = "#89B908";
38061
- const primaryButtonBorder = "#76A005";
38062
- const buttonTextColor = "rgb(122, 122, 122)";
38063
- const buttonBorderRadius = "3px";
38064
- const basicBorderColor = "#CCCCCC";
38065
- const minContainerWidth = "1000px";
38066
- const maxContainerWidth = "1200px";
38067
- const formHintColor = "#999999";
38068
- const guidelineExampleText = "#606060";
38069
- const hoverCardWidth = "450px";
38070
- const menuHighlightColor = "#96AB4F";
38071
- const menuHighlightBorderColor = "#76A005";
38072
- const menuActiveTextColor = "#FFFFFF";
38073
- const menuInactiveTextColor = "#444444";
38074
- const menuSubheaderTextColor = "rgb(120, 120, 120)";
38075
- const menuBorderColor = "#94A170";
38076
- const unreadBackgroundColor = "#ECEEF4";
38077
- const menuLineHeight = "18px";
38078
- const menuSubheaderLineHeight = "17px";
38079
- const menuSubheaderFontSize = "9px";
38080
- const notificationBarColor = "#4858A4";
38081
- const modalBodyTopPadding = "20px";
38082
- const modalDialogPadding = "15px";
38083
- const modalSectionPadding = "9px";
38084
- const mathDomain1 = "#11ACCD";
38085
- const mathDomain2 = "#63D9EA";
38086
- const mathDomain3 = "#027d97";
38087
- const mathDomain4 = "#085566";
38088
- const partnerContentDomain1 = "#01A995";
38089
- const partnerContentDomain2 = "#01D1C1";
38090
- const partnerContentDomain3 = "#208170";
38091
- const partnerContentDomain4 = "#144F44";
38092
- const csDomain1 = "#1FAB54";
38093
- const csDomain2 = "#74CF70";
38094
- const csDomain3 = "#0D923F";
38095
- const csDomain4 = "#085E29";
38096
- const economicsDomain1 = "#E07D10";
38097
- const economicsDomain2 = "#FFBE26";
38098
- const economicsDomain3 = "#A75A05";
38099
- const economicsDomain4 = "#953C02";
38100
- const collegeCareersMoreDomain1 = "#01A995";
38101
- const collegeCareersMoreDomain2 = "#01D1C1";
38102
- const collegeCareersMoreDomain3 = "#208170";
38103
- const collegeCareersMoreDomain4 = "#144F44";
38104
- const humanitiesDomain1 = "#E84D39";
38105
- const humanitiesDomain2 = "#FF8482";
38106
- const humanitiesDomain3 = "#BE2612";
38107
- const humanitiesDomain4 = "#8C1C0D";
38108
- const gtpDomain1 = "#1865F2";
38109
- const gtpDomain2 = "#1865F2";
38110
- const gtpDomain3 = "#1865F2";
38111
- const gtpDomain4 = "#1865F2";
38112
- const scienceDomain1 = "#CA337C";
38113
- const scienceDomain2 = "#FF92C6";
38114
- const scienceDomain3 = "#9E034E";
38115
- const scienceDomain4 = "#6B0235";
38116
- const testPrepDomain1 = "#1865F2";
38117
- const testPrepDomain2 = "#1865F2";
38118
- const testPrepDomain3 = "#1865F2";
38119
- const testPrepDomain4 = "#1865F2";
38120
- const defaultDomain1 = "#1865F2";
38121
- const defaultDomain2 = "#66afe9";
38122
- const defaultDomain3 = "#1152b0";
38123
- const defaultDomain4 = "#0d3d82";
38124
- const defaultDomainColor = "#314453";
38125
- const defaultSubjectColor = "#4D6779";
38126
- const defaultTopicColor = "#6A8DA6";
38127
- const defaultHoverColor = "#314453";
38128
- const defaultLinkColor = "#314453";
38129
- const defaultLinkHoverColor = "#6A8DA6";
38130
- const scienceDomainColor = "#94424F";
38131
- const scienceSubjectColor = "#9D4A5A";
38132
- const scienceTopicColor = "#C55F73";
38133
- const scienceHoverColor = "#94424F";
38134
- const scienceLinkColor = "#94424F";
38135
- const scienceLinkHoverColor = "#C55F73";
38136
- const humanitiesDomainColor = "#AD3434";
38137
- const humanitiesSubjectColor = "#C13B31";
38138
- const humanitiesTopicColor = "#D24A45";
38139
- const humanitiesHoverColor = "#AD3434";
38140
- const humanitiesLinkColor = "#AD3434";
38141
- const humanitiesLinkHoverColor = "#D24A45";
38142
- const economicsDomainColor = "#B77033";
38143
- const economicsSubjectColor = "#BF7B34";
38144
- const economicsTopicColor = "#D1933B";
38145
- const economicsHoverColor = "#B77033";
38146
- const economicsLinkColor = "#B77033";
38147
- const economicsLinkHoverColor = "#D1933B";
38148
- const csDomainColor = "#437A39";
38149
- const csSubjectColor = "#53893E";
38150
- const csTopicColor = "#689B51";
38151
- const csHoverColor = "#437A39";
38152
- const csLinkColor = "#437A39";
38153
- const csLinkHoverColor = "#689B51";
38154
- const partnerContentDomainColor = "#218270";
38155
- const partnerContentSubjectColor = "#2C8D7B";
38156
- const partnerContentTopicColor = "#329A86";
38157
- const partnerContentHoverColor = "#218270";
38158
- const partnerContentLinkColor = "#218270";
38159
- const partnerContentLinkHoverColor = "#329A86";
38160
- const essayDomainColor = "#0071B3";
38161
- const mathDomainColor = "#1C758A";
38162
- const mathSubjectColor = "#46A8BF";
38163
- const mathTopicColor = "#4FBAD4";
38164
- const mathHoverColor = "#1C758A";
38165
- const mathLinkColor = "#1C758A";
38166
- const mathLinkHoverColor = "#4FBAD4";
38167
- const testPrepDomainColor = "#644172";
38168
- const testPrepSubjectColor = "#7E5F8E";
38169
- const testPrepTopicColor = "#9A72AC";
38170
- const testPrepHoverColor = "#644172";
38171
- const testPrepLinkColor = "#644172";
38172
- const testPrepLinkHoverColor = "#9A72AC";
38173
- const collegeCareersMoreDomainColor = "#218270";
38174
- const collegeCareersMoreSubjectColor = "#2C8D7B";
38175
- const collegeCareersMoreTopicColor = "#329A86";
38176
- const collegeCareersMoreHoverColor = "#218270";
38177
- const collegeCareersMoreLinkColor = "#218270";
38178
- const collegeCareersMoreLinkHoverColor = "#329A86";
38179
- const colorProficient = "#1C758A";
38180
- const colorPracticed = "rgb(158, 221, 235)";
38181
- const colorMastery1 = "rgb(90, 197, 221)";
38182
- const colorMastery2 = "rgb(42, 174, 203)";
38183
- const colorMastery3 = "#1C758A";
38184
- const colorSuggested = "#73982C";
38185
- const colorReview = "#E35D04";
38186
- const colorNotStarted = "#CCCCCC";
38187
- const colorStarted = "#C7E5F7";
38188
- const colorStruggling = "#C30202";
38189
- const colorPersonal = "#00809C";
38190
- const colorPractice = "#96D9FF";
38191
- const colorEnergyPoints = "#005987";
38192
- const pureSmMin = "568px";
38193
- const pureMdMin = "768px";
38194
- const pureLgMin = "1024px";
38195
- const pureXlMin = "1200px";
38196
- const pureXsMax = "567px";
38197
- const pureSmMax = "767px";
38198
- const pureMdMax = "1023px";
38199
- const pureLgMax = "1199px";
38200
-
38201
- var globalConstants = /*#__PURE__*/Object.freeze({
38202
- __proto__: null,
38203
- black: black,
38204
- grayDarker: grayDarker,
38205
- grayDark: grayDark,
38206
- gray: gray,
38207
- grayLight: grayLight,
38208
- grayLighter: grayLighter,
38209
- white: white,
38210
- blue: blue,
38211
- blueDark: blueDark,
38212
- green: green,
38213
- red: red,
38214
- yellow: yellow,
38215
- orange: orange,
38216
- pink: pink,
38217
- purple: purple,
38218
- bodyBackground: bodyBackground,
38219
- textColor: textColor,
38220
- linkColor: linkColor,
38221
- linkColorHover: linkColorHover,
38222
- sansFontFamily: sansFontFamily,
38223
- serifFontFamily: serifFontFamily,
38224
- monoFontFamily: monoFontFamily,
38225
- baseFontSize: baseFontSize,
38226
- baseFontFamily: baseFontFamily,
38227
- baseLineHeight: baseLineHeight,
38228
- altFontFamily: altFontFamily,
38229
- headingsFontFamily: headingsFontFamily,
38230
- headingsFontWeight: headingsFontWeight,
38231
- headingsColor: headingsColor,
38232
- fontSizeLarge: fontSizeLarge,
38233
- fontSizeSmall: fontSizeSmall,
38234
- fontSizeMini: fontSizeMini,
38235
- paddingLarge: paddingLarge,
38236
- paddingSmall: paddingSmall,
38237
- paddingMini: paddingMini,
38238
- baseBorderRadius: baseBorderRadius,
38239
- borderRadiusLarge: borderRadiusLarge,
38240
- borderRadiusSmall: borderRadiusSmall,
38241
- tableBackground: tableBackground,
38242
- tableBackgroundAccent: tableBackgroundAccent,
38243
- tableBackgroundHover: tableBackgroundHover,
38244
- tableBorder: tableBorder,
38245
- btnBackground: btnBackground,
38246
- btnBackgroundHighlight: btnBackgroundHighlight,
38247
- btnBorder: btnBorder,
38248
- btnPrimaryBackground: btnPrimaryBackground,
38249
- btnPrimaryBackgroundHighlight: btnPrimaryBackgroundHighlight,
38250
- btnInfoBackground: btnInfoBackground,
38251
- btnInfoBackgroundHighlight: btnInfoBackgroundHighlight,
38252
- btnSuccessBackground: btnSuccessBackground,
38253
- btnSuccessBackgroundHighlight: btnSuccessBackgroundHighlight,
38254
- btnWarningBackground: btnWarningBackground,
38255
- btnWarningBackgroundHighlight: btnWarningBackgroundHighlight,
38256
- btnDangerBackground: btnDangerBackground,
38257
- btnDangerBackgroundHighlight: btnDangerBackgroundHighlight,
38258
- btnInverseBackground: btnInverseBackground,
38259
- btnInverseBackgroundHighlight: btnInverseBackgroundHighlight,
38260
- inputBackground: inputBackground,
38261
- inputBorder: inputBorder,
38262
- inputBorderRadius: inputBorderRadius,
38263
- inputDisabledBackground: inputDisabledBackground,
38264
- formActionsBackground: formActionsBackground,
38265
- inputHeight: inputHeight,
38266
- dropdownBackground: dropdownBackground,
38267
- dropdownBorder: dropdownBorder,
38268
- dropdownDividerTop: dropdownDividerTop,
38269
- dropdownDividerBottom: dropdownDividerBottom,
38270
- dropdownLinkColor: dropdownLinkColor,
38271
- dropdownLinkColorHover: dropdownLinkColorHover,
38272
- dropdownLinkColorActive: dropdownLinkColorActive,
38273
- dropdownLinkBackgroundActive: dropdownLinkBackgroundActive,
38274
- dropdownLinkBackgroundHover: dropdownLinkBackgroundHover,
38275
- zindexDropdown: zindexDropdown,
38276
- zindexPopover: zindexPopover,
38277
- zindexTooltip: zindexTooltip,
38278
- zindexFixedNavbar: zindexFixedNavbar,
38279
- zindexHeader: zindexHeader,
38280
- zindexModalBackdrop: zindexModalBackdrop,
38281
- zindexModal: zindexModal,
38282
- zindexAboveModal: zindexAboveModal,
38283
- iconSpritePath: iconSpritePath,
38284
- iconWhiteSpritePath: iconWhiteSpritePath,
38285
- placeholderText: placeholderText,
38286
- hrBorder: hrBorder,
38287
- horizontalComponentOffset: horizontalComponentOffset,
38288
- wellBackground: wellBackground,
38289
- navbarCollapseWidth: navbarCollapseWidth,
38290
- navbarCollapseDesktopWidth: navbarCollapseDesktopWidth,
38291
- navbarHeight: navbarHeight,
38292
- navbarBackgroundHighlight: navbarBackgroundHighlight,
38293
- navbarBackground: navbarBackground,
38294
- navbarBorder: navbarBorder,
38295
- navbarText: navbarText,
38296
- navbarLinkColor: navbarLinkColor,
38297
- navbarLinkColorHover: navbarLinkColorHover,
38298
- navbarLinkColorActive: navbarLinkColorActive,
38299
- navbarLinkBackgroundHover: navbarLinkBackgroundHover,
38300
- navbarLinkBackgroundActive: navbarLinkBackgroundActive,
38301
- navbarBrandColor: navbarBrandColor,
38302
- navbarInverseBackground: navbarInverseBackground,
38303
- navbarInverseBackgroundHighlight: navbarInverseBackgroundHighlight,
38304
- navbarInverseBorder: navbarInverseBorder,
38305
- navbarInverseText: navbarInverseText,
38306
- navbarInverseLinkColor: navbarInverseLinkColor,
38307
- navbarInverseLinkColorHover: navbarInverseLinkColorHover,
38308
- navbarInverseLinkColorActive: navbarInverseLinkColorActive,
38309
- navbarInverseLinkBackgroundHover: navbarInverseLinkBackgroundHover,
38310
- navbarInverseLinkBackgroundActive: navbarInverseLinkBackgroundActive,
38311
- navbarInverseSearchBackground: navbarInverseSearchBackground,
38312
- navbarInverseSearchBackgroundFocus: navbarInverseSearchBackgroundFocus,
38313
- navbarInverseSearchBorder: navbarInverseSearchBorder,
38314
- navbarInverseSearchPlaceholderColor: navbarInverseSearchPlaceholderColor,
38315
- navbarInverseBrandColor: navbarInverseBrandColor,
38316
- paginationBackground: paginationBackground,
38317
- paginationBorder: paginationBorder,
38318
- paginationActiveBackground: paginationActiveBackground,
38319
- heroUnitBackground: heroUnitBackground,
38320
- heroUnitHeadingColor: heroUnitHeadingColor,
38321
- heroUnitLeadColor: heroUnitLeadColor,
38322
- warningText: warningText,
38323
- warningBackground: warningBackground,
38324
- warningBorder: warningBorder,
38325
- errorText: errorText,
38326
- errorBackground: errorBackground,
38327
- errorBorder: errorBorder,
38328
- successText: successText,
38329
- successBackground: successBackground,
38330
- successBorder: successBorder,
38331
- infoText: infoText,
38332
- infoBackground: infoBackground,
38333
- infoBorder: infoBorder,
38334
- tooltipColor: tooltipColor,
38335
- tooltipBackground: tooltipBackground,
38336
- tooltipArrowWidth: tooltipArrowWidth,
38337
- tooltipArrowColor: tooltipArrowColor,
38338
- popoverBackground: popoverBackground,
38339
- popoverArrowWidth: popoverArrowWidth,
38340
- popoverArrowColor: popoverArrowColor,
38341
- popoverTitleBackground: popoverTitleBackground,
38342
- popoverArrowOuterWidth: popoverArrowOuterWidth,
38343
- popoverArrowOuterColor: popoverArrowOuterColor,
38344
- gridColumns: gridColumns,
38345
- gridColumnWidth: gridColumnWidth,
38346
- gridGutterWidth: gridGutterWidth,
38347
- gridRowWidth: gridRowWidth,
38348
- gridColumnWidth1200: gridColumnWidth1200,
38349
- gridGutterWidth1200: gridGutterWidth1200,
38350
- gridRowWidth1200: gridRowWidth1200,
38351
- gridColumnWidth768: gridColumnWidth768,
38352
- gridGutterWidth768: gridGutterWidth768,
38353
- gridRowWidth768: gridRowWidth768,
38354
- fluidGridColumnWidth: fluidGridColumnWidth,
38355
- fluidGridGutterWidth: fluidGridGutterWidth,
38356
- fluidGridColumnWidth1200: fluidGridColumnWidth1200,
38357
- fluidGridGutterWidth1200: fluidGridGutterWidth1200,
38358
- fluidGridColumnWidth768: fluidGridColumnWidth768,
38359
- fluidGridGutterWidth768: fluidGridGutterWidth768,
38360
- kaGreen: kaGreen,
38361
- kaGreenLight: kaGreenLight,
38362
- kaBlue: kaBlue,
38363
- kaBlueLight: kaBlueLight,
38364
- grayExtraDark: grayExtraDark,
38365
- grayExtraLight: grayExtraLight,
38366
- graySuperLight: graySuperLight,
38367
- whiteDark: whiteDark,
38368
- dark: dark,
38369
- blueDarkUnsaturated: blueDarkUnsaturated,
38370
- blueDarkSaturated: blueDarkSaturated,
38371
- blueLight: blueLight,
38372
- greenLight: greenLight,
38373
- greenDark: greenDark,
38374
- yellowGreen: yellowGreen,
38375
- okGreen: okGreen,
38376
- alertRed: alertRed,
38377
- coral: coral,
38378
- grayBlue: grayBlue,
38379
- lightPageBackground: lightPageBackground,
38380
- yclaBlue: yclaBlue,
38381
- yclaTeal: yclaTeal,
38382
- yclaTealDark: yclaTealDark,
38383
- yclaGreenDark: yclaGreenDark,
38384
- yclaGreen: yclaGreen,
38385
- learnstormBlue: learnstormBlue,
38386
- homepageBlue: homepageBlue,
38387
- backgroundBlue: backgroundBlue,
38388
- teacherSignupBlue: teacherSignupBlue,
38389
- homepageGreen: homepageGreen,
38390
- streakColor: streakColor,
38391
- facebookColor: facebookColor,
38392
- blueGoogleColor: blueGoogleColor,
38393
- redGoogleColor: redGoogleColor,
38394
- homepageColor: homepageColor,
38395
- lightTextColor: lightTextColor,
38396
- fontSizeTiny: fontSizeTiny,
38397
- fontSizeNormal: fontSizeNormal,
38398
- fontSizeMedium: fontSizeMedium,
38399
- fontSizeExtraLarge: fontSizeExtraLarge,
38400
- fontSizeHuge: fontSizeHuge,
38401
- fontSizeBakana: fontSizeBakana,
38402
- fontSizeBananas: fontSizeBananas,
38403
- fixedWidthFontFamily: fixedWidthFontFamily,
38404
- contentPadding: contentPadding,
38405
- primaryButtonBackground: primaryButtonBackground,
38406
- primaryButtonBorder: primaryButtonBorder,
38407
- buttonTextColor: buttonTextColor,
38408
- buttonBorderRadius: buttonBorderRadius,
38409
- basicBorderColor: basicBorderColor,
38410
- minContainerWidth: minContainerWidth,
38411
- maxContainerWidth: maxContainerWidth,
38412
- formHintColor: formHintColor,
38413
- guidelineExampleText: guidelineExampleText,
38414
- hoverCardWidth: hoverCardWidth,
38415
- menuHighlightColor: menuHighlightColor,
38416
- menuHighlightBorderColor: menuHighlightBorderColor,
38417
- menuActiveTextColor: menuActiveTextColor,
38418
- menuInactiveTextColor: menuInactiveTextColor,
38419
- menuSubheaderTextColor: menuSubheaderTextColor,
38420
- menuBorderColor: menuBorderColor,
38421
- unreadBackgroundColor: unreadBackgroundColor,
38422
- menuLineHeight: menuLineHeight,
38423
- menuSubheaderLineHeight: menuSubheaderLineHeight,
38424
- menuSubheaderFontSize: menuSubheaderFontSize,
38425
- notificationBarColor: notificationBarColor,
38426
- modalBodyTopPadding: modalBodyTopPadding,
38427
- modalDialogPadding: modalDialogPadding,
38428
- modalSectionPadding: modalSectionPadding,
38429
- mathDomain1: mathDomain1,
38430
- mathDomain2: mathDomain2,
38431
- mathDomain3: mathDomain3,
38432
- mathDomain4: mathDomain4,
38433
- partnerContentDomain1: partnerContentDomain1,
38434
- partnerContentDomain2: partnerContentDomain2,
38435
- partnerContentDomain3: partnerContentDomain3,
38436
- partnerContentDomain4: partnerContentDomain4,
38437
- csDomain1: csDomain1,
38438
- csDomain2: csDomain2,
38439
- csDomain3: csDomain3,
38440
- csDomain4: csDomain4,
38441
- economicsDomain1: economicsDomain1,
38442
- economicsDomain2: economicsDomain2,
38443
- economicsDomain3: economicsDomain3,
38444
- economicsDomain4: economicsDomain4,
38445
- collegeCareersMoreDomain1: collegeCareersMoreDomain1,
38446
- collegeCareersMoreDomain2: collegeCareersMoreDomain2,
38447
- collegeCareersMoreDomain3: collegeCareersMoreDomain3,
38448
- collegeCareersMoreDomain4: collegeCareersMoreDomain4,
38449
- humanitiesDomain1: humanitiesDomain1,
38450
- humanitiesDomain2: humanitiesDomain2,
38451
- humanitiesDomain3: humanitiesDomain3,
38452
- humanitiesDomain4: humanitiesDomain4,
38453
- gtpDomain1: gtpDomain1,
38454
- gtpDomain2: gtpDomain2,
38455
- gtpDomain3: gtpDomain3,
38456
- gtpDomain4: gtpDomain4,
38457
- scienceDomain1: scienceDomain1,
38458
- scienceDomain2: scienceDomain2,
38459
- scienceDomain3: scienceDomain3,
38460
- scienceDomain4: scienceDomain4,
38461
- testPrepDomain1: testPrepDomain1,
38462
- testPrepDomain2: testPrepDomain2,
38463
- testPrepDomain3: testPrepDomain3,
38464
- testPrepDomain4: testPrepDomain4,
38465
- defaultDomain1: defaultDomain1,
38466
- defaultDomain2: defaultDomain2,
38467
- defaultDomain3: defaultDomain3,
38468
- defaultDomain4: defaultDomain4,
38469
- defaultDomainColor: defaultDomainColor,
38470
- defaultSubjectColor: defaultSubjectColor,
38471
- defaultTopicColor: defaultTopicColor,
38472
- defaultHoverColor: defaultHoverColor,
38473
- defaultLinkColor: defaultLinkColor,
38474
- defaultLinkHoverColor: defaultLinkHoverColor,
38475
- scienceDomainColor: scienceDomainColor,
38476
- scienceSubjectColor: scienceSubjectColor,
38477
- scienceTopicColor: scienceTopicColor,
38478
- scienceHoverColor: scienceHoverColor,
38479
- scienceLinkColor: scienceLinkColor,
38480
- scienceLinkHoverColor: scienceLinkHoverColor,
38481
- humanitiesDomainColor: humanitiesDomainColor,
38482
- humanitiesSubjectColor: humanitiesSubjectColor,
38483
- humanitiesTopicColor: humanitiesTopicColor,
38484
- humanitiesHoverColor: humanitiesHoverColor,
38485
- humanitiesLinkColor: humanitiesLinkColor,
38486
- humanitiesLinkHoverColor: humanitiesLinkHoverColor,
38487
- economicsDomainColor: economicsDomainColor,
38488
- economicsSubjectColor: economicsSubjectColor,
38489
- economicsTopicColor: economicsTopicColor,
38490
- economicsHoverColor: economicsHoverColor,
38491
- economicsLinkColor: economicsLinkColor,
38492
- economicsLinkHoverColor: economicsLinkHoverColor,
38493
- csDomainColor: csDomainColor,
38494
- csSubjectColor: csSubjectColor,
38495
- csTopicColor: csTopicColor,
38496
- csHoverColor: csHoverColor,
38497
- csLinkColor: csLinkColor,
38498
- csLinkHoverColor: csLinkHoverColor,
38499
- partnerContentDomainColor: partnerContentDomainColor,
38500
- partnerContentSubjectColor: partnerContentSubjectColor,
38501
- partnerContentTopicColor: partnerContentTopicColor,
38502
- partnerContentHoverColor: partnerContentHoverColor,
38503
- partnerContentLinkColor: partnerContentLinkColor,
38504
- partnerContentLinkHoverColor: partnerContentLinkHoverColor,
38505
- essayDomainColor: essayDomainColor,
38506
- mathDomainColor: mathDomainColor,
38507
- mathSubjectColor: mathSubjectColor,
38508
- mathTopicColor: mathTopicColor,
38509
- mathHoverColor: mathHoverColor,
38510
- mathLinkColor: mathLinkColor,
38511
- mathLinkHoverColor: mathLinkHoverColor,
38512
- testPrepDomainColor: testPrepDomainColor,
38513
- testPrepSubjectColor: testPrepSubjectColor,
38514
- testPrepTopicColor: testPrepTopicColor,
38515
- testPrepHoverColor: testPrepHoverColor,
38516
- testPrepLinkColor: testPrepLinkColor,
38517
- testPrepLinkHoverColor: testPrepLinkHoverColor,
38518
- collegeCareersMoreDomainColor: collegeCareersMoreDomainColor,
38519
- collegeCareersMoreSubjectColor: collegeCareersMoreSubjectColor,
38520
- collegeCareersMoreTopicColor: collegeCareersMoreTopicColor,
38521
- collegeCareersMoreHoverColor: collegeCareersMoreHoverColor,
38522
- collegeCareersMoreLinkColor: collegeCareersMoreLinkColor,
38523
- collegeCareersMoreLinkHoverColor: collegeCareersMoreLinkHoverColor,
38524
- colorProficient: colorProficient,
38525
- colorPracticed: colorPracticed,
38526
- colorMastery1: colorMastery1,
38527
- colorMastery2: colorMastery2,
38528
- colorMastery3: colorMastery3,
38529
- colorSuggested: colorSuggested,
38530
- colorReview: colorReview,
38531
- colorNotStarted: colorNotStarted,
38532
- colorStarted: colorStarted,
38533
- colorStruggling: colorStruggling,
38534
- colorPersonal: colorPersonal,
38535
- colorPractice: colorPractice,
38536
- colorEnergyPoints: colorEnergyPoints,
38537
- pureSmMin: pureSmMin,
38538
- pureMdMin: pureMdMin,
38539
- pureLgMin: pureLgMin,
38540
- pureXlMin: pureXlMin,
38541
- pureXsMax: pureXsMax,
38542
- pureSmMax: pureSmMax,
38543
- pureMdMax: pureMdMax,
38544
- pureLgMax: pureLgMax
38545
- });
38546
-
38547
- const colors = {
38548
- white: "#FFFFFF",
38549
- gray98: "#FAFAFA",
38550
- gray97: "#F6F7F7",
38551
- gray95: "#F0F1F2",
38552
- gray90: "#E3E5E6",
38553
- gray85: "#D6D8DA",
38554
- gray76: "#BABEC2",
38555
- gray72: "#999A9D",
38556
- gray68: "#888D93",
38557
- gray55: "#707378",
38558
- gray41: "#626569",
38559
- gray25: "#3B3E40",
38560
- gray17: "#21242C",
38561
- gray10: "#1499af",
38562
- black: "#000000",
38563
- // These colors are pulled out from constants.js, which is itself generated
38564
- // from variables.less. We should probably avoid duplicating these here.
38565
- alertRed,
38566
- homepageBlue,
38567
- kaBlue,
38568
- kaBlueLight,
38569
- kaGreen,
38570
- kaGreenLight,
38571
- learnstormBlue,
38572
- backgroundBlue,
38573
- adminGreen: "#78C008",
38574
- kaBlueExtraLight: "#39c2db",
38575
- kaBlueHover: "#0c7f99",
38576
- kaGreenHover: "#518005",
38577
- // Domain-agnostic colors related to the study guide experience in the
38578
- // content library.
38579
- skyDark: "#001f4d",
38580
- recommendationGold: "#ffbe26",
38581
- starAced: "#ff9c39",
38582
- // We interploate the domain colors into this colors object for
38583
- // historical reasons, but everyone using domain-specific colors
38584
- // should switch to using the domainColors() function to look up
38585
- // colors instead.
38586
- //
38587
- // TODO(davidflanagan): remove this line once everything is
38588
- // working correctly with the domainColors() accessor.
38589
- // ...domainToColorsMap,
38590
- // mission: missionColors,
38591
-
38592
- // Colors for various OAuth providers
38593
- google: "#C1432f",
38594
- modernGoogle: "#be2612",
38595
- modernGoogleHover: "#8c1c0d",
38596
- facebook: "#4267B2",
38597
- modernFacebook: "#4267B2",
38598
- modernFacebookHover: "#00294a",
38599
- wonderBlocksGold: "#FFB100",
38600
- wonderBlocksLightBlue: "#37C5FD",
38601
- // We're using rgba instead of opacity to avoid affecting the focus outline
38602
- // when we just want to make the color transparent.
38603
- breadcrumbs: "rgba(255, 255, 255, 0.7)"
38604
- };
38605
- const borderRadius = 4;
38606
- const breadcrumbStyles = {
38607
- color: colors.breadcrumbs,
37935
+ // TODO: can we use WB typography?
37936
+ const bodyXsmallBold = {
37937
+ // For emphasized metadata, descriptions, etc
38608
37938
  fontFamily: "inherit",
38609
37939
  fontSize: 15,
38610
37940
  fontWeight: "bold",
38611
- letterSpacing: 0.8,
38612
- lineHeight: "19px",
38613
- textTransform: "uppercase",
38614
- // Disable subpixel antialiasing for OSX (improves light on dark text)
38615
- MozOsxFontSmoothing: "grayscale",
38616
- WebkitFontSmoothing: "antialiased"
38617
- };
38618
- const fonts = {
38619
- // The body of the page is setup to use 'Helvetica' by default and
38620
- // 'Lato' if/once it downloads. For your elements to follow this
38621
- // pattern, all you need is to make the text in your element
38622
- // inherit from the body using the "inherit" value.
38623
- regular: "inherit"
38624
- };
38625
- const typography = {
38626
- // For subject names
38627
- subjectHeadingDesktop: {
38628
- fontFamily: "inherit",
38629
- fontSize: 50,
38630
- fontWeight: "bold",
38631
- lineHeight: "61px"
38632
- },
38633
- subjectHeadingMobile: {
38634
- fontFamily: "inherit",
38635
- fontSize: 35,
38636
- fontWeight: "bold",
38637
- lineHeight: "37px"
38638
- },
38639
- // For the most important thing on the page
38640
- conceptHeadingDesktop: {
38641
- fontFamily: "inherit",
38642
- fontSize: 35,
38643
- fontWeight: "bold",
38644
- lineHeight: "37px"
38645
- },
38646
- conceptHeadingMobile: {
38647
- fontFamily: "inherit",
38648
- fontSize: 23,
38649
- fontWeight: "bold",
38650
- lineHeight: "27px"
38651
- },
38652
- // For sections or modules
38653
- subheadingDesktop: {
38654
- fontFamily: "inherit",
38655
- fontSize: 23,
38656
- fontWeight: "bold",
38657
- lineHeight: "27px"
38658
- },
38659
- subheadingMobile: {
38660
- fontFamily: "inherit",
38661
- fontSize: 20,
38662
- fontWeight: "bold",
38663
- lineHeight: "24px"
38664
- },
38665
- smallSubheadingDesktop: {
38666
- fontFamily: "inherit",
38667
- fontSize: 20,
38668
- lineHeight: 1.25
38669
- },
38670
- smallSubheadingMobile: {
38671
- fontFamily: "inherit",
38672
- fontSize: 15,
38673
- lineHeight: 1.25
38674
- },
38675
- // For callouts
38676
- smallHeading: {
38677
- color: colors.gray25,
38678
- fontFamily: "inherit",
38679
- fontSize: 17,
38680
- fontWeight: "bold",
38681
- lineHeight: "23px"
38682
- },
38683
- smallHeadingMobile: {
38684
- color: colors.gray25,
38685
- fontFamily: "inherit",
38686
- fontSize: 15,
38687
- fontWeight: "bold",
38688
- lineHeight: "18px"
38689
- },
38690
- // Accent headings
38691
- accentHeading: {
38692
- color: colors.gray68,
38693
- fontFamily: "inherit",
38694
- fontSize: 15,
38695
- fontWeight: "bold",
38696
- letterSpacing: 0.8,
38697
- lineHeight: "19px",
38698
- textTransform: "uppercase"
38699
- },
38700
- bodyLarge: {
38701
- // For articles with multiple paragraphs
38702
- fontFamily: fonts.regular,
38703
- fontSize: 20,
38704
- lineHeight: "30px"
38705
- },
38706
- bodySmall: {
38707
- // For small blocks of copy
38708
- fontFamily: fonts.regular,
38709
- fontSize: 17,
38710
- fontWeight: "normal",
38711
- lineHeight: "23px"
38712
- },
38713
- bodySmallBold: {
38714
- // For small blocks of copy
38715
- fontFamily: fonts.regular,
38716
- fontSize: 17,
38717
- fontWeight: "bold",
38718
- lineHeight: "23px"
38719
- },
38720
- bodyXsmall: {
38721
- // For metadata, descriptions, etc
38722
- fontFamily: fonts.regular,
38723
- fontSize: 15,
38724
- lineHeight: "22px"
38725
- },
38726
- bodyXsmallBold: {
38727
- // For emphasized metadata, descriptions, etc
38728
- fontFamily: "inherit",
38729
- fontSize: 15,
38730
- fontWeight: "bold",
38731
- lineHeight: "22px"
38732
- },
38733
- breadcrumb: breadcrumbStyles,
38734
- // For in-page tabs, breadcrumbs
38735
- breadcrumbSmall: {
38736
- // For in-page tabs and leaf page breadcrumbs
38737
- ...breadcrumbStyles,
38738
- fontSize: 12,
38739
- lineHeight: "13px"
38740
- },
38741
- labelLarge: {
38742
- // For chiclets and thumbnail titles
38743
- fontFamily: "inherit",
38744
- fontSize: 23,
38745
- fontWeight: "bold",
38746
- lineHeight: "27px"
38747
- },
38748
- labelMedium: {
38749
- // For chiclets and thumbnail titles
38750
- fontFamily: "inherit",
38751
- fontSize: 15,
38752
- fontWeight: "bold",
38753
- lineHeight: "18px"
38754
- },
38755
- labelSmall: {
38756
- // Generally used with labelLarge, for breadcrumbs in thumbnails
38757
- fontFamily: fonts.regular,
38758
- fontSize: 12,
38759
- lineHeight: "14px"
38760
- },
38761
- caption: {
38762
- // For image captions
38763
- fontFamily: fonts.regular,
38764
- fontSize: 14,
38765
- fontStyle: "italic",
38766
- lineHeight: "17px"
38767
- },
38768
- desktopScalingOnMobile: {
38769
- // For when you need Mobile Safari and friends to stick to desktop
38770
- // sizes
38771
- MozTextSizeAdjust: "100%",
38772
- MsTextSizeAdjust: "100%",
38773
- WebkitTextSizeAdjust: "100%"
38774
- },
38775
- // TODO (josh): This should move to within <ModalHeader>
38776
- modalSubtitle: {
38777
- fontSize: 12,
38778
- lineHeight: 1.65,
38779
- // NOTE (josh): Font smoothing used here to create a 'medium' weight
38780
- // font, between normal and bold, on webkit browsers.
38781
- // This prop is an a11y risk when used on non-bold text, since it
38782
- // makes text very thin, but it's fine on bold text.
38783
- WebkitFontSmoothing: "antialiased",
38784
- fontWeight: "bold"
38785
- },
38786
- // HACK(kevinb): temporary wonder blocks styles for header only
38787
- // TODO(kevinb): use components from wonder-blocks-typography instead
38788
- wonderBlocksHeader: {
38789
- paddingLeft: 16,
38790
- paddingRight: 16,
38791
- paddingBottom: 24,
38792
- paddingTop: 34,
38793
- [mediaQueries.mdOrLarger]: {
38794
- paddingBottom: 32
38795
- }
38796
- },
38797
- // HACK(kevinb): temporary wonder blocks styles for header only
38798
- // TODO(kevinb): use components from wonder-blocks-typography instead
38799
- wonderBlocksTitle: {
38800
- color: colors.white,
38801
- fontWeight: 900,
38802
- // "Black" weight
38803
- fontSize: 28,
38804
- lineHeight: "32px",
38805
- margin: 0,
38806
- [mediaQueries.mdOrLarger]: {
38807
- fontSize: 36,
38808
- lineHeight: "40px"
38809
- }
38810
- },
38811
- // HACK(kevinb): temporary wonder blocks styles for header only
38812
- // TODO(kevinb): use components from wonder-blocks-typography instead
38813
- wonderBlocksLabelLarge: {
38814
- fontSize: 16,
38815
- lineHeight: "20px",
38816
- fontWeight: 700 // Bold
38817
- }
37941
+ lineHeight: "22px"
38818
37942
  };
38819
37943
 
38820
- var globalStyles = /*#__PURE__*/Object.freeze({
38821
- __proto__: null,
38822
- colors: colors,
38823
- borderRadius: borderRadius,
38824
- fonts: fonts,
38825
- typography: typography
38826
- });
38827
-
38828
37944
  const AnswerChoices = props => {
38829
37945
  const {
38830
37946
  strings
@@ -39742,7 +38858,7 @@ const styles$a = aphrodite.StyleSheet.create({
39742
38858
  paddingBottom: 16
39743
38859
  },
39744
38860
  instructionsCaption: {
39745
- ...typography.bodyXsmallBold,
38861
+ ...bodyXsmallBold,
39746
38862
  paddingBottom: 16
39747
38863
  },
39748
38864
  instructionsChoices: {
@@ -43577,9 +42693,9 @@ const makeSafeUrl = (urlString, locale) => {
43577
42693
  };
43578
42694
  const styles$6 = aphrodite.StyleSheet.create({
43579
42695
  widgetContainer: {
43580
- borderRadius: borderRadiusLarge,
42696
+ borderRadius: 6,
43581
42697
  borderWidth: 1,
43582
- borderColor: basicBorderColor,
42698
+ borderColor: "#CCC",
43583
42699
  padding: wonderBlocksTokens.spacing.medium_16,
43584
42700
  paddingBottom: 0
43585
42701
  },
@@ -45068,7 +44184,7 @@ const init = function (options) {
45068
44184
 
45069
44185
  // This file is processed by a Rollup plugin (replace) to inject the production
45070
44186
  const libName = "@khanacademy/perseus";
45071
- const libVersion = "39.0.1";
44187
+ const libVersion = "40.0.0";
45072
44188
  perseusCore.addLibraryVersionToPerseusDebug(libName, libVersion);
45073
44189
 
45074
44190
  const apiVersion = {
@@ -45349,7 +44465,7 @@ const styles$3 = aphrodite.StyleSheet.create({
45349
44465
  },
45350
44466
  lastRenderedNewHint: {
45351
44467
  marginBottom: 0,
45352
- borderLeftColor: kaGreen$1
44468
+ borderLeftColor: kaGreen
45353
44469
  }
45354
44470
  });
45355
44471
 
@@ -45540,7 +44656,7 @@ const styles$2 = aphrodite.StyleSheet.create({
45540
44656
  fontSize: "100%",
45541
44657
  fontFamily: "inherit",
45542
44658
  fontWeight: "bold",
45543
- color: kaGreen$1,
44659
+ color: kaGreen,
45544
44660
  padding: 0,
45545
44661
  position: "relative"
45546
44662
  },
@@ -45942,28 +45058,6 @@ const ref = /*#__PURE__*/React__namespace.forwardRef((props, ref) => /*#__PURE__
45942
45058
  }));
45943
45059
  }));
45944
45060
 
45945
- const devices = {
45946
- PHONE: "phone",
45947
- TABLET: "tablet",
45948
- DESKTOP: "desktop"
45949
- };
45950
-
45951
- // How many pixels do we reserve on the right-hand side of a preview
45952
- // for displaying lint indicators? This space needs to be reserved
45953
- // in DeviceFramer, but it is actually allocated in PerseusFrame
45954
- const lintGutterWidth = 36;
45955
-
45956
- // How wide a border does PerseusFrame draw? We need to allocate enough
45957
- // space for it in DeviceFramer.
45958
- const perseusFrameBorderWidth = 1;
45959
-
45960
- var constants = /*#__PURE__*/Object.freeze({
45961
- __proto__: null,
45962
- devices: devices,
45963
- lintGutterWidth: lintGutterWidth,
45964
- perseusFrameBorderWidth: perseusFrameBorderWidth
45965
- });
45966
-
45967
45061
  /**
45968
45062
  * Traverses a {content, widgets, images} renderer props object,
45969
45063
  * such as `itemData.question`
@@ -48656,6 +47750,18 @@ const EditorJsonify = {
48656
47750
  }
48657
47751
  };
48658
47752
 
47753
+ /**
47754
+ * Main entry point
47755
+ */
47756
+ const GrapherUtil = {
47757
+ allTypes,
47758
+ DEFAULT_GRAPHER_PROPS,
47759
+ chooseType,
47760
+ defaultPlotProps,
47761
+ getEquationString,
47762
+ typeToButton
47763
+ };
47764
+
48659
47765
  exports.ApiOptions = ApiOptions;
48660
47766
  exports.ArticleRenderer = ArticleRenderer;
48661
47767
  exports.BaseRadio = BaseRadio;
@@ -48665,7 +47771,7 @@ exports.ClassNames = ClassNames;
48665
47771
  exports.Dependencies = dependencies;
48666
47772
  exports.EditorJsonify = EditorJsonify;
48667
47773
  exports.Expression = Expression;
48668
- exports.GrapherUtil = util;
47774
+ exports.GrapherUtil = GrapherUtil;
48669
47775
  exports.GrapherWidget = Grapher$1;
48670
47776
  exports.HintRenderer = HintRenderer;
48671
47777
  exports.HintsRenderer = HintsRenderer;
@@ -48689,17 +47795,17 @@ exports.QUESTION_WIDGETS = QUESTION_WIDGETS;
48689
47795
  exports.Radio = Radio;
48690
47796
  exports.Renderer = Renderer;
48691
47797
  exports.ServerItemRenderer = ref;
48692
- exports.SizingUtils = sizingUtils;
48693
47798
  exports.TableWidget = Table$1;
48694
47799
  exports.Util = Util;
48695
47800
  exports.WIDGET_PROP_DENYLIST = denylist;
48696
47801
  exports.Widgets = widgets$1;
48697
47802
  exports.addWidget = addWidget;
48698
47803
  exports.apiVersion = apiVersion;
47804
+ exports.bodyXsmallBold = bodyXsmallBold;
48699
47805
  exports.buildEmptyItemTreeForShape = buildEmptyItemTreeForShape;
48700
47806
  exports.buildMapper = buildMapper;
48701
47807
  exports.components = components;
48702
- exports.constants = constants;
47808
+ exports.containerSizeClass = containerSizeClass;
48703
47809
  exports.contentHasWidgetType = contentHasWidgetType;
48704
47810
  exports.convertWidgetNameToEnum = convertWidgetNameToEnum;
48705
47811
  exports.displaySigFigs = displaySigFigs;
@@ -48717,6 +47823,7 @@ exports.getCircleCoords = getCircleCoords;
48717
47823
  exports.getClockwiseAngle = getClockwiseAngle;
48718
47824
  exports.getCorrectAnswerForWidgetId = getCorrectAnswerForWidgetId;
48719
47825
  exports.getImagesWithoutAltData = getImagesWithoutAltData;
47826
+ exports.getInteractiveBoxFromSizeClass = getInteractiveBoxFromSizeClass;
48720
47827
  exports.getLineCoords = getLineCoords;
48721
47828
  exports.getLinearSystemCoords = getLinearSystemCoords;
48722
47829
  exports.getPointCoords = getPointCoords;
@@ -48731,9 +47838,8 @@ exports.getWidgetIdsFromContentByType = getWidgetIdsFromContentByType;
48731
47838
  exports.getWidgetTypeByWidgetId = getWidgetTypeByWidgetId;
48732
47839
  exports.getWidgetsFromWidgetMap = getWidgetsFromWidgetMap;
48733
47840
  exports.getWidgetsMapFromItemData = getWidgetsMapFromItemData;
48734
- exports.globalConstants = globalConstants;
48735
- exports.globalStyles = globalStyles;
48736
- exports.icons = iconPaths;
47841
+ exports.iconChevronDown = iconChevronDown;
47842
+ exports.iconTrash = iconTrash;
48737
47843
  exports.init = init;
48738
47844
  exports.injectWidgets = injectWidgets;
48739
47845
  exports.interactiveSizes = interactiveSizes$1;