Created
September 29, 2020 03:45
-
-
Save dhruvilp/a83c139cc69c98c07cebc5bbf3df0528 to your computer and use it in GitHub Desktop.
Flutter note-banner
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:flutter/material.dart'; | |
| void main() { | |
| runApp(MyApp()); | |
| } | |
| class MyApp extends StatelessWidget { | |
| @override | |
| Widget build(BuildContext context) { | |
| return MaterialApp( | |
| debugShowCheckedModeBanner: false, | |
| home: Scaffold( | |
| body: Center( | |
| child: MyWidget(), | |
| ), | |
| ), | |
| ); | |
| } | |
| } | |
| class MyWidget extends StatelessWidget { | |
| @override | |
| Widget build(BuildContext context) { | |
| return Container( | |
| width: MediaQuery.of(context).size.width / 1.5, | |
| height: 150.0, | |
| decoration: BoxDecoration( | |
| color: Colors.blue.shade100, | |
| border: Border( | |
| left: BorderSide( | |
| width: 5.0, | |
| color: Colors.blueAccent, | |
| ), | |
| ), | |
| ), | |
| child: ListTile( | |
| title: Padding( | |
| padding: const EdgeInsets.symmetric(vertical: 8.0), | |
| child: Text('》What is Lorem Ipsum?', style: Theme.of(context).textTheme.headline5,), | |
| ), | |
| subtitle: 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.", style: Theme.of(context).textTheme.bodyText2), | |
| ), | |
| ); | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment