mirror of
https://github.com/McShelby/hugo-theme-relearn.git
synced 2024-11-27 01:33:04 +00:00
style: fix style in theme.js
This commit is contained in:
parent
66ef1762f1
commit
6960d63ee0
1 changed files with 12 additions and 12 deletions
|
@ -179,10 +179,10 @@ function initMermaid( update, attrs ) {
|
|||
};
|
||||
|
||||
var serializeGraph = function( graph ){
|
||||
if (JSON.stringify(graph.dir) === "{}") {
|
||||
return "---\n" + jsyaml.dump(graph.yaml) + "---\n" + graph.content;
|
||||
if (JSON.stringify(graph.dir) === '{}') {
|
||||
return '---\n' + jsyaml.dump(graph.yaml) + '---\n' + graph.content;
|
||||
}
|
||||
return "---\n" + jsyaml.dump(graph.yaml) + "---\n" + "%%{init: " + JSON.stringify(graph.dir) + "}%%\n" + graph.content;
|
||||
return '---\n' + jsyaml.dump(graph.yaml) + '---\n' + '%%{init: ' + JSON.stringify(graph.dir) + '}%%\n' + graph.content;
|
||||
};
|
||||
|
||||
var init_func = function( attrs ){
|
||||
|
@ -191,7 +191,7 @@ function initMermaid( update, attrs ) {
|
|||
document.querySelectorAll('.mermaid').forEach( function( element ){
|
||||
var parse = parseGraph( decodeHTML( element.innerHTML ) );
|
||||
|
||||
if (JSON.stringify(parse.dir) === "{}") {
|
||||
if( JSON.stringify(parse.dir) === '{}' ){
|
||||
if( parse.yaml.theme ){
|
||||
parse.yaml.relearn_user_theme = true;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue