Skip to content

[BUG] Tooltip labels for equal data not combining using mode: nearest #5371

Closed

Description

@koltclassic

Expected Behavior

When hovering over two lines with equivalent data points, I would expect to see a tooltip with labels for both data points.

Current Behavior

When hovering over two lines with equivalent data points, the tooltip data does not combine. Rather, each individual tooltip "flashes" repeatedly one after the other.

Possible Solution

I would assume this would be an issue with the nearest method under Chart.Tooltip.positioners ?
Though there is also a getNearestItems function in core.interaction.js that might be worth checking out as well (side note: there is a typo in the getNearestItems comment, "teh" -> "the" 😄 )

Steps to Reproduce (for bugs)

From: http://www.chartjs.org/samples/latest/tooltips/interactions.html
chartjstooltipbug

Context

This doesn't impact me directly, but I could see it being an issue.

Environment

  • Chart.js version: Latest (2.7.2)
  • Browser name and version: Latest Chrome (65), Latest Firefox (59), Latest Safari (11)

Activity

  1. etimberg commented on Jun 7, 2018

    @etimberg
    Member

    @simonbrunel how do you feel about this?

  2. added this to the Version 2.8 milestone on Nov 27, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions