Skip to content

Commit

Permalink
code cleaning
Browse files Browse the repository at this point in the history
  • Loading branch information
Spyy004 committed May 9, 2023
1 parent 7251d4d commit 804fff4
Show file tree
Hide file tree
Showing 6 changed files with 250 additions and 228 deletions.
2 changes: 1 addition & 1 deletion lib/screens/createbucketscreen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ class CreateBucketScreen extends StatelessWidget {
SizedBox(
height: Sizes.screenHeight(context) * 0.02,
),
MyDropDownScope(actions: 'CREATE'),
const MyDropDownScope(actions: 'CREATE'),
SizedBox(
height: Sizes.screenHeight(context) * 0.02,
),
Expand Down
447 changes: 233 additions & 214 deletions lib/screens/explorescreen.dart

Large diffs are not rendered by default.

1 change: 0 additions & 1 deletion lib/screens/feedbackscreen.dart
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import 'package:flutter/material.dart';
import 'package:flutter_email_sender/flutter_email_sender.dart';
import 'package:flutter_gen/gen_l10n/app_localizations.dart';
import 'package:lifelist/constants/consts.dart';

import '../components/index.dart';
import '../constants/index.dart';
Expand Down
22 changes: 13 additions & 9 deletions lib/screens/homescreen.dart
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import 'package:flutter/material.dart';
import 'package:lifelist/constants/index.dart';
import 'package:lifelist/models/bucket.dart';
import 'package:lifelist/services/firebaseservice.dart';
import 'package:provider/provider.dart';
import '../components/index.dart';
import 'package:flutter_gen/gen_l10n/app_localizations.dart';
Expand Down Expand Up @@ -56,7 +55,7 @@ class HomeScreen extends StatelessWidget {
Theme.of(context).primaryColor,
context: context,
builder: (BuildContext context) {
return Container(
return SizedBox(
height:
Sizes.screenHeight(context) * 0.3,
child: Padding(
Expand Down Expand Up @@ -128,7 +127,7 @@ class HomeScreen extends StatelessWidget {
).then((value) =>
bucketModel.fetchBucketsByScope());
},
icon: Icon(Icons.remove_red_eye)),
icon: const Icon(Icons.remove_red_eye)),
IconButton(
onPressed: () {
showModalBottomSheet(
Expand Down Expand Up @@ -193,7 +192,7 @@ class HomeScreen extends StatelessWidget {
ListView.builder(
shrinkWrap: true,
physics:
NeverScrollableScrollPhysics(),
const NeverScrollableScrollPhysics(),
scrollDirection:
Axis.vertical,
itemCount:
Expand Down Expand Up @@ -316,9 +315,8 @@ class HomeScreen extends StatelessWidget {
},
);
},
icon: Icon(Icons.filter_list))
icon: const Icon(Icons.filter_list))
],

),
SliverToBoxAdapter(
child: SizedBox(
Expand Down Expand Up @@ -412,7 +410,7 @@ class HomeScreen extends StatelessWidget {
CustomCard(
onTap: () async {
bucketModel.toggleAction();

Navigator.pushNamed(
context, SINGLE_BUCKET,
arguments: {
Expand Down Expand Up @@ -481,7 +479,10 @@ class HomeScreen extends StatelessWidget {
index]!
.isCompleted
? "${bucketModel.filteredBuckets[index]!.streak} Days Streak 🔥"
: "${bucketModel.filteredBuckets[index]!.timeLeft}",
: bucketModel
.filteredBuckets[
index]!
.timeLeft,
style: Theme.of(
context)
.textTheme
Expand All @@ -493,7 +494,10 @@ class HomeScreen extends StatelessWidget {
index]!
.isCompleted
? "${bucketModel.filteredBuckets[index]!.timeLeft} 🏆"
: "${bucketModel.filteredBuckets[index]!.timeLeft}",
: bucketModel
.filteredBuckets[
index]!
.timeLeft,
style: Theme.of(
context)
.textTheme
Expand Down
2 changes: 1 addition & 1 deletion lib/screens/onboardingscreen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class OnboardingScreen extends StatelessWidget {
style: Theme.of(context)
.textTheme
.displayLarge!
.merge(TextStyle(fontSize: 24)),
.merge(const TextStyle(fontSize: 24)),
),
SizedBox(
height: Sizes.screenHeight(context) * 0.05,
Expand Down
4 changes: 2 additions & 2 deletions lib/screens/singlebucketscreen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ class BucketDetailsScreen extends StatelessWidget {
.activeSingleBucket,
taskService.tasks);
},
icon: Icon(Icons.download)))
icon: const Icon(Icons.download)))
],
)
: CustomTextField(
Expand Down Expand Up @@ -405,7 +405,7 @@ class BucketDetailsScreen extends StatelessWidget {
.transferTemporaryTasks()
});
},
icon: Icon(
icon: const Icon(
Icons.add,
size: 30,
)),
Expand Down

0 comments on commit 804fff4

Please sign in to comment.