From bbfaa7acef434613a5e736514c5b7ed96074b265 Mon Sep 17 00:00:00 2001 From: mso7nueh Date: Mon, 11 Nov 2024 13:47:08 +0300 Subject: [PATCH] feat(diary): chart width --- .../presentation/pages/diary_screen.dart | 28 +++++++++---------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/lib/features/diary/presentation/pages/diary_screen.dart b/lib/features/diary/presentation/pages/diary_screen.dart index 791df947..452e9b8e 100644 --- a/lib/features/diary/presentation/pages/diary_screen.dart +++ b/lib/features/diary/presentation/pages/diary_screen.dart @@ -263,7 +263,7 @@ class _DiaryScreenState extends State { maximum: 100, showLabels: false, showTicks: false, - radiusFactor: 0.8, + radiusFactor: 0.7, axisLineStyle: AxisLineStyle( thickness: 0.1, color: Colors.grey[200], @@ -273,7 +273,7 @@ class _DiaryScreenState extends State { // Carbohydrates Arc RangePointer( value: (chartData[0].intake / chartData[0].recommendation) * 100, - width: 0.1, + width: 0.16, color: chartData[0].color, sizeUnit: GaugeSizeUnit.factor, enableAnimation: true, @@ -282,46 +282,46 @@ class _DiaryScreenState extends State { // Fats Arc RangePointer( value: (chartData[1].intake / chartData[1].recommendation) * 100, - width: 0.1, + width: 0.16, color: chartData[1].color, sizeUnit: GaugeSizeUnit.factor, enableAnimation: true, cornerStyle: CornerStyle.bothCurve, - pointerOffset: -0.12, + pointerOffset: -0.18, ), // Proteins Arc RangePointer( value: (chartData[2].intake / chartData[2].recommendation) * 100, - width: 0.1, + width: 0.16, color: chartData[2].color, sizeUnit: GaugeSizeUnit.factor, enableAnimation: true, cornerStyle: CornerStyle.bothCurve, - pointerOffset: -0.24, + pointerOffset: -0.36, ), // Calories Arc RangePointer( value: (chartData[3].intake / chartData[3].recommendation) * 100, - width: 0.1, + width: 0.16, color: chartData[3].color, sizeUnit: GaugeSizeUnit.factor, enableAnimation: true, cornerStyle: CornerStyle.bothCurve, - pointerOffset: -0.36, + pointerOffset: -0.54, ), ], annotations: [ // Label for Carbohydrates GaugeAnnotation( widget: Transform.rotate( - angle: 30, + angle: 30.1, child: Text( 'Углеводы', style: TextStyle(color: Colors.white, fontSize: 12), ), ), - angle: 194, - positionFactor: 1, + angle: 198, + positionFactor: 0.92, ), // Label for Fats GaugeAnnotation( @@ -333,7 +333,7 @@ class _DiaryScreenState extends State { ), ), angle: 190, - positionFactor: 1.07, + positionFactor: 1.1, ), // Label for Proteins GaugeAnnotation( @@ -345,7 +345,7 @@ class _DiaryScreenState extends State { ), ), angle: 190, - positionFactor: 1.19, + positionFactor: 1.27, ), // Label for Calories GaugeAnnotation( @@ -357,7 +357,7 @@ class _DiaryScreenState extends State { ), ), angle: 192, - positionFactor: 1.31, + positionFactor: 1.46, ), ], ),