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

fix: \hline after \cr #3735

Merged
merged 2 commits into from Oct 22, 2022
Merged

fix: \hline after \cr #3735

merged 2 commits into from Oct 22, 2022

Conversation

ronkok
Copy link
Collaborator

@ronkok ronkok commented Oct 10, 2022

Support \hline when it occurs after a \cr within an environment. Fixes #3734.

@codecov
Copy link

codecov bot commented Oct 10, 2022

Codecov Report

Merging #3735 (af3547a) into main (be07984) will increase coverage by 0.00%.
The diff coverage is 100.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #3735   +/-   ##
=======================================
  Coverage   92.97%   92.98%           
=======================================
  Files          91       91           
  Lines        6765     6769    +4     
  Branches     1571     1572    +1     
=======================================
+ Hits         6290     6294    +4     
  Misses        437      437           
  Partials       38       38           
Impacted Files Coverage Δ
src/environments/array.js 98.04% <100.00%> (+0.01%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update be07984...af3547a. Read the comment docs.

@edemaine edemaine changed the title Fix: \hline after \cr fix: \hline after \cr Oct 22, 2022
Copy link
Member

@edemaine edemaine left a comment

Choose a reason for hiding this comment

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

Thanks for fixing this!

At first I thought this felt a bit hacky, but I think it's a general property of how we're simulating \cr and \hline, which are fairly different from how LaTeX does it. In the end, I can't think of a better way, except possibly adding a consumeRelax() feature to the parser. But it seems we don't actually (need to) do this anywhere else.

@edemaine edemaine enabled auto-merge (squash) October 22, 2022 16:05
@edemaine edemaine merged commit ebf6bf5 into KaTeX:main Oct 22, 2022
KaTeX-bot added a commit that referenced this pull request Oct 22, 2022
## [0.16.3](v0.16.2...v0.16.3) (2022-10-22)

### Bug Fixes

* \hline after \cr ([#3735](#3735)) ([ebf6bf5](ebf6bf5)), closes [#3734](#3734)
@KaTeX-bot
Copy link
Member

🎉 This PR is included in version 0.16.3 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

\hline not working after \cr
3 participants