@khanacademy/perseus-editor 2.6.1 → 2.6.3

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.
Files changed (176) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/dist/article-editor.d.ts +1 -2
  3. package/dist/components/form-wrapped-text-field.d.ts +1 -10
  4. package/dist/components/graph-points-count-selector.d.ts +1 -1
  5. package/dist/es/index.js +373 -364
  6. package/dist/es/index.js.map +1 -1
  7. package/dist/index.js +375 -366
  8. package/dist/index.js.map +1 -1
  9. package/dist/widgets/input-number-editor.d.ts +1 -2
  10. package/dist/widgets/interactive-graph-editor.d.ts +140 -139
  11. package/package.json +12 -12
  12. package/src/__stories__/editor.stories.tsx +3 -1
  13. package/src/__tests__/i18n.test.ts +1 -1
  14. package/src/article-editor.tsx +13 -14
  15. package/src/components/checkbox.tsx +1 -1
  16. package/src/components/dropdown-option.tsx +12 -12
  17. package/src/components/form-wrapped-text-field.tsx +4 -2
  18. package/src/components/graph-points-count-selector.tsx +3 -1
  19. package/src/components/graph-settings.tsx +1 -1
  20. package/src/components/hover-behavior.ts +2 -2
  21. package/src/components/json-editor.tsx +2 -2
  22. package/src/components/sortable.tsx +1 -1
  23. package/src/components/util.ts +1 -1
  24. package/src/components/widget-editor.tsx +7 -7
  25. package/src/diffs/__tests__/structured-item-diff.test.ts +8 -8
  26. package/src/diffs/renderer-diff.tsx +3 -3
  27. package/src/diffs/split-diff.ts +2 -2
  28. package/src/diffs/structured-item-diff.tsx +10 -10
  29. package/src/diffs/text-diff.tsx +1 -1
  30. package/src/diffs/widget-diff.tsx +2 -2
  31. package/src/editor-page.tsx +8 -8
  32. package/src/editor.tsx +36 -36
  33. package/src/hint-editor.tsx +27 -27
  34. package/src/i18n.ts +4 -4
  35. package/src/iframe-content-renderer.tsx +10 -10
  36. package/src/item-editor.tsx +4 -4
  37. package/src/multirenderer-editor.tsx +17 -11
  38. package/src/widgets/categorizer-editor.tsx +3 -3
  39. package/src/widgets/cs-program-editor.tsx +2 -2
  40. package/src/widgets/definition-editor.tsx +2 -2
  41. package/src/widgets/dropdown-editor.tsx +8 -8
  42. package/src/widgets/example-graphie-widget-editor.tsx +1 -1
  43. package/src/widgets/example-graphie-widget.tsx +2 -2
  44. package/src/widgets/example-widget-editor.tsx +2 -2
  45. package/src/widgets/example-widget.tsx +3 -3
  46. package/src/widgets/explanation-editor.tsx +3 -3
  47. package/src/widgets/expression-editor.tsx +9 -9
  48. package/src/widgets/graded-group-editor.tsx +6 -6
  49. package/src/widgets/graded-group-set-editor.tsx +3 -3
  50. package/src/widgets/grapher-editor.tsx +2 -2
  51. package/src/widgets/group-editor.tsx +3 -3
  52. package/src/widgets/iframe-editor.tsx +4 -4
  53. package/src/widgets/input-number-editor.tsx +6 -6
  54. package/src/widgets/interaction-editor.tsx +102 -102
  55. package/src/widgets/interactive-graph-editor.tsx +12 -8
  56. package/src/widgets/label-image/marker.tsx +1 -1
  57. package/src/widgets/label-image/question-markers.tsx +1 -1
  58. package/src/widgets/lights-puzzle-editor.tsx +4 -4
  59. package/src/widgets/matrix-editor.tsx +2 -2
  60. package/src/widgets/measurer-editor.tsx +6 -6
  61. package/src/widgets/molecule-editor.tsx +2 -2
  62. package/src/widgets/number-line-editor.tsx +1 -1
  63. package/src/widgets/numeric-input-editor.tsx +2 -2
  64. package/src/widgets/orderer-editor.tsx +2 -2
  65. package/src/widgets/passage-editor.tsx +3 -3
  66. package/src/widgets/passage-ref-editor.tsx +3 -3
  67. package/src/widgets/passage-ref-target-editor.tsx +1 -1
  68. package/src/widgets/plotter-editor.tsx +4 -4
  69. package/src/widgets/radio/editor.tsx +3 -3
  70. package/src/widgets/reaction-diagram-editor.tsx +5 -5
  71. package/src/widgets/sequence-editor.tsx +1 -1
  72. package/src/widgets/simple-markdown-tester-editor.tsx +3 -3
  73. package/src/widgets/simple-markdown-tester.tsx +2 -2
  74. package/src/widgets/simulator-editor.tsx +1 -1
  75. package/src/widgets/sorter-editor.tsx +1 -1
  76. package/src/widgets/table-editor.tsx +1 -1
  77. package/src/widgets/transformer-editor.tsx +10 -10
  78. package/src/widgets/unit-editor.tsx +5 -5
  79. package/tsconfig-build.tsbuildinfo +1 -1
  80. package/dist/all-editors.js.flow +0 -8
  81. package/dist/all-widgets.js.flow +0 -34
  82. package/dist/article-editor.js.flow +0 -72
  83. package/dist/components/blur-input.js.flow +0 -25
  84. package/dist/components/checkbox.js.flow +0 -26
  85. package/dist/components/device-framer.js.flow +0 -20
  86. package/dist/components/drag-target.js.flow +0 -8
  87. package/dist/components/dropdown-option.js.flow +0 -49
  88. package/dist/components/form-wrapped-text-field.js.flow +0 -45
  89. package/dist/components/graph-points-count-selector.js.flow +0 -12
  90. package/dist/components/graph-settings.js.flow +0 -8
  91. package/dist/components/graph-type-selector.js.flow +0 -12
  92. package/dist/components/hover-behavior.js.flow +0 -48
  93. package/dist/components/json-editor.js.flow +0 -8
  94. package/dist/components/link.js.flow +0 -50
  95. package/dist/components/section-control-button.js.flow +0 -25
  96. package/dist/components/segment-count-selector.js.flow +0 -11
  97. package/dist/components/simple-button.js.flow +0 -18
  98. package/dist/components/sortable.js.flow +0 -8
  99. package/dist/components/util.js.flow +0 -9
  100. package/dist/components/viewport-resizer.js.flow +0 -22
  101. package/dist/components/widget-editor.js.flow +0 -91
  102. package/dist/components/widget-select.js.flow +0 -16
  103. package/dist/diffs/article-diff.js.flow +0 -71
  104. package/dist/diffs/item-diff.js.flow +0 -41
  105. package/dist/diffs/renderer-diff.js.flow +0 -25
  106. package/dist/diffs/split-diff.js.flow +0 -8
  107. package/dist/diffs/string-array-diff.js.flow +0 -11
  108. package/dist/diffs/structured-item-diff.js.flow +0 -37
  109. package/dist/diffs/tags-diff.js.flow +0 -24
  110. package/dist/diffs/text-diff.js.flow +0 -21
  111. package/dist/diffs/widget-diff-performer.js.flow +0 -8
  112. package/dist/diffs/widget-diff.js.flow +0 -31
  113. package/dist/editor-page.js.flow +0 -72
  114. package/dist/editor.js.flow +0 -96
  115. package/dist/hint-editor.js.flow +0 -87
  116. package/dist/i18n.js.flow +0 -13
  117. package/dist/iframe-content-renderer.js.flow +0 -28
  118. package/dist/index.js.flow +0 -23
  119. package/dist/item-editor.js.flow +0 -46
  120. package/dist/item-extras-editor.js.flow +0 -23
  121. package/dist/katex-error-view.js.flow +0 -24
  122. package/dist/multirenderer-editor.js.flow +0 -46
  123. package/dist/stateful-article-editor.js.flow +0 -16
  124. package/dist/stateful-editor-page.js.flow +0 -8
  125. package/dist/testing-widgets.js.flow +0 -34
  126. package/dist/util/points.js.flow +0 -9
  127. package/dist/util/register-all-widgets-and-editors-for-testing.js.flow +0 -7
  128. package/dist/widgets/categorizer-editor.js.flow +0 -62
  129. package/dist/widgets/cs-program-editor.js.flow +0 -25
  130. package/dist/widgets/definition-editor.js.flow +0 -23
  131. package/dist/widgets/dropdown-editor.js.flow +0 -37
  132. package/dist/widgets/example-graphie-widget-editor.js.flow +0 -25
  133. package/dist/widgets/example-graphie-widget.js.flow +0 -102
  134. package/dist/widgets/example-widget-editor.js.flow +0 -26
  135. package/dist/widgets/example-widget.js.flow +0 -86
  136. package/dist/widgets/explanation-editor.js.flow +0 -27
  137. package/dist/widgets/expression-editor.js.flow +0 -43
  138. package/dist/widgets/graded-group-editor.js.flow +0 -68
  139. package/dist/widgets/graded-group-set-editor.js.flow +0 -66
  140. package/dist/widgets/grapher-editor.js.flow +0 -21
  141. package/dist/widgets/group-editor.js.flow +0 -64
  142. package/dist/widgets/iframe-editor.js.flow +0 -24
  143. package/dist/widgets/image-editor.js.flow +0 -8
  144. package/dist/widgets/input-number-editor.js.flow +0 -77
  145. package/dist/widgets/interaction/constraint-editor.js.flow +0 -35
  146. package/dist/widgets/interaction-editor.js.flow +0 -36
  147. package/dist/widgets/interactive-graph-editor.js.flow +0 -5803
  148. package/dist/widgets/label-image/answer-choices.js.flow +0 -16
  149. package/dist/widgets/label-image/behavior.js.flow +0 -17
  150. package/dist/widgets/label-image/marker.js.flow +0 -32
  151. package/dist/widgets/label-image/question-markers.js.flow +0 -23
  152. package/dist/widgets/label-image/select-image.js.flow +0 -13
  153. package/dist/widgets/label-image-editor.js.flow +0 -44
  154. package/dist/widgets/lights-puzzle-editor.js.flow +0 -34
  155. package/dist/widgets/matcher-editor.js.flow +0 -28
  156. package/dist/widgets/matrix-editor.js.flow +0 -26
  157. package/dist/widgets/measurer-editor.js.flow +0 -42
  158. package/dist/widgets/molecule-editor.js.flow +0 -23
  159. package/dist/widgets/number-line-editor.js.flow +0 -45
  160. package/dist/widgets/numeric-input-editor.js.flow +0 -8
  161. package/dist/widgets/orderer-editor.js.flow +0 -30
  162. package/dist/widgets/passage-editor.js.flow +0 -24
  163. package/dist/widgets/passage-ref-editor.js.flow +0 -17
  164. package/dist/widgets/passage-ref-target-editor.js.flow +0 -22
  165. package/dist/widgets/plotter-editor.js.flow +0 -75
  166. package/dist/widgets/radio/editor.js.flow +0 -81
  167. package/dist/widgets/reaction-diagram-editor.js.flow +0 -26
  168. package/dist/widgets/sequence-editor.js.flow +0 -73
  169. package/dist/widgets/simple-markdown-tester-editor.js.flow +0 -23
  170. package/dist/widgets/simple-markdown-tester.js.flow +0 -61
  171. package/dist/widgets/simulator-editor.js.flow +0 -26
  172. package/dist/widgets/sorter-editor.js.flow +0 -22
  173. package/dist/widgets/table-editor.js.flow +0 -24
  174. package/dist/widgets/transformer-editor.js.flow +0 -17
  175. package/dist/widgets/unit-editor.js.flow +0 -41
  176. package/dist/widgets/video-editor.js.flow +0 -25
package/dist/es/index.js CHANGED
@@ -154,7 +154,7 @@ const JsonEditor = createReactClass({
154
154
  currentValue: nextString,
155
155
  valid: true
156
156
  }, function () {
157
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
157
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
158
158
  this.props.onChange(json);
159
159
  });
160
160
  } catch (ex) {
@@ -181,7 +181,7 @@ const JsonEditor = createReactClass({
181
181
  currentValue: JSON.stringify(json, null, 4),
182
182
  valid: true
183
183
  }, function () {
184
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
184
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
185
185
  this.props.onChange(json);
186
186
  });
187
187
  } catch (ex) {
@@ -20555,7 +20555,7 @@ const _upgradeWidgetInfo = props => {
20555
20555
  // We can't call serialize here because this.refs.widget
20556
20556
  // doesn't exist before this component is mounted.
20557
20557
  const filteredProps = _.omit(props, WIDGET_PROP_DENYLIST);
20558
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'PerseusWidget' is not assignable to type 'ReactElement<any, string | JSXElementConstructor<any>>'. | TS2345 - Argument of type 'Partial<{ id: string; onChange: (widgetInfo: PerseusWidget, cb?: (() => unknown) | undefined, silent?: boolean | undefined) => unknown; onRemove: () => unknown; apiOptions: any; } & CategorizerWidget & { ...; }> | ... 38 more ... | Partial<...>' is not assignable to parameter of type 'PerseusWidget'.
20558
+ // @ts-expect-error - TS2322 - Type 'PerseusWidget' is not assignable to type 'ReactElement<any, string | JSXElementConstructor<any>>'. | TS2345 - Argument of type 'Partial<{ id: string; onChange: (widgetInfo: PerseusWidget, cb?: (() => unknown) | undefined, silent?: boolean | undefined) => unknown; onRemove: () => unknown; apiOptions: any; } & CategorizerWidget & { ...; }> | ... 38 more ... | Partial<...>' is not assignable to parameter of type 'PerseusWidget'.
20559
20559
  return Widgets.upgradeWidgetInfoToLatestVersion(filteredProps);
20560
20560
  };
20561
20561
 
@@ -20577,7 +20577,7 @@ class WidgetEditor extends React.Component {
20577
20577
  const newWidgetInfo = Object.assign({}, this.state.widgetInfo);
20578
20578
  newWidgetInfo.options = Object.assign(
20579
20579
  // eslint-disable-next-line react/no-string-refs
20580
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
20580
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
20581
20581
  this.refs.widget.serialize(), newProps);
20582
20582
  this.props.onChange(newWidgetInfo, cb, silent);
20583
20583
  };
@@ -20596,7 +20596,7 @@ class WidgetEditor extends React.Component {
20596
20596
  };
20597
20597
  this.getSaveWarnings = () => {
20598
20598
  // eslint-disable-next-line react/no-string-refs
20599
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
20599
+ // @ts-expect-error - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
20600
20600
  const issuesFunc = this.refs.widget.getSaveWarnings;
20601
20601
  return issuesFunc ? issuesFunc() : [];
20602
20602
  };
@@ -20611,19 +20611,19 @@ class WidgetEditor extends React.Component {
20611
20611
  static: widgetInfo.static,
20612
20612
  graded: widgetInfo.graded,
20613
20613
  // eslint-disable-next-line react/no-string-refs
20614
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
20614
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
20615
20615
  options: this.refs.widget.serialize(),
20616
20616
  version: widgetInfo.version
20617
20617
  };
20618
20618
  };
20619
20619
  this.state = {
20620
20620
  showWidget: false,
20621
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'ReactElement<any, any> | null' is not assignable to type 'PerseusWidget'.
20621
+ // @ts-expect-error - TS2322 - Type 'ReactElement<any, any> | null' is not assignable to type 'PerseusWidget'.
20622
20622
  widgetInfo: _upgradeWidgetInfo(props)
20623
20623
  };
20624
20624
  }
20625
20625
  UNSAFE_componentWillReceiveProps(nextProps) {
20626
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'ReactElement<any, any> | null' is not assignable to type 'PerseusWidget'.
20626
+ // @ts-expect-error - TS2322 - Type 'ReactElement<any, any> | null' is not assignable to type 'PerseusWidget'.
20627
20627
  this.setState({
20628
20628
  widgetInfo: _upgradeWidgetInfo(nextProps)
20629
20629
  });
@@ -20655,7 +20655,7 @@ class WidgetEditor extends React.Component {
20655
20655
  onClick: this._toggleWidget
20656
20656
  }, this.props.id, this.state.showWidget ? /*#__PURE__*/React.createElement(InlineIcon$b, iconChevronDown$1) : /*#__PURE__*/React.createElement(InlineIcon$b, iconChevronRight)), supportsStaticMode && /*#__PURE__*/React.createElement("input", {
20657
20657
  type: "button"
20658
- // @ts-expect-error [FEI-5003] - TS2322 - Type '(e: Event) => void' is not assignable to type 'MouseEventHandler<HTMLInputElement>'.
20658
+ // @ts-expect-error - TS2322 - Type '(e: Event) => void' is not assignable to type 'MouseEventHandler<HTMLInputElement>'.
20659
20659
  ,
20660
20660
  onClick: this._toggleStatic,
20661
20661
  className: "simple-button--small",
@@ -20852,7 +20852,7 @@ const IMAGE_REGEX$1 = /!\[[^\]]*\]\(([^\s)]+)[^)]*\)/g;
20852
20852
  * ignores captures. If you don't need captures, use String::match
20853
20853
  */
