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

Side by Side Diff: appengine/swarming/elements/res/imp/index/swarming-index.html

Issue 2177353002: Add top level app element (Closed) Base URL: https://chromium.googlesource.com/external/github.com/luci/luci-py@hello-oauth
Patch Set: Address feedback and introduce new res/ layer of direction Created 4 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
(Empty)
1 <!--
2 Copyright 2016 The LUCI Authors. All rights reserved.
3 Use of this source code is governed under the Apache License, Version 2.0
4 that can be found in the LICENSE file.
5
6 This in an HTML Import-able file that contains the definition
7 of the following elements:
8
9 <swarming-index>
10
11 Swarming Index is the landing page for the Swarming UI.
12 It will have links to all other pages and a high-level overview of the fleet .
13
14 Usage:
15
16 <swarming-index></swarming-index>
17
18 Properties:
19 None. This is a top-level element.
20
21 Methods:
22 None.
23
24 Events:
25 None.
26 -->
27
28 <link rel="import" href="/res/imp/bower_components/iron-ajax/iron-ajax.html">
29
30 <link rel="import" href="/res/imp/common/swarming-app.html">
31
32 <dom-module id="swarming-index">
33 <template>
34 <style>
35 :host {
36 display: block;
37 }
38 </style>
39
40 <swarming-app
41 auth_headers="{{auth_headers}}"
42 name="Swarming"
43 busy="[[busy]]">
44
45 <iron-ajax id="request"
46 url="/_ah/api/swarming/v1/server/details"
47 headers="[[auth_headers]]"
48 handle-as="json"
49 last-response="{{serverDetails}}"
50 loading="{{busy}}">
51 </iron-ajax>
52
53 <h1>HELLO WORLD</h1>
54
55 <div>Server Version: [[serverDetails.server_version]]</div>
56
57 </swarming-app>
58
59 </template>
60 <script>
61 Polymer({
62 is: 'swarming-index',
63
64 properties: {
65 auth_headers: {
66 type: Object,
67 observer: "signIn",
68 },
69
70 serverDetails: {
71 type: String,
72 }
73 },
74
75 signIn: function(){
76 this.$.request.generateRequest();
77 },
78
79 });
80 </script>
81 </dom-module>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698