@@ -37,29 +37,27 @@ class _HomeScreenState extends State<HomeScreen> {
3737 _currentView = viewName;
3838 });
3939 }
40- void _goBackToHome (){
40+
41+ void _goBackToHome () {
4142 setState (() {
4243 _currentView = 'home' ;
4344 });
4445 }
45- Widget _buildCurrentView (){
46- switch (_currentView){
46+
47+ Widget _buildCurrentView () {
48+ switch (_currentView) {
4749 case 'graph' :
4850 return _buildGraphView ();
4951 default :
5052 return _buildHomeView ();
5153 }
5254 }
53- Widget _buildGraphView (){
54- return Stack (
55- children: [
56- HomeDegreeGraph (
57- onBack: _goBackToHome,
58- ),
59- ],
60- );
55+
56+ Widget _buildGraphView () {
57+ return Stack (children: [HomeDegreeGraph (onBack: _goBackToHome)]);
6158 }
62- Widget _buildHomeView (){
59+
60+ Widget _buildHomeView () {
6361 return Stack (
6462 children: [
6563 Positioned (
@@ -90,26 +88,22 @@ class _HomeScreenState extends State<HomeScreen> {
9088 Column (
9189 crossAxisAlignment: CrossAxisAlignment .start,
9290 children: [
93- SizedBox (height: MediaQuery .of (context).size.height * 0.14 ),
91+ SizedBox (height: MediaQuery .of (context).size.height * 0.13 ),
9492 HomeOngiText (username: _username),
9593 SizedBox (height: MediaQuery .of (context).size.height * 0.01 ),
96- HomeCapsuleSection (
97- onGraphTap: () => _changeView ('graph' ),
98- ),
94+ HomeCapsuleSection (onGraphTap: () => _changeView ('graph' )),
9995 ],
10096 ),
10197 ],
10298 );
10399 }
100+
104101 @override
105102 Widget build (BuildContext context) {
106103 return Stack (
107104 children: [
108- Container (
109- color: AppColors .ongiOrange,
110- child: _buildCurrentView (),
111- ),
105+ Container (color: AppColors .ongiOrange, child: _buildCurrentView ()),
112106 ],
113107 );
114108 }
115- }
109+ }
0 commit comments