20854
20854
  const allMatches = function allMatches(regex, str) {
20855
- // @ts-expect-error [FEI-5003] - TS2702 - 'RegExp' only refers to a type, but is being used as a namespace here.
20855
+ // @ts-expect-error - TS2702 - 'RegExp' only refers to a type, but is being used as a namespace here.
20856
20856
  const result = [];
20857
20857
  // eslint-disable-next-line no-constant-condition
20858
20858
  while (true) {
@@ -20887,12 +20887,12 @@ class Editor extends React.Component {
20887
20887
  return;
20888
20888
  }
20889
20889
  return /*#__PURE__*/React.createElement(WidgetEditor
20890
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'string' is not assignable to type 'number | undefined'.
20890
+ // @ts-expect-error - TS2322 - Type 'string' is not assignable to type 'number | undefined'.
20891
20891
  , _extends({
20892
20892
  key: id,
20893
20893
  ref: id,
20894
20894
  id: id
20895
- // @ts-expect-error [FEI-5003] - TS2783 - 'type' is specified more than once, so this usage will be overwritten.
20895
+ // @ts-expect-error - TS2783 - 'type' is specified more than once, so this usage will be overwritten.
20896
20896
  ,
20897
20897
  type: type
20898
20898
  // eslint-disable-next-line react/jsx-no-bind
@@ -20915,7 +20915,7 @@ class Editor extends React.Component {
20915
20915
  // eslint-disable-next-line react/no-string-refs
20916
20916
  const textarea = this.refs.textarea;
20917
20917
  const re = new RegExp(widgetRegExp.replace("{id}", id), "gm");
20918
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'value' does not exist on type 'ReactInstance'.
20918
+ // @ts-expect-error - TS2339 - Property 'value' does not exist on type 'ReactInstance'.
20919
20919
  this.props.onChange({
20920
20920
  content: textarea.value.replace(re, "")
20921
20921
  });
@@ -20951,7 +20951,7 @@ class Editor extends React.Component {
20951
20951
  props.onChange({
20952
20952
  images: _.clone(images)
20953
20953
  },
20954
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'null' is not assignable to parameter of type '(() => unknown) | undefined'.
20954
+ // @ts-expect-error - TS2345 - Argument of type 'null' is not assignable to parameter of type '(() => unknown) | undefined'.
20955
20955
  null,
20956
20956
  // callback
20957
20957
  true // silent
@@ -21025,13 +21025,13 @@ class Editor extends React.Component {
21025
21025
  content: content
21026
21026
  });
21027
21027
  }).each(fileAndSentinel => {
21028
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2345 - Argument of type 'File' is not assignable to parameter of type 'string'.
21028
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2345 - Argument of type 'File' is not assignable to parameter of type 'string'.
21029
21029
  imageUploader(fileAndSentinel.file, url => {
21030
21030
  // See componentDidUpdate() for how this flag is used
21031
21031
  this.lastUserValue = origContent;
21032
21032
  this.props.onChange({
21033
21033
  content: this.state.textAreaValue.replace(
21034
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'.
21034
+ // @ts-expect-error - TS2531 - Object is possibly 'null'.
21035
21035
  fileAndSentinel.sentinel, url)
21036
21036
  });
21037
21037
  });
@@ -21063,7 +21063,7 @@ class Editor extends React.Component {
21063
21063
  const textarea = ReactDOM.findDOMNode(this.refs.textarea);
21064
21064
 
21065
21065
  // findDOMNode can also return Text, but we know it's an element.
21066
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'Element | Text | null' is not assignable to parameter of type 'HTMLTextAreaElement'.
21066
+ // @ts-expect-error - TS2345 - Argument of type 'Element | Text | null' is not assignable to parameter of type 'HTMLTextAreaElement'.
21067
21067
  const word = Util.textarea.getWordBeforeCursor(textarea);
21068
21068
  const matches = word.string.toLowerCase().match(shortcutRegexp);
21069
21069
  if (matches != null) {
@@ -21089,9 +21089,9 @@ class Editor extends React.Component {
21089
21089
  const textarea = e.currentTarget;
21090
21090
  const selectedText = textarea.value.substring(textarea.selectionStart, textarea.selectionEnd);
21091
21091
  const widgetNames = _.map(
21092
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'RegExpMatchArray | null' is not assignable to parameter of type 'Collection<any>'.
21092
+ // @ts-expect-error - TS2345 - Argument of type 'RegExpMatchArray | null' is not assignable to parameter of type 'Collection<any>'.
21093
21093
  selectedText.match(rWidgetSplit), syntax => {
21094
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'.
21094
+ // @ts-expect-error - TS2531 - Object is possibly 'null'.
21095
21095
  return Util.rWidgetParts.exec(syntax)[1];
21096
21096
  });
21097
21097
  const widgetData = _.pick(this.serialize().widgets, widgetNames);
@@ -21109,7 +21109,7 @@ class Editor extends React.Component {
21109
21109
  const widgetJSON = localStorage.perseusLastCopiedWidgets;
21110
21110
  const lastCopiedText = localStorage.perseusLastCopiedText;
21111
21111
  const textToBePasted =
21112
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'originalEvent' does not exist on type 'SyntheticEvent<HTMLTextAreaElement, Event>'.
21112
+ // @ts-expect-error - TS2339 - Property 'originalEvent' does not exist on type 'SyntheticEvent<HTMLTextAreaElement, Event>'.
21113
21113
  e.originalEvent.clipboardData.getData("text");
21114
21114
 
21115
21115
  // Only intercept if we have widget data to paste and the user is
@@ -21136,9 +21136,9 @@ class Editor extends React.Component {
21136
21136
  // Use safe widget name map to construct new text
21137
21137
  const safeText = lastCopiedText.replace(rWidgetSplit, syntax => {
21138
21138
  const match = Util.rWidgetParts.exec(syntax);
21139
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'.
21139
+ // @ts-expect-error - TS2531 - Object is possibly 'null'.
21140
21140
  const completeWidget = match[0];
21141
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'.
21141
+ // @ts-expect-error - TS2531 - Object is possibly 'null'.
21142
21142
  const widget = match[1];
21143
21143
  return completeWidget.replace(widget, safeWidgetMapping[widget]);
21144
21144
  });
@@ -21203,12 +21203,12 @@ class Editor extends React.Component {
21203
21203
  // Note: we have to use _.map here instead of Array::map
21204
21204
  // because the results of a .match might be null if no
21205
21205
  // widgets were found.
21206
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'RegExpMatchArray | null' is not assignable to parameter of type 'Collection<any>'.
21206
+ // @ts-expect-error - TS2345 - Argument of type 'RegExpMatchArray | null' is not assignable to parameter of type 'Collection<any>'.
21207
21207
  const allWidgetIds = _.map(oldContent.match(rWidgetSplit), syntax => {
21208
21208
  const match = Util.rWidgetParts.exec(syntax);
21209
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'.
21209
+ // @ts-expect-error - TS2531 - Object is possibly 'null'.
21210
21210
  const type = match[2];
21211
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'.
21211
+ // @ts-expect-error - TS2531 - Object is possibly 'null'.
21212
21212
  const num = +match[3];
21213
21213
  return [type, num];
21214
21214
  });
@@ -21232,12 +21232,12 @@ class Editor extends React.Component {
21232
21232
  const newWidgets = _.clone(this.props.widgets);
21233
21233
  newWidgets[id] = {
21234
21234
  options: (_Widgets$getEditor = Widgets.getEditor(widgetType)) == null ? void 0 : _Widgets$getEditor.defaultProps,
21235
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'string' is not assignable to type '"video" | "image" | "iframe" | "table" | "radio" | "definition" | "group" | "matrix" | "categorizer" | "cs-program" | "dropdown" | "example-graphie-widget" | "example-widget" | ... 26 more ... | "unit-input"'.
21235
+ // @ts-expect-error - TS2322 - Type 'string' is not assignable to type '"video" | "image" | "iframe" | "table" | "radio" | "definition" | "group" | "matrix" | "categorizer" | "cs-program" | "dropdown" | "example-graphie-widget" | "example-widget" | ... 26 more ... | "unit-input"'.
21236
21236
  type: widgetType,
21237
21237
  // Track widget version on creation, so that a widget editor
21238
21238
  // without a valid version prop can only possibly refer to a
21239
21239
  // pre-versioning creation time.
21240
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'Version | null | undefined' is not assignable to type 'Version | undefined'.
21240
+ // @ts-expect-error - TS2322 - Type 'Version | null | undefined' is not assignable to type 'Version | undefined'.
21241
21241
  version: Widgets.getVersion(widgetType)
21242
21242
  };
21243
21243
 
@@ -21249,7 +21249,7 @@ class Editor extends React.Component {
21249
21249
  }, function () {
21250
21250
  Util.textarea.moveCursor(
21251
21251
  // findDOMNode can return Text but we know this is Element
21252
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'Element | Text | null' is not assignable to parameter of type 'HTMLTextAreaElement'.
21252
+ // @ts-expect-error - TS2345 - Argument of type 'Element | Text | null' is not assignable to parameter of type 'HTMLTextAreaElement'.
21253
21253
  textarea,
21254
21254
  // We want to put the cursor after the widget
21255
21255
  // and after any added newlines
@@ -21260,9 +21260,9 @@ class Editor extends React.Component {
21260
21260
  // eslint-disable-next-line react/no-string-refs
21261
21261
  const textarea = this.refs.textarea;
21262
21262
  this._addWidgetToContent(this.props.content,
21263
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'selectionStart' does not exist on type 'ReactInstance'. | TS2339 - Property 'selectionEnd' does not exist on type 'ReactInstance'.
21263
+ // @ts-expect-error - TS2339 - Property 'selectionStart' does not exist on type 'ReactInstance'. | TS2339 - Property 'selectionEnd' does not exist on type 'ReactInstance'.
21264
21264
  [textarea.selectionStart, textarea.selectionEnd], widgetType);
21265
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
21265
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
21266
21266
  textarea.focus();
21267
21267
  };
21268
21268
  this.addTemplate = e => {
@@ -21308,7 +21308,7 @@ class Editor extends React.Component {
21308
21308
  const widgetIds = _.intersection(this.widgetIds, _.keys(this.refs));
21309
21309
  const warnings = _(widgetIds).chain().map(id => {
21310
21310
  // eslint-disable-next-line react/no-string-refs
21311
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
21311
+ // @ts-expect-error - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
21312
21312
  const issuesFunc = this.refs[id].getSaveWarnings;
21313
21313
  const issues = issuesFunc ? issuesFunc() : [];
21314
21314
  return _.map(issues, issue => id + ": " + issue);
@@ -21324,7 +21324,7 @@ class Editor extends React.Component {
21324
21324
  * textarea should be refined with an instanceof check to
21325
21325
  * HTMLTextAreaElement so that these props are available.
21326
21326
  */
21327
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'Element | Text'.
21327
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'Element | Text'.
21328
21328
  textarea.focus();
21329
21329
  }
21330
21330
  };
@@ -21338,9 +21338,9 @@ class Editor extends React.Component {
21338
21338
  * textarea should be refined with an instanceof check to
21339
21339
  * HTMLTextAreaElement so that these props are available.
21340
21340
  */
21341
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'selectionStart' does not exist on type 'Element | Text'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
21341
+ // @ts-expect-error - TS2339 - Property 'selectionStart' does not exist on type 'Element | Text'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
21342
21342
  textarea.selectionStart = textarea.value.length;
21343
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'selectionEnd' does not exist on type 'Element | Text'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
21343
+ // @ts-expect-error - TS2339 - Property 'selectionEnd' does not exist on type 'Element | Text'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
21344
21344
  textarea.selectionEnd = textarea.value.length;
21345
21345
  }
21346
21346
  };
@@ -21353,7 +21353,7 @@ class Editor extends React.Component {
21353
21353
  const widgetIds = _.intersection(this.widgetIds, _.keys(this.refs));
21354
21354
  _.each(widgetIds, id => {
21355
21355
  // eslint-disable-next-line react/no-string-refs
21356
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
21356
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
21357
21357
  widgets[id] = this.refs[id].serialize();
21358
21358
  });
21359
21359
 
@@ -21387,9 +21387,9 @@ class Editor extends React.Component {
21387
21387
  // setState
21388
21388
  this._sizeImages(this.props);
21389
21389
  // eslint-disable-next-line react/no-string-refs
21390
- // @ts-expect-error [FEI-5003] - TS2769 - No overload matches this call.
21390
+ // @ts-expect-error - TS2769 - No overload matches this call.
21391
21391
  $(ReactDOM.findDOMNode(this.refs.textarea))
21392
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'on' does not exist on type 'JQueryStatic'.
21392
+ // @ts-expect-error - TS2339 - Property 'on' does not exist on type 'JQueryStatic'.
21393
21393
  .on("copy cut", this._maybeCopyWidgets).on("paste", this._maybePasteWidgets);
21394
21394
  }
21395
21395
 
@@ -21419,18 +21419,18 @@ class Editor extends React.Component {
21419
21419
  * textarea should be refined with an instanceof check to
21420
21420
  * HTMLTextAreaElement so that these props are available.
21421
21421
  */
21422
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'Element | Text'.
21422
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'Element | Text'.
21423
21423
  textarea.focus();
21424
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'value' does not exist on type 'Element | Text'.
21424
+ // @ts-expect-error - TS2339 - Property 'value' does not exist on type 'Element | Text'.
21425
21425
  textarea.value = this.lastUserValue;
21426
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'selectionStart' does not exist on type 'Element | Text'.
21426
+ // @ts-expect-error - TS2339 - Property 'selectionStart' does not exist on type 'Element | Text'.
21427
21427
  textarea.selectionStart = 0;
21428
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'select' does not exist on type 'Element | Text'.
21428
+ // @ts-expect-error - TS2339 - Property 'select' does not exist on type 'Element | Text'.
21429
21429
  textarea.select(0, prevProps.content.length);
21430
21430
  if (document.execCommand("insertText", false, this.props.content) === false) {
21431
21431
  // This command is not implemented. Fall back to setting `value`
21432
21432
  // directly.
21433
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'value' does not exist on type 'Element | Text'.
21433
+ // @ts-expect-error - TS2339 - Property 'value' does not exist on type 'Element | Text'.
21434
21434
  textarea.value = this.props.content;
21435
21435
  }
21436
21436
  this.lastUserValue = null;
@@ -21473,7 +21473,7 @@ class Editor extends React.Component {
21473
21473
  // Normal text
21474
21474
  underlayPieces.push(pieces[i]);
21475
21475
 
21476
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 2 arguments, but got 1.
21476
+ // @ts-expect-error - TS2554 - Expected 2 arguments, but got 1.
21477
21477
  const ast = PerseusMarkdown.parse(pieces[i]);
21478
21478
  PerseusMarkdown.traverseContent(ast, node => {
21479
21479
  if (node.type === "math" || node.type === "blockMath") {
@@ -21485,7 +21485,7 @@ class Editor extends React.Component {
21485
21485
  } catch (e) {
21486
21486
  katexErrorList.push({
21487
21487
  math: content,
21488
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'any' is not assignable to type 'never'.
21488
+ // @ts-expect-error - TS2322 - Type 'any' is not assignable to type 'never'.
21489
21489
  message: e.message
21490
21490
  });
21491
21491
  }
@@ -21537,7 +21537,7 @@ class Editor extends React.Component {
21537
21537
  const insertTemplateString = "Insert template\u2026";
21538
21538
  templatesDropDown =
21539
21539
  /*#__PURE__*/
21540
- // @ts-expect-error [FEI-5003] - TS2322 - Type '(e: SyntheticEvent<HTMLTextAreaElement, Event>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
21540
+ // @ts-expect-error - TS2322 - Type '(e: SyntheticEvent<HTMLTextAreaElement, Event>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
21541
21541
  React.createElement("select", {
21542
21542
  onChange: this.addTemplate
21543
21543
  }, /*#__PURE__*/React.createElement("option", {
@@ -21651,7 +21651,7 @@ Editor.defaultProps = {
21651
21651
  let nextIframeID = 0;
21652
21652
  const requestIframeData = {};
21653
21653
  const updateIframeHeight = {};
21654
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'iframeDataStore' does not exist on type 'Window & typeof globalThis'.
21654
+ // @ts-expect-error - TS2339 - Property 'iframeDataStore' does not exist on type 'Window & typeof globalThis'.
21655
21655
  window.iframeDataStore = {};
21656
21656
 
21657
21657
  // This is called once after Perseus is loaded and the iframe
@@ -21705,7 +21705,7 @@ class IframeContentRenderer extends React.Component {
21705
21705
  this._lastHeight = height;
21706
21706
  if (this._isMounted && this.props.seamless) {
21707
21707
  // eslint-disable-next-line react/no-string-refs
21708
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'style' does not exist on type 'ReactInstance'.
21708
+ // @ts-expect-error - TS2339 - Property 'style' does not exist on type 'ReactInstance'.
21709
21709
  this.refs.container.style.height = height + "px";
21710
21710
  }
21711
21711
  };
@@ -21716,11 +21716,11 @@ class IframeContentRenderer extends React.Component {
21716
21716
  componentDidUpdate(prevProps) {
21717
21717
  if (!this.props.seamless) {
21718
21718
  // eslint-disable-next-line react/no-string-refs
21719
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'style' does not exist on type 'ReactInstance'.
21719
+ // @ts-expect-error - TS2339 - Property 'style' does not exist on type 'ReactInstance'.
21720
21720
  this.refs.container.style.height = "100%";
21721
21721
  } else {
21722
21722
  // eslint-disable-next-line react/no-string-refs
21723
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'style' does not exist on type 'ReactInstance'.
21723
+ // @ts-expect-error - TS2339 - Property 'style' does not exist on type 'ReactInstance'.
21724
21724
  this.refs.container.style.height = this._lastHeight + "px";
21725
21725
  }
21726
21726
  if (prevProps.datasetValue !== this.props.datasetValue) {
@@ -21737,7 +21737,7 @@ class IframeContentRenderer extends React.Component {
21737
21737
  // Don't initialize the iframe until the page has loaded
21738
21738
  if (this._frame) {
21739
21739
  // eslint-disable-next-line react/no-string-refs
21740
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'removeChild' does not exist on type 'ReactInstance'.
21740
+ // @ts-expect-error - TS2339 - Property 'removeChild' does not exist on type 'ReactInstance'.
21741
21741
  this.refs.container.removeChild(this._frame);
21742
21742
  }
21743
21743
  const frame = document.createElement("iframe");
@@ -21762,7 +21762,7 @@ class IframeContentRenderer extends React.Component {
21762
21762
  }
21763
21763
 
21764
21764
  // eslint-disable-next-line react/no-string-refs
21765
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'appendChild' does not exist on type 'ReactInstance'.
21765
+ // @ts-expect-error - TS2339 - Property 'appendChild' does not exist on type 'ReactInstance'.
21766
21766
  this.refs.container.appendChild(frame);
21767
21767
  this._frame = frame;
21768
21768
  }
@@ -21774,7 +21774,7 @@ class IframeContentRenderer extends React.Component {
21774
21774
  // We can't use JSON.stringify/parse for this because the apiOptions
21775
21775
  // includes the functions GroupMetadataEditor, groupAnnotator,
21776
21776
  // onFocusChange, and onInputError.
21777
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'iframeDataStore' does not exist on type 'Window & typeof globalThis'.
21777
+ // @ts-expect-error - TS2339 - Property 'iframeDataStore' does not exist on type 'Window & typeof globalThis'.
21778
21778
  window.iframeDataStore[this.iframeID] = data;
21779
21779
  frame.contentWindow.postMessage(this.iframeID, "*");
21780
21780
  }
@@ -21814,7 +21814,7 @@ class ArticleEditor extends React.Component {
21814
21814
  };
21815
21815
  this._handleEditorChange = (i, newProps) => {
21816
21816
  const sections = _.clone(this._sections());
21817
- // @ts-expect-error [FEI-5003] - TS2542 - Index signature in type 'readonly RendererProps[]' only permits reading.
21817
+ // @ts-expect-error - TS2542 - Index signature in type 'readonly RendererProps[]' only permits reading.
21818
21818
  sections[i] = _.extend({}, sections[i], newProps);
21819
21819
  this.props.onChange({
21820
21820
  json: sections
@@ -21830,7 +21830,7 @@ class ArticleEditor extends React.Component {
21830
21830
  _updatePreviewFrames() {
21831
21831
  if (this.props.mode === "preview") {
21832
21832
  // eslint-disable-next-line react/no-string-refs
21833
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'sendNewData' does not exist on type 'ReactInstance'.
21833
+ // @ts-expect-error - TS2339 - Property 'sendNewData' does not exist on type 'ReactInstance'.
21834
21834
  this.refs["frame-all"].sendNewData({
21835
21835
  type: "article-all",
21836
21836
  data: this._sections().map((section, i) => {
@@ -21840,7 +21840,7 @@ class ArticleEditor extends React.Component {
21840
21840
  } else if (this.props.mode === "edit") {
21841
21841
  this._sections().forEach((section, i) => {
21842
21842
  // eslint-disable-next-line react/no-string-refs
21843
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'sendNewData' does not exist on type 'ReactInstance'.
21843
+ // @ts-expect-error - TS2339 - Property 'sendNewData' does not exist on type 'ReactInstance'.
21844
21844
  this.refs["frame-" + i].sendNewData({
21845
21845
  type: "article",
21846
21846
  data: this._apiOptionsForSection(section, i)
@@ -21865,7 +21865,7 @@ class ArticleEditor extends React.Component {
21865
21865
  highlightLint: this.state.highlightLint,
21866
21866
  paths: this.props.contentPaths
21867
21867
  },
21868
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
21868
+ // @ts-expect-error - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
21869
21869
  legacyPerseusLint: editor ? editor.getSaveWarnings() : []
21870
21870
  };
21871
21871
  }
@@ -21990,9 +21990,9 @@ class ArticleEditor extends React.Component {
21990
21990
  }
21991
21991
  const sections = _.clone(this._sections());
21992
21992
  const section = sections[i];
21993
- // @ts-expect-error [FEI-5003] - TS2551 - Property 'splice' does not exist on type 'readonly RendererProps[]'. Did you mean 'slice'?
21993
+ // @ts-expect-error - TS2551 - Property 'splice' does not exist on type 'readonly RendererProps[]'. Did you mean 'slice'?
21994
21994
  sections.splice(i, 1);
21995
- // @ts-expect-error [FEI-5003] - TS2551 - Property 'splice' does not exist on type 'readonly RendererProps[]'. Did you mean 'slice'?
21995
+ // @ts-expect-error - TS2551 - Property 'splice' does not exist on type 'readonly RendererProps[]'. Did you mean 'slice'?
21996
21996
  sections.splice(i - 1, 0, section);
21997
21997
  this.props.onChange({
21998
21998
  json: sections
@@ -22004,9 +22004,9 @@ class ArticleEditor extends React.Component {
22004
22004
  return;
22005
22005
  }
22006
22006
  const section = sections[i];
22007
- // @ts-expect-error [FEI-5003] - TS2551 - Property 'splice' does not exist on type 'readonly RendererProps[]'. Did you mean 'slice'?
22007
+ // @ts-expect-error - TS2551 - Property 'splice' does not exist on type 'readonly RendererProps[]'. Did you mean 'slice'?
22008
22008
  sections.splice(i, 1);
22009
- // @ts-expect-error [FEI-5003] - TS2551 - Property 'splice' does not exist on type 'readonly RendererProps[]'. Did you mean 'slice'?
22009
+ // @ts-expect-error - TS2551 - Property 'splice' does not exist on type 'readonly RendererProps[]'. Did you mean 'slice'?
22010
22010
  sections.splice(i + 1, 0, section);
22011
22011
  this.props.onChange({
22012
22012
  json: sections
@@ -22025,7 +22025,7 @@ class ArticleEditor extends React.Component {
22025
22025
  const newSection = i >= 0 ? {
22026
22026
  widgets: sections[i].widgets
22027
22027
  } : {};
22028
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'splice' does not exist on type 'JsonType'.
22028
+ // @ts-expect-error - TS2339 - Property 'splice' does not exist on type 'JsonType'.
22029
22029
  sections.splice(i + 1, 0, newSection);
22030
22030
  this.props.onChange({
22031
22031
  json: sections
@@ -22033,7 +22033,7 @@ class ArticleEditor extends React.Component {
22033
22033
  }
22034
22034
  _handleRemoveSection(i) {
22035
22035
  const sections = _.clone(this._sections());
22036
- // @ts-expect-error [FEI-5003] - TS2551 - Property 'splice' does not exist on type 'readonly RendererProps[]'. Did you mean 'slice'?
22036
+ // @ts-expect-error - TS2551 - Property 'splice' does not exist on type 'readonly RendererProps[]'. Did you mean 'slice'?
22037
22037
  sections.splice(i, 1);
22038
22038
  this.props.onChange({
22039
22039
  json: sections
@@ -22043,7 +22043,7 @@ class ArticleEditor extends React.Component {
22043
22043
  if (this.props.mode === "edit") {
22044
22044
  return this._sections().map((section, i) => {
22045
22045
  // eslint-disable-next-line react/no-string-refs
22046
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
22046
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
22047
22047
  return this.refs["editor" + i].serialize();
22048
22048
  });
22049
22049
  }
@@ -22067,7 +22067,7 @@ class ArticleEditor extends React.Component {
22067
22067
  }
22068
22068
  return this._sections().map((section, i) => {
22069
22069
  // eslint-disable-next-line react/no-string-refs
22070
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
22070
+ // @ts-expect-error - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
22071
22071
  return this.refs["editor" + i].getSaveWarnings();
22072
22072
  });
22073
22073
  }
@@ -22575,7 +22575,7 @@ const splitDiff = function splitDiff(diffEntries) {
22575
22575
  _.each(values, (value, i) => {
22576
22576
  const isNewline = i > 0;
22577
22577
  if (isNewline) {
22578
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'any[]' is not assignable to parameter of type 'never'.
22578
+ // @ts-expect-error - TS2345 - Argument of type 'any[]' is not assignable to parameter of type 'never'.
22579
22579
  lines.push(currentLine);
22580
22580
  currentLine = [];
22581
22581
  }
@@ -22586,7 +22586,7 @@ const splitDiff = function splitDiff(diffEntries) {
22586
22586
  });
22587
22587
  });
22588
22588
  if (currentLine.length) {
22589
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'any[]' is not assignable to parameter of type 'never'.
22589
+ // @ts-expect-error - TS2345 - Argument of type 'any[]' is not assignable to parameter of type 'never'.
22590
22590
  lines.push(currentLine);
22591
22591
  }
22592
22592
  return lines;
@@ -23096,16 +23096,16 @@ const filterWidgetInfo = function filterWidgetInfo(widgetInfo, showAlignmentOpti
23096
23096
 
23097
23097
  // Show alignment options iff multiple valid ones exist for this widget
23098
23098
  if (showAlignmentOptions && Widgets.getSupportedAlignments(type).length > 1) {
23099
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'alignment' does not exist on type '{ readonly options: any; }'.
23099
+ // @ts-expect-error - TS2339 - Property 'alignment' does not exist on type '{ readonly options: any; }'.
23100
23100
  filteredWidgetInfo.alignment = alignment;
23101
23101
  }
23102
23102
  if (type === "transformer") {
23103
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'graded' does not exist on type '{ readonly options: any; }'.
23103
+ // @ts-expect-error - TS2339 - Property 'graded' does not exist on type '{ readonly options: any; }'.
23104
23104
  filteredWidgetInfo.graded = graded;
23105
23105
  }
23106
23106
  if (Widgets.supportsStaticMode(type)) {
23107
23107
  var _widgetInfo$static;
23108
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'static' does not exist on type '{ readonly options: any; }'.
23108
+ // @ts-expect-error - TS2339 - Property 'static' does not exist on type '{ readonly options: any; }'.
23109
23109
  filteredWidgetInfo.static = (_widgetInfo$static = widgetInfo == null ? void 0 : widgetInfo.static) != null ? _widgetInfo$static : undefined;
23110
23110
  }
23111
23111
  return filteredWidgetInfo;
@@ -23336,10 +23336,10 @@ function getTitle(path) {
23336
23336
  const title = [];
23337
23337
  for (let i = 0; i < path.length; i++) {
23338
23338
  if (typeof path[i] === "number") {
23339
- // @ts-expect-error [FEI-5003] - TS2365 - Operator '+' cannot be applied to types 'string | number' and 'number'.
23339
+ // @ts-expect-error - TS2365 - Operator '+' cannot be applied to types 'string | number' and 'number'.
23340
23340
  title.push((path[i] + 1).toString() + ":");
23341
23341
  } else {
23342
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'string | number' is not assignable to parameter of type 'string'.
23342
+ // @ts-expect-error - TS2345 - Argument of type 'string | number' is not assignable to parameter of type 'string'.
23343
23343
  title.push(path[i]);
23344
23344
  }
23345
23345
  }
@@ -23399,11 +23399,11 @@ class StructuredItemDiff extends React.Component {
23399
23399
  const afterList = [];
23400
23400
  buildMapper().setContentMapper((c, _, p) => beforeList.push([c, p])).setHintMapper((c, _, p) => beforeList.push([c, p])).setTagsMapper((c, _, p) => beforeList.push([c, p])).mapTree(itemToTree(before), shape);
23401
23401
  buildMapper()
23402
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'unknown' is not assignable to type 'never'. | TS2322 - Type 'Path' is not assignable to type 'never'.
23402
+ // @ts-expect-error - TS2322 - Type 'unknown' is not assignable to type 'never'. | TS2322 - Type 'Path' is not assignable to type 'never'.
23403
23403
  .setContentMapper((c, _, p) => afterList.push([c, p]))
23404
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'unknown' is not assignable to type 'never'. | TS2322 - Type 'Path' is not assignable to type 'never'.
23404
+ // @ts-expect-error - TS2322 - Type 'unknown' is not assignable to type 'never'. | TS2322 - Type 'Path' is not assignable to type 'never'.
23405
23405
  .setHintMapper((c, _, p) => afterList.push([c, p]))
23406
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'unknown' is not assignable to type 'never'. | TS2322 - Type 'Path' is not assignable to type 'never'.
23406
+ // @ts-expect-error - TS2322 - Type 'unknown' is not assignable to type 'never'. | TS2322 - Type 'Path' is not assignable to type 'never'.
23407
23407
  .setTagsMapper((c, _, p) => afterList.push([c, p])).mapTree(itemToTree(after), shape);
23408
23408
 
23409
23409
  // These are used in generateCompletePathsList()
@@ -23427,7 +23427,7 @@ class StructuredItemDiff extends React.Component {
23427
23427
  before = [[], path];
23428
23428
  }
23429
23429
  if (!after) {
23430
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'Path[]' is not assignable to type 'undefined'.
23430
+ // @ts-expect-error - TS2322 - Type 'Path[]' is not assignable to type 'undefined'.
23431
23431
  after = [[], path];
23432
23432
  }
23433
23433
  const beforeTags = [];
@@ -23439,9 +23439,9 @@ class StructuredItemDiff extends React.Component {
23439
23439
  });
23440
23440
  }
23441
23441
  const afterTags = [];
23442
- // @ts-expect-error [FEI-5003] - TS2532 - Object is possibly 'undefined'.
23442
+ // @ts-expect-error - TS2532 - Object is possibly 'undefined'.
23443
23443
  if (Array.isArray(after[0])) {
23444
- // @ts-expect-error [FEI-5003] - TS2532 - Object is possibly 'undefined'.
23444
+ // @ts-expect-error - TS2532 - Object is possibly 'undefined'.
23445
23445
  after[0].forEach(tagId => {
23446
23446
  if (typeof tagId === "string") {
23447
23447
  afterTags.push(tags.idToName(tagId));
@@ -23464,12 +23464,12 @@ class StructuredItemDiff extends React.Component {
23464
23464
  before = [buildEmptyItemTreeForShape(shapes.content), path];
23465
23465
  }
23466
23466
  if (!after) {
23467
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'any[]' is not assignable to type 'undefined'.
23467
+ // @ts-expect-error - TS2322 - Type 'any[]' is not assignable to type 'undefined'.
23468
23468
  after = [buildEmptyItemTreeForShape(shapes.content), path];
23469
23469
  }
23470
23470
  return /*#__PURE__*/React.createElement(RendererDiff, {
23471
23471
  before: before[0]
23472
- // @ts-expect-error [FEI-5003] - TS2532 - Object is possibly 'undefined'.
23472
+ // @ts-expect-error - TS2532 - Object is possibly 'undefined'.
23473
23473
  ,
23474
23474
  after: after[0],
23475
23475
  title: currentTitle,
@@ -23513,17 +23513,17 @@ class HintEditor extends React.Component {
23513
23513
  };
23514
23514
  this.focus = () => {
23515
23515
  // eslint-disable-next-line react/no-string-refs
23516
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
23516
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
23517
23517
  this.refs.editor.focus();
23518
23518
  };
23519
23519
  this.getSaveWarnings = () => {
23520
23520
  // eslint-disable-next-line react/no-string-refs
23521
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
23521
+ // @ts-expect-error - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
23522
23522
  return this.refs.editor.getSaveWarnings();
23523
23523
  };
23524
23524
  this.serialize = options => {
23525
23525
  // eslint-disable-next-line react/no-string-refs
23526
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
23526
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
23527
23527
  return this.refs.editor.serialize(options);
23528
23528
  };
23529
23529
  }
@@ -23564,7 +23564,7 @@ class HintEditor extends React.Component {
23564
23564
  onClick: _.partial(this.props.onMove, -1)
23565
23565
  }, /*#__PURE__*/React.createElement(InlineIcon$8, iconCircleArrowUp$1)), " ", this.props.isLast && /*#__PURE__*/React.createElement(InfoTip$n, null, /*#__PURE__*/React.createElement("p", null, "The last hint is automatically bolded."))), /*#__PURE__*/React.createElement("input", {
23566
23566
  type: "checkbox"
23567
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'boolean | null | undefined' is not assignable to type 'boolean | undefined'.
23567
+ // @ts-expect-error - TS2322 - Type 'boolean | null | undefined' is not assignable to type 'boolean | undefined'.
23568
23568
  ,
23569
23569
  checked: this.props.replace,
23570
23570
  onChange: this.handleChange
@@ -23591,7 +23591,7 @@ class CombinedHintEditor extends React.Component {
23591
23591
  const shouldBold = this.props.isLast && !/\*\*/.test(this.props.hint.content);
23592
23592
 
23593
23593
  // eslint-disable-next-line react/no-string-refs
23594
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'sendNewData' does not exist on type 'ReactInstance'.
23594
+ // @ts-expect-error - TS2339 - Property 'sendNewData' does not exist on type 'ReactInstance'.
23595
23595
  this.refs.frame.sendNewData({
23596
23596
  type: "hint",
23597
23597
  data: {
@@ -23609,17 +23609,17 @@ class CombinedHintEditor extends React.Component {
23609
23609
  };
23610
23610
  this.getSaveWarnings = () => {
23611
23611
  // eslint-disable-next-line react/no-string-refs
23612
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
23612
+ // @ts-expect-error - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
23613
23613
  return this.refs.editor.getSaveWarnings();
23614
23614
  };
23615
23615
  this.serialize = options => {
23616
23616
  // eslint-disable-next-line react/no-string-refs
23617
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
23617
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
23618
23618
  return this.refs.editor.serialize(options);
23619
23619
  };
23620
23620
  this.focus = () => {
23621
23621
  // eslint-disable-next-line react/no-string-refs
23622
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
23622
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
23623
23623
  this.refs.editor.focus();
23624
23624
  };
23625
23625
  }
@@ -23687,38 +23687,38 @@ class CombinedHintsEditor extends React.Component {
23687
23687
  keepDeletedWidgets: true
23688
23688
  }), newProps);
23689
23689
 
23690
- // @ts-expect-error [FEI-5003] - TS2740 - Type 'Hint' is missing the following properties from type 'readonly Hint[]': length, concat, join, slice, and 18 more.
23690
+ // @ts-expect-error - TS2740 - Type 'Hint' is missing the following properties from type 'readonly Hint[]': length, concat, join, slice, and 18 more.
23691
23691
  this.props.onChange({
23692
23692
  hints: hints
23693
23693
  }, cb, silent);
23694
23694
  };
23695
23695
  this.handleHintRemove = i => {
23696
23696
  const hints = _(this.props.hints).clone();
23697
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'splice' does not exist on type 'Hint'.
23697
+ // @ts-expect-error - TS2339 - Property 'splice' does not exist on type 'Hint'.
23698
23698
  hints.splice(i, 1);
23699
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'Hint' is not assignable to type 'readonly Hint[]'.
23699
+ // @ts-expect-error - TS2322 - Type 'Hint' is not assignable to type 'readonly Hint[]'.
23700
23700
  this.props.onChange({
23701
23701
  hints: hints
23702
23702
  });
23703
23703
  };
23704
23704
  this.handleHintMove = (i, dir) => {
23705
23705
  const hints = _(this.props.hints).clone();
23706
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'splice' does not exist on type 'Hint'.
23706
+ // @ts-expect-error - TS2339 - Property 'splice' does not exist on type 'Hint'.
23707
23707
  const hint = hints.splice(i, 1)[0];
23708
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'splice' does not exist on type 'Hint'.
23708
+ // @ts-expect-error - TS2339 - Property 'splice' does not exist on type 'Hint'.
23709
23709
  hints.splice(i + dir, 0, hint);
23710
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'Hint' is not assignable to type 'readonly Hint[]'.
23710
+ // @ts-expect-error - TS2322 - Type 'Hint' is not assignable to type 'readonly Hint[]'.
23711
23711
  this.props.onChange({
23712
23712
  hints: hints
23713
23713
  }, () => {
23714
23714
  // eslint-disable-next-line react/no-string-refs
23715
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
23715
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
23716
23716
  this.refs["hintEditor" + (i + dir)].focus();
23717
23717
  });
23718
23718
  };
23719
23719
  this.addHint = () => {
23720
23720
  const hints = _(this.props.hints).clone()
23721
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'concat' does not exist on type 'Hint'.
23721
+ // @ts-expect-error - TS2339 - Property 'concat' does not exist on type 'Hint'.
23722
23722
  .concat([{
23723
23723
  content: ""
23724
23724
  }]);
@@ -23727,7 +23727,7 @@ class CombinedHintsEditor extends React.Component {
23727
23727
  }, () => {
23728
23728
  const i = hints.length - 1;
23729
23729
  // eslint-disable-next-line react/no-string-refs
23730
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
23730
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
23731
23731
  this.refs["hintEditor" + i].focus();
23732
23732
  });
23733
23733
  };
@@ -23735,7 +23735,7 @@ class CombinedHintsEditor extends React.Component {
23735
23735
  return _.chain(this.props.hints).map((hint, i) => {
23736
23736
  return _.map(
23737
23737
  // eslint-disable-next-line react/no-string-refs
23738
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
23738
+ // @ts-expect-error - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
23739
23739
  this.refs["hintEditor" + i].getSaveWarnings(), issue => "Hint " + (i + 1) + ": " + issue);
23740
23740
  }).flatten(true).value();
23741
23741
  };
@@ -23746,7 +23746,7 @@ class CombinedHintsEditor extends React.Component {
23746
23746
  };
23747
23747
  this.serializeHint = (index, options) => {
23748
23748
  // eslint-disable-next-line react/no-string-refs
23749
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
23749
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
23750
23750
  return this.refs["hintEditor" + index].serialize(options);
23751
23751
  };
23752
23752
  }
@@ -23764,31 +23764,31 @@ class CombinedHintsEditor extends React.Component {
23764
23764
  itemId: itemId,
23765
23765
  hint: hint,
23766
23766
  pos: i
23767
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23767
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23768
23768
  ,
23769
23769
  imageUploader: this.props.imageUploader
23770
23770
  // eslint-disable-next-line react/jsx-no-bind
23771
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23771
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23772
23772
  ,
23773
23773
  onChange: this.handleHintChange.bind(this, i)
23774
23774
  // eslint-disable-next-line react/jsx-no-bind
23775
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23775
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23776
23776
  ,
23777
23777
  onRemove: this.handleHintRemove.bind(this, i)
23778
23778
  // eslint-disable-next-line react/jsx-no-bind
23779
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23779
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23780
23780
  ,
23781
23781
  onMove: this.handleHintMove.bind(this, i)
23782
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23782
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23783
23783
  ,
23784
23784
  deviceType: this.props.deviceType
23785
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23785
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23786
23786
  ,
23787
23787
  apiOptions: this.props.apiOptions
23788
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23788
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23789
23789
  ,
23790
23790
  highlightLint: this.props.highlightLint
23791
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23791
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
23792
23792
  ,
23793
23793
  previewURL: this.props.previewURL
23794
23794
  // TODO(CP-4838): what should be passed here?
@@ -23907,7 +23907,7 @@ class ItemEditor extends React.Component {
23907
23907
  };
23908
23908
  this.triggerPreviewUpdate = newData => {
23909
23909
  // eslint-disable-next-line react/no-string-refs
23910
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'sendNewData' does not exist on type 'ReactInstance'.
23910
+ // @ts-expect-error - TS2339 - Property 'sendNewData' does not exist on type 'ReactInstance'.
23911
23911
  this.refs.frame.sendNewData(newData);
23912
23912
  };
23913
23913
  this.handleEditorChange = (newProps, cb, silent) => {
@@ -23924,16 +23924,16 @@ class ItemEditor extends React.Component {
23924
23924
  };
23925
23925
  this.getSaveWarnings = () => {
23926
23926
  // eslint-disable-next-line react/no-string-refs
23927
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
23927
+ // @ts-expect-error - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
23928
23928
  return this.refs.questionEditor.getSaveWarnings();
23929
23929
  };
23930
23930
  this.serialize = options => {
23931
23931
  return {
23932
23932
  // eslint-disable-next-line react/no-string-refs
23933
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
23933
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
23934
23934
  question: this.refs.questionEditor.serialize(options),
23935
23935
  // eslint-disable-next-line react/no-string-refs
23936
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
23936
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
23937
23937
  answerArea: this.refs.itemExtrasEditor.serialize(options),
23938
23938
  itemDataVersion: ITEM_DATA_VERSION
23939
23939
  };
@@ -24015,7 +24015,7 @@ const {
24015
24015
  HUD
24016
24016
  } = components;
24017
24017
  class EditorPage extends React.Component {
24018
- // @ts-expect-error [FEI-5003] - TS2564 - Property 'rendererMountNode' has no initializer and is not definitely assigned in the constructor.
24018
+ // @ts-expect-error - TS2564 - Property 'rendererMountNode' has no initializer and is not definitely assigned in the constructor.
24019
24019
 
24020
24020
  constructor(props) {
24021
24021
  super(props);
@@ -24045,7 +24045,7 @@ class EditorPage extends React.Component {
24045
24045
  this.props.onChange(newJson);
24046
24046
  };
24047
24047
  this.state = {
24048
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'Pick<Readonly<Props> & Readonly<{ children?: ReactNode; }>, "hints" | "question" | "answerArea" | "itemDataVersion">' is not assignable to type 'PerseusJson'.
24048
+ // @ts-expect-error - TS2322 - Type 'Pick<Readonly<Props> & Readonly<{ children?: ReactNode; }>, "hints" | "question" | "answerArea" | "itemDataVersion">' is not assignable to type 'PerseusJson'.
24049
24049
  json: _.pick(this.props, "question", "answerArea", "hints", "itemDataVersion"),
24050
24050
  gradeMessage: "",
24051
24051
  wasAnswered: false,
@@ -24090,7 +24090,7 @@ class EditorPage extends React.Component {
24090
24090
  });
24091
24091
 
24092
24092
  // eslint-disable-next-line react/no-string-refs
24093
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'triggerPreviewUpdate' does not exist on type 'ReactInstance'.
24093
+ // @ts-expect-error - TS2339 - Property 'triggerPreviewUpdate' does not exist on type 'ReactInstance'.
24094
24094
  this.refs.itemEditor.triggerPreviewUpdate({
24095
24095
  type: "question",
24096
24096
  data: _({
@@ -24106,7 +24106,7 @@ class EditorPage extends React.Component {
24106
24106
  },
24107
24107
  reviewMode: true,
24108
24108
  // eslint-disable-next-line react/no-string-refs
24109
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
24109
+ // @ts-expect-error - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
24110
24110
  legacyPerseusLint: this.refs.itemEditor.getSaveWarnings()
24111
24111
  }).extend(_(this.props).pick("workAreaSelector", "solutionAreaSelector", "hintsAreaSelector", "problemNum"))
24112
24112
  });
@@ -24116,10 +24116,10 @@ class EditorPage extends React.Component {
24116
24116
  }
24117
24117
  getSaveWarnings() {
24118
24118
  // eslint-disable-next-line react/no-string-refs
24119
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
24119
+ // @ts-expect-error - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
24120
24120
  const issues1 = this.refs.itemEditor.getSaveWarnings();
24121
24121
  // eslint-disable-next-line react/no-string-refs
24122
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
24122
+ // @ts-expect-error - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
24123
24123
  const issues2 = this.refs.hintsEditor.getSaveWarnings();
24124
24124
  return issues1.concat(issues2);
24125
24125
  }
@@ -24128,10 +24128,10 @@ class EditorPage extends React.Component {
24128
24128
  return this.state.json;
24129
24129
  }
24130
24130
  // eslint-disable-next-line react/no-string-refs
24131
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
24131
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
24132
24132
  return _.extend(this.refs.itemEditor.serialize(options), {
24133
24133
  // eslint-disable-next-line react/no-string-refs
24134
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
24134
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
24135
24135
  hints: this.refs.hintsEditor.serialize(options)
24136
24136
  });
24137
24137
  }
@@ -24224,7 +24224,7 @@ const {
24224
24224
 
24225
24225
  // Takes a renderer content and parses the markdown for images
24226
24226
  function findImagesInContent(content, images) {
24227
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 2 arguments, but got 1.
24227
+ // @ts-expect-error - TS2554 - Expected 2 arguments, but got 1.
24228
24228
  const parsed = PerseusMarkdown.parse(content);
24229
24229
  PerseusMarkdown.traverseContent(parsed, function (node) {
24230
24230
  if (node.type === "image") {
@@ -24325,12 +24325,12 @@ function findImagesInItemData(itemData) {
24325
24325
  let renderers = [];
24326
24326
  if (itemData._multi) {
24327
24327
  const shape = inferItemShape(itemData);
24328
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'ContentNode' is not assignable to parameter of type 'never'.
24328
+ // @ts-expect-error - TS2345 - Argument of type 'ContentNode' is not assignable to parameter of type 'never'.
24329
24329
  findContentNodesInItem(itemData, shape, node => renderers.push(node));
24330
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'HintNode' is not assignable to parameter of type 'never'.
24330
+ // @ts-expect-error - TS2345 - Argument of type 'HintNode' is not assignable to parameter of type 'never'.
24331
24331
  findHintNodesInItem(itemData, shape, node => renderers.push(node));
24332
24332
  } else {
24333
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'any' is not assignable to type 'never'. | TS2322 - Type 'any' is not assignable to type 'never'.
24333
+ // @ts-expect-error - TS2322 - Type 'any' is not assignable to type 'never'. | TS2322 - Type 'any' is not assignable to type 'never'.
24334
24334
  renderers = [itemData.question, ...itemData.hints];
24335
24335
  }
24336
24336
  return findImagesInRenderers(renderers);
@@ -25108,7 +25108,7 @@ const withStickiness = WrappedComponent => {
25108
25108
  };
25109
25109
  this.updateStickiness = () => {
25110
25110
  const domNode = ReactDOM__default.findDOMNode(this);
25111
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2339 - Property 'offsetHeight' does not exist on type 'Element | Text'.
25111
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2339 - Property 'offsetHeight' does not exist on type 'Element | Text'.
25112
25112
  const height = domNode.offsetHeight;
25113
25113
  const windowHeight = window.innerHeight;
25114
25114
  const sticky = height > windowHeight;
@@ -25122,7 +25122,7 @@ const withStickiness = WrappedComponent => {
25122
25122
  componentDidMount() {
25123
25123
  // TODO(jeff, CP-3128): Use Wonder Blocks Timing API.
25124
25124
  // eslint-disable-next-line no-restricted-syntax
25125
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'Timer' is not assignable to type 'number'.
25125
+ // @ts-expect-error - TS2322 - Type 'Timer' is not assignable to type 'number'.
25126
25126
  this.stickynessTimer = setInterval(this.updateStickiness, 1000);
25127
25127
  this.updateStickiness();
25128
25128
  }
@@ -25134,7 +25134,7 @@ const withStickiness = WrappedComponent => {
25134
25134
  render() {
25135
25135
  return (
25136
25136
  /*#__PURE__*/
25137
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'Readonly<Config> & { sticky: boolean; children?: ReactNode; }' is not assignable to type 'IntrinsicAttributes & LibraryManagedAttributes<Component, PropsWithChildren<WithStickiness<Config>>>'.
25137
+ // @ts-expect-error - TS2322 - Type 'Readonly<Config> & { sticky: boolean; children?: ReactNode; }' is not assignable to type 'IntrinsicAttributes & LibraryManagedAttributes<Component, PropsWithChildren<WithStickiness<Config>>>'.
25138
25138
  React.createElement(WrappedComponent, _extends({}, this.props, {
25139
25139
  sticky: this.state.sticky
25140
25140
  }))
@@ -25162,7 +25162,7 @@ const ItemNodeContent = withStickiness(props => {
25162
25162
  className: css(sticky && styles$c.sticky)
25163
25163
  },
25164
25164
  /*#__PURE__*/
25165
- // @ts-expect-error [FEI-5003] - TS2769 - No overload matches this call.
25165
+ // @ts-expect-error - TS2769 - No overload matches this call.
25166
25166
  React.createElement(Editor, _extends({}, data, {
25167
25167
  onChange: newVal => actions.mergeValueAtPath(path, newVal),
25168
25168
  apiOptions: apiOptions
@@ -25413,6 +25413,15 @@ class MultiRendererEditor extends React.Component {
25413
25413
  item: item,
25414
25414
  shape: itemShape,
25415
25415
  apiOptions: apiOptions
25416
+ // Today, with analytics being the only thing in
25417
+ // dependencies, we send in a dummy function as we don't
25418
+ // want to gather analytics events from within the editor.
25419
+ ,
25420
+ dependencies: {
25421
+ analytics: {
25422
+ onAnalyticsEvent: async function () {}
25423
+ }
25424
+ }
25416
25425
  }, ({
25417
25426
  renderers
25418
25427
  }) => /*#__PURE__*/React.createElement(NodeContainer, {
@@ -25426,19 +25435,19 @@ class MultiRendererEditor extends React.Component {
25426
25435
  };
25427
25436
  this.score = () => {
25428
25437
  if (this.layout) {
25429
- // @ts-expect-error [FEI-5003] - TS2571 - Object is of type 'unknown'.
25438
+ // @ts-expect-error - TS2571 - Object is of type 'unknown'.
25430
25439
  return this.layout.score();
25431
25440
  }
25432
25441
  };
25433
25442
  this.getSerializedState = () => {
25434
25443
  if (this.layout) {
25435
- // @ts-expect-error [FEI-5003] - TS2571 - Object is of type 'unknown'.
25444
+ // @ts-expect-error - TS2571 - Object is of type 'unknown'.
25436
25445
  return this.layout.getSerializedState();
25437
25446
  }
25438
25447
  };
25439
25448
  this.restoreSerializedState = state => {
25440
25449
  if (this.layout) {
25441
- // @ts-expect-error [FEI-5003] - TS2571 - Object is of type 'unknown'.
25450
+ // @ts-expect-error - TS2571 - Object is of type 'unknown'.
25442
25451
  this.layout.restoreSerializedState(state);
25443
25452
  }
25444
25453
  };
@@ -25765,14 +25774,14 @@ class CategorizerEditor extends React.Component {
25765
25774
  })), "Categories:", /*#__PURE__*/React.createElement(TextListEditor$4, {
25766
25775
  options: this.props.categories,
25767
25776
  onChange: cat => {
25768
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
25777
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
25769
25778
  this.change("categories", cat);
25770
25779
  },
25771
25780
  layout: "horizontal"
25772
25781
  }), "Items:", /*#__PURE__*/React.createElement(TextListEditor$4, {
25773
25782
  options: this.props.items,
25774
25783
  onChange: items => {
25775
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
25784
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
25776
25785
  this.change({
25777
25786
  items: items,
25778
25787
  // TODO(eater): This truncates props.values so there
@@ -25970,7 +25979,7 @@ class CSProgramEditor extends React.Component {
25970
25979
  constructor(..._args3) {
25971
25980
  super(..._args3);
25972
25981
  this.change = (...args) => {
25973
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'readonly unknown[]' is not assignable to parameter of type 'any[]'.
25982
+ // @ts-expect-error - TS2345 - Argument of type 'readonly unknown[]' is not assignable to parameter of type 'any[]'.
25974
25983
  return Changeable.change.apply(this, args);
25975
25984
  };
25976
25985
  this._handleSettingsChange = settings => {
@@ -25996,7 +26005,7 @@ class CSProgramEditor extends React.Component {
25996
26005
  });
25997
26006
  }).fail((jqxhr, textStatus, error) => {
25998
26007
  Log.error("Error retrieving scratchpad info for program ID ", Errors.TransientService, {
25999
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'string' is not assignable to type 'Error | null | undefined'.
26008
+ // @ts-expect-error - TS2322 - Type 'string' is not assignable to type 'Error | null | undefined'.
26000
26009
  cause: error,
26001
26010
  loggedMetadata: {
26002
26011
  textStatus,
@@ -26072,7 +26081,7 @@ class DefinitionEditor extends React.Component {
26072
26081
  className: "perseus-widget-row"
26073
26082
  }, /*#__PURE__*/React.createElement("label", null, "Word to be defined:", " ", /*#__PURE__*/React.createElement(TextInput$8, {
26074
26083
  value: this.props.togglePrompt
26075
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26084
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26076
26085
  ,
26077
26086
  onChange: this.change("togglePrompt"),
26078
26087
  placeholder: "define me"
@@ -26088,7 +26097,7 @@ class DefinitionEditor extends React.Component {
26088
26097
  if (_.has(props, "content")) {
26089
26098
  newProps.definition = props.content;
26090
26099
  }
26091
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26100
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26092
26101
  this.change(newProps);
26093
26102
  }
26094
26103
  })));
@@ -26162,7 +26171,7 @@ class DropdownEditor extends React.Component {
26162
26171
  });
26163
26172
  };
26164
26173
  this.focus = i => {
26165
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2339 - Property 'focus' does not exist on type 'Element | Text'.
26174
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2339 - Property 'focus' does not exist on type 'Element | Text'.
26166
26175
  ReactDOM__default.findDOMNode(this.refs["editor" + i]).focus(); // eslint-disable-line react/no-string-refs
26167
26176
  return true;
26168
26177
  };
@@ -26195,24 +26204,24 @@ class DropdownEditor extends React.Component {
26195
26204
  ref: "radio" + i,
26196
26205
  type: "radio",
26197
26206
  name: dropdownGroupName
26198
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'string' is not assignable to type 'boolean | undefined'.
26207
+ // @ts-expect-error - TS2322 - Type 'string' is not assignable to type 'boolean | undefined'.
26199
26208
  ,
26200
26209
  checked: choice.correct ? "checked" : ""
26201
26210
  // eslint-disable-next-line react/jsx-no-bind
26202
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26211
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26203
26212
  ,
26204
26213
  onChange: this.onCorrectChange.bind(
26205
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26214
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26206
26215
  this, i),
26207
26216
  value: i
26208
26217
  }), /*#__PURE__*/React.createElement("input", {
26209
26218
  type: "text",
26210
26219
  ref: "editor" + i
26211
26220
  // eslint-disable-next-line react/jsx-no-bind
26212
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26221
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26213
26222
  ,
26214
26223
  onChange: this.onContentChange.bind(
26215
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26224
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26216
26225
  this, i),
26217
26226
  className: checkedClass,
26218
26227
  value: choice.content
@@ -26220,10 +26229,10 @@ class DropdownEditor extends React.Component {
26220
26229
  href: "#",
26221
26230
  className: "simple-button orange"
26222
26231
  // eslint-disable-next-line react/jsx-no-bind
26223
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26232
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26224
26233
  ,
26225
26234
  onClick: this.removeChoice.bind(
26226
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26235
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26227
26236
  this, i)
26228
26237
  }, /*#__PURE__*/React.createElement("span", {
26229
26238
  className: "remove-choice"
@@ -26257,7 +26266,7 @@ const {
26257
26266
  Graphie
26258
26267
  } = components;
26259
26268
 
26260
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'MovablePoint' does not exist on type 'typeof Graphie'.
26269
+ // @ts-expect-error - TS2339 - Property 'MovablePoint' does not exist on type 'typeof Graphie'.
26261
26270
  const MovablePoint = Graphie.MovablePoint;
26262
26271
  /**
26263
26272
  * This is the widget's renderer. It shows up in the right column
@@ -26274,7 +26283,7 @@ class ExampleGraphieWidget$1 extends React.Component {
26274
26283
  return Changeable.change.apply(this, args);
26275
26284
  };
26276
26285
  this.movePoint = newCoord => {
26277
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26286
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26278
26287
  this.change({
26279
26288
  coord: newCoord
26280
26289
  });
@@ -26394,7 +26403,7 @@ class ExampleGraphieWidgetEditor extends React.Component {
26394
26403
  };
26395
26404
  this.handleChange = newProps => {
26396
26405
  if (newProps.coord) {
26397
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26406
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26398
26407
  this.change({
26399
26408
  correct: newProps.coord
26400
26409
  });
@@ -26438,7 +26447,7 @@ class ExampleWidgetEditor extends React.Component {
26438
26447
  constructor(..._args) {
26439
26448
  super(..._args);
26440
26449
  this.handleAnswerChange = event => {
26441
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26450
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26442
26451
  this.change({
26443
26452
  correct: event.target.value
26444
26453
  });
@@ -26448,7 +26457,7 @@ class ExampleWidgetEditor extends React.Component {
26448
26457
  };
26449
26458
  this.focus = () => {
26450
26459
  // eslint-disable-next-line react/no-string-refs
26451
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
26460
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
26452
26461
  this.refs.input.focus();
26453
26462
  return true;
26454
26463
  };
@@ -26499,14 +26508,14 @@ class ExplanationEditor extends React.Component {
26499
26508
  className: "perseus-widget-row"
26500
26509
  }, /*#__PURE__*/React.createElement("label", null, "Prompt to show explanation:", " ", /*#__PURE__*/React.createElement(TextInput$7, {
26501
26510
  value: this.props.showPrompt
26502
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26511
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26503
26512
  ,
26504
26513
  onChange: this.change("showPrompt")
26505
26514
  }))), /*#__PURE__*/React.createElement("div", {
26506
26515
  className: "perseus-widget-row"
26507
26516
  }, /*#__PURE__*/React.createElement("label", null, "Prompt to hide explanation:", " ", /*#__PURE__*/React.createElement(TextInput$7, {
26508
26517
  value: this.props.hidePrompt
26509
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26518
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26510
26519
  ,
26511
26520
  onChange: this.change("hidePrompt")
26512
26521
  }))), /*#__PURE__*/React.createElement("div", {
@@ -26525,7 +26534,7 @@ class ExplanationEditor extends React.Component {
26525
26534
  if (_.has(props, "widgets")) {
26526
26535
  newProps.widgets = props.widgets;
26527
26536
  }
26528
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26537
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26529
26538
  this.change(newProps);
26530
26539
  }
26531
26540
  })));
@@ -26624,7 +26633,7 @@ const SortableArea = createReactClass({
26624
26633
  _setDragEvents: function () {
26625
26634
  this._dragItems = this._dragItems || [];
26626
26635
  const items =
26627
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'
26636
+ // @ts-expect-error - TS2531 - Object is possibly 'null'
26628
26637
  ReactDOM__default.findDOMNode(this).querySelectorAll("[draggable=true]");
26629
26638
  const oldItems = [];
26630
26639
  const newItems = [];
@@ -26824,7 +26833,7 @@ class ExpressionEditor extends React.Component {
26824
26833
  this.newAnswer = () => {
26825
26834
  const answerForms = this.props.answerForms.slice();
26826
26835
  answerForms.push(this._newEmptyAnswerForm());
26827
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26836
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26828
26837
  this.change({
26829
26838
  answerForms
26830
26839
  });
@@ -26832,7 +26841,7 @@ class ExpressionEditor extends React.Component {
26832
26841
  this.handleRemoveForm = i => {
26833
26842
  const answerForms = this.props.answerForms.slice();
26834
26843
  answerForms.splice(i, 1);
26835
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26844
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26836
26845
  this.change({
26837
26846
  answerForms
26838
26847
  });
@@ -26840,7 +26849,7 @@ class ExpressionEditor extends React.Component {
26840
26849
  this.updateForm = (i, props) => {
26841
26850
  const answerForms = lens(this.props.answerForms).merge([i], props).freeze();
26842
26851
 
26843
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26852
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26844
26853
  this.change({
26845
26854
  answerForms
26846
26855
  });
@@ -26848,12 +26857,12 @@ class ExpressionEditor extends React.Component {
26848
26857
  this.handleReorder = components => {
26849
26858
  const answerForms = _(components).map(component => {
26850
26859
  const form = _(component.props).pick("considered", "form", "simplify", "value");
26851
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'key' does not exist on type 'Pick<any, "form" | "value" | "simplify" | "considered">'.
26860
+ // @ts-expect-error - TS2339 - Property 'key' does not exist on type 'Pick<any, "form" | "value" | "simplify" | "considered">'.
26852
26861
  form.key = component.key;
26853
26862
  return form;
26854
26863
  });
26855
26864
 
26856
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26865
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26857
26866
  this.change({
26858
26867
  answerForms
26859
26868
  });
@@ -26885,12 +26894,12 @@ class ExpressionEditor extends React.Component {
26885
26894
  }
26886
26895
  const buttonSets = _(this.props.buttonSets).reject(set => set === remove).concat(keep);
26887
26896
 
26888
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
26897
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
26889
26898
  this.change("buttonSets", buttonSets);
26890
26899
  };
26891
26900
  this.handleTexInsert = str => {
26892
26901
  // eslint-disable-next-line react/no-string-refs
26893
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'insert' does not exist on type 'ReactInstance'.
26902
+ // @ts-expect-error - TS2339 - Property 'insert' does not exist on type 'ReactInstance'.
26894
26903
  this.refs.expression.insert(str);
26895
26904
  };
26896
26905
  this.handleFunctions = e => {
@@ -27062,7 +27071,7 @@ class AnswerOption extends React.Component {
27062
27071
  render() {
27063
27072
  let removeButton = null;
27064
27073
  if (this.state.deleteFocused) {
27065
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'Element' is not assignable to type 'null'.
27074
+ // @ts-expect-error - TS2322 - Type 'Element' is not assignable to type 'null'.
27066
27075
  removeButton = /*#__PURE__*/React.createElement("button", {
27067
27076
  type: "button",
27068
27077
  className: "simple-button orange",
@@ -27070,7 +27079,7 @@ class AnswerOption extends React.Component {
27070
27079
  onBlur: this.handleDeleteBlur
27071
27080
  }, "I'm sure!");
27072
27081
  } else {
27073
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'Element' is not assignable to type 'null'.
27082
+ // @ts-expect-error - TS2322 - Type 'Element' is not assignable to type 'null'.
27074
27083
  removeButton = /*#__PURE__*/React.createElement("button", {
27075
27084
  type: "button",
27076
27085
  className: "simple-button orange",
@@ -27142,7 +27151,7 @@ class GradedGroupEditor extends React.Component {
27142
27151
  hint
27143
27152
  }, () => {
27144
27153
  // eslint-disable-next-line react/no-string-refs
27145
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
27154
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
27146
27155
  this.refs["hint-editor"].focus();
27147
27156
  });
27148
27157
  };
@@ -27153,7 +27162,7 @@ class GradedGroupEditor extends React.Component {
27153
27162
  };
27154
27163
  this.getSaveWarnings = () => {
27155
27164
  // eslint-disable-next-line react/no-string-refs
27156
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
27165
+ // @ts-expect-error - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
27157
27166
  return this.refs.editor.getSaveWarnings();
27158
27167
  };
27159
27168
  this.serialize = () => {
@@ -27164,7 +27173,7 @@ class GradedGroupEditor extends React.Component {
27164
27173
  // eslint-disable-next-line react/no-string-refs
27165
27174
  this.refs["hint-editor"] &&
27166
27175
  // eslint-disable-next-line react/no-string-refs
27167
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
27176
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
27168
27177
  this.refs["hint-editor"].serialize()
27169
27178
  });
27170
27179
  };
@@ -27179,7 +27188,7 @@ class GradedGroupEditor extends React.Component {
27179
27188
  }, "Title:", " ", /*#__PURE__*/React.createElement(TextInput$6, {
27180
27189
  value: this.props.title,
27181
27190
  className: css(styles$a.input)
27182
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
27191
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
27183
27192
  ,
27184
27193
  onChange: this.change("title")
27185
27194
  }))), /*#__PURE__*/React.createElement(Editor
@@ -27219,7 +27228,7 @@ class GradedGroupEditor extends React.Component {
27219
27228
  onChange: props => {
27220
27229
  // Copy all props over from the existing hint
27221
27230
  // and then add new props.
27222
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
27231
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
27223
27232
  this.change("hint", Object.assign({}, this.props.hint, props));
27224
27233
  }
27225
27234
  }), /*#__PURE__*/React.createElement("button", {
@@ -27286,13 +27295,13 @@ class GradedGroupSetEditor extends React.Component {
27286
27295
  widgetEnabled: true,
27287
27296
  immutableWidgets: false,
27288
27297
  onChange: data =>
27289
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
27298
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
27290
27299
  this.change("gradedGroups", setArrayItem(this.props.gradedGroups, i, _extends({}, this.props.gradedGroups[i], data)))
27291
27300
  })));
27292
27301
  };
27293
27302
  this.addGroup = () => {
27294
27303
  const groups = this.props.gradedGroups || [];
27295
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
27304
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
27296
27305
  this.change("gradedGroups", groups.concat([GradedGroupEditor.defaultProps]));
27297
27306
  };
27298
27307
  }
@@ -27433,7 +27442,7 @@ const GraphSettings = createReactClass({
27433
27442
  }, this.changeGraph);
27434
27443
  };
27435
27444
 
27436
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
27445
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
27437
27446
  const url = ReactDOM__default.findDOMNode(this.refs["bg-url"]).value; // eslint-disable-line react/no-string-refs
27438
27447
  if (url) {
27439
27448
  Util.getImageSize(url, (width, height) => {
@@ -27861,7 +27870,7 @@ class GrapherEditor extends React.Component {
27861
27870
  // NOTE(jeremy): This editor doesn't pass in a bunch of
27862
27871
  // standard props that the Renderer provides normally (eg.
27863
27872
  // alignment, findWidgets, etc).
27864
- // @ts-expect-error [FEI-5003] - TS2769 - No overload matches this call.
27873
+ // @ts-expect-error - TS2769 - No overload matches this call.
27865
27874
  React.createElement(Grapher, _extends({}, graphProps, {
27866
27875
  apiOptions: this.props.apiOptions,
27867
27876
  containerSizeClass: sizeClass
@@ -27886,7 +27895,7 @@ class GrapherEditor extends React.Component {
27886
27895
  rulerLabel: this.props.graph.rulerLabel,
27887
27896
  rulerTicks: this.props.graph.rulerTicks,
27888
27897
  showTooltips: this.props.graph.showTooltips
27889
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
27898
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
27890
27899
  ,
27891
27900
  onChange: this.change("graph")
27892
27901
  }), /*#__PURE__*/React.createElement("div", {
@@ -27914,7 +27923,7 @@ class GroupEditor extends React.Component {
27914
27923
  const GroupMetadataEditor = this.props.apiOptions.GroupMetadataEditor;
27915
27924
  return /*#__PURE__*/React.createElement(GroupMetadataEditor, {
27916
27925
  value: this.props.metadata
27917
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
27926
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
27918
27927
  ,
27919
27928
  onChange: this.change("metadata")
27920
27929
  });
@@ -27924,12 +27933,12 @@ class GroupEditor extends React.Component {
27924
27933
  };
27925
27934
  this.getSaveWarnings = () => {
27926
27935
  // eslint-disable-next-line react/no-string-refs
27927
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
27936
+ // @ts-expect-error - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
27928
27937
  return this.refs.editor.getSaveWarnings();
27929
27938
  };
27930
27939
  this.serialize = () => {
27931
27940
  // eslint-disable-next-line react/no-string-refs
27932
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
27941
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
27933
27942
  return _.extend({}, this.refs.editor.serialize(), {
27934
27943
  metadata: this.props.metadata
27935
27944
  });
@@ -28059,7 +28068,7 @@ class IframeEditor extends React.Component {
28059
28068
  return Changeable.change.apply(this, args);
28060
28069
  };
28061
28070
  this.handleSettingsChange = settings => {
28062
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28071
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28063
28072
  this.change({
28064
28073
  settings: settings.pairs
28065
28074
  });
@@ -28076,7 +28085,7 @@ class IframeEditor extends React.Component {
28076
28085
  }
28077
28086
  }, "This widget is deprecated! ", /*#__PURE__*/React.createElement("br", null), "Try using the Video or CS Program widgets instead."), /*#__PURE__*/React.createElement("label", null, "Url or Program ID:", /*#__PURE__*/React.createElement(BlurInput, {
28078
28087
  value: this.props.url
28079
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28088
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28080
28089
  ,
28081
28090
  onChange: this.change("url")
28082
28091
  })), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("label", null, "Settings:", /*#__PURE__*/React.createElement(PairsEditor, {
@@ -28085,12 +28094,12 @@ class IframeEditor extends React.Component {
28085
28094
  onChange: this.handleSettingsChange
28086
28095
  })), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("label", null, "Width:", /*#__PURE__*/React.createElement(BlurInput, {
28087
28096
  value: this.props.width
28088
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28097
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28089
28098
  ,
28090
28099
  onChange: this.change("width")
28091
28100
  })), /*#__PURE__*/React.createElement("label", null, "Height:", /*#__PURE__*/React.createElement(BlurInput, {
28092
28101
  value: this.props.height
28093
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28102
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28094
28103
  ,
28095
28104
  onChange: this.change("height")
28096
28105
  })), /*#__PURE__*/React.createElement(PropCheckBox$9, {
@@ -28404,7 +28413,7 @@ class InputNumberEditor extends React.Component {
28404
28413
  });
28405
28414
  };
28406
28415
  this.focus = () => {
28407
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2339 - Property 'focus' does not exist on type 'Element | Text'.
28416
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2339 - Property 'focus' does not exist on type 'Element | Text'.
28408
28417
  ReactDOM__default.findDOMNode(this.refs.input).focus(); // eslint-disable-line react/no-string-refs
28409
28418
  return true;
28410
28419
  };
@@ -28435,7 +28444,7 @@ class InputNumberEditor extends React.Component {
28435
28444
  value: this.props.simplify,
28436
28445
  onChange: e => {
28437
28446
  this.props.onChange({
28438
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'string' is not assignable to type '"optional" | "required" | "enforced" | undefined'.
28447
+ // @ts-expect-error - TS2322 - Type 'string' is not assignable to type '"optional" | "required" | "enforced" | undefined'.
28439
28448
  simplify: e.target.value
28440
28449
  });
28441
28450
  }
@@ -28474,7 +28483,7 @@ class InputNumberEditor extends React.Component {
28474
28483
  }))), /*#__PURE__*/React.createElement("div", null, "Answer type:", " ", /*#__PURE__*/React.createElement("select", {
28475
28484
  value: this.props.answerType,
28476
28485
  onChange: e => {
28477
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'string' is not assignable to type '"number" | "integer" | "mixed" | "decimal" | "improper" | "percent" | "pi" | "rational" | undefined'.
28486
+ // @ts-expect-error - TS2322 - Type 'string' is not assignable to type '"number" | "integer" | "mixed" | "decimal" | "improper" | "percent" | "pi" | "rational" | undefined'.
28478
28487
  this.props.onChange({
28479
28488
  answerType: e.target.value
28480
28489
  });
@@ -28482,7 +28491,7 @@ class InputNumberEditor extends React.Component {
28482
28491
  }, answerTypeOptions), /*#__PURE__*/React.createElement(InfoTip$f, null, /*#__PURE__*/React.createElement("p", null, "Use the default \"Numbers\" unless the answer must be in a specific form (e.g., question is about converting decimals to fractions)."))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, "Width", " ", /*#__PURE__*/React.createElement("select", {
28483
28492
  value: this.props.size,
28484
28493
  onChange: e => {
28485
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'string' is not assignable to type '"small" | "normal" | undefined'.
28494
+ // @ts-expect-error - TS2322 - Type 'string' is not assignable to type '"small" | "normal" | undefined'.
28486
28495
  this.props.onChange({
28487
28496
  size: e.target.value
28488
28497
  });
@@ -28662,21 +28671,21 @@ class PointEditor extends React.Component {
28662
28671
  buttonSets: [],
28663
28672
  buttonsVisible: "never",
28664
28673
  value: this.props.coordX
28665
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28674
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28666
28675
  ,
28667
28676
  onChange: this.change("coordX")
28668
28677
  }), /*#__PURE__*/React.createElement(TeX, null, ","), " ", /*#__PURE__*/React.createElement(MathInput, {
28669
28678
  buttonSets: [],
28670
28679
  buttonsVisible: "never",
28671
28680
  value: this.props.coordY
28672
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28681
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28673
28682
  ,
28674
28683
  onChange: this.change("coordY")
28675
28684
  }), /*#__PURE__*/React.createElement(TeX, null, "\\Large)")), /*#__PURE__*/React.createElement("div", {
28676
28685
  className: "perseus-widget-row"
28677
28686
  }, /*#__PURE__*/React.createElement(ColorPicker, {
28678
28687
  value: this.props.color
28679
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28688
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28680
28689
  ,
28681
28690
  onChange: this.change("color")
28682
28691
  })));
@@ -28719,14 +28728,14 @@ class LineEditor extends React.Component {
28719
28728
  buttonSets: [],
28720
28729
  buttonsVisible: "never",
28721
28730
  value: this.props.startX
28722
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28731
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28723
28732
  ,
28724
28733
  onChange: this.change("startX")
28725
28734
  }), /*#__PURE__*/React.createElement(TeX, null, ","), " ", /*#__PURE__*/React.createElement(MathInput, {
28726
28735
  buttonSets: [],
28727
28736
  buttonsVisible: "never",
28728
28737
  value: this.props.startY
28729
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28738
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28730
28739
  ,
28731
28740
  onChange: this.change("startY")
28732
28741
  }), /*#__PURE__*/React.createElement(TeX, null, "\\Large)")), /*#__PURE__*/React.createElement("div", {
@@ -28735,33 +28744,33 @@ class LineEditor extends React.Component {
28735
28744
  buttonSets: [],
28736
28745
  buttonsVisible: "never",
28737
28746
  value: this.props.endX
28738
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28747
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28739
28748
  ,
28740
28749
  onChange: this.change("endX")
28741
28750
  }), /*#__PURE__*/React.createElement(TeX, null, ","), " ", /*#__PURE__*/React.createElement(MathInput, {
28742
28751
  buttonSets: [],
28743
28752
  buttonsVisible: "never",
28744
28753
  value: this.props.endY
28745
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28754
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28746
28755
  ,
28747
28756
  onChange: this.change("endY")
28748
28757
  }), /*#__PURE__*/React.createElement(TeX, null, "\\Large)")), /*#__PURE__*/React.createElement("div", {
28749
28758
  className: "perseus-widget-row"
28750
28759
  }, /*#__PURE__*/React.createElement(ColorPicker, {
28751
28760
  value: this.props.color
28752
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28761
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28753
28762
  ,
28754
28763
  onChange: this.change("color")
28755
28764
  })), /*#__PURE__*/React.createElement("div", {
28756
28765
  className: "perseus-widget-row"
28757
28766
  }, /*#__PURE__*/React.createElement(DashPicker, {
28758
28767
  value: this.props.strokeDasharray
28759
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28768
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28760
28769
  ,
28761
28770
  onChange: this.change("strokeDasharray")
28762
28771
  }), "\xA0 \xA0", /*#__PURE__*/React.createElement(ArrowPicker, {
28763
28772
  value: this.props.arrows
28764
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28773
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28765
28774
  ,
28766
28775
  onChange: this.change("arrows")
28767
28776
  })), /*#__PURE__*/React.createElement("div", {
@@ -28771,7 +28780,7 @@ class LineEditor extends React.Component {
28771
28780
  }, "Width:", " ", /*#__PURE__*/React.createElement(NumberInput$b, {
28772
28781
  value: this.props.strokeWidth,
28773
28782
  placeholder: 2
28774
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28783
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28775
28784
  ,
28776
28785
  onChange: this.change("strokeWidth")
28777
28786
  }))));
@@ -28970,7 +28979,7 @@ class FunctionEditor extends React.Component {
28970
28979
  buttonSets: [],
28971
28980
  buttonsVisible: "never",
28972
28981
  value: this.props.value
28973
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28982
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28974
28983
  ,
28975
28984
  onChange: this.change("value")
28976
28985
  })), /*#__PURE__*/React.createElement("div", {
@@ -28979,28 +28988,28 @@ class FunctionEditor extends React.Component {
28979
28988
  buttonSets: [],
28980
28989
  buttonsVisible: "never",
28981
28990
  value: this.props.rangeMin
28982
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28991
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28983
28992
  ,
28984
28993
  onChange: this.change("rangeMin")
28985
28994
  }), /*#__PURE__*/React.createElement(TeX, null, ","), " ", /*#__PURE__*/React.createElement(MathInput, {
28986
28995
  buttonSets: [],
28987
28996
  buttonsVisible: "never",
28988
28997
  value: this.props.rangeMax
28989
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28998
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28990
28999
  ,
28991
29000
  onChange: this.change("rangeMax")
28992
29001
  }), /*#__PURE__*/React.createElement(TeX, null, "\\Large)")), /*#__PURE__*/React.createElement("div", {
28993
29002
  className: "perseus-widget-row"
28994
29003
  }, /*#__PURE__*/React.createElement(ColorPicker, {
28995
29004
  value: this.props.color
28996
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29005
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28997
29006
  ,
28998
29007
  onChange: this.change("color")
28999
29008
  })), /*#__PURE__*/React.createElement("div", {
29000
29009
  className: "perseus-widget-row"
29001
29010
  }, /*#__PURE__*/React.createElement(DashPicker, {
29002
29011
  value: this.props.strokeDasharray
29003
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29012
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29004
29013
  ,
29005
29014
  onChange: this.change("strokeDasharray")
29006
29015
  })), /*#__PURE__*/React.createElement("div", {
@@ -29010,7 +29019,7 @@ class FunctionEditor extends React.Component {
29010
29019
  }, "Width:", " ", /*#__PURE__*/React.createElement(NumberInput$b, {
29011
29020
  value: this.props.strokeWidth,
29012
29021
  placeholder: 2
29013
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29022
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29014
29023
  ,
29015
29024
  onChange: this.change("strokeWidth")
29016
29025
  }))));
@@ -29059,7 +29068,7 @@ class ParametricEditor extends React.Component {
29059
29068
  buttonSets: [],
29060
29069
  buttonsVisible: "never",
29061
29070
  value: this.props.x
29062
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29071
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29063
29072
  ,
29064
29073
  onChange: this.change("x")
29065
29074
  })), /*#__PURE__*/React.createElement("div", {
@@ -29068,7 +29077,7 @@ class ParametricEditor extends React.Component {
29068
29077
  buttonSets: [],
29069
29078
  buttonsVisible: "never",
29070
29079
  value: this.props.y
29071
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29080
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29072
29081
  ,
29073
29082
  onChange: this.change("y")
29074
29083
  })), /*#__PURE__*/React.createElement("div", {
@@ -29077,28 +29086,28 @@ class ParametricEditor extends React.Component {
29077
29086
  buttonSets: [],
29078
29087
  buttonsVisible: "never",
29079
29088
  value: this.props.rangeMin
29080
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29089
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29081
29090
  ,
29082
29091
  onChange: this.change("rangeMin")
29083
29092
  }), /*#__PURE__*/React.createElement(TeX, null, ","), " ", /*#__PURE__*/React.createElement(MathInput, {
29084
29093
  buttonSets: [],
29085
29094
  buttonsVisible: "never",
29086
29095
  value: this.props.rangeMax
29087
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29096
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29088
29097
  ,
29089
29098
  onChange: this.change("rangeMax")
29090
29099
  }), /*#__PURE__*/React.createElement(TeX, null, "\\Large)")), /*#__PURE__*/React.createElement("div", {
29091
29100
  className: "perseus-widget-row"
29092
29101
  }, /*#__PURE__*/React.createElement(ColorPicker, {
29093
29102
  value: this.props.color
29094
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29103
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29095
29104
  ,
29096
29105
  onChange: this.change("color")
29097
29106
  })), /*#__PURE__*/React.createElement("div", {
29098
29107
  className: "perseus-widget-row"
29099
29108
  }, /*#__PURE__*/React.createElement(DashPicker, {
29100
29109
  value: this.props.strokeDasharray
29101
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29110
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29102
29111
  ,
29103
29112
  onChange: this.change("strokeDasharray")
29104
29113
  })), /*#__PURE__*/React.createElement("div", {
@@ -29108,7 +29117,7 @@ class ParametricEditor extends React.Component {
29108
29117
  }, "Width:", " ", /*#__PURE__*/React.createElement(NumberInput$b, {
29109
29118
  value: this.props.strokeWidth,
29110
29119
  placeholder: 2
29111
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29120
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29112
29121
  ,
29113
29122
  onChange: this.change("strokeWidth")
29114
29123
  }))));
@@ -29158,7 +29167,7 @@ class LabelEditor extends React.Component {
29158
29167
  className: "perseus-widget-row"
29159
29168
  }, /*#__PURE__*/React.createElement(TextInput$5, {
29160
29169
  value: this.props.label
29161
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29170
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29162
29171
  ,
29163
29172
  onChange: this.change("label"),
29164
29173
  style: {
@@ -29170,21 +29179,21 @@ class LabelEditor extends React.Component {
29170
29179
  buttonSets: [],
29171
29180
  buttonsVisible: "never",
29172
29181
  value: this.props.coordX
29173
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29182
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29174
29183
  ,
29175
29184
  onChange: this.change("coordX")
29176
29185
  }), /*#__PURE__*/React.createElement(TeX, null, ","), " ", /*#__PURE__*/React.createElement(MathInput, {
29177
29186
  buttonSets: [],
29178
29187
  buttonsVisible: "never",
29179
29188
  value: this.props.coordY
29180
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29189
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29181
29190
  ,
29182
29191
  onChange: this.change("coordY")
29183
29192
  }), /*#__PURE__*/React.createElement(TeX, null, "\\Large)")), /*#__PURE__*/React.createElement("div", {
29184
29193
  className: "perseus-widget-row"
29185
29194
  }, /*#__PURE__*/React.createElement(ColorPicker, {
29186
29195
  value: this.props.color
29187
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29196
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29188
29197
  ,
29189
29198
  onChange: this.change("color")
29190
29199
  })));
@@ -29229,14 +29238,14 @@ class RectangleEditor extends React.Component {
29229
29238
  buttonSets: [],
29230
29239
  buttonsVisible: "never",
29231
29240
  value: this.props.coordX
29232
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29241
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29233
29242
  ,
29234
29243
  onChange: this.change("coordX")
29235
29244
  }), /*#__PURE__*/React.createElement(TeX, null, ","), " ", /*#__PURE__*/React.createElement(MathInput, {
29236
29245
  buttonSets: [],
29237
29246
  buttonsVisible: "never",
29238
29247
  value: this.props.coordY
29239
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29248
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29240
29249
  ,
29241
29250
  onChange: this.change("coordY")
29242
29251
  }), /*#__PURE__*/React.createElement(TeX, null, "\\Large)")), /*#__PURE__*/React.createElement("div", {
@@ -29245,7 +29254,7 @@ class RectangleEditor extends React.Component {
29245
29254
  buttonSets: [],
29246
29255
  buttonsVisible: "never",
29247
29256
  value: this.props.width
29248
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29257
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29249
29258
  ,
29250
29259
  onChange: this.change("width")
29251
29260
  })), /*#__PURE__*/React.createElement("div", {
@@ -29254,7 +29263,7 @@ class RectangleEditor extends React.Component {
29254
29263
  buttonSets: [],
29255
29264
  buttonsVisible: "never",
29256
29265
  value: this.props.height
29257
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29266
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29258
29267
  ,
29259
29268
  onChange: this.change("height")
29260
29269
  })), /*#__PURE__*/React.createElement("div", {
@@ -29262,7 +29271,7 @@ class RectangleEditor extends React.Component {
29262
29271
  }, /*#__PURE__*/React.createElement(ColorPicker, {
29263
29272
  value: this.props.color,
29264
29273
  lightColors: true
29265
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29274
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29266
29275
  ,
29267
29276
  onChange: this.change("color")
29268
29277
  })), /*#__PURE__*/React.createElement("div", {
@@ -29294,7 +29303,7 @@ class InteractionEditor extends React.Component {
29294
29303
  this._updateGraphProps = newProps => {
29295
29304
  // TODO(eater): GraphSettings should name this tickStep instead
29296
29305
  // of step. Grr..
29297
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29306
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29298
29307
  this.change({
29299
29308
  graph: _.extend(_.omit(newProps, "step"), {
29300
29309
  tickStep: newProps.step
@@ -29315,13 +29324,13 @@ class InteractionEditor extends React.Component {
29315
29324
  let nextSubscript;
29316
29325
  if (elementType === "movable-point") {
29317
29326
  nextSubscript = _.max([_.max(this.state.usedVarSubscripts), -1]) + 1;
29318
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'varSubscript' does not exist on type '{}'.
29327
+ // @ts-expect-error - TS2339 - Property 'varSubscript' does not exist on type '{}'.
29319
29328
  newElement.options.varSubscript = nextSubscript;
29320
29329
  } else if (elementType === "movable-line") {
29321
29330
  nextSubscript = _.max([_.max(this.state.usedVarSubscripts), -1]) + 1;
29322
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'startSubscript' does not exist on type '{}'.
29331
+ // @ts-expect-error - TS2339 - Property 'startSubscript' does not exist on type '{}'.
29323
29332
  newElement.options.startSubscript = nextSubscript;
29324
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'endSubscript' does not exist on type '{}'.
29333
+ // @ts-expect-error - TS2339 - Property 'endSubscript' does not exist on type '{}'.
29325
29334
  newElement.options.endSubscript = nextSubscript + 1;
29326
29335
  } else if (elementType === "function") {
29327
29336
  // TODO(eater): The 22nd function added will be {(x) since '{'
@@ -29329,17 +29338,17 @@ class InteractionEditor extends React.Component {
29329
29338
  const nextLetter = String.fromCharCode(_.max([_.max(_.map(this.state.usedFunctionNames, function (c) {
29330
29339
  return c.charCodeAt(0);
29331
29340
  })), "e".charCodeAt(0)]) + 1);
29332
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'funcName' does not exist on type '{}'.
29341
+ // @ts-expect-error - TS2339 - Property 'funcName' does not exist on type '{}'.
29333
29342
  newElement.options.funcName = nextLetter;
29334
29343
  }
29335
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29344
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29336
29345
  this.change({
29337
29346
  elements: this.props.elements.concat(newElement)
29338
29347
  });
29339
29348
  };
29340
29349
  this._deleteElement = index => {
29341
29350
  const element = this.props.elements[index];
29342
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29351
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29343
29352
  this.change({
29344
29353
  elements: _.without(this.props.elements, element)
29345
29354
  });
@@ -29348,7 +29357,7 @@ class InteractionEditor extends React.Component {
29348
29357
  const element = this.props.elements[index];
29349
29358
  const newElements = _.without(this.props.elements, element);
29350
29359
  newElements.splice(index - 1, 0, element);
29351
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29360
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29352
29361
  this.change({
29353
29362
  elements: newElements
29354
29363
  });
@@ -29357,7 +29366,7 @@ class InteractionEditor extends React.Component {
29357
29366
  const element = this.props.elements[index];
29358
29367
  const newElements = _.without(this.props.elements, element);
29359
29368
  newElements.splice(index + 1, 0, element);
29360
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29369
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29361
29370
  this.change({
29362
29371
  elements: newElements
29363
29372
  });
@@ -29413,29 +29422,29 @@ class InteractionEditor extends React.Component {
29413
29422
  // eslint-disable-next-line react/jsx-no-bind
29414
29423
  ,
29415
29424
  onUp: n === 0 ? null :
29416
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29425
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29417
29426
  this._moveElementUp.bind(this, n)
29418
29427
  // eslint-disable-next-line react/jsx-no-bind
29419
29428
  ,
29420
29429
  onDown:
29421
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29430
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29422
29431
  n === this.props.elements.length - 1 ? null :
29423
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29432
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29424
29433
  this._moveElementDown.bind(
29425
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29434
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29426
29435
  this, n)
29427
29436
  // eslint-disable-next-line react/jsx-no-bind
29428
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29437
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29429
29438
  ,
29430
29439
  onDelete: this._deleteElement.bind(this, n),
29431
29440
  key: element.key
29432
29441
  }, /*#__PURE__*/React.createElement(MovablePointEditor, _extends({}, element.options, {
29433
29442
  onChange: newProps => {
29434
29443
  const elements = JSON.parse(JSON.stringify(
29435
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29444
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29436
29445
  this.props.elements));
29437
29446
  _.extend(elements[n].options, newProps);
29438
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29447
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29439
29448
  this.change({
29440
29449
  elements: elements
29441
29450
  });
@@ -29448,29 +29457,29 @@ class InteractionEditor extends React.Component {
29448
29457
  // eslint-disable-next-line react/jsx-no-bind
29449
29458
  ,
29450
29459
  onUp: n === 0 ? null :
29451
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29460
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29452
29461
  this._moveElementUp.bind(this, n)
29453
29462
  // eslint-disable-next-line react/jsx-no-bind
29454
29463
  ,
29455
29464
  onDown:
29456
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29465
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29457
29466
  n === this.props.elements.length - 1 ? null :
29458
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29467
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29459
29468
  this._moveElementDown.bind(
29460
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29469
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29461
29470
  this, n)
29462
29471
  // eslint-disable-next-line react/jsx-no-bind
29463
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29472
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29464
29473
  ,
29465
29474
  onDelete: this._deleteElement.bind(this, n),
29466
29475
  key: element.key
29467
29476
  }, /*#__PURE__*/React.createElement(MovableLineEditor, _extends({}, element.options, {
29468
29477
  onChange: newProps => {
29469
29478
  const elements = JSON.parse(JSON.stringify(
29470
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29479
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29471
29480
  this.props.elements));
29472
29481
  _.extend(elements[n].options, newProps);
29473
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29482
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29474
29483
  this.change({
29475
29484
  elements: elements
29476
29485
  });
@@ -29483,29 +29492,29 @@ class InteractionEditor extends React.Component {
29483
29492
  // eslint-disable-next-line react/jsx-no-bind
29484
29493
  ,
29485
29494
  onUp: n === 0 ? null :
29486
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29495
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29487
29496
  this._moveElementUp.bind(this, n)
29488
29497
  // eslint-disable-next-line react/jsx-no-bind
29489
29498
  ,
29490
29499
  onDown:
29491
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29500
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29492
29501
  n === this.props.elements.length - 1 ? null :
29493
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29502
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29494
29503
  this._moveElementDown.bind(
29495
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29504
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29496
29505
  this, n)
29497
29506
  // eslint-disable-next-line react/jsx-no-bind
29498
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29507
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29499
29508
  ,
29500
29509
  onDelete: this._deleteElement.bind(this, n),
29501
29510
  key: element.key
29502
29511
  }, /*#__PURE__*/React.createElement(PointEditor, _extends({}, element.options, {
29503
29512
  onChange: newProps => {
29504
29513
  const elements = JSON.parse(JSON.stringify(
29505
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29514
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29506
29515
  this.props.elements));
29507
29516
  _.extend(elements[n].options, newProps);
29508
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29517
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29509
29518
  this.change({
29510
29519
  elements: elements
29511
29520
  });
@@ -29518,29 +29527,29 @@ class InteractionEditor extends React.Component {
29518
29527
  // eslint-disable-next-line react/jsx-no-bind
29519
29528
  ,
29520
29529
  onUp: n === 0 ? null :
29521
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29530
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29522
29531
  this._moveElementUp.bind(this, n)
29523
29532
  // eslint-disable-next-line react/jsx-no-bind
29524
29533
  ,
29525
29534
  onDown:
29526
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29535
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29527
29536
  n === this.props.elements.length - 1 ? null :
29528
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29537
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29529
29538
  this._moveElementDown.bind(
29530
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29539
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29531
29540
  this, n)
29532
29541
  // eslint-disable-next-line react/jsx-no-bind
29533
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29542
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29534
29543
  ,
29535
29544
  onDelete: this._deleteElement.bind(this, n),
29536
29545
  key: element.key
29537
29546
  }, /*#__PURE__*/React.createElement(LineEditor, _extends({}, element.options, {
29538
29547
  onChange: newProps => {
29539
29548
  const elements = JSON.parse(JSON.stringify(
29540
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29549
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29541
29550
  this.props.elements));
29542
29551
  _.extend(elements[n].options, newProps);
29543
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29552
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29544
29553
  this.change({
29545
29554
  elements: elements
29546
29555
  });
@@ -29553,28 +29562,28 @@ class InteractionEditor extends React.Component {
29553
29562
  // eslint-disable-next-line react/jsx-no-bind
29554
29563
  ,
29555
29564
  onUp: n === 0 ? null :
29556
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29565
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29557
29566
  this._moveElementUp.bind(this, n)
29558
29567
  // eslint-disable-next-line react/jsx-no-bind
29559
29568
  ,
29560
29569
  onDown:
29561
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29570
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29562
29571
  n === this.props.elements.length - 1 ? null :
29563
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29572
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29564
29573
  this._moveElementDown.bind(
29565
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29574
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29566
29575
  this, n)
29567
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29576
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29568
29577
  ,
29569
29578
  onDelete: this._deleteElement,
29570
29579
  key: element.key
29571
29580
  }, /*#__PURE__*/React.createElement(FunctionEditor, _extends({}, element.options, {
29572
29581
  onChange: newProps => {
29573
29582
  const elements = JSON.parse(JSON.stringify(
29574
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29583
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29575
29584
  this.props.elements));
29576
29585
  _.extend(elements[n].options, newProps);
29577
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29586
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29578
29587
  this.change({
29579
29588
  elements: elements
29580
29589
  });
@@ -29587,28 +29596,28 @@ class InteractionEditor extends React.Component {
29587
29596
  // eslint-disable-next-line react/jsx-no-bind
29588
29597
  ,
29589
29598
  onUp: n === 0 ? null :
29590
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29599
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29591
29600
  this._moveElementUp.bind(this, n)
29592
29601
  // eslint-disable-next-line react/jsx-no-bind
29593
29602
  ,
29594
29603
  onDown:
29595
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29604
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29596
29605
  n === this.props.elements.length - 1 ? null :
29597
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29606
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29598
29607
  this._moveElementDown.bind(
29599
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29608
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29600
29609
  this, n)
29601
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29610
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29602
29611
  ,
29603
29612
  onDelete: this._deleteElement,
29604
29613
  key: element.key
29605
29614
  }, /*#__PURE__*/React.createElement(ParametricEditor, _extends({}, element.options, {
29606
29615
  onChange: newProps => {
29607
29616
  const elements = JSON.parse(JSON.stringify(
29608
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29617
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29609
29618
  this.props.elements));
29610
29619
  _.extend(elements[n].options, newProps);
29611
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29620
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29612
29621
  this.change({
29613
29622
  elements: elements
29614
29623
  });
@@ -29621,28 +29630,28 @@ class InteractionEditor extends React.Component {
29621
29630
  // eslint-disable-next-line react/jsx-no-bind
29622
29631
  ,
29623
29632
  onUp: n === 0 ? null :
29624
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29633
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29625
29634
  this._moveElementUp.bind(this, n)
29626
29635
  // eslint-disable-next-line react/jsx-no-bind
29627
29636
  ,
29628
29637
  onDown:
29629
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29638
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29630
29639
  n === this.props.elements.length - 1 ? null :
29631
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29640
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29632
29641
  this._moveElementDown.bind(
29633
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29642
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29634
29643
  this, n)
29635
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29644
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29636
29645
  ,
29637
29646
  onDelete: this._deleteElement,
29638
29647
  key: element.key
29639
29648
  }, /*#__PURE__*/React.createElement(LabelEditor, _extends({}, element.options, {
29640
29649
  onChange: newProps => {
29641
29650
  const elements = JSON.parse(JSON.stringify(
29642
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29651
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29643
29652
  this.props.elements));
29644
29653
  _.extend(elements[n].options, newProps);
29645
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29654
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29646
29655
  this.change({
29647
29656
  elements: elements
29648
29657
  });
@@ -29655,28 +29664,28 @@ class InteractionEditor extends React.Component {
29655
29664
  // eslint-disable-next-line react/jsx-no-bind
29656
29665
  ,
29657
29666
  onUp: n === 0 ? null :
29658
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29667
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation. | TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29659
29668
  this._moveElementUp.bind(this, n)
29660
29669
  // eslint-disable-next-line react/jsx-no-bind
29661
29670
  ,
29662
29671
  onDown:
29663
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29672
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29664
29673
  n === this.props.elements.length - 1 ? null :
29665
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29674
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29666
29675
  this._moveElementDown.bind(
29667
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29676
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29668
29677
  this, n)
29669
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29678
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29670
29679
  ,
29671
29680
  onDelete: this._deleteElement,
29672
29681
  key: element.key
29673
29682
  }, /*#__PURE__*/React.createElement(RectangleEditor, _extends({}, element.options, {
29674
29683
  onChange: newProps => {
29675
29684
  const elements = JSON.parse(JSON.stringify(
29676
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29685
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29677
29686
  this.props.elements));
29678
29687
  _.extend(elements[n].options, newProps);
29679
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29688
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29680
29689
  this.change({
29681
29690
  elements: elements
29682
29691
  });
@@ -29872,7 +29881,7 @@ class InteractiveGraphEditor extends React.Component {
29872
29881
  trackInteraction: function () {},
29873
29882
  onChange: newProps => {
29874
29883
  let correct = this.props.correct;
29875
- // @ts-expect-error [FEI-5003] - TS2532 - Object is possibly 'undefined'.
29884
+ // @ts-expect-error - TS2532 - Object is possibly 'undefined'.
29876
29885
  if (correct.type === newProps.graph.type) {
29877
29886
  correct = _.extend({}, correct, newProps.graph);
29878
29887
  } else {
@@ -29889,7 +29898,7 @@ class InteractiveGraphEditor extends React.Component {
29889
29898
  // There are a bunch of props that renderer.jsx passes to widgets via
29890
29899
  // getWidgetProps() and widget-container.jsx that the editors don't
29891
29900
  // bother passing.
29892
- // @ts-expect-error [FEI-5003] - TS2769 - No overload matches this call.
29901
+ // @ts-expect-error - TS2769 - No overload matches this call.
29893
29902
  React.createElement(InteractiveGraph, _extends({}, graphProps, {
29894
29903
  containerSizeClass: sizeClass,
29895
29904
  apiOptions: _extends({}, this.props.apiOptions, {
@@ -29898,7 +29907,7 @@ class InteractiveGraphEditor extends React.Component {
29898
29907
  }));
29899
29908
  // TODO(kevinb): Update getEquationString to only accept the data it actually
29900
29909
  // needs to compute the equation string.
29901
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type '{ readonly ref: "graph"; readonly box: any; readonly range: any; readonly labels: any; readonly step: any; readonly gridStep: any; readonly snapStep: any; readonly graph: any; readonly backgroundImage: any; ... 6 more ...; readonly onChange: (newProps: Pick<...> & ... 1 more ... & InexactPartial<...>) => void; }' is not assignable to parameter of type 'Props'.
29910
+ // @ts-expect-error - TS2345 - Argument of type '{ readonly ref: "graph"; readonly box: any; readonly range: any; readonly labels: any; readonly step: any; readonly gridStep: any; readonly snapStep: any; readonly graph: any; readonly backgroundImage: any; ... 6 more ...; readonly onChange: (newProps: Pick<...> & ... 1 more ... & InexactPartial<...>) => void; }' is not assignable to parameter of type 'Props'.
29902
29911
  equationString = InteractiveGraph.getEquationString(graphProps);
29903
29912
  } else {
29904
29913
  graph = /*#__PURE__*/React.createElement("div", {
@@ -30076,7 +30085,7 @@ class InteractiveGraphEditor extends React.Component {
30076
30085
  });
30077
30086
  _.each(["allowReflexAngles", "angleOffsetDeg", "numPoints", "numSides", "numSegments", "showAngles", "showSides", "snapTo", "snapDegrees"], function (key) {
30078
30087
  if (_.has(correct, key)) {
30079
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'graph' does not exist on type 'Pick<any, "step" | "range" | "backgroundImage" | "snapStep" | "labels" | "showTooltips" | "markings" | "gridStep" | "showProtractor" | "showRuler" | "rulerLabel" | "rulerTicks">'.
30088
+ // @ts-expect-error - TS2339 - Property 'graph' does not exist on type 'Pick<any, "step" | "range" | "backgroundImage" | "snapStep" | "labels" | "showTooltips" | "markings" | "gridStep" | "showProtractor" | "showRuler" | "rulerLabel" | "rulerTicks">'.
30080
30089
  json.graph[key] = correct[key];
30081
30090
  }
30082
30091
  });
@@ -30181,7 +30190,7 @@ class FormWrappedTextField extends React.Component {
30181
30190
  return /*#__PURE__*/React.createElement("form", {
30182
30191
  className: css(...spanStyle),
30183
30192
  style: extraStyles
30184
- // @ts-expect-error [FEI-5003] - TS2322 - Type '((arg1: ChangeEvent<HTMLInputElement>) => unknown) | ((e: Event) => void)' is not assignable to type 'FormEventHandler<HTMLFormElement> | undefined'.
30193
+ // @ts-expect-error - TS2322 - Type '((arg1: ChangeEvent<HTMLInputElement>) => unknown) | ((e: Event) => void)' is not assignable to type 'FormEventHandler<HTMLFormElement> | undefined'.
30185
30194
  ,
30186
30195
  onSubmit: onSubmit || this.disableDefault
30187
30196
  }, leftSideIcon && wrappedIcon, /*#__PURE__*/React.createElement("input", _extends({}, allProps, {
@@ -30593,7 +30602,7 @@ class HoverBehavior extends React.Component {
30593
30602
  };
30594
30603
  }
30595
30604
 
30596
- // @ts-expect-error [FEI-5003] - TS2564 - Property 'focusFlag' has no initializer and is not definitely assigned in the constructor.
30605
+ // @ts-expect-error - TS2564 - Property 'focusFlag' has no initializer and is not definitely assigned in the constructor.
30597
30606
 
30598
30607
  render() {
30599
30608
  const handlers = {
@@ -30682,7 +30691,7 @@ class Checkbox extends React.Component {
30682
30691
  className: css(styles$6.checkbox, disabled && styles$6.defaultCursor),
30683
30692
  disabled: disabled,
30684
30693
  onChange: onChange
30685
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'string | number | undefined' is not assignable to type 'number | undefined'.
30694
+ // @ts-expect-error - TS2322 - Type 'string | number | undefined' is not assignable to type 'number | undefined'.
30686
30695
  ,
30687
30696
  tabIndex: tabIndex
30688
30697
  })));
@@ -30823,7 +30832,7 @@ function focusWithChromeStickyFocusBugWorkaround(element) {
30823
30832
  // this is an issue, however, so there isn't currently a way to out of the
30824
30833
  // `preventScroll` behavior.
30825
30834
 
30826
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'Element'.
30835
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'Element'.
30827
30836
  element.focus({
30828
30837
  preventScroll: true
30829
30838
  });
@@ -30838,7 +30847,7 @@ const {
30838
30847
  const findAndFocusElement = component => {
30839
30848
  const DOMNode = ReactDOM__default.findDOMNode(component);
30840
30849
  const button = DOMNode;
30841
- // @ts-expect-error [FEI-5003] - TS2774 - This condition will always return true since this function is always defined. Did you mean to call it instead?
30850
+ // @ts-expect-error - TS2774 - This condition will always return true since this function is always defined. Did you mean to call it instead?
30842
30851
  if (button.focus) {
30843
30852
  focusWithChromeStickyFocusBugWorkaround(button);
30844
30853
  }
@@ -30889,21 +30898,21 @@ class Option extends React.Component {
30889
30898
  ariaLabel
30890
30899
  } = this.props;
30891
30900
  return /*#__PURE__*/React.createElement("button", {
30892
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'HTMLButtonElement | null' is not assignable to type 'HTMLDivElement'.
30901
+ // @ts-expect-error - TS2322 - Type 'HTMLButtonElement | null' is not assignable to type 'HTMLDivElement'.
30893
30902
  ref: node => this.node = node,
30894
30903
  value: value,
30895
30904
  role: "menuitemradio",
30896
30905
  "aria-checked": selected,
30897
30906
  className: css(styles$4.notAButton, disabled && styles$4.cursorDefault, hideFocusState && styles$4.noFocus)
30898
- // @ts-expect-error [FEI-5003] - TS2322 - Type '(value: string) => void' is not assignable to type 'MouseEventHandler<HTMLButtonElement>'.
30907
+ // @ts-expect-error - TS2322 - Type '(value: string) => void' is not assignable to type 'MouseEventHandler<HTMLButtonElement>'.
30899
30908
  ,
30900
30909
  onClick: value => {
30901
30910
  if (!disabled && onClick) {
30902
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 0 arguments, but got 1.
30911
+ // @ts-expect-error - TS2554 - Expected 0 arguments, but got 1.
30903
30912
  onClick(value);
30904
30913
  }
30905
30914
  }
30906
- // @ts-expect-error [FEI-5003] - TS2322 - Type '(event: KeyboardEvent) => void' is not assignable to type 'KeyboardEventHandler<HTMLButtonElement>'.
30915
+ // @ts-expect-error - TS2322 - Type '(event: KeyboardEvent) => void' is not assignable to type 'KeyboardEventHandler<HTMLButtonElement>'.
30907
30916
  ,
30908
30917
  onKeyDown: event => this.handleKeyDown(event),
30909
30918
  "aria-disabled": disabled,
@@ -30951,21 +30960,21 @@ class OptionGroup extends React.Component {
30951
30960
  hideFocusState
30952
30961
  } = this.props;
30953
30962
  return /*#__PURE__*/React.createElement("div", {
30954
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'Window | null' is not assignable to type 'Top<string | number> | undefined'.
30963
+ // @ts-expect-error - TS2322 - Type 'Window | null' is not assignable to type 'Top<string | number> | undefined'.
30955
30964
  style: {
30956
30965
  top
30957
30966
  },
30958
30967
  className: css(styles$4.optionGroup, noMargin && styles$4.optionGroupNoMargin)
30959
30968
  }, React.Children.map(children, (child, index) => {
30960
- // @ts-expect-error [FEI-5003] - TS2532 - Object is possibly 'undefined'.
30969
+ // @ts-expect-error - TS2532 - Object is possibly 'undefined'.
30961
30970
  const selected = selectedValues.includes(child.props.value);
30962
30971
  const reference = selected || index === 0 ? node => this.focusedElement = node : null;
30963
30972
 
30964
- // @ts-expect-error [FEI-5003] - TS2769 - No overload matches this call.
30973
+ // @ts-expect-error - TS2769 - No overload matches this call.
30965
30974
  return /*#__PURE__*/React.cloneElement(child, _extends({}, child.props, {
30966
30975
  key: index,
30967
30976
  selected: selected,
30968
- // @ts-expect-error [FEI-5003] - TS2532 - Object is possibly 'undefined'.
30977
+ // @ts-expect-error - TS2532 - Object is possibly 'undefined'.
30969
30978
  onClick: () => onSelected(child.props.value),
30970
30979
  optionRenderer: optionRenderer,
30971
30980
  ref: reference,
@@ -31155,7 +31164,7 @@ class Marker extends React.Component {
31155
31164
  }), /*#__PURE__*/React.createElement(OptionGroup, {
31156
31165
  onSelected: this.handleSelectAnswer
31157
31166
  // TODO(WB-1096): make selectedValues immutable in wonder-blocks
31158
- // @ts-expect-error [FEI-5003] - TS2769 - No overload matches this call.
31167
+ // @ts-expect-error - TS2769 - No overload matches this call.
31159
31168
  ,
31160
31169
  selectedValues: answers
31161
31170
  }, choices.map(choice => /*#__PURE__*/React.createElement(Option, {
@@ -31283,7 +31292,7 @@ class QuestionMarkers extends React.Component {
31283
31292
  // Open answer selection dropdown for each of the specified markers.
31284
31293
  indices.forEach(index => {
31285
31294
  if (this._markers[index]) {
31286
- // @ts-expect-error [FEI-5003] - TS2533 - Object is possibly 'null' or 'undefined'.
31295
+ // @ts-expect-error - TS2533 - Object is possibly 'null' or 'undefined'.
31287
31296
  this._markers[index].openDropdown();
31288
31297
  }
31289
31298
  });
@@ -31690,7 +31699,7 @@ class LightsPuzzleEditor extends React.Component {
31690
31699
  return Changeable.change.apply(this, args);
31691
31700
  };
31692
31701
  this._handlePatternChange = e => {
31693
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
31702
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
31694
31703
  this.change("flipPattern", e.target.value);
31695
31704
  };
31696
31705
  this._changeWidth = newWidth => {
@@ -31709,7 +31718,7 @@ class LightsPuzzleEditor extends React.Component {
31709
31718
  });
31710
31719
  });
31711
31720
 
31712
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
31721
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
31713
31722
  this.change({
31714
31723
  startCells: newCells
31715
31724
  });
@@ -31719,7 +31728,7 @@ class LightsPuzzleEditor extends React.Component {
31719
31728
  return y === tileY && x === tileX;
31720
31729
  });
31721
31730
 
31722
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
31731
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
31723
31732
  this.change({
31724
31733
  startCells: newCells
31725
31734
  });
@@ -31739,7 +31748,7 @@ class LightsPuzzleEditor extends React.Component {
31739
31748
  onChange: this._changeHeight
31740
31749
  })), /*#__PURE__*/React.createElement("div", null, "Flip pattern:", /*#__PURE__*/React.createElement("select", {
31741
31750
  value: this.props.flipPattern
31742
- // @ts-expect-error [FEI-5003] - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
31751
+ // @ts-expect-error - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
31743
31752
  ,
31744
31753
  onChange: this._handlePatternChange
31745
31754
  }, _.map(_.keys(PATTERNS), (pattern, i) => {
@@ -31943,7 +31952,7 @@ class MatrixEditor extends React.Component {
31943
31952
  content: this.props.prefix,
31944
31953
  widgetEnabled: false,
31945
31954
  onChange: newProps => {
31946
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
31955
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
31947
31956
  this.change({
31948
31957
  prefix: newProps.content
31949
31958
  });
@@ -31958,7 +31967,7 @@ class MatrixEditor extends React.Component {
31958
31967
  content: this.props.suffix,
31959
31968
  widgetEnabled: false,
31960
31969
  onChange: newProps => {
31961
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
31970
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
31962
31971
  this.change({
31963
31972
  suffix: newProps.content
31964
31973
  });
@@ -32012,7 +32021,7 @@ class MeasurerEditor extends React.Component {
32012
32021
  this._changeImage = (subProp, newValue) => {
32013
32022
  const image = _.clone(this.props.image);
32014
32023
  image[subProp] = newValue;
32015
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
32024
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
32016
32025
  this.change("image", image);
32017
32026
  };
32018
32027
  this.renderLabelChoices = choices => {
@@ -32057,7 +32066,7 @@ class MeasurerEditor extends React.Component {
32057
32066
  value: image.left,
32058
32067
  useArrowKeys: true
32059
32068
  }))), /*#__PURE__*/React.createElement("div", null, "Containing area [width, height]:", " ", /*#__PURE__*/React.createElement(RangeInput$2
32060
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
32069
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
32061
32070
  , {
32062
32071
  onChange: this.change("box"),
32063
32072
  value: this.props.box,
@@ -32078,7 +32087,7 @@ class MeasurerEditor extends React.Component {
32078
32087
  onChange: this.props.onChange
32079
32088
  }))), this.props.showRuler && /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, " ", "Ruler label:", " ", /*#__PURE__*/React.createElement("select", {
32080
32089
  onChange: e =>
32081
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
32090
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
32082
32091
  this.change("rulerLabel", e.target.value),
32083
32092
  value: this.props.rulerLabel
32084
32093
  }, /*#__PURE__*/React.createElement("option", {
@@ -32089,7 +32098,7 @@ class MeasurerEditor extends React.Component {
32089
32098
  label: "Imperial"
32090
32099
  }, this.renderLabelChoices([["inches", "in"], ["feet", "ft"], ["yards", "yd"], ["miles", "mi"]]))))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, " ", "Ruler ticks:", " ", /*#__PURE__*/React.createElement("select", {
32091
32100
  onChange: e =>
32092
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
32101
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
32093
32102
  this.change("rulerTicks", +e.target.value),
32094
32103
  value: this.props.rulerTicks
32095
32104
  }, _.map([1, 2, 4, 8, 10, 16], function (n) {
@@ -32099,14 +32108,14 @@ class MeasurerEditor extends React.Component {
32099
32108
  }, n);
32100
32109
  })))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, "Ruler pixels per unit:", " ", /*#__PURE__*/React.createElement(NumberInput$9, {
32101
32110
  placeholder: 40
32102
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
32111
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
32103
32112
  ,
32104
32113
  onChange: this.change("rulerPixels"),
32105
32114
  value: this.props.rulerPixels,
32106
32115
  useArrowKeys: true
32107
32116
  }))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, "Ruler length in units:", " ", /*#__PURE__*/React.createElement(NumberInput$9, {
32108
32117
  placeholder: 10
32109
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
32118
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
32110
32119
  ,
32111
32120
  onChange: this.change("rulerLength"),
32112
32121
  value: this.props.rulerLength,
@@ -32151,13 +32160,13 @@ class MoleculeWidgetEditor extends React.Component {
32151
32160
  return Changeable.change.apply(this, args);
32152
32161
  };
32153
32162
  this.updateMolecule = newValue => {
32154
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
32163
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
32155
32164
  this.change({
32156
32165
  smiles: newValue
32157
32166
  });
32158
32167
  };
32159
32168
  this.updateRotation = newValue => {
32160
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
32169
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
32161
32170
  this.change({
32162
32171
  rotationAngle: newValue
32163
32172
  });
@@ -32318,7 +32327,7 @@ class NumberLineEditor extends React.Component {
32318
32327
  className: "perseus-widget-row"
32319
32328
  }, "Correct x", " ", /*#__PURE__*/React.createElement("select", {
32320
32329
  value: this.props.correctRel
32321
- // @ts-expect-error [FEI-5003] - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
32330
+ // @ts-expect-error - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
32322
32331
  ,
32323
32332
  onChange: this.onChangeRelation
32324
32333
  }, /*#__PURE__*/React.createElement("option", {
@@ -32817,14 +32826,14 @@ const NumericInputEditor = createReactClass({
32817
32826
  // TODO(emily): This doesn't actually work, because the value is either
32818
32827
  // null or undefined when undefined, probably.
32819
32828
  if (_.contains(_.pluck(this.props.answers, "value"), "")) {
32820
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'string' is not assignable to parameter of type 'never'.
32829
+ // @ts-expect-error - TS2345 - Argument of type 'string' is not assignable to parameter of type 'never'.
32821
32830
  warnings.push("One or more answers is empty");
32822
32831
  }
32823
32832
  this.props.answers.forEach((answer, i) => {
32824
32833
  const formatError = answer.strict && (!answer.answerForms || answer.answerForms.length === 0);
32825
32834
  if (formatError) {
32826
32835
  warnings.push(
32827
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'string' is not assignable to parameter of type 'never'.
32836
+ // @ts-expect-error - TS2345 - Argument of type 'string' is not assignable to parameter of type 'never'.
32828
32837
  `Answer ${i + 1} is set to string format ` + "matching, but no format was selected");
32829
32838
  }
32830
32839
  });
@@ -32911,7 +32920,7 @@ class OrdererEditor extends React.Component {
32911
32920
  layout: this.props.layout
32912
32921
  }), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, " ", "Layout:", " ", /*#__PURE__*/React.createElement("select", {
32913
32922
  value: this.props.layout
32914
- // @ts-expect-error [FEI-5003] - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
32923
+ // @ts-expect-error - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
32915
32924
  ,
32916
32925
  onChange: this.onLayoutChange
32917
32926
  }, /*#__PURE__*/React.createElement("option", {
@@ -32920,7 +32929,7 @@ class OrdererEditor extends React.Component {
32920
32929
  value: VERTICAL$1
32921
32930
  }, "Vertical"))), /*#__PURE__*/React.createElement(InfoTip$8, null, /*#__PURE__*/React.createElement("p", null, "Use the horizontal layout for short text and small images. The vertical layout is best for longer text (e.g. proofs)."))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, " ", "Height:", " ", /*#__PURE__*/React.createElement("select", {
32922
32931
  value: this.props.height
32923
- // @ts-expect-error [FEI-5003] - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
32932
+ // @ts-expect-error - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
32924
32933
  ,
32925
32934
  onChange: this.onHeightChange
32926
32935
  }, /*#__PURE__*/React.createElement("option", {
@@ -32973,7 +32982,7 @@ class PassageEditor extends React.Component {
32973
32982
  widgetEnabled: false,
32974
32983
  placeholder: "Type passage here...",
32975
32984
  onChange: newProps => {
32976
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
32985
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
32977
32986
  this.change({
32978
32987
  passageText: newProps.content
32979
32988
  });
@@ -32989,7 +32998,7 @@ class PassageEditor extends React.Component {
32989
32998
  widgetEnabled: false,
32990
32999
  placeholder: "Type footnotes here...",
32991
33000
  onChange: newProps => {
32992
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
33001
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
32993
33002
  this.change({
32994
33003
  footnotes: newProps.content
32995
33004
  });
@@ -33008,7 +33017,7 @@ class PassageEditor extends React.Component {
33008
33017
  type: "text",
33009
33018
  defaultValue: this.props.passageTitle,
33010
33019
  onChange: e => {
33011
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
33020
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
33012
33021
  this.change({
33013
33022
  passageTitle: e.target.value
33014
33023
  });
@@ -33048,17 +33057,17 @@ class PassageRefEditor extends React.Component {
33048
33057
  render() {
33049
33058
  return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, "Passage Number: ", /*#__PURE__*/React.createElement(NumberInput$5, {
33050
33059
  value: this.props.passageNumber
33051
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
33060
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
33052
33061
  ,
33053
33062
  onChange: this.change("passageNumber")
33054
33063
  }))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, "Reference Number: ", /*#__PURE__*/React.createElement(NumberInput$5, {
33055
33064
  value: this.props.referenceNumber
33056
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
33065
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
33057
33066
  ,
33058
33067
  onChange: this.change("referenceNumber")
33059
33068
  }))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, "Summary Text: ", /*#__PURE__*/React.createElement(TextInput$2, {
33060
33069
  value: this.props.summaryText
33061
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
33070
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
33062
33071
  ,
33063
33072
  onChange: this.change("summaryText")
33064
33073
  }), /*#__PURE__*/React.createElement(InfoTip$6, null, /*#__PURE__*/React.createElement("p", null, "Short summary of the referenced section. This will be included in parentheses and quotes automatically."), /*#__PURE__*/React.createElement("p", null, "Ex: The start ... the end")))));
@@ -33083,7 +33092,7 @@ class PassageRefTargetEditor extends React.Component {
33083
33092
  return Changeable.change.apply(this, args);
33084
33093
  };
33085
33094
  this.handleContentChange = e => {
33086
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
33095
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
33087
33096
  this.change({
33088
33097
  content: e.target.value
33089
33098
  });
@@ -33208,7 +33217,7 @@ class PlotterEditor extends React.Component {
33208
33217
  if (categories) {
33209
33218
  // eslint-disable-next-line react/no-string-refs
33210
33219
  const node = ReactDOM__default.findDOMNode(this.refs.categories);
33211
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
33220
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
33212
33221
  node.value = categories.join(", ");
33213
33222
  }
33214
33223
  };
@@ -33255,7 +33264,7 @@ class PlotterEditor extends React.Component {
33255
33264
  starting: _.map(this.props.starting, scale)
33256
33265
  });
33257
33266
 
33258
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
33267
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
33259
33268
  ReactDOM__default.findDOMNode(this.refs.maxY).value = maxY; // eslint-disable-line react/no-string-refs
33260
33269
  };
33261
33270
  this.changeMax = e => {
@@ -33292,13 +33301,13 @@ class PlotterEditor extends React.Component {
33292
33301
  // eslint-disable-next-line react/no-string-refs
33293
33302
  const node = ReactDOM__default.findDOMNode(this.refs.categories);
33294
33303
 
33295
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
33304
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
33296
33305
  node.value = categories.join(", ");
33297
33306
  };
33298
33307
  this.serialize = () => {
33299
33308
  const json = _.pick(this.props, "correct", "starting", "type", "labels", "categories", "scaleY", "maxY", "snapsPerLine", "labelInterval");
33300
33309
  if (this.props.type === PIC) {
33301
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'picUrl' does not exist on type 'Pick<Readonly<any> & Readonly<{ children?: ReactNode; }>, "type" | "correct" | "labels" | "categories" | "starting" | "scaleY" | "maxY" | "snapsPerLine" | "labelInterval">'.
33310
+ // @ts-expect-error - TS2339 - Property 'picUrl' does not exist on type 'Pick<Readonly<any> & Readonly<{ children?: ReactNode; }>, "type" | "correct" | "labels" | "categories" | "starting" | "scaleY" | "maxY" | "snapsPerLine" | "labelInterval">'.
33302
33311
  json.picUrl = this.props.picUrl;
33303
33312
  }
33304
33313
  return json;
@@ -33492,7 +33501,7 @@ class RadioEditor extends React.Component {
33492
33501
  constructor(..._args) {
33493
33502
  super(..._args);
33494
33503
  this.change = (...args) => {
33495
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'readonly unknown[]' is not assignable to parameter of type 'any[]'.
33504
+ // @ts-expect-error - TS2345 - Argument of type 'readonly unknown[]' is not assignable to parameter of type 'any[]'.
33496
33505
  return Changeable.change.apply(this, args);
33497
33506
  };
33498
33507
  this.onMultipleSelectChange = allowMultiple => {
@@ -33578,7 +33587,7 @@ class RadioEditor extends React.Component {
33578
33587
  hasNoneOfTheAbove: noneOfTheAbove || this.props.hasNoneOfTheAbove
33579
33588
  }, () => {
33580
33589
  // eslint-disable-next-line react/no-string-refs
33581
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'refs' does not exist on type 'ReactInstance'.
33590
+ // @ts-expect-error - TS2339 - Property 'refs' does not exist on type 'ReactInstance'.
33582
33591
  this.refs[`choice-editor${addIndex}`].refs["content-editor"].focus();
33583
33592
  });
33584
33593
  };
@@ -33589,7 +33598,7 @@ class RadioEditor extends React.Component {
33589
33598
  };
33590
33599
  this.focus = () => {
33591
33600
  // eslint-disable-next-line react/no-string-refs
33592
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'refs' does not exist on type 'ReactInstance'.
33601
+ // @ts-expect-error - TS2339 - Property 'refs' does not exist on type 'ReactInstance'.
33593
33602
  this.refs["choice-editor0"].refs["content-editor"].focus();
33594
33603
  return true;
33595
33604
  };
@@ -33724,10 +33733,10 @@ class ReactionDiagramWidgetEditor extends React.Component {
33724
33733
  };
33725
33734
  this.updateMolecule = idx => {
33726
33735
  return function (newValue) {
33727
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33736
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33728
33737
  const newSmiles = [...this.props.smiles];
33729
33738
  newSmiles[idx] = newValue;
33730
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33739
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33731
33740
  this.change({
33732
33741
  smiles: newSmiles
33733
33742
  });
@@ -33735,10 +33744,10 @@ class ReactionDiagramWidgetEditor extends React.Component {
33735
33744
  };
33736
33745
  this.updateRotation = idx => {
33737
33746
  return function (newValue) {
33738
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33747
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33739
33748
  const newRot = [...this.props.rotationAngle];
33740
33749
  newRot[idx] = newValue;
33741
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33750
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33742
33751
  this.change({
33743
33752
  rotationAngle: newRot
33744
33753
  });
@@ -33750,7 +33759,7 @@ class ReactionDiagramWidgetEditor extends React.Component {
33750
33759
  return _extends({}, sep);
33751
33760
  });
33752
33761
  newSep[idx][propName] = newValue;
33753
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
33762
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
33754
33763
  this.change({
33755
33764
  separators: newSep
33756
33765
  });
@@ -33836,7 +33845,7 @@ class SequenceEditor extends React.Component {
33836
33845
  return {
33837
33846
  json: _.times(this.props.json.length, i => {
33838
33847
  // eslint-disable-next-line react/no-string-refs
33839
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
33848
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
33840
33849
  return this.refs["editor" + i].serialize();
33841
33850
  })
33842
33851
  };
@@ -33961,7 +33970,7 @@ class TextArea extends React.Component {
33961
33970
  super(...args);
33962
33971
  this.focus = () => {
33963
33972
  // eslint-disable-next-line react/no-string-refs
33964
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
33973
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
33965
33974
  this.refs.input.focus();
33966
33975
  return true;
33967
33976
  };
@@ -33988,7 +33997,7 @@ class SimpleMarkdownTesterEditor extends React.Component {
33988
33997
  };
33989
33998
  this.focus = () => {
33990
33999
  // eslint-disable-next-line react/no-string-refs
33991
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
34000
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
33992
34001
  this.refs.input.focus();
33993
34002
  return true;
33994
34003
  };
@@ -33999,7 +34008,7 @@ class SimpleMarkdownTesterEditor extends React.Component {
33999
34008
  render() {
34000
34009
  return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, /*#__PURE__*/React.createElement("div", null, "Simple markdown contents:"), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(TextArea, {
34001
34010
  value: this.props.value
34002
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
34011
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
34003
34012
  ,
34004
34013
  onChange: this.change("value")
34005
34014
  // eslint-disable-next-line react/no-string-refs
@@ -34023,7 +34032,7 @@ class SimulatorEditor extends React.Component {
34023
34032
  constructor(..._args) {
34024
34033
  super(..._args);
34025
34034
  this.change = (...args) => {
34026
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'readonly unknown[]' is not assignable to parameter of type 'any[]'.
34035
+ // @ts-expect-error - TS2345 - Argument of type 'readonly unknown[]' is not assignable to parameter of type 'any[]'.
34027
34036
  return Changeable.change.apply(this, args);
34028
34037
  };
34029
34038
  this.handleTargetValueChange = (propName, e) => {
@@ -34120,7 +34129,7 @@ class SorterEditor extends React.Component {
34120
34129
  layout: this.props.layout
34121
34130
  }), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, " ", "Layout:", " ", /*#__PURE__*/React.createElement("select", {
34122
34131
  value: this.props.layout
34123
- // @ts-expect-error [FEI-5003] - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
34132
+ // @ts-expect-error - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
34124
34133
  ,
34125
34134
  onChange: this.onLayoutChange
34126
34135
  }, /*#__PURE__*/React.createElement("option", {
@@ -34156,7 +34165,7 @@ class TableEditor extends React.Component {
34156
34165
  constructor(...args) {
34157
34166
  super(...args);
34158
34167
  this.focus = () => {
34159
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2339 - Property 'focus' does not exist on type 'Element | Text'.
34168
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2339 - Property 'focus' does not exist on type 'Element | Text'.
34160
34169
  ReactDOM__default.findDOMNode(this.refs.numberOfColumns).focus(); // eslint-disable-line react/no-string-refs
34161
34170
  };
34162
34171
  this.onSizeInput = (numRawRows, numRawColumns) => {
@@ -34752,7 +34761,7 @@ const ShapeTypes = {
34752
34761
  const coord0 = points[0].coord || points[0];
34753
34762
  const coord1 = points[1].coord || points[1];
34754
34763
  const radius = point.distanceToPoint(coord0, coord1);
34755
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 1 arguments, but got 0.
34764
+ // @ts-expect-error - TS2554 - Expected 1 arguments, but got 0.
34756
34765
  perimeter.remove();
34757
34766
  perimeter = graphie.circle(coord0, radius, _.extend({
34758
34767
  stroke: KhanColors.DYNAMIC,
@@ -34768,7 +34777,7 @@ const ShapeTypes = {
34768
34777
  remove: function () {
34769
34778
  // Not _.bind because the remove function changes
34770
34779
  // when the perimeter is redrawn
34771
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 1 arguments, but got 0.
34780
+ // @ts-expect-error - TS2554 - Expected 1 arguments, but got 0.
34772
34781
  perimeter.remove();
34773
34782
  }
34774
34783
  };
@@ -34807,10 +34816,10 @@ const ShapeTypes = {
34807
34816
  const line2_0 = [points2[1], points2[0]];
34808
34817
  const line2_2 = [points2[1], points2[2]];
34809
34818
  const equalUnflipped =
34810
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'any[]' is not assignable to parameter of type 'Ray'. | TS2345 - Argument of type 'any[]' is not assignable to parameter of type 'Ray'.
34819
+ // @ts-expect-error - TS2345 - Argument of type 'any[]' is not assignable to parameter of type 'Ray'. | TS2345 - Argument of type 'any[]' is not assignable to parameter of type 'Ray'.
34811
34820
  ray.equal(line1_0, line2_0) && ray.equal(line1_2, line2_2);
34812
34821
  const equalFlipped =
34813
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'any[]' is not assignable to parameter of type 'Ray'. | TS2345 - Argument of type 'any[]' is not assignable to parameter of type 'Ray'.
34822
+ // @ts-expect-error - TS2345 - Argument of type 'any[]' is not assignable to parameter of type 'Ray'. | TS2345 - Argument of type 'any[]' is not assignable to parameter of type 'Ray'.
34814
34823
  ray.equal(line1_0, line2_2) && ray.equal(line1_2, line2_0);
34815
34824
  return equalUnflipped || equalFlipped;
34816
34825
  },
@@ -34846,7 +34855,7 @@ class TransformationsShapeEditor extends React.Component {
34846
34855
  const pointCount = arraySum(_.map(types, ShapeTypes.getPointCountForType));
34847
34856
 
34848
34857
  // eslint-disable-next-line react/no-string-refs
34849
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'props' does not exist on type 'ReactInstance'.
34858
+ // @ts-expect-error - TS2339 - Property 'props' does not exist on type 'ReactInstance'.
34850
34859
  const radius = scaleToRange(4, this.refs.graph.props.range);
34851
34860
  const offset = (1 / 2 - 1 / pointCount) * 180;
34852
34861
  const coords = _.times(pointCount, function (i) {
@@ -34862,12 +34871,12 @@ class TransformationsShapeEditor extends React.Component {
34862
34871
  };
34863
34872
  this.updateCoords = () => {
34864
34873
  this.props.onChange({
34865
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'shape' does not exist on type 'TransformationsShapeEditor'.
34874
+ // @ts-expect-error - TS2339 - Property 'shape' does not exist on type 'TransformationsShapeEditor'.
34866
34875
  shape: this.shape.toJSON()
34867
34876
  });
34868
34877
  };
34869
34878
  this.setupGraphie = graphie => {
34870
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'shape' does not exist on type 'TransformationsShapeEditor'.
34879
+ // @ts-expect-error - TS2339 - Property 'shape' does not exist on type 'TransformationsShapeEditor'.
34871
34880
  this.shape = ShapeTypes.addMovableShape(graphie, {
34872
34881
  editable: true,
34873
34882
  snap: graphie.snap,
@@ -34920,13 +34929,13 @@ class TransformationsShapeEditor extends React.Component {
34920
34929
 
34921
34930
  componentDidMount() {
34922
34931
  // eslint-disable-next-line react/no-string-refs
34923
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'graphie' does not exist on type 'ReactInstance'.
34932
+ // @ts-expect-error - TS2339 - Property 'graphie' does not exist on type 'ReactInstance'.
34924
34933
  this.setupGraphie(this.refs.graph.graphie());
34925
34934
  }
34926
34935
  componentDidUpdate(prevProps) {
34927
34936
  if (!deepEq(prevProps.shape, this.props.shape)) {
34928
34937
  // eslint-disable-next-line react/no-string-refs
34929
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'reset' does not exist on type 'ReactInstance'.
34938
+ // @ts-expect-error - TS2339 - Property 'reset' does not exist on type 'ReactInstance'.
34930
34939
  this.refs.graph.reset();
34931
34940
  }
34932
34941
  }
@@ -34957,7 +34966,7 @@ class TransformerEditor extends React.Component {
34957
34966
  };
34958
34967
  this.serialize = () => {
34959
34968
  // eslint-disable-next-line react/no-string-refs
34960
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getEditorJSON' does not exist on type 'ReactInstance'.
34969
+ // @ts-expect-error - TS2339 - Property 'getEditorJSON' does not exist on type 'ReactInstance'.
34961
34970
  const json = this.refs.explorer.getEditorJSON();
34962
34971
  json.correct = json.answer;
34963
34972
  delete json.answer;
@@ -35098,7 +35107,7 @@ class UnitExample extends React.Component {
35098
35107
  }
35099
35108
  // TODO(jangmi, CP-3288): Remove usage of `UNSAFE_componentWillMount`
35100
35109
  UNSAFE_componentWillMount() {
35101
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'Readonly<any> & Readonly<{ children?: ReactNode; }>' is not assignable to parameter of type '{ name: any; original: any; sigfigs: any; }'.
35110
+ // @ts-expect-error - TS2345 - Argument of type 'Readonly<any> & Readonly<{ children?: ReactNode; }>' is not assignable to parameter of type '{ name: any; original: any; sigfigs: any; }'.
35102
35111
  this._checkValidity(this.props);
35103
35112
  }
35104
35113
  UNSAFE_componentWillReceiveProps(nextProps) {
@@ -35129,13 +35138,13 @@ class UnitInputEditor extends React.Component {
35129
35138
  };
35130
35139
  this.handleAcceptingUnitsChange = event => {
35131
35140
  const acceptingUnits = event.target.value.split(",").map(str => str.trim()).filter(str => str !== "");
35132
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
35141
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
35133
35142
  this.change({
35134
35143
  acceptingUnits
35135
35144
  });
35136
35145
  };
35137
35146
  this.handleSigfigChange = sigfigs => {
35138
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
35147
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
35139
35148
  this.change({
35140
35149
  sigfigs
35141
35150
  });
@@ -35144,7 +35153,7 @@ class UnitInputEditor extends React.Component {
35144
35153
  return sigfigs > 0 && sigfigs <= MAX_SIGFIGS;
35145
35154
  };
35146
35155
  this._setAccepting = val => {
35147
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
35156
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
35148
35157
  this.change({
35149
35158
  accepting: val
35150
35159
  });
@@ -35205,7 +35214,7 @@ class UnitInputEditor extends React.Component {
35205
35214
  key: i
35206
35215
  }));
35207
35216
 
35208
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'Element' is not assignable to type 'null'.
35217
+ // @ts-expect-error - TS2322 - Type 'Element' is not assignable to type 'null'.
35209
35218
  acceptingElem = /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("input", {
35210
35219
  type: "text",
35211
35220
  defaultValue: acceptingUnits.join(", "),
@@ -35313,7 +35322,7 @@ class TextInput extends React.Component {
35313
35322
  super(...args);
35314
35323
  this.focus = () => {
35315
35324
  // eslint-disable-next-line react/no-string-refs
35316
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
35325
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
35317
35326
  this.refs.input.focus();
35318
35327
  return true;
35319
35328
  };
@@ -35349,7 +35358,7 @@ class ExampleWidget extends React.Component {
35349
35358
  };
35350
35359
  this.focus = () => {
35351
35360
  // eslint-disable-next-line react/no-string-refs
35352
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
35361
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
35353
35362
  this.refs.input.focus();
35354
35363
  return true;
35355
35364
  };
@@ -35397,7 +35406,7 @@ class ExampleWidget extends React.Component {
35397
35406
  , {
35398
35407
  ref: "input",
35399
35408
  value: this.props.value
35400
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
35409
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
35401
35410
  ,
35402
35411
  onChange: this.change("value")
35403
35412
  });
@@ -35437,7 +35446,7 @@ class SimpleMarkdownTester extends React.Component {
35437
35446
  };
35438
35447
  this.focus = () => {
35439
35448
  // eslint-disable-next-line react/no-string-refs
35440
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
35449
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
35441
35450
  this.refs.input.focus();
35442
35451
  return true;
35443
35452
  };
@@ -35462,7 +35471,7 @@ class SimpleMarkdownTester extends React.Component {
35462
35471
  };
35463
35472
  }
35464
35473
  render() {
35465
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 2 arguments, but got 1.
35474
+ // @ts-expect-error - TS2554 - Expected 2 arguments, but got 1.
35466
35475
  const parsed = mdParse(this.props.value);
35467
35476
  const output = mdOutput(parsed);
35468
35477
  return /*#__PURE__*/React.createElement("div", null, output);