indexLabels/labels in Pie Chart are skipped whenever they get closer to other indexLabels – this behavior is by design. You can workaround this issue by either rotating the Pie Chart as shown in this JSFiddle or by showing indexLabel outside the Pie Chart as shown in this JSFiddle – indexLabel’s are placed better when they are outside.
It would be useful if you can create a JSFiddle demonstrating the issue with minimal code, so that we can look into your code, understand the scenario better and guide you accordingly.
—
Vishwas R
Team CanvasJS
Vineet,
Thanks for your valuable feedback. We will reconsider this behaviour for future releases, as we are working on some other features at this point of time.
Meanwhile, please take a look at this JSFiddle with zoom-back button that facilitates you to zoom-out step-by-step after zooming into certain region.
—
Vishwas R
Team CanvasJS
Pavlo,
The behaviour is due to the valueFormatString that you are using. For negative values, the dashes in axis labels are nothing but ‘-‘ (minus). To hide labels, I would suggest you to use labelFormatter as valueFormatString just defines how the value should be formatted before showing in label. Please take a look at this JSFiddle.
—
Vishwas R
Team CanvasJS
Michael,
Sorry to inform you that its not possible to avoid using contentFormatter in this scenario. yValueFormatString is a property of dataSeries that accepts string whereas labelFormatter and contentFormatter are methods of axis and toolTip respectively.
However you can reduce the number of lines of code using ternary operator. Please take a look at this updated JSFiddle.
—
Vishwas R
Team CanvasJS
Deepa,
You can achieve this by changing axis minimum and maximum according to the button being clicked. Please take a look at this jsfiddle.
—
Vishwas R
Team CanvasJS
Aarti,
You can achieve this by syncing axisX of range-bar chart with axisY of area chart and axisY of range-bar with axisX of area chart. Please take a look at this jsfiddle.
—
Vishwas R
Team CanvasJS
Stripline is a property of axis which you can’t add through dataSeries.
Can you kindly create jsfiddle with sample data and brief your use-case so that we can understand it better and help you with a workaround?
—
Vishwas R
Team CanvasJS
Michael,
You can achieve this with the help of axis labelFormatter and formatNumber(). Please take a look this jsfiddle.
—
Vishwas R
Team CanvasJS
Just like having DOM in a website/web-app, you can create a DOM for chart-container in html and script-part goes inside js/ts (based on your usage) files. Please take a look at this tutorial on Building Mobile App with Angular & Ionic. Also please refer this tutorial on Ionic.
—
Vishwas R
Team CanvasJS
Pavlo,
Thanks for your feedback. We will consider this behaviour for future releases.
—
Vishwas R
Team CanvasJS
It seems to be working fine. Can you kindly share sample project over Onedrive or Google-Drive so that we can look into your code, understand your scenario better and help you out?
Please find the screenshot below:
—
Vishwas R
Team CanvasJS
You can save CanvasJS file (canvasjs.min.js) in src folder of your project (‘src/assets/js’ or ‘src/lib’) and import the CanvasJS library to your app using import CanvasJS from 'canvasjs.min'
(path may vary based on file location like ‘./src/assets/js/canvasjs.min’ or ‘./src/lib/canvasjs.min’). Or you can add it in your html file using script-tag. Please take a look at this ionic documentation on Adding 3rd Party Libraries.
Also please refer this tutorial on How to Install 3rd Party Libraries in Ionic 2 and step-by-step guide given in this github thread for more info.
—
Vishwas R
Team CanvasJS
Paul,
Its not a bug but its due to invalid x-value that has been passed to chart. moment().startOf('d')
is not a valid JavaScript date-time object, however moment().startOf('d')._d
is valid date-time object. Passing valid date-time object should work fine in your case. Please take a a look at this updated jsfiddle.
—
Vishwas R
Team CanvasJS