/* * /MathJax/extensions/asciimath2jax.js * * Copyright (c) 2009-2013 The MathJax Consortium * * Part of the MathJax library. * See http://www.mathjax.org for details. * * Licensed under the Apache License, Version 2.0; * you may not use this file except in compliance with the License. * * http://www.apache.org/licenses/LICENSE-2.0 */MathJax.Extension.asciimath2jax={version:"2.2",config:{delimiters:[["`","`"]],skipTags:"script noscript style textarea pre code".split(" "),ignoreClass:"asciimath2jax_ignore",processClass:"asciimath2jax_process",preview:"AsciiMath"},PreProcess:function(a){this.configured||(this.config=MathJax.Hub.CombineConfig("asciimath2jax",this.config),this.config.Augment&&MathJax.Hub.Insert(this,this.config.Augment),this.configured=!0);"string"===typeof a&&(a=document.getElementById(a));a||(a=document.body);this.createPatterns()&&this.scanElement(a,a.nextSibling)},createPatterns:function(){var a=[],b,d,c=this.config;this.match={};if(0===c.delimiters.length)return!1;b=0;for(d=c.delimiters.length;b(document.documentMode||0)};MathJax.Hub.Register.PreProcessor(["PreProcess",MathJax.Extension.asciimath2jax]);MathJax.Ajax.loadComplete("[MathJax]/extensions/asciimath2jax.js");