Skip to content

fix: make adding exponents to superscripted bases safe - #3113

Open
davidsusu wants to merge 1 commit into
arnog:masterfrom
davidsusu:fix/3099-double-exponentiation-insert
Open

davidsusu wants to merge 1 commit into
arnog:masterfrom
davidsusu:fix/3099-double-exponentiation-insert

Conversation

@davidsusu

Copy link
Copy Markdown

Fixes #3107

Adding an exponent to a base that already had one could leave MathLive exporting invalid LaTeX like 1^2^3. This fix keeps the grouping intact, producing {1^2}^3 so the expression stays the same when saved and loaded again.

@davidsusu
davidsusu force-pushed the fix/3099-double-exponentiation-insert branch from 57c939e to 5a5560d Compare October 18, 2026 20:47
@davidsusu

Copy link
Copy Markdown
Author

I amended some more changes to make the fix more robust across different expressions, with additional regression tests to cover the expanded behavior.

This branch has not been deployed

No deployments
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.

\enclose notation is not sized or positioned to its content

1 participant