-
Notifications
You must be signed in to change notification settings - Fork 351
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Locked Labels] Count lone unescaped $ as regular dollar signs #1875
Merged
+209
−84
Commits on Nov 16, 2024
-
[Locked Figure Aria] Fix $ edge cases for spoken math aria labels
I received a couple suggestions in PR #1854. I'm implmementing them here: - Wrote a helper function that joins labels together so that we don't have to duplicate that code for every single locked figure. - Stopped calling `generateSpokenMathDetails()` on the whole aria string for the locked figure. Instead, it's now being called within the new helper function so that the labels can individually be converted, and we don't have to worry about the edge case with two different labels having dollar signs and causing all the content in between to be counted as TeX when it shouldn't. - Handled the case with a lone unescaped dollar sign, which should not count as TeX. Note: The lone unescaped dollar isn't handled for the TeX inside the graph itself yet. This will be in the next PR. Issue: https://khanacademy.atlassian.net/browse/LEMS-2548 Test plan: `yarn jest` Storybook - http://localhost:6006/?path=/story/perseuseditor-widgets-interactive-graph--mafs-with-locked-figure-labels-all-flags - Add two visible labels to the point, with one having "$1 and" as the label and the other having "$1" as the label. - Press the autogenerate button and confirm that the "and" is normal and not "a n d". Also confirm that the dollar signs show up normally. - Add two TeX labels and confirm that the auto-generated text is as expected. - Repeat for all the other locked figures.
Configuration menu - View commit details
-
Copy full SHA for 3058e93 - Browse repository at this point
Copy the full SHA 3058e93View commit details -
[Locked Labels] Count lone unescaped $ as regular dollar signs
Right now, if you type "$1" into the locked label input, it shows up as "undefined1" in the graph TeX. - Update the parsed content to count a lone unescaped $ as a regular $. Issue: https://khanacademy.atlassian.net/browse/LEMS-2591 Test plan: `yarn jest packages/perseus/src/widgets/interactive-graphs/utils.test.ts` Storybook - Go to http://localhost:6006/?path=/story/perseuseditor-widgets-interactive-graph--interactive-graph-with-aria-label - Create a new locked figure - Add a label "$1" and confirm it shows up as "$1" in the preview - Play around with different escaped and unescaped dollar signs and confirm they work as expected
Configuration menu - View commit details
-
Copy full SHA for a271489 - Browse repository at this point
Copy the full SHA a271489View commit details
Commits on Nov 20, 2024
-
Configuration menu - View commit details
-
Copy full SHA for 3379e89 - Browse repository at this point
Copy the full SHA 3379e89View commit details -
Configuration menu - View commit details
-
Copy full SHA for 90c76cd - Browse repository at this point
Copy the full SHA 90c76cdView commit details -
Configuration menu - View commit details
-
Copy full SHA for 8a22f88 - Browse repository at this point
Copy the full SHA 8a22f88View commit details -
Configuration menu - View commit details
-
Copy full SHA for 93cfb8f - Browse repository at this point
Copy the full SHA 93cfb8fView commit details -
Configuration menu - View commit details
-
Copy full SHA for 7aad8b1 - Browse repository at this point
Copy the full SHA 7aad8b1View commit details -
Configuration menu - View commit details
-
Copy full SHA for b6be09d - Browse repository at this point
Copy the full SHA b6be09dView commit details -
Configuration menu - View commit details
-
Copy full SHA for f71abc4 - Browse repository at this point
Copy the full SHA f71abc4View commit details -
Configuration menu - View commit details
-
Copy full SHA for b57fd42 - Browse repository at this point
Copy the full SHA b57fd42View commit details -
Configuration menu - View commit details
-
Copy full SHA for 7827abc - Browse repository at this point
Copy the full SHA 7827abcView commit details
Commits on Nov 26, 2024
-
Configuration menu - View commit details
-
Copy full SHA for 0b65428 - Browse repository at this point
Copy the full SHA 0b65428View commit details
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.