OLD | NEW |
---|---|
1 <!-- | 1 <!-- |
2 Copyright 2014 The Chromium Authors. All rights reserved. | 2 Copyright 2014 The Chromium Authors. All rights reserved. |
3 Use of this source code is governed by a BSD-style license that can be | 3 Use of this source code is governed by a BSD-style license that can be |
4 found in the LICENSE file. | 4 found in the LICENSE file. |
5 --> | 5 --> |
6 | 6 |
7 <link rel="import" href="ct-builder-grid.html"> | 7 <link rel="import" href="ct-builder-grid.html"> |
8 <link rel="import" href="ct-commit-list.html"> | 8 <link rel="import" href="ct-commit-list.html"> |
9 <link rel="import" href="ct-test-list.html"> | 9 <link rel="import" href="ct-test-list.html"> |
10 | 10 |
11 <polymer-element name="ct-bot-failure-card" attributes="group builderList" noscr ipt> | 11 <polymer-element name="ct-bot-failure-card" attributes="group commitLog" noscrip t> |
12 <template> | 12 <template> |
13 <style> | 13 <style> |
14 :host { | |
15 display: flex; | |
16 flex: 1; | |
ojan
2014/09/11 01:50:04
flex: 1 is a property of the embedder, not the com
| |
17 } | |
18 | |
14 ct-builder-grid { | 19 ct-builder-grid { |
15 margin-right: 10px; | 20 margin-right: 10px; |
16 width: 250px; | 21 width: 250px; |
17 } | 22 } |
18 | 23 |
19 #failure { | 24 #failure { |
20 flex: 1; | 25 flex: 1; |
21 } | 26 } |
22 </style> | 27 </style> |
23 <ct-builder-grid builderList="{{ builderList }}"></ct-builder-grid> | 28 <ct-builder-grid builderList="{{ _builderList }}"></ct-builder-grid> |
24 <div id="failure"> | 29 <div id="failure"> |
25 <ct-test-list tests="{{ group.failures }}" tree="{{ tree }}"></ct-test-lis t> | 30 <ct-test-list tests="{{ group.failures }}" tree="{{ tree }}"></ct-test-lis t> |
26 <ct-commit-list commitList="{{ group.commitList }}"></ct-commit-list> | 31 <ct-commit-list commitList="{{ group.commitList }}"></ct-commit-list> |
27 </div> | 32 </div> |
28 </template> | 33 </template> |
34 <script> | |
35 Polymer({ | |
36 group: null, | |
37 commitLog: null, | |
38 _builderList: null, | |
39 | |
40 observe: { | |
41 group: '_updateCommitList', | |
42 commitLog: '_updateCommitList', | |
43 'group.failures': '_updateBuilderList', | |
44 }, | |
45 | |
46 _updateCommitList: function() { | |
47 if (this.group && this.group.commitList && this.commitLog) | |
48 this.group.commitList.update(this.commitLog); | |
49 }, | |
50 | |
51 _updateBuilderList: function() { | |
52 this._builderList = new CTBuilderList(this.group.failures); | |
53 }, | |
54 }); | |
55 </script> | |
29 </polymer-element> | 56 </polymer-element> |
30 | 57 |
31 | 58 |
OLD | NEW |