VisActor / VChart

VChart, more than just a cross-platform charting library, but also an expressive data storyteller.
https://www.visactor.io/vchart
MIT License
776 stars 45 forks source link

[Feature] line crosshair as default, using continuous axis. #2716

Open youngwinds opened 1 month ago

youngwinds commented 1 month ago

Version

1.11.0

Link to Minimal Reproduction

none

Steps to Reproduce

{
  type: 'line',
  data: {
    values: [
      {
        time: 1,
        value: 8
      },
      {
        time: 2,
        value: 9
      },
      {
        time: 3,
        value: 11
      },
      {
        time: 4,
        value: 14
      },
      {
        time: 5,
        value: 16
      },
      {
        time: 6,
        value: 17
      },
      {
        time: 7,
        value: 17
      },
      {
        time: 8,
        value: 16
      },
      {
        time: 9,
        value: 15
      }
    ]
  },
  axes: [
    {
      orient: 'bottom',
      type:'time',
    }
  ],
  crosshair:{
    "xField": { "visible": true },
    "yField": { "visible": false }
  },
  xField: 'time',
  yField: 'value'
};

Current Behavior

missing crosshair

Expected Behavior

having crosshair

Environment

- OS:
- Browser:
- Framework:

Any additional comments?

No response