Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Non-empty options.markers.discrete Array causes invisible tooltip marker in line chart #3475

Open
mouxdev opened this issue Nov 6, 2022 · 1 comment
Labels
bug Something isn't working

Comments

@mouxdev
Copy link

mouxdev commented Nov 6, 2022

Description

Using the options.markers.discrete Array to stylize only certain markers in a chart causes the tooltip marker to disappear

Steps to Reproduce

  1. Create a chart using the standard options from the documentation and add discrete markers
{
    chart: {
      type: 'line'
    },
    series: [{
      name: 'sales',
      data: [30,40,35,50,49,60,70,91,125]
    }],
    xaxis: {
      categories: [1991,1992,1993,1994,1995,1996,1997, 1998,1999]
    },
    markers: {
        discrete: [
            {
                seriesIndex: 0,
                dataPointIndex: 3,
                fillColor: "#000000",
                size: 5
            }
        ]
    }
  }

Expected Behavior

The chart reacts to hovering by showing a tooltip along with a marker indicating which datapoint is being focused on right now on the line (first screenshot)

Actual Behavior

The chart reacts to hovering by showing only the tooltip (second screenshot)

Screenshots


Reproduction Link

Link to codepen reproducing this error

@idpaterson
Copy link
Contributor

#3715 released in 3.37.2 fixes a related problem with discrete markers that clears the way for a workaround to this invisible tooltip issue. By configuring the chart with markers: { size: 0.000001, ... } you will have effectively invisible markers as desired, but the markers will appear as expected on hover. Attempting this workaround in any version from 3.33.2 to 3.37.1 inclusive results in the tooltip sticking in the upper left rather than dynamically positioning and the markers still did not show on hover.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants