Skip to content

Commit

Permalink
applied app theme to status and nav bar
Browse files Browse the repository at this point in the history
  • Loading branch information
SP-XD committed Dec 29, 2021
1 parent 83bc20a commit b99f0e3
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
7 changes: 7 additions & 0 deletions go_green/lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import 'package:go_green/utils/routes.dart';
import 'package:provider/provider.dart';
import 'pages/welcome_page.dart';
import 'package:go_green/provider/database.dart';
import 'package:flutter/services.dart';

void main() async{
WidgetsFlutterBinding.ensureInitialized();
Expand All @@ -18,6 +19,11 @@ void main() async{
runApp(ChangeNotifierProvider(
create: (context) => DataBase(),
child:const GoGreen()));
SystemChrome.setSystemUIOverlayStyle( SystemUiOverlayStyle(
statusBarColor: Colors.grey.shade200,
statusBarIconBrightness: Brightness.dark,
systemNavigationBarColor: Colors.grey.shade200,
));
}

class GoGreen extends StatelessWidget{
Expand All @@ -38,6 +44,7 @@ class GoGreen extends StatelessWidget{
borderRadius: BorderRadius.circular(5)
)
)

),
initialRoute: "/",
routes: {
Expand Down
2 changes: 1 addition & 1 deletion go_green/lib/nav_bar.dart
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class _NavBarState extends State<NavBar> {
),
bottomNavigationBar: SafeArea(
child: Padding(
padding: const EdgeInsets.symmetric(horizontal: 15, vertical: 15),
padding: const EdgeInsets.symmetric(horizontal: 15, vertical: 10),
child: GNav(
tabBorderRadius: 10,
tabBackgroundColor: Colors.white,
Expand Down

0 comments on commit b99f0e3

Please sign in to comment.