Skip to content
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

MathJax: Add condition for Math expression parsing #11

Merged
merged 3 commits into from
Jul 25, 2024

Conversation

dat-boris
Copy link
Collaborator

@dat-boris dat-boris commented Jul 24, 2024

Summary:

We previously thought (and Khanmigo is prompted) that expression
should use \(...\) - but in real life we also have seen \[...\]
for the wrapping of MathJax.

This is a simple fix for that, as well as adding a test case for it
in our task.json ensure it works.

This also fixes an issue for Firefox when we see browser misrendering,
which we can retry by clearTypeset.

Test Plan:

Run yarn start to ensure that expression display, as well as highlighting
works with the other type of expressions.

image

We previously thought (and Khanmigo is prompted) that expression
should use `\(...\)` - but in real life we also have seen `\[...\]`
for the wrapping of MathJax.

This is a simple fix for that, as well as adding a test case for it
in our task.json ensure it works.

Test Plan:

Run `yarn start` to ensure that expression display, as well as highlighting
works with the other type of expressions.
@dat-boris dat-boris self-assigned this Jul 24, 2024
@dat-boris dat-boris marked this pull request as ready for review July 24, 2024 16:53
@dat-boris dat-boris requested review from lizfaubell and a team July 24, 2024 16:54
Copy link

@lizfaubell lizfaubell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@dat-boris dat-boris merged commit 7c5cf6b into master Jul 25, 2024
4 of 5 checks passed
khan-actions-bot pushed a commit to Khan/label-studio that referenced this pull request Jul 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants