mirror of
https://github.com/Smaug123/KaTeX
synced 2025-10-17 00:38:39 +00:00
committed by
Kevin Barabash
parent
db1cccdeab
commit
6e75ebdc2d
@@ -96,6 +96,14 @@ function parseArray(
|
||||
if (next === "&") {
|
||||
parser.consume();
|
||||
} else if (next === "\\end") {
|
||||
// Arrays terminate newlines with `\crcr` which consumes a `\cr` if
|
||||
// the last line is empty.
|
||||
const lastRow = body[body.length - 1][0].value;
|
||||
if (body.length > 1
|
||||
&& lastRow.value.length === 1
|
||||
&& lastRow.value[0].value.length === 0) {
|
||||
body.pop();
|
||||
}
|
||||
break;
|
||||
} else if (next === "\\\\" || next === "\\cr") {
|
||||
const cr = parser.parseFunction();
|
||||
|
Reference in New Issue
Block a user