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

Side by Side Diff: appengine/sheriff_o_matic/ui/ct-chart.html

Issue 1315693002: SoM: upgrade Polymer from 0.5 to 1.0 Base URL: https://chromium.googlesource.com/infra/infra.git@master
Patch Set: get bower_components from polymer_1.0.4 Created 5 years, 4 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
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 --><html><head><link rel="import" href="../lib/chart-loader.html">
6 6
7 <link rel="import" href="../lib/chart-loader.html"> 7 <dom-module id="ct-chart">
8
9 <polymer-element name="ct-chart" attributes="table options width height">
10 <template> 8 <template>
11 <canvas id='chart' width="{{ width }}" height="{{ height }}"></canvas> 9 <canvas id="chart" width="{{ width }}" height="{{ height }}"></canvas>
12 </template> 10 </template>
13 <script> 11 <script>
14 Polymer({ 12 Polymer({
15 table: null, 13 is: 'ct-chart',
16 options: null, 14 properties: {
17 observe: { 15 height: { notify: true },
18 options: 'updateChart', 16 options: {
19 table: 'updateChart' 17 value: null,
18 notify: true,
19 observer: 'updateChart'
20 },
21 table: {
22 value: null,
23 notify: true,
24 observer: 'updateChart'
25 },
26 width: { notify: true }
20 }, 27 },
21 updateChart: function() { 28 updateChart: function () {
22 if (this.table == null || this.options == null) { 29 if (this.table == null || this.options == null) {
23 return; 30 return;
24 } 31 }
25 var ctx = this.$.chart.getContext("2d"); 32 var ctx = this.$.chart.getContext('2d');
26 new Chart(ctx).Bar(this.table, this.options); 33 new Chart(ctx).Bar(this.table, this.options);
27 } 34 }
28 }); 35 });
29 </script> 36 </script>
30 </template> 37 </dom-module>
OLDNEW
« no previous file with comments | « appengine/sheriff_o_matic/ui/ct-button.html ('k') | appengine/sheriff_o_matic/ui/ct-commit.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698