Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(757)

Side by Side Diff: sky/framework/components/drawer_header.dart

Issue 1132063007: Rationalize Dart mojo and sky package structure (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 import '../fn.dart';
6 import '../layout.dart';
7 import '../theme/colors.dart';
8 import '../theme/view_configuration.dart';
9
10 class DrawerHeader extends Component {
11 static final Style _style = new Style('''
12 height: ${140 + kStatusBarHeight}px;
13 background-color: ${BlueGrey[50]};
14 border-bottom: 1px solid #D1D9E1;
15 padding-bottom: 7px;
16 margin-bottom: 8px;'''
17 );
18
19 static final FlexBoxParentData _spacerParentData = new FlexBoxParentData()..fl ex = 1;
20
21 static final Style _labelStyle = new Style('''
22 padding: 0 16px;'''
23 );
24
25 List<UINode> children;
26
27 DrawerHeader({ Object key, this.children }) : super(key: key);
28
29 UINode build() {
30 return new FlexContainer(
31 direction: FlexDirection.Column,
32 style: _style,
33 children: [
34 new ParentDataNode(
35 new Container(key: 'Spacer'),
36 _spacerParentData
37 ),
38 new Container(
39 key: 'Label',
40 style: _labelStyle,
41 children: children
42 )
43 ]
44 );
45 }
46 }
OLDNEW
« no previous file with comments | « sky/framework/components/drawer.dart ('k') | sky/framework/components/fixed_height_scrollable.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698