-
Notifications
You must be signed in to change notification settings - Fork 26
Expand file tree
/
Copy pathmain.dart
More file actions
46 lines (42 loc) · 1.21 KB
/
main.dart
File metadata and controls
46 lines (42 loc) · 1.21 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
import 'package:flutter/material.dart';
import 'package:google_fonts/google_fonts.dart';
import 'news_ui/news_ui.dart';
import 'profile/home_screen.dart';
void main() {
runApp(const MaterialApp(
debugShowCheckedModeBanner: false,
home: MyApp(),
));
}
class MyApp extends StatelessWidget {
const MyApp({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
return Scaffold(
backgroundColor: Colors.white,
body: HomePage(),
appBar: AppBar(
backgroundColor: Colors.white,
elevation: 0,
title: const Text(
"Profile",
style: TextStyle(fontSize: 30, color: Colors.black),
),
actions: [
GestureDetector(
onTap: () {
Navigator.of(context)
.push(MaterialPageRoute(builder: (context) => NewsUi()));
},
child: Padding(
padding: EdgeInsets.all(15.0),
child: Text(
'News App ',
style: TextStyle(color: Colors.blue, fontSize: 20),
),
),
)
]),
);
}
}