-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Description
Description
In 3.49.0, for area charts with multiple series with larger numbers of values (say, about 3,000), series toggling is broken - or, at least, highly unresponsive. See the attached .html example that reproduces this issue. The initial rendering of the graph is fine in 3.49.0 - only toggling a series to hide it via a mouse click has the problem. Note that 3.48.0 does not have this problem, and was likely introduced in commit 7f04fa3. For 3.48.0, series toggling is fast even for area charts with multiple large series. If this is related to linearscale() assumptions, would it be be possible to add a new attribute to allow the user to select the old behavior?
Steps to Reproduce
- Load the 'ap_issue.html' file from this gist against ApexChart 3.49.0 (note the '../../apexcharts/dist/apexcharts.js' path may need to be changed for your system).
- The chart should load showing three series: 'vals', 'moving_avg_100D', and 'exp_moving_avg_100D'.
- Select the 'vals' series in the legend and mouse click to try and toggle/hide it.
- The browser tab will become unresponsive.
- Switching to ApexCharts 3.48.0 or any prior version will not exhibit the above, and series toggling is fast and responsive.
Expected Behavior
Series toggling should be fast and responsive as seen in 3.48.0 and prior versions.
Actual Behavior
The browser tab becomes unresponsive (see screenshot below).
Screenshots
Here is the complete rendered page that includes the three series:
When trying to toggle/hide the 'vals' series, mouse over 'vals' (which shows just the 'vals' series without the others), and then upon mouse click to toggle 'vals' the browser tab become unresponsive:
Under 3.48.0, here is what should be shown after the mouse click:
Reproduction Link
See the 'ap_issue.html' file from this gist - (note the '../../apexcharts/dist/apexcharts.js' path may need to be changed for your system to point to the correct path for ApexCharts).