How to stop showing the poped-up image on hovering?

Hello, I have a 3d-scatter plot and I have used tooltip to display an image by hovering for a specific point.
I have the following code. It shows the photo when the mouse is at that point. But, when I move the mouse to other points, it still shows that image. I wondered how I can disable the poped-up image when the mouse is not on that point.

         dcc.Tooltip(id="graph-tooltip", direction='bottom'),

    Output("graph-tooltip", "show"),
    Output("graph-tooltip", "bbox"),
    Output("graph-tooltip", "children"),
    Output("graph-tooltip", "direction"),
    Input("graph3", "hoverData"),
def display_hover(hoverData):
    if hoverData is None:
        return False, no_update, no_update, no_update

    # Load image with pillow
    image_path = 'test.jpg'
    im =

    # dump it to base64
    buffer = io.BytesIO(), format="jpeg")
    encoded_image = base64.b64encode(buffer.getvalue()).decode()
    im_url = "data:image/jpeg;base64, " + encoded_image

    if hoverData["points"][0]['z'] == 2000:
        hover_data = hoverData["points"][0]
        bbox = hover_data["bbox"]

        # control the position of the tooltip
        y = hover_data["y"]
        direction = "bottom" if y > 1.5 else "top"

        children = [
                style={"width": "150px"},
            html.P("Image from base64 string"),
        return True, bbox, children, direction

        return dash.no_update