mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Math
synced 2024-11-24 07:34:22 +00:00
Add new MathHook
* Adds a new hook that is called after the rendering this is required to keep the MathIndex up to date for the MathSearch extension. * The hook can be used for special modifications of the output format. Change-Id: I7b45b4398c10ffe75f481a82c149ba4f66820338
This commit is contained in:
parent
0c3f9d69fe
commit
68f9e96240
|
@ -126,7 +126,11 @@ class MathHooks {
|
|||
wfDebugLog( "Math" , "Rendering failed. Printing error message." );
|
||||
return $renderer->getLastError();
|
||||
}
|
||||
|
||||
wfRunHooks( 'MathFormulaRendered',
|
||||
array( &$renderer,
|
||||
&$renderedMath,
|
||||
$parser->getTitle()->getArticleID(),
|
||||
$parser->nextLinkID() ) );// Enables indexing of math formula
|
||||
if ( $wgUseMathJax ) {
|
||||
$parser->getOutput()->addModules( array( 'ext.math.mathjax.enabler' ) );
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue