Primiano Tucci | 21b91bf | 2018-08-06 16:42:07 +0100 | [diff] [blame] | 1 | // 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 Tucci | f4a0c0a | 2019-10-29 10:39:52 +0100 | [diff] [blame] | 14 | |
Primiano Tucci | 21b91bf | 2018-08-06 16:42:07 +0100 | [diff] [blame] | 15 | .sidebar { |
Primiano Tucci | f4a0c0a | 2019-10-29 10:39:52 +0100 | [diff] [blame] | 16 | --sidebar-padding-bottom: 40px; |
Primiano Tucci | d3a9983 | 2020-02-12 18:35:15 +0000 | [diff] [blame] | 17 | --sidebar-timing: 0.15s; |
Primiano Tucci | 21b91bf | 2018-08-06 16:42:07 +0100 | [diff] [blame] | 18 | grid-area: sidebar; |
Primiano Tucci | 425fd42 | 2019-01-24 10:48:31 +0000 | [diff] [blame] | 19 | z-index: 4; |
Primiano Tucci | 21b91bf | 2018-08-06 16:42:07 +0100 | [diff] [blame] | 20 | background-color: #262f3c; |
Isabelle Taylor | b102437 | 2020-02-25 17:47:54 +0000 | [diff] [blame] | 21 | overflow: hidden; |
Isabelle Taylor | f41b7c7 | 2019-07-24 13:55:43 +0100 | [diff] [blame] | 22 | width: var(--sidebar-width); |
Isabelle Taylor | f57b24f | 2019-07-31 11:06:41 +0100 | [diff] [blame] | 23 | display: flex; |
| 24 | flex-direction: column; |
Primiano Tucci | d3a9983 | 2020-02-12 18:35:15 +0000 | [diff] [blame] | 25 | transition: margin-left var(--anim-easing) var(--sidebar-timing), |
| 26 | visibility linear var(--sidebar-timing); |
Primiano Tucci | 21b91bf | 2018-08-06 16:42:07 +0100 | [diff] [blame] | 27 | >* { |
| 28 | border-bottom: 1px solid #404854; |
| 29 | } |
| 30 | input[type=file] { display:none; } |
| 31 | >header { |
Primiano Tucci | 32ea103 | 2020-01-07 13:53:23 +0000 | [diff] [blame] | 32 | font-family: 'Raleway', sans-serif; |
Primiano Tucci | 21b91bf | 2018-08-06 16:42:07 +0100 | [diff] [blame] | 33 | 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 Taylor | f41b7c7 | 2019-07-24 13:55:43 +0100 | [diff] [blame] | 41 | overflow: visible; |
Primiano Tucci | d3a9983 | 2020-02-12 18:35:15 +0000 | [diff] [blame] | 42 | .brand { |
| 43 | height: 40px; |
| 44 | margin-top: 4px; |
Primiano Tucci | 21b91bf | 2018-08-06 16:42:07 +0100 | [diff] [blame] | 45 | } |
Primiano Tucci | 31b7ef4 | 2021-02-23 17:33:09 +0100 | [diff] [blame] | 46 | &.canary::before, &.autopush::before { |
Primiano Tucci | 63ac8b4 | 2021-02-16 11:50:08 +0100 | [diff] [blame] | 47 | display: block; |
Primiano Tucci | 63ac8b4 | 2021-02-16 11:50:08 +0100 | [diff] [blame] | 48 | position: absolute; |
| 49 | font-size: 10px; |
| 50 | line-height: 10px; |
| 51 | font-family: 'Roboto', sans-serif; |
| 52 | left: 155px; |
| 53 | top: 7px; |
| 54 | } |
Primiano Tucci | 31b7ef4 | 2021-02-23 17:33:09 +0100 | [diff] [blame] | 55 | &.canary::before { |
| 56 | content: 'CANARY'; |
| 57 | color: #ffd700; |
| 58 | } |
| 59 | &.autopush::before { |
| 60 | content: 'AUTOPUSH'; |
| 61 | color: #aed581; |
| 62 | } |
Primiano Tucci | d3a9983 | 2020-02-12 18:35:15 +0000 | [diff] [blame] | 63 | } |
| 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 Tucci | d3a9983 | 2020-02-12 18:35:15 +0000 | [diff] [blame] | 70 | 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 Tucci | 21b91bf | 2018-08-06 16:42:07 +0100 | [diff] [blame] | 86 | } |
Primiano Tucci | f4a0c0a | 2019-10-29 10:39:52 +0100 | [diff] [blame] | 87 | .sidebar-scroll { |
Isabelle Taylor | f57b24f | 2019-07-31 11:06:41 +0100 | [diff] [blame] | 88 | overflow-y: auto; |
| 89 | flex: 1; |
Isabelle Taylor | f57b24f | 2019-07-31 11:06:41 +0100 | [diff] [blame] | 90 | &::-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 Tucci | f4a0c0a | 2019-10-29 10:39:52 +0100 | [diff] [blame] | 101 | >.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 Tucci | 32ea103 | 2020-01-07 13:53:23 +0000 | [diff] [blame] | 114 | font-family: 'Raleway', sans-serif; |
Primiano Tucci | f4a0c0a | 2019-10-29 10:39:52 +0100 | [diff] [blame] | 115 | 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 Tucci | 32ea103 | 2020-01-07 13:53:23 +0000 | [diff] [blame] | 169 | font-family: 'Raleway', sans-serif; |
Primiano Tucci | f4a0c0a | 2019-10-29 10:39:52 +0100 | [diff] [blame] | 170 | letter-spacing: 0.5px; |
| 171 | padding: 5px 24px; |
| 172 | text-decoration: none; |
| 173 | display: block; |
Primiano Tucci | 2923745 | 2021-02-19 13:17:36 +0100 | [diff] [blame] | 174 | &.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 Tucci | f4a0c0a | 2019-10-29 10:39:52 +0100 | [diff] [blame] | 194 | &[disabled] { |
| 195 | text-decoration: line-through; |
| 196 | } |
| 197 | } |
| 198 | .material-icons { |
Primiano Tucci | f4a0c0a | 2019-10-29 10:39:52 +0100 | [diff] [blame] | 199 | margin-right: 10px; |
| 200 | } |
| 201 | &:hover { |
| 202 | background-color: #373f4b; |
| 203 | } |
Primiano Tucci | 6faa36e | 2020-05-04 21:54:51 +0100 | [diff] [blame] | 204 | .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 Tucci | f4a0c0a | 2019-10-29 10:39:52 +0100 | [diff] [blame] | 214 | } |
| 215 | } |
Isabelle Taylor | f57b24f | 2019-07-31 11:06:41 +0100 | [diff] [blame] | 216 | } |
Primiano Tucci | f4a0c0a | 2019-10-29 10:39:52 +0100 | [diff] [blame] | 217 | } |
| 218 | |
| 219 | .sidebar-footer { |
| 220 | position: absolute; |
| 221 | bottom: 0; |
Primiano Tucci | ec59013 | 2020-11-16 14:16:44 +0100 | [diff] [blame] | 222 | width: 100%; |
Primiano Tucci | f4a0c0a | 2019-10-29 10:39:52 +0100 | [diff] [blame] | 223 | 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 Tucci | 3552aaf | 2020-01-14 20:20:52 +0000 | [diff] [blame] | 240 | > .dbg-info-square { |
Primiano Tucci | f4a0c0a | 2019-10-29 10:39:52 +0100 | [diff] [blame] | 241 | 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 Tucci | 3552aaf | 2020-01-14 20:20:52 +0000 | [diff] [blame] | 250 | &.green { |
Primiano Tucci | f4a0c0a | 2019-10-29 10:39:52 +0100 | [diff] [blame] | 251 | background: #7aca75; |
| 252 | color: #12161b; |
| 253 | } |
Primiano Tucci | 3552aaf | 2020-01-14 20:20:52 +0000 | [diff] [blame] | 254 | &.amber { |
| 255 | background: #FFC107; |
| 256 | color: #333; |
| 257 | } |
| 258 | &.red { |
Primiano Tucci | c449fc1 | 2019-11-01 19:33:00 +0100 | [diff] [blame] | 259 | background: #d32f2f; |
| 260 | color: #fff; |
| 261 | } |
| 262 | > div { |
| 263 | font-size: 10px; |
| 264 | line-height: 11px; |
| 265 | } |
Isabelle Taylor | f57b24f | 2019-07-31 11:06:41 +0100 | [diff] [blame] | 266 | } |
Primiano Tucci | ec59013 | 2020-11-16 14:16:44 +0100 | [diff] [blame] | 267 | |
| 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 Tucci | 21b91bf | 2018-08-06 16:42:07 +0100 | [diff] [blame] | 280 | } |
Hector Dearman | 250376b | 2018-08-07 11:15:52 +0100 | [diff] [blame] | 281 | } |
Isabelle Taylor | f41b7c7 | 2019-07-24 13:55:43 +0100 | [diff] [blame] | 282 | |
Primiano Tucci | 8bcf608 | 2021-06-11 17:15:22 +0100 | [diff] [blame^] | 283 | // 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. |
| 285 | body.testing .sidebar-footer { |
| 286 | visibility: hidden; |
| 287 | } |
| 288 | |
Hector Dearman | f1f99eb | 2019-09-03 16:36:35 +0100 | [diff] [blame] | 289 | .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 | } |