@@ -22,60 +22,63 @@ class CategoriesCard extends StatelessWidget {
22
22
23
23
return Card (
24
24
elevation: elevation,
25
- child: Column (
26
- children: [
27
- Padding (
28
- padding: const EdgeInsets .only (top: 5 ),
29
- child: Text (
30
- currentCategory.name,
31
- style: Theme .of (context).textTheme.titleLarge,
32
- ),
33
- ),
34
- Container (
35
- padding: const EdgeInsets .all (10 ),
36
- height: 220 ,
37
- child: MeasurementChartWidgetFl (
38
- entriesAll,
39
- currentCategory.unit,
40
- avgs: entries7dAvg,
41
- ),
42
- ),
43
- if (entries7dAvg.isNotEmpty)
44
- MeasurementOverallChangeWidget (
45
- entries7dAvg.first,
46
- entries7dAvg.last,
47
- currentCategory.unit,
25
+ child: SingleChildScrollView (
26
+ scrollDirection: Axis .vertical,
27
+ child: Column (
28
+ children: [
29
+ Padding (
30
+ padding: const EdgeInsets .only (top: 5 ),
31
+ child: Text (
32
+ currentCategory.name,
33
+ style: Theme .of (context).textTheme.titleLarge,
34
+ ),
48
35
),
49
- const Divider (),
50
- Row (
51
- mainAxisAlignment: MainAxisAlignment .spaceBetween,
52
- children: [
53
- TextButton (
54
- child: Text (AppLocalizations .of (context).goToDetailPage),
55
- onPressed: () {
56
- Navigator .pushNamed (
57
- context,
58
- MeasurementEntriesScreen .routeName,
59
- arguments: currentCategory.id,
60
- );
61
- },
36
+ Container (
37
+ padding: const EdgeInsets .all (10 ),
38
+ height: 220 ,
39
+ child: MeasurementChartWidgetFl (
40
+ entriesAll,
41
+ currentCategory.unit,
42
+ avgs: entries7dAvg,
62
43
),
63
- IconButton (
64
- onPressed: () async {
65
- await Navigator .pushNamed (
66
- context,
67
- FormScreen .routeName,
68
- arguments: FormScreenArguments (
69
- AppLocalizations .of (context).newEntry,
70
- MeasurementEntryForm (currentCategory.id! ),
71
- ),
72
- );
73
- },
74
- icon: const Icon (Icons .add),
44
+ ),
45
+ if (entries7dAvg.isNotEmpty)
46
+ MeasurementOverallChangeWidget (
47
+ entries7dAvg.first,
48
+ entries7dAvg.last,
49
+ currentCategory.unit,
75
50
),
76
- ],
77
- ),
78
- ],
51
+ const Divider (),
52
+ Row (
53
+ mainAxisAlignment: MainAxisAlignment .spaceBetween,
54
+ children: [
55
+ TextButton (
56
+ child: Text (AppLocalizations .of (context).goToDetailPage),
57
+ onPressed: () {
58
+ Navigator .pushNamed (
59
+ context,
60
+ MeasurementEntriesScreen .routeName,
61
+ arguments: currentCategory.id,
62
+ );
63
+ },
64
+ ),
65
+ IconButton (
66
+ onPressed: () async {
67
+ await Navigator .pushNamed (
68
+ context,
69
+ FormScreen .routeName,
70
+ arguments: FormScreenArguments (
71
+ AppLocalizations .of (context).newEntry,
72
+ MeasurementEntryForm (currentCategory.id! ),
73
+ ),
74
+ );
75
+ },
76
+ icon: const Icon (Icons .add),
77
+ ),
78
+ ],
79
+ ),
80
+ ],
81
+ ),
79
82
),
80
83
);
81
84
}
0 commit comments