File tree Expand file tree Collapse file tree 1 file changed +29
-17
lines changed Expand file tree Collapse file tree 1 file changed +29
-17
lines changed Original file line number Diff line number Diff line change 11import 'package:flutter/material.dart' ;
22
33void main () => runApp (MaterialApp (
4- home: Scaffold (
5- appBar: AppBar (
6- backgroundColor: Colors .blue, //<-- SEE HERE
7- title: Text ('my first app' ),
8- centerTitle: true ,
9- ),
10- body: Center (
11- child: Text ('hello Fadoua' ),
12- ),
13- floatingActionButton: FloatingActionButton (
14- onPressed: () {
15- print ("clicked" );
16- // logic of the button
4+ home: Home (),
5+ )
6+ );
7+
8+ class Home extends StatelessWidget {
9+ const Home ({super .key});
10+
11+ @override
12+ Widget build (BuildContext context) {
13+ return Scaffold (
14+ appBar: AppBar (
15+ backgroundColor: Colors .blue, //<-- SEE HERE
16+ title: Text ('my first app' ),
17+ centerTitle: true ,
18+ ),
19+ body: Center (
20+ child: Text ('hello Fadoua' ),
21+ ),
22+ floatingActionButton: FloatingActionButton (
23+ onPressed: () {
24+ print ("clicked" );
25+ // logic of the button
1726 },
18- child: Text ('click' ),
19- ),
20- ),
21- ));
27+ child: Text ('click' ),
28+ ),
29+ );
30+
31+ }
32+ }
33+
2234
You can’t perform that action at this time.
0 commit comments