diff --git a/ui/src/shared/components/NewAnnotation.js b/ui/src/shared/components/NewAnnotation.js index f1b71ddffc..a5da583a6b 100644 --- a/ui/src/shared/components/NewAnnotation.js +++ b/ui/src/shared/components/NewAnnotation.js @@ -122,6 +122,7 @@ class NewAnnotation extends Component { tempAnnotation, tempAnnotation: {startTime, endTime}, } = this.props + const {isMouseOver} = this.state const crosshairOne = Math.max(-1000, dygraph.toDomXCoord(startTime)) const crosshairTwo = dygraph.toDomXCoord(endTime) @@ -161,14 +162,18 @@ class NewAnnotation extends Component { className="new-annotation--crosshair" style={{left: crosshairTwo}} > - {this.renderTimestamp(tempAnnotation.endTime)} + {isMouseOver && + isDragging && + this.renderTimestamp(tempAnnotation.endTime)}
}