@khanacademy/perseus-editor 2.6.0 → 2.6.2

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 (180) 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 +414 -436
  6. package/dist/es/index.js.map +1 -1
  7. package/dist/index.js +411 -435
  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 +48 -47
  11. package/dist/widgets/plotter-editor.d.ts +47 -23
  12. package/package.json +12 -12
  13. package/src/__stories__/editor.stories.tsx +3 -1
  14. package/src/__tests__/i18n.test.ts +1 -1
  15. package/src/article-editor.tsx +13 -14
  16. package/src/components/checkbox.tsx +2 -1
  17. package/src/components/dropdown-option.tsx +13 -12
  18. package/src/components/form-wrapped-text-field.tsx +5 -2
  19. package/src/components/graph-points-count-selector.tsx +3 -1
  20. package/src/components/graph-settings.tsx +1 -1
  21. package/src/components/hover-behavior.ts +2 -2
  22. package/src/components/json-editor.tsx +2 -2
  23. package/src/components/sortable.tsx +1 -1
  24. package/src/components/util.ts +1 -1
  25. package/src/components/widget-editor.tsx +8 -7
  26. package/src/diffs/__tests__/structured-item-diff.test.ts +8 -8
  27. package/src/diffs/renderer-diff.tsx +3 -3
  28. package/src/diffs/split-diff.ts +2 -2
  29. package/src/diffs/structured-item-diff.tsx +11 -10
  30. package/src/diffs/text-diff.tsx +1 -1
  31. package/src/diffs/widget-diff.tsx +2 -2
  32. package/src/editor-page.tsx +8 -8
  33. package/src/editor.tsx +37 -36
  34. package/src/hint-editor.tsx +28 -27
  35. package/src/i18n.ts +4 -4
  36. package/src/iframe-content-renderer.tsx +10 -10
  37. package/src/item-editor.tsx +4 -4
  38. package/src/katex-mhchem/parser.js +24 -24
  39. package/src/multirenderer-editor.tsx +11 -11
  40. package/src/widgets/__stories__/label-image-editor.stories.tsx +1 -0
  41. package/src/widgets/__stories__/radio-editor.stories.tsx +1 -0
  42. package/src/widgets/categorizer-editor.tsx +3 -3
  43. package/src/widgets/cs-program-editor.tsx +2 -2
  44. package/src/widgets/definition-editor.tsx +3 -2
  45. package/src/widgets/dropdown-editor.tsx +9 -8
  46. package/src/widgets/example-graphie-widget-editor.tsx +1 -1
  47. package/src/widgets/example-graphie-widget.tsx +2 -2
  48. package/src/widgets/example-widget-editor.tsx +2 -2
  49. package/src/widgets/example-widget.tsx +4 -3
  50. package/src/widgets/explanation-editor.tsx +4 -3
  51. package/src/widgets/expression-editor.tsx +9 -9
  52. package/src/widgets/graded-group-editor.tsx +7 -6
  53. package/src/widgets/graded-group-set-editor.tsx +3 -3
  54. package/src/widgets/grapher-editor.tsx +3 -2
  55. package/src/widgets/group-editor.tsx +4 -3
  56. package/src/widgets/iframe-editor.tsx +5 -4
  57. package/src/widgets/input-number-editor.tsx +6 -6
  58. package/src/widgets/interaction-editor.tsx +103 -102
  59. package/src/widgets/interactive-graph-editor.tsx +12 -8
  60. package/src/widgets/label-image/marker.tsx +2 -1
  61. package/src/widgets/label-image/question-markers.tsx +1 -1
  62. package/src/widgets/lights-puzzle-editor.tsx +5 -4
  63. package/src/widgets/matrix-editor.tsx +2 -2
  64. package/src/widgets/measurer-editor.tsx +7 -6
  65. package/src/widgets/molecule-editor.tsx +2 -2
  66. package/src/widgets/number-line-editor.tsx +2 -1
  67. package/src/widgets/numeric-input-editor.tsx +2 -2
  68. package/src/widgets/orderer-editor.tsx +3 -2
  69. package/src/widgets/passage-editor.tsx +3 -3
  70. package/src/widgets/passage-ref-editor.tsx +4 -3
  71. package/src/widgets/passage-ref-target-editor.tsx +1 -1
  72. package/src/widgets/plotter-editor.tsx +253 -243
  73. package/src/widgets/radio/editor.tsx +3 -3
  74. package/src/widgets/reaction-diagram-editor.tsx +5 -5
  75. package/src/widgets/sequence-editor.tsx +1 -1
  76. package/src/widgets/simple-markdown-tester-editor.tsx +4 -3
  77. package/src/widgets/simple-markdown-tester.tsx +2 -2
  78. package/src/widgets/simulator-editor.tsx +1 -1
  79. package/src/widgets/sorter-editor.tsx +2 -1
  80. package/src/widgets/table-editor.tsx +1 -1
  81. package/src/widgets/transformer-editor.tsx +10 -10
  82. package/src/widgets/unit-editor.tsx +5 -5
  83. package/tsconfig-build.tsbuildinfo +1 -1
  84. package/dist/all-editors.js.flow +0 -8
  85. package/dist/all-widgets.js.flow +0 -34
  86. package/dist/article-editor.js.flow +0 -72
  87. package/dist/components/blur-input.js.flow +0 -25
  88. package/dist/components/checkbox.js.flow +0 -26
  89. package/dist/components/device-framer.js.flow +0 -20
  90. package/dist/components/drag-target.js.flow +0 -8
  91. package/dist/components/dropdown-option.js.flow +0 -49
  92. package/dist/components/form-wrapped-text-field.js.flow +0 -45
  93. package/dist/components/graph-points-count-selector.js.flow +0 -12
  94. package/dist/components/graph-settings.js.flow +0 -8
  95. package/dist/components/graph-type-selector.js.flow +0 -12
  96. package/dist/components/hover-behavior.js.flow +0 -48
  97. package/dist/components/json-editor.js.flow +0 -8
  98. package/dist/components/link.js.flow +0 -50
  99. package/dist/components/section-control-button.js.flow +0 -25
  100. package/dist/components/segment-count-selector.js.flow +0 -11
  101. package/dist/components/simple-button.js.flow +0 -18
  102. package/dist/components/sortable.js.flow +0 -8
  103. package/dist/components/util.js.flow +0 -9
  104. package/dist/components/viewport-resizer.js.flow +0 -22
  105. package/dist/components/widget-editor.js.flow +0 -91
  106. package/dist/components/widget-select.js.flow +0 -16
  107. package/dist/diffs/article-diff.js.flow +0 -71
  108. package/dist/diffs/item-diff.js.flow +0 -41
  109. package/dist/diffs/renderer-diff.js.flow +0 -25
  110. package/dist/diffs/split-diff.js.flow +0 -8
  111. package/dist/diffs/string-array-diff.js.flow +0 -11
  112. package/dist/diffs/structured-item-diff.js.flow +0 -37
  113. package/dist/diffs/tags-diff.js.flow +0 -24
  114. package/dist/diffs/text-diff.js.flow +0 -21
  115. package/dist/diffs/widget-diff-performer.js.flow +0 -8
  116. package/dist/diffs/widget-diff.js.flow +0 -31
  117. package/dist/editor-page.js.flow +0 -72
  118. package/dist/editor.js.flow +0 -96
  119. package/dist/hint-editor.js.flow +0 -87
  120. package/dist/i18n.js.flow +0 -13
  121. package/dist/iframe-content-renderer.js.flow +0 -28
  122. package/dist/index.js.flow +0 -23
  123. package/dist/item-editor.js.flow +0 -46
  124. package/dist/item-extras-editor.js.flow +0 -23
  125. package/dist/katex-error-view.js.flow +0 -24
  126. package/dist/multirenderer-editor.js.flow +0 -46
  127. package/dist/stateful-article-editor.js.flow +0 -16
  128. package/dist/stateful-editor-page.js.flow +0 -8
  129. package/dist/testing-widgets.js.flow +0 -34
  130. package/dist/util/points.js.flow +0 -9
  131. package/dist/util/register-all-widgets-and-editors-for-testing.js.flow +0 -7
  132. package/dist/widgets/categorizer-editor.js.flow +0 -62
  133. package/dist/widgets/cs-program-editor.js.flow +0 -25
  134. package/dist/widgets/definition-editor.js.flow +0 -23
  135. package/dist/widgets/dropdown-editor.js.flow +0 -37
  136. package/dist/widgets/example-graphie-widget-editor.js.flow +0 -25
  137. package/dist/widgets/example-graphie-widget.js.flow +0 -102
  138. package/dist/widgets/example-widget-editor.js.flow +0 -26
  139. package/dist/widgets/example-widget.js.flow +0 -86
  140. package/dist/widgets/explanation-editor.js.flow +0 -27
  141. package/dist/widgets/expression-editor.js.flow +0 -43
  142. package/dist/widgets/graded-group-editor.js.flow +0 -68
  143. package/dist/widgets/graded-group-set-editor.js.flow +0 -66
  144. package/dist/widgets/grapher-editor.js.flow +0 -21
  145. package/dist/widgets/group-editor.js.flow +0 -64
  146. package/dist/widgets/iframe-editor.js.flow +0 -24
  147. package/dist/widgets/image-editor.js.flow +0 -8
  148. package/dist/widgets/input-number-editor.js.flow +0 -77
  149. package/dist/widgets/interaction/constraint-editor.js.flow +0 -35
  150. package/dist/widgets/interaction-editor.js.flow +0 -36
  151. package/dist/widgets/interactive-graph-editor.js.flow +0 -5803
  152. package/dist/widgets/label-image/answer-choices.js.flow +0 -16
  153. package/dist/widgets/label-image/behavior.js.flow +0 -17
  154. package/dist/widgets/label-image/marker.js.flow +0 -32
  155. package/dist/widgets/label-image/question-markers.js.flow +0 -23
  156. package/dist/widgets/label-image/select-image.js.flow +0 -13
  157. package/dist/widgets/label-image-editor.js.flow +0 -44
  158. package/dist/widgets/lights-puzzle-editor.js.flow +0 -34
  159. package/dist/widgets/matcher-editor.js.flow +0 -28
  160. package/dist/widgets/matrix-editor.js.flow +0 -26
  161. package/dist/widgets/measurer-editor.js.flow +0 -42
  162. package/dist/widgets/molecule-editor.js.flow +0 -23
  163. package/dist/widgets/number-line-editor.js.flow +0 -45
  164. package/dist/widgets/numeric-input-editor.js.flow +0 -8
  165. package/dist/widgets/orderer-editor.js.flow +0 -30
  166. package/dist/widgets/passage-editor.js.flow +0 -24
  167. package/dist/widgets/passage-ref-editor.js.flow +0 -17
  168. package/dist/widgets/passage-ref-target-editor.js.flow +0 -22
  169. package/dist/widgets/plotter-editor.js.flow +0 -53
  170. package/dist/widgets/radio/editor.js.flow +0 -81
  171. package/dist/widgets/reaction-diagram-editor.js.flow +0 -26
  172. package/dist/widgets/sequence-editor.js.flow +0 -73
  173. package/dist/widgets/simple-markdown-tester-editor.js.flow +0 -23
  174. package/dist/widgets/simple-markdown-tester.js.flow +0 -61
  175. package/dist/widgets/simulator-editor.js.flow +0 -26
  176. package/dist/widgets/sorter-editor.js.flow +0 -22
  177. package/dist/widgets/table-editor.js.flow +0 -24
  178. package/dist/widgets/transformer-editor.js.flow +0 -17
  179. package/dist/widgets/unit-editor.js.flow +0 -41
  180. 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) {
@@ -18371,7 +18371,7 @@ mhchemParser.stateMachines = {
18371
18371
  }
18372
18372
  },
18373
18373
  oxidation$: {
18374
- "0": {
18374
+ 0: {
18375
18375
  action_: "oxidation-output"
18376
18376
  }
18377
18377
  },
@@ -18438,7 +18438,7 @@ mhchemParser.stateMachines = {
18438
18438
  action_: ["output", "d="],
18439
18439
  nextState: "d"
18440
18440
  },
18441
- "3": {
18441
+ 3: {
18442
18442
  action_: ["sb=false", "output", "operator"],
18443
18443
  nextState: "0"
18444
18444
  }
@@ -18532,7 +18532,7 @@ mhchemParser.stateMachines = {
18532
18532
  }],
18533
18533
  nextState: "3"
18534
18534
  },
18535
- "3": {
18535
+ 3: {
18536
18536
  action_: {
18537
18537
  type_: "bond",
18538
18538
  option: "-"
@@ -18632,7 +18632,7 @@ mhchemParser.stateMachines = {
18632
18632
  a: {
18633
18633
  nextState: "as"
18634
18634
  },
18635
- "0": {
18635
+ 0: {
18636
18636
  action_: "sb=false"
18637
18637
  },
18638
18638
  "1|2": {
@@ -19243,12 +19243,12 @@ mhchemParser.stateMachines = {
19243
19243
  "*": {}
19244
19244
  },
19245
19245
  "1/2$": {
19246
- "0": {
19246
+ 0: {
19247
19247
  action_: "1/2"
19248
19248
  }
19249
19249
  },
19250
19250
  else: {
19251
- "0": {
19251
+ 0: {
19252
19252
  nextState: "1",
19253
19253
  revisit: true
19254
19254
  }
@@ -19281,12 +19281,12 @@ mhchemParser.stateMachines = {
19281
19281
  "*": {}
19282
19282
  },
19283
19283
  "1/2$": {
19284
- "0": {
19284
+ 0: {
19285
19285
  action_: "1/2"
19286
19286
  }
19287
19287
  },
19288
19288
  else: {
19289
- "0": {
19289
+ 0: {
19290
19290
  nextState: "1",
19291
19291
  revisit: true
19292
19292
  }
@@ -19387,30 +19387,30 @@ mhchemParser.stateMachines = {
19387
19387
  }
19388
19388
  },
19389
19389
  i$: {
19390
- "0": {
19390
+ 0: {
19391
19391
  nextState: "!f",
19392
19392
  revisit: true
19393
19393
  }
19394
19394
  },
19395
19395
  "(KV letters),": {
19396
- "0": {
19396
+ 0: {
19397
19397
  action_: "rm",
19398
19398
  nextState: "0"
19399
19399
  }
19400
19400
  },
19401
19401
  formula$: {
19402
- "0": {
19402
+ 0: {
19403
19403
  nextState: "f",
19404
19404
  revisit: true
19405
19405
  }
19406
19406
  },
19407
19407
  "1/2$": {
19408
- "0": {
19408
+ 0: {
19409
19409
  action_: "1/2"
19410
19410
  }
19411
19411
  },
19412
19412
  else: {
19413
- "0": {
19413
+ 0: {
19414
19414
  nextState: "!f",
19415
19415
  revisit: true
19416
19416
  }
@@ -19496,19 +19496,19 @@ mhchemParser.stateMachines = {
19496
19496
  "*": {}
19497
19497
  },
19498
19498
  x$: {
19499
- "0": {
19499
+ 0: {
19500
19500
  nextState: "!f",
19501
19501
  revisit: true
19502
19502
  }
19503
19503
  },
19504
19504
  formula$: {
19505
- "0": {
19505
+ 0: {
19506
19506
  nextState: "f",
19507
19507
  revisit: true
19508
19508
  }
19509
19509
  },
19510
19510
  else: {
19511
- "0": {
19511
+ 0: {
19512
19512
  nextState: "!f",
19513
19513
  revisit: true
19514
19514
  }
@@ -19761,13 +19761,13 @@ mhchemParser.stateMachines = {
19761
19761
  }
19762
19762
  },
19763
19763
  "(-)(9)^(-9)": {
19764
- "0": {
19764
+ 0: {
19765
19765
  action_: "number^",
19766
19766
  nextState: "a"
19767
19767
  }
19768
19768
  },
19769
19769
  "(-)(9.,9)(e)(99)": {
19770
- "0": {
19770
+ 0: {
19771
19771
  action_: "enumber",
19772
19772
  nextState: "a"
19773
19773
  }
@@ -19955,16 +19955,16 @@ mhchemParser.stateMachines = {
19955
19955
  }
19956
19956
  },
19957
19957
  "^{(...)}|^(-1)": {
19958
- "1": {
19958
+ 1: {
19959
19959
  action_: "^(-1)"
19960
19960
  }
19961
19961
  },
19962
19962
  "-9.,9": {
19963
- "0": {
19963
+ 0: {
19964
19964
  action_: "rm=",
19965
19965
  nextState: "0"
19966
19966
  },
19967
- "1": {
19967
+ 1: {
19968
19968
  action_: "^(-1)",
19969
19969
  nextState: "0"
19970
19970
  }
@@ -20014,7 +20014,7 @@ mhchemParser.stateMachines = {
20014
20014
  "pu-9,9": {
20015
20015
  transitions: mhchemParser.createTransitions({
20016
20016
  empty: {
20017
- "0": {
20017
+ 0: {
20018
20018
  action_: "output-0"
20019
20019
  },
20020
20020
  o: {
@@ -20022,13 +20022,13 @@ mhchemParser.stateMachines = {
20022
20022
  }
20023
20023
  },
20024
20024
  ",": {
20025
- "0": {
20025
+ 0: {
20026
20026
  action_: ["output-0", "comma"],
20027
20027
  nextState: "o"
20028
20028
  }
20029
20029
  },
20030
20030
  ".": {
20031
- "0": {
20031
+ 0: {
20032
20032
  action_: ["output-0", "copy"],
20033
20033
  nextState: "o"
20034
20034
  }
@@ -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;
@@ -23297,10 +23297,7 @@ TagsDiff.defaultProps = {
23297
23297
  title: "Question tags"
23298
23298
  };
23299
23299
 
23300
- /**
23301
- * A side by side diff view for Perseus exercise items
23302
- * that do not have the standard question layout.
23303
- */
23300
+ /* eslint-disable @khanacademy/ts-no-error-suppressions */
23304
23301
  /**
23305
23302
  * Outputs true if path begins with beginPath, false otherwise.
23306
23303
  */
@@ -23339,10 +23336,10 @@ function getTitle(path) {
23339
23336
  const title = [];
23340
23337
  for (let i = 0; i < path.length; i++) {
23341
23338
  if (typeof path[i] === "number") {
23342
- // @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'.
23343
23340
  title.push((path[i] + 1).toString() + ":");
23344
23341
  } else {
23345
- // @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'.
23346
23343
  title.push(path[i]);
23347
23344
  }
23348
23345
  }
@@ -23402,11 +23399,11 @@ class StructuredItemDiff extends React.Component {
23402
23399
  const afterList = [];
23403
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);
23404
23401
  buildMapper()
23405
- // @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'.
23406
23403
  .setContentMapper((c, _, p) => afterList.push([c, p]))
23407
- // @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'.
23408
23405
  .setHintMapper((c, _, p) => afterList.push([c, p]))
23409
- // @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'.
23410
23407
  .setTagsMapper((c, _, p) => afterList.push([c, p])).mapTree(itemToTree(after), shape);
23411
23408
 
23412
23409
  // These are used in generateCompletePathsList()
@@ -23430,7 +23427,7 @@ class StructuredItemDiff extends React.Component {
23430
23427
  before = [[], path];
23431
23428
  }
23432
23429
  if (!after) {
23433
- // @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'.
23434
23431
  after = [[], path];
23435
23432
  }
23436
23433
  const beforeTags = [];
@@ -23442,9 +23439,9 @@ class StructuredItemDiff extends React.Component {
23442
23439
  });
23443
23440
  }
23444
23441
  const afterTags = [];
23445
- // @ts-expect-error [FEI-5003] - TS2532 - Object is possibly 'undefined'.
23442
+ // @ts-expect-error - TS2532 - Object is possibly 'undefined'.
23446
23443
  if (Array.isArray(after[0])) {
23447
- // @ts-expect-error [FEI-5003] - TS2532 - Object is possibly 'undefined'.
23444
+ // @ts-expect-error - TS2532 - Object is possibly 'undefined'.
23448
23445
  after[0].forEach(tagId => {
23449
23446
  if (typeof tagId === "string") {
23450
23447
  afterTags.push(tags.idToName(tagId));
@@ -23467,12 +23464,12 @@ class StructuredItemDiff extends React.Component {
23467
23464
  before = [buildEmptyItemTreeForShape(shapes.content), path];
23468
23465
  }
23469
23466
  if (!after) {
23470
- // @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'.
23471
23468
  after = [buildEmptyItemTreeForShape(shapes.content), path];
23472
23469
  }
23473
23470
  return /*#__PURE__*/React.createElement(RendererDiff, {
23474
23471
  before: before[0]
23475
- // @ts-expect-error [FEI-5003] - TS2532 - Object is possibly 'undefined'.
23472
+ // @ts-expect-error - TS2532 - Object is possibly 'undefined'.
23476
23473
  ,
23477
23474
  after: after[0],
23478
23475
  title: currentTitle,
@@ -23487,7 +23484,7 @@ class StructuredItemDiff extends React.Component {
23487
23484
  }
23488
23485
  }
23489
23486
 
23490
- /* eslint-disable @babel/no-invalid-this */
23487
+ /* eslint-disable @khanacademy/ts-no-error-suppressions */
23491
23488
  const {
23492
23489
  InfoTip: InfoTip$n,
23493
23490
  InlineIcon: InlineIcon$8
@@ -23516,17 +23513,17 @@ class HintEditor extends React.Component {
23516
23513
  };
23517
23514
  this.focus = () => {
23518
23515
  // eslint-disable-next-line react/no-string-refs
23519
- // @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'.
23520
23517
  this.refs.editor.focus();
23521
23518
  };
23522
23519
  this.getSaveWarnings = () => {
23523
23520
  // eslint-disable-next-line react/no-string-refs
23524
- // @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'.
23525
23522
  return this.refs.editor.getSaveWarnings();
23526
23523
  };
23527
23524
  this.serialize = options => {
23528
23525
  // eslint-disable-next-line react/no-string-refs
23529
- // @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'.
23530
23527
  return this.refs.editor.serialize(options);
23531
23528
  };
23532
23529
  }
@@ -23567,7 +23564,7 @@ class HintEditor extends React.Component {
23567
23564
  onClick: _.partial(this.props.onMove, -1)
23568
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", {
23569
23566
  type: "checkbox"
23570
- // @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'.
23571
23568
  ,
23572
23569
  checked: this.props.replace,
23573
23570
  onChange: this.handleChange
@@ -23594,7 +23591,7 @@ class CombinedHintEditor extends React.Component {
23594
23591
  const shouldBold = this.props.isLast && !/\*\*/.test(this.props.hint.content);
23595
23592
 
23596
23593
  // eslint-disable-next-line react/no-string-refs
23597
- // @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'.
23598
23595
  this.refs.frame.sendNewData({
23599
23596
  type: "hint",
23600
23597
  data: {
@@ -23612,17 +23609,17 @@ class CombinedHintEditor extends React.Component {
23612
23609
  };
23613
23610
  this.getSaveWarnings = () => {
23614
23611
  // eslint-disable-next-line react/no-string-refs
23615
- // @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'.
23616
23613
  return this.refs.editor.getSaveWarnings();
23617
23614
  };
23618
23615
  this.serialize = options => {
23619
23616
  // eslint-disable-next-line react/no-string-refs
23620
- // @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'.
23621
23618
  return this.refs.editor.serialize(options);
23622
23619
  };
23623
23620
  this.focus = () => {
23624
23621
  // eslint-disable-next-line react/no-string-refs
23625
- // @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'.
23626
23623
  this.refs.editor.focus();
23627
23624
  };
23628
23625
  }
@@ -23690,38 +23687,38 @@ class CombinedHintsEditor extends React.Component {
23690
23687
  keepDeletedWidgets: true
23691
23688
  }), newProps);
23692
23689
 
23693
- // @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.
23694
23691
  this.props.onChange({
23695
23692
  hints: hints
23696
23693
  }, cb, silent);
23697
23694
  };
23698
23695
  this.handleHintRemove = i => {
23699
23696
  const hints = _(this.props.hints).clone();
23700
- // @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'.
23701
23698
  hints.splice(i, 1);
23702
- // @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[]'.
23703
23700
  this.props.onChange({
23704
23701
  hints: hints
23705
23702
  });
23706
23703
  };
23707
23704
  this.handleHintMove = (i, dir) => {
23708
23705
  const hints = _(this.props.hints).clone();
23709
- // @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'.
23710
23707
  const hint = hints.splice(i, 1)[0];
23711
- // @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'.
23712
23709
  hints.splice(i + dir, 0, hint);
23713
- // @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[]'.
23714
23711
  this.props.onChange({
23715
23712
  hints: hints
23716
23713
  }, () => {
23717
23714
  // eslint-disable-next-line react/no-string-refs
23718
- // @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'.
23719
23716
  this.refs["hintEditor" + (i + dir)].focus();
23720
23717
  });
23721
23718
  };
23722
23719
  this.addHint = () => {
23723
23720
  const hints = _(this.props.hints).clone()
23724
- // @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'.
23725
23722
  .concat([{
23726
23723
  content: ""
23727
23724
  }]);
@@ -23730,7 +23727,7 @@ class CombinedHintsEditor extends React.Component {
23730
23727
  }, () => {
23731
23728
  const i = hints.length - 1;
23732
23729
  // eslint-disable-next-line react/no-string-refs
23733
- // @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'.
23734
23731
  this.refs["hintEditor" + i].focus();
23735
23732
  });
23736
23733
  };
@@ -23738,7 +23735,7 @@ class CombinedHintsEditor extends React.Component {
23738
23735
  return _.chain(this.props.hints).map((hint, i) => {
23739
23736
  return _.map(
23740
23737
  // eslint-disable-next-line react/no-string-refs
23741
- // @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'.
23742
23739
  this.refs["hintEditor" + i].getSaveWarnings(), issue => "Hint " + (i + 1) + ": " + issue);
23743
23740
  }).flatten(true).value();
23744
23741
  };
@@ -23749,7 +23746,7 @@ class CombinedHintsEditor extends React.Component {
23749
23746
  };
23750
23747
  this.serializeHint = (index, options) => {
23751
23748
  // eslint-disable-next-line react/no-string-refs
23752
- // @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'.
23753
23750
  return this.refs["hintEditor" + index].serialize(options);
23754
23751
  };
23755
23752
  }
@@ -23767,31 +23764,31 @@ class CombinedHintsEditor extends React.Component {
23767
23764
  itemId: itemId,
23768
23765
  hint: hint,
23769
23766
  pos: i
23770
- // @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.
23771
23768
  ,
23772
23769
  imageUploader: this.props.imageUploader
23773
23770
  // eslint-disable-next-line react/jsx-no-bind
23774
- // @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.
23775
23772
  ,
23776
23773
  onChange: this.handleHintChange.bind(this, i)
23777
23774
  // eslint-disable-next-line react/jsx-no-bind
23778
- // @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.
23779
23776
  ,
23780
23777
  onRemove: this.handleHintRemove.bind(this, i)
23781
23778
  // eslint-disable-next-line react/jsx-no-bind
23782
- // @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.
23783
23780
  ,
23784
23781
  onMove: this.handleHintMove.bind(this, i)
23785
- // @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.
23786
23783
  ,
23787
23784
  deviceType: this.props.deviceType
23788
- // @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.
23789
23786
  ,
23790
23787
  apiOptions: this.props.apiOptions
23791
- // @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.
23792
23789
  ,
23793
23790
  highlightLint: this.props.highlightLint
23794
- // @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.
23795
23792
  ,
23796
23793
  previewURL: this.props.previewURL
23797
23794
  // TODO(CP-4838): what should be passed here?
@@ -23910,7 +23907,7 @@ class ItemEditor extends React.Component {
23910
23907
  };
23911
23908
  this.triggerPreviewUpdate = newData => {
23912
23909
  // eslint-disable-next-line react/no-string-refs
23913
- // @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'.
23914
23911
  this.refs.frame.sendNewData(newData);
23915
23912
  };
23916
23913
  this.handleEditorChange = (newProps, cb, silent) => {
@@ -23927,16 +23924,16 @@ class ItemEditor extends React.Component {
23927
23924
  };
23928
23925
  this.getSaveWarnings = () => {
23929
23926
  // eslint-disable-next-line react/no-string-refs
23930
- // @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'.
23931
23928
  return this.refs.questionEditor.getSaveWarnings();
23932
23929
  };
23933
23930
  this.serialize = options => {
23934
23931
  return {
23935
23932
  // eslint-disable-next-line react/no-string-refs
23936
- // @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'.
23937
23934
  question: this.refs.questionEditor.serialize(options),
23938
23935
  // eslint-disable-next-line react/no-string-refs
23939
- // @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'.
23940
23937
  answerArea: this.refs.itemExtrasEditor.serialize(options),
23941
23938
  itemDataVersion: ITEM_DATA_VERSION
23942
23939
  };
@@ -24018,7 +24015,7 @@ const {
24018
24015
  HUD
24019
24016
  } = components;
24020
24017
  class EditorPage extends React.Component {
24021
- // @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.
24022
24019
 
24023
24020
  constructor(props) {
24024
24021
  super(props);
@@ -24048,7 +24045,7 @@ class EditorPage extends React.Component {
24048
24045
  this.props.onChange(newJson);
24049
24046
  };
24050
24047
  this.state = {
24051
- // @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'.
24052
24049
  json: _.pick(this.props, "question", "answerArea", "hints", "itemDataVersion"),
24053
24050
  gradeMessage: "",
24054
24051
  wasAnswered: false,
@@ -24093,7 +24090,7 @@ class EditorPage extends React.Component {
24093
24090
  });
24094
24091
 
24095
24092
  // eslint-disable-next-line react/no-string-refs
24096
- // @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'.
24097
24094
  this.refs.itemEditor.triggerPreviewUpdate({
24098
24095
  type: "question",
24099
24096
  data: _({
@@ -24109,7 +24106,7 @@ class EditorPage extends React.Component {
24109
24106
  },
24110
24107
  reviewMode: true,
24111
24108
  // eslint-disable-next-line react/no-string-refs
24112
- // @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'.
24113
24110
  legacyPerseusLint: this.refs.itemEditor.getSaveWarnings()
24114
24111
  }).extend(_(this.props).pick("workAreaSelector", "solutionAreaSelector", "hintsAreaSelector", "problemNum"))
24115
24112
  });
@@ -24119,10 +24116,10 @@ class EditorPage extends React.Component {
24119
24116
  }
24120
24117
  getSaveWarnings() {
24121
24118
  // eslint-disable-next-line react/no-string-refs
24122
- // @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'.
24123
24120
  const issues1 = this.refs.itemEditor.getSaveWarnings();
24124
24121
  // eslint-disable-next-line react/no-string-refs
24125
- // @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'.
24126
24123
  const issues2 = this.refs.hintsEditor.getSaveWarnings();
24127
24124
  return issues1.concat(issues2);
24128
24125
  }
@@ -24131,10 +24128,10 @@ class EditorPage extends React.Component {
24131
24128
  return this.state.json;
24132
24129
  }
24133
24130
  // eslint-disable-next-line react/no-string-refs
24134
- // @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'.
24135
24132
  return _.extend(this.refs.itemEditor.serialize(options), {
24136
24133
  // eslint-disable-next-line react/no-string-refs
24137
- // @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'.
24138
24135
  hints: this.refs.hintsEditor.serialize(options)
24139
24136
  });
24140
24137
  }
@@ -24227,7 +24224,7 @@ const {
24227
24224
 
24228
24225
  // Takes a renderer content and parses the markdown for images
24229
24226
  function findImagesInContent(content, images) {
24230
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 2 arguments, but got 1.
24227
+ // @ts-expect-error - TS2554 - Expected 2 arguments, but got 1.
24231
24228
  const parsed = PerseusMarkdown.parse(content);
24232
24229
  PerseusMarkdown.traverseContent(parsed, function (node) {
24233
24230
  if (node.type === "image") {
@@ -24328,12 +24325,12 @@ function findImagesInItemData(itemData) {
24328
24325
  let renderers = [];
24329
24326
  if (itemData._multi) {
24330
24327
  const shape = inferItemShape(itemData);
24331
- // @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'.
24332
24329
  findContentNodesInItem(itemData, shape, node => renderers.push(node));
24333
- // @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'.
24334
24331
  findHintNodesInItem(itemData, shape, node => renderers.push(node));
24335
24332
  } else {
24336
- // @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'.
24337
24334
  renderers = [itemData.question, ...itemData.hints];
24338
24335
  }
24339
24336
  return findImagesInRenderers(renderers);
@@ -25111,7 +25108,7 @@ const withStickiness = WrappedComponent => {
25111
25108
  };
25112
25109
  this.updateStickiness = () => {
25113
25110
  const domNode = ReactDOM__default.findDOMNode(this);
25114
- // @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'.
25115
25112
  const height = domNode.offsetHeight;
25116
25113
  const windowHeight = window.innerHeight;
25117
25114
  const sticky = height > windowHeight;
@@ -25125,7 +25122,7 @@ const withStickiness = WrappedComponent => {
25125
25122
  componentDidMount() {
25126
25123
  // TODO(jeff, CP-3128): Use Wonder Blocks Timing API.
25127
25124
  // eslint-disable-next-line no-restricted-syntax
25128
- // @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'.
25129
25126
  this.stickynessTimer = setInterval(this.updateStickiness, 1000);
25130
25127
  this.updateStickiness();
25131
25128
  }
@@ -25137,7 +25134,7 @@ const withStickiness = WrappedComponent => {
25137
25134
  render() {
25138
25135
  return (
25139
25136
  /*#__PURE__*/
25140
- // @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>>>'.
25141
25138
  React.createElement(WrappedComponent, _extends({}, this.props, {
25142
25139
  sticky: this.state.sticky
25143
25140
  }))
@@ -25165,7 +25162,7 @@ const ItemNodeContent = withStickiness(props => {
25165
25162
  className: css(sticky && styles$c.sticky)
25166
25163
  },
25167
25164
  /*#__PURE__*/
25168
- // @ts-expect-error [FEI-5003] - TS2769 - No overload matches this call.
25165
+ // @ts-expect-error - TS2769 - No overload matches this call.
25169
25166
  React.createElement(Editor, _extends({}, data, {
25170
25167
  onChange: newVal => actions.mergeValueAtPath(path, newVal),
25171
25168
  apiOptions: apiOptions
@@ -25429,19 +25426,19 @@ class MultiRendererEditor extends React.Component {
25429
25426
  };
25430
25427
  this.score = () => {
25431
25428
  if (this.layout) {
25432
- // @ts-expect-error [FEI-5003] - TS2571 - Object is of type 'unknown'.
25429
+ // @ts-expect-error - TS2571 - Object is of type 'unknown'.
25433
25430
  return this.layout.score();
25434
25431
  }
25435
25432
  };
25436
25433
  this.getSerializedState = () => {
25437
25434
  if (this.layout) {
25438
- // @ts-expect-error [FEI-5003] - TS2571 - Object is of type 'unknown'.
25435
+ // @ts-expect-error - TS2571 - Object is of type 'unknown'.
25439
25436
  return this.layout.getSerializedState();
25440
25437
  }
25441
25438
  };
25442
25439
  this.restoreSerializedState = state => {
25443
25440
  if (this.layout) {
25444
- // @ts-expect-error [FEI-5003] - TS2571 - Object is of type 'unknown'.
25441
+ // @ts-expect-error - TS2571 - Object is of type 'unknown'.
25445
25442
  this.layout.restoreSerializedState(state);
25446
25443
  }
25447
25444
  };
@@ -25768,14 +25765,14 @@ class CategorizerEditor extends React.Component {
25768
25765
  })), "Categories:", /*#__PURE__*/React.createElement(TextListEditor$4, {
25769
25766
  options: this.props.categories,
25770
25767
  onChange: cat => {
25771
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
25768
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
25772
25769
  this.change("categories", cat);
25773
25770
  },
25774
25771
  layout: "horizontal"
25775
25772
  }), "Items:", /*#__PURE__*/React.createElement(TextListEditor$4, {
25776
25773
  options: this.props.items,
25777
25774
  onChange: items => {
25778
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
25775
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
25779
25776
  this.change({
25780
25777
  items: items,
25781
25778
  // TODO(eater): This truncates props.values so there
@@ -25973,7 +25970,7 @@ class CSProgramEditor extends React.Component {
25973
25970
  constructor(..._args3) {
25974
25971
  super(..._args3);
25975
25972
  this.change = (...args) => {
25976
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'readonly unknown[]' is not assignable to parameter of type 'any[]'.
25973
+ // @ts-expect-error - TS2345 - Argument of type 'readonly unknown[]' is not assignable to parameter of type 'any[]'.
25977
25974
  return Changeable.change.apply(this, args);
25978
25975
  };
25979
25976
  this._handleSettingsChange = settings => {
@@ -25999,7 +25996,7 @@ class CSProgramEditor extends React.Component {
25999
25996
  });
26000
25997
  }).fail((jqxhr, textStatus, error) => {
26001
25998
  Log.error("Error retrieving scratchpad info for program ID ", Errors.TransientService, {
26002
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'string' is not assignable to type 'Error | null | undefined'.
25999
+ // @ts-expect-error - TS2322 - Type 'string' is not assignable to type 'Error | null | undefined'.
26003
26000
  cause: error,
26004
26001
  loggedMetadata: {
26005
26002
  textStatus,
@@ -26075,7 +26072,7 @@ class DefinitionEditor extends React.Component {
26075
26072
  className: "perseus-widget-row"
26076
26073
  }, /*#__PURE__*/React.createElement("label", null, "Word to be defined:", " ", /*#__PURE__*/React.createElement(TextInput$8, {
26077
26074
  value: this.props.togglePrompt
26078
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26075
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26079
26076
  ,
26080
26077
  onChange: this.change("togglePrompt"),
26081
26078
  placeholder: "define me"
@@ -26091,7 +26088,7 @@ class DefinitionEditor extends React.Component {
26091
26088
  if (_.has(props, "content")) {
26092
26089
  newProps.definition = props.content;
26093
26090
  }
26094
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26091
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26095
26092
  this.change(newProps);
26096
26093
  }
26097
26094
  })));
@@ -26108,6 +26105,7 @@ DefinitionEditor.defaultProps = {
26108
26105
  definition: ""
26109
26106
  };
26110
26107
 
26108
+ /* eslint-disable @khanacademy/ts-no-error-suppressions */
26111
26109
  const {
26112
26110
  InfoTip: InfoTip$k,
26113
26111
  InlineIcon: InlineIcon$6
@@ -26164,7 +26162,7 @@ class DropdownEditor extends React.Component {
26164
26162
  });
26165
26163
  };
26166
26164
  this.focus = i => {
26167
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2339 - Property 'focus' does not exist on type 'Element | Text'.
26165
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2339 - Property 'focus' does not exist on type 'Element | Text'.
26168
26166
  ReactDOM__default.findDOMNode(this.refs["editor" + i]).focus(); // eslint-disable-line react/no-string-refs
26169
26167
  return true;
26170
26168
  };
@@ -26197,24 +26195,24 @@ class DropdownEditor extends React.Component {
26197
26195
  ref: "radio" + i,
26198
26196
  type: "radio",
26199
26197
  name: dropdownGroupName
26200
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'string' is not assignable to type 'boolean | undefined'.
26198
+ // @ts-expect-error - TS2322 - Type 'string' is not assignable to type 'boolean | undefined'.
26201
26199
  ,
26202
26200
  checked: choice.correct ? "checked" : ""
26203
26201
  // eslint-disable-next-line react/jsx-no-bind
26204
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26202
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26205
26203
  ,
26206
26204
  onChange: this.onCorrectChange.bind(
26207
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26205
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26208
26206
  this, i),
26209
26207
  value: i
26210
26208
  }), /*#__PURE__*/React.createElement("input", {
26211
26209
  type: "text",
26212
26210
  ref: "editor" + i
26213
26211
  // eslint-disable-next-line react/jsx-no-bind
26214
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26212
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26215
26213
  ,
26216
26214
  onChange: this.onContentChange.bind(
26217
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26215
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26218
26216
  this, i),
26219
26217
  className: checkedClass,
26220
26218
  value: choice.content
@@ -26222,10 +26220,10 @@ class DropdownEditor extends React.Component {
26222
26220
  href: "#",
26223
26221
  className: "simple-button orange"
26224
26222
  // eslint-disable-next-line react/jsx-no-bind
26225
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26223
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26226
26224
  ,
26227
26225
  onClick: this.removeChoice.bind(
26228
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26226
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
26229
26227
  this, i)
26230
26228
  }, /*#__PURE__*/React.createElement("span", {
26231
26229
  className: "remove-choice"
@@ -26259,7 +26257,7 @@ const {
26259
26257
  Graphie
26260
26258
  } = components;
26261
26259
 
26262
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'MovablePoint' does not exist on type 'typeof Graphie'.
26260
+ // @ts-expect-error - TS2339 - Property 'MovablePoint' does not exist on type 'typeof Graphie'.
26263
26261
  const MovablePoint = Graphie.MovablePoint;
26264
26262
  /**
26265
26263
  * This is the widget's renderer. It shows up in the right column
@@ -26276,7 +26274,7 @@ class ExampleGraphieWidget$1 extends React.Component {
26276
26274
  return Changeable.change.apply(this, args);
26277
26275
  };
26278
26276
  this.movePoint = newCoord => {
26279
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26277
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26280
26278
  this.change({
26281
26279
  coord: newCoord
26282
26280
  });
@@ -26396,7 +26394,7 @@ class ExampleGraphieWidgetEditor extends React.Component {
26396
26394
  };
26397
26395
  this.handleChange = newProps => {
26398
26396
  if (newProps.coord) {
26399
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26397
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26400
26398
  this.change({
26401
26399
  correct: newProps.coord
26402
26400
  });
@@ -26440,7 +26438,7 @@ class ExampleWidgetEditor extends React.Component {
26440
26438
  constructor(..._args) {
26441
26439
  super(..._args);
26442
26440
  this.handleAnswerChange = event => {
26443
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26441
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26444
26442
  this.change({
26445
26443
  correct: event.target.value
26446
26444
  });
@@ -26450,7 +26448,7 @@ class ExampleWidgetEditor extends React.Component {
26450
26448
  };
26451
26449
  this.focus = () => {
26452
26450
  // eslint-disable-next-line react/no-string-refs
26453
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
26451
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
26454
26452
  this.refs.input.focus();
26455
26453
  return true;
26456
26454
  };
@@ -26501,14 +26499,14 @@ class ExplanationEditor extends React.Component {
26501
26499
  className: "perseus-widget-row"
26502
26500
  }, /*#__PURE__*/React.createElement("label", null, "Prompt to show explanation:", " ", /*#__PURE__*/React.createElement(TextInput$7, {
26503
26501
  value: this.props.showPrompt
26504
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26502
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26505
26503
  ,
26506
26504
  onChange: this.change("showPrompt")
26507
26505
  }))), /*#__PURE__*/React.createElement("div", {
26508
26506
  className: "perseus-widget-row"
26509
26507
  }, /*#__PURE__*/React.createElement("label", null, "Prompt to hide explanation:", " ", /*#__PURE__*/React.createElement(TextInput$7, {
26510
26508
  value: this.props.hidePrompt
26511
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26509
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26512
26510
  ,
26513
26511
  onChange: this.change("hidePrompt")
26514
26512
  }))), /*#__PURE__*/React.createElement("div", {
@@ -26527,7 +26525,7 @@ class ExplanationEditor extends React.Component {
26527
26525
  if (_.has(props, "widgets")) {
26528
26526
  newProps.widgets = props.widgets;
26529
26527
  }
26530
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26528
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26531
26529
  this.change(newProps);
26532
26530
  }
26533
26531
  })));
@@ -26626,7 +26624,7 @@ const SortableArea = createReactClass({
26626
26624
  _setDragEvents: function () {
26627
26625
  this._dragItems = this._dragItems || [];
26628
26626
  const items =
26629
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'
26627
+ // @ts-expect-error - TS2531 - Object is possibly 'null'
26630
26628
  ReactDOM__default.findDOMNode(this).querySelectorAll("[draggable=true]");
26631
26629
  const oldItems = [];
26632
26630
  const newItems = [];
@@ -26826,7 +26824,7 @@ class ExpressionEditor extends React.Component {
26826
26824
  this.newAnswer = () => {
26827
26825
  const answerForms = this.props.answerForms.slice();
26828
26826
  answerForms.push(this._newEmptyAnswerForm());
26829
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26827
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26830
26828
  this.change({
26831
26829
  answerForms
26832
26830
  });
@@ -26834,7 +26832,7 @@ class ExpressionEditor extends React.Component {
26834
26832
  this.handleRemoveForm = i => {
26835
26833
  const answerForms = this.props.answerForms.slice();
26836
26834
  answerForms.splice(i, 1);
26837
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26835
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26838
26836
  this.change({
26839
26837
  answerForms
26840
26838
  });
@@ -26842,7 +26840,7 @@ class ExpressionEditor extends React.Component {
26842
26840
  this.updateForm = (i, props) => {
26843
26841
  const answerForms = lens(this.props.answerForms).merge([i], props).freeze();
26844
26842
 
26845
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26843
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26846
26844
  this.change({
26847
26845
  answerForms
26848
26846
  });
@@ -26850,12 +26848,12 @@ class ExpressionEditor extends React.Component {
26850
26848
  this.handleReorder = components => {
26851
26849
  const answerForms = _(components).map(component => {
26852
26850
  const form = _(component.props).pick("considered", "form", "simplify", "value");
26853
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'key' does not exist on type 'Pick<any, "form" | "value" | "simplify" | "considered">'.
26851
+ // @ts-expect-error - TS2339 - Property 'key' does not exist on type 'Pick<any, "form" | "value" | "simplify" | "considered">'.
26854
26852
  form.key = component.key;
26855
26853
  return form;
26856
26854
  });
26857
26855
 
26858
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
26856
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
26859
26857
  this.change({
26860
26858
  answerForms
26861
26859
  });
@@ -26887,12 +26885,12 @@ class ExpressionEditor extends React.Component {
26887
26885
  }
26888
26886
  const buttonSets = _(this.props.buttonSets).reject(set => set === remove).concat(keep);
26889
26887
 
26890
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
26888
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
26891
26889
  this.change("buttonSets", buttonSets);
26892
26890
  };
26893
26891
  this.handleTexInsert = str => {
26894
26892
  // eslint-disable-next-line react/no-string-refs
26895
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'insert' does not exist on type 'ReactInstance'.
26893
+ // @ts-expect-error - TS2339 - Property 'insert' does not exist on type 'ReactInstance'.
26896
26894
  this.refs.expression.insert(str);
26897
26895
  };
26898
26896
  this.handleFunctions = e => {
@@ -27064,7 +27062,7 @@ class AnswerOption extends React.Component {
27064
27062
  render() {
27065
27063
  let removeButton = null;
27066
27064
  if (this.state.deleteFocused) {
27067
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'Element' is not assignable to type 'null'.
27065
+ // @ts-expect-error - TS2322 - Type 'Element' is not assignable to type 'null'.
27068
27066
  removeButton = /*#__PURE__*/React.createElement("button", {
27069
27067
  type: "button",
27070
27068
  className: "simple-button orange",
@@ -27072,7 +27070,7 @@ class AnswerOption extends React.Component {
27072
27070
  onBlur: this.handleDeleteBlur
27073
27071
  }, "I'm sure!");
27074
27072
  } else {
27075
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'Element' is not assignable to type 'null'.
27073
+ // @ts-expect-error - TS2322 - Type 'Element' is not assignable to type 'null'.
27076
27074
  removeButton = /*#__PURE__*/React.createElement("button", {
27077
27075
  type: "button",
27078
27076
  className: "simple-button orange",
@@ -27144,7 +27142,7 @@ class GradedGroupEditor extends React.Component {
27144
27142
  hint
27145
27143
  }, () => {
27146
27144
  // eslint-disable-next-line react/no-string-refs
27147
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
27145
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
27148
27146
  this.refs["hint-editor"].focus();
27149
27147
  });
27150
27148
  };
@@ -27155,7 +27153,7 @@ class GradedGroupEditor extends React.Component {
27155
27153
  };
27156
27154
  this.getSaveWarnings = () => {
27157
27155
  // eslint-disable-next-line react/no-string-refs
27158
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
27156
+ // @ts-expect-error - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
27159
27157
  return this.refs.editor.getSaveWarnings();
27160
27158
  };
27161
27159
  this.serialize = () => {
@@ -27166,7 +27164,7 @@ class GradedGroupEditor extends React.Component {
27166
27164
  // eslint-disable-next-line react/no-string-refs
27167
27165
  this.refs["hint-editor"] &&
27168
27166
  // eslint-disable-next-line react/no-string-refs
27169
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
27167
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
27170
27168
  this.refs["hint-editor"].serialize()
27171
27169
  });
27172
27170
  };
@@ -27181,7 +27179,7 @@ class GradedGroupEditor extends React.Component {
27181
27179
  }, "Title:", " ", /*#__PURE__*/React.createElement(TextInput$6, {
27182
27180
  value: this.props.title,
27183
27181
  className: css(styles$a.input)
27184
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
27182
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
27185
27183
  ,
27186
27184
  onChange: this.change("title")
27187
27185
  }))), /*#__PURE__*/React.createElement(Editor
@@ -27221,7 +27219,7 @@ class GradedGroupEditor extends React.Component {
27221
27219
  onChange: props => {
27222
27220
  // Copy all props over from the existing hint
27223
27221
  // and then add new props.
27224
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
27222
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
27225
27223
  this.change("hint", Object.assign({}, this.props.hint, props));
27226
27224
  }
27227
27225
  }), /*#__PURE__*/React.createElement("button", {
@@ -27288,13 +27286,13 @@ class GradedGroupSetEditor extends React.Component {
27288
27286
  widgetEnabled: true,
27289
27287
  immutableWidgets: false,
27290
27288
  onChange: data =>
27291
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
27289
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
27292
27290
  this.change("gradedGroups", setArrayItem(this.props.gradedGroups, i, _extends({}, this.props.gradedGroups[i], data)))
27293
27291
  })));
27294
27292
  };
27295
27293
  this.addGroup = () => {
27296
27294
  const groups = this.props.gradedGroups || [];
27297
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
27295
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
27298
27296
  this.change("gradedGroups", groups.concat([GradedGroupEditor.defaultProps]));
27299
27297
  };
27300
27298
  }
@@ -27435,7 +27433,7 @@ const GraphSettings = createReactClass({
27435
27433
  }, this.changeGraph);
27436
27434
  };
27437
27435
 
27438
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
27436
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
27439
27437
  const url = ReactDOM__default.findDOMNode(this.refs["bg-url"]).value; // eslint-disable-line react/no-string-refs
27440
27438
  if (url) {
27441
27439
  Util.getImageSize(url, (width, height) => {
@@ -27863,7 +27861,7 @@ class GrapherEditor extends React.Component {
27863
27861
  // NOTE(jeremy): This editor doesn't pass in a bunch of
27864
27862
  // standard props that the Renderer provides normally (eg.
27865
27863
  // alignment, findWidgets, etc).
27866
- // @ts-expect-error [FEI-5003] - TS2769 - No overload matches this call.
27864
+ // @ts-expect-error - TS2769 - No overload matches this call.
27867
27865
  React.createElement(Grapher, _extends({}, graphProps, {
27868
27866
  apiOptions: this.props.apiOptions,
27869
27867
  containerSizeClass: sizeClass
@@ -27888,7 +27886,7 @@ class GrapherEditor extends React.Component {
27888
27886
  rulerLabel: this.props.graph.rulerLabel,
27889
27887
  rulerTicks: this.props.graph.rulerTicks,
27890
27888
  showTooltips: this.props.graph.showTooltips
27891
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
27889
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
27892
27890
  ,
27893
27891
  onChange: this.change("graph")
27894
27892
  }), /*#__PURE__*/React.createElement("div", {
@@ -27916,7 +27914,7 @@ class GroupEditor extends React.Component {
27916
27914
  const GroupMetadataEditor = this.props.apiOptions.GroupMetadataEditor;
27917
27915
  return /*#__PURE__*/React.createElement(GroupMetadataEditor, {
27918
27916
  value: this.props.metadata
27919
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
27917
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
27920
27918
  ,
27921
27919
  onChange: this.change("metadata")
27922
27920
  });
@@ -27926,12 +27924,12 @@ class GroupEditor extends React.Component {
27926
27924
  };
27927
27925
  this.getSaveWarnings = () => {
27928
27926
  // eslint-disable-next-line react/no-string-refs
27929
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
27927
+ // @ts-expect-error - TS2339 - Property 'getSaveWarnings' does not exist on type 'ReactInstance'.
27930
27928
  return this.refs.editor.getSaveWarnings();
27931
27929
  };
27932
27930
  this.serialize = () => {
27933
27931
  // eslint-disable-next-line react/no-string-refs
27934
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
27932
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
27935
27933
  return _.extend({}, this.refs.editor.serialize(), {
27936
27934
  metadata: this.props.metadata
27937
27935
  });
@@ -28061,7 +28059,7 @@ class IframeEditor extends React.Component {
28061
28059
  return Changeable.change.apply(this, args);
28062
28060
  };
28063
28061
  this.handleSettingsChange = settings => {
28064
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28062
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28065
28063
  this.change({
28066
28064
  settings: settings.pairs
28067
28065
  });
@@ -28078,7 +28076,7 @@ class IframeEditor extends React.Component {
28078
28076
  }
28079
28077
  }, "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, {
28080
28078
  value: this.props.url
28081
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28079
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28082
28080
  ,
28083
28081
  onChange: this.change("url")
28084
28082
  })), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("label", null, "Settings:", /*#__PURE__*/React.createElement(PairsEditor, {
@@ -28087,12 +28085,12 @@ class IframeEditor extends React.Component {
28087
28085
  onChange: this.handleSettingsChange
28088
28086
  })), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("label", null, "Width:", /*#__PURE__*/React.createElement(BlurInput, {
28089
28087
  value: this.props.width
28090
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28088
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28091
28089
  ,
28092
28090
  onChange: this.change("width")
28093
28091
  })), /*#__PURE__*/React.createElement("label", null, "Height:", /*#__PURE__*/React.createElement(BlurInput, {
28094
28092
  value: this.props.height
28095
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28093
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28096
28094
  ,
28097
28095
  onChange: this.change("height")
28098
28096
  })), /*#__PURE__*/React.createElement(PropCheckBox$9, {
@@ -28406,7 +28404,7 @@ class InputNumberEditor extends React.Component {
28406
28404
  });
28407
28405
  };
28408
28406
  this.focus = () => {
28409
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2339 - Property 'focus' does not exist on type 'Element | Text'.
28407
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2339 - Property 'focus' does not exist on type 'Element | Text'.
28410
28408
  ReactDOM__default.findDOMNode(this.refs.input).focus(); // eslint-disable-line react/no-string-refs
28411
28409
  return true;
28412
28410
  };
@@ -28437,7 +28435,7 @@ class InputNumberEditor extends React.Component {
28437
28435
  value: this.props.simplify,
28438
28436
  onChange: e => {
28439
28437
  this.props.onChange({
28440
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'string' is not assignable to type '"optional" | "required" | "enforced" | undefined'.
28438
+ // @ts-expect-error - TS2322 - Type 'string' is not assignable to type '"optional" | "required" | "enforced" | undefined'.
28441
28439
  simplify: e.target.value
28442
28440
  });
28443
28441
  }
@@ -28476,7 +28474,7 @@ class InputNumberEditor extends React.Component {
28476
28474
  }))), /*#__PURE__*/React.createElement("div", null, "Answer type:", " ", /*#__PURE__*/React.createElement("select", {
28477
28475
  value: this.props.answerType,
28478
28476
  onChange: e => {
28479
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'string' is not assignable to type '"number" | "integer" | "mixed" | "decimal" | "improper" | "percent" | "pi" | "rational" | undefined'.
28477
+ // @ts-expect-error - TS2322 - Type 'string' is not assignable to type '"number" | "integer" | "mixed" | "decimal" | "improper" | "percent" | "pi" | "rational" | undefined'.
28480
28478
  this.props.onChange({
28481
28479
  answerType: e.target.value
28482
28480
  });
@@ -28484,7 +28482,7 @@ class InputNumberEditor extends React.Component {
28484
28482
  }, 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", {
28485
28483
  value: this.props.size,
28486
28484
  onChange: e => {
28487
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'string' is not assignable to type '"small" | "normal" | undefined'.
28485
+ // @ts-expect-error - TS2322 - Type 'string' is not assignable to type '"small" | "normal" | undefined'.
28488
28486
  this.props.onChange({
28489
28487
  size: e.target.value
28490
28488
  });
@@ -28664,21 +28662,21 @@ class PointEditor extends React.Component {
28664
28662
  buttonSets: [],
28665
28663
  buttonsVisible: "never",
28666
28664
  value: this.props.coordX
28667
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28665
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28668
28666
  ,
28669
28667
  onChange: this.change("coordX")
28670
28668
  }), /*#__PURE__*/React.createElement(TeX, null, ","), " ", /*#__PURE__*/React.createElement(MathInput, {
28671
28669
  buttonSets: [],
28672
28670
  buttonsVisible: "never",
28673
28671
  value: this.props.coordY
28674
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28672
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28675
28673
  ,
28676
28674
  onChange: this.change("coordY")
28677
28675
  }), /*#__PURE__*/React.createElement(TeX, null, "\\Large)")), /*#__PURE__*/React.createElement("div", {
28678
28676
  className: "perseus-widget-row"
28679
28677
  }, /*#__PURE__*/React.createElement(ColorPicker, {
28680
28678
  value: this.props.color
28681
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28679
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28682
28680
  ,
28683
28681
  onChange: this.change("color")
28684
28682
  })));
@@ -28721,14 +28719,14 @@ class LineEditor extends React.Component {
28721
28719
  buttonSets: [],
28722
28720
  buttonsVisible: "never",
28723
28721
  value: this.props.startX
28724
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28722
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28725
28723
  ,
28726
28724
  onChange: this.change("startX")
28727
28725
  }), /*#__PURE__*/React.createElement(TeX, null, ","), " ", /*#__PURE__*/React.createElement(MathInput, {
28728
28726
  buttonSets: [],
28729
28727
  buttonsVisible: "never",
28730
28728
  value: this.props.startY
28731
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28729
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28732
28730
  ,
28733
28731
  onChange: this.change("startY")
28734
28732
  }), /*#__PURE__*/React.createElement(TeX, null, "\\Large)")), /*#__PURE__*/React.createElement("div", {
@@ -28737,33 +28735,33 @@ class LineEditor extends React.Component {
28737
28735
  buttonSets: [],
28738
28736
  buttonsVisible: "never",
28739
28737
  value: this.props.endX
28740
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28738
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28741
28739
  ,
28742
28740
  onChange: this.change("endX")
28743
28741
  }), /*#__PURE__*/React.createElement(TeX, null, ","), " ", /*#__PURE__*/React.createElement(MathInput, {
28744
28742
  buttonSets: [],
28745
28743
  buttonsVisible: "never",
28746
28744
  value: this.props.endY
28747
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28745
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28748
28746
  ,
28749
28747
  onChange: this.change("endY")
28750
28748
  }), /*#__PURE__*/React.createElement(TeX, null, "\\Large)")), /*#__PURE__*/React.createElement("div", {
28751
28749
  className: "perseus-widget-row"
28752
28750
  }, /*#__PURE__*/React.createElement(ColorPicker, {
28753
28751
  value: this.props.color
28754
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28752
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28755
28753
  ,
28756
28754
  onChange: this.change("color")
28757
28755
  })), /*#__PURE__*/React.createElement("div", {
28758
28756
  className: "perseus-widget-row"
28759
28757
  }, /*#__PURE__*/React.createElement(DashPicker, {
28760
28758
  value: this.props.strokeDasharray
28761
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28759
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28762
28760
  ,
28763
28761
  onChange: this.change("strokeDasharray")
28764
28762
  }), "\xA0 \xA0", /*#__PURE__*/React.createElement(ArrowPicker, {
28765
28763
  value: this.props.arrows
28766
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28764
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28767
28765
  ,
28768
28766
  onChange: this.change("arrows")
28769
28767
  })), /*#__PURE__*/React.createElement("div", {
@@ -28773,7 +28771,7 @@ class LineEditor extends React.Component {
28773
28771
  }, "Width:", " ", /*#__PURE__*/React.createElement(NumberInput$b, {
28774
28772
  value: this.props.strokeWidth,
28775
28773
  placeholder: 2
28776
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28774
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28777
28775
  ,
28778
28776
  onChange: this.change("strokeWidth")
28779
28777
  }))));
@@ -28972,7 +28970,7 @@ class FunctionEditor extends React.Component {
28972
28970
  buttonSets: [],
28973
28971
  buttonsVisible: "never",
28974
28972
  value: this.props.value
28975
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28973
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28976
28974
  ,
28977
28975
  onChange: this.change("value")
28978
28976
  })), /*#__PURE__*/React.createElement("div", {
@@ -28981,28 +28979,28 @@ class FunctionEditor extends React.Component {
28981
28979
  buttonSets: [],
28982
28980
  buttonsVisible: "never",
28983
28981
  value: this.props.rangeMin
28984
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28982
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28985
28983
  ,
28986
28984
  onChange: this.change("rangeMin")
28987
28985
  }), /*#__PURE__*/React.createElement(TeX, null, ","), " ", /*#__PURE__*/React.createElement(MathInput, {
28988
28986
  buttonSets: [],
28989
28987
  buttonsVisible: "never",
28990
28988
  value: this.props.rangeMax
28991
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28989
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28992
28990
  ,
28993
28991
  onChange: this.change("rangeMax")
28994
28992
  }), /*#__PURE__*/React.createElement(TeX, null, "\\Large)")), /*#__PURE__*/React.createElement("div", {
28995
28993
  className: "perseus-widget-row"
28996
28994
  }, /*#__PURE__*/React.createElement(ColorPicker, {
28997
28995
  value: this.props.color
28998
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
28996
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
28999
28997
  ,
29000
28998
  onChange: this.change("color")
29001
28999
  })), /*#__PURE__*/React.createElement("div", {
29002
29000
  className: "perseus-widget-row"
29003
29001
  }, /*#__PURE__*/React.createElement(DashPicker, {
29004
29002
  value: this.props.strokeDasharray
29005
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29003
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29006
29004
  ,
29007
29005
  onChange: this.change("strokeDasharray")
29008
29006
  })), /*#__PURE__*/React.createElement("div", {
@@ -29012,7 +29010,7 @@ class FunctionEditor extends React.Component {
29012
29010
  }, "Width:", " ", /*#__PURE__*/React.createElement(NumberInput$b, {
29013
29011
  value: this.props.strokeWidth,
29014
29012
  placeholder: 2
29015
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29013
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29016
29014
  ,
29017
29015
  onChange: this.change("strokeWidth")
29018
29016
  }))));
@@ -29061,7 +29059,7 @@ class ParametricEditor extends React.Component {
29061
29059
  buttonSets: [],
29062
29060
  buttonsVisible: "never",
29063
29061
  value: this.props.x
29064
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29062
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29065
29063
  ,
29066
29064
  onChange: this.change("x")
29067
29065
  })), /*#__PURE__*/React.createElement("div", {
@@ -29070,7 +29068,7 @@ class ParametricEditor extends React.Component {
29070
29068
  buttonSets: [],
29071
29069
  buttonsVisible: "never",
29072
29070
  value: this.props.y
29073
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29071
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29074
29072
  ,
29075
29073
  onChange: this.change("y")
29076
29074
  })), /*#__PURE__*/React.createElement("div", {
@@ -29079,28 +29077,28 @@ class ParametricEditor extends React.Component {
29079
29077
  buttonSets: [],
29080
29078
  buttonsVisible: "never",
29081
29079
  value: this.props.rangeMin
29082
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29080
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29083
29081
  ,
29084
29082
  onChange: this.change("rangeMin")
29085
29083
  }), /*#__PURE__*/React.createElement(TeX, null, ","), " ", /*#__PURE__*/React.createElement(MathInput, {
29086
29084
  buttonSets: [],
29087
29085
  buttonsVisible: "never",
29088
29086
  value: this.props.rangeMax
29089
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29087
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29090
29088
  ,
29091
29089
  onChange: this.change("rangeMax")
29092
29090
  }), /*#__PURE__*/React.createElement(TeX, null, "\\Large)")), /*#__PURE__*/React.createElement("div", {
29093
29091
  className: "perseus-widget-row"
29094
29092
  }, /*#__PURE__*/React.createElement(ColorPicker, {
29095
29093
  value: this.props.color
29096
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29094
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29097
29095
  ,
29098
29096
  onChange: this.change("color")
29099
29097
  })), /*#__PURE__*/React.createElement("div", {
29100
29098
  className: "perseus-widget-row"
29101
29099
  }, /*#__PURE__*/React.createElement(DashPicker, {
29102
29100
  value: this.props.strokeDasharray
29103
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29101
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29104
29102
  ,
29105
29103
  onChange: this.change("strokeDasharray")
29106
29104
  })), /*#__PURE__*/React.createElement("div", {
@@ -29110,7 +29108,7 @@ class ParametricEditor extends React.Component {
29110
29108
  }, "Width:", " ", /*#__PURE__*/React.createElement(NumberInput$b, {
29111
29109
  value: this.props.strokeWidth,
29112
29110
  placeholder: 2
29113
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29111
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29114
29112
  ,
29115
29113
  onChange: this.change("strokeWidth")
29116
29114
  }))));
@@ -29160,7 +29158,7 @@ class LabelEditor extends React.Component {
29160
29158
  className: "perseus-widget-row"
29161
29159
  }, /*#__PURE__*/React.createElement(TextInput$5, {
29162
29160
  value: this.props.label
29163
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29161
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29164
29162
  ,
29165
29163
  onChange: this.change("label"),
29166
29164
  style: {
@@ -29172,21 +29170,21 @@ class LabelEditor extends React.Component {
29172
29170
  buttonSets: [],
29173
29171
  buttonsVisible: "never",
29174
29172
  value: this.props.coordX
29175
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29173
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29176
29174
  ,
29177
29175
  onChange: this.change("coordX")
29178
29176
  }), /*#__PURE__*/React.createElement(TeX, null, ","), " ", /*#__PURE__*/React.createElement(MathInput, {
29179
29177
  buttonSets: [],
29180
29178
  buttonsVisible: "never",
29181
29179
  value: this.props.coordY
29182
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29180
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29183
29181
  ,
29184
29182
  onChange: this.change("coordY")
29185
29183
  }), /*#__PURE__*/React.createElement(TeX, null, "\\Large)")), /*#__PURE__*/React.createElement("div", {
29186
29184
  className: "perseus-widget-row"
29187
29185
  }, /*#__PURE__*/React.createElement(ColorPicker, {
29188
29186
  value: this.props.color
29189
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29187
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29190
29188
  ,
29191
29189
  onChange: this.change("color")
29192
29190
  })));
@@ -29231,14 +29229,14 @@ class RectangleEditor extends React.Component {
29231
29229
  buttonSets: [],
29232
29230
  buttonsVisible: "never",
29233
29231
  value: this.props.coordX
29234
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29232
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29235
29233
  ,
29236
29234
  onChange: this.change("coordX")
29237
29235
  }), /*#__PURE__*/React.createElement(TeX, null, ","), " ", /*#__PURE__*/React.createElement(MathInput, {
29238
29236
  buttonSets: [],
29239
29237
  buttonsVisible: "never",
29240
29238
  value: this.props.coordY
29241
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29239
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29242
29240
  ,
29243
29241
  onChange: this.change("coordY")
29244
29242
  }), /*#__PURE__*/React.createElement(TeX, null, "\\Large)")), /*#__PURE__*/React.createElement("div", {
@@ -29247,7 +29245,7 @@ class RectangleEditor extends React.Component {
29247
29245
  buttonSets: [],
29248
29246
  buttonsVisible: "never",
29249
29247
  value: this.props.width
29250
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29248
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29251
29249
  ,
29252
29250
  onChange: this.change("width")
29253
29251
  })), /*#__PURE__*/React.createElement("div", {
@@ -29256,7 +29254,7 @@ class RectangleEditor extends React.Component {
29256
29254
  buttonSets: [],
29257
29255
  buttonsVisible: "never",
29258
29256
  value: this.props.height
29259
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29257
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29260
29258
  ,
29261
29259
  onChange: this.change("height")
29262
29260
  })), /*#__PURE__*/React.createElement("div", {
@@ -29264,7 +29262,7 @@ class RectangleEditor extends React.Component {
29264
29262
  }, /*#__PURE__*/React.createElement(ColorPicker, {
29265
29263
  value: this.props.color,
29266
29264
  lightColors: true
29267
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29265
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29268
29266
  ,
29269
29267
  onChange: this.change("color")
29270
29268
  })), /*#__PURE__*/React.createElement("div", {
@@ -29296,7 +29294,7 @@ class InteractionEditor extends React.Component {
29296
29294
  this._updateGraphProps = newProps => {
29297
29295
  // TODO(eater): GraphSettings should name this tickStep instead
29298
29296
  // of step. Grr..
29299
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29297
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29300
29298
  this.change({
29301
29299
  graph: _.extend(_.omit(newProps, "step"), {
29302
29300
  tickStep: newProps.step
@@ -29317,13 +29315,13 @@ class InteractionEditor extends React.Component {
29317
29315
  let nextSubscript;
29318
29316
  if (elementType === "movable-point") {
29319
29317
  nextSubscript = _.max([_.max(this.state.usedVarSubscripts), -1]) + 1;
29320
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'varSubscript' does not exist on type '{}'.
29318
+ // @ts-expect-error - TS2339 - Property 'varSubscript' does not exist on type '{}'.
29321
29319
  newElement.options.varSubscript = nextSubscript;
29322
29320
  } else if (elementType === "movable-line") {
29323
29321
  nextSubscript = _.max([_.max(this.state.usedVarSubscripts), -1]) + 1;
29324
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'startSubscript' does not exist on type '{}'.
29322
+ // @ts-expect-error - TS2339 - Property 'startSubscript' does not exist on type '{}'.
29325
29323
  newElement.options.startSubscript = nextSubscript;
29326
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'endSubscript' does not exist on type '{}'.
29324
+ // @ts-expect-error - TS2339 - Property 'endSubscript' does not exist on type '{}'.
29327
29325
  newElement.options.endSubscript = nextSubscript + 1;
29328
29326
  } else if (elementType === "function") {
29329
29327
  // TODO(eater): The 22nd function added will be {(x) since '{'
@@ -29331,17 +29329,17 @@ class InteractionEditor extends React.Component {
29331
29329
  const nextLetter = String.fromCharCode(_.max([_.max(_.map(this.state.usedFunctionNames, function (c) {
29332
29330
  return c.charCodeAt(0);
29333
29331
  })), "e".charCodeAt(0)]) + 1);
29334
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'funcName' does not exist on type '{}'.
29332
+ // @ts-expect-error - TS2339 - Property 'funcName' does not exist on type '{}'.
29335
29333
  newElement.options.funcName = nextLetter;
29336
29334
  }
29337
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29335
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29338
29336
  this.change({
29339
29337
  elements: this.props.elements.concat(newElement)
29340
29338
  });
29341
29339
  };
29342
29340
  this._deleteElement = index => {
29343
29341
  const element = this.props.elements[index];
29344
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29342
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29345
29343
  this.change({
29346
29344
  elements: _.without(this.props.elements, element)
29347
29345
  });
@@ -29350,7 +29348,7 @@ class InteractionEditor extends React.Component {
29350
29348
  const element = this.props.elements[index];
29351
29349
  const newElements = _.without(this.props.elements, element);
29352
29350
  newElements.splice(index - 1, 0, element);
29353
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29351
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29354
29352
  this.change({
29355
29353
  elements: newElements
29356
29354
  });
@@ -29359,7 +29357,7 @@ class InteractionEditor extends React.Component {
29359
29357
  const element = this.props.elements[index];
29360
29358
  const newElements = _.without(this.props.elements, element);
29361
29359
  newElements.splice(index + 1, 0, element);
29362
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
29360
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
29363
29361
  this.change({
29364
29362
  elements: newElements
29365
29363
  });
@@ -29415,29 +29413,29 @@ class InteractionEditor extends React.Component {
29415
29413
  // eslint-disable-next-line react/jsx-no-bind
29416
29414
  ,
29417
29415
  onUp: n === 0 ? null :
29418
- // @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.
29416
+ // @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.
29419
29417
  this._moveElementUp.bind(this, n)
29420
29418
  // eslint-disable-next-line react/jsx-no-bind
29421
29419
  ,
29422
29420
  onDown:
29423
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29421
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29424
29422
  n === this.props.elements.length - 1 ? null :
29425
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29423
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29426
29424
  this._moveElementDown.bind(
29427
- // @ts-expect-error [FEI-5003] - 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.
29428
29426
  this, n)
29429
29427
  // eslint-disable-next-line react/jsx-no-bind
29430
- // @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.
29428
+ // @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.
29431
29429
  ,
29432
29430
  onDelete: this._deleteElement.bind(this, n),
29433
29431
  key: element.key
29434
29432
  }, /*#__PURE__*/React.createElement(MovablePointEditor, _extends({}, element.options, {
29435
29433
  onChange: newProps => {
29436
29434
  const elements = JSON.parse(JSON.stringify(
29437
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29435
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29438
29436
  this.props.elements));
29439
29437
  _.extend(elements[n].options, newProps);
29440
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29438
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29441
29439
  this.change({
29442
29440
  elements: elements
29443
29441
  });
@@ -29450,29 +29448,29 @@ class InteractionEditor extends React.Component {
29450
29448
  // eslint-disable-next-line react/jsx-no-bind
29451
29449
  ,
29452
29450
  onUp: n === 0 ? null :
29453
- // @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.
29451
+ // @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.
29454
29452
  this._moveElementUp.bind(this, n)
29455
29453
  // eslint-disable-next-line react/jsx-no-bind
29456
29454
  ,
29457
29455
  onDown:
29458
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29456
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29459
29457
  n === this.props.elements.length - 1 ? null :
29460
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29458
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29461
29459
  this._moveElementDown.bind(
29462
- // @ts-expect-error [FEI-5003] - 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.
29463
29461
  this, n)
29464
29462
  // eslint-disable-next-line react/jsx-no-bind
29465
- // @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.
29463
+ // @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.
29466
29464
  ,
29467
29465
  onDelete: this._deleteElement.bind(this, n),
29468
29466
  key: element.key
29469
29467
  }, /*#__PURE__*/React.createElement(MovableLineEditor, _extends({}, element.options, {
29470
29468
  onChange: newProps => {
29471
29469
  const elements = JSON.parse(JSON.stringify(
29472
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29470
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29473
29471
  this.props.elements));
29474
29472
  _.extend(elements[n].options, newProps);
29475
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29473
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29476
29474
  this.change({
29477
29475
  elements: elements
29478
29476
  });
@@ -29485,29 +29483,29 @@ class InteractionEditor extends React.Component {
29485
29483
  // eslint-disable-next-line react/jsx-no-bind
29486
29484
  ,
29487
29485
  onUp: n === 0 ? null :
29488
- // @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.
29486
+ // @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.
29489
29487
  this._moveElementUp.bind(this, n)
29490
29488
  // eslint-disable-next-line react/jsx-no-bind
29491
29489
  ,
29492
29490
  onDown:
29493
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29491
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29494
29492
  n === this.props.elements.length - 1 ? null :
29495
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29493
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29496
29494
  this._moveElementDown.bind(
29497
- // @ts-expect-error [FEI-5003] - 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.
29498
29496
  this, n)
29499
29497
  // eslint-disable-next-line react/jsx-no-bind
29500
- // @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.
29498
+ // @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.
29501
29499
  ,
29502
29500
  onDelete: this._deleteElement.bind(this, n),
29503
29501
  key: element.key
29504
29502
  }, /*#__PURE__*/React.createElement(PointEditor, _extends({}, element.options, {
29505
29503
  onChange: newProps => {
29506
29504
  const elements = JSON.parse(JSON.stringify(
29507
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29505
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29508
29506
  this.props.elements));
29509
29507
  _.extend(elements[n].options, newProps);
29510
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29508
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29511
29509
  this.change({
29512
29510
  elements: elements
29513
29511
  });
@@ -29520,29 +29518,29 @@ class InteractionEditor extends React.Component {
29520
29518
  // eslint-disable-next-line react/jsx-no-bind
29521
29519
  ,
29522
29520
  onUp: n === 0 ? null :
29523
- // @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.
29521
+ // @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.
29524
29522
  this._moveElementUp.bind(this, n)
29525
29523
  // eslint-disable-next-line react/jsx-no-bind
29526
29524
  ,
29527
29525
  onDown:
29528
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29526
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29529
29527
  n === this.props.elements.length - 1 ? null :
29530
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29528
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29531
29529
  this._moveElementDown.bind(
29532
- // @ts-expect-error [FEI-5003] - 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.
29533
29531
  this, n)
29534
29532
  // eslint-disable-next-line react/jsx-no-bind
29535
- // @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.
29533
+ // @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.
29536
29534
  ,
29537
29535
  onDelete: this._deleteElement.bind(this, n),
29538
29536
  key: element.key
29539
29537
  }, /*#__PURE__*/React.createElement(LineEditor, _extends({}, element.options, {
29540
29538
  onChange: newProps => {
29541
29539
  const elements = JSON.parse(JSON.stringify(
29542
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29540
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29543
29541
  this.props.elements));
29544
29542
  _.extend(elements[n].options, newProps);
29545
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29543
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29546
29544
  this.change({
29547
29545
  elements: elements
29548
29546
  });
@@ -29555,28 +29553,28 @@ class InteractionEditor extends React.Component {
29555
29553
  // eslint-disable-next-line react/jsx-no-bind
29556
29554
  ,
29557
29555
  onUp: n === 0 ? null :
29558
- // @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.
29556
+ // @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.
29559
29557
  this._moveElementUp.bind(this, n)
29560
29558
  // eslint-disable-next-line react/jsx-no-bind
29561
29559
  ,
29562
29560
  onDown:
29563
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29561
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29564
29562
  n === this.props.elements.length - 1 ? null :
29565
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29563
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29566
29564
  this._moveElementDown.bind(
29567
- // @ts-expect-error [FEI-5003] - 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.
29568
29566
  this, n)
29569
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29567
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29570
29568
  ,
29571
29569
  onDelete: this._deleteElement,
29572
29570
  key: element.key
29573
29571
  }, /*#__PURE__*/React.createElement(FunctionEditor, _extends({}, element.options, {
29574
29572
  onChange: newProps => {
29575
29573
  const elements = JSON.parse(JSON.stringify(
29576
- // @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.
29577
29575
  this.props.elements));
29578
29576
  _.extend(elements[n].options, newProps);
29579
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29577
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29580
29578
  this.change({
29581
29579
  elements: elements
29582
29580
  });
@@ -29589,28 +29587,28 @@ class InteractionEditor extends React.Component {
29589
29587
  // eslint-disable-next-line react/jsx-no-bind
29590
29588
  ,
29591
29589
  onUp: n === 0 ? null :
29592
- // @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.
29590
+ // @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.
29593
29591
  this._moveElementUp.bind(this, n)
29594
29592
  // eslint-disable-next-line react/jsx-no-bind
29595
29593
  ,
29596
29594
  onDown:
29597
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29595
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29598
29596
  n === this.props.elements.length - 1 ? null :
29599
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29597
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29600
29598
  this._moveElementDown.bind(
29601
- // @ts-expect-error [FEI-5003] - 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.
29602
29600
  this, n)
29603
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29601
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29604
29602
  ,
29605
29603
  onDelete: this._deleteElement,
29606
29604
  key: element.key
29607
29605
  }, /*#__PURE__*/React.createElement(ParametricEditor, _extends({}, element.options, {
29608
29606
  onChange: newProps => {
29609
29607
  const elements = JSON.parse(JSON.stringify(
29610
- // @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.
29611
29609
  this.props.elements));
29612
29610
  _.extend(elements[n].options, newProps);
29613
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29611
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29614
29612
  this.change({
29615
29613
  elements: elements
29616
29614
  });
@@ -29623,28 +29621,28 @@ class InteractionEditor extends React.Component {
29623
29621
  // eslint-disable-next-line react/jsx-no-bind
29624
29622
  ,
29625
29623
  onUp: n === 0 ? null :
29626
- // @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.
29624
+ // @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.
29627
29625
  this._moveElementUp.bind(this, n)
29628
29626
  // eslint-disable-next-line react/jsx-no-bind
29629
29627
  ,
29630
29628
  onDown:
29631
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29629
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29632
29630
  n === this.props.elements.length - 1 ? null :
29633
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29631
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29634
29632
  this._moveElementDown.bind(
29635
- // @ts-expect-error [FEI-5003] - 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.
29636
29634
  this, n)
29637
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29635
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29638
29636
  ,
29639
29637
  onDelete: this._deleteElement,
29640
29638
  key: element.key
29641
29639
  }, /*#__PURE__*/React.createElement(LabelEditor, _extends({}, element.options, {
29642
29640
  onChange: newProps => {
29643
29641
  const elements = JSON.parse(JSON.stringify(
29644
- // @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.
29645
29643
  this.props.elements));
29646
29644
  _.extend(elements[n].options, newProps);
29647
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29645
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29648
29646
  this.change({
29649
29647
  elements: elements
29650
29648
  });
@@ -29657,28 +29655,28 @@ class InteractionEditor extends React.Component {
29657
29655
  // eslint-disable-next-line react/jsx-no-bind
29658
29656
  ,
29659
29657
  onUp: n === 0 ? null :
29660
- // @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.
29658
+ // @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.
29661
29659
  this._moveElementUp.bind(this, n)
29662
29660
  // eslint-disable-next-line react/jsx-no-bind
29663
29661
  ,
29664
29662
  onDown:
29665
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29663
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29666
29664
  n === this.props.elements.length - 1 ? null :
29667
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29665
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29668
29666
  this._moveElementDown.bind(
29669
- // @ts-expect-error [FEI-5003] - 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.
29670
29668
  this, n)
29671
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29669
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29672
29670
  ,
29673
29671
  onDelete: this._deleteElement,
29674
29672
  key: element.key
29675
29673
  }, /*#__PURE__*/React.createElement(RectangleEditor, _extends({}, element.options, {
29676
29674
  onChange: newProps => {
29677
29675
  const elements = JSON.parse(JSON.stringify(
29678
- // @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.
29679
29677
  this.props.elements));
29680
29678
  _.extend(elements[n].options, newProps);
29681
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29679
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
29682
29680
  this.change({
29683
29681
  elements: elements
29684
29682
  });
@@ -29874,7 +29872,7 @@ class InteractiveGraphEditor extends React.Component {
29874
29872
  trackInteraction: function () {},
29875
29873
  onChange: newProps => {
29876
29874
  let correct = this.props.correct;
29877
- // @ts-expect-error [FEI-5003] - TS2532 - Object is possibly 'undefined'.
29875
+ // @ts-expect-error - TS2532 - Object is possibly 'undefined'.
29878
29876
  if (correct.type === newProps.graph.type) {
29879
29877
  correct = _.extend({}, correct, newProps.graph);
29880
29878
  } else {
@@ -29891,7 +29889,7 @@ class InteractiveGraphEditor extends React.Component {
29891
29889
  // There are a bunch of props that renderer.jsx passes to widgets via
29892
29890
  // getWidgetProps() and widget-container.jsx that the editors don't
29893
29891
  // bother passing.
29894
- // @ts-expect-error [FEI-5003] - TS2769 - No overload matches this call.
29892
+ // @ts-expect-error - TS2769 - No overload matches this call.
29895
29893
  React.createElement(InteractiveGraph, _extends({}, graphProps, {
29896
29894
  containerSizeClass: sizeClass,
29897
29895
  apiOptions: _extends({}, this.props.apiOptions, {
@@ -29900,7 +29898,7 @@ class InteractiveGraphEditor extends React.Component {
29900
29898
  }));
29901
29899
  // TODO(kevinb): Update getEquationString to only accept the data it actually
29902
29900
  // needs to compute the equation string.
29903
- // @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'.
29901
+ // @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'.
29904
29902
  equationString = InteractiveGraph.getEquationString(graphProps);
29905
29903
  } else {
29906
29904
  graph = /*#__PURE__*/React.createElement("div", {
@@ -30078,7 +30076,7 @@ class InteractiveGraphEditor extends React.Component {
30078
30076
  });
30079
30077
  _.each(["allowReflexAngles", "angleOffsetDeg", "numPoints", "numSides", "numSegments", "showAngles", "showSides", "snapTo", "snapDegrees"], function (key) {
30080
30078
  if (_.has(correct, key)) {
30081
- // @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">'.
30079
+ // @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">'.
30082
30080
  json.graph[key] = correct[key];
30083
30081
  }
30084
30082
  });
@@ -30183,7 +30181,7 @@ class FormWrappedTextField extends React.Component {
30183
30181
  return /*#__PURE__*/React.createElement("form", {
30184
30182
  className: css(...spanStyle),
30185
30183
  style: extraStyles
30186
- // @ts-expect-error [FEI-5003] - TS2322 - Type '((arg1: ChangeEvent<HTMLInputElement>) => unknown) | ((e: Event) => void)' is not assignable to type 'FormEventHandler<HTMLFormElement> | undefined'.
30184
+ // @ts-expect-error - TS2322 - Type '((arg1: ChangeEvent<HTMLInputElement>) => unknown) | ((e: Event) => void)' is not assignable to type 'FormEventHandler<HTMLFormElement> | undefined'.
30187
30185
  ,
30188
30186
  onSubmit: onSubmit || this.disableDefault
30189
30187
  }, leftSideIcon && wrappedIcon, /*#__PURE__*/React.createElement("input", _extends({}, allProps, {
@@ -30595,7 +30593,7 @@ class HoverBehavior extends React.Component {
30595
30593
  };
30596
30594
  }
30597
30595
 
30598
- // @ts-expect-error [FEI-5003] - TS2564 - Property 'focusFlag' has no initializer and is not definitely assigned in the constructor.
30596
+ // @ts-expect-error - TS2564 - Property 'focusFlag' has no initializer and is not definitely assigned in the constructor.
30599
30597
 
30600
30598
  render() {
30601
30599
  const handlers = {
@@ -30684,7 +30682,7 @@ class Checkbox extends React.Component {
30684
30682
  className: css(styles$6.checkbox, disabled && styles$6.defaultCursor),
30685
30683
  disabled: disabled,
30686
30684
  onChange: onChange
30687
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'string | number | undefined' is not assignable to type 'number | undefined'.
30685
+ // @ts-expect-error - TS2322 - Type 'string | number | undefined' is not assignable to type 'number | undefined'.
30688
30686
  ,
30689
30687
  tabIndex: tabIndex
30690
30688
  })));
@@ -30825,7 +30823,7 @@ function focusWithChromeStickyFocusBugWorkaround(element) {
30825
30823
  // this is an issue, however, so there isn't currently a way to out of the
30826
30824
  // `preventScroll` behavior.
30827
30825
 
30828
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'Element'.
30826
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'Element'.
30829
30827
  element.focus({
30830
30828
  preventScroll: true
30831
30829
  });
@@ -30840,7 +30838,7 @@ const {
30840
30838
  const findAndFocusElement = component => {
30841
30839
  const DOMNode = ReactDOM__default.findDOMNode(component);
30842
30840
  const button = DOMNode;
30843
- // @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?
30841
+ // @ts-expect-error - TS2774 - This condition will always return true since this function is always defined. Did you mean to call it instead?
30844
30842
  if (button.focus) {
30845
30843
  focusWithChromeStickyFocusBugWorkaround(button);
30846
30844
  }
@@ -30891,21 +30889,21 @@ class Option extends React.Component {
30891
30889
  ariaLabel
30892
30890
  } = this.props;
30893
30891
  return /*#__PURE__*/React.createElement("button", {
30894
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'HTMLButtonElement | null' is not assignable to type 'HTMLDivElement'.
30892
+ // @ts-expect-error - TS2322 - Type 'HTMLButtonElement | null' is not assignable to type 'HTMLDivElement'.
30895
30893
  ref: node => this.node = node,
30896
30894
  value: value,
30897
30895
  role: "menuitemradio",
30898
30896
  "aria-checked": selected,
30899
30897
  className: css(styles$4.notAButton, disabled && styles$4.cursorDefault, hideFocusState && styles$4.noFocus)
30900
- // @ts-expect-error [FEI-5003] - TS2322 - Type '(value: string) => void' is not assignable to type 'MouseEventHandler<HTMLButtonElement>'.
30898
+ // @ts-expect-error - TS2322 - Type '(value: string) => void' is not assignable to type 'MouseEventHandler<HTMLButtonElement>'.
30901
30899
  ,
30902
30900
  onClick: value => {
30903
30901
  if (!disabled && onClick) {
30904
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 0 arguments, but got 1.
30902
+ // @ts-expect-error - TS2554 - Expected 0 arguments, but got 1.
30905
30903
  onClick(value);
30906
30904
  }
30907
30905
  }
30908
- // @ts-expect-error [FEI-5003] - TS2322 - Type '(event: KeyboardEvent) => void' is not assignable to type 'KeyboardEventHandler<HTMLButtonElement>'.
30906
+ // @ts-expect-error - TS2322 - Type '(event: KeyboardEvent) => void' is not assignable to type 'KeyboardEventHandler<HTMLButtonElement>'.
30909
30907
  ,
30910
30908
  onKeyDown: event => this.handleKeyDown(event),
30911
30909
  "aria-disabled": disabled,
@@ -30953,21 +30951,21 @@ class OptionGroup extends React.Component {
30953
30951
  hideFocusState
30954
30952
  } = this.props;
30955
30953
  return /*#__PURE__*/React.createElement("div", {
30956
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'Window | null' is not assignable to type 'Top<string | number> | undefined'.
30954
+ // @ts-expect-error - TS2322 - Type 'Window | null' is not assignable to type 'Top<string | number> | undefined'.
30957
30955
  style: {
30958
30956
  top
30959
30957
  },
30960
30958
  className: css(styles$4.optionGroup, noMargin && styles$4.optionGroupNoMargin)
30961
30959
  }, React.Children.map(children, (child, index) => {
30962
- // @ts-expect-error [FEI-5003] - TS2532 - Object is possibly 'undefined'.
30960
+ // @ts-expect-error - TS2532 - Object is possibly 'undefined'.
30963
30961
  const selected = selectedValues.includes(child.props.value);
30964
30962
  const reference = selected || index === 0 ? node => this.focusedElement = node : null;
30965
30963
 
30966
- // @ts-expect-error [FEI-5003] - TS2769 - No overload matches this call.
30964
+ // @ts-expect-error - TS2769 - No overload matches this call.
30967
30965
  return /*#__PURE__*/React.cloneElement(child, _extends({}, child.props, {
30968
30966
  key: index,
30969
30967
  selected: selected,
30970
- // @ts-expect-error [FEI-5003] - TS2532 - Object is possibly 'undefined'.
30968
+ // @ts-expect-error - TS2532 - Object is possibly 'undefined'.
30971
30969
  onClick: () => onSelected(child.props.value),
30972
30970
  optionRenderer: optionRenderer,
30973
30971
  ref: reference,
@@ -31157,7 +31155,7 @@ class Marker extends React.Component {
31157
31155
  }), /*#__PURE__*/React.createElement(OptionGroup, {
31158
31156
  onSelected: this.handleSelectAnswer
31159
31157
  // TODO(WB-1096): make selectedValues immutable in wonder-blocks
31160
- // @ts-expect-error [FEI-5003] - TS2769 - No overload matches this call.
31158
+ // @ts-expect-error - TS2769 - No overload matches this call.
31161
31159
  ,
31162
31160
  selectedValues: answers
31163
31161
  }, choices.map(choice => /*#__PURE__*/React.createElement(Option, {
@@ -31285,7 +31283,7 @@ class QuestionMarkers extends React.Component {
31285
31283
  // Open answer selection dropdown for each of the specified markers.
31286
31284
  indices.forEach(index => {
31287
31285
  if (this._markers[index]) {
31288
- // @ts-expect-error [FEI-5003] - TS2533 - Object is possibly 'null' or 'undefined'.
31286
+ // @ts-expect-error - TS2533 - Object is possibly 'null' or 'undefined'.
31289
31287
  this._markers[index].openDropdown();
31290
31288
  }
31291
31289
  });
@@ -31692,7 +31690,7 @@ class LightsPuzzleEditor extends React.Component {
31692
31690
  return Changeable.change.apply(this, args);
31693
31691
  };
31694
31692
  this._handlePatternChange = e => {
31695
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
31693
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
31696
31694
  this.change("flipPattern", e.target.value);
31697
31695
  };
31698
31696
  this._changeWidth = newWidth => {
@@ -31711,7 +31709,7 @@ class LightsPuzzleEditor extends React.Component {
31711
31709
  });
31712
31710
  });
31713
31711
 
31714
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
31712
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
31715
31713
  this.change({
31716
31714
  startCells: newCells
31717
31715
  });
@@ -31721,7 +31719,7 @@ class LightsPuzzleEditor extends React.Component {
31721
31719
  return y === tileY && x === tileX;
31722
31720
  });
31723
31721
 
31724
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
31722
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
31725
31723
  this.change({
31726
31724
  startCells: newCells
31727
31725
  });
@@ -31741,7 +31739,7 @@ class LightsPuzzleEditor extends React.Component {
31741
31739
  onChange: this._changeHeight
31742
31740
  })), /*#__PURE__*/React.createElement("div", null, "Flip pattern:", /*#__PURE__*/React.createElement("select", {
31743
31741
  value: this.props.flipPattern
31744
- // @ts-expect-error [FEI-5003] - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
31742
+ // @ts-expect-error - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
31745
31743
  ,
31746
31744
  onChange: this._handlePatternChange
31747
31745
  }, _.map(_.keys(PATTERNS), (pattern, i) => {
@@ -31945,7 +31943,7 @@ class MatrixEditor extends React.Component {
31945
31943
  content: this.props.prefix,
31946
31944
  widgetEnabled: false,
31947
31945
  onChange: newProps => {
31948
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
31946
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
31949
31947
  this.change({
31950
31948
  prefix: newProps.content
31951
31949
  });
@@ -31960,7 +31958,7 @@ class MatrixEditor extends React.Component {
31960
31958
  content: this.props.suffix,
31961
31959
  widgetEnabled: false,
31962
31960
  onChange: newProps => {
31963
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
31961
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
31964
31962
  this.change({
31965
31963
  suffix: newProps.content
31966
31964
  });
@@ -32014,7 +32012,7 @@ class MeasurerEditor extends React.Component {
32014
32012
  this._changeImage = (subProp, newValue) => {
32015
32013
  const image = _.clone(this.props.image);
32016
32014
  image[subProp] = newValue;
32017
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
32015
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
32018
32016
  this.change("image", image);
32019
32017
  };
32020
32018
  this.renderLabelChoices = choices => {
@@ -32059,7 +32057,7 @@ class MeasurerEditor extends React.Component {
32059
32057
  value: image.left,
32060
32058
  useArrowKeys: true
32061
32059
  }))), /*#__PURE__*/React.createElement("div", null, "Containing area [width, height]:", " ", /*#__PURE__*/React.createElement(RangeInput$2
32062
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
32060
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
32063
32061
  , {
32064
32062
  onChange: this.change("box"),
32065
32063
  value: this.props.box,
@@ -32080,7 +32078,7 @@ class MeasurerEditor extends React.Component {
32080
32078
  onChange: this.props.onChange
32081
32079
  }))), this.props.showRuler && /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, " ", "Ruler label:", " ", /*#__PURE__*/React.createElement("select", {
32082
32080
  onChange: e =>
32083
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
32081
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
32084
32082
  this.change("rulerLabel", e.target.value),
32085
32083
  value: this.props.rulerLabel
32086
32084
  }, /*#__PURE__*/React.createElement("option", {
@@ -32091,7 +32089,7 @@ class MeasurerEditor extends React.Component {
32091
32089
  label: "Imperial"
32092
32090
  }, 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", {
32093
32091
  onChange: e =>
32094
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 2.
32092
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 2.
32095
32093
  this.change("rulerTicks", +e.target.value),
32096
32094
  value: this.props.rulerTicks
32097
32095
  }, _.map([1, 2, 4, 8, 10, 16], function (n) {
@@ -32101,14 +32099,14 @@ class MeasurerEditor extends React.Component {
32101
32099
  }, n);
32102
32100
  })))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, "Ruler pixels per unit:", " ", /*#__PURE__*/React.createElement(NumberInput$9, {
32103
32101
  placeholder: 40
32104
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
32102
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
32105
32103
  ,
32106
32104
  onChange: this.change("rulerPixels"),
32107
32105
  value: this.props.rulerPixels,
32108
32106
  useArrowKeys: true
32109
32107
  }))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, "Ruler length in units:", " ", /*#__PURE__*/React.createElement(NumberInput$9, {
32110
32108
  placeholder: 10
32111
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
32109
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
32112
32110
  ,
32113
32111
  onChange: this.change("rulerLength"),
32114
32112
  value: this.props.rulerLength,
@@ -32153,13 +32151,13 @@ class MoleculeWidgetEditor extends React.Component {
32153
32151
  return Changeable.change.apply(this, args);
32154
32152
  };
32155
32153
  this.updateMolecule = newValue => {
32156
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
32154
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
32157
32155
  this.change({
32158
32156
  smiles: newValue
32159
32157
  });
32160
32158
  };
32161
32159
  this.updateRotation = newValue => {
32162
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
32160
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
32163
32161
  this.change({
32164
32162
  rotationAngle: newValue
32165
32163
  });
@@ -32184,6 +32182,7 @@ MoleculeWidgetEditor.propTypes = _extends({}, Changeable.propTypes, {
32184
32182
  });
32185
32183
  MoleculeWidgetEditor.widgetName = "molecule-renderer";
32186
32184
 
32185
+ /* eslint-disable @khanacademy/ts-no-error-suppressions */
32187
32186
  const {
32188
32187
  ButtonGroup: ButtonGroup$1,
32189
32188
  InfoTip: InfoTip$a,
@@ -32319,7 +32318,7 @@ class NumberLineEditor extends React.Component {
32319
32318
  className: "perseus-widget-row"
32320
32319
  }, "Correct x", " ", /*#__PURE__*/React.createElement("select", {
32321
32320
  value: this.props.correctRel
32322
- // @ts-expect-error [FEI-5003] - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
32321
+ // @ts-expect-error - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
32323
32322
  ,
32324
32323
  onChange: this.onChangeRelation
32325
32324
  }, /*#__PURE__*/React.createElement("option", {
@@ -32818,14 +32817,14 @@ const NumericInputEditor = createReactClass({
32818
32817
  // TODO(emily): This doesn't actually work, because the value is either
32819
32818
  // null or undefined when undefined, probably.
32820
32819
  if (_.contains(_.pluck(this.props.answers, "value"), "")) {
32821
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'string' is not assignable to parameter of type 'never'.
32820
+ // @ts-expect-error - TS2345 - Argument of type 'string' is not assignable to parameter of type 'never'.
32822
32821
  warnings.push("One or more answers is empty");
32823
32822
  }
32824
32823
  this.props.answers.forEach((answer, i) => {
32825
32824
  const formatError = answer.strict && (!answer.answerForms || answer.answerForms.length === 0);
32826
32825
  if (formatError) {
32827
32826
  warnings.push(
32828
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'string' is not assignable to parameter of type 'never'.
32827
+ // @ts-expect-error - TS2345 - Argument of type 'string' is not assignable to parameter of type 'never'.
32829
32828
  `Answer ${i + 1} is set to string format ` + "matching, but no format was selected");
32830
32829
  }
32831
32830
  });
@@ -32836,7 +32835,7 @@ const NumericInputEditor = createReactClass({
32836
32835
  }
32837
32836
  });
32838
32837
 
32839
- /* eslint-disable one-var, react/forbid-prop-types, react/sort-comp */
32838
+ /* eslint-disable @khanacademy/ts-no-error-suppressions */
32840
32839
  const {
32841
32840
  InfoTip: InfoTip$8,
32842
32841
  TextListEditor: TextListEditor$2
@@ -32912,7 +32911,7 @@ class OrdererEditor extends React.Component {
32912
32911
  layout: this.props.layout
32913
32912
  }), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, " ", "Layout:", " ", /*#__PURE__*/React.createElement("select", {
32914
32913
  value: this.props.layout
32915
- // @ts-expect-error [FEI-5003] - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
32914
+ // @ts-expect-error - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
32916
32915
  ,
32917
32916
  onChange: this.onLayoutChange
32918
32917
  }, /*#__PURE__*/React.createElement("option", {
@@ -32921,7 +32920,7 @@ class OrdererEditor extends React.Component {
32921
32920
  value: VERTICAL$1
32922
32921
  }, "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", {
32923
32922
  value: this.props.height
32924
- // @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>'.
32925
32924
  ,
32926
32925
  onChange: this.onHeightChange
32927
32926
  }, /*#__PURE__*/React.createElement("option", {
@@ -32974,7 +32973,7 @@ class PassageEditor extends React.Component {
32974
32973
  widgetEnabled: false,
32975
32974
  placeholder: "Type passage here...",
32976
32975
  onChange: newProps => {
32977
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
32976
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
32978
32977
  this.change({
32979
32978
  passageText: newProps.content
32980
32979
  });
@@ -32990,7 +32989,7 @@ class PassageEditor extends React.Component {
32990
32989
  widgetEnabled: false,
32991
32990
  placeholder: "Type footnotes here...",
32992
32991
  onChange: newProps => {
32993
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
32992
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
32994
32993
  this.change({
32995
32994
  footnotes: newProps.content
32996
32995
  });
@@ -33009,7 +33008,7 @@ class PassageEditor extends React.Component {
33009
33008
  type: "text",
33010
33009
  defaultValue: this.props.passageTitle,
33011
33010
  onChange: e => {
33012
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
33011
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
33013
33012
  this.change({
33014
33013
  passageTitle: e.target.value
33015
33014
  });
@@ -33049,17 +33048,17 @@ class PassageRefEditor extends React.Component {
33049
33048
  render() {
33050
33049
  return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, "Passage Number: ", /*#__PURE__*/React.createElement(NumberInput$5, {
33051
33050
  value: this.props.passageNumber
33052
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
33051
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
33053
33052
  ,
33054
33053
  onChange: this.change("passageNumber")
33055
33054
  }))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, "Reference Number: ", /*#__PURE__*/React.createElement(NumberInput$5, {
33056
33055
  value: this.props.referenceNumber
33057
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
33056
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
33058
33057
  ,
33059
33058
  onChange: this.change("referenceNumber")
33060
33059
  }))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, "Summary Text: ", /*#__PURE__*/React.createElement(TextInput$2, {
33061
33060
  value: this.props.summaryText
33062
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
33061
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
33063
33062
  ,
33064
33063
  onChange: this.change("summaryText")
33065
33064
  }), /*#__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")))));
@@ -33084,7 +33083,7 @@ class PassageRefTargetEditor extends React.Component {
33084
33083
  return Changeable.change.apply(this, args);
33085
33084
  };
33086
33085
  this.handleContentChange = e => {
33087
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
33086
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
33088
33087
  this.change({
33089
33088
  content: e.target.value
33090
33089
  });
@@ -33116,12 +33115,15 @@ const {
33116
33115
  TextListEditor: TextListEditor$1
33117
33116
  } = components;
33118
33117
  const Plotter = PlotterWidget.widget;
33119
- const BAR = "bar",
33120
- LINE = "line",
33121
- PIC = "pic",
33122
- HISTOGRAM = "histogram",
33123
- DOTPLOT = "dotplot";
33124
-
33118
+ const BAR = "bar";
33119
+ const LINE = "line";
33120
+ const PIC = "pic";
33121
+ const HISTOGRAM = "histogram";
33122
+ const DOTPLOT = "dotplot";
33123
+ const plotTypes = [BAR, LINE, PIC, HISTOGRAM, DOTPLOT];
33124
+ const STARTING = "starting";
33125
+ const CORRECT = "correct";
33126
+ const editingStates = [STARTING, CORRECT];
33125
33127
  // Return a copy of array with length n, padded with given value
33126
33128
  function padArray(array, n, value) {
33127
33129
  const copy = _.clone(array);
@@ -33136,29 +33138,12 @@ const editorDefaults = {
33136
33138
  maxY: 10,
33137
33139
  snapsPerLine: 2
33138
33140
  };
33139
- const widgetPropTypes = {
33140
- type: PropTypes.oneOf([BAR, LINE, PIC, HISTOGRAM, DOTPLOT]),
33141
- labels: PropTypes.arrayOf(PropTypes.string),
33142
- categories: PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string])),
33143
- scaleY: PropTypes.number,
33144
- maxY: PropTypes.number,
33145
- snapsPerLine: PropTypes.number,
33146
- picSize: PropTypes.number,
33147
- pixBoxHeight: PropTypes.number,
33148
- picUrl: PropTypes.string,
33149
- plotDimensions: PropTypes.arrayOf(PropTypes.number),
33150
- labelInterval: PropTypes.number,
33151
- starting: PropTypes.arrayOf(PropTypes.number),
33152
- correct: PropTypes.arrayOf(PropTypes.number),
33153
- static: PropTypes.bool,
33154
- onChange: PropTypes.func
33155
- };
33156
33141
  const formatNumber = num => "$" + number.round(num, 2) + "$";
33157
33142
  class PlotterEditor extends React.Component {
33158
33143
  constructor(...args) {
33159
33144
  super(...args);
33160
33145
  this.state = {
33161
- editing: this.props.static ? "starting" : "correct",
33146
+ editing: this.props.static ? STARTING : CORRECT,
33162
33147
  pic: null,
33163
33148
  loadedUrl: null,
33164
33149
  minX: null,
@@ -33202,6 +33187,7 @@ class PlotterEditor extends React.Component {
33202
33187
  let categories;
33203
33188
  if (type === HISTOGRAM) {
33204
33189
  // Switching to histogram, add a label (0) to the left
33190
+ // @ts-expect-error - TS2769
33205
33191
  categories = [formatNumber(0)].concat(this.props.categories);
33206
33192
  this.props.onChange({
33207
33193
  type: type,
@@ -33222,7 +33208,7 @@ class PlotterEditor extends React.Component {
33222
33208
  if (categories) {
33223
33209
  // eslint-disable-next-line react/no-string-refs
33224
33210
  const node = ReactDOM__default.findDOMNode(this.refs.categories);
33225
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
33211
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
33226
33212
  node.value = categories.join(", ");
33227
33213
  }
33228
33214
  };
@@ -33269,7 +33255,7 @@ class PlotterEditor extends React.Component {
33269
33255
  starting: _.map(this.props.starting, scale)
33270
33256
  });
33271
33257
 
33272
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
33258
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
33273
33259
  ReactDOM__default.findDOMNode(this.refs.maxY).value = maxY; // eslint-disable-line react/no-string-refs
33274
33260
  };
33275
33261
  this.changeMax = e => {
@@ -33306,13 +33292,13 @@ class PlotterEditor extends React.Component {
33306
33292
  // eslint-disable-next-line react/no-string-refs
33307
33293
  const node = ReactDOM__default.findDOMNode(this.refs.categories);
33308
33294
 
33309
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
33295
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2339 - Property 'value' does not exist on type 'Element | Text'.
33310
33296
  node.value = categories.join(", ");
33311
33297
  };
33312
33298
  this.serialize = () => {
33313
33299
  const json = _.pick(this.props, "correct", "starting", "type", "labels", "categories", "scaleY", "maxY", "snapsPerLine", "labelInterval");
33314
33300
  if (this.props.type === PIC) {
33315
- // @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">'.
33301
+ // @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">'.
33316
33302
  json.picUrl = this.props.picUrl;
33317
33303
  }
33318
33304
  return json;
@@ -33338,29 +33324,21 @@ class PlotterEditor extends React.Component {
33338
33324
  }, this.props);
33339
33325
  return /*#__PURE__*/React.createElement("div", {
33340
33326
  className: "perseus-widget-plotter-editor"
33341
- }, /*#__PURE__*/React.createElement("div", null, "Chart type:", " ", _.map([BAR, LINE, PIC, HISTOGRAM, DOTPLOT], function (type) {
33327
+ }, /*#__PURE__*/React.createElement("div", null, "Chart type:", " ", plotTypes.map(type => {
33342
33328
  return /*#__PURE__*/React.createElement("label", {
33343
33329
  key: type
33344
33330
  }, /*#__PURE__*/React.createElement("input", {
33345
33331
  type: "radio",
33346
- name: "chart-type"
33347
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33348
- ,
33332
+ name: "chart-type",
33349
33333
  checked: this.props.type === type,
33350
- onChange: _.partial(
33351
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33352
- this.changeType, type)
33334
+ onChange: _.partial(this.changeType, type)
33353
33335
  }), type);
33354
- }, this)), /*#__PURE__*/React.createElement("div", null, "Labels:", " ", _.map(["x", "y"], function (axis, i) {
33336
+ }, this)), /*#__PURE__*/React.createElement("div", null, "Labels:", " ", ["x", "y"].map((axis, i) => {
33355
33337
  return /*#__PURE__*/React.createElement("label", {
33356
33338
  key: axis
33357
33339
  }, axis + ":", /*#__PURE__*/React.createElement("input", {
33358
33340
  type: "text",
33359
- onChange: _.partial(
33360
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33361
- this.changeLabel, i)
33362
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33363
- ,
33341
+ onChange: _.partial(this.changeLabel, i),
33364
33342
  defaultValue: this.props.labels[i]
33365
33343
  }));
33366
33344
  }, this)), setFromScale && /*#__PURE__*/React.createElement("div", {
@@ -33411,12 +33389,12 @@ class PlotterEditor extends React.Component {
33411
33389
  type: "text",
33412
33390
  onChange: this.changeSnaps,
33413
33391
  defaultValue: this.props.snapsPerLine
33414
- })), /*#__PURE__*/React.createElement(InfoTip$5, null, /*#__PURE__*/React.createElement("p", null, "Creates the specified number of divisions between the horizontal lines. Fewer snaps between lines makes the graph easier for the student to create correctly."))), /*#__PURE__*/React.createElement("div", null, "Editing values:", " ", ["correct", "starting"].map(editing => /*#__PURE__*/React.createElement("label", {
33392
+ })), /*#__PURE__*/React.createElement(InfoTip$5, null, /*#__PURE__*/React.createElement("p", null, "Creates the specified number of divisions between the horizontal lines. Fewer snaps between lines makes the graph easier for the student to create correctly."))), /*#__PURE__*/React.createElement("div", null, "Editing values:", " ", editingStates.map(editing => /*#__PURE__*/React.createElement("label", {
33415
33393
  key: editing
33416
33394
  }, /*#__PURE__*/React.createElement("input", {
33417
33395
  type: "radio",
33418
- disabled: editing === "correct" && this.props.static,
33419
- checked: this.props.static ? editing === "starting" : this.state.editing === editing,
33396
+ disabled: editing === CORRECT && this.props.static,
33397
+ checked: this.props.static ? editing === STARTING : this.state.editing === editing,
33420
33398
  onChange: e => this.changeEditing(editing)
33421
33399
  }), editing)), /*#__PURE__*/React.createElement(InfoTip$5, null, /*#__PURE__*/React.createElement("p", null, "Use this toggle to switch between editing the correct answer (what the student will be graded on) and the starting values (what the student will see plotted when they start the problem). Note: These cannot be the same."), /*#__PURE__*/React.createElement("p", null, "In static mode, the starting values are rendered out to the displayed widget."))), /*#__PURE__*/React.createElement(Plotter, _extends({}, props, {
33422
33400
  starting: this.props[this.state.editing],
@@ -33424,7 +33402,6 @@ class PlotterEditor extends React.Component {
33424
33402
  })));
33425
33403
  }
33426
33404
  }
33427
- PlotterEditor.propTypes = widgetPropTypes;
33428
33405
  PlotterEditor.widgetName = "plotter";
33429
33406
  PlotterEditor.defaultProps = _extends({}, editorDefaults, {
33430
33407
  correct: [1],
@@ -33436,6 +33413,7 @@ PlotterEditor.defaultProps = _extends({}, editorDefaults, {
33436
33413
  picBoxHeight: 36,
33437
33414
  plotDimensions: [275, 200],
33438
33415
  labelInterval: 1,
33416
+ // @ts-expect-error - TS2322
33439
33417
  get picUrl() {
33440
33418
  const staticUrl = Dependencies.getDependencies().staticUrl;
33441
33419
  if (staticUrl) {
@@ -33514,7 +33492,7 @@ class RadioEditor extends React.Component {
33514
33492
  constructor(..._args) {
33515
33493
  super(..._args);
33516
33494
  this.change = (...args) => {
33517
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'readonly unknown[]' is not assignable to parameter of type 'any[]'.
33495
+ // @ts-expect-error - TS2345 - Argument of type 'readonly unknown[]' is not assignable to parameter of type 'any[]'.
33518
33496
  return Changeable.change.apply(this, args);
33519
33497
  };
33520
33498
  this.onMultipleSelectChange = allowMultiple => {
@@ -33600,7 +33578,7 @@ class RadioEditor extends React.Component {
33600
33578
  hasNoneOfTheAbove: noneOfTheAbove || this.props.hasNoneOfTheAbove
33601
33579
  }, () => {
33602
33580
  // eslint-disable-next-line react/no-string-refs
33603
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'refs' does not exist on type 'ReactInstance'.
33581
+ // @ts-expect-error - TS2339 - Property 'refs' does not exist on type 'ReactInstance'.
33604
33582
  this.refs[`choice-editor${addIndex}`].refs["content-editor"].focus();
33605
33583
  });
33606
33584
  };
@@ -33611,7 +33589,7 @@ class RadioEditor extends React.Component {
33611
33589
  };
33612
33590
  this.focus = () => {
33613
33591
  // eslint-disable-next-line react/no-string-refs
33614
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'refs' does not exist on type 'ReactInstance'.
33592
+ // @ts-expect-error - TS2339 - Property 'refs' does not exist on type 'ReactInstance'.
33615
33593
  this.refs["choice-editor0"].refs["content-editor"].focus();
33616
33594
  return true;
33617
33595
  };
@@ -33746,10 +33724,10 @@ class ReactionDiagramWidgetEditor extends React.Component {
33746
33724
  };
33747
33725
  this.updateMolecule = idx => {
33748
33726
  return function (newValue) {
33749
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33727
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33750
33728
  const newSmiles = [...this.props.smiles];
33751
33729
  newSmiles[idx] = newValue;
33752
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33730
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33753
33731
  this.change({
33754
33732
  smiles: newSmiles
33755
33733
  });
@@ -33757,10 +33735,10 @@ class ReactionDiagramWidgetEditor extends React.Component {
33757
33735
  };
33758
33736
  this.updateRotation = idx => {
33759
33737
  return function (newValue) {
33760
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33738
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33761
33739
  const newRot = [...this.props.rotationAngle];
33762
33740
  newRot[idx] = newValue;
33763
- // @ts-expect-error [FEI-5003] - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33741
+ // @ts-expect-error - TS2683 - 'this' implicitly has type 'any' because it does not have a type annotation.
33764
33742
  this.change({
33765
33743
  rotationAngle: newRot
33766
33744
  });
@@ -33772,7 +33750,7 @@ class ReactionDiagramWidgetEditor extends React.Component {
33772
33750
  return _extends({}, sep);
33773
33751
  });
33774
33752
  newSep[idx][propName] = newValue;
33775
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
33753
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
33776
33754
  this.change({
33777
33755
  separators: newSep
33778
33756
  });
@@ -33858,7 +33836,7 @@ class SequenceEditor extends React.Component {
33858
33836
  return {
33859
33837
  json: _.times(this.props.json.length, i => {
33860
33838
  // eslint-disable-next-line react/no-string-refs
33861
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
33839
+ // @ts-expect-error - TS2339 - Property 'serialize' does not exist on type 'ReactInstance'.
33862
33840
  return this.refs["editor" + i].serialize();
33863
33841
  })
33864
33842
  };
@@ -33983,7 +33961,7 @@ class TextArea extends React.Component {
33983
33961
  super(...args);
33984
33962
  this.focus = () => {
33985
33963
  // eslint-disable-next-line react/no-string-refs
33986
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
33964
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
33987
33965
  this.refs.input.focus();
33988
33966
  return true;
33989
33967
  };
@@ -34010,7 +33988,7 @@ class SimpleMarkdownTesterEditor extends React.Component {
34010
33988
  };
34011
33989
  this.focus = () => {
34012
33990
  // eslint-disable-next-line react/no-string-refs
34013
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
33991
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
34014
33992
  this.refs.input.focus();
34015
33993
  return true;
34016
33994
  };
@@ -34021,7 +33999,7 @@ class SimpleMarkdownTesterEditor extends React.Component {
34021
33999
  render() {
34022
34000
  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, {
34023
34001
  value: this.props.value
34024
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
34002
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
34025
34003
  ,
34026
34004
  onChange: this.change("value")
34027
34005
  // eslint-disable-next-line react/no-string-refs
@@ -34045,7 +34023,7 @@ class SimulatorEditor extends React.Component {
34045
34023
  constructor(..._args) {
34046
34024
  super(..._args);
34047
34025
  this.change = (...args) => {
34048
- // @ts-expect-error [FEI-5003] - TS2345 - Argument of type 'readonly unknown[]' is not assignable to parameter of type 'any[]'.
34026
+ // @ts-expect-error - TS2345 - Argument of type 'readonly unknown[]' is not assignable to parameter of type 'any[]'.
34049
34027
  return Changeable.change.apply(this, args);
34050
34028
  };
34051
34029
  this.handleTargetValueChange = (propName, e) => {
@@ -34108,7 +34086,7 @@ SimulatorEditor.defaultProps = {
34108
34086
  proportionOrPercentage: "proportion"
34109
34087
  };
34110
34088
 
34111
- /* eslint-disable react/forbid-prop-types */
34089
+ /* eslint-disable @khanacademy/ts-no-error-suppressions */
34112
34090
  const {
34113
34091
  InfoTip: InfoTip$3,
34114
34092
  PropCheckBox: PropCheckBox$1,
@@ -34142,7 +34120,7 @@ class SorterEditor extends React.Component {
34142
34120
  layout: this.props.layout
34143
34121
  }), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, " ", "Layout:", " ", /*#__PURE__*/React.createElement("select", {
34144
34122
  value: this.props.layout
34145
- // @ts-expect-error [FEI-5003] - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
34123
+ // @ts-expect-error - TS2322 - Type '(arg1: ChangeEvent<HTMLInputElement>) => void' is not assignable to type 'ChangeEventHandler<HTMLSelectElement>'.
34146
34124
  ,
34147
34125
  onChange: this.onLayoutChange
34148
34126
  }, /*#__PURE__*/React.createElement("option", {
@@ -34178,7 +34156,7 @@ class TableEditor extends React.Component {
34178
34156
  constructor(...args) {
34179
34157
  super(...args);
34180
34158
  this.focus = () => {
34181
- // @ts-expect-error [FEI-5003] - TS2531 - Object is possibly 'null'. | TS2339 - Property 'focus' does not exist on type 'Element | Text'.
34159
+ // @ts-expect-error - TS2531 - Object is possibly 'null'. | TS2339 - Property 'focus' does not exist on type 'Element | Text'.
34182
34160
  ReactDOM__default.findDOMNode(this.refs.numberOfColumns).focus(); // eslint-disable-line react/no-string-refs
34183
34161
  };
34184
34162
  this.onSizeInput = (numRawRows, numRawColumns) => {
@@ -34774,7 +34752,7 @@ const ShapeTypes = {
34774
34752
  const coord0 = points[0].coord || points[0];
34775
34753
  const coord1 = points[1].coord || points[1];
34776
34754
  const radius = point.distanceToPoint(coord0, coord1);
34777
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 1 arguments, but got 0.
34755
+ // @ts-expect-error - TS2554 - Expected 1 arguments, but got 0.
34778
34756
  perimeter.remove();
34779
34757
  perimeter = graphie.circle(coord0, radius, _.extend({
34780
34758
  stroke: KhanColors.DYNAMIC,
@@ -34790,7 +34768,7 @@ const ShapeTypes = {
34790
34768
  remove: function () {
34791
34769
  // Not _.bind because the remove function changes
34792
34770
  // when the perimeter is redrawn
34793
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 1 arguments, but got 0.
34771
+ // @ts-expect-error - TS2554 - Expected 1 arguments, but got 0.
34794
34772
  perimeter.remove();
34795
34773
  }
34796
34774
  };
@@ -34829,10 +34807,10 @@ const ShapeTypes = {
34829
34807
  const line2_0 = [points2[1], points2[0]];
34830
34808
  const line2_2 = [points2[1], points2[2]];
34831
34809
  const equalUnflipped =
34832
- // @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'.
34810
+ // @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'.
34833
34811
  ray.equal(line1_0, line2_0) && ray.equal(line1_2, line2_2);
34834
34812
  const equalFlipped =
34835
- // @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'.
34813
+ // @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'.
34836
34814
  ray.equal(line1_0, line2_2) && ray.equal(line1_2, line2_0);
34837
34815
  return equalUnflipped || equalFlipped;
34838
34816
  },
@@ -34868,7 +34846,7 @@ class TransformationsShapeEditor extends React.Component {
34868
34846
  const pointCount = arraySum(_.map(types, ShapeTypes.getPointCountForType));
34869
34847
 
34870
34848
  // eslint-disable-next-line react/no-string-refs
34871
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'props' does not exist on type 'ReactInstance'.
34849
+ // @ts-expect-error - TS2339 - Property 'props' does not exist on type 'ReactInstance'.
34872
34850
  const radius = scaleToRange(4, this.refs.graph.props.range);
34873
34851
  const offset = (1 / 2 - 1 / pointCount) * 180;
34874
34852
  const coords = _.times(pointCount, function (i) {
@@ -34884,12 +34862,12 @@ class TransformationsShapeEditor extends React.Component {
34884
34862
  };
34885
34863
  this.updateCoords = () => {
34886
34864
  this.props.onChange({
34887
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'shape' does not exist on type 'TransformationsShapeEditor'.
34865
+ // @ts-expect-error - TS2339 - Property 'shape' does not exist on type 'TransformationsShapeEditor'.
34888
34866
  shape: this.shape.toJSON()
34889
34867
  });
34890
34868
  };
34891
34869
  this.setupGraphie = graphie => {
34892
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'shape' does not exist on type 'TransformationsShapeEditor'.
34870
+ // @ts-expect-error - TS2339 - Property 'shape' does not exist on type 'TransformationsShapeEditor'.
34893
34871
  this.shape = ShapeTypes.addMovableShape(graphie, {
34894
34872
  editable: true,
34895
34873
  snap: graphie.snap,
@@ -34942,13 +34920,13 @@ class TransformationsShapeEditor extends React.Component {
34942
34920
 
34943
34921
  componentDidMount() {
34944
34922
  // eslint-disable-next-line react/no-string-refs
34945
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'graphie' does not exist on type 'ReactInstance'.
34923
+ // @ts-expect-error - TS2339 - Property 'graphie' does not exist on type 'ReactInstance'.
34946
34924
  this.setupGraphie(this.refs.graph.graphie());
34947
34925
  }
34948
34926
  componentDidUpdate(prevProps) {
34949
34927
  if (!deepEq(prevProps.shape, this.props.shape)) {
34950
34928
  // eslint-disable-next-line react/no-string-refs
34951
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'reset' does not exist on type 'ReactInstance'.
34929
+ // @ts-expect-error - TS2339 - Property 'reset' does not exist on type 'ReactInstance'.
34952
34930
  this.refs.graph.reset();
34953
34931
  }
34954
34932
  }
@@ -34979,7 +34957,7 @@ class TransformerEditor extends React.Component {
34979
34957
  };
34980
34958
  this.serialize = () => {
34981
34959
  // eslint-disable-next-line react/no-string-refs
34982
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'getEditorJSON' does not exist on type 'ReactInstance'.
34960
+ // @ts-expect-error - TS2339 - Property 'getEditorJSON' does not exist on type 'ReactInstance'.
34983
34961
  const json = this.refs.explorer.getEditorJSON();
34984
34962
  json.correct = json.answer;
34985
34963
  delete json.answer;
@@ -35120,7 +35098,7 @@ class UnitExample extends React.Component {
35120
35098
  }
35121
35099
  // TODO(jangmi, CP-3288): Remove usage of `UNSAFE_componentWillMount`
35122
35100
  UNSAFE_componentWillMount() {
35123
- // @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; }'.
35101
+ // @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; }'.
35124
35102
  this._checkValidity(this.props);
35125
35103
  }
35126
35104
  UNSAFE_componentWillReceiveProps(nextProps) {
@@ -35151,13 +35129,13 @@ class UnitInputEditor extends React.Component {
35151
35129
  };
35152
35130
  this.handleAcceptingUnitsChange = event => {
35153
35131
  const acceptingUnits = event.target.value.split(",").map(str => str.trim()).filter(str => str !== "");
35154
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
35132
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
35155
35133
  this.change({
35156
35134
  acceptingUnits
35157
35135
  });
35158
35136
  };
35159
35137
  this.handleSigfigChange = sigfigs => {
35160
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
35138
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
35161
35139
  this.change({
35162
35140
  sigfigs
35163
35141
  });
@@ -35166,7 +35144,7 @@ class UnitInputEditor extends React.Component {
35166
35144
  return sigfigs > 0 && sigfigs <= MAX_SIGFIGS;
35167
35145
  };
35168
35146
  this._setAccepting = val => {
35169
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
35147
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
35170
35148
  this.change({
35171
35149
  accepting: val
35172
35150
  });
@@ -35227,7 +35205,7 @@ class UnitInputEditor extends React.Component {
35227
35205
  key: i
35228
35206
  }));
35229
35207
 
35230
- // @ts-expect-error [FEI-5003] - TS2322 - Type 'Element' is not assignable to type 'null'.
35208
+ // @ts-expect-error - TS2322 - Type 'Element' is not assignable to type 'null'.
35231
35209
  acceptingElem = /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("input", {
35232
35210
  type: "text",
35233
35211
  defaultValue: acceptingUnits.join(", "),
@@ -35335,7 +35313,7 @@ class TextInput extends React.Component {
35335
35313
  super(...args);
35336
35314
  this.focus = () => {
35337
35315
  // eslint-disable-next-line react/no-string-refs
35338
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
35316
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
35339
35317
  this.refs.input.focus();
35340
35318
  return true;
35341
35319
  };
@@ -35371,7 +35349,7 @@ class ExampleWidget extends React.Component {
35371
35349
  };
35372
35350
  this.focus = () => {
35373
35351
  // eslint-disable-next-line react/no-string-refs
35374
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
35352
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
35375
35353
  this.refs.input.focus();
35376
35354
  return true;
35377
35355
  };
@@ -35419,7 +35397,7 @@ class ExampleWidget extends React.Component {
35419
35397
  , {
35420
35398
  ref: "input",
35421
35399
  value: this.props.value
35422
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 3 arguments, but got 1.
35400
+ // @ts-expect-error - TS2554 - Expected 3 arguments, but got 1.
35423
35401
  ,
35424
35402
  onChange: this.change("value")
35425
35403
  });
@@ -35459,7 +35437,7 @@ class SimpleMarkdownTester extends React.Component {
35459
35437
  };
35460
35438
  this.focus = () => {
35461
35439
  // eslint-disable-next-line react/no-string-refs
35462
- // @ts-expect-error [FEI-5003] - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
35440
+ // @ts-expect-error - TS2339 - Property 'focus' does not exist on type 'ReactInstance'.
35463
35441
  this.refs.input.focus();
35464
35442
  return true;
35465
35443
  };
@@ -35484,7 +35462,7 @@ class SimpleMarkdownTester extends React.Component {
35484
35462
  };
35485
35463
  }
35486
35464
  render() {
35487
- // @ts-expect-error [FEI-5003] - TS2554 - Expected 2 arguments, but got 1.
35465
+ // @ts-expect-error - TS2554 - Expected 2 arguments, but got 1.
35488
35466
  const parsed = mdParse(this.props.value);
35489
35467
  const output = mdOutput(parsed);
35490
35468
  return /*#__PURE__*/React.createElement("div", null, output);