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

Unified Diff: appengine/swarming/elements/polymer05/stats-table-chart.html

Issue 2408743002: Move elements/ to ui/ (Closed)
Patch Set: rebase again Created 4 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: appengine/swarming/elements/polymer05/stats-table-chart.html
diff --git a/appengine/swarming/elements/polymer05/stats-table-chart.html b/appengine/swarming/elements/polymer05/stats-table-chart.html
deleted file mode 100644
index 265272f0833a4c1aaa98bb2124725cf79eb5aeee..0000000000000000000000000000000000000000
--- a/appengine/swarming/elements/polymer05/stats-table-chart.html
+++ /dev/null
@@ -1,56 +0,0 @@
-<!--
-# Copyright 2015 The LUCI Authors. All rights reserved.
-# Use of this source code is governed under the Apache License, Version 2.0
-# that can be found in the LICENSE file.
-
--->
-
-<!--
-@group Swarming Elements
-
-`stats-table-chart' encapsulates a 'google-chart' of table type.
-This element exposes a 'data' attribute which is JSON serialized
-`google.visualization.DataTable` object and a `resolution` attribute that is
-'minutes', 'hours', or 'days'.
-
-Example:
- <stats-table-chart data="{{data_table}}"></stats-table-chart>
-
-@element stats-table-chart
--->
-
-<link rel="import" href="bower_components/polymer/polymer.html">
-<link rel="import" href="bower_components/google-apis/google-jsapi.html">
-
-<polymer-element name="stats-table-chart" attributes="data">
- <template>
- <div id="chart">(Loading...)</div>
- <google-jsapi on-api-load="{{readyForAction}}"></google-jsapi>
- </template>
- <script>
- Polymer('stats-table-chart', {
- observe: {
- 'data': 'loadData'
- },
-
- readyForAction: function() {
- google.load("visualization", "1", {
- packages: ['table'],
- callback: function() {
- this.isReady = true;
- this.loadData();
- }.bind(this)
- });
- },
-
- loadData: function() {
- if (this.data && this.isReady) {
- if (!this.table) {
- this.table = new google.visualization.Table(this.$.chart);
- }
- this.table.draw(new google.visualization.DataTable(this.data));
- }
- }
- });
- </script>
-</polymer-element>

Powered by Google App Engine
This is Rietveld 408576698