Merge branch 'MDL-43856-master' of git://github.com/damyon/moodle
This commit is contained in:
Vendored
-46
@@ -1,46 +0,0 @@
|
||||
YUI.add('moodle-filter_mathjax-loader', function (Y, NAME) {
|
||||
|
||||
// This file is part of Moodle - http://moodle.org/
|
||||
//
|
||||
// Moodle is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// Moodle is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/**
|
||||
* Mathjax JS Loader.
|
||||
*
|
||||
* @package filter_mathjax
|
||||
* @copyright 2014 Damyon Wiese <[email protected]>
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
M.filter_mathjax = M.filter_mathjax || {
|
||||
init : function(params) {
|
||||
// Add an inline configuration tag to the head.
|
||||
var config = Y.Node.create('<script type="text/x-mathjax-config"></script>');
|
||||
config.setHTML(params.mathjaxconfig);
|
||||
Y.one('head').append(config);
|
||||
// Load the mathjax library.
|
||||
Y.Get.js(params.mathjaxurl, function() {
|
||||
// Tell mathjax to call back for the language files.
|
||||
debugger;
|
||||
MathJax.Localization.addTranslation(params.lang,null,{
|
||||
menuTitle: params.langdescription,
|
||||
directory: M.cfg.wwwroot + "/filter/mathjax/language.php?lang="
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
}, '@VERSION@', {"requires": ["get", "node"]});
|
||||
Vendored
-1
@@ -1 +0,0 @@
|
||||
YUI.add("moodle-filter_mathjax-loader",function(e,t){M.filter_mathjax=M.filter_mathjax||{init:function(t){var n=e.Node.create('<script type="text/x-mathjax-config"></script>');n.setHTML(t.mathjaxconfig),e.one("head").append(n),e.Get.js(t.mathjaxurl,function(){debugger;MathJax.Localization.addTranslation(t.lang,null,{menuTitle:t.langdescription,directory:M.cfg.wwwroot+"/filter/mathjax/language.php?lang="})})}}},"@VERSION@",{requires:["get","node"]});
|
||||
Vendored
-46
@@ -1,46 +0,0 @@
|
||||
YUI.add('moodle-filter_mathjax-loader', function (Y, NAME) {
|
||||
|
||||
// This file is part of Moodle - http://moodle.org/
|
||||
//
|
||||
// Moodle is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// Moodle is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/**
|
||||
* Mathjax JS Loader.
|
||||
*
|
||||
* @package filter_mathjax
|
||||
* @copyright 2014 Damyon Wiese <[email protected]>
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
M.filter_mathjax = M.filter_mathjax || {
|
||||
init : function(params) {
|
||||
// Add an inline configuration tag to the head.
|
||||
var config = Y.Node.create('<script type="text/x-mathjax-config"></script>');
|
||||
config.setHTML(params.mathjaxconfig);
|
||||
Y.one('head').append(config);
|
||||
// Load the mathjax library.
|
||||
Y.Get.js(params.mathjaxurl, function() {
|
||||
// Tell mathjax to call back for the language files.
|
||||
debugger;
|
||||
MathJax.Localization.addTranslation(params.lang,null,{
|
||||
menuTitle: params.langdescription,
|
||||
directory: M.cfg.wwwroot + "/filter/mathjax/language.php?lang="
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
}, '@VERSION@', {"requires": ["get", "node"]});
|
||||
Reference in New Issue
Block a user