Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

highcharts-custom-events

Package Overview
Dependencies
Maintainers
1
Versions
51
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

highcharts-custom-events

Plugin that allows you to add extra events, like double / right click on each chart element, for Highcharts.

  • 3.0.10
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
48K
decreased by-10.98%
Maintainers
1
Weekly downloads
 
Created
Source

Custom events - Highcharts module

Go to project page to see this module in action: http://blacklabel.github.io/custom_events/

Requirements

  • Plugin requires the latest Highcharts (tested with 6.1.4)

Installation

  • Like any other Highcharts module (e.g. exporting), add <script> tag pointing to custom_events.js below Highcharts script tag.

  • For NPM users:

var Highcharts = require('highcharts'),
    HighchartsCustomEvents = require('highcharts-custom-events')(Highcharts);
  • For BOWER users:
bower install highcharts-custom-events

Code

The latest code is available on github: https://github.com/blacklabel/custom_events/

Usage and demos

It's quite simple and intuitive, just pass function as other events:

events: {
                        dblclick: function () {
                            $('#report').html('dbclick on xAxis label');
                        },
                        click: function () {
                            $('#report').html('click on xAxis label');
                        },
                        contextmenu: function () {
                            $('#report').html('context menu on xAxis label');
                        }
}

Crosshairs

crosshair: {
    enabled: true,
    events: {
                        dblclick: function () {
                            $('#report').html('dbclick on xAxis label');
                        },
                        click: function () {
                            $('#report').html('click on xAxis label');
                        },
                        contextmenu: function () {
                            $('#report').html('context menu on xAxis label');
                        }
    }
}

Available events

  • click
  • double click (including mobile devices)
  • right click (context menu)
  • mouse over
  • mouse out
  • mouse down
  • mouse move

Elements

  • title
  • subtitle
  • axis labels
  • axis title
  • plotLines
  • plotBands, including labels
  • point
  • series
  • legend
  • datalabels
  • flags
  • crosshairs

Keywords

FAQs

Package last updated on 21 Dec 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc