mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Math
synced 2024-11-27 17:01:07 +00:00
Merge "Ignore misplaced limits commands"
This commit is contained in:
commit
0e0d5ff1f7
|
@ -930,7 +930,7 @@ class BaseParsing {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$mrow = new MMLmrow( TexClass::ORD, [] );
|
$mrow = new MMLmrow( TexClass::ORD, [] );
|
||||||
$opParsed = ( $operatorContent != null && $operatorContent["limits"] )
|
$opParsed = ( $operatorContent["limits"] ?? false )
|
||||||
? $operatorContent["limits"]->renderMML( $argsOp ) : "";
|
? $operatorContent["limits"]->renderMML( $argsOp ) : "";
|
||||||
|
|
||||||
if ( $node instanceof DQ ) {
|
if ( $node instanceof DQ ) {
|
||||||
|
@ -940,6 +940,9 @@ class BaseParsing {
|
||||||
$munderOver = new MMLmunderover();
|
$munderOver = new MMLmunderover();
|
||||||
return $munderOver->encapsulateRaw( $opParsed . $mrow->encapsulateRaw( $node->getDown()->renderMML() )
|
return $munderOver->encapsulateRaw( $opParsed . $mrow->encapsulateRaw( $node->getDown()->renderMML() )
|
||||||
. $mrow->encapsulateRaw( $node->getUp()->renderMML() ) );
|
. $mrow->encapsulateRaw( $node->getUp()->renderMML() ) );
|
||||||
|
} elseif ( $name === 'limits' || $name === 'nolimits' ) {
|
||||||
|
// Don't render limits
|
||||||
|
return '';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -118,8 +118,7 @@ class Literal extends TexNode {
|
||||||
$ret = BaseMethods::checkAndParse( $inputP, $arguments,
|
$ret = BaseMethods::checkAndParse( $inputP, $arguments,
|
||||||
array_merge( $operatorContent ?? [], $state ?? [] ),
|
array_merge( $operatorContent ?? [], $state ?? [] ),
|
||||||
$this, false );
|
$this, false );
|
||||||
if ( $ret ) {
|
if ( $ret || $ret === '' ) {
|
||||||
|
|
||||||
return $ret;
|
return $ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue