chartjs / chartjs-plugin-annotation

Annotation plugin for Chart.js
MIT License
603 stars 325 forks source link

Add z option to all annotations #738

Closed stockiNail closed 2 years ago

stockiNail commented 2 years ago

Fix #175

This PR is adding new option to all annotations and their label subelements in order to enable the user to define which annotations should be drawn on top, with the same drawTime.

stockiNail commented 2 years ago

Changing the function name, we have re-enabled code climate issue about cognitive complexity. :worried:

stockiNail commented 2 years ago

@LeeLenaleee apologize, I have tried to solve CC issue about complexity (I think better to have an exception as was before) and your approval is dismissed.

LeeLenaleee commented 2 years ago

np

stockiNail commented 2 years ago

Somewhat unrelated comment: Would be nice to normalize the common properties somehow, rather documenting for each annotation type.

Are you thinking a common MD file to import in each page or a specific page with common options?

LeeLenaleee commented 2 years ago

Common MD file that gets imported would be better, would be more in line with chart.js itself and will make it more user frienndly because people will only go to the place they are using and prob won't see the common page

stockiNail commented 2 years ago

Common MD file that gets imported would be better, would be more in line with chart.js itself and will make it more user frienndly because people will only go to the place they are using and prob won't see the common page

OK! The content for the next PR is already decided! ;)