Made drop-shadow less prominent and set new arrow-type

This commit is contained in:
Per Brolin
2024-06-03 15:42:49 +02:00
parent 195ea6405a
commit 03ba130764
3 changed files with 17 additions and 3 deletions

View File

@@ -92,7 +92,7 @@ stateDiagram-v2
<pre id="diagram" class="mermaid"> <pre id="diagram" class="mermaid">
stateDiagram-v2 stateDiagram-v2
direction LR direction LR
Active Active --> Passive

View File

@@ -156,7 +156,7 @@ g.stateGroup line {
} }
.state-shadow { .state-shadow {
filter: drop-shadow( 3px 3px 2px rgba(0,0,0,.7) ); filter: drop-shadow( 1px 1px 2px rgba(0,0,0,.7) );
} }

View File

@@ -263,6 +263,20 @@ const cross = (elem, type, id) => {
.style('stroke-width', 2) .style('stroke-width', 2)
.style('stroke-dasharray', '1,0'); .style('stroke-dasharray', '1,0');
}; };
// const barb = (elem, type, id) => {
// elem
// .append('defs')
// .append('marker')
// .attr('id', id + '_' + type + '-barbEnd')
// .attr('refX', 19)
// .attr('refY', 7)
// .attr('markerWidth', 20)
// .attr('markerHeight', 14)
// .attr('markerUnits', 'strokeWidth')
// .attr('orient', 'auto')
// .append('path')
// .attr('d', 'M 19,7 L9,13 L14,7 L9,1 Z');
// };
const barb = (elem, type, id) => { const barb = (elem, type, id) => {
elem elem
.append('defs') .append('defs')
@@ -275,7 +289,7 @@ const barb = (elem, type, id) => {
.attr('markerUnits', 'strokeWidth') .attr('markerUnits', 'strokeWidth')
.attr('orient', 'auto') .attr('orient', 'auto')
.append('path') .append('path')
.attr('d', 'M 19,7 L9,13 L14,7 L9,1 Z'); .attr('d', 'M 19,7 L13,13 L15,7 L13,1 Z');
}; };
// TODO rename the class diagram markers to something shape descriptive and semantic free // TODO rename the class diagram markers to something shape descriptive and semantic free