@khanacademy/perseus 1.2.0 → 1.3.1

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 (29) hide show
  1. package/CHANGELOG.md +19 -0
  2. package/dist/es/index.css +3 -3
  3. package/dist/es/index.js +145 -179
  4. package/dist/es/index.js.map +1 -1
  5. package/dist/index.css +3 -3
  6. package/dist/index.js +143 -177
  7. package/dist/index.js.map +1 -1
  8. package/package.json +2 -2
  9. package/src/index.js +1 -0
  10. package/src/multi-items/__tests__/__snapshots__/multi-renderer_test.js.snap +21 -11
  11. package/src/styles/widgets/passage.less +7 -3
  12. package/src/widgets/__stories__/passage-ref.stories.jsx +6 -2
  13. package/src/widgets/__stories__/passage.stories.jsx +9 -1
  14. package/src/widgets/__stories__/radio.stories.jsx +11 -0
  15. package/src/widgets/__testdata__/passage-ref_testdata.js +62 -0
  16. package/src/widgets/__testdata__/passage_testdata.js +25 -0
  17. package/src/widgets/__testdata__/radio_testdata.js +52 -0
  18. package/src/widgets/__tests__/__snapshots__/group_test.jsx.snap +21 -11
  19. package/src/widgets/__tests__/__snapshots__/passage-ref_test.jsx.snap +18 -18
  20. package/src/widgets/__tests__/__snapshots__/passage_test.jsx.snap +36 -36
  21. package/src/widgets/__tests__/__snapshots__/radio_test.jsx.snap +221 -117
  22. package/src/widgets/__tests__/passage_test.jsx +6 -8
  23. package/src/widgets/__tests__/radio_test.jsx +3 -1
  24. package/src/widgets/passage.jsx +12 -41
  25. package/src/widgets/radio/__stories__/sat-styles.stories.jsx +191 -0
  26. package/src/widgets/radio/base-radio.jsx +1 -2
  27. package/src/widgets/radio/choice.jsx +4 -10
  28. package/src/widgets/radio/widget.jsx +128 -129
  29. package/src/widgets/passage/get-line-height-for-node.js +0 -9
@@ -219,13 +219,13 @@ exports[`passage widget should snapshot multiple passages (mobile: false) 1`] =
219
219
  <div>
220
220
  <div>
221
221
  <div
222
- class="measurer_vtwrnx"
222
+ aria-hidden="true"
223
+ class="measurer_225hir"
223
224
  >
224
- <div>
225
- <div
226
- class="paragraph"
227
- />
228
- <div />
225
+ <div
226
+ class="paragraph"
227
+ >
228
+ Line Height Measurement
229
229
  </div>
230
230
  </div>
231
231
  <div
@@ -711,13 +711,13 @@ exports[`passage widget should snapshot multiple passages (mobile: false) 1`] =
711
711
  <div>
712
712
  <div>
713
713
  <div
714
- class="measurer_vtwrnx"
714
+ aria-hidden="true"
715
+ class="measurer_225hir"
715
716
  >
716
- <div>
717
- <div
718
- class="paragraph"
719
- />
720
- <div />
717
+ <div
718
+ class="paragraph"
719
+ >
720
+ Line Height Measurement
721
721
  </div>
722
722
  </div>
723
723
  <div
@@ -1090,13 +1090,13 @@ exports[`passage widget should snapshot multiple passages (mobile: true) 1`] = `
1090
1090
  <div>
1091
1091
  <div>
1092
1092
  <div
1093
- class="measurer_vtwrnx"
1093
+ aria-hidden="true"
1094
+ class="measurer_225hir"
1094
1095
  >
1095
- <div>
1096
- <div
1097
- class="paragraph"
1098
- />
1099
- <div />
1096
+ <div
1097
+ class="paragraph"
1098
+ >
1099
+ Line Height Measurement
1100
1100
  </div>
1101
1101
  </div>
1102
1102
  <div
@@ -1582,13 +1582,13 @@ exports[`passage widget should snapshot multiple passages (mobile: true) 1`] = `
1582
1582
  <div>
1583
1583
  <div>
1584
1584
  <div
1585
- class="measurer_vtwrnx"
1585
+ aria-hidden="true"
1586
+ class="measurer_225hir"
1586
1587
  >
1587
- <div>
1588
- <div
1589
- class="paragraph"
1590
- />
1591
- <div />
1588
+ <div
1589
+ class="paragraph"
1590
+ >
1591
+ Line Height Measurement
1592
1592
  </div>
1593
1593
  </div>
1594
1594
  <div
@@ -1840,13 +1840,13 @@ exports[`passage widget should snapshot simple passage (mobile: false) 1`] = `
1840
1840
  <div>
1841
1841
  <div>
1842
1842
  <div
1843
- class="measurer_vtwrnx"
1843
+ aria-hidden="true"
1844
+ class="measurer_225hir"
1844
1845
  >
1845
- <div>
1846
- <div
1847
- class="paragraph"
1848
- />
1849
- <div />
1846
+ <div
1847
+ class="paragraph"
1848
+ >
1849
+ Line Height Measurement
1850
1850
  </div>
1851
1851
  </div>
1852
1852
  <div
@@ -1941,13 +1941,13 @@ exports[`passage widget should snapshot simple passage (mobile: true) 1`] = `
1941
1941
  <div>
1942
1942
  <div>
1943
1943
  <div
1944
- class="measurer_vtwrnx"
1944
+ aria-hidden="true"
1945
+ class="measurer_225hir"
1945
1946
  >
1946
- <div>
1947
- <div
1948
- class="paragraph"
1949
- />
1950
- <div />
1947
+ <div
1948
+ class="paragraph"
1949
+ >
1950
+ Line Height Measurement
1951
1951
  </div>
1952
1952
  </div>
1953
1953
  <div