1import 'package:connect/core/localization/app_localizations.dart';
2import 'package:connect/core/utils/number_conversion.dart';
4import '../../../../../core/constants/app_values.dart';
5import '/core/ui/widgets/custom_card.dart';
6import 'package:flutter/material.dart';
7import 'package:flutter_screenutil/flutter_screenutil.dart';
8import 'package:flutter_staggered_grid_view/flutter_staggered_grid_view.dart';
9import 'package:intl/intl.dart';
10import 'package:percent_indicator/circular_percent_indicator.dart';
29 Widget
build(BuildContext context) {
33 crossAxisAlignment: CrossAxisAlignment.start,
37 .
translate(
'MONTHLY COLLECTION PERFORMANCE'),
38 style: Theme.of(context).textTheme.bodySmall,
40 SizedBox(height: 10.sp),
42 axisDirection: AxisDirection.down,
44 mainAxisSpacing: 10.sp,
45 crossAxisSpacing: 10.sp,
49 '${NumberConversionService.convertAndFormatWeight(volumeDeclared)} / ${NumberConversionService.convertAndFormatWeight(volumeDeclared)}',
67 .
translate(
'Declared VS Collected Performance'),
73 .
translate(
'Waste Management Performance'),
85 required String
title,
87 required BuildContext context,
91 decoration: BoxDecoration(
92 borderRadius: BorderRadius.circular(10),
95 mainAxisSize: MainAxisSize.min,
96 crossAxisAlignment: CrossAxisAlignment.center,
100 style: Theme.of(context).textTheme.displaySmall?.copyWith(
101 color: Theme.of(context).colorScheme.primary,
102 fontWeight: FontWeight.bold,
106 SizedBox(height: 7.sp),
109 textAlign: TextAlign.center,
110 style: Theme.of(context).textTheme.bodySmall?.copyWith(
112 color: Theme.of(context).hintColor,
121 required String
label,
122 required BuildContext context,
126 percentageValue = percentageValue / 100.0;
129 padding: EdgeInsets.all(10.sp),
130 decoration: BoxDecoration(
131 borderRadius: BorderRadius.circular(10),
134 crossAxisAlignment: CrossAxisAlignment.center,
136 CircularPercentIndicator(
139 percent: percentageValue,
141 '${(percentageValue * 100).toStringAsFixed(0)}%',
142 style: Theme.of(context).textTheme.bodySmall?.copyWith(
148 Theme.of(context).colorScheme.primary.withOpacity(0.11),
150 SizedBox(height: 10.sp),
153 textAlign: TextAlign.center,
154 style: Theme.of(context).textTheme.bodySmall?.copyWith(
156 color: Theme.of(context).hintColor,
String translate(String key)
static AppLocalizations of(BuildContext context)
final Color backgroundColor
final Color progressColor