You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

28 lines
436 B

  1. <script>
  2. import { Doughnut, mixins } from 'vue-chartjs'
  3. const { reactiveProp } = mixins
  4. export default {
  5. extends: Doughnut,
  6. mixins: [reactiveProp],
  7. props: {
  8. chartData: {
  9. type: Object,
  10. default: () => {},
  11. required: true
  12. }
  13. },
  14. data() {
  15. return {
  16. options: {
  17. maintainAspectRatio: false
  18. }
  19. }
  20. },
  21. mounted() {
  22. this.renderChart(this.chartData, this.options)
  23. }
  24. }
  25. </script>