Created
February 10, 2019 09:34
-
-
Save deven98/bccd681acff6ed697f8e5db17eec9613 to your computer and use it in GitHub Desktop.
This file contains 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:flutter/material.dart'; | |
class DemoPage extends StatefulWidget { | |
@override | |
_DemoPageState createState() => _DemoPageState(); | |
} | |
class _DemoPageState extends State<DemoPage> { | |
@override | |
Widget build(BuildContext context) { | |
return Scaffold( | |
body: Stack( | |
children: <Widget>[ | |
Container( | |
decoration: BoxDecoration( | |
image: DecorationImage( | |
image: AssetImage('images/new_york.jpg'), | |
fit: BoxFit.fitHeight, | |
), | |
), | |
), | |
Positioned( | |
bottom: 48.0, | |
left: 10.0, | |
right: 10.0, | |
child: Card( | |
elevation: 8.0, | |
shape: RoundedRectangleBorder( | |
borderRadius: BorderRadius.circular(8.0), | |
), | |
child: Column( | |
children: <Widget>[ | |
Padding( | |
padding: const EdgeInsets.all(16.0), | |
child: Text( | |
"New York", | |
style: TextStyle( | |
fontSize: 20.0, | |
fontWeight: FontWeight.bold, | |
), | |
), | |
), | |
Padding( | |
padding: const EdgeInsets.all(16.0), | |
child: Text( | |
"Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book."), | |
), | |
], | |
), | |
), | |
), | |
], | |
), | |
); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment