mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-11-15 02:04:08 +01:00
Cleanup
This commit is contained in:
@@ -109,9 +109,6 @@ function createFormattedText(width, g, structuredText, addBackground = false) {
|
|||||||
const labelGroup = g.append('g');
|
const labelGroup = g.append('g');
|
||||||
let bkg = labelGroup.insert('rect').attr('class', 'background');
|
let bkg = labelGroup.insert('rect').attr('class', 'background');
|
||||||
const textElement = labelGroup.append('text').attr('y', '-10.1');
|
const textElement = labelGroup.append('text').attr('y', '-10.1');
|
||||||
// .attr('dominant-baseline', 'middle')
|
|
||||||
// .attr('text-anchor', 'middle');
|
|
||||||
// .attr('text-anchor', 'middle');
|
|
||||||
let lineIndex = 0;
|
let lineIndex = 0;
|
||||||
structuredText.forEach((line) => {
|
structuredText.forEach((line) => {
|
||||||
/**
|
/**
|
||||||
@@ -139,7 +136,6 @@ function createFormattedText(width, g, structuredText, addBackground = false) {
|
|||||||
.attr('y', -padding)
|
.attr('y', -padding)
|
||||||
.attr('width', bbox.width + 2 * padding)
|
.attr('width', bbox.width + 2 * padding)
|
||||||
.attr('height', bbox.height + 2 * padding);
|
.attr('height', bbox.height + 2 * padding);
|
||||||
// .style('fill', 'red');
|
|
||||||
|
|
||||||
return labelGroup.node();
|
return labelGroup.node();
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user