Remove circular progress indicators
Our app is so fast these will look like bugs to flicker in front of the user.
This commit is contained in:
parent
b6a73c398e
commit
19f9dd9b3b
|
@ -76,8 +76,7 @@ class _PlansPageState extends State<_PlansPage> {
|
|||
)),
|
||||
);
|
||||
|
||||
if (plans == null)
|
||||
return const Center(child: CircularProgressIndicator());
|
||||
if (plans == null) return Container();
|
||||
|
||||
return PlanList(plans: plans);
|
||||
}),
|
||||
|
|
|
@ -69,10 +69,6 @@ class _SetList extends State<SetList> {
|
|||
pagingController: pagingController,
|
||||
gymSet: gymSet,
|
||||
),
|
||||
firstPageProgressIndicatorBuilder: (_) =>
|
||||
const Center(child: CircularProgressIndicator()),
|
||||
newPageProgressIndicatorBuilder: (_) =>
|
||||
const Center(child: CircularProgressIndicator()),
|
||||
),
|
||||
),
|
||||
floatingActionButton: FloatingActionButton(
|
||||
|
|
|
@ -53,8 +53,7 @@ class _SettingsPageState extends State<_SettingsPage> {
|
|||
final settings = snapshot.data;
|
||||
print('build: $settings');
|
||||
|
||||
if (settings == null)
|
||||
return const Center(child: CircularProgressIndicator());
|
||||
if (settings == null) return Container();
|
||||
|
||||
final filteredItems = [
|
||||
{'title': 'Alarm', 'value': settings.alarm},
|
||||
|
|
|
@ -112,8 +112,7 @@ class _StartPlanState extends State<StartPlan> {
|
|||
},
|
||||
icon: const Icon(Icons.edit)));
|
||||
|
||||
if (totals.isEmpty || counts.isEmpty)
|
||||
return const CircularProgressIndicator();
|
||||
if (totals.isEmpty || counts.isEmpty) return Container();
|
||||
|
||||
return SafeArea(
|
||||
child: Scaffold(
|
||||
|
@ -156,11 +155,19 @@ class _StartPlanState extends State<StartPlan> {
|
|||
decoration: const InputDecoration(labelText: 'Reps'),
|
||||
controller: repsController,
|
||||
focusNode: repsNode,
|
||||
onTap: () {
|
||||
repsController.selection = TextSelection(
|
||||
baseOffset: 0, extentOffset: repsController.text.length);
|
||||
},
|
||||
),
|
||||
TextFormField(
|
||||
decoration: const InputDecoration(labelText: 'Weight'),
|
||||
controller: weightController,
|
||||
focusNode: weightNode,
|
||||
onTap: () {
|
||||
weightController.selection = TextSelection(
|
||||
baseOffset: 0, extentOffset: weightController.text.length);
|
||||
},
|
||||
),
|
||||
],
|
||||
),
|
||||
|
|
Loading…
Reference in New Issue
Block a user