Fix CSS cannot select number ID issue

This commit is contained in:
Tyler Long
2018-03-17 09:10:10 +08:00
parent b777c8de15
commit 015b976c28
10 changed files with 51 additions and 10 deletions

View File

@@ -256,7 +256,7 @@ export const draw = function (txt, id, ver) {
config.nodeLabel.width = '100%'
config.nodeLabel.y = -1 * 2 * config.nodeRadius
}
const svg = d3.select('#' + id)
const svg = d3.select(`[id="${id}"]`)
svgCreateDefs(svg)
branchNum = 1
_.each(branches, function (v) {