Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import 'package:flutter/material.dart';
- import 'package:flutter/rendering.dart';
- void main() {
- runApp(MyApp());
- }
- class MyApp extends StatelessWidget {
- @override
- Widget build(BuildContext context) {
- return MaterialApp(
- title: 'Welcome to Flutter',
- home: Scaffold(
- appBar: AppBar(title: Text('Starwberry Pavlova')),
- body: Center(
- child: FractionallySizedBox(
- widthFactor: 0.8,
- child: Column(
- children: <Widget>[
- Image.network('https://ichef.bbci.co.uk/food/ic/food_16x9_832/recipes/strawberrypavlova_88895_16x9.jpg'),
- Padding(
- padding: EdgeInsets.only(top: 30, bottom: 20),
- child: Text('Strawberry Pavlova', style: TextStyle(fontSize: 20))
- ),
- Container(
- child: Text("Pavlova is a meringue-based dessert named after the Russian ballerine Anna Pavlova.\nPavlova features a crisp crust and soft, light inside, topped with fruit and whipped cream",
- textAlign: TextAlign.center, style: TextStyle(fontSize: 14, height: 1.2)),
- ),
- Padding(
- padding: EdgeInsets.only(top: 20, bottom: 20),
- child: Row(
- mainAxisAlignment: MainAxisAlignment.center,
- children: <Widget>[
- Row(children: <Widget>[for (var i = 0; i < 4; i++) Icon(Icons.star), Icon(Icons.star, color: Colors.yellow)]),
- Padding(padding: EdgeInsets.only(left: 30), child: Text('170 Reviews'))
- ])
- ),
- Container(
- margin: EdgeInsets.only(top: 5),
- child: Row(
- mainAxisAlignment: MainAxisAlignment.center,
- children: <Widget>[
- Column(children: <Widget>[Icon(Icons.bookmark_border), Padding(padding: EdgeInsets.only(top: 5, bottom: 10), child: Text('PREP')), Text('25 min')]),
- Column(children: <Widget>[Icon(Icons.alarm), Padding(padding: EdgeInsets.only(top: 5, bottom: 10, left: 30, right: 30), child: Text('COOK')), Text('1 hr')]),
- Column(children: <Widget>[Icon(Icons.local_dining), Padding(padding: EdgeInsets.only(top: 5, bottom: 10), child: Text('FEEDS')), Text('4-6')])
- ])
- )
- ],
- ),
- ),
- ),
- ),
- );
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement