@khanacademy/perseus 53.0.0 → 54.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (52) hide show
  1. package/dist/components/highlighting/types.d.ts +2 -1
  2. package/dist/components.d.ts +0 -1
  3. package/dist/es/index.js +1101 -2034
  4. package/dist/es/index.js.map +1 -1
  5. package/dist/es/strings.js +101 -14
  6. package/dist/es/strings.js.map +1 -1
  7. package/dist/index.d.ts +1 -1
  8. package/dist/index.js +1180 -2058
  9. package/dist/index.js.map +1 -1
  10. package/dist/interactive2/movable.d.ts +2 -1
  11. package/dist/server-item-renderer.d.ts +0 -3
  12. package/dist/strings.d.ts +93 -6
  13. package/dist/strings.js +184 -58
  14. package/dist/strings.js.map +1 -1
  15. package/dist/types.d.ts +3 -24
  16. package/dist/util/graphie.d.ts +1 -1
  17. package/dist/widget-ai-utils/radio/radio-ai-utils.d.ts +2 -1
  18. package/dist/widget-type-utils.d.ts +1 -0
  19. package/dist/widgets/categorizer/categorizer.d.ts +1 -2
  20. package/dist/widgets/cs-program/cs-program.d.ts +0 -2
  21. package/dist/widgets/dropdown/dropdown.d.ts +0 -2
  22. package/dist/widgets/expression/expression.d.ts +3 -10
  23. package/dist/widgets/iframe/iframe.d.ts +1 -1
  24. package/dist/widgets/interactive-graph.d.ts +2 -86
  25. package/dist/widgets/interactive-graphs/backgrounds/axis-labels.d.ts +4 -1
  26. package/dist/widgets/interactive-graphs/graphs/angle.d.ts +2 -1
  27. package/dist/widgets/interactive-graphs/graphs/circle.d.ts +6 -2
  28. package/dist/widgets/interactive-graphs/graphs/components/hairlines.d.ts +7 -0
  29. package/dist/widgets/interactive-graphs/graphs/components/movable-point-view.d.ts +1 -0
  30. package/dist/widgets/interactive-graphs/graphs/components/svg-line.d.ts +2 -1
  31. package/dist/widgets/interactive-graphs/graphs/linear-system.d.ts +2 -2
  32. package/dist/widgets/interactive-graphs/graphs/linear.d.ts +1 -1
  33. package/dist/widgets/interactive-graphs/graphs/point.d.ts +3 -2
  34. package/dist/widgets/interactive-graphs/graphs/polygon.d.ts +3 -2
  35. package/dist/widgets/interactive-graphs/graphs/ray.d.ts +1 -1
  36. package/dist/widgets/interactive-graphs/graphs/screenreader-text.d.ts +2 -1
  37. package/dist/widgets/interactive-graphs/graphs/segment.d.ts +2 -2
  38. package/dist/widgets/interactive-graphs/graphs/sinusoid.d.ts +2 -1
  39. package/dist/widgets/interactive-graphs/graphs/utils.d.ts +16 -4
  40. package/dist/widgets/interactive-graphs/interactive-graph-question-builder.d.ts +1 -2
  41. package/dist/widgets/interactive-graphs/mafs-graph.d.ts +0 -2
  42. package/dist/widgets/interactive-graphs/reducer/interactive-graph-action.d.ts +3 -3
  43. package/dist/widgets/interactive-graphs/stateful-mafs-graph.d.ts +0 -2
  44. package/dist/widgets/label-image/label-image.d.ts +1 -3
  45. package/dist/widgets/number-line/number-line.d.ts +0 -2
  46. package/dist/widgets/numeric-input/numeric-input.d.ts +0 -2
  47. package/dist/widgets/orderer/orderer.d.ts +0 -2
  48. package/dist/widgets/sorter/sorter.d.ts +1 -2
  49. package/dist/widgets.d.ts +1 -2
  50. package/package.json +46 -46
  51. package/dist/components/graph.d.ts +0 -61
  52. package/dist/widgets/interactive-graphs/mafs-supported-graph-types.d.ts +0 -4
@@ -1,6 +1,6 @@
1
1
  import type { Constraint, ConstraintCallbacks, Coord } from "./types";
2
2
  import type { Graphie } from "../util/graphie";
