#3831 Re-enabling themes for er diagrams

This commit is contained in:
Knut Sveidqvist
2022-11-21 14:30:06 +01:00
parent 0d27b1aa65
commit f9222a3bf4

View File

@@ -211,9 +211,6 @@ const drawAttributes = (groupNode, entityTextNode, attributes) => {
const typeRect = groupNode const typeRect = groupNode
.insert('rect', '#' + attributeNode.tn.node().id) .insert('rect', '#' + attributeNode.tn.node().id)
.classed(`er ${attribStyle}`, true) .classed(`er ${attribStyle}`, true)
.style('fill', conf.fill)
.style('fill-opacity', '100%')
.style('stroke', conf.stroke)
.attr('x', 0) .attr('x', 0)
.attr('y', heightOffset) .attr('y', heightOffset)
.attr('width', maxTypeWidth + widthPadding * 2 + spareColumnWidth) .attr('width', maxTypeWidth + widthPadding * 2 + spareColumnWidth)
@@ -231,9 +228,6 @@ const drawAttributes = (groupNode, entityTextNode, attributes) => {
const nameRect = groupNode const nameRect = groupNode
.insert('rect', '#' + attributeNode.nn.node().id) .insert('rect', '#' + attributeNode.nn.node().id)
.classed(`er ${attribStyle}`, true) .classed(`er ${attribStyle}`, true)
.style('fill', conf.fill)
.style('fill-opacity', '100%')
.style('stroke', conf.stroke)
.attr('x', nameXOffset) .attr('x', nameXOffset)
.attr('y', heightOffset) .attr('y', heightOffset)
.attr('width', maxNameWidth + widthPadding * 2 + spareColumnWidth) .attr('width', maxNameWidth + widthPadding * 2 + spareColumnWidth)
@@ -253,9 +247,6 @@ const drawAttributes = (groupNode, entityTextNode, attributes) => {
const keyTypeRect = groupNode const keyTypeRect = groupNode
.insert('rect', '#' + attributeNode.kn.node().id) .insert('rect', '#' + attributeNode.kn.node().id)
.classed(`er ${attribStyle}`, true) .classed(`er ${attribStyle}`, true)
.style('fill', conf.fill)
.style('fill-opacity', '100%')
.style('stroke', conf.stroke)
.attr('x', keyTypeAndCommentXOffset) .attr('x', keyTypeAndCommentXOffset)
.attr('y', heightOffset) .attr('y', heightOffset)
.attr('width', maxKeyWidth + widthPadding * 2 + spareColumnWidth) .attr('width', maxKeyWidth + widthPadding * 2 + spareColumnWidth)
@@ -276,9 +267,6 @@ const drawAttributes = (groupNode, entityTextNode, attributes) => {
groupNode groupNode
.insert('rect', '#' + attributeNode.cn.node().id) .insert('rect', '#' + attributeNode.cn.node().id)
.classed(`er ${attribStyle}`, 'true') .classed(`er ${attribStyle}`, 'true')
.style('fill', conf.fill)
.style('fill-opacity', '100%')
.style('stroke', conf.stroke)
.attr('x', keyTypeAndCommentXOffset) .attr('x', keyTypeAndCommentXOffset)
.attr('y', heightOffset) .attr('y', heightOffset)
.attr('width', maxCommentWidth + widthPadding * 2 + spareColumnWidth) .attr('width', maxCommentWidth + widthPadding * 2 + spareColumnWidth)
@@ -348,9 +336,6 @@ const drawEntities = function (svgNode, entities, graph) {
const rectNode = groupNode const rectNode = groupNode
.insert('rect', '#' + textId) .insert('rect', '#' + textId)
.classed('er entityBox', true) .classed('er entityBox', true)
.style('fill', conf.fill)
.style('fill-opacity', '100%')
.style('stroke', conf.stroke)
.attr('x', 0) .attr('x', 0)
.attr('y', 0) .attr('y', 0)
.attr('width', entityWidth) .attr('width', entityWidth)
@@ -548,9 +533,7 @@ const drawRelationshipFromLayout = function (svg, rel, g, insert, diagObj) {
.attr('x', labelPoint.x - labelBBox.width / 2) .attr('x', labelPoint.x - labelBBox.width / 2)
.attr('y', labelPoint.y - labelBBox.height / 2) .attr('y', labelPoint.y - labelBBox.height / 2)
.attr('width', labelBBox.width) .attr('width', labelBBox.width)
.attr('height', labelBBox.height) .attr('height', labelBBox.height);
.style('fill', 'white')
.style('fill-opacity', '85%');
}; };
/** /**