This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| final levelIndicator = Container( | |
| child: Container( | |
| child: LinearProgressIndicator( | |
| backgroundColor: Color.fromRGBO(209, 224, 224, 0.2), | |
| value: lesson.indicatorValue, | |
| valueColor: AlwaysStoppedAnimation(Colors.green)), | |
| ), | |
| ); | |
| final coursePrice = Container( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| final topContentText = Column( | |
| crossAxisAlignment: CrossAxisAlignment.start, | |
| children: <Widget>[ | |
| SizedBox(height: 120.0), | |
| Icon( | |
| Icons.directions_car, | |
| color: Colors.white, | |
| size: 40.0, | |
| ), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| final topContent = Stack( | |
| children: <Widget>[ | |
| Container( | |
| padding: EdgeInsets.only(left: 10.0), | |
| height: MediaQuery.of(context).size.height * 0.5, | |
| decoration: new BoxDecoration( | |
| image: new DecorationImage( | |
| image: new AssetImage("drive-steering-wheel.jpg"), | |
| fit: BoxFit.cover, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import 'package:beautiful_list/model/lesson.dart'; | |
| import 'package:flutter/material.dart'; | |
| class DetailPage extends StatelessWidget { | |
| final Lesson lesson; | |
| DetailPage({Key key, this.lesson}) : super(key: key); | |
| @override | |
| Widget build(BuildContext context) { | |
| return Scaffold( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| onTap: () { | |
| Navigator.push( | |
| context, | |
| MaterialPageRoute( | |
| builder: (context) => DetailPage(lesson: lesson))); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ListTile makeListTile(Lesson lesson) => ListTile( | |
| contentPadding: | |
| EdgeInsets.symmetric(horizontal: 20.0, vertical: 10.0), | |
| leading: Container( | |
| padding: EdgeInsets.only(right: 12.0), | |
| decoration: new BoxDecoration( | |
| border: new Border( | |
| right: new BorderSide(width: 1.0, color: Colors.white24))), | |
| child: Icon(Icons.autorenew, color: Colors.white), | |
| ), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ListTile makeListTile(Lesson lesson) => ListTile( | |
| contentPadding: | |
| EdgeInsets.symmetric(horizontal: 20.0, vertical: 10.0), | |
| leading: Container( | |
| padding: EdgeInsets.only(right: 12.0), | |
| decoration: new BoxDecoration( | |
| border: new Border( | |
| right: new BorderSide(width: 1.0, color: Colors.white24))), | |
| child: Icon(Icons.autorenew, color: Colors.white), | |
| ), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ListTile makeListTile(Lesson lesson) => ListTile( | |
| contentPadding: | |
| EdgeInsets.symmetric(horizontal: 20.0, vertical: 10.0), | |
| leading: Container( | |
| padding: EdgeInsets.only(right: 12.0), | |
| decoration: new BoxDecoration( | |
| border: new Border( | |
| right: new BorderSide(width: 1.0, color: Colors.white24))), | |
| child: Icon(Icons.autorenew, color: Colors.white), | |
| ), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ListTile makeListTile(Lesson lesson) => ListTile( | |
| contentPadding: | |
| EdgeInsets.symmetric(horizontal: 20.0, vertical: 10.0), | |
| leading: Container( | |
| padding: EdgeInsets.only(right: 12.0), | |
| decoration: new BoxDecoration( | |
| border: new Border( | |
| right: new BorderSide(width: 1.0, color: Colors.white24))), | |
| child: Icon(Icons.autorenew, color: Colors.white), | |
| ), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Card makeCard(Lesson lesson) => Card( | |
| elevation: 8.0, | |
| margin: new EdgeInsets.symmetric(horizontal: 10.0, vertical: 6.0), | |
| child: Container( | |
| decoration: BoxDecoration(color: Color.fromRGBO(64, 75, 96, .9)), | |
| child: makeListTile(lesson), | |
| ), | |
| ); |