From dc9c95375f9f600bfec853963bf60ab03f2811d8 Mon Sep 17 00:00:00 2001 From: Chris Bracken Date: Thu, 14 Dec 2017 18:32:41 -0800 Subject: [PATCH] Apply media padding in Color, Typography demos (#13592) --- .../flutter_gallery/lib/demo/colors_demo.dart | 18 +++++++++++------- .../lib/demo/typography_demo.dart | 6 +++++- 2 files changed, 16 insertions(+), 8 deletions(-) diff --git a/examples/flutter_gallery/lib/demo/colors_demo.dart b/examples/flutter_gallery/lib/demo/colors_demo.dart index 35a1be8a5d9..4693a60dccf 100644 --- a/examples/flutter_gallery/lib/demo/colors_demo.dart +++ b/examples/flutter_gallery/lib/demo/colors_demo.dart @@ -64,13 +64,17 @@ class ColorItem extends StatelessWidget { height: kColorItemHeight, padding: const EdgeInsets.symmetric(horizontal: 16.0), color: color, - child: new Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - crossAxisAlignment: CrossAxisAlignment.center, - children: [ - new Text('$prefix$index'), - new Text(colorString()), - ], + child: new SafeArea( + top: false, + bottom: false, + child: new Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + crossAxisAlignment: CrossAxisAlignment.center, + children: [ + new Text('$prefix$index'), + new Text(colorString()), + ], + ), ), ); } diff --git a/examples/flutter_gallery/lib/demo/typography_demo.dart b/examples/flutter_gallery/lib/demo/typography_demo.dart index b39f6328dff..2337a63e873 100644 --- a/examples/flutter_gallery/lib/demo/typography_demo.dart +++ b/examples/flutter_gallery/lib/demo/typography_demo.dart @@ -71,7 +71,11 @@ class TypographyDemo extends StatelessWidget { return new Scaffold( appBar: new AppBar(title: const Text('Typography')), - body: new ListView(children: styleItems) + body: new SafeArea( + top: false, + bottom: false, + child: new ListView(children: styleItems), + ), ); } }