From 04c70d6fafc0f3b0c38c311eed3ce3095c02e6aa Mon Sep 17 00:00:00 2001 From: Burak Civan Date: Thu, 9 Jun 2022 14:52:26 +0300 Subject: [PATCH] long text controlled for donut chart --- app/Widgets/ExpensesByCategory.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/Widgets/ExpensesByCategory.php b/app/Widgets/ExpensesByCategory.php index 4b39555f0..939d2a450 100644 --- a/app/Widgets/ExpensesByCategory.php +++ b/app/Widgets/ExpensesByCategory.php @@ -27,6 +27,9 @@ class ExpensesByCategory extends Widget $chart = $this->getDonutChart(trans_choice('general.expenses', 2), '100%', 300, 6); + $chart->options['legend']['width'] = 200; + $chart->options['legend']['position'] = 'right'; + return $this->view('widgets.donut_chart', [ 'chart' => $chart, ]);