updates to display ratio of analytics charts and tiles

This commit is contained in:
ggurdin 2023-11-09 14:51:43 -05:00
parent df884fb7e4
commit 6defa8c7bb
3 changed files with 11 additions and 11 deletions

View file

@ -33,13 +33,12 @@ class BarChartCard extends StatelessWidget {
style: Theme.of(context).textTheme.bodyMedium,
),
const SizedBox(height: 14),
AspectRatio(
aspectRatio: 2,
child: loadingData
Expanded(
child: loadingData || barChart == null
? const Center(
child: CircularProgressIndicator(),
)
: barChart,
: barChart!,
),
const SizedBox(height: 10),
legend,

View file

@ -197,8 +197,12 @@ class BaseAnalyticsView extends StatelessWidget {
withScrolling: false,
child: Column(
children: [
chartView(context),
Expanded(
flex: 1,
child: chartView(context),
),
Expanded(
flex: 1,
child: DefaultTabController(
length: 2,
child: Column(

View file

@ -154,19 +154,16 @@ class ConstructListView extends StatelessWidget {
@override
Widget build(BuildContext context) {
if (!init) {
return const SizedBox(
height: 400,
return const Expanded(
child: Center(child: CircularProgressIndicator()),
);
}
if (constructs.isEmpty) {
return SizedBox(
height: 400,
return Expanded(
child: Center(child: Text(L10n.of(context)!.noDataFound)),
);
}
return SizedBox(
height: 400,
return Expanded(
child: ListView.builder(
itemCount: constructs.length,
itemBuilder: (context, index) {