java.lang.Object
software.xdev.chartjs.model.options.Hover

public class Hover extends Object
  • Field Details

  • Constructor Details

    • Hover

      public Hover()
  • Method Details

    • getMode

      public HoverMode getMode()
      See Also:
    • setMode

      public Hover setMode(HoverMode mode)

      Default single

      Sets which elements hover. Acceptable options are 'single', 'label', 'x-axis', or 'dataset'.

      • single highlights the closest element.
      • label highlights elements in all datasets at the same X value.
      • x-axis also highlights elements in all datasets at the same X value, but activates when hovering anywhere within the vertical slice of the x-axis representing that X value.
      • dataset highlights the closest dataset.
    • getOnHover

      public JavaScriptFunction getOnHover()
      See Also:
    • setOnHover

      public Hover setOnHover(JavaScriptFunction onHover)
      Default null

      Called when any of the events fire. Called in the context of the chart and passed an array of active elements (bars, points, etc)