blob: 7bd6dc9434df851c063044190feea7a450bee58d [file] [log] [blame]
Primiano Tucci21b91bf2018-08-06 16:42:07 +01001// Copyright (C) 2018 The Android Open Source Project
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7// http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
Primiano Tuccif4a0c0a2019-10-29 10:39:52 +010014
Primiano Tucci21b91bf2018-08-06 16:42:07 +010015.sidebar {
Primiano Tuccif4a0c0a2019-10-29 10:39:52 +010016 --sidebar-padding-bottom: 40px;
Primiano Tuccid3a99832020-02-12 18:35:15 +000017 --sidebar-timing: 0.15s;
Primiano Tucci21b91bf2018-08-06 16:42:07 +010018 grid-area: sidebar;
Primiano Tucci425fd422019-01-24 10:48:31 +000019 z-index: 4;
Primiano Tucci21b91bf2018-08-06 16:42:07 +010020 background-color: #262f3c;
Isabelle Taylorb1024372020-02-25 17:47:54 +000021 overflow: hidden;
Isabelle Taylorf41b7c72019-07-24 13:55:43 +010022 width: var(--sidebar-width);
Isabelle Taylorf57b24f2019-07-31 11:06:41 +010023 display: flex;
24 flex-direction: column;
Primiano Tuccid3a99832020-02-12 18:35:15 +000025 transition: margin-left var(--anim-easing) var(--sidebar-timing),
26 visibility linear var(--sidebar-timing);
Primiano Tucci21b91bf2018-08-06 16:42:07 +010027 >* {
28 border-bottom: 1px solid #404854;
29 }
30 input[type=file] { display:none; }
31 >header {
Primiano Tucci32ea1032020-01-07 13:53:23 +000032 font-family: 'Raleway', sans-serif;
Primiano Tucci21b91bf2018-08-06 16:42:07 +010033 height: var(--topbar-height);
34 line-height: var(--topbar-height);
35 vertical-align: middle;
36 padding: 0 20px;
37 color: #fff;
38 font-weight: 400;
39 font-size: 24px;
40 letter-spacing: 0.5px;
Isabelle Taylorf41b7c72019-07-24 13:55:43 +010041 overflow: visible;
Primiano Tuccid3a99832020-02-12 18:35:15 +000042 .brand {
43 height: 40px;
44 margin-top: 4px;
Primiano Tucci21b91bf2018-08-06 16:42:07 +010045 }
Primiano Tucci31b7ef42021-02-23 17:33:09 +010046 &.canary::before, &.autopush::before {
Primiano Tucci63ac8b42021-02-16 11:50:08 +010047 display: block;
Primiano Tucci63ac8b42021-02-16 11:50:08 +010048 position: absolute;
49 font-size: 10px;
50 line-height: 10px;
51 font-family: 'Roboto', sans-serif;
52 left: 155px;
53 top: 7px;
54 }
Primiano Tucci31b7ef42021-02-23 17:33:09 +010055 &.canary::before {
56 content: 'CANARY';
57 color: #ffd700;
58 }
59 &.autopush::before {
60 content: 'AUTOPUSH';
61 color: #aed581;
62 }
Primiano Tuccid3a99832020-02-12 18:35:15 +000063 }
64 .sidebar-button {
65 position: absolute;
66 z-index: 5;
67 background-color: #262f3c;
68 height: var(--topbar-height);
69 left: calc(var(--sidebar-width) - 50px);
Primiano Tuccid3a99832020-02-12 18:35:15 +000070 border-radius: 0 5px 5px 0;
71 border-bottom: inherit;
72 visibility: visible; // So stays visible when the sidebar is hidden.
73 transition: left var(--anim-easing) var(--sidebar-timing);
74 width: 48px;
75 overflow: hidden;
76 >button {
77 vertical-align: middle;
78 }
79 }
80 &.hide-sidebar {
81 visibility: hidden;
82 margin-left: calc(var(--sidebar-width) * -1);
83 .sidebar-button {
84 left: 0;
85 }
Primiano Tucci21b91bf2018-08-06 16:42:07 +010086 }
Primiano Tuccif4a0c0a2019-10-29 10:39:52 +010087 .sidebar-scroll {
Isabelle Taylorf57b24f2019-07-31 11:06:41 +010088 overflow-y: auto;
89 flex: 1;
Isabelle Taylorf57b24f2019-07-31 11:06:41 +010090 &::-webkit-scrollbar {
91 width: 0.5em;
92 }
93 &::-webkit-scrollbar-track {
94 background-color: #19212b;
95 border-radius: 2px;
96 }
97 &::-webkit-scrollbar-thumb {
98 background: #b4b7ba6e;
99 border-radius: 2px;
100 }
Primiano Tuccif4a0c0a2019-10-29 10:39:52 +0100101 >.sidebar-scroll-container {
102 position: relative;
103 min-height: 100%;
104 padding-bottom: var(--sidebar-padding-bottom);
105
106 >section {
107 @include transition();
108 padding: 20px 0;
109 max-height: 80px;
110 .section-header {
111 cursor: pointer;
112 >h1,
113 >h2 {
Primiano Tucci32ea1032020-01-07 13:53:23 +0000114 font-family: 'Raleway', sans-serif;
Primiano Tuccif4a0c0a2019-10-29 10:39:52 +0100115 letter-spacing: 0.25px;
116 overflow: hidden;
117 text-overflow: ellipsis;
118 white-space: nowrap;
119 margin: 0 24px;
120 }
121 >h1 {
122 color: #fff;
123 font-size: 15px;
124 font-weight: 500;
125 }
126 >h2 {
127 @include transition();
128 color: rgba(255, 255, 255, 0.5);
129 font-size: 12px;
130 margin-top: 8px;
131 font-weight: 400;
132 }
133 }
134 &:hover {
135 background-color: #373f4b;
136 }
137 &.expanded {
138 background-color: #19212b;
139 max-height: unset;
140 .section-header h2 {
141 opacity: 0;
142 }
143 .section-content {
144 pointer-events: inherit;
145 opacity: 1;
146 }
147 }
148 }
149
150 .section-content {
151 pointer-events: none;
152 @include transition();
153 opacity: 0;
154 color: #b4b7ba;
155 a {
156 color: #b4b7ba;
157 }
158 ul {
159 list-style-type: none;
160 margin: 0;
161 padding: 0;
162 }
163 li {
164 @include transition();
165 a {
166 line-height: 24px;
167 font-size: 14px;
168 font-weight: 400;
Primiano Tucci32ea1032020-01-07 13:53:23 +0000169 font-family: 'Raleway', sans-serif;
Primiano Tuccif4a0c0a2019-10-29 10:39:52 +0100170 letter-spacing: 0.5px;
171 padding: 5px 24px;
172 text-decoration: none;
173 display: block;
Primiano Tucci29237452021-02-19 13:17:36 +0100174 &.pending {
175 color: rgba(255, 255, 255, 0.3);
176 &::after {
177 content: ' ';
178 display: inline-block;
179 vertical-align: middle;
180 box-sizing: border-box;
181 width: 18px;
182 height: 18px;
183 margin-left: 10px;
184 border-radius: 50%;
185 border: 2px solid #b4b7ba;
186 border-color: #b4b7ba transparent #b4b7ba transparent;
187 animation: pending-spinner 1.25s linear infinite;
188 }
189 @keyframes pending-spinner {
190 0% { transform: rotate(0deg); }
191 100% { transform: rotate(360deg); }
192 }
193 }
Primiano Tuccif4a0c0a2019-10-29 10:39:52 +0100194 &[disabled] {
195 text-decoration: line-through;
196 }
197 }
198 .material-icons {
Primiano Tuccif4a0c0a2019-10-29 10:39:52 +0100199 margin-right: 10px;
200 }
201 &:hover {
202 background-color: #373f4b;
203 }
Primiano Tucci6faa36e2020-05-04 21:54:51 +0100204 .trace-file-name {
205 white-space: break-spaces;
206 font-family: 'Roboto Condensed', sans-serif;
207 word-break: break-all;
208 user-select: text;
209 font-weight: 300;
210 letter-spacing: 0;
211 margin-top: -10px;
212 color: #fff;
213 }
Primiano Tuccif4a0c0a2019-10-29 10:39:52 +0100214 }
215 }
Isabelle Taylorf57b24f2019-07-31 11:06:41 +0100216 }
Primiano Tuccif4a0c0a2019-10-29 10:39:52 +0100217 }
218
219 .sidebar-footer {
220 position: absolute;
221 bottom: 0;
Primiano Tucciec590132020-11-16 14:16:44 +0100222 width: 100%;
Primiano Tuccif4a0c0a2019-10-29 10:39:52 +0100223 padding: 2px 10px;
224 display: grid;
225 height: - var(--sidebar-padding-bottom);
226 grid-template-columns: repeat(4, min-content);
227 grid-gap: 10px;
228
229 > button {
230 color: hsl(217, 39%, 94%);
231 i {
232 font-size: 24px;
233 }
234
235 &:hover {
236 color: hsl(45, 100%, 48%);
237 }
238 }
239
Primiano Tucci3552aaf2020-01-14 20:20:52 +0000240 > .dbg-info-square {
Primiano Tuccif4a0c0a2019-10-29 10:39:52 +0100241 width: 24px;
242 height: 22px;
243 line-height: 22px;
244 margin: 1px 0;
245 background: #12161b;
246 color: #4e71b3;
247 border-radius: 5px;
248 font-size: 12px;
249 text-align: center;
Primiano Tucci3552aaf2020-01-14 20:20:52 +0000250 &.green {
Primiano Tuccif4a0c0a2019-10-29 10:39:52 +0100251 background: #7aca75;
252 color: #12161b;
253 }
Primiano Tucci3552aaf2020-01-14 20:20:52 +0000254 &.amber {
255 background: #FFC107;
256 color: #333;
257 }
258 &.red {
Primiano Tuccic449fc12019-11-01 19:33:00 +0100259 background: #d32f2f;
260 color: #fff;
261 }
262 > div {
263 font-size: 10px;
264 line-height: 11px;
265 }
Isabelle Taylorf57b24f2019-07-31 11:06:41 +0100266 }
Primiano Tucciec590132020-11-16 14:16:44 +0100267
268 .version {
269 position: absolute;
270 right: 8px;
271 bottom: 3px;
272 font-size: 12px;
273 font-family: 'Roboto Condensed', 'Roboto', sans-serif;
274 a {
275 color: rgba(255, 255, 255, 0.5);
276 text-decoration: none;
277 }
278 margin-top: 11px;
279 }
Primiano Tucci21b91bf2018-08-06 16:42:07 +0100280 }
Hector Dearman250376b2018-08-07 11:15:52 +0100281}
Isabelle Taylorf41b7c72019-07-24 13:55:43 +0100282
Primiano Tucci8bcf6082021-06-11 17:15:22 +0100283// Hide the footer when running integration tests, as the version code and the
284// tiny text with pending queries can fail the screenshot diff test.
285body.testing .sidebar-footer {
286 visibility: hidden;
287}
288
Hector Dearmanf1f99eb2019-09-03 16:36:35 +0100289.keycap {
290 background-color: #fafbfc;
291 border: 1px solid #d1d5da;
292 border-bottom-color: #c6cbd1;
293 border-radius: 3px;
294 box-shadow: inset 0 -1px 0 #c6cbd1;
295 color: #444d56;
296 display: inline-block;
297 font-family: var(--monospace-font);
298 vertical-align: middle;
299
300 line-height: 20px;
301 padding: 3px 7px;
302}