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

Side by Side Diff: appengine/swarming/elements/res/imp/common/swarming-app.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-app>
10
11 Usage:
12
13 <swarming-app></swarming-app>
14
15 Properties:
16 auth_headers: Object, Use this in iron-ajax to set oauth2 headers.
17 busy: Boolean, If the busy spinner should be active.
18 name: String, the name of the app to be displayed.
19
20 Methods:
21 None.
22
23 Events:
24 None.
25 -->
26
27 <link rel="import" href="/res/imp/bower_components/app-layout/app-layout.html">
28 <link rel="import" href="/res/imp/bower_components/paper-spinner/paper-spinner-l ite.html">
29 <link rel="import" href="/res/imp/bower_components/iron-flex-layout/iron-flex-la yout-classes.html">
30
31 <link rel="import" href="/res/imp/common/auth-signin.html">
32
33 <dom-module id="swarming-app">
34 <template>
35 <style include="iron-flex">
36 :host {
37 position: absolute;
38 top: 0;
39 bottom: 0;
40 left: 0;
41 right: 0;
42 }
43
44 app-toolbar {
45 background-color: #4285f4;
46 color: #fff;
47 }
48
49 app-toolbar a {
50 color: #fff;
51 }
52 .left {
53 margin-right:15px;
54 }
55 .right {
56 margin-left:15px;
57 }
58 .main-content {
59 padding: 3px;
60 }
61
62 paper-spinner-lite {
63 --paper-spinner-color: var(--google-yellow-500);
64 }
65 </style>
66 <app-header-layout>
67 <app-header fixed>
68 <app-toolbar>
69 <div class="title left">[[name]]</div>
70 <paper-spinner-lite class="left" active="[[busy]]"></paper-spinner-lit e>
71
72 <a class="left" href="/newui/">Home</a>
73 <a class="left" href="/newui/botlist">Bot List</a>
74 <div class="flex"></div>
75 <!-- TODO(kjlubick) Remove this hard-coded client-id.-->
76 <auth-signin
77 class="right"
78 client-id="20770472288-t5smpbpjptka4nd888fv0ctd23ftba2o.apps.googl eusercontent.com"
79 auth-headers="{{auth_headers}}">
80 </auth-signin>
81 </app-toolbar>
82 </app-header>
83 <div class="main-content">
84 <content></content>
85 </div>
86 </app-header-layout>
87
88 </template>
89 <script>
90 Polymer({
91 is: 'swarming-app',
92 properties: {
93 auth_headers: {
94 type: Object,
95 notify: true,
96 },
97 busy: {
98 type: Boolean,
99 },
100 name: {
101 type: String,
102 },
103 },
104
105 });
106 </script>
107 </dom-module>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698