mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-08-23 10:16:43 +02:00
Added permananet color for the vertical line
This commit is contained in:
@@ -286,21 +286,13 @@ export const draw = function (text, id, version, diagObj) {
|
|||||||
0.5 * theBarHeight
|
0.5 * theBarHeight
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
// if (d.vert) {
|
|
||||||
// return (
|
|
||||||
// timeScale(d.startTime) +
|
|
||||||
// theSidePad +
|
|
||||||
// 0.5 * (timeScale(d.endTime) - timeScale(d.startTime)) -
|
|
||||||
// 0.5 * theBarHeight
|
|
||||||
// );
|
|
||||||
// }
|
|
||||||
return timeScale(d.startTime) + theSidePad;
|
return timeScale(d.startTime) + theSidePad;
|
||||||
})
|
})
|
||||||
.attr('y', function (d, i) {
|
.attr('y', function (d, i) {
|
||||||
// Ignore the incoming i value and use our order instead
|
// Ignore the incoming i value and use our order instead
|
||||||
i = d.order;
|
i = d.order;
|
||||||
if (d.vert) {
|
if (d.vert) {
|
||||||
return 0;
|
return conf.gridLineStartPadding;
|
||||||
}
|
}
|
||||||
return i * theGap + theTopPad;
|
return i * theGap + theTopPad;
|
||||||
})
|
})
|
||||||
@@ -309,18 +301,13 @@ export const draw = function (text, id, version, diagObj) {
|
|||||||
return theBarHeight;
|
return theBarHeight;
|
||||||
}
|
}
|
||||||
if (d.vert) {
|
if (d.vert) {
|
||||||
return 0.005 * theBarHeight;
|
return 0.08 * theBarHeight;
|
||||||
}
|
}
|
||||||
return timeScale(d.renderEndTime || d.endTime) - timeScale(d.startTime);
|
return timeScale(d.renderEndTime || d.endTime) - timeScale(d.startTime);
|
||||||
})
|
})
|
||||||
// .attr('height', theBarHeight)
|
|
||||||
.attr('height', function (d) {
|
.attr('height', function (d) {
|
||||||
if (d.vert) {
|
if (d.vert) {
|
||||||
return (
|
return taskArray.length * (conf.barHeight + conf.barGap) + conf.barHeight * 2;
|
||||||
conf.gridLineStartPadding +
|
|
||||||
taskArray.length * (conf.barHeight + conf.barGap) +
|
|
||||||
conf.barHeight * 2
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
return theBarHeight;
|
return theBarHeight;
|
||||||
})
|
})
|
||||||
@@ -407,9 +394,6 @@ export const draw = function (text, id, version, diagObj) {
|
|||||||
if (d.milestone) {
|
if (d.milestone) {
|
||||||
startX += 0.5 * (timeScale(d.endTime) - timeScale(d.startTime)) - 0.5 * theBarHeight;
|
startX += 0.5 * (timeScale(d.endTime) - timeScale(d.startTime)) - 0.5 * theBarHeight;
|
||||||
}
|
}
|
||||||
if (d.special) {
|
|
||||||
return startX + theSidePad - 5;
|
|
||||||
}
|
|
||||||
if (d.milestone) {
|
if (d.milestone) {
|
||||||
endX = startX + theBarHeight;
|
endX = startX + theBarHeight;
|
||||||
}
|
}
|
||||||
|
@@ -237,8 +237,13 @@ const getStyles = (options) =>
|
|||||||
fill: ${options.taskTextDarkColor} !important;
|
fill: ${options.taskTextDarkColor} !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.vert {
|
||||||
|
stroke: navy;
|
||||||
|
}
|
||||||
|
|
||||||
.vertText {
|
.vertText {
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
|
fill: navy;
|
||||||
}
|
}
|
||||||
|
|
||||||
.activeCritText0,
|
.activeCritText0,
|
||||||
|
Reference in New Issue
Block a user