|
|
@ -75,11 +75,12 @@ define([
|
|
|
|
|
|
|
|
|
|
|
|
var mediaMap = {};
|
|
|
|
var mediaMap = {};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var defaultCode = renderer.code;
|
|
|
|
renderer.code = function (code, language) {
|
|
|
|
renderer.code = function (code, language) {
|
|
|
|
if (language === 'mermaid' && (code.match(/^sequenceDiagram/) || code.match(/^graph/))) {
|
|
|
|
if (language === 'mermaid' && (code.match(/^sequenceDiagram/) || code.match(/^graph/))) {
|
|
|
|
return '<pre class="mermaid">'+code+'</pre>';
|
|
|
|
return '<pre class="mermaid">'+code+'</pre>';
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
return '<pre><code>'+code+'</code></pre>';
|
|
|
|
return defaultCode.apply(renderer, arguments);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|