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

Side by Side Diff: appengine/config_service/ui/src/config-ui/config-set-card.html

Issue 2989833002: config_service: include type of config to the config-set card (Closed)
Patch Set: Change config-set cards. Created 3 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
« no previous file with comments | « no previous file | appengine/config_service/ui/test/config-ui/config-set_test.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!-- 1 <!--
2 Copyright 2017 The LUCI Authors. All rights reserved. 2 Copyright 2017 The LUCI Authors. All rights reserved.
3 Use of this source code is governed under the Apache License, Version 2.0 3 Use of this source code is governed under the Apache License, Version 2.0
4 that can be found in the LICENSE file. 4 that can be found in the LICENSE file.
5 --> 5 -->
6 6
7 <link rel="import" href="../../bower_components/iron-icons/iron-icons.html"> 7 <link rel="import" href="../../bower_components/iron-icons/iron-icons.html">
8 <link rel="import" href="../../bower_components/paper-button/paper-button.html"> 8 <link rel="import" href="../../bower_components/paper-button/paper-button.html">
9 <link rel="import" href="../../bower_components/paper-card/paper-card.html"> 9 <link rel="import" href="../../bower_components/paper-card/paper-card.html">
10 <link rel="import" href="../../bower_components/polymer/polymer.html"> 10 <link rel="import" href="../../bower_components/polymer/polymer.html">
11 <link rel="import" href="../../bower_components/iron-icons/maps-icons.html"> 11 <link rel="import" href="../../bower_components/iron-icons/maps-icons.html">
12 <link rel="import" href="../../bower_components/iron-flex-layout/iron-flex-layou t.html"> 12 <link rel="import" href="../../bower_components/iron-flex-layout/iron-flex-layou t.html">
13 <link rel="import" href="../../bower_components/paper-tooltip/paper-tooltip.html "> 13 <link rel="import" href="../../bower_components/paper-tooltip/paper-tooltip.html ">
14 14
15 <dom-module id="config-set-card"> 15 <dom-module id="config-set-card">
16 <template> 16 <template>
17 <style> 17 <style>
18 a { 18 a {
19 text-decoration: none; 19 text-decoration: none;
20 color: inherit; 20 color: inherit;
21 } 21 }
22 22
23 paper-card { 23 paper-card {
24 width: 100%; 24 width: 100%;
25 } 25 }
26 26
27 p { 27 p {
28 color: var(--paper-grey-600); 28 color: var(--paper-grey-600);
29 word-wrap: break-word; 29 word-wrap: break-word;
30 font-size: 90%;
30 } 31 }
31 32
32 .config-title { 33 .config-title {
33 @apply --paper-font-headline; 34 @apply --paper-font-headline;
34 word-wrap: break-word; 35 word-wrap: break-word;
36 font-size: 120%;
35 } 37 }
36 38
37 .validation { 39 .validation {
38 float: right; 40 float: right;
39 font-size: 15px; 41 font-size: 15px;
40 vertical-align: middle; 42 vertical-align: middle;
41 } 43 }
42 44
43 .paper-green { color: var(--paper-green-600); } 45 .paper-green { color: var(--paper-green-600); }
44 46
45 .paper-red { color: var(--paper-red-600); } 47 .paper-red { color: var(--paper-red-600); }
46 48
47 .paper-grey { color: var(--paper-grey-600); } 49 .paper-grey { color: var(--paper-grey-600); }
48 50
49 </style> 51 </style>
50 52
51 <a href="#/[[name]]"> 53 <a href="#/[[name]]">
52 <paper-card elevation="2"> 54 <paper-card elevation="2">
53 <div class="card-content"> 55 <div class="card-content">
54 <div class="config-title">[[_formatName(name)]] 56 <div class="config-title">[[name]]
55 <div class="validation"> 57 <div class="validation">
56 <template is="dom-if" if="[[lastImportAttempt]]" restamp="true"> 58 <template is="dom-if" if="[[lastImportAttempt]]" restamp="true">
57 <template is="dom-if" if="[[lastImportAttempt.success]]" restamp ="true"> 59 <template is="dom-if" if="[[lastImportAttempt.success]]" restamp ="true">
58 <iron-icon id="successful-import" 60 <iron-icon id="successful-import"
59 icon="icons:check-circle" 61 icon="icons:check-circle"
60 class="paper-green"> 62 class="paper-green">
61 </iron-icon> 63 </iron-icon>
62 <paper-tooltip for="successful-import" offset="0"> 64 <paper-tooltip for="successful-import" offset="0">
63 Last import succeeded. 65 Last import succeeded.
64 </paper-tooltip> 66 </paper-tooltip>
(...skipping 12 matching lines...) Expand all
77 <iron-icon id="no-import" 79 <iron-icon id="no-import"
78 icon="icons:help" 80 icon="icons:help"
79 class="paper-grey"> 81 class="paper-grey">
80 </iron-icon> 82 </iron-icon>
81 <paper-tooltip for="no-import" offset="0"> 83 <paper-tooltip for="no-import" offset="0">
82 Last import attempt info not available. 84 Last import attempt info not available.
83 </paper-tooltip> 85 </paper-tooltip>
84 </template> 86 </template>
85 </div> 87 </div>
86 </div> 88 </div>
87 <p>Path: [[name]]</p>
88 </div> 89 </div>
89 </paper-card> 90 </paper-card>
90 </a> 91 </a>
91 92
92 </template> 93 </template>
93 <script> 94 <script>
94 Polymer({ 95 Polymer({
95 is: "config-set-card", 96 is: "config-set-card",
96 97
97 properties: { 98 properties: {
98 name: { 99 name: {
99 type: String 100 type: String
100 }, 101 },
101 102
102 lastImportAttempt: { 103 lastImportAttempt: {
103 type: Object 104 type: Object
104 }, 105 },
105 }, 106 },
106 107
107 _not: function(b) { 108 _not: function(b) {
108 return !b; 109 return !b;
109 }, 110 },
110 111
111 _formatName: function(name) {
112 var tempName = name.substring(name.indexOf("/") + 1);
113 return tempName.includes("/") ?
114 tempName.substring(0, tempName.indexOf("/")) : tempName;
115 }
116
117 }); 112 });
118 </script> 113 </script>
119 </dom-module> 114 </dom-module>
120 115
OLDNEW
« no previous file with comments | « no previous file | appengine/config_service/ui/test/config-ui/config-set_test.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698