Skip to content

Fix problem with \vert becoming stretchy after enrichment. (mathjax/MathJax#3530)#1440

Open
dpvc wants to merge 1 commit intodevelopfrom
issue3530
Open

Fix problem with \vert becoming stretchy after enrichment. (mathjax/MathJax#3530)#1440
dpvc wants to merge 1 commit intodevelopfrom
issue3530

Conversation

@dpvc
Copy link
Member

@dpvc dpvc commented Feb 27, 2026

This PR fixes a problem with \vert losing its stretchy="false" attribute when in infix form (where this is the default), but after semantic enrichment, being in pre- or postfix position (where it is not). This is similar to #1426, which handled explicit | characters, but missed handling \vert. The tests were updated to account for the difference.

An alternative to this (and #1426) would be to adjust the filter that removes redundant attributes to leave explicit stretchy attributes when the mo content is |. If you prefer that, I will redo this PR.

Resolves issue mathjax/MathJax#3530

@dpvc dpvc requested a review from zorkow February 27, 2026 13:06
@dpvc dpvc added this to the v4.2 milestone Feb 27, 2026
@codecov
Copy link

codecov bot commented Feb 27, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 86.49%. Comparing base (5caee44) to head (67e1d02).

Additional details and impacted files
@@            Coverage Diff             @@
##           develop    #1440     +/-   ##
==========================================
  Coverage    86.49%   86.49%             
==========================================
  Files          340      340             
  Lines        86044    86047      +3     
  Branches      4833     3191   -1642     
==========================================
+ Hits         74425    74428      +3     
- Misses       11595    11619     +24     
+ Partials        24        0     -24     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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.

1 participant