#926 Applying the color styling on the label instead of the node

This commit is contained in:
knsv
2019-09-08 02:56:06 -07:00
parent ece40cdc54
commit e37f5a6eb2
7 changed files with 44 additions and 13 deletions

View File

@@ -20,6 +20,7 @@ const contentLoaded = function () {
div.innerHTML = graphObj.code
document.getElementsByTagName('body')[0].appendChild(div)
global.mermaid.initialize(graphObj.mermaid)
// console.log('graphObj.mermaid', graphObj.mermaid)
global.mermaid.init()
}
}
@@ -30,7 +31,6 @@ const contentLoadedApi = function () {
const graphBase64 = document.location.href.substr(pos)
const graphObj = JSON.parse(Base64.decode(graphBase64))
// const graph = 'hello'
console.log(graphObj)
const div = document.createElement('div')
div.id = 'block'
div.className = 'mermaid'
@@ -57,6 +57,7 @@ if (typeof document !== 'undefined') {
this.console.log('Using api')
contentLoadedApi()
} else {
this.console.log('Not using api')
contentLoaded()
}
},