3
- export interface State {
3
+ interface State {
4
4
  added?: boolean;
5
5
  isHovering?: boolean;
6
6
  isMouseOver?: boolean;
@@ -96,3 +96,4 @@ export declare class Movable<Options extends Record<string, any>> {
96
96
  getMouseTarget(): Element;
97
97
  } | null | undefined;
98
98
  }
99
+ export {};
@@ -150,9 +150,6 @@ declare const ref: React.ForwardRefExoticComponent<Omit<Pick<SharedRendererProps
150
150
  canScrollPage?: boolean;
151
151
  crossOutEnabled?: boolean;
152
152
  editorChangeDelay?: number;
153
- flags?: {
154
- mafs?: false | { [Key in typeof import("./types").MafsGraphTypeFlags[number]]?: boolean; };
155
- };
156
153
  onWidgetStartProps?: (widgets: import("@khanacademy/perseus-core").PerseusWidgetsMap) => void;
157
154
  }> | undefined;
158
155
  linterContext?: PerseusLinter.LinterContextProps | undefined;
package/dist/strings.d.ts CHANGED
@@ -178,6 +178,10 @@ export type PerseusStrings = {
178
178
  simulationLoadFail: string;
179
179
  simulationLocaleWarning: string;
180
180
  selectAnAnswer: string;
181
+ srGraphInstructions: string;
182
+ srUnlimitedGraphInstructions: string;
183
+ xAxis: string;
184
+ yAxis: string;
181
185
  addPoint: string;
182
186
  removePoint: string;
183
187
  graphKeyboardPrompt: string;
@@ -242,13 +246,19 @@ export type PerseusStrings = {
242
246
  point2X: string;
243
247
  point2Y: string;
244
248
  }) => string;
245
- srAngleSideAtCoordinates: ({ point, side, x, y, }: {
246
- point: number;
247
- side: string;
249
+ srAngleStartingSide: ({ x, y }: {
248
250
  x: string;
249
251
  y: string;
250
252
  }) => string;
251
- srAngleVertexAtCoordinatesWithAngleMeasure: ({ x, y, angleMeasure, }: {
253
+ srAngleEndingSide: ({ x, y }: {
254
+ x: string;
255
+ y: string;
256
+ }) => string;
257
+ srAngleVertex: ({ x, y }: {
258
+ x: string;
259
+ y: string;
260
+ }) => string;
261
+ srAngleVertexWithAngleMeasure: ({ x, y, angleMeasure, }: {
252
262
  x: string;
253
263
  y: string;
254
264
  angleMeasure: string;
@@ -263,6 +273,14 @@ export type PerseusStrings = {
263
273
  endingSideX: string;
264
274
  endingSideY: string;
265
275
  }) => string;
276
+ srAngleInteractiveElements: ({ vertexX, vertexY, startingSideX, startingSideY, endingSideX, endingSideY, }: {
277
+ vertexX: string;
278
+ vertexY: string;
279
+ startingSideX: string;
280
+ startingSideY: string;
281
+ endingSideX: string;
282
+ endingSideY: string;
283
+ }) => string;
266
284
  srSingleSegmentGraphAriaLabel: string;
267
285
  srMultipleSegmentGraphAriaLabel: ({ countOfSegments, }: {
268
286
  countOfSegments: number;
@@ -376,6 +394,52 @@ export type PerseusStrings = {
376
394
  point3X: string;
377
395
  point3Y: string;
378
396
  }) => string;
397
+ srPolygonGraph: string;
398
+ srPolygonGraphCoordinatePlane: string;
399
+ srPolygonGraphPointsNum: ({ num }: {
400
+ num: number;
401
+ }) => string;
402
+ srPolygonGraphPointsOne: string;
403
+ srPolygonElementsNum: ({ num }: {
404
+ num: number;
405
+ }) => string;
406
+ srPolygonElementsOne: string;
407
+ srPolygonPointAngleApprox: ({ angle }: {
408
+ angle: string;
409
+ }) => string;
410
+ srPolygonPointAngle: ({ angle }: {
411
+ angle: number;
412
+ }) => string;
413
+ srPolygonSideLength: ({ pointNum, length, }: {
414
+ pointNum: number;
415
+ length: string;
416
+ }) => string;
417
+ srPolygonSideLengthApprox: ({ pointNum, length, }: {
418
+ pointNum: number;
419
+ length: string;
420
+ }) => string;
421
+ srUnlimitedPolygonEmpty: string;
422
+ srSinusoidGraph: string;
423
+ srSinusoidRootPoint: ({ x, y }: {
424
+ x: string;
425
+ y: string;
426
+ }) => string;
427
+ srSinusoidPeakPoint: ({ x, y }: {
428
+ x: string;
429
+ y: string;
430
+ }) => string;
431
+ srSinusoidDescription: ({ minValue, maxValue, cycleStart, cycleEnd, }: {
432
+ minValue: string;
433
+ maxValue: string;
434
+ cycleStart: string;
435
+ cycleEnd: string;
436
+ }) => string;
437
+ srSinusoidInteractiveElements: ({ point1X, point1Y, point2X, point2Y, }: {
438
+ point1X: string;
439
+ point1Y: string;
440
+ point2X: string;
441
+ point2Y: string;
442
+ }) => string;
379
443
  };
380
444
  /**
381
445
  * Untranslated strings used in Perseus. To be used by an external
@@ -525,6 +589,10 @@ export declare const strings: {
525
589
  openPolygon: string;
526
590
  srInteractiveElements: string;
527
591
  srNoInteractiveElements: string;
592
+ srGraphInstructions: string;
593
+ srUnlimitedGraphInstructions: string;
594
+ xAxis: string;
595
+ yAxis: string;
528
596
  srPointAtCoordinates: string;
529
597
  srCircleGraph: string;
530
598
  srCircleShape: string;
@@ -542,10 +610,13 @@ export declare const strings: {
542
610
  srLinearGraphBothIntercepts: string;
543
611
  srLinearGraphOriginIntercept: string;
544
612
  srLinearGrabHandle: string;
545
- srAngleSideAtCoordinates: string;
546
- srAngleVertexAtCoordinatesWithAngleMeasure: string;
613
+ srAngleStartingSide: string;
614
+ srAngleEndingSide: string;
615
+ srAngleVertex: string;
616
+ srAngleVertexWithAngleMeasure: string;
547
617
  srAngleGraphAriaLabel: string;
548
618
  srAngleGraphAriaDescription: string;
619
+ srAngleInteractiveElements: string;
549
620
  srSingleSegmentGraphAriaLabel: string;
550
621
  srMultipleSegmentGraphAriaLabel: string;
551
622
  srMultipleSegmentIndividualLabel: string;
@@ -576,6 +647,22 @@ export declare const strings: {
576
647
  srQuadraticPointAxis: string;
577
648
  srQuadraticPointQuadrant: string;
578
649
  srQuadraticInteractiveElements: string;
650
+ srPolygonGraph: string;
651
+ srPolygonGraphCoordinatePlane: string;
652
+ srPolygonGraphPointsNum: string;
653
+ srPolygonGraphPointsOne: string;
654
+ srPolygonElementsNum: string;
655
+ srPolygonElementsOne: string;
656
+ srPolygonPointAngleApprox: string;
657
+ srPolygonPointAngle: string;
658
+ srPolygonSideLength: string;
659
+ srPolygonSideLengthApprox: string;
660
+ srUnlimitedPolygonEmpty: string;
661
+ srSinusoidGraph: string;
662
+ srSinusoidRootPoint: string;
663
+ srSinusoidPeakPoint: string;
664
+ srSinusoidDescription: string;
665
+ srSinusoidInteractiveElements: string;
579
666
  };
580
667
  /**
581
668
  * Mock strings for the Perseus package, to be used for tests and Storybook.
package/dist/strings.js CHANGED
@@ -159,7 +159,11 @@ const strings = {
159
159
  // translation tickets after all interactive graph SR strings have
160
160
  // been finalized. Remove this comment after the tickets have been
161
161
  // created.
162
- srPointAtCoordinates: "Point %(num)s at %(x)s comma %(y)s",
162
+ srGraphInstructions: "Use the Tab key to move through the interactive elements in the graph. When an interactive element has focus, use the Arrow keys to move it.",
163
+ srUnlimitedGraphInstructions: "Press Shift + Enter to interact with the graph. Use the Tab key to move through the interactive elements in the graph and access the graph Action Bar. When an interactive element has focus, use the Arrow keys to move it or use the Delete key to remove it from the graph. Use the buttons in the Action Bar to add or adjust elements within the graph.",
164
+ xAxis: "X-axis",
165
+ yAxis: "Y-axis",
166
+ srPointAtCoordinates: "Point %(num)s at %(x)s comma %(y)s.",
163
167
  srCircleGraph: "A circle on a coordinate plane.",
164
168
  srCircleShape: "Circle. The center point is at %(centerX)s comma %(centerY)s.",
165
169
  srCircleRadiusPoint: "Radius point at %(radiusPointX)s comma %(radiusPointY)s.",
@@ -176,14 +180,17 @@ const strings = {
176
180
  srLinearGraphBothIntercepts: "The line crosses the X-axis at %(xIntercept)s comma 0 and the Y-axis at 0 comma %(yIntercept)s.",
177
181
  srLinearGraphOriginIntercept: "The line crosses the x and y axes at the graph's origin.",
178
182
  srLinearGrabHandle: "Line from %(point1X)s comma %(point1Y)s to %(point2X)s comma %(point2Y)s.",
179
- srAngleSideAtCoordinates: "Point %(point)s, %(side)s at %(x)s comma %(y)s",
180
- srAngleVertexAtCoordinatesWithAngleMeasure: "Point 2, vertex at %(x)s comma %(y)s. Angle %(angleMeasure)s degrees",
183
+ srAngleStartingSide: "Point 3, starting side at %(x)s comma %(y)s.",
184
+ srAngleEndingSide: "Point 2, ending side at %(x)s comma %(y)s.",
185
+ srAngleVertex: "Point 1, vertex at %(x)s comma %(y)s.",
186
+ srAngleVertexWithAngleMeasure: "Point 1, vertex at %(x)s comma %(y)s. Angle %(angleMeasure)s degrees.",
181
187
  srAngleGraphAriaLabel: "An angle on a coordinate plane.",
182
188
  srAngleGraphAriaDescription: "The angle measure is %(angleMeasure)s degrees with a vertex at %(vertexX)s comma %(vertexY)s, a point on the starting side at %(startingSideX)s comma %(startingSideY)s and a point on the ending side at %(endingSideX)s comma %(endingSideY)s",
189
+ srAngleInteractiveElements: "An angle formed by 3 points. The vertex is at %(vertexX)s comma %(vertexY)s. The starting side point is at %(startingSideX)s comma %(startingSideY)s. The ending side point is at %(endingSideX)s comma %(endingSideY)s.",
183
190
  srSingleSegmentGraphAriaLabel: "A line segment on a coordinate plane.",
184
191
  srMultipleSegmentGraphAriaLabel: "%(countOfSegments)s line segments on a coordinate plane.",
185
- srMultipleSegmentIndividualLabel: "Segment %(indexOfSegment)s: Endpoint 1 at %(point1X)s comma %(point1Y)s. Endpoint 2 %(point2X)s comma %(point2Y)s.",
186
- srSingleSegmentLabel: "Endpoint 1 at %(point1X)s comma %(point1Y)s. Endpoint 2 %(point2X)s comma %(point2Y)s.",
192
+ srMultipleSegmentIndividualLabel: "Segment %(indexOfSegment)s: Endpoint 1 at %(point1X)s comma %(point1Y)s. Endpoint 2 at %(point2X)s comma %(point2Y)s.",
193
+ srSingleSegmentLabel: "Endpoint 1 at %(point1X)s comma %(point1Y)s. Endpoint 2 at %(point2X)s comma %(point2Y)s.",
187
194
  srSegmentLength: "Segment length %(length)s units.",
188
195
  srSingleSegmentGraphEndpointAriaLabel: "Endpoint %(endpointNumber)s at %(x)s comma %(y)s.",
189
196
  srMultipleSegmentGraphEndpointAriaLabel: "Endpoint %(endpointNumber)s on segment %(indexOfSegment)s at %(x)s comma %(y)s.",
@@ -209,7 +216,23 @@ const strings = {
209
216
  srQuadraticPointOrigin: "Point %(pointNumber)s on parabola at the origin.",
210
217
  srQuadraticPointAxis: "Point %(pointNumber)s on parabola at %(x)s comma %(y)s.",
211
218
  srQuadraticPointQuadrant: "Point %(pointNumber)s on parabola in quadrant %(quadrant)s at %(x)s comma %(y)s.",
212
- srQuadraticInteractiveElements: "Parabola with points at %(point1X)s comma %(point1Y)s, %(point2X)s comma %(point2Y)s, and %(point3X)s comma %(point3Y)s."
219
+ srQuadraticInteractiveElements: "Parabola with points at %(point1X)s comma %(point1Y)s, %(point2X)s comma %(point2Y)s, and %(point3X)s comma %(point3Y)s.",
220
+ srPolygonGraph: "A polygon.",
221
+ srPolygonGraphCoordinatePlane: "A polygon on a coordinate plane.",
222
+ srPolygonGraphPointsNum: "The polygon has %(num)s points.",
223
+ srPolygonGraphPointsOne: "The polygon has 1 point.",
224
+ srPolygonElementsNum: "A polygon with %(num)s points.",
225
+ srPolygonElementsOne: "A polygon with 1 point.",
226
+ srPolygonPointAngleApprox: "Angle approximately equal to %(angle)s degrees.",
227
+ srPolygonPointAngle: "Angle equal to %(angle)s degrees.",
228
+ srPolygonSideLength: "A line segment, length equal to %(length)s units, connects to point %(pointNum)s.",
229
+ srPolygonSideLengthApprox: "A line segment, length approximately equal to %(length)s units, connects to point %(pointNum)s.",
230
+ srUnlimitedPolygonEmpty: "An empty coordinate plane.",
231
+ srSinusoidGraph: "A sinusoid function on a coordinate plane.",
232
+ srSinusoidRootPoint: "Midline intersection at %(x)s comma %(y)s.",
233
+ srSinusoidPeakPoint: "Extremum point at %(x)s comma %(y)s.",
234
+ srSinusoidDescription: "The graph shows a wave with a minimum value of %(minValue)s and a maximum value of %(maxValue)s. The wave completes a full cycle from %(cycleStart)s to %(cycleEnd)s.",
235
+ srSinusoidInteractiveElements: "Sinusoid graph with midline intersection point at %(point1X)s comma %(point1Y)s and extremum point at %(point2X)s comma %(point2Y)s."
213
236
  // The above strings are used for interactive graph SR descriptions.
214
237
  };
215
238
 
@@ -472,6 +495,10 @@ const mockStrings = {
472
495
  simulationLocaleWarning: "Sorry, this simulation isn't available in your language.",
473
496
  selectAnAnswer: "Select an answer",
474
497
  // The following strings are used for interactive graph SR descriptions.
498
+ srGraphInstructions: "Use the Tab key to move through the interactive elements in the graph. When an interactive element has focus, use the Arrow keys to move it.",
499
+ srUnlimitedGraphInstructions: "Press Shift + Enter to interact with the graph. Use the Tab key to move through the interactive elements in the graph and access the graph Action Bar. When an interactive element has focus, use the Arrow keys to move it or use the Delete key to remove it from the graph. Use the buttons in the Action Bar to add or adjust elements within the graph.",
500
+ xAxis: "X-axis",
501
+ yAxis: "Y-axis",
475
502
  graphKeyboardPrompt: "Press Shift + Enter to interact with the graph",
476
503
  addPoint: "Add Point",
477
504
  removePoint: "Remove Point",
@@ -483,7 +510,7 @@ const mockStrings = {
483
510
  x,
484
511
  y
485
512
  } = _ref27;
486
- return `Point ${num} at ${x} comma ${y}`;
513
+ return `Point ${num} at ${x} comma ${y}.`;
487
514
  },
488
515
  srInteractiveElements: _ref28 => {
489
516
  let {
@@ -569,25 +596,37 @@ const mockStrings = {
569
596
  } = _ref37;
570
597
  return `Line from ${point1X} comma ${point1Y} to ${point2X} comma ${point2Y}.`;
571
598
  },
572
- srAngleSideAtCoordinates: _ref38 => {
599
+ srAngleStartingSide: _ref38 => {
573
600
  let {
574
- point,
575
- side,
576
601
  x,
577
602
  y
578
603
  } = _ref38;
579
- return `Point ${point}, ${side} at ${x} comma ${y}`;
604
+ return `Point 3, starting side at ${x} comma ${y}.`;
580
605
  },
581
- srAngleVertexAtCoordinatesWithAngleMeasure: _ref39 => {
606
+ srAngleEndingSide: _ref39 => {
607
+ let {
608
+ x,
609
+ y
610
+ } = _ref39;
611
+ return `Point 2, ending side at ${x} comma ${y}.`;
612
+ },
613
+ srAngleVertex: _ref40 => {
614
+ let {
615
+ x,
616
+ y
617
+ } = _ref40;
618
+ return `Point 1, vertex at ${x} comma ${y}.`;
619
+ },
620
+ srAngleVertexWithAngleMeasure: _ref41 => {
582
621
  let {
583
622
  x,
584
623
  y,
585
624
  angleMeasure
586
- } = _ref39;
587
- return `Point 2, vertex at ${x} comma ${y}. Angle ${angleMeasure} degrees`;
625
+ } = _ref41;
626
+ return `Point 1, vertex at ${x} comma ${y}. Angle ${angleMeasure} degrees.`;
588
627
  },
589
628
  srAngleGraphAriaLabel: "An angle on a coordinate plane.",
590
- srAngleGraphAriaDescription: _ref40 => {
629
+ srAngleGraphAriaDescription: _ref42 => {
591
630
  let {
592
631
  angleMeasure,
593
632
  vertexX,
@@ -596,118 +635,129 @@ const mockStrings = {
596
635
  startingSideY,
597
636
  endingSideX,
598
637
  endingSideY
599
- } = _ref40;
638
+ } = _ref42;
600
639
  return `The angle measure is ${angleMeasure} degrees with a vertex at ${vertexX} comma ${vertexY}, a point on the starting side at ${startingSideX} comma ${startingSideY} and a point on the ending side at ${endingSideX} comma ${endingSideY}.`;
601
640
  },
641
+ srAngleInteractiveElements: _ref43 => {
642
+ let {
643
+ vertexX,
644
+ vertexY,
645
+ startingSideX,
646
+ startingSideY,
647
+ endingSideX,
648
+ endingSideY
649
+ } = _ref43;
650
+ return `An angle formed by 3 points. The vertex is at ${vertexX} comma ${vertexY}. The starting side point is at ${startingSideX} comma ${startingSideY}. The ending side point is at ${endingSideX} comma ${endingSideY}.`;
651
+ },
602
652
  srSingleSegmentGraphAriaLabel: "A line segment on a coordinate plane.",
603
- srMultipleSegmentGraphAriaLabel: _ref41 => {
653
+ srMultipleSegmentGraphAriaLabel: _ref44 => {
604
654
  let {
605
655
  countOfSegments
606
- } = _ref41;
656
+ } = _ref44;
607
657
  return `${countOfSegments} segments on a coordinate plane.`;
608
658
  },
609
- srMultipleSegmentIndividualLabel: _ref42 => {
659
+ srMultipleSegmentIndividualLabel: _ref45 => {
610
660
  let {
611
661
  point1X,
612
662
  point1Y,
613
663
  point2X,
614
664
  point2Y,
615
665
  indexOfSegment
616
- } = _ref42;
666
+ } = _ref45;
617
667
  return `Segment ${indexOfSegment}: Endpoint 1 at ${point1X} comma ${point1Y}. Endpoint 2 at ${point2X} comma ${point2Y}.`;
618
668
  },
619
- srSingleSegmentLabel: _ref43 => {
669
+ srSingleSegmentLabel: _ref46 => {
620
670
  let {
621
671
  point1X,
622
672
  point1Y,
623
673
  point2X,
624
674
  point2Y
625
- } = _ref43;
675
+ } = _ref46;
626
676
  return `Endpoint 1 at ${point1X} comma ${point1Y}. Endpoint 2 at ${point2X} comma ${point2Y}.`;
627
677
  },
628
- srSegmentLength: _ref44 => {
678
+ srSegmentLength: _ref47 => {
629
679
  let {
630
680
  length
631
- } = _ref44;
681
+ } = _ref47;
632
682
  return `Segment length ${length} units.`;
633
683
  },
634
- srSingleSegmentGraphEndpointAriaLabel: _ref45 => {
684
+ srSingleSegmentGraphEndpointAriaLabel: _ref48 => {
635
685
  let {
636
686
  endpointNumber,
637
687
  x,
638
688
  y
639
- } = _ref45;
689
+ } = _ref48;
640
690
  return `Endpoint ${endpointNumber} at ${x} comma ${y}.`;
641
691
  },
642
- srMultipleSegmentGraphEndpointAriaLabel: _ref46 => {
692
+ srMultipleSegmentGraphEndpointAriaLabel: _ref49 => {
643
693
  let {
644
694
  endpointNumber,
645
695
  x,
646
696
  y,
647
697
  indexOfSegment
648
- } = _ref46;
698
+ } = _ref49;
649
699
  return `Endpoint ${endpointNumber} on segment ${indexOfSegment} at ${x} comma ${y}.`;
650
700
  },
651
- srSegmentGrabHandle: _ref47 => {
701
+ srSegmentGrabHandle: _ref50 => {
652
702
  let {
653
703
  point1X,
654
704
  point1Y,
655
705
  point2X,
656
706
  point2Y
657
- } = _ref47;
707
+ } = _ref50;
658
708
  return `Segment from ${point1X} comma ${point1Y} to ${point2X} comma ${point2Y}.`;
659
709
  },
660
710
  srLinearSystemGraph: "Two lines on a coordinate plane.",
661
- srLinearSystemPoints: _ref48 => {
711
+ srLinearSystemPoints: _ref51 => {
662
712
  let {
663
713
  lineNumber,
664
714
  point1X,
665
715
  point1Y,
666
716
  point2X,
667
717
  point2Y
668
- } = _ref48;
718
+ } = _ref51;
669
719
  return `Line ${lineNumber} has two points, point 1 at ${point1X} comma ${point1Y} and point 2 at ${point2X} comma ${point2Y}.`;
670
720
  },
671
- srLinearSystemPoint: _ref49 => {
721
+ srLinearSystemPoint: _ref52 => {
672
722
  let {
673
723
  lineNumber,
674
724
  pointSequence,
675
725
  x,
676
726
  y
677
- } = _ref49;
727
+ } = _ref52;
678
728
  return `Point ${pointSequence} on line ${lineNumber} at ${x} comma ${y}.`;
679
729
  },
680
730
  srRayGraph: "A ray on a coordinate plane.",
681
- srRayPoints: _ref50 => {
731
+ srRayPoints: _ref53 => {
682
732
  let {
683
733
  point1X,
684
734
  point1Y,
685
735
  point2X,
686
736
  point2Y
687
- } = _ref50;
737
+ } = _ref53;
688
738
  return `The endpoint is at ${point1X} comma ${point1Y} and the ray goes through point ${point2X} comma ${point2Y}.`;
689
739
  },
690
- srRayGrabHandle: _ref51 => {
740
+ srRayGrabHandle: _ref54 => {
691
741
  let {
692
742
  point1X,
693
743
  point1Y,
694
744
  point2X,
695
745
  point2Y
696
- } = _ref51;
746
+ } = _ref54;
697
747
  return `Ray with endpoint ${point1X} comma ${point1Y} going through point ${point2X} comma ${point2Y}.`;
698
748
  },
699
- srRayEndpoint: _ref52 => {
749
+ srRayEndpoint: _ref55 => {
700
750
  let {
701
751
  x,
702
752
  y
703
- } = _ref52;
753
+ } = _ref55;
704
754
  return `Endpoint at ${x} comma ${y}.`;
705
755
  },
706
- srRayTerminalPoint: _ref53 => {
756
+ srRayTerminalPoint: _ref56 => {
707
757
  let {
708
758
  x,
709
759
  y
710
- } = _ref53;
760
+ } = _ref56;
711
761
  return `Through point at ${x} comma ${y}.`;
712
762
  },
713
763
  srQuadraticGraph: "A parabola on a 4-quadrant coordinate plane.",
@@ -716,55 +766,55 @@ const mockStrings = {
716
766
  srQuadraticGraphVertexOrigin: "Vertex is at the origin.",
717
767
  srQuadraticGraphVertexXAxis: "Vertex is on the X-axis.",
718
768
  srQuadraticGraphVertexYAxis: "Vertex is on the Y-axis.",
719
- srQuadraticGraphVertexQuadrant: _ref54 => {
769
+ srQuadraticGraphVertexQuadrant: _ref57 => {
720
770
  let {
721
771
  quadrant
722
- } = _ref54;
772
+ } = _ref57;
723
773
  return `Vertex is in quadrant ${quadrant}.`;
724
774
  },
725
- srQuadraticTwoXIntercepts: _ref55 => {
775
+ srQuadraticTwoXIntercepts: _ref58 => {
726
776
  let {
727
777
  intercept1,
728
778
  intercept2
729
- } = _ref55;
779
+ } = _ref58;
730
780
  return `The X-intercepts are at ${intercept1} comma 0 and ${intercept2} comma 0.`;
731
781
  },
732
- srQuadraticOneXIntercept: _ref56 => {
782
+ srQuadraticOneXIntercept: _ref59 => {
733
783
  let {
734
784
  intercept
735
- } = _ref56;
785
+ } = _ref59;
736
786
  return `The X-intercept is at ${intercept} comma 0.`;
737
787
  },
738
- srQuadraticYIntercept: _ref57 => {
788
+ srQuadraticYIntercept: _ref60 => {
739
789
  let {
740
790
  intercept
741
- } = _ref57;
791
+ } = _ref60;
742
792
  return `The Y-intercept is at 0 comma ${intercept}.`;
743
793
  },
744
- srQuadraticPointOrigin: _ref58 => {
794
+ srQuadraticPointOrigin: _ref61 => {
745
795
  let {
746
796
  pointNumber
747
- } = _ref58;
797
+ } = _ref61;
748
798
  return `Point ${pointNumber} on parabola at the origin.`;
749
799
  },
750
- srQuadraticPointAxis: _ref59 => {
800
+ srQuadraticPointAxis: _ref62 => {
751
801
  let {
752
802
  pointNumber,
753
803
  x,
754
804
  y
755
- } = _ref59;
805
+ } = _ref62;
756
806
  return `Point ${pointNumber} on parabola at ${x} comma ${y}.`;
757
807
  },
758
- srQuadraticPointQuadrant: _ref60 => {
808
+ srQuadraticPointQuadrant: _ref63 => {
759
809
  let {
760
810
  pointNumber,
761
811
  x,
762
812
  y,
763
813
  quadrant
764
- } = _ref60;
814
+ } = _ref63;
765
815
  return `Point ${pointNumber} on parabola in quadrant ${quadrant} at ${x} comma ${y}.`;
766
816
  },
767
- srQuadraticInteractiveElements: _ref61 => {
817
+ srQuadraticInteractiveElements: _ref64 => {
768
818
  let {
769
819
  point1X,
770
820
  point1Y,
@@ -772,8 +822,84 @@ const mockStrings = {
772
822
  point2Y,
773
823
  point3X,
774
824
  point3Y
775
- } = _ref61;
825
+ } = _ref64;
776
826
  return `Parabola with points at ${point1X} comma ${point1Y}, ${point2X} comma ${point2Y}, and ${point3X} comma ${point3Y}.`;
827
+ },
828
+ srPolygonGraph: "A polygon.",
829
+ srPolygonGraphCoordinatePlane: "A polygon on a coordinate plane.",
830
+ srPolygonGraphPointsNum: _ref65 => {
831
+ let {
832
+ num
833
+ } = _ref65;
834
+ return `The polygon has ${num} points.`;
835
+ },
836
+ srPolygonGraphPointsOne: "The polygon has 1 point.",
837
+ srPolygonElementsNum: _ref66 => {
838
+ let {
839
+ num
840
+ } = _ref66;
841
+ return `A polygon with ${num} points.`;
842
+ },
843
+ srPolygonElementsOne: "A polygon with 1 point.",
844
+ srPolygonPointAngleApprox: _ref67 => {
845
+ let {
846
+ angle
847
+ } = _ref67;
848
+ return `Angle approximately equal to ${angle} degrees.`;
849
+ },
850
+ srPolygonPointAngle: _ref68 => {
851
+ let {
852
+ angle
853
+ } = _ref68;
854
+ return `Angle equal to ${angle} degrees.`;
855
+ },
856
+ srPolygonSideLength: _ref69 => {
857
+ let {
858
+ pointNum,
859
+ length
860
+ } = _ref69;
861
+ return `A line segment, length equal to ${length} units, connects to point ${pointNum}.`;
862
+ },
863
+ srPolygonSideLengthApprox: _ref70 => {
864
+ let {
865
+ pointNum,
866
+ length
867
+ } = _ref70;
868
+ return `A line segment, length approximately equal to ${length} units, connects to point ${pointNum}.`;
869
+ },
870
+ srUnlimitedPolygonEmpty: "An empty coordinate plane.",
871
+ srSinusoidGraph: "A sinusoid function on a coordinate plane.",
872
+ srSinusoidRootPoint: _ref71 => {
873
+ let {
874
+ x,
875
+ y
876
+ } = _ref71;
877
+ return `Midline intersection at ${x} comma ${y}.`;
878
+ },
879
+ srSinusoidPeakPoint: _ref72 => {
880
+ let {
881
+ x,
882
+ y
883
+ } = _ref72;
884
+ return `Extremum point at ${x} comma ${y}.`;
885
+ },
886
+ srSinusoidDescription: _ref73 => {
887
+ let {
888
+ minValue,
889
+ maxValue,
890
+ cycleStart,
891
+ cycleEnd
892
+ } = _ref73;
893
+ return `The graph shows a wave with a minimum value of ${minValue} and a maximum value of ${maxValue}. The wave completes a full cycle from ${cycleStart} to ${cycleEnd}.`;
894
+ },
895
+ srSinusoidInteractiveElements: _ref74 => {
896
+ let {
897
+ point1X,
898
+ point1Y,
899
+ point2X,
900
+ point2Y
901
+ } = _ref74;
902
+ return `Sinusoid graph with midline intersection point at ${point1X} comma ${point1Y} and extremum point at ${point2X} comma ${point2Y}.`;
777
903
  }
778
904
  // The above strings are used for interactive graph SR descriptions.
779
905
  };