mirror of
https://github.com/nasa/openmct.git
synced 2025-03-14 16:26:50 +00:00
handle case where we only have events in timeline
This commit is contained in:
parent
0e940b2883
commit
32a0e15691
@ -286,7 +286,8 @@ export default {
|
||||
const timelineHolderRect = this.$refs.timelineHolder.getBoundingClientRect();
|
||||
const laneObjectRect = firstSwimLane.getBoundingClientRect();
|
||||
const offset = laneObjectRect.left - timelineHolderRect.left;
|
||||
const swimLaneOffset = offset + AXES_PADDING;
|
||||
const hasAxes = this.alignmentData.axes && Object.keys(this.alignmentData.axes).length > 0;
|
||||
const swimLaneOffset = hasAxes ? offset + AXES_PADDING : offset;
|
||||
return swimLaneOffset;
|
||||
} else {
|
||||
return 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user