mpx200 / ng-dygraphs

Angular 2+ library for support of dygraphs(http://dygraphs.com) charts
MIT License
3 stars 9 forks source link

Add 'NO DATA AVAILABLE' label when there are no data. #5

Closed JimiC closed 7 years ago

JimiC commented 7 years ago

This PR shows a NO DATA AVAILABLE label in place of the chart in case there are no data.

loadingInProgress has been brought before the options check in order for the loader to be displayed in case the check takes a while.

loadingInProgress has been also added, before the return statement when there are no data, in order to hide the loader if it's previously shown and an error occurred on the previous chart.

@mpx200 You may want to change the label with an image. I don't know your preferences so I went with the simplest solution.

mpx200 commented 7 years ago

i slightly change it, i like to give possibility to use custom string for NO DATA

JimiC commented 7 years ago

No problem. Just wanted to pass the concept.