Add MathJax 3 support

This commit is contained in:
Sauli Anto
2019-09-28 13:02:32 +03:00
parent 566c9a40cb
commit eed45a5dd3
3 changed files with 62 additions and 17 deletions

View File

@@ -39,7 +39,7 @@ export function renderEquation( equation, element, engine = 'katex', display = f
}
export function isMathJaxVersion3( version ) {
return version && typeof version === 'string' && version.split( '.' ).length === 3 && version.split( '.' )[0] === '3';
return version && typeof version === 'string' && version.split( '.' ).length === 3 && version.split( '.' )[ 0 ] === '3';
}
export function getSelectedMathModelWidget( selection ) {