OLD | NEW |
| (Empty) |
1 /* Copyright 2015 The Chromium Authors. All rights reserved. | |
2 * Use of this source code is governed by a BSD-style license that can be | |
3 * found in the LICENSE file. */ | |
4 | |
5 :host { | |
6 display: flex; | |
7 flex-direction: column; | |
8 } | |
9 | |
10 #date { | |
11 color: rgb(104, 113, 116); | |
12 font-size: 100%; | |
13 font-weight: 500; | |
14 margin: 24px auto 10px; | |
15 width: var(--downloads-item-width); | |
16 } | |
17 | |
18 #date:empty { | |
19 display: none; | |
20 } | |
21 | |
22 #content { | |
23 background: white; | |
24 border-radius: 2px; | |
25 display: flex; | |
26 flex: none; | |
27 margin: 6px auto; | |
28 min-height: 103px; | |
29 position: relative; | |
30 width: var(--downloads-item-width); | |
31 } | |
32 | |
33 #content.is-active { | |
34 @apply(--shadow-elevation-2dp); | |
35 } | |
36 | |
37 #content:not(.is-active) { | |
38 background: rgba(255, 255, 255, .6); | |
39 box-shadow: 0 2px 2px 0 rgba(0, 0, 0, .03), 0 1px 4px 0 rgba(0, 0, 0, .048), | |
40 0 3px 1px -2px rgba(0, 0, 0, .12); | |
41 } | |
42 | |
43 #details { | |
44 -webkit-border-start: 1px #d8d8d8 solid; | |
45 -webkit-padding-end: 16px; | |
46 -webkit-padding-start: 24px; | |
47 display: flex; | |
48 flex: 1; | |
49 flex-direction: column; | |
50 min-width: 0; /* This allows #url to ellide correctly. */ | |
51 padding-bottom: 12px; | |
52 padding-top: 16px; | |
53 } | |
54 | |
55 #content:not(.is-active) #details { | |
56 color: rgba(186, 186, 186, .6); | |
57 } | |
58 | |
59 #content:not(.is-active) #name { | |
60 text-decoration: line-through; | |
61 } | |
62 | |
63 .icon-wrapper { | |
64 align-self: center; | |
65 flex: none; | |
66 justify-content: center; | |
67 margin: 0 24px; | |
68 } | |
69 | |
70 .icon { | |
71 height: 32px; | |
72 width: 32px; | |
73 } | |
74 | |
75 #content:-webkit-any(.show-progress, .dangerous) #file-icon-wrapper { | |
76 /* TODO(dbeam): animate from top-aligned to centered when items finish? */ | |
77 align-self: flex-start; | |
78 padding-top: 16px; | |
79 } | |
80 | |
81 #content:not(.is-active) .icon { | |
82 -webkit-filter: grayscale(100%); | |
83 opacity: .5; | |
84 } | |
85 | |
86 #danger-icon { | |
87 height: 32px; | |
88 width: 32px; | |
89 } | |
90 | |
91 #danger-icon[icon='cr:warning'] { | |
92 color: rgb(255, 193, 7); | |
93 } | |
94 | |
95 #danger-icon[icon='downloads:remove-circle'] { | |
96 color: rgb(244, 67, 54); | |
97 } | |
98 | |
99 #name, | |
100 #file-link, | |
101 #url { | |
102 max-width: 100%; | |
103 } | |
104 | |
105 #name, | |
106 #file-link { | |
107 font-weight: 500; | |
108 word-break: break-all; | |
109 } | |
110 | |
111 #name { | |
112 -webkit-margin-end: 12px; /* Only really affects #tag. */ | |
113 } | |
114 | |
115 #pause-or-resume, | |
116 .is-active :-webkit-any(#name, #file-link, #show) { | |
117 color: rgb(51, 103, 214); | |
118 } | |
119 | |
120 #tag { | |
121 color: #5a5a5a; | |
122 font-weight: 500; | |
123 } | |
124 | |
125 #url { | |
126 color: inherit; | |
127 margin-top: 6px; | |
128 min-height: 0; | |
129 overflow: hidden; | |
130 text-decoration: none; | |
131 text-overflow: ellipsis; | |
132 white-space: nowrap; | |
133 } | |
134 | |
135 .is-active #url { | |
136 color: #969696; | |
137 } | |
138 | |
139 #progress, | |
140 #description:not(:empty), | |
141 .controls { | |
142 margin-top: 16px; | |
143 } | |
144 | |
145 .is-active #description { | |
146 color: #616161; | |
147 } | |
148 | |
149 .dangerous #description { | |
150 color: rgb(239, 108, 0); | |
151 } | |
152 | |
153 #progress { | |
154 --paper-progress-active-color: rgb(54, 126, 237); | |
155 --paper-progress-container-color: rgb(223, 222, 223); | |
156 width: auto; | |
157 } | |
158 | |
159 .controls { | |
160 -webkit-margin-start: -.57em; | |
161 } | |
162 | |
163 #cancel, | |
164 #retry, | |
165 .keep, | |
166 .discard { | |
167 color: #5a5a5a; | |
168 } | |
169 | |
170 #show { | |
171 margin: .7em .57em; | |
172 } | |
173 | |
174 #controlled-by { | |
175 -webkit-margin-start: 8px; | |
176 } | |
177 | |
178 #controlled-by, | |
179 #controlled-by a { | |
180 color: #5a5a5a; | |
181 } | |
182 | |
183 .is-active #controlled-by { | |
184 color: #333; | |
185 } | |
186 | |
187 .is-active #controlled-by a { | |
188 color: rgb(51, 103, 214); | |
189 } | |
190 | |
191 #remove-wrapper { | |
192 align-self: flex-start; | |
193 margin: 0; | |
194 } | |
195 | |
196 #remove { | |
197 color: #969696; | |
198 font-size: 16px; | |
199 height: 32px; | |
200 line-height: 17px; /* TODO(dbeam): why is this necesssary? */ | |
201 width: 32px; | |
202 } | |
203 | |
204 #incognito { | |
205 bottom: 20px; | |
206 content: -webkit-image-set( | |
207 url(chrome://downloads/1x/incognito_marker.png) 1x, | |
208 url(chrome://downloads/2x/incognito_marker.png) 2x); | |
209 position: absolute; | |
210 right: 10px; | |
211 } | |
OLD | NEW |